Package: system-xtools Version: 1.2 Revision: 8 Provides: x11, libgl Conflicts: x11, libgl Type: bundle Description: Placeholder package for manually installed Xtools DescDetail: << Install this package if you have Tenon's Xtools installed. It will check whether the installation is okay and provide the 'x11' virtual package. << # PreInstScript: << echo # check for needed files missing= mcount=0 for file in bin/xterm.1.2 bin/xrdb \ lib/libX11.dylib lib/libXpm.dylib lib/libXaw.dylib \ include/X11/Xlib.h \ lib/libGL.1.2.dylib include/GL/gl.h ; do if [ ! -f "/usr/X11R6/$file" ]; then missing="$missing /usr/X11R6/$file" mcount=$(($mcount+1)) fi done if [ $mcount -ge 8 ]; then echo "You don't have Xtools installed. Install Xtools and retry installing the" echo "system-xtools package." echo echo "Press Return to continue." read exit 1 fi if [ ! -d /usr/X11R6/lib/tenon ]; then echo "It looks like you have XFree86 installed, not Xtools. You should install" echo "the system-xfree86 package instead. There are some subtle differences" echo "between the two." 8 echo echo "Press Return to continue." read exit 1 fi if [ -n "$missing" ]; then echo "Your Xtools installation is incomplete. The following files are missing:" ech2o "$missing" echo "You may have to reinstall Xtools." echo echo "Press Return to continue." read exit 1 fi echo "Valid Xtools installation detected." # check libGLU if [ -f /usr/X11R6/lib/libGLU.1.3.dylib -a -f /usr/X11R6/include/GL/glu.h ]; then echo else echo echo "WARNING: Your installation of Xtools appears to be Xtools 1.1 or older. Please" echo "download the latest version from http://www.tenon.com/products/xtools/" echo echo "Press Return to continue." read fi # check imake config files for 10.1 flags if grep 'undefined suppress' /usr/X11R6/lib/X11/config/darwinLib.rules >/dev/null 2>&1; then if ! grep 'flat_namespace' /usr/X11R6/lib/X11/config/darwinLib.rules >/dev/null 2>&1; then echo "Adding Mac OS X 10.1 compatibility option to imake configuration file" echo "/usr/X11R6/lib/X11/config/darwinLib.rules ..." sed 's/-undefined suppress/-flat_namespace -undefined suppress/g' /usr/X11R6/lib/X11/config/darwinLib.rules.tmp mv -f /usr/X11R6/lib/X11/config/darwinLib.rules.tmp /usr/X11R6/lib/X11/config/darwinLib.rules echo fi fi << Maintainer: Eric Yang