mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-24 10:10:37 +03:00
remove local pic flags, now set by hardened stdenv
This commit is contained in:
parent
8329066d5e
commit
acb408646e
15 changed files with 3 additions and 32 deletions
|
@ -8,8 +8,6 @@ stdenv.mkDerivation rec {
|
||||||
sha256 = "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2";
|
sha256 = "0czccp4fcpf2ykp16xcrzdfmnircz1ynhls334q374xknd5747d2";
|
||||||
};
|
};
|
||||||
|
|
||||||
NIX_CFLAGS_COMPILE = "-fpic";
|
|
||||||
|
|
||||||
# From Handbrake
|
# From Handbrake
|
||||||
patches = [
|
patches = [
|
||||||
./A00-a52-state-t-public.patch
|
./A00-a52-state-t-public.patch
|
||||||
|
|
|
@ -12,7 +12,6 @@ stdenv.mkDerivation rec {
|
||||||
buildInputs = [ texinfo allegro perl ];
|
buildInputs = [ texinfo allegro perl ];
|
||||||
|
|
||||||
configurePhase = ''
|
configurePhase = ''
|
||||||
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -fPIC"
|
|
||||||
sh fix.sh unix
|
sh fix.sh unix
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
|
|
@ -41,8 +41,6 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
preInstall = "mkdir -p $out/{bin,lib,man/man1,man/man3,include/gsm}";
|
preInstall = "mkdir -p $out/{bin,lib,man/man1,man/man3,include/gsm}";
|
||||||
|
|
||||||
NIX_CFLAGS_COMPILE = optional (!staticSupport) "-fPIC";
|
|
||||||
|
|
||||||
parallelBuild = false;
|
parallelBuild = false;
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
|
|
|
@ -16,8 +16,6 @@ stdenv.mkDerivation rec {
|
||||||
patchPhase = ''patchShebangs .'';
|
patchPhase = ''patchShebangs .'';
|
||||||
buildInputs = [ perl zlib ];
|
buildInputs = [ perl zlib ];
|
||||||
|
|
||||||
makeFlags = "CFLAGS=-fPIC";
|
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
description = "Hebrew spell checker";
|
description = "Hebrew spell checker";
|
||||||
homepage = http://hspell.ivrix.org.il/;
|
homepage = http://hspell.ivrix.org.il/;
|
||||||
|
|
|
@ -12,7 +12,6 @@ stdenv.mkDerivation rec {
|
||||||
"-DBUILD_TESTING=OFF"
|
"-DBUILD_TESTING=OFF"
|
||||||
"-DBUILD_EXAMPLES=OFF"
|
"-DBUILD_EXAMPLES=OFF"
|
||||||
"-DBUILD_SHARED_LIBS=ON"
|
"-DBUILD_SHARED_LIBS=ON"
|
||||||
"-DCMAKE_CXX_FLAGS=-fPIC"
|
|
||||||
];
|
];
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
|
@ -12,8 +12,6 @@ stdenv.mkDerivation {
|
||||||
|
|
||||||
buildInputs = [ automake autoconf libtool ];
|
buildInputs = [ automake autoconf libtool ];
|
||||||
|
|
||||||
CFLAGS="-fPIC";
|
|
||||||
|
|
||||||
# .so endings are missing (quick and dirty fix)
|
# .so endings are missing (quick and dirty fix)
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
for i in $out/lib/*; do
|
for i in $out/lib/*; do
|
||||||
|
|
|
@ -22,7 +22,6 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
propagatedBuildInputs = [ xz ];
|
propagatedBuildInputs = [ xz ];
|
||||||
|
|
||||||
NIX_CFLAGS_COMPILE = if stdenv.system == "x86_64-linux" then "-fPIC" else "";
|
|
||||||
preInstall = ''
|
preInstall = ''
|
||||||
mkdir -p "$out/lib"
|
mkdir -p "$out/lib"
|
||||||
touch "$out/lib/libunwind-generic.so"
|
touch "$out/lib/libunwind-generic.so"
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ stdenv, fetchurl, cmake, boost, makePIC ? false }:
|
{ stdenv, fetchurl, cmake, boost }:
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
name = "libyaml-cpp-0.5.1";
|
name = "libyaml-cpp-0.5.1";
|
||||||
|
@ -10,8 +10,6 @@ stdenv.mkDerivation {
|
||||||
|
|
||||||
buildInputs = [ cmake boost ];
|
buildInputs = [ cmake boost ];
|
||||||
|
|
||||||
cmakeFlags = stdenv.lib.optionals makePIC [ "-DCMAKE_C_FLAGS=-fPIC" "-DCMAKE_CXX_FLAGS=-fPIC" ];
|
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
homepage = http://code.google.com/p/yaml-cpp/;
|
homepage = http://code.google.com/p/yaml-cpp/;
|
||||||
description = "A YAML parser and emitter for C++";
|
description = "A YAML parser and emitter for C++";
|
||||||
|
|
|
@ -20,8 +20,6 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake pkgconfig ];
|
nativeBuildInputs = [ cmake pkgconfig ];
|
||||||
|
|
||||||
NIX_CFLAGS_COMPILE = "-fPIC";
|
|
||||||
|
|
||||||
cmakeFlags = [
|
cmakeFlags = [
|
||||||
"-DCMAKE_BUILD_TYPE=${if debug then "Debug" else "Release"}"
|
"-DCMAKE_BUILD_TYPE=${if debug then "Debug" else "Release"}"
|
||||||
"-DPHONON_BUILD_PHONON4QT5=ON"
|
"-DPHONON_BUILD_PHONON4QT5=ON"
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
{ fetchurl, stdenv, mesa, freeglut, SDL
|
{ fetchurl, stdenv, mesa, freeglut, SDL
|
||||||
, libXi, libSM, libXmu, libXext, libX11,
|
, libXi, libSM, libXmu, libXext, libX11 }:
|
||||||
enablePIC ? false }:
|
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "plib-1.8.5";
|
name = "plib-1.8.5";
|
||||||
|
@ -13,8 +12,6 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
patches = [ ./CVE-2012-4552.patch ];
|
patches = [ ./CVE-2012-4552.patch ];
|
||||||
|
|
||||||
NIX_CFLAGS_COMPILE = if enablePIC then "-fPIC" else "";
|
|
||||||
|
|
||||||
propagatedBuildInputs = [
|
propagatedBuildInputs = [
|
||||||
mesa freeglut SDL
|
mesa freeglut SDL
|
||||||
|
|
||||||
|
|
|
@ -73,14 +73,10 @@ stdenv.mkDerivation {
|
||||||
configureScript=../configure
|
configureScript=../configure
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# * -fPIC is passed even in non-shared builds so that the ATLAS code can be
|
|
||||||
# used to inside of shared libraries, like Octave does.
|
|
||||||
#
|
|
||||||
# * -t 0 disables use of multi-threading. It's not quite clear what the
|
# * -t 0 disables use of multi-threading. It's not quite clear what the
|
||||||
# consequences of that setting are and whether it's necessary or not.
|
# consequences of that setting are and whether it's necessary or not.
|
||||||
configureFlags = [
|
configureFlags = [
|
||||||
"-Fa alg"
|
"-Fa alg"
|
||||||
"-fPIC"
|
|
||||||
"-t ${threads}"
|
"-t ${threads}"
|
||||||
cpuConfig
|
cpuConfig
|
||||||
] ++ optional shared "--shared"
|
] ++ optional shared "--shared"
|
||||||
|
|
|
@ -33,8 +33,6 @@ stdenv.mkDerivation {
|
||||||
"LAPACK="
|
"LAPACK="
|
||||||
];
|
];
|
||||||
|
|
||||||
NIX_CFLAGS = "-fPIC";
|
|
||||||
|
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
# Build and install shared library
|
# Build and install shared library
|
||||||
(
|
(
|
||||||
|
|
|
@ -31,8 +31,7 @@ stdenv.mkDerivation (rec {
|
||||||
|
|
||||||
# As zlib takes part in the stdenv building, we don't want references
|
# As zlib takes part in the stdenv building, we don't want references
|
||||||
# to the bootstrap-tools libgcc (as uses to happen on arm/mips)
|
# to the bootstrap-tools libgcc (as uses to happen on arm/mips)
|
||||||
NIX_CFLAGS_COMPILE = stdenv.lib.optionalString (!stdenv.isDarwin) "-static-libgcc "
|
NIX_CFLAGS_COMPILE = stdenv.lib.optionalString (!stdenv.isDarwin) "-static-libgcc";
|
||||||
+ stdenv.lib.optionalString (stdenv.isFreeBSD) "-fPIC";
|
|
||||||
|
|
||||||
crossAttrs = {
|
crossAttrs = {
|
||||||
dontStrip = static;
|
dontStrip = static;
|
||||||
|
|
|
@ -20,8 +20,6 @@ stdenv.mkDerivation rec {
|
||||||
--replace /usr/local $out
|
--replace /usr/local $out
|
||||||
'';
|
'';
|
||||||
|
|
||||||
NIX_CFLAGS_COMPILE = "-fPIC";
|
|
||||||
|
|
||||||
buildPhase = ''scons'';
|
buildPhase = ''scons'';
|
||||||
|
|
||||||
installPhase = ''scons install'';
|
installPhase = ''scons install'';
|
||||||
|
|
|
@ -15,8 +15,6 @@ stdenv.mkDerivation rec {
|
||||||
--replace '"-DSAFER"' '"-DPARANOIDSAFER"'
|
--replace '"-DSAFER"' '"-DPARANOIDSAFER"'
|
||||||
'';
|
'';
|
||||||
|
|
||||||
NIX_CFLAGS_COMPILE = "-fPIC"; # Gentoo adds this on every platform
|
|
||||||
|
|
||||||
buildInputs =
|
buildInputs =
|
||||||
[ pkgconfig flex zlib perl libpng libjpeg libxml2 makeWrapper libtiff ]
|
[ pkgconfig flex zlib perl libpng libjpeg libxml2 makeWrapper libtiff ]
|
||||||
++ lib.optional enableX11 libX11;
|
++ lib.optional enableX11 libX11;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue