1
0
forked from ports/contrib
contrib-tek/kodi/Pkgfile

45 lines
1.5 KiB
Plaintext

# Description: A free and open source software media player and entertainment hub
# URL: https://kodi.tv/
# Maintainer: Matt Housh, jaeger at crux dot ninja
# Depends on: libass libcdio libdvdnav libmicrohttpd libva libvdpau mariadb mesa openjdk21-jdk samba spdlog swig taglib tinyxml tinyxml2
name=kodi
version=21.1
release=1
source=(https://github.com/xbmc/xbmc/archive/$version-Omega/$name-$version.tar.gz
25863.patch)
build() {
export PATH="/usr/lib/java/openjdk21-jdk/bin:$PATH"
[[ -e /usr/lib/ccache ]] && PATH="$(echo ${PATH} | awk -v RS=: -v ORS=: '/ccache/ {next} {print}' | sed 's/:*$//')"
sed -i -e 's,EGL/eglextchromium.h,EGL/eglext_angle.h,g' xbmc-$version-Omega/xbmc/windowing/X11/GLContextEGL.h
patch -d xbmc-$version-Omega -p1 -i $SRC/25863.patch
cmake -Bbuild \
-DVERBOSE=ON \
-DAPP_RENDER_SYSTEM=gl \
-DCORE_PLATFORM_NAME=x11 \
-DENABLE_DVDCSS=ON \
-DENABLE_OPTICAL=ON \
-DENABLE_PYTHON=ON \
-DENABLE_INTERNAL_FFMPEG=ON \
-DENABLE_INTERNAL_FLATBUFFERS=ON \
-DENABLE_INTERNAL_FSTRCMP=ON \
-DENABLE_INTERNAL_RapidJSON=ON \
-DENABLE_TESTING=OFF \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=/usr/lib \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_FLAGS_RELEASE="$CFLAGS -DNDEBUG" \
-DCMAKE_CXX_FLAGS_RELEASE="$CXXFLAGS -DNDEBUG" \
-Wno-dev \
xbmc-$version-Omega
cmake --build build
DESTDIR=$PKG cmake --install build
find $PKG -name "README*" -delete
}