Merge pull request #168173 from afh/musikcube-darwin

musikcube: fix Darwin build
main
Sandro 2 years ago committed by GitHub
commit 0ce06bcec4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 14
      pkgs/applications/audio/musikcube/0001-apple-cmake.patch
  2. 20
      pkgs/applications/audio/musikcube/default.nix
  3. 4
      pkgs/top-level/all-packages.nix

@ -0,0 +1,14 @@
diff --git a/src/musikcube/CMakeLists.txt b/src/musikcube/CMakeLists.txt
index f42748aa..ae339946 100644
--- a/src/musikcube/CMakeLists.txt
+++ b/src/musikcube/CMakeLists.txt
@@ -98,9 +98,6 @@ else()
endif()
if (APPLE)
- message(STATUS "[ncurses] detected Darwin, linking statically")
- set(CURSES_LIBRARY_NAME "lib${CURSES_LIBRARY_NAME}.a")
- set(PANEL_LIBRARY_NAME "lib${PANEL_LIBRARY_NAME}.a")
else()
message(STATUS "[ncurses] not Darwin! will attempt to link against libtinfo")
find_library(LIBTINFO NAMES tinfo)

@ -1,6 +1,5 @@
{ cmake { cmake
, pkg-config , pkg-config
, alsa-lib
, boost , boost
, curl , curl
, fetchFromGitHub , fetchFromGitHub
@ -11,12 +10,17 @@
, libev , libev
, libmicrohttpd , libmicrohttpd
, ncurses , ncurses
, pulseaudio
, lib , lib
, stdenv , stdenv
, taglib , taglib
# Linux Dependencies
, alsa-lib
, pulseaudio
, systemdSupport ? stdenv.isLinux , systemdSupport ? stdenv.isLinux
, systemd , systemd
# Darwin Dependencies
, Cocoa
, SystemConfiguration
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
@ -38,14 +42,15 @@ stdenv.mkDerivation rec {
url = "https://github.com/clangen/musikcube/commit/1240720e27232fdb199a4da93ca6705864442026.patch"; url = "https://github.com/clangen/musikcube/commit/1240720e27232fdb199a4da93ca6705864442026.patch";
sha256 = "0bhjgwnj6d24wb1m9xz1vi1k9xk27arba1absjbcimggn54pinid"; sha256 = "0bhjgwnj6d24wb1m9xz1vi1k9xk27arba1absjbcimggn54pinid";
}) })
./0001-apple-cmake.patch
]; ];
nativeBuildInputs = [ nativeBuildInputs = [
cmake cmake
pkg-config pkg-config
]; ];
buildInputs = [ buildInputs = [
alsa-lib
boost boost
curl curl
ffmpeg ffmpeg
@ -54,9 +59,14 @@ stdenv.mkDerivation rec {
libev libev
libmicrohttpd libmicrohttpd
ncurses ncurses
pulseaudio
taglib taglib
] ++ lib.optional systemdSupport systemd; ] ++ lib.optional systemdSupport [
systemd
] ++ lib.optional stdenv.isLinux [
alsa-lib pulseaudio
] ++ lib.optional stdenv.isDarwin [
Cocoa SystemConfiguration
];
cmakeFlags = [ cmakeFlags = [
"-DDISABLE_STRIP=true" "-DDISABLE_STRIP=true"

@ -27002,7 +27002,9 @@ with pkgs;
marker = callPackage ../applications/editors/marker { }; marker = callPackage ../applications/editors/marker { };
musikcube = callPackage ../applications/audio/musikcube {}; musikcube = callPackage ../applications/audio/musikcube {
inherit (darwin.apple_sdk.frameworks) Cocoa SystemConfiguration;
};
libmt32emu = callPackage ../applications/audio/munt/libmt32emu.nix { }; libmt32emu = callPackage ../applications/audio/munt/libmt32emu.nix { };

Loading…
Cancel
Save