Commit ccfb3966 authored by fkardame's avatar fkardame 💬

Initiate PKG

parents
# vim:set ts=2 sw=2 et:
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Maintainer: BlackIkeEagle < ike DOT devolder AT gmail DOT com >
# Contributor: graysky <graysky AT archlinux DOT us>
# Contributor: DonVla <donvla@users.sourceforge.net>
# Contributor: Ulf Winkelvos <ulf [at] winkelvos [dot] de>
# Contributor: Ralf Barth <archlinux dot org at haggy dot org>
# Contributor: B & monty - Thanks for your hints :)
# Contributor: marzoul
# Contributor: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Brad Fanella <bradfanella@archlinux.us>
# Contributor: [vEX] <niechift.dot.vex.at.gmail.dot.com>
# Contributor: Zeqadious <zeqadious.at.gmail.dot.com>
# Contributor: Bartłomiej Piotrowski <bpiotrowski@archlinux.org>
# Contributor: Maxime Gauduin <alucryd@gmail.com>
# Maintainer: Furkan Kardame <furkan@fkardame.com>
# Original credits go to Edgar Hucek <gimli at dark-green dot com>
# for his xbmc-vdpau-vdr PKGBUILD at https://archvdr.svn.sourceforge.net/svnroot/archvdr/trunk/archvdr/xbmc-vdpau-vdr/PKGBUILD
pkgbase=kodi
pkgname=(
'kodi' 'kodi-bin'
'kodi-eventclients' 'kodi-tools-texturepacker' 'kodi-dev'
)
pkgver=18.6
pkgrel=1
arch=('aarch64')
url="https://kodi.tv"
license=('GPL2')
makedepends=(
'afpfs-ng' 'bluez-libs' 'cmake' 'curl' 'doxygen' 'glew'
'gperf' 'hicolor-icon-theme' 'java-runtime' 'libaacs' 'libass'
'libbluray' 'libcdio' 'libcec' 'libgl' 'mariadb-libs' 'libmicrohttpd'
'libmodplug' 'libmpeg2' 'libnfs' 'libplist' 'libpulse' 'libva'
'libvdpau' 'libxrandr' 'libxslt' 'lirc' 'lzo' 'mesa' 'nasm'
'python2-pycryptodomex' 'python2-pillow' 'python2-pybluez'
'python2-simplejson' 'shairplay' 'smbclient' 'taglib' 'tinyxml' 'swig'
'upower' 'giflib' 'rapidjson' 'ghostscript'
)
_codename=Leia
_libdvdcss_version="1.4.2-$_codename-Beta-5"
_libdvdnav_version="6.0.0-$_codename-Alpha-3"
_libdvdread_version="6.0.0-$_codename-Alpha-3"
_ffmpeg_version="4.0.4-$_codename-18.4"
_fmt_version="5.1.0"
_crossguid_version="8f399e8bd4"
_fstrcmp_version="0.7.D001"
_flatbuffers_version="1.9.0"
source=(
"$pkgbase-$pkgver-$_codename.tar.gz::https://github.com/xbmc/xbmc/archive/$pkgver-$_codename.tar.gz"
"$pkgbase-libdvdcss-$_libdvdcss_version.tar.gz::https://github.com/xbmc/libdvdcss/archive/$_libdvdcss_version.tar.gz"
"$pkgbase-libdvdnav-$_libdvdnav_version.tar.gz::https://github.com/xbmc/libdvdnav/archive/$_libdvdnav_version.tar.gz"
"$pkgbase-libdvdread-$_libdvdread_version.tar.gz::https://github.com/xbmc/libdvdread/archive/$_libdvdread_version.tar.gz"
"$pkgbase-ffmpeg-$_ffmpeg_version.tar.gz::https://github.com/xbmc/FFmpeg/archive/$_ffmpeg_version.tar.gz"
"$pkgbase-fmt-$_fmt_version.tar.gz::http://mirrors.kodi.tv/build-deps/sources/fmt-$_fmt_version.tar.gz"
"$pkgbase-crossguid-$_crossguid_version.tar.gz::http://mirrors.kodi.tv/build-deps/sources/crossguid-$_crossguid_version.tar.gz"
"$pkgbase-fstrcmp-$_fstrcmp_version.tar.gz::http://mirrors.kodi.tv/build-deps/sources/fstrcmp-$_fstrcmp_version.tar.gz"
"$pkgbase-flatbuffers-$_flatbuffers_version.tar.gz::http://mirrors.kodi.tv/build-deps/sources/flatbuffers-$_flatbuffers_version.tar.gz"
'cheat-sse-build.patch'
'cpuinfo'
)
noextract=(
"$pkgbase-libdvdcss-$_libdvdcss_commit.tar.gz"
"$pkgbase-libdvdnav-$_libdvdnav_commit.tar.gz"
"$pkgbase-libdvdread-$_libdvdread_commit.tar.gz"
"$pkgbase-ffmpeg-$_ffmpeg_version.tar.gz"
"$pkgbase-fmt-$_fmt_version.tar.gz"
"$pkgbase-crossguid-$_crossguid_version.tar.gz"
"$pkgbase-fstrcmp-$_fstrcmp_version.tar.gz"
"$pkgbase-flatbuffers-$_flatbuffers_version.tar.gz"
)
sha512sums=('9dffb052e0adf7c838ace178dd1e0e7b5fb02f01d43f90e22aa7d225bc67496586daab9bed2d20c1aaca34d4e69a9973fec5065f5076def2eb32da630d9cb67d'
'5185dbdbeb1bd13ea9d8723f1f4ab599d6f3102f5ba1096cd085aa1cda252c045f327c719227bba8e1b742352ade5e335106c8d0c1637a5a6b93ce661620dd7e'
'11c93eaacd156f8fd7dec7c43d366438b201f31ad55b2870463a9e286912b6ada08882319a021fb7992190f87b909a49f2b83e0321cc17aedc29f7fe5898fa72'
'b3419ba0a1a2dd70f1bb6236afdfe1c6e88c9ad4264198b289e3bba9375e077cecf7f89848c7b09debaa445327f3507101f3d157e692f7a7163b2bb52643e1e7'
'c6dd75dbff7119adeeda246cfb640b5e8d3b4c242ef83e5ba070207b60f0c715c3fe3cb328d87687b70a133f122a03aba990f0e95f3aac7d5dbcee25bec59078'
'b759a718353254fa8cd981e483bf01a45af0fc76901216404ace5e47f5d3edf43d42422184e5413c221e49832322fdf60d1860e8ec87349c674511064b31e5d6'
'2682d63609d3dcdfcd8136be632e45df26ad88ce93b9c49745cf728bbd2e6254a7b05c8b059ab581d532372e504206a525a52564b64d076dfdae9c965a09fd16'
'aaeb0227afd5ada5955cbe6a565254ff88d2028d677d199c00e03b7cb5de1f2c69b18e6e8b032e452350a8eda7081807b01765adbeb8476eaf803d9de6e5509c'
'0ba07dbe5b2fde1d0a6e14ee26ee2816062541d934eda204b846a30c019362f2626761b628c900293928b9b546dba8ca477c13182e022c3e0e0a142fd67f0696'
'8a238b949574e06cd60cb71202293bc73b317a0e062a2e928ee98eea364ee4b1dc6eac8dfa04a9688d2f79065ffe14b9f54f8dc720154faaceb48bf4ef45e144'
'ab99a02161b369ae8dddae38a14bd969ed58e8c9adf0a4a78a04067c7fedfd3ab5472cbf7d051056738274cf74407a5e8143b8ae35cb60ee67b74df653119316')
prepare() {
# force python 'binary' as python2
[[ -d "$srcdir/path" ]] && rm -rf "$srcdir/path"
mkdir "$srcdir/path"
ln -s /usr/bin/python2 "$srcdir/path/python"
[[ -d kodi-build-x11 ]] && rm -rf kodi-build-x11
mkdir kodi-build-x11
cd "xbmc-$pkgver-$_codename"
# detect if building in arch chroot
if [[ "$srcdir" =~ ^\/build.* ]]; then
patch -p1 -i "$srcdir/cheat-sse-build.patch"
fi
}
build() {
export PATH="$srcdir/path:$PATH"
msg2 "building kodi-x11"
cd "$srcdir/kodi-build-x11"
cmake -DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=/usr/lib \
-DENABLE_EVENTCLIENTS=ON \
-DENABLE_INTERNAL_FFMPEG=OFF \
-DENABLE_INTERNAL_FMT=ON \
-DENABLE_INTERNAL_CROSSGUID=ON \
-DENABLE_INTERNAL_FSTRCMP=ON \
-DENABLE_INTERNAL_FLATBUFFERS=ON \
-DWITH_FFMPEG=SHARED \
-DENABLE_GL=OFF \
-DENABLE_GLES=ON \
-DENABLE_VAAPI=OFF \
-DENABLE_VDPAU=OFF \
-Dlibdvdcss_URL="$srcdir/$pkgbase-libdvdcss-$_libdvdcss_version.tar.gz" \
-Dlibdvdnav_URL="$srcdir/$pkgbase-libdvdnav-$_libdvdnav_version.tar.gz" \
-Dlibdvdread_URL="$srcdir/$pkgbase-libdvdread-$_libdvdread_version.tar.gz" \
-DFFMPEG_URL="$srcdir/$pkgbase-ffmpeg-$_ffmpeg_version.tar.gz" \
-DFMT_URL="$srcdir/$pkgbase-fmt-$_fmt_version.tar.gz" \
-DCROSSGUID_URL="$srcdir/$pkgbase-crossguid-$_crossguid_version.tar.gz" \
-DFSTRCMP_URL="$srcdir/$pkgbase-fstrcmp-$_fstrcmp_version.tar.gz" \
-DFLATBUFFERS_URL="$srcdir/$pkgbase-flatbuffers-$_flatbuffers_version.tar.gz" \
../"xbmc-$pkgver-$_codename"
make
make preinstall
}
# kodi
# components: kodi
package_kodi() {
pkgdesc="A software media player and entertainment hub for digital media"
depends=(
'desktop-file-utils' 'hicolor-icon-theme' 'mesa' 'python2-pycryptodomex'
'python2-pillow' 'python2-simplejson' 'xorg-xdpyinfo'
'kodi-bin'
)
optdepends=(
'afpfs-ng: Apple shares support'
'bluez: Blutooth support'
'python2-pybluez: Bluetooth support'
'libplist: AirPlay support'
'pulseaudio: PulseAudio support'
'shairplay: AirPlay support'
'upower: Display battery level'
)
provides=('xbmc')
conflicts=('xbmc')
replaces=('xbmc')
_components=(
'kodi'
'kodi-bin'
)
export PATH="$srcdir/path:$PATH"
cd kodi-build-x11
# 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
# remove x11 binaries
rm "$pkgdir/usr/lib/kodi/"{kodi-x11,kodi-xrandr}
}
# kodi-x11
# components: kodi-bin
package_kodi-bin() {
pkgdesc="x11 kodi binary"
depends=(
'bluez-libs' 'curl' 'lcms2' 'libass' 'libbluray' 'libcdio' 'libcec'
'libmicrohttpd' 'libnfs' 'libpulse' 'libva' 'libvdpau' 'libxrandr'
'libxslt' 'lirc' 'mariadb-libs' 'python2' 'smbclient' 'taglib'
'tinyxml' 'kodi'
)
cd kodi-build-x11
install -Dm755 kodi-x11 "$pkgdir/usr/lib/kodi/kodi-x11"
install -Dm755 kodi-xrandr "$pkgdir/usr/lib/kodi/kodi-xrandr"
}
# kodi-wayland
# components: kodi-bin
package_kodi-eventclients() {
pkgdesc="Kodi Event Clients"
conflicts=('kodi-eventclients')
optdepends=('python2: most eventclients are implemented in python2')
_components=(
'kodi-eventclients-common'
'kodi-eventclients-ps3'
'kodi-eventclients-kodi-send'
)
export PATH="$srcdir/path:$PATH"
cd kodi-build-x11
# 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() {
pkgdesc="Kodi Texturepacker tool"
depends=('libpng' 'giflib' 'libjpeg-turbo' 'lzo')
_components=(
'kodi-tools-texturepacker'
)
cd kodi-build-x11
# install eventclients
for _cmp in ${_components[@]}; do
DESTDIR="$pkgdir" /usr/bin/cmake \
-DCMAKE_INSTALL_COMPONENT="$_cmp" \
-P cmake_install.cmake
done
}
# kodi-dev
# 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
package_kodi-dev() {
pkgdesc="Kodi dev files"
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'
)
export PATH="$srcdir/path:$PATH"
cd kodi-build-x11
# 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
}
--- a/cmake/modules/FindSSE.cmake 2017-08-22 09:29:22.000000000 +0200
+++ b/cmake/modules/FindSSE.cmake 2018-01-06 19:36:32.716303559 +0100
@@ -4,7 +4,7 @@
if(CMAKE_SYSTEM_NAME MATCHES "Linux")
if(CPU MATCHES "x86_64" OR CPU MATCHES "i.86")
- exec_program(cat ARGS "/proc/cpuinfo" OUTPUT_VARIABLE CPUINFO)
+ exec_program(cat ARGS "/build/kodi/src/cpuinfo" OUTPUT_VARIABLE CPUINFO)
string(REGEX REPLACE "^.*(sse).*$" "\\1" _SSE_THERE ${CPUINFO})
string(COMPARE EQUAL "sse" "${_SSE_THERE}" _SSE_TRUE)
processor : 1
vendor_id : KodiCheat
model name : KodiCheat SSE
flags : sse sse2 pni ssse3 sse4_1 sse4_2 avx avx2
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment