OSDN Git Service

4e13cd0d2b7679b058f66aa5e155d7a19e575e60
[uclinux-h8/uclibc-ng.git] / extra / Configs / Config.in
1 #
2 # For a description of the syntax of this configuration file,
3 # see extra/config/Kconfig-language.txt
4 #
5
6 mainmenu "uClibc C Library Configuration"
7
8 config DESIRED_TARGET_ARCH
9         string
10         option env="ARCH"
11
12 choice
13         prompt "Target Architecture"
14         default TARGET_alpha if DESIRED_TARGET_ARCH = "alpha"
15         default TARGET_arm if DESIRED_TARGET_ARCH = "arm"
16         default TARGET_avr32 if DESIRED_TARGET_ARCH = "avr32"
17         default TARGET_bfin if DESIRED_TARGET_ARCH = "bfin"
18         default TARGET_cris if DESIRED_TARGET_ARCH = "cris"
19         default TARGET_e1 if DESIRED_TARGET_ARCH = "e1"
20         default TARGET_frv if DESIRED_TARGET_ARCH = "frv"
21         default TARGET_h8300 if DESIRED_TARGET_ARCH = "h8300"
22         default TARGET_hppa if DESIRED_TARGET_ARCH = "hppa"
23         default TARGET_i386 if DESIRED_TARGET_ARCH = "i386"
24         default TARGET_i960 if DESIRED_TARGET_ARCH = "i960"
25         default TARGET_ia64 if DESIRED_TARGET_ARCH = "ia64"
26         default TARGET_m68k if DESIRED_TARGET_ARCH = "m68k"
27         default TARGET_microblaze if DESIRED_TARGET_ARCH = "microblaze"
28         default TARGET_mips if DESIRED_TARGET_ARCH = "mips"
29         default TARGET_nios if DESIRED_TARGET_ARCH = "nios"
30         default TARGET_nios2 if DESIRED_TARGET_ARCH = "nios2"
31         default TARGET_powerpc if DESIRED_TARGET_ARCH = "powerpc"
32         default TARGET_sh if DESIRED_TARGET_ARCH = "sh"
33         default TARGET_sh64 if DESIRED_TARGET_ARCH = "sh64"
34         default TARGET_sparc if DESIRED_TARGET_ARCH = "sparc"
35         default TARGET_v850 if DESIRED_TARGET_ARCH = "v850"
36         default TARGET_vax if DESIRED_TARGET_ARCH = "vax"
37         default TARGET_x86_64 if DESIRED_TARGET_ARCH = "x86_64"
38         default TARGET_xtensa if DESIRED_TARGET_ARCH = "xtensa"
39         help
40           The architecture of your target.
41
42 config TARGET_alpha
43         bool "alpha"
44
45 config TARGET_arm
46         bool "arm"
47
48 config TARGET_avr32
49         bool "avr32"
50
51 config TARGET_bfin
52         bool "bfin"
53
54 config TARGET_cris
55         bool "cris"
56
57 config TARGET_e1
58         bool "e1 (BROKEN)"
59
60 config TARGET_frv
61         bool "frv (BROKEN)"
62
63 config TARGET_h8300
64         bool "h8300 (BROKEN)"
65
66 config TARGET_hppa
67         bool "hppa"
68
69 config TARGET_i386
70         bool "i386"
71
72 config TARGET_i960
73         bool "i960 (BROKEN)"
74
75 config TARGET_ia64
76         bool "ia64"
77
78 config TARGET_m68k
79         bool "m68k"
80
81 config TARGET_microblaze
82         bool "microblaze (BROKEN)"
83
84 config TARGET_mips
85         bool "mips"
86
87 config TARGET_nios
88         bool "nios"
89
90 config TARGET_nios2
91         bool "nios2"
92
93 config TARGET_powerpc
94         bool "powerpc"
95
96 config TARGET_sh
97         bool "superh"
98
99 config TARGET_sh64
100         bool "sh64"
101
102 config TARGET_sparc
103         bool "sparc"
104
105 config TARGET_v850
106         bool "v850 (BROKEN)"
107
108 config TARGET_vax
109         bool "vax"
110
111 config TARGET_x86_64
112         bool "x86_64"
113
114 config TARGET_xtensa
115         bool "xtensa"
116
117 endchoice
118
119
120 menu "Target Architecture Features and Options"
121
122 if TARGET_alpha
123 source "extra/Configs/Config.alpha"
124 endif
125
126 if TARGET_arm
127 source "extra/Configs/Config.arm"
128 endif
129
130 if TARGET_avr32
131 source "extra/Configs/Config.avr32"
132 endif
133
134 if TARGET_bfin
135 source "extra/Configs/Config.bfin"
136 endif
137
138 if TARGET_cris
139 source "extra/Configs/Config.cris"
140 endif
141
142 if TARGET_e1
143 source "extra/Configs/Config.e1"
144 endif
145
146 if TARGET_frv
147 source "extra/Configs/Config.frv"
148 endif
149
150 if TARGET_h8300
151 source "extra/Configs/Config.h8300"
152 endif
153
154 if TARGET_hppa
155 source "extra/Configs/Config.hppa"
156 endif
157
158 if TARGET_i386
159 source "extra/Configs/Config.i386"
160 endif
161
162 if TARGET_i960
163 source "extra/Configs/Config.i960"
164 endif
165
166 if TARGET_ia64
167 source "extra/Configs/Config.ia64"
168 endif
169
170 if TARGET_m68k
171 source "extra/Configs/Config.m68k"
172 endif
173
174 if TARGET_nios
175 source "extra/Configs/Config.nios"
176 endif
177
178 if TARGET_nios2
179 source "extra/Configs/Config.nios2"
180 endif
181
182 if TARGET_microblaze
183 source "extra/Configs/Config.microblaze"
184 endif
185
186 if TARGET_mips
187 source "extra/Configs/Config.mips"
188 endif
189
190 if TARGET_powerpc
191 source "extra/Configs/Config.powerpc"
192 endif
193
194 if TARGET_sh
195 source "extra/Configs/Config.sh"
196 endif
197
198 if TARGET_sh64
199 source "extra/Configs/Config.sh64"
200 endif
201
202 if TARGET_sparc
203 source "extra/Configs/Config.sparc"
204 endif
205
206 if TARGET_v850
207 source "extra/Configs/Config.v850"
208 endif
209
210 if TARGET_vax
211 source "extra/Configs/Config.vax"
212 endif
213
214 if TARGET_x86_64
215 source "extra/Configs/Config.x86_64"
216 endif
217
218 if TARGET_xtensa
219 source "extra/Configs/Config.xtensa"
220 endif
221
222 config TARGET_SUBARCH
223         string
224         default "e500" if CONFIG_E500
225         default "classic" if CONFIG_CLASSIC
226         default "sh4" if CONFIG_SH4
227         default ""
228
229 source "extra/Configs/Config.in.arch"
230
231 endmenu
232
233 menu "General Library Settings"
234
235 config HAVE_NO_PIC
236         bool
237         default n
238
239 config DOPIC
240         bool "Generate only Position Independent Code (PIC)"
241         default y
242         depends on !HAVE_NO_PIC
243         help
244           If you wish to build all of uClibc as PIC objects, then answer Y here.
245           If you are unsure, then you should answer N.
246
247 config ARCH_HAS_NO_SHARED
248         bool
249         default n
250
251 config ARCH_HAS_NO_LDSO
252         bool
253         select ARCH_HAS_NO_SHARED
254         default n
255
256 config HAVE_SHARED
257         bool "Enable shared libraries"
258         depends on !ARCH_HAS_NO_SHARED
259         default y
260         help
261           If you wish to build uClibc with support for shared libraries then
262           answer Y here.  If you only want to build uClibc as a static library,
263           then answer N.
264
265 config FORCE_SHAREABLE_TEXT_SEGMENTS
266         bool "Only load shared libraries which can share their text segment"
267         depends on HAVE_SHARED
268         select DOPIC
269         default n
270         help
271           If you answer Y here, the uClibc native shared library loader will
272           only load shared libraries, which do not need to modify any
273           non-writable segments. These libraries haven't set the DT_TEXTREL
274           tag in the dynamic section (==> objdump).
275           All your libraries must be compiled with -fPIC or -fpic, and all
276           assembler function must be written as position independent code (PIC).
277           Enabling this option will make uClibc's shared library loader a
278           little bit smaller and guarantee that no memory will be wasted by
279           badly coded shared libraries.
280
281 config LDSO_LDD_SUPPORT
282         bool "Native 'ldd' support"
283         depends on HAVE_SHARED
284         default y
285         help
286           Enable all the code needed to support traditional ldd,
287           which executes the shared library loader to resolve all dependencies
288           and then provide a list of shared libraries that are required for an
289           application to function.  Disabling this option will make uClibc's
290           shared library loader a little bit smaller.
291           Most people will answer Y.
292
293 config LDSO_CACHE_SUPPORT
294         bool "Enable library loader cache (ld.so.conf)"
295         depends on HAVE_SHARED
296         default y
297         help
298           Enable this to make use of /etc/ld.so.conf, the shared library loader
299           cache configuration file to support for non-standard library paths.
300           After updating this file, it is necessary to run 'ldconfig' to update
301           the /etc/ld.so.cache shared library loader cache file.
302
303 config LDSO_PRELOAD_FILE_SUPPORT
304         bool "Enable library loader preload file (ld.so.preload)"
305         depends on HAVE_SHARED
306         default n
307         help
308           Enable this to make use of /etc/ld.so.preload. This file contains a
309           whitespace separated list of shared libraries to be loaded before
310           the program.
311
312 config LDSO_BASE_FILENAME
313         string "Shared library loader naming prefix"
314         depends on HAVE_SHARED && (LDSO_CACHE_SUPPORT || LDSO_PRELOAD_FILE_SUPPORT)
315         default "ld.so"
316         help
317           If you wish to support both uClibc and glibc on the same system, it
318           is necessary to set this to something other than "ld.so" to avoid
319           conflicts with glibc, which also uses "ld.so".  This prevents both
320           libraries from using the same /etc/ld.so.* files.  If you wish to
321           support both uClibc and glibc on the same system then you should set
322           this to "ld-uClibc.so".
323
324           Most people will leave this set to the default of "ld.so".
325
326           WARNING: Changing the default prefix could cause problems with
327                    binutils' ld !
328
329 config UCLIBC_STATIC_LDCONFIG
330         bool "Link ldconfig statically"
331         depends on HAVE_SHARED
332         default y
333         help
334           Enable this option to statically link the ldconfig binary.
335
336           Making ldconfig static can be beneficial if you have a library
337           problem and need to use ldconfig to recover.  Sometimes it is
338           preferable to instead keep the size of the system down, in which
339           case you should disable this option.
340
341 config LDSO_RUNPATH
342         bool "Enable ELF RUNPATH tag support"
343         depends on HAVE_SHARED
344         default y if LDSO_CACHE_SUPPORT
345         default n if !LDSO_CACHE_SUPPORT
346         help
347           ELF's may have dynamic RPATH/RUNPATH tags.  These tags list paths
348           which extend the library search paths.  They are really only useful
349           if a package installs libraries in non standard locations and
350           ld.so.conf support is disabled.
351
352           Usage of RUNPATH tags is not too common, so disabling this feature
353           should be safe for most people.
354
355 config LDSO_SEARCH_INTERP_PATH
356         bool "Add ldso path to lib search path"
357         depends on HAVE_SHARED
358         default y
359         help
360           The ldso is told where it is being executed from and can use that
361           path to find related core libraries.  This is useful by default,
362           but can be annoying in a mixed development environment.
363
364           i.e. if the ldso is run from /foo/boo/ldso.so, it will start its
365           library search with /foo/boo/
366
367           If unsure, simply say Y here.
368
369 config UCLIBC_CTOR_DTOR
370         bool "Support global constructors and destructors"
371         default y
372         help
373           If you wish to build uClibc with support for global constructor
374           (ctor) and global destructor (dtor) support, then answer Y here.
375           When ctor/dtor support is enabled, binaries linked with uClibc must
376           also be linked with crtbegin.o and crtend.o which are provided by gcc
377           (the "*startfile:" and "*endfile:" settings in your gcc specs file
378           may need to be adjusted to include these files).  This support will
379           also add a small amount of additional size to each binary compiled vs
380           uClibc.  If you will be using uClibc with C++, or if you need the gcc
381           __attribute__((constructor)) and __attribute__((destructor)) to work,
382           then you definitely want to answer Y here.  If you don't need ctors
383           or dtors and want your binaries to be as small as possible, then
384           answer N.
385
386 config LDSO_GNU_HASH_SUPPORT
387         bool "Enable GNU hash style support"
388         depends on HAVE_SHARED
389         default n
390         help
391           Newest binutils support a new hash style named GNU-hash. The dynamic
392           linker will use the new GNU-hash section (.gnu.hash) for symbol lookup
393           if present into the ELF binaries, otherwise it will use the old SysV
394           hash style (.hash). This ensures that it is completely backward
395           compatible.
396           Further, being the hash table implementation self-contained into each
397           executable and shared libraries, objects with mixed hash style can
398           peacefully coexist in the same process.
399
400           If you want to use this new feature, answer Y
401
402 choice
403         prompt "Thread support"
404         #default UCLIBC_HAS_THREADS_NATIVE if (TARGET_alpha || TARGET_arm || TARGET_i386 || TARGET_mips || TARGET_powerpc || TARGET_sh || TARGET_sh64)
405         default HAS_NO_THREADS
406         help
407           If you want to compile uClibc with pthread support, then answer Y.
408           This will increase the size of uClibc by adding a bunch of locking
409           to critical data structures, and adding extra code to ensure that
410           functions are properly reentrant.
411
412 config HAS_NO_THREADS
413         bool "none"
414         help
415           Disable thread support.
416
417 config LINUXTHREADS_OLD
418         bool "older (stable) version of linuxthreads"
419         # linuxthreads and linuxthreads.old need nanosleep()
420         select UCLIBC_HAS_REALTIME
421         help
422           There are two versions of linuxthreads.  The older (stable) version
423           has been in uClibc for quite a long time but hasn't seen too many
424           updates other than bugfixes.
425
426
427 config LINUXTHREADS_NEW
428         bool "slightly newer version of linuxthreads"
429         help
430           The new version has not been tested much, and lacks ports for arches
431           which glibc does not support (like bfin/frv/etc...), but is based on
432           the latest code from glibc, so it may be the only choice for the
433           newer ports (like alpha/amd64/64bit arches and hppa).
434
435 config UCLIBC_HAS_THREADS_NATIVE
436         bool "Native POSIX Threading (NPTL)"
437         select UCLIBC_HAS_TLS
438         help
439           If you want to compile uClibc with NPTL support, then answer Y.
440
441           IMPORTANT NOTE!  NPTL requires a Linux 2.6 kernel, binutils
442           at least version 2.16 and GCC with at least version 4.1.0. NPTL
443           will not work with older versions of any above sources. If you
444           ignore any of these guidelines, you do so at your own risk. Do
445           not ask for help on any of the development mailing lists.
446
447           !!!! WARNING !!!! BIG FAT WARNING !!!! REALLY BIG FAT WARNING !!!!
448
449           This is experimental code and at times it may not even build and
450           even if it does it might decide to do random damage. This code is
451           potentially hazardous to your health and sanity. It will remain
452           that way until further notice at which point this notice will
453           disappear. Thank you for your support and for not smoking.
454
455 endchoice
456
457 config UCLIBC_HAS_THREADS
458         def_bool y if !HAS_NO_THREADS
459
460 config UCLIBC_HAS_TLS
461         bool "Thread-Local Storage"
462         depends on UCLIBC_HAS_THREADS_NATIVE
463         default n
464         help
465           If you want to enable TLS support then answer Y.
466           This is fast an efficient way to store per-thread local data
467           which is not on stack. It needs __thread support enabled in
468           gcc.
469
470 config PTHREADS_DEBUG_SUPPORT
471         bool "Build pthreads debugging support"
472         default n
473         depends on UCLIBC_HAS_THREADS
474         help
475           Say Y here if you wish to be able to debug applications that use
476           uClibc's pthreads library.  By enabling this option, a library
477           named libthread_db will be built.  This library will be dlopen()'d
478           by gdb and will allow gdb to debug the threads in your application.
479
480           IMPORTANT NOTE!  Because gdb must dlopen() the libthread_db library,
481           you must compile gdb with uClibc in order for pthread debugging to
482           work properly.
483
484           If you are doing development and want to debug applications using
485           uClibc's pthread library, answer Y.  Otherwise, answer N.
486
487
488 config UCLIBC_HAS_SYSLOG
489         bool "Syslog support"
490         default y
491         depends on UCLIBC_HAS_NETWORK_SUPPORT
492         select UCLIBC_HAS_SOCKET
493         help
494           Support sending messages to the system logger.
495           This requires socket-support.
496
497 config UCLIBC_HAS_LFS
498         bool "Large File Support"
499         default y
500         help
501           If you wish to build uClibc with support for accessing large files
502           (i.e. files greater then 2 GiB) then answer Y.  Do not enable this
503           if you are using an older Linux kernel (2.0.x) that lacks large file
504           support.  Enabling this option will increase the size of uClibc.
505
506 choice
507         prompt "Malloc Implementation"
508         default MALLOC if ! ARCH_USE_MMU
509         default MALLOC_STANDARD if ARCH_USE_MMU
510
511 config MALLOC
512         bool "malloc"
513         help
514           "malloc" use mmap for all allocations and so works very well on
515           MMU-less systems that do not support the brk() system call.   It is
516           pretty smart about reusing already allocated memory, and minimizing
517           memory wastage.
518           This is the default for uClinux MMU-less systems.
519
520 config MALLOC_SIMPLE
521         bool "malloc-simple"
522         help
523           "malloc-simple" is trivially simple and slow as molasses.  It
524           was written from scratch for uClibc, and is the simplest possible
525           (and therefore smallest) malloc implementation.
526
527           This uses only the mmap() system call to allocate and free memory,
528           and does not use the brk() system call at all, making it a fine
529           choice for MMU-less systems with very limited memory.  It's 100%
530           standards compliant, thread safe, very small, and releases freed
531           memory back to the OS immediately rather than keeping it in the
532           process's heap for reallocation.  It is also VERY SLOW.
533
534 config MALLOC_STANDARD
535         bool "malloc-standard"
536         depends on ARCH_USE_MMU
537         help
538           "malloc-standard" is derived from the public domain dlmalloc
539           implementation by Doug Lea.  It is quite fast, and is pretty smart
540           about reusing already allocated memory, and minimizing memory
541           wastage.  This uses brk() for small allocations, while using mmap()
542           for larger allocations.  This is the default malloc implementation
543           for uClibc.
544
545           If unsure, answer "malloc-standard".
546
547 endchoice
548
549 config MALLOC_GLIBC_COMPAT
550         bool "Malloc returns live pointer for malloc(0)"
551         default n
552         help
553           The behavior of malloc(0) is listed as implementation-defined by
554           SuSv3.  Glibc returns a valid pointer to something, while uClibc
555           normally returns NULL.  I personally feel glibc's behavior is
556           not particularly safe, and allows buggy applications to hide very
557           serious problems.
558
559           When this option is enabled, uClibc will act just like glibc, and
560           return a live pointer when someone calls malloc(0).  This pointer
561           provides a malloc'ed area with a size of 1 byte.  This feature is
562           mostly useful when dealing with applications using autoconf's broken
563           AC_FUNC_MALLOC macro (which redefines malloc as rpl_malloc if it
564           does not detect glibc style returning-a-valid-pointer-for-malloc(0)
565           behavior).  Most people can safely answer N.
566
567 config UCLIBC_DYNAMIC_ATEXIT
568         bool "Dynamic atexit() Support"
569         default y
570         help
571           When this option is enabled, uClibc will support an infinite number,
572           of atexit() and on_exit() functions, limited only by your available
573           memory.  This can be important when uClibc is used with C++, since
574           global destructors are implemented via atexit(), and it is quite
575           possible to exceed the default number when this option is disabled.
576           Enabling this option adds a few bytes, and more significantly makes
577           atexit and on_exit depend on malloc, which can be bad when compiling
578           static executables.
579
580           Unless you use uClibc with C++, you should probably answer N.
581
582 config COMPAT_ATEXIT
583         bool "Old (visible) atexit Support"
584         default n
585         help
586           Enable this option if you want to update from 0.9.28 to git/0.9.29,
587           else you will be missing atexit() until you rebuild all apps.
588
589 config UCLIBC_SUSV3_LEGACY
590         bool "Enable SuSv3 LEGACY functions"
591         default n
592         #vfork,
593         # h_errno
594         # gethostbyaddr
595         # gethostbyname
596         help
597           Enable this option if you want to have SuSv3 LEGACY functions
598           in the library, else they are replaced by SuSv3 proposed macros.
599           Currently applies to:
600
601           bcmp, bcopy, bzero, index, rindex, ftime,
602           bsd_signal, (ecvt), (fcvt), gcvt, (getcontext),
603           (getwd), (makecontext),
604           mktemp, (pthread_attr_getstackaddr), (pthread_attr_setstackaddr),
605           scalb, (setcontext), (swapcontext), ualarm, usleep,
606           wcswcs.
607
608           WARNING! ABI incompatibility.
609
610 config UCLIBC_SUSV3_LEGACY_MACROS
611         bool "Enable SuSv3 LEGACY macros"
612         default n
613         help
614           Enable this option if you want to have SuSv3 LEGACY macros.
615           Currently applies to bcopy/bzero/bcmp/index/rindex et al.
616           WARNING! ABI incompatibility.
617
618 config UCLIBC_SUSV4_LEGACY
619         bool "Enable SuSv4 LEGACY or obsolescent functions"
620         default n
621         help
622           Enable this option if you want to have SuSv4 LEGACY functions
623           and macros in the library.
624           Currently applies to:
625
626           - XSI functions:
627             _longjmp, _setjmp, _tolower, _toupper, ftw, getitimer,
628             gettimeofday, isascii, pthread_getconcurrency,
629             pthread_setconcurrency, setitimer, setpgrp, sighold,
630             sigignore, sigpause, sigrelse, sigset, siginterrupt,
631             tempnam, toascii, ulimit.
632
633           - Base functions:
634             asctime, asctime_r, ctime, ctime_r, gets, rand_r,
635             tmpnam, utime.
636
637           WARNING! ABI incompatibility.
638
639 config UCLIBC_HAS_STUBS
640         bool "Provide stubs for unavailable functionality"
641         default n
642         help
643           With this option uClibc provides non-functional stubs for
644           functions which are impossible to implement on the target
645           architecture. Otherwise, such functions are simply omitted.
646
647           As of 2008-07, this option makes uClibc provide fork() stub
648           on NOMMU targets. It always sets errno to ENOSYS and returns -1.
649
650           This may be useful if you port a lot of software and cannot
651           audit all of it and replace or disable fork() usage.
652           With this option, a program which uses fork() will build
653           successfully. Of course, it may be useless if fork()
654           is essential for its operation.
655
656 config UCLIBC_HAS_SHADOW
657         bool "Shadow Password Support"
658         default y
659         help
660           Answer N if you do not need shadow password support.
661           Most people will answer Y.
662
663 config UCLIBC_HAS_PROGRAM_INVOCATION_NAME
664         bool "Support for program_invocation_name"
665         default n
666         help
667           Support for the GNU-specific program_invocation_name and
668           program_invocation_short_name strings.  Some GNU packages
669           (like tar and coreutils) utilize these for extra useful
670           output, but in general are not required.
671
672           At startup, these external strings are automatically set
673           up based on the value of ARGV[0].
674
675           If unsure, just answer N.
676
677 config UCLIBC_HAS___PROGNAME
678         bool "Support for __progname"
679         default y
680         depends on UCLIBC_HAS_PROGRAM_INVOCATION_NAME
681         help
682           Some packages (like openssh) like to peek into internal libc
683           symbols to make their output a bit more user friendly.
684
685           At startup, __progname is automatically set up based on the
686           value of ARGV[0].
687
688           If unsure, just answer N.
689
690 config UCLIBC_HAS_PTY
691         bool "Support for pseudo-terminals"
692         default y
693         help
694           This enables support for pseudo-terminals (see man 4 pts
695           and man 7 pty).
696
697           If unsure, just answer Y.
698
699 config ASSUME_DEVPTS
700         bool "Assume that /dev/pts is a devpts or devfs file system"
701         default y
702         depends on UCLIBC_HAS_PTY
703         help
704           Enable this if /dev/pts is on a devpts or devfs filesystem.  Both
705           these filesystems automatically manage permissions on the /dev/pts
706           devices.  You may need to mount your devpts or devfs filesystem on
707           /dev/pts for this to work.
708
709           Most people should answer Y.
710
711 config UNIX98PTY_ONLY
712         bool "Support only Unix 98 PTYs"
713         default y
714         depends on UCLIBC_HAS_PTY
715         help
716           If you want to support only Unix 98 PTYs enable this.  Some older
717           applications may need this disabled and will thus use legacy BSD
718           style PTY handling which is more complex and also bigger than
719           Unix 98 PTY handling.
720
721           For most current programs, you can generally answer Y.
722
723 if UNIX98PTY_ONLY
724 config UCLIBC_HAS_GETPT
725         bool "Support getpt() (glibc-compat)"
726         default n
727         depends on UCLIBC_HAS_PTY
728         help
729           Some packages may need getpt().
730           All of those are non-standard and can be considered
731           GNU/libc compatibility.
732           Either use posix_openpt() or just open /dev/ptmx yourself.
733
734           If unsure, just say N.
735 endif
736
737 if !UNIX98PTY_ONLY
738 # Have to use __libc_ptyname{1,2}[] and related bloat
739 config UCLIBC_HAS_GETPT
740         def_bool y
741 endif
742
743 config UCLIBC_HAS_LIBUTIL
744         bool "Provide libutil library and functions"
745         depends on UCLIBC_HAS_PTY
746         default n
747         help
748           Provide a libutil library.
749           This non-standard conforming library provides the following
750           utility functions:
751
752           forkpty(): combines openpty(), fork(2), and login_tty() to
753                        create a new process operating in a pseudo-terminal.
754           login(): write utmp and wtmp entries
755           login_tty(): prepares for a login on the tty fd by creating a
756                        new session, making fd the controlling terminal for
757                        the calling process, setting fd to be the standard
758                        input, output, and error streams of the current
759                        process, and closing fd.
760           logout(): write utmp and wtmp entries
761           logwtmp(): constructs a utmp structure and calls updwtmp() to
762                        append the structure to the utmp file.
763           openpty(): finds an available pseudo-terminal and returns
764                        file descriptors for the master and slave
765
766           This library adds about 3k-4k to your system.
767
768 config UCLIBC_HAS_TM_EXTENSIONS
769         bool "Support 'struct tm' timezone extension fields"
770         default y
771         help
772           Enabling this option adds fields to 'struct tm' in time.h for
773           tracking the number of seconds east of UTC, and an abbreviation for
774           the current timezone.  These fields are not specified by the SuSv3
775           standard, but they are commonly used in both GNU and BSD application
776           code.
777
778           To strictly follow the SuSv3 standard, leave this disabled.
779           Most people will probably want to answer Y.
780
781 config UCLIBC_HAS_TZ_CACHING
782         bool "Enable caching of the last valid timezone 'TZ' string"
783         default y
784         help
785           Answer Y to enable caching of the last valid 'TZ' string describing
786           the timezone setting.  This allows a quick string compare to avoid
787           repeated parsing of unchanged 'TZ' strings when tzset() is called.
788
789           Most people will answer Y.
790
791 config UCLIBC_HAS_TZ_FILE
792         bool "Enable '/etc/TZ' file support to set a default timezone (uClibc-specific)"
793         default y
794         help
795           Answer Y to enable the setting of a default timezone for uClibc.
796
797           Ordinarily, uClibc gets the timezone information exclusively from the
798           'TZ' environment variable.  In particular, there is no support for
799           the zoneinfo directory tree or the /etc/timezone file used by glibc.
800
801           With this option enabled, uClibc will use the value stored in the
802           file '/etc/TZ' (default path) to obtain timezone information if the
803           'TZ' environment variable is missing or has an invalid value.  The
804           file consists of a single line (newline required) of text describing
805           the timezone in the format specified for the TZ environment variable.
806
807           Doing 'echo CST6CDT > /etc/TZ' is enough to create a valid file.
808           See
809           http://www.opengroup.org/onlinepubs/007904975/basedefs/xbd_chap08.html
810           for details on valid settings of 'TZ'.
811
812           Most people will answer Y.
813
814 config UCLIBC_HAS_TZ_FILE_READ_MANY
815         bool "Repeatedly read the '/etc/TZ' file"
816         depends on UCLIBC_HAS_TZ_FILE
817         default y
818         help
819           Answer Y to enable repeated reading of the '/etc/TZ' file even after
820           a valid value has been read.  This incurs the overhead of an
821           open/read/close for each tzset() call (explicit or implied).  However,
822           setting this will allow applications to update their timezone
823           information if the contents of the file change.
824
825           Most people will answer Y.
826
827 config UCLIBC_TZ_FILE_PATH
828         string "Path to the 'TZ' file for setting the global timezone"
829         depends on UCLIBC_HAS_TZ_FILE
830         default "/etc/TZ"
831         help
832           This is the path to the 'TZ' file.
833
834           Most people will use the default of '/etc/TZ'.
835
836 endmenu
837
838 menu "Advanced Library Settings"
839
840 config UCLIBC_PWD_BUFFER_SIZE
841         int "Buffer size for getpwnam() and friends"
842         default 256
843         range 12 1024
844         help
845           This sets the value of the buffer size for getpwnam() and friends.
846           By default, this is 256. (For reference, glibc uses 1024).
847           The value can be found using sysconf() with the _SC_GETPW_R_SIZE_MAX
848           parameter.
849
850 config UCLIBC_GRP_BUFFER_SIZE
851         int "Buffer size for getgrnam() and friends"
852         default 256
853         range 12 1024
854         help
855           This sets the value of the buffer size for getgrnam() and friends.
856           By default, this is 256. (For reference, glibc uses 1024).
857           The value can be found using sysconf() with the _SC_GETGR_R_SIZE_MAX
858           parameter.
859
860 comment "Support various families of functions"
861
862 config UCLIBC_LINUX_MODULE_24
863         bool "Linux kernel module functions"
864         default !(TARGET_bfin)
865         help
866           create_module, query_module
867           are used in linux (prior to 2.6) for loadable kernel modules.
868
869           Say N if you do not use kernel modules, or you only support
870           Linux 2.6+.
871
872 config UCLIBC_LINUX_SPECIFIC
873         bool "Linux specific functions"
874         default y
875         help
876           capget(), capset(), fstatfs(), inotify_*(), ioperm(), iopl(),
877           madvise(), modify_ldt(), personality(), prctl()/arch_prctl(),
878           ppoll(), readahead(), reboot(), remap_file_pages(),
879           sched_getaffinity(), sched_setaffinity(), sendfile(),
880           setfsgid(), setfsuid(), setresuid(),
881           splice(), vmsplice(), tee(), signalfd(), swapoff(), swapon(),
882           sync_file_range(), sysctl(), sysinfo(), vhangup()
883
884 config UCLIBC_HAS_GNU_ERROR
885         bool "Support GNU extensions for error-reporting"
886         default y
887         help
888           Support for the GNU-specific error(), error_at_line(),
889           void (* error_print_progname)(), error_message_count
890           functions and variables.  Some GNU packages
891           utilize these for extra useful output, but in general
892           are not required.
893
894           If unsure, just answer N.
895
896 config UCLIBC_BSD_SPECIFIC
897         bool "BSD specific functions"
898         default y
899         help
900           mincore(), getdomainname(), setdomainname()
901
902           If unsure, say N.
903
904 config UCLIBC_HAS_BSD_ERR
905         bool "BSD err functions"
906         default y
907         help
908           These functions are non-standard BSD extensions.
909           err(), errx(), warn(), warnx(), verr(), verrx(), vwarn(), vwarnx()
910
911           If unsure, say N.
912
913 config UCLIBC_HAS_OBSOLETE_BSD_SIGNAL
914         bool "BSD obsolete signal functions"
915         default n
916         help
917           These functions are provided as a compatibility interface for
918           programs that make use of the historical System V signal API.
919           This API is obsolete:
920           new applications should use the POSIX signal API (sigaction(2),
921           sigprocmask(2), etc.).
922           Affected functions:
923
924           sigset(), sighold(), sigrelse(), sigignore()
925
926           If unsure, say N.
927
928 config UCLIBC_HAS_OBSOLETE_SYSV_SIGNAL
929         bool "SYSV obsolete signal functions"
930         default n
931         help
932           Use of sysv_signal() should be avoided; use sigaction(2) instead.
933
934           If unsure, say N.
935
936 config UCLIBC_NTP_LEGACY
937         bool "ntp_*() aliases"
938         default n
939         help
940           Provide legacy aliases for ntp functions:
941           ntp_adjtime(), ntp_gettime()
942
943           It is safe to say N here.
944
945 config UCLIBC_SV4_DEPRECATED
946         bool "Enable SVr4 deprecated functions"
947         default n
948         help
949           These functions are DEPRECATED in System V release 4.
950           Say N unless you desparately need one of the functions below:
951
952           ustat() [use statfs(2) in your code instead]
953
954 config UCLIBC_HAS_REALTIME
955         bool "Realtime-related family of SUSv functions"
956         default y
957         help
958           These functions are part of the Timers option and need not
959           be available on all implementations.
960           Includes AIO, message-queue, scheduler, semaphore functions:
961
962           aio.h
963           mqueue.h
964           sched.h
965           semaphore.h
966
967           aio_cancel()
968           aio_error()
969           aio_fsync()
970           aio_read()
971           lio_listio()
972           aio_return()
973           aio_suspend()
974           aio_write()
975           clock_getres(), clock_gettime(), clock_settime()
976           fdatasync()
977           mlockall(), munlockall()
978           mlock(), munlock()
979           mq_close()
980           mq_getattr()
981           mq_notify()
982           mq_open()
983           mq_receive()
984           mq_send()
985           mq_setattr()
986           mq_unlink()
987           nanosleep()
988           sched_getparam()
989           sched_get_priority_max(), sched_get_priority_min()
990           sched_getscheduler()
991           sched_rr_get_interval()
992           sched_setparam()
993           sched_setscheduler()
994           sem_close()
995           sem_destroy()
996           sem_getvalue()
997           sem_init()
998           sem_open()
999           sem_post()
1000           sem_trywait(), sem_wait()
1001           sem_unlink()
1002           sigqueue()
1003           sigtimedwait(), sigwaitinfo()
1004           timer_create()
1005           timer_delete()
1006           timer_getoverrun(), timer_gettime(), timer_settime()
1007
1008 config UCLIBC_HAS_ADVANCED_REALTIME
1009         bool "Advanced realtime-related family of SUSv functions"
1010         default y
1011         depends on UCLIBC_HAS_REALTIME
1012         help
1013           These functions are part of the Timers option and need not
1014           be available on all implementations.
1015
1016           clock_getcpuclockid()
1017           clock_nanosleep()
1018           mq_timedreceive()
1019           mq_timedsend()
1020           posix_fadvise()
1021           posix_fallocate()
1022           posix_madvise()
1023           posix_memalign()
1024           posix_mem_offset()
1025           posix_spawnattr_destroy(), posix_spawnattr_init()
1026           posix_spawnattr_getflags(), posix_spawnattr_setflags()
1027           posix_spawnattr_getpgroup(), posix_spawnattr_setpgroup()
1028           posix_spawnattr_getschedparam(), posix_spawnattr_setschedparam()
1029           posix_spawnattr_getschedpolicy(), posix_spawnattr_setschedpolicy()
1030           posix_spawnattr_getsigdefault(), posix_spawnattr_setsigdefault()
1031           posix_spawnattr_getsigmask(), posix_spawnattr_setsigmask()
1032           posix_spawn_file_actions_addclose()
1033           posix_spawn_file_actions_adddup2()
1034           posix_spawn_file_actions_addopen()
1035           posix_spawn_file_actions_destroy()
1036           posix_spawn_file_actions_init()
1037           posix_spawn()
1038           posix_spawnp()
1039           posix_typed_mem_get_info()
1040           pthread_mutex_timedlock()
1041           sem_timedwait()
1042
1043 #config UCLIBC_HAS_TERMIOS
1044 #       bool "termios functions"
1045 #       default y
1046 #       help
1047 #         Get and set terminal attributes, line control, get and set baud
1048 #         rate.
1049 #         termios(), tcgetattr(), tcsetattr(), tcsendbreak(), tcdrain(),
1050 #         tcflush(), tcflow(), cfmakeraw(), cfgetospeed(), cfgetispeed(),
1051 #         cfsetispeed(), cfsetospeed(), cfsetspeed()
1052 #
1053 #         If unsure, say Y.
1054
1055 config UCLIBC_HAS_EPOLL
1056         bool "epoll"
1057         default y
1058         help
1059           epoll_create(), epoll_ctl(), epoll_wait() functions.
1060
1061 config UCLIBC_HAS_XATTR
1062         bool "Extended Attributes"
1063         default y
1064         help
1065           Extended Attributes support.
1066
1067           setxattr()
1068           lsetxattr()
1069           fsetxattr()
1070           getxattr()
1071           lgetxattr()
1072           fgetxattr()
1073           listxattr()
1074           llistxattr()
1075           flistxattr()
1076           removexattr()
1077           lremovexattr()
1078           fremovexattr()
1079
1080           Say N unless you need support for extended attributes and the
1081           filesystems do actually support them.
1082
1083 config UCLIBC_HAS_PROFILING
1084         bool "Profiling support"
1085         default y
1086         help
1087           gcc's -finstrument-functions needs these.
1088
1089           Most people can safely answer N.
1090
1091 config UCLIBC_HAS_CRYPT_IMPL
1092         bool "libcrypt support"
1093         default y
1094         help
1095           libcrypt contains crypt(), setkey() and encrypt()
1096
1097 config UCLIBC_HAS_CRYPT_STUB
1098         bool "libcrypt stubs"
1099         default y
1100         depends on !UCLIBC_HAS_CRYPT_IMPL
1101         help
1102           Standards mandate that crypt(3) provides a stub if it is unavailable.
1103           If you enable this option then stubs for
1104             crypt(), setkey() and encrypt()
1105           will be provided in a small libcrypt.
1106
1107 config UCLIBC_HAS_CRYPT
1108         def_bool y
1109         depends on UCLIBC_HAS_CRYPT_IMPL || UCLIBC_HAS_CRYPT_STUB
1110 endmenu
1111
1112 menuconfig UCLIBC_HAS_NETWORK_SUPPORT
1113         bool "Networking Support"
1114         default y
1115         help
1116           Say N here if you do not need network support.
1117
1118 if UCLIBC_HAS_NETWORK_SUPPORT
1119 config UCLIBC_HAS_SOCKET
1120         bool "Socket support"
1121         default y
1122         help
1123           If you want to include support for sockets then answer Y.
1124
1125 config UCLIBC_HAS_IPV4
1126         bool "IP version 4 support"
1127         default y
1128         select UCLIBC_HAS_SOCKET
1129         help
1130           If you want to include support for the Internet Protocol
1131           (IP version 4) then answer Y.
1132
1133           Most people will say Y.
1134
1135 config UCLIBC_HAS_IPV6
1136         bool "IP version 6 support"
1137         default n
1138         select UCLIBC_HAS_SOCKET
1139         help
1140           If you want to include support for the next version of the Internet
1141           Protocol (IP version 6) then answer Y.
1142
1143           Most people should answer N.
1144
1145 config UCLIBC_HAS_RPC
1146         bool "Remote Procedure Call (RPC) support"
1147         default n
1148         # RPC+socket-ipvX doesn't currently work.
1149         depends on UCLIBC_HAS_IPV4 || UCLIBC_HAS_IPV6
1150         help
1151           If you want to include RPC support, enable this.  RPC is rarely used
1152           for anything except for the NFS filesystem.  Unless you plan to use
1153           NFS, you can probably leave this set to N and save some space.
1154
1155           If you need to use NFS then you should answer Y.
1156
1157 config UCLIBC_HAS_FULL_RPC
1158         bool "Full RPC support"
1159         depends on UCLIBC_HAS_RPC
1160         default y if !HAVE_SHARED
1161         help
1162           Normally we enable just enough RPC support for things like rshd and
1163           nfs mounts to work.  If you find you need the rest of the RPC stuff,
1164           then enable this option.  Most people can safely answer N.
1165
1166 config UCLIBC_HAS_REENTRANT_RPC
1167         bool "Reentrant RPC support"
1168         depends on UCLIBC_HAS_RPC
1169         default y if !HAVE_SHARED
1170         help
1171           Most packages utilize the normal (non-reentrant) RPC functions, but
1172           some (like exportfs from nfs-utils) need these reentrant versions.
1173
1174           Most people can safely answer N.
1175
1176 config UCLIBC_USE_NETLINK
1177         bool "Use netlink to query interfaces"
1178         default n
1179         depends on UCLIBC_HAS_SOCKET
1180         help
1181           In newer versions of Linux (2.4.17+), support was added for querying
1182           network device information via netlink rather than the old style
1183           ioctl's.  Most of the time, the older ioctl style is sufficient (and
1184           it is smaller than netlink), but if you find that not all of your
1185           devices are being returned by the if_nameindex() function, you will
1186           have to use the netlink implementation.
1187
1188           Most people can safely answer N.
1189
1190 config UCLIBC_SUPPORT_AI_ADDRCONFIG
1191         bool "Support the AI_ADDRCONFIG flag"
1192         depends on UCLIBC_USE_NETLINK
1193         default n
1194         help
1195           The implementation of AI_ADDRCONFIG is aligned with the glibc
1196           implementation using netlink to query interfaces to find both
1197           ipv4 and ipv6 support. This is only needed if an application uses
1198           the AI_ADDRCONFIG flag.
1199
1200           Most people can safely answer N.
1201
1202 config UCLIBC_HAS_BSD_RES_CLOSE
1203         bool "Support res_close() (bsd-compat)"
1204         default n
1205         help
1206           Answer Y if you desperately want to support BSD compatibility in
1207           the network code.
1208
1209           Most people will say N.
1210
1211 config UCLIBC_HAS_COMPAT_RES_STATE
1212         bool "Use compatible but bloated _res"
1213         default y
1214         help
1215           Answer Y if you build network utilities and they muck with resolver
1216           internals a lot (_res global structure). uclibc does not use most
1217           of _res.XXX fields, and with this option OFF they won't even exist.
1218           Which will make e.g. dig build fail.
1219           Answering N saves around 400 bytes in bss.
1220
1221 config UCLIBC_HAS_EXTRA_COMPAT_RES_STATE
1222         bool "Use extra compatible but extra bloated _res"
1223         default n
1224         help
1225           Answer Y if selecting UCLIBC_HAS_COMPAT_RES_STATE is not enough.
1226           As far as I can say, this should never be needed.
1227
1228 config UCLIBC_HAS_LIBRESOLV_STUB
1229         bool "Provide libresolv stub"
1230         default n
1231         help
1232           Provide a dummy resolv library.
1233
1234 config UCLIBC_HAS_LIBNSL_STUB
1235         bool "Provide libnsl stub"
1236         default n
1237         help
1238           Provide a dummy nsl library.
1239
1240 endif
1241
1242
1243 menu "String and Stdio Support"
1244
1245 config UCLIBC_HAS_STRING_GENERIC_OPT
1246         bool "Use faster (but larger) generic string functions"
1247         default y
1248         help
1249           Answer Y to use the (tweaked) glibc generic string functions.
1250
1251           In general, they are faster (but 3-5K larger) than the base
1252           uClibc string functions which are optimized solely for size.
1253
1254           Many people will answer Y.
1255
1256 config UCLIBC_HAS_STRING_ARCH_OPT
1257         bool "Use arch-specific assembly string functions (where available)"
1258         default y
1259         help
1260           Answer Y to use any archtecture-specific assembly language string
1261           functions available for this target plaform.
1262
1263           Note that assembly implementations are not available for all string
1264           functions, so some generic (written in C) string functions may
1265           still be used.
1266
1267           These are small and fast, the only reason _not_ to say Y here is
1268           for debugging purposes.
1269
1270 config UCLIBC_HAS_CTYPE_TABLES
1271         bool "Use Table Versions Of 'ctype.h' Functions."
1272         default y
1273         help
1274           Answer Y to use table versions of the 'ctype.h' functions.
1275           While the non-table versions are often smaller when building
1276           statically linked apps, they work only in stub locale mode.
1277
1278           Most people will answer Y.
1279
1280 config UCLIBC_HAS_CTYPE_SIGNED
1281         bool "Support Signed Characters In 'ctype.h' Functions."
1282         depends on UCLIBC_HAS_CTYPE_TABLES
1283         default y
1284         help
1285           Answer Y to enable support for passing signed char values to
1286           the 'ctype.h' functions.  ANSI/ISO C99 and SUSv3 specify that
1287           these functions are only defined for unsigned char values and
1288           EOF.  However, glibc allows negative signed char values as well
1289           in order to support 'broken old programs'.
1290
1291           Most people will answer Y.
1292
1293 choice
1294         prompt "ctype argument checking"
1295         depends on UCLIBC_HAS_CTYPE_TABLES
1296         default UCLIBC_HAS_CTYPE_UNSAFE
1297         help
1298           Please select the invalid arg behavior you want for the 'ctype'
1299           functions.
1300
1301           The 'ctype' functions are now implemented using table lookups, with
1302           the arg being the index.  This can result in incorrect memory accesses
1303           or even segfaults for args outside of the allowed range.
1304
1305           NOTE: This only affects the 'ctype' _functions_.  It does not affect
1306           the macro implementations.
1307
1308 config UCLIBC_HAS_CTYPE_UNSAFE
1309         bool "Do not check -- unsafe"
1310
1311 config UCLIBC_HAS_CTYPE_CHECKED
1312         bool "Detect and handle appropriately"
1313
1314 config UCLIBC_HAS_CTYPE_ENFORCED
1315         bool "Issue a diagnostic and abort()"
1316
1317 endchoice
1318
1319
1320 config UCLIBC_HAS_WCHAR
1321         bool "Wide Character Support"
1322         default n
1323         help
1324           Answer Y to enable wide character support.  This will make uClibc
1325           much larger.  It is also currently required for locale support.
1326
1327           Most people will answer N.
1328
1329 config UCLIBC_HAS_LOCALE
1330         bool "Locale Support"
1331         select UCLIBC_HAS_WCHAR
1332         select UCLIBC_HAS_CTYPE_TABLES
1333         default n
1334         help
1335           uClibc now has full ANSI/ISO C99 locale support (except for
1336           wcsftime() and collating items in regex).  Be aware that enabling
1337           this option will make uClibc much larger.
1338
1339           Enabling UCLIBC_HAS_LOCALE with the default set of supported locales
1340           (169 UTF-8 locales, and 144 locales for other codesets) will enlarge
1341           uClibc by around 300k.  You can reduce this size by building your own
1342           custom set of locate data (see extra/locale/LOCALES for details).
1343
1344           uClibc's locale support is still under development.  For example,
1345           codesets using shift states are not currently supported.  Support is
1346           planned in the next iteration of locale support.
1347
1348           Answer Y to enable locale support.  Most people will answer N.
1349
1350 choice
1351
1352 prompt "Locale data"
1353         depends on UCLIBC_HAS_LOCALE
1354         default UCLIBC_BUILD_ALL_LOCALE
1355
1356 config UCLIBC_BUILD_ALL_LOCALE
1357         bool "All locales"
1358         depends on UCLIBC_HAS_LOCALE
1359         help
1360           This builds all the locales that are available on your
1361           host-box.
1362
1363 config UCLIBC_BUILD_MINIMAL_LOCALE
1364         bool "Only selected locales"
1365         depends on UCLIBC_HAS_LOCALE
1366         help
1367           If you do not need all locales that are available on your
1368           host-box, then set this to 'Y'.
1369
1370 config UCLIBC_PREGENERATED_LOCALE_DATA
1371         bool "Use Pre-generated Locale Data"
1372         depends on UCLIBC_HAS_LOCALE
1373         help
1374           Use pre-built locale data.
1375
1376           Note that these pregenerated locales are sensitive to your
1377           target architecture (endianess, bitcount).
1378
1379           Saying N here is highly recommended.
1380
1381 endchoice
1382
1383 config UCLIBC_BUILD_MINIMAL_LOCALES
1384         string "locales to use"
1385         depends on UCLIBC_BUILD_MINIMAL_LOCALE
1386         default "en_US"
1387         help
1388           Space separated list of locales to use.
1389
1390           E.g.:
1391               en_US en_GB de_AT
1392           default:
1393               en_US
1394
1395 config UCLIBC_DOWNLOAD_PREGENERATED_LOCALE_DATA
1396         bool "Automagically Download the Pre-generated Locale Data (if necessary)"
1397         depends on UCLIBC_PREGENERATED_LOCALE_DATA
1398         default n
1399         help
1400           If you would like the build process to use 'wget' to automatically
1401           download the pregenerated locale data, enable this option.  Otherwise
1402           you will need to obtain the locale data yourself from:
1403                 http://www.uclibc.org/downloads/uClibc-locale-*.tgz
1404           and place the uClibc-locale-*.tgz tarball in the extra/locale/
1405           directory.
1406
1407           Note that the use of pregenerated locale data is discouraged.
1408
1409 config UCLIBC_HAS_XLOCALE
1410         bool "Extended Locale Support (experimental/incomplete)"
1411         depends on UCLIBC_HAS_LOCALE
1412         default n
1413         help
1414           Answer Y to enable extended locale support similar to that provided
1415           by glibc.  This is primarily intended to support libstd++
1416           functionality.
1417           However, it also allows thread-specific locale selection via
1418           uselocale().
1419
1420           Most people will answer N.
1421
1422 config UCLIBC_HAS_HEXADECIMAL_FLOATS
1423         bool "Support hexadecimal float notation"
1424         depends on UCLIBC_HAS_CTYPE_TABLES
1425         depends on UCLIBC_HAS_FLOATS
1426         default n
1427         help
1428           Answer Y to enable support for hexadecimal float notation in the
1429           (wchar and) char string to floating point conversion functions, as
1430            well as support for the %a and %A conversion specifiers in the
1431            *printf() and *scanf() functions.
1432
1433           Most people will answer N.
1434
1435 config UCLIBC_HAS_GLIBC_DIGIT_GROUPING
1436         bool "Support glibc's \"'\" flag for allowing locale-specific digit grouping"
1437         depends on UCLIBC_HAS_LOCALE
1438         depends on UCLIBC_HAS_FLOATS
1439         default n
1440         help
1441           Answer Y to enable support for glibc's \"'\" flag for allowing
1442           locale-specific digit grouping in base 10 integer conversions and
1443           appropriate floating point conversions in the *printf() and *scanf()
1444           functions.
1445
1446           Most people will answer N.
1447
1448 config UCLIBC_HAS_SCANF_LENIENT_DIGIT_GROUPING
1449         bool "Do not require digit grouping when the \"'\" flag is specified"
1450         depends on UCLIBC_HAS_GLIBC_DIGIT_GROUPING
1451         default y
1452         help
1453           Answer Y to make digit grouping optional when the \"'\" flag is
1454           specified.
1455           This is the standard glibc behavior.  If the initial string of digits
1456           exceeds the maximum group number, the input will be treated as a
1457           normal non-grouped number.
1458
1459           Most people will answer N.
1460
1461 config UCLIBC_HAS_GLIBC_CUSTOM_PRINTF
1462         bool "Support glibc's register_printf_function() (glibc-compat)"
1463         depends on !USE_OLD_VFPRINTF
1464         default n
1465         help
1466           Answer Y to support glibc's register_printf_function() to allow an
1467           application to add its own printf conversion specifiers.
1468
1469           NOTE: Limits the number or registered specifiers to 10.
1470           NOTE: Requires new conversion specifiers to be ASCII
1471                 characters (0-0x7f).  This is to avoid problems with processing
1472                 format strings in locales with different multibyte conversions.
1473
1474           Most people will answer N.
1475
1476 config USE_OLD_VFPRINTF
1477         bool "Use the old vfprintf implementation"
1478         depends on !UCLIBC_HAS_WCHAR
1479         default n
1480         help
1481           Set to true to use the old vfprintf instead of the new.  This is
1482           roughly C89 compliant with some extensions, and is much smaller.
1483           However, it does not support wide chars, positional args, or glibc
1484           custom printf specifiers.
1485
1486           Most people will answer N.
1487
1488 config UCLIBC_PRINTF_SCANF_POSITIONAL_ARGS
1489         int "Maximum number of positional args.  Either 0 or >= 9."
1490         depends on !USE_OLD_VFPRINTF
1491         default 9
1492         help
1493           Set the maximum number of positional args supported by the
1494           printf/scanf functions.  The Single Unix Specification Version 3
1495           requires a minimum value of 9.  Setting this to a value lower than
1496           9 will disable positional arg support and cause the NL_ARGMAX macro
1497           in limits.h to be #undef'd.
1498
1499           WARNING!  The workspace to support positional args is currently
1500                     allocated on the stack.  You probably don't want to set
1501                     this to too high a value.
1502
1503           Most people will answer 9.
1504
1505
1506 config UCLIBC_HAS_SCANF_GLIBC_A_FLAG
1507         bool "Support glibc's 'a' flag for scanf string conversions (not implemented)"
1508         default n
1509         help
1510           NOTE!!!  Currently Not Implemented!!! Just A Place Holder!!  NOTE!!!
1511           NOTE!!!  Conflicts with an ANSI/ISO C99 scanf flag!!         NOTE!!!
1512
1513           Answer Y to enable support for glibc's 'a' flag for the scanf string
1514           conversions '%s', '%[', '%ls', '%l[', and '%S'.  This is used to
1515           auto-allocate sufficient memory to hold the data retrieved.
1516
1517           Most people will answer N.
1518
1519 choice
1520         prompt "Stdio buffer size"
1521         default UCLIBC_HAS_STDIO_BUFSIZ_4096
1522         help
1523           Please select a value for BUFSIZ.  This will be used by the
1524           stdio subsystem as the default buffer size for a file, and
1525           affects fopen(), setvbuf(), etc.
1526
1527           NOTE: Setting this to 'none' will disable buffering completely.
1528           However, BUFSIZ will still be defined in stdio.h as 256 because
1529           many applications use this value.
1530
1531 config UCLIBC_HAS_STDIO_BUFSIZ_NONE
1532         bool "none (WARNING - BUFSIZ will be 256 in stdio.h)"
1533         depends on !UCLIBC_HAS_WCHAR
1534
1535 config UCLIBC_HAS_STDIO_BUFSIZ_256
1536         bool "256 (minimum ANSI/ISO C99 value)"
1537
1538 config UCLIBC_HAS_STDIO_BUFSIZ_512
1539         bool "512"
1540
1541 config UCLIBC_HAS_STDIO_BUFSIZ_1024
1542         bool "1024"
1543
1544 config UCLIBC_HAS_STDIO_BUFSIZ_2048
1545         bool "2048"
1546
1547 config UCLIBC_HAS_STDIO_BUFSIZ_4096
1548         bool "4096"
1549
1550 config UCLIBC_HAS_STDIO_BUFSIZ_8192
1551         bool "8192"
1552
1553 # If you add more choices, you will need to update uClibc_stdio.h.
1554
1555 endchoice
1556
1557 choice
1558         prompt "Stdio builtin buffer size (uClibc-specific)"
1559         depends on !UCLIBC_HAS_STDIO_BUFSIZ_NONE
1560         default UCLIBC_HAS_STDIO_BUILTIN_BUFFER_NONE
1561         help
1562           When a FILE is created with fopen(), an attempt is made to allocate
1563           a BUFSIZ buffer for it.  If the allocation fails, fopen() will still
1564           succeed but the FILE will be unbuffered.
1565
1566           This option adds a small amount of space to each FILE to act as an
1567           emergency buffer in the event of a buffer allocation failure.
1568
1569           Most people will answer None.
1570
1571 config UCLIBC_HAS_STDIO_BUILTIN_BUFFER_NONE
1572         bool "None"
1573
1574 config UCLIBC_HAS_STDIO_BUILTIN_BUFFER_4
1575         bool "4"
1576
1577 config UCLIBC_HAS_STDIO_BUILTIN_BUFFER_8
1578         bool "8"
1579
1580 # If you add more choices, you will need to update uClibc_stdio.h.
1581
1582 endchoice
1583
1584 config UCLIBC_HAS_STDIO_SHUTDOWN_ON_ABORT
1585         bool "Attempt to shutdown stdio subsystem when abort() is called."
1586         default n
1587         help
1588           ANSI/ISO C99 requires abort() to be asyn-signal-safe.  So there was
1589           a behavioral change made in SUSv3.  Previously, abort() was required
1590           to have the affect of fclose() on all open streams.  The wording has
1591           been changed to "may" from "shall".
1592
1593           Most people will answer N.
1594
1595 config UCLIBC_HAS_STDIO_GETC_MACRO
1596         bool "Provide a macro version of getc()"
1597         depends on !UCLIBC_HAS_STDIO_BUFSIZ_NONE
1598         default y
1599         help
1600           Provide a macro version of getc().
1601
1602           Most people will answer Y.
1603
1604 config UCLIBC_HAS_STDIO_PUTC_MACRO
1605         bool "Provide a macro version of putc()"
1606         depends on !UCLIBC_HAS_STDIO_BUFSIZ_NONE
1607         default y
1608         help
1609           Provide a macro version of putc().
1610
1611           Most people will answer Y.
1612
1613 config UCLIBC_HAS_STDIO_AUTO_RW_TRANSITION
1614         bool "Support auto-r/w transition"
1615         default y
1616         help
1617           Answer Y to enable the stdio subsystem to automaticly transition
1618           between reading and writing.  This relaxes the ANSI/ISO C99
1619           requirement:
1620
1621           When a file is opened with update mode ('+' as the second or third
1622           character in the list of mode argument values), both input and output
1623           may be performed on the associated stream. However, output shall not
1624           be directly followed by input without an intervening call to the
1625           fflush function or to a file positioning function (fseek, fsetpos,
1626           or rewind), and input shall not be directly followed by output without
1627           an intervening call to a file positioning function, unless the input
1628           operation encounters end­of­file.
1629
1630           Most people will answer Y.
1631
1632 config UCLIBC_HAS_FOPEN_LARGEFILE_MODE
1633         bool "Support an fopen() 'F' flag for large file mode (uClibc-specific)"
1634         depends on UCLIBC_HAS_LFS
1635         default n
1636         help
1637           Answer Y to enable a uClibc-specific extension to allow passing an
1638           additional 'F' flag in the mode string for fopen() to specify that
1639           the file should be open()ed with the O_LARGEFILE flag set.
1640
1641           Most people will answer N.
1642
1643 config UCLIBC_HAS_FOPEN_EXCLUSIVE_MODE
1644         bool "Support an fopen() 'x' flag for exclusive mode (glibc-compat)"
1645         default n
1646         help
1647           Answer Y to support a glibc extension to allow passing
1648           additional 'x' flag in the mode string for fopen() to specify that
1649           the file should be open()ed with the O_EXCL flag set.
1650
1651           Most people will answer N.
1652
1653 config UCLIBC_HAS_GLIBC_CUSTOM_STREAMS
1654         bool "Support fmemopen(), open_memstream(), and fopencookie() (glibc-compat)"
1655         default n
1656         help
1657           Answer Y to support the glibc 'custom stream' extension functions
1658           fmemopen(), open_memstream(), and fopencookie().
1659
1660           NOTE: There are some minor differences regarding seeking behavior.
1661
1662           Most people will answer N.
1663
1664 config UCLIBC_HAS_PRINTF_M_SPEC
1665         bool "Support the '%m' specifier in printf format strings (glibc-compat)"
1666         default n
1667         help
1668           Answer Y to support a glibc extension to interpret '%m' in printf
1669           format strings as an instruction to output the error message string
1670           (as generated by strerror) corresponding to the current value of
1671           'errno'.
1672
1673           Most people will answer N.
1674
1675 config UCLIBC_HAS_ERRNO_MESSAGES
1676         bool "Include the errno message text in the library"
1677         default y
1678         help
1679           Answer Y if you want to include the errno message text in the
1680           library.  This adds about 3K to the library, but enables strerror()
1681           to generate text other than 'Unknown error <number>'.
1682
1683           Most people will answer Y.
1684
1685 config UCLIBC_HAS_SYS_ERRLIST
1686         bool "Support sys_errlist[] (obsolete-compat)"
1687         depends on UCLIBC_HAS_ERRNO_MESSAGES
1688         default n
1689         help
1690           Answer Y if you want to support the obsolete sys_errlist[].
1691           This adds about 0.5k to the library, except for the mips
1692           arch where it adds over 4K.
1693
1694           WARNING!  In the future, support for sys_errlist[] may be unavailable
1695                     in at least some configurations.  In fact, it may be removed
1696                     altogether.
1697
1698           Most people will answer N.
1699
1700           Application writers: use the strerror(3) function.
1701
1702 config UCLIBC_HAS_SIGNUM_MESSAGES
1703         bool "Include the signum message text in the library"
1704         default y
1705         help
1706           Answer Y if you want to include the signum message text in the
1707           library.  This adds about 0.5K to the library, but enables strsignal()
1708           to generate text other than 'Unknown signal <number>'.
1709
1710           Most people will answer Y.
1711
1712 config UCLIBC_HAS_SYS_SIGLIST
1713         bool "Support sys_siglist[] (bsd-compat)"
1714         depends on UCLIBC_HAS_SIGNUM_MESSAGES
1715         default n
1716         help
1717           Answer Y if you want to support sys_siglist[].
1718
1719           WARNING!  In the future, support for sys_siglist[] may be unavailable
1720                     in at least some configurations.  In fact, it may be removed
1721                     altogether.
1722
1723           Most people will answer N.
1724
1725 config UCLIBC_HAS_GETTEXT_AWARENESS
1726         bool "Include gettext awareness"
1727         depends on UCLIBC_HAS_LOCALE && UCLIBC_MJN3_ONLY
1728         default n
1729         help
1730           NOTE!!!  Not yet integrated with strerror and strsignal.  NOTE!!!
1731
1732           Answer Y if you want to include weak stub gettext support and
1733           make the *strerror*() and strsignal() functions gettext-aware.
1734
1735           Currently, to get functional gettext functionality you will need
1736           to use gnu gettext.
1737
1738           Most people will answer N.
1739
1740 config UCLIBC_HAS_GNU_GETOPT
1741         bool "Support gnu getopt"
1742         default y
1743         help
1744           Answer Y if you want to include full gnu getopt() instead of a
1745           (much smaller) SUSv3 compatible getopt().
1746
1747           Most people will answer Y.
1748
1749 config UCLIBC_HAS_STDIO_FUTEXES
1750         bool "Use futexes for multithreaded I/O locking"
1751         default n
1752         depends on UCLIBC_HAS_THREADS_NATIVE
1753         help
1754           If you want to compile uClibc to use futexes for low-level
1755           I/O locking, answer Y.  Otherwise, answer N.
1756
1757 config UCLIBC_HAS_GETOPT_LONG
1758         bool "Support getopt_long/getopt_long_only"
1759         depends on !UCLIBC_HAS_GNU_GETOPT
1760         default y
1761         help
1762           Answer Y if you want to include getopt_long[_only() used by many
1763           apps, even busybox.
1764
1765           Most people will answer Y.
1766
1767 config UCLIBC_HAS_GNU_GETSUBOPT
1768         bool "Support glibc getsubopt"
1769         default y
1770         help
1771           Answer Y if you want to include glibc getsubopt() instead of a
1772           smaller SUSv3 compatible getsubopt().
1773
1774           Most people will answer Y.
1775 endmenu
1776
1777
1778 menu "Big and Tall"
1779
1780 config UCLIBC_HAS_REGEX
1781         bool "Regular Expression Support"
1782         default y
1783         help
1784           POSIX regular expression code is really big -- 53k all by itself.
1785           If you don't use regular expressions, turn this off and save space.
1786           Of course, if you only statically link, leave this on, since it will
1787           only be included in your apps if you use regular expressions.
1788
1789 config UCLIBC_HAS_REGEX_OLD
1790         bool "Use the older (stable) regular expression code"
1791         depends on UCLIBC_HAS_REGEX
1792         default y
1793         help
1794           There are two versions of regex.  The older (stable) version has
1795           been in uClibc for quite a long time but hasn't seen too many
1796           updates.  It also has some known issues when dealing with uncommon
1797           corner cases and multibyte/unicode strings.  However, it is quite
1798           a bit smaller than the newer version.
1799
1800           If the older version has worked for you and you don't need unicode
1801           support, then stick with the old version (and say Y here).
1802           Otherwise, you should use the new version (and say N here).
1803
1804 config UCLIBC_HAS_FNMATCH
1805         bool "fnmatch Support"
1806         default y
1807         help
1808           POSIX fnmatch.
1809
1810 config UCLIBC_HAS_FNMATCH_OLD
1811         bool "Use the older (stable) fnmatch code"
1812         depends on UCLIBC_HAS_FNMATCH
1813         default y
1814         help
1815           There are two versions of fnmatch.  The older (stable) version has
1816           been in uClibc for quite a long time but hasn't seen too many
1817           updates.  It also has some known issues when dealing with uncommon
1818           corner cases and multibyte/unicode strings.  However, it is quite
1819           a bit smaller than the newer version.
1820
1821           If the older version has worked for you and you don't need unicode
1822           support, then stick with the old version (and say Y here).
1823           Otherwise, you should use the new version (and say N here).
1824
1825 config UCLIBC_HAS_WORDEXP
1826         bool "Support the wordexp() interface"
1827         depends on UCLIBC_HAS_GLOB
1828         default n
1829         help
1830           The SuSv3 wordexp() interface performs word expansions per the  Shell
1831           and Utilities volume of IEEE Std 1003.1-2001, Section 2.6.  It is
1832           intended for use by applications that want to implement all of the
1833           standard Bourne shell expansions on input data.
1834
1835           This interface is rarely used, and very large.  Unless you have a
1836           pressing need for wordexp(), you should probably answer N.
1837
1838 config UCLIBC_HAS_NFTW
1839         bool "Support the nftw() interface"
1840         default n
1841         help
1842           The SuSv3 nftw() interface is used to recursively descend
1843           directory paths while repeatedly calling a function.
1844
1845           This interface is rarely used, and adds around 4.5k.  Unless you have
1846           a pressing need for nftw(), you should probably answer N.
1847
1848 config UCLIBC_HAS_FTW
1849         bool "Support the ftw() interface"
1850         default n
1851         depends on UCLIBC_SUSV4_LEGACY
1852         help
1853           The SuSv3 ftw() interface is used to recursively descend
1854           directory paths while repeatedly calling a function.
1855
1856           This interface is rarely used, and adds around 4.5k.  Unless you have
1857           a pressing need for ftw(), you should probably answer N.
1858
1859
1860 config UCLIBC_HAS_GLOB
1861         bool "Support the glob() interface"
1862         depends on UCLIBC_HAS_FNMATCH
1863         default y
1864         help
1865
1866           The glob interface is somewhat large (weighing in at about 2,5k).  It
1867           is used fairly often, but is an option since people wanting to go for
1868           absolute minimum size may wish to omit it.
1869
1870           Most people will answer Y.
1871
1872 config UCLIBC_HAS_GNU_GLOB
1873         bool "Support gnu glob() interface"
1874         depends on UCLIBC_HAS_GLOB
1875         default n
1876         help
1877           The gnu glob interface is somewhat larger (weighing in at about 4,2k)
1878           than it's SuSv3 counterpart (and is out of date). It is an old copy
1879           from glibc and does not support all the GNU specific options.
1880
1881           Answer Y if you want to include full gnu glob() instead of the smaller
1882           SUSv3 compatible glob().
1883
1884           Most people will answer N.
1885
1886 endmenu
1887
1888
1889
1890
1891 menu "Library Installation Options"
1892
1893 config RUNTIME_PREFIX
1894         string "uClibc runtime library directory"
1895         default "/usr/$(TARGET_ARCH)-linux-uclibc/"
1896         help
1897           RUNTIME_PREFIX is the directory into which the uClibc runtime
1898           libraries will be installed.   The result will look something
1899           like the following:
1900               $(RUNTIME_PREFIX)/
1901                   lib/            <contains all runtime libraries>
1902                   usr/bin/ldd     <the ldd utility program>
1903                   sbin/ldconfig   <the ldconfig utility program>
1904           This value is used by the 'make install' Makefile target.  Since this
1905           directory is compiled into the shared library loader, you will need to
1906           recompile uClibc if you change this value...
1907
1908           For a typical target system this should be set to "/", such that
1909           'make install' will install /lib/libuClibc-<VERSION>.so
1910
1911 config DEVEL_PREFIX
1912         string "uClibc development environment directory"
1913         default "/usr/$(TARGET_ARCH)-linux-uclibc/usr/"
1914         help
1915           DEVEL_PREFIX is the directory into which the uClibc development
1916           environment will be installed.   The result will look something
1917           like the following:
1918               $(DEVEL_PREFIX)/
1919                   lib/            <contains static libs>
1920                   include/        <Where all the header files go>
1921           This value is used by the 'make install' Makefile target when
1922           installing a uClibc development environment.
1923
1924           For a typical target system this should be set to "/usr", such that
1925           'make install' will install /usr/include/<header files>.
1926
1927 config MULTILIB_DIR
1928         string "library path component"
1929         default "lib"
1930         help
1931           Path component where libraries reside.
1932
1933           For a typical target system this should be set to "lib", such that
1934           'make install' will install libraries to "/lib" and "/usr/lib"
1935           respectively
1936             DEVEL_PREFIX/MULTILIB_DIR
1937             RUNTIME_PREFIX/MULTILIB_DIR
1938
1939           Other settings may include "lib32" or "lib64".
1940
1941 config HARDWIRED_ABSPATH
1942         bool "Hardwire absolute paths into linker scripts"
1943         default y
1944         help
1945           This prepends absolute paths to the libraries mentioned in linker
1946           scripts such as libc.so.
1947
1948           This is a build time optimization.  It has no impact on dynamic
1949           linking at runtime, which doesn't use linker scripts.
1950
1951           You must disable this to use uClibc with old non-sysroot toolchains,
1952           such as the prebuilt binary cross compilers at:
1953              http://uclibc.org/downloads/binaries
1954
1955           The amount of time saved by this optimization is actually too small to
1956           measure. The linker just had to search the library path to find the
1957           linker script, so the dentries are cache hot if it has to search the
1958           same path again.  But it's what glibc does, so we do it too.
1959
1960 endmenu
1961
1962
1963 menu "Security options"
1964
1965 config UCLIBC_BUILD_PIE
1966         bool "Build utilities as ET_DYN/PIE executables"
1967         depends on HAVE_SHARED
1968         depends on TARGET_arm || TARGET_frv || TARGET_i386 || TARGET_mips || TARGET_powerpc
1969         select FORCE_SHAREABLE_TEXT_SEGMENTS
1970         default n
1971         help
1972           If you answer Y here, ldd and iconv are built as ET_DYN/PIE
1973           executables.
1974
1975           It requires gcc-3.4 and binutils-2.15 (for arm 2.16) or later.
1976           More about ET_DYN/PIE binaries on <http://pax.grsecurity.net/> .
1977
1978           WARNING: This option also enables FORCE_SHAREABLE_TEXT_SEGMENTS, so
1979                    all libraries have to be built with -fPIC or -fpic, and all
1980                    assembler functions must be written as position independent
1981                    code (PIC).
1982
1983 config UCLIBC_HAS_ARC4RANDOM
1984         bool "Include the arc4random() function"
1985         default n
1986         help
1987           Answer Y to support the OpenBSD-like arc4random() function. This
1988           function picks a random number between 0 and N, and will always return
1989           something even if the random driver is dead. If urandom fails then
1990           gettimeofday(2) will be used as the random seed. This function is
1991           designed to be more dependable than invoking /dev/urandom directly.
1992           OpenSSL and OpenNTPD currently support this function.
1993
1994           Most people will answer N.
1995
1996 config HAVE_NO_SSP
1997         bool
1998         default n
1999
2000 config UCLIBC_HAS_SSP
2001         bool "Support for GCC stack smashing protector"
2002         depends on !HAVE_NO_SSP
2003         default n
2004         help
2005           Add code to support GCC's -fstack-protector[-all] option to uClibc.
2006           This requires GCC 4.1 or newer.  GCC does not have to provide libssp,
2007           the needed functions are added to ldso/libc instead.
2008
2009           GCC's stack protector is a reimplementation of IBM's propolice.
2010           See http://www.trl.ibm.com/projects/security/ssp/ and
2011           http://www.linuxfromscratch.org/hints/downloads/files/ssp.txt
2012           for details.
2013
2014           Note that NOEXECSTACK on a kernel with address space randomization
2015           is generally sufficient to prevent most buffer overflow exploits
2016           without increasing code size.  This option essentially adds debugging
2017           code to catch them.
2018
2019           Most people will answer N.
2020
2021 config UCLIBC_HAS_SSP_COMPAT
2022         bool "Support for gcc-3.x propolice smashing stack protector"
2023         depends on UCLIBC_HAS_SSP
2024         default n
2025         help
2026           Add gcc-3.x propolice smashing stack protector to the library.
2027
2028           This requires a patched version of GCC, supporting the
2029           -fstack-protector[-all] options, with the __guard and
2030           __stack_smash_handler functions removed from libgcc.
2031           These functions are added to ldso/libc instead.
2032
2033           More information at:
2034           <http://www.research.ibm.com/trl/projects/security/ssp/>
2035
2036           Most people will answer N.
2037
2038 config SSP_QUICK_CANARY
2039         bool "Use simple guard values without accessing /dev/urandom"
2040         depends on UCLIBC_HAS_SSP
2041         default n
2042         help
2043           Use gettimeofday(2) to define the __guard without accessing
2044           /dev/urandom.
2045           WARNING: This makes smashing stack protector vulnerable to timing
2046                 attacks.
2047           Most people will answer N.
2048
2049 choice
2050         prompt "Propolice protection blocking signal"
2051         depends on UCLIBC_HAS_SSP
2052         default PROPOLICE_BLOCK_ABRT if ! DODEBUG
2053         default PROPOLICE_BLOCK_SEGV if DODEBUG
2054         help
2055           "abort" use SIGABRT to block offending programs.
2056           This is the default implementation.
2057
2058           "segfault" use SIGSEGV to block offending programs.
2059           Use this for debugging.
2060
2061           If unsure, answer "abort".
2062
2063 config PROPOLICE_BLOCK_ABRT
2064         bool "abort"
2065
2066 config PROPOLICE_BLOCK_SEGV
2067         bool "segfault"
2068
2069 endchoice
2070
2071 config UCLIBC_BUILD_SSP
2072         bool "Build uClibc with -fstack-protector"
2073         depends on UCLIBC_HAS_SSP
2074         default n
2075         help
2076           Build all uClibc libraries and executables with -fstack-protector,
2077           adding extra stack overflow checking to most uClibc functions.
2078
2079 config UCLIBC_BUILD_RELRO
2080         bool "Build uClibc with linker option -z RELRO"
2081         depends on HAVE_SHARED
2082         default y
2083         help
2084           Build all libraries and executables with "ld -z relro".
2085
2086           This tells the linker to mark chunks of an executable or shared
2087           library read-only after applying dynamic relocations.  (This comes
2088           up when a global const variable is initialized to the address of a
2089           function or the value of another global variable.)
2090
2091           This is a fairly obscure option the ld man page doesn't even bother
2092           to document properly.  It's a security paranoia issue that's more
2093           likely to consume memory (by allocating an extra page) rather than
2094           save it.
2095
2096           This is explained in more depth at
2097           http://www.airs.com/blog/archives/189
2098
2099           Nobody is likely to care whether you say Y or N here.
2100
2101 config UCLIBC_BUILD_NOW
2102         bool "Build uClibc with linker option -z NOW"
2103         depends on HAVE_SHARED
2104         default n
2105         help
2106           Build all libraries and executables with "ld -z now".
2107
2108           This tells the linker to resolve all symbols when the library is
2109           first loaded, rather than when each function is first called.  This
2110           increases start-up latency by a few microseconds and may do
2111           unnecessary work (resolving symbols that are never used), but the
2112           realtime people like it for making microbenchmark timings slightly
2113           more predictable and in some cases it can be slightly faster due to
2114           CPU cache behavior (not having to fault the linker back in to do
2115           lazy symbol resolution).
2116
2117           Most people can't tell the difference between selecting Y or N here.
2118
2119 config UCLIBC_BUILD_NOEXECSTACK
2120         bool "Build uClibc with noexecstack marking"
2121         default y
2122         help
2123           Mark all assembler files as noexecstack, which will mark uClibc
2124           as not requiring an executable stack.  (This doesn't prevent other
2125           files you link against from claiming to need an executable stack, it
2126           just won't cause uClibc to request it unnecessarily.)
2127
2128           This is a security thing to make buffer overflows harder to exploit.
2129           By itself, it's kind of useless, as Linus Torvalds explained in 1998:
2130           http://old.lwn.net/1998/0806/a/linus-noexec.html
2131
2132           It only actually provides any security when combined with address
2133           space randomization, explained here: http://lwn.net/Articles/121845/
2134
2135           Address space randomization is on by default in current linux
2136           kernels (although it can be disabled using the option
2137           CONFIG_COMPAT_BRK).
2138
2139           You should probably say Y.
2140
2141 endmenu
2142
2143 menu "uClibc development/debugging options"
2144
2145 config CROSS_COMPILER_PREFIX
2146         string "Cross-compiling toolchain prefix"
2147         default ""
2148         help
2149           The prefix used to execute your cross-compiling toolchain.  For
2150           example, if you run 'arm-linux-uclibc-gcc' to compile something,
2151           then enter 'arm-linux-uclibc-' here.
2152
2153 config UCLIBC_EXTRA_CFLAGS
2154         string "Enter any extra CFLAGS to use to build uClibc"
2155         default ""
2156         help
2157           Add any additional CFLAGS to be used to build uClibc.
2158
2159 config DODEBUG
2160         bool "Build uClibc with debugging symbols"
2161         default n
2162         select EXTRA_WARNINGS
2163         help
2164           Say Y here if you wish to compile uClibc with debugging symbols.
2165           This will allow you to use a debugger to examine uClibc internals
2166           while applications are running.  This increases the size of the
2167           library considerably and should only be used when doing development.
2168           If you are doing development and want to debug uClibc, answer Y.
2169
2170           Otherwise, answer N.
2171
2172 config DODEBUG_PT
2173         bool "Build pthread with debugging output"
2174         depends on UCLIBC_HAS_THREADS && LINUXTHREADS_OLD
2175         default n
2176         help
2177           Enable debug output in libpthread.  This is only useful when doing
2178           development in libpthread itself.
2179
2180           Otherwise, answer N.
2181
2182 config DOSTRIP
2183         bool "Strip libraries and executables"
2184         default y
2185         depends on !DODEBUG
2186         help
2187           Say Y here if you do wish to strip all uClibc libraries and
2188           executables.  No stripping increases the size of the binaries
2189           considerably, but makes it possible to debug uClibc libraries.
2190           Most people will answer Y.
2191
2192 config DOASSERTS
2193         bool "Build uClibc with run-time assertion testing"
2194         default n
2195         help
2196           Say Y here to include runtime assertion tests.
2197           This enables runtime assertion testing in some code, which can
2198           increase the size of the library and incur runtime overhead.
2199           If you say N, then this testing will be disabled.
2200
2201 config SUPPORT_LD_DEBUG
2202         bool "Build the shared library loader with debugging support"
2203         depends on HAVE_SHARED
2204         default n
2205         help
2206           Answer Y here to enable all the extra code needed to debug the uClibc
2207           native shared library loader.  The level of debugging noise that is
2208           generated depends on the LD_DEBUG environment variable...  Just set
2209           LD_DEBUG to something like: 'LD_DEBUG=token1,token2,..  prog' to
2210           debug your application.  Diagnostic messages will then be printed to
2211           the stderr.
2212
2213           For now these debugging tokens are available:
2214             detail        provide more information for some options
2215             move          display copy processing
2216             symbols       display symbol table processing
2217             reloc         display relocation processing; detail shows the
2218                           relocation patch
2219             nofixups      never fixes up jump relocations
2220             bindings      displays the resolve processing (function calls);
2221                           detail shows the relocation patch
2222             all           Enable everything!
2223
2224           The additional environment variable:
2225             LD_DEBUG_OUTPUT=file
2226           redirects the diagnostics to an output file created using
2227           the specified name and the process id as a suffix.
2228
2229           An excellent start is simply:
2230             $ LD_DEBUG=binding,move,symbols,reloc,detail ./appname
2231           or to log everything to a file named 'logfile', try this
2232             $ LD_DEBUG=all LD_DEBUG_OUTPUT=logfile ./appname
2233
2234           If you are doing development and want to debug uClibc's shared library
2235           loader, answer Y.  Mere mortals answer N.
2236
2237 config SUPPORT_LD_DEBUG_EARLY
2238         bool "Build the shared library loader with early debugging support"
2239         depends on HAVE_SHARED
2240         default n
2241         help
2242           Answer Y here to if you find the uClibc shared library loader is
2243           crashing or otherwise not working very early on.  This is typical
2244           only when starting a new port when you haven't figured out how to
2245           properly get the values for argc, argv, environ, etc.  This method
2246           allows a degree of visibility into the very early shared library
2247           loader initialization process.  If you are doing development and want
2248           to debug the uClibc shared library loader early initialization,
2249           answer Y.  Mere mortals answer N.
2250
2251 config UCLIBC_MALLOC_DEBUGGING
2252         bool "Build malloc with debugging support"
2253         depends on MALLOC || MALLOC_STANDARD
2254         default n
2255         help
2256           Answer Y here to compile extra debugging support code into malloc.
2257           Malloc debugging output may then be enabled at runtime using the
2258           MALLOC_DEBUG environment variable.
2259
2260           The value of MALLOC_DEBUG should be an integer, which is interpreted
2261           as a bitmask with the following bits:
2262                   1   -  do extra consistency checking
2263                   2   -  output messages for malloc/free calls and OS
2264                          allocation calls
2265                   4   -  output messages for the `MMB' layer
2266                   8   -  output messages for internal malloc heap manipulation
2267                          calls
2268
2269           Because this increases the size of malloc appreciably (due to strings
2270           etc), you should say N unless you need to debug a malloc problem.
2271
2272 config WARNINGS
2273         string "Compiler Warnings"
2274         default "-Wall"
2275         help
2276           Set this to the set of gcc warnings you wish to see while compiling.
2277
2278 config EXTRA_WARNINGS
2279         bool "Enable extra annoying warnings"
2280         default n
2281         help
2282           If you wish to build with extra warnings enabled, say Y here.
2283
2284 config DOMULTI
2285         bool "Compile all sources at once into an object"
2286         default n
2287         help
2288           Set this to compile all sources at once into an object (IMA).
2289           This mode of compilation uses alot of memory but may produce
2290           smaller binaries.
2291
2292           Note that you need a very recent GCC for this to work, like
2293           gcc >= 4.3 plus eventually some patches.
2294
2295           If unsure, keep the default of N.
2296
2297 config UCLIBC_MJN3_ONLY
2298         bool "Manuel's hidden warnings"
2299         default n
2300         help
2301           Answer Y here to see all Manuel's personal notes, warnings, and todos.
2302
2303           Most people will answer N.
2304
2305 endmenu