Merge pull request #78806 from nh2/issue-78805-glibc-musl-gcc-9-build-error

glibc: Fix build error due to warning with musl
This commit is contained in:
Niklas Hambüchen 2020-01-30 04:49:19 +01:00 committed by GitHub
commit 01dfd41455
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -54,9 +54,10 @@ callPackage ./common.nix { inherit stdenv; } {
# Fix -Werror build failure when building glibc with musl with GCC >= 8, see:
# https://github.com/NixOS/nixpkgs/pull/68244#issuecomment-544307798
(stdenv.lib.optional stdenv.hostPlatform.isMusl "-Wno-error=attribute-alias")
(stdenv.lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
(stdenv.lib.optionals ((stdenv.hostPlatform != stdenv.buildPlatform) || stdenv.hostPlatform.isMusl) [
# Ignore "error: '__EI___errno_location' specifies less restrictive attributes than its target '__errno_location'"
# New warning as of GCC 9
# Same for musl: https://github.com/NixOS/nixpkgs/issues/78805
"-Wno-error=missing-attributes"
])
]);