mirror of
https://github.com/CHN-beta/nixpkgs.git
synced 2026-01-12 10:50:30 +08:00
Compare commits
97 Commits
backups/ma
...
0.5.1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
43e48ecbfc | ||
|
|
b9686c27ed | ||
|
|
d811b4c9d8 | ||
|
|
d357f1a8ed | ||
|
|
163a382727 | ||
|
|
ec232441a2 | ||
|
|
adf48bddba | ||
|
|
73ad8265a8 | ||
|
|
7a1b8bfb71 | ||
|
|
1049ba5906 | ||
|
|
5c847a370a | ||
|
|
f7561cf00e | ||
|
|
11f838c363 | ||
|
|
9dddc7f142 | ||
|
|
f1d1900a92 | ||
|
|
a1c5ff3fb6 | ||
|
|
02ec562596 | ||
|
|
9c55897afc | ||
|
|
32e4b9928d | ||
|
|
381c8b926a | ||
|
|
a1ddfbc3a5 | ||
|
|
0233bc614d | ||
|
|
b874f68d80 | ||
|
|
beaff0a892 | ||
|
|
0d4967fc35 | ||
|
|
1550034ac4 | ||
|
|
798a009f1d | ||
|
|
8776ba127c | ||
|
|
de759967c8 | ||
|
|
36356d7694 | ||
|
|
57c5759250 | ||
|
|
5c9232e063 | ||
|
|
776554d9e1 | ||
|
|
7bf54b734e | ||
|
|
2b58d63ab6 | ||
|
|
6d3efc40c1 | ||
|
|
735076eb3c | ||
|
|
e50417845d | ||
|
|
8e4d58631e | ||
|
|
9c711700e4 | ||
|
|
92b3cc5cfb | ||
|
|
8feb5fab5b | ||
|
|
ab7af4709a | ||
|
|
817d1b27ef | ||
|
|
cbdf9a0408 | ||
|
|
0376334dde | ||
|
|
b3c93a41c1 | ||
|
|
24cb251dd0 | ||
|
|
00004fa6da | ||
|
|
5a4de2c5de | ||
|
|
01a1658c6b | ||
|
|
68327c3a9d | ||
|
|
04c272508c | ||
|
|
4fc3dd4a5a | ||
|
|
085e197ea3 | ||
|
|
8ed9ea8b51 | ||
|
|
12ae5363ea | ||
|
|
bc71554fc8 | ||
|
|
2fcc5fdb08 | ||
|
|
e3ff964291 | ||
|
|
5862e56f26 | ||
|
|
892b119c9d | ||
|
|
f8f9f4d12c | ||
|
|
3c699fe619 | ||
|
|
f45695f7fa | ||
|
|
bd56b7d65c | ||
|
|
8c4a80b585 | ||
|
|
9c4cfc02ce | ||
|
|
f1b459adfd | ||
|
|
e8295a80b4 | ||
|
|
f0b3c89f89 | ||
|
|
4f155b0f7a | ||
|
|
158aa95f52 | ||
|
|
ee40be39a4 | ||
|
|
4df6ec860c | ||
|
|
cbe3e13bde | ||
|
|
5941f66f0e | ||
|
|
0fd59fd7a4 | ||
|
|
de13527000 | ||
|
|
a1b3ae0c81 | ||
|
|
ab73ec398b | ||
|
|
b8b4f9ce4b | ||
|
|
d74192ee38 | ||
|
|
c8455be838 | ||
|
|
5c5db47443 | ||
|
|
e8d2b1cc36 | ||
|
|
1b39a96d37 | ||
|
|
70d26112f2 | ||
|
|
946a2d4a48 | ||
|
|
ce50734cf0 | ||
|
|
1b8e9faf08 | ||
|
|
287edecf42 | ||
|
|
f82050134e | ||
|
|
1999676d30 | ||
|
|
b7ad383924 | ||
|
|
16c0047575 | ||
|
|
08dbd48e8d |
50
pkgs/BUGS
Normal file
50
pkgs/BUGS
Normal file
@@ -0,0 +1,50 @@
|
||||
* If NIX_DEBUG is turned on (set to "1"), autoconf configure scripts
|
||||
may fail to find the correct preprocessor:
|
||||
|
||||
checking how to run the C preprocessor... /lib/cpp
|
||||
|
||||
|
||||
* When building gcc using a Nix gcc, generated libraries link against
|
||||
the libraries of the latter:
|
||||
|
||||
$ ldd /nix/store/3b1d3995c4edbf026be5c73f66f69245-gcc-3.3.3/lib/libstdc++.so
|
||||
...
|
||||
libgcc_s.so.1 => /nix/store/1f19e61d1b7051f1131f78b41b2a0e7e-gcc-3.3.2/lib/libgcc_s.so.1 (0x400de000)
|
||||
(wrong! should be .../3b1d.../lib/libgcc_s...)
|
||||
...
|
||||
|
||||
|
||||
* Subtle problems can occur if the Nix store directory or one of its
|
||||
parents is a symlink. E.g., purity checks can barf:
|
||||
|
||||
impure path `/data/nix/store/099cd9aee7d056a9922fd6dd116a3f5c-gcc-3.3.3/bin/../lib/gcc-lib/i686-pc-linux-gnu/3.3.3/crtbegin.o' used in link
|
||||
|
||||
(This happened because /nix was a symlink to /data/nix.) Maybe we
|
||||
should disallow this entirely, since, exactly because it is
|
||||
perfectly legal for a builder to expand a symlink, we can end up
|
||||
with derivates referring to paths that existed in the build
|
||||
environment but not in the target environment.
|
||||
|
||||
Disallowing this can be highly inconvenient, since it makes it
|
||||
harder to move the Nix store to a different file system. (On Linux,
|
||||
`bind' mounts can help here.)
|
||||
|
||||
|
||||
* In libXt:
|
||||
|
||||
/bin/sh ./libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I. -DXTHREADS -DXUSE_MTSAFE_API -I/nix/store/aadf0bd4a908da11d14f6538503b8408-libX11-6.2.1/include -I/nix/store/ba366e3b944ead64ec9b0490bb615874-xproto-6.6.1/include -I./include/X11 -g -O2 -c -o ActionHook.lo `test -f 'ActionHook.c' || echo './'`ActionHook.c
|
||||
mkdir .libs
|
||||
gcc -DHAVE_CONFIG_H -I. -I. -I. -DXTHREADS -DXUSE_MTSAFE_API -I/nix/store/aadf0bd4a908da11d14f6538503b8408-libX11-6.2.1/include -I/nix/store/ba366e3b944ead64ec9b0490bb615874-xproto-6.6.1/include -I./include/X11 -g -O2 -c ActionHook.c -fPIC -DPIC -o .libs/ActionHook.o
|
||||
In file included from IntrinsicI.h:55,
|
||||
from ActionHook.c:69:
|
||||
include/X11/IntrinsicP.h:54:27: X11/Intrinsic.h: No such file or directory
|
||||
|
||||
|
||||
* Then:
|
||||
|
||||
gcc -DHAVE_CONFIG_H -I. -I. -I. -DXTHREADS -DXUSE_MTSAFE_API -I/nix/store/aadf0bd4a908da11d14f6538503b8408-libX11-6.2.1/include -I/nix/store/ba366e3b944ead64ec9b0490bb615874-xproto-6.6.1/include -I./include -I./include/X11 -g -O2 -c ActionHook.c -fPIC -DPIC -o .libs/ActionHook.o
|
||||
In file included from IntrinsicI.h:55,
|
||||
from ActionHook.c:69:
|
||||
include/X11/IntrinsicP.h:202:25: X11/ObjectP.h: No such file or directory
|
||||
|
||||
(moved to include/X11; should edit include/Makefile.am)
|
||||
@@ -104,6 +104,10 @@ ELSE IF it's DATA (i.e., doe not have a straight-forward executable semantics):
|
||||
ELSE IF it's an XSLT stylesheet (okay, these are executable...):
|
||||
./data/sgml+xml/stylesheets/xslt
|
||||
|
||||
ELSE IF it's a GAME:
|
||||
|
||||
./games
|
||||
|
||||
ELSE:
|
||||
|
||||
./misc
|
||||
|
||||
1
pkgs/STABLE
Normal file
1
pkgs/STABLE
Normal file
@@ -0,0 +1 @@
|
||||
1
|
||||
16
pkgs/TODO
Normal file
16
pkgs/TODO
Normal file
@@ -0,0 +1,16 @@
|
||||
* Bump freetype to 2.1.7 (but it breaks Pango 1.2.5).
|
||||
|
||||
* Patch development/tools/misc/libtool not to search standard
|
||||
directories for libraries (like setup.sh does now). [do we want
|
||||
this?]
|
||||
|
||||
* In setup.sh: add configureFlagsArray or something
|
||||
|
||||
* Inform freedesktop people that Xaw requires Xpm.
|
||||
|
||||
* After building gcc, filter out references to /tmp/nix... in
|
||||
.../lib/libsupc++.la and .../lib/libstdc++.la
|
||||
|
||||
* diffutils retains a dependency on coreutils/bin/pr; causes stdenv to
|
||||
depend on 2 copies of coreutils (the first one impure in
|
||||
stdenv-nix-linux!)
|
||||
@@ -1 +1 @@
|
||||
0.5
|
||||
0.5.1
|
||||
|
||||
2
pkgs/applications/editors/emacs/modes/nxml/builder.sh
Executable file → Normal file
2
pkgs/applications/editors/emacs/modes/nxml/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
mkdir -p $out/emacs/site-lisp || exit 1
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
{stdenv, fetchurl}: stdenv.mkDerivation {
|
||||
name = "nxml-mode-20031031";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www.thaiopensource.com/download/nxml-mode-20031031.tar.gz;
|
||||
md5 = "4cbc32047183e6cc1b7a2757d1078bd2";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$pkgconfig $gtk $libpng"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
cd gqview-* || exit 1
|
||||
./configure --prefix=$out || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
@@ -1,22 +1,17 @@
|
||||
{stdenv, fetchurl, pkgconfig, gtk, libpng}:
|
||||
|
||||
assert !isNull pkgconfig && !isNull gtk && !isNull libpng;
|
||||
assert pkgconfig != null && gtk != null && libpng != null;
|
||||
# Note that we cannot just copy gtk's png attribute, since gtk might
|
||||
# not be linked against png.
|
||||
assert libpng == gtk.libpng;
|
||||
# !!! assert libpng == gtk.libpng;
|
||||
|
||||
derivation {
|
||||
name = "gqview-1.3.5";
|
||||
system = stdenv.system;
|
||||
stdenv.mkDerivation {
|
||||
name = "gqview-1.4.1";
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://heanet.dl.sourceforge.net/sourceforge/gqview/gqview-1.3.5.tar.gz;
|
||||
md5 = "c44687bdd636ea6e5133fb936abf880a";
|
||||
url = http://heanet.dl.sourceforge.net/sourceforge/gqview/gqview-1.4.1.tar.gz;
|
||||
md5 = "d963fbb878d78e8ebf78ea8c18caa72f";
|
||||
};
|
||||
|
||||
stdenv = stdenv;
|
||||
pkgconfig = pkgconfig;
|
||||
gtk = gtk;
|
||||
libpng = libpng;
|
||||
buildInputs = [pkgconfig gtk libpng];
|
||||
}
|
||||
|
||||
2
pkgs/applications/misc/hello/builder.sh
Executable file → Normal file
2
pkgs/applications/misc/hello/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$perl"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
|
||||
@@ -1,13 +1,11 @@
|
||||
{stdenv, fetchurl, perl}:
|
||||
|
||||
derivation {
|
||||
stdenv.mkDerivation {
|
||||
name = "hello-2.1.1";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = ftp://ftp.nluug.nl/pub/gnu/hello/hello-2.1.1.tar.gz;
|
||||
md5 = "70c9ccf9fac07f762c24f2df2290784d";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
perl = perl;
|
||||
}
|
||||
|
||||
10
pkgs/applications/misc/xchm/default.nix
Normal file
10
pkgs/applications/misc/xchm/default.nix
Normal file
@@ -0,0 +1,10 @@
|
||||
{stdenv, fetchurl, wxGTK, chmlib}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "xchm-0.9.1";
|
||||
src = fetchurl {
|
||||
url = http://belnet.dl.sourceforge.net/sourceforge/xchm/xchm-0.9.1.tar.gz;
|
||||
md5 = "5ba671e09e4c3ac46ffb5ce9d2c985eb";
|
||||
};
|
||||
buildInputs = [wxGTK chmlib];
|
||||
}
|
||||
21
pkgs/applications/networking/browsers/firefox/builder.sh
Executable file → Normal file
21
pkgs/applications/networking/browsers/firefox/builder.sh
Executable file → Normal file
@@ -1,12 +1,8 @@
|
||||
#! /bin/sh
|
||||
. $stdenv/setup
|
||||
|
||||
buildinputs="$pkgconfig $gtk $perl $zip $libIDL"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
cd mozilla || exit 1
|
||||
|
||||
cat > .mozconfig <<EOF
|
||||
preConfigure() {
|
||||
cat > .mozconfig <<EOF
|
||||
export MOZ_PHOENIX=1
|
||||
mk_add_options MOZ_PHOENIX=1
|
||||
ac_add_options --enable-crypto
|
||||
@@ -23,8 +19,11 @@ ac_add_options --enable-swg
|
||||
ac_add_options --enable-strip
|
||||
ac_add_options --enable-default-toolkit=gtk2
|
||||
EOF
|
||||
echo "ac_add_options --prefix=$out" >> .mozconfig
|
||||
echo "ac_add_options --prefix=$out" >> .mozconfig
|
||||
}
|
||||
preConfigure=preConfigure
|
||||
|
||||
./configure || exit 1
|
||||
make -f client.mk build || exit 1
|
||||
make install || exit 1
|
||||
|
||||
makeFlags="-f client.mk build"
|
||||
|
||||
genericBuild
|
||||
|
||||
@@ -1,14 +1,13 @@
|
||||
{ stdenv, fetchurl, pkgconfig, gtk, perl, zip, libIDL
|
||||
}:
|
||||
|
||||
assert !isNull pkgconfig && !isNull gtk && !isNull perl
|
||||
&& !isNull zip && !isNull libIDL;
|
||||
assert pkgconfig != null && gtk != null && perl != null
|
||||
&& zip != null && libIDL != null;
|
||||
|
||||
assert libIDL.glib == gtk.glib;
|
||||
# !!! assert libIDL.glib == gtk.glib;
|
||||
|
||||
derivation {
|
||||
stdenv.mkDerivation {
|
||||
name = "firefox-0.8";
|
||||
system = stdenv.system;
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
@@ -16,10 +15,5 @@ derivation {
|
||||
md5 = "cdc85152f4219bf3e3f1a8dc46e04654";
|
||||
};
|
||||
|
||||
stdenv = stdenv;
|
||||
pkgconfig = pkgconfig;
|
||||
gtk = gtk;
|
||||
perl = perl;
|
||||
zip = zip;
|
||||
libIDL = libIDL;
|
||||
buildInputs = [pkgconfig gtk perl zip libIDL];
|
||||
}
|
||||
|
||||
20
pkgs/applications/networking/mailreaders/sylpheed/builder.sh
Executable file → Normal file
20
pkgs/applications/networking/mailreaders/sylpheed/builder.sh
Executable file → Normal file
@@ -1,20 +1,14 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$gtk $gdkpixbuf $openssl"
|
||||
. $stdenv/setup || exit 1
|
||||
buildInputs="$gtk $gdkpixbuf $openssl"
|
||||
. $stdenv/setup
|
||||
|
||||
if test $sslSupport; then
|
||||
extraflags="--enable-ssl $extraflags"
|
||||
configureFlags="--enable-ssl $extraflags"
|
||||
fi
|
||||
|
||||
if test $imageSupport; then
|
||||
extraflags="--enable-gdk-pixbuf $extraflags"
|
||||
configureFlags="--enable-gdk-pixbuf $extraflags"
|
||||
else
|
||||
extraflags="--disable-gdk-pixbuf --disable-imlibtest $extraflags"
|
||||
fi
|
||||
configureFlags="--disable-gdk-pixbuf --disable-imlibtest $extraflags"
|
||||
fi
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
cd sylpheed-* || exit 1
|
||||
./configure --prefix=$out $extraflags || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
genericBuild
|
||||
|
||||
@@ -3,25 +3,22 @@
|
||||
, stdenv, fetchurl, gtk, openssl ? null, gdkpixbuf ? null
|
||||
}:
|
||||
|
||||
assert !isNull gtk;
|
||||
assert sslSupport -> !isNull openssl;
|
||||
assert imageSupport -> !isNull gdkpixbuf;
|
||||
assert gtk != null;
|
||||
assert sslSupport -> openssl != null;
|
||||
assert imageSupport -> gdkpixbuf != null;
|
||||
|
||||
derivation {
|
||||
name = "sylpheed-0.9.8a";
|
||||
system = stdenv.system;
|
||||
stdenv.mkDerivation {
|
||||
name = "sylpheed-0.9.10";
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://sylpheed.good-day.net/sylpheed/sylpheed-0.9.8a.tar.bz2;
|
||||
md5 = "6ac823f06d8fe4f265f37d9c96068e05";
|
||||
url = http://sylpheed.good-day.net/sylpheed/sylpheed-0.9.10.tar.bz2;
|
||||
md5 = "4e2242436de3cf3977a1b25b1ddc4930";
|
||||
};
|
||||
|
||||
sslSupport = sslSupport;
|
||||
imageSupport = imageSupport;
|
||||
inherit sslSupport imageSupport;
|
||||
|
||||
stdenv = stdenv;
|
||||
gtk = gtk;
|
||||
inherit gtk;
|
||||
openssl = if sslSupport then openssl else null;
|
||||
gdkpixbuf = if imageSupport then gdkpixbuf else null;
|
||||
}
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$pkgconfig $gtk $gtkspell $gnet $libxml2 $perl $pcre"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
cd pan-* || exit 1
|
||||
./configure --prefix=$out || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
@@ -3,29 +3,23 @@
|
||||
, libxml2, perl, pcre
|
||||
}:
|
||||
|
||||
assert !isNull pkgconfig && !isNull gtk && !isNull gnet
|
||||
&& !isNull libxml2 && !isNull perl && !isNull pcre;
|
||||
assert spellChecking -> !isNull gtkspell && gtk == gtkspell.gtk;
|
||||
assert gtk.glib == gnet.glib;
|
||||
assert pkgconfig != null && gtk != null && gnet != null
|
||||
&& libxml2 != null && perl != null && pcre != null;
|
||||
assert spellChecking -> gtkspell != null /* !!! && gtk == gtkspell.gtk */;
|
||||
# !!! assert gtk.glib == gnet.glib;
|
||||
|
||||
derivation {
|
||||
name = "pan-0.14.2.90";
|
||||
system = stdenv.system;
|
||||
stdenv.mkDerivation {
|
||||
name = "pan-0.14.2.91";
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://pan.rebelbase.com/download/releases/0.14.2.90/SOURCE/pan-0.14.2.90.tar.bz2;
|
||||
md5 = "03e6d936254e775a94995ba261be23eb";
|
||||
url = http://pan.rebelbase.com/download/releases/0.14.2.91/SOURCE/pan-0.14.2.91.tar.bz2;
|
||||
md5 = "4770d899a1c1ba968ce96bc5aeb07b62";
|
||||
};
|
||||
|
||||
spellChecking = spellChecking;
|
||||
buildInputs = [
|
||||
pkgconfig gtk gnet libxml2 perl pcre
|
||||
(if spellChecking then gtkspell else null)
|
||||
];
|
||||
|
||||
stdenv = stdenv;
|
||||
pkgconfig = pkgconfig;
|
||||
gtk = gtk;
|
||||
gtkspell = if spellChecking then gtkspell else null;
|
||||
gnet = gnet;
|
||||
libxml2 = libxml2;
|
||||
perl = perl;
|
||||
pcre = pcre;
|
||||
inherit spellChecking stdenv;
|
||||
}
|
||||
|
||||
46
pkgs/applications/version-management/subversion/builder.sh
Executable file → Normal file
46
pkgs/applications/version-management/subversion/builder.sh
Executable file → Normal file
@@ -1,35 +1,35 @@
|
||||
#! /bin/sh
|
||||
buildInputs="$openssl $db4 $httpd $swig $python $expat"
|
||||
. $stdenv/setup
|
||||
|
||||
buildinputs="$openssl $db4 $httpd $swig $python $expat"
|
||||
. $stdenv/setup || exit 1
|
||||
configureFlags="--without-gdbm --disable-static"
|
||||
|
||||
if test $localServer; then
|
||||
extraflags="--with-berkeley-db=$db4 $extraflags"
|
||||
if test "$localServer"; then
|
||||
configureFlags="--with-berkeley-db=$db4 $configureFlags"
|
||||
fi
|
||||
|
||||
if test $sslSupport; then
|
||||
extraflags="--with-ssl --with-libs=$openssl $extraflags"
|
||||
if test "$sslSupport"; then
|
||||
configureFlags="--with-ssl --with-libs=$openssl $configureFlags"
|
||||
fi
|
||||
|
||||
if test $httpServer; then
|
||||
extraflags="--with-apxs=$httpd/bin/apxs --with-apr=$httpd --with-apr-util=$httpd $extraflags"
|
||||
extramakeflags="APACHE_LIBEXECDIR=$out/modules $extramakeflags"
|
||||
if test "$httpServer"; then
|
||||
configureFlags="--with-apxs=$httpd/bin/apxs --with-apr=$httpd --with-apr-util=$httpd $configureFlags"
|
||||
makeFlags="APACHE_LIBEXECDIR=$out/modules $makeFlags"
|
||||
fi
|
||||
|
||||
if test $swigBindings; then
|
||||
extraflags="--with-swig=$swig $extraflags"
|
||||
if test "$swigBindings"; then
|
||||
configureFlags="--with-swig=$swig $configureFlags"
|
||||
fi
|
||||
|
||||
echo "extra flags: $extraflags"
|
||||
installFlags="$makeFlags"
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
cd subversion-* || exit 1
|
||||
./configure --prefix=$out $extraflags \
|
||||
--without-gdbm --disable-static || exit 1
|
||||
make $extramakeflags || exit 1
|
||||
make install $extramakeflags || exit 1
|
||||
|
||||
if test $swigBindings; then
|
||||
make swig-py || exit 1
|
||||
make install-swig-py || exit 1
|
||||
fi
|
||||
postInstall() {
|
||||
if test "$swigBindings"; then
|
||||
make swig-py
|
||||
make install-swig-py
|
||||
fi
|
||||
}
|
||||
postInstall=postInstall
|
||||
|
||||
|
||||
genericBuild
|
||||
|
||||
@@ -6,20 +6,19 @@
|
||||
, openssl ? null, httpd ? null, db4 ? null, expat, swig ? null
|
||||
}:
|
||||
|
||||
assert !isNull expat;
|
||||
assert localServer -> !isNull db4;
|
||||
assert httpServer -> !isNull httpd && httpd.expat == expat;
|
||||
assert sslSupport -> !isNull openssl && (httpServer -> httpd.openssl == openssl);
|
||||
assert swigBindings -> !isNull swig && swig.pythonSupport;
|
||||
assert expat != null;
|
||||
assert localServer -> db4 != null;
|
||||
assert httpServer -> httpd != null && httpd.expat == expat;
|
||||
assert sslSupport -> openssl != null && (httpServer -> httpd.openssl == openssl);
|
||||
assert swigBindings -> swig != null && swig.pythonSupport;
|
||||
|
||||
derivation {
|
||||
name = "subversion-0.37.0";
|
||||
system = stdenv.system;
|
||||
stdenv.mkDerivation {
|
||||
name = "subversion-1.0.2";
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://subversion.tigris.org/tarballs/subversion-0.37.0.tar.gz;
|
||||
md5 = "048c4d17d5880dc8f3699020eac56224";
|
||||
url = http://subversion.tigris.org/tarballs/subversion-1.0.2.tar.bz2;
|
||||
md5 = "246ffcc67ca629ae523956c4c1a67cce";
|
||||
};
|
||||
|
||||
openssl = if sslSupport then openssl else null;
|
||||
@@ -28,5 +27,5 @@ derivation {
|
||||
swig = if swigBindings then swig else null;
|
||||
python = if swigBindings then swig.python else null;
|
||||
|
||||
inherit stdenv expat localServer httpServer sslSupport swigBindings;
|
||||
inherit expat localServer httpServer sslSupport swigBindings;
|
||||
}
|
||||
|
||||
31
pkgs/applications/video/MPlayer/builder.sh
Executable file → Normal file
31
pkgs/applications/video/MPlayer/builder.sh
Executable file → Normal file
@@ -1,19 +1,18 @@
|
||||
#! /bin/sh
|
||||
. $stdenv/setup
|
||||
|
||||
buildinputs="$freetype $x11 $alsa"
|
||||
. $stdenv/setup || exit 1
|
||||
postUnpack() {
|
||||
unpackFile $fonts
|
||||
}
|
||||
postUnpack=postUnpack
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
tar xvfj $fonts || exit 1
|
||||
cd MPlayer-* || exit 1
|
||||
./configure --prefix=$out --with-win32libdir=$win32codecs \
|
||||
--with-x11incdir=$x11/include --with-x11libdir=$x11/lib \
|
||||
configureFlags="\
|
||||
--with-win32libdir=$win32codecs \
|
||||
--with-reallibdir=$win32codecs \
|
||||
--disable-sdl --disable-esd --disable-xanim --disable-cdparanoia --disable-directfb \
|
||||
--disable-lirc --disable-svga --disable-libdv \
|
||||
--disable-vorbis --disable-png --disable-jpeg --disable-gif \
|
||||
--enable-runtime-cpudetection \
|
||||
|| exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
cp -p ../font-arial-iso-8859-1/font-arial-18-iso-8859-1/* $out/share/mplayer/font || exit 1
|
||||
--enable-runtime-cpudetection"
|
||||
|
||||
postInstall() {
|
||||
cp -p ../font-arial-iso-8859-1/font-arial-18-iso-8859-1/* $out/share/mplayer/font
|
||||
}
|
||||
postInstall=postInstall
|
||||
|
||||
genericBuild
|
||||
|
||||
@@ -1,31 +1,30 @@
|
||||
{ alsaSupport ? false
|
||||
, stdenv, fetchurl, x11, freetype, alsa ? null}:
|
||||
{ alsaSupport ? false, xvSupport ? true
|
||||
, stdenv, fetchurl, x11, libXv, freetype, zlib, alsa ? null}:
|
||||
|
||||
assert !isNull x11 && !isNull freetype;
|
||||
assert alsaSupport -> !isNull alsa;
|
||||
assert x11 != null && freetype != null;
|
||||
assert alsaSupport -> alsa != null;
|
||||
assert xvSupport -> libXv != null;
|
||||
|
||||
derivation {
|
||||
name = "MPlayer-1.0pre3";
|
||||
system = stdenv.system;
|
||||
stdenv.mkDerivation {
|
||||
name = "MPlayer-1.0pre4";
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www2.mplayerhq.hu/MPlayer/releases/MPlayer-1.0pre3.tar.bz2;
|
||||
md5 = "998becb79417c6a14d15c07e85188b82";
|
||||
url = http://www2.mplayerhq.hu/MPlayer/releases/MPlayer-1.0pre4.tar.bz2;
|
||||
md5 = "83ebac0f05b192516a41fca2350ca01a";
|
||||
};
|
||||
fonts = fetchurl {
|
||||
url = http://www2.mplayerhq.hu/MPlayer/releases/fonts/font-arial-iso-8859-1.tar.bz2;
|
||||
md5 = "1ecd31d17b51f16332b1fcc7da36b312";
|
||||
};
|
||||
|
||||
alsaSupport = alsaSupport;
|
||||
|
||||
stdenv = stdenv;
|
||||
x11 = x11;
|
||||
freetype = freetype;
|
||||
alsa = if alsaSupport then alsa else null;
|
||||
win32codecs = (import ./win32codecs) {
|
||||
stdenv = stdenv;
|
||||
fetchurl = fetchurl;
|
||||
inherit stdenv fetchurl;
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
x11 libXv freetype zlib
|
||||
(if alsaSupport then alsa else null)
|
||||
(if xvSupport then libXv else null)
|
||||
];
|
||||
}
|
||||
|
||||
16
pkgs/applications/video/MPlayer/win32codecs/builder.sh
Executable file → Normal file
16
pkgs/applications/video/MPlayer/win32codecs/builder.sh
Executable file → Normal file
@@ -1,9 +1,11 @@
|
||||
#! /bin/sh
|
||||
. $stdenv/setup
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
buildPhase=true
|
||||
|
||||
mkdir $out || exit 1
|
||||
cd $out || exit 1
|
||||
tar xvfj $src || exit 1
|
||||
mv extralite/* . || exit 1
|
||||
rmdir extralite || exit 1
|
||||
installPhase() {
|
||||
mkdir $out
|
||||
cp -prv * $out
|
||||
}
|
||||
installPhase=installPhase
|
||||
|
||||
genericBuild
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
name = "win32codecs-1";
|
||||
system = stdenv.system;
|
||||
{stdenv, fetchurl}: stdenv.mkDerivation {
|
||||
name = "MPlayer-codecs-essential-20040427";
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www2.mplayerhq.hu/MPlayer/releases/codecs/extralite.tar.bz2;
|
||||
md5 = "4748ecae87f71e8bda9cb2e2a9bd30b4";
|
||||
url = http://www2.mplayerhq.hu/MPlayer/releases/codecs/essential-20040427.tar.bz2;
|
||||
md5 = "4ffc1682448aa870aec9d8efc1321a09";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
2
pkgs/applications/video/mplayerplug-in/builder.sh
Executable file → Normal file
2
pkgs/applications/video/mplayerplug-in/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$x11"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
{stdenv, fetchurl, x11}:
|
||||
|
||||
assert !isNull x11;
|
||||
assert x11 != null;
|
||||
|
||||
derivation {
|
||||
stdenv.mkDerivation {
|
||||
name = "mplayerplug-in-1.0pre2";
|
||||
system = stdenv.system;
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
@@ -12,6 +11,5 @@ derivation {
|
||||
md5 = "1a6eb243989c143984bb1aac63b5282e";
|
||||
};
|
||||
|
||||
stdenv = stdenv;
|
||||
x11 = x11;
|
||||
}
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$x11 $wxGTK $libdvdcss $libdvdread $libdvdplay $mpeg2dec $a52dec $libmad $alsa"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
cd vlc-* || exit 1
|
||||
./configure --prefix=$out \
|
||||
--disable-ffmpeg \
|
||||
--enable-alsa \
|
||||
|| exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
@@ -1,29 +1,26 @@
|
||||
{ stdenv, fetchurl, x11, wxGTK, libdvdcss, libdvdplay
|
||||
{ xvSupport ? true
|
||||
, stdenv, fetchurl, x11, libXv, wxGTK, libdvdcss, libdvdplay
|
||||
, mpeg2dec, a52dec, libmad, alsa}:
|
||||
|
||||
assert !isNull x11 && !isNull wxGTK && !isNull libdvdcss
|
||||
&& !isNull libdvdplay && !isNull mpeg2dec && !isNull a52dec
|
||||
&& !isNull libmad && !isNull alsa;
|
||||
assert x11 != null && wxGTK != null && libdvdcss != null
|
||||
&& libdvdplay != null && mpeg2dec != null && a52dec != null
|
||||
&& libmad != null && alsa != null;
|
||||
assert libdvdplay.libdvdread.libdvdcss == libdvdcss;
|
||||
assert xvSupport -> libXv != null;
|
||||
|
||||
derivation {
|
||||
name = "vlc-0.7.0";
|
||||
system = stdenv.system;
|
||||
stdenv.mkDerivation {
|
||||
name = "vlc-0.7.1";
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://download.videolan.org/pub/videolan/vlc/0.7.0/vlc-0.7.0.tar.gz;
|
||||
md5 = "05efef68528892ca933585c7db0842e3";
|
||||
url = http://download.videolan.org/pub/videolan/vlc/0.7.1/vlc-0.7.1.tar.gz;
|
||||
md5 = "faa5e3162a3e9b3a3d8c3dcc06f70911";
|
||||
};
|
||||
|
||||
stdenv = stdenv;
|
||||
x11 = x11;
|
||||
wxGTK = wxGTK;
|
||||
libdvdcss = libdvdcss;
|
||||
libdvdplay = libdvdplay;
|
||||
libdvdread = libdvdplay.libdvdread;
|
||||
mpeg2dec = mpeg2dec;
|
||||
a52dec = a52dec;
|
||||
libmad = libmad;
|
||||
alsa = alsa;
|
||||
buildInputs = [
|
||||
x11 wxGTK libdvdcss libdvdplay libdvdplay.libdvdread
|
||||
mpeg2dec a52dec libmad alsa
|
||||
(if xvSupport then libXv else null)
|
||||
];
|
||||
|
||||
configureFlags = "--disable-ffmpeg --enable-alsa";
|
||||
}
|
||||
|
||||
21
pkgs/applications/video/zapping/builder.sh
Executable file → Normal file
21
pkgs/applications/video/zapping/builder.sh
Executable file → Normal file
@@ -1,18 +1,9 @@
|
||||
#! /bin/sh
|
||||
. $stdenv/setup
|
||||
|
||||
buildinputs="$pkgconfig $perl $python $x11 $libgnomeui \
|
||||
$libglade $scrollkeeper $esound $gettext $zvbi $libjpeg $libpng"
|
||||
. $stdenv/setup || exit 1
|
||||
# !!! hack
|
||||
NIX_LDFLAGS="$NIX_LDFLAGS -rpath $libXext/lib"
|
||||
|
||||
# !!! hack; this is because $linuxHeaders/config.h includes some
|
||||
# file autoconf.h. What is that?
|
||||
export NIX_CFLAGS_COMPILE="-D_LINUX_CONFIG_H $NIX_CFLAGS_COMPILE"
|
||||
# !!! hack - `make install' tries to setuid to root
|
||||
installFlags="ZSFB_OWNER=`id -u` ZSFB_GROUP=`id -g`"
|
||||
|
||||
# Bug: esound is not added to LDFLAGS, and libtool then picks it up from /usr!
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
cd zapping-* || exit 1
|
||||
LDFLAGS="-L$esound/lib" ./configure --prefix=$out || exit 1
|
||||
make || exit 1
|
||||
# !!! hack - it tries to setuid to root
|
||||
make install ZSFB_OWNER=`id -u` ZSFB_GROUP=`id -g` || exit 1
|
||||
genericBuild
|
||||
|
||||
@@ -1,23 +1,23 @@
|
||||
{ teletextSupport ? true
|
||||
, jpegSupport ? true
|
||||
, pngSupport ? true
|
||||
, stdenv, fetchurl, pkgconfig, perl, python, x11, libgnomeui
|
||||
# !!! libXext shouldn't be necessary (it's in x11); but the builder needs it.
|
||||
, stdenv, fetchurl, pkgconfig, perl, python, x11, libXv, libXext, libgnomeui
|
||||
, libglade, scrollkeeper, esound, gettext
|
||||
, zvbi ? null, libjpeg ? null, libpng ? null }:
|
||||
|
||||
assert !isNull pkgconfig && !isNull perl && !isNull python &&
|
||||
!isNull x11 && !isNull libgnomeui && !isNull libglade &&
|
||||
!isNull scrollkeeper && !isNull esound && !isNull gettext;
|
||||
assert pkgconfig != null && perl != null && python != null &&
|
||||
x11 != null && libXv != null && libgnomeui != null && libglade != null &&
|
||||
scrollkeeper != null && esound != null && gettext != null;
|
||||
|
||||
assert teletextSupport -> !isNull zvbi && zvbi.pngSupport
|
||||
&& pngSupport && zvbi.libpng == libpng;
|
||||
assert teletextSupport -> zvbi != null && zvbi.pngSupport
|
||||
/* !!! && pngSupport && zvbi.libpng == libpng */;
|
||||
|
||||
assert jpegSupport -> !isNull libjpeg;
|
||||
assert pngSupport -> !isNull libpng;
|
||||
assert jpegSupport -> libjpeg != null;
|
||||
assert pngSupport -> libpng != null;
|
||||
|
||||
derivation {
|
||||
stdenv.mkDerivation {
|
||||
name = "zapping-0.7cvs6";
|
||||
system = stdenv.system;
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
@@ -25,21 +25,13 @@ derivation {
|
||||
md5 = "cdedc0088c70f4520c37066ec05cb996";
|
||||
};
|
||||
|
||||
teletextSupport = teletextSupport;
|
||||
jpegSupport = jpegSupport;
|
||||
pngSupport = pngSupport;
|
||||
inherit teletextSupport jpegSupport pngSupport libXext;
|
||||
|
||||
stdenv = stdenv;
|
||||
pkgconfig = pkgconfig;
|
||||
perl = perl;
|
||||
python = python;
|
||||
x11 = x11;
|
||||
libgnomeui = libgnomeui;
|
||||
libglade = libglade;
|
||||
scrollkeeper = scrollkeeper;
|
||||
esound = esound;
|
||||
gettext = gettext;
|
||||
zvbi = if teletextSupport then zvbi else null;
|
||||
libjpeg = if jpegSupport then libjpeg else null;
|
||||
libpng = if pngSupport then libpng else null;
|
||||
buildInputs = [
|
||||
pkgconfig perl python x11 libXv libgnomeui
|
||||
libglade scrollkeeper esound gettext
|
||||
(if teletextSupport then zvbi else null)
|
||||
(if jpegSupport then libjpeg else null)
|
||||
(if pngSupport then libpng else null)
|
||||
];
|
||||
}
|
||||
|
||||
2
pkgs/build-support/fetchfile/builder.sh
Executable file → Normal file
2
pkgs/build-support/fetchfile/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup
|
||||
|
||||
echo "copying $url into $out..."
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
{stdenv}: {pathname, md5}: derivation {
|
||||
{stdenv}: {pathname, md5}: stdenv.mkDerivation {
|
||||
name = baseNameOf (toString url);
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
stdenv = stdenv;
|
||||
pathname = pathname;
|
||||
md5 = md5;
|
||||
id = md5;
|
||||
|
||||
21
pkgs/build-support/fetchsvn/builder.sh
Executable file → Normal file
21
pkgs/build-support/fetchsvn/builder.sh
Executable file → Normal file
@@ -1,10 +1,19 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$subversion"
|
||||
. $stdenv/setup
|
||||
|
||||
echo "exporting $url (r$rev) into $out..."
|
||||
header "exporting $url (r$rev) into $out"
|
||||
|
||||
svn export -r $rev "$url" $out || exit 1
|
||||
prefetch=$(dirname $out)/svn-checkout-tmp-$md5
|
||||
echo $prefetch
|
||||
if test -e "$prefetch"; then
|
||||
mv $prefetch $out
|
||||
else
|
||||
svn export -r "$rev" "$url" $out
|
||||
fi
|
||||
|
||||
echo $rev > $out/svn-revision || exit 1
|
||||
actual=$(nix-hash $out)
|
||||
if test "$actual" != "$md5"; then
|
||||
echo "hash is $actual, expected $md5" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
stopNest
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
{stdenv, subversion}: {url, rev}: derivation {
|
||||
name = "svn-checkout";
|
||||
system = stdenv.system;
|
||||
{stdenv, subversion, nix}: {url, rev ? "HEAD", md5}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "svn-export";
|
||||
builder = ./builder.sh;
|
||||
stdenv = stdenv;
|
||||
subversion = subversion;
|
||||
url = url;
|
||||
rev = rev;
|
||||
buildInputs = [subversion nix];
|
||||
id = md5;
|
||||
inherit url rev md5;
|
||||
}
|
||||
|
||||
47
pkgs/build-support/fetchsvn/nix-prefetch-svn
Executable file
47
pkgs/build-support/fetchsvn/nix-prefetch-svn
Executable file
@@ -0,0 +1,47 @@
|
||||
#! /bin/sh -e
|
||||
|
||||
url=$1
|
||||
rev=$2
|
||||
|
||||
if test -z "$url"; then
|
||||
echo "syntax: nix-prefetch-svn URL [REVISION]" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
test -n "$rev" || rev="HEAD"
|
||||
|
||||
# !!! hacky; we should have a way to query the location of the store.
|
||||
if storeDir=$(which nix-store); then
|
||||
storeDir=$(dirname $(dirname "$storeDir"))/store
|
||||
else
|
||||
storeDir=/nix/store
|
||||
fi
|
||||
|
||||
# !!! race? should be relatively safe, `svn export' barfs if $tmpPath exists.
|
||||
tmpPath1=$storeDir/svn-checkout-tmp-$$
|
||||
|
||||
# Perform the checkout.
|
||||
svn export -r "$rev" "$url" $tmpPath1 >&2
|
||||
|
||||
# Compute the hash.
|
||||
hash=$(nix-hash $tmpPath1)
|
||||
echo "hash is $hash" >&2
|
||||
|
||||
# Rename it so that the fetchsvn builder can find it.
|
||||
tmpPath2=$storeDir/svn-checkout-tmp-$hash
|
||||
test -e $tmpPath2 || mv $tmpPath1 $tmpPath2 # !!! race
|
||||
|
||||
# Create a Nix expression that does a fetchsvn.
|
||||
nixExpr=$(dirname $(readlink -f $0))/../../system/i686-linux.nix
|
||||
storeExpr=$( \
|
||||
echo "(import $nixExpr).fetchsvn {url=\"$url\"; rev=\"$rev\"; md5=\"$hash\";}" \
|
||||
| nix-instantiate -)
|
||||
|
||||
# Realise it.
|
||||
finalPath=$(nix-store -qnB --force-realise $storeExpr)
|
||||
|
||||
echo "path is $finalPath" >&2
|
||||
|
||||
rm -rf $tmpPath2 || true
|
||||
|
||||
echo $hash
|
||||
10
pkgs/build-support/fetchurl/builder.sh
Executable file → Normal file
10
pkgs/build-support/fetchurl/builder.sh
Executable file → Normal file
@@ -1,13 +1,13 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup
|
||||
|
||||
echo "downloading $url into $out..."
|
||||
header "downloading $out from $url"
|
||||
|
||||
wget --passive-ftp "$url" -O "$out" || exit 1
|
||||
curl --fail --location --max-redirs 20 "$url" > "$out"
|
||||
|
||||
actual=$(md5sum -b $out | cut -c1-32)
|
||||
actual=$(md5sum -b "$out" | cut -c1-32)
|
||||
if test "$actual" != "$md5"; then
|
||||
echo "hash is $actual, expected $md5"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
stopNest
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
{stdenv}: {url, md5}: derivation {
|
||||
{stdenv, curl}: {url, md5}:
|
||||
|
||||
# Note that `curl' may be `null', in case of the native stdenv.
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = baseNameOf (toString url);
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
stdenv = stdenv;
|
||||
url = url;
|
||||
md5 = md5;
|
||||
buildInputs = [curl];
|
||||
id = md5;
|
||||
inherit url md5;
|
||||
}
|
||||
|
||||
83
pkgs/build-support/gcc-wrapper/builder.sh
Normal file
83
pkgs/build-support/gcc-wrapper/builder.sh
Normal file
@@ -0,0 +1,83 @@
|
||||
. $stdenv/setup
|
||||
|
||||
|
||||
# Force gcc to use ld-wrapper.sh when calling ld.
|
||||
cflagsCompile="-B$out/bin"
|
||||
|
||||
if test -z "$nativeGlibc"; then
|
||||
# The "-B$glibc/lib" flag is a quick hack to force gcc to link
|
||||
# against the crt1.o from our own glibc, rather than the one in
|
||||
# /usr/lib. The real solution is of course to prevent those paths
|
||||
# from being used by gcc in the first place.
|
||||
cflagsCompile="$cflagsCompile -B$glibc/lib -isystem $glibc/include"
|
||||
ldflags="$ldflags -L$glibc/lib -dynamic-linker $glibc/lib/ld-linux.so.2"
|
||||
fi
|
||||
|
||||
if test -n "$nativeTools"; then
|
||||
gccPath="$nativePrefix/bin"
|
||||
ldPath="$nativePrefix/bin"
|
||||
else
|
||||
ldflags="$ldflags -L$gcc/lib"
|
||||
gccPath="$gcc/bin"
|
||||
ldPath="$binutils/bin"
|
||||
fi
|
||||
|
||||
|
||||
mkdir $out
|
||||
mkdir $out/bin
|
||||
|
||||
|
||||
mkGccWrapper () {
|
||||
local dst=$1
|
||||
local src=$2
|
||||
|
||||
if ! test -f "$src"; then
|
||||
echo "$src does not exist (skipping)"
|
||||
return
|
||||
fi
|
||||
|
||||
sed \
|
||||
-e "s^@gcc@^$src^g" \
|
||||
-e "s^@out@^$out^g" \
|
||||
-e "s^@shell@^$shell^g" \
|
||||
< $gccWrapper > $dst
|
||||
chmod +x $dst
|
||||
}
|
||||
|
||||
mkGccWrapper $out/bin/gcc $gccPath/gcc
|
||||
ln -s gcc $out/bin/cc
|
||||
|
||||
mkGccWrapper $out/bin/g++ $gccPath/g++
|
||||
ln -s g++ $out/bin/c++
|
||||
|
||||
mkGccWrapper $out/bin/g77 $gccPath/g77
|
||||
ln -s g77 $out/bin/f77
|
||||
|
||||
|
||||
sed \
|
||||
-e "s^@out@^$out^g" \
|
||||
-e "s^@ldflags@^$ldflags^g" \
|
||||
-e "s^@ld@^$ldPath/ld^g" \
|
||||
-e "s^@shell@^$shell^g" \
|
||||
< $ldWrapper > $out/bin/ld
|
||||
chmod +x $out/bin/ld
|
||||
|
||||
|
||||
mkdir $out/nix-support
|
||||
test -n "$gcc" && echo $gcc > $out/nix-support/orig-gcc
|
||||
test -n "$glibc" && echo $glibc > $out/nix-support/orig-glibc
|
||||
|
||||
cat > $out/nix-support/add-flags <<EOF
|
||||
export NIX_CFLAGS_COMPILE="$cflagsCompile \$NIX_CFLAGS_COMPILE"
|
||||
export NIX_CFLAGS_LINK="$cflagsLink \$NIX_CFLAGS_LINK"
|
||||
export NIX_LDFLAGS="$ldflags \$NIX_LDFLAGS"
|
||||
export NIX_GLIBC_FLAGS_SET=1
|
||||
EOF
|
||||
|
||||
sed \
|
||||
-e "s^@gcc@^$gcc^g" \
|
||||
-e "s^@binutils@^$binutils^g" \
|
||||
-e "s^@glibc@^$glibc^g" \
|
||||
< $setupHook > $out/nix-support/setup-hook
|
||||
|
||||
cp -p $utils $out/nix-support/utils
|
||||
27
pkgs/build-support/gcc-wrapper/default.nix
Normal file
27
pkgs/build-support/gcc-wrapper/default.nix
Normal file
@@ -0,0 +1,27 @@
|
||||
# The Nix `gcc' stdenv.mkDerivation is not directly usable, since it doesn't
|
||||
# know where the C library and standard header files are. Therefore
|
||||
# the compiler produced by that package cannot be installed directly
|
||||
# in a user environment and used from the command line. This
|
||||
# stdenv.mkDerivation provides a wrapper that sets up the right environment
|
||||
# variables so that the compiler and the linker just "work".
|
||||
|
||||
{ name, stdenv, nativeTools, nativeGlibc, nativePrefix ? ""
|
||||
, gcc ? null, glibc ? null, binutils ? null, shell ? ""
|
||||
}:
|
||||
|
||||
assert nativeTools -> nativePrefix != "";
|
||||
assert !nativeTools -> gcc != null && binutils != null;
|
||||
assert !nativeGlibc -> glibc != null;
|
||||
|
||||
stdenv.mkDerivation {
|
||||
builder = ./builder.sh;
|
||||
setupHook = ./setup-hook.sh;
|
||||
gccWrapper = ./gcc-wrapper.sh;
|
||||
ldWrapper = ./ld-wrapper.sh;
|
||||
utils = ./utils.sh;
|
||||
inherit name nativeTools nativeGlibc nativePrefix gcc glibc binutils;
|
||||
langC = if nativeTools then true else gcc.langC;
|
||||
langCC = if nativeTools then true else gcc.langCC;
|
||||
langF77 = if nativeTools then false else gcc.langF77;
|
||||
shell = if shell == "" then stdenv.shell else shell;
|
||||
}
|
||||
103
pkgs/build-support/gcc-wrapper/gcc-wrapper.sh
Normal file
103
pkgs/build-support/gcc-wrapper/gcc-wrapper.sh
Normal file
@@ -0,0 +1,103 @@
|
||||
#! @shell@ -e
|
||||
|
||||
if test -n "$NIX_GCC_WRAPPER_START_HOOK"; then
|
||||
. "$NIX_GCC_WRAPPER_START_HOOK"
|
||||
fi
|
||||
|
||||
if test -z "$NIX_GLIBC_FLAGS_SET"; then
|
||||
. @out@/nix-support/add-flags
|
||||
fi
|
||||
|
||||
. @out@/nix-support/utils
|
||||
|
||||
|
||||
# Figure out if linker flags should be passed. GCC prints annoying
|
||||
# warnings when they are not needed.
|
||||
dontLink=0
|
||||
if test "$*" = "-v" -o -z "$*"; then
|
||||
dontLink=1
|
||||
else
|
||||
for i in "$@"; do
|
||||
if test "$i" = "-c"; then
|
||||
dontLink=1
|
||||
elif test "$i" = "-S"; then
|
||||
dontLink=1
|
||||
elif test "$i" = "-E"; then
|
||||
dontLink=1
|
||||
elif test "$i" = "-E"; then
|
||||
dontLink=1
|
||||
elif test "$i" = "-M"; then
|
||||
dontLink=1
|
||||
elif test "$i" = "-MM"; then
|
||||
dontLink=1
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
|
||||
# Optionally filter out paths not refering to the store.
|
||||
params=("$@")
|
||||
if test "$NIX_ENFORCE_PURITY" = "1" -a -n "$NIX_STORE"; then
|
||||
rest=()
|
||||
n=0
|
||||
while test $n -lt ${#params[*]}; do
|
||||
p=${params[n]}
|
||||
p2=${params[$((n+1))]}
|
||||
if test "${p:0:3}" = "-L/" && badPath "${p:2}"; then
|
||||
skip $p
|
||||
elif test "$p" = "-L" && badPath "$p2"; then
|
||||
n=$((n + 1)); skip $p2
|
||||
elif test "${p:0:3}" = "-I/" && badPath "${p:2}"; then
|
||||
skip $p
|
||||
elif test "$p" = "-I" && badPath "$p2"; then
|
||||
n=$((n + 1)); skip $p2
|
||||
elif test "$p" = "-isystem" && badPath "$p2"; then
|
||||
n=$((n + 1)); skip $p2
|
||||
else
|
||||
rest=("${rest[@]}" "$p")
|
||||
fi
|
||||
n=$((n + 1))
|
||||
done
|
||||
params=("${rest[@]}")
|
||||
fi
|
||||
|
||||
|
||||
# Add the flags for the C compiler proper.
|
||||
extra=($NIX_CFLAGS_COMPILE)
|
||||
|
||||
if test "$dontLink" != "1"; then
|
||||
|
||||
# Add the flags that should only be passed to the compiler when
|
||||
# linking.
|
||||
extra=(${extra[@]} $NIX_CFLAGS_LINK)
|
||||
|
||||
# Add the flags that should be passed to the linker (and prevent
|
||||
# `ld-wrapper' from adding NIX_LDFLAGS again).
|
||||
for i in $NIX_LDFLAGS; do
|
||||
extra=(${extra[@]} "-Wl,$i")
|
||||
done
|
||||
export NIX_LDFLAGS_SET=1
|
||||
|
||||
if test "$NIX_STRIP_DEBUG" = "1"; then
|
||||
# Add executable-stripping flags.
|
||||
extra=(${extra[@]} $NIX_CFLAGS_STRIP)
|
||||
fi
|
||||
fi
|
||||
|
||||
# Optionally print debug info.
|
||||
if test "$NIX_DEBUG" = "1"; then
|
||||
echo "original flags to @gcc@:" >&2
|
||||
for i in "${params[@]}"; do
|
||||
echo " $i" >&2
|
||||
done
|
||||
echo "extra flags to @gcc@:" >&2
|
||||
for i in ${extra[@]}; do
|
||||
echo " $i" >&2
|
||||
done
|
||||
fi
|
||||
|
||||
if test -n "$NIX_GCC_WRAPPER_EXEC_HOOK"; then
|
||||
. "$NIX_GCC_WRAPPER_EXEC_HOOK"
|
||||
fi
|
||||
|
||||
exec @gcc@ "${params[@]}" ${extra[@]}
|
||||
144
pkgs/build-support/gcc-wrapper/ld-wrapper.sh
Normal file
144
pkgs/build-support/gcc-wrapper/ld-wrapper.sh
Normal file
@@ -0,0 +1,144 @@
|
||||
#! @shell@ -e
|
||||
|
||||
if test -n "$NIX_LD_WRAPPER_START_HOOK"; then
|
||||
. "$NIX_LD_WRAPPER_START_HOOK"
|
||||
fi
|
||||
|
||||
if test -z "$NIX_GLIBC_FLAGS_SET"; then
|
||||
. @out@/nix-support/add-flags
|
||||
fi
|
||||
|
||||
. @out@/nix-support/utils
|
||||
|
||||
|
||||
# Optionally filter out paths not refering to the store.
|
||||
params=("$@")
|
||||
if test "$NIX_ENFORCE_PURITY" = "1" -a -n "$NIX_STORE" \
|
||||
-a \( -z "$NIX_IGNORE_LD_THROUGH_GCC" -o -z "$NIX_LDFLAGS_SET" \); then
|
||||
rest=()
|
||||
n=0
|
||||
while test $n -lt ${#params[*]}; do
|
||||
p=${params[n]}
|
||||
p2=${params[$((n+1))]}
|
||||
if test "${p:0:3}" = "-L/" && badPath "${p:2}"; then
|
||||
skip $p
|
||||
elif test "$p" = "-L" && badPath "$p2"; then
|
||||
n=$((n + 1)); skip $p2
|
||||
elif test "$p" = "-rpath" && badPath "$p2"; then
|
||||
n=$((n + 1)); skip $p2
|
||||
elif test "$p" = "-dynamic-linker" && badPath "$p2"; then
|
||||
n=$((n + 1)); skip $p2
|
||||
elif test "${p:0:1}" = "/" && badPath "$p"; then
|
||||
# We cannot skip this; barf.
|
||||
echo "impure path \`$p' used in link" >&2
|
||||
exit 1
|
||||
else
|
||||
rest=("${rest[@]}" "$p")
|
||||
fi
|
||||
n=$((n + 1))
|
||||
done
|
||||
params=("${rest[@]}")
|
||||
fi
|
||||
|
||||
|
||||
extra=()
|
||||
|
||||
if test -z "$NIX_LDFLAGS_SET"; then
|
||||
extra=(${extra[@]} $NIX_LDFLAGS)
|
||||
fi
|
||||
|
||||
|
||||
# Add all used dynamic libraries to the rpath.
|
||||
if test "$NIX_DONT_SET_RPATH" != "1"; then
|
||||
|
||||
# First, find all -L... switches.
|
||||
allParams=("${params[@]}" ${extra[@]})
|
||||
libPath=""
|
||||
addToLibPath() {
|
||||
local path="$1"
|
||||
if test "${path:0:1}" != "/"; then return 0; fi
|
||||
case "$path" in
|
||||
*..*|*./*|*/.*|*//*)
|
||||
local path2
|
||||
if path2=$(readlink -f "$path"); then
|
||||
path="$path2"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
case $libPath in
|
||||
*\ $path\ *) return 0 ;;
|
||||
esac
|
||||
libPath="$libPath $path "
|
||||
}
|
||||
n=0
|
||||
while test $n -lt ${#allParams[*]}; do
|
||||
p=${allParams[n]}
|
||||
p2=${allParams[$((n+1))]}
|
||||
if test "${p:0:3}" = "-L/"; then
|
||||
addToLibPath ${p:2}
|
||||
elif test "$p" = "-L"; then
|
||||
addToLibPath ${p2}
|
||||
n=$((n + 1))
|
||||
fi
|
||||
n=$((n + 1))
|
||||
done
|
||||
|
||||
# Second, for each -l... switch, find the directory containing the
|
||||
# library and add it to the rpath.
|
||||
rpath=""
|
||||
addToRPath() {
|
||||
# If the path is not in the store, don't add it to the rpath.
|
||||
# This typically happens for libraries in /tmp that are later
|
||||
# copied to $out/lib. If not, we're screwed.
|
||||
if test "${1:0:${#NIX_STORE}}" != "$NIX_STORE"; then return 0; fi
|
||||
case $rpath in
|
||||
*\ $1\ *) return 0 ;;
|
||||
esac
|
||||
rpath="$rpath $1 "
|
||||
}
|
||||
findLib() {
|
||||
for i in $libPath; do
|
||||
if test -f $i/lib$1.so; then
|
||||
addToRPath $i
|
||||
fi
|
||||
done
|
||||
}
|
||||
n=0
|
||||
while test $n -lt ${#allParams[*]}; do
|
||||
p=${allParams[n]}
|
||||
p2=${allParams[$((n+1))]}
|
||||
if test "${p:0:2}" = "-l"; then
|
||||
findLib ${p:2}
|
||||
elif test "$p" = "-l"; then
|
||||
# I haven't seen `-l foo', but you never know...
|
||||
findLib ${p2}
|
||||
n=$((n + 1))
|
||||
fi
|
||||
n=$((n + 1))
|
||||
done
|
||||
|
||||
# Finally, add `-rpath' switches.
|
||||
for i in $rpath; do
|
||||
extra=(${extra[@]} -rpath $i)
|
||||
done
|
||||
|
||||
fi
|
||||
|
||||
|
||||
# Optionally print debug info.
|
||||
if test "$NIX_DEBUG" = "1"; then
|
||||
echo "original flags to @ld@:" >&2
|
||||
for i in "${params[@]}"; do
|
||||
echo " $i" >&2
|
||||
done
|
||||
echo "extra flags to @ld@:" >&2
|
||||
for i in ${extra[@]}; do
|
||||
echo " $i" >&2
|
||||
done
|
||||
fi
|
||||
|
||||
if test -n "$NIX_LD_WRAPPER_EXEC_HOOK"; then
|
||||
. "$NIX_LD_WRAPPER_EXEC_HOOK"
|
||||
fi
|
||||
|
||||
exec @ld@ "${params[@]}" ${extra[@]}
|
||||
25
pkgs/build-support/gcc-wrapper/setup-hook.sh
Normal file
25
pkgs/build-support/gcc-wrapper/setup-hook.sh
Normal file
@@ -0,0 +1,25 @@
|
||||
addCVars () {
|
||||
if test -d $1/include; then
|
||||
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -I$1/include"
|
||||
fi
|
||||
|
||||
if test -d $1/lib; then
|
||||
export NIX_LDFLAGS="$NIX_LDFLAGS -L$1/lib"
|
||||
fi
|
||||
}
|
||||
|
||||
envHooks=(${envHooks[@]} addCVars)
|
||||
|
||||
# Note: these come *after* $out in the PATH (see setup.sh).
|
||||
|
||||
if test -n "@gcc@"; then
|
||||
PATH=$PATH:@gcc@/bin
|
||||
fi
|
||||
|
||||
if test -n "@binutils@"; then
|
||||
PATH=$PATH:@binutils@/bin
|
||||
fi
|
||||
|
||||
if test -n "@glibc@"; then
|
||||
PATH=$PATH:@glibc@/bin
|
||||
fi
|
||||
23
pkgs/build-support/gcc-wrapper/utils.sh
Normal file
23
pkgs/build-support/gcc-wrapper/utils.sh
Normal file
@@ -0,0 +1,23 @@
|
||||
skip () {
|
||||
if test "$NIX_DEBUG" = "1"; then
|
||||
echo "skipping impure path $1" >&2
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
# Checks whether a path is impure. E.g., `/lib/foo.so' is impure, but
|
||||
# `/nix/store/.../lib/foo.so' isn't.
|
||||
badPath() {
|
||||
local p=$1
|
||||
|
||||
# Relative paths are okay (since they're presumably relative to
|
||||
# the temporary build directory).
|
||||
if test "${p:0:1}" != "/"; then return 1; fi
|
||||
|
||||
# Otherwise, the path should refer to the store or some temporary
|
||||
# directory (including the build directory).
|
||||
test \
|
||||
"${p:0:${#NIX_STORE}}" != "$NIX_STORE" -a \
|
||||
"${p:0:4}" != "/tmp" -a \
|
||||
"${p:0:${#NIX_BUILD_TOP}}" != "$NIX_BUILD_TOP"
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
. $stdenv/setup
|
||||
|
||||
mkdir -p $out/xml/dtd/docbook
|
||||
cd $out/xml/dtd/docbook
|
||||
unpackFile $src
|
||||
13
pkgs/data/sgml+xml/schemas/xml-dtd/docbook-4.2/default.nix
Normal file
13
pkgs/data/sgml+xml/schemas/xml-dtd/docbook-4.2/default.nix
Normal file
@@ -0,0 +1,13 @@
|
||||
{stdenv, fetchurl, unzip}:
|
||||
|
||||
assert unzip != null;
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "docbook-xml-4.2";
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www.docbook.org/xml/4.2/docbook-xml-4.2.zip;
|
||||
md5 = "73fe50dfe74ca631c1602f558ed8961f";
|
||||
};
|
||||
buildInputs = [unzip];
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
. $stdenv/setup
|
||||
|
||||
mkdir -p $out/xml/dtd/docbook
|
||||
cd $out/xml/dtd/docbook
|
||||
unpackFile $src
|
||||
13
pkgs/data/sgml+xml/schemas/xml-dtd/docbook-4.3/default.nix
Normal file
13
pkgs/data/sgml+xml/schemas/xml-dtd/docbook-4.3/default.nix
Normal file
@@ -0,0 +1,13 @@
|
||||
{stdenv, fetchurl, unzip}:
|
||||
|
||||
assert unzip != null;
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "docbook-xml-4.3";
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www.docbook.org/xml/4.3/docbook-xml-4.3.zip;
|
||||
md5 = "ab200202b9e136a144db1e0864c45074";
|
||||
};
|
||||
buildInputs = [unzip];
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
. $stdenv/setup
|
||||
|
||||
mkdir -p $out/xml/dtd/docbook-ebnf
|
||||
cd $out/xml/dtd/docbook-ebnf
|
||||
stripHash $dtd
|
||||
cp -p $dtd $strippedName
|
||||
stripHash $catalog
|
||||
cp -p $catalog $strippedName
|
||||
13
pkgs/data/sgml+xml/schemas/xml-dtd/docbook-ebnf/default.nix
Normal file
13
pkgs/data/sgml+xml/schemas/xml-dtd/docbook-ebnf/default.nix
Normal file
@@ -0,0 +1,13 @@
|
||||
{stdenv, fetchurl, unzip}:
|
||||
|
||||
assert unzip != null;
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "docbook-xml-ebnf-1.2b1";
|
||||
builder = ./builder.sh;
|
||||
dtd = fetchurl {
|
||||
url = http://www.docbook.org/xml/ebnf/1.2b1/dbebnf.dtd;
|
||||
md5 = "e50f7d38caf4285965c7a247e026fa7c";
|
||||
};
|
||||
catalog = ./docbook-ebnf.cat;
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
PUBLIC "-//OASIS//DTD DocBook EBNF Module V1.0//EN"
|
||||
"dbebnf.dtd"
|
||||
@@ -1,7 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
mkdir -p $out/xml/dtd/docbook || exit 1
|
||||
cd $out/xml/dtd/docbook || exit 1
|
||||
$unzip/bin/unzip $src || exit 1
|
||||
@@ -1,15 +0,0 @@
|
||||
{stdenv, fetchurl, unzip}:
|
||||
|
||||
assert !isNull unzip;
|
||||
|
||||
derivation {
|
||||
name = "docbook-xml-4.2";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www.oasis-open.org/docbook/xml/4.2/docbook-xml-4.2.zip;
|
||||
md5 = "73fe50dfe74ca631c1602f558ed8961f";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
unzip = unzip;
|
||||
}
|
||||
16
pkgs/data/sgml+xml/stylesheets/xslt/docbook/builder.sh
Executable file → Normal file
16
pkgs/data/sgml+xml/stylesheets/xslt/docbook/builder.sh
Executable file → Normal file
@@ -1,10 +1,8 @@
|
||||
#! /bin/sh
|
||||
. $stdenv/setup
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
mkdir $out || exit 1
|
||||
cd $out || exit 1
|
||||
tar xvfz $src || exit 1
|
||||
mkdir xml || exit 1
|
||||
mkdir xml/xsl || exit 1
|
||||
mv docbook-xsl-* xml/xsl/docbook || exit 1
|
||||
mkdir $out
|
||||
cd $out
|
||||
unpackFile $src
|
||||
mkdir xml
|
||||
mkdir xml/xsl
|
||||
mv docbook-xsl-* xml/xsl/docbook
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
{stdenv, fetchurl}:
|
||||
|
||||
derivation {
|
||||
name = "docbook-xsl-1.64.1";
|
||||
system = stdenv.system;
|
||||
stdenv.mkDerivation {
|
||||
name = "docbook-xsl-1.65.1";
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://cesnet.dl.sourceforge.net/sourceforge/docbook/docbook-xsl-1.64.1.tar.gz;
|
||||
md5 = "ed766902e8381f6206d12f5c326fbd47";
|
||||
url = http://heanet.dl.sourceforge.net/sourceforge/docbook/docbook-xsl-1.65.1.tar.gz;
|
||||
md5 = "2f7d446de5523ec34a19ccbe8caf387f";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
121
pkgs/development/compilers/gcc/builder.sh
Executable file → Normal file
121
pkgs/development/compilers/gcc/builder.sh
Executable file → Normal file
@@ -1,56 +1,93 @@
|
||||
#! /bin/sh
|
||||
. $stdenv/setup
|
||||
|
||||
buildinputs="$binutils"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
FIXINC_DUMMY=$NIX_BUILD_TOP/dummy
|
||||
mkdir $FIXINC_DUMMY
|
||||
|
||||
if test "$noSysDirs" == "1"; then
|
||||
# Disable the standard include directories.
|
||||
cd gcc-* || exit 1
|
||||
cat >> ./gcc/cppdefault.h <<EOF
|
||||
|
||||
preConfigure() {
|
||||
|
||||
if test "$noSysDirs" = "1"; then
|
||||
# Disable the standard include directories.
|
||||
cat >> ./gcc/cppdefault.h <<EOF
|
||||
#undef LOCAL_INCLUDE_DIR
|
||||
#undef SYSTEM_INCLUDE_DIR
|
||||
#undef STANDARD_INCLUDE_DIR
|
||||
EOF
|
||||
cd .. || exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
# Configure.
|
||||
mkdir build || exit 1
|
||||
cd build || exit 1
|
||||
../gcc-*/configure --prefix=$out --enable-languages=c,c++ || exit 1
|
||||
# Determine the frontends to build.
|
||||
langs="c"
|
||||
if test -n "$langCC"; then
|
||||
langs="$langs,c++"
|
||||
fi
|
||||
if test -n "$langF77"; then
|
||||
langs="$langs,f77"
|
||||
fi
|
||||
|
||||
if test "$noSysDirs" == "1"; then
|
||||
# Patch some of the makefiles to force linking against our own glibc.
|
||||
extraflags="-Wl,-s $NIX_CFLAGS_COMPILE $NIX_CFLAGS_LINK"
|
||||
for i in $NIX_LDFLAGS; do
|
||||
extraflags="$extraflags -Wl,$i"
|
||||
done
|
||||
# Perform the build in a different directory.
|
||||
mkdir ../build
|
||||
cd ../build
|
||||
|
||||
mf=Makefile
|
||||
sed \
|
||||
-e "s^FLAGS_FOR_TARGET =\(.*\)^FLAGS_FOR_TARGET = \1 $extraflags^" \
|
||||
< $mf > $mf.tmp || exit 1
|
||||
mv $mf.tmp $mf
|
||||
configureScript=../$sourceRoot/configure
|
||||
configureFlags="--enable-languages=$langs"
|
||||
}
|
||||
|
||||
mf=gcc/Makefile
|
||||
sed \
|
||||
-e "s^X_CFLAGS =\(.*\)^X_CFLAGS = \1 $extraflags^" \
|
||||
< $mf > $mf.tmp || exit 1
|
||||
mv $mf.tmp $mf
|
||||
preConfigure=preConfigure
|
||||
|
||||
# Patch gcc/Makefile to prevent fixinc.sh from "fixing" system header files
|
||||
# from /usr/include.
|
||||
mf=gcc/Makefile
|
||||
sed \
|
||||
-e "s^NATIVE_SYSTEM_HEADER_DIR =\(.*\)^NATIVE_SYSTEM_HEADER_DIR = /fixinc-disabled^" \
|
||||
< $mf > $mf.tmp || exit 1
|
||||
mv $mf.tmp $mf
|
||||
fi
|
||||
|
||||
# Build and install.
|
||||
make bootstrap || exit 1
|
||||
make install || exit 1
|
||||
postConfigure() {
|
||||
if test "$noSysDirs" = "1"; then
|
||||
# Patch some of the makefiles to force linking against our own
|
||||
# glibc.
|
||||
if test -e $NIX_GCC/nix-support/orig-glibc; then
|
||||
glibc=$(cat $NIX_GCC/nix-support/orig-glibc)
|
||||
# Ugh. Copied from gcc-wrapper/builder.sh. We can't just
|
||||
# source in $NIX_GCC/nix-support/add-flags, since that
|
||||
# would cause *this* GCC to be linked against the
|
||||
# *previous* GCC. Need some more modularity there.
|
||||
extraFlags="-Wl,-s -B$glibc/lib -isystem $glibc/include \
|
||||
-L$glibc/lib -Wl,-dynamic-linker -Wl,$glibc/lib/ld-linux.so.2"
|
||||
|
||||
find $out -name "*.a" -exec strip -S {} \; || exit 1
|
||||
# Oh, what a hack. I should be shot for this.
|
||||
# In stage 1, we should link against the previous GCC, but
|
||||
# not afterwards. Otherwise we retain a dependency.
|
||||
# However, ld-wrapper, which adds the linker flags for the
|
||||
# previous GCC, is also used in stage 2/3. We can prevent
|
||||
# it from adding them by NIX_GLIBC_FLAGS_SET, but then
|
||||
# gcc-wrapper will also not add them, thereby causing
|
||||
# stage 1 to fail. So we use a trick to only set the
|
||||
# flags in gcc-wrapper.
|
||||
hook=$(pwd)/ld-wrapper-hook
|
||||
echo "NIX_GLIBC_FLAGS_SET=1" > $hook
|
||||
export NIX_LD_WRAPPER_START_HOOK=$hook
|
||||
fi
|
||||
|
||||
mf=Makefile
|
||||
sed \
|
||||
-e "s^FLAGS_FOR_TARGET =\(.*\)^FLAGS_FOR_TARGET = \1 $extraFlags^" \
|
||||
< $mf > $mf.tmp
|
||||
mv $mf.tmp $mf
|
||||
|
||||
mf=gcc/Makefile
|
||||
sed \
|
||||
-e "s^X_CFLAGS =\(.*\)^X_CFLAGS = \1 $extraFlags^" \
|
||||
< $mf > $mf.tmp
|
||||
mv $mf.tmp $mf
|
||||
|
||||
# Patch gcc/Makefile to prevent fixinc.sh from "fixing" system
|
||||
# header files from /usr/include.
|
||||
mf=gcc/Makefile
|
||||
sed \
|
||||
-e "s^NATIVE_SYSTEM_HEADER_DIR =\(.*\)^NATIVE_SYSTEM_HEADER_DIR = $FIXINC_DUMMY^" \
|
||||
< $mf > $mf.tmp
|
||||
mv $mf.tmp $mf
|
||||
fi
|
||||
}
|
||||
|
||||
postConfigure=postConfigure
|
||||
|
||||
|
||||
makeFlags="bootstrap"
|
||||
|
||||
genericBuild
|
||||
|
||||
@@ -1,12 +1,15 @@
|
||||
{stdenv, fetchurl, binutils}: derivation {
|
||||
name = "gcc-3.3.2";
|
||||
system = stdenv.system;
|
||||
{ stdenv, fetchurl, noSysDirs
|
||||
, langC ? true, langCC ? true, langF77 ? false
|
||||
}:
|
||||
|
||||
assert langC;
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "gcc-3.3.3";
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = ftp://ftp.nluug.nl/pub/gnu/gcc/gcc-3.3.2/gcc-3.3.2.tar.bz2;
|
||||
md5 = "65999f654102f5438ac8562d13a6eced";
|
||||
url = ftp://ftp.nluug.nl/mirror/languages/gcc/releases/gcc-3.3.3/gcc-3.3.3.tar.bz2;
|
||||
md5 = "3c6cfd9fcd180481063b4058cf6faff2";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
binutils = binutils;
|
||||
noSysDirs = stdenv.noSysDirs;
|
||||
inherit noSysDirs langC langCC langF77;
|
||||
}
|
||||
|
||||
@@ -4,13 +4,11 @@ assert perl != null;
|
||||
|
||||
assert stdenv.system == "i686-linux";
|
||||
|
||||
derivation {
|
||||
name = "ghc-6.2";
|
||||
system = stdenv.system;
|
||||
builder = ./boot.sh;
|
||||
stdenv.mkDerivation {
|
||||
name = "ghc-6.2.1";
|
||||
src = fetchurl {
|
||||
url = http://www.haskell.org/ghc/dist/6.2/ghc-6.2-i386-unknown-linux.tar.bz2;
|
||||
md5 = "5b2f19ca00fd7494002047d7fb4dce3e";
|
||||
url = http://www.haskell.org/ghc/dist/6.2.1/ghc-6.2.1-i386-unknown-linux.tar.bz2;
|
||||
md5 = "48d9d6b9f7bf1f15d69e8bd732ee254c";
|
||||
};
|
||||
inherit stdenv perl;
|
||||
buildInputs = [perl];
|
||||
}
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$perl"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
cd ghc-* || exit 1
|
||||
./configure --prefix=$out || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
strip -S $out/lib/*/*.a || exit 1
|
||||
@@ -1,11 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$perl $ghc $m4"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
cd ghc-* || exit 1
|
||||
./configure --prefix=$out || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
strip -S $out/lib/*/*.a || exit 1
|
||||
@@ -2,13 +2,11 @@
|
||||
|
||||
assert perl != null && ghc != null && m4 != null;
|
||||
|
||||
derivation {
|
||||
name = "ghc-6.2";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
stdenv.mkDerivation {
|
||||
name = "ghc-6.2.1";
|
||||
src = fetchurl {
|
||||
url = http://www.haskell.org/ghc/dist/6.2/ghc-6.2-src.tar.bz2;
|
||||
md5 = "cc495e263f4384e1d6b38e851bf6eca0";
|
||||
url = http://www.haskell.org/ghc/dist/6.2.1/ghc-6.2.1-src.tar.bz2;
|
||||
md5 = "fa9f90fd6b8852679c5fc16509e94d7a";
|
||||
};
|
||||
inherit stdenv perl ghc m4;
|
||||
buildInputs = [perl ghc m4];
|
||||
}
|
||||
|
||||
2
pkgs/development/compilers/helium/builder.sh
Executable file → Normal file
2
pkgs/development/compilers/helium/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$ghc"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
|
||||
@@ -2,13 +2,12 @@
|
||||
|
||||
assert ghc != null;
|
||||
|
||||
derivation {
|
||||
stdenv.mkDerivation {
|
||||
name = "helium-1.2";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www.cs.uu.nl/helium/distr/helium-1.2-src.tar.gz;
|
||||
md5 = "6ea1d6e4436e137d75f5354b4758f299";
|
||||
};
|
||||
inherit stdenv ghc;
|
||||
inherit ghc;
|
||||
}
|
||||
|
||||
1
pkgs/development/compilers/j2sdk/builder.sh
Executable file → Normal file
1
pkgs/development/compilers/j2sdk/builder.sh
Executable file → Normal file
@@ -1,4 +1,3 @@
|
||||
#!/bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
version=j2sdk1.4.2_03
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
if stdenv.system == "i686-linux"
|
||||
then
|
||||
(import ./j2sdk-sun-linux.nix) {
|
||||
stdenv = stdenv;
|
||||
fetchurl = fetchurl;
|
||||
inherit stdenv fetchurl;
|
||||
}
|
||||
else
|
||||
false
|
||||
|
||||
2
pkgs/development/compilers/jikes/builder.sh
Executable file → Normal file
2
pkgs/development/compilers/jikes/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
{stdenv, fetchurl}: stdenv.mkDerivation {
|
||||
name = "jikes-1.18";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = ftp://www-126.ibm.com/pub/jikes/1.18/jikes-1.18.tar.bz2;
|
||||
md5 = "74bbcfd31aa2d7df4b86c5fe2db315cc";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
13
pkgs/development/compilers/strategoxt/builder.sh
Executable file → Normal file
13
pkgs/development/compilers/strategoxt/builder.sh
Executable file → Normal file
@@ -1,10 +1,5 @@
|
||||
#! /bin/sh
|
||||
buildInputs="$aterm $sdf"
|
||||
. $stdenv/setup
|
||||
|
||||
buildinputs="$aterm $sdf"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar zxf $src || exit 1
|
||||
cd $dir* || exit 1
|
||||
./configure --prefix=$out --with-aterm=$aterm --with-sdf=$sdf || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
configureFlags="--with-aterm=$aterm --with-sdf=$sdf"
|
||||
genericBuild
|
||||
|
||||
@@ -1,14 +1,11 @@
|
||||
{stdenv, fetchurl, aterm, sdf}: derivation {
|
||||
name = "strategoxt-0.9.4-4626";
|
||||
system = stdenv.system;
|
||||
{stdenv, fetchurl, aterm, sdf}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "strategoxt-0.9.5";
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://losser.labs.cs.uu.nl/~mbravenb/dailydist/strategoxt/src/strategoxt-0.9.4-4626.tar.gz;
|
||||
md5 = "f33ae9fdb9d8628ae01fa0f26bfa0429";
|
||||
url = ftp://ftp.stratego-language.org/pub/stratego/StrategoXT/strategoxt-0.9.5.tar.gz;
|
||||
md5 = "c3caea5c05f8d8439450866b6d5664df";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
aterm = aterm;
|
||||
sdf = sdf;
|
||||
tarfile = "true";
|
||||
dir = "strategoxt";
|
||||
inherit aterm sdf;
|
||||
}
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
{stdenv, fetchurl, aterm, sdf}: derivation {
|
||||
name = "strategoxt-0.9.3";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = ftp://ftp.stratego-language.org/pub/stratego/StrategoXT/strategoxt-0.9.3.tar.gz;
|
||||
md5 = "3425e7ae896426481bd258817737e3d6";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
aterm = aterm;
|
||||
sdf = sdf;
|
||||
tarfile = "true";
|
||||
dir = "strategoxt";
|
||||
}
|
||||
@@ -1,14 +1,13 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$aterm $sdf $make $automake $autoconf $libtool $which"
|
||||
. $stdenv/setup || exit 1
|
||||
. $stdenv/setup
|
||||
|
||||
echo "pwd = `pwd`"
|
||||
echo "PATH = $PATH"
|
||||
|
||||
cp -r $src strategoxt || exit 1
|
||||
echo "ACLOCAL_PATH = $ACLOCAL_PATH"
|
||||
|
||||
cp -r $src strategoxt
|
||||
chmod -R +w strategoxt
|
||||
cd strategoxt || exit 1
|
||||
./bootstrap || exit 1
|
||||
./configure --prefix=$out --with-aterm=$aterm --with-sdf=$sdf || exit 1
|
||||
make install || exit 1
|
||||
cd strategoxt
|
||||
./bootstrap
|
||||
./configure --prefix=$out --with-aterm=$aterm --with-sdf=$sdf
|
||||
make install
|
||||
|
||||
@@ -1,19 +1,15 @@
|
||||
{stdenv, fetchsvn, autotools, which, aterm, sdf}: derivation {
|
||||
{stdenv, fetchsvn, autoconf, automake, libtool, which, aterm, sdf}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "strategoxt-0.9.4-4792";
|
||||
system = stdenv.system;
|
||||
|
||||
builder = ./svnbuilder.sh;
|
||||
src = fetchsvn {
|
||||
url = https://svn.cs.uu.nl:12443/repos/StrategoXT/trunk/StrategoXT;
|
||||
rev = "4792";
|
||||
md5 = "0a7bba2cabfc7a9e2b9b5b43ddb3b7ad";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
|
||||
make = autotools.make;
|
||||
automake = autotools.automake;
|
||||
autoconf = autotools.autoconf;
|
||||
libtool = autotools.libtool;
|
||||
which = which;
|
||||
|
||||
aterm = aterm;
|
||||
sdf = sdf;
|
||||
buildInputs = [autoconf automake libtool which aterm sdf];
|
||||
inherit aterm sdf libtool;
|
||||
}
|
||||
|
||||
2
pkgs/development/compilers/tiger/builder.sh
Executable file → Normal file
2
pkgs/development/compilers/tiger/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$aterm $sdf $strategoxt"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
{stdenv, fetchurl, aterm, sdf, strategoxt}: derivation {
|
||||
{stdenv, fetchurl, aterm, sdf, strategoxt}: stdenv.mkDerivation {
|
||||
name = "tiger-1.3-4631";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://losser.st-lab.cs.uu.nl/~mbravenb/dailydist/tiger/src/tiger-1.3-4631.tar.gz;
|
||||
md5 = "1ea6070d84134eb6cff7fb32a75ef90a";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
aterm = aterm;
|
||||
sdf = sdf;
|
||||
strategoxt = strategoxt;
|
||||
|
||||
1
pkgs/development/interpreters/j2re/builder.sh
Executable file → Normal file
1
pkgs/development/interpreters/j2re/builder.sh
Executable file → Normal file
@@ -1,4 +1,3 @@
|
||||
#!/bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
version=j2re1.4.2_03
|
||||
|
||||
@@ -3,8 +3,7 @@
|
||||
if stdenv.system == "i686-linux"
|
||||
then
|
||||
(import ./j2re-sun-linux.nix) {
|
||||
stdenv = stdenv;
|
||||
fetchurl = fetchurl;
|
||||
inherit stdenv fetchurl;
|
||||
}
|
||||
else
|
||||
false
|
||||
|
||||
47
pkgs/development/interpreters/perl/builder.sh
Executable file → Normal file
47
pkgs/development/interpreters/perl/builder.sh
Executable file → Normal file
@@ -1,26 +1,31 @@
|
||||
#! /bin/sh
|
||||
buildinputs="$patch"
|
||||
. $stdenv/setup
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
cd perl-* || exit 1
|
||||
tar xvfz $src
|
||||
cd perl-*
|
||||
|
||||
# Perl's Configure messes with PATH. We can't have that, so we patch it.
|
||||
# Yeah, this is an ugly hack.
|
||||
cat Configure | \
|
||||
grep -v '^paths=' | \
|
||||
grep -v '^locincpth=' | \
|
||||
grep -v '^xlibpth=' | \
|
||||
grep -v '^glibpth=' | \
|
||||
grep -v '^loclibpth=' | \
|
||||
grep -v '^locincpth=' | \
|
||||
cat > Configure.tmp || exit 1
|
||||
mv Configure.tmp Configure || exit 1
|
||||
chmod +x Configure || exit 1
|
||||
if test "$NIX_ENFORCE_PURITY" = "1" -a -n "$NIX_STORE"; then
|
||||
cat Configure | \
|
||||
grep -v '^paths=' | \
|
||||
grep -v '^locincpth=' | \
|
||||
grep -v '^xlibpth=' | \
|
||||
grep -v '^glibpth=' | \
|
||||
grep -v '^loclibpth=' | \
|
||||
grep -v '^locincpth=' | \
|
||||
cat > Configure.tmp
|
||||
mv Configure.tmp Configure
|
||||
chmod +x Configure
|
||||
fi
|
||||
|
||||
./Configure -de -Dcc=gcc -Dprefix=$out -Uinstallusrbinperl \
|
||||
-Dlocincpth="$NIX_LIBC_INCLUDES" \
|
||||
-Dloclibpth="$NIX_LIBC_LIBS" \
|
||||
|| exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
patch -p1 < $srcPatch
|
||||
|
||||
if test "$NIX_ENFORCE_PURITY" = "1" -a -n "$NIX_STORE"; then
|
||||
GLIBC=$(cat $NIX_GCC/nix-support/orig-glibc)
|
||||
extraflags="-Dlocincpth=$GLIBC/include -Dloclibpth=$GLIBC/lib"
|
||||
fi
|
||||
|
||||
./Configure -de -Dcc=gcc -Dprefix=$out -Uinstallusrbinperl $extraflags
|
||||
make
|
||||
make install
|
||||
|
||||
@@ -1,10 +1,22 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
name = "perl-5.8.0";
|
||||
system = stdenv.system;
|
||||
{stdenv, fetchurl, patch}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "perl-5.8.3";
|
||||
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = ftp://ftp.cs.uu.nl/mirror/CPAN/src/5.0/perl-5.8.1.tar.gz;
|
||||
md5 = "87cf132f1fbf23e780f0b218046438a6";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
url = ftp://ftp.cs.uu.nl/mirror/CPAN/src/5.0/perl-5.8.3.tar.gz;
|
||||
md5 = "6d2b389f8c6424b7af303f417947714f";
|
||||
};
|
||||
|
||||
# This patch does the following:
|
||||
# 1) Do use the PATH environment variable to find the `pwd' command.
|
||||
# By default, Perl will only look for it in /lib and /usr/lib.
|
||||
# !!! what are the security implications of this?
|
||||
# 2) Force the use of <errno.h>, not /usr/include/errno.h, on Linux
|
||||
# systems. (This actually appears to be due to a bug in Perl.)
|
||||
|
||||
srcPatch = ./patch;
|
||||
|
||||
inherit patch;
|
||||
}
|
||||
|
||||
42
pkgs/development/interpreters/perl/patch
Normal file
42
pkgs/development/interpreters/perl/patch
Normal file
@@ -0,0 +1,42 @@
|
||||
diff -rc perl-5.8.3-orig/ext/Errno/Errno_pm.PL perl-5.8.3/ext/Errno/Errno_pm.PL
|
||||
*** perl-5.8.3-orig/ext/Errno/Errno_pm.PL 2003-08-04 09:37:13.000000000 +0200
|
||||
--- perl-5.8.3/ext/Errno/Errno_pm.PL 2004-02-20 16:59:05.000000000 +0100
|
||||
***************
|
||||
*** 105,111 ****
|
||||
# Watch out for cross compiling for EPOC (usually done on linux)
|
||||
$file{'/usr/local/epocemx/epocsdk/include/libc/sys/errno.h'} = 1;
|
||||
} elsif ($^O eq 'linux' &&
|
||||
! $Config{gccversion} ne '' # might be using, say, Intel's icc
|
||||
) {
|
||||
# Some Linuxes have weird errno.hs which generate
|
||||
# no #file or #line directives
|
||||
--- 105,111 ----
|
||||
# Watch out for cross compiling for EPOC (usually done on linux)
|
||||
$file{'/usr/local/epocemx/epocsdk/include/libc/sys/errno.h'} = 1;
|
||||
} elsif ($^O eq 'linux' &&
|
||||
! $Config{gccversion} eq '' # might be using, say, Intel's icc
|
||||
) {
|
||||
# Some Linuxes have weird errno.hs which generate
|
||||
# no #file or #line directives
|
||||
Only in perl-5.8.3/ext/Errno: Errno_pm.PL~
|
||||
diff -rc perl-5.8.3-orig/lib/Cwd.pm perl-5.8.3/lib/Cwd.pm
|
||||
*** perl-5.8.3-orig/lib/Cwd.pm 2003-12-20 00:05:30.000000000 +0100
|
||||
--- perl-5.8.3/lib/Cwd.pm 2004-02-20 16:58:16.000000000 +0100
|
||||
***************
|
||||
*** 201,207 ****
|
||||
|
||||
# The 'natural and safe form' for UNIX (pwd may be setuid root)
|
||||
sub _backtick_pwd {
|
||||
! local @ENV{qw(PATH IFS CDPATH ENV BASH_ENV)};
|
||||
my $cwd = `$pwd_cmd`;
|
||||
# Belt-and-suspenders in case someone said "undef $/".
|
||||
local $/ = "\n";
|
||||
--- 201,207 ----
|
||||
|
||||
# The 'natural and safe form' for UNIX (pwd may be setuid root)
|
||||
sub _backtick_pwd {
|
||||
! local @ENV{qw(IFS CDPATH ENV BASH_ENV)};
|
||||
my $cwd = `$pwd_cmd`;
|
||||
# Belt-and-suspenders in case someone said "undef $/".
|
||||
local $/ = "\n";
|
||||
Only in perl-5.8.3/lib: Cwd.pm~
|
||||
2
pkgs/development/interpreters/python/builder.sh
Executable file → Normal file
2
pkgs/development/interpreters/python/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs=""
|
||||
if test -n "$zlibSupport"; then
|
||||
buildinputs="$zlib $buildinputs"
|
||||
|
||||
@@ -2,14 +2,13 @@
|
||||
|
||||
assert zlibSupport -> zlib != null;
|
||||
|
||||
derivation {
|
||||
stdenv.mkDerivation {
|
||||
name = "python-2.3.3";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www.python.org/ftp/python/2.3.3/Python-2.3.3.tar.bz2;
|
||||
md5 = "70ada9f65742ab2c77a96bcd6dffd9b1";
|
||||
};
|
||||
zlib = if zlibSupport then zlib else null;
|
||||
inherit stdenv zlibSupport;
|
||||
inherit zlibSupport;
|
||||
}
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
cd a52dec-* || exit 1
|
||||
./configure --prefix=$out || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
strip -S $out/lib/*.a || exit 1
|
||||
@@ -1,10 +1,9 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
{stdenv, fetchurl}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "a52dec-0.7.4";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://liba52.sourceforge.net/files/a52dec-0.7.4.tar.gz;
|
||||
md5 = "caa9f5bc44232dc8aeea773fea56be80";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
name = "aterm-2.0.5";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www.cwi.nl/projects/MetaEnv/aterm/aterm-2.0.5.tar.gz;
|
||||
md5 = "68aefb0c10b2ab876b8d3c0b2d0cdb1b";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
cd aterm-* || exit 1
|
||||
./configure --prefix=$out --with-gcc || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
strip -S $out/lib/*.a || exit 1
|
||||
@@ -1,10 +1,10 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
name = "aterm-2.0";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
{stdenv, fetchurl}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "aterm-2.0.5";
|
||||
configureFlags = "--with-gcc";
|
||||
src = fetchurl {
|
||||
url = http://www.cwi.nl/projects/MetaEnv/aterm/aterm-2.0.tar.gz;
|
||||
md5 = "853474e4bcf4a85f7d38a0676b36bded";
|
||||
url = http://www.cwi.nl/projects/MetaEnv/aterm/aterm-2.0.5.tar.gz;
|
||||
md5 = "68aefb0c10b2ab876b8d3c0b2d0cdb1b";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
2
pkgs/development/libraries/audiofile/builder.sh
Executable file → Normal file
2
pkgs/development/libraries/audiofile/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs=""
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
{stdenv, fetchurl}:
|
||||
|
||||
derivation {
|
||||
stdenv.mkDerivation {
|
||||
name = "audiofile-0.2.3";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www.68k.org/~michael/audiofile/audiofile-0.2.5.tar.gz;
|
||||
md5 = "fd07c62a17ceafa317929e55e51e26c5";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
16
pkgs/development/libraries/chmlib/builder.sh
Normal file
16
pkgs/development/libraries/chmlib/builder.sh
Normal file
@@ -0,0 +1,16 @@
|
||||
. $stdenv/setup
|
||||
|
||||
unpackCmd="tar xvfj $src"
|
||||
|
||||
makeFlags="CC=gcc LD=gcc INSTALLPREFIX=$out"
|
||||
|
||||
preInstall() {
|
||||
mkdir $out
|
||||
mkdir $out/lib
|
||||
mkdir $out/include
|
||||
}
|
||||
preInstall=preInstall
|
||||
|
||||
installFlags=$makeFlags
|
||||
|
||||
genericBuild
|
||||
11
pkgs/development/libraries/chmlib/default.nix
Normal file
11
pkgs/development/libraries/chmlib/default.nix
Normal file
@@ -0,0 +1,11 @@
|
||||
{stdenv, fetchurl, libtool}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "chmlib-0.31";
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://66.93.236.84/~jedwin/projects/chmlib/chmlib-0.31.tbz;
|
||||
md5 = "c6c9e1658f43715456e00a4893d496ed";
|
||||
};
|
||||
buildInputs = [libtool];
|
||||
}
|
||||
20
pkgs/development/libraries/db4/builder.sh
Executable file → Normal file
20
pkgs/development/libraries/db4/builder.sh
Executable file → Normal file
@@ -1,10 +1,14 @@
|
||||
#! /bin/sh
|
||||
. $stdenv/setup
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
preConfigure() {
|
||||
cd build_unix
|
||||
configureScript=../dist/configure
|
||||
}
|
||||
preConfigure=preConfigure
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
cd db-*/build_unix || exit 1
|
||||
../dist/configure --prefix=$out --enable-cxx --enable-compat185 || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
rm -rf $out/doc || exit 1
|
||||
postInstall() {
|
||||
rm -rf $out/docs
|
||||
}
|
||||
postInstall=postInstall
|
||||
|
||||
genericBuild
|
||||
|
||||
@@ -1,10 +1,14 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
{stdenv, fetchurl, cxxSupport ? true, compat185 ? true}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "db4-4.2.52";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://www.sleepycat.com/update/snapshot/db-4.2.52.tar.gz;
|
||||
md5 = "cbc77517c9278cdb47613ce8cb55779f";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
configureFlags = [
|
||||
(if cxxSupport then "--enable-cxx" else "--disable-cxx")
|
||||
(if cxxSupport then "--enable-compat185" else "--disable-compat185")
|
||||
];
|
||||
}
|
||||
|
||||
2
pkgs/development/libraries/expat/builder.sh
Executable file → Normal file
2
pkgs/development/libraries/expat/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
{stdenv, fetchurl}: stdenv.mkDerivation {
|
||||
name = "expat-1.95.7";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://heanet.dl.sourceforge.net/sourceforge/expat/expat-1.95.7.tar.gz;
|
||||
md5 = "2ff59c2a5cbdd21a285c5f343e214fa9";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
buildinputs="$freetype $expat $x11 $ed"
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
# Fontconfig generates a bad `fonts.conf' file is the timezone is not known
|
||||
# (because it calls `date').
|
||||
export TZ=UTC
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
cd fontconfig-* || exit 1
|
||||
./configure --prefix=$out --with-confdir=$out/etc/fonts \
|
||||
--x-includes=$x11/include --x-libraries=$x11/lib \
|
||||
--with-expat-includes=$expat/include --with-expat-lib=$expat/lib || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
|
||||
echo "$freetype" > $out/propagated-build-inputs || exit 1
|
||||
@@ -1,21 +0,0 @@
|
||||
{stdenv, fetchurl, x11, freetype, expat, ed}:
|
||||
|
||||
assert !isNull x11 && x11.buildClientLibs;
|
||||
assert !isNull freetype;
|
||||
assert !isNull expat;
|
||||
assert !isNull ed;
|
||||
|
||||
derivation {
|
||||
name = "fontconfig-2.2.90";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://pdx.freedesktop.org/software/fontconfig/releases/fontconfig-2.2.90.tar.gz;
|
||||
md5 = "5cb87476743be1bbf1674ed72a76ae6a";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
x11 = x11;
|
||||
freetype = freetype;
|
||||
expat = expat;
|
||||
ed = ed;
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfj $src || exit 1
|
||||
cd freetype-* || exit 1
|
||||
./configure --prefix=$out || exit 1
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
strip -S $out/lib/*.a || exit 1
|
||||
@@ -1,10 +1,9 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
{stdenv, fetchurl}: stdenv.mkDerivation {
|
||||
name = "freetype-2.1.5";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = http://heanet.dl.sourceforge.net/sourceforge/freetype/freetype-2.1.5.tar.bz2;
|
||||
md5 = "54537b518b84d04190a1eccd393a29df";
|
||||
# url = http://cesnet.dl.sourceforge.net/sourceforge/freetype/freetype-2.1.7.tar.bz2;
|
||||
# md5 = "d71723948d7c0e44c401b5733c50857e";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
2
pkgs/development/libraries/gettext/builder.sh
Executable file → Normal file
2
pkgs/development/libraries/gettext/builder.sh
Executable file → Normal file
@@ -1,5 +1,3 @@
|
||||
#! /bin/sh
|
||||
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfz $src || exit 1
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
{stdenv, fetchurl}: derivation {
|
||||
{stdenv, fetchurl}: stdenv.mkDerivation {
|
||||
name = "gettext-0.12.1";
|
||||
system = stdenv.system;
|
||||
builder = ./builder.sh;
|
||||
src = fetchurl {
|
||||
url = ftp://ftp.nluug.nl/pub/gnu/gettext/gettext-0.12.1.tar.gz;
|
||||
md5 = "5d4bddd300072315e668247e5b7d5bdb";
|
||||
};
|
||||
stdenv = stdenv;
|
||||
}
|
||||
|
||||
46
pkgs/development/libraries/glibc/builder.sh
Executable file → Normal file
46
pkgs/development/libraries/glibc/builder.sh
Executable file → Normal file
@@ -1,26 +1,38 @@
|
||||
#! /bin/sh
|
||||
|
||||
# glibc cannot have itself in its rpath.
|
||||
export NIX_NO_SELF_RPATH=1
|
||||
. $stdenv/setup || exit 1
|
||||
|
||||
tar xvfj $glibcSrc || exit 1
|
||||
(cd glibc-* && tar xvfj $linuxthreadsSrc) || exit 1
|
||||
. $stdenv/setup
|
||||
|
||||
(cd glibc-* && patch -p1 < $vaargsPatch) || exit 1
|
||||
|
||||
mkdir build || exit 1
|
||||
cd build || exit 1
|
||||
LDFLAGS=-Wl,-S ../glibc-*/configure --prefix=$out --enable-add-ons --disable-profile || exit 1
|
||||
postUnpack() {
|
||||
cd $sourceRoot
|
||||
unpackFile $linuxthreadsSrc
|
||||
cd ..
|
||||
}
|
||||
|
||||
make || exit 1
|
||||
make install || exit 1
|
||||
make localedata/install-locales || exit 1
|
||||
strip -S $out/lib/*.a $out/lib/*.so $out/lib/gconv/*.so
|
||||
strip -s $out/bin/* $out/sbin/* $out/libexec/*
|
||||
postUnpack=postUnpack
|
||||
|
||||
ln -sf /etc/ld.so.cache $out/etc/ld.so.cache || exit 1
|
||||
|
||||
(cd $out/include && ln -s $kernelHeaders/include/* .) || exit 1
|
||||
preConfigure() {
|
||||
mkdir ../build
|
||||
cd ../build
|
||||
configureScript=../$sourceRoot/configure
|
||||
configureFlags="--enable-add-ons --disable-profile \
|
||||
--with-headers=$kernelHeaders/include"
|
||||
}
|
||||
|
||||
exit 0
|
||||
preConfigure=preConfigure
|
||||
|
||||
|
||||
postInstall() {
|
||||
make localedata/install-locales
|
||||
rm $out/etc/ld.so.cache
|
||||
(cd $out/include && ln -s $kernelHeaders/include/* .) || exit 1
|
||||
# `glibcbug' causes a retained dependency on the C compiler.
|
||||
rm $out/bin/glibcbug
|
||||
}
|
||||
|
||||
postInstall=postInstall
|
||||
|
||||
|
||||
genericBuild
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user