# 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 openjdk20-jdk samba spdlog swig taglib tinyxml tinyxml2 name=kodi version=21.0 release=1 source=(https://github.com/xbmc/xbmc/archive/$version-Omega/$name-$version.tar.gz) build() { export PATH="/usr/lib/java/openjdk20-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 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 }