From: Konrad Rosenbaum Date: Sun, 15 Apr 2012 19:15:27 +0000 (+0200) Subject: adjusted debian packaging for magicsmoke 2 X-Git-Url: http://git.silmor.de/gitweb/?a=commitdiff_plain;h=297b7a5ca2a1113bc34a3e9ecf4be7f5d11a76a9;p=web%2Fkonrad%2Fsmoke.git adjusted debian packaging for magicsmoke 2 --- diff --git a/debian/control b/debian/control index a7f025e..ce7fee3 100644 --- a/debian/control +++ b/debian/control @@ -2,15 +2,16 @@ Source: magicsmoke2 Section: main Priority: extra Maintainer: Konrad Rosenbaum -Build-Depends: debhelper (>= 7), libqt4-dev, qt4-dev-tools, subversion, subversion-tools +Build-Depends: debhelper (>= 7), libqt4-dev | qt4-local-dev, qt4-dev-tools | qt4-local-dev, git, git2cl Standards-Version: 3.7.3 Homepage: http://smoke.silmor.de Package: magicsmoke2-client Architecture: any Depends: ${shlibs:Depends}, ${local:libssl} -Recommends: magicsmoke2-doc, libqtscript4-core, libqtscript4-gui, libqtscript4-network, libqtscript4-xml -Suggests: magicsmoke2-server, libqtscript4-svg, libqtscript4-webkit, libqtscript4-xmlpatterns, libqtscript4-doc +Recommends: magicsmoke2-doc, + libqtscript4-qtbindings | qtscript4-local +Suggests: magicsmoke2-server, Description: MagicSmoke Ticket Sale System - Standalone Client This package contains the MagicSmoke Ticket Sales System Client version 2. . diff --git a/debian/gencl b/debian/gencl index b150b9c..cad9722 100755 --- a/debian/gencl +++ b/debian/gencl @@ -2,21 +2,19 @@ cl=debian/changelog -test -x "`which svn`" || { - echo 'Warning: cannot find svn - do you have package subversion installed?' 2>&1 +test -x "`which git`" || { + echo 'Warning: cannot find git - do you have package git installed?' 2>&1 test -f $cl && { echo cannot find svn, but $cl exists - accepting it - exit 0 } || { - echo 'Error: cannot find svn and' $cl 'does not exist - cannot proceed.' 1>&2 + echo 'Error: cannot find git and' $cl 'does not exist - cannot proceed.' 1>&2 exit 1 } } -test -d .svn || { - echo 'Warning: this is not a SVN checkout, building in non-dev mode...' 2>&1 +test -d .git || { + echo 'Warning: this is not a GIT checkout, building in non-dev mode...' 2>&1 test -f $cl && { echo 'Info:' $cl 'does exist, accepting it for now' - exit 0 } || { echo 'Error:' $cl 'does not exist, cannot proceed.' 2>&1 exit 1 @@ -25,10 +23,9 @@ test -d .svn || { echo Generating $cl ... -REV="$(svn info|grep Revision:|cut -d " " -f 2)" -REV="2$(echo -n $REV|wc -c|tr 0-9 c-l)$REV" +REV=`git log -1 --date=short --pretty=format:%ad-%h` -if test `svn stat -q|wc -l` -gt 0 ; then +if test `git status --short -uno |wc -l` -gt 0 ; then REV="$REV-modified1" fi @@ -36,14 +33,14 @@ echo "magicsmoke2 ($REV) unstable; urgency=low" >$cl echo >>$cl echo " Package Generated by" `whoami`@`hostname -f` `date -R`>>$cl echo >>$cl -test -x "`which svn2cl`" && { - svn2cl --stdout -i --group-by-day | sed 's/^/ /' | sed 's/\t/ /' >>$cl +test -x "`which git2cl`" && { + git2cl | sed 's/^/ /' | sed 's/\t/ /' >>$cl } || { echo 'Warning: cannot find svn2cl - do you have subversion-tools installed?' 2>&1 echo 'Warning:' $cl 'will have an empty body, this may not be what you wanted.' 2>&1 echo ' ' `date +%Y-%m-%d` `whoami` >>$cl - echo ' * built package without subversion info available, sorry.' >>$cl + echo ' * built package without git log info available, sorry.' >>$cl } echo >>$cl -echo -n ' -- konrad ' >>$cl +echo -n ' -- Konrad Rosenbaum ' >>$cl date -R >>$cl diff --git a/debian/magicsmoke2-client.postinst b/debian/magicsmoke2-client.postinst deleted file mode 100644 index 9079a48..0000000 --- a/debian/magicsmoke2-client.postinst +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/sh -# postinst script for xpack -# -# see: dh_installdeb(1) - -set -e - -# summary of how this script can be called: -# * `configure' -# * `abort-upgrade' -# * `abort-remove' `in-favour' -# -# * `abort-remove' -# * `abort-deconfigure' `in-favour' -# `removing' -# -# for details, see http://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - configure) - for i in /usr/share/qt4/translations/qt_*.qm; do - #echo Linking $i - ln -sf $i /usr/lib/magicsmoke/`basename $$i` - done - ;; - - abort-upgrade|abort-remove|abort-deconfigure) - rm -f /usr/lib/magicsmoke/qt_*.qm || true - ;; - - *) - echo "postinst called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 - - diff --git a/debian/magicsmoke2-client.postrm b/debian/magicsmoke2-client.postrm deleted file mode 100644 index 7acb589..0000000 --- a/debian/magicsmoke2-client.postrm +++ /dev/null @@ -1,43 +0,0 @@ -#!/bin/sh -# postrm script for xpack -# -# see: dh_installdeb(1) - -set -e - -# summary of how this script can be called: -# * `remove' -# * `purge' -# * `upgrade' -# * `failed-upgrade' -# * `abort-install' -# * `abort-install' -# * `abort-upgrade' -# * `disappear' -# -# for details, see http://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - remove|upgrade|failed-upgrade|abort-install|abort-upgrade) - ;; - - purge|disappear) - rm -f /usr/lib/magicsmoke || true - ;; - - *) - echo "postrm called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 - - diff --git a/debian/magicsmoke2-client.prerm b/debian/magicsmoke2-client.prerm deleted file mode 100644 index 2686f0c..0000000 --- a/debian/magicsmoke2-client.prerm +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -# prerm script for xpack -# -# see: dh_installdeb(1) - -set -e - -# summary of how this script can be called: -# * `remove' -# * `upgrade' -# * `failed-upgrade' -# * `remove' `in-favour' -# * `deconfigure' `in-favour' -# `removing' -# -# for details, see http://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - remove|upgrade|deconfigure) - rm -f /usr/lib/magicsmoke/qt_*.qm || true - ;; - - failed-upgrade) - ;; - - *) - echo "prerm called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 - - diff --git a/debian/rules b/debian/rules index 06a2042..95b5332 100755 --- a/debian/rules +++ b/debian/rules @@ -1,7 +1,7 @@ #!/usr/bin/make -f # -*- makefile -*- # Debian packaging script for MagicSmoke -# (c) Konrad Rosenbaum, 2009-2011 +# (c) Konrad Rosenbaum, 2009-2012 #Original comment: # Sample debian/rules that uses debhelper. @@ -32,7 +32,7 @@ build-stamp: configure-stamp @echo '********************' @echo Building... dh_testdir - #make -f Makefile.unix + make all touch $@ clean: @@ -41,7 +41,7 @@ clean: dh_testdir dh_testroot rm -f build-stamp configure-stamp - #$(MAKE) -f Makefile.unix distclean + make distclean dh_clean install: install-base install-client install-doc install-server @@ -61,7 +61,7 @@ install-client: make -C $(CURDIR) install-client PREFIX=$(CLIENT)/usr #debian docu mkdir -p $(CLIENT)/usr/share/doc/magicsmoke2-client - cp -L README COPYING* $(CLIENT)/usr/share/doc/magicsmoke2-client + cp -L README doc/copying-* doc/license.html $(CLIENT)/usr/share/doc/magicsmoke2-client gzip `ls $(CLIENT)/usr/share/doc/magicsmoke2-client/* |grep -v .gz` cp -L src/smoke*.qm $(CLIENT)/usr/lib/magicsmoke2 @@ -71,7 +71,7 @@ install-doc: @echo '********************' @echo Install Doc... mkdir -p $(DOCDIR)/$(DOCDOC) - cp -L README COPYING* $(DOCDIR)/$(DOCDOC) + cp -L README doc/copying-* doc/license.html $(DOCDIR)/$(DOCDOC) gzip `ls $(DOCDIR)/$(DOCDOC)/* |grep -v .gz` make -C $(CURDIR) install-doc PREFIX=$(DOCDIR)/usr @@ -84,7 +84,7 @@ install-server: #copy and link scripts make -C $(CURDIR) install-server PREFIX=$(SERVER)/usr #copy in docu - cp -L README COPYING* $(SERVER)/usr/share/doc/magicsmoke2-server + cp -L README doc/copying-* doc/license.html $(SERVER)/usr/share/doc/magicsmoke2-server gzip `ls $(SERVER)/usr/share/doc/magicsmoke2-server/* |grep -v .gz` gzip $(SERVER)/usr/share/doc/magicsmoke2-server/README.Debian-Install.gz