aboutsummaryrefslogtreecommitdiff
path: root/config.mk.dist
blob: a923d7dde08f560e7626dd888ebed954dc5e16e1 (plain)
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
# Example config.mk
#
# Copyright (c) 2018, Arm Limited.
# SPDX-License-Identifier: MIT

HOST_CC = gcc
HOST_CFLAGS = -std=c99 -O2
HOST_CFLAGS += -Wall -Wno-unused-function

CC = $(CROSS_COMPILE)gcc
CFLAGS = -std=c99 -pipe -O3
CFLAGS += -Wall -Wno-missing-braces
CFLAGS += -Werror=implicit-function-declaration

# Enable debug info.
HOST_CFLAGS += -g
CFLAGS += -g

# Optimize the shared libraries on aarch64 assuming they fit in 1M.
#CFLAGS_SHARED = -fPIC -mcmodel=tiny

# Use if mpfr is available on the target for ulp error checking.
#LDLIBS += -lmpfr -lgmp
#CFLAGS += -DUSE_MPFR

# Use with gcc.
CFLAGS += -frounding-math -fexcess-precision=standard -fno-stack-protector
CFLAGS += -ffp-contract=fast -fno-math-errno

# Use with clang.
#CFLAGS += -ffp-contract=fast

# Additional CFLAGS for subprojects.
#math-cflags =
#string-cflags =

# Disable fenv checks
#ULPFLAGS = -q -f
#MATHTESTFLAGS = -nostatus

# Use for cross compilation with gcc.
#CROSS_COMPILE = aarch64-none-linux-gnu-

# Use with cross testing.
#EMULATOR = qemu-aarch64-static
#EMULATOR = sh -c 'scp $$1 user@host:/dir && ssh user@host /dir/"$$@"' --