From 6c1dd69ce5c4792c21f1b4957ea6e6a9c3c9aa3f Mon Sep 17 00:00:00 2001 From: Gwenhael Le Moine Date: Sun, 3 Mar 2013 11:22:39 +0100 Subject: [PATCH] add heimdall for playing with Galaxies --- xap/heimdall/heimdall.SlackBuild | 94 ++++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+) create mode 100755 xap/heimdall/heimdall.SlackBuild diff --git a/xap/heimdall/heimdall.SlackBuild b/xap/heimdall/heimdall.SlackBuild new file mode 100755 index 00000000..baa27e53 --- /dev/null +++ b/xap/heimdall/heimdall.SlackBuild @@ -0,0 +1,94 @@ +#!/bin/sh -x + +# variables +CWD=$(pwd) + +PRGNAM=$(basename $(pwd)) +BRANCH= +VERSION=${VERSION:-$(date +"%Y.%m.%d_%H.%M")} +ARCH=${ARCH:-$(uname -m)} +BUILD=1 + + +TAG=cyco +TMP=/tmp/$TAG +PKG=$TMP/pkg-$PRGNAM +OUTPUT=/tmp + +REPOSITORIES=/home/installs/SlackBuilds/repositories + +DOCS="*.txt" + +PREFIX=/usr + +SLCKFLAGS="" + +if [ ! -e $REPOSITORIES/$PRGNAM ]; then + git clone git://github.com/Benjamin-Dobell/Heimdall.git $REPOSITORIES/$PRGNAM +else + ( cd $REPOSITORIES/$PRGNAM + git pull + ) +fi + +# nettoyage préalable +rm -fr $PKG $TMP/$PRGNAM + +mkdir -p $PKG + +# mise en place +cp -R $REPOSITORIES/$PRGNAM $TMP/$PRGNAM +cd $TMP/$PRGNAM + +cd libpit +./autogen.sh +./configure --prefix=/usr +make + +cd ../heimdall +./autogen.sh +./configure --prefix=/usr +make +make install DESTDIR=$PKG + +cd ../heimdall-frontend/ +qmake heimdall-frontend.pro +make +cd ../Linux/ + +cp heimdall-frontend $PKG$PREFIX/bin/ + +mkdir -p $PKG$PREFIX/doc/$PRGNAM/ +cp README $PKG$PREFIX/doc/$PRGNAM/ + +# correction +cd $PKG +chown -R root:root * + +find $PKG -name \.hg\* -exec rm -fr {} \; + +# Strip binaries +( cd $PKG + find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null + find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null +) + +# embaumement +mkdir -p $PKG/install +cat < $PKG/install/slack-desc +$PRGNAM: $PRGNAM (Samsung Galaxy Note tool) +$PRGNAM: +$PRGNAM: +$PRGNAM: +$PRGNAM: +$PRGNAM: +$PRGNAM: +$PRGNAM: +$PRGNAM: +$PRGNAM: http://github.com/Benjamin-Dobell/Heimdall +$PRGNAM: +EOF + +# empaquetage +cd $PKG +makepkg -l y -c n $OUTPUT/$PRGNAM-$(echo $VERSION | sed 's/-//g')-$ARCH-$BUILD$TAG.txz