diff --git a/pkgs/libjpeg/libjpeg-build.sh b/pkgs/libjpeg/libjpeg-build.sh new file mode 100755 index 000000000000..9a27a8545c45 --- /dev/null +++ b/pkgs/libjpeg/libjpeg-build.sh @@ -0,0 +1,15 @@ +#! /bin/sh + +. $stdenv/setup || exit 1 + +tar xvfz $src || exit 1 +cd jpeg-* || exit 1 +./configure --prefix=$out --enable-shared || exit 1 +make || exit 1 +mkdir $out || exit 1 +mkdir $out/bin || exit 1 +mkdir $out/lib || exit 1 +mkdir $out/include || exit 1 +mkdir $out/man || exit 1 +mkdir $out/man/man1 || exit 1 +make install || exit 1 diff --git a/pkgs/libjpeg/libjpeg.fix b/pkgs/libjpeg/libjpeg.fix new file mode 100644 index 000000000000..28d7698ef049 --- /dev/null +++ b/pkgs/libjpeg/libjpeg.fix @@ -0,0 +1,13 @@ +Package( + [ ("name", "libjpeg-6b") + + , ("build", Relative("libjpeg/libjpeg-build.sh")) + + , ("src", Call(IncludeFix("fetchurl/fetchurl.fix"), + [ ("url", "http://www.ijg.org/files/jpegsrc.v6b.tar.gz") + , ("md5", "dbd5f3b47ed13132f04c685d608a7547") + ])) + + , ("stdenv", IncludeFix("stdenv/stdenv.fix")) + ] +) diff --git a/pkgs/libpng/libpng-build.sh b/pkgs/libpng/libpng-build.sh new file mode 100755 index 000000000000..dec5856ab84c --- /dev/null +++ b/pkgs/libpng/libpng-build.sh @@ -0,0 +1,18 @@ +#! /bin/sh + +envpkgs="$zlib" +. $stdenv/setup || exit 1 + +export NIX_CFLAGS_COMPILE="-I$zlib/include $NIX_CFLAGS_COMPILE" + +tar xvfj $src || exit 1 +cd libpng-* || exit 1 +make -f scripts/makefile.linux || exit 1 +mkdir $out || exit 1 +mkdir $out/bin || exit 1 +mkdir $out/lib || exit 1 +mkdir $out/include || exit 1 +make -f scripts/makefile.linux install prefix=$out || exit 1 +strip -S $out/lib/*.a || exit 1 + +echo $envpkgs > $out/envpkgs || exit 1 diff --git a/pkgs/libpng/libpng.fix b/pkgs/libpng/libpng.fix new file mode 100644 index 000000000000..bc1232f261d4 --- /dev/null +++ b/pkgs/libpng/libpng.fix @@ -0,0 +1,14 @@ +Package( + [ ("name", "libpng-1.2.5") + + , ("build", Relative("libpng/libpng-build.sh")) + + , ("src", Call(IncludeFix("fetchurl/fetchurl.fix"), + [ ("url", "http://heanet.dl.sourceforge.net/sourceforge/png-mng/libpng-1.2.5.tar.bz2") + , ("md5", "3fc28af730f12ace49b14568de4ad934") + ])) + + , ("stdenv", IncludeFix("stdenv/stdenv.fix")) + , ("zlib", IncludeFix("zlib/zlib.fix")) + ] +) diff --git a/pkgs/libtiff/libtiff-build.sh b/pkgs/libtiff/libtiff-build.sh new file mode 100755 index 000000000000..6f7b3b168dca --- /dev/null +++ b/pkgs/libtiff/libtiff-build.sh @@ -0,0 +1,16 @@ +#! /bin/sh + +envpkgs="$zlib $jpeg" +. $stdenv/setup || exit 1 + +tar xvfz $src || exit 1 +cd tiff-* || exit 1 +./configure --prefix=$out --with-DIR_MAN=$out/man \ + --with-ZIP --with-JPEG \ + --with-DIRS_LIBINC="$zlib/include $jpeg/include" || exit 1 +make || exit 1 +mkdir $out || exit 1 +make install || exit 1 +strip -S $out/lib/*.a || exit 1 + +echo $envpkgs > $out/envpkgs || exit 1 diff --git a/pkgs/libtiff/libtiff.fix b/pkgs/libtiff/libtiff.fix new file mode 100644 index 000000000000..6e2fcd62e493 --- /dev/null +++ b/pkgs/libtiff/libtiff.fix @@ -0,0 +1,15 @@ +Package( + [ ("name", "libtiff-3.5.7") + + , ("build", Relative("libtiff/libtiff-build.sh")) + + , ("src", Call(IncludeFix("fetchurl/fetchurl.fix"), + [ ("url", "ftp://ftp.remotesensing.org/pub/libtiff/tiff-v3.5.7.tar.gz") + , ("md5", "82243b5ae9b7c9e492aeebc501680990") + ])) + + , ("stdenv", IncludeFix("stdenv/stdenv.fix")) + , ("zlib", IncludeFix("zlib/zlib.fix")) + , ("jpeg", IncludeFix("libjpeg/libjpeg.fix")) + ] +)