-SRCS = \
-TFluka.cxx AliFluka.cxx
+# Sources
+SRCS:= TFluka.cxx AliFluka.cxx \
+ source.cxx
+FSRCS:= FLUKA_input.f
+
+# Headers
+HDRS:= $(filter-out source.h,$(SRCS:.cxx=.h) )
+
+# ROOT Dictionary
+DHDR:= TFlukaLinkDef.h
+
+# Extra includes and libraries
+EINCLUDE:= Flugg geant4_vmc/include $(G4INSTALL)/include $(CLHEP_BASE_DIR)/include
+ELIBSDIR:= $(FLUPRO)
+ELIBS := flukahp
+
+######################
+#Handle Geant4 flags
+######################
+
+# If G4DEBUG or G4NO_OPTIMISE are not specified,
+# the default compilation is optimised ...
+#
+ifdef G4DEBUG
+ CXXFLAGS += -DG4DEBUG
+else
+ ifndef G4NO_OPTIMISE
+ CXXFLAGS += -DG4OPTIMISE
+ endif
+endif
+# Verbosity code can be left out (for better performance)
+# by defining G4_NO_VERBOSE.
+#
+ifndef G4_NO_VERBOSE
+ CXXFLAGS += -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
+
+CXXFLAGS += -DGNU_GCC -DG4USE_STL -DG4USE_STD_NAMESPACE
+
-HDRS:= $(SRCS:.cxx=.h)
-DHDR= TFlukaLinkDef.h