-
Notifications
You must be signed in to change notification settings - Fork 205
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Update rules_haskell & rules_nixpkgs * Define dadew POSIX toolchain on Windows * Build hpp with stack and Cabal * Replace Hazel hpp by @stackage hpp * replace backslash by forward slash * Cabal wrapper exclude bindist includes * ghci-grpc patch fix missing argument * Switch to rules_haskell master
- Loading branch information
1 parent
dcbe7a4
commit 67a7989
Showing
9 changed files
with
151 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
Adding include paths to the GHC bindist upsets the Windows builds. GHC starts | ||
looking for ghcversion.h under too long paths and fails due to not finding it. | ||
diff --git a/haskell/cabal.bzl b/haskell/cabal.bzl | ||
index b2cc1e27..a48572ab 100644 | ||
--- a/haskell/cabal.bzl | ||
+++ b/haskell/cabal.bzl | ||
@@ -88,6 +88,12 @@ def _cabal_tool_flag(tool): | ||
def _binary_paths(binaries): | ||
return [binary.dirname for binary in binaries.to_list()] | ||
|
||
+def _skip_ghc_bindist(path): | ||
+ if path.find("rules_haskell_ghc_windows_amd64") != -1: | ||
+ return None | ||
+ else: | ||
+ return path | ||
+ | ||
def _prepare_cabal_inputs(hs, cc, posix, dep_info, cc_info, component, package_id, tool_inputs, tool_input_manifests, cabal, setup, srcs, flags, cabal_wrapper, package_database): | ||
"""Compute Cabal wrapper, arguments, inputs.""" | ||
with_profiling = is_profiling_enabled(hs) | ||
@@ -118,7 +124,7 @@ def _prepare_cabal_inputs(hs, cc, posix, dep_info, cc_info, component, package_i | ||
args.add("--flags=" + " ".join(flags)) | ||
args.add("--") | ||
args.add_all(package_databases, map_each = _dirname, format_each = "--package-db=%s") | ||
- args.add_all(extra_include_dirs, format_each = "--extra-include-dirs=%s") | ||
+ args.add_all(extra_include_dirs, map_each = _skip_ghc_bindist, format_each = "--extra-include-dirs=%s") | ||
args.add_all(extra_lib_dirs, format_each = "--extra-lib-dirs=%s", uniquify = True) | ||
if with_profiling: | ||
args.add("--enable-profiling") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
resolver: lts-14.1 | ||
packages: | ||
- hpp-0.6.1 | ||
# Core packages, need to be listed for integer-simple flags. | ||
- integer-simple-0.1.1.1 | ||
- text-1.2.3.1 |