From: Joe C. <ch...@tr...> - 2006-09-13 17:11:24
|
Alan W. Irwin wrote: > On 2006-09-12 09:40+0200 Werner Smekal wrote: > >> Hi Joe, >> >> are you using the plplot library within your wxWidgets application (in a >> widget)? >> >> Anyway, as far as I remember the discussions on the wxWidgets mailing >> list, they propose to use the static wxWidgets library for Linux in case >> you want to distribute your program (or you have to fiddle around with >> LD_LIBRARY_PATH to set the path to your copied shared wxWidgets library, >> but this should not be used other than debug purposes actually). You can >> also switch off a lot of libraries you don't need during the configure >> step to reduce dependencies (either like this --without-libtiff or like >> this --with-expat=builtin). >> If wxWidgets is static, plplot must also be static - so you first need >> to recompile/reconfigure wxWidgets to be static (--disable-shared). >> If this doesn't work (I'm not 100% sure about the automake build system >> of plplot) this should be possible with the new cmake build system which >> is already in cvs - a new improved wxwidgets driver will also be >> available soon. The option ENABLE_CXX_MIX allows to introduce the cpp >> wxWidgets driver into the c plplot library. > > To clarify the situation, for the Unix case, our CBS follows the same rules > as our ABS, i.e., the psttf and wxwidgets C++ device drivers are turned off > whenever dynamic devices are disabled. The reason is that the driver > object > code becomes part of the core PLplot C library when dynamic drivers are > disabled, and some Unix platforms cannot handle the resulting mix of C++ > code from those particular device drivers and normal C code from the > remainder of the devices and the PLplot core. (Note disabling shared > libraries automatically disables dynamic drivers, but if shared libraries > are enabled, then the user has the choice of enabling or disabling dynamic > devices.) Our ABS system does not handle the windows case, but our CBS > system does. For CBS on a windows platform we have found experimentally > that you can mix the C++ device driver code into the C library so for that > particular case we allow both psttf and wxwidgets regardless of whether > dynamic devices are enabled or not. But for Unix our CBS is just as strict > on this matter as our ABS. > > So from the above explanation, we are dealing with a fairly tangled thicket > of Boolean logic, but there are practical reasons behind all of it. So, the answer is that if the plplot wxwidgets driver is used within an application, the plplot library must be installed on the target machine? There is no way to distribute a self-contained executable image of an application which uses the wxwidgets driver? There is no way to simply bundle the plplot .so files with the executable image and indicate their location through something like an environment variable? Building the plplot libs, with the wxwidgets driver, requires the target machine to also have the wxwidgets package already installed. So, an app which uses the plplot wxwidgets driver cannot be distributed as an executable image. All I wanted plplot for was its surface plotting capabilities, but this is a huge disadvantage and will force me to look elsewhere for less restrictive and more portable code. Joe Chuma TRIUMF |