From a49dcdce3e3012ab80903a2d67812915eb958610 Mon Sep 17 00:00:00 2001 From: cajus Date: Wed, 4 Apr 2007 14:38:58 +0000 Subject: [PATCH] Added simple build mechanism for sarge packages git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@5983 594d385d-05f5-0310-b6e9-bd551577e9d8 --- debian/rules | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/debian/rules b/debian/rules index 71d6555bf..0ddad67f7 100755 --- a/debian/rules +++ b/debian/rules @@ -4,6 +4,7 @@ # Some lines taken from debmake, by Cristoph Lameter. export DH_COMPAT=4 +SARGE_PACKAGE=`cat debian/changelog | head -n1 | grep sarge` # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 @@ -85,11 +86,13 @@ install-stamp: -rm -rf debian/gosa/usr/share/gosa/gen_function_list.php -rm -rf debian/gosa/usr/share/gosa/update.sh -rm -rf debian/gosa/usr/share/doc/gosa/guide* - -rm -rf debian/gosa/usr/share/gosa/include/smarty - -sed 's%"CONFIG_TEMPLATE_DIR", "../contrib/"%"CONFIG_TEMPLATE_DIR", "/usr/share/doc/gosa/contrib/"%g' debian/gosa/usr/share/gosa/include/functions.inc > debian/gosa/usr/share/gosa/include/functions.inc.new - -mv debian/gosa/usr/share/gosa/include/functions.inc.new debian/gosa/usr/share/gosa/include/functions.inc - -sed 's%require("smarty/Smarty.class.php");%require("/usr/share/php/smarty/libs/Smarty.class.php");%g' debian/gosa/usr/share/gosa/include/php_setup.inc > debian/gosa/usr/share/gosa/include/php_setup.inc.new - -mv debian/gosa/usr/share/gosa/include/php_setup.inc.new debian/gosa/usr/share/gosa/include/php_setup.inc + -if [ -z "${SARGE_PACKAGE}" ]; then \ + rm -rf debian/gosa/usr/share/gosa/include/smarty; \ + sed 's%"CONFIG_TEMPLATE_DIR", "../contrib/"%"CONFIG_TEMPLATE_DIR", "/usr/share/doc/gosa/contrib/"%g' debian/gosa/usr/share/gosa/include/functions.inc > debian/gosa/usr/share/gosa/include/functions.inc.new; \ + mv debian/gosa/usr/share/gosa/include/functions.inc.new debian/gosa/usr/share/gosa/include/functions.inc; \ + sed 's%require("smarty/Smarty.class.php");%require("/usr/share/php/smarty/libs/Smarty.class.php");%g' debian/gosa/usr/share/gosa/include/php_setup.inc > debian/gosa/usr/share/gosa/include/php_setup.inc.new; \ + mv debian/gosa/usr/share/gosa/include/php_setup.inc.new debian/gosa/usr/share/gosa/include/php_setup.inc; \ + fi touch install-stamp patch: patch-stamp @@ -115,7 +118,11 @@ binary-indep: install cd debian/gosa && find ./etc -type f -print | sed -e 's#^./#/#' > DEBIAN/conffiles chmod 644 debian/gosa/DEBIAN/conffiles - dh_gencontrol + -if [ -z "${SARGE_PACKAGE}" ]; then \ + dh_gencontrol; \ + else \ + dh_gencontrol -- -cdebian/control.sarge; \ + fi dh_md5sums dh_builddeb -- 2.30.2