+2005-09-28 Helge Hess <helge.hess@opengroupware.org>
+
+ * make-osxpkg.sh, make-osxmpkg.sh: fixed some pkg build issues
+
2005-08-21 Helge Hess <helge.hess@opengroupware.org>
* added files required to build an OSX package
RM_R="rm -r"
+# ****************************** options ******************************
+
+# if we set this to 'yes', we get no 'upgrade' button on "reinstalls"
+PKG_IS_RELOCATABLE=no
+
+# RootAuthorization / AdminAuthorization
+PKG_AUTHORIZATION=RootAuthorization
+
+
# ****************************** usage ********************************
function usage() {
plistWriteDate >>$F IFPkgBuildDate "`date -u +%Y-%m-%dT%H:%M:%SZ`"
plistWriteString >>$F IFPkgBuildVersion "${PKG_VERSION}"
#plistWriteBool >>$F IFPkgFlagAllowBackRev true
- plistWriteString >>$F IFPkgFlagAuthorizationAction AdminAuthorization
+
+ # allowed: AdminAuthorization, RootAuthorization, ??
+ plistWriteString >>$F IFPkgFlagAuthorizationAction ${PKG_AUTHORIZATION}
+
plistWriteString >>$F IFPkgFlagBackgroundAlignment topright
plistWriteString >>$F IFPkgFlagBackgroundScaling none
plistWriteString >>$F IFPkgFlagDefaultLocation /
#plistWriteBool >>$F IFPkgFlagFollowLinks true
+
#plistWriteBool >>$F IFPkgFlagInstallFat true
+
#plistWriteBool >>$F IFPkgFlagIsRequired false
#plistWriteBool >>$F IFPkgFlagOverwritePermissions false
- plistWriteBool >>$F IFPkgFlagRelocatable true
+
+ if test "x${PKG_IS_RELOCATABLE}" = "xyes"; then
+ plistWriteBool >>$F IFPkgFlagRelocatable true
+ else
+ plistWriteBool >>$F IFPkgFlagRelocatable false
+ fi
+
plistWriteString >>$F IFPkgFlagRestartAction NoRestart
plistWriteBool >>$F IFPkgFlagRootVolumeOnly false
plistWriteBool >>$F IFPkgFlagUpdateInstalledLanguages false
echo >>$F "OverwritePermissions NO" # TODO: consolidate
echo >>$F "UseUserMask NO" # TODO: consolidate
echo >>$F "RootVolumeOnly NO" # TODO: consolidate
- echo >>$F "NeedsAuthorization YES" # TODO: consolidate
+
+ if test "x${PKG_AUTHORIZATION}" = "x"; then
+ echo >>$F "NeedsAuthorization NO"
+ else
+ # need to check Admin/Root?
+ echo >>$F "NeedsAuthorization YES"
+ fi
+
echo >>$F "DefaultLocation /" # TODO: consolidate
- echo >>$F "Relocatable YES" # TODO: consolidate
- echo >>$F "Install Fat YES" # TODO: consolidate
+
+ if test "x${PKG_IS_RELOCATABLE}" = "xyes"; then
+ echo >>$F "Relocatable YES"
+ else
+ echo >>$F "Relocatable NO"
+ fi
+
+ #echo >>$F "Install Fat YES" # TODO: consolidate
echo >>$F "LibrarySubdirectory Standard"
ln -s ${PKG_RSRC_DIR}/English.lproj/${PKG_NAME}.info \
# ****************************** running ******************************
-echo "Building SOPE MacOSX Installer.app packages $PKG_NAME.mpkg .."
+echo "Building SOPE MacOSX Installer.app multipackage $PKG_NAME.mpkg .."
validateArgs;
ensureSudo;
RM_R="rm -r"
+# ****************************** options ******************************
+
+# if we set this to 'yes', we get no 'upgrade' button on "reinstalls"
+PKG_IS_RELOCATABLE=no
+
+PKG_INSTALLFAT=yes
+
+# RootAuthorization / AdminAuthorization
+PKG_AUTHORIZATION=RootAuthorization
+
+
# ****************************** usage ********************************
function usage() {
plistWriteDate >>$F IFPkgBuildDate "`date -u +%Y-%m-%dT%H:%M:%SZ`"
plistWriteString >>$F IFPkgBuildVersion "${PKG_VERSION}"
plistWriteBool >>$F IFPkgFlagAllowBackRev true
- plistWriteString >>$F IFPkgFlagAuthorizationAction AdminAuthorization
+
+ # allowed: AdminAuthorization, RootAuthorization, ??
+ plistWriteString >>$F IFPkgFlagAuthorizationAction ${PKG_AUTHORIZATION}
+
plistWriteString >>$F IFPkgFlagBackgroundAlignment topright
plistWriteString >>$F IFPkgFlagBackgroundScaling none
plistWriteString >>$F IFPkgFlagDefaultLocation /
plistWriteBool >>$F IFPkgFlagFollowLinks true
- plistWriteBool >>$F IFPkgFlagInstallFat true
+
+ if test "x${PKG_INSTALLFAT}" = "xyes"; then
+ plistWriteBool >>$F IFPkgFlagInstallFat true
+ else
+ plistWriteBool >>$F IFPkgFlagInstallFat false
+ fi
+
plistWriteInt >>$F IFPkgFlagInstalledSize $size_uncompressed
plistWriteBool >>$F IFPkgFlagIsRequired false
plistWriteBool >>$F IFPkgFlagOverwritePermissions false
- plistWriteBool >>$F IFPkgFlagRelocatable true
+
+ if test "x${PKG_IS_RELOCATABLE}" = "xyes"; then
+ plistWriteBool >>$F IFPkgFlagRelocatable true
+ else
+ plistWriteBool >>$F IFPkgFlagRelocatable false
+ fi
+
plistWriteString >>$F IFPkgFlagRestartAction NoRestart
plistWriteBool >>$F IFPkgFlagRootVolumeOnly false
plistWriteBool >>$F IFPkgFlagUpdateInstalledLanguages false
echo >>$F "OverwritePermissions NO" # TODO: consolidate
echo >>$F "UseUserMask NO" # TODO: consolidate
echo >>$F "RootVolumeOnly NO" # TODO: consolidate
- echo >>$F "NeedsAuthorization YES" # TODO: consolidate
+
+ if test "x${PKG_AUTHORIZATION}" = "x"; then
+ echo >>$F "NeedsAuthorization NO"
+ else
+ # need to check Admin/Root?
+ echo >>$F "NeedsAuthorization YES"
+ fi
+
echo >>$F "DefaultLocation /" # TODO: consolidate
- echo >>$F "Relocatable YES" # TODO: consolidate
- echo >>$F "Install Fat YES" # TODO: consolidate
+
+ if test "x${PKG_IS_RELOCATABLE}" = "xyes"; then
+ echo >>$F "Relocatable YES"
+ else
+ echo >>$F "Relocatable NO"
+ fi
+
+ if test "x${PKG_INSTALLFAT}" = "xyes"; then
+ echo >>$F "Install Fat YES"
+ else
+ echo >>$F "Install Fat NO"
+ fi
+
echo >>$F "LibrarySubdirectory Standard"
echo ".. done."