LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 03-18-2010, 05:50 AM   #1
AshishJogeshwar
LQ Newbie
 
Registered: Dec 2009
Posts: 12

Rep: Reputation: 0
Integration of a shared library package with your application environment


Hello

I am currently having an application package which provides some applications.
however API's for the same will be provided by third party.
Currently i am using a dummy functions in my code.
Now i have a release by the third party for the first Api version.
They have given a set of .so libraries.
How do i integrate this with my application?
Also i need an idea in general to how to go ahead with programming in such a development scenario where in it is distribued?

Thanks and Regards,
Ashish
 
Old 03-18-2010, 12:52 PM   #2
PTrenholme
Senior Member
 
Registered: Dec 2004
Location: Olympia, WA, USA
Distribution: Fedora, (K)Ubuntu
Posts: 4,187

Rep: Reputation: 354Reputation: 354Reputation: 354Reputation: 354
The library files, by themselves, are not sufficient. You also need the header file(s) which define the API functions' correct argument syntax (so your compilation can be properly checked), and (usually) the vendor's API documentation.

Then all you need to do is put the so file(s) in either a standard location (e.g., /lib or /lib64) or specify the library location to the linker with a -l or -L. If you're using gcc you could also add the directory in which the so files are located to the LIBRARY_PATH environment variable. See man gcc or info gcc for more details about the compiler options.

About distribution: You first will need a license from the API developer permitting you to distribute, and then either distribute a statically-linked binary, or (if you're doing a FOSS development project) distribute your source code from a source code repository. (www.sourceforge.net is a fairly standard choice for code development and distribution.)
 
Old 03-19-2010, 05:38 AM   #3
AshishJogeshwar
LQ Newbie
 
Registered: Dec 2009
Posts: 12

Original Poster
Rep: Reputation: 0
Hi PTrenholme,

Thanks for the reply. This was really useful.
i would also like to have insight into such a development scenario.
if it doesnt take much effort of yours can you suggest me some site or tutorial where i can see such a way of developing being implemented.
 
Old 03-19-2010, 03:10 PM   #4
PTrenholme
Senior Member
 
Registered: Dec 2004
Location: Olympia, WA, USA
Distribution: Fedora, (K)Ubuntu
Posts: 4,187

Rep: Reputation: 354Reputation: 354Reputation: 354Reputation: 354
Sorry, but I've never done commercial development for any Linux system, so I wouldn't know where to suggest you look. If you're using a propitiatory API, perhaps the API vendor could suggest something. Otherwise, try a Google search.
 
  


Reply



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
ldd reports shared library missing, but library exists on disk athv_gr Linux - Newbie 7 05-13-2009 12:31 PM
gcc link shared library against another shared library qcp Linux - Newbie 1 07-25-2008 11:15 AM
trying to find which package has shared library BashTin Slackware 4 06-12-2007 07:30 AM
LINUX - linking archive (static library) with shared (dynamic) library gurkama Programming 5 03-04-2007 11:11 PM
howto compile bin with my library using all-static and shared linked standart library stpg Programming 4 06-29-2004 04:20 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 06:39 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration