diff options
author | Marius Kintel <marius@kintel.net> | 2013-03-28 03:55:51 (GMT) |
---|---|---|
committer | Marius Kintel <marius@kintel.net> | 2013-03-28 03:55:51 (GMT) |
commit | eefcd6d0b271642d470cd55bc47d1579d943938e (patch) | |
tree | 48f9e4db455879025adb9317b740bfa4b72c2d66 /scripts/release-common.sh | |
parent | f70578f362c8c2c78036c9de846c20802ac7aa81 (diff) | |
parent | beff2b1f4811b7f9d2b58bfc6a469a363bc9bfd0 (diff) |
Merge branch 'master' into epec-kernel
Conflicts:
src/PolySetCGALEvaluator.cc
Diffstat (limited to 'scripts/release-common.sh')
-rwxr-xr-x | scripts/release-common.sh | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/scripts/release-common.sh b/scripts/release-common.sh index de14cb1..10a1c18 100755 --- a/scripts/release-common.sh +++ b/scripts/release-common.sh @@ -9,10 +9,12 @@ # # Usage: release-common.sh [-v <versionstring>] [-c] [-x32] # -v Version string (e.g. -v 2010.01) +# -d Version date (e.g. -d 2010.01.23) # -c Build with commit info # -mingw32 Cross-compile for win32 using MXE # -# If no version string is given, todays date will be used (YYYY-MM-DD) +# If no version string or version date is given, todays date will be used (YYYY-MM-DD) +# If only verion date is given, it will be used also as version string. # If no make target is given, release will be used on Windows, none one Mac OS X # # The commit info will extracted from git and be passed to qmake as OPENSCAD_COMMIT @@ -23,7 +25,7 @@ printUsage() { - echo "Usage: $0 -v <versionstring> -c -mingw32 + echo "Usage: $0 -v <versionstring> -d <versiondate> -c -mingw32 echo echo " Example: $0 -v 2010.01 } @@ -59,16 +61,20 @@ else exit fi -while getopts 'v:c' c +while getopts 'v:d:c' c do case $c in v) VERSION=$OPTARG;; + d) VERSIONDATE=$OPTARG;; c) OPENSCAD_COMMIT=`git log -1 --pretty=format:"%h"` esac done +if test -z "$VERSIONDATE"; then + VERSIONDATE=`date "+%Y.%m.%d"` +fi if test -z "$VERSION"; then - VERSION=`date "+%Y.%m.%d"` + VERSION=$VERSIONDATE fi @@ -102,15 +108,14 @@ if [ -d .git ]; then git submodule update fi -echo "Building openscad-$VERSION $CONFIGURATION..." +echo "Building openscad-$VERSION ($VERSIONDATE) $CONFIGURATION..." +CONFIG=deploy case $OS in LINUX|MACOSX) - CONFIG=deploy TARGET= ;; WIN) - unset CONFIG export QTDIR=/c/devmingw/qt2009.03 export QTMAKESPEC=win32-g++ export PATH=$PATH:/c/devmingw/qt2009.03/bin:/c/devmingw/qt2009.03/qt/bin @@ -119,7 +124,6 @@ case $OS in TARGET=release ;; LINXWIN) - unset CONFIG . ./scripts/setenv-mingw-xbuild.sh TARGET=release ZIP="zip" @@ -230,6 +234,7 @@ echo "Creating archive.." case $OS in MACOSX) + /usr/libexec/PlistBuddy -c "Set :CFBundleVersion $VERSIONDATE" OpenSCAD.app/Contents/Info.plist macdeployqt OpenSCAD.app -dmg -no-strip mv OpenSCAD.dmg OpenSCAD-$VERSION.dmg hdiutil internet-enable -yes -quiet OpenSCAD-$VERSION.dmg |