libcec: enable build on darwin platform (#445550)

This commit is contained in:
Aaron Andersen
2025-09-30 22:02:01 +00:00
committed by GitHub
2 changed files with 5 additions and 3 deletions
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
# Fix dlopen path
postPatch = ''
substituteInPlace include/cecloader.h --replace "libcec.so" "$out/lib/libcec.so"
substituteInPlace include/cecloader.h --replace "\"libcec." "\"$out/lib/libcec."
'';
nativeBuildInputs = [
@@ -31,9 +31,9 @@ stdenv.mkDerivation rec {
cmake
];
buildInputs = [
udev
libcec_platform
]
++ lib.optional stdenv.hostPlatform.isLinux udev
++ lib.optional withLibraspberrypi libraspberrypi;
cmakeFlags = [
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
description = "Allows you (with the right hardware) to control your device with your TV remote control using existing HDMI cabling";
homepage = "http://libcec.pulse-eight.com";
license = lib.licenses.gpl2Plus;
platforms = platforms.linux;
platforms = platforms.linux ++ platforms.darwin;
teams = [ teams.kodi ];
};
}
@@ -18,6 +18,8 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ cmake ];
cmakeFlags = lib.optional stdenv.hostPlatform.isDarwin "-DCMAKE_CXX_FLAGS='-std=c++11'";
meta = with lib; {
description = "Platform library for libcec and Kodi addons";
homepage = "https://github.com/Pulse-Eight/platform";