[QGIS Commit] r8559 - trunk/qgis/mac

svn_qgis at osgeo.org svn_qgis at osgeo.org
Sat May 31 10:30:50 EDT 2008


Author: timlinux
Date: 2008-05-31 10:30:50 -0400 (Sat, 31 May 2008)
New Revision: 8559

Modified:
   trunk/qgis/mac/1-release-extra.sh
   trunk/qgis/mac/2-release-extra-qt.sh
Log:
Updated post build scripts for mac (Tims Version) so that python libs all have proper relative references into bundle for the lib deps.


Modified: trunk/qgis/mac/1-release-extra.sh
===================================================================
--- trunk/qgis/mac/1-release-extra.sh	2008-05-31 13:09:56 UTC (rev 8558)
+++ trunk/qgis/mac/1-release-extra.sh	2008-05-31 14:30:50 UTC (rev 8559)
@@ -2,6 +2,7 @@
 # Copy supportibng libraries (except Qt) to openModeller bundle
 # and make search paths for them relative to bundle
 
+
 APP_PREFIX=/Applications/qgis0.11.0.app
 BUNDLE_DIR=${APP_PREFIX}/Contents/MacOS
 DEPS_BASE=/usr/local/qgis_universal_deps
@@ -30,6 +31,7 @@
 install_name_tool -change ${LIB_DIR}/libproj.dylib \
                    @executable_path/lib/libproj.dylib \
                    ${BUNDLE_DIR}/qgis
+
 set +x
 
 LIBS="lib/libqgis_core.dylib \
@@ -107,6 +109,43 @@
   #echo "----------------------------------"
 done
 
+# Python libs need some special care
+LIBS="share/qgis/python/qgis/core.so
+      share/qgis/python/qgis/gui.so
+      lib/libqgispython.dylib"
+for LIB in $LIBS
+do
+  install_name_tool -id @executable_path/${LIB} ${BUNDLE_DIR}/${LIB}
+  # for debugging only
+  for LIBPATH in `otool -L ${BUNDLE_DIR}/${LIB} \
+                  | sed 's/(\([a-zA-Z0-9\., ]*\))//g' \
+                  | grep  $LIB_DIR \
+                  | grep -v framework` #frameworks (in particular qt frameworks) get
+                                       #dealt with in another script
+  do 
+    #echo "------------"
+    #echo $LIBPATH 
+    #echo "------------"
+    BASELIB=`basename "$LIBPATH"`
+    #echo $BASELIB
+    install_name_tool -change ${LIBPATH} @executable_path/lib/${BASELIB} ${BUNDLE_DIR}/${LIB}
+  done
+  # Change the search path for qgis libs in python libs
+
+  CORELIBPATH=/`otool -L ${BUNDLE_DIR}/${LIB} |grep -o "\b[/A-Za-z0-9]*libqgis_core.[0-9.]*.dylib\b"`
+  CORELIB=`echo "${CORELIBPATH}" | grep -o "libqgis_core.[0-9.]*.dylib"`
+  install_name_tool -change ${CORELIBPATH} @executable_path/lib/${CORELIB} ${BUNDLE_DIR}/${LIB}
+  GUILIBPATH=/`otool -L ${BUNDLE_DIR}/${LIB} |grep -o "\b[/A-Za-z0-9]*libqgis_gui.[0-9.]*.dylib\b"`
+  GUILIB=`echo "${CORELIBPATH}" | grep -o "libqgis_gui.[0-9.]*.dylib"`
+  install_name_tool -change ${GUILIBPATH} @executable_path/lib/${GUILIB} ${BUNDLE_DIR}/${LIB}
+  echo $LIB
+  #otool -L ${BUNDLE_DIR}/lib/qgis/${LIB}
+  #echo "----------------------------------"
+done
+
+
+/Users/timlinux/dev/cpp/qgis/build/src/core/libqgis_core.0.11.dylib
+
 #
 # Strip binaries - disable for debugging
 #

Modified: trunk/qgis/mac/2-release-extra-qt.sh
===================================================================
--- trunk/qgis/mac/2-release-extra-qt.sh	2008-05-31 13:09:56 UTC (rev 8558)
+++ trunk/qgis/mac/2-release-extra-qt.sh	2008-05-31 14:30:50 UTC (rev 8559)
@@ -70,7 +70,10 @@
   lib/qgis/libwmsprovider.so
   lib/qgis/libgpsimporterplugin.so
   lib/qgis/libevis.so
-  lib/qgis/libquickprintplugin.so"
+  lib/qgis/libquickprintplugin.so
+  share/qgis/python/qgis/core.so
+  share/qgis/python/qgis/gui.so
+  lib/libqgispython.dylib"
 for FILE in ${FILES}
 do
  for FRAMEWORK in QtCore QtGui QtNetwork QtSql QtSvg QtXml



More information about the QGIS-commit mailing list