bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GNUmakefile


From: Nicola Pero
Subject: Re: GNUmakefile
Date: Tue, 24 Feb 2009 20:06:12 +0100

You want to use subprojects :-)

Your top level GNUmakefile should look like



include $(GNUSTEP_MAKEFILES)/common.make

LIBRARY_NAME = mylib
mylib_SUBPROJECTS = source1 source2

include $(GNUSTEP_MAKEFILES)/library.make


This will compile a single library, at top level, by linking together the subprojects source1 and
source2.


Then, in source1 you need a GNUmakefile such as the following one:



include $(GNUSTEP_MAKEFILES)/common.make

SUBPROJECT_NAME = source1
source1_C_FILES = file11.c file12.c

include $(GNUSTEP_MAKEFILES)/subproject.make


This will compile the files and link them into a subproject, which is then used by the top-level GNUmakefile.
In source2, you may want to add a similar GNUmakefiles.

Hope this helps! :-)

Let me know if you need more help

Thanks

On 24 Feb 2009, at 19:57, Julien Isorce wrote:

Hi,

I have a project where there is severals source directories: source1, source2, source3
I want to compile the project to make only one shared library.
I have tried to use the following:


in the top directory:
------------------------------------------------------------------------
include $(GNUSTEP_MAKEFILES)/common.make
SUBPROJECTS = source1 source2
include $(GNUSTEP_MAKEFILES)/aggregate.make
------------------------------------------------------------------------


in source1 dir:
------------------------------------------------------------------------
include $(GNUSTEP_MAKEFILES)/common.make

LIBRARY_NAME = libmylib

libmylib_C_FILES = file11.c file12.c

include $(GNUSTEP_MAKEFILES)/library.make
------------------------------------------------------------------------

and in source2:
------------------------------------------------------------------------
include $(GNUSTEP_MAKEFILES)/common.make

LIBRARY_NAME = libmylib

libmylib_C_FILES += file21.c file22.c

include $(GNUSTEP_MAKEFILES)/library.make
------------------------------------------------------------------------


but it does not work.

Any solution ?

Thx

Sincerely

Julien

_______________________________________________
Bug-gnustep mailing list
Bug-gnustep@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnustep





reply via email to

[Prev in Thread] Current Thread [Next in Thread]