removing old haskell stuff. I was using my own branch for a long time.

It will be replaced by something else anyway.
Some of those patches may still be of interest (?)

svn path=/nixpkgs/trunk/; revision=16298
This commit is contained in:
Marc Weber 2009-07-09 22:24:08 +00:00
parent f38e400515
commit 25a1533d9a
18 changed files with 0 additions and 1727 deletions

View File

@ -1,51 +0,0 @@
args: with args; with lib;
stdenv.mkDerivation {
inherit suffix name ghc readline ncurses;
buildInputs = (libraries ++ [ghcPkgUtil]);
tags = if installSourceAndTags then
map (x : sourceWithTagsDerivation (sourceWithTagsFromDerivation x))
( uniqList { inputList= filter annotatedWithSourceAndTagInfo libraries; } )
else [];
phases="installPhase";
installPhase="
set -e
ensureDir \$out/bin
if test -n \"\$ghcPackagedLibs\"; then
g=:\$(echo \$ghc/lib/ghc-*/package.conf)
fi
for a in ghc ghci ghc-pkg; do
app=$(ls -al $ghc/bin/$a | sed -n 's%.*-> \\(.*\\)%\\1%p');
cat > \"\$out/bin/\$a$suffix\" << EOF
#!`type -f sh | gawk '{ print $3; }'`
export LIBRARY_PATH=\$readline/lib:\$ncurses/lib
GHC_PACKAGE_PATH=\${GHC_PACKAGE_PATH}\${g} \$ghc/bin/$app \"\\\$@\"
EOF
chmod +x \"\$out/bin/\$a$suffix\"
done
ensureDir \$out/src
for i in \$tags; do
ln -s \$i/src/* \$out/src
done
ensureDir \$out/bin
for i in `echo $GHC_PACKAGE_PATH | sed 's/:/ /g'`; do
o=\${i/lib*/}
o=\${i/nix-support*/}
for j in \$ghc/bin/* `find \${o}bin/ -type f 2>/dev/null` `find \${o}usr/local/bin/ -type f 2>/dev/null`; do
b=`basename \$j`
if [ \$b == sh ]; then continue; fi
if [ \$b == bash ]; then continue; fi
if [ \$b == bashbug ]; then continue; fi
if [ \$b == bashbug ]; then continue; fi
if [ -e \$out/bin/\$b ]; then continue; fi
ln -s \$j \$out/bin/;
done
done
";
}

View File

@ -1,17 +0,0 @@
args: with args;
{ name, src, meta ? {}, libsFun, pass ? {} } :
let buildInputs = libsFun ((ghc68extraLibs ghcsAndLibs.ghc68) // ghcsAndLibs.ghc68.core_libs)
++ [ ghcsAndLibs.ghc68.ghc perl ];
in stdenv.mkDerivation ({
inherit name src meta;
phases = "unpackPhase patchPhase buildPhase";
# TODO The ghc must be the one having compiled the libs.. So make this obvious by not having to pass it
buildPhase = ''
ghc --make Setup.*hs -o setup
ensureDir \out
nix_ghc_pkg_tool join local-pkg-db
./setup configure --prefix=$out --package-db=local-pkg-db
./setup build
./setup install
'';
} // pass // { buildInputs = buildInputs ++ (if pass ? buildInputs then lib.toList pass.buildInputs else []); })

View File

@ -1,261 +0,0 @@
{ ghcPkgUtil, gnum4, perl, ghcboot, stdenv, fetchurl, recurseIntoAttrs, gmp, readline, lib, hasktags, ctags
, sourceByName, autoconf, happy, alex ,automake, getConfig} :
rec {
/* What's in here?
Goal: really pure GHC. This means put every library into its each package.conf
and add all together using GHC_PACKAGE_PATH
First I've tried separating the build of ghc from it's lib. It hase been to painful. I've failed. Now there is nix_ghc_pkg_tool.hs which just takes the installed package.conf
and creates a new package db file for each contained package.
The final attribute set looks similar to this:
ghc, core_libs and extra_libraries will then be used to build all the ohter packages availible on hackege..
(There is much left to be done)
ghcAndLibraries = {
ghc68 = {
ghc = {
src = "The compiler source"
extra_src = "source of extra libraries"
version = "GHC version as string"
}
core_libs = [ libs distributed the ghc core (see libraries/core-packages ];
extra_libraries = [ libraries contained extra_src ];
};
ghc66 = {
roughly the same
};
}
*/
#this only works for ghc-6.8 right now
ghcAndLibraries = { version, src /* , core_libraries, extra_libraries */
, extra_src, pass ? {} }:
recurseIntoAttrs ( rec {
inherit src extra_src version;
ghc = stdenv.mkDerivation ( lib.mergeAttrsNoOverride {} pass {
name = "ghc-"+version;
inherit src ghcboot gmp version;
buildInputs = [readline perl gnum4 gmp];
preConfigure = "
chmod u+x rts/gmp/configure
# still requires a hack for ncurses
sed -i \"s|^\(library-dirs.*$\)|\1 \\\"$ncurses/lib\\\"|\" libraries/readline/package.conf.in
";
# TODO add unique (filter duplicates?) shouldn't be there?
nix_ghc_pkg_tool = ./nix_ghc_pkg_tool.hs;
configurePhase = "./configure"
+" --prefix=\$out "
+" --with-ghc=\$ghcboot/bin/ghc"
+" --with-gmp-libraries=$gmp/lib"
+" --with-gmp-includes=${gmp}/include"
+" --with-readline-libraries=\"$readline/lib\"";
# now read the main package.conf and create a single package db file for each of them
# Also create setup hook.
makeFlags = getConfig ["ghc" "makeFlags" ] "";
# note : I don't know yet wether it's a good idea to have RUNGHC.. It's faster
# but you can't pass packages, can you?
postInstall = "
cp \$nix_ghc_pkg_tool nix_ghc_pkg_tool.hs
\$out/bin/ghc-\$version --make -o nix_ghc_pkg_tool nix_ghc_pkg_tool.hs;
./nix_ghc_pkg_tool split \$out/lib/ghc-\$version/package.conf \$out/lib/ghc-\$version
cp nix_ghc_pkg_tool \$out/bin
if test -x \$out/bin/runghc; then
RUNHGHC=\$out/bin/runghc # > ghc-6.7/8 ?
else
RUNHGHC=\$out/bin/runhaskell # ghc-6.6 and prior
fi
ensureDir \$out/nix-support
sh=\$out/nix-support/setup-hook
echo \"RUNHGHC=\$RUNHGHC\" >> \$sh
";
});
core_libs = rec {
# name (using lowercase letters everywhere because using installing packages having different capitalization is discouraged) - this way there is not that much to remember?
cabal_darcs_name = "cabal-darcs";
# introducing p here to speed things up.
# It merges derivations (defined below) and additional inputs. I hope that using as few nix functions as possible results in greates speed?
# unfortunately with x; won't work because it forces nix to evaluate all attributes of x which would lead to infinite recursion
pkgs = let x = derivations; in {
# ghc extra packages
cabal = { name = "Cabal-1.2.3.0"; srcDir = "libraries/Cabal";
deps = [x.base x.pretty x.old_locale x.old_time
x.directory x.unix x.process x.array x.containers
x.rts x.filepath ]; };
array = { name = "array-0.1.0.0"; srcDir = "libraries/array";
deps = [x.base ]; };
base = { name = "base-3.0.1.0"; srcDir = "libraries/base";
deps = [x.rts ]; };
bytestring = { name = "bytestring-0.9.0.1"; srcDir = "libraries/bytestring";
deps = [ x.base x.array ];};
containers = { name = "containers-0.1.0.1"; srcDir = "libraries/containers";
deps = [ x.base x.array ];};
directory = { name = "directory-1.0.0.0"; srcDir = "libraries/directory";
deps = [ x.base x.old_locale x.old_time x.filepath ];};
filepath = { name = "filepath-1.1.0.0"; srcDir = "libraries/filepath";
deps = [ x.base ];};
ghc = { name = "ghc-${version}"; srcDir = "compiler";
deps = [ x.base x.old_locale x.old_time x.filepath
x.directory x.array x.containers x.hpc x.bytestring
x.pretty x.packedstring x.template_haskell x.unix
x.process x.readline x.cabal x.random x.haskell98 ]; };
haskell98 = { name = "haskell98-1.0.1.0"; srcDir = "libraries/haskell98";
deps = [ x.base x.old_locale x.old_time x.filepath
x.directory x.random x.unix x.process x.array]; };
hpc = { name = "hpc-0.5.0.0"; srcDir = "libraries/hpc";
deps = [ x.base x.old_locale x.old_time x.filepath
x.directory x.array x.containers ]; };
old_locale = { name = "old-locale-1.0.0.0"; srcDir = "libraries/old-locale";
deps = [ x.base ]; };
old_time = { name = "old-time-1.0.0.0"; srcDir = "libraries/old-time";
deps = [ x.base x.old_locale ];};
packedstring = { name = "packedstring-0.1.0.0"; srcDir = "libraries/packedstring";
deps = [ x.base x.array ];};
pretty = { name = "pretty-1.0.0.0"; srcDir = "libraries/pretty";
deps = [ x.base ];};
process = { name = "process-1.0.0.0"; srcDir = "libraries/process";
deps = [ x.base x.old_locale x.old_time x.filepath
x.directory x.unix ]; };
random = { name = "random-1.0.0.0"; srcDir = "libraries/random";
deps = [ x.base x.old_locale x.old_time ]; };
readline = { name = "readline-1.0.1.0"; srcDir = "libraries/readline";
deps = [ x.base x.old_locale x.old_time x.filepath
x.directory x.unix x.process ];};
rts = rec {
name = "rts-1.0"; srcDir = "rts"; # TODO: Doesn't have .hs files so I should use ctags if creating tags at all
deps = [];
createTagFiles = [
{ name = "${name}_haskell";
tagCmd = "${toString ctags}/bin/ctags -R .;mv tags \$TAG_FILE"; }
];
};
template_haskell = { name = "template-haskell-2.2.0.0"; srcDir = "libraries/template-haskell";
deps = [ x.base x.pretty x.array x.packedstring x.containers ];};
unix = { name = "unix-2.3.0.0"; srcDir = "libraries/unix";
deps = [ x.base x.old_locale x.old_time x.filepath x.directory ];};
};
toDerivation = attrs : with attrs;
stdenv.mkDerivation {
inherit (attrs) name;
phases = "buildPhase fixupPhase";
buildInputs = [ ghcPkgUtil ];
propagatedBuildInputs = [ ghc ] ++ attrs.deps;
buildPhase = "setupHookRegisteringPackageDatabase \"${ghc}/lib/ghc-${ghc.version}/${attrs.name}.conf\"";
meta = {
sourceWithTags = {
src = ghc.src;
inherit srcDir;
name = attrs.name + "-src-with-tags";
createTagFiles = lib.maybeAttr "createTagFiles" [
{ name = "${attrs.name}_haskell";
tagCmd = "${toString hasktags}/bin/hasktags-modified --ctags `find . -type f -name \"*.*hs\"`; sort tags > \$TAG_FILE"; }
] attrs;
};
};
};
derivations = with lib; builtins.listToAttrs (lib.concatLists ( lib.mapRecordFlatten
( n : attrs : let d = (toDerivation attrs); in [ (nameValuePair n d) (nameValuePair attrs.name d) ] ) pkgs ) );
}.derivations;
});
ghc68 = ghcAndLibraries rec {
version = "6.8.2";
src = fetchurl {
#url = http://www.haskell.org/ghc/dist/stable/dist/ghc-6.8.0.20071004-src.tar.bz2;
#sha256 = "1yyl7sxykmvkiwfxkfzpqa6cmgw19phkyjcdv99ml22j16wli63l";
url = "http://www.haskell.org/ghc/dist/stable/dist/ghc-${version}-src.tar.bz2";
md5 = "745c6b7d4370610244419cbfec4b2f84";
#url = http://www.haskell.org/ghc/dist/stable/dist/ghc-6.8.20070912-src.tar.bz2;
#sha256 = "1b1gvi7hc7sc0fkh29qvzzd5lgnlvdv3ayiak4mkfnzkahvmq85s";
};
pass = { patches = ./patch; };
extra_src = fetchurl {
url = "http://www.haskell.org/ghc/dist/stable/dist/ghc-${version}-src-extralibs.tar.bz2";
sha256 = "044mpbzpkbxcnqhjnrnmjs00mr85057d123rrlz2vch795lxbkcn";
#url = http://www.haskell.org/ghc/dist/stable/dist/ghc-6.8.20070912-src-extralibs.tar.bz2;
#sha256 = "0py7d9nh3lkhjxr3yb3n9345d0hmzq79bi40al5rcr3sb84rnp9r";
};
};
# this works. commented out because I haven't uploaded all the bleeding edge source dist files.
#[> darcs version of ghc which is updated occasionally by Marc Weber
#ghc68darcs = ghcAndLibraries rec {
# version = "6.9";
# pass = { buildInputs = [ happy alex];
# patches = ./patch;
# patchPhase = "
# unset patchPhase; patchPhase
# pwd
# sed 's/GhcWithJavaGen=NO/GhcWithJavaGen=YES/g' -i mk/config.mk.in
# ";
# };
# [> each library is usually added using darcs-all get
# [> so I assemble and prepare the sources here
# src = stdenv.mkDerivation {
# name = "ghc-darcs-src-dist";
# buildInputs = [autoconf automake];
# core_libs = map (x : sourceByName "ghc_core_${x}") ["array" "base" "bytestring" "Cabal" "containers" "directory" "editline" "filepath" "ghc_prim" "haskell98" "hpc" "integer_gmp" "old_locale" "old_time" "packedstring" "pretty" "process" "random" "template_haskell" "unix" "Win32" ];
# ghc = sourceByName "ghc";
# phases = "buildPhase";
# buildPhase = "
# echo unpacking ghc
# tar xfz \$ghc &> /dev/null
# cd nix_repsoitory_manager_tmp_dir/libraries
# for i in \$core_libs; do
# echo 'unpacking core_lib :' \$i
# tar xfz \$i &> /dev/null
# n=`basename \$i`
# n=\${n/ghc_core_/}
# if [ -f nix_repsoitory_manager_tmp_dir/*.ac ]; then
# cd nix_repsoitory_manager_tmp_dir
# echo =======================================================
# echo \$n
# autoreconf
# cd ..
# fi
# mv nix_repsoitory_manager_tmp_dir \${n/.tar.gz/}
# done
# mv ghc_prim ghc-prim
# for i in integer-gmp old-locale old-time template-haskell; do
# mv \${i/-/_} $i
# done
# mkdir \$out
# cd ..
# autoreconf
# sh boot
# cd ..
# mv nix*/* \$out/
# ";
# };
# [> TODO this is copied.. use dev versions as well here
# extra_src = fetchurl {
# url = "http://www.haskell.org/ghc/dist/stable/dist/ghc-${version}-src-extralibs.tar.bz2";
# sha256 = "044mpbzpkbxcnqhjnrnmjs00mr85057d123rrlz2vch795lxbkcn";
# [>url = http://www.haskell.org/ghc/dist/stable/dist/ghc-6.8.20070912-src-extralibs.tar.bz2;
# [>sha256 = "0py7d9nh3lkhjxr3yb3n9345d0hmzq79bi40al5rcr3sb84rnp9r";
# };
#};
}

