diff options
-rw-r--r-- | compiler/ghc.mk | 5 | ||||
-rw-r--r-- | ghc.mk | 17 | ||||
-rw-r--r-- | ghc/ghc.mk | 5 | ||||
-rw-r--r-- | rules/build-package-data.mk | 8 | ||||
-rw-r--r-- | rules/build-package.mk | 8 | ||||
-rw-r--r-- | utils/ghc-pkg/ghc-pkg.cabal | 2 |
6 files changed, 19 insertions, 26 deletions
diff --git a/compiler/ghc.mk b/compiler/ghc.mk index 9621f1de4b..854b756330 100644 --- a/compiler/ghc.mk +++ b/compiler/ghc.mk @@ -24,6 +24,11 @@ compiler_stage3_MKDEPENDC_OPTS = -DMAKING_GHC_BUILD_SYSTEM_DEPENDENCIES compiler_stage1_C_FILES_NODEPS = compiler/parser/cutils.c +# This package doesn't pass the Cabal checks because include-dirs +# points outside the source directory. This isn't a real problem, so +# we just skip the check. +compiler_NO_CHECK = YES + ifneq "$(BINDIST)" "YES" compiler/stage1/package-data.mk : compiler/stage1/build/Config.hs compiler/stage2/package-data.mk : compiler/stage2/build/Config.hs @@ -566,23 +566,6 @@ libraries/dph/dph-lifted-copy_dist-install_EXCLUDED_WAYS := dyn libraries/dph/dph-lifted-vseg_dist-install_EXCLUDED_WAYS := dyn endif -# ---------------------------------------------- -# Checking packages with 'cabal check' - -ifeq "$(phase)" "final" -ifeq "$(CHECK_PACKAGES)" "YES" -all: check_packages -endif -endif - -# These packages don't pass the Cabal checks because hs-source-dirs -# points outside the source directory. This isn't a real problem in -# these cases, so we just skip checking them. -# NB. these must come before we include the ghc.mk files below, because -# they disable the relevant rules. -# In compiler's case, include-dirs points outside of the source tree -CHECKED_compiler = YES - # ----------------------------------------------------------------------------- # Include build instructions from all subdirs diff --git a/ghc/ghc.mk b/ghc/ghc.mk index 6df1a50746..71356fccf0 100644 --- a/ghc/ghc.mk +++ b/ghc/ghc.mk @@ -31,6 +31,11 @@ ifeq "$(compiler_stage1_VERSION_MUNGED)" "YES" ghc_stage1_CONFIGURE_OPTS += --constraint "ghc == $(compiler_stage1_MUNGED_VERSION)" endif +# This package doesn't pass the Cabal checks because data-dir +# points outside the source directory. This isn't a real problem, so +# we just skip the check. +ghc_NO_CHECK = YES + ghc_stage1_MORE_HC_OPTS = $(GhcStage1HcOpts) ghc_stage2_MORE_HC_OPTS = $(GhcStage2HcOpts) ghc_stage3_MORE_HC_OPTS = $(GhcStage3HcOpts) diff --git a/rules/build-package-data.mk b/rules/build-package-data.mk index 17def03638..7cee00b71c 100644 --- a/rules/build-package-data.mk +++ b/rules/build-package-data.mk @@ -102,6 +102,14 @@ $1/$2/build/autogen/cabal_macros.h : $1/$2/package-data.mk # for our build system, and registers the package for use in-place in # the build tree. $1/$2/package-data.mk : $$(GHC_CABAL_INPLACE) $$($1_$2_GHC_PKG_DEP) $1/$$($1_PACKAGE).cabal $$(wildcard $1/configure) $$(LAX_DEPS_FOLLOW) $$($1_$2_HC_CONFIG_DEP) +# Checking packages built with the bootstrapping compiler would +# generally be a waste of time. Either we will rebuild them with +# stage1/stage2, or we don't really care about them. +ifneq "$3" "0" +ifneq "$$($1_NO_CHECK)" "YES" + CROSS_COMPILE="$(CrossCompilePrefix)" "$$(GHC_CABAL_INPLACE)" check $1 +endif +endif CROSS_COMPILE="$(CrossCompilePrefix)" "$$(GHC_CABAL_INPLACE)" configure --with-ghc="$$($1_$2_HC_CONFIG)" --with-ghc-pkg="$$($1_$2_GHC_PKG)" $$($1_CONFIGURE_OPTS) $$($1_$2_CONFIGURE_OPTS) -- $2 $1 ifeq "$$($1_$2_PROG)" "" ifneq "$$($1_$2_REGISTER_PACKAGE)" "NO" diff --git a/rules/build-package.mk b/rules/build-package.mk index e64754cb3f..47b706e718 100644 --- a/rules/build-package.mk +++ b/rules/build-package.mk @@ -137,14 +137,6 @@ ifneq "$$($1_$2_GROUP)" "" all_$$($1_$2_GROUP): all_$1_$2 endif -ifneq "$$(CHECKED_$1)" "YES" -CHECKED_$1 = YES -check_packages: check_$1 -.PHONY: check_$1 -check_$1: $$(GHC_CABAL_INPLACE) - CROSS_COMPILE="$(CrossCompilePrefix)" $$(GHC_CABAL_INPLACE) check $1 -endif - ifneq "$3" "0" $(call haddock,$1,$2) endif diff --git a/utils/ghc-pkg/ghc-pkg.cabal b/utils/ghc-pkg/ghc-pkg.cabal index e7f1d539ac..2f42e31f15 100644 --- a/utils/ghc-pkg/ghc-pkg.cabal +++ b/utils/ghc-pkg/ghc-pkg.cabal @@ -11,7 +11,7 @@ Description: XXX Category: Development build-type: Simple -cabal-version: >=1.2 +cabal-version: >=1.4 Executable ghc-pkg Main-Is: Main.hs |