- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: Understanding Linker Symbols
Operating System - Linux
1748232
Members
3545
Online
108759
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
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
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- 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
тАО06-18-2007 09:41 AM
тАО06-18-2007 09:41 AM
I'm still unfamiliar with several aspects of HP-UX innerworkings. This may seem trivial but it confuses me.
I am building an .so. In the symbol table it says that symbol IteUtilAppend is an UNDEF in the .dynsym table. In the .o file I am picking up it defines the symbol as _Z13IteUtilAppendPvPPcS0_ as a GLOB.
Sometimes I have symbols that look like this and when I pick them up they look like this in the .so and everything works great, other times it get the situation i'm in where i get all the strange symbology in one and not in the other and it won't.
Obviously I'm doing something wrong and my lack of understanding about what all the jibberish is in the second symbol is the reason. I'm hoping someone can explain what this is and how it works so I can have greater success with my dynamic libraries on HP-UX. My system is 11.23 on IA. I am currently doing 32 bit builds but will move on to 64 bit builds later. I'm using aCC/ld to build my loads.
Thanks,
Fred
I am building an .so. In the symbol table it says that symbol IteUtilAppend is an UNDEF in the .dynsym table. In the .o file I am picking up it defines the symbol as _Z13IteUtilAppendPvPPcS0_ as a GLOB.
Sometimes I have symbols that look like this and when I pick them up they look like this in the .so and everything works great, other times it get the situation i'm in where i get all the strange symbology in one and not in the other and it won't.
Obviously I'm doing something wrong and my lack of understanding about what all the jibberish is in the second symbol is the reason. I'm hoping someone can explain what this is and how it works so I can have greater success with my dynamic libraries on HP-UX. My system is 11.23 on IA. I am currently doing 32 bit builds but will move on to 64 bit builds later. I'm using aCC/ld to build my loads.
Thanks,
Fred
Solved! Go to Solution.
- Tags:
- mangled
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-18-2007 07:01 PM
тАО06-18-2007 07:01 PM
Solution
You may want to use the simplified "nm -px" command and then look at the one letter symbol types.
The above two symbols are completely different.
One is extern "C": IteUtilAppend.
The other is mangled:
$ c++filt _Z13IteUtilAppendPvPPcS0_
IteUtilAppend(void*, char**, char*)
http://docs.hp.com/en/8759/gloss.htm#n
http://docs.hp.com/en/8759/otherlangs.htm#callinghpc
>will move on to 64 bit builds later.
Any reason you will do this? It isn't needed on HP-UX unless you are running out of address space.
The above two symbols are completely different.
One is extern "C": IteUtilAppend.
The other is mangled:
$ c++filt _Z13IteUtilAppendPvPPcS0_
IteUtilAppend(void*, char**, char*)
http://docs.hp.com/en/8759/gloss.htm#n
http://docs.hp.com/en/8759/otherlangs.htm#callinghpc
>will move on to 64 bit builds later.
Any reason you will do this? It isn't needed on HP-UX unless you are running out of address space.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-18-2007 07:24 PM
тАО06-18-2007 07:24 PM
Re: Understanding Linker Symbols
Hi Fred,
I think you are talking about name mangling, which is done by compilers to support features like overloading
If you want to avoid name mangling for your objects you should make the use of extern "C" keyword.
You can also do a bit googling to have more details about name mangling and extern C.
thanks
I think you are talking about name mangling, which is done by compilers to support features like overloading
If you want to avoid name mangling for your objects you should make the use of extern "C" keyword.
You can also do a bit googling to have more details about name mangling and extern C.
thanks
abandon all hope, ye who enter here..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-19-2007 02:35 AM
тАО06-19-2007 02:35 AM
Re: Understanding Linker Symbols
Thanks guys! That made my lightbulb come one. You have taken some of the mystery out of all this for me.
Fred
Fred
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP