]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - HLT/TPCLib/Makefile.am
enhanced HLT build system: EINCLUDE from pkg definition determines include paths
[u/mrichter/AliRoot.git] / HLT / TPCLib / Makefile.am
index b0981399b54a5110993cca8cb57781cf98fd4305..1f523787cff09d7442da33b29811dbf000b70aa8 100644 (file)
@@ -3,11 +3,7 @@
 
 MODULE                                 = AliHLTTPC
 
-EXTRA_DIST                     = AliHLTTPCLinkDef.h
-
-AM_CPPFLAGS                    = @ALIROOT_CPPFLAGS@         \
-                                 -I$(top_srcdir)/BASE       \
-                                 -I$(top_srcdir)/BASE/util
+EXTRA_DIST                     = 
 
 # generation of the TPC Pad mapping tables for the 
 # AliHLTTPCDigitReaderRaw reader
@@ -27,15 +23,22 @@ endif
 lib_LTLIBRARIES                        =  libAliHLTTPC.la
 
 # version info for the library
-LIBRARY_VERSION                        = '3:0:0'
+LIBRARY_VERSION                        = '4:0:1'
 
 # MODDIR is set by the AliRoot build system and denotes the topdir
 # of the module, we must set it since the package definition libAliHLTTPC.pkg
 # includes another common configuration file
 MODDIR                         = $(top_srcdir)
-PKGDEF                         = $(MODDIR)/libHLTbase.pkg
+PKGDEF                         = $(MODDIR)/libAliHLTTPC.pkg
 include $(top_srcdir)/libAliHLTTPC.pkg
 
+# compiler flags
+AM_CPPFLAGS                    = -DMODULE=$(MODULE) \
+                                 $(foreach i, $(EINCLUDE),  \
+                                       $(shell echo $(i) | sed -e "/HLT\//!d" -e "s|HLT/|-I$(top_srcdir)/|")) \
+                                 $(foreach i, $(EINCLUDE),  \
+                                       $(shell echo $(i) | sed -e "/HLT\//d" -e "s|^|-I$(ALICE_ROOT)/|"))
+
 # library sources
 libAliHLTTPC_la_SOURCES                = $(MODULE_SRCS)
 
@@ -50,12 +53,17 @@ libAliHLTTPC_la_LDFLAGS             = -L@ROOTLIBDIR@ \
                                  @ALIROOT_LIBS@ \
                                  -version-info  $(LIBRARY_VERSION)
 
+# automatic generation of data and time of library build
+COMPILE_INFO                   =  AliHLTTPCCompileInfo.cxx
+
 # set the file name for the generated root dictionary
 DICTCPP                                =  AliHLTTPC-DICT.cxx
-nodist_libAliHLTTPC_la_SOURCES  =  $(DICTCPP)
+nodist_libAliHLTTPC_la_SOURCES  =  $(COMPILE_INFO) \
+                                  $(DICTCPP)
 
 BUILT_SOURCES                  = $(TPC_MAPPING_INC)
-CLEANFILES                     = $(BUILT_SOURCES)
+CLEANFILES                     = $(COMPILE_INFO) \
+                                 $(BUILT_SOURCES)
 
 include $(top_srcdir)/make.dict
 
@@ -63,3 +71,10 @@ SUBDIRS                      = . OnlineDisplay
 
 $(TPC_MAPPING_INC): $(TPC_MAPPING_NOINST_PGM)
        ./$<
+
+$(COMPILE_INFO): $(libAliHLTTPC_la_SOURCES) $(pkginclude_HEADERS) $(noinst_HEADERS) Makefile.am
+       @echo '//automatically generated compilation info' > $@
+       @echo '//!!! DO NOT EDIT THIS FILE !!!' >> $@
+       @echo '//add changes in Makefile.am' >> $@
+       @echo 'extern "C" void CompileInfo( char*& date, char*& time)' >> $@
+       @echo '{date=__DATE__; time=__TIME__; return;}' >> $@