Skip to content
Snippets Groups Projects
  1. Nov 06, 2019
  2. Oct 30, 2019
  3. Sep 05, 2019
  4. Jul 14, 2019
    • Ben Gamari's avatar
      Don't package settings in bindist · f508b7ce
      Ben Gamari authored and Marge Bot's avatar Marge Bot committed
      Since !712 the `settings` file is produced by the build system instead
      of autoconf. However, this introduced a subtle bug where we would fail
      to rebuild the `settings` file with what we have learned from the
      install-time `configure` invocation. Fix this by not packaging
      `settings` in the bindist tarball. The build system will take care of
      the rest.
      
      Also fix a bug where the value of `UseLibdw` was not being persisted to
      the install time `configure`.
      f508b7ce
  5. May 21, 2019
  6. May 01, 2019
  7. Apr 11, 2019
  8. Apr 01, 2019
  9. Mar 25, 2019
    • Takenobu Tani's avatar
      Update Wiki URLs to point to GitLab · 3769e3a8
      Takenobu Tani authored and Marge Bot's avatar Marge Bot committed
      This moves all URL references to Trac Wiki to their corresponding
      GitLab counterparts.
      
      This substitution is classified as follows:
      
      1. Automated substitution using sed with Ben's mapping rule [1]
          Old: ghc.haskell.org/trac/ghc/wiki/XxxYyy...
          New: gitlab.haskell.org/ghc/ghc/wikis/xxx-yyy...
      
      2. Manual substitution for URLs containing `#` index
          Old: ghc.haskell.org/trac/ghc/wiki/XxxYyy...#Zzz
          New: gitlab.haskell.org/ghc/ghc/wikis/xxx-yyy...#zzz
      
      3. Manual substitution for strings starting with `Commentary`
          Old: Commentary/XxxYyy...
          New: commentary/xxx-yyy...
      
      See also !539
      
      [1]: https://gitlab.haskell.org/bgamari/gitlab-migration/blob/master/wiki-mapping.json
      3769e3a8
  10. Mar 15, 2019
  11. Mar 09, 2019
    • Ben Gamari's avatar
      Rip out perl dependency · b760269c
      Ben Gamari authored and Marge Bot's avatar Marge Bot committed
      The object splitter was the last major user of perl. There remain a few
      uses in nofib but we can just rely on the system's perl for this since
      it's not critical to the build.
      b760269c
  12. Mar 06, 2019
    • Ben Gamari's avatar
      Rip out object splitting · 37f257af
      Ben Gamari authored and Marge Bot's avatar Marge Bot committed
      The splitter is an evil Perl script that processes assembler code.
      Its job can be done better by the linker's --gc-sections flag. GHC
      passes this flag to the linker whenever -split-sections is passed on
      the command line.
      
      This is based on @DemiMarie's D2768.
      
      Fixes Trac #11315
      Fixes Trac #9832
      Fixes Trac #8964
      Fixes Trac #8685
      Fixes Trac #8629
      37f257af
  13. Feb 13, 2019
  14. Nov 23, 2018
  15. Oct 03, 2018
  16. Mar 19, 2018
  17. Jan 15, 2018
    • John Ericson's avatar
      configure: Various cleanups · 8de89305
      John Ericson authored and Ben Gamari's avatar Ben Gamari committed
      Substitute RanlibCmd for consistency, and other configure cleanups that
      should have no effect
      
      The other commands are so substituted. Maybe we don't need ranlib at
      all, and the configure snippet can be removed all together, but that
      can always be done later.
      
      Reviewers: bgamari, hvr, angerman
      
      Reviewed By: bgamari, angerman
      
      Subscribers: rwbarton, thomie, erikd, carter
      
      Differential Revision: https://phabricator.haskell.org/D4286
      8de89305
  18. Sep 26, 2017
    • Ben Gamari's avatar
      configure: Don't hard-code strip tool · 65f7d87a
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      For reasons that I don't entirely understand we didn't previously detect
      `strip` using autoconf. This naturally broke during cross-compilation.
      How did this ever work? I have no idea.
      
      Test Plan: Try cross-compiling
      
      Reviewers: austin, hvr, angerman
      
      Subscribers: rwbarton, thomie, erikd
      
      Differential Revision: https://phabricator.haskell.org/D4008
      65f7d87a
  19. Sep 05, 2017
  20. Jul 23, 2017
    • Ben Gamari's avatar
      Preserve HaskellHaveRTSLinker in bindist · 0ae0f466
      Ben Gamari authored
      Otherwise you end up with ("target has RTS linker","@HaskellHaveRTSLinker@") in
      the installed settings file.
      0ae0f466
    • Ben Gamari's avatar
      distrib/configure: Carry FFI include/lib paths from source distribution · 98ab12ad
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      `FFILibDir` and `FFIIncludeDir` both show up in the `rts` library's
      package registration file.  We therefore must define them or else we'll
      end up with spurious `@FFILibDir@` strings in the package registration.
      
      In principle I think we could also take these as arguments to the
      bindist configure but this seems simpler and I don't want to verify this
      at the moment.
      
      Test Plan: Build bindist while passing `--with-ffi-libraries=...` to
      source distribution configure then try to install and use bindist.
      
      Reviewers: austin, hvr
      
      Subscribers: rwbarton, thomie, erikd
      
      Differential Revision: https://phabricator.haskell.org/D3774
      98ab12ad
  21. Jul 20, 2017
    • Ben Gamari's avatar
      distrib/configure: Canonicalize triples · 1480080b
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      Previously we failed to do this, which meant that the bindist's
      configure would fail when passed --target (as you may need to do when
      installing an armv7 bindist on an aarch64 machine, for instance).
      
      Reviewers: hvr, erikd, austin
      
      Reviewed By: hvr
      
      Subscribers: rwbarton, thomie
      
      GHC Trac Issues: #13934
      
      Differential Revision: https://phabricator.haskell.org/D3761
      1480080b
  22. Jul 12, 2017
    • Ben Gamari's avatar
      distrib/configure: Fail if we can't detect machine's word size · 60ec8f74
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      This is a sure sign that something is terribly wrong.
      
      We also now verify that the word size that the binary distribution
      expects matches the word size produced by the local target toolchain.
      
      Finally we rename WordSize to TargetWordSize, since non-host/target
      qualified quantities are terribly confusing.
      
      Reviewers: austin, hvr, Phyx
      
      Reviewed By: Phyx
      
      Subscribers: Phyx, rwbarton, thomie, erikd
      
      Differential Revision: https://phabricator.haskell.org/D3711
      60ec8f74
  23. Jul 05, 2017
  24. Jul 03, 2017
    • Ben Gamari's avatar
      Add -fuse-ld flag to CFLAGS during configure · 960918bd
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      The decisions made by configure later in the script may depend upon the
      linker used. Consequently, it is important that configure uses the same
      linker as GHC will eventually use.
      
      For instance, on Nix I found that a program requiring `libpthread` would
      link fine with only `-lrt` when linked with BFD ld. However, with gold
      we needed to explicitly provide the `-lpthread` dependency. Presumably
      the former would happily loaded any `NEEDED` libraries whereas the
      latter wants them explicitly given. Regardless, since `configure`'s
      `NEED_PTHREAD_LIB` check didn't use the `-fuse-ld` flag that GHC would
      eventually use, we inferred the wrong value, resulting in link errors
      later in the build.
      
      Test Plan: Validate
      
      Reviewers: austin, hvr
      
      Subscribers: rwbarton, thomie, erikd
      
      GHC Trac Issues: #13541
      
      Differential Revision: https://phabricator.haskell.org/D3694
      960918bd
  25. Jun 29, 2017
    • Ben Gamari's avatar
      configure: Coerce gcc to use $LD instead of system default · 625143f4
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      The configure script will now try to coerce gcc to use the linker
      pointed to by $LD instead of the system default (typically bfd ld).
      Moreover, we now check for `ld.gold` and `ld.lld` before trying `ld`.
      
      The previous behavior can be reverted to by using the new
      --disable-ld-override flag.
      
      On my machine gold seems to trigger an apparent infelicity in
      constructor behavior, causing T5435_asm to fail. I've opened #13883 to
      record this issue and have accepted the questionable constructor
      ordering for the time being.
      
      Test Plan: Validate with `config_args='--enable-ld-override'`
      
      Reviewers: austin, hvr, simonmar
      
      Subscribers: duog, nh2, rwbarton, thomie, erikd, snowleopard
      
      GHC Trac Issues: #13541, #13810, #13883
      
      Differential Revision: https://phabricator.haskell.org/D3449
      625143f4
  26. May 11, 2017
    • Moritz Angermann's avatar
      Do not hardcode the specific linker to use · 5ddb307e
      Moritz Angermann authored
      This should be handled appropriately by a wrapper script around the compiler,
      if one wants to insist on the specific linker to be used.  Otherwise this
      breaks if the used compiler fails to understand this directive.
      
      I believe that using a specific linker should be part of the compilers
      toolchain, we delegate to and not hardcoded here in ghc.
      
      Reviewers: dfeuer, erikd, hvr, austin, rwbarton, bgamari
      
      Reviewed By: bgamari
      
      Subscribers: snowleopard, davean, dfeuer, thomie, erikd
      
      Differential Revision: https://phabricator.haskell.org/D3351
      5ddb307e
  27. Apr 25, 2017
  28. Nov 11, 2016
    • Ben Gamari's avatar
      Pass -no-pie to GCC · d421a7e2
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      Certain distributions (e.g. Debian and Ubuntu) have enabled PIE be
      default in their GCC packaging. This breaks our abuse of GCC as a linker
      which requires that we pass -Wl,-r, which is incompatible with
      PIE (since the former implies that we are generating a relocatable
      object file and the latter an executable).
      
      This is a second attempt at D2691. This attempt constrasts with D2691 in that
      it preserves the "does gcc support -no-pie" flag in settings, allowing this to
      be reconfigured by `configure` during installation of a binary distribution.
      Thanks for @rwbarton for drawing attention to this issue.
      
      Test Plan: Validate
      
      Reviewers: austin, hvr, erikd
      
      Reviewed By: erikd
      
      Subscribers: thomie, rwbarton, erikd
      
      Differential Revision: https://phabricator.haskell.org/D2693
      
      GHC Trac Issues: #12759
      d421a7e2
    • Ben Gamari's avatar
      Revert "Pass -no-pie to GCC" · 60bb9d1c
      Ben Gamari authored
      This reverts commit bae4a55b.
      
      This will be superceded by D2693.
      60bb9d1c
  29. Nov 10, 2016
    • Ben Gamari's avatar
      Pass -no-pie to GCC · bae4a55b
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      Certain distributions (e.g. Debian and Ubuntu) have enabled PIE be
      default in their GCC packaging. This breaks our abuse of GCC as a linker
      which requires that we pass -Wl,-r, which is incompatible with
      PIE (since the former implies that we are generating a relocatable
      object file and the latter an executable).
      
      Test Plan: Validate
      
      Reviewers: hvr, austin
      
      Subscribers: rwbarton, thomie, erikd
      
      Differential Revision: https://phabricator.haskell.org/D2691
      
      GHC Trac Issues: #12759
      bae4a55b
  30. Sep 05, 2016
    • Ben Gamari's avatar
      distrib: Fix libdw bindist check · 05b497ec
      Ben Gamari authored and Ben Gamari's avatar Ben Gamari committed
      As reported in #12555 this code was terribly broken. Sadly, Autoconf was
      none-the-wiser. Thanks to @rwbarton for pointing this out.
      
      Test Plan: Test with libdw version newer and older and 0.158
      
      Reviewers: hvr, austin, rwbarton
      
      Reviewed By: rwbarton
      
      Subscribers: thomie, rwbarton, erikd
      
      Differential Revision: https://phabricator.haskell.org/D2510
      
      GHC Trac Issues: #12555
      05b497ec
  31. Jun 14, 2016
  32. May 31, 2016
  33. Apr 16, 2016
    • Herbert Valerio Riedel's avatar
      Rework CC/CC_STAGE0 handling in `configure.ac` · 865602e0
      Herbert Valerio Riedel authored and Ben Gamari's avatar Ben Gamari committed
      Rather than using the non-standard/idiomatic `--with-{gcc,clang}=...`
      scheme use the `CC=...` style scheme.
      
      The basic idea is to have Autoconf's CC/CFLAG/CPPFLAG apply to
      stage{1,2,3}, while having a separate _STAGE0 set of env-vars
      denote the bootstrap-toolchain flags/programs.
      
      This should be simpler, less confusing, and somewhat more in line with
      Autoconf's idioms (allowing us to reuse more of Autoconf rather than
      (re)inventing our own confusing non-standard m4 macros to do stuff that
      Autoconf could almost do already for us)
      
      Morever, expose CC_STAGE0 as a so-called "precious" variable.
      
      So now we can better control which bootstrapping gcc is used
      (by default the one used by the stage0 ghc, unless CC_STAGE0 is
      overriden)
      
      ```
      Some influential environment variables:
        CC_STAGE0   C compiler command (bootstrap)
        CC          C compiler command
        CFLAGS      C compiler flags
        ...
      
      Use these variables to override the choices made by `configure' or to
      help it to find libraries and programs with nonstandard names/locations.
      ```
      
      Test Plan: I've tested that cross-compiling with
      `--target=powerpc-linux-gnu` still works, and tried a few variants of
      settting `CC=` and `CC_STAGE0=`; `./validate` passed as well
      
      Reviewers: erikd, austin, bgamari, simonmar
      
      Reviewed By: simonmar
      
      Subscribers: Phyx, thomie
      
      Differential Revision: https://phabricator.haskell.org/D2078
      865602e0
  34. Apr 15, 2016
  35. Mar 28, 2016
    • Herbert Valerio Riedel's avatar
      Autoconf: detect and set CFLAGS/CPPFLAGS needed for C99 mode · afc48f89
      Herbert Valerio Riedel authored
      This is the first phase of addressing #11757 which aims to make C99
      support a base-line requirement for GHC and clean up the code-base to
      use C99 facilities when sensible.
      
      This patch exploits the logic/heuristic used by `AC_PROG_CC_C99` to
      determine the flags needed in case the C compiler isn't able to compile
      C99 code in its current mode. We can't use `AC_PROG_CC_C99` directly
      though because GHC's build-system expects CC to contain a filename
      without any flags, while `AC_PROG_CC_C99` would e.g. result in
      `CC="gcc -std=gnu99"`. Morever, we support different `CC`s for
      stage0/1/2, so we need a version of `AC_PROG_CC_C99` for which we can
      specify the `CC`/`CFLAGS` variables to operate on. This is what
      `FP_SET_CFLAGS_C99` does.
      
      Note that Clang has been defaulting to C99+ for a long time, while GCC 5
      defaults to C99+ as well. So this has mostly an affect on older GCCs
      versions prior to 5.0 and possibly compilers other than GCC/Clang (which
      are not officially supported for building GHC anyway).
      
      Reviewers: kgardas, erikd, bgamari, austin
      
      Reviewed By: erikd
      
      Differential Revision: https://phabricator.haskell.org/D2045
      afc48f89
  36. Feb 07, 2016
  37. Jan 08, 2016
Loading