fractorium/package-linux.sh
Gambhiro fa5e6188ee squashed linux packaging commits
Squashed commit of the following:

commit e7261977580bfd08d08717c27732eb0b0f534bb2
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Tue Dec 8 11:25:00 2015 +0000

    build signed source package

commit e652848b5e2d5dadfe1143282af204c13f8db418
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Sun Dec 6 12:51:42 2015 +0000

    linux packaging helper script

commit 0c8bf8fcea9d62692c3e973a277c9014b9ef636b
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Sat Dec 5 21:38:37 2015 +0000

    changelog

commit d6c6815d3a59779e03119c0546f01c778188c918
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Sat Dec 5 21:37:32 2015 +0000

    now it's all qmake

commit c37673a0d747134766bf9a1c3a898bbb9e416ed6
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Sat Dec 5 08:46:27 2015 +0000

    don't symlink in manual makefile

commit 2593da2401cbb5b83ea8ec188a3450f52595186e
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Thu Dec 3 16:53:31 2015 +0000

    postfix the version with an 'a'

commit 03d4bdde55d428354d8a8ebe4827ff191162bcb1
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Thu Dec 3 14:55:33 2015 +0000

    use MAKE_OPTS env if set

commit 6f7847c7c0e3eb32ec14e60736a4e2a7b5175a7c
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Thu Dec 3 14:36:21 2015 +0000

    also install dark theme, build only amd64 for now

commit e36d863b3101d4440816e08b9af704e89316d2e9
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Wed Dec 2 18:01:42 2015 +0000

    rules.dh7

commit 0e35f2ddf3b70eaf0040fcac6453d79c1a9571c8
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Wed Dec 2 17:57:57 2015 +0000

    deps

commit 492b4ae7aa41374bf89cd8accf82d5ab0283a5f9
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Wed Dec 2 10:40:04 2015 +0000

    typo

commit 6f0ed09a37849323f220d9aa50ac7c6bd3d411cb
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Wed Dec 2 10:37:55 2015 +0000

    deps and version

commit 82f2fd07b6703d5699926c297dee25a59111acb9
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Wed Dec 2 09:50:00 2015 +0000

    rev logic

commit e5d33b62236e0b33653fa79d82274e157cb26bc2
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Wed Dec 2 09:17:50 2015 +0000

    create bin and libdir

commit 84153860e6861a43ffc0f1073d462f2452f7e7c4
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Wed Dec 2 08:48:23 2015 +0000

    support prefix

commit a5da29a15a15fc130ef1147ed495d86238e7a2f3
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Wed Dec 2 08:45:52 2015 +0000

    support DESTDIR

commit da1be8b940fb3e51632ed4a35b6afe7defe17848
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Tue Dec 1 21:06:01 2015 +0000

    rev clean logic

commit 738c78a93b159d27fc5c00361bb621cd864ac224
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Tue Dec 1 20:59:34 2015 +0000

    better make clean

commit 2bf382412e573cd93c8a744b374196d5ea59c218
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Tue Dec 1 20:44:48 2015 +0000

    debian folder

commit af420ef5d98744315fa526f0d072197b00b1af28
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Tue Dec 1 18:18:51 2015 +0000

    make clean ./Bin too

commit 6d0243a10dac725251ea566ad717ff9b4fd0eea2
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Tue Dec 1 17:56:31 2015 +0000

    lowercase

commit 41b4eaef6d9adbbb8ec00a9a15c20498f300924e
Author: Gambhiro <gambhiro.bhikkhu.85@gmail.com>
Date:   Tue Dec 1 17:34:21 2015 +0000

    configure and Makefile
2015-12-08 11:49:19 +00:00

67 lines
1.7 KiB
Bash
Executable File

#!/bin/bash
# version for the debian package
VERSION=0.9.9.2b
PROJECT=fractorium
PROJECT_ROOT=$PWD
PPA_DIR="$HOME/PPA/$PROJECT-$VERSION"
TAR_NAME="$PROJECT-$VERSION.tar.gz"
if [ ! -d '.git' -o ! -f 'main.pro' ]; then
echo "Run `basename $0` from the project root."
exit 2
fi
tarversion=$(tar --version | head -1 | sed -e 's/tar (GNU tar) \+\([0-9\.]\+\)$/\1/; s/[^0-9]//g; s/^\(.{3}\).*$/\1/;')
if [[ "$tarversion" -lt "128" ]]; then
echo "Tar >= 1.28 is required. Download the .deb from https://launchpad.net/ubuntu/+source/tar/ and install manually."
exit 2
fi
if [ ! -d "$PPA_DIR" ]; then
mkdir -p "$PPA_DIR"
fi
# tar 1.28 required for --exclude-vcs-ignores
# FIXME: somehow it didn't ignore the 'Bin' folder.
tar --exclude='package-linux.sh' \
--exclude='Bin' \
--exclude-vcs \
--exclude-vcs-ignores \
--exclude-backups \
-czf "$PPA_DIR/$TAR_NAME" .
[ $? -ne 0 ] && echo "Tar command failed." && exit 2
# TODO: find the option to specify single binary, so the question can be skipped.
cd "$PPA_DIR" &&\
bzr dh-make $PROJECT $VERSION $TAR_NAME &&\
cd fractorium/debian &&\
rm *.ex *.EX README.Debian README.source &&\
cd ..
[ $? -ne 0 ] && echo "bzr dh-make command failed." && exit 2
bzr add . &&\
bzr commit -m "Debian package $VERSION"
[ $? -ne 0 ] && echo "bzr command failed." && exit 2
# Build a signed source package for Launchpad, it will build its own binary on
# the servers.
bzr builddeb -- -S
[ $? -ne 0 ] && echo "bzr builddeb for source package failed." && exit 2
# Optionally, build an unsigned binary package for local use.
# bzr builddeb -- -b -us -uc
#
# [ $? -ne 0 ] && echo "bzr builddeb for source package failed." && exit 2