LinuxQuestions.org
Review your favorite Linux distribution.
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 09-11-2004, 05:46 AM   #1
Anup Kumar
LQ Newbie
 
Registered: Feb 2004
Posts: 9

Rep: Reputation: 0
Creating Shared objects


I want to make my function .so file. This file will not contain the main ().
I will have different entry points for the other functions using this function.

Im working on opengl.
Please help me out.
 
Old 09-11-2004, 11:45 PM   #2
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 53
you make object files with -fPIC

gcc -c -fPIC mything.c

gcc -shared -fPIC -o mything.so mything.o
 
  


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
/usr/local/lib not searched for shared objects in Redhat/Fedora? Arodef Programming 2 09-23-2005 12:44 AM
Dynamically sized objects in shared memory jtshaw Programming 2 03-16-2005 10:12 AM
any links on linking, loading shared libraries, shared objects. etc? ananthbv Programming 0 02-03-2005 07:47 AM
Creating a shared Library djgerbavore Programming 2 12-28-2004 02:35 PM
g++ missing shared objects pinguwin Linux - Software 0 05-27-2004 08:38 AM

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

All times are GMT -5. The time now is 08:16 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