wxWidgets loading shared library problem

This is a discussion on wxWidgets loading shared library problem within the Linux Programming forums, part of the Platform Specific Boards category; My environment consists of the following: GTK+ 2.8 wxWidgets 2.6.3 The following compile/link does not generate any errors: g++ test.cpp ...

  1. #1
    Registered User
    Join Date
    Mar 2005
    Location
    Mountaintop, Pa
    Posts
    1,059

    wxWidgets loading shared library problem

    My environment consists of the following:
    GTK+ 2.8
    wxWidgets 2.6.3

    The following compile/link does not generate any errors:

    g++ test.cpp `wx-config --libs --cxxflags` -o testit

    But when I execute it I get the following message:

    ./testit: error while loading shared libraries: libw_gtk2_xrc-2.6.so.0:
    Cannot open shared object file: No such file or directory

    Can anybody tell me what I'm doing wrong?

    Thanx
    Last edited by BobS0327; 05-09-2006 at 07:41 PM. Reason: typo

  2. #2
    Registered User
    Join Date
    Mar 2005
    Location
    Mountaintop, Pa
    Posts
    1,059
    Found an awkward solution to my problem in the wxWidgets docs:

    LD_LIBRARY_PATH=/usr/local/lib ./testit

    After reading some internet documentation on LD_LIBRARY_PATH, it appears that setting this variable globally is NOT a good idea. Can anybody suggest any alternatives to using the LD_LIBARARY_PATH variable?

    Thanx

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Problem with linked list and shared memory
    By Sirfabius in forum C Programming
    Replies: 10
    Last Post: 11-10-2008, 04:45 PM
  2. strange linking error -- can not find shared library
    By George2 in forum C Programming
    Replies: 2
    Last Post: 07-10-2006, 11:51 PM
  3. Shared Library creation tips
    By ezwise in forum C Programming
    Replies: 6
    Last Post: 03-01-2005, 03:29 PM
  4. Shared Library
    By Kinasz in forum Linux Programming
    Replies: 5
    Last Post: 10-07-2002, 10:25 AM
  5. Win32 API - Dynamic Link Library Loading - behind the scenes
    By Unregistered in forum Windows Programming
    Replies: 2
    Last Post: 04-05-2002, 08:31 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21