summary refs log tree commit diff
diff options
context:
space:
mode:
authorDaiderd Jordan <daiderd@gmail.com>2018-04-05 19:12:48 +0200
committerGitHub <noreply@github.com>2018-04-05 19:12:48 +0200
commitc45eadf31ddf61328a33dc9215c4b1f1f4f2c0d2 (patch)
tree4b19a65c47b6ff7668b9dc4a1d44fd6726e99361
parent05f175e06ad6c77e5a345966c5e2912fc437b8f9 (diff)
parentb206311c808e5e76313e60ae7e70c5ec4e7fae52 (diff)
downloadnixpkgs-c45eadf31ddf61328a33dc9215c4b1f1f4f2c0d2.tar
nixpkgs-c45eadf31ddf61328a33dc9215c4b1f1f4f2c0d2.tar.gz
nixpkgs-c45eadf31ddf61328a33dc9215c4b1f1f4f2c0d2.tar.bz2
nixpkgs-c45eadf31ddf61328a33dc9215c4b1f1f4f2c0d2.tar.lz
nixpkgs-c45eadf31ddf61328a33dc9215c4b1f1f4f2c0d2.tar.xz
nixpkgs-c45eadf31ddf61328a33dc9215c4b1f1f4f2c0d2.tar.zst
nixpkgs-c45eadf31ddf61328a33dc9215c4b1f1f4f2c0d2.zip
Merge pull request #38466 from thefloweringash/apg-unix
apg: Darwin support
-rw-r--r--pkgs/tools/security/apg/default.nix7
-rw-r--r--pkgs/tools/security/apg/phony-install-target.patch11
2 files changed, 16 insertions, 2 deletions
diff --git a/pkgs/tools/security/apg/default.nix b/pkgs/tools/security/apg/default.nix
index 04b29bcf8f7..db490c7822f 100644
--- a/pkgs/tools/security/apg/default.nix
+++ b/pkgs/tools/security/apg/default.nix
@@ -10,7 +10,10 @@ stdenv.mkDerivation rec {
   '';
   makeFlags = stdenv.lib.optionals stdenv.isDarwin ["CC=cc"];
 
-  patches = [ ./apg.patch ];
+  patches = [
+    ./apg.patch
+    ./phony-install-target.patch
+  ];
 
   postPatch = stdenv.lib.optionalString stdenv.isDarwin ''
     sed -i -e 's|APG_CLIBS += -lcrypt|APG_CLIBS += -L${openssl.out}/lib -lcrypto|' Makefile
@@ -64,6 +67,6 @@ stdenv.mkDerivation rec {
     homepage = http://www.adel.nursat.kz/apg/;
     license = stdenv.lib.licenses.bsd3;
     maintainers = with stdenv.lib.maintainers; [ astsmtl ];
-    platforms = stdenv.lib.platforms.linux;
+    platforms = stdenv.lib.platforms.unix;
   };
 }
diff --git a/pkgs/tools/security/apg/phony-install-target.patch b/pkgs/tools/security/apg/phony-install-target.patch
new file mode 100644
index 00000000000..9edf50b4b59
--- /dev/null
+++ b/pkgs/tools/security/apg/phony-install-target.patch
@@ -0,0 +1,11 @@
+diff -ur a/Makefile b/Makefile
+--- a/Makefile	2003-08-08 00:40:39.000000000 +0900
++++ b/Makefile	2018-04-05 22:29:39.284191020 +0900
+@@ -142,6 +142,7 @@
+ 	strip ${CS_PROGNAME}
+ 	strip ${BFM_PROGNAME}
+ 
++.PHONY: install
+ install:
+ 	if test -x ./apg; then \
+ ./mkinstalldirs ${INSTALL_PREFIX}${APG_BIN_DIR}; \