erlang: patch all versions to work with clang 4
This commit is contained in:
parent
0cf93fda07
commit
5a81c66906
@ -27,6 +27,11 @@ stdenv.mkDerivation rec {
|
|||||||
++ optional odbcSupport unixODBC
|
++ optional odbcSupport unixODBC
|
||||||
++ optionals stdenv.isDarwin [ Carbon Cocoa ];
|
++ optionals stdenv.isDarwin [ Carbon Cocoa ];
|
||||||
|
|
||||||
|
# Clang 4 (rightfully) thinks signed comparisons of pointers with NULL are nonsense
|
||||||
|
prePatch = ''
|
||||||
|
substituteInPlace lib/wx/c_src/wxe_impl.cpp --replace 'temp > NULL' 'temp != NULL'
|
||||||
|
'';
|
||||||
|
|
||||||
patchPhase = '' sed -i "s@/bin/rm@rm@" lib/odbc/configure erts/configure '';
|
patchPhase = '' sed -i "s@/bin/rm@rm@" lib/odbc/configure erts/configure '';
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
|
@ -29,6 +29,11 @@ stdenv.mkDerivation rec {
|
|||||||
++ optional odbcSupport [ unixODBC ]
|
++ optional odbcSupport [ unixODBC ]
|
||||||
++ optionals stdenv.isDarwin [ Carbon Cocoa ];
|
++ optionals stdenv.isDarwin [ Carbon Cocoa ];
|
||||||
|
|
||||||
|
# Clang 4 (rightfully) thinks signed comparisons of pointers with NULL are nonsense
|
||||||
|
prePatch = ''
|
||||||
|
substituteInPlace lib/wx/c_src/wxe_impl.cpp --replace 'temp > NULL' 'temp != NULL'
|
||||||
|
'';
|
||||||
|
|
||||||
patchPhase = '' sed -i "s@/bin/rm@rm@" lib/odbc/configure.in erts/configure.in '';
|
patchPhase = '' sed -i "s@/bin/rm@rm@" lib/odbc/configure.in erts/configure.in '';
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
|
@ -35,7 +35,12 @@ stdenv.mkDerivation rec {
|
|||||||
++ optional javacSupport openjdk
|
++ optional javacSupport openjdk
|
||||||
++ stdenv.lib.optionals stdenv.isDarwin [ Carbon Cocoa ];
|
++ stdenv.lib.optionals stdenv.isDarwin [ Carbon Cocoa ];
|
||||||
|
|
||||||
patchPhase = '' sed -i "s@/bin/rm@rm@" lib/odbc/configure erts/configure '';
|
patchPhase = ''
|
||||||
|
# Clang 4 (rightfully) thinks signed comparisons of pointers with NULL are nonsense
|
||||||
|
substituteInPlace lib/wx/c_src/wxe_impl.cpp --replace 'temp > NULL' 'temp != NULL'
|
||||||
|
|
||||||
|
sed -i "s@/bin/rm@rm@" lib/odbc/configure erts/configure
|
||||||
|
'';
|
||||||
|
|
||||||
debugInfo = enableDebugInfo;
|
debugInfo = enableDebugInfo;
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ stdenv, fetchurl, fetchFromGitHub, perl, gnum4, ncurses, openssl
|
{ stdenv, fetchurl, fetchpatch, fetchFromGitHub, perl, gnum4, ncurses, openssl
|
||||||
, gnused, gawk, autoconf, libxslt, libxml2, makeWrapper
|
, gnused, gawk, autoconf, libxslt, libxml2, makeWrapper
|
||||||
, Carbon, Cocoa
|
, Carbon, Cocoa
|
||||||
, odbcSupport ? false, unixODBC ? null
|
, odbcSupport ? false, unixODBC ? null
|
||||||
@ -53,6 +53,11 @@ stdenv.mkDerivation rec {
|
|||||||
sha256 = "10h5348p6g279b4q01i5jdqlljww5chcvrx5b4b0dv79pk0p0m9f";
|
sha256 = "10h5348p6g279b4q01i5jdqlljww5chcvrx5b4b0dv79pk0p0m9f";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Clang 4 (rightfully) thinks signed comparisons of pointers with NULL are nonsense
|
||||||
|
prePatch = ''
|
||||||
|
substituteInPlace lib/wx/c_src/wxe_impl.cpp --replace 'temp > NULL' 'temp != NULL'
|
||||||
|
'';
|
||||||
|
|
||||||
patches = [
|
patches = [
|
||||||
rmAndPwdPatch
|
rmAndPwdPatch
|
||||||
envAndCpPatch
|
envAndCpPatch
|
||||||
|
@ -46,6 +46,9 @@ stdenv.mkDerivation rec {
|
|||||||
prePatch = ''
|
prePatch = ''
|
||||||
substituteInPlace configure.in \
|
substituteInPlace configure.in \
|
||||||
--replace '`sw_vers -productVersion`' '10.10'
|
--replace '`sw_vers -productVersion`' '10.10'
|
||||||
|
|
||||||
|
# Clang 4 (rightfully) thinks signed comparisons of pointers with NULL are nonsense
|
||||||
|
substituteInPlace lib/wx/c_src/wxe_impl.cpp --replace 'temp > NULL' 'temp != NULL'
|
||||||
'';
|
'';
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
|
Loading…
x
Reference in New Issue
Block a user