Remove automake support

Since the cmake tool chain is now stable, the automake tool chain is removed from musrfit.
This makes documentation and code less cluttered.
This commit is contained in:
2019-03-08 12:50:41 +01:00
parent 64f73ffb11
commit dbfeeddf3f
55 changed files with 75 additions and 3713 deletions

View File

@ -1,261 +0,0 @@
#---------------------------------------------------
# Makefile.PMusr
#
# Author: Andreas Suter
# e-mail: andreas.suter@psi.ch
#
# $Id$
#
# Comment: If it doesn't work, try
# make --warning-undefined-variables -f Makefile.PMusr
# it might be that OSTYPE is not set properly, i.e.
# OSTYPE being a variable (set), instead of a enviornment
# variable (printenv). If so, try
# export OSTYPE=linux-gnu
# are whatever makes sense on your system.
#---------------------------------------------------
#---------------------------------------------------
# get compilation and library flags from root-config
ROOTCFLAGS = $(shell $(ROOTSYS)/bin/root-config --cflags)
ROOTLIBS = $(shell $(ROOTSYS)/bin/root-config --libs)
ROOTGLIBS = $(shell $(ROOTSYS)/bin/root-config --glibs)
#---------------------------------------------------
# depending on the architecture, choose the compiler,
# linker, and the flags to use
#
ARCH = $(shell $(ROOTSYS)/bin/root-config --arch)
ifeq ($(ARCH),linux)
OS = LINUX
endif
ifeq ($(ARCH),linuxx8664gcc)
OS = LINUX
endif
ifeq ($(ARCH),win32gcc)
OS = WIN32GCC
endif
ifeq ($(ARCH),macosx)
OS = DARWIN
endif
# -- Linux
ifeq ($(OS),LINUX)
CXX = g++
CXXFLAGS = -O3 -Wall -Wno-trigraphs -fPIC
PMUSRPATH = ../include
MNPATH = $(ROOTSYS)/include
GSLPATH = /usr/include/gsl
BOOSTPATH = /usr/include
FFTW3PATH = /usr/include
LEMPATH = ../external/TLemRunHeader
PSIBINPATH = ../external/MuSR_software/Class_MuSR_PSI
INCLUDES = -I$(PMUSRPATH) -I$(MNPATH) -I$(GSLPATH) -I$(BOOSTPATH) -I$(LEMPATH) -I$(PSIBINPATH) -I$(FFTW3PATH)
LD = g++
LDFLAGS = -O
SOFLAGS = -shared
LEMLIB = libTLemRunHeader.so
SHLIB = libPMusr.so
endif
# -- Windows/Cygwin
ifeq ($(OS),WIN32GCC)
CXX = g++
CXXFLAGS = -O3 -Wall -Wno-trigraphs -D_DLL
PMUSRPATH = ../include
MNPATH = $(ROOTSYS)/include
GSLPATH = /usr/include/gsl
BOOSTPATH = /usr/include
FFTW3PATH = /usr/include
LEMPATH = ../external/TLemRunHeader
PSIBINPATH = ../external/MuSR_software/Class_MuSR_PSI
INCLUDES = -I$(PMUSRPATH) -I$(MNPATH) -I$(GSLPATH) -I$(BOOSTPATH) -I$(LEMPATH) -I$(PSIBINPATH) -I$(FFTW3PATH)
LD = g++
LDFLAGS = -O -Wl,--enable-auto-import -Wl,--enable-runtime-pseudo-reloc
SOFLAGS = -shared -Wl,--export-all-symbols
LEMLIB = libTLemRunHeader.dll
SHLIB = libPMusr.dll
endif
# -- MacOSX/Darwin
ifeq ($(OS),DARWIN)
CXX = g++
CXXFLAGS = -O3 -Wall -Wno-trigraphs -fPIC
PMUSRPATH = ../include
MNPATH = $(ROOTSYS)/include
FINKPATH = /sw/include
GSLPATH = $(FINKPATH)/gsl
BOOSTPATH = $(FINKPATH)
FFTW3PATH = $(FINKPATH)
LEMPATH = ../external/TLemRunHeader
PSIBINPATH = ../external/MuSR_software/Class_MuSR_PSI
INCLUDES = -I$(PMUSRPATH) -I$(MNPATH) -I$(GSLPATH) -I$(BOOSTPATH) -I$(LEMPATH) -I$(PSIBINPATH) -I$(FFTW3PATH)
LD = g++
LDFLAGS = -O -Xlinker -bind_at_load
SOFLAGS = -dynamiclib -flat_namespace -undefined suppress -Wl,-x
LEMLIB = libTLemRunHeader.dylib
SHLIB = libPMusr.dylib
endif
# the output from the root-config script:
CXXFLAGS += $(ROOTCFLAGS)
LDFLAGS +=
# the ROOT libraries (G = graphic)
LIBS = $(ROOTLIBS) -lXMLParser
GLIBS = $(ROOTGLIBS) -lXMLParser
# LEM run header
PSILIB = -L. -lTLemRunHeader
# Minuit2 lib
MNLIB = -L$(ROOTSYS)/lib -lMinuit2
# GSL lib
GSLLIB = -lgslcblas -lgsl
# FFTW lib
FFTW3LIB = -lfftw3
ifeq ($(OS),WIN32GCC)
# Minuit2 lib
MNLIB = -L$(ROOTSYS)/lib -lMinuit2 -lMathMore
# GSL lib
GSLLIB = -L/usr/lib -lgslcblas -lgsl
# FFTW lib
FFTW3LIB = -L/usr/lib -lfftw3
endif
ifeq ($(OS),DARWIN)
# Minuit2 lib
MNLIB = -L$(ROOTSYS)/lib -lMinuit2 -lMathMore
# GSL lib
GSLLIB = -L/sw/lib -lgslcblas -lgsl
# FFTW lib
FFTW3LIB = -L/sw/lib -lfftw3
endif
# some definitions: headers (used to generate *Dict* stuff), sources, objects,...
OBJS =
OBJS += PStartupHandler.o PStartupHandlerDict.o
OBJS += PMsrHandler.o
OBJS += PRunDataHandler.o
OBJS += PFunctionHandler.o
OBJS += PFunction.o
OBJS += PRunBase.o
OBJS += PRunSingleHisto.o
OBJS += PRunAsymmetry.o
OBJS += PRunRRF.o
OBJS += PRunNonMusr.o
OBJS += PRunListCollection.o
OBJS += PTheory.o
OBJS += PFitterFcn.o
OBJS += PFitter.o
OBJS += PMusrCanvas.o PMusrCanvasDict.o
OBJS += PUserFcnBase.o PUserFcnBaseDict.o
OBJS += PFourier.o
OBJS += PMusrT0.o PMusrT0Dict.o
LEMOBJS =
LEMOBJS += TLemStats.o TLemStatsDict.o
LEMOBJS += TLemRunHeader.o TLemRunHeaderDict.o
EXTOBJS =
EXTOBJS += MuSR_td_PSI_bin.o
# make the shared libs:
all: lemlib musrlib
lemlib: $(LEMLIB)
musrlib: $(SHLIB)
$(LEMLIB): $(LEMOBJS)
@echo "---> Building shared library $(LEMLIB) ..."
/bin/rm -f $(LEMLIB)
$(LD) $(SOFLAGS) $(LDFLAGS) $(LEMOBJS) -o $(LEMLIB) $(LIBS)
@echo "done"
$(SHLIB): $(OBJS) $(EXTOBJS)
@echo "---> Building shared library $(SHLIB) ..."
/bin/rm -f $(SHLIB)
$(LD) $(SOFLAGS) $(LDFLAGS) $(OBJS) $(EXTOBJS) -o $(SHLIB) $(FFTW3LIB) $(GLIBS) $(PSILIB) $(MNLIB) $(GSLLIB)
@echo "done"
# clean up: remove all object file (and core files)
# semicolon needed to tell make there is no source
# for this target!
#
clean:; @rm -f $(OBJS) $(EXTOBJS) $(LEMOBJS) *Dict* core*
@echo "---> removing $(OBJS) $(EXTOBJS) $(LEMOBJS)"
#
$(OBJS): %.o: %.cpp
$(CXX) $(INCLUDES) $(CXXFLAGS) -c $<
$(LEMOBJS): ../external/TLemRunHeader/TLemRunHeader.cxx TLemRunHeaderDict.cxx ../external/TLemRunHeader/TLemStats.cxx TLemStatsDict.cxx
$(CXX) $(INCLUDES) $(CXXFLAGS) -c $^
$(EXTOBJS): ../external/MuSR_software/Class_MuSR_PSI/MuSR_td_PSI_bin.cpp
$(CXX) $(INCLUDES) $(CXXFLAGS) -c $^
TLemRunHeaderDict.cxx: ../external/TLemRunHeader/TLemRunHeader.h ../external/TLemRunHeader/TLemRunHeaderLinkDef.h
@echo "Generating dictionary $@..."
rootcling -f $@ -c -p $^
TLemStatsDict.cxx: ../external/TLemRunHeader/TLemStats.h ../external/TLemRunHeader/TLemStatsLinkDef.h
@echo "Generating dictionary $@..."
rootcling -f $@ -c -p $^
PStartupHandlerDict.cpp: ../include/PStartupHandler.h ../include/PStartupHandlerLinkDef.h
@echo "Generating dictionary $@..."
rootcling -f $@ -c -p $^
PMusrCanvasDict.cpp: ../include/PMusrCanvas.h ../include/PMusrCanvasLinkDef.h
@echo "Generating dictionary $@..."
rootcling -v -f $@ -c -p $^
PMusrT0Dict.cpp: ../include/PMusrT0.h ../include/PMusrT0LinkDef.h
@echo "Generating dictionary $@..."
rootcling -v -f $@ -c -p $^
PUserFcnBaseDict.cpp: ../include/PUserFcnBase.h ../include/PUserFcnBaseLinkDef.h
@echo "Generating dictionary $@..."
rootcling -v -f $@ -c -p $^
install: leminstall musrinstall
leminstall: lemlib
@echo "Installing shared lib: $(LEMLIB) ( you must be root ;-) )"
ifeq ($(OS),LINUX)
cp -pv $(LEMLIB) $(ROOTSYS)/lib
cp -pv $(LEMPATH)/*.h $(ROOTSYS)/include
endif
ifeq ($(OS),WIN32GCC)
cp -pv $(LEMLIB) $(ROOTSYS)/bin
ln -sf $(ROOTSYS)/bin/$(LEMLIB) $(ROOTSYS)/lib/$(LEMLIB)
cp -pv $(LEMPATH)/*.h $(ROOTSYS)/include
endif
ifeq ($(OS),DARWIN)
cp -pv $(LEMLIB) $(ROOTSYS)/lib
cp -pv $(LEMPATH)/*.h $(ROOTSYS)/include
endif
musrinstall: musrlib
@echo "Installing shared lib: $(SHLIB) ( you must be root ;-) )"
ifeq ($(OS),LINUX)
cp -pv $(SHLIB) $(ROOTSYS)/lib
cp -pv $(PMUSRPATH)/*.h $(ROOTSYS)/include
endif
ifeq ($(OS),WIN32GCC)
cp -pv $(SHLIB) $(ROOTSYS)/bin
ln -sf $(ROOTSYS)/bin/$(SHLIB) $(ROOTSYS)/lib/$(SHLIB)
cp -pv $(PMUSRPATH)/*.h $(ROOTSYS)/include
endif
ifeq ($(OS),DARWIN)
cp -pv $(SHLIB) $(ROOTSYS)/lib
cp -pv $(PMUSRPATH)/*.h $(ROOTSYS)/include
endif
cleaninstall: clean install

View File

@ -1,99 +0,0 @@
#---------------------------------------------------
# Makefile.PUserFcn
#
# Author: Andreas Suter
# e-mail: andreas.suter@psi.ch
#
# $Id$
#
#---------------------------------------------------
#---------------------------------------------------
# get compilation and library flags from root-config
ROOTCFLAGS = $(shell $(ROOTSYS)/bin/root-config --cflags)
ROOTLIBS = $(shell $(ROOTSYS)/bin/root-config --libs)
ROOTGLIBS = $(shell $(ROOTSYS)/bin/root-config --glibs)
#---------------------------------------------------
# depending on the architecture, choose the compiler,
# linker, and the flags to use
#
OSTYPE = $(shell uname)
ifeq ($(OSTYPE),Linux)
OS = LINUX
endif
ifeq ($(OSTYPE),Linux-gnu)
OS = LINUX
endif
ifeq ($(OSTYPE),darwin)
OS = DARWIN
endif
# -- Linux
ifeq ($(OS),LINUX)
CXX = g++
CXXFLAGS = -Wall -Wno-trigraphs -fPIC
INCLUDES = -I../include
LD = g++
LDFLAGS = -g
SOFLAGS = -O -shared
endif
# -- Darwin
ifeq ($(OS),DARWIN)
CXX = g++
CXXFLAGS = -Wall -Wno-trigraphs -fPIC
INCLUDES = -I../include
LD = g++
LDFLAGS = -g
SOFLAGS = -dynamic
endif
# the output from the root-config script:
CXXFLAGS += $(ROOTCFLAGS)
LDFLAGS +=
# the ROOT libraries (G = graphic)
LIBS = $(ROOTLIBS) -lXMLParser
GLIBS = $(ROOTGLIBS) -lXMLParser
# some definitions: headers (used to generate *Dict* stuff), sources, objects,...
OBJS =
OBJS += PUserFcn.o PUserFcnDict.o
SHLIB = libPUserFcn.so
# make the shared lib:
#
all: $(SHLIB)
$(SHLIB): $(OBJS)
@echo "---> Building shared library $(SHLIB) ..."
/bin/rm -f $(SHLIB)
$(LD) $(OBJS) $(SOFLAGS) -o $(SHLIB) $(LIBS)
@echo "done"
# clean up: remove all object file (and core files)
# semicolon needed to tell make there is no source
# for this target!
#
clean:; @rm -f $(OBJS) *Dict* core*
@echo "---> removing $(OBJS)"
#
$(OBJS): %.o: %.cpp
$(CXX) $(INCLUDES) $(CXXFLAGS) -c $<
PUserFcnDict.cpp: ../include/PUserFcn.h ../include/PUserFcnLinkDef.h
@echo "Generating dictionary $@..."
rootcling -f $@ -c -p $^
install: all
@echo "Installing shared lib: libPUserFcn.so ( you must be root ;-) )"
ifeq ($(OS),LINUX)
cp -pv $(SHLIB) $(ROOTSYS)/lib
cp -pv ../include/PUserFcn.h $(ROOTSYS)/include
endif

View File

@ -1,120 +0,0 @@
## Process this file with automake to create Makefile.in
h_sources = \
../include/PFitterFcn.h \
../include/PFitter.h \
../include/PFourier.h \
../include/PFourierCanvas.h \
../include/PFunctionGrammar.h \
../include/PFunction.h \
../include/PFunctionHandler.h \
../include/PMsr2Data.h \
../include/PMsrHandler.h \
../include/PMusrCanvas.h \
../include/PMusr.h \
../include/PMusrT0.h \
../include/PPrepFourier.h \
../include/PRunAsymmetry.h \
../include/PRunAsymmetryRRF.h \
../include/PRunBase.h \
../include/PRunDataHandler.h \
../include/PRunListCollection.h \
../include/PRunNonMusr.h \
../include/PRunMuMinus.h \
../include/PRunSingleHisto.h \
../include/PRunSingleHistoRRF.h \
../include/PStartupHandler.h \
../include/PTheory.h
h_sources_userFcn = \
../include/PUserFcnBase.h
h_linkdef = \
../include/PFourierCanvasLinkDef.h \
../include/PMusrCanvasLinkDef.h \
../include/PMusrT0LinkDef.h \
../include/PStartupHandlerLinkDef.h
h_linkdef_userFcn = \
../include/PUserFcnBaseLinkDef.h
dict_h_sources = \
PFourierCanvasDict.h \
PMusrCanvasDict.h \
PMusrT0Dict.h \
PStartupHandlerDict.h
dict_h_sources_userFcn = \
PUserFcnBaseDict.h
cpp_sources = \
PFitter.cpp \
PFitterFcn.cpp \
PFourier.cpp \
PFourierCanvas.cpp \
PFunction.cpp \
PFunctionHandler.cpp \
PMsr2Data.cpp \
PMsrHandler.cpp \
PMusrCanvas.cpp \
PMusr.cpp \
PMusrT0.cpp \
PPrepFourier.cpp \
PRunAsymmetry.cpp \
PRunAsymmetryRRF.cpp \
PRunBase.cpp \
PRunDataHandler.cpp \
PRunListCollection.cpp \
PRunNonMusr.cpp \
PRunMuMinus.cpp \
PRunSingleHisto.cpp \
PRunSingleHistoRRF.cpp \
PStartupHandler.cpp \
PTheory.cpp
cpp_sources_userFcn = \
PUserFcnBase.cpp
dict_cpp_sources = \
PFourierCanvasDict.cpp \
PMusrCanvasDict.cpp \
PMusrT0Dict.cpp \
PStartupHandlerDict.cpp
dict_cpp_sources_userFcn = \
PUserFcnBaseDict.cpp
pcmdir = $(libdir)
pcm_DATA = \
PFourierCanvasDict_rdict.pcm \
PMusrCanvasDict_rdict.pcm \
PMusrT0Dict_rdict.pcm \
PStartupHandlerDict_rdict.pcm \
PUserFcnBaseDict_rdict.pcm
include_HEADERS = $(h_sources) $(h_sources_userFcn)
noinst_HEADERS = $(h_linkdef) $(dict_h_sources) $(h_linkdef_userFcn) $(dict_h_sources_userFcn)
AM_CPPFLAGS = -I$(top_srcdir)/src/include $(MUSR_ROOT_CFLAGS) $(PSIBIN_CFLAGS) $(MUD_CFLAGS) $(LEM_CFLAGS) $(FFTW3_CFLAGS) $(GSL_CFLAGS) $(BOOST_CFLAGS) -I$(ROOTINCDIR) $(PNEXUS_CXXFLAGS) $(NEXUS_CFLAGS)
AM_CXXFLAGS = $(LOCAL_LIB_CXXFLAGS)
BUILT_SOURCES = $(dict_cpp_sources) $(dict_h_sources) $(dict_cpp_sources_userFcn) $(dict_h_sources_userFcn)
AM_LDFLAGS = $(LOCAL_LIB_LDFLAGS) -L@ROOTLIBDIR@
CLEANFILES = *Dict.cpp *Dict.h *Dict* *~ core
%Dict.cpp %Dict.h: ../include/%.h ../include/%LinkDef.h
@ROOTCLING@ -v -f $*Dict.cpp -c -p $(AM_CPPFLAGS) $^
lib_LTLIBRARIES = libPUserFcnBase.la libPMusr.la
libPUserFcnBase_la_SOURCES = $(h_sources_userFcn) $(cpp_sources_userFcn) $(dict_h_sources_userFcn) $(dict_cpp_sources_userFcn)
libPUserFcnBase_la_LIBADD = $(ROOT_LIBS)
libPUserFcnBase_la_LDFLAGS = -version-info $(MUSR_LIBRARY_VERSION) -release $(MUSR_RELEASE) $(AM_LDFLAGS)
libPMusr_la_SOURCES = $(h_sources) $(cpp_sources) $(dict_h_sources) $(dict_cpp_sources)
libPMusr_la_LIBADD = libPUserFcnBase.la $(MUSR_ROOT_LIBS) $(LEM_LIBS) $(PSIBIN_LIBS) $(MUD_LIBS) $(PNEXUS_LIBS) $(FFTW3_LIBS) $(GSL_LIBS) $(ROOT_LIBS)
libPMusr_la_LDFLAGS = -version-info $(MUSR_LIBRARY_VERSION) -release $(MUSR_RELEASE) $(AM_LDFLAGS)
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = PUserFcnBase.pc PMusr.pc