diff options
author | Michael Raskin <7c6f434c@mail.ru> | 2019-05-05 19:12:12 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-05-05 19:12:12 +0000 |
commit | 7770495cd7c6431bd4b1ac6eadbae4e51479538b (patch) | |
tree | ae6489d5293cb1c74834db045accaa0dff9fdf15 /pkgs/tools/archivers | |
parent | 24debf74ef5c6e7799a5bc7edc4b2d6eae8e3c07 (diff) | |
parent | 091de095c92ab1d2932ec9dd5e810ea2575e2432 (diff) |
Merge pull request #59148 from volth/gcc.arch.v3
compilation for particular x86_64 architecture
Diffstat (limited to 'pkgs/tools/archivers')
-rw-r--r-- | pkgs/tools/archivers/zpaq/default.nix | 5 | ||||
-rw-r--r-- | pkgs/tools/archivers/zpaq/zpaqd.nix | 4 |
2 files changed, 2 insertions, 7 deletions
diff --git a/pkgs/tools/archivers/zpaq/default.nix b/pkgs/tools/archivers/zpaq/default.nix index 309604999ba..48b3a91b971 100644 --- a/pkgs/tools/archivers/zpaq/default.nix +++ b/pkgs/tools/archivers/zpaq/default.nix @@ -19,10 +19,7 @@ stdenv.mkDerivation rec { CPPFLAGS = with stdenv; "" + (lib.optionalString (!isi686 && !isx86_64) "-DNOJIT ") + "-Dunix"; - CXXFLAGS = with stdenv; "" - + (lib.optionalString isi686 "-march=i686 -mtune=generic ") - + (lib.optionalString isx86_64 "-march=nocona -mtune=generic ") - + "-O3 -DNDEBUG"; + CXXFLAGS = "-O3 -DNDEBUG"; in '' buildFlagsArray=( "CPPFLAGS=${CPPFLAGS}" "CXXFLAGS=${CXXFLAGS}" ) ''; diff --git a/pkgs/tools/archivers/zpaq/zpaqd.nix b/pkgs/tools/archivers/zpaq/zpaqd.nix index 344f0889090..611654331c3 100644 --- a/pkgs/tools/archivers/zpaq/zpaqd.nix +++ b/pkgs/tools/archivers/zpaq/zpaqd.nix @@ -11,10 +11,8 @@ let sha256="0868lynb45lm79yvx5f10lj5h6bfv0yck8whcls2j080vmk3n7rk"; }; - compileFlags = stdenv.lib.concatStringsSep " " ([ "-O3" "-mtune=generic" "-DNDEBUG" ] + compileFlags = stdenv.lib.concatStringsSep " " ([ "-O3" "-DNDEBUG" ] ++ stdenv.lib.optional (stdenv.hostPlatform.isUnix) "-Dunix -pthread" - ++ stdenv.lib.optional (stdenv.hostPlatform.isi686) "-march=i686" - ++ stdenv.lib.optional (stdenv.hostPlatform.isx86_64) "-march=nocona" ++ stdenv.lib.optional (!stdenv.hostPlatform.isx86) "-DNOJIT"); in stdenv.mkDerivation { |