Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile_diracxx
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ $(DIRACXX_HOME)/.cmake_done: $(SOURCE_CODE_TARGET)
$(CMAKE3) -DCMAKE_INSTALL_PREFIX=$(DIRACXX_HOME) \
-DCMAKE_INSTALL_LIBDIR=$(DIRACXX_HOME)/lib \
-DBoost_NO_BOOST_CMAKE=ON \
-DPython_EXECUTABLE=/usr/bin/python \
-DPython3_EXECUTABLE=/usr/bin/python \
-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON ..
date > $@

Expand Down
28 changes: 24 additions & 4 deletions Makefile_hdds
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,14 @@ PYVERSION = $(shell $(BUILD_SCRIPTS)/python_chooser.sh version)
HDDS_HOME = $(PWD)/$(HDDS_DIR)
UNTAR_TEMP_DIR := untar_temp_dir_$(shell echo $$RANDOM)

CMAKE3 = $(shell $(BUILD_SCRIPTS)/cmake3_chooser.sh)

all: force_rebuild_action $(HDDS_HOME)/hdds_prereqs_version.xml

force_rebuild_action:
ifdef FORCE
@echo forcing rebuild
$(RM) $(HDDS_HOME)/.sconstruct_done
$(RM) $(HDDS_HOME)/.cmake_install_done
endif

$(TARFILE):
Expand All @@ -69,12 +71,30 @@ $(HDDS_HOME)/.untar_done: $(TARFILE)
rmdir -v $(UNTAR_TEMP_DIR)
date > $@

$(HDDS_HOME)/.sconstruct_done: $(SOURCE_CODE_TARGET)
cd $(HDDS_HOME) ; $(SCONS) install $(HDDS_SCONS_OPTIONS)
$(HDDS_HOME)/.cmake_done: $(SOURCE_CODE_TARGET)
cd $(HDDS_HOME); \
mkdir -p build; \
cd build; \
$(CMAKE3) \
-DXercesC_LIBRARY=$(XERCESCROOT)/lib/libxerces-c.so \
-DXercesC_INCLUDE_DIR=$(XERCES_INCLUDE) \
-DXercesC_VERSION=$(XERCES_C_VERSION) \
-DCMAKE_INSTALL_PREFIX=$(HDDS_HOME)/$(BMS_OSNAME) .. ; \
date > $@

$(HDDS_HOME)/.cmake_build_done: $(HDDS_HOME)/.cmake_done
cd $(HDDS_HOME)/build; \
$(CMAKE3) --build . ; \
date > $@

# use "make install" rather than "cmake3 --install ." because ifarm does not like the latter
$(HDDS_HOME)/.cmake_install_done: $(HDDS_HOME)/.cmake_build_done
cd $(HDDS_HOME)/build; \
make install $(HDDS_SCONS_OPTIONS)
date > $@

ifndef GVMS_TEST
$(HDDS_HOME)/hdds_prereqs_version.xml: $(HDDS_HOME)/.sconstruct_done
$(HDDS_HOME)/hdds_prereqs_version.xml: $(HDDS_HOME)/.cmake_install_done
else
$(HDDS_HOME)/hdds_prereqs_version.xml: $(SOURCE_CODE_TARGET)
endif
Expand Down
26 changes: 25 additions & 1 deletion Makefile_hdgeant4
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ ifdef GLOBAL_CXX_STANDARD
CXX_STANDARD = $(GLOBAL_CXX_STANDARD)
endif

CMAKE3 = $(shell $(BUILD_SCRIPTS)/cmake3_chooser.sh)

all: force_rebuild_action $(HDGEANT4_HOME)/hdgeant4_prereqs_version.xml

force_rebuild_action:
Expand Down Expand Up @@ -91,5 +93,27 @@ $(HDGEANT4_HOME)/.make_done: $(HDGEANT4_HOME)/.link_to_fixes_done
make PYTHON_CONFIG=$(PYTHON_CONFIG) PYTHON_LIB_OPTION=$(PYTHON_LIB_OPTION) BOOST_PYTHON_LIB=-l$(PYTHON_BOOST) $(QTHOME_DEF) $(HDGEANT4_MAKE_OPTIONS) && \
date > $@

$(HDGEANT4_HOME)/hdgeant4_prereqs_version.xml: $(HDGEANT4_HOME)/.make_done
$(HDGEANT4_HOME)/.cmake_done: $(HDGEANT4_HOME)/.link_to_fixes_done
cd $(HDGEANT4_HOME); \
mkdir -p build; \
cd build; \
$(CMAKE3) -DCMAKE_INSTALL_PREFIX=$(HDGEANT4_HOME)/$(BMS_OSNAME)/ \
-DDiracxx_DIR=$(DIRACXX_HOME)/lib/cmake/Diracxx \
-DPython3_EXECUTABLE=/usr/bin/python \
-DBoost_PYTHON_LIBRARY_RELEASE:FILEPATH=/lib64/lib$(PYTHON_BOOST).so \
-DJANA_DIR=$(JANA_HOME)/lib/JANA/cmake ..
date > $@

