-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.mak
73 lines (57 loc) · 2.79 KB
/
config.mak
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
#
# config.mak.dist - sample musl-cross-make configuration
#
# Copy to config.mak and edit as desired.
#
# There is no default TARGET; you must select one here or on the make
# command line. Some examples:
# TARGET = i486-linux-musl
# TARGET = x86_64-linux-musl
# TARGET = arm-linux-musleabi
TARGET = arm-linux-musleabihf
# TARGET = sh2eb-linux-muslfdpic
# ...
# By default, cross compilers are installed to ./output under the top-level
# musl-cross-make directory and can later be moved wherever you want them.
# To install directly to a specific location, set it here. Multiple targets
# can safely be installed in the same location. Some examples:
# OUTPUT = /opt/cross
# OUTPUT = /usr/local
# By default, latest supported release versions of musl and the toolchain
# components are used. You can override those here, but the version selected
# must be supported (under hashes/ and patches/) to work. For musl, you
# can use "git-refname" (e.g. git-master) instead of a release. Setting a
# blank version for gmp, mpc, mpfr and isl will suppress download and
# in-tree build of these libraries and instead depend on pre-installed
# libraries when available (isl is optional and not set by default).
# Setting a blank version for linux will suppress installation of kernel
# headers, which are not needed unless compiling programs that use them.
# BINUTILS_VER = 2.25.1
# GCC_VER = 5.2.0
# MUSL_VER = git-master
# GMP_VER =
# MPC_VER =
# MPFR_VER =
# ISL_VER =
# LINUX_VER =
# By default source archives are downloaded with wget. curl is also an option.
# DL_CMD = wget -c -O
# DL_CMD = curl -C - -L -o
# Something like the following can be used to produce a static-linked
# toolchain that's deployable to any system with matching arch, using
# an existing musl-targeted cross compiler. This only works if the
# system you build on can natively (or via binfmt_misc and qemu) run
# binaries produced by the existing toolchain (in this example, i486).
# COMMON_CONFIG += CC="i486-linux-musl-gcc -static --static" CXX="i486-linux-musl-g++ -static --static"
# Recommended options for smaller build for deploying binaries:
COMMON_CONFIG += CFLAGS="-g0 -Os " CXXFLAGS="-g0 -Os" LDFLAGS="-s"
# COMMON_CONFIG += CFLAGS="-g0 -Os -march=armv7ve -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7" CXXFLAGS="-g0 -Os -march=armv7ve -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7" LDFLAGS="-s -wl"
# Recommended options for faster/simpler build:
COMMON_CONFIG += --disable-nls
GCC_CONFIG += --enable-languages=c,c++
GCC_CONFIG += --disable-libquadmath --disable-decimal-float
GCC_CONFIG += --disable-multilib
# You can keep the local build path out of your toolchain binaries and
# target libraries with the following, but then gdb needs to be told
# where to look for source files.
# COMMON_CONFIG += --with-debug-prefix-map=$(CURDIR)=