Code

Made different section possible inside dh-make-gosa
authorcajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 3 Jun 2008 12:57:24 +0000 (12:57 +0000)
committercajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 3 Jun 2008 12:57:24 +0000 (12:57 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11173 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-core/contrib/make-gosa-package
gosa-core/dh-make-gosa

index 51199ecea3eafd726c4705c3b2991acf47789a78..fc3e36aeadef7a9314bb5891edd376ea2b74ac49 100755 (executable)
@@ -38,7 +38,7 @@ fi
 mv "gosa-${BRANCH}" "gosa-${GOSA_VER}"
 mv "gosa-si-${BRANCH}" "gosa-si-${GOSA_VER}"
 
-echo "Creating original sources '$gosa-{GOSA_VER}'..."
+echo "Creating original sources 'gosa-${GOSA_VER}'..."
 tar -c -f "gosa_${GOSA_VER}.orig.tar" "${GOSA_DIR}"
 tar -c -f "gosa-si_${GOSA_VER}.orig.tar" "${GOSA_SI_DIR}"
 
@@ -56,7 +56,7 @@ for plugin in $MAKE_PLUGINS; do
        mv "gosa-plugins-${BRANCH}/$plugin" .
 
        echo "Debianizing plugin $plugin"
-       yes | dh-make-gosa $plugin
+       yes | dh-make-gosa --section web $plugin
        rm -rf "$plugin"
 
        echo "Packing original sources 'gosa-plugin-$plugin-${GOSA_VER}'..."
index 234580c0865b13bab11ccfacf34191d3538fabae..4d9dfb705e516391aa677630744114fe01babf1e 100755 (executable)
@@ -1,7 +1,7 @@
 #!/bin/bash
 
 usage() {
-  echo "Usage: ${0##*/} [--download] [-b|--branch branch] [-e|--email mail] [--depends] plugin-dir|plugin.tar.gz" >&2
+  echo "Usage: ${0##*/} [--download] [--section section name] [-b|--branch branch] [-e|--email mail] [--depends] plugin-dir|plugin.tar.gz" >&2
   exit 1
 }
 
@@ -28,7 +28,7 @@ load_dsc() {
 }
 
 
-TEMP=`getopt -o e:r: --long download,release:,email:,depends: -n 'dh-make-gosa' -- "$@"`
+TEMP=`getopt -o e:r: --long download,release:,email:,depends:,section: -n 'dh-make-gosa' -- "$@"`
 if [ $? != 0 ] ; then
   echo "Error: cannot get command line information" >&2
   exit 1
@@ -40,6 +40,7 @@ eval set -- "$TEMP"
 RELEASE=trunk
 DOWNLOAD=
 DEPENDS=
+SECTION=web
 DEST=
 while true; do
   case "$1" in
@@ -55,6 +56,9 @@ while true; do
     --depends)  DEPENDS="$2"
                 shift 2
                 ;;
+    --section)  SECTION="$2"
+                shift 2
+                ;;
     --dest)     DEST=$2/
                 shift 2
                 ;;
@@ -183,7 +187,7 @@ sed -i "/.put author's name and email here.\
 sed -i '/^Upstream/,/^$/d' debian/copyright
 
 # Adapt control
-sed -i 's/^Section: unknown/Section: web/g' debian/control
+sed -i "s#^Section: unknown#Section: $SECTION#g" debian/control
 sed -i 's/^Architecture: any/Architecture: all/g' debian/control
 if [ "$PL_DEPENDS" ]; then
        sed -i "s/^Depends: .*$/Depends: gosa, $PL_DEPENDS/g" debian/control