Changeset: 94d47d41e081 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=94d47d41e081
Modified Files:
        debian/fix-deb.sh
Branch: default
Log Message:

Merge with Jun2016 branch.


diffs (63 lines):

diff --git a/debian/fix-deb.sh b/debian/fix-deb.sh
--- a/debian/fix-deb.sh
+++ b/debian/fix-deb.sh
@@ -1,16 +1,41 @@
 #!/bin/bash
-if [ -f /etc/lsb-release ]; then
-    source /etc/lsb-release
-    ID=${DISTRIB_ID,,}
-    VERSION_ID=$DISTRIB_RELEASE
-elif [ -f /etc/os-release ]; then
-    source /etc/os-release
-else
-    echo "don't know what distro this is"
-    exit 1
-fi
+case $# in
+0)
+    # figure out which distribution this is
+    if [ -f /etc/lsb-release ]; then
+       source /etc/lsb-release
+       SUITE=$DISTRIB_CODENAME
+    elif [ -f /etc/os-release ]; then
+       source /etc/os-release
+       if [[ $ID == debian ]]; then
+           SUITE="${VERSION#*(}"
+           SUITE="${SUITE%)*}"
+       else
+           case $VERSION in
+           *\(*\)*)
+               SUITE="${VERSION#*(}"
+               SUITE="${SUITE% *)*}"
+               ;;
+           *)
+               SUITE="${VERSION#*, }"
+               SUITE="${SUITE% *)*}"
+               ;;
+           esac
+           SUITE=${SUITE,,}
+       fi
+    else
+       echo "don't know what distro this is"
+       exit 1
+    fi
+    ;;
+1)
+    # we're passed the name of the distribution
+    SUITE=$1
+    ;;
+esac
 
-if [[ ( $ID == debian && $VERSION_ID -lt 8 ) || ( $ID == ubuntu && $VERSION_ID 
< 15.10 ) ]]; then
+case $SUITE in
+wheezy | precise | trusty)
     # fix control file because these systems don't have liblas and a
     # too old version of libgeos
     sed -i 's/, libgeos-dev[^,]*//;s/, liblas-c-dev[^,]*//' debian/control
@@ -18,4 +43,5 @@ if [[ ( $ID == debian && $VERSION_ID -lt
     sed -i '/^Package:.*geom/,/^$/d' debian/control
     rm debian/libmonetdb5-server-lidar.install 
debian/libmonetdb5-server-geom.install
     sed -i 
'/geo[ms]=yes/s/yes/no/;/gdal=yes/s/yes/no/;/lidar=yes/s/yes/no/;/liblas=yes/s/yes/no/'
 debian/rules
-fi
+    ;;
+esac
_______________________________________________
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to