LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer
User Name
Password
Linux - Embedded & Single-board computer This forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.

Notices

Reply
 
Search this Thread
Old 08-31-2012, 08:06 AM   #1
sumitnegi
LQ Newbie
 
Registered: Aug 2012
Posts: 9

Rep: Reputation: Disabled
how to add libconfig library to embedded platform


Hi all,
Can anyone tell us steps involved to add libconfig library on our embedded platform (Linux 2.6.39.4 running on Power PC -MPC8280 ).

We have already integrated this library on our PC running Ubuntu 11.10 ,but same we are not able to do for embedded Environment.

Any sort of input will be highly appreciated .

Thanks in Advance

Sumit
 
Old 09-02-2012, 01:14 AM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2014, Slack14.1 DebWheezy, +50+ other Linux OS, for test only.
Posts: 13,522

Rep: Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503
1) The easy way : Use a binary libconfig for powerpc :
libconfig8_1.3.2-2_powerpc.deb : libconfig.so.8 -> libconfig.so.8.0.0

http://packages.debian.org/squeeze/libconfig8
> powerpc > http://ftp.de.debian.org/debian/pool...-2_powerpc.deb

Unpack with : ar -x libconfig8_1.3.2-2_powerpc.deb,
and transfer the file libconfig.so.8.0.0 to the embedded unit.
Make the link / links ( e.g. libconfig.so.8, libconfig.so ).


2) Alternatively generate your own version from "libconfig source code"
with a "powerpc tool-chain / cross-compiler" http://crosstool-ng.org/

.
 
Old 09-03-2012, 06:45 AM   #3
sumitnegi
LQ Newbie
 
Registered: Aug 2012
Posts: 9

Original Poster
Rep: Reputation: Disabled
Hi knudfl,

Your reply was a real eye opener . We are able to solve the issue .Thanks for your guidance.

Below are the steps we followed

1)add the required .h file(In our case libconfig.h) to the current working directory
2)add the required .so file(In our case libconfig.so.8 & libconfig.so.8.0.0) to the current working directory
3)powerpc-linux-gcc libconfig.c -o libcon libconfig.so.8 // power pc specific

4)In target board give the following command
export LD_LIBRARY_PATH=/nfs/ramesh/cprograms/libconfig/Installation/libconfig/Examples/libconfig1
5) run the program(libcon)
/nfs/ramesh/cprograms/libconfig/Installation/libconfig/Examples/libconfig1/libcon




Quote:
Originally Posted by knudfl View Post
1) The easy way : Use a binary libconfig for powerpc :
libconfig8_1.3.2-2_powerpc.deb : libconfig.so.8 -> libconfig.so.8.0.0

http://packages.debian.org/squeeze/libconfig8
> powerpc > http://ftp.de.debian.org/debian/pool...-2_powerpc.deb

Unpack with : ar -x libconfig8_1.3.2-2_powerpc.deb,
and transfer the file libconfig.so.8.0.0 to the embedded unit.
Make the link / links ( e.g. libconfig.so.8, libconfig.so ).


2) Alternatively generate your own version from "libconfig source code"
with a "powerpc tool-chain / cross-compiler" http://crosstool-ng.org/

.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Is it possible to add a shared library to a static library ? rupa_123 Linux - Newbie 2 03-24-2012 10:25 AM
Installing SDK on embedded linux platform penguin.linux1 Linux - Newbie 1 06-07-2011 02:21 PM
Serial issues on an embedded Linux platform ljkenny Linux - Software 3 04-18-2009 01:53 AM
Looking for an embedded wireless device platform NedRyerson Linux - Embedded & Single-board computer 2 01-21-2009 11:14 AM
Gui App language for embedded platform? PatM Linux - Software 3 05-10-2008 08:11 PM


All times are GMT -5. The time now is 03:32 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration