[35914] trunk/dports/lang/nhc98

mcalhoun at macports.org mcalhoun at macports.org
Wed Apr 9 10:33:43 PDT 2008


Revision: 35914
          http://trac.macosforge.org/projects/macports/changeset/35914
Author:   mcalhoun at macports.org
Date:     2008-04-09 10:33:41 -0700 (Wed, 09 Apr 2008)

Log Message:
-----------
nhc98: Version update.

Modified Paths:
--------------
    trunk/dports/lang/nhc98/Portfile

Added Paths:
-----------
    trunk/dports/lang/nhc98/files/patch-Makefile.nhc98.diff

Removed Paths:
-------------
    trunk/dports/lang/nhc98/files/patch-cLowUnboxedArray.c
    trunk/dports/lang/nhc98/files/patch-confhc
    trunk/dports/lang/nhc98/files/patch-config-errno.c
    trunk/dports/lang/nhc98/files/patch-errnogen.c

Modified: trunk/dports/lang/nhc98/Portfile
===================================================================
--- trunk/dports/lang/nhc98/Portfile	2008-04-09 17:26:14 UTC (rev 35913)
+++ trunk/dports/lang/nhc98/Portfile	2008-04-09 17:33:41 UTC (rev 35914)
@@ -1,72 +1,59 @@
+# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4
 # $Id$
 
 PortSystem 1.0
+
 name		nhc98
-version		1.18
-revision	4
+version		1.20
 categories	lang
 maintainers	nomaintainer
 platforms	darwin
 description	The nhc98 Haskell Compiler
-long_description	\
-		nhc98 is a small, easy to install, standards-compliant	\
-		compiler for Haskell 98, the lazy functional		\
-		programming language.  It is very portable, and aims to	\
-		produce small executables that run in small amounts of	\
-		memory. It produces medium-fast code, and compilation	\
-		is itself quite fast. It also comes with extensive tool	\
-		support for automatic compilation, foreign language	\
-		interfacing, heap and time profiling, tracing, and	\
-		debugging.  (Some of its advanced kinds of heap		\
-		profiles are not found in any other Haskell compiler.)  
+long_description \
+    nhc98 is a small, easy to install, standards-compliant \
+    compiler for Haskell 98, the lazy functional \
+    programming language. It is very portable, and aims to	\
+    produce small executables that run in small amounts of \
+    memory. It produces medium-fast code, and compilation \
+    is itself quite fast. It also comes with extensive tool	\
+    support for automatic compilation, foreign language	\
+    interfacing, heap and time profiling, tracing, and \
+    debugging. Some of its advanced kinds of heap \
+    profiles are not found in any other Haskell compiler.
 
-homepage	http://www.haskell.org/${name}/
-master_sites	http://www.cs.york.ac.uk/fp/${name}/		\
-		ftp://ftp.cs.york.ac.uk/pub/haskell/${name}/
+homepage http://www.haskell.org/${name}
+master_sites \
+    http://www.cs.york.ac.uk/fp/${name} \
+    ftp://ftp.cs.york.ac.uk/pub/haskell/${name}
 
-distfiles	${name}src-${version}${extract.suffix}	\
-		${name}-${version}-library-interfaces${extract.suffix}
+distfiles ${name}src-${version}${extract.suffix}
 
-checksums	${name}src-${version}${extract.suffix}                 md5 f38b74481ec01a066cc9314b7bd18c90	\
-		${name}-${version}-library-interfaces${extract.suffix} md5 f99f413a85462fe719ea634fd319d94f
+checksums \
+    md5 55c102408da8085aa56984af4151eb9c \
+    sha1 5bcfa0e8cc192afc5a54aab0bd4c1812dafa7b45 \
+    rmd160 011e723a956f2fb9029357d00ddb705c350309af
 
-patchfiles	patch-cLowUnboxedArray.c	\
-		patch-confhc			\
-		patch-config-errno.c		\
-		patch-errnogen.c
+depends_lib port:readline port:ncurses
 
-configure.args	--mandir=${prefix}/share/man/man1	\
-		--buildwith=gcc
+configure.args \
+    --buildwith=gcc \
+    +docs \
+    --docdir=${prefix}/share/doc/${name} \
+    --mandir=${prefix}/share/man/man1 \
+    --heap=8M
 
-build		{	if {${os.platform} == "darwin" && ${os.arch} == "i386"} {
-				ui_error "nhc98 is not supported on OS X i386 yet"
-				return 1
-			}
-			
-			system "cd ${worksrcpath} && ulimit -s unlimited && make"
-		}
+patchfiles patch-Makefile.nhc98.diff
 
