1 # This file contains the common configuration options
2 # that apply to both glibc and eglibc.
4 if LIBC_glibc || LIBC_eglibc
6 # Some architectures require the ports addon. List them one by one here:
7 # This list must be carefully in sync with the architectures names
8 # we can find in config/arch/*
11 select LIBC_GLIBC_USE_PORTS
14 select LIBC_GLIBC_USE_PORTS
16 # End of arch-specific ports auto-select
18 comment "glibc/eglibc common options"
20 config LIBC_GLIBC_EXTRA_CONFIG
25 Extra flags to pass onto ./configure when configuring.
27 Eg.: --enable-static-nss
29 config LIBC_GLIBC_CONFIGPARMS
31 prompt "Extra config params (READ HELP)"
32 default "" if ! ARCH_sh
33 default "no-z-defs=yes" if ARCH_sh
35 Some architectures need to set options in the file configparms.
36 This is the case for sh3/4, which really need to set configparms
37 to "no-z-defs=yes" as of gcc-3.4/glibc-2.3.2.
39 Unless you are building a toolchain for sh3/4, you should leave that empty.
41 Note: If you need to pass more than one value, separate them with
42 '\n'. Eg.: var1=val1\nvar2=val2
44 config LIBC_GLIBC_EXTRA_CFLAGS
46 prompt "extra target CFLAGS"
49 Extra target CFLAGS to use when building.
51 config LIBC_EXTRA_CC_ARGS
53 prompt "gcc extra flags"
56 Extra flags to pass gcc when building.
58 Seldom used, except for sparc64 which seems to need the flag -64
59 to be passed onto gcc.
61 config LIBC_ENABLE_FORTIFIED_BUILD
63 prompt "Enable fortified build (EXPERIMENTAL)"
64 depends on EXPERIMENTAL
67 If you say 'y' here, then glibc will be using fortified versions
68 of functions with format arguments (eg. vsyslog, printf...), and
69 do a sanity check on the format at runtime, to avoid some of the
70 common format string attacks.
72 This is currently not supported, and will most probably result in
73 a broken build, with an error message like:
74 ../misc/syslog.c: In function '__vsyslog_chk':
75 ../misc/syslog.c:123: sorry, unimplemented: inlining failed in
76 call to 'syslog': function body not available
78 If you are brave enough and want to debug the issue, then say 'y'
79 here. Otherwise, be still and say 'n' (the default). ;-)
82 config LIBC_DISABLE_VERSIONING
84 prompt "Disable symbols versioning"
87 Do not include versioning information in the library objects.
89 config LIBC_OLDEST_ABI
91 prompt "Oldest supported ABI"
94 Set the oldest ABI supported by the C library.
96 Setting this option, for example, to 2.2 will provide ABI support
99 If this option is not set, (e)glibc will choose for you.
101 config LIBC_GLIBC_FORCE_UNWIND
103 prompt "Force unwind support (READ HELP!)"
106 If your toolchain fails building while building the C library
107 start files, or the complete C library, with a message like:
108 configure: error: forced unwind support is required
110 then you may try setting this to 'y'. Otherwise, leave it to 'n'.
112 The issue seems to be related to building NPTL on old versions
113 of glibc (and possibly eglibc as well) on some architectures
114 (seen on s390, s390x and x86_64).
116 config LIBC_GLIBC_USE_PORTS
118 prompt "Use the ports addon"
121 The ports addon contains some architecture ports that are not available
122 in the official distribution.
124 For example, this is the case for ARM with glibc-2.4 and above.
126 Say n only if you're sure that your architecture is in the official
127 distribution for your chosen version.
129 config LIBC_ADDONS_LIST
131 prompt "Extra addons"
134 Extra addons to include. Space separated list.
136 You need to specify neither linuxthreads nor nptl, as they are added
137 automagically for you depending on the threading model you choosed
140 Eg.: crypt (for very old libces)
142 if LIBC_GLIBC_USE_PORTS || ( LIBC_ADDONS_LIST != "" )
143 comment "WARNING !!! "
144 comment "| For glibc >= 2.8, it can happen that the tarballs "
145 comment "| for the addons are not available for download. "
146 comment "| If that happens, bad luck... Try a previous version "
147 comment "| or try again later... :-( "
154 prompt "Minimum supported kernel version"
155 default LIBC_GLIBC_KERNEL_VERSION_AS_HEADERS
157 config LIBC_GLIBC_KERNEL_VERSION_NONE
159 prompt "Let ./configure decide"
161 Let ./configure decide what minimum kernel version glibc/eglibc
162 will be able to run against.
164 This will inclde legacy compatibility code for older kernels in
165 the C library, thus ensuring that it will run on a large number
168 The minimum kernel version supported will be dependent upon the
169 target you build for. For example:
170 alpha*-*-linux-gnu Requires Linux 2.6.9 for NPTL
171 sh[34]-*-linux-gnu Requires Linux 2.6.11
172 powerpc* Requires Linux 2.4.19
173 arm*-*-linux-*gnueabi Requires Linux 2.6.16
175 config LIBC_GLIBC_KERNEL_VERSION_AS_HEADERS
177 prompt "Same as kernel headers (default)"
179 Normaly, you'll want glibc/eglibc to run against the same kernel
180 version as the one used for the headers.
184 If enabled, crosstool-ng will use the chosen version of kernel
185 headers for the glibc minimum kernel version supported, which is
186 what gets passed to "--enable-kernel=" when configuring glibc.
188 Enabling this will ensure that no legacy compatibility code for
189 older kernels is built into your C libraries, but it will
190 be unable to run on kernel versions older than whichever kernel
191 headers version you've built the toolchain for.
193 If you know for sure that your toolchain will never need to build
194 applications that will run under a kernel version older than your
195 chosen kernel headers version (CT_KERNEL_VERSION), you can choose
198 config LIBC_GLIBC_KERNEL_VERSION_CHOSEN
200 prompt "Specific kernel version"
202 Specify the earliest Linux kernel version you want glibc to
203 include support for. This does not have to match the kernel
204 headers version used for your toolchain. This controls what is
205 passed to the "--enable-kernel=" option to the glibc configure
208 If you want to be able to statically link programs with your
209 toolchain's C library, make sure this kernel version is lower than
210 all kernels you wish to support to avoid "FATAL: kernel too old"
211 errors. The higher the version you specify, the less legacy code
212 will be built into libc.
214 Most people can leave this at the default value of "2.6.9".
216 if LIBC_GLIBC_KERNEL_VERSION_CHOSEN
218 config LIBC_GLIBC_MIN_KERNEL_VERSION
220 prompt "Minimum kernel version to support"
223 Enter here the lowest kernel version glibc/eglibc will be able to
226 The minimum kernel version supported will be dependent upon the
227 target you build for. For example:
228 alpha*-*-linux-gnu Requires Linux 2.6.9 for NPTL
229 sh[34]-*-linux-gnu Requires Linux 2.6.11
230 powerpc* Requires Linux 2.4.19
231 arm*-*-linux-*gnueabi Requires Linux 2.6.16
233 Note that no sanity check is performed by crosstool-NG to ensure
234 that the value you enter here is appropriate for your target.
236 endif # LIBC_GLIBC_KERNEL_VERSION_CHOSEN
240 config LIBC_GLIBC_MIN_KERNEL
242 default "" if LIBC_GLIBC_KERNEL_VERSION_NONE
243 default KERNEL_VERSION if LIBC_GLIBC_KERNEL_VERSION_AS_HEADERS
244 default LIBC_GLIBC_MIN_KERNEL_VERSION if LIBC_GLIBC_KERNEL_VERSION_CHOSEN
248 endif # LIBC_glibc || LIBC_eglibc