Import Geant4 0.0.0 source tree
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
# $Id: G4ODBMS_BUILD.gmk,v 2.1 1998/07/09 13:00:42 morita Exp $
|
||||
# ----------------------------------------------------------------
|
||||
# GNUmakefile for CPPFLAGS for HepODBMS and Objectivity/DB.
|
||||
# Youhei Morita, 9th July 1998.
|
||||
#--------------------------------------------------------------------
|
||||
# Objectivity and HepODBMS definitions
|
||||
|
||||
ifdef OBJY_DIR
|
||||
CPPFLAGS += -I$(OBJY_DIR)/include
|
||||
endif
|
||||
|
||||
ifdef HEP_ODBMS_DIR
|
||||
CPPFLAGS += -I$(HEP_ODBMS_DIR)/include \
|
||||
-DHep_HAS_BUILDIN_BOOL_CONSTANTS
|
||||
endif
|
||||
#--------------------------------------------------------------------
|
||||
@@ -0,0 +1,69 @@
|
||||
# $Id: G4UI_BUILD.gmk,v 2.7 1998/10/23 15:14:36 barrand Exp $
|
||||
# -------------------------------------------------------------
|
||||
# Interfaces-specific CPPFLAGS for BUILD phase.
|
||||
# John Allison, 6th July 1998.
|
||||
# Include this *after* architecture.gmk
|
||||
# Include this *before* interactivity.gmk
|
||||
|
||||
########################### interfaces/basic #######################
|
||||
|
||||
ifndef G4UI_BUILD_TERMINAL_SESSION
|
||||
G4UI_BUILD_TERMINAL_SESSION = 1
|
||||
endif
|
||||
|
||||
ifdef G4UI_BUILD_TERMINAL_SESSION
|
||||
G4UI_BUILD = 1
|
||||
G4UI_BUILD_BASIC_SESSION = 1
|
||||
CPPFLAGS += -DG4UI_BUILD_TERMINAL_SESSION
|
||||
endif
|
||||
|
||||
ifdef G4UI_BUILD_XM_SESSION
|
||||
G4UI_BUILD = 1
|
||||
G4UI_BUILD_BASIC_SESSION = 1
|
||||
G4INTY_BUILD_XT = 1
|
||||
INC_XM = 1
|
||||
CPPFLAGS += -DG4UI_BUILD_XM_SESSION
|
||||
endif
|
||||
|
||||
ifdef G4UI_BUILD_XAW_SESSION
|
||||
G4UI_BUILD = 1
|
||||
G4UI_BUILD_BASIC_SESSION = 1
|
||||
G4INTY_BUILD_XT = 1
|
||||
INC_XAW = 1
|
||||
CPPFLAGS += -DG4UI_BUILD_XAW_SESSION
|
||||
endif
|
||||
|
||||
ifdef G4UI_BUILD_WIN32_SESSION
|
||||
G4UI_BUILD = 1
|
||||
G4UI_BUILD_BASIC_SESSION = 1
|
||||
G4INTY_BUILD_WIN32 = 1
|
||||
CPPFLAGS += -DG4UI_BUILD_WIN32_SESSION
|
||||
endif
|
||||
|
||||
########################### interfaces/GAG #######################
|
||||
|
||||
ifdef G4UI_BUILD_GAG_SESSION
|
||||
G4UI_BUILD = 1
|
||||
CPPFLAGS += -DG4UI_BUILD_GAG_SESSION
|
||||
endif
|
||||
|
||||
########################### interfaces/OPACS #######################
|
||||
|
||||
ifdef G4UI_BUILD_WO_SESSION
|
||||
G4UI_BUILD = 1
|
||||
G4INTY_BUILD_XT = 1
|
||||
INC_OPACS = 1
|
||||
CPPFLAGS += -DG4UI_BUILD_WO_SESSION
|
||||
endif
|
||||
|
||||
########################### interfaces/XVT - not currently implemented #####
|
||||
|
||||
############################################################################
|
||||
|
||||
ifdef G4UI_BUILD
|
||||
CPPFLAGS += -DG4UI_BUILD
|
||||
endif
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,79 @@
|
||||
# $Id: G4UI_USE.gmk,v 2.7 1998/08/26 11:05:37 allison Exp $
|
||||
# -------------------------------------------------------------
|
||||
# GNUmakefile for CPPFLAGS for interfaces USE phase.
|
||||
# John Allison, 6th July 1998.
|
||||
|
||||
########################### interfaces/basic #######################
|
||||
|
||||
UILIBS :=
|
||||
|
||||
ifndef G4UI_USE_TERMINAL
|
||||
G4UI_USE_TERMINAL = 1
|
||||
endif
|
||||
|
||||
ifdef G4UI_USE_TERMINAL
|
||||
G4UI_USE = 1
|
||||
G4UI_USE_BASIC = 1
|
||||
CPPFLAGS += -DG4UI_USE_TERMINAL
|
||||
endif
|
||||
|
||||
ifdef G4UI_USE_XM
|
||||
G4UI_USE = 1
|
||||
G4UI_USE_BASIC = 1
|
||||
G4INTY_USE_XT = 1
|
||||
INC_XM = 1
|
||||
LOAD_XM = 1
|
||||
CPPFLAGS += -DG4UI_USE_XM
|
||||
endif
|
||||
|
||||
ifdef G4UI_USE_XAW
|
||||
G4UI_USE = 1
|
||||
G4UI_USE_BASIC = 1
|
||||
G4INTY_USE_XT = 1
|
||||
INC_XAW = 1
|
||||
LOAD_XAW = 1
|
||||
CPPFLAGS += -DG4UI_USE_XAW
|
||||
endif
|
||||
|
||||
ifdef G4UI_USE_WIN32
|
||||
G4UI_USE = 1
|
||||
G4UI_USE_BASIC = 1
|
||||
G4INTY_USE_WIN32 = 1
|
||||
CPPFLAGS += -DG4UI_USE_WIN32
|
||||
endif
|
||||
|
||||
ifdef G4UI_USE_BASIC
|
||||
CPPFLAGS += -I$(G4BASE)/interfaces/basic/include
|
||||
UILIBS += -lG4UIbasic
|
||||
endif
|
||||
|
||||
########################### interfaces/GAG #######################
|
||||
|
||||
ifdef G4UI_USE_GAG
|
||||
G4UI_USE = 1
|
||||
CPPFLAGS += -DG4UI_USE_GAG
|
||||
CPPFLAGS += -I$(G4BASE)/interfaces/GAG/include
|
||||
UILIBS += -lG4UIGAG
|
||||
endif
|
||||
|
||||
########################### interfaces/OPACS #######################
|
||||
|
||||
ifdef G4UI_USE_WO
|
||||
G4UI_USE = 1
|
||||
G4INTY_USE_XT = 1
|
||||
CPPFLAGS += -DG4UI_USE_WO
|
||||
CPPFLAGS += -I$(G4BASE)/interfaces/OPACS/include
|
||||
UILIBS += -lG4UIOPACS
|
||||
INC_OPACS = 1
|
||||
LOAD_OPACS = 1
|
||||
endif
|
||||
|
||||
########################### interfaces/XVT - not currently implemented #####
|
||||
|
||||
########################### and finally... #######################
|
||||
|
||||
ifdef G4UI_USE
|
||||
CPPFLAGS += -DG4UI_USE
|
||||
CPPFLAGS += -I$(G4BASE)/interfaces/common/include
|
||||
UILIBS += -lG4UIcommon
|
||||
endif
|
||||
@@ -0,0 +1,86 @@
|
||||
# $Id: G4VIS_BUILD.gmk,v 1.2 1998/07/07 15:10:33 allison Exp $
|
||||
# -------------------------------------------------------------
|
||||
# Visualization-specific CPPFLAGS for BUILD phase.
|
||||
# John Allison, 24th January 1998.
|
||||
# Include this *after* architecture.gmk
|
||||
# Include this *before* interactivity.gmk
|
||||
|
||||
|
||||
# For DAWN and DAWNFILE drivers
|
||||
ifdef G4VIS_BUILD_DAWN_DRIVER
|
||||
G4VIS_BUILD = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_DAWN_DRIVER
|
||||
endif
|
||||
ifdef G4VIS_BUILD_DAWNFILE_DRIVER
|
||||
G4VIS_BUILD = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_DAWNFILE_DRIVER
|
||||
endif
|
||||
# End of DAWN and DAWNFILE drivers
|
||||
|
||||
ifdef G4VIS_BUILD_OPACS_DRIVER
|
||||
G4VIS_BUILD = 1
|
||||
G4INTY_BUILD_XT = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_OPACS_DRIVER
|
||||
INC_OPACS = 1
|
||||
endif
|
||||
|
||||
ifdef G4VIS_BUILD_OPENGLX_DRIVER
|
||||
G4VIS_BUILD_OPENGL_DRIVER = 1
|
||||
INC_X11 = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_OPENGLX_DRIVER
|
||||
endif
|
||||
ifdef G4VIS_BUILD_OPENGLWIN32_DRIVER
|
||||
G4VIS_BUILD_OPENGL_DRIVER = 1
|
||||
G4INTY_BUILD_WIN32 = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_OPENGLWIN32_DRIVER
|
||||
endif
|
||||
ifdef G4VIS_BUILD_OPENGLXM_DRIVER
|
||||
G4VIS_BUILD_OPENGL_DRIVER = 1
|
||||
G4INTY_BUILD_XT = 1
|
||||
INC_XM = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_OPENGLXM_DRIVER
|
||||
endif
|
||||
ifdef G4VIS_BUILD_OPENGL_DRIVER
|
||||
G4VIS_BUILD = 1
|
||||
INC_GL = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_OPENGL_DRIVER
|
||||
endif
|
||||
|
||||
ifdef G4VIS_BUILD_OIX_DRIVER
|
||||
G4VIS_BUILD_OI_DRIVER = 1
|
||||
G4INTY_BUILD_XT = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_OIX_DRIVER
|
||||
endif
|
||||
ifdef G4VIS_BUILD_OIWIN32_DRIVER
|
||||
G4VIS_BUILD_OI_DRIVER = 1
|
||||
G4INTY_BUILD_WIN32 = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_OIWIN32_DRIVER
|
||||
endif
|
||||
ifdef G4VIS_BUILD_OI_DRIVER
|
||||
G4VIS_BUILD = 1
|
||||
INC_IV = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_OI_DRIVER
|
||||
endif
|
||||
|
||||
ifdef G4VIS_BUILD_RAYX_DRIVER
|
||||
G4VIS_BUILD = 1
|
||||
INC_X11 = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_RAYX_DRIVER
|
||||
endif
|
||||
|
||||
# For VRML and VRMLFILE drivers
|
||||
ifdef G4VIS_BUILD_VRML_DRIVER
|
||||
G4VIS_BUILD = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_VRML_DRIVER
|
||||
endif
|
||||
ifdef G4VIS_BUILD_VRMLFILE_DRIVER
|
||||
G4VIS_BUILD = 1
|
||||
CPPFLAGS += -DG4VIS_BUILD_VRMLFILE_DRIVER
|
||||
endif
|
||||
# End of VRML and VRMLFILE drivers
|
||||
|
||||
ifdef G4VIS_BUILD
|
||||
CPPFLAGS += -DG4VIS_BUILD
|
||||
endif
|
||||
|
||||
|
||||
@@ -0,0 +1,112 @@
|
||||
# $Id: G4VIS_USE.gmk,v 1.7 1998/12/07 03:48:44 stanaka Exp $
|
||||
# -------------------------------------------------------------
|
||||
# GNUmakefile for CPPFLAGS for visualization USE phase.
|
||||
# John Allison, 24th January 1998.
|
||||
|
||||
ifndef VISLIBS
|
||||
VISLIBS :=
|
||||
endif
|
||||
|
||||
ifdef G4VIS_USE_DAWN
|
||||
G4VIS_USE_DAWN_OR_DAWNFILE = 1
|
||||
CPPFLAGS += -DG4VIS_USE_DAWN
|
||||
endif
|
||||
ifdef G4VIS_USE_DAWNFILE
|
||||
G4VIS_USE_DAWN_OR_DAWNFILE = 1
|
||||
CPPFLAGS += -DG4VIS_USE_DAWNFILE
|
||||
endif
|
||||
ifdef G4VIS_USE_DAWN_OR_DAWNFILE
|
||||
G4VIS_USE = 1
|
||||
CPPFLAGS += -I$(G4BASE)/visualization/FukuiRenderer/include
|
||||
VISLIBS += -lG4FR
|
||||
endif
|
||||
|
||||
ifdef G4VIS_USE_OPACS
|
||||
G4VIS_USE = 1
|
||||
INC_OPACS = 1
|
||||
LOAD_OPACS = 1
|
||||
CPPFLAGS += -DG4VIS_USE_OPACS
|
||||
CPPFLAGS += -I$(G4BASE)/visualization/OPACS/include
|
||||
VISLIBS += -lG4OPACS
|
||||
endif
|
||||
|
||||
ifdef G4VIS_USE_OPENGLX
|
||||
G4VIS_USE_OPENGL = 1
|
||||
CPPFLAGS += -DG4VIS_USE_OPENGLX
|
||||
INC_X11 = 1
|
||||
LOAD_X11 = 1
|
||||
endif
|
||||
ifdef G4VIS_USE_OPENGLXM
|
||||
G4VIS_USE_OPENGL = 1
|
||||
CPPFLAGS += -DG4VIS_USE_OPENGLXM
|
||||
INC_XM = 1
|
||||
LOAD_XM = 1
|
||||
endif
|
||||
ifdef G4VIS_USE_OPENGL
|
||||
G4VIS_USE = 1
|
||||
CPPFLAGS += -DG4VIS_USE_OPENGL
|
||||
CPPFLAGS += -I$(G4BASE)/visualization/OpenGL/include
|
||||
VISLIBS += -lG4OpenGL
|
||||
INC_GL = 1
|
||||
LOAD_GL = 1
|
||||
endif
|
||||
|
||||
ifdef G4VIS_USE_OIX
|
||||
G4VIS_USE_OI = 1
|
||||
CPPFLAGS += -DG4VIS_USE_OIX
|
||||
INC_XM = 1
|
||||
LOAD_XM = 1
|
||||
endif
|
||||
ifdef G4VIS_USE_OIWIN32
|
||||
G4VIS_USE_OI = 1
|
||||
CPPFLAGS += -DG4VIS_USE_OIWIN32
|
||||
endif
|
||||
ifdef G4VIS_USE_OI
|
||||
G4VIS_USE = 1
|
||||
CPPFLAGS += -DG4VIS_USE_OI
|
||||
CPPFLAGS += -I$(G4BASE)/visualization/OpenInventor/include
|
||||
VISLIBS += -lG4OpenInventor
|
||||
INC_IV = 1
|
||||
LOAD_IV = 1
|
||||
endif
|
||||
|
||||
ifdef G4VIS_USE_RAYX
|
||||
G4VIS_USE = 1
|
||||
CPPFLAGS += -DG4VIS_USE_RAYX
|
||||
CPPFLAGS += -I$(G4BASE)/visualization/G4Ray/include
|
||||
VISLIBS += -lG4Ray
|
||||
INC_X11 = 1
|
||||
LOAD_X11 = 1
|
||||
endif
|
||||
|
||||
ifdef G4VIS_USE_VRML
|
||||
G4VIS_USE_VRML_OR_VRMLFILE = 1
|
||||
CPPFLAGS += -DG4VIS_USE_VRML
|
||||
endif
|
||||
ifdef G4VIS_USE_VRMLFILE
|
||||
G4VIS_USE_VRML_OR_VRMLFILE = 1
|
||||
CPPFLAGS += -DG4VIS_USE_VRMLFILE
|
||||
endif
|
||||
ifdef G4VIS_USE_VRML_OR_VRMLFILE
|
||||
G4VIS_USE = 1
|
||||
CPPFLAGS += -I$(G4BASE)/visualization/VRML/include
|
||||
VISLIBS += -lG4VRML
|
||||
endif
|
||||
|
||||
ifdef G4VIS_USE
|
||||
ifdef G4_SOLVE_TEMPLATES
|
||||
G4_SOLVE_VIS_TEMPLATES = 1
|
||||
endif
|
||||
ifdef GNU_GCC
|
||||
G4_SOLVE_VIS_TEMPLATES = 1
|
||||
endif
|
||||
ifdef G4_SOLVE_VIS_TEMPLATES
|
||||
CPPFLAGS += -DG4_SOLVE_VIS_TEMPLATES
|
||||
endif
|
||||
CPPFLAGS += -DG4VIS_USE
|
||||
CPPFLAGS += -I$(G4BASE)/visualization/management/include
|
||||
CPPFLAGS += -I$(G4BASE)/visualization/modeling/include
|
||||
VISLIBS += -lG4vis_management
|
||||
VISLIBS += -lG4modeling
|
||||
endif
|
||||
|
||||
+236
@@ -0,0 +1,236 @@
|
||||
$Id: History,v 2.65 1998/12/15 19:29:12 gcosmo Exp $
|
||||
$Name: geant4-00 $
|
||||
-------------------------------------------------------------------
|
||||
|
||||
=========================================================
|
||||
Geant4 - an Object-Oriented Toolkit for Simulation in HEP
|
||||
=========================================================
|
||||
|
||||
Category History file
|
||||
---------------------
|
||||
|
||||
History file for Geant4 configuration scripts.
|
||||
It DOES NOT substitute the CVS log-message one should put at every
|
||||
committal in the CVS repository !
|
||||
|
||||
----------------------------------------------------------
|
||||
* Reverse chronological order (last date on top), please *
|
||||
----------------------------------------------------------
|
||||
|
||||
December 15th, 1998 - G.Cosmo (config-00-04-11)
|
||||
- Added G4_HAVE_BOOL to DEC-cxx.
|
||||
- Cosmetic changes.
|
||||
|
||||
December 12th, 1998 - J.Allison (config-00-04-10)
|
||||
- Fixed bug in OGLFLAGS and OGLLIBS user override mechanism.
|
||||
|
||||
December 11th, 1998 - J.Allison (config-00-04-09)
|
||||
- Removed -fnonstd for SUN-CC.
|
||||
|
||||
December 10th, 1998 - G.Cosmo (config-00-04-08)
|
||||
- architecture.gmk: introduced $G4DATA variable which can be user
|
||||
defined. Default is set to $G4INSTALL/data.
|
||||
- architecture.gmk: introduced $G4LEVELGAMMADATA set as default to
|
||||
$G4DATA/PhotonEvaporation.
|
||||
- globlib.gmk: fixed minor bug (courtesy of V.Krylov).
|
||||
|
||||
December 10th, 1998 - J.Allison (config-00-04-07)
|
||||
- architecture.gmk: allowed environment variables OGLFLAGS and OGLLIBS.
|
||||
|
||||
December 7th, 1998 - S.Tanaka, G.Cosmo (config-00-04-06)
|
||||
- architecture.gmk: fixed setting of VISLIBS.
|
||||
|
||||
December 7th, 1998 - S.Tanaka
|
||||
- Update of architecture.gmk and G4VIS_USE.gmk:
|
||||
In SUN-CC, "-L/usr/lib -lsocket -lnsl" is moved from X11LIBS to VISLIBS.
|
||||
|
||||
December 5th, 1998 - G.Cosmo (config-00-04-05)
|
||||
- architecture.gmk: introduced -fnonstd compiler option for SUN-CC.
|
||||
This option causes non-standard initialization of floating-point
|
||||
arithmetic hardware; it enables hardware traps for floating-point
|
||||
overflow, division by zero, and invalid operation exceptions.
|
||||
|
||||
December 4th, 1998 - G.Barrand
|
||||
- architecture.gmk: corrected paths for HepVis and HepInventor.
|
||||
- interactivity.gmk: fixed setup for LOAD_IV.
|
||||
|
||||
December 3rd, 1998 - S.Tanaka
|
||||
- Revision to make compilation of DAWN (network) driver
|
||||
at Solaris and IRIX automatic. See below.
|
||||
- Added the following line to SUN-CC and SGI-CC
|
||||
CPPFLAGS += -DSOCKET_IRIX_SOLARIS
|
||||
- Added -L/usr/lib -lsocket -lnsl in X11LIBS for SUN-CC.
|
||||
(This place is strange. But I cannot think of a better place.)
|
||||
|
||||
December 3rd, 1998 - J.Allison (config-00-04-04)
|
||||
- Set G4STREAM for all platforms.
|
||||
- Set G4STREAM_STREAMBUF_IMPLEMENTATION for selected platforms.
|
||||
|
||||
December 3rd, 1998 - S.Sadilov
|
||||
- Updated architecture.gmk : G4STREAM_STREAMBUF_IMPLEMENTATION for WIN32.
|
||||
- Updated globlib.gmk : right incremental LIB for WIN32.
|
||||
|
||||
December 1st, 1998 - G.Cosmo (config-00-04-03)
|
||||
- Updated architecture.gmk and binmake.gmk: G4SYSTEM revision.
|
||||
- Added +DAportable compiler option to HP-aCC setup to support HPPA 2.0
|
||||
for PA8000 CPUs.
|
||||
|
||||
December 1st, 1998 - J.Allison (config-00-04-02)
|
||||
- Added generators/include to binmake.gmk.
|
||||
|
||||
November 30th, 1998 - J.Allison (config-00-04-01)
|
||||
- Added neutron_hp/include to binmake.gmk.
|
||||
- CLHEP_BASE_DIR and RWBASE for WIN32 (Serguei Sadilov).
|
||||
|
||||
November 18th, 1998 - J.Allison (config-00-03-06)
|
||||
- Changed CXXFLAGS for DEC6-AFS debug from -g to -gall.
|
||||
|
||||
October 30th, 1998 - G.Cosmo (config-00-03-05)
|
||||
- architecture.gmk: added G4STREAM_STREAMBUF_IMPLEMENTATION variable. (G.Barrand)
|
||||
- G4UI_BUILD.gmk: removed G4UI_BUILD_XM_REDIRECT_COUT. (G.Barrand)
|
||||
|
||||
October 13th, 1998 J.Allison (config-00-03-04)
|
||||
- Changed ifdef G4_USE_G4STREAM to ifneq ($(findstring AIX,$(G4SYSTEM)),AIX)
|
||||
|
||||
October 13th, 1998 J.Allison (config-00-03-03)
|
||||
- Removed G4VIS_DONT_USE. (G.Barrand)
|
||||
- Added if G4_USE_G4STREAM, CPPFLAGS += -DG4STREAM. (M.Nagamatu)
|
||||
|
||||
October 9th J.Allison (config-00-03-02)
|
||||
- Tagged.
|
||||
|
||||
October 2nd, 1998 - M.Asai
|
||||
- G4_NO_STORE_TRAJECTORY option is added to architecture.gmk.
|
||||
|
||||
September 30th, 1998 - G.Barrand
|
||||
- G4VIS_USE.gmk: bracket everything with "ifndef G4VIS_DONT_USE" in order
|
||||
to be able to disconnect easily visualization for tests programs.
|
||||
|
||||
September 18th, 1998 - G.Cosmo (config-00-03-01)
|
||||
- architecture.gmk: introduced G4DUMMY_VARIABLE to hide $(shell)
|
||||
command not compatible with the new version 3.77 of GMAKE (G.Folger).
|
||||
|
||||
September 14th, 1998 - G.Cosmo
|
||||
- binmake.gmk: placed digits+hits library in the correct link order
|
||||
according to the category diagram.
|
||||
|
||||
August 31st, 1998 - G.Cosmo (config-00-02-05)
|
||||
- architecture.gmk: Changed first CPPFLAGS statement from := to +=,
|
||||
to allow additional CPPFLAGS to be defined by the user. Needed for test
|
||||
(F.Behner)
|
||||
- binmake.gmk: Added EXTRALIBS to allow a user to add own libraries in the
|
||||
link path. Needed for test.
|
||||
(F.Behner)
|
||||
- binmake.gmk: inverted link order of processes and particles libraries
|
||||
which was wrong. (G.Cosmo)
|
||||
|
||||
August 26th, 1998 - John Allison (config-00-02-04)
|
||||
- Backed out 22nd August change (G4UIGAG as default) - G4UIterminal
|
||||
is now default.
|
||||
|
||||
August 24th, 1998 - Y.Morita (config-00-02-03)
|
||||
- globlib.gmk: added $(G4LIBDIR)/lib$(name).a for target "global".
|
||||
|
||||
August 22nd, 1998 - J.Allison (config-00-02-02)
|
||||
- Set GAG variables by default.
|
||||
|
||||
August 11th, 1998 - G.Cosmo (config-00-02-01)
|
||||
- Tagged.
|
||||
|
||||
August 7th, 1998 - John Allison/Michel Maire.
|
||||
- Added -I/usr/include before -I/usr/local/include to OGLFLAGS for DEC-AFS.
|
||||
- Changed -lGl to -lMesaGL, etc., for DEC-AFS.
|
||||
|
||||
August 6th, 1998 - John Allison
|
||||
- Added UILIBS := to G4UI_USE.gmk and VISLIBS := to G4VIS_USE.gmk.
|
||||
|
||||
August 5th, 1998 - Guy Barrand
|
||||
- Added LOAD_XM = 1 and LOAD_XAW = 1 to G4UI_USE.gmk.
|
||||
|
||||
July 30th, 1998 - G.Cosmo (config-b01)
|
||||
- globlib.gmk: added phony target "wipe_libs". Now target "global"
|
||||
effectively deletes all existent granular libraries.
|
||||
- common.gmk: archiving of libraries is silent now by default.
|
||||
|
||||
July 23th, 1998 - Y.Morita (config-00-01-16)
|
||||
- globlib.gmk: fixed target "global" for G4ODBMS
|
||||
- binmake.gmk: fixes for Win/NT.
|
||||
|
||||
July 20th, 1998 - John Allison (config-00-01-15)
|
||||
- Removed LDFLAGS += -Wl,-Bstatic for G++-Linux introduced by Larry
|
||||
Felawka on July 10th for g++ 2.8. No longer thought to be necessary.
|
||||
|
||||
July 19th, 1998 - G.Cosmo (config-00-01-14)
|
||||
- common.gmk: introduced CPPVERBOSE flag.
|
||||
- architecture.gmk: protected creation of $G4SCHEMA_DIR and
|
||||
$G4EXAMPLE_BOOT_DIR directories with G4ODBMS.
|
||||
- binmake.gmk: fixed bug in creation of $G4TARGET.
|
||||
|
||||
July 18th, 1998 - G.Cosmo (config-00-01-13)
|
||||
- Added fix to binmake.gmk for WIN32-VC-NICE (G.Folger)
|
||||
|
||||
July 16th, 1998 - John Allison
|
||||
- Added GNU_GCC makefile flags where omitted.
|
||||
|
||||
July 15th, 1998 - Youhei Morita (config-00-01-12)
|
||||
- architecture.gmk added G4EXAMPLE_BOOT_DIR and G4EXAMPLE_BOOT
|
||||
- globlib.gmk revised cleandb target
|
||||
|
||||
July 14th, 1998 - Peter Urban (config-00-01-11)
|
||||
- added two Perl scripts that correct STEP exchange files.
|
||||
|
||||
July 14th, 1998 - Youhei Morita (config-00-01-10)
|
||||
- architecture.gmk added definition of G4SCHEMA_DIR
|
||||
- globlib.gmk added new target G4SCHEMA.FDDB for G4ODBMS
|
||||
|
||||
July 10th, 1998 - Youhei Morita (config-00-01-09)
|
||||
- binmake.gmk added following to INCFLAGS
|
||||
-I$(G4BASE)/persistency/digits+hits/hits/include \
|
||||
-I$(G4TMP)/$(G4SYSTEM)/G4phits \
|
||||
- binmake.gmk moved persistency include path to ifdef G4ODBMS block
|
||||
|
||||
July 10th, 1998 - John Allison??
|
||||
- binmake.gmk added geometry/solids/STEPinterface/include
|
||||
|
||||
July 10th, 1998 - Youehi Morita (config-00-01-08)
|
||||
- globlib.gmk added new targets 'headers' and 'd_files' for G4ODBMS
|
||||
- common.gmk added new target 'headers'
|
||||
added $(schema_hh) dependency to $(G4TMPDIR)/%.o
|
||||
- binmake.gmk added INCFLAGS, LDLIBS and LDFLAGS for G4ODBMS
|
||||
|
||||
July 10th, 1998 - L.Felawka
|
||||
- architecture.gmk: updated compilation flags for g++.
|
||||
|
||||
July 9th, 1998 - G.Cosmo (config-00-01-07)
|
||||
- Removed bug in "all" target in globlib.gmk, introduced recently.
|
||||
- Modified "all" target in globlib.gmk to handle G4ODBMS.
|
||||
- Added fix for G4ODBMS to common.gmk.
|
||||
|
||||
July 9th, 1998 - Youehi Morita
|
||||
- Added G4ODBMS_BUILD.gmk for HepODBMS and Objectivity/DB CPPFLAGS.
|
||||
|
||||
July 7th, 1998 - John Allison (config-00-01-06)
|
||||
- Incorporated Makoto's patches for ifndef G4UI_BUILD_TERMINAL_SESSION and
|
||||
ifndef G4UI_USE_TERMINAL.
|
||||
|
||||
July 7th, 1998 - G.Cosmo (config-00-01-05)
|
||||
- Added $(schema_hh) target and dependency to it in case of G4ODBMS
|
||||
set when building .d files.
|
||||
|
||||
July 7th, 1998 - John Allison (config-00-01-04)
|
||||
- Tagged.
|
||||
|
||||
July 7th, 1998 - Guy Barrand
|
||||
- Introduced interactivity.gmk.
|
||||
|
||||
July 6th, 1998 - J.Allison (config-00-01-03)
|
||||
- Added G4UI_BUILD.gmk and G4UI_BUILD.gmk.
|
||||
|
||||
July 6th, 1998 - G.Cosmo (config-00-01-02)
|
||||
- Introduced "glob" and "objs" targets in globlib.gmk. Modified
|
||||
rule to build global library, does not depend anymore on "libs".
|
||||
(by J.Allison)
|
||||
- Moved G4VIS_USE.gmk and G4VIS_BUILD.gmk from source/visualization.
|
||||
|
||||
July 3rd, 1998 - G.Cosmo (config-00-01-01)
|
||||
- Created
|
||||
@@ -0,0 +1,632 @@
|
||||
# $Id: architecture.gmk,v 2.40 1998/12/15 19:29:13 gcosmo Exp $
|
||||
# ------------------------------------------------------------------------
|
||||
# GEANT 4 - Architecture configuration script for GNU Make
|
||||
#
|
||||
# First implementation: July 7th 1995
|
||||
#
|
||||
# Description
|
||||
# -----------
|
||||
# to override variables defined in this script, use "gmake -e", this will
|
||||
# cause environment variables to take precedence. In this case watch for
|
||||
# inadvertant overrides!
|
||||
#
|
||||
# List of the supported architectures/compilers and related flavors for
|
||||
# the environment variable G4SYSTEM:
|
||||
#
|
||||
# AIX-xlC AIX 4.3, (xlC) C Set ++ for AIX (default)
|
||||
#
|
||||
# SUN-CC SunOS 5.6, CC 4.2 compiler
|
||||
#
|
||||
# HP-aCC HP-UX 10.20, aCC A.01.09 compiler
|
||||
#
|
||||
# SGI-CC SGI-IRIX 6.2, C++ 7.2 compiler
|
||||
#
|
||||
# DEC-cxx DEC-OSF/1 4.0, DEC C++ 6.1
|
||||
#
|
||||
# Linux-g++ Linux (Red Hat 5.1), egcs 1.1
|
||||
#
|
||||
# WIN32-VC-NICE NiceNT and Microsoft Visual C++ 5.0 installed
|
||||
# locally as CD-ROM intallation
|
||||
# ex. NiceNT at CERN (but CYGWIN32 installed
|
||||
# locally, because not full installation on NICE)
|
||||
#
|
||||
# WIN32-G++-NICE NiceNT and CYGWIN32 with g++ as base compiler
|
||||
# ex. NiceNT at CERN (but CYGWIN32 and RogueWave
|
||||
# for g++ installed locally, because not full
|
||||
# installation on NICE)
|
||||
#
|
||||
|
||||
MAKEFLAGS= --no-print-directory
|
||||
|
||||
# If not specified, the default platform for G4SYSTEM is IBM-AIX ...
|
||||
#
|
||||
ifndef G4SYSTEM
|
||||
G4SYSTEM := AIX-xlC
|
||||
endif
|
||||
|
||||
# If not specified, the default path for G4 installation G4INSTALL is
|
||||
# set to $HOME/geant4beta ...
|
||||
#
|
||||
ifndef G4INSTALL
|
||||
G4INSTALL := $(HOME)/geant4beta
|
||||
endif
|
||||
|
||||
# If not specified, the default path for G4 source G4BASE is
|
||||
# set to $G4INSTALL/source ...
|
||||
#
|
||||
ifndef G4BASE
|
||||
G4BASE := $(G4INSTALL)/source
|
||||
endif
|
||||
|
||||
# If not specified, the default path for the user's workdir is the same
|
||||
# as G4INSTALL ...
|
||||
#
|
||||
ifndef G4WORKDIR
|
||||
G4WORKDIR := $(G4INSTALL)
|
||||
endif
|
||||
|
||||
# If not specified, the default path for temporary files G4TMP is
|
||||
# set to $G4WORKDIR/tmp/$G4SYSTEM ...
|
||||
#
|
||||
ifndef G4TMP
|
||||
G4TMP := $(G4WORKDIR)/tmp
|
||||
endif
|
||||
G4DUMMY_VARIABLE:=$(shell [ ! -d $(G4TMP) ] && mkdir -p $(G4TMP) )
|
||||
|
||||
# If not specified, the default path for G4 libraries G4LIB is
|
||||
# set to $G4INSTALL/lib/$G4SYSTEM ...
|
||||
#
|
||||
ifndef G4LIB
|
||||
G4LIB := $(G4INSTALL)/lib
|
||||
endif
|
||||
G4DUMMY_VARIABLE:=$(shell [ ! -d $(G4LIB) ] && mkdir -p $(G4LIB) )
|
||||
|
||||
# If not specified, the default path for G4 binaries G4BIN is
|
||||
# set to $G4WORKDIR/bin/$G4SYSTEM ...
|
||||
#
|
||||
ifndef G4BIN
|
||||
G4BIN := $(G4WORKDIR)/bin
|
||||
endif
|
||||
G4DUMMY_VARIABLE:=$(shell [ ! -d $(G4BIN) ] && mkdir -p $(G4BIN) )
|
||||
|
||||
# If not specified, the default path for G4 schema G4SCHEMA_DIR is
|
||||
# set to $G4WORKDIR/schema ...
|
||||
#
|
||||
ifndef G4SCHEMA_DIR
|
||||
G4SCHEMA_DIR := $(G4WORKDIR)/schema
|
||||
G4SCHEMA_FDID := 207
|
||||
endif
|
||||
ifdef G4ODBMS
|
||||
G4DUMMY_VARIABLE:=$(shell [ ! -d $(G4SCHEMA_DIR) ] && mkdir -p $(G4SCHEMA_DIR) )
|
||||
endif
|
||||
|
||||
# If not specified, the default path for G4 example federated database is
|
||||
# set to $HOME/G4EXAMPLE ...
|
||||
#
|
||||
ifndef G4EXAMPLE_BOOT_DIR
|
||||
G4EXAMPLE_BOOT_DIR := $(HOME)/G4EXAMPLE
|
||||
G4EXAMPLE_BOOT := $(G4EXAMPLE_BOOT_DIR)/G4EXAMPLE
|
||||
endif
|
||||
ifdef G4ODBMS
|
||||
G4DUMMY_VARIABLE:=$(shell [ ! -d $(G4EXAMPLE_BOOT_DIR) ] && mkdir -p $(G4EXAMPLE_BOOT_DIR) )
|
||||
endif
|
||||
|
||||
# If G4DEBUG not specified, the default compilation is optimised ...
|
||||
#
|
||||
ifndef G4DEBUG
|
||||
G4OPTIMISE := 1
|
||||
endif
|
||||
|
||||
#
|
||||
# CLHEP path
|
||||
#
|
||||
|
||||
ifndef CLHEP_BASE_DIR
|
||||
CLHEP_BASE_DIR := /afs/cern.ch/rd44/dev/CLHEP/$(G4SYSTEM)/pro
|
||||
endif
|
||||
CLHEP_INCLUDE_DIR := $(CLHEP_BASE_DIR)/include
|
||||
CLHEP_LIB_DIR := $(CLHEP_BASE_DIR)/lib
|
||||
ifndef CLHEP_LIB
|
||||
CLHEP_LIB := CLHEP
|
||||
endif
|
||||
|
||||
ifeq ($(G4SYSTEM),WIN32-VC-NICE)
|
||||
#
|
||||
# NiceNT policy for letter drive mapping
|
||||
#
|
||||
ifndef CLHEP_BASE_DIR
|
||||
CLHEP_BASE_DIR := "z:\p32\lhcpp\clhep\1.1"
|
||||
endif
|
||||
CLHEP_INCLUDE_DIR := $(CLHEP_BASE_DIR)/include
|
||||
CLHEP_LIB_DIR := $(CLHEP_BASE_DIR)/lib
|
||||
CLHEP_LIB := libCLHEP-cl.a
|
||||
endif
|
||||
|
||||
#
|
||||
# Rogue Wave Tools.h++ path
|
||||
#
|
||||
|
||||
ifndef RWBASE
|
||||
RWBASE := /afs/cern.ch/rd44/dev/rogue/$(G4SYSTEM)
|
||||
endif
|
||||
RWINC := $(RWBASE)
|
||||
RWLIBDIR := $(RWBASE)/lib
|
||||
RWLIB := rwtool
|
||||
|
||||
ifeq ($(G4SYSTEM),HP-aCC)
|
||||
RWBASE := /opt/aCC
|
||||
RWINC := $(RWBASE)/include
|
||||
RWLIBDIR := /usr/lib
|
||||
endif
|
||||
|
||||
#
|
||||
# Paths for G4 data
|
||||
#
|
||||
|
||||
ifndef G4DATA
|
||||
G4DATA := $(G4INSTALL)/data
|
||||
endif
|
||||
|
||||
# Photon evaporation data
|
||||
ifndef G4LEVELGAMMADATA
|
||||
G4LEVELGAMMADATA := $(G4DATA)/PhotonEvaporation
|
||||
endif
|
||||
|
||||
ifeq ($(G4SYSTEM),WIN32-VC-NICE)
|
||||
#
|
||||
# NiceNT policy for letter drive mapping
|
||||
#
|
||||
ifndef RWBASE
|
||||
RWBASE := "z:\p32\lhcpp\rw\tools\7.0.2\rogue"
|
||||
endif
|
||||
RWINC := $(RWBASE)
|
||||
RWLIBDIR := $(RWBASE)"\lib"
|
||||
RWLIB := mtldmt.lib
|
||||
RWINCGPP := /rogue
|
||||
endif
|
||||
|
||||
ifeq ($(G4SYSTEM),WIN32-G++-NICE)
|
||||
#
|
||||
# locally installed RogueWave for g++ (mount mapping)
|
||||
#
|
||||
RWBASE := /rogue
|
||||
RWINC := $(RWBASE)
|
||||
RWLIBDIR := $(RWBASE)/lib
|
||||
RWLIB := rwtool
|
||||
endif
|
||||
|
||||
#
|
||||
# Toggle variables (positional qualifiers) between WIN32-VC and UNIX...
|
||||
#
|
||||
ifeq ($(G4SYSTEM),WIN32-VC-NICE)
|
||||
OUT_OBJ := -TP '-Fo'
|
||||
FOR_OBJ := '-Fo'
|
||||
OUT_LIB := '-out:'
|
||||
OUT_EXE := '-Fe'
|
||||
LIB_PATH := '-libpath:'
|
||||
CERNLIB_PATH := "z:\p32\cern\new\df\lib"
|
||||
PATH_DEL := \\
|
||||
#
|
||||
# pattern for next substitution
|
||||
#
|
||||
LIB_PATT := lib(LibName).a
|
||||
FLIB_PATT := (LibName).lib
|
||||
else
|
||||
OUT_OBJ := -o
|
||||
FOR_OBJ := -o
|
||||
OUT_LIB :=
|
||||
OUT_EXE := -o
|
||||
LIB_PATH := -L
|
||||
CERNLIB_PATH := /cern/pro/lib
|
||||
PATH_DEL := /
|
||||
#
|
||||
# pattern for next substitution
|
||||
#
|
||||
LIB_PATT := -l(LibName)
|
||||
FLIB_PATT := $(LIB_PATT)
|
||||
endif
|
||||
|
||||
#
|
||||
# Make dependencies files by g++ then need right RW include
|
||||
#
|
||||
ifdef RWINCGPP
|
||||
RWINCGPP := -I$(RWINCGPP)
|
||||
endif
|
||||
|
||||
#
|
||||
# Variables for implicit rules, etc., as suggested in GNU Make manual...
|
||||
#
|
||||
|
||||
CPPFLAGS += -Iinclude \
|
||||
-I$(CLHEP_INCLUDE_DIR) \
|
||||
-I$(RWINC)
|
||||
#
|
||||
# Positional qualifiers in action...
|
||||
#
|
||||
ifeq ($(G4SYSTEM),WIN32-VC-NICE)
|
||||
LDFLAGS := -link $(LIB_PATH)$(CLHEP_LIB_DIR) $(LIB_PATH)$(RWLIBDIR)
|
||||
LOADLIBS := $(CLHEP_LIB) $(RWLIB)
|
||||
else
|
||||
LDFLAGS := -L$(CLHEP_LIB_DIR) -L$(RWLIBDIR)
|
||||
LOADLIBS := -l$(CLHEP_LIB) -l$(RWLIB) -lm
|
||||
endif
|
||||
|
||||
#
|
||||
# Graphic variables...
|
||||
#
|
||||
ifndef VISLIBS
|
||||
VISLIBS :=
|
||||
endif
|
||||
# ------------------ X11 ---------------------
|
||||
X11FLAGS :=
|
||||
X11LIBS := -lXmu -lXt -lXext -lX11
|
||||
# ----------------- Motif --------------------
|
||||
XMFLAGS :=
|
||||
XMLIBS := -lXm
|
||||
# ---------------- Athena --------------------
|
||||
XAWFLAGS :=
|
||||
XAWLIBS := -lXaw
|
||||
# ---------------- OpenGL --------------------
|
||||
# The user can define his own values of OGLFLAGS and OGLLIBS.
|
||||
# OGLFLAGS gives the directory containing include files.
|
||||
# E.g.: OGLFLAGS := -I$(OGLHOME)/include
|
||||
# OGLLIBS gives the libraries.
|
||||
# E.g.: OGLLIBS := -L$(OGLHOME)/lib -lGLU -lGL
|
||||
# Or : OGLLIBS := -L$(OGLHOME)/lib -lMesaGLU -lMesaGL
|
||||
# OGLHOME is often /usr or /usr/local. Or it can point to a special
|
||||
# installation.
|
||||
# If the user does not set his/her own values, system-dependent values
|
||||
# are set below. Most system-dependent code assumes OGLHOME is set.
|
||||
# ------------- OpenInventor -----------------
|
||||
ifndef HEPVISINC
|
||||
HEPVISINC := $(HEPVISDIR)/include
|
||||
endif
|
||||
ifndef HEPVISLIB
|
||||
HEPVISLIB := $(HEPVISDIR)/source
|
||||
endif
|
||||
ifndef OIVFLAGS
|
||||
OIVFLAGS := -I${HEPVISINC}
|
||||
endif
|
||||
ifndef OIVLIBS
|
||||
OIVLIBS := -L${HEPVISLIB} -lHEPVis -lInventorXt -lInventor -lGLU -lGL
|
||||
endif
|
||||
# ----------------- OPACS --------------------
|
||||
ifndef G4_OPACS_WIDGET_SET
|
||||
G4_OPACS_WIDGET_SET := Xm
|
||||
endif
|
||||
|
||||
#
|
||||
# For cfront compilers the repository location is set to
|
||||
# $G4TMP/$G4SYSTEM/g4.ptrepository.
|
||||
#
|
||||
|
||||
G4TEMPLATE_REPOSITORY := $(G4SYSTEM)/g4.ptrepository
|
||||
G4TEMPEXEC_REPOSITORY := $(G4TEMPLATE_REPOSITORY)/exec
|
||||
G4TREP := $(G4TMP)/$(G4TEMPLATE_REPOSITORY)
|
||||
|
||||
# Default archive call. Changed for: SUN-CC.
|
||||
AR := ar r
|
||||
|
||||
# Default echo used with makedepend. Changed for SUN-CC, Linux-g++.
|
||||
ECHO:= echo
|
||||
|
||||
|
||||
#
|
||||
# Architecture dependent variables...
|
||||
#
|
||||
|
||||
# -------- AIX ----------
|
||||
#
|
||||
ifeq ($(G4SYSTEM),AIX-xlC)
|
||||
CXX := xlC
|
||||
ifdef G4OPTIMISE
|
||||
CXXFLAGS := -O3 -qtwolink -+
|
||||
else
|
||||
CXXFLAGS := -g -qdbxextra -qcheck=all -qfullpath -qtwolink -+
|
||||
FCFLAGS := -g
|
||||
endif
|
||||
FC := xlf
|
||||
FCFLAGS += -qextname
|
||||
FCLIBS := -lxlf90 -lxlf
|
||||
X11FLAGS := -I/usr/include/X11/extensions -I/usr/include/X11
|
||||
X11LIBS := -L/usr/lib -lXmu -lX11 -lXext
|
||||
XMFLAGS := -I/usr/include/Motif1.2
|
||||
XMLIBS := -L/usr/lib -lXm -lXt -lX11
|
||||
XAWFLAGS := -I/usr/include/X11
|
||||
XAWLIBS := -L/usr/lib -lXaw -lXmu -lXt -lX11 -lXext
|
||||
ifndef OGLFLAGS
|
||||
OGLFLAGS := -I$(OGLHOME)/include
|
||||
endif
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := -L$(OGLHOME)/lib -lGLU -lGL
|
||||
endif
|
||||
endif
|
||||
|
||||
# -------- SUN ---------
|
||||
#
|
||||
ifeq ($(G4SYSTEM),SUN-CC)
|
||||
CXX := CC
|
||||
ifdef G4OPTIMISE
|
||||
CXXFLAGS := -O
|
||||
else
|
||||
CXXFLAGS := -g
|
||||
FCFLAGS := -g
|
||||
endif
|
||||
# CXXFLAGS += -fnonstd
|
||||
CFRONT_G4TEMPLATE_REPOSITORY := true
|
||||
FC := f77
|
||||
SHEXT := so
|
||||
AR := $(CXX) -xar -ptr$(G4TREP) -o
|
||||
ECHO := /bin/echo
|
||||
X11FLAGS := -I/usr/openwin/include/X11/extensions -I/usr/openwin/include/X11 -I/usr/openwin/include
|
||||
X11LIBS := -L/usr/openwin/lib -L/usr/dt/lib -L/usr/ucblib -R/usr/openwin/lib -lXmu -lX11 -lXext
|
||||
|
||||
XMFLAGS := -I/usr/include/Motif1.2
|
||||
XMLIBS := -L/usr/openwin/lib -L/usr/dt/lib -L/usr/ucblib -R/usr/openwin/lib -lXt -lX11
|
||||
XAWFLAGS := -I/usr/openwin/include/X11
|
||||
XAWLIBS := -L/usr/openwin/lib -L/usr/dt/lib -L/usr/ucblib -R/usr/openwin/lib -lXaw -lXmu -lXt -lX11 -lXext
|
||||
ifndef OGLFLAGS
|
||||
OGLFLAGS := -I$(OGLHOME)/include
|
||||
endif
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := -L$(OGLHOME)/lib -lGLU -lGL
|
||||
endif
|
||||
CPPFLAGS += -DSOCKET_IRIX_SOLARIS
|
||||
VISLIBS += -L/usr/lib -lsocket -lnsl
|
||||
endif
|
||||
|
||||
# -------- HP ---------
|
||||
#
|
||||
ifeq ($(G4SYSTEM),HP-aCC)
|
||||
CXX := aCC
|
||||
ifdef G4OPTIMISE
|
||||
CXXFLAGS := +O2
|
||||
else
|
||||
CXXFLAGS := -g
|
||||
FCFLAGS := -g
|
||||
endif
|
||||
CXXFLAGS += +DAportable
|
||||
CPPFLAGS += -I/usr
|
||||
ifdef G4MAKESHLIB
|
||||
CXXFLAGS += +Z
|
||||
endif
|
||||
G4_HAVE_BOOL := yes
|
||||
FC := f77
|
||||
FCFLAGS += +E6 +ppu
|
||||
X11FLAGS := -I/usr/include/X11/extensions -I/usr/contrib/X11R6/include -I/usr/contrib/X11R6/include/X11
|
||||
X11LIBS := -L/usr/contrib/X11R6/lib -lXmu -L/usr/lib -lXt -lXext -lX11
|
||||
XMFLAGS := -I/usr/include/Motif1.2
|
||||
XMLIBS := -L/usr/lib/Motif1.2_R6 -lXm
|
||||
XAWFLAGS := -I/usr/contrib/X11R6/include -I/usr/contrib/X11R6/include/X11
|
||||
XAWLIBS := -L/usr/contrib/X11R6/lib -lXaw
|
||||
ifndef OGLFLAGS
|
||||
OGLFLAGS := -I$(OGLHOME)/include
|
||||
endif
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := -L$(OGLHOME)/lib -lGLU -lGL
|
||||
OGLLIBS += -L/opt/graphics/common/lib -lXwindow -lhpgfx -lXhp11 -ldld
|
||||
endif
|
||||
endif
|
||||
|
||||
# -------- SGI ---------
|
||||
#
|
||||
ifeq ($(G4SYSTEM),SGI-CC)
|
||||
CXX := CC
|
||||
ifdef G4OPTIMISE
|
||||
CXXFLAGS := -O -ptused
|
||||
else
|
||||
CXXFLAGS := -g -ptused
|
||||
FCFLAGS := -g
|
||||
endif
|
||||
FC := f77
|
||||
FCLIBS := -lftn
|
||||
SHEXT := so
|
||||
X11FLAGS := -I/usr/include/X11/extensions -I/usr/include/X11
|
||||
X11LIBS := -L/usr/lib -lXmu -lXt -lXext -lX11
|
||||
XMLIBS := -L/usr/lib -lXm
|
||||
ifndef OGLFLAGS
|
||||
OGLFLAGS :=
|
||||
endif
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := -L/usr/lib -lGLU -lGL
|
||||
endif
|
||||
CPPFLAGS += -DSOCKET_IRIX_SOLARIS
|
||||
endif
|
||||
|
||||
# -------- DEC ---------
|
||||
#
|
||||
ifeq ($(G4SYSTEM),DEC-cxx)
|
||||
CXX := cxx
|
||||
ifdef G4OPTIMISE
|
||||
CXXFLAGS := -O
|
||||
else
|
||||
CXXFLAGS := -gall
|
||||
FCFLAGS := -g
|
||||
endif
|
||||
CFRONT_G4TEMPLATE_REPOSITORY := true
|
||||
G4_HAVE_BOOL := yes
|
||||
LDFLAGS += -taso
|
||||
CXXFLAGS += -ieee
|
||||
FC := f77
|
||||
FCLIBS := -lUfor -lfor -lFutil -lots
|
||||
X11FLAGS := -I/usr/include/X11/extensions -I/usr/include/X11
|
||||
ifndef OGLFLAGS
|
||||
OGLFLAGS := -I$(OGLHOME)/include
|
||||
# OGLFLAGS := -I/usr/include -I/usr/local/include
|
||||
endif
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := -L$(OGLHOME)/lib -lGLU -lGL
|
||||
# OGLLIBS := -lMesaGLU -lMesaGL
|
||||
endif
|
||||
endif
|
||||
|
||||
# ------ GNU/LINUX ------
|
||||
#
|
||||
ifeq ($(G4SYSTEM),Linux-g++)
|
||||
CXX := g++
|
||||
GNU_GCC = 1
|
||||
CXXFLAGS := -pipe -fno-for-scope -DGNU_GCC
|
||||
ifdef G4OPTIMISE
|
||||
CXXFLAGS += -O
|
||||
else
|
||||
CXXFLAGS += -g
|
||||
FCFLAGS := -g
|
||||
endif
|
||||
FC := g77
|
||||
FCFLAGS += -fno-automatic -fno-backslash -fno-second-underscore
|
||||
FCLIBS := -lf2c
|
||||
ECHO := /bin/echo
|
||||
X11FLAGS := -I/usr/include/X11/extensions -I/usr/include/X11
|
||||
X11LIBS := -L/usr/X11/lib -lXmu -lXt -lXext -lX11 -lSM -lICE
|
||||
XMFLAGS := -I/usr/X11R6/include
|
||||
XMLIBS := -lXm -lXpm
|
||||
ifndef OGLFLAGS
|
||||
OGLFLAGS := -I$(OGLHOME)/include
|
||||
endif
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := -L$(OGLHOME)/lib -lGLU -lGL
|
||||
endif
|
||||
OIVFLAGS += -I$(OIHOME)/include
|
||||
endif
|
||||
|
||||
# ------ WIN32/VC/NICE ------
|
||||
#
|
||||
ifeq ($(G4SYSTEM),WIN32-VC-NICE)
|
||||
CXX := CL
|
||||
G4_HAVE_BOOL := yes
|
||||
G4_NO_CBRT := yes
|
||||
ifdef G4OPTIMISE
|
||||
CXXFLAGS += -Ox
|
||||
else
|
||||
CXXFLAGS += -Od
|
||||
endif
|
||||
CXXFLAGS += -GX -Zm200 -DWIN32 # -TP
|
||||
#
|
||||
# Should set $INCLUDE environment, if not set as below
|
||||
#
|
||||
# CXXFLAGS += -I'\\srv1_info\v2\vc50pro1\DEVSTUDIO\VC\INCLUDE'
|
||||
|
||||
LDFLAGS += -FORCE
|
||||
|
||||
#
|
||||
# Should set $LIB environment, if not set as below
|
||||
#
|
||||
# $(LIB_PATH)"c:\ProgramFiles\DevStudio\vc\lib" \
|
||||
# $(LIB_PATH)'\\srv1_info\v2\vc50pro1\DEVSTUDIO\VC\LIB' \
|
||||
# $(LIB_PATH)'\\srv1_info\v2\DecFtn5\x86\df\lib'
|
||||
|
||||
AR := LIB
|
||||
ECHO := echo -e
|
||||
FC := f77
|
||||
# FCLIBS := -lf2c
|
||||
ifndef OGLFLAGS
|
||||
OGLFLAGS :=
|
||||
endif
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := -lGLU -lGL
|
||||
endif
|
||||
endif
|
||||
|
||||
# ------ WIN32/G++/NICE ------
|
||||
#
|
||||
ifeq ($(G4SYSTEM),WIN32-G++-NICE)
|
||||
CXX := g++
|
||||
CXXFLAGS := -fno-for-scope
|
||||
G4_HAVE_BOOL := yes
|
||||
ifdef G4OPTIMISE
|
||||
CXXFLAGS += -O
|
||||
else
|
||||
CXXFLAGS += -g
|
||||
endif
|
||||
CXXFLAGS += -DCYGWIN32
|
||||
ECHO := echo -e
|
||||
FC := g77
|
||||
FCLIBS := -lf2c
|
||||
ifndef OGLFLAGS
|
||||
OGLFLAGS :=
|
||||
endif
|
||||
ifndef OGLLIBS
|
||||
OGLLIBS := -lGLU -lGL
|
||||
endif
|
||||
endif
|
||||
|
||||
# If compiler recognises implicit C++ type bool...
|
||||
ifdef G4_HAVE_BOOL
|
||||
CPPFLAGS += -DG4_HAVE_BOOL
|
||||
endif
|
||||
|
||||
# If there is no cbrt() function...
|
||||
ifdef G4_NO_CBRT
|
||||
CPPFLAGS += -DG4_NO_CBRT
|
||||
endif
|
||||
|
||||
# Standard Template Library (STL) not installed
|
||||
CPPFLAGS += -DRW_NO_STL
|
||||
|
||||
# Verbosity code can be left out (for better performance)
|
||||
# by defining G4_NO_VERBOSE.
|
||||
|
||||
ifndef G4_NO_VERBOSE
|
||||
CPPFLAGS += -DG4VERBOSE
|
||||
endif
|
||||
|
||||
# Trajectory related classes can be left out (for better performance)
|
||||
# by defining G4_NO_STORE_TRAJECTORY.
|
||||
|
||||
ifndef G4_NO_STORE_TRAJECTORY
|
||||
CPPFLAGS += -DG4_STORE_TRAJECTORY
|
||||
endif
|
||||
|
||||
#
|
||||
# Enable/disable G4cout/G4cerr
|
||||
#
|
||||
|
||||
# Set G4STREAM for all platforms.
|
||||
|
||||
G4STREAM = 1
|
||||
|
||||
# Set G4STREAM_STREAMBUF_IMPLEMENTATION for selected platforms.
|
||||
|
||||
ifeq ($(findstring AIX,$(G4SYSTEM)),AIX)
|
||||
G4STREAM_STREAMBUF_IMPLEMENTATION = 1
|
||||
endif
|
||||
|
||||
ifeq ($(findstring WIN32,$(G4SYSTEM)),WIN32)
|
||||
G4STREAM_STREAMBUF_IMPLEMENTATION = 1
|
||||
endif
|
||||
|
||||
ifdef G4STREAM
|
||||
CPPFLAGS += -DG4STREAM
|
||||
endif
|
||||
|
||||
ifdef G4STREAM_STREAMBUF_IMPLEMENTATION
|
||||
CPPFLAGS += -DG4STREAM_STREAMBUF_IMPLEMENTATION
|
||||
endif
|
||||
|
||||
#
|
||||
# Template setup - repositories, special options etc
|
||||
#
|
||||
ifdef CFRONT_G4TEMPLATE_REPOSITORY
|
||||
ifeq ($(findstring DEC,$(G4SYSTEM)),DEC)
|
||||
ifdef G4EXEC_BUILD
|
||||
CXXTEMPLATE_FLAGS := -ptr $(G4TREP)/exec -ptr $(G4TREP)
|
||||
else
|
||||
CXXTEMPLATE_FLAGS := -ptr $(G4TREP)
|
||||
endif
|
||||
else
|
||||
ifdef G4EXEC_BUILD
|
||||
CXXTEMPLATE_FLAGS := -ptr$(G4TREP)/exec -ptr$(G4TREP)
|
||||
else
|
||||
CXXTEMPLATE_FLAGS := -ptr$(G4TREP)
|
||||
endif
|
||||
endif
|
||||
CXXFLAGS += $(CXXTEMPLATE_FLAGS)
|
||||
CFRONT := true
|
||||
endif
|
||||
ifdef CFRONT
|
||||
G4TEMPLATE_REPOSITORY_PARENT := $(shell echo $(G4TREP) | sed 's!/[^/][^/]*/*$$!!' )
|
||||
G4DUMMY_VARIABLE:=$(shell [ ! -d $(G4TEMPLATE_REPOSITORY_PARENT) ] && mkdir -p $(G4TEMPLATE_REPOSITORY_PARENT) )
|
||||
G4DUMMY_VARIABLE:=$(shell [ ! -d $(G4TREP) ] && mkdir -p $(G4TREP) )
|
||||
G4DUMMY_VARIABLE:=$(shell [ ! -d $(G4TREP)/exec ] &&mkdir -p $(G4TREP)/exec )
|
||||
endif
|
||||
|
||||
@@ -0,0 +1,222 @@
|
||||
# $Id: binmake.gmk,v 2.22 1998/12/01 22:59:47 gcosmo Exp $
|
||||
# ----------------------------------------------------------
|
||||
# Script defining rules and paths for making binaries.
|
||||
# Gabriele Cosmo, 25/06/1998.
|
||||
# ----------------------------------------------------------
|
||||
|
||||
ifndef LDFLAGS
|
||||
include $(G4INSTALL)/config/architecture.gmk
|
||||
endif
|
||||
|
||||
G4LIBDIR := $(G4LIB)/$(G4SYSTEM)
|
||||
|
||||
include $(G4INSTALL)/config/G4UI_USE.gmk
|
||||
include $(G4INSTALL)/config/G4VIS_USE.gmk
|
||||
include $(G4INSTALL)/config/interactivity.gmk
|
||||
|
||||
ifndef INCFLAGS
|
||||
INCFLAGS := \
|
||||
-I$(G4BASE)/global/management/include \
|
||||
-I$(G4BASE)/global/HEPRandom/include \
|
||||
-I$(G4BASE)/global/HEPGeometry/include \
|
||||
-I$(G4BASE)/run/include \
|
||||
-I$(G4BASE)/materials/include \
|
||||
-I$(G4BASE)/particles/management/include \
|
||||
-I$(G4BASE)/particles/bosons/include \
|
||||
-I$(G4BASE)/particles/leptons/include \
|
||||
-I$(G4BASE)/particles/hadrons/barions/include \
|
||||
-I$(G4BASE)/particles/hadrons/ions/include \
|
||||
-I$(G4BASE)/particles/hadrons/mesons/include \
|
||||
-I$(G4BASE)/processes/management/include \
|
||||
-I$(G4BASE)/processes/general/include \
|
||||
-I$(G4BASE)/processes/decay/include \
|
||||
-I$(G4BASE)/processes/optical/include \
|
||||
-I$(G4BASE)/processes/transportation/include \
|
||||
-I$(G4BASE)/processes/parameterisation/include \
|
||||
-I$(G4BASE)/processes/electromagnetic/standard/include \
|
||||
-I$(G4BASE)/processes/electromagnetic/muons/include \
|
||||
-I$(G4BASE)/processes/electromagnetic/utils/include \
|
||||
-I$(G4BASE)/processes/electromagnetic/xrays/include \
|
||||
-I$(G4BASE)/processes/hadronic/management/include \
|
||||
-I$(G4BASE)/processes/hadronic/processes/include \
|
||||
-I$(G4BASE)/processes/hadronic/util/include \
|
||||
-I$(G4BASE)/processes/hadronic/cross_sections/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/de_excitation/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/diffractive_string/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/high_energy/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/kinetic_model/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/management/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/pre_equilibrium/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/quark_gluon_string/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/string_common/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/string_fragmentation/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/generator/util/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/high_energy/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/low_energy/include \
|
||||
-I$(G4BASE)/processes/hadronic/models/neutron_hp/include \
|
||||
-I$(G4BASE)/processes/hadronic/stopping/include \
|
||||
-I$(G4BASE)/geometry/management/include \
|
||||
-I$(G4BASE)/geometry/solids/CSG/include \
|
||||
-I$(G4BASE)/geometry/solids/BREPS/include \
|
||||
-I$(G4BASE)/geometry/solids/STEP/include \
|
||||
-I$(G4BASE)/geometry/solids/STEPinterface/include \
|
||||
-I$(G4BASE)/geometry/volumes/include \
|
||||
-I$(G4BASE)/geometry/magneticfield/include \
|
||||
-I$(G4BASE)/track/include \
|
||||
-I$(G4BASE)/tracking/include \
|
||||
-I$(G4BASE)/digits+hits/detector/include \
|
||||
-I$(G4BASE)/digits+hits/hits/include \
|
||||
-I$(G4BASE)/digits+hits/digits/include \
|
||||
-I$(G4BASE)/readout/include \
|
||||
-I$(G4BASE)/event/include \
|
||||
-I$(G4BASE)/graphics_reps/include \
|
||||
-I$(G4BASE)/intercoms/include
|
||||
endif
|
||||
|
||||
ifdef G4ODBMS
|
||||
INCFLAGS += \
|
||||
-I$(G4BASE)/persistency/management/include \
|
||||
-I$(G4BASE)/persistency/events/include \
|
||||
-I$(G4BASE)/persistency/digits+hits/hits/include \
|
||||
-I$(G4BASE)/persistency/geometry/management/include \
|
||||
-I$(G4BASE)/persistency/geometry/volumes/include \
|
||||
-I$(G4BASE)/persistency/geometry/solids/CSG/include \
|
||||
-I$(G4TMP)/$(G4SYSTEM)/G4pmanagement \
|
||||
-I$(G4TMP)/$(G4SYSTEM)/G4pevents \
|
||||
-I$(G4TMP)/$(G4SYSTEM)/G4phits \
|
||||
-I$(G4TMP)/$(G4SYSTEM)/G4pgeomn \
|
||||
-I$(G4TMP)/$(G4SYSTEM)/G4pvol \
|
||||
-I$(G4TMP)/$(G4SYSTEM)/G4pcsg \
|
||||
-I$(OBJY_DIR)/include \
|
||||
-I$(HEP_ODBMS_DIR)/include \
|
||||
-DHep_HAS_BUILDIN_BOOL_CONSTANTS
|
||||
endif
|
||||
|
||||
ifndef LDLIBS
|
||||
|
||||
ifdef G4EXLIB
|
||||
LDLIBS := -l$(G4TARGET) $(VISLIBS) $(UILIBS)
|
||||
else
|
||||
LDLIBS := $(VISLIBS) $(UILIBS)
|
||||
endif
|
||||
|
||||
ifdef G4ODBMS
|
||||
LDLIBS += -lG4persistency
|
||||
endif
|
||||
|
||||
LDLIBS += \
|
||||
-lG4readout \
|
||||
-lG4run \
|
||||
-lG4event \
|
||||
-lG4tracking \
|
||||
-lG4processes \
|
||||
-lG4particles \
|
||||
-lG4digits+hits \
|
||||
-lG4track \
|
||||
-lG4materials \
|
||||
-lG4geometry \
|
||||
-lG4graphics_reps \
|
||||
-lG4intercoms \
|
||||
-lG4global \
|
||||
$(INTYLIBS)
|
||||
endif
|
||||
|
||||
ifdef G4ODBMS
|
||||
LDFLAGS += -L$(OBJY_DIR)/lib \
|
||||
-L$(HEP_ODBMS_DIR)/lib
|
||||
|
||||
# Note: -loo_sahr.4.02 and -lHepODBMS should be placed
|
||||
# _before_ -l$(CLHEP_LIB) -l$(RWLIB)
|
||||
|
||||
LDLIBS += -loo_shar.4.02 -lHepODBMS
|
||||
endif
|
||||
|
||||
CPPFLAGS += $(INCFLAGS)
|
||||
LDFLAGS += -L$(G4LIBDIR)
|
||||
LDLIBS += $(LOADLIBS)
|
||||
|
||||
G4TMPDIR := $(G4TMP)/$(G4SYSTEM)/$(G4TARGET)
|
||||
G4BINDIR := $(G4BIN)/$(G4SYSTEM)
|
||||
|
||||
ifdef G4EXLIB
|
||||
G4LIBDIR := $(G4TMPDIR)
|
||||
LDFLAGS += -L$(G4LIBDIR)
|
||||
include $(G4INSTALL)/config/common.gmk
|
||||
endif
|
||||
|
||||
LDLIBS += $(EXTRALIBS)
|
||||
|
||||
sources := $(wildcard $(G4TARGET).cc)
|
||||
objects := $(patsubst %.cc,$(G4TMPDIR)/exe/%.o,$(sources))
|
||||
dependencies := $(patsubst %.cc,$(G4TMPDIR)/exe/%.d,$(sources))
|
||||
|
||||
.PHONY: bin clean clean_bin
|
||||
|
||||
# Make $(G4TARGET) executable.
|
||||
bin: $(G4BINDIR)/$(G4TARGET)
|
||||
|
||||
ifeq ($(G4SYSTEM),WIN32-VC-NICE)
|
||||
WIN32TMP := $(patsubst -L%,$(LIB_PATH)%,$(LDFLAGS))
|
||||
LDFLAGS = $(patsubst /,$(PATH_DEL),$(WIN32TMP))
|
||||
LDLIBS := $(patsubst -l%,lib%.a,$(LDLIBS))
|
||||
endif
|
||||
|
||||
$(G4BINDIR)/$(G4TARGET): $(G4TMPDIR)/exe/obj.last
|
||||
@if [ ! -d $(G4BINDIR) ] ; then mkdir $(G4BINDIR) ;fi
|
||||
ifdef CPPVERBOSE
|
||||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) \
|
||||
-o $(G4BINDIR)/$(G4TARGET) $(objects) $(LDFLAGS) $(LDLIBS)
|
||||
else
|
||||
@echo Linking $(G4TARGET) ...
|
||||
@$(CXX) $(CXXFLAGS) $(CPPFLAGS) \
|
||||
-o $(G4BINDIR)/$(G4TARGET) $(objects) $(LDFLAGS) $(LDLIBS)
|
||||
endif
|
||||
|
||||
# Touch the versioning file
|
||||
ifdef G4EXLIB
|
||||
$(G4TMPDIR)/exe/obj.last: lib $(objects)
|
||||
else
|
||||
$(G4TMPDIR)/exe/obj.last: $(objects)
|
||||
endif
|
||||
@touch $@
|
||||
|
||||
# Make the $(G4TARGET).o file.
|
||||
$(G4TMPDIR)/exe/$(G4TARGET).o : $(G4TARGET).cc
|
||||
ifdef CPPVERBOSE
|
||||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(APPFLAGS) \
|
||||
-c $(OUT_OBJ)$(G4TMPDIR)/exe/$(G4TARGET).o $(G4TARGET).cc
|
||||
else
|
||||
@echo Compiling $(G4TARGET).cc ...
|
||||
@$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(APPFLAGS) \
|
||||
-c $(OUT_OBJ)$(G4TMPDIR)/exe/$(G4TARGET).o $(G4TARGET).cc
|
||||
endif
|
||||
|
||||
# Make the $(G4TARGET).d file and include it.
|
||||
$(G4TMPDIR)/exe/$(G4TARGET).d: $(G4TARGET).cc
|
||||
@if [ ! -d $(G4TMP)/$(G4SYSTEM) ] ; then mkdir $(G4TMP)/$(G4SYSTEM) ;fi
|
||||
@if [ ! -d $(G4TMPDIR) ] ; then mkdir $(G4TMPDIR) ;fi
|
||||
@if [ ! -d $(G4TMPDIR)/exe ] ; then mkdir $(G4TMPDIR)/exe ;fi
|
||||
@echo Making dependency for file $<...
|
||||
ifeq ($(G4SYSTEM),Linux-g++)
|
||||
@($(ECHO) -n $(G4TMPDIR)/exe/ ; \
|
||||
g++ -MM $(RWINCGPP) $(CPPFLAGS) $< ) | sed 's!$(G4TMPDIR)/exe/$*.o!& $@!' >$@
|
||||
else
|
||||
@($(ECHO) $(G4TMPDIR)/\\c ; \
|
||||
g++ -MM $(RWINCGPP) $(CPPFLAGS) $< ) | sed 's!$(G4TMPDIR)/exe/$*.o!& $@!' >$@
|
||||
endif
|
||||
-include $(dependencies)
|
||||
|
||||
clean:
|
||||
@echo Cleaning up ...
|
||||
@rm -f ./core
|
||||
@rm -rf $(G4TMPDIR)
|
||||
@rm -f $(G4LIBDIR)/lib$(G4TARGET).a
|
||||
@rm -f $(G4BINDIR)/$(G4TARGET)
|
||||
ifdef CFRONT
|
||||
@rm -rf $(G4TREP)/exec
|
||||
endif
|
||||
|
||||
clean_bin:
|
||||
@echo Removing application $(G4TARGET) ...
|
||||
@rm -f ./core
|
||||
@rm -f $(G4BINDIR)/$(G4TARGET)
|
||||
@@ -0,0 +1,143 @@
|
||||
# $Id: common.gmk,v 2.7 1998/07/29 00:53:08 gcosmo Exp $
|
||||
# ----------------------------------------------------------------
|
||||
# Common part of GNUmakefile for libraries. John Allison, 5/7/95.
|
||||
# ----------------------------------------------------------------
|
||||
# Libraries are created according to G4SYSTEM. G.Cosmo, 11/6/96.
|
||||
# Introduced G4LIBDIR and G4TMPDIR. G.Cosmo, 23/6/98.
|
||||
|
||||
ifndef G4LIBDIR
|
||||
G4LIBDIR := $(G4LIB)/$(G4SYSTEM)
|
||||
endif
|
||||
G4TMPDIR := $(G4TMP)/$(G4SYSTEM)/$(name)
|
||||
|
||||
sources := $(wildcard src/*.cc)
|
||||
schema_ddl := $(wildcard include/*.ddl)
|
||||
schema_hh := $(patsubst include/%.ddl,$(G4TMPDIR)/%.hh,$(schema_ddl))
|
||||
objects := $(patsubst src/%.cc,$(G4TMPDIR)/%.o,$(sources))
|
||||
dependencies := $(patsubst src/%.cc,$(G4TMPDIR)/%.d,$(sources))
|
||||
|
||||
# output of ooddlx in G4TMPDIR (.hh, _ref.hh, _ddl.cc)
|
||||
#
|
||||
temporaries := $(patsubst include/%.ddl,$(G4TMPDIR)/%.hh,$(schema_ddl))
|
||||
|
||||
# output of ooddlx in the current directory (if the process does not finish)
|
||||
#
|
||||
temporaries2 := $(patsubst include/%.ddl,%.hh,$(schema_ddl))
|
||||
|
||||
ifdef G4ODBMS
|
||||
temporaries += $(patsubst include/%.ddl,$(G4TMPDIR)/%_ddl.cc,$(schema_ddl)) \
|
||||
$(patsubst include/%.ddl,$(G4TMPDIR)/%_ref.hh,$(schema_ddl))
|
||||
temporaries2 += $(patsubst include/%.ddl,%_ddl.cc,$(schema_ddl)) \
|
||||
$(patsubst include/%.ddl,%_ref.hh,$(schema_ddl))
|
||||
objects += $(patsubst include/%.ddl,$(G4TMPDIR)/%_ddl.o,$(schema_ddl))
|
||||
endif
|
||||
|
||||
ifneq ($(G4MAKESHLIB),)
|
||||
# Make shared library.
|
||||
$(G4LIBDIR)/lib$(name).$(SHEXT): $(G4LIBDIR)/lib$(name).a
|
||||
@cp $(objects) $(G4LIBDIR)/.
|
||||
sh $(G4MAKESHLIB) $(G4LIBDIR) $(name)
|
||||
$(RM) $(G4LIBDIR)/*.o
|
||||
endif
|
||||
|
||||
# Make library.
|
||||
$(G4LIBDIR)/lib$(name).a: $(G4TMPDIR)/obj.last
|
||||
@if [ ! -d $(G4LIBDIR) ] ; then mkdir $(G4LIBDIR) ;fi
|
||||
@echo Creating/replacing object files in $(G4LIBDIR)/lib$(name).a
|
||||
@rm -f $(G4LIBDIR)/lib$(name).a
|
||||
@$(AR) $(OUT_LIB)$(G4LIBDIR)/lib$(name).a $(G4TMPDIR)/*.o
|
||||
@if [ -f /usr/bin/ranlib -o -f /bin/ranlib ] ; then ranlib $(G4LIBDIR)/lib$(name).a ;fi
|
||||
|
||||
# Touch the versioning file
|
||||
$(G4TMPDIR)/obj.last: $(objects)
|
||||
@touch $@
|
||||
|
||||
# Make the .o files.
|
||||
ifdef G4ODBMS
|
||||
$(G4TMPDIR)/%.o: src/%.cc $(schema_hh)
|
||||
else
|
||||
$(G4TMPDIR)/%.o: src/%.cc
|
||||
endif
|
||||
ifdef CPPVERBOSE
|
||||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $(OUT_OBJ)$(G4TMPDIR)/$(*F).o src/$*.cc
|
||||
else
|
||||
@echo Compiling $*.cc ...
|
||||
@$(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $(OUT_OBJ)$(G4TMPDIR)/$(*F).o src/$*.cc
|
||||
endif
|
||||
ifdef G4ODBMS
|
||||
$(G4TMPDIR)/%.o: $(G4TMPDIR)/%.cc
|
||||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) -c -o $(G4TMPDIR)/$(*F).o $(G4TMPDIR)/$*.cc
|
||||
endif
|
||||
# Make the temporary files.
|
||||
.PRECIOUS: $(G4TMPDIR)/%_ddl.cc ddl/%.hh $(G4TMPDIR)/%_ref.hh
|
||||
|
||||
ifdef G4ODBMS
|
||||
$(G4TMPDIR)/%_ddl.cc $(G4TMPDIR)/%.hh $(G4TMPDIR)/%_ref.hh: include/%.ddl
|
||||
@if [ ! -d $(G4TMP)/$(G4SYSTEM) ] ; then mkdir $(G4TMP)/$(G4SYSTEM) ;fi
|
||||
@if [ ! -d $(G4TMPDIR) ] ; then mkdir $(G4TMPDIR) ;fi
|
||||
ooddlx -notitle -header_suffix .hh -ref_suffix _ref.hh -c++_suffix _ddl.cc \
|
||||
-DRW_NO_CONST_OVERLOAD -DRW_NO_STL -DTEMPLATEP_HIDES_FNCD \
|
||||
$(CPPFLAGS) $< $(G4EXAMPLE_BOOT)
|
||||
mv -f $*.hh $(G4TMPDIR)/
|
||||
mv -f $*_ref.hh $(G4TMPDIR)/
|
||||
mv -f $*_ddl.cc $(G4TMPDIR)/
|
||||
else
|
||||
$(G4TMPDIR)/%.hh: include/%.ddl
|
||||
@if [ ! -d $(G4TMP)/$(G4SYSTEM) ] ; then mkdir $(G4TMP)/$(G4SYSTEM) ;fi
|
||||
@if [ ! -d $(G4TMPDIR) ] ; then mkdir $(G4TMPDIR) ;fi
|
||||
ln -s -f ../$< $(G4TMPDIR)/$*.hh
|
||||
endif
|
||||
|
||||
# Make the .d file(s) and include it(them).
|
||||
# g++ -MM is good at this, except it forgets the subdirectory
|
||||
# (hence the use of $G4TMP/).
|
||||
|
||||
ifdef G4ODBMS
|
||||
$(G4TMPDIR)/%.d: src/%.cc $(schema_hh)
|
||||
else
|
||||
$(G4TMPDIR)/%.d: src/%.cc
|
||||
endif
|
||||
@if [ ! -d $(G4TMP)/$(G4SYSTEM) ] ; then mkdir $(G4TMP)/$(G4SYSTEM) ;fi
|
||||
@if [ ! -d $(G4TMPDIR) ] ; then mkdir $(G4TMPDIR) ;fi
|
||||
@echo Making dependency for file $< ...
|
||||
@($(ECHO) $(G4TMPDIR)/\\c ; \
|
||||
g++ -MM $(RWINCGPP) $(CPPFLAGS) $< ) | sed 's!$(G4TMPDIR)/$*.o!& $@!' >$@
|
||||
ifdef G4ODBMS
|
||||
ifdef G4ODBMS_DEPEND
|
||||
-include $(dependencies)
|
||||
endif
|
||||
else
|
||||
-include $(dependencies)
|
||||
endif
|
||||
|
||||
# .PHONY targets are executed regardless of time-stamp of any file of
|
||||
# same name.
|
||||
.PHONY: all obj lib clean clean_libs
|
||||
|
||||
obj: $(G4TMPDIR)/obj.last
|
||||
|
||||
ifdef G4ODBMS
|
||||
headers: $(schema_hh)
|
||||
|
||||
d_files: $(dependencies)
|
||||
|
||||
$(schema_hh): $(schema_ddl)
|
||||
endif
|
||||
|
||||
ifneq ($(G4MAKESHLIB),)
|
||||
lib: $(G4LIBDIR)/lib$(name).$(SHEXT)
|
||||
else
|
||||
lib: $(G4LIBDIR)/lib$(name).a
|
||||
endif
|
||||
|
||||
ifndef G4EXLIB
|
||||
clean:
|
||||
@echo Cleaning up ...
|
||||
@rm -f $(G4LIBDIR)/lib$(name).a
|
||||
@rm -rf $(G4TMPDIR)
|
||||
endif
|
||||
|
||||
clean_libs:
|
||||
@if [ -f $(G4LIBDIR)/lib$(name).a ] ; then \
|
||||
$(ECHO) Removing library lib$(name).a ... ; \
|
||||
$(RM) -f $(G4LIBDIR)/lib$(name).a ; fi
|
||||
Executable
+98
@@ -0,0 +1,98 @@
|
||||
#!/usr/local/bin/perl
|
||||
|
||||
sub usage {
|
||||
print STDERR "This script takes a STEP file (from STDIN)\n";
|
||||
print STDERR "and writes it to STDOUT with the data section\n";
|
||||
print STDERR "sorted by ID.\n";
|
||||
exit 1;
|
||||
}
|
||||
|
||||
sub error {
|
||||
print STDERR $_[0]."\n";
|
||||
exit 2;
|
||||
}
|
||||
|
||||
if ($#ARGV >= 0) {
|
||||
&usage();
|
||||
}
|
||||
|
||||
##########################################################################
|
||||
|
||||
$entry= "";
|
||||
while (<STDIN>) {
|
||||
while ($_ ne "") {
|
||||
|
||||
if (/[;']/) { #']){
|
||||
|
||||
$entry.= $`.$&;
|
||||
$_= $';
|
||||
if ($& eq ";") {
|
||||
|
||||
# end of entry
|
||||
$lof= $_;
|
||||
&processEntry($entry);
|
||||
$entry= "";
|
||||
$_= $lof;
|
||||
|
||||
} else {
|
||||
|
||||
# start of string
|
||||
/[']/ || &error("String does not end within the line!"); #'];
|
||||
$entry.= $`.$&;
|
||||
$_= $';
|
||||
|
||||
}
|
||||
} else {
|
||||
|
||||
$entry.= $_;
|
||||
$_= "";
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/^[ \t\n]*$/m || &error("File does not end with ';' !");
|
||||
print "$_\n";
|
||||
exit 0;
|
||||
|
||||
##########################################################################
|
||||
|
||||
sub processEntry {
|
||||
local($e)= @_;
|
||||
|
||||
if (!$inData) {
|
||||
|
||||
print $e;
|
||||
if ($e =~ /^(\s|\n)*DATA(\s|\n)*;$/m) {
|
||||
$inData= 1;
|
||||
}
|
||||
|
||||
} else {
|
||||
|
||||
if ($e =~ /^(\s|\n)*\#([0-9]+)\=/m) {
|
||||
|
||||
$id= $2;
|
||||
$entries[$id]= $e;
|
||||
|
||||
} else {
|
||||
|
||||
$e =~ /^(\s|\n)*ENDSEC(\s|\n)*;$/m ||
|
||||
&error("Data section does not end with ENDSEC;");
|
||||
$inData= 0;
|
||||
for ($id=0; $id<=$#entries; $id++) {
|
||||
$en= $entries[$id];
|
||||
if ($en ne "") {
|
||||
print $en;
|
||||
}
|
||||
}
|
||||
print $e;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
##########################################################################
|
||||
##########################################################################
|
||||
##########################################################################
|
||||
|
||||
|
||||
Executable
+41
@@ -0,0 +1,41 @@
|
||||
#!/usr/local/bin/perl
|
||||
|
||||
$filename = $ARGV[0];
|
||||
open(INFILE, $filename) || die "\nSTEP file ".$filename." not found.";
|
||||
print "Opening file ".$filename;
|
||||
@filebuf = <INFILE>;
|
||||
close(INFILE);
|
||||
|
||||
$g4 = "G4";
|
||||
$outputfile = $g4 . $filename;
|
||||
open(OUTFILE, ">$outputfile");
|
||||
print "\nModifying STEP file for NIST toolkit...";
|
||||
|
||||
foreach (@filebuf)
|
||||
{
|
||||
if(/.*VERTEX\_POINT.*/)
|
||||
{
|
||||
s/VERTEX\_POINT\(\'\'\,/VERTEX\_POINT\(\'\'\,\'\'\,/g ;
|
||||
}
|
||||
elsif(/.*EDGE\_LOOP.*/)
|
||||
{
|
||||
s/EDGE\_LOOP\(\'\'\,/EDGE\_LOOP\(\'\'\,\'\'\,/g;
|
||||
}
|
||||
elsif(/.*ADVANCED\_FACE.*/)
|
||||
{
|
||||
($a,$b,$c) = split('\)',$&);
|
||||
s//$a\)\,\'\' $b\)$c\n/;
|
||||
}
|
||||
elsif(/.*EDGE\_CURVE.*/)
|
||||
{
|
||||
($a,$b,$c,$d,$e) = split(",",$&);
|
||||
s//$a\, $b\,$c\,\'\'\,$d\,$e\n/;
|
||||
}
|
||||
|
||||
print OUTFILE;
|
||||
}
|
||||
|
||||
close(OUTFILE);
|
||||
print "\nOutput written to ".$outputfile."\n";
|
||||
|
||||
|
||||
@@ -0,0 +1,110 @@
|
||||
# $Id: globlib.gmk,v 2.15 1998/12/11 00:40:21 gcosmo Exp $
|
||||
# --------------------------------------------------------------
|
||||
# Script for compound libraries. Gabriele Cosmo, 25/6/98.
|
||||
# --------------------------------------------------------------
|
||||
|
||||
ifndef G4INSTALL
|
||||
G4INSTALL = ..
|
||||
endif
|
||||
|
||||
include $(G4INSTALL)/config/architecture.gmk
|
||||
|
||||
G4LIBDIR = $(G4LIB)/$(G4SYSTEM)
|
||||
|
||||
.PHONY : all glob global objs clean clean_libs wipe_libs
|
||||
|
||||
all:
|
||||
ifndef G4ODBMS
|
||||
@for dir in $(SUBDIRS); do (cd $$dir; $(MAKE)); done
|
||||
else
|
||||
@for dir in $(SUBDIRS); do (cd $$dir; $(MAKE) headers); done
|
||||
@for dir in $(SUBDIRS); do (cd $$dir; $(MAKE) d_files); done
|
||||
@for dir in $(SUBDIRS); do (cd $$dir; G4ODBMS_DEPEND=1; export G4ODBMS_DEPEND; $(MAKE)); done
|
||||
endif
|
||||
|
||||
ifndef G4ODBMS
|
||||
glob global: objs wipe_libs $(G4LIBDIR)/lib$(name).a
|
||||
else
|
||||
glob global: all $(G4LIBDIR)/lib$(name).a $(G4SCHEMA_DIR)/G4SCHEMA.FDDB
|
||||
endif
|
||||
|
||||
$(G4LIBDIR)/lib$(name).a: \
|
||||
$(foreach dir,$(SUBLIBS),$(G4TMP)/$(G4SYSTEM)/$(dir)/obj.last)
|
||||
@if [ ! -d $(G4LIBDIR) ] ; then mkdir $(G4LIBDIR) ; fi
|
||||
@echo Merging object files in $(G4LIBDIR)/lib$(name).a
|
||||
@$(RM) $(G4LIBDIR)/lib$(name).a
|
||||
#
|
||||
#
|
||||
#
|
||||
@if [ X$(G4SYSTEM) = XWIN32-VC-NICE ] ; i=NO; \
|
||||
then \
|
||||
(( for lib in $(SUBLIBS); \
|
||||
do ( if [ $$i = NO ]; \
|
||||
then \
|
||||
$(AR) $(OUT_LIB)$(G4LIBDIR)/lib$(name).lib \
|
||||
$(G4TMP)/$(G4SYSTEM)/$$lib/*.o ; \
|
||||
else \
|
||||
$(AR) $(G4LIBDIR)/lib$(name).lib $(G4TMP)/$(G4SYSTEM)/$$lib/*.o; \
|
||||
fi ); \
|
||||
i=YES; \
|
||||
done ) ; \
|
||||
mv $(G4LIBDIR)/lib$(name).lib $(G4LIBDIR)/lib$(name).a); \
|
||||
else \
|
||||
(for lib in $(SUBLIBS); \
|
||||
do ($(AR) $(OUT_LIB)$(G4LIBDIR)/lib$(name).a \
|
||||
$(G4TMP)/$(G4SYSTEM)/$$lib/*.o); \
|
||||
done);\
|
||||
fi
|
||||
#
|
||||
#
|
||||
#
|
||||
@if [ -f /usr/bin/ranlib -o -f /bin/ranlib ] ; then \
|
||||
ranlib $(G4LIBDIR)/lib$(name).a ; fi
|
||||
|
||||
##
|
||||
## make shared libraries
|
||||
##
|
||||
ifneq ($(G4MAKESHLIB),)
|
||||
@for lib in $(SUBLIBS); do (cp $(G4TMP)/$(G4SYSTEM)/$$lib/*.o $(G4LIBDIR)/.); done
|
||||
@sh $(G4MAKESHLIB) $(G4LIBDIR) $(name)
|
||||
$(RM) $(G4LIBDIR)/*.o
|
||||
endif
|
||||
|
||||
ifdef G4ODBMS
|
||||
headers:
|
||||
@for dir in $(SUBDIRS); do (cd $$dir; $(MAKE) headers); done
|
||||
|
||||
d_files:
|
||||
@for dir in $(SUBDIRS); do (cd $$dir; $(MAKE) d_files); done
|
||||
|
||||
$(G4SCHEMA_DIR)/G4SCHEMA.FDDB: $(G4EXAMPLE_BOOT_DIR)/G4EXAMPLE.FDDB
|
||||
ifdef G4SCHEMA_DIR
|
||||
@rm -f $(G4SCHEMA_DIR)/G4SCHEMA
|
||||
@rm -f $(G4SCHEMA_DIR)/G4SCHEMA.FDDB
|
||||
@echo Copying schema file to $(G4SCHEMA_DIR) for FDID $(G4SCHEMA_FDID)
|
||||
@$(HEP_ODBMS_DIR)/etc/getdb $(G4EXAMPLE_BOOT) \
|
||||
$(G4SCHEMA_DIR)/G4SCHEMA $(G4SCHEMA_FDID)
|
||||
endif
|
||||
endif
|
||||
|
||||
objs:
|
||||
@for dir in $(SUBDIRS); \
|
||||
do (cd $$dir; $(MAKE) -q obj && ok=yes; \
|
||||
if [ $$ok ]; \
|
||||
then echo Nothing to be done for lib$(name).a in $$dir/.; \
|
||||
else $(MAKE) clean_libs; $(MAKE) obj; \
|
||||
fi; ) \
|
||||
done
|
||||
|
||||
wipe_libs:
|
||||
@for lib in $(SUBLIBS); do (rm -f $(G4LIBDIR)/lib$$lib.a); done
|
||||
|
||||
clean:
|
||||
@echo Cleaning up ...
|
||||
@for lib in $(SUBLIBS); do (rm -rf $(G4TMP)/$(G4SYSTEM)/$$lib; rm -f $(G4LIBDIR)/lib$$lib.a); done
|
||||
@rm -f $(G4LIBDIR)/lib$(name).a
|
||||
|
||||
clean_libs:
|
||||
@echo Removing lib$(name).a and sub-libraries ...
|
||||
@for lib in $(SUBLIBS); do (rm -f $(G4LIBDIR)/lib$$lib.a); done
|
||||
@rm -f $(G4LIBDIR)/lib$(name).a
|
||||
@@ -0,0 +1,120 @@
|
||||
# GNUmakefile for CPPFLAGS, LDFLAGS for interactivy,
|
||||
# ie interfaces and visualization.
|
||||
#
|
||||
# Here we really set the CCPFLAGS, LDFLAGS for X11, Motif,...
|
||||
# according various INC_xxx, LOAD_xxx flags setted in
|
||||
# G4[UI, VIS]_[USE, BUILD].gmk. With this logic the
|
||||
# flags for one product (X11, Motif,...) will appear once
|
||||
# in the compilation/load command line.
|
||||
#
|
||||
# Guy Barrand, 7th July 1998.
|
||||
|
||||
# Other libraries
|
||||
|
||||
########################### OpenGL, Inventor ############
|
||||
|
||||
# Should be before OpenGL.
|
||||
ifdef INC_IV
|
||||
INC_GL = 1
|
||||
CPPFLAGS += $(OIVFLAGS)
|
||||
endif
|
||||
ifdef LOAD_IV
|
||||
LOAD_GL = 1
|
||||
INTYLIBS += $(OIVLIBS)
|
||||
endif
|
||||
|
||||
ifdef INC_GL
|
||||
CPPFLAGS += $(OGLFLAGS)
|
||||
endif
|
||||
ifdef LOAD_GL
|
||||
INTYLIBS += $(OGLLIBS)
|
||||
endif
|
||||
|
||||
########################### OPACS #######################
|
||||
# X11 things must come after.
|
||||
|
||||
ifdef INC_OPACS
|
||||
CPPFLAGS += -I$(COROOT)/include -I$(XXROOT)/include -I$(WOROOT)/include
|
||||
# Let Wo knows Xm (or Xaw) and Xo widget sets
|
||||
ifeq ($(G4_OPACS_WIDGET_SET),Xm)
|
||||
INC_XM = 1
|
||||
CPPFLAGS += -DHAS_XM
|
||||
else
|
||||
INC_XAW = 1
|
||||
CPPFLAGS += -DHAS_XAW
|
||||
endif
|
||||
CPPFLAGS += -DHAS_XO -DHAS_GO -I$(GOROOT)/include -I$(HOROOT)/include -I$(XOROOT)/include
|
||||
endif
|
||||
|
||||
ifdef LOAD_OPACS
|
||||
ifeq ($(G4_OPACS_WIDGET_SET),Xm)
|
||||
INC_XM = 1
|
||||
LOAD_XM = 1
|
||||
INTYLIBS += -L$(WOROOT)/$(OCONFIG) -lWoXm
|
||||
else
|
||||
INC_XAW = 1
|
||||
LOAD_XAW = 1
|
||||
INTYLIBS += -L$(WOROOT)/$(OCONFIG) -lWoXaw
|
||||
endif
|
||||
INTYLIBS += -L$(WOROOT)/$(OCONFIG) -lWo
|
||||
INTYLIBS += -L$(XOROOT)/$(OCONFIG) -lXo
|
||||
INTYLIBS += -L$(GOROOT)/$(OCONFIG) -lGo
|
||||
INTYLIBS += -L$(HOROOT)/$(OCONFIG) -lHo
|
||||
INTYLIBS += -L$(W3OROOT)/$(OCONFIG) -lW3o
|
||||
INTYLIBS += -L$(HTMLOROOT)/$(OCONFIG) -lHTMLo
|
||||
ifndef LOAD_GL
|
||||
INTYLIBS += -L$(GLOROOT)/$(OCONFIG) -lGLXo -lGLUo -lGLo
|
||||
endif
|
||||
INTYLIBS += -L$(XXROOT)/$(OCONFIG) -lXx
|
||||
INTYLIBS += -L$(COROOT)/$(OCONFIG) -lCo
|
||||
endif
|
||||
|
||||
|
||||
########################### Motif, Athena, X11 ###################
|
||||
# Motif raise X11 flags.
|
||||
|
||||
# Should be before X11.
|
||||
ifdef INC_XM
|
||||
INC_X11 = 1
|
||||
CPPFLAGS += $(XMFLAGS)
|
||||
endif
|
||||
ifdef LOAD_XM
|
||||
LOAD_X11 = 1
|
||||
INTYLIBS += $(XMLIBS)
|
||||
endif
|
||||
|
||||
# Should be before X11.
|
||||
ifdef INC_XAW
|
||||
INC_X11 = 1
|
||||
CPPFLAGS += $(XAWFLAGS)
|
||||
endif
|
||||
ifdef LOAD_XAW
|
||||
LOAD_X11 = 1
|
||||
INTYLIBS += $(XAWLIBS)
|
||||
endif
|
||||
|
||||
ifdef INC_X11
|
||||
CPPFLAGS += $(X11FLAGS)
|
||||
endif
|
||||
ifdef LOAD_X11
|
||||
INTYLIBS += $(X11LIBS)
|
||||
endif
|
||||
|
||||
########################### and finally... #######################
|
||||
|
||||
ifdef G4INTY_BUILD_XT
|
||||
CPPFLAGS += -DG4INTY_BUILD_XT
|
||||
endif
|
||||
|
||||
ifdef G4INTY_USE_XT
|
||||
CPPFLAGS += -DG4INTY_USE_XT
|
||||
endif
|
||||
|
||||
ifdef G4INTY_BUILD_WIN32
|
||||
CPPFLAGS += -DG4INTY_BUILD_WIN32
|
||||
endif
|
||||
|
||||
ifdef G4INTY_USE_WIN32
|
||||
CPPFLAGS += -DG4INTY_USE_WIN32
|
||||
endif
|
||||
|
||||
Executable
+113
@@ -0,0 +1,113 @@
|
||||
#!/bin/sh -f
|
||||
############################################
|
||||
#### To build GEANT4 sheared libraries #####
|
||||
############# G.Barrand ####################
|
||||
############################################
|
||||
if test $# -eq 2 ; then
|
||||
g4system=$1
|
||||
name=$2
|
||||
liba=lib$name.a
|
||||
#echo $g4system
|
||||
#echo $name
|
||||
############################################
|
||||
##### build libs ###########################
|
||||
############################################
|
||||
if test -f $g4system/$liba ; then
|
||||
|
||||
if test `uname` = "OSF1" ; then
|
||||
cd $g4system
|
||||
# Need to specify a path, so that at run time loader
|
||||
# is able to find the so lib. This path is put in the
|
||||
# binaries at link time. In principle a relative
|
||||
# path from the binary is ok, but we will have
|
||||
# more than one binary at different places; so
|
||||
# we have to specify an absolute path.
|
||||
rpath=`pwd`
|
||||
#echo $rpath
|
||||
libso=lib$name.so
|
||||
/bin/rm -f $libso
|
||||
/bin/rm -f so_locations
|
||||
ld -expect_unresolved '*' -shared -o $libso -all $liba -rpath $rpath
|
||||
cd ..
|
||||
echo "$libso built."
|
||||
fi
|
||||
|
||||
if test `uname` = "HP-UX" ; then
|
||||
cd $g4system
|
||||
libso=lib$name.sl
|
||||
/bin/rm -f $libso
|
||||
# get .o files
|
||||
objs=`ls *.o`
|
||||
#ld -b -a shared -o $libso $objs
|
||||
# CC does more than ld.
|
||||
CC -b -o $libso $objs
|
||||
cd ..
|
||||
echo "$libso built."
|
||||
fi
|
||||
|
||||
if test `uname` = "IRIX" ; then
|
||||
cd $g4system
|
||||
# For path same remarks as for OSF1.
|
||||
rpath=`pwd`
|
||||
libso=lib$name.so
|
||||
/bin/rm -f $libso
|
||||
/bin/rm -f so_locations
|
||||
#ld -shared -o $libso -all $liba -rpath $rpath
|
||||
# CC does more than ld.
|
||||
CC -Wl,-rpath,$rpath -shared -o $libso -all $liba
|
||||
cd ..
|
||||
echo "$libso built."
|
||||
fi
|
||||
|
||||
if test `uname` = "AIX" ; then
|
||||
# Not yet ready.
|
||||
exit
|
||||
#set -x
|
||||
cd $g4system
|
||||
libso=lib$name'.so'
|
||||
/bin/rm -f lib$name.o
|
||||
/bin/rm -f $libso
|
||||
/bin/rm -f lib$name.exp
|
||||
# Get .o files
|
||||
objs=`ls *.o`
|
||||
# Determine how to invoke nm depending on AIX version
|
||||
AIXVERSION=`uname -v`
|
||||
case ${AIXVERSION}
|
||||
{
|
||||
3*)
|
||||
NM=/usr/ucb/nm
|
||||
;;
|
||||
4*)
|
||||
NM='/usr/bin/nm -B'
|
||||
;;
|
||||
*)
|
||||
echo "Error in g4makeshlib.sh!"
|
||||
exit 1
|
||||
;;
|
||||
}
|
||||
# Build export file (from Mesa mklib.aix).
|
||||
echo "#! lib$name.so " > lib$name.exp
|
||||
echo "noentry" >> lib$name.exp
|
||||
$NM $objs | awk '/ [BD] /{print $3}' | sort | uniq >> lib$name.exp
|
||||
# Below command from Mesa mklib.aix.
|
||||
#cc -o lib$name.o $objs $3 -bE:lib$name.exp -bM:SRE -enoentry
|
||||
# Unnecessary option -enoentry that produces
|
||||
# noentry file that contains exported symbols
|
||||
cc -o lib$name.o $objs $3 -bE:lib$name.exp -bM:SRE
|
||||
if test -f lib$name.o ; then
|
||||
ar r $libso lib$name.o
|
||||
/bin/rm -f lib$name.o
|
||||
else
|
||||
echo "Can't create lib$name.o."
|
||||
fi
|
||||
#cp $libso lib$name.a
|
||||
cd ..
|
||||
echo "$libso treated."
|
||||
fi
|
||||
|
||||
|
||||
fi
|
||||
############################################
|
||||
else
|
||||
echo 'Give name of binaray directory and library'
|
||||
fi
|
||||
Reference in New Issue
Block a user