Commit graph

20 commits

Author SHA1 Message Date
rillig
3c7198b683 mk/haskell.mk: allow to generate PLIST files
Since GHC 7.10 or 7.8, the Haskell packages are installed in directories
whose name contains the package hash.  This made it harder to predict the
exact pathname.  Havin the exact pathnames in the PLIST file is the
ideal, it also helps to record the general structure of the installed
files to see whether some file unexpectedly appear or disappear.

To enable this for Haskell packages, the various base directories are
replaced with placeholders during print-PLIST.  These placeholders are
translated back to their respective paths when the +PLIST is generated
from the PLIST in the package directory.

Except for 2 packages, all Haskell packages in main pkgsrc had their
package PLIST file removed.  To help in adding them back, the pkgsrc
developer can set HS_UPDATE_PLIST=yes in mk.conf, which will generate the
PLIST directly into ${PKGDIR}/PLIST upon installation.

Most packages in pkgsrc-wip still have their old PLIST, and these are
migrated automatically as well.
2020-05-10 17:46:59 +00:00
riastradh
ea504032f9 Missed a spot -- set MAKE_ENV during haddock build too. 2020-03-30 18:23:48 +00:00
riastradh
270c7f3e7b In Haskell packages, set MAKE_ENV while running ./Setup build. 2020-03-30 17:51:07 +00:00
riastradh
4c01312406 New package variable HASKELL_PKG_NAME.
Used to form _HASKELL_PKG_DESCR_DIR.  Defaults to DISTNAME, but for
some packages (hledger, incoming), the same DISTNAME is shared by
multiple packages.  So let the package define it explicitly if need
be.
2020-03-30 16:51:53 +00:00
joerg
a1e7953bb0 Don't use normal memory size limits with GHC for module builds. 2020-03-24 20:43:17 +00:00
pho
865567336f Build ${WRKSRC}/Setup in the do-configure phase
Doing it in pre-configure makes it unable to do SUBST in that phase.
2020-01-20 14:14:33 +00:00
pho
a1f59741bc Use _MAKE_JOBS_N defined in build/build.mk 2020-01-19 23:45:06 +00:00
pho
9bbb8420be Configurable optimization level and compilation parallelism 2020-01-18 01:39:01 +00:00
pho
024aad2263 Switch from ghc7 to ghc88 2020-01-11 07:47:18 +00:00
pho
ee9f90656c Use hashed package keys for (un)installing Cabal packages
Starting from somewhere around GHC 7.8, Cabal installs packages with a
hashed package key instead of just "{NAME}-{VERSION}". In other words,
the pair of the plain package name and the version is no longer unique
in the package DB, and using it for uninstallation may also remove
packages that we didn't mean to remove.

This is paricularly problematic because GHC comes with several bundled
Cabal packages. Installing and uninstalling a package with the same
name could break GHC itself, if the uninstallation is performed
without hashed keys.
2020-01-09 12:29:32 +00:00
pho
0215d2d16a Be explicit about shared libraries
Recent versions of Cabal appears to build shared libraries by default unless --disable-shared is explicitly given.
2020-01-02 16:45:15 +00:00
pho
f20c406612 Pass -v to ./Setup when PKG_VERBOSE is defined 2020-01-02 16:34:47 +00:00
pho
d3ea0027a2 Suppress an error occurs when buildlink is not present 2020-01-01 04:54:10 +00:00
pho
e8f85a7b71 Remove unused variables 2020-01-01 04:35:29 +00:00
pho
1589ba417e For "Setup" try dynamic linkage first 2019-12-31 07:16:25 +00:00
pho
a62b984936 Support GHC 7.10.x and later 2019-12-29 16:59:55 +00:00
joerg
639d5b402f Remove support for USE_DESTDIR=no. 2016-04-10 15:58:02 +00:00
joerg
d686fdbc97 rpath flag and directory are one option, don't pass the path without
-Wl prefix.
2015-02-17 13:57:47 +00:00
obache
1c90fa81ef Some improvements and changes for Haskell Cabal support.
* HASKELL_ENABLE_LIBRARY_PROFILING and HASKELL_ENABLE_HADDOCK_DOCUMENTATION
  are "User-settable variables", not "Package-settable variables".
* Change to HASKELL_ENABLE_HADDOCK_DOCUMENTATION=yes by default.
* Add HASKELL_ENABLE_SHARED_LIBRARY("yes" by default), to enable shlib support.
* Add support for dynamically conditional PLIST entries handling for
  HASKELL_ENABLE_SHARED_LIBRARY and HASKELL_ENABLE_LIBRARY_PROFILING.

discussed with pho@ and szptvlfn@.
2014-04-18 13:42:59 +00:00
obache
d761adbc39 add Haskell Cabal support files. 2014-02-05 07:02:30 +00:00