2017-02-25 04:30:55 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
VERSION=$1
|
|
|
|
|
|
|
|
if [ -z "$VERSION" ]; then
|
|
|
|
echo "usage: ./archive-macos.sh <version>"
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
2017-03-16 04:16:52 +00:00
|
|
|
rm -rf bin/
|
2017-02-25 04:30:55 +00:00
|
|
|
|
2017-03-16 04:16:52 +00:00
|
|
|
make clean
|
2017-02-25 04:30:55 +00:00
|
|
|
cmake -DCMAKE_BUILD_TYPE=Release -DLINK_STATICALLY=true .
|
|
|
|
make -j4
|
|
|
|
|
2017-07-20 00:36:50 +00:00
|
|
|
DIRNAME="musikcube_macos_$VERSION"
|
2017-02-25 04:30:55 +00:00
|
|
|
OUTPATH="bin/dist/$DIRNAME"
|
|
|
|
|
|
|
|
rm -rf "$OUTPATH"
|
|
|
|
|
|
|
|
mkdir -p "$OUTPATH/plugins"
|
2017-03-16 04:10:28 +00:00
|
|
|
mkdir -p "$OUTPATH/locales"
|
|
|
|
mkdir -p "$OUTPATH/themes"
|
2018-02-02 18:30:25 +00:00
|
|
|
cp bin/musikcube "$OUTPATH"
|
|
|
|
cp bin/musikcubed "$OUTPATH"
|
|
|
|
cp bin/libmusikcore.dylib "$OUTPATH"
|
2017-02-25 04:30:55 +00:00
|
|
|
cp bin/plugins/*.dylib "$OUTPATH/plugins"
|
2017-03-16 04:10:28 +00:00
|
|
|
cp bin/locales/*.json "$OUTPATH/locales"
|
|
|
|
cp bin/themes/*.json "$OUTPATH/themes"
|
2017-02-25 04:30:55 +00:00
|
|
|
|
2017-07-20 00:36:50 +00:00
|
|
|
strip bin/musikcube
|
2018-02-02 18:30:25 +00:00
|
|
|
strip bin/musikcubed
|
|
|
|
strip bin/libmusikcore.dylib
|
2017-03-16 04:16:52 +00:00
|
|
|
strip bin/plugins/*.dylib
|
|
|
|
|
2017-02-25 04:30:55 +00:00
|
|
|
pushd bin/dist
|
2017-07-20 00:36:50 +00:00
|
|
|
tar cvf musikcube_macos_$VERSION.tar $DIRNAME
|
|
|
|
bzip2 musikcube_macos_$VERSION.tar
|
2017-02-25 04:30:55 +00:00
|
|
|
popd
|