[1199] | 1 | # $Id: GNUmakefile,v 1.1 2006/07/14 14:42:37 asaim Exp $ |
---|
| 2 | # -------------------------------------------------------------- |
---|
| 3 | # GNUmakefile for examples module |
---|
| 4 | # -------------------------------------------------------------- |
---|
| 5 | |
---|
| 6 | name := ParaTest |
---|
| 7 | G4TARGET := $(name) |
---|
| 8 | G4EXLIB := true |
---|
| 9 | |
---|
| 10 | ifndef G4INSTALL |
---|
| 11 | G4INSTALL = ../../../../.. |
---|
| 12 | endif |
---|
| 13 | |
---|
| 14 | .PHONY: all |
---|
| 15 | all: lib bin |
---|
| 16 | |
---|
| 17 | # A01PhysicsList use hadronic-lists, so it needs below include command. |
---|
| 18 | #include hadlist.gmk |
---|
| 19 | |
---|
| 20 | include $(G4INSTALL)/config/binmake.gmk |
---|
| 21 | |
---|
| 22 | CXXFLAGS_WITHOUT_O := $(filter-out -O% , $(CXXFLAGS)) |
---|
| 23 | CXXFLAGS_WITHOUT_O := $(filter-out +O% , $(CXXFLAGS_WITHOUT_O)) |
---|
| 24 | |
---|
| 25 | # |
---|
| 26 | # A01HadronPhysics fails to compile in optimized mode on Linux, Darwin, using g++ |
---|
| 27 | # so it needs this special rule. Hans-Peter Wellish. |
---|
| 28 | # |
---|
| 29 | ifeq ($(G4SYSTEM),Linux-g++) |
---|
| 30 | A01HADRON_NO_OPTIMIZE = 1 |
---|
| 31 | endif |
---|
| 32 | ifeq ($(G4SYSTEM),Linux-g++2) |
---|
| 33 | A01HADRON_NO_OPTIMIZE = 1 |
---|
| 34 | endif |
---|
| 35 | ifeq ($(G4SYSTEM),Linux-g++3) |
---|
| 36 | A01HADRON_NO_OPTIMIZE = 1 |
---|
| 37 | endif |
---|
| 38 | ifeq ($(G4SYSTEM),Darwin-g++) |
---|
| 39 | A01HADRON_NO_OPTIMIZE = 1 |
---|
| 40 | endif |
---|
| 41 | ifeq ($(G4SYSTEM),Darwin-g++2) |
---|
| 42 | A01HADRON_NO_OPTIMIZE = 1 |
---|
| 43 | endif |
---|
| 44 | ifeq ($(G4SYSTEM),Darwin-g++3) |
---|
| 45 | A01HADRON_NO_OPTIMIZE = 1 |
---|
| 46 | endif |
---|
| 47 | |
---|
| 48 | ifdef A01HADRON_NO_OPTIMIZE |
---|
| 49 | $(G4TMP)/$(G4SYSTEM)/$(name)/A01HadronPhysics.o: src/A01HadronPhysics.cc |
---|
| 50 | @echo "Compiling A01HadronPhysics.cc without optimization..." |
---|
| 51 | @$(CXX) $(CXXFLAGS_WITHOUT_O) $(CPPFLAGS) -c $(OUT_OBJ)$@ src/A01HadronPhysics.cc |
---|
| 52 | endif |
---|
| 53 | |
---|