git.iko.soy/typeable/nixpkgs
on master help sign in
Revert "kerberos: Modernize build"

This reverts commit 9740b0d12d467aaa0ddc1cc27559374250ae5549.

commit020cb43f551006173582d1f8b440865572770c84 authorEelco Dolstra <eelco.dolstra@logicblox.com> dateTue 2 Jun 2015, 11:35 (12 years ago) parent056e2c8
2 files changed+16−64
pkgs/development/libraries/kerberos/heimdal.nix+15−64 pkgs/top-level/all-packages.nix+1
pkgs/development/libraries/kerberos/heimdal.nix+15−64
@@ -1,32 +1,7 @@
1−{ stdenv, fetchurl, pkgconfig, flex, yacc
2−
3−# Optional Dependencies
4−, openldap ? null, libcap_ng ? null, sqlite ? null, openssl ? null, db ? null
5−, readline ? null, libedit ? null, pam ? null
6−
7−#, readline, openldap, libcap_ng
8−#, sqlite, db, ncurses, openssl, cyrus_sasl
1+{ stdenv, fetchurl, pkgconfig, flex, yacc, readline, openldap, libcap_ng
2+, sqlite, db, ncurses, openssl, cyrus_sasl
93}:
104
11−let
12− mkFlag = trueStr: falseStr: cond: name: val:
13− if cond == null then null else
14− "--${if cond != false then trueStr else falseStr}${name}${if val != null && cond != false then "=${val}" else ""}";
15− mkEnable = mkFlag "enable-" "disable-";
16− mkWith = mkFlag "with-" "without-";
17− mkOther = mkFlag "" "" true;
18−
19− shouldUsePkg = pkg: if pkg != null && stdenv.lib.any (x: x == stdenv.system) pkg.meta.platforms then pkg else null;
20−
21− optOpenldap = shouldUsePkg openldap;
22− optLibcap_ng = shouldUsePkg libcap_ng;
23− optSqlite = shouldUsePkg sqlite;
24− optOpenssl = shouldUsePkg openssl;
25− optDb = shouldUsePkg db;
26− optReadline = shouldUsePkg readline;
27− optLibedit = shouldUsePkg libedit;
28− optPam = shouldUsePkg pam;
29−in
305stdenv.mkDerivation rec {
316 name = "heimdal-1.5.3";
327
@@ -38,43 +13,14 @@ stdenv.mkDerivation rec {
3813 sha256 = "19gypf9vzfrs2bw231qljfl4cqc1riyg0ai0xmm1nd1wngnpphma";
3914 };
4015
41− nativeBuildInputs = [ pkgconfig flex yacc ];
42− buildInputs = [
43− optOpenldap optLibcap_ng optSqlite optOpenssl optDb optReadline optLibedit
44− optPam
45− ];
46−
16+ ## ugly, X should be made an option
4717 configureFlags = [
48− (mkOther "sysconfdir" "/etc")
49− (mkOther "localstatedir" "/var")
50− (mkWith (optOpenldap != null) "openldap" optOpenldap)
51− (mkEnable (optOpenldap != null) "hdb-openldap-module" null)
52− (mkEnable true "pk-init" null)
53− (mkEnable true "digest" null)
54− (mkEnable true "kx509" null)
55− (mkWith (optLibcap_ng != null) "capng" null)
56− (mkWith (optSqlite != null) "sqlite3" sqlite)
57− (mkEnable (optSqlite != null) "sqlite-cache" null)
58− #(mkWith true "libintl" glibc) # TODO libintl fix
59− (mkWith true "hdbdir" "/var/lib/heimdal")
60− (mkWith (optOpenssl != null) "openssl" optOpenssl)
61− (mkEnable true "pthread-support" null)
62− (mkEnable true "dce" null)
63− (mkEnable true "afs-support" null)
64− (mkWith (optDb != null) "berkeley-db" optDb)
65− (mkEnable false "nmdb" null)
66− (mkEnable false "developer" null)
67− (mkWith true "ipv6" null)
68− (mkEnable false "socket-wrapper" null)
69− (mkEnable true "otp" null)
70− (mkEnable false "osfc2" null)
71− (mkEnable true "mmap" null)
72− (mkEnable true "afs-string-to-key" null)
73− (mkWith (optReadline != null) "readline" optReadline)
74− (mkWith (optLibedit != null) "libedit" optLibedit)
75− (mkWith false "x" null)
76− (mkEnable true "kcm" null)
77− (mkEnable true "heimdal-documentation" null)
18+ "--enable-hdb-openldap-module"
19+ "--with-capng"
20+ "--with-openldap=${openldap}"
21+ "--with-sqlite3=${sqlite}"
22+ "--with-openssl-lib=${openssl}/lib"
23+ "--without-x"
7824 ];
7925
8026 # We need to build hcrypt for applications like samba
@@ -88,11 +34,16 @@ stdenv.mkDerivation rec {
8834 (cd lib/hcrypto; make install)
8935 (cd include/hcrypto; make install)
9036
91− # Doesn't succeed with --libexec=$out/sbin, so
37+ # dont succeed with --libexec=$out/sbin, so
9238 mv "$out/libexec/"* $out/sbin/
9339 rmdir $out/libexec
9440 '';
9541
42+ buildInputs = [
43+ pkgconfig flex yacc readline openldap libcap_ng sqlite db ncurses
44+ cyrus_sasl openssl
45+ ];
46+
9647 meta = with stdenv.lib; {
9748 description = "an implementation of Kerberos 5 (and some more stuff) largely written in Sweden";
9849 license = licenses.bsd3;
pkgs/top-level/all-packages.nix+1
@@ -6376,6 +6376,7 @@ let
63766376 openldap = openldap.override {
63776377 cyrus_sasl = cyrus_sasl.override { kerberos = null; };
63786378 };
6379+ cyrus_sasl = cyrus_sasl.override { kerberos = null; };
63796380 };
63806381
63816382 harfbuzz = callPackage ../development/libraries/harfbuzz { };