diff options
author | AndersonTorres <torres.anderson.85@protonmail.com> | 2020-09-28 03:50:11 -0300 |
---|---|---|
committer | AndersonTorres <torres.anderson.85@protonmail.com> | 2020-09-28 22:39:18 -0300 |
commit | 30729522955f1d43edc6a4af4004b323e23435a6 (patch) | |
tree | 539046d0c20b623f2e0c1857a617c4255469cfaa /pkgs/applications/networking/browsers | |
parent | 66fac9a0bf59b64f8a6c6b3ad2974bd824e9e9ba (diff) |
Netsurf browser: 3.9 -> 3.10
Diffstat (limited to 'pkgs/applications/networking/browsers')
-rw-r--r-- | pkgs/applications/networking/browsers/netsurf/browser.nix | 83 | ||||
-rw-r--r-- | pkgs/applications/networking/browsers/netsurf/default.nix | 2 |
2 files changed, 85 insertions, 0 deletions
diff --git a/pkgs/applications/networking/browsers/netsurf/browser.nix b/pkgs/applications/networking/browsers/netsurf/browser.nix new file mode 100644 index 0000000000000..407d94a4dc456 --- /dev/null +++ b/pkgs/applications/networking/browsers/netsurf/browser.nix @@ -0,0 +1,83 @@ +{ stdenv, fetchurl, fetchpatch, makeWrapper, wrapGAppsHook + +# Buildtime dependencies. +, check, pkgconfig, xxd + +# Runtime dependencies. +, curl, expat, libXcursor, libXrandr, libidn, libjpeg, libpng, libwebp, libxml2 +, openssl, perl, perlPackages + +# uilib-specific dependencies +, gtk2 # GTK 2 +, gtk3 # GTK 3 +, SDL # Framebuffer + +# Configuration +, uilib + +# Netsurf-specific dependencies +, libcss, libdom, libhubbub, libnsbmp, libnsfb, libnsgif +, libnslog, libnspsl, libnsutils, libparserutils, libsvgtiny, libutf8proc +, libwapcaplet, nsgenbind +}: + +let + inherit (stdenv.lib) optional optionals; +in +stdenv.mkDerivation rec { + pname = "netsurf"; + version = "3.10"; + + src = fetchurl { + url = "http://download.netsurf-browser.org/netsurf/releases/source/${pname}-${version}-src.tar.gz"; + sha256 = "sha256-NkhEKeGTYUaFwv8kb1W9Cm3d8xoBi+5F4NH3wohRmV4="; + }; + + nativeBuildInputs = [ + makeWrapper + perl + perlPackages.HTMLParser + pkgconfig + xxd + ] + ++ optional (uilib == "gtk2" || uilib == "gtk3") wrapGAppsHook + ; + + buildInputs = [ + check curl libXcursor libXrandr libidn libjpeg libpng libwebp libxml2 openssl + # Netsurf-specific libraries + nsgenbind libnsfb libwapcaplet libparserutils libnslog libcss + libhubbub libdom libnsbmp libnsgif libsvgtiny libnsutils libnspsl + libutf8proc + ] + ++ optionals (uilib == "framebuffer") [ expat SDL ] + ++ optional (uilib == "gtk2") gtk2 + ++ optional (uilib == "gtk3") gtk3 + ; + + preConfigure = '' + cat <<EOF > Makefile.conf + override NETSURF_GTK_RES_PATH := $out/share/ + override NETSURF_USE_GRESOURCE := YES + EOF + ''; + + makeFlags = [ + "PREFIX=${placeholder "out"}" + "TARGET=${uilib}" + ]; + + meta = with stdenv.lib; { + homepage = "https://www.netsurf-browser.org/"; + description = "A free, open source, small web browser"; + longDescription = '' + NetSurf is a free, open source web browser. It is written in C and + released under the GNU Public Licence version 2. NetSurf has its own + layout and rendering engine entirely written from scratch. It is small and + capable of handling many of the web standards in use today. + ''; + license = licenses.gpl2Only; + maintainers = [ maintainers.vrthra maintainers.AndersonTorres ]; + platforms = platforms.linux; + }; +} diff --git a/pkgs/applications/networking/browsers/netsurf/default.nix b/pkgs/applications/networking/browsers/netsurf/default.nix index 627a84df2be58..409ab80ce3acc 100644 --- a/pkgs/applications/networking/browsers/netsurf/default.nix +++ b/pkgs/applications/networking/browsers/netsurf/default.nix @@ -16,6 +16,8 @@ lib.makeScope pkgs.newScope (self: with self; { else if ui == "framebuffer" then pkgs.SDL else null; + browser = callPackage ./browser.nix { }; + buildsystem = callPackage ./buildsystem.nix { }; libcss = callPackage ./libcss.nix { }; libdom = callPackage ./libdom.nix { }; |