introduce platform dependent Makefiles using names as provided by
[u/mrichter/AliRoot.git] / build / Makefile.linuxicc
CommitLineData
02a1d5c1 1PLATFORM:=linuxicc
2
3# The C/C++ compilers
4CXX = icc
5CC = icc
6
7# Compiler version:
8ICC_MAJOR := $(shell $(CXX) -V 2>&1 | awk '{ if (NR==1) print $$8 }' | \
9 cut -d'.' -f1)
10ICC_MINOR := $(shell $(CXX) -V 2>&1 | awk '{ if (NR==1) print $$8 }' | \
11 cut -d'.' -f2)
12
13# The Fortran compiler
14ifeq ($(ICC_MAJOR),8)
15F77 = ifort
16else
17F77 = ifc
18endif
19
20# Global optimisation
21OPT = -O -g
22
23CXXOPTS = $(OPT)
24COPT = $(OPT)
25FOPT = $(OPT)
26CXXFLAGS = $(CXXOPTS)
27CFLAGS = $(COPT)
28
29# rootcint flags
30CINTFLAGS =
31
32# CERNLIB defines
33
34CLIBDEFS = -DCERNLIB_LINUX -DCERNLIB_BLDLIB -DCERNLIB_CZ
35CLIBCXXOPTS =
36CLIBCOPT =
37CLIBFOPT =
38
39# Common Fortran compilation flags
40FFLAGS = $(CLIBFOPT) $(CLIBDEFS) $(FOPT)
41
42LD = icc
43LDFLAGS = $(OPT)
44
45SHLD = $(LD)
46SOFLAGS = -Wl,-soname,$$TMPLIB -shared $(OPT)
47SHLIB =
48SOEXT = so
49
50ALLD = ar
51ALFLAGS = cr
52ALLIB =
53AEXT = a
54
55# additional ROOT libraries
56ROOTLIBS += -lcrypt
57
58# rmkdepend flags for building dependencies of FORTRAN files
59DEPENDFFLAGS = $(FFLAGS)
60
61LIBNOVER = `find /lib -name 'libNoVersion*.so' | xargs --replace basename {} .so | sed -e 's/lib/ -l/'`
62GLIBS = $(LIBNOVER)
63
64#System libraries
65SYSLIBS =
66
67EXEFLAGS += -L/usr/local/lib -lXt
68ifeq ($(ICC_MAJOR),8)
69EXEFLAGS += -L$(shell which ifort | sed -e 's|bin/ifort|lib|') \
70 -lifcore
71else
72EXEFLAGS += -L$(shell which ifc | sed -e 's|bin/ifc|lib|') \
73 -lF90 -lCEPCF90 -lintrins
74endif