1{
2 lib,
3 stdenv,
4 apacheHttpd,
5 autoconf,
6 automake,
7 autoreconfHook,
8 curl,
9 fetchFromGitHub,
10 glib,
11 lasso,
12 libtool,
13 libxml2,
14 libxslt,
15 openssl,
16 pkg-config,
17 xmlsec,
18}:
19
20stdenv.mkDerivation rec {
21
22 pname = "mod_auth_mellon";
23 version = "0.19.1";
24
25 src = fetchFromGitHub {
26 owner = "latchset";
27 repo = "mod_auth_mellon";
28 rev = "v${version}";
29 sha256 = "sha256-VcR+HZ5S7fLrGqT1SHCQLQw6v516G0x+wf8Wb5Sy4Gk=";
30 };
31
32 nativeBuildInputs = [
33 autoreconfHook
34 pkg-config
35 autoconf
36 automake
37 ];
38 buildInputs = [
39 apacheHttpd
40 curl
41 glib
42 lasso
43 libtool
44 libxml2
45 libxslt
46 openssl
47 xmlsec
48 ];
49
50 configureFlags = [
51 "--with-apxs2=${apacheHttpd.dev}/bin/apxs"
52 "--exec-prefix=$out"
53 ];
54
55 installPhase = ''
56 mkdir -p $out/bin
57 cp ./mellon_create_metadata.sh $out/bin
58 mkdir -p $out/modules
59 cp ./.libs/mod_auth_mellon.so $out/modules
60 '';
61
62 meta = with lib; {
63 homepage = "https://github.com/latchset/mod_auth_mellon";
64 description = "Apache module with a simple SAML 2.0 service provider";
65 mainProgram = "mellon_create_metadata.sh";
66 license = licenses.gpl2Plus;
67 platforms = platforms.linux;
68 maintainers = with maintainers; [ womfoo ];
69 };
70
71}