naja: 0.2.1 -> 0.2.2 (#430692)

authored by

Cosima Neidahl and committed by
GitHub
7306c79f 01ae052d

+26 -17
+26 -17
pkgs/by-name/na/naja/package.nix
··· 10 10 flex, 11 11 pkg-config, 12 12 python3, 13 + sphinx, 13 14 tbb_2021, 14 15 buildPackages, 15 16 nix-update-script, 16 17 }: 17 18 stdenv.mkDerivation (finalAttrs: { 18 19 pname = "naja"; 19 - version = "0.2.1"; 20 + version = "0.2.2"; 20 21 21 22 src = fetchFromGitHub { 22 23 owner = "najaeda"; 23 24 repo = "naja"; 24 25 tag = "v${finalAttrs.version}"; 25 - hash = "sha256-eKeb6V9u4huesQV4sq9GxIcxO2SVvMrUDeQaObCCags="; 26 + hash = "sha256-cm9MwN60R/K2bL4FWpvusFmb2ENYEYg8NcMVgmeTj0c="; 26 27 fetchSubmodules = true; 27 28 }; 28 29 ··· 32 33 "dev" 33 34 ]; 34 35 36 + postPatch = '' 37 + # This is a find module, not a config module, so this doesn't make it get automatically picked up by CMake hooks, 38 + # but it's better than dumping it at $out/cmake, and this makes it get moved to dev output 39 + substituteInPlace cmake/CMakeLists.txt \ 40 + --replace-fail 'DESTINATION cmake' 'DESTINATION ''${CMAKE_INSTALL_LIBDIR}/cmake' 41 + 42 + # Fix install location for bne library & headers 43 + # Remove when https://github.com/najaeda/naja/pull/278 merged & in release 44 + substituteInPlace src/bne/CMakeLists.txt \ 45 + --replace-fail 'LIBRARY DESTINATION lib' 'LIBRARY DESTINATION ''${CMAKE_INSTALL_LIBDIR}' \ 46 + --replace-fail 'PUBLIC_HEADER DESTINATION include' 'PUBLIC_HEADER DESTINATION ''${CMAKE_INSTALL_INCLUDEDIR}' 47 + '' 35 48 # disable building tests for cross build 36 - postPatch = 37 - lib.optionalString (!stdenv.buildPlatform.canExecute stdenv.hostPlatform) '' 38 - substituteInPlace CMakeLists.txt \ 39 - --replace-fail 'enable_testing()' "" \ 40 - --replace-fail 'add_subdirectory(test)' "" 41 - substituteInPlace thirdparty/yosys-liberty/CMakeLists.txt \ 42 - --replace-fail 'add_subdirectory(test)' "" 43 - '' 44 - + lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) '' 45 - patchShebangs --build test/test_utils/diff_files.py 46 - ''; 49 + + lib.optionalString (!stdenv.buildPlatform.canExecute stdenv.hostPlatform) '' 50 + substituteInPlace CMakeLists.txt \ 51 + --replace-fail 'enable_testing()' "" \ 52 + --replace-fail 'add_subdirectory(test)' "" 53 + substituteInPlace thirdparty/yosys-liberty/CMakeLists.txt \ 54 + --replace-fail 'add_subdirectory(test)' "" 55 + '' 56 + + lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) '' 57 + patchShebangs --build test/test_utils/diff_files.py 58 + ''; 47 59 48 60 strictDeps = true; 49 61 ··· 53 65 doxygen 54 66 flex 55 67 pkg-config 68 + sphinx 56 69 ] 57 70 ++ lib.optionals (stdenv.buildPlatform.canExecute stdenv.hostPlatform) [ 58 71 python3 # test scripts ··· 73 86 (lib.cmakeFeature "CAPNP_EXECUTABLE" (lib.getExe' buildPackages.capnproto "capnp")) 74 87 (lib.cmakeFeature "CAPNPC_CXX_EXECUTABLE" (lib.getExe' buildPackages.capnproto "capnpc-c++")) 75 88 ]; 76 - 77 - postInstall = '' 78 - moveToOutput lib/libnaja_bne.so $lib 79 - ''; 80 89 81 90 doCheck = true; 82 91