Re: [Msys2-users] one Makefile for all

2019-03-14 Thread Alan W. Irwin
On 2019-03-12 12:08+0100 Valerio Messina via Msys2-users wrote: hi, I want to use a single Makefile for three platforms (Linux64, MinGw64, MinGw32) to generate a simple binary (using SDL2). The source is a single .c file, so use Automake, Autoconf is too heavy. Hi Valerio: I am sure you cou

Re: [Msys2-users] one Makefile for all

2019-03-13 Thread Valerio Messina via Msys2-users
On 03/12/19 16:26, David Grayson wrote: The INCPATH and LIBPATH variables you have defined are probably redundant: gcc should automatically be searching those directories for header files and libraries already.  (You can run `gcc -print-search-dirs | grep libraries` to see which directories are

Re: [Msys2-users] one Makefile for all

2019-03-13 Thread Alan W. Irwin
On 2019-03-12 12:08+0100 Valerio Messina via Msys2-users wrote: hi, I want to use a single Makefile for three platforms (Linux64, MinGw64, MinGw32) to generate a simple binary (using SDL2). The source is a single .c file, so use Automake, Autoconf is too heavy. Hi Valerio: This is my second

Re: [Msys2-users] one Makefile for all

2019-03-12 Thread David Grayson
The INCPATH and LIBPATH variables you have defined are probably redundant: gcc should automatically be searching those directories for header files and libraries already. (You can run `gcc -print-search-dirs | grep libraries` to see which directories are searched for libraries. You can run `gcc -

Re: [Msys2-users] one Makefile for all

2019-03-12 Thread Vincent Torri
hello with GNU make, maybe this can help you (detection of OS + exemple) : osname := $(shell uname) OS :=$(osname) OS := $(OS:Linux=Unix) # FreeBSD, OpenBSD, NetBSD, MidnightBSD OS := $(OS:%BSD=Unix) OS := $(OS:DragonFlyD=Unix) OS := $(OS:SunOS=Unix) OS := $(OS:MINGW%=Windows) OS := $(OS:MSYS%=Wi

[Msys2-users] one Makefile for all

2019-03-12 Thread Valerio Messina via Msys2-users
hi, I want to use a single Makefile for three platforms (Linux64, MinGw64, MinGw32) to generate a simple binary (using SDL2). The source is a single .c file, so use Automake, Autoconf is too heavy. As now I concentrated the differences only in three variables: INCPATH LIBPATH LDFLAGS that have