Re: Reliably check if we're running under cygwin inside Makefile

2009-01-12 Thread Greg Chicares
On 2009-01-12 12:19Z, Eric Lilja wrote: Hello, I have a program that will built both under fedora and under cygwin. The program is written in C and the Makefile is slightly different between the two systems. Is it possible to check some environment variable in the makefile to determine what

Re: Reliably check if we're running under cygwin inside Makefile

2009-01-12 Thread Fergus
osname := $(shell uname -s) osver := $(shell uname -r) cpuarch := $(shell uname -m) Probably the fault is mine but I can't get this to do anything useful in Cygwin. You could try (something like): case `uname` in *CYGWIN*) OS=Cygwin ;; *Darwin*) OS=Darwin ;; *)

Re: Reliably check if we're running under cygwin inside Makefile

2009-01-12 Thread Dave Korn
Fergus wrote: osname := $(shell uname -s) osver := $(shell uname -r) cpuarch := $(shell uname -m) Probably the fault is mine but I can't get this to do anything useful in Cygwin. You could try (something like): case `uname` in Hmm, did you try those first examples in bash before

Re: Reliably check if we're running under cygwin inside Makefile

2009-01-12 Thread Grant Edwards
On 2009-01-12, Fergus fer...@bonhard.uklinux.net wrote: osname := $(shell uname -s) osver := $(shell uname -r) cpuarch := $(shell uname -m) Probably the fault is mine but I can't get this to do anything useful in Cygwin. You could try (something like): case `uname` in *CYGWIN*)