[ECOS] Re: EXEEXT settable in generated buildtree, via CDL ??

John Dallaway jld@ecoscentric.com
Fri Nov 26 22:11:00 GMT 2004


Andrew Lunn wrote:

> On Fri, Nov 26, 2004 at 02:51:37AM -0800, sandeep wrote:
> 
>>>If you look at the tail of the root makefile you will 
>>>see something like:
>>>
>>>$(PREFIX)/include/pkgconf/ecos.mak: makefile
>>>        @echo 'ECOS_GLOBAL_CFLAGS = -Wall
>>>-Wpointer-arith -Wstrict-prototypes -Winline -Wundef
>>>-Woverloaded-virtual -g -O2 -ffunction-sections
>>>-fdata-sections -fno-rtti -fno-exceptions
>>
>>-fvtable-gc -finit-priority' > $@
>>
>>>        @echo 'ECOS_GLOBAL_LDFLAGS = -g -nostdlib
>>>-Wl,--gc-sections -Wl,-static' >> $@
>>>        @echo 'ECOS_COMMAND_PREFIX =
>>>$(COMMAND_PREFIX)' >> $@
>>
>>i have seen this earlier also, but i haven't seen
>>ecos.mak included by subdirectory makefiles in
>>buildtrees generated by ecosconfig versions 1.3.net or
>>2.0b1 (on win2K), though ecos.mak gets generated
>>during make. i cross-checked this fact with both the
>>versions before sending this mail.
> 
> True. I made a mistake here, jumping to conclusions without
> checking. That seemed the logical purpose of this section of code but
> in fact it seems not to be used. Instead each makefile gets its own
> copy of these definitions.

The ecos.mak file is generated solely to assist application developers 
in using the correct build flags. ecos.mak is not referenced when 
building the eCos library.

> We need some import from the designers of the build system. How should
> this work...

In the original version of the makefile generation code, each of the 
package makefiles inherited the environment defined at the top of the 
master makefile. The environment definitions were added to the top of 
each package makefile some time later to allow system-level developers 
to rebuild individual packages by calling a package makefile directly.

Back to the original topic. sandeep wrote:

> many months back, i had made a minor addition in
> pkgconf/rules.mak
> 
>>> export EXEEXT := $(EXEEXT)
> 
> could this be a trivial patch, if useful??

I don't think that being able to change the executable suffix is 
generally useful. One of the things we tried to avoid when designing the 
eCos makefiles was the potential for environment variables intended for 
native compilation affecting eCos builds. In this respect, it might be 
preferable to use:

    export EXEEXT := $(ECOS_EXEEXT)

It would be trivial to modify the sources and emit this line in a 
customised build of the eCos host tools.

John Dallaway
eCosCentric Limited

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss



More information about the Ecos-discuss mailing list