3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/libraries/serf/default.nix

35 lines
1.2 KiB
Nix
Raw Normal View History

2014-08-05 10:41:32 +01:00
{ stdenv, fetchurl, apr, scons, openssl, aprutil, zlib, krb5, pkgconfig }:
stdenv.mkDerivation rec {
2014-09-02 11:44:44 +01:00
name = "serf-1.3.7";
2014-08-05 10:41:32 +01:00
src = fetchurl {
2014-08-05 10:41:32 +01:00
url = "http://serf.googlecode.com/svn/src_releases/${name}.tar.bz2";
2014-08-31 15:36:07 +01:00
sha256 = "1bphz616dv1svc50kkm8xbgyszhg3ni2dqbij99sfvjycr7bgk7c";
};
2014-08-05 10:41:32 +01:00
buildInputs = [ apr scons openssl aprutil zlib krb5 pkgconfig ];
configurePhase = ''
sed -e '/^env[.]Append(BUILDERS/ienv.Append(ENV={"PATH":os.environ["PATH"]})' -i SConstruct
sed -e '/^env[.]Append(BUILDERS/ienv.Append(ENV={"NIX_CFLAGS_COMPILE":os.environ["NIX_CFLAGS_COMPILE"]})' -i SConstruct
sed -e '/^env[.]Append(BUILDERS/ienv.Append(ENV={"NIX_LDFLAGS":os.environ["NIX_LDFLAGS"]})' -i SConstruct
'';
buildPhase = ''
scons PREFIX="$out" OPENSSL="${openssl}" ZLIB="${zlib}" APR="$(echo "${apr}"/bin/*-config)" \
APU="$(echo "${aprutil}"/bin/*-config)" GSSAPI="${krb5}" CC="${stdenv.gcc}/bin/gcc"
'';
installPhase = ''
scons install
'';
meta = {
description = "HTTP client library based on APR";
2014-09-02 11:44:44 +01:00
license = stdenv.lib.licenses.asl20;
maintainers = [stdenv.lib.maintainers.raskin];
hydraPlatforms = stdenv.lib.platforms.linux ++ stdenv.lib.platforms.darwin;
};
}