blob: fdc1ad0d1a6ce549f55cf2b5626b9c5003727b10 [file] [log] [blame]
Eric Andersen2d523c22004-10-09 01:06:03 +00001#
2
Peter Korsgaard6a53b722011-02-02 14:53:23 +01003mainmenu "Buildroot $BR2_VERSION Configuration"
Eric Andersen2d523c22004-10-09 01:06:03 +00004
5config BR2_HAVE_DOT_CONFIG
6 bool
7 default y
8
Bernhard Reutner-Fischerf5b8cd42007-09-25 11:37:31 +00009config BR2_VERSION
10 string
Yann E. MORIN56c68bc2010-10-31 17:35:14 +010011 option env="BR2_VERSION_FULL"
Bernhard Reutner-Fischerf5b8cd42007-09-25 11:37:31 +000012
Francois Perrad1d4104f2012-07-18 15:59:09 +020013config BR2_HOSTARCH
14 string
15 option env="HOSTARCH"
16
Thomas Petazzonia4239f72013-12-05 20:11:10 +010017config BR2_EXTERNAL
18 string
19 option env="BR2_EXTERNAL"
20
Yann E. MORIN4802db32016-07-17 12:34:26 +020021config BR2_BUILD_DIR
22 string
23 option env="BUILD_DIR"
24
Arnout Vandecappelle12825f72015-12-31 01:34:13 +010025# Hidden config symbols for packages to check system gcc version
26config BR2_HOST_GCC_VERSION
27 string
28 option env="HOST_GCC_VERSION"
29
Bernd Kuhls8fce6d72016-03-19 21:25:35 +010030config BR2_HOST_GCC_AT_LEAST_4_6
31 bool
32 default y if BR2_HOST_GCC_VERSION = "4 6"
33
Arnout Vandecappelle12825f72015-12-31 01:34:13 +010034config BR2_HOST_GCC_AT_LEAST_4_7
35 bool
36 default y if BR2_HOST_GCC_VERSION = "4 7"
Bernd Kuhls8fce6d72016-03-19 21:25:35 +010037 select BR2_HOST_GCC_AT_LEAST_4_6
Arnout Vandecappelle12825f72015-12-31 01:34:13 +010038
39config BR2_HOST_GCC_AT_LEAST_4_8
40 bool
41 default y if BR2_HOST_GCC_VERSION = "4 8"
42 select BR2_HOST_GCC_AT_LEAST_4_7
43
44config BR2_HOST_GCC_AT_LEAST_4_9
45 bool
46 default y if BR2_HOST_GCC_VERSION = "4 9"
47 select BR2_HOST_GCC_AT_LEAST_4_8
48
49config BR2_HOST_GCC_AT_LEAST_5
50 bool
51 default y if BR2_HOST_GCC_VERSION = "5"
52 select BR2_HOST_GCC_AT_LEAST_4_9
53
Martin Bark3d217572016-06-06 11:18:14 +010054config BR2_HOST_GCC_AT_LEAST_6
55 bool
56 default y if BR2_HOST_GCC_VERSION = "6"
57 select BR2_HOST_GCC_AT_LEAST_5
58
Maxime Hadjinlianaac3d2b2014-02-18 00:37:12 +010059# Hidden boolean selected by packages in need of Java in order to build
60# (example: xbmc)
Maxime Hadjinlian0721c712014-02-19 16:33:50 +010061config BR2_NEEDS_HOST_JAVA
Maxime Hadjinlianaac3d2b2014-02-18 00:37:12 +010062 bool
63
Maxime Hadjinlian8f9da282014-05-04 00:45:44 +020064# Hidden boolean selected by packages in need of javac in order to build
65# (example: classpath)
66config BR2_NEEDS_HOST_JAVAC
67 bool
68
69# Hidden boolean selected by packages in need of jar in order to build
70# (example: classpath)
71config BR2_NEEDS_HOST_JAR
72 bool
73
Thomas Petazzoni70d60372012-12-29 06:14:49 +000074# Hidden boolean selected by pre-built packages for x86, when they
75# need to run on x86-64 machines (example: pre-built external
76# toolchains, binary tools like SAM-BA, etc.).
77config BR2_HOSTARCH_NEEDS_IA32_LIBS
78 bool
79
Thomas Petazzoni0e4bc502013-11-11 17:47:25 +010080# Hidden boolean selected by packages that need to build 32 bits
81# binaries with the host compiler, even on 64 bits build machines (e.g
82# bootloaders).
83config BR2_HOSTARCH_NEEDS_IA32_COMPILER
84 bool
85
Thomas Petazzoni79ee3c12012-11-03 08:27:59 +000086source "arch/Config.in"
Bernhard Reutner-Fischer7d8a59b2007-07-08 16:28:54 +000087
Eric Andersen8e5fb3f2004-12-11 13:01:10 +000088menu "Build options"
89
Thomas Petazzoni15929262010-04-10 22:55:01 +020090menu "Commands"
91
Eric Andersen2d523c22004-10-09 01:06:03 +000092config BR2_WGET
Eric Andersen8e5fb3f2004-12-11 13:01:10 +000093 string "Wget command"
Peter Korsgaard6871b162010-11-04 19:16:43 +010094 default "wget --passive-ftp -nd -t 3"
Eric Andersen2d523c22004-10-09 01:06:03 +000095
Maxime Petazzonicf711112010-09-02 12:09:45 +020096config BR2_SVN
97 string "Subversion (svn) command"
98 default "svn"
Eric Andersene30cf262005-01-23 11:20:30 +000099
Maxime Petazzonicf711112010-09-02 12:09:45 +0200100config BR2_BZR
101 string "Bazaar (bzr) command"
102 default "bzr"
Sven Neumanndf03cda2009-08-07 11:57:54 +0200103
Ulf Samuelsson85f54fb2007-08-24 05:31:07 +0000104config BR2_GIT
Maxime Petazzonicf711112010-09-02 12:09:45 +0200105 string "Git command"
106 default "git"
Ulf Samuelsson85f54fb2007-08-24 05:31:07 +0000107
Gustavo Zacarias15eb1fa2013-09-11 09:12:04 -0300108config BR2_CVS
109 string "CVS command"
110 default "cvs"
111
David Wagner2690e762011-09-29 21:57:46 +0200112config BR2_LOCALFILES
113 string "Local files retrieval command"
114 default "cp"
115
Thomas De Schampheleirec61788f2011-10-19 09:25:40 +0200116config BR2_SCP
117 string "Secure copy (scp) command"
118 default "scp"
119
120config BR2_SSH
121 string "Secure shell (ssh) command"
122 default "ssh"
123
Thomas De Schampheleiref694c072011-10-19 09:25:47 +0200124config BR2_HG
125 string "Mercurial (hg) command"
126 default "hg"
127
Bernhard Reutner-Fischer859b9132006-10-01 15:07:45 +0000128config BR2_ZCAT
129 string "zcat command"
Bernhard Reutner-Fischera9612bf2007-03-09 08:26:10 +0000130 default "gzip -d -c"
Bernhard Reutner-Fischer859b9132006-10-01 15:07:45 +0000131 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700132 Command to be used to extract a gzip'ed file to stdout. zcat
133 is identical to gunzip -c except that the former may not be
134 available on your system.
Bernhard Reutner-Fischera9612bf2007-03-09 08:26:10 +0000135 Default is "gzip -d -c"
136 Other possible values include "gunzip -c" or "zcat".
Bernhard Reutner-Fischer6e2823c2006-11-17 15:43:51 +0000137
138config BR2_BZCAT
139 string "bzcat command"
140 default "bzcat"
141 help
142 Command to be used to extract a bzip2'ed file to stdout.
143 bzcat is identical to bunzip2 -c except that the former may
144 not be available on your system.
145 Default is "bzcat"
146 Other possible values include "bunzip2 -c" or "bzip2 -d -c".
Bernhard Reutner-Fischer859b9132006-10-01 15:07:45 +0000147
Allan W. Nielsen177b4b42011-05-10 08:17:05 +0200148config BR2_XZCAT
149 string "xzcat command"
150 default "xzcat"
151 help
152 Command to be used to extract a xz'ed file to stdout.
153 Default is "xzcat"
154
Bernhard Reutner-Fischerce90aae2005-12-10 14:59:02 +0000155config BR2_TAR_OPTIONS
156 string "Tar options"
Bernhard Reutner-Fischer7df4de62005-12-10 15:36:43 +0000157 default ""
158 help
159 Options to pass to tar when extracting the sources.
160 E.g. " -v --exclude='*.svn*'" to exclude all .svn internal files
161 and to be verbose.
Bernhard Reutner-Fischerce90aae2005-12-10 14:59:02 +0000162
Thomas Petazzoni15929262010-04-10 22:55:01 +0200163endmenu
164
Arnout Vandecappelle (Essensium/Mind)4e0170d2013-02-06 21:50:57 +0000165config BR2_DEFCONFIG_FROM_ENV
166 string
167 option env="BR2_DEFCONFIG"
168
169config BR2_DEFCONFIG
170 string "Location to save buildroot config"
171 default BR2_DEFCONFIG_FROM_ENV if BR2_DEFCONFIG_FROM_ENV != ""
172 default "$(CONFIG_DIR)/defconfig"
173 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700174 When running 'make savedefconfig', the defconfig file will be
175 saved in this location.
Arnout Vandecappelle (Essensium/Mind)4e0170d2013-02-06 21:50:57 +0000176
Mike Frysinger59a63a92005-10-01 00:35:24 +0000177config BR2_DL_DIR
178 string "Download dir"
H Hartley Sweetenbe695dc2009-09-23 08:46:52 +0200179 default "$(TOPDIR)/dl"
Mike Frysinger59a63a92005-10-01 00:35:24 +0000180 help
181 Directory to store all the source files that we need to fetch.
Arnout Vandecappelle67680212014-02-04 16:18:51 +0100182 If the Linux shell environment has defined the BR2_DL_DIR
Martin Kelly65f9b932016-05-31 09:57:22 -0700183 environment variable, then this overrides this configuration
184 item.
Mike Frysinger59a63a92005-10-01 00:35:24 +0000185
H Hartley Sweetenbe695dc2009-09-23 08:46:52 +0200186 The default is $(TOPDIR)/dl
Bernhard Reutner-Fischer4b0d5a82007-09-26 21:12:38 +0000187
Gustavo Zacariasa2b4f7f2011-02-02 10:05:56 -0300188config BR2_HOST_DIR
189 string "Host dir"
190 default "$(BASE_DIR)/host"
191 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700192 Directory to store all the binary files that are built for the
193 host. This includes the cross compilation toolchain when
194 building the internal buildroot toolchain.
Gustavo Zacariasa2b4f7f2011-02-02 10:05:56 -0300195
196 The default is $(BASE_DIR)/host
197
Thomas Petazzoni80080072010-12-05 21:52:37 +0100198menu "Mirrors and Download locations"
199
200config BR2_PRIMARY_SITE
201 string "Primary download site"
202 default ""
203 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700204 Primary site to download from. If this option is set then
205 buildroot will try to download package source first from this
206 site and try the default if the file is not found.
Jérôme Pouiller4a9d9802015-11-18 10:03:25 +0100207 Valid URIs are:
208 - URIs recognized by $(WGET)
209 - local URIs of the form file://absolutepath
210 - scp URIs of the form scp://[user@]host:path.
Thomas Petazzoni80080072010-12-05 21:52:37 +0100211
Thomas De Schampheleire5a83e082012-06-22 07:37:03 +0200212config BR2_PRIMARY_SITE_ONLY
213 bool "Only allow downloads from primary download site"
214 depends on BR2_PRIMARY_SITE != ""
215 help
216 If this option is enabled, downloads will only be attempted
217 from the primary download site. Other locations, like the
218 package's official download location or the backup download
Martin Kelly65f9b932016-05-31 09:57:22 -0700219 site, will not be considered. Therefore, if the package is not
220 present on the primary site, the download fails.
Thomas De Schampheleire5a83e082012-06-22 07:37:03 +0200221
Martin Kelly65f9b932016-05-31 09:57:22 -0700222 This is useful for project developers who want to ensure that
223 the project can be built even if the upstream tarball
Thomas De Schampheleire5a83e082012-06-22 07:37:03 +0200224 locations disappear.
225
226if !BR2_PRIMARY_SITE_ONLY
227
Thomas Petazzoni80080072010-12-05 21:52:37 +0100228config BR2_BACKUP_SITE
229 string "Backup download site"
Peter Seiderer4a9eb202014-02-21 23:33:36 +0100230 default "http://sources.buildroot.net"
Thomas Petazzoni80080072010-12-05 21:52:37 +0100231 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700232 Backup site to download from. If this option is set then
233 buildroot will fall back to download package sources from here
234 if the normal location fails.
Thomas Petazzoni80080072010-12-05 21:52:37 +0100235
Thomas Petazzoni80080072010-12-05 21:52:37 +0100236config BR2_KERNEL_MIRROR
237 string "Kernel.org mirror"
Alexey Brodkinde76cb72016-05-23 18:36:53 +0300238 default "https://cdn.kernel.org/pub"
Thomas Petazzoni80080072010-12-05 21:52:37 +0100239 help
Alexey Brodkinde76cb72016-05-23 18:36:53 +0300240 kernel.org is mirrored on a number of servers around the
Martin Kelly65f9b932016-05-31 09:57:22 -0700241 world. The following allows you to select your preferred
Alexey Brodkinde76cb72016-05-23 18:36:53 +0300242 mirror. By default, a CDN is used, which automatically
243 redirects to a mirror geographically close to you.
Thomas Petazzoni80080072010-12-05 21:52:37 +0100244
Martin Kelly65f9b932016-05-31 09:57:22 -0700245 Have a look on the kernel.org site for a list of mirrors, then
246 enter the URL to the base directory. Examples:
Thomas Petazzoni80080072010-12-05 21:52:37 +0100247
248 http://www.XX.kernel.org/pub (XX = country code)
249 http://mirror.aarnet.edu.au/pub/ftp.kernel.org
250
251config BR2_GNU_MIRROR
252 string "GNU Software mirror"
Thomas Petazzoni3999f0a2016-05-24 20:48:26 +0200253 default "http://ftpmirror.gnu.org"
Thomas Petazzoni80080072010-12-05 21:52:37 +0100254 help
Thomas Petazzoni3999f0a2016-05-24 20:48:26 +0200255 GNU has multiple software mirrors scattered around the
Martin Kelly65f9b932016-05-31 09:57:22 -0700256 world. The following allows you to select your preferred
Thomas Petazzoni3999f0a2016-05-24 20:48:26 +0200257 mirror. By default, a generic address is used, which
258 automatically selects an up-to-date and local mirror.
Thomas Petazzoni80080072010-12-05 21:52:37 +0100259
Martin Kelly65f9b932016-05-31 09:57:22 -0700260 Have a look on the gnu.org site for a list of mirrors, then
261 enter the URL to the base directory. Examples:
Thomas Petazzoni80080072010-12-05 21:52:37 +0100262
263 http://ftp.gnu.org/pub/gnu
264 http://mirror.aarnet.edu.au/pub/gnu
265
Francois Perrad72afb292014-01-11 16:42:07 +0100266config BR2_LUAROCKS_MIRROR
267 string "LuaRocks mirror"
Francois Perrad0b8411a2014-07-25 20:21:24 +0200268 default "http://rocks.moonscript.org"
Francois Perrad72afb292014-01-11 16:42:07 +0100269 help
270 LuaRocks repository.
271
272 See http://luarocks.org
273
Francois Perrad9fbb1692014-02-23 15:17:16 +0100274config BR2_CPAN_MIRROR
275 string "CPAN mirror (Perl packages)"
Yann E. MORIN32567d12014-07-19 12:09:19 +0200276 default "http://cpan.metacpan.org"
Francois Perrad9fbb1692014-02-23 15:17:16 +0100277 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700278 CPAN (Comprehensive Perl Archive Network) is a repository of
279 Perl packages. It has multiple software mirrors scattered
Francois Perrad9fbb1692014-02-23 15:17:16 +0100280 around the world. This option allows you to select a mirror.
281
282 The list of mirrors is available at:
283 http://search.cpan.org/mirror
284
Yann E. MORIN3318a5a2015-07-14 09:42:40 +0200285endif
286
Thomas Petazzoni80080072010-12-05 21:52:37 +0100287endmenu
Thomas Petazzoniaa41d372010-04-10 22:55:38 +0200288
Eric Andersen8e5fb3f2004-12-11 13:01:10 +0000289config BR2_JLEVEL
Nathan Lynch5016aa02012-06-16 09:37:17 +0000290 int "Number of jobs to run simultaneously (0 for auto)"
291 default "0"
Eric Andersen8e5fb3f2004-12-11 13:01:10 +0000292 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700293 Number of jobs to run simultaneously. If 0, determine
294 automatically according to number of CPUs on the host system.
Bernhard Reutner-Fischer93ab6d32007-01-28 12:03:58 +0000295
Thomas Petazzoni17b66af2010-12-07 21:09:56 +0100296config BR2_CCACHE
297 bool "Enable compiler cache"
298 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700299 This option will enable the use of ccache, a compiler cache.
300 It will cache the result of previous builds to speed up future
301 builds. By default, the cache is stored in
Thomas Petazzoni17b66af2010-12-07 21:09:56 +0100302 $HOME/.buildroot-ccache.
303
Thomas Petazzonif044e032012-03-07 20:26:50 +0100304 Note that Buildroot does not try to invalidate the cache
Martin Kelly65f9b932016-05-31 09:57:22 -0700305 contents when the compiler changes in an incompatible way.
306 Therefore, if you make a change to the compiler version and/or
307 configuration, you are responsible for purging the ccache
308 cache by removing the $HOME/.buildroot-ccache directory.
Thomas Petazzonif044e032012-03-07 20:26:50 +0100309
Danomi Manchegodd79f2d2014-04-30 22:05:07 -0400310if BR2_CCACHE
311
Thomas De Schampheleire43329072012-05-16 21:39:28 +0200312config BR2_CCACHE_DIR
313 string "Compiler cache location"
Thomas De Schampheleire43329072012-05-16 21:39:28 +0200314 default "$(HOME)/.buildroot-ccache"
315 help
316 Where ccache should store cached files.
317
Danomi Manchegodd79f2d2014-04-30 22:05:07 -0400318config BR2_CCACHE_INITIAL_SETUP
319 string "Compiler cache initial setup"
320 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700321 Initial ccache settings to apply, such as --max-files or
322 --max-size.
Danomi Manchegodd79f2d2014-04-30 22:05:07 -0400323
Martin Kelly65f9b932016-05-31 09:57:22 -0700324 For example, if your project is known to require more space
325 than the default max cache size, then you might want to
326 increase the cache size to a suitable amount using the -M
327 (--max-size) option.
Danomi Manchegodd79f2d2014-04-30 22:05:07 -0400328
Martin Kelly65f9b932016-05-31 09:57:22 -0700329 The string you specify here is passed verbatim to ccache.
330 Refer to ccache documentation for more details.
Danomi Manchegodd79f2d2014-04-30 22:05:07 -0400331
Martin Kelly65f9b932016-05-31 09:57:22 -0700332 These initial settings are applied after ccache has been
333 compiled.
Danomi Manchegodd79f2d2014-04-30 22:05:07 -0400334
Arnout Vandecappelle1e97b272015-10-04 16:25:32 +0100335config BR2_CCACHE_USE_BASEDIR
336 bool "Use relative paths"
337 default y
338 help
339 Allow ccache to convert absolute paths within the output
340 directory into relative paths.
341
Martin Kelly65f9b932016-05-31 09:57:22 -0700342 During the build, many -I include directives are given with an
343 absolute path. These absolute paths end up in the hashes that
344 are computed by ccache. Therefore, when you build from a
345 different directory, the hash will be different and the cached
346 object will not be used.
Arnout Vandecappelle1e97b272015-10-04 16:25:32 +0100347
348 To improve cache performance, set this option to y. This
349 allows ccache to rewrite absolute paths within the output
Martin Kelly65f9b932016-05-31 09:57:22 -0700350 directory into relative paths. Note that only paths within the
351 output directory will be rewritten; therefore, if you change
352 BR2_HOST_DIR to point outside the output directory and
Arnout Vandecappelle1e97b272015-10-04 16:25:32 +0100353 subsequently move it to a different location, this will lead
354 to cache misses.
355
356 This option has as a result that the debug information in the
357 object files also has only relative paths. Therefore, make
358 sure you cd to the build directory before starting gdb. See
Martin Kelly65f9b932016-05-31 09:57:22 -0700359 the section "COMPILING IN DIFFERENT DIRECTORIES" in the ccache
360 manual for more information.
Arnout Vandecappelle1e97b272015-10-04 16:25:32 +0100361
Danomi Manchegodd79f2d2014-04-30 22:05:07 -0400362endif
363
Bernhard Reutner-Fischer7779fd72007-02-09 13:31:55 +0000364config BR2_DEPRECATED
Gustavo Zacarias8515ef02014-09-19 10:41:09 -0300365 bool "Show options and packages that are deprecated or obsolete"
Bernhard Reutner-Fischer7779fd72007-02-09 13:31:55 +0000366 help
Gustavo Zacarias8515ef02014-09-19 10:41:09 -0300367 This option shows outdated/obsolete versions of packages and
368 options that are otherwise hidden.
Eric Andersenba7c48f2004-12-11 10:25:40 +0000369
Thomas De Schampheleireba4ad9d2014-01-03 17:02:50 +0100370if BR2_DEPRECATED
371
Gustavo Zacarias0f1556e2015-03-03 12:52:24 -0300372config BR2_DEPRECATED_SINCE_2015_05
373 bool
374 default y
375
Gustavo Zacarias602692a2015-06-02 14:34:34 -0300376config BR2_DEPRECATED_SINCE_2015_08
377 bool
378 default y
379
Vicente Olivert Riera429a1162015-12-17 16:39:53 +0000380config BR2_DEPRECATED_SINCE_2015_11
381 bool
382 default y
383
Gustavo Zacarias07941f42016-01-15 07:47:46 -0300384config BR2_DEPRECATED_SINCE_2016_02
385 bool
386 default y
387
Gustavo Zacariasbca107e2016-02-22 14:54:57 -0300388config BR2_DEPRECATED_SINCE_2016_05
389 bool
390 default y
391
Julien Floret995da6e2016-06-16 16:41:14 +0200392config BR2_DEPRECATED_SINCE_2016_08
393 bool
394 default y
395
Gustavo Zacariasac1f3242016-09-07 22:17:26 -0300396config BR2_DEPRECATED_SINCE_2016_11
397 bool
398 default y
399
Thomas De Schampheleireba4ad9d2014-01-03 17:02:50 +0100400endif
401
John Voltz41f6b792008-03-12 13:07:10 +0000402config BR2_ENABLE_DEBUG
403 bool "build packages with debugging symbols"
John Voltz41f6b792008-03-12 13:07:10 +0000404 help
Thomas Petazzonia9a34672012-03-14 23:49:58 +0100405 Build packages with debugging symbols enabled. All libraries
406 and binaries in the 'staging' directory will have debugging
407 symbols, which allows remote debugging even if libraries and
408 binaries are stripped on the target. Whether libraries and
409 binaries are stripped on the target is controlled by the
410 BR2_STRIP_* options below.
John Voltz41f6b792008-03-12 13:07:10 +0000411
412if BR2_ENABLE_DEBUG
413choice
414 prompt "gcc debug level"
415 default BR2_DEBUG_2
416 help
417 Set the debug level for gcc
418
419config BR2_DEBUG_1
420 bool "debug level 1"
421 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700422 Debug level 1 produces minimal information, enough for making
423 backtraces in parts of the program that you don't plan to
424 debug. This includes descriptions of functions and external
425 variables, but no information about local variables and no
426 line numbers.
John Voltz41f6b792008-03-12 13:07:10 +0000427
428config BR2_DEBUG_2
429 bool "debug level 2"
430 help
431 The default gcc debug level is 2
432
433config BR2_DEBUG_3
434 bool "debug level 3"
435 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700436 Level 3 includes extra information, such as all the macro
437 definitions present in the program. Some debuggers support
438 macro expansion when you use -g3.
John Voltz41f6b792008-03-12 13:07:10 +0000439endchoice
440endif
441
Bernhard Reutner-Fischerbbd251a2007-07-31 18:06:50 +0000442choice
Thomas Petazzonia9a34672012-03-14 23:49:58 +0100443 prompt "strip command for binaries on target"
Bernhard Reutner-Fischerbbd251a2007-07-31 18:06:50 +0000444 default BR2_STRIP_strip
Bernhard Reutner-Fischerbbd251a2007-07-31 18:06:50 +0000445
446config BR2_STRIP_strip
447 bool "strip"
Axel Lin9f2bf302013-09-03 17:39:53 +0800448 depends on !BR2_PACKAGE_HOST_ELF2FLT
Bernhard Reutner-Fischerbbd251a2007-07-31 18:06:50 +0000449 help
Thomas Petazzonia9a34672012-03-14 23:49:58 +0100450 Binaries and libraries in the target filesystem will be
Martin Kelly65f9b932016-05-31 09:57:22 -0700451 stripped using the normal 'strip' command. This allows to save
452 space, mainly by removing debugging symbols. Debugging symbols
453 on the target are needed for native debugging, but not when
454 remote debugging is used.
Ulf Samuelsson85f54fb2007-08-24 05:31:07 +0000455
Bernhard Reutner-Fischerbbd251a2007-07-31 18:06:50 +0000456config BR2_STRIP_none
457 bool "none"
458 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700459 Do not strip binaries and libraries in the target filesystem.
Bernhard Reutner-Fischerbbd251a2007-07-31 18:06:50 +0000460endchoice
461
Thomas De Schampheleire2a970452012-06-21 19:34:50 +0000462config BR2_STRIP_EXCLUDE_FILES
463 string "executables that should not be stripped"
464 depends on !BR2_STRIP_none
465 default ""
466 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700467 You may specify a space-separated list of binaries and
468 libraries here that should not be stripped on the target.
Thomas De Schampheleire2a970452012-06-21 19:34:50 +0000469
470config BR2_STRIP_EXCLUDE_DIRS
471 string "directories that should be skipped when stripping"
472 depends on !BR2_STRIP_none
473 default ""
474 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700475 You may specify a space-separated list of directories that
476 should be skipped when stripping. Binaries and libraries in
477 these directories will not be touched. The directories should
478 be specified relative to the target directory, without leading
479 slash.
Thomas De Schampheleire2a970452012-06-21 19:34:50 +0000480
John Voltz41f6b792008-03-12 13:07:10 +0000481choice
482 prompt "gcc optimization level"
John Voltz7eb796b2008-03-16 13:26:14 +0000483 default BR2_OPTIMIZE_S
John Voltz923f42a2008-03-12 11:23:11 +0000484 help
John Voltz41f6b792008-03-12 13:07:10 +0000485 Set the optimization level for gcc
486
487config BR2_OPTIMIZE_0
488 bool "optimization level 0"
489 help
Peter Korsgaard02a623d2008-08-04 19:07:05 +0000490 Do not optimize. This is the default.
John Voltz41f6b792008-03-12 13:07:10 +0000491
492config BR2_OPTIMIZE_1
493 bool "optimization level 1"
494 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700495 Optimize. Optimizing compilation takes somewhat more time, and
496 a lot more memory for a large function. With -O, the compiler
497 tries to reduce code size and execution time, without
498 performing any optimizations that take a great deal of
499 compilation time. -O turns on the following optimization
Peter Korsgaard02a623d2008-08-04 19:07:05 +0000500 flags: -fdefer-pop -fdelayed-branch -fguess-branch-probability
501 -fcprop-registers -floop-optimize -fif-conversion
502 -fif-conversion2 -ftree-ccp -ftree-dce -ftree-dominator-opts
503 -ftree-dse -ftree-ter -ftree-lrs -ftree-sra -ftree-copyrename
Martin Kelly65f9b932016-05-31 09:57:22 -0700504 -ftree-fre -ftree-ch -funit-at-a-time -fmerge-constants. -O
505 also turns on -fomit-frame-pointer on machines where doing so
506 does not interfere with debugging.
John Voltz41f6b792008-03-12 13:07:10 +0000507
508config BR2_OPTIMIZE_2
509 bool "optimization level 2"
510 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700511 Optimize even more. GCC performs nearly all supported
512 optimizations that do not involve a space-speed tradeoff. The
513 compiler does not perform loop unrolling or function inlining
514 when you specify -O2. As compared to -O, this option increases
515 both compilation time and the performance of the generated
516 code. -O2 turns on all optimization flags specified by -O. It
517 also turns on the following optimization flags:
518 -fthread-jumps -fcrossjumping -foptimize-sibling-calls
Peter Korsgaard02a623d2008-08-04 19:07:05 +0000519 -fcse-follow-jumps -fcse-skip-blocks -fgcse -fgcse-lm
Martin Kelly65f9b932016-05-31 09:57:22 -0700520 -fexpensive-optimizations -fstrength-reduce
521 -frerun-cse-after-loop -frerun-loop-opt -fcaller-saves
522 -fpeephole2 -fschedule-insns -fschedule-insns2
523 -fsched-interblock -fsched-spec -fregmove -fstrict-aliasing
524 -fdelete-null-pointer-checks -freorder-blocks
525 -freorder-functions -falign-functions -falign-jumps
526 -falign-loops -falign-labels -ftree-vrp -ftree-pre. Please
527 note the warning under -fgcse about invoking -O2 on programs
John Voltz41f6b792008-03-12 13:07:10 +0000528 that use computed gotos.
529
530config BR2_OPTIMIZE_3
531 bool "optimization level 3"
532 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700533 Optimize yet more. -O3 turns on all optimizations specified by
534 -O2 and also turns on the -finline-functions, -funswitch-loops
535 and -fgcse-after-reload options.
John Voltz41f6b792008-03-12 13:07:10 +0000536
Martin Kelly5ff84592016-05-18 14:17:55 -0700537config BR2_OPTIMIZE_G
538 bool "optimize for debugging"
539 depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_8
540 help
541 Optimize for debugging. This enables optimizations that do not
Martin Kelly65f9b932016-05-31 09:57:22 -0700542 interfere with debugging. It should be the optimization level
543 of choice for the standard edit-compile-debug cycle, offering
544 a reasonable level of optimization while maintaining fast
545 compilation and a good debugging experience.
John Voltz41f6b792008-03-12 13:07:10 +0000546
547config BR2_OPTIMIZE_S
548 bool "optimize for size"
549 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700550 Optimize for size. -Os enables all -O2 optimizations that do
551 not typically increase code size. It also performs further
552 optimizations designed to reduce code size. -Os disables the
553 following optimization flags: -falign-functions -falign-jumps
554 -falign-loops -falign-labels -freorder-blocks
555 -freorder-blocks-and-partition -fprefetch-loop-arrays
John Voltz41f6b792008-03-12 13:07:10 +0000556 -ftree-vect-loop-version
Peter Korsgaard02a623d2008-08-04 19:07:05 +0000557
John Voltz41f6b792008-03-12 13:07:10 +0000558endchoice
John Voltz923f42a2008-03-12 11:23:11 +0000559
Pascal Huerst09a1a102014-07-31 22:08:55 +0200560config BR2_GOOGLE_BREAKPAD_ENABLE
561 bool "Enable google-breakpad support"
562 select BR2_PACKAGE_GOOGLE_BREAKPAD
563 depends on BR2_INSTALL_LIBSTDCPP
564 depends on BR2_TOOLCHAIN_USES_GLIBC
565 depends on BR2_PACKAGE_GOOGLE_BREAKPAD_ARCH_SUPPORTS
566 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700567 This option will enable the use of google breakpad, a library
568 and tool suite that allows you to distribute an application to
569 users with compiler-provided debugging information removed,
570 record crashes in compact "minidump" files, send them back to
571 your server and produce C and C++ stack traces from these
572 minidumps. Breakpad can also write minidumps on request for
573 programs that have not crashed.
Pascal Huerst09a1a102014-07-31 22:08:55 +0200574
575if BR2_GOOGLE_BREAKPAD_ENABLE
576
577config BR2_GOOGLE_BREAKPAD_INCLUDE_FILES
578 string "List of executables and libraries to extract symbols from"
579 default ""
580 help
581 You may specify a space-separated list of binaries and
582 libraries with full paths relative to $(TARGET_DIR) of which
583 debug symbols will be dumped for further use with google
584 breakpad.
585
586 A directory structure that can be used by minidump-stackwalk
587 will be created at:
588
589 $(STAGING_DIR)/usr/share/google-breakpad-symbols
590
591endif
592
Steven Noonand29c7192015-12-27 12:07:31 +0100593choice
Thomas Petazzonic5866be2013-09-02 18:06:36 +0200594 bool "build code with Stack Smashing Protection"
Steven Noonand29c7192015-12-27 12:07:31 +0100595 default BR2_SSP_ALL if BR2_ENABLE_SSP # legacy
Thomas Petazzonic5866be2013-09-02 18:06:36 +0200596 depends on BR2_TOOLCHAIN_HAS_SSP
597 help
Steven Noonand29c7192015-12-27 12:07:31 +0100598 Enable stack smashing protection support using GCC's
599 -fstack-protector option family.
Thomas Petazzonic5866be2013-09-02 18:06:36 +0200600
Martin Kelly65f9b932016-05-31 09:57:22 -0700601 See
602 http://www.linuxfromscratch.org/hints/downloads/files/ssp.txt
Thomas De Schampheleirebed4e272013-11-11 17:23:23 +0100603 for details.
Thomas Petazzonic5866be2013-09-02 18:06:36 +0200604
Martin Kelly65f9b932016-05-31 09:57:22 -0700605 Note that this requires the toolchain to have SSP support.
606 This is always the case for glibc and eglibc toolchain, but is
607 optional in uClibc toolchains.
Thomas Petazzonic5866be2013-09-02 18:06:36 +0200608
Steven Noonand29c7192015-12-27 12:07:31 +0100609config BR2_SSP_NONE
610 bool "None"
611 help
612 Disable stack-smashing protection.
613
614config BR2_SSP_REGULAR
615 bool "-fstack-protector"
616 help
617 Emit extra code to check for buffer overflows, such as stack
618 smashing attacks. This is done by adding a guard variable to
619 functions with vulnerable objects. This includes functions
620 that call alloca, and functions with buffers larger than 8
621 bytes. The guards are initialized when a function is entered
622 and then checked when the function exits. If a guard check
623 fails, an error message is printed and the program exits.
624
625config BR2_SSP_STRONG
626 bool "-fstack-protector-strong"
627 depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
628 help
629 Like -fstack-protector but includes additional functions to be
630 protected - those that have local array definitions, or have
631 references to local frame addresses.
632
633comment "Stack Smashing Protection strong needs a toolchain w/ gcc >= 4.9"
634 depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
635
636config BR2_SSP_ALL
637 bool "-fstack-protector-all"
638 help
639 Like -fstack-protector except that all functions are
640 protected. This option might have a significant performance
641 impact on the compiled binaries.
642
643endchoice
644
645comment "Stack Smashing Protection needs a toolchain w/ SSP"
Thomas Petazzonic5866be2013-09-02 18:06:36 +0200646 depends on !BR2_TOOLCHAIN_HAS_SSP
647
Thomas Petazzoni158001f2014-12-11 23:50:09 +0100648choice
649 bool "libraries"
Thomas Petazzonif1d3e092014-12-11 23:50:11 +0100650 default BR2_SHARED_LIBS if BR2_BINFMT_SUPPORTS_SHARED
Thomas Petazzoni158001f2014-12-11 23:50:09 +0100651 default BR2_STATIC_LIBS if !BR2_BINFMT_SUPPORTS_SHARED
Bernhard Reutner-Fischer3096f342007-06-01 22:16:28 +0000652 help
Thomas Petazzoni158001f2014-12-11 23:50:09 +0100653 Select the type of libraries you want to use on the target.
Bernhard Reutner-Fischer3096f342007-06-01 22:16:28 +0000654
Martin Kelly65f9b932016-05-31 09:57:22 -0700655 The default is to build dynamic libraries and use those on the
656 target filesystem, except when the architecture and/or the
657 selected binary format does not support shared libraries.
Alexey Brodkin7d9c0df2014-10-12 18:34:44 +0200658
Thomas Petazzoni158001f2014-12-11 23:50:09 +0100659config BR2_STATIC_LIBS
660 bool "static only"
661 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700662 Build and use only static libraries. No shared libraries will
Bernd Kuhlsd9312d62016-07-31 18:02:47 +0200663 be installed on the target. This potentially increases your
Martin Kelly65f9b932016-05-31 09:57:22 -0700664 code size and should only be used if you know what you are
665 doing. Note that some packages may not be available when this
666 option is enabled, due to their need for dynamic library
667 support.
Thomas Petazzoni158001f2014-12-11 23:50:09 +0100668
669config BR2_SHARED_LIBS
670 bool "shared only"
671 depends on BR2_BINFMT_SUPPORTS_SHARED
672 help
673 Build and use only shared libraries. This is the recommended
674 solution as it saves space and build time.
675
676config BR2_SHARED_STATIC_LIBS
677 bool "both static and shared"
678 depends on BR2_BINFMT_SUPPORTS_SHARED
679 help
680 Build both shared and static libraries, but link executables
681 dynamically. While building both shared and static libraries
682 take more time and more disk space, having static libraries
683 may be useful to link some of the applications statically.
684
685endchoice
Alexey Brodkin7d9c0df2014-10-12 18:34:44 +0200686
Bernhard Reutner-Fischer3096f342007-06-01 22:16:28 +0000687
Thomas Petazzoniee0246e2011-09-29 21:57:38 +0200688config BR2_PACKAGE_OVERRIDE_FILE
689 string "location of a package override file"
Yann E. MORINeda3d0e2014-01-29 22:48:24 +0100690 default "$(CONFIG_DIR)/local.mk"
Thomas Petazzoniee0246e2011-09-29 21:57:38 +0200691 help
692 A package override file is a short makefile that contains
Martin Kelly65f9b932016-05-31 09:57:22 -0700693 variable definitions of the form <pkg>_OVERRIDE_SRCDIR, which
694 allows to tell Buildroot to use an existing directory as the
695 source directory for a particular package. See the Buildroot
696 documentation for more details on this feature.
Thomas Petazzoniee0246e2011-09-29 21:57:38 +0200697
Simon Dawson5538e472013-03-17 23:13:47 +0000698config BR2_GLOBAL_PATCH_DIR
Ryan Barnettbc4f79d2013-12-18 04:25:01 -0600699 string "global patch directories"
Simon Dawson5538e472013-03-17 23:13:47 +0000700 help
Martin Kelly65f9b932016-05-31 09:57:22 -0700701 You may specify a space separated list of one or more
702 directories containing global package patches. For a specific
703 version <packageversion> of a specific package <packagename>,
704 patches are applied as follows:
Simon Dawson5538e472013-03-17 23:13:47 +0000705
Martin Kelly65f9b932016-05-31 09:57:22 -0700706 First, the default Buildroot patch set for the package is
707 applied from the package's directory in Buildroot.
Simon Dawson5538e472013-03-17 23:13:47 +0000708
Ryan Barnettbc4f79d2013-12-18 04:25:01 -0600709 Then for every directory - <global-patch-dir> - that exists in
710 BR2_GLOBAL_PATCH_DIR, if the directory
Martin Kelly65f9b932016-05-31 09:57:22 -0700711 <global-patch-dir>/<packagename>/<packageversion>/ exists,
712 then all *.patch files in this directory will be applied.
Simon Dawson5538e472013-03-17 23:13:47 +0000713
Martin Kelly65f9b932016-05-31 09:57:22 -0700714 Otherwise, if the directory <global-patch-dir>/<packagename>
715 exists, then all *.patch files in the directory will be
716 applied.
Simon Dawson5538e472013-03-17 23:13:47 +0000717
Thomas Petazzoni4ac8f782014-12-10 23:53:57 +0100718menu "Advanced"
719
720config BR2_COMPILER_PARANOID_UNSAFE_PATH
721 bool "paranoid check of library/header paths"
Romain Naour61c88542016-05-15 12:26:00 +0200722 default y
Thomas Petazzoni4ac8f782014-12-10 23:53:57 +0100723 help
724 By default, when this option is disabled, when the Buildroot
Martin Kelly65f9b932016-05-31 09:57:22 -0700725 cross-compiler will encounter an unsafe library or header path
726 (such as /usr/include, or /usr/lib), the compiler will display
727 a warning.
Thomas Petazzoni4ac8f782014-12-10 23:53:57 +0100728
Martin Kelly65f9b932016-05-31 09:57:22 -0700729 By enabling this option, this warning is turned into an error,
730 which will completely abort the build when such unsafe paths
731 are encountered.
Thomas Petazzoni4ac8f782014-12-10 23:53:57 +0100732
733 Note that this mechanism is available for both the internal
Romain Naourf9d311e2016-05-15 12:26:01 +0200734 toolchain (through the toolchain wrapper and binutils patches)
735 and external toolchain backends (through the toolchain wrapper).
Thomas Petazzoni4ac8f782014-12-10 23:53:57 +0100736
Gilles Chanteperdrix71574a62016-06-14 17:31:09 +0200737config BR2_REPRODUCIBLE
738 bool "Make the build reproducible (experimental)"
Jerzy Grzegoreka446ab72016-07-02 17:06:18 +0200739 help
740 This option will remove all sources of non-reproducibility
741 from the build process. For a given Buildroot configuration,
742 this allows to generate exactly identical binaries from one
743 build to the other, including on different machines.
Gilles Chanteperdrix71574a62016-06-14 17:31:09 +0200744
Jerzy Grzegoreka446ab72016-07-02 17:06:18 +0200745 This is labeled as an experimental feature, as not all
746 packages behave properly to ensure reproducibility.
Gilles Chanteperdrix71574a62016-06-14 17:31:09 +0200747
Eric Andersen8e5fb3f2004-12-11 13:01:10 +0000748endmenu
Eric Andersen2d523c22004-10-09 01:06:03 +0000749
Yann E. MORIN1ac2cdd2016-08-25 19:19:46 +0200750endmenu
751
Bernhard Reutner-Fischer50100392007-09-25 07:55:45 +0000752source "toolchain/Config.in"
753
Thomas Petazzoni6c3e3ad2012-11-03 08:27:58 +0000754source "system/Config.in"
Thomas Petazzonibeb43c72010-12-05 21:52:44 +0100755
Yann E. MORIN24403852013-08-17 22:35:37 +0200756source "linux/Config.in"
Bernhard Reutner-Fischer50100392007-09-25 07:55:45 +0000757
Yann E. MORIN24403852013-08-17 22:35:37 +0200758source "package/Config.in"
Thomas Petazzonid06e8022012-01-28 18:42:49 +0100759
Thomas Petazzoni05852412010-03-10 22:30:06 +0100760source "fs/Config.in"
761
Thomas Petazzoni649b5b92010-03-14 18:20:45 +0100762source "boot/Config.in"
763
Yann E. MORIN24403852013-08-17 22:35:37 +0200764source "package/Config.in.host"
Arnout Vandecappelle (Essensium/Mind)ebcfa982012-11-12 10:08:28 +0000765
766source "Config.in.legacy"
Thomas Petazzoni8eb8aaf2013-12-05 20:11:11 +0100767
Peter Korsgaardf4ea4b92013-12-08 23:21:50 +0100768menu "User-provided options"
769 depends on BR2_EXTERNAL != "support/dummy-external"
770
Thomas Petazzoni8eb8aaf2013-12-05 20:11:11 +0100771source "$BR2_EXTERNAL/Config.in"
Peter Korsgaardf4ea4b92013-12-08 23:21:50 +0100772
773endmenu
Yann E. MORIN4802db32016-07-17 12:34:26 +0200774
775source "$BR2_BUILD_DIR/.br2-external.in"