about summary refs log tree commit diff
path: root/pkgs/applications/misc/makeself
diff options
context:
space:
mode:
authorDaniel Nagy <danielnagy@posteo.de>2023-05-24 15:45:00 +0200
committerDaniel Nagy <danielnagy@posteo.de>2023-05-24 16:00:00 +0200
commit2e5597d571948911ed00e664752beebea4d5f6dc (patch)
treeb1f44df7cdee2a4482a0275af254772d1b4dba28 /pkgs/applications/misc/makeself
parent6342746d6cedcbf7691fa00138b1695a8ff4b3a3 (diff)
makeself: use installManPage
Diffstat (limited to 'pkgs/applications/misc/makeself')
-rw-r--r--pkgs/applications/misc/makeself/default.nix14
1 files changed, 8 insertions, 6 deletions
diff --git a/pkgs/applications/misc/makeself/default.nix b/pkgs/applications/misc/makeself/default.nix
index bd197395e8514..3226797ca4be9 100644
--- a/pkgs/applications/misc/makeself/default.nix
+++ b/pkgs/applications/misc/makeself/default.nix
@@ -1,4 +1,4 @@
-{ lib, stdenv, fetchFromGitHub, which, zstd, pbzip2 }:
+{ lib, stdenv, fetchFromGitHub, which, zstd, pbzip2, installShellFiles }:
 
 stdenv.mkDerivation rec {
   version = "2.4.5";
@@ -12,6 +12,8 @@ stdenv.mkDerivation rec {
     sha256 = "sha256-15lUtErGsbXF2Gn0f0rvA18mMuVMmkKrGO2poeYZU9g=";
   };
 
+  nativeBuildInputs = [ installShellFiles ];
+
   postPatch = "patchShebangs test";
 
   # Issue #110149: our default /bin/sh apparently has 32-bit math only
@@ -22,11 +24,11 @@ stdenv.mkDerivation rec {
   nativeCheckInputs = [ which zstd pbzip2 ];
 
   installPhase = ''
-    mkdir -p $out/{bin,share/{${pname}-${version},man/man1}}
-    cp makeself.lsm README.md $out/share/${pname}-${version}
-    cp makeself.sh $out/bin/makeself
-    cp makeself.1  $out/share/man/man1/
-    cp makeself-header.sh $out/share/${pname}-${version}
+    runHook preInstall
+    installManPage makeself.1
+    install -Dm555 makeself.sh $out/bin/makeself
+    install -Dm444 -t $out/share/${pname}/ makeself.lsm README.md makeself-header.sh
+    runHook postInstall
   '';
 
   fixupPhase = ''