]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - TGeant4/Makefile
added comment only
[u/mrichter/AliRoot.git] / TGeant4 / Makefile
index 696d7d556e3b36dc499d43c48774f9fad47fa6e0..774ab7df4c1cc6de38667d33e0761a646632c167 100644 (file)
@@ -27,10 +27,16 @@ HDRS          =  $(wildcard *.icc) $(wildcard *.h)
 
 # Library Root dictionary
 # only for selected classes
+# (temporarily excluded for OSF1 due to compilation errors)
 
+ifneq ($(ALICE_TARGET),OSF1)
 DICT          = TGeant4Cint.cxx
-DICTH         = TGeant4.h TG4VRunConfiguration.h TGeant4LinkDef.h
+DICTH         = TGeant4.h TG4VRunConfiguration.h \
+               TG4Editor.h TG4MainFrame.h TG4GeometryGUI.h TG4GuiVolume.h \
+               TG4MaterialsFrames.h TG4VolumesFrames.h TG4ListTreeFrame.h \
+               TGeant4LinkDef.h
 DICTO         = $(patsubst %.cxx,tgt_$(ALICE_TARGET)/%.o,$(DICT))
+endif
 
 # C++ Objects
 
@@ -46,16 +52,19 @@ CXXFLAGS      = $(CXXOPTS) -I$(ROOTSYS)/include -I. -I$(ALICE_ROOT)/include/
 # Target
 
 SLIBRARY       = $(LIBDIR)/libTGeant4.$(SL)
-ALIBRARY       = $(LIBDIR)/lib/libTGeant4.a
+ALIBRARY       = $(LIBDIR)/libTGeant4.a
 
 default:       $(SLIBRARY)
 
 $(LIBDIR)/libTGeant4.$(SL):            $(OBJS)
+$(LIBDIR)/libTGeant4.a:                        $(OBJS)
 
 $(DICT):                               $(DICTH)
 
 depend:                                        $(SRCS)
 
+clean: macroclean
+
 #HEADERS =     $(filter-out %LinkDef.h,$(HDRS))
 
 TOCLEAN        =       $(OBJS) *Cint.cxx *Cint.h
@@ -66,11 +75,41 @@ CHECKS  =       $(patsubst %.cxx,check/%.viol,$(SRCS))
 
 include $(ALICE_ROOT)/conf/GeneralMacros
 
-
 # Geant4 specific compiler flags
 
 CXXFLAGS += $(CPPFLAGS)
 
+# Remove optimisation for TG4PhysicsConstructorHadron
+
+ifeq ($(ALICE_TARGET),Linux)
+  COMPILER := $(shell g++ -v 2>&1 | grep version | grep egcs)
+  ifeq ($(findstring 1.1,$(COMPILER)),1.1)
+    CXXFLAGS_WITHOUT_O := $(filter-out -O% -Wuninitialized, $(CXXFLAGS))
+    tgt_$(ALICE_TARGET)/TG4PhysicsConstructorHadron.o : TG4PhysicsConstructorHadron.cxx
+      ifeq ($(CXXVERBOSE),)
+       @$(CXX) $(CXXFLAGS_WITHOUT_O) -c -o $@ TG4PhysicsConstructorHadron.cxx
+      else
+       $(CXX) $(CXXFLAGS_WITHOUT_O) -c -o $@ TG4PhysicsConstructorHadron.cxx
+      endif
+  endif
+endif      
+
+ifeq ($(ALICE_TARGET),HP-UX.aCC)
+  # remove optimisation for TG4PhysicsConstructorHadron
+  # to be tested
+  COMPILER := $(shell aCC -V 2>&1)
+  ifeq ($(COMPILER), aCC: HP ANSI C++ B3910B A.01.15)
+    CXXFLAGS_WITHOUT_O := $(filter-out -O% , $(CXXFLAGS))
+    CXXFLAGS_WITHOUT_O := $(filter-out +O% , $(CXXFLAGS_WITHOUT_O))  
+    tgt_$(ALICE_TARGET)/TG4PhysicsConstructorHadron.o : TG4PhysicsConstructorHadron.cxx
+      ifeq ($(CXXVERBOSE),)
+       @$(CXX) $(CXXFLAGS_WITHOUT_O) -c $*.cxx -o tgt_$(ALICE_TARGET)/$*.o
+      else
+       $(CXX) $(CXXFLAGS_WITHOUT_O) -c $*.cxx -o tgt_$(ALICE_TARGET)/$*.o
+      endif
+  endif    
+endif      
+
 
 ############################ Dependencies #####################################