This page documents my attempts to install the LCG software core on various non-traditional machines.
The basic installation instructions are here for a standard Scientific Linix CERN 6 installation: <html><b><a href=“http://ph-dep-sft.web.cern.ch/document/using-lcgcmake” target=“_blank”>LCGCMake SLC6 Installation </a></b></html>
.softrc.cooley
)mkdir /path/to/lcg
export $LCG_PROJECT_PATH=/path/to/lcg
cd $LCG_PROJECT_PATH
soft add +cmake
soft add +gcc-4.8.1
mkdir dependencies
cd dependencies
mkdir install
wget ftp://ftp.ucsb.edu/pub/mirrors/procmail/procmail-3.22.tar.gz
tar zxf procmail-3.22.tar.gz
cd procmail-3.22
make lockfile CC=$(which gcc) CXX=$(which g++)
lockfile
because other parts of this package fail, but we don't need them.cd ..
mkdir install/bin
ln -s $PWD/procmail-3.22/src/lockfile $PWD/install/bin/lockfile
wget ftp://xmlsoft.org/libxml2/libxml2-2.9.2.tar.gz
tar zxf libxml2-2.9.2.tar.gz
cd libxml2-2.9.2
./configure --with-python --with-threads --prefix=/path/to/lcg/dependencies/install
make -j 10
make install
cd ..
git clone git://git.gnome.org/libxslt
cd libxslt
./autogen.sh --with-python --with-libxml-prefix=/path/to/lcg/dependencies/install --prefix=/path/to/lcg/dependencies/install
make -j 10
make install
cd ..
export PATH=/path/to/lcg/dependencies/install/bin:$PATH
export LD_LIBRARY_PATH=/path/to/lcg/dependencies/install/lib:$LD_LIBRARY_PATH
cd $LCG_PROJECT_PATH
svn co http://svn.cern.ch/guest/lcgsoft/trunk/lcgcmake
mkdir lcgcmake-build
mkdir lcgcmake-install
slc6
in the name, in the case of Cooley, slc6
gets replaced with linux
and the downloads fail since there is no tarball with linux
in the name. Edit lcgcmake/cmake/toolchain/heptools-common.cmake
around line 75 from else() execute_process(COMMAND cat /etc/os-release OUTPUT_VARIABLE os_release OUTPUT_STRIP_TRAILING_WHITESPACE) if(os_release MATCHES "centos") set(os "cc") string(REGEX REPLACE ".*VERSION_ID=\"([0-9]+).*" "\\1" osvers "${os_release}") else() message(WARNING "Unkown OS, assuming 'linux'") set(os linux) set(osvers) endif() endif()
to
else() execute_process(COMMAND cat /etc/os-release OUTPUT_VARIABLE os_release OUTPUT_STRIP_TRAILING_WHITESPACE) if(os_release MATCHES "centos") set(os "cc") string(REGEX REPLACE ".*VERSION_ID=\"([0-9]+).*" "\\1" osvers "${os_release}") else() message(WARNING "Unkown OS, assuming 'slc6'") set(os "slc") set(osvers "6") endif() endif()
lcgcmake/projects/CMakeLists.txt
line 244 in CORAL package from SVN_REPOSITORY=http://svn.cern.ch/guest/lcgcoral/coral/tags/${CORAL_native_version} --quiet
to
SVN_REPOSITORY=http://svn.cern.ch/guest/lcgcoral/coral/tags/CORAL_${CORAL_native_version} --quiet
lcgcmake/externals/CMakeLists.txt
lines 297 - 302 (or so) from #---Davix-------------------------------------------------------------------------------------------- LCGPackage_Add( Davix URL http://grid-deployment.web.cern.ch/grid-deployment/dms/lcgutil/tar/davix/davix-<NATIVE_VERSION>.tar.gz CONFIGURE_COMMAND ${CMAKE_COMMAND} -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR> -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} -DBOOST_ROOT:PATHNAME=${Boost_home} -DBOOST_INCLUDEDIR=${Boost_home}/include -DBOOST_LIBRARYDIR=${Boost_home}/lib -DBoost_NO_BOOST_CMAKE=True <SOURCE_DIR> DEPENDS Boost )
to
#---Davix-------------------------------------------------------------------------------------------- LCGPackage_Add( Davix URL http://grid-deployment.web.cern.ch/grid-deployment/dms/lcgutil/tar/davix/davix-<NATIVE_VERSION>.tar.gz CONFIGURE_COMMAND ${CMAKE_COMMAND} -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR> -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} -DBOOST_ROOT:PATHNAME=${Boost_home} -DBoost_INCLUDE_DIR:PATH=${Boost_home}/include/boost-1_55 -DBoost_LIBRARY_DIR_DEBUG:PATH=${Boost_home}/lib -DBoost_LIBRARY_DIR_RELEASE:PATH=${Boost_home}/lib -DBoost_NO_BOOST_CMAKE:BOOL=True -DCMAKE_C_COMPILER=${CMAKE_C_COMPILER} -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER} <SOURCE_DIR> DEPENDS Boost )
lcgcmake/projects/CMakeLists.txt
and insert around line 99 to the ROOT package config -DCMAKE_C_COMPILER=${CMAKE_C_COMPILER} -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
lcgcmake/projects/CMakeLists.txt
around line 186 in the RELAX package and add the lines -DCMAKE_C_COMPILER=${CMAKE_C_COMPILER} -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
.
lcgcmake/generators/CMakeLists.txt
around line 1679 in the crmc package and add the lines -DCMAKE_MODULE_PATH=${CMAKE_SOURCE_DIR}/cmake/modules -DCMAKE_C_COMPILER=${CMAKE_C_COMPILER} -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
lcgcmake/externals/CMakeLists.txt
around line ? in the hepmc3 package and add the lines -DCMAKE_C_COMPILER=${CMAKE_C_COMPILER} -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
.
lcgcmake/externals/CMakeLists.txt
around line 842 in the igprof package and comment out the -Wno-error=unused-result
.cd lcgcmake-build
cmake -DCMAKE_INSTALL_PREFIX=../lcgcmake-install -DCMAKE_C_COMPILER=$(which gcc) -DCMAKE_CXX_COMPILER=$(which g++) ../lcgcmake
When a build fails, look at this list for fixes, fix, then continue with make -j 10
.
pythia8
packages download and fail to build, the Makefile's must be edited, the files lcgcmake-build/generators/pythia8-201/src/pythia8/201/Makefile
have $(CXX_SONAME),$(notdir $@)
which must be changed to -shared
.sed 's/$(CXX_SONAME),$(notdir\ $@)/-shared/g' generators/pythia8-201/src/pythia8/201/Makefile > generators/pythia8-201/src/pythia8/201/Makefile.tmp
evtgen
package downloads and fails to build, the Makefile must be edited, the file lcgcmake-build/generators/evtgen-1.2.0/src/evtgen/1.2.0/src/Makefile
have $(shell find … )
commands inside, Add -not -path '*/\.*
' to the end of these finds. This is to exclude the many stupid hidden files ._<fildname>
that someone must have commit to the repo from their MAC.lcgcmake-build/projects/ROOT-6.02.12/src/ROOT/6.02.12/sql/odbc/inc/TODBC*.h
a #include<sqlcli.h>
just under the #include<sql.h>
at the top of the file. Add to the files lcgcmake-build/projects/ROOT-6.02.12/src/ROOT/6.02.12/sql/odbc/src/TODBCServer.cxx
and lcgcmake-build/projects/ROOT-6.02.12/src/ROOT/6.02.12/sql/odbc/src/TODBCStatement.cxx
a #include<sqlcli1.h>
at the top of the files.#!/usr/bin/env bash soft add +cmake soft add +gcc-4.8.1