I have an automake question. Any help is appreciated.

Suppose I have a C source tree like this:

 src/game.c
 src/utils/util.c
 src/gfx/gfx.c

and I need to compile "game", which simply contains all the .c files as objects.

I could simply put

 bin_PROGRAMS = game
 game_SOURCES = game.c utils/util.c gfx/gfx.c

in my src/Makefile.am, but what I really want is to be able to have a Makefile 
in each subdirectory (that compiles the .o file in their respective subdir), 
and a recursive Makefile in src/ that takes the all objects, and compiles game.

Is there any way to do this (elegantly)?

Thanks in advance,
Ian.
-- 
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html

Reply via email to