File indexing completed on 2025-02-05 23:51:34
0001
0002
0003 function die { echo $1: status $2 ; exit $2; }
0004
0005 SCRAM_TEST_NAME=TestIOPoolInputNoParentDictionary
0006 rm -rf $SCRAM_TEST_NAME
0007 mkdir $SCRAM_TEST_NAME
0008 cd $SCRAM_TEST_NAME
0009
0010
0011 NEW_CMSSW_BASE=$(/bin/pwd -P)/$CMSSW_VERSION
0012 scram -a $SCRAM_ARCH project $CMSSW_VERSION
0013 pushd $CMSSW_VERSION/src
0014 mkdir DataFormats
0015
0016
0017 if [ -d ${CMSSW_BASE}/src/DataFormats/Common ]; then
0018 cp -Lr ${CMSSW_BASE}/src/DataFormats/Common DataFormats/
0019 fi
0020 if [ -d ${CMSSW_BASE}/src/DataFormats/Provenance ]; then
0021 cp -Lr ${CMSSW_BASE}/src/DataFormats/Provenance DataFormats/
0022 fi
0023
0024 if [ -d ${CMSSW_BASE}/src/FWCore/Utilities ]; then
0025 mkdir -p FWCore
0026 cp -Lr ${CMSSW_BASE}/src/FWCore/Utilities FWCore/
0027 fi
0028
0029 if [ -d ${CMSSW_BASE}/src/FWCore/MessageLogger ]; then
0030 mkdir -p FWCore
0031 cp -Lr ${CMSSW_BASE}/src/FWCore/MessageLogger FWCore/
0032 fi
0033
0034 if [ -d ${CMSSW_BASE}/src/FWCore/Reflection ]; then
0035 mkdir -p FWCore
0036 cp -Lr ${CMSSW_BASE}/src/FWCore/Reflection FWCore/
0037 fi
0038
0039
0040 if [ -d ${CMSSW_BASE}/src/FWCore/SOA ]; then
0041 mkdir -p FWCore
0042 cp -Lr ${CMSSW_BASE}/src/FWCore/SOA FWCore/
0043 fi
0044
0045
0046 for DIR in ${CMSSW_BASE} ${CMSSW_RELEASE_BASE} ${CMSSW_FULL_RELEASE_BASE} ; do
0047 if [ -d ${DIR}/src/DataFormats/TestObjects ]; then
0048 cp -Lr ${DIR}/src/DataFormats/TestObjects DataFormats/
0049 break
0050 fi
0051 done
0052 if [ ! -e DataFormats/TestObjects ]; then
0053 echo "Failed to copy DataFormats/TestObjects from local or release area"
0054 exit 1;
0055 fi
0056
0057
0058 cat DataFormats/TestObjects/test/BuildFile_extra.xml >> DataFormats/TestObjects/test/BuildFile.xml
0059
0060 (eval $(scram run -sh) ; scram build -j $(nproc))
0061
0062 popd
0063
0064
0065 export LD_LIBRARY_PATH=${NEW_CMSSW_BASE}/lib/${SCRAM_ARCH}:${LD_LIBRARY_PATH}
0066 export ROOT_INCLUDE_PATH=${NEW_CMSSW_BASE}/src:${ROOT_INCLUDE_PATH}
0067
0068 echo "Produce a file with TransientIntParentT<1> product"
0069 cmsRun ${LOCALTOP}/src/IOPool/Input/test/PoolNoParentDictionaryTestStep1_cfg.py || die 'Failed cmsRun PoolNoParentDictionaryTestStep1_cfg.py' $?
0070
0071
0072
0073 echo "PREVENT_HEADER_PARSING" >> ${NEW_CMSSW_BASE}/src/DataFormats/TestObjects/interface/ToyProducts.h
0074 rm ${NEW_CMSSW_BASE}/lib/${SCRAM_ARCH}/DataFormatsTestObjectsParent1_xr_rdict.pcm ${NEW_CMSSW_BASE}/lib/${SCRAM_ARCH}/libDataFormatsTestObjectsParent1.so
0075 sed -i -e 's/libDataFormatsTestObjectsParent1.so/libDataFormatsTestObjectsParent2.so/' ${NEW_CMSSW_BASE}/lib/${SCRAM_ARCH}/DataFormatsTestObjectsParent1_xr.rootmap
0076
0077 echo "Read the file without TransientIntParentT<1> dictionary"
0078 cmsRun ${LOCALTOP}/src/IOPool/Input/test/PoolNoParentDictionaryTestStep2_cfg.py || die 'Failed cmsRun PoolNoParentDictionaryTestStep2_cfg.py' $?