1# Copyright (c) 2013 The Linux Foundation. All rights reserved. 2# Copyright (C) 2006-2010 OpenWrt.org 3# 4# This is free software, licensed under the GNU General Public License v2. 5# See /LICENSE for more information. 6# 7 8mainmenu "OpenWrt Configuration" 9 10config HAVE_DOT_CONFIG 11 bool 12 default y 13 14source "target/Config.in" 15 16menu "Target Images" 17 18 menuconfig TARGET_ROOTFS_INITRAMFS 19 bool "ramdisk" 20 default y if USES_INITRAMFS 21 help 22 Embed the rootfs into the kernel (initramfs) 23 24 choice 25 prompt "Compression" 26 default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_ar71xx 27 default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_ramips 28 default TARGET_INITRAMFS_COMPRESSION_NONE 29 depends TARGET_ROOTFS_INITRAMFS 30 help 31 Select ramdisk compression. 32 33 config TARGET_INITRAMFS_COMPRESSION_NONE 34 bool "none" 35 36 config TARGET_INITRAMFS_COMPRESSION_GZIP 37 bool "gzip" 38 39 config TARGET_INITRAMFS_COMPRESSION_BZIP2 40 bool "bzip2" 41 42 config TARGET_INITRAMFS_COMPRESSION_LZMA 43 bool "lzma" 44 45 config TARGET_INITRAMFS_COMPRESSION_LZO 46 bool "lzo" 47 48 config TARGET_INITRAMFS_COMPRESSION_XZ 49 bool "xz" 50 endchoice 51 52 config EXTERNAL_CPIO 53 string 54 prompt "Use external cpio" if TARGET_ROOTFS_INITRAMFS 55 default "" 56 help 57 Kernel uses specified external cpio as INITRAMFS_SOURCE 58 59 comment "Root filesystem archives" 60 61 config TARGET_ROOTFS_CPIOGZ 62 bool "cpio.gz" 63 default y if USES_CPIOGZ 64 help 65 Build a compressed cpio archive of the the root filesystem 66 67 config TARGET_ROOTFS_TARGZ 68 bool "tar.gz" 69 default y if USES_TARGZ 70 help 71 Build a compressed tar archive of the the root filesystem 72 73 comment "Root filesystem images" 74 75 config TARGET_ROOTFS_EXT4FS 76 bool "ext4" 77 default y if USES_EXT4 78 depends !TARGET_ROOTFS_INITRAMFS 79 help 80 Ext4 file system with some free space for uml images 81 82 config TARGET_ROOTFS_ISO 83 bool "iso" 84 default n 85 depends TARGET_ROOTFS_INITRAMFS && TARGET_x86 86 help 87 Create some bootable ISO image 88 89 config TARGET_ROOTFS_JFFS2 90 bool "jffs2" 91 default y if USES_JFFS2 92 depends !TARGET_ROOTFS_INITRAMFS 93 help 94 Build a jffs2 root filesystem 95 96 config TARGET_ROOTFS_JFFS2_NAND 97 bool "jffs2 for NAND" 98 default y if USES_JFFS2_NAND 99 depends on !TARGET_ROOTFS_INITRAMFS && USES_JFFS2_NAND 100 help 101 Build a jffs2 root filesystem for NAND flash 102 103 config TARGET_ROOTFS_SQUASHFS 104 bool "squashfs" 105 default y if USES_SQUASHFS 106 depends !TARGET_ROOTFS_INITRAMFS 107 help 108 Build a squashfs-lzma root filesystem 109 110 config TARGET_ROOTFS_UBIFS 111 bool "ubifs" 112 default y if USES_UBIFS 113 depends !TARGET_ROOTFS_INITRAMFS && USES_UBIFS 114 help 115 Build a ubifs root filesystem 116 117 comment "Image Options" 118 119 source "target/linux/*/image/Config.in" 120 121 config TARGET_ROOTFS_PARTSIZE 122 int "Root filesystem partition size (in MB)" 123 depends X86_GRUB_IMAGES || TARGET_ROOTFS_EXT4FS || TARGET_rb532 124 default 48 125 help 126 Allows you to change the root filesystem partition size 127 128 config TARGET_ROOTFS_MAXINODE 129 int "Maximum number of inodes in root filesystem" 130 depends TARGET_ROOTFS_EXT4FS 131 default 6000 132 help 133 Allows you to change the maximum number of inodes in the root filesystem 134 135 config TARGET_ROOTFS_RESERVED_PCT 136 int "Percentage of reserved blocks in root filesystem" 137 depends TARGET_ROOTFS_EXT4FS 138 default 5 139 help 140 Allows you to change the percentage of reserved blocks in the root filesystem 141 142endmenu 143 144menu "Global build settings" 145 146 config ALL 147 bool "Select all packages by default" 148 default n 149 150 comment "General build options" 151 152 config DISPLAY_SUPPORT 153 bool "Show packages that require graphics support (local or remote)" 154 default n 155 156 config BUILD_PATENTED 157 default y 158 bool "Compile with support for patented functionality" 159 help 160 When this option is disabled, software which provides patented functionality will not be built. 161 In case software provides optional support for patented functionality, 162 this optional support will get disabled for this package. 163 164 config BUILD_NLS 165 default n 166 bool "Compile with full language support" 167 help 168 When this option is enabled, packages are built with the full versions of iconv and GNU gettext 169 instead of the default OpenWrt stubs. If uClibc is used, it is also built with locale support. 170 171 config BUILD_STATIC_TOOLS 172 default n 173 bool "Attempt to link host utilities statically" 174 help 175 Linking host utilities like sed or firmware-utils statically increases the portability of the 176 generated ImageBuilder and SDK tarballs, however it may fail on some Linux distributions. 177 178 config SHADOW_PASSWORDS 179 bool 180 prompt "Enable shadow password support" 181 default y 182 help 183 Enable shadow password support. 184 185 config CLEAN_IPKG 186 bool 187 prompt "Remove ipkg/opkg status data files in final images" 188 default n 189 help 190 This removes all ipkg/opkg status data files from the target directory before building the root fs 191 192 config COLLECT_KERNEL_DEBUG 193 bool 194 prompt "Collect kernel debug information" 195 select KERNEL_DEBUG_INFO 196 default n 197 help 198 This collects debugging symbols from the kernel and all compiled modules. 199 Useful for release builds, so that kernel issues can be debugged offline later. 200 201 comment "Kernel build options" 202 203 config KERNEL_MODVERSIONS 204 bool "Compile the kernel with modversions enabled" 205 default n 206 207 config KERNEL_DEBUG_FS 208 bool "Compile the kernel with Debug FileSystem enabled" 209 default y 210 help 211 debugfs is a virtual file system that kernel developers use to put 212 debugging files into. Enable this option to be able to read and 213 write to these files. 214 215 config KERNEL_PERF_EVENTS 216 bool 217 default n 218 219 config KERNEL_PROFILING 220 bool "Compile the kernel with profiling enabled" 221 default n 222 select KERNEL_PERF_EVENTS 223 help 224 Enable the extended profiling support mechanisms used by profilers such 225 as OProfile. 226 227 config KERNEL_KALLSYMS 228 bool "Compile the kernel with symbol table information" 229 default n 230 help 231 This will give you more information in stack traces from kernel oopses 232 233 config KERNEL_FTRACE 234 bool "Compile the kernel with tracing support" 235 default n 236 237 config KERNEL_DYNAMIC_FTRACE 238 bool "Enable dynamic ftrace" 239 depends on KERNEL_FTRACE 240 default n 241 242 config KERNEL_ENABLE_DEFAULT_TRACERS 243 bool "Trace process context switches and events" 244 depends on KERNEL_FTRACE 245 default n 246 247 config KERNEL_FUNCTION_TRACER 248 bool "Enable function tracer" 249 depends on KERNEL_FTRACE 250 default n 251 252 config KERNEL_FUNCTION_PROFILER 253 bool "Enable function profilier" 254 depends on KERNEL_FUNCTION_TRACER 255 default n 256 257 config KERNEL_FUNCTION_GRAPH_TRACER 258 bool "Enable function graph tracer" 259 depends on KERNEL_FUNCTION_TRACER 260 default n 261 262 config KERNEL_IRQSOFF_TRACER 263 bool "Enable IRQSOFF tracer" 264 depends on KERNEL_FTRACE 265 default n 266 267 config KERNEL_PREEMPT_TRACER 268 bool "Enable PREMPTOFF tracer" 269 depends on KERNEL_FTRACE 270 default n 271 272 config KERNEL_DEBUG_KERNEL 273 bool 274 default n 275 276 config KERNEL_DEBUG_INFO 277 bool "Compile the kernel with debug information" 278 default n 279 select KERNEL_DEBUG_KERNEL 280 help 281 This will compile your kernel and modules with debug information. 282 283 config KERNEL_DEBUG_INFO_REDUCED 284 bool "Reduce debugging information" 285 depends on KERNEL_DEBUG_INFO 286 default y 287 288 config KERNEL_DEBUG_KMEMLEAK 289 bool "Compile the kernel with memory leak detector" 290 default n 291 292 config KERNEL_DEBUG_KMEMLEAK_DEFAULT_OFF 293 bool "Turn kernel memory leak detector off at boot by default" 294 default n 295 296 config KERNEL_DEBUG_LL_UART_NONE 297 bool 298 default n 299 depends on arm 300 301 config KERNEL_DEBUG_LL 302 bool 303 default n 304 depends on arm 305 select KERNEL_DEBUG_LL_UART_NONE 306 help 307 ARM low level debugging 308 309 config KERNEL_KPROBES 310 bool "Compile the kernel with kprobes support" 311 default n 312 313 config KERNEL_KEXEC 314 bool "Compile the kernel with kexec supportt" 315 default n 316 317 config KERNEL_EARLY_PRINTK 318 bool "Compile the kernel with early printk" 319 default n 320 depends on arm 321 select KERNEL_DEBUG_KERNEL 322 select KERNEL_DEBUG_LL if arm 323 help 324 Compile the kernel with early printk support. 325 This is only useful for debugging purposes to send messages 326 over the serial console in early boot. 327 Enable this to debug early boot problems. 328 329 config KERNEL_AIO 330 bool "Compile the kernel with asynchronous IO support" 331 default n 332 333 config KERNEL_MAGIC_SYSRQ 334 bool "Compile the kernel with SysRq support" 335 default y 336 337 config KERNEL_ELF_CORE 338 bool "Enable process core dump support" 339 default y 340 341 config KERNEL_PROVE_LOCKING 342 bool "Enable kernel lock checking" 343 select KERNEL_DEBUG_KERNEL 344 default n 345 346 config KERNEL_PRINTK_TIME 347 bool "Enable printk timestamps" 348 default y 349 350 config KERNEL_SLUB_DEBUG 351 bool 352 353 config KERNEL_SLUB_DEBUG_ON 354 bool 355 356 config KERNEL_SLABINFO 357 select KERNEL_SLUB_DEBUG 358 select KERNEL_SLUB_DEBUG_ON 359 bool "Enable /proc slab debug info" 360 361 config KERNEL_RELAY 362 bool 363 364 config KERNEL_SPARSE 365 bool "Enable sparse check during kernel build" 366 default n 367 368 config KERNEL_SKB_RECYCLER_PREALLOC 369 select KERNEL_SKB_RECYCLE_MAX_PREALLOC_SKBS 370 bool "Enable preallocation of skbs for recycler lists" 371 default n 372 373 config KERNEL_SKB_RECYCLE_MAX_PREALLOC_SKBS 374 depends on KERNEL_SKB_RECYCLER_PREALLOC 375 int "Number of preallocated skbs" 376 default 16384 377 378 comment "Package build options" 379 380 config DEBUG 381 bool 382 prompt "Compile packages with debugging info" 383 default n 384 help 385 Adds -g3 to the CFLAGS 386 387 config IPV6 388 bool 389 prompt "Enable IPv6 support in packages" 390 default y 391 help 392 Enable IPV6 support in packages (passes --enable-ipv6 to configure scripts). 393 394 config PKG_BUILD_PARALLEL 395 bool 396 prompt "Compile certain packages parallelized" 397 default y 398 help 399 This adds a -jX option to certain packages that are known to 400 behave well for parallel build. By default the package make processes 401 use the main jobserver, in which case this option only takes effect 402 when you add -jX to the make command. 403 404 If you are unsure, select N. 405 406 config PKG_BUILD_USE_JOBSERVER 407 bool 408 prompt "Use top-level make jobserver for packages" 409 depends on PKG_BUILD_PARALLEL 410 default y 411 help 412 This passes the main make process jobserver fds to package builds, 413 enabling full parallelization across different packages 414 415 Note that disabling this may overcommit CPU resources depending on the 416 -j level of the main make process, the number of package 417 submake jobs selected below and the number of actual CPUs present. 418 Example: If the main make is passed a -j4 and the submake -j 419 is also set to 4, we may end up with 16 parallel make processes 420 in the worst case. 421 422 423 config PKG_BUILD_JOBS 424 int 425 prompt "Number of package submake jobs (2-512)" 426 range 2 512 427 default 2 428 depends on PKG_BUILD_PARALLEL && !PKG_BUILD_USE_JOBSERVER 429 help 430 The number of jobs (-jX) to pass to packages submake. 431 432 config PKG_DEFAULT_PARALLEL 433 bool 434 prompt "Parallelize the default package build rule (May break build)" 435 depends on PKG_BUILD_PARALLEL 436 depends on BROKEN 437 default n 438 help 439 Always set the default package build rules to parallel build. 440 441 WARNING: This may break build or kill your cat, as it builds 442 packages with multiple jobs that are probably not tested in 443 a parallel build environment. 444 445 Only say Y, if you don't mind fixing broken packages. 446 Before reporting build bugs, set this to N and re-run the build. 447 448 config TOOLCHAIN_PARALLEL 449 bool 450 prompt "Parallelize the toolchain build (May break build)" 451 depends on PKG_BUILD_PARALLEL 452 depends on BROKEN 453 default n 454 help 455 Build the toolchain with parallel make jobs. 456 This speeds up the toolchain build on SMP machines, but may 457 break the build for certain toolchain versions. 458 459 If you say Y, toolchain build might break. 460 Before reporting build bugs, set this to N and re-run the build. 461 462 comment "Stripping options" 463 464 choice 465 prompt "Binary stripping method" 466 default USE_STRIP if EXTERNAL_TOOLCHAIN 467 default USE_STRIP if USE_GLIBC || USE_EGLIBC 468 default USE_SSTRIP 469 help 470 Select the binary stripping method you wish to use. 471 472 config NO_STRIP 473 bool "none" 474 help 475 This will install unstripped binaries (useful for native compiling/debugging) 476 477 config USE_STRIP 478 bool "strip" 479 help 480 This will install binaries stripped using strip from binutils 481 482 483 config USE_SSTRIP 484 bool "sstrip" 485 depends !DEBUG 486 depends !USE_GLIBC 487 depends !USE_EGLIBC 488 help 489 This will install binaries stripped using sstrip 490 endchoice 491 492 config STRIP_ARGS 493 string 494 prompt "Strip arguments" 495 depends USE_STRIP 496 default "--strip-unneeded --remove-section=.comment --remove-section=.note" if DEBUG 497 default "--strip-all" 498 help 499 Specifies arguments passed to the strip command when stripping binaries 500 501 config STRIP_KERNEL_EXPORTS 502 bool "Strip unnecessary exports from the kernel image" 503 help 504 Reduces kernel size by stripping unused kernel exports from the kernel image 505 Note that this might make the kernel incompatible with any kernel modules that 506 were not selected at the time the kernel image was created 507 508 config USE_MKLIBS 509 bool "Strip unnecessary functions from libraries" 510 help 511 Reduces libraries to only those functions that are necessary for using all 512 selected packages (including those selected as <M>) 513 Note that this will make the system libraries incompatible with most of the packages 514 that are not selected during the build process 515 516 choice 517 prompt "Preferred standard C++ library" 518 default USE_LIBSTDCXX if USE_EGLIBC 519 default USE_UCLIBCXX 520 help 521 Select the preferred standard C++ library for all packages that support this. 522 523 config USE_UCLIBCXX 524 bool "uClibc++" 525 526 config USE_LIBSTDCXX 527 bool "libstdc++" 528 529 endchoice 530 531 comment "Security Mitigations" 532 533 config ENABLE_SSP 534 bool "Enable stack protection (-fstack-protector)" 535 default y 536 select SSP_SUPPORT 537 help 538 If enabled, the packages and libc will be built with 539 stack protection, a security mitigation that prevents 540 buffer overflows from being exploitable. 541 542 config ENABLE_RELRO 543 bool "Enable RELRO (-Wl,-z,relro,-z,now)" 544 default y 545 help 546 If enabled, the packages and libc will be built with read only 547 relocation entries, preventing exploits from overwriting 548 sensitive sections in an ELF file that can lead to code execution. 549 550endmenu 551 552menuconfig DEVEL 553 bool "Advanced configuration options (for developers)" 554 default n 555 556 config BROKEN 557 bool "Show broken platforms / packages" if DEVEL 558 default n 559 560 config DOWNLOAD_FOLDER 561 string "Download folder" if DEVEL 562 default "" 563 564 config LOCALMIRROR 565 string "Local mirror for source packages" if DEVEL 566 default "" 567 568 config GIT_MIRROR 569 string "Git mirror" if DEVEL 570 default "" 571 572 config AUTOREBUILD 573 bool "Automatic rebuild of packages" if DEVEL 574 default y 575 help 576 Automatically rebuild packages when their files change 577 578 config BUILD_SUFFIX 579 string "Build suffix to append to the BUILD_DIR variable" if DEVEL 580 default "" 581 help 582 Build suffix to append to the BUILD_DIR variable, i.e: build_dir_suffix 583 584 config TARGET_ROOTFS_DIR 585 string "Override the default TARGET_ROOTFS_DIR variable" if DEVEL 586 default "" 587 help 588 Override the default TARGET_ROOTFS_DIR variable content $(BUILD_DIR) with custom path. 589 Use this option to re-define the location of the target root file system directory. 590 591 config CCACHE 592 bool "Use ccache" if DEVEL 593 default n 594 help 595 Compiler cache; see http://ccache.samba.org/ 596 597 config EXTERNAL_KERNEL_TREE 598 string "Use external kernel tree" if DEVEL 599 default "" 600 601 config KERNEL_GIT_CLONE_URI 602 string "Enter git repository to clone" if DEVEL 603 default "" 604 help 605 Enter the full git repository path i.e.: 606 git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git 607 This will create a git clone of the kernel in your build 608 directory. 609 610 config KERNEL_GIT_LOCAL_REPOSITORY 611 string "Enter path to local reference repository" if DEVEL 612 default "" 613 help 614 Enter a full pathname to a local reference git repository. 615 In this instance, the --refererence option of git clone will 616 be used thus creating a quick local clone of your repo. 617 618 config BUILD_LOG 619 bool "Enable log files during build process" if DEVEL 620 help 621 If enabled log files will be written to the ./log directory 622 623 config SRC_TREE_OVERRIDE 624 bool "Enable package source tree override" if DEVEL 625 help 626 If enabled, you can force a package to use a git tree as source 627 code instead of the normal tarball. Create a symlink 'git-src' 628 in the package directory, pointing to the .git tree that you want 629 to pull the source code from 630 631menuconfig TARGET_OPTIONS 632 bool "Target Options" if DEVEL 633 634 config TARGET_OPTIMIZATION 635 string "Target Optimizations" if TARGET_OPTIONS 636 default DEFAULT_TARGET_OPTIMIZATION 637 help 638 Optimizations to use when building for the target host. 639 640 config SOFT_FLOAT 641 bool "Use software floating point by default" if TARGET_OPTIONS 642 default y 643 depends on (arm || armeb || powerpc || mipsel || mips) && !HAS_FPU 644 help 645 If your target CPU does not have a Floating Point Unit (FPU) or a 646 kernel FPU emulator, but you still wish to support floating point 647 functions, then everything will need to be compiled with soft floating 648 point support (-msoft-float). 649 650 Most people will answer N. 651 652source "toolchain/Config.in" 653 654source "target/imagebuilder/Config.in" 655source "target/sdk/Config.in" 656source "target/toolchain/Config.in" 657 658source "tmp/.config-package.in" 659