2005-09-02 04:16:20 +00:00
|
|
|
#!/bin/csh
|
|
|
|
|
2006-07-06 11:04:46 +00:00
|
|
|
## Berkeley Open Infrastructure for Network Computing
|
|
|
|
## http://boinc.berkeley.edu
|
|
|
|
## Copyright (C) 2005 University of California
|
|
|
|
##
|
|
|
|
## This is free software; you can redistribute it and/or
|
|
|
|
## modify it under the terms of the GNU Lesser General Public
|
|
|
|
## License as published by the Free Software Foundation;
|
|
|
|
## either version 2.1 of the License, or (at your option) any later version.
|
|
|
|
##
|
|
|
|
## This software is distributed in the hope that it will be useful,
|
|
|
|
## but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
## See the GNU Lesser General Public License for more details.
|
|
|
|
##
|
|
|
|
## To view the GNU Lesser General Public License visit
|
|
|
|
## http://www.gnu.org/copyleft/lesser.html
|
|
|
|
## or write to the Free Software Foundation, Inc.,
|
|
|
|
## 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
|
|
|
2005-09-02 04:16:20 +00:00
|
|
|
##
|
2007-07-11 09:52:05 +00:00
|
|
|
# Release Script for Macintosh BOINC Manager 7/11/07 by Charlie Fenton
|
2005-09-02 04:16:20 +00:00
|
|
|
##
|
|
|
|
|
|
|
|
## Usage:
|
|
|
|
## cd to the root directory of the boinc tree, for example:
|
|
|
|
## cd [path]/boinc
|
|
|
|
##
|
|
|
|
## Invoke this script with the three parts of version number as arguments.
|
|
|
|
## For example, if the version is 3.2.1:
|
|
|
|
## source [path_to_this_script] 3 2 1
|
|
|
|
##
|
|
|
|
## This will create a director "BOINC_Installer" in the parent directory of
|
|
|
|
## the current directory
|
2006-01-23 13:16:28 +00:00
|
|
|
##
|
|
|
|
## For testing only, you can use the development build by adding a fourth argument -dev
|
|
|
|
## For example, if the version is 3.2.1:
|
|
|
|
## source [path_to_this_script] 3 2 1 -dev
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2005-11-08 01:07:13 +00:00
|
|
|
if [ $# -lt 3 ]; then
|
|
|
|
echo "Usage:"
|
|
|
|
echo " cd [path]/boinc"
|
|
|
|
echo " source [path_to_this_script] major_version minor_version revision_number"
|
2006-04-17 07:58:19 +00:00
|
|
|
return 1
|
2005-11-08 01:07:13 +00:00
|
|
|
fi
|
|
|
|
|
2006-12-01 06:45:59 +00:00
|
|
|
#pushd ./
|
|
|
|
BOINCPath=$PWD
|
2006-01-21 12:42:04 +00:00
|
|
|
|
2005-11-08 01:07:13 +00:00
|
|
|
## XCode 2.x has separate directories for Development and Deployment build products
|
2006-01-20 14:04:06 +00:00
|
|
|
if [ "$4" = "-dev" ]; then
|
|
|
|
if [ -d mac_build/build/Development/ ]; then
|
|
|
|
BUILDPATH="mac_build/build/Development"
|
|
|
|
else
|
|
|
|
BUILDPATH="mac_build/build"
|
|
|
|
fi
|
2005-11-08 01:07:13 +00:00
|
|
|
else
|
2006-02-02 12:48:36 +00:00
|
|
|
if [ -d mac_build/build/Deployment/ ]; then
|
|
|
|
BUILDPATH="mac_build/build/Deployment"
|
2006-01-20 14:04:06 +00:00
|
|
|
else
|
|
|
|
BUILDPATH="mac_build/build"
|
|
|
|
fi
|
2005-11-08 01:07:13 +00:00
|
|
|
fi
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2005-10-01 21:54:55 +00:00
|
|
|
sudo rm -dfR ../BOINC_Installer/Installer\ Resources/
|
|
|
|
sudo rm -dfR ../BOINC_Installer/Pkg_Root
|
2005-09-02 04:16:20 +00:00
|
|
|
|
|
|
|
mkdir -p ../BOINC_Installer/Installer\ Resources/
|
|
|
|
|
|
|
|
cp -fp mac_Installer/License.rtf ../BOINC_Installer/Installer\ Resources/
|
|
|
|
cp -fp mac_installer/ReadMe.rtf ../BOINC_Installer/Installer\ Resources/
|
2007-06-12 10:25:48 +00:00
|
|
|
cp -fp win_build/installerv2/redist/all_projects_list.xml ../BOINC_Installer/Installer\ Resources/
|
|
|
|
|
2006-04-17 23:55:35 +00:00
|
|
|
# Update version number
|
|
|
|
sed -i "" s/"<VER_NUM>"/"$1.$2.$3"/g ../BOINC_Installer/Installer\ Resources/ReadMe.rtf
|
|
|
|
|
2006-04-17 07:58:19 +00:00
|
|
|
#### We don't customize BOINC Data directory name for branding
|
2006-12-14 02:58:52 +00:00
|
|
|
## cp -fp mac_installer/preinstall ../BOINC_Installer/Installer\ Resources/
|
|
|
|
## cp -fp mac_installer/preinstall ../BOINC_Installer/Installer\ Resources/preupgrade
|
2005-09-02 04:16:20 +00:00
|
|
|
cp -fp mac_installer/postinstall ../BOINC_Installer/Installer\ Resources/
|
|
|
|
cp -fp mac_installer/postupgrade ../BOINC_Installer/Installer\ Resources/
|
|
|
|
|
2007-04-03 09:48:57 +00:00
|
|
|
cp -fpR $BUILDPATH/PostInstall.app ../BOINC_Installer/Installer\ Resources/
|
2005-09-02 04:16:20 +00:00
|
|
|
|
|
|
|
mkdir -p ../BOINC_Installer/Pkg_Root
|
|
|
|
mkdir -p ../BOINC_Installer/Pkg_Root/Applications
|
|
|
|
mkdir -p ../BOINC_Installer/Pkg_Root/Library
|
|
|
|
mkdir -p ../BOINC_Installer/Pkg_Root/Library/Screen\ Savers
|
|
|
|
mkdir -p ../BOINC_Installer/Pkg_Root/Library/Application\ Support
|
|
|
|
mkdir -p ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data
|
|
|
|
mkdir -p ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/locale
|
2006-06-20 11:25:23 +00:00
|
|
|
mkdir -p ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/switcher
|
2007-07-11 09:52:05 +00:00
|
|
|
mkdir -p ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/skins
|
2006-06-20 11:25:23 +00:00
|
|
|
|
|
|
|
cp -fpR $BUILDPATH/switcher ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/switcher/
|
2006-07-06 11:04:46 +00:00
|
|
|
cp -fpR $BUILDPATH/setprojectgrp ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/switcher/
|
2007-02-20 01:39:26 +00:00
|
|
|
## cp -fpR $BUILDPATH/AppStats ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/switcher/
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2006-12-14 02:58:52 +00:00
|
|
|
## FOR NOW - Don't install WCG Skins. If you reinstate this, also reinstate preinstall & preupgrade above
|
2006-12-01 06:45:59 +00:00
|
|
|
## Copy the World Community Grid skins into the installer tree, minus the CVS files
|
2006-12-14 02:58:52 +00:00
|
|
|
## mkdir -p ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/skins
|
|
|
|
## cd "${BOINCPath}/clientgui/skins"
|
|
|
|
## cp -fpR World\ Community\ Grid ../../../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/skins/
|
|
|
|
## cd "${BOINCPath}"
|
|
|
|
## sudo rm -dfR ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/skins/World\ Community\ Grid/CVS
|
|
|
|
## sudo rm -dfR ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/skins/World\ Community\ Grid/graphic/CVS
|
2006-12-01 06:45:59 +00:00
|
|
|
|
2007-06-12 10:25:48 +00:00
|
|
|
cp -fp curl/ca-bundle.crt ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/
|
2006-08-25 12:38:18 +00:00
|
|
|
|
2005-11-08 01:07:13 +00:00
|
|
|
cp -fpR $BUILDPATH/BOINCManager.app ../BOINC_Installer/Pkg_Root/Applications/
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2005-11-08 01:07:13 +00:00
|
|
|
cp -fpR $BUILDPATH/BOINCSaver.saver ../BOINC_Installer/Pkg_Root/Library/Screen\ Savers/
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2005-10-20 10:06:07 +00:00
|
|
|
## Copy the localization files into the installer tree
|
|
|
|
## Old way copies CVS and *.po files which are not needed
|
2005-10-20 09:56:22 +00:00
|
|
|
## cp -fpR locale/client/ ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/locale
|
|
|
|
## sudo rm -dfR ../BOINC_Installer/Pkg_Root/Library/Application\ Support/BOINC\ Data/locale/CVS
|
2005-10-20 10:07:00 +00:00
|
|
|
## New way copies only *.mo files (adapted from boinc/sea/make-tar.sh)
|
2006-02-16 11:21:40 +00:00
|
|
|
find locale/client -name '*.mo' | cut -d '/' -f 3 | awk '{print "\"../BOINC_Installer/Pkg_Root/Library/Application Support/BOINC Data/locale/"$0"\""}' | xargs mkdir -p
|
2005-10-20 10:06:07 +00:00
|
|
|
find locale/client -name '*.mo' | cut -d '/' -f 3,4 | awk '{print "cp \"locale/client/"$0"\" \"../BOINC_Installer/Pkg_Root/Library/Application Support/BOINC Data/locale/"$0"\""}' | bash
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2006-01-21 12:42:04 +00:00
|
|
|
## Fix up ownership and permissions
|
2005-09-02 04:16:20 +00:00
|
|
|
sudo chown -R root:admin ../BOINC_Installer/Pkg_Root/*
|
2006-06-20 11:25:23 +00:00
|
|
|
sudo chmod -R u+rw,g+rw,o+r-w ../BOINC_Installer/Pkg_Root/*
|
2006-01-21 12:42:04 +00:00
|
|
|
sudo chmod 1775 ../BOINC_Installer/Pkg_Root/Library
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2006-01-21 12:42:04 +00:00
|
|
|
sudo chown -R 501:admin ../BOINC_Installer/Pkg_Root/Library/Application\ Support/*
|
2006-06-20 11:25:23 +00:00
|
|
|
sudo chmod -R u+rw,g+r-w,o+r-w ../BOINC_Installer/Pkg_Root/Library/Application\ Support/*
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2005-09-02 07:15:22 +00:00
|
|
|
sudo chown -R root:admin ../BOINC_Installer/Installer\ Resources/*
|
2006-06-20 11:25:23 +00:00
|
|
|
sudo chmod -R u+rw,g+r-w,o+r-w ../BOINC_Installer/Installer\ Resources/*
|
2005-09-02 07:15:22 +00:00
|
|
|
|
2005-10-01 21:54:55 +00:00
|
|
|
sudo rm -dfR ../BOINC_Installer/New_Release_$1_$2_$3/
|
|
|
|
|
2005-09-02 04:16:20 +00:00
|
|
|
mkdir -p ../BOINC_Installer/New_Release_$1_$2_$3/
|
2006-02-02 13:20:53 +00:00
|
|
|
mkdir -p ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal
|
2007-06-09 11:42:26 +00:00
|
|
|
mkdir -p ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras
|
2006-02-02 13:20:53 +00:00
|
|
|
mkdir -p ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin
|
2005-09-21 04:51:20 +00:00
|
|
|
mkdir -p ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_SymbolTables
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2006-04-17 23:55:35 +00:00
|
|
|
cp -fp ../BOINC_Installer/Installer\ Resources/ReadMe.rtf ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal
|
2006-02-02 13:20:53 +00:00
|
|
|
sudo chown -R 501:admin ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/ReadMe.rtf
|
2006-06-20 11:25:23 +00:00
|
|
|
sudo chmod -R 644 ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/ReadMe.rtf
|
2007-06-09 11:42:26 +00:00
|
|
|
cp -fp COPYING ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras
|
|
|
|
sudo chown -R 501:admin ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras/COPYING
|
|
|
|
sudo chmod -R 644 ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras/COPYING
|
|
|
|
cp -fp COPYRIGHT ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras
|
|
|
|
sudo chown -R 501:admin ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras/COPYRIGHT
|
|
|
|
sudo chmod -R 644 ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras/COPYRIGHT
|
|
|
|
|
|
|
|
cp -fpR $BUILDPATH/Uninstall\ BOINC.app ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras
|
|
|
|
sudo chown -R root:admin ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras/Uninstall\ BOINC.app
|
|
|
|
sudo chmod -R 555 ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/extras/Uninstall\ BOINC.app
|
2007-06-06 11:42:51 +00:00
|
|
|
|
2006-06-27 12:56:11 +00:00
|
|
|
# Copy the installer wrapper application "BOINC Installer.app"
|
|
|
|
cp -fpR $BUILDPATH/BOINC\ Installer.app ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/
|
|
|
|
# Build the installer package inside the wrapper application's bundle
|
|
|
|
/Developer/Tools/packagemaker -build -p ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/BOINC\ Installer.app/Contents/Resources/BOINC.pkg -f ../BOINC_Installer/Pkg_Root -r ../BOINC_Installer/Installer\ Resources/ -i mac_build/Pkg-Info.plist -d mac_Installer/Description.plist -ds
|
|
|
|
# Allow the installer wrapper application to modify the package's Info.plist file
|
|
|
|
sudo chmod u+w,g+w,o+w ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/BOINC\ Installer.app/Contents/Resources/BOINC.pkg/Contents/Info.plist
|
2007-06-06 11:42:51 +00:00
|
|
|
sudo chmod u+w,g+w,o+w ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_universal/BOINC\ Installer.app/Contents/Resources/BOINC.pkg/Contents/Info.plist
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2006-09-22 02:54:27 +00:00
|
|
|
# Build the stand-alone client distribution
|
|
|
|
cp -fpR mac_build/Mac_SA_Insecure.sh ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/
|
|
|
|
cp -fpR mac_build/Mac_SA_Secure.sh ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/
|
2006-10-10 10:48:18 +00:00
|
|
|
cp -fpR COPYING ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/
|
|
|
|
cp -fpR COPYRIGHT ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/
|
2007-05-05 01:28:43 +00:00
|
|
|
cp -fp mac_Installer/License.rtf ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/
|
2006-10-10 10:48:18 +00:00
|
|
|
sudo chown -R 501:admin ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/*
|
|
|
|
sudo chmod -R 644 ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/*
|
2006-09-22 02:54:27 +00:00
|
|
|
|
|
|
|
mkdir -p ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir
|
|
|
|
cp -fpR $BUILDPATH/boinc ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir/
|
|
|
|
cp -fpR $BUILDPATH/boinc_cmd ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir/
|
|
|
|
cp -fpR curl/ca-bundle.crt ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir/
|
|
|
|
|
|
|
|
mkdir -p ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir/switcher
|
|
|
|
cp -fpR $BUILDPATH/switcher ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir/switcher/
|
|
|
|
cp -fpR $BUILDPATH/setprojectgrp ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir/switcher/
|
2007-02-20 01:48:19 +00:00
|
|
|
## cp -fpR $BUILDPATH/AppStats ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir/switcher/
|
2006-09-22 02:54:27 +00:00
|
|
|
|
2006-10-10 10:48:18 +00:00
|
|
|
sudo chown -R root:admin ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir/*
|
|
|
|
sudo chmod -R u+rw-s,g+r-ws,o+r-w ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_universal-apple-darwin/move_to_boinc_dir/*
|
2006-09-22 02:54:27 +00:00
|
|
|
|
|
|
|
cp -fpR $BUILDPATH/SymbolTables ../BOINC_Installer/New_Release_$1_$2_$3/boinc_$1.$2.$3_macOSX_SymbolTables/
|
|
|
|
|
2005-09-02 04:16:20 +00:00
|
|
|
cd ../BOINC_Installer/New_Release_$1_$2_$3
|
2006-02-25 09:16:32 +00:00
|
|
|
zip -rqy boinc_$1.$2.$3_macOSX_universal.zip boinc_$1.$2.$3_macOSX_universal
|
|
|
|
zip -rqy boinc_$1.$2.$3_universal-apple-darwin.zip boinc_$1.$2.$3_universal-apple-darwin
|
|
|
|
zip -rqy boinc_$1.$2.$3_macOSX_SymbolTables.zip boinc_$1.$2.$3_macOSX_SymbolTables
|
2005-09-02 04:16:20 +00:00
|
|
|
|
2006-12-01 06:45:59 +00:00
|
|
|
#popd
|
|
|
|
cd "${BOINCPath}"
|
|
|
|
|
2006-01-21 12:42:04 +00:00
|
|
|
return 0
|