Mail Archives: cygwin/2001/11/19/06:58:28
-----Original Message-----
>From: Mohammad Saleem [mailto:mosa AT enea DOT se]
>Sent: 18 November 2001 11:46
Hiya Mohammad, I can see a couple of things here:
>Even with link I tried with a flag --gc-sections
D'oh, yes, sorry, I should have mentioned that one.
>test.srec: $(OBJ) appcon.o
> $(LD) --gc-sections $(LDFLAGS) $^ mylib.a $(LIBS) -o $@
But you are linking mylib.a as if it were an object file! I think it
needs to be supplied with a -l flag to be treated as a library, does it
not ? Try renaming mylib.a to libmylib.a (ld requires the name to be in
the format libXXXX.a and then you use -lXXXX), and then try using the
ld line in the makefile like
> $(LD) --gc-sections $(LDFLAGS) $^ -lmylib -L. $(LIBS) -o $@
- ie we tell it that we want the library mylib, it knows then to look for
'libmylib.a', and the -L. tells it that the lib may be found in the
current directory.
>********************************************
>compiling appcon.c
>h8300-hitachi-hms-ld: warning: no memory region specified for section `.
>_init'
>h8300-hitachi-hms-ld: warning: no memory region specified for section
>`.configu'
>h8300-hitachi-hms-ld: warning: no memory region specified for section
>`.timerIn'
>*************************************************
This may reflect a problem with the srec format limiting the length of
section name strings, but see if it goes away when you try the new flags.
DaveK
--
Burn your ID card! http://www.optional-identity.org.uk/
Help support the campaign, copy this into your .sig!
**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.
This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.
www.mimesweeper.com
**********************************************************************
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
- Raw text -