diff options
author | Doron Behar <doron.behar@gmail.com> | 2022-10-26 15:48:11 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-26 15:48:11 +0000 |
commit | f9adc060fdbfb0062552bbd1dffd36f1844d0b5d (patch) | |
tree | c9650d35fe823d2b156b59a5a03083d83da4aac2 /pkgs/applications | |
parent | ca37f69ab9bc8e46905111189595a58216b6a0cf (diff) | |
parent | d4c4f87e04952db681ef3277674237688213b1f3 (diff) |
Merge pull request #197639 from jiegec/gnuradio-darwin
Diffstat (limited to 'pkgs/applications')
-rw-r--r-- | pkgs/applications/radio/gnuradio/3.8.nix | 4 | ||||
-rw-r--r-- | pkgs/applications/radio/gnuradio/3.9.nix | 2 | ||||
-rw-r--r-- | pkgs/applications/radio/gnuradio/default.nix | 2 | ||||
-rw-r--r-- | pkgs/applications/radio/gnuradio/shared.nix | 9 | ||||
-rw-r--r-- | pkgs/applications/radio/gnuradio/wrapper.nix | 10 |
5 files changed, 16 insertions, 11 deletions
diff --git a/pkgs/applications/radio/gnuradio/3.8.nix b/pkgs/applications/radio/gnuradio/3.8.nix index f3a56cfdb0550..301193a657853 100644 --- a/pkgs/applications/radio/gnuradio/3.8.nix +++ b/pkgs/applications/radio/gnuradio/3.8.nix @@ -271,11 +271,11 @@ stdenv.mkDerivation rec { # order to build, see https://github.com/qradiolink/qradiolink/issues/67 ++ lib.optionals (hasFeature "gr-vocoder") [ "-DLIBCODEC2_FOUND=TRUE" - "-DLIBCODEC2_LIBRARIES=${codec2}/lib/libcodec2.so" + "-DLIBCODEC2_LIBRARIES=${codec2}/lib/libcodec2${stdenv.hostPlatform.extensions.sharedLibrary}" "-DLIBCODEC2_INCLUDE_DIRS=${codec2}/include" "-DLIBCODEC2_HAS_FREEDV_API=ON" "-DLIBGSM_FOUND=TRUE" - "-DLIBGSM_LIBRARIES=${gsm}/lib/libgsm.so" + "-DLIBGSM_LIBRARIES=${gsm}/lib/libgsm${stdenv.hostPlatform.extensions.sharedLibrary}" "-DLIBGSM_INCLUDE_DIRS=${gsm}/include/gsm" ] ++ lib.optionals (hasFeature "volk" && volk != null) [ diff --git a/pkgs/applications/radio/gnuradio/3.9.nix b/pkgs/applications/radio/gnuradio/3.9.nix index 29998fb2097a4..e54c502060a23 100644 --- a/pkgs/applications/radio/gnuradio/3.9.nix +++ b/pkgs/applications/radio/gnuradio/3.9.nix @@ -296,7 +296,7 @@ stdenv.mkDerivation rec { # This is the only python reference worth removing, if needed. + lib.optionalString (!hasFeature "python-support") '' ${removeReferencesTo}/bin/remove-references-to -t ${python} $out/lib/cmake/gnuradio/GnuradioConfig.cmake - ${removeReferencesTo}/bin/remove-references-to -t ${python} $(readlink -f $out/lib/libgnuradio-runtime.so) + ${removeReferencesTo}/bin/remove-references-to -t ${python} $(readlink -f $out/lib/libgnuradio-runtime${stdenv.hostPlatform.extensions.sharedLibrary}) ${removeReferencesTo}/bin/remove-references-to -t ${python.pkgs.pybind11} $out/lib/cmake/gnuradio/gnuradio-runtimeTargets.cmake '' ; diff --git a/pkgs/applications/radio/gnuradio/default.nix b/pkgs/applications/radio/gnuradio/default.nix index 01fa40ebcf3c1..39aa9336aec9f 100644 --- a/pkgs/applications/radio/gnuradio/default.nix +++ b/pkgs/applications/radio/gnuradio/default.nix @@ -317,7 +317,7 @@ stdenv.mkDerivation rec { # This is the only python reference worth removing, if needed. + lib.optionalString (!hasFeature "python-support") '' ${removeReferencesTo}/bin/remove-references-to -t ${python} $out/lib/cmake/gnuradio/GnuradioConfig.cmake - ${removeReferencesTo}/bin/remove-references-to -t ${python} $(readlink -f $out/lib/libgnuradio-runtime.so) + ${removeReferencesTo}/bin/remove-references-to -t ${python} $(readlink -f $out/lib/libgnuradio-runtime${stdenv.hostPlatform.extensions.sharedLibrary}) ${removeReferencesTo}/bin/remove-references-to -t ${python.pkgs.pybind11} $out/lib/cmake/gnuradio/gnuradio-runtimeTargets.cmake '' ; diff --git a/pkgs/applications/radio/gnuradio/shared.nix b/pkgs/applications/radio/gnuradio/shared.nix index acb13cc1e2a34..a5ae83eb35130 100644 --- a/pkgs/applications/radio/gnuradio/shared.nix +++ b/pkgs/applications/radio/gnuradio/shared.nix @@ -84,7 +84,11 @@ rec { postInstall = "" # Gcc references + lib.optionalString (hasFeature "gnuradio-runtime") '' - ${removeReferencesTo}/bin/remove-references-to -t ${stdenv.cc} $(readlink -f $out/lib/libgnuradio-runtime.so) + ${removeReferencesTo}/bin/remove-references-to -t ${stdenv.cc} $(readlink -f $out/lib/libgnuradio-runtime${stdenv.hostPlatform.extensions.sharedLibrary}) + '' + # Clang references in InstalledDir + + lib.optionalString (hasFeature "gnuradio-runtime" && stdenv.isDarwin) '' + ${removeReferencesTo}/bin/remove-references-to -t ${stdenv.cc.cc} $(readlink -f $out/lib/libgnuradio-runtime${stdenv.hostPlatform.extensions.sharedLibrary}) '' ; # NOTE: Outputs are disabled due to upstream not using GNU InstallDIrs cmake @@ -112,7 +116,6 @@ rec { doCheck = false; meta = with lib; { - broken = stdenv.isDarwin; description = "Software Defined Radio (SDR) software"; longDescription = '' GNU Radio is a free & open-source software development toolkit that @@ -126,6 +129,6 @@ rec { homepage = "https://www.gnuradio.org"; license = licenses.gpl3; platforms = platforms.unix; - maintainers = with maintainers; [ doronbehar bjornfor fpletz ]; + maintainers = with maintainers; [ doronbehar bjornfor fpletz jiegec ]; }; } diff --git a/pkgs/applications/radio/gnuradio/wrapper.nix b/pkgs/applications/radio/gnuradio/wrapper.nix index 57d8f75320bb2..926022353e41f 100644 --- a/pkgs/applications/radio/gnuradio/wrapper.nix +++ b/pkgs/applications/radio/gnuradio/wrapper.nix @@ -98,19 +98,21 @@ let "${ lib.makeSearchPath unwrapped.qt.qtbase.qtPluginPrefix - (builtins.map lib.getBin [ + (builtins.map lib.getBin ([ unwrapped.qt.qtbase + ] ++ lib.optionals stdenv.isLinux [ unwrapped.qt.qtwayland - ]) + ])) }" "--prefix" "QML2_IMPORT_PATH" ":" "${ lib.makeSearchPath unwrapped.qt.qtbase.qtQmlPrefix - (builtins.map lib.getBin [ + (builtins.map lib.getBin ([ unwrapped.qt.qtbase + ] ++ lib.optionals stdenv.isLinux [ unwrapped.qt.qtwayland - ]) + ])) }" ] else |