- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: How to force linking to symbolic name of the l...
Operating System - HP-UX
1753259
Members
5656
Online
108792
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
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
тАО05-15-2009 08:36 AM
тАО05-15-2009 08:36 AM
How to force linking to symbolic name of the library?
My question is quite simple:
I have to produce binary that will then run in production on different machine (HPUX 11.11, PA-RISC).
I need to link it with oracle libclntsh.sl.
On my development server I can see that libclntsh.sl is symbolic link to libclntsh.sl.8.0.
After linking (with aCC), I can verify with chatr that it is linked as dynamic /opt/oracle8/product/8.1.7/lib/libclntsh.sl.8.0
In production the binary will be installed on machines with oracle v.8 and v.9. I've verified that the same binary runs correctly with libclntsh.sl.8.0 and libclntsh.sl.9.0, as it does simply things - connect and fetch some data from some tables. So I want that binary to be marked that it should be linked simply with libclntsh.sl. How to do this?
To be honest - I'm quite confused. In so many situations I've noticed that the stored libraries are really symbolic links to some specific versions. I found it really elegant way to have a common api (name of the library that is symbolic link) and the implementation (installed version). But how can this be used, when it is not possible to produce the binary that should link against the name of that link?
If I have on the development server link libclntsh.sl -> libclntsh.sl.8.0 and on the production libclntsh.sl -> libclntsh.sl.9.0 this mechanism is useless. My binary will be able to link only against libclntsh.sl.8.0 anyway, so using those links is only fake.
I hope I described my frustration precisely enough. It is quite likely that this problem is commonly known, but I could not find any good reference besides this
https://forums11.itrc.hp.com/service/forums/questionanswer.do?admit=109447626+1242387279181+28353475&threadId=82006
although I've tried to search carefully. If so, if I'm trying to invent the wheel again, I'm sorry.
Quite similar problem I have with OpenSSL, where libcrypto.sl leads to libcrypto.sl.0.9.7 on my development server, but can lead to different places in production.
Thanks in advance for help.
Regards
Adam
I have to produce binary that will then run in production on different machine (HPUX 11.11, PA-RISC).
I need to link it with oracle libclntsh.sl.
On my development server I can see that libclntsh.sl is symbolic link to libclntsh.sl.8.0.
After linking (with aCC), I can verify with chatr that it is linked as dynamic /opt/oracle8/product/8.1.7/lib/libclntsh.sl.8.0
In production the binary will be installed on machines with oracle v.8 and v.9. I've verified that the same binary runs correctly with libclntsh.sl.8.0 and libclntsh.sl.9.0, as it does simply things - connect and fetch some data from some tables. So I want that binary to be marked that it should be linked simply with libclntsh.sl. How to do this?
To be honest - I'm quite confused. In so many situations I've noticed that the stored libraries are really symbolic links to some specific versions. I found it really elegant way to have a common api (name of the library that is symbolic link) and the implementation (installed version). But how can this be used, when it is not possible to produce the binary that should link against the name of that link?
If I have on the development server link libclntsh.sl -> libclntsh.sl.8.0 and on the production libclntsh.sl -> libclntsh.sl.9.0 this mechanism is useless. My binary will be able to link only against libclntsh.sl.8.0 anyway, so using those links is only fake.
I hope I described my frustration precisely enough. It is quite likely that this problem is commonly known, but I could not find any good reference besides this
https://forums11.itrc.hp.com/service/forums/questionanswer.do?admit=109447626+1242387279181+28353475&threadId=82006
although I've tried to search carefully. If so, if I'm trying to invent the wheel again, I'm sorry.
Quite similar problem I have with OpenSSL, where libcrypto.sl leads to libcrypto.sl.0.9.7 on my development server, but can lead to different places in production.
Thanks in advance for help.
Regards
Adam
I do everything perfectly, except from my mistakes
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-15-2009 01:00 PM
тАО05-15-2009 01:00 PM
Re: How to force linking to symbolic name of the library?
>I need to link it with oracle libclntsh.sl.
Oracle has implemented SVR4 shlib versioning and that basically says every libclntsh.sl is binary incompatible with any other.
You can't do what you want and is likely not supported.
You of course, could insert symlink trampolines.
>I hope I described my frustration precisely enough.
You need to talk to Oracle to ask their intentions and compatibility statements.
HP-UX has realized that except for using shlib versioning for the great 10.20 to 11.x divide, to maintain forward binary compatibility, you can't really use shlib versioning.
Oracle has implemented SVR4 shlib versioning and that basically says every libclntsh.sl is binary incompatible with any other.
You can't do what you want and is likely not supported.
You of course, could insert symlink trampolines.
>I hope I described my frustration precisely enough.
You need to talk to Oracle to ask their intentions and compatibility statements.
HP-UX has realized that except for using shlib versioning for the great 10.20 to 11.x divide, to maintain forward binary compatibility, you can't really use shlib versioning.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-22-2009 09:21 AM
тАО05-22-2009 09:21 AM
Re: How to force linking to symbolic name of the library?
Hello Dennis
Thanks for your support in the first place.
However your answer is pretty depressing, as it is confirming the statement that I've suggested: Using symlinks for the shared libraries is only fake. I only wonder that they are still created at all.
If libclntsh.sl.8.0 is not compatible with libclntsh.sl.9.0 and making them separate is action done on purpose, so why and for what reason those symlinks keep on being created?
Of course inserting symlink trampolines is the most irrational thing that can be done in such situation, because if separation is done for some reason, faking that libclntsh.sl.8.0 is libclntsh.sl.9.0 seems to be even worse than using plain libclntsh.sl name.
BTW - Do you have any knowledge about the situation with OpenSSL and libcrypto.sl?
Thanks anyway.
Regards
Adam
Thanks for your support in the first place.
However your answer is pretty depressing, as it is confirming the statement that I've suggested: Using symlinks for the shared libraries is only fake. I only wonder that they are still created at all.
If libclntsh.sl.8.0 is not compatible with libclntsh.sl.9.0 and making them separate is action done on purpose, so why and for what reason those symlinks keep on being created?
Of course inserting symlink trampolines is the most irrational thing that can be done in such situation, because if separation is done for some reason, faking that libclntsh.sl.8.0 is libclntsh.sl.9.0 seems to be even worse than using plain libclntsh.sl name.
BTW - Do you have any knowledge about the situation with OpenSSL and libcrypto.sl?
Thanks anyway.
Regards
Adam
I do everything perfectly, except from my mistakes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-22-2009 02:22 PM
тАО05-22-2009 02:22 PM
Re: How to force linking to symbolic name of the library?
>Using symlinks for the shared libraries is only fake. I only wonder that they are still created at all.
Shlib versioning allows multiple incompatible versions of the product to co-exist.
It does mean that the vendor must continue to supply older versions of the shlibs along with newer versions, so that existing applications continue to work.
If Oracle does this correctly, it shouldn't matter what version you linked with, as long as you used the oldest version.
>Do you have any knowledge about the situation with OpenSSL and libcrypto.sl?
Sorry, no.
Shlib versioning allows multiple incompatible versions of the product to co-exist.
It does mean that the vendor must continue to supply older versions of the shlibs along with newer versions, so that existing applications continue to work.
If Oracle does this correctly, it shouldn't matter what version you linked with, as long as you used the oldest version.
>Do you have any knowledge about the situation with OpenSSL and libcrypto.sl?
Sorry, no.
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