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 9 , cereal 10 10 , cgal 11 11 , curl 12 + , darwin 12 13 , dbus 13 14 , eigen 14 15 , expat ··· 111 112 catch2 112 113 ] ++ lib.optionals withSystemd [ 113 114 systemd 115 + ] ++ lib.optionals stdenv.isDarwin [ 116 + darwin.apple_sdk_11_0.frameworks.CoreWLAN 114 117 ]; 115 118 116 119 separateDebugInfo = true; ··· 190 193 homepage = "https://github.com/prusa3d/PrusaSlicer"; 191 194 license = licenses.agpl3; 192 195 maintainers = with maintainers; [ moredread tweber tmarkus ]; 196 + platforms = platforms.unix; 193 197 } // lib.optionalAttrs (stdenv.isDarwin) { 194 198 mainProgram = "PrusaSlicer"; 195 199 };
+5
pkgs/development/libraries/openvdb/default.nix
··· 20 20 21 21 cmakeFlags = [ "-DOPENVDB_CORE_STATIC=OFF" ]; 22 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 + 23 28 postFixup = '' 24 29 substituteInPlace $dev/lib/cmake/OpenVDB/FindOpenVDB.cmake \ 25 30 --replace \''${OPENVDB_LIBRARYDIR} $out/lib \
+3 -1
pkgs/top-level/all-packages.nix
··· 35320 35320 35321 35321 printrun = callPackage ../applications/misc/printrun { }; 35322 35322 35323 - prusa-slicer = darwin.apple_sdk_11_0.callPackage ../applications/misc/prusa-slicer { }; 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 + }; 35324 35326 35325 35327 super-slicer = darwin.apple_sdk_11_0.callPackage ../applications/misc/prusa-slicer/super-slicer.nix { }; 35326 35328