473,503 Members | 1,700 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

undefined symbol + shared object + template

I have not done much programming with template so please excuse my
inexperience. I have function defined in one of the class in this
manner. This function is being showed as an undefined function in the
shared object that we have created. I am getting a link time error that
symbol not found while creating an execuable.

template <Class T> long
ITLDOdbFactory_T<Class Y>::connection_count (const string& db_name)
throw (ITLDOdbConnectException)
{
return queue->connections();
}

I did an nm on the object file of this code and its not there. I don't
know why this happens or what is suppose to happen. I was wondering if
somebody can give me the heads up so that I can then find my way...

tia...

Oct 7 '05 #1
2 2986
kamit wrote:
I have not done much programming with template so please excuse my
inexperience. I have function defined in one of the class in this
manner. This function is being showed as an undefined function in the
shared object that we have created. I am getting a link time error that
symbol not found while creating an execuable.

template <Class T> long
ITLDOdbFactory_T<Class Y>::connection_count (const string& db_name)
throw (ITLDOdbConnectException)
{
return queue->connections();
}

I did an nm on the object file of this code and its not there. I don't
know why this happens or what is suppose to happen. I was wondering if
somebody can give me the heads up so that I can then find my way...

tia...


It's in the FAQ, it's also (I reckon) the single most commonly asked
question in this group.

http://www.parashift.com/c++-faq-lit....html#faq-35.8

john
Oct 7 '05 #2
Thanks john !!

Oct 7 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
11217
by: Stu | last post by:
I am trying to build the xerces shared library with 2.3.0 version of their source code on an AIX 5.1 32 bit machine with the following version of the g++ compiler /usr/local/bin/g++ -v Reading...
2
4426
by: Manuel Maria Diaz Gomez | last post by:
Hi Everybody, maybe you can give me a hint about this. I implemented a simple singleton Factory that will (among other things) keep a registry of objects. Objects register themself in the...
8
4561
by: Scott J. McCaughrin | last post by:
The following program compiles fine but elicits this message from the linker: "undefined reference to VarArray::funct" and thus fails. It seems to behave as if the static data-member:...
3
19230
by: Kenneth Kahl | last post by:
Hello, I would like to call a C++ programm out of Java with help of JNI. By the followed command I created a "shared library": g++ -shared -o libcalculate.so rechner.cpp When I create an...
1
5530
by: yamitmehta | last post by:
When I compile to code using g++arm of VxWorks 5.5 and put it on my board i get the follwing undefined symbols:- Cpool and Csingleton are template classes. CPool has the static member...
1
4890
by: Justin Johnson | last post by:
Hello, I'm trying to build Python 2.5.0 on AIX 5.3 using IBM's compiler (VisualAge C++ Professional / C for AIX Compiler, Version 6). I run configure and make, but makes fails with undefined...
5
10462
by: kp | last post by:
Hi, I am compiling on an AIX 5.1 box and my test machine is AIX 5.3. I run the foll. steps for compiling my test binary "test" /usr/vacpp/bin/xlC test.c -c -o test.o -I/home/jag/progs/include...
5
1731
by: .rhavin grobert | last post by:
Hi group....;-) i have the following class.... _____________________________________________________ // QSharedReg.hpp typedef unsigned __int64 QUAD; using namespace boost;
6
18878
by: tvnaidu | last post by:
opening shared lib with dlopen, gets success, but dlsym returns an error saying undefined symbol, also passing "-rdynamic" during linking this shared lib, any idea?. dlopen success, dlsym gets error,...
0
7278
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7328
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6988
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7456
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5578
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5011
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4672
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3153
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
734
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.