From ec3b5134c18f0e0ee6ae6cdb71adb95c4d45750b Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Fri, 11 Jul 2003 21:08:53 +0000 Subject: [PATCH] * Converted some old Fix descriptors. * A solution to the library abstraction problem (i.e., if package X needs library Y, and library Y needs library Z, then we do not (generally) want to declare Z as a input to X since that would break abstraction). This was not possible under the old Nix. svn path=/nixpkgs/trunk/; revision=150 --- pkgs/Xft/Xft-build.sh | 12 ++++++++++ pkgs/Xft/Xft.fix | 14 +++++++++++ pkgs/aterm/aterm.fix | 2 +- pkgs/fontconfig/fontconfig-build.sh | 12 ++++++++++ pkgs/fontconfig/fontconfig.fix | 14 +++++++++++ pkgs/freetype/freetype-build.sh | 9 ++++++++ pkgs/freetype/freetype.fix | 9 ++++++++ pkgs/helpers/set-env.sh | 30 ++++++++++++++++++++++++ pkgs/openssl/openssl-build.sh | 10 ++++++++ pkgs/openssl/openssl.fix | 9 ++++++++ pkgs/pkgconfig/pkgconfig.fix | 2 +- pkgs/subversion/subversion-build.sh | 36 +++++++++++++++++++++++++++++ pkgs/subversion/subversion.fix | 11 +++++++++ pkgs/system/populate-linkdirs.pl | 2 +- pkgs/system/system.fix | 3 +++ 15 files changed, 172 insertions(+), 3 deletions(-) create mode 100755 pkgs/Xft/Xft-build.sh create mode 100644 pkgs/Xft/Xft.fix create mode 100755 pkgs/fontconfig/fontconfig-build.sh create mode 100644 pkgs/fontconfig/fontconfig.fix create mode 100755 pkgs/freetype/freetype-build.sh create mode 100644 pkgs/freetype/freetype.fix create mode 100644 pkgs/helpers/set-env.sh create mode 100755 pkgs/openssl/openssl-build.sh create mode 100644 pkgs/openssl/openssl.fix create mode 100755 pkgs/subversion/subversion-build.sh create mode 100644 pkgs/subversion/subversion.fix diff --git a/pkgs/Xft/Xft-build.sh b/pkgs/Xft/Xft-build.sh new file mode 100755 index 000000000000..501f07a5d9b8 --- /dev/null +++ b/pkgs/Xft/Xft-build.sh @@ -0,0 +1,12 @@ +#! /bin/sh + +export PATH=/bin:/usr/bin +envpkgs=$fontconfig +. $setenv + +tar xvfz $src || exit 1 +cd fcpackage*/Xft || exit 1 +./configure --prefix=$out --x-includes=/usr/X11/include --x-libraries=/usr/X11/lib || exit 1 +make || exit 1 +make install || exit 1 +echo $envpkgs > $out/envpkgs || exit 1 diff --git a/pkgs/Xft/Xft.fix b/pkgs/Xft/Xft.fix new file mode 100644 index 000000000000..f59ed4b01cf9 --- /dev/null +++ b/pkgs/Xft/Xft.fix @@ -0,0 +1,14 @@ +Package( + [ ("name", "Xft-20021121") + + , ("build", Relative("Xft/Xft-build.sh")) + , ("setenv", Relative("helpers/set-env.sh")) + + , ("src", App(IncludeFix("fetchurl/fetchurl.fix"), + [ ("url", "http://fontconfig.org/release/fcpackage.2_1.tar.gz") + , ("md5", "2f2852c80924a9b5356c3037a471c1a1") + ])) + + , ("fontconfig", IncludeFix("fontconfig/fontconfig.fix")) + ] +) diff --git a/pkgs/aterm/aterm.fix b/pkgs/aterm/aterm.fix index 08d3398c824a..7bb76b33ca65 100644 --- a/pkgs/aterm/aterm.fix +++ b/pkgs/aterm/aterm.fix @@ -3,7 +3,7 @@ Package( , ("build", Relative("aterm/aterm-build.sh")) , ("src", App(IncludeFix("fetchurl/fetchurl.fix"), [ ("url", "http://www.cwi.nl/projects/MetaEnv/aterm/aterm-2.0.tar.gz") - , ("hash", "653b1bb8140ee0206b00aab126ef412e") + , ("md5", "853474e4bcf4a85f7d38a0676b36bded") ])) ] ) diff --git a/pkgs/fontconfig/fontconfig-build.sh b/pkgs/fontconfig/fontconfig-build.sh new file mode 100755 index 000000000000..6584f1f19f4e --- /dev/null +++ b/pkgs/fontconfig/fontconfig-build.sh @@ -0,0 +1,12 @@ +#! /bin/sh + +export PATH=/bin:/usr/bin +envpkgs=$freetype +. $setenv + +tar xvfz $src || exit 1 +cd fcpackage*/fontconfig || exit 1 +./configure --prefix=$out --with-confdir=$out/etc/fonts --x-includes=/usr/X11/include --x-libraries=/usr/X11/lib || exit 1 +make || exit 1 +make install || exit 1 +echo $envpkgs > $out/envpkgs || exit 1 diff --git a/pkgs/fontconfig/fontconfig.fix b/pkgs/fontconfig/fontconfig.fix new file mode 100644 index 000000000000..41e8f4b6970d --- /dev/null +++ b/pkgs/fontconfig/fontconfig.fix @@ -0,0 +1,14 @@ +Package( + [ ("name", "fontconfig-20021121") + + , ("build", Relative("fontconfig/fontconfig-build.sh")) + , ("setenv", Relative("helpers/set-env.sh")) + + , ("src", App(IncludeFix("fetchurl/fetchurl.fix"), + [ ("url", "http://fontconfig.org/release/fcpackage.2_1.tar.gz") + , ("md5", "2f2852c80924a9b5356c3037a471c1a1") + ])) + + , ("freetype", IncludeFix("freetype/freetype.fix")) + ] +) diff --git a/pkgs/freetype/freetype-build.sh b/pkgs/freetype/freetype-build.sh new file mode 100755 index 000000000000..96629602570c --- /dev/null +++ b/pkgs/freetype/freetype-build.sh @@ -0,0 +1,9 @@ +#! /bin/sh + +export PATH=/bin:/usr/bin + +tar xvfj $src || exit 1 +cd freetype-* || exit 1 +./configure --prefix=$out || exit 1 +make || exit 1 +make install || exit 1 diff --git a/pkgs/freetype/freetype.fix b/pkgs/freetype/freetype.fix new file mode 100644 index 000000000000..39aba3af69fc --- /dev/null +++ b/pkgs/freetype/freetype.fix @@ -0,0 +1,9 @@ +Package( + [ ("name", "freetype-2.1.4") + , ("build", Relative("freetype/freetype-build.sh")) + , ("src", App(IncludeFix("fetchurl/fetchurl.fix"), + [ ("url", "http://easynews.dl.sourceforge.net/sourceforge/freetype/freetype-2.1.4.tar.bz2") + , ("md5", "1fc0b188f1fe1216776e5855d2da141f") + ])) + ] +) diff --git a/pkgs/helpers/set-env.sh b/pkgs/helpers/set-env.sh new file mode 100644 index 000000000000..f28e9af18f15 --- /dev/null +++ b/pkgs/helpers/set-env.sh @@ -0,0 +1,30 @@ +addtoenv() +{ + envpkgs="$envpkgs $1" + + if test -d $1/bin; then + export PATH=$1/bin:$PATH + fi + + if test -d $1/lib; then + export LIBRARY_PATH=$1/lib:$LIBRARY_PATH + export LD_LIBRARY_PATH=$1/lib:$LD_LIBRARY_PATH + fi + + if test -d $1/lib/pkgconfig; then + export PKG_CONFIG_PATH=$1/lib/pkgconfig:$PKG_CONFIG_PATH + fi + + if test -f $1/envpkgs; then + for i in $(cat $1/envpkgs); do + addtoenv $i + done + fi +} + +oldenvpkgs=$envpkgs +envpkgs= + +for i in $oldenvpkgs; do + addtoenv $i +done diff --git a/pkgs/openssl/openssl-build.sh b/pkgs/openssl/openssl-build.sh new file mode 100755 index 000000000000..93af431fc55e --- /dev/null +++ b/pkgs/openssl/openssl-build.sh @@ -0,0 +1,10 @@ +#! /bin/sh + +export PATH=/bin:/usr/bin + +tar xvfz $src || exit 1 +cd openssl-* || exit 1 +./config --prefix=$out shared || exit 1 +make || exit 1 +mkdir $out || exit 1 +make install || exit 1 diff --git a/pkgs/openssl/openssl.fix b/pkgs/openssl/openssl.fix new file mode 100644 index 000000000000..91cfb3b85d8e --- /dev/null +++ b/pkgs/openssl/openssl.fix @@ -0,0 +1,9 @@ +Package( + [ ("name", "openssl-0.9.7b") + , ("build", Relative("openssl/openssl-build.sh")) + , ("src", App(IncludeFix("fetchurl/fetchurl.fix"), + [ ("url", "http://www.openssl.org/source/openssl-0.9.7b.tar.gz") + , ("md5", "fae4bec090fa78e20f09d76d55b6ccff") + ])) + ] +) diff --git a/pkgs/pkgconfig/pkgconfig.fix b/pkgs/pkgconfig/pkgconfig.fix index 312db4a0e640..8ba079f70928 100644 --- a/pkgs/pkgconfig/pkgconfig.fix +++ b/pkgs/pkgconfig/pkgconfig.fix @@ -3,7 +3,7 @@ Package( , ("build", Relative("pkgconfig/pkgconfig-build.sh")) , ("src", App(IncludeFix("fetchurl/fetchurl.fix"), [ ("url", "http://www.freedesktop.org/software/pkgconfig/releases/pkgconfig-0.15.0.tar.gz") - , ("hash", "c62371dd07ef85043e91f298176c771f") + , ("md5", "c62371dd07ef85043e91f298176c771f") ])) ] ) diff --git a/pkgs/subversion/subversion-build.sh b/pkgs/subversion/subversion-build.sh new file mode 100755 index 000000000000..d4b279df2229 --- /dev/null +++ b/pkgs/subversion/subversion-build.sh @@ -0,0 +1,36 @@ +#! /bin/sh + +export PATH=$libxml/bin:/bin:/usr/bin:/usr/local/bin +export LD_LIBRARY_PATH=$ssl/lib: + +export LDFLAGS=-s + +if test $localServer; then + extraflags="--with-berkeley-db=$db4 $extraflags" +fi + +if test $httpsClient; then + extraflags="--with-ssl --with-libs=$ssl $extraflags" +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" +fi + +if test $pythonBindings; then + extraflags="--with-swig=$swig $extraflags" +fi + +echo "extra flags: $extraflags" + +tar xvfz $src || exit 1 +cd subversion-* || exit 1 +./configure --prefix=$out $extraflags || exit 1 +make $extramakeflags || exit 1 +make install $extramakeflags || exit 1 + +if test $pythonBindings; then + make swig-py || exit 1 + make install-swig-py || exit 1 +fi diff --git a/pkgs/subversion/subversion.fix b/pkgs/subversion/subversion.fix new file mode 100644 index 000000000000..13e7f5f00a65 --- /dev/null +++ b/pkgs/subversion/subversion.fix @@ -0,0 +1,11 @@ +Package( + [ ("name", "subversion-0.25.0") + , ("build", Relative("subversion/subversion-build.sh")) + , ("src", App(IncludeFix("fetchurl/fetchurl.fix"), + [ ("url", "http://subversion.tigris.org/files/documents/15/5110/subversion-0.25.tar.gz") + , ("md5", "a018220d5c790161bc712ccb7d0f1b38") + ])) + , ("httpsClient", "1") + , ("ssl", IncludeFix("openssl/openssl.fix")) + ] +) diff --git a/pkgs/system/populate-linkdirs.pl b/pkgs/system/populate-linkdirs.pl index 79a4374e0564..4bff975f9cc0 100755 --- a/pkgs/system/populate-linkdirs.pl +++ b/pkgs/system/populate-linkdirs.pl @@ -30,7 +30,7 @@ sub createLinks { my $target = readlink($dstfile); die "collission between $srcfile and $target"; } else { - print "linking $dstfile to $srcfile\n"; +# print "linking $dstfile to $srcfile\n"; symlink($srcfile, $dstfile) || die "error creating link $dstfile"; } diff --git a/pkgs/system/system.fix b/pkgs/system/system.fix index db40ada11f14..8c5bf5893d52 100644 --- a/pkgs/system/system.fix +++ b/pkgs/system/system.fix @@ -4,5 +4,8 @@ Package( , ("actATerm", IncludeFix("aterm/aterm.fix")) , ("actPkgConfig", IncludeFix("pkgconfig/pkgconfig.fix")) + , ("actOpenSSL", IncludeFix("openssl/openssl.fix")) + , ("actSubversion", IncludeFix("subversion/subversion.fix")) + , ("actXft", IncludeFix("Xft/Xft.fix")) ] )