views:

71

answers:

1

I would like to create an XPCOM plugin for a XULRunner application that I'm building. Since Mozilla only provides a 32-bit build of the XULRunner SDK I have to link with 32-bit libraries. This means that a lot of libraries need to be built by me.

Relating this I have a few questions:

Can I do a sudo make install for a 32-bit build? Or will it mess up my system?
If I can't do it, then what is the workaround?
My current solution is including the lib dir in the configure command:

CFLAGS=" -arch i386" CCFLAGS=" -arch i386" CXXFLAGS=" -arch i386" LDFLAGS=" -L`pwd`/../libs/gst-plugins-base -L`pwd`/../libs/liboil -arch i386" ./configure

Is this the way to go or are the better alternatives?

+2  A: 

sudo make install will be fine, IF the installation location does not conflict with the system libraries. In order to allow the built binaries to find your libraries, otool and install_name_tool are your friends. For deployment, these will allow you to make everything bundle-relative even if it has been built for a different install location.

Andrew McGregor
+1 for in-bundle deployment, probably always better for custom libraries.
Georg Fritzsche