pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc
Module Name: pkgsrc
Committed By: rillig
Date: Sun Jun 21 22:21:03 UTC 2020
Modified Files:
pkgsrc/devel/hs-bytestring-builder: PLIST
pkgsrc/devel/hs-fail: PLIST
pkgsrc/math/hs-nats: PLIST
pkgsrc/mk: haskell.mk
pkgsrc/textproc/hs-cgrep: PLIST
Log Message:
mk/haskell.mk: fix PLIST generation for Haskell packages
The package textproc/hs-cgrep does not install a Haskell library. This
was unexpected to mk/haskell.mk, which generated an obviously wrong PLIST
file for that package, and for 3 other packages.
Noticed by wiz.
To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 pkgsrc/devel/hs-bytestring-builder/PLIST
cvs rdiff -u -r1.1 -r1.2 pkgsrc/devel/hs-fail/PLIST
cvs rdiff -u -r1.3 -r1.4 pkgsrc/math/hs-nats/PLIST
cvs rdiff -u -r1.20 -r1.21 pkgsrc/mk/haskell.mk
cvs rdiff -u -r1.3 -r1.4 pkgsrc/textproc/hs-cgrep/PLIST
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/devel/hs-bytestring-builder/PLIST
diff -u pkgsrc/devel/hs-bytestring-builder/PLIST:1.1 pkgsrc/devel/hs-bytestring-builder/PLIST:1.2
--- pkgsrc/devel/hs-bytestring-builder/PLIST:1.1 Mon May 11 17:52:00 2020
+++ pkgsrc/devel/hs-bytestring-builder/PLIST Sun Jun 21 22:21:02 2020
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.1 2020/05/11 17:52:00 rillig Exp $
-${HS_DOCS}${HS_IMPL}${HS_INTF}/package-description
-${HS_DOCS}${HS_IMPL}${HS_INTF}/package-id
-${HS_DOCS}${HS_IMPL}share/doc/x86_64-netbsd-ghc-8.8.1/bytestring-builder-${PKGVERSION}/LICENSE
+@comment $NetBSD: PLIST,v 1.2 2020/06/21 22:21:02 rillig Exp $
+${HS_INTF}/package-description
+${HS_INTF}/package-id
+share/doc/x86_64-netbsd-ghc-8.8.1/bytestring-builder-${PKGVERSION}/LICENSE
Index: pkgsrc/devel/hs-fail/PLIST
diff -u pkgsrc/devel/hs-fail/PLIST:1.1 pkgsrc/devel/hs-fail/PLIST:1.2
--- pkgsrc/devel/hs-fail/PLIST:1.1 Mon May 11 17:52:03 2020
+++ pkgsrc/devel/hs-fail/PLIST Sun Jun 21 22:21:03 2020
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.1 2020/05/11 17:52:03 rillig Exp $
-${HS_DOCS}${HS_IMPL}${HS_INTF}/package-description
-${HS_DOCS}${HS_IMPL}${HS_INTF}/package-id
-${HS_DOCS}${HS_IMPL}share/doc/x86_64-netbsd-ghc-8.8.1/fail-${PKGVERSION}/LICENSE
+@comment $NetBSD: PLIST,v 1.2 2020/06/21 22:21:03 rillig Exp $
+${HS_INTF}/package-description
+${HS_INTF}/package-id
+share/doc/x86_64-netbsd-ghc-8.8.1/fail-${PKGVERSION}/LICENSE
Index: pkgsrc/math/hs-nats/PLIST
diff -u pkgsrc/math/hs-nats/PLIST:1.3 pkgsrc/math/hs-nats/PLIST:1.4
--- pkgsrc/math/hs-nats/PLIST:1.3 Wed May 13 04:53:16 2020
+++ pkgsrc/math/hs-nats/PLIST Sun Jun 21 22:21:03 2020
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.3 2020/05/13 04:53:16 rillig Exp $
-${HS_DOCS}${HS_IMPL}${HS_INTF}/package-description
-${HS_DOCS}${HS_IMPL}${HS_INTF}/package-id
-${HS_DOCS}${HS_IMPL}share/doc/x86_64-netbsd-ghc-8.8.1/nats-${PKGVERSION}/LICENSE
+@comment $NetBSD: PLIST,v 1.4 2020/06/21 22:21:03 rillig Exp $
+${HS_INTF}/package-description
+${HS_INTF}/package-id
+share/doc/x86_64-netbsd-ghc-8.8.1/nats-${PKGVERSION}/LICENSE
Index: pkgsrc/mk/haskell.mk
diff -u pkgsrc/mk/haskell.mk:1.20 pkgsrc/mk/haskell.mk:1.21
--- pkgsrc/mk/haskell.mk:1.20 Sun May 10 17:46:59 2020
+++ pkgsrc/mk/haskell.mk Sun Jun 21 22:21:02 2020
@@ -1,4 +1,4 @@
-# $NetBSD: haskell.mk,v 1.20 2020/05/10 17:46:59 rillig Exp $
+# $NetBSD: haskell.mk,v 1.21 2020/06/21 22:21:02 rillig Exp $
#
# This Makefile fragment handles Haskell Cabal packages.
# See: http://www.haskell.org/cabal/
@@ -105,7 +105,14 @@ BUILD_DEFS+= HASKELL_ENABLE_HADDOCK_DOCU
# Declarations for ../../mk/misc/show.mk
-_VARGROUPS+= haskell
+_VARGROUPS+= haskell
+_USER_VARS.haskell= \
+ HASKELL_ENABLE_SHARED_LIBRARY \
+ HASKELL_ENABLE_LIBRARY_PROFILING \
+ HASKELL_ENABLE_HADDOCK_DOCUMENTATION
+_SYS_VARS.haskell= \
+ PKGNAME DISTNAME MASTER_SITES MASTER_SITE_HASKELL_HACKAGE \
+ HOMEPAGE UNLIMIT_RESOURCES PREFIX
_DEF_VARS.haskell= \
HASKELL_OPTIMIZATION_LEVEL \
HASKELL_PKG_NAME \
@@ -121,10 +128,8 @@ _DEF_VARS.haskell= \
_HASKELL_PKG_DESCR_FILE \
_HASKELL_PKG_ID_FILE \
_HASKELL_VERSION
-_USER_VARS.haskell= \
- HASKELL_ENABLE_SHARED_LIBRARY \
- HASKELL_ENABLE_LIBRARY_PROFILING \
- HASKELL_ENABLE_HADDOCK_DOCUMENTATION
+_IGN_VARS.haskell= \
+ USE_TOOLS _*
# PKGNAME is usually named after DISTNAME.
PKGNAME?= hs-${DISTNAME}
@@ -211,16 +216,30 @@ CONFIGURE_ARGS+= --with-haddock=${BUILDL
# Optimization
CONFIGURE_ARGS+= -O${HASKELL_OPTIMIZATION_LEVEL}
+.if !exists(${PKGDIR}/PLIST)
+_HS_PLIST_STATUS= missing
+.elif ${${GREP} HS_INTF ${PKGDIR}/PLIST || ${TRUE}:L:sh}
+_HS_PLIST_STATUS= lib-ok
+.elif !${${GREP} "/package-id" ${PKGDIR}/PLIST || ${TRUE}:L:sh}
+_HS_PLIST_STATUS= plain
+.else
+_HS_PLIST_STATUS= outdated
+.endif
+
# Starting from GHC 7.10 (or 7.8?), packages are installed in directories
# with a hashed name, which makes it a bit more complicated to generate
# the PLIST.
#
+.if ${_HS_PLIST_STATUS} == lib-ok || ${_HS_PLIST_STATUS} == missing
+
_HASKELL_PL_INTF= ${_HASKELL_PKG_ID_FILE:H:S,^${PREFIX}/,,}
-_HASKELL_PL_IMPL_AWK= prev == "import-dirs:" { print $$1; exit } { prev = $$0 }
+_HASKELL_PL_IMPL_AWK= prev == "import-dirs:" { dir = $$1; exit }
+_HASKELL_PL_IMPL_AWK+= { prev = $$0 }
+_HASKELL_PL_IMPL_AWK+= END { print(dir ? dir : "never_match_this") }
_HASKELL_PL_IMPL_CMD= ${AWK} '${_HASKELL_PL_IMPL_AWK}' ${DESTDIR}${_HASKELL_PKG_DESCR_FILE}
_HASKELL_PL_IMPL= ${_HASKELL_PL_IMPL_CMD:sh:S,^${PREFIX}/,,}
_HASKELL_PL_DOCS= ${_HASKELL_PL_IMPL:S,^lib,share/doc,:C,-[A-Za-z0-9]*$,,}
-_HASKELL_PL_PLATFORM= ${_HASKELL_PL_IMPL:H:T}
+_HASKELL_PL_PLATFORM= ${_HASKELL_PL_IMPL:H:T:S,^.$,never_match_this,}
_HASKELL_PL_PKGID_CMD= ${CAT} ${DESTDIR}${_HASKELL_PKG_ID_FILE}
_HASKELL_PL_PKGID= ${_HASKELL_PL_PKGID_CMD:sh}
_HASKELL_PL_VER= ${_HASKELL_VERSION:S,-,,}
@@ -238,23 +257,14 @@ PRINT_PLIST_AWK+= { sub("/${_HASKELL_PL_
PRINT_PLIST_AWK+= { sub( "${_HASKELL_PL_PKGID}", "$${HS_PKGID}") }
PRINT_PLIST_AWK+= { sub( "${_HASKELL_PL_VER}", "$${HS_VER}") }
-.if !exists(${PKGDIR}/PLIST)
-_HS_PLIST_STATUS= missing
-.elif ${${GREP} HS_INTF ${PKGDIR}/PLIST || ${TRUE}:L:sh}
-_HS_PLIST_STATUS= up-to-date
-.else
-_HS_PLIST_STATUS= outdated
-.endif
-
HS_UPDATE_PLIST?= no
-.if ${HS_UPDATE_PLIST} != no && ${_HS_PLIST_STATUS} != up-to-date
+. if ${HS_UPDATE_PLIST} != no && ${_HS_PLIST_STATUS} == missing
GENERATE_PLIST+= ${MAKE} print-PLIST > ${PKGDIR}/PLIST;
+. endif
.endif
-.if ${_HS_PLIST_STATUS} != up-to-date
-# The PLISTs that don't use HS_INTF and the other placeholders defined
-# above are outdated and wrong, and are therefore ignored.
+.if ${_HS_PLIST_STATUS} == missing || ${_HS_PLIST_STATUS} == outdated
GENERATE_PLIST+= \
cd ${DESTDIR:Q}${PREFIX:Q} && \
${FIND} * \( -type f -o -type l \) | ${SORT};
Index: pkgsrc/textproc/hs-cgrep/PLIST
diff -u pkgsrc/textproc/hs-cgrep/PLIST:1.3 pkgsrc/textproc/hs-cgrep/PLIST:1.4
--- pkgsrc/textproc/hs-cgrep/PLIST:1.3 Wed May 13 04:53:17 2020
+++ pkgsrc/textproc/hs-cgrep/PLIST Sun Jun 21 22:21:03 2020
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.3 2020/05/13 04:53:17 rillig Exp $
-${HS_PKGID}${HS_DOCS}${HS_IMPL}bin/cgrep
-${HS_PKGID}${HS_DOCS}${HS_IMPL}share/doc/x86_64-netbsd-ghc-8.8.1/cgrep-${PKGVERSION}/LICENSE
-${HS_PKGID}${HS_DOCS}${HS_IMPL}@pkgdir lib/cgrep-${PKGVERSION}/ghc-8.8.1
+@comment $NetBSD: PLIST,v 1.4 2020/06/21 22:21:03 rillig Exp $
+bin/cgrep
+share/doc/x86_64-netbsd-ghc-8.8.1/cgrep-${PKGVERSION}/LICENSE
+@pkgdir lib/cgrep-${PKGVERSION}/ghc-8.8.1
Home |
Main Index |
Thread Index |
Old Index