-post-destroot	{ file delete -force ${destroot}${prefix}/lib/hmake
+post-patch {
+    reinplace "s|-\$(CC)|-\${BUILDCOMP}|g" ${worksrcpath}/Makefile
+}
 
-		  file delete ${destroot}${prefix}/bin/cpphs
-		  file delete ${destroot}${prefix}/bin/hi
-		  file delete ${destroot}${prefix}/bin/hmake
-		  file delete ${destroot}${prefix}/bin/hmake-config
-
-		  file rename ${destroot}${prefix}/bin/harch ${destroot}${prefix}/bin/harch-${name}
-
-#
-# NB - The greencard-nhc98 and hp2graph scripts are hardlinks to
-#      the same file. Change one, all are changed.
-#
-		  reinplace "s|${prefix}/bin/harch|${prefix}/bin/harch\-nhc98|"     ${destroot}${prefix}/bin/greencard\-nhc98
-		  reinplace "s|\{NHC98BINDIR\}/harch|\{NHC98BINDIR\}/harch\-nhc98|" ${destroot}${prefix}/bin/hood
-		  reinplace "s|NHC98BINDIR/harch|NHC98BINDIR/harch\-nhc98|"         ${destroot}${prefix}/bin/nhc98
-
-		  file delete ${destroot}${prefix}/share/man/man1/harch.1
-		  file delete ${destroot}${prefix}/share/man/man1/hi.1
-		  file delete ${destroot}${prefix}/share/man/man1/hmake.1
+post-destroot {
+    set rexp1 "'s|${worksrcpath}/script|${prefix}/bin|g'"
+    set rexp2 "'s|${worksrcpath}/include|${prefix}/include/nhc98|g'"
+    set rfile "${destroot}${prefix}/lib/hmake/`${worksrcpath}/script/harch`/hmakerc"
+    system "sed -i '' -e ${rexp1} -e ${rexp2} ${rfile}"
 }
 
-post-activate	{ system "find ${prefix}/lib/${name} -name \"*.a\" -exec ranlib -s {} \\;"
-		}
+livecheck.check  regex
+livecheck.regex  "Version (.*) released"

Added: trunk/dports/lang/nhc98/files/patch-Makefile.nhc98.diff
===================================================================
--- trunk/dports/lang/nhc98/files/patch-Makefile.nhc98.diff	                        (rev 0)
+++ trunk/dports/lang/nhc98/files/patch-Makefile.nhc98.diff	2008-04-09 17:33:41 UTC (rev 35914)
@@ -0,0 +1,10 @@
+--- src/hsc2hs/Makefile.nhc98.orig	2008-03-17 09:50:40.000000000 -0700
++++ src/hsc2hs/Makefile.nhc98	2008-03-17 09:51:43.000000000 -0700
+@@ -9,6 +9,7 @@
+ 	 ../libraries/process/System/Cmd.$C \
+ 	 ../libraries/directory/System/Directory.$C \
+ 	 ../libraries/base/Control/Monad.$C \
++	 ../libraries/base/Control/Exception.$C \
+ 	 ../libraries/base/Foreign/C/String.$C \
+ 	 ../libraries/base/Foreign/Marshal/Alloc.$C \
+ 	 ../libraries/base/Foreign/Marshal/Array.$C \

Deleted: trunk/dports/lang/nhc98/files/patch-cLowUnboxedArray.c
===================================================================
--- trunk/dports/lang/nhc98/files/patch-cLowUnboxedArray.c	2008-04-09 17:26:14 UTC (rev 35913)
+++ trunk/dports/lang/nhc98/files/patch-cLowUnboxedArray.c	2008-04-09 17:33:41 UTC (rev 35914)
@@ -1,9 +0,0 @@
---- src/prelude/BinArray/cLowUnboxedArray.c.sav	2005-09-18 21:43:09.000000000 -0400
-+++ src/prelude/BinArray/cLowUnboxedArray.c	2005-09-18 21:43:31.000000000 -0400
-@@ -1,5 +1,5 @@
--#include "cLowUnboxedArray.h"
- #include <stdlib.h>
-+#include "cLowUnboxedArray.h"
- 
- void finaliseUBA (UBA uba) {
-   free(uba->block);

Deleted: trunk/dports/lang/nhc98/files/patch-confhc
===================================================================
--- trunk/dports/lang/nhc98/files/patch-confhc	2008-04-09 17:26:14 UTC (rev 35913)
+++ trunk/dports/lang/nhc98/files/patch-confhc	2008-04-09 17:33:41 UTC (rev 35914)
@@ -1,11 +0,0 @@
---- script/confhc.sav	2005-09-19 18:36:34.000000000 -0400
-+++ script/confhc	2005-09-19 18:37:47.000000000 -0400
-@@ -78,7 +78,7 @@
- ghcsym () {
-   echo __GLASGOW_HASKELL__ >ghcsym.hs;
-   $1 -E -cpp -optP-P ghcsym.hs -o ghcsym.out;
--  grep -v '^#' ghcsym.out > $2;
-+  grep -E '^[0-9]+$' ghcsym.out > $2;
-   rm -f ghcsym.hs ghcsym.out;
- }
- echo -n "  Looking for ghc...   "

Deleted: trunk/dports/lang/nhc98/files/patch-config-errno.c
===================================================================
--- trunk/dports/lang/nhc98/files/patch-config-errno.c	2008-04-09 17:26:14 UTC (rev 35913)
+++ trunk/dports/lang/nhc98/files/patch-config-errno.c	2008-04-09 17:33:41 UTC (rev 35914)
@@ -1,8 +0,0 @@
---- script/config-errno.c.sav	2005-09-18 21:52:17.000000000 -0400
-+++ script/config-errno.c	2005-09-18 21:52:50.000000000 -0400
-@@ -1,3 +1,5 @@
-+#include <stdlib.h>
-+#include <stdio.h>
- #include <errno.h>
- 
- #ifdef E2BIG

Deleted: trunk/dports/lang/nhc98/files/patch-errnogen.c
===================================================================
--- trunk/dports/lang/nhc98/files/patch-errnogen.c	2008-04-09 17:26:14 UTC (rev 35913)
+++ trunk/dports/lang/nhc98/files/patch-errnogen.c	2008-04-09 17:33:41 UTC (rev 35914)
@@ -1,8 +0,0 @@
---- script/errnogen.c.sav	2005-09-18 21:52:25.000000000 -0400
-+++ script/errnogen.c	2005-09-18 21:53:27.000000000 -0400
-@@ -1,3 +1,5 @@
-+#include <stdlib.h>
-+#include <stdio.h>
- #include <errno.h>
- main() {
-   int i, j=0, max=0, noncontig=0, dup=0;

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20080409/01f3640b/attachment.html


More information about the macports-changes mailing list