From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bart Veer To: larwe@larwe.com Cc: ecos-discuss@sources.redhat.com Subject: Re: [ECOS] Enable thumb interworking? Date: Fri, 09 Feb 2001 10:40:00 -0000 Message-id: <200102091840.f19IeWD26571@sheesh.cambridge.redhat.com> References: <4.3.2.7.2.20010208150039.00b51890@larwe.com> X-SW-Source: 2001-02/msg00154.html >>>>> "Lewin" == Lewin A R W Edwards writes: Lewin> Secondly, why is the ecos/install/lib/target.ld file always Lewin> generated incorrectly by ecosconfig? The spacing is all Lewin> screwed; every word has a carriage return after it. I have Lewin> to copy the linker script from my Windows machine in order Lewin> to link at all. target.ld is not build by ecosconfig, it is built by a custom build step defined in the CDL for the architectural HAL package. For an ARM processor that means the following: /lib/target.ld: /src/arm.ld $(CC) -E -P -Wp,-MD,target.tmp -DEXTRAS=1 -xc $(INCLUDE_PATH) $(CFLAGS) -o $@ $< @echo $@ ": \\" > $(notdir $@).deps @tail +2 target.tmp >> $(notdir $@).deps @echo >> $(notdir $@).deps @rm target.tmp The first command is the important one. Essentially it passes the arm.ld file from the src subdirectory of the ARM architectural HAL package through the C preprocessor. It ends up #include'ing a file provided by the platform HAL which supplies information such as what memory is actually available. If you are seeing spurious carriage returns then either these are generated by the C preprocessor, or some of the files being #include'd contain spurious carriage returns e.g. because they were just copied directly from a Windows box. I have never seen the actual behaviour you describe, so you'll have to investigate further. Problems with the C preprocessor should be reported to the appropriate gcc mailing list. Bart