aboutsummaryrefslogtreecommitdiffstats
path: root/devel/hs-fgl
diff options
context:
space:
mode:
authorpgj <pgj@FreeBSD.org>2010-05-13 00:33:59 +0800
committerpgj <pgj@FreeBSD.org>2010-05-13 00:33:59 +0800
commitf203c3895196ffa8b69517527e8c488cc49ada57 (patch)
treed7be6abb9940698d6dc43b1587948a03039a23b5 /devel/hs-fgl
parent965f4ecbcd1c9f6296e907af59901feeedfdc42f (diff)
downloadfreebsd-ports-gnome-f203c3895196ffa8b69517527e8c488cc49ada57.tar.gz
freebsd-ports-gnome-f203c3895196ffa8b69517527e8c488cc49ada57.tar.zst
freebsd-ports-gnome-f203c3895196ffa8b69517527e8c488cc49ada57.zip
Introduce a new (and hopefully better) ports infrastructure for Haskell Cabal
ports which makes possible the direct translation of Cabal package descriptions to FreeBSD ports. It promises both easier addition and maintenance for Cabal-based ports.
Diffstat (limited to 'devel/hs-fgl')
-rw-r--r--devel/hs-fgl/Makefile70
-rw-r--r--devel/hs-fgl/pkg-plist84
2 files changed, 47 insertions, 107 deletions
diff --git a/devel/hs-fgl/Makefile b/devel/hs-fgl/Makefile
index bda8320c9114..c027c6235a8b 100644
--- a/devel/hs-fgl/Makefile
+++ b/devel/hs-fgl/Makefile
@@ -8,75 +8,15 @@
PORTNAME= fgl
PORTVERSION= 5.4.2.2
CATEGORIES= devel haskell
-MASTER_SITES= http://hackage.haskell.org/packages/archive/${PORTNAME}/${PORTVERSION}/
-PKGNAMEPREFIX= hs-
MAINTAINER= jacula@gmail.com
COMMENT= Martin Erwig Functional Graph Library
-BUILD_DEPENDS+= ghc:${PORTSDIR}/lang/ghc
-RUN_DEPENDS+= ghc:${PORTSDIR}/lang/ghc
+CABAL_SETUP= Setup.hs
-GHC_VERSION= 6.10.4
-FGL_VERSION= ${PORTVERSION}
-
-GHC_CMD= ${LOCALBASE}/bin/ghc
-SETUP_CMD= ./setup
-
-DATADIR= ${PREFIX}/share/${DISTNAME}
-PORTDATA= *
-
-DOCSDIR= ${PREFIX}/share/doc/${DISTNAME}
-FGL_LIBDIR_REL= lib/${DISTNAME}
-
-PLIST_SUB= GHC_VERSION=${GHC_VERSION} \
- FGL_VERSION=${FGL_VERSION} \
- FGL_LIBDIR_REL=${FGL_LIBDIR_REL}
-
-.if defined(NOPORTDOCS)
-PLIST_SUB+= NOPORTDOCS=""
-.else
-PLIST_SUB+= NOPORTDOCS="@comment "
-.endif
-
-.if !defined(NOPORTDOCS)
-
-PORT_HADDOCK!= (cd ${.CURDIR}/../../lang/ghc && ${MAKE} -V PORT_HADDOCK)
-.if !empty(PORT_HADDOCK:M?0)
-BUILD_DEPENDS+= haddock:${PORTSDIR}/devel/hs-haddock
-.endif
-BUILD_DEPENDS+= HsColour:${PORTSDIR}/print/hs-hscolour
-
-HSCOLOUR_VERSION= 1.15
-HSCOLOUR_DATADIR= ${PREFIX}/share/hscolour-${HSCOLOUR_VERSION}
-
-PORTDOCS= *
-.endif
-
-.SILENT:
-
-do-configure:
- cd ${WRKSRC} && ${GHC_CMD} --make Setup.hs -o setup -package Cabal \
- && ${SETUP_CMD} configure --haddock-options=-w --prefix=${PREFIX}
-
-do-build:
- cd ${WRKSRC} && ${SETUP_CMD} build \
- && ${SETUP_CMD} register --gen-script
-
-.if !defined(NOPORTDOCS)
- cd ${WRKSRC} && ${SETUP_CMD} haddock --hyperlink-source \
- --hscolour-css=${HSCOLOUR_DATADIR}/hscolour.css
-.endif
-
-do-install:
- cd ${WRKSRC} && ${SETUP_CMD} install \
- && ${INSTALL_SCRIPT} register.sh ${PREFIX}/${FGL_LIBDIR_REL}/register.sh
-.if !defined(NOPORTDATA)
- @${MKDIR} ${DATADIR} && ${INSTALL_DATA} ${WRKSRC}/doc/CHANGES ${DATADIR} \
- && ${INSTALL_DATA} ${WRKSRC}/doc/README ${DATADIR}
-.endif
-
-post-install:
- ${RM} -f ${PREFIX}/lib/ghc-${GHC_VERSION}/package.conf.old
+PORTDATA= *
+INSTALL_PORTDATA= ${INSTALL_DATA} ${WRKSRC}/doc/CHANGES ${DATADIR} \
+ && ${INSTALL_DATA} ${WRKSRC}/doc/README ${DATADIR}
+.include "${.CURDIR}/../../lang/ghc/bsd.cabal.mk"
.include <bsd.port.mk>
diff --git a/devel/hs-fgl/pkg-plist b/devel/hs-fgl/pkg-plist
index 7715fa9965cd..94de4c073461 100644
--- a/devel/hs-fgl/pkg-plist
+++ b/devel/hs-fgl/pkg-plist
@@ -1,47 +1,47 @@
@comment $FreeBSD$
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Basic.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Example.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Graph.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Graphviz.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/FiniteMap.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/Heap.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/Queue.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/RootPath.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/Thread.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Monad.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Monad/IOArray.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/NodeMap.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/PatriciaTree.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/ArtPoint.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/BCC.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/BFS.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/DFS.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/Dominators.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/GVD.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/Indep.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/MST.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/MaxFlow.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/MaxFlow2.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/Monad.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/SP.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/TransClos.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Tree.hi
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/HSfgl-%%FGL_VERSION%%.o
-%%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/libHSfgl-%%FGL_VERSION%%.a
-%%FGL_LIBDIR_REL%%/register.sh
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Basic.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Example.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Graph.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Graphviz.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/FiniteMap.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/Heap.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/Queue.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/RootPath.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal/Thread.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Monad.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Monad/IOArray.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/NodeMap.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/PatriciaTree.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/ArtPoint.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/BCC.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/BFS.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/DFS.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/Dominators.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/GVD.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/Indep.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/MST.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/MaxFlow.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/MaxFlow2.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/Monad.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/SP.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query/TransClos.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Tree.hi
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/HS%%PORTNAME%%-%%PORTVERSION%%.o
+%%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/libHS%%PORTNAME%%-%%PORTVERSION%%.a
+%%LIBDIR_REL%%/register.sh
%%NOPORTDOCS%%%%DOCSDIR%%/LICENSE
%%NOPORTDOCS%%@dirrmtry %%DOCSDIR%%
-@dirrm %%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query
-@dirrm %%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Monad
-@dirrm %%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal
-@dirrm %%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive
-@dirrm %%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph
-@dirrm %%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data
-@dirrm %%FGL_LIBDIR_REL%%/ghc-%%GHC_VERSION%%
-@dirrm %%FGL_LIBDIR_REL%%
-@exec /bin/sh %D/%%FGL_LIBDIR_REL%%/register.sh
+@dirrm %%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Query
+@dirrm %%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Monad
+@dirrm %%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive/Internal
+@dirrm %%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph/Inductive
+@dirrm %%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data/Graph
+@dirrm %%LIBDIR_REL%%/ghc-%%GHC_VERSION%%/Data
+@dirrm %%LIBDIR_REL%%/ghc-%%GHC_VERSION%%
+@dirrm %%LIBDIR_REL%%
+@exec /bin/sh %D/%%LIBDIR_REL%%/register.sh
@exec /bin/rm -f %D/lib/ghc-%%GHC_VERSION%%/package.conf.old
-@unexec %D/bin/ghc-pkg unregister fgl
+@unexec %D/bin/ghc-pkg unregister %%PORTNAME%%-%%PORTVERSION%%
@unexec /bin/rm -f %D/lib/ghc-%%GHC_VERSION%%/package.conf.old