Compare commits

..

1 Commits
0.12 ... 0.11

Author SHA1 Message Date
Eelco Dolstra
7eec5e69f8 svn path=/nixpkgs/branches/0.11-release/; revision=9310 2007-09-11 22:30:30 +00:00
2082 changed files with 35823 additions and 103996 deletions

View File

@@ -1 +1 @@
0.12
0.11

View File

@@ -16,7 +16,7 @@ NEWS_OPTS = \
--stringparam section.autolabel.max.depth 0 \
--stringparam header.rule 0
all: NEWS.html NEWS.txt manual.html
all: NEWS.html NEWS.txt
NEWS.html: release-notes.xml
$(XSLTPROC) --nonet --xinclude --output $@ $(NEWS_OPTS) \
@@ -28,10 +28,3 @@ NEWS.txt: release-notes.xml
$(docbookxsl)/html/docbook.xsl -
LANG=en_US w3m -dump $@.tmp.html > $@
rm $@.tmp.html
manual.html: *.xml
$(XSLTPROC) --nonet --xinclude --output manual.html \
$(docbookxsl)/html/docbook.xsl manual.xml
manual.pdf: *.xml
dblatex manual.xml

View File

@@ -1,21 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="chap-introduction">
<title>Introduction</title>
<para>This manual tells you how to write packages for the Nix Packages
collection (Nixpkgs). Thus its for packagers and developers who want
to add packages to Nixpkgs. End users are kindly referred to the
<link xlink:href="http://nixos.org/releases/nix/unstable/manual/">Nix
manual</link>.</para>
<para>This manual does not describe the syntax and semantics of the
Nix expression language, which are given in the Nix manual in the
<link
xlink:href="http://nixos.org/releases/nix/unstable/manual/#chap-writing-nix-expressions">chapter
on writing Nix expressions</link>. It only describes the facilities
provided by Nixpkgs to make writing packages easier, such as the
standard build environment (<literal>stdenv</literal>).</para>
</chapter>

View File

@@ -1,185 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="chap-meta">
<title>Support for specific programming languages</title>
<para>The <link linkend="chap-stdenv">standard build
environment</link> makes it easy to build typical Autotools-based
packages with very little code. Any other kind of package can be
accomodated by overriding the appropriate phases of
<literal>stdenv</literal>. However, there are specialised functions
in Nixpkgs to easily build packages for other programming languages,
such as Perl or Haskell. These are described in this chapter.</para>
<section><title>Perl</title>
<para>Nixpkgs provides a function <varname>buildPerlPackage</varname>,
a generic package builder function for any Perl package that has a
standard <varname>Makefile.PL</varname>. Its implemented in <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/development/perl-modules/generic"><filename>pkgs/development/perl-modules/generic</filename></link>.</para>
<para>Perl packages from CPAN are defined in <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/top-level/perl-packages.nix"><filename>pkgs/perl-packages.nix</filename></link>,
rather than <filename>pkgs/all-packages.nix</filename>. Most Perl
packages are so straight-forward to build that they are defined here
directly, rather than having a separate function for each package
called from <filename>perl-packages.nix</filename>. However, more
complicated packages should be put in a separate file, typically in
<filename>pkgs/development/perl-modules</filename>. Here is an
example of the former:
<programlisting>
ClassC3 = buildPerlPackage rec {
name = "Class-C3-0.21";
src = fetchurl {
url = "mirror://cpan/authors/id/F/FL/FLORA/${name}.tar.gz";
sha256 = "1bl8z095y4js66pwxnm7s853pi9czala4sqc743fdlnk27kq94gz";
};
};
</programlisting>
Note the use of <literal>mirror://cpan/</literal>, and the
<literal>${name}</literal> in the URL definition to ensure that the
name attribute is consistent with the source that were actually
downloading. Perl packages are made available in
<filename>all-packages.nix</filename> through the variable
<varname>perlPackages</varname>. For instance, if you have a package
that needs <varname>ClassC3</varname>, you would typically write
<programlisting>
foo = import ../path/to/foo.nix {
inherit stdenv fetchurl ...;
inherit (perlPackages) ClassC3;
};
</programlisting>
in <filename>all-packages.nix</filename>. You can test building a
Perl package as follows:
<screen>
$ nix-build -A perlPackages.ClassC3
</screen>
<varname>buildPerlPackage</varname> adds <literal>perl-</literal> to
the start of the name attribute, so the package above is actually
called <literal>perl-Class-C3-0.21</literal>. So to install it, you
can say:
<screen>
$ nix-env -i perl-Class-C3
</screen>
(Of course you can also install using the attribute name:
<literal>nix-env -i -A perlPackages.ClassC3</literal>.)</para>
<para>So what does <varname>buildPerlPackage</varname> do? It does
the following:
<orderedlist>
<listitem><para>In the configure phase, it calls <literal>perl
Makefile.PL</literal> to generate a Makefile. You can set the
variable <varname>makeMakerFlags</varname> to pass flags to
<filename>Makefile.PL</filename></para></listitem>
<listitem><para>It adds the contents of the <envar>PERL5LIB</envar>
environment variable to <literal>#! .../bin/perl</literal> line of
Perl scripts as <literal>-I<replaceable>dir</replaceable></literal>
flags. This ensures that a script can find its
dependencies.</para></listitem>
<listitem><para>In the fixup phase, it writes the propagated build
inputs (<varname>propagatedBuildInputs</varname>) to the file
<filename>$out/nix-support/propagated-user-env-packages</filename>.
<command>nix-env</command> recursively installs all packages listed
in this file when you install a package that has it. This ensures
that a Perl package can find its dependencies.</para></listitem>
</orderedlist>
</para>
<para><varname>buildPerlPackage</varname> is built on top of
<varname>stdenv</varname>, so everything can be customised in the
usual way. For instance, the <literal>BerkeleyDB</literal> module has
a <varname>preConfigure</varname> hook to generate a configuration
file used by <filename>Makefile.PL</filename>:
<programlisting>
{buildPerlPackage, fetchurl, db4}:
buildPerlPackage rec {
name = "BerkeleyDB-0.36";
src = fetchurl {
url = "mirror://cpan/authors/id/P/PM/PMQS/${name}.tar.gz";
sha256 = "07xf50riarb60l1h6m2dqmql8q5dij619712fsgw7ach04d8g3z1";
};
preConfigure = ''
echo "LIB = ${db4}/lib" > config.in
echo "INCLUDE = ${db4}/include" >> config.in
'';
}
</programlisting>
</para>
<para>Dependencies on other Perl packages can be specified in the
<varname>buildInputs</varname> and
<varname>propagatedBuildInputs</varname> attributes. If something is
exclusively a build-time dependency, use
<varname>buildInputs</varname>; if its (also) a runtime dependency,
use <varname>propagatedBuildInputs</varname>. For instance, this
builds a Perl module that has runtime dependencies on a bunch of other
modules:
<programlisting>
ClassC3Componentised = buildPerlPackage rec {
name = "Class-C3-Componentised-1.0004";
src = fetchurl {
url = "mirror://cpan/authors/id/A/AS/ASH/${name}.tar.gz";
sha256 = "0xql73jkcdbq4q9m0b0rnca6nrlvf5hyzy8is0crdk65bynvs8q1";
};
propagatedBuildInputs = [
ClassC3 ClassInspector TestException MROCompat
];
};
</programlisting>
</para>
</section>
<section><title>Python</title>
<para>TODO</para>
</section>
<section><title>Haskell</title>
<para>TODO</para>
</section>
<section><title>Java</title>
<para>TODO; Java support needs lots of improvement</para>
</section>
<section><title>TeX / LaTeX</title>
<para>* Special support for building TeX documents</para>
</section>
</chapter>

View File

@@ -1,39 +0,0 @@
<book xmlns="http://docbook.org/ns/docbook"
xmlns:xi="http://www.w3.org/2001/XInclude">
<info>
<title>Nixpkgs Manual</title>
<subtitle>Draft (Version <xi:include href="../VERSION"
parse="text" />)</subtitle>
<author>
<personname>
<firstname>Eelco</firstname>
<surname>Dolstra</surname>
</personname>
<affiliation>
<orgname>Delft University of Technology</orgname>
<orgdiv>Department of Software Technology</orgdiv>
</affiliation>
</author>
<copyright>
<year>2008</year>
<holder>Eelco Dolstra</holder>
</copyright>
<date>June 2008</date>
</info>
<xi:include href="introduction.xml" />
<xi:include href="quick-start.xml" />
<xi:include href="stdenv.xml" />
<xi:include href="meta.xml" />
<xi:include href="language-support.xml" />
<xi:include href="package-notes.xml" />
</book>

View File

@@ -1,208 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="chap-meta">
<title>Meta-attributes</title>
<para>Nix packages can declare <emphasis>meta-attributes</emphasis>
that contain information about a package such as a description, its
homepage, its license, and so on. For instance, the GNU Hello package
has a <varname>meta</varname> declaration like this:
<programlisting>
meta = {
description = "A program that produces a familiar, friendly greeting";
longDescription = ''
GNU Hello is a program that prints "Hello, world!" when you run it.
It is fully customizable.
'';
homepage = http://www.gnu.org/software/hello/manual/;
license = "GPLv3+";
};
</programlisting>
</para>
<para>Meta-attributes are not passed to the builder of the package.
Thus, a change to a meta-attribute doesnt trigger a recompilation of
the package. The value of a meta-attribute must a string.</para>
<para>The meta-attributes of a package can be queried from the
command-line using <command>nix-env</command>:
<screen>
$ nix-env -qa hello --meta --xml
&lt;?xml version='1.0' encoding='utf-8'?>
&lt;items>
&lt;item attrPath="hello" name="hello-2.3" system="i686-linux">
&lt;meta name="description" value="A program that produces a familiar, friendly greeting" />
&lt;meta name="homepage" value="http://www.gnu.org/software/hello/manual/" />
&lt;meta name="license" value="GPLv3+" />
&lt;meta name="longDescription" value="GNU Hello is a program that prints &amp;quot;Hello, world!&amp;quot; when you run it.&amp;#xA;It is fully customizable.&amp;#xA;" />
&lt;/item>
&lt;/items>
</screen>
<command>nix-env</command> knows about the
<varname>description</varname> field specifically:
<screen>
$ nix-env -qa hello --description
hello-2.3 A program that produces a familiar, friendly greeting
</screen>
</para>
<section><title>Standard meta-attributes</title>
<para>The following meta-attributes have a standard
interpretation:</para>
<variablelist>
<varlistentry>
<term><varname>description</varname></term>
<listitem><para>A short (one-line) description of the package.
This is shown by <command>nix-env -q --description</command> and
also on the Nixpkgs release pages.</para>
<para>Dont include a period at the end. Dont include newline
characters. Capitalise the first character. For brevity, dont
repeat the name of package — just describe what it does.</para>
<para>Wrong: <literal>"libpng is a library that allows you to decode PNG images."</literal></para>
<para>Right: <literal>"A library for decoding PNG images"</literal></para>
</listitem>
</varlistentry>
<varlistentry>
<term><varname>longDescription</varname></term>
<listitem><para>An arbitrarily long description of the
package.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>homepage</varname></term>
<listitem><para>The packages homepage. Example:
<literal>http://www.gnu.org/software/hello/manual/</literal></para></listitem>
</varlistentry>
<varlistentry>
<term><varname>license</varname></term>
<listitem><para>The license for the package. See below for the
allowed values.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>priority</varname></term>
<listitem><para>The <emphasis>priority</emphasis> of the package,
used by <command>nix-env</command> to resolve file name conflicts
between packages. See the Nix manual page for
<command>nix-env</command> for details. Example:
<literal>"10"</literal> (a low-priority
package).</para></listitem>
</varlistentry>
</variablelist>
</section>
<section><title>Licenses</title>
<note><para>This is just a first attempt at standardising the license
attribute.</para></note>
<para>The <varname>meta.license</varname> attribute must be one of the
following:
<variablelist>
<varlistentry>
<term><varname>GPL</varname></term>
<listitem><para>GNU General Public License; version not
specified.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>GPLv2</varname></term>
<listitem><para>GNU General Public License, version
2.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>GPLv2+</varname></term>
<listitem><para>GNU General Public License, version
2 or higher.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>GPLv3</varname></term>
<listitem><para>GNU General Public License, version
3.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>GPLv3+</varname></term>
<listitem><para>GNU General Public License, version
3 or higher.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>free</varname></term>
<listitem><para>Catch-all for free software licenses not listed
above.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>free-copyleft</varname></term>
<listitem><para>Catch-all for free, copyleft software licenses not
listed above.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>unfree-redistributable</varname></term>
<listitem><para>Unfree package that can be redistributed in binary
form. That is, its legal to redistribute the
<emphasis>output</emphasis> of the derivation. This means that
the package can be included in the Nixpkgs
channel.</para>
<para>Sometimes proprietary software can only be redistributed
unmodified. Make sure the builder doesnt actually modify the
original binaries; otherwise were breaking the license. For
instance, the NVIDIA X11 drivers can be redistributed unmodified,
but our builder applies <command>patchelf</command> to make them
work. Thus, its license is <varname>unfree</varname> and it
cannot be included in the Nixpkgs channel.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>unfree</varname></term>
<listitem><para>Unfree package that cannot be redistributed. You
can build it yourself, but you cannot redistribute the output of
the derivation. Thus it cannot be included in the Nixpkgs
channel.</para></listitem>
</varlistentry>
<varlistentry>
<term><varname>unfree-redistributable-firmware</varname></term>
<listitem><para>This package supplies unfree, redistributable
firmware. This is a separate value from
<varname>unfree-redistributable</varname> because not everybody
cares whether firmware is free.</para></listitem>
</varlistentry>
</variablelist>
</para>
</section>
</chapter>

View File

@@ -1,158 +0,0 @@
- The standard environment
(Some of this can be moved from the Nix manual)
- Special attributes
- Generic builder
- Helper functions
- GCC / ld wrapper (+ env vars)
- Phases (+ how to add phases) and hooks
- Override functions for stdenv
- Overriding GCC
- Overriding the setup script
- Predefined override functions in all-packages.nix: static binary
stdenv, dietlibc stdenv
- Stdenv bootstrap; how to update the Linux bootstrap binaries
- Specific platform notes (Linux, Native, Cygwin, Mingw)
- Support for specific languages
- Perl
- Generic Perl builder
- Python
- Wrapper generation
- Haskell
- TODO
- Java
- TODO; Java needs lots of improvement
- TeX/LaTeX
- Special support for building TeX documents
- Special kinds of applications
- OpenGL apps
- Binary-only apps
- Linux kernel modules
- Mozilla plugins/extensions
- X apps
- KDE apps
- GConf-based apps
- Programs that need wrappers
- makeWrapper etc.
- Initial ramdisks
- Library functions
- i.e. in lib/default.nix
- Specific package notes
- Linux kernel; how to update; feature tests
- X.org; how to update
- Gnome; how to update
- GCC?
- GHC?
- ...
- Meta attributes
- License attr; possible values
- Virtual machine support (for the build farm)
- vmtools
- KVM notes
- Performing a build in a VM
- In the host FS
- In a disk image
- RPM builds
- RPM image creation
- Deb builds
- Deb image creation
- Debugging VM builds
- Guidelines for Nixpkgs contributions
- File naming conventions
- Versioning of packages
- Tree organisation
- Variable naming
- Layout / indentations style
- Output FS hierarchy (e.g. $out/share/man instead of $out/man)
- Misc
- Building outside of the Nixpkgs tree
- Config options
- Downloading stuff
- fetchurl
- mirror:// scheme
- fetchsvn
- fetchcvs
- fetchdarcs
- Appendix: Nixpkgs config options

View File

