Add expression for PolyML
[nixpkgs-libre.git] / pkgs / top-level / all-packages.nix
blob480b39b968e6dae7d6d8f0162f9da5edf08ca8e9
1 /* This file composes the Nix Packages collection.  That is, it
2    imports the functions that build the various packages, and calls
3    them with appropriate arguments.  The result is a set of all the
4    packages in the Nix Packages collection for some particular
5    platform.
7    You want to get to know where to add a new package ?
8    Have a look at nixpkgs/maintainers/docs/classification.txt */
11 { # The system (e.g., `i686-linux') for which to build the packages.
12   system ? builtins.currentSystem
14   # Usually, the system type uniquely determines the stdenv and thus
15   # how to build the packages.  But on some platforms we have
16   # different stdenvs, leading to different ways to build the
17   # packages.  For instance, on Windows we support both Cygwin and
18   # Mingw builds.  In both cases, `system' is `i686-cygwin'.  The
19   # attribute `stdenvType' is used to select the specific kind of
20   # stdenv to use, e.g., `i686-mingw'.
21 , stdenvType ? system
23 , # The standard environment to use.  Only used for bootstrapping.  If
24   # null, the default standard environment is used.
25   bootStdenv ? null
27   # More flags for the bootstrapping of stdenv.
28 , noSysDirs ? true
29 , gccWithCC ? true
30 , gccWithProfiling ? true
32 , # Allow a configuration attribute set to be passed in as an
33   # argument.  Otherwise, it's read from $NIXPKGS_CONFIG or
34   # ~/.nixpkgs/config.nix.
35   config ? null
39 let config_ = config; in # rename the function argument
41 let
43   lib = import ../lib; # see also libTests below
45   # The contents of the configuration file found at $NIXPKGS_CONFIG or
46   # $HOME/.nixpkgs/config.nix.
47   # for NIXOS (nixos-rebuild): use nixpkgs.config option
48   config =
49     let
50       toPath = builtins.toPath;
51       getEnv = x: if builtins ? getEnv then builtins.getEnv x else "";
52       pathExists = name:
53         builtins ? pathExists && builtins.pathExists (toPath name);
55       configFile = getEnv "NIXPKGS_CONFIG";
56       homeDir = getEnv "HOME";
57       configFile2 = homeDir + "/.nixpkgs/config.nix";
59       configExpr =
60         if config_ != null then config_
61         else if configFile != "" && pathExists configFile then import (toPath configFile)
62         else if homeDir != "" && pathExists configFile2 then import (toPath configFile2)
63         else {};
65     in
66       # allow both:
67       # { /* the config */ } and
68       # { pkgsOrig, pkgs, ... } : { /* the config */ }
69       if builtins.isFunction configExpr
70         then configExpr { inherit pkgs pkgsOrig; }
71         else configExpr;
73   # Return an attribute from the Nixpkgs configuration file, or
74   # a default value if the attribute doesn't exist.
75   getConfig = attrPath: default: lib.attrByPath attrPath default config;
78   # Helper functions that are exported through `pkgs'.
79   helperFunctions =
80     (import ../stdenv/adapters.nix { inherit (pkgs) dietlibc fetchurl runCommand; }) //
81     (import ../build-support/trivial-builders.nix { inherit (pkgs) stdenv; inherit (pkgs.xorg) lndir; });
84   # Allow packages to be overriden globally via the `packageOverrides'
85   # configuration option, which must be a function that takes `pkgs'
86   # as an argument and returns a set of new or overriden packages.
87   # `__overrides' is a magic attribute that causes the attributes in
88   # its value to be added to the surrounding `rec'.  The
89   # `packageOverrides' function is called with the *original*
90   # (un-overriden) set of packages, allowing packageOverrides
91   # attributes to refer to the original attributes (e.g. "foo =
92   # ... pkgs.foo ...").
93   __overrides = (getConfig ["packageOverrides"] (pkgs: {})) pkgsOrig;
95   pkgsOrig = pkgsFun {}; # the un-overriden packages, passed to packageOverrides
96   pkgsOverriden = pkgsFun __overrides; # the overriden, final packages
97   pkgs = pkgsOverriden // helperFunctions;
100   # The package compositions.  Yes, this isn't properly indented.
101   pkgsFun = __overrides: with helperFunctions; rec {
104   inherit __overrides;
107   # For convenience, allow callers to get the path to Nixpkgs.
108   path = ../..;
111   ### Symbolic names.
114   x11 = xlibsWrapper;
116   # `xlibs' is the set of X library components.  This used to be the
117   # old modular X libraries project (called `xlibs') but now it's just
118   # the set of packages in the modular X.org tree (which also includes
119   # non-library components like the server, drivers, fonts, etc.).
120   xlibs = xorg // {xlibs = xlibsWrapper;};
123   ### Helper functions.
126   inherit lib config getConfig;
128   inherit (lib) lowPrio appendToName makeOverridable;
130   # Applying this to an attribute set will cause nix-env to look
131   # inside the set for derivations.
132   recurseIntoAttrs = attrs: attrs // {recurseForDerivations = true;};
134   useFromStdenv = it : alternative : if (builtins.hasAttr it stdenv) then
135     (builtins.getAttr it stdenv) else alternative;
137   # Return the first available value in the order: pkg.val, val, or default.
138   getPkgConfig = pkg : val : default : (getConfig [ pkg val ] (getConfig [ val ] default));
140   # Check absence of non-used options
141   checker = x: flag: opts: config:
142     (if flag then let result=(
143       (import ../build-support/checker)
144       opts config); in
145       (if (result=="") then x else
146       abort ("Unknown option specified: " + result))
147     else x);
149   builderDefs = composedArgsAndFun (import ../build-support/builder-defs/builder-defs.nix) {
150     inherit stringsWithDeps lib stdenv writeScript
151       fetchurl fetchmtn fetchgit;
152   };
154   composedArgsAndFun = lib.composedArgsAndFun;
156   builderDefsPackage = builderDefs.builderDefsPackage builderDefs;
158   stringsWithDeps = lib.stringsWithDeps;
161   ### STANDARD ENVIRONMENT
164   allStdenvs = import ../stdenv {
165     inherit system stdenvType;
166     allPackages = args: import ./all-packages.nix ({ inherit config; } // args);
167   };
169   defaultStdenv = allStdenvs.stdenv;
171   stdenv =
172     if bootStdenv != null then bootStdenv else
173       let changer = getConfig ["replaceStdenv"] null;
174       in if changer != null then
175         changer {
176           stdenv = defaultStdenv;
177           overrideSetup = overrideSetup;
178         }
179       else defaultStdenv;
181   # A stdenv capable of building 32-bit binaries.  On x86_64-linux,
182   # it uses GCC compiled with multilib support; on i686-linux, it's
183   # just the plain stdenv.
184   stdenv_32bit =
185     if system == "x86_64-linux" then
186       overrideGCC stdenv gcc43_multi
187     else
188       stdenv;
191   ### BUILD SUPPORT
193   attrSetToDir = arg : import ../build-support/upstream-updater/attrset-to-dir.nix {
194     inherit writeTextFile stdenv lib;
195     theAttrSet = arg;
196   };
198   buildEnv = import ../build-support/buildenv {
199     inherit stdenv perl;
200   };
202   debPackage = {
203     debBuild = lib.sumTwoArgs(import ../build-support/deb-package) {
204       inherit builderDefs;
205     };
206     inherit fetchurl stdenv;
207   };
209   fetchbzr = import ../build-support/fetchbzr {
210     inherit stdenv bazaar;
211   };
213   fetchcvs = import ../build-support/fetchcvs {
214     inherit stdenv cvs;
215   };
217   fetchdarcs = import ../build-support/fetchdarcs {
218     inherit stdenv darcs nix;
219   };
221   fetchgit = import ../build-support/fetchgit {
222     inherit stdenv git;
223   };
225   fetchmtn = import ../build-support/fetchmtn {
226     inherit monotone stdenv;
227     cacheDB = getConfig ["fetchmtn" "cacheDB"] "";
228     defaultDBMirrors = getConfig ["fetchmtn" "defaultDBMirrors"] [];
229   };
231   fetchsvn = import ../build-support/fetchsvn {
232     inherit stdenv subversion openssh;
233     sshSupport = true;
234   };
236   fetchsvnssh = import ../build-support/fetchsvnssh {
237     inherit stdenv subversion openssh expect;
238     sshSupport = true;
239   };
241   fetchhg = import ../build-support/fetchhg {
242     inherit stdenv mercurial nix;
243   };
245   # `fetchurl' downloads a file from the network.  The `useFromStdenv'
246   # is there to allow stdenv to determine fetchurl.  Used during the
247   # stdenv-linux bootstrap phases to prevent lots of different curls
248   # from being built.
249   fetchurl = useFromStdenv "fetchurl"
250     (import ../build-support/fetchurl {
251       inherit curl stdenv;
252     });
254   # fetchurlBoot is used for curl and its dependencies in order to
255   # prevent a cyclic dependency (curl depends on curl.tar.bz2,
256   # curl.tar.bz2 depends on fetchurl, fetchurl depends on curl).  It
257   # uses the curl from the previous bootstrap phase (e.g. a statically
258   # linked curl in the case of stdenv-linux).
259   fetchurlBoot = stdenv.fetchurlBoot;
261   resolveMirrorURLs = {url}: fetchurl {
262     showURLs = true;
263     inherit url;
264   };
266   makeDesktopItem = import ../build-support/make-desktopitem {
267     inherit stdenv;
268   };
270   makeInitrd = {contents}: import ../build-support/kernel/make-initrd.nix {
271     inherit stdenv perl cpio contents;
272   };
274   makeWrapper = makeSetupHook ../build-support/make-wrapper/make-wrapper.sh;
276   makeModulesClosure = {kernel, rootModules, allowMissing ? false}:
277     import ../build-support/kernel/modules-closure.nix {
278       inherit stdenv module_init_tools kernel nukeReferences
279         rootModules allowMissing;
280     };
282   pathsFromGraph = ../build-support/kernel/paths-from-graph.pl;
284   srcOnly = args: (import ../build-support/src-only) ({inherit stdenv; } // args);
286   substituteAll = import ../build-support/substitute/substitute-all.nix {
287     inherit stdenv;
288   };
290   nukeReferences = import ../build-support/nuke-references/default.nix {
291     inherit stdenv;
292   };
294   vmTools = import ../build-support/vm/default.nix {
295     inherit pkgs;
296   };
298   releaseTools = import ../build-support/release/default.nix {
299     inherit pkgs;
300   };
302   composableDerivation = (import ../lib/composable-derivation.nix) {
303     inherit pkgs lib;
304   };
307   ### TOOLS
309   acct = import ../tools/system/acct {
310     inherit fetchurl stdenv;
311   };
313   aefs = import ../tools/filesystems/aefs {
314     inherit fetchurl stdenv fuse;
315   };
317   aircrackng = import ../tools/networking/aircrack-ng {
318     inherit fetchurl stdenv libpcap openssl zlib wirelesstools;
319   };
321   ec2apitools = import ../tools/virtualization/amazon-ec2-api-tools {
322     inherit stdenv fetchurl unzip ;
323   };
325   amule = import ../tools/networking/p2p/amule {
326     inherit fetchurl stdenv zlib perl cryptopp gettext libupnp makeWrapper;
327     inherit wxGTK;
328   };
330   aria = builderDefsPackage (import ../tools/networking/aria) {
331   };
333   at = import ../tools/system/at {
334     inherit fetchurl stdenv bison flex pam ssmtp;
335   };
337   autogen = import ../development/tools/misc/autogen {
338     inherit fetchurl stdenv guile which;
339   };
341   autojump = import ../tools/misc/autojump {
342     inherit fetchurl stdenv python;
343   };
345   avahi =
346     let qt4Support = getConfig [ "avahi" "qt4Support" ] false;
347     in
348       makeOverridable (import ../development/libraries/avahi) {
349         inherit stdenv fetchurl pkgconfig libdaemon dbus perl perlXMLParser
350           expat gettext intltool lib;
351         inherit (gtkLibs) glib gtk;
352         inherit qt4Support;
353         qt4 = if qt4Support then qt4 else null;
354       };
356   axel = import ../tools/networking/axel {
357     inherit fetchurl stdenv;
358   };
360   azureus = import ../tools/networking/p2p/azureus {
361     inherit fetchurl stdenv jdk swt;
362   };
364   bc = import ../tools/misc/bc {
365     inherit fetchurl stdenv flex readline;
366   };
368   bfr = import ../tools/misc/bfr {
369     inherit fetchurl stdenv perl;
370   };
372   bootchart = import ../tools/system/bootchart {
373     inherit fetchurl stdenv gnutar gzip coreutils utillinux gnugrep gnused psmisc nettools;
374   };
376   btrfsProgs = builderDefsPackage (import ../tools/filesystems/btrfsprogs) {
377     inherit libuuid zlib acl;
378   };
380   eggdrop = import ../tools/networking/eggdrop {
381     inherit fetchurl stdenv tcl;
382   };
384   mcrl = import ../tools/misc/mcrl {
385     inherit fetchurl stdenv coreutils;
386   };
388   mcrl2 = import ../tools/misc/mcrl2 {
389     inherit fetchurl stdenv mesa ;
390     inherit (xorg) libX11;
391     inherit wxGTK;
392   };
394   syslogng = import ../tools/misc/syslog-ng {
395     inherit fetchurl stdenv eventlog pkgconfig glib;
396   };
398   asciidoc = import ../tools/typesetting/asciidoc {
399     inherit fetchurl stdenv python;
400   };
402   bibtextools = import ../tools/typesetting/bibtex-tools {
403     inherit fetchurl stdenv aterm tetex hevea;
404     inherit (strategoPackages016) strategoxt sdf;
405   };
407   bittorrent = import ../tools/networking/p2p/bittorrent {
408     inherit fetchurl stdenv makeWrapper python pycrypto twisted;
409     wxPython = wxPython26;
410     gui = true;
411   };
413   bittornado = import ../tools/networking/p2p/bit-tornado {
414     inherit fetchurl stdenv python wxPython26;
415   };
417   bmrsa = builderDefsPackage (import ../tools/security/bmrsa/11.nix) {
418     inherit unzip;
419   };
421   bogofilter = import ../tools/misc/bogofilter {
422     inherit fetchurl stdenv flex;
423     bdb = db4;
424   };
426   bsdiff = import ../tools/compression/bsdiff {
427     inherit fetchurl stdenv;
428   };
430   bzip2 = useFromStdenv "bzip2"
431     (import ../tools/compression/bzip2 {
432       inherit fetchurl stdenv;
433     });
435   cabextract = import ../tools/archivers/cabextract {
436     inherit fetchurl stdenv;
437   };
439   ccrypt = import ../tools/security/ccrypt {
440     inherit fetchurl stdenv;
441   };
443   cdecl = import ../development/tools/cdecl {
444     inherit fetchurl stdenv yacc flex readline ncurses;
445   };
447   cdrdao = import ../tools/cd-dvd/cdrdao {
448     inherit fetchurl stdenv lame libvorbis libmad pkgconfig libao;
449   };
451   cdrkit = import ../tools/cd-dvd/cdrkit {
452     inherit fetchurl stdenv cmake libcap zlib bzip2;
453   };
455   checkinstall = import ../tools/package-management/checkinstall {
456     inherit fetchurl stdenv gettext;
457   };
459   cheetahTemplate = builderDefsPackage (import ../tools/text/cheetah-template/2.0.1.nix) {
460     inherit makeWrapper python;
461   };
463   chkrootkit = import ../tools/security/chkrootkit {
464     inherit fetchurl stdenv;
465   };
467   cksfv = import ../tools/networking/cksfv {
468     inherit fetchurl stdenv;
469   };
471   convertlit = import ../tools/text/convertlit {
472     inherit fetchurl stdenv unzip libtommath;
473   };
475   unifdef = import ../development/tools/misc/unifdef {
476     inherit fetchurl stdenv;
477   };
479   cloogppl = import ../development/libraries/cloog-ppl {
480     inherit fetchurl stdenv ppl;
481   };
483   coreutils = useFromStdenv "coreutils"
484     (makeOverridable (if stdenv ? isDietLibC
485       then import ../tools/misc/coreutils-5
486       else import ../tools/misc/coreutils)
487     {
488       inherit fetchurl stdenv acl;
489       aclSupport = stdenv.isLinux;
490     });
492   cpio = import ../tools/archivers/cpio {
493     inherit fetchurl stdenv;
494   };
496   cromfs = import ../tools/archivers/cromfs {
497     inherit fetchurl stdenv pkgconfig fuse perl;
498   };
500   cron = import ../tools/system/cron { # see also fcron
501     inherit fetchurl stdenv;
502   };
504   curl = import ../tools/networking/curl {
505     fetchurl = fetchurlBoot;
506     inherit stdenv zlib openssl;
507     zlibSupport = ! ((stdenv ? isDietLibC) || (stdenv ? isStatic));
508     sslSupport = ! ((stdenv ? isDietLibC) || (stdenv ? isStatic));
509   };
511   curlftpfs = import ../tools/filesystems/curlftpfs {
512     inherit fetchurl stdenv fuse curl pkgconfig zlib glib;
513   };
515   dadadodo = builderDefsPackage (import ../tools/text/dadadodo) {
516   };
518   dar = import ../tools/archivers/dar {
519     inherit fetchurl stdenv zlib bzip2 openssl;
520   };
522   davfs2 = import ../tools/filesystems/davfs2 {
523     inherit fetchurl stdenv zlib;
524     neon = neon028;
525   };
527   dcraw = import ../tools/graphics/dcraw {
528     inherit fetchurl stdenv gettext libjpeg lcms;
529   };
531   debootstrap = import ../tools/misc/debootstrap {
532     inherit fetchurl stdenv lib dpkg gettext gawk wget perl;
533   };
535   ddclient = import ../tools/networking/ddclient {
536     inherit fetchurl buildPerlPackage perl;
537   };
539   ddrescue = import ../tools/system/ddrescue {
540     inherit fetchurl stdenv;
541   };
543   desktop_file_utils = import ../tools/misc/desktop-file-utils {
544     inherit stdenv fetchurl pkgconfig glib;
545   };
547   dev86 = import ../development/compilers/dev86 {
548     inherit fetchurl stdenv;
549   };
551   dnsmasq = import ../tools/networking/dnsmasq {
552     # TODO i18n can be installed as well, implement it?
553     inherit fetchurl stdenv;
554   };
556   dhcp = import ../tools/networking/dhcp {
557     inherit fetchurl stdenv nettools iputils iproute makeWrapper;
558   };
560   dhcpcd = import ../tools/networking/dhcpcd {
561     inherit fetchurl stdenv;
562   };
564   diffstat = import ../tools/text/diffstat {
565     inherit fetchurl stdenv;
566   };
568   diffutils = useFromStdenv "diffutils"
569     (import ../tools/text/diffutils {
570       inherit fetchurl stdenv coreutils;
571     });
573   docbook2x = import ../tools/typesetting/docbook2x {
574     inherit fetchurl stdenv texinfo perl
575             gnused groff libxml2 libxslt makeWrapper;
576     inherit (perlPackages) XMLSAX XMLParser XMLNamespaceSupport;
577     libiconv = if stdenv.isDarwin then libiconv else null;
578   };
580   dosfstools = composedArgsAndFun (import ../tools/filesystems/dosfstools) {
581     inherit builderDefs;
582   };
584   dvdplusrwtools = import ../tools/cd-dvd/dvd+rw-tools {
585     inherit fetchurl stdenv cdrkit m4;
586   };
588   e2fsprogs = import ../tools/filesystems/e2fsprogs {
589     inherit fetchurl stdenv pkgconfig libuuid;
590   };
592   enblendenfuse = import ../tools/graphics/enblend-enfuse {
593     inherit fetchurl stdenv libtiff libpng lcms libxmi boost;
594   };
596   enscript = import ../tools/text/enscript {
597     inherit fetchurl stdenv;
598   };
600   eprover = composedArgsAndFun (import ../tools/misc/eProver) {
601     inherit fetchurl stdenv which;
602     texLive = texLiveAggregationFun {
603       paths = [
604         texLive texLiveExtra
605       ];
606     };
607   };
609   ethtool = import ../tools/misc/ethtool {
610     inherit fetchurl stdenv;
611   };
613   exif = import ../tools/graphics/exif {
614     inherit fetchurl stdenv pkgconfig libexif popt;
615   };
617   exiftags = import ../tools/graphics/exiftags {
618     inherit stdenv fetchurl;
619   };
621   expect = import ../tools/misc/expect {
622     inherit fetchurl stdenv tcl tk autoconf;
623     inherit (xorg) xproto libX11;
624   };
626   fcron = import ../tools/system/fcron { # see also cron
627     inherit fetchurl stdenv perl;
628   };
630   fdisk = import ../tools/system/fdisk {
631     inherit fetchurl stdenv parted libuuid gettext;
632   };
634   figlet = import ../tools/misc/figlet {
635     inherit fetchurl stdenv;
636   };
638   file = import ../tools/misc/file {
639     inherit fetchurl stdenv;
640   };
642   filelight = import ../tools/system/filelight {
643     inherit fetchurl stdenv kdelibs x11 zlib perl libpng;
644     qt = qt3;
645   };
647   findutils = useFromStdenv "findutils"
648     (if stdenv.isDarwin then findutils4227 else
649       import ../tools/misc/findutils {
650         inherit fetchurl stdenv coreutils;
651       }
652     );
654   findutils4227 = import ../tools/misc/findutils/4.2.27.nix {
655     inherit fetchurl stdenv coreutils;
656   };
658   findutilsWrapper = lowPrio (appendToName "wrapper" (import ../tools/misc/findutils-wrapper {
659     inherit stdenv findutils;
660   }));
662   finger_bsd = import ../tools/networking/bsd-finger {
663     inherit fetchurl stdenv;
664   };
666   fontforge = import ../tools/misc/fontforge {
667     inherit fetchurl stdenv gettext freetype zlib
668       libungif libpng libjpeg libtiff libxml2 lib;
669   };
671   fontforgeX = import ../tools/misc/fontforge {
672     inherit fetchurl stdenv gettext freetype zlib
673       libungif libpng libjpeg libtiff libxml2 lib;
674     inherit (xlibs) libX11 xproto libXt;
675   };
677   gawk = useFromStdenv "gawk"
678     (import ../tools/text/gawk {
679       inherit fetchurl stdenv;
680     });
682   gdmap = composedArgsAndFun (import ../tools/system/gdmap/0.8.1.nix) {
683     inherit stdenv fetchurl builderDefs pkgconfig libxml2 intltool
684       gettext;
685     inherit (gtkLibs) gtk;
686   };
688   genext2fs = import ../tools/filesystems/genext2fs {
689     inherit fetchurl stdenv;
690   };
692   getopt = import ../tools/misc/getopt {
693     inherit fetchurl stdenv;
694   };
696   gftp = import ../tools/networking/gftp {
697     inherit lib fetchurl stdenv;
698     inherit readline ncurses gettext openssl pkgconfig;
699     inherit (gtkLibs) glib gtk;
700   };
702   gifsicle = import ../tools/graphics/gifscile {
703     inherit fetchurl stdenv;
704     inherit (xlibs) xproto libXt libX11;
705   };
707   glusterfs = builderDefsPackage ../tools/filesystems/glusterfs {
708     inherit fuse;
709     bison = bison24;
710     flex = flex2535;
711   };
713   glxinfo = import ../tools/graphics/glxinfo {
714     inherit fetchurl stdenv x11 mesa;
715   };
717   gnokii = builderDefsPackage (import ../tools/misc/gnokii) {
718     inherit intltool perl gettext libusb;
719   };
721   gnugrep = useFromStdenv "gnugrep"
722     (import ../tools/text/gnugrep {
723       inherit fetchurl stdenv pcre;
724     });
726   gnupatch = useFromStdenv "patch" (import ../tools/text/gnupatch {
727     inherit fetchurl stdenv;
728   });
730   gnupg = import ../tools/security/gnupg {
731     inherit fetchurl stdenv readline;
732     ideaSupport = getPkgConfig "gnupg" "idea" false; # enable for IDEA crypto support
733   };
735   gnupg2 = import ../tools/security/gnupg2 {
736     inherit fetchurl stdenv readline libgpgerror libgcrypt libassuan pth libksba zlib;
737     openldap = if getPkgConfig "gnupg" "ldap" true then openldap else null;
738     bzip2 = if getPkgConfig "gnupg" "bzip2" true then bzip2 else null;
739     libusb = if getPkgConfig "gnupg" "usb" true then libusb else null;
740     curl = if getPkgConfig "gnupg" "curl" true then curl else null;
741   };
743   gnuplot = import ../tools/graphics/gnuplot {
744     inherit fetchurl stdenv zlib gd texinfo readline emacs;
745     inherit (xlibs) libX11 libXt libXaw libXpm;
746     x11Support = getPkgConfig "gnuplot" "x11" false;
747     wxGTK = if getPkgConfig "gnuplot" "wxGtk" false then wxGTK else null;
748     inherit (gtkLibs) pango;
749     inherit cairo pkgconfig;
750   };
752   gnused = useFromStdenv "gnused"
753     (import ../tools/text/gnused {
754       inherit fetchurl stdenv;
755     });
757   gnused_4_2 = import ../tools/text/gnused/4.2.nix {
758     inherit fetchurl stdenv;
759   };
761   gnutar = useFromStdenv "gnutar"
762     (import ../tools/archivers/gnutar {
763       inherit fetchurl stdenv;
764     });
766   gnuvd = import ../tools/misc/gnuvd {
767     inherit fetchurl stdenv;
768   };
770   graphviz = import ../tools/graphics/graphviz {
771     inherit fetchurl stdenv pkgconfig libpng libjpeg expat x11 yacc
772       libtool fontconfig gd;
773     inherit (xlibs) libXaw;
774     inherit (gtkLibs) pango;
775   };
777   groff = import ../tools/text/groff {
778     inherit fetchurl stdenv perl;
779     ghostscript = null;
780   };
782   grub = import ../tools/misc/grub {
783     inherit fetchurl autoconf automake;
784     stdenv = stdenv_32bit;
785     buggyBiosCDSupport = (getConfig ["grub" "buggyBiosCDSupport"] true);
786   };
788   grub2 = import ../tools/misc/grub/1.9x.nix {
789     inherit stdenv fetchurl bison ncurses libusb freetype;
790   };
792   gssdp = import ../development/libraries/gssdp {
793     inherit fetchurl stdenv pkgconfig libxml2 glib;
794     inherit (gnome) libsoup;
795   };
797   gtkgnutella = import ../tools/networking/p2p/gtk-gnutella {
798     inherit fetchurl stdenv pkgconfig libxml2;
799     inherit (gtkLibs) glib gtk;
800   };
802   gupnp = import ../development/libraries/gupnp {
803     inherit fetchurl stdenv pkgconfig libxml2 gssdp e2fsprogs glib;
804     inherit (gnome) libsoup;
805   };
807   gupnptools = import ../tools/networking/gupnp-tools {
808     inherit fetchurl stdenv gssdp gupnp pkgconfig libxml2 e2fsprogs;
809     inherit (gtkLibs) gtk glib;
810     inherit (gnome) libsoup libglade gnomeicontheme;
811   };
813   gvpe = builderDefsPackage ../tools/networking/gvpe {
814     inherit openssl gmp nettools iproute;
815   };
817   gzip = useFromStdenv "gzip"
818     (import ../tools/compression/gzip {
819       inherit fetchurl stdenv;
820     });
822   pigz = import ../tools/compression/pigz {
823     inherit fetchurl stdenv zlib;
824   };
826   halibut = import ../tools/typesetting/halibut {
827     inherit fetchurl stdenv perl;
828   };
830   hddtemp = import ../tools/misc/hddtemp {
831     inherit fetchurl stdenv;
832   };
834   hevea = import ../tools/typesetting/hevea {
835     inherit fetchurl stdenv ocaml;
836   };
838   highlight = import ../tools/text/highlight {
839     inherit fetchurl stdenv getopt;
840   };
842   host = import ../tools/networking/host {
843     inherit fetchurl stdenv;
844   };
846   iasl = import ../development/compilers/iasl {
847     inherit fetchurl stdenv bison flex;
848   };
850   idutils = import ../tools/misc/idutils {
851     inherit fetchurl stdenv emacs;
852   };
854   iftop = import ../tools/networking/iftop {
855     inherit fetchurl stdenv ncurses libpcap;
856   };
858   imapsync = import ../tools/networking/imapsync {
859     inherit fetchurl stdenv perl openssl;
860     inherit (perlPackages) MailIMAPClient;
861   };
863   inetutils = import ../tools/networking/inetutils {
864     inherit fetchurl stdenv;
865   };
867   iodine = import ../tools/networking/iodine {
868     inherit stdenv fetchurl zlib nettools;
869   };
871   iperf = import ../tools/networking/iperf {
872     inherit fetchurl stdenv;
873   };
875   jdiskreport = import ../tools/misc/jdiskreport {
876     inherit fetchurl stdenv unzip jdk;
877   };
879   jfsrec = import ../tools/filesystems/jfsrec {
880     inherit fetchurl stdenv boost;
881   };
883   jfsutils = import ../tools/filesystems/jfsutils {
884     inherit fetchurl stdenv libuuid;
885   };
887   jhead = import ../tools/graphics/jhead {
888     inherit stdenv fetchurl;
889   };
891   jing = import ../tools/text/xml/jing {
892     inherit fetchurl stdenv unzip;
893   };
895   jing_tools = import ../tools/text/xml/jing/jing-script.nix {
896     inherit fetchurl stdenv unzip jre;
897   };
899   jnettop = import ../tools/networking/jnettop {
900     inherit fetchurl stdenv autoconf libpcap ncurses pkgconfig;
901     inherit (gnome) glib;
902   };
904   jwhois = import ../tools/networking/jwhois {
905     inherit fetchurl stdenv;
906   };
908   keychain = import ../tools/misc/keychain {
909     inherit fetchurl stdenv;
910   };
912   kismet = import ../applications/networking/sniffers/kismet {
913     inherit fetchurl stdenv libpcap ncurses expat;
914   };
916   ktorrent = import ../tools/networking/p2p/ktorrent {
917     inherit fetchurl stdenv pkgconfig kdelibs
918       xlibs zlib libpng libjpeg perl gmp;
919   };
921   less = import ../tools/misc/less {
922     inherit fetchurl stdenv ncurses;
923   };
925   lftp = import ../tools/networking/lftp {
926     inherit fetchurl stdenv readline;
927   };
929   libtorrent = import ../tools/networking/p2p/libtorrent {
930     inherit fetchurl stdenv pkgconfig openssl libsigcxx;
931   };
933   lout = import ../tools/typesetting/lout {
934     inherit fetchurl stdenv ghostscript;
935   };
937   lrzip = import ../tools/compression/lrzip {
938     inherit fetchurl stdenv zlib lzo bzip2 nasm;
939   };
941   lsh = import ../tools/networking/lsh {
942     inherit stdenv fetchurl gperf guile gmp zlib liboop gnum4 pam
943       readline nettools lsof procps;
944   };
946   lzma = import ../tools/compression/lzma {
947     inherit fetchurl stdenv;
948   };
950   xz = import ../tools/compression/xz {
951     inherit fetchurl stdenv lib;
952   };
954   lzop = import ../tools/compression/lzop {
955     inherit fetchurl stdenv lzo;
956   };
958   mailutils = import ../tools/networking/mailutils {
959     inherit fetchurl stdenv gettext gdbm libtool pam readline ncurses
960       gnutls mysql guile texinfo gnum4;
961   };
963   man = import ../tools/misc/man {
964     inherit fetchurl stdenv groff less;
965   };
967   man_db = import ../tools/misc/man-db {
968     inherit fetchurl stdenv db4 groff;
969   };
971   memtest86 = import ../tools/misc/memtest86 {
972     inherit fetchurl stdenv;
973   };
975   mc = import ../tools/misc/mc {
976     inherit fetchurl stdenv lib pkgconfig ncurses shebangfix perl zip unzip slang
977       gettext e2fsprogs gpm glib;
978     inherit (xlibs) libX11 libXt;
979   };
981   mcabber = import ../applications/networking/instant-messengers/mcabber {
982     inherit fetchurl stdenv openssl ncurses pkgconfig glib;
983   };
985   mcron = import ../tools/system/mcron {
986     inherit fetchurl stdenv guile which ed;
987   };
989   mdbtools = import ../tools/misc/mdbtools {
990     inherit fetchurl stdenv readline pkgconfig bison glib;
991     flex = flex2535;
992   };
994   mjpegtools = import ../tools/video/mjpegtools {
995     inherit fetchurl stdenv libjpeg;
996     inherit (xlibs) libX11;
997   };
999   mktemp = import ../tools/security/mktemp {
1000     inherit fetchurl stdenv;
1001   };
1003   mldonkey = import ../applications/networking/p2p/mldonkey {
1004     inherit fetchurl stdenv ocaml zlib ncurses;
1005   };
1007   monit = builderDefsPackage ../tools/system/monit {
1008     flex = flex2535;
1009     bison = bison24;
1010     inherit openssl;
1011   };
1013   mpage = import ../tools/text/mpage {
1014     inherit fetchurl stdenv;
1015   };
1017   msf = builderDefsPackage (import ../tools/security/metasploit/3.1.nix) {
1018     inherit ruby makeWrapper;
1019   };
1021   mssys = import ../tools/misc/mssys {
1022     inherit fetchurl stdenv gettext;
1023   };
1025   multitran = recurseIntoAttrs (let
1026       inherit fetchurl stdenv help2man;
1027     in rec {
1028       multitrandata = import ../tools/text/multitran/data {
1029         inherit fetchurl stdenv;
1030       };
1032       libbtree = import ../tools/text/multitran/libbtree {
1033         inherit fetchurl stdenv;
1034       };
1036       libmtsupport = import ../tools/text/multitran/libmtsupport {
1037         inherit fetchurl stdenv;
1038       };
1040       libfacet = import ../tools/text/multitran/libfacet {
1041         inherit fetchurl stdenv libmtsupport;
1042       };
1044       libmtquery = import ../tools/text/multitran/libmtquery {
1045         inherit fetchurl stdenv libmtsupport libfacet libbtree multitrandata;
1046       };
1048       mtutils = import ../tools/text/multitran/mtutils {
1049         inherit fetchurl stdenv libmtsupport libfacet libbtree libmtquery help2man;
1050       };
1051     });
1053   mysql2pgsql = import ../tools/misc/mysql2pgsql {
1054     inherit fetchurl stdenv perl shebangfix;
1055   };
1057   namazu = import ../tools/text/namazu {
1058     inherit fetchurl stdenv perl;
1059   };
1061   nbd = import ../tools/networking/nbd {
1062     inherit fetchurl stdenv pkgconfig glib;
1063   };
1065   nc6 = composedArgsAndFun (import ../tools/networking/nc6/1.0.nix) {
1066     inherit builderDefs;
1067   };
1069   ncat = import ../tools/networking/ncat {
1070     inherit fetchurl stdenv openssl;
1071   };
1073   ncftp = import ../tools/networking/ncftp {
1074     inherit fetchurl stdenv ncurses coreutils;
1075   };
1077   netcat = import ../tools/networking/netcat {
1078     inherit fetchurl stdenv;
1079   };
1081   netkittftp = import ../tools/networking/netkit/tftp {
1082     inherit fetchurl stdenv;
1083   };
1085   netpbm = import ../tools/graphics/netpbm {
1086     inherit stdenv fetchsvn libjpeg libpng zlib flex perl libxml2;
1087   };
1089   netselect = import ../tools/networking/netselect {
1090     inherit fetchurl stdenv;
1091   };
1093   nmap = import ../tools/security/nmap {
1094     inherit fetchurl stdenv libpcap pkgconfig openssl
1095       python pygtk makeWrapper pygobject pycairo;
1096     inherit (pythonPackages) pysqlite;
1097     inherit (xlibs) libX11;
1098     inherit (gtkLibs) gtk;
1099   };
1101   ntfs3g = import ../tools/filesystems/ntfs-3g {
1102     inherit fetchurl stdenv utillinux;
1103   };
1105   ntfsprogs = import ../tools/filesystems/ntfsprogs {
1106     inherit fetchurl stdenv libuuid;
1107   };
1109   ntp = import ../tools/networking/ntp {
1110     inherit fetchurl stdenv libcap;
1111   };
1113   nssmdns = import ../tools/networking/nss-mdns {
1114     inherit fetchurl stdenv avahi;
1115   };
1117   nylon = import ../tools/networking/nylon {
1118     inherit fetchurl stdenv libevent;
1119   };
1121   obexd = import ../tools/bluetooth/obexd {
1122     inherit fetchurl stdenv pkgconfig dbus openobex bluez glib;
1123   };
1125   obexfs = import ../tools/bluetooth/obexfs {
1126     inherit fetchurl stdenv pkgconfig fuse obexftp;
1127   };
1129   obexftp = import ../tools/bluetooth/obexftp {
1130     inherit fetchurl stdenv pkgconfig openobex bluez;
1131   };
1133   openjade = import ../tools/text/sgml/openjade {
1134     inherit fetchurl opensp perl;
1135     stdenv = overrideGCC stdenv gcc33;
1136   };
1138   openobex = import ../tools/bluetooth/openobex {
1139     inherit fetchurl stdenv pkgconfig bluez libusb;
1140   };
1142   openssh = import ../tools/networking/openssh {
1143     inherit fetchurl stdenv zlib openssl pam perl;
1144     pamSupport = getPkgConfig "openssh" "pam" true;
1145     hpnSupport = getConfig [ "openssh" "hpn" ] false;
1146     etcDir = getConfig [ "openssh" "etcDir" ] "/etc/ssh";
1147   };
1149   opensp = import ../tools/text/sgml/opensp {
1150     inherit fetchurl;
1151     stdenv = overrideGCC stdenv gcc33;
1152   };
1154   openvpn = import ../tools/networking/openvpn {
1155     inherit fetchurl stdenv iproute lzo openssl nettools;
1156   };
1158   p7zip = import ../tools/archivers/p7zip {
1159     inherit fetchurl stdenv;
1160   };
1162   panomatic = import ../tools/graphics/panomatic {
1163     inherit fetchurl stdenv boost zlib;
1164   };
1166   par2cmdline = import ../tools/networking/par2cmdline {
1167     inherit fetchurl stdenv;
1168   };
1170   patchutils = import ../tools/text/patchutils {
1171     inherit fetchurl stdenv;
1172   };
1174   parted = import ../tools/misc/parted {
1175     inherit fetchurl stdenv devicemapper libuuid gettext readline;
1176   };
1178   patch = gnupatch;
1180   pciutils = import ../tools/system/pciutils {
1181     inherit fetchurl stdenv zlib;
1182   };
1184   pdf2djvu = import ../tools/typesetting/pdf2djvu {
1185     inherit fetchurl stdenv pkgconfig djvulibre poppler fontconfig libjpeg;
1186   };
1188   pdfjam = import ../tools/typesetting/pdfjam {
1189     inherit fetchurl stdenv;
1190   };
1192   pg_top = import ../tools/misc/pg_top {
1193     inherit fetchurl stdenv ncurses postgresql;
1194   };
1196   pdsh = import ../tools/networking/pdsh {
1197     inherit fetchurl stdenv perl;
1198     readline = if getPkgConfig "pdsh" "readline" true then readline else null;
1199     rsh = getPkgConfig "pdsh" "rsh" true;
1200     ssh = if getPkgConfig "pdsh" "ssh" true then openssh else null;
1201     pam = if getPkgConfig "pdsh" "pam" true then pam else null;
1202   };
1204   pfstools = import ../tools/graphics/pfstools {
1205     inherit fetchurl stdenv imagemagick libjpeg libtiff mesa freeglut bzip2 libpng expat;
1206     openexr = openexr_1_6_1;
1207     qt = qt3;
1208     inherit (xlibs) libX11;
1209   };
1211   pinentry = import ../tools/misc/pinentry {
1212     inherit fetchurl stdenv pkgconfig ncurses;
1213     inherit (gnome) glib gtk;
1214   };
1216   plan9port = import ../tools/system/plan9port {
1217     inherit fetchurl stdenv;
1218     inherit (xlibs) libX11 xproto libXt xextproto;
1219   };
1221   ploticus = import ../tools/graphics/ploticus {
1222     inherit fetchurl stdenv zlib libpng;
1223     inherit (xlibs) libX11;
1224   };
1226   plotutils = import ../tools/graphics/plotutils {
1227     inherit fetchurl stdenv libpng;
1228   };
1230   povray = import ../tools/graphics/povray {
1231     inherit fetchurl stdenv;
1232   };
1234   ppl = import ../development/libraries/ppl {
1235     inherit fetchurl stdenv gmpxx perl gnum4;
1236   };
1238   /* WARNING: this version is unsuitable for using with a setuid wrapper */
1239   ppp = builderDefsPackage (import ../tools/networking/ppp) {
1240   };
1242   proxychains = import ../tools/networking/proxychains {
1243     inherit fetchurl stdenv;
1244   };
1246   proxytunnel = import ../tools/misc/proxytunnel {
1247     inherit fetchurl stdenv openssl;
1248   };
1250   psmisc = import ../tools/misc/psmisc {
1251     inherit stdenv fetchurl ncurses;
1252   };
1254   pstoedit = import ../tools/graphics/pstoedit {
1255     inherit fetchurl stdenv lib pkgconfig ghostscript gd zlib plotutils;
1256   };
1258   pv = import ../tools/misc/pv {
1259     inherit fetchurl stdenv;
1260   };
1262   pwgen = import ../tools/security/pwgen {
1263     inherit stdenv fetchurl;
1264   };
1266   pydb = import ../tools/pydb {
1267     inherit fetchurl stdenv python emacs;
1268   };
1270   pystringtemplate = import ../development/python-modules/stringtemplate {
1271     inherit stdenv fetchurl python antlr;
1272   };
1274   pythonDBus = builderDefsPackage (import ../development/python-modules/dbus) {
1275     inherit python pkgconfig dbus_glib;
1276     dbus = dbus.libs;
1277   };
1279   pythonIRClib = builderDefsPackage (import ../development/python-modules/irclib) {
1280     inherit python;
1281   };
1283   pythonSexy = builderDefsPackage (import ../development/python-modules/libsexy) {
1284     inherit python libsexy pkgconfig libxml2 pygtk;
1285     inherit (gtkLibs) pango gtk glib;
1286   };
1288   openmpi = import ../development/libraries/openmpi {
1289     inherit fetchurl stdenv;
1290   };
1292   qhull = import ../development/libraries/qhull {
1293     inherit stdenv fetchurl;
1294   };
1296   reiser4progs = import ../tools/filesystems/reiser4progs {
1297     inherit fetchurl stdenv libaal;
1298   };
1300   reiserfsprogs = import ../tools/filesystems/reiserfsprogs {
1301     inherit fetchurl stdenv;
1302   };
1304   relfs = composedArgsAndFun (import ../tools/filesystems/relfs) {
1305     inherit fetchcvs stdenv ocaml postgresql fuse pcre
1306       builderDefs pkgconfig libuuid;
1307     inherit (gnome) gnomevfs GConf;
1308   };
1310   remind = import ../tools/misc/remind {
1311     inherit fetchurl stdenv;
1312   };
1314   replace = import ../tools/text/replace {
1315     inherit fetchurl stdenv;
1316   };
1318   /*
1319   rdiff_backup = import ../tools/backup/rdiff-backup {
1320     inherit fetchurl stdenv librsync gnused;
1321     python=python;
1322   };
1323   */
1325   rsnapshot = import ../tools/backup/rsnapshot {
1326     inherit fetchurl stdenv perl openssh rsync;
1328     # For the `logger' command, we can use either `utillinux' or
1329     # GNU Inetutils.  The latter is more portable.
1330     logger = inetutils;
1331   };
1333   rlwrap = composedArgsAndFun (import ../tools/misc/rlwrap/0.28.nix) {
1334     inherit builderDefs readline;
1335   };
1337   rpPPPoE = builderDefsPackage (import ../tools/networking/rp-pppoe) {
1338     inherit ppp;
1339   };
1341   rpm = import ../tools/package-management/rpm {
1342     inherit fetchurl stdenv cpio zlib bzip2 xz file elfutils nspr nss popt;
1343     db4 = db45;
1344   };
1346   rrdtool = import ../tools/misc/rrdtool {
1347     inherit stdenv fetchurl gettext perl pkgconfig libxml2 cairo;
1348     inherit (gtkLibs) pango;
1349   };
1351   rtorrent = import ../tools/networking/p2p/rtorrent {
1352     inherit fetchurl stdenv libtorrent ncurses pkgconfig libsigcxx curl zlib openssl;
1353   };
1355   rubber = import ../tools/typesetting/rubber {
1356     inherit fetchurl stdenv python texinfo;
1357   };
1359   rxp = import ../tools/text/xml/rxp {
1360     inherit fetchurl stdenv;
1361   };
1363   rzip = import ../tools/compression/rzip {
1364     inherit fetchurl stdenv bzip2;
1365   };
1367   s3backer = import ../tools/filesystems/s3backer {
1368     inherit fetchurl stdenv pkgconfig fuse curl expat;
1369   };
1371   sablotron = import ../tools/text/xml/sablotron {
1372     inherit fetchurl stdenv expat;
1373   };
1375   screen = import ../tools/misc/screen {
1376     inherit fetchurl stdenv ncurses;
1377   };
1379   scrot = import ../tools/graphics/scrot {
1380     inherit fetchurl stdenv giblib x11;
1381   };
1383   seccure = import ../tools/security/seccure/0.4.nix {
1384     inherit fetchurl stdenv libgcrypt;
1385   };
1387   setserial = builderDefsPackage (import ../tools/system/setserial) {
1388     inherit groff;
1389   };
1391   sharutils = import ../tools/archivers/sharutils/4.6.3.nix {
1392     inherit fetchurl stdenv;
1393   };
1395   shebangfix = import ../tools/misc/shebangfix {
1396     inherit stdenv perl;
1397   };
1399   slsnif = import ../tools/misc/slsnif {
1400     inherit fetchurl stdenv;
1401   };
1403   smartmontools = import ../tools/system/smartmontools {
1404     inherit fetchurl stdenv;
1405   };
1407   smbfsFuse = composedArgsAndFun (import ../tools/filesystems/smbfs-fuse) {
1408     inherit builderDefs samba fuse;
1409   };
1411   socat = import ../tools/networking/socat {
1412     inherit fetchurl stdenv openssl;
1413   };
1415   socat2pre = builderDefsPackage ../tools/networking/socat/2.0.0-b3.nix {
1416     inherit fetchurl stdenv openssl;
1417   };
1419   squashfsTools = import ../tools/filesystems/squashfs {
1420     inherit fetchurl stdenv zlib;
1421   };
1423   sshfsFuse = import ../tools/filesystems/sshfs-fuse {
1424     inherit fetchurl stdenv pkgconfig fuse glib;
1425   };
1427   sudo = import ../tools/security/sudo {
1428     inherit fetchurl stdenv coreutils pam groff;
1429   };
1431   suidChroot = builderDefsPackage (import ../tools/system/suid-chroot) {
1432   };
1434   superkaramba = import ../desktops/superkaramba {
1435     inherit stdenv fetchurl kdebase kdelibs zlib libjpeg
1436       perl qt3 python libpng freetype expat;
1437     inherit (xlibs) libX11 libXext libXt libXaw libXpm;
1438   };
1440   ssmtp = import ../tools/networking/ssmtp {
1441     inherit fetchurl stdenv openssl;
1442     tlsSupport = true;
1443   };
1445   ssss = composedArgsAndFun (import ../tools/security/ssss/0.5.nix) {
1446     inherit builderDefs gmp;
1447   };
1449   stun = import ../tools/networking/stun {
1450     inherit fetchurl stdenv lib;
1451   };
1453   stunnel = import ../tools/networking/stunnel {
1454     inherit fetchurl stdenv openssl;
1455   };
1457   su = import ../tools/misc/su {
1458     inherit fetchurl stdenv pam;
1459   };
1461   system_config_printer = import ../tools/misc/system-config-printer {
1462     inherit stdenv fetchurl perl perlXMLParser desktop_file_utils;
1463   };
1465   sitecopy = import ../tools/networking/sitecopy {
1466     inherit fetchurl stdenv neon openssl;
1467   };
1469   privoxy = import ../tools/networking/privoxy {
1470     inherit fetchurl stdenv autoconf automake ;
1471   };
1473   tcpdump = import ../tools/networking/tcpdump {
1474     inherit fetchurl stdenv libpcap;
1475   };
1477   tcng = import ../tools/networking/tcng {
1478     inherit fetchurl stdenv iproute bison flex db4 perl;
1479     kernel = kernel_2_6_28;
1480   };
1482   telnet = import ../tools/networking/telnet {
1483     inherit fetchurl stdenv ncurses;
1484   };
1486   ttf2pt1 = import ../tools/misc/ttf2pt1 {
1487     inherit fetchurl stdenv perl freetype;
1488   };
1490   ucl = import ../development/libraries/ucl {
1491     inherit fetchurl stdenv;
1492   };
1494   ufraw = import ../applications/graphics/ufraw {
1495     inherit fetchurl stdenv pkgconfig gettext bzip2 zlib
1496       libjpeg libtiff cfitsio exiv2 lcms gtkimageview;
1497     inherit (gnome) gtk;
1498   };
1500   upx = import ../tools/compression/upx {
1501     inherit fetchurl stdenv ucl zlib;
1502   };
1504   vbetool = builderDefsPackage ../tools/system/vbetool {
1505     inherit pciutils libx86 zlib;
1506   };
1508   viking = import ../applications/misc/viking {
1509     inherit fetchurl stdenv pkgconfig intltool gettext expat curl
1510       gpsd bc file;
1511     inherit (gtkLibs) gtk;
1512   };
1514   vncrec = builderDefsPackage ../tools/video/vncrec {
1515     inherit (xlibs) imake libX11 xproto gccmakedep libXt
1516       libXmu libXaw libXext xextproto libSM libICE libXpm
1517       libXp;
1518   };
1520   vpnc = import ../tools/networking/vpnc {
1521     inherit fetchurl stdenv libgcrypt perl gawk
1522       nettools makeWrapper;
1523   };
1525   vtun = import ../tools/networking/vtun {
1526     inherit fetchurl stdenv lzo openssl zlib yacc flex;
1527   };
1529   testdisk = import ../tools/misc/testdisk {
1530     inherit fetchurl stdenv ncurses libjpeg e2fsprogs zlib openssl;
1531   };
1533   htmlTidy = import ../tools/text/html-tidy {
1534     inherit fetchcvs stdenv autoconf automake libtool;
1535   };
1537   tightvnc = import ../tools/admin/tightvnc {
1538     inherit fetchurl stdenv x11 zlib libjpeg perl;
1539     inherit (xlibs) imake gccmakedep libXmu libXaw libXpm libXp xauth;
1540     fontDirectories = [ xorg.fontadobe75dpi xorg.fontmiscmisc xorg.fontcursormisc
1541       xorg.fontbhlucidatypewriter75dpi ];
1542   };
1544   time = import ../tools/misc/time {
1545     inherit fetchurl stdenv;
1546   };
1548   tm = import ../tools/system/tm {
1549     inherit fetchurl stdenv;
1550   };
1552   trang = import ../tools/text/xml/trang {
1553     inherit fetchurl stdenv unzip jre;
1554   };
1556   ts = import ../tools/system/ts {
1557     inherit fetchurl stdenv;
1558   };
1560   transfig = import ../tools/graphics/transfig {
1561     inherit fetchurl stdenv libpng libjpeg zlib;
1562     inherit (xlibs) imake;
1563   };
1565   truecrypt = import ../applications/misc/truecrypt {
1566     inherit fetchurl stdenv pkgconfig fuse devicemapper;
1567     inherit wxGTK;
1568     wxGUI = getConfig [ "truecrypt" "wxGUI" ] true;
1569   };
1571   ttmkfdir = import ../tools/misc/ttmkfdir {
1572     inherit stdenv fetchurl freetype fontconfig libunwind libtool bison;
1573     flex = flex2534;
1574   };
1576   units = import ../tools/misc/units {
1577     inherit fetchurl stdenv;
1578   };
1580   unrar = import ../tools/archivers/unrar {
1581     inherit fetchurl stdenv;
1582   };
1584   unshield = import ../tools/archivers/unshield {
1585     inherit fetchurl stdenv zlib;
1586   };
1588   unzip = unzip552;
1590   # TODO: remove in the next stdenv update.
1591   unzip552 = import ../tools/archivers/unzip/5.52.nix {
1592     inherit fetchurl stdenv;
1593   };
1595   unzip60 = import ../tools/archivers/unzip/6.0.nix {
1596     inherit fetchurl stdenv bzip2;
1597   };
1599   uptimed = import ../tools/system/uptimed {
1600     inherit fetchurl stdenv automake autoconf libtool;
1601   };
1603   wdfs = import ../tools/filesystems/wdfs {
1604     inherit stdenv fetchurl neon fuse pkgconfig glib;
1605   };
1607   webdruid = builderDefsPackage ../tools/admin/webdruid {
1608     inherit zlib libpng freetype gd which
1609       libxml2 geoip;
1610   };
1612   wget = import ../tools/networking/wget {
1613     inherit fetchurl stdenv gettext openssl;
1614   };
1616   which = import ../tools/system/which {
1617     inherit fetchurl stdenv readline;
1618   };
1620   wv = import ../tools/misc/wv {
1621     inherit fetchurl stdenv libpng zlib imagemagick
1622       pkgconfig libgsf libxml2 bzip2 glib;
1623   };
1625   wv2 = import ../tools/misc/wv2 {
1626     inherit stdenv fetchurl pkgconfig libgsf libxml2 glib;
1627   };
1629   x11_ssh_askpass = import ../tools/networking/x11-ssh-askpass {
1630     inherit fetchurl stdenv x11;
1631     inherit (xorg) imake;
1632   };
1634   xclip = import ../tools/misc/xclip {
1635     inherit fetchurl stdenv x11;
1636     inherit (xlibs) libXmu;
1637   };
1639   xfsprogs = import ../tools/filesystems/xfsprogs {
1640     inherit fetchurl stdenv libtool gettext libuuid;
1641   };
1643   xmlroff = import ../tools/typesetting/xmlroff {
1644     inherit fetchurl stdenv pkgconfig libxml2 libxslt popt;
1645     inherit (gtkLibs) glib pango gtk;
1646     inherit (gnome) libgnomeprint;
1647     inherit pangoxsl;
1648   };
1650   xmlto = import ../tools/typesetting/xmlto {
1651     inherit fetchurl stdenv flex libxml2 libxslt
1652             docbook_xml_dtd_42 docbook_xsl w3m
1653             bash getopt mktemp findutils makeWrapper;
1654   };
1656   xmltv = import ../tools/misc/xmltv {
1657     inherit fetchurl perl perlPackages;
1658   };
1660   xmpppy = builderDefsPackage (import ../development/python-modules/xmpppy) {
1661     inherit python setuptools;
1662   };
1664   xpf = import ../tools/text/xml/xpf {
1665     inherit fetchurl stdenv python;
1666     libxml2 = libxml2Python;
1667   };
1669   xsel = import ../tools/misc/xsel {
1670     inherit fetchurl stdenv x11;
1671   };
1673   zdelta = import ../tools/compression/zdelta {
1674     inherit fetchurl stdenv;
1675   };
1677   zile = import ../applications/editors/zile {
1678     inherit fetchurl stdenv ncurses help2man;
1679   };
1681   zip = import ../tools/archivers/zip {
1682     inherit fetchurl stdenv;
1683   };
1686   ### SHELLS
1689   bash = lowPrio (useFromStdenv "bash" bashReal);
1691   bashReal = makeOverridable (import ../shells/bash) {
1692     inherit fetchurl stdenv bison;
1693   };
1695   bashInteractive = appendToName "interactive" (bashReal.override {
1696     inherit readline texinfo;
1697     interactive = true;
1698   });
1700   tcsh = import ../shells/tcsh {
1701     inherit fetchurl stdenv ncurses;
1702   };
1704   zsh = import ../shells/zsh {
1705     inherit fetchurl stdenv ncurses coreutils;
1706   };
1709   ### DEVELOPMENT / COMPILERS
1712   abc =
1713     abcPatchable [];
1715   abcPatchable = patches :
1716     import ../development/compilers/abc/default.nix {
1717       inherit stdenv fetchurl patches jre apacheAnt;
1718       javaCup = import ../development/libraries/java/cup {
1719         inherit stdenv fetchurl jdk;
1720       };
1721     };
1723   aspectj =
1724     import ../development/compilers/aspectj {
1725       inherit stdenv fetchurl jre;
1726     };
1728   bigloo = import ../development/compilers/bigloo {
1729     inherit fetchurl stdenv;
1730   };
1732   dylan = import ../development/compilers/gwydion-dylan {
1733     inherit fetchurl stdenv perl boehmgc yacc flex readline;
1734     dylan =
1735       import ../development/compilers/gwydion-dylan/binary.nix {
1736         inherit fetchurl stdenv;
1737       };
1738   };
1740   adobeFlexSDK33 = import ../development/compilers/adobe-flex-sdk {
1741     inherit fetchurl stdenv unzip jre;
1742   };
1744   fpc = import ../development/compilers/fpc {
1745     inherit fetchurl stdenv gawk system;
1746   };
1748   gcc = gcc43;
1750   gcc295 = wrapGCC (import ../development/compilers/gcc-2.95 {
1751     inherit fetchurl stdenv noSysDirs;
1752   });
1754   gcc33 = wrapGCC (import ../development/compilers/gcc-3.3 {
1755     inherit fetchurl stdenv noSysDirs;
1756   });
1758   gcc34 = wrapGCC (import ../development/compilers/gcc-3.4 {
1759     inherit fetchurl stdenv noSysDirs;
1760   });
1762   # XXX: GCC 4.2 (and possibly others) misdetects `makeinfo' when
1763   # using Texinfo >= 4.10, just because it uses a stupid regexp that
1764   # expects a single digit after the dot.  As a workaround, we feed
1765   # GCC with Texinfo 4.9.  Stupid bug, hackish workaround.
1767   gcc40 = wrapGCC (makeOverridable (import ../development/compilers/gcc-4.0) {
1768     inherit fetchurl stdenv noSysDirs;
1769     texinfo = texinfo49;
1770     profiledCompiler = true;
1771   });
1773   gcc41 = wrapGCC (makeOverridable (import ../development/compilers/gcc-4.1) {
1774     inherit fetchurl stdenv noSysDirs;
1775     texinfo = texinfo49;
1776     profiledCompiler = false;
1777   });
1779   gcc42 = wrapGCC (makeOverridable (import ../development/compilers/gcc-4.2) {
1780     inherit fetchurl stdenv noSysDirs;
1781     profiledCompiler = false;
1782   });
1784   gcc43 = useFromStdenv "gcc" gcc43_real;
1786   gcc43_real = lowPrio (wrapGCC (makeOverridable (import ../development/compilers/gcc-4.3) {
1787     inherit fetchurl stdenv texinfo gmp mpfr noSysDirs;
1788     profiledCompiler = true;
1789   }));
1791   gcc43_multi = lowPrio (wrapGCCWith (import ../build-support/gcc-wrapper) glibc_multi (gcc43_real.gcc.override {
1792     stdenv = overrideGCC stdenv (wrapGCCWith (import ../build-support/gcc-wrapper) glibc_multi gcc);
1793     profiledCompiler = false;
1794     enableMultilib = true;
1795   }));
1797   gcc44 = lowPrio (wrapGCC (makeOverridable (import ../development/compilers/gcc-4.4) {
1798     inherit fetchurl stdenv texinfo gmp mpfr ppl cloogppl
1799       gettext which noSysDirs;
1800     profiledCompiler = true;
1801   }));
1803   gccApple =
1804     wrapGCC ( (if stdenv.system == "i686-darwin" then import ../development/compilers/gcc-apple else import ../development/compilers/gcc-apple64) {
1805       inherit fetchurl stdenv noSysDirs;
1806       profiledCompiler = true;
1807     }) ;
1809   gccupc40 = wrapGCCUPC (import ../development/compilers/gcc-upc-4.0 {
1810     inherit fetchurl stdenv bison autoconf gnum4 noSysDirs;
1811     texinfo = texinfo49;
1812   });
1814   gfortran = gfortran43;
1816   gfortran40 = wrapGCC (gcc40.gcc.override {
1817     name = "gfortran";
1818     langFortran = true;
1819     langCC = false;
1820     inherit gmp mpfr;
1821   });
1823   gfortran41 = wrapGCC (gcc41.gcc.override {
1824     name = "gfortran";
1825     langFortran = true;
1826     langCC = false;
1827     langC = false;
1828     inherit gmp mpfr;
1829   });
1831   gfortran42 = wrapGCC (gcc42.gcc.override {
1832     name = "gfortran";
1833     langFortran = true;
1834     langCC = false;
1835     langC = false;
1836     inherit gmp mpfr;
1837   });
1839   gfortran43 = wrapGCC (gcc43_real.gcc.override {
1840     name = "gfortran";
1841     langFortran = true;
1842     langCC = false;
1843     langC = false;
1844     profiledCompiler = false;
1845   });
1847   gfortran44 = wrapGCC (gcc44.gcc.override {
1848     name = "gfortran";
1849     langFortran = true;
1850     langCC = false;
1851     langC = false;
1852     profiledCompiler = false;
1853   });
1855   gcj = gcj44;
1857   gcj44 = wrapGCC (gcc44.gcc.override {
1858     name = "gcj";
1859     langJava = true;
1860     langFortran = false;
1861     langCC = true;
1862     langC = false;
1863     profiledCompiler = false;
1864     inherit zip unzip zlib boehmgc gettext pkgconfig;
1865     inherit (gtkLibs) gtk;
1866     inherit (gnome) libart_lgpl;
1867     inherit (xlibs) libX11 libXt libSM libICE libXtst libXi libXrender
1868       libXrandr xproto renderproto xextproto inputproto randrproto;
1869   });
1871   /*
1872   Broken; fails because of unability to find its own symbols during linking
1874   gcl = builderDefsPackage ../development/compilers/gcl {
1875     inherit mpfr m4 binutils fetchcvs emacs;
1876     inherit (xlibs) libX11 xproto inputproto libXi
1877       libXext xextproto libXt libXaw libXmu;
1878     stdenv = (overrideGCC stdenv gcc34) // {gcc = gcc33;};
1879   };
1880   */
1882   # GHC
1884   # GHC binaries are around for bootstrapping purposes
1886   #ghc = haskellPackages.ghc;
1888   ghc642Binary = lowPrio (import ../development/compilers/ghc/6.4.2-binary.nix {
1889     inherit fetchurl stdenv ncurses gmp;
1890     readline = if stdenv.system == "i686-linux" then readline4 else readline;
1891     perl = perl58;
1892   });
1894   ghc6101Binary = lowPrio (import ../development/compilers/ghc/6.10.1-binary.nix {
1895     inherit fetchurl stdenv perl ncurses gmp libedit;
1896   });
1898   ghc6102Binary = lowPrio (import ../development/compilers/ghc/6.10.2-binary.nix {
1899     inherit fetchurl stdenv perl ncurses gmp libedit;
1900   });
1902   # For several compiler versions, we export a large set of Haskell-related
1903   # packages.
1905   haskellPackages = haskellPackages_ghc6104;
1907   haskellPackages_ghc642 = import ./haskell-packages.nix {
1908     inherit pkgs;
1909     ghc = import ../development/compilers/ghc/6.4.2.nix {
1910       inherit fetchurl stdenv perl ncurses readline m4 gmp;
1911       ghc = ghc642Binary;
1912     };
1913   };
1915   haskellPackages_ghc661 = import ./haskell-packages.nix {
1916     inherit pkgs;
1917     ghc = import ../development/compilers/ghc/6.6.1.nix {
1918       inherit fetchurl stdenv readline perl58 gmp ncurses m4;
1919       ghc = ghc642Binary;
1920     };
1921   };
1923   haskellPackages_ghc682 = import ./haskell-packages.nix {
1924     inherit pkgs;
1925     ghc = import ../development/compilers/ghc/6.8.2.nix {
1926       inherit fetchurl stdenv readline perl gmp ncurses m4;
1927       ghc = ghc642Binary;
1928     };
1929   };
1931   haskellPackages_ghc683 = recurseIntoAttrs (import ./haskell-packages.nix {
1932     inherit pkgs;
1933     ghc = import ../development/compilers/ghc/6.8.3.nix {
1934       inherit fetchurl stdenv readline perl gmp ncurses m4;
1935       ghc = ghc642Binary;
1936       haddock = import ../development/tools/documentation/haddock/boot.nix {
1937         inherit gmp;
1938         cabal = import ../development/libraries/haskell/cabal/cabal.nix {
1939           inherit stdenv fetchurl lib;
1940           ghc = ghc642Binary;
1941         };
1942       };
1943     };
1944   });
1946   haskellPackages_ghc6101 = import ./haskell-packages.nix {
1947     inherit pkgs;
1948     ghc = import ../development/compilers/ghc/6.10.1.nix {
1949       inherit fetchurl stdenv perl ncurses gmp libedit;
1950       ghc = ghc6101Binary;
1951     };
1952   };
1954   haskellPackages_ghc6102 = import ./haskell-packages.nix {
1955     inherit pkgs;
1956     ghc = import ../development/compilers/ghc/6.10.2.nix {
1957       inherit fetchurl stdenv perl ncurses gmp libedit;
1958       ghc = ghc6101Binary;
1959     };
1960   };
1962   haskellPackages_ghc6103 = recurseIntoAttrs (import ./haskell-packages.nix {
1963     inherit pkgs;
1964     ghc = import ../development/compilers/ghc/6.10.3.nix {
1965       inherit fetchurl stdenv perl ncurses gmp libedit;
1966       ghc = ghc6101Binary;
1967     };
1968   });
1970   haskellPackages_ghc6104 = recurseIntoAttrs (import ./haskell-packages.nix {
1971     inherit pkgs;
1972     ghc = import ../development/compilers/ghc/6.10.4.nix {
1973       inherit fetchurl stdenv perl ncurses gmp libedit;
1974       ghc = ghc6101Binary;
1975     };
1976   });
1978   haskellPackages_ghc6121 = import ./haskell-packages.nix {
1979     inherit pkgs;
1980     ghc = import ../development/compilers/ghc/6.12.1.nix {
1981       inherit fetchurl stdenv perl ncurses gmp;
1982       ghc = ghc6101Binary;
1983     };
1984   };
1986   haskellPackages_ghcHEAD = import ./haskell-packages.nix {
1987     inherit pkgs;
1988     ghc = import ../development/compilers/ghc/6.11.nix {
1989       inherit fetchurl stdenv perl ncurses gmp libedit;
1990       inherit (haskellPackages) happy alex; # hope these aren't required for the final version
1991       ghc = ghc6101Binary;
1992     };
1993   };
1995   haxe = import ../development/compilers/haxe {
1996     inherit fetchurl stdenv lib ocaml zlib makeWrapper;
1997     inherit (bleedingEdgeRepos) sourceByName;
1998   };
2000   falcon = builderDefsPackage (import ../development/interpreters/falcon) {
2001     inherit cmake;
2002   };
2004   go = import ../development/compilers/go {
2005     inherit stdenv fetchhg glibc bison ed which bash makeWrapper;
2006   };
2008   gprolog = import ../development/compilers/gprolog {
2009     inherit fetchurl stdenv;
2010   };
2012   gwt = import ../development/compilers/gwt {
2013     inherit stdenv fetchurl jdk;
2014     inherit (gtkLibs) glib gtk pango atk;
2015     inherit (xlibs) libX11 libXt;
2016     libstdcpp5 = gcc33.gcc;
2017   };
2019   ikarus = import ../development/compilers/ikarus {
2020     inherit stdenv fetchurl gmp;
2021   };
2023   #TODO add packages http://cvs.haskell.org/Hugs/downloads/2006-09/packages/ and test
2024   # commented out because it's using the new configuration style proposal which is unstable
2025   hugs = import ../development/compilers/hugs {
2026     inherit lib fetchurl stdenv composableDerivation;
2027   };
2029   openjdkDarwin = import ../development/compilers/openjdk-darwin {
2030     inherit fetchurl stdenv;
2031   };
2033   j2sdk14x = (
2034     assert system == "i686-linux";
2035     import ../development/compilers/jdk/default-1.4.nix {
2036       inherit fetchurl stdenv;
2037     });
2039   jdk5 = (
2040     assert system == "i686-linux" || system == "x86_64-linux";
2041     import ../development/compilers/jdk/default-5.nix {
2042       inherit fetchurl stdenv unzip;
2043     });
2045   jdk       = jdkdistro true  false;
2046   jre       = jdkdistro false false;
2048   jdkPlugin = jdkdistro true true;
2049   jrePlugin = jdkdistro false true;
2051   supportsJDK =
2052     system == "i686-linux" ||
2053     system == "x86_64-linux" ||
2054     system == "powerpc-linux";
2056   jdkdistro = installjdk: pluginSupport:
2057        (assert supportsJDK;
2058     (if pluginSupport then appendToName "plugin" else x: x) (import ../development/compilers/jdk {
2059       inherit fetchurl stdenv unzip installjdk xlibs pluginSupport makeWrapper;
2060     }));
2062   jikes = import ../development/compilers/jikes {
2063     inherit fetchurl stdenv;
2064   };
2066   lazarus = builderDefsPackage (import ../development/compilers/fpc/lazarus.nix) {
2067     inherit fpc makeWrapper;
2068     inherit (gtkLibs) gtk glib pango atk;
2069     inherit (xlibs) libXi inputproto libX11 xproto libXext xextproto;
2070   };
2072   llvm = import ../development/compilers/llvm {
2073     inherit fetchurl stdenv gcc flex perl libtool;
2074   };
2076   llvmGCC = builderDefsPackage (import ../development/compilers/llvm/llvm-gcc.nix) {
2077     flex=flex2535;
2078     inherit llvm perl libtool bison;
2079   };
2081   mono = import ../development/compilers/mono {
2082     inherit fetchurl stdenv bison pkgconfig gettext perl glib;
2083   };
2085   monoDLLFixer = import ../build-support/mono-dll-fixer {
2086     inherit stdenv perl;
2087   };
2089   monotone = import ../applications/version-management/monotone {
2090     inherit stdenv fetchurl boost zlib botan libidn pcre
2091       sqlite lib perl;
2092     lua = lua5;
2093   };
2095   monotoneViz = builderDefsPackage (import ../applications/version-management/monotone-viz/mtn-head.nix) {
2096     inherit ocaml lablgtk graphviz pkgconfig autoconf automake libtool;
2097     inherit (gnome) gtk libgnomecanvas glib;
2098   };
2100   viewMtn = builderDefsPackage (import ../applications/version-management/viewmtn/0.10.nix)
2101   {
2102     inherit monotone flup cheetahTemplate highlight ctags
2103       makeWrapper graphviz which python;
2104   };
2106   neko = import ../development/compilers/neko {
2107     inherit (bleedingEdgeRepos) sourceByName ;
2108     inherit fetchurl stdenv lib pkgconfig composableDerivation boehmgc apacheHttpd
2109       mysql zlib sqlite pcre apr makeWrapper;
2110     inherit (gtkLibs) gtk;
2111   };
2113   nasm = import ../development/compilers/nasm {
2114     inherit fetchurl stdenv;
2115   };
2117   ocaml = ocaml_3_11_1;
2119   ocaml_3_08_0 = import ../development/compilers/ocaml/3.08.0.nix {
2120     inherit fetchurl stdenv x11 ncurses;
2121   };
2123   ocaml_3_09_1 = import ../development/compilers/ocaml/3.09.1.nix {
2124     inherit fetchurl stdenv x11 ncurses;
2125   };
2127   ocaml_3_10_0 = import ../development/compilers/ocaml/3.10.0.nix {
2128     inherit fetchurl stdenv x11 ncurses;
2129   };
2131   ocaml_3_11_1 = import ../development/compilers/ocaml/3.11.1.nix {
2132     inherit fetchurl stdenv x11 ncurses;
2133   };
2135   opencxx = import ../development/compilers/opencxx {
2136     inherit fetchurl stdenv libtool;
2137     gcc = gcc33;
2138   };
2140   qcmm = import ../development/compilers/qcmm {
2141     lua   = lua4;
2142     ocaml = ocaml_3_08_0;
2143     inherit fetchurl stdenv mk noweb groff;
2144   };
2146   roadsend = import ../development/compilers/roadsend {
2147     inherit fetchurl stdenv flex bison bigloo lib curl composableDerivation;
2148     # optional features
2149     # all features pcre, fcgi xml mysql, sqlite3, (not implemented: odbc gtk gtk2)
2150     flags = ["pcre" "xml" "mysql"];
2151     inherit mysql libxml2 fcgi;
2152   };
2154   sbcl = builderDefsPackage (import ../development/compilers/sbcl) {
2155     inherit makeWrapper;
2156     clisp = clisp_2_44_1;
2157   };
2159   scala = import ../development/compilers/scala {
2160     inherit stdenv fetchurl;
2161   };
2163   stalin = import ../development/compilers/stalin {
2164     inherit stdenv fetchurl;
2165     inherit (xlibs) libX11;
2166   };
2168   strategoPackages = strategoPackages017;
2170   strategoPackages016 = import ../development/compilers/strategoxt/0.16.nix {
2171     inherit fetchurl pkgconfig aterm getopt;
2172     stdenv = overrideInStdenv stdenv [gnumake380];
2173   };
2175   strategoPackages017 = import ../development/compilers/strategoxt/0.17.nix {
2176     inherit fetchurl stdenv pkgconfig aterm getopt jdk ncurses;
2177     readline = readline5;
2178   };
2180   strategoPackages018 = import ../development/compilers/strategoxt/0.18.nix {
2181     inherit fetchurl stdenv pkgconfig aterm getopt jdk makeStaticBinaries ncurses;
2182     readline = readline5;
2183   };
2185   metaBuildEnv = import ../development/compilers/meta-environment/meta-build-env {
2186     inherit fetchurl stdenv;
2187   };
2189   swiProlog = import ../development/compilers/swi-prolog {
2190     inherit fetchurl stdenv gmp readline openssl libjpeg unixODBC zlib;
2191     inherit (xlibs) libXinerama libXft libXpm libSM libXt;
2192   };
2194   tinycc = import ../development/compilers/tinycc {
2195     inherit fetchurl stdenv perl texinfo;
2196   };
2198   visualcpp = (import ../development/compilers/visual-c++ {
2199     inherit fetchurl stdenv cabextract;
2200   });
2202   webdsl = import ../development/compilers/webdsl {
2203     inherit stdenv fetchurl pkgconfig strategoPackages;
2204   };
2206   win32hello = import ../development/compilers/visual-c++/test {
2207     inherit fetchurl stdenv visualcpp windowssdk;
2208   };
2210   wrapGCCWith = gccWrapper: glibc: baseGCC: gccWrapper {
2211     nativeTools = stdenv ? gcc && stdenv.gcc.nativeTools;
2212     nativeLibc = stdenv ? gcc && stdenv.gcc.nativeLibc;
2213     nativePrefix = if stdenv ? gcc then stdenv.gcc.nativePrefix else "";
2214     gcc = baseGCC;
2215     libc = glibc;
2216     inherit stdenv binutils;
2217   };
2219   wrapGCC = wrapGCCWith (import ../build-support/gcc-wrapper) glibc;
2221   # FIXME: This is a specific hack for GCC-UPC.  Eventually, we may
2222   # want to merge `gcc-upc-wrapper' and `gcc-wrapper'.
2223   wrapGCCUPC = baseGCC: import ../build-support/gcc-upc-wrapper {
2224     nativeTools = stdenv ? gcc && stdenv.gcc.nativeTools;
2225     nativeLibc = stdenv ? gcc && stdenv.gcc.nativeLibc;
2226     gcc = baseGCC;
2227     libc = glibc;
2228     inherit stdenv binutils;
2229   };
2231   # prolog
2232   yap = import ../development/compilers/yap {
2233     inherit fetchurl stdenv;
2234   };
2237   ### DEVELOPMENT / INTERPRETERS
2239   acl2 = builderDefsPackage ../development/interpreters/acl2 {
2240     inherit sbcl;
2241   };
2243   clisp = import ../development/interpreters/clisp {
2244     inherit fetchurl stdenv libsigsegv gettext
2245       readline ncurses coreutils pcre zlib libffi libffcall;
2246     inherit (xlibs) libX11 libXau libXt xproto
2247       libXpm libXext xextproto;
2248   };
2250   # compatibility issues in 2.47 - at list 2.44.1 is known good
2251   # for sbcl bootstrap
2252   clisp_2_44_1 = import ../development/interpreters/clisp/2.44.1.nix {
2253     inherit fetchurl stdenv gettext
2254       readline ncurses coreutils pcre zlib libffi libffcall;
2255     inherit (xlibs) libX11 libXau libXt xproto
2256       libXpm libXext xextproto;
2257     libsigsegv = libsigsegv_25;
2258   };
2260   erlang = import ../development/interpreters/erlang {
2261     inherit fetchurl stdenv perl gnum4 ncurses openssl;
2262   };
2264   guile = import ../development/interpreters/guile {
2265     inherit fetchurl stdenv readline libtool gmp gawk makeWrapper;
2266   };
2268   guile_1_9 = import ../development/interpreters/guile/1.9.nix {
2269     inherit fetchurl stdenv readline libtool gmp gawk makeWrapper
2270       libunistring pkgconfig boehmgc;
2271   };
2273   guile_1_9_coverage = import ../development/interpreters/guile/1.9.nix {
2274     inherit fetchurl stdenv readline libtool gmp gawk makeWrapper
2275       libunistring pkgconfig boehmgc;
2276     inherit (releaseTools) coverageAnalysis;
2277   };
2279   io = builderDefsPackage (import ../development/interpreters/io) {
2280     inherit sqlite zlib gmp libffi cairo ncurses freetype mesa
2281       libpng libtiff libjpeg readline libsndfile libxml2
2282       freeglut e2fsprogs libsamplerate pcre libevent libedit;
2283   };
2285   kaffe =  import ../development/interpreters/kaffe {
2286     inherit fetchurl stdenv jikes alsaLib xlibs;
2287   };
2289   lua4 = import ../development/interpreters/lua-4 {
2290     inherit fetchurl stdenv;
2291   };
2293   lua5 = import ../development/interpreters/lua-5 {
2294     inherit fetchurl stdenv ncurses readline;
2295   };
2297   maude = import ../development/interpreters/maude {
2298     inherit fetchurl stdenv flex bison ncurses buddy tecla gmpxx libsigsegv makeWrapper;
2299   };
2301   octave = import ../development/interpreters/octave {
2302     inherit stdenv fetchurl gfortran readline ncurses perl flex qhull texinfo;
2303   };
2305   # mercurial (hg) bleeding edge version
2306   octaveHG = import ../development/interpreters/octave/hg.nix {
2307     inherit fetchurl readline ncurses perl flex atlas getConfig glibc qhull gfortran;
2308     inherit automake autoconf bison gperf lib python gnuplot texinfo texLive; # for dev Version
2309     inherit stdenv;
2310     inherit (xlibs) libX11;
2311     #stdenv = overrideGCC stdenv gcc40;
2312     inherit (bleedingEdgeRepos) sourceByName;
2313   };
2315   perl58 = import ../development/interpreters/perl-5.8 {
2316       inherit fetchurl stdenv;
2317       impureLibcPath = if stdenv.isLinux then null else "/usr";
2318     };
2320   perl510 = import ../development/interpreters/perl-5.10 {
2321     inherit stdenv;
2322     fetchurl = fetchurlBoot;
2323     impureLibcPath = if stdenv.isLinux then null else "/usr";
2324   };
2326   perl = if system != "i686-cygwin" then perl510 else sysPerl;
2328   # FIXME: unixODBC needs patching on Darwin (see darwinports)
2329   phpOld = import ../development/interpreters/php {
2330     inherit stdenv fetchurl flex bison libxml2 apacheHttpd;
2331     unixODBC =
2332       if stdenv.isDarwin then null else unixODBC;
2333   };
2335   php = import ../development/interpreters/php_configurable {
2336     inherit
2337       stdenv fetchurl lib composableDerivation autoconf automake
2338       flex bison apacheHttpd mysql libxml2 # gettext
2339       zlib curl gd postgresql openssl pkgconfig sqlite getConfig;
2340   };
2342   pltScheme = builderDefsPackage (import ../development/interpreters/plt-scheme) {
2343     inherit cairo fontconfig freetype libjpeg libpng openssl
2344       perl mesa zlib which;
2345     inherit (xorg) libX11 libXaw libXft libXrender libICE xproto
2346       renderproto pixman libSM libxcb libXext xextproto libXmu
2347       libXt;
2348   };
2350   polyml = import ../development/compilers/polyml {
2351     inherit stdenv fetchurl;
2352   };
2354   python = if getConfig ["python" "full"] false then pythonFull else pythonBase;
2355   python25 = if getConfig ["python" "full"] false then python25Full else python25Base;
2356   pythonBase = python25Base;
2357   pythonFull = python25Full;
2359   python24 = import ../development/interpreters/python/2.4 {
2360     inherit fetchurl stdenv zlib bzip2;
2361   };
2363   python25Base = composedArgsAndFun (import ../development/interpreters/python/2.5) {
2364     inherit fetchurl stdenv zlib bzip2 gdbm;
2365   };
2367   python25Full = python25Base.passthru.function {
2368     # FIXME: We lack ncurses support, needed, e.g., for `gpsd'.
2369     db4 = if getConfig ["python" "db4Support"] true then db4 else null;
2370     sqlite = if getConfig ["python" "sqliteSupport"] true then sqlite else null;
2371     readline = if getConfig ["python" "readlineSupport"] true then readline else null;
2372     openssl = if getConfig ["python" "opensslSupport"] true then openssl else null;
2373     tk = if getConfig ["python" "tkSupport"] true then tk else null;
2374     tcl = if getConfig ["python" "tkSupport"] true then tcl else null;
2375     libX11 = if getConfig ["python" "tkSupport"] true then xlibs.libX11 else null;
2376     xproto = if getConfig ["python" "tkSupport"] true then xlibs.xproto else null;
2377   };
2379   python26Base = composedArgsAndFun (import ../development/interpreters/python/2.6) {
2380     inherit fetchurl stdenv zlib bzip2 gdbm;
2381     arch = if stdenv.isDarwin then darwinArchUtility else null;
2382     sw_vers = if stdenv.isDarwin then darwinSwVersUtility else null;
2383   };
2385   python26Full = python26Base.passthru.function {
2386     # FIXME: We lack ncurses support, needed, e.g., for `gpsd'.
2387     db4 = if getConfig ["python" "db4Support"] true then db4 else null;
2388     sqlite = if getConfig ["python" "sqliteSupport"] true then sqlite else null;
2389     readline = if getConfig ["python" "readlineSupport"] true then readline else null;
2390     openssl = if getConfig ["python" "opensslSupport"] true then openssl else null;
2391     tk = if getConfig ["python" "tkSupport"] true then tk else null;
2392     tcl = if getConfig ["python" "tkSupport"] true then tcl else null;
2393     libX11 = if getConfig ["python" "tkSupport"] true then xlibs.libX11 else null;
2394     xproto = if getConfig ["python" "tkSupport"] true then xlibs.xproto else null;
2395   };
2397   # new python and lib proposal
2398   # - adding a python lib to buildinputs should be enough
2399   #   (handles .pth files by patching site.py
2400   #    while introducing NIX_PYTHON_SITES describing list of modules)
2401   # - adding pyCheck = "import foo" test scripts to ensure libraries can be imported
2402   # - providing pythonWrapper so that you can run python and import the selected libraries
2403   # feel free to comment on this (experimental)
2404   python25New = recurseIntoAttrs ((import ../development/interpreters/python-new/2.5) pkgs);
2405   pythonNew = python25New; # the default python
2407   pyrex = pyrex095;
2409   pyrex095 = import ../development/interpreters/pyrex/0.9.5.nix {
2410     inherit fetchurl stdenv stringsWithDeps lib builderDefs python;
2411   };
2413   pyrex096 = import ../development/interpreters/pyrex/0.9.6.nix {
2414     inherit fetchurl stdenv stringsWithDeps lib builderDefs python;
2415   };
2417   Qi = composedArgsAndFun (import ../development/compilers/qi/9.1.nix) {
2418     inherit clisp stdenv fetchurl builderDefs unzip;
2419   };
2421   ruby18 = import ../development/interpreters/ruby {
2422     inherit fetchurl stdenv readline ncurses zlib openssl gdbm;
2423   };
2424   #ruby19 = import ../development/interpreters/ruby/ruby-19.nix { inherit ruby18 fetchurl; };
2425   ruby = ruby18;
2427   rubyLibs = recurseIntoAttrs (import ../development/interpreters/ruby/libs.nix {
2428     inherit pkgs stdenv;
2429   });
2431   rake = import ../development/ruby-modules/rake {
2432     inherit fetchurl stdenv ruby ;
2433   };
2435   rubySqlite3 = import ../development/ruby-modules/sqlite3 {
2436     inherit fetchurl stdenv ruby sqlite;
2437   };
2439   rLang = import ../development/interpreters/r-lang {
2440     inherit fetchurl stdenv readline perl gfortran libpng zlib;
2441     inherit (xorg) libX11 libXt;
2442     withBioconductor = getConfig ["rLang" "withBioconductor"] false;
2443   };
2445   rubygemsFun = ruby: builderDefsPackage (import ../development/interpreters/ruby/gems.nix) {
2446     inherit ruby makeWrapper;
2447   };
2448   rubygems = rubygemsFun ruby;
2450   rq = import ../applications/networking/cluster/rq {
2451     inherit fetchurl stdenv sqlite ruby ;
2452   };
2454   scsh = import ../development/interpreters/scsh {
2455     inherit stdenv fetchurl;
2456   };
2458   spidermonkey = import ../development/interpreters/spidermonkey {
2459     inherit fetchurl stdenv readline;
2460   };
2462   sysPerl = import ../development/interpreters/sys-perl {
2463     inherit stdenv;
2464   };
2466   tcl = import ../development/interpreters/tcl {
2467     inherit fetchurl stdenv;
2468   };
2470   xulrunnerWrapper = {application, launcher}:
2471     import ../development/interpreters/xulrunner/wrapper {
2472       inherit stdenv application launcher;
2473       xulrunner = xulrunner35;
2474     };
2477   ### DEVELOPMENT / MISC
2479   avrgcclibc = import ../development/misc/avr-gcc-with-avr-libc {
2480     inherit fetchurl stdenv writeTextFile gnumake coreutils gnutar bzip2
2481       gnugrep gnused gawk;
2482     gcc = gcc40;
2483   };
2485   avr8burnomat = import ../development/misc/avr8-burn-omat {
2486     inherit fetchurl stdenv unzip;
2487   };
2489   /*
2490   toolbus = import ../development/interpreters/toolbus {
2491     inherit stdenv fetchurl atermjava toolbuslib aterm yacc flex;
2492   };
2493   */
2495   bleedingEdgeRepos = import ../development/misc/bleeding-edge-repos {
2496     inherit getConfig fetchurl lib;
2497   };
2499   ecj = import ../development/eclipse/ecj {
2500     inherit fetchurl stdenv unzip ant gcj;
2501   };
2503   jdtsdk = import ../development/eclipse/jdt-sdk {
2504     inherit fetchurl stdenv unzip;
2505   };
2507   jruby116 = import ../development/interpreters/jruby {
2508     inherit fetchurl stdenv;
2509   };
2511   guileCairo = import ../development/guile-modules/guile-cairo {
2512     inherit fetchurl stdenv guile pkgconfig cairo guileLib;
2513   };
2515   guileGnome = import ../development/guile-modules/guile-gnome {
2516     inherit fetchurl stdenv guile guileLib gwrap pkgconfig guileCairo;
2517     gconf = gnome.GConf;
2518     inherit (gnome) glib gnomevfs gtk libglade libgnome libgnomecanvas
2519       libgnomeui pango;
2520   };
2522   guileLib = import ../development/guile-modules/guile-lib {
2523     inherit fetchurl stdenv guile texinfo;
2524   };
2526   windowssdk = (
2527     import ../development/misc/windows-sdk {
2528       inherit fetchurl stdenv cabextract;
2529     });
2532   ### DEVELOPMENT / TOOLS
2535   antlr = import ../development/tools/parsing/antlr/2.7.7.nix {
2536     inherit fetchurl stdenv jdk python;
2537   };
2539   antlr3 = import ../development/tools/parsing/antlr {
2540     inherit fetchurl stdenv jre;
2541   };
2543   antDarwin = apacheAnt.override rec { jdk = openjdkDarwin ; name = "ant-" + jdk.name ; } ;
2545   ant = apacheAnt;
2546   apacheAnt = makeOverridable (import ../development/tools/build-managers/apache-ant) {
2547     inherit fetchurl stdenv jdk;
2548     name = "ant-" + jdk.name;
2549   };
2551   apacheAnt14 = import ../development/tools/build-managers/apache-ant {
2552     inherit fetchurl stdenv;
2553     jdk = j2sdk14x;
2554     name = "ant-" + j2sdk14x.name;
2555   };
2557   apacheAntGcj = import ../development/tools/build-managers/apache-ant/from-source.nix {
2558     inherit fetchurl stdenv;
2559     inherit junit; # must be either pre-built or built with GCJ *alone*
2560     javac = gcj;
2561     jvm = gcj;
2562   };
2564   autobuild = import ../development/tools/misc/autobuild {
2565     inherit fetchurl stdenv makeWrapper perl openssh rsync;
2566   };
2568   autoconf = import ../development/tools/misc/autoconf {
2569     inherit fetchurl stdenv perl m4;
2570   };
2572   autoconf213 = import ../development/tools/misc/autoconf/2.13.nix {
2573     inherit fetchurl stdenv perl m4 lzma;
2574   };
2576   automake = automake110x;
2578   automake17x = import ../development/tools/misc/automake/automake-1.7.x.nix {
2579     inherit fetchurl stdenv perl autoconf makeWrapper;
2580   };
2582   automake19x = import ../development/tools/misc/automake/automake-1.9.x.nix {
2583     inherit fetchurl stdenv perl autoconf makeWrapper;
2584   };
2586   automake110x = import ../development/tools/misc/automake/automake-1.10.x.nix {
2587     inherit fetchurl stdenv perl autoconf makeWrapper;
2588   };
2590   automake111x = import ../development/tools/misc/automake/automake-1.11.x.nix {
2591     inherit fetchurl stdenv perl autoconf makeWrapper;
2592   };
2594   avrdude = import ../development/tools/misc/avrdude {
2595     inherit lib fetchurl stdenv flex yacc composableDerivation texLive;
2596   };
2598   binutils = useFromStdenv "binutils"
2599     (import ../development/tools/misc/binutils {
2600       inherit fetchurl stdenv noSysDirs;
2601     });
2603   bison = bison23;
2605   bison1875 = import ../development/tools/parsing/bison/bison-1.875.nix {
2606     inherit fetchurl stdenv m4;
2607   };
2609   bison23 = import ../development/tools/parsing/bison/bison-2.3.nix {
2610     inherit fetchurl stdenv m4;
2611   };
2613   bison24 = import ../development/tools/parsing/bison/bison-2.4.nix {
2614     inherit fetchurl stdenv m4;
2615   };
2617   buildbot = import ../development/tools/build-managers/buildbot {
2618     inherit fetchurl stdenv python twisted makeWrapper;
2619   };
2621   byacc = import ../development/tools/parsing/byacc {
2622     inherit fetchurl stdenv;
2623   };
2625   camlp5_strict = import ../development/tools/ocaml/camlp5 {
2626     inherit stdenv fetchurl ocaml;
2627   };
2629   camlp5_transitional = import ../development/tools/ocaml/camlp5 {
2630     inherit stdenv fetchurl ocaml;
2631     transitional = true;
2632   };
2634   ccache = import ../development/tools/misc/ccache {
2635     inherit fetchurl stdenv;
2636   };
2638   ctags = import ../development/tools/misc/ctags {
2639     inherit fetchurl stdenv bleedingEdgeRepos automake autoconf;
2640   };
2642   ctagsWrapped = import ../development/tools/misc/ctags/wrapped.nix {
2643     inherit pkgs ctags writeScriptBin;
2644   };
2646   cmake = import ../development/tools/build-managers/cmake {
2647     inherit fetchurl stdenv replace ncurses;
2648   };
2650   cproto = import ../development/tools/misc/cproto {
2651     inherit fetchurl stdenv flex bison;
2652   };
2654   cflow = import ../development/tools/misc/cflow {
2655     inherit fetchurl stdenv gettext emacs;
2656   };
2658   cscope = import ../development/tools/misc/cscope {
2659     inherit fetchurl stdenv ncurses pkgconfig emacs;
2660   };
2662   dejagnu = import ../development/tools/misc/dejagnu {
2663     inherit fetchurl stdenv expect makeWrapper;
2664   };
2666   ddd = import ../development/tools/misc/ddd {
2667     inherit fetchurl stdenv lesstif ncurses;
2668     inherit (xlibs) libX11 libXt;
2669   };
2671   distcc = import ../development/tools/misc/distcc {
2672     inherit fetchurl stdenv popt python;
2673     avahi = if getPkgConfig "distcc" "avahi" false then avahi else null;
2674     pkgconfig = if getPkgConfig "distcc" "gtk" false then pkgconfig else null;
2675     gtk = if getPkgConfig "distcc" "gtk" false then gtkLibs.gtk else null;
2676   };
2678   docutils = builderDefsPackage (import ../development/tools/documentation/docutils) {
2679     inherit python pil makeWrapper;
2680   };
2682   doxygen = import ../development/tools/documentation/doxygen {
2683     inherit fetchurl stdenv graphviz perl flex bison gnumake;
2684     inherit (xlibs) libX11 libXext;
2685     qt = if getPkgConfig "doxygen" "qt4" true then qt4 else null;
2686   };
2688   eggdbus = import ../development/tools/misc/eggdbus {
2689     inherit stdenv fetchurl pkgconfig dbus dbus_glib glib;
2690   };
2692   elfutils = import ../development/tools/misc/elfutils {
2693     inherit fetchurl stdenv m4;
2694   };
2696   epm = import ../development/tools/misc/epm {
2697     inherit fetchurl stdenv rpm;
2698   };
2700   emma = import ../development/tools/analysis/emma {
2701     inherit fetchurl stdenv unzip;
2702   };
2704   findbugs = import ../development/tools/analysis/findbugs {
2705     inherit fetchurl stdenv;
2706   };
2708   pmd = import ../development/tools/analysis/pmd {
2709     inherit fetchurl stdenv unzip;
2710   };
2712   jdepend = import ../development/tools/analysis/jdepend {
2713     inherit fetchurl stdenv unzip;
2714   };
2716   checkstyle = import ../development/tools/analysis/checkstyle {
2717     inherit fetchurl stdenv unzip;
2718   };
2720   flex = flex254a;
2722   flex2535 = import ../development/tools/parsing/flex/flex-2.5.35.nix {
2723     inherit fetchurl stdenv yacc m4;
2724   };
2726   flex2534 = import ../development/tools/parsing/flex/flex-2.5.34.nix {
2727     inherit fetchurl stdenv yacc m4;
2728   };
2730   flex2533 = import ../development/tools/parsing/flex/flex-2.5.33.nix {
2731     inherit fetchurl stdenv yacc m4;
2732   };
2734   # Note: 2.5.4a is much older than 2.5.35 but happens first when sorting
2735   # alphabetically, hence the low priority.
2736   flex254a = lowPrio (import ../development/tools/parsing/flex/flex-2.5.4a.nix {
2737     inherit fetchurl stdenv yacc;
2738   });
2740   m4 = gnum4;
2742   global = import ../development/tools/misc/global {
2743     inherit fetchurl stdenv;
2744   };
2746   gnum4 = import ../development/tools/misc/gnum4 {
2747     inherit fetchurl stdenv;
2748   };
2750   gnumake = useFromStdenv "gnumake"
2751     (import ../development/tools/build-managers/gnumake {
2752       inherit fetchurl stdenv;
2753     });
2755   gnumake380 = import ../development/tools/build-managers/gnumake-3.80 {
2756     inherit fetchurl stdenv;
2757   };
2759   gperf = import ../development/tools/misc/gperf {
2760     inherit fetchurl stdenv;
2761   };
2763   gtkdialog = import ../development/tools/misc/gtkdialog {
2764     inherit fetchurl stdenv pkgconfig;
2765     inherit (gtkLibs) gtk;
2766   };
2768   /*
2769   hsc2hs = import ../development/tools/misc/hsc2hs {
2770     inherit bleedingEdgeRepos stdenv;
2771     ghc = ghcsAndLibs.ghc68.ghc;
2772     libs = with (ghc68extraLibs ghcsAndLibs.ghc68 // ghcsAndLibs.ghc68.core_libs); [ base directory process cabal_darcs ];
2773   };
2774   */
2776   guileLint = import ../development/tools/guile/guile-lint {
2777     inherit fetchurl stdenv guile;
2778   };
2780   gwrap = import ../development/tools/guile/g-wrap {
2781     inherit fetchurl stdenv guile libffi pkgconfig guileLib glib;
2782   };
2784   help2man = import ../development/tools/misc/help2man {
2785     inherit fetchurl stdenv perl gettext;
2786     inherit (perlPackages) LocaleGettext;
2787   };
2789   iconnamingutils = import ../development/tools/misc/icon-naming-utils {
2790     inherit fetchurl stdenv perl;
2791     inherit (perlPackages) XMLSimple;
2792   };
2794   indent = import ../development/tools/misc/indent {
2795     inherit fetchurl stdenv;
2796   };
2798   jikespg = import ../development/tools/parsing/jikespg {
2799     inherit fetchurl stdenv;
2800   };
2802   kcachegrind = import ../development/tools/misc/kcachegrind {
2803     inherit fetchurl stdenv kdelibs zlib perl expat libpng libjpeg;
2804     inherit (xlibs) libX11 libXext libSM;
2805     qt = qt3;
2806   };
2808   lcov = import ../development/tools/analysis/lcov {
2809     inherit fetchurl stdenv perl;
2810   };
2812   libtool = libtool_2;
2814   libtool_1_5 = import ../development/tools/misc/libtool {
2815     inherit fetchurl stdenv perl m4;
2816   };
2818   libtool_2 = import ../development/tools/misc/libtool/libtool2.nix {
2819     inherit fetchurl stdenv lzma perl m4;
2820   };
2822   lsof = import ../development/tools/misc/lsof {
2823     inherit fetchurl stdenv;
2824   };
2826   ltrace = composedArgsAndFun (import ../development/tools/misc/ltrace/0.5-3deb.nix) {
2827     inherit fetchurl stdenv builderDefs stringsWithDeps lib elfutils;
2828   };
2830   mk = import ../development/tools/build-managers/mk {
2831     inherit fetchurl stdenv;
2832   };
2834   noweb = import ../development/tools/literate-programming/noweb {
2835     inherit fetchurl stdenv;
2836   };
2838   openafsClient = import ../servers/openafs-client {
2839     inherit stdenv fetchurl autoconf automake flex yacc;
2840     inherit kernel_2_6_28 glibc ncurses perl krb5;
2841   };
2843   openocd = import ../development/tools/misc/openocd {
2844     inherit fetchurl stdenv libftdi;
2845   };
2847   oprofile = import ../development/tools/profiling/oprofile {
2848     inherit fetchurl stdenv binutils popt;
2849     inherit makeWrapper gawk which gnugrep;
2850   };
2852   patchelf = useFromStdenv "patchelf"
2853     (import ../development/tools/misc/patchelf {
2854       inherit fetchurl stdenv;
2855     });
2857   patchelf05 = import ../development/tools/misc/patchelf/0.5.nix {
2858     inherit fetchurl stdenv;
2859   };
2861   pmccabe = import ../development/tools/misc/pmccabe {
2862     inherit fetchurl stdenv;
2863   };
2865   /**
2866    * pkgconfig is optionally taken from the stdenv to allow bootstrapping
2867    * of glib and pkgconfig itself on MinGW.
2868    */
2869   pkgconfig = useFromStdenv "pkgconfig"
2870     (import ../development/tools/misc/pkgconfig {
2871       inherit fetchurl stdenv;
2872     });
2874   radare = import ../development/tools/analysis/radare {
2875     inherit stdenv fetchurl pkgconfig libusb readline gtkdialog python
2876       ruby libewf perl;
2877     inherit (gtkLibs) gtk;
2878     inherit (gnome) vte;
2879     lua = lua5;
2880     useX11 = getConfig ["radare" "useX11"] false;
2881     pythonBindings = getConfig ["radare" "pythonBindings"] false;
2882     rubyBindings = getConfig ["radare" "rubyBindings"] false;
2883     luaBindings = getConfig ["radare" "luaBindings"] false;
2884   };
2886   ragel = import ../development/tools/parsing/ragel {
2887     inherit composableDerivation fetchurl transfig texLive;
2888   };
2890   remake = import ../development/tools/build-managers/remake {
2891       inherit fetchurl stdenv;
2892     };
2894   # couldn't find the source yet
2895   seleniumRCBin = import ../development/tools/selenium/remote-control {
2896     inherit fetchurl stdenv unzip;
2897     jre = jdk;
2898   };
2900   scons = import ../development/tools/build-managers/scons {
2901     inherit fetchurl stdenv python makeWrapper;
2902   };
2904   sloccount = import ../development/tools/misc/sloccount {
2905     inherit fetchurl stdenv perl;
2906   };
2908   sparse = import ../development/tools/analysis/sparse {
2909     inherit fetchurl stdenv pkgconfig;
2910   };
2912   spin = import ../development/tools/analysis/spin {
2913     inherit fetchurl stdenv flex yacc tk;
2914   };
2916   splint = import ../development/tools/analysis/splint {
2917     inherit fetchurl stdenv flex;
2918   };
2920   strace = import ../development/tools/misc/strace {
2921     inherit fetchurl stdenv;
2922   };
2924   swig = import ../development/tools/misc/swig {
2925     inherit fetchurl stdenv boost;
2926   };
2928   swigWithJava = swig;
2930   swftools = import ../tools/video/swftools {
2931     inherit fetchurl stdenv x264 zlib libjpeg freetype giflib;
2932   };
2934   texinfo49 = import ../development/tools/misc/texinfo/4.9.nix {
2935     inherit fetchurl stdenv ncurses;
2936   };
2938   texinfo = import ../development/tools/misc/texinfo {
2939     inherit fetchurl stdenv ncurses lzma;
2940   };
2942   texi2html = import ../development/tools/misc/texi2html {
2943     inherit fetchurl stdenv perl;
2944   };
2946   uisp = import ../development/tools/misc/uisp {
2947     inherit fetchurl stdenv;
2948   };
2950   gdb = import ../development/tools/misc/gdb {
2951     inherit fetchurl stdenv ncurses gmp mpfr expat texinfo;
2952     readline = readline5;
2953   };
2955   valgrind = import ../development/tools/analysis/valgrind {
2956     inherit fetchurl stdenv perl gdb;
2957   };
2959   xxdiff = builderDefsPackage (import ../development/tools/misc/xxdiff/3.2.nix) {
2960     flex = flex2535;
2961     qt = qt3;
2962     inherit pkgconfig makeWrapper bison python;
2963     inherit (xlibs) libXext libX11;
2964   };
2966   yacc = bison;
2968   yodl = import ../development/tools/misc/yodl {
2969     inherit stdenv fetchurl perl;
2970   };
2973   ### DEVELOPMENT / LIBRARIES
2976   a52dec = import ../development/libraries/a52dec {
2977     inherit fetchurl stdenv;
2978   };
2980   aalib = import ../development/libraries/aalib {
2981     inherit fetchurl stdenv ncurses;
2982   };
2984   acl = useFromStdenv "acl"
2985     (import ../development/libraries/acl {
2986       inherit stdenv fetchurl gettext attr libtool;
2987     });
2989   adns = import ../development/libraries/adns/1.4.nix {
2990     inherit stdenv fetchurl;
2991     static = getPkgConfig "adns" "static" (stdenv ? isStatic || stdenv ? isDietLibC);
2992   };
2994   agg = import ../development/libraries/agg {
2995     inherit fetchurl stdenv autoconf automake libtool pkgconfig
2996       freetype SDL;
2997     inherit (xlibs) libX11;
2998   };
3000   amrnb = import ../development/libraries/amrnb {
3001     inherit fetchurl stdenv unzip;
3002   };
3004   amrwb = import ../development/libraries/amrwb {
3005     inherit fetchurl stdenv unzip;
3006   };
3008   apr = makeOverridable (import ../development/libraries/apr) {
3009     inherit (pkgsOverriden) fetchurl stdenv;
3010   };
3012   aprutil = makeOverridable (import ../development/libraries/apr-util) {
3013     inherit (pkgsOverriden) fetchurl stdenv apr expat db4;
3014     bdbSupport = true;
3015   };
3017   arts = import ../development/libraries/arts {
3018     inherit fetchurl stdenv pkgconfig;
3019     inherit (xlibs) libX11 libXext;
3020     inherit kdelibs zlib libjpeg libpng perl;
3021     qt = qt3;
3022     inherit (gnome) glib;
3023   };
3025   aspell = import ../development/libraries/aspell {
3026     inherit fetchurl stdenv perl;
3027   };
3029   aspellDicts = recurseIntoAttrs (import ../development/libraries/aspell/dictionaries.nix {
3030     inherit fetchurl stdenv aspell which;
3031   });
3033   aterm = aterm25;
3035   aterm242fixes = lowPrio (import ../development/libraries/aterm/2.4.2-fixes.nix {
3036     inherit fetchurl stdenv;
3037   });
3039   aterm25 = makeOverridable (import ../development/libraries/aterm/2.5.nix) {
3040     inherit fetchurl stdenv;
3041   };
3043   aterm28 = lowPrio (import ../development/libraries/aterm/2.8.nix {
3044     inherit fetchurl stdenv;
3045   });
3047   attr = useFromStdenv "attr"
3048     (import ../development/libraries/attr {
3049       inherit stdenv fetchurl gettext libtool;
3050     });
3052   aubio = import ../development/libraries/aubio {
3053     inherit fetchurl stdenv pkgconfig fftw libsndfile libsamplerate python
3054       alsaLib jackaudio;
3055   };
3057   axis = import ../development/libraries/axis {
3058     inherit fetchurl stdenv;
3059   };
3061   babl = import ../development/libraries/babl {
3062     inherit fetchurl stdenv;
3063   };
3065   beecrypt = import ../development/libraries/beecrypt {
3066     inherit fetchurl stdenv m4;
3067   };
3069   boehmgc = import ../development/libraries/boehm-gc {
3070     inherit fetchurl stdenv;
3071   };
3073   boolstuff = import ../development/libraries/boolstuff {
3074     inherit fetchurl stdenv lib pkgconfig;
3075   };
3077   boost_1_36_0 = import ../development/libraries/boost/1.36.0.nix {
3078     inherit fetchurl stdenv icu expat zlib bzip2 python;
3079   };
3081   boost = makeOverridable (import ../development/libraries/boost/1.41.0.nix) {
3082     inherit fetchurl stdenv icu expat zlib bzip2 python;
3083   };
3085   # A Boost build with all library variants enabled.  Very large (about 250 MB).
3086   boostFull = appendToName "full" (boost.override {
3087     enableDebug = true;
3088     enableSingleThreaded = true;
3089     enableStatic = true;
3090   });
3092   botan = builderDefsPackage (import ../development/libraries/botan) {
3093     inherit perl;
3094   };
3096   buddy = import ../development/libraries/buddy {
3097     inherit fetchurl stdenv bison;
3098   };
3100   cairo = import ../development/libraries/cairo {
3101     inherit fetchurl stdenv pkgconfig x11 fontconfig freetype zlib libpng;
3102     inherit (xlibs) pixman libxcb xcbutil;
3103   };
3105   cairomm = import ../development/libraries/cairomm {
3106     inherit fetchurl stdenv pkgconfig cairo x11 fontconfig freetype libsigcxx;
3107   };
3109   ccrtp = import ../development/libraries/ccrtp {
3110     inherit fetchurl stdenv lib pkgconfig openssl libgcrypt commoncpp2;
3111   };
3113   chipmunk = builderDefsPackage (import ../development/libraries/chipmunk) {
3114     inherit cmake freeglut mesa;
3115     inherit (xlibs) libX11 xproto inputproto libXi libXmu;
3116   };
3118   chmlib = import ../development/libraries/chmlib {
3119     inherit fetchurl stdenv;
3120   };
3122   cil = import ../development/libraries/cil {
3123     inherit stdenv fetchurl ocaml perl;
3124   };
3126   cilaterm = import ../development/libraries/cil-aterm {
3127     stdenv = overrideInStdenv stdenv [gnumake380];
3128     inherit fetchurl perl ocaml;
3129   };
3131   clanlib = import ../development/libraries/clanlib {
3132     inherit fetchurl stdenv zlib libpng libjpeg libvorbis libogg mesa;
3133     inherit (xlibs) libX11 xf86vidmodeproto libXmu libXxf86vm;
3134   };
3136   classpath = import ../development/libraries/java/classpath {
3137     javac = gcj;
3138     jvm = gcj;
3139     inherit fetchurl stdenv pkgconfig antlr;
3140     inherit (gtkLibs) gtk;
3141     gconf = gnome.GConf;
3142   };
3144   clearsilver = import ../development/libraries/clearsilver {
3145     inherit fetchurl stdenv python;
3146   };
3148   clppcre = builderDefsPackage (import ../development/libraries/cl-ppcre) {
3149   };
3151   cluceneCore = (import ../development/libraries/clucene-core) {
3152     inherit fetchurl stdenv;
3153   };
3155   commoncpp2 = import ../development/libraries/commoncpp2 {
3156     inherit stdenv fetchurl lib;
3157   };
3159   consolekit = makeOverridable (import ../development/libraries/consolekit) {
3160     inherit stdenv fetchurl pkgconfig dbus_glib zlib pam policykit expat glib;
3161     inherit (xlibs) libX11;
3162   };
3164   coredumper = import ../development/libraries/coredumper {
3165     inherit fetchurl stdenv;
3166   };
3168   ctl = import ../development/libraries/ctl {
3169     inherit fetchurl stdenv ilmbase;
3170   };
3172   cppunit = import ../development/libraries/cppunit {
3173     inherit fetchurl stdenv;
3174   };
3176   cracklib = import ../development/libraries/cracklib {
3177     inherit fetchurl stdenv;
3178   };
3180   cryptopp = import ../development/libraries/crypto++ {
3181     inherit fetchurl stdenv unzip libtool;
3182   };
3184   cyrus_sasl = import ../development/libraries/cyrus-sasl {
3185     inherit fetchurl stdenv openssl db4 gettext;
3186   };
3188   db4 = db45;
3190   db44 = import ../development/libraries/db4/db4-4.4.nix {
3191     inherit fetchurl stdenv;
3192   };
3194   db45 = import ../development/libraries/db4/db4-4.5.nix {
3195     inherit fetchurl stdenv;
3196   };
3198   dbus = import ../development/libraries/dbus {
3199     inherit fetchurl stdenv pkgconfig expat;
3200     inherit (xlibs) libX11 libICE libSM;
3201     useX11 = true; # !!! `false' doesn't build
3202   };
3204   dbus_glib = makeOverridable (import ../development/libraries/dbus-glib) {
3205     inherit fetchurl stdenv pkgconfig gettext dbus expat glib;
3206   };
3208   dclib = import ../development/libraries/dclib {
3209     inherit fetchurl stdenv libxml2 openssl bzip2;
3210   };
3212   directfb = import ../development/libraries/directfb {
3213     inherit fetchurl stdenv perl zlib libjpeg freetype
3214       SDL libpng giflib;
3215     inherit (xlibs) libX11 libXext xproto xextproto renderproto
3216       libXrender;
3217   };
3219   enchant = makeOverridable (import ../development/libraries/enchant) {
3220     inherit fetchurl stdenv aspell pkgconfig;
3221     inherit (gnome) glib;
3222   };
3224   exiv2 = import ../development/libraries/exiv2 {
3225     inherit fetchurl stdenv zlib;
3226   };
3228   expat = import ../development/libraries/expat {
3229     inherit fetchurl stdenv;
3230   };
3232   extremetuxracer = builderDefsPackage (import ../games/extremetuxracer) {
3233     inherit mesa tcl freeglut SDL SDL_mixer pkgconfig
3234         libpng gettext intltool;
3235     inherit (xlibs) libX11 xproto libXi inputproto
3236         libXmu libXext xextproto libXt libSM libICE;
3237   };
3239   eventlog = import ../development/libraries/eventlog {
3240     inherit fetchurl stdenv;
3241   };
3243   facile = import ../development/libraries/facile {
3244     inherit fetchurl stdenv;
3245     # Actually, we don't need this version but we need native-code compilation
3246     ocaml = ocaml_3_10_0;
3247   };
3249   faac = import ../development/libraries/faac {
3250     inherit fetchurl stdenv autoconf automake libtool;
3251   };
3253   faad2 = import ../development/libraries/faad2 {
3254     inherit fetchurl stdenv;
3255   };
3257   fcgi = import ../development/libraries/fcgi {
3258       inherit fetchurl stdenv;
3259   };
3261   ffmpeg = import ../development/libraries/ffmpeg {
3262     inherit fetchurl stdenv faad2;
3263   };
3265   fftw = import ../development/libraries/fftw {
3266     inherit fetchurl stdenv builderDefs stringsWithDeps;
3267     singlePrecision = false;
3268   };
3270   fftwSinglePrec = import ../development/libraries/fftw {
3271     inherit fetchurl stdenv builderDefs stringsWithDeps;
3272     singlePrecision = true;
3273   };
3275   fltk11 = (import ../development/libraries/fltk/fltk11.nix) {
3276     inherit composableDerivation x11 lib pkgconfig freeglut;
3277     inherit fetchurl stdenv mesa mesaHeaders libpng libjpeg zlib ;
3278     inherit (xlibs) inputproto libXi libXinerama libXft;
3279     flags = [ "useNixLibs" "threads" "shared" "gl" ];
3280   };
3282   fltk20 = (import ../development/libraries/fltk) {
3283     inherit composableDerivation x11 lib pkgconfig freeglut;
3284     inherit fetchurl stdenv mesa mesaHeaders libpng libjpeg zlib ;
3285     inherit (xlibs) inputproto libXi libXinerama libXft;
3286     flags = [ "useNixLibs" "threads" "shared" "gl" ];
3287   };
3289   fmod = import ../development/libraries/fmod {
3290     inherit stdenv fetchurl;
3291   };
3293   freeimage = import ../development/libraries/freeimage {
3294     inherit fetchurl stdenv unzip;
3295   };
3297   freetts = import ../development/libraries/freetts {
3298     inherit stdenv fetchurl apacheAnt unzip sharutils lib;
3299   };
3301   cfitsio = import ../development/libraries/cfitsio {
3302     inherit fetchurl stdenv;
3303   };
3305   fontconfig = import ../development/libraries/fontconfig {
3306     inherit fetchurl stdenv freetype expat;
3307   };
3309   makeFontsConf = let fontconfig_ = fontconfig; in {fontconfig ? fontconfig_, fontDirectories}:
3310     import ../development/libraries/fontconfig/make-fonts-conf.nix {
3311       inherit runCommand libxslt fontconfig fontDirectories;
3312     };
3314   freealut = import ../development/libraries/freealut {
3315     inherit fetchurl stdenv openal;
3316   };
3318   freeglut = import ../development/libraries/freeglut {
3319     inherit fetchurl stdenv x11 mesa;
3320   };
3322   freetype = import ../development/libraries/freetype {
3323     inherit fetchurl stdenv;
3324   };
3326   fribidi = import ../development/libraries/fribidi {
3327     inherit fetchurl stdenv;
3328   };
3330   fam = gamin;
3332   gamin = import ../development/libraries/gamin {
3333     inherit fetchurl stdenv python pkgconfig glib;
3334   };
3336   gav = import ../games/gav {
3337     inherit fetchurl SDL SDL_image SDL_mixer SDL_net;
3338     stdenv = overrideGCC stdenv gcc41;
3339   };
3341   gdbm = import ../development/libraries/gdbm {
3342     inherit fetchurl stdenv;
3343   };
3345   gdk_pixbuf = import ../development/libraries/gdk-pixbuf {
3346     inherit fetchurl stdenv libtiff libjpeg libpng;
3347     inherit (gtkLibs1x) gtk;
3348   };
3350   gegl = import ../development/libraries/gegl {
3351     inherit fetchurl stdenv libpng pkgconfig babl;
3352     openexr = openexr_1_6_1;
3353     #  avocodec avformat librsvg
3354     inherit cairo libjpeg librsvg;
3355     inherit (gtkLibs) pango glib gtk;
3356   };
3358   geoip = builderDefsPackage ../development/libraries/geoip {
3359     inherit zlib;
3360   };
3362   geos = import ../development/libraries/geos {
3363     inherit fetchurl fetchsvn stdenv autoconf
3364       automake libtool swig which lib composableDerivation python ruby;
3365     use_svn = stdenv.system == "x86_64-linux";
3366   };
3368   gettext = import ../development/libraries/gettext {
3369     inherit fetchurl stdenv libiconv;
3370   };
3372   gd = import ../development/libraries/gd {
3373     inherit fetchurl stdenv zlib libpng freetype libjpeg fontconfig;
3374   };
3376   gdal = stdenv.mkDerivation {
3377     name = "gdal-1.6.1-rc1";
3378     src = fetchurl {
3379       url = ftp://ftp.remotesensing.org/gdal/gdal-1.6.1-RC1.tar.gz;
3380       sha256 = "0f7da588yvb1d3l3gk5m0hrqlhg8m4gw93aip3dwkmnawz9r0qcw";
3381     };
3382   };
3384   giblib = import ../development/libraries/giblib {
3385     inherit fetchurl stdenv x11 imlib2;
3386   };
3388   glew = import ../development/libraries/glew {
3389     inherit fetchurl stdenv mesa x11 libtool;
3390     inherit (xlibs) libXmu libXi;
3391   };
3393   glefw = import ../development/libraries/glefw {
3394     inherit fetchurl stdenv lib mesa;
3395     inherit (xlibs) libX11 libXext xextproto;
3396   };
3398   glibc =
3399     let haveRedHatKernel       = system == "i686-linux" || system == "x86_64-linux";
3400         haveBrokenRedHatKernel = haveRedHatKernel && getConfig ["brokenRedHatKernel"] false;
3401     in
3402     useFromStdenv "glibc" (if haveBrokenRedHatKernel then glibc25 else glibc29);
3404   glibc25 = import ../development/libraries/glibc-2.5 {
3405     inherit fetchurl stdenv kernelHeaders;
3406     installLocales = getPkgConfig "glibc" "locales" false;
3407   };
3409   glibc27 = import ../development/libraries/glibc-2.7 {
3410     inherit fetchurl stdenv kernelHeaders;
3411     #installLocales = false;
3412   };
3414   glibc29 = import ../development/libraries/glibc-2.9 {
3415     inherit fetchurl stdenv kernelHeaders;
3416     installLocales = getPkgConfig "glibc" "locales" false;
3417   };
3419   glibcLocales = makeOverridable (import ../development/libraries/glibc-2.9/locales.nix) {
3420     inherit fetchurl stdenv;
3421   };
3423   glibcInfo = import ../development/libraries/glibc-2.9/info.nix {
3424     inherit fetchurl stdenv texinfo perl;
3425   };
3427   glibc_multi =
3428       runCommand "${glibc.name}-multi"
3429         { glibc64 = glibc;
3430           glibc32 = (import ./all-packages.nix {system = "i686-linux";}).glibc;
3431         }
3432         ''
3433           ensureDir $out
3434           ln -s $glibc64/* $out/
3436           rm $out/lib $out/lib64
3437           ensureDir $out/lib
3438           ln -s $glibc64/lib/* $out/lib
3439           ln -s $glibc32/lib $out/lib/32
3440           ln -s lib $out/lib64
3442           rm $out/include
3443           cp -rs $glibc32/include $out
3444           chmod -R u+w $out/include
3445           cp -rsf $glibc64/include $out
3446         '' # */
3447         ;
3449   gmime = import ../development/libraries/gmime {
3450     inherit fetchurl stdenv pkgconfig zlib glib;
3451   };
3453   gmm = import ../development/libraries/gmm {
3454     inherit fetchurl stdenv;
3455   };
3457   gmp = import ../development/libraries/gmp {
3458     inherit fetchurl stdenv m4;
3459     cxx = false;
3460   };
3462   gmpxx = import ../development/libraries/gmp {
3463     inherit fetchurl stdenv m4;
3464     cxx = true;
3465   };
3467   goffice = import ../development/libraries/goffice {
3468     inherit fetchurl stdenv pkgconfig libgsf libxml2 cairo
3469       intltool gettext bzip2;
3470     inherit (gnome) glib gtk libglade libgnomeui pango;
3471     gconf = gnome.GConf;
3472     libart = gnome.libart_lgpl;
3473   };
3475   goocanvas = import ../development/libraries/goocanvas {
3476     inherit fetchurl stdenv pkgconfig cairo;
3477     inherit (gnome) gtk glib;
3478   };
3480   #GMP ex-satellite, so better keep it near gmp
3481   mpfr = import ../development/libraries/mpfr {
3482     inherit fetchurl stdenv gmp;
3483   };
3485   gst_all = recurseIntoAttrs (import ../development/libraries/gstreamer {
3486     inherit lib stdenv fetchurl perl bison pkgconfig libxml2
3487       python alsaLib cdparanoia libogg libvorbis libtheora freetype liboil
3488       libjpeg zlib speex libpng libdv aalib cairo libcaca flac hal libiec61883
3489       dbus libavc1394 ladspaH taglib pulseaudio gdbm bzip2 which makeOverridable;
3490     flex = flex2535;
3491     inherit (xorg) libX11 libXv libXext;
3492     inherit (gtkLibs) glib pango gtk;
3493     inherit (gnome) gnomevfs /* <- only passed for the no longer used older versions
3494              it is deprecated and didn't build on amd64 due to samba dependency */ gtkdoc
3495              libsoup;
3496   });
3498   gnet = import ../development/libraries/gnet {
3499     inherit fetchurl stdenv pkgconfig glib;
3500   };
3502   gnutls = import ../development/libraries/gnutls {
3503     inherit fetchurl stdenv libgcrypt zlib lzo libtasn1 guile;
3504     guileBindings = getConfig ["gnutls" "guile"] true;
3505   };
3507   gpgme = import ../development/libraries/gpgme {
3508     inherit fetchurl stdenv libgpgerror pkgconfig pth gnupg gnupg2 glib;
3509   };
3511   gsl = import ../development/libraries/gsl {
3512     inherit fetchurl stdenv;
3513   };
3515   gtkimageview = import ../development/libraries/gtkimageview {
3516     inherit fetchurl stdenv pkgconfig;
3517     inherit (gnome) gtk;
3518   };
3520   gtkLibs = recurseIntoAttrs gtkLibs218;
3522   glib = gtkLibs.glib;
3524   gtkLibs1x = rec {
3526     glib = import ../development/libraries/glib/1.2.x.nix {
3527       inherit fetchurl stdenv;
3528     };
3530     gtk = import ../development/libraries/gtk+/1.2.x.nix {
3531       inherit fetchurl stdenv x11 glib;
3532     };
3534   };
3536   gtkLibs216 = rec {
3538     glib = import ../development/libraries/glib/2.20.x.nix {
3539       inherit fetchurl stdenv pkgconfig gettext perl;
3540     };
3542     glibmm = import ../development/libraries/glibmm/2.18.x.nix {
3543       inherit fetchurl stdenv pkgconfig glib libsigcxx;
3544     };
3546     atk = import ../development/libraries/atk/1.24.x.nix {
3547       inherit fetchurl stdenv pkgconfig perl glib;
3548     };
3550     pango = import ../development/libraries/pango/1.24.x.nix {
3551       inherit fetchurl stdenv pkgconfig gettext x11 glib cairo libpng;
3552     };
3554     pangomm = import ../development/libraries/pangomm/2.14.x.nix {
3555       inherit fetchurl stdenv pkgconfig pango glibmm cairomm libpng;
3556     };
3558     gtk = import ../development/libraries/gtk+/2.16.x.nix {
3559       inherit fetchurl stdenv pkgconfig perl jasper x11 glib atk pango
3560         libtiff libjpeg libpng cairo xlibs;
3561     };
3563     gtkmm = import ../development/libraries/gtkmm/2.14.x.nix {
3564       inherit fetchurl stdenv pkgconfig gtk atk glibmm cairomm pangomm;
3565     };
3567   };
3569   gtkLibs218 = rec {
3571     glib = import ../development/libraries/glib/2.22.x.nix {
3572       inherit fetchurl stdenv pkgconfig gettext perl;
3573     };
3575     glibmm = import ../development/libraries/glibmm/2.22.x.nix {
3576       inherit fetchurl stdenv pkgconfig glib libsigcxx;
3577     };
3579     atk = import ../development/libraries/atk/1.28.x.nix {
3580       inherit fetchurl stdenv pkgconfig perl glib;
3581     };
3583     pango = import ../development/libraries/pango/1.26.x.nix {
3584       inherit fetchurl stdenv pkgconfig gettext x11 glib cairo libpng;
3585     };
3587     pangomm = import ../development/libraries/pangomm/2.26.x.nix {
3588       inherit fetchurl stdenv pkgconfig pango glibmm cairomm libpng;
3589     };
3591     gtk = import ../development/libraries/gtk+/2.18.x.nix {
3592       inherit fetchurl stdenv pkgconfig perl jasper glib atk pango
3593         libtiff libjpeg libpng cairo xlibs cups;
3594     };
3596     gtkmm = import ../development/libraries/gtkmm/2.18.x.nix {
3597       inherit fetchurl stdenv pkgconfig gtk atk glibmm cairomm pangomm;
3598     };
3600   };
3602   gtkmozembedsharp = import ../development/libraries/gtkmozembed-sharp {
3603     inherit fetchurl stdenv mono pkgconfig monoDLLFixer;
3604     inherit (gnome) gtk;
3605     gtksharp = gtksharp2;
3606   };
3608   gtksharp1 = import ../development/libraries/gtk-sharp-1 {
3609     inherit fetchurl stdenv mono pkgconfig libxml2 monoDLLFixer;
3610     inherit (gnome) gtk glib pango libglade libgtkhtml gtkhtml
3611               libgnomecanvas libgnomeui libgnomeprint
3612               libgnomeprintui GConf;
3613   };
3615   gtksharp2 = import ../development/libraries/gtk-sharp-2 {
3616     inherit fetchurl stdenv mono pkgconfig libxml2 monoDLLFixer;
3617     inherit (gnome) gtk glib pango libglade libgtkhtml gtkhtml
3618               libgnomecanvas libgnomeui libgnomeprint
3619               libgnomeprintui GConf gnomepanel;
3620   };
3622   gtksourceviewsharp = import ../development/libraries/gtksourceview-sharp {
3623     inherit fetchurl stdenv mono pkgconfig monoDLLFixer;
3624     inherit (gnome) gtksourceview;
3625     gtksharp = gtksharp2;
3626   };
3628   gtkspell = import ../development/libraries/gtkspell {
3629     inherit fetchurl stdenv pkgconfig;
3630     inherit (gtkLibs) gtk;
3631     inherit aspell;
3632   };
3634   # TODO : Add MIT Kerberos and let admin choose.
3635   kerberos = heimdal;
3637   heimdal = import ../development/libraries/kerberos/heimdal.nix {
3638     inherit fetchurl stdenv readline db4 openssl openldap cyrus_sasl;
3639   };
3641   hsqldb = import ../development/libraries/java/hsqldb {
3642     inherit stdenv fetchurl unzip;
3643   };
3645   hwloc = import ../development/libraries/hwloc {
3646     inherit fetchurl stdenv pkgconfig cairo expat;
3647   };
3649   icu = import ../development/libraries/icu {
3650     inherit fetchurl stdenv;
3651   };
3653   id3lib = import ../development/libraries/id3lib {
3654     inherit fetchurl stdenv;
3655   };
3657   ilbc = import ../development/libraries/ilbc {
3658     inherit stdenv msilbc;
3659   };
3661   ilmbase = import ../development/libraries/ilmbase {
3662     inherit fetchurl stdenv;
3663   };
3665   imlib = import ../development/libraries/imlib {
3666     inherit fetchurl stdenv libjpeg libtiff libungif libpng;
3667     inherit (xlibs) libX11 libXext xextproto;
3668   };
3670   imlib2 = import ../development/libraries/imlib2 {
3671     inherit fetchurl stdenv x11 libjpeg libtiff libungif libpng bzip2;
3672   };
3674   indilib = import ../development/libraries/indilib {
3675     inherit fetchurl stdenv cfitsio libusb zlib;
3676   };
3678   iniparser = import ../development/libraries/iniparser {
3679     inherit fetchurl stdenv;
3680   };
3682   intltool = gnome.intltool;
3684   isocodes = import ../development/libraries/iso-codes {
3685     inherit stdenv fetchurl gettext python;
3686   };
3688   jamp = builderDefsPackage ../games/jamp {
3689     inherit mesa SDL SDL_image SDL_mixer;
3690   };
3692   jasper = import ../development/libraries/jasper {
3693     inherit fetchurl stdenv unzip xlibs libjpeg;
3694   };
3696   jetty_gwt = import ../development/libraries/java/jetty-gwt {
3697     inherit stdenv fetchurl;
3698   };
3700   jetty_util = import ../development/libraries/java/jetty-util {
3701     inherit stdenv fetchurl;
3702   };
3704   krb5 = import ../development/libraries/kerberos/krb5.nix {
3705     inherit stdenv fetchurl perl ncurses yacc;
3706   };
3708   lablgtk = import ../development/libraries/lablgtk {
3709     inherit fetchurl stdenv ocaml pkgconfig;
3710     inherit (gtkLibs) gtk;
3711     inherit (gnome) libgnomecanvas;
3712   };
3714   lcms = import ../development/libraries/lcms {
3715     inherit fetchurl stdenv;
3716   };
3718   lesstif = import ../development/libraries/lesstif {
3719     inherit fetchurl stdenv x11;
3720     inherit (xlibs) libXp libXau;
3721   };
3723   lesstif93 = import ../development/libraries/lesstif-0.93 {
3724     inherit fetchurl stdenv x11;
3725     inherit (xlibs) libXp libXau;
3726   };
3728   lib3ds = import ../development/libraries/lib3ds {
3729     inherit fetchurl stdenv unzip;
3730   };
3732   libaal = import ../development/libraries/libaal {
3733     inherit fetchurl stdenv;
3734   };
3736   libao = import ../development/libraries/libao {
3737     inherit stdenv fetchurl pkgconfig pulseaudio;
3738   };
3740   libarchive = import ../development/libraries/libarchive {
3741     inherit fetchurl stdenv zlib bzip2 e2fsprogs sharutils;
3742   };
3744   libassuan = import ../development/libraries/libassuan {
3745     inherit fetchurl stdenv pth;
3746   };
3748   libavc1394 = import ../development/libraries/libavc1394 {
3749     inherit fetchurl stdenv pkgconfig libraw1394;
3750   };
3752   libcaca = import ../development/libraries/libcaca {
3753     inherit fetchurl stdenv ncurses;
3754   };
3756   libcanberra = import ../development/libraries/libcanberra {
3757     inherit fetchurl stdenv pkgconfig libtool alsaLib pulseaudio libvorbis;
3758     inherit (gtkLibs) gtk gthread;
3759     gstreamer = gst_all.gstreamer;
3760   };
3762   libcdaudio = import ../development/libraries/libcdaudio {
3763     inherit fetchurl stdenv;
3764   };
3766   libcddb = import ../development/libraries/libcddb {
3767     inherit fetchurl stdenv;
3768   };
3770   libcdio = import ../development/libraries/libcdio {
3771     inherit fetchurl stdenv libcddb pkgconfig ncurses help2man;
3772   };
3774   libcm = import ../development/libraries/libcm {
3775     inherit fetchurl stdenv pkgconfig xlibs mesa glib;
3776   };
3778   libcv = builderDefsPackage (import ../development/libraries/libcv) {
3779     inherit libtiff libjpeg libpng pkgconfig;
3780     inherit (gtkLibs) gtk glib;
3781   };
3783   libdaemon = import ../development/libraries/libdaemon {
3784     inherit fetchurl stdenv;
3785   };
3787   libdbi = composedArgsAndFun (import ../development/libraries/libdbi/0.8.2.nix) {
3788     inherit stdenv fetchurl builderDefs;
3789   };
3791   libdbiDriversBase = composedArgsAndFun (import ../development/libraries/libdbi-drivers/0.8.2-1.nix) {
3792     inherit stdenv fetchurl builderDefs libdbi;
3793   };
3795   libdbiDrivers = libdbiDriversBase.passthru.function {
3796     inherit sqlite mysql;
3797   };
3799   libdv = import ../development/libraries/libdv {
3800     inherit fetchurl stdenv lib composableDerivation;
3801   };
3803   libdrm = import ../development/libraries/libdrm {
3804     inherit fetchurl stdenv pkgconfig;
3805     inherit (xorg) libpthreadstubs;
3806   };
3808   libdvdcss = import ../development/libraries/libdvdcss {
3809     inherit fetchurl stdenv;
3810   };
3812   libdvdnav = import ../development/libraries/libdvdnav {
3813     inherit fetchurl stdenv libdvdread;
3814   };
3816   libdvdread = import ../development/libraries/libdvdread {
3817     inherit fetchurl stdenv libdvdcss;
3818   };
3820   libedit = import ../development/libraries/libedit {
3821     inherit fetchurl stdenv ncurses;
3822   };
3824   liblo = import ../development/libraries/liblo {
3825     inherit fetchurl stdenv;
3826   };
3828   libev = builderDefsPackage ../development/libraries/libev {
3829   };
3831   libevent = import ../development/libraries/libevent {
3832     inherit fetchurl stdenv;
3833   };
3835   libewf = import ../development/libraries/libewf {
3836     inherit fetchurl stdenv zlib openssl libuuid;
3837   };
3839   libexif = import ../development/libraries/libexif {
3840     inherit fetchurl stdenv gettext;
3841   };
3843   libextractor = composedArgsAndFun (import ../development/libraries/libextractor/0.5.18.nix) {
3844     inherit fetchurl stdenv builderDefs zlib;
3845   };
3847   libffcall = builderDefsPackage (import ../development/libraries/libffcall) {
3848     inherit fetchcvs;
3849   };
3851   libffi = import ../development/libraries/libffi {
3852     inherit fetchurl stdenv;
3853   };
3855   libftdi = import ../development/libraries/libftdi {
3856     inherit fetchurl stdenv libusb;
3857   };
3859   libgcrypt = import ../development/libraries/libgcrypt {
3860     inherit fetchurl stdenv libgpgerror;
3861   };
3863   libgpgerror = import ../development/libraries/libgpg-error {
3864     inherit fetchurl stdenv;
3865   };
3867   libgphoto2 = import ../development/libraries/libgphoto2 {
3868     inherit fetchurl stdenv pkgconfig libusb libtool libexif libjpeg gettext;
3869   };
3871   libgpod = import ../development/libraries/libgpod {
3872     inherit fetchurl stdenv gettext perl perlXMLParser pkgconfig libxml2 glib;
3873   };
3875   libharu = import ../development/libraries/libharu {
3876     inherit fetchurl stdenv lib zlib libpng;
3877   };
3879   libical = import ../development/libraries/libical {
3880     inherit stdenv fetchurl perl;
3881   };
3883   libQGLViewer = import ../development/libraries/libqglviewer {
3884     inherit fetchurl stdenv;
3885     inherit qt4;
3886   };
3888   libsamplerate = import ../development/libraries/libsamplerate {
3889     inherit fetchurl stdenv pkgconfig lib;
3890   };
3892   libspectre = import ../development/libraries/libspectre {
3893     inherit fetchurl stdenv;
3894     ghostscript = ghostscriptX;
3895   };
3897   libgsf = import ../development/libraries/libgsf {
3898     inherit fetchurl stdenv perl perlXMLParser pkgconfig libxml2
3899       intltool gettext bzip2 python;
3900     inherit (gnome) glib gnomevfs libbonobo;
3901   };
3903   libiconv = import ../development/libraries/libiconv {
3904     inherit fetchurl stdenv;
3905   };
3907   libid3tag = import ../development/libraries/libid3tag {
3908     inherit fetchurl stdenv zlib;
3909   };
3911   libidn = import ../development/libraries/libidn {
3912     inherit fetchurl stdenv;
3913   };
3915   libiec61883 = import ../development/libraries/libiec61883 {
3916     inherit fetchurl stdenv pkgconfig libraw1394;
3917   };
3919   libjingle = import ../development/libraries/libjingle/0.3.11.nix {
3920     inherit fetchurl stdenv mediastreamer;
3921   };
3923   libjpeg = makeOverridable (import ../development/libraries/libjpeg) {
3924     inherit fetchurl stdenv;
3925     libtool = libtool_1_5;
3926   };
3928   libjpegStatic = lowPrio (appendToName "static" (libjpeg.override {
3929     static = true;
3930   }));
3932   libksba = import ../development/libraries/libksba {
3933     inherit fetchurl stdenv libgpgerror;
3934   };
3936   libmad = import ../development/libraries/libmad {
3937     inherit fetchurl stdenv;
3938   };
3940   libmcs = import ../development/libraries/libmcs {
3941     inherit fetchurl stdenv pkgconfig libmowgli;
3942   };
3944   libmicrohttpd = import ../development/libraries/libmicrohttpd {
3945     inherit fetchurl stdenv curl;
3946   };
3948   libmowgli = import ../development/libraries/libmowgli {
3949     inherit fetchurl stdenv;
3950   };
3952   libmng = import ../development/libraries/libmng {
3953     inherit fetchurl stdenv lib zlib libpng libjpeg lcms automake autoconf libtool;
3954   };
3956   libmpcdec = import ../development/libraries/libmpcdec {
3957     inherit fetchurl stdenv;
3958   };
3960   libmsn = import ../development/libraries/libmsn {
3961     inherit stdenv fetchurl cmake openssl;
3962   };
3964   libmspack = import ../development/libraries/libmspack {
3965     inherit fetchurl stdenv;
3966   };
3968   libnova = import ../development/libraries/libnova {
3969     inherit fetchurl stdenv;
3970   };
3972   libogg = import ../development/libraries/libogg {
3973     inherit fetchurl stdenv;
3974   };
3976   liboil = makeOverridable (import ../development/libraries/liboil) {
3977     inherit fetchurl stdenv pkgconfig glib;
3978   };
3980   liboop = import ../development/libraries/liboop {
3981     inherit fetchurl stdenv;
3982   };
3984   libotr = import ../development/libraries/libotr {
3985     inherit fetchurl stdenv libgcrypt;
3986   };
3988   libpcap = import ../development/libraries/libpcap {
3989     inherit fetchurl stdenv flex bison;
3990   };
3992   libpng = import ../development/libraries/libpng {
3993     inherit fetchurl stdenv zlib;
3994   };
3996   libproxy = import ../development/libraries/libproxy {
3997     inherit stdenv fetchurl;
3998   };
4000   libpseudo = import ../development/libraries/libpseudo {
4001     inherit fetchurl stdenv pkgconfig ncurses glib;
4002   };
4004   libsigcxx = import ../development/libraries/libsigcxx {
4005     inherit fetchurl stdenv pkgconfig;
4006   };
4008   libsigsegv = import ../development/libraries/libsigsegv {
4009     inherit fetchurl stdenv;
4010   };
4012   # To bootstrap SBCL, I need CLisp 2.44.1; it needs libsigsegv 2.5
4013   libsigsegv_25 =  import ../development/libraries/libsigsegv/2.5.nix {
4014     inherit fetchurl stdenv;
4015   };
4017   libsndfile = import ../development/libraries/libsndfile {
4018     inherit fetchurl stdenv;
4019   };
4021   libtasn1 = import ../development/libraries/libtasn1 {
4022     inherit fetchurl stdenv;
4023   };
4025   libtheora = import ../development/libraries/libtheora {
4026     inherit fetchurl stdenv libogg libvorbis;
4027   };
4029   libtiff = import ../development/libraries/libtiff {
4030     inherit fetchurl stdenv zlib libjpeg;
4031   };
4033   libtommath = import ../development/libraries/libtommath {
4034     inherit fetchurl stdenv libtool;
4035   };
4037   libunistring = import ../development/libraries/libunistring {
4038     inherit fetchurl stdenv libiconv;
4039   };
4041   libupnp = import ../development/libraries/pupnp {
4042     inherit fetchurl stdenv;
4043   };
4045   giflib = import ../development/libraries/giflib {
4046     inherit fetchurl stdenv;
4047   };
4049   libungif = import ../development/libraries/giflib/libungif.nix {
4050     inherit fetchurl stdenv;
4051   };
4053   libusb = import ../development/libraries/libusb {
4054     inherit fetchurl stdenv;
4055   };
4057   libunwind = import ../development/libraries/libunwind {
4058     inherit fetchurl stdenv;
4059   };
4061   libvncserver = builderDefsPackage (import ../development/libraries/libvncserver) {
4062     inherit libtool libjpeg openssl zlib;
4063     inherit (xlibs) xproto libX11 damageproto libXdamage
4064       libXext xextproto fixesproto libXfixes xineramaproto
4065       libXinerama libXrandr randrproto libXtst;
4066   };
4068   libviper = import ../development/libraries/libviper {
4069     inherit fetchurl stdenv pkgconfig ncurses gpm glib;
4070   };
4072   libvterm = import ../development/libraries/libvterm {
4073     inherit fetchurl stdenv pkgconfig ncurses glib;
4074   };
4076   libvorbis = import ../development/libraries/libvorbis {
4077     inherit fetchurl stdenv libogg;
4078   };
4080   libwmf = import ../development/libraries/libwmf {
4081     inherit fetchurl stdenv pkgconfig imagemagick
4082       zlib libpng freetype libjpeg libxml2 glib;
4083   };
4085   libwpd = import ../development/libraries/libwpd {
4086     inherit fetchurl stdenv pkgconfig libgsf libxml2 bzip2;
4087     inherit (gnome) glib;
4088   };
4090   libx86 = builderDefsPackage ../development/libraries/libx86 {};
4092   libxcrypt = import ../development/libraries/libxcrypt {
4093     inherit fetchurl stdenv;
4094   };
4096   libxklavier = import ../development/libraries/libxklavier {
4097     inherit fetchurl stdenv xkeyboard_config pkgconfig libxml2 isocodes glib;
4098     inherit (xorg) libX11 libICE libXi libxkbfile;
4099   };
4101   libxmi = import ../development/libraries/libxmi {
4102     inherit fetchurl stdenv libtool;
4103   };
4105   libxml2 = makeOverridable (import ../development/libraries/libxml2) {
4106     inherit fetchurl stdenv zlib python;
4107     pythonSupport = false;
4108   };
4110   libxml2Python = libxml2.override {
4111     pythonSupport = true;
4112   };
4114   libxslt = makeOverridable (import ../development/libraries/libxslt) {
4115     inherit fetchurl stdenv libxml2;
4116   };
4118   libixp_for_wmii = lowPrio (import ../development/libraries/libixp_for_wmii {
4119     inherit fetchurl stdenv;
4120   });
4122   libzip = import ../development/libraries/libzip {
4123     inherit fetchurl stdenv zlib;
4124   };
4126   libzrtpcpp = import ../development/libraries/libzrtpcpp {
4127     inherit fetchurl stdenv lib commoncpp2 openssl pkgconfig ccrtp;
4128   };
4130   lightning = import ../development/libraries/lightning {
4131     inherit fetchurl stdenv;
4132   };
4134   log4cxx = import ../development/libraries/log4cxx {
4135     inherit fetchurl stdenv automake autoconf libtool cppunit libxml2 boost;
4136     inherit apr aprutil db45 expat;
4137   };
4139   loudmouth = import ../development/libraries/loudmouth {
4140     inherit fetchurl stdenv libidn openssl pkgconfig zlib glib;
4141   };
4143   lzo = import ../development/libraries/lzo {
4144     inherit fetchurl stdenv;
4145   };
4147   # failed to build
4148   mediastreamer = composedArgsAndFun (import ../development/libraries/mediastreamer/2.2.0-cvs20080207.nix) {
4149     inherit fetchurl stdenv automake libtool autoconf alsaLib pkgconfig speex
4150       ortp ffmpeg;
4151   };
4153   mesaSupported =
4154     system == "i686-linux" ||
4155     system == "x86_64-linux" ||
4156     system == "x86_64-darwin" ||
4157     system == "i686-darwin";
4159   mesa = import ../development/libraries/mesa {
4160     inherit fetchurl stdenv pkgconfig expat x11 xlibs libdrm;
4161   };
4163   mesaHeaders = import ../development/libraries/mesa/headers.nix {
4164     inherit stdenv;
4165     mesaSrc = mesa.src;
4166   };
4168   ming = import ../development/libraries/ming {
4169     inherit fetchurl stdenv flex bison freetype zlib libpng perl;
4170   };
4172   mpeg2dec = import ../development/libraries/mpeg2dec {
4173     inherit fetchurl stdenv;
4174   };
4176   msilbc = import ../development/libraries/msilbc {
4177     inherit fetchurl stdenv ilbc mediastreamer pkgconfig;
4178   };
4180   mpich2 = import ../development/libraries/mpich2 {
4181     inherit fetchurl stdenv python;
4182   };
4184   muparser = import ../development/libraries/muparser {
4185     inherit fetchurl stdenv;
4186   };
4188   ncurses = composedArgsAndFun (import ../development/libraries/ncurses) {
4189     inherit fetchurl stdenv;
4190     unicode = (system != "i686-cygwin");
4191   };
4193   neon = neon026;
4195   neon026 = import ../development/libraries/neon/0.26.nix {
4196     inherit fetchurl stdenv libxml2 zlib openssl;
4197     compressionSupport = true;
4198     sslSupport = true;
4199   };
4201   neon028 = import ../development/libraries/neon/0.28.nix {
4202     inherit fetchurl stdenv libxml2 zlib openssl;
4203     compressionSupport = true;
4204     sslSupport = true;
4205   };
4207   nethack = builderDefsPackage (import ../games/nethack) {
4208     inherit ncurses flex bison;
4209   };
4211   nettle = import ../development/libraries/nettle {
4212     inherit fetchurl stdenv gmp gnum4;
4213   };
4215   nspr = import ../development/libraries/nspr {
4216     inherit fetchurl stdenv;
4217   };
4219   nss = import ../development/libraries/nss {
4220     inherit fetchurl stdenv nspr perl zlib;
4221   };
4223   ode = builderDefsPackage (import ../development/libraries/ode) {
4224   };
4226   openal = import ../development/libraries/openal {
4227     inherit fetchurl stdenv cmake alsaLib;
4228   };
4230   # added because I hope that it has been easier to compile on x86 (for blender)
4231   openalSoft = import ../development/libraries/openalSoft {
4232     inherit fetchurl stdenv alsaLib libtool cmake;
4233   };
4235   openbabel = import ../development/libraries/openbabel {
4236     inherit fetchurl stdenv zlib libxml2;
4237   };
4239   opencascade = import ../development/libraries/opencascade {
4240     inherit fetchurl stdenv mesa qt4 tcl tk;
4241   };
4243   # this ctl version is needed by openexr_viewers
4244   openexr_ctl = import ../development/libraries/openexr_ctl {
4245     inherit fetchurl stdenv ilmbase ctl;
4246     openexr = openexr_1_6_1;
4247   };
4249   openexr_1_6_1 = import ../development/libraries/openexr {
4250     inherit fetchurl stdenv ilmbase zlib pkgconfig lib;
4251     version = "1.6.1";
4252     # optional features:
4253     inherit ctl;
4254   };
4256   # This older version is needed by blender (it complains about missing half.h )
4257   openexr_1_4_0 = import ../development/libraries/openexr {
4258     inherit fetchurl stdenv ilmbase zlib pkgconfig lib;
4259     version = "1.4.0";
4260   };
4262   openldap = import ../development/libraries/openldap {
4263     inherit fetchurl stdenv openssl cyrus_sasl db4 groff;
4264   };
4266   openlierox = builderDefsPackage ../games/openlierox {
4267     inherit (xlibs) libX11 xproto;
4268     inherit gd SDL SDL_image SDL_mixer zlib libxml2
4269       pkgconfig;
4270   };
4272   openssl = import ../development/libraries/openssl {
4273     fetchurl = fetchurlBoot;
4274     inherit stdenv perl;
4275   };
4277   ortp = import ../development/libraries/ortp {
4278     inherit fetchurl stdenv;
4279   };
4281   pangoxsl = import ../development/libraries/pangoxsl {
4282     inherit fetchurl stdenv pkgconfig;
4283     inherit (gtkLibs) glib pango;
4284   };
4286   pcre = makeOverridable (import ../development/libraries/pcre) {
4287     inherit fetchurl stdenv;
4288     unicodeSupport = getConfig ["pcre" "unicode"] false;
4289     cplusplusSupport = !stdenv ? isDietLibC;
4290   };
4292   physfs = import ../development/libraries/physfs {
4293     inherit fetchurl stdenv cmake;
4294   };
4296   plib = import ../development/libraries/plib {
4297     inherit fetchurl stdenv mesa freeglut SDL;
4298     inherit (xlibs) libXi libSM libXmu libXext libX11;
4299   };
4301   polkit = import ../development/libraries/polkit {
4302     inherit stdenv fetchurl pkgconfig eggdbus expat pam intltool gettext glib;
4303   };
4305   policykit = makeOverridable (import ../development/libraries/policykit) {
4306     inherit stdenv fetchurl pkgconfig dbus dbus_glib expat pam
4307       intltool gettext libxslt docbook_xsl glib;
4308   };
4310   poppler = makeOverridable (import ../development/libraries/poppler) {
4311     inherit fetchurl stdenv cairo freetype fontconfig zlib libjpeg pkgconfig;
4312     inherit (gtkLibs) glib gtk;
4313     qt4Support = false;
4314   };
4316   popplerQt44 = poppler.override {
4317     qt4Support = true;
4318     qt4 = qt44;
4319   };
4321   popplerQt45 = poppler.override {
4322     qt4Support = true;
4323     qt4 = qt45;
4324   };
4326   popt = import ../development/libraries/popt {
4327     inherit fetchurl stdenv;
4328   };
4330   proj = import ../development/libraries/proj.4 {
4331     inherit fetchurl stdenv;
4332   };
4334   pth = import ../development/libraries/pth {
4335     inherit fetchurl stdenv;
4336   };
4338   qt3 = makeOverridable (import ../development/libraries/qt-3) {
4339     inherit fetchurl stdenv x11 zlib libjpeg libpng which mysql mesa;
4340     inherit (xlibs) xextproto libXft libXrender libXrandr randrproto
4341       libXmu libXinerama libXcursor;
4342     openglSupport = mesaSupported;
4343     mysqlSupport = getConfig ["qt" "mysql"] false;
4344   };
4346   qt3mysql = qt3.override {
4347     mysqlSupport = true;
4348   };
4350   qt4 = qt44;
4352   qt44 = import ../development/libraries/qt-4.4 {
4353     inherit fetchurl stdenv fetchsvn zlib libjpeg libpng which mysql mesa openssl cups dbus
4354       fontconfig freetype pkgconfig libtiff;
4355     inherit (xlibs) xextproto libXft libXrender libXrandr randrproto
4356       libXmu libXinerama xineramaproto libXcursor libICE libSM libX11 libXext
4357       inputproto fixesproto libXfixes;
4358     inherit (gnome) glib;
4359   };
4361   qt45 = import ../development/libraries/qt-4.5 {
4362     inherit fetchurl stdenv lib zlib libjpeg libpng which mysql mesa openssl cups dbus
4363       fontconfig freetype pkgconfig libtiff;
4364     inherit (xlibs) xextproto libXft libXrender libXrandr randrproto
4365       libXmu libXinerama xineramaproto libXcursor libXext
4366       inputproto fixesproto libXfixes;
4367     inherit (gnome) glib;
4368   };
4370   qtscriptgenerator = import ../development/libraries/qtscriptgenerator {
4371     inherit stdenv fetchurl;
4372     qt4 = qt45;
4373   };
4375   readline = readline6;
4377   readline4 = import ../development/libraries/readline/readline4.nix {
4378     inherit fetchurl stdenv ncurses;
4379   };
4381   readline5 = import ../development/libraries/readline/readline5.nix {
4382     inherit fetchurl stdenv ncurses;
4383   };
4385   readline6 = import ../development/libraries/readline/readline6.nix {
4386     inherit fetchurl stdenv ncurses;
4387   };
4389   librdf_raptor = import ../development/libraries/librdf/raptor.nix {
4390     inherit fetchurl stdenv lib libxml2 curl;
4391   };
4392   librdf_rasqal = import ../development/libraries/librdf/rasqal.nix {
4393     inherit fetchurl stdenv lib pcre libxml2 gmp librdf_raptor;
4394   };
4395   librdf = import ../development/libraries/librdf {
4396     inherit fetchurl stdenv lib pkgconfig librdf_raptor ladspaH openssl zlib;
4397   };
4399   # Also known as librdf, includes raptor and rasqal
4400   redland = composedArgsAndFun (import ../development/libraries/redland/1.0.9.nix) {
4401     inherit fetchurl stdenv openssl libxml2 pkgconfig perl postgresql sqlite
4402       mysql libxslt curl pcre librdf_rasqal librdf_raptor;
4403     bdb = db4;
4404   };
4406   redland_1_0_8 = composedArgsAndFun (import ../development/libraries/redland/1.0.8.nix) {
4407     inherit fetchurl stdenv openssl libxml2 pkgconfig perl postgresql sqlite
4408       mysql libxslt curl pcre librdf_rasqal librdf_raptor;
4409     bdb = db4;
4410   };
4412   rhino = import ../development/libraries/java/rhino {
4413     inherit fetchurl stdenv unzip;
4414     ant = apacheAntGcj;
4415     javac = gcj;
4416     jvm = gcj;
4417   };
4419   rte = import ../development/libraries/rte {
4420     inherit fetchurl stdenv;
4421   };
4423   rubberband = import ../development/libraries/rubberband {
4424     inherit fetchurl stdenv lib pkgconfig libsamplerate libsndfile ladspaH;
4425     fftw = fftwSinglePrec;
4426     inherit (vamp) vampSDK;
4427   };
4429   schroedinger = import ../development/libraries/schroedinger {
4430     inherit fetchurl stdenv liboil pkgconfig;
4431   };
4433   SDL = makeOverridable (import ../development/libraries/SDL) {
4434     inherit fetchurl stdenv pkgconfig x11 mesa alsaLib pulseaudio;
4435     inherit (xlibs) libXrandr;
4436     openglSupport = mesaSupported;
4437     alsaSupport = true;
4438     pulseaudioSupport = false; # better go through ALSA
4439   };
4441   SDL_image = import ../development/libraries/SDL_image {
4442     inherit fetchurl stdenv SDL libjpeg libungif libtiff libpng;
4443     inherit (xlibs) libXpm;
4444   };
4446   SDL_mixer = import ../development/libraries/SDL_mixer {
4447     inherit fetchurl stdenv SDL libogg libvorbis;
4448   };
4450   SDL_net = import ../development/libraries/SDL_net {
4451     inherit fetchurl stdenv SDL;
4452   };
4454   SDL_ttf = import ../development/libraries/SDL_ttf {
4455     inherit fetchurl stdenv SDL freetype;
4456   };
4458   slang = import ../development/libraries/slang {
4459     inherit fetchurl stdenv ncurses pcre libpng zlib readline;
4460   };
4462   slibGuile = import ../development/libraries/slib {
4463     inherit fetchurl stdenv unzip texinfo;
4464     scheme = guile;
4465   };
4467   snack = import ../development/libraries/snack {
4468     inherit fetchurl stdenv tcl tk pkgconfig x11;
4469         # optional
4470     inherit alsaLib vorbisTools python;
4471   };
4473   speex = import ../development/libraries/speex {
4474     inherit fetchurl stdenv libogg;
4475   };
4477   sqlite = import ../development/libraries/sqlite {
4478     inherit fetchurl stdenv readline tcl;
4479   };
4481   stlport =  import ../development/libraries/stlport {
4482     inherit fetchurl stdenv;
4483   };
4485   t1lib = import ../development/libraries/t1lib {
4486     inherit fetchurl stdenv x11;
4487     inherit (xlibs) libXaw libXpm;
4488   };
4490   taglib = import ../development/libraries/taglib {
4491     inherit fetchurl stdenv zlib;
4492   };
4494   taglib_extras = import ../development/libraries/taglib-extras {
4495     inherit stdenv fetchurl cmake taglib;
4496   };
4498   tapioca_qt = import ../development/libraries/tapioca-qt {
4499     inherit stdenv fetchurl cmake qt4 telepathy_qt;
4500   };
4502   tecla = import ../development/libraries/tecla {
4503     inherit fetchurl stdenv;
4504   };
4506   telepathy_gabble = import ../development/libraries/telepathy-gabble {
4507     inherit fetchurl stdenv pkgconfig libxslt telepathy_glib loudmouth;
4508   };
4510   telepathy_glib = import ../development/libraries/telepathy-glib {
4511     inherit fetchurl stdenv dbus_glib pkgconfig libxslt python glib;
4512   };
4514   telepathy_qt = import ../development/libraries/telepathy-qt {
4515     inherit stdenv fetchurl cmake qt4;
4516   };
4518   tk = import ../development/libraries/tk/8.5.7.nix {
4519     inherit fetchurl stdenv tcl x11;
4520   };
4522   unixODBC = import ../development/libraries/unixODBC {
4523     inherit fetchurl stdenv;
4524   };
4526   unixODBCDrivers = recurseIntoAttrs (import ../development/libraries/unixODBCDrivers {
4527     inherit fetchurl stdenv unixODBC glibc libtool openssl zlib;
4528     inherit postgresql mysql sqlite;
4529   });
4531   vamp = import ../development/libraries/audio/vamp {
4532     inherit fetchurl stdenv lib pkgconfig libsndfile;
4533   };
4535   vtk = import ../development/libraries/vtk {
4536     inherit stdenv fetchurl cmake mesa;
4537     inherit (xlibs) libX11 xproto libXt;
4538   };
4540   vxl = import ../development/libraries/vxl {
4541    inherit fetchurl stdenv cmake unzip libtiff expat zlib libpng libjpeg;
4542   };
4544   webkit = builderDefsPackage (import ../development/libraries/webkit) {
4545     inherit (gnome28) gtkdoc libsoup;
4546     inherit (gtkLibs) gtk atk pango glib;
4547     inherit freetype fontconfig gettext gperf curl
4548       libjpeg libtiff libpng libxml2 libxslt sqlite
4549       icu cairo perl intltool automake libtool
4550       pkgconfig autoconf bison libproxy enchant;
4551     inherit (gst_all) gstreamer gstPluginsBase gstFfmpeg
4552       gstPluginsGood;
4553     flex = flex2535;
4554     inherit (xlibs) libXt;
4555   };
4557   wxGTK = wxGTK28;
4559   wxGTK26 = import ../development/libraries/wxGTK-2.6 {
4560     inherit fetchurl stdenv pkgconfig;
4561     inherit (gtkLibs216) gtk;
4562     inherit (xlibs) libXinerama libSM libXxf86vm xf86vidmodeproto;
4563   };
4565   wxGTK28 = makeOverridable (import ../development/libraries/wxGTK-2.8) {
4566     inherit fetchurl stdenv pkgconfig mesa;
4567     inherit (gtkLibs216) gtk;
4568     inherit (xlibs) libXinerama libSM libXxf86vm xf86vidmodeproto;
4569   };
4571   wtk = import ../development/libraries/wtk {
4572       inherit fetchurl stdenv unzip xlibs;
4573     };
4575   x264 = import ../development/libraries/x264 {
4576     inherit fetchurl stdenv;
4577   };
4579   xapian = makeOverridable (import ../development/libraries/xapian) {
4580     inherit fetchurl stdenv zlib;
4581   };
4583   xapianBindings = (import ../development/libraries/xapian/bindings/1.0.14.nix) {
4584     inherit fetchurl stdenv xapian composableDerivation pkgconfig;
4585     inherit ruby perl php tcl python; # TODO perl php Java, tcl, C#, python
4586   };
4588   Xaw3d = import ../development/libraries/Xaw3d {
4589     inherit fetchurl stdenv x11 bison;
4590     flex = flex2533;
4591     inherit (xlibs) imake gccmakedep libXmu libXpm libXp;
4592   };
4594   xineLib = import ../development/libraries/xine-lib {
4595     inherit fetchurl stdenv zlib libdvdcss alsaLib pkgconfig mesa aalib
4596       libvorbis libtheora speex xlibs perl ffmpeg;
4597   };
4599   xautolock = import ../misc/screensavers/xautolock {
4600     inherit fetchurl stdenv x11;
4601     inherit (xorg) imake;
4602     inherit (xlibs) libXScrnSaver scrnsaverproto;
4603   };
4605   xercesJava = import ../development/libraries/java/xerces {
4606     inherit fetchurl stdenv;
4607     ant   = apacheAntGcj;  # for bootstrap purposes
4608     javac = gcj;
4609     jvm   = gcj;
4610   };
4612   xlibsWrapper = import ../development/libraries/xlibs-wrapper {
4613     inherit stdenv;
4614     packages = [
4615       freetype fontconfig xlibs.xproto xlibs.libX11 xlibs.libXt
4616       xlibs.libXft xlibs.libXext xlibs.libSM xlibs.libICE
4617       xlibs.xextproto
4618     ];
4619   };
4621   zangband = builderDefsPackage (import ../games/zangband) {
4622     inherit ncurses flex bison autoconf automake m4 coreutils;
4623   };
4625   zlib = import ../development/libraries/zlib {
4626     fetchurl = fetchurlBoot;
4627     inherit stdenv;
4628   };
4630   zlibStatic = lowPrio (appendToName "static" (import ../development/libraries/zlib {
4631     inherit fetchurl stdenv;
4632     static = true;
4633   }));
4635   zvbi = import ../development/libraries/zvbi {
4636     inherit fetchurl stdenv libpng x11;
4637     pngSupport = true;
4638   };
4641   ### DEVELOPMENT / LIBRARIES / JAVA
4644   atermjava = import ../development/libraries/java/aterm {
4645     inherit fetchurl sharedobjects jjtraveler jdk;
4646     stdenv = overrideInStdenv stdenv [gnumake380];
4647   };
4649   commonsFileUpload = import ../development/libraries/java/jakarta-commons/file-upload {
4650     inherit stdenv fetchurl;
4651   };
4653   fastjar = import ../development/tools/java/fastjar {
4654     inherit fetchurl stdenv zlib;
4655   };
4657   httpunit = import ../development/libraries/java/httpunit {
4658     inherit stdenv fetchurl unzip;
4659   };
4661   gwtdragdrop = import ../development/libraries/java/gwt-dragdrop {
4662     inherit stdenv fetchurl;
4663   };
4665   gwtwidgets = import ../development/libraries/java/gwt-widgets {
4666     inherit stdenv fetchurl;
4667   };
4669   jakartabcel = import ../development/libraries/java/jakarta-bcel {
4670     regexp = jakartaregexp;
4671     inherit fetchurl stdenv;
4672   };
4674   jakartaregexp = import ../development/libraries/java/jakarta-regexp {
4675     inherit fetchurl stdenv;
4676   };
4678   javaCup = import ../development/libraries/java/cup {
4679     inherit stdenv fetchurl jdk;
4680   };
4682   javasvn = import ../development/libraries/java/javasvn {
4683     inherit stdenv fetchurl unzip;
4684   };
4686   jclasslib = import ../development/tools/java/jclasslib {
4687     inherit fetchurl stdenv xpf jre;
4688     ant = apacheAnt14;
4689   };
4691   jdom = import ../development/libraries/java/jdom {
4692     inherit stdenv fetchurl;
4693   };
4695   jflex = import ../development/libraries/java/jflex {
4696     inherit stdenv fetchurl;
4697   };
4699   jjtraveler = import ../development/libraries/java/jjtraveler {
4700     inherit fetchurl jdk;
4701     stdenv = overrideInStdenv stdenv [gnumake380];
4702   };
4704   junit = import ../development/libraries/java/junit {
4705     inherit stdenv fetchurl unzip;
4706   };
4708   lucene = import ../development/libraries/java/lucene {
4709     inherit stdenv fetchurl;
4710   };
4712   mockobjects = import ../development/libraries/java/mockobjects {
4713     inherit stdenv fetchurl;
4714   };
4716   saxon = import ../development/libraries/java/saxon {
4717     inherit fetchurl stdenv unzip;
4718   };
4720   saxonb = import ../development/libraries/java/saxon/default8.nix {
4721     inherit fetchurl stdenv unzip jre;
4722   };
4724   sharedobjects = import ../development/libraries/java/shared-objects {
4725     inherit fetchurl jdk;
4726     stdenv = overrideInStdenv stdenv [gnumake380];
4727   };
4729   smack = import ../development/libraries/java/smack {
4730     inherit stdenv fetchurl;
4731   };
4733   swt = import ../development/libraries/java/swt {
4734     inherit stdenv fetchurl unzip jdk pkgconfig;
4735     inherit (gtkLibs) gtk;
4736     inherit (xlibs) libXtst;
4737   };
4739   xalanj = xalanJava;
4740   xalanJava = import ../development/libraries/java/xalanj {
4741     inherit fetchurl stdenv;
4742     ant    = apacheAntGcj;  # for bootstrap purposes
4743     javac  = gcj;
4744     jvm    = gcj;
4745     xerces = xercesJava;
4746   };
4748   zziplib = import ../development/libraries/zziplib {
4749     inherit fetchurl stdenv perl python zip xmlto zlib;
4750   };
4753   ### DEVELOPMENT / PERL MODULES
4755   buildPerlPackage = import ../development/perl-modules/generic perl;
4757   perlPackages = recurseIntoAttrs (import ./perl-packages.nix {
4758     inherit pkgs;
4759   });
4761   perlXMLParser = perlPackages.XMLParser;
4764   ### DEVELOPMENT / PYTHON MODULES
4766   buildPythonPackage =
4767     import ../development/python-modules/generic {
4768       inherit python setuptools makeWrapper lib;
4769     };
4771   pythonPackages = recurseIntoAttrs (import ./python-packages.nix {
4772     inherit pkgs;
4773   });
4775   foursuite = import ../development/python-modules/4suite {
4776     inherit fetchurl stdenv python;
4777   };
4779   bsddb3 = import ../development/python-modules/bsddb3 {
4780     inherit fetchurl stdenv python db4;
4781   };
4783   flup = builderDefsPackage ../development/python-modules/flup {
4784     inherit fetchurl stdenv;
4785     python = python25;
4786     setuptools = setuptools.passthru.function {python = python25;};
4787   };
4789   numeric = import ../development/python-modules/numeric {
4790     inherit fetchurl stdenv python;
4791   };
4793   pil = import ../development/python-modules/pil {
4794     inherit fetchurl stdenv python zlib libjpeg freetype;
4795   };
4797   psyco = import ../development/python-modules/psyco {
4798       inherit fetchurl stdenv python;
4799     };
4801   pycairo = import ../development/python-modules/pycairo {
4802     inherit fetchurl stdenv python pkgconfig cairo x11;
4803   };
4805   pycrypto = import ../development/python-modules/pycrypto {
4806     inherit fetchurl stdenv python gmp;
4807   };
4809   pycups = import ../development/python-modules/pycups {
4810     inherit stdenv fetchurl python cups;
4811   };
4813   pygame = import ../development/python-modules/pygame {
4814     inherit fetchurl stdenv python pkgconfig SDL SDL_image
4815       SDL_mixer SDL_ttf numeric;
4816   };
4818   pygobject = import ../development/python-modules/pygobject {
4819     inherit fetchurl stdenv python pkgconfig glib;
4820   };
4822   pygtk = import ../development/python-modules/pygtk {
4823     inherit fetchurl stdenv python pkgconfig pygobject pycairo;
4824     inherit (gtkLibs) glib gtk;
4825   };
4827   pyGtkGlade = import ../development/python-modules/pygtk {
4828     inherit fetchurl stdenv python pkgconfig pygobject pycairo;
4829     inherit (gtkLibs) glib gtk;
4830     inherit (gnome) libglade;
4831   };
4833   pyopengl = import ../development/python-modules/pyopengl {
4834     inherit fetchurl stdenv setuptools mesa freeglut pil python;
4835   };
4837   pyopenssl = builderDefsPackage (import ../development/python-modules/pyopenssl) {
4838     inherit python openssl;
4839   };
4841   pythonSip = builderDefsPackage (import ../development/python-modules/python-sip/4.7.4.nix) {
4842     inherit python;
4843   };
4845   rhpl = import ../development/python-modules/rhpl {
4846     inherit stdenv fetchurl rpm cpio python wirelesstools gettext;
4847   };
4849   sip = import ../development/python-modules/python-sip {
4850     inherit stdenv fetchurl lib python;
4851   };
4853   pyqt = builderDefsPackage (import ../development/python-modules/pyqt/4.3.3.nix) {
4854     inherit pkgconfig python pythonSip glib;
4855     inherit (xlibs) libX11 libXext;
4856     qt = qt4;
4857   };
4859   pyqt4 = import ../development/python-modules/pyqt {
4860     inherit stdenv fetchurl lib python sip;
4861     qt4 = qt45;
4862   };
4864   pyx = import ../development/python-modules/pyx {
4865     inherit fetchurl stdenv python makeWrapper;
4866   };
4868   pyxml = import ../development/python-modules/pyxml {
4869     inherit fetchurl stdenv python makeWrapper;
4870   };
4872   setuptools = builderDefsPackage (import ../development/python-modules/setuptools) {
4873     inherit python makeWrapper;
4874   };
4876   wxPython = wxPython26;
4878   wxPython26 = import ../development/python-modules/wxPython/2.6.nix {
4879     inherit fetchurl stdenv pkgconfig python;
4880     wxGTK = wxGTK26;
4881   };
4883   wxPython28 = import ../development/python-modules/wxPython/2.8.nix {
4884     inherit fetchurl stdenv pkgconfig python;
4885     inherit wxGTK;
4886   };
4888   twisted = pythonPackages.twisted;
4890   ZopeInterface = import ../development/python-modules/ZopeInterface {
4891     inherit fetchurl stdenv python;
4892   };
4894   zope = import ../development/python-modules/zope {
4895     inherit fetchurl stdenv;
4896     python = python24;
4897   };
4899   ### SERVERS
4902   apacheHttpd = makeOverridable (import ../servers/http/apache-httpd) {
4903     inherit (pkgsOverriden) fetchurl stdenv perl openssl zlib apr aprutil pcre;
4904     sslSupport = true;
4905   };
4907   sabnzbd = import ../servers/sabnzbd {
4908     inherit fetchurl stdenv python cheetahTemplate makeWrapper par2cmdline unzip unrar;
4909   };
4911   bind = builderDefsPackage (import ../servers/dns/bind/9.5.0.nix) {
4912     inherit openssl libtool;
4913   };
4915   dico = import ../servers/dico {
4916     inherit fetchurl stdenv libtool gettext zlib readline guile python;
4917   };
4919   dict = composedArgsAndFun (import ../servers/dict/1.9.15.nix) {
4920     inherit builderDefs which bison;
4921     flex=flex2534;
4922   };
4924   dictdDBs = recurseIntoAttrs (import ../servers/dict/dictd-db.nix {
4925     inherit builderDefs;
4926   });
4928   dictDBCollector = import ../servers/dict/dictd-db-collector.nix {
4929     inherit stdenv lib dict;
4930   };
4932   dovecot = import ../servers/mail/dovecot {
4933     inherit fetchurl stdenv openssl pam;
4934   };
4935   dovecot_1_1_1 = import ../servers/mail/dovecot/1.1.1.nix {
4936     inherit fetchurl stdenv openssl pam;
4937   };
4939   ejabberd = import ../servers/xmpp/ejabberd {
4940     inherit fetchurl stdenv expat erlang zlib openssl pam lib;
4941   };
4943   couchdb = import ../servers/http/couchdb {
4944     inherit fetchurl stdenv erlang spidermonkey icu getopt
4945       curl;
4946   };
4948   fingerd_bsd = import ../servers/fingerd/bsd-fingerd {
4949     inherit fetchurl stdenv;
4950   };
4952   ircdHybrid = import ../servers/irc/ircd-hybrid {
4953     inherit fetchurl stdenv openssl zlib;
4954   };
4956   jboss = import ../servers/http/jboss {
4957     inherit fetchurl stdenv unzip jdk lib;
4958   };
4960   jboss_mysql_jdbc = import ../servers/http/jboss/jdbc/mysql {
4961     inherit stdenv jboss mysql_jdbc;
4962   };
4964   jetty = import ../servers/http/jetty {
4965     inherit fetchurl stdenv unzip;
4966   };
4968   jetty61 = import ../servers/http/jetty/6.1 {
4969     inherit fetchurl stdenv unzip;
4970   };
4972   lighttpd = import ../servers/http/lighttpd {
4973     inherit fetchurl stdenv pcre libxml2 zlib attr bzip2;
4974   };
4976   mod_python = makeOverridable (import ../servers/http/apache-modules/mod_python) {
4977     inherit (pkgsOverriden) fetchurl stdenv apacheHttpd python;
4978   };
4980   myserver = import ../servers/http/myserver {
4981     inherit fetchurl stdenv libgcrypt libevent libidn gnutls libxml2
4982       zlib texinfo cppunit;
4983   };
4985   nginx = builderDefsPackage (import ../servers/http/nginx) {
4986     inherit openssl pcre zlib libxml2 libxslt;
4987   };
4989   postfix = import ../servers/mail/postfix {
4990     inherit fetchurl stdenv db4 openssl cyrus_sasl glibc;
4991   };
4993   pulseaudio = makeOverridable (import ../servers/pulseaudio) {
4994     inherit fetchurl stdenv pkgconfig gnum4 gdbm
4995       dbus hal avahi liboil libsamplerate libsndfile speex
4996       intltool gettext glib;
4997     inherit (xlibs) libX11 libICE libSM;
4998     inherit alsaLib;    # Needs ALSA >= 1.0.17.
4999     gconf = gnome.GConf;
5001     # Work around Libtool 1.5 interaction with Ltdl 2.x
5002     # ("undefined reference to lt__PROGRAM__LTX_preloaded_symbols").
5003     libtool = libtool_1_5;
5004   };
5006   tomcat_connectors = import ../servers/http/apache-modules/tomcat-connectors {
5007     inherit fetchurl stdenv apacheHttpd jdk;
5008   };
5010   portmap = makeOverridable (import ../servers/portmap) {
5011     inherit fetchurl stdenv lib tcpWrapper;
5012   };
5014   monetdb = import ../servers/sql/monetdb {
5015     inherit composableDerivation getConfig;
5016     inherit fetchurl stdenv pcre openssl readline libxml2 geos apacheAnt jdk5;
5017   };
5019   mysql4 = import ../servers/sql/mysql {
5020     inherit fetchurl stdenv ncurses zlib perl;
5021     ps = procps; /* !!! Linux only */
5022   };
5024   mysql5 = import ../servers/sql/mysql5 {
5025     inherit fetchurl stdenv ncurses zlib perl openssl;
5026     ps = procps; /* !!! Linux only */
5027   };
5029   mysql = mysql5;
5031   mysql_jdbc = import ../servers/sql/mysql/jdbc {
5032     inherit fetchurl stdenv ant;
5033   };
5035   nagios = import ../servers/monitoring/nagios {
5036     inherit fetchurl stdenv perl gd libpng zlib;
5037     gdSupport = true;
5038   };
5040   nagiosPluginsOfficial = import ../servers/monitoring/nagios/plugins/official {
5041     inherit fetchurl stdenv openssh;
5042   };
5044   openfire = composedArgsAndFun (import ../servers/xmpp/openfire) {
5045     inherit builderDefs jre;
5046   };
5048   postgresql = postgresql83;
5050   postgresql83 = import ../servers/sql/postgresql/8.3.x.nix {
5051     inherit fetchurl stdenv readline ncurses zlib;
5052   };
5054   postgresql84 = import ../servers/sql/postgresql/8.4.x.nix {
5055     inherit fetchurl stdenv readline ncurses zlib;
5056   };
5058   postgresql_jdbc = import ../servers/sql/postgresql/jdbc {
5059     inherit fetchurl stdenv ant;
5060   };
5062   pyIRCt = builderDefsPackage (import ../servers/xmpp/pyIRCt) {
5063     inherit xmpppy pythonIRClib python makeWrapper;
5064   };
5066   pyMAILt = builderDefsPackage (import ../servers/xmpp/pyMAILt) {
5067     inherit xmpppy python makeWrapper fetchcvs;
5068   };
5070   samba = makeOverridable (import ../servers/samba) {
5071     inherit stdenv fetchurl readline openldap pam kerberos popt iniparser
5072   libunwind acl fam;
5073   };
5075   squids = recurseIntoAttrs( import ../servers/squid/squids.nix {
5076     inherit fetchurl stdenv perl lib composableDerivation;
5077   });
5078   squid = squids.squid3Beta; # has ipv6 support
5080   tomcat5 = import ../servers/http/tomcat {
5081     inherit fetchurl stdenv jdk;
5082   };
5084   tomcat6 = import ../servers/http/tomcat/6.0.nix {
5085     inherit fetchurl stdenv jdk;
5086   };
5088   tomcat_mysql_jdbc = import ../servers/http/tomcat/jdbc/mysql {
5089     inherit stdenv tomcat6 mysql_jdbc;
5090   };
5092   axis2 = import ../servers/http/tomcat/axis2 {
5093     inherit fetchurl stdenv jdk apacheAnt unzip;
5094   };
5096   vsftpd = import ../servers/ftp/vsftpd {
5097     inherit fetchurl openssl stdenv libcap pam;
5098   };
5100   xinetd = import ../servers/xinetd {
5101     inherit fetchurl stdenv;
5102   };
5104   xorg = recurseIntoAttrs (import ../servers/x11/xorg/default.nix {
5105     inherit fetchurl fetchsvn stdenv pkgconfig freetype fontconfig
5106       libxslt expat libdrm libpng zlib perl mesa mesaHeaders
5107       xkeyboard_config dbus hal libuuid openssl gperf m4
5108       automake autoconf libtool;
5110     # !!! pythonBase is use instead of python because this cause an infinite
5111     # !!! recursion when the flag python.full is set to true.  Packages
5112     # !!! contained in the loop are python, tk, xlibs-wrapper, libX11,
5113     # !!! libxcd (and xcb-proto).
5114     python =  pythonBase;
5115   });
5117   xorgReplacements = composedArgsAndFun (import ../servers/x11/xorg/replacements.nix) {
5118     inherit fetchurl stdenv automake autoconf libtool xorg composedArgsAndFun;
5119   };
5121   xorgVideoUnichrome = import ../servers/x11/xorg/unichrome/default.nix {
5122     inherit stdenv fetchgit pkgconfig libdrm mesa automake autoconf libtool;
5123     inherit (xorg) fontsproto libpciaccess randrproto renderproto videoproto
5124       libX11 xextproto xf86driproto xorgserver xproto libXvMC glproto
5125       libXext utilmacros;
5126   };
5128   zabbixAgent = import ../servers/monitoring/zabbix {
5129     inherit fetchurl stdenv;
5130     enableServer = false;
5131   };
5133   zabbixServer = import ../servers/monitoring/zabbix {
5134     inherit fetchurl stdenv postgresql curl;
5135     enableServer = true;
5136   };
5139   ### OS-SPECIFIC
5141   autofs5 = import ../os-specific/linux/autofs/autofs-v5.nix {
5142     inherit bleedingEdgeRepos fetchurl stdenv flex bison kernelHeaders;
5143   };
5145   _915resolution = import ../os-specific/linux/915resolution {
5146     inherit fetchurl stdenv;
5147   };
5149   nfsUtils = import ../os-specific/linux/nfs-utils {
5150     inherit fetchurl stdenv tcpWrapper libuuid;
5151   };
5153   acpi = import ../os-specific/linux/acpi {
5154     inherit fetchurl stdenv;
5155   };
5157   acpid = import ../os-specific/linux/acpid {
5158     inherit fetchurl stdenv;
5159   };
5161   acpitool = import ../os-specific/linux/acpitool {
5162     inherit fetchurl stdenv;
5163   };
5165   alsaLib = import ../os-specific/linux/alsa-lib {
5166     inherit stdenv fetchurl;
5167   };
5169   alsaPlugins = import ../os-specific/linux/alsa-plugins {
5170     inherit fetchurl stdenv lib pkgconfig alsaLib pulseaudio jackaudio;
5171   };
5172   alsaPluginWrapper = import ../os-specific/linux/alsa-plugins/wrapper.nix {
5173     inherit stdenv alsaPlugins writeScriptBin;
5174   };
5176   alsaUtils = import ../os-specific/linux/alsa-utils {
5177     inherit stdenv fetchurl alsaLib gettext ncurses;
5178   };
5180   bluez = import ../os-specific/linux/bluez {
5181     inherit fetchurl stdenv pkgconfig dbus libusb alsaLib glib;
5182   };
5184   bridge_utils = import ../os-specific/linux/bridge_utils {
5185     inherit fetchurl stdenv autoconf automake;
5186   };
5188   cpufrequtils = (
5189     import ../os-specific/linux/cpufrequtils {
5190     inherit fetchurl stdenv libtool gettext;
5191     glibc = stdenv.gcc.libc;
5192     kernelHeaders = stdenv.gcc.libc.kernelHeaders;
5193   });
5195   cryopid = import ../os-specific/linux/cryopid {
5196     inherit fetchurl stdenv zlibStatic;
5197   };
5199   cryptsetup = import ../os-specific/linux/cryptsetup {
5200     inherit stdenv fetchurl libuuid popt devicemapper udev;
5201   };
5203   cramfsswap = import ../os-specific/linux/cramfsswap {
5204     inherit fetchurl stdenv zlib;
5205   };
5207   darwinArchUtility = import ../os-specific/darwin/arch {
5208     inherit stdenv;
5209   };
5211   darwinSwVersUtility = import ../os-specific/darwin/sw_vers {
5212     inherit stdenv;
5213   };
5215   devicemapper = import ../os-specific/linux/device-mapper {
5216     inherit fetchurl stdenv;
5217   };
5219   dmidecode = import ../os-specific/linux/dmidecode {
5220     inherit fetchurl stdenv;
5221   };
5223   dietlibc = import ../os-specific/linux/dietlibc {
5224     inherit fetchurl glibc;
5225     # Dietlibc 0.30 doesn't compile on PPC with GCC 4.1, bus GCC 3.4 works.
5226     stdenv = if stdenv.system == "powerpc-linux" then overrideGCC stdenv gcc34 else stdenv;
5227   };
5229   directvnc = builderDefsPackage ../os-specific/linux/directvnc {
5230     inherit libjpeg pkgconfig zlib directfb;
5231     inherit (xlibs) xproto;
5232   };
5234   dmraid = builderDefsPackage ../os-specific/linux/dmraid {
5235     inherit devicemapper;
5236   };
5238   libuuid = if ! stdenv.isDarwin then utillinuxng else null;
5240   e3cfsprogs = import ../os-specific/linux/e3cfsprogs {
5241     inherit stdenv fetchurl gettext;
5242   };
5244   eject = import ../os-specific/linux/eject {
5245     inherit fetchurl stdenv gettext;
5246   };
5248   fbterm = builderDefsPackage (import ../os-specific/linux/fbterm) {
5249     inherit fontconfig gpm freetype pkgconfig ncurses;
5250   };
5252   fuse = import ../os-specific/linux/fuse {
5253     inherit fetchurl stdenv utillinux;
5254   };
5256   fxload = import ../os-specific/linux/fxload {
5257     inherit fetchurl stdenv;
5258   };
5260   gpm = import ../servers/gpm {
5261     inherit fetchurl stdenv ncurses bison;
5262     flex = flex2535;
5263   };
5265   hal = makeOverridable (import ../os-specific/linux/hal) {
5266     inherit fetchurl stdenv pkgconfig python pciutils usbutils expat
5267       libusb dbus dbus_glib libuuid perl perlXMLParser
5268       gettext zlib eject libsmbios udev gperf dmidecode utillinuxng
5269       consolekit policykit pmutils glib;
5270   };
5272   halevt = import ../os-specific/linux/hal/hal-evt.nix {
5273     inherit fetchurl stdenv lib libxml2 pkgconfig boolstuff hal dbus_glib;
5274   };
5276   hal_info = import ../os-specific/linux/hal/info.nix {
5277     inherit fetchurl stdenv pkgconfig;
5278   };
5280   hal_info_synaptics = import ../os-specific/linux/hal/synaptics.nix {
5281     inherit stdenv;
5282   };
5284   hdparm = import ../os-specific/linux/hdparm {
5285     inherit fetchurl stdenv;
5286   };
5288   hibernate = import ../os-specific/linux/hibernate {
5289     inherit fetchurl stdenv gawk;
5290   };
5292   htop = import ../os-specific/linux/htop {
5293     inherit fetchurl stdenv ncurses;
5294   };
5296   hwdata = import ../os-specific/linux/hwdata {
5297     inherit fetchurl stdenv;
5298   };
5300   ifplugd = import ../os-specific/linux/ifplugd {
5301     inherit fetchurl stdenv pkgconfig libdaemon;
5302   };
5304   iproute = import ../os-specific/linux/iproute {
5305     inherit fetchurl stdenv flex bison db4;
5306   };
5308   iputils = (
5309     import ../os-specific/linux/iputils {
5310     inherit fetchurl stdenv;
5311     glibc = stdenv.gcc.libc;
5312     kernelHeaders = stdenv.gcc.libc.kernelHeaders;
5313   });
5315   iptables = import ../os-specific/linux/iptables {
5316     inherit fetchurl stdenv;
5317   };
5319   ipw2200fw = import ../os-specific/linux/firmware/ipw2200 {
5320     inherit fetchurl stdenv;
5321   };
5323   iwlwifi3945ucode = import ../os-specific/linux/firmware/iwlwifi-3945-ucode {
5324     inherit fetchurl stdenv;
5325   };
5327   iwlwifi4965ucodeV1 = import ../os-specific/linux/firmware/iwlwifi-4965-ucode {
5328     inherit fetchurl stdenv;
5329   };
5331   iwlwifi4965ucodeV2 = import ../os-specific/linux/firmware/iwlwifi-4965-ucode/version-2.nix {
5332     inherit fetchurl stdenv;
5333   };
5335   iwlwifi5000ucode = import ../os-specific/linux/firmware/iwlwifi-5000-ucode {
5336     inherit fetchurl stdenv;
5337   };
5339   kbd = import ../os-specific/linux/kbd {
5340     inherit fetchurl stdenv bison flex;
5341   };
5343   kernelHeaders = kernelHeaders_2_6_28;
5345   kernelHeaders_2_6_18 = import ../os-specific/linux/kernel-headers/2.6.18.5.nix {
5346     inherit fetchurl stdenv unifdef;
5347   };
5349   kernelHeaders_2_6_23 = import ../os-specific/linux/kernel-headers/2.6.23.16.nix {
5350     inherit fetchurl stdenv;
5351   };
5353   kernelHeaders_2_6_26 = import ../os-specific/linux/kernel-headers/2.6.26.2.nix {
5354     inherit fetchurl stdenv;
5355   };
5357   kernelHeaders_2_6_27 = import ../os-specific/linux/kernel-headers/2.6.27.8.nix {
5358     inherit fetchurl stdenv;
5359   };
5361   kernelHeaders_2_6_28 = import ../os-specific/linux/kernel-headers/2.6.28.nix {
5362     inherit fetchurl stdenv perl;
5363   };
5365   kernelHeadersArm = import ../os-specific/linux/kernel-headers-cross {
5366     inherit fetchurl stdenv;
5367     cross = "arm-linux";
5368   };
5370   kernelHeadersMips = import ../os-specific/linux/kernel-headers-cross {
5371     inherit fetchurl stdenv;
5372     cross = "mips-linux";
5373   };
5375   kernelHeadersSparc = import ../os-specific/linux/kernel-headers-cross {
5376     inherit fetchurl stdenv;
5377     cross = "sparc-linux";
5378   };
5380   kernel_2_6_25 = import ../os-specific/linux/kernel/linux-2.6.25.nix {
5381     inherit fetchurl stdenv perl mktemp module_init_tools;
5382     kernelPatches = [
5383       { name = "fbcondecor-0.9.4-2.6.25-rc6";
5384         patch = fetchurl {
5385           url = http://dev.gentoo.org/~spock/projects/fbcondecor/archive/fbcondecor-0.9.4-2.6.25-rc6.patch;
5386           sha256 = "1wm94n7f0qyb8xvafip15r158z5pzw7zb7q8hrgddb092c6ibmq8";
5387         };
5388         extraConfig = "CONFIG_FB_CON_DECOR=y";
5389         features = { fbConDecor = true; };
5390       }
5391       { name = "sec_perm-2.6.24";
5392         patch = ../os-specific/linux/kernel/sec_perm-2.6.24.patch;
5393         features = { secPermPatch = true; };
5394       }
5395     ];
5396     extraConfig =
5397       lib.optional (getConfig ["kernel" "timer_stats"] false) "CONFIG_TIMER_STATS=y" ++
5398       lib.optional (getConfig ["kernel" "no_irqbalance"] false) "# CONFIG_IRQBALANCE is not set" ++
5399       [(getConfig ["kernel" "addConfig"] "")];
5400   };
5402   kernel_2_6_26 = import ../os-specific/linux/kernel/linux-2.6.26.nix {
5403     inherit fetchurl stdenv perl mktemp module_init_tools;
5404     kernelPatches = [
5405       { name = "fbcondecor-0.9.4-2.6.25-rc6";
5406         patch = fetchurl {
5407           url = http://dev.gentoo.org/~spock/projects/fbcondecor/archive/fbcondecor-0.9.4-2.6.25-rc6.patch;
5408           sha256 = "1wm94n7f0qyb8xvafip15r158z5pzw7zb7q8hrgddb092c6ibmq8";
5409         };
5410         extraConfig = "CONFIG_FB_CON_DECOR=y";
5411         features = { fbConDecor = true; };
5412       }
5413       { name = "sec_perm-2.6.24";
5414         patch = ../os-specific/linux/kernel/sec_perm-2.6.24.patch;
5415         features = { secPermPatch = true; };
5416       }
5417     ];
5418     extraConfig =
5419       lib.optional (getConfig ["kernel" "no_irqbalance"] false) "# CONFIG_IRQBALANCE is not set" ++
5420       [(getConfig ["kernel" "addConfig"] "")];
5421   };
5423   kernel_2_6_27 = import ../os-specific/linux/kernel/linux-2.6.27.nix {
5424     inherit fetchurl stdenv perl mktemp module_init_tools;
5425     kernelPatches = [
5426       { name = "fbcondecor-0.9.4-2.6.27";
5427         patch = fetchurl {
5428           url = http://dev.gentoo.org/~spock/projects/fbcondecor/archive/fbcondecor-0.9.4-2.6.27.patch;
5429           sha256 = "170l9l5fvbgjrr4klqcwbgjg4kwvrrhjpmgbfpqj0scq0s4q4vk6";
5430         };
5431         extraConfig = "CONFIG_FB_CON_DECOR=y";
5432         features = { fbConDecor = true; };
5433       }
5434       { name = "sec_perm-2.6.24";
5435         patch = ../os-specific/linux/kernel/sec_perm-2.6.24.patch;
5436         features = { secPermPatch = true; };
5437       }
5438     ];
5439     extraConfig =
5440       lib.optional (getConfig ["kernel" "no_irqbalance"] false) "# CONFIG_IRQBALANCE is not set" ++
5441       [(getConfig ["kernel" "addConfig"] "")];
5442   };
5444   kernel_2_6_28 = makeOverridable (import ../os-specific/linux/kernel/linux-2.6.28.nix) {
5445     inherit fetchurl stdenv perl mktemp module_init_tools;
5446     kernelPatches = [
5447       { name = "fbcondecor-0.9.5-2.6.28";
5448         patch = fetchurl {
5449           url = http://dev.gentoo.org/~spock/projects/fbcondecor/archive/fbcondecor-0.9.5-2.6.28.patch;
5450           sha256 = "105q2dwrwi863r7nhlrvljim37aqv67mjc3lgg529jzqgny3fjds";
5451         };
5452         extraConfig = "CONFIG_FB_CON_DECOR=y";
5453         features = { fbConDecor = true; };
5454       }
5455       { name = "sec_perm-2.6.24";
5456         patch = ../os-specific/linux/kernel/sec_perm-2.6.24.patch;
5457         features = { secPermPatch = true; };
5458       }
5459       { # http://patchwork.kernel.org/patch/19495/
5460         name = "ext4-softlockups-fix";
5461         patch = fetchurl {
5462           url = http://patchwork.kernel.org/patch/19495/raw;
5463           sha256 = "0vqcj9qs7jajlvmwm97z8cljr4vb277aqhsjqrakbxfdiwlhrzzf";
5464         };
5465       }
5466     ];
5467     extraConfig =
5468       lib.optional (getConfig ["kernel" "no_irqbalance"] false) "# CONFIG_IRQBALANCE is not set" ++
5469       [(getConfig ["kernel" "addConfig"] "")];
5470   };
5472   kernel_2_6_29 = makeOverridable (import ../os-specific/linux/kernel/linux-2.6.29.nix) {
5473     inherit fetchurl stdenv perl mktemp module_init_tools;
5474     kernelPatches = [
5475       { name = "fbcondecor-0.9.5-2.6.28";
5476         patch = fetchurl {
5477           url = http://dev.gentoo.org/~spock/projects/fbcondecor/archive/fbcondecor-0.9.6-2.6.29.2.patch;
5478           sha256 = "1yppvji13sgnql62h4wmskzl9l198pp1pbixpbymji7mr4a0ylx1";
5479         };
5480         extraConfig = "CONFIG_FB_CON_DECOR=y";
5481         features = { fbConDecor = true; };
5482       }
5483       { name = "sec_perm-2.6.24";
5484         patch = ../os-specific/linux/kernel/sec_perm-2.6.24.patch;
5485         features = { secPermPatch = true; };
5486       }
5487     ];
5488   };
5490   kernel_2_6_31 = makeOverridable (import ../os-specific/linux/kernel/linux-2.6.31.nix) {
5491     inherit fetchurl stdenv perl mktemp module_init_tools;
5492     kernelPatches = [];
5493   };
5495   kernel_2_6_31_zen5 = makeOverridable (import ../os-specific/linux/zen-kernel/2.6.31-zen5.nix) {
5496     inherit fetchurl stdenv perl mktemp module_init_tools
5497       lib builderDefs;
5498   };
5500   kernel_2_6_31_zen5_bfs = kernel_2_6_31_zen5.override {
5501     ckSched = true;
5502   };
5504   kernel_2_6_31_zen7 = makeOverridable (import ../os-specific/linux/zen-kernel/zen-stable.nix) {
5505     inherit fetchurl stdenv perl mktemp module_init_tools
5506       lib builderDefs;
5507   };
5509   kernel_2_6_31_zen7_bfs = kernel_2_6_31_zen7.override {
5510     ckSched = true;
5511   };
5513   kernel_2_6_31_zen = kernel_2_6_31_zen7;
5514   kernel_2_6_31_zen_bfs = kernel_2_6_31_zen7_bfs;
5516   /* Kernel modules are inherently tied to a specific kernel.  So
5517      rather than provide specific instances of those packages for a
5518      specific kernel, we have a function that builds those packages
5519      for a specific kernel.  This function can then be called for
5520      whatever kernel you're using. */
5522   kernelPackagesFor = kernel: rec {
5524     inherit kernel;
5526     aufs = import ../os-specific/linux/aufs {
5527       inherit fetchurl stdenv kernel;
5528     };
5530     # Currently it is broken
5531     # Build requires exporting some symbols from kernel
5532     # Go to package homepage to learn about the needed
5533     # patch. Feel free to take over the package.
5534     aufs2 = import ../os-specific/linux/aufs2 {
5535       inherit fetchgit stdenv kernel perl;
5536     };
5538     aufs2Utils = if lib.attrByPath ["features" "aufs"] false kernel then
5539       builderDefsPackage ../os-specific/linux/aufs2-utils {
5540         inherit kernel;
5541       }
5542     else null;
5544     exmap = import ../os-specific/linux/exmap {
5545       inherit fetchurl stdenv kernel boost pcre pkgconfig;
5546       inherit (gtkLibs) gtkmm;
5547     };
5549     iwlwifi = import ../os-specific/linux/iwlwifi {
5550       inherit fetchurl stdenv kernel;
5551     };
5553     iwlwifi4965ucode =
5554       (if (builtins.compareVersions kernel.version "2.6.27" == 0)
5555           || (builtins.compareVersions kernel.version "2.6.27" == 1)
5556        then iwlwifi4965ucodeV2
5557        else iwlwifi4965ucodeV1);
5559     atheros = composedArgsAndFun (import ../os-specific/linux/atheros/0.9.4.nix) {
5560       inherit fetchurl stdenv builderDefs kernel lib;
5561     };
5563     nvidia_x11 = import ../os-specific/linux/nvidia-x11 {
5564       inherit stdenv fetchurl kernel xlibs gtkLibs zlib;
5565     };
5567     nvidia_x11_legacy = import ../os-specific/linux/nvidia-x11/legacy.nix {
5568       inherit stdenv fetchurl kernel xlibs gtkLibs zlib;
5569     };
5571     wis_go7007 = import ../os-specific/linux/wis-go7007 {
5572       inherit fetchurl stdenv kernel ncurses fxload;
5573     };
5575     kqemu = builderDefsPackage ../os-specific/linux/kqemu/1.4.0pre1.nix {
5576       inherit kernel perl;
5577     };
5579     splashutils =
5580       # Splashutils 1.3 is broken, so disable splash on older kernels.
5581       if kernel.features ? fbSplash then /* splashutils_13 */ null else
5582       if kernel.features ? fbConDecor then splashutils_15 else
5583       null;
5585     ext3cowtools = import ../os-specific/linux/ext3cow-tools {
5586       inherit stdenv fetchurl;
5587       kernel_ext3cowpatched = kernel;
5588     };
5590     /* compiles but has to be integrated into the kernel somehow
5591       Let's have it uncommented and finish it..
5592     */
5593     ndiswrapper = import ../os-specific/linux/ndiswrapper {
5594       inherit fetchurl stdenv;
5595       inherit kernel perl;
5596     };
5598     ov511 = import ../os-specific/linux/ov511 {
5599       inherit fetchurl kernel;
5600       stdenv = overrideGCC stdenv gcc34;
5601     };
5603     # State Nix
5604     snix = import ../tools/package-management/snix {
5605       inherit fetchurl stdenv perl curl bzip2 openssl bison;
5606       inherit libtool automake autoconf docbook5 docbook5_xsl libxslt docbook_xml_dtd_43 w3m;
5608       aterm = aterm242fixes;
5609       db4 = db45;
5611       flex = flex2533;
5613       inherit ext3cowtools e3cfsprogs rsync;
5614       ext3cow_kernel = kernel;
5615     };
5617     sysprof = import ../development/tools/profiling/sysprof {
5618       inherit fetchurl stdenv binutils pkgconfig kernel;
5619       inherit (gnome) gtk glib pango libglade;
5620     };
5622     virtualbox = import ../applications/virtualization/virtualbox {
5623       stdenv = stdenv_32bit;
5624       inherit fetchurl lib iasl dev86 libxslt libxml2 SDL hal
5625           libcap libpng zlib kernel python which alsaLib curl glib;
5626       qt4 = qt45;
5627       inherit (xlibs) xproto libX11 libXext libXcursor;
5628       inherit (gnome) libIDL;
5629     };
5631     virtualboxGuestAdditions = import ../applications/virtualization/virtualbox/guest-additions {
5632       inherit stdenv fetchurl lib patchelf cdrkit kernel;
5633       inherit (xlibs) libX11 libXt libXext libXmu libXcomposite libXfixes;
5634     };
5635   };
5637   # Build the kernel modules for the some of the kernels.
5638   kernelPackages_2_6_25 = recurseIntoAttrs (kernelPackagesFor kernel_2_6_25);
5639   kernelPackages_2_6_26 = recurseIntoAttrs (kernelPackagesFor kernel_2_6_26);
5640   kernelPackages_2_6_27 = recurseIntoAttrs (kernelPackagesFor kernel_2_6_27);
5641   kernelPackages_2_6_28 = recurseIntoAttrs (kernelPackagesFor kernel_2_6_28);
5642   kernelPackages_2_6_29 = recurseIntoAttrs (kernelPackagesFor kernel_2_6_29);
5643   kernelPackages_2_6_31_zen5 = recurseIntoAttrs (kernelPackagesFor kernel_2_6_31_zen5);
5644   kernelPackages_2_6_31_zen = recurseIntoAttrs (kernelPackagesFor kernel_2_6_31_zen);
5645   kernelPackages_2_6_31_zen_bfs = recurseIntoAttrs (kernelPackagesFor kernel_2_6_31_zen_bfs);
5646   kernelPackages_2_6_31 = recurseIntoAttrs (kernelPackagesFor kernel_2_6_31);
5648   # The current default kernel / kernel modules.
5649   kernelPackages = kernelPackages_2_6_28;
5651   customKernel = composedArgsAndFun (lib.sumTwoArgs (import ../os-specific/linux/kernel/generic.nix) {
5652     inherit fetchurl stdenv perl mktemp module_init_tools;
5653   });
5655   libselinux = import ../os-specific/linux/libselinux {
5656     inherit fetchurl stdenv libsepol;
5657   };
5659   libraw1394 = import ../development/libraries/libraw1394 {
5660     inherit fetchurl stdenv;
5661   };
5663   libsexy = import ../development/libraries/libsexy {
5664     inherit stdenv fetchurl pkgconfig libxml2;
5665     inherit (gtkLibs) glib gtk pango;
5666   };
5668   librsvg = gnome.librsvg;
5670   libsepol = import ../os-specific/linux/libsepol {
5671     inherit fetchurl stdenv;
5672   };
5674   libsmbios = import ../os-specific/linux/libsmbios {
5675     inherit fetchurl stdenv pkgconfig libxml2 perl;
5676   };
5678   lm_sensors = import ../os-specific/linux/lm_sensors {
5679     inherit fetchurl stdenv bison flex perl;
5680   };
5682   klibc = makeOverridable (import ../os-specific/linux/klibc) {
5683     inherit fetchurl stdenv perl bison mktemp;
5684     kernelHeaders = glibc.kernelHeaders;
5685   };
5687   # Old version; needed in vmtools for insmod.  Should use
5688   # module_init_tools instead.
5689   klibc_15 = makeOverridable (import ../os-specific/linux/klibc/1.5.nix) {
5690     inherit fetchurl stdenv perl bison mktemp;
5691     kernelHeaders = glibc.kernelHeaders;
5692   };
5694   klibcShrunk = makeOverridable (import ../os-specific/linux/klibc/shrunk.nix) {
5695     inherit stdenv klibc;
5696   };
5698   kvm = kvm76;
5700   kvm76 = import ../os-specific/linux/kvm/76.nix {
5701     inherit fetchurl stdenv zlib e2fsprogs SDL alsaLib pkgconfig rsync;
5702     inherit (glibc) kernelHeaders;
5703   };
5705   kvm86 = import ../os-specific/linux/kvm/86.nix {
5706     inherit fetchurl stdenv zlib SDL alsaLib pkgconfig pciutils;
5707     inherit (glibc) kernelHeaders;
5708   };
5710   kvm88 = import ../os-specific/linux/kvm/88.nix {
5711     inherit fetchurl stdenv zlib SDL alsaLib pkgconfig pciutils;
5712     inherit (glibc) kernelHeaders;
5713   };
5715   libcap = import ../os-specific/linux/libcap {
5716     inherit fetchurl stdenv attr;
5717   };
5719   libnscd = import ../os-specific/linux/libnscd {
5720     inherit fetchurl stdenv;
5721   };
5723   libnotify = import ../development/libraries/libnotify {
5724     inherit stdenv fetchurl pkgconfig dbus dbus_glib;
5725     inherit (gtkLibs) gtk glib;
5726   };
5728   libvolume_id = import ../os-specific/linux/libvolume_id {
5729     inherit fetchurl stdenv;
5730   };
5732   lvm2 = import ../os-specific/linux/lvm2 {
5733     inherit fetchurl stdenv devicemapper;
5734   };
5736   mdadm = import ../os-specific/linux/mdadm {
5737     inherit fetchurl stdenv groff;
5738   };
5740   mingetty = import ../os-specific/linux/mingetty {
5741     inherit fetchurl stdenv;
5742   };
5744   module_init_tools = import ../os-specific/linux/module-init-tools {
5745     inherit fetchurl stdenv;
5746   };
5748   mount_cifs = import ../os-specific/linux/mount-cifs {
5749     inherit fetchurl stdenv;
5750   };
5752   aggregateModules = modules:
5753     import ../os-specific/linux/module-init-tools/aggregator.nix {
5754       inherit stdenv module_init_tools modules buildEnv;
5755     };
5757   modutils = import ../os-specific/linux/modutils {
5758     inherit fetchurl bison flex;
5759     stdenv = overrideGCC stdenv gcc34;
5760   };
5762   nettools = import ../os-specific/linux/net-tools {
5763     inherit fetchurl stdenv;
5764   };
5766   neverball = import ../games/neverball {
5767     inherit stdenv fetchurl SDL mesa libpng libjpeg SDL_ttf libvorbis
5768       gettext physfs;
5769   };
5771   numactl = import ../os-specific/linux/numactl {
5772     inherit fetchurl stdenv;
5773   };
5775   gw6c = builderDefsPackage (import ../os-specific/linux/gw6c) {
5776     inherit fetchurl stdenv nettools openssl procps iproute;
5777   };
5779   nss_ldap = import ../os-specific/linux/nss_ldap {
5780     inherit fetchurl stdenv openldap;
5781   };
5783   pam = import ../os-specific/linux/pam {
5784     inherit stdenv fetchurl cracklib flex;
5785   };
5787   pam_console = import ../os-specific/linux/pam_console {
5788     inherit stdenv fetchurl pam autoconf automake pkgconfig bison glib;
5789     libtool = libtool_1_5;
5790     flex = if stdenv.system == "i686-linux" then flex else flex2533;
5791   };
5793   pam_devperm = import ../os-specific/linux/pam_devperm {
5794     inherit stdenv fetchurl pam;
5795   };
5797   pam_ldap = import ../os-specific/linux/pam_ldap {
5798     inherit stdenv fetchurl pam openldap;
5799   };
5801   pam_login = import ../os-specific/linux/pam_login {
5802     inherit stdenv fetchurl pam;
5803   };
5805   pam_unix2 = import ../os-specific/linux/pam_unix2 {
5806     inherit stdenv fetchurl pam libxcrypt;
5807   };
5809   pcmciaUtils = composedArgsAndFun (import ../os-specific/linux/pcmciautils) {
5810     inherit stdenv fetchurl udev yacc flex;
5811     inherit sysfsutils module_init_tools;
5813     firmware = getConfig ["pcmciaUtils" "firmware"] [];
5814     config = getConfig ["pcmciaUtils" "config"] null;
5815     inherit lib;
5816   };
5818   pmutils = import ../os-specific/linux/pm-utils {
5819     inherit fetchurl stdenv;
5820   };
5822   powertop = import ../os-specific/linux/powertop {
5823     inherit fetchurl stdenv ncurses gettext;
5824   };
5826   procps = import ../os-specific/linux/procps {
5827     inherit fetchurl stdenv ncurses;
5828   };
5830   pwdutils = import ../os-specific/linux/pwdutils {
5831     inherit fetchurl stdenv pam openssl libnscd;
5832   };
5834   qemu_kvm = import ../os-specific/linux/qemu-kvm {
5835     inherit fetchurl stdenv zlib SDL alsaLib pkgconfig pciutils;
5836   };
5838   radeontools = import ../os-specific/linux/radeontools {
5839     inherit pciutils;
5840     inherit fetchurl stdenv;
5841   };
5843   rt73fw = import ../os-specific/linux/firmware/rt73 {
5844     inherit fetchurl stdenv unzip;
5845   };
5847   sdparm = import ../os-specific/linux/sdparm {
5848     inherit fetchurl stdenv;
5849   };
5851   shadowutils = import ../os-specific/linux/shadow {
5852     inherit fetchurl stdenv;
5853   };
5855   splashutils_13 = import ../os-specific/linux/splashutils/1.3.nix {
5856     inherit fetchurl stdenv klibc;
5857     zlib = zlibStatic;
5858     libjpeg = libjpegStatic;
5859   };
5861   splashutils_15 = import ../os-specific/linux/splashutils/1.5.nix {
5862     inherit fetchurl stdenv klibc;
5863     zlib = zlibStatic;
5864     libjpeg = libjpegStatic;
5865   };
5867   statifier = builderDefsPackage (import ../os-specific/linux/statifier) {
5868   };
5870   sysfsutils = import ../os-specific/linux/sysfsutils {
5871     inherit fetchurl stdenv;
5872   };
5874   # Provided with sysfsutils.
5875   libsysfs = sysfsutils;
5876   systool = sysfsutils;
5878   sysklogd = import ../os-specific/linux/sysklogd {
5879     inherit fetchurl stdenv;
5880   };
5882   syslinux = import ../os-specific/linux/syslinux {
5883     inherit fetchurl stdenv nasm perl;
5884   };
5886   sysstat = import ../os-specific/linux/sysstat {
5887     inherit fetchurl stdenv gettext;
5888   };
5890   sysvinit = import ../os-specific/linux/sysvinit {
5891     inherit fetchurl stdenv;
5892   };
5894   sysvtools = import ../os-specific/linux/sysvinit {
5895     inherit fetchurl stdenv;
5896     withoutInitTools = true;
5897   };
5899   # FIXME: `tcp-wrapper' is actually not OS-specific.
5900   tcpWrapper = import ../os-specific/linux/tcp-wrapper {
5901     inherit fetchurl stdenv;
5902   };
5904   trackballs = import ../games/trackballs {
5905     inherit stdenv fetchurl SDL mesa SDL_ttf gettext zlib SDL_mixer SDL_image guile;
5906     debug = false;
5907   };
5909   tunctl = import ../os-specific/linux/tunctl {
5910     inherit stdenv fetchurl;
5911   };
5913   /*tuxracer = builderDefsPackage (import ../games/tuxracer) {
5914     inherit mesa tcl freeglut;
5915     inherit (xlibs) libX11 xproto;
5916   };*/
5918   udev = makeOverridable (import ../os-specific/linux/udev) {
5919     inherit fetchurl stdenv gperf pkgconfig acl libusb usbutils pciutils glib;
5920   };
5922   uml = import ../os-specific/linux/kernel/linux-2.6.20.nix {
5923     inherit fetchurl stdenv perl mktemp module_init_tools;
5924     userModeLinux = true;
5925   };
5927   umlutilities = import ../os-specific/linux/uml-utilities {
5928     inherit fetchurl kernelHeaders stdenv readline lib;
5929     tunctl = true; mconsole = true;
5930   };
5932   upstart = import ../os-specific/linux/upstart {
5933     inherit fetchurl stdenv;
5934   };
5936   upstart06 = import ../os-specific/linux/upstart/0.6.nix {
5937     inherit fetchurl stdenv pkgconfig dbus expat;
5938   };
5940   upstartJobControl = import ../os-specific/linux/upstart/jobcontrol.nix {
5941     inherit stdenv;
5942   };
5944   usbutils = import ../os-specific/linux/usbutils {
5945     inherit fetchurl stdenv pkgconfig libusb;
5946   };
5948   utillinux = utillinuxng;
5950   utillinuxCurses = utillinuxngCurses;
5952   utillinuxng = makeOverridable (import ../os-specific/linux/util-linux-ng) {
5953     inherit fetchurl stdenv;
5954   };
5956   utillinuxngCurses = utillinuxng.override {
5957     inherit ncurses;
5958   };
5960   wesnoth = import ../games/wesnoth {
5961     inherit fetchurl stdenv SDL SDL_image SDL_mixer SDL_net gettext zlib boost freetype;
5962   };
5964   wirelesstools = import ../os-specific/linux/wireless-tools {
5965     inherit fetchurl stdenv;
5966   };
5968   wpa_supplicant = import ../os-specific/linux/wpa_supplicant {
5969     inherit fetchurl stdenv openssl;
5970   };
5972   wpa_supplicant_gui_qt4 = import ../os-specific/linux/wpa_supplicant/gui-qt4.nix {
5973     inherit fetchurl stdenv qt4 imagemagick inkscape;
5974   };
5976   xmoto = builderDefsPackage (import ../games/xmoto) {
5977     inherit chipmunk sqlite curl zlib bzip2 libjpeg libpng
5978       freeglut mesa SDL SDL_mixer SDL_image SDL_net SDL_ttf
5979       lua5 ode;
5980   };
5982   xorg_sys_opengl = import ../os-specific/linux/opengl/xorg-sys {
5983     inherit stdenv xlibs expat libdrm;
5984   };
5986   zd1211fw = import ../os-specific/linux/firmware/zd1211 {
5987     inherit stdenv fetchurl;
5988   };
5990   ### DATA
5992   arkpandora_ttf = builderDefsPackage (import ../data/fonts/arkpandora) {
5993   };
5995   bakoma_ttf = import ../data/fonts/bakoma-ttf {
5996     inherit fetchurl stdenv;
5997   };
5999   corefonts = import ../data/fonts/corefonts {
6000     inherit fetchurl stdenv cabextract;
6001   };
6003   wrapFonts = paths : ((import ../data/fonts/fontWrap) {
6004     inherit fetchurl stdenv builderDefs paths ttmkfdir;
6005     inherit (xorg) mkfontdir mkfontscale;
6006   });
6008   clearlyU = composedArgsAndFun (import ../data/fonts/clearlyU/1.9.nix) {
6009     inherit builderDefs;
6010     inherit (xorg) mkfontdir mkfontscale;
6011   };
6013   dejavu_fonts = import ../data/fonts/dejavu-fonts {
6014     inherit fetchurl stdenv fontforge perl fontconfig;
6015     inherit (perlPackages) FontTTF;
6016   };
6018   docbook5 = import ../data/sgml+xml/schemas/docbook-5.0 {
6019     inherit fetchurl stdenv unzip;
6020   };
6022   docbook_xml_dtd_412 = import ../data/sgml+xml/schemas/xml-dtd/docbook/4.1.2.nix {
6023     inherit fetchurl stdenv unzip;
6024   };
6026   docbook_xml_dtd_42 = import ../data/sgml+xml/schemas/xml-dtd/docbook/4.2.nix {
6027     inherit fetchurl stdenv unzip;
6028   };
6030   docbook_xml_dtd_43 = import ../data/sgml+xml/schemas/xml-dtd/docbook/4.3.nix {
6031     inherit fetchurl stdenv unzip;
6032   };
6034   docbook_xml_dtd_45 = import ../data/sgml+xml/schemas/xml-dtd/docbook/4.5.nix {
6035     inherit fetchurl stdenv unzip;
6036   };
6038   docbook_xml_ebnf_dtd = import ../data/sgml+xml/schemas/xml-dtd/docbook-ebnf {
6039     inherit fetchurl stdenv unzip;
6040   };
6042   docbook_xml_xslt = docbook_xsl;
6044   docbook_xsl = import ../data/sgml+xml/stylesheets/xslt/docbook-xsl {
6045     inherit fetchurl stdenv;
6046   };
6048   docbook5_xsl = docbook_xsl_ns;
6050   docbook_xsl_ns = import ../data/sgml+xml/stylesheets/xslt/docbook-xsl-ns {
6051     inherit fetchurl stdenv;
6052   };
6054   junicode = composedArgsAndFun (import ../data/fonts/junicode/0.6.15.nix) {
6055     inherit builderDefs fontforge unzip;
6056     inherit (xorg) mkfontdir mkfontscale;
6057   };
6059   freefont_ttf = import ../data/fonts/freefont-ttf {
6060     inherit fetchurl stdenv;
6061   };
6063   liberation_ttf = import ../data/fonts/redhat-liberation-fonts {
6064     inherit fetchurl stdenv;
6065   };
6067   libertine = builderDefsPackage (import ../data/fonts/libertine/2.7.nix) {
6068     inherit fontforge;
6069   };
6070   libertineBin = builderDefsPackage (import ../data/fonts/libertine/2.7.bin.nix) {
6071   };
6073   lmodern = import ../data/fonts/lmodern {
6074     inherit fetchurl stdenv;
6075   };
6077   manpages = import ../data/documentation/man-pages {
6078     inherit fetchurl stdenv;
6079   };
6081   miscfiles = import ../data/misc/miscfiles {
6082     inherit fetchurl stdenv;
6083   };
6085   mph_2b_damase = import ../data/fonts/mph-2b-damase {
6086     inherit fetchurl stdenv unzip;
6087   };
6089   pthreadmanpages = lowPrio (import ../data/documentation/pthread-man-pages {
6090     inherit fetchurl stdenv perl;
6091   });
6093   shared_mime_info = import ../data/misc/shared-mime-info {
6094     inherit fetchurl stdenv pkgconfig gettext
6095       intltool perl perlXMLParser libxml2 glib;
6096   };
6098   stdmanpages = import ../data/documentation/std-man-pages {
6099     inherit fetchurl stdenv;
6100   };
6102   iana_etc = import ../data/misc/iana-etc {
6103     inherit fetchurl stdenv;
6104   };
6106   popplerData = import ../data/misc/poppler-data {
6107     inherit fetchurl stdenv;
6108   };
6110   r3rs = import ../data/documentation/rnrs/r3rs.nix {
6111     inherit fetchurl stdenv texinfo;
6112   };
6114   r4rs = import ../data/documentation/rnrs/r4rs.nix {
6115     inherit fetchurl stdenv texinfo;
6116   };
6118   r5rs = import ../data/documentation/rnrs/r5rs.nix {
6119     inherit fetchurl stdenv texinfo;
6120   };
6122   themes = name: import (../data/misc/themes + ("/" + name + ".nix")) {
6123     inherit fetchurl;
6124   };
6126   ttf_bitstream_vera = import ../data/fonts/ttf-bitstream-vera {
6127     inherit fetchurl stdenv;
6128   };
6130   ucsFonts = import ../data/fonts/ucs-fonts {
6131     inherit fetchurl stdenv wrapFonts;
6132   };
6134   unifont = import ../data/fonts/unifont {
6135     inherit debPackage perl;
6136     inherit (xorg) mkfontdir mkfontscale bdftopcf fontutil;
6137   };
6139   vistafonts = import ../data/fonts/vista-fonts {
6140     inherit fetchurl stdenv cabextract;
6141   };
6143   wqy_zenhei = composedArgsAndFun (import ../data/fonts/wqy_zenhei/0.4.23-1.nix) {
6144     inherit builderDefs;
6145   };
6147   xhtml1 = import ../data/sgml+xml/schemas/xml-dtd/xhtml1 {
6148     inherit fetchurl stdenv libxml2;
6149   };
6151   xkeyboard_config = import ../data/misc/xkeyboard-config {
6152     inherit fetchurl stdenv perl perlXMLParser gettext intltool;
6153     inherit (xlibs) xkbcomp;
6154   };
6157   ### APPLICATIONS
6160   aangifte2005 = import ../applications/taxes/aangifte-2005 {
6161     inherit stdenv fetchurl;
6162     inherit (xlibs) libX11 libXext;
6163   };
6165   aangifte2006 = import ../applications/taxes/aangifte-2006 {
6166     inherit stdenv fetchurl;
6167     inherit (xlibs) libX11 libXext;
6168   };
6170   aangifte2007 = import ../applications/taxes/aangifte-2007 {
6171     inherit stdenv fetchurl;
6172     inherit (xlibs) libX11 libXext libSM;
6173   };
6175   aangifte2008 = import ../applications/taxes/aangifte-2008 {
6176     inherit stdenv fetchurl;
6177     inherit (xlibs) libX11 libXext libSM;
6178   };
6180   abcde = import ../applications/audio/abcde {
6181     inherit fetchurl stdenv libcdio cddiscid wget bash vorbisTools
6182             makeWrapper;
6183   };
6185   abiword = import ../applications/office/abiword {
6186     inherit fetchurl stdenv pkgconfig fribidi libpng popt libgsf enchant wv;
6187     inherit (gtkLibs) gtk;
6188     inherit (gnome) libglade libgnomeprint libgnomeprintui libgnomecanvas;
6189   };
6191   adobeReader = import ../applications/misc/adobe-reader {
6192     inherit fetchurl stdenv zlib libxml2 cups;
6193     inherit (xlibs) libX11;
6194     inherit (gtkLibs) glib pango atk gtk;
6195   };
6197   amsn = import ../applications/networking/instant-messengers/amsn {
6198     inherit fetchurl stdenv which tcl tk x11;
6199     libstdcpp = gcc33.gcc;
6200   };
6202   ardour = import ../applications/audio/ardour {
6203     inherit fetchurl stdenv lib pkgconfig scons boost redland librdf_raptor
6204       librdf_rasqal jackaudio flac libsamplerate alsaLib libxml2 libxslt
6205       libsndfile libsigcxx libusb cairomm librdf liblo fftw fftwSinglePrec
6206       aubio libmad;
6207     inherit (gtkLibs) glib pango gtk glibmm gtkmm;
6208     inherit (gnome) libgnomecanvas;
6209   };
6211   audacious = import ../applications/audio/audacious/player.nix {
6212     inherit fetchurl stdenv pkgconfig libmowgli libmcs gettext xlibs dbus_glib;
6213     inherit (gnome) libglade;
6214     inherit (gtkLibs) glib gtk;
6215   };
6217   audacious_plugins = import ../applications/audio/audacious/plugins.nix {
6218     inherit fetchurl stdenv pkgconfig audacious dbus_glib gettext
6219       libmad xlibs alsaLib taglib libmpcdec libogg libvorbis
6220       libcdio libcddb libxml2;
6221   };
6223   audacity = import ../applications/audio/audacity {
6224     inherit fetchurl stdenv gettext pkgconfig zlib perl intltool libogg
6225       libvorbis libmad;
6226     inherit (gtkLibs) gtk glib;
6227     inherit wxGTK;
6228   };
6230   aumix = import ../applications/audio/aumix {
6231     inherit fetchurl stdenv ncurses pkgconfig gettext;
6232     inherit (gtkLibs) gtk;
6233     gtkGUI = false;
6234   };
6236   autopanosiftc = import ../applications/graphics/autopanosiftc {
6237     inherit fetchurl stdenv cmake libpng libtiff libjpeg panotools libxml2;
6238   };
6240   avidemux = import ../applications/video/avidemux {
6241     inherit fetchurl stdenv cmake pkgconfig libxml2 qt4 gettext SDL libxslt x264
6242       alsaLib lame faac faad2 libvorbis;
6243     inherit (gtkLibs) gtk;
6244     inherit (xlibs) libXv pixman libpthreadstubs libXau libXdmcp;
6245   };
6247   batik = import ../applications/graphics/batik {
6248     inherit fetchurl stdenv unzip;
6249   };
6251   bazaar = import ../applications/version-management/bazaar {
6252     inherit fetchurl stdenv makeWrapper;
6253     python = pythonFull;
6254   };
6256   bazaarTools = builderDefsPackage (import ../applications/version-management/bazaar/tools.nix) {
6257     inherit bazaar;
6258   };
6260   beast = import ../applications/audio/beast {
6261 # stdenv = overrideGCC stdenv gcc34;
6262     inherit stdenv fetchurl zlib guile pkgconfig intltool libogg libvorbis python libxml2 bash perl gettext;
6263     inherit (bleedingEdgeRepos) sourceByName;
6264     inherit (gtkLibs) gtk glib;
6265     inherit (gnome) libgnomecanvas libart_lgpl;
6266     inherit automake autoconf;
6267   };
6269   bitlbee = import ../applications/networking/instant-messengers/bitlbee {
6270     inherit fetchurl stdenv gnutls pkgconfig glib;
6271   };
6273   bitlbeeOtr = import ../applications/networking/instant-messengers/bitlbee-otr {
6274     inherit fetchbzr stdenv gnutls pkgconfig libotr libgcrypt
6275       libxslt xmlto docbook_xsl docbook_xml_dtd_42 perl glib;
6276   };
6278   # commented out because it's using the new configuration style proposal which is unstable
6279   #biew = import ../applications/misc/biew {
6280   #  inherit lib stdenv fetchurl ncurses;
6281   #};
6283   # only to be able to compile blender - I couldn't compile the default openal software
6284   # Perhaps this can be removed - don't know which one openal{,soft} is better
6285   freealut_soft = import ../development/libraries/freealut {
6286     inherit fetchurl stdenv;
6287     openal = openalSoft;
6288   };
6290   blender = import ../applications/misc/blender {
6291     inherit cmake mesa gettext freetype SDL libtiff fetchurl glibc scons x11 lib
6292       libjpeg libpng zlib /* smpeg sdl */ python;
6293     inherit (xlibs) inputproto libXi;
6294     freealut = freealut_soft;
6295     openal = openalSoft;
6296     openexr = openexr_1_4_0;
6297     # using gcc43 makes blender segfault when pressing p then esc.
6298     # is this related to the PHP bug? I'm to lazy to try recompilng it without optimizations
6299     stdenv = overrideGCC stdenv gcc42;
6300   };
6302   bmp = import ../applications/audio/bmp {
6303     inherit fetchurl stdenv pkgconfig libogg libvorbis alsaLib id3lib;
6304     inherit (gnome) esound libglade;
6305     inherit (gtkLibs) glib gtk;
6306   };
6308   bmp_plugin_musepack = import ../applications/audio/bmp-plugins/musepack {
6309     inherit fetchurl stdenv pkgconfig bmp libmpcdec taglib;
6310   };
6312   bmp_plugin_wma = import ../applications/audio/bmp-plugins/wma {
6313     inherit fetchurl stdenv pkgconfig bmp;
6314   };
6316   bvi = import ../applications/editors/bvi {
6317     inherit fetchurl stdenv ncurses;
6318   };
6320   carrier = builderDefsPackage (import ../applications/networking/instant-messengers/carrier/2.5.0.nix) {
6321     inherit fetchurl stdenv pkgconfig perl perlXMLParser libxml2 openssl nss
6322       gtkspell aspell gettext ncurses avahi dbus dbus_glib python
6323       libtool automake autoconf;
6324     GStreamer = gst_all.gstreamer;
6325     inherit (gtkLibs) gtk glib;
6326     inherit (gnome) startupnotification GConf ;
6327     inherit (xlibs) libXScrnSaver scrnsaverproto libX11 xproto kbproto;
6328   };
6329   funpidgin = carrier;
6331   cddiscid = import ../applications/audio/cd-discid {
6332     inherit fetchurl stdenv;
6333   };
6335   cdparanoia = cdparanoiaIII;
6337   cdparanoiaIII = import ../applications/audio/cdparanoia {
6338     inherit fetchurl stdenv;
6339   };
6341   cdrtools = import ../applications/misc/cdrtools {
6342     inherit fetchurl stdenv;
6343   };
6345   chatzilla =
6346     xulrunnerWrapper {
6347       launcher = "chatzilla";
6348       application = import ../applications/networking/irc/chatzilla {
6349         inherit fetchurl stdenv unzip;
6350       };
6351     };
6353   chrome = import ../applications/networking/browsers/chromium {
6354     inherit stdenv fetchurl ffmpeg cairo nspr nss fontconfig freetype alsaLib makeWrapper unzip expat zlib;
6355     inherit (xlibs) libX11 libXext libXrender libXt ;
6356     inherit (gtkLibs) gtk glib pango atk;
6357     inherit (gnome) GConf;
6358   };
6360   chromeWrapper = wrapFirefox chrome "chrome" "";
6363   cinelerra = import ../applications/video/cinelerra {
6364     inherit fetchurl stdenv
6365       automake autoconf libtool
6366       a52dec alsaLib   lame libavc1394 libiec61883 libraw1394 libsndfile
6367       libvorbis libogg libjpeg libtiff freetype mjpegtools x264
6368       gettext faad2 faac libtheora libpng libdv perl nasm e2fsprogs
6369       pkgconfig;
6370       openexr = openexr_1_6_1;
6371     fftw = fftwSinglePrec;
6372     inherit (xorg) libXxf86vm libXv;
6373     inherit (bleedingEdgeRepos) sourceByName;
6374     inherit (gnome) esound;
6375   };
6377   compizBase = (builderDefsPackage (import ../applications/window-managers/compiz/0.8.0.nix)) {
6378     inherit lib stringsWithDeps builderDefs;
6379     inherit fetchurl stdenv pkgconfig libpng mesa perl perlXMLParser libxslt gettext
6380       intltool binutils;
6381     inherit (xorg) libXcomposite libXfixes libXdamage libXrandr
6382       libXinerama libICE libSM libXrender xextproto compositeproto fixesproto
6383       damageproto randrproto xineramaproto renderproto kbproto xproto libX11
6384       libxcb;
6385     inherit (gnome) startupnotification libwnck GConf;
6386     inherit (gtkLibs) gtk;
6387     inherit (gnome) libgnome libgnomeui metacity
6388       glib pango libglade libgtkhtml gtkhtml
6389       libgnomecanvas libgnomeprint
6390       libgnomeprintui gnomepanel;
6391     gnomegtk = gnome.gtk;
6392     inherit librsvg fuse;
6393     inherit dbus dbus_glib;
6394   };
6396   compiz = compizBase.passthru.function (x : x // {
6397     extraConfigureFlags = getConfig ["compiz" "extraConfigureFlags"] [];
6398   });
6400   compizFusion = import ../applications/window-managers/compiz-fusion {
6401     version = getConfig ["compizFusion" "version"] "0.7.8";
6402     inherit compiz;
6403     inherit stringsWithDeps lib builderDefs;
6404     inherit fetchurl stdenv pkgconfig libpng mesa perl perlXMLParser libxslt libxml2;
6405     inherit (xorg) libXcomposite libXfixes libXdamage libXrandr
6406       libXinerama libICE libSM libXrender xextproto;
6407     inherit (gnome) startupnotification libwnck GConf;
6408     inherit (gtkLibs) gtk;
6409     inherit (gnome) libgnome libgnomeui metacity
6410       glib pango libglade libgtkhtml gtkhtml
6411       libgnomecanvas libgnomeprint
6412       libgnomeprintui gnomepanel gnomedesktop;
6413     gnomegtk = gnome.gtk;
6414     inherit librsvg fuse dbus dbus_glib git;
6415     inherit automake autoconf libtool intltool python pyrex gettext;
6416     inherit pygtk pycairo getopt libjpeg glxinfo;
6417     inherit (xorg) xvinfo xdpyinfo;
6418   };
6420   compizExtra = import ../applications/window-managers/compiz/extra.nix {
6421     inherit fetchurl stdenv pkgconfig compiz perl perlXMLParser dbus;
6422     inherit (gnome) GConf;
6423     inherit (gtkLibs) gtk;
6424   };
6426   cinepaint = import ../applications/graphics/cinepaint {
6427     inherit stdenv fetchcvs cmake pkgconfig freetype fontconfig lcms flex libtiff
6428       libjpeg libpng libexif zlib perl mesa perlXMLParser python pygtk gettext
6429       intltool babl gegl automake autoconf libtool;
6430     inherit (xlibs) makedepend libX11 xf86vidmodeproto xineramaproto libXmu
6431       libXext libXpm libXxf86vm;
6432     inherit (gtkLibs) gtk glib;
6433     openexr = openexr_1_6_1;
6434     fltk = fltk11;
6435   };
6437   codeville = builderDefsPackage (import ../applications/version-management/codeville/0.8.0.nix) {
6438     inherit makeWrapper;
6439     python = pythonFull;
6440   };
6442   comical = import ../applications/graphics/comical {
6443     inherit stdenv fetchurl utillinux zlib;
6444     wxGTK = wxGTK26;
6445   };
6447   cuneiform = builderDefsPackage (import ../tools/graphics/cuneiform) {
6448     inherit cmake patchelf;
6449     imagemagick=imagemagick;
6450   };
6452   cvs = import ../applications/version-management/cvs {
6453     inherit fetchurl stdenv nano;
6454   };
6456   cvsps = import ../applications/version-management/cvsps {
6457     inherit fetchurl stdenv cvs zlib;
6458   };
6460   cvs2svn = import ../applications/version-management/cvs2svn {
6461     inherit fetchurl stdenv python makeWrapper;
6462   };
6464   d4x = import ../applications/misc/d4x {
6465     inherit fetchurl stdenv pkgconfig openssl boost;
6466     inherit (gtkLibs) gtk glib;
6467   };
6469   darcs = haskellPackages.darcs;
6471   dia = import ../applications/graphics/dia {
6472     inherit stdenv fetchurl pkgconfig perl perlXMLParser
6473       libxml2 gettext python libxml2Python docbook5 docbook_xsl
6474       libxslt;
6475     inherit (gtkLibs) gtk glib;
6476   };
6478   djvulibre = import ../applications/misc/djvulibre {
6479     inherit stdenv fetchurl libjpeg libtiff libungif zlib
6480       ghostscript libpng x11 mesa;
6481     qt = if (getConfig ["djvulibre" "qt3Frontend"] true) then qt3 else null;
6482     inherit (xlibs) libX11;
6483   };
6485   djview4 = import ../applications/graphics/djview {
6486     inherit fetchurl stdenv qt4 djvulibre;
6487   };
6489   dmenu = import ../applications/misc/dmenu {
6490     inherit lib fetchurl stdenv;
6491     inherit (xlibs) libX11 libXinerama;
6492   };
6494   dmtx = builderDefsPackage (import ../tools/graphics/dmtx) {
6495     inherit libpng libtiff libjpeg imagemagick librsvg
6496       pkgconfig bzip2 zlib libtool;
6497     inherit (xlibs) libX11;
6498   };
6500   dvdauthor = import ../applications/video/dvdauthor {
6501     inherit fetchurl stdenv freetype libpng fribidi libxml2 libdvdread imagemagick;
6502   };
6504   dwm = import ../applications/window-managers/dwm {
6505     inherit fetchurl stdenv;
6506     inherit (xlibs) libX11 libXinerama;
6507   };
6509   eaglemode = import ../applications/misc/eaglemode {
6510     inherit fetchurl stdenv perl xineLib libjpeg libpng libtiff;
6511     inherit (xlibs) libX11;
6512   };
6514   eclipse = import ../applications/editors/eclipse {
6515     inherit stdenv fetchurl patchelf makeDesktopItem makeWrapper freetype fontconfig jre zlib;
6516     # GTK 2.18 gives glitches such as mouse clicks on buttons not
6517     # working correctly.
6518     inherit (gtkLibs216) glib gtk;
6519     inherit (xlibs) libX11 libXext libXrender libXtst;
6520   };
6522   ed = import ../applications/editors/ed {
6523     inherit fetchurl stdenv;
6524   };
6526   elinks = import ../applications/networking/browsers/elinks {
6527     inherit stdenv fetchurl python perl ncurses x11 zlib openssl spidermonkey
6528       guile bzip2;
6529   };
6531   elvis = import ../applications/editors/elvis {
6532     inherit fetchurl stdenv ncurses;
6533   };
6535   emacs = emacs23;
6537   emacs22 = import ../applications/editors/emacs-22 {
6538     inherit fetchurl stdenv ncurses pkgconfig x11 Xaw3d;
6539     inherit (xlibs) libXaw libXpm;
6540     inherit (gtkLibs) gtk;
6541     xaw3dSupport = getPkgConfig "emacs" "xaw3dSupport" false;
6542     gtkGUI = getPkgConfig "emacs" "gtkSupport" true;
6543   };
6545   emacs23 = import ../applications/editors/emacs-23 {
6546     inherit fetchurl stdenv ncurses pkgconfig x11 Xaw3d
6547       libpng libjpeg libungif libtiff texinfo dbus;
6548     inherit (xlibs) libXaw libXpm libXft;
6549     inherit (gtkLibs) gtk;
6550     xawSupport = stdenv.isDarwin || getPkgConfig "emacs" "xawSupport" false;
6551     xaw3dSupport = getPkgConfig "emacs" "xaw3dSupport" false;
6552     gtkGUI = getPkgConfig "emacs" "gtkSupport" true;
6553     xftSupport = getPkgConfig "emacs" "xftSupport" true;
6554     dbusSupport = getPkgConfig "emacs" "dbusSupport" true;
6555   };
6557   emacsSnapshot = lowPrio (import ../applications/editors/emacs-snapshot {
6558     inherit fetchcvs stdenv ncurses pkgconfig x11 Xaw3d
6559       libpng libjpeg libungif libtiff texinfo dbus
6560       autoconf automake;
6561     inherit (xlibs) libXaw libXpm libXft;
6562     inherit (gtkLibs) gtk;
6563     xawSupport = getPkgConfig "emacs" "xawSupport" false;
6564     xaw3dSupport = getPkgConfig "emacs" "xaw3dSupport" false;
6565     gtkGUI = getPkgConfig "emacs" "gtkSupport" true;
6566     xftSupport = getPkgConfig "emacs" "xftSupport" true;
6567     dbusSupport = getPkgConfig "emacs" "dbusSupport" true;
6568   });
6570   emacsPackages = emacs: recurseIntoAttrs (rec {
6571     bbdb = import ../applications/editors/emacs-modes/bbdb {
6572       inherit fetchurl stdenv emacs texinfo ctags;
6573     };
6575     cedet = import ../applications/editors/emacs-modes/cedet {
6576       inherit fetchurl stdenv emacs;
6577     };
6579     cua = import ../applications/editors/emacs-modes/cua {
6580       inherit fetchurl stdenv;
6581     };
6583     ecb = import ../applications/editors/emacs-modes/ecb {
6584       inherit fetchurl stdenv emacs cedet jdee texinfo;
6585     };
6587     emacsSessionManagement = import ../applications/editors/emacs-modes/session-management-for-emacs {
6588       inherit fetchurl stdenv emacs;
6589     };
6591     emacsw3m = import ../applications/editors/emacs-modes/emacs-w3m {
6592       inherit fetchcvs stdenv emacs w3m imagemagick texinfo autoconf;
6593     };
6595     emms = import ../applications/editors/emacs-modes/emms {
6596       inherit fetchurl stdenv emacs texinfo mpg321 vorbisTools taglib
6597         alsaUtils;
6598     };
6600     jdee = import ../applications/editors/emacs-modes/jdee {
6601       # Requires Emacs 23, for `avl-tree'.
6602       inherit fetchsvn stdenv cedet ant emacs;
6603     };
6605     stratego = import ../applications/editors/emacs-modes/stratego {
6606       inherit fetchsvn stdenv;
6607     };
6609     haskellMode = import ../applications/editors/emacs-modes/haskell {
6610       inherit fetchurl stdenv emacs;
6611     };
6613     magit = import ../applications/editors/emacs-modes/magit {
6614       inherit fetchurl stdenv emacs texinfo;
6615     };
6617     maudeMode = import ../applications/editors/emacs-modes/maude {
6618       inherit fetchurl stdenv emacs;
6619     };
6621     nxml = import ../applications/editors/emacs-modes/nxml {
6622       inherit fetchurl stdenv;
6623     };
6625     prologMode = import ../applications/editors/emacs-modes/prolog {
6626       inherit fetchurl stdenv;
6627     };
6629     quack = import ../applications/editors/emacs-modes/quack {
6630       inherit fetchurl stdenv emacs;
6631     };
6633     remember = import ../applications/editors/emacs-modes/remember {
6634       inherit fetchurl stdenv texinfo emacs bbdb;
6635     };
6637     scalaMode = import ../applications/editors/emacs-modes/scala-mode {
6638       inherit fetchsvn stdenv emacs;
6639     };
6640   });
6642   emacs22Packages = emacsPackages emacs22;
6643   emacs23Packages = emacsPackages emacs23;
6645   evince = makeOverridable (import ../applications/misc/evince) {
6646     inherit fetchurl stdenv perl perlXMLParser gettext intltool
6647       pkgconfig poppler libspectre djvulibre libxslt
6648       dbus dbus_glib shared_mime_info which makeWrapper;
6649     inherit (gnome) gnomedocutils gnomeicontheme libgnome
6650       libgnomeui libglade glib gtk scrollkeeper gnome_keyring;
6651   };
6653   exrdisplay = import ../applications/graphics/exrdisplay {
6654     inherit fetchurl stdenv pkgconfig mesa which openexr_ctl;
6655     fltk = fltk20;
6656     openexr = openexr_1_6_1;
6657   };
6659   fbpanel = composedArgsAndFun (import ../applications/window-managers/fbpanel/4.12.nix) {
6660     inherit fetchurl stdenv builderDefs pkgconfig libpng libjpeg libtiff librsvg;
6661     inherit (gtkLibs) gtk;
6662     inherit (xlibs) libX11 libXmu libXpm;
6663   };
6665   fetchmail = import ../applications/misc/fetchmail {
6666     inherit stdenv fetchurl openssl;
6667   };
6669   grip = import ../applications/misc/grip {
6670     inherit fetchurl stdenv lib grip pkgconfig curl cdparanoia libid3tag;
6671     inherit (gtkLibs) gtk glib;
6672     inherit (gnome) libgnome libgnomeui vte;
6673   };
6675   gwenview = import ../applications/graphics/gwenview {
6676     inherit stdenv fetchurl exiv2 zlib libjpeg perl libpng expat qt3;
6677     inherit (kde3) kdelibs;
6678     inherit (xlibs) libXt libXext;
6679   };
6681   wavesurfer = import ../applications/misc/audio/wavesurfer {
6682     inherit fetchurl stdenv tcl tk snack makeWrapper;
6683   };
6685   wireshark = import ../applications/networking/sniffers/wireshark {
6686     inherit fetchurl stdenv perl pkgconfig libpcap flex bison;
6687     inherit (gtkLibs) gtk;
6688   };
6690   fbida = builderDefsPackage ../applications/graphics/fbida {
6691     inherit libjpeg libexif giflib libtiff libpng
6692       imagemagick ghostscript which curl pkgconfig
6693       freetype fontconfig;
6694   };
6696   fdupes = import ../tools/misc/fdupes {
6697     inherit fetchurl stdenv;
6698   };
6700   feh = import ../applications/graphics/feh {
6701     inherit fetchurl stdenv x11 imlib2 libjpeg libpng giblib;
6702   };
6704   firefox = firefox35;
6706   firefoxWrapper = firefox35Wrapper;
6708   firefox2 = lowPrio (import ../applications/networking/browsers/firefox/2.0.nix {
6709     inherit fetchurl stdenv pkgconfig perl zip libjpeg libpng zlib cairo;
6710     inherit (gtkLibs) gtk;
6711     inherit (gnome) libIDL;
6712     inherit (xlibs) libXi;
6713   });
6715   firefox2Wrapper = wrapFirefox firefox2 "firefox" "";
6717   firefox3Pkgs = lowPrio (import ../applications/networking/browsers/firefox/3.0.nix {
6718     inherit fetchurl stdenv pkgconfig perl zip libjpeg libpng zlib cairo
6719       python dbus dbus_glib freetype fontconfig bzip2 xlibs file;
6720     inherit (gtkLibs) gtk pango;
6721     inherit (gnome) libIDL;
6722   });
6724   firefox3 = firefox3Pkgs.firefox;
6725   xulrunner3 = firefox3Pkgs.xulrunner;
6726   firefox3Wrapper = wrapFirefox firefox3 "firefox" "";
6728   firefox35Pkgs = lowPrio (import ../applications/networking/browsers/firefox/3.5.nix {
6729     inherit fetchurl stdenv pkgconfig perl zip libjpeg libpng zlib cairo
6730       python dbus dbus_glib freetype fontconfig bzip2 xlibs file alsaLib
6731       nspr nss;
6732     inherit (gtkLibs) gtk pango;
6733     inherit (gnome) libIDL;
6734   });
6736   firefox35 = firefox35Pkgs.firefox;
6737   xulrunner35 = firefox35Pkgs.xulrunner;
6738   firefox35Wrapper = wrapFirefox firefox35 "firefox" "";
6740   flac = import ../applications/audio/flac {
6741     inherit fetchurl stdenv libogg;
6742   };
6744   flashplayer = flashplayer10;
6746   flashplayer9 = (
6747     import ../applications/networking/browsers/mozilla-plugins/flashplayer-9 {
6748       inherit fetchurl stdenv zlib alsaLib nss nspr fontconfig freetype expat;
6749       inherit (xlibs) libX11 libXext libXrender libXt ;
6750       inherit (gtkLibs) gtk glib pango atk;
6751     });
6753   flashplayer10 = (
6754     import ../applications/networking/browsers/mozilla-plugins/flashplayer-10 {
6755       inherit fetchurl stdenv zlib alsaLib curl nss nspr fontconfig freetype expat;
6756       inherit (xlibs) libX11 libXext libXrender libXt ;
6757       inherit (gtkLibs) gtk glib pango atk;
6758     });
6760   flite = import ../applications/misc/flite {
6761     inherit fetchurl stdenv;
6762   };
6764   freemind = import ../applications/misc/freemind {
6765     inherit fetchurl stdenv ant coreutils gnugrep;
6766     jdk = jdk;
6767     jre = jdk;
6768   };
6770   freepv = import ../applications/graphics/freepv {
6771     inherit fetchurl stdenv mesa freeglut libjpeg zlib cmake libxml2 libpng;
6772     inherit (xlibs) libX11 libXxf86vm;
6773   };
6775   fspot = import ../applications/graphics/f-spot {
6776     inherit fetchurl stdenv perl perlXMLParser pkgconfig mono
6777             libexif libjpeg sqlite lcms libgphoto2 monoDLLFixer;
6778     inherit (gnome) libgnome libgnomeui;
6779     gtksharp = gtksharp1;
6780   };
6782   gimp = import ../applications/graphics/gimp {
6783     inherit fetchurl stdenv pkgconfig freetype fontconfig
6784       libtiff libjpeg libpng libexif zlib perl perlXMLParser
6785       python pygtk gettext xlibs intltool babl gegl;
6786     inherit (gnome) gtk libart_lgpl;
6787   };
6789   gimpPlugins = import ../applications/graphics/gimp/plugins { inherit pkgs gimp; };
6791   gitAndTools = recurseIntoAttrs (import ../applications/version-management/git-and-tools {
6792     inherit pkgs;
6793   });
6794   git = gitAndTools.git;
6796   gnucash = import ../applications/office/gnucash {
6797     inherit fetchurl stdenv pkgconfig libxml2 goffice enchant
6798       gettext intltool perl guile slibGuile swig isocodes bzip2 makeWrapper;
6799     inherit (gnome) gtk glib libglade libgnomeui libgtkhtml gtkhtml
6800       libgnomeprint;
6801     gconf = gnome.GConf;
6802   };
6804   qcad = import ../applications/misc/qcad {
6805     inherit fetchurl stdenv qt3 libpng;
6806     inherit (xlibs) libXext libX11;
6807   };
6809   qjackctl = import ../applications/audio/qjackctl {
6810     inherit fetchurl stdenv alsaLib jackaudio;
6811     qt4 = qt4;
6812   };
6814   gkrellm = import ../applications/misc/gkrellm {
6815     inherit fetchurl stdenv gettext pkgconfig;
6816     inherit (gtkLibs) glib gtk;
6817     inherit (xlibs) libX11 libICE libSM;
6818   };
6820   gnash = import ../applications/video/gnash {
6821     inherit fetchurl stdenv SDL SDL_mixer libogg libxml2 libjpeg mesa libpng
6822             boost freetype agg dbus curl pkgconfig x11 libtool lib libungif
6823             gettext makeWrapper ming dejagnu python;
6824     inherit (gtkLibs) glib gtk;
6825     inherit (gst_all) gstreamer gstPluginsBase gstFfmpeg;
6826   };
6828   gnome_mplayer = import ../applications/video/gnome-mplayer {
6829     inherit fetchurl stdenv pkgconfig dbus dbus_glib;
6830     inherit (gtkLibs) glib gtk;
6831     inherit (gnome) GConf;
6832   };
6834   gnunet = import ../applications/networking/p2p/gnunet {
6835     inherit fetchurl stdenv libextractor libmicrohttpd libgcrypt
6836       gmp curl libtool guile adns sqlite gettext zlib pkgconfig
6837       libxml2 ncurses findutils makeWrapper;
6838     inherit (gnome) gtk libglade;
6839     gtkSupport = getConfig [ "gnunet" "gtkSupport" ] true;
6840   };
6842   gocr = composedArgsAndFun (import ../applications/graphics/gocr/0.44.nix) {
6843     inherit builderDefs fetchurl stdenv;
6844   };
6846   gphoto2 = import ../applications/misc/gphoto2 {
6847     inherit fetchurl stdenv pkgconfig libgphoto2 libexif popt gettext
6848       libjpeg readline libtool;
6849   };
6851   gphoto2fs = builderDefsPackage ../applications/misc/gphoto2/gphotofs.nix {
6852     inherit libgphoto2 fuse pkgconfig glib;
6853   };
6855   gtkpod = import ../applications/audio/gtkpod {
6856     inherit stdenv fetchurl pkgconfig libgpod gettext perl perlXMLParser flex libid3tag libvorbis;
6857     inherit (gtkLibs) gtk glib;
6858     inherit (gnome) libglade;
6859   };
6861   qrdecode = builderDefsPackage (import ../tools/graphics/qrdecode) {
6862     inherit libpng libcv;
6863   };
6865   qrencode = builderDefsPackage (import ../tools/graphics/qrencode) {
6866     inherit libpng pkgconfig;
6867   };
6869   gecko_mediaplayer = import ../applications/networking/browsers/mozilla-plugins/gecko-mediaplayer {
6870     inherit fetchurl stdenv pkgconfig dbus dbus_glib x11 gnome_mplayer MPlayer glib;
6871     inherit (gnome) GConf;
6872     browser = firefox35;
6873   };
6875   geeqie = import ../applications/graphics/geeqie {
6876     inherit fetchurl stdenv pkgconfig libpng lcms exiv2
6877       intltool gettext;
6878     inherit (gtkLibs) gtk;
6879   };
6881   gqview = import ../applications/graphics/gqview {
6882     inherit fetchurl stdenv pkgconfig libpng;
6883     inherit (gtkLibs) gtk;
6884   };
6886   googleearth = import ../applications/misc/googleearth {
6887       inherit stdenv fetchurl glibc mesa freetype zlib glib;
6888       inherit (xlibs) libSM libICE libXi libXv libXrender libXrandr libXfixes
6889         libXcursor libXinerama libXext libX11;
6890       inherit patchelf05;
6891     };
6893   gpsbabel = import ../applications/misc/gpsbabel {
6894     inherit fetchurl stdenv zlib expat;
6895   };
6897   gpscorrelate = import ../applications/misc/gpscorrelate {
6898     inherit fetchurl stdenv pkgconfig exiv2 libxml2
6899       libxslt docbook_xsl docbook_xml_dtd_42;
6900     inherit (gtkLibs) gtk;
6901   };
6903   gpsd = import ../servers/gpsd {
6904     inherit fetchurl stdenv pkgconfig dbus dbus_glib
6905       ncurses makeWrapper libxslt xmlto;
6906     inherit (xlibs) libX11 libXt libXpm libXaw libXext;
6908     # We need a Python with NCurses bindings.
6909     python = pythonFull;
6910   };
6912   gv = import ../applications/misc/gv {
6913     inherit fetchurl stdenv Xaw3d ghostscriptX;
6914   };
6916   hello = makeOverridable (import ../applications/misc/hello/ex-2) {
6917     inherit fetchurl stdenv;
6918   };
6920   hugin = import ../applications/graphics/hugin {
6921     inherit stdenv fetchurl cmake panotools libtiff libpng boost pkgconfig
6922       exiv2 gettext ilmbase enblendenfuse autopanosiftc;
6923     inherit wxGTK;
6924     openexr = openexr_1_6_1;
6925   };
6927   i810switch = import ../applications/misc/i810 {
6928     inherit fetchurl stdenv pciutils;
6929   };
6931   icecat3 = lowPrio (import ../applications/networking/browsers/icecat-3 {
6932     inherit fetchurl stdenv pkgconfig perl zip libjpeg libpng zlib cairo
6933       python dbus dbus_glib freetype fontconfig bzip2 xlibs alsaLib;
6934     inherit (gnome) libIDL libgnomeui gnomevfs gtk pango;
6935     inherit (pythonPackages) ply;
6936   });
6938   icecatXulrunner3 = lowPrio (import ../applications/networking/browsers/icecat-3 {
6939     application = "xulrunner";
6940     inherit fetchurl stdenv pkgconfig perl zip libjpeg libpng zlib cairo
6941       python dbus dbus_glib freetype fontconfig bzip2 xlibs alsaLib;
6942     inherit (gnome) libIDL libgnomeui gnomevfs gtk pango;
6943     inherit (pythonPackages) ply;
6944   });
6946   icecat3Xul =
6947     (symlinkJoin "icecat-with-xulrunner-${icecat3.version}"
6948        [ icecat3 icecatXulrunner3 ])
6949     // { inherit (icecat3) gtk isFirefox3Like meta; };
6951   icecatWrapper = wrapFirefox icecat3Xul "icecat" "";
6953   icewm = import ../applications/window-managers/icewm {
6954     inherit fetchurl stdenv gettext libjpeg libtiff libungif libpng imlib;
6955     inherit (xlibs) libX11 libXft libXext libXinerama libXrandr;
6956   };
6958   ikiwiki = makeOverridable (import ../applications/misc/ikiwiki) {
6959     inherit fetchurl stdenv perl gettext makeWrapper lib;
6960     inherit (perlPackages) TextMarkdown URI HTMLParser HTMLScrubber
6961       HTMLTemplate TimeDate CGISession DBFile CGIFormBuilder;
6962     inherit git; # The RCS should be optional
6963     monotone = null;
6964     extraUtils = [];
6965   };
6967   imagemagick = import ../applications/graphics/ImageMagick {
6968     inherit stdenv fetchurl bzip2 freetype graphviz ghostscript
6969       libjpeg libpng libtiff libxml2 zlib libtool;
6970     inherit (xlibs) libX11;
6971   };
6973   imagemagickBig = import ../applications/graphics/ImageMagick {
6974     inherit stdenv fetchurl bzip2 freetype graphviz ghostscript
6975       libjpeg libpng libtiff libxml2 zlib tetex librsvg libtool;
6976     inherit (xlibs) libX11;
6977   };
6979   # Impressive, formerly known as "KeyJNote".
6980   impressive = import ../applications/office/impressive {
6981     inherit fetchurl stdenv xpdf pil pyopengl pygame makeWrapper lib python;
6983     # XXX These are the PyOpenGL dependencies, which we need here.
6984     inherit setuptools mesa freeglut;
6985   };
6987   inkscape = import ../applications/graphics/inkscape {
6988     inherit fetchurl stdenv perl perlXMLParser pkgconfig zlib popt
6989       libxml2 libxslt libpng boehmgc libsigcxx lcms boost gettext
6990       cairomm python pyxml makeWrapper intltool gsl;
6991     inherit (pythonPackages) lxml;
6992     inherit (gtkLibs) gtk glib glibmm gtkmm;
6993     inherit (xlibs) libXft;
6994   };
6996   ion3 = import ../applications/window-managers/ion-3 {
6997     inherit fetchurl stdenv x11 gettext groff;
6998     lua = lua5;
6999   };
7001   iptraf = import ../applications/networking/iptraf {
7002     inherit fetchurl stdenv ncurses;
7003   };
7005   irssi = import ../applications/networking/irc/irssi {
7006     inherit stdenv fetchurl pkgconfig ncurses openssl glib;
7007   };
7009   jackmeter = import ../applications/audio/jackmeter {
7010     inherit fetchurl stdenv lib jackaudio pkgconfig;
7011   };
7013   jedit = import ../applications/editors/jedit {
7014     inherit fetchurl stdenv ant;
7015   };
7017   jigdo = import ../applications/misc/jigdo {
7018     inherit fetchurl stdenv db45 libwpd bzip2;
7019     inherit (gtkLibs) gtk;
7020   };
7022   joe = import ../applications/editors/joe {
7023     inherit stdenv fetchurl;
7024   };
7026   jwm = import ../applications/window-managers/jwm {
7027     inherit fetchurl stdenv;
7028     inherit (xlibs) libX11 libXext libXinerama libXpm libXft;
7029   };
7031   k3b = import ../applications/misc/k3b {
7032     inherit stdenv fetchurl kdelibs x11 zlib libpng libjpeg perl qt3;
7033   };
7035   kbasket = import ../applications/misc/kbasket {
7036     inherit stdenv fetchurl kdelibs x11 zlib libpng libjpeg
7037       perl qt3 gpgme libgpgerror;
7038   };
7040   kermit = import ../tools/misc/kermit {
7041     inherit fetchurl stdenv ncurses;
7042   };
7044   kino = import ../applications/video/kino {
7045     inherit fetchurl stdenv pkgconfig libxml2 perl perlXMLParser
7046       libdv libraw1394 libavc1394 libiec61883 x11 gettext cairo; /* libavformat */
7047     inherit libsamplerate ffmpeg;
7048     inherit (gnome) libglade gtk glib;
7049     inherit (xlibs) libXv libX11;
7050     inherit (gtkLibs) pango;
7051     # #  optional
7052     #  inherit ffmpeg2theora sox, vorbis-tools lame mjpegtools dvdauthor 'Q'dvdauthor growisofs mencoder;
7053   };
7055   kile = import ../applications/editors/kile {
7056     inherit stdenv fetchurl perl arts kdelibs zlib libpng libjpeg freetype expat;
7057     inherit (xlibs) libX11 libXt libXext libXrender libXft;
7058     qt = qt3;
7059   };
7061   konversation = import ../applications/networking/irc/konversation {
7062     inherit fetchurl stdenv perl arts kdelibs zlib libpng libjpeg expat;
7063     inherit (xlibs) libX11 libXt libXext libXrender libXft;
7064     qt = qt3;
7065   };
7067   kphone = import ../applications/networking/kphone {
7068     inherit fetchurl lib autoconf automake libtool pkgconfig openssl libpng alsaLib;
7069     qt = qt3;
7070     inherit (xlibs) libX11 libXext libXt libICE libSM;
7071     stdenv = overrideGCC stdenv gcc42; # I'm to lazy to clean up header files
7072   };
7074   kuickshow = import ../applications/graphics/kuickshow {
7075     inherit fetchurl stdenv kdelibs arts libpng libjpeg libtiff libungif imlib expat perl;
7076     inherit (xlibs) libX11 libXext libSM;
7077     qt = qt3;
7078   };
7080   lame = import ../applications/audio/lame {
7081     inherit fetchurl stdenv;
7082   };
7084   ladspaH = import ../applications/audio/ladspa-plugins/ladspah.nix {
7085     inherit fetchurl stdenv builderDefs stringsWithDeps;
7086   };
7088   ladspaPlugins = import ../applications/audio/ladspa-plugins {
7089     inherit fetchurl stdenv builderDefs stringsWithDeps fftw ladspaH pkgconfig;
7090   };
7092   ldcpp = composedArgsAndFun (import ../applications/networking/p2p/ldcpp/1.0.3.nix) {
7093     inherit builderDefs scons pkgconfig bzip2 openssl;
7094     inherit (gtkLibs) gtk;
7095     inherit (gnome) libglade;
7096     inherit (xlibs) libX11;
7097   };
7099   links = import ../applications/networking/browsers/links {
7100     inherit fetchurl stdenv;
7101   };
7103   ledger = import ../applications/office/ledger {
7104     inherit stdenv fetchurl emacs gmp pcre;
7105   };
7107   links2 = (builderDefsPackage ../applications/networking/browsers/links2) {
7108     inherit fetchurl stdenv bzip2 zlib libjpeg libpng libtiff
7109       gpm openssl SDL SDL_image SDL_net pkgconfig;
7110     inherit (xlibs) libX11 libXau xproto libXt;
7111   };
7113   lynx = import ../applications/networking/browsers/lynx {
7114     inherit fetchurl stdenv ncurses openssl;
7115   };
7117   lyx = import ../applications/misc/lyx {
7118    inherit fetchurl stdenv texLive python;
7119    qt = qt4;
7120   };
7122   mercurial = import ../applications/version-management/mercurial {
7123     inherit fetchurl stdenv makeWrapper getConfig tk;
7124     guiSupport = getConfig ["mercurial" "guiSupport"] false; # for hgk (gitk gui for hg)
7125     python = # allow cloning sources from https servers.
7126       if getConfig ["mercurial" "httpsSupport"] true
7127       then pythonFull
7128       else pythonBase;
7129   };
7131   meshlab = import ../applications/graphics/meshlab {
7132     inherit fetchurl stdenv bzip2;
7133     qt = qt4;
7134   };
7136   midori = builderDefsPackage (import ../applications/networking/browsers/midori) {
7137     inherit imagemagick intltool python pkgconfig webkit libxml2
7138       which gettext makeWrapper file libidn sqlite docutils libnotify;
7139     inherit (gtkLibs) gtk glib;
7140     inherit (gnome28) gtksourceview libsoup;
7141   };
7143   minicom = import ../tools/misc/minicom {
7144     inherit fetchurl stdenv ncurses;
7145   };
7147   monodevelop = import ../applications/editors/monodevelop {
7148     inherit fetchurl stdenv file mono gtksourceviewsharp
7149             gtkmozembedsharp monodoc perl perlXMLParser pkgconfig;
7150     inherit (gnome) gnomevfs libbonobo libglade libgnome GConf glib gtk;
7151     mozilla = firefox;
7152     gtksharp = gtksharp2;
7153   };
7155   monodoc = import ../applications/editors/monodoc {
7156     inherit fetchurl stdenv mono pkgconfig;
7157     gtksharp = gtksharp1;
7158   };
7160   mozilla = import ../applications/networking/browsers/mozilla {
7161     inherit fetchurl pkgconfig stdenv perl zip;
7162     inherit (gtkLibs) gtk;
7163     inherit (gnome) libIDL;
7164     inherit (xlibs) libXi;
7165   };
7167   mozplugger = builderDefsPackage (import ../applications/networking/browsers/mozilla-plugins/mozplugger) {
7168     inherit firefox;
7169     inherit (xlibs) libX11 xproto;
7170   };
7172   mpg321 = import ../applications/audio/mpg321 {
7173     inherit stdenv fetchurl libao libmad libid3tag zlib;
7174   };
7176   MPlayer = import ../applications/video/MPlayer {
7177     inherit fetchurl stdenv freetype x11 zlib libtheora libcaca freefont_ttf libdvdnav
7178       cdparanoia mesa pkgconfig unzip amrnb amrwb;
7179     inherit (xlibs) libX11 libXv libXinerama libXrandr;
7180     alsaSupport = true;
7181     alsa = alsaLib;
7182     theoraSupport = true;
7183     cacaSupport = true;
7184     xineramaSupport = true;
7185     randrSupport = true;
7186     cddaSupport = true;
7187     amrSupport = getConfig [ "MPlayer" "amr" ] false;
7188   };
7190   MPlayerPlugin = browser:
7191     import ../applications/networking/browsers/mozilla-plugins/mplayerplug-in {
7192       inherit browser;
7193       inherit fetchurl stdenv pkgconfig gettext;
7194       inherit (xlibs) libXpm;
7195       # !!! should depend on MPlayer
7196     };
7198   MPlayerTrunk = import ../applications/video/MPlayer/trunk.nix {
7199     inherit (bleedingEdgeRepos) sourceByName;
7200     inherit fetchurl stdenv freetype x11 zlib libtheora libcaca freefont_ttf libdvdnav
7201       cdparanoia mesa pkgconfig jackaudio;
7202     inherit (xlibs) libX11 libXv libXinerama libXrandr;
7203     alsaSupport = true;
7204     alsa = alsaLib;
7205     theoraSupport = true;
7206     cacaSupport = true;
7207     xineramaSupport = true;
7208     randrSupport = true;
7209     cddaSupport = true;
7210   };
7212   mrxvt = import ../applications/misc/mrxvt {
7213     inherit lib fetchurl stdenv freetype pkgconfig which;
7214     inherit (xlibs) libXaw xproto libXt libX11 libSM libICE libXft
7215       libXi inputproto;
7216   };
7218   multisync = import ../applications/misc/multisync {
7219     inherit fetchurl stdenv autoconf automake libtool pkgconfig;
7220     inherit (gnome) gtk glib ORBit2 libbonobo libgnomeui GConf;
7221   };
7223   mutt = import ../applications/networking/mailreaders/mutt {
7224     inherit fetchurl stdenv ncurses which openssl gdbm;
7225   };
7227   msmtp = import ../applications/networking/msmtp {
7228     inherit fetchurl stdenv;
7229   };
7231   mythtv = import ../applications/video/mythtv {
7232     inherit fetchurl stdenv which x11 xlibs lame zlib mesa freetype perl alsaLib;
7233     qt3 = qt3mysql;
7234   };
7236   nano = import ../applications/editors/nano {
7237     inherit fetchurl stdenv ncurses gettext;
7238   };
7240   nedit = import ../applications/editors/nedit {
7241       inherit fetchurl stdenv x11;
7242       inherit (xlibs) libXpm;
7243       motif = lesstif;
7244     };
7246   netsurfBrowser = netsurf.browser;
7247   netsurf = recurseIntoAttrs (import ../applications/networking/browsers/netsurf { inherit pkgs; });
7249   nvi = import ../applications/editors/nvi {
7250     inherit fetchurl stdenv ncurses;
7251   };
7253   openoffice = import ../applications/office/openoffice {
7254     inherit fetchurl stdenv pam python tcsh libxslt perl zlib libjpeg
7255       expat pkgconfig freetype fontconfig libwpd libxml2 db4 sablotron
7256       curl libsndfile flex zip unzip libmspack getopt file neon cairo
7257       which icu jdk ant cups openssl bison boost gperf cppunit;
7258     inherit (xlibs) libXaw libXext libX11 libXtst libXi libXinerama;
7259     inherit (gtkLibs) gtk;
7260     inherit (perlPackages) ArchiveZip CompressZlib;
7261     inherit (gnome) GConf ORBit2;
7262   };
7264   opera = import ../applications/networking/browsers/opera {
7265     inherit fetchurl zlib glibc stdenv makeDesktopItem;
7266     inherit (xlibs) libX11 libSM libICE libXt libXext;
7267     qt = qt3;
7268   };
7270   pan = import ../applications/networking/newsreaders/pan {
7271     inherit fetchurl stdenv pkgconfig perl pcre gmime gettext;
7272     inherit (gtkLibs) gtk;
7273     spellChecking = false;
7274   };
7276   panotools = import ../applications/graphics/panotools {
7277     inherit stdenv fetchsvn libpng libjpeg libtiff automake libtool autoconf;
7278   };
7280   pavucontrol = import ../applications/audio/pavucontrol {
7281     inherit fetchurl stdenv pkgconfig pulseaudio libsigcxx
7282       libcanberra intltool gettext;
7283     inherit (gtkLibs) gtkmm;
7284     inherit (gnome) libglademm;
7285   };
7287   paraview = import ../applications/graphics/paraview {
7288     inherit fetchurl stdenv cmake qt4;
7289   };
7291   partitionManager = import ../tools/misc/partition-manager {
7292     inherit fetchurl stdenv lib cmake pkgconfig gettext parted libuuid perl;
7293     kde = kde43;
7294     qt = qt4;
7295   };
7297   pidgin = import ../applications/networking/instant-messengers/pidgin {
7298     inherit fetchurl stdenv pkgconfig perl perlXMLParser libxml2 nss nspr
7299       gtkspell aspell gettext ncurses avahi dbus dbus_glib lib intltool;
7300     openssl = if (getConfig ["pidgin" "openssl"] true) then openssl else null;
7301     gnutls = if (getConfig ["pidgin" "gnutls"] false) then gnutls else null;
7302     GStreamer = gst_all.gstreamer;
7303     inherit (gtkLibs) gtk;
7304     inherit (gnome) startupnotification;
7305     inherit (xlibs) libXScrnSaver;
7306   };
7308   pidginlatex = composedArgsAndFun (import ../applications/networking/instant-messengers/pidgin-plugins/pidgin-latex) {
7309     inherit fetchurl stdenv pkgconfig ghostscript pidgin texLive;
7310     imagemagick = imagemagickBig;
7311     inherit (gtkLibs) glib gtk;
7312   };
7314   pidginlatexSF = builderDefsPackage
7315     (import ../applications/networking/instant-messengers/pidgin-plugins/pidgin-latex/pidgin-latex-sf.nix)
7316     {
7317       inherit pkgconfig pidgin texLive imagemagick which;
7318       inherit (gtkLibs) glib gtk;
7319     };
7321   pidginotr = import ../applications/networking/instant-messengers/pidgin-plugins/otr {
7322     inherit fetchurl stdenv libotr pidgin;
7323   };
7325   pinfo = import ../applications/misc/pinfo {
7326     inherit fetchurl stdenv ncurses readline;
7327   };
7329   pqiv = import ../applications/graphics/pqiv {
7330     inherit fetchurl stdenv getopt which pkgconfig;
7331     inherit (gtkLibs) gtk;
7332   };
7334   # perhaps there are better apps for this task? It's how I had configured my preivous system.
7335   # And I don't want to rewrite all rules
7336   procmail = import ../applications/misc/procmail {
7337     inherit fetchurl stdenv autoconf;
7338   };
7340   pstree = import ../applications/misc/pstree {
7341     inherit stdenv fetchurl;
7342   };
7344   pythonmagick = import ../applications/graphics/PythonMagick {
7345     inherit fetchurl stdenv pkgconfig imagemagick boost python;
7346   };
7348   qemu = import ../applications/virtualization/qemu/0.11.0.nix {
7349     inherit stdenv fetchurl SDL zlib which;
7350   };
7352   qemuSVN = import ../applications/virtualization/qemu/svn-6642.nix {
7353     inherit fetchsvn SDL zlib which stdenv;
7354   };
7356   qemuImage = composedArgsAndFun (import ../applications/virtualization/qemu/linux-img/0.2.nix) {
7357     inherit builderDefs fetchurl stdenv;
7358   };
7360   qtpfsgui = import ../applications/graphics/qtpfsgui {
7361     inherit fetchurl stdenv exiv2 libtiff fftw qt4 ilmbase;
7362     openexr = openexr_1_6_1;
7363   };
7365   ratpoison = import ../applications/window-managers/ratpoison {
7366     inherit fetchurl stdenv fontconfig readline;
7367     inherit (xlibs) libX11 inputproto libXt libXpm libXft
7368       libXtst xextproto libXi;
7369   };
7371   rcs = import ../applications/version-management/rcs {
7372     inherit fetchurl stdenv;
7373   };
7375   rdesktop = import ../applications/networking/remote/rdesktop {
7376     inherit fetchurl stdenv openssl;
7377     inherit (xlibs) libX11;
7378   };
7380   RealPlayer =
7381     (import ../applications/video/RealPlayer {
7382       inherit fetchurl stdenv;
7383       inherit (gtkLibs) glib pango atk gtk;
7384       inherit (xlibs) libX11;
7385       libstdcpp5 = gcc33.gcc;
7386     });
7388   rsync = import ../applications/networking/sync/rsync {
7389     inherit fetchurl stdenv acl;
7390     enableACLs = !stdenv.isDarwin;
7391   };
7393   rxvt = import ../applications/misc/rxvt {
7394     inherit lib fetchurl stdenv;
7395     inherit (xlibs) libXt libX11;
7396   };
7398   # = urxvt
7399   rxvt_unicode = makeOverridable (import ../applications/misc/rxvt_unicode) {
7400     inherit lib fetchurl stdenv perl ncurses;
7401     inherit (xlibs) libXt libX11 libXft;
7402     perlSupport = false;
7403   };
7405   sbagen = import ../applications/misc/sbagen {
7406     inherit fetchurl stdenv;
7407   };
7409   scribus = import ../applications/office/scribus {
7410     inherit fetchurl stdenv lib cmake pkgconfig freetype lcms libtiff libxml2
7411       cairo python cups fontconfig zlib libjpeg libpng;
7412     inherit (gnome) libart_lgpl;
7413     inherit (xlibs) libXaw libXext libX11 libXtst libXi libXinerama;
7414     qt = qt3;
7415   };
7417   skype_linux = import ../applications/networking/skype {
7418     inherit fetchurl stdenv;
7419     inherit glibc alsaLib freetype fontconfig libsigcxx gcc;
7420     inherit (xlibs) libSM libICE libXi libXrender libXrandr libXfixes libXcursor
7421                     libXinerama libXext libX11 libXv libXScrnSaver;
7422   };
7424   slim = import ../applications/display-managers/slim {
7425     inherit fetchurl stdenv x11 libjpeg libpng freetype pam;
7426     inherit (xlibs) libXmu;
7427   };
7429   sndBase = builderDefsPackage (import ../applications/audio/snd) {
7430     inherit fetchurl stdenv stringsWithDeps lib fftw;
7431     inherit pkgconfig gmp gettext;
7432     inherit (xlibs) libXpm libX11;
7433     inherit (gtkLibs) gtk glib;
7434   };
7436   snd = sndBase.passthru.function {
7437     inherit guile mesa libtool jackaudio alsaLib;
7438   };
7440   sonicVisualizer = import ../applications/audio/sonic-visualizer {
7441     inherit fetchurl stdenv lib libsndfile libsamplerate bzip2 librdf
7442       rubberband jackaudio pulseaudio libmad
7443       libogg liblo alsaLib librdf_raptor librdf_rasqal redland fftw;
7444     inherit (vamp) vampSDK;
7445     qt = qt4;
7446   };
7448   sox = import ../applications/misc/audio/sox {
7449     inherit fetchurl stdenv lib composableDerivation;
7450     # optional features
7451     inherit alsaLib libao ffmpeg;
7452     inherit libsndfile libogg flac libmad lame libsamplerate;
7453     # Using the default nix ffmpeg I get this error when linking
7454     # .libs/libsox_la-ffmpeg.o: In function `audio_decode_frame':
7455     # /tmp/nix-7957-1/sox-14.0.0/src/ffmpeg.c:130: undefined reference to `avcodec_decode_audio2
7456     # That's why I'v added ffmpeg_svn
7457   };
7459   stumpwm = builderDefsPackage (import ../applications/window-managers/stumpwm) {
7460     inherit texinfo;
7461     clisp = clisp_2_44_1;
7462   };
7464   subversion = makeOverridable (import ../applications/version-management/subversion/default.nix) {
7465     inherit (pkgsOverriden) fetchurl stdenv apr aprutil expat swig zlib jdk python perl sqlite;
7466     neon = neon028;
7467     bdbSupport = getConfig ["subversion" "bdbSupport"] true;
7468     httpServer = getConfig ["subversion" "httpServer"] false;
7469     httpSupport = getConfig ["subversion" "httpSupport"] true;
7470     sslSupport = getConfig ["subversion" "sslSupport"] true;
7471     pythonBindings = getConfig ["subversion" "pythonBindings"] false;
7472     perlBindings = getConfig ["subversion" "perlBindings"] false;
7473     javahlBindings = supportsJDK && getConfig ["subversion" "javahlBindings"] false;
7474     compressionSupport = getConfig ["subversion" "compressionSupport"] true;
7475     httpd = pkgsOverriden.apacheHttpd;
7476   };
7478   svk = perlPackages.SVK;
7480   sylpheed = import ../applications/networking/mailreaders/sylpheed {
7481     inherit fetchurl stdenv pkgconfig openssl gpgme;
7482     inherit (gtkLibs) gtk;
7483     sslSupport = true;
7484     gpgSupport = true;
7485   };
7487   # linux only by now
7488   synergy = import ../applications/misc/synergy {
7489     inherit fetchurl bleedingEdgeRepos stdenv x11;
7490     inherit (xlibs) xextproto libXtst inputproto libXi;
7491   };
7493   tahoelafs = import ../tools/networking/p2p/tahoe-lafs {
7494     inherit fetchurl lib unzip nettools buildPythonPackage;
7495     inherit (pythonPackages) twisted foolscap simplejson nevow zfec
7496       pycryptopp pysqlite;
7497   };
7499   tailor = builderDefsPackage (import ../applications/version-management/tailor) {
7500     inherit makeWrapper python;
7501   };
7503   tangogps = import ../applications/misc/tangogps {
7504     inherit fetchurl stdenv pkgconfig gettext curl libexif sqlite;
7505     inherit (gtkLibs) gtk;
7506     gconf = gnome.GConf;
7507   };
7509   /* does'nt work yet i686-linux only (32bit version)
7510   teamspeak_client = import ../applications/networking/instant-messengers/teamspeak/client.nix {
7511     inherit fetchurl stdenv;
7512     inherit glibc x11;
7513   };
7514   */
7516   taskJuggler = import ../applications/misc/taskjuggler {
7517     inherit stdenv fetchurl;
7518     inherit zlib libpng perl expat;
7519     qt = qt3;
7521     inherit (xlibs) libX11 libXext libSM libICE;
7523     # KDE support is not working yet.
7524     inherit kdelibs kdebase;
7525     withKde = pkgs.getConfig ["taskJuggler" "kde"] false;
7526   };
7528   thinkingRock = import ../applications/misc/thinking-rock {
7529     inherit fetchurl stdenv;
7530   };
7532   thunderbird = import ../applications/networking/mailreaders/thunderbird-2.x {
7533     inherit fetchurl stdenv pkgconfig perl zip libjpeg libpng zlib cairo;
7534     inherit (gtkLibs) gtk;
7535     inherit (gnome) libIDL;
7536     inherit (xlibs) libXi;
7537     #enableOfficialBranding = true;
7538   };
7540   /*
7541   Despaired. Looks like ThunderBird-on-Firefox's-Xulrunner is non-trivial
7543   thunderbird3 = lowPrio (import ../applications/networking/mailreaders/thunderbird-3.x {
7544     inherit fetchurl stdenv pkgconfig perl zip libjpeg zlib cairo
7545       python dbus dbus_glib freetype fontconfig bzip2 libpng alsaLib sqlite
7546       patchelf;
7547     inherit (gtkLibs) gtk pango;
7548     inherit (gnome) libIDL;
7549     #enableOfficialBranding = true;
7550     xulrunner = xulrunner3;
7551     autoconf = autoconf213;
7552   });*/
7554   timidity = import ../tools/misc/timidity {
7555     inherit fetchurl stdenv lib alsaLib composableDerivation jackaudio ncurses;
7556   };
7558   tkcvs = import ../applications/version-management/tkcvs {
7559     inherit stdenv fetchurl tcl tk;
7560   };
7562   tla = import ../applications/version-management/arch {
7563     inherit fetchurl stdenv diffutils gnutar gnupatch which;
7564   };
7566   twinkle = import ../applications/networking/twinkle {
7567     inherit fetchurl stdenv lib pkgconfig commoncpp2 ccrtp openssl speex libjpeg perl
7568       libzrtpcpp libsndfile libxml2 file readline alsaLib;
7569     qt = qt3;
7570     boost = boostFull;
7571     inherit (xlibs) libX11 libXaw libICE libXext;
7572   };
7574   unison = import ../applications/networking/sync/unison {
7575     inherit fetchurl stdenv ocaml lablgtk makeWrapper;
7576     inherit (xorg) xset fontschumachermisc;
7577   };
7579   uucp = import ../tools/misc/uucp {
7580     inherit fetchurl stdenv;
7581   };
7583   uzbl = builderDefsPackage (import ../applications/networking/browsers/uzbl) {
7584     inherit pkgconfig webkit makeWrapper;
7585     inherit (gtkLibs) gtk glib;
7586     libsoup = gnome28.libsoup;
7587   };
7589   uzblExperimental = builderDefsPackage
7590         (import ../applications/networking/browsers/uzbl/experimental.nix) {
7591     inherit pkgconfig webkit makeWrapper;
7592     inherit (gtkLibs) gtk glib;
7593     libsoup = gnome28.libsoup;
7594   };
7596   valknut = import ../applications/networking/p2p/valknut {
7597     inherit fetchurl stdenv perl x11 libxml2 libjpeg libpng openssl dclib;
7598     qt = qt3;
7599   };
7601   vim = import ../applications/editors/vim {
7602     inherit fetchurl stdenv ncurses lib;
7603   };
7605   vimHugeX = import ../applications/editors/vim {
7606     inherit fetchurl stdenv lib ncurses pkgconfig
7607       perl python tcl;
7608     inherit (xlibs) libX11 libXext libSM libXpm
7609       libXt libXaw libXau;
7610     inherit (gtkLibs) glib gtk;
7612     # Looks like python and perl can conflict
7613     flags = ["hugeFeatures" "gtkGUI" "x11Support"
7614       /*"perlSupport"*/ "pythonSupport" "tclSupport"];
7615   };
7617   vim_configurable = import ../applications/editors/vim/configurable.nix {
7618     inherit fetchurl stdenv ncurses pkgconfig composableDerivation lib;
7619     inherit (xlibs) libX11 libXext libSM libXpm
7620         libXt libXaw libXau libXmu;
7621     inherit (gtkLibs) glib gtk;
7622     features = "huge"; # one of  tiny, small, normal, big or huge
7623     # optional features by passing
7624     # python
7625     # TODO mzschemeinterp perlinterp
7626     inherit python perl tcl ruby /*x11*/;
7628     # optional features by flags
7629     flags = [ "X11" ]; # only flag "X11" by now
7630   };
7632   vlc = import ../applications/video/vlc {
7633     inherit fetchurl stdenv perl xlibs zlib a52dec libmad faad2
7634       ffmpeg libdvdnav pkgconfig hal fribidi qt4 freefont_ttf;
7635     dbus = dbus.libs;
7636     alsa = alsaLib;
7637   };
7639   vnstat = import ../applications/networking/vnstat {
7640     inherit fetchurl stdenv ncurses;
7641   };
7643   vorbisTools = import ../applications/audio/vorbis-tools {
7644     inherit fetchurl stdenv libogg libvorbis libao pkgconfig curl glibc
7645       speex flac;
7646   };
7648   vwm = import ../applications/window-managers/vwm {
7649     inherit fetchurl stdenv ncurses pkgconfig libviper libpseudo gpm glib libvterm;
7650   };
7652   w3m = import ../applications/networking/browsers/w3m {
7653     inherit fetchurl stdenv ncurses openssl boehmgc gettext zlib imlib2 x11;
7654     graphicsSupport = false;
7655   };
7657   # I'm keen on wmiimenu only  >wmii-3.5 no longer has it...
7658   wmiimenu = import ../applications/window-managers/wmii31 {
7659     libixp = libixp_for_wmii;
7660     inherit fetchurl /* fetchhg */ stdenv gawk;
7661     inherit (xlibs) libX11;
7662   };
7664   wmiiSnap = import ../applications/window-managers/wmii {
7665     libixp = libixp_for_wmii;
7666     inherit fetchurl /* fetchhg */ stdenv gawk;
7667     inherit (xlibs) libX11 xextproto libXt libXext;
7668     includeUnpack = getConfig ["stdenv" "includeUnpack"] false;
7669   };
7671   wordnet = import ../applications/misc/wordnet {
7672     inherit stdenv fetchurl tcl tk x11 makeWrapper;
7673   };
7675   wrapFirefox = browser: browserName: nameSuffix: import ../applications/networking/browsers/firefox/wrapper.nix {
7676     inherit stdenv nameSuffix makeWrapper makeDesktopItem browser browserName;
7677     plugins =
7678       let enableAdobeFlash = getConfig [ browserName "enableAdobeFlash" ] true;
7679       in
7680        ([]
7681         ++ lib.optional (!enableAdobeFlash) gnash
7682         ++ lib.optional enableAdobeFlash flashplayer
7683         # RealPlayer is disabled by default for legal reasons.
7684         ++ lib.optional (system != "i686-linux" && getConfig [browserName "enableRealPlayer"] false) RealPlayer
7685         ++ lib.optional (getConfig [browserName "enableMPlayer"] false) (MPlayerPlugin browser)
7686         ++ lib.optional (getConfig [browserName "enableGeckoMediaPlayer"] false) gecko_mediaplayer
7687         ++ lib.optional (supportsJDK && getConfig [browserName "jre"] false && jrePlugin ? mozillaPlugin) jrePlugin
7688        );
7689   };
7691   x11vnc = composedArgsAndFun (import ../tools/X11/x11vnc/0.9.3.nix) {
7692     inherit builderDefs openssl zlib libjpeg ;
7693     inherit (xlibs) libXfixes fixesproto libXdamage damageproto
7694       libX11 xproto libXtst libXinerama xineramaproto libXrandr randrproto
7695       libXext xextproto inputproto recordproto libXi renderproto
7696       libXrender;
7697   };
7699   x2vnc = composedArgsAndFun (import ../tools/X11/x2vnc/1.7.2.nix) {
7700     inherit builderDefs;
7701     inherit (xlibs) libX11 xproto xextproto libXext libXrandr randrproto;
7702   };
7704   xaos = builderDefsPackage (import ../applications/graphics/xaos) {
7705     inherit (xlibs) libXt libX11 libXext xextproto xproto;
7706     inherit gsl aalib zlib libpng intltool gettext perl;
7707   };
7709   xara = import ../applications/graphics/xara {
7710     inherit fetchurl stdenv autoconf automake libtool gettext cvs
7711       pkgconfig libxml2 zip libpng libjpeg shebangfix perl freetype;
7712     inherit (gtkLibs) gtk;
7713     wxGTK = wxGTK26;
7714   };
7716   xawtv = import ../applications/video/xawtv {
7717     inherit fetchurl stdenv ncurses libjpeg perl;
7718     inherit (xlibs) libX11 libXt libXft xproto libFS fontsproto libXaw libXpm libXext libSM libICE xextproto;
7719   };
7721   xchat = import ../applications/networking/irc/xchat {
7722     inherit fetchurl stdenv pkgconfig tcl;
7723     inherit (gtkLibs) gtk;
7724   };
7726   xchm = import ../applications/misc/xchm {
7727     inherit fetchurl stdenv chmlib wxGTK;
7728   };
7730   /* Doesn't work yet
7732   xen = builderDefsPackage (import ../applications/virtualization/xen) {
7733     inherit python e2fsprogs gnutls pkgconfig libjpeg
7734       ncurses SDL libvncserver zlib;
7735     texLive = if (getConfig ["xen" "texLive"] false) then texLive else null;
7736     graphviz = if (getConfig ["xen" "graphviz"] false) then graphviz else null;
7737     ghostscript = if (getConfig ["xen" "ghostscript"] false) then ghostscript else null;
7738   }; */
7740   xfig = import ../applications/graphics/xfig {
7741     stdenv = overrideGCC stdenv gcc34;
7742     inherit fetchurl makeWrapper x11 Xaw3d libpng libjpeg;
7743     inherit (xlibs) imake libXpm libXmu libXi libXp;
7744   };
7746   xineUI = import ../applications/video/xine-ui {
7747     inherit fetchurl stdenv pkgconfig xlibs xineLib libpng readline ncurses curl;
7748   };
7750   xmms = import ../applications/audio/xmms {
7751     inherit fetchurl libogg libvorbis alsaLib;
7752     inherit (gnome) esound;
7753     inherit (gtkLibs1x) glib gtk;
7754     stdenv = overrideGCC stdenv gcc34; # due to problems with gcc 4.x
7755   };
7757   xneur = import ../applications/misc/xneur {
7758     inherit fetchurl stdenv pkgconfig pcre libxml2 aspell imlib2
7759       xosd libnotify cairo;
7760     GStreamer=gst_all.gstreamer;
7761     inherit (xlibs) libX11 libXpm libXt libXext libXi;
7762     inherit (gtkLibs) glib gtk pango atk;
7763   };
7765   xneur_0_8 = import ../applications/misc/xneur/0.8.nix {
7766     inherit fetchurl stdenv pkgconfig pcre libxml2 aspell imlib2 xosd glib;
7767     GStreamer = gst_all.gstreamer;
7768     inherit (xlibs) libX11 libXpm libXt libXext;
7769   };
7771   xournal = builderDefsPackage (import ../applications/graphics/xournal) {
7772     inherit ghostscript fontconfig freetype zlib
7773       poppler popplerData autoconf automake
7774       libtool pkgconfig;
7775     inherit (xlibs) xproto libX11;
7776     inherit (gtkLibs) gtk atk pango glib;
7777     inherit (gnome) libgnomeprint libgnomeprintui
7778       libgnomecanvas;
7779   };
7781   xpdf = import ../applications/misc/xpdf {
7782     inherit fetchurl stdenv x11 freetype t1lib;
7783     motif = lesstif;
7784     base14Fonts = "${ghostscript}/share/ghostscript/fonts";
7785   };
7787   xpra = import ../tools/X11/xpra {
7788     inherit stdenv fetchurl pkgconfig python pygtk xlibs makeWrapper;
7789     inherit (gtkLibs) gtk;
7790     pyrex = pyrex095;
7791   };
7793   xscreensaverBase = composedArgsAndFun (import ../applications/graphics/xscreensaver) {
7794     inherit stdenv fetchurl builderDefs lib pkgconfig bc perl intltool;
7795     inherit (xlibs) libX11 libXmu;
7796   };
7798   xscreensaver = xscreensaverBase.passthru.function {
7799     flags = ["GL" "gdkpixbuf" "DPMS" "gui" "jpeg"];
7800     inherit mesa libxml2 libjpeg;
7801     inherit (gtkLibs) gtk;
7802     inherit (gnome) libglade;
7803   };
7805   xterm = import ../applications/misc/xterm {
7806     inherit fetchurl stdenv ncurses freetype pkgconfig;
7807     inherit (xlibs) libXaw xproto libXt libX11 libSM libICE libXext libXft luit;
7808   };
7810   xlaunch = import ../tools/X11/xlaunch {
7811     inherit stdenv;
7812     inherit (xorg) xorgserver;
7813   };
7815   xmacro = import ../tools/X11/xmacro {
7816     inherit fetchurl stdenv;
7817     inherit (xlibs) libX11 libXi libXtst xextproto inputproto;
7818   };
7820   xmove = import ../applications/misc/xmove {
7821     inherit fetchurl stdenv;
7822     inherit (xlibs) libX11 libXi imake libXau;
7823     inherit (xorg) xauth;
7824   };
7826   xnee = builderDefsPackage (import ../tools/X11/xnee) {
7827     inherit (gtkLibs) gtk;
7828     inherit (xlibs) libX11 libXtst xextproto libXext
7829       inputproto libXi xproto recordproto;
7830     inherit pkgconfig;
7831   };
7833   xvidcap = import ../applications/video/xvidcap {
7834     inherit fetchurl stdenv perl perlXMLParser pkgconfig gettext lame;
7835     inherit (gtkLibs) gtk;
7836     inherit (gnome) scrollkeeper libglade;
7837     inherit (xlibs) libXmu libXext libXfixes libXdamage libX11;
7838   };
7840   yate = import ../applications/misc/yate {
7841     inherit sox speex openssl automake autoconf pkgconfig;
7842     inherit fetchurl stdenv lib composableDerivation;
7843     qt = qt4;
7844   };
7846   # doesn't compile yet - in case someone else want's to continue ..
7847   qgis = (import ../applications/misc/qgis/1.0.1-2.nix) {
7848     inherit composableDerivation fetchsvn stdenv flex lib
7849             ncurses fetchurl perl cmake gdal geos proj x11
7850             gsl libpng zlib bison
7851             sqlite glibc fontconfig freetype /* use libc from stdenv ? - to lazy now - Marc */;
7852     inherit (xlibs) libSM libXcursor libXinerama libXrandr libXrender;
7853     inherit (xorg) libICE;
7854     qt = qt4;
7856     # optional features
7857     # grass = "not yet supported" # cmake -D WITH_GRASS=TRUE  and GRASS_PREFX=..
7858   };
7860   zapping = import ../applications/video/zapping {
7861     inherit fetchurl stdenv pkgconfig perl python
7862             gettext zvbi libjpeg libpng x11
7863             rte perlXMLParser;
7864     inherit (gnome) scrollkeeper libgnomeui libglade esound;
7865     inherit (xlibs) libXv libXmu libXext;
7866     teletextSupport = true;
7867     jpegSupport = true;
7868     pngSupport = true;
7869     recordingSupport = true;
7870   };
7873   ### GAMES
7875   ballAndPaddle = import ../games/ball-and-paddle {
7876     inherit fetchurl stdenv SDL SDL_image SDL_mixer SDL_ttf guile gettext;
7877   };
7879   bsdgames = import ../games/bsdgames {
7880     inherit fetchurl stdenv ncurses openssl flex bison miscfiles;
7881   };
7883   castleCombat = import ../games/castle-combat {
7884     inherit fetchurl stdenv python pygame twisted lib numeric makeWrapper;
7885   };
7887   construoBase = composedArgsAndFun (import ../games/construo/0.2.2.nix) {
7888     inherit stdenv fetchurl builderDefs
7889       zlib;
7890     inherit (xlibs) libX11 xproto;
7891   };
7893   construo = construoBase.passthru.function {
7894     inherit mesa freeglut;
7895   };
7897   eduke32 = import ../games/eduke32 {
7898     inherit stdenv fetchurl SDL SDL_mixer unzip libvorbis mesa pkgconfig nasm makeDesktopItem;
7899     inherit (gtkLibs) gtk;
7900   };
7902   exult = import ../games/exult {
7903     inherit fetchurl SDL SDL_mixer zlib libpng unzip;
7904     stdenv = overrideGCC stdenv gcc42;
7905   };
7907   /*
7908   exultSnapshot = lowPrio (import ../games/exult/snapshot.nix {
7909     inherit fetchurl stdenv SDL SDL_mixer zlib libpng unzip
7910       autoconf automake libtool flex bison;
7911   });
7912   */
7914   fsg = import ../games/fsg {
7915     inherit stdenv fetchurl pkgconfig mesa;
7916     inherit (gtkLibs) glib gtk;
7917     inherit (xlibs) libX11 xproto;
7918     wxGTK = wxGTK28.override {unicode = false;};
7919   };
7921   fsgAltBuild = import ../games/fsg/alt-builder.nix {
7922     inherit stdenv fetchurl mesa;
7923     wxGTK = wxGTK28.override {unicode = false;};
7924     inherit (xlibs) libX11 xproto;
7925     inherit stringsWithDeps builderDefs;
7926   };
7928   gemrb = import ../games/gemrb {
7929     inherit fetchurl stdenv SDL openal freealut zlib libpng python;
7930   };
7932   gnuchess = builderDefsPackage (import ../games/gnuchess) {
7933     flex = flex2535;
7934   };
7936   gparted = import ../tools/misc/gparted {
7937     inherit fetchurl stdenv parted intltool gettext libuuid pkgconfig libxml2;
7938     inherit (gtkLibs) gtk glib gtkmm;
7939     inherit (gnome) gnomedocutils;
7940   };
7942   hexen = import ../games/hexen {
7943     inherit stdenv fetchurl SDL;
7944   };
7946   kobodeluxe = import ../games/kobodeluxe {
7947     inherit stdenv fetchurl SDL SDL_image;
7948   };
7950   lincity = builderDefsPackage (import ../games/lincity) {
7951     inherit (xlibs) libX11 libXext xextproto
7952       libICE libSM xproto;
7953     inherit libpng zlib;
7954   };
7956   micropolis = import ../games/micropolis {
7957     inherit lib fetchurl stdenv;
7958     inherit (xlibs) libX11 libXpm libXext xextproto;
7959     inherit byacc bash;
7960   };
7962   openttd = import ../games/openttd {
7963     inherit fetchurl stdenv SDL libpng;
7964     zlib = zlibStatic;
7965   };
7967   quake3demo = import ../games/quake3/wrapper {
7968     name = "quake3-demo-${quake3game.name}";
7969     description = "Demo of Quake 3 Arena, a classic first-person shooter";
7970     inherit fetchurl stdenv mesa makeWrapper;
7971     game = quake3game;
7972     paks = [quake3demodata];
7973   };
7975   quake3demodata = import ../games/quake3/demo {
7976     inherit fetchurl stdenv;
7977   };
7979   quake3game = import ../games/quake3/game {
7980     inherit fetchurl stdenv x11 SDL mesa openal;
7981   };
7983   rogue = import ../games/rogue {
7984     inherit fetchurl stdenv ncurses;
7985   };
7987   scummvm = import ../games/scummvm {
7988     inherit fetchurl stdenv SDL zlib mpeg2dec;
7989   };
7991   scorched3d = import ../games/scorched3d {
7992     inherit stdenv fetchurl mesa openal autoconf automake libtool freealut freetype fftw SDL SDL_net zlib libpng libjpeg;
7993     wxGTK = wxGTK26;
7994   };
7996   sgtpuzzles = builderDefsPackage (import ../games/sgt-puzzles) {
7997     inherit (gtkLibs) gtk glib;
7998     inherit pkgconfig;
7999     inherit (xlibs) libX11;
8000   };
8002   # You still can override by passing more arguments.
8003   spaceOrbit = composedArgsAndFun (import ../games/orbit/1.01.nix) {
8004     inherit fetchurl stdenv builderDefs mesa freeglut;
8005     inherit (gnome) esound;
8006     inherit (xlibs) libXt libX11 libXmu libXi libXext;
8007   };
8009   superTuxKart = import ../games/super-tux-kart {
8010     inherit fetchurl stdenv plib SDL openal freealut mesa
8011       libvorbis libogg gettext;
8012   };
8014   teeworlds = import ../games/teeworlds {
8015     inherit fetchurl stdenv python alsaLib mesa SDL;
8016     inherit (xlibs) libX11;
8017   };
8019   /*tpm = import ../games/thePenguinMachine {
8020     inherit stdenv fetchurl pil pygame SDL;
8021     python24 = python;
8022   };*/
8024   ut2004demo = import ../games/ut2004demo {
8025     inherit fetchurl stdenv xlibs mesa;
8026   };
8028   xboard = builderDefsPackage (import ../games/xboard) {
8029     inherit (xlibs) libX11 xproto libXt libXaw libSM
8030       libICE libXmu libXext libXpm;
8031     inherit gnuchess texinfo;
8032   };
8034   xsokoban = builderDefsPackage (import ../games/xsokoban) {
8035     inherit (xlibs) libX11 xproto libXpm libXt;
8036   };
8038   zdoom = import ../games/zdoom {
8039     inherit cmake stdenv fetchsvn SDL nasm p7zip zlib flac fmod libjpeg;
8040   };
8042   zoom = import ../games/zoom {
8043     inherit fetchurl stdenv perl expat freetype;
8044     inherit (xlibs) xlibs;
8045   };
8047   keen4 = import ../games/keen4 {
8048     inherit fetchurl stdenv dosbox unzip;
8049   };
8052   ### DESKTOP ENVIRONMENTS
8055   enlightenment = import ../desktops/enlightenment {
8056     inherit stdenv fetchurl pkgconfig x11 xlibs dbus imlib2 freetype;
8057   };
8059   gnome28 = import ../desktops/gnome-2.28 pkgs;
8061   gnome = gnome28;
8063   kde3 = {
8065     kdelibs = import ../desktops/kde-3/kdelibs {
8066       inherit
8067         fetchurl stdenv xlibs zlib perl openssl pcre pkgconfig
8068         libjpeg libpng libtiff libxml2 libxslt libtool
8069         expat freetype bzip2 cups attr acl;
8070       qt = qt3;
8071     };
8073     kdebase = import ../desktops/kde-3/kdebase {
8074       inherit
8075         fetchurl stdenv pkgconfig x11 xlibs zlib libpng libjpeg perl
8076         kdelibs openssl bzip2 fontconfig pam hal dbus glib;
8077       qt = qt3;
8078     };
8080   };
8082   kde4 = kde43;
8084   kde43 = import ../desktops/kde-4.3 (pkgs // {
8085     openexr = openexr_1_6_1;
8086     qt4 = qt45;
8087     popplerQt4 = popplerQt45;
8088   });
8090   kdelibs = kde3.kdelibs;
8091   kdebase = kde3.kdebase;
8093   ### SCIENCE
8095   xplanet = import ../applications/science/xplanet {
8096     inherit stdenv fetchurl lib pkgconfig freetype libpng libjpeg giflib libtiff;
8097     inherit (gtkLibs) pango;
8098   };
8100   ### SCIENCE/GEOMETRY
8102   drgeo = builderDefsPackage (import ../applications/science/geometry/drgeo) {
8103     inherit (gnome) libglade gtk;
8104     inherit libxml2 guile perl intltool libtool pkgconfig;
8105   };
8108   ### SCIENCE/BIOLOGY
8110   alliance = import ../applications/science/electronics/alliance {
8111     inherit fetchurl stdenv bison flex;
8112     inherit (xlibs) xproto libX11 libXt libXpm;
8113     motif = lesstif;
8114   };
8116   arb = import ../applications/science/biology/arb {
8117     inherit fetchurl readline libpng zlib x11 lesstif93 freeglut perl;
8118     inherit (xlibs) libXpm libXaw libX11 libXext libXt;
8119     inherit mesa glew libtiff lynx rxp sablotron jdk transfig gv gnuplot;
8120     lesstif = lesstif93;
8121     stdenv = overrideGCC stdenv gcc42;
8122   };
8124   biolib = import ../development/libraries/science/biology/biolib {
8125     inherit fetchurl stdenv readline perl cmake rLang zlib;
8126   };
8128   emboss = import ../applications/science/biology/emboss {
8129     inherit fetchurl stdenv readline perl libpng zlib;
8130     inherit (xorg) libX11 libXt;
8131   };
8133   mrbayes = import ../applications/science/biology/mrbayes {
8134     inherit fetchurl stdenv readline;
8135   };
8137   ncbi_tools = import ../applications/science/biology/ncbi-tools {
8138     inherit fetchurl stdenv cpio;
8139   };
8141   paml = import ../applications/science/biology/paml {
8142     inherit fetchurl stdenv;
8143   };
8145   /* slr = import ../applications/science/biology/slr {
8146     inherit fetchurl stdenv liblapack;
8147   }; */
8149   pal2nal = import ../applications/science/biology/pal2nal {
8150     inherit fetchurl stdenv perl paml;
8151   };
8154   ### SCIENCE/MATH
8156   atlas = import ../development/libraries/science/math/atlas {
8157     inherit fetchurl stdenv gfortran;
8158   };
8160   /* liblapack = import ../development/libraries/science/math/liblapack {
8161     inherit fetchurl stdenv gfortran;
8162   }; */
8165   ### SCIENCE/LOGIC
8167   coq = import ../applications/science/logic/coq {
8168     inherit stdenv fetchurl ocaml lablgtk ncurses;
8169     camlp5 = camlp5_transitional;
8170   };
8172   ssreflect = import ../applications/science/logic/ssreflect {
8173     inherit stdenv fetchurl ocaml coq;
8174     camlp5 = camlp5_transitional;
8175   };
8177   ### SCIENCE / ELECTRONICS
8179   ngspice = import ../applications/science/electronics/ngspice {
8180     inherit fetchurl stdenv readline;
8181   };
8184   ### SCIENCE / MATH
8186   maxima = import ../applications/science/math/maxima {
8187     inherit fetchurl stdenv clisp;
8188   };
8190   wxmaxima = import ../applications/science/math/wxmaxima {
8191     inherit fetchurl stdenv maxima;
8192     inherit wxGTK;
8193   };
8195   scilab = (import ../applications/science/math/scilab) {
8196     inherit stdenv fetchurl lib gfortran;
8197     inherit (gtkLibs) gtk;
8198     inherit ncurses Xaw3d tcl tk ocaml x11;
8200     withXaw3d = false;
8201     withTk = true;
8202     withGtk = false;
8203     withOCaml = true;
8204     withX = true;
8205   };
8208   ### MISC
8210   atari800 = import ../misc/emulators/atari800 {
8211     inherit fetchurl stdenv unzip zlib SDL;
8212   };
8214   ataripp = import ../misc/emulators/atari++ {
8215     inherit fetchurl stdenv x11 SDL;
8216   };
8218   auctex = import ../misc/tex/auctex {
8219     inherit stdenv fetchurl emacs texLive;
8220   };
8222   busybox = import ../misc/busybox {
8223     inherit fetchurl stdenv;
8224   };
8226   cups = import ../misc/cups {
8227     inherit fetchurl stdenv pkgconfig zlib libjpeg libpng libtiff pam openssl dbus;
8228   };
8230   gutenprint = import ../misc/drivers/gutenprint {
8231     inherit fetchurl stdenv lib pkgconfig composableDerivation cups libtiff libpng
8232       openssl git gimp;
8233   };
8235   gutenprintBin = import ../misc/drivers/gutenprint/bin.nix {
8236     inherit fetchurl stdenv rpm cpio zlib;
8237   };
8239   cupsBjnp = import ../misc/cups/drivers/cups-bnjp {
8240     inherit fetchurl stdenv cups;
8241   };
8243   dblatex = import ../misc/tex/dblatex {
8244     inherit fetchurl stdenv python libxslt tetex;
8245   };
8247   dosbox = import ../misc/emulators/dosbox {
8248     inherit fetchurl stdenv SDL makeDesktopItem;
8249   };
8251   dpkg = import ../tools/package-management/dpkg {
8252     inherit fetchurl stdenv perl zlib bzip2;
8253   };
8255   electricsheep = import ../misc/screensavers/electricsheep {
8256     inherit fetchurl stdenv pkgconfig expat zlib libpng libjpeg xlibs;
8257   };
8259   foldingathome = import ../misc/foldingathome {
8260       inherit fetchurl stdenv;
8261     };
8263   freestyle = import ../misc/freestyle {
8264     inherit fetchurl freeglut qt4 libpng lib3ds libQGLViewer swig;
8265     inherit (xlibs) libXi;
8266     #stdenv = overrideGCC stdenv gcc41;
8267     inherit stdenv python;
8268   };
8270   gajim = builderDefsPackage (import ../applications/networking/instant-messengers/gajim) {
8271     inherit perl intltool pyGtkGlade gettext pkgconfig makeWrapper pygobject
8272       pyopenssl gtkspell libsexy pycrypto aspell pythonDBus pythonSexy
8273       docutils;
8274     dbus = dbus.libs;
8275     inherit (gnome) gtk libglade;
8276     inherit (xlibs) libXScrnSaver libXt xproto libXext xextproto libX11
8277       scrnsaverproto;
8278     python = pythonFull;
8279   };
8281   generator = import ../misc/emulators/generator {
8282     inherit fetchurl stdenv SDL nasm zlib bzip2 libjpeg;
8283     inherit (gtkLibs1x) gtk;
8284   };
8286   ghostscript = makeOverridable (import ../misc/ghostscript) {
8287     inherit fetchurl stdenv libjpeg libpng libtiff zlib x11 pkgconfig
8288       fontconfig cups openssl;
8289     x11Support = false;
8290     cupsSupport = getPkgConfig "ghostscript" "cups" true;
8291   };
8293   ghostscriptX = lowPrio (appendToName "with-X" (ghostscript.override {
8294     x11Support = true;
8295   }));
8297   gxemul = (import ../misc/gxemul) {
8298     inherit lib stdenv fetchurl composableDerivation;
8299     inherit (xlibs) libX11;
8300   };
8302   # using the new configuration style proposal which is unstable
8303   jackaudio = import ../misc/jackaudio {
8304     inherit composableDerivation
8305            ncurses lib stdenv fetchurl alsaLib pkgconfig;
8306     flags = [ "posix_shm" "timestamps" "alsa"];
8307   };
8309   keynav = import ../tools/X11/keynav {
8310     inherit stdenv fetchurl;
8311     inherit (xlibs) libX11 xextproto libXtst imake libXi libXext;
8312   };
8314   lazylist = import ../misc/tex/lazylist {
8315     inherit fetchurl stdenv tetex;
8316   };
8318   lilypond = import ../misc/lilypond {
8319     inherit (bleedingEdgeRepos) sourceByName;
8320     inherit fetchurl stdenv lib automake autoconf
8321       ghostscript texinfo imagemagick texi2html guile python gettext
8322       perl bison pkgconfig texLive fontconfig freetype fontforge help2man;
8323     inherit (gtkLibs) pango;
8324     flex = flex2535;
8325   };
8327   linuxwacom = import ../misc/linuxwacom {
8328     inherit fetchurl stdenv ncurses pkgconfig;
8329     inherit (xorg) libX11 libXi xproto inputproto xorgserver;
8330   };
8332   martyr = import ../development/libraries/martyr {
8333     inherit stdenv fetchurl apacheAnt;
8334   };
8336   maven = import ../misc/maven/maven-1.0.nix {
8337     inherit stdenv fetchurl jdk;
8338   };
8340   maven2 = import ../misc/maven {
8341     inherit stdenv fetchurl jdk makeWrapper;
8342   };
8344   nix = makeOverridable (import ../tools/package-management/nix) {
8345     inherit fetchurl stdenv perl curl bzip2 openssl;
8346     aterm = aterm242fixes;
8347     db4 = db45;
8348     supportOldDBs = getPkgConfig "nix" "OldDBSupport" true;
8349     storeDir = getPkgConfig "nix" "storeDir" "/nix/store";
8350     stateDir = getPkgConfig "nix" "stateDir" "/nix/var";
8351   };
8353   # The bleeding edge.
8354   nixUnstable = makeOverridable (import ../tools/package-management/nix/unstable.nix) {
8355     inherit fetchurl stdenv perl curl bzip2 openssl;
8356     aterm = aterm242fixes;
8357     storeDir = getPkgConfig "nix" "storeDir" "/nix/store";
8358     stateDir = getPkgConfig "nix" "stateDir" "/nix/var";
8359   };
8361   nixCustomFun = src: preConfigure: enableScripts: configureFlags:
8362     import ../tools/package-management/nix/custom.nix {
8363       inherit fetchurl stdenv perl curl bzip2 openssl src preConfigure automake
8364         autoconf libtool configureFlags enableScripts lib bison libxml2;
8365       flex = flex2533;
8366       aterm = aterm242fixes;
8367       db4 = db45;
8368       inherit docbook5_xsl libxslt docbook5 docbook_xml_dtd_43 w3m;
8369     };
8371   disnix = import ../tools/package-management/disnix {
8372     inherit stdenv fetchsvn openssl autoconf automake libtool pkgconfig dbus_glib libxml2;
8373   };
8375   disnix_activation_scripts = import ../tools/package-management/disnix/activation-scripts {
8376     inherit stdenv fetchsvn autoconf automake;
8377   };
8379   DisnixService = import ../tools/package-management/disnix/DisnixService {
8380     inherit stdenv fetchsvn apacheAnt jdk axis2 shebangfix;
8381   };
8383   pgadmin = import ../applications/misc/pgadmin {
8384     inherit fetchurl stdenv postgresql libxml2 libxslt openssl;
8385     inherit wxGTK;
8386   };
8388   pgf = pgf2;
8390   # Keep the old PGF since some documents don't render properly with
8391   # the new one.
8392   pgf1 = import ../misc/tex/pgf/1.x.nix {
8393     inherit fetchurl stdenv;
8394   };
8396   pgf2 = import ../misc/tex/pgf/2.x.nix {
8397     inherit fetchurl stdenv;
8398   };
8400   polytable = import ../misc/tex/polytable {
8401     inherit fetchurl stdenv tetex lazylist;
8402   };
8404   psi = (import ../applications/networking/instant-messengers/psi) {
8405     inherit stdenv fetchurl zlib aspell sox qt4;
8406     inherit (xlibs) xproto libX11 libSM libICE;
8407     qca2 = kde4.qca2;
8408   };
8410   putty = import ../applications/networking/remote/putty {
8411     inherit stdenv fetchurl ncurses;
8412     inherit (gtkLibs1x) gtk;
8413   };
8415   rssglx = import ../misc/screensavers/rss-glx {
8416     inherit fetchurl stdenv x11 mesa pkgconfig imagemagick libtiff bzip2;
8417   };
8419   xlockmore = import ../misc/screensavers/xlockmore {
8420     inherit fetchurl stdenv x11 freetype;
8421     pam = if getPkgConfig "xlockmore" "pam" true then pam else null;
8422   };
8424   saneBackends = import ../misc/sane-backends {
8425     inherit fetchurl stdenv libusb;
8426     gt68xxFirmware = getConfig ["sane" "gt68xxFirmware"] null;
8427   };
8429   saneFrontends = import ../misc/sane-front {
8430     inherit fetchurl stdenv pkgconfig libusb saneBackends;
8431     inherit (gtkLibs) gtk;
8432     inherit (xlibs) libX11;
8433   };
8435   sourceAndTags = import ../misc/source-and-tags {
8436     inherit pkgs stdenv unzip lib ctags;
8437     hasktags = haskellPackages.myhasktags;
8438   };
8440   synaptics = import ../misc/synaptics {
8441     inherit fetchurl stdenv pkgconfig;
8442     inherit (xlibs) libX11 libXi libXext pixman xf86inputevdev;
8443     inherit (xorg) xorgserver;
8444   };
8446   tetex = import ../misc/tex/tetex {
8447     inherit fetchurl stdenv flex bison zlib libpng ncurses ed;
8448   };
8450   texFunctions = import ../misc/tex/nix {
8451     inherit stdenv perl tetex graphviz ghostscript makeFontsConf imagemagick runCommand lib;
8452     inherit (haskellPackages) lhs2tex;
8453   };
8455   texLive = builderDefsPackage (import ../misc/tex/texlive) {
8456     inherit builderDefs zlib bzip2 ncurses libpng ed
8457       gd t1lib freetype icu perl ruby expat curl
8458       libjpeg bison;
8459     inherit (xlibs) libXaw libX11 xproto libXt libXpm
8460       libXmu libXext xextproto libSM libICE;
8461     flex = flex2535;
8462     ghostscript = ghostscriptX;
8463   };
8465   /* Look in configurations/misc/raskin.nix for usage example (around revisions
8466   where TeXLive was added)
8468   (texLiveAggregationFun {
8469     paths = [texLive texLiveExtra texLiveCMSuper
8470       texLiveBeamer
8471     ];
8472   })
8474   You need to use texLiveAggregationFun to regenerate, say, ls-R (TeX-related file list)
8475   Just installing a few packages doesn't work.
8476   */
8477   texLiveAggregationFun =
8478     (builderDefsPackage (import ../misc/tex/texlive/aggregate.nix));
8480   texLiveContext = builderDefsPackage (import ../misc/tex/texlive/context.nix) {
8481     inherit texLive;
8482   };
8484   texLiveExtra = builderDefsPackage (import ../misc/tex/texlive/extra.nix) {
8485     inherit texLive;
8486   };
8488   texLiveCMSuper = builderDefsPackage (import ../misc/tex/texlive/cm-super.nix) {
8489     inherit texLive;
8490   };
8492   texLiveLatexXColor = builderDefsPackage (import ../misc/tex/texlive/xcolor.nix) {
8493     inherit texLive;
8494   };
8496   texLivePGF = builderDefsPackage (import ../misc/tex/texlive/pgf.nix) {
8497     inherit texLiveLatexXColor texLive;
8498   };
8500   texLiveBeamer = builderDefsPackage (import ../misc/tex/texlive/beamer.nix) {
8501     inherit texLiveLatexXColor texLivePGF texLive;
8502   };
8504   toolbuslib = import ../development/libraries/toolbuslib {
8505     inherit stdenv fetchurl aterm;
8506   };
8508   trac = import ../misc/trac {
8509     inherit stdenv fetchurl python clearsilver makeWrapper
8510       sqlite subversion;
8511     inherit (pythonPackages) pysqlite;
8512   };
8514    vice = import ../misc/emulators/vice {
8515      inherit stdenv fetchurl lib perl gettext libpng giflib libjpeg alsaLib readline mesa;
8516      inherit pkgconfig SDL makeDesktopItem autoconf automake;
8517      inherit (gtkLibs) gtk;
8518    };
8520   wine =
8521     if system == "x86_64-linux" then
8522       # Can't build this in 64-bit; use a 32-bit build instead.
8523       (import ./all-packages.nix {system = "i686-linux";}).wine
8524       # some hackery to make nix-env show this package on x86_64...
8525       // {system = "x86_64-linux";}
8526     else
8527       import ../misc/emulators/wine {
8528         inherit fetchurl stdenv flex bison mesa ncurses
8529           libpng libjpeg alsaLib lcms xlibs freetype
8530           fontconfig fontforge libxml2 libxslt openssl;
8531       };
8533   xosd = import ../misc/xosd {
8534     inherit fetchurl stdenv;
8535     inherit (xlibs) libX11 libXext libXt xextproto xproto;
8536   };
8538   xsane = import ../misc/xsane {
8539     inherit fetchurl stdenv pkgconfig libusb
8540       saneBackends saneFrontends;
8541     inherit (gtkLibs) gtk;
8542     inherit (xlibs) libX11;
8543   };
8545   yafc = import ../applications/networking/yafc {
8546     inherit fetchurl stdenv readline openssh;
8547   };
8549   myEnvFun = import ../misc/my-env {
8550     inherit substituteAll pkgs;
8551     inherit (stdenv) mkDerivation;
8552   };
8554   misc = import ../misc/misc.nix { inherit pkgs stdenv; };
8556 }; in pkgs