diff --git a/pkgs/development/libraries/libvncserver/default.nix b/pkgs/development/libraries/libvncserver/default.nix index 7856183e5e9b..35adb4600414 100644 --- a/pkgs/development/libraries/libvncserver/default.nix +++ b/pkgs/development/libraries/libvncserver/default.nix @@ -1,29 +1,38 @@ -args : -let - lib = args.lib; - fetchurl = args.fetchurl; - - version = lib.attrByPath ["version"] "0.9.9" args; - buildInputs = with args; [ +{stdenv, fetchurl, + libtool, libjpeg, openssl, libX11, libXdamage, xproto, damageproto, + xextproto, libXext, fixesproto, libXfixes, xineramaproto, libXinerama, + libXrandr, randrproto, libXtst, zlib +}: +let + s = # Generated upstream information + rec { + baseName="libvncserver"; + version="0.9.9"; + name="${baseName}-${version}"; + hash="1y83z31wbjivbxs60kj8a8mmjmdkgxlvr2x15yz95yy24lshs1ng"; + url="mirror://sourceforge/project/libvncserver/libvncserver/0.9.9/LibVNCServer-0.9.9.tar.gz"; + sha256="1y83z31wbjivbxs60kj8a8mmjmdkgxlvr2x15yz95yy24lshs1ng"; + }; + buildInputs = [ libtool libjpeg openssl libX11 libXdamage xproto damageproto xextproto libXext fixesproto libXfixes xineramaproto libXinerama libXrandr randrproto libXtst zlib ]; in -rec { - src = fetchurl { - url = "mirror://sourceforge/libvncserver/LibVNCServer-${version}.tar.gz"; - sha256 = "1y83z31wbjivbxs60kj8a8mmjmdkgxlvr2x15yz95yy24lshs1ng"; - }; - +stdenv.mkDerivation { + inherit (s) name version; inherit buildInputs; - configureFlags = []; - - /* doConfigure should be specified separately */ - phaseNames = ["doConfigure" "doMakeInstall"]; - - name = "libvncserver-" + version; + src = fetchurl { + inherit (s) url sha256; + }; + preConfigure = '' + sed -e 's@/usr/include/linux@${stdenv.gcc.libc}/include/linux@g' -i configure + ''; meta = { - description = "VNC server library"; + inherit (s) version; + description = "VNC server library"; + license = stdenv.lib.licenses.gpl2Plus ; + maintainers = [stdenv.lib.maintainers.raskin]; + platforms = stdenv.lib.platforms.linux; }; } diff --git a/pkgs/development/libraries/libvncserver/default.upstream b/pkgs/development/libraries/libvncserver/default.upstream new file mode 100644 index 000000000000..eae481974398 --- /dev/null +++ b/pkgs/development/libraries/libvncserver/default.upstream @@ -0,0 +1,4 @@ +url http://sourceforge.net/projects/libvncserver/files/libvncserver/ +SF_version_dir +version_link '[.]tar[.][bgx]z[0-9]*/download$' +SF_redirect diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 6fe6ee466caa..5deb63fc8f9d 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -5058,12 +5058,7 @@ let libvisual = callPackage ../development/libraries/libvisual { }; - libvncserver = builderDefsPackage (import ../development/libraries/libvncserver) { - inherit libtool libjpeg openssl zlib; - inherit (xlibs) xproto libX11 damageproto libXdamage - libXext xextproto fixesproto libXfixes xineramaproto - libXinerama libXrandr randrproto libXtst; - }; + libvncserver = callPackage ../development/libraries/libvncserver {}; libviper = callPackage ../development/libraries/libviper { };