aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/glibc/glibc-initial.inc
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@linux.intel.com>2010-08-27 15:14:24 +0100
committerRichard Purdie <rpurdie@linux.intel.com>2010-08-27 15:29:45 +0100
commit29d6678fd546377459ef75cf54abeef5b969b5cf (patch)
tree8edd65790e37a00d01c3f203f773fe4b5012db18 /meta/recipes-core/glibc/glibc-initial.inc
parentda49de6885ee1bc424e70bc02f21f6ab920efb55 (diff)
downloadopenembedded-core-contrib-29d6678fd546377459ef75cf54abeef5b969b5cf.tar.gz
Major layout change to the packages directory
Having one monolithic packages directory makes it hard to find things and is generally overwhelming. This commit splits it into several logical sections roughly based on function, recipes.txt gives more information about the classifications used. The opportunity is also used to switch from "packages" to "recipes" as used in OpenEmbedded as the term "packages" can be confusing to people and has many different meanings. Not all recipes have been classified yet, this is just a first pass at separating things out. Some packages are moved to meta-extras as they're no longer actively used or maintained. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'meta/recipes-core/glibc/glibc-initial.inc')
-rw-r--r--meta/recipes-core/glibc/glibc-initial.inc53
1 files changed, 53 insertions, 0 deletions
diff --git a/meta/recipes-core/glibc/glibc-initial.inc b/meta/recipes-core/glibc/glibc-initial.inc
new file mode 100644
index 0000000000..8d864db91a
--- /dev/null
+++ b/meta/recipes-core/glibc/glibc-initial.inc
@@ -0,0 +1,53 @@
+SECTION = "libs"
+DEPENDS = "virtual/${TARGET_PREFIX}gcc-initial linux-libc-headers"
+PROVIDES = "virtual/${TARGET_PREFIX}libc-initial"
+FILESPATH = "${@base_set_filespath([ '${FILE_DIRNAME}/glibc-${PV}', '${FILE_DIRNAME}/glibc-2.4', '${FILE_DIRNAME}/glibc', '${FILE_DIRNAME}/files', '${FILE_DIRNAME}' ], d)}"
+
+PACKAGES = ""
+PACKAGES_DYNAMIC = ""
+
+do_configure () {
+ sed -ie 's,{ (exit 1); exit 1; }; },{ (exit 0); }; },g' ${S}/configure
+ chmod +x ${S}/configure
+ find ${S} -name "configure" | xargs touch
+ ${S}/configure --host=${TARGET_SYS} --build=${BUILD_SYS} \
+ --without-cvs --disable-sanity-checks \
+ --with-headers=${STAGING_DIR_TARGET}${includedir} \
+ --enable-hacker-mode
+ if grep -q GLIBC_2.3 ${S}/ChangeLog; then
+ # glibc-2.3.x passes cross options to $(CC) when generating errlist-compat.c, which fails without a real cross-compiler.
+ # Fortunately, we don't need errlist-compat.c, since we just need .h files,
+ # so work around this by creating a fake errlist-compat.c and satisfying its dependencies.
+ # Another workaround might be to tell configure to not use any cross options to $(CC).
+ # The real fix would be to get install-headers to not generate errlist-compat.c.
+ make sysdeps/gnu/errlist.c
+ mkdir -p stdio-common
+ touch stdio-common/errlist-compat.c
+ fi
+}
+
+do_compile () {
+ :
+}
+
+do_install () {
+ oe_runmake cross-compiling=yes install_root=${D} \
+ includedir='${includedir}' prefix='${prefix}' \
+ install-bootstrap-headers=yes install-headers
+
+ oe_runmake csu/subdir_lib
+ # Two headers -- stubs.h and features.h -- aren't installed by install-headers,
+ # so do them by hand. We can tolerate an empty stubs.h for the moment.
+ # See e.g. http://gcc.gnu.org/ml/gcc/2002-01/msg00900.html
+ mkdir -p ${D}${includedir}/gnu/
+ touch ${D}${includedir}/gnu/stubs.h
+ cp ${S}/include/features.h ${D}${includedir}/features.h
+
+ if [ -e ${B}/bits/stdio_lim.h ]; then
+ cp ${B}/bits/stdio_lim.h ${D}${includedir}/bits/
+ fi
+ mkdir -p ${D}${libdir}/
+ install -m 644 csu/crt[1in].o ${D}${libdir}
+ ${CC} -nostdlib -nostartfiles -shared -x c /dev/null \
+ -o ${D}${libdir}/libc.so
+}