alarm/kodi-rbp-git: update to 17.0rc3.20170114-1 (#1440)

This commit is contained in:
graysky 2017-01-15 12:29:58 -05:00 committed by Oleg Rakhmanov
parent a8b0ec04a0
commit 9c50183c1a

View file

@ -1,3 +1,5 @@
# Contributor graysky <graysky AT archlinux DOT org>
# Contributor BlackIkeEagle < ike DOT devolder AT gmail DOT com >
# Contributor Oleg Rakhmanov <oleg [at] archlinuxarm [dot] com>
# Contributor tomasgroth at yahoo.dk
# Contributor WarheadsSE <max@warheads.net>
@ -8,12 +10,11 @@ buildarch=20
_prefix=/usr
pkgbase=kodi-rbp-git
pkgname=('kodi-rbp-git' 'kodi-rbp-git-eventclients')
pkgver=17.0rc2.20170101
_tag=17.0rc2-Krypton
pkgrel=2
pkgdesc="A software media player and entertainment hub for digital media for the Raspberry Pi"
_suffix=rbp-git
pkgname=("kodi-$_suffix" "kodi-eventclients-$_suffix" "kodi-tools-texturepacker-$_suffix" "kodi-dev-$_suffix")
pkgver=17.0rc3.20170114
_tag=17.0rc3-Krypton
pkgrel=1
arch=('armv6h' 'armv7h')
url="http://kodi.tv"
license=('GPL2')
@ -30,7 +31,7 @@ source=("xbmc-$_tag.tar.gz::https://github.com/xbmc/xbmc/archive/$_tag.tar.gz"
'https://github.com/popcornmix/xbmc/commit/0c320b6cdd4fb409be45008e6b9042463d54b742.patch'
'https://github.com/popcornmix/xbmc/commit/4d983105d7fd65b1d92f2ae2602e6e1cdcaddbe0.patch'
'polkit.rules')
sha256sums=('6bd03e0e26251972c2237d5ca25ab3c292f9a88e4ee02b798d9f89360e8ac522'
sha256sums=('b285ac8fd75a8876dd55103e0764ad533f8bd95d1bf33ddf8b24500ce7a86c56'
'5235068d5800d69f0287087815990e7fe8d6572733d60c8800546d35f608e87f'
'b31570f95654434b01fd8531612fbb6be77cbc1c519dd60f92feae26eb160f3d'
'813f8c622c341eefb33774115199d2abe9c189cf2ce52e79719dbd42d48a1274'
@ -45,95 +46,87 @@ prepare() {
# hacky fix for files with GMC
patch -Np1 -i "$srcdir/4d983105d7fd65b1d92f2ae2602e6e1cdcaddbe0.patch"
find -type f -name *.py -exec sed 's|^#!.*python$|#!/usr/bin/python2|' -i "{}" +
sed 's|^#!.*python$|#!/usr/bin/python2|' -i tools/depends/native/rpl-native/rpl
sed 's/python/python2/' -i tools/Linux/kodi.sh.in
sed 's/shell python/shell python2/' -i tools/EventClients/Makefile.in
# disable wiiremote due to incompatibility with bluez-5.29
sed '/WiiRemote/d' -i tools/EventClients/Makefile.in
sed '/mkdir -p $(DESTDIR)$(bindir)/i \
install:' -i tools/EventClients/Makefile.in
[[ -d kodi-build ]] && rm -rf kodi-build
mkdir $srcdir/kodi-build
}
build() {
cd "$srcdir/xbmc-$_tag"
cd "kodi-build"
# Bootstrapping
MAKEFLAGS=-j1 ./bootstrap
# -DCPU=arm1176jzf-s for rpi1
# -DCPU=cortex-a7 for rpi2
# -DCPU=cortex-a53 for rpi3
# Configuring Kodi
export PYTHON_VERSION=2 # external python v2
# we need to compile for armv6 instead of armv5 to avoid problems compiling assembler code
FLAGS="-Ofast -fexcess-precision=fast -mfloat-abi=hard -mabi=aapcs-linux -pipe -fstack-protector --param=ssp-buffer-size=4 -D_GLIBCXX_USE_CXX11_ABI=1 \
-I/opt/vc/include/ -I/opt/vc/include/IL -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux"
[[ $CARCH == "armv6h" ]] && export CFLAGS="$FLAGS -mcpu=arm1176jzf-s -mtune=arm1176jzf-s -mfpu=vfp" && export CXXFLAGS="$FLAGS -mcpu=arm1176jzf-s -mtune=arm1176jzf-s -mfpu=vfp"
[[ $CARCH == "armv7h" ]] && export CFLAGS="$FLAGS -mcpu=cortex-a7 -mtune=cortex-a7 -mfpu=neon-vfpv4 -mvectorize-with-neon-quad" && export CXXFLAGS="$FLAGS -mcpu=cortex-a7 -mtune=cortex-a7 -mfpu=neon-vfpv4 -mvectorize-with-neon-quad"
[[ $CARCH == "armv6h" ]] && _CPU=arm1176jzf-s
[[ $CARCH == "armv7h" ]] && _CPU=cortex-a7
export LDFLAGS="$LDFLAGS -L/opt/vc/lib"
cmake -DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=/usr/lib \
-DCMAKE_PREFIX_PATH=/opt/vc \
-DCORE_SYSTEM_NAME=rbpi \
-DWITH_CPU="$_CPU" \
-DENABLE_EVENTCLIENTS=ON \
-DENABLE_OPENGL=OFF \
-DENABLE_X11=OFF \
-DENABLE_VAAPI=OFF \
-DENABLE_VDPAU=OFF \
-DLIRC_DEVICE=/run/lirc/lircd \
../"xbmc-$_tag"/project/cmake
# If build fails try uncommenting the line below first
# export MAKEFLAGS="-j1"
./configure --prefix=$_prefix --exec-prefix=$_prefix \
--with-platform=raspberry-pi \
--disable-gl \
--enable-gles \
--disable-x11 \
--disable-vaapi \
--disable-vdpau \
--disable-debug \
--disable-mid \
--enable-player=omxplayer \
--with-lirc-device=/run/lirc/lircd \
ac_cv_lib_bluetooth_hci_devid=no
make
make VERBOSE=1
make preinstall
}
package_kodi-rbp-git() {
pkgdesc="A software media player and entertainment hub for digital media (Raspberry Pi)"
# depends expected for kodi plugins:
# 'python2-pillow' 'python2-pybluez' 'python2-simplejson'
# depends expeced in FEH.py
# 'mesa-demos' 'xorg-xdpyinfo'
depends=('hicolor-icon-theme' 'fribidi' 'lzo2' 'smbclient' 'libtiff' 'libva' 'libpng' 'libcdio'
'yajl' 'libmariadbclient' 'libjpeg-turbo' 'libsamplerate' 'libssh' 'libmicrohttpd'
'sdl_image' 'python2' 'python2-pillow' 'python2-pybluez' 'python2-simplejson' 'libass'
'libmpeg2' 'libmad' 'libmodplug' 'jasper' 'rtmpdump' 'unzip' 'xorg-xdpyinfo' 'libbluray'
'libnfs' 'avahi' 'bluez-libs' 'tinyxml' 'raspberrypi-firmware'
'avahi' 'bluez-libs' 'tinyxml' 'raspberrypi-firmware'
'libplist' 'swig' 'taglib' 'libxslt' 'shairplay' 'libcrossguid-git')
optdepends=(
'afpfs-ng: Apple shares support'
'libcec-rpi: Pulse-Eight USB-CEC adapter support'
'libnfs: NFS shares support'
'lirc: remote controller support'
'lsb-release: log distro information in crashlog'
'polkit: permissions for automounting external drives and power management functionality'
'udisks: automount external drives'
'upower: used to trigger power management functionality'
'unrar: access compressed files without unpacking them'
'lsb-release: log distro information in crashlog')
'unzip: access compressed files without unpacking them'
'upower: used to trigger power management functionality')
install='kodi.install'
provides=('xbmc' 'kodi')
conflicts=('xbmc' 'kodi' 'arm-mem-git' 'shairplay-git')
replaces=('xbmc-rbp-git')
cd "$srcdir/xbmc-$_tag"
# Running make install
make DESTDIR="$pkgdir" install
_components=(
'kodi'
'kodi-bin'
)
# We will no longer support the xbmc name
rm "$pkgdir/usr/share/xsessions/xbmc.desktop"
rm "$pkgdir/usr/bin/"xbmc{,-standalone}
# we will leave /usr/{include,lib,share}/xbmc for now
cd kodi-build
# install eventclients
for _cmp in ${_components[@]}; do
DESTDIR="$pkgdir" /usr/bin/cmake \
-DCMAKE_INSTALL_COMPONENT="$_cmp" \
-P cmake_install.cmake
done
# Licenses
install -dm0755 "$pkgdir$_prefix/share/licenses/$pkgname"
install -dm755 ${pkgdir}/usr/share/licenses/${pkgname}
for licensef in LICENSE.GPL copying.txt; do
mv "$pkgdir$_prefix/share/doc/kodi/$licensef" "$pkgdir$_prefix/share/licenses/$pkgname"
mv ${pkgdir}/usr/share/doc/kodi/${licensef} \
${pkgdir}/usr/share/licenses/${pkgname}
done
# python2 is being used
cd "$pkgdir"
grep -lR '#!.*python' * | while read file; do sed -s 's/\(#!.*python\)/\12/g' -i "$file"; done
install -Dm0644 "$srcdir/kodi.service" "$pkgdir/usr/lib/systemd/system/kodi.service"
install -Dm0644 "$srcdir/polkit.rules" "$pkgdir/usr/share/polkit-1/rules.d/10-kodi.rules"
chmod 0700 "$pkgdir/usr/share/polkit-1/rules.d/"
@ -142,13 +135,78 @@ package_kodi-rbp-git() {
install -Dm0644 "$srcdir/99-kodi.rules" "$pkgdir/etc/udev/rules.d/99-kodi.rules"
}
package_kodi-rbp-git-eventclients() {
pkgdesc="Kodi Event Clients (Raspberry Pi)"
provides=('kodi-eventclients')
package_kodi-eventclients-rbp-git() {
pkgdesc="Kodi Event Clients (master branch)"
conflicts=('kodi-eventclients')
depends=('cwiid')
cd "$srcdir/xbmc-$_tag"
# disable wiiremote due to incompatibility with bluez-5.29
_components=(
'kodi-eventclients-common'
'kodi-eventclients-ps3'
#'kodi-eventclients-wiiremote'
'kodi-eventclients-xbmc-send'
)
make DESTDIR="$pkgdir" eventclients WII_EXTRA_OPTS=-DCWIID_OLD
cd kodi-build
# install eventclients
for _cmp in ${_components[@]}; do
DESTDIR="$pkgdir" /usr/bin/cmake \
-DCMAKE_INSTALL_COMPONENT="$_cmp" \
-P cmake_install.cmake
done
# python2 is being used
cd "$pkgdir"
grep -lR '#!.*python' * | while read file; do sed -s 's/\(#!.*python\)/\12/g' -i "$file"; done
}
# kodi-tools-texturepacker
# components: kodi-tools-texturepacker
package_kodi-tools-texturepacker-rbp-git() {
pkgdesc="Kodi Texturepacker tool (master branch)"
depends=('libpng' 'giflib' 'libjpeg-turbo' 'lzo')
_components=(
'kodi-tools-texturepacker'
)
cd kodi-build
# install eventclients
for _cmp in ${_components[@]}; do
DESTDIR="$pkgdir" /usr/bin/cmake \
-DCMAKE_INSTALL_COMPONENT="$_cmp" \
-P cmake_install.cmake
done
}
package_kodi-dev-rbp-git() {
pkgdesc="Kodi dev files (master branch)"
depends=('kodi')
_components=(
'kodi-addon-dev'
'kodi-audio-dev'
'kodi-eventclients-dev'
'kodi-game-dev'
'kodi-inputstream-dev'
'kodi-peripheral-dev'
'kodi-pvr-dev'
'kodi-screensaver-dev'
'kodi-visualization-dev'
)
cd kodi-build
# install eventclients
for _cmp in ${_components[@]}; do
DESTDIR="$pkgdir" /usr/bin/cmake \
-DCMAKE_INSTALL_COMPONENT="$_cmp" \
-P cmake_install.cmake
done
# python2 is being used
cd "$pkgdir"
grep -lR '#!.*python' * | while read file; do sed -s 's/\(#!.*python\)/\12/g' -i "$file"; done
}