linker problem? <Could not find library ../../../lib/libwx_g

Hello,

I have a strange link problem. The cube application links fine … but
when it runs it is missing
a shared library. That shared library is installed and can be linked
dynamically with other apps.

Armin

touch *.cpp

make

QCC -c -D__WXGTK__ -DGTK_NO_CHECK_CASTS -D_REENTRANT -g -O
2 -shared -I. -I/usr/local/include -I…/…/…/include -I…/…/
…/include -I…/…/…/src/zlib -I…/…/…/src/png -I…/…/…/s
rc/jpeg -I…/…/…/src/tiff -I/usr/local/include/gtk-1.2 -I/us
r/local/include/glib-1.2 -I/usr/local/lib/glib/include -I/usr/
X11R6/include -Wall “-DwxINSTALL_PREFIX=”/usr/local"" -o
cube.o cube.cpp

QCC -Wl,-E -g -o cube cube.o …/…/…/lib/libwx_gtk-2.2.so.6
…1.6 -L/usr/local/lib -L/usr/X11R6/lib -lgtk -lgdk -lgmodule -
lgthread -lglib -lXext -lX11 -lsocket -lm -lGL -lGLU …/…/…
/lib/libwx_gtk_gl.so

cube

Could not find library …/…/…/lib/libwx_gtk-2.2.so.6.1.6 —>
library is installed

Armin <a-steinhoff@web.de> wrote:

Hello,

Hello,

I have a strange link problem. The cube application links fine … but
when it runs it is missing
a shared library. That shared library is installed and can be linked
dynamically with other apps.

Armin

touch *.cpp

make

QCC -c -D__WXGTK__ -DGTK_NO_CHECK_CASTS -D_REENTRANT -g -O
2 -shared -I. -I/usr/local/include -I…/…/…/include -I…/…/
…/include -I…/…/…/src/zlib -I…/…/…/src/png -I…/…/…/s
rc/jpeg -I…/…/…/src/tiff -I/usr/local/include/gtk-1.2 -I/us
r/local/include/glib-1.2 -I/usr/local/lib/glib/include -I/usr/
X11R6/include -Wall “-DwxINSTALL_PREFIX=”/usr/local"" -o
cube.o cube.cpp

QCC -Wl,-E -g -o cube cube.o …/…/…/lib/libwx_gtk-2.2.so.6
.1.6 -L/usr/local/lib -L/usr/X11R6/lib -lgtk -lgdk -lgmodule -
lgthread -lglib -lXext -lX11 -lsocket -lm -lGL -lGLU …/…/…
/lib/libwx_gtk_gl.so

cube

Could not find library …/…/…/lib/libwx_gtk-2.2.so.6.1.6 —
library is installed

specify the full path where your lib is:

ie. /blah/blah/blah/blah/lib/libwx_gtk-2.2.so.6.1.6

Regards,

Marcin

Hello Marcin,

Tools Mail Account wrote:

Armin <> a-steinhoff@web.de> > wrote:

Hello

Hello,

I have a strange link problem. The cube application links fine … but
when it runs it is missing
a shared library. That shared library is installed and can be linked
dynamically with other apps.

Armin

touch *.cpp

make

QCC -c -D__WXGTK__ -DGTK_NO_CHECK_CASTS -D_REENTRANT -g -O
2 -shared -I. -I/usr/local/include -I…/…/…/include -I…/…/
…/include -I…/…/…/src/zlib -I…/…/…/src/png -I…/…/…/s
rc/jpeg -I…/…/…/src/tiff -I/usr/local/include/gtk-1.2 -I/us
r/local/include/glib-1.2 -I/usr/local/lib/glib/include -I/usr/
X11R6/include -Wall “-DwxINSTALL_PREFIX=”/usr/local"" -o
cube.o cube.cpp

QCC -Wl,-E -g -o cube cube.o …/…/…/lib/libwx_gtk-2.2.so.6
.1.6 -L/usr/local/lib -L/usr/X11R6/lib -lgtk -lgdk -lgmodule -
lgthread -lglib -lXext -lX11 -lsocket -lm -lGL -lGLU …/…/…
/lib/libwx_gtk_gl.so

cube

Could not find library …/…/…/lib/libwx_gtk-2.2.so.6.1.6 —
library is installed



specify the full path where your lib is:

ie. /blah/blah/blah/blah/lib/libwx_gtk-2.2.so.6.1.6

the linker has no problem to find the libs with the relative path

… why should the absolute path helpful ??

I have in the meantime replaced the specification with the realtive
path by a standard -lxy
specification … and it works.

However, wxPython works now flawless with OpenGL as a part of the
DACHS software suite.

Armin

http://www.steinhoff-automation.com

a-steinhoff@web.de wrote:

Hello Armin,

Hello Marcin,

Tools Mail Account wrote:

Armin <> a-steinhoff@web.de> > wrote:

Hello

Hello,

I have a strange link problem. The cube application links fine … but
when it runs it is missing
a shared library. That shared library is installed and can be linked
dynamically with other apps.

Armin

touch *.cpp

make

QCC -c -D__WXGTK__ -DGTK_NO_CHECK_CASTS -D_REENTRANT -g -O
2 -shared -I. -I/usr/local/include -I…/…/…/include -I…/…/
…/include -I…/…/…/src/zlib -I…/…/…/src/png -I…/…/…/s
rc/jpeg -I…/…/…/src/tiff -I/usr/local/include/gtk-1.2 -I/us
r/local/include/glib-1.2 -I/usr/local/lib/glib/include -I/usr/
X11R6/include -Wall “-DwxINSTALL_PREFIX=”/usr/local"" -o
cube.o cube.cpp

QCC -Wl,-E -g -o cube cube.o …/…/…/lib/libwx_gtk-2.2.so.6
.1.6 -L/usr/local/lib -L/usr/X11R6/lib -lgtk -lgdk -lgmodule -
lgthread -lglib -lXext -lX11 -lsocket -lm -lGL -lGLU …/…/…
/lib/libwx_gtk_gl.so

cube

Could not find library …/…/…/lib/libwx_gtk-2.2.so.6.1.6 —
library is installed



specify the full path where your lib is:

ie. /blah/blah/blah/blah/lib/libwx_gtk-2.2.so.6.1.6

the linker has no problem to find the libs with the relative path
… why should the absolute path helpful ??

If you perform “objdump -x _YOUR_PROGRAM | grep NEEDED” it is going to
show you “NEEDED …/…/…/lib/libwx_gtk-2.2.so.6.1.6” ,which is
causing the error “Could not find library …/…/…/lib/libwx_gtk-2.2.so.6.1.6”
, by specifying the full path (absolute) there won’t be any problems at the
runtime, unless you move your lib from the hardcoded path.

Best Regards,

Marcin


I have in the meantime replaced the specification with the realtive
path by a standard -lxy
specification … and it works.

However, wxPython works now flawless with OpenGL as a part of the
DACHS software suite.

Armin

http://www.steinhoff-automation.com

Hello Marcin,

[clip ]

when it runs it is missing
a shared library. That shared library is installed and can be linked
dynamically with other apps.

Armin

touch *.cpp

make

QCC -c -D__WXGTK__ -DGTK_NO_CHECK_CASTS -D_REENTRANT -g -O
2 -shared -I. -I/usr/local/include -I…/…/…/include -I…/…/
…/include -I…/…/…/src/zlib -I…/…/…/src/png -I…/…/…/s
rc/jpeg -I…/…/…/src/tiff -I/usr/local/include/gtk-1.2 -I/us
r/local/include/glib-1.2 -I/usr/local/lib/glib/include -I/usr/
X11R6/include -Wall “-DwxINSTALL_PREFIX=”/usr/local"" -o
cube.o cube.cpp

QCC -Wl,-E -g -o cube cube.o …/…/…/lib/libwx_gtk-2.2.so.6
.1.6 -L/usr/local/lib -L/usr/X11R6/lib -lgtk -lgdk -lgmodule -
lgthread -lglib -lXext -lX11 -lsocket -lm -lGL -lGLU …/…/…
/lib/libwx_gtk_gl.so

cube

Could not find library …/…/…/lib/libwx_gtk-2.2.so.6.1.6 —
library is installed



specify the full path where your lib is:

ie. /blah/blah/blah/blah/lib/libwx_gtk-2.2.so.6.1.6


the linker has no problem to find the libs with the relative path
… why should the absolute path helpful ??


If you perform “objdump -x _YOUR_PROGRAM | grep NEEDED” it is going to
show you “NEEDED …/…/…/lib/libwx_gtk-2.2.so.6.1.6” ,which is
causing the error “Could not find library
…/…/…/lib/libwx_gtk-2.2.so.6.1.6”
, by specifying the full path (absolute) there won’t be any problems
at the
runtime, unless you move your lib from the hardcoded path.

Yes … that’s the case. The problem seems to be a problem of the loader.

I have checked all previous compiled, linked and working samples of
wxGTK (wxWindows) and ALL of them have now that problem.

The point is that this problem comes up after installation patch A of
QNX 6.1

Regards

Armin


Best Regards,

Marcin



I have in the meantime replaced the specification with the realtive
path by a standard -lxy
specification … and it works.


However, wxPython works now flawless with OpenGL as a part of the
DACHS software suite.


Armin


http://www.steinhoff-automation.com

\