root5: -fpermissive fix for new compiler, patch for python312

This commit is contained in:
Dmitry Kalinkin 2024-11-17 21:54:46 -05:00
parent 7bee67400f
commit a32e0aa07c

View File

@ -121,6 +121,11 @@ stdenv.mkDerivation rec {
substituteInPlace misc/memstat/src/TMemStatHook.cxx \
--replace "defined(R__GNU) && (defined(R__LINUX) || defined(__APPLE__))" \
"defined(R__GNU) && (defined(__APPLE__))"
# python 3.12
substituteInPlace bindings/pyroot/src/PyROOT.h \
--replace " PyUnicode_GET_SIZE" " PyUnicode_GetLength" \
--replace " PyUnicode_GetSize" " PyUnicode_GetLength"
''
# Fix CINTSYSDIR for "build" version of rootcint
# This is probably a bug that breaks out-of-source builds
@ -169,6 +174,8 @@ stdenv.mkDerivation rec {
]
++ lib.optional ((!stdenv.hostPlatform.isDarwin) && (stdenv.cc.libc != null)) "-DC_INCLUDE_DIRS=${lib.getDev stdenv.cc.libc}/include";
env.NIX_CFLAGS_COMPILE = "-fpermissive";
setupHook = ./setup-hook.sh;
meta = with lib; {