Hi All,
I am again having issues with RDataFrame and CMake, a number of warnings indicating that linking is attempting to use the ROOT build path:
-- The C compiler identification is GNU 8.1.0
-- The CXX compiler identification is GNU 8.1.0
-- Check for working C compiler: /opt/x86_64-pc-linux-gnu-rhel6/gcc/8.1.0/bin/gcc
-- Check for working C compiler: /opt/x86_64-pc-linux-gnu-rhel6/gcc/8.1.0/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /opt/x86_64-pc-linux-gnu-rhel6/gcc/8.1.0/bin/g++
-- Check for working CXX compiler: /opt/x86_64-pc-linux-gnu-rhel6/gcc/8.1.0/bin/g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- RDataFrame Enabled
-- Configuring done
CMake Warning at CMakeLists.txt:27 (add_executable):
Cannot generate a safe linker search path for target rdf_test because files
in some directories may conflict with libraries in implicit directories:
link library [libCore.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libImt.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libRIO.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libNet.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libHist.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libGraf.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libGraf3d.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libGpad.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libROOTDataFrame.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libTree.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libTreePlayer.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libRint.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libPostscript.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libMatrix.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libPhysics.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libMathCore.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libThread.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
link library [libMultiProc.so] in /opt/root/gcc_8.1.0/6.16.00/install/lib may be hidden by files in:
/opt/root/gcc_8.1.0/6.16.00/build/lib
Some of these libraries may not be found correctly.
... (Warning repeats)
-- Generating done
-- Build files have been written to: rdataframe_cmake_test/build
The path variables are set to the ROOT install directory and root-config
returns the install directory for the prefix.
MWE CMake file:
cmake_minimum_required(VERSION 3.0)
#Find the ROOT package.
find_package(ROOT 6 REQUIRED)
option(RDataFrame "Use RDataFrame for analysis." ON)
#If the user requests RDataFrame then ROOT 6.14 is required with the RootDataFrame library.
if (${RDataFrame})
find_package(ROOT 6.14 REQUIRED COMPONENTS ROOTDataFrame)
message(STATUS "RDataFrame Enabled")
endif (${RDataFrame})
add_executable(rdf_test rdf_test.cxx)
target_link_libraries(rdf_test PUBLIC ${ROOT_LIBRARIES})
set_target_properties(rdf_test PROPERTIES INSTALL_RPATH "${ROOT_LIBRARY_DIR}")
if (${RDataFrame})
target_link_libraries(rdf_test PUBLIC ROOT::ROOTDataFrame)
target_compile_definitions(rdf_test PUBLIC USE_RDataFrame)
endif (${RDataFrame})
The dummy program:
#ifdef USE_RDataFrame
#include <ROOT/RDataFrame.hxx>
#endif
int main() {
return 0;
}
This post follows from a previous one:
Any help is appreciated.
ROOT Version: 6.16.00
Platform: RHEL 6
Compiler: gcc 8.1.0 (cmake 3.10.3)