You can check if you are running windows by checking if a variable only defined under Windows is set (I use it quite often in my Makefiles:
ifndef OS
# Linux code
else
# WIndows code
endif
You can also do:
ifdef OS
# WIndows code
else
# Linux code
endif
I prefer the top version due to my preference of Linux over Windows.
You can check if you are running windows by checking if a variable only defined under Windows is set (I use it quite often in my Makefiles:
You can also do:
I prefer the top version due to my preference of Linux over Windows.