$(HDGEANT4_HOME)/.cmake_build_done: $(HDGEANT4_HOME)/.cmake_done
cd $(HDGEANT4_HOME)/build; \
$(CMAKE3) --build . $(HDGEANT4_MAKE_OPTIONS)
date > $@

# use "make install" rather than "cmake3 --install ." because ifarm does not like the latter
$(HDGEANT4_HOME)/.cmake_install_done: $(HDGEANT4_HOME)/.cmake_build_done
cd $(HDGEANT4_HOME)/build; \
make install $(HDGEANT4_MAKE_OPTIONS)
date > $@

$(HDGEANT4_HOME)/hdgeant4_prereqs_version.xml: $(HDGEANT4_HOME)/.cmake_install_done
cd $(HDGEANT4_HOME) ; $(BUILD_SCRIPTS)/version_prereqs.pl hdgeant4
1 change: 1 addition & 0 deletions Makefile_root_6_inc
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ ifeq ($(ROOT_EQ_6_24), true)
patch $(ROOTDIR)/cmake/scripts/ROOTConfig.cmake.in < $(BUILD_SCRIPTS)/patches/root/ROOTConfig.cmake.in.patch
else ifeq ($(ROOT_EQ_6_32), true)
patch $(ROOTDIR)/cmake/scripts/ROOTConfig.cmake.in < $(BUILD_SCRIPTS)/patches/root/ROOTConfig.cmake.in.patch
patch $(ROOTDIR)/cmake/scripts/RootUseFile.cmake.in < $(BUILD_SCRIPTS)/patches/root/RootUseFile.cmake.in.patch
endif
date > $@

Expand Down
10 changes: 8 additions & 2 deletions customize_version.pl
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,14 @@
use IO::File;

