packages feed

hake-0.8: hake.cabal

Name:		hake
Version:	0.8
License:	GPL
License-file:	LICENSE
Author:		Yoshikuni Jujo
Maintainer:	Yoshikuni Jujo <PAF01143@nifty.ne.jp>
Category:	Development
Synopsis:	make tool. ruby : rake = haskell : hake

Description:	Like ruby's rake, hake have Hakefile which is Haskell source.
		.
		And Hakefile is like rake's Rakefile, and make's Makefile.
		.
		Hakefile is just Haskell source code,
		then you can use all Haskell features.
		.
		> import Development.Hake
		> hake_rules = [
		>
		>  dflt	[ "greeting" ]
		>  ,
		>  file	( [ "greeting", "greeting.log" ], [ "hello.o", "good-bye.o" ] ,
		> 		[ "linker -o greeting hello.o good-bye.o" ] )
		>  ,
		>  rule	( ".o", ".sfx1",
		> 		\t s -> [ "compiler1 " ++ s ++ " -o " ++ t ] )
		>  ,
		>  rule	( ".o", ".sfx2",
		> 		\t s -> [ "compiler2 " ++ s ++ " -o " ++ t ] )
		>  ,
		>  task	( "clean" , [ "rm -f *.o greeting greeting.log" ] )
		>  ,
		>  mkfl	( "script.sh", [ "#!/bin/sh", "echo This is script", "echo made by Hakefile" ] )
		>  ,
		>  ruleSS ( "", ".o", \t s -> [ (".c",  [ "gcc " ++ s ++ " -o " ++ t ] ) ,
		>                               (".cc", [ "g++ " ++ s ++ " -o " ++ t ] ) ] )
		>  ,
		>  rule   ( ".o", ".c",  \_ s -> [ "gcc -c " ++ s ] )
		>  ,
		>  rule   ( ".o", ".cc", \_ s -> [ "g++ -c " ++ s ] )
		>  ,
		>  base   ( [ (=="foo") ], const [ "foo.gen", "Hakefile" ], \t [s] -> [ \_ -> do
		>               gen <- readFile s
		>               writeFile t $ unlines $
		>                 [ "#!/bin/sh", "echo This is script" ] ++ lines gen
		>               return ExitSuccess ] )
		>
		>  ]
		>
		> main = hake hake_rules

Stability:	experimental
Homepage:	http://homepage3.nifty.com/salamander/second/projects/hake/index.xhtml
Package-Url:	http://code.haskell.org/hake/
Cabal-Version:	>= 1.2
Build-type:	Simple
Tested-With:	GHC
Data-Files:
Extra-Source-Files:
Extra-Tmp-Files:

Library
  GHC-Options:		-Wall
--  CPP-Options:		-DDEBUG
  Build-Depends:	base, old-time, mtl, filepath
  Exposed-Modules:	Development.Hake
  Other-Modules:	Development.Hake.HiddenTools

Executable hake
  GHC-Options:		-Wall
--  CPP-Options:		-DDEBUG
  Build-Depends:	directory, process, yjtools >= 0.6, regexpr >= 0.3
  Other-Modules:	Development.Hake.HiddenTools
  Main-Is:		Main.hs