refactor: Several random fixes + Experimental playground (#917)

This commit is contained in:
Murat Seker
2020-08-02 22:37:52 +02:00
committed by GitHub
parent d183c630c8
commit b7a9a10223
13 changed files with 130 additions and 96 deletions

View File

@@ -1,24 +1,46 @@
#!/bin/sh
# exit on error
set -e
TARGET=${1:-hyperion}
CFG="${2:-Release}"
INST="$( [ "${3:-}" = "install" ] && echo true || echo false )"
sudo apt-get update
sudo apt-get install git cmake build-essential qtbase5-dev libqt5serialport5-dev libusb-1.0-0-dev libturbojpeg0-dev python3-dev libcec-dev libxcb-util0-dev libxcb-randr0-dev libxrandr-dev libxrender-dev libavahi-core-dev libavahi-compat-libdnssd-dev libssl-dev libjpeg-dev libqt5sql5-sqlite zlib1g-dev || exit 1
sudo apt-get install \
git \
cmake \
build-essential \
qtbase5-dev \
libqt5serialport5-dev \
libusb-1.0-0-dev \
libturbojpeg0-dev \
python3-dev \
libcec-dev \
libxcb-util0-dev \
libxcb-randr0-dev \
libxrandr-dev \
libxrender-dev \
libavahi-core-dev \
libavahi-compat-libdnssd-dev \
libssl-dev \
libjpeg-dev \
libqt5sql5-sqlite \
zlib1g-dev \
if [ -e /dev/vc-cma -a -e /dev/vc-mem ]
then
sudo apt-get install libraspberrypi-dev || exit 1
sudo apt-get install libraspberrypi-dev
fi
git clone --recursive https://github.com/hyperion-project/hyperion.ng.git ${TARGET} || exit 1
git clone --recursive https://github.com/hyperion-project/hyperion.ng.git ${TARGET}
rm -rf $TARGET/build
mkdir -p $TARGET/build || exit 1
cd $TARGET/build || exit 1
cmake -DCMAKE_BUILD_TYPE=$CFG .. || exit 1
make -j $(nproc) || exit 1
rm -rf $TARGET/build
mkdir -p $TARGET/build
cd $TARGET/build
cmake -DCMAKE_BUILD_TYPE=$CFG ..
make -j $(nproc)
# optional: install into your system
$INST && sudo make install/strip

View File

@@ -97,9 +97,9 @@ if [ $OS_OPENELEC -eq 1 ]; then
echo '---> Remove the OpenELEC Hyperion binaries and hyperion.config.json'
rm -rv /storage/hyperion 2>/dev/null
rm -v /storage/.config/hyperion.config.json 2>/dev/null
else
else
#Remove binaries on all distributions/systems (not OpenELEC)
echo "---> Remove links to the binaries"
echo "---> Remove links to the binaries"
rm -v /usr/bin/hyperiond 2>/dev/null
rm -v /usr/bin/hyperion-remote 2>/dev/null
rm -v /usr/bin/hyperion-v4l2 2>/dev/null
@@ -112,8 +112,8 @@ else
rm -rv /etc/hyperion 2>/dev/null
rm -rv /usr/share/hyperion 2>/dev/null
fi
echo '*******************************************************************************'
echo '*******************************************************************************'
echo 'Hyperion successful removed!'
echo '*******************************************************************************'
echo '*******************************************************************************'
exit 0