Skip to content

Instantly share code, notes, and snippets.

Created November 20, 2017 15:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/1268649174f8141bbee3f0bdee651d05 to your computer and use it in GitHub Desktop.
Save anonymous/1268649174f8141bbee3f0bdee651d05 to your computer and use it in GitHub Desktop.
PKGBUILD
# Maintainer: Jose Riha <jose1711 gmail com>
# Contributor: archdaemon
pkgname=untrunc-git
pkgver=r46.06ee3da
pkgrel=1
pkgdesc="restore a damaged (truncated) mp4, m4v, mov, 3gp video"
arch=('x86_64' 'i686')
url="https://github.com/ponchio/untrunc"
license=('GPL2')
depends=()
makedepends=()
source=(
"${pkgname}"::'git+https://github.com/ponchio/untrunc.git'
http://libav.org/releases/libav-12.2.tar.xz
)
md5sums=('SKIP'
'69b5d9de6e4b2fbf6956653f61c7ffe1')
build() {
cd $srcdir/libav-12.2
./configure --disable-bzlib --disable-vdpau --disable-libxcb-shm --disable-libxcb-xfixes --disable-zlib --disable-outdevs --disable-hwaccels --enable-nonfree --enable-gpl --enable-version3 --disable-programs --disable-doc
make
cd $srcdir/$pkgname
g++ -o untrunc file.cpp main.cpp track.cpp atom.cpp mp4.cpp -I../libav-12.2 -L../libav-12.2/libavformat -lavformat -L../libav-12.2/libavcodec -lavcodec -L../libav-12.2/libavresample -lavresample -L../libav-12.2/libavutil -lavutil -lpthread
}
pkgver() {
cd "$srcdir/${pkgname}"
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
package() {
install -Dm755 $srcdir/$pkgname/untrunc $pkgdir/usr/bin/untrunc
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment