Index: Makefile.am =================================================================== RCS file: /projects/pgadmin3/Makefile.am,v retrieving revision 1.34 diff -u -r1.34 Makefile.am --- Makefile.am 23 Feb 2005 15:32:51 -0000 1.34 +++ Makefile.am 12 Mar 2005 16:20:26 -0000 @@ -27,4 +27,45 @@ $(top_srcdir)/docs/en_US/*.css $(top_srcdir)/docs/en_US/pgadmin3.hh* \ $(top_srcdir)/docs/en_US/tips.txt - +PgAdminIII.app: + @echo "Building Bundle PgAdminIII.app" + @test -d PgAdminIII.app || $(mkinstalldirs) PgAdminIII.app + @test -d PgAdminIII.app/Contents/MacOS || $(mkinstalldirs) PgAdminIII.app/Contents/MacOS + @test -d PgAdminIII.app/Contents/Resources || $(mkinstalldirs) PgAdminIII.app/Contents/Resources + @test -d PgAdminIII.app/Contents/SharedSupport || $(mkinstalldirs) PgAdminIII.app/Contents/SharedSupport + @test -d PgAdminIII.app/Contents/Frameworks || $(mkinstalldirs) PgAdminIII.app/Contents/Frameworks + @cp pkg/mac/PkgInfo PgAdminIII.app + @cp pkg/mac/Info.plist PgAdminIII.app/Contents + @cp pkg/mac/PgAdminIII.icns PgAdminIII.app/Contents/Resources + @$$(@WX_CONFIG@ --rezflags | sed 's/-t[[:space:]]*APPL//') \ + PgAdminIII.app/Contents/Resources/PgAdminIII.rsrc \ + -useDF + @cp -r $(pkgdatadir)/* PgAdminIII.app/Contents/SharedSupport + @cp -r $(bindir)/pgadmin3 PgAdminIII.app/Contents/MacOS/PgAdminIII + @echo "Adding all non-standard shared libraries to PgAdminIII.app" ; \ + cd PgAdminIII.app/Contents ; \ + todo=MacOS/PgAdminIII ; \ + while test "$$todo" != ""; do \ + todo_old=$$todo ; \ + todo="" ; \ + for todo_obj in $$todo_old; do \ + for lib in $$( \ + otool -L $$todo_obj | \ + sed -n 's|^.*[[:space:]]\([^[:space:]]*\.dylib\).*$$|\1|p' | \ + egrep -v '^(/usr/lib)|(/System)' \ + ); do \ + lib_bn="$$(basename "$$lib")" ;\ + if ! test -f "Frameworks/$$lib_bn"; then \ + cp "$$lib" "Frameworks/$$lib_bn" ; \ + install_name_tool \ + -id "@executable_path/../Frameworks/$$lib_bn" \ + "Frameworks/$$lib_bn" ; \ + todo="$$todo Frameworks/$$lib_bn" ; \ + fi ; \ + install_name_tool -change \ + "$$lib" \ + "@executable_path/../Frameworks/$$lib_bn" \ + "$$todo_obj" ; \ + done ; \ + done ; \ + done ; Index: acinclude.m4 =================================================================== RCS file: /projects/pgadmin3/acinclude.m4,v retrieving revision 1.42 diff -u -r1.42 acinclude.m4 --- acinclude.m4 2 Mar 2005 23:47:23 -0000 1.42 +++ acinclude.m4 12 Mar 2005 16:20:27 -0000 @@ -64,6 +64,18 @@ [pg_static_build=no]) ]) +############################ +# Static build of pgAdmin3 # +############################ +AC_DEFUN([ENABLE_APPBUNDLE], +[AC_ARG_ENABLE(appbundle, +[ --enable-appbundle Build PgAdminIII.app], +[pg_appbundle=yes +prefix=$(pwd)/tmp +], +[pg_appbundle=no]) +]) + ######################################## # Check for PostgreSQL library (libpq) # ######################################## @@ -486,3 +498,5 @@ fi fi ]) +AC_SUBST(WX_CONFIG) + Index: configure.ac =================================================================== RCS file: /projects/pgadmin3/configure.ac,v retrieving revision 1.33 diff -u -r1.33 configure.ac --- configure.ac 29 Nov 2004 21:42:20 -0000 1.33 +++ configure.ac 12 Mar 2005 16:20:27 -0000 @@ -30,6 +30,7 @@ AC_CHECK_FUNCS([gethostbyname inet_ntoa memmove memset strchr]) # Custom checks +ENABLE_APPBUNDLE CHECK_WX_CONFIG_BINARY CHECK_PGSQL_INCLUDE ENABLE_DEBUG