summaryrefslogtreecommitdiff
path: root/ghc.mk
diff options
context:
space:
mode:
authorJohn Ericson <John.Ericson@Obsidian.Systems>2021-07-22 07:26:47 +0000
committerMarge Bot <ben+marge-bot@smart-cactus.org>2021-08-09 15:11:58 -0400
commitd5de970dafd5876ef30601697576167f56b9c132 (patch)
treecb2ccf4bc4c13e39e211beb60915d7bb4ccc477d /ghc.mk
parentfc350dba63da7eefbaa2793fe9fe99f8571b75c0 (diff)
downloadhaskell-d5de970dafd5876ef30601697576167f56b9c132.tar.gz
Move `/includes` to `/rts/include`, sort per package better
In order to make the packages in this repo "reinstallable", we need to associate source code with a specific packages. Having a top level `/includes` dir that mixes concerns (which packages' includes?) gets in the way of this. To start, I have moved everything to `rts/`, which is mostly correct. There are a few things however that really don't belong in the rts (like the generated constants haskell type, `CodeGen.Platform.h`). Those needed to be manually adjusted. Things of note: - No symlinking for sake of windows, so we hard-link at configure time. - `CodeGen.Platform.h` no longer as `.hs` extension (in addition to being moved to `compiler/`) so as not to confuse anyone, since it is next to Haskell files. - Blanket `-Iincludes` is gone in both build systems, include paths now more strictly respect per-package dependencies. - `deriveConstants` has been taught to not require a `--target-os` flag when generating the platform-agnostic Haskell type. Make takes advantage of this, but Hadrian has yet to.
Diffstat (limited to 'ghc.mk')
-rw-r--r--ghc.mk12
1 files changed, 6 insertions, 6 deletions
diff --git a/ghc.mk b/ghc.mk
index a244c1b53c..94c2ce38ee 100644
--- a/ghc.mk
+++ b/ghc.mk
@@ -634,7 +634,7 @@ BUILD_DIRS += driver/ghc
BUILD_DIRS += driver/haddock
BUILD_DIRS += libffi
BUILD_DIRS += utils/deriveConstants
-BUILD_DIRS += includes
+BUILD_DIRS += rts/include
BUILD_DIRS += rts
BUILD_DIRS += bindisttest
BUILD_DIRS += utils/genapply
@@ -1043,7 +1043,7 @@ $(eval $(call bindist-list,.,\
$(BINDIST_LIBS) \
$(BINDIST_HI) \
$(BINDIST_EXTRAS) \
- includes/Makefile \
+ rts/include/Makefile \
$(includes_H_FILES) \
$(includes_1_H_CONFIG) \
$(includes_1_H_PLATFORM) \
@@ -1331,8 +1331,8 @@ CLEAN_FILES += compiler/ghc.cabal.old
# These are no longer generated, but we still clean them for a while
# as they may still be in old GHC trees:
-CLEAN_FILES += includes/GHCConstants.h
-CLEAN_FILES += includes/DerivedConstants.h
+CLEAN_FILES += rts/include/GHCConstants.h
+CLEAN_FILES += rts/include/DerivedConstants.h
$(foreach n,0 1 2, \
$(foreach h,$(includes_$n_H_CONFIG) $(includes_$n_H_PLATFORM) $(includes_$n_H_VERSION), \
$(eval CLEAN_FILES += $h)))
@@ -1347,7 +1347,7 @@ clean : clean_files clean_libraries
clean_files :
$(call removeFiles,$(CLEAN_FILES))
# this is here since CLEAN_FILES can't handle folders
- $(call removeTrees,includes/dist-derivedconstants)
+ $(call removeTrees,rts/include/dist-derivedconstants)
$(call removeTrees,inplace/bin)
$(call removeTrees,inplace/lib)
$(call removeTrees,libraries/bootstrapping.conf)
@@ -1433,7 +1433,7 @@ distclean : clean
$(call removeTrees,bindisttest/a)
# Not sure why this is being cleaned here.
- $(call removeTrees,includes/dist-derivedconstants)
+ $(call removeTrees,rts/include/dist-derivedconstants)
# Also clean Windows-only inplace directories.
# Don't delete 'inplace' itself, it contains source files.