Unverified Commit b275c083 authored by Sandro Jäckel's avatar Sandro Jäckel Committed by GitHub
Browse files

Merge pull request #144832 from r-burns/i686-lto

parents 1442afd8 c9d935da
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -13,8 +13,6 @@ stdenv.mkDerivation {

  postPatch = ''
    substituteInPlace Makefile --replace "--static" ""
  '' + lib.optionalString stdenv.isi686 ''
    substituteInPlace Makefile --replace "-flto" ""
  '';

  installPhase = ''
+0 −4
Original line number Diff line number Diff line
@@ -30,10 +30,6 @@ edk2.mkDerivation projectDscPath {

  hardeningDisable = [ "format" "stackprotector" "pic" "fortify" ];

  # Fails on i686 with:
  # 'cc1: error: LTO support has not been enabled in this configuration'
  NIX_CFLAGS_COMPILE = lib.optionals stdenv.isi686 [ "-fno-lto" ];

  buildFlags =
    lib.optionals secureBoot [ "-D SECURE_BOOT_ENABLE=TRUE" ]
    ++ lib.optionals csmSupport [ "-D CSM_ENABLE" "-D FD_SIZE_2MB" ]
+0 −3
Original line number Diff line number Diff line
@@ -65,9 +65,6 @@ in stdenv.mkDerivation rec {

  cmakeDir = "../drivers/xgl";

  # LTO is disabled in gcc for i686 as of #66528
  cmakeFlags = lib.optionals stdenv.is32bit ["-DXGL_ENABLE_LTO=OFF"];

  installPhase = ''
    install -Dm755 -t $out/lib icd/amdvlk${suffix}.so
    install -Dm644 -t $out/share/vulkan/icd.d icd/amd_icd${suffix}.json
+0 −6
Original line number Diff line number Diff line
@@ -15,12 +15,6 @@ stdenv.mkDerivation rec {
    sha256 = "sha256-vUhP71vZ5XFG7MDkPFpAcCUL4kIdzHJ1hAkwqIi6ksQ=";
  };

  # We have no LTO on i686 since commit 22284b0
  postPatch = lib.optionalString stdenv.isi686 ''
    substituteInPlace chelper/__init__.py \
      --replace "-flto -fwhole-program " ""
  '';

  sourceRoot = "source/klippy";

  # there is currently an attempt at moving it to Python 3, but it will remain
+0 −2
Original line number Diff line number Diff line
@@ -22,8 +22,6 @@ stdenv.mkDerivation rec {
      sha256 = "1sbijvlpv4khkix3vix9mbhzffj8lp8zpnbxm9gnzjz8yssz9p5h";
    })
  ];
  # We have no LTO here since commit 22284b07.
  postPatch = if stdenv.isi686 then "sed '/^CFLAGS/s/-flto//' -i Make.defaults" else null;

  makeFlags = [ "EFIDIR=nixos" "PKG_CONFIG=${stdenv.cc.targetPrefix}pkg-config" ];

Loading