@@ -1,239 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="chap-introduction">
<title>Package Notes</title>
<para>This chapter contains information about how to use and maintain
the Nix expressions for a number of specific packages, such as the
Linux kernel or X.org.</para>
<!--============================================================-->
<section>
<title>Linux kernel</title>
<para>The Nix expressions to build the Linux kernel are in <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/os-specific/linux/kernel"><filename>pkgs/os-specific/linux/kernel</filename></link>.</para>
<para>The function that builds the kernel has an argument
<varname>kernelPatches</varname> which should be a list of
<literal>{name, patch, extraConfig}</literal> attribute sets, where
<varname>name</varname> is the name of the patch (which is included in
the kernels <varname>meta.description</varname> attribute),
<varname>patch</varname> is the patch itself (possibly compressed),
and <varname>extraConfig</varname> (optional) is a string specifying
extra options to be concatenated to the kernel configuration file
(<filename>.config</filename>).</para>
<para>The kernel derivation exports an attribute
<varname>features</varname> specifying whether optional functionality
is or isnt enabled. This is used in NixOS to implement
kernel-specific behaviour. For instance, if the kernel has the
<varname>iwlwifi</varname> feature (i.e. has built-in support for
Intel wireless chipsets), then NixOS doesnt have to build the
external <varname>iwlwifi</varname> package:
<programlisting>
modulesTree = [kernel]
++ pkgs.lib.optional (!kernel.features ? iwlwifi) kernelPackages.iwlwifi
++ ...;
</programlisting>
</para>
<para>How to add a new (major) version of the Linux kernel to Nixpkgs:
<orderedlist>
<listitem>
<para>Copy (<command>svn cp</command>) the old Nix expression
(e.g. <filename>linux-2.6.21.nix</filename>) to the new one
(e.g. <filename>linux-2.6.22.nix</filename>) and update it.</para>
</listitem>
<listitem>
<para>Add the new kernel to <filename>all-packages.nix</filename>
(e.g., create an attribute
<varname>kernel_2_6_22</varname>).</para>
</listitem>
<listitem>
<para>Now were going to update the kernel configuration. First
unpack the kernel. Then for each supported platform
(<literal>i686</literal>, <literal>x86_64</literal>,
<literal>uml</literal>) do the following:
<orderedlist>
<listitem>
<para>Make an <command>svn copy</command> from the old
config (e.g. <filename>config-2.6.21-i686-smp</filename>) to
the new one
(e.g. <filename>config-2.6.22-i686-smp</filename>).</para>
</listitem>
<listitem>
<para>Copy the config file for this platform
(e.g. <filename>config-2.6.22-i686-smp</filename>) to
<filename>.config</filename> in the kernel source tree.
</para>
</listitem>
<listitem>
<para>Run <literal>make oldconfig
ARCH=<replaceable>{i386,x86_64,um}</replaceable></literal>
and answer all questions. (For the uml configuration, also
add <literal>SHELL=bash</literal>.) Make sure to keep the
configuration consistent between platforms (i.e. dont
enable some feature on <literal>i686</literal> and disable
it on <literal>x86_64</literal>).
</para>
</listitem>
<listitem>
<para>If needed you can also run <literal>make
menuconfig</literal>:
<screen>
$ nix-env -i ncurses
$ export NIX_CFLAGS_LINK=-lncurses
$ make menuconfig ARCH=<replaceable>arch</replaceable></screen>
</para>
</listitem>
<listitem>
<para>Make sure that
<literal>CONFIG_FB_TILEBLITTING</literal> is <emphasis>not
set</emphasis> (otherwise <command>fbsplash</command> won't
work). This option has a tendency to be enabled as a
side-effect of other options. If it is, investigate why
(there's probably another option that forces it to be on)
and fix it.</para>
</listitem>
<listitem>
<para>Copy <filename>.config</filename> over the new config
file (e.g. <filename>config-2.6.22-i686-smp</filename>).</para>
</listitem>
</orderedlist>
</para>
</listitem>
<listitem>
<para>Test building the kernel: <literal>nix-build -A
kernel_2_6_22</literal>. If it compiles, ship it! For extra
credit, try booting NixOS with it.</para>
</listitem>
<listitem>
<para>It may be that the new kernel requires updating the external
kernel modules and kernel-dependent packages listed in the
<varname>kernelPackagesFor</varname> function in
<filename>all-packages.nix</filename> (such as the NVIDIA drivers,
AUFS, splashutils, etc.). If the updated packages arent
backwards compatible with older kernels, you need to keep the
older versions and use some conditionals. For example, new
kernels require splashutils 1.5 while old kernel require 1.3, so
<varname>kernelPackagesFor</varname> says:
<programlisting>
splashutils =
if kernel.features ? fbSplash then splashutils_13 else
if kernel.features ? fbConDecor then splashutils_15 else
null;
splashutils_13 = ...;
splashutils_15 = ...;</programlisting>
</para>
</listitem>
</orderedlist>
</para>
</section>
<!--============================================================-->
<section>
<title>X.org</title>
<para>The Nix expressions for the X.org packages reside in
<filename>pkgs/servers/x11/xorg/default.nix</filename>. This file is
automatically generated from lists of tarballs in an X.org
release. As such it should not be modified directly; rather, you
should modify the lists or the generator script.</para>
<para>The generator is invoked as follows:
<screen>
$ cd pkgs/servers/x11/xorg
$ cat tarballs-7.4.list extra.list old.list \
| perl ./generate-expr-from-tarballs.pl
</screen>
For each of the tarballs in the <filename>.list</filename> files, the
script downloads it, unpacks it, and searches its
<filename>configure.ac</filename> and <filename>*.pc.in</filename>
files for dependencies. This information is used to generate
<filename>default.nix</filename>. The generator caches downloaded
tarballs between runs. Pay close attention to the <literal>NOT FOUND:
<replaceable>name</replaceable></literal> messages at the end of the
run, since they may indicate missing dependencies. (Some might be
optional dependencies, however.)</para>
<para>A file like <filename>tarballs-7.4.list</filename> contains all
tarballs in a X.org release. It can be generated like this:
<screen>
$ export i="mirror://xorg/X11R7.4/src/everything/"
$ cat $(PRINT_PATH=1 nix-prefetch-url $i | tail -n 1) \
| perl -e 'while (&lt;>) { if (/(href|HREF)="([^"]*.bz2)"/) { print "$ENV{'i'}$2\n"; }; }' \
| sort > tarballs-7.4.list
</screen>
<filename>extra.list</filename> contains libraries that arent part of
X.org proper, but are closely related to it, such as
<literal>libxcb</literal>. <filename>old.list</filename> contains
some packages that were removed from X.org, but are still needed by
some people or by other packages (such as
<varname>imake</varname>).</para>
<para>If the expression for a package requires derivation attributes
that the generator cannot figure out automatically (say,
<varname>patches</varname> or a <varname>postInstall</varname> hook),
you should modify the generator script
(<varname>generate-expr-from-tarballs.pl</varname>).</para>
</section>
<!--============================================================-->
<section>
<title>Gnome</title>
<para>* Expression is auto-generated</para>
<para>* How to update</para>
</section>
<!--============================================================-->
<section>
<title>GCC</title>
<para></para>
</section>
</chapter>

View File

@@ -1,240 +0,0 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xml:id="chap-overvie">
<title>Quick Start to Adding a Package</title>
<para>To add a package to Nixpkgs:
<orderedlist>
<listitem>
<para>Checkout the Nixpkgs source tree:
<screen>
$ svn checkout https://svn.nixos.org/repos/nix/nixpkgs/trunk nixpkgs
$ cd nixpkgs</screen>
</para>
</listitem>
<listitem>
<para>Find a good place in the Nixpkgs tree to add the Nix
expression for your package. For instance, a library package
typically goes into
<filename>pkgs/development/libraries/<replaceable>pkgname</replaceable></filename>,
while a web browser goes into
<filename>pkgs/applications/networking/browsers/<replaceable>pkgname</replaceable></filename>.
See Section XXX for some hints on the tree organisation. Create a
directory for your package, e.g.
<screen>
$ svn mkdir pkgs/development/libraries/libfoo</screen>
</para>
</listitem>
<listitem>
<para>In the package directory, create a Nix expression — a piece
of code that describes how to build the package. In this case, it
should be a <emphasis>function</emphasis> that is called with the
package dependencies as arguments, and returns a build of the
package in the Nix store. The expression should usually be called
<filename>default.nix</filename>.
<screen>
$ emacs pkgs/development/libraries/libfoo/default.nix
$ svn add pkgs/development/libraries/libfoo/default.nix</screen>
</para>
<para>You can have a look at the existing Nix expressions under
<filename>pkgs/</filename> to see how its done. Here are some
good ones:
<itemizedlist>
<listitem>
<para>GNU cpio: <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/tools/archivers/cpio/default.nix"><filename>pkgs/tools/archivers/cpio/default.nix</filename></link>.
The simplest possible package. The generic builder in
<varname>stdenv</varname> does everything for you. It has
no dependencies beyond <varname>stdenv</varname>.</para>
</listitem>
<listitem>
<para>GNU Hello: <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/applications/misc/hello/ex-2/default.nix"><filename>pkgs/applications/misc/hello/ex-2/default.nix</filename></link>.
Also trivial, but it specifies some <varname>meta</varname>
attributes which is good practice.</para>
</listitem>
<listitem>
<para>GNU Multiple Precision arithmetic library (GMP): <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/development/libraries/gmp/default.nix"><filename>pkgs/development/libraries/gmp/default.nix</filename></link>.
Also done by the generic builder, but has a dependency on
<varname>m4</varname>.</para>
</listitem>
<listitem>
<para>Pan, a GTK-based newsreader: <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/applications/networking/newsreaders/pan/default.nix"><filename>pkgs/applications/networking/newsreaders/pan/default.nix</filename></link>.
Has an optional dependency on <varname>gtkspell</varname>,
which is only built if <varname>spellCheck</varname> is
<literal>true</literal>.</para>
</listitem>
<listitem>
<para>Apache HTTPD: <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/servers/http/apache-httpd/default.nix"><filename>pkgs/servers/http/apache-httpd/default.nix</filename></link>.
A bunch of optional features, variable substitutions in the
configure flags, a post-install hook, and miscellaneous
hackery.</para>
</listitem>
<listitem>
<para>BitTorrent (wxPython-based): <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/tools/networking/p2p/bittorrent/default.nix"><filename>pkgs/tools/networking/p2p/bittorrent/default.nix</filename></link>.
Uses an external <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/tools/networking/p2p/bittorrent/builder.sh">build
script</link>, which can be useful if you have lots of code
that you dont want cluttering up the Nix expression. But
external builders are mostly obsolete.
</para>
</listitem>
<listitem>
<para>Firefox: <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/applications/networking/browsers/firefox-3/default.nix"><filename>pkgs/applications/networking/browsers/firefox-3/default.nix</filename></link>.
Lots of dependencies.</para>
</listitem>
<listitem>
<para>JDiskReport, a Java utility: <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/tools/misc/jdiskreport/default.nix"><filename>pkgs/tools/misc/jdiskreport/default.nix</filename></link>
(and the <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/tools/misc/jdiskreport/builder.sh">builder</link>).
Nixpkgs doesnt have a decent <varname>stdenv</varname> for
Java yet so this is pretty ad-hoc.</para>
</listitem>
<listitem>
<para>XML::Simple, a Perl module: <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/top-level/all-packages.nix"><filename>pkgs/top-level/all-packages.nix</filename></link>
(search for the <varname>perlXMLSimple</varname>
attribute). Most Perl modules are so simple to build that
they are defined directly in
<filename>all-packages.nix</filename>, no need to make a
separate file for them.</para>
</listitem>
<listitem>
<para>Adobe Reader: <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/applications/misc/acrobat-reader/default.nix"><filename>pkgs/applications/misc/acrobat-reader/default.nix</filename></link>.
Shows how binary-only packages can be supported. In
particular the <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/applications/misc/acrobat-reader/builder.sh">builder</link>
uses <command>patchelf</command> to set the RUNPATH and ELF
interpreter of the executables so that the right libraries
are found at runtime.</para>
</listitem>
</itemizedlist>
</para>
<para>Some notes:
<itemizedlist>
<listitem>
<para>All <varname>meta</varname> attributes are optional,
but its still a good idea to provide at least the
<varname>description</varname> and
<varname>homepage</varname>.</para>
</listitem>
<listitem>
<para>You can use <command>nix-prefetch-url</command>
<replaceable>url</replaceable> to get the SHA-256 hash of
source distributions.</para>
</listitem>
<listitem>
<para>A list of schemes for <literal>mirror://</literal>
URLs can be found in <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/build-support/fetchurl/mirrors.nix"><filename>pkgs/build-support/fetchurl/mirrors.nix</filename></link>.</para>
</listitem>
</itemizedlist>
</para>
<para>The exact syntax and semantics of the Nix expression
language, including the built-in function, are described in the
Nix manual in the <link
xlink:href="http://nixos.org/releases/nix/unstable/manual/#chap-writing-nix-expressions">chapter
on writing Nix expressions</link>.</para>
</listitem>
<listitem>
<para>Add a call to the function defined in the previous step to
<link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/top-level/all-packages.nix"><filename>pkgs/top-level/all-packages.nix</filename></link>
with some descriptive name for the variable,
e.g. <varname>libfoo</varname>.
<screen>
$ emacs pkgs/top-level/all-packages.nix</screen>
</para>
<para>The attributes in that file are sorted by category (like
“Development / Libraries”) that more-or-less correspond to the
directory structure of Nixpkgs, and then by attribute name.</para>
</listitem>
<listitem>
<para>Test whether the package builds:
<screen>
$ nix-build -A libfoo</screen>
where <varname>libfoo</varname> should be the variable name
defined in the previous step. You may want to add the flag
<option>-K</option> to keep the temporary build directory in case
something fails. If the build succeeds, a symlink
<filename>./result</filename> to the package in the Nix store is
created.</para>
</listitem>
<listitem>
<para>If you want to install the package into your profile
(optional), do
<screen>
$ nix-env -f . -iA libfoo</screen>
</para>
</listitem>
<listitem>
<para>Optionally commit the new package (<command>svn
ci</command>) or send a patch to
<literal>nix-dev@cs.uu.nl</literal>.</para>
</listitem>
<listitem>
<para>If you want the TU Delft build farm to build binaries of the
package and make them available in the <link
xlink:href="http://nixos.org/releases/nixpkgs/channels/nixpkgs-unstable/"><literal>nixpkgs</literal>
channel</link>, add it to <link
xlink:href="https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/top-level/build-for-release.nix"><filename>pkgs/top-level/build-for-release.nix</filename></link>.</para>
</listitem>
</orderedlist>
</para>
</chapter>

View File

@@ -5,94 +5,6 @@
<title>Nixpkgs Release Notes</title>
<section><title>Release 0.12 (April 24, 2009)</title>
<para>There are way too many additions to Nixpkgs since the last
release to list here: for example, the number of packages on Linux has
increased from 1002 to 2159. However, some specific improvements are
worth listing:
<itemizedlist>
<listitem><para>Nixpkgs now has a manual. In particular, it
describes the standard build environment in
detail.</para></listitem>
<listitem><para>Major new packages:
<itemizedlist>
<listitem><para>KDE 4.</para></listitem>
<listitem><para>TeXLive.</para></listitem>
<listitem><para>VirtualBox.</para></listitem>
</itemizedlist>
… and many others.
</para></listitem>
<listitem><para>Important updates:
<itemizedlist>
<listitem><para>Glibc 2.7.</para></listitem>
<listitem><para>GCC 4.2.4.</para></listitem>
<listitem><para>Linux 2.6.25 — 2.6.28.</para></listitem>
<listitem><para>Firefox 3.</para></listitem>
<listitem><para>X.org 7.3.</para></listitem>
</itemizedlist>
</para></listitem>
<listitem><para>Support for building derivations in a virtual
machine, including RPM and Debian builds in automatically generated
VM images. See
<filename>pkgs/build-support/vm.default.nix</filename> for
details.</para></listitem>
<listitem><para>Improved support for building Haskell
packages.</para></listitem>
</itemizedlist>
</para>
<para>The following people contributed to this release:
Andres Löh,
Arie Middelkoop,
Armijn Hemel,
Eelco Dolstra,
Lluís Batlle,
Ludovic Courtès,
Marc Weber,
Mart Kolthof,
Martin Bravenboer,
Michael Raskin,
Nicolas Pierron,
Peter Simons,
Pjotr Prins,
Rob Vermaas,
Sander van der Burg,
Tobias Hammerschmidt,
Valentin David,
Wouter den Breejen and
Yury G. Kudryashov.
In addition, several people contributed patches on the
<literal>nix-dev</literal> mailing list.</para>
</section>
<section><title>Release 0.11 (September 11, 2007)</title>
<para>This release has the following improvements:
@@ -197,12 +109,12 @@ fetchurl {
<function>fetchurl</function> will first try to download this file
from <link
xlink:href="http://nixos.org/tarballs/sha1/eb72f55e4a8bf08e8c6ef227c0ade3d068ba1082"/>.
xlink:href="http://nix.cs.uu.nl/dist/tarballs/sha1/eb72f55e4a8bf08e8c6ef227c0ade3d068ba1082"/>.
If that file doesnt exist, it will try the original URL. In
general, the “content-addressed” location is
<replaceable>mirror</replaceable><literal>/</literal><replaceable>hash-type</replaceable><literal>/</literal><replaceable>hash</replaceable>.
There is currently only one content-addressable mirror (<link
xlink:href="http://nixos.org/tarballs"/>), but more can be
xlink:href="http://nix.cs.uu.nl/dist/tarballs"/>), but more can be
specified in the <varname>hashedMirrors</varname> attribute in
<filename>pkgs/build-support/fetchurl/mirrors.nix</filename>, or by
setting the <envar>NIX_HASHED_MIRRORS</envar> environment variable
@@ -297,7 +209,7 @@ export NIX_MIRRORS_sourceforge=http://osdn.dl.sourceforge.net/sourceforge/</prog
<section><title>Release 0.10 (October 12, 2006)</title>
<note><para>This release of Nixpkgs requires <link
xlink:href='http://nixos.org/releases/nix/nix-0.10/'>Nix
xlink:href='http://nix.cs.uu.nl/dist/nix/nix-0.10/'>Nix
0.10</link> or higher.</para></note>
<para>This release has the following improvements:</para>
@@ -503,7 +415,7 @@ some of the more notable changes:</para>
<itemizedlist>
<listitem><para>Distribution files have been moved to <link
xlink:href="http://nixos.org/" />.</para></listitem>
xlink:href="http://nix.cs.uu.nl/" />.</para></listitem>
<listitem><para>The C library on Linux, Glibc, has been updated to
version 2.3.6.</para></listitem>

File diff suppressed because it is too large Load Diff

View File

@@ -1,101 +0,0 @@
Some conventions:
* Directories / file names: lowercase, and use dashes between words,
no camel case. I.e., all-packages.nix, not all allPackages.nix or
AllPackages.nix.
* Don't use TABs. Everybody has different TAB settings so it's asking
for trouble.
* Use 2 spaces of indentation per indentation level in Nix
expressions, 4 spaces in shell scripts. (Maybe 2 is too low, but
for consistency's sake it should be the same. Certainly indentation
should be consistent within a single file.)
* Use lowerCamelCase for variable names, not UpperCamelCase.
* Function calls with attribute set arguments are written as
foo {
arg = ...;
}
not
foo
{
arg = ...;
}
Also fine is
foo { arg = ...; }
if it's a short call.
* In attribute sets or lists that span multiple lines, the attribute
names or list elements should be aligned:
# A long list.
list = [
elem1
elem2
elem3
];
# A long attribute set.
attrs = {
attr1 = short_expr;
attr2 =
if true then big_expr else big_expr;
};
* Short lists or attribute sets can be written on one line:
# A short list.
list = [ elem1 elem2 elem3 ];
# A short set.
attrs = { x = 1280; y = 1024; };
* Breaking in the middle of a function argument can give hard-to-read
code, like
someFunction { x = 1280;
y = 1024; } otherArg
yetAnotherArg
(especially if the argument is very large, spanning multiple lines).
Better:
someFunction
{ x = 1280; y = 1024; }
otherArg
yetAnotherArg
or
let res = { x = 1280; y = 1024; };
in someFunction res otherArg yetAnotherArg
* The bodies of functions, asserts, and withs are not indented, so
assert system == "i686-linux";
stdenv.mkDerivation { ...
not
assert system == "i686-linux";
stdenv.mkDerivation { ...
* Function formal arguments are written as:
{arg1, arg2, arg3}:
but if they don't fit on one line they're written as:
{ arg1, arg2, arg3
, arg4, ...
, argN
}:

View File

@@ -8,7 +8,7 @@ find "$1" -name "*.nix" | while read fn; do
if url=$(echo "$line" | sed 's^url = \(.*\);^\1^'); then
if ! echo "$url" | grep -q -E "www.cs.uu.nl|nixos.org|.stratego-language.org|java.sun.com|ut2004|linuxq3a|RealPlayer|Adbe|belastingdienst|microsoft|armijn/.nix|sun.com|archive.eclipse.org"; then
if ! echo "$url" | grep -q -E "www.cs.uu.nl|nix.cs.uu.nl|.stratego-language.org|java.sun.com|ut2004|linuxq3a|RealPlayer|Adbe|belastingdienst|microsoft|armijn/.nix|sun.com|archive.eclipse.org"; then
base="$(basename "$url")"
newPath="$distDir/$base"
@@ -80,4 +80,4 @@ find "$1" -name "*.nix" | while read fn; do
done
echo DONE
echo DONE

View File

@@ -1,16 +0,0 @@
Choose the right CDROM reader syntax for `cd-paranoia'.
--- abcde-2.3.99.6/abcde 2006-08-05 21:14:00.000000000 +0200
+++ abcde-2.3.99.6/abcde 2008-10-29 22:55:38.000000000 +0100
@@ -3184,7 +3184,10 @@ if [ -n "$DISCID" ] || [ "$CDROMREADERSY
if [ "$CDROMREADERSYNTAX" = "" ]; then
for DEFAULT_CDROMREADER in $DEFAULT_CDROMREADERS; do
if new_checkexec $DEFAULT_CDROMREADER; then
- CDROMREADERSYNTAX=$DEFAULT_CDROMREADER
+ case "$DEFAULT_CDROMREADER" in
+ cd-paranoia) CDROMREADERSYNTAX=cdparanoia;;
+ *) CDROMREADERSYNTAX=$DEFAULT_CDROMREADER;;
+ esac
break
fi
done

View File

@@ -1,61 +0,0 @@
{ stdenv, fetchurl, libcdio, cddiscid, wget, bash, vorbisTools
, makeWrapper }:
let version = "2.3.99.6";
in
stdenv.mkDerivation {
name = "abcde-${version}";
src = fetchurl {
url = "mirror://debian/pool/main/a/abcde/abcde_${version}.orig.tar.gz";
sha256 = "1wl4ygj1cf1d6g05gwwygsd5g83l039fzi011r30ma5lnm763lyb";
};
# FIXME: This package does not support MP3 encoding (only Ogg),
# nor `distmp3', `eject', etc.
patches = [ ./install.patch ./which.patch ./cd-paranoia.patch ];
configurePhase = ''
sed -i "s|^[[:blank:]]*prefix *=.*$|prefix = $out|g ;
s|^[[:blank:]]*etcdir *=.*$|etcdir = $out/etc|g ;
s|^[[:blank:]]*INSTALL *=.*$|INSTALL = install -c|g" \
"Makefile";
# We use `cd-paranoia' from GNU libcdio, which contains a hyphen
# in its name, unlike Xiph's cdparanoia.
sed -i "s|^[[:blank:]]*CDPARANOIA=.*$|CDPARANOIA=cd-paranoia|g ;
s|^[[:blank:]]*DEFAULT_CDROMREADERS=.*$|DEFAULT_CDROMREADERS=\"cd-paranoia cdda2wav\"|g" \
"abcde"
substituteInPlace "abcde" \
--replace "/etc/abcde.conf" "$out/etc/abcde.conf"
'';
buildInputs = [ makeWrapper ];
postInstall = ''
substituteInPlace "$out/bin/cddb-tool" \
--replace '#!/bin/sh' '#!${bash}/bin/sh'
substituteInPlace "$out/bin/abcde" \
--replace '#!/bin/bash' '#!${bash}/bin/bash'
wrapProgram "$out/bin/abcde" --prefix PATH ":" \
"$out/bin:${libcdio}/bin:${cddiscid}/bin:${wget}/bin:${vorbisTools}/bin"
wrapProgram "$out/bin/cddb-tool" --prefix PATH ":" \
"${wget}/bin"
'';
meta = {
homepage = http://www.hispalinux.es/~data/abcde.php;
licence = "GPLv2+";
description = "A Better CD Encoder (ABCDE)";
longDescription = ''
abcde is a front-end command-line utility (actually, a shell
script) that grabs tracks off a CD, encodes them to
Ogg/Vorbis, MP3, FLAC, Ogg/Speex and/or MPP/MP+ (Musepack)
format, and tags them, all in one go.
'';
};
}

View File

@@ -1,21 +0,0 @@
--- abcde-2.3.3/Makefile~ 2005-08-26 00:43:27.000000000 +0200
+++ abcde-2.3.3/Makefile 2008-05-26 22:20:17.000000000 +0200
@@ -14,13 +14,13 @@ clean:
install:
$(INSTALL) -d -m 755 $(bindir)
- $(INSTALL) -m 755 -o 0 abcde $(bindir)
- $(INSTALL) -m 755 -o 0 cddb-tool $(bindir)
+ $(INSTALL) -m 755 abcde $(bindir)
+ $(INSTALL) -m 755 cddb-tool $(bindir)
$(INSTALL) -d -m 755 $(mandir)
- $(INSTALL) -m 644 -o 0 abcde.1 $(mandir)
- $(INSTALL) -m 644 -o 0 cddb-tool.1 $(mandir)
+ $(INSTALL) -m 644 abcde.1 $(mandir)
+ $(INSTALL) -m 644 cddb-tool.1 $(mandir)
$(INSTALL) -d -m 755 $(etcdir)
- $(INSTALL) -m 644 -o 0 abcde.conf $(etcdir)
+ $(INSTALL) -m 644 abcde.conf $(etcdir)
tarball:
@cd .. && tar czvf abcde_$(VERSION).orig.tar.gz \

View File

@@ -1,16 +0,0 @@
Add an alias for `which'.
--- abcde-2.3.99.6/abcde 2006-08-05 21:14:00.000000000 +0200
+++ abcde-2.3.99.6/abcde 2008-10-29 22:49:16.000000000 +0100
@@ -15,6 +15,11 @@
VERSION='2.3.99-$Revision: 222M $'
+which ()
+{
+ type -P $1
+}
+
usage ()
{
echo "This is abcde v$VERSION."

View File

@@ -1,32 +0,0 @@
{ stdenv, fetchurl, pkgconfig, glib, gtk, libmowgli
, libglade, libmcs, gettext, xlibs, dbus_glib
}:
stdenv.mkDerivation {
name = "audacious-1.5.1";
src = fetchurl {
url = http://distfiles.atheme.org/audacious-1.5.1.tbz2;
sha256 = "1s32pdgx85qkrq15wwmvdw7wbcbxcf3nrhqxi6y72aijqm6fjwnz";
};
buildInputs = [pkgconfig libglade libmcs gettext dbus_glib];
propagatedBuildInputs = [glib gtk libmowgli libmcs];
NIX_LDFLAGS = "-rpath ${xlibs.libX11}/lib";
# Otherwise we barf with "libgcc_s.so.1 must be installed for
# pthread_cancel to work" on exit, as it tries to find libgcc_s
# dynamically.
dontPatchELF = true;
preBuild = ''
ensureDir $out/lib
'';
meta = {
description = "Audacious, a media player forked from the Beep Media Player, which was itself an XMMS fork";
homepage = http://audacious-media-player.org/;
};
}

View File

@@ -1,33 +0,0 @@
{ stdenv, fetchurl, pkgconfig, audacious, dbus_glib, gettext
, libmad, xlibs, alsaLib, taglib, libmpcdec, libogg, libvorbis
, libcdio, libcddb
}:
stdenv.mkDerivation {
name = "audacious-plugins-1.5.1";
src = fetchurl {
url = http://distfiles.atheme.org/audacious-plugins-1.5.1.tbz2;
sha256 = "1ki5bd50g4vi4d0qzxynyrgaq2n4cwhbsxln9rwk8ppphvk9pawc";
};
buildInputs = [
pkgconfig audacious dbus_glib gettext libmad
xlibs.libXcomposite alsaLib taglib libmpcdec
libogg libvorbis libcdio libcddb
];
preBuild = ''
makeFlagsArray=(pluginlibdir=$out/lib/audacious)
'';
NIX_LDFLAGS = "-L${audacious}/lib/audacious"; # needed because we override pluginlibdir
# `--enable-amidiplug' is to prevent configure from looking in /proc/asound.
configureFlags = "--enable-amidiplug";
meta = {
description = "Plugins for the Audacious media player";
homepage = http://audacious-media-player.org/;
};
}

View File

@@ -1,19 +0,0 @@
{ stdenv, fetchurl, wxGTK, pkgconfig, gettext, gtk, glib, zlib }:
stdenv.mkDerivation {
name = "audacity-1.3.7";
NIX_CFLAGS_COMPILE = "-fPIC -lgtk-x11-2.0 -lglib-2.0 -lgobject-2.0 -lz";
src = fetchurl {
url = mirror://sourceforge/audacity/audacity-fullsrc-1.3.7.tar.bz2;
sha256 = "1kashc6cc6d5g6i59nqcrl795x1jqdh0lpg3msa1wckfj3hpljmy";
};
buildInputs = [ wxGTK pkgconfig gettext gtk glib zlib ];
meta = {
description = "Sound editor with graphical UI";
homepage = http://audacity.sourceforge.net;
license = "GPLv2+";
};
}

View File

@@ -1,26 +0,0 @@
{stdenv, fetchurl, gettext, ncurses
, gtkGUI ? false
, pkgconfig ? null
, gtk ? null}:
assert gtkGUI -> pkgconfig != null && gtk != null;
stdenv.mkDerivation {
name = "aumix-2.8";
src = fetchurl {
url = http://www.jpj.net/~trevor/aumix/aumix-2.8.tar.bz2;
sha256 = "636eef7f400c2f3df489c0d2fa21507e88692113561e75a40a26c52bc422d7fc";
};
buildInputs = [ gettext ncurses ]
++ (if gtkGUI then [pkgconfig gtk] else []);
meta = {
longDescription = ''
Aumix adjusts an audio mixer from X, the console, a terminal,
the command line or a script.
'';
homepage = http://www.jpj.net/~trevor/aumix.html;
license = "GPL";
};
}

View File

@@ -1,36 +0,0 @@
args: with args;
args.stdenv.mkDerivation {
name = "beast-0.7.1";
src = args.fetchurl {
url = ftp://beast.gtk.org/pub/beast/v0.7/beast-0.7.1.tar.bz2;
sha256 = "0jyl1i1918rsn4296w07fsf6wx3clvad522m3bzgf8ms7gxivg5l";
};
buildInputs =[zlib guile libart_lgpl pkgconfig intltool gtk glib
libogg libvorbis libgnomecanvas gettext
];
inherit bash perl;
patchPhase = ''
unset patchPhase; patchPhase
sed 's=-DG_DISABLE_DEPRECATED==g' -i `find -type f` # the patches didn't remove all occurences
sed 's=/bin/bash=/$bash/bin/bash=g' -i `find -type f`
sed 's=/usr/bin/perl=/$perl/bin/bash=g' -i `find -type f`
'';
patches = [
(fetchurl {
url = mirror://gentoo/distfiles/beast-0.7.1-guile-1.8.diff.bz2;
sha256 = "dc5194deff4b0a0eec368a69090db682d0c3113044ce2c2ed017ddfec9d3814e";
})
./patch.patch # patches taken from gentoo
];
meta = {
description = "BEAST - the Bedevilled Sound Engine";
homepage = http://beast.gtk.org;
license = ["GPL-2" "LGPL-2.1"];
};
}

View File

@@ -1,187 +0,0 @@
Index: beast-0.7.1/shell/Makefile.in
===================================================================
--- beast-0.7.1.orig/shell/Makefile.in
+++ beast-0.7.1/shell/Makefile.in
@@ -859,10 +859,7 @@ check-before: check-installation
check-installation:
@for p in $(bin_PROGRAMS) ; do \
pp="$(DESTDIR)$(bindir)/$$p" ; \
- echo "TEST: test -x \"$$pp\"" ; \
- test -x "$$pp" || \
- { echo "Failed to verify installation of executable: $$pp"; \
- exit 1 ; } \
+ echo "TEST: test -x \"$$pp\" Test disabled" ; \
done
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
Index: beast-0.7.1/shell/Makefile.am
===================================================================
--- beast-0.7.1.orig/shell/Makefile.am
+++ beast-0.7.1/shell/Makefile.am
@@ -859,10 +859,7 @@ check-before: check-installation
check-installation:
@for p in $(bin_PROGRAMS) ; do \
pp="$(DESTDIR)$(bindir)/$$p" ; \
- echo "TEST: test -x \"$$pp\"" ; \
- test -x "$$pp" || \
- { echo "Failed to verify installation of executable: $$pp"; \
- exit 1 ; } \
+ echo "TEST: test -x \"$$pp\" Test disabled" ; \
done
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
Index: beast-0.7.1/birnet/birnettests.h
===================================================================
--- beast-0.7.1.orig/birnet/birnettests.h
+++ beast-0.7.1/birnet/birnettests.h
@@ -27,6 +27,7 @@
#include <glib.h>
#include <string.h>
+#include <signal.h>
BIRNET_EXTERN_C_BEGIN();
Index: beast-0.7.1/tools/bseloopfuncs.c
===================================================================
--- beast-0.7.1.orig/tools/bseloopfuncs.c
+++ beast-0.7.1/tools/bseloopfuncs.c
@@ -21,6 +21,7 @@
#include <string.h>
#include <stdio.h>
#include <math.h>
+#include <signal.h>
typedef struct {
gdouble score;
--- beast-0.7.1.orig/bse/Makefile.am 2008-06-01 13:12:28.116708321 +0200
+++ beast-0.7.1/bse/Makefile.am 2008-06-01 13:12:40.000000000 +0200
@@ -10,7 +10,7 @@
# need -I$(top_builddir) for <sfi/sficonfig.h>
# need -I$(srcdir) for "bseserver.h" in .genprc.c
# need -I. (builddir) for "bsecore.genidl.hh" in bsecore.cc
-INCLUDES += -I$(top_srcdir) -I$(top_builddir) -I$(srcdir) -I. $(BSE_CFLAGS) -DG_DISABLE_DEPRECATED -DG_DISABLE_CONST_RETURNS
+INCLUDES += -I$(top_srcdir) -I$(top_builddir) -I$(srcdir) -I. $(BSE_CFLAGS) -DG_DISABLE_CONST_RETURNS
DEFS += $(strip \
$(patsubst %, -DG_LOG_DOMAIN=\"BSE\" -DBSE_COMPILATION, \
$(filter $(<F), $(bse_sources) $(bse_sources))) \
--- beast-0.7.1.orig/bse/zintern/Makefile.am 2008-06-01 13:14:25.880028999 +0200
+++ beast-0.7.1/bse/zintern/Makefile.am 2008-06-01 13:14:38.000000000 +0200
@@ -4,7 +4,7 @@
## GNU Lesser General Public License version 2 or any later version.
include $(top_srcdir)/Makefile.decl
-INCLUDES += -I$(top_srcdir) -I$(top_builddir) $(BSE_CFLAGS) -DG_DISABLE_DEPRECATED -DG_DISABLE_CONST_RETURNS
+INCLUDES += -I$(top_srcdir) -I$(top_builddir) $(BSE_CFLAGS) -DG_DISABLE_CONST_RETURNS
ZFILE_DEFS = $(strip \
wave-mono $(srcdir)/wave-mono.bse \
--- a/configure.in 2008-06-01 15:19:46.000000000 +0200
+++ b/configure.in 2008-06-01 15:27:45.000000000 +0200
@@ -159,39 +159,33 @@
dnl # Define package requirements.
dnl #
dnl ## include acintltool.m4 to provide IT_PROG_INTLTOOL
-builtin(include, acintltool.m4)dnl
-AC_DEFUN([AC_I18N_REQUIREMENTS],
-[
- ALL_LINGUAS=`cat "$srcdir/po/LINGUAS" | grep -v '^#' | xargs echo -n `
- AC_SUBST(ALL_LINGUAS)
- AC_SUBST([CONFIG_STATUS_DEPENDENCIES], ['$(top_srcdir)/po/LINGUAS'])
-
- dnl # versioned BEAST gettext domain (po/)
- BST_GETTEXT_DOMAIN=beast-v$BIN_VERSION # version without -rcZ
- AC_SUBST(BST_GETTEXT_DOMAIN)
- AC_DEFINE_UNQUOTED(BST_GETTEXT_DOMAIN, "$BST_GETTEXT_DOMAIN", [Versioned BEAST gettext domain])
- GETTEXT_PACKAGE=$BST_GETTEXT_DOMAIN
- AC_SUBST(GETTEXT_PACKAGE)
-
- dnl # locale directory for all domains
- dnl # (AM_GLIB_DEFINE_LOCALEDIR() could do this if it would do AC_SUBST())
- saved_prefix="$prefix"
- saved_exec_prefix="$exec_prefix"
- test "x$prefix" = xNONE && prefix=$ac_default_prefix
- test "x$exec_prefix" = xNONE && exec_prefix=$prefix
- if test "x$CATOBJEXT" = "x.mo" ; then
- beastlocaledir=`eval echo "${libdir}/locale"`
- else
- beastlocaledir=`eval echo "${datadir}/locale"`
- fi
- exec_prefix="$saved_exec_prefix"
- prefix="$saved_prefix"
- AC_SUBST(beastlocaledir)
-
- dnl # do gettext checks and prepare for intltool
- AM_GLIB_GNU_GETTEXT
- IT_PROG_INTLTOOL
-])
+IT_PROG_INTLTOOL([0.35.0])
+
+dnl # versioned BEAST gettext domain (po/)
+BST_GETTEXT_DOMAIN=beast-v$BIN_VERSION # version without -rcZ
+AC_SUBST(BST_GETTEXT_DOMAIN)
+AC_DEFINE_UNQUOTED(BST_GETTEXT_DOMAIN, "$BST_GETTEXT_DOMAIN", [Versioned BEAST gettext domain])
+GETTEXT_PACKAGE=$BST_GETTEXT_DOMAIN
+AC_SUBST(GETTEXT_PACKAGE)
+
+dnl # locale directory for all domains
+dnl # (AM_GLIB_DEFINE_LOCALEDIR() could do this if it would do AC_SUBST())
+saved_prefix="$prefix"
+saved_exec_prefix="$exec_prefix"
+test "x$prefix" = xNONE && prefix=$ac_default_prefix
+test "x$exec_prefix" = xNONE && exec_prefix=$prefix
+if test "x$CATOBJEXT" = "x.mo" ; then
+ beastlocaledir=`eval echo "${libdir}/locale"`
+else
+ beastlocaledir=`eval echo "${datadir}/locale"`
+fi
+exec_prefix="$saved_exec_prefix"
+prefix="$saved_prefix"
+AC_SUBST(beastlocaledir)
+
+dnl # do gettext checks and prepare for intltool
+AM_GLIB_GNU_GETTEXT
+
AC_DEFUN([AC_SFI_REQUIREMENTS],
[
dnl # check for GLib libs, libbirnet already provides gthread-2.0 and glib-2.0
@@ -570,7 +564,6 @@
AC_BIRNET_REQUIREMENTS
# Check requirement sets
-AC_I18N_REQUIREMENTS
AC_SFI_REQUIREMENTS
AC_BSE_REQUIREMENTS
AC_BSESCM_REQUIREMENTS
--- a/po/POTFILES.in 2008-06-22 15:12:10.000000000 +0200
+++ b/po/POTFILES.in 2008-06-22 15:13:28.000000000 +0200
@@ -131,3 +131,29 @@
plugins/davxtalstrings.c
plugins/freeverb/bsefreeverb.c
tools/bsewavetool.cc
+
+beast-gtk/bstgentypes.c
+birnet/birnetcpu.cc
+birnet/birnetutils.hh
+bse/bsebus.genprc.c
+bse/bsebusmodule.genidl.hh
+bse/bsecontainer.genprc.c
+bse/bsecore.genidl.hh
+bse/bseieee754.h
+bse/bseladspamodule.c
+bse/bseparasite.genprc.c
+bse/bsesong.genprc.c
+bse/bsesource.genprc.c
+bse/bsetrack.genprc.c
+plugins/artscompressor.genidl.hh
+plugins/bseamplifier.genidl.hh
+plugins/bsebalance.genidl.hh
+plugins/bsecontribsampleandhold.genidl.hh
+plugins/bsenoise.genidl.hh
+plugins/bsequantizer.genidl.hh
+plugins/bsesummation.genidl.hh
+plugins/davbassfilter.genidl.hh
+plugins/davchorus.genidl.hh
+plugins/standardguspatchenvelope.genidl.hh
+plugins/standardsaturator.genidl.hh
+tests/latency/bselatencytest.genidl.hh

View File

@@ -1,31 +0,0 @@
{ fetchurl, stdenv }:
let version = "0.9";
in
stdenv.mkDerivation {
name = "cd-discid-${version}";
src = fetchurl {
url = "mirror://debian/pool/main/c/cd-discid/cd-discid_${version}.orig.tar.gz";
sha256 = "1fx2ky1pb07l1r0bldpw16wdsfzw7a0093ib9v66kmilwy2sq5s9";
};
patches = [ ./install.patch ];
configurePhase = ''
sed -i "s|^[[:blank:]]*prefix *=.*$|prefix = $out|g ;
s|^[[:blank:]]*INSTALL *=.*$|INSTALL = install -c|g" \
"Makefile";
'';
meta = {
homepage = http://lly.org/~rcw/cd-discid/;
licence = "GPLv2+";
description = "cd-discid, a command-line utility to retrieve a disc's CDDB ID";
longDescription = ''
cd-discid is a backend utility to get CDDB discid information
from a CD-ROM disc. It was originally designed for cdgrab (now
abcde), but can be used for any purpose requiring CDDB data.
'';
};
}

View File

@@ -1,14 +0,0 @@
--- cd-discid-0.9/Makefile 2003-01-05 21:18:07.000000000 +0100
+++ cd-discid-0.9/Makefile 2008-05-26 22:14:56.000000000 +0200
@@ -32,9 +32,9 @@ clean:
install: cd-discid
$(INSTALL) -d -m 755 $(bindir)
- $(INSTALL) -s -m 755 -o 0 cd-discid $(bindir)
+ $(INSTALL) -s -m 755 cd-discid $(bindir)
$(INSTALL) -d -m 755 $(mandir)
- $(INSTALL) -m 644 -o 0 cd-discid.1 $(mandir)
+ $(INSTALL) -m 644 cd-discid.1 $(mandir)
tarball:
@cd .. && tar czvf cd-discid_$(VERSION).orig.tar.gz \

View File

@@ -8,8 +8,4 @@ stdenv.mkDerivation {
};
patches = [./fix.patch];
meta = {
homepage = http://xiph.org/paranoia;
};
}

View File

@@ -1,16 +1,11 @@
{stdenv, fetchurl, libogg}:
stdenv.mkDerivation rec {
name = "flac-1.2.1";
stdenv.mkDerivation {
name = "flac-1.1.2";
src = fetchurl {
url = mirror://sourceforge/flac/flac-1.2.1.tar.gz;
sha256 = "1pry5lgzfg57pga1zbazzdd55fkgk3v5qy4axvrbny5lrr5s8dcn";
url = http://downloads.xiph.org/releases/flac/flac-1.1.2.tar.gz;
md5 = "2bfc127cdda02834d0491ab531a20960";
};
buildInputs = [libogg];
meta = {
homepage = http://flac.sourceforge.net;
};
buildInputs = [libogg] ;
}

View File

@@ -1,17 +0,0 @@
{ stdenv, fetchurl, pkgconfig, libgpod, gtk, glib, gettext, perl, perlXMLParser, libglade, flex, libid3tag }:
stdenv.mkDerivation {
name = "gtkpod-0.99.14";
src = fetchurl {
url = mirror://sourceforge/gtkpod/gtkpod-0.99.14.tar.gz;
sha256 = "0ggcfyhcdlf3br88csdki215k4clxixa192afz6f16k7h8s2iqbk";
};
buildInputs = [ pkgconfig libgpod gettext perl perlXMLParser gtk libglade flex libid3tag];
meta = {
description = "GTK Manager for an Apple ipod";
homepage = http://gtkpod.sourceforge.net;
license = "GPLv2+";
};
}

View File

@@ -1,27 +0,0 @@
args: with args;
let localDefs = builderDefs.passthru.function {
src =
fetchurl {
url = http://plugin.org.uk/releases/0.4.15/swh-plugins-0.4.15.tar.gz;
sha256 = "0h462s4mmqg4iw7zdsihnrmz2vjg0fd49qxw2a284bnryjjfhpnh";
};
buildInputs = [fftw ladspaH pkgconfig];
configureFlags = [];
};
in with localDefs;
let
postInstall = FullDepEntry ("
ensureDir \$out/share/ladspa/
ln -s \$out/lib/ladspa \$out/share/ladspa/lib
") [minInit defEnsureDir];
in
stdenv.mkDerivation {
name = "swh-plugins-0.4.15";
builder = writeScript "swh-plugins-0.4.15-builder"
(textClosure localDefs [doConfigure doMakeInstall
postInstall doForceShare]);
meta = {
description = "LADSPA format audio plugins";
inherit src;
};
}

View File

@@ -1,28 +0,0 @@
args: with args;
let
src =
fetchurl {
url = http://www.ladspa.org/ladspa_sdk/ladspa.h.txt;
sha256 = "1b908csn85ng9sz5s5d1mqk711cmawain2z8px2ajngihdrynb67";
};
in
let localDefs = builderDefs.passthru.function {
buildInputs = [];
inherit src;
};
in with localDefs;
let
copyFile = FullDepEntry ("
ensureDir \$out/include
cp ${src} \$out/include/ladspa.h
") [minInit defEnsureDir];
in
stdenv.mkDerivation {
name = "ladspa.h";
builder = writeScript "ladspa.h-builder"
(textClosure localDefs [copyFile]);
meta = {
description = "LADSPA format audio plugins";
inherit src;
};
}

View File

@@ -1,9 +1,9 @@
{stdenv, fetchurl}:
stdenv.mkDerivation {
name = "lame-3.97";
name = "lame-3.96.1";
src = fetchurl {
url = mirror://sourceforge/lame/lame-3.97.tar.gz ;
sha256 = "05xy9lv6m9s013lzlvhxwvr1586c239xaiiwka52k18hs6k388qa";
url = mirror://sourceforge/lame/lame-3.96.1.tar.gz ;
md5 = "e1206c46a5e276feca11a7149e2fc6ac" ;
};
}

View File

@@ -1,17 +0,0 @@
{stdenv, fetchurl, libao, libmad, libid3tag, zlib}:
stdenv.mkDerivation {
name = "mpg321-0.2.10";
src = fetchurl {
url = mirror://sourceforge/mpg321/mpg321-0.2.10.tar.gz;
sha256 = "db0c299592b8f1f704f41bd3fc3a2bf138658108588d51af61638c551af1b0d4";
};
buildInputs = [libao libid3tag libmad zlib];
meta = {
description = "Command-line MP3 player.";
homepage = http://mpg321.sourceforge.net/;
license = "GPLv2";
};
}

View File

@@ -1,20 +0,0 @@
args:
args.stdenv.mkDerivation {
# some dependencies such as killall have to be installed additionally
name = "qjackctl-0.3.3";
src = args.fetchurl {
url = http://downloads.sourceforge.net/qjackctl/qjackctl-0.3.3.tar.gz;
sha256 = "1z9v208fs79ka6ni3p5v5xb0k5y1wqqm2a9cf903387b9p3fhpxj";
};
buildInputs =(with args; [qt4 alsaLib jackaudio]);
meta = {
description = "qt jackd control gui tool";
homepage = http://qjackctl.sourceforge.net/;
license = "GPL";
};
}

View File

@@ -1,60 +0,0 @@
args :
let
lib = args.lib;
fetchurl = args.fetchurl;
FullDepEntry = args.FullDepEntry;
version = lib.getAttr ["version"] "9.4" args;
buildInputs = with args; [gtk glib pkgconfig
libXpm gmp gettext libX11 fftw]
++ (lib.optional (args ? ruby) args.ruby)
++ (lib.optional (args ? mesa) args.mesa)
++ (lib.optional (args ? guile) args.guile)
++ (lib.optional (args ? libtool) args.libtool)
++ (lib.optional (args ? sndlib) args.sndlib)
++ (lib.optional (args ? alsaLib) args.alsaLib)
++ (lib.optional (args ? jackaudio) args.jackaudio)
;
configureFlags = ["--with-gtk" "--with-xpm"]
++ (lib.optional (args ? ruby) "--with-ruby" )
++ (lib.optional (args ? mesa) "--with-gl" )
++ (lib.optional (args ? guile) "--with-guile")
++ (lib.optional (args ? sndlib) "--with-midi" )
++ (lib.optional (args ? alsaLib) "--with-alsa")
++ (lib.optional (args ? jackaudio) "--with-jack" )
++ [ "--with-fftw" "--htmldir=$out/share/snd/html" "--with-doc-dir=$out/share/snd/html" ]
;
in
rec {
src = fetchurl {
url = "http://downloads.sourceforge.net/snd/snd-${version}.tar.gz";
sha256 = "0zqgfnkvkqxby1k74mwba1r4pb520glcsz5jjmpzm9m41nqnghmm";
};
inherit buildInputs;
configureFlags = [];
/* doConfigure should be specified separately */
phaseNames = ["doConfigure" "preBuild" "makeDocsWork"
"doMakeInstall" "doForceShare"];
makeDocsWork = FullDepEntry ''
# hackish way to make html docs work
h="$out/share/snd/html"; ensureDir "$h"; cp *.html "$h"
patch -p1 < ${./doc.patch}
sed "s@HTML-DIR@$h@" -i index.scm snd-help.c
'' ["defEnsureDir"];
preBuild = FullDepEntry (''
cp config.log /tmp/snd-config.log
export NIX_LDFLAGS="$NIX_LDFLAGS -L${args.libX11}/lib -lX11"
'') ["minInit" "doUnpack" "makeDocsWork"];
name = "Snd-" + version;
meta = {
description = "Snd sound editor.";
homepage = http://ccrma.stanford.edu/software/snd;
inherit src;
};
}

View File

@@ -1,62 +0,0 @@
diff --git a/index.scm b/index.scm
index 2148a58..713939c 100644
--- a/index.scm
+++ b/index.scm
@@ -18,24 +18,7 @@ and if one is found, and the Snd documentation can be found, calls (html-program
(lambda (n)
;; look for doc on current dir, then html dir, then global dir
;; snd.html is what we'll search for
- (let ((dir (if (file-exists? "snd.html")
- (getcwd)
- (if (and (string? (html-dir))
- (file-exists? (string-append (html-dir) "/snd.html")))
- (html-dir)
- (if (file-exists? "/usr/share/doc/snd-9/snd.html")
- "/usr/share/doc/snd-9"
- (if (file-exists? "/usr/local/share/doc/snd-9/snd.html")
- "/usr/local/share/doc/snd-9"
- (if (file-exists? "/usr/doc/snd-9/snd.html")
- "/usr/doc/snd-9"
- (if (file-exists? "/usr/share/doc/snd-8/snd.html")
- "/usr/share/doc/snd-8"
- (if (file-exists? "/usr/local/share/doc/snd-8/snd.html")
- "/usr/local/share/doc/snd-8"
- (if (file-exists? "/usr/doc/snd-8/snd.html")
- "/usr/doc/snd-8"
- #f))))))))))
+ (let (dir "HTML-DIR")
(if dir
(if (or (string=? (html-program) "netscape")
(string=? (html-program) "mozilla")
diff --git a/snd-help.c b/snd-help.c
index a6557e0..a40a02e 100644
--- a/snd-help.c
+++ b/snd-help.c
@@ -3554,26 +3554,7 @@ static char *doc_files[DOC_DIRECTORIES] = {
static char *html_directory(void)
{
- int i;
- if (mus_file_probe("snd.html"))
- return(mus_getcwd());
- if (html_dir(ss))
- {
- bool happy;
- char *hd = NULL;
- hd = (char *)CALLOC(snd_strlen(html_dir(ss)) + 16, sizeof(char));
- sprintf(hd, html_dir(ss), "/snd.html");
- happy = mus_file_probe(hd);
- FREE(hd);
- if (happy) return(copy_string(html_dir(ss)));
- }
-#ifdef MUS_DEFAULT_DOC_DIR
- if (mus_file_probe(MUS_DEFAULT_DOC_DIR "/snd.html"))
- return(copy_string(MUS_DEFAULT_DOC_DIR "/snd.html"));
-#endif
- for (i = 0; i < DOC_DIRECTORIES; i++)
- if (mus_file_probe(doc_files[i])) return(copy_string(doc_directories[i]));
- return(NULL);
+ return (copy_string ("HTML-DIR"));
}

View File

@@ -1,25 +0,0 @@
{stdenv, fetchurl, libogg, libvorbis, libao, pkgconfig, curl, glibc
, speex, flac}:
stdenv.mkDerivation {
name = "vorbis-tools-1.1.1";
src = fetchurl {
url = http://downloads.xiph.org/releases/vorbis/vorbis-tools-1.1.1.tar.gz;
sha256 = "617b4aa69e600c215b34fa3fd5764bc1d9d205d9d7d9fe7812bde7ec956fcaad";
};
# FIXME: Vorbis-tools expects `libOggFLAC', but this library was
# merged with `libFLAC' as of FLAC 1.1.3.
buildInputs = [ libogg libvorbis libao pkgconfig curl speex glibc flac ];
patches = [ ./ogg123-curlopt-mute.patch ];
meta = {
longDescription = ''
A set of command-line tools to manipulate Ogg Vorbis audio
files, notably the `ogg123' player and the `oggenc' encoder.
'';
homepage = http://xiph.org/vorbis/;
license = "GPLv2";
};
}

View File

@@ -1,13 +0,0 @@
--- vorbis-tools-1.1.1/ogg123/http_transport.c 2005-06-13 15:11:44.000000000 +0200
+++ vorbis-tools-1.1.1/ogg123/http_transport.c 2008-02-12 18:38:41.000000000 +0100
@@ -116,7 +116,9 @@ void set_curl_opts (http_private_t *priv
if (inputOpts.ProxyTunnel)
curl_easy_setopt (handle, CURLOPT_HTTPPROXYTUNNEL, inputOpts.ProxyTunnel);
*/
+#ifdef CURLOPT_MUTE
curl_easy_setopt(handle, CURLOPT_MUTE, 1);
+#endif
curl_easy_setopt(handle, CURLOPT_ERRORBUFFER, private->error);
curl_easy_setopt(handle, CURLOPT_PROGRESSFUNCTION, progress_callback);
curl_easy_setopt(handle, CURLOPT_PROGRESSDATA, private);

View File

@@ -3,7 +3,7 @@
stdenv.mkDerivation {
name = "xmms-1.2.10";
src = fetchurl {
url = http://nixos.org/tarballs/xmms-1.2.10.tar.bz2;
url = http://nix.cs.uu.nl/dist/tarballs/xmms-1.2.10.tar.bz2;
md5 = "03a85cfc5e1877a2e1f7be4fa1d3f63c";
};
@@ -14,6 +14,5 @@ stdenv.mkDerivation {
meta = {
description = "A music player very similar to Winamp";
homepage = http://www.xmms.org;
};
}

View File

@@ -1,35 +1,23 @@
{stdenv, fetchurl, x11, libjpeg, libpng, libXmu, freetype, pam}:
stdenv.mkDerivation rec {
name = "slim-1.3.1";
stdenv.mkDerivation {
name = "slim-1.2.6";
src = fetchurl {
url = "http://download.berlios.de/slim/${name}.tar.gz";
sha256 = "0xqgzvg6h1bd29140mcgg9r16vcmskz7zmym7i7jlz7x9c1a9mxc";
url = http://download.berlios.de/slim/slim-1.2.6.tar.gz;
sha256 = "0plcmm955rnv67sx67ka6dccanr4rfzwzvsj6lnr8kqdip4522jg";
};
patches = [
# Allow the paths of the configuration file and theme directory to
# be set at runtime.
./runtime-paths.patch
# Fix a bug in slim's PAM support: the "resp" argument to the
# conversation function is a pointer to a pointer to an array of
# pam_response structures, not a pointer to an array of pointers to
# pam_response structures. Of course C can't tell the difference...
# PAM support from
# http://developer.berlios.de/patch/?func=detailpatch&patch_id=1979&group_id=2663
./pam.patch
];
buildInputs = [x11 libjpeg libpng libXmu freetype pam];
NIX_CFLAGS_COMPILE = "-I${freetype}/include/freetype2";
preBuild = ''
preBuild = "
substituteInPlace Makefile --replace /usr /no-such-path
makeFlagsArray=(CC=gcc CXX=g++ PREFIX=$out MANDIR=$out/share/man CFGDIR=$out/etc USE_PAM=1)
'';
meta = {
homepage = http://slim.berlios.de;
};
makeFlagsArray=(CC=gcc CXX=g++ PREFIX=$out MANDIR=$out/share/man CFGDIR=$out/etc)
";
}

View File

@@ -1,89 +1,369 @@
diff -rc slim-1.3.1-orig/app.cpp slim-1.3.1/app.cpp
*** slim-1.3.1-orig/app.cpp 2008-09-26 02:54:15.000000000 +0200
--- slim-1.3.1/app.cpp 2009-02-17 19:50:06.000000000 +0100
diff -rc slim-1.2.6-orig/app.cpp slim-1.2.6/app.cpp
*** slim-1.2.6-orig/app.cpp 2006-09-15 23:00:37.000000000 +0200
--- slim-1.2.6/app.cpp 2007-06-05 12:45:58.000000000 +0200
***************
*** 41,48 ****
Panel* panel = *static_cast<Panel**>(appdata_ptr);
int result = PAM_SUCCESS;
for (int i=0; i<num_msg; i++){
! resp[i]->resp=0;
! resp[i]->resp_retcode=0;
switch(msg[i]->msg_style){
case PAM_PROMPT_ECHO_ON:
// We assume PAM is asking for the username
--- 41,48 ----
Panel* panel = *static_cast<Panel**>(appdata_ptr);
int result = PAM_SUCCESS;
for (int i=0; i<num_msg; i++){
! (*resp)[i].resp=0;
! (*resp)[i].resp_retcode=0;
switch(msg[i]->msg_style){
case PAM_PROMPT_ECHO_ON:
// We assume PAM is asking for the username
*** 25,30 ****
--- 25,68 ----
#include "app.h"
#include "numlock.h"
+ #ifdef USE_PAM
+ #include <security/pam_appl.h>
+ #include <security/pam_misc.h>
+ #include <string>
+
+ pam_handle_t* pamh;
+ char const* PAM_service = "slim"; // <----- Change this, if the patch gets accepted upstream
+ string password;
+
+ int conv(int num_msg, const struct pam_message **msg,
+ struct pam_response **resp, void *appdata_ptr){
+ *resp = (struct pam_response *) calloc(num_msg, sizeof(struct pam_response));
+ for (int i=0; i<num_msg; i++){
+ resp[i]->resp_retcode=0;
+ switch(msg[i]->msg_style){
+ case PAM_PROMPT_ECHO_ON:
+ // We assume PAM is asking for the username
+ // As we should have given that already, this should never happen
+ cerr << APPNAME << ": PAM send an unexpected PAM_PROMPT_ECHO_ON" << endl;
+ cerr << APPNAME << ": " << msg[i]->msg << endl;
+ break;
+
+ case PAM_PROMPT_ECHO_OFF:
+ // We assume PAM is asking for the password
+ resp[i]->resp=x_strdup(password.c_str());
+ break;
+
+ case PAM_ERROR_MSG:
+ case PAM_TEXT_INFO:
+ // We simply right these to the log
+ // TODO: Maybe we should simply ignore them
+ cerr << APPNAME << ": " << msg[i]->msg << endl;
+ break;
+ }
+ }
+ return PAM_SUCCESS;
+ }
+ #endif
extern App* LoginApp;
***************
*** 51,63 ****
case Panel::Suspend:
case Panel::Halt:
case Panel::Reboot:
! resp[i]->resp=strdup("root");
break;
case Panel::Console:
case Panel::Exit:
case Panel::Login:
! resp[i]->resp=strdup(panel->GetName().c_str());
break;
}
break;
--- 51,63 ----
case Panel::Suspend:
case Panel::Halt:
case Panel::Reboot:
! (*resp)[i].resp=strdup("root");
break;
case Panel::Console:
case Panel::Exit:
case Panel::Login:
! (*resp)[i].resp=strdup(panel->GetName().c_str());
break;
}
break;
***************
*** 73,79 ****
default:
panel->EventHandler(Panel::Get_Passwd);
! resp[i]->resp=strdup(panel->GetPasswd().c_str());
break;
}
break;
--- 73,79 ----
default:
panel->EventHandler(Panel::Get_Passwd);
! (*resp)[i].resp=strdup(panel->GetPasswd().c_str());
break;
}
break;
***************
*** 89,97 ****
*** 133,138 ****
--- 171,209 ----
}
}
if (result!=PAM_SUCCESS){
for (int i=0; i<num_msg; i++){
! if (resp[i]->resp==0) continue;
! free(resp[i]->resp);
! resp[i]->resp=0;
};
free(*resp);
*resp=0;
--- 89,97 ----
+ #ifdef USE_PAM
+ int last_result;
+ struct pam_conv pam_conversation = {
+ conv,
+ NULL
+ };
+
+ // Start the PAM session
+ if ((last_result=pam_start(PAM_service, NULL, &pam_conversation, &pamh))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ exit(ERR_EXIT);
+ }
+
+ // Setup some PAM items
+ if ((last_result=pam_set_item(pamh, PAM_TTY, DisplayName))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ pam_end(pamh, last_result);
+ exit(ERR_EXIT);
+ }
+ char* pam_ruser = "root\0"; // <---- We already checked for this in the constructor
+ if ((last_result=pam_set_item(pamh, PAM_RUSER, pam_ruser))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ pam_end(pamh, last_result);
+ exit(ERR_EXIT);
+ }
+ char* pam_rhost = "localhost\0"; // <---- This might not entirely correct
+ if ((last_result=pam_set_item(pamh, PAM_RHOST, pam_rhost))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ pam_end(pamh, last_result);
+ exit(ERR_EXIT);
+ }
+ #endif
+
bool loaded = false;
while (!loaded) {
themedir = themebase + themeName;
***************
*** 313,318 ****
--- 384,421 ----
struct passwd *pw;
pid_t pid;
+ #ifdef USE_PAM
+ int last_result;
+ switch ((last_result=pam_setcred(pamh, PAM_ESTABLISH_CRED | PAM_SILENT))){
+ case PAM_SUCCESS:
+ // Credentials was established successfully
+ break;
+
+ case PAM_CRED_ERR:
+ case PAM_CRED_EXPIRED:
+ case PAM_CRED_UNAVAIL:
+ case PAM_USER_UNKNOWN:
+ // Credentials couldn't be established
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ return;
+
+ case PAM_BUF_ERR:
+ case PAM_SYSTEM_ERR:
+ default:
+ // System error -> bail out!
+ last_result=pam_setcred(pamh, PAM_DELETE_CRED);
+ pam_end(pamh, last_result);
+ exit(ERR_EXIT);
+ }
+
+ if ((last_result=pam_open_session(pamh, PAM_SILENT))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ pam_setcred(pamh, PAM_DELETE_CRED);
+ // TODO: Do we need more serious actions?
+ return;
+ }
+ #endif
+
pw = LoginPanel->GetInput()->GetPasswdStruct();
if(pw == 0)
return;
***************
*** 320,325 ****
--- 423,433 ----
// Create new process
pid = fork();
if(pid == 0) {
+ #ifdef USE_PAM
+ // Close the child's copy of the PAM-handle
+ pam_end(pamh, PAM_SUCCESS | PAM_DATA_SILENT);
+ #endif
+
// Login process starts here
SwitchUser Su(pw, cfg, DisplayName);
string session = LoginPanel->getSession();
***************
*** 355,361 ****
}
}
if (result!=PAM_SUCCESS){
for (int i=0; i<num_msg; i++){
! if ((*resp)[i].resp==0) continue;
! free((*resp)[i].resp);
! (*resp)[i].resp=0;
};
free(*resp);
*resp=0;
! // Close all clients
KillAllClients(False);
KillAllClients(True);
--- 463,477 ----
}
}
! #ifdef USE_PAM
! if ((last_result=pam_close_session(pamh, PAM_SILENT))!=PAM_SUCCESS){
! cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
! last_result=pam_setcred(pamh, PAM_DELETE_CRED);
! // TODO: Do we need more serious actions?
! }
! #endif
!
! // Close all clients
KillAllClients(False);
KillAllClients(True);
***************
*** 382,387 ****
--- 498,510 ----
// Stop alarm clock
alarm(0);
+ #ifdef USE_PAM
+ int last_result;
+ if ((last_result=pam_end(pamh, PAM_SUCCESS))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ }
+ #endif
+
// Write message
LoginPanel->Message((char*)cfg->getOption("reboot_msg").c_str());
sleep(3);
***************
*** 398,403 ****
--- 521,533 ----
// Stop alarm clock
alarm(0);
+ #ifdef USE_PAM
+ int last_result;
+ if ((last_result=pam_end(pamh, PAM_SUCCESS))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ }
+ #endif
+
// Write message
LoginPanel->Message((char*)cfg->getOption("shutdown_msg").c_str());
sleep(3);
***************
*** 433,438 ****
--- 563,575 ----
void App::Exit() {
+ #ifdef USE_PAM
+ int last_result;
+ if ((last_result=pam_end(pamh, PAM_SUCCESS))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ }
+ #endif
+
if (testing) {
char* testmsg = "This is a test message :-)";
LoginPanel->Message(testmsg);
***************
*** 453,458 ****
--- 590,602 ----
}
void App::RestartServer() {
+ #ifdef USE_PAM
+ int last_result;
+ if ((last_result=pam_end(pamh, PAM_SUCCESS))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ }
+ #endif
+
StopServer();
RemoveLock();
Run();
Only in slim-1.2.6/: app.cpp~
diff -rc slim-1.2.6-orig/input.cpp slim-1.2.6/input.cpp
*** slim-1.2.6-orig/input.cpp 2006-09-15 23:00:37.000000000 +0200
--- slim-1.2.6/input.cpp 2007-06-05 12:45:58.000000000 +0200
***************
*** 12,17 ****
--- 12,25 ----
#include "input.h"
#include <cstdlib>
+ #ifdef USE_PAM
+ #include <security/pam_appl.h>
+ #include <string>
+
+ extern pam_handle_t* pamh;
+ extern string password;
+ #endif
+
Input::Input(Cfg* c) {
NameBuffer[0] = '\0';
PasswdBuffer[0] = '\0';
***************
*** 100,106 ****
--- 108,126 ----
struct passwd* Input::GetPasswdStruct() {
+ #ifdef USE_PAM
+ int last_result;
+ char* username=NULL;
+
+ if ((last_result=pam_get_item(pamh, PAM_USER, (const void**)&username))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ pam_end(pamh, last_result);
+ exit(ERR_EXIT);
+ }
+ struct passwd* pw = getpwnam(username);
+ #else
struct passwd* pw = getpwnam(NameBuffer);
+ #endif
endpwent();
if (pw->pw_shell[0] == '\0') {
setusershell();
***************
*** 183,188 ****
--- 203,240 ----
}
int Input::Correct() {
+ #ifdef USE_PAM
+ int last_result;
+
+ // Store the password in global variables accessible
+ // by the PAM-conversation function
+ password=PasswdBuffer;
+
+ // Set the username in PAM
+ if ((last_result=pam_set_item(pamh, PAM_USER, NameBuffer))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ pam_end(pamh, last_result);
+ exit(ERR_EXIT);
+ }
+
+ // Authenticate the user
+ if ((last_result=pam_authenticate(pamh, PAM_DISALLOW_NULL_AUTHTOK))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ if (last_result==PAM_ABORT){
+ pam_end(pamh, last_result);
+ exit(ERR_EXIT);
+ }
+ return 0;
+ }
+
+ // Check the health of the account
+ if ((last_result=pam_acct_mgmt(pamh, PAM_SILENT))!=PAM_SUCCESS){
+ cerr << APPNAME << ": " << pam_strerror(pamh, last_result) << endl;
+ return 0;
+ }
+
+ return 1;
+ #else
char *unencrypted, *encrypted, *correct;
struct passwd *pw;
***************
*** 197,203 ****
if(sp)
correct = sp->sp_pwdp;
else
! #endif
correct = pw->pw_passwd;
if(correct == 0 || correct[0] == '\0')
--- 249,255 ----
if(sp)
correct = sp->sp_pwdp;
else
! #endif /* HAVE_SHADOW */
correct = pw->pw_passwd;
if(correct == 0 || correct[0] == '\0')
***************
*** 207,212 ****
--- 259,265 ----
encrypted = crypt(unencrypted, correct);
memset(unencrypted, 0, strlen (unencrypted));
return (strcmp(encrypted, correct) == 0);
+ #endif /* USE_PAM */
}
diff -rc slim-1.2.6-orig/Makefile slim-1.2.6/Makefile
*** slim-1.2.6-orig/Makefile 2006-09-15 23:00:37.000000000 +0200
--- slim-1.2.6/Makefile 2007-06-05 12:45:58.000000000 +0200
***************
*** 6,13 ****
CXX=/usr/bin/g++
CC=/usr/bin/gcc
CFLAGS=-I. -I/usr/X11R6/include -I/usr/include/freetype2 -I/usr/include/freetype2/config -I/usr/include/libpng12 -I/usr/include
! LDFLAGS=-L/usr/X11R6/lib -lXft -lX11 -lfreetype -lXrender -lfontconfig -lpng12 -lz -lm -lcrypt -lXmu -lpng -ljpeg
! CUSTOM=-DHAVE_SHADOW
PREFIX=/usr
CFGDIR=/etc
MANDIR=/usr/man
--- 6,13 ----
CXX=/usr/bin/g++
CC=/usr/bin/gcc
CFLAGS=-I. -I/usr/X11R6/include -I/usr/include/freetype2 -I/usr/include/freetype2/config -I/usr/include/libpng12 -I/usr/include
! LDFLAGS=-L/usr/X11R6/lib -lXft -lX11 -lfreetype -lXrender -lfontconfig -lpng12 -lz -lm -lcrypt -lXmu -lpng -ljpeg -lpam
! CUSTOM=-DHAVE_SHADOW -DUSE_PAM
PREFIX=/usr
CFGDIR=/etc
MANDIR=/usr/man

View File

@@ -1,17 +0,0 @@
args : with args;
stdenv.mkDerivation {
name = "bvi-1.3.2";
src = fetchurl {
url = http://prdownloads.sourceforge.net/bvi/bvi-1.3.2.src.tar.gz;
sha256 = "110wxqnyianqamxq4y53drqqxb9vp4k2fcvic45qggvlqkqhlfgz";
};
buildInputs = [ncurses];
meta = {
description = "hex editor with vim style keybindings";
homepage = http://bvi.sourceforge.net/download.html;
license = "GPL2";
};
}

View File

@@ -1,96 +0,0 @@
args: with args; let
# hint: eclipse -data <dir to save global eclipse settings>
eclipsePlugin = name : src : stdenv.mkDerivation {
inherit src;
name = "${name}-eclipse-plugin";
phases = "unpackPhase";
buildInputs = [ args.unzip ];
unpackPhase = ''
mkdir tmp; cd tmp
unpackFile "$src"
[ -d ./eclipse ] || { # if plugin doesn't contain the eclipse directory itself create it (eg viPlugin)
mkdir "$TMP/eclipse"
mv * "$TMP/eclipse"
cd "$TMP"
}
ensureDir $out;
mv eclipse "$out"
'';
};
eclipseEnv = {name, eclipse, links}: runCommand name { inherit links eclipse; } ''
ensureDir $out/eclipse/links;
cp -r "$eclipse/bin" "$out/bin"
for f in $eclipse/eclipse/*; do
# using ln eclipse doesn't take the correct link folder :-( (TODO)
# ln -s "$f" "$out/eclipse/$(basename "$f")"
cp -r "$f" "$out/eclipse/$(basename "$f")"
done
# create links
for link in $links; do
echo "path=$link" >> "$out/eclipse/links/$(basename "$link").link"
done
'';
# mmh, this derivation is superfluous. We could also create them directly
# instead of symlinking them into the final env build by buildEnv
linkFile = deriv : writeTextFile {
name = "${deriv.name}-eclipse-feature-link";
destination = "/eclipse/links/${deriv.name}.link";
};
attr = rec {
eclipse = import ( ../eclipse-new + "/${version}/eclipse.nix") args; # without any additional plugins, why can't I use ./ instead of ../eclipse-new ?
plugins = rec {
viPlugin = { # see its license!
plugin = eclipsePlugin "viPlugin_1.15.6" (fetchurl {
url = http://www.satokar.com/viplugin/files/viPlugin_1.15.6.zip;
sha256 = "0p53q45a754j143pnnp51rjwj7lzawcxfy9xzpjasdic4a2l0f96";
# license = "Other/Proprietary License with Free Trial";
});
};
# PHP developement
emfSdoXsdSDK232 = {
plugin = eclipsePlugin "emf-sdo-xsd-SDK-2.3.2" (fetchurl {
url = http://eclipsemirror.yoxos.com/eclipse.org/modeling/emf/emf/downloads/drops/2.3.2/R200802051830/emf-sdo-xsd-SDK-2.3.2.zip;
sha256 = "1k20fn47x1giwhc80rzkqaw3mn0p3861sjp7aw39842lv2hjwn1c";
});
};
gefSDK332 = {
plugin = eclipsePlugin "GEF-SDK-3.3.2" (fetchurl {
url = http://ftp-stud.fht-esslingen.de/pub/Mirrors/eclipse/tools/gef/downloads/drops/3.3.2/R200802211602/GEF-SDK-3.3.2.zip;
sha256 = "1pk5qlwk0iyvs85s966y96ks8vq1g81fivvbf4lh43155rg0z037";
});
};
wtpSdkR202X = {
plugin = eclipsePlugin "wtp-sdk-R-2.0.2-20080223205547" (fetchurl {
url = http://ftp.wh2.tu-dresden.de/pub/mirrors/eclipse/webtools/downloads/drops/R2.0/R-2.0.2-20080223205547/wtp-sdk-R-2.0.2-20080223205547.zip;
sha256 = "0hmmmqzcd67jir2gmjd0xri5w2434xb2dk21hpgcv2qp0h9hhx0f";
});
};
pdt = {
deps = [ wtpSdkR202X gefSDK332 emfSdoXsdSDK232 ];
plugin = eclipsePlugin "pdt-runtime-1.0.3" (fetchurl {
url = http://sunsite.informatik.rwth-aachen.de:3080/eclipse/tools/pdt/downloads/drops/1.0.3/R200806030000/pdt-runtime-1.0.3.zip;
sha256 = "0wd2vc9bqrk5mqj5al2ichm8lxlf7gwifsb9lzv1d896j04ilm96";
});
};
};
};
pluginToList = a : [ a.plugin ] ++ lib.optionals (a ? deps ) (lib.concatMap pluginToList a.deps);
in
eclipseEnv {
name = "eclipse-${version}-with-plugins";
inherit (attr) eclipse;
links =
# example custom config: eclipse = { plugins = {eclipse, version, plugins } : let p = plugins; in [p.pdt]; };
let userChosenPlugins = (getConfig [ "eclipse" "plugins" ] ( {eclipse, version, plugins} : [] ))
{ inherit (attr) eclipse plugins; inherit version; };
in # concatenate plugins and plugin dependencies
(lib.uniqList { inputList = lib.concatMap pluginToList userChosenPlugins; });
}

View File

@@ -1,22 +0,0 @@
--- a/build.xml 2008-03-02 14:34:05.000000000 +0100
+++ b/build.xml 2008-03-02 14:34:57.000000000 +0100
@@ -291,19 +291,6 @@
</condition>
<property name="bootclasspath" refid="default.bootclasspath" />
- <!--set the compiler and compiler arguments-->
- <!--the default compiler is set to the one used by eclipse rel. eng. -->
- <condition property="build.compiler" value="org.eclipse.jdt.core.JDTCompilerAdapter">
- <available file="${basedir}/ecj.jar" />
- </condition>
- <fail message="The Eclipse compiler (ecj.jar) cannot be found.">
- <condition>
- <not>
- <equals arg1="${build.compiler}" arg2="org.eclipse.jdt.core.JDTCompilerAdapter" />
- </not>
- </condition>
- </fail>
-
<property name="compilerArg" value="-enableJavadoc -encoding ISO-8859-1" />
<property name="javacSource" value="1.6" />
<property name="javacTarget" value="1.6" />

View File

@@ -1,53 +0,0 @@
# Note, if you want to install plugins using the update manager you should
# copy the store path to a local directory and chown -R $USER yourcopy
# Then start your local copy
args: with args;
let arch = if stdenv.system == "x86_64-linux" then "x86_64"
else if stdenv.system == "i686-linux" then "x86"
else throw "not supported system";
in
args.stdenv.mkDerivation rec {
name = "eclipse-classic-3.3.1.1";
unpackPhase = "unzip \$src; set -x ";
buildInputs = [ unzip jdk gtk glib libXtst ant makeWrapper];
patches=./build-with-jdk-compiler.patch;
buildPhase = "./build -os linux -ws gtk -arch ${arch}";
libraries = [gtk glib libXtst];
installPhase = "
t=\$out/share/${name}
ensureDir \$t \$out/bin
cd result
tar xfz linux-gtk-*.tar.gz
mv eclipse \$out
"
#copied from other eclipse expressions
+" rpath=
for i in \$libraries; do
rpath=\$rpath\${rpath:+:}\$i/lib
done
find \$out \\( -type f -a -perm +0100 \\) \\
-print \\
-exec patchelf --interpreter \"$(cat \$NIX_GCC/nix-support/dynamic-linker)\" \\
--set-rpath \"\$rpath\" {} \\;
# Make a wrapper script so that the proper JDK is found.
makeWrapper \$out/eclipse/eclipse \$out/bin/eclipse \\
--prefix PATH \":\" \"\$jdk/bin\" \\
--prefix LD_LIBRARY_PATH \":\" \"\$rpath\"
sed -e 's=exec.*=exec \$(dirname $0)/../eclipse/eclipse $@=' -i \$out/bin/eclipse
";
# using dirname so that eclipse still runs after copying the whole store
# directory somewhere else (so that you can use the update manager
src = args.fetchurl {
url = http://mawercer.de/~nix/iyyx4hs1mgh1b1wa78j07pgq9k882m2k-eclipse-sourceBuild-srcIncluded-3.3.1.1.zip;
sha256 = "0n56i7ml816f839704qlkgs5ahl0iqgwc80kjq7n7g5rl9a4vhp4";
};
}

View File

@@ -1,22 +0,0 @@
--- a/build.xml 2008-03-02 14:34:05.000000000 +0100
+++ b/build.xml 2008-03-02 14:34:57.000000000 +0100
@@ -291,19 +291,6 @@
</condition>
<property name="bootclasspath" refid="default.bootclasspath" />
- <!--set the compiler and compiler arguments-->
- <!--the default compiler is set to the one used by eclipse rel. eng. -->
- <condition property="build.compiler" value="org.eclipse.jdt.core.JDTCompilerAdapter">
- <available file="${basedir}/ecj.jar" />
- </condition>
- <fail message="The Eclipse compiler (ecj.jar) cannot be found.">
- <condition>
- <not>
- <equals arg1="${build.compiler}" arg2="org.eclipse.jdt.core.JDTCompilerAdapter" />
- </not>
- </condition>
- </fail>
-
<property name="compilerArg" value="-enableJavadoc -encoding ISO-8859-1" />
<property name="javacSource" value="1.6" />
<property name="javacTarget" value="1.6" />

View File

@@ -1,4 +1,5 @@
source $stdenv/setup
source $makeWrapper
unpackFile $src
ensureDir $out
@@ -15,16 +16,9 @@ find $out \( -type f -a -perm +0100 \) \
--set-rpath "$rpath" {} \;
# Make a wrapper script so that the proper JDK is found.
# don't use makeWrapper in order to change the last line.
ensureDir $out/bin
cat >> $out/bin/eclipse << EOF
#! /bin/sh -e
export PATH=${jdk}/bin\${PATH:+:}\$PATH
export LD_LIBRARY_PATH=$rpath\${LD_LIBRARY_PATH:+:}\$LD_LIBRARY_PATH
exec \$(dirname $0)/../eclipse/eclipse $@
EOF
chmod +x $out/bin/eclipse
makeWrapper $out/eclipse/eclipse $out/bin/eclipse \
--prefix PATH ":" "$jdk/bin" \
--prefix LD_LIBRARY_PATH ":" "$rpath"
ensureDir plugin-working-dir
workingdir="$(pwd)/plugin-working-dir"

View File

@@ -1,33 +1,20 @@
# recommended installation:
# nix-build -A eclipsesdk
# then cp -r $store-path ~/my-eclipse; chmod -R 777 ~/my-eclipse # ugh! I'm to lazy to assign permissions properly
# maybe also using a wrapper such as this (lower values should suffice for most needs)
# eclipseWrapper () {
# "$@" -vmargs -Xms2048m -Xmx2048m -XX:MaxPermSize=2048m
# }
#
# Why use a local copy? This way it's easier to use the update manager to get plugins :-)
{fetchurl, stdenv, jdk, gtk, glib, libXtst, plugins ? []}:
{fetchurl, stdenv, makeWrapper, jdk, gtk, glib, libXtst, plugins ? []}:
let {
body =
stdenv.mkDerivation {
name = "eclipse-sdk-3.5M6";
name = "eclipse-sdk-3.2.2";
builder = ./builder.sh;
src = bindist;
buildInputs = [];
inherit jdk plugins;
inherit makeWrapper jdk plugins;
libraries = [gtk glib libXtst];
};
bindist =
if (stdenv.system == "x86_64-linux") then fetchurl {
url = ftp://sunsite.informatik.rwth-aachen.de/pub/mirror/eclipse/S-3.5M6-200903130100/eclipse-SDK-3.5M6-linux-gtk-x86_64.tar.gz;
sha256 = "10p4idp5rcdf7xqwfk3kvmjxhi8x1v835m0y4pn9q4nhfb5643pi";
} else fetchurl {
url = ftp://mirror.micromata.de/eclipse/eclipse/downloads/drops/S-3.5M6-200903130100/eclipse-SDK-3.5M6-linux-gtk.tar.gz;
sha256 = "1z8j26b632ydhqrmwgbcqgiq7f1a542jam06z2h62mcbqazrcyah";
fetchurl {
url = http://ftp-stud.fht-esslingen.de/pub/Mirrors/eclipse/eclipse/downloads/drops/R-3.2.2-200702121330/eclipse-SDK-3.2.2-linux-gtk.tar.gz;
sha256 = "0slrx8l75k91v8hqr2rvh6x0a2xdplza8gm1dc39bhyaq2gx9sdx";
};
}

View File

@@ -1,6 +1,6 @@
{stdenv, fetchurl}:
fetchurl {
url = http://nixos.org/tarballs/org.spoofax.editor_0.3.10.jar;
url = http://nix.cs.uu.nl/dist/tarballs/org.spoofax.editor_0.3.10.jar;
md5 = "ff77853e750e19a9b8d380c17ea27f3d";
}

View File

@@ -1,30 +0,0 @@
{ fetchurl, stdenv }:
stdenv.mkDerivation rec {
name = "ed-1.2";
src = fetchurl {
url = "mirror://gnu/ed/${name}.tar.gz";
sha256 = "1jhw050fzaffjf5qdj1ccn7alngam7yhd5zpzyxvrjphwmkd46kx";
};
doCheck = true;
meta = {
description = "GNU ed, an implementation of the standard Unix editor";
longDescription = ''
GNU ed is a line-oriented text editor. It is used to create,
display, modify and otherwise manipulate text files, both
interactively and via shell scripts. A restricted version of ed,
red, can only edit files in the current directory and cannot
execute shell commands. Ed is the "standard" text editor in the
sense that it is the original editor for Unix, and thus widely
available. For most purposes, however, it is superseded by
full-screen editors such as GNU Emacs or GNU Moe.
'';
license = "GPLv3+";
homepage = http://www.gnu.org/software/ed/;
};
}

View File

@@ -1,40 +0,0 @@
{ fetchurl, stdenv, ncurses }:
stdenv.mkDerivation rec {
name = "elvis-2.2_0";
src = fetchurl {
url = ftp://ftp.cs.pdx.edu/pub/elvis/elvis-2.2_0.tar.gz;
sha256 = "182fj9qzyq6cjq1r849gpam6nq9smwv9f9xwaq84961p56r6d14s";
};
buildInputs = [ ncurses ];
patchPhase = ''
sed -i s/-lcurses/-lncurses/ configure
'';
preConfigure = ''
ensureDir $out/share/man/man1
'';
installPhase = ''
ensureDir $out/bin $out/share/elvis $out/share/elvis/doc
cp elvis ref elvtags elvfmt $out/bin
cp -R data/* $out/share/elvis
cp doc/* $out/share/elvis/doc
ensureDir $out/share/man/man1
for a in doc/*.man; do
cp $a $out/share/man/man1/`basename $a .man`.1
done
'';
configureFlags = "--ioctl=termios";
meta = {
homepage = http://elvis.vi-editor.org/;
description = "A vi clone for Unix and other operating systems";
license = "free";
};
}

View File

@@ -12,7 +12,7 @@ stdenv.mkDerivation {
name = "emacs-21.4a";
builder = ./builder.sh;
src = fetchurl {
url = http://nixos.org/tarballs/emacs-21.4a.tar.gz;
url = http://nix.cs.uu.nl/dist/tarballs/emacs-21.4a.tar.gz;
md5 = "8f9d97cbd126121bd5d97e5e31168a87";
};
patches = [./crt.patch];

View File

@@ -1,28 +1,13 @@
source $stdenv/setup
preConfigure=preConfigure
preConfigure() {
libc=$(cat ${NIX_GCC}/nix-support/orig-libc)
echo "libc: $libc"
myglibc=`cat ${NIX_GCC}/nix-support/orig-libc`
echo "glibc: $myglibc"
case "${system}" in
x86_64-*) glibclibdir=lib64 ;;
*) glibclibdir=lib ;;
esac
for i in src/s/*.h src/m/*.h; do
substituteInPlace $i \
--replace /usr/${glibclibdir}/crt1.o $libc/${glibclibdir}/crt1.o \
--replace /usr/${glibclibdir}/crti.o $libc/${glibclibdir}/crti.o \
--replace /usr/${glibclibdir}/crtn.o $libc/${glibclibdir}/crtn.o \
--replace /usr/lib/crt1.o $libc/${glibclibdir}/crt1.o \
--replace /usr/lib/crti.o $libc/${glibclibdir}/crti.o \
--replace /usr/lib/crtn.o $libc/${glibclibdir}/crtn.o
done
for i in Makefile.in ./src/Makefile.in ./lib-src/Makefile.in ./leim/Makefile.in; do
substituteInPlace $i --replace /bin/pwd pwd
done
postConfigure() {
cp $myglibc/lib/crt1.o src
cp $myglibc/lib/crti.o src
cp $myglibc/lib/crtn.o src
}
postConfigure=postConfigure
genericBuild

View File

@@ -0,0 +1,41 @@
Only in emacs-21.3: configure.in~
Only in emacs-21.3: patchfile
Only in emacs-21.3/src: Makefile.in~
diff -rc emacs-orig/src/s/gnu-linux.h emacs-21.3/src/s/gnu-linux.h
*** emacs-orig/src/s/gnu-linux.h 2001-09-28 17:50:04.000000000 +0200
--- emacs-21.3/src/s/gnu-linux.h 2004-10-06 13:13:19.000000000 +0200
***************
*** 173,179 ****
/* GNU/Linux usually has crt0.o in a non-standard place */
#define START_FILES pre-crt0.o /usr/lib/crt0.o
#else
! #define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o
#endif
#ifdef __ELF__
--- 173,179 ----
/* GNU/Linux usually has crt0.o in a non-standard place */
#define START_FILES pre-crt0.o /usr/lib/crt0.o
#else
! #define START_FILES pre-crt0.o crt1.o crti.o
#endif
#ifdef __ELF__
***************
*** 225,231 ****
#else
#undef LIB_GCC
#define LIB_GCC
! #define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o
#endif
/* Don't use -g in test compiles in configure.
--- 225,231 ----
#else
#undef LIB_GCC
#define LIB_GCC
! #define LIB_STANDARD -lgcc -lc -lgcc crtn.o
#endif
/* Don't use -g in test compiles in configure.
Only in emacs-21.3/src/s: gnu-linux.h~

View File

@@ -12,35 +12,19 @@ assert xawSupport && xaw3dSupport -> Xaw3d != null;
assert xpmSupport -> libXpm != null;
assert gtkGUI -> pkgconfig != null && gtk != null;
stdenv.mkDerivation rec {
name = "emacs-22.3";
stdenv.mkDerivation {
name = "emacs-22.1";
builder = ./builder.sh;
src = fetchurl {
url = "mirror://gnu/emacs/${name}.tar.gz";
sha256 = "05hd89bchcpwzcx5la0alcp0wb7xywvnf98dxrshrqlfvccvgnbv";
url = mirror://gnu/emacs/emacs-22.1.tar.gz;
sha256 = "1l1y3il98pq3cz464p244wz2d3nga5lq8fkw5pwp5r97f7pkpi0y";
};
buildInputs = [ncurses x11]
++ stdenv.lib.optional xawSupport (if xaw3dSupport then Xaw3d else libXaw)
++ stdenv.lib.optional xpmSupport libXpm
++ stdenv.lib.optionals gtkGUI [pkgconfig gtk];
patches = [./crt.patch];
buildInputs = [
ncurses x11
(if xawSupport then if xaw3dSupport then Xaw3d else libXaw else null)
(if xpmSupport then libXpm else null)
] ++ (if gtkGUI then [pkgconfig gtk] else []);
configureFlags =
stdenv.lib.optional gtkGUI "--with-x-toolkit=gtk";
meta = {
description = "GNU Emacs, *the* text editor";
longDescription = ''
GNU Emacs is an extensible, customizable text editorand more.
At its core is an interpreter for Emacs Lisp, a dialect of the
Lisp programming language with extensions to support text
editing.
'';
homepage = http://www.gnu.org/software/emacs/;
license = "GPLv3+";
};
if gtkGUI then ["--with-x-toolkit=gtk"] else [];
}

View File

@@ -1,12 +0,0 @@
source "$stdenv/setup" || exit 1
unpackPhase && \
cd bbdb-*.* && patchPhase && \
./configure --prefix="$out" \
--with-package-dir="$out/share/emacs/site-lisp" && \
make && make install-pkg && \
mkdir -p "$out/info" && \
make -C texinfo install-pkg && \
mv "$out/share/emacs/site-lisp/lisp/bbdb/"* \
"$out/share/emacs/site-lisp" && \
rm -rf "$out/share/emacs/site-lisp/lisp"

View File

@@ -1,21 +0,0 @@
{stdenv, fetchurl, emacs, texinfo, ctags}:
stdenv.mkDerivation {
name = "bbdb-2.35";
src = fetchurl {
url = http://bbdb.sourceforge.net/bbdb-2.35.tar.gz;
sha256 = "3fb1316e2ed74d47ca61187fada550e58797467bd9e8ad67343ed16da769f916";
};
patches = [ ./install-infodir.patch ];
buildInputs = [emacs texinfo ctags];
builder = ./builder.sh;
meta = {
description = "The Insidious Big Brother Database (BBDB), a contact management utility for Emacs";
homepage = http://bbdb.sourceforge.net/;
license = "GPL";
};
}

View File

@@ -1,28 +0,0 @@
--- bbdb-2.35/texinfo/Makefile.in 2001-11-20 09:00:12.000000000 +0100
+++ bbdb-2.35/texinfo/Makefile.in 2008-02-20 12:07:36.000000000 +0100
@@ -27,22 +27,22 @@ all: info bbdb.dvi
install-pkg: uninstall-pkg info
@if test "x$(SYMLINKS)" = "xno" ; then \
for i in `ls bbdb.info* ` ; do \
- $(INSTALL_DATA) $$i $(PACKAGEDIR)/info/ ; \
+ $(INSTALL_DATA) $$i $(infodir)/ ; \
done ; \
else \
if test "x$(LINKPATH)" = "x" ; then \
for i in `ls bbdb.info* ` ; do \
- $(LN_S) `pwd`/$$i $(PACKAGEDIR)/info/$$i ; \
+ $(LN_S) `pwd`/$$i $(infodir)/$$i ; \
done ; \
else \
for i in `ls bbdb.info* ` ; do \
- $(LN_S) $(LINKPATH)/texinfo/$$i $(PACKAGEDIR)/info/$$i ; \
+ $(LN_S) $(LINKPATH)/texinfo/$$i $(infodir)/$$i ; \
done ; \
fi ; \
fi
uninstall-pkg:
- -$(RM) $(PACKAGEDIR)/info/bbdb.info*
+ -$(RM) $(infodir)/bbdb.info*
info: bbdb.info

View File

@@ -1,48 +0,0 @@
{ fetchurl, stdenv, emacs }:
stdenv.mkDerivation rec {
name = "cedet-1.0pre6";
src = fetchurl {
url = "mirror://sourceforge/cedet/${name}.tar.gz";
sha256 = "0pvd54rjlba12cxgqibm8v4i8x43r5c239z891lgcbafjvkzpdxb";
};
buildInputs = [ emacs ];
doCheck = true;
checkPhase = "make utest";
installPhase = ''
ensureDir "$out/share/emacs/site-lisp"
cp -v */*.el */*/*.el */*.elc */*/*.elc "$out/share/emacs/site-lisp"
chmod a-x "$out/share/emacs/site-lisp/"*
ensureDir "$out/share/info"
cp -v */*.info* */*/*.info* "$out/share/info"
'';
meta = {
description = "CEDET, a Collection of Emacs Development Environment Tools";
longDescription = ''
CEDET is a collection of tools written with the end goal of
creating an advanced development environment in Emacs.
Emacs already is a great environment for writing software, but
there are additional areas that need improvement. Many new
ideas for integrated environments have been developed in newer
products, such as JBuilder, Eclipse, or KDevelop. CEDET is a
project which brings together several different tools needed to
implement advanced features.
CEDET includes EIEIO (Enhanced Implementation of Emacs
Interpreted Objects), Semantic, SRecode, Speedbar, EDE (Emacs
Development Environment), and COGRE (COnnected GRaph Editor).
'';
license = "GPLv2+";
homepage = http://cedet.sourceforge.net/;
};
}

View File

@@ -2,7 +2,7 @@
name = "cua-mode-2.10";
builder = ./builder.sh;
src = fetchurl {
url = http://nixos.org/tarballs/cua-mode-2.10.el;
url = http://nix.cs.uu.nl/dist/tarballs/cua-mode-2.10.el;
md5 = "5bf5e43f5f38c8383868c7c6c5baca09";
};
}

View File

@@ -1,40 +0,0 @@
{ fetchurl, stdenv, emacs }:
stdenv.mkDerivation rec {
name = "eieio-0.17";
src = fetchurl {
url = "mirror://sourceforge/cedet/${name}.tar.gz";
sha256 = "0n31z9d47ar10g9xrnzz3nl4pmixw1nkk0kpxaillls7xvjd1zy2";
};
buildInputs = [ emacs ];
doCheck = false;
checkPhase = "make test";
installPhase = ''
ensureDir "$out/share/emacs/site-lisp"
cp -v *.el *.elc "$out/share/emacs/site-lisp"
chmod a-x "$out/share/emacs/site-lisp/"*
ensureDir "$out/share/info"
cp -v *.info* "$out/share/info"
'';
meta = {
description = "EIEIO: Enhanced Implementation of Emacs Interpreted Objects";
longDescription = ''
This package is now part of CEDET, please upgrade.
EIEIO is a package which implements a CLOS subset for Emacs. It
includes examples which can draw simple tree graphs, and bar
charts.
'';
license = "GPLv2+";
homepage = http://cedet.sourceforge.net/;
};
}

View File

@@ -1,62 +0,0 @@
{ stdenv, fetchurl, emacs, texinfo
, mpg321, vorbisTools, taglib, alsaUtils }:
# XXX: EMMS also supports Xine, MPlayer, Jack, etc.
stdenv.mkDerivation rec {
name = "emms-3.0";
src = fetchurl {
# These guys don't use ftp.gnu.org...
url = "http://www.gnu.org/software/emms/download/${name}.tar.gz";
sha256 = "151mfx97x15lfpd1qc2sqbvhwhvg46axgh15qyqmdy42vh906xav";
};
buildInputs = [ emacs texinfo ];
configurePhase = ''
sed -i "Makefile" -e "s|PREFIX *=.*\$|PREFIX = $out|g ;
s|/usr/sbin/install-info|install-info|g ;
s|/usr/include/taglib|${taglib}/include/taglib|g ;
s|/usr/lib|${taglib}/lib|g ;
s|^all:\(.*\)\$|all:\1 emms-print-metadata|g"
ensureDir "$out/share/man/man1"
sed -i "emms-player-mpg321-remote.el" \
-e 's|emms-player-mpg321-remote-command[[:blank:]]\+"mpg321"|emms-player-mpg321-remote-command "${mpg321}/bin/mpg321"|g'
sed -i "emms-player-simple.el" \
-e 's|"ogg123"|"${vorbisTools}/bin/ogg123"|g'
sed -i "emms-info-ogginfo.el" \
-e 's|emms-info-ogginfo-program-name[[:blank:]]\+"ogginfo"|emms-info-ogginfo-program-name "${vorbisTools}/bin/ogginfo"|g'
sed -i "emms-info-libtag.el" \
-e "s|\"emms-print-metadata\"|\"$out/bin/emms-print-metadata\"|g"
sed -i "emms-volume-amixer.el" \
-e 's|"amixer"|"${alsaUtils}/bin/amixer"|g'
# Use the libtag info back-end for MP3s since we're building it.
sed -i "emms-setup.el" \
-e 's|emms-info-mp3info|emms-info-libtag|g'
'';
postInstall = ''
ensureDir "$out/bin" && cp emms-print-metadata "$out/bin"
'';
meta = {
description = "GNU EMMS, The Emacs Multimedia System";
longDescription = ''
EMMS is the Emacs Multimedia System. It tries to be a clean and
small application to play multimedia files from Emacs using
external players. Many of it's ideas are derived from
MpthreePlayer, but it tries to be more general and cleaner.
The fact that EMMS is based on external players makes it
powerful, because it supports all formats that those players
support, with no effort from your side.
'';
homepage = http://www.gnu.org/software/emms/;
license = "GPLv3+";
};
}

View File

@@ -0,0 +1,6 @@
source $stdenv/setup
mkdir -p $out/emacs/site-lisp
tar zxvf $src
cp haskell-mode*/*.el $out/emacs/site-lisp
cp haskell-mode*/*.hs $out/emacs/site-lisp

View File

@@ -1,17 +1,8 @@
{stdenv, fetchurl, emacs}:
stdenv.mkDerivation rec {
name = "haskell-mode-2.4";
{stdenv, fetchurl}: stdenv.mkDerivation {
name = "haskell-mode-1.45";
builder = ./builder.sh;
src = fetchurl {
url = "http://www.iro.umontreal.ca/~monnier/elisp/${name}.tar.gz";
sha256 = "1s2dd0clwm0qaq7z43vxx437l48c88yrd3z1a6qhbq8aak9y8jc5";
url = http://nix.cs.uu.nl/dist/tarballs/haskell-mode-1.45.tar.gz;
md5 = "c609998580cdb9ca8888c7d47d22ca3b";
};
buildInputs = [emacs];
installPhase = ''
ensureDir "$out/share/emacs/site-lisp"
cp *.el *.elc *.hs "$out/share/emacs/site-lisp/"
'';
}

View File

@@ -1,13 +0,0 @@
{stdenv, fetchurl, emacs}:
stdenv.mkDerivation
{
name = "maude-mode-0.1";
src = fetchurl
{
url = "mirror://sourceforge/maude-mode/maude-mode.tar.gz";
sha256 = "12555j01mar48da2jy3ay93xfn7ybl23bpvhp0srzg8858gisx5g";
};
buildInputs = [emacs];
configureFlags = "--with-lispdir=$$out/share/emacs/site-lisp";
}

View File

@@ -2,7 +2,7 @@
name = "nxml-mode-20041004";
builder = ./builder.sh;
src = fetchurl {
url = http://nixos.org/tarballs/nxml-mode-20041004.tar.gz;
url = http://nix.cs.uu.nl/dist/tarballs/nxml-mode-20041004.tar.gz;
md5 = "ac137024cf337d6f11d8ab278d39b4db";
};
}

View File

@@ -1,7 +0,0 @@
source "$stdenv/setup" || exit 1
emacsDir="$out/share/emacs/site-lisp"
ensureDir "$emacsDir" && \
cp "$src" "$emacsDir/quack.el" && \
emacs --batch -f batch-byte-compile "$emacsDir/quack.el"

View File

@@ -1,21 +0,0 @@
{ fetchurl, stdenv, emacs }:
stdenv.mkDerivation {
name = "quack-0.30";
src = fetchurl {
# XXX: Upstream URL is not versioned, which might eventually break this.
url = "http://www.neilvandyke.org/quack/quack.el";
sha256 = "1xmpbdb064s3l3cv4agf03ir1g7xfzyvlqayr3yy5f8z3i6pf7mi";
};
buildInputs = [ emacs ];
builder = ./builder.sh;
meta = {
description = "Enhanced Emacs support for editing and running Scheme code";
homepage = http://www.neilvandyke.org/quack/;
license = "GPLv2+";
};
}

View File

@@ -1,45 +0,0 @@
{ fetchurl, stdenv, texinfo, emacs, bbdb }:
stdenv.mkDerivation rec {
# Note: Remember is part of GNU Emacs 23.
name = "remember-2.0";
src = fetchurl {
url = "http://download.gna.org/remember-el/${name}.tar.gz";
sha256 = "04bp071xjbb6mbspjpwcza0krgx2827v6rfxbsdcpn0qcjgad9wm";
};
# FIXME: It also has a (soft) dependency on Planner and Bibl-mode.
buildInputs = [ emacs bbdb texinfo ];
patchPhase = ''
sed -i "Makefile.defs" \
-e"s|^ *PREFIX *=.*$|PREFIX = $out|g ;
s|^ *ELISPDIR *=.*$|ELISPDIR = $out/share/emacs/site-lisp|g ;
s|^ *EMACS *=.*$|EMACS = emacs -L \"${bbdb}/share/emacs/site-lisp\"|g"
'';
meta = {
description = "Remember, an Emacs mode for quickly remembering data";
longDescription = ''
Remember is an Emacs mode for quickly remembering data. It uses
whatever back-end is appropriate to record and correlate the
data, but its main intention is to allow you to express as
little structure as possible up front.
When you enter data, either by typing it into a buffer, or using
the contents of the selected region, Remember will store that
data -- unindexed, uninterpreted -- in a data pool. It will
also try to remember as much context information as possible
(any text properties that were set, where you copied it from,
when, how, etc). Later, you can walk through your accumulated
set of data (both organized, and unorganized) and easily begin
moving things around, and making annotations that will express
the full meaning of that data, as far as you know it.
'';
homepage = http://gna.org/projects/remember-el/;
license = "GPLv2+";
};
}

View File

@@ -1,52 +0,0 @@
{ fetchurl, stdenv, emacs, eieio }:
stdenv.mkDerivation rec {
name = "semantic-1.4.4";
src = fetchurl {
url = "mirror://sourceforge/cedet/${name}.tar.gz";
sha256 = "0j50dqdy5bl35vqfbgxp93grs11llg9i4398044br73lvvif9n5f";
};
buildInputs = [ emacs eieio ];
doCheck = true;
checkPhase = "make Tests";
preConfigure = ''
sed -i "Makefile" -es'|^LOADPATH[[:blank:]]*=.*$|LOADPATH = ${eieio}/share/emacs/site-lisp|g'
'';
installPhase = ''
ensureDir "$out/share/emacs/site-lisp"
cp -v *.el *.elc "$out/share/emacs/site-lisp"
chmod a-x "$out/share/emacs/site-lisp/"*
ensureDir "$out/share/info"
cp -v *.info* "$out/share/info"
'';
meta = {
description = "Semantic, infrastructure for parser based text analysis in Emacs";
longDescription = ''
This package is now part of CEDET, please upgrade.
Semantic is an infrastructure for parser based text analysis in
Emacs. It is a lexer, parser-generator, and parser. It is
written in Emacs Lisp and is customized to the way Emacs thinks
about language files, and is optimized to use Emacs' parsing
capabilities.
Semantic's goal is to provide an intermediate API for authors of
language agnostic tools who want to deal with languages in a
generic way. It also provides a simple way for Mode Authors who
are experts in their language, to provide a parser for those
tool authors, without knowing anything about those tools.
'';
license = "GPLv2+";
homepage = http://cedet.sourceforge.net/;
};
}

View File

@@ -1,22 +1,17 @@
source $stdenv/setup
preConfigure=preConfigure
preConfigure() {
libc=$(cat ${NIX_GCC}/nix-support/orig-libc)
echo "libc: $libc"
myglibc=`cat ${NIX_GCC}/nix-support/orig-libc`
echo "glibc: $myglibc"
for i in src/s/*.h src/m/*.h; do
substituteInPlace $i \
--replace /usr/lib/crt1.o $libc/lib/crt1.o \
--replace /usr/lib/crti.o $libc/lib/crti.o \
--replace /usr/lib/crtn.o $libc/lib/crtn.o
done
for i in Makefile.in ./src/Makefile.in ./lib-src/Makefile.in ./leim/Makefile.in; do
substituteInPlace $i --replace /bin/pwd pwd
done
postConfigure=postConfigure
postConfigure() {
cp $myglibc/lib/crt1.o src
cp $myglibc/lib/crti.o src
cp $myglibc/lib/crtn.o src
for i in Makefile ./src/Makefile ./lib-src/Makefile ./leim/Makefile ./admin/unidata/Makefile; do
substituteInPlace $i --replace /bin/pwd pwd
done
}
preBuild="make bootstrap"
genericBuild

View File

@@ -0,0 +1,41 @@
Only in emacs-21.3: configure.in~
Only in emacs-21.3: patchfile
Only in emacs-21.3/src: Makefile.in~
diff -rc emacs-orig/src/s/gnu-linux.h emacs-21.3/src/s/gnu-linux.h
*** emacs-orig/src/s/gnu-linux.h 2001-09-28 17:50:04.000000000 +0200
--- emacs-21.3/src/s/gnu-linux.h 2004-10-06 13:13:19.000000000 +0200
***************
*** 173,179 ****
/* GNU/Linux usually has crt0.o in a non-standard place */
#define START_FILES pre-crt0.o /usr/lib/crt0.o
#else
! #define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o
#endif
#ifdef __ELF__
--- 173,179 ----
/* GNU/Linux usually has crt0.o in a non-standard place */
#define START_FILES pre-crt0.o /usr/lib/crt0.o
#else
! #define START_FILES pre-crt0.o crt1.o crti.o
#endif
#ifdef __ELF__
***************
*** 225,231 ****
#else
#undef LIB_GCC
#define LIB_GCC
! #define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o
#endif
/* Don't use -g in test compiles in configure.
--- 225,231 ----
#else
#undef LIB_GCC
#define LIB_GCC
! #define LIB_STANDARD -lgcc -lc -lgcc crtn.o
#endif
/* Don't use -g in test compiles in configure.
Only in emacs-21.3/src/s: gnu-linux.h~

View File

@@ -1,56 +1,44 @@
{ xawSupport ? true
, xpmSupport ? true
, dbusSupport ? true
, xaw3dSupport ? false
, gtkGUI ? false
, xftSupport ? false
, stdenv, fetchcvs, ncurses, x11, libXaw ? null, libXpm ? null, Xaw3d ? null
, pkgconfig ? null, gtk ? null, libXft ? null, dbus ? null
, libpng, libjpeg, libungif, libtiff, texinfo
, autoconf, automake
, stdenv, fetchurl, ncurses, x11, libXaw ? null, libXpm ? null, Xaw3d ? null
, pkgconfig ? null, gtk ? null, libXft ? null, libpng ? null
}:
assert xawSupport -> libXaw != null;
assert xpmSupport -> libXpm != null;
assert dbusSupport -> dbus != null;
assert xaw3dSupport -> Xaw3d != null;
assert gtkGUI -> pkgconfig != null && gtk != null;
assert xftSupport -> libXft != null && libpng != null; # libpng = probably a bug
let date = "2009-02-16"; in
stdenv.mkDerivation {
name = "emacs-snapshot-23-${date}";
name = "emacs-23.0.0.1-pre20070127";
builder = ./builder.sh;
src = fetchcvs {
inherit date;
cvsRoot = ":pserver:anonymous@cvs.savannah.gnu.org:/sources/emacs";
module = "emacs";
sha256 = "6ec63da94a199c5f95bf4a9aa578cf14b3d85800fd37b3562d9a446b144b0d47";
src = fetchurl {
url = http://losser.st-lab.cs.uu.nl/~eelco/dist/emacs-snapshot_20070127.orig.tar.gz;
sha256 = "1p5ds3sjxx6izzmfq4k3wkvklm8yw7spanl7zgl16s7cln3m7hv2";
};
preConfigure = "autoreconf -vfi";
patches = [
./crt.patch
# From Debian: use --enable-font-backend by default.
./xft-default.patch
];
buildInputs = [
autoconf automake
ncurses x11 texinfo
ncurses x11
(if xawSupport then libXaw else null)
(if xpmSupport then libXpm else null)
(if dbusSupport then dbus else null)
(if xaw3dSupport then Xaw3d else null)
libpng libjpeg libungif libtiff # maybe not strictly required?
]
++ (if gtkGUI then [pkgconfig gtk] else [])
++ (if xftSupport then [libXft] else []);
++ (if xftSupport then [libXft libpng] else []);
configureFlags = "
${if gtkGUI then "--with-x-toolkit=gtk --enable-font-backend --with-xft" else ""}
${if gtkGUI then "--with-gtk --enable-font-backend --with-xft" else ""}
";
meta = {
description = "GNU Emacs with Unicode, GTK and Xft support (23.x alpha)";
description = "Emacs with Unicode, GTK and Xft support (23.x alpha)";
homepage = http://www.emacswiki.org/cgi-bin/wiki/XftGnuEmacs;
license = "GPLv3+";
};
}

View File

@@ -0,0 +1,39 @@
diff -rc emacs-snapshot-20070127-orig/src/emacs.c emacs-snapshot-20070127/src/emacs.c
*** emacs-snapshot-20070127-orig/src/emacs.c Sun Jan 28 02:08:54 2007
--- emacs-snapshot-20070127/src/emacs.c Mon Feb 5 15:35:26 2007
***************
*** 1408,1417 ****
= argmatch (argv, argc, "-nl", "--no-loadup", 6, NULL, &skip_args);
#ifdef USE_FONT_BACKEND
! enable_font_backend = 0;
if (argmatch (argv, argc, "-enable-font-backend", "--enable-font-backend",
4, NULL, &skip_args))
enable_font_backend = 1;
#endif /* USE_FONT_BACKEND */
#ifdef HAVE_X_WINDOWS
--- 1408,1420 ----
= argmatch (argv, argc, "-nl", "--no-loadup", 6, NULL, &skip_args);
#ifdef USE_FONT_BACKEND
! enable_font_backend = 1;
if (argmatch (argv, argc, "-enable-font-backend", "--enable-font-backend",
4, NULL, &skip_args))
enable_font_backend = 1;
+ if (argmatch (argv, argc, "-disable-font-backend", "--disable-font-backend",
+ 4, NULL, &skip_args))
+ enable_font_backend = 0;
#endif /* USE_FONT_BACKEND */
#ifdef HAVE_X_WINDOWS
***************
*** 1817,1822 ****
--- 1820,1826 ----
{ "-no-multibyte", "--no-multibyte", 80, 0 },
{ "-nl", "--no-loadup", 70, 0 },
{ "-enable-font-backend", "--enable-font-backend", 65, 0 },
+ { "-disable-font-backend", "--disable-font-backend", 64, 0 },
/* -d must come last before the options handled in startup.el. */
{ "-d", "--display", 60, 1 },
{ "-display", 0, 60, 1 },

View File

@@ -1,28 +0,0 @@
args: with args;
stdenv.mkDerivation {
name = "jedit-4.2";
src = fetchurl {
url = mirror://sf/jedit/jedit42source.tar.gz;
sha256 = "1ckqghsw2r30kfkqfgjl4k47gdwpz8c1h85haw0y0ymq4rqh798j";
};
phases = "unpackPhase buildPhase";
buildPhase = "
sed -i 's/\\<SplashScreen\\>/org.gjt.sp.jedit.gui.SplashScreen/g' org/gjt/sp/jedit/GUIUtilities.java
ant dist
ensureDir $out/lib
cp jedit.jar $out/lib
ensureDir \$out/lib/modes
cp modes/catalog \$out/lib/modes
";
buildInputs = [ant];
meta = {
description = "really nice programmers editor written in Java. Give it a try";
homepage = http://www.jedit.org;
license = "GPL";
};
}

View File

@@ -1,18 +0,0 @@
args: with args;
stdenv.mkDerivation {
name = jedit.name+"_startscript";
java = jre+"/bin/java";
jeditjar = jedit+"/lib/jedit.jar";
phases = "buildPhase";
buildPhase = "
ensureDir \$out/bin
cat > \$out/bin/${jedit.name} << EOF
#!/bin/sh
exec $java -jar $jeditjar \\$*
EOF
chmod +x \$out/bin/${jedit.name}
";
}

View File

@@ -1,13 +1,9 @@
{stdenv, fetchurl} :
stdenv.mkDerivation {
name = "joe-3.3";
src = fetchurl {
url = mirror://sourceforge/joe-editor/joe-3.3.tar.gz;
md5 = "02221716679c039c5da00c275d61dbf4";
};
meta = {
homepage = http://joe-editor.sourceforge.net;
};
name = "joe-3.3";
src = fetchurl {
url = mirror://sourceforge/joe-editor/joe-3.3.tar.gz;
md5 = "02221716679c039c5da00c275d61dbf4";
};
}

View File

@@ -1,21 +0,0 @@
{stdenv, fetchurl, perl, arts, qt, kdelibs,
libX11, libXt, libXext, libXrender, libXft,
zlib, libpng, libjpeg, freetype, expat }:
stdenv.mkDerivation {
name = "kile-2.0.3";
src = fetchurl {
url = mirror://sourceforge/kile/kile-2.0.3.tar.bz2;
md5 = "f0296547d3e916dd385e0b8913918852";
};
buildInputs = [ perl arts qt kdelibs libX11 libXt libXext libXrender libXft
zlib libpng libjpeg freetype expat ];
meta = {
description = "An integrated LaTeX editor for KDE";
homepage = http://kile.sourceforge.net;
license = "GPLv2";
};
}

View File

@@ -1,26 +0,0 @@
{cabal, gtk2hs, binary, parsec, regexPosix, utf8String, libedit, makeWrapper}:
cabal.mkDerivation (self : {
pname = "leksah";
version = "0.4.4.1";
sha256 = "092a8gi73jhalgs4ppg8ki761vwk3gdnjwlyd4chnahbv5i1wrjw";
# !!! The explicit libedit dependency shouldn't be necessary.
extraBuildInputs = [gtk2hs binary parsec regexPosix utf8String libedit makeWrapper];
preConfigure =
''
substituteInPlace leksah.cabal --replace 'Cabal ==1.6.0.1' 'Cabal >=1.6.0.1'
'';
postInstall =
''
wrapProgram $out/bin/leksah --prefix XDG_DATA_DIRS : ${gtk2hs.gtksourceview}/share
'';
meta = {
homepage = http://leksah.org/;
description = "An Integrated Development Environment for Haskell written in Haskell";
};
})

View File

@@ -10,7 +10,7 @@ stdenv.mkDerivation {
builder = ./builder.sh;
src = fetchurl {
url = http://nixos.org/tarballs/monodevelop-0.6-pre2315.tar.bz2;
url = http://nix.cs.uu.nl/dist/tarballs/monodevelop-0.6-pre2315.tar.bz2;
md5 = "8c33df5629b0676b7ab552854c1de6fd";
};

View File

@@ -5,7 +5,7 @@ stdenv.mkDerivation {
builder = ./builder.sh;
src = fetchurl {
url = http://nixos.org/tarballs/monodoc-1.0.6.tar.gz;
url = http://nix.cs.uu.nl/dist/tarballs/monodoc-1.0.6.tar.gz;
md5 = "f2fc27e8e4717d90dc7efa2450625693";
};

View File

@@ -1,29 +1,11 @@
args: with args;
stdenv.mkDerivation (rec {
pname = "nano";
version = "2.0.7";
name = "${pname}-${version}";
{stdenv, fetchurl, ncurses, gettext}:
stdenv.mkDerivation {
name = "nano-2.0.6";
src = fetchurl {
url = "mirror://gnu/nano/${name}.tar.gz";
sha256 = "5dc783c412c4d1ff463c450d2a2f9e1ea53a43d9ba1dda92bbf5182f60db532f";
url = mirror://gnu/nano/nano-2.0.6.tar.gz;
sha256 = "0p2xfs4jzj7dvp208qdrxij7x8gbwxgnrdm7zafgpbbg1bvxh40d";
};
buildInputs = [ncurses gettext];
# configureFlags = "--enable-tiny";
configureFlags = "
--disable-browser
--disable-help
--disable-justify
--disable-mouse
--disable-operatingdir
--disable-speller
--disable-tabcomp
--disable-wrapping
";
meta = {
homepage = http://www.nano-editor.org/;
description = "A small, user-friendly console text editor";
};
})
configureFlags = "--enable-tiny";
}

View File

@@ -16,8 +16,4 @@ stdenv.mkDerivation {
buildInputs = [x11 motif libXpm];
buildFlags = if stdenv.system == "i686-linux" then "linux" else "";
meta = {
homepage = http://www.nedit.org;
};
}

View File

@@ -1,49 +0,0 @@
{ fetchurl, stdenv, ncurses }:
stdenv.mkDerivation rec {
name = "nvi-1.79";
src = fetchurl {
url = ftp://ftp.bostic.com/pub/nvi-1.79.tar.gz;
sha256 = "0cvf56rbylz7ksny6g2256sjg8yrsxrmbpk82r64rhi53sm8fnvm";
};
buildInputs = [ ncurses ];
# nvi tries to write to a usual tmp directory (/var/tmp),
# so we will force it to use /tmp.
patchPhase = ''
sed -i -e s/-lcurses/-lncurses/ \
-e s@vi_cv_path_preserve=no@vi_cv_path_preserve=/tmp/vi.recover@ \
-e s@/var/tmp@@ build/configure
'';
configurePhase = ''
mkdir mybuild
cd mybuild
../build/configure --prefix=$out --disable-curses
'';
installPhase = ''
ensureDir $out/bin $out/share/vi/catalog
for a in dutch english french german ru_SU.KOI8-R spanish swedish; do
cp ../catalog/$a $out/share/vi/catalog
done
cp nvi $out/bin/nvi
ln -s $out/bin/nvi $out/bin/vi
ln -s $out/bin/nvi $out/bin/ex
ln -s $out/bin/nvi $out/bin/view
ensureDir $out/share/man/man1
cp ../docs/USD.doc/vi.man/vi.1 $out/share/man/man1/nvi.1
ln -s $out/share/man/man1/nvi.1 $out/share/man/man1/vi
ln -s $out/share/man/man1/nvi.1 $out/share/man/man1/ex
ln -s $out/share/man/man1/nvi.1 $out/share/man/man1/view
'';
meta = {
homepage = http://www.bostic.com/vi/;
description = "The Berkeley Vi Editor";
license = "free";
};
}

View File

@@ -12,8 +12,4 @@ stdenv.mkDerivation {
buildInputs = [ncurses];
NIX_CFLAGS_COMPILE="-D_BSD_SOURCE=1";
meta = {
homepage = http://www.vim.org;
};
}

View File

@@ -1,80 +0,0 @@
# TODO tidy up eg The patchelf code is patching gvim even if you don't build it..
# but I have gvim with python support now :) - Marc
args: with args;
let inherit (args.composableDerivation) composableDerivation edf; in
composableDerivation {} {
name = "vim_configurable-7.2";
src = args.fetchurl {
url = ftp://ftp.vim.org/pub/vim/unix/vim-7.2.tar.bz2;
sha256 = "11hxkb6r2550c4n13nwr0d8afvh30qjyr5c2hw16zgay43rb0kci";
};
configureFlags = ["--enable-gui=auto" "--with-features=${args.features}"];
buildInputs = [ncurses pkgconfig]
++ [ gtk libX11 libXext libSM libXpm libXt libXaw libXau libXmu ];
# most interpreters aren't tested yet.. (see python for example how to do it)
flags = {
ftNix = {
patches = [ ./ft-nix-support.patch ];
};
}
// edf { name = "darwin"; } #Disable Darwin (Mac OS X) support.
// edf { name = "xsmp"; } #Disable XSMP session management
// edf { name = "xsmp_interact"; } #Disable XSMP interaction
// edf { name = "mzscheme"; } #Include MzScheme interpreter.
// edf { name = "perl"; feat = "perlinterp"; enable = { buildInputs = [perl]; };} #Include Perl interpreter.
// edf { name = "python"; feat = "pythoninterp"; enable = { buildInputs = [python]; }; } #Include Python interpreter.
// edf { name = "tcl"; enable = { buildInputs = [tcl]; }; } #Include Tcl interpreter.
// edf { name = "ruby"; feat = "rubyinterp"; enable = { buildInputs = [ruby]; };} #Include Ruby interpreter.
// edf { name = "cscope"; } #Include cscope interface.
// edf { name = "workshop"; } #Include Sun Visual Workshop support.
// edf { name = "netbeans"; } #Disable NetBeans integration support.
// edf { name = "sniff"; } #Include Sniff interface.
// edf { name = "multibyte"; } #Include multibyte editing support.
// edf { name = "hangulinput"; } #Include Hangul input support.
# // edf { name = "xim"; enable = { buildInputs = [xim]; }; } #Include XIM input support.
// edf { name = "fontset"; } #Include X fontset output support.
// edf { name = "acl"; } #Don't check for ACL support.
// edf { name = "gpm"; } #Don't use gpm (Linux mouse daemon).
// edf { name = "nls"; } #Don't support NLS (gettext()).
;
cfg = {
pythonSupport = true;
ftNixSupport = true; # add .nix filetype detection and minimal syntax highlighting support
};
#--enable-gui=OPTS X11 GUI default=auto OPTS=auto/no/gtk/gtk2/gnome/gnome2/motif/athena/neXtaw/photon/carbon
/*
// edf "gtk_check" "gtk_check" { } #If auto-select GUI, check for GTK default=yes
// edf "gtk2_check" "gtk2_check" { } #If GTK GUI, check for GTK+ 2 default=yes
// edf "gnome_check" "gnome_check" { } #If GTK GUI, check for GNOME default=no
// edf "motif_check" "motif_check" { } #If auto-select GUI, check for Motif default=yes
// edf "athena_check" "athena_check" { } #If auto-select GUI, check for Athena default=yes
// edf "nextaw_check" "nextaw_check" { } #If auto-select GUI, check for neXtaw default=yes
// edf "carbon_check" "carbon_check" { } #If auto-select GUI, check for Carbon default=yes
// edf "gtktest" "gtktest" { } #Do not try to compile and run a test GTK program
*/
postInstall = "
rpath=`patchelf --print-rpath \$out/bin/vim`;
for i in $\buildInputs; do
echo adding \$i/lib
rpath=\$rpath:\$i/lib
done
echo \$buildInputs
echo \$rpath
patchelf --set-rpath \$rpath \$out/bin/{vim,gvim}
";
dontStrip =1;
meta = {
description = "The most popular clone of the VI editor";
homepage = "www.vim.org";
};
}

View File

@@ -9,28 +9,17 @@ let
["athenaGUI" "libXau" "libXt" "libXaw" "libXpm" "libXext" "x11Support"]
["x11Support" "libX11"]
["hugeFeatures"]
["pythonSupport" "python"]
["perlSupport" "perl"]
["tclSupport" "tcl"]
["true" "ncurses"]
["false" "libSM"]
];
nameSuffixes = [
"hugeFeatures" "-huge"
"x11Support" "-X11"
"pythonSupport" "-python"
"perlSupport" "-perl"
"tclSupport" "-tcl"
"ximSupport" "-xim"
];
configFlags = [
"true" " "
"true" " --disable-xim "
"x11Support" " --enable-gui=auto "
"hugeFeatures" "--with-features=huge --enable-cscope --enable-multibyte --enable-xsmp "
"pythonSupport" " --enable-pythoninterp "
"perlSupport" " --enable-perlinterp "
"tclSupport" " --enable-tclinterp "
"ximSupport" " --enable-xim "
"hugeFeatures" "--with-features=huge --enable-cscope --enable-multibyte --enable-xsmp"
];
buildInputsNames = args.lib.filter (x: (null!=getVal x))
(args.lib.uniqList {inputList =
@@ -40,11 +29,11 @@ let
in
assert args.lib.checkReqs args defList reqsList;
args.stdenv.mkDerivation {
name = args.lib.condConcat "vim-7.2" nameSuffixes check;
name = args.lib.condConcat "vim-7.1" nameSuffixes check;
src = args.fetchurl {
url = ftp://ftp.vim.org/pub/vim/unix/vim-7.2.tar.bz2;
sha256 = "076ydlfcmlnldjzarahg58vflawn083y90is6sz2j4klg9mj2iim";
url = ftp://ftp.nluug.nl/pub/editors/vim/unix/vim-7.1.tar.bz2;
sha256 = "0w6gy49gdbw7hby5rjkjpa7cdvc0z5iajsm4j1h8108rvfam22kz";
};
inherit (args) ncurses;
@@ -55,10 +44,7 @@ args.stdenv.mkDerivation {
preBuild="touch src/auto/link.sed";
configureFlags = args.lib.condConcat "" configFlags check;
NIX_LDFLAGS = "-lpthread -lutil";
meta = {
description = "The most popular clone of the VI editor";
homepage = http://www.vim.org;
};
}

View File

@@ -1,66 +0,0 @@
diff --git a/runtime/filetype.vim b/runtime/filetype.vim
index a8e6261..2b008fc 100644
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -2258,6 +2258,9 @@ au BufNewFile,BufRead *.zsql call s:SQL()
" Z80 assembler asz80
au BufNewFile,BufRead *.z8a setf z8a
+" NIX
+au BufNewFile,BufRead *.nix setf nix
+
augroup END
@@ -2440,3 +2443,5 @@ endfunc
" Restore 'cpoptions'
let &cpo = s:cpo_save
unlet s:cpo_save
+
+
diff --git a/runtime/syntax/nix.vim b/runtime/syntax/nix.vim
new file mode 100644
index 0000000..a2f9918
--- /dev/null
+++ b/runtime/syntax/nix.vim
@@ -0,0 +1,40 @@
+" Vim syntax file
+" Language: nix
+" Maintainer: Marc Weber <marco-oweber@gmx.de>
+" Modify and commit if you feel that way
+" Last Change: 2007 Dec
+"
+" this syntax file can be still be enhanced very much..
+" Don't ask, do it :-)
+
+" Quit when a (custom) syntax file was already loaded
+if exists("b:current_syntax")
+ finish
+endif
+
+syn keyword nixKeyword let throw inherit import true false null with
+syn keyword nixConditional if else then
+syn keyword nixBrace ( ) { } =
+syn keyword nixBuiltin __currentSystem __currentTime __isFunction __getEnv __trace __toPath __pathExists
+ \ __readFile __toXML __toFile __filterSource __attrNames __getAttr __hasAttr __isAttrs __listToAttrs __isList
+ \ __head __tail __add __sub __lessThan __substring __stringLength
+
+syn match nixAttr "\w\+\ze\s*="
+syn match nixFuncArg "\zs\w\+\ze\s*:"
+syn region nixStringParam start=+\${+ end=+}+
+syn region nixMultiLineComment start=+/\*+ skip=+\\"+ end=+\*/+
+syn match nixEndOfLineComment "#.*$"
+syn region nixStringIndented start=+''+ skip=+'''\|''${\|"+ end=+''+ contains=nixStringParam
+syn region nixString start=+"+ skip=+\\"+ end=+"+ contains=nixStringParam
+
+hi def link nixKeyword Keyword
+hi def link nixConditional Conditional
+hi def link nixBrace Special
+hi def link nixString String
+hi def link nixStringIndented String
+hi def link nixBuiltin Special
+hi def link nixStringParam Macro
+hi def link nixMultiLineComment Comment
+hi def link nixEndOfLineComment Comment
+hi def link nixAttr Identifier
+hi def link nixFuncArg Identifier

View File

@@ -1,43 +0,0 @@
{ fetchurl, stdenv, ncurses, help2man }:
stdenv.mkDerivation rec {
name = "zile-2.3.7";
src = fetchurl {
url = "mirror://gnu/zile/${name}.tar.gz";
sha256 = "04fiqy4nwhm42pdl839av7xgmpps9wfm4srpmhgwaydvjv79dgs1";
};
buildInputs = [ ncurses help2man ];
# Tests can't be run because most of them rely on the ability to
# fiddle with the terminal.
doCheck = false;
meta = {
description = "GNU Zile, a lightweight Emacs clone";
longDescription = ''
GNU Zile, which is a lightweight Emacs clone. Zile is short
for Zile Is Lossy Emacs. Zile has been written to be as
similar as possible to Emacs; every Emacs user should feel at
home.
Zile has all of Emacs's basic editing features: it is 8-bit
clean (though it currently lacks Unicode support), and the
number of editing buffers and windows is only limited by
available memory and screen space respectively. Registers,
minibuffer completion and auto fill are available. Function
and variable names are identical with Emacs's (except those
containing the word "emacs", which instead contain the word
"zile"!).
However, all of this is packed into a program which typically
compiles to about 130Kb.
'';
homepage = http://www.gnu.org/software/zile/;
license = "GPLv3+";
};
}

View File

@@ -1,35 +1,16 @@
args: with args;
let version = "6.4.8-9"; in
stdenv.mkDerivation (rec {
name = "ImageMagick-${version}";
{stdenv, fetchurl, bzip2, freetype, graphviz, ghostscript,
libjpeg, libpng, libtiff, libX11, libxml2, zlib}:
stdenv.mkDerivation {
name = "ImageMagick-6.3.5";
src = fetchurl {
url = "mirror://imagemagick/${name}.tar.bz2";
sha256 = "1ngfs99wryrc7v5pqrjbcrvhsilc29iaj6zplzxm450f49xmpidq";
url = ftp://ftp.imagemagick.org/pub/ImageMagick/ImageMagick-6.3.5-5.tar.bz2;
sha256 = "0avq6kllxw552krxgsa72c1b44zwyhwi38dk4a4ij3fqy0svy9zh";
};
configureFlags = ''
--with-dots
--with-gs-font-dir=${ghostscript}/share/ghostscript/fonts
--with-gslib
${if args ? tetex then "--with-frozenpaths" else ""}
'';
configureFlags = " --with-dots --with-gs-font-dir="+ ghostscript +
"/share/ghostscript/fonts --with-gslib ";
buildInputs =
[ bzip2 freetype ghostscript graphviz libjpeg libpng
libtiff libX11 libxml2 zlib libtool
]
++ stdenv.lib.optional (args ? tetex) args.tetex
++ stdenv.lib.optional (args ? librsvg) args.librsvg;
preConfigure = if args ? tetex then
''
export DVIDecodeDelegate=${args.tetex}/bin/dvips
'' else "";
meta = {
homepage = http://www.imagemagick.org;
};
})
buildInputs = [bzip2 freetype ghostscript graphviz libjpeg libpng
libtiff libX11 libxml2 zlib ];
}

View File

@@ -10,7 +10,4 @@ stdenv.mkDerivation {
buildInputs = [python boost pkgconfig imagemagick];
meta = {
homepage = http://www.imagemagick.org/script/api.php;
};
}

View File

@@ -1,39 +0,0 @@
{stdenv, fetchurl, cmake, libpng, libtiff, libjpeg, panotools, libxml2 }:
stdenv.mkDerivation {
name = "autopano-sift-C-2.5.0";
src = fetchurl {
url = mirror://sourceforge/hugin/autopano-sift-C-2.5.0.tar.gz;
sha256 = "0pvkapjg7qdkjg151wjc7islly9ag8fg6bj0g5nbllv981ixjql3";
};
buildInputs = [ cmake libpng libtiff libjpeg panotools libxml2 ];
# I added these flags to get all the rpaths right, which I guess they are
# taken from the qt4 sources. Not very nice.
cmakeFlags = "-DCMAKE_SHARED_LINKER_FLAGS=\"-Wl,-rpath,$out/lib\"" +
" -DCMAKE_EXE_LINKER_FLAGS=\"-Wl,-rpath,$out/lib" +
" -lpng12 -lpano13 -ljpeg -ltiff -lz -lxml2 \"" +
" -DCMAKE_SKIP_BUILD_RPATH=ON" +
" -DCMAKE_BUILD_TYPE=Release" +
" -DCMAKE_INSTALL_PREFIX=$out";
dontUseCmakeConfigure = true;
# I rewrote the configure phase to get the $out references evaluated in
# cmakeFlags
configurePhase = ''
set -x
mkdir -p build;
cd build
eval -- "cmake .. $cmakeFlags"
set +x
'';
meta = {
homepage = http://hugin.sourceforge.net/;
description = "Implementation in C of the autopano-sift algorithm for automatically stitching panoramas";
license = "GPLv2";
};
}

View File

@@ -4,7 +4,7 @@ stdenv.mkDerivation {
name = "batik-1.6";
builder = ./builder.sh;
src = fetchurl {
url = http://nixos.org/tarballs/batik-1.6.zip;
url = http://nix.cs.uu.nl/dist/tarballs/batik-1.6.zip;
md5 = "edff288fc64f968ff96ca49763d50f3c";
};

View File

@@ -1,39 +0,0 @@
{ stdenv, fetchurl, pkgconfig, gtk, freetype, fontconfig, lcms, fltk,
flex, libtiff, libjpeg, libpng, libexif, zlib, perl, libX11,
perlXMLParser, python, pygtk, gettext, intltool, babl, gegl,
glib, makedepend, xf86vidmodeproto, xineramaproto, libXmu, openexr,
mesa, libXext, libXpm, libXxf86vm } :
stdenv.mkDerivation {
name = "cinepaint-0.22-1";
src = fetchurl {
url = mirror://sourceforge/cinepaint/cinepaint-0.22-1.tar.gz;
sha256 = "bb08a9210658959772df12408769d660999ede168b7431514e1f3cead07c0fea";
};
buildInputs = [ pkgconfig gtk freetype fontconfig lcms fltk flex libtiff
libjpeg libpng libexif zlib perl libX11 perlXMLParser python pygtk gettext
intltool babl gegl glib makedepend xf86vidmodeproto xineramaproto libXmu
openexr mesa libXext libXpm libXxf86vm ];
patches = [ ./fltk.patch ];
prePatch = ''
sed -i -e s@/usr/X11R6/bin/makedepend@${makedepend}/bin/makedepend@ \
-e s@/usr/X11R6/include/X11/extensions/xf86vmode@${xf86vidmodeproto}/include/X11/extensions/xf86vmode@ \
-e s@/usr/X11R6/include/X11/Xlib.h@${libX11}/include/X11/Xlib.h@ \
-e s@/usr/X11R6/include/X11/extensions/Xinerama.h@${xineramaproto}/include/X11/extensions/Xinerama.h@ \
-e s@/usr/X11R6/lib/libfreetype.a@${freetype}/lib/libfreetype.a@ \
plug-ins/icc_examin/icc_examin/configure \
plug-ins/icc_examin/icc_examin/configure.sh
'';
configureFlags = [ "--disable-print" "--enable-gtk2" ];
meta = {
homepage = http://www.cinepaint.org/;
license = "free";
description = "Image editor which supports images over 8bpp and ICC profiles";
};
}

View File

@@ -1,13 +0,0 @@
diff --git a/plug-ins/icc_examin/icc_examin/icc_helfer_fltk.cpp b/plug-ins/icc_examin/icc_examin/icc_helfer_fltk.cpp
index b507454..85f4441 100644
--- a/plug-ins/icc_examin/icc_examin/icc_helfer_fltk.cpp
+++ b/plug-ins/icc_examin/icc_examin/icc_helfer_fltk.cpp
@@ -226,7 +226,7 @@ namespace icc_examin_ns {
int awake(void)
{
- Fl::awake(0);
+ Fl::awake((void *)0);
return 0;
}
int leerWait(void) { return 0; }

View File

@@ -1,23 +0,0 @@
{stdenv, fetchurl, wxGTK, utillinux, zlib }:
stdenv.mkDerivation {
name = "comical-0.8";
src = fetchurl {
url = mirror://sourceforge/comical/comical-0.8.tar.gz;
sha256 = "0b6527cc06b25a937041f1eb248d0fd881cf055362097036b939817f785ab85e";
};
buildInputs = [ wxGTK utillinux zlib ];
patchPhase = ''
sed -i -e 's@"zlib\\.h"@<zlib.h>@' unzip/unzip.h
sed -i -e 's@/usr/local@'$out@ \
-e 's@-lminiunzip@-lminiunzip -lz@' Makefile
'';
installPhase = "mkdir -p $out/bin ; make install";
meta = {
description = "Viewer of CBR and CBZ files, often used to store scanned comics";
homepage = http://comical.sourceforge.net/;
license = "GPLv2+";
};
}

View File

@@ -11,6 +11,5 @@ stdenv.mkDerivation {
meta = {
description = "Gnome Diagram drawing software.";
homepage = http://www.gnome.org/projects/dia;
};
}

View File

@@ -1,17 +0,0 @@
args: with args;
stdenv.mkDerivation {
name = "djview4-4.1-2";
src = fetchurl {
url = mirror://sf/djvu/djview4-4.1-2.tar.gz;
sha256 = "10k0h892kab3n8xypw6vsnvhwil410hvvqj375pwiss4vlm5isv1";
};
buildInputs = [djvulibre qt4];
meta = {
homepage = http://djvu.sourceforge.net/djview4.html;
description = "A new portable DjVu viewer and browser plugin";
license = "GPL2";
};
}

View File

@@ -1,27 +0,0 @@
args: with args;
assert fltk.glSupport;
stdenv.mkDerivation {
name ="openexr_viewers-1.0.1";
src = fetchurl {
url = "http://download.savannah.nongnu.org/releases/openexr/openexr_viewers-1.0.1.tar.gz";
sha256 = "1w5qbcdp7sw48z1wk2v07f7p14vqqb1m2ncxyxnbkm9f4ab0ymg6";
};
inherit fltk mesa;
configurePhase = "
# don't know why.. adding these flags it works
#export CXXFLAGS=`fltk-config --use-gl --cxxflags --ldflags`
./configure --prefix=\$out --with-fltk-config=\$fltk/bin/fltk-config";
buildInputs = [openexr fltk pkgconfig mesa which openexr_ctl];
meta = {
description = "tool to view OpenEXR images";
homepage = http://openexr.com;
license = "BSD-like";
};
}

View File

@@ -10,7 +10,7 @@ stdenv.mkDerivation {
makeWrapper = ../../../build-support/make-wrapper/make-wrapper.sh;
src = fetchurl {
url = http://nixos.org/tarballs/f-spot-0.0.10.tar.bz2;
url = http://nix.cs.uu.nl/dist/tarballs/f-spot-0.0.10.tar.bz2;
md5 = "19cc6e067ccc261b0502ff6189b79832";
};
@@ -23,8 +23,4 @@ stdenv.mkDerivation {
];
inherit monoDLLFixer gtksharp sqlite libgnomeui;
meta = {
homepage = http://f-spot.org;
};
}

View File

@@ -1,45 +0,0 @@
{ stdenv, fetchurl, libjpeg, mesa, freeglut, zlib, cmake, libX11, libxml2, libpng,
libXxf86vm }:
stdenv.mkDerivation {
name = "freepv-0.3.0_beta1";
src = fetchurl {
url = mirror://sourceforge/freepv/freepv-0.3.0_beta1.tar.gz;
sha256 = "084qqa361np73anvqrv78ngw8hjxglmdm3akkpszbwnzniw89qla";
};
buildInputs = [ libjpeg mesa freeglut zlib cmake libX11 libxml2 libpng
libXxf86vm ];
patchPhase = ''
sed -i -e '/GECKO/d' CMakeLists.txt
sed -i -e '/mozilla/d' src/CMakeLists.txt
'';
# I added these flags to get all the rpaths right, which I guess they are
# taken from the qt4 sources. Not very nice.
cmakeFlags = " -DCMAKE_EXE_LINKER_FLAGS=\"" +
" -lpng12 -lXxf86vm -ljpeg -lz -lglut -lGLU -lxml2 -lX11\"" +
" -DCMAKE_SKIP_BUILD_RPATH=ON" +
" -DCMAKE_BUILD_TYPE=Release" +
" -DCMAKE_INSTALL_PREFIX=$out";
dontUseCmakeConfigure = true;
# I rewrote the configure phase to get the $out references evaluated in
# cmakeFlags
configurePhase = ''
set -x
mkdir -p build;
cd build
eval -- "cmake .. $cmakeFlags"
set +x
'';
meta = {
description = "Open source panorama viewer using GL";
homepage = http://freepv.sourceforge.net/;
license = "LGPL";
};
}

Some files were not shown because too many files have changed in this diff Show More