2013-03-01 18:31:00 +00:00
|
|
|
{stdenv, fetchurl, makeWrapper, gtk, webkit, pkgconfig, glib, glib_networking, libsoup, patches ? null}:
|
2011-08-11 16:33:41 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "surf-${version}";
|
2013-02-25 20:07:44 +00:00
|
|
|
version="0.6";
|
2011-08-11 16:33:41 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://dl.suckless.org/surf/surf-${version}.tar.gz";
|
2013-03-01 18:31:00 +00:00
|
|
|
sha256 = "fdc1ccfaee5c4f008eeb8fe5f9200d3ad71296e8d7af52bdd6a771f111866805";
|
2011-08-11 16:33:41 +00:00
|
|
|
};
|
|
|
|
|
2013-03-01 18:31:00 +00:00
|
|
|
buildInputs = [ gtk makeWrapper webkit pkgconfig glib libsoup glib_networking ];
|
2011-08-11 16:33:41 +00:00
|
|
|
|
|
|
|
# Allow users set their own list of patches
|
|
|
|
inherit patches;
|
|
|
|
|
|
|
|
buildPhase = " make ";
|
|
|
|
|
|
|
|
# `-lX11' to make sure libX11's store path is in the RPATH
|
|
|
|
NIX_LDFLAGS = "-lX11";
|
|
|
|
preConfigure = [ ''sed -i "s@PREFIX = /usr/local@PREFIX = $out@g" config.mk'' ];
|
2013-03-01 18:31:00 +00:00
|
|
|
installPhase = ''
|
|
|
|
make PREFIX=/ DESTDIR=$out install
|
|
|
|
wrapProgram "$out/bin/surf" --prefix GIO_EXTRA_MODULES : \
|
|
|
|
${glib_networking}/lib/gio/modules
|
|
|
|
'';
|
2011-08-11 16:33:41 +00:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "surf is a simple web browser based on WebKit/GTK+. It is able to display websites and follow links. It supports the XEmbed protocol which makes it possible to embed it in another application. Furthermore, one can point surf to another URI by setting its XProperties.";
|
|
|
|
homepage = http://surf.suckless.org;
|
|
|
|
license = "MIT";
|
2011-08-20 05:24:19 +00:00
|
|
|
platforms = stdenv.lib.platforms.linux;
|
2011-08-11 16:33:41 +00:00
|
|
|
};
|
|
|
|
}
|