math lib inclusion
Joel Sherrill
joel.sherrill at OARcorp.com
Fri Nov 7 16:48:21 UTC 2008
Neil Mayes wrote:
> All works, many thanks.
>
> Is there a better application makefile template to use?
>
Not yet. The version of these in 4.9 and the
CVS head is cleaner but fundamentally the same.
Chris Johns has done some work converting all
the examples to autotools but I don't know that
he is completely ready.
> Regards,
> Neil
>
>
>> -----Original Message-----
>> From: Joel Sherrill [mailto:joel.sherrill at oarcorp.com]
>> Sent: 07 November 2008 15:55
>> To: Neil Mayes
>> Cc: rtems-users at rtems.org
>> Subject: Re: math lib inclusion
>>
>> Neil Mayes wrote:
>>
>>> Hi all,
>>>
>>> I am trying to get an application running that uses math.h. I
>>> understand I need to supply the math lib which is achieved
>>>
>> by adding
>>
>>> '-lm' to the library list.
>>>
>>> I am using RTEMS4.8.0 and gcc4.2.2 for the sparc (ERC32). I
>>>
>> have based
>>
>>> my application make file from an RTEMS example where there
>>>
>> is the line:
>>
>>> # Libraries
>>> LIBS = -lrtemsall -lc
>>>
>>>
>>>
>> Those are unfortunately relics in these old application
>> Makefiles and aren't even needed since there is no rtemsall
>> library and libc is implicit. I don't think they do anything.
>>
>> Try
>>
>> *LD_LIBS += -lm
>> *
>>
>>> include $(RTEMS_MAKEFILE_PATH)/Makefile.inc
>>> .
>>> .
>>>
>>> Should I just be able to add -lm to LIBS?
>>>
>>> Do I have to build the math library seperately from gcc and
>>>
>> newlib for
>>
>>> the sparc?
>>>
>>> Thanks,
>>> Neil Mayes
>>>
>>> _______________________________________________
>>> rtems-users mailing list
>>> rtems-users at rtems.com
>>> http://rtems.rtems.org/mailman/listinfo/rtems-users
>>>
>>>
>> --
>> Joel Sherrill, Ph.D. Director of Research & Development
>> joel.sherrill at OARcorp.com On-Line Applications Research
>> Ask me about RTEMS: a free RTOS Huntsville AL 35805
>> Support Available (256) 722-9985
>>
>>
>>
>>
--
Joel Sherrill, Ph.D. Director of Research & Development
joel.sherrill at OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (256) 722-9985
More information about the users
mailing list