ghc.git
5 years agoAllow unregisterised ghc-8.4 to build newer GHC
Debian Haskell Group [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
Allow unregisterised ghc-8.4 to build newer GHC

Commit 4075656e8bb introduced a regression stopping existing unregisteristed
compilers from being able to compile newer versions of GHC. The problem is
that the bootstrap compiler uses the newer `rts/storage/ClosureTypes.h` file
where some defines have been renamed, resulting in the following error:
.
  error: ‘stg_MUT_ARR_PTRS_FROZEN0_info’ undeclared (first use in this function); did you mean ‘stg_MUT_ARR_PTRS_FROZEN_DIRTY_info’?
.
 For more information, see https://gitlab.haskell.org/ghc/ghc/issues/15913.
.
 This patch can be removed, once ghc-8.4 is no longer the bootstrap compiler.
Author: Ilias Tsitsimpis <iliastsi@debian.org>
Bug: https://gitlab.haskell.org/ghc/ghc/issues/15913
Bug-Debian: https://bugs.debian.org/932941

Gbp-Pq: Name fix-build-using-unregisterized-v8.4

5 years agolocal-mathjax
Debian Haskell Group [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
local-mathjax

Gbp-Pq: Name local-mathjax

5 years agoAdd kfreebsdgnu to GHC_CONVERT_OS in aclocal.m4
Svante Signell [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
Add kfreebsdgnu to GHC_CONVERT_OS in aclocal.m4

Bug-Debian: https://bugs.debian.org/913140

Gbp-Pq: Name kfreebsd-aclocal.m4

5 years agoadd_-latomic_to_ghc-prim
Debian Haskell Group [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
add_-latomic_to_ghc-prim

commit ce3897ffd6e7c8b8f36b8e920168bac8c7f836ae
Author: Ilias Tsitsimpis <iliastsi@debian.org>
Date:   Tue Sep 18 17:45:17 2018 +0200

    Fix check whether GCC supports __atomic_ builtins

    Summary:
    C11 atomics are never used because:

    * The program used for checking whether GCC supports
    __atomic_ builtins fails with the following error:

    ```
      error: size mismatch in argument 2 of `__atomic_load`
       int test(int *x) { int y; __atomic_load(&x, &y, __ATOMIC_SEQ_CST); return x; }
    ```

    * There is a typo when checking if CONF_GCC_SUPPORTS__ATOMICS equals YES,
    resulting in PRIM_CFLAGS and PRIM_EXTRA_LIBRARIES never being set.

    Reviewers: bgamari

    Reviewed By: bgamari

    Subscribers: rwbarton, erikd, carter

    Differential Revision: https://phabricator.haskell.org/D5154

Gbp-Pq: Name add_-latomic_to_ghc-prim

5 years agofix osReserveHeapMemory block alignment
Sergei Trofimovich [Wed, 18 Jul 2018 21:36:58 +0000 (22:36 +0100)]
fix osReserveHeapMemory block alignment

X-Git-Url: https://git.haskell.org/ghc.git/commitdiff_plain/e175aaf6918bb2b497b83618dc4c270a0d231a1c

fix osReserveHeapMemory block alignment

Before the change osReserveHeapMemory() attempted
to allocate chunks of memory via osTryReserveHeapMemory()
not multiple of MBLOCK_SIZE in the following fallback code:

```
    if (at == NULL) {
        *len -= *len / 8;
```

and caused assertion failure:

```
$ make fulltest TEST=T11607 WAY=threaded1
T11607: internal error: ASSERTION FAILED: file rts/posix/OSMem.c, line 457
    (GHC version 8.7.20180716 for riscv64_unknown_linux)

```

The change applies alignment mask before each MBLOCK allocation attempt
and fixes WAY=threaded1 test failures on qemu-riscv64.

Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
Test Plan: run 'make fulltest WAY=threaded1'

Reviewers: simonmar, bgamari, erikd

Reviewed By: simonmar

Subscribers: rwbarton, thomie, carter

Differential Revision: https://phabricator.haskell.org/D4982

Gbp-Pq: Name e175aaf6918bb2b497b83618dc4c270a0d231a1c.patch

5 years agodriver: skip -Bsymbolic on unregisterised targets
Debian Haskell Group [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
driver: skip -Bsymbolic on unregisterised targets

Trac #15338 is yet another example where -Bsymbolic breaks
semantics of a C program: global variable duplication happens
and unsafePerformIO creates two stdout copies.

When -Bsymbolic is not used both C compiler and linker agree
on how global variables are handled. In case of sh4 it consists
on a few assertions:

1. global variable is exported from shared library
2. code is referred to this variable via GOT-like mechanism to allow
   interposition
3. global variable is present .bss section on an executable
   (as an R_*_COPY relocation: symbol contents is copied at executable
   startup time)
4. and symbol in executable interposes symbol in shared library.

This way both code in shared library and code in executable refer
to a copy of global variable in .bss section of an executable.

Unfortunately -Bsymbolic option breaks assumption [2.] and generates
direct references to the symbol. This causes mismatch between
values seen from executable and values seen from shared library code.

This change disables '-Bsymbolic' for unregisterised targets.

Gbp-Pq: Name bsymbolic-only-for-registerised.patch

5 years agowith new ghc 8.4.3, the armel situation seems to have improved,
Debian Haskell Group [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
with new ghc 8.4.3, the armel situation seems to have improved,

apply this patch unconditionally.
===================================================================

Gbp-Pq: Name llvm-arm-unknown-linux-gnueabi.patch

5 years agoUse the stage1 binaries for install
John Paul Adrian Glaubitz [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
Use the stage1 binaries for install

Last-Update: 2017-01-29

In order to be able to perform a cross-build, we need to use
the stage1 binaries during installation. Both ghc and ghc-pkg
are run during the install target and therefore must be able
to run on the build machine.

Gbp-Pq: Name use-stage1-binaries-for-install.patch

5 years agoUse native x86_64 instructions on x32
Debian Haskell Group [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
Use native x86_64 instructions on x32

This patch enables a few native 64-bit integer instructions
on x32 which are available on this architecture despite using
32-bit pointers. These instructions are present on x86_64 but
not on x86 and ghc checks the size of (void *) to determine
that. This method fails on x32 since despite using 32-bit
pointers and hence sizeof(void *) == 4, it still uses the
full x86_64 instruction set and software-emulated variants
of the aforementioned 64-bit integer instructions are
therefore not present in the toolchain which will make ghc
fail to build on x32.
See: https://ghc.haskell.org/trac/ghc/ticket/11571

Gbp-Pq: Name x32-use-native-x86_64-insn.patch

5 years agobuildpath-abi-stability
Debian Haskell Group [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
buildpath-abi-stability

Forwarded to https://ghc.haskell.org/trac/ghc/ticket/10424

Forwarded to https://ghc.haskell.org/trac/ghc/ticket/10424

Gbp-Pq: Name buildpath-abi-stability.patch

5 years agoDo not emit a warning if the .haddock file is missing
Joachim Breitner [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
Do not emit a warning if the .haddock file is missing

As it is quite common on Debian installations to install the -dev package
without the -doc package.

Gbp-Pq: Name no-missing-haddock-file-warning

5 years agoUse VFPv3-D16 FPU for ARM builds
Jani Monoses [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
Use VFPv3-D16 FPU for ARM builds

Upstream-Bug: https://ghc.haskell.org/trac/ghc/ticket/5914
Launchpad-Bug: https://ghc.haskell.org/trac/ghc/ticket/5914

Jani writes: The D16 part was Debian/Ubuntu specific, IIRC we define hardfloat
in that particular variant (16 double registers) or we had a different naming
for some reason.

Gbp-Pq: Name ARM-VFPv3D16

5 years agouse-debian-gen_contents_index
Debian Haskell Group [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
use-debian-gen_contents_index

===================================================================

Gbp-Pq: Name use-debian-gen_contents_index

5 years agoghc (8.8.1+dfsg1+is+8.6.5+dfsg1-3) unstable; urgency=medium
Sandro Tosi [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
ghc (8.8.1+dfsg1+is+8.6.5+dfsg1-3) unstable; urgency=medium

  * Switch to python3-sphinx; Closes: #943097

[dgit import unpatched ghc 8.8.1+dfsg1+is+8.6.5+dfsg1-3]

5 years agoImport ghc_8.8.1+dfsg1+is+8.6.5+dfsg1-3.debian.tar.xz
Sandro Tosi [Tue, 24 Mar 2020 01:50:31 +0000 (01:50 +0000)]
Import ghc_8.8.1+dfsg1+is+8.6.5+dfsg1-3.debian.tar.xz

[dgit import tarball ghc 8.8.1+dfsg1+is+8.6.5+dfsg1-3 ghc_8.8.1+dfsg1+is+8.6.5+dfsg1-3.debian.tar.xz]

6 years agoImport ghc_8.8.1+dfsg1+is+8.6.5+dfsg1.orig.tar.xz
Gianfranco Costamagna [Thu, 12 Sep 2019 06:25:57 +0000 (07:25 +0100)]
Import ghc_8.8.1+dfsg1+is+8.6.5+dfsg1.orig.tar.xz

[dgit import orig ghc_8.8.1+dfsg1+is+8.6.5+dfsg1.orig.tar.xz]