# get the file name
$status=getopts("i:o:s:g:4:a:t:r:m:h");
$status=getopts("i:o:s:g:d:4:a:t:r:m:h");
$filename_in = $opt_i;
$filename_out = $opt_o;
$halld_home = $opt_s;
$halld_recon_home = $opt_r;
$halld_sim_home = $opt_m;
$hdds_home = $opt_g;
$hddm_home = $opt_d;
$hdgeant4_home = $opt_4;
$gluex_root_analysis_home = $opt_a;
$amptools_home = $opt_t;
Expand All @@ -28,7 +29,7 @@
print_usage();
exit 1;
}
if (!($halld_home || $halld_recon_home || $halld_sim_home || $hdds_home || $hdgeant4_home || $gluex_root_analysis_home || $amptools_home)) {
if (!($halld_home || $halld_recon_home || $halld_sim_home || $hdds_home || $hddm_home || $hdgeant4_home || $gluex_root_analysis_home || $amptools_home)) {
print "\nError: no custom home directories specified, no action taken\n\n";
print_usage();
exit 2;
Expand Down Expand Up @@ -82,6 +83,10 @@
if (uc($hdds_home) ne "NONE") {
$writer->emptyTag("package", "name" => "$name", "home" => "$hdds_home");
}
} elsif ($name eq "hddm" && $hddm_home) {
if (uc($hddm_home) ne "NONE") {
$writer->emptyTag("package", "name" => "$name", "home" => "$hddm_home");
}
} elsif ($name eq "hdgeant4" && $hdgeant4_home) {
if (uc($hdgeant4_home) ne "NONE") {
$writer->emptyTag("package", "name" => "$name", "home" => "$hdgeant4_home");
Expand Down Expand Up @@ -142,6 +147,7 @@ sub print_usage {
-r <custom halld_recon home directory> (optional, r for recon)
-m <custom halld_sim home directory> (optional, m for Monte Carlo)
-g <custom HDDS home directory> (optional, g for geometry)
-d <custom HDDM home directory> (optional, d for data model)
-4 <custom HDGeant4 home directory> (optional, 4 for 4)
-a <custom gluex_root_analysis home directory> (optional, a for analysis)
-t <custom amptools home directory> (optional, t for tools)
Expand Down
2 changes: 2 additions & 0 deletions gluex_env.csh
Original file line number Diff line number Diff line change
Expand Up @@ -145,9 +145,11 @@ if ($?HDGEANT4_HOME) then
if ($?G4SYSTEM) then
echo $PATH | grep $HDGEANT4_HOME/bin/$G4SYSTEM > /dev/null
if ($status) setenv PATH $HDGEANT4_HOME/bin/${G4SYSTEM}:$PATH
if ($status) setenv PATH $HDGEANT4_HOME/${BMS_OSNAME}/bin:$PATH
endif
echo $PYTHONPATH | grep $HDGEANT4_HOME/g4py > /dev/null
if ($status) setenv PYTHONPATH $HDGEANT4_HOME/g4py:$PYTHONPATH
if ($status) setenv PYTHONPATH $HDGEANT4_HOME/${BMS_OSNAME}/g4py:$PYTHONPATH
endif
#
# hd_utilities: nothing to do for hd_utilities
Expand Down
6 changes: 4 additions & 2 deletions gluex_env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -221,11 +221,13 @@ fi
if [ -n "$HDGEANT4_HOME" ]; then
if [ -n "$G4SYSTEM" ]; then
if [ `echo $PATH | grep -c $HDGEANT4_HOME/bin/$G4SYSTEM` -eq 0 ]; then
export PATH=$HDGEANT4_HOME/bin/${G4SYSTEM}:$PATH
export PATH=$HDGEANT4_HOME/bin/${G4SYSTEM}:$PATH # pre-cmake era
export PATH=$HDGEANT4_HOME/${BMS_OSNAME}/bin:$PATH
fi
fi
if [ `echo $PYTHONPATH | grep -c $HDGEANT4_HOME/g4py` -eq 0 ]; then
export PYTHONPATH=$HDGEANT4_HOME/g4py:$PYTHONPATH
export PYTHONPATH=$HDGEANT4_HOME/g4py:$PYTHONPATH # pre-cmake era
export PYTHONPATH=$HDGEANT4_HOME/${BMS_OSNAME}/g4py:$PYTHONPATH
fi
fi
#
Expand Down
12 changes: 11 additions & 1 deletion my_halld_build_jlab
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ where:
(default: keep all packages that appear in the input xml file)
package_n package name, choose from:
hdds
hddm
sim-recon
halld_recon
halld_sim
Expand Down Expand Up @@ -60,6 +61,11 @@ case $key in
list="$list hdds"
shift
;;
hddm)
cmd="$cmd -d $mydir/hddm"
list="$list hddm"
shift
;;
sim-recon)
cmd="$cmd -s $mydir/sim-recon"
list="$list sim-recon"
Expand Down Expand Up @@ -102,8 +108,9 @@ if [ -z "$xmlfile" ]
fi
if [ -z "$list" ]
then
list="hdds halld_recon halld_sim hdgeant4 gluex_root_analysis amptools"
list="hdds hddm halld_recon halld_sim hdgeant4 gluex_root_analysis amptools"
cmd="$cmd -g $mydir/hdds"
cmd="$cmd -d $mydir/hddm"
cmd="$cmd -r $mydir/halld_recon"
cmd="$cmd -m $mydir/halld_sim"
cmd="$cmd -4 $mydir/hdgeant4"
Expand Down Expand Up @@ -178,6 +185,9 @@ fi
if [[ $list = *hdds* ]]
then make -f $BUILD_SCRIPTS/Makefile_hdds
fi
if [[ $list = *hddm* ]]
then make -f $BUILD_SCRIPTS/Makefile_hddm
fi
if [[ $list = *sim-recon* ]]
then make -f $BUILD_SCRIPTS/Makefile_sim-recon SIM_RECON_SCONS_OPTIONS="$threads_option"
fi
Expand Down
11 changes: 11 additions & 0 deletions patches/root/RootUseFile.cmake.in.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- RootUseFile.cmake.in 2025-11-25 09:45:15.000000000 -0500
+++ RootUseFile.cmake.in.patched 2026-03-03 13:01:10.280437508 -0500
@@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 3.10 FATAL_ERROR)

#---Define the Standard macros for ROOT-----------------------------------------------------------
-include(${CMAKE_CURRENT_LIST_DIR}/RootMacros.cmake)
+include(${CMAKE_CURRENT_LIST_DIR}/modules/RootMacros.cmake)

#---Set Link and include directories--------------------------------------------------------------
include_directories(${ROOT_INCLUDE_DIRS})
4 changes: 3 additions & 1 deletion pull_request/build_pull_request.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ logfile=make_${branch}.log
mkdir -p -v $target_dir
pushd $target_dir

export REPO_URL=https://github.com/JeffersonLab/$repo
#export REPO_URL=https://github.com/JeffersonLab/$repo
if [ -f "$repo^$branch" ]; then
rm "$repo^$branch"
fi
Expand All @@ -21,8 +21,10 @@ if [ "$repo" == "sim-recon" ]; then
export SIM_RECON_SCONS_OPTIONS="-j8 SHOWBUILD=1"
elif [ "$repo" == "halld_recon" ]; then
export HALLD_RECON_SCONS_OPTIONS="-j8 SHOWBUILD=1"
export HALLD_RECON_URL=$REPO_URL
elif [ "$repo" == "halld_sim" ]; then
export HALLD_SIM_SCONS_OPTIONS="-j8 SHOWBUILD=1"
export HALLD_SIM_URL=$REPO_URL
fi

# save environment
Expand Down