[xsd-users] Building xsd with the eclipse cdt

Boris Kolpackov boris at codesynthesis.com
Fri Jan 22 09:26:15 EST 2010


Hi Monika,

In the future please keep your replies CC'ed to the xsd-users mailing
list as discussed in the posting guidelines:

http://www.codesynthesis.com/support/posting-guidelines.xhtml

Huether, Monika <monika.huether at fkie.fraunhofer.de> writes:

> thank you for your quick answer. Now everything works fine. But when I 
> try to run the project, I return an error: "error while loading shared 
> libraries: libxerces-c-3.0.so: cannot open shared object file: No such 
> file or directory"
> 
> But the library and library path are entered in the properties dialog 
> correctly.

Those paths are for the compiler/linker. Here you are having a problem
running the program. There are multiple ways to address this, listed
from more general to more specific:

1. Add the /opt/xerces-c/lib path to the /etc/ld.so.conf file. This
   will allow you and other users on this computer to run programs 
   linked to Xerces-C++ without any extra action either from a terminal 
   or from Eclipse.

2. Add the /opt/xerces-c/lib path to the LD_LIBRARY_PATH variable in 
   your .bash_login or similar (and re-login):

   export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/xerces-c/lib
 
   This will allow you to run programs linked to Xerces-C++ without 
   any extra action either from a terminal or from Eclipse.

3. Add the /opt/xerces-c/lib path to the LD_LIBRARY_PATH variable in 
   a terminal:

   $ export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/xerces-c/lib

   This will allow you to run programs linked to Xerces-C++ from this
   terminal and from Eclipse if you start it from this terminal.

4. In Eclipse in Project Explorer right-click on the project name and 
   select Properties. Select Run/Debug Settings and either edit an
   existing configuration or create a new one. Select the Environment
   tab and click New. Enter LD_LIBRARY_PATH in the Name field and
   /opt/xerces-c/lib in the Value field. Click Ok, to close all the
   dialogs. This will allow you to run this project from the Eclipse
   IDE only.

Boris



More information about the xsd-users mailing list