help-gplusplus
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to link in shared object?


From: James Egan
Subject: How to link in shared object?
Date: Fri, 15 Apr 2005 23:34:31 -0400
User-agent: Pan/0.14.2.91 (As She Crawled Across the Table)

I'm just beginning to learn C++.  If the test() 
function listed below was in a shared object 
library named mylib.so, how would I access then 
from another .cpp program?  Can someone please 
show me a .cpp example, and then how to link it 
with GNU g++?  I tried to find the answer on google, 
but could not.

-Thanks


#include <iostream>

using namespace std;

void test()
{
  cout << "In test() function" << endl;
}


reply via email to

[Prev in Thread] Current Thread [Next in Thread]