qucs-s: enable on darwin

This commit is contained in:
Dmitry Kalinkin
2024-12-22 22:38:48 -05:00
parent 9468b63e4c
commit 0bd44ede0a
@@ -29,8 +29,29 @@ stdenv.mkDerivation rec {
hash = "sha256-ll5P8cqJBzoieExElggn5tRbDcmH7L3yvcbtAQ0BBww=";
};
postPatch = ''
# Workaround a CMake bug (we don't generally do distributable bundles in nixpkgs anyway):
# warning: cannot resolve item '/usr/lib/libSystem.B.dylib'
#
# possible problems:
# need more directories?
# need to use InstallRequiredSystemLibraries?
# run in install tree instead of build tree?
for filename in \
qucs/CMakeLists.txt \
qucs-transcalc/CMakeLists.txt \
qucs-attenuator/CMakeLists.txt \
qucs-s-spar-viewer/CMakeLists.txt \
; do
substituteInPlace "$filename" \
--replace-fail 'fixup_bundle(' 'message(\"nixpkgs will not fixup_bundle: \" '
done
'';
nativeBuildInputs = [ flex bison wrapQtAppsHook cmake ];
buildInputs = [ qtbase qttools qtcharts qtsvg qtwayland libX11 gperf adms ] ++ kernels;
buildInputs = [ qtbase qttools qtcharts qtsvg gperf adms ]
++ lib.optionals stdenv.isLinux [ qtwayland libX11 ]
++ kernels;
cmakeFlags = [
"-DWITH_QT6=ON"
@@ -56,6 +77,6 @@ stdenv.mkDerivation rec {
license = licenses.gpl2Plus;
mainProgram = "qucs-s";
maintainers = with maintainers; [ mazurel kashw2 thomaslepoix ];
platforms = with platforms; linux;
platforms = with platforms; unix;
};
}