- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: not able to link shared library
Operating System - HP-UX
1753297
Members
7204
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
тАО08-14-2008 02:46 AM
тАО08-14-2008 02:46 AM
not able to link shared library
Hi,
We are using nmake utility to compile and build our application (on hp-ux 11.23 IPF).
We are trying to link third party software SHARED libraries (TUXEDO) to build our application.
Please find the nmake file we are using below
In the nmake file the -lutrace (lbutrace.sl) is the TUXEDO shared library which we are trying to link. Runtime it is failing ( saying library not found).
But if we use the while path like /opt/tuxedo/tuxedo9.1/lib/libutrace.sl instead of -lutrace it works.
Is there any flag that can be used to link shared libraries?. The same nmake file works fine in hp-ux 11.0 PA machine
=============================================
.SOURCE.C : .
.SOURCE.h : ../../../../../../develop/mis/src/include \
../../../../../../develop/include \
/opt/tuxedo/tuxedo9.1/include \
$(VROOT)/develop/mis/src/lib/SC/SCincl \
/appdev/mis/misdev/sushant/perfmon_temp/inc \
$(TUXDIR)/include
.SOURCE.a : ../../../../../../develop/lib \
../../../../../../lib \
$(VROOT)/develop/mis/src/lib/SC \
/appdev/mis/misdev/ccp2/userprofile.PB148/lib/prod_up
.SOURCE.sl : $(VROOT)/develop/lib \
/opt/tuxedo/tuxedo9.1/lib
/* --------------- Default Variables --------------- */
if "$(PURIFY)" == "ON"
CC = purify /opt/aCC/bin/aCC
TARGET = mistop.cgi.purify
else
CC = /opt/aCC/bin/aCC
TARGET = mistop.cgi
end
INSTALL_DIR = ../../../../../../develop/cgi-bin
CFILES1 = \
mistop.C
OFILES1 = $(CFILES1:C|\.C|\.o)
LIBS = \
-lutrace \
-lSC++
implicit_template_definition_warning=
CCFLAGS = \
-g0 -mt +DD64 -DOS_UNIX_HP -DMIS_T3 -v -Wl,+s \
$(CFLAGS) -Wl,+s -L/opt/tuxedo/tuxedo9.1/lib -W,L/usr/lib/hpux64
incdirs = $(VPATH:/:/ /G:X=$(VOFFSET):X=$(*.SOURCE.h))
uniqdirs = $(incdirs:I=$(incdirs))
Ioptions = $(VPATH:?$(uniqdirs:/^/-I/G)?$(*.SOURCE.h:/^/-I/G)?)
LDFLAGS = \
$(Ioptions) -I- $(Ioptions)
/* --------------- Assertions --------------- */
.ERROR : .MAKE
error 3 Make of $(TARGET) failed.
finish : start $(INSTALL_DIR)/$(TARGET)
:
: +++++ $(TARGET) installed in $(INSTALL_DIR) +++++
:
start :
:
: ----- Attempting to make $(TARGET) -----
:
$(INSTALL_DIR)/$(TARGET) : $(OFILES1) $(LIBS)
rm -f $(<)
CC="$(CC)" CFLAGS="$(CCFLAGS) $(Ioptions)" LDFLAGS="$(LDFLAGS)" buildclient -v -o $(INSTALL_DIR)/$(TARGET) -f "$(*)" -l "
-Wl,-L../../../../../../develop/lib -Wl,-L../../../../../../lib -Wl,-L$(VROOT)/develop/mis/src/lib/SC -Wl,-L/appdev/mis/misdev
/ccp2/userprofile.PB148/lib/prod_up -Wl,+s -L/$(TUXDIR)/lib, -Wl,-L/usr/lib/hpux64 $(LIBS)"
if [ ! -x $(<) ]
then
exit 1
fi
==========================================
We are using nmake utility to compile and build our application (on hp-ux 11.23 IPF).
We are trying to link third party software SHARED libraries (TUXEDO) to build our application.
Please find the nmake file we are using below
In the nmake file the -lutrace (lbutrace.sl) is the TUXEDO shared library which we are trying to link. Runtime it is failing ( saying library not found).
But if we use the while path like /opt/tuxedo/tuxedo9.1/lib/libutrace.sl instead of -lutrace it works.
Is there any flag that can be used to link shared libraries?. The same nmake file works fine in hp-ux 11.0 PA machine
=============================================
.SOURCE.C : .
.SOURCE.h : ../../../../../../develop/mis/src/include \
../../../../../../develop/include \
/opt/tuxedo/tuxedo9.1/include \
$(VROOT)/develop/mis/src/lib/SC/SCincl \
/appdev/mis/misdev/sushant/perfmon_temp/inc \
$(TUXDIR)/include
.SOURCE.a : ../../../../../../develop/lib \
../../../../../../lib \
$(VROOT)/develop/mis/src/lib/SC \
/appdev/mis/misdev/ccp2/userprofile.PB148/lib/prod_up
.SOURCE.sl : $(VROOT)/develop/lib \
/opt/tuxedo/tuxedo9.1/lib
/* --------------- Default Variables --------------- */
if "$(PURIFY)" == "ON"
CC = purify /opt/aCC/bin/aCC
TARGET = mistop.cgi.purify
else
CC = /opt/aCC/bin/aCC
TARGET = mistop.cgi
end
INSTALL_DIR = ../../../../../../develop/cgi-bin
CFILES1 = \
mistop.C
OFILES1 = $(CFILES1:C|\.C|\.o)
LIBS = \
-lutrace \
-lSC++
implicit_template_definition_warning=
CCFLAGS = \
-g0 -mt +DD64 -DOS_UNIX_HP -DMIS_T3 -v -Wl,+s \
$(CFLAGS) -Wl,+s -L/opt/tuxedo/tuxedo9.1/lib -W,L/usr/lib/hpux64
incdirs = $(VPATH:/:/ /G:X=$(VOFFSET):X=$(*.SOURCE.h))
uniqdirs = $(incdirs:I=$(incdirs))
Ioptions = $(VPATH:?$(uniqdirs:/^/-I/G)?$(*.SOURCE.h:/^/-I/G)?)
LDFLAGS = \
$(Ioptions) -I- $(Ioptions)
/* --------------- Assertions --------------- */
.ERROR : .MAKE
error 3 Make of $(TARGET) failed.
finish : start $(INSTALL_DIR)/$(TARGET)
:
: +++++ $(TARGET) installed in $(INSTALL_DIR) +++++
:
start :
:
: ----- Attempting to make $(TARGET) -----
:
$(INSTALL_DIR)/$(TARGET) : $(OFILES1) $(LIBS)
rm -f $(<)
CC="$(CC)" CFLAGS="$(CCFLAGS) $(Ioptions)" LDFLAGS="$(LDFLAGS)" buildclient -v -o $(INSTALL_DIR)/$(TARGET) -f "$(*)" -l "
-Wl,-L../../../../../../develop/lib -Wl,-L../../../../../../lib -Wl,-L$(VROOT)/develop/mis/src/lib/SC -Wl,-L/appdev/mis/misdev
/ccp2/userprofile.PB148/lib/prod_up -Wl,+s -L/$(TUXDIR)/lib, -Wl,-L/usr/lib/hpux64 $(LIBS)"
if [ ! -x $(<) ]
then
exit 1
fi
==========================================
- Tags:
- shlib
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-14-2008 04:57 AM
тАО08-14-2008 04:57 AM
Re: not able to link shared library
Shalom,
Check the SHLIB_PATH variable.
Make sure the required library is the first one found on that path.
SEP
Check the SHLIB_PATH variable.
Make sure the required library is the first one found on that path.
SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-14-2008 05:32 PM
тАО08-14-2008 05:32 PM
Re: not able to link shared library
It would be helpful if you didn't show us your makefile but only the actual link line.
For dld the paths with -L are also used at runtime. You can change this by using LD_LIBRARY_PATH or SHLIB_PATH. You can also embed the path with -Wl,+b,paths.
For dld the paths with -L are also used at runtime. You can change this by using LD_LIBRARY_PATH or SHLIB_PATH. You can also embed the path with -Wl,+b,paths.
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