Skip to content

Commit

Permalink
packaging: added compile support for debian/sid and centos-6
Browse files Browse the repository at this point in the history
This commit allows to compile winexe for debian/sid and centos-6
using ./packaging/build script.

Signed-off-by: Andrzej Hajda <[email protected]>
  • Loading branch information
Andrzej Hajda committed Nov 11, 2013
1 parent cdeb3c9 commit 1b0cac8
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
14 changes: 11 additions & 3 deletions packaging/build
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ if [ ! -d "$distro" ]; then
}
eval "case \"$distro\" in
${dist_deb// /|})
sudo debootstrap $distro $distro;;
sudo debootstrap --include=sudo $distro $distro;;
${dist_rpm// /|})
sudo rinse --arch amd64 --directory $distro --distribution $distro --add-pkg-list sudo;;
echo sudo | sudo rinse --arch amd64 --directory $distro --distribution $distro --add-pkg-list /dev/stdin;;
*)
echo \"Unknown distro: $distro\"
exit 1;;
Expand All @@ -37,19 +37,27 @@ fi

trap on_exit EXIT

[ -c $distro/dev/tty ] || sudo mknod $distro/dev/tty c 5 0
[ -c $distro/dev/null ] || sudo mknod -m 666 $distro/dev/null c 1 3

mark_is postinstall || sudo chroot $distro /bin/bash -c '
case $(lsb_release -is 2>dev/null) in
Ubuntu)
echo "deb https://archive.ubuntu.com/ubuntu $(lsb_release -sc) universe" >> /etc/apt/sources.list
apt-get update
;;
esac
[ grep CentOS /etc/redhat-release ] && {
yum-config-manager --add-repo https://www.lfarkas.org/linux/packages/centos/lfarkas.repo
rpm -i https://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
}
echo postinstall >>/mark.log
'

case $distro in
opensuse-*) pkg_install="zypper -n install";;
*) pkg_install="apt-get -y install";;
centos-*) pkg_install="yum -y install";;
*) pkg_install="apt-get --force-yes -y install";;
esac

grep -P "^$USER:" /etc/passwd | sudo tee -a $distro/etc/passwd >/dev/null
Expand Down
1 change: 1 addition & 0 deletions packaging/spec.centos-6
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
builddep="gcc pkgconfig libtalloc-devel samba4-devel popt-devel mingw64-gcc mingw32-gcc"
1 change: 1 addition & 0 deletions packaging/spec.sid
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
builddep="gcc gcc-mingw-w64 pkg-config libtalloc-dev samba-dev libtevent-dev"

0 comments on commit 1b0cac8

Please sign in to comment.