Cleanup
[u/mrichter/AliRoot.git] / build / Makefile.linux
CommitLineData
b934f194 1# Makefile to build AliRoot for Linux
2
02a1d5c1 3# The compilers
4CXX = g++
5F77 = g77
6CC = gcc
7CCMAJORV = $(shell $(CC) -dumpversion | cut -d. -f1)
19ca05d1 8CCMINORV = $(shell $(CC) -dumpversion | cut -d. -f2)
02a1d5c1 9
10# Global optimisation
11OPT = -O -g
19ca05d1 12NOOPT = -g
02a1d5c1 13
19ca05d1 14CXXOPT = $(OPT)
15CXXNOOPT = $(NOOPT)
02a1d5c1 16COPT = $(OPT)
19ca05d1 17FOPT = $(OPT)
02a1d5c1 18
19# CERNLIB defines
02a1d5c1 20CLIBDEFS = -DCERNLIB_LINUX -DCERNLIB_BLDLIB -DCERNLIB_CZ
21CLIBCXXOPTS =
22CLIBCOPT =
19ca05d1 23CLIBFOPT = $(CLIBDEFS)
24
25# Compiler flags
26ifeq ($(CCMAJORV),2)
27CXXFLAGS = $(OPT) -W -Wall -fPIC -pipe
28CXXFLAGSNO = $(NOOPT) -W -Wall -fPIC -pipe
29else
bdfb9593 30CXXFLAGS = $(OPT) -W -Wall -Werror -fPIC -pipe -fmessage-length=0 -Wno-long-long -pedantic-errors -ansi -Dlinux
19ca05d1 31CXXFLAGSNO = $(NOOPT) -W -Wall -Werror -fPIC -pipe -fmessage-length=0 -Wno-long-long -pedantic-errors -ansi
32endif
33CFLAGS = $(OPT) -Wall -Werror -fPIC -pipe -Wno-long-long -pedantic-errors -ansi
34FFLAGS = $(CLIBFOPT) $(FOPT) -fno-second-underscore
35# rmkdepend flags for building dependencies of FORTRAN files
36DEPENDFFLAGS = $(FFLAGS)
37
38# rootcint flags
39CINTFLAGS =
02a1d5c1 40
02a1d5c1 41LD = g++
42LDFLAGS = $(OPT)
43
44SHLD = $(LD)
45SOFLAGS = $(OPT) -shared -Wl
46SHLIB = -lg2c
47SOEXT = so
48
49ALLD = ar
50ALFLAGS = cr
51ALLIB =
52AEXT = a
53
54# additional ROOT libraries
55ROOTLIBS += -lcrypt
56
02a1d5c1 57LIBNOVER = `find /lib -name 'libNoVersion*.so' | xargs --replace basename {} .so | sed -e 's/lib/ -l/'`
58GLIBS = -L/usr/X11R6/lib -lX11 $(LIBNOVER)
59
60#System libraries
61SYSLIBS = -ldl
62
63EXEFLAGS+= -lg2c
64
65
66
67