Kyng Chaos
“The beast is actively interested only in now, and, as it is always now and always shall be, there is an eternity of time for the accomplishment of objects.”
- the wisdom of Tarzan

Developer Notes

FIXME may be old info here – needs updating

All the Tiger packages are built with GCC 4 on Tiger. The Panther packages are built with GCC 3.3.

Separating these into subfolders in /usr/local has created some issues for using them, since they're not in 'standard' locations. Also, leaving out the static libraries creates problems. Here are some that I've run into and how I deal with them.

• Some dependency checking is done by xxxxx-config binaries (usually scripts) or other executable binaries, in some /bin locations (ie /usr/local/bin). Mapserver checks for nad2bin, from libproj. Normally configure checks in whatever locations are set in your environment PATH. You should add the various framework Programs folders to your PATH if they have useful exectuables, ie /Library/Frameworks/PROJ.framework/Programs.

• The simplest way to deal with this is to check the configure script options. Look for options to explicitly specify library paths for libraries. ie –with-jpeg=/Library/Frameworks/UnixImageIO.framework/unix, or a pair of –with-jpeg-lib=/Library/Frameworks/UnixImageIO.framework/unix/lib –with-jpeg-include=/Library/Frameworks/UnixImageIO.framework/unix/include.

Software I've found that works this way includes libtiff, GDAL, GRASS and PHP (tho there is one library that needs the next method also for PHP).

Sometimes the option is broken, or other library options get in the way.

• Another simple trick is to set environment variables. ie (for bash) export LDFLAGS=-L/Library/Frameworks/UnixImageIO.framework/unix/lib; export CFLAGS=-I/Library/Frameworks/UnixImageIO.framework/unix/include (or CXXFLAGS for C++ builds). This normally puts these options in front of everything else, so it's a good way to fix broken –with options or override other options that might get in the way. If you need to include multiple paths, separate them with spaces and enclose the whole thing in quotes. ie export LDFLAGS="-L/Library/Frameworks/UnixImageIO.framework/unix/lib -L/usr/local/lib".

Stuff that works with this method includes JasPer and GD.

Just be aware that not all configure scripts make use of these environment variables (even though their help says they do).

• Some configure scripts are not very Mac-savvy, or need static libraries installed. They check for the static library (.a), the UNIX/Linux shared library (.so) or the Windows shared library (.dll). You have to look at the config.log to see why things failed and look at configure to figure out what it is doing. Fixing it means patching configure to look for the Mac dynamic library (.dylib) for problem libraries.

Stuff that needs this sort of patch includes geotiff and MapServer.

software/devnotes.txt · Last modified: 2007/11/25 17:23 by kyngchaos
Copyright © 2004-2016 William Kyngesburye Driven by DokuWiki Recent changes RSS feed Valid XHTML 1.0