]> rtime.felk.cvut.cz Git - coffee/buildroot.git/blob - Config.in
core: do not hard-code inclusion of br2-external in Kconfig
[coffee/buildroot.git] / Config.in
1 #
2
3 mainmenu "Buildroot $BR2_VERSION Configuration"
4
5 config BR2_HAVE_DOT_CONFIG
6         bool
7         default y
8
9 config BR2_VERSION
10         string
11         option env="BR2_VERSION_FULL"
12
13 config BR2_HOSTARCH
14         string
15         option env="HOSTARCH"
16
17 config BR2_BUILD_DIR
18         string
19         option env="BUILD_DIR"
20
21 # Hidden config symbols for packages to check system gcc version
22 config BR2_HOST_GCC_VERSION
23         string
24         option env="HOST_GCC_VERSION"
25
26 config BR2_HOST_GCC_AT_LEAST_4_6
27         bool
28         default y if BR2_HOST_GCC_VERSION = "4 6"
29
30 config BR2_HOST_GCC_AT_LEAST_4_7
31         bool
32         default y if BR2_HOST_GCC_VERSION = "4 7"
33         select BR2_HOST_GCC_AT_LEAST_4_6
34
35 config BR2_HOST_GCC_AT_LEAST_4_8
36         bool
37         default y if BR2_HOST_GCC_VERSION = "4 8"
38         select BR2_HOST_GCC_AT_LEAST_4_7
39
40 config BR2_HOST_GCC_AT_LEAST_4_9
41         bool
42         default y if BR2_HOST_GCC_VERSION = "4 9"
43         select BR2_HOST_GCC_AT_LEAST_4_8
44
45 config BR2_HOST_GCC_AT_LEAST_5
46         bool
47         default y if BR2_HOST_GCC_VERSION = "5"
48         select BR2_HOST_GCC_AT_LEAST_4_9
49
50 config BR2_HOST_GCC_AT_LEAST_6
51         bool
52         default y if BR2_HOST_GCC_VERSION = "6"
53         select BR2_HOST_GCC_AT_LEAST_5
54
55 # Hidden boolean selected by packages in need of Java in order to build
56 # (example: xbmc)
57 config BR2_NEEDS_HOST_JAVA
58         bool
59
60 # Hidden boolean selected by packages in need of javac in order to build
61 # (example: classpath)
62 config BR2_NEEDS_HOST_JAVAC
63         bool
64
65 # Hidden boolean selected by packages in need of jar in order to build
66 # (example: classpath)
67 config BR2_NEEDS_HOST_JAR
68         bool
69
70 # Hidden boolean selected by pre-built packages for x86, when they
71 # need to run on x86-64 machines (example: pre-built external
72 # toolchains, binary tools like SAM-BA, etc.).
73 config BR2_HOSTARCH_NEEDS_IA32_LIBS
74         bool
75
76 # Hidden boolean selected by packages that need to build 32 bits
77 # binaries with the host compiler, even on 64 bits build machines (e.g
78 # bootloaders).
79 config BR2_HOSTARCH_NEEDS_IA32_COMPILER
80         bool
81
82 source "arch/Config.in"
83
84 menu "Build options"
85
86 menu "Commands"
87
88 config BR2_WGET
89         string "Wget command"
90         default "wget --passive-ftp -nd -t 3"
91
92 config BR2_SVN
93         string "Subversion (svn) command"
94         default "svn"
95
96 config BR2_BZR
97         string "Bazaar (bzr) command"
98         default "bzr"
99
100 config BR2_GIT
101         string "Git command"
102         default "git"
103
104 config BR2_CVS
105         string "CVS command"
106         default "cvs"
107
108 config BR2_LOCALFILES
109         string "Local files retrieval command"
110         default "cp"
111
112 config BR2_SCP
113         string "Secure copy (scp) command"
114         default "scp"
115
116 config BR2_SSH
117         string "Secure shell (ssh) command"
118         default "ssh"
119
120 config BR2_HG
121         string "Mercurial (hg) command"
122         default "hg"
123
124 config BR2_ZCAT
125         string "zcat command"
126         default "gzip -d -c"
127         help
128           Command to be used to extract a gzip'ed file to stdout. zcat
129           is identical to gunzip -c except that the former may not be
130           available on your system.
131           Default is "gzip -d -c"
132           Other possible values include "gunzip -c" or "zcat".
133
134 config BR2_BZCAT
135         string "bzcat command"
136         default "bzcat"
137         help
138           Command to be used to extract a bzip2'ed file to stdout.
139           bzcat is identical to bunzip2 -c except that the former may
140           not be available on your system.
141           Default is "bzcat"
142           Other possible values include "bunzip2 -c" or "bzip2 -d -c".
143
144 config BR2_XZCAT
145         string "xzcat command"
146         default "xzcat"
147         help
148           Command to be used to extract a xz'ed file to stdout.
149           Default is "xzcat"
150
151 config BR2_TAR_OPTIONS
152         string "Tar options"
153         default ""
154         help
155           Options to pass to tar when extracting the sources.
156           E.g. " -v --exclude='*.svn*'" to exclude all .svn internal files
157           and to be verbose.
158
159 endmenu
160
161 config BR2_DEFCONFIG_FROM_ENV
162         string
163         option env="BR2_DEFCONFIG"
164
165 config BR2_DEFCONFIG
166         string "Location to save buildroot config"
167         default BR2_DEFCONFIG_FROM_ENV if BR2_DEFCONFIG_FROM_ENV != ""
168         default "$(CONFIG_DIR)/defconfig"
169         help
170           When running 'make savedefconfig', the defconfig file will be
171           saved in this location.
172
173 config BR2_DL_DIR
174         string "Download dir"
175         default "$(TOPDIR)/dl"
176         help
177           Directory to store all the source files that we need to fetch.
178           If the Linux shell environment has defined the BR2_DL_DIR
179           environment variable, then this overrides this configuration
180           item.
181
182           The default is $(TOPDIR)/dl
183
184 config BR2_HOST_DIR
185         string "Host dir"
186         default "$(BASE_DIR)/host"
187         help
188           Directory to store all the binary files that are built for the
189           host. This includes the cross compilation toolchain when
190           building the internal buildroot toolchain.
191
192           The default is $(BASE_DIR)/host
193
194 menu "Mirrors and Download locations"
195
196 config BR2_PRIMARY_SITE
197         string "Primary download site"
198         default ""
199         help
200           Primary site to download from. If this option is set then
201           buildroot will try to download package source first from this
202           site and try the default if the file is not found.
203           Valid URIs are:
204             - URIs recognized by $(WGET)
205             - local URIs of the form file://absolutepath
206             - scp URIs of the form scp://[user@]host:path.
207
208 config BR2_PRIMARY_SITE_ONLY
209         bool "Only allow downloads from primary download site"
210         depends on BR2_PRIMARY_SITE != ""
211         help
212           If this option is enabled, downloads will only be attempted
213           from the primary download site. Other locations, like the
214           package's official download location or the backup download
215           site, will not be considered. Therefore, if the package is not
216           present on the primary site, the download fails.
217
218           This is useful for project developers who want to ensure that
219           the project can be built even if the upstream tarball
220           locations disappear.
221
222 if !BR2_PRIMARY_SITE_ONLY
223
224 config BR2_BACKUP_SITE
225         string "Backup download site"
226         default "http://sources.buildroot.net"
227         help
228           Backup site to download from. If this option is set then
229           buildroot will fall back to download package sources from here
230           if the normal location fails.
231
232 config BR2_KERNEL_MIRROR
233         string "Kernel.org mirror"
234         default "https://cdn.kernel.org/pub"
235         help
236           kernel.org is mirrored on a number of servers around the
237           world. The following allows you to select your preferred
238           mirror. By default, a CDN is used, which automatically
239           redirects to a mirror geographically close to you.
240
241           Have a look on the kernel.org site for a list of mirrors, then
242           enter the URL to the base directory. Examples:
243
244              http://www.XX.kernel.org/pub (XX = country code)
245              http://mirror.aarnet.edu.au/pub/ftp.kernel.org
246
247 config BR2_GNU_MIRROR
248         string "GNU Software mirror"
249         default "http://ftpmirror.gnu.org"
250         help
251           GNU has multiple software mirrors scattered around the
252           world. The following allows you to select your preferred
253           mirror. By default, a generic address is used, which
254           automatically selects an up-to-date and local mirror.
255
256           Have a look on the gnu.org site for a list of mirrors, then
257           enter the URL to the base directory. Examples:
258
259              http://ftp.gnu.org/pub/gnu
260              http://mirror.aarnet.edu.au/pub/gnu
261
262 config BR2_LUAROCKS_MIRROR
263         string "LuaRocks mirror"
264         default "http://rocks.moonscript.org"
265         help
266           LuaRocks repository.
267
268           See http://luarocks.org
269
270 config BR2_CPAN_MIRROR
271         string "CPAN mirror (Perl packages)"
272         default "http://cpan.metacpan.org"
273         help
274           CPAN (Comprehensive Perl Archive Network) is a repository of
275           Perl packages. It has multiple software mirrors scattered
276           around the world. This option allows you to select a mirror.
277
278           The list of mirrors is available at:
279           http://search.cpan.org/mirror
280
281 endif
282
283 endmenu
284
285 config BR2_JLEVEL
286         int "Number of jobs to run simultaneously (0 for auto)"
287         default "0"
288         help
289           Number of jobs to run simultaneously. If 0, determine
290           automatically according to number of CPUs on the host system.
291
292 config BR2_CCACHE
293         bool "Enable compiler cache"
294         help
295           This option will enable the use of ccache, a compiler cache.
296           It will cache the result of previous builds to speed up future
297           builds. By default, the cache is stored in
298           $HOME/.buildroot-ccache.
299
300           Note that Buildroot does not try to invalidate the cache
301           contents when the compiler changes in an incompatible way.
302           Therefore, if you make a change to the compiler version and/or
303           configuration, you are responsible for purging the ccache
304           cache by removing the $HOME/.buildroot-ccache directory.
305
306 if BR2_CCACHE
307
308 config BR2_CCACHE_DIR
309         string "Compiler cache location"
310         default "$(HOME)/.buildroot-ccache"
311         help
312           Where ccache should store cached files.
313
314 config BR2_CCACHE_INITIAL_SETUP
315         string "Compiler cache initial setup"
316         help
317           Initial ccache settings to apply, such as --max-files or
318           --max-size.
319
320           For example, if your project is known to require more space
321           than the default max cache size, then you might want to
322           increase the cache size to a suitable amount using the -M
323           (--max-size) option.
324
325           The string you specify here is passed verbatim to ccache.
326           Refer to ccache documentation for more details.
327
328           These initial settings are applied after ccache has been
329           compiled.
330
331 config BR2_CCACHE_USE_BASEDIR
332         bool "Use relative paths"
333         default y
334         help
335           Allow ccache to convert absolute paths within the output
336           directory into relative paths.
337
338           During the build, many -I include directives are given with an
339           absolute path. These absolute paths end up in the hashes that
340           are computed by ccache. Therefore, when you build from a
341           different directory, the hash will be different and the cached
342           object will not be used.
343
344           To improve cache performance, set this option to y. This
345           allows ccache to rewrite absolute paths within the output
346           directory into relative paths. Note that only paths within the
347           output directory will be rewritten; therefore, if you change
348           BR2_HOST_DIR to point outside the output directory and
349           subsequently move it to a different location, this will lead
350           to cache misses.
351
352           This option has as a result that the debug information in the
353           object files also has only relative paths. Therefore, make
354           sure you cd to the build directory before starting gdb. See
355           the section "COMPILING IN DIFFERENT DIRECTORIES" in the ccache
356           manual for more information.
357
358 endif
359
360 config BR2_ENABLE_DEBUG
361         bool "build packages with debugging symbols"
362         help
363           Build packages with debugging symbols enabled. All libraries
364           and binaries in the 'staging' directory will have debugging
365           symbols, which allows remote debugging even if libraries and
366           binaries are stripped on the target. Whether libraries and
367           binaries are stripped on the target is controlled by the
368           BR2_STRIP_* options below.
369
370 if BR2_ENABLE_DEBUG
371 choice
372         prompt "gcc debug level"
373         default BR2_DEBUG_2
374         help
375           Set the debug level for gcc
376
377 config BR2_DEBUG_1
378         bool "debug level 1"
379         help
380           Debug level 1 produces minimal information, enough for making
381           backtraces in parts of the program that you don't plan to
382           debug. This includes descriptions of functions and external
383           variables, but no information about local variables and no
384           line numbers.
385
386 config BR2_DEBUG_2
387         bool "debug level 2"
388         help
389           The default gcc debug level is 2
390
391 config BR2_DEBUG_3
392         bool "debug level 3"
393         help
394           Level 3 includes extra information, such as all the macro
395           definitions present in the program. Some debuggers support
396           macro expansion when you use -g3.
397 endchoice
398 endif
399
400 choice
401         prompt "strip command for binaries on target"
402         default BR2_STRIP_strip
403
404 config BR2_STRIP_strip
405         bool "strip"
406         depends on !BR2_PACKAGE_HOST_ELF2FLT
407         help
408           Binaries and libraries in the target filesystem will be
409           stripped using the normal 'strip' command. This allows to save
410           space, mainly by removing debugging symbols. Debugging symbols
411           on the target are needed for native debugging, but not when
412           remote debugging is used.
413
414 config BR2_STRIP_none
415         bool "none"
416         help
417           Do not strip binaries and libraries in the target filesystem.
418 endchoice
419
420 config BR2_STRIP_EXCLUDE_FILES
421         string "executables that should not be stripped"
422         depends on !BR2_STRIP_none
423         default ""
424         help
425           You may specify a space-separated list of binaries and
426           libraries here that should not be stripped on the target.
427
428 config BR2_STRIP_EXCLUDE_DIRS
429         string "directories that should be skipped when stripping"
430         depends on !BR2_STRIP_none
431         default ""
432         help
433           You may specify a space-separated list of directories that
434           should be skipped when stripping. Binaries and libraries in
435           these directories will not be touched. The directories should
436           be specified relative to the target directory, without leading
437           slash.
438
439 choice
440         prompt "gcc optimization level"
441         default BR2_OPTIMIZE_S
442         help
443           Set the optimization level for gcc
444
445 config BR2_OPTIMIZE_0
446         bool "optimization level 0"
447         help
448           Do not optimize. This is the default.
449
450 config BR2_OPTIMIZE_1
451         bool "optimization level 1"
452         help
453           Optimize. Optimizing compilation takes somewhat more time, and
454           a lot more memory for a large function. With -O, the compiler
455           tries to reduce code size and execution time, without
456           performing any optimizations that take a great deal of
457           compilation time. -O turns on the following optimization
458           flags: -fdefer-pop -fdelayed-branch -fguess-branch-probability
459           -fcprop-registers -floop-optimize -fif-conversion
460           -fif-conversion2 -ftree-ccp -ftree-dce -ftree-dominator-opts
461           -ftree-dse -ftree-ter -ftree-lrs -ftree-sra -ftree-copyrename
462           -ftree-fre -ftree-ch -funit-at-a-time -fmerge-constants. -O
463           also turns on -fomit-frame-pointer on machines where doing so
464           does not interfere with debugging.
465
466 config BR2_OPTIMIZE_2
467         bool "optimization level 2"
468         help
469           Optimize even more. GCC performs nearly all supported
470           optimizations that do not involve a space-speed tradeoff. The
471           compiler does not perform loop unrolling or function inlining
472           when you specify -O2. As compared to -O, this option increases
473           both compilation time and the performance of the generated
474           code. -O2 turns on all optimization flags specified by -O. It
475           also turns on the following optimization flags:
476           -fthread-jumps -fcrossjumping -foptimize-sibling-calls
477           -fcse-follow-jumps -fcse-skip-blocks -fgcse  -fgcse-lm
478           -fexpensive-optimizations -fstrength-reduce
479           -frerun-cse-after-loop -frerun-loop-opt -fcaller-saves
480           -fpeephole2 -fschedule-insns -fschedule-insns2
481           -fsched-interblock -fsched-spec -fregmove -fstrict-aliasing
482           -fdelete-null-pointer-checks -freorder-blocks
483           -freorder-functions -falign-functions -falign-jumps
484           -falign-loops -falign-labels -ftree-vrp -ftree-pre. Please
485           note the warning under -fgcse about invoking -O2 on programs
486           that use computed gotos.
487
488 config BR2_OPTIMIZE_3
489         bool "optimization level 3"
490         help
491           Optimize yet more. -O3 turns on all optimizations specified by
492           -O2 and also turns on the -finline-functions, -funswitch-loops
493           and -fgcse-after-reload options.
494
495 config BR2_OPTIMIZE_G
496         bool "optimize for debugging"
497         depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_8
498         help
499           Optimize for debugging. This enables optimizations that do not
500           interfere with debugging. It should be the optimization level
501           of choice for the standard edit-compile-debug cycle, offering
502           a reasonable level of optimization while maintaining fast
503           compilation and a good debugging experience.
504
505 config BR2_OPTIMIZE_S
506         bool "optimize for size"
507         help
508           Optimize for size. -Os enables all -O2 optimizations that do
509           not typically increase code size. It also performs further
510           optimizations designed to reduce code size. -Os disables the
511           following optimization flags: -falign-functions -falign-jumps
512           -falign-loops -falign-labels -freorder-blocks
513           -freorder-blocks-and-partition -fprefetch-loop-arrays
514           -ftree-vect-loop-version
515
516 endchoice
517
518 config BR2_GOOGLE_BREAKPAD_ENABLE
519         bool "Enable google-breakpad support"
520         select BR2_PACKAGE_GOOGLE_BREAKPAD
521         depends on BR2_INSTALL_LIBSTDCPP
522         depends on BR2_USE_WCHAR
523         depends on BR2_TOOLCHAIN_HAS_THREADS
524         depends on (BR2_TOOLCHAIN_USES_GLIBC || BR2_TOOLCHAIN_USES_UCLIBC)
525         depends on BR2_PACKAGE_GOOGLE_BREAKPAD_ARCH_SUPPORTS
526         help
527           This option will enable the use of google breakpad, a library
528           and tool suite that allows you to distribute an application to
529           users with compiler-provided debugging information removed,
530           record crashes in compact "minidump" files, send them back to
531           your server and produce C and C++ stack traces from these
532           minidumps. Breakpad can also write minidumps on request for
533           programs that have not crashed.
534
535 if BR2_GOOGLE_BREAKPAD_ENABLE
536
537 config BR2_GOOGLE_BREAKPAD_INCLUDE_FILES
538         string "List of executables and libraries to extract symbols from"
539         default ""
540         help
541           You may specify a space-separated list of binaries and
542           libraries with full paths relative to $(TARGET_DIR) of which
543           debug symbols will be dumped for further use with google
544           breakpad.
545
546           A directory structure that can be used by minidump-stackwalk
547           will be created at:
548
549           $(STAGING_DIR)/usr/share/google-breakpad-symbols
550
551 endif
552
553 choice
554         bool "build code with Stack Smashing Protection"
555         default BR2_SSP_ALL if BR2_ENABLE_SSP # legacy
556         depends on BR2_TOOLCHAIN_HAS_SSP
557         help
558           Enable stack smashing protection support using GCC's
559           -fstack-protector option family.
560
561           See
562           http://www.linuxfromscratch.org/hints/downloads/files/ssp.txt
563           for details.
564
565           Note that this requires the toolchain to have SSP support.
566           This is always the case for glibc and eglibc toolchain, but is
567           optional in uClibc toolchains.
568
569 config BR2_SSP_NONE
570         bool "None"
571         help
572           Disable stack-smashing protection.
573
574 config BR2_SSP_REGULAR
575         bool "-fstack-protector"
576         help
577           Emit extra code to check for buffer overflows, such as stack
578           smashing attacks. This is done by adding a guard variable to
579           functions with vulnerable objects. This includes functions
580           that call alloca, and functions with buffers larger than 8
581           bytes. The guards are initialized when a function is entered
582           and then checked when the function exits. If a guard check
583           fails, an error message is printed and the program exits.
584
585 config BR2_SSP_STRONG
586         bool "-fstack-protector-strong"
587         depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
588         help
589           Like -fstack-protector but includes additional functions to be
590           protected - those that have local array definitions, or have
591           references to local frame addresses.
592
593 comment "Stack Smashing Protection strong needs a toolchain w/ gcc >= 4.9"
594         depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
595
596 config BR2_SSP_ALL
597         bool "-fstack-protector-all"
598         help
599           Like -fstack-protector except that all functions are
600           protected. This option might have a significant performance
601           impact on the compiled binaries.
602
603 endchoice
604
605 comment "Stack Smashing Protection needs a toolchain w/ SSP"
606         depends on !BR2_TOOLCHAIN_HAS_SSP
607
608 choice
609         bool "libraries"
610         default BR2_SHARED_LIBS if BR2_BINFMT_SUPPORTS_SHARED
611         default BR2_STATIC_LIBS if !BR2_BINFMT_SUPPORTS_SHARED
612         help
613           Select the type of libraries you want to use on the target.
614
615           The default is to build dynamic libraries and use those on the
616           target filesystem, except when the architecture and/or the
617           selected binary format does not support shared libraries.
618
619 config BR2_STATIC_LIBS
620         bool "static only"
621         help
622           Build and use only static libraries. No shared libraries will
623           be installed on the target. This potentially increases your
624           code size and should only be used if you know what you are
625           doing. Note that some packages may not be available when this
626           option is enabled, due to their need for dynamic library
627           support.
628
629 config BR2_SHARED_LIBS
630         bool "shared only"
631         depends on BR2_BINFMT_SUPPORTS_SHARED
632         help
633           Build and use only shared libraries. This is the recommended
634           solution as it saves space and build time.
635
636 config BR2_SHARED_STATIC_LIBS
637         bool "both static and shared"
638         depends on BR2_BINFMT_SUPPORTS_SHARED
639         help
640           Build both shared and static libraries, but link executables
641           dynamically. While building both shared and static libraries
642           take more time and more disk space, having static libraries
643           may be useful to link some of the applications statically.
644
645 endchoice
646
647
648 config BR2_PACKAGE_OVERRIDE_FILE
649         string "location of a package override file"
650         default "$(CONFIG_DIR)/local.mk"
651         help
652           A package override file is a short makefile that contains
653           variable definitions of the form <pkg>_OVERRIDE_SRCDIR, which
654           allows to tell Buildroot to use an existing directory as the
655           source directory for a particular package. See the Buildroot
656           documentation for more details on this feature.
657
658 config BR2_GLOBAL_PATCH_DIR
659         string "global patch directories"
660         help
661           You may specify a space separated list of one or more
662           directories containing global package patches. For a specific
663           version <packageversion> of a specific package <packagename>,
664           patches are applied as follows:
665
666           First, the default Buildroot patch set for the package is
667           applied from the package's directory in Buildroot.
668
669           Then for every directory - <global-patch-dir> - that exists in
670           BR2_GLOBAL_PATCH_DIR, if the directory
671           <global-patch-dir>/<packagename>/<packageversion>/ exists,
672           then all *.patch files in this directory will be applied.
673
674           Otherwise, if the directory <global-patch-dir>/<packagename>
675           exists, then all *.patch files in the directory will be
676           applied.
677
678 menu "Advanced"
679
680 config BR2_COMPILER_PARANOID_UNSAFE_PATH
681         bool "paranoid check of library/header paths"
682         default y
683         help
684           By default, when this option is disabled, when the Buildroot
685           cross-compiler will encounter an unsafe library or header path
686           (such as /usr/include, or /usr/lib), the compiler will display
687           a warning.
688
689           By enabling this option, this warning is turned into an error,
690           which will completely abort the build when such unsafe paths
691           are encountered.
692
693           Note that this mechanism is available for both the internal
694           toolchain (through the toolchain wrapper and binutils patches)
695           and external toolchain backends (through the toolchain wrapper).
696
697 config BR2_REPRODUCIBLE
698         bool "Make the build reproducible (experimental)"
699         help
700           This option will remove all sources of non-reproducibility
701           from the build process. For a given Buildroot configuration,
702           this allows to generate exactly identical binaries from one
703           build to the other, including on different machines.
704
705           This is labeled as an experimental feature, as not all
706           packages behave properly to ensure reproducibility.
707
708 endmenu
709
710 endmenu
711
712 source "toolchain/Config.in"
713
714 source "system/Config.in"
715
716 source "linux/Config.in"
717
718 source "package/Config.in"
719
720 source "fs/Config.in"
721
722 source "boot/Config.in"
723
724 source "package/Config.in.host"
725
726 source "Config.in.legacy"
727
728 source "$BR2_BUILD_DIR/.br2-external.in"