This is a followup to 2073b55e6b.
* gnu/build/cross-toolchain.scm (%gcc-include-paths): Switch back to
'C_INCLUDE_PATH' & co.
* gnu/packages/cross-base.scm (%gcc-include-paths): Likewise.
(cross-gcc-arguments): Remove 'treat-glibc-as-system-header' phase.
(cross-gcc)[native-inputs]: Reorder so that libc comes last.
[search-paths]: Add "include/c++" for 'CROSS_CPLUS_INCLUDE_PATH'.
* guix/build-system/gnu.scm (standard-cross-packages): Have "cross-gcc"
appear both for 'host and 'target.
This patch parameterizes previously hard-coded instances of
i686-w64-mingw32, adding support for x86_64-w64-mingw32.
* gnu/packages/mingw.scm (make-mingw-w64): New procedure.
(mingw-w64-i686, mingw-w64-x86_64): New variables.
(%mingw-triplet): Remove.
(mingw-w64): Update to point to 'mingw-w64-i686'.
* gnu/packages/cross-base.scm (cross-gcc): Use 'libc' keyword argument
if specified, instead of treating it as a boolean.
(native-libc): Return the correct mingw-w64 depending on machine
specified in target.
* gnu/packages/bootstrap.scm (glibc-dynamic-linker): Add "x86_64-mingw".
* gnu/build/cross-toolchain.scm (set-cross-path/mingw): Replace
hardcoded 'i686-w64-mingw32' instances with 'target' keyword argument.
(cross-gcc-build-phases): Update accordingly; use 'target-mingw?'
implementation of target checking and add commentary.
* gnu/ci.scm (%cross-targets): Add "x86_64-w64-mingw32".
This makes sure it is inherited by packages using (cross-gcc ...). This
commit is a followup to 01e8263feb.
* gnu/build/cross-toolchain.scm (cross-gcc-build-phases): Move
'treat-glibc-as-system-header' phase ...
* gnu/packages/cross-base.scm (cross-gcc-arguments): ... here.
* gnu/packages/cross-base.scm (%gcc-cross-include-paths): Remove
CROSS_C_INCLUDE_PATH & co in favor of CROSS_CPATH.
* gnu/build/cross-toolchain.scm (%gcc-cross-include-paths): Likewise.
(cross-gcc-build-phases): Set CROSS_C_INCLUDE_PATH and
CROSS_CPLUS_INCLUDE_PATH when building the cross GCC.
* gnu/packages/commencement.scm (libstdc++): Add
"--disable-libstdcxx-dual-abi" to #:configure-flags.
(gcc-boot0)[arguments]: Add "--disable-libmpx"
to #:configure-flags.
(gcc-final): Add phase to set C_INCLUDE_PATH and CPLUS_INCLUDE_PATH before
building GCC.
(gcc-toolchain-5): Use MAKE-GCC-TOOLCHAIN.
(gcc-toolchain-7): Change to GCC-TOOLCHAIN.
* gnu/packages/gcc.scm (gcc): Change from GCC-5 to GCC-7.
(gfortran): Change to GFORTRAN-7.
(gcc-objc): Change to GCC-OBJC-7.
(gcc-objc++): Change to GCC-OBJC++-7.
* gnu/packages/rust.scm (rust-1.19.0)[native-search-paths]: Change from
C_INCLUDE_PATH & co to CPATH.
* gnu/packages/cross-base.scm (cross-gcc-arguments) <#:phases>: Use
'cross-gcc-build-phases', and move body cross-toolchain.scm.
(cross-gcc): Add #:imported-modules. Add (gnu build cross-toolchain) to
#:modules.
* gnu/build/cross-toolchain.scm: New file, with code from
'cross-gcc-arguments'.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.