Files
ThirdParty-common/etc/makeFiles/scotch/Makefile.inc.OpenFOAM-Linux.shlib
Mark Olesen 770e22bf51 ENH: update handling of compiler and flags
- support use of wmake -show-xyz, as well as older WM_CC, WM_CFLAGS etc.

- add support for Makefile.inc for scotch

- add -toolset= option for making boost and use b2 instead of legacy
  bjam for configuration
2019-04-25 10:46:44 +02:00

57 lines
1.4 KiB
Makefile

#-------------------------------*- makefile -*---------------------------------
#
# Prior to OpenFOAM-v1906, these were always part of the environment
#
# - WM_CFLAGS : with -m32 / -m64 and -fPIC
# - WM_LDFLAGS : with -m32 / -m64
#
# With OpenFOAM-v1906 and later
#
# - wmake -show-cflags : with -m32 / -m64
# - wmake -show-cflags-arch : with -m32 / -m64
#
# Pass these in via the enviroment since using '$(shell ...)' here does not
# always work well.
#
# Notes:
# - compiled without pthread
#
# Normally set CCS, CCP by caller
#------------------------------------------------------------------------------
EXE =
LIB = .so
OBJ = .o
AR = $(CC)
ARFLAGS = $(WM_CFLAGS) -shared -o
CCS ?= $(CC)
CCP ?= mpicc
CCD = $(CCP)
CFLAGS = $(WM_CFLAGS) -fPIC -O3 \
-DCOMMON_FILE_COMPRESS_GZ \
-DCOMMON_RANDOM_FIXED_SEED \
-DSCOTCH_DETERMINISTIC \
-DSCOTCH_RENAME \
-Drestrict=__restrict
# 32-bit vs. 64-bit labels
ifeq ($(WM_LABEL_SIZE),64)
CFLAGS += -DINTSIZE64
endif
CLIBFLAGS = -shared
LDFLAGS = -Xlinker --no-as-needed $(WM_LDFLAGS) -lz -lm -lrt
MAKE = make
CP = cp
CAT = cat
LN = ln
MKDIR = mkdir
MV = mv
RANLIB = echo
LEX = flex -Pscotchyy -olex.yy.c
YACC = bison -pscotchyy -y -b y
#------------------------------------------------------------------------------