# Makefile to build AliRoot for Linux # The compilers CXX = g++ F77 = g77 CC = gcc CCMAJORV = $(shell $(CC) -dumpversion | cut -d. -f1) CCMINORV = $(shell $(CC) -dumpversion | cut -d. -f2) # Global optimisation OPT = -O -g NOOPT = -g CXXOPT = $(OPT) CXXNOOPT = $(NOOPT) COPT = $(OPT) FOPT = $(OPT) # CERNLIB defines CLIBDEFS = -DCERNLIB_LINUX -DCERNLIB_BLDLIB -DCERNLIB_CZ CLIBCXXOPTS = CLIBCOPT = CLIBFOPT = $(CLIBDEFS) # Compiler flags ifeq ($(CCMAJORV),2) CXXFLAGS = $(OPT) -W -Wall -fPIC -pipe CXXFLAGSNO = $(NOOPT) -W -Wall -fPIC -pipe else CXXFLAGS = $(OPT) -W -Wall -Woverloaded-virtual -fPIC -pipe -fmessage-length=0 -Wno-long-long -pedantic-errors -ansi -Dlinux CXXFLAGSNO = $(NOOPT) -W -Wall -Werror -fPIC -pipe -fmessage-length=0 -Wno-long-long -pedantic-errors -ansi endif CFLAGS = $(OPT) -Wall -Werror -fPIC -pipe -Wno-long-long -pedantic-errors -ansi FFLAGS = $(CLIBFOPT) $(FOPT) -fno-second-underscore # rmkdepend flags for building dependencies of FORTRAN files DEPENDFFLAGS = $(FFLAGS) # rootcint flags CINTFLAGS = LD = g++ LDFLAGS = $(OPT) SHLD = $(LD) SOFLAGS = $(OPT) -shared -Wl SHLIB = -lg2c SOEXT = so ALLD = ar ALFLAGS = cr ALLIB = AEXT = a # additional ROOT libraries LIBNOVER = `find /lib -name 'libNoVersion*.so' | xargs --replace basename {} .so | sed -e 's/lib/ -l/'` #System libraries SYSLIBS := -ldl -lg2c -lcrypt -L/usr/X11R6/lib -lX11 $(LIBNOVER)