- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Linking problem
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-30-2009 10:36 PM
01-30-2009 10:36 PM
I am trying to make binary for using some library but getting linking error.
command:
/opt/aCC/bin/aCC -I. +test.c -L/usr/lib/ -L/opt/OC/lib/hpux32/ -l M3UAOamAPIWBB.
=======
o/p:
/usr/ccs/bin/ld -z -o a.out -u___exit -umain -L/opt/aCC/lib/hpux32 test.o -L /usr/lib/ -L /opt/OC/lib/hpux32/ -lTTL -lM3UAOamAPIWBB -lstd_v2 -lCsup -lpthread -lm -lunwind -lCsup -lc -ldl >/var/tmp/AAAa18375 2>&1
/opt/aCC/bin/c++filt &2
ld: Unsatisfied symbol "M3UA_oamcmd(int,int,timeval*,void*,M3uaOamObject,int*,M3uaOamCmd,M3uaCmdParms*)" in file test.o
1 errors.
removing /var/tmp/AAAa18375
=======
I checked that may be function is not defind in that library so I am geeting error.
so I checked that library file and found:
when i use nm comand for finding this procedure in /opt/OC/lib/hpux32/ and found
bash-2.05b# nm *.so|grep M3UA_oamcmd
nm: libTTLIntf.so: cannot open
[265] | 67635600| 8528|FUNC |GLOB |0| .text|M3UA_oamcmd
[265] | 67635600| 8528|FUNC |GLOB |0| .text|M3UA_oamcmd
[265] | 67635600| 8528|FUNC |GLOB |0| .text|M3UA_oamcmd
[265] | 67635600| 8528|FUNC |GLOB |0| .text|M3UA_oamcmd
bash-2.05b#
When function def is present why in linking it is throwing error.
Expert ant comments on ??
TIA
-Amit
Solved! Go to Solution.
- Tags:
- unsat
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-30-2009 11:42 PM
01-30-2009 11:42 PM
Re: Linking problem
Remove this. There should be NO IPF shlibs in this path. This is for PA32 only.
>ld: Unsatisfied symbol M3UA_oamcmd(int,int,timeval*,void*,M3uaOamObject,int*,M3uaOamCmd,M3uaCmdParms*)
This is a C++ mangled name.
>FUNC |GLOB |0| .text|M3UA_oamcmd
This is a C name.
>When function def is present why in linking it is throwing error?
If your definition is C, you must declare it as:
extern "C" void? M3UA_oamcmd(int,int,timeval*,void*,M3uaOamObject,int*,M3uaOamCmd,M3uaCmdParms*)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2009 01:30 AM
01-31-2009 01:30 AM
Re: Linking problem
Thanks
But I am not getting this
========
If your definition is C, you must declare it as:
extern "C" void? M3UA_oamcmd(int,int,timeval*,void*,M3uaOamObject,int*,M3uaOamCmd,M3uaCmd
Parms*)
===============================
Please clarified more.
And one more thing both the thing is provied by HP, Is any work around to make binary in this case.I ha.ve to use this system call but i can not able to make binary
Regard,
Amit
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2009 01:38 AM
01-31-2009 01:38 AM
Solution(This should now be obvious and a light should have appeared above your head. :-)
========
If your definition is C, you must declare it as:
extern "C" void? M3UA_oamcmd(int, int, timeval*, void*, M3uaOamObject, int*, M3uaOamCmd, M3uaCmdParms*)
===============================
>Please clarified more.
What language is M3UA_oamcmd written?
test.o is in C++. If you want C++ to call C, you must declare the functions, types and data in an extern "C" block. (Or use extern "C" before each function.)
>the thing is provided by HP, Is any work around to make binary in this case. I have to use this system call but i can not able to make binary
Where is your header that declares M3UA_oamcmd? You need to edit it (C++ify it.)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2009 10:33 PM
01-31-2009 10:33 PM
Re: Linking problem
Resloved issue.
-Amit
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2009 10:35 PM
01-31-2009 10:35 PM