Ok, I found out how to change the Makefile in order to change the name of the 
library to libxerces-c.so, but that still doen't work. When I try to run the 
programs, they still search for libxerces-c.so.27.

So putting it simple: How can I avoid this? When I run the programs that use 
Xerces' library, I want them to search for libxerces-c.so, not 
libxerces-c.so.27...

Thanks!

Rafael

-----Original Message-----
From: Rafael Sousa (Ext_Altior) 
Sent: segunda-feira, 21 de Novembro de 2005 11:15
To: [email protected]
Subject: RE: Can the Makefile be changed to compile directly only one library 
named libxerces-c.so ?


Hi Dave!

Thanks for your help, but I changed the LD_SONAME variable in Makefile.incl as 
you suggested, and the result is the same: the library name is 
libxerces-c.so.27.0, and there are 2 symbolic links that point to this one, 
named libxerces-c.so.27 and libxerces-c.so.

The problem is that when I try to run a program, it keeps asking me for 
libxerces-c.so.27. And it's not very convenient to create the links, in my 
particular case. What I need is to be able to distribute xerces in the 
production system as a standalone library, without the links.

So what (I think) I need is that when compiling the resulting library name is 
libxerces-c.so, so that I can compile the programs using -lxerces-c, and be 
able to run them, without any symbolic link. I'm hoping that this way when I 
try to run the programs, they won't search for libxerces-c.so.27...

Any more ideas anyone?

Thanks again,

Rafael
 

-----Original Message-----
From: David Bertoni [mailto:[EMAIL PROTECTED] 
Sent: sábado, 19 de Novembro de 2005 2:17
To: [email protected]
Subject: Re: Can the Makefile be changed to compile directly only one library 
named libxerces-c.so ?

Rafael Sousa (Ext_Altior) wrote:
> Hi David!
> 
> But do you think that changing the Makefiles by hand so that the
> resulting lib is directly named libxerces-c.so, and not
> libxerces-c.so.27.0, will solve my problem, i.e., I will no longer get
> these kind of errors that ask for libxerces-c.so.27 ?
> 
> By the way, my platform is Solaris.
> 

It's probably easier for you to just modify the Solaris-specifc section 
of src/xercesc/Makefile.incl to modify the LD_SONAME variable.  You can 
change the following:

   LD_SONAME = -h ${SO_NAME}

to:

   LD_SONAME = -h libxerces-c.so

Note that you should be very careful about doing this is you plan to 
distribute your binary, or you expect it to work correctly on a system 
that has multiple versions of Xerces-C on it.

Dave

-----Original Message-----
From: David Bertoni [mailto:[EMAIL PROTECTED] 
Sent: sexta-feira, 18 de Novembro de 2005 23:40
To: [email protected]
Subject: Re: Can the Makefile be changed to compile directly only one
library named libxerces-c.so ?

Rafael Sousa (Ext_Altior) wrote:
> Hi all!
>  
> How can I change the name of the library that results from compiling
> Xerces?

You will probably have to modify the Makefiles by hand.

>  
> When I compile Xerces, I get a library named libxerces-c.so.27.0, and
2
> symbolic links referencing this library, named libxerces-c.so.27 and
> libxerces-c.so. But why is this? Can't I just compile it directly to a
> library named libxerces-c.so ?

You don't state your platform, but this is a very typical naming scheme 
for ELF executables.

>  
> This question might seem strange, but apparently just renaming the
file
> (from libxerces-c.so.27.0 to libxerces-c.so.27), isn't enough. When I
> try to run a program that references the renamed libxerces-c.so (whose
> makefile has -lxerces-c), I'm getting errors that ask for
> libxerces-c.so.27...

No, because the SONAME "libxerces-c.so.27" is embedded in the 
executable.  I believe this is changing for 3.0, but I'm not sure what 
the state of that branch is.

Dave



Reply via email to