Browse Source

xap/obs-studio: Bundle the v4l2sink plugin.

current-20200608
Damien Goutte-Gattat 2 months ago
parent
commit
a6f04deddd
2 changed files with 27 additions and 1 deletions
  1. +26
    -1
      xap/obs-studio/obs-studio.SlackBuild
  2. +1
    -0
      xap/obs-studio/obs-v4l2sink-0.1.0.tar.gz.sha256

+ 26
- 1
xap/obs-studio/obs-studio.SlackBuild View File

@ -33,9 +33,13 @@ VERSION=${VERSION:-26.0.2}
ARCHIVE=${ARCHIVE:-$NAMESRC-$VERSION.tar.gz}
WGET=${WGET:-https://github.com/obsproject/obs-studio/archive/$VERSION.tar.gz}
V4L2SINK_VERSION=${V4L2SINK_VERSION:-0.1.0}
V4L2SINK_ARCHIVE=${V4L2SINK_ARCHIVE:-obs-v4l2sink-$V4L2SINK_VERSION.tar.gz}
V4L2SINK_WGET=${V4L2SINK_WGET:-https://github.com/CatxFish/obs-v4l2sink/archive/$V4L2SINK_VERSION.tar.gz}
# Build infos
NAMEPKG=${NAMEPKG:-obs-studio}
BUILD=${BUILD:-1GGD}
BUILD=${BUILD:-2GGD}
ARCH=${ARCH:-$(uname -m | sed 's/^i.86$/i486/;s/^arm.*/arm/')}
JOBS=${JOBS:-1}
EXT=${EXT:-txz}
@ -66,7 +70,12 @@ if [ ! -r $ARCHIVE ]; then
wget -c -O $ARCHIVE.part "$WGET"
mv $ARCHIVE.part $ARCHIVE
fi
if [ ! -r $V4L2SINK_ARCHIVE ]; then
wget -c -O $V4L2SINK_ARCHIVE.part "$V4L2SINK_WGET"
mv $V4L2SINK_ARCHIVE.part $V4L2SINK_ARCHIVE
fi
sha256sum -c $ARCHIVE.sha256
sha256sum -c $V4L2SINK_ARCHIVE.sha256
NAME=$(tar ft $ARCHIVE | head -n 1 | cut -d / -f 1)
# Compile
@ -94,6 +103,22 @@ if sphinx-build -b html docs/sphinx $PKG/usr/doc/$NAME/html ; then
rm -rf $PKG/usr/doc/$NAME/html/.{buildinfo,doctrees}
fi
# Compile the V4L2sink plugin
tar xf $CWD/$V4L2SINK_ARCHIVE
cd obs-v4l2sink-$V4L2SINK_VERSION
mkdir build && cd build
if [ "x$ARCH" = xx86_64 ]; then
sed -i "s,/lib/obs-plugins,/lib$LIBDIRSUFFIX/obs-plugins," ../CMakeLists.txt
fi
cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DLIBOBS_INCLUDE_DIR=../../libobs \
-DCMAKE_BUILD_TYPE=Release \
..
make -j $JOBS
make install/strip DESTDIR=$PKG
install -m 644 ../README.md $PKG/usr/doc/$NAME/README_v4l2sink.md
# Copy slack-desc and doinst.sh files
install -D -m 644 $CWD/slack-desc $PKG/install/slack-desc
install -m 755 $CWD/doinst.sh $PKG/install/doinst.sh


+ 1
- 0
xap/obs-studio/obs-v4l2sink-0.1.0.tar.gz.sha256 View File

@ -0,0 +1 @@
83e9bb104dcc3840acd17ebc0810de30c8de27545d4ef181d58f8a375dba06d4 obs-v4l2sink-0.1.0.tar.gz

Loading…
Cancel
Save