]> git.uio.no Git - u/mrichter/AliRoot.git/blame - build/Makefile.macosx64
Added event-mixing management in buffer and some new functions, plus some corrections...
[u/mrichter/AliRoot.git] / build / Makefile.macosx64
CommitLineData
d95a3ef8 1# -*- mode: makefile -*-
f36e7e21 2# Makefile for AliRoot for MacOS X with gcc
ee0345bd 3
4XARGS = xargs
5
6# OS version
7MACOSX_MAJOR := $(strip $(shell sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 1))
8MACOSX_MINOR := $(strip $(shell sw_vers | sed -n 's/ProductVersion://p' | cut -d . -f 2))
9
10# fink directories
11FINK_ROOT := $(shell which fink | sed -e 's?/bin/fink??')
12ifeq (,$(FINK_ROOT))
13# No fink, build will probably fail, but we try a guess
14FINK_ROOT=/usr/local
15endif
16
17# The compilers
18CXX = g++
19CC = gcc
d95a3ef8 20F77 = $(shell root-config --f77)
ee0345bd 21
22# Global optimisation
23OPT = -O -g
24NOOPT = -O0 -g
25
26CXXOPT = $(OPT)
27CXXNOOPT = $(NOOPT)
28COPT = $(OPT)
f36e7e21 29FOPT = $(OPT) -fno-second-underscore -m64
d95a3ef8 30ifeq (g95,$(F77))
ee0345bd 31FOPT += -fbounds-check
32endif
33
34# CERNLIB defines
cb47c659 35CLIBDEFS = -DCERNLIB_LXIA64 -DCERNLIB_BLDLIB -DCERNLIB_CZ -DCERNLIB_PPC
ee0345bd 36CLIBCXXOPTS =
37CLIBCOPT =
38CLIBFOPT = $(CLIBDEFS)
39
8ac4fa64 40CXXSTF = -m64 -pipe -Wall -W -Wno-long-double -pipe -fbounds-check -fsigned-char -fno-common -fmessage-length=0 -Woverloaded-virtual -Weffc++ -Wconversion -Wshadow -fno-default-inline -fno-inline -I/usr/X11R6/include -I$(FINK_ROOT)/include
ee0345bd 41
42# Compiler flags
1bbe2977 43CXXFLAGS = $(CXXOPT) $(CXXSTF)
ee0345bd 44
ee0345bd 45CXXFLAGSNO = $(CXXNOOPT) $(CXXSTF)
46
47CFLAGS = $(COPT) -m64 -Wall -W -fno-common -pipe -I$(FINK_ROOT)/include
48
f36e7e21 49FFLAGS = $(CLIBFOPT) $(FOPT)
d95a3ef8 50ifeq (g95,$(F77))
ee0345bd 51FFLAGS += -ftrace=full
7da87db6 52FFLAGS +=-DFORTRAN_G95
53else
54FFLAGS +=-DFORTRAN_GFORTRAN
ee0345bd 55endif
7da87db6 56
ee0345bd 57# rmkdepend flags for building dependencies of FORTRAN files
58DEPENDFFLAGS = $(FFLAGS)
59
60# rootcint flags
61CINTFLAGS =
62
63LD = export MACOSX_DEPLOYMENT_TARGET=$(MACOSX_MAJOR).$(MACOSX_MINOR) ; \
64 unset LD_PREBIND ; \
65 g++
f36e7e21 66LDFLAGS = $(OPT) -m64 $(DICTLOAD)
ee0345bd 67
68SHLD := $(LD)
69SOFLAGS := -m64 -bundle -undefined dynamic_lookup
70SHLIB :=
71SOEXT := so
72
73DYLD := $(LD)
74DYFLAGS = -m64 -dynamiclib -undefined dynamic_lookup -single_module
75DYLIB :=
76DYEXT := dylib
77
78ALLD = ar
79ALFLAGS = cr
80ALLIB =
81AEXT = a
82
83DEPENDCXXFLAGS = $(CXXFLAGS) -I/usr/include/sys
84
85SYSLIBS := -L/usr/X11R6/lib -lX11
86
87EXEFLAGS := -bind_at_load
88
89#System libraries
90
d95a3ef8 91ifeq (g95,$(F77))
ee0345bd 92SYSLIBS += -L$(shell g95 --print-search-dirs | sed -n -e 's/install: //p') -lf95
93else
1bbe2977 94SYSLIBS += -ldl $(shell $(F77) -m64 -print-file-name=libgfortran.dylib)
95SYSLIBS += $(shell $(F77) -m64 -print-file-name=libgfortranbegin.a)
ee0345bd 96endif