Generally, both versions of the library are needed if one needs multi architecture building option (e.g. x86_64 native build and i386 backsupport (cross)build for 32-bit installations).
I am building my i386 and x86_64 application on Ubuntu 12.04.3 LTS using -m32 and -m64 gcc options.
But running only 64-bit version of the application locally for the matter.
Hi Andrew.
Generally, both versions of the library are needed if one needs multi architecture building option (e.g. x86_64 native build and i386 backsupport (cross)build for 32-bit installations).
I am building my i386 and x86_64 application on Ubuntu 12.04.3 LTS using -m32 and -m64 gcc options.
But running only 64-bit version of the application locally for the matter.
To accomplish this I have done:
Firstly installed libxml2-dev (x86_64)
sudo apt-get install libxml2-dev
Secondly, move problematic xml2-config xml2-config /usr/bin/ xml2-config. x86_64
sudo mv /usr/bin/
Then install libxml2-dev:i386
sudo apt-get install libxml2-dev:i386
Rename xml2-config for i386 xml2-config /usr/bin/ xml2-config. i386
sudo mv /usr/bin/
Restore x86_64 xml2-config xml2-config. x86_64 /usr/bin/ xml2-config
sudo cp /usr/bin/
Finally, had to call ldconfig to refresh the library paths and gcc builds my application with -m32 and excplicit -m64 (although not needed).
ldconfig reports: x86_64- linux-gnu/ libxml2. so.2 i386-linux- gnu/libxml2. so.2 x86_64- linux-gnu/ libxml2. so
$ ldconfig -p | grep xml2
libxml2.so.2 (libc6,x86-64) => /usr/lib/
libxml2.so.2 (libc6) => /usr/lib/
libxml2.so (libc6,x86-64) => /usr/lib/