1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91
|
#-------------------------------------------------------------------------------
# (C) Altran Praxis Limited
#===============================================================================
################################################################################
# PURPOSE
#-------------------------------------------------------------------------------
# Makefile for Victor
# For Linux, Windows, Solaris or Mac OS X (aka Darwin).
################################################################################
################################################################################
# BUILD CONFIGURATION
################################################################################
OUTPUT_NAME:=vct
ALT_ERGO:=alt-ergo
VICTOR:=vct
# Location of root.
ROOT:=..
# Location of common.
COMMON:=${ROOT}/common
include ${COMMON}/Makefile.inc
################################################################################
# PLATFORM SPECIFIC CONFIGURATION
################################################################################
# Windows.
ifeq (${TARGET},Windows)
ifeq (${GCC_TARGET},i686-pc-mingw32)
# on windows, let the compiler know the gmplib location
CPPFLAGS="-I /gmp/include"
LDFLAGS="-L /gmp/lib"
endif
endif
################################################################################
# TARGETS
################################################################################
ALT_ERGO_DIR=$(shell ${TAR} ztf ${ALT_ERGO}-*.tar.gz | head -1)
# Target to build vct and alt-ergo
ifeq (${BUILD_VICTOR},true)
all: ${VICTOR}-target
else
all:
endif
${VICTOR}-target:
# Don't build Victor in parallel (-j). Missing dependencies in the Makefile.
ifeq (${TARGET},Darwin)
$(MAKE) -C ${VICTOR}/src CPPFLAGS=${CPPFLAGS} LDFLAGS=${LDFLAGS} STATIC_GMP_MAC=1
else
$(MAKE) -C ${VICTOR}/src CPPFLAGS=${CPPFLAGS} LDFLAGS=${LDFLAGS}
endif
${ALT_ERGO}-target: ${ALT_ERGO}
ifeq (${GCC_TARGET},i686-pc-mingw32)
# on windows we mimick the build by copying the mingw binary provided
# by the Alt-Ergo team to where a source built binary would have
# appeared
cp alt-ergo-*-mingw.exe ${ALT_ERGO}/alt-ergo.opt
else
# by default, we build Alt-Ergo from the sources
# Don't build Alt-Ergo in parallel (-j). Missing dependencies in the Makefile.
cd ${ALT_ERGO} && ./configure
$(MAKE) -C ${ALT_ERGO}
endif
${ALT_ERGO}:
${TAR} zxvf ${ALT_ERGO}-*.tar.gz
mv ${ALT_ERGO_DIR} ${ALT_ERGO}
# Cleaning code base
# ==================
clean:
rm -Rf ${ALT_ERGO}
-$(MAKE) -C ${VICTOR}/src clean
rm -f ${VICTOR}/bin/${OUTPUT_NAME}${EXE_EXTN}
reallyclean: clean
################################################################################
# END-OF-FILE
|