Config.in 26 KB

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