mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2025-01-05 20:11:43 +03:00
root5: fix build
This commit is contained in:
parent
52dae14f0c
commit
c36f841ec7
@ -1,4 +1,4 @@
|
|||||||
{ stdenv, fetchurl, cmake, pcre, pkgconfig, python2
|
{ stdenv, fetchurl, fetchpatch, cmake, pcre, pkgconfig, python2
|
||||||
, libX11, libXpm, libXft, libXext, libGLU_combined, zlib, libxml2, lzma, gsl_1
|
, libX11, libXpm, libXft, libXext, libGLU_combined, zlib, libxml2, lzma, gsl_1
|
||||||
, Cocoa, OpenGL, cf-private, noSplash ? false }:
|
, Cocoa, OpenGL, cf-private, noSplash ? false }:
|
||||||
|
|
||||||
@ -19,11 +19,30 @@ stdenv.mkDerivation rec {
|
|||||||
|
|
||||||
patches = [
|
patches = [
|
||||||
./sw_vers_root5.patch
|
./sw_vers_root5.patch
|
||||||
|
|
||||||
|
(fetchpatch {
|
||||||
|
name = "enable_new_gcc.patch";
|
||||||
|
url = "https://aur.archlinux.org/cgit/aur.git/plain/enable_new_gcc.patch?h=root5&id=91c50876081a0af36f84ec4f0f9dba869107fa4f";
|
||||||
|
sha256 = "1rnp0xlw0yqi7mjs4w145njd79i8kkir1qik7zwicdik9axf8ygm";
|
||||||
|
})
|
||||||
|
|
||||||
|
# prevents rootcint from looking in /usr/includes and such
|
||||||
|
./purify_include_paths_root5.patch
|
||||||
|
|
||||||
|
# disable dictionary generation for stuff that includes libc headers
|
||||||
|
# our glibc requires a modern compiler
|
||||||
|
./disable_libc_dicts_root5.patch
|
||||||
];
|
];
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
patchShebangs build/unix/
|
patchShebangs build/unix/
|
||||||
ln -s ${stdenv.lib.getDev stdenv.cc.libc}/include/AvailabilityMacros.h cint/cint/include/
|
ln -s ${stdenv.lib.getDev stdenv.cc.libc}/include/AvailabilityMacros.h cint/cint/include/
|
||||||
|
''
|
||||||
|
# Fix CINTSYSDIR for "build" version of rootcint
|
||||||
|
# This is probably a bug that breaks out-of-source builds
|
||||||
|
+ ''
|
||||||
|
substituteInPlace cint/cint/src/loadfile.cxx\
|
||||||
|
--replace 'env = "cint";' 'env = "'`pwd`'/cint";'
|
||||||
'' + stdenv.lib.optionalString noSplash ''
|
'' + stdenv.lib.optionalString noSplash ''
|
||||||
substituteInPlace rootx/src/rootx.cxx --replace "gNoLogo = false" "gNoLogo = true"
|
substituteInPlace rootx/src/rootx.cxx --replace "gNoLogo = false" "gNoLogo = true"
|
||||||
'';
|
'';
|
||||||
@ -73,8 +92,5 @@ stdenv.mkDerivation rec {
|
|||||||
description = "A data analysis framework";
|
description = "A data analysis framework";
|
||||||
platforms = platforms.unix;
|
platforms = platforms.unix;
|
||||||
maintainers = with maintainers; [ veprbl ];
|
maintainers = with maintainers; [ veprbl ];
|
||||||
# needs to be adapted to work with modern glibc
|
|
||||||
# it works on darwin by impurely picking up system's libc headers
|
|
||||||
broken = stdenv.isLinux;
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,27 @@
|
|||||||
|
diff --git a/cint/ROOT/CMakeLists.txt b/cint/ROOT/CMakeLists.txt
|
||||||
|
--- a/cint/ROOT/CMakeLists.txt
|
||||||
|
+++ b/cint/ROOT/CMakeLists.txt
|
||||||
|
@@ -47,21 +47,13 @@ set(CINTSTLDLLHEADERS
|
||||||
|
${CMAKE_SOURCE_DIR}/cint/cint/lib/stdstrct/stdcxxfunc.h
|
||||||
|
)
|
||||||
|
set(CINTINCDLLNAMES
|
||||||
|
- stdfunc
|
||||||
|
+# stdfunc
|
||||||
|
# stdcxxfunc
|
||||||
|
)
|
||||||
|
set(CINTINCDLLHEADERS
|
||||||
|
- ${CMAKE_SOURCE_DIR}/cint/cint/lib/stdstrct/stdfunc.h
|
||||||
|
+# ${CMAKE_SOURCE_DIR}/cint/cint/lib/stdstrct/stdfunc.h
|
||||||
|
# ${CMAKE_SOURCE_DIR}/cint/cint/lib/stdstrct/stdcxxfunc.h
|
||||||
|
)
|
||||||
|
-if(NOT WIN32)
|
||||||
|
- set(CINTSTLDLLNAMES ${CINTSTLDLLNAMES} valarray)
|
||||||
|
- set(CINTSTLDLLHEADERS ${CINTSTLDLLHEADERS} ${CINTDLLDIR}/vary.h)
|
||||||
|
- set(CINTINCDLLNAMES ${CINTINCDLLNAMES} posix ipc)
|
||||||
|
- set(CINTINCDLLHEADERS ${CINTINCDLLHEADERS}
|
||||||
|
- ${CMAKE_SOURCE_DIR}/cint/cint/lib/posix/exten.h
|
||||||
|
- ${CMAKE_SOURCE_DIR}/cint/cint/lib/ipc/ipcif.h)
|
||||||
|
-endif()
|
||||||
|
|
||||||
|
set(CINTBUILDLOADER
|
||||||
|
vector
|
@ -0,0 +1,204 @@
|
|||||||
|
diff --git a/cint/cint/src/loadfile.cxx b/cint/cint/src/loadfile.cxx
|
||||||
|
--- a/cint/cint/src/loadfile.cxx
|
||||||
|
+++ b/cint/cint/src/loadfile.cxx
|
||||||
|
@@ -1365,92 +1365,6 @@ int G__statfilename(const char *filenamein, struct stat *statBuf,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif /* G__EDU_VERSION */
|
||||||
|
-
|
||||||
|
-#ifdef G__VISUAL
|
||||||
|
- /**********************************************
|
||||||
|
- * try /msdev/include
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- workname.Format("/msdev/include/%s%s",filename(),addpost[i2]);
|
||||||
|
- res = stat( workname, statBuf );
|
||||||
|
- if (res==0) {
|
||||||
|
- if (fullPath) fullPath->Swap(workname);
|
||||||
|
- return res;
|
||||||
|
- }
|
||||||
|
- }
|
||||||
|
-#endif /* G__VISUAL */
|
||||||
|
-
|
||||||
|
-#ifdef G__SYMANTEC
|
||||||
|
- /**********************************************
|
||||||
|
- * try /sc/include
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- workname.Format("/sc/include/%s%s",filename(),addpost[i2]);
|
||||||
|
- res = stat( workname, statBuf );
|
||||||
|
- if (res==0) {
|
||||||
|
- if (fullPath) fullPath->Swap(workname);
|
||||||
|
- return res;
|
||||||
|
- }
|
||||||
|
- }
|
||||||
|
-#endif // G__SYMANTEC
|
||||||
|
-
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- /**********************************************
|
||||||
|
- * try /usr/include/filename
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- workname.Format("/usr/include/%s%s",filename(),addpost[i2]);
|
||||||
|
- res = stat( workname, statBuf );
|
||||||
|
- if (res==0) {
|
||||||
|
- if (fullPath) fullPath->Swap(workname);
|
||||||
|
- return res;
|
||||||
|
- }
|
||||||
|
- }
|
||||||
|
-#endif
|
||||||
|
-
|
||||||
|
-#ifdef __GNUC__
|
||||||
|
- /**********************************************
|
||||||
|
- * try /usr/include/g++/filename
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- workname.Format("/usr/include/g++/%s%s",filename(),addpost[i2]);
|
||||||
|
- res = stat( workname, statBuf );
|
||||||
|
- if (res==0) {
|
||||||
|
- if (fullPath) fullPath->Swap(workname);
|
||||||
|
- return res;
|
||||||
|
- }
|
||||||
|
- }
|
||||||
|
-#endif /* __GNUC__ */
|
||||||
|
-
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- /* #ifdef __hpux */
|
||||||
|
- /**********************************************
|
||||||
|
- * try /usr/include/CC/filename
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- workname.Format("/usr/include/CC/%s%s",filename(),addpost[i2]);
|
||||||
|
- res = stat( workname, statBuf );
|
||||||
|
- if (res==0) {
|
||||||
|
- if (fullPath) fullPath->Swap(workname);
|
||||||
|
- return res;
|
||||||
|
- }
|
||||||
|
- }
|
||||||
|
-#endif
|
||||||
|
-
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- /**********************************************
|
||||||
|
- * try /usr/include/codelibs/filename
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- workname.Format("/usr/include/codelibs/%s%s"
|
||||||
|
- ,filename(),addpost[i2]);
|
||||||
|
- res = stat( workname, statBuf );
|
||||||
|
- if (res==0) {
|
||||||
|
- if (fullPath) fullPath->Swap(workname);
|
||||||
|
- return res;
|
||||||
|
- }
|
||||||
|
- }
|
||||||
|
-#endif
|
||||||
|
}
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
@@ -1960,107 +1874,6 @@ int G__loadfile(const char *filenamein)
|
||||||
|
}
|
||||||
|
if(G__ifile.fp) break;
|
||||||
|
#endif /* G__EDU_VERSION */
|
||||||
|
-
|
||||||
|
-#ifdef G__VISUAL
|
||||||
|
- /**********************************************
|
||||||
|
- * try /msdev/include
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- G__snprintf(G__ifile.name,G__MAXFILENAME,"/msdev/include/%s%s",filename(),addpost[i2]);
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"r");
|
||||||
|
-#else
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"rb");
|
||||||
|
-#endif
|
||||||
|
- G__globalcomp=G__store_globalcomp;
|
||||||
|
- }
|
||||||
|
- if(G__ifile.fp) break;
|
||||||
|
-#endif /* G__VISUAL */
|
||||||
|
-
|
||||||
|
-#ifdef G__SYMANTEC
|
||||||
|
- /**********************************************
|
||||||
|
- * try /sc/include
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- G__snprintf(G__ifile.name,G__MAXFILENAME,"/sc/include/%s%s",filename(),addpost[i2]);
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"r");
|
||||||
|
-#else
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"rb");
|
||||||
|
-#endif
|
||||||
|
- G__globalcomp=G__store_globalcomp;
|
||||||
|
- }
|
||||||
|
- if(G__ifile.fp) break;
|
||||||
|
-#endif /* G__SYMANTEC */
|
||||||
|
-
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- /**********************************************
|
||||||
|
- * try /usr/include/filename
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- G__snprintf(G__ifile.name,G__MAXFILENAME,"/usr/include/%s%s",filename(),addpost[i2]);
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"r");
|
||||||
|
-#else
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"rb");
|
||||||
|
-#endif
|
||||||
|
- G__globalcomp=G__store_globalcomp;
|
||||||
|
- }
|
||||||
|
- if(G__ifile.fp) break;
|
||||||
|
-#endif
|
||||||
|
-
|
||||||
|
-#ifdef __GNUC__
|
||||||
|
- /**********************************************
|
||||||
|
- * try /usr/include/g++/filename
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- G__snprintf(G__ifile.name,G__MAXFILENAME,"/usr/include/g++/%s%s",filename(),addpost[i2]);
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"r");
|
||||||
|
-#else
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"rb");
|
||||||
|
-#endif
|
||||||
|
- G__globalcomp=G__store_globalcomp;
|
||||||
|
- }
|
||||||
|
- if(G__ifile.fp) break;
|
||||||
|
-#endif /* __GNUC__ */
|
||||||
|
-
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
-/* #ifdef __hpux */
|
||||||
|
- /**********************************************
|
||||||
|
- * try /usr/include/CC/filename
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- G__snprintf(G__ifile.name,G__MAXFILENAME,"/usr/include/CC/%s%s",filename(),addpost[i2]);
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"r");
|
||||||
|
-#else
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"rb");
|
||||||
|
-#endif
|
||||||
|
- G__globalcomp=G__store_globalcomp;
|
||||||
|
- }
|
||||||
|
- if(G__ifile.fp) break;
|
||||||
|
-/* #endif __hpux */
|
||||||
|
-#endif
|
||||||
|
-
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
-/* #ifdef __hpux */
|
||||||
|
- /**********************************************
|
||||||
|
- * try /usr/include/codelibs/filename
|
||||||
|
- **********************************************/
|
||||||
|
- if('\0'!=G__cintsysdir[0]) {
|
||||||
|
- G__snprintf(G__ifile.name,G__MAXFILENAME,"/usr/include/codelibs/%s%s"
|
||||||
|
- ,filename(),addpost[i2]);
|
||||||
|
-#ifndef G__WIN32
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"r");
|
||||||
|
-#else
|
||||||
|
- G__ifile.fp = fopen(G__ifile.name,"rb");
|
||||||
|
-#endif
|
||||||
|
- G__globalcomp=G__store_globalcomp;
|
||||||
|
- }
|
||||||
|
- if(G__ifile.fp) break;
|
||||||
|
-/* #endif __hpux */
|
||||||
|
-#endif
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user