TOP
SSV SOFTWARE SYSTEMS REGISTER  REGISTER
Log in to check your private messages  Log in to check your private messages
START FAQ SEARCH MITGLIEDER PROFILE  Log in 
SSV-Forum
compilation error

 
Post new topic   Reply to topic    SSV-Forum Forum Index >>> DNP/9200
<<< Previous topic - Next topic >>>  
Display posts from previous:   
Author Message
sandsfr



Joined: 03 Dec 2008
Posts: 1

PostPosted: 04.12.2008, 14:23    Post subject: compilation error Reply with quote

hi every body

is someone could help me to solve my follwing problem :

i try to build a simple exemple with call to mathematical functions.

i solve problem concerning build and link but each time i execute my progam, i have the follwing error message :

[root@emblinux guest]$essai
essai: error in loading shared libraries: /lib/libm.so.6: symbol __register_fra
me_info, version GLIBC_2.0 not defined in file libc.so.6 with link time referenc
e

i compile and build on coLinux (ubuntu)
my commande line is
Export PATH=/usr/local/arm-ssv1-linux/bin:$PATH
arm-ssv1-linux-gcc -Wall -O2 -Wl,-s -lm -o essai essai.c

i copy the /usr/local/arm-ssv1-linux/sysroot/lib/libm.so.6 into DNP/9200 into directory /lib


My essai.c program is :
#include <stdio.h>
#include <stdlib.h>
#include <math.h>

int main()
{
printf ("test sur cible : racine de 4 = %f", sqrt(4.0));

return (0);
}

for infomation :
i have :
* windows XP SP3
* coLinux and ubuntu
* the DNP/SK25 Embedded Linux Start Kit
* the DNP/9200


best regards[/code]
Back to top
View user's profile Send private message
hne



Joined: 11 Jul 2008
Posts: 208
Location: Hannover

PostPosted: 09.12.2008, 11:54    Post subject: Reply with quote

Hello sandsfr,

first check the current kernel version on DNP/9200 with uname -r on your Telnet console.

for kernel 2.6.16.20:

  1. Run the compiler with:
    Code:
    export PATH=/usr/local/arm-ssv1-linux/bin:$PATH
    arm-ssv1-linux-gcc -Wall -O2 -Wl,-s -lm -o essai essai.c

  2. Copy the file /usr/local/arm-ssv1-linux/sysroot/lib/libm-2.3.5.so to DNP and store it as /flash/libm.so.6
  3. Copy the file "essai" into directory /flash on DNP/9200
  4. Make the file executable with "chmod +x /flash/essai"
  5. Run the program on DNP/9200 with
    Code:
    LD_LIBRARY_PATH=/flash /flash/essai


for kernel 2.4.27:

  1. Run the compiler with:
    Code:
    export PATH=/usr/local/arm-linux/bin:$PATH
    arm-linux-gcc -Wall -O2 -Wl,-s -lm -o essai essai.c

  2. Copy the file /usr/local/arm-linux/arm-linux/lib/libm-2.1.3.so to DNP and store it as /flash/libm.so.6
  3. Copy the file "essai" into directory /flash on DNP/9200
  4. Make the file executable with "chmod +x /flash/essai"
  5. Run the program on DNP/9200 with
    Code:
    LD_LIBRARY_PATH=/flash /flash/essai


_________________
Henry Nestler
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    SSV-Forum Forum Index >>> DNP/9200 All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

SSV SOFTWARE SYSTEMS

Dünenweg 5
30419 Hannover

Fon: +49(0)511  ·  40 000-0
Fax: +49(0)511  ·  40 000-40

sales@ssv-embedded.de


Impressum    ·    Datenschutz    ·    AGB

© 2024 SSV SOFTWARE SYSTEMS GmbH. Alle Rechte vorbehalten.

ISO 9001:2015