diff options
author | Ian Lynagh <igloo@earth.li> | 2010-10-20 10:47:59 +0000 |
---|---|---|
committer | Ian Lynagh <igloo@earth.li> | 2010-10-20 10:47:59 +0000 |
commit | 02856df2ce1e728930cb96210e79422f34929579 (patch) | |
tree | 510adf9dc5e816be4c1f904fc441f3e9b9750183 /rules/hs-sources.mk | |
parent | 351f4d4230012eee97d38110cc800a4215de8f65 (diff) | |
download | haskell-02856df2ce1e728930cb96210e79422f34929579.tar.gz |
Look for sources in Cabal's autogen directory too
Diffstat (limited to 'rules/hs-sources.mk')
-rw-r--r-- | rules/hs-sources.mk | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/rules/hs-sources.mk b/rules/hs-sources.mk index 2a2f37a7c6..4164be44ad 100644 --- a/rules/hs-sources.mk +++ b/rules/hs-sources.mk @@ -26,11 +26,11 @@ endif # NB. use :=, we only want this thing evaluated once. # $1_$2_HS_SRCS := $$(foreach file,$$($1_$2_SLASH_MODS),\ - $$(firstword \ - $$(wildcard \ - $$(foreach dir,$$($1_$2_HS_SRC_DIRS),\ - $1/$$(dir)/$$(file).hs $1/$$(dir)/$$(file).lhs)) \ - $1/$2/build/$$(file).hs)) + $$(firstword \ + $$(wildcard \ + $$(foreach dir,$$($1_$2_HS_SRC_DIRS) $2/build/autogen,\ + $1/$$(dir)/$$(file).hs $1/$$(dir)/$$(file).lhs)) \ + $1/$2/build/$$(file).hs)) # .hs-boot files must be in the same place as the .hs file they go # with (GHC assumes this). When we preprocess a source file, and @@ -47,12 +47,12 @@ $1_$2_HS_SRCS := $$(foreach file,$$($1_$2_SLASH_MODS),\ # NB. use :=, we only want this thing evaluated once. # $1_$2_HS_BOOT_SRCS := $$(foreach dir,$$($1_$2_HS_SRC_DIRS),\ - $$(subst $1/$$(dir),$1/$2/build,\ - $$(wildcard \ - $$(subst $1/$2/build,$1/$$(dir),\ - $$(foreach file,\ - $$(filter $1/$2/build%,$$($1_$2_HS_SRCS)),\ - $$(patsubst %.hs,%.hs-boot,$$(file)) \ - $$(patsubst %.hs,%.lhs-boot,$$(file))))))) + $$(subst $1/$$(dir),$1/$2/build,\ + $$(wildcard \ + $$(subst $1/$2/build,$1/$$(dir),\ + $$(foreach file,\ + $$(filter $1/$2/build%,$$($1_$2_HS_SRCS)),\ + $$(patsubst %.hs,%.hs-boot,$$(file)) \ + $$(patsubst %.hs,%.lhs-boot,$$(file))))))) endef |