summary refs log tree commit diff
path: root/pkgs/development/libraries/libfsm
diff options
context:
space:
mode:
authorAustin Seipp <aseipp@pobox.com>2019-10-23 22:15:10 -0500
committerAustin Seipp <aseipp@pobox.com>2019-10-23 22:16:18 -0500
commit9dab9a79706ceb63930b15b0c6305066046bac1e (patch)
tree8696aee5a8c9e84ac7d96a672bed8a52c06658a8 /pkgs/development/libraries/libfsm
parent5b508327806cd04eb0f82598ca953a512db3b313 (diff)
downloadnixpkgs-9dab9a79706ceb63930b15b0c6305066046bac1e.tar
nixpkgs-9dab9a79706ceb63930b15b0c6305066046bac1e.tar.gz
nixpkgs-9dab9a79706ceb63930b15b0c6305066046bac1e.tar.bz2
nixpkgs-9dab9a79706ceb63930b15b0c6305066046bac1e.tar.lz
nixpkgs-9dab9a79706ceb63930b15b0c6305066046bac1e.tar.xz
nixpkgs-9dab9a79706ceb63930b15b0c6305066046bac1e.tar.zst
nixpkgs-9dab9a79706ceb63930b15b0c6305066046bac1e.zip
libfsm: 0.1pre1869_f70c3c5 -> 0.1pre1905_bd5937fa
Properly separate the build and install phases for better nix shell
hacking when using `buildPhase` -- and also fix a bug where
`$NIX_BUILD_CORES` wasn't properly passed to `bmake`.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
Diffstat (limited to 'pkgs/development/libraries/libfsm')
-rw-r--r--pkgs/development/libraries/libfsm/default.nix16
1 files changed, 10 insertions, 6 deletions
diff --git a/pkgs/development/libraries/libfsm/default.nix b/pkgs/development/libraries/libfsm/default.nix
index ce7d615f4d3..78f1f66623a 100644
--- a/pkgs/development/libraries/libfsm/default.nix
+++ b/pkgs/development/libraries/libfsm/default.nix
@@ -4,13 +4,13 @@
 
 stdenv.mkDerivation rec {
   pname = "libfsm";
-  version = "0.1pre1869_${builtins.substring 0 7 src.rev}";
+  version = "0.1pre1905_${builtins.substring 0 8 src.rev}";
 
   src = fetchFromGitHub {
     owner  = "katef";
-    repo   = "libfsm";
-    rev    = "f70c3c5778a79eeecb52f9fd35c7cbc241db0ed6";
-    sha256 = "1hgv272jdv6dwnsdjajyky537z84q0cwzspw9br46qj51h8gkwvx";
+    repo   = pname;
+    rev    = "bd5937fad42b26a86bac1fe3ec49eff73581bd1d";
+    sha256 = "1q3grbmvjnnvc2sshswbd40cc2j2hnwibmljcqx9jqgda0wd6pgv";
     fetchSubmodules = true;
   };
 
@@ -22,12 +22,16 @@ stdenv.mkDerivation rec {
   # if we use stdenv vs clangStdenv, we don't know which, and CC=cc in all
   # cases.) it's unclear exactly what should be done if we want those flags,
   # but the defaults work fine.
-  buildPhase = "PREFIX=$out bmake -r install";
+  buildPhase = "PREFIX=$out bmake -r -j$NIX_BUILD_CORES";
+  installPhase = ''
+    PREFIX=$out bmake -r install
+    runHook postInstall
+  '';
 
   # fix up multi-output install. we also have to fix the pkgconfig libdir
   # file; it uses prefix=$out; libdir=${prefix}/lib, which is wrong in
   # our case; libdir should really be set to the $lib output.
-  installPhase = ''
+  postInstall = ''
     mkdir -p $lib $dev/lib
 
     mv $out/lib             $lib/lib