- Mar 26, 2025
-
-
Cheng Shao authored
Hadrian used to omit the docs target as a part of binary-dist-dir for cross targets. This commit enables docs to be built as a part of cross bindists and it works just fine in CI. (cherry picked from commit a794e733) (cherry picked from commit a0af1500)
-
Cheng Shao authored
This commit enables building stage1 haddock for cross ghc. Without this change, hadrian would panic with "Unknown program" error when building the _build/stage1/bin/cross-prefix-haddock program needed by the docs-haddock target, even if it only needs to copy from _build/stage0/bin/cross-prefix-haddock. (cherry picked from commit 272eaef0) (cherry picked from commit 0b775a8a)
-
Cheng Shao authored
This patch adds a +text_simdutf flavour transformer to hadrian to allow downstream packagers and users that build from source to opt-in simdutf support for text, in order to benefit from SIMD speedup at run-time. It's still disabled by default for the time being. (cherry picked from commit 44e2abfb)
-
Cheng Shao authored
(cherry picked from commit c35281f9)
-
Cheng Shao authored
This patch fixes one incoherent place between bindist makefile and hadrian logic: I forgot to include wasi/wasm32 in OsSupportsGHCi/ArchSupportsGHCi as well. And this results in incorrect settings file generated after installing the bindist, and "Use interpreter"/"Have interpreter" fields incorrectly have "NO" values where they should be "YES" like --info output of in-tree version. (cherry picked from commit 75a2eae4) (cherry picked from commit 735f3f9a)
-
Cheng Shao authored
This patch disables internal-interpreter flag for stage0 ghc-bin when not cross compiling, see added comment for explanation. Fixes #25406. (cherry picked from commit fde12aba)
-
Cheng Shao authored
This commit flips on the support for shared libs and ghci for the wasm target, given all required support logic has been added in previous commits. (cherry picked from commit 652e7239)
-
Cheng Shao authored
This commit adds the wasm dynamic linker implementation, as well as ghci logic to call it and hadrian logic to install it to the correct location. See the top-level note in utils/jsffi/dyld.mjs for more details. (cherry picked from commit 549582ef)
-
Cheng Shao authored
This patch implements the targetRTSLinkerOnlySupportsSharedLibs predicate in hadrian. Its definition in hadrian is the single source of truth, and the information propagates to ghc settings file, ghc driver and testsuite driver. It is used in various places to ensure dynamic dependency is selected when the target RTS linker only supports loading dynamic code. (cherry picked from commit 8c74a0ed)
-
Cheng Shao authored
This commit implements the config.cross field in the testsuite driver. It comes from the "cross compiling" ghc info field for both in-tree/out-of-tree GHC, and is an accurate predicate of whether we're cross-compiling or not (compared to the precense of target emulator), and is useful to implement predicates to assert the precense of internal interpreter (only available on non-cross GHC) for tests that do require it (e.g. plugins). (cherry picked from commit 2956a3f7)
-
Cheng Shao authored
This commit adds the host_fully_static flavour transformer to hadrian, which ensures stage0 is fully statically linked while still permitting stage1 libdir to contain shared libraries. This is intended to be used by the wasm backend to build portable linux bindists that contain wasm shared libraries. (cherry picked from commit b45080a3)
-
Cheng Shao authored
This commit re-enables --with-pic=yes configuration option of gmp when building for wasm, given we're about to include support for shared libraries, TH and ghci. (cherry picked from commit 775410fd)
-
Cheng Shao authored
This commit adds -fvisibility=default to CFLAGS of gmp when building for wasm. This is required to generate the ghc-bignum shared library without linking errors. Clang defaults to -fvisibility=hidden for wasm targets, which will cause issues when a symbol is expected to be exported in a shared library but without explicit visibility attribute annotation. (cherry picked from commit c247f2ee)
-
Cheng Shao authored
This commit enables internal-interpreter flag for ghc-bin even when compiling stage0, as long as target supports ghci. It enables ghci functionality for cross targets that support ghci, since cross ghc-bin is really stage0. (cherry picked from commit 577c1819)
-
Cheng Shao authored
This commit disable the internal-interpreter flag of ghc library when cross compiling, only external interpreter works in such cases. (cherry picked from commit f232c872)
-
Cheng Shao authored
This commit changes the hostSupportsRPaths predicate to targetSupportsRPaths and use that to decide whether to pass RPATH-related link-time options. It's not applied to stage0, we should just use the default link-time options of stageBoot ghc. (cherry picked from commit a6a82cdb)
-
Cheng Shao authored
This commit renames prelude.js to prelude.mjs for wasm backend rts jsbits, and slightly adjusts the jsbits contents. This is for preparing the implementation of dyld.mjs that contains wasm dynamic linker logic, which needs to import prelude.mjs as a proper ESM module. (cherry picked from commit 71a471e7)
-
Cheng Shao authored
This patch removes the ghciWithDebugger field from flavour config since it's actually not used anywhere. (cherry picked from commit c6e5fd3d)
-
Cheng Shao authored
hadrian may invoke findExecutable "" at run-time due to a certain program is not found by configure script. Which is fine and findExecutable is supposed to return Nothing in this case. However, on Windows there's a directory bug that throws an exception (see https://github.com/haskell/directory/issues/180), so we might as well use a wrapper for findExecutable and handle exceptions gracefully. (cherry picked from commit 1e5752f6)
-
Cheng Shao authored
When split sections is enabled, ensure -fsplit-sections is passed to GHC as well when invoking GHC to compile C/C++; and pass -ffunction-sections -fdata-sections to gcc/clang when compiling C/C++ with the hadrian Cc builder. Fixes #23381. (cherry picked from commit 0958937e)
-
Cheng Shao authored
(cherry picked from commit a580722e)
-
Add a dependency between Syntax and Internal (via module reexport). (cherry picked from commit 4d78c53c)
-
Historically quite a few packages had to be stage0 as they depended on `template-haskell` and that was stage0. In #23536 we made it so that was no longer the case. This allows us to remove a bunch of packages from this list. A few still remain. A new version of `Win32` is required by `semaphore-compat`. Including `Win32` in the stage0 set requires also including `filepath` because otherwise Hadrian's dependency logic gets confused. Once our boot compiler has a newer version of `Win32` all of these will be able to be dropped. Resolves #24652 (cherry picked from commit dd339c7a)
-
Promoting template-haskell from a stage0 to a stage1 package means that we can much more easily refactor template-haskell. We implement this by duplicating the in-tree `template-haskell`. A new `template-haskell-next` library is autogenerated to mirror `template-haskell` `stage1:ghc` to depend on the new interface of the library including the `Binary` instances without adding an explicit dependency on `template-haskell`. This is controlled by the `bootstrap-th` cabal flag When building `template-haskell` modules as part of this vendoring we do not have access to quote syntax, so we cannot use variable quote notation (`'Just`). So we either replace these with hand-written `Name`s or hide the code behind CPP. We can remove the `th_hack` from hadrian, which was required when building stage0 packages using the in-tree `template-haskell` library. For more details see Note [Bootstrapping Template Haskell]. Resolves #23536 Co-Authored-By:
Sebastian Graf <sgraf1337@gmail.com> Co-Authored-By:
Matthew Craven <5086-clyring@users.noreply.gitlab.haskell.org> (cherry picked from commit 42bd0407)
-
Cheng Shao authored
This reverts commit 3a18d9e7.
- Mar 05, 2025
-
-
Ben Gamari authored
This reverts commit 15ca7b2c as it breaks bootstrapping with 9.8 and 9.6, where `directory-1.3.9` is not shipped.
-
- Feb 27, 2025
-
-
Ben Gamari authored
Updates text submodule.
-
- Feb 19, 2025
-
-
Andreas Klebinger authored
-
- Feb 14, 2025
-
-
At least some versions of Texlive's `mktexfmt` utility cannot be invoked concurrently in their initial run since they fail to handle failure of `mkdir` due to racing. Specifically, we see ``` | Run Xelatex: users_guide.tex => /tmp/extra-dir-9616886274866 | Run Xelatex: Haddock.tex => /tmp/extra-dir-9616886274869 This is XeTeX, Version 3.14159265-2.6-0.999992 (TeX Live 2020) (preloaded format=xelatex) restricted \write18 enabled. kpathsea: Running mktexfmt xelatex.fmt mktexfmt: mktexfmt is using the following fmtutil.cnf files (in precedence order): mktexfmt: /usr/share/texlive/texmf-dist/web2c/fmtutil.cnf mktexfmt: mktexfmt is using the following fmtutil.cnf file for writing changes: mktexfmt: /builds/ghc/ghc/tmp-home/.texlive2020/texmf-config/web2c/fmtutil.cnf /usr/bin/mktexfmt: mkdir(/builds/ghc/ghc/tmp-home/.texlive2020/texmf-var/web2c/) failed for tree /builds/ghc/ghc/tmp-home/.texlive2020/texmf-var/web2c: File exists at /usr/share/texlive/tlpkg/TeXLive/TLUtils.pm line 937. I can't find the format file `xelatex.fmt'! ``` That is two `mktexfmt` invocations (for the user's guide and haddock builds) attempted to create `$HOME/texlive2020/texmf-var/web2c` and raced. One of the two `mkdir`'s consequently failed, bringing down the entire build. We avoid this by ensuring that the first `xelatex` invocation is always performed serially. Fixes #25564. (cherry picked from commit 41dae5b8)
-
- Feb 06, 2025
-
-
Andreas Klebinger authored
Earlier versions of `directory` are racy on Windows due to #24382.
-
- Feb 05, 2025
-
-
Andreas Klebinger authored
This avoids some bound issues when using ghc-9.10.1 as boot compiler.
-
- Jan 14, 2025
-
-
hadrian does not utilise the build-tool-depends fields in cabal files and their presence can cause issues when building source distribution (see #24826) Ideally Cabal would support building "full" source distributions which would remove the need for workarounds in hadrian but for now we can patch the build-tool-depends out of the cabal files. Fixes #24826 (cherry picked from commit aba2c9d4)
-
There is some convoluted logic which determines whether we build ghci object files are not. In any case, if you set `ghcDynPrograms = pure False` then it forces them to be built. Given we aren't ever building executables with this flavour it's fine to leave `ghcDynPrograms` as the default and it should be a bit faster to build less. Also fixes #24949 (cherry picked from commit a949c792)
-
- Dec 18, 2024
-
-
(cherry picked from commit be514bb4)
-
This patch makes hadrian build in-tree GMP with the --enable-alloca=malloc-notreentrant configure option. We will only need malloc-reentrant when we have threaded RTS and SMP support on wasm32, which will take some time to happen, before which we should use malloc-notreentrant to avoid undesired runtime overhead. (cherry picked from commit 06277d56)
-
This patch disables in-tree GMP FFT code paths for wasm32 target in order to give up some performance of multiplying very large operands in exchange for reduced code size. (cherry picked from commit 1a32f828)
-