LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 12-30-2017, 03:10 PM   #16
dugan
LQ Guru
 
Registered: Nov 2003
Location: Canada
Distribution: distro hopper
Posts: 11,244

Rep: Reputation: 5322Reputation: 5322Reputation: 5322Reputation: 5322Reputation: 5322Reputation: 5322Reputation: 5322Reputation: 5322Reputation: 5322Reputation: 5322Reputation: 5322

I just knocked up (well, not "knocked up"; I wrote it with a level of care appropriate for one of the programs I use the most) a SlackBuild that uses mpv_build to build a pkgtools-managed package. With the manpage, documentation, etc. I just used it to build 0.28 on -current. Is everything good now?

https://github.com/duganchen/my_slac...mpv.SlackBuild

Code:
#!/usr/bin/env bash

set -e

TMP=${TMP:-/tmp}
PKG="$TMP/package-mpv"
BUILD=${BUILD:-1}
TAG=${TAG:-dc}
SBO="${SBO:-https://raw.githubusercontent.com/Ponce/slackbuilds/master/multimedia/mpv}"

cd "$TMP"
rm -rf mpv-build package-mpv
git clone https://github.com/mpv-player/mpv-build
cd mpv-build
./use-mpv-release
cat << EOF > mpv_options
--prefix=/usr
--confdir=/etc/mpv
--mandir=/usr/man
--docdir=/usr/doc/mpv
EOF
./rebuild -j"$(nproc)"
cd mpv
VERSION="$(git describe --tags | cut -c 2-)"
./waf --destdir="$PKG" install

find "$PKG" -print0 | xargs -0 file | grep -e "executable" -e "shared object" \
  | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true

gzip -9 "$PKG/usr/man/man1/mpv.1"
ETC="$PKG/etc/mpv"
mv "$ETC/encoding-profiles.conf" "$ETC/encoding-profiles.conf.new"
DOC="$PKG/usr/doc"
DOCDIR="$DOC/mpv-$VERSION"
mv "$DOC/mpv" "$DOCDIR"
cp -a DOCS "$DOCDIR"
INSTALL="$PKG/install"
mkdir "$INSTALL"
wget -O "$INSTALL/doinst.sh" "$SBO/doinst.sh"
wget -O "$INSTALL/slack-desc" "$SBO/slack-desc"
cd "$PKG"
ARCH="$(uname -r)"
/sbin/makepkg -l y -c n "$TMP/mpv-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}"

Last edited by dugan; 12-30-2017 at 03:25 PM.
 
2 members found this post helpful.
Old 12-31-2017, 01:17 AM   #17
1337_powerslacker
Member
 
Registered: Nov 2009
Location: Kansas, USA
Distribution: Slackware64-15.0
Posts: 862

Original Poster
Blog Entries: 9

Rep: Reputation: 592Reputation: 592Reputation: 592Reputation: 592Reputation: 592Reputation: 592
Quote:
Originally Posted by dugan View Post
I just knocked up (well, not "knocked up"; I wrote it with a level of care appropriate for one of the programs I use the most) a SlackBuild that uses mpv_build to build a pkgtools-managed package. With the manpage, documentation, etc. I just used it to build 0.28 on -current. Is everything good now?
Oh, yes! I used your SlackBuild to good effect, and as a side benefit, this makes for a great birthday gift, since yesterday was my birthday. Thanks again!
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
icu4c package upgrade in -current mpv breakage & fix 1337_powerslacker Slackware 4 12-08-2017 09:39 AM
How do I compile gnome-mpv? linuxs64 Slackware 6 07-04-2017 02:26 AM
Slackware Current: WindowMaker/X11 woes with Steam and MPV Xylemon Slackware 7 01-05-2016 08:29 AM
[SOLVED] mpv's interface moisespedro Slackware 8 12-05-2014 03:14 PM
animated gif to .mpv frieza Linux - Software 1 12-05-2007 05:09 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 12:41 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration