That's really what I was looking for. Thank you very much for your time!

--------------------------------------------------
From: <dherr...@tentpost.com>
Sent: Tuesday, December 06, 2011 2:05 AM
To: <automake@gnu.org>
Subject: Re: Directions on compiling the right files

    In other words, there will be new .c files that should be compiled
only
for the windows version and some .c files exclusive to the linux version.
    Suppose also I want to specify this at configure-time (e.g.
"./configure" builds linux, "./configure --enable-win32" builds windows).
    I know I can do this on configure.ac, but I don't know, at configure
time, how would I change the Makefile's dependencies for each of these two
builds. Any directions on how to do this (pointing a relatively simple
package that does this also can help a lot) are very well accepted!

Use conditionals.
http://www.gnu.org/software/automake/manual/html_node/Usage-of-Conditionals.html

something like
if COND_WINDOWS
 prog_SOURCES+=win32.c
endif
if COND_LINUX
 prog_SOURCES+=linux.c
endif

- Daniel




Reply via email to