Merge pull request #283675 from wegank/prusa-slicer-aarch64-darwin

prusa-slicer: fix build on darwin

authored by Maciej Krüger and committed by GitHub 82ee0694 939e432e

+12 -1
+4
pkgs/applications/misc/prusa-slicer/default.nix
··· 9 , cereal 10 , cgal 11 , curl 12 , dbus 13 , eigen 14 , expat ··· 111 catch2 112 ] ++ lib.optionals withSystemd [ 113 systemd 114 ]; 115 116 separateDebugInfo = true; ··· 190 homepage = "https://github.com/prusa3d/PrusaSlicer"; 191 license = licenses.agpl3; 192 maintainers = with maintainers; [ moredread tweber tmarkus ]; 193 } // lib.optionalAttrs (stdenv.isDarwin) { 194 mainProgram = "PrusaSlicer"; 195 };
··· 9 , cereal 10 , cgal 11 , curl 12 + , darwin 13 , dbus 14 , eigen 15 , expat ··· 112 catch2 113 ] ++ lib.optionals withSystemd [ 114 systemd 115 + ] ++ lib.optionals stdenv.isDarwin [ 116 + darwin.apple_sdk_11_0.frameworks.CoreWLAN 117 ]; 118 119 separateDebugInfo = true; ··· 193 homepage = "https://github.com/prusa3d/PrusaSlicer"; 194 license = licenses.agpl3; 195 maintainers = with maintainers; [ moredread tweber tmarkus ]; 196 + platforms = platforms.unix; 197 } // lib.optionalAttrs (stdenv.isDarwin) { 198 mainProgram = "PrusaSlicer"; 199 };
+5
pkgs/development/libraries/openvdb/default.nix
··· 20 21 cmakeFlags = [ "-DOPENVDB_CORE_STATIC=OFF" ]; 22 23 postFixup = '' 24 substituteInPlace $dev/lib/cmake/OpenVDB/FindOpenVDB.cmake \ 25 --replace \''${OPENVDB_LIBRARYDIR} $out/lib \
··· 20 21 cmakeFlags = [ "-DOPENVDB_CORE_STATIC=OFF" ]; 22 23 + # error: aligned deallocation function of type 'void (void *, std::align_val_t) noexcept' is only available on macOS 10.13 or newer 24 + env = lib.optionalAttrs (stdenv.isDarwin && lib.versionOlder stdenv.hostPlatform.darwinMinVersion "10.13" && lib.versionAtLeast tbb.version "2021.8.0") { 25 + NIX_CFLAGS_COMPILE = "-faligned-allocation"; 26 + }; 27 + 28 postFixup = '' 29 substituteInPlace $dev/lib/cmake/OpenVDB/FindOpenVDB.cmake \ 30 --replace \''${OPENVDB_LIBRARYDIR} $out/lib \
+3 -1
pkgs/top-level/all-packages.nix
··· 35320 35321 printrun = callPackage ../applications/misc/printrun { }; 35322 35323 - prusa-slicer = darwin.apple_sdk_11_0.callPackage ../applications/misc/prusa-slicer { }; 35324 35325 super-slicer = darwin.apple_sdk_11_0.callPackage ../applications/misc/prusa-slicer/super-slicer.nix { }; 35326
··· 35320 35321 printrun = callPackage ../applications/misc/printrun { }; 35322 35323 + prusa-slicer = darwin.apple_sdk_11_0.callPackage ../applications/misc/prusa-slicer { 35324 + stdenv = if stdenv.isDarwin then overrideLibcxx darwin.apple_sdk_11_0.llvmPackages_14.stdenv else stdenv; 35325 + }; 35326 35327 super-slicer = darwin.apple_sdk_11_0.callPackage ../applications/misc/prusa-slicer/super-slicer.nix { }; 35328