Re: [gtk-list] Makefiles
- From: Erik Mouw <J A K Mouw its tudelft nl>
- To: gtk-list redhat com
- Subject: Re: [gtk-list] Makefiles
- Date: Wed, 2 Feb 2000 19:14:13 +0100 (MET)
On Wed, 02 Feb 2000 17:45:29 +0000 (GMT), Phil Huish <se96ph> wrote:
> I've got my main file in my main source directory,
> this directory has a directory for the GTK frontend files and a directory
> for the files that deal with the inside of the game...
> how do i write a makefile that understands this...
The difficult answer: In the main Make, use this for target "all:"
$MAKE -C subdir1 all
$MAKE -C subdir2 all
This assumes that you use GNU make. If you don't, use:
(cd subdir1 ; make all)
(cd subdir2 ; make all)
The easy answer: use automake + autoconf to handle your Makefiles. With
automake, it's just a matter of using the SUBDIRS variable in the main
SUBDIRS = subdir1 subdir2
and all your subdirectories will be visited by make.
J.A.K. (Erik) Mouw, Information and Communication Theory Group, Department
of Electrical Engineering, Faculty of Information Technology and Systems,
Delft University of Technology, PO BOX 5031, 2600 GA Delft, The Netherlands
Phone: +31-15-2785859 Fax: +31-15-2781843 Email J.A.K.Mouw@its.tudelft.nl
] [Thread Prev