View File

@ -1,48 +0,0 @@
-- packages: filepath,Cabal,directory
{-# OPTIONS_GHC -fglasgow-exts #-}
module Main where
import Distribution.InstalledPackageInfo (InstalledPackageInfo (..))
import Distribution.Package (showPackageId)
import System.FilePath
import System.Environment
import System.Directory
import System.IO
import System.Exit
import Data.List
usage = unlines [
" usage a) <app-name> split in_path out_path"
, " b) <app-anme> join out_path"
, "This small helper executable servers two purposes:"
, "a) split the main package db created by ghc installation into single libs"
, " so that nix can add them piecwise as needed to buildInputs"
, "b) merge databases into one single file, so when building a library"
, " we can create one db containing all dependencies passed by GHC_PACKAGE_PATH"
, " I think this is a better solution than patching and mantaining cabal so"
, " that it support GHC_PACKAGE_PATH (not only by accident) ?"
]
mySplit :: (Eq Char) => [Char] ->[[ Char ]]
mySplit [] = []
mySplit list = let (l, l') = span (not . (`elem` ":;")) list
in l: mySplit (drop 1 l')
myReadFile f = doesFileExist f >>= \fe ->
if fe then readFile f
else do hPutStrLn stderr $ "unable to read file " ++ f
exitWith (ExitFailure 1)
main = do
args <- getArgs
case args of
["split", inFile, outDir] -> do
-- prior to 6.9.x (when exactly) this must be InstalledPackageInfo only (not InstalledPackageInfo_ String)
-- (packagedb :: [InstalledPackageInfo_ String] ) <- fmap read $ myReadFile inFile
(packagedb :: [InstalledPackageInfo] ) <- fmap read $ myReadFile inFile
mapM_ (\pi -> let fn = outDir </> (showPackageId $ package pi) ++ ".conf"
in writeFile fn (show [pi])
) packagedb
["join", outpath] -> do
getEnv "GHC_PACKAGE_PATH" >>= mapM myReadFile . nub . mySplit
>>= writeFile outpath . show . concat . map (read :: String -> [InstalledPackageInfo])
_ -> putStrLn usage

View File

@ -1,55 +0,0 @@
diff -rN -U3 old-ghc_package_db/compiler/package.conf.in new-ghc_package_db/compiler/package.conf.in
--- old-ghc_package_db/compiler/package.conf.in 2008-04-24 02:03:28.000000000 +0200
+++ new-ghc_package_db/compiler/package.conf.in 2008-04-24 02:03:28.000000000 +0200
@@ -10,7 +10,6 @@
BasicTypes
BinIface
Binary
- BitSet
Bitmap
BuildTyCl
ByteCodeAsm
@@ -91,7 +90,6 @@
Encoding
FastString
FastTypes
- FieldLabel
Finder
FiniteMap
FloatIn
@@ -121,7 +119,6 @@
IfaceEnv
IfaceSyn
IfaceType
- IlxGen
Inst
InstEnv
Java
@@ -179,7 +176,6 @@
RdrHsSyn
RdrName
RegAllocInfo
- RegisterAlloc
RnBinds
RnEnv
RnExpr
diff -rN -U3 old-ghc_package_db/mk/package.mk new-ghc_package_db/mk/package.mk
--- old-ghc_package_db/mk/package.mk 2008-04-24 02:03:26.000000000 +0200
+++ new-ghc_package_db/mk/package.mk 2008-04-24 02:03:28.000000000 +0200
@@ -61,6 +61,7 @@
package.conf.inplace : package.conf.in
$(CPP) $(RAWCPP_FLAGS) -P \
+ $(if $(subst NO,,$(GhcWithJavaGen)),, -DJava= -D JavaGen= -DPrintJava= ) \
-DIMPORT_DIR='"$(IMPORT_DIR_INPLACE)"' \
-DLIB_DIR='"$(LIB_DIR_INPLACE)"' \
-DINCLUDE_DIR='"$(INCLUDE_DIR_INPLACE)"' \
@@ -74,6 +75,7 @@
install::
$(CPP) $(RAWCPP_FLAGS) -P -DINSTALLING \
+ $(if $(subst NO,,$(GhcWithJavaGen)),, -DJava= -D JavaGen= -DPrintJava= ) \
-DIMPORT_DIR='"$(IMPORT_DIR_INSTALLED)"' \
-DLIB_DIR='"$(LIB_DIR_INSTALLED)"' \
-DINCLUDE_DIR='"$(INCLUDE_DIR_INSTALLED)"' \

View File

@ -1,37 +0,0 @@
# mantainer: Marc Weber (marco-oweber@gmx.de)
#
# example usage: add ghcPkgUtil to buildInputs then somewhere in buildPhase:
#
# createEmptyPackageDatabaseAndSetupHook
# configure --with-package-db=$PACKAGE_DB
# ... compile ghc library ...
# add your library to propagatedBuildInputs instead of buildInputs
# in all depending libraries
# creates a setup hook
# adding the package database
# nix-support/package.conf to GHC_PACKAGE_PATH
# if not already contained
setupHookRegisteringPackageDatabase(){
ensureDir $out/nix-support;
if test -n "$1"; then
local pkgdb=$1
else
local pkgdb=$out/nix-support/package.conf
fi
cat >> $out/nix-support/setup-hook << EOF
echo \$GHC_PACKAGE_PATH | grep -l $pkgdb &> /dev/null || \
export GHC_PACKAGE_PATH=\$GHC_PACKAGE_PATH\${GHC_PACKAGE_PATH:+$PATH_DELIMITER}$pkgdb;
EOF
}
# create an empty package database in which the new library can be registered.
createEmptyPackageDatabaseAndSetupHook(){
ensureDir $out/nix-support;
PACKAGE_DB=$out/nix-support/package.conf;
echo '[]' > "$PACKAGE_DB";
setupHookRegisteringPackageDatabase
}

View File

@ -1,163 +0,0 @@
args: with args;
let inherit (bleedingEdgeRepos) sourceByName;
# map ghcCabalExecutableFun and add cabal dependency to all
executables = lib.mapAttrs ( name_dummy : a : ghcCabalExecutableFun (a // { libsFun = x : (a.libsFun x) ++ [x.cabal_darcs]; } ) )
({
nixRepositoryManager = import ./nix-repository-manager.nix {
inherit (args) lib pkgs;
inherit bleedingEdgeRepos;
};
hasktags = {
# calling it hasktags-modified to not clash with the one distributed with ghc
name = "hasktags-modified";
src = args.fetchurl {
url = http://mawercer.de/~nix/hasktags.hs;
sha256 = "9d1be56133f468f5a2302d8531742eba710ad89d5a271308453b44cc9f47e94a";
};
libsFun = x : [x.base x.directory x.haskell98 x.mtl];
pass = {
phases = "buildPhase";
buildPhase = "
ensureDir \$out/bin; cp $src hasktags.hs
ghc --make hasktags.hs -o \$out/bin/hasktags-modified
";
};
meta = {
# this package can be removed again when somone comitts my changes into the distribution
description = "Marc's modified hasktags";
};
};
happy = {
name = "happy-1.17";
libsFun = x : [x.base x.directory x.haskell98 x.mtl];
src = fetchurl {
url = "http://hackage.haskell.org/packages/archive/happy/1.17/happy-1.17.tar.gz";
sha256 = "0aqaqy27fkkilj3wk03krx2gdgrw5hynn8wnahrkimg52xyy996w";
};
meta = {
executables = ["happy"];
description = "A lexical analyser generator for Haskell";
homepage = http://www.haskell.org/happy/;
license = "BSD3";
};
pass = {
patchPhase = '' sed -e "s/buildVerbose flags/fromFlag (buildVerbosity flags)/g" -e "s/BuildFlags(..)/BuildFlags(..), fromFlag/g" -i Setup.lhs '';
};
};
alex = {
name = "alex-2.2";
libsFun = x : [x.base x.haskell98];
src = fetchurl {
url = "http://hackage.haskell.org/packages/archive/alex/2.2/alex-2.2.tar.gz";
sha256 = "1zhzlhwljbd52hwd8dm7fcbinfzjhal5x91rvi8x7cgxdkyd8n79";
};
meta = {
executables = ["alex"];
description = "tool generating lexical analysers";
homepage = http://www.haskell.org/alex/;
license = "BSD3";
};
pass = {
patchPhase = '' sed -e "s/buildVerbose flags/fromFlag (buildVerbosity flags)/g" -e "s/BuildFlags(..)/BuildFlags(..), fromFlag/g" -i Setup.lhs '';
};
};
drift = {
name = "DrIFT-2.2.3";
libsFun = x : [ x.base x.haskell98 ];
src = fetchurl {
url = http://hackage.haskell.org/packages/archive/DrIFT/2.2.3/DrIFT-2.2.3.tar.gz;
sha256 = "1615ijdz1bcmgnz86yx54ap6r7q08flh309jfyc7xaxxq5cdib0k";
};
meta = {
description = "DrIFT is a type sensitive preprocessor for Haskell";
homepage = http://repetae.net/computer/haskell/DrIFT/;
license = "BSD3";
};
};
hxq = {
name="hxq-0.7";
libsFun = x: [ x.base x.haskell98 x.template_haskell ];
src = fetchurl { url = http://hackage.haskell.org/packages/archive/HXQ/0.7/HXQ-0.7.tar.gz; sha256 = "0zwar8fykks1n86zm0alkdx4yg903hkdr66wffsji6fhhpkzcmrh";};
};
#leksah = {
#name="leksah-darcs";
#libsFun = x: [ x.base x.filepath x.parsec x.mtl x.process x.old_time x.containers x.pretty x.directory x.gtk2hs x.binary x.bytestring x.cabal_darcs x.ghc ];
#src = sourceByName "leksah";
#};
#hsffig =
# let version = "0.1.2-08-29-2007"; in
# rec {
# name = "hsffig-${version}";
# src = fetchurl {
# url = "http://www.golubovsky.org/software/hsffig/nightly/hsffig.${version}.tar.gz";
# sha256 = "0pp27dchp5jshsacc1n15jvabsvc60l6phyfw0x9y6cmcwq72blg";
# };
# pass = { patchPhase = ''
# sed -e "s/ALEX =.*/ALEX=alex/" -e "s/-package text//" -i Makefile
# '';
# buildPhase = "unset buildPhase; buildPhase"; [> force using default buildPhase
# };
# libsFun = x : [ x.base x.directory x.process x.cabal_darcs x.finitemap executables.alex executables.happy ];
# meta = {
# description = "automatically generates C bindings for haskell (needs hsc2hs)";
# homepage = "now sourceforge";
# license = "BSD";
# executables = ["hsffig"];
# };
#};
flapjax = {
name = "flapjax-source-20070514";
src = args.fetchurl {
url = http://www.flapjax-lang.org/download/20070514/flapjax-source.tar.gz;
sha256 = "188dafpggbfdyciqhrjaq12q0q01z1rp3mpm2iixb0mvrci14flc";
};
pass = { buildPhase = "
ensureDir \$out/bin
cd compiler;
ghc --make Fjc.hs -o \$out/bin/fjc
"; };
libsFun = x : [x.mtl x.parsec x.random];
meta = {
description = "programming language designed around the demands of modern, client-based Web applications";
homepage = http://www.flapjax-lang.org/;
license = "BSD";
executables = ["fjc"];
};
};
/*
xmonad = {
name = "xmonad-darcs";
libsFun = x : [x.base x.mtl x.unix x.x11 x.x11extras xmessage ];
src = sourceByName "xmonad";
};
darcs_unstable = {
name = "darcs_unstable";
libsFun = x : [x.base x.haskell98 x.http_darcs x.regex_compat x.quickcheck x.bytestring x.parsec x.html x.containers];
src = sourceByName "pg_darcsone";
pass = {
buildInputs = [ autoconf zlib ];
postUnpack = "cd nix_*; pwd; autoconf; cd ..";
NIX_LDFLAGS = "-lz";
};
};
*/
mkcabal = {
name = "mkcabal-0.4.1";
libsFun = x : [x.base x.readline x.pcreLight x.mtl];
src = sourceByName "mkcabal";
meta = {
executables = ["mkcabal"];
description = "mkcabal";
homepage = "hackage";
license = "BSD3";
};
pass = {
patchPhase = "sed -i s/0.3/0.3.1/g -i mkcabal.cabal";
buildInputs = pkgs.readline; # hack - this shouldn't be needed!
};
};
} // getConfig ["ghc68CustomExecutables"] (x : {} ) pkgs ); in executables

View File

@ -1,48 +0,0 @@
/*
repos for config file taken from all-pacakges.bleedingEdgeFetchInfo
nix-repository-manager --update <name> (for your local use only)
if you want to publish repos ask for the password (marco-oweber@gmx.de)
echo '{ bleedingEdgeFetchInfo = "${your_nix_pkgs_location}/pkgs/misc/bleeding-edge-fetch-info"; }' >> .nixpkgs/config.nix
reinstall nix-repository-manager to recreate config
nix-repository-manager --publish <name> (to save on server
*/
args: with args; with args.lib;
let
inherit (builtins) getAttr attrNames;
toConfigLine = name : set :
"[(\"name\",\"${name}\")," + ( concatStringsSep "," (map (a: "(\"${a}\",\"${getAttr a set}\")" ) (attrNames set)))+"]";
config = pkgs.writeText "nix-repository-manager_config"
(bleedingEdgeRepos.managedRepoDir+"\n" +
concatStringsSep "\n" (mapRecordFlatten toConfigLine (bleedingEdgeRepos.repos)));
in
{
name = "nix-repository-manager";
libsFun = x : [x.base x.time x.old_locale x.mtl];
src = bleedingEdgeRepos.sourceByName "nix_repository_manager";
pass = {
buildPhase = ''
cp ${pkgs.getConfig ["nixRepositoryManager" "sourcefile"] "nix-repository-manager.hs"} source.hs
s=$out/share/nix-repository-manager
ensureDir $out/bin $s
ghc --make source.hs -o $s/nix-repository-manager
b=$out/bin/nix-repository-manager
echo -e "#!/bin/sh\n$s/nix-repository-manager ${config} \$@" > $b
chmod +x $b
'';
};
meta = {
description = "makes it easy to keep some packages up to date";
homepage = http://mawercer.de/repos/nix-repository-manager;
license = "GPL";
};
}

View File

@ -1,67 +0,0 @@
--- b/Setup.lhs 2007-07-13 16:06:51.000000000 +0000
+++ a/Setup.lhs 2008-05-07 19:20:08.000000000 +0000
@@ -4,7 +4,10 @@
> import Distribution.Simple
> import Distribution.Simple.Configure
> import Distribution.Simple.LocalBuildInfo
+> import Distribution.Simple.Program
> import Distribution.Setup
+> import Distribution.Text
+> import Distribution.Verbosity
> import Distribution.PackageDescription
> import IO
> import System
@@ -17,23 +20,23 @@
> { instHook = myInstaller
> }
>
-> myInstaller :: PackageDescription -> LocalBuildInfo -> Maybe UserHooks -> InstallFlags -> IO ()
-> myInstaller pdesc lbi mhook userFlags =
-> do instHook defaultUserHooks pdesc lbi mhook userFlags
+> myInstaller :: PackageDescription -> LocalBuildInfo -> UserHooks -> InstallFlags -> IO ()
+> myInstaller pdesc lbi hook userFlags =
+> do instHook defaultUserHooks pdesc lbi hook userFlags
> myPostInstaller pdesc userFlags lbi
>
> -- | Build and install the shell script to invoke the Haskell compiler with
> -- the correct flags
> myPostInstaller :: PackageDescription -> InstallFlags -> LocalBuildInfo -> IO ()
> myPostInstaller pdesc instFlags localBuildInfo =
-> let hc = compiler localBuildInfo
-> bindir = prefix localBuildInfo ++ "/bin"
+> let bindir = ((fromPathTemplate . prefix . installDirTemplates) localBuildInfo) ++ "/bin"
> generated = bindir ++ "/washc"
-> pid = showPackageId (package pdesc)
+> pid = display (package pdesc)
> in
> do h <- openFile generated WriteMode
+> compilerPath <- fmap ( programPath . fst) $ requireProgram normal ghcProgram AnyVersion (withPrograms localBuildInfo)
> hPutStrLn h "#!/bin/sh"
-> hPutStr h (compilerPath hc)
+> hPutStr h compilerPath
> hPutStr h " -pgmF "
> hPutStr h bindir
> hPutStr h "/wash2hs"
--- a/WASH.cabal 2008-05-11 22:35:37.000000000 +0200
+++ b/WASH.cabal 2008-05-11 22:35:51.000000000 +0200
@@ -8,7 +8,7 @@
Category: Web
Stability: Beta
Synopsis: WASH is a family of embedded domain specific languages (EDSL) for programming Web applications in Haskell.
-Build-Depends: base, regex-compat, haskell98, parsec
+Build-Depends: base, regex-compat, haskell98, parsec, containers
Extensions: ForeignFunctionInterface
Exposed-Modules:
WASH.CGI.AbstractSelector
--- a/Setup.lhs
+++ b/Setup.lhs
@@ -5,7 +5,7 @@ arch-tag: Main setup script
> import Distribution.Simple.Configure
> import Distribution.Simple.LocalBuildInfo
> import Distribution.Simple.Program
-> import Distribution.Setup
+> import Distribution.Simple.Setup
> import Distribution.Text
> import Distribution.Verbosity
> import Distribution.PackageDescription

View File

@ -1,452 +0,0 @@
/* hackish collection of ghc packages
this will be replaced in the future
A library is defined by this attribute set:
<attr name> = {
name =
src =
p_deps = [ x.<attr name> x.<attr name> ] # x = recursive list of packages defined here and the core packages shipping with ghc
srcDir = <subDir of source> # optional
pass = {
# stuff passed to the builder as is (used for patches most of the time
};
}
*/
# TODO use nix names (regexCompat instead of regex_compat)
args : ghc: with args;
rec {
# name (using lowercase letters everywhere because using installing packages having different capitalization is discouraged) - this way there is not that much to remember?
cabal_darcs_name = "cabal-darcs";
# introducing p here to speed things up.
# It merges derivations (defined below) and additional inputs. I hope that using as few nix functions as possible results in greates speed?
# unfortunately with x; won't work because it forces nix to evaluate all attributes of x which would lead to infinite recursion
pkgs = let x = ghc.core_libs // derivations;
wxVersion = "0.10.3";
wxSrc = fetchurl { url = "mirror://sourceforge/wxhaskell/wxhaskell-src-${wxVersion}.tar.gz";
sha256 = "2a9b70b92c96ef1aa3eaa3426e224c0994c24bfdaccbf2b673edef65ba3cffce"; };
inherit (bleedingEdgeRepos) sourceByName;
in {
# ghc extra packages
mtl = { name="mtl-1.1.0.0"; srcDir="libraries/mtl"; p_deps=[ x.base ]; src = ghc.extra_src; };
parsec = { name="parsec-2.1.0.0"; srcDir="libraries/parsec"; p_deps=[ x.base ]; src = ghc.extra_src; };
network = { name="network-2.1.0.0"; srcDir="libraries/network"; p_deps=[ x.base x.parsec3 x.haskell98 ]; src = ghc.extra_src; };
regex_base = { name="regex-base-0.72.0.1"; srcDir="libraries/regex-base"; p_deps=[ x.base x.array x.bytestring x.haskell98 ]; src = ghc.extra_src; };
regex_posix = { name="regex-posix-0.72.0.2"; srcDir="libraries/regex-posix"; p_deps=[ x.regex_base x.haskell98 ]; src = ghc.extra_src; };
regex_compat = { name="regex-compat-0.71.0.1"; srcDir="libraries/regex-compat"; p_deps=[ x.base x.regex_posix x.regex_base x.haskell98 ]; src = ghc.extra_src; };
stm = { name="stm-2.1.1.0"; srcDir="libraries/stm"; p_deps=[ x.base x.array ]; src = ghc.extra_src; };
hunit = { name="HUnit-1.2.0.0"; srcDir="libraries/HUnit"; p_deps=[ x.base ]; src = ghc.extra_src; };
quickcheck = { name="QuickCheck-1.1.0.0"; srcDir="libraries/QuickCheck"; p_deps=[x.base x.random]; src = ghc.extra_src; };
tagsoup = { name = "tagsoup-0.4"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/tagsoup/0.4/tagsoup-0.4.tar.gz; sha256 = "0rdy303qaw63la1fhw1z8h6k8cs33f71955pwlzxyx0n45g58hc7";}; p_deps = [ x.base x.mtl x.network ]; };
hxt = { name = "hxt-7.5"; src =fetchurl { url = http://hackage.haskell.org/packages/archive/hxt/7.5/hxt-7.5.tar.gz; sha256 ="00q6m90a4qm4d5cg1x9r6b7f0rszcf2y7ifzs9mvy9kmzfl5ga7n"; }; p_deps = [x.base x.haskell98 x.http_darcs x.hunit x.network x.parsec x.tagsoup ]; };
storableVector = { name = "storablevector-0.1.2.2"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/storablevector/0.1.2.2/storablevector-0.1.2.2.tar.gz; sha256="1gf2a40mv8xxppdmg9l3svshww4sg0wwdqlwjl95nhacm0f6yrhb"; }; p_deps = [ x.base x.bytestring x.mtl x.quickcheck x.random ]; };
storableVectorDarcs = { name = "storablevector-darcs"; src = sourceByName "storableVector"; p_deps = [ x.base x.bytestring x.mtl x.quickcheck x.random ]; };
typeInt = { name="type-int-0.4"; src = fetchurl { url = "/nix/store/cvnf71gxvk1lxnibigc2ang10hi4i5qi-type-int-0.4.tar.gz"; sha256="0h64cx2zpijaaxnzhal2m311q33drvynjbmxavh7z5b8fmaqmnws"; }; p_deps = [ x.base x.template_haskell ]; };
typeLevel = {name="type-level-0.2.1"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/type-level/0.2.1/type-level-0.2.1.tar.gz; sha256 = "077g6i9v1wvsk1narnxp9m0svlkz9lpf0adalhlw2m7268rpr148"; }; p_deps = [ x.base x.template_haskell ]; };
haskellnet = { name = "HaskellNet-0.2"; src = sourceByName "haskellnet"; p_deps = [ x.base x.haskell98 x.network x.crypto x.mtl x.parsec x.time x.haxml x.bytestring x.pretty x.array x.dataenc x.containers x.old_locale x.old_time ];
pass = {
patchPhase = "
patch -p1 < \$patch
sed -i 's/mtl/mtl, bytestring, pretty, array, dataenc, containers, old-locale, old-time/' *.cabal
";
patch= ./haskellnetPatch ;
};
};
dataenc = { name = "dataenc-0.10.2"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/dataenc/0.10.2/dataenc-0.10.2.tar.gz; sha256="1kl087994ajbwy65f24qjnz6wchlhmk5vkdw1506zzfbi5fr6x7r"; }; p_deps = [ x.base ]; };
# other pacakges (hackage etc)
polyparse = { name = "polyparse-2.3"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/polyparse/1.1/polyparse-1.1.tar.gz; sha256 = "0mrrk3hhfrn68xn5y4jfg4ba0pa08bj05l007862vrxyyb4bksl7"; }; p_deps = [ x.base x.haskell98 ]; };
# plugins doesn't compile with recent cabal
# plugins = { name="plugins-1.2"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/plugins/1.2/plugins-1.2.tar.gz; sha256 = "1v2b3p3d2d3ab8zlzad4i6yy3zmarvkd09r71yc237xx66s7i9s5"; }; p_deps = [ x.array x.base x.cabal_darcs x.containers x.directory x.ghc x.haskellSrc x.process x.random ]; };
plugins_darcs = { name="plugins-darcs"; src = sourceByName "plugins"; p_deps = [ x.array x.base x.cabal_darcs x.containers x.directory x.ghc x.haskellSrc x.process x.random ];
pass = { patches = ./plugins-darcs.patch; };
};
hinotify = { name="hinitofy-0.2"; src = fetchurl{ url = http://hackage.haskell.org/packages/archive/hinotify/0.2/hinotify-0.2.tar.gz; sha256 = "1x9mnlqy8lsq3qy9d559kxwqlj32smr9an76nf5i4hj67vicw1al"; }; p_deps = [ x.base x.containers x.directory x.unix ]; };
harp = { name="harp-0.2.1"; src = fetchurl{ url = http://hackage.haskell.org/packages/archive/harp/0.2.1/harp-0.2.1.tar.gz; sha256 = "865e8c229e1ff89297b4348be95d93c10e373b63b7910da1e6b3330b48b96b87"; }; p_deps = [x.base]; };
hsx = { name="hsx-0.4.4"; src = fetchurl{ url = http://hackage.haskell.org/packages/archive/hsx/0.4.4/hsx-0.4.4.tar.gz; sha256 = "1wr70h1r8vmzs1xsiiq89h0k3gips8krp5p4s4f6vjglg3w27q7h"; }; p_deps = [x.base x.haskellSrcExt x.mtl x.haskellSrcExtDarcs]; };
# TODO remove
# haskell_src_exts_metaquote = { name = "haskell_src_exts_metaquote-darcs"; src = sourceByName "haskell_src_exts_metaquote"; p_deps = [ x.base x.mtl x.containers x.array x.pretty x.binary x.packaged_string ]; };
# hint = { name="hint-0.1"; src = fetchurl { url = "http://hackage.haskell.org/packages/archive/hint/0.1/hint-0.1.tar.gz"; sha256 = "1adydl2la4lxxl6zz24lm4vbdrsi4bkpppzxhpkkmzsjhhkpf2f9"; }; p_deps = [ x.base x.ghc x.haskellSrc x.mtl ]; };
pcreLight = { name="pcre-light-0.3.1"; src= fetchurl { url = http://hackage.haskell.org/packages/archive/pcre-light/0.3.1/pcre-light-0.3.1.tar.gz; sha256 = "1h0qhfvqjcx59zkqhvsy7vw23l4444czg2z7b2lndy6cmkqc719m"; }; p_deps = [x.base x.bytestring pcre x.haskell98 ];
pass = { patchPhase = "
echo \" extra-lib-dirs: ${pcre}/lib\" >> pcre-light.cabal
";
}; };
hsHaruPDF = { name = "HsHaruPDF-0.0.0"; src = fetchurl{url= "http://hackage.haskell.org/packages/archive/HsHaruPDF/0.0.0/HsHaruPDF-0.0.0.tar.gz"; sha256="1yifhxk1m3z2i7gaxgwlmk6cv2spbpx8fny4sn59ybca8wd9z7ps";}; p_deps = [ x.base x.haskell98 ];
pass = { buildInputs = [ mysql zlib libpng ];
patchPhase = "
sed 's/include-dirs:.*/include-dirs: haru/' -i HsHaruPDF.cabal
sed 's=extra-lib-dirs:.*=extra-lib-dirs: ${libpng}/lib ${zlib}/lib=' -i HsHaruPDF.cabal
";
};
};
# hint = { name="hint-0.1"; src = fetchurl { url = "http://hackage.haskell.org/packages/archive/hint/0.1/hint-0.1.tar.gz"; sha256 = "1adydl2la4lxxl6zz24lm4vbdrsi4bkpppzxhpkkmzsjhhkpf2f9"; }; p_deps = [ x.base x.ghc x.haskellSrc x.mtl ]; };
bloomfilter = { name = "bloomfilter-1.2.1"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/bloomfilter/1.2.1/bloomfilter-1.2.1.tar.gz; sha256 = "1d2m0w8lgpdpykdgp08bmy5jb1c89by4xnkfy2bnh8f02nb1zlsm"; }; p_deps = [ x.base x.bytestring x.containers ]; };
timeout = { name="timeout-0.1.2"; src = fetchurl{ url = http://hackage.haskell.org/packages/archive/control-timeout/0.1.2/control-timeout-0.1.2.tar.gz; sha256 = "1g1x6c4dafckwcw48v83f3nm2sxv8kynwv8ib236ay913ycgayvg";}; p_deps = [ x.base x.time x.stm ]; };
parsec3 = { name="parsec-3.0.0"; p_deps=[ x.base x.mtl x.bytestring ]; src = fetchurl { url = "http://hackage.haskell.org/packages/archive/parsec/3.0.0/parsec-3.0.0.tar.gz"; sha256 = "0fqryy09y8h7z0hlayg5gpavghgwa0g3bldynwl17ks8l87ykj7a"; }; };
binary = rec { name = "binary-0.4.1"; p_deps = [ x.base x.bytestring x.containers x.array ];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/binary/0.4.1/binary-0.4.1.tar.gz";
sha256 = "0jg5i1k5fz0xp1piaaf5bzhagqvfl3i73hlpdmgs4gc40r1q4x5v"; };
};
hlist = { name="HList-0.1"; src = fetchurl { url="http://hackage.haskell.org/packages/archive/HList/0.1/HList-0.1.tar.gz"; sha256 = "1gv80qrnf71fzgb2ywaybkfvida0pwkd4a53vhmc0yg214yin4kh"; }; p_deps = [ ]; };
# using different name to not clash with postgresql
postgresql_bindings = rec { name = "PostgreSQL-0.2"; p_deps = [x.base x.mtl postgresql x.haskell98];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/PostgreSQL/0.2/PostgreSQL-0.2.tar.gz";
sha256 = "0p5q3yc8ymgzzlc600h4mb9w86ncrgjdbpqfi49b2jqvkcx5bwrr"; };
pass = {
inherit postgresql;
patchPhase = "echo 'extensions: MultiParamTypeClasses ForeignFunctionInterface EmptyDataDecls GeneralizedNewtypeDeriving FlexibleInstances UndecidableInstances' >> PostgreSQL.cabal
echo \"extra-lib-dirs: \$postgresql/lib\" >> PostgreSQL.cabal
echo \"extra-libraries: pq\" >> PostgreSQL.cabal
";
};
};
unixCompat ={ name = "unix-compat-0.1.2.1"; src = fetchurl { url=http://hackage.haskell.org/packages/archive/unix-compat/0.1.2.1/unix-compat-0.1.2.1.tar.gz; sha256 = "119fiazjr83xm4nk394v7lmsvhkic5k78pzcvv70j7zp83hjccsm"; }; p_deps = [ x.base x.directory x.old_time x.haskell98 ]; };
tar = rec { name = "tar-0.1.1.1"; p_deps = [ x.base x.bytestring x.haskell98 x.binary x.unixCompat ];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/tar/0.1.1.1/tar-0.1.1.1.tar.gz";
sha256 = "08ns56xxw6519q0f7fqdznhcwx5dj2rc531mivxdyja6lmmjcfcb"; };
};
zlib = rec { name = "zlib-0.4.0.4"; p_deps = [ x.base x.bytestring x.haskell98 ];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/zlib/0.4.0.4/zlib-0.4.0.4.tar.gz";
sha256 = "14hzqpzqs3rcwx6qpgybrcz33yrzb5y4p0bdsilhdgl15594ibad"; };
pass = {
patchPhase = ''
echo " extra-lib-dirs: ${zlib}/lib" >> zlib.cabal
echo " include-dirs: ${zlib}/include" >> zlib.cabal'';
}; };
bzlib = rec { name = "bzlib-0.4.0.3"; p_deps = [ x.base x.bytestring x.haskell98 ];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/bzlib/0.4.0.3/bzlib-0.4.0.3.tar.gz";
sha256 = "0mdhqds2d4lx75yy39bvbvmvkb81xl1mhgbjwi4299j7isrrgmb4"; };
pass = {
patchPhase = ''
echo " extra-lib-dirs: ${bzip2}/lib
include-dirs: ${bzip2}/include" >> bzlib.cabal '';
}; };
wash = rec { name = "WashNGo-2.12"; p_deps = [x.base x.mtl x.haskell98 x.regex_compat x.parsec x.containers ];
src = fetchurl { url = "http://www.informatik.uni-freiburg.de/~thiemann/WASH/WashNGo-2.12.tgz";
sha256 = "1dyc2062jpl3xdlm0n7xkz620h060g2i5ghnb32cn95brcj9fgrz"; };
useLocalPkgDB = true;
pass = {
patches = ./WASHNGo_Patch_ghc682;
};
};
#hsql = rec { name = "hsql-1.7"; p_deps = [x.base x.mtl x.haskell98 x.old_time ];
#src = fetchurl { url = "http://hackage.haskell.org/packages/archive/hsql/1.7/hsql-1.7.tar.gz";
#sha256 = "0j2lkvg5c0x5gf2sy7zmmgrda0c3l73i9d6hyka2f15d5n1rfjc9"; };
#pass = { patchPhase = "
#sed -e 's=build-depends:.*=build-depends: base, old-locale, old-time=' -i hsql.cabal
#echo \"extensions:
#ForeignFunctionInterface, TypeSynonymInstances, CPP, ExistentialQuantification, GeneralizedNewtypeDeriving, PatternSignatures, ScopedTypeVariables, Rank2Types, DeriveDataTypeable \" >> hsql.cabal
#"; };
#};
# supports new time library
hsqlDarcs = rec { name = "hsql-darcs"; p_deps = [x.base x.mtl x.haskell98 x.old_time x.old_locale x.time ];
src = sourceByName "hsql";
pass = { srcDir = "HSQL"; };
};
hsqlMysqlDarcs = { name = "hsql-mysql-darcs"; srcDir = "MySQL"; src = sourceByName "hsql"; p_deps = [ x.base x.hsqlDarcs x.old_time ];
pass = { buildInputs = [ mysql zlib ];
patchPhase = "echo \" extra-lib-dirs: ${zlib}/lib\" >> MySQL/hsql-mysql.cabal
sed -e \"s=configVerbose=configVerbosity=\" -e \"s=sqlite_path=\$sqlite=\" -i MySQL/Setup.lhs
";
};
};
#hsql_postgresql = rec { name = "hsql-postgresql-1.7"; p_deps = [ x.base x.mtl x.haskell98 x.old_time x.hsql postgresql ];
# src = fetchurl { url = "";
# sha256 = "180c8acp4p9hsl5h8ryhhli9mlqcmcfjqaxzr7sa074gpzq29vfc"; };
# pass = { patchPhase = "
# sed -e 's=build-depends:.*=build-depends: base, old-locale, old-time=' -i hsql.cabal
# echo \"extensions:
# ForeignFunctionInterface, TypeSynonymInstances, CPP, ExistentialQuantification, GeneralizedNewtypeDeriving, PatternSignatures, ScopedTypeVariables, Rank2Types, DeriveDataTypeable \" >> hsql.cabal
# "; };
# };
# I'm getting a glibc error when compiling - where does it come from ?
#takusen = rec { name = "takusen-0.8"; p_deps = [ x.base x.mtl x.haskell98 x.time postgresql sqlite ];
# src = sourceByName "takusen";
# pass = {
# inherit postgresql sqlite;
# patch = ./takusen_setup_patch;
# [> no ODBC, Oracle support in nix
# patchPhase = "patch -p1 Setup.hs < \$patch
# sed -e '/ODBC/d' -i Takusen.cabal
# sed -e '/Oracle/d' -i Takusen.cabal
# sed -e \"s=pg_path=\$postgresql=\" -e \"s=sqlite_path=\$sqlite=\" -i Setup.hs
# sed -e \"s=configVerbose=configVerbosity=\" -e \"s=sqlite_path=\$sqlite=\" -i Setup.hs
# sed -e \"s=regVerbose=regVerbosity=\" -e \"s=sqlite_path=\$sqlite=\" -i Setup.hs
# ";
# };
# };
hdbc = rec { name = "hdbc-1.1.4.0"; p_deps = [ x.base x.mtl x.haskell98 x.time x.bytestring postgresql sqlite ];
src = fetchurl {
url = http://software.complete.org/hdbc/static/download_area/1.1.4.0/hdbc_1.1.4.0.tar.gz;
sha256 = "677e789094e3790be2462331b6c0f97b4ac1d65c8eb98cf7d8b83d5f3f9fbd39";
};
pass = {
inherit postgresql sqlite;
#patch = ./takusen_setup_patch;
# no ODBC, Oracle support in nix
#patchPhase = "patch -p1 Setup.hs < \$patch
# sed -e '/ODBC/d' -i Takusen.cabal
# sed -e '/Oracle/d' -i Takusen.cabal
# sed -e \"s=pg_path=\$postgresql=\" -e \"s=sqlite_path=\$sqlite=\" -i Setup.hs
# ";
};
};
hdbc_postgresql = { name = "hdbc-postgresql"; p_deps = [ x.hdbc x.parsec3 postgresql ];
src = fetchurl {
url = http://hackage.haskell.org/packages/archive/HDBC-postgresql/1.1.4.0/HDBC-postgresql-1.1.4.0.tar.gz;
sha256 = "1b9lxj55jvvq76ll8dr4kfb6aj7r0baj4gh8wkhgwc1kd41sx7h3"; };
pass = {
patches = [ ./hdbc_postgresql_patch ];
patchPhase = "unset patchPhase; patchPhase;
sed -e '/Cabal-Ver/d' -i HDBC-postgresql.cabal";
};
};
gtk2hs = rec { name = "gtk2hs-0.9.12.1"; p_deps = [ x.haskell98 x.mtl x.bytestring pkgconfig ] ++ (with gtkLibs; [ glib pango gtk gnome.glib gnome.gtksourceview]);
src = fetchurl {
url = "http://downloads.sourceforge.net/gtk2hs/${name}.tar.gz";
sha256 = "110z6v9gzhg6nzlz5gs8aafmipbva6rc50b8z1jgq0k2g25hfy22"; };
pass = {
buildPhase = "
createEmptyPackageDatabaseAndSetupHook
export GHC_PACKAGE_PATH
./configure --prefix=\$out --with-user-pkgconf=local-pkg-db --with-pkgconf=\$PACKAGE_DB
make
ensureDir \$out
make install
";
};
};
hspread = { name = "hspread-0.3"; p_deps = [ x.base x.bytestring x.network x.binary ];
src = fetchurl {
url = http://hackage.haskell.org/packages/archive/hspread/0.3/hspread-0.3.tar.gz;
sha256 = "0lwq7v7p6akykcsz6inkg99h3z7ab1gs5nkjjlgsbyqbwvimmf5n"; };
pass = {
};
};
wxcore = rec {
name = "wxhaskel-${wxVersion}"; p_deps = [ x.haskell98 x.mtl x.bytestring x.parsec3 pkgconfig wxGTK ] ++ (with gtkLibs; [ glib pango gtk gnome.glib]);
src = wxSrc;
pass = {
profiling = if getConfig [ "ghc68" "profiling" ] false then "--hcprof" else "";
buildInputs = [ unzip ];
buildPhase = "
createEmptyPackageDatabaseAndSetupHook
export GHC_PACKAGE_PATH
sed -e 's/which/type -p/g' configure
./configure --prefix=\$out --package-conf=\$PACKAGE_DB \$profiling
make
ensureDir \$out
make install
";
};
};
wx = { name="wx-${wxVersion}"; src =wxSrc; srcDir="wx"; p_deps = [ x.haskell98 x.mtl x.bytestring x.parsec3 x.wxcore pkgconfig wxGTK ] ++ (with gtkLibs; [ glib pango gtk gnome.glib]);
# TODO rempove pwd
pass = { patchPhase = "pwd; cp {,wx/}license.txt"; };
};
typecompose = { name="TypeCompose-0.4"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/TypeCompose/0.5/TypeCompose-0.5.tar.gz; sha256 = "0mzjvwjixkp0jxfzxjw1pq8k1sm61sb5y96fk07xm91nn4sgpaqj"; }; p_deps = [ x.base ]; };
reactive = { name="reactive-0.5"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/reactive/0.5/reactive-0.5.tar.gz; sha256 = "1giv5p2nks4rw683bkmnjmdanpx8mgqi6dzj099cjbk93jag9581"; }; p_deps = [ x.base x.typecompose ]; };
phooey = { name="phooey-2.0"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/phooey/2.0/phooey-2.0.tar.gz; sha256 = "1bb6cn2vk7b57gaxh863ymidb4l7ldiwcnpif790rd4bq44fwfvf"; }; p_deps = [ x.base x.typecompose x.reactive x.wx x.wxcore ]; };
# depreceated (This is the deprecated Data.FiniteMap library, often useful to get old code to build when you are too lazy to update it.)
finitemap = { name="finitemap-0.1"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/FiniteMap/0.1/FiniteMap-0.1.tar.gz; sha256 = "1kf638h5gsc8fklhaw2jiad1r0ssgj8zkfmzywp85lrx5z529gky"; }; p_deps = [ x.base x.haskell98 ]; };
parallel = { name = "parallel-1.0.0.0"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/parallel/1.0.0.0/parallel-1.0.0.0.tar.gz; sha256 = "0f6g724zpdqhjcfv064yknrdx4rjaaj71bfx57c8ywizifcwxp4h"; }; p_deps = [x.base]; };
httpSimple = { name = "HTTP-Simple-0.1"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/HTTP-Simple/0.1/HTTP-Simple-0.1.tar.gz; sha256 = "0mbszgx8x02wry2h8jhdc51ryi7dwbi396y5h4k6p0bva8yp5bd0"; }; p_deps = [x.base x.network x.http_darcs]; };
deeparrow = { name = "DeepArrow-0.2"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/DeepArrow/0.2/DeepArrow-0.2.tar.gz; sha256 = "1rm55nryg2z4r5919da2cc3nq08cg0g9gf59qfzl50lfccq8x2wd"; }; p_deps = [ x.base x.mtl x.typecompose x.haskellSrc ]; };
tv = { name = "TV-0.4"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/TV/0.4/TV-0.4.tar.gz; sha256 = "0hracvx6pydmqfkx9n906k0463b0qaxskis91kir63ivf91zwndp"; }; p_deps = [ x.base x.typecompose x.deeparrow]; };
guitv = { name = "GuiTV-0.4"; src = fetchurl { url = http://darcs.haskell.org/packages/GuiTV/dist/GuiTV-0.4.tar.gz; sha256 = "15mndbxm83q0d8ci3vj51zwrmzl0f5i5yqv0caw05vlzfsr4ib5i";}; p_deps = [ x.base x.deeparrow x.typecompose x.phooey x.tv ]; };
haskellSrc = { name = "haskell-src-1.0.1.1"; src = fetchurl { url = "http://hackage.haskell.org/packages/archive/haskell-src/1.0.1.1/haskell-src-1.0.1.1.tar.gz"; sha256 = "06kilrf7y5h6dxj57kwymr20zvdsq6zhchwn4wky12mrmzjxyj01"; }; p_deps = [ x.haskell98 x.base x.pretty x.array ];
pass = { buildInputs = (with executables; [ happy alex ] ); };
};
haskellSrcExt = { name = "haskell-src-exts-0.3.3.tar.gz"; src = fetchurl { url = "http://hackage.haskell.org/packages/archive/haskell-src-exts/0.3.3/haskell-src-exts-0.3.3.tar.gz"; sha256 = "0g9ibjj1k5k3mqfx5mp8pqr0zx53pp9dkf52r8cdv18bl8xhzbpx"; }; p_deps = [ x.base x.base x.array x.pretty ];
pass = { buildInputs = (with executables; [ happy alex ] ); };
};
haskellSrcExtDarcs = { name = "haskell-src-exts-darcs"; src = sourceByName "haskell_src_exts"; p_deps = [ x.base x.base x.array x.pretty ];
pass = { buildInputs = (with executables; [ happy alex ] ); };
};
# haskelldb
haskelldb = { name = "haskelldb-0.10"; src = fetchurl { url = "http://hackage.haskell.org/packages/archive/haskelldb/0.10/haskelldb-0.10.tar.gz"; sha256 = "1i4kgsgajr9cijg0a2c04rn1zqwiasfvdbvs8c5qm49vkbdzm7l5"; }; p_deps = [ x.base x.haskell98 x.mtl x.pretty x.old_time x.directory x.old_locale];
pass = { patchPhase = "sed -i 's/mtl/mtl, pretty, old-time, directory, old-locale/' haskelldb.cabal
echo 'ghc-options: -O2 -fglasgow-exts -fallow-undecidable-instances' >> haskelldb.cabal"; };
};
#hsql drivers
haskelldbHsql = { name= "haskelldb-hsql--0.10"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/haskelldb-hsql/0.10/haskelldb-hsql-0.10.tar.gz; sha256 = "0s3bjm080hzw23zjxr4412m81v408ll9y6gqb2yyw30n886ixzgh"; }; p_deps = [ x.base x.haskell98 x.mtl x.hsqlDarcs x.haskelldb x.old_time x.old_locale ];
pass = { patchPhase = "sed -i 's/mtl/mtl, pretty, old-time, directory, old-locale/' haskelldb-hsql.cabal
echo 'ghc-options: -O2 -fglasgow-exts -fallow-undecidable-instances' >> haskelldb-hsql.cabal"; };
};
haskelldbHsqlMysql = { name= "haskelldb-hsql-mysql-0.10"; src = fetchurl { url = http://hackage.haskell.org/packages/archive/haskelldb-hsql-mysql/0.10/haskelldb-hsql-mysql-0.10.tar.gz; sha256 = "0nfgq0xn45rhwxr8jvawviqfhgvhqr56l7ki1d72605y34dfx7rw"; }; p_deps = [ x.base x.haskell98 x.mtl x.hsqlDarcs x.haskelldbHsql x.hsqlMysqlDarcs x.haskelldb ]; };
getOptions = rec { name = "GetOptions"; p_deps = [ x.haskell98 x.base x.mtl ];
src = sourceByName "getOptions";
};
# 1.13 is stable. There are more recent non stable versions
haxml = rec { name = "HaXml-1.13.3"; p_deps = [ x.base x.rts x.directory x.process x.pretty x.containers x.filepath x.haskell98 ];
src = fetchurl { url = "http://www.haskell.org/HaXml/${name}.tar.gz";
sha256 = "08d9wy0rg9m66dd10x0zvkl74l25vxdakz7xp3j88s2gd31jp1v0"; };
};
haxml_darcs = { name = "HaXml-darcs"; p_deps = [ x.base x.rts x.directory x.process x.pretty x.containers x.filepath x.haskell98 x.polyparse x.bytestring ];
src = sourceByName "haxml";
};
xhtml = rec { name = "xhtml-3000.0.2.2"; p_deps = [ x.base ];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/xhtml/3000.0.2.2/xhtml-3000.0.2.2.tar.gz";
sha256 = "112mbq26ksh7r22y09h0xvm347kba3p4ns12vj5498fqqj333878"; };
};
html = rec { name = "html-1.0.1.1"; p_deps = [ x.base ];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/html/1.0.1.1/html-1.0.1.1.tar.gz";
sha256 = "10fayfm18p83zlkr9ikxlqgnzxg1ckdqaqvz6wp1xj95fy3p6yl1"; };
};
crypto = rec { name = "crypto-4.1.0"; p_deps = [ x.base x.array x.pretty x.quickcheck x.random x.hunit ];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/Crypto/4.1.0/Crypto-4.1.0.tar.gz";
sha256 = "13rbpbn6p1da6qa9m6f7dmkzdkmpnx6jiyyndzaz99nzqlrwi109"; };
};
hslogger = rec { name = "hslogger-1.0.4"; p_deps = [ x.containers x.directory x.mtl x.network x.process];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/hslogger/1.0.4/hslogger-1.0.4.tar.gz";
sha256 = "0kmz8xs1q41rg2xwk22fadyhxdg5mizhw0r4d74y43akkjwj96ar"; };
};
parsep = { name = "parsep-0.1"; p_deps = [ x.base x.mtl x.bytestring ];
src = fetchurl { url = "http://twan.home.fmf.nl/parsep/parsep-0.1.tar.gz";
sha256 = "1y5pbs5mzaa21127cixsamahlbvmqzyhzpwh6x0nznsgmg2dpc9q"; };
pass = { patchPhase = "sed -i 's/fps/bytestring/' *.cabal"; };
};
time = { name = "time-1.1.2.0"; p_deps = [ x.base x.old_locale ];
src = fetchurl { url = "http://hackage.haskell.org/packages/archive/time/1.1.2.0/time-1.1.2.0.tar.gz";
sha256 = "0zm4qqczwbqzy2pk7wz5p1virgylwyzd9zxp0406s5zvp35gvl89"; };
};
rjson = { name = "RJson-0.3.3"; p_deps = [ x.base x.mtl x.parsec3 x.bytestring x.iconv x.array x.containers x.syb_with_class_darcs ];
src = fetchurl { url = http://hackage.haskell.org/packages/archive/RJson/0.3.3/RJson-0.3.3.tar.gz;
sha256 = "0va1rbgjb8m3rij02318a31bi9gmy3zwyx5z12164c7iwafnd5v2"; };
};
iconv = { name = "iconv-0.4"; p_deps = [ x.base x.bytestring ];
src = fetchurl { url = http://hackage.haskell.org/packages/archive/iconv/0.4/iconv-0.4.tar.gz;
sha256 = "1snqzz7hi2qa83m5v3098rsldb485kz2jggd335qhvjahcp4bj1p"; };
};
utf8string = { name = "utf8-string-0.3"; p_deps = [ x.base x.bytestring ];
src = fetchurl { url = http://hackage.haskell.org/packages/archive/utf8-string/0.3/utf8-string-0.3.tar.gz;
sha256 = "11mln2r0ym4y12zxizn6n40xbgsi6q4n6n810rcg94bv35gqgcby"; };
};
x11 = { name = "x11-1.4.1"; p_deps = [ x.base x.haskell98 x.bytestring ] ++ (with xlibs; [ libX11 libXext ]);
src = fetchurl { url = http://hackage.haskell.org/packages/archive/X11/1.4.1/X11-1.4.1.tar.gz;
sha256 = "0yczl1m7g3lggcxh56fy2br13kbk4c5vrkcc4w76ys0m2ia3h475"; };
};
x11extras = { name = "X11-extras-0.4"; p_deps = [ x.base x.bytestring x.x11 xlibs.libXinerama ];
src = fetchurl { url = http://hackage.haskell.org/packages/archive/X11-extras/0.4/X11-extras-0.4.tar.gz;
sha256 = "1cpjr09gddcjd0wqwvaankv1zj7fyc6hbfdvar63f51g3vvw627a"; };
};
/*
x11xft = { name = "xft-0.2"; p_deps = [ x.base x.bytestring x.haskell98 x.x11 x.utf8string x.bytestring xlibs.libXft freetype];
src = fetchurl { url = http://hackage.haskell.org/packages/archive/X11-xft/0.2/X11-xft-0.2.tar.gz;
sha256 = "1ahvpkgh5mr6v8gisv1sc9s4075hqh85cpqcqh1ylr6lkf7dz31w"; };
pass = {
inherit freetype;
patchPhase = "sed -i \"s=include-dirs:.*=include-dirs: $freetype/include=\" *.cabal"; };
};
*/
# HAPPS - Libraries
http_darcs = { name="http-darcs"; p_deps = [x.network x.parsec3];
src = sourceByName "http";
#src = fetchdarcs { url = "http://darcs.haskell.org/http/"; md5 = "4475f858cf94f4551b77963d08d7257c"; };
};
syb_with_class_darcs = { name="syb-with-class-darcs"; p_deps = [x.template_haskell x.bytestring ];
src =
# fetchdarcs { url = "http://happs.org/HAppS/syb-with-class"; md5 = "b42336907f7bfef8bea73bc36282d6ac"; };
sourceByName "syb_with_class"; # { url = "http://happs.org/HAppS/syb-with-class"; md5 = "b42336907f7bfef8bea73bc36282d6ac"; };
};
happs_data_darcs = { name="HAppS-Data-darcs"; p_deps=[ x.base x.mtl x.template_haskell x.syb_with_class_darcs x.haxml x.happs_util_darcs x.regex_compat x.bytestring x.pretty x.binary ];
src = sourceByName "happs_data"; # fetchdarcs { url = "http://happs.org/repos/HAppS-Data"; md5 = "10c505dd687e9dc999cb187090af9ba7"; };
};
happs_util_darcs = { name="HAppS-Util-darcs"; p_deps=[ x.base x.mtl x.hslogger x.template_haskell x.array x.bytestring x.old_time x.process x.directory ];
src = sourceByName "happs_util"; # fetchdarcs { url = "http://happs.org/repos/HAppS-Util"; md5 = "693cb79017e522031c307ee5e59fc250"; };
};
happs_state_darcs = { name="HAppS-State-darcs"; p_deps=[ x.base x.haxml
x.mtl x.network x.stm x.template_haskell x.hslogger
x.happs_util_darcs x.happs_data_darcs x.bytestring x.containers
x.random x.old_time x.old_locale x.unix x.directory x.binary x.hspread ];
src = sourceByName "happs_state";
#src = fetchdarcs { url = "http://happs.org/repos/HAppS-State";
# md5 = "956e5c293b60f4a98148fedc5fa38acc";
# };
};
happs_hsp_darcs = { name="happs-hsp-darcs"; src=sourceByName "happs_hsp"; p_deps=[x.base x.mtl x.bytestring x.plugins_darcs x.happs_server_darcs x.hsp_darcs x.containers x.rjson x.directory x.hinotify x.filepath];
pass = { patches = ./hsp-darcs.patch; };
};
happs_hsp_template_darcs = { name="happs-hsp-template-darcs"; src=sourceByName "happs_hsp_template"; p_deps=[ x.base x.bytestring x.filepath x.directory x.mtl x.containers x.network x.hinotify x.plugins_darcs x.rjson x.happs_server_darcs x.hsp_darcs]; };
hsp_darcs = { name="hsp-darcs"; src=sourceByName "hsp"; p_deps=[x.base x.mtl x.harp x.hsx x.hjscript_darcs];
pass = { inherit (x) hsx; postUnpack=''PATH=$PATH:$hsx/usr/local/bin''; };
};
#hsp_xml_darcs = { name="hsp-xml-darcs"; src=sourceByName "hsp_xml"; p_deps=[x.base x.haskell98 x.hsp_darcs x.hsx x.mtl x.harp x.haxml_darcs];
# pass = { inherit (x) hsx; postUnpack=''PATH=$PATH:$hsx/usr/local/bin''; };
# };
hspCgi_darcs = { name="hsp-cgi-darcs"; src=sourceByName "hspCgi"; p_deps=[x.base x.hsp_darcs x.network x.containers x.harp];
pass = { inherit (x) hsx; postUnpack=''PATH=$PATH:$hsx/usr/local/bin''; };
};
hjscript_darcs = { name="hjscript-darcs"; src=sourceByName "hjscript"; p_deps=[x.base x.hjavascript_darcs x.mtl x.hsx]; };
hjquery_darcs = { name="hjquery-darcs"; src=sourceByName "hjquery"; p_deps=[x.base x.hjscript_darcs ]; };
hjavascript_darcs = { name="darcs"; src=sourceByName "hjavascript"; p_deps=[x.base x.pretty]; };
#happs_plugins_darcs = { name="HAppS-plugins-darcs"; p_deps=[ x.base x.mtl x.hslogger x.happs_util_darcs x.happs_data_darcs x.happs_state_darcs x.containers ];
#src = bleedingEdgeRepos.sourceByName "happs_plugins";
#};
# there is no .cabal yet
#happs_smtp_darcs = { name="HAppS-smtp-darcs"; p_deps=[];
#src = fetchdarcs { url = "http://happs.org/repos/HAppS-smtp"; md5 = "5316917e271ea1ed8ad261080bcb47db"; };
#};
happs_ixset_darcs = { name="HAppS-IxSet-darcs"; p_deps=[ x.base x.mtl
x.hslogger x.happs_util_darcs x.happs_state_darcs x.happs_data_darcs
x.template_haskell x.syb_with_class_darcs x.containers ];
src = sourceByName "happs_ixset";
};
happs_server_darcs = { name="HAppS-Server-darcs"; p_deps=[x.haxml x.parsec3 x.mtl
x.network x.regex_compat x.hslogger x.happs_data_darcs
x.happs_util_darcs x.happs_state_darcs x.happs_ixset_darcs x.http_darcs
x.template_haskell x.xhtml x.html x.bytestring x.random
x.containers x.old_time x.old_locale x.directory x.unix];
#src = fetchdarcs { url = "http://happs.org/repos/HAppS-HTTP"; md5 = "e1bb17eb30a39d30b8c34dffbf80edc2"; };
src = sourceByName "happs_server";
};
# using darcs with minimal patch applied to support $GHC_PACKAGE_PATH
cabal_darcs =
{ name=cabal_darcs_name; p_deps = with ghc.core_libs; [base rts directory process pretty containers filepath];
src = sourceByName "cabal";
pass = { dummy = 2; };
};
} // (getConfig [ "ghc68CustomLibs" ] ( args: x : {} ) ) args x;
toDerivation = attrs : with attrs;
# result is { mtl = <deriv>;
addHasktagsTaggingInfo (ghcCabalDerivation {
inherit (attrs) name src;
useLocalPkgDB = attrs ? useLocalPkgDB;
propagatedBuildInputs = p_deps ++ (lib.optional (attrs.name != cabal_darcs_name) derivations.cabal_darcs );
srcDir = if attrs ? srcDir then attrs.srcDir else ".";
# add cabal, take deps either from this list or from ghc.core_libs
pass = if attrs ? pass then attrs.pass else {};
});
derivations = with lib; builtins.listToAttrs (lib.concatLists ( lib.mapRecordFlatten
( n : attrs : let d = (toDerivation attrs); in [ (nameValuePair n d) (nameValuePair attrs.name d) ] ) pkgs ) );
}.derivations

View File

@ -1,66 +0,0 @@
diff -rN -U3 old-pg_haskellnet/HaskellNet/Auth.hs new-pg_haskellnet/HaskellNet/Auth.hs
--- old-pg_haskellnet/HaskellNet/Auth.hs 2008-04-22 19:21:58.000000000 +0200
+++ new-pg_haskellnet/HaskellNet/Auth.hs 2008-04-22 19:21:58.000000000 +0200
@@ -21,6 +21,7 @@
import Data.List
import Data.Bits
import Data.Array
+import Data.Maybe
type UserName = String
type Password = String
@@ -41,7 +42,7 @@
b64Encode = map (toEnum.fromEnum) . B64.encode . map (toEnum.fromEnum)
b64Decode :: String -> String
-b64Decode = map (toEnum.fromEnum) . B64.decode . map (toEnum.fromEnum)
+b64Decode = map (toEnum.fromEnum) . fromJust . B64.decode . map (toEnum.fromEnum)
showOctet :: [Octet] -> String
showOctet = concat . map hexChars
diff -rN -U3 old-pg_haskellnet/haskellnet.cabal new-pg_haskellnet/haskellnet.cabal
--- old-pg_haskellnet/haskellnet.cabal 2008-04-22 19:21:58.000000000 +0200
+++ new-pg_haskellnet/haskellnet.cabal 2008-04-22 19:21:58.000000000 +0200
@@ -3,7 +3,7 @@
Author: Jun Mukai
License: BSD3
Category: Network
-Build-Depends: base, haskell98, network, Crypto, mtl, parsec, time, HaXml
+Build-Depends: base, haskell98, network, Crypto, mtl, parsec, time, HaXml, bytestring, pretty, array, dataenc, containers, old-locale, old-time
Synopsis: network related libraries such as HTTP, POP3, SMTP
Exposed-modules:
Text.IMAPParsers,
diff -rN -U3 old-pg_haskellnet/Text/Atom.hs new-pg_haskellnet/Text/Atom.hs
--- old-pg_haskellnet/Text/Atom.hs 2008-04-22 19:21:58.000000000 +0200
+++ new-pg_haskellnet/Text/Atom.hs 2008-04-22 19:21:58.000000000 +0200
@@ -38,7 +38,8 @@
import Data.Map (findWithDefault, insert, Map)
import qualified Data.Map as M
import Data.Monoid (Sum(..))
-import Data.Time.LocalTime (LocalTime(..), TimeOfDay(..), ZonedTime(..), TimeZone(..), formatTime, minutesToTimeZone, utc)
+import Data.Time.Format (formatTime)
+import Data.Time.LocalTime (LocalTime(..), TimeOfDay(..), ZonedTime(..), TimeZone(..), minutesToTimeZone, utc)
import System.Locale (defaultTimeLocale)
import Data.Time.Calendar
import Text.XML.HaXml hiding (version)
@@ -55,7 +56,7 @@
b64Encode :: String -> String
b64Encode = map e2e . B64.encode . map e2e
b64Decode :: String -> String
-b64Decode = map e2e . B64.decode . map e2e
+b64Decode = map e2e . fromJust . B64.decode . map e2e
atomEscaper = mkXmlEscaper [('<', "lt"), ('>', "gt"), ('&', "amp"), ('"', "quot")] (`elem` "<>\"")
xEscape :: [Content] -> [Content]
diff -rN -U3 old-pg_haskellnet/Text/RSS.hs new-pg_haskellnet/Text/RSS.hs
--- old-pg_haskellnet/Text/RSS.hs 2008-04-22 19:21:58.000000000 +0200
+++ new-pg_haskellnet/Text/RSS.hs 2008-04-22 19:21:58.000000000 +0200
@@ -26,6 +26,7 @@
import Data.Record
import Data.List (isPrefixOf)
import Data.Maybe
+import Data.Time.Format (formatTime)
import Data.Time.Calendar (fromGregorian)
import Data.Time.LocalTime
import System.Locale (defaultTimeLocale)

View File

@ -1,10 +0,0 @@
--- a/Setup.lhs 2008-03-12 08:47:46.000000000 +0100
+++ b/Setup.lhs 2008-03-12 08:46:39.000000000 +0100
@@ -2,7 +2,8 @@
\begin{code}
import Distribution.PackageDescription
+import Distribution.PackageDescription.Parse
import Distribution.Simple
import Distribution.Simple.LocalBuildInfo
import Distribution.Simple.Program

View File

@ -1,13 +0,0 @@
diff --git a/happs-hsp.cabal b/happs-hsp.cabal
index 9669b43..d41c7ac 100644
--- a/happs-hsp.cabal
+++ b/happs-hsp.cabal
@@ -1,7 +1,7 @@
Name: happs-hsp
Version: 0.1
Build-Type: Simple
-Build-Depends: base, mtl, bytestring, plugins, HAppS-Server, hsp
+Build-Depends: base, mtl, bytestring, plugins, HAppS-Server, hsp, containers, RJson, directory, hinotify, filepath
LICENSE: BSD3
Hs-Source-Dirs: src

View File

@ -1,73 +0,0 @@
--- b/Setup.lhs 2008-04-04 19:21:06.000000000 +0200
+++ a/Setup.lhs 2008-04-04 19:43:42.000000000 +0200
@@ -1,12 +1,14 @@
+-- packages: process, Cabal, directory, filepath
#!/usr/bin/runghc
\begin{code}
import Data.Maybe(fromMaybe)
import Distribution.PackageDescription
+import Distribution.Verbosity
+import Distribution.PackageDescription.Parse
import Distribution.Setup
import Distribution.Simple
import Distribution.Simple.LocalBuildInfo
-import Distribution.Simple.Utils(rawSystemVerbose)
import System.Info
import System.Exit
import System.Directory
@@ -15,19 +17,19 @@
import Control.Monad(when)
import Control.Exception(try)
+
main = defaultMainWithHooks defaultUserHooks{preConf=preConf, postConf=postConf}
where
preConf :: [String] -> ConfigFlags -> IO HookedBuildInfo
preConf args flags = do
try (removeFile "MySQL.buildinfo")
return emptyHookedBuildInfo
- postConf :: [String] -> ConfigFlags -> PackageDescription -> LocalBuildInfo -> IO ExitCode
+ postConf :: [String] -> ConfigFlags -> PackageDescription -> LocalBuildInfo -> IO ()
postConf args flags _ localbuildinfo = do
- mb_bi <- mysqlConfigBuildInfo (configVerbose flags)
+ mb_bi <- mysqlConfigBuildInfo (fromFlag (configVerbose flags))
let default_binfo | os == "mingw32" = emptyBuildInfo{extraLibs=["libmySQL"], ccOptions=["-Dmingw32_HOST_OS"]}
| otherwise = emptyBuildInfo{extraLibs=["mysqlclient"]}
writeHookedBuildInfo "MySQL.buildinfo" (Just (fromMaybe default_binfo mb_bi),[])
- return ExitSuccess
\end{code}
The following code is derived from Distribution.Simple.Configure
@@ -46,9 +48,9 @@
message ("Using " ++ name ++ ": " ++ path)
return (Just path)
-rawSystemGrabOutput :: Int -> FilePath -> [String] -> IO String
+rawSystemGrabOutput :: Verbosity -> FilePath -> [String] -> IO String
rawSystemGrabOutput verbose path args = do
- when (verbose > 0) $
+ when (verbose > silent ) $
putStrLn (path ++ concatMap (' ':) args)
(inp,out,err,pid) <- runInteractiveProcess path args Nothing Nothing
exitCode <- waitForProcess pid
@@ -67,7 +69,7 @@
Populate BuildInfo using pkg-config tool.
\begin{code}
-mysqlConfigBuildInfo :: Int -> IO (Maybe BuildInfo)
+mysqlConfigBuildInfo :: Verbosity -> IO (Maybe BuildInfo)
mysqlConfigBuildInfo verbose = do
mb_mysql_config_path <- findProgram "mysql_config" Nothing
case mb_mysql_config_path of
--- a/hsql-mysql.cabal 2008-04-07 17:36:32.000000000 +0200
+++ b/hsql-mysql.cabal 2008-04-07 17:34:17.000000000 +0200
@@ -5,7 +5,7 @@
category: Database
description: MySQL driver for HSQL.
exposed-modules: Database.HSQL.MySQL
-build-depends: base, hsql
+build-depends: base, hsql, old-time
extensions: ForeignFunctionInterface, CPP
cc-options: -IDatabase/HSQL
extra-source-files: Database/HSQL/HsMySQL.h

View File

@ -1,10 +0,0 @@
-- - a/hsx-0.4.4/src/HSX/Transform.hs
+++ b/hsx-0.4.4/src/HSX/Transform.hs
@@ -17,6 +17,7 @@ module HSX.Transform (
transform -- :: HsModule -> HsModule
) where
+import Language.Haskell.Meta.Exts.Syntax
import Language.Haskell.Exts.Syntax
import Language.Haskell.Exts.Build
import Data.List (union)

View File

@ -1,166 +0,0 @@
diff --git a/src/System/Plugins/Env.hs b/src/System/Plugins/Env.hs
index 64a840c..8bb0e8d 100644
--- a/src/System/Plugins/Env.hs
+++ b/src/System/Plugins/Env.hs
@@ -73,7 +73,9 @@ import System.IO.Error ( catch, ioError, isDoesNotExistError )
import Control.Concurrent.MVar ( MVar(), newMVar, withMVar )
-import Distribution.Package
+import Distribution.Package hiding (PackageName, packageName, depends)
+import Distribution.Text (display, simpleParse)
+
import Text.ParserCombinators.ReadP
import qualified Data.Map as M
@@ -284,9 +286,9 @@ addPkgConf f = do
union :: PkgEnvs -> [PackageConfig] -> PkgEnvs
union ls ps' =
let fm = emptyFM -- new FM for this package.conf
- in foldr (\p fm' -> if packageName_ p == "base" -- ghc doesn't supply a version with 'base'
+ in foldr (\p fm' -> if display (packageName_ p) == "base" -- ghc doesn't supply a version with 'base'
-- for some reason.
- then addToFM (addToFM fm' (packageName_ p) p) (packageName p) p
+ then addToFM (addToFM fm' (packageName p) p) (packageName p) p
else addToFM fm' (packageName p) p) fm ps' : ls
--
@@ -330,7 +332,7 @@ addStaticPkg pkg = modifyStaticPkgEnv env $ \set -> return $ S.insert pkg set
isStaticPkg :: PackageName -> IO Bool
isStaticPkg pkg
- = case readP_to_S parsePackageName pkg of
+ = case reads pkg of
((pkgName,_):_) -> withStaticPkgEnv env $ \set -> return $ S.member pkgName set
[] -> return False
@@ -513,4 +515,3 @@ addMerge a b z = modifyMerged env $ \fm -> return $ addToFM fm (a,b) z
--
(</>) :: FilePath -> FilePath -> FilePath
[] </> b = b
-a </> b = a ++ "/" ++ b
diff --git a/src/System/Plugins/PackageAPI.hs b/src/System/Plugins/PackageAPI.hs
index 7ac4201..ba8db23 100644
--- a/src/System/Plugins/PackageAPI.hs
+++ b/src/System/Plugins/PackageAPI.hs
@@ -40,7 +40,8 @@ module System.Plugins.PackageAPI (
#if CABAL == 1 || __GLASGOW_HASKELL__ >= 604
import Distribution.InstalledPackageInfo
-import Distribution.Package
+import Distribution.Package hiding (PackageName, packageName, depends)
+import Distribution.Text (display)
#else
import System.Plugins.Package
#endif
@@ -57,9 +58,9 @@ type PackageName = String
type PackageConfig = InstalledPackageInfo
-packageName = showPackageId . package
+packageName = display . package
packageName_ = pkgName . package
-packageDeps = (map showPackageId) . depends
+packageDeps = (map display) . depends
updImportDirs f pk@(InstalledPackageInfo { importDirs = idirs }) =
pk { importDirs = f idirs }
diff --git a/src/System/Plugins/ParsePkgConfCabal.hs b/src/System/Plugins/ParsePkgConfCabal.hs
index eba427e..2f7c13b 100644
--- a/src/System/Plugins/ParsePkgConfCabal.hs
+++ b/src/System/Plugins/ParsePkgConfCabal.hs
@@ -6,18 +6,27 @@ module System.Plugins.ParsePkgConfCabal (
) where
import Distribution.InstalledPackageInfo
-import Distribution.Package
+import Distribution.Package hiding (depends)
+import Distribution.ModuleName (components, ModuleName)
+import Distribution.Text (simpleParse)
+
import Distribution.Version
import Data.Char ( isSpace, isAlpha, isAlphaNum, isUpper, isDigit )
-import Data.List ( break )
+import Data.List ( break, intercalate )
+import Data.Maybe ( fromJust )
import Data.Array
+
#if __GLASGOW_HASKELL__ >= 503
import GHC.Exts
#else
import GlaExts
#endif
+moduleName :: [String] -> [ModuleName]
+moduleName = map (sParse "module name")
+sParse what = (\s -> maybe (error ("couldn't parse " ++ what ++ ", string: " ++ s)) id (simpleParse s))
+
-- parser produced by Happy Version 1.15
newtype HappyAbsSyn = HappyAbsSyn (() -> ())
@@ -269,8 +278,8 @@ happyReduction_13 happy_x_3
case happyOut16 happy_x_3 of { happy_var_3 ->
happyIn9
(\p -> case happy_var_1 of
- "exposedModules" -> p{exposedModules = happy_var_3}
- "hiddenModules" -> p{hiddenModules = happy_var_3}
+ "exposedModules" -> p{exposedModules = moduleName happy_var_3 }
+ "hiddenModules" -> p{hiddenModules = moduleName happy_var_3}
"importDirs" -> p{importDirs = happy_var_3}
"libraryDirs" -> p{libraryDirs = happy_var_3}
"hsLibraries" -> p{hsLibraries = happy_var_3}
@@ -316,7 +325,7 @@ happyReduction_15 (happy_x_10 `HappyStk`
= case happyOutTok happy_x_5 of { (ITstring happy_var_5) ->
case happyOut11 happy_x_9 of { happy_var_9 ->
happyIn10
- (PackageIdentifier{ pkgName = happy_var_5,
+ (PackageIdentifier{ pkgName = sParse "package name" happy_var_5,
pkgVersion = happy_var_9 }
) `HappyStk` happyRest}}
diff --git a/src/System/Plugins/ParsePkgConfCabal.y_in b/src/System/Plugins/ParsePkgConfCabal.y_in
index ddd4516..38bb068 100644
--- a/src/System/Plugins/ParsePkgConfCabal.y_in
+++ b/src/System/Plugins/ParsePkgConfCabal.y_in
@@ -36,12 +36,18 @@ module System.Plugins.ParsePkgConfCabal (
) where
import Distribution.InstalledPackageInfo
-import Distribution.Package
+import Distribution.Package hiding (depends)
import Distribution.Version
+import Distribution.ModuleName (components, ModuleName)
+import Distribution.Text (simpleParse)
import Data.Char ( isSpace, isAlpha, isAlphaNum, isUpper, isDigit )
-import Data.List ( break )
+import Data.List ( break, intercalate )
+import Data.Maybe ( fromJust )
+moduleName :: [String] -> [ModuleName]
+moduleName = map (sParse "module name")
+sParse what = (\s -> maybe (error ("couldn't parse " ++ what ++ ", string: " ++ s)) id (simpleParse s))
}
%token
@@ -102,8 +108,8 @@ field :: { PackageConfig -> PackageConfig }
| VARID '=' strlist
{\p -> case $1 of
- "exposedModules" -> p{exposedModules = $3}
- "hiddenModules" -> p{hiddenModules = $3}
+ "exposedModules" -> p{exposedModules = moduleName $3}
+ "hiddenModules" -> p{hiddenModules = moduleName $3}
"importDirs" -> p{importDirs = $3}
"libraryDirs" -> p{libraryDirs = $3}
"hsLibraries" -> p{hsLibraries = $3}
@@ -130,7 +136,7 @@ field :: { PackageConfig -> PackageConfig }
pkgid :: { PackageIdentifier }
: CONID '{' VARID '=' STRING ',' VARID '=' version '}'
- { PackageIdentifier{ pkgName = $5,
+ { PackageIdentifier{ pkgName = sParse "package name" $5,
pkgVersion = $9 } }
version :: { Version }

View File

@ -1,51 +0,0 @@
--- orig/Setup.hs 2008-03-11 16:35:54.000000000 +0100
+++ mod/Setup.hs 2008-03-11 16:45:16.000000000 +0100
@@ -1,3 +1,4 @@
+-- packages:HAppS-Server,mtl,HAppS-Data,HAppS-State,mtl,process,filepath,Cabal,directory
-- #!/usr/bin/env runhaskell
{-# OPTIONS -cpp #-}
@@ -8,12 +9,13 @@
import Control.Exception (bracket)
import Control.Monad (when)
import Data.List (isPrefixOf, unionBy)
+import Distribution.PackageDescription.Parse (writeHookedBuildInfo)
import Distribution.PackageDescription
( PackageDescription(..), Library(..), BuildInfo(..), HookedBuildInfo
- , emptyHookedBuildInfo, writeHookedBuildInfo, emptyBuildInfo, hasLibs
+ , emptyHookedBuildInfo, emptyBuildInfo, hasLibs
)
import Distribution.Simple.Setup -- ( --Flag, fromFlag, toFlag
- ( ConfigFlags(..), BuildFlags(..)
+ ( fromFlag, Flag(..), ConfigFlags(..), BuildFlags(..)
, InstallFlags(..), HaddockFlags(..)
, CopyFlags(..)
, RegisterFlags(..), emptyRegisterFlags
@@ -78,11 +80,16 @@
preConf args flags = do
try (removeFile "takusen.buildinfo")
return emptyHookedBuildInfo
+ conf libName path = (Just emptyBuildInfo {
+ extraLibs = [libName]
+ , extraLibDirs = [ path ++ "/lib" ]
+ , includeDirs = [ path ++ "/include" ]
+ })
postConf :: Args -> ConfigFlags -> PackageDescription -> LocalBuildInfo -> IO ()
postConf args flags _ localbuildinfo = do
let verbose = (configVerbose flags)
- sqliteBI <- configSqlite3 verbose
- pgBI <- configPG verbose
+ let sqliteBI = conf "sqlite3" "sqlite_path"
+ let pgBI = conf "pq" "pg_path"
oraBI <- configOracle verbose
odbcBI <- configOdbc verbose
let bis = [sqliteBI, pgBI, oraBI, odbcBI]
@@ -99,7 +106,7 @@
defaultInstallHook :: PackageDescription -> LocalBuildInfo
-> UserHooks -> InstallFlags -> IO ()
defaultInstallHook pkg_descr localbuildinfo _ (InstallFlags uInstFlag verbosity) = do
- install pkg_descr localbuildinfo (CopyFlags NoCopyDest verbosity)
+ install pkg_descr localbuildinfo (CopyFlags (Flag NoCopyDest) verbosity)
when (hasLibs pkg_descr) $
register pkg_descr localbuildinfo
emptyRegisterFlags{ regPackageDB=uInstFlag, regVerbose=verbosity }

View File

@ -1743,145 +1743,6 @@ let
inherit zlib boehmgc;
});
# This new ghc stuff is under heavy development and will change !
# ===============================================================
# usage: see ghcPkgUtil.sh
# depreceated -> use functions defined in builderDefs
ghcPkgUtil = runCommand "ghcPkgUtil-internal"
{ ghcPkgUtil = ../development/libraries/haskell/generic/ghcPkgUtil.sh; }
"mkdir -p $out/nix-support; cp $ghcPkgUtil \$out/nix-support/setup-hook;";
ghcsAndLibs =
assert builtins ? listToAttrs;
import ../development/compilers/ghcs {
ghcboot = ghc642Binary;
inherit fetchurl stdenv recurseIntoAttrs perl gnum4 gmp readline lib;
inherit ghcPkgUtil ctags autoconf automake getConfig;
inherit (ghc68executables) hasktags;
inherit (bleedingEdgeRepos) sourceByName;
# needed for install darcs ghc version
happy = ghc68executables.happy;
alex = ghc68executables.alex;
};
# creates ghc-X-wl wich adds the passed libraries to the env var GHC_PACKAGE_PATH
ghcWrapper = { ghcPackagedLibs ? false, ghc, libraries, name, suffix ? "ghc_wrapper_${ghc.name}" } :
import ../development/compilers/ghc/ghc-wrapper {
inherit ghcPackagedLibs ghc name suffix libraries ghcPkgUtil
lib
readline ncurses stdenv;
inherit (sourceAndTags) sourceWithTagsDerivation annotatedWithSourceAndTagInfo sourceWithTagsFromDerivation;
#inherit stdenv ghcPackagedLibs ghc name suffix libraries ghcPkgUtil
# annotatedDerivations lib sourceWithTagsDerivation annotatedWithSourceAndTagInfo;
installSourceAndTags = getConfig ["haskell" "ghcWrapper" "installSourceAndTags"] false;
};
# args must contain src name buildInputs
# classic expression style.. seems to work fine
# used now
#
# args must contain: src name buildInputs propagatedBuildInputs
# classic expression style.. seems to work fine
# used now
# srcDir contains source directory (containing the .cabal file)
# TODO: set --bindir=/usr/local or such (executables are installed to
# /usr/local/bin which is not added to path when building other packages
# hsp needs trhsx from hsx
# TODO add eval "$preBuild" phase
ghcCabalDerivation = args : with args;
let buildInputs = (if (args ? buildInputs) then args.buildInputs else [])
++ [ ghcPkgUtil ] ++ ( if args ? pass && args.pass ? buildInputs then args.pass.buildInputs else []);
configure = if (args ? useLocalPkgDB)
then "nix_ghc_pkg_tool join localDb\n" +
"\$CABAL_SETUP configure --package-db=localDb \$profiling \$cabalFlags"
else "\$CABAL_SETUP configure --by-env=\$PACKAGE_DB \$profiling \$cabalFlags";
in stdenv.mkDerivation ({
srcDir = if (args ? srcDir) then args.srcDir else ".";
inherit (args) name src propagatedBuildInputs;
phases = "unpackPhase patchPhase buildPhase";
profiling = if getConfig [ "ghc68" "profiling" ] false then "-p" else "";
cabalFlags = map lib.escapeShellArg
(getConfig [ "cabal" "flags" ] []
++ (if args ? cabalFlags then args.cabalFlags else []) );
# TODO remove echo line
buildPhase ="
createEmptyPackageDatabaseAndSetupHook
export GHC_PACKAGE_PATH
cd \$srcDir
ghc --make Setup.*hs -o setup
CABAL_SETUP=./setup
" + configure +"
\$CABAL_SETUP build
\$CABAL_SETUP copy --destdir=\$out
\$CABAL_SETUP register --gen-script
sed -e \"s=/usr/local/lib=\$out/usr/local/lib=g\" \\
-e \"s#bin/ghc-pkg --package-conf.*#bin/ghc-pkg --package-conf=\$PACKAGE_DB register -#\" \\
-i register.sh
./register.sh
rm \${PACKAGE_DB}.old
ensureDir \"\$out/nix-support\"
echo \"\$propagatedBuildInputs\" > \"\$out/nix-support/propagated-build-inputs\"
";
} // ( if args ? pass then (args.pass) else {} ) // { inherit buildInputs; } );
ghcCabalExecutableFun = (import ../development/compilers/ghc/ghc-wrapper/ghc-cabal-executable-fun.nix){
inherit ghc68extraLibs ghcsAndLibs stdenv lib;
# extra packages from this top level file:
inherit perl;
};
# this may change in the future
ghc68extraLibs = (import ../misc/ghc68extraLibs ) {
# lib like stuff
inherit (sourceAndTags) addHasktagsTaggingInfo;
inherit bleedingEdgeRepos fetchurl lib ghcCabalDerivation pkgconfig unzip zlib;
# used (non haskell) libraries (ffi etc)
inherit postgresql mysql sqlite gtkLibs gnome xlibs freetype getConfig libpng bzip2 pcre;
executables = ghc68executables;
wxGTK = wxGTK26;
};
# Executables compiled by this ghc68 - I'm too lazy to add them all as additional file in here
ghc68executables = import ../misc/ghc68executables {
inherit ghcCabalExecutableFun fetchurl lib bleedingEdgeRepos autoconf zlib getConfig;
#inherit X11;
inherit (xlibs) xmessage;
inherit pkgs; # passing pkgs to add the possibility for the user to add his own executables. pkgs is passed.
};
# the wrappers basically does one thing: It defines GHC_PACKAGE_PATH before calling ghc{i,-pkg}
# So you can have different wrappers with different library combinations
# So installing ghc libraries isn't done by nix-env -i package but by adding
# the lib to the libraries list below
# Doesn't create that much useless symlinks (you seldomly want to read the
# .hi and .o files, right?
ghcLibraryWrapper68 =
let ghc = ghcsAndLibs.ghc68.ghc; in
ghcWrapper rec {
ghcPackagedLibs = true;
name = "ghc${ghc.version}_wrapper";
suffix = "${ghc.version}wrapper";
libraries =
# core_libs distributed with this ghc version
(lib.flattenAttrs ghcsAndLibs.ghc68.core_libs)
# (map ( a : builtins.getAttr a ghcsAndLibs.ghc68.core_libs ) [ "cabal" "mtl" "base" ]
# some extra libs
++ (lib.flattenAttrs (ghc68extraLibs ghcsAndLibs.ghc68) );
# ++ map ( a : builtins.getAttr a (ghc68extraLibs ghcsAndLibs.ghc68 ) ) [ "mtl" "parsec" ... ]
inherit ghc;
};
#ghc = haskellPackages.ghc;
ghc642Binary = lowPrio (import ../development/compilers/ghc/6.4.2-binary.nix {