summaryrefslogtreecommitdiff
path: root/config/libc
diff options
context:
space:
mode:
authorYann E. MORIN" <yann.morin.1998@anciens.enib.fr>2008-09-14 18:09:36 (GMT)
committerYann E. MORIN" <yann.morin.1998@anciens.enib.fr>2008-09-14 18:09:36 (GMT)
commit02d2b29cdaefd315977bfad549416d6904f40d04 (patch)
tree8c54aba158dd98ab12dfbd6d2d485747ed6b255a /config/libc
parent91a8de54e4d0176e5697c4d750aba235686cb2e3 (diff)
Enhance setting the minimum kernel version glibc will run against.
Ideally, eglibc should also benefit for that, but the current code does not set it. /trunk/scripts/build/libc/glibc.sh | 38 33 5 0 +++++++++++++++--- /trunk/config/libc/glibc.in | 4 2 2 0 +- /trunk/config/libc/uClibc.in | 2 2 0 0 + /trunk/config/libc/eglibc.in | 4 2 2 0 +- /trunk/config/libc/glibc-eglibc-common.in | 80 68 12 0 +++++++++++++++++++++++++++++++------ /trunk/config/libc.in | 69 38 31 0 ++++++++++++++++++-------------- 6 files changed, 145 insertions(+), 52 deletions(-)
Diffstat (limited to 'config/libc')
l---------config/libc/eglibc-glibc-common.in1
-rw-r--r--config/libc/eglibc.in4
-rw-r--r--config/libc/glibc-eglibc-common.in80
-rw-r--r--config/libc/glibc.in4
-rw-r--r--config/libc/uClibc.in2
5 files changed, 74 insertions, 17 deletions
diff --git a/config/libc/eglibc-glibc-common.in b/config/libc/eglibc-glibc-common.in
deleted file mode 120000
index b1ac70d..0000000
--- a/config/libc/eglibc-glibc-common.in
+++ /dev/null
@@ -1 +0,0 @@
-glibc-eglibc-common.in \ No newline at end of file
diff --git a/config/libc/eglibc.in b/config/libc/eglibc.in
index df9e782..0a0a8b3 100644
--- a/config/libc/eglibc.in
+++ b/config/libc/eglibc.in
@@ -1,5 +1,7 @@
# eglibc options
+comment "eglibc specific options"
+
choice
bool
prompt "eglibc version"
@@ -68,5 +70,3 @@ config EGLIBC_CHECKOUT
Note that crosstool-NG will *not* update your working copy, you will
have to do that yourself.
-
-source config/libc/eglibc-glibc-common.in
diff --git a/config/libc/glibc-eglibc-common.in b/config/libc/glibc-eglibc-common.in
index 6037fad..007c524 100644
--- a/config/libc/glibc-eglibc-common.in
+++ b/config/libc/glibc-eglibc-common.in
@@ -7,6 +7,8 @@
# If mconf is updated to accept multiple inclusion of the same
# file, then the symlink can go (and the includers be updated).
+comment "glibc/eglibc common options"
+
config LIBC_GLIBC_EXTRA_CONFIG
string
prompt "extra config"
@@ -68,30 +70,57 @@ config LIBC_ADDONS_LIST
Eg.: crypt (for very old libces)
-config LIBC_GLIBC_USE_HEADERS_MIN_KERNEL
+if KERNEL_LINUX
+
+choice
bool
- prompt "Use headers version for minimum kernel version supported"
- default y
+ prompt "Minimum supported kernel version"
+ default LIBC_GLIBC_KERNEL_VERSION_AS_HEADERS
+
+config LIBC_GLIBC_KERNEL_VERSION_NONE
+ bool
+ prompt "Let ./configure decide"
help
+ Let ./configure decide what minimum kernel version glibc/eglibc
+ will be able to run against.
+
+ This will inclde legacy compatibility code for older kernels in
+ the C library, thus ensuring that it will run on a large number
+ of old kernels.
+
+ The minimum kernel version supported will be dependent upon the
+ target you build for. For example:
+ alpha*-*-linux-gnu Requires Linux 2.6.9 for NPTL
+ sh[34]-*-linux-gnu Requires Linux 2.6.11
+ powerpc* Requires Linux 2.4.19
+ arm*-*-linux-*gnueabi Requires Linux 2.6.16
+
+config LIBC_GLIBC_KERNEL_VERSION_AS_HEADERS
+ bool
+ prompt "Same as kernel headers (default)"
+ help
+ Normaly, you'll want glibc/eglibc to run against the same kernel
+ version as the one used for the headers.
+
+ This is the default.
+
If enabled, crosstool-ng will use the chosen version of kernel
headers for the glibc minimum kernel version supported, which is
what gets passed to "--enable-kernel=" when configuring glibc.
-
+
Enabling this will ensure that no legacy compatibility code for
older kernels is built into your C libraries, but it will
be unable to run on kernel versions older than whichever kernel
headers version you've built the toolchain for.
-
+
If you know for sure that your toolchain will never need to build
applications that will run under a kernel version older than your
chosen kernel headers version (CT_KERNEL_VERSION), you can choose
"y" here.
-config LIBC_GLIBC_MIN_KERNEL_CHOSEN
- string
- prompt "Minimum kernel version supported"
- default "2.6.9"
- depends on ! LIBC_GLIBC_USE_HEADERS_MIN_KERNEL
+config LIBC_GLIBC_KERNEL_VERSION_CHOSEN
+ bool
+ prompt "Specific kernel version"
help
Specify the earliest Linux kernel version you want glibc to
include support for. This does not have to match the kernel
@@ -107,7 +136,34 @@ config LIBC_GLIBC_MIN_KERNEL_CHOSEN
Most people can leave this at the default value of "2.6.9".
+if LIBC_GLIBC_KERNEL_VERSION_CHOSEN
+
+config LIBC_GLIBC_MIN_KERNEL_VERSION
+ string
+ prompt "Minimum kernel version to support"
+ default "2.6.9"
+ help
+ Enter here the lowest kernel version glibc/eglibc will be able to
+ run against.
+
+ The minimum kernel version supported will be dependent upon the
+ target you build for. For example:
+ alpha*-*-linux-gnu Requires Linux 2.6.9 for NPTL
+ sh[34]-*-linux-gnu Requires Linux 2.6.11
+ powerpc* Requires Linux 2.4.19
+ arm*-*-linux-*gnueabi Requires Linux 2.6.16
+
+ Note that no sanity check is performed by crosstool-NG to ensure
+ that the value you enter here is appropriate for your target.
+
+endif # LIBC_GLIBC_KERNEL_VERSION_CHOSEN
+
+endchoice
+
config LIBC_GLIBC_MIN_KERNEL
string
- default KERNEL_VERSION if LIBC_GLIBC_USE_HEADERS_MIN_KERNEL
- default LIBC_GLIBC_MIN_KERNEL_CHOSEN if ! LIBC_GLIBC_USE_HEADERS_MIN_KERNEL
+ default "" if LIBC_GLIBC_KERNEL_VERSION_NONE
+ default KERNEL_VERSION if LIBC_GLIBC_KERNEL_VERSION_AS_HEADERS
+ default LIBC_GLIBC_MIN_KERNEL_VERSION if LIBC_GLIBC_USE_HEADERS_MIN_KERNEL
+
+endif # KERNEL_LINUX
diff --git a/config/libc/glibc.in b/config/libc/glibc.in
index 546463b..9b25f17 100644
--- a/config/libc/glibc.in
+++ b/config/libc/glibc.in
@@ -1,5 +1,7 @@
# glibc options
+comment "glibc specific options"
+
choice
bool
prompt "glibc version"
@@ -72,5 +74,3 @@ config LIBC_GLIBC_CONFIGPARMS
Note: this is awkward, doesn't work well if you need more than one
line in configparms
-
-source config/libc/glibc-eglibc-common.in
diff --git a/config/libc/uClibc.in b/config/libc/uClibc.in
index 8de2755..885cc82 100644
--- a/config/libc/uClibc.in
+++ b/config/libc/uClibc.in
@@ -1,5 +1,7 @@
# uClibc options
+comment "uClibc specific options"
+
choice
bool
prompt "uClibc version"