Skip to content

Commit

Permalink
add -h command to build_openpliPC.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
ambrosa committed Dec 18, 2011
1 parent 071232f commit ef4c579
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 34 deletions.
6 changes: 2 additions & 4 deletions README
Expand Up @@ -53,10 +53,8 @@ Some tasks require root access (sudo). You will be asked for your password.
If you are interested to have a logfile , simply do:
./build_openpliPC.sh.sh 2>&1 | tee build_log.log

./build_openpliPC.sh has two command-line options:
./build_openpliPC.sh -b backup E2 config before new E2 build&install
./build_openpliPC.sh -r restore E2 config after new E2 build&install (previously saved with -b)
./build_openpliPC.sh -b -r backup config, build&install E2, restore old config
./build_openpliPC.sh has some command-line options
./build_openpliPC.sh -h to see them


------------------------------
Expand Down
76 changes: 46 additions & 30 deletions build_openpliPC.sh
Expand Up @@ -9,6 +9,7 @@ BACKUP_E2="etc/enigma2 etc/tuxbox/*.xml etc/tuxbox/nim_sockets"

DO_BACKUP=0
DO_RESTORE=0
DO_XINE=1

function e2_backup {
echo "-----------------------------"
Expand All @@ -28,15 +29,37 @@ function e2_restore {
fi
}

function usage {
echo "Usage:"
echo " -b : backup E2 conf file before re-compile"
echo " -r : restore E2 conf file after re-compile"
echo " -x : don't compile xine-lib (compile only enigma2)"
echo " -h : this help"
echo ""
echo "common usage:"
echo " $0 -b -r : make E2 backup, compile E2, restore E2 conf files"
echo ""
}

while [ "$1" != "" ]; do
case $1 in
-b ) DO_BACKUP=1
;;
-r ) DO_RESTORE=1
;;
-b ) DO_BACKUP=1
shift
;;
-r ) DO_RESTORE=1
shift
;;
-x ) DO_XINE=0
shift
;;
-h ) usage
exit
;;
* ) echo "Unknown parameter"
usage
exit
;;
esac
shift
done

if [ "$DO_BACKUP" -eq "1" ]; then
Expand All @@ -45,39 +68,32 @@ fi

# ----------------------------------------------------------------------

# Build and install xine-lib:
PKG="xine-lib"
echo "-----------------------------------------"
echo "configuring OpenPliPC $PKG"
echo "-----------------------------------------"
if [ "$DO_XINE" -eq "1" ]; then

#if [ -d $PKG ]; then
# echo "Erasing older build dir"
# rm -Rf $PKG
# rm -f $PKG*
#fi
#git clone git://projects.vdr-developer.org/$PKG.git
# Build and install xine-lib:
PKG="xine-lib"
echo "-----------------------------------------"
echo "configuring OpenPliPC $PKG"
echo "-----------------------------------------"

cd $PKG
cd $PKG

#git checkout df-osd-handling+alter-vdpau-h264-decoder
#git checkout $XINELIB_REF
#patch -p1 < ../patches/$XINELIB_PATCH
./autogen.sh --disable-xinerama --disable-musepack --prefix=/usr

./autogen.sh --disable-xinerama --disable-musepack --prefix=/usr
echo "-----------------------------------------"
echo "build OpenPliPC $PKG, please wait..."
echo "-----------------------------------------"

echo "-----------------------------------------"
echo "build OpenPliPC $PKG, please wait..."
echo "-----------------------------------------"
make

make
echo "--------------------------------------"
echo "installing OpenPliPC $PKG"
echo "--------------------------------------"

echo "--------------------------------------"
echo "installing OpenPliPC $PKG"
echo "--------------------------------------"
sudo make install
cd ..

sudo make install
cd ..
fi

# ----------------------------------------------------------------------

Expand Down

0 comments on commit ef4c579

Please sign in to comment.