Import Geant4 7.0.0 source tree
This commit is contained in:
+24
-2
@@ -1,5 +1,4 @@
|
||||
$Id: History,v 1.254 2004/06/23 10:56:23 gcosmo Exp $
|
||||
$Name: geant4-06-02 $
|
||||
$Id: History,v 1.260 2004/12/08 12:46:06 gcosmo Exp $
|
||||
-------------------------------------------------------------------
|
||||
|
||||
=========================================================
|
||||
@@ -17,6 +16,29 @@ committal in the CVS repository !
|
||||
* Reverse chronological order (last date on top), please *
|
||||
----------------------------------------------------------
|
||||
|
||||
8th December 2004 John Allison (config-V06-02-03)
|
||||
- Darwin-g++.gmk: fixes on setup for dynamic libraries.
|
||||
|
||||
30th November 2004 Gabriele Cosmo (config-V06-02-02)
|
||||
- binmake.gmk: added electromagnetic/highenergy module to INCLUDE path.
|
||||
|
||||
27th November 2004 Gabriele Cosmo (config-V06-02-01)
|
||||
- binmake.gmk: added parameterisations/trd_clusters and
|
||||
parameterisations/gflash modules to INCLUDE path.
|
||||
|
||||
29th October 2004 Gabriele Cosmo (config-V06-02-00)
|
||||
- Archived setup for Windows/VC++6. WIN32-VC now corresponds to WIN32-VC7.
|
||||
Archived WIN32-VC7.gmk.
|
||||
- Removed strict compilation options for SUN-CC and thread specific.
|
||||
|
||||
12th October 2004 John Allison
|
||||
- Darwin-g++.gmk : added -lXi to X11LIBS.
|
||||
|
||||
08th July 2004 Guy Barrand
|
||||
- Darwin-g++.gmk : correct options to build granular shared libs.
|
||||
Have "-undefined define_a_way" instead of "-undefined error" since
|
||||
granular libs are not linked for the moment.
|
||||
|
||||
23rd June 2004 Gabriele Cosmo (config-V06-01-10)
|
||||
- Updated win32def.c program to fix retrivial of public static data for
|
||||
building DLLs on Windows (G.Barrand).
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# $Id: architecture.gmk,v 1.99 2004/06/14 10:42:12 gcosmo Exp $
|
||||
# $Id: architecture.gmk,v 1.100 2004/10/29 17:27:45 gcosmo Exp $
|
||||
# ------------------------------------------------------------------------
|
||||
# GEANT 4 - Architecture configuration script for GNU Make
|
||||
#
|
||||
@@ -13,11 +13,11 @@
|
||||
# List of the supported architectures/compilers and related flavors for
|
||||
# the environment variable G4SYSTEM:
|
||||
#
|
||||
# Linux-g++ Linux (Red Hat 7.3), gcc-3.2.3 (default)
|
||||
# Linux-g++ Linux (Red Hat Enterprise/SCL3), gcc-3.2.3 (default)
|
||||
#
|
||||
# SUN-CC SunOS 5.8, CC 5.4
|
||||
#
|
||||
# WIN32-VC7 Windows/2000/XP and Microsoft Visual C++ 7.1 .NET
|
||||
# WIN32-VC Windows/XP and Microsoft Visual C++ 7.1 .NET
|
||||
# Adding CYGWIN32 tools
|
||||
# -------------------------------------------------------------------------
|
||||
|
||||
|
||||
+4
-2
@@ -1,4 +1,4 @@
|
||||
# $Id: binmake.gmk,v 1.102 2004/06/11 14:07:47 gcosmo Exp $
|
||||
# $Id: binmake.gmk,v 1.104 2004/11/30 08:33:42 gcosmo Exp $
|
||||
# ----------------------------------------------------------
|
||||
# Script defining rules and paths for making binaries.
|
||||
# First implementation: Gabriele Cosmo, 25/06/1998.
|
||||
@@ -51,7 +51,8 @@ ifndef INCFLAGS
|
||||
-I$(G4BASE)/global/HEPNumerics/include \
|
||||
-I$(G4BASE)/run/include \
|
||||
-I$(G4BASE)/materials/include \
|
||||
-I$(G4BASE)/parameterisations/include \
|
||||
-I$(G4BASE)/parameterisations/trd_clusters/include \
|
||||
-I$(G4BASE)/parameterisations/gflash/include \
|
||||
-I$(G4BASE)/particles/management/include \
|
||||
-I$(G4BASE)/particles/bosons/include \
|
||||
-I$(G4BASE)/particles/leptons/include \
|
||||
@@ -70,6 +71,7 @@ ifndef INCFLAGS
|
||||
-I$(G4BASE)/processes/electromagnetic/utils/include \
|
||||
-I$(G4BASE)/processes/electromagnetic/xrays/include \
|
||||
-I$(G4BASE)/processes/electromagnetic/lowenergy/include \
|
||||
-I$(G4BASE)/processes/electromagnetic/highenergy/include \
|
||||
-I$(G4BASE)/processes/hadronic/cross_sections/include \
|
||||
-I$(G4BASE)/processes/hadronic/management/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/abrasion/include \
|
||||
|
||||
+2
-2
@@ -1,4 +1,4 @@
|
||||
# $Id: globlib.gmk,v 1.24 2004/06/08 10:04:46 gcosmo Exp $
|
||||
# $Id: globlib.gmk,v 1.25 2004/10/29 17:30:43 gcosmo Exp $
|
||||
# --------------------------------------------------------------
|
||||
# Script for compound libraries. Gabriele Cosmo, 25/6/98.
|
||||
# --------------------------------------------------------------
|
||||
@@ -45,7 +45,7 @@ $(G4LIBDIR)/lib$(name).a: \
|
||||
#
|
||||
#
|
||||
#
|
||||
@if [ X$(G4SYSTEM) = XWIN32-VC -o X$(G4SYSTEM) = XWIN32-VC7 ] ; \
|
||||
@if [ X$(G4SYSTEM) = XWIN32-VC ] ; \
|
||||
then \
|
||||
i=NO; \
|
||||
(( for lib in $(SUBLIBS); \
|
||||
|
||||
@@ -34,18 +34,34 @@ echo "On this machine the G4SYSTEM=\$G4SYSTEM"
|
||||
# g4dirs.U
|
||||
#
|
||||
#+
|
||||
if ( X$g4install != X$g4final_install ) then
|
||||
setenv G4INSTALL "$g4final_install/src/geant4"
|
||||
echo "On this machine the G4INSTALL=\$G4INSTALL"
|
||||
else
|
||||
setenv G4INSTALL "$g4install"
|
||||
echo "On this machine the G4INSTALL=\$G4INSTALL"
|
||||
endif
|
||||
|
||||
#+
|
||||
if ( X$g4include != X ) then
|
||||
setenv G4INCLUDE "$g4include"
|
||||
if ( X$g4includes_flag != Xn ) then
|
||||
if ( X$g4install != X$g4final_install ) then
|
||||
setenv G4INCLUDE "$g4final_install/include/geant4"
|
||||
else
|
||||
setenv G4INCLUDE "$g4final_install/include"
|
||||
endif
|
||||
echo "On this machine the G4INCLUDE=\$G4INCLUDE"
|
||||
#else
|
||||
#setenv G4BASE "$g4final_install/include/geant4/source"
|
||||
#echo "On this machine the G4BASE=\$G4BASE"
|
||||
endif
|
||||
|
||||
#+
|
||||
if ( X$g4lib != X ) then
|
||||
setenv G4LIB "$g4lib"
|
||||
if ( X$g4install != X$g4final_install ) then
|
||||
setenv G4LIB "$g4final_install/lib/geant4"
|
||||
else
|
||||
setenv G4LIB "$g4final_install/lib"
|
||||
endif
|
||||
echo "On this machine the G4LIB=\$G4LIB"
|
||||
endif
|
||||
|
||||
@@ -292,6 +308,12 @@ setenv G4LIB_USE_GRANULAR 1
|
||||
echo "On this machine the G4LIB_USE_GRANULAR=\$G4LIB_USE_GRANULAR"
|
||||
endif
|
||||
|
||||
# Check for Windows!
|
||||
if ( "X$G4SYSTEM" != "XWIN32-VC" && "X$G4SYSTEM" != "XWIN32-VC7" ) then
|
||||
setenv G4UI_USE_TCSH 1
|
||||
echo "On this machine the G4UI_USE_TCSH=\$G4UI_USE_TCSH"
|
||||
endif
|
||||
|
||||
#####################################################################
|
||||
|
||||
!GROK!THIS!
|
||||
|
||||
@@ -37,24 +37,42 @@ fi
|
||||
# g4dirs.U
|
||||
#
|
||||
#+
|
||||
if [ X$g4install != X$g4final_install ] ; then
|
||||
G4INSTALL="$g4final_install/src/geant4"
|
||||
else
|
||||
G4INSTALL="$g4install"
|
||||
fi
|
||||
export G4INSTALL
|
||||
if [ X\$g4non_display = X ] ; then
|
||||
echo "On this machine the G4INSTALL=\$G4INSTALL"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4include != X ] ; then
|
||||
G4INCLUDE="$g4include"
|
||||
if [ X$g4includes_flag != Xn ] ; then
|
||||
if [ X$g4install != X$g4final_install ] ; then
|
||||
G4INCLUDE="$g4final_install/include/geant4"
|
||||
else
|
||||
G4INCLUDE="$g4install/include/"
|
||||
fi
|
||||
export G4INCLUDE
|
||||
if [ X\$g4non_display = X ] ; then
|
||||
echo "On this machine the G4INCLUDE=\$G4INCLUDE"
|
||||
fi
|
||||
#else
|
||||
#G4BASE="$g4final_install/include/geant4/source"
|
||||
#export G4BASE
|
||||
#if [ X\$g4non_display = X ] ; then
|
||||
#echo "On this machine the G4BASE=\$G4BASE"
|
||||
#fi
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4lib != X ] ; then
|
||||
G4LIB="$g4lib"
|
||||
if [ X$g4install != X$g4final_install ] ; then
|
||||
G4LIB="$g4final_install/lib/geant4"
|
||||
else
|
||||
G4LIB="$g4install/lib"
|
||||
fi
|
||||
export G4LIB
|
||||
if [ X\$g4non_display = X ] ; then
|
||||
echo "On this machine the G4LIB=\$G4LIB"
|
||||
@@ -415,6 +433,19 @@ echo "On this machine the G4LIB_USE_GRANULAR=\$G4LIB_USE_GRANULAR"
|
||||
fi
|
||||
fi
|
||||
|
||||
# Check for Windows!
|
||||
if test "X$G4SYSTEM" != "XWIN32-VC" -a "X$G4SYSTEM" != "XWIN32-VC7"; then
|
||||
#+
|
||||
#
|
||||
# UI_USE_TCSH for Unix
|
||||
#
|
||||
G4UI_USE_TCSH=1
|
||||
export G4UI_USE_TCSH
|
||||
if [ X\$g4non_display = X ] ; then
|
||||
echo "On this machine the G4UI_USE_TCSH=\$G4UI_USE_TCSH"
|
||||
fi
|
||||
fi
|
||||
|
||||
#####################################################################
|
||||
|
||||
!GROK!THIS!
|
||||
|
||||
@@ -40,7 +40,7 @@ export G4INSTALL
|
||||
echo "On this machine the G4INSTALL=\$G4INSTALL"
|
||||
|
||||
#+
|
||||
if [ X$g4include != X ] ; then
|
||||
if [ X$g4include != X -a X$g4include != Xn ] ; then
|
||||
G4INCLUDE="$g4include"
|
||||
export G4INCLUDE
|
||||
echo "On this machine the G4INCLUDE=\$G4INCLUDE"
|
||||
@@ -110,6 +110,12 @@ export CLHEP_BASE_DIR
|
||||
echo "On this machine the CLHEP_BASE_DIR=\$CLHEP_BASE_DIR"
|
||||
fi
|
||||
|
||||
if [ X$g4clhep_base_dir != X/usr -o X$g4clhep_base_dir != X/usr/local ] ; then
|
||||
CLHEP_BASE_DIR="$g4clhep_base_dir"
|
||||
export CLHEP_BASE_DIR
|
||||
echo "On this machine the CLHEP_BASE_DIR=\$CLHEP_BASE_DIR"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4clhep_include_dir != X ] ; then
|
||||
CLHEP_INCLUDE_DIR="$g4clhep_include_dir"
|
||||
@@ -362,7 +368,7 @@ mkdir -p \$G4LIB/\$G4SYSTEM
|
||||
$g4make -n -p -f \$G4INSTALL/config/scripts/GNUmakefile > \$G4LIB/\$G4SYSTEM/GNUmakefile.db
|
||||
|
||||
echo ""
|
||||
echo "Starting installation..."
|
||||
echo "Starting build..."
|
||||
echo ""
|
||||
cd $g4install/source
|
||||
#echo `pwd`
|
||||
@@ -401,11 +407,13 @@ if test -f \$g4conf/g4make.log ; then
|
||||
# different arithmetic expansion...So we are doing it by 'text'
|
||||
# in two steps...
|
||||
|
||||
err=\`grep Error $g4conf/g4make.log | wc -w\`
|
||||
int=\`grep Stop\. $g4conf/g4make.log | wc -w\`
|
||||
err=\`grep " Error " $g4conf/g4make.log | wc -w\`
|
||||
int=\`grep " Interrupt " $g4conf/g4make.log | wc -w\`
|
||||
stp=\`grep Stop\. $g4conf/g4make.log | wc -w\`
|
||||
|
||||
err2=\`echo \$err\`
|
||||
int2=\`echo \$int\`
|
||||
stp2=\`echo \$stp\`
|
||||
|
||||
if [ X\$err2 = X0 -a X\$int2 = X0 ] ; then
|
||||
echo ""
|
||||
@@ -436,11 +444,6 @@ echo "############################################################"
|
||||
echo ""
|
||||
fi
|
||||
|
||||
# There is no env!
|
||||
if [ X$g4includes_flag = Xy ] ; then
|
||||
$g4make includes
|
||||
fi
|
||||
|
||||
!GROK!THIS!
|
||||
|
||||
: In the following dollars and backticks do not need the extra backslash.
|
||||
|
||||
@@ -0,0 +1,417 @@
|
||||
case $CONFIG in
|
||||
'')
|
||||
if test -f config.sh; then TOP=.;
|
||||
elif test -f ../config.sh; then TOP=..;
|
||||
elif test -f ../../config.sh; then TOP=../..;
|
||||
elif test -f ../../../config.sh; then TOP=../../..;
|
||||
elif test -f ../../../../config.sh; then TOP=../../../..;
|
||||
else
|
||||
echo "Can't find config.sh."; exit 1
|
||||
fi
|
||||
. $TOP/config.sh
|
||||
;;
|
||||
esac
|
||||
: This forces SH files to create target in same directory as SH file.
|
||||
: This is so that make depend always knows where to find SH derivatives.
|
||||
case "$0" in
|
||||
*/*) cd `expr X$0 : 'X\(.*\)/'` ;;
|
||||
esac
|
||||
#echo "Extracting move.sh (with variable substitutions)"
|
||||
: This section of the file will have variable substitutions done on it.
|
||||
: Move anything that needs config subs from !NO!SUBS! section to !GROK!THIS!.
|
||||
: Protect any dollar signs and backticks that you do not want interpreted
|
||||
: by putting a backslash in front. You may delete these comments.
|
||||
$spitshell >move.sh <<!GROK!THIS!
|
||||
######################################
|
||||
#
|
||||
# g4system.U
|
||||
#
|
||||
#+
|
||||
G4SYSTEM="$g4system"
|
||||
export G4SYSTEM
|
||||
echo "On this machine the G4SYSTEM=\$G4SYSTEM"
|
||||
|
||||
#
|
||||
# g4dirs.U
|
||||
#
|
||||
#+
|
||||
G4INSTALL="$g4install"
|
||||
export G4INSTALL
|
||||
echo "On this machine the G4INSTALL=\$G4INSTALL"
|
||||
|
||||
#+
|
||||
if [ X$g4include != X -a X$g4include != Xn ] ; then
|
||||
G4INCLUDE="$g4include"
|
||||
export G4INCLUDE
|
||||
echo "On this machine the G4INCLUDE=\$G4INCLUDE"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4tmp != X ] ; then
|
||||
G4TMP="$g4tmp"
|
||||
export G4TMP
|
||||
echo "On this machine the G4TMP=\$G4TMP"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4lib != X ] ; then
|
||||
G4LIB="$g4lib"
|
||||
export G4LIB
|
||||
echo "On this machine the G4LIB=\$G4LIB"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4lib != X ] ; then
|
||||
G4BIN="$g4lib/../bin"
|
||||
export G4BIN
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4levelgammadata != X ] ; then
|
||||
G4LEVELGAMMADATA="$g4levelgammadata"
|
||||
export G4LEVELGAMMADATA
|
||||
echo "On this machine the G4LEVELGAMMADATA=\$G4LEVELGAMMADATA"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4radioactivedata != X ] ; then
|
||||
G4RADIOACTIVEDATA="$g4radioactivedata"
|
||||
export G4RADIOACTIVEDATA
|
||||
echo "On this machine the G4RADIOACTIVEDATA=\$G4RADIOACTIVEDATA"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4ledata != X ] ; then
|
||||
G4LEDATA="$g4ledata"
|
||||
export G4LEDATA
|
||||
echo "On this machine the G4LEDATA=\$G4LEDATA"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4neutronhpcrosssections != X ] ; then
|
||||
NeutronHPCrossSections="$g4neutronhpcrosssections"
|
||||
export NeutronHPCrossSections
|
||||
echo "On this machine the NeutronHPCrossSections=\$NeutronHPCrossSections"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4elasticdata != X ] ; then
|
||||
G4ELASTICDATA="$g4elasticdata"
|
||||
export G4ELASTICDATA
|
||||
echo "On this machine the G4ELASTICDATA=\$G4ELASTICDATA"
|
||||
fi
|
||||
|
||||
#
|
||||
# g4clhep.U
|
||||
#
|
||||
if [ X$g4clhep_base_dir != X/usr -o X$g4clhep_base_dir != X/usr/local ] ; then
|
||||
CLHEP_BASE_DIR="$g4clhep_base_dir"
|
||||
export CLHEP_BASE_DIR
|
||||
echo "On this machine the CLHEP_BASE_DIR=\$CLHEP_BASE_DIR"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4clhep_include_dir != X ] ; then
|
||||
CLHEP_INCLUDE_DIR="$g4clhep_include_dir"
|
||||
export CLHEP_INCLUDE_DIR
|
||||
echo "On this machine the CLHEP_INCLUDE_DIR=\$CLHEP_INCLUDE_DIR"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4clhep_lib_dir != X ] ; then
|
||||
CLHEP_LIB_DIR="$g4clhep_lib_dir"
|
||||
export CLHEP_LIB_DIR
|
||||
echo "On this machine the CLHEP_LIB_DIR=\$CLHEP_LIB_DIR"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4clhep_lib != X ] ; then
|
||||
CLHEP_LIB="$g4clhep_lib"
|
||||
export CLHEP_LIB
|
||||
echo "On this machine the CLHEP_LIB=\$CLHEP_LIB"
|
||||
fi
|
||||
|
||||
#+
|
||||
#
|
||||
# g4debug
|
||||
#
|
||||
if [ X$g4debug != X ] ; then
|
||||
G4DEBUG="$g4debug"
|
||||
export G4DEBUG
|
||||
echo "On this machine the G4DEBUG=\$G4DEBUG"
|
||||
fi
|
||||
|
||||
#
|
||||
# g4analysis
|
||||
#
|
||||
#+
|
||||
if [ X$g4wanalysis_use = Xy ] ; then
|
||||
G4ANALYSIS_USE=1
|
||||
export G4ANALYSIS_USE
|
||||
echo "On this machine the G4ANALYSIS_USE=\$G4ANALYSIS_USE"
|
||||
fi
|
||||
|
||||
#
|
||||
# g4ui
|
||||
#
|
||||
#+
|
||||
if [ X$g4ui_build_xaw_session = Xy ] ; then
|
||||
G4UI_BUILD_XAW_SESSION=1
|
||||
export G4UI_BUILD_XAW_SESSION
|
||||
echo "On this machine the G4UI_BUILD_XAW_SESSION=\$G4UI_BUILD_XAW_SESSION"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4ui_use_xaw = Xy ] ; then
|
||||
G4UI_USE_XAW=1
|
||||
export G4UI_USE_XAW
|
||||
echo "On this machine the G4UI_USE_XAW=\$G4UI_USE_XAW"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4ui_build_xm_session = Xy ] ; then
|
||||
G4UI_BUILD_XM_SESSION=1
|
||||
export G4UI_BUILD_XM_SESSION
|
||||
echo "On this machine the G4UI_BUILD_XM_SESSION=\$G4UI_BUILD_XM_SESSION"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4ui_use_xm = Xy ] ; then
|
||||
G4UI_USE_XM=1
|
||||
export G4UI_USE_XM
|
||||
echo "On this machine the G4UI_USE_XM=\$G4UI_USE_XM"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4ui_build_win32_session = Xy ] ; then
|
||||
G4UI_BUILD_WIN32_SESSION=1
|
||||
export G4UI_BUILD_WIN32_SESSION
|
||||
echo "On this machine the G4UI_BUILD_WIN32_SESSION=\$G4UI_BUILD_WIN32_SESSION"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4ui_use_win32 = Xy ] ; then
|
||||
G4UI_USE_WIN32=1
|
||||
export G4UI_USE_WIN32
|
||||
echo "On this machine the G4UI_USE_WIN32=\$G4UI_USE_WIN32"
|
||||
fi
|
||||
|
||||
#
|
||||
# g4vis
|
||||
#
|
||||
#+
|
||||
if [ X$g4vis_build_dawn_driver = Xy ] ; then
|
||||
G4VIS_BUILD_DAWN_DRIVER=1
|
||||
export G4VIS_BUILD_DAWN_DRIVER
|
||||
echo "On this machine the G4VIS_BUILD_DAWN_DRIVER=\$G4VIS_BUILD_DAWN_DRIVER"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_build_openglx_driver = Xy ] ; then
|
||||
G4VIS_BUILD_OPENGLX_DRIVER=1
|
||||
export G4VIS_BUILD_OPENGLX_DRIVER
|
||||
echo "On this machine the G4VIS_BUILD_OPENGLX_DRIVER=\$G4VIS_BUILD_OPENGLX_DRIVER"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_build_openglxm_driver = Xy ] ; then
|
||||
G4VIS_BUILD_OPENGLXM_DRIVER=1
|
||||
export G4VIS_BUILD_OPENGLXM_DRIVER
|
||||
echo "On this machine the G4VIS_BUILD_OPENGLXM_DRIVER=\$G4VIS_BUILD_OPENGLXM_DRIVER"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_build_openglwin32_driver = Xy ] ; then
|
||||
G4VIS_BUILD_OPENGLWIN32_DRIVER=1
|
||||
export G4VIS_BUILD_OPENGLWIN32_DRIVER
|
||||
echo "On this machine the G4VIS_BUILD_OPENGLWIN32_DRIVER=\$G4VIS_BUILD_OPENGLWIN32_DRIVER"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_build_oix_driver = Xy ] ; then
|
||||
G4VIS_BUILD_OIX_DRIVER=1
|
||||
export G4VIS_BUILD_OIX_DRIVER
|
||||
echo "On this machine the G4VIS_BUILD_OIX_DRIVER=\$G4VIS_BUILD_OIX_DRIVER"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_build_oiwin32_driver = Xy ] ; then
|
||||
G4VIS_BUILD_OIWIN32_DRIVER=1
|
||||
export G4VIS_BUILD_OIWIN32_DRIVER
|
||||
echo "On this machine the G4VIS_BUILD_OIWIN32_DRIVER=\$G4VIS_BUILD_OIWIN32_DRIVER"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_build_vrml_driver = Xy ] ; then
|
||||
G4VIS_BUILD_VRML_DRIVER=1
|
||||
export G4VIS_BUILD_VRML_DRIVER
|
||||
echo "On this machine the G4VIS_BUILD_VRML_DRIVER=\$G4VIS_BUILD_VRML_DRIVER"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_use_dawn = Xy ] ; then
|
||||
G4VIS_USE_DAWN=1
|
||||
export G4VIS_USE_DAWN
|
||||
echo "On this machine the G4VIS_USE_DAWN=\$G4VIS_USE_DAWN"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_use_openglx = Xy ] ; then
|
||||
G4VIS_USE_OPENGLX=1
|
||||
export G4VIS_USE_OPENGLX
|
||||
echo "On this machine the G4VIS_USE_OPENGLX=\$G4VIS_USE_OPENGLX"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_use_openglxm = Xy ] ; then
|
||||
G4VIS_USE_OPENGLXM=1
|
||||
export G4VIS_USE_OPENGLXM
|
||||
echo "On this machine the G4VIS_USE_OPENGLXM=\$G4VIS_USE_OPENGLXM"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_use_openglwin32 = Xy ] ; then
|
||||
G4VIS_USE_OPENGLWIN32=1
|
||||
export G4VIS_USE_OPENGLWIN32
|
||||
echo "On this machine the G4VIS_USE_OPENGLWIN32=\$G4VIS_USE_OPENGLWIN32"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_use_oix = Xy ] ; then
|
||||
G4VIS_USE_OIX=1
|
||||
export G4VIS_USE_OIX
|
||||
echo "On this machine the G4VIS_USE_OIX=\$G4VIS_USE_OIX"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_use_oiwin32 = Xy ] ; then
|
||||
G4VIS_USE_OIWIN32=1
|
||||
export G4VIS_USE_OIWIN32
|
||||
echo "On this machine the G4VIS_USE_OIWIN32=\$G4VIS_USE_OIWIN32"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_use_vrml = Xy ] ; then
|
||||
G4VIS_USE_VRML=1
|
||||
export G4VIS_USE_VRML
|
||||
echo "On this machine the G4VIS_USE_VRML=\$G4VIS_USE_VRML"
|
||||
fi
|
||||
|
||||
#+
|
||||
if [ X$g4vis_oglhome != X ] ; then
|
||||
OGLHOME="$g4vis_oglhome"
|
||||
export OGLHOME
|
||||
echo "On this machine the OGLHOME=\$OGLHOME"
|
||||
fi
|
||||
|
||||
#
|
||||
# Use G3TOG4 module
|
||||
#
|
||||
#+
|
||||
if [ X$g4wlib_build_g3tog4 = Xy ] ; then
|
||||
G4LIB_BUILD_G3TOG4=1
|
||||
export G4LIB_BUILD_G3TOG4
|
||||
echo "On this machine the G4LIB_BUILD_G3TOG4=\$G4LIB_BUILD_G3TOG4"
|
||||
fi
|
||||
|
||||
if [ X$g4w_use_g3tog4 = Xy ] ; then
|
||||
G4USE_G3TOG4=1
|
||||
export G4USE_G3TOG4
|
||||
echo "On this machine the G4USE_G3TOG4=\$G4USE_G3TOG4"
|
||||
fi
|
||||
|
||||
#+
|
||||
#
|
||||
# g4shared
|
||||
#
|
||||
if [ X$g4lib_build_shared = Xy ] ; then
|
||||
G4LIB_BUILD_SHARED=1
|
||||
export G4LIB_BUILD_SHARED
|
||||
echo "On this machine the G4LIB_BUILD_SHARED=\$G4LIB_BUILD_SHARED"
|
||||
fi
|
||||
|
||||
if [ X$g4lib_build_static = Xy ] ; then
|
||||
G4LIB_BUILD_STATIC=1
|
||||
export G4LIB_BUILD_STATIC
|
||||
echo "On this machine the G4LIB_BUILD_STATIC=\$G4LIB_BUILD_STATIC"
|
||||
fi
|
||||
|
||||
#+
|
||||
#
|
||||
# g4granular
|
||||
#
|
||||
if [ X$g4lib_use_granular = Xy ] ; then
|
||||
G4LIB_USE_GRANULAR=1
|
||||
export G4LIB_USE_GRANULAR
|
||||
echo "On this machine the G4LIB_USE_GRANULAR=\$G4LIB_USE_GRANULAR"
|
||||
fi
|
||||
|
||||
#####################################################################
|
||||
|
||||
#####################################################################
|
||||
|
||||
echo ""
|
||||
echo "Starting installation..."
|
||||
echo ""
|
||||
|
||||
cd $g4install
|
||||
#echo `pwd`
|
||||
|
||||
|
||||
# Remove 'verbosity' in 'tar' command
|
||||
# If not INCLUDE then install full tree in 'src' directory!
|
||||
#
|
||||
if [ X$g4includes_flag = Xn ] ; then
|
||||
if [ X$g4install != X$g4final_install ] ; then
|
||||
echo ""
|
||||
echo "Installing sources and headers..."
|
||||
echo ""
|
||||
mkdir -p $g4final_install/src/geant4/
|
||||
tar cf - Configure config/ source/ environments/ physics_lists/ examples/ |(cd $g4final_install/src/geant4/; tar xf -)
|
||||
fi
|
||||
fi
|
||||
|
||||
########################################
|
||||
# There is no env!
|
||||
if [ X$g4includes_flag = Xy ] ; then
|
||||
|
||||
if [ X$g4install != X$g4final_install ] ; then
|
||||
echo ""
|
||||
echo "Installing sources..."
|
||||
echo ""
|
||||
|
||||
mkdir -p $g4final_install/src/geant4/
|
||||
tar cf - Configure config/ source/ environments/ physics_lists/ examples/ |(cd $g4final_install/src/geant4/; tar xf -)
|
||||
fi
|
||||
|
||||
echo ""
|
||||
echo "Installing headers..."
|
||||
echo ""
|
||||
cd $g4install/source
|
||||
$g4make includes dependencies=""
|
||||
fi
|
||||
|
||||
# Move libraries
|
||||
if [ X$g4install != X$g4final_install ] ; then
|
||||
echo ""
|
||||
echo "Installing libraries..."
|
||||
echo ""
|
||||
mkdir -p $g4final_install/lib/geant4
|
||||
cd $g4install/lib
|
||||
tar cf - $g4system |(cd $g4final_install/lib/geant4; tar xf -)
|
||||
fi
|
||||
|
||||
# For the reason of strange behaivior for DOTted directory...
|
||||
mkdir -p $g4final_install/src/geant4/.config
|
||||
cd $g4install/.config
|
||||
tar cf - . |(cd $g4final_install/src/geant4/.config; tar xf -)
|
||||
|
||||
|
||||
!GROK!THIS!
|
||||
|
||||
: In the following dollars and backticks do not need the extra backslash.
|
||||
$spitshell >>move.sh <<'!NO!SUBS!'
|
||||
!NO!SUBS!
|
||||
chmod 755 move.sh
|
||||
$eunicefix move.sh
|
||||
|
||||
@@ -41,9 +41,11 @@ ifeq ($(G4SYSTEM),Darwin-g++)
|
||||
ECHO := /bin/echo -n
|
||||
SHEXT := dylib
|
||||
X11FLAGS := -I/usr/include/X11/extensions -I/usr/include/X11
|
||||
X11LIBS := -L/usr/X11R6/lib -lXmu -lXt -lXext -lX11 -lSM -lICE
|
||||
X11LIBS := -L/usr/X11R6/lib -lXmu -lXt -lXext -lX11 -lXi -lSM -lICE
|
||||
XMFLAGS := -I/sw/include
|
||||
# XMFLAGS := -I/usr/X11R6/include ##### some installations.
|
||||
XMLIBS := -L/sw/lib -lXm -lXpm
|
||||
# XMLIBS := -L/usr/X11R6/lib -lXm -lXpm ##### some installations.
|
||||
DLDLIBS := -ldl
|
||||
ifndef OGLHOME
|
||||
OGLHOME := /usr/X11R6
|
||||
@@ -54,14 +56,38 @@ ifeq ($(G4SYSTEM),Darwin-g++)
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := -L$(OGLHOME)/lib -lGLU -lGL
|
||||
endif
|
||||
#
|
||||
# There are two ways to build shared libs (.dylib) on MacOSX.
|
||||
# Up to now the "flat_namespace" option had been used ; but
|
||||
# due to the fact that Apple promotes now the "two_level_namespace"
|
||||
# way of doing, we had tried to build the shared libs in this way.
|
||||
# But it appears that for the moment this option induces
|
||||
# unresolved early crashes at runtim. These crashes are
|
||||
# probably due to a problem in the sequence of execution
|
||||
# of constructor of static objects that are now heavily
|
||||
# used in Geant4.
|
||||
# Waiting a solution to that, we put the "flat_namespace"
|
||||
# way of doing as the default to build the .dylib (knowing
|
||||
# that it is anyway not a long term solution).
|
||||
# G.Barrand (16/07/2004)
|
||||
#
|
||||
#### G4_MACOSX_TWO_LEVEL_NAMESPACE = 1
|
||||
ifdef G4_MACOSX_TWO_LEVEL_NAMESPACE
|
||||
define build-granular-shared-lib
|
||||
@libdir=`(cd $(@D);/bin/pwd)`; \
|
||||
cd $(G4TMPDIR); \
|
||||
g++ -dynamiclib -twolevel_namespace -undefined error -dynamic \
|
||||
g++ -dynamiclib -twolevel_namespace -undefined define_a_way -dynamic \
|
||||
-single_module -o $$libdir/$(@F) *.o -L$(G4LIB)/$(G4SYSTEM) \
|
||||
$(patsubst lib%,-l%,$(patsubst %.lib,%,$(GLOBLIBS))) \
|
||||
-L$(CLHEP_LIB_DIR) -l$(CLHEP_LIB) $(INTYLIBS)
|
||||
endef
|
||||
else
|
||||
define build-granular-shared-lib
|
||||
@libdir=`(cd $(@D);/bin/pwd)`; \
|
||||
cd $(G4TMPDIR); \
|
||||
g++ -dynamiclib -flat_namespace -undefined suppress -dynamic -single_module -o $$libdir/$(@F) $(INTYLIBS) *.o
|
||||
endef
|
||||
endif
|
||||
ifdef G4_MACOSX_TWO_LEVEL_NAMESPACE
|
||||
define build-global-shared-lib
|
||||
@libdir=`(cd $(@D);/bin/pwd)`; \
|
||||
cd $(G4TMP)/$(G4SYSTEM); \
|
||||
@@ -71,5 +97,12 @@ ifeq ($(G4SYSTEM),Darwin-g++)
|
||||
$(patsubst lib%,-l%,$(patsubst %.lib,%,$(GLOBLIBS))) \
|
||||
-L$(CLHEP_LIB_DIR) -l$(CLHEP_LIB) $(INTYLIBS);
|
||||
endef
|
||||
else
|
||||
define build-global-shared-lib
|
||||
@libdir=`(cd $(@D);/bin/pwd)`; \
|
||||
cd $(G4TMP)/$(G4SYSTEM); \
|
||||
g++ -dynamiclib -flat_namespace -undefined suppress -dynamic -single_module -o $$libdir/$(@F) $(INTYLIBS) $(foreach dir,$(SUBLIBS),$(dir)/*.o);
|
||||
endef
|
||||
endif
|
||||
|
||||
endif
|
||||
|
||||
@@ -12,7 +12,6 @@ ifeq ($(G4SYSTEM),SUN-CC)
|
||||
CCFLAGS := -g
|
||||
endif
|
||||
endif
|
||||
CXXFLAGS += -features=no%anachronisms -mt -lpthread
|
||||
ifdef G4LIB_BUILD_SHARED
|
||||
CXXFLAGS += -KPIC
|
||||
FCFLAGS += -KPIC
|
||||
|
||||
+27
-3
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# ------ WIN32/VC ------ Visual-C++ 6.0 SP5
|
||||
# ------ WIN32/VC ------ Visual-C++ 7 .NET
|
||||
#
|
||||
ifeq ($(G4SYSTEM),WIN32-VC)
|
||||
CXX := CL
|
||||
@@ -12,9 +12,9 @@ ifeq ($(G4SYSTEM),WIN32-VC)
|
||||
endif
|
||||
CXXFLAGS += -MD -GR -GX -Zm200 -nologo -DWIN32
|
||||
CXXFLAGS += -D_CONSOLE -D_WIN32 -DOS
|
||||
CPPFLAGS += -DWIN32
|
||||
CPPFLAGS += -DWIN32 -DXPNET
|
||||
LDFLAGS += -FORCE /NODEFAULTLIB:MSVCRT.dll
|
||||
|
||||
|
||||
SHEXT := dll
|
||||
AR := LIB
|
||||
ECHO := echo -e
|
||||
@@ -30,6 +30,30 @@ ifeq ($(G4SYSTEM),WIN32-VC)
|
||||
UI32LIBS := gdi32.lib user32.lib
|
||||
endif
|
||||
|
||||
#
|
||||
# Building DLLs (G.Barrand)
|
||||
# -------------
|
||||
# The commands below allow to build DLLs from the archive libraries.
|
||||
# From a libG4xxx.a, it will extract the symbols with :
|
||||
# DOS> dumpbin /symbols libG4xxx.a > G4xxx.dumpbin
|
||||
# After that it will produce a G4xxx.def using the 'win32def' program.
|
||||
# The G4xxx.def file will contain the list of symbols that are "exported"
|
||||
# or made public for using the DLLs.
|
||||
# The source win32def.c is in the geant4/config directory. The binary is
|
||||
# built during the library installation process, and will be placed in
|
||||
# $G4LIB/G4SYSTEM.
|
||||
# If can also be built as follows :
|
||||
# DOS> cl.exe /Fowin32def.exe win32def.c
|
||||
# Then, to use it :
|
||||
# DOS> win32def G4xxx < G4xxx.dumpbin > G4xxx.def
|
||||
# Libraries libG4xxx.lib can also be built with :
|
||||
# DOS> lib /def:G4xxx.def /out:libG4xxx.lib
|
||||
# It also produces a libG4xxx.exp used to build the DLL.
|
||||
# The DLL can be built with :
|
||||
# DOS> link /dll /out:G4xxx.dll libG4xxx.exp libG4xxx.a <dependencies>
|
||||
# Note that a DLL must be fully linked. You should NOT have undefined
|
||||
# symbols as output of the link command.
|
||||
#
|
||||
define build-granular-shared-lib
|
||||
@libdir=`(cd $(@D);/bin/pwd)`;\
|
||||
cd $(G4TMP)/$(G4SYSTEM);\
|
||||
|
||||
@@ -1,103 +0,0 @@
|
||||
#
|
||||
# ------ WIN32/VC ------ Visual-C++ 7 .NET
|
||||
#
|
||||
ifeq ($(G4SYSTEM),WIN32-VC7)
|
||||
CXX := CL
|
||||
ifdef G4OPTIMISE
|
||||
CXXFLAGS += -Ox
|
||||
else
|
||||
ifdef G4DEBUG
|
||||
CXXFLAGS += -Od -Zi -Fd$(G4LIBDIR)/lib$(name)
|
||||
endif
|
||||
endif
|
||||
CXXFLAGS += -MD -GR -GX -Zm200 -nologo -DWIN32
|
||||
CXXFLAGS += -D_CONSOLE -D_WIN32 -DOS
|
||||
CPPFLAGS += -DWIN32 -DXPNET
|
||||
LDFLAGS += -FORCE /NODEFAULTLIB:MSVCRT.dll
|
||||
|
||||
SHEXT := dll
|
||||
AR := LIB
|
||||
ECHO := echo -e
|
||||
FC := g77
|
||||
# FCLIBS := -lf2c
|
||||
ifndef OGLFLAGS
|
||||
OGLFLAGS :=
|
||||
endif
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := glu32.lib opengl32.lib
|
||||
endif
|
||||
ifndef UI32LIBS
|
||||
UI32LIBS := gdi32.lib user32.lib
|
||||
endif
|
||||
|
||||
#
|
||||
# Building DLLs (G.Barrand)
|
||||
# -------------
|
||||
# The commands below allow to build DLLs from the archive libraries.
|
||||
# From a libG4xxx.a, it will extract the symbols with :
|
||||
# DOS> dumpbin /symbols libG4xxx.a > G4xxx.dumpbin
|
||||
# After that it will produce a G4xxx.def using the 'win32def' program.
|
||||
# The G4xxx.def file will contain the list of symbols that are "exported"
|
||||
# or made public for using the DLLs.
|
||||
# The source win32def.c is in the geant4/config directory. The binary is
|
||||
# built during the library installation process, and will be placed in
|
||||
# $G4LIB/G4SYSTEM.
|
||||
# If can also be built as follows :
|
||||
# DOS> cl.exe /Fowin32def.exe win32def.c
|
||||
# Then, to use it :
|
||||
# DOS> win32def G4xxx < G4xxx.dumpbin > G4xxx.def
|
||||
# Libraries libG4xxx.lib can also be built with :
|
||||
# DOS> lib /def:G4xxx.def /out:libG4xxx.lib
|
||||
# It also produces a libG4xxx.exp used to build the DLL.
|
||||
# The DLL can be built with :
|
||||
# DOS> link /dll /out:G4xxx.dll libG4xxx.exp libG4xxx.a <dependencies>
|
||||
# Note that a DLL must be fully linked. You should NOT have undefined
|
||||
# symbols as output of the link command.
|
||||
#
|
||||
define build-granular-shared-lib
|
||||
@libdir=`(cd $(@D);/bin/pwd)`;\
|
||||
cd $(G4TMP)/$(G4SYSTEM);\
|
||||
echo "Building $(name).dumpbin file ...";\
|
||||
$(RM) $(name).dumpbin;\
|
||||
dumpbin /symbols $(G4LIBDIR)/lib$(name).a > $(name).dumpbin;\
|
||||
echo "Building $(name).def file ...";\
|
||||
$(RM) $(name).def;\
|
||||
$(G4LIB)/$(G4SYSTEM)/win32def.exe $(name) < $(name).dumpbin > $(name).def;\
|
||||
$(RM) $(name).dumpbin;\
|
||||
echo "Building lib$(name).exp and lib$(name).lib file ...";\
|
||||
$(RM) $(G4LIBDIR)/lib$(name).exp;\
|
||||
$(RM) $(G4LIBDIR)/lib$(name).lib;\
|
||||
lib.exe /nologo /machine:ix86 /def:$(name).def \
|
||||
/out:$(G4LIBDIR)/lib$(name).lib;\
|
||||
$(RM) $(G4LIBDIR)/$(name).dll;\
|
||||
echo "Building $(name).dll file ...";\
|
||||
link.exe /nologo /dll /out:$(G4LIBDIR)/$(name).dll \
|
||||
$(G4LIBDIR)/lib$(name).exp $(G4LIBDIR)/lib$(name).a \
|
||||
/libpath:$(G4LIBDIR) $(GLOBLIBS) \
|
||||
$(LIB_PATH)$(CLHEP_LIB_DIR) $(CLHEP_LIB) \
|
||||
$(INTYLIBS) $(ANALYSISLIBS) $(UI32LIBS)
|
||||
endef
|
||||
define build-global-shared-lib
|
||||
@libdir=`(cd $(@D);/bin/pwd)`;\
|
||||
cd $(G4TMP)/$(G4SYSTEM);\
|
||||
echo "Building $(name).dumpbin file ...";\
|
||||
$(RM) $(name).dumpbin;\
|
||||
dumpbin /symbols $(G4LIBDIR)/lib$(name).a > $(name).dumpbin;\
|
||||
echo "Building $(name).def file ...";\
|
||||
$(RM) $(name).def;\
|
||||
$(G4LIB)/$(G4SYSTEM)/win32def.exe $(name) < $(name).dumpbin > $(name).def;\
|
||||
$(RM) $(name).dumpbin;\
|
||||
echo "Building lib$(name).exp and lib$(name).lib ...";\
|
||||
$(RM) $(G4LIBDIR)/lib$(name).exp;\
|
||||
$(RM) $(G4LIBDIR)/lib$(name).lib;\
|
||||
lib.exe /nologo /machine:ix86 /def:$(name).def \
|
||||
/out:$(G4LIBDIR)/lib$(name).lib;\
|
||||
$(RM) $(G4LIBDIR)/$(name).dll;\
|
||||
echo "Building $(name).dll ...";\
|
||||
link.exe /nologo /dll /out:$(G4LIBDIR)/$(name).dll \
|
||||
$(G4LIBDIR)/lib$(name).exp $(G4LIBDIR)/lib$(name).a \
|
||||
/libpath:$(G4LIBDIR) $(GLOBLIBS) \
|
||||
$(LIB_PATH)$(CLHEP_LIB_DIR) $(CLHEP_LIB) \
|
||||
$(INTYLIBS) $(ANALYSISLIBS) $(UI32LIBS)
|
||||
endef
|
||||
endif
|
||||
Reference in New Issue
Block a user