~ubuntu-branches/ubuntu/trusty/argyll/trusty-proposed

« back to all changes in this revision

Viewing changes to makepackagebin.sh

  • Committer: Package Import Robot
  • Author(s): Artur Rona
  • Date: 2014-02-12 00:35:39 UTC
  • mfrom: (13.1.24 sid)
  • Revision ID: package-import@ubuntu.com-20140212003539-24tautzlitsiz61w
Tags: 1.5.1-5ubuntu1
* Merge from Debian unstable. (LP: #1275572) Remaining changes:
  - debian/control:
    + Build-depend on libtiff-dev rather than libtiff4-dev.
  - debian/control, debian/patches/06_fix_udev_rule.patch:
    + Fix udev rules to actually work; ENV{ACL_MANAGE} has
      stopped working ages ago, and with logind it's now the
      "uaccess" tag. Dropping also consolekit from Recommends.
  - debian/patches/drop-usb-db.patch:
    + Use hwdb builtin, instead of the obsolete usb-db
      in the udev rules.
* debian/patches/05_ftbfs-underlinkage.diff:
  - Dropped change, no needed anymore.
* Refresh the patches.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#!/bin/sh
2
2
echo "Script to invoke Jam and then package the binary release."
3
3
 
4
 
#       Typical environment variables:
5
 
#
6
 
#       Platform                                                $OSTYPE         MACHTYPE                                HOSTTYPE
7
 
#
8
 
#       Win2K [CMD.EXE]                                 (none)          (none)                                  (none)          
9
 
#
10
 
#       Cygwin Win2K [bash]                             cygwin          i686-pc-cygwin                  i686
11
 
#
12
 
#       OS X PPC 10.3 [zsh]                             darwin7.0       powerpc                                 (none)
13
 
#
14
 
#       OS X i386 10.4 [bash]                   darwin8.0       i386-apple-darwin8.0    i386
15
 
#
16
 
#       OS X i386 10.5 [bash]                   darwin9.0       i386-apple-darwin9.0    i386
17
 
#
18
 
#       OS X i386 10.6 [bash]                   darwin10.0      i386-apple-darwin8.0    i386
19
 
#
20
 
#       Linux RH 4.0 [bash]                             linux-gnu       i686-redhat-linux-gnu   i686
21
 
#
22
 
#       Linux Fedora 7.1 [bash]                 linux-gnu       i386-redhat-linux-gnu   i386
23
 
#       Linux Ubuntu  ??7                               linux-gnu       i486-pc-linux-gnu               i686
24
 
#
25
 
#       Linux Fedora 7.1 64 bit [bash]  linux-gnu       x86_64-redhat-linux-gnu x86_64
 
4
#   Typical environment variables:
 
5
#   (NOTE some systems don't export these ENV vars. by default !!!)
 
6
#
 
7
#   Platform                        $OSTYPE      $MACHTYPE                $HOSTTYPE
 
8
#
 
9
#   Win2K [CMD.EXE]                 (none)       (none)                   (none)        
 
10
#
 
11
#   Cygwin Win2K [bash]             cygwin       i686-pc-cygwin           i686
 
12
#
 
13
#   OS X PPC 10.3 [zsh]             darwin7.0    powerpc                  (none)
 
14
#
 
15
#   OS X i386 10.4 [bash]           darwin8.0    i386-apple-darwin8.0     i386
 
16
#
 
17
#   OS X i386 10.5 [bash]           darwin9.0    i386-apple-darwin9.0     i386
 
18
#
 
19
#   OS X i386 10.6 [bash]           darwin10.0   x86_64-apple-darwin10.0  x86_64
 
20
#
 
21
#   OS X i386 10.7 [bash]           darwin11     x86_64-apple-darwin11    x86_64
 
22
#
 
23
#   Linux RH 4.0 [bash]             linux-gnu    i686-redhat-linux-gnu    i686
 
24
#
 
25
#   Linux Fedora 7.1 [bash]         linux-gnu    i386-redhat-linux-gnu    i386
 
26
#   Linux Ubuntu  ??7               linux-gnu    i486-pc-linux-gnu        i686
 
27
#
 
28
#   Linux Fedora 7.1 64 bit [bash]  linux-gnu    x86_64-redhat-linux-gnu  x86_64
 
29
#   Ubuntu 12.10 64 bit [bash]      linux-gnu    x86_64-pc-linux-gnu      x86_64
 
30
#
 
31
#   FreeBSD 9.1 64 bit [bash]       freebsd9.1   amd64-portbld-freebsd9.1 amd64
26
32
#
27
33
 
28
34
# Set the environment string VERSION from the #define, ie 1.0.0
29
35
VERSION=`grep ARGYLL_VERSION_STR h/aconfig.h | sed 's/#define ARGYLL_VERSION_STR //' | sed 's/"//g'`
30
36
 
31
 
echo "About to make Argyll binary distribution $PACKAGE"
 
37
echo "About to make Argyll binary distribution"
32
38
 
33
39
TOPDIR=Argyll_V$VERSION
34
40
 
35
41
if [ X$OS != "XWindows_NT" ] ; then
36
42
        # Fixup issues with the .zip format
37
43
        chmod +x *.sh
38
 
        chmod +x tiff/configure
39
 
#       chmod +x libusb/configure
40
44
fi
41
45
 
42
46
# Make sure that some environment variable are visible to Jam:
56
60
 
57
61
if [ X$OS = "XWindows_NT" ] ; then
58
62
        echo "We're on MSWindows!"
59
 
        PACKAGE=Argyll_V${VERSION}_win32_exe.zip
60
 
        USBDIRS="libusb1"
61
 
        USBBINFILES="binfiles.msw"
62
 
        unset USETAR
 
63
        # Hack cross comile
 
64
        if [ X$COMPILER = "XMINGW64" ] ; then
 
65
                echo "We're cross compiling to MSWin 64 bit !"
 
66
                PACKAGE=Argyll_V${VERSION}_win64_exe.zip
 
67
                USBDIRS="usb"
 
68
                USBBINFILES="binfiles.msw"
 
69
                unset USETAR
 
70
        else
 
71
                # ~~ should detect native 64 bit here ~~
 
72
                echo "We're on MSWin 32 bit !"
 
73
                PACKAGE=Argyll_V${VERSION}_win32_exe.zip
 
74
                USBDIRS="usb"
 
75
                USBBINFILES="binfiles.msw"
 
76
                unset USETAR
 
77
        fi
63
78
else if [ X$OSTYPE = "Xdarwin7.0" ] ; then
64
79
        echo "We're on OSX 10.3 PPC!"
65
80
        PACKAGE=Argyll_V${VERSION}_osx10.3_ppc_bin.tgz
66
 
        USBDIRS="libusb1"
 
81
        USBDIRS="usb"
67
82
        USBBINFILES="binfiles.osx"
68
83
        USETAR=true
69
84
else if [ X$OSTYPE = "Xdarwin8.0" ] ; then
75
90
                PACKAGE=Argyll_V${VERSION}_osx10.4_ppc_bin.tgz
76
91
        fi
77
92
        fi
78
 
        USBDIRS="libusb1"
 
93
        USBDIRS="usb"
79
94
        USBBINFILES="binfiles.osx"
80
95
        USETAR=true
81
 
else if [ X$OSTYPE = "Xdarwin9.0" ] ; then
82
 
        if [ X$MACHTYPE = "Xi386-apple-darwin9.0" ] ; then
83
 
                echo "We're on OSX 10.5 i386!"
84
 
                PACKAGE=Argyll_V${VERSION}_osx10.5_i86_bin.tgz
 
96
else if [ X$OSTYPE = "Xdarwin10.0" \
 
97
       -o X$OSTYPE = "Xdarwin11" ] ; then
 
98
        if [ X$HOSTTYPE = "Xx86_64" ] ; then
 
99
                echo "We're on OSX 10.6 x86_64!"
 
100
                PACKAGE=Argyll_V${VERSION}_osx10.6_x86_64_bin.tgz
85
101
        fi
86
 
        USBDIRS="libusb1"
 
102
        USBDIRS="usb"
87
103
        USBBINFILES="binfiles.osx"
88
104
        USETAR=true
89
105
else if [ X$OSTYPE = "Xlinux-gnu" ] ; then
90
 
        if [ X$MACHTYPE = "Xi686-redhat-linux-gnu" \
91
 
      -o X$MACHTYPE = "Xi386-redhat-linux-gnu" \
92
 
      -o X$MACHTYPE = "Xi486-pc-linux-gnu" ] ; then
 
106
        if [[ "$MACHTYPE" =~ x86_64-.*-linux-gnu ]] ; then
 
107
                echo "We're on Linux x86_64!"
 
108
                PACKAGE=Argyll_V${VERSION}_linux_x86_64_bin.tgz
 
109
        else if [[ "$MACHTYPE" =~ i.86-.*-linux-gnu ]] ; then
93
110
                echo "We're on Linux x86!"
94
111
                PACKAGE=Argyll_V${VERSION}_linux_x86_bin.tgz
95
 
        else if [ X$MACHTYPE = "Xx86_64-redhat-linux-gnu" ] ; then
96
 
                echo "We're on Linux x86_64!"
97
 
                PACKAGE=Argyll_V${VERSION}_linux_x86_64_bin.tgz
98
 
        fi
99
 
        fi
100
 
        USBDIRS="libusb1"
101
 
        USBBINFILES="binfiles.unix"
 
112
        fi
 
113
        fi
 
114
        USBDIRS="usb"
 
115
        USBBINFILES="binfiles.lx"
102
116
        USETAR=true
103
117
fi
104
118
fi
106
120
fi
107
121
fi
108
122
 
 
123
if [ X$PACKAGE = "X" ] ; then
 
124
        echo "Unknown host - build failed!"
 
125
        exit 1
 
126
fi 
 
127
 
109
128
echo "Making GNU Argyll binary distribution $PACKAGE for Version $VERSION"
110
129
 
111
130
rm -rf $TOPDIR