fp support of newlib based projects?

cancel
Showing results for 
Search instead for 
Did you mean: 

fp support of newlib based projects?

510 Views
mbu2015
Contributor II

Hello,

I have added some dummy floating point code to an example S32DS project.

I have chosen MPC5748G and newlib in the project wizard for core Z4_0.

This is what it tells me while building:

pastedImage_1.png

Do I have to include libm.a manually in the linker script? Where and how exactly?

One of the other cores I configured differently using EWL behaves as expected and obviously knows automatically where to take sqrtf() from.

Do you need the workspace?

Regards

Matthias

Labels (1)
0 Kudos
2 Replies

167 Views
stanish
NXP Employee
NXP Employee

Hi Matthias,

for the newlib project I'd suggest to add libm.a manually since it's not the default Newlib setup.

All you need to add "m" it into Standard S32DS C Linker settings -> Libraries. It appears as -lm  gcc switch and linker interprets it as "libm.a".

pastedImage_3.png

EWL know it automatically since it has been created by NXP whereas newlib is GNU project and we use it as is.

Hope it helps

Stan

0 Kudos

167 Views
mbu2015
Contributor II

Hello Stan,

it's always amazing to see what a single letter at the right location can

do... :smileywink:

Thanks.

Mit freundlichem Gruss

With Best Regards

Matthias Busch

Embedded Solutions 2.4 (TD-S24)

IAV GmbH

Visitors:

Kauffahrtei 25

09120 CHEMNITZ

GERMANY

Postal:

Auer Straße 54

09366 STOLLBERG

GERMANY

Phone: +49 371 23 7 - 3 46 69

Fax: +49 371 23 7 - 3 41 12

E-Mail: <mailto:matthias.busch@iav.de>

Internet: http://www.iav.de

Sitz/Registered Office: Berlin,

Registergericht/Registration Court: Amtsgericht Charlottenburg,

Registernummer/Company Registration Number: HRB 21 280,

Geschäftsführer/Managing Directors: Kurt Blumenröder, Michael Schubert,

Kai-Stefan Linnenkohl

Vorsitzender des Aufsichtsrates/Chairman of the Supervisory Board: Prof.

Dr. Harald Ludanek

Von: stanish <admin@community.nxp.com>

An: Matthias Busch <matthias.busch@iav.de>,

Datum: 23.05.2017 16:39

Betreff: Re: - Re: fp support of

newlib based projects?

NXP Community

Re: fp support of newlib based projects?

reply from Stanislav Sliva in S32 Design Studio - View the full discussion

Hi Matthias,

for the newlib project I'd suggest to add libm.a manually since it's not

the default Newlib setup.

All you need to add "m" it into Standard S32DS C Linker settings ->

Libraries. It appears as -lm gcc switch and linker interprets it as

"libm.a".

https://community.nxp.com/servlet/JiveServlet/downloadImage/2-907937-185314/pastedImage_3.png

EWL know it automatically since it has been created by NXP whereas newlib

is GNU project and we use it as is.

Hope it helps

Stan

Reply to this message by replying to this email, or go to the message on

NXP Community

Start a new discussion in S32 Design Studio by email or at NXP Community

Following Re: fp support of newlib based projects? in these streams: Inbox

This email was sent by NXP Community because you are a registered user.

You may unsubscribe instantly from NXP Community, or adjust email

frequency in your email preferences

0 Kudos