From b2f192faabe412adce79534e22efe9fb69ee40e2 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Fri, 21 Jul 2006 10:10:31 +0000 Subject: Rename /openembedded/ -> /meta/ git-svn-id: https://svn.o-hand.com/repos/poky/trunk@530 311d38ba-8fff-0310-9ca6-ca027cbcb966 --- meta/packages/alsa/alsa-lib_1.0.10.bb | 31 + meta/packages/alsa/alsa-oss_1.0.10.bb | 18 + meta/packages/alsa/alsa-tools_1.0.10.bb | 10 + meta/packages/alsa/alsa-utils_1.0.10.bb | 55 + .../alsa/files/alsa-utils-sys-siglist.patch | 15 + meta/packages/apmd/apmd-3.2.2/apmd_proxy | 91 + meta/packages/apmd/apmd-3.2.2/apmd_proxy.conf | 16 + meta/packages/apmd/apmd-3.2.2/debian.patch | 54 + meta/packages/apmd/apmd-3.2.2/default | 8 + meta/packages/apmd/apmd-3.2.2/init | 44 + meta/packages/apmd/apmd-3.2.2/workaround.patch | 55 + meta/packages/apmd/apmd-3.2.2/zaurus24.patch | 50 + meta/packages/apmd/apmd_3.2.2.bb | 64 + meta/packages/atk/atk_1.10.1.bb | 21 + .../autoconf/autoconf-2.59/autoconf-x.patch | 36 + .../autoconf259-update-configscripts.patch | 393 + .../autoheader-nonfatal-warnings.patch | 13 + .../autoconf-2.59/autoreconf-exclude.patch | 125 + .../autoconf-2.59/autoreconf-foreign.patch | 11 + .../autoconf-2.59/autoreconf-gnuconfigize.patch | 47 + .../autoconf-2.59/autoreconf-include.patch | 10 + .../autoconf/autoconf-2.59/path_prog_fixes.patch | 126 + .../autoconf/autoconf-2.59/program_prefix.patch | 19 + .../autoconf/autoconf-2.59/sizeof_types.patch | 59 + meta/packages/autoconf/autoconf-native_2.59.bb | 10 + meta/packages/autoconf/autoconf_2.59.bb | 22 + .../automake182-update-configscripts.patch | 201 + meta/packages/automake/automake-native.inc | 11 + meta/packages/automake/automake-native_1.9.3.bb | 3 + meta/packages/automake/automake.inc | 23 + meta/packages/automake/automake_1.9.3.bb | 28 + meta/packages/automake/files/path_prog_fixes.patch | 60 + meta/packages/avahi/avahi_0.6.10.bb | 58 + meta/packages/base-files/base-files/akita/fstab | 16 + meta/packages/base-files/base-files/c7x0/fstab | 12 + meta/packages/base-files/base-files/c7x0/usbd | 1 + meta/packages/base-files/base-files/collie/fstab | 8 + meta/packages/base-files/base-files/collie/usbd | 1 + meta/packages/base-files/base-files/epia/fstab | 4 + meta/packages/base-files/base-files/familiar/issue | 2 + .../base-files/base-files/familiar/issue.net | 3 + meta/packages/base-files/base-files/filesystems | 6 + meta/packages/base-files/base-files/fstab | 12 + meta/packages/base-files/base-files/h3600/fstab | 6 + meta/packages/base-files/base-files/h3900/fstab | 8 + meta/packages/base-files/base-files/host.conf | 2 + meta/packages/base-files/base-files/inputrc | 61 + .../base-files/base-files/ipaq-pxa270/fstab | 9 + meta/packages/base-files/base-files/issue | 2 + meta/packages/base-files/base-files/issue.net | 3 + .../base-files/base-files/jornada56x/fstab | 6 + .../base-files/base-files/jornada720/fstab | 6 + .../base-files/base-files/licenses/Artistic | 131 + meta/packages/base-files/base-files/licenses/BSD | 26 + meta/packages/base-files/base-files/licenses/GPL-2 | 340 + .../packages/base-files/base-files/licenses/LGPL-2 | 481 + .../base-files/base-files/licenses/LGPL-2.1 | 510 + meta/packages/base-files/base-files/motd | 0 meta/packages/base-files/base-files/mtx-1/fstab | 8 + meta/packages/base-files/base-files/mtx-1/profile | 25 + meta/packages/base-files/base-files/netvista/fstab | 5 + meta/packages/base-files/base-files/nokia770/fstab | 6 + meta/packages/base-files/base-files/nsswitch.conf | 19 + meta/packages/base-files/base-files/nylon/issue | 2 + .../packages/base-files/base-files/nylon/issue.net | 3 + meta/packages/base-files/base-files/openmn/fstab | 6 + meta/packages/base-files/base-files/openmn/issue | 2 + .../base-files/base-files/openmn/issue.net | 2 + meta/packages/base-files/base-files/openmn/profile | 31 + meta/packages/base-files/base-files/openmn/usbd | 1 + .../base-files/base-files/opensimpad/issue | 2 + .../base-files/base-files/opensimpad/issue.net | 2 + .../base-files/base-files/openzaurus/issue | 2 + .../base-files/base-files/openzaurus/issue.net | 2 + meta/packages/base-files/base-files/poodle/fstab | 13 + meta/packages/base-files/base-files/poodle/usbd | 1 + meta/packages/base-files/base-files/profile | 32 + .../base-files/base-files/share/dot.bashrc | 16 + .../base-files/base-files/share/dot.profile | 10 + meta/packages/base-files/base-files/simpad/fstab | 8 + meta/packages/base-files/base-files/spitz/fstab | 28 + meta/packages/base-files/base-files/tosa/fstab | 12 + meta/packages/base-files/base-files/tosa/usbd | 1 + meta/packages/base-files/base-files/usbd | 0 meta/packages/base-files/base-files/wrt54/fstab | 7 + meta/packages/base-files/base-files/wrt54/profile | 25 + meta/packages/base-files/base-files/xxs1500/fstab | 8 + meta/packages/base-files/base-files_3.0.14.bb | 154 + .../base-passwd/base-passwd-3.5.9/configure.patch | 23 + .../base-passwd/base-passwd-3.5.9/mysql.patch | 8 + .../base-passwd/base-passwd-3.5.9/nobash.patch | 13 + .../base-passwd/base-passwd-3.5.9/root-home.patch | 8 + meta/packages/base-passwd/base-passwd_3.5.9.bb | 59 + .../binutils-100_cflags_for_build.patch | 91 + ...tils-2.15.90.0.3-uclibc-200-build_modules.patch | 33 + .../binutils-2.15.90.0.3-uclibc-210-cflags.patch | 30 + .../binutils-2.15.91.0.1-uclibc-100-conf.patch | 604 + ...tils-2.16.91.0.6-objcopy-rename-errorcode.patch | 31 + .../binutils-uclibc-100-uclibc-conf.patch | 139 + ...binutils-uclibc-300-001_ld_makefile_patch.patch | 50 + ...binutils-uclibc-300-006_better_file_error.patch | 43 + ...ils-uclibc-300-012_check_ldrunpath_length.patch | 47 + ...nutils-uclibc-400-mips-ELF_MAXPAGESIZE-4K.patch | 26 + ...inutils-uclibc-702-binutils-skip-comments.patch | 93 + .../binutils-100_cflags_for_build.patch | 28 + .../binutils-2.16/binutils-2.16-linux-uclibc.patch | 700 + .../binutils-2.16-objcopy-rename-errorcode.patch | 29 + .../binutils-2.16/binutils-2.16-thumb-glue.patch | 76 + .../binutils-2.16-thumb-trampoline.patch | 292 + meta/packages/binutils/binutils-cross.inc | 30 + .../binutils/binutils-cross_2.15.94.0.1.bb | 32 + .../binutils/binutils-cross_2.16.91.0.7.bb | 32 + meta/packages/binutils/binutils-cross_2.16.bb | 3 + meta/packages/binutils/binutils.inc | 117 + meta/packages/binutils/binutils_2.15.94.0.1.bb | 124 + meta/packages/binutils/binutils_2.16.91.0.7.bb | 123 + meta/packages/binutils/binutils_2.16.bb | 26 + .../binutils/files/better_file_error.patch | 17 + meta/packages/binutils/files/ld_makefile.patch | 22 + meta/packages/binutils/files/objdump_fix.patch | 134 + meta/packages/binutils/files/plt32trunc.patch | 24 + meta/packages/binutils/files/signed_char_fix.patch | 12 + meta/packages/bison/bison-2.0/m4.patch | 589 + meta/packages/bison/bison-native_2.0.bb | 21 + meta/packages/bison/bison_2.0.bb | 10 + .../busybox/busybox-1.01/add-getkey-applet.patch | 157 + .../busybox/busybox-1.01/angstrom/defconfig | 475 + meta/packages/busybox/busybox-1.01/below.patch | 49 + meta/packages/busybox/busybox-1.01/defconfig | 476 + .../busybox/busybox-1.01/dhcp-hostname.patch | 30 + .../busybox/busybox-1.01/dhcpretrytime.patch | 81 + .../busybox/busybox-1.01/familiar/defconfig | 470 + meta/packages/busybox/busybox-1.01/fbset.patch | 24 + meta/packages/busybox/busybox-1.01/hdparm_M.patch | 47 + .../busybox-1.01/ifupdown-spurious-environ.patch | 12 + .../busybox/busybox-1.01/iproute-flush-cache.patch | 23 + .../busybox/busybox-1.01/mount-all-type.patch | 84 + meta/packages/busybox/busybox-1.01/nylon/defconfig | 458 + .../packages/busybox/busybox-1.01/openmn/defconfig | 475 + .../busybox/busybox-1.01/openzaurus/defconfig | 475 + meta/packages/busybox/busybox-1.01/readlink.patch | 85 + meta/packages/busybox/busybox-1.01/rmmod.patch | 44 + .../packages/busybox/busybox-1.01/slugos/defconfig | 444 + .../busybox/busybox-1.01/slugos/sysctl.conf | 32 + .../busybox/busybox-1.01/slugos/udhcpscript.patch | 162 + meta/packages/busybox/busybox-1.01/sparc/defconfig | 467 + .../busybox/busybox-1.01/thumb-bsdlabel.patch | 11 + .../busybox/busybox-1.01/uclibc_posix.patch | 20 + .../busybox-1.01/udhcppidfile-breakage.patch | 57 + .../busybox/busybox-1.01/udhcppidfile.patch | 276 + .../busybox/busybox-1.01/udhcpscript.patch | 17 + meta/packages/busybox/busybox-1.01/wrt54/defconfig | 476 + meta/packages/busybox/busybox_1.01.bb | 169 + meta/packages/busybox/files/busybox-cron | 39 + meta/packages/busybox/files/busybox-httpd | 44 + meta/packages/busybox/files/busybox-udhcpd | 43 + meta/packages/busybox/files/default.script | 4 + meta/packages/busybox/files/glibc2.4-icmp6.patch | 15 + meta/packages/busybox/files/hwclock.sh | 74 + meta/packages/busybox/files/mount.busybox | 3 + meta/packages/busybox/files/postinst | 25 + meta/packages/busybox/files/prerm | 10 + meta/packages/busybox/files/syslog | 69 + meta/packages/busybox/files/syslog.conf | 9 + meta/packages/busybox/files/umount.busybox | 3 + meta/packages/bzip2/bzip2-1.0.2/installpaths.patch | 103 + meta/packages/bzip2/bzip2_1.0.2.bb | 41 + meta/packages/cairo/cairo_1.0.0.bb | 15 + meta/packages/cairo/cairo_1.0.4.bb | 13 + meta/packages/cairo/cairo_1.2.0.bb | 15 + meta/packages/chkhinge26/chkhinge26_svn.bb | 20 + meta/packages/chkhinge26/files/hinge-handler | 47 + meta/packages/compositeext/compositeext_cvs.bb | 20 + .../console-tools-0.3.2/codepage.patch | 16 + .../console-tools-0.3.2/compile.patch | 10 + .../console-tools-0.3.2/config/codeset.m4 | 17 + .../console-tools-0.3.2/config/gettext.m4 | 370 + .../console-tools-0.3.2/config/glibc21.m4 | 26 + .../console-tools-0.3.2/config/iconv.m4 | 69 + .../console-tools-0.3.2/config/lcmessage.m4 | 24 + .../console-tools-0.3.2/config/progtest.m4 | 51 + .../console-tools-0.3.2/configure.patch | 46 + .../console-tools-0.3.2/kbdrate.patch | 73 + .../console-tools-0.3.2/uclibc-fileno.patch | 47 + meta/packages/console-tools/console-tools_0.3.2.bb | 48 + meta/packages/contacts/contacts_0.1.bb | 24 + meta/packages/contacts/contacts_svn.bb | 30 + meta/packages/contacts/files/stock_contact.png | Bin 0 -> 2311 bytes meta/packages/contacts/files/stock_person.png | Bin 0 -> 2280 bytes .../coreutils/coreutils-5.1.3/install-cross.patch | 27 + meta/packages/coreutils/coreutils-5.1.3/man.patch | 42 + meta/packages/coreutils/coreutils-native_5.1.3.bb | 7 + meta/packages/coreutils/coreutils_5.1.3.bb | 85 + meta/packages/curl/curl-native_7.14.0.bb | 13 + meta/packages/curl/curl_7.14.0.bb | 38 + .../packages/damageext/damageext-1.0/autofoo.patch | 18 + meta/packages/damageext/damageext_cvs.bb | 20 + meta/packages/dates/dates_0.1.bb | 19 + meta/packages/dates/dates_svn.bb | 19 + meta/packages/db/db-native_4.2.52.bb | 13 + meta/packages/db/db_4.1.25.bb | 87 + meta/packages/db/db_4.2.52.bb | 97 + meta/packages/db/db_4.3.29.bb | 100 + meta/packages/db/files/arm-thumb-mutex.patch | 36 + meta/packages/dbus/dbus-0.60/dbus-1.init | 86 + meta/packages/dbus/dbus-0.60/no-bindings.patch | 12 + meta/packages/dbus/dbus-0.60/no-introspect.patch | 14 + meta/packages/dbus/dbus-native_0.50.bb | 19 + meta/packages/dbus/dbus-native_0.60.bb | 19 + meta/packages/dbus/dbus.inc | 65 + meta/packages/dbus/dbus/0.23.1.diff | 308 + meta/packages/dbus/dbus/config.diff | 17 + meta/packages/dbus/dbus/cross.patch | 15 + meta/packages/dbus/dbus/dbus-1.init | 86 + meta/packages/dbus/dbus/dbus-monitor.patch | 150 + .../dbus/dbus/dbus-quiesce-startup-errors.patch | 23 + meta/packages/dbus/dbus/dbussend.patch | 399 + meta/packages/dbus/dbus/gettext.patch | 164 + meta/packages/dbus/dbus/no-bindings.patch | 12 + meta/packages/dbus/dbus/no-examples.patch | 8 + meta/packages/dbus/dbus/no-introspect.patch | 19 + meta/packages/dbus/dbus/spawn-priority.diff | 17 + meta/packages/dbus/dbus/tmpdir.patch | 30 + meta/packages/dbus/dbus/tools.diff | 12 + meta/packages/dbus/dbus_0.60.bb | 13 + meta/packages/dbus/dbus_0.60.inc | 64 + meta/packages/dropbear/dropbear.inc | 73 + meta/packages/dropbear/dropbear/allow-nopw.patch | 37 + .../dropbear/chansession-security-fix.patch | 74 + meta/packages/dropbear/dropbear/configure.patch | 27 + meta/packages/dropbear/dropbear/fix-2kb-keys.patch | 11 + meta/packages/dropbear/dropbear/init | 98 + .../urandom-xauth-changes-to-options.h.patch | 21 + meta/packages/dropbear/dropbear_0.47.bb | 3 + .../e2fsprogs/e2fsprogs-1.38/no-hardlinks.patch | 82 + .../e2fsprogs/e2fsprogs/compile-subst.patch | 16 + meta/packages/e2fsprogs/e2fsprogs/configure.patch | 122 + .../packages/e2fsprogs/e2fsprogs/e2fsprogs_1.34.bb | 18 + meta/packages/e2fsprogs/e2fsprogs/ldflags.patch | 27 + meta/packages/e2fsprogs/e2fsprogs/ln.patch | 58 + meta/packages/e2fsprogs/e2fsprogs/m4.patch | 2155 + meta/packages/e2fsprogs/e2fsprogs_1.38.bb | 50 + meta/packages/eds/eds-dbus/disable_orbit.patch | 13 + meta/packages/eds/eds-dbus/fix_calendar.patch | 11 + meta/packages/eds/eds-dbus/iconv-detect.h | 5 + meta/packages/eds/eds-dbus/no_iconv_test.patch | 70 + meta/packages/eds/eds-dbus/no_libdb.patch | 14 + .../eds/eds-dbus/no_libedataserverui.patch | 13 + meta/packages/eds/eds-dbus/no_libgnome.patch | 45 + meta/packages/eds/eds-dbus_svn.bb | 40 + meta/packages/expat/expat-1.95.7/autotools.patch | 13 + meta/packages/expat/expat-native_1.95.7.bb | 4 + meta/packages/expat/expat_1.95.7.bb | 30 + meta/packages/fakeroot/fakeroot-native_1.2.13.bb | 19 + meta/packages/fakeroot/fakeroot_1.2.13.bb | 8 + meta/packages/fakeroot/files/fix-prefix.patch | 18 + meta/packages/file/file-native_4.16.bb | 8 + meta/packages/file/file_4.16.bb | 18 + meta/packages/file/files/native-fix.diff | 13 + meta/packages/fixesext/fixesext_cvs.bb | 20 + meta/packages/flex/files/fix-gen.patch | 17 + meta/packages/flex/files/flex-lvalue.diff | 36 + meta/packages/flex/flex-2.5.31/include.patch | 27 + meta/packages/flex/flex-native_2.5.31.bb | 10 + meta/packages/flex/flex.inc | 11 + meta/packages/flex/flex_2.5.31.bb | 9 + meta/packages/fontconfig/files/local.conf | 12 + meta/packages/fontconfig/files/stop-fc-cache.patch | 8 + .../fontconfig-2.2.95/fc-glyphname.patch | 19 + .../fontconfig/fontconfig-2.2.95/fc-lang.patch | 18 + .../fontconfig/fontconfig-native_2.2.95.bb | 15 + meta/packages/fontconfig/fontconfig_2.2.95.bb | 36 + meta/packages/freetype/files/configure.patch | 47 + meta/packages/freetype/files/no-hardcode.patch | 11 + meta/packages/freetype/freetype-native_2.1.10.bb | 21 + meta/packages/freetype/freetype_2.1.10.bb | 32 + meta/packages/galago/eds-feed/disable-bonobo.patch | 62 + meta/packages/galago/eds-feed_0.3.2.bb | 14 + meta/packages/galago/files/no-check.patch | 15 + meta/packages/galago/galago-daemon_0.3.4.bb | 15 + meta/packages/galago/libgalago_0.3.3.bb | 18 + .../packages/gcalctool/gcalctool/makefile-fix.diff | 18 + meta/packages/gcalctool/gcalctool_5.7.32.bb | 13 + meta/packages/gcc/gcc-3.3.4/arm-gotoff.dpatch | 135 + meta/packages/gcc/gcc-3.3.4/arm-ldm-peephole.patch | 91 + meta/packages/gcc/gcc-3.3.4/arm-ldm.dpatch | 148 + meta/packages/gcc/gcc-3.3.4/arm-tune.patch | 9 + meta/packages/gcc/gcc-3.3.4/bash3.patch | 20 + .../gcc/gcc-3.3.4/gcc-uclibc-3.3-100-conf.patch | 1593 + .../gcc/gcc-3.3.4/gcc-uclibc-3.3-110-conf.patch | 55 + .../gcc-3.3.4/gcc-uclibc-3.3-120-softfloat.patch | 14 + .../gcc/gcc-3.3.4/gcc-uclibc-3.3-200-code.patch | 3021 ++ meta/packages/gcc/gcc-3.3.4/gcc34-15089.patch | 19 + .../gcc/gcc-3.3.4/libibery-crosstool.patch | 683 + meta/packages/gcc/gcc-3.3.4/reverse-compare.patch | 31 + .../gcc/gcc-3.3.4/sdk-libstdc++-includes.patch | 48 + meta/packages/gcc/gcc-3.4.3/15342.patch | 22 + .../gcc/gcc-3.4.3/GCC3.4.0VisibilityPatch.diff | 1100 + .../packages/gcc/gcc-3.4.3/always-fixincperm.patch | 32 + .../gcc-3.4.3/gcc-3.4.0-arm-bigendian-uclibc.patch | 30 + .../gcc/gcc-3.4.3/gcc-3.4.0-arm-bigendian.patch | 70 + .../gcc/gcc-3.4.3/gcc-3.4.0-arm-lib1asm.patch | 24 + .../gcc/gcc-3.4.3/gcc-3.4.0-arm-nolibfloat.patch | 24 + .../gcc/gcc-3.4.3/gcc-3.4.0-arm-softfloat.patch | 256 + .../gcc/gcc-3.4.3/gcc-3.4.1-uclibc-100-conf.patch | 442 + .../gcc-3.4.3/gcc-3.4.1-uclibc-200-locale.patch | 3246 ++ .../gcc-3.4.3/gcc-uclibc-3.4.0-120-softfloat.patch | 14 + .../gcc/gcc-3.4.3/gcc34-arm-ldm-peephole.patch | 79 + meta/packages/gcc/gcc-3.4.3/gcc34-arm-ldm.patch | 119 + meta/packages/gcc/gcc-3.4.3/gcc34-arm-tune.patch | 9 + .../gcc/gcc-3.4.3/gcc34-reverse-compare.patch | 32 + .../gcc/gcc-3.4.3/sdk-libstdc++-includes.patch | 22 + meta/packages/gcc/gcc-3.4.4/15342.patch | 22 + .../gcc/gcc-3.4.4/GCC3.4.0VisibilityPatch.diff | 1100 + .../packages/gcc/gcc-3.4.4/always-fixincperm.patch | 32 + .../gcc-3.4.4/gcc-3.4.0-arm-bigendian-uclibc.patch | 30 + .../gcc/gcc-3.4.4/gcc-3.4.0-arm-bigendian.patch | 70 + .../gcc/gcc-3.4.4/gcc-3.4.0-arm-lib1asm.patch | 24 + .../gcc/gcc-3.4.4/gcc-3.4.0-arm-nolibfloat.patch | 24 + .../gcc/gcc-3.4.4/gcc-3.4.0-arm-softfloat.patch | 256 + .../gcc/gcc-3.4.4/gcc-3.4.1-uclibc-100-conf.patch | 442 + .../gcc-3.4.4/gcc-3.4.1-uclibc-200-locale.patch | 3246 ++ .../gcc-3.4.4/gcc-uclibc-3.4.0-120-softfloat.patch | 14 + .../gcc/gcc-3.4.4/gcc34-arm-ldm-peephole.patch | 79 + meta/packages/gcc/gcc-3.4.4/gcc34-arm-ldm.patch | 119 + meta/packages/gcc/gcc-3.4.4/gcc34-arm-tune.patch | 9 + .../gcc/gcc-3.4.4/gcc34-configure.in.patch | 22 + .../gcc/gcc-3.4.4/gcc34-reverse-compare.patch | 32 + .../gcc/gcc-3.4.4/gcc34-thumb-support.patch | 156 + .../gcc/gcc-3.4.4/sdk-libstdc++-includes.patch | 22 + meta/packages/gcc/gcc-4.0.2/100-uclibc-conf.patch | 556 + .../packages/gcc/gcc-4.0.2/200-uclibc-locale.patch | 3240 ++ .../gcc/gcc-4.0.2/301-missing-execinfo_h.patch | 14 + meta/packages/gcc/gcc-4.0.2/302-c99-snprintf.patch | 14 + .../gcc/gcc-4.0.2/303-c99-complex-ugly-hack.patch | 15 + .../packages/gcc/gcc-4.0.2/800-arm-bigendian.patch | 70 + meta/packages/gcc/gcc-4.0.2/arm-nolibfloat.patch | 24 + meta/packages/gcc/gcc-4.0.2/arm-softfloat.patch | 16 + meta/packages/gcc/gcc-4.0.2/ldflags.patch | 22 + .../gcc/gcc-4.0.2/zecke-host-cpp-ac-hack.patch | 140 + meta/packages/gcc/gcc-cross-initial_3.3.4.bb | 28 + meta/packages/gcc/gcc-cross-initial_3.4.3.bb | 28 + meta/packages/gcc/gcc-cross-initial_3.4.4.bb | 28 + meta/packages/gcc/gcc-cross-initial_4.0.2.bb | 29 + .../gcc/gcc-cross-initial_csl-arm-2005q3.bb | 28 + meta/packages/gcc/gcc-cross_3.3.4.bb | 13 + meta/packages/gcc/gcc-cross_3.4.3.bb | 16 + meta/packages/gcc/gcc-cross_3.4.4.bb | 16 + meta/packages/gcc/gcc-cross_4.0.2.bb | 16 + meta/packages/gcc/gcc-cross_csl-arm-2005q3.bb | 15 + meta/packages/gcc/gcc-csl-arm/15342.patch | 22 + .../gcc/gcc-csl-arm/gcc-3.4.0-arm-lib1asm.patch | 24 + meta/packages/gcc/gcc-csl-arm/gcc34-arm-tune.patch | 9 + meta/packages/gcc/gcc-csl-arm/gcc_optab_arm.patch | 95 + meta/packages/gcc/gcc-csl-arm/no-libfloat.patch | 11 + meta/packages/gcc/gcc-csl-arm/pic-without-sl.patch | 303 + meta/packages/gcc/gcc-package-cross.inc | 77 + meta/packages/gcc/gcc-package.inc | 111 + meta/packages/gcc/gcc-paths-cross.inc | 7 + meta/packages/gcc/gcc3-build-cross.inc | 47 + meta/packages/gcc/gcc3-build.inc | 95 + meta/packages/gcc/gcc4-build.inc | 6 + meta/packages/gcc/gcc_3.3.4.bb | 176 + meta/packages/gcc/gcc_3.4.3.bb | 27 + meta/packages/gcc/gcc_3.4.4.bb | 30 + meta/packages/gcc/gcc_4.0.2.bb | 28 + meta/packages/gcc/gcc_csl-arm-2005q3.bb | 27 + meta/packages/gdb/files/gdbserver-cflags-last.diff | 13 + meta/packages/gdb/files/kill_arm_map_symbols.patch | 24 + meta/packages/gdb/files/libiberty-cross.patch | 630 + meta/packages/gdb/files/sim-install.patch | 34 + meta/packages/gdb/files/uclibc.patch | 194 + meta/packages/gdb/gdb-6.3/uclibc.patch | 194 + meta/packages/gdb/gdb-cross_6.3.bb | 36 + meta/packages/gdb/gdb_6.3.bb | 50 + meta/packages/gdbm/gdbm-1.8.3/libtool-mode.patch | 20 + meta/packages/gdbm/gdbm-1.8.3/makefile.patch | 59 + .../packages/gdbm/gdbm-native-1.8.3/makefile.patch | 59 + meta/packages/gdbm/gdbm-native_1.8.3.bb | 17 + meta/packages/gdbm/gdbm_1.8.3.bb | 17 + .../genext2fs/genext2fs-1.3/autosize.patch | 339 + meta/packages/genext2fs/genext2fs-1.3/misc.patch | 2143 + meta/packages/genext2fs/genext2fs-native_1.3.bb | 11 + meta/packages/genext2fs/genext2fs.inc | 4 + meta/packages/genext2fs/genext2fs_1.3.bb | 15 + .../gettext/gettext-0.14.1/fixchicken.patch | 26 + .../gettext/gettext-0.14.1/gettext-vpath.patch | 11 + meta/packages/gettext/gettext-native_0.14.1.bb | 53 + meta/packages/gettext/gettext_0.14.1.bb | 33 + meta/packages/glib-2.0/files/atomic_fix.patch | 16 + .../glib-2.0/files/glib-gettextize-dir.patch | 11 + meta/packages/glib-2.0/files/glibconfig-sysdefs.h | 6 + meta/packages/glib-2.0/files/glibinclude.patch | 18 + .../glib-gettextize-dir.patch | 11 + meta/packages/glib-2.0/glib-2.0-native_2.10.3.bb | 55 + meta/packages/glib-2.0/glib-2.0-native_2.12.0.bb | 54 + meta/packages/glib-2.0/glib-2.0-native_2.6.5.bb | 49 + meta/packages/glib-2.0/glib-2.0_2.10.3.bb | 48 + meta/packages/glib-2.0/glib-2.0_2.12.0.bb | 47 + meta/packages/glib-2.0/glib-2.0_2.6.4.bb | 49 + meta/packages/glib-2.0/glib-2.0_2.8.6.bb | 49 + .../glibc/files/5090_all_stubs-rule-fix.patch | 39 + meta/packages/glibc/files/etc/ld.so.conf | 3 + meta/packages/glibc/files/fhs-linux-paths.patch | 11 + meta/packages/glibc/files/generate-supported.mk | 11 + meta/packages/glibc/glibc-2.4/arm-longlong.patch | 58 + meta/packages/glibc/glibc-2.4/arm-memcpy.patch | 758 + .../packages/glibc/glibc-2.4/dl-cache-libcmp.patch | 10 + .../glibc/glibc-2.4/dyn-ldconfig-20041128.patch | 22 + meta/packages/glibc/glibc-2.4/dyn-ldconfig.patch | 62 + meta/packages/glibc/glibc-2.4/etc/ld.so.conf | 3 + .../glibc/glibc-2.4/fixup-aeabi-syscalls.patch | 329 + .../packages/glibc/glibc-2.4/generic-bits_select.h | 35 + meta/packages/glibc/glibc-2.4/generic-bits_time.h | 75 + meta/packages/glibc/glibc-2.4/generic-bits_types.h | 200 + .../glibc/glibc-2.4/generic-bits_typesizes.h | 66 + .../glibc/glibc-2.4/glibc-2.4-compile.patch | 29 + .../glibc/glibc-2.4/ldsocache-varrun.patch | 18 + .../glibc/glibc-2.4/nptl-crosscompile.patch | 26 + .../packages/glibc/glibc-cvs-2.3.5/arm-audit.patch | 58 + .../glibc/glibc-cvs-2.3.5/arm-audit2.patch | 18 + .../glibc/glibc-cvs-2.3.5/arm-longlong.patch | 59 + .../glibc/glibc-cvs-2.3.5/arm-memcpy.patch | 758 + .../glibc/glibc-cvs-2.3.5/arm-no-hwcap.patch | 11 + .../glibc/glibc-cvs-2.3.5/dl-cache-libcmp.patch | 10 + .../glibc-cvs-2.3.5/dyn-ldconfig-20041128.patch | 22 + .../glibc/glibc-cvs-2.3.5/ldsocache-varrun.patch | 18 + meta/packages/glibc/glibc-cvs/arm-ioperm.patch | 13 + meta/packages/glibc/glibc-cvs/arm-longlong.patch | 59 + .../glibc/glibc-cvs/arm-machine-gmon.patch | 11 + meta/packages/glibc/glibc-cvs/arm-memcpy.patch | 758 + meta/packages/glibc/glibc-cvs/arm-no-hwcap.patch | 11 + .../glibc/glibc-cvs/dyn-ldconfig-20041128.patch | 22 + meta/packages/glibc/glibc-cvs/dyn-ldconfig.patch | 62 + meta/packages/glibc/glibc-cvs/eabi-patch-1 | 88 + meta/packages/glibc/glibc-cvs/eabi-patch-2 | 2446 ++ meta/packages/glibc/glibc-cvs/eabi-patch-3 | 430 + meta/packages/glibc/glibc-cvs/eabi-patch-4 | 64 + meta/packages/glibc/glibc-cvs/etc/ld.so.conf | 3 + .../glibc/glibc-cvs/glibc-fp-byteorder.patch | 203 + meta/packages/glibc/glibc-cvs/ldconfig.patch | 37 + meta/packages/glibc/glibc-cvs/ldd.patch | 38 + .../glibc/glibc-cvs/ldsocache-varrun.patch | 18 + meta/packages/glibc/glibc-cvs/makeconfig.patch | 15 + meta/packages/glibc/glibc-cvs/mips-no-throw.patch | 22 + meta/packages/glibc/glibc-cvs/noinfo.patch | 52 + meta/packages/glibc/glibc-cvs/trampoline.patch | 560 + meta/packages/glibc/glibc-initial_2.4.bb | 46 + meta/packages/glibc/glibc-intermediate_2.4.bb | 14 + meta/packages/glibc/glibc-package.bbclass | 300 + meta/packages/glibc/glibc_2.3.5+cvs20050627.bb | 175 + meta/packages/glibc/glibc_2.4.bb | 201 + meta/packages/gmp/gmp-4.1.2/amd64.patch | 16 + meta/packages/gmp/gmp-4.1.2/configure.patch | 864 + meta/packages/gmp/gmp-4.1.2/gcc-compile.patch | 72 + meta/packages/gmp/gmp-4.1.4/amd64.patch | 14 + meta/packages/gmp/gmp-4.1.4/configure.patch | 837 + meta/packages/gmp/gmp-4.1.4/sh4-asmfix.patch | 26 + meta/packages/gmp/gmp-native_4.1.2.bb | 7 + meta/packages/gmp/gmp_4.1.2.bb | 18 + meta/packages/gmp/gmp_4.1.4.bb | 19 + meta/packages/gnome/files/gtk-doc.m4 | 53 + meta/packages/gnome/files/gtk-doc.make | 148 + meta/packages/gnome/gconf-2.6.1/backends.patch | 13 + meta/packages/gnome/gconf-dbus/69gconfd-dbus | 3 + .../gnome/gconf-dbus/gconf-dbus-update.patch | 31 + .../packages/gnome/gconf-dbus/no-deprecation.patch | 11 + .../gnome/gconf-dbus/remove-old-translations.patch | 11 + .../gconf-dbus/xml-backend-locks-compile-fix.patch | 16 + .../gconf-dbus/xml-backend-oldxml-Makefile.patch | 11 + meta/packages/gnome/gconf-dbus_cvs.bb | 38 + meta/packages/gnome/gconf-dbus_svn.bb | 49 + meta/packages/gnome/gconf_2.6.1.bb | 33 + meta/packages/gnome/gnome-common/omf.patch | 13 + meta/packages/gnome/gnome-common_2.4.0.bb | 28 + meta/packages/gnome/gnome-mime-data_2.4.2.bb | 7 + .../gnome/gnome-vfs-dbus/gconftool-lossage.patch | 11 + meta/packages/gnome/gnome-vfs-dbus/gssapi.patch | 13 + .../packages/gnome/gnome-vfs-dbus/no-gtk-doc.patch | 24 + .../gnome-vfs-dbus/remove-old-translations.patch | 11 + meta/packages/gnome/gnome-vfs-dbus_2.8.4.4.bb | 91 + meta/packages/gnome/gnome-vfs-dbus_cvs.bb | 102 + meta/packages/gnome/libart-lgpl/Makefile.am.patch | 13 + meta/packages/gnome/libart-lgpl/arm/art_config.h | 10 + meta/packages/gnome/libart-lgpl/i386/art_config.h | 10 + meta/packages/gnome/libart-lgpl/i586/art_config.h | 10 + meta/packages/gnome/libart-lgpl/i686/art_config.h | 10 + meta/packages/gnome/libart-lgpl_2.3.16.bb | 30 + meta/packages/gnome/libgnomecanvas_2.6.1.1.bb | 16 + meta/packages/gnome/libsoup_2.2.7.bb | 18 + .../gnome/orbit2-2.10.2/configure-lossage.patch | 35 + meta/packages/gnome/orbit2-native_2.10.2.bb | 21 + meta/packages/gnome/orbit2_2.10.2.bb | 46 + .../gnu-config/gnu-config-native_20050701.bb | 15 + .../gnu-config/config-guess-uclibc.patch | 155 + .../gnu-config/gnu-config/gnu-configize.in | 267 + meta/packages/gnu-config/gnu-config/uclibc.patch | 21 + meta/packages/gnu-config/gnu-config_20050701.bb | 32 + .../gnutls/gnutls-1.0.25/export-symbols.patch | 11 + .../gnutls/gnutls-1.0.25/gnutls-openssl.patch | 126 + meta/packages/gnutls/gnutls_1.0.25.bb | 29 + meta/packages/gtk+/files/migration.patch | 619 + .../gtk+/gtk+-2.10.0/automake-lossage.patch | 24 + .../gtk+/gtk+-2.10.0/cellrenderer-cairo.patch | 32 + .../gtk+/gtk+-2.10.0/disable-tooltips.patch | 11 + meta/packages/gtk+/gtk+-2.10.0/entry-cairo.patch | 114 + .../packages/gtk+/gtk+-2.10.0/gtk+-handhelds.patch | 264 + meta/packages/gtk+/gtk+-2.10.0/gtkbuiltincache.h | 31864 ++++++++++++++ .../gtk+/gtk+-2.10.0/gtklabel-resize-patch | 10 + .../gtk+/gtk+-2.10.0/gtktreeview-316689.patch | 25 + .../gtk+/gtk+-2.10.0/hardcoded_libtool.patch | 29 + .../gtk+/gtk+-2.10.0/menu-deactivate.patch | 50 + meta/packages/gtk+/gtk+-2.10.0/no-demos.patch | 10 + .../gtk+-2.10.0/no-generate-builtincache.patch | 33 + meta/packages/gtk+/gtk+-2.10.0/no-xwc.patch | 179 + .../packages/gtk+/gtk+-2.10.0/scroll-timings.patch | 15 + meta/packages/gtk+/gtk+-2.10.0/single-click.patch | 36 + .../gtk+/gtk+-2.10.0/small-gtkfilesel.patch | 267 + meta/packages/gtk+/gtk+-2.10.0/spinbutton.patch | 128 + meta/packages/gtk+/gtk+-2.10.0/style-cairo.patch | 2193 + meta/packages/gtk+/gtk+-2.10.0/xsettings.patch | 16 + .../000_gtk+-2.0.6-exportsymbols.patch | 26 + .../000_gtk+-2.2.0-buildfix-immodule.patch | 33 + .../gtk+/gtk+-2.6.4-1.osso7/002_xpmico.patch | 18 + .../gtk+/gtk+-2.6.4-1.osso7/003_iconcache.patch | 11 + .../gtk+/gtk+-2.6.4-1.osso7/automake-lossage.patch | 24 + .../gtk+/gtk+-2.6.4-1.osso7/configure.diff | 1885 + .../gtk+/gtk+-2.6.4-1.osso7/configure.in.diff | 53 + .../gtk+/gtk+-2.6.4-1.osso7/disable-tooltips.patch | 11 + .../gtk+/gtk+-2.6.4-1.osso7/gdkwindow-x11.c.diff | 38 + .../gtk+/gtk+-2.6.4-1.osso7/gtk+-handhelds.patch | 236 + meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtk.h.diff | 10 + .../gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.am.diff | 27 + .../gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.in.diff | 292 + .../gtk+/gtk+-2.6.4-1.osso7/gtkalias.h.diff | 17 + .../gtk+/gtk+-2.6.4-1.osso7/gtkbutton.c.diff | 471 + .../gtk+/gtk+-2.6.4-1.osso7/gtkbutton.h.diff | 23 + .../gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.c.diff | 2464 ++ .../gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.h.diff | 12 + .../gtk+-2.6.4-1.osso7/gtkcellrenderertext.c.diff | 66 + .../gtkcellrenderertoggle.c.diff | 11 + .../gtk+/gtk+-2.6.4-1.osso7/gtkcellview.c.diff | 19 + .../gtk+/gtk+-2.6.4-1.osso7/gtkcellview.h.diff | 10 + .../gtk+/gtk+-2.6.4-1.osso7/gtkcheckbutton.c.diff | 520 + .../gtk+/gtk+-2.6.4-1.osso7/gtkcombobox.c.diff | 950 + .../gtk+-2.6.4-1.osso7/gtkcomboboxentry.c.diff | 24 + .../gtk+/gtk+-2.6.4-1.osso7/gtkcontainer.c.diff | 284 + .../gtk+/gtk+-2.6.4-1.osso7/gtkdialog.c.diff | 451 + .../packages/gtk+/gtk+-2.6.4-1.osso7/gtkdnd.c.diff | 12 + .../gtk+/gtk+-2.6.4-1.osso7/gtkentry.c.diff | 1308 + .../gtk+/gtk+-2.6.4-1.osso7/gtkenums.h.diff | 15 + .../gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.c.diff | 12 + .../gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.h.diff | 12 + .../gtk+/gtk+-2.6.4-1.osso7/gtkframe.c.diff | 82 + .../gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.c.diff | 102 + .../gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.h.diff | 64 + .../gtk+/gtk+-2.6.4-1.osso7/gtkhbbox.c.diff | 344 + .../gtk+/gtk+-2.6.4-1.osso7/gtkhseparator.c.diff | 40 + .../gtk+/gtk+-2.6.4-1.osso7/gtkiconfactory.c.diff | 69 + .../gtk+/gtk+-2.6.4-1.osso7/gtkicontheme.c.diff | 48 + .../gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.c.diff | 52 + .../gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.h.diff | 29 + .../gtk+-2.6.4-1.osso7/gtkimmulticontext.c.diff | 155 + .../gtk+/gtk+-2.6.4-1.osso7/gtklabel-resize-patch | 10 + .../gtk+/gtk+-2.6.4-1.osso7/gtklabel.c.diff | 390 + .../gtk+/gtk+-2.6.4-1.osso7/gtklabel.h.diff | 29 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmain.c.diff | 35 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.c.diff | 266 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.h.diff | 284 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.c.diff | 606 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.h.diff | 622 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmenu.c.diff | 1223 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmenu.h.diff | 12 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.c.diff | 457 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.h.diff | 10 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.c.diff | 490 + .../gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.h.diff | 12 + .../gtk+/gtk+-2.6.4-1.osso7/gtknotebook.c.diff | 831 + .../gtk+/gtk+-2.6.4-1.osso7/gtkprogress.c.diff | 20 + .../gtk+/gtk+-2.6.4-1.osso7/gtkprogressbar.c.diff | 141 + .../gtk+/gtk+-2.6.4-1.osso7/gtkradiobutton.c.diff | 244 + .../gtk+/gtk+-2.6.4-1.osso7/gtkrange.c.diff | 845 + .../gtk+/gtk+-2.6.4-1.osso7/gtkrange.h.diff | 29 + .../gtk+/gtk+-2.6.4-1.osso7/gtkrbtree.c.diff | 48 + meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkrc.c.diff | 581 + meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkrc.h.diff | 19 + .../gtk+-2.6.4-1.osso7/gtkscrolledwindow.c.diff | 162 + .../gtk+/gtk+-2.6.4-1.osso7/gtkseparator.c.diff | 21 + .../gtk+-2.6.4-1.osso7/gtkseparatortoolitem.c.diff | 90 + .../gtk+/gtk+-2.6.4-1.osso7/gtksettings.c.diff | 66 + .../gtk+/gtk+-2.6.4-1.osso7/gtkspinbutton.c.diff | 50 + .../gtk+/gtk+-2.6.4-1.osso7/gtkstyle.c.diff | 250 + .../gtk+/gtk+-2.6.4-1.osso7/gtkstyle.h.diff | 13 + .../gtk+/gtk+-2.6.4-1.osso7/gtktable.c.diff | 95 + .../gtk+/gtk+-2.6.4-1.osso7/gtktextbuffer.c.diff | 443 + .../gtk+/gtk+-2.6.4-1.osso7/gtktextbuffer.h.diff | 17 + .../gtktextbufferserialize.c.diff | 1688 + .../gtktextbufferserialize.h.diff | 40 + .../gtk+/gtk+-2.6.4-1.osso7/gtktextview.c.diff | 417 + .../gtk+/gtk+-2.6.4-1.osso7/gtktoolbar.c.diff | 252 + .../gtk+/gtk+-2.6.4-1.osso7/gtktoolbutton.c.diff | 65 + .../gtk+/gtk+-2.6.4-1.osso7/gtktoolbutton.h.diff | 10 + .../gtk+-2.6.4-1.osso7/gtktreemodelfilter.c.diff | 52 + .../gtk+-2.6.4-1.osso7/gtktreemodelsort.c.diff | 21 + .../gtk+/gtk+-2.6.4-1.osso7/gtktreeprivate.h.diff | 58 + .../gtk+-2.6.4-1.osso7/gtktreeselection.c.diff | 91 + .../gtk+/gtk+-2.6.4-1.osso7/gtktreeview.c.diff | 2253 + .../gtk+/gtk+-2.6.4-1.osso7/gtktreeview.h.diff | 18 + .../gtk+-2.6.4-1.osso7/gtktreeviewcolumn.c.diff | 51 + .../gtk+/gtk+-2.6.4-1.osso7/gtktypebuiltins.c.diff | 86 + .../gtk+/gtk+-2.6.4-1.osso7/gtktypebuiltins.h.diff | 24 + .../gtk+/gtk+-2.6.4-1.osso7/gtkvseparator.c.diff | 45 + .../gtk+/gtk+-2.6.4-1.osso7/gtkwidget.c.diff | 1046 + .../gtk+/gtk+-2.6.4-1.osso7/gtkwidget.h.diff | 59 + .../gtk+/gtk+-2.6.4-1.osso7/gtkwindow.c.diff | 78 + .../gtk+/gtk+-2.6.4-1.osso7/gtkwindow.h.diff | 13 + .../gtk+-2.6.4-1.osso7/hardcoded_libtool.patch | 29 + .../gtk+-2.6.4-1.osso7/io-gif-animation.c.diff | 108 + .../packages/gtk+/gtk+-2.6.4-1.osso7/io-gif.c.diff | 37 + .../gtk+/gtk+-2.6.4-1.osso7/menu-deactivate.patch | 50 + .../gtk+/gtk+-2.6.4-1.osso7/no-demos.patch | 10 + meta/packages/gtk+/gtk+-2.6.4-1.osso7/no-xwc.patch | 151 + .../gtk+/gtk+-2.6.4-1.osso7/scroll-timings.patch | 15 + .../gtk+/gtk+-2.6.4-1.osso7/single-click.patch | 54 + .../gtk+/gtk+-2.6.4-1.osso7/small-gtkfilesel.patch | 267 + .../gtk+/gtk+-2.6.4-1.osso7/spinbutton.patch | 128 + .../gtk+/gtk+-2.6.4-1.osso7/xsettings.patch | 16 + .../gtk+/gtk+-2.6.7/automake-lossage.patch | 24 + .../gtk+/gtk+-2.6.7/disable-tooltips.patch | 11 + meta/packages/gtk+/gtk+-2.6.7/gtk+-handhelds.patch | 186 + .../packages/gtk+/gtk+-2.6.7/gtklabel-center.patch | 13 + .../packages/gtk+/gtk+-2.6.7/gtklabel-resize-patch | 10 + .../gtk+/gtk+-2.6.7/hardcoded_libtool.patch | 29 + .../packages/gtk+/gtk+-2.6.7/menu-deactivate.patch | 50 + meta/packages/gtk+/gtk+-2.6.7/no-demos.patch | 10 + meta/packages/gtk+/gtk+-2.6.7/no-xwc.patch | 151 + meta/packages/gtk+/gtk+-2.6.7/scroll-timings.patch | 15 + meta/packages/gtk+/gtk+-2.6.7/single-click.patch | 54 + .../gtk+/gtk+-2.6.7/small-gtkfilesel.patch | 267 + meta/packages/gtk+/gtk+-2.6.7/spinbutton.patch | 128 + .../gtk+/gtk+-2.6.8/automake-lossage.patch | 24 + .../gtk+/gtk+-2.6.8/disable-tooltips.patch | 11 + meta/packages/gtk+/gtk+-2.6.8/gtk+-handhelds.patch | 186 + .../packages/gtk+/gtk+-2.6.8/gtklabel-resize-patch | 10 + .../gtk+/gtk+-2.6.8/hardcoded_libtool.patch | 29 + .../packages/gtk+/gtk+-2.6.8/menu-deactivate.patch | 50 + meta/packages/gtk+/gtk+-2.6.8/no-demos.patch | 10 + meta/packages/gtk+/gtk+-2.6.8/no-deprecation.patch | 334 + meta/packages/gtk+/gtk+-2.6.8/no-xwc.patch | 151 + meta/packages/gtk+/gtk+-2.6.8/scroll-timings.patch | 15 + meta/packages/gtk+/gtk+-2.6.8/spinbutton.patch | 128 + .../gtk+/gtk+-2.8.16/automake-lossage.patch | 24 + .../gtk+/gtk+-2.8.16/disable-tooltips.patch | 11 + .../packages/gtk+/gtk+-2.8.16/gtk+-handhelds.patch | 264 + .../gtk+/gtk+-2.8.16/gtklabel-resize-patch | 10 + .../gtk+/gtk+-2.8.16/gtktreeview-316689.patch | 25 + .../gtk+/gtk+-2.8.16/hardcoded_libtool.patch | 29 + .../gtk+/gtk+-2.8.16/menu-deactivate.patch | 50 + meta/packages/gtk+/gtk+-2.8.16/no-demos.patch | 10 + meta/packages/gtk+/gtk+-2.8.16/no-xwc.patch | 179 + .../packages/gtk+/gtk+-2.8.16/scroll-timings.patch | 15 + meta/packages/gtk+/gtk+-2.8.16/single-click.patch | 36 + .../gtk+/gtk+-2.8.16/small-gtkfilesel.patch | 267 + meta/packages/gtk+/gtk+-2.8.16/spinbutton.patch | 128 + meta/packages/gtk+/gtk+-2.8.16/xsettings.patch | 16 + meta/packages/gtk+/gtk+_2.10.0.bb | 97 + meta/packages/gtk+/gtk+_2.6.4-1.osso7.bb | 167 + meta/packages/gtk+/gtk+_2.6.7.bb | 83 + meta/packages/gtk+/gtk+_2.6.8.bb | 80 + meta/packages/gtk+/gtk+_2.8.16.bb | 86 + meta/packages/gtk-doc/gtk-doc-native.bb | 3 + meta/packages/gtk-doc/gtk-doc.bb | 8 + meta/packages/gtk-doc/gtk-doc.m4 | 53 + .../gtk-engines/gtk-clearlooks-engine_0.6.2.bb | 23 + meta/packages/gtk-engines/gtk-engines_2.7.1.bb | 32 + meta/packages/gtkhtml2/gtkhtml2_cvs.bb | 29 + meta/packages/hal/hal_0.5.4.bb | 33 + meta/packages/hdparm/hdparm-6.3/bswap.patch | 36 + meta/packages/hdparm/hdparm-6.3/uclibc.patch | 32 + meta/packages/hdparm/hdparm_6.3.bb | 14 + meta/packages/hostap/files/hostap-fw-load.patch | 20 + meta/packages/hostap/files/hostap_cs.conf | 185 + meta/packages/hostap/files/hostap_cs.conf-upstream | 191 + meta/packages/hostap/hostap-conf_1.0.bb | 16 + meta/packages/hostap/hostap-modules.inc | 39 + meta/packages/hostap/hostap-modules/Makefile.patch | 11 + .../packages/hostap/hostap-modules/add_event.patch | 28 + .../hostap/hostap-modules/hostap-utsname.patch | 77 + .../hostap/hostap-modules/hostap_cardid.patch | 70 + .../hostap/hostap-modules/ipaq_compat.patch | 11 + .../hostap/hostap-modules/kernel_updates.patch | 192 + .../packages/hostap/hostap-modules/mtx_compat.diff | 20 + .../hostap-modules/mtx_hostap_deferred_irq.diff | 81 + meta/packages/hostap/hostap-modules_0.3.9.bb | 7 + meta/packages/hostap/hostap-utils.inc | 24 + meta/packages/hostap/hostap-utils_0.3.7.bb | 3 + meta/packages/hostap/hostap-utils_0.4.0.bb | 3 + .../initscripts/initscripts-1.0/akita/devices | 68 + .../initscripts/initscripts-1.0/arm/alignment.sh | 6 + meta/packages/initscripts/initscripts-1.0/banner | 15 + .../initscripts/initscripts-1.0/bootmisc.sh | 71 + .../initscripts/initscripts-1.0/c7x0/devices | 68 + .../initscripts/initscripts-1.0/checkfs.sh | 46 + .../initscripts/initscripts-1.0/checkroot.sh | 165 + .../initscripts/initscripts-1.0/collie/devices | 67 + .../initscripts/initscripts-1.0/device_table.txt | 179 + meta/packages/initscripts/initscripts-1.0/devices | 66 + meta/packages/initscripts/initscripts-1.0/devpts | 5 + .../packages/initscripts/initscripts-1.0/devpts.sh | 28 + meta/packages/initscripts/initscripts-1.0/finish | 6 + .../initscripts/initscripts-1.0/h3600/devices | 37 + .../initscripts/initscripts-1.0/h3900/devices | 37 + meta/packages/initscripts/initscripts-1.0/halt | 31 + .../initscripts/initscripts-1.0/hostname.sh | 11 + .../initscripts/initscripts-1.0/jornada56x/devices | 37 + .../initscripts/initscripts-1.0/jornada6xx/devices | 70 + .../initscripts/initscripts-1.0/jornada7xx/devices | 37 + .../initscripts/initscripts-1.0/mountall.sh | 45 + .../initscripts/initscripts-1.0/mountnfs.sh | 87 + .../initscripts/initscripts-1.0/openmn/extractfs | 7 + .../initscripts/initscripts-1.0/openmn/packages | 63 + .../initscripts/initscripts-1.0/openmn/umountfs | 17 + .../initscripts-1.0/openzaurus/checkversion | 31 + .../initscripts/initscripts-1.0/poodle/devices | 67 + .../initscripts-1.0/populate-volatile.sh | 138 + meta/packages/initscripts/initscripts-1.0/ramdisk | 46 + meta/packages/initscripts/initscripts-1.0/reboot | 17 + .../packages/initscripts/initscripts-1.0/rmnologin | 14 + meta/packages/initscripts/initscripts-1.0/sendsigs | 17 + .../initscripts/initscripts-1.0/simpad/devices | 37 + meta/packages/initscripts/initscripts-1.0/single | 21 + .../initscripts/initscripts-1.0/spitz/devices | 68 + meta/packages/initscripts/initscripts-1.0/sysfs.sh | 11 + .../initscripts/initscripts-1.0/tosa/devices | 72 + .../initscripts/initscripts-1.0/uml/devices | 61 + meta/packages/initscripts/initscripts-1.0/umountfs | 18 + .../initscripts/initscripts-1.0/umountnfs.sh | 28 + meta/packages/initscripts/initscripts-1.0/urandom | 41 + .../packages/initscripts/initscripts-1.0/volatiles | 39 + meta/packages/initscripts/initscripts_1.0.bb | 141 + meta/packages/intltool/intltool-native_0.31.bb | 4 + meta/packages/intltool/intltool_0.31.bb | 13 + .../ipkg-utils/ipkg-link/link-vfat-libs.patch | 34 + .../ipkg-utils/ipkg-link_1.6+cvs20050404.bb | 20 + .../ipkg-utils-native/ipkg-utils-fix.patch | 17 + .../ipkg-utils-native_1.6+cvs20050404.bb | 16 + .../ipkg-utils/ipkg-utils_1.6+cvs20050404.bb | 33 + meta/packages/ipkg/files/terse.patch | 18 + meta/packages/ipkg/files/uclibc.patch | 13 + meta/packages/ipkg/files/uninclude-replace.patch | 10 + meta/packages/ipkg/ipkg-collateral.bb | 23 + meta/packages/ipkg/ipkg-collateral/akita/dest | 4 + meta/packages/ipkg/ipkg-collateral/akita/lists | 4 + meta/packages/ipkg/ipkg-collateral/collie/dest | 4 + meta/packages/ipkg/ipkg-collateral/dest | 1 + .../ipkg/ipkg-collateral/ipkg.conf.comments | 23 + meta/packages/ipkg/ipkg-collateral/jornada56x/dest | 4 + meta/packages/ipkg/ipkg-collateral/lists | 2 + meta/packages/ipkg/ipkg-collateral/openmn/src | 1 + meta/packages/ipkg/ipkg-collateral/poodle/dest | 4 + meta/packages/ipkg/ipkg-collateral/simpad/dest | 3 + meta/packages/ipkg/ipkg-collateral/src | 0 meta/packages/ipkg/ipkg-collateral/tosa/dest | 4 + meta/packages/ipkg/ipkg-native.inc | 12 + meta/packages/ipkg/ipkg-native_0.99.154.bb | 2 + meta/packages/ipkg/ipkg.inc | 56 + meta/packages/ipkg/ipkg_0.99.154.bb | 2 + meta/packages/irda-utils/files/init | 72 + .../packages/irda-utils/irda-utils/configure.patch | 25 + meta/packages/irda-utils/irda-utils/m4.patch | 204 + meta/packages/irda-utils/irda-utils_0.9.16.bb | 32 + meta/packages/jpeg/jpeg-6b/debian.patch | 10014 +++++ meta/packages/jpeg/jpeg-6b/ldflags.patch | 16 + meta/packages/jpeg/jpeg-6b/paths.patch | 77 + meta/packages/jpeg/jpeg-native_6b.bb | 14 + meta/packages/jpeg/jpeg_6b.bb | 36 + meta/packages/js/files/host-cc.patch | 16 + meta/packages/js/files/jsautocfg.h | 52 + meta/packages/js/js_1.5.bb | 36 + meta/packages/keymaps/files/akita/keymap-2.4.map | 128 + meta/packages/keymaps/files/akita/keymap-2.6.map | 228 + meta/packages/keymaps/files/c7x0/keymap-2.6.map | 213 + meta/packages/keymaps/files/collie/keymap-2.4.map | 114 + meta/packages/keymaps/files/collie/keymap-2.6.map | 262 + meta/packages/keymaps/files/keymap | 16 + meta/packages/keymaps/files/poodle/keymap-2.6.map | 151 + meta/packages/keymaps/files/spitz/keymap-2.4.map | 128 + meta/packages/keymaps/files/spitz/keymap-2.6.map | 228 + meta/packages/keymaps/files/tosa/keymap-2.4.map | 133 + meta/packages/keymaps/files/tosa/keymap-2.6.map | 210 + meta/packages/keymaps/keymaps_1.0.bb | 34 + meta/packages/kf/files/fix-configure.patch | 25 + meta/packages/kf/files/fix-desktop-file.patch | 22 + meta/packages/kf/kf_0.5.4.1.bb | 16 + meta/packages/leafpad/files/leafpad.desktop | 11 + meta/packages/leafpad/files/leafpad.png | Bin 0 -> 1950 bytes meta/packages/leafpad/leafpad_0.8.4.bb | 21 + meta/packages/leafpad/leafpad_0.8.9.bb | 21 + meta/packages/less/less-382/configure.patch | 243 + meta/packages/less/less_382.bb | 16 + meta/packages/libdaemon/libdaemon_0.10.bb | 20 + meta/packages/libfakekey/libfakekey_svn.bb | 23 + meta/packages/libgcrypt/libgcrypt_1.2.1.bb | 28 + .../libglade/libglade-2.5.1/glade-cruft.patch | 100 + .../libglade/libglade-2.5.1/no-deprecation.patch | 10 + .../packages/libglade/libglade-2.5.1/no-xml2.patch | 499 + meta/packages/libglade/libglade_2.5.1.bb | 34 + .../libgpg-error/libgpg-error-1.0/pkgconfig.patch | 56 + meta/packages/libgpg-error/libgpg-error_1.0.bb | 28 + meta/packages/libgtkstylus/files/gtkstylus.sh | 5 + meta/packages/libgtkstylus/libgtkstylus_0.5.bb | 17 + meta/packages/libiconv/libiconv_1.9.2.bb | 29 + meta/packages/libidl/libidl-native_0.8.3.bb | 5 + meta/packages/libidl/libidl_0.8.3.bb | 23 + meta/packages/libmatchbox/files/16bppfixes.patch | 36 + meta/packages/libmatchbox/files/autofoo.patch | 19 + meta/packages/libmatchbox/files/check.m4 | 133 + .../libmatchbox/files/fix-configure-for-1.9.patch | 14 + meta/packages/libmatchbox/libmatchbox.inc | 23 + meta/packages/libmatchbox/libmatchbox_1.7.bb | 8 + meta/packages/libmatchbox/libmatchbox_svn.bb | 13 + .../packages/libnss-mdns/files/alignment-fix.patch | 11 + meta/packages/libnss-mdns/libnss-mdns_0.7.bb | 29 + meta/packages/libpcap/libpcap-0.9.3/shared.patch | 119 + meta/packages/libpcap/libpcap_0.9.3.bb | 32 + meta/packages/libpng/libpng-native_1.2.8.bb | 14 + meta/packages/libpng/libpng_1.2.8.bb | 57 + .../packages/libtool/libtool-1.5.10/3figures.patch | 29 + .../libtool/libtool-1.5.10/autotools.patch | 127 + .../libtool-1.5.10/install-path-check.patch | 25 + .../libtool/libtool-1.5.10/libdir-la.patch | 52 + meta/packages/libtool/libtool-1.5.10/prefix.patch | 40 + meta/packages/libtool/libtool-1.5.10/sedvar.patch | 16 + meta/packages/libtool/libtool-1.5.10/tag.patch | 19 + meta/packages/libtool/libtool-1.5.10/tag1.patch | 13 + meta/packages/libtool/libtool-1.5.10/uclibc.patch | 19 + meta/packages/libtool/libtool-cross_1.5.10.bb | 27 + meta/packages/libtool/libtool-native_1.5.10.bb | 35 + meta/packages/libtool/libtool_1.5.10.bb | 35 + meta/packages/libusb/libusb-0.1.10a/ARMfix.patch | 20 + .../libusb/libusb-0.1.10a/debian-changes.patch | 407 + meta/packages/libusb/libusb_0.1.10a.bb | 28 + meta/packages/libxml/files/no-testapi.patch | 51 + meta/packages/libxml/libxml2_2.6.10.bb | 40 + meta/packages/libxml/libxml2_2.6.22.bb | 39 + meta/packages/libxml/libxml2_cvs.bb | 43 + .../libxsettings-client_0.14.bb | 21 + .../libxsettings-client/make_pkgconfig_x11.patch | 21 + meta/packages/libxsettings/libxsettings_0.11.bb | 24 + meta/packages/linux-hotplug/files/collie/usbd | 1 + meta/packages/linux-hotplug/files/mmc.agent | 52 + meta/packages/linux-hotplug/files/sleeve.agent | 120 + meta/packages/linux-hotplug/files/sleeve.rc | 60 + meta/packages/linux-hotplug/files/soc.agent | 62 + .../packages/linux-hotplug/files/sysconfig-hotplug | 12 + meta/packages/linux-hotplug/files/sysconfig-usb | 0 .../linux-hotplug/files/tosa/sysconfig-usb | 2 + meta/packages/linux-hotplug/files/usbd | 2 + meta/packages/linux-hotplug/files/usbd.agent | 63 + .../linux-hotplug-20040920/fix-net.agent | 29 + .../hotplug-net-agent-usb.patch | 43 + .../linux-hotplug-20040920/isapnp-exit.diff | 11 + .../linux-hotplug-20040920/logcheck-ignore | 1 + .../linux-hotplug-20040920/update-usb.usermap | 37 + .../linux-hotplug-20040920/usb-storage | 2 + .../linux-hotplug-20040920/usbrc-busybox.patch | 13 + .../linux-hotplug-20040920/userspecified_hcd.patch | 55 + .../linux-hotplug/linux-hotplug_20040920.bb | 73 + .../linux-libc-headers/files/keyboard.patch | 78 + .../linux-libc-headers-2.6.15.99/3477-1.patch | 43 + .../asm-arch-irqs.patch | 19 + .../linux-netdevice.patch | 11 + .../linux-netfilter_ipv4.patch | 31 + .../linux-libc-headers-2.6.15.99/linux-rtc.patch | 11 + .../linux-videodev2.patch | 45 + .../linux-libc-headers_2.6.11.1.bb | 65 + .../linux-libc-headers_2.6.15.99.bb | 80 + .../linux-cmx270-2.6.17/add_2700g_plat-r0.patch | 126 + .../linux/linux-cmx270-2.6.17/cm_x2xx_mbx.patch | 1566 + meta/packages/linux/linux-cmx270-2.6.17/defconfig | 1169 + meta/packages/linux/linux-cmx270-2.6.17/mach-types | 1112 + .../linux/linux-cmx270-2.6.17/mtd_fixes-r0.patch | 599 + .../linux/linux-cmx270-2.6.17/mtd_fixes1-r0.patch | 15 + .../linux/linux-cmx270-rp-2.6.17/defconfig | 1485 + .../linux/linux-cmx270-rp-2.6.17/mach-types | 1095 + meta/packages/linux/linux-cmx270-rp_2.6.17.bb | 42 + meta/packages/linux/linux-cmx270_2.6.17.bb | 40 + .../nokia770/defconfig | 1297 + .../linux/linux-nokia770_2.6.12.3-osso14.bb | 31 + .../linux/linux-openzaurus-2.6.16/00-hostap.patch | 45 + .../linux/linux-openzaurus-2.6.16/10-pcnet.patch | 27 + .../add-oz-release-string.patch | 24 + .../connectplus-remove-ide-HACK.patch | 12 + .../linux/linux-openzaurus-2.6.16/defconfig-akita | 1565 + .../linux/linux-openzaurus-2.6.16/defconfig-c7x0 | 1601 + .../linux/linux-openzaurus-2.6.16/defconfig-collie | 1147 + .../linux-openzaurus-2.6.16/defconfig-ipaq-pxa270 | 1021 + .../linux/linux-openzaurus-2.6.16/defconfig-poodle | 1549 + .../linux-openzaurus-2.6.16/defconfig-qemuarm | 961 + .../linux/linux-openzaurus-2.6.16/defconfig-spitz | 1565 + .../linux/linux-openzaurus-2.6.16/defconfig-tosa | 1601 + .../hrw-pcmcia-ids-r2.patch | 42 + .../locomo-kbd-hotkeys.patch | 48 + .../locomo-lcd-def-bightness.patch | 11 + .../locomo-sysrq+keyrepeat.patch | 49 + .../linux-openzaurus-2.6.16/pxa-serial-hack.patch | 73 + .../linux/linux-openzaurus-2.6.16/rmk-mmc1.patch | 61 + .../linux/linux-openzaurus-2.6.16/rmk-mmc2.patch | 26 + ...t-for-non-standard-xtals-to-16c950-driver.patch | 155 + .../squashfs3.0-2.6.15.patch | 4173 ++ .../linux/linux-openzaurus-2.6.17/00-hostap.patch | 45 + .../linux/linux-openzaurus-2.6.17/10-pcnet.patch | 27 + .../add-oz-release-string.patch | 24 + .../connectplus-remove-ide-HACK.patch | 12 + .../linux/linux-openzaurus-2.6.17/defconfig-akita | 1565 + .../linux/linux-openzaurus-2.6.17/defconfig-c7x0 | 1601 + .../linux/linux-openzaurus-2.6.17/defconfig-collie | 1147 + .../linux-openzaurus-2.6.17/defconfig-ipaq-pxa270 | 1021 + .../linux/linux-openzaurus-2.6.17/defconfig-poodle | 1549 + .../linux-openzaurus-2.6.17/defconfig-qemuarm | 934 + .../linux/linux-openzaurus-2.6.17/defconfig-spitz | 1565 + .../linux/linux-openzaurus-2.6.17/defconfig-tosa | 1601 + .../hrw-pcmcia-ids-r2.patch | 42 + .../linux-openzaurus-2.6.17/pxa-serial-hack.patch | 73 + ...t-for-non-standard-xtals-to-16c950-driver.patch | 155 + .../squashfs3.0-2.6.15.patch | 4173 ++ meta/packages/linux/linux-openzaurus.inc | 199 + meta/packages/linux/linux-openzaurus_2.6.16.bb | 158 + meta/packages/linux/linux-openzaurus_2.6.17.bb | 120 + meta/packages/lirc/files/lirc_sir-sa1100.patch | 10 + meta/packages/lirc/files/lircd.conf_nslu2 | 1886 + meta/packages/lirc/files/lircd.init | 39 + meta/packages/lirc/files/lircexec.init | 37 + meta/packages/lirc/files/lircmd.init | 38 + meta/packages/lirc/files/lircrc_nslu2 | 113 + meta/packages/lirc/files/split-hauppauge.patch | 141 + meta/packages/lirc/lirc-config.inc | 12 + meta/packages/lirc/lirc-modules_0.7.1.bb | 34 + meta/packages/lirc/lirc_0.7.1.bb | 38 + meta/packages/loudmouth/loudmouth_1.0.1.bb | 13 + meta/packages/lrzsz/lrzsz-0.12.20/autotools.patch | 37 + meta/packages/lrzsz/lrzsz-0.12.20/gettext.patch | 21882 ++++++++++ meta/packages/lrzsz/lrzsz-0.12.20/makefile.patch | 20 + meta/packages/lrzsz/lrzsz_0.12.20.bb | 24 + meta/packages/lsof/lsof_4.75.bb | 38 + .../lttng/lttng-control-0.10/lttctl_sti-r0.patch | 147 + .../lttng/lttng-control-0.6/lttctl_sti-r0.patch | 134 + meta/packages/lttng/lttng-control_0.10.bb | 17 + meta/packages/lttng/lttng-control_0.6.bb | 16 + .../packages/lttng/lttng-viewer_0.8.41-20060512.bb | 20 + meta/packages/m4/m4-native_1.4.2.bb | 19 + meta/packages/m4/m4/make.patch | 41 + meta/packages/m4/m4_1.4.2.bb | 12 + meta/packages/maemo/nokia770-init/fixup-770.sh | 25 + meta/packages/maemo/nokia770-init_1.0.bb | 42 + meta/packages/maemo/xpext/auxdir.patch | 13 + meta/packages/maemo/xpext_1.0-5.bb | 27 + meta/packages/maemo/xsp_1.0.0-8.bb | 20 + meta/packages/make/make-3.80/SCCS.patch | 16 + meta/packages/make/make_3.80.bb | 9 + meta/packages/makedevs/makedevs-1.0.0/makedevs.c | 338 + meta/packages/makedevs/makedevs-native_1.0.0.bb | 10 + meta/packages/makedevs/makedevs_1.0.0.bb | 20 + .../matchbox-applet-inputmanager_0.6.bb | 12 + .../matchbox-applet-startup-monitor_0.1.bb | 12 + .../matchbox-applet-volume_0.1.bb | 12 + .../matchbox-common/matchbox-common_0.9.1.bb | 14 + .../matchbox-common/matchbox-common_svn.bb | 17 + meta/packages/matchbox-common/matchbox_0.9.1.bb | 7 + .../matchbox-config-gtk/matchbox-config-gtk_svn.bb | 11 + .../matchbox-desktop/matchbox-desktop_0.9.1.bb | 27 + .../matchbox-desktop/matchbox-desktop_svn.bb | 31 + .../matchbox-keyboard/matchbox-keyboard_svn.bb | 22 + .../home-panelapp.desktop | 7 + .../matchbox-panel-hacks-0.3-1/mb-applet-home | 2 + .../xrandr-panelapp.desktop | 7 + .../matchbox-panel-hacks-0.3-1/xrandr-panelapp.sh | 9 + .../matchbox-panel-hacks-0.3-1/xrandr.png | Bin 0 -> 1651 bytes .../matchbox-panel-hacks_0.3-1.bb | 23 + .../matchbox-panel-manager_0.1.bb | 12 + meta/packages/matchbox-panel/matchbox-panel.inc | 22 + .../matchbox-panel/matchbox-panel_0.9.2.bb | 6 + meta/packages/matchbox-panel/matchbox-panel_svn.bb | 11 + .../matchbox-poky/etc/matchbox/session | 43 + meta/packages/matchbox-poky/matchbox-poky_0.1.bb | 20 + .../matchbox-stroke/matchbox-stroke_svn.bb | 19 + .../matchbox-themes-extra_0.3.bb | 25 + .../matchbox-themes-extra_svn.bb | 30 + meta/packages/matchbox-themes-gtk/files/gtkrc | 1 + .../matchbox-themes-gtk/matchbox-themes-gtk.bb | 17 + .../matchbox-wm/matchbox-wm/collie/kbdconfig | 54 + meta/packages/matchbox-wm/matchbox-wm/kbdconfig | 47 + .../matchbox-wm/kbdconfig_keylaunch_simpad.patch | 12 + .../matchbox-wm/matchbox-wm/simpad/kbdconfig | 48 + meta/packages/matchbox-wm/matchbox-wm_0.9.5.bb | 33 + meta/packages/matchbox-wm/matchbox-wm_svn.bb | 34 + meta/packages/meta/bootstrap-image.bb | 17 + meta/packages/meta/oh-image-devel.bb | 24 + meta/packages/meta/oh-image-minimal.bb | 21 + meta/packages/meta/oh-image-sdk.bb | 27 + meta/packages/meta/oh-image.bb | 22 + meta/packages/meta/package-index.bb | 34 + meta/packages/meta/task-oh-sdk.bb | 188 + meta/packages/meta/task-oh.bb | 124 + .../misc-binary-only/prism3-firmware_1.8.4.bb | 27 + .../module-init-tools/files/ignore_arch_directory | 24 + meta/packages/module-init-tools/files/manpagesopt | 41 + .../module-init-tools/files/modutils_extension | 55 + .../module-init-tools/files/no_man_rebuild | 12 + .../module-init-tools-cross_3.2.2.bb | 16 + .../module-init-tools/module-init-tools_3.2.2.bb | 63 + meta/packages/modutils/files/armeb.patch | 14 + meta/packages/modutils/files/configure.patch | 33 + meta/packages/modutils/files/gcc4.patch | 66 + meta/packages/modutils/files/ipaq-pxa-2.6/modules | 18 + .../modutils/files/ipaq-pxa-2.6/modules.conf | 1 + meta/packages/modutils/files/lex.l.diff | 33 + meta/packages/modutils/files/mnci/modules | 1 + meta/packages/modutils/files/mnci/modules-ramses | 1 + meta/packages/modutils/files/mnci/modules.conf | 20 + meta/packages/modutils/files/mnci/modutils.sh | 10 + meta/packages/modutils/files/modules | 0 meta/packages/modutils/files/modules.conf | 0 meta/packages/modutils/files/modutils-notest.patch | 14 + meta/packages/modutils/files/modutils.sh | 27 + meta/packages/modutils/files/mtx-1/modules | 3 + meta/packages/modutils/files/omap1610h2/modules | 0 .../modutils/files/omap1610h2/modules.conf | 0 meta/packages/modutils/files/poodle/modules | 3 + meta/packages/modutils/files/poodle/modules.conf | 4 + meta/packages/modutils/files/program_prefix.patch | 69 + meta/packages/modutils/files/tosa/modules | 4 + meta/packages/modutils/files/tosa/modules.conf | 4 + meta/packages/modutils/files/wrt54/modules | 4 + meta/packages/modutils/modutils-collateral.bb | 16 + .../packages/modutils/modutils-cross/module.h.diff | 33 + meta/packages/modutils/modutils-cross_2.4.27.bb | 27 + meta/packages/modutils/modutils-initscripts.bb | 18 + meta/packages/modutils/modutils_2.4.27.bb | 88 + meta/packages/mozilla/files/minimo.desktop | 9 + meta/packages/mozilla/files/minimo.png | Bin 0 -> 4323 bytes .../packages/mozilla/files/mozilla-firefox.desktop | 11 + meta/packages/mozilla/files/mozilla-firefox.png | Bin 0 -> 4323 bytes .../mozilla/files/mozilla-thunderbird.desktop | 11 + .../packages/mozilla/files/mozilla-thunderbird.png | Bin 0 -> 6499 bytes meta/packages/mozilla/files/no-xmb.patch | 18 + meta/packages/mozilla/files/xptcstubs.patch | 19 + .../packages/mozilla/minimo/host_ldflags_fix.patch | 62 + meta/packages/mozilla/minimo/mozconfig | 76 + meta/packages/mozilla/minimo_cvs.bb | 54 + meta/packages/mozilla/mozilla-cvs.inc | 12 + meta/packages/mpfr/mpfr-native_2.1.1.bb | 4 + meta/packages/mpfr/mpfr_2.1.1.bb | 20 + meta/packages/mtd/mtd-utils-native_20060223.bb | 12 + .../add-exclusion-to-mkfs-jffs2-20060131.patch | 100 + .../mtd-utils/add-exclusion-to-mkfs-jffs2.patch | 103 + .../mtd/mtd-utils/fix-ignoreerrors-20060131.patch | 20 + meta/packages/mtd/mtd-utils/fix-ignoreerrors.patch | 20 + meta/packages/mtd/mtd-utils/more-verbosity.patch | 17 + meta/packages/mtd/mtd-utils_20060223.bb | 36 + meta/packages/ncurses/ncurses-native_5.4.bb | 6 + meta/packages/ncurses/ncurses.inc | 86 + meta/packages/ncurses/ncurses/20030906.patch | 43248 +++++++++++++++++++ meta/packages/ncurses/ncurses/configure.patch | 193 + meta/packages/ncurses/ncurses/mk_shared_lib.patch | 27 + meta/packages/ncurses/ncurses/run_tic.patch | 23 + meta/packages/ncurses/ncurses/tic.patch | 19 + meta/packages/ncurses/ncurses/visibility.patch | 4904 +++ meta/packages/ncurses/ncurses_5.4.bb | 7 + meta/packages/netbase/netbase/busybox.patch | 13 + meta/packages/netbase/netbase/colinux/interfaces | 8 + meta/packages/netbase/netbase/epia/interfaces | 10 + meta/packages/netbase/netbase/hosts | 2 + meta/packages/netbase/netbase/init | 102 + meta/packages/netbase/netbase/interfaces | 43 + meta/packages/netbase/netbase/mtx-1/interfaces | 29 + meta/packages/netbase/netbase/openmn/hosts | 2 + meta/packages/netbase/netbase/openmn/interfaces | 10 + meta/packages/netbase/netbase/options | 3 + meta/packages/netbase/netbase/tosa/interfaces | 24 + meta/packages/netbase/netbase/wrt54/interfaces | 23 + meta/packages/netbase/netbase/xxs1500/interfaces | 15 + meta/packages/netbase/netbase_4.21.bb | 42 + .../network-suspend-scripts/files/ifupdown | 26 + meta/packages/network-suspend-scripts/files/usbnet | 16 + .../network-suspend-scripts.bb | 22 + meta/packages/oh/usbinit.bb | 19 + meta/packages/oh/usbinit/usb-gether | 19 + .../openswan/openswan-2.2.0/gcc4-fixes.patch | 329 + .../openswan-2.2.0/ld-library-path-breakage.patch | 26 + .../openswan-2.2.0/makefile-whitespace-fix.patch | 11 + .../openswan-2.2.0/openswan-2.2.0-gentoo.patch | 382 + meta/packages/openswan/openswan_2.2.0.bb | 37 + .../fix-warnings.patch | 11 + .../opensync/libopensync-plugin-evolution2_0.17.bb | 17 + .../opensync/libopensync-plugin-file_0.17.bb | 16 + meta/packages/opensync/libopensync_0.17.bb | 24 + meta/packages/opensync/multisync_0.90.17.bb | 6 + meta/packages/oprofile/oprofile-0.9.1/acinclude.m4 | 600 + .../oprofile-0.9.1/no_arm_mapping_syms.patch | 21 + meta/packages/oprofile/oprofile/acinclude.m4 | 600 + .../oprofile/oprofile/no_arm_mapping_syms.patch | 21 + meta/packages/oprofile/oprofile_0.9.1.bb | 39 + meta/packages/oprofile/oprofile_cvs.bb | 41 + meta/packages/orinoco/files/hermes.conf | 85 + meta/packages/orinoco/files/orinoco_cs.conf | 2 + meta/packages/orinoco/files/spectrum.conf | 18 + meta/packages/orinoco/files/spectrum_fw.h | 4569 ++ meta/packages/orinoco/orinoco-conf_1.0.bb | 19 + .../orinoco-modules-0.15rc2/add_event.patch | 56 + .../orinoco-modules-0.15rc2/add_utsname.patch | 21 + .../catch-up-with-kernel-changes.patch | 48 + .../orinoco-modules-0.15rc2/list-move.patch | 22 + .../orinoco-modules-0.15rc2/makefile_fix.patch | 13 + .../orinoco-modules-0.15rc2/spectrum_cs_ids.patch | 101 + meta/packages/orinoco/orinoco-modules_0.15rc2.bb | 38 + meta/packages/orinoco/spectrum-fw.bb | 21 + meta/packages/orinoco/spectrum-fw/get_symbol_fw | 43 + meta/packages/orinoco/spectrum-fw/parse_symbol_fw | 129 + meta/packages/pango/files/gtk-doc.patch | 59 + meta/packages/pango/files/no-tests.patch | 15 + meta/packages/pango/pango_1.10.0.bb | 49 + meta/packages/pango/pango_1.12.0.bb | 49 + meta/packages/pango/pango_1.13.3.bb | 49 + meta/packages/pango/pango_1.9.1.bb | 49 + .../pcmanfm/files/emblem-symbolic-link.png | Bin 0 -> 999 bytes meta/packages/pcmanfm/files/gnome-fs-directory.png | Bin 0 -> 2044 bytes meta/packages/pcmanfm/files/gnome-fs-regular.png | Bin 0 -> 3220 bytes .../pcmanfm/files/gnome-mime-text-plain.png | Bin 0 -> 2855 bytes meta/packages/pcmanfm/files/no-fam-gtk2.6.patch | 374 + meta/packages/pcmanfm/files/pcmanfm.desktop | 11 + meta/packages/pcmanfm/files/pcmanfm.png | Bin 0 -> 2281 bytes meta/packages/pcmanfm/pcmanfm_0.1.9.8.bb | 29 + meta/packages/pcmcia-cs/files/arm/pcmcia | 40 + meta/packages/pcmcia-cs/files/gcc4_fixes.patch | 26 + meta/packages/pcmcia-cs/files/network.conf | 13 + meta/packages/pcmcia-cs/files/pcmcia | 1 + meta/packages/pcmcia-cs/files/wnv.conf | 14 + .../pcmcia-cs/pcmcia-cs-3.2.8/automount.patch | 19 + .../pcmcia-cs/pcmcia-cs-3.2.8/busybox.patch | 20 + meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/ide.opts | 25 + .../pcmcia-cs/pcmcia-cs-3.2.8/network.patch | 92 + .../pcmcia-cs-3.2.8/no-hostap-cards.patch | 124 + .../pcmcia-cs/pcmcia-cs-3.2.8/nocleanup.patch | 11 + .../pcmcia-cs/pcmcia-cs-3.2.8/pcic-extra.patch | 30 + .../pcmcia-cs/pcmcia-cs-3.2.8/ratoc-cfu1u.patch | 23 + .../pcmcia-cs/pcmcia-cs-3.2.8/spitz/ide.opts | 28 + .../pcmcia-cs/pcmcia-cs-3.2.8/wireless.opts | 47 + meta/packages/pcmcia-cs/pcmcia-cs_3.2.8.bb | 102 + .../pcmciautils/pcmciautils-013/makefile_fix.patch | 20 + .../pcmciautils-013/version_workaround.patch | 16 + meta/packages/pcmciautils/pcmciautils_010.bb | 31 + meta/packages/pcmciautils/pcmciautils_013.bb | 33 + meta/packages/perl/files/Configure-multilib.patch | 11 + meta/packages/perl/files/Makefile.SH.patch | 298 + meta/packages/perl/files/Makefile.patch | 23 + meta/packages/perl/files/config.sh-arm-linux.patch | 46 + meta/packages/perl/files/config.sh-i686-linux | 1024 + meta/packages/perl/files/config.sh-mipsel-linux | 1026 + .../libperl-5.8.3-create-libperl-soname.patch | 11 + meta/packages/perl/files/uclibc.patch | 26 + .../perl/libxml-parser-perl-native_2.34.bb | 4 + meta/packages/perl/libxml-parser-perl_2.34.bb | 6 + meta/packages/perl/perl-5.8.7/Makefile.SH.patch | 206 + meta/packages/perl/perl-5.8.7/Makefile.patch | 18 + meta/packages/perl/perl-5.8.7/config.sh-arm-linux | 1029 + .../perl/perl-5.8.7/config.sh-arm-linux.patch | 34 + .../packages/perl/perl-5.8.7/config.sh-armeb-linux | 1028 + meta/packages/perl/perl-5.8.7/config.sh-i386-linux | 1028 + meta/packages/perl/perl-5.8.7/config.sh-i686-linux | 1028 + .../perl/perl-5.8.7/config.sh-mipsel-linux | 1031 + .../libperl-5.8.3-create-libperl-soname.patch | 11 + meta/packages/perl/perl-5.8.7/uclibc.patch | 0 meta/packages/perl/perl-native_5.8.7.bb | 38 + meta/packages/perl/perl-rdepends_5.8.7.inc | 1137 + meta/packages/perl/perl.inc | 73 + meta/packages/perl/perl_5.8.7.bb | 101 + .../pkgconfig/pkgconfig-0.15.0/configure.patch | 495 + .../pkgconfig-0.15.0/glibconfig-sysdefs.h | 6 + meta/packages/pkgconfig/pkgconfig-0.15.0/pkg.m4 | 156 + meta/packages/pkgconfig/pkgconfig-native_0.15.0.bb | 7 + meta/packages/pkgconfig/pkgconfig_0.15.0.bb | 26 + meta/packages/popt/popt-1.7/intl.patch | 15 + meta/packages/popt/popt-1.7/m4.patch | 2155 + meta/packages/popt/popt-native_1.7.bb | 6 + meta/packages/popt/popt_1.7.bb | 16 + meta/packages/portmap/files/make.patch | 83 + meta/packages/portmap/files/no-libwrap.patch | 26 + meta/packages/portmap/files/portmap.init | 50 + meta/packages/portmap/portmap_5-9.bb | 33 + meta/packages/ppp-dialin/files/host-peer | 11 + meta/packages/ppp-dialin/files/ppp-dialin | 3 + meta/packages/ppp-dialin/ppp-dialin_0.1.bb | 35 + meta/packages/ppp/files/08setupdns | 12 + meta/packages/ppp/files/92removedns | 5 + meta/packages/ppp/files/init | 50 + meta/packages/ppp/files/ip-down | 43 + meta/packages/ppp/files/ip-up | 44 + meta/packages/ppp/files/poff | 26 + meta/packages/ppp/files/pon | 9 + meta/packages/ppp/ppp-2.4.3/cifdefroute.patch | 286 + meta/packages/ppp/ppp-2.4.3/enable-ipv6.patch | 11 + .../makefile-remove-hard-usr-reference.patch | 19 + meta/packages/ppp/ppp-2.4.3/makefile.patch | 89 + meta/packages/ppp/ppp-2.4.3/plugins-fix-CC.patch | 7 + .../ppp/ppp-2.4.3/pppd-resolv-varrun.patch | 43 + meta/packages/ppp/ppp-2.4.3/pppoatm-makefile.patch | 7 + meta/packages/ppp/ppp_2.4.3.bb | 70 + meta/packages/prism3-support/files/hostap-fw-load | 20 + .../prism3-support/prism3-support_1.0.0.bb | 16 + meta/packages/psmisc/psmisc-20.2/gettext.patch | 18062 ++++++++ meta/packages/psmisc/psmisc_20.2.bb | 43 + meta/packages/puzzles/puzzles/game.png | Bin 0 -> 2168 bytes meta/packages/puzzles/puzzles_r6727.bb | 45 + meta/packages/qemu/files/configure.patch | 13 + meta/packages/qemu/files/mouse_fix-r0.patch | 25 + meta/packages/qemu/files/nodocs_cvs.patch | 44 + meta/packages/qemu/files/pl110_rgb-r0.patch | 219 + meta/packages/qemu/qemu-native_cvs.bb | 14 + meta/packages/qemu/qemu_cvs.bb | 13 + meta/packages/quilt/files/install.patch | 19 + meta/packages/quilt/files/non-gnu.patch | 13 + meta/packages/quilt/files/nostrip.patch | 16 + meta/packages/quilt/quilt-native_0.42.bb | 14 + meta/packages/quilt/quilt-package.inc | 10 + meta/packages/quilt/quilt.inc | 13 + meta/packages/quilt/quilt_0.42.bb | 7 + meta/packages/randrext/randrext_1.0.bb | 16 + meta/packages/randrext/randrext_cvs.bb | 18 + meta/packages/readline/readline-4.3/acinclude.m4 | 1815 + .../readline/readline-4.3/shlink-termcap.patch | 45 + meta/packages/readline/readline-native_4.3.bb | 4 + meta/packages/readline/readline_4.3.bb | 34 + meta/packages/recordext/recordext_cvs.bb | 18 + meta/packages/renderext/renderext_0.8.bb | 16 + meta/packages/renderext/renderext_cvs.bb | 19 + meta/packages/resourceext/resourceext_1.0.bb | 17 + meta/packages/resourceext/resourceext_cvs.bb | 19 + meta/packages/rxvt-unicode/files/makefile.patch | 20 + meta/packages/rxvt-unicode/files/rxvt.desktop | 10 + meta/packages/rxvt-unicode/files/rxvt.png | Bin 0 -> 2847 bytes meta/packages/rxvt-unicode/files/signedchar.patch | 11 + meta/packages/rxvt-unicode/files/xwc.patch | 28 + .../rxvt-unicode/rxvt-unicode-5.6/xwc.patch | 24 + meta/packages/rxvt-unicode/rxvt-unicode_5.6.bb | 68 + meta/packages/scap/files/scap.desktop | 9 + meta/packages/scap/files/scap.png | Bin 0 -> 628 bytes meta/packages/scap/files/scap.sh | 20 + meta/packages/scap/scap_0.1.bb | 15 + meta/packages/setserial/setserial_2.17.bb | 12 + .../settings-daemon/files/70settings-daemon | 3 + .../settings-daemon/settings-daemon_svn.bb | 18 + .../shared-mime-info/shared-mime-info_0.16.bb | 18 + .../sharp-binary-only/sharp-flash-header-c700.bb | 8 + .../sharp-flash-header-c700/header-c700.bin | Bin 0 -> 16 bytes .../startup-notification_0.8.bb | 19 + meta/packages/strace/strace-4.5.12/quota.patch | 10 + meta/packages/strace/strace/arm-syscallent.patch | 402 + meta/packages/strace/strace_4.5.12.bb | 13 + meta/packages/sysfsutils/sysfsutils_2.0.0.bb | 23 + meta/packages/sysvinit/sysvinit-2.86/install.patch | 77 + .../sysvinit/sysvinit-2.86/sysvinit-2.86.patch | 4880 +++ meta/packages/sysvinit/sysvinit/bootlogd.init | 85 + meta/packages/sysvinit/sysvinit/inittab | 30 + meta/packages/sysvinit/sysvinit/need | 6 + meta/packages/sysvinit/sysvinit/postinst | 17 + meta/packages/sysvinit/sysvinit/prerm | 9 + meta/packages/sysvinit/sysvinit/provide | 6 + meta/packages/sysvinit/sysvinit/rc | 102 + meta/packages/sysvinit/sysvinit/rcS | 110 + meta/packages/sysvinit/sysvinit/rcS-default | 21 + meta/packages/sysvinit/sysvinit_2.86.bb | 130 + .../tinylogin/tinylogin-1.4/add-system.patch | 115 + .../tinylogin-1.4/adduser-empty_pwd.patch | 43 + .../tinylogin/tinylogin-1.4/cvs-20040608.patch | 821 + meta/packages/tinylogin/tinylogin_1.4.bb | 28 + meta/packages/tslib/tslib-maemo/multievent.patch | 843 + meta/packages/tslib/tslib-maemo/nokia770/ts.conf | 2 + meta/packages/tslib/tslib-maemo/nokia770/tslib.sh | 5 + meta/packages/tslib/tslib-maemo/ts.conf | 25 + meta/packages/tslib/tslib-maemo_0.0.1-15.bb | 49 + meta/packages/tslib/tslib/akita/tslib.sh | 16 + meta/packages/tslib/tslib/c7x0/tslib.sh | 16 + meta/packages/tslib/tslib/collie/ts.conf | 5 + meta/packages/tslib/tslib/collie/tslib.sh | 16 + meta/packages/tslib/tslib/devfs.patch | 18 + meta/packages/tslib/tslib/event1.patch | 80 + meta/packages/tslib/tslib/h1940/tslib.sh | 8 + meta/packages/tslib/tslib/h3600/tslib.sh | 15 + meta/packages/tslib/tslib/h3900/tslib.sh | 19 + meta/packages/tslib/tslib/h6300/tslib.sh | 7 + meta/packages/tslib/tslib/ipaq-pxa270/tslib.sh | 6 + meta/packages/tslib/tslib/jornada56x/ts.conf | 5 + meta/packages/tslib/tslib/jornada56x/tslib.sh | 6 + meta/packages/tslib/tslib/jornada6xx/ts.conf | 5 + meta/packages/tslib/tslib/jornada6xx/tslib.sh | 6 + meta/packages/tslib/tslib/jornada7xx/ts.conf | 5 + meta/packages/tslib/tslib/jornada7xx/tslib.sh | 6 + meta/packages/tslib/tslib/mnci/ts.conf | 5 + meta/packages/tslib/tslib/mnci/tslib.sh | 1 + meta/packages/tslib/tslib/multievent.patch | 843 + meta/packages/tslib/tslib/nokia770/ts.conf | 25 + meta/packages/tslib/tslib/omap1610h2/ts.conf | 5 + meta/packages/tslib/tslib/omap1610h2/tslib.sh | 5 + meta/packages/tslib/tslib/omap5912osk/ts.conf | 6 + meta/packages/tslib/tslib/omap5912osk/tslib.sh | 4 + meta/packages/tslib/tslib/poodle/tslib.sh | 16 + meta/packages/tslib/tslib/simpad/tslib.sh | 15 + meta/packages/tslib/tslib/spitz/tslib.sh | 16 + meta/packages/tslib/tslib/tosa/tslib.sh | 16 + meta/packages/tslib/tslib/ts-2.6.conf | 5 + meta/packages/tslib/tslib/ts.conf | 25 + meta/packages/tslib/tslib/ts.conf-collie-2.4 | 5 + meta/packages/tslib/tslib/ts.conf-corgi-2.4 | 5 + meta/packages/tslib/tslib/ts.conf-h3600-2.4 | 5 + meta/packages/tslib/tslib/ts.conf-simpad-2.4 | 5 + meta/packages/tslib/tslib/tslib.sh | 0 meta/packages/tslib/tslib/usec_fix.patch | 26 + meta/packages/tslib/tslib_cvs.bb | 81 + meta/packages/udev/files/akita/mount.blacklist | 6 + meta/packages/udev/files/c7x0/mount.blacklist | 6 + meta/packages/udev/files/devfs-udev.rules | 108 + meta/packages/udev/files/fix-alignment.patch | 24 + meta/packages/udev/files/init | 208 + meta/packages/udev/files/links.conf | 21 + meta/packages/udev/files/local.rules | 22 + meta/packages/udev/files/mount.blacklist | 2 + meta/packages/udev/files/mount.sh | 67 + meta/packages/udev/files/network.sh | 55 + meta/packages/udev/files/noasmlinkage.patch | 38 + meta/packages/udev/files/permissions.rules | 81 + meta/packages/udev/files/slugos/mount.blacklist | 4 + meta/packages/udev/files/spitz/mount.blacklist | 7 + meta/packages/udev/files/tmpfs.patch | 16 + meta/packages/udev/files/tosa/mount.blacklist | 6 + meta/packages/udev/files/udev.rules | 98 + meta/packages/udev/files/udev_network_queue.sh | 35 + meta/packages/udev/files/udevsynthesize.patch | 776 + meta/packages/udev/files/udevsynthesize.sh | 51 + meta/packages/udev/udev-084/flags.patch | 52 + meta/packages/udev/udev-084/init | 227 + meta/packages/udev/udev-084/local.rules | 28 + meta/packages/udev/udev-084/udev.rules | 99 + meta/packages/udev/udev-089/flags.patch | 51 + meta/packages/udev/udev-089/init | 227 + meta/packages/udev/udev-089/local.rules | 28 + meta/packages/udev/udev-089/udev.rules | 98 + meta/packages/udev/udev-092/flags.patch | 51 + meta/packages/udev/udev-092/init | 227 + meta/packages/udev/udev-092/local.rules | 31 + meta/packages/udev/udev-092/permissions.rules | 109 + meta/packages/udev/udev-092/udev.rules | 98 + meta/packages/udev/udev.inc | 61 + meta/packages/udev/udev_084.bb | 60 + meta/packages/udev/udev_089.bb | 49 + meta/packages/udev/udev_092.bb | 49 + .../update-modules-1.0/openmn/update-modules | 3 + .../update-modules-1.0/update-modules | 197 + meta/packages/update-modules/update-modules_1.0.bb | 19 + .../update-rc.d/update-rc.d-0.6/copyright.patch | 27 + meta/packages/update-rc.d/update-rc.d_0.6.bb | 22 + meta/packages/update-rc.d/update-rc.d_0.7.bb | 21 + .../packages/vera-fonts/ttf-bitstream-vera_1.10.bb | 34 + meta/packages/web/web_svn.bb | 12 + .../wireless-tools/wireless-tools/fixheaders.patch | 34 + .../wireless-tools/wireless-tools/man.patch | 13 + .../wireless-tools/wireless-tools.if-pre-up | 122 + .../wireless-tools/zzz-wireless.if-pre-up | 34 + .../wireless-tools/wireless-tools_28-pre6.bb | 43 + .../wireless-tools/wireless-tools_29-pre10.bb | 44 + meta/packages/wpa-supplicant/files/defaults-sane | 8 + meta/packages/wpa-supplicant/files/defconfig | 157 + .../packages/wpa-supplicant/files/defconfig-gnutls | 176 + .../wpa-supplicant/files/driver-hermes.patch | 889 + meta/packages/wpa-supplicant/files/init.sh | 50 + .../wpa-supplicant/files/madwifi-bsd-fix.diff | 12 + meta/packages/wpa-supplicant/files/mtx-1/defconfig | 157 + meta/packages/wpa-supplicant/files/openmn/defaults | 8 + .../wpa-supplicant/files/slugos/defaults-sane | 8 + .../wpa-supplicant/files/use-channel.patch | 32 + .../wpa-supplicant/files/wpa_supplicant.conf | 502 + .../wpa-supplicant/files/wpa_supplicant.conf-sane | 7 + .../files/wpa_supplicant_default.conf | 13 + .../wpa-supplicant/wpa-supplicant-0.4.7/defconfig | 160 + .../wpa-supplicant-0.4.7/driver-hermes.patch | 884 + .../wpa-supplicant-0.4.7/driver-zd1211.patch | 535 + .../wpa-supplicant-0.4.7/madwifi-bsd-fix.diff | 12 + .../wpa-supplicant-0.4.7/wpa_supplicant.conf | 502 + .../wpa-supplicant-nossl/wpa-defconfig | 4 + .../wpa-supplicant/wpa-supplicant-nossl_0.2.6.bb | 7 + .../wpa-supplicant-ssl/wpa-defconfig | 15 + .../wpa-supplicant/wpa-supplicant-ssl_0.2.6.bb | 9 + .../wpa-supplicant/wpa-supplicant_0.2.6.inc | 34 + .../wpa-supplicant/wpa-supplicant_0.3.6.bb | 34 + .../wpa-supplicant/wpa-supplicant_0.3.8.bb | 36 + .../wpa-supplicant/wpa-supplicant_0.4.7.bb | 38 + .../wpa-supplicant/wpa-supplicant_0.5.1.bb | 58 + meta/packages/wpa-supplicant/wpa-supplicant_cvs.bb | 59 + meta/packages/xauth/xauth/autofoo.patch | 148 + meta/packages/xauth/xauth_cvs.bb | 13 + meta/packages/xcalibrate/xcalibrate_cvs.bb | 15 + meta/packages/xcalibrateext/xcalibrateext_cvs.bb | 13 + .../fix_watch_cursor.patch | 24 + .../use-relative-symlinks.patch | 11 + .../xcursor-transparent-theme_0.1.1.bb | 11 + meta/packages/xdpyinfo/xdpyinfo_cvs.bb | 12 + .../xextensions/xextensions-native_1.0.1.bb | 4 + meta/packages/xextensions/xextensions_1.0.1.bb | 13 + meta/packages/xhost/xhost/autofoo.patch | 165 + meta/packages/xhost/xhost_20040413.bb | 14 + meta/packages/xlibs/diet-x11_6.2.1.bb | 10 + meta/packages/xlibs/libice/autofoo.patch | 21 + meta/packages/xlibs/libice_6.3.3.bb | 18 + meta/packages/xlibs/libsm/autofoo.patch | 21 + meta/packages/xlibs/libsm_6.0.3.bb | 17 + meta/packages/xlibs/libx11-native_6.2.1.bb | 6 + meta/packages/xlibs/libx11/autofoo.patch | 22 + .../xlibs/libx11/errordb-keysymdb-path-fix.patch | 22 + .../xlibs/libx11/fix-utf8-wrong-define.patch | 16 + meta/packages/xlibs/libx11_6.2.1.bb | 40 + meta/packages/xlibs/libxau-native_0.1.1.bb | 6 + meta/packages/xlibs/libxau-native_cvs.bb | 6 + meta/packages/xlibs/libxau/autofoo.patch | 21 + meta/packages/xlibs/libxau_0.1.1.bb | 18 + meta/packages/xlibs/libxau_cvs.bb | 18 + .../xlibs/libxcomposite-1.0.1/autofoo.patch | 17 + meta/packages/xlibs/libxcomposite_1.0.1.bb | 16 + meta/packages/xlibs/libxcomposite_cvs.bb | 15 + meta/packages/xlibs/libxcursor-1.1.2/autofoo.patch | 20 + meta/packages/xlibs/libxcursor/autofoo.patch | 22 + meta/packages/xlibs/libxcursor_1.1.2.bb | 18 + meta/packages/xlibs/libxdamage-1.0.1/autofoo.patch | 17 + meta/packages/xlibs/libxdamage/m4.patch | 65 + meta/packages/xlibs/libxdamage_1.0.1.bb | 17 + meta/packages/xlibs/libxdamage_cvs.bb | 16 + meta/packages/xlibs/libxdmcp-native_0.1.3.bb | 6 + meta/packages/xlibs/libxdmcp/autofoo.patch | 22 + meta/packages/xlibs/libxdmcp_0.1.3.bb | 18 + meta/packages/xlibs/libxext-native_cvs.bb | 6 + meta/packages/xlibs/libxext/autofoo.patch | 18 + meta/packages/xlibs/libxext_cvs.bb | 16 + meta/packages/xlibs/libxfixes/autofoo.patch | 20 + meta/packages/xlibs/libxfixes_2.0.1.bb | 15 + meta/packages/xlibs/libxfixes_cvs.bb | 14 + meta/packages/xlibs/libxfont/autofoo.patch | 18 + meta/packages/xlibs/libxfont/scalable.patch | 27 + meta/packages/xlibs/libxfont_1.4.2.bb | 19 + meta/packages/xlibs/libxfont_cvs.bb | 18 + meta/packages/xlibs/libxft/autofoo.patch | 21 + meta/packages/xlibs/libxft_2.1.6.bb | 27 + meta/packages/xlibs/libxft_cvs.bb | 26 + meta/packages/xlibs/libxi/autofoo.patch | 12 + meta/packages/xlibs/libxi_6.0.1.bb | 16 + meta/packages/xlibs/libxmu_cvs.bb | 21 + meta/packages/xlibs/libxpm/autofoo.patch | 18 + meta/packages/xlibs/libxpm_3.5.1.bb | 19 + meta/packages/xlibs/libxpm_cvs.bb | 19 + meta/packages/xlibs/libxrandr-1.0.2/autofoo.patch | 20 + meta/packages/xlibs/libxrandr/autofoo.patch | 30 + meta/packages/xlibs/libxrandr_1.0.2.bb | 15 + meta/packages/xlibs/libxrender/autofoo.patch | 20 + meta/packages/xlibs/libxrender_cvs.bb | 15 + meta/packages/xlibs/libxt/autofoo.patch | 20 + meta/packages/xlibs/libxt_0.1.5.bb | 29 + meta/packages/xlibs/libxtst_cvs.bb | 17 + meta/packages/xlibs/xtrans-native_0.1.bb | 3 + meta/packages/xlibs/xtrans_0.1.bb | 15 + meta/packages/xlibs/xtrans_cvs.bb | 16 + meta/packages/xmodmap/xmodmap/autofoo.patch | 109 + meta/packages/xmodmap/xmodmap_cvs.bb | 14 + meta/packages/xournal/files/no-printing.diff | 178 + meta/packages/xournal/xournal_0.2.bb | 12 + meta/packages/xproto/xproto-native_6.6.2.bb | 4 + meta/packages/xproto/xproto-native_cvs.bb | 4 + meta/packages/xproto/xproto_6.6.2+cvs20050226.bb | 13 + meta/packages/xproto/xproto_6.6.2.bb | 13 + meta/packages/xproto/xproto_cvs.bb | 15 + meta/packages/xrandr/xrandr_cvs.bb | 10 + meta/packages/xrdb/xrdb/autofoo.patch | 132 + meta/packages/xrdb/xrdb_cvs.bb | 13 + .../xserver-kdrive-common/etc/X11/Xdefaults | 3 + .../xserver-kdrive-common/etc/X11/Xinit | 16 + .../xserver-kdrive-common/etc/X11/Xinit.d/01xrandr | 4 + .../xserver-kdrive-common/etc/X11/Xinit.d/11zaurus | 12 + .../xserver-kdrive-common/etc/X11/Xinit.d/12keymap | 23 + .../etc/X11/Xinit.d/30xTs_Calibrate | 6 + .../etc/X11/Xinit.d/40xmodmap | 5 + .../etc/X11/Xinit.d/55xScreenSaver | 4 + .../etc/X11/Xinit.d/60xXDefaults | 3 + .../xserver-kdrive-common/etc/X11/Xserver | 75 + .../xserver-kdrive-common/etc/X11/Xsession | 47 + .../etc/X11/Xsession.d/60xXDefaults | 4 + .../etc/X11/Xsession.d/90xXWindowManager | 8 + .../xserver-kdrive-common/etc/X11/collie.xmodmap | 5 + .../xserver-kdrive-common/etc/X11/h2200.xmodmap | 5 + .../xserver-kdrive-common/etc/X11/shepherd.xmodmap | 49 + .../xserver-kdrive-common/etc/X11/simpad.xmodmap | 2 + .../xserver-kdrive-common_0.1.bb | 18 + .../xserver-kdrive-common/xserver-nodm-init.bb | 21 + .../xserver-nodm-init/xserver-nodm | 48 + .../xserver-kdrive-omap/configure-tslib.patch | 13 + .../xserver-kdrive-omap/fbdev-not-fix.patch | 14 + .../xserver/xserver-kdrive-omap/kmode.patch | 19 + meta/packages/xserver/xserver-kdrive-omap_6.6.3.bb | 26 + .../build-20050207-against-X11R7.diff | 464 + meta/packages/xserver/xserver-kdrive/devfs.patch | 47 + .../xserver/xserver-kdrive/disable-apm.patch | 20 + meta/packages/xserver/xserver-kdrive/epson.patch | 11 + .../xserver/xserver-kdrive/faster-rotated.patch | 241 + .../xserver/xserver-kdrive/fbdev-not-fix.patch | 14 + .../xserver/xserver-kdrive/kdrive-evdev.patch | 515 + .../xserver/xserver-kdrive/kdrive-use-evdev.patch | 53 + meta/packages/xserver/xserver-kdrive/kmode.patch | 28 + .../xserver/xserver-kdrive/no-serial-probing.patch | 13 + meta/packages/xserver/xserver-kdrive/onlyfb.patch | 21 + .../xserver-kdrive/xserver-kdrive-poodle.patch | 44 + meta/packages/xserver/xserver-kdrive_20050207.bb | 74 + meta/packages/xserver/xserver-kdrive_20050624.bb | 49 + meta/packages/xserver/xserver-kdrive_20060312.bb | 52 + meta/packages/xserver/xserver-kdrive_cvs.bb | 47 + meta/packages/xserver/xserver-xorg/dri.patch | 10 + meta/packages/xserver/xserver-xorg/fontfile.patch | 11 + meta/packages/xserver/xserver-xorg/freetype.patch | 22 + .../xserver/xserver-xorg/imake-installed.patch | 11 + .../xserver/xserver-xorg/imake-staging.patch | 38 + meta/packages/xserver/xserver-xorg_6.8.99.10.bb | 65 + meta/packages/xserver/xserver-xorg_6.8.99.11.bb | 65 + meta/packages/xserver/xserver-xorg_cvs.bb | 61 + meta/packages/xset/xset/autofoo.patch | 109 + meta/packages/xset/xset/disable-xkb.patch | 18 + meta/packages/xset/xset_20040817.bb | 18 + meta/packages/xtscal/xtscal/xtscal-cxk.patch | 11 + meta/packages/xtscal/xtscal/xtscal-poodle.patch | 12 + meta/packages/xtscal/xtscal_0.6.3.bb | 13 + meta/packages/zaurus-updater/akita/updater.sh | 252 + meta/packages/zaurus-updater/c7x0/updater.sh | 242 + .../zaurus-updater/encdec-updater-native.bb | 6 + meta/packages/zaurus-updater/encdec-updater.bb | 16 + .../packages/zaurus-updater/files/encdec-updater.c | 80 + meta/packages/zaurus-updater/files/gnu-tar.gz | Bin 0 -> 242146 bytes meta/packages/zaurus-updater/poodle/updater.sh | 231 + meta/packages/zaurus-updater/spitz/updater.sh | 280 + meta/packages/zaurus-updater/tosa/updater.sh | 241 + meta/packages/zaurus-updater/zaurus-updater.bb | 31 + meta/packages/zaurusd/zaurusd_svn.bb | 18 + meta/packages/zeroconf/files/debian-zeroconf | 51 + meta/packages/zeroconf/files/zeroconf-default | 17 + meta/packages/zeroconf/zeroconf_0.9.bb | 21 + meta/packages/zile/files/for_build.patch | 64 + meta/packages/zile/zile_1.7+2.0beta6.bb | 20 + meta/packages/zip/zip-native_2.31.bb | 9 + meta/packages/zip/zip_2.31.bb | 17 + meta/packages/zlib/files/visibility.patch | 1022 + meta/packages/zlib/files/zlib_1.2.2-8.diff.gz | Bin 0 -> 15553 bytes meta/packages/zlib/zlib-1.2.3/visibility.patch | 1034 + meta/packages/zlib/zlib-native_1.1.4.bb | 4 + meta/packages/zlib/zlib-native_1.2.2.bb | 4 + meta/packages/zlib/zlib-native_1.2.3.bb | 5 + meta/packages/zlib/zlib_1.1.4.bb | 34 + meta/packages/zlib/zlib_1.2.2.bb | 38 + meta/packages/zlib/zlib_1.2.3.bb | 37 + 1561 files changed, 330312 insertions(+) create mode 100644 meta/packages/alsa/alsa-lib_1.0.10.bb create mode 100644 meta/packages/alsa/alsa-oss_1.0.10.bb create mode 100644 meta/packages/alsa/alsa-tools_1.0.10.bb create mode 100644 meta/packages/alsa/alsa-utils_1.0.10.bb create mode 100644 meta/packages/alsa/files/alsa-utils-sys-siglist.patch create mode 100644 meta/packages/apmd/apmd-3.2.2/apmd_proxy create mode 100644 meta/packages/apmd/apmd-3.2.2/apmd_proxy.conf create mode 100644 meta/packages/apmd/apmd-3.2.2/debian.patch create mode 100644 meta/packages/apmd/apmd-3.2.2/default create mode 100755 meta/packages/apmd/apmd-3.2.2/init create mode 100644 meta/packages/apmd/apmd-3.2.2/workaround.patch create mode 100644 meta/packages/apmd/apmd-3.2.2/zaurus24.patch create mode 100644 meta/packages/apmd/apmd_3.2.2.bb create mode 100644 meta/packages/atk/atk_1.10.1.bb create mode 100644 meta/packages/autoconf/autoconf-2.59/autoconf-x.patch create mode 100644 meta/packages/autoconf/autoconf-2.59/autoconf259-update-configscripts.patch create mode 100644 meta/packages/autoconf/autoconf-2.59/autoheader-nonfatal-warnings.patch create mode 100644 meta/packages/autoconf/autoconf-2.59/autoreconf-exclude.patch create mode 100644 meta/packages/autoconf/autoconf-2.59/autoreconf-foreign.patch create mode 100644 meta/packages/autoconf/autoconf-2.59/autoreconf-gnuconfigize.patch create mode 100644 meta/packages/autoconf/autoconf-2.59/autoreconf-include.patch create mode 100644 meta/packages/autoconf/autoconf-2.59/path_prog_fixes.patch create mode 100644 meta/packages/autoconf/autoconf-2.59/program_prefix.patch create mode 100644 meta/packages/autoconf/autoconf-2.59/sizeof_types.patch create mode 100644 meta/packages/autoconf/autoconf-native_2.59.bb create mode 100644 meta/packages/autoconf/autoconf_2.59.bb create mode 100644 meta/packages/automake/automake-1.9.3/automake182-update-configscripts.patch create mode 100644 meta/packages/automake/automake-native.inc create mode 100644 meta/packages/automake/automake-native_1.9.3.bb create mode 100644 meta/packages/automake/automake.inc create mode 100644 meta/packages/automake/automake_1.9.3.bb create mode 100644 meta/packages/automake/files/path_prog_fixes.patch create mode 100644 meta/packages/avahi/avahi_0.6.10.bb create mode 100644 meta/packages/base-files/base-files/akita/fstab create mode 100644 meta/packages/base-files/base-files/c7x0/fstab create mode 100644 meta/packages/base-files/base-files/c7x0/usbd create mode 100644 meta/packages/base-files/base-files/collie/fstab create mode 100644 meta/packages/base-files/base-files/collie/usbd create mode 100644 meta/packages/base-files/base-files/epia/fstab create mode 100644 meta/packages/base-files/base-files/familiar/issue create mode 100644 meta/packages/base-files/base-files/familiar/issue.net create mode 100644 meta/packages/base-files/base-files/filesystems create mode 100644 meta/packages/base-files/base-files/fstab create mode 100644 meta/packages/base-files/base-files/h3600/fstab create mode 100644 meta/packages/base-files/base-files/h3900/fstab create mode 100644 meta/packages/base-files/base-files/host.conf create mode 100644 meta/packages/base-files/base-files/inputrc create mode 100644 meta/packages/base-files/base-files/ipaq-pxa270/fstab create mode 100644 meta/packages/base-files/base-files/issue create mode 100644 meta/packages/base-files/base-files/issue.net create mode 100644 meta/packages/base-files/base-files/jornada56x/fstab create mode 100644 meta/packages/base-files/base-files/jornada720/fstab create mode 100644 meta/packages/base-files/base-files/licenses/Artistic create mode 100644 meta/packages/base-files/base-files/licenses/BSD create mode 100644 meta/packages/base-files/base-files/licenses/GPL-2 create mode 100644 meta/packages/base-files/base-files/licenses/LGPL-2 create mode 100644 meta/packages/base-files/base-files/licenses/LGPL-2.1 create mode 100644 meta/packages/base-files/base-files/motd create mode 100644 meta/packages/base-files/base-files/mtx-1/fstab create mode 100644 meta/packages/base-files/base-files/mtx-1/profile create mode 100644 meta/packages/base-files/base-files/netvista/fstab create mode 100644 meta/packages/base-files/base-files/nokia770/fstab create mode 100644 meta/packages/base-files/base-files/nsswitch.conf create mode 100644 meta/packages/base-files/base-files/nylon/issue create mode 100644 meta/packages/base-files/base-files/nylon/issue.net create mode 100644 meta/packages/base-files/base-files/openmn/fstab create mode 100644 meta/packages/base-files/base-files/openmn/issue create mode 100644 meta/packages/base-files/base-files/openmn/issue.net create mode 100644 meta/packages/base-files/base-files/openmn/profile create mode 100644 meta/packages/base-files/base-files/openmn/usbd create mode 100644 meta/packages/base-files/base-files/opensimpad/issue create mode 100644 meta/packages/base-files/base-files/opensimpad/issue.net create mode 100644 meta/packages/base-files/base-files/openzaurus/issue create mode 100644 meta/packages/base-files/base-files/openzaurus/issue.net create mode 100644 meta/packages/base-files/base-files/poodle/fstab create mode 100644 meta/packages/base-files/base-files/poodle/usbd create mode 100644 meta/packages/base-files/base-files/profile create mode 100644 meta/packages/base-files/base-files/share/dot.bashrc create mode 100644 meta/packages/base-files/base-files/share/dot.profile create mode 100644 meta/packages/base-files/base-files/simpad/fstab create mode 100644 meta/packages/base-files/base-files/spitz/fstab create mode 100644 meta/packages/base-files/base-files/tosa/fstab create mode 100644 meta/packages/base-files/base-files/tosa/usbd create mode 100644 meta/packages/base-files/base-files/usbd create mode 100644 meta/packages/base-files/base-files/wrt54/fstab create mode 100644 meta/packages/base-files/base-files/wrt54/profile create mode 100644 meta/packages/base-files/base-files/xxs1500/fstab create mode 100644 meta/packages/base-files/base-files_3.0.14.bb create mode 100644 meta/packages/base-passwd/base-passwd-3.5.9/configure.patch create mode 100644 meta/packages/base-passwd/base-passwd-3.5.9/mysql.patch create mode 100644 meta/packages/base-passwd/base-passwd-3.5.9/nobash.patch create mode 100644 meta/packages/base-passwd/base-passwd-3.5.9/root-home.patch create mode 100644 meta/packages/base-passwd/base-passwd_3.5.9.bb create mode 100644 meta/packages/binutils/binutils-2.15.94.0.1/binutils-100_cflags_for_build.patch create mode 100644 meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.90.0.3-uclibc-200-build_modules.patch create mode 100644 meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.90.0.3-uclibc-210-cflags.patch create mode 100644 meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.91.0.1-uclibc-100-conf.patch create mode 100644 meta/packages/binutils/binutils-2.16.91.0.7/binutils-2.16.91.0.6-objcopy-rename-errorcode.patch create mode 100644 meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-100-uclibc-conf.patch create mode 100644 meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-001_ld_makefile_patch.patch create mode 100644 meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-006_better_file_error.patch create mode 100644 meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-012_check_ldrunpath_length.patch create mode 100644 meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-400-mips-ELF_MAXPAGESIZE-4K.patch create mode 100644 meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-702-binutils-skip-comments.patch create mode 100644 meta/packages/binutils/binutils-2.16/binutils-100_cflags_for_build.patch create mode 100644 meta/packages/binutils/binutils-2.16/binutils-2.16-linux-uclibc.patch create mode 100644 meta/packages/binutils/binutils-2.16/binutils-2.16-objcopy-rename-errorcode.patch create mode 100644 meta/packages/binutils/binutils-2.16/binutils-2.16-thumb-glue.patch create mode 100644 meta/packages/binutils/binutils-2.16/binutils-2.16-thumb-trampoline.patch create mode 100644 meta/packages/binutils/binutils-cross.inc create mode 100644 meta/packages/binutils/binutils-cross_2.15.94.0.1.bb create mode 100644 meta/packages/binutils/binutils-cross_2.16.91.0.7.bb create mode 100644 meta/packages/binutils/binutils-cross_2.16.bb create mode 100644 meta/packages/binutils/binutils.inc create mode 100644 meta/packages/binutils/binutils_2.15.94.0.1.bb create mode 100644 meta/packages/binutils/binutils_2.16.91.0.7.bb create mode 100644 meta/packages/binutils/binutils_2.16.bb create mode 100644 meta/packages/binutils/files/better_file_error.patch create mode 100644 meta/packages/binutils/files/ld_makefile.patch create mode 100644 meta/packages/binutils/files/objdump_fix.patch create mode 100644 meta/packages/binutils/files/plt32trunc.patch create mode 100644 meta/packages/binutils/files/signed_char_fix.patch create mode 100644 meta/packages/bison/bison-2.0/m4.patch create mode 100644 meta/packages/bison/bison-native_2.0.bb create mode 100644 meta/packages/bison/bison_2.0.bb create mode 100644 meta/packages/busybox/busybox-1.01/add-getkey-applet.patch create mode 100644 meta/packages/busybox/busybox-1.01/angstrom/defconfig create mode 100644 meta/packages/busybox/busybox-1.01/below.patch create mode 100644 meta/packages/busybox/busybox-1.01/defconfig create mode 100644 meta/packages/busybox/busybox-1.01/dhcp-hostname.patch create mode 100644 meta/packages/busybox/busybox-1.01/dhcpretrytime.patch create mode 100644 meta/packages/busybox/busybox-1.01/familiar/defconfig create mode 100644 meta/packages/busybox/busybox-1.01/fbset.patch create mode 100644 meta/packages/busybox/busybox-1.01/hdparm_M.patch create mode 100644 meta/packages/busybox/busybox-1.01/ifupdown-spurious-environ.patch create mode 100644 meta/packages/busybox/busybox-1.01/iproute-flush-cache.patch create mode 100644 meta/packages/busybox/busybox-1.01/mount-all-type.patch create mode 100644 meta/packages/busybox/busybox-1.01/nylon/defconfig create mode 100644 meta/packages/busybox/busybox-1.01/openmn/defconfig create mode 100644 meta/packages/busybox/busybox-1.01/openzaurus/defconfig create mode 100644 meta/packages/busybox/busybox-1.01/readlink.patch create mode 100644 meta/packages/busybox/busybox-1.01/rmmod.patch create mode 100644 meta/packages/busybox/busybox-1.01/slugos/defconfig create mode 100644 meta/packages/busybox/busybox-1.01/slugos/sysctl.conf create mode 100644 meta/packages/busybox/busybox-1.01/slugos/udhcpscript.patch create mode 100644 meta/packages/busybox/busybox-1.01/sparc/defconfig create mode 100644 meta/packages/busybox/busybox-1.01/thumb-bsdlabel.patch create mode 100644 meta/packages/busybox/busybox-1.01/uclibc_posix.patch create mode 100644 meta/packages/busybox/busybox-1.01/udhcppidfile-breakage.patch create mode 100644 meta/packages/busybox/busybox-1.01/udhcppidfile.patch create mode 100644 meta/packages/busybox/busybox-1.01/udhcpscript.patch create mode 100644 meta/packages/busybox/busybox-1.01/wrt54/defconfig create mode 100644 meta/packages/busybox/busybox_1.01.bb create mode 100755 meta/packages/busybox/files/busybox-cron create mode 100755 meta/packages/busybox/files/busybox-httpd create mode 100755 meta/packages/busybox/files/busybox-udhcpd create mode 100644 meta/packages/busybox/files/default.script create mode 100644 meta/packages/busybox/files/glibc2.4-icmp6.patch create mode 100644 meta/packages/busybox/files/hwclock.sh create mode 100755 meta/packages/busybox/files/mount.busybox create mode 100644 meta/packages/busybox/files/postinst create mode 100644 meta/packages/busybox/files/prerm create mode 100644 meta/packages/busybox/files/syslog create mode 100644 meta/packages/busybox/files/syslog.conf create mode 100755 meta/packages/busybox/files/umount.busybox create mode 100644 meta/packages/bzip2/bzip2-1.0.2/installpaths.patch create mode 100644 meta/packages/bzip2/bzip2_1.0.2.bb create mode 100644 meta/packages/cairo/cairo_1.0.0.bb create mode 100644 meta/packages/cairo/cairo_1.0.4.bb create mode 100644 meta/packages/cairo/cairo_1.2.0.bb create mode 100755 meta/packages/chkhinge26/chkhinge26_svn.bb create mode 100755 meta/packages/chkhinge26/files/hinge-handler create mode 100644 meta/packages/compositeext/compositeext_cvs.bb create mode 100644 meta/packages/console-tools/console-tools-0.3.2/codepage.patch create mode 100644 meta/packages/console-tools/console-tools-0.3.2/compile.patch create mode 100644 meta/packages/console-tools/console-tools-0.3.2/config/codeset.m4 create mode 100644 meta/packages/console-tools/console-tools-0.3.2/config/gettext.m4 create mode 100644 meta/packages/console-tools/console-tools-0.3.2/config/glibc21.m4 create mode 100644 meta/packages/console-tools/console-tools-0.3.2/config/iconv.m4 create mode 100644 meta/packages/console-tools/console-tools-0.3.2/config/lcmessage.m4 create mode 100644 meta/packages/console-tools/console-tools-0.3.2/config/progtest.m4 create mode 100644 meta/packages/console-tools/console-tools-0.3.2/configure.patch create mode 100644 meta/packages/console-tools/console-tools-0.3.2/kbdrate.patch create mode 100644 meta/packages/console-tools/console-tools-0.3.2/uclibc-fileno.patch create mode 100644 meta/packages/console-tools/console-tools_0.3.2.bb create mode 100755 meta/packages/contacts/contacts_0.1.bb create mode 100755 meta/packages/contacts/contacts_svn.bb create mode 100644 meta/packages/contacts/files/stock_contact.png create mode 100644 meta/packages/contacts/files/stock_person.png create mode 100644 meta/packages/coreutils/coreutils-5.1.3/install-cross.patch create mode 100644 meta/packages/coreutils/coreutils-5.1.3/man.patch create mode 100644 meta/packages/coreutils/coreutils-native_5.1.3.bb create mode 100644 meta/packages/coreutils/coreutils_5.1.3.bb create mode 100644 meta/packages/curl/curl-native_7.14.0.bb create mode 100644 meta/packages/curl/curl_7.14.0.bb create mode 100644 meta/packages/damageext/damageext-1.0/autofoo.patch create mode 100644 meta/packages/damageext/damageext_cvs.bb create mode 100755 meta/packages/dates/dates_0.1.bb create mode 100755 meta/packages/dates/dates_svn.bb create mode 100644 meta/packages/db/db-native_4.2.52.bb create mode 100644 meta/packages/db/db_4.1.25.bb create mode 100644 meta/packages/db/db_4.2.52.bb create mode 100644 meta/packages/db/db_4.3.29.bb create mode 100644 meta/packages/db/files/arm-thumb-mutex.patch create mode 100644 meta/packages/dbus/dbus-0.60/dbus-1.init create mode 100644 meta/packages/dbus/dbus-0.60/no-bindings.patch create mode 100644 meta/packages/dbus/dbus-0.60/no-introspect.patch create mode 100644 meta/packages/dbus/dbus-native_0.50.bb create mode 100644 meta/packages/dbus/dbus-native_0.60.bb create mode 100644 meta/packages/dbus/dbus.inc create mode 100644 meta/packages/dbus/dbus/0.23.1.diff create mode 100644 meta/packages/dbus/dbus/config.diff create mode 100644 meta/packages/dbus/dbus/cross.patch create mode 100644 meta/packages/dbus/dbus/dbus-1.init create mode 100644 meta/packages/dbus/dbus/dbus-monitor.patch create mode 100644 meta/packages/dbus/dbus/dbus-quiesce-startup-errors.patch create mode 100644 meta/packages/dbus/dbus/dbussend.patch create mode 100644 meta/packages/dbus/dbus/gettext.patch create mode 100644 meta/packages/dbus/dbus/no-bindings.patch create mode 100644 meta/packages/dbus/dbus/no-examples.patch create mode 100644 meta/packages/dbus/dbus/no-introspect.patch create mode 100644 meta/packages/dbus/dbus/spawn-priority.diff create mode 100644 meta/packages/dbus/dbus/tmpdir.patch create mode 100644 meta/packages/dbus/dbus/tools.diff create mode 100644 meta/packages/dbus/dbus_0.60.bb create mode 100644 meta/packages/dbus/dbus_0.60.inc create mode 100644 meta/packages/dropbear/dropbear.inc create mode 100644 meta/packages/dropbear/dropbear/allow-nopw.patch create mode 100644 meta/packages/dropbear/dropbear/chansession-security-fix.patch create mode 100644 meta/packages/dropbear/dropbear/configure.patch create mode 100644 meta/packages/dropbear/dropbear/fix-2kb-keys.patch create mode 100755 meta/packages/dropbear/dropbear/init create mode 100644 meta/packages/dropbear/dropbear/urandom-xauth-changes-to-options.h.patch create mode 100644 meta/packages/dropbear/dropbear_0.47.bb create mode 100644 meta/packages/e2fsprogs/e2fsprogs-1.38/no-hardlinks.patch create mode 100644 meta/packages/e2fsprogs/e2fsprogs/compile-subst.patch create mode 100644 meta/packages/e2fsprogs/e2fsprogs/configure.patch create mode 100644 meta/packages/e2fsprogs/e2fsprogs/e2fsprogs_1.34.bb create mode 100644 meta/packages/e2fsprogs/e2fsprogs/ldflags.patch create mode 100644 meta/packages/e2fsprogs/e2fsprogs/ln.patch create mode 100644 meta/packages/e2fsprogs/e2fsprogs/m4.patch create mode 100644 meta/packages/e2fsprogs/e2fsprogs_1.38.bb create mode 100644 meta/packages/eds/eds-dbus/disable_orbit.patch create mode 100644 meta/packages/eds/eds-dbus/fix_calendar.patch create mode 100644 meta/packages/eds/eds-dbus/iconv-detect.h create mode 100644 meta/packages/eds/eds-dbus/no_iconv_test.patch create mode 100644 meta/packages/eds/eds-dbus/no_libdb.patch create mode 100644 meta/packages/eds/eds-dbus/no_libedataserverui.patch create mode 100644 meta/packages/eds/eds-dbus/no_libgnome.patch create mode 100755 meta/packages/eds/eds-dbus_svn.bb create mode 100644 meta/packages/expat/expat-1.95.7/autotools.patch create mode 100644 meta/packages/expat/expat-native_1.95.7.bb create mode 100644 meta/packages/expat/expat_1.95.7.bb create mode 100644 meta/packages/fakeroot/fakeroot-native_1.2.13.bb create mode 100644 meta/packages/fakeroot/fakeroot_1.2.13.bb create mode 100644 meta/packages/fakeroot/files/fix-prefix.patch create mode 100644 meta/packages/file/file-native_4.16.bb create mode 100644 meta/packages/file/file_4.16.bb create mode 100644 meta/packages/file/files/native-fix.diff create mode 100644 meta/packages/fixesext/fixesext_cvs.bb create mode 100644 meta/packages/flex/files/fix-gen.patch create mode 100644 meta/packages/flex/files/flex-lvalue.diff create mode 100644 meta/packages/flex/flex-2.5.31/include.patch create mode 100644 meta/packages/flex/flex-native_2.5.31.bb create mode 100644 meta/packages/flex/flex.inc create mode 100644 meta/packages/flex/flex_2.5.31.bb create mode 100644 meta/packages/fontconfig/files/local.conf create mode 100644 meta/packages/fontconfig/files/stop-fc-cache.patch create mode 100644 meta/packages/fontconfig/fontconfig-2.2.95/fc-glyphname.patch create mode 100644 meta/packages/fontconfig/fontconfig-2.2.95/fc-lang.patch create mode 100644 meta/packages/fontconfig/fontconfig-native_2.2.95.bb create mode 100644 meta/packages/fontconfig/fontconfig_2.2.95.bb create mode 100644 meta/packages/freetype/files/configure.patch create mode 100644 meta/packages/freetype/files/no-hardcode.patch create mode 100644 meta/packages/freetype/freetype-native_2.1.10.bb create mode 100644 meta/packages/freetype/freetype_2.1.10.bb create mode 100644 meta/packages/galago/eds-feed/disable-bonobo.patch create mode 100644 meta/packages/galago/eds-feed_0.3.2.bb create mode 100644 meta/packages/galago/files/no-check.patch create mode 100644 meta/packages/galago/galago-daemon_0.3.4.bb create mode 100644 meta/packages/galago/libgalago_0.3.3.bb create mode 100644 meta/packages/gcalctool/gcalctool/makefile-fix.diff create mode 100644 meta/packages/gcalctool/gcalctool_5.7.32.bb create mode 100644 meta/packages/gcc/gcc-3.3.4/arm-gotoff.dpatch create mode 100644 meta/packages/gcc/gcc-3.3.4/arm-ldm-peephole.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/arm-ldm.dpatch create mode 100644 meta/packages/gcc/gcc-3.3.4/arm-tune.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/bash3.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-100-conf.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-110-conf.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-120-softfloat.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-200-code.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/gcc34-15089.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/libibery-crosstool.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/reverse-compare.patch create mode 100644 meta/packages/gcc/gcc-3.3.4/sdk-libstdc++-includes.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/15342.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/GCC3.4.0VisibilityPatch.diff create mode 100644 meta/packages/gcc/gcc-3.4.3/always-fixincperm.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-bigendian-uclibc.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-bigendian.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-lib1asm.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-nolibfloat.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-softfloat.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc-3.4.1-uclibc-100-conf.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc-3.4.1-uclibc-200-locale.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc-uclibc-3.4.0-120-softfloat.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc34-arm-ldm-peephole.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc34-arm-ldm.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc34-arm-tune.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/gcc34-reverse-compare.patch create mode 100644 meta/packages/gcc/gcc-3.4.3/sdk-libstdc++-includes.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/15342.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/GCC3.4.0VisibilityPatch.diff create mode 100644 meta/packages/gcc/gcc-3.4.4/always-fixincperm.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-bigendian-uclibc.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-bigendian.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-lib1asm.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-nolibfloat.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-softfloat.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc-3.4.1-uclibc-100-conf.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc-3.4.1-uclibc-200-locale.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc-uclibc-3.4.0-120-softfloat.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc34-arm-ldm-peephole.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc34-arm-ldm.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc34-arm-tune.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc34-configure.in.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc34-reverse-compare.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/gcc34-thumb-support.patch create mode 100644 meta/packages/gcc/gcc-3.4.4/sdk-libstdc++-includes.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/100-uclibc-conf.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/200-uclibc-locale.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/301-missing-execinfo_h.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/302-c99-snprintf.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/303-c99-complex-ugly-hack.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/800-arm-bigendian.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/arm-nolibfloat.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/arm-softfloat.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/ldflags.patch create mode 100644 meta/packages/gcc/gcc-4.0.2/zecke-host-cpp-ac-hack.patch create mode 100644 meta/packages/gcc/gcc-cross-initial_3.3.4.bb create mode 100644 meta/packages/gcc/gcc-cross-initial_3.4.3.bb create mode 100644 meta/packages/gcc/gcc-cross-initial_3.4.4.bb create mode 100644 meta/packages/gcc/gcc-cross-initial_4.0.2.bb create mode 100644 meta/packages/gcc/gcc-cross-initial_csl-arm-2005q3.bb create mode 100644 meta/packages/gcc/gcc-cross_3.3.4.bb create mode 100644 meta/packages/gcc/gcc-cross_3.4.3.bb create mode 100644 meta/packages/gcc/gcc-cross_3.4.4.bb create mode 100644 meta/packages/gcc/gcc-cross_4.0.2.bb create mode 100644 meta/packages/gcc/gcc-cross_csl-arm-2005q3.bb create mode 100644 meta/packages/gcc/gcc-csl-arm/15342.patch create mode 100644 meta/packages/gcc/gcc-csl-arm/gcc-3.4.0-arm-lib1asm.patch create mode 100644 meta/packages/gcc/gcc-csl-arm/gcc34-arm-tune.patch create mode 100644 meta/packages/gcc/gcc-csl-arm/gcc_optab_arm.patch create mode 100644 meta/packages/gcc/gcc-csl-arm/no-libfloat.patch create mode 100644 meta/packages/gcc/gcc-csl-arm/pic-without-sl.patch create mode 100644 meta/packages/gcc/gcc-package-cross.inc create mode 100644 meta/packages/gcc/gcc-package.inc create mode 100644 meta/packages/gcc/gcc-paths-cross.inc create mode 100644 meta/packages/gcc/gcc3-build-cross.inc create mode 100644 meta/packages/gcc/gcc3-build.inc create mode 100644 meta/packages/gcc/gcc4-build.inc create mode 100644 meta/packages/gcc/gcc_3.3.4.bb create mode 100644 meta/packages/gcc/gcc_3.4.3.bb create mode 100644 meta/packages/gcc/gcc_3.4.4.bb create mode 100644 meta/packages/gcc/gcc_4.0.2.bb create mode 100644 meta/packages/gcc/gcc_csl-arm-2005q3.bb create mode 100644 meta/packages/gdb/files/gdbserver-cflags-last.diff create mode 100644 meta/packages/gdb/files/kill_arm_map_symbols.patch create mode 100644 meta/packages/gdb/files/libiberty-cross.patch create mode 100644 meta/packages/gdb/files/sim-install.patch create mode 100644 meta/packages/gdb/files/uclibc.patch create mode 100644 meta/packages/gdb/gdb-6.3/uclibc.patch create mode 100644 meta/packages/gdb/gdb-cross_6.3.bb create mode 100644 meta/packages/gdb/gdb_6.3.bb create mode 100644 meta/packages/gdbm/gdbm-1.8.3/libtool-mode.patch create mode 100644 meta/packages/gdbm/gdbm-1.8.3/makefile.patch create mode 100644 meta/packages/gdbm/gdbm-native-1.8.3/makefile.patch create mode 100644 meta/packages/gdbm/gdbm-native_1.8.3.bb create mode 100644 meta/packages/gdbm/gdbm_1.8.3.bb create mode 100644 meta/packages/genext2fs/genext2fs-1.3/autosize.patch create mode 100644 meta/packages/genext2fs/genext2fs-1.3/misc.patch create mode 100644 meta/packages/genext2fs/genext2fs-native_1.3.bb create mode 100644 meta/packages/genext2fs/genext2fs.inc create mode 100644 meta/packages/genext2fs/genext2fs_1.3.bb create mode 100644 meta/packages/gettext/gettext-0.14.1/fixchicken.patch create mode 100644 meta/packages/gettext/gettext-0.14.1/gettext-vpath.patch create mode 100644 meta/packages/gettext/gettext-native_0.14.1.bb create mode 100644 meta/packages/gettext/gettext_0.14.1.bb create mode 100644 meta/packages/glib-2.0/files/atomic_fix.patch create mode 100644 meta/packages/glib-2.0/files/glib-gettextize-dir.patch create mode 100644 meta/packages/glib-2.0/files/glibconfig-sysdefs.h create mode 100644 meta/packages/glib-2.0/files/glibinclude.patch create mode 100644 meta/packages/glib-2.0/glib-2.0-native-2.10.3/glib-gettextize-dir.patch create mode 100644 meta/packages/glib-2.0/glib-2.0-native_2.10.3.bb create mode 100644 meta/packages/glib-2.0/glib-2.0-native_2.12.0.bb create mode 100644 meta/packages/glib-2.0/glib-2.0-native_2.6.5.bb create mode 100644 meta/packages/glib-2.0/glib-2.0_2.10.3.bb create mode 100644 meta/packages/glib-2.0/glib-2.0_2.12.0.bb create mode 100644 meta/packages/glib-2.0/glib-2.0_2.6.4.bb create mode 100644 meta/packages/glib-2.0/glib-2.0_2.8.6.bb create mode 100644 meta/packages/glibc/files/5090_all_stubs-rule-fix.patch create mode 100644 meta/packages/glibc/files/etc/ld.so.conf create mode 100644 meta/packages/glibc/files/fhs-linux-paths.patch create mode 100644 meta/packages/glibc/files/generate-supported.mk create mode 100644 meta/packages/glibc/glibc-2.4/arm-longlong.patch create mode 100644 meta/packages/glibc/glibc-2.4/arm-memcpy.patch create mode 100644 meta/packages/glibc/glibc-2.4/dl-cache-libcmp.patch create mode 100644 meta/packages/glibc/glibc-2.4/dyn-ldconfig-20041128.patch create mode 100644 meta/packages/glibc/glibc-2.4/dyn-ldconfig.patch create mode 100644 meta/packages/glibc/glibc-2.4/etc/ld.so.conf create mode 100644 meta/packages/glibc/glibc-2.4/fixup-aeabi-syscalls.patch create mode 100644 meta/packages/glibc/glibc-2.4/generic-bits_select.h create mode 100644 meta/packages/glibc/glibc-2.4/generic-bits_time.h create mode 100644 meta/packages/glibc/glibc-2.4/generic-bits_types.h create mode 100644 meta/packages/glibc/glibc-2.4/generic-bits_typesizes.h create mode 100644 meta/packages/glibc/glibc-2.4/glibc-2.4-compile.patch create mode 100644 meta/packages/glibc/glibc-2.4/ldsocache-varrun.patch create mode 100644 meta/packages/glibc/glibc-2.4/nptl-crosscompile.patch create mode 100644 meta/packages/glibc/glibc-cvs-2.3.5/arm-audit.patch create mode 100644 meta/packages/glibc/glibc-cvs-2.3.5/arm-audit2.patch create mode 100644 meta/packages/glibc/glibc-cvs-2.3.5/arm-longlong.patch create mode 100644 meta/packages/glibc/glibc-cvs-2.3.5/arm-memcpy.patch create mode 100644 meta/packages/glibc/glibc-cvs-2.3.5/arm-no-hwcap.patch create mode 100644 meta/packages/glibc/glibc-cvs-2.3.5/dl-cache-libcmp.patch create mode 100644 meta/packages/glibc/glibc-cvs-2.3.5/dyn-ldconfig-20041128.patch create mode 100644 meta/packages/glibc/glibc-cvs-2.3.5/ldsocache-varrun.patch create mode 100644 meta/packages/glibc/glibc-cvs/arm-ioperm.patch create mode 100644 meta/packages/glibc/glibc-cvs/arm-longlong.patch create mode 100644 meta/packages/glibc/glibc-cvs/arm-machine-gmon.patch create mode 100644 meta/packages/glibc/glibc-cvs/arm-memcpy.patch create mode 100644 meta/packages/glibc/glibc-cvs/arm-no-hwcap.patch create mode 100644 meta/packages/glibc/glibc-cvs/dyn-ldconfig-20041128.patch create mode 100644 meta/packages/glibc/glibc-cvs/dyn-ldconfig.patch create mode 100644 meta/packages/glibc/glibc-cvs/eabi-patch-1 create mode 100644 meta/packages/glibc/glibc-cvs/eabi-patch-2 create mode 100644 meta/packages/glibc/glibc-cvs/eabi-patch-3 create mode 100644 meta/packages/glibc/glibc-cvs/eabi-patch-4 create mode 100644 meta/packages/glibc/glibc-cvs/etc/ld.so.conf create mode 100644 meta/packages/glibc/glibc-cvs/glibc-fp-byteorder.patch create mode 100644 meta/packages/glibc/glibc-cvs/ldconfig.patch create mode 100644 meta/packages/glibc/glibc-cvs/ldd.patch create mode 100644 meta/packages/glibc/glibc-cvs/ldsocache-varrun.patch create mode 100644 meta/packages/glibc/glibc-cvs/makeconfig.patch create mode 100644 meta/packages/glibc/glibc-cvs/mips-no-throw.patch create mode 100644 meta/packages/glibc/glibc-cvs/noinfo.patch create mode 100644 meta/packages/glibc/glibc-cvs/trampoline.patch create mode 100644 meta/packages/glibc/glibc-initial_2.4.bb create mode 100644 meta/packages/glibc/glibc-intermediate_2.4.bb create mode 100644 meta/packages/glibc/glibc-package.bbclass create mode 100644 meta/packages/glibc/glibc_2.3.5+cvs20050627.bb create mode 100644 meta/packages/glibc/glibc_2.4.bb create mode 100644 meta/packages/gmp/gmp-4.1.2/amd64.patch create mode 100644 meta/packages/gmp/gmp-4.1.2/configure.patch create mode 100644 meta/packages/gmp/gmp-4.1.2/gcc-compile.patch create mode 100644 meta/packages/gmp/gmp-4.1.4/amd64.patch create mode 100644 meta/packages/gmp/gmp-4.1.4/configure.patch create mode 100644 meta/packages/gmp/gmp-4.1.4/sh4-asmfix.patch create mode 100644 meta/packages/gmp/gmp-native_4.1.2.bb create mode 100644 meta/packages/gmp/gmp_4.1.2.bb create mode 100644 meta/packages/gmp/gmp_4.1.4.bb create mode 100644 meta/packages/gnome/files/gtk-doc.m4 create mode 100644 meta/packages/gnome/files/gtk-doc.make create mode 100644 meta/packages/gnome/gconf-2.6.1/backends.patch create mode 100755 meta/packages/gnome/gconf-dbus/69gconfd-dbus create mode 100755 meta/packages/gnome/gconf-dbus/gconf-dbus-update.patch create mode 100644 meta/packages/gnome/gconf-dbus/no-deprecation.patch create mode 100644 meta/packages/gnome/gconf-dbus/remove-old-translations.patch create mode 100644 meta/packages/gnome/gconf-dbus/xml-backend-locks-compile-fix.patch create mode 100644 meta/packages/gnome/gconf-dbus/xml-backend-oldxml-Makefile.patch create mode 100755 meta/packages/gnome/gconf-dbus_cvs.bb create mode 100644 meta/packages/gnome/gconf-dbus_svn.bb create mode 100644 meta/packages/gnome/gconf_2.6.1.bb create mode 100644 meta/packages/gnome/gnome-common/omf.patch create mode 100644 meta/packages/gnome/gnome-common_2.4.0.bb create mode 100644 meta/packages/gnome/gnome-mime-data_2.4.2.bb create mode 100644 meta/packages/gnome/gnome-vfs-dbus/gconftool-lossage.patch create mode 100644 meta/packages/gnome/gnome-vfs-dbus/gssapi.patch create mode 100644 meta/packages/gnome/gnome-vfs-dbus/no-gtk-doc.patch create mode 100644 meta/packages/gnome/gnome-vfs-dbus/remove-old-translations.patch create mode 100644 meta/packages/gnome/gnome-vfs-dbus_2.8.4.4.bb create mode 100755 meta/packages/gnome/gnome-vfs-dbus_cvs.bb create mode 100644 meta/packages/gnome/libart-lgpl/Makefile.am.patch create mode 100644 meta/packages/gnome/libart-lgpl/arm/art_config.h create mode 100644 meta/packages/gnome/libart-lgpl/i386/art_config.h create mode 100644 meta/packages/gnome/libart-lgpl/i586/art_config.h create mode 100644 meta/packages/gnome/libart-lgpl/i686/art_config.h create mode 100644 meta/packages/gnome/libart-lgpl_2.3.16.bb create mode 100644 meta/packages/gnome/libgnomecanvas_2.6.1.1.bb create mode 100644 meta/packages/gnome/libsoup_2.2.7.bb create mode 100644 meta/packages/gnome/orbit2-2.10.2/configure-lossage.patch create mode 100644 meta/packages/gnome/orbit2-native_2.10.2.bb create mode 100644 meta/packages/gnome/orbit2_2.10.2.bb create mode 100644 meta/packages/gnu-config/gnu-config-native_20050701.bb create mode 100644 meta/packages/gnu-config/gnu-config/config-guess-uclibc.patch create mode 100755 meta/packages/gnu-config/gnu-config/gnu-configize.in create mode 100644 meta/packages/gnu-config/gnu-config/uclibc.patch create mode 100644 meta/packages/gnu-config/gnu-config_20050701.bb create mode 100644 meta/packages/gnutls/gnutls-1.0.25/export-symbols.patch create mode 100644 meta/packages/gnutls/gnutls-1.0.25/gnutls-openssl.patch create mode 100644 meta/packages/gnutls/gnutls_1.0.25.bb create mode 100644 meta/packages/gtk+/files/migration.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/automake-lossage.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/cellrenderer-cairo.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/disable-tooltips.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/entry-cairo.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/gtk+-handhelds.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/gtkbuiltincache.h create mode 100644 meta/packages/gtk+/gtk+-2.10.0/gtklabel-resize-patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/gtktreeview-316689.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/hardcoded_libtool.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/menu-deactivate.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/no-demos.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/no-generate-builtincache.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/no-xwc.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/scroll-timings.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/single-click.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/small-gtkfilesel.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/spinbutton.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/style-cairo.patch create mode 100644 meta/packages/gtk+/gtk+-2.10.0/xsettings.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.0.6-exportsymbols.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/000_gtk+-2.2.0-buildfix-immodule.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/002_xpmico.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/003_iconcache.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/automake-lossage.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/configure.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/configure.in.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/disable-tooltips.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gdkwindow-x11.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtk+-handhelds.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtk.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.am.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtk_Makefile.in.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkalias.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkbutton.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcalendar.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertext.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellrenderertoggle.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcellview.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcheckbutton.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcombobox.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcomboboxentry.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkcontainer.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdialog.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkdnd.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkentry.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkenums.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkfilesystem.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkframe.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhashtable.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhbbox.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkhseparator.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkiconfactory.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkicontheme.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimcontext.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkimmulticontext.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel-resize-patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtklabel.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmain.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshal.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmarshalers.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenu.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenuitem.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkmenushell.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtknotebook.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogress.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkprogressbar.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkradiobutton.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkrange.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkrange.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkrbtree.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkrc.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkrc.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkscrolledwindow.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkseparator.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkseparatortoolitem.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtksettings.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkspinbutton.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkstyle.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkstyle.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktable.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktextbuffer.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktextbuffer.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktextbufferserialize.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktextbufferserialize.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktextview.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktoolbar.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktoolbutton.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktoolbutton.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktreemodelfilter.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktreemodelsort.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeprivate.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeselection.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeview.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeview.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktreeviewcolumn.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktypebuiltins.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtktypebuiltins.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkvseparator.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkwidget.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkwidget.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkwindow.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/gtkwindow.h.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/hardcoded_libtool.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/io-gif-animation.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/io-gif.c.diff create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/menu-deactivate.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/no-demos.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/no-xwc.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/scroll-timings.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/single-click.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/small-gtkfilesel.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/spinbutton.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.4-1.osso7/xsettings.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/automake-lossage.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/disable-tooltips.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/gtk+-handhelds.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/gtklabel-center.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/gtklabel-resize-patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/hardcoded_libtool.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/menu-deactivate.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/no-demos.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/no-xwc.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/scroll-timings.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/single-click.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/small-gtkfilesel.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.7/spinbutton.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/automake-lossage.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/disable-tooltips.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/gtk+-handhelds.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/gtklabel-resize-patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/hardcoded_libtool.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/menu-deactivate.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/no-demos.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/no-deprecation.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/no-xwc.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/scroll-timings.patch create mode 100644 meta/packages/gtk+/gtk+-2.6.8/spinbutton.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/automake-lossage.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/disable-tooltips.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/gtk+-handhelds.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/gtklabel-resize-patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/gtktreeview-316689.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/hardcoded_libtool.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/menu-deactivate.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/no-demos.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/no-xwc.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/scroll-timings.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/single-click.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/small-gtkfilesel.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/spinbutton.patch create mode 100644 meta/packages/gtk+/gtk+-2.8.16/xsettings.patch create mode 100644 meta/packages/gtk+/gtk+_2.10.0.bb create mode 100644 meta/packages/gtk+/gtk+_2.6.4-1.osso7.bb create mode 100644 meta/packages/gtk+/gtk+_2.6.7.bb create mode 100644 meta/packages/gtk+/gtk+_2.6.8.bb create mode 100644 meta/packages/gtk+/gtk+_2.8.16.bb create mode 100644 meta/packages/gtk-doc/gtk-doc-native.bb create mode 100644 meta/packages/gtk-doc/gtk-doc.bb create mode 100644 meta/packages/gtk-doc/gtk-doc.m4 create mode 100644 meta/packages/gtk-engines/gtk-clearlooks-engine_0.6.2.bb create mode 100644 meta/packages/gtk-engines/gtk-engines_2.7.1.bb create mode 100755 meta/packages/gtkhtml2/gtkhtml2_cvs.bb create mode 100644 meta/packages/hal/hal_0.5.4.bb create mode 100644 meta/packages/hdparm/hdparm-6.3/bswap.patch create mode 100644 meta/packages/hdparm/hdparm-6.3/uclibc.patch create mode 100644 meta/packages/hdparm/hdparm_6.3.bb create mode 100644 meta/packages/hostap/files/hostap-fw-load.patch create mode 100644 meta/packages/hostap/files/hostap_cs.conf create mode 100644 meta/packages/hostap/files/hostap_cs.conf-upstream create mode 100644 meta/packages/hostap/hostap-conf_1.0.bb create mode 100644 meta/packages/hostap/hostap-modules.inc create mode 100644 meta/packages/hostap/hostap-modules/Makefile.patch create mode 100644 meta/packages/hostap/hostap-modules/add_event.patch create mode 100644 meta/packages/hostap/hostap-modules/hostap-utsname.patch create mode 100644 meta/packages/hostap/hostap-modules/hostap_cardid.patch create mode 100644 meta/packages/hostap/hostap-modules/ipaq_compat.patch create mode 100644 meta/packages/hostap/hostap-modules/kernel_updates.patch create mode 100644 meta/packages/hostap/hostap-modules/mtx_compat.diff create mode 100644 meta/packages/hostap/hostap-modules/mtx_hostap_deferred_irq.diff create mode 100644 meta/packages/hostap/hostap-modules_0.3.9.bb create mode 100644 meta/packages/hostap/hostap-utils.inc create mode 100644 meta/packages/hostap/hostap-utils_0.3.7.bb create mode 100644 meta/packages/hostap/hostap-utils_0.4.0.bb create mode 100755 meta/packages/initscripts/initscripts-1.0/akita/devices create mode 100644 meta/packages/initscripts/initscripts-1.0/arm/alignment.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/banner create mode 100755 meta/packages/initscripts/initscripts-1.0/bootmisc.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/c7x0/devices create mode 100755 meta/packages/initscripts/initscripts-1.0/checkfs.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/checkroot.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/collie/devices create mode 100644 meta/packages/initscripts/initscripts-1.0/device_table.txt create mode 100755 meta/packages/initscripts/initscripts-1.0/devices create mode 100644 meta/packages/initscripts/initscripts-1.0/devpts create mode 100755 meta/packages/initscripts/initscripts-1.0/devpts.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/finish create mode 100755 meta/packages/initscripts/initscripts-1.0/h3600/devices create mode 100755 meta/packages/initscripts/initscripts-1.0/h3900/devices create mode 100755 meta/packages/initscripts/initscripts-1.0/halt create mode 100755 meta/packages/initscripts/initscripts-1.0/hostname.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/jornada56x/devices create mode 100644 meta/packages/initscripts/initscripts-1.0/jornada6xx/devices create mode 100755 meta/packages/initscripts/initscripts-1.0/jornada7xx/devices create mode 100755 meta/packages/initscripts/initscripts-1.0/mountall.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/mountnfs.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/openmn/extractfs create mode 100755 meta/packages/initscripts/initscripts-1.0/openmn/packages create mode 100755 meta/packages/initscripts/initscripts-1.0/openmn/umountfs create mode 100755 meta/packages/initscripts/initscripts-1.0/openzaurus/checkversion create mode 100755 meta/packages/initscripts/initscripts-1.0/poodle/devices create mode 100755 meta/packages/initscripts/initscripts-1.0/populate-volatile.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/ramdisk create mode 100755 meta/packages/initscripts/initscripts-1.0/reboot create mode 100755 meta/packages/initscripts/initscripts-1.0/rmnologin create mode 100755 meta/packages/initscripts/initscripts-1.0/sendsigs create mode 100644 meta/packages/initscripts/initscripts-1.0/simpad/devices create mode 100755 meta/packages/initscripts/initscripts-1.0/single create mode 100755 meta/packages/initscripts/initscripts-1.0/spitz/devices create mode 100644 meta/packages/initscripts/initscripts-1.0/sysfs.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/tosa/devices create mode 100755 meta/packages/initscripts/initscripts-1.0/uml/devices create mode 100755 meta/packages/initscripts/initscripts-1.0/umountfs create mode 100755 meta/packages/initscripts/initscripts-1.0/umountnfs.sh create mode 100755 meta/packages/initscripts/initscripts-1.0/urandom create mode 100644 meta/packages/initscripts/initscripts-1.0/volatiles create mode 100644 meta/packages/initscripts/initscripts_1.0.bb create mode 100644 meta/packages/intltool/intltool-native_0.31.bb create mode 100644 meta/packages/intltool/intltool_0.31.bb create mode 100644 meta/packages/ipkg-utils/ipkg-link/link-vfat-libs.patch create mode 100644 meta/packages/ipkg-utils/ipkg-link_1.6+cvs20050404.bb create mode 100644 meta/packages/ipkg-utils/ipkg-utils-native/ipkg-utils-fix.patch create mode 100644 meta/packages/ipkg-utils/ipkg-utils-native_1.6+cvs20050404.bb create mode 100644 meta/packages/ipkg-utils/ipkg-utils_1.6+cvs20050404.bb create mode 100644 meta/packages/ipkg/files/terse.patch create mode 100644 meta/packages/ipkg/files/uclibc.patch create mode 100644 meta/packages/ipkg/files/uninclude-replace.patch create mode 100644 meta/packages/ipkg/ipkg-collateral.bb create mode 100644 meta/packages/ipkg/ipkg-collateral/akita/dest create mode 100644 meta/packages/ipkg/ipkg-collateral/akita/lists create mode 100644 meta/packages/ipkg/ipkg-collateral/collie/dest create mode 100644 meta/packages/ipkg/ipkg-collateral/dest create mode 100644 meta/packages/ipkg/ipkg-collateral/ipkg.conf.comments create mode 100644 meta/packages/ipkg/ipkg-collateral/jornada56x/dest create mode 100644 meta/packages/ipkg/ipkg-collateral/lists create mode 100644 meta/packages/ipkg/ipkg-collateral/openmn/src create mode 100644 meta/packages/ipkg/ipkg-collateral/poodle/dest create mode 100644 meta/packages/ipkg/ipkg-collateral/simpad/dest create mode 100644 meta/packages/ipkg/ipkg-collateral/src create mode 100644 meta/packages/ipkg/ipkg-collateral/tosa/dest create mode 100644 meta/packages/ipkg/ipkg-native.inc create mode 100644 meta/packages/ipkg/ipkg-native_0.99.154.bb create mode 100644 meta/packages/ipkg/ipkg.inc create mode 100644 meta/packages/ipkg/ipkg_0.99.154.bb create mode 100755 meta/packages/irda-utils/files/init create mode 100644 meta/packages/irda-utils/irda-utils/configure.patch create mode 100644 meta/packages/irda-utils/irda-utils/m4.patch create mode 100644 meta/packages/irda-utils/irda-utils_0.9.16.bb create mode 100644 meta/packages/jpeg/jpeg-6b/debian.patch create mode 100644 meta/packages/jpeg/jpeg-6b/ldflags.patch create mode 100644 meta/packages/jpeg/jpeg-6b/paths.patch create mode 100644 meta/packages/jpeg/jpeg-native_6b.bb create mode 100644 meta/packages/jpeg/jpeg_6b.bb create mode 100644 meta/packages/js/files/host-cc.patch create mode 100644 meta/packages/js/files/jsautocfg.h create mode 100644 meta/packages/js/js_1.5.bb create mode 100644 meta/packages/keymaps/files/akita/keymap-2.4.map create mode 100644 meta/packages/keymaps/files/akita/keymap-2.6.map create mode 100755 meta/packages/keymaps/files/c7x0/keymap-2.6.map create mode 100644 meta/packages/keymaps/files/collie/keymap-2.4.map create mode 100644 meta/packages/keymaps/files/collie/keymap-2.6.map create mode 100755 meta/packages/keymaps/files/keymap create mode 100644 meta/packages/keymaps/files/poodle/keymap-2.6.map create mode 100644 meta/packages/keymaps/files/spitz/keymap-2.4.map create mode 100644 meta/packages/keymaps/files/spitz/keymap-2.6.map create mode 100644 meta/packages/keymaps/files/tosa/keymap-2.4.map create mode 100644 meta/packages/keymaps/files/tosa/keymap-2.6.map create mode 100644 meta/packages/keymaps/keymaps_1.0.bb create mode 100644 meta/packages/kf/files/fix-configure.patch create mode 100644 meta/packages/kf/files/fix-desktop-file.patch create mode 100755 meta/packages/kf/kf_0.5.4.1.bb create mode 100644 meta/packages/leafpad/files/leafpad.desktop create mode 100644 meta/packages/leafpad/files/leafpad.png create mode 100644 meta/packages/leafpad/leafpad_0.8.4.bb create mode 100644 meta/packages/leafpad/leafpad_0.8.9.bb create mode 100644 meta/packages/less/less-382/configure.patch create mode 100644 meta/packages/less/less_382.bb create mode 100644 meta/packages/libdaemon/libdaemon_0.10.bb create mode 100644 meta/packages/libfakekey/libfakekey_svn.bb create mode 100644 meta/packages/libgcrypt/libgcrypt_1.2.1.bb create mode 100644 meta/packages/libglade/libglade-2.5.1/glade-cruft.patch create mode 100644 meta/packages/libglade/libglade-2.5.1/no-deprecation.patch create mode 100644 meta/packages/libglade/libglade-2.5.1/no-xml2.patch create mode 100644 meta/packages/libglade/libglade_2.5.1.bb create mode 100644 meta/packages/libgpg-error/libgpg-error-1.0/pkgconfig.patch create mode 100644 meta/packages/libgpg-error/libgpg-error_1.0.bb create mode 100644 meta/packages/libgtkstylus/files/gtkstylus.sh create mode 100644 meta/packages/libgtkstylus/libgtkstylus_0.5.bb create mode 100644 meta/packages/libiconv/libiconv_1.9.2.bb create mode 100644 meta/packages/libidl/libidl-native_0.8.3.bb create mode 100644 meta/packages/libidl/libidl_0.8.3.bb create mode 100644 meta/packages/libmatchbox/files/16bppfixes.patch create mode 100644 meta/packages/libmatchbox/files/autofoo.patch create mode 100644 meta/packages/libmatchbox/files/check.m4 create mode 100644 meta/packages/libmatchbox/files/fix-configure-for-1.9.patch create mode 100644 meta/packages/libmatchbox/libmatchbox.inc create mode 100644 meta/packages/libmatchbox/libmatchbox_1.7.bb create mode 100644 meta/packages/libmatchbox/libmatchbox_svn.bb create mode 100644 meta/packages/libnss-mdns/files/alignment-fix.patch create mode 100644 meta/packages/libnss-mdns/libnss-mdns_0.7.bb create mode 100644 meta/packages/libpcap/libpcap-0.9.3/shared.patch create mode 100644 meta/packages/libpcap/libpcap_0.9.3.bb create mode 100644 meta/packages/libpng/libpng-native_1.2.8.bb create mode 100644 meta/packages/libpng/libpng_1.2.8.bb create mode 100644 meta/packages/libtool/libtool-1.5.10/3figures.patch create mode 100644 meta/packages/libtool/libtool-1.5.10/autotools.patch create mode 100644 meta/packages/libtool/libtool-1.5.10/install-path-check.patch create mode 100644 meta/packages/libtool/libtool-1.5.10/libdir-la.patch create mode 100644 meta/packages/libtool/libtool-1.5.10/prefix.patch create mode 100644 meta/packages/libtool/libtool-1.5.10/sedvar.patch create mode 100644 meta/packages/libtool/libtool-1.5.10/tag.patch create mode 100644 meta/packages/libtool/libtool-1.5.10/tag1.patch create mode 100644 meta/packages/libtool/libtool-1.5.10/uclibc.patch create mode 100644 meta/packages/libtool/libtool-cross_1.5.10.bb create mode 100644 meta/packages/libtool/libtool-native_1.5.10.bb create mode 100644 meta/packages/libtool/libtool_1.5.10.bb create mode 100644 meta/packages/libusb/libusb-0.1.10a/ARMfix.patch create mode 100644 meta/packages/libusb/libusb-0.1.10a/debian-changes.patch create mode 100644 meta/packages/libusb/libusb_0.1.10a.bb create mode 100644 meta/packages/libxml/files/no-testapi.patch create mode 100644 meta/packages/libxml/libxml2_2.6.10.bb create mode 100644 meta/packages/libxml/libxml2_2.6.22.bb create mode 100644 meta/packages/libxml/libxml2_cvs.bb create mode 100644 meta/packages/libxsettings-client/libxsettings-client_0.14.bb create mode 100644 meta/packages/libxsettings-client/make_pkgconfig_x11.patch create mode 100644 meta/packages/libxsettings/libxsettings_0.11.bb create mode 100644 meta/packages/linux-hotplug/files/collie/usbd create mode 100755 meta/packages/linux-hotplug/files/mmc.agent create mode 100755 meta/packages/linux-hotplug/files/sleeve.agent create mode 100755 meta/packages/linux-hotplug/files/sleeve.rc create mode 100644 meta/packages/linux-hotplug/files/soc.agent create mode 100644 meta/packages/linux-hotplug/files/sysconfig-hotplug create mode 100644 meta/packages/linux-hotplug/files/sysconfig-usb create mode 100644 meta/packages/linux-hotplug/files/tosa/sysconfig-usb create mode 100644 meta/packages/linux-hotplug/files/usbd create mode 100755 meta/packages/linux-hotplug/files/usbd.agent create mode 100644 meta/packages/linux-hotplug/linux-hotplug-20040920/fix-net.agent create mode 100644 meta/packages/linux-hotplug/linux-hotplug-20040920/hotplug-net-agent-usb.patch create mode 100644 meta/packages/linux-hotplug/linux-hotplug-20040920/isapnp-exit.diff create mode 100644 meta/packages/linux-hotplug/linux-hotplug-20040920/logcheck-ignore create mode 100755 meta/packages/linux-hotplug/linux-hotplug-20040920/update-usb.usermap create mode 100644 meta/packages/linux-hotplug/linux-hotplug-20040920/usb-storage create mode 100644 meta/packages/linux-hotplug/linux-hotplug-20040920/usbrc-busybox.patch create mode 100644 meta/packages/linux-hotplug/linux-hotplug-20040920/userspecified_hcd.patch create mode 100644 meta/packages/linux-hotplug/linux-hotplug_20040920.bb create mode 100644 meta/packages/linux-libc-headers/files/keyboard.patch create mode 100644 meta/packages/linux-libc-headers/linux-libc-headers-2.6.15.99/3477-1.patch create mode 100644 meta/packages/linux-libc-headers/linux-libc-headers-2.6.15.99/asm-arch-irqs.patch create mode 100644 meta/packages/linux-libc-headers/linux-libc-headers-2.6.15.99/linux-netdevice.patch create mode 100644 meta/packages/linux-libc-headers/linux-libc-headers-2.6.15.99/linux-netfilter_ipv4.patch create mode 100644 meta/packages/linux-libc-headers/linux-libc-headers-2.6.15.99/linux-rtc.patch create mode 100644 meta/packages/linux-libc-headers/linux-libc-headers-2.6.15.99/linux-videodev2.patch create mode 100644 meta/packages/linux-libc-headers/linux-libc-headers_2.6.11.1.bb create mode 100644 meta/packages/linux-libc-headers/linux-libc-headers_2.6.15.99.bb create mode 100644 meta/packages/linux/linux-cmx270-2.6.17/add_2700g_plat-r0.patch create mode 100644 meta/packages/linux/linux-cmx270-2.6.17/cm_x2xx_mbx.patch create mode 100644 meta/packages/linux/linux-cmx270-2.6.17/defconfig create mode 100644 meta/packages/linux/linux-cmx270-2.6.17/mach-types create mode 100644 meta/packages/linux/linux-cmx270-2.6.17/mtd_fixes-r0.patch create mode 100644 meta/packages/linux/linux-cmx270-2.6.17/mtd_fixes1-r0.patch create mode 100644 meta/packages/linux/linux-cmx270-rp-2.6.17/defconfig create mode 100644 meta/packages/linux/linux-cmx270-rp-2.6.17/mach-types create mode 100644 meta/packages/linux/linux-cmx270-rp_2.6.17.bb create mode 100644 meta/packages/linux/linux-cmx270_2.6.17.bb create mode 100644 meta/packages/linux/linux-nokia770-2.6.12.3-osso14/nokia770/defconfig create mode 100644 meta/packages/linux/linux-nokia770_2.6.12.3-osso14.bb create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/00-hostap.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/10-pcnet.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/add-oz-release-string.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/connectplus-remove-ide-HACK.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/defconfig-akita create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/defconfig-c7x0 create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/defconfig-collie create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/defconfig-ipaq-pxa270 create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/defconfig-poodle create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/defconfig-qemuarm create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/defconfig-spitz create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/defconfig-tosa create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/hrw-pcmcia-ids-r2.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/locomo-kbd-hotkeys.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/locomo-lcd-def-bightness.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/locomo-sysrq+keyrepeat.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/pxa-serial-hack.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/rmk-mmc1.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/rmk-mmc2.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/serial-add-support-for-non-standard-xtals-to-16c950-driver.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.16/squashfs3.0-2.6.15.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/00-hostap.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/10-pcnet.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/add-oz-release-string.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/connectplus-remove-ide-HACK.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/defconfig-akita create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/defconfig-c7x0 create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/defconfig-collie create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/defconfig-ipaq-pxa270 create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/defconfig-poodle create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/defconfig-qemuarm create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/defconfig-spitz create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/defconfig-tosa create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/hrw-pcmcia-ids-r2.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/pxa-serial-hack.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/serial-add-support-for-non-standard-xtals-to-16c950-driver.patch create mode 100644 meta/packages/linux/linux-openzaurus-2.6.17/squashfs3.0-2.6.15.patch create mode 100644 meta/packages/linux/linux-openzaurus.inc create mode 100644 meta/packages/linux/linux-openzaurus_2.6.16.bb create mode 100644 meta/packages/linux/linux-openzaurus_2.6.17.bb create mode 100644 meta/packages/lirc/files/lirc_sir-sa1100.patch create mode 100644 meta/packages/lirc/files/lircd.conf_nslu2 create mode 100755 meta/packages/lirc/files/lircd.init create mode 100755 meta/packages/lirc/files/lircexec.init create mode 100755 meta/packages/lirc/files/lircmd.init create mode 100644 meta/packages/lirc/files/lircrc_nslu2 create mode 100644 meta/packages/lirc/files/split-hauppauge.patch create mode 100644 meta/packages/lirc/lirc-config.inc create mode 100644 meta/packages/lirc/lirc-modules_0.7.1.bb create mode 100644 meta/packages/lirc/lirc_0.7.1.bb create mode 100755 meta/packages/loudmouth/loudmouth_1.0.1.bb create mode 100644 meta/packages/lrzsz/lrzsz-0.12.20/autotools.patch create mode 100644 meta/packages/lrzsz/lrzsz-0.12.20/gettext.patch create mode 100644 meta/packages/lrzsz/lrzsz-0.12.20/makefile.patch create mode 100644 meta/packages/lrzsz/lrzsz_0.12.20.bb create mode 100644 meta/packages/lsof/lsof_4.75.bb create mode 100644 meta/packages/lttng/lttng-control-0.10/lttctl_sti-r0.patch create mode 100644 meta/packages/lttng/lttng-control-0.6/lttctl_sti-r0.patch create mode 100644 meta/packages/lttng/lttng-control_0.10.bb create mode 100644 meta/packages/lttng/lttng-control_0.6.bb create mode 100644 meta/packages/lttng/lttng-viewer_0.8.41-20060512.bb create mode 100644 meta/packages/m4/m4-native_1.4.2.bb create mode 100644 meta/packages/m4/m4/make.patch create mode 100644 meta/packages/m4/m4_1.4.2.bb create mode 100644 meta/packages/maemo/nokia770-init/fixup-770.sh create mode 100644 meta/packages/maemo/nokia770-init_1.0.bb create mode 100644 meta/packages/maemo/xpext/auxdir.patch create mode 100644 meta/packages/maemo/xpext_1.0-5.bb create mode 100644 meta/packages/maemo/xsp_1.0.0-8.bb create mode 100644 meta/packages/make/make-3.80/SCCS.patch create mode 100644 meta/packages/make/make_3.80.bb create mode 100644 meta/packages/makedevs/makedevs-1.0.0/makedevs.c create mode 100644 meta/packages/makedevs/makedevs-native_1.0.0.bb create mode 100644 meta/packages/makedevs/makedevs_1.0.0.bb create mode 100644 meta/packages/matchbox-applet-inputmanager/matchbox-applet-inputmanager_0.6.bb create mode 100644 meta/packages/matchbox-applet-startup-monitor/matchbox-applet-startup-monitor_0.1.bb create mode 100644 meta/packages/matchbox-applet-volume/matchbox-applet-volume_0.1.bb create mode 100644 meta/packages/matchbox-common/matchbox-common_0.9.1.bb create mode 100644 meta/packages/matchbox-common/matchbox-common_svn.bb create mode 100644 meta/packages/matchbox-common/matchbox_0.9.1.bb create mode 100644 meta/packages/matchbox-config-gtk/matchbox-config-gtk_svn.bb create mode 100644 meta/packages/matchbox-desktop/matchbox-desktop_0.9.1.bb create mode 100644 meta/packages/matchbox-desktop/matchbox-desktop_svn.bb create mode 100644 meta/packages/matchbox-keyboard/matchbox-keyboard_svn.bb create mode 100644 meta/packages/matchbox-panel-hacks/matchbox-panel-hacks-0.3-1/home-panelapp.desktop create mode 100755 meta/packages/matchbox-panel-hacks/matchbox-panel-hacks-0.3-1/mb-applet-home create mode 100644 meta/packages/matchbox-panel-hacks/matchbox-panel-hacks-0.3-1/xrandr-panelapp.desktop create mode 100755 meta/packages/matchbox-panel-hacks/matchbox-panel-hacks-0.3-1/xrandr-panelapp.sh create mode 100644 meta/packages/matchbox-panel-hacks/matchbox-panel-hacks-0.3-1/xrandr.png create mode 100644 meta/packages/matchbox-panel-hacks/matchbox-panel-hacks_0.3-1.bb create mode 100644 meta/packages/matchbox-panel-manager/matchbox-panel-manager_0.1.bb create mode 100644 meta/packages/matchbox-panel/matchbox-panel.inc create mode 100644 meta/packages/matchbox-panel/matchbox-panel_0.9.2.bb create mode 100644 meta/packages/matchbox-panel/matchbox-panel_svn.bb create mode 100755 meta/packages/matchbox-poky/matchbox-poky/etc/matchbox/session create mode 100644 meta/packages/matchbox-poky/matchbox-poky_0.1.bb create mode 100644 meta/packages/matchbox-stroke/matchbox-stroke_svn.bb create mode 100644 meta/packages/matchbox-themes-extra/matchbox-themes-extra_0.3.bb create mode 100644 meta/packages/matchbox-themes-extra/matchbox-themes-extra_svn.bb create mode 100644 meta/packages/matchbox-themes-gtk/files/gtkrc create mode 100644 meta/packages/matchbox-themes-gtk/matchbox-themes-gtk.bb create mode 100644 meta/packages/matchbox-wm/matchbox-wm/collie/kbdconfig create mode 100644 meta/packages/matchbox-wm/matchbox-wm/kbdconfig create mode 100644 meta/packages/matchbox-wm/matchbox-wm/kbdconfig_keylaunch_simpad.patch create mode 100644 meta/packages/matchbox-wm/matchbox-wm/simpad/kbdconfig create mode 100644 meta/packages/matchbox-wm/matchbox-wm_0.9.5.bb create mode 100644 meta/packages/matchbox-wm/matchbox-wm_svn.bb create mode 100644 meta/packages/meta/bootstrap-image.bb create mode 100644 meta/packages/meta/oh-image-devel.bb create mode 100644 meta/packages/meta/oh-image-minimal.bb create mode 100644 meta/packages/meta/oh-image-sdk.bb create mode 100644 meta/packages/meta/oh-image.bb create mode 100644 meta/packages/meta/package-index.bb create mode 100644 meta/packages/meta/task-oh-sdk.bb create mode 100644 meta/packages/meta/task-oh.bb create mode 100644 meta/packages/misc-binary-only/prism3-firmware_1.8.4.bb create mode 100644 meta/packages/module-init-tools/files/ignore_arch_directory create mode 100644 meta/packages/module-init-tools/files/manpagesopt create mode 100644 meta/packages/module-init-tools/files/modutils_extension create mode 100644 meta/packages/module-init-tools/files/no_man_rebuild create mode 100644 meta/packages/module-init-tools/module-init-tools-cross_3.2.2.bb create mode 100644 meta/packages/module-init-tools/module-init-tools_3.2.2.bb create mode 100644 meta/packages/modutils/files/armeb.patch create mode 100644 meta/packages/modutils/files/configure.patch create mode 100644 meta/packages/modutils/files/gcc4.patch create mode 100644 meta/packages/modutils/files/ipaq-pxa-2.6/modules create mode 100644 meta/packages/modutils/files/ipaq-pxa-2.6/modules.conf create mode 100644 meta/packages/modutils/files/lex.l.diff create mode 100644 meta/packages/modutils/files/mnci/modules create mode 100644 meta/packages/modutils/files/mnci/modules-ramses create mode 100644 meta/packages/modutils/files/mnci/modules.conf create mode 100755 meta/packages/modutils/files/mnci/modutils.sh create mode 100644 meta/packages/modutils/files/modules create mode 100644 meta/packages/modutils/files/modules.conf create mode 100644 meta/packages/modutils/files/modutils-notest.patch create mode 100755 meta/packages/modutils/files/modutils.sh create mode 100644 meta/packages/modutils/files/mtx-1/modules create mode 100644 meta/packages/modutils/files/omap1610h2/modules create mode 100644 meta/packages/modutils/files/omap1610h2/modules.conf create mode 100644 meta/packages/modutils/files/poodle/modules create mode 100644 meta/packages/modutils/files/poodle/modules.conf create mode 100644 meta/packages/modutils/files/program_prefix.patch create mode 100644 meta/packages/modutils/files/tosa/modules create mode 100644 meta/packages/modutils/files/tosa/modules.conf create mode 100644 meta/packages/modutils/files/wrt54/modules create mode 100644 meta/packages/modutils/modutils-collateral.bb create mode 100644 meta/packages/modutils/modutils-cross/module.h.diff create mode 100644 meta/packages/modutils/modutils-cross_2.4.27.bb create mode 100644 meta/packages/modutils/modutils-initscripts.bb create mode 100644 meta/packages/modutils/modutils_2.4.27.bb create mode 100644 meta/packages/mozilla/files/minimo.desktop create mode 100644 meta/packages/mozilla/files/minimo.png create mode 100644 meta/packages/mozilla/files/mozilla-firefox.desktop create mode 100644 meta/packages/mozilla/files/mozilla-firefox.png create mode 100644 meta/packages/mozilla/files/mozilla-thunderbird.desktop create mode 100644 meta/packages/mozilla/files/mozilla-thunderbird.png create mode 100644 meta/packages/mozilla/files/no-xmb.patch create mode 100644 meta/packages/mozilla/files/xptcstubs.patch create mode 100644 meta/packages/mozilla/minimo/host_ldflags_fix.patch create mode 100644 meta/packages/mozilla/minimo/mozconfig create mode 100644 meta/packages/mozilla/minimo_cvs.bb create mode 100644 meta/packages/mozilla/mozilla-cvs.inc create mode 100644 meta/packages/mpfr/mpfr-native_2.1.1.bb create mode 100644 meta/packages/mpfr/mpfr_2.1.1.bb create mode 100644 meta/packages/mtd/mtd-utils-native_20060223.bb create mode 100644 meta/packages/mtd/mtd-utils/add-exclusion-to-mkfs-jffs2-20060131.patch create mode 100644 meta/packages/mtd/mtd-utils/add-exclusion-to-mkfs-jffs2.patch create mode 100644 meta/packages/mtd/mtd-utils/fix-ignoreerrors-20060131.patch create mode 100644 meta/packages/mtd/mtd-utils/fix-ignoreerrors.patch create mode 100644 meta/packages/mtd/mtd-utils/more-verbosity.patch create mode 100644 meta/packages/mtd/mtd-utils_20060223.bb create mode 100644 meta/packages/ncurses/ncurses-native_5.4.bb create mode 100644 meta/packages/ncurses/ncurses.inc create mode 100644 meta/packages/ncurses/ncurses/20030906.patch create mode 100644 meta/packages/ncurses/ncurses/configure.patch create mode 100644 meta/packages/ncurses/ncurses/mk_shared_lib.patch create mode 100644 meta/packages/ncurses/ncurses/run_tic.patch create mode 100644 meta/packages/ncurses/ncurses/tic.patch create mode 100644 meta/packages/ncurses/ncurses/visibility.patch create mode 100644 meta/packages/ncurses/ncurses_5.4.bb create mode 100644 meta/packages/netbase/netbase/busybox.patch create mode 100644 meta/packages/netbase/netbase/colinux/interfaces create mode 100644 meta/packages/netbase/netbase/epia/interfaces create mode 100644 meta/packages/netbase/netbase/hosts create mode 100644 meta/packages/netbase/netbase/init create mode 100644 meta/packages/netbase/netbase/interfaces create mode 100644 meta/packages/netbase/netbase/mtx-1/interfaces create mode 100644 meta/packages/netbase/netbase/openmn/hosts create mode 100644 meta/packages/netbase/netbase/openmn/interfaces create mode 100644 meta/packages/netbase/netbase/options create mode 100644 meta/packages/netbase/netbase/tosa/interfaces create mode 100644 meta/packages/netbase/netbase/wrt54/interfaces create mode 100644 meta/packages/netbase/netbase/xxs1500/interfaces create mode 100644 meta/packages/netbase/netbase_4.21.bb create mode 100644 meta/packages/network-suspend-scripts/files/ifupdown create mode 100644 meta/packages/network-suspend-scripts/files/usbnet create mode 100644 meta/packages/network-suspend-scripts/network-suspend-scripts.bb create mode 100644 meta/packages/oh/usbinit.bb create mode 100755 meta/packages/oh/usbinit/usb-gether create mode 100644 meta/packages/openswan/openswan-2.2.0/gcc4-fixes.patch create mode 100644 meta/packages/openswan/openswan-2.2.0/ld-library-path-breakage.patch create mode 100644 meta/packages/openswan/openswan-2.2.0/makefile-whitespace-fix.patch create mode 100644 meta/packages/openswan/openswan-2.2.0/openswan-2.2.0-gentoo.patch create mode 100644 meta/packages/openswan/openswan_2.2.0.bb create mode 100644 meta/packages/opensync/libopensync-plugin-evolution2-0.17/fix-warnings.patch create mode 100644 meta/packages/opensync/libopensync-plugin-evolution2_0.17.bb create mode 100644 meta/packages/opensync/libopensync-plugin-file_0.17.bb create mode 100644 meta/packages/opensync/libopensync_0.17.bb create mode 100644 meta/packages/opensync/multisync_0.90.17.bb create mode 100644 meta/packages/oprofile/oprofile-0.9.1/acinclude.m4 create mode 100644 meta/packages/oprofile/oprofile-0.9.1/no_arm_mapping_syms.patch create mode 100644 meta/packages/oprofile/oprofile/acinclude.m4 create mode 100644 meta/packages/oprofile/oprofile/no_arm_mapping_syms.patch create mode 100644 meta/packages/oprofile/oprofile_0.9.1.bb create mode 100644 meta/packages/oprofile/oprofile_cvs.bb create mode 100644 meta/packages/orinoco/files/hermes.conf create mode 100644 meta/packages/orinoco/files/orinoco_cs.conf create mode 100644 meta/packages/orinoco/files/spectrum.conf create mode 100644 meta/packages/orinoco/files/spectrum_fw.h create mode 100644 meta/packages/orinoco/orinoco-conf_1.0.bb create mode 100644 meta/packages/orinoco/orinoco-modules-0.15rc2/add_event.patch create mode 100644 meta/packages/orinoco/orinoco-modules-0.15rc2/add_utsname.patch create mode 100644 meta/packages/orinoco/orinoco-modules-0.15rc2/catch-up-with-kernel-changes.patch create mode 100644 meta/packages/orinoco/orinoco-modules-0.15rc2/list-move.patch create mode 100644 meta/packages/orinoco/orinoco-modules-0.15rc2/makefile_fix.patch create mode 100644 meta/packages/orinoco/orinoco-modules-0.15rc2/spectrum_cs_ids.patch create mode 100644 meta/packages/orinoco/orinoco-modules_0.15rc2.bb create mode 100644 meta/packages/orinoco/spectrum-fw.bb create mode 100755 meta/packages/orinoco/spectrum-fw/get_symbol_fw create mode 100755 meta/packages/orinoco/spectrum-fw/parse_symbol_fw create mode 100644 meta/packages/pango/files/gtk-doc.patch create mode 100644 meta/packages/pango/files/no-tests.patch create mode 100644 meta/packages/pango/pango_1.10.0.bb create mode 100644 meta/packages/pango/pango_1.12.0.bb create mode 100644 meta/packages/pango/pango_1.13.3.bb create mode 100644 meta/packages/pango/pango_1.9.1.bb create mode 100644 meta/packages/pcmanfm/files/emblem-symbolic-link.png create mode 100644 meta/packages/pcmanfm/files/gnome-fs-directory.png create mode 100644 meta/packages/pcmanfm/files/gnome-fs-regular.png create mode 100644 meta/packages/pcmanfm/files/gnome-mime-text-plain.png create mode 100644 meta/packages/pcmanfm/files/no-fam-gtk2.6.patch create mode 100644 meta/packages/pcmanfm/files/pcmanfm.desktop create mode 100644 meta/packages/pcmanfm/files/pcmanfm.png create mode 100644 meta/packages/pcmanfm/pcmanfm_0.1.9.8.bb create mode 100644 meta/packages/pcmcia-cs/files/arm/pcmcia create mode 100644 meta/packages/pcmcia-cs/files/gcc4_fixes.patch create mode 100644 meta/packages/pcmcia-cs/files/network.conf create mode 100644 meta/packages/pcmcia-cs/files/pcmcia create mode 100644 meta/packages/pcmcia-cs/files/wnv.conf create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/automount.patch create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/busybox.patch create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/ide.opts create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/network.patch create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/no-hostap-cards.patch create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/nocleanup.patch create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/pcic-extra.patch create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/ratoc-cfu1u.patch create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/spitz/ide.opts create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs-3.2.8/wireless.opts create mode 100644 meta/packages/pcmcia-cs/pcmcia-cs_3.2.8.bb create mode 100644 meta/packages/pcmciautils/pcmciautils-013/makefile_fix.patch create mode 100644 meta/packages/pcmciautils/pcmciautils-013/version_workaround.patch create mode 100644 meta/packages/pcmciautils/pcmciautils_010.bb create mode 100644 meta/packages/pcmciautils/pcmciautils_013.bb create mode 100644 meta/packages/perl/files/Configure-multilib.patch create mode 100644 meta/packages/perl/files/Makefile.SH.patch create mode 100644 meta/packages/perl/files/Makefile.patch create mode 100644 meta/packages/perl/files/config.sh-arm-linux.patch create mode 100644 meta/packages/perl/files/config.sh-i686-linux create mode 100644 meta/packages/perl/files/config.sh-mipsel-linux create mode 100644 meta/packages/perl/files/libperl-5.8.3-create-libperl-soname.patch create mode 100644 meta/packages/perl/files/uclibc.patch create mode 100644 meta/packages/perl/libxml-parser-perl-native_2.34.bb create mode 100644 meta/packages/perl/libxml-parser-perl_2.34.bb create mode 100644 meta/packages/perl/perl-5.8.7/Makefile.SH.patch create mode 100644 meta/packages/perl/perl-5.8.7/Makefile.patch create mode 100644 meta/packages/perl/perl-5.8.7/config.sh-arm-linux create mode 100644 meta/packages/perl/perl-5.8.7/config.sh-arm-linux.patch create mode 100644 meta/packages/perl/perl-5.8.7/config.sh-armeb-linux create mode 100644 meta/packages/perl/perl-5.8.7/config.sh-i386-linux create mode 100644 meta/packages/perl/perl-5.8.7/config.sh-i686-linux create mode 100644 meta/packages/perl/perl-5.8.7/config.sh-mipsel-linux create mode 100644 meta/packages/perl/perl-5.8.7/libperl-5.8.3-create-libperl-soname.patch create mode 100644 meta/packages/perl/perl-5.8.7/uclibc.patch create mode 100644 meta/packages/perl/perl-native_5.8.7.bb create mode 100644 meta/packages/perl/perl-rdepends_5.8.7.inc create mode 100644 meta/packages/perl/perl.inc create mode 100644 meta/packages/perl/perl_5.8.7.bb create mode 100644 meta/packages/pkgconfig/pkgconfig-0.15.0/configure.patch create mode 100644 meta/packages/pkgconfig/pkgconfig-0.15.0/glibconfig-sysdefs.h create mode 100644 meta/packages/pkgconfig/pkgconfig-0.15.0/pkg.m4 create mode 100644 meta/packages/pkgconfig/pkgconfig-native_0.15.0.bb create mode 100644 meta/packages/pkgconfig/pkgconfig_0.15.0.bb create mode 100644 meta/packages/popt/popt-1.7/intl.patch create mode 100644 meta/packages/popt/popt-1.7/m4.patch create mode 100644 meta/packages/popt/popt-native_1.7.bb create mode 100644 meta/packages/popt/popt_1.7.bb create mode 100644 meta/packages/portmap/files/make.patch create mode 100644 meta/packages/portmap/files/no-libwrap.patch create mode 100755 meta/packages/portmap/files/portmap.init create mode 100644 meta/packages/portmap/portmap_5-9.bb create mode 100644 meta/packages/ppp-dialin/files/host-peer create mode 100644 meta/packages/ppp-dialin/files/ppp-dialin create mode 100644 meta/packages/ppp-dialin/ppp-dialin_0.1.bb create mode 100644 meta/packages/ppp/files/08setupdns create mode 100644 meta/packages/ppp/files/92removedns create mode 100755 meta/packages/ppp/files/init create mode 100755 meta/packages/ppp/files/ip-down create mode 100755 meta/packages/ppp/files/ip-up create mode 100644 meta/packages/ppp/files/poff create mode 100644 meta/packages/ppp/files/pon create mode 100644 meta/packages/ppp/ppp-2.4.3/cifdefroute.patch create mode 100644 meta/packages/ppp/ppp-2.4.3/enable-ipv6.patch create mode 100644 meta/packages/ppp/ppp-2.4.3/makefile-remove-hard-usr-reference.patch create mode 100644 meta/packages/ppp/ppp-2.4.3/makefile.patch create mode 100644 meta/packages/ppp/ppp-2.4.3/plugins-fix-CC.patch create mode 100644 meta/packages/ppp/ppp-2.4.3/pppd-resolv-varrun.patch create mode 100644 meta/packages/ppp/ppp-2.4.3/pppoatm-makefile.patch create mode 100644 meta/packages/ppp/ppp_2.4.3.bb create mode 100644 meta/packages/prism3-support/files/hostap-fw-load create mode 100644 meta/packages/prism3-support/prism3-support_1.0.0.bb create mode 100644 meta/packages/psmisc/psmisc-20.2/gettext.patch create mode 100644 meta/packages/psmisc/psmisc_20.2.bb create mode 100644 meta/packages/puzzles/puzzles/game.png create mode 100644 meta/packages/puzzles/puzzles_r6727.bb create mode 100644 meta/packages/qemu/files/configure.patch create mode 100644 meta/packages/qemu/files/mouse_fix-r0.patch create mode 100644 meta/packages/qemu/files/nodocs_cvs.patch create mode 100644 meta/packages/qemu/files/pl110_rgb-r0.patch create mode 100644 meta/packages/qemu/qemu-native_cvs.bb create mode 100644 meta/packages/qemu/qemu_cvs.bb create mode 100644 meta/packages/quilt/files/install.patch create mode 100644 meta/packages/quilt/files/non-gnu.patch create mode 100644 meta/packages/quilt/files/nostrip.patch create mode 100644 meta/packages/quilt/quilt-native_0.42.bb create mode 100644 meta/packages/quilt/quilt-package.inc create mode 100644 meta/packages/quilt/quilt.inc create mode 100644 meta/packages/quilt/quilt_0.42.bb create mode 100644 meta/packages/randrext/randrext_1.0.bb create mode 100644 meta/packages/randrext/randrext_cvs.bb create mode 100644 meta/packages/readline/readline-4.3/acinclude.m4 create mode 100644 meta/packages/readline/readline-4.3/shlink-termcap.patch create mode 100644 meta/packages/readline/readline-native_4.3.bb create mode 100644 meta/packages/readline/readline_4.3.bb create mode 100644 meta/packages/recordext/recordext_cvs.bb create mode 100644 meta/packages/renderext/renderext_0.8.bb create mode 100644 meta/packages/renderext/renderext_cvs.bb create mode 100644 meta/packages/resourceext/resourceext_1.0.bb create mode 100644 meta/packages/resourceext/resourceext_cvs.bb create mode 100644 meta/packages/rxvt-unicode/files/makefile.patch create mode 100644 meta/packages/rxvt-unicode/files/rxvt.desktop create mode 100644 meta/packages/rxvt-unicode/files/rxvt.png create mode 100644 meta/packages/rxvt-unicode/files/signedchar.patch create mode 100644 meta/packages/rxvt-unicode/files/xwc.patch create mode 100644 meta/packages/rxvt-unicode/rxvt-unicode-5.6/xwc.patch create mode 100644 meta/packages/rxvt-unicode/rxvt-unicode_5.6.bb create mode 100644 meta/packages/scap/files/scap.desktop create mode 100644 meta/packages/scap/files/scap.png create mode 100644 meta/packages/scap/files/scap.sh create mode 100644 meta/packages/scap/scap_0.1.bb create mode 100644 meta/packages/setserial/setserial_2.17.bb create mode 100755 meta/packages/settings-daemon/files/70settings-daemon create mode 100644 meta/packages/settings-daemon/settings-daemon_svn.bb create mode 100644 meta/packages/shared-mime-info/shared-mime-info_0.16.bb create mode 100644 meta/packages/sharp-binary-only/sharp-flash-header-c700.bb create mode 100644 meta/packages/sharp-binary-only/sharp-flash-header-c700/header-c700.bin create mode 100644 meta/packages/startup-notification/startup-notification_0.8.bb create mode 100644 meta/packages/strace/strace-4.5.12/quota.patch create mode 100644 meta/packages/strace/strace/arm-syscallent.patch create mode 100644 meta/packages/strace/strace_4.5.12.bb create mode 100644 meta/packages/sysfsutils/sysfsutils_2.0.0.bb create mode 100644 meta/packages/sysvinit/sysvinit-2.86/install.patch create mode 100644 meta/packages/sysvinit/sysvinit-2.86/sysvinit-2.86.patch create mode 100755 meta/packages/sysvinit/sysvinit/bootlogd.init create mode 100644 meta/packages/sysvinit/sysvinit/inittab create mode 100644 meta/packages/sysvinit/sysvinit/need create mode 100644 meta/packages/sysvinit/sysvinit/postinst create mode 100644 meta/packages/sysvinit/sysvinit/prerm create mode 100644 meta/packages/sysvinit/sysvinit/provide create mode 100755 meta/packages/sysvinit/sysvinit/rc create mode 100755 meta/packages/sysvinit/sysvinit/rcS create mode 100644 meta/packages/sysvinit/sysvinit/rcS-default create mode 100644 meta/packages/sysvinit/sysvinit_2.86.bb create mode 100644 meta/packages/tinylogin/tinylogin-1.4/add-system.patch create mode 100644 meta/packages/tinylogin/tinylogin-1.4/adduser-empty_pwd.patch create mode 100644 meta/packages/tinylogin/tinylogin-1.4/cvs-20040608.patch create mode 100644 meta/packages/tinylogin/tinylogin_1.4.bb create mode 100644 meta/packages/tslib/tslib-maemo/multievent.patch create mode 100644 meta/packages/tslib/tslib-maemo/nokia770/ts.conf create mode 100644 meta/packages/tslib/tslib-maemo/nokia770/tslib.sh create mode 100644 meta/packages/tslib/tslib-maemo/ts.conf create mode 100644 meta/packages/tslib/tslib-maemo_0.0.1-15.bb create mode 100644 meta/packages/tslib/tslib/akita/tslib.sh create mode 100644 meta/packages/tslib/tslib/c7x0/tslib.sh create mode 100644 meta/packages/tslib/tslib/collie/ts.conf create mode 100644 meta/packages/tslib/tslib/collie/tslib.sh create mode 100644 meta/packages/tslib/tslib/devfs.patch create mode 100644 meta/packages/tslib/tslib/event1.patch create mode 100644 meta/packages/tslib/tslib/h1940/tslib.sh create mode 100644 meta/packages/tslib/tslib/h3600/tslib.sh create mode 100644 meta/packages/tslib/tslib/h3900/tslib.sh create mode 100644 meta/packages/tslib/tslib/h6300/tslib.sh create mode 100644 meta/packages/tslib/tslib/ipaq-pxa270/tslib.sh create mode 100644 meta/packages/tslib/tslib/jornada56x/ts.conf create mode 100644 meta/packages/tslib/tslib/jornada56x/tslib.sh create mode 100644 meta/packages/tslib/tslib/jornada6xx/ts.conf create mode 100644 meta/packages/tslib/tslib/jornada6xx/tslib.sh create mode 100644 meta/packages/tslib/tslib/jornada7xx/ts.conf create mode 100644 meta/packages/tslib/tslib/jornada7xx/tslib.sh create mode 100644 meta/packages/tslib/tslib/mnci/ts.conf create mode 100644 meta/packages/tslib/tslib/mnci/tslib.sh create mode 100644 meta/packages/tslib/tslib/multievent.patch create mode 100644 meta/packages/tslib/tslib/nokia770/ts.conf create mode 100644 meta/packages/tslib/tslib/omap1610h2/ts.conf create mode 100644 meta/packages/tslib/tslib/omap1610h2/tslib.sh create mode 100644 meta/packages/tslib/tslib/omap5912osk/ts.conf create mode 100644 meta/packages/tslib/tslib/omap5912osk/tslib.sh create mode 100644 meta/packages/tslib/tslib/poodle/tslib.sh create mode 100644 meta/packages/tslib/tslib/simpad/tslib.sh create mode 100644 meta/packages/tslib/tslib/spitz/tslib.sh create mode 100644 meta/packages/tslib/tslib/tosa/tslib.sh create mode 100644 meta/packages/tslib/tslib/ts-2.6.conf create mode 100644 meta/packages/tslib/tslib/ts.conf create mode 100644 meta/packages/tslib/tslib/ts.conf-collie-2.4 create mode 100644 meta/packages/tslib/tslib/ts.conf-corgi-2.4 create mode 100644 meta/packages/tslib/tslib/ts.conf-h3600-2.4 create mode 100644 meta/packages/tslib/tslib/ts.conf-simpad-2.4 create mode 100644 meta/packages/tslib/tslib/tslib.sh create mode 100644 meta/packages/tslib/tslib/usec_fix.patch create mode 100644 meta/packages/tslib/tslib_cvs.bb create mode 100644 meta/packages/udev/files/akita/mount.blacklist create mode 100644 meta/packages/udev/files/c7x0/mount.blacklist create mode 100644 meta/packages/udev/files/devfs-udev.rules create mode 100644 meta/packages/udev/files/fix-alignment.patch create mode 100755 meta/packages/udev/files/init create mode 100644 meta/packages/udev/files/links.conf create mode 100644 meta/packages/udev/files/local.rules create mode 100644 meta/packages/udev/files/mount.blacklist create mode 100644 meta/packages/udev/files/mount.sh create mode 100644 meta/packages/udev/files/network.sh create mode 100644 meta/packages/udev/files/noasmlinkage.patch create mode 100644 meta/packages/udev/files/permissions.rules create mode 100644 meta/packages/udev/files/slugos/mount.blacklist create mode 100644 meta/packages/udev/files/spitz/mount.blacklist create mode 100644 meta/packages/udev/files/tmpfs.patch create mode 100644 meta/packages/udev/files/tosa/mount.blacklist create mode 100644 meta/packages/udev/files/udev.rules create mode 100644 meta/packages/udev/files/udev_network_queue.sh create mode 100644 meta/packages/udev/files/udevsynthesize.patch create mode 100644 meta/packages/udev/files/udevsynthesize.sh create mode 100644 meta/packages/udev/udev-084/flags.patch create mode 100644 meta/packages/udev/udev-084/init create mode 100644 meta/packages/udev/udev-084/local.rules create mode 100644 meta/packages/udev/udev-084/udev.rules create mode 100644 meta/packages/udev/udev-089/flags.patch create mode 100644 meta/packages/udev/udev-089/init create mode 100644 meta/packages/udev/udev-089/local.rules create mode 100644 meta/packages/udev/udev-089/udev.rules create mode 100644 meta/packages/udev/udev-092/flags.patch create mode 100644 meta/packages/udev/udev-092/init create mode 100644 meta/packages/udev/udev-092/local.rules create mode 100644 meta/packages/udev/udev-092/permissions.rules create mode 100644 meta/packages/udev/udev-092/udev.rules create mode 100644 meta/packages/udev/udev.inc create mode 100644 meta/packages/udev/udev_084.bb create mode 100644 meta/packages/udev/udev_089.bb create mode 100644 meta/packages/udev/udev_092.bb create mode 100755 meta/packages/update-modules/update-modules-1.0/openmn/update-modules create mode 100755 meta/packages/update-modules/update-modules-1.0/update-modules create mode 100644 meta/packages/update-modules/update-modules_1.0.bb create mode 100644 meta/packages/update-rc.d/update-rc.d-0.6/copyright.patch create mode 100644 meta/packages/update-rc.d/update-rc.d_0.6.bb create mode 100644 meta/packages/update-rc.d/update-rc.d_0.7.bb create mode 100644 meta/packages/vera-fonts/ttf-bitstream-vera_1.10.bb create mode 100755 meta/packages/web/web_svn.bb create mode 100644 meta/packages/wireless-tools/wireless-tools/fixheaders.patch create mode 100644 meta/packages/wireless-tools/wireless-tools/man.patch create mode 100755 meta/packages/wireless-tools/wireless-tools/wireless-tools.if-pre-up create mode 100644 meta/packages/wireless-tools/wireless-tools/zzz-wireless.if-pre-up create mode 100644 meta/packages/wireless-tools/wireless-tools_28-pre6.bb create mode 100644 meta/packages/wireless-tools/wireless-tools_29-pre10.bb create mode 100644 meta/packages/wpa-supplicant/files/defaults-sane create mode 100644 meta/packages/wpa-supplicant/files/defconfig create mode 100644 meta/packages/wpa-supplicant/files/defconfig-gnutls create mode 100644 meta/packages/wpa-supplicant/files/driver-hermes.patch create mode 100755 meta/packages/wpa-supplicant/files/init.sh create mode 100644 meta/packages/wpa-supplicant/files/madwifi-bsd-fix.diff create mode 100644 meta/packages/wpa-supplicant/files/mtx-1/defconfig create mode 100644 meta/packages/wpa-supplicant/files/openmn/defaults create mode 100644 meta/packages/wpa-supplicant/files/slugos/defaults-sane create mode 100644 meta/packages/wpa-supplicant/files/use-channel.patch create mode 100644 meta/packages/wpa-supplicant/files/wpa_supplicant.conf create mode 100644 meta/packages/wpa-supplicant/files/wpa_supplicant.conf-sane create mode 100644 meta/packages/wpa-supplicant/files/wpa_supplicant_default.conf create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant-0.4.7/defconfig create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant-0.4.7/driver-hermes.patch create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant-0.4.7/driver-zd1211.patch create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant-0.4.7/madwifi-bsd-fix.diff create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant-0.4.7/wpa_supplicant.conf create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant-nossl/wpa-defconfig create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant-nossl_0.2.6.bb create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant-ssl/wpa-defconfig create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant-ssl_0.2.6.bb create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant_0.2.6.inc create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant_0.3.6.bb create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant_0.3.8.bb create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant_0.4.7.bb create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant_0.5.1.bb create mode 100644 meta/packages/wpa-supplicant/wpa-supplicant_cvs.bb create mode 100644 meta/packages/xauth/xauth/autofoo.patch create mode 100644 meta/packages/xauth/xauth_cvs.bb create mode 100644 meta/packages/xcalibrate/xcalibrate_cvs.bb create mode 100644 meta/packages/xcalibrateext/xcalibrateext_cvs.bb create mode 100644 meta/packages/xcursor-transparent-theme/xcursor-transparent-theme-0.1.1/fix_watch_cursor.patch create mode 100644 meta/packages/xcursor-transparent-theme/xcursor-transparent-theme-0.1.1/use-relative-symlinks.patch create mode 100644 meta/packages/xcursor-transparent-theme/xcursor-transparent-theme_0.1.1.bb create mode 100644 meta/packages/xdpyinfo/xdpyinfo_cvs.bb create mode 100644 meta/packages/xextensions/xextensions-native_1.0.1.bb create mode 100644 meta/packages/xextensions/xextensions_1.0.1.bb create mode 100644 meta/packages/xhost/xhost/autofoo.patch create mode 100644 meta/packages/xhost/xhost_20040413.bb create mode 100644 meta/packages/xlibs/diet-x11_6.2.1.bb create mode 100644 meta/packages/xlibs/libice/autofoo.patch create mode 100644 meta/packages/xlibs/libice_6.3.3.bb create mode 100644 meta/packages/xlibs/libsm/autofoo.patch create mode 100644 meta/packages/xlibs/libsm_6.0.3.bb create mode 100644 meta/packages/xlibs/libx11-native_6.2.1.bb create mode 100644 meta/packages/xlibs/libx11/autofoo.patch create mode 100644 meta/packages/xlibs/libx11/errordb-keysymdb-path-fix.patch create mode 100644 meta/packages/xlibs/libx11/fix-utf8-wrong-define.patch create mode 100644 meta/packages/xlibs/libx11_6.2.1.bb create mode 100644 meta/packages/xlibs/libxau-native_0.1.1.bb create mode 100644 meta/packages/xlibs/libxau-native_cvs.bb create mode 100644 meta/packages/xlibs/libxau/autofoo.patch create mode 100644 meta/packages/xlibs/libxau_0.1.1.bb create mode 100644 meta/packages/xlibs/libxau_cvs.bb create mode 100644 meta/packages/xlibs/libxcomposite-1.0.1/autofoo.patch create mode 100644 meta/packages/xlibs/libxcomposite_1.0.1.bb create mode 100644 meta/packages/xlibs/libxcomposite_cvs.bb create mode 100644 meta/packages/xlibs/libxcursor-1.1.2/autofoo.patch create mode 100644 meta/packages/xlibs/libxcursor/autofoo.patch create mode 100644 meta/packages/xlibs/libxcursor_1.1.2.bb create mode 100644 meta/packages/xlibs/libxdamage-1.0.1/autofoo.patch create mode 100644 meta/packages/xlibs/libxdamage/m4.patch create mode 100644 meta/packages/xlibs/libxdamage_1.0.1.bb create mode 100644 meta/packages/xlibs/libxdamage_cvs.bb create mode 100644 meta/packages/xlibs/libxdmcp-native_0.1.3.bb create mode 100644 meta/packages/xlibs/libxdmcp/autofoo.patch create mode 100644 meta/packages/xlibs/libxdmcp_0.1.3.bb create mode 100644 meta/packages/xlibs/libxext-native_cvs.bb create mode 100644 meta/packages/xlibs/libxext/autofoo.patch create mode 100644 meta/packages/xlibs/libxext_cvs.bb create mode 100644 meta/packages/xlibs/libxfixes/autofoo.patch create mode 100644 meta/packages/xlibs/libxfixes_2.0.1.bb create mode 100644 meta/packages/xlibs/libxfixes_cvs.bb create mode 100644 meta/packages/xlibs/libxfont/autofoo.patch create mode 100644 meta/packages/xlibs/libxfont/scalable.patch create mode 100644 meta/packages/xlibs/libxfont_1.4.2.bb create mode 100644 meta/packages/xlibs/libxfont_cvs.bb create mode 100644 meta/packages/xlibs/libxft/autofoo.patch create mode 100644 meta/packages/xlibs/libxft_2.1.6.bb create mode 100644 meta/packages/xlibs/libxft_cvs.bb create mode 100644 meta/packages/xlibs/libxi/autofoo.patch create mode 100644 meta/packages/xlibs/libxi_6.0.1.bb create mode 100644 meta/packages/xlibs/libxmu_cvs.bb create mode 100644 meta/packages/xlibs/libxpm/autofoo.patch create mode 100644 meta/packages/xlibs/libxpm_3.5.1.bb create mode 100644 meta/packages/xlibs/libxpm_cvs.bb create mode 100644 meta/packages/xlibs/libxrandr-1.0.2/autofoo.patch create mode 100644 meta/packages/xlibs/libxrandr/autofoo.patch create mode 100644 meta/packages/xlibs/libxrandr_1.0.2.bb create mode 100644 meta/packages/xlibs/libxrender/autofoo.patch create mode 100644 meta/packages/xlibs/libxrender_cvs.bb create mode 100644 meta/packages/xlibs/libxt/autofoo.patch create mode 100644 meta/packages/xlibs/libxt_0.1.5.bb create mode 100644 meta/packages/xlibs/libxtst_cvs.bb create mode 100644 meta/packages/xlibs/xtrans-native_0.1.bb create mode 100644 meta/packages/xlibs/xtrans_0.1.bb create mode 100644 meta/packages/xlibs/xtrans_cvs.bb create mode 100644 meta/packages/xmodmap/xmodmap/autofoo.patch create mode 100644 meta/packages/xmodmap/xmodmap_cvs.bb create mode 100644 meta/packages/xournal/files/no-printing.diff create mode 100644 meta/packages/xournal/xournal_0.2.bb create mode 100644 meta/packages/xproto/xproto-native_6.6.2.bb create mode 100644 meta/packages/xproto/xproto-native_cvs.bb create mode 100644 meta/packages/xproto/xproto_6.6.2+cvs20050226.bb create mode 100644 meta/packages/xproto/xproto_6.6.2.bb create mode 100644 meta/packages/xproto/xproto_cvs.bb create mode 100644 meta/packages/xrandr/xrandr_cvs.bb create mode 100644 meta/packages/xrdb/xrdb/autofoo.patch create mode 100644 meta/packages/xrdb/xrdb_cvs.bb create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xdefaults create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xinit create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xinit.d/01xrandr create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xinit.d/11zaurus create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xinit.d/12keymap create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xinit.d/30xTs_Calibrate create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xinit.d/40xmodmap create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xinit.d/55xScreenSaver create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xinit.d/60xXDefaults create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xserver create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xsession create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xsession.d/60xXDefaults create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/Xsession.d/90xXWindowManager create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/collie.xmodmap create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/h2200.xmodmap create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/shepherd.xmodmap create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common/etc/X11/simpad.xmodmap create mode 100644 meta/packages/xserver-kdrive-common/xserver-kdrive-common_0.1.bb create mode 100644 meta/packages/xserver-kdrive-common/xserver-nodm-init.bb create mode 100755 meta/packages/xserver-kdrive-common/xserver-nodm-init/xserver-nodm create mode 100644 meta/packages/xserver/xserver-kdrive-omap/configure-tslib.patch create mode 100644 meta/packages/xserver/xserver-kdrive-omap/fbdev-not-fix.patch create mode 100644 meta/packages/xserver/xserver-kdrive-omap/kmode.patch create mode 100644 meta/packages/xserver/xserver-kdrive-omap_6.6.3.bb create mode 100644 meta/packages/xserver/xserver-kdrive/build-20050207-against-X11R7.diff create mode 100644 meta/packages/xserver/xserver-kdrive/devfs.patch create mode 100644 meta/packages/xserver/xserver-kdrive/disable-apm.patch create mode 100644 meta/packages/xserver/xserver-kdrive/epson.patch create mode 100644 meta/packages/xserver/xserver-kdrive/faster-rotated.patch create mode 100644 meta/packages/xserver/xserver-kdrive/fbdev-not-fix.patch create mode 100644 meta/packages/xserver/xserver-kdrive/kdrive-evdev.patch create mode 100644 meta/packages/xserver/xserver-kdrive/kdrive-use-evdev.patch create mode 100644 meta/packages/xserver/xserver-kdrive/kmode.patch create mode 100644 meta/packages/xserver/xserver-kdrive/no-serial-probing.patch create mode 100644 meta/packages/xserver/xserver-kdrive/onlyfb.patch create mode 100644 meta/packages/xserver/xserver-kdrive/xserver-kdrive-poodle.patch create mode 100644 meta/packages/xserver/xserver-kdrive_20050207.bb create mode 100644 meta/packages/xserver/xserver-kdrive_20050624.bb create mode 100644 meta/packages/xserver/xserver-kdrive_20060312.bb create mode 100644 meta/packages/xserver/xserver-kdrive_cvs.bb create mode 100644 meta/packages/xserver/xserver-xorg/dri.patch create mode 100644 meta/packages/xserver/xserver-xorg/fontfile.patch create mode 100644 meta/packages/xserver/xserver-xorg/freetype.patch create mode 100644 meta/packages/xserver/xserver-xorg/imake-installed.patch create mode 100644 meta/packages/xserver/xserver-xorg/imake-staging.patch create mode 100644 meta/packages/xserver/xserver-xorg_6.8.99.10.bb create mode 100644 meta/packages/xserver/xserver-xorg_6.8.99.11.bb create mode 100644 meta/packages/xserver/xserver-xorg_cvs.bb create mode 100644 meta/packages/xset/xset/autofoo.patch create mode 100644 meta/packages/xset/xset/disable-xkb.patch create mode 100644 meta/packages/xset/xset_20040817.bb create mode 100644 meta/packages/xtscal/xtscal/xtscal-cxk.patch create mode 100644 meta/packages/xtscal/xtscal/xtscal-poodle.patch create mode 100644 meta/packages/xtscal/xtscal_0.6.3.bb create mode 100644 meta/packages/zaurus-updater/akita/updater.sh create mode 100644 meta/packages/zaurus-updater/c7x0/updater.sh create mode 100644 meta/packages/zaurus-updater/encdec-updater-native.bb create mode 100644 meta/packages/zaurus-updater/encdec-updater.bb create mode 100644 meta/packages/zaurus-updater/files/encdec-updater.c create mode 100644 meta/packages/zaurus-updater/files/gnu-tar.gz create mode 100644 meta/packages/zaurus-updater/poodle/updater.sh create mode 100755 meta/packages/zaurus-updater/spitz/updater.sh create mode 100644 meta/packages/zaurus-updater/tosa/updater.sh create mode 100644 meta/packages/zaurus-updater/zaurus-updater.bb create mode 100644 meta/packages/zaurusd/zaurusd_svn.bb create mode 100644 meta/packages/zeroconf/files/debian-zeroconf create mode 100644 meta/packages/zeroconf/files/zeroconf-default create mode 100644 meta/packages/zeroconf/zeroconf_0.9.bb create mode 100644 meta/packages/zile/files/for_build.patch create mode 100644 meta/packages/zile/zile_1.7+2.0beta6.bb create mode 100644 meta/packages/zip/zip-native_2.31.bb create mode 100644 meta/packages/zip/zip_2.31.bb create mode 100644 meta/packages/zlib/files/visibility.patch create mode 100644 meta/packages/zlib/files/zlib_1.2.2-8.diff.gz create mode 100644 meta/packages/zlib/zlib-1.2.3/visibility.patch create mode 100644 meta/packages/zlib/zlib-native_1.1.4.bb create mode 100644 meta/packages/zlib/zlib-native_1.2.2.bb create mode 100644 meta/packages/zlib/zlib-native_1.2.3.bb create mode 100644 meta/packages/zlib/zlib_1.1.4.bb create mode 100644 meta/packages/zlib/zlib_1.2.2.bb create mode 100644 meta/packages/zlib/zlib_1.2.3.bb (limited to 'meta/packages') diff --git a/meta/packages/alsa/alsa-lib_1.0.10.bb b/meta/packages/alsa/alsa-lib_1.0.10.bb new file mode 100644 index 000000000..a5d542631 --- /dev/null +++ b/meta/packages/alsa/alsa-lib_1.0.10.bb @@ -0,0 +1,31 @@ +DESCRIPTION = "Alsa sound library" +MAINTAINER = "Lorn Potter " +SECTION = "libs/multimedia" +LICENSE = "GPL" + +# configure.in sets -D__arm__ on the command line for any arm system +# (not just those with the ARM instruction set), this should be removed, +# (or replaced by a permitted #define). +#FIXME: remove the following +ARM_INSTRUCTION_SET = "arm" + +SRC_URI = "ftp://ftp.alsa-project.org/pub/lib/alsa-lib-${PV}.tar.bz2" + +inherit autotools pkgconfig + +EXTRA_OECONF = "--with-cards=pdaudiocf --with-oss=yes" + +do_stage () { + oe_libinstall -so -C src libasound ${STAGING_LIBDIR}/ + install -d ${STAGING_INCDIR}/alsa/sound + install -m 0644 include/*.h ${STAGING_INCDIR}/alsa/ + install -m 0644 include/sound/ainstr*.h ${STAGING_INCDIR}/alsa/sound/ + install -d ${STAGING_DATADIR}/aclocal + install -m 0644 utils/alsa.m4 ${STAGING_DATADIR}/aclocal/ +} + +PACKAGES = "libasound alsa-server alsa-conf alsa-doc alsa-dev" +FILES_libasound = "${libdir}/libasound.so*" +FILES_alsa-server = "${bindir}" +FILES_alsa-conf = "${datadir}" +FILES_alsa-dev = "${libdir}/pkgconfig/ /usr/include/" diff --git a/meta/packages/alsa/alsa-oss_1.0.10.bb b/meta/packages/alsa/alsa-oss_1.0.10.bb new file mode 100644 index 000000000..acf2ba750 --- /dev/null +++ b/meta/packages/alsa/alsa-oss_1.0.10.bb @@ -0,0 +1,18 @@ +DESCRIPTION = "Alsa OSS Compatibility Package" +MAINTAINER = "Lorn Potter " +SECTION = "libs/multimedia" +LICENSE = "GPL" +DEPENDS = "alsa-lib" + +SRC_URI = "ftp://ftp.alsa-project.org/pub/oss-lib/alsa-oss-${PV}.tar.bz2" + +inherit autotools + +do_configure_prepend () { + touch NEWS README AUTHORS ChangeLog +} + +do_stage () { + oe_libinstall -C alsa -a -so libaoss ${STAGING_LIBDIR} + oe_libinstall -C alsa -a -so libalsatoss ${STAGING_LIBDIR} +} diff --git a/meta/packages/alsa/alsa-tools_1.0.10.bb b/meta/packages/alsa/alsa-tools_1.0.10.bb new file mode 100644 index 000000000..eed86e5db --- /dev/null +++ b/meta/packages/alsa/alsa-tools_1.0.10.bb @@ -0,0 +1,10 @@ +BROKEN = "1" + +DESCRIPTION = "Alsa Tools" +SECTION = "console/utils" +LICENSE = "GPL" +DEPENDS = "alsa-lib" + +SRC_URI = "ftp://ftp.alsa-project.org/pub/tools/alsa-tools-${PV}.tar.bz2" + +inherit autotools diff --git a/meta/packages/alsa/alsa-utils_1.0.10.bb b/meta/packages/alsa/alsa-utils_1.0.10.bb new file mode 100644 index 000000000..94e49ebf2 --- /dev/null +++ b/meta/packages/alsa/alsa-utils_1.0.10.bb @@ -0,0 +1,55 @@ +DESCRIPTION = "ALSA Utilities" +MAINTAINER = "Lorn Potter " +SECTION = "console/utils" +LICENSE = "GPL" +DEPENDS = "alsa-lib ncurses" + +SRC_URI = "ftp://ftp.alsa-project.org/pub/utils/alsa-utils-${PV}.tar.bz2" + +inherit autotools + +# This are all packages that we need to make. Also, the now empty alsa-utils +# ipk depend on them. + +PACKAGES += "alsa-utils-alsamixer" +PACKAGES += "alsa-utils-midi" +PACKAGES += "alsa-utils-aplay" +PACKAGES += "alsa-utils-amixer" +PACKAGES += "alsa-utils-aconnect" +PACKAGES += "alsa-utils-iecset" +PACKAGES += "alsa-utils-speakertest" +PACKAGES += "alsa-utils-aseqnet" +PACKAGES += "alsa-utils-alsactl" + + +# We omit alsaconf, because +# a) this is a bash script +# b) it creates config files for RedHat, Debian, Mandrake etc, but not +# for Familiar, OpenZaurus etc + + +FILES_${PN} = "" +FILES_alsa-utils-aplay = "${bindir}/aplay ${bindir}/arecord" +FILES_alsa-utils-amixer = "${bindir}/amixer" +FILES_alsa-utils-alsamixer = "${bindir}/alsamixer" +FILES_alsa-utils-speakertest = "${bindir}/speaker-test" +FILES_alsa-utils-midi = "${bindir}/aplaymidi ${bindir}/arecordmidi ${bindir}/amidi" +FILES_alsa-utils-aconnect = "${bindir}/aconnect" +FILES_alsa-utils-aseqnet = "${bindir}/aseqnet" +FILES_alsa-utils-iecset = "${bindir}/iecset" +FILES_alsa-utils-alsactl = "${sbindir}/alsactl" + +DESCRIPTION_alsa-utils-aplay = "play (and record) sound files via ALSA" +DESCRIPTION_alsa-utils-amixer = "command-line based control for ALSA mixer and settings" +DESCRIPTION_alsa-utils-alsamixer = "ncurses based control for ALSA mixer and settings" +#DESCRIPTION_alsa-utils-speaker-test= "??" +DESCRIPTION_alsa-utils-midi = "miscalleanous MIDI utilities for ALSA" +DESCRIPTION_alsa-utils-aconnect = "ALSA sequencer connection manager" +DESCRIPTION_alsa-utils-aseqnet = "network client/server on ALSA sequencer" +DESCRIPTION_alsa-utils-alsactl = "saves/restores ALSA-settings in /etc/asound.state" +DESCRIPTION_alsa-utils-alsaconf = "a bash script that creates ALSA configuration files" + +RDEPENDS_alsa-utils-aplay += "alsa-conf" +RDEPENDS_alsa-utils-amixer += "alsa-conf" + +ALLOW_EMPTY_alsa-utils = "1" diff --git a/meta/packages/alsa/files/alsa-utils-sys-siglist.patch b/meta/packages/alsa/files/alsa-utils-sys-siglist.patch new file mode 100644 index 000000000..8c499e8d6 --- /dev/null +++ b/meta/packages/alsa/files/alsa-utils-sys-siglist.patch @@ -0,0 +1,15 @@ +sys_siglist is not supported by default on uclibc and is, in general, +a bad thing for the same reasons as sys_errlist is a bad thing. GNU +supports strsignal in the manner of strerror + +--- alsa-utils-1.0.8/alsamixer/alsamixer.c.orig 2005-09-06 12:44:41.415219126 -0700 ++++ alsa-utils-1.0.8/alsamixer/alsamixer.c 2005-09-06 12:44:43.407344482 -0700 +@@ -2188,7 +2188,7 @@ + mixer_signal_handler (int signal) + { + if (signal != SIGSEGV) +- mixer_abort (ERR_SIGNAL, sys_siglist[signal], 0); ++ mixer_abort (ERR_SIGNAL, strsignal(signal), 0); + else + { + fprintf (stderr, "\nSegmentation fault.\n"); diff --git a/meta/packages/apmd/apmd-3.2.2/apmd_proxy b/meta/packages/apmd/apmd-3.2.2/apmd_proxy new file mode 100644 index 000000000..c48ee4e5d --- /dev/null +++ b/meta/packages/apmd/apmd-3.2.2/apmd_proxy @@ -0,0 +1,91 @@ +#!/bin/sh +# +# apmd_proxy - program dispatcher for APM daemon +# +# Written by Craig Markwardt (craigm@lheamail.gsfc.nasa.gov) 21 May 1999 +# Modified for Debian by Avery Pennarun +# +# This shell script is called by the APM daemon (apmd) when a power +# management event occurs. Its first and second arguments describe the +# event. For example, apmd will call "apmd_proxy suspend system" just +# before the system is suspended. +# +# Here are the possible arguments: +# +# start - APM daemon has started +# stop - APM daemon is shutting down +# suspend critical - APM system indicates critical suspend (++) +# suspend system - APM system has requested suspend mode +# suspend user - User has requested suspend mode +# standby system - APM system has requested standby mode +# standby user - User has requested standby mode +# resume suspend - System has resumed from suspend mode +# resume standby - System has resumed from standby mode +# resume critical - System has resumed from critical suspend +# change battery - APM system reported low battery +# change power - APM system reported AC/battery change +# change time - APM system reported time change (*) +# change capability - APM system reported config. change (+) +# +# (*) - APM daemon may be configured to not call these sequences +# (+) - Available if APM kernel supports it. +# (++) - "suspend critical" is never passed to apmd from the kernel, +# so we will never see it here. Scripts that process "resume +# critical" events need to take this into account. +# +# It is the proxy script's responsibility to examine the APM status +# (via /proc/apm) or other status and to take appropriate actions. +# For example, the script might unmount network drives before the +# machine is suspended. +# +# In Debian, the usual way of adding functionality to the proxy is to +# add a script to /etc/apm/event.d. This script will be called by +# apmd_proxy (via run-parts) with the same arguments. +# +# If it is important that a certain set of script be run in a certain +# order on suspend and in a different order on resume, then put all +# the scripts in /etc/apm/scripts.d instead of /etc/apm/event.d and +# symlink to these from /etc/apm/suspend.d, /etc/apm/resume.d and +# /etc/apm/other.d using names whose lexicographical order is the same +# as the desired order of execution. +# +# If the kernel's APM driver supports it, apmd_proxy can return a non-zero +# exit status on suspend and standby events, indicating that the suspend +# or standby event should be rejected. +# +# ******************************************************************* + +set -e + +# The following doesn't yet work, because current kernels (up to at least +# 2.4.20) do not support rejection of APM events. Supporting this would +# require substantial modifications to the APM driver. We will re-enable +# this feature if the driver is ever modified. -- cph@debian.org +# +#SUSPEND_ON_AC=false +#[ -r /etc/apm/apmd_proxy.conf ] && . /etc/apm/apmd_proxy.conf +# +#if [ "${SUSPEND_ON_AC}" = "false" -a "${2}" = "system" ] \ +# && on_ac_power >/dev/null; then +# # Reject system suspends and standbys if we are on AC power +# exit 1 # Reject (NOTE kernel support must be enabled) +#fi + +if [ "${1}" = "suspend" -o "${1}" = "standby" ]; then + run-parts -a "${1}" -a "${2}" /etc/apm/event.d + if [ -d /etc/apm/suspend.d ]; then + run-parts -a "${1}" -a "${2}" /etc/apm/suspend.d + fi +elif [ "${1}" = "resume" ]; then + if [ -d /etc/apm/resume.d ]; then + run-parts -a "${1}" -a "${2}" /etc/apm/resume.d + fi + run-parts -a "${1}" -a "${2}" /etc/apm/event.d +else + run-parts -a "${1}" -a "${2}" /etc/apm/event.d + if [ -d /etc/apm/other.d ]; then + run-parts -a "${1}" -a "${2}" /etc/apm/other.d + fi +fi + +exit 0 diff --git a/meta/packages/apmd/apmd-3.2.2/apmd_proxy.conf b/meta/packages/apmd/apmd-3.2.2/apmd_proxy.conf new file mode 100644 index 000000000..751145c52 --- /dev/null +++ b/meta/packages/apmd/apmd-3.2.2/apmd_proxy.conf @@ -0,0 +1,16 @@ +# /etc/apm/apmd_proxy.conf: configuration file for apmd. +# +# This file is managed by debconf when installing or reconfiguring the +# package. It is generated by merging the answers gathered by debconf +# into the template file "/usr/share/apmd/apmd_proxy.conf". + +# The following doesn't yet work, because current kernels (up to at least +# 2.4.20) do not support rejection of APM events. Supporting this would +# require substantial modifications to the APM driver. We will re-enable +# this feature if the driver is ever modified. -- cph@debian.org +# +# Set the following to "false" if you want to reject system suspend or +# system standby requests when the computer is running on AC power. +# Otherwise set this to "true". Such requests are never rejected when +# the computer is running on battery power. +#SUSPEND_ON_AC=true diff --git a/meta/packages/apmd/apmd-3.2.2/debian.patch b/meta/packages/apmd/apmd-3.2.2/debian.patch new file mode 100644 index 000000000..d49e524bb --- /dev/null +++ b/meta/packages/apmd/apmd-3.2.2/debian.patch @@ -0,0 +1,54 @@ +--- apmd-3.2.2.orig/apmd.c ++++ apmd-3.2.2/apmd.c +@@ -343,7 +343,7 @@ + /* parent */ + int status, retval; + ssize_t len; +- time_t time_limit; ++ time_t countdown; + + if (pid < 0) { + /* Couldn't fork */ +@@ -356,8 +356,9 @@ + /* Capture the child's output, if any, but only until it terminates */ + close(fds[1]); + fcntl(fds[0], F_SETFL, O_RDONLY|O_NONBLOCK); +- time_limit = time(0) + proxy_timeout; ++ countdown = proxy_timeout; + do { ++ countdown -= 1; + while ((len = read(fds[0], line, sizeof(line)-1)) > 0) { + line[len] = 0; + APMD_SYSLOG(LOG_INFO, "+ %s", line); +@@ -372,16 +373,16 @@ + goto proxy_done; + } + +- sleep(1); ++ while (sleep(1) > 0) ; + } while ( +- (time(0) < time_limit) ++ (countdown >= 0) + || (proxy_timeout < 0) + ); + + APMD_SYSLOG(LOG_NOTICE, "Proxy has been running more than %d seconds; killing it", proxy_timeout); + + kill(pid, SIGTERM); +- time_limit = time(0) + 5; ++ countdown = 5; + do { + retval = waitpid(pid, &status, WNOHANG); + if (retval == pid) +@@ -392,9 +393,9 @@ + goto proxy_done; + } + +- sleep(1); ++ while (sleep(1) > 0) ; + +- } while (time(0) < time_limit); ++ } while (countdown >= 0); + + kill(pid, SIGKILL); + status = __W_EXITCODE(0, SIGKILL); diff --git a/meta/packages/apmd/apmd-3.2.2/default b/meta/packages/apmd/apmd-3.2.2/default new file mode 100644 index 000000000..4b7965abf --- /dev/null +++ b/meta/packages/apmd/apmd-3.2.2/default @@ -0,0 +1,8 @@ +# +# Default for /etc/init.d/apmd +# + +# As apmd can be called with arguments, we use the following variable +# to store them, e.g., APMD="-w 5 -p 2". +# See the manual page apmd(8) for details. +APMD="--proxy-timeout 30" diff --git a/meta/packages/apmd/apmd-3.2.2/init b/meta/packages/apmd/apmd-3.2.2/init new file mode 100755 index 000000000..f1098a752 --- /dev/null +++ b/meta/packages/apmd/apmd-3.2.2/init @@ -0,0 +1,44 @@ +#!/bin/sh +# +# Start or stop the Advanced Power Management daemon. +# +# Written by Dirk Eddelbuettel +# Greatly modified by Avery Pennarun +# +# I think this script is now free of bashisms. +# Please correct me if I'm wrong! + +PATH=/bin:/usr/bin:/sbin:/usr/sbin + +[ -f /etc/default/rcS ] && . /etc/default/rcS +[ -f /etc/default/apmd ] && . /etc/default/apmd + +case "$1" in + start) + echo -n "Starting advanced power management daemon: " + start-stop-daemon -S -x /usr/sbin/apmd -- \ + -P /etc/apm/apmd_proxy $APMD + if [ $? = 0 ]; then + echo "apmd." + else + echo "(failed.)" + fi + ;; + stop) + echo -n "Stopping advanced power management daemon: " + start-stop-daemon -K \ + -x /usr/sbin/apmd + echo "apmd." + ;; + restart|force-reload) + $0 stop + $0 start + exit + ;; + *) + echo "Usage: /etc/init.d/apmd {start|stop|restart|force-reload}" + exit 1 + ;; +esac + +exit 0 diff --git a/meta/packages/apmd/apmd-3.2.2/workaround.patch b/meta/packages/apmd/apmd-3.2.2/workaround.patch new file mode 100644 index 000000000..19cf07311 --- /dev/null +++ b/meta/packages/apmd/apmd-3.2.2/workaround.patch @@ -0,0 +1,55 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- apmd-3.2.2.orig/apmd.c~workaround.patch ++++ apmd-3.2.2.orig/apmd.c +@@ -158,6 +158,7 @@ + static int quiet_bios_batlow; /* = 0 */ + static int verbosity = DEFAULT_VERBOSITY; + static int warn_level = 10; ++static int sleep_now = 0; /* ntp */ + + static uid_t apmd_uid = 0; + static int apmd_fd = -1; +@@ -942,6 +943,12 @@ + exit(0); + } + ++/* ntp */ ++static void sig_usr1(int sig) ++{ ++ sleep_now = 1; ++} ++ + int main(int argc, char **argv) + { + int c; +@@ -1151,6 +1158,8 @@ + openlog("apmd", (verbosity>=LOG_DEBUG)?LOG_PERROR:0 | LOG_PID | LOG_CONS, LOG_DAEMON); + + /* Set up signal handler */ ++ if (signal(SIGUSR1, SIG_IGN) != SIG_IGN) ++ signal(SIGUSR1, sig_usr1); /* ntp */ + if (signal(SIGINT, SIG_IGN) != SIG_IGN) + signal(SIGINT, sig_handler); + if (signal(SIGQUIT, SIG_IGN) != SIG_IGN) +@@ -1230,9 +1239,16 @@ + + for (;;) + { +- int num_events = apm_get_events(apmd_fd, check_interval, events, MAX_EVENTS); ++ int num_events; + int e, a; + ++ /* ntp */ ++ if (sleep_now) { ++ sleep_now = 0; ++ handle_event(APM_USER_SUSPEND, &apminfo); ++ } ++ ++ num_events = apm_get_events(apmd_fd, check_interval, events, MAX_EVENTS); + apm_read(&apminfo); + + if (num_events == 0) { diff --git a/meta/packages/apmd/apmd-3.2.2/zaurus24.patch b/meta/packages/apmd/apmd-3.2.2/zaurus24.patch new file mode 100644 index 000000000..5df016ab7 --- /dev/null +++ b/meta/packages/apmd/apmd-3.2.2/zaurus24.patch @@ -0,0 +1,50 @@ +Index: apmd-3.2.2.orig/apm.c +=================================================================== +--- apmd-3.2.2.orig.orig/apm.c 2006-01-26 15:15:27.000000000 +0100 ++++ apmd-3.2.2.orig/apm.c 2006-01-26 17:50:14.000000000 +0100 +@@ -24,10 +24,12 @@ + #include + #include + #include ++#include + #include + #include + #include + #include ++#include + #include "apm.h" + + static int verbose = 0; +@@ -43,6 +45,9 @@ + int fd; + time_t then, now; + int error; ++ FILE* pid_file; ++ int apmd_pid; ++ struct utsname uname_ver; + + fd = open(APM_DEVICE, O_WRONLY); + if (fd < 0) +@@ -54,6 +59,22 @@ + switch (mode) + { + case SUSPEND: ++ if(0 == system("grep -i hardware /proc/cpuinfo|grep -i SHARP")) ++ { ++ uname(&uname_ver); ++ ++ if(0 == strncmp("2.4", uname_ver.release, 3)) ++ { ++ pid_file = fopen("/var/run/apmd.pid", "r"); ++ if(pid_file) ++ { ++ fscanf(pid_file, "%d", &apmd_pid); ++ fclose(pid_file); ++ } ++ ++ kill(apmd_pid, SIGKILL); ++ } ++ } + error = apm_suspend(fd); + break; + case STANDBY: diff --git a/meta/packages/apmd/apmd_3.2.2.bb b/meta/packages/apmd/apmd_3.2.2.bb new file mode 100644 index 000000000..4a23f3959 --- /dev/null +++ b/meta/packages/apmd/apmd_3.2.2.bb @@ -0,0 +1,64 @@ +DESCRIPTION = "Set of tools for managing notebook power consumption." +SECTION = "base" +PRIORITY = "required" +DEPENDS = "libtool-cross" +LICENSE = "GPL" +PR = "r7" + +SRC_URI = "${DEBIAN_MIRROR}/main/a/apmd/apmd_${PV}.orig.tar.gz; \ + file://debian.patch;patch=1 \ + file://workaround.patch;patch=1 \ + file://zaurus24.patch;patch=1 \ + file://init \ + file://default \ + file://apmd_proxy \ + file://apmd_proxy.conf" + +S = "${WORKDIR}/apmd-${PV}.orig" + +inherit update-rc.d + +INITSCRIPT_NAME = "apmd" +INITSCRIPT_PARAMS = "defaults" + +do_compile() { + oe_runmake "LIBTOOL=${STAGING_BINDIR}/${TARGET_PREFIX}libtool" apm apmd +} + +do_stage() { + install -m 0644 apm.h ${STAGING_INCDIR} + oe_libinstall -so libapm ${STAGING_LIBDIR} +} + +do_install() { + install -d ${D}${sysconfdir} + install -d ${D}${sysconfdir}/apm + install -d ${D}${sysconfdir}/apm/event.d + install -d ${D}${sysconfdir}/apm/other.d + install -d ${D}${sysconfdir}/apm/suspend.d + install -d ${D}${sysconfdir}/apm/resume.d + install -d ${D}${sysconfdir}/apm/scripts.d + install -d ${D}${sysconfdir}/default + install -d ${D}${sysconfdir}/init.d + install -d ${D}${sbindir} + install -d ${D}${bindir} + install -d ${D}${libdir} + install -d ${D}${datadir}/apmd + + install -m 4755 ${S}/.libs/apm ${D}${bindir}/apm + install -m 0755 ${S}/.libs/apmd ${D}${sbindir}/apmd + install -m 0755 ${WORKDIR}/apmd_proxy ${D}${sysconfdir}/apm/ + install -m 0644 ${WORKDIR}/apmd_proxy.conf ${D}${datadir}/apmd/ + install -m 0644 ${WORKDIR}/default ${D}${sysconfdir}/default/apmd + oe_libinstall -so libapm ${D}${libdir} + install -m 0644 apm.h ${D}${includedir} + + cat ${WORKDIR}/init | sed -e 's,/usr/sbin,${sbindir},g; s,/etc,${sysconfdir},g;' > ${D}${sysconfdir}/init.d/apmd + chmod 755 ${D}${sysconfdir}/init.d/apmd +} + +PACKAGES =+ "libapm libapm-dev apm" + +FILES_libapm = "${libdir}/libapm.so.*" +FILES_libapm-dev = "${libdir}/libapm.* ${includedir}" +FILES_apm = "${bindir}/apm*" diff --git a/meta/packages/atk/atk_1.10.1.bb b/meta/packages/atk/atk_1.10.1.bb new file mode 100644 index 000000000..6424167ca --- /dev/null +++ b/meta/packages/atk/atk_1.10.1.bb @@ -0,0 +1,21 @@ +DEPENDS = "glib-2.0 gtk-doc" +DESCRIPTION = "An accessibility toolkit for GNOME." +SECTION = "x11/libs" +PRIORITY = "optional" +MAINTAINER = "Philip Blundell " +LICENSE = "LGPL" + +SRC_URI = "ftp://ftp.gtk.org/pub/gtk/v2.8/atk-${PV}.tar.bz2" + +inherit autotools pkgconfig + +EXTRA_OECONF = "--disable-glibtest" + +CFLAGS_append = " -I${STAGING_INCDIR}/glib-2.0 \ + -I${STAGING_INCDIR}/glib-2.0/glib \ + -I${STAGING_INCDIR}/glib-2.0/gobject" + +do_stage () { + oe_libinstall -so -C atk libatk-1.0 ${STAGING_LIBDIR} + autotools_stage_includes +} diff --git a/meta/packages/autoconf/autoconf-2.59/autoconf-x.patch b/meta/packages/autoconf/autoconf-2.59/autoconf-x.patch new file mode 100644 index 000000000..596535b7d --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/autoconf-x.patch @@ -0,0 +1,36 @@ +Index: lib/autoconf/libs.m4 +=================================================================== +RCS file: /cvsroot/autoconf/autoconf/lib/autoconf/libs.m4,v +retrieving revision 1.13 +diff -p -u -r1.13 libs.m4 +--- autoconf-2.59/lib/autoconf/libs.m4 6 Sep 2005 15:34:06 -0000 1.13 ++++ autoconf-2.59/lib/autoconf/libs.m4 18 Sep 2005 17:09:58 -0000 +@@ -265,13 +265,13 @@ ac_x_header_dirs=' + /usr/openwin/share/include' + + if test "$ac_x_includes" = no; then +- # Guess where to find include files, by looking for Intrinsic.h. ++ # Guess where to find include files, by looking for Xlib.h. + # First, try using that file with no special directory specified. +- AC_PREPROC_IFELSE([AC_LANG_SOURCE([@%:@include ])], ++ AC_PREPROC_IFELSE([AC_LANG_SOURCE([@%:@include ])], + [# We can compile using X headers with no special include directory. + ac_x_includes=], + [for ac_dir in $ac_x_header_dirs; do +- if test -r "$ac_dir/X11/Intrinsic.h"; then ++ if test -r "$ac_dir/X11/Xlib.h"; then + ac_x_includes=$ac_dir + break + fi +@@ -284,9 +284,9 @@ if test "$ac_x_libraries" = no; then + # Don't add to $LIBS permanently. + ac_save_LIBS=$LIBS +- LIBS="-lXt $LIBS" +- AC_LINK_IFELSE([AC_LANG_PROGRAM([@%:@include ], +- [XtMalloc (0)])], ++ LIBS="-lX11 $LIBS" ++ AC_LINK_IFELSE([AC_LANG_PROGRAM([@%:@include ], ++ [XrmInitialize ()])], + [LIBS=$ac_save_LIBS + # We can link X programs with no special library path. + ac_x_libraries=], diff --git a/meta/packages/autoconf/autoconf-2.59/autoconf259-update-configscripts.patch b/meta/packages/autoconf/autoconf-2.59/autoconf259-update-configscripts.patch new file mode 100644 index 000000000..77be3c647 --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/autoconf259-update-configscripts.patch @@ -0,0 +1,393 @@ +--- autoconf-2.59/config/config.guess.old 2003-10-23 10:28:51.000000000 -0400 ++++ autoconf-2.59/config/config.guess 2004-04-24 22:36:28.000000000 -0400 +@@ -3,7 +3,7 @@ + # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, + # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. + +-timestamp='2003-10-03' ++timestamp='2004-03-12' + + # This file is free software; you can redistribute it and/or modify it + # under the terms of the GNU General Public License as published by +@@ -197,12 +197,18 @@ + # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. + echo "${machine}-${os}${release}" + exit 0 ;; ++ amd64:OpenBSD:*:*) ++ echo x86_64-unknown-openbsd${UNAME_RELEASE} ++ exit 0 ;; + amiga:OpenBSD:*:*) + echo m68k-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; + arc:OpenBSD:*:*) + echo mipsel-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; ++ cats:OpenBSD:*:*) ++ echo arm-unknown-openbsd${UNAME_RELEASE} ++ exit 0 ;; + hp300:OpenBSD:*:*) + echo m68k-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; +@@ -221,6 +227,9 @@ + mvmeppc:OpenBSD:*:*) + echo powerpc-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; ++ pegasos:OpenBSD:*:*) ++ echo powerpc-unknown-openbsd${UNAME_RELEASE} ++ exit 0 ;; + pmax:OpenBSD:*:*) + echo mipsel-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; +@@ -236,10 +245,24 @@ + *:OpenBSD:*:*) + echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; ++ *:ekkoBSD:*:*) ++ echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} ++ exit 0 ;; ++ macppc:MirBSD:*:*) ++ echo powerppc-unknown-mirbsd${UNAME_RELEASE} ++ exit 0 ;; ++ *:MirBSD:*:*) ++ echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} ++ exit 0 ;; + alpha:OSF1:*:*) +- if test $UNAME_RELEASE = "V4.0"; then ++ case $UNAME_RELEASE in ++ *4.0) + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` +- fi ++ ;; ++ *5.*) ++ UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ++ ;; ++ esac + # According to Compaq, /usr/sbin/psrinfo has been available on + # OSF/1 and Tru64 systems produced since 1995. I hope that + # covers most systems running today. This code pipes the CPU +@@ -277,11 +300,12 @@ + "EV7.9 (21364A)") + UNAME_MACHINE="alphaev79" ;; + esac ++ # A Pn.n version is a patched version. + # A Vn.n version is a released version. + # A Tn.n version is a released field test version. + # A Xn.n version is an unreleased experimental baselevel. + # 1.2 uses "1.2" for uname -r. +- echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` ++ echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` + exit 0 ;; + Alpha*:OpenVMS:*:*) + echo alpha-hp-vms +@@ -307,6 +331,9 @@ + *:OS/390:*:*) + echo i370-ibm-openedition + exit 0 ;; ++ *:OS400:*:*) ++ echo powerpc-ibm-os400 ++ exit 0 ;; + arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) + echo arm-acorn-riscix${UNAME_RELEASE} + exit 0;; +@@ -399,6 +426,9 @@ + *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) + echo m68k-unknown-mint${UNAME_RELEASE} + exit 0 ;; ++ m68k:machten:*:*) ++ echo m68k-apple-machten${UNAME_RELEASE} ++ exit 0 ;; + powerpc:machten:*:*) + echo powerpc-apple-machten${UNAME_RELEASE} + exit 0 ;; +@@ -742,6 +772,11 @@ + FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` + echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit 0 ;; ++ 5000:UNIX_System_V:4.*:*) ++ FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` ++ FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` ++ echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" ++ exit 0 ;; + i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) + echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} + exit 0 ;; +@@ -751,7 +786,7 @@ + *:BSD/OS:*:*) + echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} + exit 0 ;; +- *:FreeBSD:*:*|*:GNU/FreeBSD:*:*) ++ *:FreeBSD:*:*) + # Determine whether the default compiler uses glibc. + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c +@@ -763,7 +798,7 @@ + #endif + EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` +- # GNU/FreeBSD systems have a "k" prefix to indicate we are using ++ # GNU/KFreeBSD systems have a "k" prefix to indicate we are using + # FreeBSD's kernel, but not the complete OS. + case ${LIBC} in gnu) kernel_only='k' ;; esac + echo ${UNAME_MACHINE}-unknown-${kernel_only}freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC} +@@ -799,8 +834,13 @@ + echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit 0 ;; + *:GNU:*:*) ++ # the GNU system + echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` + exit 0 ;; ++ *:GNU/*:*:*) ++ # other systems with GNU libc and userland ++ echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu ++ exit 0 ;; + i*86:Minix:*:*) + echo ${UNAME_MACHINE}-pc-minix + exit 0 ;; +@@ -813,6 +853,9 @@ + ia64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit 0 ;; ++ m32r*:Linux:*:*) ++ echo ${UNAME_MACHINE}-unknown-linux-gnu ++ exit 0 ;; + m68*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit 0 ;; +@@ -981,6 +1024,9 @@ + i*86:atheos:*:*) + echo ${UNAME_MACHINE}-unknown-atheos + exit 0 ;; ++ i*86:syllable:*:*) ++ echo ${UNAME_MACHINE}-pc-syllable ++ exit 0 ;; + i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) + echo i386-unknown-lynxos${UNAME_RELEASE} + exit 0 ;; +@@ -1052,7 +1098,7 @@ + exit 0 ;; + M68*:*:R3V[567]*:*) + test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;; +- 3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0) ++ 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0) + OS_REL='' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` +@@ -1167,7 +1213,7 @@ + *:QNX:*:4*) + echo i386-pc-qnx + exit 0 ;; +- NSR-[DGKLNPTVWY]:NONSTOP_KERNEL:*:*) ++ NSR-?:NONSTOP_KERNEL:*:*) + echo nsr-tandem-nsk${UNAME_RELEASE} + exit 0 ;; + *:NonStop-UX:*:*) +@@ -1211,6 +1257,9 @@ + SEI:*:*:SEIUX) + echo mips-sei-seiux${UNAME_RELEASE} + exit 0 ;; ++ *:DragonFly:*:*) ++ echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ++ exit 0 ;; + esac + + #echo '(No uname command or uname output not recognized.)' 1>&2 +--- autoconf-2.59/config/config.sub.old 2003-10-23 10:28:51.000000000 -0400 ++++ autoconf-2.59/config/config.sub 2004-04-24 22:36:28.000000000 -0400 +@@ -3,7 +3,7 @@ + # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, + # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. + +-timestamp='2003-08-18' ++timestamp='2004-03-12' + + # This file is (in principle) common to ALL GNU software. + # The presence of a machine in this file suggests that SOME GNU software +@@ -118,7 +118,8 @@ + # Here we must recognize all the valid KERNEL-OS combinations. + maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` + case $maybe_os in +- nto-qnx* | linux-gnu* | linux-dietlibc | kfreebsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) ++ nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \ ++ kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) + os=-$maybe_os + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` + ;; +@@ -236,7 +237,7 @@ + | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ + | i370 | i860 | i960 | ia64 \ + | ip2k | iq2000 \ +- | m32r | m68000 | m68k | m88k | mcore \ ++ | m32r | m32rle | m68000 | m68k | m88k | mcore \ + | mips | mipsbe | mipseb | mipsel | mipsle \ + | mips16 \ + | mips64 | mips64el \ +@@ -261,7 +262,7 @@ + | pyramid \ + | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \ + | sh64 | sh64le \ +- | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \ ++ | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv8 | sparcv9 | sparcv9b \ + | strongarm \ + | tahoe | thumb | tic4x | tic80 | tron \ + | v850 | v850e \ +@@ -307,7 +308,7 @@ + | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ + | i*86-* | i860-* | i960-* | ia64-* \ + | ip2k-* | iq2000-* \ +- | m32r-* \ ++ | m32r-* | m32rle-* \ + | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ + | m88110-* | m88k-* | mcore-* \ + | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ +@@ -335,7 +336,7 @@ + | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \ + | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ + | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \ +- | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \ ++ | sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \ + | tahoe-* | thumb-* \ + | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ + | tron-* \ +@@ -362,6 +363,9 @@ + basic_machine=a29k-amd + os=-udi + ;; ++ abacus) ++ basic_machine=abacus-unknown ++ ;; + adobe68k) + basic_machine=m68010-adobe + os=-scout +@@ -379,6 +383,9 @@ + amd64) + basic_machine=x86_64-pc + ;; ++ amd64-*) ++ basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` ++ ;; + amdahl) + basic_machine=580-amdahl + os=-sysv +@@ -438,12 +445,20 @@ + basic_machine=j90-cray + os=-unicos + ;; ++ cr16c) ++ basic_machine=cr16c-unknown ++ os=-elf ++ ;; + crds | unos) + basic_machine=m68k-crds + ;; + cris | cris-* | etrax*) + basic_machine=cris-axis + ;; ++ crx) ++ basic_machine=crx-unknown ++ os=-elf ++ ;; + da30 | da30-*) + basic_machine=m68k-da30 + ;; +@@ -743,6 +758,10 @@ + basic_machine=or32-unknown + os=-coff + ;; ++ os400) ++ basic_machine=powerpc-ibm ++ os=-os400 ++ ;; + OSE68000 | ose68000) + basic_machine=m68000-ericsson + os=-ose +@@ -963,6 +982,10 @@ + tower | tower-32) + basic_machine=m68k-ncr + ;; ++ tpf) ++ basic_machine=s390x-ibm ++ os=-tpf ++ ;; + udi29k) + basic_machine=a29k-amd + os=-udi +@@ -1058,7 +1081,7 @@ + sh64) + basic_machine=sh64-unknown + ;; +- sparc | sparcv9 | sparcv9b) ++ sparc | sparcv8 | sparcv9 | sparcv9b) + basic_machine=sparc-sun + ;; + cydra) +@@ -1131,19 +1154,20 @@ + | -aos* \ + | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ + | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ +- | -hiux* | -386bsd* | -netbsd* | -openbsd* | -kfreebsd* | -freebsd* | -riscix* \ +- | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ ++ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \ ++ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ ++ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ + | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ + | -chorusos* | -chorusrdb* \ + | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ +- | -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \ ++ | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \ + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ + | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ + | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ + | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ + | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ +- | -powermax* | -dnix* | -nx6 | -nx7 | -sei*) ++ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly*) + # Remember, each alternative MUST END IN *, to match a version number. + ;; + -qnx*) +@@ -1182,6 +1206,9 @@ + -opened*) + os=-openedition + ;; ++ -os400*) ++ os=-os400 ++ ;; + -wince*) + os=-wince + ;; +@@ -1203,6 +1230,9 @@ + -atheos*) + os=-atheos + ;; ++ -syllable*) ++ os=-syllable ++ ;; + -386bsd) + os=-bsd + ;; +@@ -1225,6 +1255,9 @@ + -sinix*) + os=-sysv4 + ;; ++ -tpf*) ++ os=-tpf ++ ;; + -triton*) + os=-sysv3 + ;; +@@ -1473,9 +1506,15 @@ + -mvs* | -opened*) + vendor=ibm + ;; ++ -os400*) ++ vendor=ibm ++ ;; + -ptx*) + vendor=sequent + ;; ++ -tpf*) ++ vendor=ibm ++ ;; + -vxsim* | -vxworks* | -windiss*) + vendor=wrs + ;; diff --git a/meta/packages/autoconf/autoconf-2.59/autoheader-nonfatal-warnings.patch b/meta/packages/autoconf/autoconf-2.59/autoheader-nonfatal-warnings.patch new file mode 100644 index 000000000..1f18e04bb --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/autoheader-nonfatal-warnings.patch @@ -0,0 +1,13 @@ +--- autoconf-2.59/bin/autoheader.in~ 2003-10-10 14:52:56.000000000 +0100 ++++ autoconf-2.59/bin/autoheader.in 2004-05-03 01:36:45.000000000 +0100 +@@ -272,8 +272,8 @@ + } + + } +- exit 1 +- if keys %symbol; ++# exit 1 ++# if keys %symbol; + } + + update_file ("$tmp/config.hin", "$config_h_in"); diff --git a/meta/packages/autoconf/autoconf-2.59/autoreconf-exclude.patch b/meta/packages/autoconf/autoconf-2.59/autoreconf-exclude.patch new file mode 100644 index 000000000..764495551 --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/autoreconf-exclude.patch @@ -0,0 +1,125 @@ +--- autoconf-2.59/bin/autoreconf.in 2004-05-06 00:27:34.000000000 -0400 ++++ autoconf-2.59.new/bin/autoreconf.in 2004-05-06 00:27:46.000000000 -0400 +@@ -75,6 +75,7 @@ + -f, --force consider all files obsolete + -i, --install copy missing auxiliary files + -s, --symlink with -i, install symbolic links instead of copies ++ -x, --exclude=STEPS steps we should not run + -m, --make when applicable, re-run ./configure && make + -W, --warnings=CATEGORY report the warnings falling in CATEGORY [syntax] + +@@ -127,6 +128,13 @@ + # Rerun `./configure && make'? + my $make = 0; + ++# Steps to exclude ++my @exclude; ++my @ex; ++ ++my $uses_gettext; ++my $configure_ac; ++ + ## ---------- ## + ## Routines. ## + ## ---------- ## +@@ -144,6 +152,7 @@ + 'B|prepend-include=s' => \@prepend_include, + 'i|install' => \$install, + 's|symlink' => \$symlink, ++ 'x|exclude=s' => \@exclude, + 'm|make' => \$make); + + # Split the warnings as a list of elements instead of a list of +@@ -152,6 +161,8 @@ + parse_WARNINGS; + parse_warnings '--warnings', @warning; + ++ @exclude = map { split /,/ } @exclude; ++ + # Even if the user specified a configure.ac, trim to get the + # directory, and look for configure.ac again. Because (i) the code + # is simpler, and (ii) we are still able to diagnose simultaneous +@@ -237,6 +249,11 @@ + { + my ($aclocal, $flags) = @_; + ++ @ex = grep (/^aclocal$/, @exclude); ++ if ($#ex != -1) { ++ return; ++ } ++ + # aclocal 1.8+ does all this for free. It can be recognized by its + # --force support. + if ($aclocal_supports_force) +@@ -348,7 +365,10 @@ + } + else + { +- xsystem "$autopoint"; ++ @ex = grep (/^autopoint$/, @exclude); ++ if ($#ex == -1) { ++ xsystem ("$autopoint"); ++ } + } + + +@@ -501,7 +521,10 @@ + } + elsif ($install) + { +- xsystem ($libtoolize); ++ @ex = grep (/^libtoolize$/, @exclude); ++ if ($#ex == -1) { ++ xsystem ("$libtoolize"); ++ } + $rerun_aclocal = 1; + } + else +@@ -541,7 +564,10 @@ + # latter runs the former, and (ii) autoconf is stricter than + # autoheader. So all in all, autoconf should give better error + # messages. +- xsystem ($autoconf); ++ @ex = grep (/^autoconf$/, @exclude); ++ if ($#ex == -1) { ++ xsystem ("$autoconf"); ++ } + + + # -------------------- # +@@ -562,7 +588,10 @@ + } + else + { +- xsystem ($autoheader); ++ @ex = grep (/^autoheader$/, @exclude); ++ if ($#ex == -1) { ++ xsystem ("$autoheader"); ++ } + } + + +@@ -580,7 +609,10 @@ + # We should always run automake, and let it decide whether it shall + # update the file or not. In fact, the effect of `$force' is already + # included in `$automake' via `--no-force'. +- xsystem ($automake); ++ @ex = grep (/^automake$/, @exclude); ++ if ($#ex == -1) { ++ xsystem ("$automake"); ++ } + } + + +@@ -604,7 +636,10 @@ + } + else + { +- xsystem ("make"); ++ @ex = grep (/^make$/, @exclude); ++ if ($#ex == -1) { ++ xsystem ("make"); ++ } + } + } + } diff --git a/meta/packages/autoconf/autoconf-2.59/autoreconf-foreign.patch b/meta/packages/autoconf/autoconf-2.59/autoreconf-foreign.patch new file mode 100644 index 000000000..587a82382 --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/autoreconf-foreign.patch @@ -0,0 +1,11 @@ +--- autoconf-2.59/bin/autoreconf.in~autoreconf-foreign 2004-05-09 20:55:06.000000000 -0400 ++++ autoconf-2.59/bin/autoreconf.in 2004-05-09 20:55:55.000000000 -0400 +@@ -184,6 +184,8 @@ + + $aclocal_supports_force = `$aclocal --help` =~ /--force/; + ++ $automake .= ' --foreign'; ++ + # Dispatch autoreconf's option to the tools. + # --include; + $autoconf .= join (' --include=', '', @include); diff --git a/meta/packages/autoconf/autoconf-2.59/autoreconf-gnuconfigize.patch b/meta/packages/autoconf/autoconf-2.59/autoreconf-gnuconfigize.patch new file mode 100644 index 000000000..44709d550 --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/autoreconf-gnuconfigize.patch @@ -0,0 +1,47 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- autoconf-2.59/bin/autoreconf.in~autoreconf-gnuconfigize 2004-05-14 19:04:35.000000000 -0500 ++++ autoconf-2.59/bin/autoreconf.in 2004-05-14 19:07:34.000000000 -0500 +@@ -58,7 +58,7 @@ + $help = "Usage: $0 [OPTION] ... [CONFIGURE-AC or DIRECTORY] ... + + Run `autoconf' (and `autoheader', `aclocal', `automake', `autopoint' +-(formerly `gettextize'), and `libtoolize' where appropriate) ++(formerly `gettextize'), `libtoolize', and `gnu-configize' where appropriate) + repeatedly to remake the GNU Build System files in the DIRECTORIES or + the directory trees driven by CONFIGURE-AC (defaulting to `.'). + +@@ -105,12 +105,13 @@ + "; + + # Lib files. +-my $autoconf = $ENV{'AUTOCONF'} || '@bindir@/@autoconf-name@'; +-my $autoheader = $ENV{'AUTOHEADER'} || '@bindir@/@autoheader-name@'; +-my $automake = $ENV{'AUTOMAKE'} || 'automake'; +-my $aclocal = $ENV{'ACLOCAL'} || 'aclocal'; +-my $libtoolize = $ENV{'LIBTOOLIZE'} || 'libtoolize'; +-my $autopoint = $ENV{'AUTOPOINT'} || 'autopoint'; ++my $autoconf = $ENV{'AUTOCONF'} || '@bindir@/@autoconf-name@'; ++my $autoheader = $ENV{'AUTOHEADER'} || '@bindir@/@autoheader-name@'; ++my $automake = $ENV{'AUTOMAKE'} || 'automake'; ++my $aclocal = $ENV{'ACLOCAL'} || 'aclocal'; ++my $libtoolize = $ENV{'LIBTOOLIZE'} || 'libtoolize'; ++my $autopoint = $ENV{'AUTOPOINT'} || 'autopoint'; ++my $gnuconfigize = $ENV{'GNUCONFIGIZE'} || 'gnu-configize'; + + # --install -- as --add-missing in other tools. + my $install = 0; +@@ -617,6 +618,10 @@ + } + } + ++ @ex = grep (/^gnu-configize$/, @exclude); ++ if ($#ex == -1) { ++ xsystem ("$gnuconfigize"); ++ } + + # -------------- # + # Running make. # diff --git a/meta/packages/autoconf/autoconf-2.59/autoreconf-include.patch b/meta/packages/autoconf/autoconf-2.59/autoreconf-include.patch new file mode 100644 index 000000000..5a7604b0f --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/autoreconf-include.patch @@ -0,0 +1,10 @@ +--- autoconf/bin/autoreconf.in~ 2004-04-06 23:36:10.000000000 +0100 ++++ autoconf/bin/autoreconf.in 2004-04-08 20:51:57.000000000 +0100 +@@ -179,6 +179,7 @@ + $autoconf .= join (' --prepend-include=', '', @prepend_include); + $autoheader .= join (' --include=', '', @include); + $autoheader .= join (' --prepend-include=', '', @prepend_include); ++ $aclocal .= join (' -I ', '', @include); + + # --install and --symlink; + if ($install) diff --git a/meta/packages/autoconf/autoconf-2.59/path_prog_fixes.patch b/meta/packages/autoconf/autoconf-2.59/path_prog_fixes.patch new file mode 100644 index 000000000..5f0d055a4 --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/path_prog_fixes.patch @@ -0,0 +1,126 @@ +Index: autoconf-2.59/bin/autoheader.in +=================================================================== +--- autoconf-2.59.orig/bin/autoheader.in 2005-03-09 16:27:17.933878952 -0500 ++++ autoconf-2.59/bin/autoheader.in 2005-03-09 16:29:57.360642400 -0500 +@@ -1,8 +1,8 @@ +-#! @PERL@ ++#! @bindir@/env perl + # -*- Perl -*- + # @configure_input@ + +-eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' ++eval 'case $# in 0) exec @bindir@/env perl -S "$0";; *) exec @bindir@/env perl -S "$0" "$@";; esac' + if 0; + + # autoheader -- create `config.h.in' from `configure.ac' +Index: autoconf-2.59/bin/autom4te.in +=================================================================== +--- autoconf-2.59.orig/bin/autom4te.in 2003-10-28 03:48:36.000000000 -0500 ++++ autoconf-2.59/bin/autom4te.in 2005-03-09 16:30:14.957967200 -0500 +@@ -1,8 +1,10 @@ +-#! @PERL@ -w ++#! @bindir@/env perl + # -*- perl -*- + # @configure_input@ + +-eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' ++use warnings; ++ ++eval 'case $# in 0) exec @bindir@/env perl -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' + if 0; + + # autom4te - Wrapper around M4 libraries. +@@ -87,7 +89,7 @@ + my $freeze = 0; + + # $M4. +-my $m4 = $ENV{"M4"} || '@M4@'; ++my $m4 = $ENV{"M4"} || '@bindir@/env m4'; + # Some non-GNU m4's don't reject the --help option, so give them /dev/null. + fatal "need GNU m4 1.4 or later: $m4" + if system "$m4 --help &1 | grep reload-state >/dev/null"; +Index: autoconf-2.59/bin/autoreconf.in +=================================================================== +--- autoconf-2.59.orig/bin/autoreconf.in 2005-03-09 16:27:17.354966960 -0500 ++++ autoconf-2.59/bin/autoreconf.in 2005-03-09 16:31:19.572144352 -0500 +@@ -1,8 +1,10 @@ +-#! @PERL@ -w ++#! @bindir@/env perl + # -*- perl -*- + # @configure_input@ + +-eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' ++use warnings; ++ ++eval 'case $# in 0) exec @bindir@/env perl -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' + if 0; + + # autoreconf - install the GNU Build System in a directory tree +Index: autoconf-2.59/bin/autoscan.in +=================================================================== +--- autoconf-2.59.orig/bin/autoscan.in 2003-09-26 08:57:49.000000000 -0400 ++++ autoconf-2.59/bin/autoscan.in 2005-03-09 16:30:18.136483992 -0500 +@@ -1,4 +1,4 @@ +-#! @PERL@ -w ++#! @bindir@/env perl + # -*- perl -*- + # autoscan - Create configure.scan (a preliminary configure.ac) for a package. + # Copyright (C) 1994, 1999, 2000, 2001, 2002, 2003 +@@ -21,7 +21,9 @@ + + # Written by David MacKenzie . + +-eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' ++use warnings; ++ ++eval 'case $# in 0) exec @bindir@/env perl -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' + if 0; + + BEGIN +Index: autoconf-2.59/bin/autoupdate.in +=================================================================== +--- autoconf-2.59.orig/bin/autoupdate.in 2003-08-27 07:26:32.000000000 -0400 ++++ autoconf-2.59/bin/autoupdate.in 2005-03-09 16:30:19.912214040 -0500 +@@ -1,4 +1,4 @@ +-#! @PERL@ -w ++#! @bindir@/env perl + # -*- perl -*- + # autoupdate - modernize an Autoconf file. + # Copyright (C) 1994, 1999, 2000, 2001, 2002, 2003 +@@ -22,7 +22,9 @@ + # Originally written by David MacKenzie . + # Rewritten by Akim Demaille . + +-eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' ++use warnings; ++ ++eval 'case $# in 0) exec @bindir@/env perl -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' + if 0; + + BEGIN +@@ -54,7 +56,7 @@ + my @include = ('@datadir@'); + my $force = 0; + # m4. +-my $m4 = $ENV{"M4"} || '@M4@'; ++my $m4 = $ENV{"M4"} || '@bindir@/env m4'; + + + # $HELP +Index: autoconf-2.59/bin/ifnames.in +=================================================================== +--- autoconf-2.59.orig/bin/ifnames.in 2003-10-10 09:52:56.000000000 -0400 ++++ autoconf-2.59/bin/ifnames.in 2005-03-09 16:30:22.656796800 -0500 +@@ -1,8 +1,10 @@ +-#! @PERL@ -w ++#! @bindir@/env perl + # -*- perl -*- + # @configure_input@ + +-eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' ++use warnings; ++ ++eval 'case $# in 0) exec @bindir@/env perl -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' + if 0; + + # ifnames - print the identifiers used in C preprocessor conditionals diff --git a/meta/packages/autoconf/autoconf-2.59/program_prefix.patch b/meta/packages/autoconf/autoconf-2.59/program_prefix.patch new file mode 100644 index 000000000..e6f4096a9 --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/program_prefix.patch @@ -0,0 +1,19 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- autoconf-2.57/lib/autoconf/general.m4~program_prefix ++++ autoconf-2.57/lib/autoconf/general.m4 +@@ -1676,8 +1676,9 @@ + # The aliases save the names the user supplied, while $host etc. + # will get canonicalized. + test -n "$target_alias" && +- test "$program_prefix$program_suffix$program_transform_name" = \ +- NONENONEs,x,x, && ++ test "$target_alias" != "$host_alias" && ++ test "$program_prefix$program_suffix$program_transform_name" = \ ++ NONENONEs,x,x, && + program_prefix=${target_alias}-[]dnl + ])# AC_CANONICAL_TARGET + diff --git a/meta/packages/autoconf/autoconf-2.59/sizeof_types.patch b/meta/packages/autoconf/autoconf-2.59/sizeof_types.patch new file mode 100644 index 000000000..9a6e47453 --- /dev/null +++ b/meta/packages/autoconf/autoconf-2.59/sizeof_types.patch @@ -0,0 +1,59 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- autoconf-2.59/lib/autoconf/types.m4~sizeof_types.patch 2003-05-22 08:05:14.000000000 -0400 ++++ autoconf-2.59/lib/autoconf/types.m4 2004-05-29 01:31:24.828295015 -0400 +@@ -380,32 +380,38 @@ + # Generic checks. # + # ---------------- # + ++AC_DEFUN([AC_PROG_SIZE], ++[ ++ AC_CHECK_TOOL(SIZE, size, :) ++]) + + # AC_CHECK_SIZEOF(TYPE, [IGNORED], [INCLUDES = DEFAULT-INCLUDES]) + # --------------------------------------------------------------- + AC_DEFUN([AC_CHECK_SIZEOF], +-[AS_LITERAL_IF([$1], [], ++[AC_REQUIRE([AC_PROG_SIZE]) ++AC_REQUIRE([AC_PROG_AWK]) ++ AS_LITERAL_IF([$1], [], + [AC_FATAL([$0: requires literal arguments])])dnl + AC_CHECK_TYPE([$1], [], [], [$3]) + AC_CACHE_CHECK([size of $1], AS_TR_SH([ac_cv_sizeof_$1]), +-[if test "$AS_TR_SH([ac_cv_type_$1])" = yes; then +- # The cast to unsigned long works around a bug in the HP C Compiler +- # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +- # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +- # This bug is HP SR number 8606223364. +- _AC_COMPUTE_INT([(long) (sizeof ($1))], +- [AS_TR_SH([ac_cv_sizeof_$1])], +- [AC_INCLUDES_DEFAULT([$3])], +- [AC_MSG_FAILURE([cannot compute sizeof ($1), 77])]) ++[ ++if test "$AS_TR_SH([ac_cv_type_$1])" = yes; then ++AC_COMPILE_IFELSE([AC_LANG_PROGRAM([AC_INCLUDES_DEFAULT([$3])], ++ [static const $1 x[[256]];])], ++ [ ++ AS_TR_SH([ac_cv_sizeof_$1])=`$SIZE conftest.$ac_objext | tail -n 1 | $AWK '{print [$]3/256}'` ++ ], ++ [ ++ AS_TR_SH([ac_cv_sizeof_$1])=0 ++ ]) + else + AS_TR_SH([ac_cv_sizeof_$1])=0 +-fi])dnl ++fi ++])dnl + AC_DEFINE_UNQUOTED(AS_TR_CPP(sizeof_$1), $AS_TR_SH([ac_cv_sizeof_$1]), + [The size of a `$1', as computed by sizeof.]) + ])# AC_CHECK_SIZEOF + +- +- + # ---------------- # + # Generic checks. # + # ---------------- # diff --git a/meta/packages/autoconf/autoconf-native_2.59.bb b/meta/packages/autoconf/autoconf-native_2.59.bb new file mode 100644 index 000000000..21a200245 --- /dev/null +++ b/meta/packages/autoconf/autoconf-native_2.59.bb @@ -0,0 +1,10 @@ +SECTION = "devel" +include autoconf_${PV}.bb +DEPENDS = "m4-native gnu-config-native" +RDEPENDS_${PN} = "m4-native gnu-config-native" +RRECOMMENDS_${PN} = "automake-native" + +S = "${WORKDIR}/autoconf-${PV}" +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/autoconf-${PV}" + +inherit native diff --git a/meta/packages/autoconf/autoconf_2.59.bb b/meta/packages/autoconf/autoconf_2.59.bb new file mode 100644 index 000000000..3cc962da0 --- /dev/null +++ b/meta/packages/autoconf/autoconf_2.59.bb @@ -0,0 +1,22 @@ +DESCRIPTION = "A package of M4 macros to produce scripts to \ +automatically configure sourcecode." +LICENSE = "GPL" +HOMEPAGE = "http://www.gnu.org/software/autoconf/" +SECTION = "devel" +DEPENDS += "m4-native" +RDEPENDS_${PN} = "m4 gnu-config" +RRECOMMENDS_${PN} = "automake" +PR = "r4" + +SRC_URI = "${GNU_MIRROR}/autoconf/autoconf-${PV}.tar.bz2 \ + file://program_prefix.patch;patch=1 \ + file://autoreconf-include.patch;patch=1 \ + file://autoreconf-exclude.patch;patch=1 \ + file://autoreconf-foreign.patch;patch=1 \ + file://autoreconf-gnuconfigize.patch;patch=1 \ + file://autoconf259-update-configscripts.patch;patch=1 \ + file://autoheader-nonfatal-warnings.patch;patch=1 \ + file://sizeof_types.patch;patch=1 \ + file://autoconf-x.patch;patch=1 \ + ${@['file://path_prog_fixes.patch;patch=1', ''][bb.data.inherits_class('native', d)]}" +inherit autotools diff --git a/meta/packages/automake/automake-1.9.3/automake182-update-configscripts.patch b/meta/packages/automake/automake-1.9.3/automake182-update-configscripts.patch new file mode 100644 index 000000000..52992b3b2 --- /dev/null +++ b/meta/packages/automake/automake-1.9.3/automake182-update-configscripts.patch @@ -0,0 +1,201 @@ +--- automake-1.8.2/lib/config.guess.old 2004-01-11 15:33:12.000000000 -0500 ++++ automake-1.8.2/lib/config.guess 2004-04-24 22:42:44.000000000 -0400 +@@ -3,7 +3,7 @@ + # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, + # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. + +-timestamp='2004-01-05' ++timestamp='2004-03-12' + + # This file is free software; you can redistribute it and/or modify it + # under the terms of the GNU General Public License as published by +@@ -197,12 +197,18 @@ + # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. + echo "${machine}-${os}${release}" + exit 0 ;; ++ amd64:OpenBSD:*:*) ++ echo x86_64-unknown-openbsd${UNAME_RELEASE} ++ exit 0 ;; + amiga:OpenBSD:*:*) + echo m68k-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; + arc:OpenBSD:*:*) + echo mipsel-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; ++ cats:OpenBSD:*:*) ++ echo arm-unknown-openbsd${UNAME_RELEASE} ++ exit 0 ;; + hp300:OpenBSD:*:*) + echo m68k-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; +@@ -239,10 +245,24 @@ + *:OpenBSD:*:*) + echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; ++ *:ekkoBSD:*:*) ++ echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} ++ exit 0 ;; ++ macppc:MirBSD:*:*) ++ echo powerppc-unknown-mirbsd${UNAME_RELEASE} ++ exit 0 ;; ++ *:MirBSD:*:*) ++ echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} ++ exit 0 ;; + alpha:OSF1:*:*) +- if test $UNAME_RELEASE = "V4.0"; then ++ case $UNAME_RELEASE in ++ *4.0) + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` +- fi ++ ;; ++ *5.*) ++ UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ++ ;; ++ esac + # According to Compaq, /usr/sbin/psrinfo has been available on + # OSF/1 and Tru64 systems produced since 1995. I hope that + # covers most systems running today. This code pipes the CPU +@@ -280,11 +300,12 @@ + "EV7.9 (21364A)") + UNAME_MACHINE="alphaev79" ;; + esac ++ # A Pn.n version is a patched version. + # A Vn.n version is a released version. + # A Tn.n version is a released field test version. + # A Xn.n version is an unreleased experimental baselevel. + # 1.2 uses "1.2" for uname -r. +- echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` ++ echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` + exit 0 ;; + Alpha*:OpenVMS:*:*) + echo alpha-hp-vms +@@ -405,6 +426,9 @@ + *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) + echo m68k-unknown-mint${UNAME_RELEASE} + exit 0 ;; ++ m68k:machten:*:*) ++ echo m68k-apple-machten${UNAME_RELEASE} ++ exit 0 ;; + powerpc:machten:*:*) + echo powerpc-apple-machten${UNAME_RELEASE} + exit 0 ;; +@@ -829,6 +853,9 @@ + ia64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit 0 ;; ++ m32r*:Linux:*:*) ++ echo ${UNAME_MACHINE}-unknown-linux-gnu ++ exit 0 ;; + m68*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit 0 ;; +@@ -1230,8 +1257,8 @@ + SEI:*:*:SEIUX) + echo mips-sei-seiux${UNAME_RELEASE} + exit 0 ;; +- *:DRAGONFLY:*:*) +- echo ${UNAME_MACHINE}-unknown-dragonfly${UNAME_RELEASE} ++ *:DragonFly:*:*) ++ echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` + exit 0 ;; + esac + +--- automake-1.8.2/lib/config.sub.old 2004-01-11 15:33:12.000000000 -0500 ++++ automake-1.8.2/lib/config.sub 2004-04-24 22:42:44.000000000 -0400 +@@ -3,7 +3,7 @@ + # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, + # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. + +-timestamp='2004-01-05' ++timestamp='2004-03-12' + + # This file is (in principle) common to ALL GNU software. + # The presence of a machine in this file suggests that SOME GNU software +@@ -237,7 +237,7 @@ + | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ + | i370 | i860 | i960 | ia64 \ + | ip2k | iq2000 \ +- | m32r | m68000 | m68k | m88k | mcore \ ++ | m32r | m32rle | m68000 | m68k | m88k | mcore \ + | mips | mipsbe | mipseb | mipsel | mipsle \ + | mips16 \ + | mips64 | mips64el \ +@@ -262,7 +262,7 @@ + | pyramid \ + | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \ + | sh64 | sh64le \ +- | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \ ++ | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv8 | sparcv9 | sparcv9b \ + | strongarm \ + | tahoe | thumb | tic4x | tic80 | tron \ + | v850 | v850e \ +@@ -308,7 +308,7 @@ + | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ + | i*86-* | i860-* | i960-* | ia64-* \ + | ip2k-* | iq2000-* \ +- | m32r-* \ ++ | m32r-* | m32rle-* \ + | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ + | m88110-* | m88k-* | mcore-* \ + | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ +@@ -336,7 +336,7 @@ + | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \ + | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ + | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \ +- | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \ ++ | sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \ + | tahoe-* | thumb-* \ + | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ + | tron-* \ +@@ -363,6 +363,9 @@ + basic_machine=a29k-amd + os=-udi + ;; ++ abacus) ++ basic_machine=abacus-unknown ++ ;; + adobe68k) + basic_machine=m68010-adobe + os=-scout +@@ -442,12 +445,20 @@ + basic_machine=j90-cray + os=-unicos + ;; ++ cr16c) ++ basic_machine=cr16c-unknown ++ os=-elf ++ ;; + crds | unos) + basic_machine=m68k-crds + ;; + cris | cris-* | etrax*) + basic_machine=cris-axis + ;; ++ crx) ++ basic_machine=crx-unknown ++ os=-elf ++ ;; + da30 | da30-*) + basic_machine=m68k-da30 + ;; +@@ -1070,7 +1081,7 @@ + sh64) + basic_machine=sh64-unknown + ;; +- sparc | sparcv9 | sparcv9b) ++ sparc | sparcv8 | sparcv9 | sparcv9b) + basic_machine=sparc-sun + ;; + cydra) +@@ -1143,8 +1154,9 @@ + | -aos* \ + | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ + | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ +- | -hiux* | -386bsd* | -knetbsd* | -netbsd* | -openbsd* | -kfreebsd* | -freebsd* | -riscix* \ +- | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ ++ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \ ++ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ ++ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ + | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ + | -chorusos* | -chorusrdb* \ diff --git a/meta/packages/automake/automake-native.inc b/meta/packages/automake/automake-native.inc new file mode 100644 index 000000000..7b69252ff --- /dev/null +++ b/meta/packages/automake/automake-native.inc @@ -0,0 +1,11 @@ +SECTION = "devel" +include automake_${PV}.bb +DEPENDS = "autoconf-native" +RDEPENDS_automake-native = "autoconf-native perl-native-runtime" + +inherit native + +do_stage () { + oe_runmake install + install -d ${datadir}/aclocal +} diff --git a/meta/packages/automake/automake-native_1.9.3.bb b/meta/packages/automake/automake-native_1.9.3.bb new file mode 100644 index 000000000..39544b7c1 --- /dev/null +++ b/meta/packages/automake/automake-native_1.9.3.bb @@ -0,0 +1,3 @@ +PV := "${PV}" + +include automake-native.inc diff --git a/meta/packages/automake/automake.inc b/meta/packages/automake/automake.inc new file mode 100644 index 000000000..fa59c1f5c --- /dev/null +++ b/meta/packages/automake/automake.inc @@ -0,0 +1,23 @@ +RDEPENDS_automake += "\ + autoconf \ + perl \ + perl-module-bytes \ + perl-module-constant \ + perl-module-cwd \ + perl-module-data-dumper \ + perl-module-dynaloader \ + perl-module-errno \ + perl-module-exporter-heavy \ + perl-module-file-basename \ + perl-module-file-compare \ + perl-module-file-copy \ + perl-module-file-glob \ + perl-module-file-spec-unix \ + perl-module-file-stat \ + perl-module-getopt-long \ + perl-module-io \ + perl-module-io-file \ + perl-module-posix \ + perl-module-strict \ + perl-module-text-parsewords \ + perl-module-vars " diff --git a/meta/packages/automake/automake_1.9.3.bb b/meta/packages/automake/automake_1.9.3.bb new file mode 100644 index 000000000..fb75b83b6 --- /dev/null +++ b/meta/packages/automake/automake_1.9.3.bb @@ -0,0 +1,28 @@ +DESCRIPTION = "A tool for automatically generating Makefiles." +LICENSE = "GPL" +HOMEPAGE = "http://www.gnu.org/software/automake/" +SECTION = "devel" +PR = "r5" + +SRC_URI = "${GNU_MIRROR}/automake/automake-${PV}.tar.bz2 \ + ${@['file://path_prog_fixes.patch;patch=1', ''][bb.data.inherits_class('native', d)]}" +S = "${WORKDIR}/automake-${PV}" +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/automake-${PV}" + +inherit autotools + +export AUTOMAKE = "${@bb.which('automake', bb.data.getVar('PATH', d, 1))}" +FILES_${PN} += "${datadir}/automake* ${datadir}/aclocal*" + +include automake.inc + +do_install () { + oe_runmake 'DESTDIR=${D}' install + install -d ${D}${datadir} + if [ ! -e ${D}${datadir}/aclocal ]; then + ln -sf aclocal-1.9 ${D}${datadir}/aclocal + fi + if [ ! -e ${D}${datadir}/automake ]; then + ln -sf automake-1.9 ${D}${datadir}/automake + fi +} diff --git a/meta/packages/automake/files/path_prog_fixes.patch b/meta/packages/automake/files/path_prog_fixes.patch new file mode 100644 index 000000000..a85b24420 --- /dev/null +++ b/meta/packages/automake/files/path_prog_fixes.patch @@ -0,0 +1,60 @@ +Index: automake-1.9.3/Makefile.am +=================================================================== +--- automake-1.9.3.orig/Makefile.am 2004-10-25 14:57:30.000000000 -0400 ++++ automake-1.9.3/Makefile.am 2005-03-09 16:47:38.241364016 -0500 +@@ -66,7 +66,8 @@ + -e 's,[@]SHELL[@],$(SHELL),g' \ + -e 's,[@]VERSION[@],$(VERSION),g' \ + -e 's,[@]configure_input[@],Generated from $@.in; do not edit by hand.,g' \ +- -e 's,[@]datadir[@],$(datadir),g' ++ -e 's,[@]datadir[@],$(datadir),g' \ ++ -e 's,[@]bindir[@],$(bindir),g' + + ## These files depend on Makefile so they are rebuilt if $(VERSION), + ## $(datadir) or other do_subst'ituted variables change. +Index: automake-1.9.3/Makefile.in +=================================================================== +--- automake-1.9.3.orig/Makefile.in 2004-11-01 05:23:54.000000000 -0500 ++++ automake-1.9.3/Makefile.in 2005-03-09 16:47:54.712859968 -0500 +@@ -161,7 +161,8 @@ + -e 's,[@]SHELL[@],$(SHELL),g' \ + -e 's,[@]VERSION[@],$(VERSION),g' \ + -e 's,[@]configure_input[@],Generated from $@.in; do not edit by hand.,g' \ +- -e 's,[@]datadir[@],$(datadir),g' ++ -e 's,[@]datadir[@],$(datadir),g' \ ++ -e 's,[@]bindir[@],$(bindir),g' + + WGET = wget + WGETSGO = $(WGET) http://savannah.gnu.org/cgi-bin/viewcvs/~checkout~ +Index: automake-1.9.3/aclocal.in +=================================================================== +--- automake-1.9.3.orig/aclocal.in 2004-10-10 12:10:24.000000000 -0400 ++++ automake-1.9.3/aclocal.in 2005-03-09 16:47:38.241364016 -0500 +@@ -1,8 +1,8 @@ +-#!@PERL@ ++#!@bindir@/env perl + # -*- perl -*- + # @configure_input@ + +-eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' ++eval 'case $# in 0) exec @bindir@/env perl -S "$0";; *) exec @bindir@/env perl -S "$0" "$@";; esac' + if 0; + + # aclocal - create aclocal.m4 by scanning configure.ac +Index: automake-1.9.3/automake.in +=================================================================== +--- automake-1.9.3.orig/automake.in 2004-10-21 16:23:26.000000000 -0400 ++++ automake-1.9.3/automake.in 2005-03-09 16:47:38.245363408 -0500 +@@ -1,8 +1,10 @@ +-#!@PERL@ -w ++#!@bindir@/env perl + # -*- perl -*- + # @configure_input@ + +-eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' ++use warnings; ++ ++eval 'case $# in 0) exec @bindir@/env perl -S "$0";; *) exec @bindir@/env perl -S "$0" "$@";; esac' + if 0; + + # automake - create Makefile.in from Makefile.am diff --git a/meta/packages/avahi/avahi_0.6.10.bb b/meta/packages/avahi/avahi_0.6.10.bb new file mode 100644 index 000000000..2b12d91c8 --- /dev/null +++ b/meta/packages/avahi/avahi_0.6.10.bb @@ -0,0 +1,58 @@ +DESCRIPTION = "Avahi implements the DNS-SD over Multicast DNS" +SECTION = "network" +PRIORITY = "optional" +AUTHOR = "Lennart Poettering " +HOMEPAGE = "http://avahi.org" +MAINTAINER = "Philipp Zabel " +LICENSE= "GPL" + +DEPENDS = "expat libdaemon dbus" +RRECOMMENDS = "libnss-mdns" + +SRC_URI = "http://avahi.org/download/avahi-${PV}.tar.gz" + +PACKAGES = "avahi-daemon libavahi-common libavahi-core libavahi-client avahi-dnsconfd libavahi-glib avahi-dev avahi-doc avahi-utils" + +FILES_libavahi-common = "${libdir}/libavahi-common.so.*" +FILES_libavahi-core= "${libdir}/libavahi-core.so.*" +FILES_avahi-daemon = "${sbindir}/avahi-daemon \ + ${sysconfdir}/avahi/avahi-daemon.conf \ + ${sysconfdir}/avahi/hosts \ + ${sysconfdir}/avahi/services \ + ${sysconfdir}/dbus-1 \ + ${sysconfdir}/init.d/avahi-daemon \ + ${datadir}/avahi/introspection/*.introspect \ + ${datadir}/avahi/avahi-service.dtd \ + ${datadir}/avahi/service-types" +FILES_libavahi-client = "${libdir}/libavahi-client.so.*" +FILES_avahi-dnsconfd = "${sbindir}/avahi-dnsconfd \ + ${sysconfdir}/avahi/avahi-dnsconfd.action \ + ${sysconfdir}/init.d/avahi-dnsconfd" +FILES_libavahi-glib = "${libdir}/libavahi-glib.so.*" +FILES_avahi-utils = "${bindir}/avahi-*" + +CONFFILES_avahi-daemon = "${sysconfdir}/avahi/avahi-daemon.conf" + +EXTRA_OECONF = "--with-distro=debian --disable-gdbm --disable-gtk --disable-mono --disable-monodoc --disable-qt3 --disable-qt4 --disable-python" +inherit autotools pkgconfig update-rc.d + +INITSCRIPT_PACKAGES = "avahi-daemon avahi-dnsconfd" +INITSCRIPT_NAME_avahi-daemon = "avahi-daemon" +INITSCRIPT_PARAMS_avahi-daemon = "defaults 21 19" +INITSCRIPT_NAME_avahi-dnsconfd = "avahi-dnsconfd" +INITSCRIPT_PARAMS_avahi-dnsconfd = "defaults 22 19" + +pkg_postinst_avahi-daemon () { + if [ "x$D" != "x" ]; then + exit 1 + fi + + grep avahi /etc/group || addgroup avahi + grep avahi /etc/passwd || adduser --disabled-password --system --home /var/run/avahi-daemon --no-create-home avahi --ingroup avahi -g Avahi + /etc/init.d/dbus-1 force-reload +} + +pkg_postrm_avahi-daemon () { + deluser avahi || true + delgroup avahi || true +} diff --git a/meta/packages/base-files/base-files/akita/fstab b/meta/packages/base-files/base-files/akita/fstab new file mode 100644 index 000000000..754f140b3 --- /dev/null +++ b/meta/packages/base-files/base-files/akita/fstab @@ -0,0 +1,16 @@ +/dev/mtdblock2 / jffs2 rw,noatime 1 1 +/dev/mtdblock3 /home jffs2 defaults,noatime 1 2 +proc /proc proc defaults 0 0 +/dev/hda1 /media/cf auto defaults,sync,noauto 0 0 + +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 + +# SD/MMC in kernel 2.4 +/dev/mmcda1 /media/card auto defaults,sync,noauto 0 0 +# SD/MMC in kernel 2.6 +/dev/mmcblk0p1 /media/card auto defaults,sync,noauto 0 0 + +# USB Storage +/dev/sda1 /media/usbhdd vfat noauto,umask=000,noatime,iocharset=utf8,codepage=932 0 0 + diff --git a/meta/packages/base-files/base-files/c7x0/fstab b/meta/packages/base-files/base-files/c7x0/fstab new file mode 100644 index 000000000..fb37e07ae --- /dev/null +++ b/meta/packages/base-files/base-files/c7x0/fstab @@ -0,0 +1,12 @@ +/dev/mtdblock2 / jffs2 rw,noatime 1 1 +/dev/mtdblock3 /home jffs2 defaults,noatime 1 2 +proc /proc proc defaults 0 0 +/dev/hda1 /media/cf auto defaults,sync,noauto 0 0 + +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 + +# SD/MMC in kernel 2.4 +/dev/mmcda1 /media/card auto defaults,sync,noauto 0 0 +# SD/MMC in kernel 2.6 +/dev/mmcblk0p1 /media/card auto defaults,sync,noauto 0 0 diff --git a/meta/packages/base-files/base-files/c7x0/usbd b/meta/packages/base-files/base-files/c7x0/usbd new file mode 100644 index 000000000..40931ee8e --- /dev/null +++ b/meta/packages/base-files/base-files/c7x0/usbd @@ -0,0 +1 @@ +usbdmodule=pxa_bi diff --git a/meta/packages/base-files/base-files/collie/fstab b/meta/packages/base-files/base-files/collie/fstab new file mode 100644 index 000000000..ce5bc3bac --- /dev/null +++ b/meta/packages/base-files/base-files/collie/fstab @@ -0,0 +1,8 @@ +/dev/mtdblock4 / jffs2 defaults 1 1 +proc /proc proc defaults 0 0 +/dev/hda1 /media/cf auto defaults,sync,noauto,noatime,user,exec,suid,gid=100,umask=0002 0 0 +/dev/mmcda1 /media/card auto defaults,sync,noauto,noatime,user,exec,suid 0 0 +tmpfs /var tmpfs defaults 0 0 + +# we use a non-volatile ramdisk, see /etc/init.d/ramdisk +#tmpfs /media/ram tmpfs defaults 0 0 diff --git a/meta/packages/base-files/base-files/collie/usbd b/meta/packages/base-files/base-files/collie/usbd new file mode 100644 index 000000000..425761458 --- /dev/null +++ b/meta/packages/base-files/base-files/collie/usbd @@ -0,0 +1 @@ +usbdmodule=sa1100_bi diff --git a/meta/packages/base-files/base-files/epia/fstab b/meta/packages/base-files/base-files/epia/fstab new file mode 100644 index 000000000..70f0b0735 --- /dev/null +++ b/meta/packages/base-files/base-files/epia/fstab @@ -0,0 +1,4 @@ +/dev/ram0 / ext2 rw 1 1 +tmpfs /var tmpfs defaults 0 0 +proc /proc proc defaults 0 0 +tmpfs /tmp tmpfs defaults 0 0 diff --git a/meta/packages/base-files/base-files/familiar/issue b/meta/packages/base-files/base-files/familiar/issue new file mode 100644 index 000000000..2224b6ce8 --- /dev/null +++ b/meta/packages/base-files/base-files/familiar/issue @@ -0,0 +1,2 @@ +Familiar Linux Unofficial Snapshot \n \l + diff --git a/meta/packages/base-files/base-files/familiar/issue.net b/meta/packages/base-files/base-files/familiar/issue.net new file mode 100644 index 000000000..2539ffe3a --- /dev/null +++ b/meta/packages/base-files/base-files/familiar/issue.net @@ -0,0 +1,3 @@ +Familiar Linux Unofficial Snapshot %h + + diff --git a/meta/packages/base-files/base-files/filesystems b/meta/packages/base-files/base-files/filesystems new file mode 100644 index 000000000..653593a43 --- /dev/null +++ b/meta/packages/base-files/base-files/filesystems @@ -0,0 +1,6 @@ +minix +fat +vfat +ext2 +ext3 +* diff --git a/meta/packages/base-files/base-files/fstab b/meta/packages/base-files/base-files/fstab new file mode 100644 index 000000000..8bfb08720 --- /dev/null +++ b/meta/packages/base-files/base-files/fstab @@ -0,0 +1,12 @@ +# stock fstab - you probably want to override this with a machine specific one + +rootfs / auto defaults 1 1 +proc /proc proc defaults 0 0 +devpts /dev/pts devpts mode=0620,gid=5 0 0 +usbdevfs /proc/bus/usb usbdevfs noauto 0 0 +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 + +# uncomment this if your device has a SD/MMC/Transflash slot +#/dev/mmcblk0p1 /media/card auto defaults,sync,noauto 0 0 + diff --git a/meta/packages/base-files/base-files/h3600/fstab b/meta/packages/base-files/base-files/h3600/fstab new file mode 100644 index 000000000..4228c15c0 --- /dev/null +++ b/meta/packages/base-files/base-files/h3600/fstab @@ -0,0 +1,6 @@ +/dev/mtdblock4 / jffs2 defaults 1 1 +proc /proc proc defaults 0 0 +/dev/hda1 /media/cf auto defaults,noauto,noatime,user,exec,suid 0 0 +/dev/mmc/part1 /media/card auto defaults,noauto,noatime,user,exec,suid 0 0 +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 diff --git a/meta/packages/base-files/base-files/h3900/fstab b/meta/packages/base-files/base-files/h3900/fstab new file mode 100644 index 000000000..2a3929fd1 --- /dev/null +++ b/meta/packages/base-files/base-files/h3900/fstab @@ -0,0 +1,8 @@ +/dev/mtdblock/1 / jffs2 defaults 1 1 +#breaks h51xx +#/dev/mtdblock/2 /home jffs2 defaults 1 1 +proc /proc proc defaults 0 0 +/dev/hda1 /media/cf auto defaults,noauto,noatime,user,exec,suid 0 0 +/dev/mmc/part1 /media/card auto defaults,noauto,noatime,user,exec,suid 0 0 +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 diff --git a/meta/packages/base-files/base-files/host.conf b/meta/packages/base-files/base-files/host.conf new file mode 100644 index 000000000..1a8c1e151 --- /dev/null +++ b/meta/packages/base-files/base-files/host.conf @@ -0,0 +1,2 @@ +order hosts,bind +multi on diff --git a/meta/packages/base-files/base-files/inputrc b/meta/packages/base-files/base-files/inputrc new file mode 100644 index 000000000..b5c4c8af2 --- /dev/null +++ b/meta/packages/base-files/base-files/inputrc @@ -0,0 +1,61 @@ +# /etc/inputrc - global inputrc for libreadline +# See readline(3readline) and `info rluserman' for more information. + +# Be 8 bit clean. +set input-meta on +set output-meta on + +# To allow the use of 8bit-characters like the german umlauts, comment out +# the line below. However this makes the meta key not work as a meta key, +# which is annoying to those which don't need to type in 8-bit characters. + +# set convert-meta off + +# try to enable the application keypad when it is called. Some systems +# need this to enable the arrow keys. +# set enable-keypad on + +# see /usr/share/doc/bash/inputrc.arrows for other codes of arrow keys + +# do not bell on tab-completion +# set bell-style none + +# some defaults / modifications for the emacs mode +$if mode=emacs + +# allow the use of the Home/End keys +# "\e[1~": beginning-of-line +# "\e[4~": end-of-line + +# allow the use of the Delete/Insert keys +# "\e[3~": delete-char +# "\e[2~": quoted-insert + +# mappings for "page up" and "page down" to step to the beginning/end +# of the history +# "\e[5~": beginning-of-history +# "\e[6~": end-of-history + +# alternate mappings for "page up" and "page down" to search the history +# "\e[5~": history-search-backward +# "\e[6~": history-search-forward + +# # mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving +# "\e[5C": forward-word +# "\e[5D": backward-word +# "\e\e[C": forward-word +# "\e\e[D": backward-word + +# $if term=rxvt +# "\e[8~": end-of-line +# $endif + +# for non RH/Debian xterm, can't hurt for RH/DEbian xterm +# "\eOH": beginning-of-line +# "\eOF": end-of-line + +# for freebsd console +# "\e[H": beginning-of-line +# "\e[F": end-of-line + +$endif diff --git a/meta/packages/base-files/base-files/ipaq-pxa270/fstab b/meta/packages/base-files/base-files/ipaq-pxa270/fstab new file mode 100644 index 000000000..3dfde917e --- /dev/null +++ b/meta/packages/base-files/base-files/ipaq-pxa270/fstab @@ -0,0 +1,9 @@ +/dev/mtdblock2 / jffs2 defaults 1 1 +/dev/mtdblock3 /home jffs2 defaults 1 1 + +proc /proc proc defaults 0 0 +sys /sys sysfs defaults 0 0 + +/dev/hda1 /media/cf auto defaults,noauto,noatime,exec,suid 0 0 +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 diff --git a/meta/packages/base-files/base-files/issue b/meta/packages/base-files/base-files/issue new file mode 100644 index 000000000..329af4665 --- /dev/null +++ b/meta/packages/base-files/base-files/issue @@ -0,0 +1,2 @@ +OpenEmbedded Linux \n \l + diff --git a/meta/packages/base-files/base-files/issue.net b/meta/packages/base-files/base-files/issue.net new file mode 100644 index 000000000..6dc3588b4 --- /dev/null +++ b/meta/packages/base-files/base-files/issue.net @@ -0,0 +1,3 @@ +OpenEmbedded Linux %h + + diff --git a/meta/packages/base-files/base-files/jornada56x/fstab b/meta/packages/base-files/base-files/jornada56x/fstab new file mode 100644 index 000000000..07ccff0fe --- /dev/null +++ b/meta/packages/base-files/base-files/jornada56x/fstab @@ -0,0 +1,6 @@ +/dev/mtdblock1 / jffs2 rw,noatime 1 1 +proc /proc proc defaults 0 0 +/dev/hda1 /mnt/cf auto defaults,sync,noauto 0 0 +tmpfs /var tmpfs defaults 0 0 +tmpfs /mnt/ram tmpfs defaults 0 0 +devpts /dev/pts devpts defaults 0 0 \ No newline at end of file diff --git a/meta/packages/base-files/base-files/jornada720/fstab b/meta/packages/base-files/base-files/jornada720/fstab new file mode 100644 index 000000000..07ccff0fe --- /dev/null +++ b/meta/packages/base-files/base-files/jornada720/fstab @@ -0,0 +1,6 @@ +/dev/mtdblock1 / jffs2 rw,noatime 1 1 +proc /proc proc defaults 0 0 +/dev/hda1 /mnt/cf auto defaults,sync,noauto 0 0 +tmpfs /var tmpfs defaults 0 0 +tmpfs /mnt/ram tmpfs defaults 0 0 +devpts /dev/pts devpts defaults 0 0 \ No newline at end of file diff --git a/meta/packages/base-files/base-files/licenses/Artistic b/meta/packages/base-files/base-files/licenses/Artistic new file mode 100644 index 000000000..5f221241e --- /dev/null +++ b/meta/packages/base-files/base-files/licenses/Artistic @@ -0,0 +1,131 @@ + + + + + The "Artistic License" + + Preamble + +The intent of this document is to state the conditions under which a +Package may be copied, such that the Copyright Holder maintains some +semblance of artistic control over the development of the package, +while giving the users of the package the right to use and distribute +the Package in a more-or-less customary fashion, plus the right to make +reasonable modifications. + +Definitions: + + "Package" refers to the collection of files distributed by the + Copyright Holder, and derivatives of that collection of files + created through textual modification. + + "Standard Version" refers to such a Package if it has not been + modified, or has been modified in accordance with the wishes + of the Copyright Holder as specified below. + + "Copyright Holder" is whoever is named in the copyright or + copyrights for the package. + + "You" is you, if you're thinking about copying or distributing + this Package. + + "Reasonable copying fee" is whatever you can justify on the + basis of media cost, duplication charges, time of people involved, + and so on. (You will not be required to justify it to the + Copyright Holder, but only to the computing community at large + as a market that must bear the fee.) + + "Freely Available" means that no fee is charged for the item + itself, though there may be fees involved in handling the item. + It also means that recipients of the item may redistribute it + under the same conditions they received it. + +1. You may make and give away verbatim copies of the source form of the +Standard Version of this Package without restriction, provided that you +duplicate all of the original copyright notices and associated disclaimers. + +2. You may apply bug fixes, portability fixes and other modifications +derived from the Public Domain or from the Copyright Holder. A Package +modified in such a way shall still be considered the Standard Version. + +3. You may otherwise modify your copy of this Package in any way, provided +that you insert a prominent notice in each changed file stating how and +when you changed that file, and provided that you do at least ONE of the +following: + + a) place your modifications in the Public Domain or otherwise make them + Freely Available, such as by posting said modifications to Usenet or + an equivalent medium, or placing the modifications on a major archive + site such as uunet.uu.net, or by allowing the Copyright Holder to include + your modifications in the Standard Version of the Package. + + b) use the modified Package only within your corporation or organization. + + c) rename any non-standard executables so the names do not conflict + with standard executables, which must also be provided, and provide + a separate manual page for each non-standard executable that clearly + documents how it differs from the Standard Version. + + d) make other distribution arrangements with the Copyright Holder. + +4. You may distribute the programs of this Package in object code or +executable form, provided that you do at least ONE of the following: + + a) distribute a Standard Version of the executables and library files, + together with instructions (in the manual page or equivalent) on where + to get the Standard Version. + + b) accompany the distribution with the machine-readable source of + the Package with your modifications. + + c) give non-standard executables non-standard names, and clearly + document the differences in manual pages (or equivalent), together + with instructions on where to get the Standard Version. + + d) make other distribution arrangements with the Copyright Holder. + +5. You may charge a reasonable copying fee for any distribution of this +Package. You may charge any fee you choose for support of this +Package. You may not charge a fee for this Package itself. However, +you may distribute this Package in aggregate with other (possibly +commercial) programs as part of a larger (possibly commercial) software +distribution provided that you do not advertise this Package as a +product of your own. You may embed this Package's interpreter within +an executable of yours (by linking); this shall be construed as a mere +form of aggregation, provided that the complete Standard Version of the +interpreter is so embedded. + +6. The scripts and library files supplied as input to or produced as +output from the programs of this Package do not automatically fall +under the copyright of this Package, but belong to whoever generated +them, and may be sold commercially, and may be aggregated with this +Package. If such scripts or library files are aggregated with this +Package via the so-called "undump" or "unexec" methods of producing a +binary executable image, then distribution of such an image shall +neither be construed as a distribution of this Package nor shall it +fall under the restrictions of Paragraphs 3 and 4, provided that you do +not represent such an executable image as a Standard Version of this +Package. + +7. C subroutines (or comparably compiled subroutines in other +languages) supplied by you and linked into this Package in order to +emulate subroutines and variables of the language defined by this +Package shall not be considered part of this Package, but are the +equivalent of input as in Paragraph 6, provided these subroutines do +not change the language in any way that would cause it to fail the +regression tests for the language. + +8. Aggregation of this Package with a commercial distribution is always +permitted provided that the use of this Package is embedded; that is, +when no overt attempt is made to make this Package's interfaces visible +to the end user of the commercial distribution. Such use shall not be +construed as a distribution of this Package. + +9. The name of the Copyright Holder may not be used to endorse or promote +products derived from this software without specific prior written permission. + +10. THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR +IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED +WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. + + The End diff --git a/meta/packages/base-files/base-files/licenses/BSD b/meta/packages/base-files/base-files/licenses/BSD new file mode 100644 index 000000000..c7a0aa4f9 --- /dev/null +++ b/meta/packages/base-files/base-files/licenses/BSD @@ -0,0 +1,26 @@ +Copyright (c) The Regents of the University of California. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. +3. Neither the name of the University nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +SUCH DAMAGE. diff --git a/meta/packages/base-files/base-files/licenses/GPL-2 b/meta/packages/base-files/base-files/licenses/GPL-2 new file mode 100644 index 000000000..d60c31a97 --- /dev/null +++ b/meta/packages/base-files/base-files/licenses/GPL-2 @@ -0,0 +1,340 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. diff --git a/meta/packages/base-files/base-files/licenses/LGPL-2 b/meta/packages/base-files/base-files/licenses/LGPL-2 new file mode 100644 index 000000000..f5030495b --- /dev/null +++ b/meta/packages/base-files/base-files/licenses/LGPL-2 @@ -0,0 +1,481 @@ + GNU LIBRARY GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1991 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the library GPL. It is + numbered 2 because it goes with version 2 of the ordinary GPL.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Library General Public License, applies to some +specially designated Free Software Foundation software, and to any +other libraries whose authors decide to use it. You can use it for +your libraries, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if +you distribute copies of the library, or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link a program with the library, you must provide +complete object files to the recipients so that they can relink them +with the library, after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + Our method of protecting your rights has two steps: (1) copyright +the library, and (2) offer you this license which gives you legal +permission to copy, distribute and/or modify the library. + + Also, for each distributor's protection, we want to make certain +that everyone understands that there is no warranty for this free +library. If the library is modified by someone else and passed on, we +want its recipients to know that what they have is not the original +version, so that any problems introduced by others will not reflect on +the original authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that companies distributing free +software will individually obtain patent licenses, thus in effect +transforming the program into proprietary software. To prevent this, +we have made it clear that any patent must be licensed for everyone's +free use or not licensed at all. + + Most GNU software, including some libraries, is covered by the ordinary +GNU General Public License, which was designed for utility programs. This +license, the GNU Library General Public License, applies to certain +designated libraries. This license is quite different from the ordinary +one; be sure to read it in full, and don't assume that anything in it is +the same as in the ordinary license. + + The reason we have a separate public license for some libraries is that +they blur the distinction we usually make between modifying or adding to a +program and simply using it. Linking a program with a library, without +changing the library, is in some sense simply using the library, and is +analogous to running a utility program or application program. However, in +a textual and legal sense, the linked executable is a combined work, a +derivative of the original library, and the ordinary General Public License +treats it as such. + + Because of this blurred distinction, using the ordinary General +Public License for libraries did not effectively promote software +sharing, because most developers did not use the libraries. We +concluded that weaker conditions might promote sharing better. + + However, unrestricted linking of non-free programs would deprive the +users of those programs of all benefit from the free status of the +libraries themselves. This Library General Public License is intended to +permit developers of non-free programs to use free libraries, while +preserving your freedom as a user of such programs to change the free +libraries that are incorporated in them. (We have not seen how to achieve +this as regards changes in header files, but we have achieved it as regards +changes in the actual functions of the Library.) The hope is that this +will lead to faster development of free libraries. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, while the latter only +works together with the library. + + Note that it is possible for a library to be covered by the ordinary +General Public License rather than by this special one. + + GNU LIBRARY GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library which +contains a notice placed by the copyright holder or other authorized +party saying it may be distributed under the terms of this Library +General Public License (also called "this License"). Each licensee is +addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also compile or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + c) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + d) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the source code distributed need not include anything that is normally +distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Library General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Libraries + + If you develop a new library, and you want it to be of the greatest +possible use to the public, we recommend making it free software that +everyone can redistribute and change. You can do so by permitting +redistribution under these terms (or, alternatively, under the terms of the +ordinary General Public License). + + To apply these terms, attach the following notices to the library. It is +safest to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least the +"copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + +Also add information on how to contact you by electronic and paper mail. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the library, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the + library `Frob' (a library for tweaking knobs) written by James Random Hacker. + + , 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! diff --git a/meta/packages/base-files/base-files/licenses/LGPL-2.1 b/meta/packages/base-files/base-files/licenses/LGPL-2.1 new file mode 100644 index 000000000..b124cf581 --- /dev/null +++ b/meta/packages/base-files/base-files/licenses/LGPL-2.1 @@ -0,0 +1,510 @@ + + GNU LESSER GENERAL PUBLIC LICENSE + Version 2.1, February 1999 + + Copyright (C) 1991, 1999 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the Lesser GPL. It also counts + as the successor of the GNU Library Public License, version 2, hence + the version number 2.1.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Lesser General Public License, applies to some +specially designated software packages--typically libraries--of the +Free Software Foundation and other authors who decide to use it. You +can use it too, but we suggest you first think carefully about whether +this license or the ordinary General Public License is the better +strategy to use in any particular case, based on the explanations +below. + + When we speak of free software, we are referring to freedom of use, +not price. Our General Public Licenses are designed to make sure that +you have the freedom to distribute copies of free software (and charge +for this service if you wish); that you receive source code or can get +it if you want it; that you can change the software and use pieces of +it in new free programs; and that you are informed that you can do +these things. + + To protect your rights, we need to make restrictions that forbid +distributors to deny you these rights or to ask you to surrender these +rights. These restrictions translate to certain responsibilities for +you if you distribute copies of the library or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link other code with the library, you must provide +complete object files to the recipients, so that they can relink them +with the library after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + We protect your rights with a two-step method: (1) we copyright the +library, and (2) we offer you this license, which gives you legal +permission to copy, distribute and/or modify the library. + + To protect each distributor, we want to make it very clear that +there is no warranty for the free library. Also, if the library is +modified by someone else and passed on, the recipients should know +that what they have is not the original version, so that the original +author's reputation will not be affected by problems that might be +introduced by others. + + Finally, software patents pose a constant threat to the existence of +any free program. We wish to make sure that a company cannot +effectively restrict the users of a free program by obtaining a +restrictive license from a patent holder. Therefore, we insist that +any patent license obtained for a version of the library must be +consistent with the full freedom of use specified in this license. + + Most GNU software, including some libraries, is covered by the +ordinary GNU General Public License. This license, the GNU Lesser +General Public License, applies to certain designated libraries, and +is quite different from the ordinary General Public License. We use +this license for certain libraries in order to permit linking those +libraries into non-free programs. + + When a program is linked with a library, whether statically or using +a shared library, the combination of the two is legally speaking a +combined work, a derivative of the original library. The ordinary +General Public License therefore permits such linking only if the +entire combination fits its criteria of freedom. The Lesser General +Public License permits more lax criteria for linking other code with +the library. + + We call this license the "Lesser" General Public License because it +does Less to protect the user's freedom than the ordinary General +Public License. It also provides other free software developers Less +of an advantage over competing non-free programs. These disadvantages +are the reason we use the ordinary General Public License for many +libraries. However, the Lesser license provides advantages in certain +special circumstances. + + For example, on rare occasions, there may be a special need to +encourage the widest possible use of a certain library, so that it +becomes a de-facto standard. To achieve this, non-free programs must +be allowed to use the library. A more frequent case is that a free +library does the same job as widely used non-free libraries. In this +case, there is little to gain by limiting the free library to free +software only, so we use the Lesser General Public License. + + In other cases, permission to use a particular library in non-free +programs enables a greater number of people to use a large body of +free software. For example, permission to use the GNU C Library in +non-free programs enables many more people to use the whole GNU +operating system, as well as its variant, the GNU/Linux operating +system. + + Although the Lesser General Public License is Less protective of the +users' freedom, it does ensure that the user of a program that is +linked with the Library has the freedom and the wherewithal to run +that program using a modified version of the Library. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, whereas the latter must +be combined with the library in order to run. + + GNU LESSER GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library or other +program which contains a notice placed by the copyright holder or +other authorized party saying it may be distributed under the terms of +this Lesser General Public License (also called "this License"). +Each licensee is addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control +compilation and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also combine or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (1) uses at run time a + copy of the library already present on the user's computer system, + rather than copying library functions into the executable, and (2) + will operate properly with a modified version of the library, if + the user installs one, as long as the modified version is + interface-compatible with the version that the work was made with. + + c) Accompany the work with a written offer, valid for at least + three years, to give the same user the materials specified in + Subsection 6a, above, for a charge no more than the cost of + performing this distribution. + + d) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + e) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the materials to be distributed need not include anything that is +normally distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties with +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply, and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License +may add an explicit geographical distribution limitation excluding those +countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Lesser General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Libraries + + If you develop a new library, and you want it to be of the greatest +possible use to the public, we recommend making it free software that +everyone can redistribute and change. You can do so by permitting +redistribution under these terms (or, alternatively, under the terms +of the ordinary General Public License). + + To apply these terms, attach the following notices to the library. +It is safest to attach them to the start of each source file to most +effectively convey the exclusion of warranty; and each file should +have at least the "copyright" line and a pointer to where the full +notice is found. + + + + Copyright (C) + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + +Also add information on how to contact you by electronic and paper mail. + +You should also get your employer (if you work as a programmer) or +your school, if any, to sign a "copyright disclaimer" for the library, +if necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the + library `Frob' (a library for tweaking knobs) written by James + Random Hacker. + + , 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! + + diff --git a/meta/packages/base-files/base-files/motd b/meta/packages/base-files/base-files/motd new file mode 100644 index 000000000..e69de29bb diff --git a/meta/packages/base-files/base-files/mtx-1/fstab b/meta/packages/base-files/base-files/mtx-1/fstab new file mode 100644 index 000000000..ffab21cf6 --- /dev/null +++ b/meta/packages/base-files/base-files/mtx-1/fstab @@ -0,0 +1,8 @@ +# /etc/fstab: static file system information. mtx-1 +# +# +rootfs / auto defaults 1 1 +tmpfs /var tmpfs size=10m 0 0 +proc /proc proc defaults 0 0 +devpts /dev/pts devpts mode=0620,gid=5 0 0 +usbdevfs /proc/bus/usb usbdevfs noauto 0 0 diff --git a/meta/packages/base-files/base-files/mtx-1/profile b/meta/packages/base-files/base-files/mtx-1/profile new file mode 100644 index 000000000..bedf2fc7d --- /dev/null +++ b/meta/packages/base-files/base-files/mtx-1/profile @@ -0,0 +1,25 @@ +# /etc/profile: system-wide .profile file for the Bourne shell (sh(1)) +# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...). + +PATH="/usr/local/bin:/usr/bin:/bin" + +if [ "`id -u`" -eq 0 ]; then + PATH=$PATH:/usr/local/sbin:/usr/sbin:/sbin: +fi +if [ "$PS1" ]; then +# works for bash and ash (no other shells known to be in use here) + PS1='\u@\h:\w\$ ' +fi + +if [ -d /etc/profile.d ]; then + for i in `ls /etc/profile.d/`; do + . /etc/profile.d/$i + done + unset i +fi + +export PATH PS1 + +umask 022 + +alias ll="ls -lah" \ No newline at end of file diff --git a/meta/packages/base-files/base-files/netvista/fstab b/meta/packages/base-files/base-files/netvista/fstab new file mode 100644 index 000000000..e235acaa2 --- /dev/null +++ b/meta/packages/base-files/base-files/netvista/fstab @@ -0,0 +1,5 @@ +/dev/hdc2 / ext2 rw,noatime 1 1 +tmpfs /var tmpfs defaults 0 0 +proc /proc proc defaults 0 0 +tmpfs /tmp tmpfs defaults 0 0 +devfs /dev/devfs devfs defaults 0 0 diff --git a/meta/packages/base-files/base-files/nokia770/fstab b/meta/packages/base-files/base-files/nokia770/fstab new file mode 100644 index 000000000..68b56b63e --- /dev/null +++ b/meta/packages/base-files/base-files/nokia770/fstab @@ -0,0 +1,6 @@ +rootfs / rootfs defaults,errors=remount-ro,noatime 0 0 +/dev/mmcblk0p1 /media/card auto defaults,noauto,noatime,exec,suid 0 0 +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 +proc /proc proc defaults 0 0 +usbdevfs /proc/bus/usb usbdevfs noauto 0 0 diff --git a/meta/packages/base-files/base-files/nsswitch.conf b/meta/packages/base-files/base-files/nsswitch.conf new file mode 100644 index 000000000..06f03d22a --- /dev/null +++ b/meta/packages/base-files/base-files/nsswitch.conf @@ -0,0 +1,19 @@ +# /etc/nsswitch.conf +# +# Example configuration of GNU Name Service Switch functionality. +# If you have the `glibc-doc' and `info' packages installed, try: +# `info libc "Name Service Switch"' for information about this file. + +passwd: compat +group: compat +shadow: compat + +hosts: files dns +networks: files + +protocols: db files +services: db files +ethers: db files +rpc: db files + +netgroup: nis diff --git a/meta/packages/base-files/base-files/nylon/issue b/meta/packages/base-files/base-files/nylon/issue new file mode 100644 index 000000000..15de9b8eb --- /dev/null +++ b/meta/packages/base-files/base-files/nylon/issue @@ -0,0 +1,2 @@ +Nylon Mesh Router Linux \n \l + diff --git a/meta/packages/base-files/base-files/nylon/issue.net b/meta/packages/base-files/base-files/nylon/issue.net new file mode 100644 index 000000000..93565c98c --- /dev/null +++ b/meta/packages/base-files/base-files/nylon/issue.net @@ -0,0 +1,3 @@ +Nylon Mesh Router Linux %h + + diff --git a/meta/packages/base-files/base-files/openmn/fstab b/meta/packages/base-files/base-files/openmn/fstab new file mode 100644 index 000000000..a2e78a201 --- /dev/null +++ b/meta/packages/base-files/base-files/openmn/fstab @@ -0,0 +1,6 @@ +devfs /dev devfs defaults 0 0 +proc /proc proc defaults 0 0 +none /sys sysfs defaults 0 0 +rootfs / rootfs rw 1 1 +tmpfs /var tmpfs defaults 0 0 +tmpfs /tmp tmpfs defaults 0 0 diff --git a/meta/packages/base-files/base-files/openmn/issue b/meta/packages/base-files/base-files/openmn/issue new file mode 100644 index 000000000..8c70d49b3 --- /dev/null +++ b/meta/packages/base-files/base-files/openmn/issue @@ -0,0 +1,2 @@ +M&N 5.4 + diff --git a/meta/packages/base-files/base-files/openmn/issue.net b/meta/packages/base-files/base-files/openmn/issue.net new file mode 100644 index 000000000..8c70d49b3 --- /dev/null +++ b/meta/packages/base-files/base-files/openmn/issue.net @@ -0,0 +1,2 @@ +M&N 5.4 + diff --git a/meta/packages/base-files/base-files/openmn/profile b/meta/packages/base-files/base-files/openmn/profile new file mode 100644 index 000000000..2b01071e1 --- /dev/null +++ b/meta/packages/base-files/base-files/openmn/profile @@ -0,0 +1,31 @@ +# /etc/profile: system-wide .profile file for the Bourne shell (sh(1)) +# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...). + +OPIEDIR=/opt/QtPalmtop +QPEDIR=/opt/QtPalmtop +QTDIR=/opt/QtPalmtop +PATH="/opt/QtPalmtop/bin:/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games" + +PS1='$ ' +if [ "`id -u`" -eq 0 ]; then + PATH=$PATH:/usr/local/sbin:/usr/sbin:/sbin: + PS1='# ' +fi + +if [ -d /etc/profile.d ]; then + for i in `ls /etc/profile.d/`; do + . /etc/profile.d/$i + done + unset i +fi + +case "`cat /proc/sys/board/lcd_type`" in + 2) export QWS_DISPLAY=Transformed:Rot90 ;; + 3) export QWS_DISPLAY=Transformed:Rot270 ;; + *) export QWS_DISPLAY=Transformed:Rot180 ;; +esac +alias ll="ls -lAF" + +export PATH PS1 OPIEDIR QPEDIR QTDIR + +umask 022 diff --git a/meta/packages/base-files/base-files/openmn/usbd b/meta/packages/base-files/base-files/openmn/usbd new file mode 100644 index 000000000..40931ee8e --- /dev/null +++ b/meta/packages/base-files/base-files/openmn/usbd @@ -0,0 +1 @@ +usbdmodule=pxa_bi diff --git a/meta/packages/base-files/base-files/opensimpad/issue b/meta/packages/base-files/base-files/opensimpad/issue new file mode 100644 index 000000000..05a1eeaea --- /dev/null +++ b/meta/packages/base-files/base-files/opensimpad/issue @@ -0,0 +1,2 @@ +OpenSIMpad Unofficial Snapshot Version \n \l + diff --git a/meta/packages/base-files/base-files/opensimpad/issue.net b/meta/packages/base-files/base-files/opensimpad/issue.net new file mode 100644 index 000000000..6d524cc65 --- /dev/null +++ b/meta/packages/base-files/base-files/opensimpad/issue.net @@ -0,0 +1,2 @@ +OpenSIMpad Unofficial Snapshot %h + diff --git a/meta/packages/base-files/base-files/openzaurus/issue b/meta/packages/base-files/base-files/openzaurus/issue new file mode 100644 index 000000000..1983c1531 --- /dev/null +++ b/meta/packages/base-files/base-files/openzaurus/issue @@ -0,0 +1,2 @@ +OpenZaurus Unofficial Snapshot Version \n \l + diff --git a/meta/packages/base-files/base-files/openzaurus/issue.net b/meta/packages/base-files/base-files/openzaurus/issue.net new file mode 100644 index 000000000..17bc7423f --- /dev/null +++ b/meta/packages/base-files/base-files/openzaurus/issue.net @@ -0,0 +1,2 @@ +OpenZaurus Unofficial Snapshot %h + diff --git a/meta/packages/base-files/base-files/poodle/fstab b/meta/packages/base-files/base-files/poodle/fstab new file mode 100644 index 000000000..06b967250 --- /dev/null +++ b/meta/packages/base-files/base-files/poodle/fstab @@ -0,0 +1,13 @@ +/dev/mtdblock2 / jffs2 rw,noatime 1 1 +/dev/mtdblock3 /home jffs2 defaults,noatime 1 2 +proc /proc proc defaults 0 0 +/dev/hda1 /media/cf auto defaults,sync,noauto 0 0 + +# SD/MMC in kernel 2.6 +/dev/mmcblk0p1 /media/card auto defaults,sync,noauto 0 0 + +# SD/MMC in kernel 2.4 +/dev/mmcda1 /media/card auto defaults,sync,noauto 0 0 + +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 diff --git a/meta/packages/base-files/base-files/poodle/usbd b/meta/packages/base-files/base-files/poodle/usbd new file mode 100644 index 000000000..40931ee8e --- /dev/null +++ b/meta/packages/base-files/base-files/poodle/usbd @@ -0,0 +1 @@ +usbdmodule=pxa_bi diff --git a/meta/packages/base-files/base-files/profile b/meta/packages/base-files/base-files/profile new file mode 100644 index 000000000..a4c16944b --- /dev/null +++ b/meta/packages/base-files/base-files/profile @@ -0,0 +1,32 @@ +# /etc/profile: system-wide .profile file for the Bourne shell (sh(1)) +# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...). + +PATH="/usr/local/bin:/usr/bin:/bin" +EDITOR="/bin/vi" # needed for packages like cron +TERM="vt100" # Basic terminal capab. For screen etc. + +if [ ! -e /etc/localtime ]; then + TZ="UTC" # Time Zone. Look at http://theory.uwinnipeg.ca/gnu/glibc/libc_303.html + # for an explanation of how to set this to your local timezone. + export TZ +fi + +if [ "`id -u`" -eq 0 ]; then + PATH=$PATH:/usr/local/sbin:/usr/sbin:/sbin: +fi +if [ "$PS1" ]; then +# works for bash and ash (no other shells known to be in use here) + PS1='\u@\h:\w\$ ' +fi + +if [ -d /etc/profile.d ]; then + for i in `ls /etc/profile.d/`; do + . /etc/profile.d/$i + done + unset i +fi + +export PATH PS1 OPIEDIR QPEDIR QTDIR EDITOR TERM + +umask 022 + diff --git a/meta/packages/base-files/base-files/share/dot.bashrc b/meta/packages/base-files/base-files/share/dot.bashrc new file mode 100644 index 000000000..4be63686c --- /dev/null +++ b/meta/packages/base-files/base-files/share/dot.bashrc @@ -0,0 +1,16 @@ +# ~/.bashrc: executed by bash(1) for non-login shells. + +export PS1='\h:\w\$ ' +umask 022 + +# You may uncomment the following lines if you want `ls' to be colorized: +# export LS_OPTIONS='--color=auto' +# eval `dircolors` +# alias ls='ls $LS_OPTIONS' +# alias ll='ls $LS_OPTIONS -l' +# alias l='ls $LS_OPTIONS -lA' +# +# Some more alias to avoid making mistakes: +# alias rm='rm -i' +# alias cp='cp -i' +# alias mv='mv -i' diff --git a/meta/packages/base-files/base-files/share/dot.profile b/meta/packages/base-files/base-files/share/dot.profile new file mode 100644 index 000000000..979793e8b --- /dev/null +++ b/meta/packages/base-files/base-files/share/dot.profile @@ -0,0 +1,10 @@ +# ~/.profile: executed by Bourne-compatible login shells. + +if [ -f ~/.bashrc ]; then + . ~/.bashrc +fi + +# path set by /etc/profile +# export PATH + +mesg n diff --git a/meta/packages/base-files/base-files/simpad/fstab b/meta/packages/base-files/base-files/simpad/fstab new file mode 100644 index 000000000..51aaaf925 --- /dev/null +++ b/meta/packages/base-files/base-files/simpad/fstab @@ -0,0 +1,8 @@ +rootfs / auto defaults 1 1 +proc /proc proc defaults 0 0 +devpts /dev/pts devpts mode=0620,gid=5 0 0 +usbdevfs /proc/bus/usb usbdevfs noauto 0 0 +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 +/dev/mtdblock/2 /home jffs2 defaults 1 1 +/dev/hda1 /media/cf auto noauto,owner 0 0 diff --git a/meta/packages/base-files/base-files/spitz/fstab b/meta/packages/base-files/base-files/spitz/fstab new file mode 100644 index 000000000..3d0e508df --- /dev/null +++ b/meta/packages/base-files/base-files/spitz/fstab @@ -0,0 +1,28 @@ +# don't mount /dev/mtdblock2 since Spitz uses pivot_root +# or 2.6 directly boots from the hdd +# /dev/mtdblock2 / jffs2 rw,noatime 1 1 +rootfs / auto defaults 1 1 +proc /proc proc defaults 0 0 +# we can use a normal var filesystem with a microdrive +# tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 + +# Compact Flash memory cards +/dev/hdc1 /media/cf auto defaults,sync,noauto 0 0 +# SD/MMC in kernel 2.4 +/dev/mmcda1 /media/card auto defaults,sync,noauto 0 0 +# SD/MMC in kernel 2.6 +/dev/mmcblk0p1 /media/card auto defaults,sync,noauto 0 0 + +# +# USB +# +/dev/sda1 /media/usbhdd vfat noauto,umask=000,noatime,iocharset=utf8,codepage=932 0 0 +devpts /dev/pts devpts mode=0620,gid=5 0 0 +usbfs /proc/bus/usb usbfs noauto 0 0 + +# +# Harddisk +# +/dev/hda2 /home ext3 defaults 0 0 +/dev/hda3 /media/hdd vfat defaults 0 0 diff --git a/meta/packages/base-files/base-files/tosa/fstab b/meta/packages/base-files/base-files/tosa/fstab new file mode 100644 index 000000000..fb37e07ae --- /dev/null +++ b/meta/packages/base-files/base-files/tosa/fstab @@ -0,0 +1,12 @@ +/dev/mtdblock2 / jffs2 rw,noatime 1 1 +/dev/mtdblock3 /home jffs2 defaults,noatime 1 2 +proc /proc proc defaults 0 0 +/dev/hda1 /media/cf auto defaults,sync,noauto 0 0 + +tmpfs /var tmpfs defaults 0 0 +tmpfs /media/ram tmpfs defaults 0 0 + +# SD/MMC in kernel 2.4 +/dev/mmcda1 /media/card auto defaults,sync,noauto 0 0 +# SD/MMC in kernel 2.6 +/dev/mmcblk0p1 /media/card auto defaults,sync,noauto 0 0 diff --git a/meta/packages/base-files/base-files/tosa/usbd b/meta/packages/base-files/base-files/tosa/usbd new file mode 100644 index 000000000..40931ee8e --- /dev/null +++ b/meta/packages/base-files/base-files/tosa/usbd @@ -0,0 +1 @@ +usbdmodule=pxa_bi diff --git a/meta/packages/base-files/base-files/usbd b/meta/packages/base-files/base-files/usbd new file mode 100644 index 000000000..e69de29bb diff --git a/meta/packages/base-files/base-files/wrt54/fstab b/meta/packages/base-files/base-files/wrt54/fstab new file mode 100644 index 000000000..c1e52f892 --- /dev/null +++ b/meta/packages/base-files/base-files/wrt54/fstab @@ -0,0 +1,7 @@ +# /etc/fstab: static file system information. wrt +# +# +rootfs / auto defaults 1 1 +tmpfs /var tmpfs size=50% 0 0 +proc /proc proc defaults 0 0 +devpts /dev/pts devpts mode=0620,gid=5 0 0 diff --git a/meta/packages/base-files/base-files/wrt54/profile b/meta/packages/base-files/base-files/wrt54/profile new file mode 100644 index 000000000..bedf2fc7d --- /dev/null +++ b/meta/packages/base-files/base-files/wrt54/profile @@ -0,0 +1,25 @@ +# /etc/profile: system-wide .profile file for the Bourne shell (sh(1)) +# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...). + +PATH="/usr/local/bin:/usr/bin:/bin" + +if [ "`id -u`" -eq 0 ]; then + PATH=$PATH:/usr/local/sbin:/usr/sbin:/sbin: +fi +if [ "$PS1" ]; then +# works for bash and ash (no other shells known to be in use here) + PS1='\u@\h:\w\$ ' +fi + +if [ -d /etc/profile.d ]; then + for i in `ls /etc/profile.d/`; do + . /etc/profile.d/$i + done + unset i +fi + +export PATH PS1 + +umask 022 + +alias ll="ls -lah" \ No newline at end of file diff --git a/meta/packages/base-files/base-files/xxs1500/fstab b/meta/packages/base-files/base-files/xxs1500/fstab new file mode 100644 index 000000000..7007ab021 --- /dev/null +++ b/meta/packages/base-files/base-files/xxs1500/fstab @@ -0,0 +1,8 @@ +# /etc/fstab: static file system information. +# +# +rootfs / auto defaults 1 1 +tmpfs /var tmpfs size=10m 0 0 +proc /proc proc defaults 0 0 +devpts /dev/pts devpts mode=0620,gid=5 0 0 +usbdevfs /proc/bus/usb usbdevfs noauto 0 0 diff --git a/meta/packages/base-files/base-files_3.0.14.bb b/meta/packages/base-files/base-files_3.0.14.bb new file mode 100644 index 000000000..866c01696 --- /dev/null +++ b/meta/packages/base-files/base-files_3.0.14.bb @@ -0,0 +1,154 @@ +DESCRIPTION = "Miscellaneous files for the base system." +SECTION = "base" +PRIORITY = "required" +PR = "r51" +LICENSE = "GPL" + +SRC_URI = " \ + file://nsswitch.conf \ + file://motd \ + file://inputrc \ + file://host.conf \ + file://profile \ + file://fstab \ + file://filesystems \ + file://issue.net \ + file://issue \ + file://usbd \ + file://share/dot.bashrc \ + file://share/dot.profile \ + file://licenses/BSD \ + file://licenses/GPL-2 \ + file://licenses/LGPL-2 \ + file://licenses/LGPL-2.1 \ + file://licenses/Artistic " +S = "${WORKDIR}" + +docdir_append = "/${P}" +dirs1777 = "/tmp ${localstatedir}/lock ${localstatedir}/tmp" +dirs2775 = "/home ${prefix}/src ${localstatedir}/local" +dirs755 = "/bin /boot /dev ${sysconfdir} ${sysconfdir}/default \ + ${sysconfdir}/skel /lib /mnt /proc /home/root /sbin \ + ${prefix} ${bindir} ${docdir} /usr/games ${includedir} \ + ${libdir} ${sbindir} ${datadir} \ + ${datadir}/common-licenses ${datadir}/dict ${infodir} \ + ${mandir} ${datadir}/misc ${localstatedir} \ + ${localstatedir}/backups ${localstatedir}/cache \ + ${localstatedir}/lib /sys ${localstatedir}/lib/misc \ + ${localstatedir}/lock/subsys ${localstatedir}/log \ + ${localstatedir}/run ${localstatedir}/spool \ + /mnt /media /media/card /media/cf /media/net /media/ram \ + /media/union /media/realroot /media/hdd \ + /media/mmc1" +conffiles = "${sysconfdir}/debian_version ${sysconfdir}/host.conf \ + ${sysconfdir}/inputrc ${sysconfdir}/issue /${sysconfdir}/issue.net \ + ${sysconfdir}/nsswitch.conf ${sysconfdir}/profile \ + ${sysconfdir}/default" + +# +# set standard hostname, might be a candidate for a DISTRO variable? :M: +# +hostname = "openembedded" +hostname_slugos = "nslu2" +hostname_mnci = "MNCI" +hostname_rt3000 = "MNRT" + +do_install () { + for d in ${dirs755}; do + install -m 0755 -d ${D}$d + done + for d in ${dirs1777}; do + install -m 1777 -d ${D}$d + done + for d in ${dirs2775}; do + install -m 2755 -d ${D}$d + done + for d in card cf net ram; do + ln -sf /media/$d ${D}/mnt/$d + done + + if [ -n "${MACHINE}" -a "${hostname}" = "openembedded" ]; then + echo ${MACHINE} > ${D}${sysconfdir}/hostname + else + echo ${hostname} > ${D}${sysconfdir}/hostname + fi + + if [ -n "${DISTRO_NAME}" ]; then + echo -n "${DISTRO_NAME} " > ${D}${sysconfdir}/issue + echo -n "${DISTRO_NAME} " > ${D}${sysconfdir}/issue.net + if [ -n "${DISTRO_VERSION}" ]; then + echo -n "${DISTRO_VERSION} " >> ${D}${sysconfdir}/issue + echo -n "${DISTRO_VERSION} " >> ${D}${sysconfdir}/issue.net + fi + echo "\n \l" >> ${D}${sysconfdir}/issue + echo >> ${D}${sysconfdir}/issue + echo "%h" >> ${D}${sysconfdir}/issue.net + echo >> ${D}${sysconfdir}/issue.net + else + install -m 0644 ${WORKDIR}/issue ${D}${sysconfdir}/issue + install -m 0644 ${WORKDIR}/issue.net ${D}${sysconfdir}/issue.net + fi + + install -m 0644 ${WORKDIR}/fstab ${D}${sysconfdir}/fstab + install -m 0644 ${WORKDIR}/filesystems ${D}${sysconfdir}/filesystems + install -m 0644 ${WORKDIR}/usbd ${D}${sysconfdir}/default/usbd + install -m 0644 ${WORKDIR}/profile ${D}${sysconfdir}/profile + install -m 0755 ${WORKDIR}/share/dot.profile ${D}${sysconfdir}/skel/.profile + install -m 0755 ${WORKDIR}/share/dot.bashrc ${D}${sysconfdir}/skel/.bashrc + install -m 0644 ${WORKDIR}/inputrc ${D}${sysconfdir}/inputrc + install -m 0644 ${WORKDIR}/nsswitch.conf ${D}${sysconfdir}/nsswitch.conf + install -m 0644 ${WORKDIR}/host.conf ${D}${sysconfdir}/host.conf + install -m 0644 ${WORKDIR}/motd ${D}${sysconfdir}/motd + + for license in BSD GPL-2 LGPL-2 LGPL-2.1 Artistic; do + install -m 0644 ${WORKDIR}/licenses/$license ${D}${datadir}/common-licenses/ + done + + ln -sf /proc/mounts ${D}${sysconfdir}/mtab +} + + +do_install_append_mnci () { + rmdir ${D}/tmp + mkdir -p ${D}${localstatedir}/tmp + ln -s var/tmp ${D}/tmp +} + +do_install_append_nylon() { + printf "" "" >${D}${sysconfdir}/resolv.conf + rm -r ${D}/mnt/* + rm -r ${D}/media + rm -rf ${D}/tmp + ln -sf /var/tmp ${D}/tmp +} + +do_install_append_slugos() { + printf "" "" >${D}${sysconfdir}/resolv.conf + rm -r ${D}/mnt/* + rmdir ${D}/home/root + install -m 0755 -d ${D}/root + ln -s ../root ${D}/home/root +} + +PACKAGES = "${PN}-doc ${PN}" +FILES_${PN} = "/" +FILES_${PN}-doc = "${docdir} ${datadir}/common-licenses" + +# M&N specific packaging +PACKAGE_ARCH_mnci = "mnci" +PACKAGE_ARCH_rt3000 = "rt3000" + +# Unslung distribution specific packaging + +PACKAGES_unslung = "${PN}-unslung" +PACKAGE_ARCH_${PN}-unslung = "nslu2" +MAINTAINER_${PN}-unslung = "NSLU2 Linux " +RDEPENDS_${PN}-unslung = "nslu2-linksys-ramdisk" +RPROVIDES_${PN}-unslung = "${PN}" + +FILES_${PN}-unslung = "" + +CONFFILES_${PN} = "${sysconfdir}/fstab ${sysconfdir}/hostname" +CONFFILES_${PN}_nylon = "${sysconfdir}/resolv.conf ${sysconfdir}/fstab ${sysconfdir}/hostname" +CONFFILES_${PN}_slugos = "${sysconfdir}/resolv.conf ${sysconfdir}/fstab ${sysconfdir}/hostname" + diff --git a/meta/packages/base-passwd/base-passwd-3.5.9/configure.patch b/meta/packages/base-passwd/base-passwd-3.5.9/configure.patch new file mode 100644 index 000000000..a9adb1e9e --- /dev/null +++ b/meta/packages/base-passwd/base-passwd-3.5.9/configure.patch @@ -0,0 +1,23 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- base-passwd/configure.in~configure ++++ base-passwd/configure.in +@@ -1,5 +1,6 @@ + dnl Initialize the autoconf process +-AC_INIT(update-passwd.c) ++AC_INIT ++AC_CONFIG_SRCDIR([update-passwd.c]) + AC_CONFIG_HEADER(config.h) + AC_PREFIX_DEFAULT(/usr) + +@@ -12,5 +13,6 @@ + AC_CHECK_FUNCS(putgrent) + + dnl Finally output everything +-AC_OUTPUT(Makefile) ++AC_CONFIG_FILES([Makefile]) ++AC_OUTPUT + diff --git a/meta/packages/base-passwd/base-passwd-3.5.9/mysql.patch b/meta/packages/base-passwd/base-passwd-3.5.9/mysql.patch new file mode 100644 index 000000000..b641f4123 --- /dev/null +++ b/meta/packages/base-passwd/base-passwd-3.5.9/mysql.patch @@ -0,0 +1,8 @@ +--- base-passwd/group.master.orig 2005-07-08 06:36:07.717990112 +0200 ++++ base-passwd/group.master 2005-07-08 06:36:32.000000000 +0200 +@@ -36,4 +36,5 @@ + staff:*:50: + games:*:60: + users:*:100: ++mysql:*:64001: + nogroup:*:65534: diff --git a/meta/packages/base-passwd/base-passwd-3.5.9/nobash.patch b/meta/packages/base-passwd/base-passwd-3.5.9/nobash.patch new file mode 100644 index 000000000..2bde9bf33 --- /dev/null +++ b/meta/packages/base-passwd/base-passwd-3.5.9/nobash.patch @@ -0,0 +1,13 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- base-passwd/passwd.master~nobash ++++ base-passwd/passwd.master +@@ -1,4 +1,4 @@ +-root::0:0:root:/root:/bin/bash ++root::0:0:root:/root:/bin/sh + daemon:*:1:1:daemon:/usr/sbin:/bin/sh + bin:*:2:2:bin:/bin:/bin/sh + sys:*:3:3:sys:/dev:/bin/sh diff --git a/meta/packages/base-passwd/base-passwd-3.5.9/root-home.patch b/meta/packages/base-passwd/base-passwd-3.5.9/root-home.patch new file mode 100644 index 000000000..85d96b618 --- /dev/null +++ b/meta/packages/base-passwd/base-passwd-3.5.9/root-home.patch @@ -0,0 +1,8 @@ +--- base-passwd/passwd.master.orig 2005-07-08 06:26:22.000000000 +0200 ++++ base-passwd/passwd.master 2005-07-08 06:31:58.000000000 +0200 +@@ -1,4 +1,4 @@ +-root::0:0:root:/root:/bin/sh ++root::0:0:root:/home/root:/bin/sh + daemon:*:1:1:daemon:/usr/sbin:/bin/sh + bin:*:2:2:bin:/bin:/bin/sh + sys:*:3:3:sys:/dev:/bin/sh diff --git a/meta/packages/base-passwd/base-passwd_3.5.9.bb b/meta/packages/base-passwd/base-passwd_3.5.9.bb new file mode 100644 index 000000000..6fcb211bd --- /dev/null +++ b/meta/packages/base-passwd/base-passwd_3.5.9.bb @@ -0,0 +1,59 @@ +DESCRIPTION = "Base system password/group files." +SECTION = "base" +PR = "r2" +LICENSE = "GPL" + +SRC_URI = "${DEBIAN_MIRROR}/main/b/base-passwd/base-passwd_${PV}.tar.gz \ + file://configure.patch;patch=1 \ + file://nobash.patch;patch=1 \ + file://root-home.patch;patch=1 \ + file://mysql.patch;patch=1" + +S = "${WORKDIR}/base-passwd" + +inherit autotools + +FILES_${PN}-doc += "${docdir}" + +do_install () { + install -d -m 755 ${D}${sbindir} + install -p -m 755 update-passwd ${D}${sbindir}/ + install -d -m 755 \ + ${D}${mandir}/man8 ${D}${mandir}/pl/man8 + install -p -m 644 man/update-passwd.8 \ + ${D}${mandir}/man8/ + install -p -m 644 man/update-passwd.pl.8 \ + ${D}${mandir}/pl/man8/update-passwd.8 + gzip -9 ${D}${mandir}/man8/* \ + ${D}${mandir}/pl/man8/* + install -d -m 755 ${D}${datadir}/base-passwd + install -p -m 644 passwd.master \ + ${D}${datadir}/base-passwd/ + install -p -m 644 group.master \ + ${D}${datadir}/base-passwd/ + + install -d -m 755 ${D}${docdir}/${PN} + install -p -m 644 debian/changelog ${D}${docdir}/${PN}/ + gzip -9 ${D}${docdir}/${PN}/* + install -p -m 644 README ${D}${docdir}/${PN}/ + install -p -m 644 debian/copyright ${D}${docdir}/${PN}/ +} + + +do_install_append_openmn() { + echo "0:Jn6tcg/qjqvUE:0:0:root:/root:/bin/sh" >>${D}${datadir}/base-passwd/passwd.master +} + + +pkg_postinst () { + set -e + + if [ ! -e $D${sysconfdir}/passwd ] ; then + cp $D${datadir}/base-passwd/passwd.master $D${sysconfdir}/passwd + fi + + if [ ! -e $D${sysconfdir}/group ] ; then + cp $D${datadir}/base-passwd/group.master $D${sysconfdir}/group + fi + exit 0 +} diff --git a/meta/packages/binutils/binutils-2.15.94.0.1/binutils-100_cflags_for_build.patch b/meta/packages/binutils/binutils-2.15.94.0.1/binutils-100_cflags_for_build.patch new file mode 100644 index 000000000..468808bf5 --- /dev/null +++ b/meta/packages/binutils/binutils-2.15.94.0.1/binutils-100_cflags_for_build.patch @@ -0,0 +1,91 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- src/bfd/doc/Makefile.am~binutils-100_cflags_for_build.patch ++++ src/bfd/doc/Makefile.am +@@ -55,10 +55,10 @@ + MKDOC = chew$(EXEEXT_FOR_BUILD) + + $(MKDOC): chew.o +- $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS) $(LOADLIBES) $(LDFLAGS) ++ $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS_FOR_BUILD) $(LOADLIBES) $(LDFLAGS_FOR_BUILD) + + chew.o: chew.c +- $(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS) $(srcdir)/chew.c ++ $(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS_FOR_BUILD) $(srcdir)/chew.c + + protos: libbfd.h libcoff.h bfd.h + +--- src/binutils/Makefile.am~binutils-100_cflags_for_build.patch ++++ src/binutils/Makefile.am +@@ -219,20 +219,20 @@ + ./sysinfo$(EXEEXT_FOR_BUILD) -d <$(srcdir)/sysroff.info >sysroff.h + + sysinfo$(EXEEXT_FOR_BUILD): sysinfo.o syslex.o +- $(CC_FOR_BUILD) $(CFLAGS) $(LDFLAGS) -o $@ sysinfo.o syslex.o ++ $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) -o $@ sysinfo.o syslex.o + + syslex.o: syslex.c sysinfo.h + if [ -r syslex.c ]; then \ +- $(CC_FOR_BUILD) -c -I. $(CFLAGS) syslex.c ; \ ++ $(CC_FOR_BUILD) -c -I. $(CFLAGS_FOR_BUILD) syslex.c ; \ + else \ +- $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(CFLAGS) $(srcdir)/syslex.c ;\ ++ $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(CFLAGS_FOR_BUILD) $(srcdir)/syslex.c ;\ + fi + + sysinfo.o: sysinfo.c + if [ -r sysinfo.c ]; then \ +- $(CC_FOR_BUILD) -c -I. $(CFLAGS) sysinfo.c ; \ ++ $(CC_FOR_BUILD) -c -I. $(CFLAGS_FOR_BUILD) sysinfo.c ; \ + else \ +- $(CC_FOR_BUILD) -c -I. $(CFLAGS) $(srcdir)/sysinfo.c ; \ ++ $(CC_FOR_BUILD) -c -I. $(CFLAGS_FOR_BUILD) $(srcdir)/sysinfo.c ; \ + fi + + # We need these for parallel make. +--- src/bfd/doc/Makefile.in~binutils-100_cflags_for_build.patch ++++ src/bfd/doc/Makefile.in +@@ -470,10 +470,10 @@ + + + $(MKDOC): chew.o +- $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS) $(LOADLIBES) $(LDFLAGS) ++ $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS_FOR_BUILD) $(LOADLIBES) $(LDFLAGS_FOR_BUILD) + + chew.o: chew.c +- $(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS) $(srcdir)/chew.c ++ $(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS_FOR_BUILD) $(srcdir)/chew.c + + protos: libbfd.h libcoff.h bfd.h + +--- src/binutils/Makefile.in~binutils-100_cflags_for_build.patch ++++ src/binutils/Makefile.in +@@ -978,20 +978,20 @@ + ./sysinfo$(EXEEXT_FOR_BUILD) -d <$(srcdir)/sysroff.info >sysroff.h + + sysinfo$(EXEEXT_FOR_BUILD): sysinfo.o syslex.o +- $(CC_FOR_BUILD) $(CFLAGS) $(LDFLAGS) -o $@ sysinfo.o syslex.o ++ $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) -o $@ sysinfo.o syslex.o + + syslex.o: syslex.c sysinfo.h + if [ -r syslex.c ]; then \ +- $(CC_FOR_BUILD) -c -I. $(CFLAGS) syslex.c ; \ ++ $(CC_FOR_BUILD) -c -I. $(CFLAGS_FOR_BUILD) syslex.c ; \ + else \ +- $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(CFLAGS) $(srcdir)/syslex.c ;\ ++ $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(CFLAGS_FOR_BUILD) $(srcdir)/syslex.c ;\ + fi + + sysinfo.o: sysinfo.c + if [ -r sysinfo.c ]; then \ +- $(CC_FOR_BUILD) -c -I. $(CFLAGS) sysinfo.c ; \ ++ $(CC_FOR_BUILD) -c -I. $(CFLAGS_FOR_BUILD) sysinfo.c ; \ + else \ +- $(CC_FOR_BUILD) -c -I. $(CFLAGS) $(srcdir)/sysinfo.c ; \ ++ $(CC_FOR_BUILD) -c -I. $(CFLAGS_FOR_BUILD) $(srcdir)/sysinfo.c ; \ + fi + + # We need these for parallel make. diff --git a/meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.90.0.3-uclibc-200-build_modules.patch b/meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.90.0.3-uclibc-200-build_modules.patch new file mode 100644 index 000000000..3560d2ca3 --- /dev/null +++ b/meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.90.0.3-uclibc-200-build_modules.patch @@ -0,0 +1,33 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- src/configure~binutils-2.15.90.0.3-uclibc-200-build_modules.patch ++++ src/configure +@@ -940,6 +940,11 @@ + build_configdirs=`echo ${build_libs} ${build_tools}` + fi + ++case "$target" in ++ *-*-*-uclibc*) ++ build_modules= ++ ;; ++esac + ################################################################################ + + srcname="gnu development package" +--- src/configure.in~binutils-2.15.90.0.3-uclibc-200-build_modules.patch ++++ src/configure.in +@@ -189,6 +189,11 @@ + build_configdirs=`echo ${build_libs} ${build_tools}` + fi + ++case "$target" in ++ *-*-*-uclibc*) ++ build_modules= ++ ;; ++esac + ################################################################################ + + srcname="gnu development package" diff --git a/meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.90.0.3-uclibc-210-cflags.patch b/meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.90.0.3-uclibc-210-cflags.patch new file mode 100644 index 000000000..40a71c602 --- /dev/null +++ b/meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.90.0.3-uclibc-210-cflags.patch @@ -0,0 +1,30 @@ +--- binutils-2.15.90.0.3/bfd/doc/Makefile.am.cflags 2004-01-14 16:07:44.000000000 -0500 ++++ binutils-2.15.90.0.3/bfd/doc/Makefile.am 2004-04-22 22:06:35.000000000 -0400 +@@ -55,10 +55,10 @@ + MKDOC = chew$(EXEEXT_FOR_BUILD) + + $(MKDOC): chew.o +- $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS) $(LOADLIBES) $(LDFLAGS) ++ $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS_FOR_BUILD) $(LOADLIBES) $(LDFLAGS) + + chew.o: chew.c +- $(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS) $(srcdir)/chew.c ++ $(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS_FOR_BUILD) $(srcdir)/chew.c + + protos: libbfd.h libcoff.h bfd.h + +--- binutils-2.15.90.0.3/bfd/doc/Makefile.in.cflags 2004-04-12 15:56:34.000000000 -0400 ++++ binutils-2.15.90.0.3/bfd/doc/Makefile.in 2004-04-22 22:06:35.000000000 -0400 +@@ -472,10 +472,10 @@ + + + $(MKDOC): chew.o +- $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS) $(LOADLIBES) $(LDFLAGS) ++ $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS_FOR_BUILD) $(LOADLIBES) $(LDFLAGS) + + chew.o: chew.c +- $(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS) $(srcdir)/chew.c ++ $(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS_FOR_BUILD) $(srcdir)/chew.c + + protos: libbfd.h libcoff.h bfd.h + diff --git a/meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.91.0.1-uclibc-100-conf.patch b/meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.91.0.1-uclibc-100-conf.patch new file mode 100644 index 000000000..d650cdbc9 --- /dev/null +++ b/meta/packages/binutils/binutils-2.15.94.0.1/binutils-2.15.91.0.1-uclibc-100-conf.patch @@ -0,0 +1,604 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- binutils-2.15.94.0.1/bfd/config.bfd~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/bfd/config.bfd +@@ -140,7 +140,7 @@ + targ_defvec=ecoffalpha_little_vec + targ_selvecs=bfd_elf64_alpha_vec + ;; +- alpha*-*-linux-gnu* | alpha*-*-elf*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc* | alpha*-*-elf*) + targ_defvec=bfd_elf64_alpha_vec + targ_selvecs=ecoffalpha_little_vec + ;; +@@ -150,7 +150,7 @@ + alpha*-*-*) + targ_defvec=ecoffalpha_little_vec + ;; +- ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf* | ia64*-*-kfreebsd*-gnu) ++ ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf* | ia64*-*-linux-uclibc* | ia64*-*-kfreebsd*-gnu) + targ_defvec=bfd_elf64_ia64_little_vec + targ_selvecs="bfd_elf64_ia64_big_vec bfd_efi_app_ia64_vec" + ;; +@@ -227,7 +227,7 @@ + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec + ;; +- armeb-*-elf | arm*b-*-linux-gnu*) ++ armeb-*-elf | arm*b-*-linux-gnu* | arm*b-*-linux-uclibc*) + targ_defvec=bfd_elf32_bigarm_vec + targ_selvecs=bfd_elf32_littlearm_vec + ;; +@@ -237,7 +237,7 @@ + ;; + arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-conix* | \ + arm*-*-uclinux* | arm-*-kfreebsd*-gnu | arm-*-vxworks | \ +- arm*-*-eabi* ) ++ arm*-*-eabi* | arm*-*-linux-uclibc* ) + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec + ;; +@@ -381,7 +381,7 @@ + ;; + + #ifdef BFD64 +- hppa*64*-*-linux-gnu*) ++ hppa*64*-*-linux-gnu* | hppa*64*-*-linux-uclibc*) + targ_defvec=bfd_elf64_hppa_linux_vec + targ_selvecs=bfd_elf64_hppa_vec + ;; +@@ -392,7 +392,7 @@ + ;; + #endif + +- hppa*-*-linux-gnu*) ++ hppa*-*-linux-gnu* | hppa*-*-linux-uclibc*) + targ_defvec=bfd_elf32_hppa_linux_vec + targ_selvecs=bfd_elf32_hppa_vec + ;; +@@ -525,7 +525,7 @@ + targ_selvecs=bfd_elf32_i386_vec + targ_underscore=yes + ;; +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + targ_defvec=bfd_elf32_i386_vec + targ_selvecs="i386linux_vec bfd_efi_app_ia32_vec" + targ64_selvecs=bfd_elf64_x86_64_vec +@@ -539,7 +539,7 @@ + targ_defvec=bfd_elf64_x86_64_vec + targ_selvecs="bfd_elf32_i386_vec i386netbsd_vec i386coff_vec bfd_efi_app_ia32_vec" + ;; +- x86_64-*-linux-gnu*) ++ x86_64-*-linux-gnu* | x86_64-*-linux-uclibc*) + targ_defvec=bfd_elf64_x86_64_vec + targ_selvecs="bfd_elf32_i386_vec i386linux_vec bfd_efi_app_ia32_vec" + ;; +@@ -715,7 +715,7 @@ + targ_selvecs=bfd_elf32_m68k_vec + targ_underscore=yes + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + targ_defvec=bfd_elf32_m68k_vec + targ_selvecs=m68klinux_vec + ;; +@@ -1001,7 +1001,8 @@ + ;; + #endif + powerpc-*-*bsd* | powerpc-*-elf* | powerpc-*-sysv4* | powerpc-*-eabi* | \ +- powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-rtems* | \ ++ powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-linux-uclibc* | \ ++ powerpc-*-rtems* | \ + powerpc-*-chorus* | powerpc-*-vxworks* | powerpc-*-windiss*) + targ_defvec=bfd_elf32_powerpc_vec + targ_selvecs="rs6000coff_vec bfd_elf32_powerpcle_vec ppcboot_vec" +@@ -1038,8 +1039,8 @@ + targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec" + ;; + powerpcle-*-elf* | powerpcle-*-sysv4* | powerpcle-*-eabi* | \ +- powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-vxworks* |\ +- powerpcle-*-rtems*) ++ powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-linux-uclibc* |\ ++ powerpcle-*-vxworks* | powerpcle-*-rtems*) + targ_defvec=bfd_elf32_powerpcle_vec + targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec" + targ64_selvecs="bfd_elf64_powerpc_vec bfd_elf64_powerpcle_vec" +@@ -1206,7 +1207,7 @@ + targ_selvecs="bfd_elf32_sparc_vec sunos_big_vec" + targ_underscore=yes + ;; +- sparc-*-linux-gnu*) ++ sparc-*-linux-gnu* | sparc-*-linux-uclibc*) + targ_defvec=bfd_elf32_sparc_vec + targ_selvecs="sparclinux_vec bfd_elf64_sparc_vec sunos_big_vec" + ;; +@@ -1253,7 +1254,7 @@ + targ_defvec=sunos_big_vec + targ_underscore=yes + ;; +- sparc64-*-linux-gnu*) ++ sparc64-*-linux-gnu* | sparc64-*-linux-uclibc*) + targ_defvec=bfd_elf64_sparc_vec + targ_selvecs="bfd_elf32_sparc_vec sparclinux_vec sunos_big_vec" + ;; +--- binutils-2.15.94.0.1/bfd/configure~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/bfd/configure +@@ -3583,6 +3583,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +@@ -9914,7 +9919,7 @@ + alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu) + COREFILE='' + ;; +- alpha*-*-linux-gnu*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/alphalinux.h"' + ;; +@@ -9978,7 +9983,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386mach3.h"' + ;; +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386linux.h"' + ;; +@@ -10016,7 +10021,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/hp300bsd.h"' + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/m68klinux.h"' + ;; +--- binutils-2.15.94.0.1/bfd/configure.in~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/bfd/configure.in +@@ -163,7 +163,7 @@ + alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu) + COREFILE='' + ;; +- alpha*-*-linux-gnu*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/alphalinux.h"' + ;; +@@ -248,7 +248,7 @@ + TRAD_HEADER='"hosts/i386mach3.h"' + ;; + changequote(,)dnl +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + changequote([,])dnl + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386linux.h"' +@@ -289,7 +289,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/hp300bsd.h"' + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/m68klinux.h"' + ;; +--- binutils-2.15.94.0.1/gas/configure~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/gas/configure +@@ -3420,6 +3420,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +@@ -4256,6 +4261,7 @@ + alpha*-*-osf*) fmt=ecoff ;; + alpha*-*-linuxecoff*) fmt=ecoff ;; + alpha*-*-linux-gnu*) fmt=elf em=linux ;; ++ alpha*-*-linux-uclibc*) fmt=elf em=linux ;; + alpha*-*-netbsd*) fmt=elf em=nbsd ;; + alpha*-*-openbsd*) fmt=elf em=obsd ;; + +@@ -4271,6 +4277,7 @@ + arm*-*-conix*) fmt=elf ;; + arm-*-linux*aout*) fmt=aout em=linux ;; + arm*-*-linux-gnu*) fmt=elf em=linux ;; ++ arm*-*-linux-uclibc*) fmt=elf em=linux ;; + arm*-*-uclinux*) fmt=elf em=linux ;; + arm-*-netbsdelf*) fmt=elf em=nbsd ;; + arm-*-*n*bsd*) fmt=aout em=nbsd ;; +@@ -4284,6 +4291,7 @@ + + cris-*-linux-gnu* | crisv32-*-linux-gnu*) + fmt=multi bfd_gas=yes em=linux ;; ++ cris-*-linux-uclibc*) fmt=multi bfd_gas=yes em=linux ;; + cris-*-* | crisv32-*-*) fmt=multi bfd_gas=yes ;; + + crx-*-elf*) fmt=elf ;; +@@ -4343,7 +4351,9 @@ + i386-*-linux*oldld) fmt=aout em=linux ;; + i386-*-linux*coff*) fmt=coff em=linux ;; + i386-*-linux-gnu*) fmt=elf em=linux ;; ++ i386-*-linux-uclibc*) fmt=elf em=linux ;; + x86_64-*-linux-gnu*) fmt=elf em=linux ;; ++ x86_64-*-linux-uclibc*) fmt=elf em=linux ;; + i386-*-lynxos*) fmt=elf em=lynx bfd_gas=yes ;; + i386-*-sysv[45]*) fmt=elf ;; + i386-*-solaris*) fmt=elf ;; +@@ -4403,6 +4413,7 @@ + ia64-*-elf*) fmt=elf ;; + ia64-*-aix*) fmt=elf em=ia64aix ;; + ia64-*-linux-gnu*) fmt=elf em=linux ;; ++ ia64-*-linux-uclibc*) fmt=elf em=linux ;; + ia64-*-hpux*) fmt=elf em=hpux ;; + ia64-*-netbsd*) fmt=elf em=nbsd ;; + +@@ -4430,6 +4441,7 @@ + m68k-*-hpux*) fmt=hp300 em=hp300 ;; + m68k-*-linux*aout*) fmt=aout em=linux ;; + m68k-*-linux-gnu*) fmt=elf em=linux ;; ++ m68k-*-linux-uclibc*) fmt=elf em=linux ;; + m68k-*-uclinux*) fmt=elf ;; + m68k-*-gnu*) fmt=elf ;; + m68k-*-lynxos*) fmt=coff em=lynx ;; +@@ -4504,7 +4516,7 @@ + ppc-*-beos*) fmt=coff ;; + ppc-*-*n*bsd* | ppc-*-elf*) fmt=elf ;; + ppc-*-eabi* | ppc-*-sysv4*) fmt=elf ;; +- ppc-*-linux-gnu*) fmt=elf em=linux ++ ppc-*-linux-uclibc* | ppc-*-linux-gnu*) fmt=elf em=linux + case "$endian" in + big) ;; + *) { { echo "$as_me:$LINENO: error: GNU/Linux must be configured big endian" >&5 +@@ -4531,7 +4543,9 @@ + ppc-*-lynxos*) fmt=elf em=lynx bfd_gas=yes ;; + + s390x-*-linux-gnu*) fmt=elf em=linux ;; ++ s390x-*-linux-uclibc*) fmt=elf em=linux ;; + s390-*-linux-gnu*) fmt=elf em=linux ;; ++ s390-*-linux-uclibc*) fmt=elf em=linux ;; + + sh*-*-linux*) fmt=elf em=linux + case ${cpu} in +@@ -4566,6 +4580,7 @@ + sparc-*-coff) fmt=coff ;; + sparc-*-linux*aout*) fmt=aout em=linux ;; + sparc-*-linux-gnu*) fmt=elf em=linux ;; ++ sparc-*-linux-uclibc*) fmt=elf em=linux ;; + sparc-*-lynxos*) fmt=coff em=lynx ;; + sparc-fujitsu-none) fmt=aout ;; + sparc-*-elf) fmt=elf ;; +--- binutils-2.15.94.0.1/gas/configure.in~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/gas/configure.in +@@ -202,6 +202,7 @@ + alpha*-*-osf*) fmt=ecoff ;; + alpha*-*-linuxecoff*) fmt=ecoff ;; + alpha*-*-linux-gnu*) fmt=elf em=linux ;; ++ alpha*-*-linux-uclibc*) fmt=elf em=linux ;; + alpha*-*-netbsd*) fmt=elf em=nbsd ;; + alpha*-*-openbsd*) fmt=elf em=obsd ;; + +@@ -217,6 +218,7 @@ + arm*-*-conix*) fmt=elf ;; + arm-*-linux*aout*) fmt=aout em=linux ;; + arm*-*-linux-gnu*) fmt=elf em=linux ;; ++ arm*-*-linux-uclibc*) fmt=elf em=linux ;; + arm*-*-uclinux*) fmt=elf em=linux ;; + arm-*-netbsdelf*) fmt=elf em=nbsd ;; + arm-*-*n*bsd*) fmt=aout em=nbsd ;; +@@ -230,6 +232,7 @@ + + cris-*-linux-gnu* | crisv32-*-linux-gnu*) + fmt=multi bfd_gas=yes em=linux ;; ++ cris-*-linux-uclibc*) fmt=multi bfd_gas=yes em=linux ;; + cris-*-* | crisv32-*-*) fmt=multi bfd_gas=yes ;; + + crx-*-elf*) fmt=elf ;; +@@ -289,7 +292,9 @@ + i386-*-linux*oldld) fmt=aout em=linux ;; + i386-*-linux*coff*) fmt=coff em=linux ;; + i386-*-linux-gnu*) fmt=elf em=linux ;; ++ i386-*-linux-uclibc*) fmt=elf em=linux ;; + x86_64-*-linux-gnu*) fmt=elf em=linux ;; ++ x86_64-*-linux-uclibc*) fmt=elf em=linux ;; + i386-*-lynxos*) fmt=elf em=lynx bfd_gas=yes ;; + changequote(,)dnl + i386-*-sysv[45]*) fmt=elf ;; +@@ -342,6 +347,7 @@ + ia64-*-elf*) fmt=elf ;; + ia64-*-aix*) fmt=elf em=ia64aix ;; + ia64-*-linux-gnu*) fmt=elf em=linux ;; ++ ia64-*-linux-uclibc*) fmt=elf em=linux ;; + ia64-*-hpux*) fmt=elf em=hpux ;; + ia64-*-netbsd*) fmt=elf em=nbsd ;; + +@@ -369,6 +375,7 @@ + m68k-*-hpux*) fmt=hp300 em=hp300 ;; + m68k-*-linux*aout*) fmt=aout em=linux ;; + m68k-*-linux-gnu*) fmt=elf em=linux ;; ++ m68k-*-linux-uclibc*) fmt=elf em=linux ;; + m68k-*-uclinux*) fmt=elf ;; + m68k-*-gnu*) fmt=elf ;; + m68k-*-lynxos*) fmt=coff em=lynx ;; +@@ -440,7 +447,7 @@ + ppc-*-beos*) fmt=coff ;; + ppc-*-*n*bsd* | ppc-*-elf*) fmt=elf ;; + ppc-*-eabi* | ppc-*-sysv4*) fmt=elf ;; +- ppc-*-linux-gnu*) fmt=elf em=linux ++ ppc-*-linux-uclibc* | ppc-*-linux-gnu*) fmt=elf em=linux + case "$endian" in + big) ;; + *) AC_MSG_ERROR(GNU/Linux must be configured big endian) ;; +@@ -460,7 +467,9 @@ + ppc-*-lynxos*) fmt=elf em=lynx bfd_gas=yes ;; + + s390x-*-linux-gnu*) fmt=elf em=linux ;; ++ s390x-*-linux-uclibc*) fmt=elf em=linux ;; + s390-*-linux-gnu*) fmt=elf em=linux ;; ++ s390-*-linux-uclibc*) fmt=elf em=linux ;; + + sh*-*-linux*) fmt=elf em=linux + case ${cpu} in +@@ -491,6 +500,7 @@ + sparc-*-coff) fmt=coff ;; + sparc-*-linux*aout*) fmt=aout em=linux ;; + sparc-*-linux-gnu*) fmt=elf em=linux ;; ++ sparc-*-linux-uclibc*) fmt=elf em=linux ;; + sparc-*-lynxos*) fmt=coff em=lynx ;; + sparc-fujitsu-none) fmt=aout ;; + sparc-*-elf) fmt=elf ;; +--- binutils-2.15.94.0.1/ld/configure~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/ld/configure +@@ -1579,6 +1579,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +--- binutils-2.15.94.0.1/ld/configure.tgt~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/ld/configure.tgt +@@ -32,6 +32,7 @@ + targ_extra_libpath=$targ_extra_emuls ;; + cris-*-linux-gnu* | cris-*-linux-gnu*) + targ_emul=crislinux ;; ++cris-*-linux-uclibc*) targ_emul=crislinux ;; + cris-*-* | crisv32-*-*) targ_emul=criself + targ_extra_emuls="crisaout crislinux" + targ_extra_libpath=$targ_extra_emuls ;; +@@ -62,14 +63,16 @@ + tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/aout//'` + tdir_sun4=sparc-sun-sunos4 + ;; +-sparc64-*-linux-gnu*) targ_emul=elf64_sparc ++sparc64-*-linux-gnu* | sparc64-*-linux-uclibc*) \ ++ targ_emul=elf64_sparc + targ_extra_emuls="elf32_sparc sparclinux sun4" + targ_extra_libpath=elf32_sparc + tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/64//'` + tdir_sparclinux=${tdir_elf32_sparc}aout + tdir_sun4=sparc-sun-sunos4 + ;; +-sparc*-*-linux-gnu*) targ_emul=elf32_sparc ++sparc*-*-linux-gnu* | sparc*-*-linux-uclibc*) \ ++ targ_emul=elf32_sparc + targ_extra_emuls="sparclinux elf64_sparc sun4" + targ_extra_libpath=elf64_sparc + tdir_sparclinux=${targ_alias}aout +@@ -132,7 +135,7 @@ + m68*-apple-aux*) targ_emul=m68kaux ;; + maxq-*-coff) targ_emul=maxqcoff;; + *-tandem-none) targ_emul=st2000 ;; +-i370-*-elf* | i370-*-linux-gnu*) targ_emul=elf32i370 ;; ++i370-*-elf* | i370-*-linux-gnu* | i370-*-linux-uclibc*) targ_emul=elf32i370 ;; + i[3-7]86-*-nto-qnx*) targ_emul=i386nto ;; + i[3-7]86-*-vsta) targ_emul=vsta ;; + i[3-7]86-go32-rtems*) targ_emul=i386go32 ;; +@@ -156,14 +159,16 @@ + tdir_elf_i386=`echo ${targ_alias} | sed -e 's/aout//'` + ;; + i[3-7]86-*-linux*oldld) targ_emul=i386linux; targ_extra_emuls=elf_i386 ;; +-i[3-7]86-*-linux-gnu*) targ_emul=elf_i386 ++i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) \ ++ targ_emul=elf_i386 + targ_extra_emuls=i386linux + if test x${want64} = xtrue; then + targ_extra_emuls="$targ_extra_emuls elf_x86_64" + fi + tdir_i386linux=${targ_alias}aout + ;; +-x86_64-*-linux-gnu*) targ_emul=elf_x86_64 ++x86_64-*-linux-gnu* | x86_64-*-linux-uclibc*) \ ++ targ_emul=elf_x86_64 + targ_extra_emuls="elf_i386 i386linux" + targ_extra_libpath=elf_i386 + tdir_i386linux=`echo ${targ_alias}aout | sed -e 's/x86_64/i386/'` +@@ -263,11 +268,14 @@ + arm-*-kaos*) targ_emul=armelf ;; + arm9e-*-elf) targ_emul=armelf ;; + arm*b-*-linux-gnu*) targ_emul=armelfb_linux; targ_extra_emuls=armelfb ;; ++arm*b-*-linux-uclibc*) targ_emul=armelfb_linux; targ_extra_emuls=armelfb ;; + arm*-*-linux-gnueabi) targ_emul=armelf_linux_eabi ;; + arm*-*-linux-gnu*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;; ++arm*-*-linux-uclibc*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;; + arm*-*-uclinux*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;; + arm*-*-conix*) targ_emul=armelf ;; +-thumb-*-linux-gnu* | thumb-*-uclinux*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;; ++thumb-*-linux-gnu* | thumb-*-linux-uclibc* | thumb-*-uclinux*) ++ targ_emul=armelf_linux; targ_extra_emuls=armelf ;; + strongarm-*-coff) targ_emul=armcoff ;; + strongarm-*-elf) targ_emul=armelf ;; + strongarm-*-kaos*) targ_emul=armelf ;; +@@ -371,7 +379,8 @@ + targ_extra_emuls=m68kelf + tdir_m68kelf=`echo ${targ_alias} | sed -e 's/aout//'` + ;; +-m68k-*-linux-gnu*) targ_emul=m68kelf ++m68k-*-linux-gnu* | m68k-*-linux-uclibc*) \ ++ targ_emul=m68kelf + targ_extra_emuls=m68klinux + tdir_m68klinux=`echo ${targ_alias} | sed -e 's/linux/linuxaout/'` + ;; +@@ -388,9 +397,9 @@ + m68*-*-psos*) targ_emul=m68kpsos ;; + m68*-*-rtemscoff*) targ_emul=m68kcoff ;; + m68*-*-rtems*) targ_emul=m68kelf ;; +-hppa*64*-*-linux-gnu*) targ_emul=hppa64linux ;; ++hppa*64*-*-linux-gnu* | hppa*64*-*-linux-uclibc*) targ_emul=hppa64linux ;; + hppa*64*-*) targ_emul=elf64hppa ;; +-hppa*-*-linux-gnu*) targ_emul=hppalinux ;; ++hppa*-*-linux-gnu* | hppa*-*-linux-uclibc*) targ_emul=hppalinux ;; + hppa*-*-*elf*) targ_emul=hppaelf ;; + hppa*-*-lites*) targ_emul=hppaelf ;; + hppa*-*-netbsd*) targ_emul=hppanbsd ;; +@@ -436,16 +445,20 @@ + mips*-*-vxworks*) targ_emul=elf32ebmip + targ_extra_emuls="elf32elmip" ;; + mips*-*-windiss) targ_emul=elf32mipswindiss ;; +-mips64*el-*-linux-gnu*) targ_emul=elf32ltsmipn32 ++mips64*el-*-linux-gnu* | mips64*el-*-linux-uclibc*) ++ targ_emul=elf32ltsmipn32 + targ_extra_emuls="elf32btsmipn32 elf32ltsmip elf32btsmip elf64ltsmip elf64btsmip" + ;; +-mips64*-*-linux-gnu*) targ_emul=elf32btsmipn32 ++mips64*-*-linux-gnu* | mips64*-*-linux-uclibc*) ++ targ_emul=elf32btsmipn32 + targ_extra_emuls="elf32ltsmipn32 elf32btsmip elf32ltsmip elf64btsmip elf64ltsmip" + ;; +-mips*el-*-linux-gnu*) targ_emul=elf32ltsmip ++mips*el-*-linux-gnu* | mips*el-*-linux-uclibc*) ++ targ_emul=elf32ltsmip + targ_extra_emuls="elf32btsmip elf32ltsmipn32 elf64ltsmip elf32btsmipn32 elf64btsmip" + ;; +-mips*-*-linux-gnu*) targ_emul=elf32btsmip ++mips*-*-linux-gnu* | mips*-*-linux-uclibc*) ++ targ_emul=elf32btsmip + targ_extra_emuls="elf32ltsmip elf32btsmipn32 elf64btsmip elf32ltsmipn32 elf64ltsmip" + ;; + mips*-*-lnews*) targ_emul=mipslnews ;; +@@ -468,6 +481,10 @@ + alpha*-*-linux-gnu*) targ_emul=elf64alpha targ_extra_emuls=alpha + tdir_alpha=`echo ${targ_alias} | sed -e 's/linux/linuxecoff/'` + ;; ++alpha*-*-linux-uclibc*) targ_emul=elf64alpha targ_extra_emuls=alpha ++ # The following needs to be checked... ++ tdir_alpha=`echo ${targ_alias} | sed -e 's/linux/linuxecoff/'` ++ ;; + alpha*-*-osf*) targ_emul=alpha ;; + alpha*-*-gnu*) targ_emul=elf64alpha ;; + alpha*-*-netware*) targ_emul=alpha ;; +--- binutils-2.15.94.0.1/configure~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/configure +@@ -1341,6 +1341,18 @@ + i[3456789]86-*-coff | i[3456789]86-*-elf) + noconfigdirs="$noconfigdirs ${libgcj}" + ;; ++ i[3456789]86-*-linux-uclibc) ++ # This section makes it possible to build newlib natively on linux. ++ # If we are using a cross compiler then don't configure newlib. ++ if test x${is_cross_compiler} != xno ; then ++ noconfigdirs="$noconfigdirs target-newlib" ++ fi ++ noconfigdirs="$noconfigdirs target-libgloss" ++ # If we are not using a cross compiler, do configure newlib. ++ # Note however, that newlib will only be configured in this situation ++ # if the --with-newlib option has been given, because otherwise ++ # 'target-newlib' will appear in skipdirs. ++ ;; + i[3456789]86-*-linux*) + # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's + # not build java stuff by default. +--- binutils-2.15.94.0.1/configure.in~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/configure.in +@@ -563,6 +563,19 @@ + i[[3456789]]86-*-coff | i[[3456789]]86-*-elf) + noconfigdirs="$noconfigdirs ${libgcj}" + ;; ++ i[3456789]86-*-linux-uclibc) ++ # This section makes it possible to build newlib natively on linux. ++ # If we are using a cross compiler then don't configure newlib. ++ if test x${is_cross_compiler} != xno ; then ++ noconfigdirs="$noconfigdirs target-newlib" ++ fi ++ noconfigdirs="$noconfigdirs target-libgloss" ++ build_modules= ++ # If we are not using a cross compiler, do configure newlib. ++ # Note however, that newlib will only be configured in this situation ++ # if the --with-newlib option has been given, because otherwise ++ # 'target-newlib' will appear in skipdirs. ++ ;; + i[[3456789]]86-*-linux*) + # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's + # not build java stuff by default. +--- binutils-2.15.94.0.1/libtool.m4~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/libtool.m4 +@@ -645,6 +645,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + [lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'] +--- binutils-2.15.94.0.1/ltconfig~binutils-2.15.91.0.1-uclibc-100-conf ++++ binutils-2.15.94.0.1/ltconfig +@@ -603,6 +603,7 @@ + # Transform linux* to *-*-linux-gnu*, to support old configure scripts. + case $host_os in + linux-gnu*) ;; ++linux-uclibc*) ;; + linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'` + esac + +@@ -1270,6 +1271,24 @@ + dynamic_linker='GNU/Linux ld.so' + ;; + ++linux-uclibc*) ++ version_type=linux ++ need_lib_prefix=no ++ need_version=no ++ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' ++ soname_spec='${libname}${release}.so$major' ++ finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' ++ shlibpath_var=LD_LIBRARY_PATH ++ shlibpath_overrides_runpath=no ++ # This implies no fast_install, which is unacceptable. ++ # Some rework will be needed to allow for fast_install ++ # before this can be enabled. ++ # Note: copied from linux-gnu, and may not be appropriate. ++ hardcode_into_libs=yes ++ # Assume using the uClibc dynamic linker. ++ dynamic_linker="uClibc ld.so" ++ ;; ++ + netbsd*) + need_lib_prefix=no + need_version=no diff --git a/meta/packages/binutils/binutils-2.16.91.0.7/binutils-2.16.91.0.6-objcopy-rename-errorcode.patch b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-2.16.91.0.6-objcopy-rename-errorcode.patch new file mode 100644 index 000000000..4461bedd4 --- /dev/null +++ b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-2.16.91.0.6-objcopy-rename-errorcode.patch @@ -0,0 +1,31 @@ +# strip (and objcopy) fail to set the error code if there is no +# output file name and the rename of the stripped (or copied) file +# fails, yet the command fails to do anything. This fixes both +# objcopy and strip. +# +# modification by bero: Ported to 2.16.91.0.6 +# +#Signed-off-by: John Bowler +#Signed-off-by: Bernhard Rosenkraenzer +--- binutils-2.16.91.0.6/binutils/objcopy.c.ark 2006-03-11 15:59:07.000000000 +0100 ++++ binutils-2.16.91.0.6/binutils/objcopy.c 2006-03-11 15:59:45.000000000 +0100 +@@ -2593,7 +2593,8 @@ + if (preserve_dates) + set_times (tmpname, &statbuf); + if (output_file == NULL) +- smart_rename (tmpname, argv[i], preserve_dates); ++ if(smart_rename (tmpname, argv[i], preserve_dates)) ++ hold_status = 1; + status = hold_status; + } + else +@@ -3184,7 +3185,8 @@ + { + if (preserve_dates) + set_times (tmpname, &statbuf); +- smart_rename (tmpname, input_filename, preserve_dates); ++ if (smart_rename (tmpname, input_filename, preserve_dates)) ++ status = 1; + } + else + unlink (tmpname); diff --git a/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-100-uclibc-conf.patch b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-100-uclibc-conf.patch new file mode 100644 index 000000000..25222e5df --- /dev/null +++ b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-100-uclibc-conf.patch @@ -0,0 +1,139 @@ +--- binutils-2.16.91.0.7/bfd/configure ++++ binutils-2.16.91.0.7/bfd/configure +@@ -3576,7 +3576,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu*|linux-uclibc*) + lt_cv_deplibs_check_method=pass_all + ;; + +--- binutils-2.16.91.0.7/binutils/configure ++++ binutils-2.16.91.0.7/binutils/configure +@@ -3411,7 +3411,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu*|linux-uclibc*) + lt_cv_deplibs_check_method=pass_all + ;; + +--- binutils-2.16.91.0.7/configure ++++ binutils-2.16.91.0.7/configure +@@ -1270,7 +1270,7 @@ + am33_2.0-*-linux*) + noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss" + ;; +- sh-*-linux*) ++ sh*-*-linux*) + noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss" + ;; + sh*-*-pe|mips*-*-pe|*arm-wince-pe) +@@ -1578,7 +1578,7 @@ + romp-*-*) + noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes target-libgloss ${libgcj}" + ;; +- sh-*-* | sh64-*-*) ++ sh*-*-* | sh64-*-*) + case "${host}" in + i[3456789]86-*-vsta) ;; # don't add gprof back in + i[3456789]86-*-go32*) ;; # don't add gprof back in +--- binutils-2.16.91.0.7/configure.in ++++ binutils-2.16.91.0.7/configure.in +@@ -468,7 +468,7 @@ + am33_2.0-*-linux*) + noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss" + ;; +- sh-*-linux*) ++ sh*-*-linux*) + noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss" + ;; + sh*-*-pe|mips*-*-pe|*arm-wince-pe) +@@ -776,7 +776,7 @@ + romp-*-*) + noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes target-libgloss ${libgcj}" + ;; +- sh-*-* | sh64-*-*) ++ sh*-*-* | sh64-*-*) + case "${host}" in + i[[3456789]]86-*-vsta) ;; # don't add gprof back in + i[[3456789]]86-*-go32*) ;; # don't add gprof back in +--- binutils-2.16.91.0.7/gas/configure ++++ binutils-2.16.91.0.7/gas/configure +@@ -3411,7 +3411,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu*|linux-uclibc*) + lt_cv_deplibs_check_method=pass_all + ;; + +--- binutils-2.16.91.0.7/gprof/configure ++++ binutils-2.16.91.0.7/gprof/configure +@@ -3419,6 +3419,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +--- binutils-2.16.91.0.7/ld/configure ++++ binutils-2.16.91.0.7/ld/configure +@@ -3413,7 +3413,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu*|linux-uclibc*) + lt_cv_deplibs_check_method=pass_all + ;; + +--- binutils-2.16.91.0.7/libtool.m4 ++++ binutils-2.16.91.0.7/libtool.m4 +@@ -739,7 +739,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu*|linux-uclibc*) + lt_cv_deplibs_check_method=pass_all + ;; + +--- binutils-2.16.91.0.7/ltconfig ++++ binutils-2.16.91.0.7/ltconfig +@@ -602,6 +602,7 @@ + + # Transform linux* to *-*-linux-gnu*, to support old configure scripts. + case $host_os in ++linux-uclibc*) ;; + linux-gnu*) ;; + linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'` + esac +@@ -1247,7 +1248,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu*|linux-uclibc*) + version_type=linux + need_lib_prefix=no + need_version=no +--- binutils-2.16.91.0.7/opcodes/configure ++++ binutils-2.16.91.0.7/opcodes/configure +@@ -3579,7 +3579,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu*|linux-uclibc*) + lt_cv_deplibs_check_method=pass_all + ;; + diff --git a/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-001_ld_makefile_patch.patch b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-001_ld_makefile_patch.patch new file mode 100644 index 000000000..04a7e61e2 --- /dev/null +++ b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-001_ld_makefile_patch.patch @@ -0,0 +1,50 @@ +#!/bin/sh -e +## 001_ld_makefile_patch.dpatch +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Description: correct where ld scripts are installed +## DP: Author: Chris Chimelis +## DP: Upstream status: N/A +## DP: Date: ?? + +if [ $# -ne 1 ]; then + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1 +fi + +[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts +patch_opts="${patch_opts:--f --no-backup-if-mismatch}" + +case "$1" in + -patch) patch $patch_opts -p1 < $0;; + -unpatch) patch $patch_opts -p1 -R < $0;; + *) + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1;; +esac + +exit 0 + +@DPATCH@ +--- binutils-2.16.91.0.1/ld/Makefile.am ++++ binutils-2.16.91.0.1/ld/Makefile.am +@@ -20,7 +20,7 @@ + # We put the scripts in the directory $(scriptdir)/ldscripts. + # We can't put the scripts in $(datadir) because the SEARCH_DIR + # directives need to be different for native and cross linkers. +-scriptdir = $(tooldir)/lib ++scriptdir = $(libdir) + + EMUL = @EMUL@ + EMULATION_OFILES = @EMULATION_OFILES@ +--- binutils-2.16.91.0.1/ld/Makefile.in ++++ binutils-2.16.91.0.1/ld/Makefile.in +@@ -268,7 +268,7 @@ + # We put the scripts in the directory $(scriptdir)/ldscripts. + # We can't put the scripts in $(datadir) because the SEARCH_DIR + # directives need to be different for native and cross linkers. +-scriptdir = $(tooldir)/lib ++scriptdir = $(libdir) + BASEDIR = $(srcdir)/.. + BFDDIR = $(BASEDIR)/bfd + INCDIR = $(BASEDIR)/include diff --git a/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-006_better_file_error.patch b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-006_better_file_error.patch new file mode 100644 index 000000000..f337611ed --- /dev/null +++ b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-006_better_file_error.patch @@ -0,0 +1,43 @@ +#!/bin/sh -e +## 006_better_file_error.dpatch by David Kimdon +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Specify which filename is causing an error if the filename is a +## DP: directory. (#45832) + +if [ $# -ne 1 ]; then + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1 +fi + +[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts +patch_opts="${patch_opts:--f --no-backup-if-mismatch}" + +case "$1" in + -patch) patch $patch_opts -p1 < $0;; + -unpatch) patch $patch_opts -p1 -R < $0;; + *) + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1;; +esac + +exit 0 + +@DPATCH@ +diff -urNad /home/james/debian/packages/binutils/binutils-2.14.90.0.6/bfd/opncls.c binutils-2.14.90.0.6/bfd/opncls.c +--- /home/james/debian/packages/binutils/binutils-2.14.90.0.6/bfd/opncls.c 2003-07-23 16:08:09.000000000 +0100 ++++ binutils-2.14.90.0.6/bfd/opncls.c 2003-09-10 22:35:00.000000000 +0100 +@@ -150,6 +150,13 @@ + { + bfd *nbfd; + const bfd_target *target_vec; ++ struct stat s; ++ ++ if (stat (filename, &s) == 0) ++ if (S_ISDIR(s.st_mode)) { ++ bfd_set_error (bfd_error_file_not_recognized); ++ return NULL; ++ } + + nbfd = _bfd_new_bfd (); + if (nbfd == NULL) diff --git a/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-012_check_ldrunpath_length.patch b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-012_check_ldrunpath_length.patch new file mode 100644 index 000000000..498651a90 --- /dev/null +++ b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-300-012_check_ldrunpath_length.patch @@ -0,0 +1,47 @@ +#!/bin/sh -e +## 012_check_ldrunpath_length.dpatch by Chris Chimelis +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Only generate an RPATH entry if LD_RUN_PATH is not empty, for +## DP: cases where -rpath isn't specified. (#151024) + +if [ $# -ne 1 ]; then + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1 +fi + +[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts +patch_opts="${patch_opts:--f --no-backup-if-mismatch}" + +case "$1" in + -patch) patch $patch_opts -p1 < $0;; + -unpatch) patch $patch_opts -p1 -R < $0;; + *) + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1;; +esac + +exit 0 + +@DPATCH@ +diff -urNad /home/james/debian/packages/binutils/new/binutils-2.15/ld/emultempl/elf32.em binutils-2.15/ld/emultempl/elf32.em +--- /home/james/debian/packages/binutils/new/binutils-2.15/ld/emultempl/elf32.em 2004-05-21 23:12:58.000000000 +0100 ++++ binutils-2.15/ld/emultempl/elf32.em 2004-05-21 23:12:59.000000000 +0100 +@@ -692,6 +692,8 @@ + && command_line.rpath == NULL) + { + lib_path = (const char *) getenv ("LD_RUN_PATH"); ++ if ((lib_path) && (strlen (lib_path) == 0)) ++ lib_path = NULL; + if (gld${EMULATION_NAME}_search_needed (lib_path, &n, + force)) + break; +@@ -871,6 +873,8 @@ + rpath = command_line.rpath; + if (rpath == NULL) + rpath = (const char *) getenv ("LD_RUN_PATH"); ++ if ((rpath) && (strlen (rpath) == 0)) ++ rpath = NULL; + if (! (bfd_elf_size_dynamic_sections + (output_bfd, command_line.soname, rpath, + command_line.filter_shlib, diff --git a/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-400-mips-ELF_MAXPAGESIZE-4K.patch b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-400-mips-ELF_MAXPAGESIZE-4K.patch new file mode 100644 index 000000000..5959c718d --- /dev/null +++ b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-400-mips-ELF_MAXPAGESIZE-4K.patch @@ -0,0 +1,26 @@ +--- binutils/bfd/elf32-mips.c~ ++++ binutils/bfd/elf32-mips.c +@@ -1613,7 +1613,9 @@ + + /* The SVR4 MIPS ABI says that this should be 0x10000, and Linux uses + page sizes of up to that limit, so we need to respect it. */ +-#define ELF_MAXPAGESIZE 0x10000 ++/*#define ELF_MAXPAGESIZE 0x10000*/ ++/* Use 4K to shrink the elf header. NOT for general use! */ ++#define ELF_MAXPAGESIZE 0x1000 + #define elf32_bed elf32_tradbed + + /* Include the target file again for this target. */ +--- binutils/bfd/elfn32-mips.c~ ++++ binutils/bfd/elfn32-mips.c +@@ -2399,7 +2399,9 @@ + + /* The SVR4 MIPS ABI says that this should be 0x10000, and Linux uses + page sizes of up to that limit, so we need to respect it. */ +-#define ELF_MAXPAGESIZE 0x10000 ++/*#define ELF_MAXPAGESIZE 0x10000*/ ++/* Use 4K to shrink the elf header. NOT for general use! */ ++#define ELF_MAXPAGESIZE 0x1000 + #define elf32_bed elf32_tradbed + + /* Include the target file again for this target. */ diff --git a/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-702-binutils-skip-comments.patch b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-702-binutils-skip-comments.patch new file mode 100644 index 000000000..9ef7a7c9e --- /dev/null +++ b/meta/packages/binutils/binutils-2.16.91.0.7/binutils-uclibc-702-binutils-skip-comments.patch @@ -0,0 +1,93 @@ +Retrieved from http://sources.redhat.com/ml/binutils/2004-04/msg00646.html +Fixes +localealias.s:544: Error: junk at end of line, first unrecognized character is `,' +when building glibc-2.3.2 with gcc-3.4.0 and binutils-2.15.90.0.3 + +Paths adjusted to match crosstool's patcher. + +Message-Id: m3n052qw2g.fsf@whitebox.m5r.de +From: Andreas Schwab +To: Nathan Sidwell +Cc: Ian Lance Taylor , binutils at sources dot redhat dot com +Date: Fri, 23 Apr 2004 22:27:19 +0200 +Subject: Re: demand_empty_rest_of_line and ignore_rest_of_line + +Nathan Sidwell writes: + +> Index: read.c +> =================================================================== +> RCS file: /cvs/src/src/gas/read.c,v +> retrieving revision 1.76 +> diff -c -3 -p -r1.76 read.c +> *** read.c 12 Mar 2004 17:48:12 -0000 1.76 +> --- read.c 18 Mar 2004 09:56:05 -0000 +> *************** read_a_source_file (char *name) +> *** 1053,1059 **** +> #endif +> input_line_pointer--; +> /* Report unknown char as ignored. */ +> ! ignore_rest_of_line (); +> } +> +> #ifdef md_after_pass_hook +> --- 1053,1059 ---- +> #endif +> input_line_pointer--; +> /* Report unknown char as ignored. */ +> ! demand_empty_rest_of_line (); +> } +> +> #ifdef md_after_pass_hook + +This means that the unknown character is no longer ignored, despite the +comment. As a side effect a line starting with a line comment character +not followed by APP in NO_APP mode now triggers an error instead of just a +warning, breaking builds of glibc on m68k-linux. Earlier in +read_a_source_file where #APP is handled there is another comment that +claims that unknown comments are ignored, when in fact they aren't (only +the initial line comment character is skipped). + +Note that the presence of #APP will mess up the line counters, but +that appears to be difficult to fix. + +Andreas. + +2004-04-23 Andreas Schwab + + * read.c (read_a_source_file): Ignore unknown text after line + comment character. Fix misleading comment. + +--- binutils/gas/read.c.~1.78.~ 2004-04-23 08:58:23.000000000 +0200 ++++ binutils/gas/read.c 2004-04-23 21:49:01.000000000 +0200 +@@ -950,10 +950,14 @@ read_a_source_file (char *name) + unsigned int new_length; + char *tmp_buf = 0; + +- bump_line_counters (); + s = input_line_pointer; + if (strncmp (s, "APP\n", 4)) +- continue; /* We ignore it */ ++ { ++ /* We ignore it */ ++ ignore_rest_of_line (); ++ continue; ++ } ++ bump_line_counters (); + s += 4; + + sb_new (&sbuf); +@@ -1052,7 +1056,7 @@ read_a_source_file (char *name) + continue; + #endif + input_line_pointer--; +- /* Report unknown char as ignored. */ ++ /* Report unknown char as error. */ + demand_empty_rest_of_line (); + } + + +-- +Andreas Schwab, SuSE Labs, schwab@suse.de +SuSE Linux AG, MaxfeldstraÃe 5, 90409 NÃrnberg, Germany +Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 +"And now for something completely different." diff --git a/meta/packages/binutils/binutils-2.16/binutils-100_cflags_for_build.patch b/meta/packages/binutils/binutils-2.16/binutils-100_cflags_for_build.patch new file mode 100644 index 000000000..08e704994 --- /dev/null +++ b/meta/packages/binutils/binutils-2.16/binutils-100_cflags_for_build.patch @@ -0,0 +1,28 @@ +--- binutils-2.16/binutils/Makefile.am.old 2005-06-05 16:59:47.000000000 +0100 ++++ binutils-2.16/binutils/Makefile.am 2005-06-05 17:00:39.000000000 +0100 +@@ -219,20 +219,20 @@ + ./sysinfo$(EXEEXT_FOR_BUILD) -d <$(srcdir)/sysroff.info >sysroff.h + + sysinfo$(EXEEXT_FOR_BUILD): sysinfo.o syslex.o +- $(CC_FOR_BUILD) $(CFLAGS) $(LDFLAGS) -o $@ sysinfo.o syslex.o ++ $(CC_FOR_BUILD) $(CFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) -o $@ sysinfo.o syslex.o + + syslex.o: + if [ -r syslex.c ]; then \ +- $(CC_FOR_BUILD) -c -I. $(AM_CFLAGS) $(CFLAGS) syslex.c ; \ ++ $(CC_FOR_BUILD) -c -I. $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) syslex.c ; \ + else \ +- $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(AM_CFLAGS) $(CFLAGS) $(srcdir)/syslex.c ;\ ++ $(CC_FOR_BUILD) -c -I. -I$(srcdir) $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) $(srcdir)/syslex.c ;\ + fi + + sysinfo.o: + if [ -r sysinfo.c ]; then \ +- $(CC_FOR_BUILD) -c -I. $(AM_CFLAGS) $(CFLAGS) sysinfo.c ; \ ++ $(CC_FOR_BUILD) -c -I. $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) sysinfo.c ; \ + else \ +- $(CC_FOR_BUILD) -c -I. $(AM_CFLAGS) $(CFLAGS) $(srcdir)/sysinfo.c ; \ ++ $(CC_FOR_BUILD) -c -I. $(AM_CFLAGS) $(CFLAGS_FOR_BUILD) $(srcdir)/sysinfo.c ; \ + fi + + # We need these for parallel make. diff --git a/meta/packages/binutils/binutils-2.16/binutils-2.16-linux-uclibc.patch b/meta/packages/binutils/binutils-2.16/binutils-2.16-linux-uclibc.patch new file mode 100644 index 000000000..2f727a5b5 --- /dev/null +++ b/meta/packages/binutils/binutils-2.16/binutils-2.16-linux-uclibc.patch @@ -0,0 +1,700 @@ +# This patch adds 'linux-uclibc' to all cases which otherwise only +# fire for 'linux' - most of the time the 'linux-gnu*' cases. This +# ensures that by default *-*-linux-uclibc is handled in the same way +# as *-*-linux-gnu +# +--- binutils-2.16/bfd/config.bfd.orig 2005-09-06 19:58:39.153670708 -0700 ++++ binutils-2.16/bfd/config.bfd 2005-09-06 20:03:14.959026045 -0700 +@@ -140,7 +140,7 @@ + targ_defvec=ecoffalpha_little_vec + targ_selvecs=bfd_elf64_alpha_vec + ;; +- alpha*-*-linux-gnu* | alpha*-*-elf*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc* | alpha*-*-elf*) + targ_defvec=bfd_elf64_alpha_vec + targ_selvecs=ecoffalpha_little_vec + ;; +@@ -150,7 +150,7 @@ + alpha*-*-*) + targ_defvec=ecoffalpha_little_vec + ;; +- ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf* | ia64*-*-kfreebsd*-gnu) ++ ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-linux-uclibc* | ia64*-*-elf* | ia64*-*-kfreebsd*-gnu) + targ_defvec=bfd_elf64_ia64_little_vec + targ_selvecs="bfd_elf64_ia64_big_vec bfd_efi_app_ia64_vec" + ;; +@@ -227,7 +227,7 @@ + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec + ;; +- armeb-*-elf | arm*b-*-linux-gnu*) ++ armeb-*-elf | arm*b-*-linux-gnu* | arm*b-*-linux-uclibc*) + targ_defvec=bfd_elf32_bigarm_vec + targ_selvecs=bfd_elf32_littlearm_vec + ;; +@@ -235,7 +235,7 @@ + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec + ;; +- arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-conix* | \ ++ arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-linux-uclibc* | arm*-*-conix* | \ + arm*-*-uclinux* | arm-*-kfreebsd*-gnu | \ + arm*-*-eabi* ) + targ_defvec=bfd_elf32_littlearm_vec +@@ -385,7 +385,7 @@ + ;; + + #ifdef BFD64 +- hppa*64*-*-linux-gnu*) ++ hppa*64*-*-linux-gnu* | hppa*64*-*-linux-uclibc*) + targ_defvec=bfd_elf64_hppa_linux_vec + targ_selvecs=bfd_elf64_hppa_vec + ;; +@@ -396,7 +396,7 @@ + ;; + #endif + +- hppa*-*-linux-gnu*) ++ hppa*-*-linux-gnu* | hppa*-*-linux-uclibc*) + targ_defvec=bfd_elf32_hppa_linux_vec + targ_selvecs=bfd_elf32_hppa_vec + ;; +@@ -529,7 +529,7 @@ + targ_selvecs=bfd_elf32_i386_vec + targ_underscore=yes + ;; +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + targ_defvec=bfd_elf32_i386_vec + targ_selvecs="i386linux_vec bfd_efi_app_ia32_vec" + targ64_selvecs=bfd_elf64_x86_64_vec +@@ -543,7 +543,7 @@ + targ_defvec=bfd_elf64_x86_64_vec + targ_selvecs="bfd_elf32_i386_vec i386netbsd_vec i386coff_vec bfd_efi_app_ia32_vec" + ;; +- x86_64-*-linux-gnu*) ++ x86_64-*-linux-gnu* | x86_64-*-linux-uclibc*) + targ_defvec=bfd_elf64_x86_64_vec + targ_selvecs="bfd_elf32_i386_vec i386linux_vec bfd_efi_app_ia32_vec" + ;; +@@ -719,7 +719,7 @@ + targ_selvecs=bfd_elf32_m68k_vec + targ_underscore=yes + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + targ_defvec=bfd_elf32_m68k_vec + targ_selvecs=m68klinux_vec + ;; +@@ -1005,7 +1005,7 @@ + ;; + #endif + powerpc-*-*bsd* | powerpc-*-elf* | powerpc-*-sysv4* | powerpc-*-eabi* | \ +- powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-rtems* | \ ++ powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-linux-uclibc* | powerpc-*-rtems* | \ + powerpc-*-chorus* | powerpc-*-vxworks* | powerpc-*-windiss*) + targ_defvec=bfd_elf32_powerpc_vec + targ_selvecs="rs6000coff_vec bfd_elf32_powerpcle_vec ppcboot_vec" +@@ -1042,7 +1042,7 @@ + targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec" + ;; + powerpcle-*-elf* | powerpcle-*-sysv4* | powerpcle-*-eabi* | \ +- powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-vxworks* |\ ++ powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-linux-uclibc* | powerpcle-*-vxworks* |\ + powerpcle-*-rtems*) + targ_defvec=bfd_elf32_powerpcle_vec + targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec" +@@ -1213,7 +1213,7 @@ + targ_selvecs="bfd_elf32_sparc_vec sunos_big_vec" + targ_underscore=yes + ;; +- sparc-*-linux-gnu*) ++ sparc-*-linux-gnu* | sparc-*-linux-uclibc*) + targ_defvec=bfd_elf32_sparc_vec + targ_selvecs="sparclinux_vec bfd_elf64_sparc_vec sunos_big_vec" + ;; +@@ -1260,7 +1260,7 @@ + targ_defvec=sunos_big_vec + targ_underscore=yes + ;; +- sparc64-*-linux-gnu*) ++ sparc64-*-linux-gnu* | sparc64-*-linux-uclibc*) + targ_defvec=bfd_elf64_sparc_vec + targ_selvecs="bfd_elf32_sparc_vec sparclinux_vec sunos_big_vec" + ;; +@@ -1329,7 +1329,7 @@ + targ_underscore=yes + ;; + +- vax-*-linux-gnu*) ++ vax-*-linux-gnu* | vax-*-linux-uclibc*) + targ_defvec=bfd_elf32_vax_vec + ;; + +--- binutils-2.16/bfd/configure.in.orig 2005-09-06 20:25:48.848220921 -0700 ++++ binutils-2.16/bfd/configure.in 2005-09-06 20:26:58.628611924 -0700 +@@ -163,7 +163,7 @@ + alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu) + COREFILE='' + ;; +- alpha*-*-linux-gnu*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/alphalinux.h"' + ;; +@@ -248,7 +248,7 @@ + TRAD_HEADER='"hosts/i386mach3.h"' + ;; + changequote(,)dnl +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + changequote([,])dnl + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386linux.h"' +@@ -289,7 +289,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/hp300bsd.h"' + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/m68klinux.h"' + ;; +@@ -375,7 +375,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/vaxult2.h"' + ;; +- vax-*-linux-gnu*) ++ vax-*-linux-gnu* | vax-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/vaxlinux.h"' + ;; +--- binutils-2.16/bfd/configure.orig 2005-09-06 20:03:14.991028059 -0700 ++++ binutils-2.16/bfd/configure 2005-09-06 20:04:48.512913020 -0700 +@@ -3572,7 +3572,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu* | linux-uclibc*) + case $host_cpu in + alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* ) + lt_cv_deplibs_check_method=pass_all ;; +@@ -9918,7 +9918,7 @@ + alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu) + COREFILE='' + ;; +- alpha*-*-linux-gnu*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/alphalinux.h"' + ;; +@@ -9982,7 +9982,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386mach3.h"' + ;; +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386linux.h"' + ;; +@@ -10020,7 +10020,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/hp300bsd.h"' + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/m68klinux.h"' + ;; +@@ -10154,7 +10154,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/vaxult2.h"' + ;; +- vax-*-linux-gnu*) ++ vax-*-linux-gnu* | vax-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/vaxlinux.h"' + ;; +--- binutils-2.16/binutils/configure.orig 2005-09-06 20:26:58.676614945 -0700 ++++ binutils-2.16/binutils/configure 2005-09-06 20:27:21.230034142 -0700 +@@ -1564,7 +1564,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu* | linux-uclibc*) + case $host_cpu in + alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* ) + lt_cv_deplibs_check_method=pass_all ;; +--- binutils-2.16/configure.in.orig 2005-09-06 20:31:11.872547560 -0700 ++++ binutils-2.16/configure.in 2005-09-06 20:31:47.322778302 -0700 +@@ -346,7 +346,7 @@ + ;; + "") + case "${target}" in +- *-*-linux*-gnu | *-*-gnu* | *-*-k*bsd*-gnu) ++ *-*-linux*-gnu | *-*-linux*-uclibc | *-*-gnu* | *-*-k*bsd*-gnu) + # Enable libmudflap by default in GNU and friends. + ;; + *-*-freebsd*) +--- binutils-2.16/configure.orig 2005-09-06 20:30:00.120032459 -0700 ++++ binutils-2.16/configure 2005-09-06 20:31:11.832545043 -0700 +@@ -1142,7 +1142,7 @@ + ;; + "") + case "${target}" in +- *-*-linux*-gnu | *-*-gnu* | *-*-k*bsd*-gnu) ++ *-*-linux*-gnu | *-*-linux*-uclibc | *-*-gnu* | *-*-k*bsd*-gnu) + # Enable libmudflap by default in GNU and friends. + ;; + *-*-freebsd*) +--- binutils-2.16/gas/configure.in.orig 2005-09-06 20:32:36.993903909 -0700 ++++ binutils-2.16/gas/configure.in 2005-09-06 20:32:55.667078938 -0700 +@@ -161,7 +161,7 @@ + AC_DEFINE(AIX_WEAK_SUPPORT, 1, + [Define if using AIX 5.2 value for C_WEAKEXT.]) + ;; +- ppc-*-linux-gnu*) ++ ppc-*-linux-gnu* | ppc-*-linux-uclibc*) + case "$endian" in + big) ;; + *) AC_MSG_ERROR(GNU/Linux must be configured big endian) ;; +--- binutils-2.16/gas/configure.orig 2005-09-06 20:31:55.247276960 -0700 ++++ binutils-2.16/gas/configure 2005-09-06 20:32:36.961901896 -0700 +@@ -3409,7 +3409,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu* | linux-uclibc*) + case $host_cpu in + alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* ) + lt_cv_deplibs_check_method=pass_all ;; +@@ -4462,7 +4462,7 @@ + _ACEOF + + ;; +- ppc-*-linux-gnu*) ++ ppc-*-linux-gnu* | ppc-*-linux-uclibc*) + case "$endian" in + big) ;; + *) { { echo "$as_me:$LINENO: error: GNU/Linux must be configured big endian" >&5 +--- binutils-2.16/gas/configure.tgt.orig 2005-09-06 20:32:55.695080700 -0700 ++++ binutils-2.16/gas/configure.tgt 2005-09-06 20:35:59.482645723 -0700 +@@ -100,7 +100,7 @@ + alpha-*-*vms*) fmt=evax ;; + alpha-*-osf*) fmt=ecoff ;; + alpha-*-linuxecoff*) fmt=ecoff ;; +- alpha-*-linux-gnu*) fmt=elf em=linux ;; ++ alpha-*-linux-gnu* | alpha-*-linux-uclibc*) fmt=elf em=linux ;; + alpha-*-netbsd*) fmt=elf em=nbsd ;; + alpha-*-openbsd*) fmt=elf em=obsd ;; + +@@ -116,7 +116,7 @@ + arm-*-conix*) fmt=elf ;; + arm-*-linux*aout*) fmt=aout em=linux ;; + arm-*-linux-gnueabi*) fmt=elf em=armlinuxeabi ;; +- arm-*-linux-gnu*) fmt=elf em=linux ;; ++ arm-*-linux-gnu* | arm-*-linux-uclibc*) fmt=elf em=linux ;; + arm-*-uclinux*) fmt=elf em=linux ;; + arm-*-netbsdelf*) fmt=elf em=nbsd ;; + arm-*-*n*bsd*) fmt=aout em=nbsd ;; +@@ -128,7 +128,7 @@ + + avr-*-*) fmt=elf ;; + +- cris-*-linux-gnu* | crisv32-*-linux-gnu*) ++ cris-*-linux-gnu* | crisv32-*-linux-gnu* | cris-*-linux-uclibc* | crisv32-*-linux-uclibc*) + fmt=multi bfd_gas=yes em=linux ;; + cris-*-* | crisv32-*-*) fmt=multi bfd_gas=yes ;; + +@@ -192,7 +192,7 @@ + i386-*-linux*aout*) fmt=aout em=linux ;; + i386-*-linux*oldld) fmt=aout em=linux ;; + i386-*-linux*coff*) fmt=coff em=linux ;; +- i386-*-linux-gnu*) fmt=elf em=linux ;; ++ i386-*-linux-gnu* | i386-*-linux-uclibc*) fmt=elf em=linux ;; + i386-*-lynxos*) fmt=elf em=lynx bfd_gas=yes ;; + i386-*-sysv[45]*) fmt=elf ;; + i386-*-solaris*) fmt=elf ;; +@@ -238,7 +238,7 @@ + + ia64-*-elf*) fmt=elf ;; + ia64-*-aix*) fmt=elf em=ia64aix ;; +- ia64-*-linux-gnu*) fmt=elf em=linux ;; ++ ia64-*-linux-gnu* | ia64-*-linux-uclibc*) fmt=elf em=linux ;; + ia64-*-hpux*) fmt=elf em=hpux ;; + ia64-*-netbsd*) fmt=elf em=nbsd ;; + +@@ -265,7 +265,7 @@ + m68k-*-rtems*) fmt=elf ;; + m68k-*-hpux*) fmt=hp300 em=hp300 ;; + m68k-*-linux*aout*) fmt=aout em=linux ;; +- m68k-*-linux-gnu*) fmt=elf em=linux ;; ++ m68k-*-linux-gnu* | m68k-*-linux-uclibc*) fmt=elf em=linux ;; + m68k-*-uclinux*) fmt=elf ;; + m68k-*-gnu*) fmt=elf ;; + m68k-*-netbsdelf*) fmt=elf em=nbsd ;; +@@ -332,7 +332,7 @@ + ppc-*-beos*) fmt=coff ;; + ppc-*-*n*bsd* | ppc-*-elf*) fmt=elf ;; + ppc-*-eabi* | ppc-*-sysv4*) fmt=elf ;; +- ppc-*-linux-gnu*) fmt=elf em=linux ;; ++ ppc-*-linux-gnu* | ppc-*-linux-uclibc*) fmt=elf em=linux ;; + ppc-*-solaris*) fmt=elf ;; + ppc-*-rtems*) fmt=elf ;; + ppc-*-macos*) fmt=coff em=macos ;; +@@ -340,7 +340,7 @@ + ppc-*-kaos*) fmt=elf ;; + ppc-*-lynxos*) fmt=elf em=lynx bfd_gas=yes ;; + +- s390-*-linux-gnu*) fmt=elf em=linux ;; ++ s390-*-linux-gnu* | s390-*-linux-uclibc*) fmt=elf em=linux ;; + s390-*-tpf*) fmt=elf ;; + + sh*-*-linux*) fmt=elf em=linux +@@ -369,7 +369,7 @@ + sparc-*-aout | sparc*-*-vxworks*) fmt=aout em=sparcaout ;; + sparc-*-coff) fmt=coff ;; + sparc-*-linux*aout*) fmt=aout em=linux ;; +- sparc-*-linux-gnu*) fmt=elf em=linux ;; ++ sparc-*-linux-gnu* | sparc-*-linux-uclibc*) fmt=elf em=linux ;; + sparc-fujitsu-none) fmt=aout ;; + sparc-*-elf) fmt=elf ;; + sparc-*-sysv4*) fmt=elf ;; +@@ -398,7 +398,7 @@ + vax-*-netbsdelf*) fmt=elf em=nbsd ;; + vax-*-netbsd*) fmt=aout em=nbsd ;; + vax-*-bsd* | vax-*-ultrix*) fmt=aout ;; +- vax-*-linux-gnu*) fmt=elf em=linux bfd_gas=yes ;; ++ vax-*-linux-gnu* | vax-*-linux-uclibc*) fmt=elf em=linux bfd_gas=yes ;; + + w65-*-*) fmt=coff ;; + +--- binutils-2.16/gprof/configure.orig 2005-09-06 20:36:04.850983531 -0700 ++++ binutils-2.16/gprof/configure 2005-09-06 20:36:26.344336022 -0700 +@@ -3407,7 +3407,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu* | linux-uclibc*) + case $host_cpu in + alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* ) + lt_cv_deplibs_check_method=pass_all ;; +--- binutils-2.16/ld/configure.host.orig 2005-09-06 20:37:46.085353808 -0700 ++++ binutils-2.16/ld/configure.host 2005-09-06 20:40:03.381993341 -0700 +@@ -83,7 +83,7 @@ + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,ld\[^ \]\*,ld-linux,g"` + ;; + +-arm*-*-linux-gnu*) ++arm*-*-linux-gnu* | arm*-*-linux-uclibc*) + HOSTING_CRT0='-p '`echo "$HOSTING_CRT0" | sed -e "s,ld\[^ \]\*,ld-linux,g"` + ;; + +@@ -141,7 +141,7 @@ + HOSTING_LIBS="$HOSTING_LIBS"' -lcygwin -L/usr/lib/w32api -luser32 -lkernel32 -ladvapi32 -lshell32 `if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else ${CC} -print-libgcc-file-name; fi`' + ;; + +-ia64-*-linux-gnu*) ++ia64-*-linux-gnu* | ia64-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,ld\[^ \]*\*,ld-linux-ia64,g"` + ;; + +@@ -155,11 +155,11 @@ + HOSTING_LIBS='-L/usr/lib32 '"$HOSTING_LIBS"' `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o ; else ${CC} -print-file-name=crtend.o; fi` /usr/lib32/crtn.o -init __do_global_ctors -fini __do_global_dtors' + ;; + +-mips*-*-linux-gnu*) ++mips*-*-linux-gnu* | mips*-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,\\\`specs.*\"\\\`,/lib/ld.so.1,"` + ;; + +-m68*-*-linux-gnu*) ++m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,\\\`specs.*\"\\\`,/lib/ld.so.1,"` + ;; + +@@ -183,19 +183,19 @@ + HOSTING_LIBS="$HOSTING_LIBS"' `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else ${CC} -print-file-name=crtend.o; fi`' + ;; + +-powerpc64*-*-linux-gnu*) ++powerpc64*-*-linux-gnu* | powerpc64*-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,\\\`specs.*\"\\\`,/lib64/ld64.so.1,"` + ;; + +-powerpc*-*-linux-gnu*) ++powerpc*-*-linux-gnu* | powerpc*-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,\\\`specs.*\"\\\`,/lib/ld.so.1,"` + ;; + +-s390x-*-linux-gnu*) ++s390x-*-linux-gnu* | s390x-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,\\\`specs.*\"\\\`,/lib/ld64.so.1,"` + ;; + +-s390-*-linux-gnu*) ++s390-*-linux-gnu* | s390-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,\\\`specs.*\"\\\`,/lib/ld.so.1,"` + ;; + +@@ -209,15 +209,15 @@ + HOSTING_LIBS="$HOSTING_LIBS"' `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else ${CC} -print-file-name=crtend.o; fi` `if [ -f ../gcc/crtn.o ]; then echo ../gcc/crtn.o; else ${CC} -print-file-name=crtn.o; fi`' + ;; + +-sparc-*-linux-gnu*) ++sparc-*-linux-gnu* | sparc-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,\\\`specs.*\"\\\`,/lib/ld-linux.so.2,"` + ;; + +-sparc64-*-linux-gnu*) ++sparc64-*-linux-gnu* | sparc64-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,\\\`specs.*\"\\\`,/lib64/ld-linux.so.2,"` + ;; + +-x86_64-*-linux-gnu*) ++x86_64-*-linux-gnu* | x86_64-*-linux-uclibc*) + HOSTING_CRT0=`echo "$HOSTING_CRT0" | sed -e "s,\\\`specs.*\"\\\`,/lib64/ld-linux-x86-64.so.2,"` + ;; + +--- binutils-2.16/ld/configure.orig 2005-09-06 20:37:34.700637413 -0700 ++++ binutils-2.16/ld/configure 2005-09-06 20:37:46.013349277 -0700 +@@ -1568,7 +1568,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu* | linux-uclibc*) + case $host_cpu in + alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* ) + lt_cv_deplibs_check_method=pass_all ;; +--- binutils-2.16/ld/configure.tgt.orig 2005-09-06 20:40:03.413995355 -0700 ++++ binutils-2.16/ld/configure.tgt 2005-09-06 20:45:48.111685813 -0700 +@@ -30,7 +30,7 @@ + cris-*-*aout*) targ_emul=crisaout + targ_extra_emuls="criself crislinux" + targ_extra_libpath=$targ_extra_emuls ;; +-cris-*-linux-gnu* | cris-*-linux-gnu*) ++cris-*-linux-gnu* | cris-*-linux-gnu* | cris-*-linux-uclibc* | cris-*-linux-uclibc*) + targ_emul=crislinux ;; + cris-*-* | crisv32-*-*) targ_emul=criself + targ_extra_emuls="crisaout crislinux" +@@ -62,14 +62,14 @@ + tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/aout//'` + tdir_sun4=sparc-sun-sunos4 + ;; +-sparc64-*-linux-gnu*) targ_emul=elf64_sparc ++sparc64-*-linux-gnu* | sparc64-*-linux-uclibc*) targ_emul=elf64_sparc + targ_extra_emuls="elf32_sparc sparclinux sun4" + targ_extra_libpath=elf32_sparc + tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/64//'` + tdir_sparclinux=${tdir_elf32_sparc}aout + tdir_sun4=sparc-sun-sunos4 + ;; +-sparc*-*-linux-gnu*) targ_emul=elf32_sparc ++sparc*-*-linux-gnu* | sparc*-*-linux-uclibc*) targ_emul=elf32_sparc + targ_extra_emuls="sparclinux elf64_sparc sun4" + targ_extra_libpath=elf64_sparc + tdir_sparclinux=${targ_alias}aout +@@ -119,8 +119,8 @@ + ia64-*-aix*) targ_emul=elf64_aix ;; + m32r*le-*-elf*) targ_emul=m32rlelf ;; + m32r*-*-elf*) targ_emul=m32relf ;; +-m32r*le-*-linux-gnu*) targ_emul=m32rlelf_linux ;; +-m32r*-*-linux-gnu*) targ_emul=m32relf_linux ;; ++m32r*le-*-linux-gnu* | m32r*le-*-linux-uclibc*) targ_emul=m32rlelf_linux ;; ++m32r*-*-linux-gnu* | m32r*-*-linux-uclibc*) targ_emul=m32relf_linux ;; + m68hc11-*-*|m6811-*-*) targ_emul=m68hc11elf + targ_extra_emuls="m68hc11elfb m68hc12elf m68hc12elfb" ;; + m68hc12-*-*|m6812-*-*) targ_emul=m68hc12elf +@@ -131,7 +131,7 @@ + m68*-apple-aux*) targ_emul=m68kaux ;; + maxq-*-coff) targ_emul=maxqcoff;; + *-tandem-none) targ_emul=st2000 ;; +-i370-*-elf* | i370-*-linux-gnu*) targ_emul=elf32i370 ;; ++i370-*-elf* | i370-*-linux-gnu* | i370-*-linux-uclibc*) targ_emul=elf32i370 ;; + i[3-7]86-*-nto-qnx*) targ_emul=i386nto ;; + i[3-7]86-*-vsta) targ_emul=vsta ;; + i[3-7]86-go32-rtems*) targ_emul=i386go32 ;; +@@ -155,14 +155,14 @@ + tdir_elf_i386=`echo ${targ_alias} | sed -e 's/aout//'` + ;; + i[3-7]86-*-linux*oldld) targ_emul=i386linux; targ_extra_emuls=elf_i386 ;; +-i[3-7]86-*-linux-gnu*) targ_emul=elf_i386 ++i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) targ_emul=elf_i386 + targ_extra_emuls=i386linux + if test x${want64} = xtrue; then + targ_extra_emuls="$targ_extra_emuls elf_x86_64" + fi + tdir_i386linux=${targ_alias}aout + ;; +-x86_64-*-linux-gnu*) targ_emul=elf_x86_64 ++x86_64-*-linux-gnu* | x86_64-*-linux-uclibc*) targ_emul=elf_x86_64 + targ_extra_emuls="elf_i386 i386linux" + targ_extra_libpath=elf_i386 + tdir_i386linux=`echo ${targ_alias}aout | sed -e 's/x86_64/i386/'` +@@ -262,13 +262,14 @@ + arm-*-kaos*) targ_emul=armelf ;; + arm9e-*-elf) targ_emul=armelf ;; + arm*b-*-linux-gnueabi) targ_emul=armelfb_linux_eabi ;; +-arm*b-*-linux-gnu*) targ_emul=armelfb_linux; targ_extra_emuls=armelfb ;; ++arm*b-*-linux-gnu* | arm*b-*-linux-uclibc*) targ_emul=armelfb_linux; targ_extra_emuls=armelfb ;; + arm*-*-linux-gnueabi) targ_emul=armelf_linux_eabi ;; +-arm*-*-linux-gnu*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;; ++arm*-*-linux-gnu* | arm*-*-linux-uclibc*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;; + arm*-*-uclinux*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;; + arm-*-vxworks) targ_emul=armelf_vxworks ;; + arm*-*-conix*) targ_emul=armelf ;; +-thumb-*-linux-gnu* | thumb-*-uclinux*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;; ++thumb-*-linux-gnu* | thumb-*-linux-uclibc* | thumb-*-uclinux*) targ_emul=armelf_linux; targ_extra_emuls=armelf ;; ++thumbb-*-linux-gnu* | thumbb-*-linux-uclibc* | thumbb-*-uclinux*) targ_emul=armelfb_linux; targ_extra_emuls=armelfb ;; + strongarm-*-coff) targ_emul=armcoff ;; + strongarm-*-elf) targ_emul=armelf ;; + strongarm-*-kaos*) targ_emul=armelf ;; +@@ -372,7 +373,7 @@ + targ_extra_emuls=m68kelf + tdir_m68kelf=`echo ${targ_alias} | sed -e 's/aout//'` + ;; +-m68k-*-linux-gnu*) targ_emul=m68kelf ++m68k-*-linux-gnu* | m68k-*-linux-uclibc*) targ_emul=m68kelf + targ_extra_emuls=m68klinux + tdir_m68klinux=`echo ${targ_alias} | sed -e 's/linux/linuxaout/'` + ;; +@@ -388,9 +389,9 @@ + m68*-*-psos*) targ_emul=m68kpsos ;; + m68*-*-rtemscoff*) targ_emul=m68kcoff ;; + m68*-*-rtems*) targ_emul=m68kelf ;; +-hppa*64*-*-linux-gnu*) targ_emul=hppa64linux ;; ++hppa*64*-*-linux-gnu* | hppa*64*-*-linux-uclibc*) targ_emul=hppa64linux ;; + hppa*64*-*) targ_emul=elf64hppa ;; +-hppa*-*-linux-gnu*) targ_emul=hppalinux ;; ++hppa*-*-linux-gnu* | hppa*-*-linux-uclibc*) targ_emul=hppalinux ;; + hppa*-*-*elf*) targ_emul=hppaelf ;; + hppa*-*-lites*) targ_emul=hppaelf ;; + hppa*-*-netbsd*) targ_emul=hppanbsd ;; +@@ -402,7 +403,7 @@ + vax-*-netbsdaout* | vax-*-netbsd*) + targ_emul=vaxnbsd + targ_extra_emuls=elf32vax ;; +-vax-*-linux-gnu*) targ_emul=elf32vax ;; ++vax-*-linux-gnu* | vax-*-linux-uclibc*) targ_emul=elf32vax ;; + mips*-*-pe) targ_emul=mipspe ; + targ_extra_ofiles="deffilep.o pe-dll.o" ;; + mips*-dec-ultrix*) targ_emul=mipslit ;; +@@ -436,18 +437,18 @@ + mips*-*-vxworks*) targ_emul=elf32ebmip + targ_extra_emuls="elf32elmip" ;; + mips*-*-windiss) targ_emul=elf32mipswindiss ;; +-mips64*el-*-linux-gnu*) targ_emul=elf32ltsmipn32 ++mips64*el-*-linux-gnu* | mips64*el-*-linux-uclibc*) targ_emul=elf32ltsmipn32 + targ_extra_emuls="elf32btsmipn32 elf32ltsmip elf32btsmip elf64ltsmip elf64btsmip" + targ_extra_libpath="elf32ltsmip elf64ltsmip" + ;; +-mips64*-*-linux-gnu*) targ_emul=elf32btsmipn32 ++mips64*-*-linux-gnu* | mips64*-*-linux-uclibc*) targ_emul=elf32btsmipn32 + targ_extra_emuls="elf32ltsmipn32 elf32btsmip elf32ltsmip elf64btsmip elf64ltsmip" + targ_extra_libpath="elf32btsmip elf64btsmip" + ;; +-mips*el-*-linux-gnu*) targ_emul=elf32ltsmip ++mips*el-*-linux-gnu* | mips*el-*-linux-uclibc*) targ_emul=elf32ltsmip + targ_extra_emuls="elf32btsmip elf32ltsmipn32 elf64ltsmip elf32btsmipn32 elf64btsmip" + ;; +-mips*-*-linux-gnu*) targ_emul=elf32btsmip ++mips*-*-linux-gnu* | mips*-*-linux-uclibc*) targ_emul=elf32btsmip + targ_extra_emuls="elf32ltsmip elf32btsmipn32 elf64btsmip elf32ltsmipn32 elf64ltsmip" + ;; + mips*-*-lnews*) targ_emul=mipslnews ;; +@@ -467,7 +468,7 @@ + alpha*-*-linuxecoff*) targ_emul=alpha targ_extra_emuls=elf64alpha + tdir_elf64alpha=`echo ${targ_alias} | sed -e 's/ecoff//'` + ;; +-alpha*-*-linux-gnu*) targ_emul=elf64alpha targ_extra_emuls=alpha ++alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*) targ_emul=elf64alpha targ_extra_emuls=alpha + tdir_alpha=`echo ${targ_alias} | sed -e 's/linux/linuxecoff/'` + ;; + alpha*-*-osf*) targ_emul=alpha ;; +--- binutils-2.16/ld/emultempl/elf32.em.orig 2005-09-06 20:45:48.247694371 -0700 ++++ binutils-2.16/ld/emultempl/elf32.em 2005-09-06 20:46:39.158898011 -0700 +@@ -65,7 +65,7 @@ + + if [ "x${USE_LIBPATH}" = xyes ] ; then + case ${target} in +- *-*-linux-gnu*) ++ *-*-linux-gnu* | *-*-linux-uclibc*) + cat >>e${EMULATION_NAME}.c < +@@ -350,7 +350,7 @@ + + EOF + case ${target} in +- *-*-linux-gnu*) ++ *-*-linux-gnu* | *-*-linux-uclibc*) + cat >>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <>e${EMULATION_NAME}.c <name, force)) + break; +--- binutils-2.16/libtool.m4.orig 2005-09-06 20:46:55.131903129 -0700 ++++ binutils-2.16/libtool.m4 2005-09-06 20:47:07.364672889 -0700 +@@ -634,7 +634,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu* | linux-uclibc*) + case $host_cpu in + alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* ) + lt_cv_deplibs_check_method=pass_all ;; +--- binutils-2.16/ltconfig.orig 2005-09-06 20:47:13.965088227 -0700 ++++ binutils-2.16/ltconfig 2005-09-06 20:49:12.944575134 -0700 +@@ -1247,7 +1247,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu* | linux-uclibc*) + version_type=linux + need_lib_prefix=no + need_version=no +--- binutils-2.16/ltmain.sh.orig 2005-09-06 20:49:12.980577399 -0700 ++++ binutils-2.16/ltmain.sh 2005-09-06 20:50:15.180491393 -0700 +@@ -2600,7 +2600,7 @@ + versuffix="$major.$revision" + ;; + +- linux) ++ linux | linux-uclibc) + major=.`expr $current - $age` + versuffix="$major.$age.$revision" + ;; +--- binutils-2.16/opcodes/configure.orig 2005-09-06 20:50:15.220493910 -0700 ++++ binutils-2.16/opcodes/configure 2005-09-06 20:50:38.053930728 -0700 +@@ -3576,7 +3576,7 @@ + ;; + + # This must be Linux ELF. +-linux-gnu*) ++linux-gnu* | linux-uclibc*) + case $host_cpu in + alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* ) + lt_cv_deplibs_check_method=pass_all ;; diff --git a/meta/packages/binutils/binutils-2.16/binutils-2.16-objcopy-rename-errorcode.patch b/meta/packages/binutils/binutils-2.16/binutils-2.16-objcopy-rename-errorcode.patch new file mode 100644 index 000000000..e4372de88 --- /dev/null +++ b/meta/packages/binutils/binutils-2.16/binutils-2.16-objcopy-rename-errorcode.patch @@ -0,0 +1,29 @@ +# strip (and objcopy) fail to set the error code if there is no +# output file name and the rename of the stripped (or copied) file +# fails, yet the command fails to do anything. This fixes both +# objcopy and strip. +# +#Signed-off-by: John Bowler + +--- binutils-2.16/binutils/objcopy.c.orig 2006-01-31 11:15:38.797318519 -0800 ++++ binutils-2.16/binutils/objcopy.c 2006-01-31 11:15:40.463318516 -0800 +@@ -2434,7 +2434,8 @@ strip_main (int argc, char *argv[]) + if (preserve_dates) + set_times (tmpname, &statbuf); + if (output_file == NULL) +- smart_rename (tmpname, argv[i], preserve_dates); ++ if (smart_rename (tmpname, argv[i], preserve_dates)) ++ hold_status = 1; + status = hold_status; + } + else +@@ -3013,7 +3014,8 @@ copy_main (int argc, char *argv[]) + { + if (preserve_dates) + set_times (tmpname, &statbuf); +- smart_rename (tmpname, input_filename, preserve_dates); ++ if (smart_rename (tmpname, input_filename, preserve_dates)) ++ status = 1; + } + else + unlink (tmpname); diff --git a/meta/packages/binutils/binutils-2.16/binutils-2.16-thumb-glue.patch b/meta/packages/binutils/binutils-2.16/binutils-2.16-thumb-glue.patch new file mode 100644 index 000000000..59d8035f7 --- /dev/null +++ b/meta/packages/binutils/binutils-2.16/binutils-2.16-thumb-glue.patch @@ -0,0 +1,76 @@ +# The ARM->Thumb glue uses an ldr of the target function address, this +# simply doesn't work for PIC code, changed to use 4 word PIC glue +# +--- binutils-2.16/.pc/binutils-2.16-thumb-glue.patch/bfd/elf32-arm.c 2005-09-18 03:52:15.465165051 -0700 ++++ binutils-2.16/bfd/elf32-arm.c 2005-09-18 03:52:33.546302825 -0700 +@@ -1493,19 +1493,20 @@ + return myh; + } + +-/* ARM->Thumb glue: ++/* ARM->Thumb glue (PIC version): + + .arm + __func_from_arm: + ldr r12, __func_addr ++ add r12, r12, pc @ pc is __func_addr, so r12 is func + bx r12 + __func_addr: +- .word func @ behave as if you saw a ARM_32 reloc. */ ++ .word func-.+1 @ offset to actual function, low bit set */ + +-#define ARM2THUMB_GLUE_SIZE 12 +-static const insn32 a2t1_ldr_insn = 0xe59fc000; +-static const insn32 a2t2_bx_r12_insn = 0xe12fff1c; +-static const insn32 a2t3_func_addr_insn = 0x00000001; ++#define ARM2THUMB_GLUE_SIZE 16 ++static const insn32 a2t1_ldr_insn = 0xe59fc004; ++static const insn32 a2t2_add_r12_insn = 0xe08fc00c; ++static const insn32 a2t3_bx_r12_insn = 0xe12fff1c; + + /* Thumb->ARM: Thumb->(non-interworking aware) ARM + +@@ -2187,6 +2188,8 @@ + + if ((my_offset & 0x01) == 0x01) + { ++ long int ret_offset; ++ + if (sym_sec != NULL + && sym_sec->owner != NULL + && !INTERWORK_FLAG (sym_sec->owner)) +@@ -2203,12 +2206,31 @@ + bfd_put_32 (output_bfd, (bfd_vma) a2t1_ldr_insn, + s->contents + my_offset); + +- bfd_put_32 (output_bfd, (bfd_vma) a2t2_bx_r12_insn, ++ bfd_put_32 (output_bfd, (bfd_vma) a2t2_add_r12_insn, + s->contents + my_offset + 4); + +- /* It's a thumb address. Add the low order bit. */ +- bfd_put_32 (output_bfd, val | a2t3_func_addr_insn, ++ bfd_put_32 (output_bfd, (bfd_vma) a2t3_bx_r12_insn, + s->contents + my_offset + 8); ++ ++ /* Calculate the offset to the actual function. */ ++ ret_offset = ++ /* Address of destination of the stub. */ ++ ((bfd_signed_vma) val) ++ - ((bfd_signed_vma) ++ /* Offset from the start of the current section ++ to the start of the stubs. */ ++ (s->output_offset ++ /* Offset of the start of this stub from the start of the stubs. */ ++ + my_offset ++ /* Address of the start of the current section. */ ++ + s->output_section->vma) ++ /* The word is 12 bytes into the stub. */ ++ + 12 ++ /* The destination is a thumb function so the bottom bit must be set. */ ++ - 1); ++ ++ bfd_put_32 (output_bfd, (bfd_vma) ret_offset, ++ s->contents + my_offset + 12); + } + + BFD_ASSERT (my_offset <= globals->arm_glue_size); diff --git a/meta/packages/binutils/binutils-2.16/binutils-2.16-thumb-trampoline.patch b/meta/packages/binutils/binutils-2.16/binutils-2.16-thumb-trampoline.patch new file mode 100644 index 000000000..a4f90a725 --- /dev/null +++ b/meta/packages/binutils/binutils-2.16/binutils-2.16-thumb-trampoline.patch @@ -0,0 +1,292 @@ +--- binutils-2.16/.pc/binutils-2.16-thumb-trampoline.patch/bfd/elf32-arm.c 2005-05-02 12:43:06.000000000 -0700 ++++ binutils-2.16/bfd/elf32-arm.c 2005-09-19 22:58:49.834931044 -0700 +@@ -24,6 +24,8 @@ + #include "libbfd.h" + #include "elf-bfd.h" + ++#define NOTE_DEBUG 0 ++ + #ifndef NUM_ELEM + #define NUM_ELEM(a) (sizeof (a) / (sizeof (a)[0])) + #endif +@@ -1127,6 +1129,10 @@ + used, we need to record the index into .got.plt instead of + recomputing it from the PLT offset. */ + bfd_signed_vma plt_got_offset; ++ ++ /* This is used to sanity check that the Thumb trampoline space ++ really was allocated. */ ++ int accomodate_trampoline; + }; + + /* Traverse an arm ELF linker hash table. */ +@@ -1219,9 +1225,15 @@ + table, string)); + if (ret != NULL) + { ++#if NOTE_DEBUG ++ _bfd_error_handler( ++ _("NOTE: %x(%s): New hash entry (plt refcount %d)"), ++ ret, string, ret->root.plt.refcount); ++#endif + ret->relocs_copied = NULL; + ret->plt_thumb_refcount = 0; + ret->plt_got_offset = -1; ++ ret->accomodate_trampoline = 0; + } + + return (struct bfd_hash_entry *) ret; +@@ -1335,16 +1347,38 @@ + eind->relocs_copied = NULL; + } + +- /* If the direct symbol already has an associated PLT entry, the +- indirect symbol should not. If it doesn't, swap refcount information +- from the indirect symbol. */ +- if (edir->plt_thumb_refcount == 0) ++ if (ind->root.type == bfd_link_hash_indirect) + { +- edir->plt_thumb_refcount = eind->plt_thumb_refcount; +- eind->plt_thumb_refcount = 0; ++ bfd_signed_vma tmp; ++ bfd_signed_vma lowest_valid = bed->can_refcount; ++ ++ /* If the direct symbol already has an associated PLT entry, the ++ indirect symbol should not. If it doesn't, swap refcount information ++ from the indirect symbol. */ ++#if NOTE_DEBUG ++ _bfd_error_handler(_("NOTE: %x(%s,%d,%d) <== %x(%s,%d,%d)"), ++ dir, dir->root.root.string, dir->plt.refcount, edir->plt_thumb_refcount, ++ ind, ind->root.root.string, ind->plt.refcount, eind->plt_thumb_refcount); ++#endif ++ ++ /* Copy over the global and procedure linkage table refcount entries. ++ These may have been already set up by a check_relocs routine. This ++ code duplicates that for the plt refcount in elf.c ++ _bfd_elf_link_hash_copy_indirect */ ++ tmp = dir->plt.refcount; ++ /* this obfuscated test evaluates to bed->can_refcount && plt.refcount == 0 ++ * || plt.refcount < 0. ++ */ ++ if (tmp < lowest_valid) ++ { ++ tmp = edir->plt_thumb_refcount; ++ edir->plt_thumb_refcount = eind->plt_thumb_refcount; ++ eind->plt_thumb_refcount = tmp; ++ BFD_ASSERT(eind->accomodate_trampoline == 0); ++ } ++ else ++ BFD_ASSERT (eind->plt_thumb_refcount == 0); + } +- else +- BFD_ASSERT (eind->plt_thumb_refcount == 0); + + _bfd_elf_link_hash_copy_indirect (bed, dir, ind); + } +@@ -2060,7 +2094,7 @@ + (*_bfd_error_handler) + (_("%B(%s): warning: interworking not enabled.\n" + " first occurrence: %B: thumb call to arm"), +- sym_sec->owner, input_bfd, name); ++ sym_sec->owner, name, input_bfd); + + return FALSE; + } +@@ -2165,7 +2199,7 @@ + (*_bfd_error_handler) + (_("%B(%s): warning: interworking not enabled.\n" + " first occurrence: %B: arm call to thumb"), +- sym_sec->owner, input_bfd, name); ++ sym_sec->owner, name, input_bfd); + } + + --my_offset; +@@ -2481,7 +2515,7 @@ + instruction instead ? */ + if (sym_flags != STT_ARM_TFUNC) + (*_bfd_error_handler) +- (_("\%B: Warning: Arm BLX instruction targets Arm function '%s'."), ++ (_("%B: Warning: Arm BLX instruction targets Arm function '%s'."), + input_bfd, + h ? h->root.root.string : "(local)"); + } +@@ -2697,6 +2731,20 @@ + /* Handle calls via the PLT. */ + if (h != NULL && splt != NULL && h->plt.offset != (bfd_vma) -1) + { ++ struct elf32_arm_link_hash_entry *eh; ++ eh = (struct elf32_arm_link_hash_entry *) h; ++ if (!eh->accomodate_trampoline) ++ { ++ /* %B of output_bfd crashes here, so %x is used instead */ ++ _bfd_error_handler( ++ _("ERROR: %B: %x(%s): missing thumb trampoline, refcount(thumb %d, plt %d) in %x at %x+%x+%x"), ++ input_bfd, h, h->root.root.string, eh->plt_thumb_refcount, ++ h->plt.refcount, output_bfd, splt->output_section->vma, ++ splt->output_offset, h->plt.offset); ++ /* The relocation would point to garbage, it gets skipped... */ ++ return bfd_reloc_dangerous; ++ } ++ + value = (splt->output_section->vma + + splt->output_offset + + h->plt.offset); +@@ -3525,8 +3573,9 @@ + { + _bfd_error_handler + (_("ERROR: Source object %B has EABI version %d, but target %B has EABI version %d"), +- ibfd, obfd, ++ ibfd, + (in_flags & EF_ARM_EABIMASK) >> 24, ++ obfd, + (out_flags & EF_ARM_EABIMASK) >> 24); + return FALSE; + } +@@ -3538,8 +3587,9 @@ + { + _bfd_error_handler + (_("ERROR: %B is compiled for APCS-%d, whereas target %B uses APCS-%d"), +- ibfd, obfd, ++ ibfd, + in_flags & EF_ARM_APCS_26 ? 26 : 32, ++ obfd, + out_flags & EF_ARM_APCS_26 ? 26 : 32); + flags_compatible = FALSE; + } +@@ -3903,10 +3953,18 @@ + eh = (struct elf32_arm_link_hash_entry *) h; + + if (h->plt.refcount > 0) ++ h->plt.refcount -= 1; ++ ++ if (ELF32_R_TYPE (rel->r_info) == R_ARM_THM_PC22) + { +- h->plt.refcount -= 1; +- if (ELF32_R_TYPE (rel->r_info) == R_ARM_THM_PC22) +- eh->plt_thumb_refcount--; ++ BFD_ASSERT (eh->plt_thumb_refcount > 0); ++ eh->plt_thumb_refcount--; ++ BFD_ASSERT (eh->accomodate_trampoline == 0); ++#if NOTE_DEBUG ++ _bfd_error_handler( ++ _("NOTE: %B: %x(%s): Thumb refcount decremented to %d (plt refcount %d)"), ++ abfd, h, h->root.root.string, eh->plt_thumb_refcount, h->plt.refcount); ++#endif + } + + if (r_type == R_ARM_ABS32 +@@ -3994,6 +4052,10 @@ + h = sym_hashes[r_symndx - symtab_hdr->sh_info]; + + eh = (struct elf32_arm_link_hash_entry *) h; ++#if NOTE_DEBUG ++ if (h != NULL) ++ _bfd_error_handler(_("NOTE: %B: %x(%s): verify relocation"), abfd, h, h->root.root.string); ++#endif + + switch (r_type) + { +@@ -4078,10 +4140,30 @@ + + /* If we create a PLT entry, this relocation will reference + it, even if it's an ABS32 relocation. */ +- h->plt.refcount += 1; ++ if (h->plt.refcount >= 0) ++ h->plt.refcount += 1; ++ else ++ { ++ /* This happens, I suspect it happens with glue code because, ++ * somehow, the backend data had can_refcount==0. Expert required... ++ */ ++ _bfd_error_handler( ++ _("WARNING: %B: %x(%s): PLT refcount was %d (set to 1)"), ++ abfd, h, h->root.root.string, h->plt.refcount); ++ h->plt.refcount = 1; ++ } + + if (r_type == R_ARM_THM_PC22) +- eh->plt_thumb_refcount += 1; ++ { ++ eh->plt_thumb_refcount += 1; ++ BFD_ASSERT (eh->plt_thumb_refcount <= h->plt.refcount); ++ BFD_ASSERT (eh->accomodate_trampoline == 0); ++#if NOTE_DEBUG ++ _bfd_error_handler( ++ _("NOTE: %B: %x(%s): Thumb refcount incremented to %d (plt refcount %d)"), ++ abfd, h, h->root.root.string, eh->plt_thumb_refcount, h->plt.refcount); ++#endif ++ } + } + + /* If we are creating a shared library or relocatable executable, +@@ -4376,8 +4458,15 @@ + object, or if all references were garbage collected. In + such a case, we don't actually need to build a procedure + linkage table, and we can just do a PC24 reloc instead. */ ++#if NOTE_DEBUG ++ _bfd_error_handler( ++ _("NOTE: %x(%s): Thumb refcount zeroed (plt refcount %d, thumb %d) (%s)"), ++ h, h->root.root.string, h->plt.refcount, eh->plt_thumb_refcount, ++ SYMBOL_CALLS_LOCAL (info, h) ? "local call" : "invisible"); ++#endif + h->plt.offset = (bfd_vma) -1; + eh->plt_thumb_refcount = 0; ++ BFD_ASSERT (eh->accomodate_trampoline == 0); + h->needs_plt = 0; + } + +@@ -4390,8 +4479,14 @@ + in check_relocs. We can't decide accurately between function + and non-function syms in check-relocs; Objects loaded later in + the link may change h->type. So fix it now. */ ++#if NOTE_DEBUG ++ _bfd_error_handler( ++ _("NOTE: %x(%s): Thumb refcount zeroed (%d, plt refcount %d)"), ++ h, h->root.root.string, eh->plt_thumb_refcount, h->plt.refcount); ++#endif + h->plt.offset = (bfd_vma) -1; + eh->plt_thumb_refcount = 0; ++ BFD_ASSERT (eh->accomodate_trampoline == 0); + } + + /* If this is a weak symbol, and there is a real definition, the +@@ -4521,8 +4616,14 @@ + for it. */ + if (!htab->symbian_p && eh->plt_thumb_refcount > 0) + { ++#if NOTE_DEBUG ++ _bfd_error_handler(_("NOTE: %x(%s): Thumb trampoline created at %x"), ++ h, h->root.root.string, h->plt.offset); ++#endif + h->plt.offset += PLT_THUMB_STUB_SIZE; + s->size += PLT_THUMB_STUB_SIZE; ++ BFD_ASSERT (eh->accomodate_trampoline == 0); ++ eh->accomodate_trampoline = 1; + } + + /* If this symbol is not defined in a regular file, and we are +@@ -5014,10 +5115,20 @@ + + if (eh->plt_thumb_refcount > 0) + { +- bfd_put_16 (output_bfd, elf32_arm_plt_thumb_stub[0], +- splt->contents + h->plt.offset - 4); +- bfd_put_16 (output_bfd, elf32_arm_plt_thumb_stub[1], +- splt->contents + h->plt.offset - 2); ++ if (eh->accomodate_trampoline == 1) ++ { ++ bfd_put_16 (output_bfd, elf32_arm_plt_thumb_stub[0], ++ splt->contents + h->plt.offset - 4); ++ bfd_put_16 (output_bfd, elf32_arm_plt_thumb_stub[1], ++ splt->contents + h->plt.offset - 2); ++ } ++ else ++ { ++ (*_bfd_error_handler) ( ++ _("%B: no space for THUMB trampoline at %x[%x]"), ++ output_bfd, h->plt.offset, got_offset); ++ return FALSE; ++ } + } + + bfd_put_32 (output_bfd, elf32_arm_plt_entry[0] | ((got_displacement & 0x0ff00000) >> 20), diff --git a/meta/packages/binutils/binutils-cross.inc b/meta/packages/binutils/binutils-cross.inc new file mode 100644 index 000000000..c63ea687a --- /dev/null +++ b/meta/packages/binutils/binutils-cross.inc @@ -0,0 +1,30 @@ +SECTION = "devel" +inherit cross +DEPENDS += "flex-native bison-native" +PROVIDES = "virtual/${TARGET_PREFIX}binutils" +PACKAGES = "" +EXTRA_OECONF = "--with-sysroot=${CROSS_DIR}/${TARGET_SYS} \ + --program-prefix=${TARGET_PREFIX}" + +do_stage () { + oe_runmake install + + # We don't really need these, so we'll remove them... + rm -rf ${CROSS_DIR}/lib/ldscripts + rm -rf ${CROSS_DIR}/share/info + rm -rf ${CROSS_DIR}/share/locale + rm -rf ${CROSS_DIR}/share/man + rmdir ${CROSS_DIR}/share || : + rmdir ${CROSS_DIR}/${libdir}/gcc-lib || : + rmdir ${CROSS_DIR}/${libdir} || : + rmdir ${CROSS_DIR}/${prefix} || : + + # We want to move this into the target specific location + mkdir -p ${CROSS_DIR}/${TARGET_SYS}/lib + mv -f ${CROSS_DIR}/lib/libiberty.a ${CROSS_DIR}/${TARGET_SYS}/lib + rmdir ${CROSS_DIR}/lib || : +} + +do_install () { + : +} diff --git a/meta/packages/binutils/binutils-cross_2.15.94.0.1.bb b/meta/packages/binutils/binutils-cross_2.15.94.0.1.bb new file mode 100644 index 000000000..7e165271d --- /dev/null +++ b/meta/packages/binutils/binutils-cross_2.15.94.0.1.bb @@ -0,0 +1,32 @@ +SECTION = "devel" +include binutils_${PV}.bb +inherit cross +DEPENDS += "flex-native bison-native" +PROVIDES = "virtual/${TARGET_PREFIX}binutils" +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/binutils-${PV}" +PACKAGES = "" +EXTRA_OECONF = "--with-sysroot=${CROSS_DIR}/${TARGET_SYS} \ + --program-prefix=${TARGET_PREFIX}" + +do_stage () { + oe_runmake install + + # We don't really need these, so we'll remove them... + rm -rf ${CROSS_DIR}/lib/ldscripts + rm -rf ${CROSS_DIR}/share/info + rm -rf ${CROSS_DIR}/share/locale + rm -rf ${CROSS_DIR}/share/man + rmdir ${CROSS_DIR}/share || : + rmdir ${CROSS_DIR}/${libdir}/gcc-lib || : + rmdir ${CROSS_DIR}/${libdir} || : + rmdir ${CROSS_DIR}/${prefix} || : + + # We want to move this into the target specific location + mkdir -p ${CROSS_DIR}/${TARGET_SYS}/lib + mv -f ${CROSS_DIR}/lib/libiberty.a ${CROSS_DIR}/${TARGET_SYS}/lib + rmdir ${CROSS_DIR}/lib || : +} + +do_install () { + : +} diff --git a/meta/packages/binutils/binutils-cross_2.16.91.0.7.bb b/meta/packages/binutils/binutils-cross_2.16.91.0.7.bb new file mode 100644 index 000000000..7e165271d --- /dev/null +++ b/meta/packages/binutils/binutils-cross_2.16.91.0.7.bb @@ -0,0 +1,32 @@ +SECTION = "devel" +include binutils_${PV}.bb +inherit cross +DEPENDS += "flex-native bison-native" +PROVIDES = "virtual/${TARGET_PREFIX}binutils" +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/binutils-${PV}" +PACKAGES = "" +EXTRA_OECONF = "--with-sysroot=${CROSS_DIR}/${TARGET_SYS} \ + --program-prefix=${TARGET_PREFIX}" + +do_stage () { + oe_runmake install + + # We don't really need these, so we'll remove them... + rm -rf ${CROSS_DIR}/lib/ldscripts + rm -rf ${CROSS_DIR}/share/info + rm -rf ${CROSS_DIR}/share/locale + rm -rf ${CROSS_DIR}/share/man + rmdir ${CROSS_DIR}/share || : + rmdir ${CROSS_DIR}/${libdir}/gcc-lib || : + rmdir ${CROSS_DIR}/${libdir} || : + rmdir ${CROSS_DIR}/${prefix} || : + + # We want to move this into the target specific location + mkdir -p ${CROSS_DIR}/${TARGET_SYS}/lib + mv -f ${CROSS_DIR}/lib/libiberty.a ${CROSS_DIR}/${TARGET_SYS}/lib + rmdir ${CROSS_DIR}/lib || : +} + +do_install () { + : +} diff --git a/meta/packages/binutils/binutils-cross_2.16.bb b/meta/packages/binutils/binutils-cross_2.16.bb new file mode 100644 index 000000000..df0f17b1e --- /dev/null +++ b/meta/packages/binutils/binutils-cross_2.16.bb @@ -0,0 +1,3 @@ +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/binutils-${PV}" +include binutils_${PV}.bb +include binutils-cross.inc diff --git a/meta/packages/binutils/binutils.inc b/meta/packages/binutils/binutils.inc new file mode 100644 index 000000000..680e579a0 --- /dev/null +++ b/meta/packages/binutils/binutils.inc @@ -0,0 +1,117 @@ +inherit autotools gettext + +PACKAGES = "${PN} ${PN}-dev ${PN}-doc ${PN}-symlinks" + +FILES_${PN} = " \ + ${bindir}/${TARGET_PREFIX}* \ + ${libdir}/lib*-*.so \ + ${prefix}/${TARGET_SYS}/bin/*" + +FILES_${PN}-dev = " \ + ${includedir} \ + ${libdir}/*.a \ + ${libdir}/*.la \ + ${libdir}/libbfd.so \ + ${libdir}/libopcodes.so" + +FILES_${PN}-symlinks = " \ + ${bindir}/addr2line \ + ${bindir}/as \ + ${bindir}/c++filt \ + ${bindir}/gprof \ + ${bindir}/ld \ + ${bindir}/nm \ + ${bindir}/objcopy \ + ${bindir}/objdump \ + ${bindir}/ranlib \ + ${bindir}/readelf \ + ${bindir}/size \ + ${bindir}/strip" + +EXTRA_OECONF = "--program-prefix=${TARGET_PREFIX} \ + --enable-shared" + +# This is necessary due to a bug in the binutils Makefiles +EXTRA_OEMAKE = "configure-build-libiberty all" + +export AR = "${HOST_PREFIX}ar" +export AS = "${HOST_PREFIX}as" +export LD = "${HOST_PREFIX}ld" +export NM = "${HOST_PREFIX}nm" +export RANLIB = "${HOST_PREFIX}ranlib" +export OBJCOPY = "${HOST_PREFIX}objcopy" +export OBJDUMP = "${HOST_PREFIX}objdump" + +export AR_FOR_TARGET = "${TARGET_PREFIX}ar" +export AS_FOR_TARGET = "${TARGET_PREFIX}as" +export LD_FOR_TARGET = "${TARGET_PREFIX}ld" +export NM_FOR_TARGET = "${TARGET_PREFIX}nm" +export RANLIB_FOR_TARGET = "${TARGET_PREFIX}ranlib" + +export CC_FOR_HOST = "${CCACHE} ${HOST_PREFIX}gcc ${HOST_CC_ARCH}" +export CXX_FOR_HOST = "${CCACHE} ${HOST_PREFIX}gcc ${HOST_CC_ARCH}" + +export CC_FOR_BUILD = "${BUILD_CC}" +export CPP_FOR_BUILD = "${BUILD_CPP}" +export CFLAGS_FOR_BUILD = "${BUILD_CFLAGS}" + +export CC = "${CCACHE} ${HOST_PREFIX}gcc ${HOST_CC_ARCH}" + +do_configure () { + (cd ${S}; gnu-configize) || die "Failed to run gnu-configize" + oe_runconf +} + +do_stage () { + oe_libinstall -so -a -C opcodes libopcodes ${STAGING_LIBDIR}/ + oe_libinstall -a -C libiberty libiberty ${STAGING_LIBDIR}/ + oe_libinstall -so -a -C bfd libbfd ${STAGING_LIBDIR}/ + install -m 0644 ${S}/include/dis-asm.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/symcat.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/libiberty.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/ansidecl.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/bfdlink.h ${STAGING_INCDIR}/ + install -m 0644 bfd/bfd.h ${STAGING_INCDIR}/ +} + +do_install () { + autotools_do_install + + # We don't really need these, so we'll remove them... + rm -rf ${D}${libdir}/ldscripts + + # Fix the /usr/${TARGET_SYS}/bin/* links + for l in ${D}${prefix}/${TARGET_SYS}/bin/*; do + rm -f $l + ln -sf `echo ${prefix}/${TARGET_SYS}/bin \ + | tr -s / \ + | sed -e 's,^/,,' -e 's,[^/]*,..,g'`${bindir}/${TARGET_PREFIX}`basename $l` $l + done + + # Install the libiberty header + install -d ${D}${includedir} + install -m 644 ${S}/include/ansidecl.h ${D}${includedir} + install -m 644 ${S}/include/libiberty.h ${D}${includedir} + + cd ${D}${bindir} + + # Symlinks for ease of running these on the native target + for p in ${TARGET_SYS}-* ; do + ln -sf $p `echo $p | sed -e s,${TARGET_SYS}-,,` + done + + rm ${D}${bindir}/ar ${D}${bindir}/strings +} + + +pkg_postinst_${PN}-symlinks () { + update-alternatives --install ${bindir}/ar ar ${TARGET_SYS}-ar 100 + update-alternatives --install ${bindir}/strings strings ${TARGET_SYS}-strings 100 +} + + +pkg_prerm_${PN}-symlinks () { + update-alternatives --remove ar ${TARGET_SYS}-ar + update-alternatives --remove strings ${TARGET_SYS}-strings +} + diff --git a/meta/packages/binutils/binutils_2.15.94.0.1.bb b/meta/packages/binutils/binutils_2.15.94.0.1.bb new file mode 100644 index 000000000..2b2996abe --- /dev/null +++ b/meta/packages/binutils/binutils_2.15.94.0.1.bb @@ -0,0 +1,124 @@ +DESCRIPTION = "A GNU collection of binary utilities" +HOMEPAGE = "http://www.gnu.org/software/binutils/" +SECTION = "devel" +LICENSE = "GPL" +MAINTAINER = "Gerald Britton " +PR = "r2" + +inherit autotools gettext + +PACKAGES = "${PN} ${PN}-dev ${PN}-doc ${PN}-symlinks" + +FILES_${PN} = " \ + ${bindir}/${TARGET_PREFIX}* \ + ${libdir}/lib*-*.so \ + ${prefix}/${TARGET_SYS}/bin/*" + +FILES_${PN}-dev = " \ + ${includedir} \ + ${libdir}/*.a \ + ${libdir}/*.la \ + ${libdir}/libbfd.so \ + ${libdir}/libopcodes.so" + +FILES_${PN}-symlinks = " \ + ${bindir}/addr2line \ + ${bindir}/ar \ + ${bindir}/as \ + ${bindir}/c++filt \ + ${bindir}/gprof \ + ${bindir}/ld \ + ${bindir}/nm \ + ${bindir}/objcopy \ + ${bindir}/objdump \ + ${bindir}/ranlib \ + ${bindir}/readelf \ + ${bindir}/size \ + ${bindir}/strings \ + ${bindir}/strip" + +SRC_URI = \ + "http://ftp.kernel.org/pub/linux/devel/binutils/binutils-${PV}.tar.bz2 \ + file://ld_makefile.patch;patch=1 \ + file://better_file_error.patch;patch=1 \ + file://signed_char_fix.patch;patch=1 \ + file://objdump_fix.patch;patch=1 \ + file://binutils-100_cflags_for_build.patch;patch=1 \ + file://binutils-2.15.91.0.1-uclibc-100-conf.patch;patch=1 \ + file://binutils-2.15.90.0.3-uclibc-200-build_modules.patch;patch=1" + +S = "${WORKDIR}/binutils-${PV}" +B = "${S}/build.${HOST_SYS}.${TARGET_SYS}" + +EXTRA_OECONF = "--program-prefix=${TARGET_PREFIX} \ + --enable-shared" + +# This is necessary due to a bug in the binutils Makefiles +EXTRA_OEMAKE = "configure-build-libiberty all" + +export AR = "${HOST_PREFIX}ar" +export AS = "${HOST_PREFIX}as" +export LD = "${HOST_PREFIX}ld" +export NM = "${HOST_PREFIX}nm" +export RANLIB = "${HOST_PREFIX}ranlib" +export OBJCOPY = "${HOST_PREFIX}objcopy" +export OBJDUMP = "${HOST_PREFIX}objdump" + +export AR_FOR_TARGET = "${TARGET_PREFIX}ar" +export AS_FOR_TARGET = "${TARGET_PREFIX}as" +export LD_FOR_TARGET = "${TARGET_PREFIX}ld" +export NM_FOR_TARGET = "${TARGET_PREFIX}nm" +export RANLIB_FOR_TARGET = "${TARGET_PREFIX}ranlib" + +export CC_FOR_HOST = "${CCACHE} ${HOST_PREFIX}gcc ${HOST_CC_ARCH}" +export CXX_FOR_HOST = "${CCACHE} ${HOST_PREFIX}gcc ${HOST_CC_ARCH}" + +export CC_FOR_BUILD = "${BUILD_CC}" +export CPP_FOR_BUILD = "${BUILD_CPP}" +export CFLAGS_FOR_BUILD = "${BUILD_CFLAGS}" + +export CC = "${CCACHE} ${HOST_PREFIX}gcc ${HOST_CC_ARCH}" + +do_configure () { + (cd ${S}; gnu-configize) || die "Failed to run gnu-configize" + oe_runconf +} + +do_stage () { + oe_libinstall -so -a -C opcodes libopcodes ${STAGING_LIBDIR}/ + oe_libinstall -a -C libiberty libiberty ${STAGING_LIBDIR}/ + oe_libinstall -so -a -C bfd libbfd ${STAGING_LIBDIR}/ + install -m 0644 ${S}/include/dis-asm.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/symcat.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/libiberty.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/ansidecl.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/bfdlink.h ${STAGING_INCDIR}/ + install -m 0644 bfd/bfd.h ${STAGING_INCDIR}/ +} + +do_install () { + autotools_do_install + + # We don't really need these, so we'll remove them... + rm -rf ${D}${libdir}/ldscripts + + # Fix the /usr/${TARGET_SYS}/bin/* links + for l in ${D}${prefix}/${TARGET_SYS}/bin/*; do + rm -f $l + ln -sf `echo ${prefix}/${TARGET_SYS}/bin \ + | tr -s / \ + | sed -e 's,^/,,' -e 's,[^/]*,..,g'`${bindir}/${TARGET_PREFIX}`basename $l` $l + done + + # Install the libiberty header + install -d ${D}${includedir} + install -m 644 ${S}/include/ansidecl.h ${D}${includedir} + install -m 644 ${S}/include/libiberty.h ${D}${includedir} + + cd ${D}${bindir} + + # Symlinks for ease of running these on the native target + for p in ${TARGET_SYS}-* ; do + ln -sf $p `echo $p | sed -e s,${TARGET_SYS}-,,` + done +} diff --git a/meta/packages/binutils/binutils_2.16.91.0.7.bb b/meta/packages/binutils/binutils_2.16.91.0.7.bb new file mode 100644 index 000000000..664fce8cb --- /dev/null +++ b/meta/packages/binutils/binutils_2.16.91.0.7.bb @@ -0,0 +1,123 @@ +DESCRIPTION = "A GNU collection of binary utilities" +HOMEPAGE = "http://www.gnu.org/software/binutils/" +SECTION = "devel" +LICENSE = "GPL" +DEFAULT_PREFERENCE = "-1" + +inherit autotools gettext + +PACKAGES = "${PN} ${PN}-dev ${PN}-doc ${PN}-symlinks" + +FILES_${PN} = " \ + ${bindir}/${TARGET_PREFIX}* \ + ${libdir}/lib*-*.so \ + ${prefix}/${TARGET_SYS}/bin/*" + +FILES_${PN}-dev = " \ + ${includedir} \ + ${libdir}/*.a \ + ${libdir}/*.la \ + ${libdir}/libbfd.so \ + ${libdir}/libopcodes.so" + +FILES_${PN}-symlinks = " \ + ${bindir}/addr2line \ + ${bindir}/ar \ + ${bindir}/as \ + ${bindir}/c++filt \ + ${bindir}/gprof \ + ${bindir}/ld \ + ${bindir}/nm \ + ${bindir}/objcopy \ + ${bindir}/objdump \ + ${bindir}/ranlib \ + ${bindir}/readelf \ + ${bindir}/size \ + ${bindir}/strings \ + ${bindir}/strip" + +SRC_URI = \ + "http://ftp.kernel.org/pub/linux/devel/binutils/binutils-${PV}.tar.bz2 \ + file://binutils-2.16.91.0.6-objcopy-rename-errorcode.patch;patch=1 \ + file://binutils-uclibc-100-uclibc-conf.patch;patch=1 \ + file://binutils-uclibc-300-001_ld_makefile_patch.patch;patch=1 \ + file://binutils-uclibc-300-006_better_file_error.patch;patch=1 \ + file://binutils-uclibc-300-012_check_ldrunpath_length.patch;patch=1 \ + file://binutils-uclibc-400-mips-ELF_MAXPAGESIZE-4K.patch;patch=1 \ + file://binutils-uclibc-702-binutils-skip-comments.patch;patch=1" + +S = "${WORKDIR}/binutils-${PV}" +B = "${S}/build.${HOST_SYS}.${TARGET_SYS}" + +EXTRA_OECONF = "--program-prefix=${TARGET_PREFIX} \ + --enable-shared" + +# This is necessary due to a bug in the binutils Makefiles +EXTRA_OEMAKE = "configure-build-libiberty all" + +export AR = "${HOST_PREFIX}ar" +export AS = "${HOST_PREFIX}as" +export LD = "${HOST_PREFIX}ld" +export NM = "${HOST_PREFIX}nm" +export RANLIB = "${HOST_PREFIX}ranlib" +export OBJCOPY = "${HOST_PREFIX}objcopy" +export OBJDUMP = "${HOST_PREFIX}objdump" + +export AR_FOR_TARGET = "${TARGET_PREFIX}ar" +export AS_FOR_TARGET = "${TARGET_PREFIX}as" +export LD_FOR_TARGET = "${TARGET_PREFIX}ld" +export NM_FOR_TARGET = "${TARGET_PREFIX}nm" +export RANLIB_FOR_TARGET = "${TARGET_PREFIX}ranlib" + +export CC_FOR_HOST = "${CCACHE} ${HOST_PREFIX}gcc ${HOST_CC_ARCH}" +export CXX_FOR_HOST = "${CCACHE} ${HOST_PREFIX}gcc ${HOST_CC_ARCH}" + +export CC_FOR_BUILD = "${BUILD_CC}" +export CPP_FOR_BUILD = "${BUILD_CPP}" +export CFLAGS_FOR_BUILD = "${BUILD_CFLAGS}" + +export CC = "${CCACHE} ${HOST_PREFIX}gcc ${HOST_CC_ARCH}" + +do_configure () { + (cd ${S}; gnu-configize) || die "Failed to run gnu-configize" + oe_runconf +} + +do_stage () { + oe_libinstall -so -a -C opcodes libopcodes ${STAGING_LIBDIR}/ + oe_libinstall -a -C libiberty libiberty ${STAGING_LIBDIR}/ + oe_libinstall -so -a -C bfd libbfd ${STAGING_LIBDIR}/ + install -m 0644 ${S}/include/dis-asm.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/symcat.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/libiberty.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/ansidecl.h ${STAGING_INCDIR}/ + install -m 0644 ${S}/include/bfdlink.h ${STAGING_INCDIR}/ + install -m 0644 bfd/bfd.h ${STAGING_INCDIR}/ +} + +do_install () { + autotools_do_install + + # We don't really need these, so we'll remove them... + rm -rf ${D}${libdir}/ldscripts + + # Fix the /usr/${TARGET_SYS}/bin/* links + for l in ${D}${prefix}/${TARGET_SYS}/bin/*; do + rm -f $l + ln -sf `echo ${prefix}/${TARGET_SYS}/bin \ + | tr -s / \ + | sed -e 's,^/,,' -e 's,[^/]*,..,g'`${bindir}/${TARGET_PREFIX}`basename $l` $l + done + + # Install the libiberty header + install -d ${D}${includedir} + install -m 644 ${S}/include/ansidecl.h ${D}${includedir} + install -m 644 ${S}/include/libiberty.h ${D}${includedir} + + cd ${D}${bindir} + + # Symlinks for ease of running these on the native target + for p in ${TARGET_SYS}-* ; do + ln -sf $p `echo $p | sed -e s,${TARGET_SYS}-,,` + done +} diff --git a/meta/packages/binutils/binutils_2.16.bb b/meta/packages/binutils/binutils_2.16.bb new file mode 100644 index 000000000..5b936dcc6 --- /dev/null +++ b/meta/packages/binutils/binutils_2.16.bb @@ -0,0 +1,26 @@ +DESCRIPTION = "A GNU collection of binary utilities" +HOMEPAGE = "http://www.gnu.org/software/binutils/" +SECTION = "devel" +LICENSE = "GPL" +MAINTAINER = "Gerald Britton " +PR = "r7" + +SRC_URI = \ + "http://ftp.gnu.org/gnu/binutils/binutils-${PV}.tar.bz2 \ + file://ld_makefile.patch;patch=1 \ + file://better_file_error.patch;patch=1 \ + file://signed_char_fix.patch;patch=1 \ + file://binutils-2.16-objcopy-rename-errorcode.patch;patch=1 \ + file://binutils-100_cflags_for_build.patch;patch=1" + +# uclibc patches +SRC_URI += "file://binutils-2.16-linux-uclibc.patch;patch=1" + +# thumb support patches +SRC_URI += "file://binutils-2.16-thumb-trampoline.patch;patch=1" +SRC_URI += "file://binutils-2.16-thumb-glue.patch;patch=1" + +S = "${WORKDIR}/binutils-${PV}" +B = "${S}/build.${HOST_SYS}.${TARGET_SYS}" + +include binutils.inc diff --git a/meta/packages/binutils/files/better_file_error.patch b/meta/packages/binutils/files/better_file_error.patch new file mode 100644 index 000000000..38ef52966 --- /dev/null +++ b/meta/packages/binutils/files/better_file_error.patch @@ -0,0 +1,17 @@ +diff -urN binutils-2.11.92.0.5/bfd/opncls.c binutils-2.11.92.0.5.new/bfd/opncls.c +--- binutils-2.11.92.0.5/bfd/opncls.c Mon Oct 1 18:25:21 2001 ++++ binutils-2.11.92.0.5.new/bfd/opncls.c Sat Oct 13 11:26:59 2001 +@@ -127,6 +127,13 @@ + { + bfd *nbfd; + const bfd_target *target_vec; ++ struct stat s; ++ ++ if (stat (filename, &s) == 0) ++ if (S_ISDIR(s.st_mode)) { ++ bfd_set_error (bfd_error_file_not_recognized); ++ return NULL; ++ } + + nbfd = _bfd_new_bfd (); + if (nbfd == NULL) diff --git a/meta/packages/binutils/files/ld_makefile.patch b/meta/packages/binutils/files/ld_makefile.patch new file mode 100644 index 000000000..c1d2ac1ec --- /dev/null +++ b/meta/packages/binutils/files/ld_makefile.patch @@ -0,0 +1,22 @@ +--- binutils-2.11.90.0.19.orig/ld/Makefile.am ++++ binutils-2.11.90.0.19/ld/Makefile.am +@@ -19,7 +19,7 @@ + # We put the scripts in the directory $(scriptdir)/ldscripts. + # We can't put the scripts in $(datadir) because the SEARCH_DIR + # directives need to be different for native and cross linkers. +-scriptdir = $(tooldir)/lib ++scriptdir = $(libdir) + + EMUL = @EMUL@ + EMULATION_OFILES = @EMULATION_OFILES@ +--- binutils-2.11.90.0.19.orig/ld/Makefile.in ++++ binutils-2.11.90.0.19/ld/Makefile.in +@@ -123,7 +123,7 @@ + # We put the scripts in the directory $(scriptdir)/ldscripts. + # We can't put the scripts in $(datadir) because the SEARCH_DIR + # directives need to be different for native and cross linkers. +-scriptdir = $(tooldir)/lib ++scriptdir = $(libdir) + + EMUL = @EMUL@ + EMULATION_OFILES = @EMULATION_OFILES@ diff --git a/meta/packages/binutils/files/objdump_fix.patch b/meta/packages/binutils/files/objdump_fix.patch new file mode 100644 index 000000000..90ad732c0 --- /dev/null +++ b/meta/packages/binutils/files/objdump_fix.patch @@ -0,0 +1,134 @@ +From binutils-return-38148-listarch-binutils=sources dot redhat dot com at sources dot redhat dot com Tue Feb 22 19:24:15 2005 +Return-Path: +Delivered-To: listarch-binutils at sources dot redhat dot com +Received: (qmail 4446 invoked by alias); 22 Feb 2005 19:24:15 -0000 +Mailing-List: contact binutils-help at sources dot redhat dot com; run by ezmlm +Precedence: bulk +List-Subscribe: +List-Archive: +List-Post: +List-Help: , +Sender: binutils-owner at sources dot redhat dot com +Delivered-To: mailing list binutils at sources dot redhat dot com +Received: (qmail 4401 invoked from network); 22 Feb 2005 19:24:08 -0000 +Received: from unknown (HELO bgo1smout1.broadpark.no) (217.13.4.94) + by sourceware dot org with SMTP; 22 Feb 2005 19:24:08 -0000 +Received: from bgo1sminn1.broadpark.no ([217.13.4.93]) + by bgo1smout1 dot broadpark dot no + (Sun Java System Messaging Server 6 dot 1 HotFix 0 dot 05 (built Oct 21 2004)) + with ESMTP id <0ICB007QZUZCC0C0 at bgo1smout1 dot broadpark dot no> for + binutils at sources dot redhat dot com; Tue, 22 Feb 2005 20:18:48 +0100 (CET) +Received: from [127.0.0.1] ([80.202.165.9]) by bgo1sminn1.broadpark.no + (Sun Java System Messaging Server 6 dot 1 HotFix 0 dot 05 (built Oct 21 2004)) + with ESMTP id <0ICB006NCVBVHE21 at bgo1sminn1 dot broadpark dot no> for + binutils at sources dot redhat dot com; Tue, 22 Feb 2005 20:26:20 +0100 (CET) +Date: Tue, 22 Feb 2005 20:24:08 +0100 +From: =?ISO-8859-1?Q?Stig_Petter_Olsr=F8d?= +Subject: [PATCH] objdump relocation fixes for ARM disassembly +To: binutils at sources dot redhat dot com +Message-id: <421B86D8.8080604@users.sourceforge.net> +MIME-version: 1.0 +Content-type: text/plain; charset=ISO-8859-1; format=flowed +Content-transfer-encoding: 7BIT +User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) + +Hello, + +objdump disassembly did not relocate correctly for the ARM processor. It seems +that the test for triggering the INSN_HAS_RELOC flag was void (one test killed the other, +since octets would always be zero) and all relocations would thus fail. I changed the test +so the flag is set when we are about to disassemble an insn that the current relocation +entry points to. I also changed objdump_print_addr to use the current relocation entry if +the insn has such an entry. This causes the symbol printed to be correct for both external +symbols (from the undefined section) and local symbols. + +This has only been tested for the ARM processor, but I don't think it should break other +DISASSEMBLER_NEEDS_RELOCS processors either. + + +binutils/ + +2005-02-22 Stig Petter Olsroed + + * objdump.c (disassemble_bytes): Fixed relocation check for + DISASSEMBLER_NEEDS_RELOCS platforms to properly trigger the + INSN_HAS_RELOC flag. Set the current relocation entry in + objdump_disasm_info to allow printing the proper symbol. + (objdump_print_addr): Use the relocation entry in + objdump_disasm_info to lookup the correct symbol for + DISASSEMBLER_NEEDS_RELOCS platforms. + +--- 1/binutils/objdump.c 2005-02-22 01:50:06.000000000 +0100 ++++ 2/binutils/objdump.c 2005-02-22 14:27:33.066960900 +0100 +@@ -128,6 +128,7 @@ + arelent ** dynrelbuf; + long dynrelcount; + disassembler_ftype disassemble_fn; ++ arelent * reloc; + }; + + /* Architecture to disassemble for, or default if NULL. */ +@@ -852,6 +853,8 @@ + { + struct objdump_disasm_info *aux; + asymbol *sym; ++ arelent *q; ++ int skip_find = 0; + + if (sorted_symcount < 1) + { +@@ -861,6 +864,22 @@ + } + + aux = (struct objdump_disasm_info *) info->application_data; ++ ++ q = aux->reloc; ++ if (q != NULL) ++ { ++ if (q->sym_ptr_ptr != NULL && *q->sym_ptr_ptr != NULL) ++ { ++ /* Adjust the vma to the reloc */ ++ vma += bfd_asymbol_value (*q->sym_ptr_ptr); ++ if (bfd_is_und_section (bfd_get_section (*q->sym_ptr_ptr))) ++ { ++ skip_find = 1; ++ sym = *q->sym_ptr_ptr; ++ } ++ } ++ } ++ if (!skip_find) + sym = find_symbol_for_address (vma, info, NULL); + objdump_print_addr_with_sym (aux->abfd, aux->sec, sym, vma, info, + skip_zeroes); +@@ -1350,16 +1369,22 @@ + info->bytes_per_chunk = 0; + + #ifdef DISASSEMBLER_NEEDS_RELOCS +- /* FIXME: This is wrong. It tests the number of octets +- in the last instruction, not the current one. */ +- if (*relppp < relppend +- && (**relppp)->address >= rel_offset + addr_offset +- && ((**relppp)->address +- < rel_offset + addr_offset + octets / opb)) ++ /* Check if the current relocation entry applies to the ++ instruction we are about to disassemble. ++ This works for ARM at least. ++ */ ++ if ((*relppp) < relppend ++ && ((**relppp)->address == rel_offset + addr_offset)) ++ { + info->flags = INSN_HAS_RELOC; ++ aux->reloc = **relppp; ++ } + else + #endif ++ { + info->flags = 0; ++ aux->reloc = NULL; ++ } + + octets = (*disassemble_fn) (section->vma + addr_offset, info); + info->fprintf_func = (fprintf_ftype) fprintf; + + + diff --git a/meta/packages/binutils/files/plt32trunc.patch b/meta/packages/binutils/files/plt32trunc.patch new file mode 100644 index 000000000..4990f5dbb --- /dev/null +++ b/meta/packages/binutils/files/plt32trunc.patch @@ -0,0 +1,24 @@ +--- binutils/bfd/elf32-arm.h.orig 2004-04-22 22:11:15.000000000 -0400 ++++ binutils/bfd/elf32-arm.h 2004-04-22 22:28:37.000000000 -0400 +@@ -2229,6 +2229,8 @@ elf32_arm_relocate_section (output_bfd, + case R_ARM_PC24: + case R_ARM_ABS32: + case R_ARM_THM_PC22: ++ case R_ARM_PLT32: ++ + if (info->shared + && ( + (!info->symbolic && h->dynindx != -1) +@@ -2262,11 +2264,6 @@ elf32_arm_relocate_section (output_bfd, + relocation = 0; + break; + +- case R_ARM_PLT32: +- if (h->plt.offset != (bfd_vma)-1) +- relocation = 0; +- break; +- + default: + if (unresolved_reloc) + _bfd_error_handler + diff --git a/meta/packages/binutils/files/signed_char_fix.patch b/meta/packages/binutils/files/signed_char_fix.patch new file mode 100644 index 000000000..b3709dabe --- /dev/null +++ b/meta/packages/binutils/files/signed_char_fix.patch @@ -0,0 +1,12 @@ +diff -urN binutils-2.11.92.0.12.3/opcodes/i386-dis.c binutils-2.11.92.0.12.3.new/opcodes/i386-dis.c +--- binutils-2.11.92.0.12.3/opcodes/i386-dis.c Fri Nov 16 17:05:55 2001 ++++ binutils-2.11.92.0.12.3.new/opcodes/i386-dis.c Mon Dec 31 15:55:04 2001 +@@ -1830,7 +1830,7 @@ + * The function returns the length of this instruction in bytes. + */ + +-static char intel_syntax; ++static signed char intel_syntax; + static char open_char; + static char close_char; + static char separator_char; diff --git a/meta/packages/bison/bison-2.0/m4.patch b/meta/packages/bison/bison-2.0/m4.patch new file mode 100644 index 000000000..b62fe89d0 --- /dev/null +++ b/meta/packages/bison/bison-2.0/m4.patch @@ -0,0 +1,589 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- /dev/null ++++ bison-1.875/m4/inttypes-pri.m4 +@@ -0,0 +1,32 @@ ++# inttypes-pri.m4 serial 1 (gettext-0.11.4) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Bruno Haible. ++ ++# Define PRI_MACROS_BROKEN if exists and defines the PRI* ++# macros to non-string values. This is the case on AIX 4.3.3. ++ ++AC_DEFUN([gt_INTTYPES_PRI], ++[ ++ AC_REQUIRE([gt_HEADER_INTTYPES_H]) ++ if test $gt_cv_header_inttypes_h = yes; then ++ AC_CACHE_CHECK([whether the inttypes.h PRIxNN macros are broken], ++ gt_cv_inttypes_pri_broken, ++ [ ++ AC_TRY_COMPILE([#include ++#ifdef PRId32 ++char *p = PRId32; ++#endif ++], [], gt_cv_inttypes_pri_broken=no, gt_cv_inttypes_pri_broken=yes) ++ ]) ++ fi ++ if test "$gt_cv_inttypes_pri_broken" = yes; then ++ AC_DEFINE_UNQUOTED(PRI_MACROS_BROKEN, 1, ++ [Define if exists and defines unusable PRI* macros.]) ++ fi ++]) +--- /dev/null ++++ bison-1.875/m4/lcmessage.m4 +@@ -0,0 +1,32 @@ ++# lcmessage.m4 serial 3 (gettext-0.11.3) ++dnl Copyright (C) 1995-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++dnl ++dnl This file can can be used in projects which are not available under ++dnl the GNU General Public License or the GNU Library General Public ++dnl License but which still want to provide support for the GNU gettext ++dnl functionality. ++dnl Please note that the actual code of the GNU gettext library is covered ++dnl by the GNU Library General Public License, and the rest of the GNU ++dnl gettext package package is covered by the GNU General Public License. ++dnl They are *not* in the public domain. ++ ++dnl Authors: ++dnl Ulrich Drepper , 1995. ++ ++# Check whether LC_MESSAGES is available in . ++ ++AC_DEFUN([AM_LC_MESSAGES], ++[ ++ AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES, ++ [AC_TRY_LINK([#include ], [return LC_MESSAGES], ++ am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)]) ++ if test $am_cv_val_LC_MESSAGES = yes; then ++ AC_DEFINE(HAVE_LC_MESSAGES, 1, ++ [Define if your file defines LC_MESSAGES.]) ++ fi ++]) +--- /dev/null ++++ bison-1.875/m4/uintmax_t.m4 +@@ -0,0 +1,29 @@ ++# uintmax_t.m4 serial 6 (gettext-0.11) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++AC_PREREQ(2.13) ++ ++# Define uintmax_t to `unsigned long' or `unsigned long long' ++# if does not exist. ++ ++AC_DEFUN([jm_AC_TYPE_UINTMAX_T], ++[ ++ AC_REQUIRE([jm_AC_HEADER_INTTYPES_H]) ++ AC_REQUIRE([jm_AC_HEADER_STDINT_H]) ++ if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then ++ AC_REQUIRE([jm_AC_TYPE_UNSIGNED_LONG_LONG]) ++ test $ac_cv_type_unsigned_long_long = yes \ ++ && ac_type='unsigned long long' \ ++ || ac_type='unsigned long' ++ AC_DEFINE_UNQUOTED(uintmax_t, $ac_type, ++ [Define to unsigned long or unsigned long long ++ if and don't define.]) ++ fi ++]) +--- /dev/null ++++ bison-1.875/m4/glibc21.m4 +@@ -0,0 +1,32 @@ ++# glibc21.m4 serial 2 (fileutils-4.1.3, gettext-0.10.40) ++dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++# Test for the GNU C Library, version 2.1 or newer. ++# From Bruno Haible. ++ ++AC_DEFUN([jm_GLIBC21], ++ [ ++ AC_CACHE_CHECK(whether we are using the GNU C Library 2.1 or newer, ++ ac_cv_gnu_library_2_1, ++ [AC_EGREP_CPP([Lucky GNU user], ++ [ ++#include ++#ifdef __GNU_LIBRARY__ ++ #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2) ++ Lucky GNU user ++ #endif ++#endif ++ ], ++ ac_cv_gnu_library_2_1=yes, ++ ac_cv_gnu_library_2_1=no) ++ ] ++ ) ++ AC_SUBST(GLIBC21) ++ GLIBC21="$ac_cv_gnu_library_2_1" ++ ] ++) +--- /dev/null ++++ bison-1.875/m4/stdint_h.m4 +@@ -0,0 +1,28 @@ ++# stdint_h.m4 serial 2 (gettext-0.11.4) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++# Define HAVE_STDINT_H_WITH_UINTMAX if exists, ++# doesn't clash with , and declares uintmax_t. ++ ++AC_DEFUN([jm_AC_HEADER_STDINT_H], ++[ ++ AC_CACHE_CHECK([for stdint.h], jm_ac_cv_header_stdint_h, ++ [AC_TRY_COMPILE( ++ [#include ++#include ], ++ [uintmax_t i = (uintmax_t) -1;], ++ jm_ac_cv_header_stdint_h=yes, ++ jm_ac_cv_header_stdint_h=no)]) ++ if test $jm_ac_cv_header_stdint_h = yes; then ++ AC_DEFINE_UNQUOTED(HAVE_STDINT_H_WITH_UINTMAX, 1, ++[Define if exists, doesn't clash with , ++ and declares uintmax_t. ]) ++ fi ++]) +--- /dev/null ++++ bison-1.875/m4/inttypes_h.m4 +@@ -0,0 +1,28 @@ ++# inttypes_h.m4 serial 4 (gettext-0.11.4) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++# Define HAVE_INTTYPES_H_WITH_UINTMAX if exists, ++# doesn't clash with , and declares uintmax_t. ++ ++AC_DEFUN([jm_AC_HEADER_INTTYPES_H], ++[ ++ AC_CACHE_CHECK([for inttypes.h], jm_ac_cv_header_inttypes_h, ++ [AC_TRY_COMPILE( ++ [#include ++#include ], ++ [uintmax_t i = (uintmax_t) -1;], ++ jm_ac_cv_header_inttypes_h=yes, ++ jm_ac_cv_header_inttypes_h=no)]) ++ if test $jm_ac_cv_header_inttypes_h = yes; then ++ AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H_WITH_UINTMAX, 1, ++[Define if exists, doesn't clash with , ++ and declares uintmax_t. ]) ++ fi ++]) +--- /dev/null ++++ bison-1.875/m4/ulonglong.m4 +@@ -0,0 +1,23 @@ ++# ulonglong.m4 serial 2 (fileutils-4.0.32, gettext-0.10.40) ++dnl Copyright (C) 1999-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++AC_DEFUN([jm_AC_TYPE_UNSIGNED_LONG_LONG], ++[ ++ AC_CACHE_CHECK([for unsigned long long], ac_cv_type_unsigned_long_long, ++ [AC_TRY_LINK([unsigned long long ull = 1; int i = 63;], ++ [unsigned long long ullmax = (unsigned long long) -1; ++ return ull << i | ull >> i | ullmax / ull | ullmax % ull;], ++ ac_cv_type_unsigned_long_long=yes, ++ ac_cv_type_unsigned_long_long=no)]) ++ if test $ac_cv_type_unsigned_long_long = yes; then ++ AC_DEFINE(HAVE_UNSIGNED_LONG_LONG, 1, ++ [Define if you have the unsigned long long type.]) ++ fi ++]) +--- /dev/null ++++ bison-1.875/m4/codeset.m4 +@@ -0,0 +1,23 @@ ++# codeset.m4 serial AM1 (gettext-0.10.40) ++dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Bruno Haible. ++ ++AC_DEFUN([AM_LANGINFO_CODESET], ++[ ++ AC_CACHE_CHECK([for nl_langinfo and CODESET], am_cv_langinfo_codeset, ++ [AC_TRY_LINK([#include ], ++ [char* cs = nl_langinfo(CODESET);], ++ am_cv_langinfo_codeset=yes, ++ am_cv_langinfo_codeset=no) ++ ]) ++ if test $am_cv_langinfo_codeset = yes; then ++ AC_DEFINE(HAVE_LANGINFO_CODESET, 1, ++ [Define if you have and nl_langinfo(CODESET).]) ++ fi ++]) +--- /dev/null ++++ bison-1.875/m4/intdiv0.m4 +@@ -0,0 +1,72 @@ ++# intdiv0.m4 serial 1 (gettext-0.11.3) ++dnl Copyright (C) 2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Bruno Haible. ++ ++AC_DEFUN([gt_INTDIV0], ++[ ++ AC_REQUIRE([AC_PROG_CC])dnl ++ AC_REQUIRE([AC_CANONICAL_HOST])dnl ++ ++ AC_CACHE_CHECK([whether integer division by zero raises SIGFPE], ++ gt_cv_int_divbyzero_sigfpe, ++ [ ++ AC_TRY_RUN([ ++#include ++#include ++ ++static void ++#ifdef __cplusplus ++sigfpe_handler (int sig) ++#else ++sigfpe_handler (sig) int sig; ++#endif ++{ ++ /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */ ++ exit (sig != SIGFPE); ++} ++ ++int x = 1; ++int y = 0; ++int z; ++int nan; ++ ++int main () ++{ ++ signal (SIGFPE, sigfpe_handler); ++/* IRIX and AIX (when "xlc -qcheck" is used) yield signal SIGTRAP. */ ++#if (defined (__sgi) || defined (_AIX)) && defined (SIGTRAP) ++ signal (SIGTRAP, sigfpe_handler); ++#endif ++/* Linux/SPARC yields signal SIGILL. */ ++#if defined (__sparc__) && defined (__linux__) ++ signal (SIGILL, sigfpe_handler); ++#endif ++ ++ z = x / y; ++ nan = y / y; ++ exit (1); ++} ++], gt_cv_int_divbyzero_sigfpe=yes, gt_cv_int_divbyzero_sigfpe=no, ++ [ ++ # Guess based on the CPU. ++ case "$host_cpu" in ++ alpha* | i[34567]86 | m68k | s390*) ++ gt_cv_int_divbyzero_sigfpe="guessing yes";; ++ *) ++ gt_cv_int_divbyzero_sigfpe="guessing no";; ++ esac ++ ]) ++ ]) ++ case "$gt_cv_int_divbyzero_sigfpe" in ++ *yes) value=1;; ++ *) value=0;; ++ esac ++ AC_DEFINE_UNQUOTED(INTDIV0_RAISES_SIGFPE, $value, ++ [Define if integer division by zero raises signal SIGFPE.]) ++]) +--- /dev/null ++++ bison-1.875/m4/glib.m4 +@@ -0,0 +1,196 @@ ++# Configure paths for GLIB ++# Owen Taylor 97-11-3 ++ ++dnl AM_PATH_GLIB([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]]) ++dnl Test for GLIB, and define GLIB_CFLAGS and GLIB_LIBS, if "gmodule" or ++dnl gthread is specified in MODULES, pass to glib-config ++dnl ++AC_DEFUN(AM_PATH_GLIB, ++[dnl ++dnl Get the cflags and libraries from the glib-config script ++dnl ++AC_ARG_WITH(glib-prefix,[ --with-glib-prefix=PFX Prefix where GLIB is installed (optional)], ++ glib_config_prefix="$withval", glib_config_prefix="") ++AC_ARG_WITH(glib-exec-prefix,[ --with-glib-exec-prefix=PFX Exec prefix where GLIB is installed (optional)], ++ glib_config_exec_prefix="$withval", glib_config_exec_prefix="") ++AC_ARG_ENABLE(glibtest, [ --disable-glibtest Do not try to compile and run a test GLIB program], ++ , enable_glibtest=yes) ++ ++ if test x$glib_config_exec_prefix != x ; then ++ glib_config_args="$glib_config_args --exec-prefix=$glib_config_exec_prefix" ++ if test x${GLIB_CONFIG+set} != xset ; then ++ GLIB_CONFIG=$glib_config_exec_prefix/bin/glib-config ++ fi ++ fi ++ if test x$glib_config_prefix != x ; then ++ glib_config_args="$glib_config_args --prefix=$glib_config_prefix" ++ if test x${GLIB_CONFIG+set} != xset ; then ++ GLIB_CONFIG=$glib_config_prefix/bin/glib-config ++ fi ++ fi ++ ++ for module in . $4 ++ do ++ case "$module" in ++ gmodule) ++ glib_config_args="$glib_config_args gmodule" ++ ;; ++ gthread) ++ glib_config_args="$glib_config_args gthread" ++ ;; ++ esac ++ done ++ ++ AC_PATH_PROG(GLIB_CONFIG, glib-config, no) ++ min_glib_version=ifelse([$1], ,0.99.7,$1) ++ AC_MSG_CHECKING(for GLIB - version >= $min_glib_version) ++ no_glib="" ++ if test "$GLIB_CONFIG" = "no" ; then ++ no_glib=yes ++ else ++ GLIB_CFLAGS=`$GLIB_CONFIG $glib_config_args --cflags` ++ GLIB_LIBS=`$GLIB_CONFIG $glib_config_args --libs` ++ glib_config_major_version=`$GLIB_CONFIG $glib_config_args --version | \ ++ sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` ++ glib_config_minor_version=`$GLIB_CONFIG $glib_config_args --version | \ ++ sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` ++ glib_config_micro_version=`$GLIB_CONFIG $glib_config_args --version | \ ++ sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` ++ if test "x$enable_glibtest" = "xyes" ; then ++ ac_save_CFLAGS="$CFLAGS" ++ ac_save_LIBS="$LIBS" ++ CFLAGS="$CFLAGS $GLIB_CFLAGS" ++ LIBS="$GLIB_LIBS $LIBS" ++dnl ++dnl Now check if the installed GLIB is sufficiently new. (Also sanity ++dnl checks the results of glib-config to some extent ++dnl ++ rm -f conf.glibtest ++ AC_TRY_RUN([ ++#include ++#include ++#include ++ ++int ++main () ++{ ++ int major, minor, micro; ++ char *tmp_version; ++ ++ system ("touch conf.glibtest"); ++ ++ /* HP/UX 9 (%@#!) writes to sscanf strings */ ++ tmp_version = g_strdup("$min_glib_version"); ++ if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { ++ printf("%s, bad version string\n", "$min_glib_version"); ++ exit(1); ++ } ++ ++ if ((glib_major_version != $glib_config_major_version) || ++ (glib_minor_version != $glib_config_minor_version) || ++ (glib_micro_version != $glib_config_micro_version)) ++ { ++ printf("\n*** 'glib-config --version' returned %d.%d.%d, but GLIB (%d.%d.%d)\n", ++ $glib_config_major_version, $glib_config_minor_version, $glib_config_micro_version, ++ glib_major_version, glib_minor_version, glib_micro_version); ++ printf ("*** was found! If glib-config was correct, then it is best\n"); ++ printf ("*** to remove the old version of GLIB. You may also be able to fix the error\n"); ++ printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n"); ++ printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n"); ++ printf("*** required on your system.\n"); ++ printf("*** If glib-config was wrong, set the environment variable GLIB_CONFIG\n"); ++ printf("*** to point to the correct copy of glib-config, and remove the file config.cache\n"); ++ printf("*** before re-running configure\n"); ++ } ++ else if ((glib_major_version != GLIB_MAJOR_VERSION) || ++ (glib_minor_version != GLIB_MINOR_VERSION) || ++ (glib_micro_version != GLIB_MICRO_VERSION)) ++ { ++ printf("*** GLIB header files (version %d.%d.%d) do not match\n", ++ GLIB_MAJOR_VERSION, GLIB_MINOR_VERSION, GLIB_MICRO_VERSION); ++ printf("*** library (version %d.%d.%d)\n", ++ glib_major_version, glib_minor_version, glib_micro_version); ++ } ++ else ++ { ++ if ((glib_major_version > major) || ++ ((glib_major_version == major) && (glib_minor_version > minor)) || ++ ((glib_major_version == major) && (glib_minor_version == minor) && (glib_micro_version >= micro))) ++ { ++ return 0; ++ } ++ else ++ { ++ printf("\n*** An old version of GLIB (%d.%d.%d) was found.\n", ++ glib_major_version, glib_minor_version, glib_micro_version); ++ printf("*** You need a version of GLIB newer than %d.%d.%d. The latest version of\n", ++ major, minor, micro); ++ printf("*** GLIB is always available from ftp://ftp.gtk.org.\n"); ++ printf("***\n"); ++ printf("*** If you have already installed a sufficiently new version, this error\n"); ++ printf("*** probably means that the wrong copy of the glib-config shell script is\n"); ++ printf("*** being found. The easiest way to fix this is to remove the old version\n"); ++ printf("*** of GLIB, but you can also set the GLIB_CONFIG environment to point to the\n"); ++ printf("*** correct copy of glib-config. (In this case, you will have to\n"); ++ printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); ++ printf("*** so that the correct libraries are found at run-time))\n"); ++ } ++ } ++ return 1; ++} ++],, no_glib=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) ++ CFLAGS="$ac_save_CFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ fi ++ if test "x$no_glib" = x ; then ++ AC_MSG_RESULT(yes) ++ ifelse([$2], , :, [$2]) ++ else ++ AC_MSG_RESULT(no) ++ if test "$GLIB_CONFIG" = "no" ; then ++ echo "*** The glib-config script installed by GLIB could not be found" ++ echo "*** If GLIB was installed in PREFIX, make sure PREFIX/bin is in" ++ echo "*** your path, or set the GLIB_CONFIG environment variable to the" ++ echo "*** full path to glib-config." ++ else ++ if test -f conf.glibtest ; then ++ : ++ else ++ echo "*** Could not run GLIB test program, checking why..." ++ CFLAGS="$CFLAGS $GLIB_CFLAGS" ++ LIBS="$LIBS $GLIB_LIBS" ++ AC_TRY_LINK([ ++#include ++#include ++], [ return ((glib_major_version) || (glib_minor_version) || (glib_micro_version)); ], ++ [ echo "*** The test program compiled, but did not run. This usually means" ++ echo "*** that the run-time linker is not finding GLIB or finding the wrong" ++ echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your" ++ echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" ++ echo "*** to the installed location Also, make sure you have run ldconfig if that" ++ echo "*** is required on your system" ++ echo "***" ++ echo "*** If you have an old version installed, it is best to remove it, although" ++ echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ++ echo "***" ++ echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that" ++ echo "*** came with the system with the command" ++ echo "***" ++ echo "*** rpm --erase --nodeps gtk gtk-devel" ], ++ [ echo "*** The test program failed to compile or link. See the file config.log for the" ++ echo "*** exact error that occured. This usually means GLIB was incorrectly installed" ++ echo "*** or that you have moved GLIB since it was installed. In the latter case, you" ++ echo "*** may want to edit the glib-config script: $GLIB_CONFIG" ]) ++ CFLAGS="$ac_save_CFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ fi ++ GLIB_CFLAGS="" ++ GLIB_LIBS="" ++ ifelse([$3], , :, [$3]) ++ fi ++ AC_SUBST(GLIB_CFLAGS) ++ AC_SUBST(GLIB_LIBS) ++ rm -f conf.glibtest ++]) +--- /dev/null ++++ bison-1.875/m4/inttypes.m4 +@@ -0,0 +1,27 @@ ++# inttypes.m4 serial 1 (gettext-0.11.4) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++# Define HAVE_INTTYPES_H if exists and doesn't clash with ++# . ++ ++AC_DEFUN([gt_HEADER_INTTYPES_H], ++[ ++ AC_CACHE_CHECK([for inttypes.h], gt_cv_header_inttypes_h, ++ [ ++ AC_TRY_COMPILE( ++ [#include ++#include ], ++ [], gt_cv_header_inttypes_h=yes, gt_cv_header_inttypes_h=no) ++ ]) ++ if test $gt_cv_header_inttypes_h = yes; then ++ AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H, 1, ++ [Define if exists and doesn't clash with .]) ++ fi ++]) +--- /dev/null ++++ bison-1.875/m4/isc-posix.m4 +@@ -0,0 +1,26 @@ ++# isc-posix.m4 serial 2 (gettext-0.11.2) ++dnl Copyright (C) 1995-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++# This file is not needed with autoconf-2.53 and newer. Remove it in 2005. ++ ++# This test replaces the one in autoconf. ++# Currently this macro should have the same name as the autoconf macro ++# because gettext's gettext.m4 (distributed in the automake package) ++# still uses it. Otherwise, the use in gettext.m4 makes autoheader ++# give these diagnostics: ++# configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX ++# configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX ++ ++undefine([AC_ISC_POSIX]) ++ ++AC_DEFUN([AC_ISC_POSIX], ++ [ ++ dnl This test replaces the obsolescent AC_ISC_POSIX kludge. ++ AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"]) ++ ] ++) diff --git a/meta/packages/bison/bison-native_2.0.bb b/meta/packages/bison/bison-native_2.0.bb new file mode 100644 index 000000000..57065cd50 --- /dev/null +++ b/meta/packages/bison/bison-native_2.0.bb @@ -0,0 +1,21 @@ +include bison_${PV}.bb +SECTION = "devel" +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/bison-${PV}" +S = "${WORKDIR}/bison-${PV}" +PR = "r2" + +inherit native autotools + +do_stage() { + rm -f ${STAGING_BINDIR}/yacc + rm -f ${STAGING_BINDIR}/bison + install -m 0755 src/bison ${STAGING_BINDIR}/ + cat >${STAGING_BINDIR}/yacc < ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include "busybox.h" ++ ++extern int getkey_main(int argc, char **argv) ++{ ++ int status = EXIT_FAILURE; ++ ++ if ( argc < 2 ) ++ { ++ bb_show_usage(); ++ } ++ ++ /* ++ * If no terminal is attached it is quite useless ++ * to treat it like one. ++ */ ++ if( !isatty(STDIN_FILENO) ) ++ { ++ goto error_hard; ++ } ++ ++ //bb_printf( "DEBUG: time = '%s'\n", argv[1] ); ++ //bb_printf( "DEBUG: mesg = '%s'\n", argv[2] ); ++ ++ struct termios orig; ++ struct termios attr; ++ ++ if ( tcgetattr(STDIN_FILENO, &orig) == -1 ) ++ { ++ goto error_hard; ++ } ++ ++ attr = orig; ++ attr.c_cc[VMIN] = 0; ++ attr.c_cc[VTIME] = 0; ++ attr.c_iflag |= INLCR; ++ attr.c_oflag |= OPOST|ONLCR; ++ attr.c_cflag &= ~PARENB; ++ attr.c_lflag &= ~(ICANON/*|ECHO*/); ++ if ( tcsetattr(STDIN_FILENO,TCSANOW,&attr) == -1 ) ++ { ++ goto error_hard; ++ } ++ ++ fd_set rfds; ++ struct timeval tv; ++ int retval; ++ ++ FD_ZERO(&rfds); ++ FD_SET(0, &rfds); ++ ++ tv.tv_sec = atoi( argv[1] ); ++ tv.tv_usec = 0; ++ ++ if ( argc == 3 ) ++ { ++ bb_printf( argv[2], tv.tv_sec ); ++ bb_printf( "\n" ); ++ fflush(stdout); ++ } ++ retval = select(1, &rfds, NULL, NULL, &tv); ++ if (retval > 0) ++ { ++ status = EXIT_SUCCESS; ++ } ++ ++ if (tcsetattr(STDIN_FILENO,TCSANOW,&orig) == -1 ) ++ { ++ goto error_hard; ++ } ++ ++ return status; ++ ++error_hard : ++ return EXIT_FAILURE; ++}; ++ +--- busybox-1.00/console-tools/Makefile.in~add-getkey-applet.patch ++++ busybox-1.00/console-tools/Makefile.in +@@ -28,6 +28,7 @@ + CONSOLETOOLS_DIR-$(CONFIG_CLEAR) += clear.o + CONSOLETOOLS_DIR-$(CONFIG_DEALLOCVT) += deallocvt.o + CONSOLETOOLS_DIR-$(CONFIG_DUMPKMAP) += dumpkmap.o ++CONSOLETOOLS_DIR-$(CONFIG_GETKEY) += getkey.o + CONSOLETOOLS_DIR-$(CONFIG_LOADFONT) += loadfont.o + CONSOLETOOLS_DIR-$(CONFIG_LOADKMAP) += loadkmap.o + CONSOLETOOLS_DIR-$(CONFIG_OPENVT) += openvt.o +--- busybox-1.00/console-tools/Config.in~add-getkey-applet.patch ++++ busybox-1.00/console-tools/Config.in +@@ -31,6 +31,14 @@ + This program dumps the kernel's keyboard translation table to + stdout, in binary format. You can then use loadkmap to load it. + ++config CONFIG_GETKEY ++ bool "getkey" ++ default n ++ help ++ This program displays a configurable message and waits ++ a dedicated number of seconds for a keypress. It sets ++ the exit code accordingly, i.e. SUCCESS if there was a keypress. ++ + config CONFIG_LOADFONT + bool "loadfont" + default n +--- busybox-1.00/include/applets.h~add-getkey-applet.patch ++++ busybox-1.00/include/applets.h +@@ -223,6 +223,9 @@ + #ifdef CONFIG_FTPPUT + APPLET(ftpput, ftpgetput_main, _BB_DIR_USR_BIN, _BB_SUID_NEVER) + #endif ++#ifdef CONFIG_GETKEY ++ APPLET(getkey, getkey_main, _BB_DIR_SBIN, _BB_SUID_NEVER) ++#endif + #ifdef CONFIG_GETOPT + APPLET(getopt, getopt_main, _BB_DIR_BIN, _BB_SUID_NEVER) + #endif +--- busybox-1.00/include/usage.h~add-getkey-applet.patch ++++ busybox-1.00/include/usage.h +@@ -734,6 +734,13 @@ + "\t-p, --password Password to be used\n" \ + "\t-P, --port Port number to be used" + ++#define getkey_trivial_usage \ ++ "time [message]" ++#define getkey_full_usage \ ++ "Display a message and wait for a keypress." ++#define getkey_example_usage \ ++ "$ getkey 5 'Press a key within %d seconds to interrupt autoboot.'" ++ + #define getopt_trivial_usage \ + "[OPTIONS]..." + #define getopt_full_usage \ diff --git a/meta/packages/busybox/busybox-1.01/angstrom/defconfig b/meta/packages/busybox/busybox-1.01/angstrom/defconfig new file mode 100644 index 000000000..34a5804a4 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/angstrom/defconfig @@ -0,0 +1,475 @@ +# +# Automatically generated make config: don't edit +# +HAVE_DOT_CONFIG=y + +# +# General Configuration +# +# CONFIG_FEATURE_BUFFERS_USE_MALLOC is not set +CONFIG_FEATURE_BUFFERS_GO_ON_STACK=y +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +# CONFIG_FEATURE_VERBOSE_USAGE is not set +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_LOCALE_SUPPORT is not set +# CONFIG_FEATURE_DEVFS is not set +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +# CONFIG_FEATURE_SUID is not set +# CONFIG_SELINUX is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +CONFIG_LFS=y +# USING_CROSS_COMPILER is not set +EXTRA_CFLAGS_OPTIONS="" + +# +# Installation Options +# +# CONFIG_INSTALL_NO_USR is not set +PREFIX="./_install" + +# +# Archival Utilities +# +CONFIG_AR=y +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +CONFIG_BUNZIP2=y +CONFIG_CPIO=y +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +CONFIG_GUNZIP=y +# CONFIG_FEATURE_GUNZIP_UNCOMPRESS is not set +CONFIG_GZIP=y +# CONFIG_RPM2CPIO is not set +# CONFIG_RPM is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_BZIP2=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_GZIP=y +# CONFIG_FEATURE_TAR_COMPRESS is not set +CONFIG_FEATURE_TAR_OLDGNU_COMPATABILITY=y +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_UNCOMPRESS is not set +# CONFIG_UNZIP is not set + +# +# Common options for cpio and tar +# +# CONFIG_FEATURE_UNARCHIVE_TAPE is not set + +# +# Coreutils +# +CONFIG_BASENAME=y +# CONFIG_CAL is not set +CONFIG_CAT=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_CHROOT=y +# CONFIG_CMP is not set +CONFIG_CP=y +CONFIG_CUT=y +CONFIG_DATE=y + +# +# date (forced enabled for use with watch) +# +# CONFIG_FEATURE_DATE_ISOFMT is not set +CONFIG_DD=y +CONFIG_DF=y +CONFIG_DIRNAME=y +# CONFIG_DOS2UNIX is not set +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFALT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPR=y +CONFIG_FALSE=y +# CONFIG_FOLD is not set +CONFIG_HEAD=y +# CONFIG_FEATURE_FANCY_HEAD is not set +# CONFIG_HOSTID is not set +CONFIG_ID=y +# CONFIG_INSTALL is not set +# CONFIG_LENGTH is not set +CONFIG_LN=y +CONFIG_LOGNAME=y +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +# CONFIG_FEATURE_LS_RECURSIVE is not set +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MV=y +CONFIG_OD=y +CONFIG_PRINTF=y +CONFIG_PWD=y +# CONFIG_REALPATH is not set +CONFIG_RM=y +CONFIG_RMDIR=y +CONFIG_SEQ=y +# CONFIG_SHA1SUM is not set +CONFIG_SLEEP=y +# CONFIG_FEATURE_FANCY_SLEEP is not set +CONFIG_SORT=y +CONFIG_STTY=y +CONFIG_SYNC=y +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +# CONFIG_FEATURE_TEE_USE_BLOCK_IO is not set +CONFIG_TEST=y + +# +# test (forced enabled for use with shell) +# +# CONFIG_FEATURE_TEST_64 is not set +CONFIG_TOUCH=y +CONFIG_TR=y +CONFIG_TRUE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNIQ=y +# CONFIG_USLEEP is not set +# CONFIG_UUDECODE is not set +# CONFIG_UUENCODE is not set +CONFIG_WATCH=y +CONFIG_WC=y +CONFIG_WHO=y +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options for cp and mv +# +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set + +# +# Common options for ls and more +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum +# +# CONFIG_FEATURE_MD5_SHA1_SUM_CHECK is not set + +# +# Console Utilities +# +CONFIG_CHVT=y +CONFIG_CLEAR=y +CONFIG_DEALLOCVT=y +# CONFIG_DUMPKMAP is not set +CONFIG_GETKEY=y +# CONFIG_LOADFONT is not set +# CONFIG_LOADKMAP is not set +CONFIG_OPENVT=y +CONFIG_RESET=y +# CONFIG_SETKEYCODES is not set + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +# CONFIG_PIPE_PROGRESS is not set +CONFIG_READLINK=y +CONFIG_FEATURE_READLINK_FOLLOW=y +CONFIG_RUN_PARTS=y +CONFIG_START_STOP_DAEMON=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_MATH=y +# CONFIG_PATCH is not set +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +CONFIG_FEATURE_VI_USE_SIGNALS=y +# CONFIG_FEATURE_VI_DOT_CMD is not set +# CONFIG_FEATURE_VI_READONLY is not set +# CONFIG_FEATURE_VI_SETOPTS is not set +# CONFIG_FEATURE_VI_SET is not set +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_OPTIMIZE_CURSOR=y + +# +# Finding Utilities +# +CONFIG_FIND=y +CONFIG_FEATURE_FIND_MTIME=y +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +CONFIG_FEATURE_FIND_NEWER=y +# CONFIG_FEATURE_FIND_INUM is not set +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +# CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION is not set +# CONFIG_FEATURE_XARGS_SUPPORT_QUOTES is not set +# CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT is not set +# CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM is not set + +# +# Init Utilities +# +# CONFIG_INIT is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +# CONFIG_REBOOT is not set +# CONFIG_MESG is not set + +# +# Login/Password Management Utilities +# +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_ADDGROUP is not set +# CONFIG_DELGROUP is not set +# CONFIG_ADDUSER is not set +# CONFIG_DELUSER is not set +# CONFIG_GETTY is not set +CONFIG_FEATURE_U_W_TMP=y +# CONFIG_LOGIN is not set +# CONFIG_PASSWD is not set +# CONFIG_SU is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +# CONFIG_CROND is not set +# CONFIG_CRONTAB is not set +CONFIG_DC=y +# CONFIG_DEVFSD is not set +# CONFIG_LAST is not set +# CONFIG_HDPARM is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_MT is not set +# CONFIG_RX is not set +CONFIG_STRINGS=y +# CONFIG_TIME is not set +# CONFIG_WATCHDOG is not set + +# +# Linux Module Utilities +# +CONFIG_INSMOD=y +CONFIG_FEATURE_2_4_MODULES=y +CONFIG_FEATURE_2_6_MODULES=y +# CONFIG_FEATURE_INSMOD_VERSION_CHECKING is not set +CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS=y +# CONFIG_FEATURE_INSMOD_LOADINKMEM is not set +CONFIG_FEATURE_INSMOD_LOAD_MAP=y +CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL=y +CONFIG_LSMOD=y +CONFIG_MODPROBE=y +CONFIG_RMMOD=y +CONFIG_FEATURE_CHECK_TAINTED_MODULE=y + +# +# Networking Utilities +# +CONFIG_FEATURE_IPV6=y +# CONFIG_ARPING is not set +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +CONFIG_HOSTNAME=y +# CONFIG_HTTPD is not set +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +CONFIG_FEATURE_IFCONFIG_HW=y +# CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS is not set +CONFIG_IFUPDOWN=y +# CONFIG_FEATURE_IFUPDOWN_IP is not set +CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +CONFIG_FEATURE_IFUPDOWN_IPV6=y +# CONFIG_FEATURE_IFUPDOWN_IPX is not set +CONFIG_FEATURE_IFUPDOWN_MAPPING=y +# CONFIG_INETD is not set +CONFIG_IP=y +CONFIG_FEATURE_IP_ADDRESS=y +CONFIG_FEATURE_IP_LINK=y +CONFIG_FEATURE_IP_ROUTE=y +CONFIG_FEATURE_IP_TUNNEL=y +# CONFIG_IPCALC is not set +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_NAMEIF is not set +CONFIG_NC=y +CONFIG_NETSTAT=y +CONFIG_NSLOOKUP=y +CONFIG_PING=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING6=y +CONFIG_ROUTE=y +CONFIG_TELNET=y +# CONFIG_FEATURE_TELNET_TTYPE is not set +CONFIG_FEATURE_TELNET_AUTOLOGIN=y +# CONFIG_TELNETD is not set +CONFIG_TFTP=y +CONFIG_FEATURE_TFTP_GET=y +CONFIG_FEATURE_TFTP_PUT=y +# CONFIG_FEATURE_TFTP_BLOCKSIZE is not set +# CONFIG_FEATURE_TFTP_DEBUG is not set +CONFIG_TRACEROUTE=y +# CONFIG_FEATURE_TRACEROUTE_VERBOSE is not set +# CONFIG_VCONFIG is not set +CONFIG_WGET=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_IP6_LITERAL=y + +# +# udhcp Server/Client +# +# CONFIG_UDHCPD is not set +CONFIG_UDHCPC=y +CONFIG_FEATURE_UDHCP_SYSLOG=y +# CONFIG_FEATURE_UDHCP_DEBUG is not set + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_KILL=y +CONFIG_KILLALL=y +# CONFIG_PIDOF is not set +CONFIG_PS=y +CONFIG_RENICE=y +CONFIG_TOP=y +FEATURE_CPU_USAGE_PERCENTAGE=y +CONFIG_UPTIME=y +# CONFIG_SYSCTL is not set + +# +# Another Bourne-like Shell +# +CONFIG_FEATURE_SH_IS_ASH=y +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_LASH is not set +# CONFIG_FEATURE_SH_IS_MSH is not set +# CONFIG_FEATURE_SH_IS_NONE is not set +CONFIG_ASH=y + +# +# Ash Shell Options +# +CONFIG_ASH_JOB_CONTROL=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_MATH_SUPPORT=y +# CONFIG_ASH_MATH_SUPPORT_64 is not set +CONFIG_ASH_GETOPTS=y +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_MAIL is not set +CONFIG_ASH_OPTIMIZE_FOR_SIZE=y +# CONFIG_ASH_RANDOM_SUPPORT is not set +# CONFIG_HUSH is not set +# CONFIG_LASH is not set +# CONFIG_MSH is not set + +# +# Bourne Shell Options +# +CONFIG_FEATURE_SH_EXTRA_QUIET=y +# CONFIG_FEATURE_SH_STANDALONE_SHELL is not set +CONFIG_FEATURE_COMMAND_EDITING=y +CONFIG_FEATURE_COMMAND_HISTORY=63 +# CONFIG_FEATURE_COMMAND_SAVEHISTORY is not set +CONFIG_FEATURE_COMMAND_TAB_COMPLETION=y +# CONFIG_FEATURE_COMMAND_USERNAME_COMPLETION is not set +CONFIG_FEATURE_SH_FANCY_PROMPT=y + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +# CONFIG_FEATURE_ROTATE_LOGFILE is not set +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_LOGREAD=y +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +CONFIG_KLOGD=y +CONFIG_LOGGER=y + +# +# Linux System Utilities +# +CONFIG_DMESG=y +CONFIG_FBSET=y +CONFIG_FEATURE_FBSET_FANCY=y +# CONFIG_FEATURE_FBSET_READMODE is not set +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +CONFIG_FDISK=y +FDISK_SUPPORT_LARGE_DISKS=y +CONFIG_FEATURE_FDISK_WRITABLE=y +# CONFIG_FEATURE_AIX_LABEL is not set +# CONFIG_FEATURE_SGI_LABEL is not set +# CONFIG_FEATURE_SUN_LABEL is not set +# CONFIG_FEATURE_OSF_LABEL is not set +# CONFIG_FEATURE_FDISK_ADVANCED is not set +# CONFIG_FREERAMDISK is not set +# CONFIG_FSCK_MINIX is not set +# CONFIG_MKFS_MINIX is not set +# CONFIG_GETOPT is not set +CONFIG_HEXDUMP=y +CONFIG_HWCLOCK=y +CONFIG_FEATURE_HWCLOCK_LONGOPTIONS=y +CONFIG_LOSETUP=y +CONFIG_MKSWAP=y +CONFIG_MORE=y +CONFIG_FEATURE_USE_TERMIOS=y +CONFIG_PIVOT_ROOT=y +# CONFIG_RDATE is not set +CONFIG_SWAPONOFF=y +CONFIG_MOUNT=y +CONFIG_NFSMOUNT=y +CONFIG_UMOUNT=y +CONFIG_FEATURE_MOUNT_FORCE=y + +# +# Common options for mount/umount +# +CONFIG_FEATURE_MOUNT_LOOP=y +# CONFIG_FEATURE_MTAB_SUPPORT is not set + +# +# Debugging Options +# +# CONFIG_DEBUG is not set diff --git a/meta/packages/busybox/busybox-1.01/below.patch b/meta/packages/busybox/busybox-1.01/below.patch new file mode 100644 index 000000000..ec97b2996 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/below.patch @@ -0,0 +1,49 @@ +Index: modutils/modprobe.c +=================================================================== +RCS file: /var/cvs/busybox/modutils/modprobe.c,v +retrieving revision 1.41 +diff -u -r1.41 modprobe.c +--- busybox/modutils/modprobe.c 24 Sep 2004 09:18:55 -0000 1.41 ++++ busybox/modutils/modprobe.c 29 Dec 2004 11:56:07 -0000 +@@ -357,6 +357,41 @@ + } + } + } ++ else if ((strncmp (buffer, "below", 5) == 0) && isspace (buffer[5])) { ++ char *mod, *deps; ++ if (parse_tag_value (buffer + 6, &mod, &deps)) { ++ struct dep_t *dt; ++ ++ for (dt = first; dt; dt = dt->m_next) { ++ if (strcmp (dt->m_name, mod) == 0) ++ break; ++ } ++ if (dt) { ++ char *pp; ++ char *name; ++ ++ pp = name = deps; ++ ++ for (;;) { ++ while (*pp != 0 && !isspace (*pp)) ++ pp++; ++ if (isspace (*pp)) ++ *(pp++) = 0; ++ ++ dt->m_depcnt++; ++ dt->m_deparr = (char **) xrealloc (dt->m_deparr, ++ sizeof (char *) * dt->m_depcnt); ++ dt->m_deparr[dt->m_depcnt - 1] = bb_xstrdup (name); ++ ++ while (isspace (*pp)) ++ pp++; ++ name = pp; ++ if (*pp == 0) ++ break; ++ } ++ } ++ } ++ } + } + } + close ( fd ); diff --git a/meta/packages/busybox/busybox-1.01/defconfig b/meta/packages/busybox/busybox-1.01/defconfig new file mode 100644 index 000000000..8b8212c54 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/defconfig @@ -0,0 +1,476 @@ +# +# Automatically generated make config: don't edit +# +HAVE_DOT_CONFIG=y + +# +# General Configuration +# +CONFIG_FEATURE_BUFFERS_USE_MALLOC=y +# CONFIG_FEATURE_BUFFERS_GO_ON_STACK is not set +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +# CONFIG_FEATURE_VERBOSE_USAGE is not set +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_LOCALE_SUPPORT is not set +CONFIG_FEATURE_DEVFS=y +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +# CONFIG_FEATURE_SUID is not set +# CONFIG_SELINUX is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +CONFIG_LFS=y +# USING_CROSS_COMPILER is not set +EXTRA_CFLAGS_OPTIONS="" + +# +# Installation Options +# +# CONFIG_INSTALL_NO_USR is not set +PREFIX="./_install" + +# +# Archival Utilities +# +CONFIG_AR=y +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +CONFIG_BUNZIP2=y +CONFIG_CPIO=y +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +CONFIG_GUNZIP=y +# CONFIG_FEATURE_GUNZIP_UNCOMPRESS is not set +CONFIG_GZIP=y +# CONFIG_RPM2CPIO is not set +# CONFIG_RPM is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_BZIP2=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_GZIP=y +# CONFIG_FEATURE_TAR_COMPRESS is not set +CONFIG_FEATURE_TAR_OLDGNU_COMPATABILITY=y +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_UNCOMPRESS is not set +CONFIG_UNZIP=y + +# +# Common options for cpio and tar +# +# CONFIG_FEATURE_UNARCHIVE_TAPE is not set + +# +# Coreutils +# +CONFIG_BASENAME=y +# CONFIG_CAL is not set +CONFIG_CAT=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_CHROOT=y +# CONFIG_CMP is not set +CONFIG_CP=y +CONFIG_CUT=y +CONFIG_DATE=y + +# +# date (forced enabled for use with watch) +# +# CONFIG_FEATURE_DATE_ISOFMT is not set +CONFIG_DD=y +CONFIG_DF=y +CONFIG_DIRNAME=y +# CONFIG_DOS2UNIX is not set +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFALT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPR=y +CONFIG_FALSE=y +# CONFIG_FOLD is not set +CONFIG_HEAD=y +# CONFIG_FEATURE_FANCY_HEAD is not set +# CONFIG_HOSTID is not set +CONFIG_ID=y +# CONFIG_INSTALL is not set +# CONFIG_LENGTH is not set +CONFIG_LN=y +CONFIG_LOGNAME=y +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +# CONFIG_FEATURE_LS_RECURSIVE is not set +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MV=y +CONFIG_OD=y +CONFIG_PRINTF=y +CONFIG_PWD=y +# CONFIG_REALPATH is not set +CONFIG_RM=y +CONFIG_RMDIR=y +CONFIG_SEQ=y +# CONFIG_SHA1SUM is not set +CONFIG_SLEEP=y +# CONFIG_FEATURE_FANCY_SLEEP is not set +CONFIG_SORT=y +CONFIG_STTY=y +CONFIG_SYNC=y +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +# CONFIG_FEATURE_TEE_USE_BLOCK_IO is not set +CONFIG_TEST=y + +# +# test (forced enabled for use with shell) +# +# CONFIG_FEATURE_TEST_64 is not set +CONFIG_TOUCH=y +CONFIG_TR=y +CONFIG_TRUE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNIQ=y +# CONFIG_USLEEP is not set +# CONFIG_UUDECODE is not set +# CONFIG_UUENCODE is not set +CONFIG_WATCH=y +CONFIG_WC=y +CONFIG_WHO=y +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options for cp and mv +# +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set + +# +# Common options for ls and more +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum +# +# CONFIG_FEATURE_MD5_SHA1_SUM_CHECK is not set + +# +# Console Utilities +# +CONFIG_CHVT=y +CONFIG_CLEAR=y +CONFIG_DEALLOCVT=y +CONFIG_DUMPKMAP=y +CONFIG_GETKEY=y +CONFIG_LOADFONT=y +CONFIG_LOADKMAP=y +CONFIG_OPENVT=y +CONFIG_RESET=y +# CONFIG_SETKEYCODES is not set + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +# CONFIG_PIPE_PROGRESS is not set +CONFIG_READLINK=y +CONFIG_FEATURE_READLINK_FOLLOW=y +CONFIG_RUN_PARTS=y +CONFIG_START_STOP_DAEMON=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_MATH=y +# CONFIG_PATCH is not set +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +CONFIG_FEATURE_VI_USE_SIGNALS=y +# CONFIG_FEATURE_VI_DOT_CMD is not set +# CONFIG_FEATURE_VI_READONLY is not set +# CONFIG_FEATURE_VI_SETOPTS is not set +# CONFIG_FEATURE_VI_SET is not set +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_OPTIMIZE_CURSOR=y + +# +# Finding Utilities +# +CONFIG_FIND=y +CONFIG_FEATURE_FIND_MTIME=y +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +CONFIG_FEATURE_FIND_NEWER=y +# CONFIG_FEATURE_FIND_INUM is not set +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +# CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION is not set +# CONFIG_FEATURE_XARGS_SUPPORT_QUOTES is not set +# CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT is not set +# CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM is not set + +# +# Init Utilities +# +# CONFIG_INIT is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +# CONFIG_REBOOT is not set +# CONFIG_MESG is not set + +# +# Login/Password Management Utilities +# +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_ADDGROUP is not set +# CONFIG_DELGROUP is not set +# CONFIG_ADDUSER is not set +# CONFIG_DELUSER is not set +# CONFIG_GETTY is not set +CONFIG_FEATURE_U_W_TMP=y +# CONFIG_LOGIN is not set +# CONFIG_PASSWD is not set +# CONFIG_SU is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +# CONFIG_CROND is not set +# CONFIG_CRONTAB is not set +CONFIG_DC=y +# CONFIG_DEVFSD is not set +# CONFIG_LAST is not set +# CONFIG_HDPARM is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_MT is not set +# CONFIG_RX is not set +CONFIG_STRINGS=y +# CONFIG_TIME is not set +# CONFIG_WATCHDOG is not set + +# +# Linux Module Utilities +# +CONFIG_INSMOD=y +CONFIG_FEATURE_2_4_MODULES=y +CONFIG_FEATURE_2_6_MODULES=y +# CONFIG_FEATURE_INSMOD_VERSION_CHECKING is not set +CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS=y +# CONFIG_FEATURE_INSMOD_LOADINKMEM is not set +CONFIG_FEATURE_INSMOD_LOAD_MAP=y +CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL=y +CONFIG_LSMOD=y +CONFIG_MODPROBE=y +CONFIG_RMMOD=y +CONFIG_FEATURE_CHECK_TAINTED_MODULE=y + +# +# Networking Utilities +# +CONFIG_FEATURE_IPV6=y +# CONFIG_ARPING is not set +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +CONFIG_HOSTNAME=y +# CONFIG_HTTPD is not set +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +CONFIG_FEATURE_IFCONFIG_HW=y +# CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS is not set +CONFIG_IFUPDOWN=y +# CONFIG_FEATURE_IFUPDOWN_IP is not set +CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +CONFIG_FEATURE_IFUPDOWN_IPV6=y +# CONFIG_FEATURE_IFUPDOWN_IPX is not set +CONFIG_FEATURE_IFUPDOWN_MAPPING=y +# CONFIG_INETD is not set +CONFIG_IP=y +CONFIG_FEATURE_IP_ADDRESS=y +CONFIG_FEATURE_IP_LINK=y +CONFIG_FEATURE_IP_ROUTE=y +CONFIG_FEATURE_IP_TUNNEL=y +# CONFIG_IPCALC is not set +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_NAMEIF is not set +CONFIG_NC=y +CONFIG_NETSTAT=y +CONFIG_NSLOOKUP=y +CONFIG_PING=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING6=y +CONFIG_ROUTE=y +CONFIG_TELNET=y +# CONFIG_FEATURE_TELNET_TTYPE is not set +CONFIG_FEATURE_TELNET_AUTOLOGIN=y +# CONFIG_TELNETD is not set +CONFIG_TFTP=y +CONFIG_TRACEROUTE=y +# CONFIG_FEATURE_TRACEROUTE_VERBOSE is not set +# CONFIG_VCONFIG is not set +CONFIG_WGET=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_IP6_LITERAL=y + +# +# udhcp Server/Client +# +CONFIG_UDHCPD=y +CONFIG_UDHCPC=y +CONFIG_FEATURE_UDHCP_SYSLOG=y +# CONFIG_FEATURE_UDHCP_DEBUG is not set + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_KILL=y +CONFIG_KILLALL=y +# CONFIG_PIDOF is not set +CONFIG_PS=y +CONFIG_RENICE=y +CONFIG_TOP=y +FEATURE_CPU_USAGE_PERCENTAGE=y +CONFIG_UPTIME=y +# CONFIG_SYSCTL is not set + +# +# Another Bourne-like Shell +# +CONFIG_FEATURE_SH_IS_ASH=y +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_LASH is not set +# CONFIG_FEATURE_SH_IS_MSH is not set +# CONFIG_FEATURE_SH_IS_NONE is not set +CONFIG_ASH=y + +# +# Ash Shell Options +# +CONFIG_ASH_JOB_CONTROL=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_MATH_SUPPORT=y +# CONFIG_ASH_MATH_SUPPORT_64 is not set +CONFIG_ASH_GETOPTS=y +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_MAIL is not set +CONFIG_ASH_OPTIMIZE_FOR_SIZE=y +# CONFIG_ASH_RANDOM_SUPPORT is not set +# CONFIG_HUSH is not set +# CONFIG_LASH is not set +# CONFIG_MSH is not set + +# +# Bourne Shell Options +# +CONFIG_FEATURE_SH_EXTRA_QUIET=y +# CONFIG_FEATURE_SH_STANDALONE_SHELL is not set +CONFIG_FEATURE_COMMAND_EDITING=y +CONFIG_FEATURE_COMMAND_HISTORY=63 +# CONFIG_FEATURE_COMMAND_SAVEHISTORY is not set +CONFIG_FEATURE_COMMAND_TAB_COMPLETION=y +# CONFIG_FEATURE_COMMAND_USERNAME_COMPLETION is not set +CONFIG_FEATURE_SH_FANCY_PROMPT=y + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +# CONFIG_FEATURE_ROTATE_LOGFILE is not set +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_LOGREAD=y +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +CONFIG_KLOGD=y +CONFIG_LOGGER=y + +# +# Linux System Utilities +# +CONFIG_DMESG=y +CONFIG_FBSET=y +CONFIG_FEATURE_FBSET_FANCY=y +# CONFIG_FEATURE_FBSET_READMODE is not set +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +CONFIG_FDISK=y +FDISK_SUPPORT_LARGE_DISKS=y +CONFIG_FEATURE_FDISK_WRITABLE=y +# CONFIG_FEATURE_AIX_LABEL is not set +# CONFIG_FEATURE_SGI_LABEL is not set +# CONFIG_FEATURE_SUN_LABEL is not set +# CONFIG_FEATURE_OSF_LABEL is not set +# CONFIG_FEATURE_FDISK_ADVANCED is not set +# CONFIG_FREERAMDISK is not set +CONFIG_FSCK_MINIX=y +CONFIG_MKFS_MINIX=y + +# +# Minix filesystem support +# +CONFIG_FEATURE_MINIX2=y +# CONFIG_GETOPT is not set +CONFIG_HEXDUMP=y +CONFIG_HWCLOCK=y +CONFIG_FEATURE_HWCLOCK_LONGOPTIONS=y +CONFIG_LOSETUP=y +CONFIG_MKSWAP=y +CONFIG_MORE=y +CONFIG_FEATURE_USE_TERMIOS=y +CONFIG_PIVOT_ROOT=y +# CONFIG_RDATE is not set +CONFIG_SWAPONOFF=y +CONFIG_MOUNT=y +CONFIG_NFSMOUNT=y +CONFIG_UMOUNT=y +CONFIG_FEATURE_MOUNT_FORCE=y + +# +# Common options for mount/umount +# +CONFIG_FEATURE_MOUNT_LOOP=y +# CONFIG_FEATURE_MTAB_SUPPORT is not set + +# +# Debugging Options +# +# CONFIG_DEBUG is not set diff --git a/meta/packages/busybox/busybox-1.01/dhcp-hostname.patch b/meta/packages/busybox/busybox-1.01/dhcp-hostname.patch new file mode 100644 index 000000000..e0adea662 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/dhcp-hostname.patch @@ -0,0 +1,30 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- busybox-1.01/networking/udhcp/dhcpc.c~dhcp-hostname ++++ busybox-1.01/networking/udhcp/dhcpc.c +@@ -193,6 +193,7 @@ + int max_fd; + int sig; + int no_clientid = 0; ++ char hostbuf[256]; /* SUSv2: hostnames are <= 255 bytes */ + + static const struct option arg_options[] = { + {"clientid", required_argument, 0, 'c'}, +@@ -211,6 +212,14 @@ + {0, 0, 0, 0} + }; + ++ if (gethostname (hostbuf, sizeof (hostbuf)) == 0) { ++ len = strlen (hostbuf); ++ client_config.hostname = xmalloc (len + 2); ++ client_config.hostname[OPT_CODE] = DHCP_HOST_NAME; ++ client_config.hostname[OPT_LEN] = len; ++ strncpy(client_config.hostname + 2, hostbuf, len); ++ } ++ + /* get options */ + while (1) { + int option_index = 0; diff --git a/meta/packages/busybox/busybox-1.01/dhcpretrytime.patch b/meta/packages/busybox/busybox-1.01/dhcpretrytime.patch new file mode 100644 index 000000000..e41ea9de5 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/dhcpretrytime.patch @@ -0,0 +1,81 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- busybox-1.01/networking/udhcp/dhcpc.c~dhcpretrytime ++++ busybox-1.01/networking/udhcp/dhcpc.c +@@ -48,6 +48,7 @@ + static unsigned long requested_ip; /* = 0 */ + static unsigned long server_addr; + static unsigned long timeout; ++static unsigned long retrytime = 60; + static int packet_num; /* = 0 */ + static int fd = -1; + +@@ -91,6 +92,7 @@ + " -r, --request=IP IP address to request (default: none)\n" + " -s, --script=file Run file at dhcp events (default:\n" + " " DEFAULT_SCRIPT ")\n" ++" -t, --retrytime time to retry DHCP request (default 60s)\n") + " -v, --version Display version\n" + ); + exit(0); +@@ -208,6 +210,7 @@ + {"quit", no_argument, 0, 'q'}, + {"request", required_argument, 0, 'r'}, + {"script", required_argument, 0, 's'}, ++ {"retrytime", required_argument, 0, 't'}, + {"version", no_argument, 0, 'v'}, + {0, 0, 0, 0} + }; +@@ -223,7 +226,7 @@ + /* get options */ + while (1) { + int option_index = 0; +- c = getopt_long(argc, argv, "c:CfbH:h:i:np:qr:s:v", arg_options, &option_index); ++ c = getopt_long(argc, argv, "c:fbH:h:i:np:qr:s:t:v", arg_options, &option_index); + if (c == -1) break; + + switch (c) { +@@ -274,6 +277,9 @@ + case 's': + client_config.script = optarg; + break; ++ case 't': ++ retrytime = atol(optarg); ++ break; + case 'v': + printf("udhcpcd, version %s\n\n", VERSION); + return 0; +@@ -353,7 +359,7 @@ + } + /* wait to try again */ + packet_num = 0; +- timeout = now + 60; ++ timeout = now + retrytime; + } + break; + case RENEW_REQUESTED: +--- busybox-1.01/networking/ifupdown.c~dhcpretrytime ++++ busybox-1.01/networking/ifupdown.c +@@ -541,7 +541,7 @@ + static int dhcp_up(struct interface_defn_t *ifd, execfn *exec) + { + if (execable("/sbin/udhcpc")) { +- return( execute("udhcpc -n -p /var/run/udhcpc.%iface%.pid -i " ++ return( execute("udhcpc -b -p /var/run/udhcpc.%iface%.pid -i " + "%iface% [[-H %hostname%]] [[-c %clientid%]]", ifd, exec)); + } else if (execable("/sbin/pump")) { + return( execute("pump -i %iface% [[-h %hostname%]] [[-l %leasehours%]]", ifd, exec)); +@@ -561,8 +561,8 @@ + /* SIGUSR2 forces udhcpc to release the current lease and go inactive, + * and SIGTERM causes udhcpc to exit. Signals are queued and processed + * sequentially so we don't need to sleep */ +- result = execute("kill -USR2 `cat /var/run/udhcpc.%iface%.pid` 2>/dev/null", ifd, exec); +- result += execute("kill -TERM `cat /var/run/udhcpc.%iface%.pid` 2>/dev/null", ifd, exec); ++ result = execute("kill -USR2 `cat /var/run/udhcpc.%iface%.pid 2>/dev/null` 2>/dev/null", ifd, exec); ++ result += execute("kill -TERM `cat /var/run/udhcpc.%iface%.pid 2>/dev/null` 2>/dev/null", ifd, exec); + } else if (execable("/sbin/pump")) { + result = execute("pump -i %iface% -k", ifd, exec); + } else if (execable("/sbin/dhclient")) { diff --git a/meta/packages/busybox/busybox-1.01/familiar/defconfig b/meta/packages/busybox/busybox-1.01/familiar/defconfig new file mode 100644 index 000000000..49dd403eb --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/familiar/defconfig @@ -0,0 +1,470 @@ +# +# Automatically generated make config: don't edit +# +HAVE_DOT_CONFIG=y + +# +# General Configuration +# +# CONFIG_FEATURE_BUFFERS_USE_MALLOC is not set +CONFIG_FEATURE_BUFFERS_GO_ON_STACK=y +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +# CONFIG_FEATURE_VERBOSE_USAGE is not set +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_LOCALE_SUPPORT is not set +CONFIG_FEATURE_DEVFS=y +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +CONFIG_FEATURE_SUID=y +# CONFIG_FEATURE_SUID_CONFIG is not set +# CONFIG_SELINUX is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +CONFIG_LFS=y +# USING_CROSS_COMPILER is not set +EXTRA_CFLAGS_OPTIONS="" + +# +# Installation Options +# +# CONFIG_INSTALL_NO_USR is not set +PREFIX="./_install" + +# +# Archival Utilities +# +CONFIG_AR=y +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +CONFIG_BUNZIP2=y +CONFIG_CPIO=y +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +CONFIG_GUNZIP=y +# CONFIG_FEATURE_GUNZIP_UNCOMPRESS is not set +CONFIG_GZIP=y +# CONFIG_RPM2CPIO is not set +# CONFIG_RPM is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_BZIP2=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_GZIP=y +# CONFIG_FEATURE_TAR_COMPRESS is not set +CONFIG_FEATURE_TAR_OLDGNU_COMPATABILITY=y +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_UNCOMPRESS is not set +# CONFIG_UNZIP is not set + +# +# Common options for cpio and tar +# +# CONFIG_FEATURE_UNARCHIVE_TAPE is not set + +# +# Coreutils +# +CONFIG_BASENAME=y +# CONFIG_CAL is not set +CONFIG_CAT=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_CHROOT=y +# CONFIG_CMP is not set +CONFIG_CP=y +CONFIG_CUT=y +CONFIG_DATE=y + +# +# date (forced enabled for use with watch) +# +# CONFIG_FEATURE_DATE_ISOFMT is not set +CONFIG_DD=y +CONFIG_DF=y +CONFIG_DIRNAME=y +# CONFIG_DOS2UNIX is not set +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFALT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPR=y +CONFIG_FALSE=y +# CONFIG_FOLD is not set +CONFIG_HEAD=y +# CONFIG_FEATURE_FANCY_HEAD is not set +# CONFIG_HOSTID is not set +CONFIG_ID=y +# CONFIG_INSTALL is not set +# CONFIG_LENGTH is not set +CONFIG_LN=y +CONFIG_LOGNAME=y +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +# CONFIG_FEATURE_LS_RECURSIVE is not set +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MV=y +CONFIG_OD=y +CONFIG_PRINTF=y +CONFIG_PWD=y +# CONFIG_REALPATH is not set +CONFIG_RM=y +CONFIG_RMDIR=y +CONFIG_SEQ=y +# CONFIG_SHA1SUM is not set +CONFIG_SLEEP=y +# CONFIG_FEATURE_FANCY_SLEEP is not set +CONFIG_SORT=y +CONFIG_STTY=y +CONFIG_SYNC=y +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +# CONFIG_FEATURE_TEE_USE_BLOCK_IO is not set +CONFIG_TEST=y + +# +# test (forced enabled for use with shell) +# +# CONFIG_FEATURE_TEST_64 is not set +CONFIG_TOUCH=y +CONFIG_TR=y +CONFIG_TRUE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNIQ=y +# CONFIG_USLEEP is not set +# CONFIG_UUDECODE is not set +# CONFIG_UUENCODE is not set +CONFIG_WATCH=y +CONFIG_WC=y +CONFIG_WHO=y +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options for cp and mv +# +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set + +# +# Common options for ls and more +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum +# +# CONFIG_FEATURE_MD5_SHA1_SUM_CHECK is not set + +# +# Console Utilities +# +CONFIG_CHVT=y +CONFIG_CLEAR=y +CONFIG_DEALLOCVT=y +CONFIG_DUMPKMAP=y +CONFIG_GETKEY=y +CONFIG_LOADFONT=y +CONFIG_LOADKMAP=y +CONFIG_OPENVT=y +CONFIG_RESET=y +# CONFIG_SETKEYCODES is not set + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +# CONFIG_PIPE_PROGRESS is not set +CONFIG_READLINK=y +CONFIG_FEATURE_READLINK_FOLLOW=y +CONFIG_RUN_PARTS=y +CONFIG_START_STOP_DAEMON=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_MATH=y +# CONFIG_PATCH is not set +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +CONFIG_FEATURE_VI_USE_SIGNALS=y +# CONFIG_FEATURE_VI_DOT_CMD is not set +# CONFIG_FEATURE_VI_READONLY is not set +# CONFIG_FEATURE_VI_SETOPTS is not set +# CONFIG_FEATURE_VI_SET is not set +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_OPTIMIZE_CURSOR=y + +# +# Finding Utilities +# +CONFIG_FIND=y +CONFIG_FEATURE_FIND_MTIME=y +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +CONFIG_FEATURE_FIND_NEWER=y +# CONFIG_FEATURE_FIND_INUM is not set +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +# CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION is not set +# CONFIG_FEATURE_XARGS_SUPPORT_QUOTES is not set +# CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT is not set +# CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM is not set + +# +# Init Utilities +# +# CONFIG_INIT is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +# CONFIG_REBOOT is not set +# CONFIG_MESG is not set + +# +# Login/Password Management Utilities +# +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_ADDGROUP is not set +# CONFIG_DELGROUP is not set +# CONFIG_ADDUSER is not set +# CONFIG_DELUSER is not set +# CONFIG_GETTY is not set +CONFIG_FEATURE_UTMP=y +# CONFIG_LOGIN is not set +# CONFIG_PASSWD is not set +# CONFIG_SU is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +# CONFIG_CROND is not set +# CONFIG_CRONTAB is not set +CONFIG_DC=y +# CONFIG_DEVFSD is not set +# CONFIG_LAST is not set +# CONFIG_HDPARM is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_MT is not set +# CONFIG_RX is not set +CONFIG_STRINGS=y +# CONFIG_TIME is not set +# CONFIG_WATCHDOG is not set + +# +# Linux Module Utilities +# +CONFIG_INSMOD=y +CONFIG_FEATURE_2_4_MODULES=y +CONFIG_FEATURE_2_6_MODULES=y +# CONFIG_FEATURE_INSMOD_VERSION_CHECKING is not set +CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS=y +# CONFIG_FEATURE_INSMOD_LOADINKMEM is not set +CONFIG_FEATURE_INSMOD_LOAD_MAP=y +CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL=y +CONFIG_LSMOD=y +CONFIG_MODPROBE=y +CONFIG_RMMOD=y +CONFIG_FEATURE_CHECK_TAINTED_MODULE=y + +# +# Networking Utilities +# +CONFIG_FEATURE_IPV6=y +# CONFIG_ARPING is not set +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +CONFIG_HOSTNAME=y +# CONFIG_HTTPD is not set +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +CONFIG_FEATURE_IFCONFIG_HW=y +# CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS is not set +CONFIG_IFUPDOWN=y +# CONFIG_FEATURE_IFUPDOWN_IP is not set +CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +CONFIG_FEATURE_IFUPDOWN_IPV6=y +# CONFIG_FEATURE_IFUPDOWN_IPX is not set +CONFIG_FEATURE_IFUPDOWN_MAPPING=y +# CONFIG_INETD is not set +CONFIG_IP=y +CONFIG_FEATURE_IP_ADDRESS=y +CONFIG_FEATURE_IP_LINK=y +CONFIG_FEATURE_IP_ROUTE=y +CONFIG_FEATURE_IP_TUNNEL=y +# CONFIG_IPCALC is not set +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_NAMEIF is not set +CONFIG_NC=y +CONFIG_NETSTAT=y +CONFIG_NSLOOKUP=y +CONFIG_PING=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING6=y +CONFIG_ROUTE=y +CONFIG_TELNET=y +# CONFIG_FEATURE_TELNET_TTYPE is not set +CONFIG_FEATURE_TELNET_AUTOLOGIN=y +# CONFIG_TELNETD is not set +CONFIG_TFTP=y +CONFIG_FEATURE_TFTP_GET=y +CONFIG_FEATURE_TFTP_PUT=y +# CONFIG_FEATURE_TFTP_BLOCKSIZE is not set +# CONFIG_FEATURE_TFTP_DEBUG is not set +CONFIG_TRACEROUTE=y +# CONFIG_FEATURE_TRACEROUTE_VERBOSE is not set +# CONFIG_VCONFIG is not set +CONFIG_WGET=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_IP6_LITERAL=y + +# +# udhcp Server/Client +# +# CONFIG_UDHCPD is not set +CONFIG_UDHCPC=y +CONFIG_FEATURE_UDHCP_SYSLOG=y +# CONFIG_FEATURE_UDHCP_DEBUG is not set + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_KILL=y +CONFIG_KILLALL=y +# CONFIG_PIDOF is not set +CONFIG_PS=y +CONFIG_RENICE=y +CONFIG_TOP=y +FEATURE_CPU_USAGE_PERCENTAGE=y +CONFIG_UPTIME=y +# CONFIG_SYSCTL is not set + +# +# Another Bourne-like Shell +# +CONFIG_FEATURE_SH_IS_ASH=y +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_LASH is not set +# CONFIG_FEATURE_SH_IS_MSH is not set +# CONFIG_FEATURE_SH_IS_NONE is not set +CONFIG_ASH=y + +# +# Ash Shell Options +# +CONFIG_ASH_JOB_CONTROL=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_MATH_SUPPORT=y +# CONFIG_ASH_MATH_SUPPORT_64 is not set +CONFIG_ASH_GETOPTS=y +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_MAIL is not set +CONFIG_ASH_OPTIMIZE_FOR_SIZE=y +# CONFIG_ASH_RANDOM_SUPPORT is not set +# CONFIG_HUSH is not set +# CONFIG_LASH is not set +# CONFIG_MSH is not set + +# +# Bourne Shell Options +# +CONFIG_FEATURE_SH_EXTRA_QUIET=y +# CONFIG_FEATURE_SH_STANDALONE_SHELL is not set +CONFIG_FEATURE_COMMAND_EDITING=y +CONFIG_FEATURE_COMMAND_HISTORY=63 +# CONFIG_FEATURE_COMMAND_SAVEHISTORY is not set +CONFIG_FEATURE_COMMAND_TAB_COMPLETION=y +# CONFIG_FEATURE_COMMAND_USERNAME_COMPLETION is not set +CONFIG_FEATURE_SH_FANCY_PROMPT=y + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +# CONFIG_FEATURE_ROTATE_LOGFILE is not set +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_LOGREAD=y +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +CONFIG_KLOGD=y +CONFIG_LOGGER=y + +# +# Linux System Utilities +# +CONFIG_DMESG=y +CONFIG_FBSET=y +CONFIG_FEATURE_FBSET_FANCY=y +# CONFIG_FEATURE_FBSET_READMODE is not set +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +# CONFIG_FDISK is not set +FDISK_SUPPORT_LARGE_DISKS=y +# CONFIG_FREERAMDISK is not set +# CONFIG_FSCK_MINIX is not set +# CONFIG_MKFS_MINIX is not set +# CONFIG_GETOPT is not set +CONFIG_HEXDUMP=y +CONFIG_HWCLOCK=y +CONFIG_FEATURE_HWCLOCK_LONGOPTIONS=y +CONFIG_LOSETUP=y +CONFIG_MKSWAP=y +CONFIG_MORE=y +CONFIG_FEATURE_USE_TERMIOS=y +CONFIG_PIVOT_ROOT=y +# CONFIG_RDATE is not set +CONFIG_SWAPONOFF=y +CONFIG_MOUNT=y +CONFIG_NFSMOUNT=y +CONFIG_UMOUNT=y +CONFIG_FEATURE_MOUNT_FORCE=y + +# +# Common options for mount/umount +# +CONFIG_FEATURE_MOUNT_LOOP=y +# CONFIG_FEATURE_MTAB_SUPPORT is not set + +# +# Debugging Options +# +# CONFIG_DEBUG is not set diff --git a/meta/packages/busybox/busybox-1.01/fbset.patch b/meta/packages/busybox/busybox-1.01/fbset.patch new file mode 100644 index 000000000..d0609ce6f --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/fbset.patch @@ -0,0 +1,24 @@ +--- busybox/util-linux/fbset.c~ 2004-07-03 16:24:23.000000000 +0100 ++++ busybox/util-linux/fbset.c 2004-12-30 20:09:26.000000000 +0000 +@@ -337,7 +337,7 @@ + { + struct fb_var_screeninfo var, varset; + int fh, i; +- char *fbdev = DEFAULTFBDEV; ++ char *fbdev = NULL; + char *modefile = DEFAULTFBMODE; + char *thisarg, *mode = NULL; + +@@ -404,7 +404,12 @@ + } + } + ++ if (fbdev == NULL) ++ fbdev = DEFAULTFBDEV; + if ((fh = open(fbdev, O_RDONLY)) < 0) ++#ifdef CONFIG_FEATURE_DEVFS ++ if ((fh = open("/dev/fb0", O_RDONLY)) < 0) ++#endif + bb_perror_msg_and_die("fbset(open)"); + if (ioctl(fh, FBIOGET_VSCREENINFO, &var)) + bb_perror_msg_and_die("fbset(ioctl)"); diff --git a/meta/packages/busybox/busybox-1.01/hdparm_M.patch b/meta/packages/busybox/busybox-1.01/hdparm_M.patch new file mode 100644 index 000000000..170906535 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/hdparm_M.patch @@ -0,0 +1,47 @@ +diff -Naur busybox-1.00/miscutils/hdparm.c busybox-1.00-patched/miscutils/hdparm.c +--- busybox-1.00/miscutils/hdparm.c 2004-07-21 00:53:59.000000000 +0200 ++++ busybox-1.00-patched/miscutils/hdparm.c 2004-10-21 15:17:13.000000000 +0200 +@@ -1254,6 +1254,7 @@ + static unsigned long set_sleepnow = 0, get_sleepnow = 0; + static unsigned long get_powermode = 0; + static unsigned long set_apmmode = 0, get_apmmode= 0, apmmode = 0; ++static unsigned long set_acoustic = 0, get_acoustic = 0, acoustic = 0; + #endif + #ifdef CONFIG_FEATURE_HDPARM_GET_IDENTITY + static int get_IDentity = 0; +@@ -2123,6 +2124,20 @@ + } + bb_ioctl(fd, HDIO_DRIVE_CMD, &args,"HDIO_DRIVE_CMD"); + } ++ if (set_acoustic) ++ { ++ no_scsi(); ++ acoustic=check_if_min_and_set_val(acoustic,0); ++ acoustic=check_if_maj_and_set_val(acoustic,254); ++ if_printf(get_acoustic," setting AAM level to 0x%02lX (%ld)\n", acoustic, acoustic); ++ bb_ioctl(fd, HDIO_SET_ACOUSTIC, (int*)acoustic,"HDIO_SET_ACOUSTIC"); ++ } ++ if (get_acoustic) ++ { ++ no_scsi(); ++ bb_ioctl(fd, HDIO_GET_ACOUSTIC, (unsigned long*)&parm,"HDIO_GET_ACOUSTIC"); ++ printf(" acoustic = %2ld (128=quiet ... 254=fast)\n", parm); ++ } + if (set_wcache) + { + #ifdef DO_FLUSHCACHE +@@ -2831,6 +2846,13 @@ + p = *argv++, --argc; + p=GET_NUMBER(p,&set_readahead,&Xreadahead); + break; ++ case 'M': ++ get_acoustic = noisy; ++ noisy = 1; ++ if (!*p && argc && isalnum(**argv)) ++ p = *argv++, --argc; ++ p=GET_NUMBER(p,&set_acoustic,&acoustic); ++ break; + case 'B': + get_apmmode = noisy; + noisy = 1; + diff --git a/meta/packages/busybox/busybox-1.01/ifupdown-spurious-environ.patch b/meta/packages/busybox/busybox-1.01/ifupdown-spurious-environ.patch new file mode 100644 index 000000000..8753315f2 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/ifupdown-spurious-environ.patch @@ -0,0 +1,12 @@ +--- busybox-1.00/networking/ifupdown.c.old 2005-06-11 19:51:59.000000000 +0100 ++++ busybox-1.00/networking/ifupdown.c 2005-06-11 19:52:19.000000000 +0100 +@@ -148,6 +148,9 @@ + struct mapping_defn_t *mappings; + }; + ++/* XXX */ ++#define environ local_environ ++ + static char no_act = 0; + static char verbose = 0; + static char **environ = NULL; diff --git a/meta/packages/busybox/busybox-1.01/iproute-flush-cache.patch b/meta/packages/busybox/busybox-1.01/iproute-flush-cache.patch new file mode 100644 index 000000000..f8becc339 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/iproute-flush-cache.patch @@ -0,0 +1,23 @@ +Index: networking/libiproute/iproute.c +=================================================================== +RCS file: /var/cvs/busybox/networking/libiproute/iproute.c,v +retrieving revision 1.14 +diff -u -r1.14 iproute.c +--- networking/libiproute/iproute.c 11 Aug 2004 08:10:58 -0000 1.14 ++++ networking/libiproute/iproute.c 30 Nov 2004 20:43:44 -0000 +@@ -537,6 +537,15 @@ + } else if (matches(*argv, "match") == 0) { + NEXT_ARG(); + get_prefix(&filter.mdst, *argv, do_ipv6); ++ } else if (matches(*argv, "table") == 0) { ++ NEXT_ARG(); ++ if (matches(*argv, "cache") == 0) { ++ filter.tb = -1; ++ } else if (matches(*argv, "main") != 0) { ++ invarg("invalid \"table\"", *argv); ++ } ++ } else if (matches(*argv, "cache") == 0) { ++ filter.tb = -1; + } else { + if (matches(*argv, "exact") == 0) { + NEXT_ARG(); diff --git a/meta/packages/busybox/busybox-1.01/mount-all-type.patch b/meta/packages/busybox/busybox-1.01/mount-all-type.patch new file mode 100644 index 000000000..476094a80 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/mount-all-type.patch @@ -0,0 +1,84 @@ +--- busybox-1.00/.pc/mount-all-type.patch/util-linux/mount.c 2004-08-02 17:14:02.000000000 -0700 ++++ busybox-1.00/util-linux/mount.c 2005-05-13 00:17:19.054232796 -0700 +@@ -364,6 +364,56 @@ + exit(EXIT_SUCCESS); + } + ++/* Does this file system type, from /etc/fstab, match the given ++ * -t option value? ++ */ ++static int match_fs(const char *option, const char *type) ++{ ++ const int len = strlen(type); ++ const int no = option[0] == 'n' && option[1] == 'o'; ++ const char *optp = option; ++ ++ if (len > 0) do { ++ const char *match = strstr(optp, type); ++ ++ if (match == NULL) { ++ /* No match, but if the option string starts 'no' no match ++ * means yes. ++ */ ++ return no; ++ } ++ ++ /* Match, may be partial, check for end-of-type in option string. */ ++ if (match[len] == 0 || match[len] == ',') { ++ /* Ok, check for type or notype. */ ++ if (match == option) { ++ /* Exact match at start (can't be 'no') */ ++ return 1; ++ } ++ if (match > option+1) { ++ if (match[-1] == ',') { ++ /* Exact match in middle, might be 'no' */ ++ return !no; ++ } ++ if (match == option+2 && no) { ++ /* Exact match to 'notype' at start. */ ++ return 0; ++ } ++ if (match > option+2 && match[-3] == ',' && ++ match[-2] == 'n' && match[-1] == 'o') { ++ return 0; ++ } ++ } ++ } ++ ++ /* Look for another match. */ ++ optp = match+1; ++ } while (1); ++ ++ /* zero length type in fstab (impossible?), don't match it. */ ++ return 0; ++} ++ + extern int mount_main(int argc, char **argv) + { + struct stat statbuf; +@@ -371,6 +421,7 @@ + char *extra_opts; + int flags = 0; + char *filesystemType = "auto"; ++ char *filesystemOption = 0; + int got_filesystemType = 0; + char *device = xmalloc(PATH_MAX); + char *directory = xmalloc(PATH_MAX); +@@ -393,6 +444,7 @@ + break; + case 't': + filesystemType = optarg; ++ filesystemOption = optarg; + got_filesystemType = 1; + break; + case 'w': +@@ -460,6 +512,8 @@ + + strcpy(device, m->mnt_fsname); + strcpy(directory, m->mnt_dir); ++ if (all && filesystemOption != 0 && !match_fs(filesystemOption, m->mnt_type)) ++ continue; + filesystemType = bb_xstrdup(m->mnt_type); + singlemount: + extra_opts = string_flags; diff --git a/meta/packages/busybox/busybox-1.01/nylon/defconfig b/meta/packages/busybox/busybox-1.01/nylon/defconfig new file mode 100644 index 000000000..599051baf --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/nylon/defconfig @@ -0,0 +1,458 @@ +# +# Automatically generated make config: don't edit +# +HAVE_DOT_CONFIG=y + +# +# General Configuration +# +CONFIG_FEATURE_BUFFERS_USE_MALLOC=y +# CONFIG_FEATURE_BUFFERS_GO_ON_STACK is not set +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +CONFIG_FEATURE_VERBOSE_USAGE=y +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_LOCALE_SUPPORT is not set +CONFIG_FEATURE_DEVFS=y +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +CONFIG_FEATURE_SUID=y +CONFIG_FEATURE_SUID_CONFIG=y +CONFIG_FEATURE_SUID_CONFIG_QUIET=y +# CONFIG_SELINUX is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +# CONFIG_LFS is not set +# USING_CROSS_COMPILER is not set +EXTRA_CFLAGS_OPTIONS="" + +# +# Installation Options +# +# CONFIG_INSTALL_NO_USR is not set +PREFIX="./_install" + +# +# Archival Utilities +# +CONFIG_AR=y +CONFIG_FEATURE_AR_LONG_FILENAMES=y +CONFIG_BUNZIP2=y +CONFIG_CPIO=y +CONFIG_DPKG=y +CONFIG_DPKG_DEB=y +# CONFIG_FEATURE_DPKG_DEB_EXTRACT_ONLY is not set +CONFIG_GUNZIP=y +CONFIG_FEATURE_GUNZIP_UNCOMPRESS=y +CONFIG_GZIP=y +# CONFIG_RPM2CPIO is not set +# CONFIG_RPM is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_BZIP2=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_GZIP=y +CONFIG_FEATURE_TAR_COMPRESS=y +CONFIG_FEATURE_TAR_OLDGNU_COMPATABILITY=y +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +CONFIG_FEATURE_TAR_LONG_OPTIONS=y +CONFIG_UNCOMPRESS=y +CONFIG_UNZIP=y + +# +# Common options for cpio and tar +# +# CONFIG_FEATURE_UNARCHIVE_TAPE is not set + +# +# Common options for dpkg and dpkg_deb +# +CONFIG_FEATURE_DEB_TAR_GZ=y +CONFIG_FEATURE_DEB_TAR_BZ2=y + +# +# Coreutils +# +CONFIG_BASENAME=y +CONFIG_CAL=y +CONFIG_CAT=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_CHROOT=y +CONFIG_CMP=y +CONFIG_CP=y +CONFIG_CUT=y +CONFIG_DATE=y + +# +# date (forced enabled for use with watch) +# +CONFIG_FEATURE_DATE_ISOFMT=y +CONFIG_DD=y +CONFIG_DF=y +CONFIG_DIRNAME=y +CONFIG_DOS2UNIX=y +CONFIG_UNIX2DOS=y +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFALT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPR=y +CONFIG_FALSE=y +CONFIG_FOLD=y +CONFIG_HEAD=y +CONFIG_FEATURE_FANCY_HEAD=y +CONFIG_HOSTID=y +CONFIG_ID=y +CONFIG_INSTALL=y +CONFIG_LENGTH=y +CONFIG_LN=y +CONFIG_LOGNAME=y +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +CONFIG_FEATURE_LS_RECURSIVE=y +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MV=y +CONFIG_OD=y +CONFIG_PRINTF=y +CONFIG_PWD=y +CONFIG_REALPATH=y +CONFIG_RM=y +CONFIG_RMDIR=y +CONFIG_SEQ=y +CONFIG_SHA1SUM=y +CONFIG_SLEEP=y +CONFIG_FEATURE_FANCY_SLEEP=y +CONFIG_SORT=y +CONFIG_STTY=y +CONFIG_SYNC=y +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +CONFIG_FEATURE_TEE_USE_BLOCK_IO=y +# CONFIG_TEST is not set +CONFIG_TOUCH=y +CONFIG_TR=y +CONFIG_TRUE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNIQ=y +CONFIG_USLEEP=y +CONFIG_UUDECODE=y +CONFIG_UUENCODE=y +CONFIG_WATCH=y +CONFIG_WC=y +CONFIG_WHO=y +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options for cp and mv +# +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set + +# +# Common options for ls and more +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum +# +CONFIG_FEATURE_MD5_SHA1_SUM_CHECK=y + +# +# Console Utilities +# +# CONFIG_CHVT is not set +CONFIG_CLEAR=y +# CONFIG_DEALLOCVT is not set +CONFIG_DUMPKMAP=y +CONFIG_GETKEY=y +# CONFIG_LOADFONT is not set +CONFIG_LOADKMAP=y +# CONFIG_OPENVT is not set +CONFIG_RESET=y +CONFIG_SETKEYCODES=y + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +CONFIG_PIPE_PROGRESS=y +CONFIG_READLINK=y +CONFIG_FEATURE_READLINK_FOLLOW=y +CONFIG_RUN_PARTS=y +CONFIG_START_STOP_DAEMON=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_MATH=y +CONFIG_PATCH=y +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +CONFIG_FEATURE_VI_USE_SIGNALS=y +CONFIG_FEATURE_VI_DOT_CMD=y +CONFIG_FEATURE_VI_READONLY=y +CONFIG_FEATURE_VI_SETOPTS=y +CONFIG_FEATURE_VI_SET=y +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_OPTIMIZE_CURSOR=y + +# +# Finding Utilities +# +CONFIG_FIND=y +CONFIG_FEATURE_FIND_MTIME=y +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +CONFIG_FEATURE_FIND_NEWER=y +CONFIG_FEATURE_FIND_INUM=y +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION=y +CONFIG_FEATURE_XARGS_SUPPORT_QUOTES=y +CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT=y +CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM=y + +# +# Init Utilities +# +# CONFIG_INIT is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +# CONFIG_REBOOT is not set +# CONFIG_MESG is not set + +# +# Login/Password Management Utilities +# +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_ADDGROUP is not set +# CONFIG_DELGROUP is not set +# CONFIG_ADDUSER is not set +# CONFIG_DELUSER is not set +# CONFIG_GETTY is not set +CONFIG_FEATURE_U_W_TMP=y +# CONFIG_LOGIN is not set +# CONFIG_PASSWD is not set +# CONFIG_SU is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +CONFIG_CROND=y +# CONFIG_FEATURE_CROND_CALL_SENDMAIL is not set +CONFIG_CRONTAB=y +CONFIG_DC=y +# CONFIG_DEVFSD is not set +# CONFIG_LAST is not set +# CONFIG_HDPARM is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_MT is not set +# CONFIG_RX is not set +CONFIG_STRINGS=y +CONFIG_TIME=y +CONFIG_WATCHDOG=y + +# +# Linux Module Utilities +# +# CONFIG_INSMOD is not set +# CONFIG_LSMOD is not set +# CONFIG_MODPROBE is not set +# CONFIG_RMMOD is not set + +# +# Networking Utilities +# +CONFIG_FEATURE_IPV6=y +CONFIG_ARPING=y +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +CONFIG_HOSTNAME=y +CONFIG_HTTPD=y +# CONFIG_FEATURE_HTTPD_USAGE_FROM_INETD_ONLY is not set +CONFIG_FEATURE_HTTPD_BASIC_AUTH=y +CONFIG_FEATURE_HTTPD_AUTH_MD5=y +CONFIG_FEATURE_HTTPD_RELOAD_CONFIG_SIGHUP=y +CONFIG_FEATURE_HTTPD_SETUID=y +CONFIG_FEATURE_HTTPD_CONFIG_WITH_MIME_TYPES=y +CONFIG_FEATURE_HTTPD_CGI=y +CONFIG_FEATURE_HTTPD_SET_REMOTE_PORT_TO_ENV=y +CONFIG_FEATURE_HTTPD_ENCODE_URL_STR=y +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ=y +CONFIG_FEATURE_IFCONFIG_HW=y +CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS=y +CONFIG_IFUPDOWN=y +# CONFIG_FEATURE_IFUPDOWN_IP is not set +CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +CONFIG_FEATURE_IFUPDOWN_IPV6=y +# CONFIG_FEATURE_IFUPDOWN_IPX is not set +CONFIG_FEATURE_IFUPDOWN_MAPPING=y +CONFIG_INETD=y +CONFIG_FEATURE_INETD_SUPPORT_BILTIN_ECHO=y +CONFIG_FEATURE_INETD_SUPPORT_BILTIN_DISCARD=y +CONFIG_FEATURE_INETD_SUPPORT_BILTIN_TIME=y +CONFIG_FEATURE_INETD_SUPPORT_BILTIN_DAYTIME=y +CONFIG_FEATURE_INETD_SUPPORT_BILTIN_CHARGEN=y +# CONFIG_IP is not set +CONFIG_IPCALC=y +CONFIG_FEATURE_IPCALC_FANCY=y +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +CONFIG_NAMEIF=y +CONFIG_NC=y +CONFIG_NETSTAT=y +CONFIG_NSLOOKUP=y +CONFIG_PING=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING6=y +CONFIG_ROUTE=y +CONFIG_TELNET=y +CONFIG_FEATURE_TELNET_TTYPE=y +CONFIG_FEATURE_TELNET_AUTOLOGIN=y +# CONFIG_TELNETD is not set +CONFIG_TFTP=y +CONFIG_FEATURE_TFTP_GET=y +CONFIG_FEATURE_TFTP_PUT=y +CONFIG_FEATURE_TFTP_BLOCKSIZE=y +# CONFIG_FEATURE_TFTP_DEBUG is not set +CONFIG_TRACEROUTE=y +CONFIG_FEATURE_TRACEROUTE_VERBOSE=y +CONFIG_VCONFIG=y +CONFIG_WGET=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_IP6_LITERAL=y + +# +# udhcp Server/Client +# +CONFIG_UDHCPD=y +CONFIG_UDHCPC=y +CONFIG_DUMPLEASES=y +CONFIG_FEATURE_UDHCP_SYSLOG=y +# CONFIG_FEATURE_UDHCP_DEBUG is not set + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_KILL=y +CONFIG_KILLALL=y +CONFIG_PIDOF=y +CONFIG_PS=y +CONFIG_RENICE=y +CONFIG_TOP=y +FEATURE_CPU_USAGE_PERCENTAGE=y +CONFIG_UPTIME=y +CONFIG_SYSCTL=y + +# +# Another Bourne-like Shell +# +# CONFIG_FEATURE_SH_IS_ASH is not set +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_LASH is not set +# CONFIG_FEATURE_SH_IS_MSH is not set +CONFIG_FEATURE_SH_IS_NONE=y +# CONFIG_ASH is not set +# CONFIG_HUSH is not set +# CONFIG_LASH is not set +# CONFIG_MSH is not set + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +CONFIG_FEATURE_ROTATE_LOGFILE=y +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_LOGREAD=y +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +CONFIG_KLOGD=y +CONFIG_LOGGER=y + +# +# Linux System Utilities +# +CONFIG_DMESG=y +CONFIG_FBSET=y +CONFIG_FEATURE_FBSET_FANCY=y +CONFIG_FEATURE_FBSET_READMODE=y +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +CONFIG_FDISK=y +FDISK_SUPPORT_LARGE_DISKS=y +CONFIG_FEATURE_FDISK_WRITABLE=y +# CONFIG_FEATURE_AIX_LABEL is not set +# CONFIG_FEATURE_SGI_LABEL is not set +# CONFIG_FEATURE_SUN_LABEL is not set +# CONFIG_FEATURE_OSF_LABEL is not set +# CONFIG_FEATURE_FDISK_ADVANCED is not set +CONFIG_FREERAMDISK=y +# CONFIG_FSCK_MINIX is not set +# CONFIG_MKFS_MINIX is not set +# CONFIG_GETOPT is not set +CONFIG_HEXDUMP=y +# CONFIG_HWCLOCK is not set +CONFIG_LOSETUP=y +CONFIG_MKSWAP=y +# CONFIG_MORE is not set +CONFIG_PIVOT_ROOT=y +# CONFIG_RDATE is not set +CONFIG_SWAPONOFF=y +CONFIG_MOUNT=y +CONFIG_NFSMOUNT=y +CONFIG_UMOUNT=y +CONFIG_FEATURE_MOUNT_FORCE=y + +# +# Common options for mount/umount +# +CONFIG_FEATURE_MOUNT_LOOP=y +# CONFIG_FEATURE_MTAB_SUPPORT is not set + +# +# Debugging Options +# +# CONFIG_DEBUG is not set diff --git a/meta/packages/busybox/busybox-1.01/openmn/defconfig b/meta/packages/busybox/busybox-1.01/openmn/defconfig new file mode 100644 index 000000000..f98af9185 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/openmn/defconfig @@ -0,0 +1,475 @@ +# +# Automatically generated make config: don't edit +# +HAVE_DOT_CONFIG=y + +# +# General Configuration +# +CONFIG_FEATURE_BUFFERS_USE_MALLOC=y +# CONFIG_FEATURE_BUFFERS_GO_ON_STACK is not set +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +# CONFIG_FEATURE_VERBOSE_USAGE is not set +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_LOCALE_SUPPORT is not set +CONFIG_FEATURE_DEVFS=y +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +# CONFIG_FEATURE_SUID is not set +# CONFIG_FEATURE_SUID_CONFIG is not set +# CONFIG_FEATURE_SUID_CONFIG_QUIET is not set +# CONFIG_SELINUX is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +# CONFIG_LFS is not set +# USING_CROSS_COMPILER is not set +EXTRA_CFLAGS_OPTIONS="" + +# +# Installation Options +# +# CONFIG_INSTALL_NO_USR is not set +PREFIX="./_install" + +# +# Archival Utilities +# +CONFIG_AR=y +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +CONFIG_BUNZIP2=y +CONFIG_CPIO=y +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +CONFIG_GUNZIP=y +# CONFIG_FEATURE_GUNZIP_UNCOMPRESS is not set +CONFIG_GZIP=y +# CONFIG_RPM2CPIO is not set +# CONFIG_RPM is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_BZIP2=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_GZIP=y +# CONFIG_FEATURE_TAR_COMPRESS is not set +CONFIG_FEATURE_TAR_OLDGNU_COMPATABILITY=y +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_UNCOMPRESS is not set +CONFIG_UNZIP=y + +# +# Common options for cpio and tar +# +# CONFIG_FEATURE_UNARCHIVE_TAPE is not set + +# +# Coreutils +# +CONFIG_BASENAME=y +# CONFIG_CAL is not set +CONFIG_CAT=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_CHROOT=y +CONFIG_CMP=y +CONFIG_CP=y +CONFIG_CUT=y +CONFIG_DATE=y + +# +# date (forced enabled for use with watch) +# +CONFIG_FEATURE_DATE_ISOFMT=y +CONFIG_DD=y +CONFIG_DF=y +CONFIG_DIRNAME=y +# CONFIG_DOS2UNIX is not set +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFALT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPR=y +CONFIG_FALSE=y +# CONFIG_FOLD is not set +CONFIG_HEAD=y +# CONFIG_FEATURE_FANCY_HEAD is not set +# CONFIG_HOSTID is not set +CONFIG_ID=y +# CONFIG_INSTALL is not set +# CONFIG_LENGTH is not set +CONFIG_LN=y +CONFIG_LOGNAME=y +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +CONFIG_FEATURE_LS_RECURSIVE=y +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +# CONFIG_FEATURE_LS_COLOR is not set +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MV=y +CONFIG_OD=y +CONFIG_PRINTF=y +CONFIG_PWD=y +# CONFIG_REALPATH is not set +CONFIG_RM=y +CONFIG_RMDIR=y +CONFIG_SEQ=y +# CONFIG_SHA1SUM is not set +CONFIG_SLEEP=y +# CONFIG_FEATURE_FANCY_SLEEP is not set +CONFIG_SORT=y +CONFIG_STTY=y +CONFIG_SYNC=y +CONFIG_TAIL=y +# CONFIG_FEATURE_FANCY_TAIL is not set +CONFIG_TEE=y +# CONFIG_FEATURE_TEE_USE_BLOCK_IO is not set +CONFIG_TEST=y + +# +# test (forced enabled for use with shell) +# +# CONFIG_FEATURE_TEST_64 is not set +CONFIG_TOUCH=y +CONFIG_TR=y +CONFIG_TRUE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNIQ=y +CONFIG_USLEEP=y +# CONFIG_UUDECODE is not set +# CONFIG_UUENCODE is not set +CONFIG_WATCH=y +CONFIG_WC=y +CONFIG_WHO=y +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options for cp and mv +# +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set + +# +# Common options for ls and more +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum +# +# CONFIG_FEATURE_MD5_SHA1_SUM_CHECK is not set + +# +# Console Utilities +# +CONFIG_CHVT=y +CONFIG_CLEAR=y +CONFIG_DEALLOCVT=y +CONFIG_DUMPKMAP=y +CONFIG_GETKEY=y +CONFIG_LOADFONT=y +CONFIG_LOADKMAP=y +CONFIG_OPENVT=y +CONFIG_RESET=y +CONFIG_SETKEYCODES=y + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +# CONFIG_PIPE_PROGRESS is not set +CONFIG_READLINK=y +CONFIG_FEATURE_READLINK_FOLLOW=y +CONFIG_RUN_PARTS=y +CONFIG_START_STOP_DAEMON=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_MATH=y +# CONFIG_PATCH is not set +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +CONFIG_FEATURE_VI_USE_SIGNALS=y +# CONFIG_FEATURE_VI_DOT_CMD is not set +# CONFIG_FEATURE_VI_READONLY is not set +# CONFIG_FEATURE_VI_SETOPTS is not set +# CONFIG_FEATURE_VI_SET is not set +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_OPTIMIZE_CURSOR=y + +# +# Finding Utilities +# +CONFIG_FIND=y +CONFIG_FEATURE_FIND_MTIME=y +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +CONFIG_FEATURE_FIND_NEWER=y +# CONFIG_FEATURE_FIND_INUM is not set +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +# CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION is not set +# CONFIG_FEATURE_XARGS_SUPPORT_QUOTES is not set +# CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT is not set +CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM=y + +# +# Init Utilities +# +# CONFIG_INIT is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +# CONFIG_REBOOT is not set +# CONFIG_MESG is not set + +# +# Login/Password Management Utilities +# +# CONFIG_USE_BB_PWD_GRP is not set +CONFIG_ADDGROUP=y +CONFIG_DELGROUP=y +CONFIG_ADDUSER=y +CONFIG_DELUSER=y +CONFIG_GETTY=y +CONFIG_FEATURE_U_W_TMP=y +CONFIG_LOGIN=y +# CONFIG_FEATURE_SECURETTY is not set +CONFIG_PASSWD=y +CONFIG_SU=y +CONFIG_SULOGIN=y +CONFIG_VLOCK=y + +# +# Common options for adduser, deluser, login, su +# +CONFIG_FEATURE_SHADOWPASSWDS=y + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +# CONFIG_CROND is not set +# CONFIG_CRONTAB is not set +CONFIG_DC=y +# CONFIG_DEVFSD is not set +# CONFIG_LAST is not set +# CONFIG_HDPARM is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_MT is not set +# CONFIG_RX is not set +CONFIG_STRINGS=y +CONFIG_TIME=y +# CONFIG_WATCHDOG is not set + +# +# Linux Module Utilities +# +CONFIG_INSMOD=y +CONFIG_FEATURE_2_4_MODULES=y +CONFIG_FEATURE_2_6_MODULES=y +# CONFIG_FEATURE_INSMOD_VERSION_CHECKING is not set +CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS=y +# CONFIG_FEATURE_INSMOD_LOADINKMEM is not set +CONFIG_FEATURE_INSMOD_LOAD_MAP=y +CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL=y +CONFIG_LSMOD=y +CONFIG_MODPROBE=y +CONFIG_RMMOD=y +# CONFIG_FEATURE_CHECK_TAINTED_MODULE is not set + +# +# Networking Utilities +# +# CONFIG_FEATURE_IPV6 is not set +CONFIG_ARPING=y +# CONFIG_FTPGET is not set +CONFIG_FTPPUT=y +CONFIG_HOSTNAME=y +# CONFIG_HTTPD is not set +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +CONFIG_FEATURE_IFCONFIG_HW=y +# CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS is not set +CONFIG_IFUPDOWN=y +# CONFIG_FEATURE_IFUPDOWN_IP is not set +CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +# CONFIG_FEATURE_IFUPDOWN_IPV6 is not set +# CONFIG_FEATURE_IFUPDOWN_IPX is not set +# CONFIG_FEATURE_IFUPDOWN_MAPPING is not set +# CONFIG_INETD is not set +CONFIG_IP=y +CONFIG_FEATURE_IP_ADDRESS=y +CONFIG_FEATURE_IP_LINK=y +CONFIG_FEATURE_IP_ROUTE=y +# CONFIG_FEATURE_IP_TUNNEL is not set +# CONFIG_IPCALC is not set +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_NAMEIF is not set +CONFIG_NC=y +CONFIG_NETSTAT=y +CONFIG_NSLOOKUP=y +CONFIG_PING=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_ROUTE=y +CONFIG_TELNET=y +# CONFIG_FEATURE_TELNET_TTYPE is not set +# CONFIG_FEATURE_TELNET_AUTOLOGIN is not set +# CONFIG_TELNETD is not set +# CONFIG_TFTP is not set +CONFIG_TRACEROUTE=y +# CONFIG_FEATURE_TRACEROUTE_VERBOSE is not set +# CONFIG_VCONFIG is not set +CONFIG_WGET=y +# CONFIG_FEATURE_WGET_STATUSBAR is not set +CONFIG_FEATURE_WGET_AUTHENTICATION=y +# CONFIG_FEATURE_WGET_IP6_LITERAL is not set + +# +# udhcp Server/Client +# +# CONFIG_UDHCPD is not set +CONFIG_UDHCPC=y +CONFIG_FEATURE_UDHCP_SYSLOG=y +# CONFIG_FEATURE_UDHCP_DEBUG is not set + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_KILL=y +CONFIG_KILLALL=y +# CONFIG_PIDOF is not set +CONFIG_PS=y +CONFIG_RENICE=y +CONFIG_TOP=y +FEATURE_CPU_USAGE_PERCENTAGE=y +CONFIG_UPTIME=y +# CONFIG_SYSCTL is not set + +# +# Another Bourne-like Shell +# +CONFIG_FEATURE_SH_IS_ASH=y +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_LASH is not set +# CONFIG_FEATURE_SH_IS_MSH is not set +# CONFIG_FEATURE_SH_IS_NONE is not set +CONFIG_ASH=y + +# +# Ash Shell Options +# +CONFIG_ASH_JOB_CONTROL=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_MATH_SUPPORT=y +# CONFIG_ASH_MATH_SUPPORT_64 is not set +CONFIG_ASH_GETOPTS=y +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_MAIL is not set +# CONFIG_ASH_OPTIMIZE_FOR_SIZE is not set +# CONFIG_ASH_RANDOM_SUPPORT is not set +# CONFIG_HUSH is not set +# CONFIG_LASH is not set +# CONFIG_MSH is not set + +# +# Bourne Shell Options +# +CONFIG_FEATURE_SH_EXTRA_QUIET=y +# CONFIG_FEATURE_SH_STANDALONE_SHELL is not set +CONFIG_FEATURE_COMMAND_EDITING=y +CONFIG_FEATURE_COMMAND_HISTORY=31 +# CONFIG_FEATURE_COMMAND_SAVEHISTORY is not set +CONFIG_FEATURE_COMMAND_TAB_COMPLETION=y +# CONFIG_FEATURE_COMMAND_USERNAME_COMPLETION is not set +CONFIG_FEATURE_SH_FANCY_PROMPT=y + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +# CONFIG_FEATURE_ROTATE_LOGFILE is not set +# CONFIG_FEATURE_REMOTE_LOG is not set +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_LOGREAD=y +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +CONFIG_KLOGD=y +CONFIG_LOGGER=y + +# +# Linux System Utilities +# +CONFIG_DMESG=y +# CONFIG_FBSET is not set +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +CONFIG_FDISK=y +# FDISK_SUPPORT_LARGE_DISKS is not set +CONFIG_FEATURE_FDISK_WRITABLE=y +# CONFIG_FEATURE_AIX_LABEL is not set +# CONFIG_FEATURE_SGI_LABEL is not set +# CONFIG_FEATURE_SUN_LABEL is not set +# CONFIG_FEATURE_OSF_LABEL is not set +# CONFIG_FEATURE_FDISK_ADVANCED is not set +# CONFIG_FREERAMDISK is not set +# CONFIG_FSCK_MINIX is not set +# CONFIG_MKFS_MINIX is not set +CONFIG_GETOPT=y +CONFIG_HEXDUMP=y +CONFIG_HWCLOCK=y +CONFIG_FEATURE_HWCLOCK_LONGOPTIONS=y +CONFIG_LOSETUP=y +CONFIG_MKSWAP=y +CONFIG_MORE=y +CONFIG_FEATURE_USE_TERMIOS=y +CONFIG_PIVOT_ROOT=y +# CONFIG_RDATE is not set +# CONFIG_SWAPONOFF is not set +CONFIG_MOUNT=y +CONFIG_NFSMOUNT=y +CONFIG_UMOUNT=y +CONFIG_FEATURE_MOUNT_FORCE=y + +# +# Common options for mount/umount +# +CONFIG_FEATURE_MOUNT_LOOP=y +# CONFIG_FEATURE_MTAB_SUPPORT is not set + +# +# Debugging Options +# +# CONFIG_DEBUG is not set diff --git a/meta/packages/busybox/busybox-1.01/openzaurus/defconfig b/meta/packages/busybox/busybox-1.01/openzaurus/defconfig new file mode 100644 index 000000000..34a5804a4 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/openzaurus/defconfig @@ -0,0 +1,475 @@ +# +# Automatically generated make config: don't edit +# +HAVE_DOT_CONFIG=y + +# +# General Configuration +# +# CONFIG_FEATURE_BUFFERS_USE_MALLOC is not set +CONFIG_FEATURE_BUFFERS_GO_ON_STACK=y +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +# CONFIG_FEATURE_VERBOSE_USAGE is not set +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_LOCALE_SUPPORT is not set +# CONFIG_FEATURE_DEVFS is not set +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +# CONFIG_FEATURE_SUID is not set +# CONFIG_SELINUX is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +CONFIG_LFS=y +# USING_CROSS_COMPILER is not set +EXTRA_CFLAGS_OPTIONS="" + +# +# Installation Options +# +# CONFIG_INSTALL_NO_USR is not set +PREFIX="./_install" + +# +# Archival Utilities +# +CONFIG_AR=y +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +CONFIG_BUNZIP2=y +CONFIG_CPIO=y +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +CONFIG_GUNZIP=y +# CONFIG_FEATURE_GUNZIP_UNCOMPRESS is not set +CONFIG_GZIP=y +# CONFIG_RPM2CPIO is not set +# CONFIG_RPM is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_BZIP2=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_GZIP=y +# CONFIG_FEATURE_TAR_COMPRESS is not set +CONFIG_FEATURE_TAR_OLDGNU_COMPATABILITY=y +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_UNCOMPRESS is not set +# CONFIG_UNZIP is not set + +# +# Common options for cpio and tar +# +# CONFIG_FEATURE_UNARCHIVE_TAPE is not set + +# +# Coreutils +# +CONFIG_BASENAME=y +# CONFIG_CAL is not set +CONFIG_CAT=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_CHROOT=y +# CONFIG_CMP is not set +CONFIG_CP=y +CONFIG_CUT=y +CONFIG_DATE=y + +# +# date (forced enabled for use with watch) +# +# CONFIG_FEATURE_DATE_ISOFMT is not set +CONFIG_DD=y +CONFIG_DF=y +CONFIG_DIRNAME=y +# CONFIG_DOS2UNIX is not set +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFALT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPR=y +CONFIG_FALSE=y +# CONFIG_FOLD is not set +CONFIG_HEAD=y +# CONFIG_FEATURE_FANCY_HEAD is not set +# CONFIG_HOSTID is not set +CONFIG_ID=y +# CONFIG_INSTALL is not set +# CONFIG_LENGTH is not set +CONFIG_LN=y +CONFIG_LOGNAME=y +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +# CONFIG_FEATURE_LS_RECURSIVE is not set +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MV=y +CONFIG_OD=y +CONFIG_PRINTF=y +CONFIG_PWD=y +# CONFIG_REALPATH is not set +CONFIG_RM=y +CONFIG_RMDIR=y +CONFIG_SEQ=y +# CONFIG_SHA1SUM is not set +CONFIG_SLEEP=y +# CONFIG_FEATURE_FANCY_SLEEP is not set +CONFIG_SORT=y +CONFIG_STTY=y +CONFIG_SYNC=y +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +# CONFIG_FEATURE_TEE_USE_BLOCK_IO is not set +CONFIG_TEST=y + +# +# test (forced enabled for use with shell) +# +# CONFIG_FEATURE_TEST_64 is not set +CONFIG_TOUCH=y +CONFIG_TR=y +CONFIG_TRUE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNIQ=y +# CONFIG_USLEEP is not set +# CONFIG_UUDECODE is not set +# CONFIG_UUENCODE is not set +CONFIG_WATCH=y +CONFIG_WC=y +CONFIG_WHO=y +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options for cp and mv +# +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set + +# +# Common options for ls and more +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum +# +# CONFIG_FEATURE_MD5_SHA1_SUM_CHECK is not set + +# +# Console Utilities +# +CONFIG_CHVT=y +CONFIG_CLEAR=y +CONFIG_DEALLOCVT=y +# CONFIG_DUMPKMAP is not set +CONFIG_GETKEY=y +# CONFIG_LOADFONT is not set +# CONFIG_LOADKMAP is not set +CONFIG_OPENVT=y +CONFIG_RESET=y +# CONFIG_SETKEYCODES is not set + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +# CONFIG_PIPE_PROGRESS is not set +CONFIG_READLINK=y +CONFIG_FEATURE_READLINK_FOLLOW=y +CONFIG_RUN_PARTS=y +CONFIG_START_STOP_DAEMON=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_MATH=y +# CONFIG_PATCH is not set +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +CONFIG_FEATURE_VI_USE_SIGNALS=y +# CONFIG_FEATURE_VI_DOT_CMD is not set +# CONFIG_FEATURE_VI_READONLY is not set +# CONFIG_FEATURE_VI_SETOPTS is not set +# CONFIG_FEATURE_VI_SET is not set +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_OPTIMIZE_CURSOR=y + +# +# Finding Utilities +# +CONFIG_FIND=y +CONFIG_FEATURE_FIND_MTIME=y +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +CONFIG_FEATURE_FIND_NEWER=y +# CONFIG_FEATURE_FIND_INUM is not set +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +# CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION is not set +# CONFIG_FEATURE_XARGS_SUPPORT_QUOTES is not set +# CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT is not set +# CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM is not set + +# +# Init Utilities +# +# CONFIG_INIT is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +# CONFIG_REBOOT is not set +# CONFIG_MESG is not set + +# +# Login/Password Management Utilities +# +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_ADDGROUP is not set +# CONFIG_DELGROUP is not set +# CONFIG_ADDUSER is not set +# CONFIG_DELUSER is not set +# CONFIG_GETTY is not set +CONFIG_FEATURE_U_W_TMP=y +# CONFIG_LOGIN is not set +# CONFIG_PASSWD is not set +# CONFIG_SU is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +# CONFIG_CROND is not set +# CONFIG_CRONTAB is not set +CONFIG_DC=y +# CONFIG_DEVFSD is not set +# CONFIG_LAST is not set +# CONFIG_HDPARM is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_MT is not set +# CONFIG_RX is not set +CONFIG_STRINGS=y +# CONFIG_TIME is not set +# CONFIG_WATCHDOG is not set + +# +# Linux Module Utilities +# +CONFIG_INSMOD=y +CONFIG_FEATURE_2_4_MODULES=y +CONFIG_FEATURE_2_6_MODULES=y +# CONFIG_FEATURE_INSMOD_VERSION_CHECKING is not set +CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS=y +# CONFIG_FEATURE_INSMOD_LOADINKMEM is not set +CONFIG_FEATURE_INSMOD_LOAD_MAP=y +CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL=y +CONFIG_LSMOD=y +CONFIG_MODPROBE=y +CONFIG_RMMOD=y +CONFIG_FEATURE_CHECK_TAINTED_MODULE=y + +# +# Networking Utilities +# +CONFIG_FEATURE_IPV6=y +# CONFIG_ARPING is not set +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +CONFIG_HOSTNAME=y +# CONFIG_HTTPD is not set +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +CONFIG_FEATURE_IFCONFIG_HW=y +# CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS is not set +CONFIG_IFUPDOWN=y +# CONFIG_FEATURE_IFUPDOWN_IP is not set +CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +CONFIG_FEATURE_IFUPDOWN_IPV6=y +# CONFIG_FEATURE_IFUPDOWN_IPX is not set +CONFIG_FEATURE_IFUPDOWN_MAPPING=y +# CONFIG_INETD is not set +CONFIG_IP=y +CONFIG_FEATURE_IP_ADDRESS=y +CONFIG_FEATURE_IP_LINK=y +CONFIG_FEATURE_IP_ROUTE=y +CONFIG_FEATURE_IP_TUNNEL=y +# CONFIG_IPCALC is not set +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_NAMEIF is not set +CONFIG_NC=y +CONFIG_NETSTAT=y +CONFIG_NSLOOKUP=y +CONFIG_PING=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING6=y +CONFIG_ROUTE=y +CONFIG_TELNET=y +# CONFIG_FEATURE_TELNET_TTYPE is not set +CONFIG_FEATURE_TELNET_AUTOLOGIN=y +# CONFIG_TELNETD is not set +CONFIG_TFTP=y +CONFIG_FEATURE_TFTP_GET=y +CONFIG_FEATURE_TFTP_PUT=y +# CONFIG_FEATURE_TFTP_BLOCKSIZE is not set +# CONFIG_FEATURE_TFTP_DEBUG is not set +CONFIG_TRACEROUTE=y +# CONFIG_FEATURE_TRACEROUTE_VERBOSE is not set +# CONFIG_VCONFIG is not set +CONFIG_WGET=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_IP6_LITERAL=y + +# +# udhcp Server/Client +# +# CONFIG_UDHCPD is not set +CONFIG_UDHCPC=y +CONFIG_FEATURE_UDHCP_SYSLOG=y +# CONFIG_FEATURE_UDHCP_DEBUG is not set + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_KILL=y +CONFIG_KILLALL=y +# CONFIG_PIDOF is not set +CONFIG_PS=y +CONFIG_RENICE=y +CONFIG_TOP=y +FEATURE_CPU_USAGE_PERCENTAGE=y +CONFIG_UPTIME=y +# CONFIG_SYSCTL is not set + +# +# Another Bourne-like Shell +# +CONFIG_FEATURE_SH_IS_ASH=y +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_LASH is not set +# CONFIG_FEATURE_SH_IS_MSH is not set +# CONFIG_FEATURE_SH_IS_NONE is not set +CONFIG_ASH=y + +# +# Ash Shell Options +# +CONFIG_ASH_JOB_CONTROL=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_MATH_SUPPORT=y +# CONFIG_ASH_MATH_SUPPORT_64 is not set +CONFIG_ASH_GETOPTS=y +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_MAIL is not set +CONFIG_ASH_OPTIMIZE_FOR_SIZE=y +# CONFIG_ASH_RANDOM_SUPPORT is not set +# CONFIG_HUSH is not set +# CONFIG_LASH is not set +# CONFIG_MSH is not set + +# +# Bourne Shell Options +# +CONFIG_FEATURE_SH_EXTRA_QUIET=y +# CONFIG_FEATURE_SH_STANDALONE_SHELL is not set +CONFIG_FEATURE_COMMAND_EDITING=y +CONFIG_FEATURE_COMMAND_HISTORY=63 +# CONFIG_FEATURE_COMMAND_SAVEHISTORY is not set +CONFIG_FEATURE_COMMAND_TAB_COMPLETION=y +# CONFIG_FEATURE_COMMAND_USERNAME_COMPLETION is not set +CONFIG_FEATURE_SH_FANCY_PROMPT=y + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +# CONFIG_FEATURE_ROTATE_LOGFILE is not set +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_LOGREAD=y +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +CONFIG_KLOGD=y +CONFIG_LOGGER=y + +# +# Linux System Utilities +# +CONFIG_DMESG=y +CONFIG_FBSET=y +CONFIG_FEATURE_FBSET_FANCY=y +# CONFIG_FEATURE_FBSET_READMODE is not set +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +CONFIG_FDISK=y +FDISK_SUPPORT_LARGE_DISKS=y +CONFIG_FEATURE_FDISK_WRITABLE=y +# CONFIG_FEATURE_AIX_LABEL is not set +# CONFIG_FEATURE_SGI_LABEL is not set +# CONFIG_FEATURE_SUN_LABEL is not set +# CONFIG_FEATURE_OSF_LABEL is not set +# CONFIG_FEATURE_FDISK_ADVANCED is not set +# CONFIG_FREERAMDISK is not set +# CONFIG_FSCK_MINIX is not set +# CONFIG_MKFS_MINIX is not set +# CONFIG_GETOPT is not set +CONFIG_HEXDUMP=y +CONFIG_HWCLOCK=y +CONFIG_FEATURE_HWCLOCK_LONGOPTIONS=y +CONFIG_LOSETUP=y +CONFIG_MKSWAP=y +CONFIG_MORE=y +CONFIG_FEATURE_USE_TERMIOS=y +CONFIG_PIVOT_ROOT=y +# CONFIG_RDATE is not set +CONFIG_SWAPONOFF=y +CONFIG_MOUNT=y +CONFIG_NFSMOUNT=y +CONFIG_UMOUNT=y +CONFIG_FEATURE_MOUNT_FORCE=y + +# +# Common options for mount/umount +# +CONFIG_FEATURE_MOUNT_LOOP=y +# CONFIG_FEATURE_MTAB_SUPPORT is not set + +# +# Debugging Options +# +# CONFIG_DEBUG is not set diff --git a/meta/packages/busybox/busybox-1.01/readlink.patch b/meta/packages/busybox/busybox-1.01/readlink.patch new file mode 100644 index 000000000..0c5431085 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/readlink.patch @@ -0,0 +1,85 @@ +diff -p -u -r1.7 Config.in +--- busybox-1.00/debianutils/Config.in 15 Mar 2004 08:28:24 -0000 1.7 ++++ busybox-1.00-patched/debianutils/Config.in 16 Nov 2004 11:46:41 -0000 +@@ -24,6 +24,13 @@ config CONFIG_READLINK + This program reads a symbolic link and returns the name + of the file it points to + ++config CONFIG_FEATURE_READLINK_FOLLOW ++ bool " Enable canonicalization by following all symlinks (-f)" ++ default n ++ depends on CONFIG_READLINK ++ help ++ Enable the readlink option (-f). ++ + config CONFIG_RUN_PARTS + bool "run-parts" + default n +diff -p -u -r1.2 readlink.c +--- busybox-1.00/debianutils/readlink.c 19 Mar 2003 09:11:41 -0000 1.2 ++++ busybox-1.00-patched/debianutils/readlink.c 16 Nov 2004 11:46:41 -0000 +@@ -23,18 +23,38 @@ + #include + #include + #include ++#include + #include "busybox.h" + ++#ifdef CONFIG_FEATURE_READLINK_FOLLOW ++# define READLINK_FOLLOW "f" ++# define READLINK_FLAG_f (1 << 0) ++#else ++# define READLINK_FOLLOW "" ++#endif ++ ++static const char readlink_options[] = READLINK_FOLLOW; ++ + int readlink_main(int argc, char **argv) + { + char *buf = NULL; ++ unsigned long opt = bb_getopt_ulflags(argc, argv, readlink_options); ++#ifdef CONFIG_FEATURE_READLINK_FOLLOW ++ RESERVE_CONFIG_BUFFER(resolved_path, PATH_MAX); ++#endif + + /* no options, no getopt */ + +- if (argc != 2) ++ if (optind + 1 != argc) + bb_show_usage(); + +- buf = xreadlink(argv[1]); ++#ifdef CONFIG_FEATURE_READLINK_FOLLOW ++ if (opt & READLINK_FLAG_f) { ++ buf = realpath(argv[optind], resolved_path); ++ } else ++#endif ++ buf = xreadlink(argv[optind]); ++ + if (!buf) + return EXIT_FAILURE; + puts(buf); +diff -p -u -r1.222 usage.h +--- busybox-1.00/include/usage.h 14 Sep 2004 16:23:56 -0000 1.222 ++++ busybox-1.00-patched/include/usage.h 16 Nov 2004 11:46:42 -0000 +@@ -1985,10 +1985,18 @@ + "\t-s\tSet the system date and time (default).\n" \ + "\t-p\tPrint the date and time." + ++#ifdef CONFIG_FEATURE_READLINK_FOLLOW ++#define USAGE_READLINK_FOLLOW(a) a ++#else ++#define USAGE_READLINK_FOLLOW(a) ++#endif ++ + #define readlink_trivial_usage \ +- "" ++ USAGE_READLINK_FOLLOW("[-f] ") "FILE" + #define readlink_full_usage \ +- "Displays the value of a symbolic link." ++ "Displays the value of a symbolic link." \ ++ USAGE_READLINK_FOLLOW("\n\nOptions:\n" \ ++ "\t-f\tcanonicalize by following all symlinks") + + #define realpath_trivial_usage \ + "pathname ..." diff --git a/meta/packages/busybox/busybox-1.01/rmmod.patch b/meta/packages/busybox/busybox-1.01/rmmod.patch new file mode 100644 index 000000000..5a557ef35 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/rmmod.patch @@ -0,0 +1,44 @@ +Index: modutils/rmmod.c +=================================================================== +RCS file: /var/cvs/busybox/modutils/rmmod.c,v +retrieving revision 1.31 +diff -u -r1.31 rmmod.c +--- busybox/modutils/rmmod.c 20 Jul 2004 18:36:51 -0000 1.31 ++++ busybox/modutils/rmmod.c 10 Dec 2004 22:56:36 -0000 +@@ -28,6 +28,7 @@ + #include + #include + #include ++#include + #include "busybox.h" + + #ifdef CONFIG_FEATURE_2_6_MODULES +@@ -63,6 +64,16 @@ + void *buf; /* hold the module names which we ignore but must get */ + size_t bufsize = 0; + #endif ++#ifdef CONFIG_FEATURE_2_6_MODULES ++ int k_version = 0; ++ struct utsname myuname; ++ ++ if (uname(&myuname) == 0) { ++ if (myuname.release[0] == '2') { ++ k_version = myuname.release[2] - '0'; ++ } ++ } ++#endif + + /* Parse command line. */ + while ((n = getopt(argc, argv, "a")) != EOF) { +@@ -109,7 +120,10 @@ + for (n = optind; n < argc; n++) { + #ifdef CONFIG_FEATURE_2_6_MODULES + char module_name[strlen(argv[n]) + 1]; +- filename2modname(module_name, argv[n]); ++ if (k_version != 4) ++ filename2modname(module_name, argv[n]); ++ else ++ strcpy(module_name, argv[n]); + #else + #define module_name argv[n] + #endif diff --git a/meta/packages/busybox/busybox-1.01/slugos/defconfig b/meta/packages/busybox/busybox-1.01/slugos/defconfig new file mode 100644 index 000000000..55aa5f3b5 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/slugos/defconfig @@ -0,0 +1,444 @@ +# +# Automatically generated make config: don't edit +# +HAVE_DOT_CONFIG=y + +# +# General Configuration +# +# CONFIG_FEATURE_BUFFERS_USE_MALLOC is not set +CONFIG_FEATURE_BUFFERS_GO_ON_STACK=y +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +CONFIG_FEATURE_VERBOSE_USAGE=y +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_LOCALE_SUPPORT is not set +# CONFIG_FEATURE_DEVFS is not set +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +CONFIG_FEATURE_SUID=y +# CONFIG_FEATURE_SUID_CONFIG is not set +# CONFIG_SELINUX is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +CONFIG_LFS=y +# USING_CROSS_COMPILER is not set +EXTRA_CFLAGS_OPTIONS="" + +# +# Installation Options +# +# CONFIG_INSTALL_NO_USR is not set +PREFIX="./_install" + +# +# Archival Utilities +# +CONFIG_AR=y +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +CONFIG_BUNZIP2=y +# CONFIG_CPIO is not set +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +CONFIG_GUNZIP=y +# CONFIG_FEATURE_GUNZIP_UNCOMPRESS is not set +CONFIG_GZIP=y +# CONFIG_RPM2CPIO is not set +# CONFIG_RPM is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_BZIP2=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_GZIP=y +# CONFIG_FEATURE_TAR_COMPRESS is not set +CONFIG_FEATURE_TAR_OLDGNU_COMPATABILITY=y +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_UNCOMPRESS is not set +CONFIG_UNZIP=y + +# +# Common options for cpio and tar +# +# CONFIG_FEATURE_UNARCHIVE_TAPE is not set + +# +# Coreutils +# +CONFIG_BASENAME=y +# CONFIG_CAL is not set +CONFIG_CAT=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_CHROOT=y +# CONFIG_CMP is not set +CONFIG_CP=y +CONFIG_CUT=y +CONFIG_DATE=y + +# +# date (forced enabled for use with watch) +# +# CONFIG_FEATURE_DATE_ISOFMT is not set +CONFIG_DD=y +CONFIG_DF=y +CONFIG_DIRNAME=y +# CONFIG_DOS2UNIX is not set +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFALT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPR=y +CONFIG_FALSE=y +# CONFIG_FOLD is not set +CONFIG_HEAD=y +CONFIG_FEATURE_FANCY_HEAD=y +# CONFIG_HOSTID is not set +CONFIG_ID=y +# CONFIG_INSTALL is not set +# CONFIG_LENGTH is not set +CONFIG_LN=y +CONFIG_LOGNAME=y +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +CONFIG_FEATURE_LS_RECURSIVE=y +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MV=y +CONFIG_OD=y +CONFIG_PRINTF=y +CONFIG_PWD=y +# CONFIG_REALPATH is not set +CONFIG_RM=y +CONFIG_RMDIR=y +CONFIG_SEQ=y +# CONFIG_SHA1SUM is not set +CONFIG_SLEEP=y +# CONFIG_FEATURE_FANCY_SLEEP is not set +CONFIG_SORT=y +CONFIG_STTY=y +CONFIG_SYNC=y +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +# CONFIG_FEATURE_TEE_USE_BLOCK_IO is not set +CONFIG_TEST=y + +# +# test (forced enabled for use with shell) +# +# CONFIG_FEATURE_TEST_64 is not set +CONFIG_TOUCH=y +CONFIG_TR=y +CONFIG_TRUE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNIQ=y +# CONFIG_USLEEP is not set +# CONFIG_UUDECODE is not set +# CONFIG_UUENCODE is not set +CONFIG_WATCH=y +CONFIG_WC=y +CONFIG_WHO=y +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options for cp and mv +# +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set + +# +# Common options for ls and more +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum +# +# CONFIG_FEATURE_MD5_SHA1_SUM_CHECK is not set + +# +# Console Utilities +# +# CONFIG_CHVT is not set +CONFIG_CLEAR=y +# CONFIG_DEALLOCVT is not set +# CONFIG_DUMPKMAP is not set +CONFIG_GETKEY=y +# CONFIG_LOADFONT is not set +# CONFIG_LOADKMAP is not set +# CONFIG_OPENVT is not set +CONFIG_RESET=y +# CONFIG_SETKEYCODES is not set + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +# CONFIG_PIPE_PROGRESS is not set +CONFIG_READLINK=y +CONFIG_FEATURE_READLINK_FOLLOW=y +CONFIG_RUN_PARTS=y +CONFIG_START_STOP_DAEMON=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_MATH=y +# CONFIG_PATCH is not set +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +CONFIG_FEATURE_VI_USE_SIGNALS=y +CONFIG_FEATURE_VI_DOT_CMD=y +CONFIG_FEATURE_VI_READONLY=y +CONFIG_FEATURE_VI_SETOPTS=y +CONFIG_FEATURE_VI_SET=y +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_OPTIMIZE_CURSOR=y + +# +# Finding Utilities +# +# CONFIG_FIND is not set +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +# CONFIG_XARGS is not set + +# +# Init Utilities +# +# CONFIG_INIT is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +# CONFIG_REBOOT is not set +# CONFIG_MESG is not set + +# +# Login/Password Management Utilities +# +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_ADDGROUP is not set +# CONFIG_DELGROUP is not set +# CONFIG_ADDUSER is not set +# CONFIG_DELUSER is not set +# CONFIG_GETTY is not set +CONFIG_FEATURE_UTMP=y +# CONFIG_LOGIN is not set +# CONFIG_PASSWD is not set +# CONFIG_SU is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +# CONFIG_CROND is not set +# CONFIG_CRONTAB is not set +# CONFIG_DC is not set +# CONFIG_DEVFSD is not set +# CONFIG_LAST is not set +# CONFIG_HDPARM is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_MT is not set +# CONFIG_RX is not set +CONFIG_STRINGS=y +CONFIG_TIME=y +# CONFIG_WATCHDOG is not set + +# +# Linux Module Utilities +# +# CONFIG_INSMOD is not set +# CONFIG_LSMOD is not set +# CONFIG_MODPROBE is not set +# CONFIG_RMMOD is not set + +# +# Networking Utilities +# +CONFIG_FEATURE_IPV6=y +# CONFIG_ARPING is not set +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +CONFIG_HOSTNAME=y +# CONFIG_HTTPD is not set +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +CONFIG_FEATURE_IFCONFIG_HW=y +# CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS is not set +CONFIG_IFUPDOWN=y +# CONFIG_FEATURE_IFUPDOWN_IP is not set +CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +CONFIG_FEATURE_IFUPDOWN_IPV6=y +# CONFIG_FEATURE_IFUPDOWN_IPX is not set +# CONFIG_FEATURE_IFUPDOWN_MAPPING is not set +# CONFIG_INETD is not set +# CONFIG_IP is not set +# CONFIG_IPCALC is not set +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_NAMEIF is not set +CONFIG_NC=y +CONFIG_NETSTAT=y +CONFIG_NSLOOKUP=y +CONFIG_PING=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING6=y +CONFIG_ROUTE=y +CONFIG_TELNET=y +CONFIG_FEATURE_TELNET_TTYPE=y +CONFIG_FEATURE_TELNET_AUTOLOGIN=y +# CONFIG_TELNETD is not set +CONFIG_TFTP=y +CONFIG_FEATURE_TFTP_GET=y +CONFIG_FEATURE_TFTP_PUT=y +# CONFIG_FEATURE_TFTP_BLOCKSIZE is not set +# CONFIG_FEATURE_TFTP_DEBUG is not set +CONFIG_TRACEROUTE=y +# CONFIG_FEATURE_TRACEROUTE_VERBOSE is not set +# CONFIG_VCONFIG is not set +CONFIG_WGET=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_IP6_LITERAL=y + +# +# udhcp Server/Client +# +# CONFIG_UDHCPD is not set +CONFIG_UDHCPC=y +CONFIG_FEATURE_UDHCP_SYSLOG=y +# CONFIG_FEATURE_UDHCP_DEBUG is not set + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_KILL=y +CONFIG_KILLALL=y +CONFIG_PIDOF=y +CONFIG_PS=y +CONFIG_RENICE=y +CONFIG_TOP=y +FEATURE_CPU_USAGE_PERCENTAGE=y +CONFIG_UPTIME=y +CONFIG_SYSCTL=y + +# +# Another Bourne-like Shell +# +CONFIG_FEATURE_SH_IS_ASH=y +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_LASH is not set +# CONFIG_FEATURE_SH_IS_MSH is not set +# CONFIG_FEATURE_SH_IS_NONE is not set +CONFIG_ASH=y + +# +# Ash Shell Options +# +CONFIG_ASH_JOB_CONTROL=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_MATH_SUPPORT=y +# CONFIG_ASH_MATH_SUPPORT_64 is not set +CONFIG_ASH_GETOPTS=y +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_MAIL is not set +CONFIG_ASH_OPTIMIZE_FOR_SIZE=y +# CONFIG_ASH_RANDOM_SUPPORT is not set +# CONFIG_HUSH is not set +# CONFIG_LASH is not set +# CONFIG_MSH is not set + +# +# Bourne Shell Options +# +CONFIG_FEATURE_SH_EXTRA_QUIET=y +# CONFIG_FEATURE_SH_STANDALONE_SHELL is not set +CONFIG_FEATURE_COMMAND_EDITING=y +CONFIG_FEATURE_COMMAND_HISTORY=63 +# CONFIG_FEATURE_COMMAND_SAVEHISTORY is not set +CONFIG_FEATURE_COMMAND_TAB_COMPLETION=y +# CONFIG_FEATURE_COMMAND_USERNAME_COMPLETION is not set +CONFIG_FEATURE_SH_FANCY_PROMPT=y + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +# CONFIG_FEATURE_ROTATE_LOGFILE is not set +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_LOGREAD=y +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +CONFIG_KLOGD=y +CONFIG_LOGGER=y + +# +# Linux System Utilities +# +CONFIG_DMESG=y +# CONFIG_FBSET is not set +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +CONFIG_FDISK=y +FDISK_SUPPORT_LARGE_DISKS=y +CONFIG_FEATURE_FDISK_WRITABLE=y +# CONFIG_FEATURE_AIX_LABEL is not set +# CONFIG_FEATURE_SGI_LABEL is not set +# CONFIG_FEATURE_SUN_LABEL is not set +CONFIG_FEATURE_OSF_LABEL=y +# CONFIG_FEATURE_FDISK_ADVANCED is not set +# CONFIG_FREERAMDISK is not set +# CONFIG_FSCK_MINIX is not set +# CONFIG_MKFS_MINIX is not set +# CONFIG_GETOPT is not set +CONFIG_HEXDUMP=y +CONFIG_HWCLOCK=y +CONFIG_FEATURE_HWCLOCK_LONGOPTIONS=y +# CONFIG_LOSETUP is not set +CONFIG_MKSWAP=y +CONFIG_MORE=y +CONFIG_FEATURE_USE_TERMIOS=y +CONFIG_PIVOT_ROOT=y +# CONFIG_RDATE is not set +# CONFIG_SWAPONOFF is not set +# CONFIG_MOUNT is not set +# CONFIG_UMOUNT is not set + +# +# Debugging Options +# +# CONFIG_DEBUG is not set diff --git a/meta/packages/busybox/busybox-1.01/slugos/sysctl.conf b/meta/packages/busybox/busybox-1.01/slugos/sysctl.conf new file mode 100644 index 000000000..cfaa3c7f9 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/slugos/sysctl.conf @@ -0,0 +1,32 @@ +# +# /etc/sysctl.conf - Configuration file for setting system variables +# See sysctl.conf (5) for information. +# + +#kernel.domainname = example.com + +# This flag allows the machine to respond to broadcast pings. +# Very useful on embedded machines +net/ipv4/icmp_echo_ignore_broadcasts=0 + +# Uncomment the following to stop low-level messages on console +#kernel/printk = 4 4 1 7 + +##############################################################3 +# Functions previously found in netbase +# + +# Uncomment the next line to enable Spoof protection (reverse-path filter) +#net/ipv4/conf/all/rp_filter=1 + +# Uncomment the next line to enable TCP/IP SYN cookies +#net/ipv4/tcp_syncookies=1 + +# Uncomment the next line to enable packet forwarding for IPv4 +#net/ipv4/ip_forward=1 + +# Uncomment the next line to enable packet forwarding for IPv6 +#net/ipv6/ip_forward=1 + +# This sets the app to run on a hotplug event +kernel/hotplug=/sbin/udevsend diff --git a/meta/packages/busybox/busybox-1.01/slugos/udhcpscript.patch b/meta/packages/busybox/busybox-1.01/slugos/udhcpscript.patch new file mode 100644 index 000000000..277a22cdd --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/slugos/udhcpscript.patch @@ -0,0 +1,162 @@ +diff -rup busybox-1.01/.pc/udhcpscript.patch/examples/udhcp/simple.script busybox-1.01/examples/udhcp/simple.script +--- busybox-1.01/examples/udhcp/simple.script 1970-01-01 00:00:00.000000000 +0000 ++++ busybox-1.01/examples/udhcp/simple.script 1970-01-01 00:00:00.000000000 +0000 +@@ -1,40 +1,129 @@ + #!/bin/sh ++# slugos UDHCP client script ++# ++. /etc/default/functions ++ ++echodns(){ ++ local dns ++ if test $# -gt 0 ++ then ++ for dns in "$@" ++ do ++ echo "nameserver $dns #dhcp:$interface" ++ done ++ fi ++} + +-# udhcpc script edited by Tim Riker ++# Output the correct contents for resolv.conf based on ++# the current one and any new information ++mkresolv() { ++ local rmdomain ++ rmdomain= ++ # last search takes precedence, so a user ++ # specified search in resolv.conf is retained ++ test -n "$domain" && { ++ echo "search $domain #dhcp" ++ rmdomain='|search [^ ]* #dhcp' ++ } ++ # first nameserver takes precedence, use a user ++ # specified nameserver in preference then the ++ # new ones ++ egrep -v '^(nameserver [^ ]* #dhcp:.*'"$rmdomain"')$' "$1" ++ echodns $dns ++ egrep '^nameserver [^ ]* #dhcp:.*$' "$1" | egrep -v :"$interface"'$' ++} ++ ++# checksum of a file (or stdin if -) ++md5strm() { ++ md5sum $1 2>/dev/null | sed -n 's/^\([0-9A-Za-z]*\).*$/\1/p' ++} ++ ++# update resolv.conf for $interface using $domain and $dns ++updresolv() { ++ local md5old md5new resolv ++ md5old="$(md5strm /etc/resolv.conf)" ++ resolv="$(mkresolv /etc/resolv.conf)" ++ md5new="$(echo "$resolv" | md5strm -)" ++ test "$md5old" != "$md5new" && echo "$resolv" >/etc/resolv.conf ++} ++ ++unroute() { ++ # called to deconfig the interface ++ while route del default gw 0.0.0.0 dev $interface 2>/dev/null ++ do ++ : ++ done ++} ++ ++bind() { ++ local B N metric i olddomain resolv ++ B= ++ test -n "$broadcast" && B="broadcast $broadcast" ++ N= ++ test -n "$subnet" && N="netmask $subnet" ++ ifconfig "$interface" "$ip" $B $N up ++ ++ # If given router information delete the old information and ++ # enter new stuff, routers get metrics incremented by 1 ++ # between each (this is somewhat arbitrary) ++ if test -n "$router" ++ then ++ unroute ++ metric=0 ++ for i in $router ++ do ++ route add default gw "$i" dev "$interface" metric $((metric++)) ++ done ++ fi + +-[ -z "$1" ] && echo "Error: should be called from udhcpc" && exit 1 ++ olddomain= ++ test -r /etc/defaultdomain && olddomain="$(cat /etc/defaultdomain)" ++ if test -n "$domain" -a "$domain" != "$olddomain" ++ then ++ echo "$domain" >/etc/defaultdomain ++ # and update the kernel view too ++ echo "$domain" >/proc/sys/kernel/domainname ++ fi + +-RESOLV_CONF="/etc/resolv.conf" +-[ -n "$broadcast" ] && BROADCAST="broadcast $broadcast" +-[ -n "$subnet" ] && NETMASK="netmask $subnet" ++ updresolv ++} + + case "$1" in +- deconfig) +- /sbin/ifconfig $interface 0.0.0.0 +- ;; +- +- renew|bound) +- /sbin/ifconfig $interface $ip $BROADCAST $NETMASK +- +- if [ -n "$router" ] ; then +- echo "deleting routers" +- while route del default gw 0.0.0.0 dev $interface ; do +- : +- done +- +- metric=0 +- for i in $router ; do +- route add default gw $i dev $interface metric $((metric++)) +- done ++deconfig) ++ # Bring the interface up (without inet at this point) ++ # Remove the resolver information because deconfig is called ++ # on leasefail and we need to remove this interface at that ++ # point to ensure the machine remains visible on another ++ # interface! ++ domain= ++ dns= ++ unroute ++ updresolv ++ ifconfig "$interface" up;; ++ ++renew|bound) ++ bind;; ++ ++leasefail) ++ # Pull the values from the config data if (only only if) this ++ # is the config interface ++ if test "$interface" = "$(config iface)" ++ then ++ ip="$(config ip)" ++ if test -n "$ip" ++ then ++ router="$(config gateway)" ++ subnet="$(config netmask)" ++ broadcast="$(config broadcast)" ++ domain="$(config domain)" ++ dns="$(config dns)" ++ ++ bind + fi ++ fi;; + +- echo -n > $RESOLV_CONF +- [ -n "$domain" ] && echo search $domain >> $RESOLV_CONF +- for i in $dns ; do +- echo adding dns $i +- echo nameserver $i >> $RESOLV_CONF +- done +- ;; ++*) echo "udhcpc: $*: unknown command" >&2 ++ exit 1;; + esac + + exit 0 diff --git a/meta/packages/busybox/busybox-1.01/sparc/defconfig b/meta/packages/busybox/busybox-1.01/sparc/defconfig new file mode 100644 index 000000000..8b8cbfc83 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/sparc/defconfig @@ -0,0 +1,467 @@ +# +# Automatically generated make config: don't edit +# +HAVE_DOT_CONFIG=y + +# +# General Configuration +# +CONFIG_FEATURE_BUFFERS_USE_MALLOC=y +# CONFIG_FEATURE_BUFFERS_GO_ON_STACK is not set +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +# CONFIG_FEATURE_VERBOSE_USAGE is not set +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_LOCALE_SUPPORT is not set +CONFIG_FEATURE_DEVFS=y +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +# CONFIG_FEATURE_SUID is not set +# CONFIG_SELINUX is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +# CONFIG_LFS is not set +# USING_CROSS_COMPILER is not set +EXTRA_CFLAGS_OPTIONS="" + +# +# Installation Options +# +# CONFIG_INSTALL_NO_USR is not set +PREFIX="./_install" + +# +# Archival Utilities +# +CONFIG_AR=y +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +CONFIG_BUNZIP2=y +CONFIG_CPIO=y +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +CONFIG_GUNZIP=y +# CONFIG_FEATURE_GUNZIP_UNCOMPRESS is not set +CONFIG_GZIP=y +# CONFIG_RPM2CPIO is not set +# CONFIG_RPM is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_BZIP2=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_GZIP=y +# CONFIG_FEATURE_TAR_COMPRESS is not set +CONFIG_FEATURE_TAR_OLDGNU_COMPATABILITY=y +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_UNCOMPRESS is not set +CONFIG_UNZIP=y + +# +# Common options for cpio and tar +# +# CONFIG_FEATURE_UNARCHIVE_TAPE is not set + +# +# Coreutils +# +CONFIG_BASENAME=y +# CONFIG_CAL is not set +CONFIG_CAT=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_CHROOT=y +# CONFIG_CMP is not set +CONFIG_CP=y +CONFIG_CUT=y +CONFIG_DATE=y + +# +# date (forced enabled for use with watch) +# +# CONFIG_FEATURE_DATE_ISOFMT is not set +CONFIG_DD=y +CONFIG_DF=y +CONFIG_DIRNAME=y +# CONFIG_DOS2UNIX is not set +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFALT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPR=y +CONFIG_FALSE=y +# CONFIG_FOLD is not set +CONFIG_HEAD=y +# CONFIG_FEATURE_FANCY_HEAD is not set +# CONFIG_HOSTID is not set +CONFIG_ID=y +# CONFIG_INSTALL is not set +# CONFIG_LENGTH is not set +CONFIG_LN=y +CONFIG_LOGNAME=y +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +# CONFIG_FEATURE_LS_RECURSIVE is not set +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MV=y +CONFIG_OD=y +CONFIG_PRINTF=y +CONFIG_PWD=y +# CONFIG_REALPATH is not set +CONFIG_RM=y +CONFIG_RMDIR=y +CONFIG_SEQ=y +# CONFIG_SHA1SUM is not set +CONFIG_SLEEP=y +# CONFIG_FEATURE_FANCY_SLEEP is not set +CONFIG_SORT=y +CONFIG_STTY=y +CONFIG_SYNC=y +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +# CONFIG_FEATURE_TEE_USE_BLOCK_IO is not set +CONFIG_TEST=y + +# +# test (forced enabled for use with shell) +# +# CONFIG_FEATURE_TEST_64 is not set +CONFIG_TOUCH=y +CONFIG_TR=y +CONFIG_TRUE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNIQ=y +# CONFIG_USLEEP is not set +# CONFIG_UUDECODE is not set +# CONFIG_UUENCODE is not set +CONFIG_WATCH=y +CONFIG_WC=y +CONFIG_WHO=y +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options for cp and mv +# +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set + +# +# Common options for ls and more +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum +# +# CONFIG_FEATURE_MD5_SHA1_SUM_CHECK is not set + +# +# Console Utilities +# +CONFIG_CHVT=y +CONFIG_CLEAR=y +CONFIG_DEALLOCVT=y +CONFIG_DUMPKMAP=y +CONFIG_GETKEY=y +CONFIG_LOADFONT=y +CONFIG_LOADKMAP=y +CONFIG_OPENVT=y +CONFIG_RESET=y +# CONFIG_SETKEYCODES is not set + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +# CONFIG_PIPE_PROGRESS is not set +CONFIG_READLINK=y +CONFIG_RUN_PARTS=y +CONFIG_START_STOP_DAEMON=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_MATH=y +# CONFIG_PATCH is not set +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +CONFIG_FEATURE_VI_USE_SIGNALS=y +# CONFIG_FEATURE_VI_DOT_CMD is not set +# CONFIG_FEATURE_VI_READONLY is not set +# CONFIG_FEATURE_VI_SETOPTS is not set +# CONFIG_FEATURE_VI_SET is not set +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_OPTIMIZE_CURSOR=y + +# +# Finding Utilities +# +CONFIG_FIND=y +CONFIG_FEATURE_FIND_MTIME=y +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +CONFIG_FEATURE_FIND_NEWER=y +# CONFIG_FEATURE_FIND_INUM is not set +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +# CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION is not set +# CONFIG_FEATURE_XARGS_SUPPORT_QUOTES is not set +# CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT is not set +# CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM is not set + +# +# Init Utilities +# +# CONFIG_INIT is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +# CONFIG_REBOOT is not set +# CONFIG_MESG is not set + +# +# Login/Password Management Utilities +# +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_ADDGROUP is not set +# CONFIG_DELGROUP is not set +# CONFIG_ADDUSER is not set +# CONFIG_DELUSER is not set +# CONFIG_GETTY is not set +CONFIG_FEATURE_U_W_TMP=y +# CONFIG_LOGIN is not set +# CONFIG_PASSWD is not set +# CONFIG_SU is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +# CONFIG_CROND is not set +# CONFIG_CRONTAB is not set +CONFIG_DC=y +# CONFIG_DEVFSD is not set +# CONFIG_LAST is not set +# CONFIG_HDPARM is not set +CONFIG_MAKEDEVS=y +# CONFIG_MT is not set +# CONFIG_RX is not set +CONFIG_STRINGS=y +# CONFIG_TIME is not set +# CONFIG_WATCHDOG is not set + +# +# Linux Module Utilities +# +# CONFIG_INSMOD is not set +# CONFIG_LSMOD is not set +# CONFIG_MODPROBE is not set +# CONFIG_RMMOD is not set + +# +# Networking Utilities +# +CONFIG_FEATURE_IPV6=y +# CONFIG_ARPING is not set +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +CONFIG_HOSTNAME=y +# CONFIG_HTTPD is not set +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +CONFIG_FEATURE_IFCONFIG_HW=y +# CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS is not set +CONFIG_IFUPDOWN=y +# CONFIG_FEATURE_IFUPDOWN_IP is not set +CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +CONFIG_FEATURE_IFUPDOWN_IPV6=y +# CONFIG_FEATURE_IFUPDOWN_IPX is not set +# CONFIG_FEATURE_IFUPDOWN_MAPPING is not set +# CONFIG_INETD is not set +CONFIG_IP=y +CONFIG_FEATURE_IP_ADDRESS=y +CONFIG_FEATURE_IP_LINK=y +CONFIG_FEATURE_IP_ROUTE=y +CONFIG_FEATURE_IP_TUNNEL=y +# CONFIG_IPCALC is not set +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_NAMEIF is not set +CONFIG_NC=y +CONFIG_NETSTAT=y +CONFIG_NSLOOKUP=y +CONFIG_PING=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING6=y +CONFIG_ROUTE=y +CONFIG_TELNET=y +# CONFIG_FEATURE_TELNET_TTYPE is not set +CONFIG_FEATURE_TELNET_AUTOLOGIN=y +# CONFIG_TELNETD is not set +# CONFIG_TFTP is not set +CONFIG_TRACEROUTE=y +# CONFIG_FEATURE_TRACEROUTE_VERBOSE is not set +# CONFIG_VCONFIG is not set +CONFIG_WGET=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_IP6_LITERAL=y + +# +# udhcp Server/Client +# +# CONFIG_UDHCPD is not set +CONFIG_UDHCPC=y +CONFIG_FEATURE_UDHCP_SYSLOG=y +# CONFIG_FEATURE_UDHCP_DEBUG is not set + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_KILL=y +CONFIG_KILLALL=y +CONFIG_PIDOF=y +CONFIG_PS=y +CONFIG_RENICE=y +CONFIG_TOP=y +FEATURE_CPU_USAGE_PERCENTAGE=y +CONFIG_UPTIME=y +# CONFIG_SYSCTL is not set + +# +# Another Bourne-like Shell +# +CONFIG_FEATURE_SH_IS_ASH=y +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_LASH is not set +# CONFIG_FEATURE_SH_IS_MSH is not set +# CONFIG_FEATURE_SH_IS_NONE is not set +CONFIG_ASH=y + +# +# Ash Shell Options +# +CONFIG_ASH_JOB_CONTROL=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_MATH_SUPPORT=y +# CONFIG_ASH_MATH_SUPPORT_64 is not set +CONFIG_ASH_GETOPTS=y +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_MAIL is not set +CONFIG_ASH_OPTIMIZE_FOR_SIZE=y +# CONFIG_ASH_RANDOM_SUPPORT is not set +# CONFIG_HUSH is not set +# CONFIG_LASH is not set +# CONFIG_MSH is not set + +# +# Bourne Shell Options +# +CONFIG_FEATURE_SH_EXTRA_QUIET=y +# CONFIG_FEATURE_SH_STANDALONE_SHELL is not set +CONFIG_FEATURE_COMMAND_EDITING=y +CONFIG_FEATURE_COMMAND_HISTORY=63 +# CONFIG_FEATURE_COMMAND_SAVEHISTORY is not set +CONFIG_FEATURE_COMMAND_TAB_COMPLETION=y +# CONFIG_FEATURE_COMMAND_USERNAME_COMPLETION is not set +CONFIG_FEATURE_SH_FANCY_PROMPT=y + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +# CONFIG_FEATURE_ROTATE_LOGFILE is not set +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_LOGREAD=y +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +CONFIG_KLOGD=y +CONFIG_LOGGER=y + +# +# Linux System Utilities +# +CONFIG_DMESG=y +CONFIG_FBSET=y +CONFIG_FEATURE_FBSET_FANCY=y +# CONFIG_FEATURE_FBSET_READMODE is not set +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +CONFIG_FDISK=y +FDISK_SUPPORT_LARGE_DISKS=y +CONFIG_FEATURE_FDISK_WRITABLE=y +# CONFIG_FEATURE_AIX_LABEL is not set +# CONFIG_FEATURE_SGI_LABEL is not set +# CONFIG_FEATURE_SUN_LABEL is not set +# CONFIG_FEATURE_OSF_LABEL is not set +# CONFIG_FEATURE_FDISK_ADVANCED is not set +# CONFIG_FREERAMDISK is not set +CONFIG_FSCK_MINIX=y +CONFIG_MKFS_MINIX=y + +# +# Minix filesystem support +# +CONFIG_FEATURE_MINIX2=y +# CONFIG_GETOPT is not set +CONFIG_HEXDUMP=y +CONFIG_HWCLOCK=y +CONFIG_FEATURE_HWCLOCK_LONGOPTIONS=y +# CONFIG_LOSETUP is not set +CONFIG_MKSWAP=y +CONFIG_MORE=y +CONFIG_FEATURE_USE_TERMIOS=y +CONFIG_PIVOT_ROOT=y +# CONFIG_RDATE is not set +CONFIG_SWAPONOFF=y +CONFIG_MOUNT=y +CONFIG_NFSMOUNT=y +CONFIG_UMOUNT=y +CONFIG_FEATURE_MOUNT_FORCE=y + +# +# Common options for mount/umount +# +# CONFIG_FEATURE_MOUNT_LOOP is not set +# CONFIG_FEATURE_MTAB_SUPPORT is not set + +# +# Debugging Options +# +# CONFIG_DEBUG is not set diff --git a/meta/packages/busybox/busybox-1.01/thumb-bsdlabel.patch b/meta/packages/busybox/busybox-1.01/thumb-bsdlabel.patch new file mode 100644 index 000000000..dc3eb7c55 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/thumb-bsdlabel.patch @@ -0,0 +1,11 @@ +--- busybox-1.01/util-linux/fdisk.c 1970-01-01 00:00:00.000000000 +0000 ++++ busybox-1.01/util-linux/fdisk.c 1970-01-01 00:00:00.000000000 +0000 +@@ -507,7 +507,7 @@ check_aix_label( void ) + + #define BSD_LINUX_BOOTDIR "/usr/ucb/mdec" + +-#if defined (i386) || defined (__sparc__) || defined (__arm__) || defined (__mips__) || defined (__s390__) || defined (__sh__) || defined(__x86_64__) ++#if defined (i386) || defined (__sparc__) || defined (__arm__) || defined (__thumb__) || defined (__mips__) || defined (__s390__) || defined (__sh__) || defined(__x86_64__) + #define BSD_LABELSECTOR 1 + #define BSD_LABELOFFSET 0 + #elif defined (__alpha__) || defined (__powerpc__) || defined (__ia64__) || defined (__hppa__) diff --git a/meta/packages/busybox/busybox-1.01/uclibc_posix.patch b/meta/packages/busybox/busybox-1.01/uclibc_posix.patch new file mode 100644 index 000000000..aefb99406 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/uclibc_posix.patch @@ -0,0 +1,20 @@ +see http://www.busybox.net/lists/busybox/2004-December/013276.html + +--- busybox-old/libbb/loop.c 2004-08-16 04:36:28.000000000 -0400 ++++ busybox/libbb/loop.c 2004-12-04 23:45:58.000000000 -0500 +@@ -19,6 +19,7 @@ + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + ++#include + #include + #include + #include +@@ -30,7 +31,6 @@ + /* Grumble... The 2.6.x kernel breaks asm/posix_types.h + * so we get to try and cope as best we can... */ + #include +-#include + + #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0) + #define __bb_kernel_dev_t __kernel_old_dev_t diff --git a/meta/packages/busybox/busybox-1.01/udhcppidfile-breakage.patch b/meta/packages/busybox/busybox-1.01/udhcppidfile-breakage.patch new file mode 100644 index 000000000..031274908 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/udhcppidfile-breakage.patch @@ -0,0 +1,57 @@ +--- busybox-1.00/networking/udhcp/common.c~udhcppidfile2 ++++ busybox-1.00/networking/udhcp/common.c +@@ -74,7 +74,7 @@ + + if (pid > 0) { + /* parent */ +- if (pidfile_reassign(pidfile, pid) < 0) { ++ if (pidfile != NULL && pidfile_reassign(pidfile, pid) < 0) { + (void)kill(pid, SIGKILL); + exit(1); + } else +@@ -119,7 +119,7 @@ + sanitize_fds(); + + /* do some other misc startup stuff while we are here to save bytes */ +- if (pidfile_acquire(pidfile) < 0) ++ if (pidfile != NULL && pidfile_acquire(pidfile) < 0) + exit(1); + + /* equivelent of doing a fflush after every \n */ +@@ -166,7 +166,7 @@ + sanitize_fds(); + + /* do some other misc startup stuff while we are here to save bytes */ +- if (pidfile_acquire(pidfile) < 0) ++ if (pidfile != NULL && pidfile_acquire(pidfile) < 0) + exit(1); + + /* equivelent of doing a fflush after every \n */ +--- busybox-1.00/networking/udhcp/pidfile.c~udhcppidfile2 ++++ busybox-1.00/networking/udhcp/pidfile.c +@@ -141,7 +141,11 @@ + int pidfile_acquire(const char *pidfile) + { + int fd, result; +- if (!pidfile) return (-1); ++ ++ if (pidfile == NULL) { ++ LOG(LOG_ERR, "pidfile_acquire: filename is NULL\n"); ++ return (-1); ++ } + + if ((fd = pidfile_open(pidfile)) < 0) + return (-1); +@@ -170,7 +174,11 @@ + int pidfile_reassign(const char *pidfile, int pid) + { + int fd, result; +- if (!pidfile) return (-1); ++ ++ if (pidfile == NULL) { ++ LOG(LOG_ERR, "pidfile_reassign: filename is NULL\n"); ++ return (-1); ++ } + + if ((fd = pidfile_open(pidfile)) < 0) + return (-1); diff --git a/meta/packages/busybox/busybox-1.01/udhcppidfile.patch b/meta/packages/busybox/busybox-1.01/udhcppidfile.patch new file mode 100644 index 000000000..fb2b2ec19 --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/udhcppidfile.patch @@ -0,0 +1,276 @@ +--- busybox-1.00/networking/udhcp/pidfile.h-dist 2004-04-15 03:51:26.000000000 +1000 ++++ busybox-1.00/networking/udhcp/pidfile.h 2004-10-27 15:46:38.000000000 +1000 +@@ -21,5 +21,5 @@ + + + int pidfile_acquire(const char *pidfile); +-void pidfile_write_release(int pid_fd); ++int pidfile_reassign(const char *pidfile, int newpid); + +--- busybox-1.00/networking/udhcp/pidfile.c-dist 2004-04-15 03:51:25.000000000 +1000 ++++ busybox-1.00/networking/udhcp/pidfile.c 2004-10-27 19:43:40.000000000 +1000 +@@ -25,6 +25,7 @@ + #include + #include + #include ++#include + + #include "pidfile.h" + #include "common.h" +@@ -37,39 +38,146 @@ + } + + +-int pidfile_acquire(const char *pidfile) ++static int pidfile_open(const char *pidfile) + { +- int pid_fd; +- if (!pidfile) return -1; ++ int fd; + +- pid_fd = open(pidfile, O_CREAT | O_WRONLY, 0644); +- if (pid_fd < 0) { +- LOG(LOG_ERR, "Unable to open pidfile %s: %m\n", pidfile); +- } else { +- lockf(pid_fd, F_LOCK, 0); +- if (!saved_pidfile) +- atexit(pidfile_delete); +- saved_pidfile = (char *) pidfile; ++ if ((fd = open(pidfile, O_CREAT | O_RDWR, 0644)) < 0) { ++ LOG(LOG_ERR, "pidfile_open: open %s failed: %m\n", pidfile); ++ return (-1); ++ } ++ ++ /* NOTE: lockf is not inherited by child after fork */ ++ if (lockf(fd, F_LOCK, 0) < 0) { ++ LOG(LOG_ERR, "pidfile_open: lock %s failed: %m\n", pidfile); ++ close(fd); ++ return (-1); ++ } ++ ++ return (fd); ++} ++ ++ ++static int pidfile_check(int fd, const char *pidfile) ++{ ++ int len, pid; ++ char buf[20]; ++ ++ if (lseek(fd, 0L, SEEK_SET) < 0) { ++ LOG(LOG_ERR, "pidfile_check: lseek %s failed: %m\n", pidfile); ++ return (-1); ++ } ++ ++ if ((len = read(fd, buf, sizeof buf - 1)) < 0) { ++ LOG(LOG_ERR, "pidfile_check: read %s failed: %m\n", pidfile); ++ return (-1); ++ } ++ ++ if (len == 0) ++ return (0); ++ ++ buf[len] = '\0'; ++ ++ if ((pid = atoi(buf)) <= 1) { ++ LOG(LOG_WARNING, ++ "pidfile_check: ignoring bogus pid (%s) in %s\n", ++ buf, pidfile); ++ return (0); ++ } ++ ++ if (kill((pid_t)pid, 0) == 0) { ++ LOG(LOG_ERR, "pidfile_check: process %d exists (%s)\n", ++ pid, pidfile); ++ return (-1); ++ } ++ ++ if (errno != ESRCH) { ++ LOG(LOG_ERR, "pidfile_check: kill %d failed (%s): %m\n", ++ pid, pidfile); ++ return (-1); ++ } ++ ++ return (0); ++} ++ ++ ++static int pidfile_store(int fd, const char *pidfile, int pid) ++{ ++ int len; ++ char buf[20]; ++ ++ if (lseek(fd, 0L, SEEK_SET) < 0) { ++ LOG(LOG_ERR, "pidfile_store: lseek %s failed: %m\n", pidfile); ++ return (-1); ++ } ++ ++ len = snprintf(buf, sizeof buf - 1, "%d\n", pid); ++ buf[len] = '\0'; ++ ++ if (write(fd, buf, len) < 0) { ++ LOG(LOG_ERR, "pidfile_store: write %s failed: %m\n", ++ pidfile); ++ return (-1); ++ } ++ ++ if (ftruncate(fd, len) < 0) { ++ LOG(LOG_ERR, "pidfile_store: ftruncate %d failed (%s): %m\n", ++ len, pidfile); ++ return (-1); + } + +- return pid_fd; ++ return (0); + } + + +-void pidfile_write_release(int pid_fd) ++static void pidfile_close(int fd) + { +- FILE *out; ++ (void)lseek(fd, 0L, SEEK_SET); ++ (void)lockf(fd, F_ULOCK, 0); ++ (void)close(fd); ++} + +- if (pid_fd < 0) return; + +- if ((out = fdopen(pid_fd, "w")) != NULL) { +- fprintf(out, "%d\n", getpid()); +- fclose(out); ++int pidfile_acquire(const char *pidfile) ++{ ++ int fd, result; ++ if (!pidfile) return (-1); ++ ++ if ((fd = pidfile_open(pidfile)) < 0) ++ return (-1); ++ ++ if ((result = pidfile_check(fd, pidfile)) == 0) ++ result = pidfile_store(fd, pidfile, getpid()); ++ ++ pidfile_close(fd); ++ ++ if (result == 0) { ++ saved_pidfile = (char *) pidfile; ++ atexit(pidfile_delete); + } +- lockf(pid_fd, F_UNLCK, 0); +- close(pid_fd); ++ ++ return (result); + } + + ++/* ++ * reassign the pid in a pidfile - used just after a fork so a parent ++ * can store the pid of its child into the file without any window ++ * where the pid in the file is a dead process (which might let another ++ * instance of the program start). Note the parent must use _exit() to ++ * avoid triggering the unlink scheduled above in pidfile_acquire() ++ */ ++int pidfile_reassign(const char *pidfile, int pid) ++{ ++ int fd, result; ++ if (!pidfile) return (-1); ++ ++ if ((fd = pidfile_open(pidfile)) < 0) ++ return (-1); + ++ result = pidfile_store(fd, pidfile, pid); + ++ pidfile_close(fd); ++ ++ return (result); ++} +--- busybox-1.00/networking/udhcp/common.c-dist 2004-05-19 19:18:04.000000000 +1000 ++++ busybox-1.00/networking/udhcp/common.c 2004-10-27 19:58:10.000000000 +1000 +@@ -64,16 +64,34 @@ + #ifdef __uClinux__ + LOG(LOG_ERR, "Cannot background in uclinux (yet)"); + #else /* __uClinux__ */ +- int pid_fd; ++ int pid, fd; + +- /* hold lock during fork. */ +- pid_fd = pidfile_acquire(pidfile); +- if (daemon(0, 0) == -1) { ++ /* NOTE: lockf is not inherited by the child after fork */ ++ if ((pid = fork()) < 0) { + perror("fork"); + exit(1); + } ++ ++ if (pid > 0) { ++ /* parent */ ++ if (pidfile_reassign(pidfile, pid) < 0) { ++ (void)kill(pid, SIGKILL); ++ exit(1); ++ } else ++ _exit(0); ++ } ++ ++ /* child */ ++ (void)chdir("/"); ++ if ((fd = open("/dev/null", O_RDWR)) >= 0) { ++ (void)dup2(fd, 0); ++ (void)dup2(fd, 1); ++ (void)dup2(fd, 2); ++ (void)close(fd); ++ } ++ (void)setsid(); ++ + daemonized++; +- pidfile_write_release(pid_fd); + #endif /* __uClinux__ */ + } + +@@ -97,14 +115,12 @@ + + void start_log_and_pid(const char *client_server, const char *pidfile) + { +- int pid_fd; +- + /* Make sure our syslog fd isn't overwritten */ + sanitize_fds(); + + /* do some other misc startup stuff while we are here to save bytes */ +- pid_fd = pidfile_acquire(pidfile); +- pidfile_write_release(pid_fd); ++ if (pidfile_acquire(pidfile) < 0) ++ exit(1); + + /* equivelent of doing a fflush after every \n */ + setlinebuf(stdout); +@@ -150,8 +166,8 @@ + sanitize_fds(); + + /* do some other misc startup stuff while we are here to save bytes */ +- pid_fd = pidfile_acquire(pidfile); +- pidfile_write_release(pid_fd); ++ if (pidfile_acquire(pidfile) < 0) ++ exit(1); + + /* equivelent of doing a fflush after every \n */ + setlinebuf(stdout); +--- busybox-1.00/networking/udhcp/common.h-dist 2004-05-19 18:29:05.000000000 +1000 ++++ busybox-1.00/networking/udhcp/common.h 2004-10-27 15:10:16.000000000 +1000 +@@ -42,7 +42,6 @@ + long uptime(void); + void background(const char *pidfile); + void start_log_and_pid(const char *client_server, const char *pidfile); +-void background(const char *pidfile); + void udhcp_logging(int level, const char *fmt, ...); + + #define LOG(level, str, args...) udhcp_logging(level, str, ## args) +--- busybox-1.00/networking/udhcp/script.c-dist 2004-05-19 17:45:47.000000000 +1000 ++++ busybox-1.00/networking/udhcp/script.c 2004-10-27 15:54:04.000000000 +1000 +@@ -228,6 +228,6 @@ + execle(client_config.script, client_config.script, + name, NULL, envp); + LOG(LOG_ERR, "script %s failed: %m", client_config.script); +- exit(1); ++ _exit(1); + } + } diff --git a/meta/packages/busybox/busybox-1.01/udhcpscript.patch b/meta/packages/busybox/busybox-1.01/udhcpscript.patch new file mode 100644 index 000000000..fc21d440c --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/udhcpscript.patch @@ -0,0 +1,17 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- busybox-1.00-rc3/examples/udhcp/simple.script~udhcpscript ++++ busybox-1.00-rc3/examples/udhcp/simple.script +@@ -17,8 +17,7 @@ + /sbin/ifconfig $interface $ip $BROADCAST $NETMASK + + if [ -n "$router" ] ; then +- echo "deleting routers" +- while route del default gw 0.0.0.0 dev $interface ; do ++ while route del default gw 0.0.0.0 dev $interface 2>/dev/null ; do + : + done + diff --git a/meta/packages/busybox/busybox-1.01/wrt54/defconfig b/meta/packages/busybox/busybox-1.01/wrt54/defconfig new file mode 100644 index 000000000..7f1aef4ef --- /dev/null +++ b/meta/packages/busybox/busybox-1.01/wrt54/defconfig @@ -0,0 +1,476 @@ +# +# Automatically generated make config: don't edit +# +HAVE_DOT_CONFIG=y + +# +# General Configuration +# +# CONFIG_FEATURE_BUFFERS_USE_MALLOC is not set +CONFIG_FEATURE_BUFFERS_GO_ON_STACK=y +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +CONFIG_FEATURE_VERBOSE_USAGE=y +# CONFIG_FEATURE_INSTALLER is not set +# CONFIG_LOCALE_SUPPORT is not set +CONFIG_FEATURE_DEVFS=y +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_CLEAN_UP is not set +CONFIG_FEATURE_SUID=y +# CONFIG_FEATURE_SUID_CONFIG is not set +# CONFIG_SELINUX is not set + +# +# Build Options +# +# CONFIG_STATIC is not set +CONFIG_LFS=y +USING_CROSS_COMPILER=y +CROSS_COMPILER_PREFIX="mipsel-uclibc-" +EXTRA_CFLAGS_OPTIONS="-Os " + +# +# Installation Options +# +# CONFIG_INSTALL_NO_USR is not set +PREFIX="./_install" + +# +# Archival Utilities +# +# CONFIG_AR is not set +CONFIG_BUNZIP2=y +# CONFIG_CPIO is not set +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +CONFIG_GUNZIP=y +CONFIG_FEATURE_GUNZIP_UNCOMPRESS=y +CONFIG_GZIP=y +# CONFIG_RPM2CPIO is not set +# CONFIG_RPM is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_BZIP2=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_GZIP=y +# CONFIG_FEATURE_TAR_COMPRESS is not set +# CONFIG_FEATURE_TAR_OLDGNU_COMPATABILITY is not set +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_UNCOMPRESS is not set +# CONFIG_UNZIP is not set + +# +# Common options for cpio and tar +# +# CONFIG_FEATURE_UNARCHIVE_TAPE is not set + +# +# Coreutils +# +CONFIG_BASENAME=y +# CONFIG_CAL is not set +CONFIG_CAT=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_CHROOT=y +# CONFIG_CMP is not set +CONFIG_CP=y +CONFIG_CUT=y +CONFIG_DATE=y +CONFIG_FEATURE_DATE_ISOFMT=y +CONFIG_DD=y +CONFIG_DF=y +CONFIG_DIRNAME=y +# CONFIG_DOS2UNIX is not set +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFALT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPR=y +CONFIG_FALSE=y +# CONFIG_FOLD is not set +CONFIG_HEAD=y +CONFIG_FEATURE_FANCY_HEAD=y +CONFIG_HOSTID=y +CONFIG_ID=y +# CONFIG_INSTALL is not set +CONFIG_LENGTH=y +CONFIG_LN=y +# CONFIG_LOGNAME is not set +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +CONFIG_FEATURE_LS_RECURSIVE=y +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +CONFIG_MD5SUM=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +# CONFIG_MKNOD is not set +CONFIG_MV=y +# CONFIG_OD is not set +# CONFIG_PRINTF is not set +CONFIG_PWD=y +# CONFIG_REALPATH is not set +CONFIG_RM=y +CONFIG_RMDIR=y +# CONFIG_SEQ is not set +# CONFIG_SHA1SUM is not set +CONFIG_SLEEP=y +CONFIG_FEATURE_FANCY_SLEEP=y +CONFIG_SORT=y +# CONFIG_STTY is not set +CONFIG_SYNC=y +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +CONFIG_FEATURE_TEE_USE_BLOCK_IO=y +CONFIG_TEST=y + +# +# test (forced enabled for use with shell) +# +# CONFIG_FEATURE_TEST_64 is not set +CONFIG_TOUCH=y +CONFIG_TR=y +CONFIG_TRUE=y +# CONFIG_TTY is not set +CONFIG_UNAME=y +CONFIG_UNIQ=y +# CONFIG_USLEEP is not set +# CONFIG_UUDECODE is not set +# CONFIG_UUENCODE is not set +# CONFIG_WATCH is not set +CONFIG_WC=y +# CONFIG_WHO is not set +# CONFIG_WHOAMI is not set +CONFIG_YES=y + +# +# Common options for cp and mv +# +CONFIG_FEATURE_PRESERVE_HARDLINKS=y + +# +# Common options for ls and more +# +CONFIG_FEATURE_AUTOWIDTH=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Common options for md5sum, sha1sum +# +CONFIG_FEATURE_MD5_SHA1_SUM_CHECK=y + +# +# Console Utilities +# +# CONFIG_CHVT is not set +CONFIG_CLEAR=y +# CONFIG_DEALLOCVT is not set +# CONFIG_DUMPKMAP is not set +# CONFIG_GETKEY is not set +# CONFIG_LOADFONT is not set +# CONFIG_LOADKMAP is not set +# CONFIG_OPENVT is not set +CONFIG_RESET=y +# CONFIG_SETKEYCODES is not set + +# +# Debian Utilities +# +CONFIG_MKTEMP=y +# CONFIG_PIPE_PROGRESS is not set +# CONFIG_READLINK is not set +CONFIG_RUN_PARTS=y +CONFIG_START_STOP_DAEMON=y +CONFIG_WHICH=y + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_MATH=y +# CONFIG_PATCH is not set +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +CONFIG_FEATURE_VI_USE_SIGNALS=y +CONFIG_FEATURE_VI_DOT_CMD=y +CONFIG_FEATURE_VI_READONLY=y +CONFIG_FEATURE_VI_SETOPTS=y +CONFIG_FEATURE_VI_SET=y +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_OPTIMIZE_CURSOR=y + +# +# Finding Utilities +# +CONFIG_FIND=y +# CONFIG_FEATURE_FIND_MTIME is not set +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +# CONFIG_FEATURE_FIND_NEWER is not set +# CONFIG_FEATURE_FIND_INUM is not set +CONFIG_GREP=y +CONFIG_FEATURE_GREP_EGREP_ALIAS=y +CONFIG_FEATURE_GREP_FGREP_ALIAS=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION=y +CONFIG_FEATURE_XARGS_SUPPORT_QUOTES=y +CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT=y +CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM=y + +# +# Init Utilities +# +CONFIG_INIT=y +CONFIG_FEATURE_USE_INITTAB=y +# CONFIG_FEATURE_INITRD is not set +# CONFIG_FEATURE_INIT_COREDUMPS is not set +# CONFIG_FEATURE_EXTRA_QUIET is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +CONFIG_REBOOT=y +CONFIG_MESG=y + +# +# Login/Password Management Utilities +# +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_ADDGROUP is not set +# CONFIG_DELGROUP is not set +# CONFIG_ADDUSER is not set +# CONFIG_DELUSER is not set +# CONFIG_GETTY is not set +# CONFIG_FEATURE_U_W_TMP is not set +CONFIG_LOGIN=y +CONFIG_FEATURE_SECURETTY=y +CONFIG_PASSWD=y +# CONFIG_SU is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Common options for adduser, deluser, login, su +# +# CONFIG_FEATURE_SHADOWPASSWDS is not set + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +CONFIG_CROND=y +# CONFIG_FEATURE_CROND_CALL_SENDMAIL is not set +CONFIG_CRONTAB=y +# CONFIG_DC is not set +# CONFIG_DEVFSD is not set +# CONFIG_LAST is not set +# CONFIG_HDPARM is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_MT is not set +# CONFIG_RX is not set +CONFIG_STRINGS=y +CONFIG_TIME=y +# CONFIG_WATCHDOG is not set + +# +# Linux Module Utilities +# +CONFIG_INSMOD=y +CONFIG_FEATURE_2_4_MODULES=y +# CONFIG_FEATURE_2_6_MODULES is not set +# CONFIG_FEATURE_INSMOD_VERSION_CHECKING is not set +# CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS is not set +# CONFIG_FEATURE_INSMOD_LOADINKMEM is not set +# CONFIG_FEATURE_INSMOD_LOAD_MAP is not set +CONFIG_LSMOD=y +CONFIG_FEATURE_QUERY_MODULE_INTERFACE=y +# CONFIG_MODPROBE is not set +CONFIG_RMMOD=y +CONFIG_FEATURE_CHECK_TAINTED_MODULE=y + +# +# Networking Utilities +# +CONFIG_FEATURE_IPV6=y +CONFIG_ARPING=y +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +# CONFIG_HOSTNAME is not set +CONFIG_HTTPD=y +# CONFIG_FEATURE_HTTPD_USAGE_FROM_INETD_ONLY is not set +CONFIG_FEATURE_HTTPD_BASIC_AUTH=y +CONFIG_FEATURE_HTTPD_AUTH_MD5=y +CONFIG_FEATURE_HTTPD_RELOAD_CONFIG_SIGHUP=y +# CONFIG_FEATURE_HTTPD_SETUID is not set +CONFIG_FEATURE_HTTPD_CONFIG_WITH_MIME_TYPES=y +CONFIG_FEATURE_HTTPD_CGI=y +CONFIG_FEATURE_HTTPD_SET_REMOTE_PORT_TO_ENV=y +CONFIG_FEATURE_HTTPD_ENCODE_URL_STR=y +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +CONFIG_FEATURE_IFCONFIG_HW=y +CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS=y +CONFIG_IFUPDOWN=y +# CONFIG_FEATURE_IFUPDOWN_IP is not set +CONFIG_FEATURE_IFUPDOWN_IP_BUILTIN=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +# CONFIG_FEATURE_IFUPDOWN_IPV6 is not set +# CONFIG_FEATURE_IFUPDOWN_IPX is not set +# CONFIG_FEATURE_IFUPDOWN_MAPPING is not set +# CONFIG_INETD is not set +# CONFIG_IP is not set +CONFIG_IPCALC=y +CONFIG_FEATURE_IPCALC_FANCY=y +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_NAMEIF is not set +CONFIG_NC=y +CONFIG_NETSTAT=y +CONFIG_NSLOOKUP=y +CONFIG_PING=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING6=y +CONFIG_ROUTE=y +# CONFIG_TELNET is not set +# CONFIG_TELNETD is not set +# CONFIG_TFTP is not set +CONFIG_TRACEROUTE=y +CONFIG_FEATURE_TRACEROUTE_VERBOSE=y +CONFIG_VCONFIG=y +CONFIG_WGET=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_IP6_LITERAL=y + +# +# udhcp Server/Client +# +# CONFIG_UDHCPD is not set +CONFIG_UDHCPC=y +# CONFIG_FEATURE_UDHCP_SYSLOG is not set +# CONFIG_FEATURE_UDHCP_DEBUG is not set + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_KILL=y +CONFIG_KILLALL=y +CONFIG_PIDOF=y +CONFIG_PS=y +# CONFIG_RENICE is not set +CONFIG_TOP=y +FEATURE_CPU_USAGE_PERCENTAGE=y +CONFIG_UPTIME=y +CONFIG_SYSCTL=y + +# +# Another Bourne-like Shell +# +CONFIG_FEATURE_SH_IS_ASH=y +# CONFIG_FEATURE_SH_IS_HUSH is not set +# CONFIG_FEATURE_SH_IS_LASH is not set +# CONFIG_FEATURE_SH_IS_MSH is not set +# CONFIG_FEATURE_SH_IS_NONE is not set +CONFIG_ASH=y + +# +# Ash Shell Options +# +CONFIG_ASH_PIPE_OPTIMIZATION=y +CONFIG_FEATURE_BUILTIN_TEST=y +CONFIG_FEATURE_BUILTIN_ECHO=y +CONFIG_FEATURE_BUILTIN_PIDOF=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_MATH_SUPPORT=y +# CONFIG_ASH_MATH_SUPPORT_64 is not set +CONFIG_ASH_GETOPTS=y +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_MAIL is not set +CONFIG_ASH_OPTIMIZE_FOR_SIZE=y +# CONFIG_ASH_RANDOM_SUPPORT is not set +# CONFIG_HUSH is not set +# CONFIG_LASH is not set +# CONFIG_MSH is not set + +# +# Bourne Shell Options +# +# CONFIG_FEATURE_SH_EXTRA_QUIET is not set +# CONFIG_FEATURE_SH_STANDALONE_SHELL is not set +CONFIG_FEATURE_COMMAND_EDITING=y +CONFIG_FEATURE_COMMAND_HISTORY=15 +# CONFIG_FEATURE_COMMAND_SAVEHISTORY is not set +CONFIG_FEATURE_COMMAND_TAB_COMPLETION=y +# CONFIG_FEATURE_COMMAND_USERNAME_COMPLETION is not set +CONFIG_FEATURE_SH_FANCY_PROMPT=y + +# +# System Logging Utilities +# +CONFIG_SYSLOGD=y +CONFIG_FEATURE_ROTATE_LOGFILE=y +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_LOGREAD=y +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +CONFIG_KLOGD=y +CONFIG_LOGGER=y + +# +# Linux System Utilities +# +CONFIG_DMESG=y +# CONFIG_FBSET is not set +# CONFIG_FDFLUSH is not set +# CONFIG_FDFORMAT is not set +# CONFIG_FDISK is not set +FDISK_SUPPORT_LARGE_DISKS=y +# CONFIG_FREERAMDISK is not set +# CONFIG_FSCK_MINIX is not set +# CONFIG_MKFS_MINIX is not set +# CONFIG_GETOPT is not set +CONFIG_HEXDUMP=y +# CONFIG_HWCLOCK is not set +# CONFIG_LOSETUP is not set +# CONFIG_MKSWAP is not set +CONFIG_MORE=y +CONFIG_FEATURE_USE_TERMIOS=y +CONFIG_PIVOT_ROOT=y +CONFIG_RDATE=y +# CONFIG_SWAPONOFF is not set +CONFIG_MOUNT=y +CONFIG_NFSMOUNT=y +CONFIG_UMOUNT=y +CONFIG_FEATURE_MOUNT_FORCE=y + +# +# Common options for mount/umount +# +CONFIG_FEATURE_MOUNT_LOOP=y +# CONFIG_FEATURE_MTAB_SUPPORT is not set + +# +# Debugging Options +# +# CONFIG_DEBUG is not set diff --git a/meta/packages/busybox/busybox_1.01.bb b/meta/packages/busybox/busybox_1.01.bb new file mode 100644 index 000000000..996b5418a --- /dev/null +++ b/meta/packages/busybox/busybox_1.01.bb @@ -0,0 +1,169 @@ +DESCRIPTION = "BusyBox combines tiny versions of many common UNIX utilities into a single \ +small executable. It provides minimalist replacements for most of the \ +utilities you usually find in GNU fileutils, shellutils, etc. The utilities \ +in BusyBox generally have fewer options than their full-featured GNU \ +cousins; however, the options that are included provide the expected \ +functionality and behave very much like their GNU counterparts. BusyBox \ +provides a fairly complete POSIX environment for any small or embedded \ +system." +HOMEPAGE = "http://www.busybox.net" +LICENSE = "GPL" +SECTION = "base" +PRIORITY = "required" +PR = "r11" + +SRC_URI = "http://www.busybox.net/downloads/busybox-${PV}.tar.gz \ + file://udhcppidfile.patch;patch=1 \ + file://udhcppidfile-breakage.patch;patch=1 \ + file://add-getkey-applet.patch;patch=1 \ + file://below.patch;patch=1 \ + file://dhcp-hostname.patch;patch=1 \ + file://dhcpretrytime.patch;patch=1 \ + file://fbset.patch;patch=1 \ + file://hdparm_M.patch;patch=1 \ + file://ifupdown-spurious-environ.patch;patch=1 \ + file://iproute-flush-cache.patch;patch=1;pnum=0 \ + file://mount-all-type.patch;patch=1 \ + file://readlink.patch;patch=1 \ + file://rmmod.patch;patch=1 \ + file://udhcpscript.patch;patch=1 \ + file://thumb-bsdlabel.patch;patch=1 \ + file://uclibc_posix.patch;patch=1 \ + file://glibc2.4-icmp6.patch;patch=1 \ + file://defconfig \ + file://busybox-cron \ + file://busybox-httpd \ + file://busybox-udhcpd \ + file://syslog \ + file://hwclock.sh \ + file://default.script \ + file://syslog.conf \ + file://mount.busybox \ + file://umount.busybox" +SRC_URI_append_slugos += " file://sysctl.conf " + +S = "${WORKDIR}/busybox-${PV}" + +export EXTRA_CFLAGS = "${CFLAGS}" +EXTRA_OEMAKE_append = " CROSS=${HOST_PREFIX}" +PACKAGES =+ "${PN}-httpd ${PN}-udhcpd" + +FILES_${PN}-httpd = "${sysconfdir}/init.d/busybox-httpd /srv/www" +FILES_${PN}-udhcpd = "${sysconfdir}/init.d/busybox-udhcpd" + +FILES_${PN} += " ${datadir}/udhcpc" + +INITSCRIPT_PACKAGES = "${PN} ${PN}-httpd ${PN}-udhcpd" +INITSCRIPT_NAME_${PN}-httpd = "busybox-httpd" +INITSCRIPT_NAME_${PN}-udhcpd = "busybox-udhcpd" +INITSCRIPT_NAME_${PN} = "syslog" +CONFFILES_${PN} = "${sysconfdir}/syslog.conf" + +# This disables the syslog startup links in slugos (see slugos-init) +INITSCRIPT_PARAMS_${PN}_slugos = "start 20 ." + +inherit cml1 update-rc.d + +do_configure () { + install -m 0644 ${WORKDIR}/defconfig ${S}/.config + cml1_do_configure +} + +do_compile () { + unset CFLAGS + base_do_compile +} + +do_install () { + install -d ${D}${sysconfdir}/init.d + oe_runmake 'PREFIX=${D}' install + + # Move everything to /busybox (not supposed to end up in any package) + install -d ${D}/busybox + mv ${D}${base_bindir} ${D}${base_sbindir} ${D}${prefix} ${D}/busybox/ + # Move the busybox binary back to /bin + install -d ${D}${base_bindir} + mv ${D}/busybox${base_bindir}/busybox ${D}${base_bindir}/ + # Move back the sh symlink + mv ${D}/busybox${base_bindir}/sh ${D}${base_bindir}/ + + install -m 0755 ${WORKDIR}/syslog ${D}${sysconfdir}/init.d/ + install -m 644 ${WORKDIR}/syslog.conf ${D}${sysconfdir}/ + if grep "CONFIG_CROND=y" ${WORKDIR}/defconfig; then + # Move crond back to /usr/sbin/crond + install -d ${D}${sbindir} + mv ${D}/busybox${sbindir}/crond ${D}${sbindir}/ + + install -m 0755 ${WORKDIR}/busybox-cron ${D}${sysconfdir}/init.d/ + fi + if grep "CONFIG_HTTPD=y" ${WORKDIR}/defconfig; then + # Move httpd back to /usr/sbin/httpd + install -d ${D}${sbindir} + mv ${D}/busybox${sbindir}/httpd ${D}${sbindir}/ + + install -m 0755 ${WORKDIR}/busybox-httpd ${D}${sysconfdir}/init.d/ + install -d ${D}/srv/www + fi + if grep "CONFIG_UDHCPD=y" ${WORKDIR}/defconfig; then + # Move udhcpd back to /usr/sbin/udhcpd + install -d ${D}${sbindir} + mv ${D}/busybox${sbindir}/udhcpd ${D}${sbindir}/ + + install -m 0755 ${WORKDIR}/busybox-udhcpd ${D}${sysconfdir}/init.d/ + fi + if grep "CONFIG_HWCLOCK=y" ${WORKDIR}/defconfig; then + # Move hwclock back to /sbin/hwclock + install -d ${D}${base_sbindir} + mv ${D}/busybox${base_sbindir}/hwclock ${D}${base_sbindir}/ + + install -m 0755 ${WORKDIR}/hwclock.sh ${D}${sysconfdir}/init.d/ + fi + if grep "CONFIG_UDHCPC=y" ${WORKDIR}/defconfig; then + # Move dhcpc back to /usr/sbin/udhcpc + install -d ${D}${base_sbindir} + mv ${D}/busybox${base_sbindir}/udhcpc ${D}${base_sbindir}/ + + install -d ${D}${sysconfdir}/udhcpc.d + install -d ${D}${datadir}/udhcpc + install -m 0755 ${S}/examples/udhcp/simple.script ${D}${sysconfdir}/udhcpc.d/50default + install -m 0755 ${WORKDIR}/default.script ${D}${datadir}/udhcpc/default.script + fi + + install -m 0644 ${S}/busybox.links ${D}${sysconfdir} +} + +do_install_append_slugos() { + install -m 0644 ${WORKDIR}/sysctl.conf ${D}${sysconfdir} +} + +pkg_postinst_${PN} () { + # If we are not making an image we create links for the utilities that doesn't exist + # so the update-alternatives script will get the utilities it needs + # (update-alternatives have no problem replacing links later anyway) + test -n 2> /dev/null || alias test='busybox test' + if test "x$D" = "x"; then while read link; do if test ! -h "$link"; then case "$link" in /*/*/*) to="../../bin/busybox";; /bin/*) to="busybox";; /*/*) to="../bin/busybox";; esac; busybox ln -s $to $link; fi; done /* offsetof */ + #include "busybox.h" + ++#ifndef ICMP6_MEMBERSHIP_QUERY /* glibc >= 2.4 */ ++#define ICMP6_MEMBERSHIP_QUERY MLD_LISTENER_QUERY ++#define ICMP6_MEMBERSHIP_REPORT MLD_LISTENER_REPORT ++#define ICMP6_MEMBERSHIP_REDUCTION MLD_LISTENER_REDUCTION ++#endif ++ + static const int DEFDATALEN = 56; + static const int MAXIPLEN = 60; + static const int MAXICMPLEN = 76; diff --git a/meta/packages/busybox/files/hwclock.sh b/meta/packages/busybox/files/hwclock.sh new file mode 100644 index 000000000..5acfb9fb2 --- /dev/null +++ b/meta/packages/busybox/files/hwclock.sh @@ -0,0 +1,74 @@ +#!/bin/sh +# hwclock.sh Set system clock to hardware clock, according to the UTC +# setting in /etc/default/rcS (see also rcS(5)). +# +# WARNING: If your hardware clock is not in UTC/GMT, this script +# must know the local time zone. This information is +# stored in /etc/localtime. This might be a problem if +# your /etc/localtime is a symlink to something in +# /usr/share/zoneinfo AND /usr isn't in the root +# partition! The workaround is to define TZ either +# in /etc/default/rcS, or in the proper place below. + +[ ! -x /sbin/hwclock ] && exit 0 + +. /etc/default/rcS + +case "$1" in + start) + if [ "$VERBOSE" != no ] + then + echo "System time was `date`." + echo "Setting the System Clock using the Hardware Clock as reference..." + fi + + if [ "$HWCLOCKACCESS" != no ] + then + if [ -z "$TZ" ] + then + hwclock --hctosys + else + TZ="$TZ" hwclock --hctosys + fi + fi + + if [ "$VERBOSE" != no ] + then + echo "System Clock set. System local time is now `date`." + fi + ;; + stop|restart|reload|force-reload) + # + # Updates the Hardware Clock with the System Clock time. + # This will *override* any changes made to the Hardware Clock. + # + # WARNING: If you disable this, any changes to the system + # clock will not be carried across reboots. + # + if [ "$VERBOSE" != no ] + then + echo "Saving the System Clock time to the Hardware Clock..." + fi + if [ "$HWCLOCKACCESS" != no ] + then + hwclock --systohc + fi + if [ "$VERBOSE" != no ] + then + echo "Hardware Clock updated to `date`." + fi + exit 0 + ;; + show) + if [ "$HWCLOCKACCESS" != no ] + then + hwclock --show + fi + ;; + *) + echo "Usage: hwclock.sh {start|stop|show|reload|restart}" >&2 + echo " start sets kernel (system) clock from hardware (RTC) clock" >&2 + echo " stop and reload set hardware (RTC) clock from kernel (system) clock" >&2 + exit 1 + ;; +esac diff --git a/meta/packages/busybox/files/mount.busybox b/meta/packages/busybox/files/mount.busybox new file mode 100755 index 000000000..fef945b7b --- /dev/null +++ b/meta/packages/busybox/files/mount.busybox @@ -0,0 +1,3 @@ +#!/bin/sh + +exec /bin/busybox mount $@ diff --git a/meta/packages/busybox/files/postinst b/meta/packages/busybox/files/postinst new file mode 100644 index 000000000..36d8190f8 --- /dev/null +++ b/meta/packages/busybox/files/postinst @@ -0,0 +1,25 @@ +#!/bin/busybox ash + +action="$1" +oldversion="$2" + +umask 022 + +if /bin/busybox [ "$action" != configure ] +then + exit 0 +fi + +. /etc/default/functions + +setup_init_hwclock() { + updatercd hwclock.sh start 50 S . stop 25 0 1 6 . + /etc/init.d/hwclock.sh restart +} + +/bin/busybox ash /usr/bin/update-alternatives --install /bin/vi vi /bin/busybox 100 +/bin/busybox ash /usr/bin/update-alternatives --install /bin/sh sh /bin/busybox 100 + +setup_init_hwclock + +exit 0 diff --git a/meta/packages/busybox/files/prerm b/meta/packages/busybox/files/prerm new file mode 100644 index 000000000..7ade4b1de --- /dev/null +++ b/meta/packages/busybox/files/prerm @@ -0,0 +1,10 @@ +#!/bin/sh + +if [ "$1" != "upgrade" ]; then + update-alternatives --remove sh /bin/busybox + update-alternatives --remove vi /bin/busybox + find /etc -name [SK][0-9][0-9]hwclock.sh | xargs rm -f + find /etc -name [SK][0-9][0-9]syslog | xargs rm -f +fi + +exit 0 diff --git a/meta/packages/busybox/files/syslog b/meta/packages/busybox/files/syslog new file mode 100644 index 000000000..a999565e8 --- /dev/null +++ b/meta/packages/busybox/files/syslog @@ -0,0 +1,69 @@ +#! /bin/sh +# +# syslog init.d script for busybox syslogd/klogd +# Written by Robert Griebl +# Configuration file added by +set -e + +if [ -f /etc/syslog.conf ]; then + . /etc/syslog.conf + LOG_LOCAL=0 + LOG_REMOTE=0 + for D in $DESTINATION; do + if [ "$D" = "buffer" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -C $BUFFERSIZE" + LOG_LOCAL=1 + elif [ "$D" = "file" ]; then + if [ -n "$LOGFILE" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -O $LOGFILE" + fi + if [ -n "$ROTATESIZE" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -s $ROTATESIZE" + fi + if [ -n "$ROTATEGENS" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -b $ROTATEGENS" + fi + LOCAL=0 + elif [ "$D" = "remote" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -R $REMOTE" + LOG_REMOTE=1 + fi + done + if [ "$LOG_LOCAL" = "1" -a "$LOG_REMOTE" = "1" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -L" + fi + if [ -n "$MARKINT" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -m $MARKINT" + fi + if [ "$REDUCE" = "yes" ]; then + SYSLOG_ARGS="$SYSLOG_ARGS -S" + fi +else + # default: log to 16K shm circular buffer + SYSLOG_ARGS="-C" +fi + +case "$1" in + start) + echo -n "Starting syslogd/klogd: " + start-stop-daemon -S -b -n syslogd -a /sbin/syslogd -- -n $SYSLOG_ARGS + start-stop-daemon -S -b -n klogd -a /sbin/klogd -- -n + echo "done" + ;; + stop) + echo -n "Stopping syslogd/klogd: " + start-stop-daemon -K -n syslogd + start-stop-daemon -K -n klogd + echo "done" + ;; + restart) + $0 stop + $0 start + ;; + *) + echo "Usage: syslog { start | stop | restart }" >&2 + exit 1 + ;; +esac + +exit 0 diff --git a/meta/packages/busybox/files/syslog.conf b/meta/packages/busybox/files/syslog.conf new file mode 100644 index 000000000..d4a0e02f5 --- /dev/null +++ b/meta/packages/busybox/files/syslog.conf @@ -0,0 +1,9 @@ +DESTINATION="buffer" # log destinations (buffer file remote) +MARKINT=20 # intervall between --mark-- entries +LOGFILE=/var/log/messages # where to log (file) +REMOTE=loghost:514 # where to log (syslog remote) +REDUCE=no # reduce-size logging +#ROTATESIZE=0 # rotate log if grown beyond X [kByte] (incompatible with busybox) +#ROTATEGENS=3 # keep X generations of rotated logs (incompatible with busybox) +BUFFERSIZE=64 # size of circular buffer [kByte] +FOREGROUND=no # run in foreground (don't use!) diff --git a/meta/packages/busybox/files/umount.busybox b/meta/packages/busybox/files/umount.busybox new file mode 100755 index 000000000..f3731626e --- /dev/null +++ b/meta/packages/busybox/files/umount.busybox @@ -0,0 +1,3 @@ +#!/bin/sh + +exec /bin/busybox umount $@ diff --git a/meta/packages/bzip2/bzip2-1.0.2/installpaths.patch b/meta/packages/bzip2/bzip2-1.0.2/installpaths.patch new file mode 100644 index 000000000..e7d09a71c --- /dev/null +++ b/meta/packages/bzip2/bzip2-1.0.2/installpaths.patch @@ -0,0 +1,103 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- bzip2-1.0.2/Makefile~installpaths ++++ bzip2-1.0.2/Makefile +@@ -12,8 +12,12 @@ + CFLAGS=-Wall -Winline -O2 -fomit-frame-pointer -fno-strength-reduce $(BIGFILES) + + # Where you want it installed when you do 'make install' +-PREFIX=/usr +- ++DESTDIR= ++prefix=/usr ++bindir=$(prefix)/bin ++mandir=$(prefix)/man ++includedir=$(prefix)/include ++libdir=$(prefix)/lib + + OBJS= blocksort.o \ + huffman.o \ +@@ -58,43 +62,43 @@ + @cat words3 + + install: bzip2 bzip2recover +- if ( test ! -d $(PREFIX)/bin ) ; then mkdir -p $(PREFIX)/bin ; fi +- if ( test ! -d $(PREFIX)/lib ) ; then mkdir -p $(PREFIX)/lib ; fi +- if ( test ! -d $(PREFIX)/man ) ; then mkdir -p $(PREFIX)/man ; fi +- if ( test ! -d $(PREFIX)/man/man1 ) ; then mkdir -p $(PREFIX)/man/man1 ; fi +- if ( test ! -d $(PREFIX)/include ) ; then mkdir -p $(PREFIX)/include ; fi +- cp -f bzip2 $(PREFIX)/bin/bzip2 +- cp -f bzip2 $(PREFIX)/bin/bunzip2 +- cp -f bzip2 $(PREFIX)/bin/bzcat +- cp -f bzip2recover $(PREFIX)/bin/bzip2recover +- chmod a+x $(PREFIX)/bin/bzip2 +- chmod a+x $(PREFIX)/bin/bunzip2 +- chmod a+x $(PREFIX)/bin/bzcat +- chmod a+x $(PREFIX)/bin/bzip2recover +- cp -f bzip2.1 $(PREFIX)/man/man1 +- chmod a+r $(PREFIX)/man/man1/bzip2.1 +- cp -f bzlib.h $(PREFIX)/include +- chmod a+r $(PREFIX)/include/bzlib.h +- cp -f libbz2.a $(PREFIX)/lib +- chmod a+r $(PREFIX)/lib/libbz2.a +- cp -f bzgrep $(PREFIX)/bin/bzgrep +- ln $(PREFIX)/bin/bzgrep $(PREFIX)/bin/bzegrep +- ln $(PREFIX)/bin/bzgrep $(PREFIX)/bin/bzfgrep +- chmod a+x $(PREFIX)/bin/bzgrep +- cp -f bzmore $(PREFIX)/bin/bzmore +- ln $(PREFIX)/bin/bzmore $(PREFIX)/bin/bzless +- chmod a+x $(PREFIX)/bin/bzmore +- cp -f bzdiff $(PREFIX)/bin/bzdiff +- ln $(PREFIX)/bin/bzdiff $(PREFIX)/bin/bzcmp +- chmod a+x $(PREFIX)/bin/bzdiff +- cp -f bzgrep.1 bzmore.1 bzdiff.1 $(PREFIX)/man/man1 +- chmod a+r $(PREFIX)/man/man1/bzgrep.1 +- chmod a+r $(PREFIX)/man/man1/bzmore.1 +- chmod a+r $(PREFIX)/man/man1/bzdiff.1 +- echo ".so man1/bzgrep.1" > $(PREFIX)/man/man1/bzegrep.1 +- echo ".so man1/bzgrep.1" > $(PREFIX)/man/man1/bzfgrep.1 +- echo ".so man1/bzmore.1" > $(PREFIX)/man/man1/bzless.1 +- echo ".so man1/bzdiff.1" > $(PREFIX)/man/man1/bzcmp.1 ++ if ( test ! -d $(DESTDIR)$(bindir) ) ; then mkdir -p $(DESTDIR)$(bindir) ; fi ++ if ( test ! -d $(DESTDIR)$(libdir) ) ; then mkdir -p $(DESTDIR)$(libdir) ; fi ++ if ( test ! -d $(DESTDIR)$(mandir) ) ; then mkdir -p $(DESTDIR)$(mandir) ; fi ++ if ( test ! -d $(DESTDIR)$(mandir)/man1 ) ; then mkdir -p $(DESTDIR)$(mandir)/man1 ; fi ++ if ( test ! -d $(DESTDIR)$(includedir) ) ; then mkdir -p $(DESTDIR)$(includedir) ; fi ++ cp -f bzip2 $(DESTDIR)$(bindir)/bzip2 ++ cp -f bzip2 $(DESTDIR)$(bindir)/bunzip2 ++ cp -f bzip2 $(DESTDIR)$(bindir)/bzcat ++ cp -f bzip2recover $(DESTDIR)$(bindir)/bzip2recover ++ chmod a+x $(DESTDIR)$(bindir)/bzip2 ++ chmod a+x $(DESTDIR)$(bindir)/bunzip2 ++ chmod a+x $(DESTDIR)$(bindir)/bzcat ++ chmod a+x $(DESTDIR)$(bindir)/bzip2recover ++ cp -f bzip2.1 $(DESTDIR)$(mandir)/man1 ++ chmod a+r $(DESTDIR)$(mandir)/man1/bzip2.1 ++ cp -f bzlib.h $(DESTDIR)$(includedir) ++ chmod a+r $(DESTDIR)$(includedir)/bzlib.h ++ cp -f libbz2.a $(DESTDIR)$(libdir) ++ chmod a+r $(DESTDIR)$(libdir)/libbz2.a ++ cp -f bzgrep $(DESTDIR)$(bindir)/bzgrep ++ ln $(DESTDIR)$(bindir)/bzgrep $(DESTDIR)$(bindir)/bzegrep ++ ln $(DESTDIR)$(bindir)/bzgrep $(DESTDIR)$(bindir)/bzfgrep ++ chmod a+x $(DESTDIR)$(bindir)/bzgrep ++ cp -f bzmore $(DESTDIR)$(bindir)/bzmore ++ ln $(DESTDIR)$(bindir)/bzmore $(DESTDIR)$(bindir)/bzless ++ chmod a+x $(DESTDIR)$(bindir)/bzmore ++ cp -f bzdiff $(DESTDIR)$(bindir)/bzdiff ++ ln $(DESTDIR)$(bindir)/bzdiff $(DESTDIR)$(bindir)/bzcmp ++ chmod a+x $(DESTDIR)$(bindir)/bzdiff ++ cp -f bzgrep.1 bzmore.1 bzdiff.1 $(DESTDIR)$(mandir)/man1 ++ chmod a+r $(DESTDIR)$(mandir)/man1/bzgrep.1 ++ chmod a+r $(DESTDIR)$(mandir)/man1/bzmore.1 ++ chmod a+r $(DESTDIR)$(mandir)/man1/bzdiff.1 ++ echo ".so man1/bzgrep.1" > $(DESTDIR)$(mandir)/man1/bzegrep.1 ++ echo ".so man1/bzgrep.1" > $(DESTDIR)$(mandir)/man1/bzfgrep.1 ++ echo ".so man1/bzmore.1" > $(DESTDIR)$(mandir)/man1/bzless.1 ++ echo ".so man1/bzdiff.1" > $(DESTDIR)$(mandir)/man1/bzcmp.1 + + distclean: clean + clean: diff --git a/meta/packages/bzip2/bzip2_1.0.2.bb b/meta/packages/bzip2/bzip2_1.0.2.bb new file mode 100644 index 000000000..1e1cb8e53 --- /dev/null +++ b/meta/packages/bzip2/bzip2_1.0.2.bb @@ -0,0 +1,41 @@ +DESCRIPTION = "Very high-quality data compression program." +SECTION = "console/utils" +PR = "r1" + +LICENSE = "bzip2" +SRC_URI = "ftp://sources.redhat.com/pub/bzip2/v102/bzip2-${PV}.tar.gz \ + file://installpaths.patch;patch=1" + +CFLAGS_append = " -fPIC -fpic -Winline -fno-strength-reduce -D_FILE_OFFSET_BITS=64" + +do_compile () { + oe_runmake -f Makefile-libbz2_so + ln -sf libbz2.so.1.0.2 libbz2.so.1.0 + ln -sf libbz2.so.1.0.2 libbz2.so.1 + ln -sf libbz2.so.1.0.2 libbz2.so + oe_runmake libbz2.a bzip2 bzip2recover +} + +do_stage () { + install -m 0644 bzlib.h ${STAGING_INCDIR}/ + oe_libinstall -a -so libbz2 ${STAGING_LIBDIR} +} + +do_install () { + oe_runmake 'DESTDIR=${D}' install + oe_libinstall -a -so libbz2 ${D}${libdir} + mv ${D}${bindir}/bunzip2 ${D}${bindir}/bunzip2.${PN} + mv ${D}${bindir}/bzcat ${D}${bindir}/bzcat.${PN} +} + + +pkg_postinst_${PN} () { + update-alternatives --install ${bindir}/bunzip2 bunzip2 bunzip2.${PN} 100 + update-alternatives --install ${bindir}/bzcat bzcat bzcat.${PN} 100 +} + + +pkg_prerm_${PN} () { + update-alternatives --remove bunzip2 bunzip2.${PN} + update-alternatives --remove bzcat bzcat.${PN} +} diff --git a/meta/packages/cairo/cairo_1.0.0.bb b/meta/packages/cairo/cairo_1.0.0.bb new file mode 100644 index 000000000..10603e3f2 --- /dev/null +++ b/meta/packages/cairo/cairo_1.0.0.bb @@ -0,0 +1,15 @@ +SECTION = "libs" +PRIORITY = "optional" +MAINTAINER = "Phil Blundell " +DEPENDS = "libx11 libpng fontconfig libxrender" +DESCRIPTION = "Cairo graphics library" +LICENSE = "MPL LGPL" +PR = "r1" + +SRC_URI = "http://cairographics.org/releases/cairo-${PV}.tar.gz" + +inherit autotools pkgconfig + +do_stage () { + autotools_stage_all +} diff --git a/meta/packages/cairo/cairo_1.0.4.bb b/meta/packages/cairo/cairo_1.0.4.bb new file mode 100644 index 000000000..61aefa91f --- /dev/null +++ b/meta/packages/cairo/cairo_1.0.4.bb @@ -0,0 +1,13 @@ +SECTION = "libs" +PRIORITY = "optional" +DEPENDS = "libx11 libpng fontconfig libxrender" +DESCRIPTION = "Cairo graphics library" +LICENSE = "MPL LGPL" + +SRC_URI = "http://cairographics.org/releases/cairo-${PV}.tar.gz" + +inherit autotools pkgconfig + +do_stage () { +autotools_stage_all +} diff --git a/meta/packages/cairo/cairo_1.2.0.bb b/meta/packages/cairo/cairo_1.2.0.bb new file mode 100644 index 000000000..10603e3f2 --- /dev/null +++ b/meta/packages/cairo/cairo_1.2.0.bb @@ -0,0 +1,15 @@ +SECTION = "libs" +PRIORITY = "optional" +MAINTAINER = "Phil Blundell " +DEPENDS = "libx11 libpng fontconfig libxrender" +DESCRIPTION = "Cairo graphics library" +LICENSE = "MPL LGPL" +PR = "r1" + +SRC_URI = "http://cairographics.org/releases/cairo-${PV}.tar.gz" + +inherit autotools pkgconfig + +do_stage () { + autotools_stage_all +} diff --git a/meta/packages/chkhinge26/chkhinge26_svn.bb b/meta/packages/chkhinge26/chkhinge26_svn.bb new file mode 100755 index 000000000..5313401b5 --- /dev/null +++ b/meta/packages/chkhinge26/chkhinge26_svn.bb @@ -0,0 +1,20 @@ +LICENSE = "LGPL" +SECTION = "x11" +MAINTAINER = "Matthew Allum " +DESCRIPTION = "Chkhinge26 fires off cmds on cXXXX Zs." +PR = "r2" + +SRC_URI = "svn://svn.o-hand.com/repos/misc/trunk;module=chkhinge26;proto=http \ + file://hinge-handler" + +S = "${WORKDIR}/${PN}" + +inherit autotools pkgconfig + +do_install_append () { + install -m 0755 ${WORKDIR}/hinge-handler ${D}/${bindir}/ +} + +FILES_${PN} += "${bindir}/hinge-handler" + + diff --git a/meta/packages/chkhinge26/files/hinge-handler b/meta/packages/chkhinge26/files/hinge-handler new file mode 100755 index 000000000..5d5f62e30 --- /dev/null +++ b/meta/packages/chkhinge26/files/hinge-handler @@ -0,0 +1,47 @@ +#!/bin/sh +# +# Quick handler for chkhinge26 and X. +# + +killproc() { # kill the named process(es) + pid=`/bin/ps -e x | + /bin/grep $1 | + /bin/grep -v grep | + /bin/sed -e 's/^ *//' -e 's/ .*//'` + [ "$pid" != "" ] && kill $pid +} + +export DISPLAY=:0 + +if [ -z "$1" ]; then + echo "Usage: hinge-handler ( 3 = closed, 0 = landscape, 2 = portrait )" + exit 1 +fi + +STATE=$1 + +if [ $STATE = "3" ]; then + echo "sleeping" + apm -s + exit 0 +fi + +if [ $STATE = "0" ]; then + echo "lanscape" + killproc /usr/bin/mbinputmgr +# urg mbinputmgr should kill below + killproc /usr/bin/matchbox-keyboard + killproc /usr/bin/matchbox-stroke + xrandr -o normal + exit 0 +fi + +if [ $STATE = "2" ]; then + echo "portrait" + xrandr -o left +# just to be extra safe + sleep 1 + /usr/bin/mbinputmgr & + exit 0 +fi + diff --git a/meta/packages/compositeext/compositeext_cvs.bb b/meta/packages/compositeext/compositeext_cvs.bb new file mode 100644 index 000000000..94160746e --- /dev/null +++ b/meta/packages/compositeext/compositeext_cvs.bb @@ -0,0 +1,20 @@ +PV = "0.0+cvs${SRCDATE}" +LICENSE= "BSD-X" +SECTION = "libs" +MAINTAINER = "Greg Gilbert " +DEPENDS = "xextensions fixesext" +DESCRIPTION = "X Composite extension headers and specification" +DEFAULT_PREFERENCE = "1" + +SRC_URI = "${FREEDESKTOP_CVS}/xlibs;module=CompositeExt" +S = "${WORKDIR}/CompositeExt" + +inherit autotools pkgconfig + +do_stage() { + oe_runmake install prefix=${STAGING_DIR} \ + bindir=${STAGING_BINDIR} \ + includedir=${STAGING_INCDIR} \ + libdir=${STAGING_LIBDIR} \ + datadir=${STAGING_DATADIR} +} diff --git a/meta/packages/console-tools/console-tools-0.3.2/codepage.patch b/meta/packages/console-tools/console-tools-0.3.2/codepage.patch new file mode 100644 index 000000000..f6bd91e3e --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/codepage.patch @@ -0,0 +1,16 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- console-tools-0.3.2/contrib/codepage.c~codepage ++++ console-tools-0.3.2/contrib/codepage.c +@@ -229,7 +229,7 @@ + return 0; + + fprintf(stderr, "\ +-Warning: CP format is a hack!\n ++Warning: CP format is a hack!\n\ + The files produced may or may not be usable!\n"); + + sprintf(outfile, "%d.cp", CPEntryHeader.codepage); diff --git a/meta/packages/console-tools/console-tools-0.3.2/compile.patch b/meta/packages/console-tools/console-tools-0.3.2/compile.patch new file mode 100644 index 000000000..29012fe88 --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/compile.patch @@ -0,0 +1,10 @@ +--- console-tools-0.3.2/kbdtools/showkey.c~compile 1999-08-25 17:20:08.000000000 -0400 ++++ console-tools-0.3.2/kbdtools/showkey.c 2004-05-09 03:03:23.000000000 -0400 +@@ -264,7 +264,6 @@ + break; + case cmd_keymap: + printf(")\n"); +- default: + } + } + diff --git a/meta/packages/console-tools/console-tools-0.3.2/config/codeset.m4 b/meta/packages/console-tools/console-tools-0.3.2/config/codeset.m4 new file mode 100644 index 000000000..863c9cfa7 --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/config/codeset.m4 @@ -0,0 +1,17 @@ +#serial AM1 + +dnl From Bruno Haible. + +AC_DEFUN([AM_LANGINFO_CODESET], +[ + AC_CACHE_CHECK([for nl_langinfo and CODESET], am_cv_langinfo_codeset, + [AC_TRY_LINK([#include ], + [char* cs = nl_langinfo(CODESET);], + am_cv_langinfo_codeset=yes, + am_cv_langinfo_codeset=no) + ]) + if test $am_cv_langinfo_codeset = yes; then + AC_DEFINE(HAVE_LANGINFO_CODESET, 1, + [Define if you have and nl_langinfo(CODESET).]) + fi +]) diff --git a/meta/packages/console-tools/console-tools-0.3.2/config/gettext.m4 b/meta/packages/console-tools/console-tools-0.3.2/config/gettext.m4 new file mode 100644 index 000000000..e4d524cf0 --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/config/gettext.m4 @@ -0,0 +1,370 @@ +# Macro to add for using GNU gettext. +# Ulrich Drepper , 1995. +# +# This file can be copied and used freely without restrictions. It can +# be used in projects which are not available under the GNU General Public +# License or the GNU Library General Public License but which still want +# to provide support for the GNU gettext functionality. +# Please note that the actual code of the GNU gettext library is covered +# by the GNU Library General Public License, and the rest of the GNU +# gettext package package is covered by the GNU General Public License. +# They are *not* in the public domain. + +# serial 10 + +dnl Usage: AM_WITH_NLS([TOOLSYMBOL], [NEEDSYMBOL], [LIBDIR]). +dnl If TOOLSYMBOL is specified and is 'use-libtool', then a libtool library +dnl $(top_builddir)/intl/libintl.la will be created (shared and/or static, +dnl depending on --{enable,disable}-{shared,static} and on the presence of +dnl AM-DISABLE-SHARED). Otherwise, a static library +dnl $(top_builddir)/intl/libintl.a will be created. +dnl If NEEDSYMBOL is specified and is 'need-ngettext', then GNU gettext +dnl implementations (in libc or libintl) without the ngettext() function +dnl will be ignored. +dnl LIBDIR is used to find the intl libraries. If empty, +dnl the value `$(top_builddir)/intl/' is used. +dnl +dnl The result of the configuration is one of three cases: +dnl 1) GNU gettext, as included in the intl subdirectory, will be compiled +dnl and used. +dnl Catalog format: GNU --> install in $(datadir) +dnl Catalog extension: .mo after installation, .gmo in source tree +dnl 2) GNU gettext has been found in the system's C library. +dnl Catalog format: GNU --> install in $(datadir) +dnl Catalog extension: .mo after installation, .gmo in source tree +dnl 3) No internationalization, always use English msgid. +dnl Catalog format: none +dnl Catalog extension: none +dnl The use of .gmo is historical (it was needed to avoid overwriting the +dnl GNU format catalogs when building on a platform with an X/Open gettext), +dnl but we keep it in order not to force irrelevant filename changes on the +dnl maintainers. +dnl +AC_DEFUN([AM_WITH_NLS], + [AC_MSG_CHECKING([whether NLS is requested]) + dnl Default is enabled NLS + AC_ARG_ENABLE(nls, + [ --disable-nls do not use Native Language Support], + USE_NLS=$enableval, USE_NLS=yes) + AC_MSG_RESULT($USE_NLS) + AC_SUBST(USE_NLS) + + BUILD_INCLUDED_LIBINTL=no + USE_INCLUDED_LIBINTL=no + INTLLIBS= + + dnl If we use NLS figure out what method + if test "$USE_NLS" = "yes"; then + AC_DEFINE(ENABLE_NLS, 1, + [Define to 1 if translation of program messages to the user's native language + is requested.]) + AC_MSG_CHECKING([whether included gettext is requested]) + AC_ARG_WITH(included-gettext, + [ --with-included-gettext use the GNU gettext library included here], + nls_cv_force_use_gnu_gettext=$withval, + nls_cv_force_use_gnu_gettext=no) + AC_MSG_RESULT($nls_cv_force_use_gnu_gettext) + + nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" + if test "$nls_cv_force_use_gnu_gettext" != "yes"; then + dnl User does not insist on using GNU NLS library. Figure out what + dnl to use. If GNU gettext is available we use this. Else we have + dnl to fall back to GNU NLS library. + CATOBJEXT=NONE + + dnl Add a version number to the cache macros. + define(gt_cv_func_gnugettext_libc, [gt_cv_func_gnugettext]ifelse([$2], need-ngettext, 2, 1)[_libc]) + define(gt_cv_func_gnugettext_libintl, [gt_cv_func_gnugettext]ifelse([$2], need-ngettext, 2, 1)[_libintl]) + + AC_CHECK_HEADER(libintl.h, + [AC_CACHE_CHECK([for GNU gettext in libc], gt_cv_func_gnugettext_libc, + [AC_TRY_LINK([#include +extern int _nl_msg_cat_cntr;], + [bindtextdomain ("", ""); +return (int) gettext ("")]ifelse([$2], need-ngettext, [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr], + gt_cv_func_gnugettext_libc=yes, + gt_cv_func_gnugettext_libc=no)]) + + if test "$gt_cv_func_gnugettext_libc" != "yes"; then + AC_CACHE_CHECK([for GNU gettext in libintl], + gt_cv_func_gnugettext_libintl, + [gt_save_LIBS="$LIBS" + LIBS="$LIBS -lintl $LIBICONV" + AC_TRY_LINK([#include +extern int _nl_msg_cat_cntr;], + [bindtextdomain ("", ""); +return (int) gettext ("")]ifelse([$2], need-ngettext, [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr], + gt_cv_func_gnugettext_libintl=yes, + gt_cv_func_gnugettext_libintl=no) + LIBS="$gt_save_LIBS"]) + fi + + dnl If an already present or preinstalled GNU gettext() is found, + dnl use it. But if this macro is used in GNU gettext, and GNU + dnl gettext is already preinstalled in libintl, we update this + dnl libintl. (Cf. the install rule in intl/Makefile.in.) + if test "$gt_cv_func_gnugettext_libc" = "yes" \ + || { test "$gt_cv_func_gnugettext_libintl" = "yes" \ + && test "$PACKAGE" != gettext; }; then + AC_DEFINE(HAVE_GETTEXT, 1, + [Define if the GNU gettext() function is already present or preinstalled.]) + + if test "$gt_cv_func_gnugettext_libintl" = "yes"; then + dnl If iconv() is in a separate libiconv library, then anyone + dnl linking with libintl{.a,.so} also needs to link with + dnl libiconv. + INTLLIBS="-lintl $LIBICONV" + fi + + gt_save_LIBS="$LIBS" + LIBS="$LIBS $INTLLIBS" + AC_CHECK_FUNCS(dcgettext) + LIBS="$gt_save_LIBS" + + dnl Search for GNU msgfmt in the PATH. + AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, + [$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1], :) + AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) + + dnl Search for GNU xgettext in the PATH. + AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, + [$ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1], :) + + CATOBJEXT=.gmo + fi + ]) + + if test "$CATOBJEXT" = "NONE"; then + dnl GNU gettext is not found in the C library. + dnl Fall back on GNU gettext library. + nls_cv_use_gnu_gettext=yes + fi + fi + + if test "$nls_cv_use_gnu_gettext" = "yes"; then + dnl Mark actions used to generate GNU NLS library. + INTLOBJS="\$(GETTOBJS)" + AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, + [$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1], :) + AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) + AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, + [$ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1], :) + AC_SUBST(MSGFMT) + BUILD_INCLUDED_LIBINTL=yes + USE_INCLUDED_LIBINTL=yes + CATOBJEXT=.gmo + INTLLIBS="ifelse([$3],[],\$(top_builddir)/intl,[$3])/libintl.ifelse([$1], use-libtool, [l], [])a $LIBICONV" + LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'` + fi + + dnl This could go away some day; the PATH_PROG_WITH_TEST already does it. + dnl Test whether we really found GNU msgfmt. + if test "$GMSGFMT" != ":"; then + dnl If it is no GNU msgfmt we define it as : so that the + dnl Makefiles still can work. + if $GMSGFMT --statistics /dev/null >/dev/null 2>&1; then + : ; + else + AC_MSG_RESULT( + [found msgfmt program is not GNU msgfmt; ignore it]) + GMSGFMT=":" + fi + fi + + dnl This could go away some day; the PATH_PROG_WITH_TEST already does it. + dnl Test whether we really found GNU xgettext. + if test "$XGETTEXT" != ":"; then + dnl If it is no GNU xgettext we define it as : so that the + dnl Makefiles still can work. + if $XGETTEXT --omit-header /dev/null >/dev/null 2>&1; then + : ; + else + AC_MSG_RESULT( + [found xgettext program is not GNU xgettext; ignore it]) + XGETTEXT=":" + fi + fi + + dnl We need to process the po/ directory. + POSUB=po + fi + AC_OUTPUT_COMMANDS( + [for ac_file in $CONFIG_FILES; do + # Support "outfile[:infile[:infile...]]" + case "$ac_file" in + *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; + esac + # PO directories have a Makefile.in generated from Makefile.in.in. + case "$ac_file" in */Makefile.in) + # Adjust a relative srcdir. + ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` + ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" + ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` + # In autoconf-2.13 it is called $ac_given_srcdir. + # In autoconf-2.50 it is called $srcdir. + test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" + case "$ac_given_srcdir" in + .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; + /*) top_srcdir="$ac_given_srcdir" ;; + *) top_srcdir="$ac_dots$ac_given_srcdir" ;; + esac + if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then + rm -f "$ac_dir/POTFILES" + test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" + sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," -e "\$s/\(.*\) \\\\/\1/" < "$ac_given_srcdir/$ac_dir/POTFILES.in" > "$ac_dir/POTFILES" + test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" + sed -e "/POTFILES =/r $ac_dir/POTFILES" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" + fi + ;; + esac + done]) + + + dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL + dnl to 'yes' because some of the testsuite requires it. + if test "$PACKAGE" = gettext; then + BUILD_INCLUDED_LIBINTL=yes + fi + + dnl intl/plural.c is generated from intl/plural.y. It requires bison, + dnl because plural.y uses bison specific features. It requires at least + dnl bison-1.26 because earlier versions generate a plural.c that doesn't + dnl compile. + dnl bison is only needed for the maintainer (who touches plural.y). But in + dnl order to avoid separate Makefiles or --enable-maintainer-mode, we put + dnl the rule in general Makefile. Now, some people carelessly touch the + dnl files or have a broken "make" program, hence the plural.c rule will + dnl sometimes fire. To avoid an error, defines BISON to ":" if it is not + dnl present or too old. + AC_CHECK_PROGS([INTLBISON], [bison]) + if test -z "$INTLBISON"; then + ac_verc_fail=yes + else + dnl Found it, now check the version. + AC_MSG_CHECKING([version of bison]) +changequote(<<,>>)dnl + ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'` + case $ac_prog_version in + '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; + 1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*) +changequote([,])dnl + ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; + *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; + esac + AC_MSG_RESULT([$ac_prog_version]) + fi + if test $ac_verc_fail = yes; then + INTLBISON=: + fi + + dnl These rules are solely for the distribution goal. While doing this + dnl we only have to keep exactly one list of the available catalogs + dnl in configure.in. + for lang in $ALL_LINGUAS; do + GMOFILES="$GMOFILES $lang.gmo" + POFILES="$POFILES $lang.po" + done + + dnl Make all variables we use known to autoconf. + AC_SUBST(BUILD_INCLUDED_LIBINTL) + AC_SUBST(USE_INCLUDED_LIBINTL) + AC_SUBST(CATALOGS) + AC_SUBST(CATOBJEXT) + AC_SUBST(GMOFILES) + AC_SUBST(INTLLIBS) + AC_SUBST(INTLOBJS) + AC_SUBST(POFILES) + AC_SUBST(POSUB) + + dnl For backward compatibility. Some configure.ins may be using this. + nls_cv_header_intl= + nls_cv_header_libgt= + + dnl For backward compatibility. Some Makefiles may be using this. + DATADIRNAME=share + AC_SUBST(DATADIRNAME) + + dnl For backward compatibility. Some Makefiles may be using this. + INSTOBJEXT=.mo + AC_SUBST(INSTOBJEXT) + + dnl For backward compatibility. Some Makefiles may be using this. + GENCAT=gencat + AC_SUBST(GENCAT) + ]) + +dnl Usage: Just like AM_WITH_NLS, which see. +AC_DEFUN([AM_GNU_GETTEXT], + [AC_REQUIRE([AC_PROG_MAKE_SET])dnl + AC_REQUIRE([AC_PROG_CC])dnl + AC_REQUIRE([AC_CANONICAL_HOST])dnl + AC_REQUIRE([AC_PROG_RANLIB])dnl + AC_REQUIRE([AC_ISC_POSIX])dnl + AC_REQUIRE([AC_HEADER_STDC])dnl + AC_REQUIRE([AC_C_CONST])dnl + AC_REQUIRE([AC_C_INLINE])dnl + AC_REQUIRE([AC_TYPE_OFF_T])dnl + AC_REQUIRE([AC_TYPE_SIZE_T])dnl + AC_REQUIRE([AC_FUNC_ALLOCA])dnl + AC_REQUIRE([AC_FUNC_MMAP])dnl + AC_REQUIRE([jm_GLIBC21])dnl + + AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ +stdlib.h string.h unistd.h sys/param.h]) + AC_CHECK_FUNCS([feof_unlocked fgets_unlocked getcwd getegid geteuid \ +getgid getuid mempcpy munmap putenv setenv setlocale stpcpy strchr strcasecmp \ +strdup strtoul tsearch __argz_count __argz_stringify __argz_next]) + + AM_ICONV + AM_LANGINFO_CODESET + AM_LC_MESSAGES + AM_WITH_NLS([$1],[$2],[$3]) + + if test "x$CATOBJEXT" != "x"; then + if test "x$ALL_LINGUAS" = "x"; then + LINGUAS= + else + AC_MSG_CHECKING(for catalogs to be installed) + NEW_LINGUAS= + for presentlang in $ALL_LINGUAS; do + useit=no + for desiredlang in ${LINGUAS-$ALL_LINGUAS}; do + # Use the presentlang catalog if desiredlang is + # a. equal to presentlang, or + # b. a variant of presentlang (because in this case, + # presentlang can be used as a fallback for messages + # which are not translated in the desiredlang catalog). + case "$desiredlang" in + "$presentlang"*) useit=yes;; + esac + done + if test $useit = yes; then + NEW_LINGUAS="$NEW_LINGUAS $presentlang" + fi + done + LINGUAS=$NEW_LINGUAS + AC_MSG_RESULT($LINGUAS) + fi + + dnl Construct list of names of catalog files to be constructed. + if test -n "$LINGUAS"; then + for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done + fi + fi + + dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly + dnl find the mkinstalldirs script in another subdir but $(top_srcdir). + dnl Try to locate is. + MKINSTALLDIRS= + if test -n "$ac_aux_dir"; then + MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" + fi + if test -z "$MKINSTALLDIRS"; then + MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" + fi + AC_SUBST(MKINSTALLDIRS) + + dnl Enable libtool support if the surrounding package wishes it. + INTL_LIBTOOL_SUFFIX_PREFIX=ifelse([$1], use-libtool, [l], []) + AC_SUBST(INTL_LIBTOOL_SUFFIX_PREFIX) + ]) diff --git a/meta/packages/console-tools/console-tools-0.3.2/config/glibc21.m4 b/meta/packages/console-tools/console-tools-0.3.2/config/glibc21.m4 new file mode 100644 index 000000000..5b88ef231 --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/config/glibc21.m4 @@ -0,0 +1,26 @@ +#serial 2 + +# Test for the GNU C Library, version 2.1 or newer. +# From Bruno Haible. + +AC_DEFUN([jm_GLIBC21], + [ + AC_CACHE_CHECK(whether we are using the GNU C Library 2.1 or newer, + ac_cv_gnu_library_2_1, + [AC_EGREP_CPP([Lucky GNU user], + [ +#include +#ifdef __GNU_LIBRARY__ + #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2) + Lucky GNU user + #endif +#endif + ], + ac_cv_gnu_library_2_1=yes, + ac_cv_gnu_library_2_1=no) + ] + ) + AC_SUBST(GLIBC21) + GLIBC21="$ac_cv_gnu_library_2_1" + ] +) diff --git a/meta/packages/console-tools/console-tools-0.3.2/config/iconv.m4 b/meta/packages/console-tools/console-tools-0.3.2/config/iconv.m4 new file mode 100644 index 000000000..17237344a --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/config/iconv.m4 @@ -0,0 +1,69 @@ +#serial AM2 + +dnl From Bruno Haible. + +AC_DEFUN([AM_ICONV], +[ + dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and + dnl those with the standalone portable GNU libiconv installed). + + AC_ARG_WITH([libiconv-prefix], +[ --with-libiconv-prefix=DIR search for libiconv in DIR/include and DIR/lib], [ + for dir in `echo "$withval" | tr : ' '`; do + if test -d $dir/include; then CPPFLAGS="$CPPFLAGS -I$dir/include"; fi + if test -d $dir/lib; then LDFLAGS="$LDFLAGS -L$dir/lib"; fi + done + ]) + + AC_CACHE_CHECK(for iconv, am_cv_func_iconv, [ + am_cv_func_iconv="no, consider installing GNU libiconv" + am_cv_lib_iconv=no + AC_TRY_LINK([#include +#include ], + [iconv_t cd = iconv_open("",""); + iconv(cd,NULL,NULL,NULL,NULL); + iconv_close(cd);], + am_cv_func_iconv=yes) + if test "$am_cv_func_iconv" != yes; then + am_save_LIBS="$LIBS" + LIBS="$LIBS -liconv" + AC_TRY_LINK([#include +#include ], + [iconv_t cd = iconv_open("",""); + iconv(cd,NULL,NULL,NULL,NULL); + iconv_close(cd);], + am_cv_lib_iconv=yes + am_cv_func_iconv=yes) + LIBS="$am_save_LIBS" + fi + ]) + if test "$am_cv_func_iconv" = yes; then + AC_DEFINE(HAVE_ICONV, 1, [Define if you have the iconv() function.]) + AC_MSG_CHECKING([for iconv declaration]) + AC_CACHE_VAL(am_cv_proto_iconv, [ + AC_TRY_COMPILE([ +#include +#include +extern +#ifdef __cplusplus +"C" +#endif +#if defined(__STDC__) || defined(__cplusplus) +size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); +#else +size_t iconv(); +#endif +], [], am_cv_proto_iconv_arg1="", am_cv_proto_iconv_arg1="const") + am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"]) + am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'` + AC_MSG_RESULT([$]{ac_t:- + }[$]am_cv_proto_iconv) + AC_DEFINE_UNQUOTED(ICONV_CONST, $am_cv_proto_iconv_arg1, + [Define as const if the declaration of iconv() needs const.]) + fi + LIBICONV= + if test "$am_cv_lib_iconv" = yes; then + LIBICONV="-liconv" + fi + AC_SUBST(LIBICONV) +]) diff --git a/meta/packages/console-tools/console-tools-0.3.2/config/lcmessage.m4 b/meta/packages/console-tools/console-tools-0.3.2/config/lcmessage.m4 new file mode 100644 index 000000000..18d47a94f --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/config/lcmessage.m4 @@ -0,0 +1,24 @@ +# Check whether LC_MESSAGES is available in . +# Ulrich Drepper , 1995. +# +# This file can be copied and used freely without restrictions. It can +# be used in projects which are not available under the GNU General Public +# License or the GNU Library General Public License but which still want +# to provide support for the GNU gettext functionality. +# Please note that the actual code of the GNU gettext library is covered +# by the GNU Library General Public License, and the rest of the GNU +# gettext package package is covered by the GNU General Public License. +# They are *not* in the public domain. + +# serial 2 + +AC_DEFUN([AM_LC_MESSAGES], + [if test $ac_cv_header_locale_h = yes; then + AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES, + [AC_TRY_LINK([#include ], [return LC_MESSAGES], + am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)]) + if test $am_cv_val_LC_MESSAGES = yes; then + AC_DEFINE(HAVE_LC_MESSAGES, 1, + [Define if your file defines LC_MESSAGES.]) + fi + fi]) diff --git a/meta/packages/console-tools/console-tools-0.3.2/config/progtest.m4 b/meta/packages/console-tools/console-tools-0.3.2/config/progtest.m4 new file mode 100644 index 000000000..35dc3da1f --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/config/progtest.m4 @@ -0,0 +1,51 @@ +# Search path for a program which passes the given test. +# Ulrich Drepper , 1996. +# +# This file can be copied and used freely without restrictions. It can +# be used in projects which are not available under the GNU General Public +# License or the GNU Library General Public License but which still want +# to provide support for the GNU gettext functionality. +# Please note that the actual code of the GNU gettext library is covered +# by the GNU Library General Public License, and the rest of the GNU +# gettext package package is covered by the GNU General Public License. +# They are *not* in the public domain. + +# serial 2 + +dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, +dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) +AC_DEFUN([AM_PATH_PROG_WITH_TEST], +[# Extract the first word of "$2", so it can be a program name with args. +set dummy $2; ac_word=[$]2 +AC_MSG_CHECKING([for $ac_word]) +AC_CACHE_VAL(ac_cv_path_$1, +[case "[$]$1" in + /*) + ac_cv_path_$1="[$]$1" # Let the user override the test with a path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in ifelse([$5], , $PATH, [$5]); do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if [$3]; then + ac_cv_path_$1="$ac_dir/$ac_word" + break + fi + fi + done + IFS="$ac_save_ifs" +dnl If no 4th arg is given, leave the cache variable unset, +dnl so AC_PATH_PROGS will keep looking. +ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" +])dnl + ;; +esac])dnl +$1="$ac_cv_path_$1" +if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then + AC_MSG_RESULT([$]$1) +else + AC_MSG_RESULT(no) +fi +AC_SUBST($1)dnl +]) diff --git a/meta/packages/console-tools/console-tools-0.3.2/configure.patch b/meta/packages/console-tools/console-tools-0.3.2/configure.patch new file mode 100644 index 000000000..f5b75327e --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/configure.patch @@ -0,0 +1,46 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- console-tools-0.3.2/configure.in~configure ++++ console-tools-0.3.2/configure.in +@@ -2,13 +2,14 @@ + dnl Process this file with autoconf to produce a configure script. + + # Initialize +-AC_INIT(kbdtools/loadkeys.y) ++AC_INIT ++AC_CONFIG_SRCDIR([kbdtools/loadkeys.y]) + + define(ct_unicodedata_default,/usr/share/unidata/UnicodeData-2.txt) + ct_localdatadir_default=/usr/local/share # iff --enable-localdatadir without specific dir + + #AC_CONFIG_AUX_DIR(autoconf) +-AC_CANONICAL_SYSTEM ++AC_CANONICAL_TARGET([]) + AM_INIT_AUTOMAKE(console-tools, 0.3.2) + + # Defaults +@@ -25,7 +26,7 @@ + # i18n stuff + ALL_LINGUAS="cs de ru ga fr" + AM_GNU_GETTEXT +-AC_OUTPUT_COMMANDS([sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile]) ++AC_CONFIG_COMMANDS([default-1],[[sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile]],[[]]) + + AC_DEFINE_UNQUOTED(LOCALEDIR, "/usr/share/locale") + +@@ -172,10 +173,11 @@ + AC_SUBST(CHARMAPDIR) + + # Output +-AC_OUTPUT([Makefile lib/Makefile lib/console/Makefile lib/cfont/Makefile ++AC_CONFIG_FILES([Makefile lib/Makefile lib/console/Makefile lib/cfont/Makefile + lib/ctutils/Makefile lib/ctlocal/Makefile lib/generic/Makefile + fontfiletools/Makefile vttools/Makefile + kbdtools/Makefile screenfonttools/Makefile contrib/Makefile + include/Makefile include/lct/Makefile compat/Makefile + doc/Makefile doc/man/Makefile examples/Makefile + po/Makefile.in intl/Makefile]) ++AC_OUTPUT diff --git a/meta/packages/console-tools/console-tools-0.3.2/kbdrate.patch b/meta/packages/console-tools/console-tools-0.3.2/kbdrate.patch new file mode 100644 index 000000000..47d7ea54b --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/kbdrate.patch @@ -0,0 +1,73 @@ +Patch from Matthias Goebl +Added via OE bugtracker: bug #478 + +--- console-tools-0.3.2/kbdtools/kbd_mode.c.orig ++++ console-tools-0.3.2/kbdtools/kbd_mode.c +@@ -29,11 +29,16 @@ + OPT("-u --unicode ", _("UTF-8 mode (UNICODE)")); + OPT("-s --scancode ", _("scancode mode (RAW)")); + OPT(" --mode={8bit,keycode,unicode,scancode} ", _("set mode")); ++ OPT("-r --rate=RATE ", _("set repeat rate (default: 33)")); ++ OPT("-d --delay=DELAY ", _("set repeat delay (default: 250)")); + + OPT("-h --help ", HELPDESC); + OPT("-V --version ", VERSIONDESC); + } + ++int rate=-1; ++int delay=-1; ++ + static int parse_cmdline (int argc, char *argv[]) + { + int mode = -1; +@@ -46,11 +51,13 @@ + { "mode" , required_argument, NULL, 'm' }, + { "scancode" , no_argument, NULL, 's' }, + { "unicode" , no_argument, NULL, 'u' }, ++ { "rate" , required_argument, NULL, 'r' }, ++ { "delay" , required_argument, NULL, 'd' }, + { NULL, 0, NULL, 0 } + }; + int c; + +- while ( (c = getopt_long (argc, argv, "Vhaksu", long_opts, NULL)) != EOF) ++ while ( (c = getopt_long (argc, argv, "Vhaksur:d:", long_opts, NULL)) != EOF) + switch (c) { + case 'h': + usage (); +@@ -58,6 +65,14 @@ + case 'V': + version (); + exit(0); ++ case 'r': ++ rate = atoi(optarg); ++ mode = -2; ++ break; ++ case 'd': ++ delay = atoi(optarg); ++ mode = -2; ++ break; + case 'a': + mode = K_XLATE; + break; +@@ -129,6 +144,20 @@ + exit(0); + } + ++ if ( rate != -1 || delay != -1 ) ++ { ++ struct kbd_repeat kbd_rep; ++ kbd_rep.delay = delay; ++ kbd_rep.period = rate; ++ if (ioctl(fd, KDKBDREP, &kbd_rep)) ++ { ++ fprintf(stderr, progname); ++ perror(_(": error setting keyboard repeat mode\n")); ++ exit(1); ++ } ++ if(mode==-2) exit(0); ++ } ++ + if (ioctl(fd, KDSKBMODE, mode)) + { + fprintf(stderr, progname); diff --git a/meta/packages/console-tools/console-tools-0.3.2/uclibc-fileno.patch b/meta/packages/console-tools/console-tools-0.3.2/uclibc-fileno.patch new file mode 100644 index 000000000..c73d8a3d9 --- /dev/null +++ b/meta/packages/console-tools/console-tools-0.3.2/uclibc-fileno.patch @@ -0,0 +1,47 @@ +Fixing the locale issues isn't enough, console-tools also does a couple of +other pretty stupid things (like FILE *f; f->_fileno instead of fileno(f)), + +--- console-tools-0.3.2/lib/cfont/fontstruct.c.ark 2005-05-22 19:12:38.000000000 +0000 ++++ console-tools-0.3.2/lib/cfont/fontstruct.c 2005-05-22 19:13:23.000000000 +0000 +@@ -50,8 +50,7 @@ + * get filesize + */ + +- /* FIXME: should not use _fileno ! */ +- if (fstat(fontfile->_fileno, &stbuf) == -1) ++ if (fstat(fileno(fontfile), &stbuf) == -1) + goto rsf_return_error; + + if (S_ISREG(stbuf.st_mode)) +@@ -211,8 +210,7 @@ + * get filesize + */ + +- /* FIXME: should not use _fileno ! */ +- if (fstat(fontfile->_fileno, &stbuf) == -1) ++ if (fstat(fileno(fontfile), &stbuf) == -1) + goto rfg_return_error; + + if (S_ISREG(stbuf.st_mode)) +--- console-tools-0.3.2/lib/console/acm.c.ark 2005-05-22 19:17:15.000000000 +0000 ++++ console-tools-0.3.2/lib/console/acm.c 2005-05-22 19:17:23.000000000 +0000 +@@ -30,7 +30,7 @@ + lct_boolean parse_failed = False; + lct_boolean is_unicode; + +- if (fstat(fp->_fileno, &stbuf)) ++ if (fstat(fileno(fp), &stbuf)) + perror(_("Cannot stat ACM file")), exit(1); + + /* first try a wg15-charmap (glibc) file format */ +--- console-tools-0.3.2/include/lct/local.h.ark 2005-05-22 19:08:54.000000000 +0000 ++++ console-tools-0.3.2/include/lct/local.h 2005-05-22 19:09:12.000000000 +0000 +@@ -8,7 +8,7 @@ + #include + + +-#ifdef HAVE_LOCALE_H ++#if defined(HAVE_LOCALE_H) && defined(HAVE_LIBINTL_H) + # include + # define _(String) gettext (String) + # ifdef gettext_noop diff --git a/meta/packages/console-tools/console-tools_0.3.2.bb b/meta/packages/console-tools/console-tools_0.3.2.bb new file mode 100644 index 000000000..01c2e42a3 --- /dev/null +++ b/meta/packages/console-tools/console-tools_0.3.2.bb @@ -0,0 +1,48 @@ +SECTION = "base" +LICENSE = "GPL" +DESCRIPTION = "Allows you to set-up and manipulate the Linux console." +PR = "r2" + +SRC_URI = "${SOURCEFORGE_MIRROR}/lct/console-tools-${PV}.tar.gz \ + file://codepage.patch;patch=1 \ + file://configure.patch;patch=1 \ + file://compile.patch;patch=1 \ + file://kbdrate.patch;patch=1 \ + file://uclibc-fileno.patch;patch=1 \ + file://config/*.m4" + +export SUBDIRS = "fontfiletools vttools kbdtools screenfonttools contrib \ + examples po intl compat" + +acpaths = "-I config" +do_configure_prepend () { + mkdir -p config + cp ${WORKDIR}/config/*.m4 config/ +} + +do_compile () { + oe_runmake -C lib + oe_runmake 'SUBDIRS=${SUBDIRS}' +} + +inherit autotools + +do_install () { + autotools_do_install + mv ${D}${bindir}/chvt ${D}${bindir}/chvt.${PN} + mv ${D}${bindir}/deallocvt ${D}${bindir}/deallocvt.${PN} + mv ${D}${bindir}/openvt ${D}${bindir}/openvt.${PN} +} + +pkg_postinst_${PN} () { + update-alternatives --install ${bindir}/chvt chvt chvt.${PN} 100 + update-alternatives --install ${bindir}/deallocvt deallocvt deallocvt.${PN} 100 + update-alternatives --install ${bindir}/openvt openvt openvt.${PN} 100 +} + +pkg_prerm_${PN} () { + update-alternatives --remove chvt chvt.${PN} + update-alternatives --remove deallocvt deallocvt.${PN} + update-alternatives --remove openvt openvt.${PN} +} + diff --git a/meta/packages/contacts/contacts_0.1.bb b/meta/packages/contacts/contacts_0.1.bb new file mode 100755 index 000000000..cf025259f --- /dev/null +++ b/meta/packages/contacts/contacts_0.1.bb @@ -0,0 +1,24 @@ +LICENSE = "LGPL" +SECTION = "x11" +DEPENDS = "glib-2.0 gtk+ libglade eds-dbus" +MAINTAINER = "Chris Lord " +DESCRIPTION = "Contacts is an address-book application." +PR = "r1" + +SRC_URI = "svn://svn.o-hand.com/repos/${PN}/tags;module=release-0.1;proto=http \ + file://stock_contact.png \ + file://stock_person.png" + +inherit autotools pkgconfig + +S = "${WORKDIR}/release-0.1" + +do_install_append () { + install -d ${D}/${datadir}/pixmaps + install -m 0644 ${WORKDIR}/stock_contact.png ${D}/${datadir}/pixmaps + install -m 0644 ${WORKDIR}/stock_person.png ${D}/${datadir}/pixmaps +} + +FILES_${PN} += "${datadir}/pixmaps/stock_contact.png \ + ${datadir}/pixmaps/stock_person.png" + diff --git a/meta/packages/contacts/contacts_svn.bb b/meta/packages/contacts/contacts_svn.bb new file mode 100755 index 000000000..cd4f6a783 --- /dev/null +++ b/meta/packages/contacts/contacts_svn.bb @@ -0,0 +1,30 @@ +LICENSE = "LGPL" +SECTION = "x11" +DEPENDS = "glib-2.0 gtk+ libglade eds-dbus gnome-vfs" +RDEPENDS = "gnome-vfs-plugin-file" +RRECOMMENDS = "gnome-vfs-plugin-http" +MAINTAINER = "Chris Lord " +DESCRIPTION = "Contacts is an address-book application." +PR = "r5" + +PV = "0.1+svn${SRCDATE}" + +SRC_URI = "svn://svn.o-hand.com/repos/${PN};module=trunk;proto=http \ + file://stock_contact.png \ + file://stock_person.png" + +inherit autotools pkgconfig + +S = "${WORKDIR}/trunk" + +EXTRA_OECONF = "--enable-gnome-vfs" + +do_install_append () { + install -d ${D}/${datadir}/pixmaps + install -m 0644 ${WORKDIR}/stock_contact.png ${D}/${datadir}/pixmaps + install -m 0644 ${WORKDIR}/stock_person.png ${D}/${datadir}/pixmaps +} + +FILES_${PN} += "${datadir}/pixmaps/stock_contact.png \ + ${datadir}/pixmaps/stock_person.png" + diff --git a/meta/packages/contacts/files/stock_contact.png b/meta/packages/contacts/files/stock_contact.png new file mode 100644 index 000000000..123b4485a Binary files /dev/null and b/meta/packages/contacts/files/stock_contact.png differ diff --git a/meta/packages/contacts/files/stock_person.png b/meta/packages/contacts/files/stock_person.png new file mode 100644 index 000000000..2b1328b4e Binary files /dev/null and b/meta/packages/contacts/files/stock_person.png differ diff --git a/meta/packages/coreutils/coreutils-5.1.3/install-cross.patch b/meta/packages/coreutils/coreutils-5.1.3/install-cross.patch new file mode 100644 index 000000000..98ba3d916 --- /dev/null +++ b/meta/packages/coreutils/coreutils-5.1.3/install-cross.patch @@ -0,0 +1,27 @@ +--- src/install.c~ 2003-08-09 18:46:45.000000000 +0100 ++++ src/install.c 2004-03-27 18:38:45.000000000 +0000 +@@ -516,7 +516,14 @@ + strip (const char *path) + { + int status; +- pid_t pid = fork (); ++ pid_t pid; ++ char *strip_name; ++ ++ strip_name = getenv ("STRIP"); ++ if (strip_name == NULL) ++ strip_name = "strip"; ++ ++ pid = fork (); + + switch (pid) + { +@@ -524,7 +531,7 @@ + error (EXIT_FAILURE, errno, _("fork system call failed")); + break; + case 0: /* Child. */ +- execlp ("strip", "strip", path, NULL); ++ execlp (strip_name, "strip", path, NULL); + error (EXIT_FAILURE, errno, _("cannot run strip")); + break; + default: /* Parent. */ diff --git a/meta/packages/coreutils/coreutils-5.1.3/man.patch b/meta/packages/coreutils/coreutils-5.1.3/man.patch new file mode 100644 index 000000000..b067c380e --- /dev/null +++ b/meta/packages/coreutils/coreutils-5.1.3/man.patch @@ -0,0 +1,42 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- coreutils-5.1.3/configure.ac~man 2004-01-25 16:57:15.000000000 -0600 ++++ coreutils-5.1.3/configure.ac 2004-06-29 14:22:10.000000000 -0500 +@@ -232,6 +232,20 @@ + AM_GNU_GETTEXT([external], [need-ngettext]) + AM_GNU_GETTEXT_VERSION(0.13.1) + ++AC_MSG_CHECKING([whether to build man pages]) ++AC_ARG_WITH(manpages, ++ AS_HELP_STRING([--with-manpages], ++ [Enable building of manpages (default=yes)]), ++ [cu_cv_build_manpages=$enableval], ++ [cu_cv_build_manpages=yes]) ++# help2man doesn't work when crosscompiling, as it needs to run the ++# binary that was built. ++if test x"$cross_compiling" = x"yes"; then ++ cu_cv_build_manpages=no ++fi ++AC_MSG_RESULT($cu_cv_build_manpages) ++AM_CONDITIONAL(ENABLE_MANPAGES, test x"$cu_cv_build_manpages" = x"yes") ++ + AC_CONFIG_FILES( + Makefile + doc/Makefile +--- coreutils-5.1.3/Makefile.am~man 2003-11-09 14:23:02.000000000 -0600 ++++ coreutils-5.1.3/Makefile.am 2004-06-29 14:18:14.000000000 -0500 +@@ -1,6 +1,11 @@ + ## Process this file with automake to produce Makefile.in -*-Makefile-*- + ++if ENABLE_MANPAGES + SUBDIRS = lib src doc man m4 po tests ++else ++SUBDIRS = lib src doc m4 po tests ++endif ++ + EXTRA_DIST = Makefile.cfg Makefile.maint GNUmakefile \ + .kludge-stamp .prev-version THANKS-to-translators THANKStt.in \ + .x-sc_space_tab .x-sc_sun_os_names \ diff --git a/meta/packages/coreutils/coreutils-native_5.1.3.bb b/meta/packages/coreutils/coreutils-native_5.1.3.bb new file mode 100644 index 000000000..74b39541f --- /dev/null +++ b/meta/packages/coreutils/coreutils-native_5.1.3.bb @@ -0,0 +1,7 @@ +SECTION = "base" + +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/coreutils-${PV}" +S = "${WORKDIR}/coreutils-${PV}" + +include coreutils_${PV}.bb +inherit native diff --git a/meta/packages/coreutils/coreutils_5.1.3.bb b/meta/packages/coreutils/coreutils_5.1.3.bb new file mode 100644 index 000000000..31af80907 --- /dev/null +++ b/meta/packages/coreutils/coreutils_5.1.3.bb @@ -0,0 +1,85 @@ +LICENSE = "GPL" +SECTION = "base" +DESCRIPTION = "A collection of core GNU utilities." +RREPLACES = "textutils shellutils fileutils" +RPROVIDES = "textutils shellutils fileutils" +PR = "r7" + +SRC_URI = "ftp://alpha.gnu.org/gnu/coreutils/coreutils-${PV}.tar.bz2 \ + file://install-cross.patch;patch=1;pnum=0 \ + file://man.patch;patch=1" + +inherit autotools + +# [ gets a special treatment and is not included in this +bindir_progs = "basename cksum comm csplit cut dir dircolors dirname du \ + env expand expr factor fmt fold groups head hostid id install \ + join link logname md5sum mkfifo nice nl nohup od paste pathchk \ + pinky pr printenv printf ptx readlink seq sha1sum shred sort \ + split stat sum tac tail tee test tr tsort tty unexpand uniq \ + unlink users vdir wc who whoami yes \ + " + +# hostname gets a special treatment and is not included in this +base_bindir_progs = "cat chgrp chmod chown cp date dd echo false kill \ + ln ls mkdir mknod mv pwd rm rmdir sleep stty sync touch \ + true uname \ + " + +sbindir_progs= "chroot" + +do_install () { + autotools_do_install + + # Renaming the utilities that should go in /usr/bin + for i in ${bindir_progs}; do mv ${D}${bindir}/$i ${D}${bindir}/$i.${PN}; done + + # Renaming and moving the utilities that should go in /bin (FHS) + install -d ${D}${base_bindir} + for i in ${base_bindir_progs}; do mv ${D}${bindir}/$i ${D}${base_bindir}/$i.${PN}; done + + # Renaming and moving the utilities that should go in /usr/sbin (FHS) + install -d ${D}${sbindir} + for i in ${sbindir_progs}; do mv ${D}${bindir}/$i ${D}${sbindir}/$i.${PN}; done + + # [ requires special handling because [.coreutils will cause the sed stuff + # in update-alternatives to fail, therefore use lbracket - the name used + # for the actual source file. + mv ${D}${bindir}/[ ${D}${bindir}/lbracket.${PN} + # hostname and uptime separated. busybox's versions are preferred + mv ${D}${bindir}/hostname ${D}${base_bindir}/hostname.${PN} + mv ${D}${bindir}/uptime ${D}${bindir}/uptime.${PN} + +} + +pkg_postinst_${PN} () { + # The utilities in /usr/bin + for i in ${bindir_progs}; do update-alternatives --install ${bindir}/$i $i $i.${PN} 100; done + + # The utilities in /bin + for i in ${base_bindir_progs}; do update-alternatives --install ${base_bindir}/$i $i $i.${PN} 100; done + + # The utilities in /usr/sbin + for i in ${sbindir_progs}; do update-alternatives --install ${sbindir}/$i $i $i.${PN} 100; done + + # Special cases. uptime and hostname is broken, prefer busybox's version. [ needs to be treated separately. + update-alternatives --install ${bindir}/uptime uptime uptime.${PN} 10 + update-alternatives --install ${base_bindir}/hostname hostname hostname.${PN} 10 + update-alternatives --install '${bindir}/[' '[' 'lbracket.${PN}' 100 +} + +pkg_prerm_${PN} () { + # The utilities in /usr/bin + for i in ${bindir_progs}; do update-alternatives --remove $i $i.${PN}; done + + # The utilities in /bin + for i in ${base_bindir_progs}; do update-alternatives --remove $i $i.${PN}; done + + # The utilities in /usr/sbin + for i in ${sbindir_progs}; do update-alternatives --remove $i $i.${PN}; done + + # The special cases + update-alternatives --remove hostname hostname.${PN} + update-alternatives --remove uptime uptime.${PN} + update-alternatives --remove '[' 'lbracket.${PN}' +} diff --git a/meta/packages/curl/curl-native_7.14.0.bb b/meta/packages/curl/curl-native_7.14.0.bb new file mode 100644 index 000000000..59af4ef32 --- /dev/null +++ b/meta/packages/curl/curl-native_7.14.0.bb @@ -0,0 +1,13 @@ +include curl_${PV}.bb +inherit native + +do_stage () { + install -d ${STAGING_INCDIR}/curl + install -m 0644 ${S}/include/curl/*.h ${STAGING_INCDIR}/curl/ + oe_libinstall -so -a -C lib libcurl ${STAGING_LIBDIR} +} + +do_install() { + : +} + diff --git a/meta/packages/curl/curl_7.14.0.bb b/meta/packages/curl/curl_7.14.0.bb new file mode 100644 index 000000000..b163e955f --- /dev/null +++ b/meta/packages/curl/curl_7.14.0.bb @@ -0,0 +1,38 @@ +DESCRIPTION = "Command line tool and library for client-side URL transfers." +LICENSE = "MIT" +DEPENDS = "zlib" +SECTION = "console/network" +RPROVIDES_lib${PN} += "libcurl" + +SRC_URI = "http://curl.haxx.se/download/curl-${PV}.tar.bz2" +S = "${WORKDIR}/curl-${PV}" + +inherit autotools pkgconfig binconfig + +EXTRA_OECONF = "--with-zlib=${STAGING_LIBDIR}/../ \ + --without-ssl \ + --with-random=/dev/urandom \ + --without-idn \ + --enable-http \ + --enable-file" + +do_stage () { + install -d ${STAGING_INCDIR}/curl + install -m 0644 ${S}/include/curl/*.h ${STAGING_INCDIR}/curl/ + oe_libinstall -so -a -C lib libcurl ${STAGING_LIBDIR} +} + +PACKAGES = "curl curl-doc libcurl libcurl-dev libcurl-doc" +FILES_${PN} = "${bindir}/curl" +FILES_${PN}-doc = "${mandir}/man1/curl.1" +FILES_lib${PN} = "${libdir}/lib*.so.*" +FILES_lib${PN}-dev = "${includedir} \ + ${libdir}/lib*.so \ + ${libdir}/lib*.a \ + ${libdir}/lib*.la \ + ${libdir}/pkgconfig \ + ${datadir}/aclocal \ + ${bindir}/*-config" +FILES_lib${PN}-doc = "${mandir}/man3 \ + ${mandir}/man1/curl-config.1" + diff --git a/meta/packages/damageext/damageext-1.0/autofoo.patch b/meta/packages/damageext/damageext-1.0/autofoo.patch new file mode 100644 index 000000000..e36fb1d74 --- /dev/null +++ b/meta/packages/damageext/damageext-1.0/autofoo.patch @@ -0,0 +1,18 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- damageext-1.0/configure.ac~autofoo 2003-11-25 22:47:58.000000000 -0500 ++++ damageext-1.0/configure.ac 2005-01-16 11:47:08.123775952 -0500 +@@ -25,9 +25,9 @@ + + AC_PREREQ([2.57]) + AC_INIT([damageext], [1.0], [keithp@keithp.com], damageext) ++AC_CONFIG_AUX_DIR(.) + AM_INIT_AUTOMAKE([dist-bzip2]) + AM_MAINTAINER_MODE +-AC_CONFIG_AUX_DIR(.) + + PKG_CHECK_MODULES(FIXESEXT, fixesext) + diff --git a/meta/packages/damageext/damageext_cvs.bb b/meta/packages/damageext/damageext_cvs.bb new file mode 100644 index 000000000..86a6032b2 --- /dev/null +++ b/meta/packages/damageext/damageext_cvs.bb @@ -0,0 +1,20 @@ +PV = "0.0+cvs${SRCDATE}" +LICENSE = "MIT-X" +SECTION = "libs" +MAINTAINER = "Greg Gilbert " +DEPENDS = "xextensions fixesext" +DESCRIPTION = "X Damage extension headers and specification" +PR = "r1" + +SRC_URI = "${FREEDESKTOP_CVS}/xlibs;module=DamageExt" +S = "${WORKDIR}/DamageExt" + +inherit autotools pkgconfig + +do_stage() { + oe_runmake install prefix=${STAGING_DIR} \ + bindir=${STAGING_BINDIR} \ + includedir=${STAGING_INCDIR} \ + libdir=${STAGING_LIBDIR} \ + datadir=${STAGING_DATADIR} +} diff --git a/meta/packages/dates/dates_0.1.bb b/meta/packages/dates/dates_0.1.bb new file mode 100755 index 000000000..b13fb0190 --- /dev/null +++ b/meta/packages/dates/dates_0.1.bb @@ -0,0 +1,19 @@ +LICENSE = "LGPL" +SECTION = "x11" +DEPENDS = "glib-2.0 gtk+ libglade eds-dbus" +MAINTAINER = "Chris Lord " +DESCRIPTION = "Dates is a calendar application." + +SRC_URI = "http://projects.o-hand.com/sources/dates/dates-0.1.tar.gz" + +inherit autotools pkgconfig gtk-icon-cache + +# EXTRA_OECONF = "--disable-debug" + +FILES_${PN} += "${datadir}/pixmaps/dates.png" + +do_install_append () { + install -d ${D}/${datadir}/pixmaps + install -m 0644 ${D}/${datadir}/icons/hicolor/48x48/apps/dates.png ${D}/${datadir}/pixmaps/ +} + diff --git a/meta/packages/dates/dates_svn.bb b/meta/packages/dates/dates_svn.bb new file mode 100755 index 000000000..408ba5da5 --- /dev/null +++ b/meta/packages/dates/dates_svn.bb @@ -0,0 +1,19 @@ +LICENSE = "LGPL" +SECTION = "x11" +DEPENDS = "glib-2.0 gtk+ libglade eds-dbus" +MAINTAINER = "Chris Lord " +DESCRIPTION = "Dates is a calendar application." + +PV = "0.1+svn${SRCDATE}" +S = "${WORKDIR}/trunk" + +SRC_URI = "svn://svn.o-hand.com/repos/${PN};module=trunk;proto=http" + +inherit autotools pkgconfig gtk-icon-cache + +FILES_${PN} += "${datadir}/pixmaps/dates.png" + +do_install_append () { + install -d ${D}/${datadir}/pixmaps + install -m 0644 ${D}/${datadir}/icons/hicolor/48x48/apps/dates.png ${D}/${datadir}/pixmaps/ +} diff --git a/meta/packages/db/db-native_4.2.52.bb b/meta/packages/db/db-native_4.2.52.bb new file mode 100644 index 000000000..5aaeb4329 --- /dev/null +++ b/meta/packages/db/db-native_4.2.52.bb @@ -0,0 +1,13 @@ +# This wrapper builds a native version of the SleepyCat +# Berkeley DB for those packages which need it (e.g. +# perl). +SECTION = "libs" +VIRTUAL_NAME = "virtual/db-native" +CONFLICTS = "db3-native" +#PR tracks the non-native package + +inherit native + +include db_${PV}.bb + +PACKAGES = "" diff --git a/meta/packages/db/db_4.1.25.bb b/meta/packages/db/db_4.1.25.bb new file mode 100644 index 000000000..381c69a61 --- /dev/null +++ b/meta/packages/db/db_4.1.25.bb @@ -0,0 +1,87 @@ +# Version 4 of the Berkeley DB from Sleepycat +# +# At present this package only installs the DB code +# itself (shared libraries, .a in the dev package), +# documentation and headers. +# +# The headers have the same names as those as v3 +# of the DB, only one version can be used *for dev* +# at once - DB3 and DB4 can both be installed on the +# same system at the same time if really necessary. +SECTION = "libs" +DESCRIPTION = "Berkeley DB v4." +HOMEPAGE = "http://www.sleepycat.com" +LICENSE = "BSD Sleepycat" +PR = "r2" + +SRC_URI = "http://downloads.sleepycat.com/${P}.tar.gz" + +inherit autotools + +# At present virtual/db is only in the db4 file, but it +# should probably be in the other candidates (db3, gdbm) +# because it doesn't make any sense to have multiple +# relational databases on an embedded machine... +PROVIDES += " db4 virtual/db" + +# bitbake isn't quite clever enough to deal with sleepycat, +# the distribution sits in the expected directory, but all +# the builds must occur from a sub-directory. The following +# persuades bitbake to go to the right place +S = "${WORKDIR}/${P}/build_unix" + +# The executables go in a separate package - typically there +# is no need to install these unless doing real database +# management on the system. +PACKAGES += " ${PN}-bin" + +# Package contents +FILES_${PN} = "${libdir}/libdb*so*" +FILES_${PN}-bin = "${bindir}" +# The dev package has the .so link (as in db3) and the .a's - +# it is therefore incompatible (cannot be installed at the +# same time) as the db3 package +FILES_${PN}-dev = "${includedir} ${libdir}" + +#configuration - set in local.conf to override +DB4_CONFIG ?= "--enable-o_direct --enable-smallbuild" +# Override the MUTEX setting here, the POSIX library is +# the default - "POSIX/pthreads/library". +# Don't ignore the nice SWP instruction on the ARM: +EXTRA_OECONF = "${DB4_CONFIG}" +# These enable the ARM assembler mutex code, this won't +# work with thumb compilation... +ARM_MUTEX = "--with-mutex=ARM/gcc-assembly" +ARM_MUTEX_thumb = "" +# NOTE: only tested on nslu2, should probably be _armeb +EXTRA_OECONF_nslu2 = "${DB4_CONFIG} ${ARM_MUTEX}" + +# Cancel the site stuff - it's set for db3 and destroys the +# configure. +CONFIG_SITE = "" +do_configure() { + echo '#!/bin/sh' >${S}/configure + echo 'rm ${S}/configure' >>${S}/configure + echo 'exec ../dist/configure "$@"' >>${S}/configure + chmod a+x ${S}/configure + oe_runconf +} + +do_stage() { + oe_runmake DESTDIR="${STAGING_DIR}/${BUILD_SYS}" includedir="${STAGING_INCDIR}" install_include + oe_libinstall -so -C .libs libdb-4.1 ${STAGING_LIBDIR} + ln -s ${STAGING_LIBDIR}/libdb-4.1.so ${STAGING_LIBDIR}/libdb-4.so + ln -s ${STAGING_LIBDIR}/libdb-4.so ${STAGING_LIBDIR}/libdb.so +} + +do_install() { + oe_runmake includedir="${D}${includedir}" libdir="${D}${libdir}" bindir="${D}${bindir}" docdir="${D}${docdir}" install + + # The docs end up in /usr/docs - not right. + if test -d "${D}/${prefix}/docs" + then + mkdir -p "${D}/${datadir}" + test ! -d "${D}/${docdir}" || rmdir "${D}/${docdir}" + mv "${D}/${prefix}/docs" "${D}/${docdir}" + fi +} diff --git a/meta/packages/db/db_4.2.52.bb b/meta/packages/db/db_4.2.52.bb new file mode 100644 index 000000000..9e5978fe1 --- /dev/null +++ b/meta/packages/db/db_4.2.52.bb @@ -0,0 +1,97 @@ +# Version 4 of the Berkeley DB from Sleepycat +# +# At present this package only installs the DB code +# itself (shared libraries, .a in the dev package), +# documentation and headers. +# +# The headers have the same names as those as v3 +# of the DB, only one version can be used *for dev* +# at once - DB3 and DB4 can both be installed on the +# same system at the same time if really necessary. +SECTION = "libs" +DESCRIPTION = "Berkeley DB v4." +HOMEPAGE = "http://www.sleepycat.com" +LICENSE = "BSD Sleepycat" +VIRTUAL_NAME ?= "virtual/db" +CONFLICTS = "db3" +PR = "r3" + +SRC_URI = "http://downloads.sleepycat.com/db-${PV}.tar.gz" +#SRC_URI_MD5 = "http://downloads.sleepycat.com/db-${PV}.tar.gz.md5" +#TODO SRC_URI += "file://arm-thumb-mutex.patch;patch=1" + +inherit autotools + +# Put virtual/db in any appropriate provider of a +# relational database, use it as a dependency in +# place of a specific db and use: +# +# PREFERRED_PROVIDER_virtual/db +# +# to select the correct db in the build (distro) .conf +PROVIDES += "${VIRTUAL_NAME}" + +# bitbake isn't quite clever enough to deal with sleepycat, +# the distribution sits in the expected directory, but all +# the builds must occur from a sub-directory. The following +# persuades bitbake to go to the right place +S = "${WORKDIR}/db-${PV}/dist" +B = "${WORKDIR}/db-${PV}/build_unix" + +# The executables go in a separate package - typically there +# is no need to install these unless doing real database +# management on the system. +PACKAGES += " ${PN}-bin" + +# Package contents +FILES_${PN} = "${libdir}/libdb-4*so*" +FILES_${PN}-bin = "${bindir}" +# The dev package has the .so link (as in db3) and the .a's - +# it is therefore incompatible (cannot be installed at the +# same time) as the db3 package +FILES_${PN}-dev = "${includedir} ${libdir}" + +#configuration - set in local.conf to override +DB4_CONFIG ?= " --disable-cryptography --disable-queue --disable-replication --disable-verify --enable-hash" +EXTRA_OECONF = "${DB4_CONFIG}" + +# Override the MUTEX setting here, the POSIX library is +# the default - "POSIX/pthreads/library". +# Don't ignore the nice SWP instruction on the ARM: +# These enable the ARM assembler mutex code, this won't +# work with thumb compilation... +ARM_MUTEX = "--with-mutex=ARM/gcc-assembly" +MUTEX = "" +MUTEX_arm = "${ARM_MUTEX}" +MUTEX_armeb = "${ARM_MUTEX}" +EXTRA_OECONF += "${MUTEX}" + +# Cancel the site stuff - it's set for db3 and destroys the +# configure. +CONFIG_SITE = "" +do_configure() { + oe_runconf +} + +do_stage() { + # The .h files get installed read-only, the autostage + # function just uses cp -pPR, so do this by hand + rm -rf ${STAGE_TEMP} + mkdir -p ${STAGE_TEMP} + oe_runmake DESTDIR="${STAGE_TEMP}" install_include + cp -pPRf ${STAGE_TEMP}/${includedir}/* ${STAGING_INCDIR}/. + rm -rf ${STAGE_TEMP} + oe_libinstall -so -C .libs libdb-4.2 ${STAGING_LIBDIR} + ln -sf libdb-4.2.so ${STAGING_LIBDIR}/libdb.so + ln -sf libdb-4.2.a ${STAGING_LIBDIR}/libdb.a +} + +do_install_append() { + # The docs end up in /usr/docs - not right. + if test -d "${D}/${prefix}/docs" + then + mkdir -p "${D}/${datadir}" + test ! -d "${D}/${docdir}" || rmdir "${D}/${docdir}" + mv "${D}/${prefix}/docs" "${D}/${docdir}" + fi +} diff --git a/meta/packages/db/db_4.3.29.bb b/meta/packages/db/db_4.3.29.bb new file mode 100644 index 000000000..a4059aac6 --- /dev/null +++ b/meta/packages/db/db_4.3.29.bb @@ -0,0 +1,100 @@ +# Has issues with eds +DEFAULT_PREFERENCE = "-1" + +# Version 4 of the Berkeley DB from Sleepycat +# +# At present this package only installs the DB code +# itself (shared libraries, .a in the dev package), +# documentation and headers. +# +# The headers have the same names as those as v3 +# of the DB, only one version can be used *for dev* +# at once - DB3 and DB4 can both be installed on the +# same system at the same time if really necessary. +SECTION = "libs" +DESCRIPTION = "Berkeley DB v4." +HOMEPAGE = "http://www.sleepycat.com" +LICENSE = "BSD Sleepycat" +VIRTUAL_NAME ?= "virtual/db" +CONFLICTS = "db3" +PR = "r3" + +SRC_URI = "http://downloads.sleepycat.com/db-${PV}.tar.gz" +#SRC_URI_MD5 = "http://downloads.sleepycat.com/db-${PV}.tar.gz.md5" +SRC_URI += "file://arm-thumb-mutex.patch;patch=1" + +inherit autotools + +# Put virtual/db in any appropriate provider of a +# relational database, use it as a dependency in +# place of a specific db and use: +# +# PREFERRED_PROVIDER_virtual/db +# +# to select the correct db in the build (distro) .conf +PROVIDES += "${VIRTUAL_NAME}" + +# bitbake isn't quite clever enough to deal with sleepycat, +# the distribution sits in the expected directory, but all +# the builds must occur from a sub-directory. The following +# persuades bitbake to go to the right place +S = "${WORKDIR}/db-${PV}/dist" +B = "${WORKDIR}/db-${PV}/build_unix" + +# The executables go in a separate package - typically there +# is no need to install these unless doing real database +# management on the system. +PACKAGES += " ${PN}-bin" + +# Package contents +FILES_${PN} = "${libdir}/libdb-4*so*" +FILES_${PN}-bin = "${bindir}" +# The dev package has the .so link (as in db3) and the .a's - +# it is therefore incompatible (cannot be installed at the +# same time) as the db3 package +FILES_${PN}-dev = "${includedir} ${libdir}" + +#configuration - set in local.conf to override +DB4_CONFIG ?= "--enable-o_direct --enable-smallbuild --enable-compat185" +EXTRA_OECONF = "${DB4_CONFIG}" + +# Override the MUTEX setting here, the POSIX library is +# the default - "POSIX/pthreads/library". +# Don't ignore the nice SWP instruction on the ARM: +# These enable the ARM assembler mutex code, this won't +# work with thumb compilation... +ARM_MUTEX = "--with-mutex=ARM/gcc-assembly" +MUTEX = "" +MUTEX_arm = "${ARM_MUTEX}" +MUTEX_armeb = "${ARM_MUTEX}" +EXTRA_OECONF += "${MUTEX}" + +# Cancel the site stuff - it's set for db3 and destroys the +# configure. +CONFIG_SITE = "" +do_configure() { + oe_runconf +} + +do_stage() { + # The .h files get installed read-only, the autostage + # function just uses cp -pPR, so do this by hand + rm -rf ${STAGE_TEMP} + mkdir -p ${STAGE_TEMP} + oe_runmake DESTDIR="${STAGE_TEMP}" install_include + cp -pPRf ${STAGE_TEMP}/${includedir}/* ${STAGING_INCDIR}/. + rm -rf ${STAGE_TEMP} + oe_libinstall -so -C .libs libdb-4.3 ${STAGING_LIBDIR} + ln -sf libdb-4.3.so ${STAGING_LIBDIR}/libdb.so + ln -sf libdb-4.3.a ${STAGING_LIBDIR}/libdb.a +} + +do_install_append() { + # The docs end up in /usr/docs - not right. + if test -d "${D}/${prefix}/docs" + then + mkdir -p "${D}/${datadir}" + test ! -d "${D}/${docdir}" || rmdir "${D}/${docdir}" + mv "${D}/${prefix}/docs" "${D}/${docdir}" + fi +} diff --git a/meta/packages/db/files/arm-thumb-mutex.patch b/meta/packages/db/files/arm-thumb-mutex.patch new file mode 100644 index 000000000..acd446fcd --- /dev/null +++ b/meta/packages/db/files/arm-thumb-mutex.patch @@ -0,0 +1,36 @@ +--- db-4.3.29-dist/../dbinc/mutex.h 2005-11-15 07:33:27.761042518 -0800 ++++ db-4.3.29-dist/../dbinc/mutex.h 2005-11-15 07:55:24.823920060 -0800 +@@ -470,6 +470,25 @@ + #ifdef LOAD_ACTUAL_MUTEX_CODE + #define MUTEX_SET_TEST 1 /* gcc/arm: 0 is clear, 1 is set. */ + ++#if defined __thumb__ ++#define MUTEX_SET(tsl) ({ \ ++ int __r, __p; \ ++ asm volatile( \ ++ ".align 2\n\t" \ ++ "bx pc\n\t" \ ++ "nop\n\t" \ ++ ".arm\n\t" \ ++ "swpb %0, %2, [%3]\n\t" \ ++ "eor %0, %0, #1\n\t" \ ++ "orr %1, pc, #1\n\t" \ ++ "bx %1\n\t" \ ++ ".force_thumb" \ ++ : "=&r" (__r), "=r" (__p) \ ++ : "r" (1), "r" (tsl) \ ++ ); \ ++ __r & 1; \ ++}) ++#else + #define MUTEX_SET(tsl) ({ \ + int __r; \ + asm volatile( \ +@@ -480,6 +499,7 @@ + ); \ + __r & 1; \ + }) ++#endif + + #define MUTEX_UNSET(tsl) (*(volatile tsl_t *)(tsl) = 0) + #define MUTEX_INIT(tsl) MUTEX_UNSET(tsl) diff --git a/meta/packages/dbus/dbus-0.60/dbus-1.init b/meta/packages/dbus/dbus-0.60/dbus-1.init new file mode 100644 index 000000000..60440b722 --- /dev/null +++ b/meta/packages/dbus/dbus-0.60/dbus-1.init @@ -0,0 +1,86 @@ +#! /bin/sh +# -*- coding: utf-8 -*- +# Debian init.d script for D-BUS +# Copyright © 2003 Colin Walters + +set -e + +DAEMON=/usr/bin/dbus-daemon +NAME=dbus-1 +DAEMONUSER=messagebus +PIDDIR=/var/run/dbus +PIDFILE=$PIDDIR/pid +DESC="system message bus" +EVENTDIR=/etc/dbus-1/event.d + +test -x $DAEMON || exit 0 + +# Source defaults file; edit that file to configure this script. +ENABLED=1 +PARAMS="" +if [ -e /etc/default/dbus-1 ]; then + . /etc/default/dbus-1 +fi + +test "$ENABLED" != "0" || exit 0 + +start_it_up() +{ + if [ ! -d $PIDDIR ]; then + mkdir -p $PIDDIR + chown $DAEMONUSER $PIDDIR + chgrp $DAEMONUSER $PIDDIR + fi + if [ -e $PIDFILE ]; then + PIDDIR=/proc/$(cat $PIDFILE) + if [ -d ${PIDDIR} -a "$(readlink -f ${PIDDIR}/exe)" = "${DAEMON}" ]; then + echo "$DESC already started; not starting." + else + echo "Removing stale PID file $PIDFILE." + rm -f $PIDFILE + fi + fi + echo -n "Starting $DESC: " + start-stop-daemon --start --quiet --pidfile $PIDFILE \ + --user $DAEMONUSER --exec $DAEMON -- --system $PARAMS + echo "$NAME." + if [ -d $EVENTDIR ]; then + run-parts --arg=start $EVENTDIR + fi +} + +shut_it_down() +{ + if [ -d $EVENTDIR ]; then + run-parts --reverse --arg=stop $EVENTDIR + fi + echo -n "Stopping $DESC: " + start-stop-daemon --stop --quiet --pidfile $PIDFILE \ + --user $DAEMONUSER + # We no longer include these arguments so that start-stop-daemon + # can do its job even given that we may have been upgraded. + # We rely on the pidfile being sanely managed + # --exec $DAEMON -- --system $PARAMS + echo "$NAME." + rm -f $PIDFILE +} + +case "$1" in + start) + start_it_up + ;; + stop) + shut_it_down + ;; + restart|force-reload) + shut_it_down + sleep 1 + start_it_up + ;; + *) + echo "Usage: /etc/init.d/$NAME {start|stop|restart|force-reload}" >&2 + exit 1 + ;; +esac + +exit 0 diff --git a/meta/packages/dbus/dbus-0.60/no-bindings.patch b/meta/packages/dbus/dbus-0.60/no-bindings.patch new file mode 100644 index 000000000..ccfc3f88b --- /dev/null +++ b/meta/packages/dbus/dbus-0.60/no-bindings.patch @@ -0,0 +1,12 @@ +--- dbus-0.50/tools/Makefile.am.orig 2005-09-07 10:05:38 +0200 ++++ dbus-0.50/tools/Makefile.am 2005-09-07 10:06:30 +0200 +@@ -6,9 +6,6 @@ + nodist_libdbus_glib_HEADERS = dbus-glib-bindings.h + libdbus_glibdir = $(includedir)/dbus-1.0/dbus + +-dbus-glib-bindings.h: dbus-bus-introspect.xml $(top_builddir)/glib/dbus-binding-tool$(EXEEXT) +- $(top_builddir)/glib/dbus-binding-tool --mode=glib-client --output=dbus-glib-bindings.h dbus-bus-introspect.xml +- + BUILT_SOURCES = dbus-glib-bindings.h dbus-bus-introspect.xml + + else diff --git a/meta/packages/dbus/dbus-0.60/no-introspect.patch b/meta/packages/dbus/dbus-0.60/no-introspect.patch new file mode 100644 index 000000000..1e43dd121 --- /dev/null +++ b/meta/packages/dbus/dbus-0.60/no-introspect.patch @@ -0,0 +1,14 @@ +--- dbus-0.50/tools/Makefile.am.orig 2005-09-07 10:03:49 +0200 ++++ dbus-0.50/tools/Makefile.am 2005-09-07 10:04:28 +0200 +@@ -21,11 +21,6 @@ + GTK_TOOLS= + endif + +-if HAVE_GLIB +-dbus-bus-introspect.xml: $(top_builddir)/bus/dbus-daemon$(EXEEXT) dbus-launch$(EXEEXT) dbus-send$(EXEEXT) $(top_builddir)/bus/dbus-daemon$(EXEEXT) Makefile +- DBUS_TOP_BUILDDIR=$(top_builddir) $(srcdir)/run-with-tmp-session-bus.sh ./dbus-send --print-reply=literal --dest=org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus.Introspectable.Introspect > dbus-bus-introspect.xml.tmp && mv dbus-bus-introspect.xml.tmp dbus-bus-introspect.xml +-endif +- + bin_PROGRAMS=dbus-send $(GLIB_TOOLS) dbus-launch dbus-cleanup-sockets $(GTK_TOOLS) + + dbus_send_SOURCES= \ diff --git a/meta/packages/dbus/dbus-native_0.50.bb b/meta/packages/dbus/dbus-native_0.50.bb new file mode 100644 index 000000000..9e661dbcc --- /dev/null +++ b/meta/packages/dbus/dbus-native_0.50.bb @@ -0,0 +1,19 @@ +include dbus_${PV}.inc + +SRC_URI_EXTRA="" + +inherit native + +S = "${WORKDIR}/dbus-${PV}" +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/dbus" +DEPENDS = "glib-2.0-native" + +PR = "r1" + +do_stage() { + oe_runmake install + install -d ${STAGING_DATADIR}/dbus + install -m 0644 tools/dbus-bus-introspect.xml ${STAGING_DATADIR}/dbus + install -m 0644 tools/dbus-glib-bindings.h ${STAGING_DATADIR}/dbus +} + diff --git a/meta/packages/dbus/dbus-native_0.60.bb b/meta/packages/dbus/dbus-native_0.60.bb new file mode 100644 index 000000000..9e661dbcc --- /dev/null +++ b/meta/packages/dbus/dbus-native_0.60.bb @@ -0,0 +1,19 @@ +include dbus_${PV}.inc + +SRC_URI_EXTRA="" + +inherit native + +S = "${WORKDIR}/dbus-${PV}" +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/dbus" +DEPENDS = "glib-2.0-native" + +PR = "r1" + +do_stage() { + oe_runmake install + install -d ${STAGING_DATADIR}/dbus + install -m 0644 tools/dbus-bus-introspect.xml ${STAGING_DATADIR}/dbus + install -m 0644 tools/dbus-glib-bindings.h ${STAGING_DATADIR}/dbus +} + diff --git a/meta/packages/dbus/dbus.inc b/meta/packages/dbus/dbus.inc new file mode 100644 index 000000000..1c63c37fd --- /dev/null +++ b/meta/packages/dbus/dbus.inc @@ -0,0 +1,65 @@ +SECTION = "base" +PR = "r0" +HOMEPAGE = "http://www.freedesktop.org/Software/dbus" +DESCRIPTION = "message bus system for applications to talk to one another" +LICENSE = "GPL" +DEPENDS = "expat glib-2.0 virtual/libintl" +DEFAULT_PREFERENCE = "-1" + +SRC_URI = "http://freedesktop.org/software/dbus/releases/dbus-${PV}.tar.gz \ + file://cross.patch;patch=1 \ + file://tmpdir.patch;patch=1 \ + file://dbus-1.init \ + ${SRC_URI_EXTRA}" + + +inherit autotools pkgconfig update-rc.d gettext + +INITSCRIPT_NAME = "dbus-1" +INITSCRIPT_PARAMS = "defaults" + +CONFFILES_${PN} = "${sysconfdir}/dbus-1/system.conf ${sysconfdir}/dbus-1/session.conf" + +FILES_${PN} = "${bindir}/dbus-daemon-1 ${bindir}/dbus-launch ${bindir}/dbus-cleanup-sockets ${bindir}/dbus-send ${bindir}/dbus-monitor ${sysconfdir} ${datadir}/dbus-1/services ${libdir}/lib*.so.*" +FILES_${PN}-dev += "${libdir}/dbus-1.0/include ${bindir}/dbus-glib-tool" + +pkg_postinst_dbus() { +#!/bin/sh + +# can't do adduser stuff offline +if [ "x$D" != "x" ]; then + exit 1 +fi + +MESSAGEUSER=messagebus +MESSAGEHOME=/var/run/dbus + +mkdir -p $MESSAGEHOME || true +chgrp "$MESSAGEUSER" "$MESSAGEHOME" 2>/dev/null || addgroup "$MESSAGEUSER" +chown "$MESSAGEUSER"."$MESSAGEUSER" "$MESSAGEHOME" 2>/dev/null || adduser --system --home "$MESSAGEHOME" --no-create-home --disabled-password --ingroup "$MESSAGEUSER" "$MESSAGEUSER" +} + +EXTRA_OECONF = "--disable-qt --disable-gtk --disable-tests \ + --disable-checks --disable-xml-docs --disable-doxygen-docs \ + --with-xml=expat --without-x" + + +do_stage () { + oe_libinstall -so -C dbus libdbus-1 ${STAGING_LIBDIR} + oe_libinstall -so -C glib libdbus-glib-1 ${STAGING_LIBDIR} + + autotools_stage_includes + + mkdir -p ${STAGING_LIBDIR}/dbus-1.0/include/dbus/ + install -m 0644 dbus/dbus-arch-deps.h ${STAGING_LIBDIR}/dbus-1.0/include/dbus/ +} + +do_install_append () { + install -d ${D}${sysconfdir}/init.d + install -m 0755 ${WORKDIR}/dbus-1.init ${D}${sysconfdir}/init.d/dbus-1 +} + +python populate_packages_prepend () { + if (bb.data.getVar('DEBIAN_NAMES', d, 1)): + bb.data.setVar('PKG_dbus', 'dbus-1', d) +} diff --git a/meta/packages/dbus/dbus/0.23.1.diff b/meta/packages/dbus/dbus/0.23.1.diff new file mode 100644 index 000000000..d56e1afc9 --- /dev/null +++ b/meta/packages/dbus/dbus/0.23.1.diff @@ -0,0 +1,308 @@ +diff -ur dbus-0.23/ChangeLog dbus-0.23.1/ChangeLog +--- dbus-0.23/ChangeLog 2005-01-13 00:48:43.000000000 +0200 ++++ dbus-0.23.1/ChangeLog 2005-02-11 20:25:48.000000000 +0200 +@@ -1,3 +1,33 @@ ++2005-02-11 Joe Shaw ++ ++ * NEWS: Update for 0.23.1 ++ ++ * configure.in: Release 0.23.1 ++ ++2005-02-10 Joe Shaw ++ ++ * dbus/dbus-connection.c ++ (_dbus_connection_queue_received_message_link, ++ _dbus_connection_message_sent): Add the path to ++ the verbose output. ++ (_dbus_connection_send_preallocated_and_unlock): Added. Calls ++ _dbus_connection_send_preallocated_unlocked(), updated the ++ dispatch status, and unlocks. Fixes a bug where certain ++ situations (like a broken pipe) could cause a Disconnect message ++ to not be sent, tricking the bus into thinking a service was still ++ there when the process had quit. ++ (_dbus_connection_send_preallocated): Call ++ _dbus_connection_send_preallocated_and_unlock(). ++ (_dbus_connection_send_and_unlock): Added. Calls ++ _dbus_connection_send_preallocated_and_unlock(). ++ (dbus_connection_send): Call _dbus_connection_send_and_unlock(). ++ (dbus_connection_send_with_reply): Update the dispatch status and ++ unlock. ++ ++ * mono/Service.cs (~Service): Added. Removes the filter so that ++ we don't get unmanaged code calling back into a GCed delegate. ++ (RemoveFilter); Added. ++ + 2005-01-12 Joe Shaw + + * NEWS: Update for 0.23. +diff -ur dbus-0.23/NEWS dbus-0.23.1/NEWS +--- dbus-0.23/NEWS 2005-01-13 00:20:40.000000000 +0200 ++++ dbus-0.23.1/NEWS 2005-02-11 20:25:16.000000000 +0200 +@@ -1,3 +1,11 @@ ++D-BUS 0.23.1 (11 Feb 2005) ++=== ++- fix a bug in which the bus daemon wouldn't recognize that a service ++ owner quit ++- fix a bug in the mono bindings that would cause unmanaged code to ++ call back into a delegate that had been garbage collected and ++ crashed. ++ + D-BUS 0.23 (11 Jan 2005) + === + +diff -ur dbus-0.23/configure dbus-0.23.1/configure +--- dbus-0.23/configure 2005-01-13 00:21:25.000000000 +0200 ++++ dbus-0.23.1/configure 2005-02-11 19:53:33.000000000 +0200 +@@ -1826,7 +1826,7 @@ + + # Define the identity of the package. + PACKAGE=dbus +- VERSION=0.23 ++ VERSION=0.23.1 + + + cat >>confdefs.h <<_ACEOF +diff -ur dbus-0.23/configure.in dbus-0.23.1/configure.in +--- dbus-0.23/configure.in 2005-01-13 00:20:40.000000000 +0200 ++++ dbus-0.23.1/configure.in 2005-02-11 19:53:09.000000000 +0200 +@@ -3,7 +3,7 @@ + + AC_INIT(dbus/dbus.h) + +-AM_INIT_AUTOMAKE(dbus, 0.23) ++AM_INIT_AUTOMAKE(dbus, 0.23.1) + + AM_CONFIG_HEADER(config.h) + +diff -ur dbus-0.23/dbus/dbus-connection.c dbus-0.23.1/dbus/dbus-connection.c +--- dbus-0.23/dbus/dbus-connection.c 2005-01-11 21:31:56.000000000 +0200 ++++ dbus-0.23.1/dbus/dbus-connection.c 2005-02-11 19:52:47.000000000 +0200 +@@ -358,9 +358,10 @@ + + _dbus_connection_wakeup_mainloop (connection); + +- _dbus_verbose ("Message %p (%d %s %s '%s') added to incoming queue %p, %d incoming\n", ++ _dbus_verbose ("Message %p (%d %s %s %s '%s') added to incoming queue %p, %d incoming\n", + message, + dbus_message_get_type (message), ++ dbus_message_get_path (message), + dbus_message_get_interface (message) ? + dbus_message_get_interface (message) : + "no interface", +@@ -473,9 +474,10 @@ + + connection->n_outgoing -= 1; + +- _dbus_verbose ("Message %p (%d %s %s '%s') removed from outgoing queue %p, %d left to send\n", ++ _dbus_verbose ("Message %p (%d %s %s %s '%s') removed from outgoing queue %p, %d left to send\n", + message, + dbus_message_get_type (message), ++ dbus_message_get_path (message), + dbus_message_get_interface (message) ? + dbus_message_get_interface (message) : + "no interface", +@@ -1572,9 +1574,10 @@ + } + #endif + +- _dbus_verbose ("Message %p (%d %s %s '%s') added to outgoing queue %p, %d pending to send\n", ++ _dbus_verbose ("Message %p (%d %s %s %s '%s') added to outgoing queue %p, %d pending to send\n", + message, + dbus_message_get_type (message), ++ dbus_message_get_path (message), + dbus_message_get_interface (message) ? + dbus_message_get_interface (message) : + "no interface", +@@ -1606,12 +1609,30 @@ + _dbus_connection_do_iteration (connection, + DBUS_ITERATION_DO_WRITING, + -1); +- ++ + /* If stuff is still queued up, be sure we wake up the main loop */ + if (connection->n_outgoing > 0) + _dbus_connection_wakeup_mainloop (connection); + } + ++static void ++_dbus_connection_send_preallocated_and_unlock (DBusConnection *connection, ++ DBusPreallocatedSend *preallocated, ++ DBusMessage *message, ++ dbus_uint32_t *client_serial) ++{ ++ DBusDispatchStatus status; ++ ++ _dbus_connection_send_preallocated_unlocked (connection, ++ preallocated, ++ message, client_serial); ++ ++ status = _dbus_connection_get_dispatch_status_unlocked (connection); ++ ++ /* this calls out to user code */ ++ _dbus_connection_update_dispatch_status_and_unlock (connection, status); ++} ++ + /** + * Sends a message using preallocated resources. This function cannot fail. + * It works identically to dbus_connection_send() in other respects. +@@ -1642,10 +1663,9 @@ + dbus_message_get_member (message) != NULL)); + + CONNECTION_LOCK (connection); +- _dbus_connection_send_preallocated_unlocked (connection, +- preallocated, +- message, client_serial); +- CONNECTION_UNLOCK (connection); ++ _dbus_connection_send_preallocated_and_unlock (connection, ++ preallocated, ++ message, client_serial); + } + + static dbus_bool_t +@@ -1670,6 +1690,27 @@ + return TRUE; + } + ++static dbus_bool_t ++_dbus_connection_send_and_unlock (DBusConnection *connection, ++ DBusMessage *message, ++ dbus_uint32_t *client_serial) ++{ ++ DBusPreallocatedSend *preallocated; ++ ++ _dbus_assert (connection != NULL); ++ _dbus_assert (message != NULL); ++ ++ preallocated = _dbus_connection_preallocate_send_unlocked (connection); ++ if (preallocated == NULL) ++ return FALSE; ++ ++ _dbus_connection_send_preallocated_and_unlock (connection, ++ preallocated, ++ message, ++ client_serial); ++ return TRUE; ++} ++ + /** + * Adds a message to the outgoing message queue. Does not block to + * write the message to the network; that happens asynchronously. To +@@ -1698,14 +1739,9 @@ + + CONNECTION_LOCK (connection); + +- if (!_dbus_connection_send_unlocked (connection, message, client_serial)) +- { +- CONNECTION_UNLOCK (connection); +- return FALSE; +- } +- +- CONNECTION_UNLOCK (connection); +- return TRUE; ++ return _dbus_connection_send_and_unlock (connection, ++ message, ++ client_serial); + } + + static dbus_bool_t +@@ -1784,6 +1820,7 @@ + DBusMessage *reply; + DBusList *reply_link; + dbus_int32_t serial = -1; ++ DBusDispatchStatus status; + + _dbus_return_val_if_fail (connection != NULL, FALSE); + _dbus_return_val_if_fail (message != NULL, FALSE); +@@ -1845,8 +1882,11 @@ + else + dbus_pending_call_unref (pending); + +- CONNECTION_UNLOCK (connection); +- ++ status = _dbus_connection_get_dispatch_status_unlocked (connection); ++ ++ /* this calls out to user code */ ++ _dbus_connection_update_dispatch_status_and_unlock (connection, status); ++ + return TRUE; + + error: +@@ -2256,9 +2296,10 @@ + link = _dbus_list_pop_first_link (&connection->incoming_messages); + connection->n_incoming -= 1; + +- _dbus_verbose ("Message %p (%d %s %s '%s') removed from incoming queue %p, %d incoming\n", ++ _dbus_verbose ("Message %p (%d %s %s %s '%s') removed from incoming queue %p, %d incoming\n", + link->data, + dbus_message_get_type (link->data), ++ dbus_message_get_path (link->data), + dbus_message_get_interface (link->data) ? + dbus_message_get_interface (link->data) : + "no interface", +diff -ur dbus-0.23/mono/Service.cs dbus-0.23.1/mono/Service.cs +--- dbus-0.23/mono/Service.cs 2004-08-31 06:59:14.000000000 +0300 ++++ dbus-0.23.1/mono/Service.cs 2005-02-11 19:52:47.000000000 +0200 +@@ -23,6 +23,9 @@ + private static AssemblyBuilder proxyAssembly; + private ModuleBuilder module = null; + ++ // Add a match for signals. FIXME: Can we filter the service? ++ private const string MatchRule = "type='signal'"; ++ + internal Service(string name, Connection connection) + { + this.name = name; +@@ -47,6 +50,12 @@ + this.local = true; + } + ++ ~Service () ++ { ++ if (this.filterCalled != null) ++ RemoveFilter (); ++ } ++ + public static bool Exists(Connection connection, string name) + { + Error error = new Error(); +@@ -113,9 +122,17 @@ + IntPtr.Zero)) + throw new OutOfMemoryException(); + +- // Add a match for signals. FIXME: Can we filter the service? +- string rule = "type='signal'"; +- dbus_bus_add_match(connection.RawConnection, rule, IntPtr.Zero); ++ dbus_bus_add_match(connection.RawConnection, MatchRule, IntPtr.Zero); ++ } ++ ++ private void RemoveFilter() ++ { ++ dbus_connection_remove_filter (Connection.RawConnection, ++ this.filterCalled, ++ IntPtr.Zero); ++ this.filterCalled = null; ++ ++ dbus_bus_remove_match (connection.RawConnection, MatchRule, IntPtr.Zero); + } + + private int Service_FilterCalled(IntPtr rawConnection, +@@ -200,9 +217,19 @@ + IntPtr freeData); + + [DllImport("dbus-1")] ++ private extern static void dbus_connection_remove_filter(IntPtr rawConnection, ++ DBusHandleMessageFunction filter, ++ IntPtr userData); ++ ++ [DllImport("dbus-1")] + private extern static void dbus_bus_add_match(IntPtr rawConnection, + string rule, + IntPtr erro); + ++ [DllImport("dbus-1")] ++ private extern static void dbus_bus_remove_match(IntPtr rawConnection, ++ string rule, ++ IntPtr erro); ++ + } + } diff --git a/meta/packages/dbus/dbus/config.diff b/meta/packages/dbus/dbus/config.diff new file mode 100644 index 000000000..b67c8d72f --- /dev/null +++ b/meta/packages/dbus/dbus/config.diff @@ -0,0 +1,17 @@ +Only in /home/kihamala/svn/dbus/bus: .svn +diff -ur bus/session.conf.in /home/kihamala/svn/dbus/bus/session.conf.in +--- bus/session.conf.in 2004-10-25 21:48:58.000000000 +0300 ++++ /home/kihamala/svn/dbus/bus/session.conf.in 2005-02-15 11:03:26.000000000 +0200 +@@ -8,9 +8,10 @@ + + session + +- unix:tmpdir=@DBUS_SESSION_SOCKET_DIR@ ++ unix:path=/tmp/session_bus_socket + +- @EXPANDED_DATADIR@/dbus-1/services ++ @EXPANDED_LIBDIR@/dbus-1.0/services ++ + + + diff --git a/meta/packages/dbus/dbus/cross.patch b/meta/packages/dbus/dbus/cross.patch new file mode 100644 index 000000000..6d1d9d8e7 --- /dev/null +++ b/meta/packages/dbus/dbus/cross.patch @@ -0,0 +1,15 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- dbus-0.20/configure.in~cross ++++ dbus-0.20/configure.in +@@ -466,6 +466,7 @@ + exit (0); + ]])], + [have_abstract_sockets=yes], ++ [have_abstract_sockets=no], + [have_abstract_sockets=no]) + AC_LANG_POP(C) + AC_MSG_RESULT($have_abstract_sockets) diff --git a/meta/packages/dbus/dbus/dbus-1.init b/meta/packages/dbus/dbus/dbus-1.init new file mode 100644 index 000000000..adefe7c5b --- /dev/null +++ b/meta/packages/dbus/dbus/dbus-1.init @@ -0,0 +1,86 @@ +#! /bin/sh +# -*- coding: utf-8 -*- +# Debian init.d script for D-BUS +# Copyright © 2003 Colin Walters + +set -e + +DAEMON=/usr/bin/dbus-daemon-1 +NAME=dbus-1 +DAEMONUSER=messagebus +PIDDIR=/var/run/dbus +PIDFILE=$PIDDIR/pid +DESC="system message bus" +EVENTDIR=/etc/dbus-1/event.d + +test -x $DAEMON || exit 0 + +# Source defaults file; edit that file to configure this script. +ENABLED=1 +PARAMS="" +if [ -e /etc/default/dbus-1 ]; then + . /etc/default/dbus-1 +fi + +test "$ENABLED" != "0" || exit 0 + +start_it_up() +{ + if [ ! -d $PIDDIR ]; then + mkdir -p $PIDDIR + chown $DAEMONUSER $PIDDIR + chgrp $DAEMONUSER $PIDDIR + fi + if [ -e $PIDFILE ]; then + PIDDIR=/proc/$(cat $PIDFILE) + if [ -d ${PIDDIR} -a "$(readlink -f ${PIDDIR}/exe)" = "${DAEMON}" ]; then + echo "$DESC already started; not starting." + else + echo "Removing stale PID file $PIDFILE." + rm -f $PIDFILE + fi + fi + echo -n "Starting $DESC: " + start-stop-daemon --start --quiet --pidfile $PIDFILE \ + --user $DAEMONUSER --exec $DAEMON -- --system $PARAMS + echo "$NAME." + if [ -d $EVENTDIR ]; then + run-parts --arg=start $EVENTDIR + fi +} + +shut_it_down() +{ + if [ -d $EVENTDIR ]; then + run-parts --reverse --arg=stop $EVENTDIR + fi + echo -n "Stopping $DESC: " + start-stop-daemon --stop --quiet --pidfile $PIDFILE \ + --user $DAEMONUSER + # We no longer include these arguments so that start-stop-daemon + # can do its job even given that we may have been upgraded. + # We rely on the pidfile being sanely managed + # --exec $DAEMON -- --system $PARAMS + echo "$NAME." + rm -f $PIDFILE +} + +case "$1" in + start) + start_it_up + ;; + stop) + shut_it_down + ;; + restart|force-reload) + shut_it_down + sleep 1 + start_it_up + ;; + *) + echo "Usage: /etc/init.d/$NAME {start|stop|restart|force-reload}" >&2 + exit 1 + ;; +esac + +exit 0 diff --git a/meta/packages/dbus/dbus/dbus-monitor.patch b/meta/packages/dbus/dbus/dbus-monitor.patch new file mode 100644 index 000000000..c2f90c885 --- /dev/null +++ b/meta/packages/dbus/dbus/dbus-monitor.patch @@ -0,0 +1,150 @@ +diff -urN dbus-0.22.orig/tools/dbus-monitor.1 dbus-0.22/tools/dbus-monitor.1 +--- dbus-0.22.orig/tools/dbus-monitor.1 2004-10-10 20:47:19.906823680 +1000 ++++ dbus-0.22/tools/dbus-monitor.1 2004-10-10 20:47:27.791625008 +1000 +@@ -9,6 +9,7 @@ + .PP + .B dbus-monitor + [\-\-system | \-\-session] ++[watch expressions] + + .SH DESCRIPTION + +@@ -25,6 +26,11 @@ + monitor the system or session buses respectively. If neither is + specified, \fIdbus-monitor\fP monitors the session bus. + ++.PP ++In order to get \fIdbus-monitor\fP to see the messages you are interested ++in, you should specify a set of watch expressions as you would expect to ++be passed to the \fIdbus_bus_add_watch\fP function. ++ + .PP + The message bus configuration may keep \fIdbus-monitor\fP from seeing + all messages, especially if you run the monitor as a non-root user. +@@ -37,6 +43,15 @@ + .I "--session" + Monitor the session message bus. (This is the default.) + ++.SH EXAMPLE ++Here is an example of using dbus-monitor to watch for the gnome typing ++monitor to say things ++.nf ++ ++ dbus-monitor "type='signal',sender='org.gnome.TypingMonitor',interface='org.gnome.TypingMonitor'" ++ ++.fi ++ + .SH AUTHOR + dbus-monitor was written by Philip Blundell. + +--- dbus-0.22-1ubuntu1/tools/dbus-monitor.c 2004-08-10 13:03:37.000000000 +1000 ++++ dbus-0.22/tools/dbus-monitor.c 2004-10-10 21:38:08.532362152 +1000 +@@ -45,7 +45,7 @@ + static void + usage (char *name, int ecode) + { +- fprintf (stderr, "Usage: %s [--system | --session]\n", name); ++ fprintf (stderr, "Usage: %s [--system | --session] [watch expressions]\n", name); + exit (ecode); + } + +@@ -56,8 +56,8 @@ + DBusError error; + DBusBusType type = DBUS_BUS_SESSION; + GMainLoop *loop; +- int i; +- ++ int i = 0, j = 0, numFilters = 0; ++ char **filters = NULL; + for (i = 1; i < argc; i++) + { + char *arg = argv[i]; +@@ -69,14 +69,18 @@ + else if (!strcmp (arg, "--help")) + usage (argv[0], 0); + else if (!strcmp (arg, "--")) +- break; ++ continue; + else if (arg[0] == '-') + usage (argv[0], 1); ++ else { ++ numFilters++; ++ filters = (char **)realloc(filters, numFilters * sizeof(char *)); ++ filters[j] = (char *)malloc((strlen(arg) + 1) * sizeof(char *)); ++ snprintf(filters[j], strlen(arg) + 1, "%s", arg); ++ j++; ++ } + } + +- if (argc > 2) +- usage (argv[0], 1); +- + loop = g_main_loop_new (NULL, FALSE); + + dbus_error_init (&error); +@@ -92,26 +102,45 @@ + + dbus_connection_setup_with_g_main (connection, NULL); + +- dbus_bus_add_match (connection, +- "type='signal'", +- &error); +- if (dbus_error_is_set (&error)) +- goto lose; +- dbus_bus_add_match (connection, +- "type='method_call'", +- &error); +- if (dbus_error_is_set (&error)) +- goto lose; +- dbus_bus_add_match (connection, +- "type='method_return'", +- &error); +- if (dbus_error_is_set (&error)) +- goto lose; +- dbus_bus_add_match (connection, +- "type='error'", +- &error); +- if (dbus_error_is_set (&error)) +- goto lose; ++ if (numFilters) ++ { ++ for (i = 0; i < j; i++) ++ { ++ dbus_bus_add_match (connection, filters[i], &error); ++ if (dbus_error_is_set (&error)) ++ { ++ fprintf (stderr, "Failed to setup match \"%s\": %s\n", ++ filters[i], error.message); ++ dbus_error_free (&error); ++ exit (1); ++ } ++ free(filters[i]); ++ } ++ } ++ else ++ { ++ dbus_bus_add_match (connection, ++ "type='signal'", ++ &error); ++ if (dbus_error_is_set (&error)) ++ goto lose; ++ dbus_bus_add_match (connection, ++ "type='method_call'", ++ &error); ++ if (dbus_error_is_set (&error)) ++ goto lose; ++ dbus_bus_add_match (connection, ++ "type='method_return'", ++ &error); ++ if (dbus_error_is_set (&error)) ++ goto lose; ++ dbus_bus_add_match (connection, ++ "type='error'", ++ &error); ++ if (dbus_error_is_set (&error)) ++ goto lose; ++ } ++ + if (!dbus_connection_add_filter (connection, filter_func, NULL, NULL)) { + fprintf (stderr, "Couldn't add filter!\n"); + exit (1); diff --git a/meta/packages/dbus/dbus/dbus-quiesce-startup-errors.patch b/meta/packages/dbus/dbus/dbus-quiesce-startup-errors.patch new file mode 100644 index 000000000..ba5142af2 --- /dev/null +++ b/meta/packages/dbus/dbus/dbus-quiesce-startup-errors.patch @@ -0,0 +1,23 @@ +--- dbus-0.20-virgin-patches/bus/config-parser.c 2003-10-14 21:30:21.000000000 +0100 ++++ dbus-0.20/bus/config-parser.c 2004-02-10 00:40:05.000000000 +0000 +@@ -1710,8 +1710,18 @@ + { + if (!include_file (parser, &full_path, TRUE, error)) + { +- _dbus_string_free (&full_path); +- goto failed; ++ /* Debian patch to skip malformed /etc/dbus-1/system.d entries */ ++ /* ++ * _dbus_string_free (&full_path); ++ * goto failed; ++ */ ++ if (dbus_error_is_set (error)) ++ { ++ _dbus_warn("\nEncountered error '%s' while parsing '%s'\n", ++ error->message, ++ _dbus_string_get_const_data(&full_path)); ++ dbus_error_free (error); ++ } + } + } + diff --git a/meta/packages/dbus/dbus/dbussend.patch b/meta/packages/dbus/dbus/dbussend.patch new file mode 100644 index 000000000..49a251bbb --- /dev/null +++ b/meta/packages/dbus/dbus/dbussend.patch @@ -0,0 +1,399 @@ +Index: dbus-send.1 +=================================================================== +--- tools/dbus-send.1 (revision 691) ++++ tools/dbus-send.1 (working copy) +@@ -36,8 +36,8 @@ + specified. Following arguments, if any, are the message contents + (message arguments). These are given as a type name, a colon, and + then the value of the argument. The possible type names are: string, +-int32, uint32, double, byte, boolean. (D-BUS supports more types than +-these, but \fIdbus-send\fP currently does not.) ++int32, uint32, double, byte, boolean, array. (D-BUS supports more types ++than these, but \fIdbus-send\fP currently does not.) + + .PP + Here is an example invocation: +@@ -46,7 +46,8 @@ + dbus-send \-\-dest='org.freedesktop.ExampleService' \\ + /org/freedesktop/sample/object/name \\ + org.freedesktop.ExampleInterface.ExampleMethod \\ +- int32:47 string:'hello world' double:65.32 ++ int32:47 string:'hello world' double:65.32 \\ ++ array:byte[0,1,2] + + .fi + +Index: dbus-print-message.c +=================================================================== +--- tools/dbus-print-message.c (revision 691) ++++ tools/dbus-print-message.c (working copy) +@@ -39,6 +39,78 @@ + } + } + ++static void ++iterate (DBusMessageIter* iter, int entry_type) ++{ ++ do ++ { ++ char *str; ++ dbus_uint32_t uint32; ++ dbus_int32_t int32; ++ double d; ++ unsigned char byte; ++ dbus_bool_t boolean; ++ int type = dbus_message_iter_get_arg_type (iter); ++ ++ DBusMessageIter array_iter; ++ int array_type = DBUS_TYPE_INVALID; ++ ++ if (type == DBUS_TYPE_INVALID) ++ { ++ if (entry_type == DBUS_TYPE_INVALID) ++ break; ++ else ++ type == entry_type; ++ } ++ ++ switch (type) ++ { ++ case DBUS_TYPE_STRING: ++ str = dbus_message_iter_get_string (iter); ++ printf ("string:%s\n", str); ++ break; ++ ++ case DBUS_TYPE_INT32: ++ int32 = dbus_message_iter_get_int32 (iter); ++ printf ("int32:%d\n", int32); ++ break; ++ ++ case DBUS_TYPE_UINT32: ++ uint32 = dbus_message_iter_get_uint32 (iter); ++ printf ("int32:%u\n", uint32); ++ break; ++ ++ case DBUS_TYPE_DOUBLE: ++ d = dbus_message_iter_get_double (iter); ++ printf ("double:%f\n", d); ++ break; ++ ++ case DBUS_TYPE_BYTE: ++ byte = dbus_message_iter_get_byte (iter); ++ printf ("byte:%d\n", byte); ++ break; ++ ++ case DBUS_TYPE_BOOLEAN: ++ boolean = dbus_message_iter_get_boolean (iter); ++ printf ("boolean:%s\n", boolean ? "true" : "false"); ++ break; ++ ++ case DBUS_TYPE_ARRAY: ++ dbus_message_iter_init_array_iterator (iter, ++ &array_iter, ++ &array_type); ++ printf ("array[\n"); ++ iterate (&array_iter, array_type); ++ printf ("]\n"); ++ break; ++ ++ default: ++ printf ("(unknown arg type %d)\n", type); ++ break; ++ } ++ } while (dbus_message_iter_next (iter)); ++} ++ + void + print_message (DBusMessage *message) + { +@@ -81,55 +153,6 @@ + + dbus_message_iter_init (message, &iter); + +- do +- { +- int type = dbus_message_iter_get_arg_type (&iter); +- char *str; +- dbus_uint32_t uint32; +- dbus_int32_t int32; +- double d; +- unsigned char byte; +- dbus_bool_t boolean; +- +- if (type == DBUS_TYPE_INVALID) +- break; +- +- switch (type) +- { +- case DBUS_TYPE_STRING: +- str = dbus_message_iter_get_string (&iter); +- printf ("string:%s\n", str); +- break; +- +- case DBUS_TYPE_INT32: +- int32 = dbus_message_iter_get_int32 (&iter); +- printf ("int32:%d\n", int32); +- break; +- +- case DBUS_TYPE_UINT32: +- uint32 = dbus_message_iter_get_uint32 (&iter); +- printf ("int32:%u\n", uint32); +- break; +- +- case DBUS_TYPE_DOUBLE: +- d = dbus_message_iter_get_double (&iter); +- printf ("double:%f\n", d); +- break; +- +- case DBUS_TYPE_BYTE: +- byte = dbus_message_iter_get_byte (&iter); +- printf ("byte:%d\n", byte); +- break; +- +- case DBUS_TYPE_BOOLEAN: +- boolean = dbus_message_iter_get_boolean (&iter); +- printf ("boolean:%s\n", boolean ? "true" : "false"); +- break; +- +- default: +- printf ("(unknown arg type %d)\n", type); +- break; +- } +- } while (dbus_message_iter_next (&iter)); ++ iterate (&iter, DBUS_TYPE_INVALID); + } + +Index: dbus-send.c +=================================================================== +--- tools/dbus-send.c (revision 691) ++++ tools/dbus-send.c (working copy) +@@ -34,6 +34,146 @@ + exit (ecode); + } + ++ ++static int ++get_type (char **argv, char *arg) ++{ ++ int type; ++ ++ if (arg[0] == 0 || !strcmp (arg, "string")) ++ type = DBUS_TYPE_STRING; ++ else if (!strcmp (arg, "int32")) ++ type = DBUS_TYPE_INT32; ++ else if (!strcmp (arg, "uint32")) ++ type = DBUS_TYPE_UINT32; ++ else if (!strcmp (arg, "double")) ++ type = DBUS_TYPE_DOUBLE; ++ else if (!strcmp (arg, "byte")) ++ type = DBUS_TYPE_BYTE; ++ else if (!strcmp (arg, "boolean")) ++ type = DBUS_TYPE_BOOLEAN; ++ else if (!strcmp (arg, "array")) ++ type = DBUS_TYPE_ARRAY; ++ else ++ { ++ fprintf (stderr, "%s: Unknown type \"%s\"\n", argv[0], arg); ++ exit (1); ++ } ++ ++ return type; ++} ++ ++ ++static void ++append (char **argv, char *arg, char *c, DBusMessageIter *iter) ++{ ++ int type, atype = 0; ++ dbus_uint32_t uint32; ++ dbus_int32_t int32; ++ double d; ++ unsigned char byte; ++ DBusMessageIter array_iter; ++ int end_found = 0; ++ char *next; ++ ++ /* FIXME - we are ignoring OOM returns on all these functions */ ++ ++ type = get_type(argv, arg); ++ if (type == DBUS_TYPE_ARRAY) ++ { ++ arg = c; ++ c = strchr (c, '['); ++ if (c == NULL) ++ { ++ fprintf (stderr, "%s: Data item \"%s\" is badly formed\n", argv[0], arg); ++ exit (1); ++ } ++ ++ if (strchr(c, ']') == NULL) ++ { ++ fprintf (stderr, "%s: Data item \"%s\" is badly formed\n", argv[0], arg); ++ exit (1); ++ } ++ ++ *(c++) = 0; ++ ++ atype = get_type(argv, arg); ++ } ++ ++ ++ switch (type) ++ { ++ case DBUS_TYPE_BYTE: ++ byte = strtoul (c, NULL, 0); ++ dbus_message_iter_append_byte (iter, byte); ++ break; ++ ++ case DBUS_TYPE_DOUBLE: ++ d = strtod (c, NULL); ++ dbus_message_iter_append_double (iter, d); ++ break; ++ ++ case DBUS_TYPE_INT32: ++ int32 = strtol (c, NULL, 0); ++ dbus_message_iter_append_int32 (iter, int32); ++ break; ++ ++ case DBUS_TYPE_UINT32: ++ uint32 = strtoul (c, NULL, 0); ++ dbus_message_iter_append_uint32 (iter, uint32); ++ break; ++ ++ case DBUS_TYPE_STRING: ++ dbus_message_iter_append_string (iter, c); ++ break; ++ ++ case DBUS_TYPE_BOOLEAN: ++ if (strcmp(c, "true") == 0) ++ dbus_message_iter_append_boolean (iter, TRUE); ++ else if (strcmp(c, "false") == 0) ++ dbus_message_iter_append_boolean (iter, FALSE); ++ else ++ { ++ fprintf (stderr, "%s: Expected \"true\" or \"false\" instead of \"%s\"\n", argv[0], c); ++ exit (1); ++ } ++ break; ++ ++ case DBUS_TYPE_ARRAY: ++ /* Decompose parameters and put it as array */ ++ dbus_message_iter_append_array(iter, &array_iter, atype); ++ ++ while(!end_found) ++ { ++ next = strchr(c, ','); ++ if (next == NULL) ++ { ++ next = strchr(c, ']'); ++ ++ if (next != NULL) ++ next[0] = 0; ++ else ++ break; ++ ++ end_found = 1; ++ } ++ else ++ { ++ next[0] = 0; ++ next++; ++ } ++ ++ append (argv, arg, c, &array_iter); ++ c = next; ++ } ++ break; ++ ++ default: ++ fprintf (stderr, "%s: Unsupported data type\n", argv[0]); ++ exit (1); ++ } ++} ++ + int + main (int argc, char *argv[]) + { +@@ -174,12 +314,7 @@ + { + char *arg; + char *c; +- int type; +- dbus_uint32_t uint32; +- dbus_int32_t int32; +- double d; +- unsigned char byte; +- ++ + type = DBUS_TYPE_INVALID; + arg = argv[i++]; + c = strchr (arg, ':'); +@@ -192,67 +327,7 @@ + + *(c++) = 0; + +- if (arg[0] == 0 || !strcmp (arg, "string")) +- type = DBUS_TYPE_STRING; +- else if (!strcmp (arg, "int32")) +- type = DBUS_TYPE_INT32; +- else if (!strcmp (arg, "uint32")) +- type = DBUS_TYPE_UINT32; +- else if (!strcmp (arg, "double")) +- type = DBUS_TYPE_DOUBLE; +- else if (!strcmp (arg, "byte")) +- type = DBUS_TYPE_BYTE; +- else if (!strcmp (arg, "boolean")) +- type = DBUS_TYPE_BOOLEAN; +- else +- { +- fprintf (stderr, "%s: Unknown type \"%s\"\n", argv[0], arg); +- exit (1); +- } +- +- /* FIXME - we are ignoring OOM returns on all these functions */ +- switch (type) +- { +- case DBUS_TYPE_BYTE: +- byte = strtoul (c, NULL, 0); +- dbus_message_iter_append_byte (&iter, byte); +- break; +- +- case DBUS_TYPE_DOUBLE: +- d = strtod (c, NULL); +- dbus_message_iter_append_double (&iter, d); +- break; +- +- case DBUS_TYPE_INT32: +- int32 = strtol (c, NULL, 0); +- dbus_message_iter_append_int32 (&iter, int32); +- break; +- +- case DBUS_TYPE_UINT32: +- uint32 = strtoul (c, NULL, 0); +- dbus_message_iter_append_uint32 (&iter, uint32); +- break; +- +- case DBUS_TYPE_STRING: +- dbus_message_iter_append_string (&iter, c); +- break; +- +- case DBUS_TYPE_BOOLEAN: +- if (strcmp(c, "true") == 0) +- dbus_message_iter_append_boolean (&iter, TRUE); +- else if (strcmp(c, "false") == 0) +- dbus_message_iter_append_boolean (&iter, FALSE); +- else +- { +- fprintf (stderr, "%s: Expected \"true\" or \"false\" instead of \"%s\"\n", argv[0], c); +- exit (1); +- } +- break; +- +- default: +- fprintf (stderr, "%s: Unsupported data type\n", argv[0]); +- exit (1); +- } ++ append (argv, arg, c, &iter); + } + + if (print_reply) diff --git a/meta/packages/dbus/dbus/gettext.patch b/meta/packages/dbus/dbus/gettext.patch new file mode 100644 index 000000000..7042bd090 --- /dev/null +++ b/meta/packages/dbus/dbus/gettext.patch @@ -0,0 +1,164 @@ +Index: dbus-0.23/configure.in +=================================================================== +--- dbus-0.23.orig/configure.in 2005-04-02 17:14:37.780040976 -0500 ++++ dbus-0.23/configure.in 2005-04-02 17:14:38.024003888 -0500 +@@ -22,6 +22,9 @@ + AC_ISC_POSIX + AC_HEADER_STDC + ++AM_GNU_GETTEXT_VERSION(0.11.5) ++AM_GNU_GETTEXT([external], [need-ngettext]) ++ + AC_ARG_ENABLE(qt, [ --enable-qt enable Qt-friendly client library],enable_qt=$enableval,enable_qt=auto) + AC_ARG_ENABLE(glib, [ --enable-glib enable GLib-friendly client library],enable_glib=$enableval,enable_glib=auto) + AC_ARG_ENABLE(gtk, [ --enable-gtk enable GTK-requiring executables],enable_gtk=$enableval,enable_gtk=auto) +Index: dbus-0.23/glib/Makefile.am +=================================================================== +--- dbus-0.23.orig/glib/Makefile.am 2004-07-29 04:00:45.000000000 -0400 ++++ dbus-0.23/glib/Makefile.am 2005-04-02 17:22:27.302662688 -0500 +@@ -15,7 +15,7 @@ + dbus-gvalue.c \ + dbus-gvalue.h + +-libdbus_glib_1_la_LIBADD= $(DBUS_GLIB_LIBS) $(top_builddir)/dbus/libdbus-1.la ++libdbus_glib_1_la_LIBADD= $(DBUS_GLIB_LIBS) $(LIBINTL) $(top_builddir)/dbus/libdbus-1.la + ## don't export symbols that start with "_" (we use this + ## convention for internal symbols) + libdbus_glib_1_la_LDFLAGS= -export-symbols-regex "^[^_].*" +Index: dbus-0.23/glib/dbus-glib-tool.c +=================================================================== +--- dbus-0.23.orig/glib/dbus-glib-tool.c 2004-08-09 23:07:00.000000000 -0400 ++++ dbus-0.23/glib/dbus-glib-tool.c 2005-04-02 17:14:38.024003888 -0500 +@@ -26,8 +26,13 @@ + #include "dbus-gparser.h" + #include "dbus-gutils.h" + #include ++ ++#ifdef HAVE_GETTEXT + #include + #define _(x) dgettext (GETTEXT_PACKAGE, x) ++#else ++#define _(x) x ++#endif + #define N_(x) x + #include + #include +Index: dbus-0.23/glib/dbus-glib.c +=================================================================== +--- dbus-0.23.orig/glib/dbus-glib.c 2004-08-09 23:07:00.000000000 -0400 ++++ dbus-0.23/glib/dbus-glib.c 2005-04-02 17:14:38.024003888 -0500 +@@ -27,8 +27,12 @@ + #include "dbus-gtest.h" + #include "dbus-gutils.h" + ++#ifdef HAVE_GETTEXT + #include + #define _(x) dgettext (GETTEXT_PACKAGE, x) ++#else ++#define _(x) x ++#endif + #define N_(x) x + + /** +Index: dbus-0.23/glib/dbus-gmain.c +=================================================================== +--- dbus-0.23.orig/glib/dbus-gmain.c 2004-11-13 02:07:47.000000000 -0500 ++++ dbus-0.23/glib/dbus-gmain.c 2005-04-02 17:14:38.025003736 -0500 +@@ -27,8 +27,12 @@ + #include "dbus-gtest.h" + #include "dbus-gutils.h" + ++#ifdef HAVE_GETTEXT + #include + #define _(x) dgettext (GETTEXT_PACKAGE, x) ++#else ++#define _(x) x ++#endif + #define N_(x) x + + /** +Index: dbus-0.23/glib/dbus-gparser.c +=================================================================== +--- dbus-0.23.orig/glib/dbus-gparser.c 2004-08-09 23:07:00.000000000 -0400 ++++ dbus-0.23/glib/dbus-gparser.c 2005-04-02 17:14:38.025003736 -0500 +@@ -20,12 +20,18 @@ + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ ++ ++#include + #include "dbus-gparser.h" + #include "dbus-gidl.h" + #include + ++#ifdef HAVE_GETTEXT + #include + #define _(x) gettext ((x)) ++#else ++#define _(x) x ++#endif + #define N_(x) x + + #ifndef DOXYGEN_SHOULD_SKIP_THIS +Index: dbus-0.23/tools/Makefile.am +=================================================================== +--- dbus-0.23.orig/tools/Makefile.am 2004-04-21 17:29:07.000000000 -0400 ++++ dbus-0.23/tools/Makefile.am 2005-04-02 17:22:00.712704976 -0500 +@@ -37,8 +37,8 @@ + + dbus_send_LDADD= $(top_builddir)/dbus/libdbus-1.la + dbus_monitor_LDADD= $(top_builddir)/glib/libdbus-glib-1.la +-dbus_launch_LDADD= $(DBUS_X_LIBS) +-dbus_viewer_LDADD= $(DBUS_GLIB_TOOL_LIBS) $(top_builddir)/glib/libdbus-gtool.la $(DBUS_GTK_LIBS) ++dbus_launch_LDADD= $(DBUS_X_LIBS) $(LIBINTL) ++dbus_viewer_LDADD= $(DBUS_GLIB_TOOL_LIBS) $(LIBINTL) $(top_builddir)/glib/libdbus-gtool.la $(DBUS_GTK_LIBS) + + man_MANS = dbus-send.1 dbus-monitor.1 dbus-launch.1 dbus-cleanup-sockets.1 + EXTRA_DIST = $(man_MANS) +Index: dbus-0.23/tools/dbus-launch.c +=================================================================== +--- dbus-0.23.orig/tools/dbus-launch.c 2004-08-09 23:07:01.000000000 -0400 ++++ dbus-0.23/tools/dbus-launch.c 2005-04-02 17:14:38.026003584 -0500 +@@ -22,6 +22,8 @@ + */ + #include + #include ++#include ++#include + #include + #include + #include +Index: dbus-0.23/tools/dbus-tree-view.c +=================================================================== +--- dbus-0.23.orig/tools/dbus-tree-view.c 2004-08-09 23:07:01.000000000 -0400 ++++ dbus-0.23/tools/dbus-tree-view.c 2005-04-02 17:14:38.026003584 -0500 +@@ -24,8 +24,12 @@ + #include + #include "dbus-tree-view.h" + ++#ifdef HAVE_GETTEXT + #include + #define _(x) dgettext (GETTEXT_PACKAGE, x) ++#else ++#define _(x) x ++#endif + #define N_(x) x + + enum +Index: dbus-0.23/tools/dbus-viewer.c +=================================================================== +--- dbus-0.23.orig/tools/dbus-viewer.c 2004-08-09 23:07:01.000000000 -0400 ++++ dbus-0.23/tools/dbus-viewer.c 2005-04-02 17:14:38.027003432 -0500 +@@ -30,8 +30,12 @@ + #include + #include + ++#ifdef HAVE_GETTEXT + #include + #define _(x) dgettext (GETTEXT_PACKAGE, x) ++#else ++#define _(x) x ++#endif + #define N_(x) x + + typedef struct diff --git a/meta/packages/dbus/dbus/no-bindings.patch b/meta/packages/dbus/dbus/no-bindings.patch new file mode 100644 index 000000000..12ba00ff7 --- /dev/null +++ b/meta/packages/dbus/dbus/no-bindings.patch @@ -0,0 +1,12 @@ +--- dbus-0.34/tools/Makefile.am.old 2005-06-27 21:48:44.000000000 +0100 ++++ dbus-0.34/tools/Makefile.am 2005-06-27 21:49:04.000000000 +0100 +@@ -6,9 +6,6 @@ + nodist_libdbus_glib_HEADERS = dbus-glib-bindings.h + libdbus_glibdir = $(includedir)/dbus-1.0/dbus + +-dbus-glib-bindings.h: dbus-bus-introspect.xml $(top_builddir)/glib/dbus-binding-tool +- $(top_builddir)/glib/dbus-binding-tool --mode=glib-client --output=dbus-glib-bindings.h dbus-bus-introspect.xml +- + BUILT_SOURCES = dbus-glib-bindings.h dbus-bus-introspect.xml + + else diff --git a/meta/packages/dbus/dbus/no-examples.patch b/meta/packages/dbus/dbus/no-examples.patch new file mode 100644 index 000000000..8767705ce --- /dev/null +++ b/meta/packages/dbus/dbus/no-examples.patch @@ -0,0 +1,8 @@ +--- dbus-0.36.2/glib/Makefile.am.orig 2005-09-06 17:30:26 +0200 ++++ dbus-0.36.2/glib/Makefile.am 2005-09-06 17:30:34 +0200 +@@ -1,4 +1,4 @@ +-SUBDIRS = . examples ++SUBDIRS = . + + INCLUDES=-I$(top_srcdir) $(DBUS_CLIENT_CFLAGS) $(DBUS_GLIB_CFLAGS) $(DBUS_GLIB_TOOL_CFLAGS) -DDBUS_COMPILATION=1 -DDBUS_LOCALEDIR=\"$(prefix)/@DATADIRNAME@/locale\" + diff --git a/meta/packages/dbus/dbus/no-introspect.patch b/meta/packages/dbus/dbus/no-introspect.patch new file mode 100644 index 000000000..d7ae8e4ca --- /dev/null +++ b/meta/packages/dbus/dbus/no-introspect.patch @@ -0,0 +1,19 @@ +--- dbus-0.34/tools/Makefile.am.old 2005-06-27 20:54:36.000000000 +0100 ++++ dbus-0.34/tools/Makefile.am 2005-06-27 20:54:43.000000000 +0100 +@@ -21,16 +21,6 @@ + GTK_TOOLS= + endif + +-if HAVE_GLIB +-noinst_PROGRAMS = print-introspect +- +-print_introspect_SOURCES = print-introspect.c +-print_introspect_LDADD = $(top_builddir)/glib/libdbus-glib-1.la +- +-dbus-bus-introspect.xml: $(top_builddir)/bus/dbus-daemon dbus-launch print-introspect $(top_builddir)/bus/dbus-daemon +- DBUS_TOP_BUILDDIR=$(top_builddir) $(srcdir)/run-with-tmp-session-bus.sh ./print-introspect org.freedesktop.DBus /org/freedesktop/DBus > dbus-bus-introspect.xml.tmp && mv dbus-bus-introspect.xml.tmp dbus-bus-introspect.xml +-endif +- + bin_PROGRAMS=dbus-send $(GLIB_TOOLS) dbus-launch dbus-cleanup-sockets $(GTK_TOOLS) + + dbus_send_SOURCES= \ diff --git a/meta/packages/dbus/dbus/spawn-priority.diff b/meta/packages/dbus/dbus/spawn-priority.diff new file mode 100644 index 000000000..954d2512f --- /dev/null +++ b/meta/packages/dbus/dbus/spawn-priority.diff @@ -0,0 +1,17 @@ +diff -ur dbus/dbus/dbus-spawn.c dbus.work/dbus/dbus-spawn.c +--- dbus/dbus/dbus-spawn.c 2005-03-14 14:25:02.849823496 +0200 ++++ dbus.work/dbus/dbus-spawn.c 2005-03-14 14:34:43.947483224 +0200 +@@ -1117,6 +1117,12 @@ + } + else if (grandchild_pid == 0) + { ++ int p; ++ errno = 0; ++ p = getpriority(PRIO_PROCESS, 0); ++ if (!errno && p < 0) { ++ setpriority(PRIO_PROCESS, 0, 0); ++ } + do_exec (child_err_report_pipe[WRITE_END], + argv, + child_setup, user_data); +Only in dbus.work/dbus: dbus-spawn.c~ diff --git a/meta/packages/dbus/dbus/tmpdir.patch b/meta/packages/dbus/dbus/tmpdir.patch new file mode 100644 index 000000000..838b903f0 --- /dev/null +++ b/meta/packages/dbus/dbus/tmpdir.patch @@ -0,0 +1,30 @@ +--- dbus-0.22/configure.in.orig 2004-08-13 00:57:16.000000000 +0200 ++++ dbus-0.22/configure.in 2004-12-30 21:15:57.000000000 +0100 +@@ -1047,15 +1048,18 @@ + AC_SUBST(ABSOLUTE_TOP_BUILDDIR) + + #### Find socket directories +-if ! test -z "$TMPDIR" ; then +- DEFAULT_SOCKET_DIR=$TMPDIR +-elif ! test -z "$TEMP" ; then +- DEFAULT_SOCKET_DIR=$TEMP +-elif ! test -z "$TMP" ; then +- DEFAULT_SOCKET_DIR=$TMP +-else +- DEFAULT_SOCKET_DIR=/tmp +-fi ++#if ! test -z "$TMPDIR" ; then ++# DEFAULT_SOCKET_DIR=$TMPDIR ++#elif ! test -z "$TEMP" ; then ++# DEFAULT_SOCKET_DIR=$TEMP ++#elif ! test -z "$TMP" ; then ++# DEFAULT_SOCKET_DIR=$TMP ++#else ++# DEFAULT_SOCKET_DIR=/tmp ++#fi ++ ++# checks disabled to avoid expanding this at build time ++DEFAULT_SOCKET_DIR=/tmp + + if ! test -z "$with_test_socket_dir" ; then + TEST_SOCKET_DIR="$with_test_socket_dir" diff --git a/meta/packages/dbus/dbus/tools.diff b/meta/packages/dbus/dbus/tools.diff new file mode 100644 index 000000000..d9e871298 --- /dev/null +++ b/meta/packages/dbus/dbus/tools.diff @@ -0,0 +1,12 @@ +Only in /home/kihamala/svn/dbus/tools: .svn +diff -ur tools/dbus-launch.c /home/kihamala/svn/dbus/tools/dbus-launch.c +--- tools/dbus-launch.c 2004-08-10 06:07:01.000000000 +0300 ++++ /home/kihamala/svn/dbus/tools/dbus-launch.c 2005-02-09 17:59:05.000000000 +0200 +@@ -20,6 +20,7 @@ + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ ++#include + #include + #include + #include diff --git a/meta/packages/dbus/dbus_0.60.bb b/meta/packages/dbus/dbus_0.60.bb new file mode 100644 index 000000000..e82745737 --- /dev/null +++ b/meta/packages/dbus/dbus_0.60.bb @@ -0,0 +1,13 @@ +include dbus_${PV}.inc + + +DEPENDS = "expat glib-2.0 virtual/libintl dbus-native" +SRC_URI_EXTRA = "file://no-introspect.patch;patch=1 file://no-bindings.patch;patch=1" + +FILES_${PN} += "${bindir}/dbus-daemon" +FILES_${PN}-dev += "${bindir}/dbus-binding-tool" + +do_configure_prepend() { + install -m 0644 ${STAGING_DIR}/${BUILD_SYS}/share/dbus/dbus-bus-introspect.xml ${S}/tools/ + install -m 0644 ${STAGING_DIR}/${BUILD_SYS}/share/dbus/dbus-glib-bindings.h ${S}/tools/ +} diff --git a/meta/packages/dbus/dbus_0.60.inc b/meta/packages/dbus/dbus_0.60.inc new file mode 100644 index 000000000..70546ed5b --- /dev/null +++ b/meta/packages/dbus/dbus_0.60.inc @@ -0,0 +1,64 @@ +SECTION = "base" +PR = "r0" +HOMEPAGE = "http://www.freedesktop.org/Software/dbus" +DESCRIPTION = "message bus system for applications to talk to one another" +LICENSE = "GPL" +DEPENDS = "expat glib-2.0 virtual/libintl" + +SRC_URI = "http://freedesktop.org/software/dbus/releases/dbus-${PV}.tar.gz \ + file://cross.patch;patch=1 \ + file://tmpdir.patch;patch=1 \ + file://dbus-1.init \ + file://no-examples.patch;patch=1 \ + ${SRC_URI_EXTRA}" + +inherit autotools pkgconfig update-rc.d gettext + +INITSCRIPT_NAME = "dbus-1" +INITSCRIPT_PARAMS = "defaults" + +CONFFILES_${PN} = "${sysconfdir}/dbus-1/system.conf ${sysconfdir}/dbus-1/session.conf" + +FILES_${PN} = "${bindir}/dbus-daemon ${bindir}/dbus-launch ${bindir}/dbus-cleanup-sockets ${bindir}/dbus-send ${bindir}/dbus-monitor ${sysconfdir} ${datadir}/dbus-1/services ${libdir}/lib*.so.*" +FILES_${PN}-dev += "${libdir}/dbus-1.0/include ${bindir}/dbus-glib-tool" + +pkg_postinst_dbus() { +#!/bin/sh + +# can't do adduser stuff offline +if [ "x$D" != "x" ]; then + exit 1 +fi + +MESSAGEUSER=messagebus +MESSAGEHOME=/var/run/dbus + +mkdir -p $MESSAGEHOME || true +chgrp "$MESSAGEUSER" "$MESSAGEHOME" 2>/dev/null || addgroup "$MESSAGEUSER" +chown "$MESSAGEUSER"."$MESSAGEUSER" "$MESSAGEHOME" 2>/dev/null || adduser --system --home "$MESSAGEHOME" --no-create-home --disabled-password --ingroup "$MESSAGEUSER" "$MESSAGEUSER" +} + +EXTRA_OECONF = "--disable-qt --disable-gtk --disable-tests \ + --disable-checks --disable-xml-docs --disable-doxygen-docs \ + --with-xml=expat --without-x" + + +do_stage () { + oe_libinstall -so -C dbus libdbus-1 ${STAGING_LIBDIR} + oe_libinstall -so -C glib libdbus-glib-1 ${STAGING_LIBDIR} + + autotools_stage_includes + + mkdir -p ${STAGING_LIBDIR}/dbus-1.0/include/dbus/ + install -m 0644 dbus/dbus-arch-deps.h ${STAGING_LIBDIR}/dbus-1.0/include/dbus/ +} + +do_install_append () { + install -d ${D}${sysconfdir}/init.d + install -m 0755 ${WORKDIR}/dbus-1.init ${D}${sysconfdir}/init.d/dbus-1 +} + +python populate_packages_prepend () { + if (bb.data.getVar('DEBIAN_NAMES', d, 1)): + bb.data.setVar('PKG_dbus', 'dbus-1', d) +} diff --git a/meta/packages/dropbear/dropbear.inc b/meta/packages/dropbear/dropbear.inc new file mode 100644 index 000000000..301ac24cb --- /dev/null +++ b/meta/packages/dropbear/dropbear.inc @@ -0,0 +1,73 @@ +DESCRIPTION = "Dropbear is a lightweight SSH and SCP Implementation" +HOMEPAGE = "http://matt.ucc.asn.au/dropbear/dropbear.html" +SECTION = "console/network" +LICENSE = "MIT" +DEPENDS = "zlib" +PROVIDES = "ssh sshd" +RPROVIDES = "ssh sshd" + +SRC_URI = "http://matt.ucc.asn.au/dropbear/releases/dropbear-${PV}.tar.gz \ + file://urandom-xauth-changes-to-options.h.patch;patch=1 \ + file://configure.patch;patch=1 \ + file://fix-2kb-keys.patch;patch=1 \ + file://allow-nopw.patch \ + file://init" + +inherit autotools update-rc.d + +INITSCRIPT_NAME = "dropbear" +INITSCRIPT_PARAMS = "defaults 10" + +CFLAGS_prepend = " -I. " +LD = "${CC}" + +SBINCOMMANDS = "dropbear dropbearkey dropbearconvert" +BINCOMMANDS = "dbclient ssh scp" +EXTRA_OEMAKE = 'MULTI=1 SCPPROGRESS=1 PROGRAMS="${SBINCOMMANDS} ${BINCOMMANDS}"' + +do_configure_prepend() { + if [ "x${DISTRO}" != "xfamiliar" -a "${DISTRO_TYPE}" == "debug" ]; then + oenote "WARNING: applying allow-nopw.patch which allows password-less logins!" + patch -p1 < ${WORKDIR}/allow-nopw.patch + fi +} + +do_install() { + install -d ${D}${sysconfdir} \ + ${D}${sysconfdir}/init.d \ + ${D}${sysconfdir}/default \ + ${D}${sysconfdir}/dropbear \ + ${D}${bindir} \ + ${D}${sbindir} \ + ${D}${localstatedir} + + install -m 0755 dropbearmulti ${D}${sbindir}/ + ln -s ${sbindir}/dropbearmulti ${D}${bindir}/dbclient + + for i in ${SBINCOMMANDS} + do + ln -s ./dropbearmulti ${D}${sbindir}/$i + done + cat ${WORKDIR}/init | sed -e 's,/etc,${sysconfdir},g' \ + -e 's,/usr/sbin,${sbindir},g' \ + -e 's,/var,${localstatedir},g' \ + -e 's,/usr/bin,${bindir},g' \ + -e 's,/usr,${prefix},g' > ${D}${sysconfdir}/init.d/dropbear + chmod 755 ${D}${sysconfdir}/init.d/dropbear +} + +pkg_postinst () { + update-alternatives --install ${bindir}/scp scp ${sbindir}/dropbearmulti 20 + update-alternatives --install ${bindir}/ssh ssh ${sbindir}/dropbearmulti 20 +} + +pkg_postrm_append () { + if [ -f "${sysconfdir}/dropbear/dropbear_rsa_host_key" ]; then + rm ${sysconfdir}/dropbear/dropbear_rsa_host_key + fi + if [ -f "${sysconfdir}/dropbear/dropbear_dss_host_key" ]; then + rm ${sysconfdir}/dropbear/dropbear_dss_host_key + fi + update-alternatives --remove ssh ${bindir}/dropbearmulti + update-alternatives --remove scp ${bindir}/dropbearmulti +} diff --git a/meta/packages/dropbear/dropbear/allow-nopw.patch b/meta/packages/dropbear/dropbear/allow-nopw.patch new file mode 100644 index 000000000..1a709b8da --- /dev/null +++ b/meta/packages/dropbear/dropbear/allow-nopw.patch @@ -0,0 +1,37 @@ +diff -Nurd dropbear-0.45/svr-auth.c dropbear-0.45.patched/svr-auth.c +--- dropbear-0.45/svr-auth.c 2005-03-06 20:27:02.000000000 -0800 ++++ dropbear-0.45.patched/svr-auth.c 2005-03-08 15:22:43.998592744 -0800 +@@ -237,6 +237,7 @@ + } + + /* check for an empty password */ ++#ifdef DISALLOW_EMPTY_PW + if (ses.authstate.pw->pw_passwd[0] == '\0') { + TRACE(("leave checkusername: empty pword")) + dropbear_log(LOG_WARNING, "user '%s' has blank password, rejected", +@@ -244,7 +245,7 @@ + send_msg_userauth_failure(0, 1); + return DROPBEAR_FAILURE; + } +- ++#endif + TRACE(("shell is %s", ses.authstate.pw->pw_shell)) + + /* check that the shell is set */ +diff -Nurd dropbear-0.45/svr-authpasswd.c dropbear-0.45.patched/svr-authpasswd.c +--- dropbear-0.45/svr-authpasswd.c 2005-03-06 20:27:02.000000000 -0800 ++++ dropbear-0.45.patched/svr-authpasswd.c 2005-03-08 15:22:44.010591023 -0800 +@@ -64,9 +64,13 @@ + * since the shadow password may differ to that tested + * in auth.c */ + if (passwdcrypt[0] == '\0') { ++#ifdef DISALLOW_EMPTY_PASSWD + dropbear_log(LOG_WARNING, "user '%s' has blank password, rejected", + ses.authstate.printableuser); + send_msg_userauth_failure(0, 1); ++#else ++ send_msg_userauth_success(); ++#endif + return; + } + diff --git a/meta/packages/dropbear/dropbear/chansession-security-fix.patch b/meta/packages/dropbear/dropbear/chansession-security-fix.patch new file mode 100644 index 000000000..bc4c461fe --- /dev/null +++ b/meta/packages/dropbear/dropbear/chansession-security-fix.patch @@ -0,0 +1,74 @@ +Date: Sun, 11 Dec 2005 23:30:02 +0800 +From: Matt Johnston +To: dropbear@ucc.gu.uwa.edu.au +Subject: Dropbear 0.47 (and security fix) +Message-ID: <20051211153002.GH28839@ucc.gu.uwa.edu.au> + +Hi all. + +I've put up a new release 0.47 of Dropbear, which has +various fixes and new features - see the change summary +below. +http://matt.ucc.asn.au/dropbear/dropbear.html is the +url as usual or directly at +http://matt.ucc.asn.au/dropbear/dropbear-0.47.tar.bz2 + +This release also fixes a potential security issue, which +may allow authenticated users to run arbitrary code as the +server user. I'm unsure exactly how likely it is to be +exploitable, but anyone who's running a multi-user server is +advised to upgrade. For older releases, the patch is: +(against chanesssion.c for 0.43 and earlier). + +--- dropbear/svr-chansession.c ++++ dropbear/svr-chansession.c +@@ -810,7 +810,7 @@ + /* need to increase size */ + if (i == svr_ses.childpidsize) { + svr_ses.childpids = (struct ChildPid*)m_realloc(svr_ses.childpids, +- sizeof(struct ChildPid) * svr_ses.childpidsize+1); ++ sizeof(struct ChildPid) * (svr_ses.childpidsize+1)); + svr_ses.childpidsize++; + } + + +Matt + + +0.47 - Thurs Dec 8 2005 + +- SECURITY: fix for buffer allocation error in server code, could potentially + allow authenticated users to gain elevated privileges. All multi-user systems + running the server should upgrade (or apply the patch available on the + Dropbear webpage). + +- Fix channel handling code so that redirecting to /dev/null doesn't use + 100% CPU. + +- Turn on zlib compression for dbclient. + +- Set "low delay" TOS bit, can significantly improve interactivity + over some links. + +- Added client keyboard-interactive mode support, allows operation with + newer OpenSSH servers in default config. + +- Log when pubkey auth fails because of bad ~/.ssh/authorized_keys permissions + +- Improve logging of assertions + +- Added aes-256 cipher and sha1-96 hmac. + +- Fix twofish so that it actually works. + +- Improve PAM prompt comparison. + +- Added -g (dbclient) and -a (dropbear server) options to allow + connections to listening forwarded ports from remote machines. + +- Various other minor fixes + +- Compile fixes for glibc 2.1 (ss_family vs __ss_family) and NetBSD + (netinet/in_systm.h needs to be included). + + diff --git a/meta/packages/dropbear/dropbear/configure.patch b/meta/packages/dropbear/dropbear/configure.patch new file mode 100644 index 000000000..9ae84b260 --- /dev/null +++ b/meta/packages/dropbear/dropbear/configure.patch @@ -0,0 +1,27 @@ +diff -Nurd dropbear-0.45/configure.in dropbear-0.45.patched/configure.in +--- dropbear-0.45/configure.in 2005-03-06 20:27:02.000000000 -0800 ++++ dropbear-0.45.patched/configure.in 2005-03-08 15:22:44.040586721 -0800 +@@ -161,15 +161,20 @@ + AC_MSG_RESULT(Not using openpty) + else + AC_MSG_RESULT(Using openpty if available) +- AC_SEARCH_LIBS(openpty, util, [AC_DEFINE(HAVE_OPENPTY,,Have openpty() function)]) ++ AC_SEARCH_LIBS(openpty, util, [dropbear_cv_func_have_openpty=yes]) + fi + ], + [ + AC_MSG_RESULT(Using openpty if available) +- AC_SEARCH_LIBS(openpty, util, [AC_DEFINE(HAVE_OPENPTY)]) ++ AC_SEARCH_LIBS(openpty, util, [dropbear_cv_func_have_openpty=yes]) + ] + ) +- ++ ++if test "x$dropbear_cv_func_have_openpty" = "xyes"; then ++ AC_DEFINE(HAVE_OPENPTY,,Have openpty() function) ++ no_ptc_check=yes ++ no_ptmx_check=yes ++fi + + AC_ARG_ENABLE(syslog, + [ --disable-syslog Don't include syslog support], diff --git a/meta/packages/dropbear/dropbear/fix-2kb-keys.patch b/meta/packages/dropbear/dropbear/fix-2kb-keys.patch new file mode 100644 index 000000000..ba2b19d44 --- /dev/null +++ b/meta/packages/dropbear/dropbear/fix-2kb-keys.patch @@ -0,0 +1,11 @@ +diff -Nurd dropbear-0.45/kex.h dropbear-0.45.patched/kex.h +--- dropbear-0.45/kex.h 2005-03-06 20:27:02.000000000 -0800 ++++ dropbear-0.45.patched/kex.h 2005-03-08 15:22:44.064583279 -0800 +@@ -64,6 +64,6 @@ + + }; + +-#define MAX_KEXHASHBUF 2000 ++#define MAX_KEXHASHBUF 3000 + + #endif /* _KEX_H_ */ diff --git a/meta/packages/dropbear/dropbear/init b/meta/packages/dropbear/dropbear/init new file mode 100755 index 000000000..d019bdb4b --- /dev/null +++ b/meta/packages/dropbear/dropbear/init @@ -0,0 +1,98 @@ +#!/bin/sh +# +# Do not configure this file. Edit /etc/default/dropbear instead! +# + +PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin +DAEMON=/usr/sbin/dropbear +NAME=dropbear +DESC="Dropbear SSH server" + +DROPBEAR_PORT=22 +DROPBEAR_EXTRA_ARGS= +NO_START=0 + +set -e + +test ! -r /etc/default/dropbear || . /etc/default/dropbear +test "$NO_START" = "0" || exit 0 +test -x "$DAEMON" || exit 0 +test ! -h /var/service/dropbear || exit 0 + +readonly_rootfs=0 +for flag in `awk '{ if ($2 == "/") { split($4,FLAGS,",") } }; END { for (f in FLAGS) print FLAGS[f] }' &2 + exit 1 + ;; +esac + +exit 0 diff --git a/meta/packages/dropbear/dropbear/urandom-xauth-changes-to-options.h.patch b/meta/packages/dropbear/dropbear/urandom-xauth-changes-to-options.h.patch new file mode 100644 index 000000000..e2b1dd5da --- /dev/null +++ b/meta/packages/dropbear/dropbear/urandom-xauth-changes-to-options.h.patch @@ -0,0 +1,21 @@ +diff -Nurd dropbear-0.45/options.h dropbear-0.45.patched/options.h +--- dropbear-0.45/options.h 2005-03-06 20:27:02.000000000 -0800 ++++ dropbear-0.45.patched/options.h 2005-03-08 15:25:09.368742090 -0800 +@@ -143,7 +143,7 @@ + * however significantly reduce the security of your ssh connections + * if the PRNG state becomes guessable - make sure you know what you are + * doing if you change this. */ +-#define DROPBEAR_RANDOM_DEV "/dev/random" ++#define DROPBEAR_RANDOM_DEV "/dev/urandom" + + /* prngd must be manually set up to produce output */ + /*#define DROPBEAR_PRNGD_SOCKET "/var/run/dropbear-rng"*/ +@@ -167,7 +167,7 @@ + /* The command to invoke for xauth when using X11 forwarding. + * "-q" for quiet */ + #ifndef XAUTH_COMMAND +-#define XAUTH_COMMAND "/usr/X11R6/bin/xauth -q" ++#define XAUTH_COMMAND "xauth -q" + #endif + + /* if you want to enable running an sftp server (such as the one included with diff --git a/meta/packages/dropbear/dropbear_0.47.bb b/meta/packages/dropbear/dropbear_0.47.bb new file mode 100644 index 000000000..5990260b8 --- /dev/null +++ b/meta/packages/dropbear/dropbear_0.47.bb @@ -0,0 +1,3 @@ +include dropbear.inc + +PR = "r2" diff --git a/meta/packages/e2fsprogs/e2fsprogs-1.38/no-hardlinks.patch b/meta/packages/e2fsprogs/e2fsprogs-1.38/no-hardlinks.patch new file mode 100644 index 000000000..979f0d1f0 --- /dev/null +++ b/meta/packages/e2fsprogs/e2fsprogs-1.38/no-hardlinks.patch @@ -0,0 +1,82 @@ +--- e2fsprogs-1.38/misc/Makefile.in.orig 2005-11-08 23:56:06.000000000 +0100 ++++ e2fsprogs-1.38/misc/Makefile.in 2005-11-08 23:59:15.000000000 +0100 +@@ -230,17 +230,13 @@ + $(INSTALL_PROGRAM) $$i $(DESTDIR)$(sbindir)/$$i; \ + done + @echo " LINK $(root_sbindir)/mkfs.ext2" +- @$(LN) -f $(DESTDIR)$(root_sbindir)/mke2fs \ +- $(DESTDIR)$(root_sbindir)/mkfs.ext2 ++ @(cd $(DESTDIR)$(root_sbindir) && $(LN_S) -f mke2fs mkfs.ext2) + @echo " LINK $(root_sbindir)/mkfs.ext3" +- @$(LN) -f $(DESTDIR)$(root_sbindir)/mke2fs \ +- $(DESTDIR)$(root_sbindir)/mkfs.ext3 ++ @(cd $(DESTDIR)$(root_sbindir) && $(LN_S) -f mke2fs mkfs.ext3) + @echo " LINK $(root_sbindir)/e2label" +- @$(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \ +- $(DESTDIR)$(root_sbindir)/e2label ++ @(cd $(DESTDIR)$(root_sbindir) && $(LN_S) -f tune2fs e2label) + @echo " LINK $(root_sbindir)/findfs" +- @$(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \ +- $(DESTDIR)$(root_sbindir)/findfs ++ @(cd $(DESTDIR)$(root_sbindir) && $(LN_S) -f tune2fs findfs) + @for i in $(UPROGS); do \ + echo " INSTALL $(bindir)/$$i"; \ + $(INSTALL_PROGRAM) $$i $(DESTDIR)$(bindir)/$$i; \ +@@ -259,11 +255,9 @@ + @$(RM) -f $(DESTDIR)$(man8dir)/mkfs.ext2.8.gz \ + $(DESTDIR)$(man8dir)/mkfs.ext3.8.gz + @echo " LINK mkfs.ext2.8" +- @$(LN) -f $(DESTDIR)$(man8dir)/mke2fs.8 \ +- $(DESTDIR)$(man8dir)/mkfs.ext2.8 ++ @(cd $(DESTDIR)$(man8dir) && $(LN_S) -f mke2fs.8 mkfs.ext2.8) + @echo " LINK mkfs.ext3.8" +- @$(LN) -f $(DESTDIR)$(man8dir)/mke2fs.8 \ +- $(DESTDIR)$(man8dir)/mkfs.ext3.8 ++ @(cd $(DESTDIR)$(man8dir) && $(LN_S) -f mke2fs.8 mkfs.ext3.8) + @for i in $(UMANPAGES); do \ + $(RM) -f $(DESTDIR)$(man1dir)/$$i.gz; \ + echo " INSTALL_DATA $(man1dir)/$$i"; \ +--- e2fsprogs-1.38/lib/uuid/Makefile.in.orig 2005-11-08 23:54:17.000000000 +0100 ++++ e2fsprogs-1.38/lib/uuid/Makefile.in 2005-11-08 23:55:51.000000000 +0100 +@@ -146,9 +146,9 @@ + @$(RM) -f $(DESTDIR)$(man3dir)/uuid_generate_random.3.gz \ + $(DESTDIR)$(man3dir)/uuid_generate_time.3.gz + @echo " LINK $(man3dir)/uuid_generate_random.3" +- @$(LN) -f $(DESTDIR)$(man3dir)/uuid_generate.3 $(DESTDIR)$(man3dir)/uuid_generate_random.3 ++ @(cd $(DESTDIR)$(man3dir) && $(LN_S) -f uuid_generate.3 uuid_generate_random.3) + @echo " LINK $(man3dir)/uuid_generate_time.3" +- @$(LN) -f $(DESTDIR)$(man3dir)/uuid_generate.3 $(DESTDIR)$(man3dir)/uuid_generate_time.3 ++ @(cd $(DESTDIR)$(man3dir) && $(LN_S) -f uuid_generate.3 uuid_generate_time.3) + @echo " INSTALL_DATA $(libdir)/pkgconfig/uuid.pc" + @$(INSTALL_DATA) uuid.pc $(DESTDIR)$(libdir)/pkgconfig/uuid.pc + +--- e2fsprogs-1.38/e2fsck/Makefile.in.orig 2005-11-08 23:53:07.000000000 +0100 ++++ e2fsprogs-1.38/e2fsck/Makefile.in 2005-11-08 23:53:43.000000000 +0100 +@@ -161,11 +161,9 @@ + $(INSTALL_PROGRAM) $$i $(DESTDIR)$(root_sbindir)/$$i; \ + done + @echo " LINK $(root_sbindir)/fsck.ext2" +- @$(LN) -f $(DESTDIR)$(root_sbindir)/e2fsck \ +- $(DESTDIR)$(root_sbindir)/fsck.ext2 ++ @(cd $(DESTDIR)$(root_sbindir) && $(LN_S) -f e2fsck fsck.ext2) + @echo " LINK $(root_sbindir)/fsck.ext3" +- @$(LN) -f $(DESTDIR)$(root_sbindir)/e2fsck \ +- $(DESTDIR)$(root_sbindir)/fsck.ext3 ++ @(cd $(DESTDIR)$(root_sbindir) && $(LN_S) -f e2fsck fsck.ext3) + @for i in $(MANPAGES); do \ + for j in $(COMPRESS_EXT); do \ + $(RM) -f $(DESTDIR)$(man8dir)/$$i.$$j; \ +@@ -174,11 +172,9 @@ + $(INSTALL_DATA) $$i $(DESTDIR)$(man8dir)/$$i; \ + done + @echo " LINK $(man8dir)/fsck.ext2.8" +- @$(LN) -f $(DESTDIR)$(man8dir)/e2fsck.8 \ +- $(DESTDIR)$(man8dir)/fsck.ext2.8 ++ @(cd $(DESTDIR)$(man8dir) && $(LN_S) -f e2fsck.8 fsck.ext2.8) + @echo " LINK $(man8dir)/fsck.ext3.8" +- @$(LN) -f $(DESTDIR)$(man8dir)/e2fsck.8 \ +- $(DESTDIR)$(man8dir)/fsck.ext3.8 ++ @(cd $(DESTDIR)$(man8dir) && $(LN_S) -f e2fsck.8 fsck.ext3.8) + + install-strip: install + @for i in $(PROGS); do \ diff --git a/meta/packages/e2fsprogs/e2fsprogs/compile-subst.patch b/meta/packages/e2fsprogs/e2fsprogs/compile-subst.patch new file mode 100644 index 000000000..ccac8ea06 --- /dev/null +++ b/meta/packages/e2fsprogs/e2fsprogs/compile-subst.patch @@ -0,0 +1,16 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- e2fsprogs-1.33/util/subst.c~compile-subst ++++ e2fsprogs-1.33/util/subst.c +@@ -10,7 +10,7 @@ + #include + #include + #include +-#include ++//#include + + #ifdef HAVE_GETOPT_H + #include diff --git a/meta/packages/e2fsprogs/e2fsprogs/configure.patch b/meta/packages/e2fsprogs/e2fsprogs/configure.patch new file mode 100644 index 000000000..b00e5ea70 --- /dev/null +++ b/meta/packages/e2fsprogs/e2fsprogs/configure.patch @@ -0,0 +1,122 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- e2fsprogs-1.33/./lib/uuid/configure.in~configure ++++ e2fsprogs-1.33/./lib/uuid/configure.in +@@ -2,9 +2,11 @@ + dnl Not used now, for the future when uuid is separated out into its + dnl own package. + dnl +-AC_INIT(gen_uuid.c) +-AC_PREREQ(2.12) ++AC_INIT ++AC_CONFIG_SRCDIR([gen_uuid.c]) ++AC_PREREQ(2.57) + + AC_CHECK_HEADERS(stdlib.h unistd.h sys/sockio.h net/if.h netinet/in.h) + AC_CHECK_FUNCS(srandom) +-AC_OUTPUT(Makefile) ++AC_CONFIG_FILES([Makefile]) ++AC_OUTPUT +--- e2fsprogs-1.33/./configure.in~configure ++++ e2fsprogs-1.33/./configure.in +@@ -1,5 +1,6 @@ +-AC_INIT(version.h) +-AC_PREREQ(2.12) ++AC_INIT ++AC_CONFIG_SRCDIR([version.h]) ++AC_PREREQ(2.57) + MCONFIG=./MCONFIG + AC_SUBST_FILE(MCONFIG) + BINARY_TYPE=bin +@@ -537,10 +538,7 @@ + dnl is not decleared. + AC_MSG_CHECKING(whether d_reclen declared in dirent) + AC_CACHE_VAL(e2fsprogs_cv_have_d_reclen_dirent, +- AC_TRY_COMPILE( +-[#include ], [struct dirent de; de.d_reclen = 0; ], +- [e2fsprogs_cv_have_d_reclen_dirent=yes], +- [e2fsprogs_cv_have_d_reclen_dirent=no])) ++ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], [[struct dirent de; de.d_reclen = 0; ]])],[e2fsprogs_cv_have_d_reclen_dirent=yes],[e2fsprogs_cv_have_d_reclen_dirent=no])) + AC_MSG_RESULT($e2fsprogs_cv_have_d_reclen_dirent) + if test "$e2fsprogs_cv_have_d_reclen_dirent" = yes; then + AC_DEFINE(HAVE_RECLEN_DIRENT) +@@ -548,10 +546,7 @@ + dnl Check to see if ssize_t was decleared + AC_MSG_CHECKING(whether ssize_t declared) + AC_CACHE_VAL(e2fsprogs_cv_have_ssize_t, +- AC_TRY_COMPILE( +-[#include ], [ssize_t a = 0; ], +- [e2fsprogs_cv_have_ssize_t=yes], +- [e2fsprogs_cv_have_ssize_t=no])) ++ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], [[ssize_t a = 0; ]])],[e2fsprogs_cv_have_ssize_t=yes],[e2fsprogs_cv_have_ssize_t=no])) + AC_MSG_RESULT($e2fsprogs_cv_have_ssize_t) + if test "$e2fsprogs_cv_have_ssize_t" = yes; then + AC_DEFINE(HAVE_TYPE_SSIZE_T) +@@ -565,10 +560,7 @@ + dnl + AC_MSG_CHECKING(whether llseek declared in unistd.h) + AC_CACHE_VAL(e2fsprogs_cv_have_llseek_prototype, +- AC_TRY_COMPILE( +-[#include ], [extern int llseek(int);], +- [e2fsprogs_cv_have_llseek_prototype=no], +- [e2fsprogs_cv_have_llseek_prototype=yes])) ++ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], [[extern int llseek(int);]])],[e2fsprogs_cv_have_llseek_prototype=no],[e2fsprogs_cv_have_llseek_prototype=yes])) + AC_MSG_RESULT($e2fsprogs_cv_have_llseek_prototype) + if test "$e2fsprogs_cv_have_llseek_prototype" = yes; then + AC_DEFINE(HAVE_LLSEEK_PROTOTYPE) +@@ -584,12 +576,9 @@ + dnl + AC_MSG_CHECKING(whether lseek64 declared in unistd.h) + AC_CACHE_VAL(e2fsprogs_cv_have_lseek64_prototype, +- AC_TRY_COMPILE( +-[#define _LARGEFILE_SOURCE ++ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#define _LARGEFILE_SOURCE + #define _LARGEFILE64_SOURCE +-#include ], [extern int lseek64(int);], +- [e2fsprogs_cv_have_lseek64_prototype=no], +- [e2fsprogs_cv_have_lseek64_prototype=yes])) ++#include ]], [[extern int lseek64(int);]])],[e2fsprogs_cv_have_lseek64_prototype=no],[e2fsprogs_cv_have_lseek64_prototype=yes])) + AC_MSG_RESULT($e2fsprogs_cv_have_lseek64_prototype) + if test "$e2fsprogs_cv_have_lseek64_prototype" = yes; then + AC_DEFINE(HAVE_LSEEK64_PROTOTYPE) +@@ -624,18 +613,12 @@ + dnl + AC_MSG_CHECKING(whether struct stat has a st_flags field) + AC_CACHE_VAL(e2fsprogs_cv_struct_st_flags, +- AC_TRY_COMPILE([#include ], +- [struct stat stat; stat.st_flags = 0;], +- [e2fsprogs_cv_struct_st_flags=yes], +- [e2fsprogs_cv_struct_st_flags=no])) ++ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], [[struct stat stat; stat.st_flags = 0;]])],[e2fsprogs_cv_struct_st_flags=yes],[e2fsprogs_cv_struct_st_flags=no])) + AC_MSG_RESULT($e2fsprogs_cv_struct_st_flags) + if test "$e2fsprogs_cv_struct_st_flags" = yes; then + AC_MSG_CHECKING(whether st_flags field is useful) + AC_CACHE_VAL(e2fsprogs_cv_struct_st_flags_immut, +- AC_TRY_COMPILE([#include ], +- [struct stat stat; stat.st_flags |= UF_IMMUTABLE;], +- [e2fsprogs_cv_struct_st_flags_immut=yes], +- [e2fsprogs_cv_struct_st_flags_immut=no])) ++ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], [[struct stat stat; stat.st_flags |= UF_IMMUTABLE;]])],[e2fsprogs_cv_struct_st_flags_immut=yes],[e2fsprogs_cv_struct_st_flags_immut=no])) + AC_MSG_RESULT($e2fsprogs_cv_struct_st_flags_immut) + if test "$e2fsprogs_cv_struct_st_flags_immut" = yes; then + AC_DEFINE(HAVE_STAT_FLAGS) +@@ -747,8 +730,7 @@ + AC_MSG_CHECKING([whether linker accepts -static]) + AC_CACHE_VAL(ac_cv_e2fsprogs_use_static, + [SAVE_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -static" +-AC_TRY_LINK([#include ],[fflush(stdout);], +- ac_cv_e2fsprogs_use_static=yes, ac_cv_e2fsprogs_use_static=no) ++AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include ]], [[fflush(stdout);]])],[ac_cv_e2fsprogs_use_static=yes],[ac_cv_e2fsprogs_use_static=no]) + LDFLAGS=$SAVE_LDFLAGS]) + dnl + dnl Regardless of how the test turns out, Solaris doesn't handle -static +@@ -804,4 +786,5 @@ + outlist="$outlist $i" + fi + done +-AC_OUTPUT($outlist) ++AC_CONFIG_FILES([$outlist]) ++AC_OUTPUT diff --git a/meta/packages/e2fsprogs/e2fsprogs/e2fsprogs_1.34.bb b/meta/packages/e2fsprogs/e2fsprogs/e2fsprogs_1.34.bb new file mode 100644 index 000000000..a9576b686 --- /dev/null +++ b/meta/packages/e2fsprogs/e2fsprogs/e2fsprogs_1.34.bb @@ -0,0 +1,18 @@ +DESCRIPTION="EXT2 Filesystem Utilities" +SECTION="base" +PRIORITY="optional" +MAINTAINER="Greg Gilbert " +RDEPENDS="libc6" +DEPENDS=virtual/libc + +SRC_URI=${SOURCEFORGE_MIRROR}/e2fsprogs/e2fsprogs-${PV}.tar.gz \ + file://${FILESDIR}/ln.patch;patch=1 \ + file://${FILESDIR}/configure.patch;patch=1 \ + file://${FILESDIR}/compile-subst.patch;patch=1 \ + file://${FILESDIR}/m4.patch;patch=1 + +inherit autotools + +do_compile_prepend () { + find ./ -print|xargs chmod u=rwX +} diff --git a/meta/packages/e2fsprogs/e2fsprogs/ldflags.patch b/meta/packages/e2fsprogs/e2fsprogs/ldflags.patch new file mode 100644 index 000000000..0a7ed4ed7 --- /dev/null +++ b/meta/packages/e2fsprogs/e2fsprogs/ldflags.patch @@ -0,0 +1,27 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- e2fsprogs-1.34/lib/uuid/Makefile.in~ldflags ++++ e2fsprogs-1.34/lib/uuid/Makefile.in +@@ -94,7 +94,7 @@ + $(CC) $(ALL_LDFLAGS) -o tst_uuid tst_uuid.o $(STATIC_LIBUUID) + + uuid_time: $(srcdir)/uuid_time.c $(DEPLIBUUID) +- $(CC) $(ALL_CFLAGS) -DDEBUG -o uuid_time $(srcdir)/uuid_time.c \ ++ $(CC) $(ALL_CFLAGS) -DDEBUG $(ALL_LDFLAGS) -o uuid_time $(srcdir)/uuid_time.c \ + $(LIBUUID) + + libuuid.3: $(DEP_SUBSTITUTE) $(srcdir)/libuuid.3.in +--- e2fsprogs-1.34/lib/evms/Makefile.in~ldflags ++++ e2fsprogs-1.34/lib/evms/Makefile.in +@@ -36,7 +36,7 @@ + + $(ELF_LIB): $(OBJS) + $(CC) --shared -o $(ELF_LIB) -Wl,-soname,$(ELF_SONAME) \ +- $(OBJS) $(ELF_OTHER_LIBS) ++ $(OBJS) $(ELF_OTHER_LIBS) $(ALL_LDFLAGS) + + installdirs:: + $(top_srcdir)/mkinstalldirs $(DESTDIR)$(ELF_INSTALL_DIR) diff --git a/meta/packages/e2fsprogs/e2fsprogs/ln.patch b/meta/packages/e2fsprogs/e2fsprogs/ln.patch new file mode 100644 index 000000000..247def8b3 --- /dev/null +++ b/meta/packages/e2fsprogs/e2fsprogs/ln.patch @@ -0,0 +1,58 @@ +diff -urNd e2fsprogs-1.32/e2fsck/Makefile.in e2fsprogs-1.32-new/e2fsck/Makefile.in +--- e2fsprogs-1.32/e2fsck/Makefile.in 2002-10-31 02:49:21.000000000 -0600 ++++ e2fsprogs-1.32-new/e2fsck/Makefile.in 2002-11-29 11:06:39.000000000 -0600 +@@ -145,9 +145,9 @@ + $(INSTALL_PROGRAM) $$i $(DESTDIR)$(root_sbindir)/$$i; \ + $(STRIP) $(DESTDIR)$(root_sbindir)/$$i; \ + done +- $(LN) -f $(DESTDIR)$(root_sbindir)/e2fsck \ ++ $(LN_S) -f ./e2fsck \ + $(DESTDIR)$(root_sbindir)/fsck.ext2 +- $(LN) -f $(DESTDIR)$(root_sbindir)/e2fsck \ ++ $(LN_S) -f ./e2fsck \ + $(DESTDIR)$(root_sbindir)/fsck.ext3 + for i in $(MANPAGES); do \ + for j in $(COMPRESS_EXT); do \ +@@ -155,8 +155,8 @@ + done; \ + $(INSTALL_DATA) $$i $(DESTDIR)$(man8dir)/$$i; \ + done +- $(LN) -f $(DESTDIR)$(man8dir)/e2fsck.8 $(DESTDIR)$(man8dir)/fsck.ext2.8 +- $(LN) -f $(DESTDIR)$(man8dir)/e2fsck.8 $(DESTDIR)$(man8dir)/fsck.ext3.8 ++ $(LN_S) -f ./e2fsck.8 $(DESTDIR)$(man8dir)/fsck.ext2.8 ++ $(LN_S) -f ./e2fsck.8 $(DESTDIR)$(man8dir)/fsck.ext3.8 + + uninstall: + for i in $(PROGS); do \ +diff -urNd e2fsprogs-1.32/misc/Makefile.in e2fsprogs-1.32-new/misc/Makefile.in +--- e2fsprogs-1.32/misc/Makefile.in 2002-10-31 02:49:21.000000000 -0600 ++++ e2fsprogs-1.32-new/misc/Makefile.in 2002-11-29 11:05:25.000000000 -0600 +@@ -154,13 +154,13 @@ + $(INSTALL_PROGRAM) $$i $(DESTDIR)$(sbindir)/$$i; \ + $(STRIP) $(DESTDIR)$(sbindir)/$$i; \ + done +- $(LN) -f $(DESTDIR)$(root_sbindir)/mke2fs \ ++ $(LN_S) -f ./mke2fs \ + $(DESTDIR)$(root_sbindir)/mkfs.ext2 +- $(LN) -f $(DESTDIR)$(root_sbindir)/mke2fs \ ++ $(LN_S) -f ./mke2fs \ + $(DESTDIR)$(root_sbindir)/mkfs.ext3 +- $(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \ ++ $(LN_S) -f ./tune2fs \ + $(DESTDIR)$(root_sbindir)/e2label +- $(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \ ++ $(LN_S) -f ./tune2fs \ + $(DESTDIR)$(root_sbindir)/findfs + for i in $(UPROGS); do \ + $(INSTALL_PROGRAM) $$i $(DESTDIR)$(bindir)/$$i; \ +@@ -174,8 +174,8 @@ + done + $(RM) -f $(DESTDIR)$(man8dir)/mkfs.ext2.8.gz \ + $(DESTDIR)$(man8dir)/mkfs.ext3.8.gz +- $(LN) -f $(DESTDIR)$(man8dir)/mke2fs.8 $(DESTDIR)$(man8dir)/mkfs.ext2.8 +- $(LN) -f $(DESTDIR)$(man8dir)/mke2fs.8 $(DESTDIR)$(man8dir)/mkfs.ext3.8 ++ $(LN_S) -f ./mke2fs.8 $(DESTDIR)$(man8dir)/mkfs.ext2.8 ++ $(LN_S) -f ./mke2fs.8 $(DESTDIR)$(man8dir)/mkfs.ext3.8 + for i in $(UMANPAGES); do \ + $(RM) -f $(DESTDIR)$(man1dir)/$$i.gz; \ + $(INSTALL_DATA) $$i $(DESTDIR)$(man1dir)/$$i; \ diff --git a/meta/packages/e2fsprogs/e2fsprogs/m4.patch b/meta/packages/e2fsprogs/e2fsprogs/m4.patch new file mode 100644 index 000000000..2a9b2a64f --- /dev/null +++ b/meta/packages/e2fsprogs/e2fsprogs/m4.patch @@ -0,0 +1,2155 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/codeset.m4 +@@ -0,0 +1,23 @@ ++# codeset.m4 serial AM1 (gettext-0.10.40) ++dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Bruno Haible. ++ ++AC_DEFUN([AM_LANGINFO_CODESET], ++[ ++ AC_CACHE_CHECK([for nl_langinfo and CODESET], am_cv_langinfo_codeset, ++ [AC_TRY_LINK([#include ], ++ [char* cs = nl_langinfo(CODESET);], ++ am_cv_langinfo_codeset=yes, ++ am_cv_langinfo_codeset=no) ++ ]) ++ if test $am_cv_langinfo_codeset = yes; then ++ AC_DEFINE(HAVE_LANGINFO_CODESET, 1, ++ [Define if you have and nl_langinfo(CODESET).]) ++ fi ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/gettext.m4 +@@ -0,0 +1,587 @@ ++# gettext.m4 serial 17 (gettext-0.11.5) ++dnl Copyright (C) 1995-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++dnl ++dnl This file can can be used in projects which are not available under ++dnl the GNU General Public License or the GNU Library General Public ++dnl License but which still want to provide support for the GNU gettext ++dnl functionality. ++dnl Please note that the actual code of the GNU gettext library is covered ++dnl by the GNU Library General Public License, and the rest of the GNU ++dnl gettext package package is covered by the GNU General Public License. ++dnl They are *not* in the public domain. ++ ++dnl Authors: ++dnl Ulrich Drepper , 1995-2000. ++dnl Bruno Haible , 2000-2002. ++ ++dnl Macro to add for using GNU gettext. ++ ++dnl Usage: AM_GNU_GETTEXT([INTLSYMBOL], [NEEDSYMBOL], [INTLDIR]). ++dnl INTLSYMBOL can be one of 'external', 'no-libtool', 'use-libtool'. The ++dnl default (if it is not specified or empty) is 'no-libtool'. ++dnl INTLSYMBOL should be 'external' for packages with no intl directory, ++dnl and 'no-libtool' or 'use-libtool' for packages with an intl directory. ++dnl If INTLSYMBOL is 'use-libtool', then a libtool library ++dnl $(top_builddir)/intl/libintl.la will be created (shared and/or static, ++dnl depending on --{enable,disable}-{shared,static} and on the presence of ++dnl AM-DISABLE-SHARED). If INTLSYMBOL is 'no-libtool', a static library ++dnl $(top_builddir)/intl/libintl.a will be created. ++dnl If NEEDSYMBOL is specified and is 'need-ngettext', then GNU gettext ++dnl implementations (in libc or libintl) without the ngettext() function ++dnl will be ignored. If NEEDSYMBOL is specified and is ++dnl 'need-formatstring-macros', then GNU gettext implementations that don't ++dnl support the ISO C 99 formatstring macros will be ignored. ++dnl INTLDIR is used to find the intl libraries. If empty, ++dnl the value `$(top_builddir)/intl/' is used. ++dnl ++dnl The result of the configuration is one of three cases: ++dnl 1) GNU gettext, as included in the intl subdirectory, will be compiled ++dnl and used. ++dnl Catalog format: GNU --> install in $(datadir) ++dnl Catalog extension: .mo after installation, .gmo in source tree ++dnl 2) GNU gettext has been found in the system's C library. ++dnl Catalog format: GNU --> install in $(datadir) ++dnl Catalog extension: .mo after installation, .gmo in source tree ++dnl 3) No internationalization, always use English msgid. ++dnl Catalog format: none ++dnl Catalog extension: none ++dnl If INTLSYMBOL is 'external', only cases 2 and 3 can occur. ++dnl The use of .gmo is historical (it was needed to avoid overwriting the ++dnl GNU format catalogs when building on a platform with an X/Open gettext), ++dnl but we keep it in order not to force irrelevant filename changes on the ++dnl maintainers. ++dnl ++AC_DEFUN([AM_GNU_GETTEXT], ++[ ++ dnl Argument checking. ++ ifelse([$1], [], , [ifelse([$1], [external], , [ifelse([$1], [no-libtool], , [ifelse([$1], [use-libtool], , ++ [errprint([ERROR: invalid first argument to AM_GNU_GETTEXT ++])])])])]) ++ ifelse([$2], [], , [ifelse([$2], [need-ngettext], , [ifelse([$2], [need-formatstring-macros], , ++ [errprint([ERROR: invalid second argument to AM_GNU_GETTEXT ++])])])]) ++ define(gt_included_intl, ifelse([$1], [external], [no], [yes])) ++ define(gt_libtool_suffix_prefix, ifelse([$1], [use-libtool], [l], [])) ++ ++ AC_REQUIRE([AM_PO_SUBDIRS])dnl ++ ifelse(gt_included_intl, yes, [ ++ AC_REQUIRE([AM_INTL_SUBDIR])dnl ++ ]) ++ ++ dnl Prerequisites of AC_LIB_LINKFLAGS_BODY. ++ AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) ++ AC_REQUIRE([AC_LIB_RPATH]) ++ ++ dnl Sometimes libintl requires libiconv, so first search for libiconv. ++ dnl Ideally we would do this search only after the ++ dnl if test "$USE_NLS" = "yes"; then ++ dnl if test "$gt_cv_func_gnugettext_libc" != "yes"; then ++ dnl tests. But if configure.in invokes AM_ICONV after AM_GNU_GETTEXT ++ dnl the configure script would need to contain the same shell code ++ dnl again, outside any 'if'. There are two solutions: ++ dnl - Invoke AM_ICONV_LINKFLAGS_BODY here, outside any 'if'. ++ dnl - Control the expansions in more detail using AC_PROVIDE_IFELSE. ++ dnl Since AC_PROVIDE_IFELSE is only in autoconf >= 2.52 and not ++ dnl documented, we avoid it. ++ ifelse(gt_included_intl, yes, , [ ++ AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY]) ++ ]) ++ ++ AC_MSG_CHECKING([whether NLS is requested]) ++ dnl Default is enabled NLS ++ AC_ARG_ENABLE(nls, ++ [ --disable-nls do not use Native Language Support], ++ USE_NLS=$enableval, USE_NLS=yes) ++ AC_MSG_RESULT($USE_NLS) ++ AC_SUBST(USE_NLS) ++ ++ ifelse(gt_included_intl, yes, [ ++ BUILD_INCLUDED_LIBINTL=no ++ USE_INCLUDED_LIBINTL=no ++ ]) ++ LIBINTL= ++ LTLIBINTL= ++ POSUB= ++ ++ dnl If we use NLS figure out what method ++ if test "$USE_NLS" = "yes"; then ++ gt_use_preinstalled_gnugettext=no ++ ifelse(gt_included_intl, yes, [ ++ AC_MSG_CHECKING([whether included gettext is requested]) ++ AC_ARG_WITH(included-gettext, ++ [ --with-included-gettext use the GNU gettext library included here], ++ nls_cv_force_use_gnu_gettext=$withval, ++ nls_cv_force_use_gnu_gettext=no) ++ AC_MSG_RESULT($nls_cv_force_use_gnu_gettext) ++ ++ nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" ++ if test "$nls_cv_force_use_gnu_gettext" != "yes"; then ++ ]) ++ dnl User does not insist on using GNU NLS library. Figure out what ++ dnl to use. If GNU gettext is available we use this. Else we have ++ dnl to fall back to GNU NLS library. ++ ++ dnl Add a version number to the cache macros. ++ define([gt_api_version], ifelse([$2], [need-formatstring-macros], 3, ifelse([$2], [need-ngettext], 2, 1))) ++ define([gt_cv_func_gnugettext_libc], [gt_cv_func_gnugettext]gt_api_version[_libc]) ++ define([gt_cv_func_gnugettext_libintl], [gt_cv_func_gnugettext]gt_api_version[_libintl]) ++ ++ AC_CACHE_CHECK([for GNU gettext in libc], gt_cv_func_gnugettext_libc, ++ [AC_TRY_LINK([#include ++]ifelse([$2], [need-formatstring-macros], ++[#ifndef __GNU_GETTEXT_SUPPORTED_REVISION ++#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1) ++#endif ++changequote(,)dnl ++typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1]; ++changequote([,])dnl ++], [])[extern int _nl_msg_cat_cntr; ++extern int *_nl_domain_bindings;], ++ [bindtextdomain ("", ""); ++return (int) gettext ("")]ifelse([$2], [need-ngettext], [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr + *_nl_domain_bindings], ++ gt_cv_func_gnugettext_libc=yes, ++ gt_cv_func_gnugettext_libc=no)]) ++ ++ if test "$gt_cv_func_gnugettext_libc" != "yes"; then ++ dnl Sometimes libintl requires libiconv, so first search for libiconv. ++ ifelse(gt_included_intl, yes, , [ ++ AM_ICONV_LINK ++ ]) ++ dnl Search for libintl and define LIBINTL, LTLIBINTL and INCINTL ++ dnl accordingly. Don't use AC_LIB_LINKFLAGS_BODY([intl],[iconv]) ++ dnl because that would add "-liconv" to LIBINTL and LTLIBINTL ++ dnl even if libiconv doesn't exist. ++ AC_LIB_LINKFLAGS_BODY([intl]) ++ AC_CACHE_CHECK([for GNU gettext in libintl], ++ gt_cv_func_gnugettext_libintl, ++ [gt_save_CPPFLAGS="$CPPFLAGS" ++ CPPFLAGS="$CPPFLAGS $INCINTL" ++ gt_save_LIBS="$LIBS" ++ LIBS="$LIBS $LIBINTL" ++ dnl Now see whether libintl exists and does not depend on libiconv. ++ AC_TRY_LINK([#include ++]ifelse([$2], [need-formatstring-macros], ++[#ifndef __GNU_GETTEXT_SUPPORTED_REVISION ++#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1) ++#endif ++changequote(,)dnl ++typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1]; ++changequote([,])dnl ++], [])[extern int _nl_msg_cat_cntr; ++extern ++#ifdef __cplusplus ++"C" ++#endif ++const char *_nl_expand_alias ();], ++ [bindtextdomain ("", ""); ++return (int) gettext ("")]ifelse([$2], [need-ngettext], [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr + *_nl_expand_alias (0)], ++ gt_cv_func_gnugettext_libintl=yes, ++ gt_cv_func_gnugettext_libintl=no) ++ dnl Now see whether libintl exists and depends on libiconv. ++ if test "$gt_cv_func_gnugettext_libintl" != yes && test -n "$LIBICONV"; then ++ LIBS="$LIBS $LIBICONV" ++ AC_TRY_LINK([#include ++]ifelse([$2], [need-formatstring-macros], ++[#ifndef __GNU_GETTEXT_SUPPORTED_REVISION ++#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1) ++#endif ++changequote(,)dnl ++typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1]; ++changequote([,])dnl ++], [])[extern int _nl_msg_cat_cntr; ++extern ++#ifdef __cplusplus ++"C" ++#endif ++const char *_nl_expand_alias ();], ++ [bindtextdomain ("", ""); ++return (int) gettext ("")]ifelse([$2], [need-ngettext], [ + (int) ngettext ("", "", 0)], [])[ + _nl_msg_cat_cntr + *_nl_expand_alias (0)], ++ [LIBINTL="$LIBINTL $LIBICONV" ++ LTLIBINTL="$LTLIBINTL $LTLIBICONV" ++ gt_cv_func_gnugettext_libintl=yes ++ ]) ++ fi ++ CPPFLAGS="$gt_save_CPPFLAGS" ++ LIBS="$gt_save_LIBS"]) ++ fi ++ ++ dnl If an already present or preinstalled GNU gettext() is found, ++ dnl use it. But if this macro is used in GNU gettext, and GNU ++ dnl gettext is already preinstalled in libintl, we update this ++ dnl libintl. (Cf. the install rule in intl/Makefile.in.) ++ if test "$gt_cv_func_gnugettext_libc" = "yes" \ ++ || { test "$gt_cv_func_gnugettext_libintl" = "yes" \ ++ && test "$PACKAGE" != gettext; }; then ++ gt_use_preinstalled_gnugettext=yes ++ else ++ dnl Reset the values set by searching for libintl. ++ LIBINTL= ++ LTLIBINTL= ++ INCINTL= ++ fi ++ ++ ifelse(gt_included_intl, yes, [ ++ if test "$gt_use_preinstalled_gnugettext" != "yes"; then ++ dnl GNU gettext is not found in the C library. ++ dnl Fall back on included GNU gettext library. ++ nls_cv_use_gnu_gettext=yes ++ fi ++ fi ++ ++ if test "$nls_cv_use_gnu_gettext" = "yes"; then ++ dnl Mark actions used to generate GNU NLS library. ++ INTLOBJS="\$(GETTOBJS)" ++ BUILD_INCLUDED_LIBINTL=yes ++ USE_INCLUDED_LIBINTL=yes ++ LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LIBICONV" ++ LTLIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.[]gt_libtool_suffix_prefix[]a $LTLIBICONV" ++ LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'` ++ fi ++ ++ if test "$gt_use_preinstalled_gnugettext" = "yes" \ ++ || test "$nls_cv_use_gnu_gettext" = "yes"; then ++ dnl Mark actions to use GNU gettext tools. ++ CATOBJEXT=.gmo ++ fi ++ ]) ++ ++ if test "$gt_use_preinstalled_gnugettext" = "yes" \ ++ || test "$nls_cv_use_gnu_gettext" = "yes"; then ++ AC_DEFINE(ENABLE_NLS, 1, ++ [Define to 1 if translation of program messages to the user's native language ++ is requested.]) ++ else ++ USE_NLS=no ++ fi ++ fi ++ ++ if test "$USE_NLS" = "yes"; then ++ ++ if test "$gt_use_preinstalled_gnugettext" = "yes"; then ++ if test "$gt_cv_func_gnugettext_libintl" = "yes"; then ++ AC_MSG_CHECKING([how to link with libintl]) ++ AC_MSG_RESULT([$LIBINTL]) ++ AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCINTL]) ++ fi ++ ++ dnl For backward compatibility. Some packages may be using this. ++ AC_DEFINE(HAVE_GETTEXT, 1, ++ [Define if the GNU gettext() function is already present or preinstalled.]) ++ AC_DEFINE(HAVE_DCGETTEXT, 1, ++ [Define if the GNU dcgettext() function is already present or preinstalled.]) ++ fi ++ ++ dnl We need to process the po/ directory. ++ POSUB=po ++ fi ++ ++ ifelse(gt_included_intl, yes, [ ++ dnl If this is used in GNU gettext we have to set BUILD_INCLUDED_LIBINTL ++ dnl to 'yes' because some of the testsuite requires it. ++ if test "$PACKAGE" = gettext; then ++ BUILD_INCLUDED_LIBINTL=yes ++ fi ++ ++ dnl Make all variables we use known to autoconf. ++ AC_SUBST(BUILD_INCLUDED_LIBINTL) ++ AC_SUBST(USE_INCLUDED_LIBINTL) ++ AC_SUBST(CATOBJEXT) ++ AC_SUBST(INTLOBJS) ++ ++ dnl For backward compatibility. Some configure.ins may be using this. ++ nls_cv_header_intl= ++ nls_cv_header_libgt= ++ ++ dnl For backward compatibility. Some Makefiles may be using this. ++ DATADIRNAME=share ++ AC_SUBST(DATADIRNAME) ++ ++ dnl For backward compatibility. Some Makefiles may be using this. ++ INSTOBJEXT=.mo ++ AC_SUBST(INSTOBJEXT) ++ ++ dnl For backward compatibility. Some Makefiles may be using this. ++ GENCAT=gencat ++ AC_SUBST(GENCAT) ++ ++ dnl Enable libtool support if the surrounding package wishes it. ++ INTL_LIBTOOL_SUFFIX_PREFIX=gt_libtool_suffix_prefix ++ AC_SUBST(INTL_LIBTOOL_SUFFIX_PREFIX) ++ ]) ++ ++ dnl For backward compatibility. Some Makefiles may be using this. ++ INTLLIBS="$LIBINTL" ++ AC_SUBST(INTLLIBS) ++ ++ dnl Make all documented variables known to autoconf. ++ AC_SUBST(LIBINTL) ++ AC_SUBST(LTLIBINTL) ++ AC_SUBST(POSUB) ++]) ++ ++ ++dnl Checks for all prerequisites of the po subdirectory, ++dnl except for USE_NLS. ++AC_DEFUN([AM_PO_SUBDIRS], ++[ ++ AC_REQUIRE([AC_PROG_MAKE_SET])dnl ++ AC_REQUIRE([AC_PROG_INSTALL])dnl ++ AC_REQUIRE([AM_MKINSTALLDIRS])dnl ++ ++ dnl Perform the following tests also if --disable-nls has been given, ++ dnl because they are needed for "make dist" to work. ++ ++ dnl Search for GNU msgfmt in the PATH. ++ dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions. ++ dnl The second test excludes FreeBSD msgfmt. ++ AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt, ++ [$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 && ++ (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], ++ :) ++ AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT) ++ ++ dnl Search for GNU xgettext 0.11 or newer in the PATH. ++ dnl The first test excludes Solaris xgettext and early GNU xgettext versions. ++ dnl The second test excludes FreeBSD xgettext. ++ AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext, ++ [$ac_dir/$ac_word --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 && ++ (if $ac_dir/$ac_word --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)], ++ :) ++ dnl Remove leftover from FreeBSD xgettext call. ++ rm -f messages.po ++ ++ dnl Search for GNU msgmerge 0.11 or newer in the PATH. ++ AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge, ++ [$ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1], :) ++ ++ dnl This could go away some day; the PATH_PROG_WITH_TEST already does it. ++ dnl Test whether we really found GNU msgfmt. ++ if test "$GMSGFMT" != ":"; then ++ dnl If it is no GNU msgfmt we define it as : so that the ++ dnl Makefiles still can work. ++ if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 && ++ (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then ++ : ; ++ else ++ GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'` ++ AC_MSG_RESULT( ++ [found $GMSGFMT program is not GNU msgfmt; ignore it]) ++ GMSGFMT=":" ++ fi ++ fi ++ ++ dnl This could go away some day; the PATH_PROG_WITH_TEST already does it. ++ dnl Test whether we really found GNU xgettext. ++ if test "$XGETTEXT" != ":"; then ++ dnl If it is no GNU xgettext we define it as : so that the ++ dnl Makefiles still can work. ++ if $XGETTEXT --omit-header --copyright-holder= /dev/null >/dev/null 2>&1 && ++ (if $XGETTEXT --omit-header --copyright-holder= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then ++ : ; ++ else ++ AC_MSG_RESULT( ++ [found xgettext program is not GNU xgettext; ignore it]) ++ XGETTEXT=":" ++ fi ++ dnl Remove leftover from FreeBSD xgettext call. ++ rm -f messages.po ++ fi ++ ++ AC_OUTPUT_COMMANDS([ ++ for ac_file in $CONFIG_FILES; do ++ # Support "outfile[:infile[:infile...]]" ++ case "$ac_file" in ++ *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; ++ esac ++ # PO directories have a Makefile.in generated from Makefile.in.in. ++ case "$ac_file" in */Makefile.in) ++ # Adjust a relative srcdir. ++ ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` ++ ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" ++ ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` ++ # In autoconf-2.13 it is called $ac_given_srcdir. ++ # In autoconf-2.50 it is called $srcdir. ++ test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" ++ case "$ac_given_srcdir" in ++ .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; ++ /*) top_srcdir="$ac_given_srcdir" ;; ++ *) top_srcdir="$ac_dots$ac_given_srcdir" ;; ++ esac ++ if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then ++ rm -f "$ac_dir/POTFILES" ++ test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" ++ cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" ++ # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend ++ # on $ac_dir but don't depend on user-specified configuration ++ # parameters. ++ if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then ++ # The LINGUAS file contains the set of available languages. ++ if test -n "$ALL_LINGUAS"; then ++ test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" ++ fi ++ ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"` ++ # Hide the ALL_LINGUAS assigment from automake. ++ eval 'ALL_LINGUAS''=$ALL_LINGUAS_' ++ fi ++ case "$ac_given_srcdir" in ++ .) srcdirpre= ;; ++ *) srcdirpre='$(srcdir)/' ;; ++ esac ++ POFILES= ++ GMOFILES= ++ UPDATEPOFILES= ++ DUMMYPOFILES= ++ for lang in $ALL_LINGUAS; do ++ POFILES="$POFILES $srcdirpre$lang.po" ++ GMOFILES="$GMOFILES $srcdirpre$lang.gmo" ++ UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" ++ DUMMYPOFILES="$DUMMYPOFILES $lang.nop" ++ done ++ # CATALOGS depends on both $ac_dir and the user's LINGUAS ++ # environment variable. ++ INST_LINGUAS= ++ if test -n "$ALL_LINGUAS"; then ++ for presentlang in $ALL_LINGUAS; do ++ useit=no ++ if test "%UNSET%" != "$LINGUAS"; then ++ desiredlanguages="$LINGUAS" ++ else ++ desiredlanguages="$ALL_LINGUAS" ++ fi ++ for desiredlang in $desiredlanguages; do ++ # Use the presentlang catalog if desiredlang is ++ # a. equal to presentlang, or ++ # b. a variant of presentlang (because in this case, ++ # presentlang can be used as a fallback for messages ++ # which are not translated in the desiredlang catalog). ++ case "$desiredlang" in ++ "$presentlang"*) useit=yes;; ++ esac ++ done ++ if test $useit = yes; then ++ INST_LINGUAS="$INST_LINGUAS $presentlang" ++ fi ++ done ++ fi ++ CATALOGS= ++ if test -n "$INST_LINGUAS"; then ++ for lang in $INST_LINGUAS; do ++ CATALOGS="$CATALOGS $lang.gmo" ++ done ++ fi ++ test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" ++ sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" ++ for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do ++ if test -f "$f"; then ++ case "$f" in ++ *.orig | *.bak | *~) ;; ++ *) cat "$f" >> "$ac_dir/Makefile" ;; ++ esac ++ fi ++ done ++ fi ++ ;; ++ esac ++ done], ++ [# Capture the value of obsolete ALL_LINGUAS because we need it to compute ++ # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it ++ # from automake. ++ eval 'ALL_LINGUAS''="$ALL_LINGUAS"' ++ # Capture the value of LINGUAS because we need it to compute CATALOGS. ++ LINGUAS="${LINGUAS-%UNSET%}" ++ ]) ++]) ++ ++ ++dnl Checks for all prerequisites of the intl subdirectory, ++dnl except for INTL_LIBTOOL_SUFFIX_PREFIX (and possibly LIBTOOL), INTLOBJS, ++dnl USE_INCLUDED_LIBINTL, BUILD_INCLUDED_LIBINTL. ++AC_DEFUN([AM_INTL_SUBDIR], ++[ ++ AC_REQUIRE([AC_PROG_INSTALL])dnl ++ AC_REQUIRE([AM_MKINSTALLDIRS])dnl ++ AC_REQUIRE([AC_PROG_CC])dnl ++ AC_REQUIRE([AC_CANONICAL_HOST])dnl ++ AC_REQUIRE([AC_PROG_RANLIB])dnl ++ AC_REQUIRE([AC_ISC_POSIX])dnl ++ AC_REQUIRE([AC_HEADER_STDC])dnl ++ AC_REQUIRE([AC_C_CONST])dnl ++ AC_REQUIRE([AC_C_INLINE])dnl ++ AC_REQUIRE([AC_TYPE_OFF_T])dnl ++ AC_REQUIRE([AC_TYPE_SIZE_T])dnl ++ AC_REQUIRE([AC_FUNC_ALLOCA])dnl ++ AC_REQUIRE([AC_FUNC_MMAP])dnl ++ AC_REQUIRE([jm_GLIBC21])dnl ++ AC_REQUIRE([gt_INTDIV0])dnl ++ AC_REQUIRE([jm_AC_TYPE_UINTMAX_T])dnl ++ AC_REQUIRE([gt_HEADER_INTTYPES_H])dnl ++ AC_REQUIRE([gt_INTTYPES_PRI])dnl ++ ++ AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ ++stdlib.h string.h unistd.h sys/param.h]) ++ AC_CHECK_FUNCS([feof_unlocked fgets_unlocked getc_unlocked getcwd getegid \ ++geteuid getgid getuid mempcpy munmap putenv setenv setlocale stpcpy \ ++strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next]) ++ ++ AM_ICONV ++ AM_LANGINFO_CODESET ++ if test $ac_cv_header_locale_h = yes; then ++ AM_LC_MESSAGES ++ fi ++ ++ dnl intl/plural.c is generated from intl/plural.y. It requires bison, ++ dnl because plural.y uses bison specific features. It requires at least ++ dnl bison-1.26 because earlier versions generate a plural.c that doesn't ++ dnl compile. ++ dnl bison is only needed for the maintainer (who touches plural.y). But in ++ dnl order to avoid separate Makefiles or --enable-maintainer-mode, we put ++ dnl the rule in general Makefile. Now, some people carelessly touch the ++ dnl files or have a broken "make" program, hence the plural.c rule will ++ dnl sometimes fire. To avoid an error, defines BISON to ":" if it is not ++ dnl present or too old. ++ AC_CHECK_PROGS([INTLBISON], [bison]) ++ if test -z "$INTLBISON"; then ++ ac_verc_fail=yes ++ else ++ dnl Found it, now check the version. ++ AC_MSG_CHECKING([version of bison]) ++changequote(<<,>>)dnl ++ ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'` ++ case $ac_prog_version in ++ '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; ++ 1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*) ++changequote([,])dnl ++ ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; ++ *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; ++ esac ++ AC_MSG_RESULT([$ac_prog_version]) ++ fi ++ if test $ac_verc_fail = yes; then ++ INTLBISON=: ++ fi ++]) ++ ++ ++AC_DEFUN([AM_MKINSTALLDIRS], ++[ ++ dnl If the AC_CONFIG_AUX_DIR macro for autoconf is used we possibly ++ dnl find the mkinstalldirs script in another subdir but $(top_srcdir). ++ dnl Try to locate is. ++ MKINSTALLDIRS= ++ if test -n "$ac_aux_dir"; then ++ MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ++ fi ++ if test -z "$MKINSTALLDIRS"; then ++ MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" ++ fi ++ AC_SUBST(MKINSTALLDIRS) ++]) ++ ++ ++dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version]) ++AC_DEFUN([AM_GNU_GETTEXT_VERSION], []) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/glibc21.m4 +@@ -0,0 +1,32 @@ ++# glibc21.m4 serial 2 (fileutils-4.1.3, gettext-0.10.40) ++dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++# Test for the GNU C Library, version 2.1 or newer. ++# From Bruno Haible. ++ ++AC_DEFUN([jm_GLIBC21], ++ [ ++ AC_CACHE_CHECK(whether we are using the GNU C Library 2.1 or newer, ++ ac_cv_gnu_library_2_1, ++ [AC_EGREP_CPP([Lucky GNU user], ++ [ ++#include ++#ifdef __GNU_LIBRARY__ ++ #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2) ++ Lucky GNU user ++ #endif ++#endif ++ ], ++ ac_cv_gnu_library_2_1=yes, ++ ac_cv_gnu_library_2_1=no) ++ ] ++ ) ++ AC_SUBST(GLIBC21) ++ GLIBC21="$ac_cv_gnu_library_2_1" ++ ] ++) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/glib.m4 +@@ -0,0 +1,196 @@ ++# Configure paths for GLIB ++# Owen Taylor 97-11-3 ++ ++dnl AM_PATH_GLIB([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]]) ++dnl Test for GLIB, and define GLIB_CFLAGS and GLIB_LIBS, if "gmodule" or ++dnl gthread is specified in MODULES, pass to glib-config ++dnl ++AC_DEFUN(AM_PATH_GLIB, ++[dnl ++dnl Get the cflags and libraries from the glib-config script ++dnl ++AC_ARG_WITH(glib-prefix,[ --with-glib-prefix=PFX Prefix where GLIB is installed (optional)], ++ glib_config_prefix="$withval", glib_config_prefix="") ++AC_ARG_WITH(glib-exec-prefix,[ --with-glib-exec-prefix=PFX Exec prefix where GLIB is installed (optional)], ++ glib_config_exec_prefix="$withval", glib_config_exec_prefix="") ++AC_ARG_ENABLE(glibtest, [ --disable-glibtest Do not try to compile and run a test GLIB program], ++ , enable_glibtest=yes) ++ ++ if test x$glib_config_exec_prefix != x ; then ++ glib_config_args="$glib_config_args --exec-prefix=$glib_config_exec_prefix" ++ if test x${GLIB_CONFIG+set} != xset ; then ++ GLIB_CONFIG=$glib_config_exec_prefix/bin/glib-config ++ fi ++ fi ++ if test x$glib_config_prefix != x ; then ++ glib_config_args="$glib_config_args --prefix=$glib_config_prefix" ++ if test x${GLIB_CONFIG+set} != xset ; then ++ GLIB_CONFIG=$glib_config_prefix/bin/glib-config ++ fi ++ fi ++ ++ for module in . $4 ++ do ++ case "$module" in ++ gmodule) ++ glib_config_args="$glib_config_args gmodule" ++ ;; ++ gthread) ++ glib_config_args="$glib_config_args gthread" ++ ;; ++ esac ++ done ++ ++ AC_PATH_PROG(GLIB_CONFIG, glib-config, no) ++ min_glib_version=ifelse([$1], ,0.99.7,$1) ++ AC_MSG_CHECKING(for GLIB - version >= $min_glib_version) ++ no_glib="" ++ if test "$GLIB_CONFIG" = "no" ; then ++ no_glib=yes ++ else ++ GLIB_CFLAGS=`$GLIB_CONFIG $glib_config_args --cflags` ++ GLIB_LIBS=`$GLIB_CONFIG $glib_config_args --libs` ++ glib_config_major_version=`$GLIB_CONFIG $glib_config_args --version | \ ++ sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` ++ glib_config_minor_version=`$GLIB_CONFIG $glib_config_args --version | \ ++ sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` ++ glib_config_micro_version=`$GLIB_CONFIG $glib_config_args --version | \ ++ sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` ++ if test "x$enable_glibtest" = "xyes" ; then ++ ac_save_CFLAGS="$CFLAGS" ++ ac_save_LIBS="$LIBS" ++ CFLAGS="$CFLAGS $GLIB_CFLAGS" ++ LIBS="$GLIB_LIBS $LIBS" ++dnl ++dnl Now check if the installed GLIB is sufficiently new. (Also sanity ++dnl checks the results of glib-config to some extent ++dnl ++ rm -f conf.glibtest ++ AC_TRY_RUN([ ++#include ++#include ++#include ++ ++int ++main () ++{ ++ int major, minor, micro; ++ char *tmp_version; ++ ++ system ("touch conf.glibtest"); ++ ++ /* HP/UX 9 (%@#!) writes to sscanf strings */ ++ tmp_version = g_strdup("$min_glib_version"); ++ if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { ++ printf("%s, bad version string\n", "$min_glib_version"); ++ exit(1); ++ } ++ ++ if ((glib_major_version != $glib_config_major_version) || ++ (glib_minor_version != $glib_config_minor_version) || ++ (glib_micro_version != $glib_config_micro_version)) ++ { ++ printf("\n*** 'glib-config --version' returned %d.%d.%d, but GLIB (%d.%d.%d)\n", ++ $glib_config_major_version, $glib_config_minor_version, $glib_config_micro_version, ++ glib_major_version, glib_minor_version, glib_micro_version); ++ printf ("*** was found! If glib-config was correct, then it is best\n"); ++ printf ("*** to remove the old version of GLIB. You may also be able to fix the error\n"); ++ printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n"); ++ printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n"); ++ printf("*** required on your system.\n"); ++ printf("*** If glib-config was wrong, set the environment variable GLIB_CONFIG\n"); ++ printf("*** to point to the correct copy of glib-config, and remove the file config.cache\n"); ++ printf("*** before re-running configure\n"); ++ } ++ else if ((glib_major_version != GLIB_MAJOR_VERSION) || ++ (glib_minor_version != GLIB_MINOR_VERSION) || ++ (glib_micro_version != GLIB_MICRO_VERSION)) ++ { ++ printf("*** GLIB header files (version %d.%d.%d) do not match\n", ++ GLIB_MAJOR_VERSION, GLIB_MINOR_VERSION, GLIB_MICRO_VERSION); ++ printf("*** library (version %d.%d.%d)\n", ++ glib_major_version, glib_minor_version, glib_micro_version); ++ } ++ else ++ { ++ if ((glib_major_version > major) || ++ ((glib_major_version == major) && (glib_minor_version > minor)) || ++ ((glib_major_version == major) && (glib_minor_version == minor) && (glib_micro_version >= micro))) ++ { ++ return 0; ++ } ++ else ++ { ++ printf("\n*** An old version of GLIB (%d.%d.%d) was found.\n", ++ glib_major_version, glib_minor_version, glib_micro_version); ++ printf("*** You need a version of GLIB newer than %d.%d.%d. The latest version of\n", ++ major, minor, micro); ++ printf("*** GLIB is always available from ftp://ftp.gtk.org.\n"); ++ printf("***\n"); ++ printf("*** If you have already installed a sufficiently new version, this error\n"); ++ printf("*** probably means that the wrong copy of the glib-config shell script is\n"); ++ printf("*** being found. The easiest way to fix this is to remove the old version\n"); ++ printf("*** of GLIB, but you can also set the GLIB_CONFIG environment to point to the\n"); ++ printf("*** correct copy of glib-config. (In this case, you will have to\n"); ++ printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n"); ++ printf("*** so that the correct libraries are found at run-time))\n"); ++ } ++ } ++ return 1; ++} ++],, no_glib=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"]) ++ CFLAGS="$ac_save_CFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ fi ++ if test "x$no_glib" = x ; then ++ AC_MSG_RESULT(yes) ++ ifelse([$2], , :, [$2]) ++ else ++ AC_MSG_RESULT(no) ++ if test "$GLIB_CONFIG" = "no" ; then ++ echo "*** The glib-config script installed by GLIB could not be found" ++ echo "*** If GLIB was installed in PREFIX, make sure PREFIX/bin is in" ++ echo "*** your path, or set the GLIB_CONFIG environment variable to the" ++ echo "*** full path to glib-config." ++ else ++ if test -f conf.glibtest ; then ++ : ++ else ++ echo "*** Could not run GLIB test program, checking why..." ++ CFLAGS="$CFLAGS $GLIB_CFLAGS" ++ LIBS="$LIBS $GLIB_LIBS" ++ AC_TRY_LINK([ ++#include ++#include ++], [ return ((glib_major_version) || (glib_minor_version) || (glib_micro_version)); ], ++ [ echo "*** The test program compiled, but did not run. This usually means" ++ echo "*** that the run-time linker is not finding GLIB or finding the wrong" ++ echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your" ++ echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" ++ echo "*** to the installed location Also, make sure you have run ldconfig if that" ++ echo "*** is required on your system" ++ echo "***" ++ echo "*** If you have an old version installed, it is best to remove it, although" ++ echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" ++ echo "***" ++ echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that" ++ echo "*** came with the system with the command" ++ echo "***" ++ echo "*** rpm --erase --nodeps gtk gtk-devel" ], ++ [ echo "*** The test program failed to compile or link. See the file config.log for the" ++ echo "*** exact error that occured. This usually means GLIB was incorrectly installed" ++ echo "*** or that you have moved GLIB since it was installed. In the latter case, you" ++ echo "*** may want to edit the glib-config script: $GLIB_CONFIG" ]) ++ CFLAGS="$ac_save_CFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ fi ++ GLIB_CFLAGS="" ++ GLIB_LIBS="" ++ ifelse([$3], , :, [$3]) ++ fi ++ AC_SUBST(GLIB_CFLAGS) ++ AC_SUBST(GLIB_LIBS) ++ rm -f conf.glibtest ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/iconv.m4 +@@ -0,0 +1,103 @@ ++# iconv.m4 serial AM4 (gettext-0.11.3) ++dnl Copyright (C) 2000-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Bruno Haible. ++ ++AC_DEFUN([AM_ICONV_LINKFLAGS_BODY], ++[ ++ dnl Prerequisites of AC_LIB_LINKFLAGS_BODY. ++ AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) ++ AC_REQUIRE([AC_LIB_RPATH]) ++ ++ dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV ++ dnl accordingly. ++ AC_LIB_LINKFLAGS_BODY([iconv]) ++]) ++ ++AC_DEFUN([AM_ICONV_LINK], ++[ ++ dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and ++ dnl those with the standalone portable GNU libiconv installed). ++ ++ dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV ++ dnl accordingly. ++ AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY]) ++ ++ dnl Add $INCICONV to CPPFLAGS before performing the following checks, ++ dnl because if the user has installed libiconv and not disabled its use ++ dnl via --without-libiconv-prefix, he wants to use it. The first ++ dnl AC_TRY_LINK will then fail, the second AC_TRY_LINK will succeed. ++ am_save_CPPFLAGS="$CPPFLAGS" ++ AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV]) ++ ++ AC_CACHE_CHECK(for iconv, am_cv_func_iconv, [ ++ am_cv_func_iconv="no, consider installing GNU libiconv" ++ am_cv_lib_iconv=no ++ AC_TRY_LINK([#include ++#include ], ++ [iconv_t cd = iconv_open("",""); ++ iconv(cd,NULL,NULL,NULL,NULL); ++ iconv_close(cd);], ++ am_cv_func_iconv=yes) ++ if test "$am_cv_func_iconv" != yes; then ++ am_save_LIBS="$LIBS" ++ LIBS="$LIBS $LIBICONV" ++ AC_TRY_LINK([#include ++#include ], ++ [iconv_t cd = iconv_open("",""); ++ iconv(cd,NULL,NULL,NULL,NULL); ++ iconv_close(cd);], ++ am_cv_lib_iconv=yes ++ am_cv_func_iconv=yes) ++ LIBS="$am_save_LIBS" ++ fi ++ ]) ++ if test "$am_cv_func_iconv" = yes; then ++ AC_DEFINE(HAVE_ICONV, 1, [Define if you have the iconv() function.]) ++ fi ++ if test "$am_cv_lib_iconv" = yes; then ++ AC_MSG_CHECKING([how to link with libiconv]) ++ AC_MSG_RESULT([$LIBICONV]) ++ else ++ dnl If $LIBICONV didn't lead to a usable library, we don't need $INCICONV ++ dnl either. ++ CPPFLAGS="$am_save_CPPFLAGS" ++ LIBICONV= ++ LTLIBICONV= ++ fi ++ AC_SUBST(LIBICONV) ++ AC_SUBST(LTLIBICONV) ++]) ++ ++AC_DEFUN([AM_ICONV], ++[ ++ AM_ICONV_LINK ++ if test "$am_cv_func_iconv" = yes; then ++ AC_MSG_CHECKING([for iconv declaration]) ++ AC_CACHE_VAL(am_cv_proto_iconv, [ ++ AC_TRY_COMPILE([ ++#include ++#include ++extern ++#ifdef __cplusplus ++"C" ++#endif ++#if defined(__STDC__) || defined(__cplusplus) ++size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); ++#else ++size_t iconv(); ++#endif ++], [], am_cv_proto_iconv_arg1="", am_cv_proto_iconv_arg1="const") ++ am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"]) ++ am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'` ++ AC_MSG_RESULT([$]{ac_t:- ++ }[$]am_cv_proto_iconv) ++ AC_DEFINE_UNQUOTED(ICONV_CONST, $am_cv_proto_iconv_arg1, ++ [Define as const if the declaration of iconv() needs const.]) ++ fi ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/intdiv0.m4 +@@ -0,0 +1,72 @@ ++# intdiv0.m4 serial 1 (gettext-0.11.3) ++dnl Copyright (C) 2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Bruno Haible. ++ ++AC_DEFUN([gt_INTDIV0], ++[ ++ AC_REQUIRE([AC_PROG_CC])dnl ++ AC_REQUIRE([AC_CANONICAL_HOST])dnl ++ ++ AC_CACHE_CHECK([whether integer division by zero raises SIGFPE], ++ gt_cv_int_divbyzero_sigfpe, ++ [ ++ AC_TRY_RUN([ ++#include ++#include ++ ++static void ++#ifdef __cplusplus ++sigfpe_handler (int sig) ++#else ++sigfpe_handler (sig) int sig; ++#endif ++{ ++ /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */ ++ exit (sig != SIGFPE); ++} ++ ++int x = 1; ++int y = 0; ++int z; ++int nan; ++ ++int main () ++{ ++ signal (SIGFPE, sigfpe_handler); ++/* IRIX and AIX (when "xlc -qcheck" is used) yield signal SIGTRAP. */ ++#if (defined (__sgi) || defined (_AIX)) && defined (SIGTRAP) ++ signal (SIGTRAP, sigfpe_handler); ++#endif ++/* Linux/SPARC yields signal SIGILL. */ ++#if defined (__sparc__) && defined (__linux__) ++ signal (SIGILL, sigfpe_handler); ++#endif ++ ++ z = x / y; ++ nan = y / y; ++ exit (1); ++} ++], gt_cv_int_divbyzero_sigfpe=yes, gt_cv_int_divbyzero_sigfpe=no, ++ [ ++ # Guess based on the CPU. ++ case "$host_cpu" in ++ alpha* | i[34567]86 | m68k | s390*) ++ gt_cv_int_divbyzero_sigfpe="guessing yes";; ++ *) ++ gt_cv_int_divbyzero_sigfpe="guessing no";; ++ esac ++ ]) ++ ]) ++ case "$gt_cv_int_divbyzero_sigfpe" in ++ *yes) value=1;; ++ *) value=0;; ++ esac ++ AC_DEFINE_UNQUOTED(INTDIV0_RAISES_SIGFPE, $value, ++ [Define if integer division by zero raises signal SIGFPE.]) ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/inttypes_h.m4 +@@ -0,0 +1,28 @@ ++# inttypes_h.m4 serial 4 (gettext-0.11.4) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++# Define HAVE_INTTYPES_H_WITH_UINTMAX if exists, ++# doesn't clash with , and declares uintmax_t. ++ ++AC_DEFUN([jm_AC_HEADER_INTTYPES_H], ++[ ++ AC_CACHE_CHECK([for inttypes.h], jm_ac_cv_header_inttypes_h, ++ [AC_TRY_COMPILE( ++ [#include ++#include ], ++ [uintmax_t i = (uintmax_t) -1;], ++ jm_ac_cv_header_inttypes_h=yes, ++ jm_ac_cv_header_inttypes_h=no)]) ++ if test $jm_ac_cv_header_inttypes_h = yes; then ++ AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H_WITH_UINTMAX, 1, ++[Define if exists, doesn't clash with , ++ and declares uintmax_t. ]) ++ fi ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/inttypes.m4 +@@ -0,0 +1,27 @@ ++# inttypes.m4 serial 1 (gettext-0.11.4) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++# Define HAVE_INTTYPES_H if exists and doesn't clash with ++# . ++ ++AC_DEFUN([gt_HEADER_INTTYPES_H], ++[ ++ AC_CACHE_CHECK([for inttypes.h], gt_cv_header_inttypes_h, ++ [ ++ AC_TRY_COMPILE( ++ [#include ++#include ], ++ [], gt_cv_header_inttypes_h=yes, gt_cv_header_inttypes_h=no) ++ ]) ++ if test $gt_cv_header_inttypes_h = yes; then ++ AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H, 1, ++ [Define if exists and doesn't clash with .]) ++ fi ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/inttypes-pri.m4 +@@ -0,0 +1,32 @@ ++# inttypes-pri.m4 serial 1 (gettext-0.11.4) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Bruno Haible. ++ ++# Define PRI_MACROS_BROKEN if exists and defines the PRI* ++# macros to non-string values. This is the case on AIX 4.3.3. ++ ++AC_DEFUN([gt_INTTYPES_PRI], ++[ ++ AC_REQUIRE([gt_HEADER_INTTYPES_H]) ++ if test $gt_cv_header_inttypes_h = yes; then ++ AC_CACHE_CHECK([whether the inttypes.h PRIxNN macros are broken], ++ gt_cv_inttypes_pri_broken, ++ [ ++ AC_TRY_COMPILE([#include ++#ifdef PRId32 ++char *p = PRId32; ++#endif ++], [], gt_cv_inttypes_pri_broken=no, gt_cv_inttypes_pri_broken=yes) ++ ]) ++ fi ++ if test "$gt_cv_inttypes_pri_broken" = yes; then ++ AC_DEFINE_UNQUOTED(PRI_MACROS_BROKEN, 1, ++ [Define if exists and defines unusable PRI* macros.]) ++ fi ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/isc-posix.m4 +@@ -0,0 +1,26 @@ ++# isc-posix.m4 serial 2 (gettext-0.11.2) ++dnl Copyright (C) 1995-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++# This file is not needed with autoconf-2.53 and newer. Remove it in 2005. ++ ++# This test replaces the one in autoconf. ++# Currently this macro should have the same name as the autoconf macro ++# because gettext's gettext.m4 (distributed in the automake package) ++# still uses it. Otherwise, the use in gettext.m4 makes autoheader ++# give these diagnostics: ++# configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX ++# configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX ++ ++undefine([AC_ISC_POSIX]) ++ ++AC_DEFUN([AC_ISC_POSIX], ++ [ ++ dnl This test replaces the obsolescent AC_ISC_POSIX kludge. ++ AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"]) ++ ] ++) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/lcmessage.m4 +@@ -0,0 +1,32 @@ ++# lcmessage.m4 serial 3 (gettext-0.11.3) ++dnl Copyright (C) 1995-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++dnl ++dnl This file can can be used in projects which are not available under ++dnl the GNU General Public License or the GNU Library General Public ++dnl License but which still want to provide support for the GNU gettext ++dnl functionality. ++dnl Please note that the actual code of the GNU gettext library is covered ++dnl by the GNU Library General Public License, and the rest of the GNU ++dnl gettext package package is covered by the GNU General Public License. ++dnl They are *not* in the public domain. ++ ++dnl Authors: ++dnl Ulrich Drepper , 1995. ++ ++# Check whether LC_MESSAGES is available in . ++ ++AC_DEFUN([AM_LC_MESSAGES], ++[ ++ AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES, ++ [AC_TRY_LINK([#include ], [return LC_MESSAGES], ++ am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)]) ++ if test $am_cv_val_LC_MESSAGES = yes; then ++ AC_DEFINE(HAVE_LC_MESSAGES, 1, ++ [Define if your file defines LC_MESSAGES.]) ++ fi ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/lib-ld.m4 +@@ -0,0 +1,97 @@ ++# lib-ld.m4 serial 1 (gettext-0.11) ++dnl Copyright (C) 1996-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl Subroutines of libtool.m4, ++dnl with replacements s/AC_/AC_LIB/ and s/lt_cv/acl_cv/ to avoid collision ++dnl with libtool.m4. ++ ++dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no. ++AC_DEFUN([AC_LIB_PROG_LD_GNU], ++[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], acl_cv_prog_gnu_ld, ++[# I'd rather use --version here, but apparently some GNU ld's only accept -v. ++if $LD -v 2>&1 &5; then ++ acl_cv_prog_gnu_ld=yes ++else ++ acl_cv_prog_gnu_ld=no ++fi]) ++with_gnu_ld=$acl_cv_prog_gnu_ld ++]) ++ ++dnl From libtool-1.4. Sets the variable LD. ++AC_DEFUN([AC_LIB_PROG_LD], ++[AC_ARG_WITH(gnu-ld, ++[ --with-gnu-ld assume the C compiler uses GNU ld [default=no]], ++test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no) ++AC_REQUIRE([AC_PROG_CC])dnl ++AC_REQUIRE([AC_CANONICAL_HOST])dnl ++ac_prog=ld ++if test "$GCC" = yes; then ++ # Check if gcc -print-prog-name=ld gives a path. ++ AC_MSG_CHECKING([for ld used by GCC]) ++ case $host in ++ *-*-mingw*) ++ # gcc leaves a trailing carriage return which upsets mingw ++ ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; ++ *) ++ ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; ++ esac ++ case $ac_prog in ++ # Accept absolute paths. ++ [[\\/]* | [A-Za-z]:[\\/]*)] ++ [re_direlt='/[^/][^/]*/\.\./'] ++ # Canonicalize the path of ld ++ ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` ++ while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do ++ ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` ++ done ++ test -z "$LD" && LD="$ac_prog" ++ ;; ++ "") ++ # If it fails, then pretend we aren't using GCC. ++ ac_prog=ld ++ ;; ++ *) ++ # If it is relative, then search for the first ld in PATH. ++ with_gnu_ld=unknown ++ ;; ++ esac ++elif test "$with_gnu_ld" = yes; then ++ AC_MSG_CHECKING([for GNU ld]) ++else ++ AC_MSG_CHECKING([for non-GNU ld]) ++fi ++AC_CACHE_VAL(acl_cv_path_LD, ++[if test -z "$LD"; then ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then ++ acl_cv_path_LD="$ac_dir/$ac_prog" ++ # Check to see if the program is GNU ld. I'd rather use --version, ++ # but apparently some GNU ld's only accept -v. ++ # Break only if it was the GNU/non-GNU ld that we prefer. ++ if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then ++ test "$with_gnu_ld" != no && break ++ else ++ test "$with_gnu_ld" != yes && break ++ fi ++ fi ++ done ++ IFS="$ac_save_ifs" ++else ++ acl_cv_path_LD="$LD" # Let the user override the test with a path. ++fi]) ++LD="$acl_cv_path_LD" ++if test -n "$LD"; then ++ AC_MSG_RESULT($LD) ++else ++ AC_MSG_RESULT(no) ++fi ++test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) ++AC_LIB_PROG_LD_GNU ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/lib-link.m4 +@@ -0,0 +1,554 @@ ++# lib-link.m4 serial 3 (gettext-0.11.3) ++dnl Copyright (C) 2001-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Bruno Haible. ++ ++dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and ++dnl the libraries corresponding to explicit and implicit dependencies. ++dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and ++dnl augments the CPPFLAGS variable. ++AC_DEFUN([AC_LIB_LINKFLAGS], ++[ ++ AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) ++ AC_REQUIRE([AC_LIB_RPATH]) ++ define([Name],[translit([$1],[./-], [___])]) ++ define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], ++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [ ++ AC_LIB_LINKFLAGS_BODY([$1], [$2]) ++ ac_cv_lib[]Name[]_libs="$LIB[]NAME" ++ ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME" ++ ac_cv_lib[]Name[]_cppflags="$INC[]NAME" ++ ]) ++ LIB[]NAME="$ac_cv_lib[]Name[]_libs" ++ LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs" ++ INC[]NAME="$ac_cv_lib[]Name[]_cppflags" ++ AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME) ++ AC_SUBST([LIB]NAME) ++ AC_SUBST([LTLIB]NAME) ++ dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the ++ dnl results of this search when this library appears as a dependency. ++ HAVE_LIB[]NAME=yes ++ undefine([Name]) ++ undefine([NAME]) ++]) ++ ++dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode) ++dnl searches for libname and the libraries corresponding to explicit and ++dnl implicit dependencies, together with the specified include files and ++dnl the ability to compile and link the specified testcode. If found, it ++dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and ++dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and ++dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs ++dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty. ++AC_DEFUN([AC_LIB_HAVE_LINKFLAGS], ++[ ++ AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) ++ AC_REQUIRE([AC_LIB_RPATH]) ++ define([Name],[translit([$1],[./-], [___])]) ++ define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], ++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ ++ dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME ++ dnl accordingly. ++ AC_LIB_LINKFLAGS_BODY([$1], [$2]) ++ ++ dnl Add $INC[]NAME to CPPFLAGS before performing the following checks, ++ dnl because if the user has installed lib[]Name and not disabled its use ++ dnl via --without-lib[]Name-prefix, he wants to use it. ++ ac_save_CPPFLAGS="$CPPFLAGS" ++ AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME) ++ ++ AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [ ++ ac_save_LIBS="$LIBS" ++ LIBS="$LIBS $LIB[]NAME" ++ AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no]) ++ LIBS="$ac_save_LIBS" ++ ]) ++ if test "$ac_cv_lib[]Name" = yes; then ++ HAVE_LIB[]NAME=yes ++ AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.]) ++ AC_MSG_CHECKING([how to link with lib[]$1]) ++ AC_MSG_RESULT([$LIB[]NAME]) ++ else ++ HAVE_LIB[]NAME=no ++ dnl If $LIB[]NAME didn't lead to a usable library, we don't need ++ dnl $INC[]NAME either. ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIB[]NAME= ++ LTLIB[]NAME= ++ fi ++ AC_SUBST([HAVE_LIB]NAME) ++ AC_SUBST([LIB]NAME) ++ AC_SUBST([LTLIB]NAME) ++ undefine([Name]) ++ undefine([NAME]) ++]) ++ ++dnl Determine the platform dependent parameters needed to use rpath: ++dnl libext, shlibext, hardcode_libdir_flag_spec, hardcode_libdir_separator, ++dnl hardcode_direct, hardcode_minus_L, ++dnl sys_lib_search_path_spec, sys_lib_dlsearch_path_spec. ++AC_DEFUN([AC_LIB_RPATH], ++[ ++ AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS ++ AC_REQUIRE([AC_LIB_PROG_LD]) dnl we use $LD, $with_gnu_ld ++ AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use $host ++ AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir ++ AC_CACHE_CHECK([for shared library run path origin], acl_cv_rpath, [ ++ CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \ ++ ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh ++ . ./conftest.sh ++ rm -f ./conftest.sh ++ acl_cv_rpath=done ++ ]) ++ wl="$acl_cv_wl" ++ libext="$acl_cv_libext" ++ shlibext="$acl_cv_shlibext" ++ hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" ++ hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" ++ hardcode_direct="$acl_cv_hardcode_direct" ++ hardcode_minus_L="$acl_cv_hardcode_minus_L" ++ sys_lib_search_path_spec="$acl_cv_sys_lib_search_path_spec" ++ sys_lib_dlsearch_path_spec="$acl_cv_sys_lib_dlsearch_path_spec" ++ dnl Determine whether the user wants rpath handling at all. ++ AC_ARG_ENABLE(rpath, ++ [ --disable-rpath do not hardcode runtime library paths], ++ :, enable_rpath=yes) ++]) ++ ++dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and ++dnl the libraries corresponding to explicit and implicit dependencies. ++dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables. ++AC_DEFUN([AC_LIB_LINKFLAGS_BODY], ++[ ++ define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-], ++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])]) ++ dnl By default, look in $includedir and $libdir. ++ use_additional=yes ++ AC_LIB_WITH_FINAL_PREFIX([ ++ eval additional_includedir=\"$includedir\" ++ eval additional_libdir=\"$libdir\" ++ ]) ++ AC_ARG_WITH([lib$1-prefix], ++[ --with-lib$1-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib ++ --without-lib$1-prefix don't search for lib$1 in includedir and libdir], ++[ ++ if test "X$withval" = "Xno"; then ++ use_additional=no ++ else ++ if test "X$withval" = "X"; then ++ AC_LIB_WITH_FINAL_PREFIX([ ++ eval additional_includedir=\"$includedir\" ++ eval additional_libdir=\"$libdir\" ++ ]) ++ else ++ additional_includedir="$withval/include" ++ additional_libdir="$withval/lib" ++ fi ++ fi ++]) ++ dnl Search the library and its dependencies in $additional_libdir and ++ dnl $LDFLAGS. Using breadth-first-seach. ++ LIB[]NAME= ++ LTLIB[]NAME= ++ INC[]NAME= ++ rpathdirs= ++ ltrpathdirs= ++ names_already_handled= ++ names_next_round='$1 $2' ++ while test -n "$names_next_round"; do ++ names_this_round="$names_next_round" ++ names_next_round= ++ for name in $names_this_round; do ++ already_handled= ++ for n in $names_already_handled; do ++ if test "$n" = "$name"; then ++ already_handled=yes ++ break ++ fi ++ done ++ if test -z "$already_handled"; then ++ names_already_handled="$names_already_handled $name" ++ dnl See if it was already located by an earlier AC_LIB_LINKFLAGS ++ dnl or AC_LIB_HAVE_LINKFLAGS call. ++ uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` ++ eval value=\"\$HAVE_LIB$uppername\" ++ if test -n "$value"; then ++ if test "$value" = yes; then ++ eval value=\"\$LIB$uppername\" ++ test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value" ++ eval value=\"\$LTLIB$uppername\" ++ test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value" ++ else ++ dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined ++ dnl that this library doesn't exist. So just drop it. ++ : ++ fi ++ else ++ dnl Search the library lib$name in $additional_libdir and $LDFLAGS ++ dnl and the already constructed $LIBNAME/$LTLIBNAME. ++ found_dir= ++ found_la= ++ found_so= ++ found_a= ++ if test $use_additional = yes; then ++ if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then ++ found_dir="$additional_libdir" ++ found_so="$additional_libdir/lib$name.$shlibext" ++ if test -f "$additional_libdir/lib$name.la"; then ++ found_la="$additional_libdir/lib$name.la" ++ fi ++ else ++ if test -f "$additional_libdir/lib$name.$libext"; then ++ found_dir="$additional_libdir" ++ found_a="$additional_libdir/lib$name.$libext" ++ if test -f "$additional_libdir/lib$name.la"; then ++ found_la="$additional_libdir/lib$name.la" ++ fi ++ fi ++ fi ++ fi ++ if test "X$found_dir" = "X"; then ++ for x in $LDFLAGS $LTLIB[]NAME; do ++ AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) ++ case "$x" in ++ -L*) ++ dir=`echo "X$x" | sed -e 's/^X-L//'` ++ if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then ++ found_dir="$dir" ++ found_so="$dir/lib$name.$shlibext" ++ if test -f "$dir/lib$name.la"; then ++ found_la="$dir/lib$name.la" ++ fi ++ else ++ if test -f "$dir/lib$name.$libext"; then ++ found_dir="$dir" ++ found_a="$dir/lib$name.$libext" ++ if test -f "$dir/lib$name.la"; then ++ found_la="$dir/lib$name.la" ++ fi ++ fi ++ fi ++ ;; ++ esac ++ if test "X$found_dir" != "X"; then ++ break ++ fi ++ done ++ fi ++ if test "X$found_dir" != "X"; then ++ dnl Found the library. ++ LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$found_dir -l$name" ++ if test "X$found_so" != "X"; then ++ dnl Linking with a shared library. We attempt to hardcode its ++ dnl directory into the executable's runpath, unless it's the ++ dnl standard /usr/lib. ++ if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then ++ dnl No hardcoding is needed. ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" ++ else ++ dnl Use an explicit option to hardcode DIR into the resulting ++ dnl binary. ++ dnl Potentially add DIR to ltrpathdirs. ++ dnl The ltrpathdirs will be appended to $LTLIBNAME at the end. ++ haveit= ++ for x in $ltrpathdirs; do ++ if test "X$x" = "X$found_dir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ ltrpathdirs="$ltrpathdirs $found_dir" ++ fi ++ dnl The hardcoding into $LIBNAME is system dependent. ++ if test "$hardcode_direct" = yes; then ++ dnl Using DIR/libNAME.so during linking hardcodes DIR into the ++ dnl resulting binary. ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" ++ else ++ if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then ++ dnl Use an explicit option to hardcode DIR into the resulting ++ dnl binary. ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" ++ dnl Potentially add DIR to rpathdirs. ++ dnl The rpathdirs will be appended to $LIBNAME at the end. ++ haveit= ++ for x in $rpathdirs; do ++ if test "X$x" = "X$found_dir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ rpathdirs="$rpathdirs $found_dir" ++ fi ++ else ++ dnl Rely on "-L$found_dir". ++ dnl But don't add it if it's already contained in the LDFLAGS ++ dnl or the already constructed $LIBNAME ++ haveit= ++ for x in $LDFLAGS $LIB[]NAME; do ++ AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) ++ if test "X$x" = "X-L$found_dir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir" ++ fi ++ if test "$hardcode_minus_L" != no; then ++ dnl FIXME: Not sure whether we should use ++ dnl "-L$found_dir -l$name" or "-L$found_dir $found_so" ++ dnl here. ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so" ++ else ++ dnl We cannot use $hardcode_runpath_var and LD_RUN_PATH ++ dnl here, because this doesn't fit in flags passed to the ++ dnl compiler. So give up. No hardcoding. This affects only ++ dnl very old systems. ++ dnl FIXME: Not sure whether we should use ++ dnl "-L$found_dir -l$name" or "-L$found_dir $found_so" ++ dnl here. ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name" ++ fi ++ fi ++ fi ++ fi ++ else ++ if test "X$found_a" != "X"; then ++ dnl Linking with a static library. ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_a" ++ else ++ dnl We shouldn't come here, but anyway it's good to have a ++ dnl fallback. ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir -l$name" ++ fi ++ fi ++ dnl Assume the include files are nearby. ++ additional_includedir= ++ case "$found_dir" in ++ */lib | */lib/) ++ basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` ++ additional_includedir="$basedir/include" ++ ;; ++ esac ++ if test "X$additional_includedir" != "X"; then ++ dnl Potentially add $additional_includedir to $INCNAME. ++ dnl But don't add it ++ dnl 1. if it's the standard /usr/include, ++ dnl 2. if it's /usr/local/include and we are using GCC on Linux, ++ dnl 3. if it's already present in $CPPFLAGS or the already ++ dnl constructed $INCNAME, ++ dnl 4. if it doesn't exist as a directory. ++ if test "X$additional_includedir" != "X/usr/include"; then ++ haveit= ++ if test "X$additional_includedir" = "X/usr/local/include"; then ++ if test -n "$GCC"; then ++ case $host_os in ++ linux*) haveit=yes;; ++ esac ++ fi ++ fi ++ if test -z "$haveit"; then ++ for x in $CPPFLAGS $INC[]NAME; do ++ AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) ++ if test "X$x" = "X-I$additional_includedir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ if test -d "$additional_includedir"; then ++ dnl Really add $additional_includedir to $INCNAME. ++ INC[]NAME="${INC[]NAME}${INC[]NAME:+ }-I$additional_includedir" ++ fi ++ fi ++ fi ++ fi ++ fi ++ dnl Look for dependencies. ++ if test -n "$found_la"; then ++ dnl Read the .la file. It defines the variables ++ dnl dlname, library_names, old_library, dependency_libs, current, ++ dnl age, revision, installed, dlopen, dlpreopen, libdir. ++ save_libdir="$libdir" ++ case "$found_la" in ++ */* | *\\*) . "$found_la" ;; ++ *) . "./$found_la" ;; ++ esac ++ libdir="$save_libdir" ++ dnl We use only dependency_libs. ++ for dep in $dependency_libs; do ++ case "$dep" in ++ -L*) ++ additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` ++ dnl Potentially add $additional_libdir to $LIBNAME and $LTLIBNAME. ++ dnl But don't add it ++ dnl 1. if it's the standard /usr/lib, ++ dnl 2. if it's /usr/local/lib and we are using GCC on Linux, ++ dnl 3. if it's already present in $LDFLAGS or the already ++ dnl constructed $LIBNAME, ++ dnl 4. if it doesn't exist as a directory. ++ if test "X$additional_libdir" != "X/usr/lib"; then ++ haveit= ++ if test "X$additional_libdir" = "X/usr/local/lib"; then ++ if test -n "$GCC"; then ++ case $host_os in ++ linux*) haveit=yes;; ++ esac ++ fi ++ fi ++ if test -z "$haveit"; then ++ haveit= ++ for x in $LDFLAGS $LIB[]NAME; do ++ AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) ++ if test "X$x" = "X-L$additional_libdir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ if test -d "$additional_libdir"; then ++ dnl Really add $additional_libdir to $LIBNAME. ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$additional_libdir" ++ fi ++ fi ++ haveit= ++ for x in $LDFLAGS $LTLIB[]NAME; do ++ AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) ++ if test "X$x" = "X-L$additional_libdir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ if test -d "$additional_libdir"; then ++ dnl Really add $additional_libdir to $LTLIBNAME. ++ LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$additional_libdir" ++ fi ++ fi ++ fi ++ fi ++ ;; ++ -R*) ++ dir=`echo "X$dep" | sed -e 's/^X-R//'` ++ if test "$enable_rpath" != no; then ++ dnl Potentially add DIR to rpathdirs. ++ dnl The rpathdirs will be appended to $LIBNAME at the end. ++ haveit= ++ for x in $rpathdirs; do ++ if test "X$x" = "X$dir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ rpathdirs="$rpathdirs $dir" ++ fi ++ dnl Potentially add DIR to ltrpathdirs. ++ dnl The ltrpathdirs will be appended to $LTLIBNAME at the end. ++ haveit= ++ for x in $ltrpathdirs; do ++ if test "X$x" = "X$dir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ ltrpathdirs="$ltrpathdirs $dir" ++ fi ++ fi ++ ;; ++ -l*) ++ dnl Handle this in the next round. ++ names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` ++ ;; ++ *.la) ++ dnl Handle this in the next round. Throw away the .la's ++ dnl directory; it is already contained in a preceding -L ++ dnl option. ++ names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` ++ ;; ++ *) ++ dnl Most likely an immediate library name. ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$dep" ++ LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$dep" ++ ;; ++ esac ++ done ++ fi ++ else ++ dnl Didn't find the library; assume it is in the system directories ++ dnl known to the linker and runtime loader. (All the system ++ dnl directories known to the linker should also be known to the ++ dnl runtime loader, otherwise the system is severely misconfigured.) ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name" ++ LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-l$name" ++ fi ++ fi ++ fi ++ done ++ done ++ if test "X$rpathdirs" != "X"; then ++ if test -n "$hardcode_libdir_separator"; then ++ dnl Weird platform: only the last -rpath option counts, the user must ++ dnl pass all path elements in one option. We can arrange that for a ++ dnl single library, but not when more than one $LIBNAMEs are used. ++ alldirs= ++ for found_dir in $rpathdirs; do ++ alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" ++ done ++ dnl Note: hardcode_libdir_flag_spec uses $libdir and $wl. ++ acl_save_libdir="$libdir" ++ libdir="$alldirs" ++ eval flag=\"$hardcode_libdir_flag_spec\" ++ libdir="$acl_save_libdir" ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" ++ else ++ dnl The -rpath options are cumulative. ++ for found_dir in $rpathdirs; do ++ acl_save_libdir="$libdir" ++ libdir="$found_dir" ++ eval flag=\"$hardcode_libdir_flag_spec\" ++ libdir="$acl_save_libdir" ++ LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag" ++ done ++ fi ++ fi ++ if test "X$ltrpathdirs" != "X"; then ++ dnl When using libtool, the option that works for both libraries and ++ dnl executables is -R. The -R options are cumulative. ++ for found_dir in $ltrpathdirs; do ++ LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir" ++ done ++ fi ++]) ++ ++dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR, ++dnl unless already present in VAR. ++dnl Works only for CPPFLAGS, not for LIB* variables because that sometimes ++dnl contains two or three consecutive elements that belong together. ++AC_DEFUN([AC_LIB_APPENDTOVAR], ++[ ++ for element in [$2]; do ++ haveit= ++ for x in $[$1]; do ++ AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) ++ if test "X$x" = "X$element"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ [$1]="${[$1]}${[$1]:+ }$element" ++ fi ++ done ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/lib-prefix.m4 +@@ -0,0 +1,148 @@ ++# lib-prefix.m4 serial 1 (gettext-0.11) ++dnl Copyright (C) 2001-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Bruno Haible. ++ ++dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed ++dnl to access previously installed libraries. The basic assumption is that ++dnl a user will want packages to use other packages he previously installed ++dnl with the same --prefix option. ++dnl This macro is not needed if only AC_LIB_LINKFLAGS is used to locate ++dnl libraries, but is otherwise very convenient. ++AC_DEFUN([AC_LIB_PREFIX], ++[ ++ AC_BEFORE([$0], [AC_LIB_LINKFLAGS]) ++ AC_REQUIRE([AC_PROG_CC]) ++ AC_REQUIRE([AC_CANONICAL_HOST]) ++ AC_REQUIRE([AC_LIB_PREPARE_PREFIX]) ++ dnl By default, look in $includedir and $libdir. ++ use_additional=yes ++ AC_LIB_WITH_FINAL_PREFIX([ ++ eval additional_includedir=\"$includedir\" ++ eval additional_libdir=\"$libdir\" ++ ]) ++ AC_ARG_WITH([lib-prefix], ++[ --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib ++ --without-lib-prefix don't search for libraries in includedir and libdir], ++[ ++ if test "X$withval" = "Xno"; then ++ use_additional=no ++ else ++ if test "X$withval" = "X"; then ++ AC_LIB_WITH_FINAL_PREFIX([ ++ eval additional_includedir=\"$includedir\" ++ eval additional_libdir=\"$libdir\" ++ ]) ++ else ++ additional_includedir="$withval/include" ++ additional_libdir="$withval/lib" ++ fi ++ fi ++]) ++ if test $use_additional = yes; then ++ dnl Potentially add $additional_includedir to $CPPFLAGS. ++ dnl But don't add it ++ dnl 1. if it's the standard /usr/include, ++ dnl 2. if it's already present in $CPPFLAGS, ++ dnl 3. if it's /usr/local/include and we are using GCC on Linux, ++ dnl 4. if it doesn't exist as a directory. ++ if test "X$additional_includedir" != "X/usr/include"; then ++ haveit= ++ for x in $CPPFLAGS; do ++ AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) ++ if test "X$x" = "X-I$additional_includedir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ if test "X$additional_includedir" = "X/usr/local/include"; then ++ if test -n "$GCC"; then ++ case $host_os in ++ linux*) haveit=yes;; ++ esac ++ fi ++ fi ++ if test -z "$haveit"; then ++ if test -d "$additional_includedir"; then ++ dnl Really add $additional_includedir to $CPPFLAGS. ++ CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }-I$additional_includedir" ++ fi ++ fi ++ fi ++ fi ++ dnl Potentially add $additional_libdir to $LDFLAGS. ++ dnl But don't add it ++ dnl 1. if it's the standard /usr/lib, ++ dnl 2. if it's already present in $LDFLAGS, ++ dnl 3. if it's /usr/local/lib and we are using GCC on Linux, ++ dnl 4. if it doesn't exist as a directory. ++ if test "X$additional_libdir" != "X/usr/lib"; then ++ haveit= ++ for x in $LDFLAGS; do ++ AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"]) ++ if test "X$x" = "X-L$additional_libdir"; then ++ haveit=yes ++ break ++ fi ++ done ++ if test -z "$haveit"; then ++ if test "X$additional_libdir" = "X/usr/local/lib"; then ++ if test -n "$GCC"; then ++ case $host_os in ++ linux*) haveit=yes;; ++ esac ++ fi ++ fi ++ if test -z "$haveit"; then ++ if test -d "$additional_libdir"; then ++ dnl Really add $additional_libdir to $LDFLAGS. ++ LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir" ++ fi ++ fi ++ fi ++ fi ++ fi ++]) ++ ++dnl AC_LIB_PREPARE_PREFIX creates variables acl_final_prefix, ++dnl acl_final_exec_prefix, containing the values to which $prefix and ++dnl $exec_prefix will expand at the end of the configure script. ++AC_DEFUN([AC_LIB_PREPARE_PREFIX], ++[ ++ dnl Unfortunately, prefix and exec_prefix get only finally determined ++ dnl at the end of configure. ++ if test "X$prefix" = "XNONE"; then ++ acl_final_prefix="$ac_default_prefix" ++ else ++ acl_final_prefix="$prefix" ++ fi ++ if test "X$exec_prefix" = "XNONE"; then ++ acl_final_exec_prefix='${prefix}' ++ else ++ acl_final_exec_prefix="$exec_prefix" ++ fi ++ acl_save_prefix="$prefix" ++ prefix="$acl_final_prefix" ++ eval acl_final_exec_prefix=\"$acl_final_exec_prefix\" ++ prefix="$acl_save_prefix" ++]) ++ ++dnl AC_LIB_WITH_FINAL_PREFIX([statement]) evaluates statement, with the ++dnl variables prefix and exec_prefix bound to the values they will have ++dnl at the end of the configure script. ++AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX], ++[ ++ acl_save_prefix="$prefix" ++ prefix="$acl_final_prefix" ++ acl_save_exec_prefix="$exec_prefix" ++ exec_prefix="$acl_final_exec_prefix" ++ $1 ++ exec_prefix="$acl_save_exec_prefix" ++ prefix="$acl_save_prefix" ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/progtest.m4 +@@ -0,0 +1,59 @@ ++# progtest.m4 serial 2 (gettext-0.10.40) ++dnl Copyright (C) 1996-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++dnl ++dnl This file can can be used in projects which are not available under ++dnl the GNU General Public License or the GNU Library General Public ++dnl License but which still want to provide support for the GNU gettext ++dnl functionality. ++dnl Please note that the actual code of the GNU gettext library is covered ++dnl by the GNU Library General Public License, and the rest of the GNU ++dnl gettext package package is covered by the GNU General Public License. ++dnl They are *not* in the public domain. ++ ++dnl Authors: ++dnl Ulrich Drepper , 1996. ++ ++# Search path for a program which passes the given test. ++ ++dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR, ++dnl TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]]) ++AC_DEFUN([AM_PATH_PROG_WITH_TEST], ++[# Extract the first word of "$2", so it can be a program name with args. ++set dummy $2; ac_word=[$]2 ++AC_MSG_CHECKING([for $ac_word]) ++AC_CACHE_VAL(ac_cv_path_$1, ++[case "[$]$1" in ++ /*) ++ ac_cv_path_$1="[$]$1" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in ifelse([$5], , $PATH, [$5]); do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if [$3]; then ++ ac_cv_path_$1="$ac_dir/$ac_word" ++ break ++ fi ++ fi ++ done ++ IFS="$ac_save_ifs" ++dnl If no 4th arg is given, leave the cache variable unset, ++dnl so AC_PATH_PROGS will keep looking. ++ifelse([$4], , , [ test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4" ++])dnl ++ ;; ++esac])dnl ++$1="$ac_cv_path_$1" ++if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then ++ AC_MSG_RESULT([$]$1) ++else ++ AC_MSG_RESULT(no) ++fi ++AC_SUBST($1)dnl ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/stdint_h.m4 +@@ -0,0 +1,28 @@ ++# stdint_h.m4 serial 2 (gettext-0.11.4) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++# Define HAVE_STDINT_H_WITH_UINTMAX if exists, ++# doesn't clash with , and declares uintmax_t. ++ ++AC_DEFUN([jm_AC_HEADER_STDINT_H], ++[ ++ AC_CACHE_CHECK([for stdint.h], jm_ac_cv_header_stdint_h, ++ [AC_TRY_COMPILE( ++ [#include ++#include ], ++ [uintmax_t i = (uintmax_t) -1;], ++ jm_ac_cv_header_stdint_h=yes, ++ jm_ac_cv_header_stdint_h=no)]) ++ if test $jm_ac_cv_header_stdint_h = yes; then ++ AC_DEFINE_UNQUOTED(HAVE_STDINT_H_WITH_UINTMAX, 1, ++[Define if exists, doesn't clash with , ++ and declares uintmax_t. ]) ++ fi ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/uintmax_t.m4 +@@ -0,0 +1,29 @@ ++# uintmax_t.m4 serial 6 (gettext-0.11) ++dnl Copyright (C) 1997-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++AC_PREREQ(2.13) ++ ++# Define uintmax_t to `unsigned long' or `unsigned long long' ++# if does not exist. ++ ++AC_DEFUN([jm_AC_TYPE_UINTMAX_T], ++[ ++ AC_REQUIRE([jm_AC_HEADER_INTTYPES_H]) ++ AC_REQUIRE([jm_AC_HEADER_STDINT_H]) ++ if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then ++ AC_REQUIRE([jm_AC_TYPE_UNSIGNED_LONG_LONG]) ++ test $ac_cv_type_unsigned_long_long = yes \ ++ && ac_type='unsigned long long' \ ++ || ac_type='unsigned long' ++ AC_DEFINE_UNQUOTED(uintmax_t, $ac_type, ++ [Define to unsigned long or unsigned long long ++ if and don't define.]) ++ fi ++]) +--- /dev/null ++++ e2fsprogs-libs-1.34/m4/ulonglong.m4 +@@ -0,0 +1,23 @@ ++# ulonglong.m4 serial 2 (fileutils-4.0.32, gettext-0.10.40) ++dnl Copyright (C) 1999-2002 Free Software Foundation, Inc. ++dnl This file is free software, distributed under the terms of the GNU ++dnl General Public License. As a special exception to the GNU General ++dnl Public License, this file may be distributed as part of a program ++dnl that contains a configuration script generated by Autoconf, under ++dnl the same distribution terms as the rest of that program. ++ ++dnl From Paul Eggert. ++ ++AC_DEFUN([jm_AC_TYPE_UNSIGNED_LONG_LONG], ++[ ++ AC_CACHE_CHECK([for unsigned long long], ac_cv_type_unsigned_long_long, ++ [AC_TRY_LINK([unsigned long long ull = 1; int i = 63;], ++ [unsigned long long ullmax = (unsigned long long) -1; ++ return ull << i | ull >> i | ullmax / ull | ullmax % ull;], ++ ac_cv_type_unsigned_long_long=yes, ++ ac_cv_type_unsigned_long_long=no)]) ++ if test $ac_cv_type_unsigned_long_long = yes; then ++ AC_DEFINE(HAVE_UNSIGNED_LONG_LONG, 1, ++ [Define if you have the unsigned long long type.]) ++ fi ++]) diff --git a/meta/packages/e2fsprogs/e2fsprogs_1.38.bb b/meta/packages/e2fsprogs/e2fsprogs_1.38.bb new file mode 100644 index 000000000..c27cf4c3f --- /dev/null +++ b/meta/packages/e2fsprogs/e2fsprogs_1.38.bb @@ -0,0 +1,50 @@ +DESCRIPTION = "EXT2 Filesystem Utilities" +HOMEPAGE = "http://e2fsprogs.sourceforge.net" +LICENSE = "GPL" +SECTION = "base" +PR = "r6" + +SRC_URI = "${SOURCEFORGE_MIRROR}/e2fsprogs/e2fsprogs-${PV}.tar.gz \ + file://no-hardlinks.patch;patch=1" +S = "${WORKDIR}/e2fsprogs-${PV}" + +inherit autotools + +EXTRA_OECONF = "--enable-dynamic-e2fsck --sbindir=${base_sbindir}" + +do_compile_prepend () { + find ./ -print|xargs chmod u=rwX + ( cd util; ${BUILD_CC} subst.c -o subst ) +} + +ext2fsheaders = "ext2_ext_attr.h bitops.h ext2_err.h \ + ext2_types.h ext2_fs.h ext2_io.h \ + ext2fs.h" +e2pheaders = "e2p.h" + +do_stage () { + oe_libinstall -a -C lib libe2p ${STAGING_LIBDIR}/ + oe_libinstall -a -C lib libext2fs ${STAGING_LIBDIR}/ + install -d ${STAGING_INCDIR}/e2p + for h in ${e2pheaders}; do + install -m 0644 lib/e2p/$h ${STAGING_INCDIR}/e2p/ || die "failed to install $h" + done + install -d ${STAGING_INCDIR}/ext2fs + for h in ${ext2fsheaders}; do + install -m 0644 lib/ext2fs/$h ${STAGING_INCDIR}/ext2fs/ || die "failed to install $h" + done +} + +# blkid used to be part of e2fsprogs but is useful outside, add it +# as an RDEPENDS so that anything relying on it being in e2fsprogs +# still works +RDEPENDS_e2fsprogs = "e2fsprogs-blkid e2fsprogs-uuidgen e2fsprogs-badblocks" + +PACKAGES =+ "e2fsprogs-blkid e2fsprogs-uuidgen e2fsprogs-e2fsck e2fsprogs-mke2fs e2fsprogs-fsck e2fsprogs-tune2fs e2fsprogs-badblocks" +FILES_e2fsprogs-blkid = "${base_sbindir}/blkid" +FILES_e2fsprogs-uuidgen = "${bindir}/uuidgen" +FILES_e2fsprogs-fsck = "${base_sbindir}/fsck" +FILES_e2fsprogs-e2fsck = "${base_sbindir}/e2fsck ${base_sbindir}/fsck.ext*" +FILES_e2fsprogs-mke2fs = "${base_sbindir}/mke2fs ${base_sbindir}/mkfs.ext*" +FILES_e2fsprogs-tune2fs = "${base_sbindir}/tune2fs ${base_sbindir}/e2label ${base_sbindir}/findfs" +FILES_e2fsprogs-badblocks = "${base_sbindir}/badblocks" \ No newline at end of file diff --git a/meta/packages/eds/eds-dbus/disable_orbit.patch b/meta/packages/eds/eds-dbus/disable_orbit.patch new file mode 100644 index 000000000..8757666e9 --- /dev/null +++ b/meta/packages/eds/eds-dbus/disable_orbit.patch @@ -0,0 +1,13 @@ +Index: trunk/configure.in +=================================================================== +--- trunk.orig/configure.in 2006-01-20 02:08:42.555073776 +0000 ++++ trunk/configure.in 2006-01-20 10:19:13.631870024 +0000 +@@ -1114,7 +1114,7 @@ + AC_MSG_RESULT($with_bug_buddy) + + if test "x${with_dbus}" = "xno"; then +- AM_PATH_ORBIT2(2.9.8) ++dnl AM_PATH_ORBIT2(2.9.8) + + AC_MSG_CHECKING(for CORBA include paths) + IDL_INCLUDES="-I "`pkg-config --variable=idldir libbonobo-2.0`" -I "`pkg-config --variable=idldir bonobo-activation-2.0` diff --git a/meta/packages/eds/eds-dbus/fix_calendar.patch b/meta/packages/eds/eds-dbus/fix_calendar.patch new file mode 100644 index 000000000..dab40a822 --- /dev/null +++ b/meta/packages/eds/eds-dbus/fix_calendar.patch @@ -0,0 +1,11 @@ +--- trunk/calendar/libecal-dbus/e-cal.c.old 2006-07-05 12:23:17.000000000 +0100 ++++ trunk/calendar/libecal-dbus/e-cal.c 2006-07-05 12:24:17.000000000 +0100 +@@ -2930,7 +2930,7 @@ + E_CALENDAR_CHECK_STATUS (E_CALENDAR_STATUS_CORBA_EXCEPTION, error); + } + +- if (uid) ++ if (!uid) + E_CALENDAR_CHECK_STATUS (E_CALENDAR_STATUS_OTHER_ERROR, error); + else + E_CALENDAR_CHECK_STATUS (E_CALENDAR_STATUS_OK, error); diff --git a/meta/packages/eds/eds-dbus/iconv-detect.h b/meta/packages/eds/eds-dbus/iconv-detect.h new file mode 100644 index 000000000..46f476d5b --- /dev/null +++ b/meta/packages/eds/eds-dbus/iconv-detect.h @@ -0,0 +1,5 @@ +/* This is an auto-generated header, DO NOT EDIT! */ + +#define ICONV_ISO_D_FORMAT "iso-%d-%d" +#define ICONV_ISO_S_FORMAT "iso-%d-%s" +#define ICONV_10646 "iso-10646" diff --git a/meta/packages/eds/eds-dbus/no_iconv_test.patch b/meta/packages/eds/eds-dbus/no_iconv_test.patch new file mode 100644 index 000000000..6e33c7889 --- /dev/null +++ b/meta/packages/eds/eds-dbus/no_iconv_test.patch @@ -0,0 +1,70 @@ +Index: trunk/configure.in +=================================================================== +--- trunk.orig/configure.in 2005-09-28 17:34:08.000000000 +0000 ++++ trunk/configure.in 2005-09-28 19:13:22.000000000 +0000 +@@ -213,39 +213,6 @@ + if test $ac_cv_libiconv = no; then + AC_CHECK_FUNCS(gnu_get_libc_version) + fi +- AC_CACHE_CHECK([if iconv() handles UTF-8], ac_cv_libiconv_utf8, AC_TRY_RUN([ +-#include +-#include +-#include +-#ifdef HAVE_GNU_GET_LIBC_VERSION +-#include +-#endif +- +-int main (int argc, char **argv) +-{ +- const char *from = "Some Text \xA4"; +- const char *utf8 = "Some Text \xC2\xA4"; +- char *transbuf = malloc (20), *trans = transbuf; +- iconv_t cd; +- size_t from_len = strlen (from), utf8_len = 20; +- size_t utf8_real_len = strlen (utf8); +- +-#ifdef HAVE_GNU_GET_LIBC_VERSION +- /* glibc 2.1.2's iconv is broken in hard to test ways. */ +- if (!strcmp (gnu_get_libc_version (), "2.1.2")) +- exit (1); +-#endif +- +- cd = iconv_open ("UTF-8", "ISO_8859-1"); +- if (cd == (iconv_t) -1) +- exit (1); +- if (iconv (cd, &from, &from_len, &trans, &utf8_len) == -1 || from_len != 0) +- exit (1); +- if (memcmp (utf8, transbuf, utf8_real_len) != 0) +- exit (1); +- +- exit (0); +-}], ac_cv_libiconv_utf8=yes, [ac_cv_libiconv_utf8=no; have_iconv=no], [ac_cv_libiconv_utf8=no; have_iconv=no])) + fi + + if test "$have_iconv" = no; then +@@ -254,25 +221,6 @@ + AC_SUBST(ICONV_CFLAGS) + AC_SUBST(ICONV_LIBS) + +-CFLAGS="$CFLAGS -I$srcdir" +- +-AC_MSG_CHECKING(preferred charset formats for system iconv) +-AC_TRY_RUN([ +-#define CONFIGURE_IN +-#include "iconv-detect.c" +-],[ +- AC_MSG_RESULT(found) +-],[ +- AC_MSG_RESULT(not found) +- AC_WARN([ +- *** The iconv-detect program was unable to determine the +- *** preferred charset formats recognized by your system +- *** iconv library. It is suggested that you install a +- *** working iconv library such as the one found at +- *** ftp://ftp.gnu.org/pub/gnu/libiconv +- ]) +-]) +- + CFLAGS="$save_CFLAGS" + LIBS="$save_LIBS" + diff --git a/meta/packages/eds/eds-dbus/no_libdb.patch b/meta/packages/eds/eds-dbus/no_libdb.patch new file mode 100644 index 000000000..ae9a66dea --- /dev/null +++ b/meta/packages/eds/eds-dbus/no_libdb.patch @@ -0,0 +1,14 @@ +Index: configure.in +=================================================================== +--- trunk/configure.in (revision 306) ++++ trunk/configure.in (working copy) +@@ -1353,9 +1353,6 @@ + if test $enable_calendar = yes; then + AC_CONFIG_SUBDIRS(calendar/libical) + fi +-if test $dynamic_libdb = no; then +- AC_CONFIG_SUBDIRS(libdb/dist) +-fi + + AC_OUTPUT([ + Makefile diff --git a/meta/packages/eds/eds-dbus/no_libedataserverui.patch b/meta/packages/eds/eds-dbus/no_libedataserverui.patch new file mode 100644 index 000000000..bb6f78d9f --- /dev/null +++ b/meta/packages/eds/eds-dbus/no_libedataserverui.patch @@ -0,0 +1,13 @@ +Index: Makefile.am +=================================================================== +--- trunk/Makefile.am (revision 306) ++++ trunk/Makefile.am (working copy) +@@ -16,7 +16,7 @@ + endif + + if ENABLE_DBUS +-SUBDIRS = $(LIBDB) libedataserver $(CAMEL_DIR) addressbook $(CALENDAR_DIR) libedataserverui docs art po ++SUBDIRS = $(LIBDB) libedataserver $(CAMEL_DIR) addressbook $(CALENDAR_DIR) docs art po + else + SUBDIRS = $(LIBDB) libedataserver servers $(CAMEL_DIR) addressbook $(CALENDAR_DIR) libedataserverui src docs art po + endif diff --git a/meta/packages/eds/eds-dbus/no_libgnome.patch b/meta/packages/eds/eds-dbus/no_libgnome.patch new file mode 100644 index 000000000..a8bae50d0 --- /dev/null +++ b/meta/packages/eds/eds-dbus/no_libgnome.patch @@ -0,0 +1,45 @@ +Index: trunk/configure.in +=================================================================== +--- trunk.orig/configure.in 2005-09-28 20:01:02.000000000 +0000 ++++ trunk/configure.in 2005-09-28 21:02:35.000000000 +0000 +@@ -1120,7 +1120,12 @@ + AC_SUBST(E_DATA_SERVER_CFLAGS) + AC_SUBST(E_DATA_SERVER_LIBS) + +-E_DATA_SERVER_UI_DEPS="gtk+-2.0 libglade-2.0 gconf-2.0 libgnome-2.0" ++if test "x${with_libgnome}" != "xno"; then ++ E_DATA_SERVER_UI_DEPS="gtk+-2.0 libglade-2.0 gconf-2.0 libgnome-2.0" ++else ++ E_DATA_SERVER_UI_DEPS="gtk+-2.0 libglade-2.0 gconf-2.0" ++fi ++ + + EVO_SET_COMPILE_FLAGS(E_DATA_SERVER_UI, $E_DATA_SERVER_UI_DEPS, $THREADS_CFLAGS, $THREADS_LIBS) + AC_SUBST(E_DATA_SERVER_UI_CFLAGS) +@@ -1128,7 +1133,7 @@ + + dnl --- evolution-addressbook flags + +-EVOLUTION_ADDRESSBOOK_DEPS="libxml-2.0 gobject-2.0 gconf-2.0 $IPC_DEPS gnome-vfs-2.0 " ++EVOLUTION_ADDRESSBOOK_DEPS="libxml-2.0 gobject-2.0 gconf-2.0 $IPC_DEPS " + + EVO_SET_COMPILE_FLAGS(EVOLUTION_ADDRESSBOOK, $EVOLUTION_ADDRESSBOOK_DEPS) + AC_SUBST(EVOLUTION_ADDRESSBOOK_CFLAGS) +@@ -1136,7 +1141,7 @@ + + dnl --- evolution-calendar flags + +-EVOLUTION_CALENDAR_DEPS="libxml-2.0 gobject-2.0 gconf-2.0 gnome-vfs-2.0 dbus-glib-1" ++EVOLUTION_CALENDAR_DEPS="libxml-2.0 gobject-2.0 gconf-2.0 dbus-glib-1" + + EVO_SET_COMPILE_FLAGS(EVOLUTION_CALENDAR, $EVOLUTION_CALENDAR_DEPS) + AC_SUBST(EVOLUTION_CALENDAR_CFLAGS) +@@ -1145,7 +1150,7 @@ + if test "x${with_dbus}" = "xno"; then + dnl --- factory flags + +- E_FACTORY_DEPS="gobject-2.0 >= $GLIB_REQUIRED $IPC_DEPS gconf-2.0 gnome-vfs-2.0 libgnome-2.0 $mozilla_nspr" ++ E_FACTORY_DEPS="gobject-2.0 >= $GLIB_REQUIRED $IPC_DEPS gconf-2.0 $mozilla_nspr" + + EVO_SET_COMPILE_FLAGS(E_FACTORY, $E_FACTORY_DEPS, $THREADS_CFLAGS $MANUAL_NSPR_CFLAGS, $THREADS_LIBS $MANUAL_NSPR_LIBS) + AC_SUBST(E_FACTORY_CFLAGS) diff --git a/meta/packages/eds/eds-dbus_svn.bb b/meta/packages/eds/eds-dbus_svn.bb new file mode 100755 index 000000000..6a6162da8 --- /dev/null +++ b/meta/packages/eds/eds-dbus_svn.bb @@ -0,0 +1,40 @@ +LICENSE = "LGPL" +DEPENDS = "glib-2.0 gtk+ gconf dbus db gnome-common libglade virtual/libiconv" +MAINTAINER = "Chris Lord " +DESCRIPTION = "Evolution database backend server" +PV = "1.4.0+svn${SRCDATE}" +PR = "r19" + +SRC_URI = "svn://svn.o-hand.com/repos/${PN};module=trunk;proto=http \ + file://no_libdb.patch;patch=1 \ + file://no_iconv_test.patch;patch=1 \ + file://no_libedataserverui.patch;patch=1 \ + file://disable_orbit.patch;patch=1;maxdate=20060126 \ + file://fix_calendar.patch;patch=1;maxdate=20060619 \ + file://iconv-detect.h" + +S = "${WORKDIR}/trunk" + +inherit autotools pkgconfig + +EXTRA_OECONF = "--without-openldap --with-dbus --without-bug-buddy --without-soup --with-libdb=${STAGING_DIR}/${HOST_SYS} --disable-smime --disable-nss --disable-nntp --disable-gtk-doc" + +acpaths = " -I ${STAGING_DATADIR}/aclocal/gnome-macros " + +FILES_${PN} += "${libdir}/evolution-data-server-1.2/extensions/*.so \ + ${libdir}/evolution-data-server-1.2/camel-providers/*.so \ + ${libdir}/evolution-data-server-1.2/camel-providers/*.urls \ + ${datadir}/evolution-data-server-1.4/zoneinfo/zones.tab \ + ${datadir}/evolution-data-server-1.4/zoneinfo/*/*.ics \ + ${datadir}/evolution-data-server-1.4/zoneinfo/*/*/*.ics \ + ${datadir}/dbus-1/services/*.service" +FILES_${PN}-dev += "${libdir}/evolution-data-server-1.2/extensions/*.la \ + ${libdir}/evolution-data-server-1.2/camel-providers/*.la" + + +do_configure_append = " cp ${WORKDIR}/iconv-detect.h ${S} " + +do_stage () { + autotools_stage_all +} + diff --git a/meta/packages/expat/expat-1.95.7/autotools.patch b/meta/packages/expat/expat-1.95.7/autotools.patch new file mode 100644 index 000000000..f22b2401c --- /dev/null +++ b/meta/packages/expat/expat-1.95.7/autotools.patch @@ -0,0 +1,13 @@ +--- expat-1.95.7/configure.in~autotools 2004-05-13 22:46:28.000000000 -0400 ++++ expat-1.95.7/configure.in 2004-05-13 22:46:39.000000000 -0400 +@@ -50,9 +50,7 @@ + + AC_CONFIG_HEADER(expat_config.h) + +-sinclude(conftools/libtool.m4) +-sinclude(conftools/ac_c_bigendian_cross.m4) +- ++ + AC_LIBTOOL_WIN32_DLL + AC_PROG_LIBTOOL + diff --git a/meta/packages/expat/expat-native_1.95.7.bb b/meta/packages/expat/expat-native_1.95.7.bb new file mode 100644 index 000000000..2c40ba848 --- /dev/null +++ b/meta/packages/expat/expat-native_1.95.7.bb @@ -0,0 +1,4 @@ +SECTION = "libs" +include expat_${PV}.bb +inherit native +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/expat-${PV}" diff --git a/meta/packages/expat/expat_1.95.7.bb b/meta/packages/expat/expat_1.95.7.bb new file mode 100644 index 000000000..c3bbb8981 --- /dev/null +++ b/meta/packages/expat/expat_1.95.7.bb @@ -0,0 +1,30 @@ +SECTION = "libs" +DESCRIPTION = "Jim Clarkes XML parser library." +HOMEPAGE = "http://expat.sourceforge.net/" +LICENSE = "MIT" +PR = "r1" + +SRC_URI = "${SOURCEFORGE_MIRROR}/expat/expat-${PV}.tar.gz \ + file://autotools.patch;patch=1" +S = "${WORKDIR}/expat-${PV}" + +inherit autotools lib_package +export LTCC = "${CC}" + +do_configure () { + rm -f ${S}/conftools/libtool.m4 + autotools_do_configure +} + +do_stage () { + install -m 0644 ${S}/lib/expat.h ${STAGING_INCDIR}/ + oe_libinstall -so libexpat ${STAGING_LIBDIR} +} + +do_install () { + oe_runmake prefix="${D}${prefix}" \ + bindir="${D}${bindir}" \ + libdir="${D}${libdir}" \ + includedir="${D}${includedir}" \ + install +} diff --git a/meta/packages/fakeroot/fakeroot-native_1.2.13.bb b/meta/packages/fakeroot/fakeroot-native_1.2.13.bb new file mode 100644 index 000000000..cc3dfd223 --- /dev/null +++ b/meta/packages/fakeroot/fakeroot-native_1.2.13.bb @@ -0,0 +1,19 @@ +SECTION = "base" +PR = "r0" +include fakeroot_${PV}.bb +inherit native + +SRC_URI += "file://fix-prefix.patch;patch=1" +S = "${WORKDIR}/fakeroot-${PV}" + +EXTRA_OECONF = " --program-prefix=" + +# Compatability for the rare systems not using or having SYSV +python () { + if bb.data.getVar('HOST_NONSYSV', d, True) and bb.data.getVar('HOST_NONSYSV', d, True) != '0': + bb.data.setVar('EXTRA_OECONF', ' --with-ipc=tcp --program-prefix= ', d) +} + +do_stage_append () { + oe_libinstall -so libfakeroot ${STAGING_LIBDIR}/libfakeroot/ +} diff --git a/meta/packages/fakeroot/fakeroot_1.2.13.bb b/meta/packages/fakeroot/fakeroot_1.2.13.bb new file mode 100644 index 000000000..8ae7ca38b --- /dev/null +++ b/meta/packages/fakeroot/fakeroot_1.2.13.bb @@ -0,0 +1,8 @@ +DESCRIPTION = "Gives a fake root environment" +SECTION = "base" +HOMEPAGE = "http://joostje.op.het.net/fakeroot/index.html" +LICENSE = "GPL" + +SRC_URI = "http://openzaurus.org/mirror/fakeroot_${PV}.tar.gz" + +inherit autotools diff --git a/meta/packages/fakeroot/files/fix-prefix.patch b/meta/packages/fakeroot/files/fix-prefix.patch new file mode 100644 index 000000000..3884aca01 --- /dev/null +++ b/meta/packages/fakeroot/files/fix-prefix.patch @@ -0,0 +1,18 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- fakeroot-1.2.13/scripts/fakeroot.in~fix-prefix ++++ fakeroot-1.2.13/scripts/fakeroot.in +@@ -15,8 +15,8 @@ + } + + # strip /bin/fakeroot to find install prefix +-PREFIX=@prefix@ +-BINDIR=@bindir@ ++BINDIR=`dirname $0` ++PREFIX=`dirname ${BINDIR}` + + LIB=lib@fakeroot_transformed@.so.0 + PATHS=@libdir@:${PREFIX}/lib64/libfakeroot:${PREFIX}/lib32/libfakeroot diff --git a/meta/packages/file/file-native_4.16.bb b/meta/packages/file/file-native_4.16.bb new file mode 100644 index 000000000..3228ed683 --- /dev/null +++ b/meta/packages/file/file-native_4.16.bb @@ -0,0 +1,8 @@ +include file_${PV}.bb +inherit native + +# avoid dependency loop +DEPENDS = "" +PR = "r1" + +SRC_URI += "file://native-fix.diff;patch=1" diff --git a/meta/packages/file/file_4.16.bb b/meta/packages/file/file_4.16.bb new file mode 100644 index 000000000..3e579c5ef --- /dev/null +++ b/meta/packages/file/file_4.16.bb @@ -0,0 +1,18 @@ +DESCRIPTION = "File attempts to classify files depending \ +on their contents and prints a description if a match is found." +SECTION = "console/utils" +LICENSE = "BSD-ADV" +DEPENDS = "file-native" + +SRC_URI = "ftp://ftp.astron.com/pub/file/file-${PV}.tar.gz" +S = "${WORKDIR}/file-${PV}" + +inherit autotools + +do_configure_prepend() { + sed -i -e 's,$(top_builddir)/src/file,file,' ${S}/magic/Makefile.am +} + +do_stage() { + autotools_stage_all +} diff --git a/meta/packages/file/files/native-fix.diff b/meta/packages/file/files/native-fix.diff new file mode 100644 index 000000000..d17215a1b --- /dev/null +++ b/meta/packages/file/files/native-fix.diff @@ -0,0 +1,13 @@ +Index: file-4.16/magic/Makefile.am +=================================================================== +--- file-4.16.orig/magic/Makefile.am 2005-08-18 17:20:49.000000000 +0200 ++++ file-4.16/magic/Makefile.am 2006-03-08 17:01:13.000000000 +0100 +@@ -18,7 +18,7 @@ + if IS_CROSS_COMPILE + FILE_COMPILE = file + else +-FILE_COMPILE = $(top_builddir)/src/file ++FILE_COMPILE = ../src/file + endif + + magic.mgc: magic diff --git a/meta/packages/fixesext/fixesext_cvs.bb b/meta/packages/fixesext/fixesext_cvs.bb new file mode 100644 index 000000000..30b946013 --- /dev/null +++ b/meta/packages/fixesext/fixesext_cvs.bb @@ -0,0 +1,20 @@ +PV = "0.0+cvs${SRCDATE}" +LICENSE= "BSD-X" +SECTION = "libs" +MAINTAINER = "Greg Gilbert " +DEPENDS = "xextensions" +DESCRIPTION = "X Fixes extension headers and specification." +DEFAULT_PREFERENCE = "1" + +SRC_URI = "${FREEDESKTOP_CVS}/xlibs;module=FixesExt" +S = "${WORKDIR}/FixesExt" + +inherit autotools pkgconfig + +do_stage() { + oe_runmake install prefix=${STAGING_DIR} \ + bindir=${STAGING_BINDIR} \ + includedir=${STAGING_INCDIR} \ + libdir=${STAGING_LIBDIR} \ + datadir=${STAGING_DATADIR} +} diff --git a/meta/packages/flex/files/fix-gen.patch b/meta/packages/flex/files/fix-gen.patch new file mode 100644 index 000000000..55f4f6fdf --- /dev/null +++ b/meta/packages/flex/files/fix-gen.patch @@ -0,0 +1,17 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- flex-2.5.31/gen.c~fix-gen ++++ flex-2.5.31/gen.c +@@ -1812,8 +1812,7 @@ + if (yytext_is_array) { + if (!reentrant){ + indent_puts ("static int yy_more_offset = 0;"); +- }else{ +- indent_puts ("static int yy_prev_more_offset = 0;"); ++ indent_puts ("static int yy_prev_more_offset = 0;"); + } + } + else if (!reentrant) { diff --git a/meta/packages/flex/files/flex-lvalue.diff b/meta/packages/flex/files/flex-lvalue.diff new file mode 100644 index 000000000..56ae539a6 --- /dev/null +++ b/meta/packages/flex/files/flex-lvalue.diff @@ -0,0 +1,36 @@ +Patch from http://bugs.debian.org/cgi-bin/bugreport.cgi/flex-lvalue.diff?bug=194844;msg=10;att=1 + +according to posix 0,1,2 are already setup and this avoids +the issues with +| filter.c: In function 'filter_apply_chain': +| filter.c:161: error: invalid lvalue in assignment +| filter.c:163: error: invalid lvalue in assignment +| filter.c:184: error: invalid lvalue in assignment + + +diff -ur flex-2.5.31.ORIG/filter.c flex-2.5.31/filter.c +--- flex-2.5.31.ORIG/filter.c 2003-03-25 16:39:08.000000000 +0000 ++++ flex-2.5.31/filter.c 2003-05-27 17:00:26.000000000 +0000 +@@ -157,11 +157,8 @@ + if (chain->filter_func) { + int r; + +- /* setup streams again */ +- if ((stdin = fdopen (0, "r")) == NULL) +- flexfatal (_("fdopen(0) failed")); +- if ((stdout = fdopen (1, "w")) == NULL) +- flexfatal (_("fdopen(1) failed")); ++ /* POSIX says we inherit fd[0-2], so we don't need ++ to do anything to them here */ + + if ((r = chain->filter_func (chain)) == -1) + flexfatal (_("filter_func failed")); +@@ -181,8 +178,6 @@ + if (dup2 (pipes[1], 1) == -1) + flexfatal (_("dup2(pipes[1],1)")); + close (pipes[1]); +- if ((stdout = fdopen (1, "w")) == NULL) +- flexfatal (_("fdopen(1) failed")); + + return true; + } diff --git a/meta/packages/flex/flex-2.5.31/include.patch b/meta/packages/flex/flex-2.5.31/include.patch new file mode 100644 index 000000000..b60dcb29d --- /dev/null +++ b/meta/packages/flex/flex-2.5.31/include.patch @@ -0,0 +1,27 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- flex-2.5.31/Makefile.am~include ++++ flex-2.5.31/Makefile.am +@@ -141,7 +141,7 @@ + tests + + localedir = $(datadir)/locale +-AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\" -I@includedir@ -I$(top_srcdir)/intl ++AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\" -I$(top_srcdir)/intl + LIBS = @LIBINTL@ @LIBS@ + + skel.c: flex.skl mkskel.sh flexint.h tables_shared.h +--- flex-2.5.31/Makefile.in~include ++++ flex-2.5.31/Makefile.in +@@ -292,7 +292,7 @@ + + + localedir = $(datadir)/locale +-AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\" -I@includedir@ -I$(top_srcdir)/intl ++AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\" -I$(top_srcdir)/intl + + # Run GNU indent on sources. Don't run this unless all the sources compile cleanly. + # diff --git a/meta/packages/flex/flex-native_2.5.31.bb b/meta/packages/flex/flex-native_2.5.31.bb new file mode 100644 index 000000000..ff8a42772 --- /dev/null +++ b/meta/packages/flex/flex-native_2.5.31.bb @@ -0,0 +1,10 @@ +include flex.inc +inherit native +PR = "r2" + +do_stage () { + install -m 0755 flex ${STAGING_BINDIR} + oe_libinstall -a libfl ${STAGING_LIBDIR} + ln -sf ./flex ${STAGING_BINDIR}/flex++ + ln -sf ./flex ${STAGING_BINDIR}/lex +} diff --git a/meta/packages/flex/flex.inc b/meta/packages/flex/flex.inc new file mode 100644 index 000000000..d6affad22 --- /dev/null +++ b/meta/packages/flex/flex.inc @@ -0,0 +1,11 @@ +DESCRIPTION = "Flex is a tool for generating programs that recognize lexical patterns in text." +SECTION = "devel" +LICENSE = "BSD" + +SRC_URI = "${SOURCEFORGE_MIRROR}/lex/flex-2.5.31.tar.bz2 \ + file://flex-lvalue.diff;patch=1 \ + file://fix-gen.patch;patch=1" +S = "${WORKDIR}/flex-${PV}" + +inherit autotools + diff --git a/meta/packages/flex/flex_2.5.31.bb b/meta/packages/flex/flex_2.5.31.bb new file mode 100644 index 000000000..b96c64513 --- /dev/null +++ b/meta/packages/flex/flex_2.5.31.bb @@ -0,0 +1,9 @@ +include flex.inc +PR = "r4" + +SRC_URI += "file://include.patch;patch=1" + +do_stage() { + oe_libinstall -a libfl ${STAGING_LIBDIR} +} + diff --git a/meta/packages/fontconfig/files/local.conf b/meta/packages/fontconfig/files/local.conf new file mode 100644 index 000000000..ddd7cf9d0 --- /dev/null +++ b/meta/packages/fontconfig/files/local.conf @@ -0,0 +1,12 @@ + + + + + + + + unknown + + rgb + + diff --git a/meta/packages/fontconfig/files/stop-fc-cache.patch b/meta/packages/fontconfig/files/stop-fc-cache.patch new file mode 100644 index 000000000..7b549118f --- /dev/null +++ b/meta/packages/fontconfig/files/stop-fc-cache.patch @@ -0,0 +1,8 @@ +--- fontconfig-2.2.95/Makefile.am.old 2006-02-07 01:01:01.000000000 +0000 ++++ fontconfig-2.2.95/Makefile.am 2006-02-07 01:01:15.000000000 +0000 +@@ -50,4 +50,4 @@ + echo " $(INSTALL_DATA) local.conf $(DESTDIR)$(configdir)/local.conf"; \ + $(INSTALL_DATA) local.conf $(DESTDIR)$(configdir)/local.conf; \ + fi; fi; fi +- if [ x$(DESTDIR) = x ]; then fc-cache/fc-cache -f -v; fi ++# if [ x$(DESTDIR) = x ]; then fc-cache/fc-cache -f -v; fi diff --git a/meta/packages/fontconfig/fontconfig-2.2.95/fc-glyphname.patch b/meta/packages/fontconfig/fontconfig-2.2.95/fc-glyphname.patch new file mode 100644 index 000000000..1afd9324f --- /dev/null +++ b/meta/packages/fontconfig/fontconfig-2.2.95/fc-glyphname.patch @@ -0,0 +1,19 @@ +--- fontconfig/fc-glyphname/Makefile.am~ 2004-04-14 17:06:35.000000000 +0100 ++++ fontconfig/fc-glyphname/Makefile.am 2004-05-15 11:41:35.000000000 +0100 +@@ -27,6 +27,7 @@ + TMPL=fcglyphname.tmpl.h + STMPL=${top_srcdir}/fc-glyphname/${TMPL} + TARG=fcglyphname.h ++FC_GLYPHNAME=./fc-glyphname + + noinst_PROGRAMS=fc-glyphname + +@@ -41,7 +42,7 @@ + + $(TARG): $(STMPL) fc-glyphname $(SGLYPHNAME) + rm -f $(TARG) +- ./fc-glyphname $(SGLYPHNAME) < $(STMPL) > $(TARG) ++ $(FC_GLYPHNAME) $(SGLYPHNAME) < $(STMPL) > $(TARG) + + CLEANFILES=$(TARG) + diff --git a/meta/packages/fontconfig/fontconfig-2.2.95/fc-lang.patch b/meta/packages/fontconfig/fontconfig-2.2.95/fc-lang.patch new file mode 100644 index 000000000..d08242a37 --- /dev/null +++ b/meta/packages/fontconfig/fontconfig-2.2.95/fc-lang.patch @@ -0,0 +1,18 @@ +--- fontconfig/fc-lang/Makefile.am~ 2004-04-14 17:06:36.000000000 +0100 ++++ fontconfig/fc-lang/Makefile.am 2004-05-15 11:22:44.000000000 +0100 +@@ -27,6 +27,7 @@ + TMPL=fclang.tmpl.h + STMPL=${top_srcdir}/fc-lang/fclang.tmpl.h + TARG=fclang.h ++FC_LANG=./fc-lang + + noinst_PROGRAMS=fc-lang + +@@ -40,6 +41,6 @@ + + $(TARG):$(ORTH) fc-lang $(STMPL) + rm -f $(TARG) +- ./fc-lang -d ${srcdir} $(ORTH) < $(STMPL) > $(TARG) ++ $(FC_LANG) -d ${srcdir} $(ORTH) < $(STMPL) > $(TARG) + + CLEANFILES=$(TARG) diff --git a/meta/packages/fontconfig/fontconfig-native_2.2.95.bb b/meta/packages/fontconfig/fontconfig-native_2.2.95.bb new file mode 100644 index 000000000..6872db92f --- /dev/null +++ b/meta/packages/fontconfig/fontconfig-native_2.2.95.bb @@ -0,0 +1,15 @@ +SECTION = "base" +LICENSE = "BSD" +include fontconfig_${PV}.bb +inherit native +DEPENDS = "freetype-native expat-native zlib-native" +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/fontconfig-${PV}" +SRC_URI += " file://stop-fc-cache.patch;patch=1" + +EXTRA_OEMAKE = "" + +do_stage () { + oe_runmake install + install fc-lang/fc-lang ${STAGING_BINDIR} + install fc-glyphname/fc-glyphname ${STAGING_BINDIR} +} diff --git a/meta/packages/fontconfig/fontconfig_2.2.95.bb b/meta/packages/fontconfig/fontconfig_2.2.95.bb new file mode 100644 index 000000000..78b35b179 --- /dev/null +++ b/meta/packages/fontconfig/fontconfig_2.2.95.bb @@ -0,0 +1,36 @@ +SECTION = "libs" +LICENSE = "BSD" +DESCRIPTION = "A library for configuring and customizing font access." +DEPENDS = "expat freetype freetype-native zlib fontconfig-native" + +SRC_URI = "http://pdx.freedesktop.org/fontconfig/release/fontconfig-${PV}.tar.gz \ + file://fc-glyphname.patch;patch=1 \ + file://fc-lang.patch;patch=1 \ + file://local.conf" +PR = "r2" + +PACKAGES =+ "fontconfig-utils " +FILES_fontconfig-utils = "${bindir}/*" + +PKG_fontconfig-utils=fontconfig-utils + +S = "${WORKDIR}/fontconfig-${PV}" + +inherit autotools pkgconfig + +export HASDOCBOOK="no" + +EXTRA_OECONF = " --disable-docs " +EXTRA_OEMAKE = "FC_LANG=fc-lang FC_GLYPHNAME=fc-glyphname" + +do_stage () { + oe_libinstall -so -a -C src libfontconfig ${STAGING_LIBDIR} + install -d ${STAGING_INCDIR}/fontconfig + for i in ${S}/fontconfig/*.h; do install -m 0644 $i ${STAGING_INCDIR}/fontconfig/; done +} + +do_install () { + autotools_do_install + install -m 0644 ${WORKDIR}/local.conf ${D}${sysconfdir}/fonts/local.conf +} + diff --git a/meta/packages/freetype/files/configure.patch b/meta/packages/freetype/files/configure.patch new file mode 100644 index 000000000..f11cf96be --- /dev/null +++ b/meta/packages/freetype/files/configure.patch @@ -0,0 +1,47 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +Index: freetype-2.1.8/builds/unix/configure.ac +=================================================================== +--- freetype-2.1.8.orig/builds/unix/configure.ac 2004-04-14 04:49:11.000000000 -0400 ++++ freetype-2.1.8/builds/unix/configure.ac 2005-03-12 03:14:23.000000000 -0500 +@@ -111,8 +111,8 @@ + # Check for system zlib + + AC_ARG_WITH([zlib], +- dnl don't quote AS_HELP_STRING! +- AS_HELP_STRING([--without-zlib], ++ dnl don't quote AC_HELP_STRING! ++ AC_HELP_STRING([--without-zlib], + [use internal zlib instead of system-wide])) + if test x$with_zlib != xno && test -z "$LIBZ"; then + AC_CHECK_LIB([z], [gzsetparams], [AC_CHECK_HEADER([zlib.h], [LIBZ='-lz'])]) +@@ -127,7 +127,7 @@ + # Whether to use Mac OS resource-based fonts or not + + AC_ARG_WITH([old-mac-fonts], +- dnl don't quote AS_HELP_STRING! +- AS_HELP_STRING([--with-old-mac-fonts], ++ dnl don't quote AC_HELP_STRING! ++ AC_HELP_STRING([--with-old-mac-fonts], + [allow Mac resource-based fonts to be used])) + if test x$with_old_mac_fonts = xyes; then +Index: freetype-2.1.8/builds/unix/unix-cc.in +=================================================================== +--- freetype-2.1.8.orig/builds/unix/unix-cc.in 2003-11-09 03:37:13.000000000 -0500 ++++ freetype-2.1.8/builds/unix/unix-cc.in 2005-03-12 18:37:24.613693760 -0500 +@@ -14,9 +14,11 @@ + + CC := @CC@ + COMPILER_SEP := $(SEP) ++SHELL := @SHELL@ ++top_builddir := $(BUILD_DIR) + + ifndef LIBTOOL +- LIBTOOL := $(BUILD_DIR)/libtool ++ LIBTOOL := @LIBTOOL@ + endif + + diff --git a/meta/packages/freetype/files/no-hardcode.patch b/meta/packages/freetype/files/no-hardcode.patch new file mode 100644 index 000000000..44ae450a1 --- /dev/null +++ b/meta/packages/freetype/files/no-hardcode.patch @@ -0,0 +1,11 @@ +--- freetype-2.1.10/builds/unix/freetype-config.in.old 2006-05-01 12:39:20.000000000 +0100 ++++ freetype-2.1.10/builds/unix/freetype-config.in 2006-05-01 12:39:34.000000000 +0100 +@@ -16,7 +16,7 @@ + libdir=@libdir@ + enable_shared=@enable_shared@ + wl=@wl@ +-hardcode_libdir_flag_spec='@hardcode_libdir_flag_spec@' ++hardcode_libdir_flag_spec='' + + usage() + { diff --git a/meta/packages/freetype/freetype-native_2.1.10.bb b/meta/packages/freetype/freetype-native_2.1.10.bb new file mode 100644 index 000000000..64fac71cb --- /dev/null +++ b/meta/packages/freetype/freetype-native_2.1.10.bb @@ -0,0 +1,21 @@ +include freetype_${PV}.bb +inherit native +DEPENDS = "" +FILESPATH = "${FILE_DIRNAME}/freetype-${PV}:${FILE_DIRNAME}/freetype:${FILE_DIRNAME}/files" + +EXTRA_OEMAKE= + +do_configure() { + (cd builds/unix && gnu-configize) || die "failure running gnu-configize" + oe_runconf +} + +do_stage() { + autotools_stage_includes + oe_libinstall -so -a -C objs libfreetype ${STAGING_LIBDIR} +} + +do_install() { + : +} + diff --git a/meta/packages/freetype/freetype_2.1.10.bb b/meta/packages/freetype/freetype_2.1.10.bb new file mode 100644 index 000000000..35c0d0cbd --- /dev/null +++ b/meta/packages/freetype/freetype_2.1.10.bb @@ -0,0 +1,32 @@ +DESCRIPTION = "Freetype font rendering library" +HOMEPAGE = "http://www.freetype.org" +SECTION = "libs" +LICENSE = "freetype" +PR = "r1" + +SRC_URI = "${SOURCEFORGE_MIRROR}/freetype/freetype-${PV}.tar.bz2 \ + file://configure.patch;patch=1 \ + file://no-hardcode.patch;patch=1" +S = "${WORKDIR}/freetype-${PV}" + +inherit autotools pkgconfig binconfig + +LIBTOOL = "${S}/builds/unix/${HOST_SYS}-libtool" +EXTRA_OEMAKE = "'LIBTOOL=${LIBTOOL}'" + +do_configure() { + cd builds/unix + gnu-configize + aclocal -I . + autoconf + cd ${S} + oe_runconf +} + +do_stage() { + autotools_stage_includes + oe_libinstall -so -a -C objs libfreetype ${STAGING_LIBDIR} +} + +FILES_${PN} = "${libdir}/lib*.so.*" +FILES_${PN}-dev += "${bindir}" diff --git a/meta/packages/galago/eds-feed/disable-bonobo.patch b/meta/packages/galago/eds-feed/disable-bonobo.patch new file mode 100644 index 000000000..3a2097877 --- /dev/null +++ b/meta/packages/galago/eds-feed/disable-bonobo.patch @@ -0,0 +1,62 @@ +Index: eds-feed-0.3.2/configure.ac +=================================================================== +--- eds-feed-0.3.2.orig/configure.ac 2005-08-28 19:11:39.000000000 +0000 ++++ eds-feed-0.3.2/configure.ac 2005-12-16 09:22:10.000000000 +0000 +@@ -65,7 +65,7 @@ + libxml-2.0) + + # Check which version of eds we're using +-PKG_CHECK_MODULES(EDS, libebook-1.2 >= 1.1.4 libedata-book-1.2 >= 1.1.4) ++PKG_CHECK_MODULES(EDS, libebook-1.2 >= 1.1.4) + + PACKAGE_CFLAGS="$PACKAGE_CFLAGS $EDS_CFLAGS" + PACKAGE_LIBS="$PACKAGE_LIBS $EDS_LIBS" +Index: eds-feed-0.3.2/src/main.c +=================================================================== +--- eds-feed-0.3.2.orig/src/main.c 2005-08-21 07:26:02.000000000 +0000 ++++ eds-feed-0.3.2/src/main.c 2005-12-16 09:24:38.000000000 +0000 +@@ -20,17 +20,11 @@ + */ + #include + #include +-#include + + #include +-#include +-#include + + #include + +-#define E_DATA_BOOK_FACTORY_OAF_ID \ +- "OAFIID:GNOME_Evolution_DataServer_BookFactory" +- + static EBookView *book_view = NULL; + static EBook *book = NULL; + static gulong book_view_tag = 0; +@@ -157,8 +151,8 @@ + galago_person_set_photo(person, NULL); + else + { +- galago_photo_new(person, (unsigned char *)ephoto->data, +- ephoto->length); ++// galago_photo_new(person, (unsigned char *)ephoto->data, ++// ephoto->length); + } + } + +@@ -294,15 +288,6 @@ + + galago_core_set_exit_with_daemon(TRUE); + +- if (!bonobo_init_full(NULL, NULL, bonobo_activation_orb_get(), +- CORBA_OBJECT_NIL, CORBA_OBJECT_NIL)) +- { +- fprintf(stderr, "Unable to initialize bonobo.\n"); +- exit(1); +- } +- +- bonobo_activate(); +- + setup_book_view(); + setup_services(); + diff --git a/meta/packages/galago/eds-feed_0.3.2.bb b/meta/packages/galago/eds-feed_0.3.2.bb new file mode 100644 index 000000000..5ad9a822a --- /dev/null +++ b/meta/packages/galago/eds-feed_0.3.2.bb @@ -0,0 +1,14 @@ +DESCRIPTION = "Galago linkage to the Evolution Data Server." +HOMEPAGE = "http://www.galago-project.org/" +LICENSE = "GPL" +DEPENDS = "gettext libgalago dbus glib-2.0 eds-dbus" + +SRC_URI = "http://www.galago-project.org/files/releases/source/${PN}/${P}.tar.gz \ + file://disable-bonobo.patch;patch=1" +# file://no-check.patch;patch=1" +#EXTRA_OECONF = "--disable-binreloc" + +FILES_${PN} += "${libdir}/galago/eds-feed" + +inherit autotools pkgconfig + diff --git a/meta/packages/galago/files/no-check.patch b/meta/packages/galago/files/no-check.patch new file mode 100644 index 000000000..89b0eafac --- /dev/null +++ b/meta/packages/galago/files/no-check.patch @@ -0,0 +1,15 @@ +--- /tmp/configure.ac 2005-09-08 21:38:49.316449440 +0200 ++++ libgalago-0.3.3/configure.ac 2005-09-08 21:39:32.697854464 +0200 +@@ -198,11 +198,8 @@ + dnl # + dnl # Check for Check + dnl # +-AM_PATH_CHECK(, [have_check="yes"], +-[ +- AC_MSG_WARN([Check not found; cannot run some unit tests]) + have_check="no" +-]) ++ + + AM_CONDITIONAL(HAVE_CHECK, test "$have_check" = "yes") + diff --git a/meta/packages/galago/galago-daemon_0.3.4.bb b/meta/packages/galago/galago-daemon_0.3.4.bb new file mode 100644 index 000000000..22257b6f4 --- /dev/null +++ b/meta/packages/galago/galago-daemon_0.3.4.bb @@ -0,0 +1,15 @@ +DESCRIPTION = "Galago is a desktop presence framework, designed to transmit presence information between programs." +HOMEPAGE = "http://www.galago-project.org/" +MAINTAINER = "Koen Kooi " +LICENSE = "GPL" +DEPENDS = "gettext libgalago dbus glib-2.0" +PR = "r1" + +SRC_URI = "http://www.galago-project.org/files/releases/source/${PN}/${P}.tar.gz \ + file://no-check.patch;patch=1" +EXTRA_OECONF = "--disable-binreloc" + +FILES_${PN} += "${datadir}/dbus-1/services/" + +inherit autotools pkgconfig + diff --git a/meta/packages/galago/libgalago_0.3.3.bb b/meta/packages/galago/libgalago_0.3.3.bb new file mode 100644 index 000000000..85f409780 --- /dev/null +++ b/meta/packages/galago/libgalago_0.3.3.bb @@ -0,0 +1,18 @@ +DESCRIPTION = "Galago is a desktop presence framework, designed to transmit presence information between programs." +HOMEPAGE = "http://www.galago-project.org/" +MAINTAINER = "Koen Kooi " +LICENSE = "LGPL" +DEPENDS = "gettext dbus glib-2.0" +PR = "r1" + + +SRC_URI = "http://www.galago-project.org/files/releases/source/${PN}/${P}.tar.gz \ + file://no-check.patch;patch=1" + +inherit autotools pkgconfig + +do_stage() { + autotools_stage_includes + install -d ${STAGING_LIBDIR} + install -m 755 libgalago/.libs/libgalago.so.1.0.0 ${STAGING_LIBDIR}/libgalago.so +} diff --git a/meta/packages/gcalctool/gcalctool/makefile-fix.diff b/meta/packages/gcalctool/gcalctool/makefile-fix.diff new file mode 100644 index 000000000..48a546271 --- /dev/null +++ b/meta/packages/gcalctool/gcalctool/makefile-fix.diff @@ -0,0 +1,18 @@ +--- gcalctool/Makefile.am~ 2005-03-23 16:50:10.000000000 +0000 ++++ gcalctool/Makefile.am 2006-03-20 13:59:17.000000000 +0000 +@@ -30,15 +30,8 @@ + + SCHEMAS_FILE = gcalctool.schemas + +-### Install the schemas file in /etc if GNOME support is not compiled in, +-### and do not install the schemas at all +-if DISABLE_GNOME +-schemasdir = $(sysconfdir)/gcalctool +-schemas_DATA = $(SCHEMAS_FILE) +-else + schemadir = $(GCONF_SCHEMA_FILE_DIR) + schema_DATA = $(SCHEMAS_FILE) +-endif + + EXTRA_DIST = \ + autogen.sh \ diff --git a/meta/packages/gcalctool/gcalctool_5.7.32.bb b/meta/packages/gcalctool/gcalctool_5.7.32.bb new file mode 100644 index 000000000..cb416235a --- /dev/null +++ b/meta/packages/gcalctool/gcalctool_5.7.32.bb @@ -0,0 +1,13 @@ +LICENSE = "GPL" +SECTION = "x11" +DEPENDS = "gtk+" +MAINTAINER = "Ross Burton " +DESCRIPTION = "gcalctool is a powerful calculator +PR = "r1" + +SRC_URI = "http://download.gnome.org/sources/${PN}/5.7/${PN}-${PV}.tar.gz \ + file://makefile-fix.diff;patch=1" + +inherit autotools pkgconfig + +EXTRA_OECONF = "--disable-gnome" diff --git a/meta/packages/gcc/gcc-3.3.4/arm-gotoff.dpatch b/meta/packages/gcc/gcc-3.3.4/arm-gotoff.dpatch new file mode 100644 index 000000000..610f9430e --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/arm-gotoff.dpatch @@ -0,0 +1,135 @@ +#! /bin/sh -e + +src=gcc +if [ $# -eq 3 -a "$2" = '-d' ]; then + pdir="-d $3" + src=$3/gcc +elif [ $# -ne 1 ]; then + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1 +fi +case "$1" in + -patch) + patch $pdir -f --no-backup-if-mismatch -p0 --fuzz 10 < $0 + ;; + -unpatch) + patch $pdir -f --no-backup-if-mismatch -R -p0 --fuzz 10 < $0 + ;; + *) + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1 +esac +exit 0 + +# DP: use GOTOFF not GOT relocs for .LCn and other local symbols; +# DP: don't use gotoff for non-static functions, even if defined locally + +--- gcc/config/arm/arm.c 2003-06-14 15:20:53.000000000 +0100 ++++ gcc/config/arm/arm.c 2004-03-06 15:15:32.000000000 +0000 +@@ -2364,6 +2394,40 @@ + return 1; + } + ++/* Return true if OP is a symbolic operand that resolves locally. */ ++ ++static int ++local_symbolic_operand (op, mode) ++ rtx op; ++ enum machine_mode mode ATTRIBUTE_UNUSED; ++{ ++ if (GET_CODE (op) == CONST ++ && GET_CODE (XEXP (op, 0)) == PLUS ++ && GET_CODE (XEXP (XEXP (op, 0), 1)) == CONST_INT) ++ op = XEXP (XEXP (op, 0), 0); ++ ++ if (GET_CODE (op) == LABEL_REF) ++ return 1; ++ ++ if (GET_CODE (op) != SYMBOL_REF) ++ return 0; ++ ++ /* These we've been told are local by varasm and encode_section_info ++ respectively. */ ++ if (CONSTANT_POOL_ADDRESS_P (op) || ENCODED_LOCAL_BINDING_ATTR_P (XSTR (op, 0))) ++ return 1; ++ ++ /* There is, however, a not insubstantial body of code in the rest of ++ the compiler that assumes it can just stick the results of ++ ASM_GENERATE_INTERNAL_LABEL in a symbol_ref and have done. */ ++ /* ??? This is a hack. Should update the body of the compiler to ++ always create a DECL an invoke targetm.encode_section_info. */ ++ if (strncmp (arm_strip_name_encoding (XSTR (op, 0)), ".L", 2) == 0) ++ return 1; ++ ++ return 0; ++} ++ + rtx + legitimize_pic_address (orig, mode, reg) + rtx orig; +@@ -2404,10 +2468,7 @@ + else + emit_insn (gen_pic_load_addr_thumb (address, orig)); + +- if ((GET_CODE (orig) == LABEL_REF +- || (GET_CODE (orig) == SYMBOL_REF && +- ENCODED_SHORT_CALL_ATTR_P (XSTR (orig, 0)))) +- && NEED_GOT_RELOC) ++ if (local_symbolic_operand (orig, Pmode) && NEED_GOT_RELOC) + pic_ref = gen_rtx_PLUS (Pmode, pic_offset_table_rtx, address); + else + { +@@ -8804,11 +8911,7 @@ + if (NEED_GOT_RELOC && flag_pic && making_const_table && + (GET_CODE (x) == SYMBOL_REF || GET_CODE (x) == LABEL_REF)) + { +- if (GET_CODE (x) == SYMBOL_REF +- && (CONSTANT_POOL_ADDRESS_P (x) +- || ENCODED_SHORT_CALL_ATTR_P (XSTR (x, 0)))) +- fputs ("(GOTOFF)", asm_out_file); +- else if (GET_CODE (x) == LABEL_REF) ++ if (local_symbolic_operand (x, Pmode)) + fputs ("(GOTOFF)", asm_out_file); + else + fputs ("(GOT)", asm_out_file); +@@ -11335,6 +11418,11 @@ + else if (! TREE_PUBLIC (decl)) + arm_encode_call_attribute (decl, SHORT_CALL_FLAG_CHAR); + } ++ ++ if (TREE_CODE_CLASS (TREE_CODE (decl)) == 'd' ++ && flag_pic ++ && (*targetm.binds_local_p) (decl)) ++ arm_encode_call_attribute (decl, LOCAL_BINDING_FLAG_CHAR); + } + #endif /* !ARM_PE */ + + +--- gcc/config/arm/arm.h Fri Mar 5 18:49:44 2004 ++++ gcc/config/arm/arm.h Fri Mar 5 15:04:31 2004 +@@ -1870,6 +1870,7 @@ + Note, '@' and '*' have already been taken. */ + #define SHORT_CALL_FLAG_CHAR '^' + #define LONG_CALL_FLAG_CHAR '#' ++#define LOCAL_BINDING_FLAG_CHAR '%' + + #define ENCODED_SHORT_CALL_ATTR_P(SYMBOL_NAME) \ + (*(SYMBOL_NAME) == SHORT_CALL_FLAG_CHAR) +@@ -1877,6 +1878,9 @@ + #define ENCODED_LONG_CALL_ATTR_P(SYMBOL_NAME) \ + (*(SYMBOL_NAME) == LONG_CALL_FLAG_CHAR) + ++#define ENCODED_LOCAL_BINDING_ATTR_P(SYMBOL_NAME) \ ++ (*(SYMBOL_NAME) == LOCAL_BINDING_FLAG_CHAR) ++ + #ifndef SUBTARGET_NAME_ENCODING_LENGTHS + #define SUBTARGET_NAME_ENCODING_LENGTHS + #endif +@@ -1888,6 +1892,7 @@ + #define ARM_NAME_ENCODING_LENGTHS \ + case SHORT_CALL_FLAG_CHAR: return 1; \ + case LONG_CALL_FLAG_CHAR: return 1; \ ++ case LOCAL_BINDING_FLAG_CHAR: return 1; \ + case '*': return 1; \ + SUBTARGET_NAME_ENCODING_LENGTHS + diff --git a/meta/packages/gcc/gcc-3.3.4/arm-ldm-peephole.patch b/meta/packages/gcc/gcc-3.3.4/arm-ldm-peephole.patch new file mode 100644 index 000000000..83b07e034 --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/arm-ldm-peephole.patch @@ -0,0 +1,91 @@ +2004-03-19 Philip Blundell + + * config/arm/arm.c (adjacent_mem_locations): Reject location pairs + where both offsets are nonzero if target is Harvard architecture. + (load_multiple_sequence, store_multiple_sequence): Avoid two-word + LDM/STM on XScale unless -Os. + * config/arm/arm.md (arith_adjacentmem): Inhibit if tuning for + XScale and not -Os. + * genpeep.c: Have generated code include flags.h. + +--- gcc/genpeep.c~ 2001-12-02 00:04:19.000000000 +0000 ++++ gcc/genpeep.c 2004-03-19 11:17:18.000000000 +0000 +@@ -402,6 +402,7 @@ + printf ("#include \"recog.h\"\n"); + printf ("#include \"except.h\"\n\n"); + printf ("#include \"function.h\"\n\n"); ++ printf ("#include \"flags.h\"\n\n"); + + printf ("#ifdef HAVE_peephole\n"); + printf ("extern rtx peep_operand[];\n\n"); + +--- gcc/config/arm/arm.md~ 2004-03-11 15:28:01.000000000 +0000 ++++ gcc/config/arm/arm.md 2004-03-19 13:00:03.000000000 +0000 +@@ -7958,13 +7958,16 @@ + (set_attr "length" "4,8,8")] + ) + ++; Try to convert LDR+LDR+arith into [add+]LDM+arith ++; On XScale, LDM is always slower than two LDRs, so only do this if ++; optimising for size. + (define_insn "*arith_adjacentmem" + [(set (match_operand:SI 0 "s_register_operand" "=r") + (match_operator:SI 1 "shiftable_operator" + [(match_operand:SI 2 "memory_operand" "m") + (match_operand:SI 3 "memory_operand" "m")])) + (clobber (match_scratch:SI 4 "=r"))] +- "TARGET_ARM && adjacent_mem_locations (operands[2], operands[3])" ++ "TARGET_ARM && (!arm_tune_xscale || optimize_size) && adjacent_mem_locations (operands[2], operands[3])" + "* + { + rtx ldm[3]; +@@ -7999,7 +8002,9 @@ + } + if (val1 && val2) + { ++ /* This would be a loss on a Harvard core, but adjacent_mem_locations() ++ will prevent it from happening. */ + rtx ops[3]; + ldm[0] = ops[0] = operands[4]; + ops[1] = XEXP (XEXP (operands[2], 0), 0); + +--- gcc/config/arm/arm.c~ 2004-03-11 15:28:01.000000000 +0000 ++++ gcc/config/arm/arm.c 2004-03-19 15:36:03.000000000 +0000 +@@ -3818,8 +3818,11 @@ + sequence. */ + if (!const_ok_for_op (PLUS, val0) || !const_ok_for_op (PLUS, val1)) + return 0; +- +- return (reg0 == reg1) && ((val1 - val0) == 4 || (val0 - val1) == 4); ++ ++ /* For Harvard cores, only accept pairs where one offset is zero. ++ See comment in load_multiple_sequence. */ ++ return (reg0 == reg1) && ((val1 - val0) == 4 || (val0 - val1) == 4) ++ && (!arm_ld_sched || val0 == 0 || val1 == 0); + } + return 0; + } +@@ -4075,6 +4078,11 @@ + *load_offset = unsorted_offsets[order[0]]; + } + ++ /* For XScale a two-word LDM is a performance loss, so only do this if ++ size is more important. See comments in arm_gen_load_multiple. */ ++ if (nops == 2 && arm_tune_xscale && !optimize_size) ++ return 0; ++ + if (unsorted_offsets[order[0]] == 0) + return 1; /* ldmia */ + +@@ -4307,6 +4315,11 @@ + *load_offset = unsorted_offsets[order[0]]; + } + ++ /* For XScale a two-word LDM is a performance loss, so only do this if ++ size is more important. See comments in arm_gen_load_multiple. */ ++ if (nops == 2 && arm_tune_xscale && !optimize_size) ++ return 0; ++ + if (unsorted_offsets[order[0]] == 0) + return 1; /* stmia */ + diff --git a/meta/packages/gcc/gcc-3.3.4/arm-ldm.dpatch b/meta/packages/gcc/gcc-3.3.4/arm-ldm.dpatch new file mode 100644 index 000000000..561624f39 --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/arm-ldm.dpatch @@ -0,0 +1,148 @@ +#! /bin/sh -e + +src=gcc +if [ $# -eq 3 -a "$2" = '-d' ]; then + pdir="-d $3" + src=$3/gcc +elif [ $# -ne 1 ]; then + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1 +fi +case "$1" in + -patch) + patch $pdir -f --no-backup-if-mismatch -p0 --fuzz 10 < $0 + ;; + -unpatch) + patch $pdir -f --no-backup-if-mismatch -R -p0 --fuzz 10 < $0 + ;; + *) + echo >&2 "`basename $0`: script expects -patch|-unpatch as argument" + exit 1 +esac +exit 0 + +# DP: try harder to avoid ldm in function epilogues + +--- gcc/config/arm/arm.c Fri Mar 5 18:49:42 2004 ++++ gcc/config/arm/arm.c Fri Mar 5 16:00:21 2004 +@@ -7598,6 +7629,26 @@ + return_used_this_function = 0; + } + ++/* Return the number (counting from 0) of ++ the least significant set bit in MASK. */ ++ ++#ifdef __GNUC__ ++inline ++#endif ++static int ++number_of_first_bit_set (mask) ++ int mask; ++{ ++ int bit; ++ ++ for (bit = 0; ++ (mask & (1 << bit)) == 0; ++ ++bit) ++ continue; ++ ++ return bit; ++} ++ + const char * + arm_output_epilogue (really_return) + int really_return; +@@ -7788,27 +7839,47 @@ + saved_regs_mask |= (1 << PC_REGNUM); + } + +- /* Load the registers off the stack. If we only have one register +- to load use the LDR instruction - it is faster. */ +- if (saved_regs_mask == (1 << LR_REGNUM)) +- { +- /* The exception handler ignores the LR, so we do +- not really need to load it off the stack. */ +- if (eh_ofs) +- asm_fprintf (f, "\tadd\t%r, %r, #4\n", SP_REGNUM, SP_REGNUM); +- else +- asm_fprintf (f, "\tldr\t%r, [%r], #4\n", LR_REGNUM, SP_REGNUM); +- } +- else if (saved_regs_mask) ++ if (saved_regs_mask) + { +- if (saved_regs_mask & (1 << SP_REGNUM)) +- /* Note - write back to the stack register is not enabled +- (ie "ldmfd sp!..."). We know that the stack pointer is +- in the list of registers and if we add writeback the +- instruction becomes UNPREDICTABLE. */ +- print_multi_reg (f, "ldmfd\t%r", SP_REGNUM, saved_regs_mask); ++ /* Load the registers off the stack. If we only have one register ++ to load use the LDR instruction - it is faster. */ ++ if (bit_count (saved_regs_mask) == 1) ++ { ++ int reg = number_of_first_bit_set (saved_regs_mask); ++ ++ switch (reg) ++ { ++ case SP_REGNUM: ++ /* Mustn't use base writeback when loading SP. */ ++ asm_fprintf (f, "\tldr\t%r, [%r]\n", SP_REGNUM, SP_REGNUM); ++ break; ++ ++ case LR_REGNUM: ++ if (eh_ofs) ++ { ++ /* The exception handler ignores the LR, so we do ++ not really need to load it off the stack. */ ++ asm_fprintf (f, "\tadd\t%r, %r, #4\n", SP_REGNUM, SP_REGNUM); ++ break; ++ } ++ /* else fall through */ ++ ++ default: ++ asm_fprintf (f, "\tldr\t%r, [%r], #4\n", reg, SP_REGNUM); ++ break; ++ } ++ } + else +- print_multi_reg (f, "ldmfd\t%r!", SP_REGNUM, saved_regs_mask); ++ { ++ if (saved_regs_mask & (1 << SP_REGNUM)) ++ /* Note - write back to the stack register is not enabled ++ (ie "ldmfd sp!..."). We know that the stack pointer is ++ in the list of registers and if we add writeback the ++ instruction becomes UNPREDICTABLE. */ ++ print_multi_reg (f, "ldmfd\t%r", SP_REGNUM, saved_regs_mask); ++ else ++ print_multi_reg (f, "ldmfd\t%r!", SP_REGNUM, saved_regs_mask); ++ } + } + + if (current_function_pretend_args_size) +@@ -9610,26 +9677,6 @@ + } + } + +-/* Return the number (counting from 0) of +- the least significant set bit in MASK. */ +- +-#ifdef __GNUC__ +-inline +-#endif +-static int +-number_of_first_bit_set (mask) +- int mask; +-{ +- int bit; +- +- for (bit = 0; +- (mask & (1 << bit)) == 0; +- ++bit) +- continue; +- +- return bit; +-} +- + /* Generate code to return from a thumb function. + If 'reg_containing_return_addr' is -1, then the return address is + actually on the stack, at the stack pointer. */ diff --git a/meta/packages/gcc/gcc-3.3.4/arm-tune.patch b/meta/packages/gcc/gcc-3.3.4/arm-tune.patch new file mode 100644 index 000000000..701c99b87 --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/arm-tune.patch @@ -0,0 +1,9 @@ +--- gcc/config/arm/linux-elf.h.orig 2004-03-11 14:46:33.000000000 +0000 ++++ gcc/config/arm/linux-elf.h 2004-03-11 14:48:23.000000000 +0000 +@@ -128,3 +128,6 @@ + + #define LINK_GCC_C_SEQUENCE_SPEC \ + "%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}" ++ ++/* Tune for XScale. */ ++#define TARGET_TUNE_DEFAULT TARGET_CPU_xscale diff --git a/meta/packages/gcc/gcc-3.3.4/bash3.patch b/meta/packages/gcc/gcc-3.3.4/bash3.patch new file mode 100644 index 000000000..614ba50ee --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/bash3.patch @@ -0,0 +1,20 @@ +--- gcc-3.3.4/configure.orig 2002-09-29 18:11:24.000000000 +0200 ++++ gcc-3.3.4/configure 2005-01-28 12:26:40.000000000 +0100 +@@ -697,7 +697,7 @@ + if test -f skip-this-dir; then + # Perform the same cleanup as the trap handler, minus the "exit 1" of course, + # and reset the trap handler. +- trap 0 ++ trap '' 0 + rm -rf Makefile* ${tmpdir} + # Execute the final clean-up actions + ${config_shell} skip-this-dir +@@ -1596,7 +1596,7 @@ + # Perform the same cleanup as the trap handler, minus the "exit 1" of course, + # and reset the trap handler. + rm -rf ${tmpdir} +-trap 0 ++trap '' 0 + + exit 0 + diff --git a/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-100-conf.patch b/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-100-conf.patch new file mode 100644 index 000000000..213b4fbbd --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-100-conf.patch @@ -0,0 +1,1593 @@ +diff -urN gcc-3.3.3/boehm-gc/config.sub gcc-3.3.3-new/boehm-gc/config.sub +--- gcc-3.3.3/boehm-gc/config.sub 2002-02-11 22:37:53.000000000 -0600 ++++ gcc-3.3.3-new/boehm-gc/config.sub 2004-02-16 21:12:16.000000000 -0600 +@@ -118,7 +118,7 @@ + # Here we must recognize all the valid KERNEL-OS combinations. + maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` + case $maybe_os in +- nto-qnx* | linux-gnu* | storm-chaos* | os2-emx* | windows32-*) ++ nto-qnx* | linux-gnu* | linux-uclibc* | storm-chaos* | os2-emx* | windows32-*) + os=-$maybe_os + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` + ;; +@@ -1089,7 +1089,8 @@ + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ + | -chorusos* | -chorusrdb* \ + | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ +- | -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \ ++ | -mingw32* | -linux-gnu* | -linux-uclibc* \ ++ | -uxpv* | -beos* | -mpeix* | -udk* \ + | -interix* | -uwin* | -rhapsody* | -darwin* | -opened* \ + | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ + | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ +diff -urN gcc-3.3.3/config.sub gcc-3.3.3-new/config.sub +--- gcc-3.3.3/config.sub 2003-01-30 17:25:36.000000000 -0600 ++++ gcc-3.3.3-new/config.sub 2004-02-16 21:12:16.000000000 -0600 +@@ -118,7 +118,7 @@ + # Here we must recognize all the valid KERNEL-OS combinations. + maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` + case $maybe_os in +- nto-qnx* | linux-gnu* | freebsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) ++ nto-qnx* | linux-gnu* | linux-uclibc* | freebsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) + os=-$maybe_os + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` + ;; +@@ -1112,7 +1112,8 @@ + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ + | -chorusos* | -chorusrdb* \ + | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ +- | -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \ ++ | -mingw32* | -linux-gnu* | -linux-uclibc* \ ++ | -uxpv* | -beos* | -mpeix* | -udk* \ + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ + | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ + | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ +diff -urN gcc-3.3.3/gcc/config/arm/linux-elf.h gcc-3.3.3-new/gcc/config/arm/linux-elf.h +--- gcc-3.3.3/gcc/config/arm/linux-elf.h 2003-09-16 10:39:23.000000000 -0500 ++++ gcc-3.3.3-new/gcc/config/arm/linux-elf.h 2004-02-16 21:12:16.000000000 -0600 +@@ -78,6 +78,18 @@ + "%{!shared:crtend.o%s} %{shared:crtendS.o%s} crtn.o%s" + + #undef LINK_SPEC ++#ifdef USE_UCLIBC ++#define LINK_SPEC "%{h*} %{version:-v} \ ++ %{b} %{Wl,*:%*} \ ++ %{static:-Bstatic} \ ++ %{shared:-shared} \ ++ %{symbolic:-Bsymbolic} \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0} \ ++ -X \ ++ %{mbig-endian:-EB}" \ ++ SUBTARGET_EXTRA_LINK_SPEC ++#else + #define LINK_SPEC "%{h*} %{version:-v} \ + %{b} %{Wl,*:%*} \ + %{static:-Bstatic} \ +@@ -88,6 +100,7 @@ + -X \ + %{mbig-endian:-EB}" \ + SUBTARGET_EXTRA_LINK_SPEC ++#endif + + #define TARGET_OS_CPP_BUILTINS() \ + do { \ +diff -urN gcc-3.3.3/gcc/config/cris/linux.h gcc-3.3.3-new/gcc/config/cris/linux.h +--- gcc-3.3.3/gcc/config/cris/linux.h 2003-03-10 21:01:35.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/cris/linux.h 2004-02-16 21:12:16.000000000 -0600 +@@ -81,6 +81,25 @@ + #undef CRIS_DEFAULT_CPU_VERSION + #define CRIS_DEFAULT_CPU_VERSION CRIS_CPU_NG + ++#ifdef USE_UCLIBC ++ ++#undef CRIS_SUBTARGET_VERSION ++#define CRIS_SUBTARGET_VERSION " - cris-axis-linux-uclibc" ++ ++#undef CRIS_LINK_SUBTARGET_SPEC ++#define CRIS_LINK_SUBTARGET_SPEC \ ++ "-mcrislinux\ ++ -rpath-link include/asm/../..%s\ ++ %{shared} %{static}\ ++ %{symbolic:-Bdynamic} %{shlib:-Bdynamic} %{static:-Bstatic}\ ++ %{!shared: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}} \ ++ %{!r:%{O2|O3: --gc-sections}}" ++ ++#else /* USE_UCLIBC */ ++ + #undef CRIS_SUBTARGET_VERSION + #define CRIS_SUBTARGET_VERSION " - cris-axis-linux-gnu" + +@@ -95,6 +114,8 @@ + %{!shared:%{!static:%{rdynamic:-export-dynamic}}}\ + %{!r:%{O2|O3: --gc-sections}}" + ++#endif /* USE_UCLIBC */ ++ + + /* Node: Run-time Target */ + +diff -urN gcc-3.3.3/gcc/config/cris/t-linux-uclibc gcc-3.3.3-new/gcc/config/cris/t-linux-uclibc +--- gcc-3.3.3/gcc/config/cris/t-linux-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/cris/t-linux-uclibc 2004-02-16 21:12:16.000000000 -0600 +@@ -0,0 +1,3 @@ ++T_CFLAGS = -DUSE_UCLIBC ++TARGET_LIBGCC2_CFLAGS += -fPIC ++CRTSTUFF_T_CFLAGS_S = $(TARGET_LIBGCC2_CFLAGS) +diff -urN gcc-3.3.3/gcc/config/i386/linux.h gcc-3.3.3-new/gcc/config/i386/linux.h +--- gcc-3.3.3/gcc/config/i386/linux.h 2003-11-14 00:46:12.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/i386/linux.h 2004-02-16 21:12:16.000000000 -0600 +@@ -136,6 +136,15 @@ + %{static:-static}}}" + #endif + #else ++#if defined USE_UCLIBC ++#define LINK_SPEC "-m elf_i386 %{shared:-shared} \ ++ %{!shared: \ ++ %{!ibcs: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}} \ ++ %{static:-static}}}" ++#else + #define LINK_SPEC "-m elf_i386 %{shared:-shared} \ + %{!shared: \ + %{!ibcs: \ +@@ -144,6 +153,7 @@ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ + %{static:-static}}}" + #endif ++#endif + + /* A C statement (sans semicolon) to output to the stdio stream + FILE the assembler definition of uninitialized global DECL named +diff -urN gcc-3.3.3/gcc/config/mips/linux.h gcc-3.3.3-new/gcc/config/mips/linux.h +--- gcc-3.3.3/gcc/config/mips/linux.h 2003-12-23 02:58:00.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/mips/linux.h 2004-02-16 21:12:16.000000000 -0600 +@@ -175,6 +175,17 @@ + + /* Borrowed from sparc/linux.h */ + #undef LINK_SPEC ++#ifdef USE_UCLIBC ++#define LINK_SPEC \ ++ "%(endian_spec) \ ++ %{shared:-shared} \ ++ %{!shared: \ ++ %{!ibcs: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}} \ ++ %{static:-static}}}" ++#else + #define LINK_SPEC \ + "%(endian_spec) \ + %{shared:-shared} \ +@@ -184,6 +195,7 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}} \ + %{static:-static}}}" ++#endif + + #undef SUBTARGET_ASM_SPEC + #define SUBTARGET_ASM_SPEC "\ +diff -urN gcc-3.3.3/gcc/config/sh/linux.h gcc-3.3.3-new/gcc/config/sh/linux.h +--- gcc-3.3.3/gcc/config/sh/linux.h 2003-11-06 17:13:33.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/sh/linux.h 2004-02-16 21:12:16.000000000 -0600 +@@ -44,12 +44,21 @@ + #undef SUBTARGET_LINK_EMUL_SUFFIX + #define SUBTARGET_LINK_EMUL_SUFFIX "_linux" + #undef SUBTARGET_LINK_SPEC ++#ifdef USE_UCLIBC ++#define SUBTARGET_LINK_SPEC \ ++ "%{shared:-shared} \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}} \ ++ %{static:-static}" ++#else + #define SUBTARGET_LINK_SPEC \ + "%{shared:-shared} \ + %{!static: \ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ + %{static:-static}" ++#endif + + /* The GNU C++ standard library requires that these macros be defined. */ + #undef CPLUSPLUS_CPP_SPEC +diff -urN gcc-3.3.3/gcc/config/sh/t-linux-uclibc gcc-3.3.3-new/gcc/config/sh/t-linux-uclibc +--- gcc-3.3.3/gcc/config/sh/t-linux-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/sh/t-linux-uclibc 2004-02-16 21:12:16.000000000 -0600 +@@ -0,0 +1,16 @@ ++T_CFLAGS = -DUSE_UCLIBC ++ ++# Don't run fixproto ++STMP_FIXPROTO = ++ ++TARGET_LIBGCC2_CFLAGS = -fpic ++LIB1ASMFUNCS_CACHE = _ic_invalidate ++ ++LIB2FUNCS_EXTRA= ++ ++MULTILIB_OPTIONS= $(MULTILIB_ENDIAN) m3e/m4 ++MULTILIB_DIRNAMES= ++MULTILIB_MATCHES = ++MULTILIB_EXCEPTIONS= ++ ++EXTRA_MULTILIB_PARTS= crtbegin.o crtend.o crtbeginS.o crtendS.o +diff -urN gcc-3.3.3/gcc/config/sh/t-sh64-uclibc gcc-3.3.3-new/gcc/config/sh/t-sh64-uclibc +--- gcc-3.3.3/gcc/config/sh/t-sh64-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/sh/t-sh64-uclibc 2004-02-16 21:12:16.000000000 -0600 +@@ -0,0 +1,13 @@ ++EXTRA_MULTILIB_PARTS= crtbegin.o crtend.o ++ ++LIB1ASMFUNCS = \ ++ _sdivsi3 _sdivsi3_i4 _udivsi3 _udivsi3_i4 _set_fpscr \ ++ _shcompact_call_trampoline _shcompact_return_trampoline \ ++ _shcompact_incoming_args _ic_invalidate _nested_trampoline \ ++ _push_pop_shmedia_regs \ ++ _udivdi3 _divdi3 _umoddi3 _moddi3 ++ ++MULTILIB_OPTIONS = $(MULTILIB_ENDIAN) m5-32media-nofpu/m5-compact/m5-compact-nofpu/m5-64media/m5-64media-nofpu ++MULTILIB_DIRNAMES= $(MULTILIB_ENDIAN) nofpu compact nofpu/compact media64 nofpu/media64 ++MULTILIB_MATCHES= ++MULTILIB_EXCEPTIONS= +diff -urN gcc-3.3.3/gcc/config/t-linux-uclibc gcc-3.3.3-new/gcc/config/t-linux-uclibc +--- gcc-3.3.3/gcc/config/t-linux-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/t-linux-uclibc 2004-02-16 21:12:16.000000000 -0600 +@@ -0,0 +1,23 @@ ++T_CFLAGS = -DUSE_UCLIBC ++ ++# Don't run fixproto ++STMP_FIXPROTO = ++ ++# Compile crtbeginS.o and crtendS.o with pic. ++CRTSTUFF_T_CFLAGS_S = $(CRTSTUFF_T_CFLAGS) -fPIC ++# Compile libgcc2.a with pic. ++TARGET_LIBGCC2_CFLAGS = -fPIC ++ ++# Override t-slibgcc-elf-ver to export some libgcc symbols with ++# the symbol versions that glibc used. ++SHLIB_MAPFILES += $(srcdir)/config/libgcc-glibc.ver ++ ++# Use unwind-dw2-fde-glibc ++#LIB2ADDEH = $(srcdir)/unwind-dw2.c $(srcdir)/unwind-dw2-fde-glibc.c \ ++# $(srcdir)/unwind-sjlj.c $(srcdir)/unwind-c.c ++#LIB2ADDEHDEP = unwind.inc unwind-dw2-fde.h unwind-dw2-fde.c ++ ++# Use unwind-dw2-fde ++LIB2ADDEH = $(srcdir)/unwind-dw2.c $(srcdir)/unwind-dw2-fde.c \ ++ $(srcdir)/unwind-sjlj.c $(srcdir)/unwind-c.c ++LIB2ADDEHDEP = unwind.inc unwind-dw2-fde.h +diff -urN gcc-3.3.3/gcc/config.gcc gcc-3.3.3-new/gcc/config.gcc +--- gcc-3.3.3/gcc/config.gcc 2004-01-21 00:06:00.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config.gcc 2004-02-16 21:12:16.000000000 -0600 +@@ -697,6 +697,17 @@ + extra_parts="" + use_collect2=yes + ;; ++arm*-*-linux-uclibc*) # ARM GNU/Linux with ELF - uClibc ++ tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h arm/linux-gas.h arm/linux-elf.h" ++ tmake_file="t-slibgcc-elf-ver t-linux-uclibc arm/t-linux" ++ extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" ++ gnu_ld=yes ++ case x${enable_threads} in ++ x | xyes | xpthreads | xposix) ++ thread_file='posix' ++ ;; ++ esac ++ ;; + arm*-*-linux*) # ARM GNU/Linux with ELF + tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h arm/linux-gas.h arm/linux-elf.h" + tmake_file="t-slibgcc-elf-ver t-linux arm/t-linux" +@@ -772,6 +783,10 @@ + tmake_file="cris/t-cris cris/t-elfmulti" + gas=yes + ;; ++cris-*-linux-uclibc*) ++ tm_file="dbxelf.h elfos.h svr4.h ${tm_file} linux.h cris/linux.h" ++ tmake_file="cris/t-cris t-slibgcc-elf-ver cris/t-linux-uclibc" ++ ;; + cris-*-linux*) + tm_file="dbxelf.h elfos.h svr4.h ${tm_file} linux.h cris/linux.h" + tmake_file="cris/t-cris t-slibgcc-elf-ver cris/t-linux" +@@ -1173,6 +1188,11 @@ + thread_file='single' + fi + ;; ++i[34567]86-*-linux*uclibc*) # Intel 80386's running GNU/Linux ++ # with ELF format using uClibc ++ tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h linux.h i386/linux.h" ++ tmake_file="t-slibgcc-elf-ver t-linux-uclibc i386/t-crtstuff" ++ ;; + i[34567]86-*-linux*) # Intel 80386's running GNU/Linux + # with ELF format using glibc 2 + # aka GNU/Linux C library 6 +@@ -1883,6 +1903,16 @@ + tm_file="elfos.h ${tm_file} mips/netbsd.h" + tmake_file="${tmake_file} mips/t-netbsd" + ;; ++mips*-*-linux-uclibc*) # Linux MIPS, either endian. uClibc ++ tm_file="dbxelf.h elfos.h svr4.h linux.h ${tm_file} mips/linux.h" ++ case $machine in ++ mipsisa32*-*) ++ target_cpu_default="MASK_SOFT_FLOAT" ++ tm_defines="MIPS_ISA_DEFAULT=32" ++ ;; ++ esac ++ tmake_file="t-slibgcc-elf-ver t-linux-uclibc mips/t-linux" ++ ;; + mips*-*-linux*) # Linux MIPS, either endian. + tm_file="dbxelf.h elfos.h svr4.h linux.h ${tm_file} mips/linux.h" + case $machine in +@@ -2129,6 +2159,11 @@ + out_file=rs6000/rs6000.c + tmake_file="rs6000/t-ppcos t-slibgcc-elf-ver t-linux rs6000/t-ppccomm" + ;; ++powerpc-*-linux-uclibc*) ++ tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h" ++ out_file=rs6000/rs6000.c ++ tmake_file="rs6000/t-ppcos t-slibgcc-elf-ver t-linux-uclibc rs6000/t-ppccomm" ++ ;; + powerpc-*-linux*) + tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h" + out_file=rs6000/rs6000.c +@@ -2313,10 +2348,18 @@ + tmake_file="${tmake_file} sh/t-le" + ;; + esac +- tmake_file="${tmake_file} sh/t-linux" ++ case $machine in ++ *-*-linux-uclibc*) tmake_file="${tmake_file} sh/t-linux-uclibc" ;; ++ *) tmake_file="${tmake_file} sh/t-linux" ;; ++ esac + tm_file="${tm_file} dbxelf.h elfos.h svr4.h sh/elf.h sh/linux.h" + gas=yes gnu_ld=yes + case $machine in ++ sh64*-*-linux-uclibc*) ++ tmake_file="${tmake_file} sh/t-sh64-uclibc" ++ tm_file="${tm_file} sh/sh64.h" ++ extra_headers="shmedia.h ushmedia.h sshmedia.h" ++ ;; + sh64*) + tmake_file="${tmake_file} sh/t-sh64" + tm_file="${tm_file} sh/sh64.h" +diff -urN gcc-3.3.3/libstdc++-v3/aclocal.m4 gcc-3.3.3-new/libstdc++-v3/aclocal.m4 +--- gcc-3.3.3/libstdc++-v3/aclocal.m4 2004-01-12 10:18:44.000000000 -0600 ++++ gcc-3.3.3-new/libstdc++-v3/aclocal.m4 2004-02-16 21:12:16.000000000 -0600 +@@ -1216,6 +1216,9 @@ + dnl Default to "generic" + if test x$enable_clocale_flag = xno; then + case x${target_os} in ++ xlinux-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + xlinux* | xgnu*) + AC_EGREP_CPP([_GLIBCPP_ok], [ + #include +@@ -1339,6 +1342,41 @@ + CTIME_CC=config/locale/generic/time_members.cc + CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h + ;; ++ xuclibc) ++ AC_MSG_RESULT(uclibc) ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ AC_CHECK_PROG(check_msgfmt, msgfmt, yes, no) ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcpp_MOFILES="$glibcpp_MOFILES $ling.mo"; \ ++ glibcpp_POFILES="$glibcpp_POFILES $ling.po"; \ ++ done ++ AC_SUBST(glibcpp_MOFILES) ++ AC_SUBST(glibcpp_POFILES) ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_H=config/locale/uclibc/codecvt_specializations.h ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + *) + echo "$enable_clocale is an unknown locale package" 1>&2 + exit 1 +diff -urN gcc-3.3.3/libstdc++-v3/configure gcc-3.3.3-new/libstdc++-v3/configure +--- gcc-3.3.3/libstdc++-v3/configure 2004-01-12 10:18:45.000000000 -0600 ++++ gcc-3.3.3-new/libstdc++-v3/configure 2004-02-17 00:21:12.000000000 -0600 +@@ -2996,6 +2996,9 @@ + + if test x$enable_clocale_flag = xno; then + case x${target_os} in ++ xlinux-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + xlinux* | xgnu*) + cat > conftest.$ac_ext <&6 ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ # Extract the first word of "msgfmt", so it can be a program name with args. ++set dummy msgfmt; ac_word=$2 ++echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 ++echo "configure:3117: checking for $ac_word" >&5 ++if eval "test \"`echo '$''{'ac_cv_prog_check_msgfmt'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ if test -n "$check_msgfmt"; then ++ ac_cv_prog_check_msgfmt="$check_msgfmt" # Let the user override the test. ++else ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" ++ ac_dummy="$PATH" ++ for ac_dir in $ac_dummy; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ ac_cv_prog_check_msgfmt="yes" ++ break ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_prog_check_msgfmt" && ac_cv_prog_check_msgfmt="no" ++fi ++fi ++check_msgfmt="$ac_cv_prog_check_msgfmt" ++if test -n "$check_msgfmt"; then ++ echo "$ac_t""$check_msgfmt" 1>&6 ++else ++ echo "$ac_t""no" 1>&6 ++fi ++ ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcpp_MOFILES="$glibcpp_MOFILES $ling.mo"; \ ++ glibcpp_POFILES="$glibcpp_POFILES $ling.po"; \ ++ done ++ ++ ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_H=config/locale/uclibc/codecvt_specializations.h ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + *) + echo "$enable_clocale is an unknown locale package" 1>&2 + exit 1 +@@ -4212,6 +4279,968 @@ + # GLIBCPP_CHECK_MATH_SUPPORT + + case "$target" in ++ *-uclibc*) ++ os_include_dir="os/uclibc" ++ for ac_hdr in nan.h ieeefp.h endian.h sys/isa_defs.h \ ++ machine/endian.h machine/param.h sys/machine.h sys/types.h \ ++ fp.h locale.h float.h inttypes.h ++do ++ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` ++echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 ++echo "configure:4224: checking for $ac_hdr" >&5 ++if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++EOF ++ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" ++{ (eval echo configure:4234: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` ++if test -z "$ac_err"; then ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=yes" ++else ++ echo "$ac_err" >&5 ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=no" ++fi ++rm -f conftest* ++fi ++if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` ++ cat >> confdefs.h <&6 ++fi ++done ++ ++ SECTION_FLAGS='-ffunction-sections -fdata-sections' ++ ++ ++ # If we're not using GNU ld, then there's no point in even trying these ++ # tests. Check for that first. We should have already tested for gld ++ # by now (in libtool), but require it now just to be safe... ++ test -z "$SECTION_LDFLAGS" && SECTION_LDFLAGS='' ++ test -z "$OPT_LDFLAGS" && OPT_LDFLAGS='' ++ ++ ++ # The name set by libtool depends on the version of libtool. Shame on us ++ # for depending on an impl detail, but c'est la vie. Older versions used ++ # ac_cv_prog_gnu_ld, but now it's lt_cv_prog_gnu_ld, and is copied back on ++ # top of with_gnu_ld (which is also set by --with-gnu-ld, so that actually ++ # makes sense). We'll test with_gnu_ld everywhere else, so if that isn't ++ # set (hence we're using an older libtool), then set it. ++ if test x${with_gnu_ld+set} != xset; then ++ if test x${ac_cv_prog_gnu_ld+set} != xset; then ++ # We got through "ac_require(ac_prog_ld)" and still not set? Huh? ++ with_gnu_ld=no ++ else ++ with_gnu_ld=$ac_cv_prog_gnu_ld ++ fi ++ fi ++ ++ # Start by getting the version number. I think the libtool test already ++ # does some of this, but throws away the result. ++ ++ ldver=`$LD --version 2>/dev/null | head -1 | \ ++ sed -e 's/GNU ld version \([0-9.][0-9.]*\).*/\1/'` ++ ++ glibcpp_gnu_ld_version=`echo $ldver | \ ++ $AWK -F. '{ if (NF<3) $3=0; print ($1*100+$2)*100+$3 }'` ++ ++ # Set --gc-sections. ++ if test "$with_gnu_ld" = "notbroken"; then ++ # GNU ld it is! Joy and bunny rabbits! ++ ++ # All these tests are for C++; save the language and the compiler flags. ++ # Need to do this so that g++ won't try to link in libstdc++ ++ ac_test_CFLAGS="${CFLAGS+set}" ++ ac_save_CFLAGS="$CFLAGS" ++ CFLAGS='-x c++ -Wl,--gc-sections' ++ ++ # Check for -Wl,--gc-sections ++ # XXX This test is broken at the moment, as symbols required for ++ # linking are now in libsupc++ (not built yet.....). In addition, ++ # this test has cored on solaris in the past. In addition, ++ # --gc-sections doesn't really work at the moment (keeps on discarding ++ # used sections, first .eh_frame and now some of the glibc sections for ++ # iconv). Bzzzzt. Thanks for playing, maybe next time. ++ echo $ac_n "checking for ld that supports -Wl,--gc-sections""... $ac_c" 1>&6 ++echo "configure:4312: checking for ld that supports -Wl,--gc-sections" >&5 ++ if test "$cross_compiling" = yes; then ++ ac_sectionLDflags=yes ++else ++ cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null ++then ++ ac_sectionLDflags=yes ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -fr conftest* ++ ac_sectionLDflags=no ++fi ++rm -fr conftest* ++fi ++ ++ if test "$ac_test_CFLAGS" = set; then ++ CFLAGS="$ac_save_CFLAGS" ++ else ++ # this is the suspicious part ++ CFLAGS='' ++ fi ++ if test "$ac_sectionLDflags" = "yes"; then ++ SECTION_LDFLAGS="-Wl,--gc-sections $SECTION_LDFLAGS" ++ fi ++ echo "$ac_t""$ac_sectionLDflags" 1>&6 ++ fi ++ ++ # Set linker optimization flags. ++ if test x"$with_gnu_ld" = x"yes"; then ++ OPT_LDFLAGS="-Wl,-O1 $OPT_LDFLAGS" ++ fi ++ ++ ++ ++ ++ ++ echo $ac_n "checking for main in -lm""... $ac_c" 1>&6 ++echo "configure:4362: checking for main in -lm" >&5 ++ac_lib_var=`echo m'_'main | sed 'y%./+-%__p_%'` ++if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ ac_save_LIBS="$LIBS" ++LIBS="-lm $LIBS" ++cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ rm -rf conftest* ++ eval "ac_cv_lib_$ac_lib_var=yes" ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_lib_$ac_lib_var=no" ++fi ++rm -f conftest* ++LIBS="$ac_save_LIBS" ++ ++fi ++if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \ ++ -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` ++ cat >> confdefs.h <&6 ++fi ++ ++ for ac_func in nan copysignf ++do ++echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 ++echo "configure:4407: checking for $ac_func" >&5 ++if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++/* Override any gcc2 internal prototype to avoid an error. */ ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func(); ++ ++int main() { ++ ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++$ac_func(); ++#endif ++ ++; return 0; } ++EOF ++if { (eval echo configure:4435: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=yes" ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=no" ++fi ++rm -f conftest* ++fi ++ ++if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` ++ cat >> confdefs.h <&6 ++LIBMATHOBJS="$LIBMATHOBJS ${ac_func}.lo" ++fi ++done ++ ++ ++ for ac_func in __signbit ++do ++echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 ++echo "configure:4464: checking for $ac_func" >&5 ++if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++/* Override any gcc2 internal prototype to avoid an error. */ ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func(); ++ ++int main() { ++ ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++$ac_func(); ++#endif ++ ++; return 0; } ++EOF ++if { (eval echo configure:4492: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=yes" ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=no" ++fi ++rm -f conftest* ++fi ++ ++if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` ++ cat >> confdefs.h <&6 ++LIBMATHOBJS="$LIBMATHOBJS signbit.lo" ++fi ++done ++ ++ for ac_func in __signbitf ++do ++echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 ++echo "configure:4520: checking for $ac_func" >&5 ++if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++/* Override any gcc2 internal prototype to avoid an error. */ ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func(); ++ ++int main() { ++ ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++$ac_func(); ++#endif ++ ++; return 0; } ++EOF ++if { (eval echo configure:4548: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=yes" ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=no" ++fi ++rm -f conftest* ++fi ++ ++if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` ++ cat >> confdefs.h <&6 ++LIBMATHOBJS="$LIBMATHOBJS signbitf.lo" ++fi ++done ++ ++ ++ if test x$ac_cv_func_copysignl = x"yes"; then ++ for ac_func in __signbitl ++do ++echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 ++echo "configure:4578: checking for $ac_func" >&5 ++if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++/* Override any gcc2 internal prototype to avoid an error. */ ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func(); ++ ++int main() { ++ ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++$ac_func(); ++#endif ++ ++; return 0; } ++EOF ++if { (eval echo configure:4606: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=yes" ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=no" ++fi ++rm -f conftest* ++fi ++ ++if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` ++ cat >> confdefs.h <&6 ++LIBMATHOBJS="$LIBMATHOBJS signbitl.lo" ++fi ++done ++ ++ fi ++ ++ if test -n "$LIBMATHOBJS"; then ++ need_libmath=yes ++ fi ++ ++ ++ ++if test "$need_libmath" = yes; then ++ GLIBCPP_BUILD_LIBMATH_TRUE= ++ GLIBCPP_BUILD_LIBMATH_FALSE='#' ++else ++ GLIBCPP_BUILD_LIBMATH_TRUE='#' ++ GLIBCPP_BUILD_LIBMATH_FALSE= ++fi ++ ++ ++ enable_wchar_t=no ++ ++ echo $ac_n "checking for mbstate_t""... $ac_c" 1>&6 ++echo "configure:4651: checking for mbstate_t" >&5 ++ cat > conftest.$ac_ext < ++int main() { ++mbstate_t teststate; ++; return 0; } ++EOF ++if { (eval echo configure:4660: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++ rm -rf conftest* ++ have_mbstate_t=yes ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ have_mbstate_t=no ++fi ++rm -f conftest* ++ echo "$ac_t""$have_mbstate_t" 1>&6 ++ if test x"$have_mbstate_t" = xyes; then ++ cat >> confdefs.h <<\EOF ++#define HAVE_MBSTATE_T 1 ++EOF ++ ++ fi ++ ++ for ac_hdr in wchar.h ++do ++ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` ++echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 ++echo "configure:4682: checking for $ac_hdr" >&5 ++if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++EOF ++ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" ++{ (eval echo configure:4692: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` ++if test -z "$ac_err"; then ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=yes" ++else ++ echo "$ac_err" >&5 ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=no" ++fi ++rm -f conftest* ++fi ++if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` ++ cat >> confdefs.h <&6 ++ac_has_wchar_h=no ++fi ++done ++ ++ for ac_hdr in wctype.h ++do ++ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` ++echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 ++echo "configure:4723: checking for $ac_hdr" >&5 ++if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++EOF ++ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" ++{ (eval echo configure:4733: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` ++if test -z "$ac_err"; then ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=yes" ++else ++ echo "$ac_err" >&5 ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=no" ++fi ++rm -f conftest* ++fi ++if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` ++ cat >> confdefs.h <&6 ++ac_has_wctype_h=no ++fi ++done ++ ++ ++ if test x"$ac_has_wchar_h" = xyes && ++ test x"$ac_has_wctype_h" = xyes && ++ test x"$enable_c_mbchar" != xno; then ++ ++ echo $ac_n "checking for WCHAR_MIN and WCHAR_MAX""... $ac_c" 1>&6 ++echo "configure:4766: checking for WCHAR_MIN and WCHAR_MAX" >&5 ++ cat > conftest.$ac_ext < ++int main() { ++int i = WCHAR_MIN; int j = WCHAR_MAX; ++; return 0; } ++EOF ++if { (eval echo configure:4775: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++ rm -rf conftest* ++ has_wchar_minmax=yes ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ has_wchar_minmax=no ++fi ++rm -f conftest* ++ echo "$ac_t""$has_wchar_minmax" 1>&6 ++ ++ echo $ac_n "checking for WEOF""... $ac_c" 1>&6 ++echo "configure:4788: checking for WEOF" >&5 ++ cat > conftest.$ac_ext < ++ #include ++int main() { ++wint_t i = WEOF; ++; return 0; } ++EOF ++if { (eval echo configure:4799: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++ rm -rf conftest* ++ has_weof=yes ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ has_weof=no ++fi ++rm -f conftest* ++ echo "$ac_t""$has_weof" 1>&6 ++ ++ ac_wfuncs=yes ++ for ac_func in wcslen wmemchr wmemcmp wmemcpy wmemmove wmemset ++do ++echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 ++echo "configure:4815: checking for $ac_func" >&5 ++if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++/* Override any gcc2 internal prototype to avoid an error. */ ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func(); ++ ++int main() { ++ ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++$ac_func(); ++#endif ++ ++; return 0; } ++EOF ++if { (eval echo configure:4843: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=yes" ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=no" ++fi ++rm -f conftest* ++fi ++ ++if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` ++ cat >> confdefs.h <&6 ++\ ++ ac_wfuncs=no ++fi ++done ++ ++ ++ for ac_func in btowc wctob fgetwc fgetws fputwc fputws fwide \ ++ fwprintf fwscanf swprintf swscanf vfwprintf vfwscanf vswprintf vswscanf \ ++ vwprintf vwscanf wprintf wscanf getwc getwchar mbsinit mbrlen mbrtowc \ ++ mbsrtowcs wcsrtombs putwc putwchar ungetwc wcrtomb wcstod wcstof wcstol \ ++ wcstoul wcscpy wcsncpy wcscat wcsncat wcscmp wcscoll wcsncmp wcsxfrm \ ++ wcscspn wcsspn wcstok wcsftime wcschr wcspbrk wcsrchr wcsstr ++do ++echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 ++echo "configure:4878: checking for $ac_func" >&5 ++if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++/* Override any gcc2 internal prototype to avoid an error. */ ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func(); ++ ++int main() { ++ ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++$ac_func(); ++#endif ++ ++; return 0; } ++EOF ++if { (eval echo configure:4906: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=yes" ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=no" ++fi ++rm -f conftest* ++fi ++ ++if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` ++ cat >> confdefs.h <&6 ++\ ++ ac_wfuncs=no ++fi ++done ++ ++ ++ echo $ac_n "checking for ISO C99 wchar_t support""... $ac_c" 1>&6 ++echo "configure:4934: checking for ISO C99 wchar_t support" >&5 ++ if test x"$has_weof" = xyes && ++ test x"$has_wchar_minmax" = xyes && ++ test x"$ac_wfuncs" = xyes; then ++ ac_isoC99_wchar_t=yes ++ else ++ ac_isoC99_wchar_t=no ++ fi ++ echo "$ac_t""$ac_isoC99_wchar_t" 1>&6 ++ ++ ac_safe=`echo "iconv.h" | sed 'y%./+-%__p_%'` ++echo $ac_n "checking for iconv.h""... $ac_c" 1>&6 ++echo "configure:4946: checking for iconv.h" >&5 ++if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++EOF ++ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" ++{ (eval echo configure:4956: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` ++if test -z "$ac_err"; then ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=yes" ++else ++ echo "$ac_err" >&5 ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=no" ++fi ++rm -f conftest* ++fi ++if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_has_iconv_h=yes ++else ++ echo "$ac_t""no" 1>&6 ++ac_has_iconv_h=no ++fi ++ ++ ac_safe=`echo "langinfo.h" | sed 'y%./+-%__p_%'` ++echo $ac_n "checking for langinfo.h""... $ac_c" 1>&6 ++echo "configure:4980: checking for langinfo.h" >&5 ++if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++EOF ++ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" ++{ (eval echo configure:4990: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` ++if test -z "$ac_err"; then ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=yes" ++else ++ echo "$ac_err" >&5 ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_header_$ac_safe=no" ++fi ++rm -f conftest* ++fi ++if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_has_langinfo_h=yes ++else ++ echo "$ac_t""no" 1>&6 ++ac_has_langinfo_h=no ++fi ++ ++ ++ echo $ac_n "checking for iconv in -liconv""... $ac_c" 1>&6 ++echo "configure:5014: checking for iconv in -liconv" >&5 ++ac_lib_var=`echo iconv'_'iconv | sed 'y%./+-%__p_%'` ++if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ ac_save_LIBS="$LIBS" ++LIBS="-liconv $LIBS" ++cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ rm -rf conftest* ++ eval "ac_cv_lib_$ac_lib_var=yes" ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_lib_$ac_lib_var=no" ++fi ++rm -f conftest* ++LIBS="$ac_save_LIBS" ++ ++fi ++if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ libiconv="-liconv" ++else ++ echo "$ac_t""no" 1>&6 ++fi ++ ++ ac_save_LIBS="$LIBS" ++ LIBS="$LIBS $libiconv" ++ ++ for ac_func in iconv_open iconv_close iconv nl_langinfo ++do ++echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 ++echo "configure:5059: checking for $ac_func" >&5 ++if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then ++ echo $ac_n "(cached) $ac_c" 1>&6 ++else ++ cat > conftest.$ac_ext < ++/* Override any gcc2 internal prototype to avoid an error. */ ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func(); ++ ++int main() { ++ ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++$ac_func(); ++#endif ++ ++; return 0; } ++EOF ++if { (eval echo configure:5087: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=yes" ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ rm -rf conftest* ++ eval "ac_cv_func_$ac_func=no" ++fi ++rm -f conftest* ++fi ++ ++if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then ++ echo "$ac_t""yes" 1>&6 ++ ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` ++ cat >> confdefs.h <&6 ++ac_XPG2funcs=no ++fi ++done ++ ++ ++ LIBS="$ac_save_LIBS" ++ ++ echo $ac_n "checking for XPG2 wchar_t support""... $ac_c" 1>&6 ++echo "configure:5117: checking for XPG2 wchar_t support" >&5 ++ if test x"$ac_has_iconv_h" = xyes && ++ test x"$ac_has_langinfo_h" = xyes && ++ test x"$ac_XPG2funcs" = xyes; then ++ ac_XPG2_wchar_t=yes ++ else ++ ac_XPG2_wchar_t=no ++ fi ++ echo "$ac_t""$ac_XPG2_wchar_t" 1>&6 ++ ++ if test x"$ac_isoC99_wchar_t" = xyes && ++ test x"$ac_XPG2_wchar_t" = xyes; then ++ cat >> confdefs.h <<\EOF ++#define _GLIBCPP_USE_WCHAR_T 1 ++EOF ++ ++ enable_wchar_t=yes ++ fi ++ fi ++ echo $ac_n "checking for enabled wchar_t specializations""... $ac_c" 1>&6 ++echo "configure:5137: checking for enabled wchar_t specializations" >&5 ++ echo "$ac_t""$enable_wchar_t" 1>&6 ++ ++ ++if test "$enable_wchar_t" = yes; then ++ GLIBCPP_TEST_WCHAR_T_TRUE= ++ GLIBCPP_TEST_WCHAR_T_FALSE='#' ++else ++ GLIBCPP_TEST_WCHAR_T_TRUE='#' ++ GLIBCPP_TEST_WCHAR_T_FALSE= ++fi ++ ++ ++ cat >> confdefs.h <<\EOF ++#define HAVE_COPYSIGN 1 ++EOF ++ ++ cat >> confdefs.h <<\EOF ++#define HAVE_FINITE 1 ++EOF ++ ++ cat >> confdefs.h <<\EOF ++#define HAVE_FINITEF 1 ++EOF ++ ++ cat >> confdefs.h <<\EOF ++#define HAVE_ISINF 1 ++EOF ++ ++ cat >> confdefs.h <<\EOF ++#define HAVE_ISINFF 1 ++EOF ++ ++ cat >> confdefs.h <<\EOF ++#define HAVE_ISNAN 1 ++EOF ++ ++ cat >> confdefs.h <<\EOF ++#define HAVE_ISNANF 1 ++EOF ++ ;; + *-linux*) + os_include_dir="os/gnu-linux" + for ac_hdr in nan.h ieeefp.h endian.h sys/isa_defs.h \ +diff -urN gcc-3.3.3/libstdc++-v3/configure.in gcc-3.3.3-new/libstdc++-v3/configure.in +--- gcc-3.3.3/libstdc++-v3/configure.in 2004-01-12 10:19:22.000000000 -0600 ++++ gcc-3.3.3-new/libstdc++-v3/configure.in 2004-02-16 23:13:45.000000000 -0600 +@@ -117,6 +117,36 @@ + # GLIBCPP_CHECK_MATH_SUPPORT + + case "$target" in ++ *-uclibc*) ++ os_include_dir="os/uclibc" ++ AC_CHECK_HEADERS([nan.h ieeefp.h endian.h sys/isa_defs.h \ ++ machine/endian.h machine/param.h sys/machine.h sys/types.h \ ++ fp.h locale.h float.h inttypes.h]) ++ SECTION_FLAGS='-ffunction-sections -fdata-sections' ++ AC_SUBST(SECTION_FLAGS) ++ GLIBCPP_CHECK_LINKER_FEATURES ++ GLIBCPP_CHECK_COMPLEX_MATH_SUPPORT ++ GLIBCPP_CHECK_WCHAR_T_SUPPORT ++ ++ AC_DEFINE(HAVE_COPYSIGN) ++ #AC_DEFINE(HAVE_COPYSIGNF) ++ AC_DEFINE(HAVE_FINITE) ++ AC_DEFINE(HAVE_FINITEF) ++ #AC_DEFINE(HAVE_FREXPF) ++ #AC_DEFINE(HAVE_HYPOTF) ++ AC_DEFINE(HAVE_ISINF) ++ AC_DEFINE(HAVE_ISINFF) ++ AC_DEFINE(HAVE_ISNAN) ++ AC_DEFINE(HAVE_ISNANF) ++ #AC_DEFINE(HAVE_SINCOS) ++ #AC_DEFINE(HAVE_SINCOSF) ++ #if test x"long_double_math_on_this_cpu" = x"yes"; then ++ #AC_DEFINE(HAVE_FINITEL) ++ #AC_DEFINE(HAVE_HYPOTL) ++ #AC_DEFINE(HAVE_ISINFL) ++ #AC_DEFINE(HAVE_ISNANL) ++ #fi ++ ;; + *-linux*) + os_include_dir="os/gnu-linux" + AC_CHECK_HEADERS([nan.h ieeefp.h endian.h sys/isa_defs.h \ +diff -urN gcc-3.3.3/libstdc++-v3/configure.target gcc-3.3.3-new/libstdc++-v3/configure.target +--- gcc-3.3.3/libstdc++-v3/configure.target 2003-10-01 14:07:07.000000000 -0500 ++++ gcc-3.3.3-new/libstdc++-v3/configure.target 2004-02-16 21:12:16.000000000 -0600 +@@ -133,6 +133,9 @@ + freebsd*) + os_include_dir="os/bsd/freebsd" + ;; ++ linux-uclibc*) ++ os_include_dir="os/uclibc" ++ ;; + gnu* | linux*) + os_include_dir="os/gnu-linux" + ;; +diff -urN gcc-3.3.3/libstdc++-v3/include/c_std/std_cstdlib.h gcc-3.3.3-new/libstdc++-v3/include/c_std/std_cstdlib.h +--- gcc-3.3.3/libstdc++-v3/include/c_std/std_cstdlib.h 2003-04-18 05:08:05.000000000 -0500 ++++ gcc-3.3.3-new/libstdc++-v3/include/c_std/std_cstdlib.h 2004-02-16 21:12:16.000000000 -0600 +@@ -101,9 +101,11 @@ + using ::labs; + using ::ldiv; + using ::malloc; ++#if _GLIBCPP_USE_WCHAR_T + using ::mblen; + using ::mbstowcs; + using ::mbtowc; ++#endif + using ::qsort; + using ::rand; + using ::realloc; +@@ -112,8 +114,10 @@ + using ::strtol; + using ::strtoul; + using ::system; ++#if _GLIBCPP_USE_WCHAR_T + using ::wcstombs; + using ::wctomb; ++#endif + + inline long + abs(long __i) { return labs(__i); } +diff -urN gcc-3.3.3/libstdc++-v3/include/c_std/std_cwchar.h gcc-3.3.3-new/libstdc++-v3/include/c_std/std_cwchar.h +--- gcc-3.3.3/libstdc++-v3/include/c_std/std_cwchar.h 2003-04-18 05:08:05.000000000 -0500 ++++ gcc-3.3.3-new/libstdc++-v3/include/c_std/std_cwchar.h 2004-02-16 21:12:16.000000000 -0600 +@@ -165,7 +165,9 @@ + using ::wcscoll; + using ::wcscpy; + using ::wcscspn; ++#ifdef HAVE_WCSFTIME + using ::wcsftime; ++#endif + using ::wcslen; + using ::wcsncat; + using ::wcsncmp; +diff -urN gcc-3.3.3/ltconfig gcc-3.3.3-new/ltconfig +--- gcc-3.3.3/ltconfig 2003-02-19 20:10:02.000000000 -0600 ++++ gcc-3.3.3-new/ltconfig 2004-02-16 21:12:16.000000000 -0600 +@@ -603,6 +603,7 @@ + # Transform linux* to *-*-linux-gnu*, to support old configure scripts. + case $host_os in + linux-gnu*) ;; ++linux-uclibc*) ;; + linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'` + esac + +@@ -1247,6 +1248,24 @@ + dynamic_linker='GNU/Linux ld.so' + ;; + ++linux-uclibc*) ++ version_type=linux ++ need_lib_prefix=no ++ need_version=no ++ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' ++ soname_spec='${libname}${release}.so$major' ++ finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' ++ shlibpath_var=LD_LIBRARY_PATH ++ shlibpath_overrides_runpath=no ++ # This implies no fast_install, which is unacceptable. ++ # Some rework will be needed to allow for fast_install ++ # before this can be enabled. ++ # Note: copied from linux-gnu, and may not be appropriate. ++ hardcode_into_libs=yes ++ # Assume using the uClibc dynamic linker. ++ dynamic_linker="uClibc ld.so" ++ ;; ++ + netbsd*) + need_lib_prefix=no + need_version=no diff --git a/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-110-conf.patch b/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-110-conf.patch new file mode 100644 index 000000000..f297c3283 --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-110-conf.patch @@ -0,0 +1,55 @@ +Use the patch by Carl Miller for powerpc, with +some minor modifications. Changed *os_uclibc to *os_linux_uclibc since +at some point we might support other platforms. Also updated to 3.3.3. +diff -urN gcc-3.3.3/gcc/config/rs6000/linux.h gcc-3.3.3-new/gcc/config/rs6000/linux.h +--- gcc-3.3.3/gcc/config/rs6000/linux.h 2003-11-14 00:46:10.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/rs6000/linux.h 2004-02-16 21:13:40.000000000 -0600 +@@ -64,7 +64,11 @@ + #define LINK_START_DEFAULT_SPEC "%(link_start_linux)" + + #undef LINK_OS_DEFAULT_SPEC ++#ifdef USE_UCLIBC ++#define LINK_OS_DEFAULT_SPEC "%(link_os_linux_uclibc)" ++#else + #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)" ++#endif + + #undef TARGET_VERSION + #define TARGET_VERSION fprintf (stderr, " (PowerPC GNU/Linux)"); +diff -urN gcc-3.3.3/gcc/config/rs6000/sysv4.h gcc-3.3.3-new/gcc/config/rs6000/sysv4.h +--- gcc-3.3.3/gcc/config/rs6000/sysv4.h 2003-10-28 13:55:41.000000000 -0600 ++++ gcc-3.3.3-new/gcc/config/rs6000/sysv4.h 2004-02-16 21:13:40.000000000 -0600 +@@ -968,9 +968,11 @@ + %{mcall-linux: %(link_os_linux) } \ + %{mcall-gnu: %(link_os_gnu) } \ + %{mcall-netbsd: %(link_os_netbsd) } \ ++%{mcall-uclibc: %(link_os_linux_uclibc) } \ + %{!mads: %{!myellowknife: %{!mmvme: %{!msim: %{!mwindiss: \ + %{!mcall-freebsd: %{!mcall-linux: %{!mcall-gnu: \ +- %{!mcall-netbsd: %(link_os_default) }}}}}}}}}" ++ %{!mcall-netbsd: %{!mcall-uclibc: \ ++ %(link_os_default) }}}}}}}}}}" + + #define LINK_OS_DEFAULT_SPEC "" + +@@ -1307,6 +1309,12 @@ + + #define LINK_OS_WINDISS_SPEC "" + ++/* uClibc support for Linux. */ ++ ++#define LINK_OS_LINUX_UCLIBC_SPEC "-m elf32ppclinux %{!shared: %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}}" ++ + /* Define any extra SPECS that the compiler needs to generate. */ + /* Override rs6000.h definition. */ + #undef SUBTARGET_EXTRA_SPECS +@@ -1372,6 +1380,7 @@ + { "link_os_netbsd", LINK_OS_NETBSD_SPEC }, \ + { "link_os_vxworks", LINK_OS_VXWORKS_SPEC }, \ + { "link_os_windiss", LINK_OS_WINDISS_SPEC }, \ ++ { "link_os_linux_uclibc", LINK_OS_LINUX_UCLIBC_SPEC }, \ + { "link_os_default", LINK_OS_DEFAULT_SPEC }, \ + { "cc1_endian_big", CC1_ENDIAN_BIG_SPEC }, \ + { "cc1_endian_little", CC1_ENDIAN_LITTLE_SPEC }, \ diff --git a/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-120-softfloat.patch b/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-120-softfloat.patch new file mode 100644 index 000000000..f2431896c --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-120-softfloat.patch @@ -0,0 +1,14 @@ +--- gcc-3.3.2-old/configure.in 2003-08-09 01:57:21.000000000 -0500 ++++ gcc-3.3.2/configure.in 2004-01-15 12:46:29.000000000 -0600 +@@ -1418,6 +1418,11 @@ + fi + + FLAGS_FOR_TARGET= ++case " $targargs " in ++ *" --nfp "* | *" --without-float "*) ++ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -msoft-float' ++ ;; ++esac + case " $target_configdirs " in + *" newlib "*) + case " $targargs " in diff --git a/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-200-code.patch b/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-200-code.patch new file mode 100644 index 000000000..5880d834b --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/gcc-uclibc-3.3-200-code.patch @@ -0,0 +1,3021 @@ +Warning! This patch is not finished. The wide char time-related stuff +is broken or non-functional. But it serves as a starting point to get +things building while I continue to work on the uClibc locale internals. +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/c++locale_internal.h gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/c++locale_internal.h +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/c++locale_internal.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/c++locale_internal.h 2004-01-09 07:55:02.000000000 -0600 +@@ -0,0 +1,63 @@ ++// Prototypes for GLIBC thread locale __-prefixed functions -*- C++ -*- ++ ++// Copyright (C) 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// Written by Jakub Jelinek ++ ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning clean this up ++#endif ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ ++extern "C" __typeof(iswctype_l) __iswctype_l; ++extern "C" __typeof(nl_langinfo_l) __nl_langinfo_l; ++extern "C" __typeof(strcoll_l) __strcoll_l; ++extern "C" __typeof(strftime_l) __strftime_l; ++extern "C" __typeof(strtod_l) __strtod_l; ++extern "C" __typeof(strtof_l) __strtof_l; ++extern "C" __typeof(strtold_l) __strtold_l; ++extern "C" __typeof(strtol_l) __strtol_l; ++extern "C" __typeof(strtoll_l) __strtoll_l; ++extern "C" __typeof(strtoul_l) __strtoul_l; ++extern "C" __typeof(strtoull_l) __strtoull_l; ++extern "C" __typeof(strxfrm_l) __strxfrm_l; ++extern "C" __typeof(towlower_l) __towlower_l; ++extern "C" __typeof(towupper_l) __towupper_l; ++extern "C" __typeof(wcscoll_l) __wcscoll_l; ++extern "C" __typeof(wcsftime_l) __wcsftime_l; ++extern "C" __typeof(wcsxfrm_l) __wcsxfrm_l; ++extern "C" __typeof(wctype_l) __wctype_l; ++extern "C" __typeof(newlocale) __newlocale; ++extern "C" __typeof(freelocale) __freelocale; ++extern "C" __typeof(duplocale) __duplocale; ++extern "C" __typeof(uselocale) __uselocale; ++ ++#endif // GLIBC 2.3 and later +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/c_locale.cc gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/c_locale.cc +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/c_locale.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/c_locale.cc 2004-01-09 08:37:55.000000000 -0600 +@@ -0,0 +1,231 @@ ++// Wrapper for underlying C-language localization -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.8 Standard locale categories. ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++#include ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __strtol_l(S, E, B, L) strtol((S), (E), (B)) ++#define __strtoul_l(S, E, B, L) strtoul((S), (E), (B)) ++#define __strtoll_l(S, E, B, L) strtoll((S), (E), (B)) ++#define __strtoull_l(S, E, B, L) strtoull((S), (E), (B)) ++#define __strtof_l(S, E, L) strtof((S), (E)) ++#define __strtod_l(S, E, L) strtod((S), (E)) ++#define __strtold_l(S, E, L) strtold((S), (E)) ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ __convert_to_v(const char* __s, long& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc, int __base) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ long __l = __strtol_l(__s, &__sanity, __base, __cloc); ++ if (__sanity != __s && *__sanity == '\0' && errno != ERANGE) ++ __v = __l; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, unsigned long& __v, ++ ios_base::iostate& __err, const __c_locale& __cloc, ++ int __base) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ unsigned long __ul = __strtoul_l(__s, &__sanity, __base, __cloc); ++ if (__sanity != __s && *__sanity == '\0' && errno != ERANGE) ++ __v = __ul; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++#ifdef _GLIBCPP_USE_LONG_LONG ++ template<> ++ void ++ __convert_to_v(const char* __s, long long& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc, int __base) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ long long __ll = __strtoll_l(__s, &__sanity, __base, __cloc); ++ if (__sanity != __s && *__sanity == '\0' && errno != ERANGE) ++ __v = __ll; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, unsigned long long& __v, ++ ios_base::iostate& __err, const __c_locale& __cloc, ++ int __base) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ unsigned long long __ull = __strtoull_l(__s, &__sanity, __base, ++ __cloc); ++ if (__sanity != __s && *__sanity == '\0' && errno != ERANGE) ++ __v = __ull; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++#endif ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, float& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc, int) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ float __f = __strtof_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && *__sanity == '\0' && errno != ERANGE) ++ __v = __f; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, double& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc, int) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ double __d = __strtod_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && *__sanity == '\0' && errno != ERANGE) ++ __v = __d; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, long double& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc, int) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ long double __ld = __strtold_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && *__sanity == '\0' && errno != ERANGE) ++ __v = __ld; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ void ++ locale::facet::_S_create_c_locale(__c_locale& __cloc, const char* __s, ++ __c_locale __old) ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __cloc = __newlocale(1 << LC_ALL, __s, __old); ++ if (!__cloc) ++ { ++ // This named locale is not supported by the underlying OS. ++ __throw_runtime_error("attempt to create locale from unknown name"); ++ } ++#else ++ __cloc = NULL; ++#endif ++ } ++ ++ void ++ locale::facet::_S_destroy_c_locale(__c_locale& __cloc) ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ if (_S_c_locale != __cloc) ++ __freelocale(__cloc); ++#else ++ __cloc = NULL; ++#endif ++ } ++ ++ __c_locale ++ locale::facet::_S_clone_c_locale(__c_locale& __cloc) ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ { return __duplocale(__cloc); } ++#else ++ { return __c_locale(); } ++#endif ++ ++ const char* locale::_S_categories[_S_categories_size ++ + _S_extra_categories_size] = ++ { ++ "LC_CTYPE", ++ "LC_NUMERIC", ++ "LC_TIME", ++ "LC_COLLATE", ++ "LC_MONETARY", ++ "LC_MESSAGES" ++#if _GLIBCPP_NUM_CATEGORIES != 0 ++ , ++ "LC_PAPER", ++ "LC_NAME", ++ "LC_ADDRESS", ++ "LC_TELEPHONE", ++ "LC_MEASUREMENT", ++ "LC_IDENTIFICATION" ++#endif ++ }; ++} // namespace std +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/c_locale.h gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/c_locale.h +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/c_locale.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/c_locale.h 2004-01-09 07:51:06.000000000 -0600 +@@ -0,0 +1,118 @@ ++// Wrapper for underlying C-language localization -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.8 Standard locale categories. ++// ++ ++// Written by Benjamin Kosnik ++ ++#ifndef _CPP_BITS_C_LOCALE_H ++#define _CPP_BITS_C_LOCALE_H 1 ++ ++#pragma GCC system_header ++ ++#include ++#include // For codecvt ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC_HAS_LOCALE__ ++#include // For codecvt using iconv, iconv_t ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++#include // For messages ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning what is _GLIBCPP_C_LOCALE_GNU for ++#endif ++#define _GLIBCPP_C_LOCALE_GNU 1 ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix categories ++#endif ++// #define _GLIBCPP_NUM_CATEGORIES 6 ++#define _GLIBCPP_NUM_CATEGORIES 0 ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++namespace __gnu_cxx ++{ ++ extern "C" __typeof(uselocale) __uselocale; ++} ++#endif ++ ++namespace std ++{ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ typedef __locale_t __c_locale; ++#else ++ typedef int* __c_locale; ++#endif ++ ++ // Convert numeric value of type _Tv to string and return length of ++ // string. If snprintf is available use it, otherwise fall back to ++ // the unsafe sprintf which, in general, can be dangerous and should ++ // be avoided. ++ template ++ int ++ __convert_from_v(char* __out, const int __size, const char* __fmt, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ _Tv __v, const __c_locale& __cloc, int __prec = -1) ++ { ++ __c_locale __old = __gnu_cxx::__uselocale(__cloc); ++#else ++ _Tv __v, const __c_locale&, int __prec = -1) ++ { ++# ifdef __UCLIBC_HAS_LOCALE__ ++ char* __old = setlocale(LC_ALL, NULL); ++ char* __sav = static_cast(malloc(strlen(__old) + 1)); ++ if (__sav) ++ strcpy(__sav, __old); ++ setlocale(LC_ALL, "C"); ++# endif ++#endif ++ ++ int __ret; ++ if (__prec >= 0) ++ __ret = snprintf(__out, __size, __fmt, __prec, __v); ++ else ++ __ret = snprintf(__out, __size, __fmt, __v); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __gnu_cxx::__uselocale(__old); ++#elif defined __UCLIBC_HAS_LOCALE__ ++ setlocale(LC_ALL, __sav); ++ free(__sav); ++#endif ++ return __ret; ++ } ++} ++ ++#endif +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/codecvt_members.cc gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/codecvt_members.cc +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/codecvt_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/codecvt_members.cc 2004-01-09 04:04:34.000000000 -0600 +@@ -0,0 +1,113 @@ ++// std::codecvt implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.1.5 - Template class codecvt ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++namespace std ++{ ++ // Specializations. ++#ifdef _GLIBCPP_USE_WCHAR_T ++ codecvt_base::result ++ codecvt:: ++ do_out(state_type& __state, const intern_type* __from, ++ const intern_type* __from_end, const intern_type*& __from_next, ++ extern_type* __to, extern_type* __to_end, ++ extern_type*& __to_next) const ++ { ++ result __ret = error; ++ size_t __len = min(__from_end - __from, __to_end - __to); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_S_c_locale); ++#endif ++ size_t __conv = wcsrtombs(__to, &__from, __len, &__state); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ if (__conv == __len) ++ { ++ __from_next = __from; ++ __to_next = __to + __conv; ++ __ret = ok; ++ } ++ else if (__conv > 0 && __conv < __len) ++ { ++ __from_next = __from; ++ __to_next = __to + __conv; ++ __ret = partial; ++ } ++ else ++ __ret = error; ++ ++ return __ret; ++ } ++ ++ codecvt_base::result ++ codecvt:: ++ do_in(state_type& __state, const extern_type* __from, ++ const extern_type* __from_end, const extern_type*& __from_next, ++ intern_type* __to, intern_type* __to_end, ++ intern_type*& __to_next) const ++ { ++ result __ret = error; ++ size_t __len = min(__from_end - __from, __to_end - __to); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_S_c_locale); ++#endif ++ size_t __conv = mbsrtowcs(__to, &__from, __len, &__state); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ if (__conv == __len) ++ { ++ __from_next = __from; ++ __to_next = __to + __conv; ++ __ret = ok; ++ } ++ else if (__conv > 0 && __conv < __len) ++ { ++ __from_next = __from; ++ __to_next = __to + __conv; ++ __ret = partial; ++ } ++ else ++ __ret = error; ++ ++ return __ret; ++ } ++#endif ++} +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/codecvt_specializations.h gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/codecvt_specializations.h +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/codecvt_specializations.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/codecvt_specializations.h 2004-01-09 01:53:51.000000000 -0600 +@@ -0,0 +1,461 @@ ++// Locale support (codecvt) -*- C++ -*- ++ ++// Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.1.5 Template class codecvt ++// ++ ++// Warning: this file is not meant for user inclusion. Use . ++ ++// Written by Benjamin Kosnik ++ ++ // XXX ++ // Define this here to codecvt.cc can have _S_max_size definition. ++#define _GLIBCPP_USE___ENC_TRAITS 1 ++ ++ // Extension to use icov for dealing with character encodings, ++ // including conversions and comparisons between various character ++ // sets. This object encapsulates data that may need to be shared between ++ // char_traits, codecvt and ctype. ++ class __enc_traits ++ { ++ public: ++ // Types: ++ // NB: A conversion descriptor subsumes and enhances the ++ // functionality of a simple state type such as mbstate_t. ++ typedef iconv_t __desc_type; ++ ++ protected: ++ // Data Members: ++ // Max size of charset encoding name ++ static const int _S_max_size = 32; ++ // Name of internal character set encoding. ++ char _M_int_enc[_S_max_size]; ++ // Name of external character set encoding. ++ char _M_ext_enc[_S_max_size]; ++ ++ // Conversion descriptor between external encoding to internal encoding. ++ __desc_type _M_in_desc; ++ // Conversion descriptor between internal encoding to external encoding. ++ __desc_type _M_out_desc; ++ ++ // Details the byte-order marker for the external encoding, if necessary. ++ int _M_ext_bom; ++ ++ // Details the byte-order marker for the internal encoding, if necessary. ++ int _M_int_bom; ++ ++ public: ++ explicit __enc_traits() ++ : _M_in_desc(0), _M_out_desc(0), _M_ext_bom(0), _M_int_bom(0) ++ { ++ memset(_M_int_enc, 0, _S_max_size); ++ memset(_M_ext_enc, 0, _S_max_size); ++ } ++ ++ explicit __enc_traits(const char* __int, const char* __ext, ++ int __ibom = 0, int __ebom = 0) ++ : _M_in_desc(0), _M_out_desc(0), _M_ext_bom(0), _M_int_bom(0) ++ { ++ strncpy(_M_int_enc, __int, _S_max_size); ++ strncpy(_M_ext_enc, __ext, _S_max_size); ++ } ++ ++ // 21.1.2 traits typedefs ++ // p4 ++ // typedef STATE_T state_type ++ // requires: state_type shall meet the requirements of ++ // CopyConstructible types (20.1.3) ++ __enc_traits(const __enc_traits& __obj): _M_in_desc(0), _M_out_desc(0) ++ { ++ strncpy(_M_int_enc, __obj._M_int_enc, _S_max_size); ++ strncpy(_M_ext_enc, __obj._M_ext_enc, _S_max_size); ++ _M_ext_bom = __obj._M_ext_bom; ++ _M_int_bom = __obj._M_int_bom; ++ } ++ ++ // Need assignment operator as well. ++ __enc_traits& ++ operator=(const __enc_traits& __obj) ++ { ++ strncpy(_M_int_enc, __obj._M_int_enc, _S_max_size); ++ strncpy(_M_ext_enc, __obj._M_ext_enc, _S_max_size); ++ _M_in_desc = 0; ++ _M_out_desc = 0; ++ _M_ext_bom = __obj._M_ext_bom; ++ _M_int_bom = __obj._M_int_bom; ++ return *this; ++ } ++ ++ ~__enc_traits() ++ { ++ __desc_type __err = reinterpret_cast(-1); ++ if (_M_in_desc && _M_in_desc != __err) ++ iconv_close(_M_in_desc); ++ if (_M_out_desc && _M_out_desc != __err) ++ iconv_close(_M_out_desc); ++ } ++ ++ void ++ _M_init() ++ { ++ const __desc_type __err = reinterpret_cast(-1); ++ if (!_M_in_desc) ++ { ++ _M_in_desc = iconv_open(_M_int_enc, _M_ext_enc); ++ if (_M_in_desc == __err) ++ __throw_runtime_error("creating iconv input descriptor failed."); ++ } ++ if (!_M_out_desc) ++ { ++ _M_out_desc = iconv_open(_M_ext_enc, _M_int_enc); ++ if (_M_out_desc == __err) ++ __throw_runtime_error("creating iconv output descriptor failed."); ++ } ++ } ++ ++ bool ++ _M_good() ++ { ++ const __desc_type __err = reinterpret_cast(-1); ++ bool __test = _M_in_desc && _M_in_desc != __err; ++ __test &= _M_out_desc && _M_out_desc != __err; ++ return __test; ++ } ++ ++ const __desc_type* ++ _M_get_in_descriptor() ++ { return &_M_in_desc; } ++ ++ const __desc_type* ++ _M_get_out_descriptor() ++ { return &_M_out_desc; } ++ ++ int ++ _M_get_external_bom() ++ { return _M_ext_bom; } ++ ++ int ++ _M_get_internal_bom() ++ { return _M_int_bom; } ++ ++ const char* ++ _M_get_internal_enc() ++ { return _M_int_enc; } ++ ++ const char* ++ _M_get_external_enc() ++ { return _M_ext_enc; } ++ }; ++ ++ // Partial specialization ++ // This specialization takes advantage of iconv to provide code ++ // conversions between a large number of character encodings. ++ template ++ class codecvt<_InternT, _ExternT, __enc_traits> ++ : public __codecvt_abstract_base<_InternT, _ExternT, __enc_traits> ++ { ++ public: ++ // Types: ++ typedef codecvt_base::result result; ++ typedef _InternT intern_type; ++ typedef _ExternT extern_type; ++ typedef __enc_traits state_type; ++ typedef __enc_traits::__desc_type __desc_type; ++ typedef __enc_traits __enc_type; ++ ++ // Data Members: ++ static locale::id id; ++ ++ explicit ++ codecvt(size_t __refs = 0) ++ : __codecvt_abstract_base(__refs) ++ { } ++ ++ explicit ++ codecvt(__enc_type* __enc, size_t __refs = 0) ++ : __codecvt_abstract_base(__refs) ++ { } ++ ++ protected: ++ virtual ++ ~codecvt() { } ++ ++ virtual result ++ do_out(state_type& __state, const intern_type* __from, ++ const intern_type* __from_end, const intern_type*& __from_next, ++ extern_type* __to, extern_type* __to_end, ++ extern_type*& __to_next) const; ++ ++ virtual result ++ do_unshift(state_type& __state, extern_type* __to, ++ extern_type* __to_end, extern_type*& __to_next) const; ++ ++ virtual result ++ do_in(state_type& __state, const extern_type* __from, ++ const extern_type* __from_end, const extern_type*& __from_next, ++ intern_type* __to, intern_type* __to_end, ++ intern_type*& __to_next) const; ++ ++ virtual int ++ do_encoding() const throw(); ++ ++ virtual bool ++ do_always_noconv() const throw(); ++ ++ virtual int ++ do_length(const state_type&, const extern_type* __from, ++ const extern_type* __end, size_t __max) const; ++ ++ virtual int ++ do_max_length() const throw(); ++ }; ++ ++ template ++ locale::id ++ codecvt<_InternT, _ExternT, __enc_traits>::id; ++ ++ // This adaptor works around the signature problems of the second ++ // argument to iconv(): SUSv2 and others use 'const char**', but glibc 2.2 ++ // uses 'char**', which matches the POSIX 1003.1-2001 standard. ++ // Using this adaptor, g++ will do the work for us. ++ template ++ inline size_t ++ __iconv_adaptor(size_t(*__func)(iconv_t, _T, size_t*, char**, size_t*), ++ iconv_t __cd, char** __inbuf, size_t* __inbytes, ++ char** __outbuf, size_t* __outbytes) ++ { return __func(__cd, (_T)__inbuf, __inbytes, __outbuf, __outbytes); } ++ ++ template ++ codecvt_base::result ++ codecvt<_InternT, _ExternT, __enc_traits>:: ++ do_out(state_type& __state, const intern_type* __from, ++ const intern_type* __from_end, const intern_type*& __from_next, ++ extern_type* __to, extern_type* __to_end, ++ extern_type*& __to_next) const ++ { ++ result __ret = codecvt_base::error; ++ if (__state._M_good()) ++ { ++ typedef state_type::__desc_type __desc_type; ++ const __desc_type* __desc = __state._M_get_out_descriptor(); ++ const size_t __fmultiple = sizeof(intern_type); ++ size_t __fbytes = __fmultiple * (__from_end - __from); ++ const size_t __tmultiple = sizeof(extern_type); ++ size_t __tbytes = __tmultiple * (__to_end - __to); ++ ++ // Argument list for iconv specifies a byte sequence. Thus, ++ // all to/from arrays must be brutally casted to char*. ++ char* __cto = reinterpret_cast(__to); ++ char* __cfrom; ++ size_t __conv; ++ ++ // Some encodings need a byte order marker as the first item ++ // in the byte stream, to designate endian-ness. The default ++ // value for the byte order marker is NULL, so if this is ++ // the case, it's not necessary and we can just go on our ++ // merry way. ++ int __int_bom = __state._M_get_internal_bom(); ++ if (__int_bom) ++ { ++ size_t __size = __from_end - __from; ++ intern_type* __cfixed = static_cast(__builtin_alloca(sizeof(intern_type) * (__size + 1))); ++ __cfixed[0] = static_cast(__int_bom); ++ char_traits::copy(__cfixed + 1, __from, __size); ++ __cfrom = reinterpret_cast(__cfixed); ++ __conv = __iconv_adaptor(iconv, *__desc, &__cfrom, ++ &__fbytes, &__cto, &__tbytes); ++ } ++ else ++ { ++ intern_type* __cfixed = const_cast(__from); ++ __cfrom = reinterpret_cast(__cfixed); ++ __conv = __iconv_adaptor(iconv, *__desc, &__cfrom, &__fbytes, ++ &__cto, &__tbytes); ++ } ++ ++ if (__conv != size_t(-1)) ++ { ++ __from_next = reinterpret_cast(__cfrom); ++ __to_next = reinterpret_cast(__cto); ++ __ret = codecvt_base::ok; ++ } ++ else ++ { ++ if (__fbytes < __fmultiple * (__from_end - __from)) ++ { ++ __from_next = reinterpret_cast(__cfrom); ++ __to_next = reinterpret_cast(__cto); ++ __ret = codecvt_base::partial; ++ } ++ else ++ __ret = codecvt_base::error; ++ } ++ } ++ return __ret; ++ } ++ ++ template ++ codecvt_base::result ++ codecvt<_InternT, _ExternT, __enc_traits>:: ++ do_unshift(state_type& __state, extern_type* __to, ++ extern_type* __to_end, extern_type*& __to_next) const ++ { ++ result __ret = codecvt_base::error; ++ if (__state._M_good()) ++ { ++ typedef state_type::__desc_type __desc_type; ++ const __desc_type* __desc = __state._M_get_in_descriptor(); ++ const size_t __tmultiple = sizeof(intern_type); ++ size_t __tlen = __tmultiple * (__to_end - __to); ++ ++ // Argument list for iconv specifies a byte sequence. Thus, ++ // all to/from arrays must be brutally casted to char*. ++ char* __cto = reinterpret_cast(__to); ++ size_t __conv = __iconv_adaptor(iconv,*__desc, NULL, NULL, ++ &__cto, &__tlen); ++ ++ if (__conv != size_t(-1)) ++ { ++ __to_next = reinterpret_cast(__cto); ++ if (__tlen == __tmultiple * (__to_end - __to)) ++ __ret = codecvt_base::noconv; ++ else if (__tlen == 0) ++ __ret = codecvt_base::ok; ++ else ++ __ret = codecvt_base::partial; ++ } ++ else ++ __ret = codecvt_base::error; ++ } ++ return __ret; ++ } ++ ++ template ++ codecvt_base::result ++ codecvt<_InternT, _ExternT, __enc_traits>:: ++ do_in(state_type& __state, const extern_type* __from, ++ const extern_type* __from_end, const extern_type*& __from_next, ++ intern_type* __to, intern_type* __to_end, ++ intern_type*& __to_next) const ++ { ++ result __ret = codecvt_base::error; ++ if (__state._M_good()) ++ { ++ typedef state_type::__desc_type __desc_type; ++ const __desc_type* __desc = __state._M_get_in_descriptor(); ++ const size_t __fmultiple = sizeof(extern_type); ++ size_t __flen = __fmultiple * (__from_end - __from); ++ const size_t __tmultiple = sizeof(intern_type); ++ size_t __tlen = __tmultiple * (__to_end - __to); ++ ++ // Argument list for iconv specifies a byte sequence. Thus, ++ // all to/from arrays must be brutally casted to char*. ++ char* __cto = reinterpret_cast(__to); ++ char* __cfrom; ++ size_t __conv; ++ ++ // Some encodings need a byte order marker as the first item ++ // in the byte stream, to designate endian-ness. The default ++ // value for the byte order marker is NULL, so if this is ++ // the case, it's not necessary and we can just go on our ++ // merry way. ++ int __ext_bom = __state._M_get_external_bom(); ++ if (__ext_bom) ++ { ++ size_t __size = __from_end - __from; ++ extern_type* __cfixed = static_cast(__builtin_alloca(sizeof(extern_type) * (__size + 1))); ++ __cfixed[0] = static_cast(__ext_bom); ++ char_traits::copy(__cfixed + 1, __from, __size); ++ __cfrom = reinterpret_cast(__cfixed); ++ __conv = __iconv_adaptor(iconv, *__desc, &__cfrom, ++ &__flen, &__cto, &__tlen); ++ } ++ else ++ { ++ extern_type* __cfixed = const_cast(__from); ++ __cfrom = reinterpret_cast(__cfixed); ++ __conv = __iconv_adaptor(iconv, *__desc, &__cfrom, ++ &__flen, &__cto, &__tlen); ++ } ++ ++ ++ if (__conv != size_t(-1)) ++ { ++ __from_next = reinterpret_cast(__cfrom); ++ __to_next = reinterpret_cast(__cto); ++ __ret = codecvt_base::ok; ++ } ++ else ++ { ++ if (__flen < static_cast(__from_end - __from)) ++ { ++ __from_next = reinterpret_cast(__cfrom); ++ __to_next = reinterpret_cast(__cto); ++ __ret = codecvt_base::partial; ++ } ++ else ++ __ret = codecvt_base::error; ++ } ++ } ++ return __ret; ++ } ++ ++ template ++ int ++ codecvt<_InternT, _ExternT, __enc_traits>:: ++ do_encoding() const throw() ++ { ++ int __ret = 0; ++ if (sizeof(_ExternT) <= sizeof(_InternT)) ++ __ret = sizeof(_InternT)/sizeof(_ExternT); ++ return __ret; ++ } ++ ++ template ++ bool ++ codecvt<_InternT, _ExternT, __enc_traits>:: ++ do_always_noconv() const throw() ++ { return false; } ++ ++ template ++ int ++ codecvt<_InternT, _ExternT, __enc_traits>:: ++ do_length(const state_type&, const extern_type* __from, ++ const extern_type* __end, size_t __max) const ++ { return min(__max, static_cast(__end - __from)); } ++ ++#ifdef _GLIBCPP_RESOLVE_LIB_DEFECTS ++// 74. Garbled text for codecvt::do_max_length ++ template ++ int ++ codecvt<_InternT, _ExternT, __enc_traits>:: ++ do_max_length() const throw() ++ { return 1; } ++#endif +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/collate_members.cc gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/collate_members.cc +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/collate_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/collate_members.cc 2004-01-09 08:06:24.000000000 -0600 +@@ -0,0 +1,80 @@ ++// std::collate implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.4.1.2 collate virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __strcoll_l(S1, S2, L) strcoll((S1), (S2)) ++#define __strxfrm_l(S1, S2, N, L) strxfrm((S1), (S2), (N)) ++#define __wcscoll_l(S1, S2, L) wcscoll((S1), (S2)) ++#define __wcsxfrm_l(S1, S2, N, L) wcsxfrm((S1), (S2), (N)) ++#endif ++ ++namespace std ++{ ++ // These are basically extensions to char_traits, and perhaps should ++ // be put there instead of here. ++ template<> ++ int ++ collate::_M_compare(const char* __one, const char* __two) const ++ { ++ int __cmp = __strcoll_l(__one, __two, _M_c_locale_collate); ++ return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0); ++ } ++ ++ template<> ++ size_t ++ collate::_M_transform(char* __to, const char* __from, ++ size_t __n) const ++ { return __strxfrm_l(__to, __from, __n, _M_c_locale_collate); } ++ ++#ifdef _GLIBCPP_USE_WCHAR_T ++ template<> ++ int ++ collate::_M_compare(const wchar_t* __one, ++ const wchar_t* __two) const ++ { ++ int __cmp = __wcscoll_l(__one, __two, _M_c_locale_collate); ++ return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0); ++ } ++ ++ template<> ++ size_t ++ collate::_M_transform(wchar_t* __to, const wchar_t* __from, ++ size_t __n) const ++ { return __wcsxfrm_l(__to, __from, __n, _M_c_locale_collate); } ++#endif ++} +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/ctype_members.cc gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/ctype_members.cc +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/ctype_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/ctype_members.cc 2004-01-09 08:15:41.000000000 -0600 +@@ -0,0 +1,274 @@ ++// std::ctype implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.1.1.2 ctype virtual functions. ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __wctype_l(S, L) wctype((S)) ++#define __towupper_l(C, L) towupper((C)) ++#define __towlower_l(C, L) towlower((C)) ++#define __iswctype_l(C, M, L) iswctype((C), (M)) ++#endif ++ ++namespace std ++{ ++ // NB: The other ctype specializations are in src/locale.cc and ++ // various /config/os/* files. ++ template<> ++ ctype_byname::ctype_byname(const char* __s, size_t __refs) ++ : ctype(0, false, __refs) ++ { ++ _S_destroy_c_locale(_M_c_locale_ctype); ++ _S_create_c_locale(_M_c_locale_ctype, __s); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_toupper = _M_c_locale_ctype->__ctype_toupper; ++ _M_tolower = _M_c_locale_ctype->__ctype_tolower; ++ _M_table = _M_c_locale_ctype->__ctype_b; ++#endif ++ } ++ ++#ifdef _GLIBCPP_USE_WCHAR_T ++ ctype::__wmask_type ++ ctype::_M_convert_to_wmask(const mask __m) const ++ { ++ __wmask_type __ret; ++ switch (__m) ++ { ++ case space: ++ __ret = __wctype_l("space", _M_c_locale_ctype); ++ break; ++ case print: ++ __ret = __wctype_l("print", _M_c_locale_ctype); ++ break; ++ case cntrl: ++ __ret = __wctype_l("cntrl", _M_c_locale_ctype); ++ break; ++ case upper: ++ __ret = __wctype_l("upper", _M_c_locale_ctype); ++ break; ++ case lower: ++ __ret = __wctype_l("lower", _M_c_locale_ctype); ++ break; ++ case alpha: ++ __ret = __wctype_l("alpha", _M_c_locale_ctype); ++ break; ++ case digit: ++ __ret = __wctype_l("digit", _M_c_locale_ctype); ++ break; ++ case punct: ++ __ret = __wctype_l("punct", _M_c_locale_ctype); ++ break; ++ case xdigit: ++ __ret = __wctype_l("xdigit", _M_c_locale_ctype); ++ break; ++ case alnum: ++ __ret = __wctype_l("alnum", _M_c_locale_ctype); ++ break; ++ case graph: ++ __ret = __wctype_l("graph", _M_c_locale_ctype); ++ break; ++ default: ++ __ret = 0; ++ } ++ return __ret; ++ }; ++ ++ wchar_t ++ ctype::do_toupper(wchar_t __c) const ++ { return __towupper_l(__c, _M_c_locale_ctype); } ++ ++ const wchar_t* ++ ctype::do_toupper(wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi) ++ { ++ *__lo = __towupper_l(*__lo, _M_c_locale_ctype); ++ ++__lo; ++ } ++ return __hi; ++ } ++ ++ wchar_t ++ ctype::do_tolower(wchar_t __c) const ++ { return __towlower_l(__c, _M_c_locale_ctype); } ++ ++ const wchar_t* ++ ctype::do_tolower(wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi) ++ { ++ *__lo = __towlower_l(*__lo, _M_c_locale_ctype); ++ ++__lo; ++ } ++ return __hi; ++ } ++ ++ bool ++ ctype:: ++ do_is(mask __m, wchar_t __c) const ++ { ++ // Highest bitmask in ctype_base == 10, but extra in "C" ++ // library for blank. ++ bool __ret = false; ++ const size_t __bitmasksize = 11; ++ for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur) ++ { ++ const mask __bit = static_cast(_ISbit(__bitcur)); ++ if (__m & __bit) ++ __ret |= __iswctype_l(__c, _M_convert_to_wmask(__bit), ++ _M_c_locale_ctype); ++ } ++ return __ret; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_is(const wchar_t* __lo, const wchar_t* __hi, mask* __vec) const ++ { ++ for (;__lo < __hi; ++__vec, ++__lo) ++ { ++ // Highest bitmask in ctype_base == 10, but extra in "C" ++ // library for blank. ++ const size_t __bitmasksize = 11; ++ mask __m = 0; ++ for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur) ++ { ++ const mask __bit = static_cast(_ISbit(__bitcur)); ++ if (__iswctype_l(*__lo, _M_convert_to_wmask(__bit), ++ _M_c_locale_ctype)) ++ __m |= __bit; ++ } ++ *__vec = __m; ++ } ++ return __hi; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_scan_is(mask __m, const wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi && !this->do_is(__m, *__lo)) ++ ++__lo; ++ return __lo; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_scan_not(mask __m, const char_type* __lo, const char_type* __hi) const ++ { ++ while (__lo < __hi && this->do_is(__m, *__lo) != 0) ++ ++__lo; ++ return __lo; ++ } ++ ++ wchar_t ++ ctype:: ++ do_widen(char __c) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ wchar_t __ret = btowc(__c); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __ret; ++ } ++ ++ const char* ++ ctype:: ++ do_widen(const char* __lo, const char* __hi, wchar_t* __dest) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ mbstate_t __state; ++ memset(static_cast(&__state), 0, sizeof(mbstate_t)); ++ mbsrtowcs(__dest, &__lo, __hi - __lo, &__state); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __hi; ++ } ++ ++ char ++ ctype:: ++ do_narrow(wchar_t __wc, char __dfault) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ int __c = wctob(__wc); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return (__c == EOF ? __dfault : static_cast(__c)); ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault, ++ char* __dest) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ size_t __offset = 0; ++ while (true) ++ { ++ const wchar_t* __start = __lo + __offset; ++ size_t __len = __hi - __start; ++ ++ mbstate_t __state; ++ memset(static_cast(&__state), 0, sizeof(mbstate_t)); ++ size_t __con = wcsrtombs(__dest + __offset, &__start, __len, &__state); ++ if (__con != __len && __start != 0) ++ { ++ __offset = __start - __lo; ++ __dest[__offset++] = __dfault; ++ } ++ else ++ break; ++ } ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __hi; ++ } ++#endif // _GLIBCPP_USE_WCHAR_T ++} +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/messages_members.cc gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/messages_members.cc +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/messages_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/messages_members.cc 2004-01-09 08:46:16.000000000 -0600 +@@ -0,0 +1,100 @@ ++// std::messages implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.7.1.2 messages virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix gettext stuff ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++extern "C" char *__dcgettext(const char *domainname, ++ const char *msgid, int category); ++#undef gettext ++#define gettext(msgid) __dcgettext(NULL, msgid, LC_MESSAGES) ++#else ++#undef gettext ++#define gettext(msgid) (msgid) ++#endif ++ ++namespace std ++{ ++ // Specializations. ++ template<> ++ string ++ messages::do_get(catalog, int, int, const string& __dfault) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_messages); ++ const char* __msg = const_cast(gettext(__dfault.c_str())); ++ __uselocale(__old); ++ return string(__msg); ++#elif defined __UCLIBC_HAS_LOCALE__ ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_messages); ++ const char* __msg = gettext(__dfault.c_str()); ++ setlocale(LC_ALL, __old); ++ free(__old); ++ return string(__msg); ++#else ++ const char* __msg = gettext(__dfault.c_str()); ++ return string(__msg); ++#endif ++ } ++ ++#ifdef _GLIBCPP_USE_WCHAR_T ++ template<> ++ wstring ++ messages::do_get(catalog, int, int, const wstring& __dfault) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_messages); ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ __uselocale(__old); ++ return _M_convert_from_char(__msg); ++#elif defined __UCLIBC_HAS_LOCALE__ ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_messages); ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ setlocale(LC_ALL, __old); ++ free(__old); ++ return _M_convert_from_char(__msg); ++# else ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ return _M_convert_from_char(__msg); ++# endif ++ } ++#endif ++} +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/messages_members.h gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/messages_members.h +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/messages_members.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/messages_members.h 2004-01-09 08:52:48.000000000 -0600 +@@ -0,0 +1,122 @@ ++// std::messages implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.7.1.2 messages functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix prototypes for *textdomain funcs ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++extern "C" char *__textdomain(const char *domainname); ++extern "C" char *__bindtextdomain(const char *domainname, ++ const char *dirname); ++#else ++#undef __textdomain ++#undef __bindtextdomain ++#define __textdomain(D) ((void)0) ++#define __bindtextdomain(D,P) ((void)0) ++#endif ++ ++ // Non-virtual member functions. ++ template ++ messages<_CharT>::messages(size_t __refs) ++ : locale::facet(__refs) ++ { ++#ifndef __UCLIBC_HAS_XLOCALE__ ++ _M_name_messages = _S_c_name; ++#endif ++ _M_c_locale_messages = _S_c_locale; ++ } ++ ++ template ++ messages<_CharT>::messages(__c_locale __cloc, ++ const char* __s, size_t __refs) ++ : locale::facet(__refs) ++ { ++#ifndef __UCLIBC_HAS_XLOCALE__ ++ _M_name_messages = new char[strlen(__s) + 1]; ++ strcpy(_M_name_messages, __s); ++#endif ++ _M_c_locale_messages = _S_clone_c_locale(__cloc); ++ } ++ ++ template ++ typename messages<_CharT>::catalog ++ messages<_CharT>::open(const basic_string& __s, const locale& __loc, ++ const char* __dir) const ++ { ++ __bindtextdomain(__s.c_str(), __dir); ++ return this->do_open(__s, __loc); ++ } ++ ++ // Virtual member functions. ++ template ++ messages<_CharT>::~messages() ++ { ++#ifndef __UCLIBC_HAS_XLOCALE__ ++ if (_S_c_name != _M_name_messages) ++ delete [] _M_name_messages; ++#endif ++ _S_destroy_c_locale(_M_c_locale_messages); ++ } ++ ++ template ++ typename messages<_CharT>::catalog ++ messages<_CharT>::do_open(const basic_string& __s, ++ const locale&) const ++ { ++ // No error checking is done, assume the catalog exists and can ++ // be used. ++ __textdomain(__s.c_str()); ++ return 0; ++ } ++ ++ template ++ void ++ messages<_CharT>::do_close(catalog) const ++ { } ++ ++ // messages_byname ++ template ++ messages_byname<_CharT>::messages_byname(const char* __s, size_t __refs) ++ : messages<_CharT>(__refs) ++ { ++#ifndef __UCLIBC_HAS_XLOCALE__ ++ if (_S_c_name != _M_name_messages) ++ delete [] _M_name_messages; ++ _M_name_messages = new char[strlen(__s) + 1]; ++ strcpy(_M_name_messages, __s); ++#endif ++ _S_destroy_c_locale(_M_c_locale_messages); ++ _S_create_c_locale(_M_c_locale_messages, __s); ++ } +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/monetary_members.cc gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/monetary_members.cc +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/monetary_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/monetary_members.cc 2004-01-09 18:20:23.000000000 -0600 +@@ -0,0 +1,578 @@ ++// std::moneypunct implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.6.3.2 moneypunct virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning optimize this for uclibc ++#warning tailor for stub locale support ++#endif ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ // Construct and return valid pattern consisting of some combination of: ++ // space none symbol sign value ++ money_base::pattern ++ money_base::_S_construct_pattern(char __precedes, char __space, char __posn) ++ { ++ pattern __ret; ++ ++ // This insanely complicated routine attempts to construct a valid ++ // pattern for use with monyepunct. A couple of invariants: ++ ++ // if (__precedes) symbol -> value ++ // else value -> symbol ++ ++ // if (__space) space ++ // else none ++ ++ // none == never first ++ // space never first or last ++ ++ // Any elegant implementations of this are welcome. ++ switch (__posn) ++ { ++ case 0: ++ case 1: ++ // 1 The sign precedes the value and symbol. ++ if (__space) ++ { ++ // Pattern starts with sign. ++ if (__precedes) ++ { ++ __ret.field[1] = symbol; ++ __ret.field[2] = space; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[1] = value; ++ __ret.field[2] = space; ++ __ret.field[3] = symbol; ++ } ++ __ret.field[0] = sign; ++ } ++ else ++ { ++ // Pattern starts with sign and ends with none. ++ if (__precedes) ++ { ++ __ret.field[1] = symbol; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[1] = value; ++ __ret.field[2] = symbol; ++ } ++ __ret.field[0] = sign; ++ __ret.field[3] = none; ++ } ++ break; ++ case 2: ++ // 2 The sign follows the value and symbol. ++ if (__space) ++ { ++ // Pattern either ends with sign. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = space; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[1] = space; ++ __ret.field[2] = symbol; ++ } ++ __ret.field[3] = sign; ++ } ++ else ++ { ++ // Pattern ends with sign then none. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[1] = symbol; ++ } ++ __ret.field[2] = sign; ++ __ret.field[3] = none; ++ } ++ break; ++ case 3: ++ // 3 The sign immediately precedes the symbol. ++ if (__space) ++ { ++ // Have space. ++ if (__precedes) ++ { ++ __ret.field[0] = sign; ++ __ret.field[1] = symbol; ++ __ret.field[2] = space; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[1] = space; ++ __ret.field[2] = sign; ++ __ret.field[3] = symbol; ++ } ++ } ++ else ++ { ++ // Have none. ++ if (__precedes) ++ { ++ __ret.field[0] = sign; ++ __ret.field[1] = symbol; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[1] = sign; ++ __ret.field[2] = symbol; ++ } ++ __ret.field[3] = none; ++ } ++ break; ++ case 4: ++ // 4 The sign immediately follows the symbol. ++ if (__space) ++ { ++ // Have space. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = sign; ++ __ret.field[2] = space; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[1] = space; ++ __ret.field[2] = symbol; ++ __ret.field[3] = sign; ++ } ++ } ++ else ++ { ++ // Have none. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = sign; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[1] = symbol; ++ __ret.field[2] = sign; ++ } ++ __ret.field[3] = none; ++ } ++ break; ++ default: ++ ; ++ } ++ return __ret; ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++ const char*) ++ { ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_decimal_point = '.'; ++ _M_thousands_sep = ','; ++ _M_grouping = ""; ++ _M_curr_symbol = ""; ++ _M_positive_sign = ""; ++ _M_negative_sign = ""; ++ _M_frac_digits = 0; ++ _M_pos_format = money_base::_S_default_pattern; ++ _M_neg_format = money_base::_S_default_pattern; ++ } ++ else ++ { ++ // Named locale. ++ _M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT, __cloc)); ++ _M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP, __cloc)); ++ _M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_positive_sign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ ++ char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc)); ++ if (!__nposn) ++ _M_negative_sign = "()"; ++ else ++ _M_negative_sign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ ++ // _Intl == true ++ _M_curr_symbol = __nl_langinfo_l(__INT_CURR_SYMBOL, __cloc); ++ _M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__INT_P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__INT_P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__INT_P_SIGN_POSN, __cloc)); ++ _M_pos_format = _S_construct_pattern(__pprecedes, __pspace, __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__INT_N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__INT_N_SEP_BY_SPACE, __cloc)); ++ _M_neg_format = _S_construct_pattern(__nprecedes, __nspace, __nposn); ++ } ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++ const char*) ++ { ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_decimal_point = '.'; ++ _M_thousands_sep = ','; ++ _M_grouping = ""; ++ _M_curr_symbol = ""; ++ _M_positive_sign = ""; ++ _M_negative_sign = ""; ++ _M_frac_digits = 0; ++ _M_pos_format = money_base::_S_default_pattern; ++ _M_neg_format = money_base::_S_default_pattern; ++ } ++ else ++ { ++ // Named locale. ++ _M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT, __cloc)); ++ _M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP, __cloc)); ++ _M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_positive_sign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ ++ char __nposn = *(__nl_langinfo_l(__N_SIGN_POSN, __cloc)); ++ if (!__nposn) ++ _M_negative_sign = "()"; ++ else ++ _M_negative_sign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ ++ // _Intl == false ++ _M_curr_symbol = __nl_langinfo_l(__CURRENCY_SYMBOL, __cloc); ++ _M_frac_digits = *(__nl_langinfo_l(__FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__P_SIGN_POSN, __cloc)); ++ _M_pos_format = _S_construct_pattern(__pprecedes, __pspace, __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__N_SEP_BY_SPACE, __cloc)); ++ _M_neg_format = _S_construct_pattern(__nprecedes, __nspace, __nposn); ++ } ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { } ++ ++#ifdef _GLIBCPP_USE_WCHAR_T ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const char*) ++#else ++ const char* __name) ++#endif ++ { ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_decimal_point = L'.'; ++ _M_thousands_sep = L','; ++ _M_grouping = ""; ++ _M_curr_symbol = L""; ++ _M_positive_sign = L""; ++ _M_negative_sign = L""; ++ _M_frac_digits = 0; ++ _M_pos_format = money_base::_S_default_pattern; ++ _M_neg_format = money_base::_S_default_pattern; ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(__cloc); ++#else ++ // Switch to named locale so that mbsrtowcs will work. ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, __name); ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_decimal_point = __cloc->decimal_point_wc; ++ _M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_decimal_point = __global_locale->decimal_point_wc; ++ _M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ _M_decimal_point = static_cast(((union { const char *__s; unsigned int __w; }){ __s: __nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc)}).__w); ++ ++ _M_thousands_sep = static_cast(((union { const char *__s; unsigned int __w; }){ __s: __nl_langinfo_l(_NL_NUMERIC_THOUSANDS_SEP_WC, __cloc)}).__w); ++#endif ++ _M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ ++ const char* __cpossign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ const char* __cnegsign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ const char* __ccurr = __nl_langinfo_l(__INT_CURR_SYMBOL, __cloc); ++ ++ mbstate_t __state; ++ size_t __len = strlen(__cpossign); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__cpossign, __len, &__state); ++ _M_positive_sign = __wcs; ++ } ++ else ++ _M_positive_sign = L""; ++ ++ char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc)); ++ __len = strlen(__cnegsign); ++ if (!__nposn) ++ _M_negative_sign = L"()"; ++ else if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__cnegsign, __len, &__state); ++ _M_negative_sign = __wcs; ++ } ++ else ++ _M_negative_sign = L""; ++ ++ // _Intl == true. ++ __len = strlen(__ccurr); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__ccurr, __len, &__state); ++ _M_curr_symbol = __wcs; ++ } ++ else ++ _M_curr_symbol = L""; ++ ++ _M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__INT_P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__INT_P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__INT_P_SIGN_POSN, __cloc)); ++ _M_pos_format = _S_construct_pattern(__pprecedes, __pspace, __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__INT_N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__INT_N_SEP_BY_SPACE, __cloc)); ++ _M_neg_format = _S_construct_pattern(__nprecedes, __nspace, __nposn); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const char*) ++#else ++ const char* __name) ++#endif ++ { ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_decimal_point = L'.'; ++ _M_thousands_sep = L','; ++ _M_grouping = ""; ++ _M_curr_symbol = L""; ++ _M_positive_sign = L""; ++ _M_negative_sign = L""; ++ _M_frac_digits = 0; ++ _M_pos_format = money_base::_S_default_pattern; ++ _M_neg_format = money_base::_S_default_pattern; ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(__cloc); ++#else ++ // Switch to named locale so that mbsrtowcs will work. ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, __name); ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_decimal_point = __cloc->decimal_point_wc; ++ _M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_decimal_point = __global_locale->decimal_point_wc; ++ _M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ _M_decimal_point = static_cast(((union { const char *__s; unsigned int __w; }){ __s: __nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc)}).__w); ++ _M_thousands_sep = static_cast(((union { const char *__s; unsigned int __w; }){ __s: __nl_langinfo_l(_NL_NUMERIC_THOUSANDS_SEP_WC, __cloc)}).__w); ++#endif ++ _M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ ++ const char* __cpossign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ const char* __cnegsign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ const char* __ccurr = __nl_langinfo_l(__CURRENCY_SYMBOL, __cloc); ++ ++ mbstate_t __state; ++ size_t __len; ++ __len = strlen(__cpossign); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__cpossign, __len, &__state); ++ _M_positive_sign = __wcs; ++ } ++ else ++ _M_positive_sign = L""; ++ ++ char __nposn = *(__nl_langinfo_l(__N_SIGN_POSN, __cloc)); ++ __len = strlen(__cnegsign); ++ if (!__nposn) ++ _M_negative_sign = L"()"; ++ else if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__cnegsign, __len, &__state); ++ _M_negative_sign = __wcs; ++ } ++ else ++ _M_negative_sign = L""; ++ ++ // _Intl == true. ++ __len = strlen(__ccurr); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__ccurr, __len, &__state); ++ _M_curr_symbol = __wcs; ++ } ++ else ++ _M_curr_symbol = L""; ++ ++ _M_frac_digits = *(__nl_langinfo_l(__FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__P_SIGN_POSN, __cloc)); ++ _M_pos_format = _S_construct_pattern(__pprecedes, __pspace, __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__N_SEP_BY_SPACE, __cloc)); ++ _M_neg_format = _S_construct_pattern(__nprecedes, __nspace, __nposn); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { ++ if (wcslen(_M_positive_sign)) ++ delete [] _M_positive_sign; ++ if (wcslen(_M_negative_sign) && (wcscmp(_M_negative_sign, L"()") != 0)) ++ delete [] _M_negative_sign; ++ if (wcslen(_M_curr_symbol)) ++ delete [] _M_curr_symbol; ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { ++ if (wcslen(_M_positive_sign)) ++ delete [] _M_positive_sign; ++ if (wcslen(_M_negative_sign) && (wcscmp(_M_negative_sign, L"()") != 0)) ++ delete [] _M_negative_sign; ++ if (wcslen(_M_curr_symbol)) ++ delete [] _M_curr_symbol; ++ } ++#endif ++} +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/numeric_members.cc gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/numeric_members.cc +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/numeric_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/numeric_members.cc 2004-01-09 18:20:59.000000000 -0600 +@@ -0,0 +1,129 @@ ++// std::numpunct implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.3.1.2 numpunct virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning tailor for stub locale support ++#endif ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ numpunct::_M_initialize_numpunct(__c_locale __cloc) ++ { ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_decimal_point = '.'; ++ _M_thousands_sep = ','; ++ _M_grouping = ""; ++ } ++ else ++ { ++ // Named locale. ++ _M_decimal_point = *(__nl_langinfo_l(RADIXCHAR, __cloc)); ++ _M_thousands_sep = *(__nl_langinfo_l(THOUSEP, __cloc)); ++ // Check for NUL, which implies no grouping. ++ if (_M_thousands_sep == '\0') ++ _M_grouping = ""; ++ else ++ _M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ } ++ // NB: There is no way to extact this info from posix locales. ++ // _M_truename = __nl_langinfo_l(YESSTR, __cloc); ++ _M_truename = "true"; ++ // _M_falsename = __nl_langinfo_l(NOSTR, __cloc); ++ _M_falsename = "false"; ++ } ++ ++ template<> ++ numpunct::~numpunct() ++ { } ++ ++#ifdef _GLIBCPP_USE_WCHAR_T ++ template<> ++ void ++ numpunct::_M_initialize_numpunct(__c_locale __cloc) ++ { ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_decimal_point = L'.'; ++ _M_thousands_sep = L','; ++ _M_grouping = ""; ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_decimal_point = __cloc->decimal_point_wc; ++ _M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_decimal_point = __global_locale->decimal_point_wc; ++ _M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ _M_decimal_point = static_cast(((union { const char *__s; unsigned int __w; }){ __s: __nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc)}).__w); ++ _M_thousands_sep = static_cast(((union { const char *__s; unsigned int __w; }){ __s: __nl_langinfo_l(_NL_NUMERIC_THOUSANDS_SEP_WC, __cloc)}).__w); ++#endif ++ if (_M_thousands_sep == L'\0') ++ _M_grouping = ""; ++ else ++ _M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ } ++ // NB: There is no way to extact this info from posix locales. ++ // _M_truename = __nl_langinfo_l(YESSTR, __cloc); ++ _M_truename = L"true"; ++ // _M_falsename = __nl_langinfo_l(NOSTR, __cloc); ++ _M_falsename = L"false"; ++ } ++ ++ template<> ++ numpunct::~numpunct() ++ { } ++ #endif ++} +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/time_members.cc gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/time_members.cc +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/time_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/time_members.cc 2004-01-09 08:25:03.000000000 -0600 +@@ -0,0 +1,341 @@ ++// std::time_get, std::time_put implementation, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.5.1.2 - time_get virtual functions ++// ISO C++ 14882: 22.2.5.3.2 - time_put virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning tailor for stub locale support ++#endif ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ __timepunct:: ++ _M_put(char* __s, size_t __maxlen, const char* __format, ++ const tm* __tm) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __strftime_l(__s, __maxlen, __format, __tm, _M_c_locale_timepunct); ++#else ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_timepunct); ++ strftime(__s, __maxlen, __format, __tm); ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ ++ template<> ++ void ++ __timepunct::_M_initialize_timepunct(__c_locale __cloc) ++ { ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_c_locale_timepunct = _S_c_locale; ++ ++ _M_date_format = "%m/%d/%y"; ++ _M_date_era_format = "%m/%d/%y"; ++ _M_time_format = "%H:%M:%S"; ++ _M_time_era_format = "%H:%M:%S"; ++ _M_date_time_format = ""; ++ _M_date_time_era_format = ""; ++ _M_am = "AM"; ++ _M_pm = "PM"; ++ _M_am_pm_format = ""; ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_day1 = "Sunday"; ++ _M_day2 = "Monday"; ++ _M_day3 = "Tuesday"; ++ _M_day4 = "Wednesday"; ++ _M_day5 = "Thursday"; ++ _M_day6 = "Friday"; ++ _M_day7 = "Saturday"; ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_day_a1 = "Sun"; ++ _M_day_a2 = "Mon"; ++ _M_day_a3 = "Tue"; ++ _M_day_a4 = "Wed"; ++ _M_day_a5 = "Thu"; ++ _M_day_a6 = "Fri"; ++ _M_day_a7 = "Sat"; ++ ++ // Month names, starting with "C"'s January. ++ _M_month01 = "January"; ++ _M_month02 = "February"; ++ _M_month03 = "March"; ++ _M_month04 = "April"; ++ _M_month05 = "May"; ++ _M_month06 = "June"; ++ _M_month07 = "July"; ++ _M_month08 = "August"; ++ _M_month09 = "September"; ++ _M_month10 = "October"; ++ _M_month11 = "November"; ++ _M_month12 = "December"; ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_month_a01 = "Jan"; ++ _M_month_a02 = "Feb"; ++ _M_month_a03 = "Mar"; ++ _M_month_a04 = "Apr"; ++ _M_month_a05 = "May"; ++ _M_month_a06 = "Jun"; ++ _M_month_a07 = "July"; ++ _M_month_a08 = "Aug"; ++ _M_month_a09 = "Sep"; ++ _M_month_a10 = "Oct"; ++ _M_month_a11 = "Nov"; ++ _M_month_a12 = "Dec"; ++ } ++ else ++ { ++ _M_c_locale_timepunct = _S_clone_c_locale(__cloc); ++ ++ _M_date_format = __nl_langinfo_l(D_FMT, __cloc); ++ _M_date_era_format = __nl_langinfo_l(ERA_D_FMT, __cloc); ++ _M_time_format = __nl_langinfo_l(T_FMT, __cloc); ++ _M_time_era_format = __nl_langinfo_l(ERA_T_FMT, __cloc); ++ _M_date_time_format = __nl_langinfo_l(D_T_FMT, __cloc); ++ _M_date_time_era_format = __nl_langinfo_l(ERA_D_T_FMT, __cloc); ++ _M_am = __nl_langinfo_l(AM_STR, __cloc); ++ _M_pm = __nl_langinfo_l(PM_STR, __cloc); ++ _M_am_pm_format = __nl_langinfo_l(T_FMT_AMPM, __cloc); ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_day1 = __nl_langinfo_l(DAY_1, __cloc); ++ _M_day2 = __nl_langinfo_l(DAY_2, __cloc); ++ _M_day3 = __nl_langinfo_l(DAY_3, __cloc); ++ _M_day4 = __nl_langinfo_l(DAY_4, __cloc); ++ _M_day5 = __nl_langinfo_l(DAY_5, __cloc); ++ _M_day6 = __nl_langinfo_l(DAY_6, __cloc); ++ _M_day7 = __nl_langinfo_l(DAY_7, __cloc); ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_day_a1 = __nl_langinfo_l(ABDAY_1, __cloc); ++ _M_day_a2 = __nl_langinfo_l(ABDAY_2, __cloc); ++ _M_day_a3 = __nl_langinfo_l(ABDAY_3, __cloc); ++ _M_day_a4 = __nl_langinfo_l(ABDAY_4, __cloc); ++ _M_day_a5 = __nl_langinfo_l(ABDAY_5, __cloc); ++ _M_day_a6 = __nl_langinfo_l(ABDAY_6, __cloc); ++ _M_day_a7 = __nl_langinfo_l(ABDAY_7, __cloc); ++ ++ // Month names, starting with "C"'s January. ++ _M_month01 = __nl_langinfo_l(MON_1, __cloc); ++ _M_month02 = __nl_langinfo_l(MON_2, __cloc); ++ _M_month03 = __nl_langinfo_l(MON_3, __cloc); ++ _M_month04 = __nl_langinfo_l(MON_4, __cloc); ++ _M_month05 = __nl_langinfo_l(MON_5, __cloc); ++ _M_month06 = __nl_langinfo_l(MON_6, __cloc); ++ _M_month07 = __nl_langinfo_l(MON_7, __cloc); ++ _M_month08 = __nl_langinfo_l(MON_8, __cloc); ++ _M_month09 = __nl_langinfo_l(MON_9, __cloc); ++ _M_month10 = __nl_langinfo_l(MON_10, __cloc); ++ _M_month11 = __nl_langinfo_l(MON_11, __cloc); ++ _M_month12 = __nl_langinfo_l(MON_12, __cloc); ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_month_a01 = __nl_langinfo_l(ABMON_1, __cloc); ++ _M_month_a02 = __nl_langinfo_l(ABMON_2, __cloc); ++ _M_month_a03 = __nl_langinfo_l(ABMON_3, __cloc); ++ _M_month_a04 = __nl_langinfo_l(ABMON_4, __cloc); ++ _M_month_a05 = __nl_langinfo_l(ABMON_5, __cloc); ++ _M_month_a06 = __nl_langinfo_l(ABMON_6, __cloc); ++ _M_month_a07 = __nl_langinfo_l(ABMON_7, __cloc); ++ _M_month_a08 = __nl_langinfo_l(ABMON_8, __cloc); ++ _M_month_a09 = __nl_langinfo_l(ABMON_9, __cloc); ++ _M_month_a10 = __nl_langinfo_l(ABMON_10, __cloc); ++ _M_month_a11 = __nl_langinfo_l(ABMON_11, __cloc); ++ _M_month_a12 = __nl_langinfo_l(ABMON_12, __cloc); ++ } ++ } ++ ++#ifdef _GLIBCPP_USE_WCHAR_T ++ template<> ++ void ++ __timepunct:: ++ _M_put(wchar_t* __s, size_t __maxlen, const wchar_t* __format, ++ const tm* __tm) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __wcsftime_l(__s, __maxlen, __format, __tm, _M_c_locale_timepunct); ++#else ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_timepunct); ++ wcsftime(__s, __maxlen, __format, __tm); ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ ++ template<> ++ void ++ __timepunct::_M_initialize_timepunct(__c_locale __cloc) ++ { ++#warning wide time stuff ++// if (!__cloc) ++ { ++ // "C" locale ++ _M_c_locale_timepunct = _S_c_locale; ++ ++ _M_date_format = L"%m/%d/%y"; ++ _M_date_era_format = L"%m/%d/%y"; ++ _M_time_format = L"%H:%M:%S"; ++ _M_time_era_format = L"%H:%M:%S"; ++ _M_date_time_format = L""; ++ _M_date_time_era_format = L""; ++ _M_am = L"AM"; ++ _M_pm = L"PM"; ++ _M_am_pm_format = L""; ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_day1 = L"Sunday"; ++ _M_day2 = L"Monday"; ++ _M_day3 = L"Tuesday"; ++ _M_day4 = L"Wednesday"; ++ _M_day5 = L"Thursday"; ++ _M_day6 = L"Friday"; ++ _M_day7 = L"Saturday"; ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_day_a1 = L"Sun"; ++ _M_day_a2 = L"Mon"; ++ _M_day_a3 = L"Tue"; ++ _M_day_a4 = L"Wed"; ++ _M_day_a5 = L"Thu"; ++ _M_day_a6 = L"Fri"; ++ _M_day_a7 = L"Sat"; ++ ++ // Month names, starting with "C"'s January. ++ _M_month01 = L"January"; ++ _M_month02 = L"February"; ++ _M_month03 = L"March"; ++ _M_month04 = L"April"; ++ _M_month05 = L"May"; ++ _M_month06 = L"June"; ++ _M_month07 = L"July"; ++ _M_month08 = L"August"; ++ _M_month09 = L"September"; ++ _M_month10 = L"October"; ++ _M_month11 = L"November"; ++ _M_month12 = L"December"; ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_month_a01 = L"Jan"; ++ _M_month_a02 = L"Feb"; ++ _M_month_a03 = L"Mar"; ++ _M_month_a04 = L"Apr"; ++ _M_month_a05 = L"May"; ++ _M_month_a06 = L"Jun"; ++ _M_month_a07 = L"July"; ++ _M_month_a08 = L"Aug"; ++ _M_month_a09 = L"Sep"; ++ _M_month_a10 = L"Oct"; ++ _M_month_a11 = L"Nov"; ++ _M_month_a12 = L"Dec"; ++ } ++#if 0 ++ else ++ { ++ _M_c_locale_timepunct = _S_clone_c_locale(__cloc); ++ ++ _M_date_format = reinterpret_cast(__nl_langinfo_l(_NL_WD_FMT, __cloc)); ++ _M_date_era_format = reinterpret_cast(__nl_langinfo_l(_NL_WERA_D_FMT, __cloc)); ++ _M_time_format = reinterpret_cast(__nl_langinfo_l(_NL_WT_FMT, __cloc)); ++ _M_time_era_format = reinterpret_cast(__nl_langinfo_l(_NL_WERA_T_FMT, __cloc)); ++ _M_date_time_format = reinterpret_cast(__nl_langinfo_l(_NL_WD_T_FMT, __cloc)); ++ _M_date_time_era_format = reinterpret_cast(__nl_langinfo_l(_NL_WERA_D_T_FMT, __cloc)); ++ _M_am = reinterpret_cast(__nl_langinfo_l(_NL_WAM_STR, __cloc)); ++ _M_pm = reinterpret_cast(__nl_langinfo_l(_NL_WPM_STR, __cloc)); ++ _M_am_pm_format = reinterpret_cast(__nl_langinfo_l(_NL_WT_FMT_AMPM, __cloc)); ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_day1 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_1, __cloc)); ++ _M_day2 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_2, __cloc)); ++ _M_day3 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_3, __cloc)); ++ _M_day4 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_4, __cloc)); ++ _M_day5 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_5, __cloc)); ++ _M_day6 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_6, __cloc)); ++ _M_day7 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_7, __cloc)); ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_day_a1 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_1, __cloc)); ++ _M_day_a2 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_2, __cloc)); ++ _M_day_a3 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_3, __cloc)); ++ _M_day_a4 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_4, __cloc)); ++ _M_day_a5 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_5, __cloc)); ++ _M_day_a6 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_6, __cloc)); ++ _M_day_a7 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_7, __cloc)); ++ ++ // Month names, starting with "C"'s January. ++ _M_month01 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_1, __cloc)); ++ _M_month02 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_2, __cloc)); ++ _M_month03 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_3, __cloc)); ++ _M_month04 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_4, __cloc)); ++ _M_month05 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_5, __cloc)); ++ _M_month06 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_6, __cloc)); ++ _M_month07 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_7, __cloc)); ++ _M_month08 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_8, __cloc)); ++ _M_month09 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_9, __cloc)); ++ _M_month10 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_10, __cloc)); ++ _M_month11 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_11, __cloc)); ++ _M_month12 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_12, __cloc)); ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_month_a01 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_1, __cloc)); ++ _M_month_a02 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_2, __cloc)); ++ _M_month_a03 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_3, __cloc)); ++ _M_month_a04 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_4, __cloc)); ++ _M_month_a05 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_5, __cloc)); ++ _M_month_a06 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_6, __cloc)); ++ _M_month_a07 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_7, __cloc)); ++ _M_month_a08 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_8, __cloc)); ++ _M_month_a09 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_9, __cloc)); ++ _M_month_a10 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_10, __cloc)); ++ _M_month_a11 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_11, __cloc)); ++ _M_month_a12 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_12, __cloc)); ++ } ++#endif // 0 ++ } ++#endif ++} +diff -urN gcc-3.3.2/libstdc++-v3/config/locale/uclibc/time_members.h gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/time_members.h +--- gcc-3.3.2/libstdc++-v3/config/locale/uclibc/time_members.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/locale/uclibc/time_members.h 2004-01-09 04:26:21.000000000 -0600 +@@ -0,0 +1,68 @@ ++// std::time_get, std::time_put implementation, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.5.1.2 - time_get functions ++// ISO C++ 14882: 22.2.5.3.2 - time_put functions ++// ++ ++// Written by Benjamin Kosnik ++ ++ template ++ __timepunct<_CharT>::__timepunct(size_t __refs) ++ : locale::facet(__refs) ++ { ++#ifndef __UCLIBC_HAS_XLOCALE__ ++ _M_name_timepunct = _S_c_name; ++#endif ++ _M_initialize_timepunct(); ++ } ++ ++ template ++ __timepunct<_CharT>::__timepunct(__c_locale __cloc, ++ const char* __s, ++ size_t __refs) ++ : locale::facet(__refs) ++ { ++#ifndef __UCLIBC_HAS_XLOCALE__ ++ _M_name_timepunct = new char[strlen(__s) + 1]; ++ strcpy(_M_name_timepunct, __s); ++#endif ++ _M_initialize_timepunct(__cloc); ++ } ++ ++ template ++ __timepunct<_CharT>::~__timepunct() ++ { ++#ifndef __UCLIBC_HAS_XLOCALE__ ++ if (_S_c_name != _M_name_timepunct) ++ delete [] _M_name_timepunct; ++#endif ++ _S_destroy_c_locale(_M_c_locale_timepunct); ++ } +diff -urN gcc-3.3.2/libstdc++-v3/config/os/uclibc/ctype_base.h gcc-3.3.2-uClibc/libstdc++-v3/config/os/uclibc/ctype_base.h +--- gcc-3.3.2/libstdc++-v3/config/os/uclibc/ctype_base.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/os/uclibc/ctype_base.h 2004-01-09 02:54:54.000000000 -0600 +@@ -0,0 +1,57 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 1997, 1998, 1999, 2000, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// Information as gleaned from /usr/include/ctype.h ++ ++ struct ctype_base ++ { ++ // Note: In uClibc, the following two types depend on configuration. ++ ++ // Non-standard typedefs. ++ typedef const __ctype_touplow_t* __to_type; ++ // NB: Offsets into ctype::_M_table force a particular size ++ // on the mask type. Because of this, we don't use an enum. ++ typedef __ctype_mask_t mask; ++ ++ static const mask upper = _ISupper; ++ static const mask lower = _ISlower; ++ static const mask alpha = _ISalpha; ++ static const mask digit = _ISdigit; ++ static const mask xdigit = _ISxdigit; ++ static const mask space = _ISspace; ++ static const mask print = _ISprint; ++ static const mask graph = _ISgraph; ++ static const mask cntrl = _IScntrl; ++ static const mask punct = _ISpunct; ++ static const mask alnum = _ISalnum; ++ }; +diff -urN gcc-3.3.2/libstdc++-v3/config/os/uclibc/ctype_inline.h gcc-3.3.2-uClibc/libstdc++-v3/config/os/uclibc/ctype_inline.h +--- gcc-3.3.2/libstdc++-v3/config/os/uclibc/ctype_inline.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/os/uclibc/ctype_inline.h 2002-06-24 00:49:19.000000000 -0500 +@@ -0,0 +1,69 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 2000, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*) ++// functions go in ctype.cc ++ ++ bool ++ ctype:: ++ is(mask __m, char __c) const ++ { return _M_table[static_cast(__c)] & __m; } ++ ++ const char* ++ ctype:: ++ is(const char* __low, const char* __high, mask* __vec) const ++ { ++ while (__low < __high) ++ *__vec++ = _M_table[static_cast(*__low++)]; ++ return __high; ++ } ++ ++ const char* ++ ctype:: ++ scan_is(mask __m, const char* __low, const char* __high) const ++ { ++ while (__low < __high ++ && !(_M_table[static_cast(*__low)] & __m)) ++ ++__low; ++ return __low; ++ } ++ ++ const char* ++ ctype:: ++ scan_not(mask __m, const char* __low, const char* __high) const ++ { ++ while (__low < __high ++ && (_M_table[static_cast(*__low)] & __m) != 0) ++ ++__low; ++ return __low; ++ } +diff -urN gcc-3.3.2/libstdc++-v3/config/os/uclibc/ctype_noninline.h gcc-3.3.2-uClibc/libstdc++-v3/config/os/uclibc/ctype_noninline.h +--- gcc-3.3.2/libstdc++-v3/config/os/uclibc/ctype_noninline.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/os/uclibc/ctype_noninline.h 2004-01-09 03:34:53.000000000 -0600 +@@ -0,0 +1,90 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 ++// Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// Information as gleaned from /usr/include/ctype.h ++ ++ const ctype_base::mask* ++ ctype::classic_table() throw() ++ { ++ return __C_ctype_b; ++ } ++ ++ ctype::ctype(__c_locale, const mask* __table, bool __del, ++ size_t __refs) ++ : __ctype_abstract_base(__refs), _M_del(__table != 0 && __del) ++ { ++ _M_toupper = __C_ctype_toupper; ++ _M_tolower = __C_ctype_tolower; ++ _M_table = __table ? __table : __C_ctype_b; ++ _M_c_locale_ctype = _S_c_locale; ++ } ++ ++ ctype::ctype(const mask* __table, bool __del, size_t __refs) : ++ __ctype_abstract_base(__refs), _M_del(__table != 0 && __del) ++ { ++ _M_toupper = __C_ctype_toupper; ++ _M_tolower = __C_ctype_tolower; ++ _M_table = __table ? __table : __C_ctype_b; ++ _M_c_locale_ctype = _S_c_locale; ++ } ++ ++ char ++ ctype::do_toupper(char __c) const ++ { return _M_toupper[static_cast(__c)]; } ++ ++ const char* ++ ctype::do_toupper(char* __low, const char* __high) const ++ { ++ while (__low < __high) ++ { ++ *__low = _M_toupper[static_cast(*__low)]; ++ ++__low; ++ } ++ return __high; ++ } ++ ++ char ++ ctype::do_tolower(char __c) const ++ { return _M_tolower[static_cast(__c)]; } ++ ++ const char* ++ ctype::do_tolower(char* __low, const char* __high) const ++ { ++ while (__low < __high) ++ { ++ *__low = _M_tolower[static_cast(*__low)]; ++ ++__low; ++ } ++ return __high; ++ } +diff -urN gcc-3.3.2/libstdc++-v3/config/os/uclibc/os_defines.h gcc-3.3.2-uClibc/libstdc++-v3/config/os/uclibc/os_defines.h +--- gcc-3.3.2/libstdc++-v3/config/os/uclibc/os_defines.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.3.2-uClibc/libstdc++-v3/config/os/uclibc/os_defines.h 2004-01-09 04:56:13.000000000 -0600 +@@ -0,0 +1,56 @@ ++// Specific definitions for GNU/Linux -*- C++ -*- ++ ++// Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++#ifndef _GLIBCPP_OS_DEFINES ++#define _GLIBCPP_OS_DEFINES 1 ++ ++// System-specific #define, typedefs, corrections, etc, go here. This ++// file will come before all others. ++ ++// This keeps isanum, et al from being propagated as macros. ++#define __NO_CTYPE 1 ++ ++#include ++ ++// These systems have declarations mismatching those in libio.h by ++// omitting throw qualifiers. Cleanest way out is to not provide ++// throw-qualifiers at all. Defining it as empty here will make libio.h ++// not define it. ++#undef __THROW ++#define __THROW ++ ++// Tell Glibc not to try to provide its own inline versions of ++// some math functions. Those cause assembly-time clashes with ++// our definitions. ++#define __NO_MATH_INLINES ++ ++// We must not see the optimized string functions GNU libc defines. ++#define __NO_STRING_INLINES ++ ++#endif diff --git a/meta/packages/gcc/gcc-3.3.4/gcc34-15089.patch b/meta/packages/gcc/gcc-3.3.4/gcc34-15089.patch new file mode 100644 index 000000000..3b7a056e6 --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/gcc34-15089.patch @@ -0,0 +1,19 @@ +2004-04-29 Philip Blundell + + * loop.c (scan_loop): Don't delete SET of a hard register. + +Index: loop.c +=================================================================== +RCS file: /cvs/gcc/gcc/gcc/loop.c,v +retrieving revision 1.488.2.3 +diff -u -r1.488.2.3 loop.c +--- gcc/gcc/loop.c 14 Feb 2004 14:46:03 -0000 1.488.2.3 ++++ gcc/gcc/loop.c 28 Apr 2004 22:02:53 -0000 +@@ -929,6 +929,7 @@ + || (! (GET_CODE (SET_SRC (set)) == REG + && (REGNO (SET_SRC (set)) + < FIRST_PSEUDO_REGISTER)))) ++ && regno >= FIRST_PSEUDO_REGISTER + /* This test is not redundant; SET_SRC (set) might be + a call-clobbered register and the life of REGNO + might span a call. */ diff --git a/meta/packages/gcc/gcc-3.3.4/libibery-crosstool.patch b/meta/packages/gcc/gcc-3.3.4/libibery-crosstool.patch new file mode 100644 index 000000000..2898cf18f --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/libibery-crosstool.patch @@ -0,0 +1,683 @@ +diff -urN gcc-3.3.3.orig/libiberty/configure gcc-3.3.3/libiberty/configure +--- gcc-3.3.3.orig/libiberty/configure 2003-11-12 12:32:29.000000000 -0500 ++++ gcc-3.3.3/libiberty/configure 2004-04-09 23:04:23.000000000 -0400 +@@ -1000,13 +1000,60 @@ + fi + + ++echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 ++echo "configure:1005: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ++ ++ac_ext=c ++# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. ++ac_cpp='$CPP $CPPFLAGS' ++ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' ++ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' ++cross_compiling=$ac_cv_prog_cc_cross ++ ++cat > conftest.$ac_ext << EOF ++ ++#line 1016 "configure" ++#include "confdefs.h" ++ ++main(){return(0);} ++EOF ++if { (eval echo configure:1021: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ ac_cv_prog_cc_works=yes ++ # If we can't run a trivial program, we are probably using a cross compiler. ++ if (./conftest; exit) 2>/dev/null; then ++ ac_cv_prog_cc_cross=no ++ else ++ ac_cv_prog_cc_cross=yes ++ fi ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ ac_cv_prog_cc_works=no ++fi ++rm -fr conftest* ++ac_ext=c ++# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. ++ac_cpp='$CPP $CPPFLAGS' ++ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' ++ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' ++cross_compiling=$ac_cv_prog_cc_cross ++ ++echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 ++if test $ac_cv_prog_cc_works = no; then ++ { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } ++fi ++echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 ++echo "configure:1047: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 ++echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 ++cross_compiling=$ac_cv_prog_cc_cross ++ + + if test "x$CC" != xcc; then + echo $ac_n "checking whether $CC and cc understand -c and -o together""... $ac_c" 1>&6 +-echo "configure:1007: checking whether $CC and cc understand -c and -o together" >&5 ++echo "configure:1054: checking whether $CC and cc understand -c and -o together" >&5 + else + echo $ac_n "checking whether cc understands -c and -o together""... $ac_c" 1>&6 +-echo "configure:1010: checking whether cc understands -c and -o together" >&5 ++echo "configure:1057: checking whether cc understands -c and -o together" >&5 + fi + set dummy $CC; ac_cc="`echo $2 | + sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`" +@@ -1018,16 +1065,16 @@ + # We do the test twice because some compilers refuse to overwrite an + # existing .o file with -o, though they will create one. + ac_try='${CC-cc} -c conftest.c -o conftest.o 1>&5' +-if { (eval echo configure:1022: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } && +- test -f conftest.o && { (eval echo configure:1023: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; ++if { (eval echo configure:1069: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } && ++ test -f conftest.o && { (eval echo configure:1070: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; + then + eval ac_cv_prog_cc_${ac_cc}_c_o=yes + if test "x$CC" != xcc; then + # Test first that cc exists at all. +- if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:1028: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then ++ if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:1075: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then + ac_try='cc -c conftest.c -o conftest.o 1>&5' +- if { (eval echo configure:1030: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } && +- test -f conftest.o && { (eval echo configure:1031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; ++ if { (eval echo configure:1077: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } && ++ test -f conftest.o && { (eval echo configure:1078: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; + then + # cc works too. + : +@@ -1063,7 +1110,7 @@ + + + echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6 +-echo "configure:1067: checking for POSIXized ISC" >&5 ++echo "configure:1114: checking for POSIXized ISC" >&5 + if test -d /etc/conf/kconfig.d && + grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1 + then +@@ -1084,12 +1131,12 @@ + fi + + echo $ac_n "checking for working const""... $ac_c" 1>&6 +-echo "configure:1088: checking for working const" >&5 ++echo "configure:1135: checking for working const" >&5 + if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1189: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_const=yes + else +@@ -1159,21 +1206,21 @@ + fi + + echo $ac_n "checking for inline""... $ac_c" 1>&6 +-echo "configure:1163: checking for inline" >&5 ++echo "configure:1210: checking for inline" >&5 + if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + ac_cv_c_inline=no + for ac_kw in inline __inline__ __inline; do + cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1224: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_inline=$ac_kw; break + else +@@ -1216,7 +1263,7 @@ + # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" + # ./install, which can be erroneously created by make from ./install.sh. + echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 +-echo "configure:1220: checking for a BSD compatible install" >&5 ++echo "configure:1267: checking for a BSD compatible install" >&5 + if test -z "$INSTALL"; then + if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +@@ -1277,7 +1324,7 @@ + # able to link anything, it had better be able to at least compile + # something. + echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 +-echo "configure:1281: checking how to run the C preprocessor" >&5 ++echo "configure:1328: checking how to run the C preprocessor" >&5 + # On Suns, sometimes $CPP names a directory. + if test -n "$CPP" && test -d "$CPP"; then + CPP= +@@ -1292,13 +1339,13 @@ + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. + cat > conftest.$ac_ext < + Syntax Error + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1302: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1349: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + : +@@ -1309,13 +1356,13 @@ + rm -rf conftest* + CPP="${CC-cc} -E -traditional-cpp" + cat > conftest.$ac_ext < + Syntax Error + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1319: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1366: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + : +@@ -1326,13 +1373,13 @@ + rm -rf conftest* + CPP="${CC-cc} -nologo -E" + cat > conftest.$ac_ext < + Syntax Error + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1336: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1383: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + : +@@ -1360,17 +1407,17 @@ + do + ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` + echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +-echo "configure:1364: checking for $ac_hdr" >&5 ++echo "configure:1411: checking for $ac_hdr" >&5 + if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1374: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1421: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + rm -rf conftest* +@@ -1397,12 +1444,12 @@ + done + + echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6 +-echo "configure:1401: checking for sys/wait.h that is POSIX.1 compatible" >&5 ++echo "configure:1448: checking for sys/wait.h that is POSIX.1 compatible" >&5 + if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #include +@@ -1418,7 +1465,7 @@ + s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; + ; return 0; } + EOF +-if { (eval echo configure:1422: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1469: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_header_sys_wait_h=yes + else +@@ -1439,12 +1486,12 @@ + fi + + echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 +-echo "configure:1443: checking whether time.h and sys/time.h may both be included" >&5 ++echo "configure:1490: checking whether time.h and sys/time.h may both be included" >&5 + if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #include +@@ -1453,7 +1500,7 @@ + struct tm *tp; + ; return 0; } + EOF +-if { (eval echo configure:1457: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1504: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_header_time=yes + else +@@ -1475,19 +1522,19 @@ + + + echo $ac_n "checking whether errno must be declared""... $ac_c" 1>&6 +-echo "configure:1479: checking whether errno must be declared" >&5 ++echo "configure:1526: checking whether errno must be declared" >&5 + if eval "test \"`echo '$''{'libiberty_cv_declare_errno'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + int main() { + int x = errno; + ; return 0; } + EOF +-if { (eval echo configure:1491: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1538: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + libiberty_cv_declare_errno=no + else +@@ -1509,12 +1556,12 @@ + + + echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 +-echo "configure:1513: checking for ANSI C header files" >&5 ++echo "configure:1560: checking for ANSI C header files" >&5 + if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #include +@@ -1522,7 +1569,7 @@ + #include + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1526: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1573: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + rm -rf conftest* +@@ -1539,7 +1586,7 @@ + if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat > conftest.$ac_ext < + EOF +@@ -1557,7 +1604,7 @@ + if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat > conftest.$ac_ext < + EOF +@@ -1578,7 +1625,7 @@ + : + else + cat > conftest.$ac_ext < + #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +@@ -1589,7 +1636,7 @@ + exit (0); } + + EOF +-if { (eval echo configure:1593: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null ++if { (eval echo configure:1640: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null + then + : + else +@@ -1613,12 +1660,12 @@ + fi + + echo $ac_n "checking for uintptr_t""... $ac_c" 1>&6 +-echo "configure:1617: checking for uintptr_t" >&5 ++echo "configure:1664: checking for uintptr_t" >&5 + if eval "test \"`echo '$''{'ac_cv_type_uintptr_t'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #if STDC_HEADERS +@@ -1654,12 +1701,12 @@ + + + echo $ac_n "checking for pid_t""... $ac_c" 1>&6 +-echo "configure:1658: checking for pid_t" >&5 ++echo "configure:1705: checking for pid_t" >&5 + if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #if STDC_HEADERS +@@ -1746,12 +1793,12 @@ + for ac_func in asprintf atexit basename bcmp bcopy bsearch bzero calloc clock + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:1750: checking for $ac_func" >&5 ++echo "configure:1797: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:1825: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -1801,12 +1848,12 @@ + for ac_func in getcwd getpagesize index insque mkstemps memchr memcmp memcpy + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:1805: checking for $ac_func" >&5 ++echo "configure:1852: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:1880: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -1856,12 +1903,12 @@ + for ac_func in memmove memset putenv random rename rindex sigsetmask + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:1860: checking for $ac_func" >&5 ++echo "configure:1907: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:1935: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -1911,12 +1958,12 @@ + for ac_func in strcasecmp setenv strchr strdup strncasecmp strrchr strstr + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:1915: checking for $ac_func" >&5 ++echo "configure:1962: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:1990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -1966,12 +2013,12 @@ + for ac_func in strtod strtol strtoul tmpnam vasprintf vfprintf vprintf + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:1970: checking for $ac_func" >&5 ++echo "configure:2017: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:2045: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -2021,12 +2068,12 @@ + for ac_func in vsprintf waitpid getrusage on_exit psignal strerror strsignal + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:2025: checking for $ac_func" >&5 ++echo "configure:2072: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:2100: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -2076,12 +2123,12 @@ + for ac_func in sysconf times sbrk gettimeofday ffs + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:2080: checking for $ac_func" >&5 ++echo "configure:2127: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:2155: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -2131,12 +2178,12 @@ + for ac_func in realpath canonicalize_file_name + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:2135: checking for $ac_func" >&5 ++echo "configure:2182: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:2210: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -2186,12 +2233,12 @@ + for ac_func in pstat_getstatic pstat_getdynamic sysmp getsysinfo table sysctl + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:2190: checking for $ac_func" >&5 ++echo "configure:2237: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:2265: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -2443,53 +2490,6 @@ + + # We haven't set the list of objects yet. Use the standard autoconf + # tests. This will only work if the compiler works. +- echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 +-echo "configure:2448: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +- +-ac_ext=c +-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. +-ac_cpp='$CPP $CPPFLAGS' +-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' +-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' +-cross_compiling=$ac_cv_prog_cc_cross +- +-cat > conftest.$ac_ext << EOF +- +-#line 2459 "configure" +-#include "confdefs.h" +- +-main(){return(0);} +-EOF +-if { (eval echo configure:2464: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +- ac_cv_prog_cc_works=yes +- # If we can't run a trivial program, we are probably using a cross compiler. +- if (./conftest; exit) 2>/dev/null; then +- ac_cv_prog_cc_cross=no +- else +- ac_cv_prog_cc_cross=yes +- fi +-else +- echo "configure: failed program was:" >&5 +- cat conftest.$ac_ext >&5 +- ac_cv_prog_cc_works=no +-fi +-rm -fr conftest* +-ac_ext=c +-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. +-ac_cpp='$CPP $CPPFLAGS' +-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' +-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' +-cross_compiling=$ac_cv_prog_cc_cross +- +-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 +-if test $ac_cv_prog_cc_works = no; then +- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } +-fi +-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 +-echo "configure:2490: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 +-cross_compiling=$ac_cv_prog_cc_cross +- + for ac_func in $funcs + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +diff -urN gcc-3.3.3.orig/libiberty/configure.in gcc-3.3.3/libiberty/configure.in +--- gcc-3.3.3.orig/libiberty/configure.in 2003-11-12 12:32:30.000000000 -0500 ++++ gcc-3.3.3/libiberty/configure.in 2004-04-09 23:04:05.000000000 -0400 +@@ -100,6 +100,7 @@ + AC_CHECK_TOOL(RANLIB, ranlib, :) + + LIB_AC_PROG_CC ++AC_PROG_CC_WORKS + + AC_PROG_CC_C_O + # autoconf is lame and doesn't give us any substitution variable for this. +@@ -396,7 +397,6 @@ + + # We haven't set the list of objects yet. Use the standard autoconf + # tests. This will only work if the compiler works. +- AC_PROG_CC_WORKS + AC_REPLACE_FUNCS($funcs) + libiberty_AC_FUNC_C_ALLOCA + AC_FUNC_VFORK diff --git a/meta/packages/gcc/gcc-3.3.4/reverse-compare.patch b/meta/packages/gcc/gcc-3.3.4/reverse-compare.patch new file mode 100644 index 000000000..7b6c1b642 --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/reverse-compare.patch @@ -0,0 +1,31 @@ +--- gcc-3.3.3/gcc/flow.c~ 2003-07-30 01:57:24.000000000 +0100 ++++ gcc-3.3.3/gcc/flow.c 2004-04-23 19:23:43.000000000 +0100 +@@ -1904,6 +1904,7 @@ + regset diff = INITIALIZE_REG_SET (diff_head); + basic_block bb_true, bb_false; + rtx cond_true, cond_false, set_src; ++ enum rtx_code reversed_code; + int i; + + /* Identify the successor blocks. */ +@@ -1934,7 +1935,11 @@ + /* Extract the condition from the branch. */ + set_src = SET_SRC (pc_set (bb->end)); + cond_true = XEXP (set_src, 0); +- cond_false = gen_rtx_fmt_ee (reverse_condition (GET_CODE (cond_true)), ++ reversed_code = reverse_condition (GET_CODE (cond_true)); ++ if (reversed_code == UNKNOWN) ++ goto skip; ++ ++ cond_false = gen_rtx_fmt_ee (reversed_code, + GET_MODE (cond_true), XEXP (cond_true, 0), + XEXP (cond_true, 1)); + if (GET_CODE (XEXP (set_src, 1)) == PC) +@@ -1980,6 +1985,7 @@ + }); + } + ++ skip: + FREE_REG_SET (diff); + } + #endif diff --git a/meta/packages/gcc/gcc-3.3.4/sdk-libstdc++-includes.patch b/meta/packages/gcc/gcc-3.3.4/sdk-libstdc++-includes.patch new file mode 100644 index 000000000..9eb7d01fc --- /dev/null +++ b/meta/packages/gcc/gcc-3.3.4/sdk-libstdc++-includes.patch @@ -0,0 +1,48 @@ +--- gcc-3.3.4/libstdc++-v3/testsuite/Makefile.am~ 2003-12-10 21:53:55.000000000 +0000 ++++ gcc-3.3.4/libstdc++-v3/testsuite/Makefile.am 2004-08-22 11:43:54.676189984 +0100 +@@ -53,7 +53,8 @@ + + INCLUDES = \ + -nostdinc++ \ +- @GLIBCPP_INCLUDES@ @LIBSUPCXX_INCLUDES@ @TOPLEVEL_INCLUDES@ ++ @GLIBCPP_INCLUDES@ @LIBSUPCXX_INCLUDES@ @TOPLEVEL_INCLUDES@ \ ++ -I$(toplevel_srcdir)/include + + ## Build support library. + noinst_LIBRARIES = libv3test.a +--- gcc-3.3.4/libstdc++-v3/src/Makefile.am~ 2004-01-12 23:00:30.000000000 +0000 ++++ gcc-3.3.4/libstdc++-v3/src/Makefile.am 2004-08-22 11:12:34.838968680 +0100 +@@ -191,7 +191,8 @@ + $(LIBSUPCXX_CXXFLAGS) \ + $(WARN_CXXFLAGS) \ + $(OPTIMIZE_CXXFLAGS) \ +- $(CONFIG_CXXFLAGS) ++ $(CONFIG_CXXFLAGS) \ ++ -I$(toplevel_srcdir)/include + + + # libstdc++ libtool notes +--- gcc-3.3.4/libstdc++-v3/testsuite/Makefile.in~ 2003-12-10 21:53:55.000000000 +0000 ++++ gcc-3.3.4/libstdc++-v3/testsuite/Makefile.in 2004-08-22 11:44:09.634915912 +0100 +@@ -175,7 +175,8 @@ + + INCLUDES = \ + -nostdinc++ \ +- @GLIBCPP_INCLUDES@ @LIBSUPCXX_INCLUDES@ @TOPLEVEL_INCLUDES@ ++ @GLIBCPP_INCLUDES@ @LIBSUPCXX_INCLUDES@ @TOPLEVEL_INCLUDES@ \ ++ -I$(toplevel_srcdir)/include + + + noinst_LIBRARIES = libv3test.a +--- gcc-3.3.4/libstdc++-v3/src/Makefile.in~ 2004-01-12 23:00:29.000000000 +0000 ++++ gcc-3.3.4/libstdc++-v3/src/Makefile.in 2004-08-22 11:27:29.380977624 +0100 +@@ -263,7 +263,8 @@ + $(LIBSUPCXX_CXXFLAGS) \ + $(WARN_CXXFLAGS) \ + $(OPTIMIZE_CXXFLAGS) \ +- $(CONFIG_CXXFLAGS) ++ $(CONFIG_CXXFLAGS) \ ++ -I$(toplevel_srcdir)/include + + + # libstdc++ libtool notes diff --git a/meta/packages/gcc/gcc-3.4.3/15342.patch b/meta/packages/gcc/gcc-3.4.3/15342.patch new file mode 100644 index 000000000..d0f3e72d4 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/15342.patch @@ -0,0 +1,22 @@ +--- gcc/gcc/regrename.c~ 2004-01-14 17:55:20.000000000 +0000 ++++ gcc/gcc/regrename.c 2005-02-28 07:24:25.893015200 +0000 +@@ -671,7 +671,8 @@ + + case SET: + scan_rtx (insn, &SET_SRC (x), class, action, OP_IN, 0); +- scan_rtx (insn, &SET_DEST (x), class, action, OP_OUT, 0); ++ scan_rtx (insn, &SET_DEST (x), class, action, ++ GET_CODE (PATTERN (insn)) == COND_EXEC ? OP_INOUT : OP_OUT, 0); + return; + + case STRICT_LOW_PART: +@@ -696,7 +697,8 @@ + abort (); + + case CLOBBER: +- scan_rtx (insn, &SET_DEST (x), class, action, OP_OUT, 1); ++ scan_rtx (insn, &SET_DEST (x), class, action, ++ GET_CODE (PATTERN (insn)) == COND_EXEC ? OP_INOUT : OP_OUT, 0); + return; + + case EXPR_LIST: diff --git a/meta/packages/gcc/gcc-3.4.3/GCC3.4.0VisibilityPatch.diff b/meta/packages/gcc/gcc-3.4.3/GCC3.4.0VisibilityPatch.diff new file mode 100644 index 000000000..d51da7157 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/GCC3.4.0VisibilityPatch.diff @@ -0,0 +1,1100 @@ + +diff -aur gcc-3.4.0orig/gcc/c-common.c gcc-3.4.0/gcc/c-common.c +--- gcc-3.4.0orig/gcc/c-common.c 2004-03-19 01:32:59.000000000 +0000 ++++ gcc-3.4.0/gcc/c-common.c 2004-05-10 21:05:33.000000000 +0100 +@@ -833,7 +833,7 @@ + handle_deprecated_attribute }, + { "vector_size", 1, 1, false, true, false, + handle_vector_size_attribute }, +- { "visibility", 1, 1, true, false, false, ++ { "visibility", 1, 1, false, false, false, + handle_visibility_attribute }, + { "tls_model", 1, 1, true, false, false, + handle_tls_model_attribute }, +@@ -4886,7 +4886,16 @@ + + *no_add_attrs = true; + +- if (decl_function_context (decl) != 0 || ! TREE_PUBLIC (decl)) ++ if (TYPE_P (*node)) ++ { ++ if (TREE_CODE (*node) != RECORD_TYPE && TREE_CODE (*node) != UNION_TYPE) ++ { ++ warning ("`%s' attribute ignored on non-class types", ++ IDENTIFIER_POINTER (name)); ++ return NULL_TREE; ++ } ++ } ++ else if (decl_function_context (decl) != 0 || ! TREE_PUBLIC (decl)) + { + warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name)); + return NULL_TREE; +@@ -4897,6 +4906,14 @@ + error ("visibility arg not a string"); + return NULL_TREE; + } ++ ++ /* If this is a type, set the visibility on the type decl. */ ++ if (TYPE_P (decl)) ++ { ++ decl = TYPE_NAME (decl); ++ if (! decl) ++ return NULL_TREE; ++ } + + if (strcmp (TREE_STRING_POINTER (id), "default") == 0) + DECL_VISIBILITY (decl) = VISIBILITY_DEFAULT; +@@ -4908,6 +4925,14 @@ + DECL_VISIBILITY (decl) = VISIBILITY_PROTECTED; + else + error ("visibility arg must be one of \"default\", \"hidden\", \"protected\" or \"internal\""); ++ DECL_VISIBILITYSPECIFIED (decl) = 1; ++ ++ /* For decls only, go ahead and attach the attribute to the node as well. ++ This is needed so we can determine whether we have VISIBILITY_DEFAULT ++ because the visibility was not specified, or because it was explicitly ++ overridden from the class visibility. */ ++ if (DECL_P (*node)) ++ *no_add_attrs = false; + + return NULL_TREE; + } + +diff -aur gcc-3.4.0orig/gcc/c-decl.c gcc-3.4.0/gcc/c-decl.c +--- gcc-3.4.0orig/gcc/c-decl.c 2004-03-22 17:58:18.000000000 +0000 ++++ gcc-3.4.0/gcc/c-decl.c 2004-05-10 15:16:27.000000000 +0100 +@@ -1164,9 +1164,8 @@ + } + + /* warnings */ +- /* All decls must agree on a non-default visibility. */ +- if (DECL_VISIBILITY (newdecl) != VISIBILITY_DEFAULT +- && DECL_VISIBILITY (olddecl) != VISIBILITY_DEFAULT ++ /* All decls must agree on a visibility. */ ++ if (DECL_VISIBILITYSPECIFIED (newdecl) && DECL_VISIBILITYSPECIFIED (olddecl) + && DECL_VISIBILITY (newdecl) != DECL_VISIBILITY (olddecl)) + { + warning ("%Jredeclaration of '%D' with different visibility " +@@ -1361,9 +1360,12 @@ + Currently, it can only be defined in the prototype. */ + COPY_DECL_ASSEMBLER_NAME (olddecl, newdecl); + +- /* If either declaration has a nondefault visibility, use it. */ +- if (DECL_VISIBILITY (olddecl) != VISIBILITY_DEFAULT) +- DECL_VISIBILITY (newdecl) = DECL_VISIBILITY (olddecl); ++ /* Use visibility of whichever declaration had it specified */ ++ if (DECL_VISIBILITYSPECIFIED (olddecl)) ++ { ++ DECL_VISIBILITY (newdecl) = DECL_VISIBILITY (olddecl); ++ DECL_VISIBILITYSPECIFIED (newdecl) = 1; ++ } + + if (TREE_CODE (newdecl) == FUNCTION_DECL) + { + +diff -aur gcc-3.4.0orig/gcc/common.opt gcc-3.4.0/gcc/common.opt +--- gcc-3.4.0orig/gcc/common.opt 2004-02-18 00:09:04.000000000 +0000 ++++ gcc-3.4.0/gcc/common.opt 2004-05-09 08:10:50.000000000 +0100 +@@ -718,6 +718,11 @@ + Common + Add extra commentary to assembler output + ++fvisibility= ++Common Joined RejectNegative ++-fvisibility=[default|internal|hidden|protected] Set the default symbol visibility ++ ++ + fvpt + Common + Use expression value profiles in optimizations + +diff -aur gcc-3.4.0orig/gcc/c.opt gcc-3.4.0/gcc/c.opt +--- gcc-3.4.0orig/gcc/c.opt 2004-02-18 00:09:03.000000000 +0000 ++++ gcc-3.4.0/gcc/c.opt 2004-05-09 08:10:50.000000000 +0100 +@@ -656,6 +656,10 @@ + C++ ObjC++ + Use __cxa_atexit to register destructors + ++fvisibility-inlines-hidden ++C++ ++Marks all inlined methods as having hidden visibility ++ + fvtable-gc + C++ ObjC++ + Discard unused virtual functions +diff -aur gcc-3.4.0orig/gcc/c-opts.c gcc-3.4.0/gcc/c-opts.c +--- gcc-3.4.0orig/gcc/c-opts.c 2004-02-18 00:09:03.000000000 +0000 ++++ gcc-3.4.0/gcc/c-opts.c 2004-05-09 08:10:50.000000000 +0100 +@@ -912,6 +912,10 @@ + case OPT_fuse_cxa_atexit: + flag_use_cxa_atexit = value; + break; ++ ++ case OPT_fvisibility_inlines_hidden: ++ visibility_options.inlineshidden = value; ++ break; + + case OPT_fweak: + flag_weak = value; + +diff -aur gcc-3.4.0orig/gcc/cp/class.c gcc-3.4.0/gcc/cp/class.c +--- gcc-3.4.0orig/gcc/cp/class.c 2004-03-09 07:27:23.000000000 +0000 ++++ gcc-3.4.0/gcc/cp/class.c 2004-05-10 21:06:50.000000000 +0100 +@@ -524,6 +524,10 @@ + DECL_ALIGN (decl) = MAX (TYPE_ALIGN (double_type_node), + DECL_ALIGN (decl)); + ++ /* The vtable's visibility is the class visibility. There is no way ++ to override the visibility for just the vtable. */ ++ DECL_VISIBILITY (decl) = CLASSTYPE_VISIBILITY (class_type); ++ DECL_VISIBILITYSPECIFIED (decl) = CLASSTYPE_VISIBILITYSPECIFIED (class_type); + import_export_vtable (decl, class_type, 0); + + return decl; +@@ -2971,7 +2975,25 @@ + continue; + + if (TREE_CODE (x) == CONST_DECL || TREE_CODE (x) == VAR_DECL) +- continue; ++ { ++ /* Apply the class's visibility attribute to static members ++ which do not have a visibility attribute. */ ++ if (! lookup_attribute ("visibility", DECL_ATTRIBUTES (x))) ++ { ++ if (visibility_options.inlineshidden && DECL_INLINE (x)) ++ { ++ DECL_VISIBILITY (x) = VISIBILITY_HIDDEN; ++ DECL_VISIBILITYSPECIFIED (x) = 1; ++ } ++ else ++ { ++ DECL_VISIBILITY (x) = CLASSTYPE_VISIBILITY (current_class_type); ++ DECL_VISIBILITYSPECIFIED (x) = CLASSTYPE_VISIBILITYSPECIFIED (current_class_type); ++ } ++ } ++ ++ continue; ++ } + + /* Now it can only be a FIELD_DECL. */ + +@@ -3708,6 +3730,22 @@ + check_for_override (x, t); + if (DECL_PURE_VIRTUAL_P (x) && ! DECL_VINDEX (x)) + cp_error_at ("initializer specified for non-virtual method `%D'", x); ++ ++ /* Apply the class's visibility attribute to methods which do ++ not have a visibility attribute. */ ++ if (! lookup_attribute ("visibility", DECL_ATTRIBUTES (x))) ++ { ++ if (visibility_options.inlineshidden && DECL_INLINE (x)) ++ { ++ DECL_VISIBILITY (x) = VISIBILITY_HIDDEN; ++ DECL_VISIBILITYSPECIFIED (x) = 1; ++ } ++ else ++ { ++ DECL_VISIBILITY (x) = CLASSTYPE_VISIBILITY (current_class_type); ++ DECL_VISIBILITYSPECIFIED (x) = CLASSTYPE_VISIBILITYSPECIFIED (current_class_type); ++ } ++ } + + /* The name of the field is the original field name + Save this in auxiliary field for later overloading. */ +@@ -7830,3 +7868,4 @@ + *vid->last_init = build_tree_list (NULL_TREE, init); + vid->last_init = &TREE_CHAIN (*vid->last_init); + } ++ + +diff -aur gcc-3.4.0orig/gcc/cp/cp-tree.h gcc-3.4.0/gcc/cp/cp-tree.h +--- gcc-3.4.0orig/gcc/cp/cp-tree.h 2004-03-20 00:13:08.000000000 +0000 ++++ gcc-3.4.0/gcc/cp/cp-tree.h 2004-05-10 20:56:56.000000000 +0100 +@@ -1008,7 +1008,12 @@ + #define PUBLICLY_UNIQUELY_DERIVED_P(PARENT, TYPE) \ + (lookup_base ((TYPE), (PARENT), ba_not_special | ba_quiet, NULL) \ + != NULL_TREE) +- ++ ++/* Gives the visibility specification for a class type. */ ++#define CLASSTYPE_VISIBILITY(TYPE) DECL_VISIBILITY (TYPE_NAME (TYPE)) ++#define CLASSTYPE_VISIBILITYSPECIFIED(TYPE) DECL_VISIBILITYSPECIFIED (TYPE_NAME (TYPE)) ++ ++ + /* This is a few header flags for 'struct lang_type'. Actually, + all but the first are used only for lang_type_class; they + are put in this structure to save space. */ + +diff -aur gcc-3.4.0orig/gcc/cp/decl.c gcc-3.4.0/gcc/cp/decl.c +--- gcc-3.4.0orig/gcc/cp/decl.c 2004-04-01 21:47:21.000000000 +0100 ++++ gcc-3.4.0/gcc/cp/decl.c 2004-05-28 21:16:11.000000000 +0100 +@@ -1869,17 +1869,34 @@ + DECL_COMMON (newdecl) = DECL_COMMON (olddecl); + COPY_DECL_ASSEMBLER_NAME (olddecl, newdecl); + +- /* If either declaration has a nondefault visibility, use it. */ +- if (DECL_VISIBILITY (olddecl) != VISIBILITY_DEFAULT) ++ /* Warn about conflicting visibility specifications. */ ++ if (DECL_VISIBILITYSPECIFIED (olddecl) && DECL_VISIBILITYSPECIFIED (newdecl) ++ && DECL_VISIBILITY (newdecl) != DECL_VISIBILITY (olddecl)) ++ { ++ warning ("%J'%D': visibility attribute ignored because it", ++ newdecl, newdecl); ++ warning ("%Jconflicts with previous declaration here", olddecl); ++ } ++ /* Choose the declaration which specified visibility. */ ++ if (DECL_VISIBILITYSPECIFIED (olddecl)) + { +- if (DECL_VISIBILITY (newdecl) != VISIBILITY_DEFAULT +- && DECL_VISIBILITY (newdecl) != DECL_VISIBILITY (olddecl)) +- { +- warning ("%J'%D': visibility attribute ignored because it", +- newdecl, newdecl); +- warning ("%Jconflicts with previous declaration here", olddecl); +- } + DECL_VISIBILITY (newdecl) = DECL_VISIBILITY (olddecl); ++ DECL_VISIBILITYSPECIFIED (newdecl) = 1; ++ } ++ /* If it's a definition of a global operator new or operator ++ delete, it must be default visibility. */ ++ if (NEW_DELETE_OPNAME_P (DECL_NAME (newdecl)) && DECL_INITIAL (newdecl) != NULL_TREE) ++ { ++ if (!DECL_FUNCTION_MEMBER_P (newdecl) && VISIBILITY_DEFAULT != DECL_VISIBILITY (newdecl)) ++ { ++ warning ("%J`%D': ignoring non-default symbol", ++ newdecl, newdecl); ++ warning ("%Jvisibility on global operator new or delete", newdecl); ++ DECL_VISIBILITY (olddecl) = VISIBILITY_DEFAULT; ++ DECL_VISIBILITYSPECIFIED (olddecl) = 1; ++ DECL_VISIBILITY (newdecl) = VISIBILITY_DEFAULT; ++ DECL_VISIBILITYSPECIFIED (newdecl) = 1; ++ } + } + + if (TREE_CODE (newdecl) == FUNCTION_DECL) + +diff -aur gcc-3.4.0orig/gcc/cp/method.c gcc-3.4.0/gcc/cp/method.c +--- gcc-3.4.0orig/gcc/cp/method.c 2004-04-08 23:15:58.000000000 +0100 ++++ gcc-3.4.0/gcc/cp/method.c 2004-05-09 08:10:52.000000000 +0100 +@@ -394,6 +394,7 @@ + rewrite. */ + TREE_PUBLIC (thunk_fndecl) = TREE_PUBLIC (function); + DECL_VISIBILITY (thunk_fndecl) = DECL_VISIBILITY (function); ++ DECL_VISIBILITYSPECIFIED (thunk_fndecl) = DECL_VISIBILITYSPECIFIED (function); + + if (flag_syntax_only) + { + +diff -aur gcc-3.4.0orig/gcc/cp/optimize.c gcc-3.4.0/gcc/cp/optimize.c +--- gcc-3.4.0orig/gcc/cp/optimize.c 2004-02-08 01:52:50.000000000 +0000 ++++ gcc-3.4.0/gcc/cp/optimize.c 2004-05-09 08:10:52.000000000 +0100 +@@ -155,6 +155,7 @@ + DECL_NOT_REALLY_EXTERN (clone) = DECL_NOT_REALLY_EXTERN (fn); + TREE_PUBLIC (clone) = TREE_PUBLIC (fn); + DECL_VISIBILITY (clone) = DECL_VISIBILITY (fn); ++ DECL_VISIBILITYSPECIFIED (clone) = DECL_VISIBILITYSPECIFIED (fn); + + /* Adjust the parameter names and locations. */ + parm = DECL_ARGUMENTS (fn); + +diff -aur gcc-3.4.0orig/gcc/cp/rtti.c gcc-3.4.0/gcc/cp/rtti.c +--- gcc-3.4.0orig/gcc/cp/rtti.c 2004-03-08 23:00:26.000000000 +0000 ++++ gcc-3.4.0/gcc/cp/rtti.c 2004-05-10 21:09:21.000000000 +0100 +@@ -361,7 +361,11 @@ + pushdecl_top_level_and_finish (d, NULL_TREE); + + if (CLASS_TYPE_P (type)) +- CLASSTYPE_TYPEINFO_VAR (TYPE_MAIN_VARIANT (type)) = d; ++ { ++ CLASSTYPE_TYPEINFO_VAR (TYPE_MAIN_VARIANT (type)) = d; ++ DECL_VISIBILITY (d) = CLASSTYPE_VISIBILITY (type); ++ DECL_VISIBILITYSPECIFIED (d) = CLASSTYPE_VISIBILITYSPECIFIED (type); ++ } + + /* Remember the type it is for. */ + TREE_TYPE (name) = type; +@@ -759,6 +763,11 @@ + TREE_STATIC (name_decl) = 1; + DECL_EXTERNAL (name_decl) = 0; + TREE_PUBLIC (name_decl) = 1; ++ if (CLASS_TYPE_P (target)) ++ { ++ DECL_VISIBILITY (name_decl) = CLASSTYPE_VISIBILITY (target); ++ DECL_VISIBILITYSPECIFIED (name_decl) = CLASSTYPE_VISIBILITYSPECIFIED (target); ++ } + import_export_tinfo (name_decl, target, typeinfo_in_lib_p (target)); + /* External name of the string containing the type's name has a + special name. */ + +diff -aur gcc-3.4.0orig/gcc/c-pragma.c gcc-3.4.0/gcc/c-pragma.c +--- gcc-3.4.0orig/gcc/c-pragma.c 2004-01-23 23:35:53.000000000 +0000 ++++ gcc-3.4.0/gcc/c-pragma.c 2004-05-09 08:10:52.000000000 +0100 +@@ -480,6 +480,86 @@ + return asmname; + } + ++ ++#ifdef HANDLE_PRAGMA_VISIBILITY ++static void handle_pragma_visibility (cpp_reader *); ++ ++/* Sets the default visibility for symbols to something other than that ++ specified on the command line. */ ++static void ++handle_pragma_visibility (cpp_reader *dummy ATTRIBUTE_UNUSED) ++{ /* Form is #pragma GCC visibility push(hidden)|pop */ ++ static int visstack [16], visidx; ++ tree x; ++ enum cpp_ttype token; ++ enum { bad, push, pop } action = bad; ++ ++ token = c_lex (&x); ++ if (token == CPP_NAME) ++ { ++ const char *op = IDENTIFIER_POINTER (x); ++ if (!strcmp (op, "push")) ++ action = push; ++ else if (!strcmp (op, "pop")) ++ action = pop; ++ } ++ if (bad == action) ++ GCC_BAD ("#pragma GCC visibility must be followed by push or pop"); ++ else ++ { ++ if (pop == action) ++ { ++ if (!visidx) ++ { ++ GCC_BAD ("No matching push for '#pragma GCC visibility pop'"); ++ } ++ else ++ { ++ default_visibility = visstack[--visidx]; ++ visibility_options.inpragma = (visidx>0); ++ } ++ } ++ else ++ { ++ if (c_lex (&x) != CPP_OPEN_PAREN) ++ GCC_BAD ("missing '(' after '#pragma GCC visibility push' - ignored"); ++ token = c_lex (&x); ++ if (token != CPP_NAME) ++ { ++ GCC_BAD ("malformed #pragma GCC visibility push"); ++ } ++ else if (visidx >= 16) ++ { ++ GCC_BAD ("No more than sixteen #pragma GCC visibility pushes allowed at once"); ++ } ++ else ++ { ++ const char *str = IDENTIFIER_POINTER (x); ++ visstack[visidx++] = default_visibility; ++ if (!strcmp (str, "default")) ++ default_visibility = VISIBILITY_DEFAULT; ++ else if (!strcmp (str, "internal")) ++ default_visibility = VISIBILITY_INTERNAL; ++ else if (!strcmp (str, "hidden")) ++ default_visibility = VISIBILITY_HIDDEN; ++ else if (!strcmp (str, "protected")) ++ default_visibility = VISIBILITY_PROTECTED; ++ else ++ { ++ GCC_BAD ("#pragma GCC visibility push() must specify default, internal, hidden or protected"); ++ } ++ visibility_options.inpragma = 1; ++ } ++ if (c_lex (&x) != CPP_CLOSE_PAREN) ++ GCC_BAD ("missing '(' after '#pragma GCC visibility push' - ignored"); ++ } ++ } ++ if (c_lex (&x) != CPP_EOF) ++ warning ("junk at end of '#pragma GCC visibility'"); ++} ++ ++#endif ++ + /* Front-end wrapper for pragma registration to avoid dragging + cpplib.h in almost everywhere. */ + void +@@ -505,6 +585,9 @@ + #ifdef HANDLE_PRAGMA_EXTERN_PREFIX + c_register_pragma (0, "extern_prefix", handle_pragma_extern_prefix); + #endif ++#ifdef HANDLE_PRAGMA_VISIBILITY ++ c_register_pragma ("GCC", "visibility", handle_pragma_visibility); ++#endif + + #ifdef REGISTER_TARGET_PRAGMAS + REGISTER_TARGET_PRAGMAS (); +diff -aur gcc-3.4.0orig/gcc/c-pragma.h gcc-3.4.0/gcc/c-pragma.h +--- gcc-3.4.0orig/gcc/c-pragma.h 2004-01-31 06:18:05.000000000 +0000 ++++ gcc-3.4.0/gcc/c-pragma.h 2004-05-09 08:10:53.000000000 +0100 +@@ -44,6 +44,11 @@ + #define HANDLE_PRAGMA_PACK 1 + #endif /* HANDLE_PRAGMA_PACK_PUSH_POP */ + ++/* It's safe to always leave visibility pragma enabled as if ++ visibility is not supported on the host OS platform the ++ statements are ignored. */ ++#define HANDLE_PRAGMA_VISIBILITY 1 ++ + extern void init_pragma (void); + + /* Front-end wrapper for pragma registration to avoid dragging + + +diff -aur gcc-3.4.0orig/gcc/doc/invoke.texi gcc-3.4.0/gcc/doc/invoke.texi +--- gcc-3.4.0orig/gcc/doc/invoke.texi 2004-04-19 00:05:36.000000000 +0100 ++++ gcc-3.4.0/gcc/doc/invoke.texi 2004-05-28 21:29:36.000000000 +0100 +@@ -183,7 +183,8 @@ + -fno-optional-diags -fpermissive @gol + -frepo -fno-rtti -fstats -ftemplate-depth-@var{n} @gol + -fuse-cxa-atexit -fno-weak -nostdinc++ @gol +--fno-default-inline -Wabi -Wctor-dtor-privacy @gol ++-fno-default-inline -fvisibility-inlines-hidden @gol ++-Wabi -Wctor-dtor-privacy @gol + -Wnon-virtual-dtor -Wreorder @gol + -Weffc++ -Wno-deprecated @gol + -Wno-non-template-friend -Wold-style-cast @gol +@@ -674,7 +675,8 @@ + -fargument-alias -fargument-noalias @gol + -fargument-noalias-global -fleading-underscore @gol + -ftls-model=@var{model} @gol +--ftrapv -fwrapv -fbounds-check} ++-ftrapv -fwrapv -fbounds-check @gol ++-fvisibility} + @end table + + @menu +@@ -1433,6 +1435,20 @@ + destructors, but will only work if your C library supports + @code{__cxa_atexit}. + ++@item -fvisibility-inlines-hidden ++@opindex fvisibility-inlines-hidden ++Causes all inlined methods to be marked with ++@code{__attribute__ ((visibility ("hidden")))} so that they do not ++appear in the export table of a DSO and do not require a PLT indirection ++when used within the DSO. Enabling this option can have a dramatic effect ++on load and link times of a DSO as it massively reduces the size of the ++dynamic export table when the library makes heavy use of templates. While ++it can cause bloating through duplication of code within each DSO where ++it is used, often the wastage is less than the considerable space occupied ++by a long symbol name in the export table which is typical when using ++templates and namespaces. For even more savings, combine with the ++@code{-fvisibility=hidden} switch. ++ + @item -fno-weak + @opindex fno-weak + Do not use weak symbol support, even if it is provided by the linker. +@@ -11198,6 +11214,54 @@ + + The default without @option{-fpic} is @code{initial-exec}; with + @option{-fpic} the default is @code{global-dynamic}. ++ ++@item -fvisibility=@var{default|internal|hidden|protected} ++@opindex fvisibility ++Set the default ELF image symbol visibility to the specified option - all ++symbols will be marked with this unless overrided within the code. ++Using this feature can very substantially improve linking and ++load times of shared object libraries, produce more optimised ++code, provide near-perfect API export and prevent symbol clashes. ++It is @strong{strongly} recommended that you use this in any shared objects ++you distribute. ++ ++Despite the nomenclature, @code{default} always means public ie; ++available to be linked against from outside the shared object. ++@code{protected} and @code{internal} are pretty useless in real-world ++usage so the only other commonly used option will be @code{hidden}. ++The default if -fvisibility isn't specified is @code{default} ie; make every ++symbol public - this causes the same behaviour as previous versions of ++GCC. ++ ++A good explanation of the benefits offered by ensuring ELF ++symbols have the correct visibility is given by ``How To Write ++Shared Libraries'' by Ulrich Drepper (which can be found at ++@w{@uref{http://people.redhat.com/~drepper/}}) - however a superior ++solution made possible by this option to marking things hidden when ++the default is public is to make the default hidden and mark things ++public. This is the norm with DLL's on Windows and with @option{-fvisibility=hidden} ++and @code{__attribute__ ((visibility("default")))} instead of ++@code{__declspec(dllexport)} you get almost identical semantics with ++identical syntax. This is a great boon to those working with ++cross-platform projects. ++ ++For those adding visibility support to existing code, you may find ++@samp{#pragma GCC visibility} of use. This works by you enclosing ++the declarations you wish to set visibility for with (for example) ++@samp{#pragma GCC visibility push(hidden)} and ++@samp{#pragma GCC visibility pop}. These can be nested up to sixteen ++times. Bear in mind that symbol visibility should be viewed @strong{as ++part of the API interface contract} and thus all new code should ++always specify visibility when it is not the default ie; declarations ++only for use within the local DSO should @strong{always} be marked explicitly ++as hidden as so to avoid PLT indirection overheads - making this ++abundantly clear also aids readability and self-documentation of the code. ++Note that due to ISO C++ specification requirements, operator new and ++operator delete must always be of default visibility. ++ ++An overview of these techniques, their benefits and how to use them ++is at @w{@uref{http://www.nedprod.com/programs/gccvisibility.html}}. ++ + @end table + + @c man end + +diff -aur gcc-3.4.0orig/gcc/flags.h gcc-3.4.0/gcc/flags.h +--- gcc-3.4.0orig/gcc/flags.h 2004-02-18 00:09:04.000000000 +0000 ++++ gcc-3.4.0/gcc/flags.h 2004-05-09 08:10:53.000000000 +0100 +@@ -60,6 +60,30 @@ + /* Nonzero means emit debugging information only for symbols which are used. */ + extern int flag_debug_only_used_symbols; + ++/* Enumerate visibility settings. */ ++#ifndef SYMBOL_VISIBILITY_DEFINED ++#define SYMBOL_VISIBILITY_DEFINED ++enum symbol_visibility ++{ ++ VISIBILITY_DEFAULT, ++ VISIBILITY_INTERNAL, ++ VISIBILITY_HIDDEN, ++ VISIBILITY_PROTECTED ++}; ++#endif ++ ++/* The default visibility for all symbols (unless overridden). */ ++extern enum symbol_visibility default_visibility; ++ ++struct visibility_flags ++{ ++ unsigned inpragma : 1; /* True when in #pragma GCC visibility. */ ++ unsigned inlineshidden : 1; /* True when -finlineshidden in effect. */ ++}; ++ ++/* Global visibility options. */ ++extern struct visibility_flags visibility_options; ++ + /* Nonzero means do optimizations. -opt. */ + + extern int optimize; + +diff -aur gcc-3.4.0orig/gcc/opts.c gcc-3.4.0/gcc/opts.c +--- gcc-3.4.0orig/gcc/opts.c 2004-02-18 00:09:04.000000000 +0000 ++++ gcc-3.4.0/gcc/opts.c 2004-05-09 08:10:53.000000000 +0100 +@@ -142,6 +142,12 @@ + write_symbols is set to DBX_DEBUG, XCOFF_DEBUG, or DWARF_DEBUG. */ + bool use_gnu_debug_info_extensions; + ++/* The default visibility for all symbols (unless overridden) */ ++enum symbol_visibility default_visibility = VISIBILITY_DEFAULT; ++ ++/* Global visibility options. */ ++struct visibility_flags visibility_options; ++ + /* Columns of --help display. */ + static unsigned int columns = 80; + +@@ -1440,6 +1446,21 @@ + flag_verbose_asm = value; + break; + ++ case OPT_fvisibility_: ++ { ++ if(!strcmp(arg, "default")) ++ default_visibility=VISIBILITY_DEFAULT; ++ else if(!strcmp(arg, "internal")) ++ default_visibility=VISIBILITY_INTERNAL; ++ else if(!strcmp(arg, "hidden")) ++ default_visibility=VISIBILITY_HIDDEN; ++ else if(!strcmp(arg, "protected")) ++ default_visibility=VISIBILITY_PROTECTED; ++ else ++ error("unrecognised visibility value \"%s\"", arg); ++ } ++ break; ++ + case OPT_fweb: + flag_web = value; + break; + +diff -aur gcc-3.4.0orig/gcc/tree.c gcc-3.4.0/gcc/tree.c +--- gcc-3.4.0orig/gcc/tree.c 2004-02-05 22:01:35.000000000 +0000 ++++ gcc-3.4.0/gcc/tree.c 2004-05-10 15:22:52.000000000 +0100 +@@ -2563,6 +2563,11 @@ + layout_decl (t, 0); + else if (code == FUNCTION_DECL) + DECL_MODE (t) = FUNCTION_MODE; ++ ++ /* Set default visibility to whatever the user supplied with ++ visibility_specified depending on #pragma GCC visibility. */ ++ DECL_VISIBILITY (t) = default_visibility; ++ DECL_VISIBILITYSPECIFIED (t) = visibility_options.inpragma; + + return t; + } + +diff -aur gcc-3.4.0orig/gcc/tree.h gcc-3.4.0/gcc/tree.h +--- gcc-3.4.0orig/gcc/tree.h 2004-02-08 01:52:43.000000000 +0000 ++++ gcc-3.4.0/gcc/tree.h 2004-05-09 08:10:54.000000000 +0100 +@@ -1499,6 +1499,10 @@ + /* Value of the decls's visibility attribute */ + #define DECL_VISIBILITY(NODE) (DECL_CHECK (NODE)->decl.visibility) + ++/* Nonzero means that the decl had its visibility specified rather than ++ being inferred. */ ++#define DECL_VISIBILITYSPECIFIED(NODE) (DECL_CHECK (NODE)->decl.visibility_specified) ++ + /* In a FUNCTION_DECL, nonzero if the function cannot be inlined. */ + #define DECL_UNINLINABLE(NODE) (FUNCTION_DECL_CHECK (NODE)->decl.uninlinable) + +@@ -1633,7 +1637,8 @@ + || TREE_CODE (DECL_CONTEXT (EXP)) == TRANSLATION_UNIT_DECL) + + /* Enumerate visibility settings. */ +- ++#ifndef SYMBOL_VISIBILITY_DEFINED ++#define SYMBOL_VISIBILITY_DEFINED + enum symbol_visibility + { + VISIBILITY_DEFAULT, +@@ -1641,6 +1646,7 @@ + VISIBILITY_HIDDEN, + VISIBILITY_PROTECTED + }; ++#endif + + struct function; + +@@ -1684,8 +1690,7 @@ + unsigned thread_local_flag : 1; + unsigned declared_inline_flag : 1; + ENUM_BITFIELD(symbol_visibility) visibility : 2; +- unsigned unused : 1; +- /* one unused bit. */ ++ unsigned visibility_specified : 1; + + unsigned lang_flag_0 : 1; + unsigned lang_flag_1 : 1; + +diff -aur gcc-3.4.0orig/gcc/varasm.c gcc-3.4.0/gcc/varasm.c +--- gcc-3.4.0orig/gcc/varasm.c 2004-04-14 22:14:08.000000000 +0100 ++++ gcc-3.4.0/gcc/varasm.c 2004-05-09 08:10:54.000000000 +0100 +@@ -5150,8 +5150,8 @@ + /* Static variables are always local. */ + else if (! TREE_PUBLIC (exp)) + local_p = true; +- /* A variable is local if the user tells us so. */ +- else if (DECL_VISIBILITY (exp) != VISIBILITY_DEFAULT) ++ /* A variable is local if the user explicitly tells us so. */ ++ else if (DECL_VISIBILITYSPECIFIED (exp) && DECL_VISIBILITY (exp) != VISIBILITY_DEFAULT) + local_p = true; + /* Otherwise, variables defined outside this object may not be local. */ + else if (DECL_EXTERNAL (exp)) +@@ -5159,6 +5159,9 @@ + /* Linkonce and weak data are never local. */ + else if (DECL_ONE_ONLY (exp) || DECL_WEAK (exp)) + local_p = false; ++ /* If none of the above and visibility is not default, make local. */ ++ else if (DECL_VISIBILITY (exp) != VISIBILITY_DEFAULT) ++ local_p = true; + /* If PIC, then assume that any global name can be overridden by + symbols resolved from other modules. */ + else if (shlib) + +diff -Naur gcc-3.4.0orig/gcc/testsuite/gcc.dg/visibility-9.c gcc-3.4.0/gcc/testsuite/gcc.dg/visibility-9.c +--- gcc-3.4.0orig/gcc/testsuite/gcc.dg/visibility-9.c 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/gcc.dg/visibility-9.c 2004-05-09 12:40:39.000000000 +0100 +@@ -0,0 +1,9 @@ ++/* Test that -fvisibility works. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility=hidden" } */ ++/* { dg-final { scan-assembler "\\.hidden.*foo" } } */ ++ ++void foo(); ++ ++void foo() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/gcc.dg/visibility-a.c gcc-3.4.0/gcc/testsuite/gcc.dg/visibility-a.c +--- gcc-3.4.0orig/gcc/testsuite/gcc.dg/visibility-a.c 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/gcc.dg/visibility-a.c 2004-05-09 12:55:04.000000000 +0100 +@@ -0,0 +1,10 @@ ++/* Test that #pragma GCC visibility works. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*foo" } } */ ++ ++#pragma GCC visibility push(hidden) ++void foo(); ++#pragma GCC visibility pop ++ ++void foo() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility.C 2004-05-09 19:17:13.000000000 +0100 +@@ -0,0 +1,12 @@ ++/* Test that -fvisibility affects class members. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility=hidden" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++class Foo ++{ ++ void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-inlines-hidden.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-inlines-hidden.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-inlines-hidden.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-inlines-hidden.C 2004-05-09 19:17:59.000000000 +0100 +@@ -0,0 +1,18 @@ ++/* Test that -fvisibility-inlines-hidden affects class members. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility-inlines-hidden" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++class Foo ++{ ++public: ++ void method() { } ++}; ++ ++int main(void) ++{ ++ Foo f; ++ f.method(); ++ return 0; ++} +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override1.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override1.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override1.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override1.C 2004-05-09 19:18:06.000000000 +0100 +@@ -0,0 +1,12 @@ ++/* Test that -fvisibility does not override class member specific settings. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility=hidden" } */ ++/* { dg-final { scan-assembler "\\.internal.*Foo.methodEv" } } */ ++ ++class __attribute__ ((visibility ("internal"))) Foo ++{ ++ void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override2.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override2.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override2.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override2.C 2004-05-09 19:18:12.000000000 +0100 +@@ -0,0 +1,12 @@ ++/* Test that -fvisibility does not override class member specific settings. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility=hidden" } */ ++/* { dg-final { scan-assembler "\\.internal.*Foo.methodEv" } } */ ++ ++class Foo ++{ ++ __attribute__ ((visibility ("internal"))) void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/memfuncts.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/memfuncts.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/memfuncts.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/memfuncts.C 2004-05-09 19:18:19.000000000 +0100 +@@ -0,0 +1,11 @@ ++/* Test that setting visibility for class member functions works. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++class __attribute__ ((visibility ("hidden"))) Foo ++{ ++ void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/noPLT.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/noPLT.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/noPLT.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/noPLT.C 2004-05-09 19:21:49.000000000 +0100 +@@ -0,0 +1,20 @@ ++/* Test that -fvisibility=hidden prevents PLT. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fPIC -fvisibility=hidden" } */ ++/* { dg-final { scan-assembler-not "methodEv@PLT" } } */ ++ ++class Foo ++{ ++public: ++ void method(); ++}; ++ ++void Foo::method() { } ++ ++int main(void) ++{ ++ Foo f; ++ f.method(); ++ return 0; ++} +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma.C 2004-05-09 19:18:30.000000000 +0100 +@@ -0,0 +1,13 @@ ++/* Test that #pragma GCC visibility affects class members. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++#pragma GCC visibility push(hidden) ++class Foo ++{ ++ void method(); ++}; ++#pragma GCC visibility pop ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma-override1.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma-override1.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma-override1.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma-override1.C 2004-05-09 19:18:36.000000000 +0100 +@@ -0,0 +1,13 @@ ++/* Test that #pragma GCC visibility does not override class member specific settings. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.internal.*Foo.methodEv" } } */ ++ ++#pragma GCC visibility push(hidden) ++class __attribute__ ((visibility ("internal"))) Foo ++{ ++ void method(); ++}; ++#pragma GCC visibility pop ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma-override2.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma-override2.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma-override2.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma-override2.C 2004-05-09 19:18:44.000000000 +0100 +@@ -0,0 +1,13 @@ ++/* Test that #pragma GCC visibility does not override class member specific settings. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.internal.*Foo.methodEv" } } */ ++ ++#pragma GCC visibility push(hidden) ++class Foo ++{ ++ __attribute__ ((visibility ("internal"))) void method(); ++}; ++#pragma GCC visibility pop ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/staticmemfuncts.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/staticmemfuncts.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/staticmemfuncts.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/staticmemfuncts.C 2004-05-09 19:18:50.000000000 +0100 +@@ -0,0 +1,11 @@ ++/* Test that setting visibility for static class member functions works. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++class __attribute__ ((visibility ("hidden"))) Foo ++{ ++ static void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/virtual.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/virtual.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/virtual.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/virtual.C 2004-05-09 13:24:06.000000000 +0100 +@@ -0,0 +1,11 @@ ++/* Test that setting visibility for class affects virtual table. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*ZTV3Foo" } } */ ++ ++class __attribute__ ((visibility ("hidden"))) Foo ++{ ++ virtual void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-1.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-1.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-1.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-1.C 2003-12-10 06:34:44.000000000 +0000 +@@ -0,0 +1,8 @@ ++/* Test visibility attribute on function definition. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ ++ ++void ++__attribute__((visibility ("hidden"))) ++foo() ++{ } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-2.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-2.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-2.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-2.C 2003-12-10 06:34:44.000000000 +0000 +@@ -0,0 +1,7 @@ ++/* Test that visibility attribute on declaration extends to definition. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ ++ ++void __attribute__((visibility ("hidden"))) foo(); ++ ++void foo() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-3.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-3.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-3.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-3.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,7 @@ ++/* Test visibility attribute on forward declaration of global variable */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ ++ ++int ++__attribute__((visibility ("hidden"))) ++xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-4.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-4.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-4.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-4.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,8 @@ ++/* Test visibility attribute on forward declaration of global variable */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ ++ ++extern int __attribute__ ((visibility ("hidden"))) ++xyzzy; ++ ++int xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-5.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-5.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-5.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-5.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,11 @@ ++/* Test visibility attribute on definition of a function that has ++ already had a forward declaration. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ ++ ++void foo(); ++ ++void ++ __attribute__((visibility ("hidden"))) ++foo() ++{ } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-6.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-6.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-6.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-6.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,10 @@ ++/* Test visibility attribute on definition of global variable that has ++ already had a forward declaration. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ ++ ++extern int xyzzy; ++ ++int ++__attribute__((visibility ("hidden"))) ++xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-7.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-7.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-7.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-7.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,11 @@ ++/* Test warning from conflicting visibility specifications. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ ++ ++extern int ++__attribute__((visibility ("hidden"))) ++xyzzy; /* { dg-warning "previous declaration here" "" } */ ++ ++int ++__attribute__((visibility ("protected"))) ++xyzzy = 5; /* { dg-warning "visibility attribute ignored" "" } */ +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-1.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-1.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-1.C 2003-12-10 06:34:44.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-1.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,8 +0,0 @@ +-/* Test visibility attribute on function definition. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ +- +-void +-__attribute__((visibility ("hidden"))) +-foo() +-{ } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-2.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-2.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-2.C 2003-12-10 06:34:44.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-2.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,7 +0,0 @@ +-/* Test that visibility attribute on declaration extends to definition. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ +- +-void __attribute__((visibility ("hidden"))) foo(); +- +-void foo() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-3.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-3.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-3.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-3.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,7 +0,0 @@ +-/* Test visibility attribute on forward declaration of global variable */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ +- +-int +-__attribute__((visibility ("hidden"))) +-xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-4.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-4.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-4.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-4.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,8 +0,0 @@ +-/* Test visibility attribute on forward declaration of global variable */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ +- +-extern int __attribute__ ((visibility ("hidden"))) +-xyzzy; +- +-int xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-5.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-5.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-5.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-5.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,11 +0,0 @@ +-/* Test visibility attribute on definition of a function that has +- already had a forward declaration. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ +- +-void foo(); +- +-void +- __attribute__((visibility ("hidden"))) +-foo() +-{ } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-6.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-6.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-6.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-6.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,10 +0,0 @@ +-/* Test visibility attribute on definition of global variable that has +- already had a forward declaration. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ +- +-extern int xyzzy; +- +-int +-__attribute__((visibility ("hidden"))) +-xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-7.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-7.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-7.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-7.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,11 +0,0 @@ +-/* Test warning from conflicting visibility specifications. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ +- +-extern int +-__attribute__((visibility ("hidden"))) +-xyzzy; /* { dg-warning "previous declaration here" "" } */ +- +-int +-__attribute__((visibility ("protected"))) +-xyzzy = 5; /* { dg-warning "visibility attribute ignored" "" } */ diff --git a/meta/packages/gcc/gcc-3.4.3/always-fixincperm.patch b/meta/packages/gcc/gcc-3.4.3/always-fixincperm.patch new file mode 100644 index 000000000..59e5e2ede --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/always-fixincperm.patch @@ -0,0 +1,32 @@ +Index: gcc-3.4.3/gcc/configure +=================================================================== +--- gcc-3.4.3.orig/gcc/configure 2004-11-04 23:14:05.000000000 -0500 ++++ gcc-3.4.3/gcc/configure 2005-03-11 14:41:06.373910320 -0500 +@@ -9916,11 +9916,6 @@ + BUILD_PREFIX=build- + BUILD_PREFIX_1=build- + BUILD_CFLAGS='$(INTERNAL_CFLAGS) $(T_CFLAGS) $(CFLAGS_FOR_BUILD)' +- +- if test "x$TARGET_SYSTEM_ROOT" = x; then +- STMP_FIXINC= +- STMP_FIXPROTO= +- fi + fi + + # Expand extra_headers to include complete path. +Index: gcc-3.4.3/gcc/configure.ac +=================================================================== +--- gcc-3.4.3.orig/gcc/configure.ac 2004-09-23 20:43:53.000000000 -0400 ++++ gcc-3.4.3/gcc/configure.ac 2005-03-11 14:40:55.256600408 -0500 +@@ -1524,11 +1524,6 @@ + BUILD_PREFIX=build- + BUILD_PREFIX_1=build- + BUILD_CFLAGS='$(INTERNAL_CFLAGS) $(T_CFLAGS) $(CFLAGS_FOR_BUILD)' +- +- if test "x$TARGET_SYSTEM_ROOT" = x; then +- STMP_FIXINC= +- STMP_FIXPROTO= +- fi + fi + + # Expand extra_headers to include complete path. diff --git a/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-bigendian-uclibc.patch b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-bigendian-uclibc.patch new file mode 100644 index 000000000..8fa9af880 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-bigendian-uclibc.patch @@ -0,0 +1,30 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- gcc-3.4.1/gcc/config.gcc~gcc-3.4.0-arm-bigendian-uclibc ++++ gcc-3.4.1/gcc/config.gcc +@@ -666,6 +666,11 @@ + ;; + arm*-*-linux-uclibc*) # ARM GNU/Linux with ELF - uClibc + tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" ++ case $target in ++ arm*b-*) ++ tm_defines="TARGET_BIG_ENDIAN_DEFAULT=1 $tm_defines" ++ ;; ++ esac + tmake_file="t-slibgcc-elf-ver t-linux-uclibc arm/t-linux" + extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" + gnu_ld=yes +--- gcc-3.4.1/gcc/config/arm/linux-elf.h~gcc-3.4.0-arm-bigendian-uclibc ++++ gcc-3.4.1/gcc/config/arm/linux-elf.h +@@ -120,7 +120,7 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2} \ + -X \ +- %{mbig-endian:-EB}" \ ++ %{mbig-endian:-EB} %{mlittle-endian:-EL}" \ + SUBTARGET_EXTRA_LINK_SPEC + #endif + diff --git a/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-bigendian.patch b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-bigendian.patch new file mode 100644 index 000000000..c9288c6c1 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-bigendian.patch @@ -0,0 +1,70 @@ +By Lennert Buytenhek +Adds support for arm*b-linux* big-endian ARM targets + +See http://gcc.gnu.org/PR16350 + +diff -urN gcc-3.4.0.orig/gcc/config/arm/linux-elf.h gcc-3.4.0/gcc/config/arm/linux-elf.h +--- gcc-3.4.0.orig/gcc/config/arm/linux-elf.h 2004-01-31 07:18:11.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/linux-elf.h 2004-07-02 14:46:29.225443757 +0200 +@@ -30,17 +30,34 @@ + /* Do not assume anything about header files. */ + #define NO_IMPLICIT_EXTERN_C + ++/* ++ * 'config.gcc' defines TARGET_BIG_ENDIAN_DEFAULT as 1 for arm*b-* ++ * (big endian) configurations. ++ */ ++#if TARGET_BIG_ENDIAN_DEFAULT ++#define TARGET_ENDIAN_DEFAULT ARM_FLAG_BIG_END ++#define TARGET_ENDIAN_OPTION "mbig-endian" ++#define TARGET_LINKER_EMULATION "armelfb_linux" ++#else ++#define TARGET_ENDIAN_DEFAULT 0 ++#define TARGET_ENDIAN_OPTION "mlittle-endian" ++#define TARGET_LINKER_EMULATION "armelf_linux" ++#endif ++ + /* Default is to use APCS-32 mode. */ + #undef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_APCS_32 | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_APCS_32 | \ ++ ARM_FLAG_MMU_TRAPS | \ ++ TARGET_ENDIAN_DEFAULT ) + + #define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm6 + +-#define SUBTARGET_EXTRA_LINK_SPEC " -m armelf_linux -p" ++#define SUBTARGET_EXTRA_LINK_SPEC " -m " TARGET_LINKER_EMULATION " -p" + + #undef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "marm", "mlittle-endian", "mhard-float", "mapcs-32", "mno-thumb-interwork" } ++ { "marm", TARGET_ENDIAN_OPTION, "mhard-float", "mapcs-32", "mno-thumb-interwork" } + + #define CPP_APCS_PC_DEFAULT_SPEC "-D__APCS_32__" + +@@ -89,7 +106,7 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2} \ + -X \ +- %{mbig-endian:-EB}" \ ++ %{mbig-endian:-EB} %{mlittle-endian:-EL}" \ + SUBTARGET_EXTRA_LINK_SPEC + + #define TARGET_OS_CPP_BUILTINS() LINUX_TARGET_OS_CPP_BUILTINS() +diff -urN gcc-3.4.0.orig/gcc/config.gcc gcc-3.4.0/gcc/config.gcc +--- gcc-3.4.0.orig/gcc/config.gcc 2004-04-17 04:28:24.000000000 +0200 ++++ gcc-3.4.0/gcc/config.gcc 2004-07-02 14:44:40.045822542 +0200 +@@ -666,6 +666,11 @@ + ;; + arm*-*-linux*) # ARM GNU/Linux with ELF + tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" ++ case $target in ++ arm*b-*) ++ tm_defines="TARGET_BIG_ENDIAN_DEFAULT=1 $tm_defines" ++ ;; ++ esac + tmake_file="t-slibgcc-elf-ver t-linux arm/t-linux" + extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" + gnu_ld=yes diff --git a/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-lib1asm.patch b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-lib1asm.patch new file mode 100644 index 000000000..ca42bfbc0 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-lib1asm.patch @@ -0,0 +1,24 @@ +# Fixes errors like the following when building glibc (or any other executable +# or shared library) when using gcc 3.4.0 for ARM with softfloat: +# +# .../libc_pic.os(.text+0x15834): In function `__modf': undefined reference to `__subdf3' +# .../libc_pic.os(.text+0x158b8): In function `__modf': undefined reference to `__subdf3' +# .../libc_pic.os(.text+0x1590c): In function `scalbn': undefined reference to `__muldf3' +# .../libc_pic.os(.text+0x15e94): In function `__ldexpf': undefined reference to `__eqsf2' +# .../libc_pic.os(.text+0xcee4c): In function `monstartup': undefined reference to `__fixsfsi' + +diff -urNd gcc-3.4.0-orig/gcc/config/arm/t-linux gcc-3.4.0/gcc/config/arm/t-linux +--- gcc-3.4.0-orig/gcc/config/arm/t-linux 2003-09-20 23:09:07.000000000 +0200 ++++ gcc-3.4.0/gcc/config/arm/t-linux 2004-05-01 20:31:59.102846400 +0200 +@@ -4,7 +4,10 @@ + LIBGCC2_DEBUG_CFLAGS = -g0 + + LIB1ASMSRC = arm/lib1funcs.asm +-LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx ++LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \ ++ _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \ ++ _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \ ++ _fixsfsi _fixunssfsi + + # MULTILIB_OPTIONS = mhard-float/msoft-float + # MULTILIB_DIRNAMES = hard-float soft-float diff --git a/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-nolibfloat.patch b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-nolibfloat.patch new file mode 100644 index 000000000..43eed3ef2 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-nolibfloat.patch @@ -0,0 +1,24 @@ +# Dimitry Andric , 2004-05-01 +# +# * Removed the extra -lfloat option from LIBGCC_SPEC, since it isn't needed +# anymore. (The required functions are now in libgcc.) +# +# Fixes errors like +# arm-softfloat-linux-gnu/3.4.0/../../../../arm-softfloat-linux-gnu/bin/ld: cannot find -lfloat +# collect2: ld returned 1 exit status +# make[2]: *** [arm-softfloat-linux-gnu/gcc-3.4.0-glibc-2.3.2/build-glibc/iconvdata/ISO8859-1.so] Error 1 +# when building glibc-2.3.3 with gcc-3.4.0 for arm-softfloat + +diff -urNd gcc-3.4.0-orig/gcc/config/arm/linux-elf.h gcc-3.4.0/gcc/config/arm/linux-elf.h +--- gcc-3.4.0-orig/gcc/config/arm/linux-elf.h 2004-01-31 07:18:11.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/linux-elf.h 2004-05-01 19:19:06.935979200 +0200 +@@ -55,7 +73,7 @@ + %{shared:-lc} \ + %{!shared:%{profile:-lc_p}%{!profile:-lc}}" + +-#define LIBGCC_SPEC "%{msoft-float:-lfloat} -lgcc" ++#define LIBGCC_SPEC "-lgcc" + + /* Provide a STARTFILE_SPEC appropriate for GNU/Linux. Here we add + the GNU/Linux magical crtbegin.o file (see crtstuff.c) which + diff --git a/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-softfloat.patch b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-softfloat.patch new file mode 100644 index 000000000..f53d64b37 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.0-arm-softfloat.patch @@ -0,0 +1,256 @@ +# +# Submitted: +# +# Dimitry Andric , 2004-05-01 +# +# Description: +# +# Nicholas Pitre released this patch for gcc soft-float support here: +# http://lists.arm.linux.org.uk/pipermail/linux-arm/2003-October/006436.html +# +# This version has been adapted to work with gcc 3.4.0. +# +# The original patch doesn't distinguish between softfpa and softvfp modes +# in the way Nicholas Pitre probably meant. His description is: +# +# "Default is to use APCS-32 mode with soft-vfp. The old Linux default for +# floats can be achieved with -mhard-float or with the configure +# --with-float=hard option. If -msoft-float or --with-float=soft is used then +# software float support will be used just like the default but with the legacy +# big endian word ordering for double float representation instead." +# +# Which means the following: +# +# * If you compile without -mhard-float or -msoft-float, you should get +# software floating point, using the VFP format. The produced object file +# should have these flags in its header: +# +# private flags = 600: [APCS-32] [VFP float format] [software FP] +# +# * If you compile with -mhard-float, you should get hardware floating point, +# which always uses the FPA format. Object file header flags should be: +# +# private flags = 0: [APCS-32] [FPA float format] +# +# * If you compile with -msoft-float, you should get software floating point, +# using the FPA format. This is done for compatibility reasons with many +# existing distributions. Object file header flags should be: +# +# private flags = 200: [APCS-32] [FPA float format] [software FP] +# +# The original patch from Nicholas Pitre contained the following constructs: +# +# #define SUBTARGET_EXTRA_ASM_SPEC "%{!mcpu=*:-mcpu=xscale} \ +# %{mhard-float:-mfpu=fpa} \ +# %{!mhard-float: %{msoft-float:-mfpu=softfpa;:-mfpu=softvfp}}" +# +# However, gcc doesn't accept this ";:" notation, used in the 3rd line. This +# is probably the reason Robert Schwebel modified it to: +# +# #define SUBTARGET_EXTRA_ASM_SPEC "%{!mcpu=*:-mcpu=xscale} \ +# %{mhard-float:-mfpu=fpa} \ +# %{!mhard-float: %{msoft-float:-mfpu=softfpa -mfpu=softvfp}}" +# +# But this causes the following behaviour: +# +# * If you compile without -mhard-float or -msoft-float, the compiler generates +# software floating point instructions, but *nothing* is passed to the +# assembler, which results in an object file which has flags: +# +# private flags = 0: [APCS-32] [FPA float format] +# +# This is not correct! +# +# * If you compile with -mhard-float, the compiler generates hardware floating +# point instructions, and passes "-mfpu=fpa" to the assembler, which results +# in an object file which has the same flags as in the previous item, but now +# those *are* correct. +# +# * If you compile with -msoft-float, the compiler generates software floating +# point instructions, and passes "-mfpu=softfpa -mfpu=softvfp" (in that +# order) to the assembler, which results in an object file with flags: +# +# private flags = 600: [APCS-32] [VFP float format] [software FP] +# +# This is not correct, because the last "-mfpu=" option on the assembler +# command line determines the actual FPU convention used (which should be FPA +# in this case). +# +# Therefore, I modified this patch to get the desired behaviour. Every +# instance of the notation: +# +# %{msoft-float:-mfpu=softfpa -mfpu=softvfp} +# +# was changed to: +# +# %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp} +# +# I also did the following: +# +# * Modified all TARGET_DEFAULT macros I could find to include ARM_FLAG_VFP, to +# be consistent with Nicholas' original patch. +# * Removed any "msoft-float" or "mhard-float" from all MULTILIB_DEFAULTS +# macros I could find. I think that if you compile without any options, you +# would like to get the defaults. :) +# * Removed the extra -lfloat option from LIBGCC_SPEC, since it isn't needed +# anymore. (The required functions are now in libgcc.) + +diff -urNd gcc-3.4.0-orig/gcc/config/arm/coff.h gcc-3.4.0/gcc/config/arm/coff.h +--- gcc-3.4.0-orig/gcc/config/arm/coff.h 2004-02-24 15:25:22.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/coff.h 2004-05-01 19:07:06.059409600 +0200 +@@ -31,11 +31,16 @@ + #define TARGET_VERSION fputs (" (ARM/coff)", stderr) + + #undef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_SOFT_FLOAT | ARM_FLAG_APCS_32 | ARM_FLAG_APCS_FRAME | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_SOFT_FLOAT \ ++ | ARM_FLAG_VFP \ ++ | ARM_FLAG_APCS_32 \ ++ | ARM_FLAG_APCS_FRAME \ ++ | ARM_FLAG_MMU_TRAPS ) + + #ifndef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "marm", "mlittle-endian", "msoft-float", "mapcs-32", "mno-thumb-interwork" } ++ { "marm", "mlittle-endian", "mapcs-32", "mno-thumb-interwork" } + #endif + + /* This is COFF, but prefer stabs. */ +diff -urNd gcc-3.4.0-orig/gcc/config/arm/elf.h gcc-3.4.0/gcc/config/arm/elf.h +--- gcc-3.4.0-orig/gcc/config/arm/elf.h 2004-02-24 15:25:22.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/elf.h 2004-05-01 19:12:16.976486400 +0200 +@@ -46,7 +46,9 @@ + + #ifndef SUBTARGET_ASM_FLOAT_SPEC + #define SUBTARGET_ASM_FLOAT_SPEC "\ +-%{mapcs-float:-mfloat} %{msoft-float:-mfpu=softfpa}" ++%{mapcs-float:-mfloat} \ ++%{mhard-float:-mfpu=fpa} \ ++%{!mhard-float: %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp}}" + #endif + + #ifndef ASM_SPEC +@@ -106,12 +108,17 @@ + #endif + + #ifndef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_SOFT_FLOAT | ARM_FLAG_APCS_32 | ARM_FLAG_APCS_FRAME | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_SOFT_FLOAT \ ++ | ARM_FLAG_VFP \ ++ | ARM_FLAG_APCS_32 \ ++ | ARM_FLAG_APCS_FRAME \ ++ | ARM_FLAG_MMU_TRAPS ) + #endif + + #ifndef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "marm", "mlittle-endian", "msoft-float", "mapcs-32", "mno-thumb-interwork", "fno-leading-underscore" } ++ { "marm", "mlittle-endian", "mapcs-32", "mno-thumb-interwork", "fno-leading-underscore" } + #endif + + #define TARGET_ASM_FILE_START_APP_OFF true +diff -urNd gcc-3.4.0-orig/gcc/config/arm/linux-elf.h gcc-3.4.0/gcc/config/arm/linux-elf.h +--- gcc-3.4.0-orig/gcc/config/arm/linux-elf.h 2004-01-31 07:18:11.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/linux-elf.h 2004-05-01 19:19:06.935979200 +0200 +@@ -30,9 +30,27 @@ + /* Do not assume anything about header files. */ + #define NO_IMPLICIT_EXTERN_C + +-/* Default is to use APCS-32 mode. */ ++/* ++ * Default is to use APCS-32 mode with soft-vfp. ++ * The old Linux default for floats can be achieved with -mhard-float ++ * or with the configure --with-float=hard option. ++ * If -msoft-float or --with-float=soft is used then software float ++ * support will be used just like the default but with the legacy ++ * big endian word ordering for double float representation instead. ++ */ ++ + #undef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_APCS_32 | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_APCS_32 \ ++ | ARM_FLAG_SOFT_FLOAT \ ++ | ARM_FLAG_VFP \ ++ | ARM_FLAG_MMU_TRAPS ) ++ ++#undef SUBTARGET_EXTRA_ASM_SPEC ++#define SUBTARGET_EXTRA_ASM_SPEC "\ ++%{!mcpu=*:-mcpu=xscale} \ ++%{mhard-float:-mfpu=fpa} \ ++%{!mhard-float: %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp}}" + + #define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm6 + +@@ -40,7 +58,7 @@ + + #undef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "marm", "mlittle-endian", "mhard-float", "mapcs-32", "mno-thumb-interwork" } ++ { "marm", "mlittle-endian", "mapcs-32", "mno-thumb-interwork" } + + #define CPP_APCS_PC_DEFAULT_SPEC "-D__APCS_32__" + +@@ -55,7 +73,7 @@ + %{shared:-lc} \ + %{!shared:%{profile:-lc_p}%{!profile:-lc}}" + +-#define LIBGCC_SPEC "%{msoft-float:-lfloat} -lgcc" ++#define LIBGCC_SPEC "-lgcc" + + /* Provide a STARTFILE_SPEC appropriate for GNU/Linux. Here we add + the GNU/Linux magical crtbegin.o file (see crtstuff.c) which +diff -urNd gcc-3.4.0-orig/gcc/config/arm/t-linux gcc-3.4.0/gcc/config/arm/t-linux +--- gcc-3.4.0-orig/gcc/config/arm/t-linux 2003-09-20 23:09:07.000000000 +0200 ++++ gcc-3.4.0/gcc/config/arm/t-linux 2004-05-01 20:31:59.102846400 +0200 +@@ -4,7 +4,10 @@ + LIBGCC2_DEBUG_CFLAGS = -g0 + + LIB1ASMSRC = arm/lib1funcs.asm +-LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx ++LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \ ++ _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \ ++ _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \ ++ _fixsfsi _fixunssfsi + + # MULTILIB_OPTIONS = mhard-float/msoft-float + # MULTILIB_DIRNAMES = hard-float soft-float +diff -urNd gcc-3.4.0-orig/gcc/config/arm/unknown-elf.h gcc-3.4.0/gcc/config/arm/unknown-elf.h +--- gcc-3.4.0-orig/gcc/config/arm/unknown-elf.h 2004-02-24 15:25:22.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/unknown-elf.h 2004-05-01 19:09:09.016212800 +0200 +@@ -30,7 +30,12 @@ + + /* Default to using APCS-32 and software floating point. */ + #ifndef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_SOFT_FLOAT | ARM_FLAG_APCS_32 | ARM_FLAG_APCS_FRAME | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_SOFT_FLOAT \ ++ | ARM_FLAG_VFP \ ++ | ARM_FLAG_APCS_32 \ ++ | ARM_FLAG_APCS_FRAME \ ++ | ARM_FLAG_MMU_TRAPS ) + #endif + + /* Now we define the strings used to build the spec file. */ +diff -urNd gcc-3.4.0-orig/gcc/config/arm/xscale-elf.h gcc-3.4.0/gcc/config/arm/xscale-elf.h +--- gcc-3.4.0-orig/gcc/config/arm/xscale-elf.h 2003-07-02 01:26:43.000000000 +0200 ++++ gcc-3.4.0/gcc/config/arm/xscale-elf.h 2004-05-01 20:15:36.620105600 +0200 +@@ -49,11 +49,12 @@ + endian, regardless of the endian-ness of the memory + system. */ + +-#define SUBTARGET_EXTRA_ASM_SPEC "%{!mcpu=*:-mcpu=xscale} \ +- %{mhard-float:-mfpu=fpa} \ +- %{!mhard-float: %{msoft-float:-mfpu=softfpa;:-mfpu=softvfp}}" ++#define SUBTARGET_EXTRA_ASM_SPEC "\ ++%{!mcpu=*:-mcpu=xscale} \ ++%{mhard-float:-mfpu=fpa} \ ++%{!mhard-float: %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp}}" + + #ifndef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "mlittle-endian", "mno-thumb-interwork", "marm", "msoft-float" } ++ { "mlittle-endian", "mno-thumb-interwork", "marm" } + #endif diff --git a/meta/packages/gcc/gcc-3.4.3/gcc-3.4.1-uclibc-100-conf.patch b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.1-uclibc-100-conf.patch new file mode 100644 index 000000000..29e4c802e --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.1-uclibc-100-conf.patch @@ -0,0 +1,442 @@ +diff -urN gcc-3.4.1-dist/boehm-gc/configure gcc-3.4.1/boehm-gc/configure +--- gcc-3.4.1-dist/boehm-gc/configure 2004-07-01 14:14:03.000000000 -0500 ++++ gcc-3.4.1/boehm-gc/configure 2004-08-12 16:22:57.000000000 -0500 +@@ -1947,6 +1947,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +diff -urN gcc-3.4.1-dist/boehm-gc/ltconfig gcc-3.4.1/boehm-gc/ltconfig +--- gcc-3.4.1-dist/boehm-gc/ltconfig 2002-11-20 09:59:06.000000000 -0600 ++++ gcc-3.4.1/boehm-gc/ltconfig 2004-08-12 15:54:42.000000000 -0500 +@@ -1981,6 +1981,23 @@ + fi + ;; + ++linux-uclibc*) ++ version_type=linux ++ need_lib_prefix=no ++ need_version=no ++ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' ++ soname_spec='${libname}${release}.so$major' ++ finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' ++ shlibpath_var=LD_LIBRARY_PATH ++ shlibpath_overrides_runpath=no ++ deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ++ file_magic_cmd=/usr/bin/file ++ file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ++ # Assume using the uClibc dynamic linker. ++ dynamic_linker="uClibc ld.so" ++ ;; ++ + netbsd*) + version_type=sunos + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then +diff -urN gcc-3.4.1-dist/gcc/config/arm/linux-elf.h gcc-3.4.1/gcc/config/arm/linux-elf.h +--- gcc-3.4.1-dist/gcc/config/arm/linux-elf.h 2004-01-31 00:18:11.000000000 -0600 ++++ gcc-3.4.1/gcc/config/arm/linux-elf.h 2004-08-12 15:54:42.000000000 -0500 +@@ -81,6 +81,18 @@ + "%{!shared:crtend.o%s} %{shared:crtendS.o%s} crtn.o%s" + + #undef LINK_SPEC ++#ifdef USE_UCLIBC ++#define LINK_SPEC "%{h*} %{version:-v} \ ++ %{b} %{Wl,*:%*} \ ++ %{static:-Bstatic} \ ++ %{shared:-shared} \ ++ %{symbolic:-Bsymbolic} \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0} \ ++ -X \ ++ %{mbig-endian:-EB}" \ ++ SUBTARGET_EXTRA_LINK_SPEC ++#else + #define LINK_SPEC "%{h*} %{version:-v} \ + %{b} %{Wl,*:%*} \ + %{static:-Bstatic} \ +@@ -91,6 +103,7 @@ + -X \ + %{mbig-endian:-EB}" \ + SUBTARGET_EXTRA_LINK_SPEC ++#endif + + #define TARGET_OS_CPP_BUILTINS() LINUX_TARGET_OS_CPP_BUILTINS() + +diff -urN gcc-3.4.1-dist/gcc/config/cris/linux.h gcc-3.4.1/gcc/config/cris/linux.h +--- gcc-3.4.1-dist/gcc/config/cris/linux.h 2003-11-28 21:08:09.000000000 -0600 ++++ gcc-3.4.1/gcc/config/cris/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -79,6 +79,25 @@ + #undef CRIS_DEFAULT_CPU_VERSION + #define CRIS_DEFAULT_CPU_VERSION CRIS_CPU_NG + ++#ifdef USE_UCLIBC ++ ++#undef CRIS_SUBTARGET_VERSION ++#define CRIS_SUBTARGET_VERSION " - cris-axis-linux-uclibc" ++ ++#undef CRIS_LINK_SUBTARGET_SPEC ++#define CRIS_LINK_SUBTARGET_SPEC \ ++ "-mcrislinux\ ++ -rpath-link include/asm/../..%s\ ++ %{shared} %{static}\ ++ %{symbolic:-Bdynamic} %{shlib:-Bdynamic} %{static:-Bstatic}\ ++ %{!shared: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}} \ ++ %{!r:%{O2|O3: --gc-sections}}" ++ ++#else /* USE_UCLIBC */ ++ + #undef CRIS_SUBTARGET_VERSION + #define CRIS_SUBTARGET_VERSION " - cris-axis-linux-gnu" + +@@ -93,6 +112,8 @@ + %{!shared:%{!static:%{rdynamic:-export-dynamic}}}\ + %{!r:%{O2|O3: --gc-sections}}" + ++#endif /* USE_UCLIBC */ ++ + + /* Node: Run-time Target */ + +diff -urN gcc-3.4.1-dist/gcc/config/cris/t-linux-uclibc gcc-3.4.1/gcc/config/cris/t-linux-uclibc +--- gcc-3.4.1-dist/gcc/config/cris/t-linux-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.1/gcc/config/cris/t-linux-uclibc 2004-08-12 15:54:43.000000000 -0500 +@@ -0,0 +1,3 @@ ++T_CFLAGS = -DUSE_UCLIBC ++TARGET_LIBGCC2_CFLAGS += -fPIC ++CRTSTUFF_T_CFLAGS_S = $(TARGET_LIBGCC2_CFLAGS) +diff -urN gcc-3.4.1-dist/gcc/config/i386/linux.h gcc-3.4.1/gcc/config/i386/linux.h +--- gcc-3.4.1-dist/gcc/config/i386/linux.h 2003-11-28 21:08:10.000000000 -0600 ++++ gcc-3.4.1/gcc/config/i386/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -118,6 +118,15 @@ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.1}} \ + %{static:-static}}}" + #else ++#if defined USE_UCLIBC ++#define LINK_SPEC "-m elf_i386 %{shared:-shared} \ ++ %{!shared: \ ++ %{!ibcs: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}} \ ++ %{static:-static}}}" ++#else + #define LINK_SPEC "-m elf_i386 %{shared:-shared} \ + %{!shared: \ + %{!ibcs: \ +@@ -126,6 +135,7 @@ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ + %{static:-static}}}" + #endif ++#endif + + /* A C statement (sans semicolon) to output to the stdio stream + FILE the assembler definition of uninitialized global DECL named +diff -urN gcc-3.4.1-dist/gcc/config/mips/linux.h gcc-3.4.1/gcc/config/mips/linux.h +--- gcc-3.4.1-dist/gcc/config/mips/linux.h 2004-06-15 20:42:24.000000000 -0500 ++++ gcc-3.4.1/gcc/config/mips/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -109,6 +109,17 @@ + + /* Borrowed from sparc/linux.h */ + #undef LINK_SPEC ++#ifdef USE_UCLIBC ++#define LINK_SPEC \ ++ "%(endian_spec) \ ++ %{shared:-shared} \ ++ %{!shared: \ ++ %{!ibcs: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}} \ ++ %{static:-static}}}" ++#else + #define LINK_SPEC \ + "%(endian_spec) \ + %{shared:-shared} \ +@@ -118,6 +129,7 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}} \ + %{static:-static}}}" ++#endif + + #undef SUBTARGET_ASM_SPEC + #define SUBTARGET_ASM_SPEC "\ +diff -urN gcc-3.4.1-dist/gcc/config/rs6000/linux.h gcc-3.4.1/gcc/config/rs6000/linux.h +--- gcc-3.4.1-dist/gcc/config/rs6000/linux.h 2004-02-25 09:11:19.000000000 -0600 ++++ gcc-3.4.1/gcc/config/rs6000/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -61,7 +61,11 @@ + #define LINK_START_DEFAULT_SPEC "%(link_start_linux)" + + #undef LINK_OS_DEFAULT_SPEC ++#ifdef USE_UCLIBC ++#define LINK_OS_DEFAULT_SPEC "%(link_os_linux_uclibc)" ++#else + #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)" ++#endif + + #define LINK_GCC_C_SEQUENCE_SPEC \ + "%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}" +diff -urN gcc-3.4.1-dist/gcc/config/rs6000/sysv4.h gcc-3.4.1/gcc/config/rs6000/sysv4.h +--- gcc-3.4.1-dist/gcc/config/rs6000/sysv4.h 2004-06-10 01:39:50.000000000 -0500 ++++ gcc-3.4.1/gcc/config/rs6000/sysv4.h 2004-08-12 15:54:43.000000000 -0500 +@@ -947,6 +947,7 @@ + mcall-linux : %(link_os_linux) ; \ + mcall-gnu : %(link_os_gnu) ; \ + mcall-netbsd : %(link_os_netbsd) ; \ ++ mcall-linux-uclibc : %(link_os_linux_uclibc); \ + mcall-openbsd: %(link_os_openbsd) ; \ + : %(link_os_default) }" + +@@ -1124,6 +1125,10 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}}}" + ++#define LINK_OS_LINUX_UCLIBC_SPEC "-m elf32ppclinux %{!shared: %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}}" ++ + #if defined(HAVE_LD_EH_FRAME_HDR) + # define LINK_EH_SPEC "%{!static:--eh-frame-hdr} " + #endif +@@ -1290,6 +1295,7 @@ + { "link_os_sim", LINK_OS_SIM_SPEC }, \ + { "link_os_freebsd", LINK_OS_FREEBSD_SPEC }, \ + { "link_os_linux", LINK_OS_LINUX_SPEC }, \ ++ { "link_os_linux_uclibc", LINK_OS_LINUX_UCLIBC_SPEC }, \ + { "link_os_gnu", LINK_OS_GNU_SPEC }, \ + { "link_os_netbsd", LINK_OS_NETBSD_SPEC }, \ + { "link_os_openbsd", LINK_OS_OPENBSD_SPEC }, \ +diff -urN gcc-3.4.1-dist/gcc/config/sh/linux.h gcc-3.4.1/gcc/config/sh/linux.h +--- gcc-3.4.1-dist/gcc/config/sh/linux.h 2004-01-11 20:29:13.000000000 -0600 ++++ gcc-3.4.1/gcc/config/sh/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -73,12 +73,21 @@ + #undef SUBTARGET_LINK_EMUL_SUFFIX + #define SUBTARGET_LINK_EMUL_SUFFIX "_linux" + #undef SUBTARGET_LINK_SPEC ++#ifdef USE_UCLIBC ++#define SUBTARGET_LINK_SPEC \ ++ "%{shared:-shared} \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}} \ ++ %{static:-static}" ++#else + #define SUBTARGET_LINK_SPEC \ + "%{shared:-shared} \ + %{!static: \ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ + %{static:-static}" ++#endif + + #undef LIB_SPEC + #define LIB_SPEC \ +diff -urN gcc-3.4.1-dist/gcc/config/sh/t-linux-uclibc gcc-3.4.1/gcc/config/sh/t-linux-uclibc +--- gcc-3.4.1-dist/gcc/config/sh/t-linux-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.1/gcc/config/sh/t-linux-uclibc 2004-08-12 15:54:43.000000000 -0500 +@@ -0,0 +1,13 @@ ++T_CFLAGS = -DUSE_UCLIBC ++ ++TARGET_LIBGCC2_CFLAGS = -fpic -DNO_FPSCR_VALUES ++LIB1ASMFUNCS_CACHE = _ic_invalidate ++ ++LIB2FUNCS_EXTRA= ++ ++MULTILIB_OPTIONS= $(MULTILIB_ENDIAN) m3e/m4 ++MULTILIB_DIRNAMES= ++MULTILIB_MATCHES = ++MULTILIB_EXCEPTIONS= ++ ++EXTRA_MULTILIB_PARTS= crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o +diff -urN gcc-3.4.1-dist/gcc/config/sh/t-sh64-uclibc gcc-3.4.1/gcc/config/sh/t-sh64-uclibc +--- gcc-3.4.1-dist/gcc/config/sh/t-sh64-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.1/gcc/config/sh/t-sh64-uclibc 2004-08-12 15:54:43.000000000 -0500 +@@ -0,0 +1,13 @@ ++EXTRA_MULTILIB_PARTS= crt1.o crti.o crtn.o crtbegin.o crtend.o ++ ++LIB1ASMFUNCS = \ ++ _sdivsi3 _sdivsi3_i4 _udivsi3 _udivsi3_i4 _set_fpscr \ ++ _shcompact_call_trampoline _shcompact_return_trampoline \ ++ _shcompact_incoming_args _ic_invalidate _nested_trampoline \ ++ _push_pop_shmedia_regs \ ++ _udivdi3 _divdi3 _umoddi3 _moddi3 ++ ++MULTILIB_OPTIONS = $(MULTILIB_ENDIAN) m5-32media-nofpu/m5-compact/m5-compact-nofpu/m5-64media/m5-64media-nofpu ++MULTILIB_DIRNAMES= $(MULTILIB_ENDIAN) nofpu compact nofpu/compact media64 nofpu/media64 ++MULTILIB_MATCHES= ++MULTILIB_EXCEPTIONS= +diff -urN gcc-3.4.1-dist/gcc/config/t-linux-uclibc gcc-3.4.1/gcc/config/t-linux-uclibc +--- gcc-3.4.1-dist/gcc/config/t-linux-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.1/gcc/config/t-linux-uclibc 2004-08-12 15:54:43.000000000 -0500 +@@ -0,0 +1,15 @@ ++T_CFLAGS = -DUSE_UCLIBC ++ ++# Compile crtbeginS.o and crtendS.o with pic. ++CRTSTUFF_T_CFLAGS_S = $(CRTSTUFF_T_CFLAGS) -fPIC ++# Compile libgcc2.a with pic. ++TARGET_LIBGCC2_CFLAGS = -fPIC ++ ++# Override t-slibgcc-elf-ver to export some libgcc symbols with ++# the symbol versions that glibc used. ++#SHLIB_MAPFILES += $(srcdir)/config/libgcc-glibc.ver ++ ++# Use unwind-dw2-fde ++LIB2ADDEH = $(srcdir)/unwind-dw2.c $(srcdir)/unwind-dw2-fde.c \ ++ $(srcdir)/unwind-sjlj.c $(srcdir)/gthr-gnat.c $(srcdir)/unwind-c.c ++LIB2ADDEHDEP = unwind.inc unwind-dw2-fde.h +diff -urN gcc-3.4.1-dist/gcc/config.gcc gcc-3.4.1/gcc/config.gcc +--- gcc-3.4.1-dist/gcc/config.gcc 2004-04-21 10:12:35.000000000 -0500 ++++ gcc-3.4.1/gcc/config.gcc 2004-08-12 15:59:46.000000000 -0500 +@@ -664,6 +664,12 @@ + extra_parts="" + use_collect2=yes + ;; ++arm*-*-linux-uclibc*) # ARM GNU/Linux with ELF - uClibc ++ tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" ++ tmake_file="t-slibgcc-elf-ver t-linux-uclibc arm/t-linux" ++ extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" ++ gnu_ld=yes ++ ;; + arm*-*-linux*) # ARM GNU/Linux with ELF + tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" + tmake_file="t-slibgcc-elf-ver t-linux arm/t-linux" +@@ -725,6 +731,10 @@ + tmake_file="cris/t-cris cris/t-elfmulti" + gas=yes + ;; ++cris-*-linux-uclibc*) ++ tm_file="dbxelf.h elfos.h svr4.h ${tm_file} linux.h cris/linux.h" ++ tmake_file="cris/t-cris t-slibgcc-elf-ver cris/t-linux-uclibc" ++ ;; + cris-*-linux*) + tm_file="dbxelf.h elfos.h svr4.h ${tm_file} linux.h cris/linux.h" + tmake_file="cris/t-cris t-slibgcc-elf-ver cris/t-linux" +@@ -988,6 +998,11 @@ + thread_file='single' + fi + ;; ++i[34567]86-*-linux*uclibc*) # Intel 80386's running GNU/Linux ++ # with ELF format using uClibc ++ tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h linux.h i386/linux.h" ++ tmake_file="t-slibgcc-elf-ver t-linux-uclibc i386/t-crtstuff" ++ ;; + i[34567]86-*-linux*) # Intel 80386's running GNU/Linux + # with ELF format using glibc 2 + # aka GNU/Linux C library 6 +@@ -1547,6 +1562,16 @@ + gnu_ld=yes + gas=yes + ;; ++mips*-*-linux-uclibc*) # Linux MIPS, either endian. uClibc ++ tm_file="dbxelf.h elfos.h svr4.h linux.h ${tm_file} mips/linux.h" ++ case ${target} in ++ mipsisa32*-*) ++ target_cpu_default="MASK_SOFT_FLOAT" ++ tm_defines="MIPS_ISA_DEFAULT=32" ++ ;; ++ esac ++ tmake_file="t-slibgcc-elf-ver t-linux-uclibc" ++ ;; + mips*-*-linux*) # Linux MIPS, either endian. + tm_file="dbxelf.h elfos.h svr4.h linux.h ${tm_file} mips/linux.h" + case ${target} in +@@ -1764,6 +1789,10 @@ + tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h rs6000/linuxspe.h" + tmake_file="rs6000/t-fprules rs6000/t-ppcos t-slibgcc-elf-ver t-linux rs6000/t-ppccomm" + ;; ++powerpc-*-linux-uclibc*) ++ tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h" ++ tmake_file="rs6000/t-fprules rs6000/t-ppcos t-slibgcc-elf-ver t-linux-uclibc rs6000/t-ppccomm" ++ ;; + powerpc-*-linux*) + tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h" + tmake_file="rs6000/t-fprules rs6000/t-ppcos t-slibgcc-elf-ver t-linux rs6000/t-ppccomm" +@@ -1916,7 +1945,7 @@ + tm_file="${tm_file} dbxelf.h elfos.h svr4.h sh/elf.h sh/embed-elf.h sh/rtemself.h rtems.h" + ;; + sh-*-linux* | sh[2346lbe]*-*-linux*) +- tmake_file="sh/t-sh sh/t-elf t-slibgcc-elf-ver t-linux" ++ tmake_file="sh/t-sh sh/t-elf t-slibgcc-elf-ver" + case ${target} in + sh*be-*-* | sh*eb-*-*) ;; + *) +@@ -1924,9 +1953,17 @@ + tmake_file="${tmake_file} sh/t-le" + ;; + esac +- tmake_file="${tmake_file} sh/t-linux" ++ case ${target} in ++ *-*-linux-uclibc*) tmake_file="${tmake_file} t-linux-uclibc sh/t-linux-uclibc" ;; ++ *) tmake_file="${tmake_file} t-linux sh/t-linux" ;; ++ esac + tm_file="${tm_file} dbxelf.h elfos.h svr4.h sh/elf.h sh/linux.h" + case ${target} in ++ sh64*-*-linux-uclibc*) ++ tmake_file="${tmake_file} sh/t-sh64-uclibc" ++ tm_file="${tm_file} sh/sh64.h" ++ extra_headers="shmedia.h ushmedia.h sshmedia.h" ++ ;; + sh64*) + tmake_file="${tmake_file} sh/t-sh64" + tm_file="${tm_file} sh/sh64.h" +diff -urN gcc-3.4.1-dist/libtool.m4 gcc-3.4.1/libtool.m4 +--- gcc-3.4.1-dist/libtool.m4 2004-05-18 04:08:37.000000000 -0500 ++++ gcc-3.4.1/libtool.m4 2004-08-12 15:54:43.000000000 -0500 +@@ -689,6 +689,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + [lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'] +diff -urN gcc-3.4.1-dist/ltconfig gcc-3.4.1/ltconfig +--- gcc-3.4.1-dist/ltconfig 2004-03-05 15:05:41.000000000 -0600 ++++ gcc-3.4.1/ltconfig 2004-08-12 15:55:48.000000000 -0500 +@@ -602,6 +602,7 @@ + + # Transform linux* to *-*-linux-gnu*, to support old configure scripts. + case $host_os in ++linux-uclibc*) ;; + linux-gnu*) ;; + linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'` + esac +@@ -1262,6 +1263,24 @@ + dynamic_linker='GNU/Linux ld.so' + ;; + ++linux-uclibc*) ++ version_type=linux ++ need_lib_prefix=no ++ need_version=no ++ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' ++ soname_spec='${libname}${release}.so$major' ++ finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' ++ shlibpath_var=LD_LIBRARY_PATH ++ shlibpath_overrides_runpath=no ++ # This implies no fast_install, which is unacceptable. ++ # Some rework will be needed to allow for fast_install ++ # before this can be enabled. ++ # Note: copied from linux-gnu, and may not be appropriate. ++ hardcode_into_libs=yes ++ # Assume using the uClibc dynamic linker. ++ dynamic_linker="uClibc ld.so" ++ ;; ++ + netbsd*) + need_lib_prefix=no + need_version=no diff --git a/meta/packages/gcc/gcc-3.4.3/gcc-3.4.1-uclibc-200-locale.patch b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.1-uclibc-200-locale.patch new file mode 100644 index 000000000..3fc4900b0 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc-3.4.1-uclibc-200-locale.patch @@ -0,0 +1,3246 @@ +diff -urN gcc-3.4.2-dist/libstdc++-v3/acinclude.m4 gcc-3.4.2/libstdc++-v3/acinclude.m4 +--- gcc-3.4.2-dist/libstdc++-v3/acinclude.m4 2004-07-15 12:42:45.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/acinclude.m4 2004-09-10 10:47:40.000000000 -0500 +@@ -996,7 +996,7 @@ + AC_MSG_CHECKING([for C locale to use]) + GLIBCXX_ENABLE(clocale,auto,[@<:@=MODEL@:>@], + [use MODEL for target locale package], +- [permit generic|gnu|ieee_1003.1-2001|yes|no|auto]) ++ [permit generic|gnu|ieee_1003.1-2001|uclibc|yes|no|auto]) + + # If they didn't use this option switch, or if they specified --enable + # with no specific model, we'll have to look for one. If they +@@ -1012,6 +1012,9 @@ + # Default to "generic". + if test $enable_clocale_flag = auto; then + case x${target_os} in ++ x*-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + xlinux* | xgnu* | xkfreebsd*-gnu | xknetbsd*-gnu) + AC_EGREP_CPP([_GLIBCXX_ok], [ + #include +@@ -1138,6 +1141,41 @@ + CTIME_CC=config/locale/generic/time_members.cc + CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h + ;; ++ uclibc) ++ AC_MSG_RESULT(uclibc) ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ AC_CHECK_PROG(check_msgfmt, msgfmt, yes, no) ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcxx_MOFILES="$glibcxx_MOFILES $ling.mo"; \ ++ glibcxx_POFILES="$glibcxx_POFILES $ling.po"; \ ++ done ++ AC_SUBST(glibcxx_MOFILES) ++ AC_SUBST(glibcxx_POFILES) ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_H=config/locale/ieee_1003.1-2001/codecvt_specializations.h ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + esac + + # This is where the testsuite looks for locale catalogs, using the +diff -urN gcc-3.4.2-dist/libstdc++-v3/aclocal.m4 gcc-3.4.2/libstdc++-v3/aclocal.m4 +--- gcc-3.4.2-dist/libstdc++-v3/aclocal.m4 2004-08-13 15:44:03.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/aclocal.m4 2004-09-10 10:47:40.000000000 -0500 +@@ -1025,6 +1025,9 @@ + # Default to "generic". + if test $enable_clocale_flag = auto; then + case x${target_os} in ++ x*-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + xlinux* | xgnu* | xkfreebsd*-gnu | xknetbsd*-gnu) + AC_EGREP_CPP([_GLIBCXX_ok], [ + #include +@@ -1151,6 +1154,41 @@ + CTIME_CC=config/locale/generic/time_members.cc + CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h + ;; ++ uclibc) ++ AC_MSG_RESULT(uclibc) ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ AC_CHECK_PROG(check_msgfmt, msgfmt, yes, no) ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcxx_MOFILES="$glibcxx_MOFILES $ling.mo"; \ ++ glibcxx_POFILES="$glibcxx_POFILES $ling.po"; \ ++ done ++ AC_SUBST(glibcxx_MOFILES) ++ AC_SUBST(glibcxx_POFILES) ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_H=config/locale/ieee_1003.1-2001/codecvt_specializations.h ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + esac + + # This is where the testsuite looks for locale catalogs, using the +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c++locale_internal.h gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c++locale_internal.h +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c++locale_internal.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c++locale_internal.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,59 @@ ++// Prototypes for GLIBC thread locale __-prefixed functions -*- C++ -*- ++ ++// Copyright (C) 2002, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// Written by Jakub Jelinek ++ ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning clean this up ++#endif ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ ++extern "C" __typeof(iswctype_l) __iswctype_l; ++extern "C" __typeof(nl_langinfo_l) __nl_langinfo_l; ++extern "C" __typeof(strcoll_l) __strcoll_l; ++extern "C" __typeof(strftime_l) __strftime_l; ++extern "C" __typeof(strtod_l) __strtod_l; ++extern "C" __typeof(strtof_l) __strtof_l; ++extern "C" __typeof(strtold_l) __strtold_l; ++extern "C" __typeof(strxfrm_l) __strxfrm_l; ++extern "C" __typeof(towlower_l) __towlower_l; ++extern "C" __typeof(towupper_l) __towupper_l; ++extern "C" __typeof(wcscoll_l) __wcscoll_l; ++extern "C" __typeof(wcsftime_l) __wcsftime_l; ++extern "C" __typeof(wcsxfrm_l) __wcsxfrm_l; ++extern "C" __typeof(wctype_l) __wctype_l; ++extern "C" __typeof(newlocale) __newlocale; ++extern "C" __typeof(freelocale) __freelocale; ++extern "C" __typeof(duplocale) __duplocale; ++extern "C" __typeof(uselocale) __uselocale; ++ ++#endif // GLIBC 2.3 and later +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c_locale.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c_locale.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c_locale.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c_locale.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,160 @@ ++// Wrapper for underlying C-language localization -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.8 Standard locale categories. ++// ++ ++// Written by Benjamin Kosnik ++ ++#include // For errno ++#include ++#include ++#include ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __strtol_l(S, E, B, L) strtol((S), (E), (B)) ++#define __strtoul_l(S, E, B, L) strtoul((S), (E), (B)) ++#define __strtoll_l(S, E, B, L) strtoll((S), (E), (B)) ++#define __strtoull_l(S, E, B, L) strtoull((S), (E), (B)) ++#define __strtof_l(S, E, L) strtof((S), (E)) ++#define __strtod_l(S, E, L) strtod((S), (E)) ++#define __strtold_l(S, E, L) strtold((S), (E)) ++#warning should dummy __newlocale check for C|POSIX ? ++#define __newlocale(a, b, c) NULL ++#define __freelocale(a) ((void)0) ++#define __duplocale(a) __c_locale() ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ __convert_to_v(const char* __s, float& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ float __f = __strtof_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && errno != ERANGE) ++ __v = __f; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, double& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ double __d = __strtod_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && errno != ERANGE) ++ __v = __d; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, long double& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ long double __ld = __strtold_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && errno != ERANGE) ++ __v = __ld; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ void ++ locale::facet::_S_create_c_locale(__c_locale& __cloc, const char* __s, ++ __c_locale __old) ++ { ++ __cloc = __newlocale(1 << LC_ALL, __s, __old); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ if (!__cloc) ++ { ++ // This named locale is not supported by the underlying OS. ++ __throw_runtime_error(__N("locale::facet::_S_create_c_locale " ++ "name not valid")); ++ } ++#endif ++ } ++ ++ void ++ locale::facet::_S_destroy_c_locale(__c_locale& __cloc) ++ { ++ if (_S_get_c_locale() != __cloc) ++ __freelocale(__cloc); ++ } ++ ++ __c_locale ++ locale::facet::_S_clone_c_locale(__c_locale& __cloc) ++ { return __duplocale(__cloc); } ++} // namespace std ++ ++namespace __gnu_cxx ++{ ++ const char* const category_names[6 + _GLIBCXX_NUM_CATEGORIES] = ++ { ++ "LC_CTYPE", ++ "LC_NUMERIC", ++ "LC_TIME", ++ "LC_COLLATE", ++ "LC_MONETARY", ++ "LC_MESSAGES", ++#if _GLIBCXX_NUM_CATEGORIES != 0 ++ "LC_PAPER", ++ "LC_NAME", ++ "LC_ADDRESS", ++ "LC_TELEPHONE", ++ "LC_MEASUREMENT", ++ "LC_IDENTIFICATION" ++#endif ++ }; ++} ++ ++namespace std ++{ ++ const char* const* const locale::_S_categories = __gnu_cxx::category_names; ++} // namespace std +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c_locale.h gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c_locale.h +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c_locale.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c_locale.h 2004-09-10 10:48:08.000000000 -0500 +@@ -0,0 +1,115 @@ ++// Wrapper for underlying C-language localization -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.8 Standard locale categories. ++// ++ ++// Written by Benjamin Kosnik ++ ++#ifndef _C_LOCALE_H ++#define _C_LOCALE_H 1 ++ ++#pragma GCC system_header ++ ++#include // get std::strlen ++#include // get std::snprintf or std::sprintf ++#include ++#include // For codecvt ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC_HAS_LOCALE__ ++#include // For codecvt using iconv, iconv_t ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++#include // For messages ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning what is _GLIBCXX_C_LOCALE_GNU for ++#endif ++#define _GLIBCXX_C_LOCALE_GNU 1 ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix categories ++#endif ++// #define _GLIBCXX_NUM_CATEGORIES 6 ++#define _GLIBCXX_NUM_CATEGORIES 0 ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++namespace __gnu_cxx ++{ ++ extern "C" __typeof(uselocale) __uselocale; ++} ++#endif ++ ++namespace std ++{ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ typedef __locale_t __c_locale; ++#else ++ typedef int* __c_locale; ++#endif ++ ++ // Convert numeric value of type _Tv to string and return length of ++ // string. If snprintf is available use it, otherwise fall back to ++ // the unsafe sprintf which, in general, can be dangerous and should ++ // be avoided. ++ template ++ int ++ __convert_from_v(char* __out, const int __size, const char* __fmt, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ _Tv __v, const __c_locale& __cloc, int __prec) ++ { ++ __c_locale __old = __gnu_cxx::__uselocale(__cloc); ++#else ++ _Tv __v, const __c_locale&, int __prec) ++ { ++# ifdef __UCLIBC_HAS_LOCALE__ ++ char* __old = std::setlocale(LC_ALL, NULL); ++ char* __sav = new char[std::strlen(__old) + 1]; ++ std::strcpy(__sav, __old); ++ std::setlocale(LC_ALL, "C"); ++# endif ++#endif ++ ++ const int __ret = std::snprintf(__out, __size, __fmt, __prec, __v); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __gnu_cxx::__uselocale(__old); ++#elif defined __UCLIBC_HAS_LOCALE__ ++ std::setlocale(LC_ALL, __sav); ++ delete [] __sav; ++#endif ++ return __ret; ++ } ++} ++ ++#endif +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/codecvt_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/codecvt_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/codecvt_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/codecvt_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,306 @@ ++// std::codecvt implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.1.5 - Template class codecvt ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++namespace std ++{ ++ // Specializations. ++#ifdef _GLIBCXX_USE_WCHAR_T ++ codecvt_base::result ++ codecvt:: ++ do_out(state_type& __state, const intern_type* __from, ++ const intern_type* __from_end, const intern_type*& __from_next, ++ extern_type* __to, extern_type* __to_end, ++ extern_type*& __to_next) const ++ { ++ result __ret = ok; ++ state_type __tmp_state(__state); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ ++ // wcsnrtombs is *very* fast but stops if encounters NUL characters: ++ // in case we fall back to wcrtomb and then continue, in a loop. ++ // NB: wcsnrtombs is a GNU extension ++ for (__from_next = __from, __to_next = __to; ++ __from_next < __from_end && __to_next < __to_end ++ && __ret == ok;) ++ { ++ const intern_type* __from_chunk_end = wmemchr(__from_next, L'\0', ++ __from_end - __from_next); ++ if (!__from_chunk_end) ++ __from_chunk_end = __from_end; ++ ++ __from = __from_next; ++ const size_t __conv = wcsnrtombs(__to_next, &__from_next, ++ __from_chunk_end - __from_next, ++ __to_end - __to_next, &__state); ++ if (__conv == static_cast(-1)) ++ { ++ // In case of error, in order to stop at the exact place we ++ // have to start again from the beginning with a series of ++ // wcrtomb. ++ for (; __from < __from_next; ++__from) ++ __to_next += wcrtomb(__to_next, *__from, &__tmp_state); ++ __state = __tmp_state; ++ __ret = error; ++ } ++ else if (__from_next && __from_next < __from_chunk_end) ++ { ++ __to_next += __conv; ++ __ret = partial; ++ } ++ else ++ { ++ __from_next = __from_chunk_end; ++ __to_next += __conv; ++ } ++ ++ if (__from_next < __from_end && __ret == ok) ++ { ++ extern_type __buf[MB_LEN_MAX]; ++ __tmp_state = __state; ++ const size_t __conv = wcrtomb(__buf, *__from_next, &__tmp_state); ++ if (__conv > static_cast(__to_end - __to_next)) ++ __ret = partial; ++ else ++ { ++ memcpy(__to_next, __buf, __conv); ++ __state = __tmp_state; ++ __to_next += __conv; ++ ++__from_next; ++ } ++ } ++ } ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ return __ret; ++ } ++ ++ codecvt_base::result ++ codecvt:: ++ do_in(state_type& __state, const extern_type* __from, ++ const extern_type* __from_end, const extern_type*& __from_next, ++ intern_type* __to, intern_type* __to_end, ++ intern_type*& __to_next) const ++ { ++ result __ret = ok; ++ state_type __tmp_state(__state); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ ++ // mbsnrtowcs is *very* fast but stops if encounters NUL characters: ++ // in case we store a L'\0' and then continue, in a loop. ++ // NB: mbsnrtowcs is a GNU extension ++ for (__from_next = __from, __to_next = __to; ++ __from_next < __from_end && __to_next < __to_end ++ && __ret == ok;) ++ { ++ const extern_type* __from_chunk_end; ++ __from_chunk_end = static_cast(memchr(__from_next, '\0', ++ __from_end ++ - __from_next)); ++ if (!__from_chunk_end) ++ __from_chunk_end = __from_end; ++ ++ __from = __from_next; ++ size_t __conv = mbsnrtowcs(__to_next, &__from_next, ++ __from_chunk_end - __from_next, ++ __to_end - __to_next, &__state); ++ if (__conv == static_cast(-1)) ++ { ++ // In case of error, in order to stop at the exact place we ++ // have to start again from the beginning with a series of ++ // mbrtowc. ++ for (;; ++__to_next, __from += __conv) ++ { ++ __conv = mbrtowc(__to_next, __from, __from_end - __from, ++ &__tmp_state); ++ if (__conv == static_cast(-1) ++ || __conv == static_cast(-2)) ++ break; ++ } ++ __from_next = __from; ++ __state = __tmp_state; ++ __ret = error; ++ } ++ else if (__from_next && __from_next < __from_chunk_end) ++ { ++ // It is unclear what to return in this case (see DR 382). ++ __to_next += __conv; ++ __ret = partial; ++ } ++ else ++ { ++ __from_next = __from_chunk_end; ++ __to_next += __conv; ++ } ++ ++ if (__from_next < __from_end && __ret == ok) ++ { ++ if (__to_next < __to_end) ++ { ++ // XXX Probably wrong for stateful encodings ++ __tmp_state = __state; ++ ++__from_next; ++ *__to_next++ = L'\0'; ++ } ++ else ++ __ret = partial; ++ } ++ } ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ return __ret; ++ } ++ ++ int ++ codecvt:: ++ do_encoding() const throw() ++ { ++ // XXX This implementation assumes that the encoding is ++ // stateless and is either single-byte or variable-width. ++ int __ret = 0; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ if (MB_CUR_MAX == 1) ++ __ret = 1; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __ret; ++ } ++ ++ int ++ codecvt:: ++ do_max_length() const throw() ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ // XXX Probably wrong for stateful encodings. ++ int __ret = MB_CUR_MAX; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __ret; ++ } ++ ++ int ++ codecvt:: ++ do_length(state_type& __state, const extern_type* __from, ++ const extern_type* __end, size_t __max) const ++ { ++ int __ret = 0; ++ state_type __tmp_state(__state); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ ++ // mbsnrtowcs is *very* fast but stops if encounters NUL characters: ++ // in case we advance past it and then continue, in a loop. ++ // NB: mbsnrtowcs is a GNU extension ++ ++ // A dummy internal buffer is needed in order for mbsnrtocws to consider ++ // its fourth parameter (it wouldn't with NULL as first parameter). ++ wchar_t* __to = static_cast(__builtin_alloca(sizeof(wchar_t) ++ * __max)); ++ while (__from < __end && __max) ++ { ++ const extern_type* __from_chunk_end; ++ __from_chunk_end = static_cast(memchr(__from, '\0', ++ __end ++ - __from)); ++ if (!__from_chunk_end) ++ __from_chunk_end = __end; ++ ++ const extern_type* __tmp_from = __from; ++ size_t __conv = mbsnrtowcs(__to, &__from, ++ __from_chunk_end - __from, ++ __max, &__state); ++ if (__conv == static_cast(-1)) ++ { ++ // In case of error, in order to stop at the exact place we ++ // have to start again from the beginning with a series of ++ // mbrtowc. ++ for (__from = __tmp_from;; __from += __conv) ++ { ++ __conv = mbrtowc(NULL, __from, __end - __from, ++ &__tmp_state); ++ if (__conv == static_cast(-1) ++ || __conv == static_cast(-2)) ++ break; ++ } ++ __state = __tmp_state; ++ __ret += __from - __tmp_from; ++ break; ++ } ++ if (!__from) ++ __from = __from_chunk_end; ++ ++ __ret += __from - __tmp_from; ++ __max -= __conv; ++ ++ if (__from < __end && __max) ++ { ++ // XXX Probably wrong for stateful encodings ++ __tmp_state = __state; ++ ++__from; ++ ++__ret; ++ --__max; ++ } ++ } ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ return __ret; ++ } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/collate_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/collate_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/collate_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/collate_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,80 @@ ++// std::collate implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.4.1.2 collate virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __strcoll_l(S1, S2, L) strcoll((S1), (S2)) ++#define __strxfrm_l(S1, S2, N, L) strxfrm((S1), (S2), (N)) ++#define __wcscoll_l(S1, S2, L) wcscoll((S1), (S2)) ++#define __wcsxfrm_l(S1, S2, N, L) wcsxfrm((S1), (S2), (N)) ++#endif ++ ++namespace std ++{ ++ // These are basically extensions to char_traits, and perhaps should ++ // be put there instead of here. ++ template<> ++ int ++ collate::_M_compare(const char* __one, const char* __two) const ++ { ++ int __cmp = __strcoll_l(__one, __two, _M_c_locale_collate); ++ return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0); ++ } ++ ++ template<> ++ size_t ++ collate::_M_transform(char* __to, const char* __from, ++ size_t __n) const ++ { return __strxfrm_l(__to, __from, __n, _M_c_locale_collate); } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ int ++ collate::_M_compare(const wchar_t* __one, ++ const wchar_t* __two) const ++ { ++ int __cmp = __wcscoll_l(__one, __two, _M_c_locale_collate); ++ return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0); ++ } ++ ++ template<> ++ size_t ++ collate::_M_transform(wchar_t* __to, const wchar_t* __from, ++ size_t __n) const ++ { return __wcsxfrm_l(__to, __from, __n, _M_c_locale_collate); } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/ctype_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/ctype_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/ctype_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/ctype_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,300 @@ ++// std::ctype implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.1.1.2 ctype virtual functions. ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __wctype_l(S, L) wctype((S)) ++#define __towupper_l(C, L) towupper((C)) ++#define __towlower_l(C, L) towlower((C)) ++#define __iswctype_l(C, M, L) iswctype((C), (M)) ++#endif ++ ++namespace std ++{ ++ // NB: The other ctype specializations are in src/locale.cc and ++ // various /config/os/* files. ++ template<> ++ ctype_byname::ctype_byname(const char* __s, size_t __refs) ++ : ctype(0, false, __refs) ++ { ++ if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0) ++ { ++ this->_S_destroy_c_locale(this->_M_c_locale_ctype); ++ this->_S_create_c_locale(this->_M_c_locale_ctype, __s); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ this->_M_toupper = this->_M_c_locale_ctype->__ctype_toupper; ++ this->_M_tolower = this->_M_c_locale_ctype->__ctype_tolower; ++ this->_M_table = this->_M_c_locale_ctype->__ctype_b; ++#endif ++ } ++ } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ ctype::__wmask_type ++ ctype::_M_convert_to_wmask(const mask __m) const ++ { ++ __wmask_type __ret; ++ switch (__m) ++ { ++ case space: ++ __ret = __wctype_l("space", _M_c_locale_ctype); ++ break; ++ case print: ++ __ret = __wctype_l("print", _M_c_locale_ctype); ++ break; ++ case cntrl: ++ __ret = __wctype_l("cntrl", _M_c_locale_ctype); ++ break; ++ case upper: ++ __ret = __wctype_l("upper", _M_c_locale_ctype); ++ break; ++ case lower: ++ __ret = __wctype_l("lower", _M_c_locale_ctype); ++ break; ++ case alpha: ++ __ret = __wctype_l("alpha", _M_c_locale_ctype); ++ break; ++ case digit: ++ __ret = __wctype_l("digit", _M_c_locale_ctype); ++ break; ++ case punct: ++ __ret = __wctype_l("punct", _M_c_locale_ctype); ++ break; ++ case xdigit: ++ __ret = __wctype_l("xdigit", _M_c_locale_ctype); ++ break; ++ case alnum: ++ __ret = __wctype_l("alnum", _M_c_locale_ctype); ++ break; ++ case graph: ++ __ret = __wctype_l("graph", _M_c_locale_ctype); ++ break; ++ default: ++ __ret = 0; ++ } ++ return __ret; ++ } ++ ++ wchar_t ++ ctype::do_toupper(wchar_t __c) const ++ { return __towupper_l(__c, _M_c_locale_ctype); } ++ ++ const wchar_t* ++ ctype::do_toupper(wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi) ++ { ++ *__lo = __towupper_l(*__lo, _M_c_locale_ctype); ++ ++__lo; ++ } ++ return __hi; ++ } ++ ++ wchar_t ++ ctype::do_tolower(wchar_t __c) const ++ { return __towlower_l(__c, _M_c_locale_ctype); } ++ ++ const wchar_t* ++ ctype::do_tolower(wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi) ++ { ++ *__lo = __towlower_l(*__lo, _M_c_locale_ctype); ++ ++__lo; ++ } ++ return __hi; ++ } ++ ++ bool ++ ctype:: ++ do_is(mask __m, wchar_t __c) const ++ { ++ // Highest bitmask in ctype_base == 10, but extra in "C" ++ // library for blank. ++ bool __ret = false; ++ const size_t __bitmasksize = 11; ++ for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur) ++ if (__m & _M_bit[__bitcur] ++ && __iswctype_l(__c, _M_wmask[__bitcur], _M_c_locale_ctype)) ++ { ++ __ret = true; ++ break; ++ } ++ return __ret; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_is(const wchar_t* __lo, const wchar_t* __hi, mask* __vec) const ++ { ++ for (; __lo < __hi; ++__vec, ++__lo) ++ { ++ // Highest bitmask in ctype_base == 10, but extra in "C" ++ // library for blank. ++ const size_t __bitmasksize = 11; ++ mask __m = 0; ++ for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur) ++ if (__iswctype_l(*__lo, _M_wmask[__bitcur], _M_c_locale_ctype)) ++ __m |= _M_bit[__bitcur]; ++ *__vec = __m; ++ } ++ return __hi; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_scan_is(mask __m, const wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi && !this->do_is(__m, *__lo)) ++ ++__lo; ++ return __lo; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_scan_not(mask __m, const char_type* __lo, const char_type* __hi) const ++ { ++ while (__lo < __hi && this->do_is(__m, *__lo) != 0) ++ ++__lo; ++ return __lo; ++ } ++ ++ wchar_t ++ ctype:: ++ do_widen(char __c) const ++ { return _M_widen[static_cast(__c)]; } ++ ++ const char* ++ ctype:: ++ do_widen(const char* __lo, const char* __hi, wchar_t* __dest) const ++ { ++ while (__lo < __hi) ++ { ++ *__dest = _M_widen[static_cast(*__lo)]; ++ ++__lo; ++ ++__dest; ++ } ++ return __hi; ++ } ++ ++ char ++ ctype:: ++ do_narrow(wchar_t __wc, char __dfault) const ++ { ++ if (__wc >= 0 && __wc < 128 && _M_narrow_ok) ++ return _M_narrow[__wc]; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ const int __c = wctob(__wc); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return (__c == EOF ? __dfault : static_cast(__c)); ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault, ++ char* __dest) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ if (_M_narrow_ok) ++ while (__lo < __hi) ++ { ++ if (*__lo >= 0 && *__lo < 128) ++ *__dest = _M_narrow[*__lo]; ++ else ++ { ++ const int __c = wctob(*__lo); ++ *__dest = (__c == EOF ? __dfault : static_cast(__c)); ++ } ++ ++__lo; ++ ++__dest; ++ } ++ else ++ while (__lo < __hi) ++ { ++ const int __c = wctob(*__lo); ++ *__dest = (__c == EOF ? __dfault : static_cast(__c)); ++ ++__lo; ++ ++__dest; ++ } ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __hi; ++ } ++ ++ void ++ ctype::_M_initialize_ctype() ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ wint_t __i; ++ for (__i = 0; __i < 128; ++__i) ++ { ++ const int __c = wctob(__i); ++ if (__c == EOF) ++ break; ++ else ++ _M_narrow[__i] = static_cast(__c); ++ } ++ if (__i == 128) ++ _M_narrow_ok = true; ++ else ++ _M_narrow_ok = false; ++ for (size_t __j = 0; ++ __j < sizeof(_M_widen) / sizeof(wint_t); ++__j) ++ _M_widen[__j] = btowc(__j); ++ ++ for (size_t __k = 0; __k <= 11; ++__k) ++ { ++ _M_bit[__k] = static_cast(_ISbit(__k)); ++ _M_wmask[__k] = _M_convert_to_wmask(_M_bit[__k]); ++ } ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ } ++#endif // _GLIBCXX_USE_WCHAR_T ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/messages_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/messages_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/messages_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/messages_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,100 @@ ++// std::messages implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.7.1.2 messages virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix gettext stuff ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++extern "C" char *__dcgettext(const char *domainname, ++ const char *msgid, int category); ++#undef gettext ++#define gettext(msgid) __dcgettext(NULL, msgid, LC_MESSAGES) ++#else ++#undef gettext ++#define gettext(msgid) (msgid) ++#endif ++ ++namespace std ++{ ++ // Specializations. ++ template<> ++ string ++ messages::do_get(catalog, int, int, const string& __dfault) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_messages); ++ const char* __msg = const_cast(gettext(__dfault.c_str())); ++ __uselocale(__old); ++ return string(__msg); ++#elif defined __UCLIBC_HAS_LOCALE__ ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_messages); ++ const char* __msg = gettext(__dfault.c_str()); ++ setlocale(LC_ALL, __old); ++ free(__old); ++ return string(__msg); ++#else ++ const char* __msg = gettext(__dfault.c_str()); ++ return string(__msg); ++#endif ++ } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ wstring ++ messages::do_get(catalog, int, int, const wstring& __dfault) const ++ { ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_messages); ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ __uselocale(__old); ++ return _M_convert_from_char(__msg); ++# elif defined __UCLIBC_HAS_LOCALE__ ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_messages); ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ setlocale(LC_ALL, __old); ++ free(__old); ++ return _M_convert_from_char(__msg); ++# else ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ return _M_convert_from_char(__msg); ++# endif ++ } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/messages_members.h gcc-3.4.2/libstdc++-v3/config/locale/uclibc/messages_members.h +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/messages_members.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/messages_members.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,118 @@ ++// std::messages implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.7.1.2 messages functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix prototypes for *textdomain funcs ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++extern "C" char *__textdomain(const char *domainname); ++extern "C" char *__bindtextdomain(const char *domainname, ++ const char *dirname); ++#else ++#undef __textdomain ++#undef __bindtextdomain ++#define __textdomain(D) ((void)0) ++#define __bindtextdomain(D,P) ((void)0) ++#endif ++ ++ // Non-virtual member functions. ++ template ++ messages<_CharT>::messages(size_t __refs) ++ : facet(__refs), _M_c_locale_messages(_S_get_c_locale()), ++ _M_name_messages(_S_get_c_name()) ++ { } ++ ++ template ++ messages<_CharT>::messages(__c_locale __cloc, const char* __s, ++ size_t __refs) ++ : facet(__refs), _M_c_locale_messages(_S_clone_c_locale(__cloc)), ++ _M_name_messages(__s) ++ { ++ char* __tmp = new char[std::strlen(__s) + 1]; ++ std::strcpy(__tmp, __s); ++ _M_name_messages = __tmp; ++ } ++ ++ template ++ typename messages<_CharT>::catalog ++ messages<_CharT>::open(const basic_string& __s, const locale& __loc, ++ const char* __dir) const ++ { ++ __bindtextdomain(__s.c_str(), __dir); ++ return this->do_open(__s, __loc); ++ } ++ ++ // Virtual member functions. ++ template ++ messages<_CharT>::~messages() ++ { ++ if (_M_name_messages != _S_get_c_name()) ++ delete [] _M_name_messages; ++ _S_destroy_c_locale(_M_c_locale_messages); ++ } ++ ++ template ++ typename messages<_CharT>::catalog ++ messages<_CharT>::do_open(const basic_string& __s, ++ const locale&) const ++ { ++ // No error checking is done, assume the catalog exists and can ++ // be used. ++ __textdomain(__s.c_str()); ++ return 0; ++ } ++ ++ template ++ void ++ messages<_CharT>::do_close(catalog) const ++ { } ++ ++ // messages_byname ++ template ++ messages_byname<_CharT>::messages_byname(const char* __s, size_t __refs) ++ : messages<_CharT>(__refs) ++ { ++ if (this->_M_name_messages != locale::facet::_S_get_c_name()) ++ delete [] this->_M_name_messages; ++ char* __tmp = new char[std::strlen(__s) + 1]; ++ std::strcpy(__tmp, __s); ++ this->_M_name_messages = __tmp; ++ ++ if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0) ++ { ++ this->_S_destroy_c_locale(this->_M_c_locale_messages); ++ this->_S_create_c_locale(this->_M_c_locale_messages, __s); ++ } ++ } +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/monetary_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/monetary_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/monetary_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/monetary_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,698 @@ ++// std::moneypunct implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.6.3.2 moneypunct virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning optimize this for uclibc ++#warning tailor for stub locale support ++#endif ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ // Construct and return valid pattern consisting of some combination of: ++ // space none symbol sign value ++ money_base::pattern ++ money_base::_S_construct_pattern(char __precedes, char __space, char __posn) ++ { ++ pattern __ret; ++ ++ // This insanely complicated routine attempts to construct a valid ++ // pattern for use with monyepunct. A couple of invariants: ++ ++ // if (__precedes) symbol -> value ++ // else value -> symbol ++ ++ // if (__space) space ++ // else none ++ ++ // none == never first ++ // space never first or last ++ ++ // Any elegant implementations of this are welcome. ++ switch (__posn) ++ { ++ case 0: ++ case 1: ++ // 1 The sign precedes the value and symbol. ++ __ret.field[0] = sign; ++ if (__space) ++ { ++ // Pattern starts with sign. ++ if (__precedes) ++ { ++ __ret.field[1] = symbol; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[1] = value; ++ __ret.field[3] = symbol; ++ } ++ __ret.field[2] = space; ++ } ++ else ++ { ++ // Pattern starts with sign and ends with none. ++ if (__precedes) ++ { ++ __ret.field[1] = symbol; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[1] = value; ++ __ret.field[2] = symbol; ++ } ++ __ret.field[3] = none; ++ } ++ break; ++ case 2: ++ // 2 The sign follows the value and symbol. ++ if (__space) ++ { ++ // Pattern either ends with sign. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[2] = symbol; ++ } ++ __ret.field[1] = space; ++ __ret.field[3] = sign; ++ } ++ else ++ { ++ // Pattern ends with sign then none. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[1] = symbol; ++ } ++ __ret.field[2] = sign; ++ __ret.field[3] = none; ++ } ++ break; ++ case 3: ++ // 3 The sign immediately precedes the symbol. ++ if (__precedes) ++ { ++ __ret.field[0] = sign; ++ __ret.field[1] = symbol; ++ if (__space) ++ { ++ __ret.field[2] = space; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[2] = value; ++ __ret.field[3] = none; ++ } ++ } ++ else ++ { ++ __ret.field[0] = value; ++ if (__space) ++ { ++ __ret.field[1] = space; ++ __ret.field[2] = sign; ++ __ret.field[3] = symbol; ++ } ++ else ++ { ++ __ret.field[1] = sign; ++ __ret.field[2] = symbol; ++ __ret.field[3] = none; ++ } ++ } ++ break; ++ case 4: ++ // 4 The sign immediately follows the symbol. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = sign; ++ if (__space) ++ { ++ __ret.field[2] = space; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[2] = value; ++ __ret.field[3] = none; ++ } ++ } ++ else ++ { ++ __ret.field[0] = value; ++ if (__space) ++ { ++ __ret.field[1] = space; ++ __ret.field[2] = symbol; ++ __ret.field[3] = sign; ++ } ++ else ++ { ++ __ret.field[1] = symbol; ++ __ret.field[2] = sign; ++ __ret.field[3] = none; ++ } ++ } ++ break; ++ default: ++ ; ++ } ++ return __ret; ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++ const char*) ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = '.'; ++ _M_data->_M_thousands_sep = ','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = ""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = ""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = ""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ _M_data->_M_atoms[__i] = money_base::_S_atoms[__i]; ++ } ++ else ++ { ++ // Named locale. ++ _M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT, ++ __cloc)); ++ _M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP, ++ __cloc)); ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ _M_data->_M_positive_sign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ _M_data->_M_positive_sign_size = strlen(_M_data->_M_positive_sign); ++ ++ char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc)); ++ if (!__nposn) ++ _M_data->_M_negative_sign = "()"; ++ else ++ _M_data->_M_negative_sign = __nl_langinfo_l(__NEGATIVE_SIGN, ++ __cloc); ++ _M_data->_M_negative_sign_size = strlen(_M_data->_M_negative_sign); ++ ++ // _Intl == true ++ _M_data->_M_curr_symbol = __nl_langinfo_l(__INT_CURR_SYMBOL, __cloc); ++ _M_data->_M_curr_symbol_size = strlen(_M_data->_M_curr_symbol); ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS, ++ __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__INT_P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__INT_P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__INT_P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__INT_N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__INT_N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ } ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++ const char*) ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = '.'; ++ _M_data->_M_thousands_sep = ','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = ""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = ""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = ""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ _M_data->_M_atoms[__i] = money_base::_S_atoms[__i]; ++ } ++ else ++ { ++ // Named locale. ++ _M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT, ++ __cloc)); ++ _M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP, ++ __cloc)); ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ _M_data->_M_positive_sign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ _M_data->_M_positive_sign_size = strlen(_M_data->_M_positive_sign); ++ ++ char __nposn = *(__nl_langinfo_l(__N_SIGN_POSN, __cloc)); ++ if (!__nposn) ++ _M_data->_M_negative_sign = "()"; ++ else ++ _M_data->_M_negative_sign = __nl_langinfo_l(__NEGATIVE_SIGN, ++ __cloc); ++ _M_data->_M_negative_sign_size = strlen(_M_data->_M_negative_sign); ++ ++ // _Intl == false ++ _M_data->_M_curr_symbol = __nl_langinfo_l(__CURRENCY_SYMBOL, __cloc); ++ _M_data->_M_curr_symbol_size = strlen(_M_data->_M_curr_symbol); ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ } ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { delete _M_data; } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { delete _M_data; } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const char*) ++#else ++ const char* __name) ++#endif ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = L'.'; ++ _M_data->_M_thousands_sep = L','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ // Use ctype::widen code without the facet... ++ unsigned char uc; ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ { ++ uc = static_cast(money_base::_S_atoms[__i]); ++ _M_data->_M_atoms[__i] = btowc(uc); ++ } ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(__cloc); ++#else ++ // Switch to named locale so that mbsrtowcs will work. ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, __name); ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this... should be monetary ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_data->_M_decimal_point = __cloc->decimal_point_wc; ++ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_data->_M_decimal_point = __global_locale->decimal_point_wc; ++ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ union __s_and_w { const char *__s; unsigned int __w; } __u; ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_DECIMAL_POINT_WC, __cloc); ++ _M_data->_M_decimal_point = static_cast(__u.__w); ++ ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_THOUSANDS_SEP_WC, __cloc); ++ _M_data->_M_thousands_sep = static_cast(__u.__w); ++#endif ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ ++ const char* __cpossign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ const char* __cnegsign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ const char* __ccurr = __nl_langinfo_l(__INT_CURR_SYMBOL, __cloc); ++ ++ wchar_t* __wcs_ps = 0; ++ wchar_t* __wcs_ns = 0; ++ const char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc)); ++ try ++ { ++ mbstate_t __state; ++ size_t __len = strlen(__cpossign); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ps = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ps, &__cpossign, __len, &__state); ++ _M_data->_M_positive_sign = __wcs_ps; ++ } ++ else ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = wcslen(_M_data->_M_positive_sign); ++ ++ __len = strlen(__cnegsign); ++ if (!__nposn) ++ _M_data->_M_negative_sign = L"()"; ++ else if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ns = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ns, &__cnegsign, __len, &__state); ++ _M_data->_M_negative_sign = __wcs_ns; ++ } ++ else ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = wcslen(_M_data->_M_negative_sign); ++ ++ // _Intl == true. ++ __len = strlen(__ccurr); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__ccurr, __len, &__state); ++ _M_data->_M_curr_symbol = __wcs; ++ } ++ else ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = wcslen(_M_data->_M_curr_symbol); ++ } ++ catch (...) ++ { ++ delete _M_data; ++ _M_data = 0; ++ delete __wcs_ps; ++ delete __wcs_ns; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ __throw_exception_again; ++ } ++ ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS, ++ __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__INT_P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__INT_P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__INT_P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__INT_N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__INT_N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const char*) ++#else ++ const char* __name) ++#endif ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = L'.'; ++ _M_data->_M_thousands_sep = L','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ // Use ctype::widen code without the facet... ++ unsigned char uc; ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ { ++ uc = static_cast(money_base::_S_atoms[__i]); ++ _M_data->_M_atoms[__i] = btowc(uc); ++ } ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(__cloc); ++#else ++ // Switch to named locale so that mbsrtowcs will work. ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, __name); ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this... should be monetary ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_data->_M_decimal_point = __cloc->decimal_point_wc; ++ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_data->_M_decimal_point = __global_locale->decimal_point_wc; ++ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ union __s_and_w { const char *__s; unsigned int __w; } __u; ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_DECIMAL_POINT_WC, __cloc); ++ _M_data->_M_decimal_point = static_cast(__u.__w); ++ ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_THOUSANDS_SEP_WC, __cloc); ++ _M_data->_M_thousands_sep = static_cast(__u.__w); ++#endif ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ ++ const char* __cpossign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ const char* __cnegsign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ const char* __ccurr = __nl_langinfo_l(__CURRENCY_SYMBOL, __cloc); ++ ++ wchar_t* __wcs_ps = 0; ++ wchar_t* __wcs_ns = 0; ++ const char __nposn = *(__nl_langinfo_l(__N_SIGN_POSN, __cloc)); ++ try ++ { ++ mbstate_t __state; ++ size_t __len; ++ __len = strlen(__cpossign); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ps = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ps, &__cpossign, __len, &__state); ++ _M_data->_M_positive_sign = __wcs_ps; ++ } ++ else ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = wcslen(_M_data->_M_positive_sign); ++ ++ __len = strlen(__cnegsign); ++ if (!__nposn) ++ _M_data->_M_negative_sign = L"()"; ++ else if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ns = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ns, &__cnegsign, __len, &__state); ++ _M_data->_M_negative_sign = __wcs_ns; ++ } ++ else ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = wcslen(_M_data->_M_negative_sign); ++ ++ // _Intl == true. ++ __len = strlen(__ccurr); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__ccurr, __len, &__state); ++ _M_data->_M_curr_symbol = __wcs; ++ } ++ else ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = wcslen(_M_data->_M_curr_symbol); ++ } ++ catch (...) ++ { ++ delete _M_data; ++ _M_data = 0; ++ delete __wcs_ps; ++ delete __wcs_ns; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ __throw_exception_again; ++ } ++ ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { ++ if (_M_data->_M_positive_sign_size) ++ delete [] _M_data->_M_positive_sign; ++ if (_M_data->_M_negative_sign_size ++ && wcscmp(_M_data->_M_negative_sign, L"()") != 0) ++ delete [] _M_data->_M_negative_sign; ++ if (_M_data->_M_curr_symbol_size) ++ delete [] _M_data->_M_curr_symbol; ++ delete _M_data; ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { ++ if (_M_data->_M_positive_sign_size) ++ delete [] _M_data->_M_positive_sign; ++ if (_M_data->_M_negative_sign_size ++ && wcscmp(_M_data->_M_negative_sign, L"()") != 0) ++ delete [] _M_data->_M_negative_sign; ++ if (_M_data->_M_curr_symbol_size) ++ delete [] _M_data->_M_curr_symbol; ++ delete _M_data; ++ } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/numeric_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/numeric_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/numeric_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/numeric_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,183 @@ ++// std::numpunct implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.3.1.2 numpunct virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning tailor for stub locale support ++#endif ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ numpunct::_M_initialize_numpunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __numpunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_use_grouping = false; ++ ++ _M_data->_M_decimal_point = '.'; ++ _M_data->_M_thousands_sep = ','; ++ ++ for (size_t __i = 0; __i < __num_base::_S_oend; ++__i) ++ _M_data->_M_atoms_out[__i] = __num_base::_S_atoms_out[__i]; ++ ++ for (size_t __j = 0; __j < __num_base::_S_iend; ++__j) ++ _M_data->_M_atoms_in[__j] = __num_base::_S_atoms_in[__j]; ++ } ++ else ++ { ++ // Named locale. ++ _M_data->_M_decimal_point = *(__nl_langinfo_l(DECIMAL_POINT, ++ __cloc)); ++ _M_data->_M_thousands_sep = *(__nl_langinfo_l(THOUSANDS_SEP, ++ __cloc)); ++ ++ // Check for NULL, which implies no grouping. ++ if (_M_data->_M_thousands_sep == '\0') ++ _M_data->_M_grouping = ""; ++ else ++ _M_data->_M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ } ++ ++ // NB: There is no way to extact this info from posix locales. ++ // _M_truename = __nl_langinfo_l(YESSTR, __cloc); ++ _M_data->_M_truename = "true"; ++ _M_data->_M_truename_size = strlen(_M_data->_M_truename); ++ // _M_falsename = __nl_langinfo_l(NOSTR, __cloc); ++ _M_data->_M_falsename = "false"; ++ _M_data->_M_falsename_size = strlen(_M_data->_M_falsename); ++ } ++ ++ template<> ++ numpunct::~numpunct() ++ { delete _M_data; } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ void ++ numpunct::_M_initialize_numpunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __numpunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_use_grouping = false; ++ ++ _M_data->_M_decimal_point = L'.'; ++ _M_data->_M_thousands_sep = L','; ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_S_get_c_locale()); ++#endif ++ // Use ctype::widen code without the facet... ++ unsigned char uc; ++ for (size_t __i = 0; __i < __num_base::_S_oend; ++__i) ++ { ++ uc = static_cast(__num_base::_S_atoms_out[__i]); ++ _M_data->_M_atoms_out[__i] = btowc(uc); ++ } ++ ++ for (size_t __j = 0; __j < __num_base::_S_iend; ++__j) ++ { ++ uc = static_cast(__num_base::_S_atoms_in[__j]); ++ _M_data->_M_atoms_in[__j] = btowc(uc); ++ } ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_data->_M_decimal_point = __cloc->decimal_point_wc; ++ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_data->_M_decimal_point = __global_locale->decimal_point_wc; ++ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ union __s_and_w { const char *__s; unsigned int __w; } __u; ++ __u.__s = __nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc); ++ _M_data->_M_decimal_point = static_cast(__u.__w); ++ ++ __u.__s = __nl_langinfo_l(_NL_NUMERIC_THOUSANDS_SEP_WC, __cloc); ++ _M_data->_M_thousands_sep = static_cast(__u.__w); ++#endif ++ ++ if (_M_data->_M_thousands_sep == L'\0') ++ _M_data->_M_grouping = ""; ++ else ++ _M_data->_M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ } ++ ++ // NB: There is no way to extact this info from posix locales. ++ // _M_truename = __nl_langinfo_l(YESSTR, __cloc); ++ _M_data->_M_truename = L"true"; ++ _M_data->_M_truename_size = wcslen(_M_data->_M_truename); ++ // _M_falsename = __nl_langinfo_l(NOSTR, __cloc); ++ _M_data->_M_falsename = L"false"; ++ _M_data->_M_falsename_size = wcslen(_M_data->_M_falsename); ++ } ++ ++ template<> ++ numpunct::~numpunct() ++ { delete _M_data; } ++ #endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/time_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/time_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/time_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/time_members.cc 2004-09-10 10:48:00.000000000 -0500 +@@ -0,0 +1,356 @@ ++// std::time_get, std::time_put implementation, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.5.1.2 - time_get virtual functions ++// ISO C++ 14882: 22.2.5.3.2 - time_put virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning tailor for stub locale support ++#endif ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ __timepunct:: ++ _M_put(char* __s, size_t __maxlen, const char* __format, ++ const tm* __tm) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const size_t __len = __strftime_l(__s, __maxlen, __format, __tm, ++ _M_c_locale_timepunct); ++#else ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_timepunct); ++ const size_t __len = strftime(__s, __maxlen, __format, __tm); ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ // Make sure __s is null terminated. ++ if (__len == 0) ++ __s[0] = '\0'; ++ } ++ ++ template<> ++ void ++ __timepunct::_M_initialize_timepunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __timepunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_c_locale_timepunct = _S_get_c_locale(); ++ ++ _M_data->_M_date_format = "%m/%d/%y"; ++ _M_data->_M_date_era_format = "%m/%d/%y"; ++ _M_data->_M_time_format = "%H:%M:%S"; ++ _M_data->_M_time_era_format = "%H:%M:%S"; ++ _M_data->_M_date_time_format = ""; ++ _M_data->_M_date_time_era_format = ""; ++ _M_data->_M_am = "AM"; ++ _M_data->_M_pm = "PM"; ++ _M_data->_M_am_pm_format = ""; ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = "Sunday"; ++ _M_data->_M_day2 = "Monday"; ++ _M_data->_M_day3 = "Tuesday"; ++ _M_data->_M_day4 = "Wednesday"; ++ _M_data->_M_day5 = "Thursday"; ++ _M_data->_M_day6 = "Friday"; ++ _M_data->_M_day7 = "Saturday"; ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = "Sun"; ++ _M_data->_M_aday2 = "Mon"; ++ _M_data->_M_aday3 = "Tue"; ++ _M_data->_M_aday4 = "Wed"; ++ _M_data->_M_aday5 = "Thu"; ++ _M_data->_M_aday6 = "Fri"; ++ _M_data->_M_aday7 = "Sat"; ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = "January"; ++ _M_data->_M_month02 = "February"; ++ _M_data->_M_month03 = "March"; ++ _M_data->_M_month04 = "April"; ++ _M_data->_M_month05 = "May"; ++ _M_data->_M_month06 = "June"; ++ _M_data->_M_month07 = "July"; ++ _M_data->_M_month08 = "August"; ++ _M_data->_M_month09 = "September"; ++ _M_data->_M_month10 = "October"; ++ _M_data->_M_month11 = "November"; ++ _M_data->_M_month12 = "December"; ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = "Jan"; ++ _M_data->_M_amonth02 = "Feb"; ++ _M_data->_M_amonth03 = "Mar"; ++ _M_data->_M_amonth04 = "Apr"; ++ _M_data->_M_amonth05 = "May"; ++ _M_data->_M_amonth06 = "Jun"; ++ _M_data->_M_amonth07 = "Jul"; ++ _M_data->_M_amonth08 = "Aug"; ++ _M_data->_M_amonth09 = "Sep"; ++ _M_data->_M_amonth10 = "Oct"; ++ _M_data->_M_amonth11 = "Nov"; ++ _M_data->_M_amonth12 = "Dec"; ++ } ++ else ++ { ++ _M_c_locale_timepunct = _S_clone_c_locale(__cloc); ++ ++ _M_data->_M_date_format = __nl_langinfo_l(D_FMT, __cloc); ++ _M_data->_M_date_era_format = __nl_langinfo_l(ERA_D_FMT, __cloc); ++ _M_data->_M_time_format = __nl_langinfo_l(T_FMT, __cloc); ++ _M_data->_M_time_era_format = __nl_langinfo_l(ERA_T_FMT, __cloc); ++ _M_data->_M_date_time_format = __nl_langinfo_l(D_T_FMT, __cloc); ++ _M_data->_M_date_time_era_format = __nl_langinfo_l(ERA_D_T_FMT, __cloc); ++ _M_data->_M_am = __nl_langinfo_l(AM_STR, __cloc); ++ _M_data->_M_pm = __nl_langinfo_l(PM_STR, __cloc); ++ _M_data->_M_am_pm_format = __nl_langinfo_l(T_FMT_AMPM, __cloc); ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = __nl_langinfo_l(DAY_1, __cloc); ++ _M_data->_M_day2 = __nl_langinfo_l(DAY_2, __cloc); ++ _M_data->_M_day3 = __nl_langinfo_l(DAY_3, __cloc); ++ _M_data->_M_day4 = __nl_langinfo_l(DAY_4, __cloc); ++ _M_data->_M_day5 = __nl_langinfo_l(DAY_5, __cloc); ++ _M_data->_M_day6 = __nl_langinfo_l(DAY_6, __cloc); ++ _M_data->_M_day7 = __nl_langinfo_l(DAY_7, __cloc); ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = __nl_langinfo_l(ABDAY_1, __cloc); ++ _M_data->_M_aday2 = __nl_langinfo_l(ABDAY_2, __cloc); ++ _M_data->_M_aday3 = __nl_langinfo_l(ABDAY_3, __cloc); ++ _M_data->_M_aday4 = __nl_langinfo_l(ABDAY_4, __cloc); ++ _M_data->_M_aday5 = __nl_langinfo_l(ABDAY_5, __cloc); ++ _M_data->_M_aday6 = __nl_langinfo_l(ABDAY_6, __cloc); ++ _M_data->_M_aday7 = __nl_langinfo_l(ABDAY_7, __cloc); ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = __nl_langinfo_l(MON_1, __cloc); ++ _M_data->_M_month02 = __nl_langinfo_l(MON_2, __cloc); ++ _M_data->_M_month03 = __nl_langinfo_l(MON_3, __cloc); ++ _M_data->_M_month04 = __nl_langinfo_l(MON_4, __cloc); ++ _M_data->_M_month05 = __nl_langinfo_l(MON_5, __cloc); ++ _M_data->_M_month06 = __nl_langinfo_l(MON_6, __cloc); ++ _M_data->_M_month07 = __nl_langinfo_l(MON_7, __cloc); ++ _M_data->_M_month08 = __nl_langinfo_l(MON_8, __cloc); ++ _M_data->_M_month09 = __nl_langinfo_l(MON_9, __cloc); ++ _M_data->_M_month10 = __nl_langinfo_l(MON_10, __cloc); ++ _M_data->_M_month11 = __nl_langinfo_l(MON_11, __cloc); ++ _M_data->_M_month12 = __nl_langinfo_l(MON_12, __cloc); ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = __nl_langinfo_l(ABMON_1, __cloc); ++ _M_data->_M_amonth02 = __nl_langinfo_l(ABMON_2, __cloc); ++ _M_data->_M_amonth03 = __nl_langinfo_l(ABMON_3, __cloc); ++ _M_data->_M_amonth04 = __nl_langinfo_l(ABMON_4, __cloc); ++ _M_data->_M_amonth05 = __nl_langinfo_l(ABMON_5, __cloc); ++ _M_data->_M_amonth06 = __nl_langinfo_l(ABMON_6, __cloc); ++ _M_data->_M_amonth07 = __nl_langinfo_l(ABMON_7, __cloc); ++ _M_data->_M_amonth08 = __nl_langinfo_l(ABMON_8, __cloc); ++ _M_data->_M_amonth09 = __nl_langinfo_l(ABMON_9, __cloc); ++ _M_data->_M_amonth10 = __nl_langinfo_l(ABMON_10, __cloc); ++ _M_data->_M_amonth11 = __nl_langinfo_l(ABMON_11, __cloc); ++ _M_data->_M_amonth12 = __nl_langinfo_l(ABMON_12, __cloc); ++ } ++ } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ void ++ __timepunct:: ++ _M_put(wchar_t* __s, size_t __maxlen, const wchar_t* __format, ++ const tm* __tm) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __wcsftime_l(__s, __maxlen, __format, __tm, _M_c_locale_timepunct); ++ const size_t __len = __wcsftime_l(__s, __maxlen, __format, __tm, ++ _M_c_locale_timepunct); ++#else ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_timepunct); ++ const size_t __len = wcsftime(__s, __maxlen, __format, __tm); ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ // Make sure __s is null terminated. ++ if (__len == 0) ++ __s[0] = L'\0'; ++ } ++ ++ template<> ++ void ++ __timepunct::_M_initialize_timepunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __timepunct_cache; ++ ++#warning wide time stuff ++// if (!__cloc) ++ { ++ // "C" locale ++ _M_c_locale_timepunct = _S_get_c_locale(); ++ ++ _M_data->_M_date_format = L"%m/%d/%y"; ++ _M_data->_M_date_era_format = L"%m/%d/%y"; ++ _M_data->_M_time_format = L"%H:%M:%S"; ++ _M_data->_M_time_era_format = L"%H:%M:%S"; ++ _M_data->_M_date_time_format = L""; ++ _M_data->_M_date_time_era_format = L""; ++ _M_data->_M_am = L"AM"; ++ _M_data->_M_pm = L"PM"; ++ _M_data->_M_am_pm_format = L""; ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = L"Sunday"; ++ _M_data->_M_day2 = L"Monday"; ++ _M_data->_M_day3 = L"Tuesday"; ++ _M_data->_M_day4 = L"Wednesday"; ++ _M_data->_M_day5 = L"Thursday"; ++ _M_data->_M_day6 = L"Friday"; ++ _M_data->_M_day7 = L"Saturday"; ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = L"Sun"; ++ _M_data->_M_aday2 = L"Mon"; ++ _M_data->_M_aday3 = L"Tue"; ++ _M_data->_M_aday4 = L"Wed"; ++ _M_data->_M_aday5 = L"Thu"; ++ _M_data->_M_aday6 = L"Fri"; ++ _M_data->_M_aday7 = L"Sat"; ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = L"January"; ++ _M_data->_M_month02 = L"February"; ++ _M_data->_M_month03 = L"March"; ++ _M_data->_M_month04 = L"April"; ++ _M_data->_M_month05 = L"May"; ++ _M_data->_M_month06 = L"June"; ++ _M_data->_M_month07 = L"July"; ++ _M_data->_M_month08 = L"August"; ++ _M_data->_M_month09 = L"September"; ++ _M_data->_M_month10 = L"October"; ++ _M_data->_M_month11 = L"November"; ++ _M_data->_M_month12 = L"December"; ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = L"Jan"; ++ _M_data->_M_amonth02 = L"Feb"; ++ _M_data->_M_amonth03 = L"Mar"; ++ _M_data->_M_amonth04 = L"Apr"; ++ _M_data->_M_amonth05 = L"May"; ++ _M_data->_M_amonth06 = L"Jun"; ++ _M_data->_M_amonth07 = L"Jul"; ++ _M_data->_M_amonth08 = L"Aug"; ++ _M_data->_M_amonth09 = L"Sep"; ++ _M_data->_M_amonth10 = L"Oct"; ++ _M_data->_M_amonth11 = L"Nov"; ++ _M_data->_M_amonth12 = L"Dec"; ++ } ++#if 0 ++ else ++ { ++ _M_c_locale_timepunct = _S_clone_c_locale(__cloc); ++ ++ _M_data->_M_date_format = reinterpret_cast(__nl_langinfo_l(_NL_WD_FMT, __cloc)); ++ _M_data->_M_date_era_format = reinterpret_cast(__nl_langinfo_l(_NL_WERA_D_FMT, __cloc)); ++ _M_data->_M_time_format = reinterpret_cast(__nl_langinfo_l(_NL_WT_FMT, __cloc)); ++ _M_data->_M_time_era_format = reinterpret_cast(__nl_langinfo_l(_NL_WERA_T_FMT, __cloc)); ++ _M_data->_M_date_time_format = reinterpret_cast(__nl_langinfo_l(_NL_WD_T_FMT, __cloc)); ++ _M_data->_M_date_time_era_format = reinterpret_cast(__nl_langinfo_l(_NL_WERA_D_T_FMT, __cloc)); ++ _M_data->_M_am = reinterpret_cast(__nl_langinfo_l(_NL_WAM_STR, __cloc)); ++ _M_data->_M_pm = reinterpret_cast(__nl_langinfo_l(_NL_WPM_STR, __cloc)); ++ _M_data->_M_am_pm_format = reinterpret_cast(__nl_langinfo_l(_NL_WT_FMT_AMPM, __cloc)); ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_1, __cloc)); ++ _M_data->_M_day2 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_2, __cloc)); ++ _M_data->_M_day3 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_3, __cloc)); ++ _M_data->_M_day4 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_4, __cloc)); ++ _M_data->_M_day5 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_5, __cloc)); ++ _M_data->_M_day6 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_6, __cloc)); ++ _M_data->_M_day7 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_7, __cloc)); ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_1, __cloc)); ++ _M_data->_M_aday2 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_2, __cloc)); ++ _M_data->_M_aday3 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_3, __cloc)); ++ _M_data->_M_aday4 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_4, __cloc)); ++ _M_data->_M_aday5 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_5, __cloc)); ++ _M_data->_M_aday6 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_6, __cloc)); ++ _M_data->_M_aday7 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_7, __cloc)); ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_1, __cloc)); ++ _M_data->_M_month02 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_2, __cloc)); ++ _M_data->_M_month03 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_3, __cloc)); ++ _M_data->_M_month04 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_4, __cloc)); ++ _M_data->_M_month05 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_5, __cloc)); ++ _M_data->_M_month06 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_6, __cloc)); ++ _M_data->_M_month07 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_7, __cloc)); ++ _M_data->_M_month08 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_8, __cloc)); ++ _M_data->_M_month09 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_9, __cloc)); ++ _M_data->_M_month10 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_10, __cloc)); ++ _M_data->_M_month11 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_11, __cloc)); ++ _M_data->_M_month12 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_12, __cloc)); ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_1, __cloc)); ++ _M_data->_M_amonth02 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_2, __cloc)); ++ _M_data->_M_amonth03 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_3, __cloc)); ++ _M_data->_M_amonth04 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_4, __cloc)); ++ _M_data->_M_amonth05 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_5, __cloc)); ++ _M_data->_M_amonth06 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_6, __cloc)); ++ _M_data->_M_amonth07 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_7, __cloc)); ++ _M_data->_M_amonth08 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_8, __cloc)); ++ _M_data->_M_amonth09 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_9, __cloc)); ++ _M_data->_M_amonth10 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_10, __cloc)); ++ _M_data->_M_amonth11 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_11, __cloc)); ++ _M_data->_M_amonth12 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_12, __cloc)); ++ } ++#endif // 0 ++ } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/time_members.h gcc-3.4.2/libstdc++-v3/config/locale/uclibc/time_members.h +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/time_members.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/time_members.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,68 @@ ++// std::time_get, std::time_put implementation, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.5.1.2 - time_get functions ++// ISO C++ 14882: 22.2.5.3.2 - time_put functions ++// ++ ++// Written by Benjamin Kosnik ++ ++ template ++ __timepunct<_CharT>::__timepunct(size_t __refs) ++ : facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL), ++ _M_name_timepunct(_S_get_c_name()) ++ { _M_initialize_timepunct(); } ++ ++ template ++ __timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs) ++ : facet(__refs), _M_data(__cache), _M_c_locale_timepunct(NULL), ++ _M_name_timepunct(_S_get_c_name()) ++ { _M_initialize_timepunct(); } ++ ++ template ++ __timepunct<_CharT>::__timepunct(__c_locale __cloc, const char* __s, ++ size_t __refs) ++ : facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL), ++ _M_name_timepunct(__s) ++ { ++ char* __tmp = new char[std::strlen(__s) + 1]; ++ std::strcpy(__tmp, __s); ++ _M_name_timepunct = __tmp; ++ _M_initialize_timepunct(__cloc); ++ } ++ ++ template ++ __timepunct<_CharT>::~__timepunct() ++ { ++ if (_M_name_timepunct != _S_get_c_name()) ++ delete [] _M_name_timepunct; ++ delete _M_data; ++ _S_destroy_c_locale(_M_c_locale_timepunct); ++ } +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_base.h gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_base.h +--- gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_base.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_base.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,58 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 1997, 1998, 1999, 2000, 2002, 2003 ++// Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// Information as gleaned from /usr/include/ctype.h ++ ++ struct ctype_base ++ { ++ // Note: In uClibc, the following two types depend on configuration. ++ ++ // Non-standard typedefs. ++ typedef const __ctype_touplow_t* __to_type; ++ ++ // NB: Offsets into ctype::_M_table force a particular size ++ // on the mask type. Because of this, we don't use an enum. ++ typedef __ctype_mask_t mask; ++ static const mask upper = _ISupper; ++ static const mask lower = _ISlower; ++ static const mask alpha = _ISalpha; ++ static const mask digit = _ISdigit; ++ static const mask xdigit = _ISxdigit; ++ static const mask space = _ISspace; ++ static const mask print = _ISprint; ++ static const mask graph = _ISalpha | _ISdigit | _ISpunct; ++ static const mask cntrl = _IScntrl; ++ static const mask punct = _ISpunct; ++ static const mask alnum = _ISalpha | _ISdigit; ++ }; +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_inline.h gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_inline.h +--- gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_inline.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_inline.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,69 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 2000, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*) ++// functions go in ctype.cc ++ ++ bool ++ ctype:: ++ is(mask __m, char __c) const ++ { return _M_table[static_cast(__c)] & __m; } ++ ++ const char* ++ ctype:: ++ is(const char* __low, const char* __high, mask* __vec) const ++ { ++ while (__low < __high) ++ *__vec++ = _M_table[static_cast(*__low++)]; ++ return __high; ++ } ++ ++ const char* ++ ctype:: ++ scan_is(mask __m, const char* __low, const char* __high) const ++ { ++ while (__low < __high ++ && !(_M_table[static_cast(*__low)] & __m)) ++ ++__low; ++ return __low; ++ } ++ ++ const char* ++ ctype:: ++ scan_not(mask __m, const char* __low, const char* __high) const ++ { ++ while (__low < __high ++ && (_M_table[static_cast(*__low)] & __m) != 0) ++ ++__low; ++ return __low; ++ } +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_noninline.h gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_noninline.h +--- gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_noninline.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_noninline.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,92 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2004 ++// Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// Information as gleaned from /usr/include/ctype.h ++ ++ const ctype_base::mask* ++ ctype::classic_table() throw() ++ { return __C_ctype_b; } ++ ++ ctype::ctype(__c_locale, const mask* __table, bool __del, ++ size_t __refs) ++ : facet(__refs), _M_c_locale_ctype(_S_get_c_locale()), ++ _M_del(__table != 0 && __del), _M_widen_ok(0), _M_narrow_ok(0) ++ { ++ _M_toupper = __C_ctype_toupper; ++ _M_tolower = __C_ctype_tolower; ++ _M_table = __table ? __table : __C_ctype_b; ++ memset(_M_widen, 0, sizeof(_M_widen)); ++ memset(_M_narrow, 0, sizeof(_M_narrow)); ++ } ++ ++ ctype::ctype(const mask* __table, bool __del, size_t __refs) ++ : facet(__refs), _M_c_locale_ctype(_S_get_c_locale()), ++ _M_del(__table != 0 && __del), _M_widen_ok(0), _M_narrow_ok(0) ++ { ++ _M_toupper = __C_ctype_toupper; ++ _M_tolower = __C_ctype_tolower; ++ _M_table = __table ? __table : __C_ctype_b; ++ memset(_M_widen, 0, sizeof(_M_widen)); ++ memset(_M_narrow, 0, sizeof(_M_narrow)); ++ } ++ ++ char ++ ctype::do_toupper(char __c) const ++ { return _M_toupper[static_cast(__c)]; } ++ ++ const char* ++ ctype::do_toupper(char* __low, const char* __high) const ++ { ++ while (__low < __high) ++ { ++ *__low = _M_toupper[static_cast(*__low)]; ++ ++__low; ++ } ++ return __high; ++ } ++ ++ char ++ ctype::do_tolower(char __c) const ++ { return _M_tolower[static_cast(__c)]; } ++ ++ const char* ++ ctype::do_tolower(char* __low, const char* __high) const ++ { ++ while (__low < __high) ++ { ++ *__low = _M_tolower[static_cast(*__low)]; ++ ++__low; ++ } ++ return __high; ++ } +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/os_defines.h gcc-3.4.2/libstdc++-v3/config/os/uclibc/os_defines.h +--- gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/os_defines.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/os/uclibc/os_defines.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,44 @@ ++// Specific definitions for GNU/Linux -*- C++ -*- ++ ++// Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++#ifndef _GLIBCXX_OS_DEFINES ++#define _GLIBCXX_OS_DEFINES 1 ++ ++// System-specific #define, typedefs, corrections, etc, go here. This ++// file will come before all others. ++ ++// This keeps isanum, et al from being propagated as macros. ++#define __NO_CTYPE 1 ++ ++#include ++ ++// We must not see the optimized string functions GNU libc defines. ++#define __NO_STRING_INLINES ++ ++#endif +diff -urN gcc-3.4.2-dist/libstdc++-v3/configure gcc-3.4.2/libstdc++-v3/configure +--- gcc-3.4.2-dist/libstdc++-v3/configure 2004-08-13 15:44:04.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/configure 2004-09-10 10:47:40.000000000 -0500 +@@ -3878,6 +3878,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +@@ -5545,6 +5550,9 @@ + # Default to "generic". + if test $enable_clocale_flag = auto; then + case x${target_os} in ++ xlinux-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + xlinux* | xgnu* | xkfreebsd*-gnu | xknetbsd*-gnu) + cat >conftest.$ac_ext <<_ACEOF + #line $LINENO "configure" +@@ -5759,6 +5767,77 @@ + CTIME_CC=config/locale/generic/time_members.cc + CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h + ;; ++ uclibc) ++ echo "$as_me:$LINENO: result: uclibc" >&5 ++echo "${ECHO_T}uclibc" >&6 ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ # Extract the first word of "msgfmt", so it can be a program name with args. ++set dummy msgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_prog_check_msgfmt+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ if test -n "$check_msgfmt"; then ++ ac_cv_prog_check_msgfmt="$check_msgfmt" # Let the user override the test. ++else ++as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_prog_check_msgfmt="yes" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_prog_check_msgfmt" && ac_cv_prog_check_msgfmt="no" ++fi ++fi ++check_msgfmt=$ac_cv_prog_check_msgfmt ++if test -n "$check_msgfmt"; then ++ echo "$as_me:$LINENO: result: $check_msgfmt" >&5 ++echo "${ECHO_T}$check_msgfmt" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcxx_MOFILES="$glibcxx_MOFILES $ling.mo"; \ ++ glibcxx_POFILES="$glibcxx_POFILES $ling.po"; \ ++ done ++ ++ ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_H=config/locale/ieee_1003.1-2001/codecvt_specializations.h ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + esac + + # This is where the testsuite looks for locale catalogs, using the +diff -urN gcc-3.4.2-dist/libstdc++-v3/configure.host gcc-3.4.2/libstdc++-v3/configure.host +--- gcc-3.4.2-dist/libstdc++-v3/configure.host 2004-08-27 14:52:30.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/configure.host 2004-09-10 10:47:40.000000000 -0500 +@@ -217,6 +217,12 @@ + ;; + esac + ++# Override for uClibc since linux-uclibc gets mishandled above. ++case "${host_os}" in ++ *-uclibc*) ++ os_include_dir="os/uclibc" ++ ;; ++esac + + # Set any OS-dependent and CPU-dependent bits. + # THIS TABLE IS SORTED. KEEP IT THAT WAY. +diff -urN gcc-3.4.2-dist/libstdc++-v3/crossconfig.m4 gcc-3.4.2/libstdc++-v3/crossconfig.m4 +--- gcc-3.4.2-dist/libstdc++-v3/crossconfig.m4 2004-07-06 20:23:49.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/crossconfig.m4 2004-09-10 10:47:40.000000000 -0500 +@@ -138,6 +138,99 @@ + ;; + esac + ;; ++ *-uclibc*) ++# Temporary hack until we implement the float versions of the libm funcs ++ AC_CHECK_HEADERS([nan.h ieeefp.h endian.h sys/isa_defs.h \ ++ machine/endian.h machine/param.h sys/machine.h sys/types.h \ ++ fp.h float.h endian.h inttypes.h locale.h float.h stdint.h]) ++ SECTION_FLAGS='-ffunction-sections -fdata-sections' ++ AC_SUBST(SECTION_FLAGS) ++ GLIBCXX_CHECK_LINKER_FEATURES ++ GLIBCXX_CHECK_COMPLEX_MATH_SUPPORT ++ GLIBCXX_CHECK_WCHAR_T_SUPPORT ++ ++ # For LFS. ++ AC_DEFINE(HAVE_INT64_T) ++ case "$target" in ++ *-uclinux*) ++ # Don't enable LFS with uClinux ++ ;; ++ *) ++ AC_DEFINE(_GLIBCXX_USE_LFS) ++ esac ++ ++ # For showmanyc_helper(). ++ AC_CHECK_HEADERS(sys/ioctl.h sys/filio.h) ++ GLIBCXX_CHECK_POLL ++ GLIBCXX_CHECK_S_ISREG_OR_S_IFREG ++ ++ # For xsputn_2(). ++ AC_CHECK_HEADERS(sys/uio.h) ++ GLIBCXX_CHECK_WRITEV ++ ++# AC_DEFINE(HAVE_ACOSF) ++# AC_DEFINE(HAVE_ASINF) ++# AC_DEFINE(HAVE_ATANF) ++# AC_DEFINE(HAVE_ATAN2F) ++ AC_DEFINE(HAVE_CEILF) ++ AC_DEFINE(HAVE_COPYSIGN) ++# AC_DEFINE(HAVE_COPYSIGNF) ++# AC_DEFINE(HAVE_COSF) ++# AC_DEFINE(HAVE_COSHF) ++# AC_DEFINE(HAVE_EXPF) ++# AC_DEFINE(HAVE_FABSF) ++ AC_DEFINE(HAVE_FINITE) ++ AC_DEFINE(HAVE_FINITEF) ++ AC_DEFINE(HAVE_FLOORF) ++# AC_DEFINE(HAVE_FMODF) ++# AC_DEFINE(HAVE_FREXPF) ++ AC_DEFINE(HAVE_HYPOT) ++# AC_DEFINE(HAVE_HYPOTF) ++ AC_DEFINE(HAVE_ISINF) ++ AC_DEFINE(HAVE_ISINFF) ++ AC_DEFINE(HAVE_ISNAN) ++ AC_DEFINE(HAVE_ISNANF) ++# AC_DEFINE(HAVE_LOGF) ++# AC_DEFINE(HAVE_LOG10F) ++# AC_DEFINE(HAVE_MODFF) ++# AC_DEFINE(HAVE_SINF) ++# AC_DEFINE(HAVE_SINHF) ++# AC_DEFINE(HAVE_SINCOS) ++# AC_DEFINE(HAVE_SINCOSF) ++ AC_DEFINE(HAVE_SQRTF) ++# AC_DEFINE(HAVE_TANF) ++# AC_DEFINE(HAVE_TANHF) ++ if test x"long_double_math_on_this_cpu" = x"yes"; then ++ AC_MSG_ERROR([long_double_math_on_this_cpu is yes!]) ++# AC_DEFINE(HAVE_ACOSL) ++# AC_DEFINE(HAVE_ASINL) ++# AC_DEFINE(HAVE_ATANL) ++# AC_DEFINE(HAVE_ATAN2L) ++# AC_DEFINE(HAVE_CEILL) ++# AC_DEFINE(HAVE_COPYSIGNL) ++# AC_DEFINE(HAVE_COSL) ++# AC_DEFINE(HAVE_COSHL) ++# AC_DEFINE(HAVE_EXPL) ++# AC_DEFINE(HAVE_FABSL) ++# AC_DEFINE(HAVE_FINITEL) ++# AC_DEFINE(HAVE_FLOORL) ++# AC_DEFINE(HAVE_FMODL) ++# AC_DEFINE(HAVE_FREXPL) ++# AC_DEFINE(HAVE_HYPOTL) ++# AC_DEFINE(HAVE_ISINFL) ++# AC_DEFINE(HAVE_ISNANL) ++# AC_DEFINE(HAVE_LOGL) ++# AC_DEFINE(HAVE_LOG10L) ++# AC_DEFINE(HAVE_MODFL) ++# AC_DEFINE(HAVE_POWL) ++# AC_DEFINE(HAVE_SINL) ++# AC_DEFINE(HAVE_SINHL) ++# AC_DEFINE(HAVE_SINCOSL) ++# AC_DEFINE(HAVE_SQRTL) ++# AC_DEFINE(HAVE_TANL) ++# AC_DEFINE(HAVE_TANHL) ++ fi ++ ;; + *-linux* | *-uclinux* | *-gnu* | *-kfreebsd*-gnu | *-knetbsd*-gnu) + AC_CHECK_HEADERS([nan.h ieeefp.h endian.h sys/isa_defs.h \ + machine/endian.h machine/param.h sys/machine.h sys/types.h \ +@@ -152,7 +245,7 @@ + AC_DEFINE(HAVE_INT64_T) + case "$target" in + *-uclinux*) +- # Don't enable LFS with uClibc ++ # Don't enable LFS with uClinux + ;; + *) + AC_DEFINE(_GLIBCXX_USE_LFS) +diff -urN gcc-3.4.2-dist/libstdc++-v3/include/c_compatibility/wchar.h gcc-3.4.2/libstdc++-v3/include/c_compatibility/wchar.h +--- gcc-3.4.2-dist/libstdc++-v3/include/c_compatibility/wchar.h 2003-12-08 21:51:45.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/include/c_compatibility/wchar.h 2004-09-10 10:47:40.000000000 -0500 +@@ -101,7 +101,9 @@ + using std::wmemcpy; + using std::wmemmove; + using std::wmemset; ++#if _GLIBCXX_HAVE_WCSFTIME + using std::wcsftime; ++#endif + + #if _GLIBCXX_USE_C99 + using std::wcstold; +diff -urN gcc-3.4.2-dist/libstdc++-v3/include/c_std/std_cwchar.h gcc-3.4.2/libstdc++-v3/include/c_std/std_cwchar.h +--- gcc-3.4.2-dist/libstdc++-v3/include/c_std/std_cwchar.h 2004-07-20 03:52:12.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/include/c_std/std_cwchar.h 2004-09-10 10:47:40.000000000 -0500 +@@ -179,7 +179,9 @@ + using ::wcscoll; + using ::wcscpy; + using ::wcscspn; ++#if _GLIBCXX_HAVE_WCSFTIME + using ::wcsftime; ++#endif + using ::wcslen; + using ::wcsncat; + using ::wcsncmp; diff --git a/meta/packages/gcc/gcc-3.4.3/gcc-uclibc-3.4.0-120-softfloat.patch b/meta/packages/gcc/gcc-3.4.3/gcc-uclibc-3.4.0-120-softfloat.patch new file mode 100644 index 000000000..f2431896c --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc-uclibc-3.4.0-120-softfloat.patch @@ -0,0 +1,14 @@ +--- gcc-3.3.2-old/configure.in 2003-08-09 01:57:21.000000000 -0500 ++++ gcc-3.3.2/configure.in 2004-01-15 12:46:29.000000000 -0600 +@@ -1418,6 +1418,11 @@ + fi + + FLAGS_FOR_TARGET= ++case " $targargs " in ++ *" --nfp "* | *" --without-float "*) ++ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -msoft-float' ++ ;; ++esac + case " $target_configdirs " in + *" newlib "*) + case " $targargs " in diff --git a/meta/packages/gcc/gcc-3.4.3/gcc34-arm-ldm-peephole.patch b/meta/packages/gcc/gcc-3.4.3/gcc34-arm-ldm-peephole.patch new file mode 100644 index 000000000..fb317e153 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc34-arm-ldm-peephole.patch @@ -0,0 +1,79 @@ +--- gcc-3.4.0/gcc/config/arm/arm.md.arm-ldm-peephole 2004-01-13 08:24:37.000000000 -0500 ++++ gcc-3.4.0/gcc/config/arm/arm.md 2004-04-24 18:18:04.000000000 -0400 +@@ -8810,13 +8810,16 @@ + (set_attr "length" "4,8,8")] + ) + ++; Try to convert LDR+LDR+arith into [add+]LDM+arith ++; On XScale, LDM is always slower than two LDRs, so only do this if ++; optimising for size. + (define_insn "*arith_adjacentmem" + [(set (match_operand:SI 0 "s_register_operand" "=r") + (match_operator:SI 1 "shiftable_operator" + [(match_operand:SI 2 "memory_operand" "m") + (match_operand:SI 3 "memory_operand" "m")])) + (clobber (match_scratch:SI 4 "=r"))] +- "TARGET_ARM && adjacent_mem_locations (operands[2], operands[3])" ++ "TARGET_ARM && (!arm_tune_xscale || optimize_size) && adjacent_mem_locations (operands[2], operands[3])" + "* + { + rtx ldm[3]; +@@ -8851,6 +8854,8 @@ + } + if (val1 && val2) + { ++ /* This would be a loss on a Harvard core, but adjacent_mem_locations() ++ will prevent it from happening. */ + rtx ops[3]; + ldm[0] = ops[0] = operands[4]; + ops[1] = XEXP (XEXP (operands[2], 0), 0); +--- gcc-3.4.0/gcc/config/arm/arm.c.arm-ldm-peephole 2004-04-24 18:16:25.000000000 -0400 ++++ gcc-3.4.0/gcc/config/arm/arm.c 2004-04-24 18:18:04.000000000 -0400 +@@ -4593,8 +4593,11 @@ + arith_adjacentmem pattern to output an overlong sequence. */ + if (!const_ok_for_op (PLUS, val0) || !const_ok_for_op (PLUS, val1)) + return 0; +- +- return (reg0 == reg1) && ((val1 - val0) == 4 || (val0 - val1) == 4); ++ ++ /* For Harvard cores, only accept pairs where one offset is zero. ++ See comment in load_multiple_sequence. */ ++ return (reg0 == reg1) && ((val1 - val0) == 4 || (val0 - val1) == 4) ++ && (!arm_ld_sched || val0 == 0 || val1 == 0); + } + return 0; + } +@@ -4838,6 +4841,11 @@ + *load_offset = unsorted_offsets[order[0]]; + } + ++ /* For XScale a two-word LDM is a performance loss, so only do this if ++ size is more important. See comments in arm_gen_load_multiple. */ ++ if (nops == 2 && arm_tune_xscale && !optimize_size) ++ return 0; ++ + if (unsorted_offsets[order[0]] == 0) + return 1; /* ldmia */ + +@@ -5064,6 +5072,11 @@ + *load_offset = unsorted_offsets[order[0]]; + } + ++ /* For XScale a two-word LDM is a performance loss, so only do this if ++ size is more important. See comments in arm_gen_load_multiple. */ ++ if (nops == 2 && arm_tune_xscale && !optimize_size) ++ return 0; ++ + if (unsorted_offsets[order[0]] == 0) + return 1; /* stmia */ + +--- gcc-3.4.0/gcc/genpeep.c.arm-ldm-peephole 2003-07-05 01:27:22.000000000 -0400 ++++ gcc-3.4.0/gcc/genpeep.c 2004-04-24 18:18:04.000000000 -0400 +@@ -381,6 +381,7 @@ + printf ("#include \"recog.h\"\n"); + printf ("#include \"except.h\"\n\n"); + printf ("#include \"function.h\"\n\n"); ++ printf ("#include \"flags.h\"\n\n"); + + printf ("#ifdef HAVE_peephole\n"); + printf ("extern rtx peep_operand[];\n\n"); diff --git a/meta/packages/gcc/gcc-3.4.3/gcc34-arm-ldm.patch b/meta/packages/gcc/gcc-3.4.3/gcc34-arm-ldm.patch new file mode 100644 index 000000000..142052fdf --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc34-arm-ldm.patch @@ -0,0 +1,119 @@ +--- gcc-3.4.0/gcc/config/arm/arm.c.arm-ldm 2004-02-27 09:51:05.000000000 -0500 ++++ gcc-3.4.0/gcc/config/arm/arm.c 2004-04-24 18:16:25.000000000 -0400 +@@ -8520,6 +8520,26 @@ + return_used_this_function = 0; + } + ++/* Return the number (counting from 0) of ++ the least significant set bit in MASK. */ ++ ++#ifdef __GNUC__ ++inline ++#endif ++static int ++number_of_first_bit_set (mask) ++ int mask; ++{ ++ int bit; ++ ++ for (bit = 0; ++ (mask & (1 << bit)) == 0; ++ ++bit) ++ continue; ++ ++ return bit; ++} ++ + const char * + arm_output_epilogue (rtx sibling) + { +@@ -8753,27 +8773,47 @@ + saved_regs_mask |= (1 << PC_REGNUM); + } + +- /* Load the registers off the stack. If we only have one register +- to load use the LDR instruction - it is faster. */ +- if (saved_regs_mask == (1 << LR_REGNUM)) +- { +- /* The exception handler ignores the LR, so we do +- not really need to load it off the stack. */ +- if (eh_ofs) +- asm_fprintf (f, "\tadd\t%r, %r, #4\n", SP_REGNUM, SP_REGNUM); +- else +- asm_fprintf (f, "\tldr\t%r, [%r], #4\n", LR_REGNUM, SP_REGNUM); +- } +- else if (saved_regs_mask) ++ if (saved_regs_mask) + { +- if (saved_regs_mask & (1 << SP_REGNUM)) +- /* Note - write back to the stack register is not enabled +- (ie "ldmfd sp!..."). We know that the stack pointer is +- in the list of registers and if we add writeback the +- instruction becomes UNPREDICTABLE. */ +- print_multi_reg (f, "ldmfd\t%r", SP_REGNUM, saved_regs_mask); ++ /* Load the registers off the stack. If we only have one register ++ to load use the LDR instruction - it is faster. */ ++ if (bit_count (saved_regs_mask) == 1) ++ { ++ int reg = number_of_first_bit_set (saved_regs_mask); ++ ++ switch (reg) ++ { ++ case SP_REGNUM: ++ /* Mustn't use base writeback when loading SP. */ ++ asm_fprintf (f, "\tldr\t%r, [%r]\n", SP_REGNUM, SP_REGNUM); ++ break; ++ ++ case LR_REGNUM: ++ if (eh_ofs) ++ { ++ /* The exception handler ignores the LR, so we do ++ not really need to load it off the stack. */ ++ asm_fprintf (f, "\tadd\t%r, %r, #4\n", SP_REGNUM, SP_REGNUM); ++ break; ++ } ++ /* else fall through */ ++ ++ default: ++ asm_fprintf (f, "\tldr\t%r, [%r], #4\n", reg, SP_REGNUM); ++ break; ++ } ++ } + else +- print_multi_reg (f, "ldmfd\t%r!", SP_REGNUM, saved_regs_mask); ++ { ++ if (saved_regs_mask & (1 << SP_REGNUM)) ++ /* Note - write back to the stack register is not enabled ++ (ie "ldmfd sp!..."). We know that the stack pointer is ++ in the list of registers and if we add writeback the ++ instruction becomes UNPREDICTABLE. */ ++ print_multi_reg (f, "ldmfd\t%r", SP_REGNUM, saved_regs_mask); ++ else ++ print_multi_reg (f, "ldmfd\t%r!", SP_REGNUM, saved_regs_mask); ++ } + } + + if (current_function_pretend_args_size) +@@ -11401,22 +11441,6 @@ + } + } + +-/* Return the number (counting from 0) of +- the least significant set bit in MASK. */ +- +-inline static int +-number_of_first_bit_set (int mask) +-{ +- int bit; +- +- for (bit = 0; +- (mask & (1 << bit)) == 0; +- ++bit) +- continue; +- +- return bit; +-} +- + /* Generate code to return from a thumb function. + If 'reg_containing_return_addr' is -1, then the return address is + actually on the stack, at the stack pointer. */ diff --git a/meta/packages/gcc/gcc-3.4.3/gcc34-arm-tune.patch b/meta/packages/gcc/gcc-3.4.3/gcc34-arm-tune.patch new file mode 100644 index 000000000..cdb20bef9 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc34-arm-tune.patch @@ -0,0 +1,9 @@ +--- gcc-3.4.0/gcc/config/arm/linux-elf.h.arm-tune 2004-01-31 01:18:11.000000000 -0500 ++++ gcc-3.4.0/gcc/config/arm/linux-elf.h 2004-04-24 18:19:10.000000000 -0400 +@@ -126,3 +126,6 @@ + + #define LINK_GCC_C_SEQUENCE_SPEC \ + "%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}" ++ ++/* Tune for XScale. */ ++#define TARGET_TUNE_DEFAULT TARGET_CPU_xscale diff --git a/meta/packages/gcc/gcc-3.4.3/gcc34-reverse-compare.patch b/meta/packages/gcc/gcc-3.4.3/gcc34-reverse-compare.patch new file mode 100644 index 000000000..c3c40dd18 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/gcc34-reverse-compare.patch @@ -0,0 +1,32 @@ +--- gcc-3.4.0/gcc/flow.c.reverse-compare 2004-02-27 22:39:19.000000000 -0500 ++++ gcc-3.4.0/gcc/flow.c 2004-04-24 16:36:00.000000000 -0400 +@@ -1843,6 +1843,7 @@ + regset_head diff_head; + regset diff = INITIALIZE_REG_SET (diff_head); + basic_block bb_true, bb_false; ++ enum rtx_code reversed_code; + int i; + + /* Identify the successor blocks. */ +@@ -1889,8 +1890,11 @@ + if (GET_CODE (reg) == REG + && XEXP (cond_true, 1) == const0_rtx) + { +- rtx cond_false +- = gen_rtx_fmt_ee (reverse_condition (GET_CODE (cond_true)), ++ rtx cond_false; ++ reversed_code = reverse_condition (GET_CODE (cond_true)); ++ if (reversed_code == UNKNOWN) ++ goto skip; ++ cond_false = gen_rtx_fmt_ee (reversed_code, + GET_MODE (cond_true), XEXP (cond_true, 0), + XEXP (cond_true, 1)); + if (GET_CODE (XEXP (set_src, 1)) == PC) +@@ -1925,6 +1929,7 @@ + } + } + ++ skip: + FREE_REG_SET (diff); + } + #endif diff --git a/meta/packages/gcc/gcc-3.4.3/sdk-libstdc++-includes.patch b/meta/packages/gcc/gcc-3.4.3/sdk-libstdc++-includes.patch new file mode 100644 index 000000000..4377c2143 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.3/sdk-libstdc++-includes.patch @@ -0,0 +1,22 @@ +--- gcc-3.4.1/libstdc++-v3/libmath/Makefile.am~ 2003-08-27 22:29:42.000000000 +0100 ++++ gcc-3.4.1/libstdc++-v3/libmath/Makefile.am 2004-07-22 16:41:45.152130128 +0100 +@@ -32,7 +32,7 @@ + + libmath_la_SOURCES = stubs.c + +-AM_CPPFLAGS = $(CANADIAN_INCLUDES) ++AM_CPPFLAGS = $(CANADIAN_INCLUDES) -I$(toplevel_srcdir)/include + + # Only compiling "C" sources in this directory. + LIBTOOL = @LIBTOOL@ --tag CC +--- gcc-3.4.1/libstdc++-v3/fragment.am.old 2004-07-22 18:24:58.024083656 +0100 ++++ gcc-3.4.1/libstdc++-v3/fragment.am 2004-07-22 18:24:59.019932264 +0100 +@@ -18,7 +18,7 @@ + $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once + + # -I/-D flags to pass when compiling. +-AM_CPPFLAGS = $(GLIBCXX_INCLUDES) ++AM_CPPFLAGS = $(GLIBCXX_INCLUDES) -I$(toplevel_srcdir)/include + + + diff --git a/meta/packages/gcc/gcc-3.4.4/15342.patch b/meta/packages/gcc/gcc-3.4.4/15342.patch new file mode 100644 index 000000000..d0f3e72d4 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/15342.patch @@ -0,0 +1,22 @@ +--- gcc/gcc/regrename.c~ 2004-01-14 17:55:20.000000000 +0000 ++++ gcc/gcc/regrename.c 2005-02-28 07:24:25.893015200 +0000 +@@ -671,7 +671,8 @@ + + case SET: + scan_rtx (insn, &SET_SRC (x), class, action, OP_IN, 0); +- scan_rtx (insn, &SET_DEST (x), class, action, OP_OUT, 0); ++ scan_rtx (insn, &SET_DEST (x), class, action, ++ GET_CODE (PATTERN (insn)) == COND_EXEC ? OP_INOUT : OP_OUT, 0); + return; + + case STRICT_LOW_PART: +@@ -696,7 +697,8 @@ + abort (); + + case CLOBBER: +- scan_rtx (insn, &SET_DEST (x), class, action, OP_OUT, 1); ++ scan_rtx (insn, &SET_DEST (x), class, action, ++ GET_CODE (PATTERN (insn)) == COND_EXEC ? OP_INOUT : OP_OUT, 0); + return; + + case EXPR_LIST: diff --git a/meta/packages/gcc/gcc-3.4.4/GCC3.4.0VisibilityPatch.diff b/meta/packages/gcc/gcc-3.4.4/GCC3.4.0VisibilityPatch.diff new file mode 100644 index 000000000..d51da7157 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/GCC3.4.0VisibilityPatch.diff @@ -0,0 +1,1100 @@ + +diff -aur gcc-3.4.0orig/gcc/c-common.c gcc-3.4.0/gcc/c-common.c +--- gcc-3.4.0orig/gcc/c-common.c 2004-03-19 01:32:59.000000000 +0000 ++++ gcc-3.4.0/gcc/c-common.c 2004-05-10 21:05:33.000000000 +0100 +@@ -833,7 +833,7 @@ + handle_deprecated_attribute }, + { "vector_size", 1, 1, false, true, false, + handle_vector_size_attribute }, +- { "visibility", 1, 1, true, false, false, ++ { "visibility", 1, 1, false, false, false, + handle_visibility_attribute }, + { "tls_model", 1, 1, true, false, false, + handle_tls_model_attribute }, +@@ -4886,7 +4886,16 @@ + + *no_add_attrs = true; + +- if (decl_function_context (decl) != 0 || ! TREE_PUBLIC (decl)) ++ if (TYPE_P (*node)) ++ { ++ if (TREE_CODE (*node) != RECORD_TYPE && TREE_CODE (*node) != UNION_TYPE) ++ { ++ warning ("`%s' attribute ignored on non-class types", ++ IDENTIFIER_POINTER (name)); ++ return NULL_TREE; ++ } ++ } ++ else if (decl_function_context (decl) != 0 || ! TREE_PUBLIC (decl)) + { + warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name)); + return NULL_TREE; +@@ -4897,6 +4906,14 @@ + error ("visibility arg not a string"); + return NULL_TREE; + } ++ ++ /* If this is a type, set the visibility on the type decl. */ ++ if (TYPE_P (decl)) ++ { ++ decl = TYPE_NAME (decl); ++ if (! decl) ++ return NULL_TREE; ++ } + + if (strcmp (TREE_STRING_POINTER (id), "default") == 0) + DECL_VISIBILITY (decl) = VISIBILITY_DEFAULT; +@@ -4908,6 +4925,14 @@ + DECL_VISIBILITY (decl) = VISIBILITY_PROTECTED; + else + error ("visibility arg must be one of \"default\", \"hidden\", \"protected\" or \"internal\""); ++ DECL_VISIBILITYSPECIFIED (decl) = 1; ++ ++ /* For decls only, go ahead and attach the attribute to the node as well. ++ This is needed so we can determine whether we have VISIBILITY_DEFAULT ++ because the visibility was not specified, or because it was explicitly ++ overridden from the class visibility. */ ++ if (DECL_P (*node)) ++ *no_add_attrs = false; + + return NULL_TREE; + } + +diff -aur gcc-3.4.0orig/gcc/c-decl.c gcc-3.4.0/gcc/c-decl.c +--- gcc-3.4.0orig/gcc/c-decl.c 2004-03-22 17:58:18.000000000 +0000 ++++ gcc-3.4.0/gcc/c-decl.c 2004-05-10 15:16:27.000000000 +0100 +@@ -1164,9 +1164,8 @@ + } + + /* warnings */ +- /* All decls must agree on a non-default visibility. */ +- if (DECL_VISIBILITY (newdecl) != VISIBILITY_DEFAULT +- && DECL_VISIBILITY (olddecl) != VISIBILITY_DEFAULT ++ /* All decls must agree on a visibility. */ ++ if (DECL_VISIBILITYSPECIFIED (newdecl) && DECL_VISIBILITYSPECIFIED (olddecl) + && DECL_VISIBILITY (newdecl) != DECL_VISIBILITY (olddecl)) + { + warning ("%Jredeclaration of '%D' with different visibility " +@@ -1361,9 +1360,12 @@ + Currently, it can only be defined in the prototype. */ + COPY_DECL_ASSEMBLER_NAME (olddecl, newdecl); + +- /* If either declaration has a nondefault visibility, use it. */ +- if (DECL_VISIBILITY (olddecl) != VISIBILITY_DEFAULT) +- DECL_VISIBILITY (newdecl) = DECL_VISIBILITY (olddecl); ++ /* Use visibility of whichever declaration had it specified */ ++ if (DECL_VISIBILITYSPECIFIED (olddecl)) ++ { ++ DECL_VISIBILITY (newdecl) = DECL_VISIBILITY (olddecl); ++ DECL_VISIBILITYSPECIFIED (newdecl) = 1; ++ } + + if (TREE_CODE (newdecl) == FUNCTION_DECL) + { + +diff -aur gcc-3.4.0orig/gcc/common.opt gcc-3.4.0/gcc/common.opt +--- gcc-3.4.0orig/gcc/common.opt 2004-02-18 00:09:04.000000000 +0000 ++++ gcc-3.4.0/gcc/common.opt 2004-05-09 08:10:50.000000000 +0100 +@@ -718,6 +718,11 @@ + Common + Add extra commentary to assembler output + ++fvisibility= ++Common Joined RejectNegative ++-fvisibility=[default|internal|hidden|protected] Set the default symbol visibility ++ ++ + fvpt + Common + Use expression value profiles in optimizations + +diff -aur gcc-3.4.0orig/gcc/c.opt gcc-3.4.0/gcc/c.opt +--- gcc-3.4.0orig/gcc/c.opt 2004-02-18 00:09:03.000000000 +0000 ++++ gcc-3.4.0/gcc/c.opt 2004-05-09 08:10:50.000000000 +0100 +@@ -656,6 +656,10 @@ + C++ ObjC++ + Use __cxa_atexit to register destructors + ++fvisibility-inlines-hidden ++C++ ++Marks all inlined methods as having hidden visibility ++ + fvtable-gc + C++ ObjC++ + Discard unused virtual functions +diff -aur gcc-3.4.0orig/gcc/c-opts.c gcc-3.4.0/gcc/c-opts.c +--- gcc-3.4.0orig/gcc/c-opts.c 2004-02-18 00:09:03.000000000 +0000 ++++ gcc-3.4.0/gcc/c-opts.c 2004-05-09 08:10:50.000000000 +0100 +@@ -912,6 +912,10 @@ + case OPT_fuse_cxa_atexit: + flag_use_cxa_atexit = value; + break; ++ ++ case OPT_fvisibility_inlines_hidden: ++ visibility_options.inlineshidden = value; ++ break; + + case OPT_fweak: + flag_weak = value; + +diff -aur gcc-3.4.0orig/gcc/cp/class.c gcc-3.4.0/gcc/cp/class.c +--- gcc-3.4.0orig/gcc/cp/class.c 2004-03-09 07:27:23.000000000 +0000 ++++ gcc-3.4.0/gcc/cp/class.c 2004-05-10 21:06:50.000000000 +0100 +@@ -524,6 +524,10 @@ + DECL_ALIGN (decl) = MAX (TYPE_ALIGN (double_type_node), + DECL_ALIGN (decl)); + ++ /* The vtable's visibility is the class visibility. There is no way ++ to override the visibility for just the vtable. */ ++ DECL_VISIBILITY (decl) = CLASSTYPE_VISIBILITY (class_type); ++ DECL_VISIBILITYSPECIFIED (decl) = CLASSTYPE_VISIBILITYSPECIFIED (class_type); + import_export_vtable (decl, class_type, 0); + + return decl; +@@ -2971,7 +2975,25 @@ + continue; + + if (TREE_CODE (x) == CONST_DECL || TREE_CODE (x) == VAR_DECL) +- continue; ++ { ++ /* Apply the class's visibility attribute to static members ++ which do not have a visibility attribute. */ ++ if (! lookup_attribute ("visibility", DECL_ATTRIBUTES (x))) ++ { ++ if (visibility_options.inlineshidden && DECL_INLINE (x)) ++ { ++ DECL_VISIBILITY (x) = VISIBILITY_HIDDEN; ++ DECL_VISIBILITYSPECIFIED (x) = 1; ++ } ++ else ++ { ++ DECL_VISIBILITY (x) = CLASSTYPE_VISIBILITY (current_class_type); ++ DECL_VISIBILITYSPECIFIED (x) = CLASSTYPE_VISIBILITYSPECIFIED (current_class_type); ++ } ++ } ++ ++ continue; ++ } + + /* Now it can only be a FIELD_DECL. */ + +@@ -3708,6 +3730,22 @@ + check_for_override (x, t); + if (DECL_PURE_VIRTUAL_P (x) && ! DECL_VINDEX (x)) + cp_error_at ("initializer specified for non-virtual method `%D'", x); ++ ++ /* Apply the class's visibility attribute to methods which do ++ not have a visibility attribute. */ ++ if (! lookup_attribute ("visibility", DECL_ATTRIBUTES (x))) ++ { ++ if (visibility_options.inlineshidden && DECL_INLINE (x)) ++ { ++ DECL_VISIBILITY (x) = VISIBILITY_HIDDEN; ++ DECL_VISIBILITYSPECIFIED (x) = 1; ++ } ++ else ++ { ++ DECL_VISIBILITY (x) = CLASSTYPE_VISIBILITY (current_class_type); ++ DECL_VISIBILITYSPECIFIED (x) = CLASSTYPE_VISIBILITYSPECIFIED (current_class_type); ++ } ++ } + + /* The name of the field is the original field name + Save this in auxiliary field for later overloading. */ +@@ -7830,3 +7868,4 @@ + *vid->last_init = build_tree_list (NULL_TREE, init); + vid->last_init = &TREE_CHAIN (*vid->last_init); + } ++ + +diff -aur gcc-3.4.0orig/gcc/cp/cp-tree.h gcc-3.4.0/gcc/cp/cp-tree.h +--- gcc-3.4.0orig/gcc/cp/cp-tree.h 2004-03-20 00:13:08.000000000 +0000 ++++ gcc-3.4.0/gcc/cp/cp-tree.h 2004-05-10 20:56:56.000000000 +0100 +@@ -1008,7 +1008,12 @@ + #define PUBLICLY_UNIQUELY_DERIVED_P(PARENT, TYPE) \ + (lookup_base ((TYPE), (PARENT), ba_not_special | ba_quiet, NULL) \ + != NULL_TREE) +- ++ ++/* Gives the visibility specification for a class type. */ ++#define CLASSTYPE_VISIBILITY(TYPE) DECL_VISIBILITY (TYPE_NAME (TYPE)) ++#define CLASSTYPE_VISIBILITYSPECIFIED(TYPE) DECL_VISIBILITYSPECIFIED (TYPE_NAME (TYPE)) ++ ++ + /* This is a few header flags for 'struct lang_type'. Actually, + all but the first are used only for lang_type_class; they + are put in this structure to save space. */ + +diff -aur gcc-3.4.0orig/gcc/cp/decl.c gcc-3.4.0/gcc/cp/decl.c +--- gcc-3.4.0orig/gcc/cp/decl.c 2004-04-01 21:47:21.000000000 +0100 ++++ gcc-3.4.0/gcc/cp/decl.c 2004-05-28 21:16:11.000000000 +0100 +@@ -1869,17 +1869,34 @@ + DECL_COMMON (newdecl) = DECL_COMMON (olddecl); + COPY_DECL_ASSEMBLER_NAME (olddecl, newdecl); + +- /* If either declaration has a nondefault visibility, use it. */ +- if (DECL_VISIBILITY (olddecl) != VISIBILITY_DEFAULT) ++ /* Warn about conflicting visibility specifications. */ ++ if (DECL_VISIBILITYSPECIFIED (olddecl) && DECL_VISIBILITYSPECIFIED (newdecl) ++ && DECL_VISIBILITY (newdecl) != DECL_VISIBILITY (olddecl)) ++ { ++ warning ("%J'%D': visibility attribute ignored because it", ++ newdecl, newdecl); ++ warning ("%Jconflicts with previous declaration here", olddecl); ++ } ++ /* Choose the declaration which specified visibility. */ ++ if (DECL_VISIBILITYSPECIFIED (olddecl)) + { +- if (DECL_VISIBILITY (newdecl) != VISIBILITY_DEFAULT +- && DECL_VISIBILITY (newdecl) != DECL_VISIBILITY (olddecl)) +- { +- warning ("%J'%D': visibility attribute ignored because it", +- newdecl, newdecl); +- warning ("%Jconflicts with previous declaration here", olddecl); +- } + DECL_VISIBILITY (newdecl) = DECL_VISIBILITY (olddecl); ++ DECL_VISIBILITYSPECIFIED (newdecl) = 1; ++ } ++ /* If it's a definition of a global operator new or operator ++ delete, it must be default visibility. */ ++ if (NEW_DELETE_OPNAME_P (DECL_NAME (newdecl)) && DECL_INITIAL (newdecl) != NULL_TREE) ++ { ++ if (!DECL_FUNCTION_MEMBER_P (newdecl) && VISIBILITY_DEFAULT != DECL_VISIBILITY (newdecl)) ++ { ++ warning ("%J`%D': ignoring non-default symbol", ++ newdecl, newdecl); ++ warning ("%Jvisibility on global operator new or delete", newdecl); ++ DECL_VISIBILITY (olddecl) = VISIBILITY_DEFAULT; ++ DECL_VISIBILITYSPECIFIED (olddecl) = 1; ++ DECL_VISIBILITY (newdecl) = VISIBILITY_DEFAULT; ++ DECL_VISIBILITYSPECIFIED (newdecl) = 1; ++ } + } + + if (TREE_CODE (newdecl) == FUNCTION_DECL) + +diff -aur gcc-3.4.0orig/gcc/cp/method.c gcc-3.4.0/gcc/cp/method.c +--- gcc-3.4.0orig/gcc/cp/method.c 2004-04-08 23:15:58.000000000 +0100 ++++ gcc-3.4.0/gcc/cp/method.c 2004-05-09 08:10:52.000000000 +0100 +@@ -394,6 +394,7 @@ + rewrite. */ + TREE_PUBLIC (thunk_fndecl) = TREE_PUBLIC (function); + DECL_VISIBILITY (thunk_fndecl) = DECL_VISIBILITY (function); ++ DECL_VISIBILITYSPECIFIED (thunk_fndecl) = DECL_VISIBILITYSPECIFIED (function); + + if (flag_syntax_only) + { + +diff -aur gcc-3.4.0orig/gcc/cp/optimize.c gcc-3.4.0/gcc/cp/optimize.c +--- gcc-3.4.0orig/gcc/cp/optimize.c 2004-02-08 01:52:50.000000000 +0000 ++++ gcc-3.4.0/gcc/cp/optimize.c 2004-05-09 08:10:52.000000000 +0100 +@@ -155,6 +155,7 @@ + DECL_NOT_REALLY_EXTERN (clone) = DECL_NOT_REALLY_EXTERN (fn); + TREE_PUBLIC (clone) = TREE_PUBLIC (fn); + DECL_VISIBILITY (clone) = DECL_VISIBILITY (fn); ++ DECL_VISIBILITYSPECIFIED (clone) = DECL_VISIBILITYSPECIFIED (fn); + + /* Adjust the parameter names and locations. */ + parm = DECL_ARGUMENTS (fn); + +diff -aur gcc-3.4.0orig/gcc/cp/rtti.c gcc-3.4.0/gcc/cp/rtti.c +--- gcc-3.4.0orig/gcc/cp/rtti.c 2004-03-08 23:00:26.000000000 +0000 ++++ gcc-3.4.0/gcc/cp/rtti.c 2004-05-10 21:09:21.000000000 +0100 +@@ -361,7 +361,11 @@ + pushdecl_top_level_and_finish (d, NULL_TREE); + + if (CLASS_TYPE_P (type)) +- CLASSTYPE_TYPEINFO_VAR (TYPE_MAIN_VARIANT (type)) = d; ++ { ++ CLASSTYPE_TYPEINFO_VAR (TYPE_MAIN_VARIANT (type)) = d; ++ DECL_VISIBILITY (d) = CLASSTYPE_VISIBILITY (type); ++ DECL_VISIBILITYSPECIFIED (d) = CLASSTYPE_VISIBILITYSPECIFIED (type); ++ } + + /* Remember the type it is for. */ + TREE_TYPE (name) = type; +@@ -759,6 +763,11 @@ + TREE_STATIC (name_decl) = 1; + DECL_EXTERNAL (name_decl) = 0; + TREE_PUBLIC (name_decl) = 1; ++ if (CLASS_TYPE_P (target)) ++ { ++ DECL_VISIBILITY (name_decl) = CLASSTYPE_VISIBILITY (target); ++ DECL_VISIBILITYSPECIFIED (name_decl) = CLASSTYPE_VISIBILITYSPECIFIED (target); ++ } + import_export_tinfo (name_decl, target, typeinfo_in_lib_p (target)); + /* External name of the string containing the type's name has a + special name. */ + +diff -aur gcc-3.4.0orig/gcc/c-pragma.c gcc-3.4.0/gcc/c-pragma.c +--- gcc-3.4.0orig/gcc/c-pragma.c 2004-01-23 23:35:53.000000000 +0000 ++++ gcc-3.4.0/gcc/c-pragma.c 2004-05-09 08:10:52.000000000 +0100 +@@ -480,6 +480,86 @@ + return asmname; + } + ++ ++#ifdef HANDLE_PRAGMA_VISIBILITY ++static void handle_pragma_visibility (cpp_reader *); ++ ++/* Sets the default visibility for symbols to something other than that ++ specified on the command line. */ ++static void ++handle_pragma_visibility (cpp_reader *dummy ATTRIBUTE_UNUSED) ++{ /* Form is #pragma GCC visibility push(hidden)|pop */ ++ static int visstack [16], visidx; ++ tree x; ++ enum cpp_ttype token; ++ enum { bad, push, pop } action = bad; ++ ++ token = c_lex (&x); ++ if (token == CPP_NAME) ++ { ++ const char *op = IDENTIFIER_POINTER (x); ++ if (!strcmp (op, "push")) ++ action = push; ++ else if (!strcmp (op, "pop")) ++ action = pop; ++ } ++ if (bad == action) ++ GCC_BAD ("#pragma GCC visibility must be followed by push or pop"); ++ else ++ { ++ if (pop == action) ++ { ++ if (!visidx) ++ { ++ GCC_BAD ("No matching push for '#pragma GCC visibility pop'"); ++ } ++ else ++ { ++ default_visibility = visstack[--visidx]; ++ visibility_options.inpragma = (visidx>0); ++ } ++ } ++ else ++ { ++ if (c_lex (&x) != CPP_OPEN_PAREN) ++ GCC_BAD ("missing '(' after '#pragma GCC visibility push' - ignored"); ++ token = c_lex (&x); ++ if (token != CPP_NAME) ++ { ++ GCC_BAD ("malformed #pragma GCC visibility push"); ++ } ++ else if (visidx >= 16) ++ { ++ GCC_BAD ("No more than sixteen #pragma GCC visibility pushes allowed at once"); ++ } ++ else ++ { ++ const char *str = IDENTIFIER_POINTER (x); ++ visstack[visidx++] = default_visibility; ++ if (!strcmp (str, "default")) ++ default_visibility = VISIBILITY_DEFAULT; ++ else if (!strcmp (str, "internal")) ++ default_visibility = VISIBILITY_INTERNAL; ++ else if (!strcmp (str, "hidden")) ++ default_visibility = VISIBILITY_HIDDEN; ++ else if (!strcmp (str, "protected")) ++ default_visibility = VISIBILITY_PROTECTED; ++ else ++ { ++ GCC_BAD ("#pragma GCC visibility push() must specify default, internal, hidden or protected"); ++ } ++ visibility_options.inpragma = 1; ++ } ++ if (c_lex (&x) != CPP_CLOSE_PAREN) ++ GCC_BAD ("missing '(' after '#pragma GCC visibility push' - ignored"); ++ } ++ } ++ if (c_lex (&x) != CPP_EOF) ++ warning ("junk at end of '#pragma GCC visibility'"); ++} ++ ++#endif ++ + /* Front-end wrapper for pragma registration to avoid dragging + cpplib.h in almost everywhere. */ + void +@@ -505,6 +585,9 @@ + #ifdef HANDLE_PRAGMA_EXTERN_PREFIX + c_register_pragma (0, "extern_prefix", handle_pragma_extern_prefix); + #endif ++#ifdef HANDLE_PRAGMA_VISIBILITY ++ c_register_pragma ("GCC", "visibility", handle_pragma_visibility); ++#endif + + #ifdef REGISTER_TARGET_PRAGMAS + REGISTER_TARGET_PRAGMAS (); +diff -aur gcc-3.4.0orig/gcc/c-pragma.h gcc-3.4.0/gcc/c-pragma.h +--- gcc-3.4.0orig/gcc/c-pragma.h 2004-01-31 06:18:05.000000000 +0000 ++++ gcc-3.4.0/gcc/c-pragma.h 2004-05-09 08:10:53.000000000 +0100 +@@ -44,6 +44,11 @@ + #define HANDLE_PRAGMA_PACK 1 + #endif /* HANDLE_PRAGMA_PACK_PUSH_POP */ + ++/* It's safe to always leave visibility pragma enabled as if ++ visibility is not supported on the host OS platform the ++ statements are ignored. */ ++#define HANDLE_PRAGMA_VISIBILITY 1 ++ + extern void init_pragma (void); + + /* Front-end wrapper for pragma registration to avoid dragging + + +diff -aur gcc-3.4.0orig/gcc/doc/invoke.texi gcc-3.4.0/gcc/doc/invoke.texi +--- gcc-3.4.0orig/gcc/doc/invoke.texi 2004-04-19 00:05:36.000000000 +0100 ++++ gcc-3.4.0/gcc/doc/invoke.texi 2004-05-28 21:29:36.000000000 +0100 +@@ -183,7 +183,8 @@ + -fno-optional-diags -fpermissive @gol + -frepo -fno-rtti -fstats -ftemplate-depth-@var{n} @gol + -fuse-cxa-atexit -fno-weak -nostdinc++ @gol +--fno-default-inline -Wabi -Wctor-dtor-privacy @gol ++-fno-default-inline -fvisibility-inlines-hidden @gol ++-Wabi -Wctor-dtor-privacy @gol + -Wnon-virtual-dtor -Wreorder @gol + -Weffc++ -Wno-deprecated @gol + -Wno-non-template-friend -Wold-style-cast @gol +@@ -674,7 +675,8 @@ + -fargument-alias -fargument-noalias @gol + -fargument-noalias-global -fleading-underscore @gol + -ftls-model=@var{model} @gol +--ftrapv -fwrapv -fbounds-check} ++-ftrapv -fwrapv -fbounds-check @gol ++-fvisibility} + @end table + + @menu +@@ -1433,6 +1435,20 @@ + destructors, but will only work if your C library supports + @code{__cxa_atexit}. + ++@item -fvisibility-inlines-hidden ++@opindex fvisibility-inlines-hidden ++Causes all inlined methods to be marked with ++@code{__attribute__ ((visibility ("hidden")))} so that they do not ++appear in the export table of a DSO and do not require a PLT indirection ++when used within the DSO. Enabling this option can have a dramatic effect ++on load and link times of a DSO as it massively reduces the size of the ++dynamic export table when the library makes heavy use of templates. While ++it can cause bloating through duplication of code within each DSO where ++it is used, often the wastage is less than the considerable space occupied ++by a long symbol name in the export table which is typical when using ++templates and namespaces. For even more savings, combine with the ++@code{-fvisibility=hidden} switch. ++ + @item -fno-weak + @opindex fno-weak + Do not use weak symbol support, even if it is provided by the linker. +@@ -11198,6 +11214,54 @@ + + The default without @option{-fpic} is @code{initial-exec}; with + @option{-fpic} the default is @code{global-dynamic}. ++ ++@item -fvisibility=@var{default|internal|hidden|protected} ++@opindex fvisibility ++Set the default ELF image symbol visibility to the specified option - all ++symbols will be marked with this unless overrided within the code. ++Using this feature can very substantially improve linking and ++load times of shared object libraries, produce more optimised ++code, provide near-perfect API export and prevent symbol clashes. ++It is @strong{strongly} recommended that you use this in any shared objects ++you distribute. ++ ++Despite the nomenclature, @code{default} always means public ie; ++available to be linked against from outside the shared object. ++@code{protected} and @code{internal} are pretty useless in real-world ++usage so the only other commonly used option will be @code{hidden}. ++The default if -fvisibility isn't specified is @code{default} ie; make every ++symbol public - this causes the same behaviour as previous versions of ++GCC. ++ ++A good explanation of the benefits offered by ensuring ELF ++symbols have the correct visibility is given by ``How To Write ++Shared Libraries'' by Ulrich Drepper (which can be found at ++@w{@uref{http://people.redhat.com/~drepper/}}) - however a superior ++solution made possible by this option to marking things hidden when ++the default is public is to make the default hidden and mark things ++public. This is the norm with DLL's on Windows and with @option{-fvisibility=hidden} ++and @code{__attribute__ ((visibility("default")))} instead of ++@code{__declspec(dllexport)} you get almost identical semantics with ++identical syntax. This is a great boon to those working with ++cross-platform projects. ++ ++For those adding visibility support to existing code, you may find ++@samp{#pragma GCC visibility} of use. This works by you enclosing ++the declarations you wish to set visibility for with (for example) ++@samp{#pragma GCC visibility push(hidden)} and ++@samp{#pragma GCC visibility pop}. These can be nested up to sixteen ++times. Bear in mind that symbol visibility should be viewed @strong{as ++part of the API interface contract} and thus all new code should ++always specify visibility when it is not the default ie; declarations ++only for use within the local DSO should @strong{always} be marked explicitly ++as hidden as so to avoid PLT indirection overheads - making this ++abundantly clear also aids readability and self-documentation of the code. ++Note that due to ISO C++ specification requirements, operator new and ++operator delete must always be of default visibility. ++ ++An overview of these techniques, their benefits and how to use them ++is at @w{@uref{http://www.nedprod.com/programs/gccvisibility.html}}. ++ + @end table + + @c man end + +diff -aur gcc-3.4.0orig/gcc/flags.h gcc-3.4.0/gcc/flags.h +--- gcc-3.4.0orig/gcc/flags.h 2004-02-18 00:09:04.000000000 +0000 ++++ gcc-3.4.0/gcc/flags.h 2004-05-09 08:10:53.000000000 +0100 +@@ -60,6 +60,30 @@ + /* Nonzero means emit debugging information only for symbols which are used. */ + extern int flag_debug_only_used_symbols; + ++/* Enumerate visibility settings. */ ++#ifndef SYMBOL_VISIBILITY_DEFINED ++#define SYMBOL_VISIBILITY_DEFINED ++enum symbol_visibility ++{ ++ VISIBILITY_DEFAULT, ++ VISIBILITY_INTERNAL, ++ VISIBILITY_HIDDEN, ++ VISIBILITY_PROTECTED ++}; ++#endif ++ ++/* The default visibility for all symbols (unless overridden). */ ++extern enum symbol_visibility default_visibility; ++ ++struct visibility_flags ++{ ++ unsigned inpragma : 1; /* True when in #pragma GCC visibility. */ ++ unsigned inlineshidden : 1; /* True when -finlineshidden in effect. */ ++}; ++ ++/* Global visibility options. */ ++extern struct visibility_flags visibility_options; ++ + /* Nonzero means do optimizations. -opt. */ + + extern int optimize; + +diff -aur gcc-3.4.0orig/gcc/opts.c gcc-3.4.0/gcc/opts.c +--- gcc-3.4.0orig/gcc/opts.c 2004-02-18 00:09:04.000000000 +0000 ++++ gcc-3.4.0/gcc/opts.c 2004-05-09 08:10:53.000000000 +0100 +@@ -142,6 +142,12 @@ + write_symbols is set to DBX_DEBUG, XCOFF_DEBUG, or DWARF_DEBUG. */ + bool use_gnu_debug_info_extensions; + ++/* The default visibility for all symbols (unless overridden) */ ++enum symbol_visibility default_visibility = VISIBILITY_DEFAULT; ++ ++/* Global visibility options. */ ++struct visibility_flags visibility_options; ++ + /* Columns of --help display. */ + static unsigned int columns = 80; + +@@ -1440,6 +1446,21 @@ + flag_verbose_asm = value; + break; + ++ case OPT_fvisibility_: ++ { ++ if(!strcmp(arg, "default")) ++ default_visibility=VISIBILITY_DEFAULT; ++ else if(!strcmp(arg, "internal")) ++ default_visibility=VISIBILITY_INTERNAL; ++ else if(!strcmp(arg, "hidden")) ++ default_visibility=VISIBILITY_HIDDEN; ++ else if(!strcmp(arg, "protected")) ++ default_visibility=VISIBILITY_PROTECTED; ++ else ++ error("unrecognised visibility value \"%s\"", arg); ++ } ++ break; ++ + case OPT_fweb: + flag_web = value; + break; + +diff -aur gcc-3.4.0orig/gcc/tree.c gcc-3.4.0/gcc/tree.c +--- gcc-3.4.0orig/gcc/tree.c 2004-02-05 22:01:35.000000000 +0000 ++++ gcc-3.4.0/gcc/tree.c 2004-05-10 15:22:52.000000000 +0100 +@@ -2563,6 +2563,11 @@ + layout_decl (t, 0); + else if (code == FUNCTION_DECL) + DECL_MODE (t) = FUNCTION_MODE; ++ ++ /* Set default visibility to whatever the user supplied with ++ visibility_specified depending on #pragma GCC visibility. */ ++ DECL_VISIBILITY (t) = default_visibility; ++ DECL_VISIBILITYSPECIFIED (t) = visibility_options.inpragma; + + return t; + } + +diff -aur gcc-3.4.0orig/gcc/tree.h gcc-3.4.0/gcc/tree.h +--- gcc-3.4.0orig/gcc/tree.h 2004-02-08 01:52:43.000000000 +0000 ++++ gcc-3.4.0/gcc/tree.h 2004-05-09 08:10:54.000000000 +0100 +@@ -1499,6 +1499,10 @@ + /* Value of the decls's visibility attribute */ + #define DECL_VISIBILITY(NODE) (DECL_CHECK (NODE)->decl.visibility) + ++/* Nonzero means that the decl had its visibility specified rather than ++ being inferred. */ ++#define DECL_VISIBILITYSPECIFIED(NODE) (DECL_CHECK (NODE)->decl.visibility_specified) ++ + /* In a FUNCTION_DECL, nonzero if the function cannot be inlined. */ + #define DECL_UNINLINABLE(NODE) (FUNCTION_DECL_CHECK (NODE)->decl.uninlinable) + +@@ -1633,7 +1637,8 @@ + || TREE_CODE (DECL_CONTEXT (EXP)) == TRANSLATION_UNIT_DECL) + + /* Enumerate visibility settings. */ +- ++#ifndef SYMBOL_VISIBILITY_DEFINED ++#define SYMBOL_VISIBILITY_DEFINED + enum symbol_visibility + { + VISIBILITY_DEFAULT, +@@ -1641,6 +1646,7 @@ + VISIBILITY_HIDDEN, + VISIBILITY_PROTECTED + }; ++#endif + + struct function; + +@@ -1684,8 +1690,7 @@ + unsigned thread_local_flag : 1; + unsigned declared_inline_flag : 1; + ENUM_BITFIELD(symbol_visibility) visibility : 2; +- unsigned unused : 1; +- /* one unused bit. */ ++ unsigned visibility_specified : 1; + + unsigned lang_flag_0 : 1; + unsigned lang_flag_1 : 1; + +diff -aur gcc-3.4.0orig/gcc/varasm.c gcc-3.4.0/gcc/varasm.c +--- gcc-3.4.0orig/gcc/varasm.c 2004-04-14 22:14:08.000000000 +0100 ++++ gcc-3.4.0/gcc/varasm.c 2004-05-09 08:10:54.000000000 +0100 +@@ -5150,8 +5150,8 @@ + /* Static variables are always local. */ + else if (! TREE_PUBLIC (exp)) + local_p = true; +- /* A variable is local if the user tells us so. */ +- else if (DECL_VISIBILITY (exp) != VISIBILITY_DEFAULT) ++ /* A variable is local if the user explicitly tells us so. */ ++ else if (DECL_VISIBILITYSPECIFIED (exp) && DECL_VISIBILITY (exp) != VISIBILITY_DEFAULT) + local_p = true; + /* Otherwise, variables defined outside this object may not be local. */ + else if (DECL_EXTERNAL (exp)) +@@ -5159,6 +5159,9 @@ + /* Linkonce and weak data are never local. */ + else if (DECL_ONE_ONLY (exp) || DECL_WEAK (exp)) + local_p = false; ++ /* If none of the above and visibility is not default, make local. */ ++ else if (DECL_VISIBILITY (exp) != VISIBILITY_DEFAULT) ++ local_p = true; + /* If PIC, then assume that any global name can be overridden by + symbols resolved from other modules. */ + else if (shlib) + +diff -Naur gcc-3.4.0orig/gcc/testsuite/gcc.dg/visibility-9.c gcc-3.4.0/gcc/testsuite/gcc.dg/visibility-9.c +--- gcc-3.4.0orig/gcc/testsuite/gcc.dg/visibility-9.c 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/gcc.dg/visibility-9.c 2004-05-09 12:40:39.000000000 +0100 +@@ -0,0 +1,9 @@ ++/* Test that -fvisibility works. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility=hidden" } */ ++/* { dg-final { scan-assembler "\\.hidden.*foo" } } */ ++ ++void foo(); ++ ++void foo() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/gcc.dg/visibility-a.c gcc-3.4.0/gcc/testsuite/gcc.dg/visibility-a.c +--- gcc-3.4.0orig/gcc/testsuite/gcc.dg/visibility-a.c 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/gcc.dg/visibility-a.c 2004-05-09 12:55:04.000000000 +0100 +@@ -0,0 +1,10 @@ ++/* Test that #pragma GCC visibility works. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*foo" } } */ ++ ++#pragma GCC visibility push(hidden) ++void foo(); ++#pragma GCC visibility pop ++ ++void foo() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility.C 2004-05-09 19:17:13.000000000 +0100 +@@ -0,0 +1,12 @@ ++/* Test that -fvisibility affects class members. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility=hidden" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++class Foo ++{ ++ void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-inlines-hidden.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-inlines-hidden.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-inlines-hidden.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-inlines-hidden.C 2004-05-09 19:17:59.000000000 +0100 +@@ -0,0 +1,18 @@ ++/* Test that -fvisibility-inlines-hidden affects class members. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility-inlines-hidden" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++class Foo ++{ ++public: ++ void method() { } ++}; ++ ++int main(void) ++{ ++ Foo f; ++ f.method(); ++ return 0; ++} +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override1.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override1.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override1.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override1.C 2004-05-09 19:18:06.000000000 +0100 +@@ -0,0 +1,12 @@ ++/* Test that -fvisibility does not override class member specific settings. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility=hidden" } */ ++/* { dg-final { scan-assembler "\\.internal.*Foo.methodEv" } } */ ++ ++class __attribute__ ((visibility ("internal"))) Foo ++{ ++ void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override2.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override2.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override2.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/fvisibility-override2.C 2004-05-09 19:18:12.000000000 +0100 +@@ -0,0 +1,12 @@ ++/* Test that -fvisibility does not override class member specific settings. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fvisibility=hidden" } */ ++/* { dg-final { scan-assembler "\\.internal.*Foo.methodEv" } } */ ++ ++class Foo ++{ ++ __attribute__ ((visibility ("internal"))) void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/memfuncts.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/memfuncts.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/memfuncts.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/memfuncts.C 2004-05-09 19:18:19.000000000 +0100 +@@ -0,0 +1,11 @@ ++/* Test that setting visibility for class member functions works. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++class __attribute__ ((visibility ("hidden"))) Foo ++{ ++ void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/noPLT.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/noPLT.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/noPLT.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/noPLT.C 2004-05-09 19:21:49.000000000 +0100 +@@ -0,0 +1,20 @@ ++/* Test that -fvisibility=hidden prevents PLT. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-options "-fPIC -fvisibility=hidden" } */ ++/* { dg-final { scan-assembler-not "methodEv@PLT" } } */ ++ ++class Foo ++{ ++public: ++ void method(); ++}; ++ ++void Foo::method() { } ++ ++int main(void) ++{ ++ Foo f; ++ f.method(); ++ return 0; ++} +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma.C 2004-05-09 19:18:30.000000000 +0100 +@@ -0,0 +1,13 @@ ++/* Test that #pragma GCC visibility affects class members. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++#pragma GCC visibility push(hidden) ++class Foo ++{ ++ void method(); ++}; ++#pragma GCC visibility pop ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma-override1.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma-override1.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma-override1.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma-override1.C 2004-05-09 19:18:36.000000000 +0100 +@@ -0,0 +1,13 @@ ++/* Test that #pragma GCC visibility does not override class member specific settings. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.internal.*Foo.methodEv" } } */ ++ ++#pragma GCC visibility push(hidden) ++class __attribute__ ((visibility ("internal"))) Foo ++{ ++ void method(); ++}; ++#pragma GCC visibility pop ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma-override2.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma-override2.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/pragma-override2.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/pragma-override2.C 2004-05-09 19:18:44.000000000 +0100 +@@ -0,0 +1,13 @@ ++/* Test that #pragma GCC visibility does not override class member specific settings. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.internal.*Foo.methodEv" } } */ ++ ++#pragma GCC visibility push(hidden) ++class Foo ++{ ++ __attribute__ ((visibility ("internal"))) void method(); ++}; ++#pragma GCC visibility pop ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/staticmemfuncts.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/staticmemfuncts.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/staticmemfuncts.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/staticmemfuncts.C 2004-05-09 19:18:50.000000000 +0100 +@@ -0,0 +1,11 @@ ++/* Test that setting visibility for static class member functions works. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*Foo.methodEv" } } */ ++ ++class __attribute__ ((visibility ("hidden"))) Foo ++{ ++ static void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/virtual.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/virtual.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/virtual.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/virtual.C 2004-05-09 13:24:06.000000000 +0100 +@@ -0,0 +1,11 @@ ++/* Test that setting visibility for class affects virtual table. */ ++/* { dg-do compile } */ ++/* { dg-require-visibility "" } */ ++/* { dg-final { scan-assembler "\\.hidden.*ZTV3Foo" } } */ ++ ++class __attribute__ ((visibility ("hidden"))) Foo ++{ ++ virtual void method(); ++}; ++ ++void Foo::method() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-1.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-1.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-1.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-1.C 2003-12-10 06:34:44.000000000 +0000 +@@ -0,0 +1,8 @@ ++/* Test visibility attribute on function definition. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ ++ ++void ++__attribute__((visibility ("hidden"))) ++foo() ++{ } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-2.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-2.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-2.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-2.C 2003-12-10 06:34:44.000000000 +0000 +@@ -0,0 +1,7 @@ ++/* Test that visibility attribute on declaration extends to definition. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ ++ ++void __attribute__((visibility ("hidden"))) foo(); ++ ++void foo() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-3.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-3.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-3.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-3.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,7 @@ ++/* Test visibility attribute on forward declaration of global variable */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ ++ ++int ++__attribute__((visibility ("hidden"))) ++xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-4.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-4.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-4.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-4.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,8 @@ ++/* Test visibility attribute on forward declaration of global variable */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ ++ ++extern int __attribute__ ((visibility ("hidden"))) ++xyzzy; ++ ++int xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-5.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-5.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-5.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-5.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,11 @@ ++/* Test visibility attribute on definition of a function that has ++ already had a forward declaration. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ ++ ++void foo(); ++ ++void ++ __attribute__((visibility ("hidden"))) ++foo() ++{ } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-6.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-6.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-6.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-6.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,10 @@ ++/* Test visibility attribute on definition of global variable that has ++ already had a forward declaration. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ ++ ++extern int xyzzy; ++ ++int ++__attribute__((visibility ("hidden"))) ++xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-7.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-7.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility/visibility-7.C 1970-01-01 01:00:00.000000000 +0100 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility/visibility-7.C 2003-12-10 06:34:45.000000000 +0000 +@@ -0,0 +1,11 @@ ++/* Test warning from conflicting visibility specifications. */ ++/* { dg-do compile { target *86-*-linux* } } */ ++/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ ++ ++extern int ++__attribute__((visibility ("hidden"))) ++xyzzy; /* { dg-warning "previous declaration here" "" } */ ++ ++int ++__attribute__((visibility ("protected"))) ++xyzzy = 5; /* { dg-warning "visibility attribute ignored" "" } */ +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-1.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-1.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-1.C 2003-12-10 06:34:44.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-1.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,8 +0,0 @@ +-/* Test visibility attribute on function definition. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ +- +-void +-__attribute__((visibility ("hidden"))) +-foo() +-{ } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-2.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-2.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-2.C 2003-12-10 06:34:44.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-2.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,7 +0,0 @@ +-/* Test that visibility attribute on declaration extends to definition. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ +- +-void __attribute__((visibility ("hidden"))) foo(); +- +-void foo() { } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-3.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-3.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-3.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-3.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,7 +0,0 @@ +-/* Test visibility attribute on forward declaration of global variable */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ +- +-int +-__attribute__((visibility ("hidden"))) +-xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-4.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-4.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-4.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-4.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,8 +0,0 @@ +-/* Test visibility attribute on forward declaration of global variable */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ +- +-extern int __attribute__ ((visibility ("hidden"))) +-xyzzy; +- +-int xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-5.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-5.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-5.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-5.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,11 +0,0 @@ +-/* Test visibility attribute on definition of a function that has +- already had a forward declaration. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*_Z3foov" } } */ +- +-void foo(); +- +-void +- __attribute__((visibility ("hidden"))) +-foo() +-{ } +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-6.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-6.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-6.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-6.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,10 +0,0 @@ +-/* Test visibility attribute on definition of global variable that has +- already had a forward declaration. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ +- +-extern int xyzzy; +- +-int +-__attribute__((visibility ("hidden"))) +-xyzzy = 5; +diff -Naur gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-7.C gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-7.C +--- gcc-3.4.0orig/gcc/testsuite/g++.dg/ext/visibility-7.C 2003-12-10 06:34:45.000000000 +0000 ++++ gcc-3.4.0/gcc/testsuite/g++.dg/ext/visibility-7.C 1970-01-01 01:00:00.000000000 +0100 +@@ -1,11 +0,0 @@ +-/* Test warning from conflicting visibility specifications. */ +-/* { dg-do compile { target *86-*-linux* } } */ +-/* { dg-final { scan-assembler "\\.hidden.*xyzzy" } } */ +- +-extern int +-__attribute__((visibility ("hidden"))) +-xyzzy; /* { dg-warning "previous declaration here" "" } */ +- +-int +-__attribute__((visibility ("protected"))) +-xyzzy = 5; /* { dg-warning "visibility attribute ignored" "" } */ diff --git a/meta/packages/gcc/gcc-3.4.4/always-fixincperm.patch b/meta/packages/gcc/gcc-3.4.4/always-fixincperm.patch new file mode 100644 index 000000000..59e5e2ede --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/always-fixincperm.patch @@ -0,0 +1,32 @@ +Index: gcc-3.4.3/gcc/configure +=================================================================== +--- gcc-3.4.3.orig/gcc/configure 2004-11-04 23:14:05.000000000 -0500 ++++ gcc-3.4.3/gcc/configure 2005-03-11 14:41:06.373910320 -0500 +@@ -9916,11 +9916,6 @@ + BUILD_PREFIX=build- + BUILD_PREFIX_1=build- + BUILD_CFLAGS='$(INTERNAL_CFLAGS) $(T_CFLAGS) $(CFLAGS_FOR_BUILD)' +- +- if test "x$TARGET_SYSTEM_ROOT" = x; then +- STMP_FIXINC= +- STMP_FIXPROTO= +- fi + fi + + # Expand extra_headers to include complete path. +Index: gcc-3.4.3/gcc/configure.ac +=================================================================== +--- gcc-3.4.3.orig/gcc/configure.ac 2004-09-23 20:43:53.000000000 -0400 ++++ gcc-3.4.3/gcc/configure.ac 2005-03-11 14:40:55.256600408 -0500 +@@ -1524,11 +1524,6 @@ + BUILD_PREFIX=build- + BUILD_PREFIX_1=build- + BUILD_CFLAGS='$(INTERNAL_CFLAGS) $(T_CFLAGS) $(CFLAGS_FOR_BUILD)' +- +- if test "x$TARGET_SYSTEM_ROOT" = x; then +- STMP_FIXINC= +- STMP_FIXPROTO= +- fi + fi + + # Expand extra_headers to include complete path. diff --git a/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-bigendian-uclibc.patch b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-bigendian-uclibc.patch new file mode 100644 index 000000000..8fa9af880 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-bigendian-uclibc.patch @@ -0,0 +1,30 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- gcc-3.4.1/gcc/config.gcc~gcc-3.4.0-arm-bigendian-uclibc ++++ gcc-3.4.1/gcc/config.gcc +@@ -666,6 +666,11 @@ + ;; + arm*-*-linux-uclibc*) # ARM GNU/Linux with ELF - uClibc + tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" ++ case $target in ++ arm*b-*) ++ tm_defines="TARGET_BIG_ENDIAN_DEFAULT=1 $tm_defines" ++ ;; ++ esac + tmake_file="t-slibgcc-elf-ver t-linux-uclibc arm/t-linux" + extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" + gnu_ld=yes +--- gcc-3.4.1/gcc/config/arm/linux-elf.h~gcc-3.4.0-arm-bigendian-uclibc ++++ gcc-3.4.1/gcc/config/arm/linux-elf.h +@@ -120,7 +120,7 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2} \ + -X \ +- %{mbig-endian:-EB}" \ ++ %{mbig-endian:-EB} %{mlittle-endian:-EL}" \ + SUBTARGET_EXTRA_LINK_SPEC + #endif + diff --git a/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-bigendian.patch b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-bigendian.patch new file mode 100644 index 000000000..c9288c6c1 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-bigendian.patch @@ -0,0 +1,70 @@ +By Lennert Buytenhek +Adds support for arm*b-linux* big-endian ARM targets + +See http://gcc.gnu.org/PR16350 + +diff -urN gcc-3.4.0.orig/gcc/config/arm/linux-elf.h gcc-3.4.0/gcc/config/arm/linux-elf.h +--- gcc-3.4.0.orig/gcc/config/arm/linux-elf.h 2004-01-31 07:18:11.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/linux-elf.h 2004-07-02 14:46:29.225443757 +0200 +@@ -30,17 +30,34 @@ + /* Do not assume anything about header files. */ + #define NO_IMPLICIT_EXTERN_C + ++/* ++ * 'config.gcc' defines TARGET_BIG_ENDIAN_DEFAULT as 1 for arm*b-* ++ * (big endian) configurations. ++ */ ++#if TARGET_BIG_ENDIAN_DEFAULT ++#define TARGET_ENDIAN_DEFAULT ARM_FLAG_BIG_END ++#define TARGET_ENDIAN_OPTION "mbig-endian" ++#define TARGET_LINKER_EMULATION "armelfb_linux" ++#else ++#define TARGET_ENDIAN_DEFAULT 0 ++#define TARGET_ENDIAN_OPTION "mlittle-endian" ++#define TARGET_LINKER_EMULATION "armelf_linux" ++#endif ++ + /* Default is to use APCS-32 mode. */ + #undef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_APCS_32 | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_APCS_32 | \ ++ ARM_FLAG_MMU_TRAPS | \ ++ TARGET_ENDIAN_DEFAULT ) + + #define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm6 + +-#define SUBTARGET_EXTRA_LINK_SPEC " -m armelf_linux -p" ++#define SUBTARGET_EXTRA_LINK_SPEC " -m " TARGET_LINKER_EMULATION " -p" + + #undef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "marm", "mlittle-endian", "mhard-float", "mapcs-32", "mno-thumb-interwork" } ++ { "marm", TARGET_ENDIAN_OPTION, "mhard-float", "mapcs-32", "mno-thumb-interwork" } + + #define CPP_APCS_PC_DEFAULT_SPEC "-D__APCS_32__" + +@@ -89,7 +106,7 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2} \ + -X \ +- %{mbig-endian:-EB}" \ ++ %{mbig-endian:-EB} %{mlittle-endian:-EL}" \ + SUBTARGET_EXTRA_LINK_SPEC + + #define TARGET_OS_CPP_BUILTINS() LINUX_TARGET_OS_CPP_BUILTINS() +diff -urN gcc-3.4.0.orig/gcc/config.gcc gcc-3.4.0/gcc/config.gcc +--- gcc-3.4.0.orig/gcc/config.gcc 2004-04-17 04:28:24.000000000 +0200 ++++ gcc-3.4.0/gcc/config.gcc 2004-07-02 14:44:40.045822542 +0200 +@@ -666,6 +666,11 @@ + ;; + arm*-*-linux*) # ARM GNU/Linux with ELF + tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" ++ case $target in ++ arm*b-*) ++ tm_defines="TARGET_BIG_ENDIAN_DEFAULT=1 $tm_defines" ++ ;; ++ esac + tmake_file="t-slibgcc-elf-ver t-linux arm/t-linux" + extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" + gnu_ld=yes diff --git a/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-lib1asm.patch b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-lib1asm.patch new file mode 100644 index 000000000..ca42bfbc0 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-lib1asm.patch @@ -0,0 +1,24 @@ +# Fixes errors like the following when building glibc (or any other executable +# or shared library) when using gcc 3.4.0 for ARM with softfloat: +# +# .../libc_pic.os(.text+0x15834): In function `__modf': undefined reference to `__subdf3' +# .../libc_pic.os(.text+0x158b8): In function `__modf': undefined reference to `__subdf3' +# .../libc_pic.os(.text+0x1590c): In function `scalbn': undefined reference to `__muldf3' +# .../libc_pic.os(.text+0x15e94): In function `__ldexpf': undefined reference to `__eqsf2' +# .../libc_pic.os(.text+0xcee4c): In function `monstartup': undefined reference to `__fixsfsi' + +diff -urNd gcc-3.4.0-orig/gcc/config/arm/t-linux gcc-3.4.0/gcc/config/arm/t-linux +--- gcc-3.4.0-orig/gcc/config/arm/t-linux 2003-09-20 23:09:07.000000000 +0200 ++++ gcc-3.4.0/gcc/config/arm/t-linux 2004-05-01 20:31:59.102846400 +0200 +@@ -4,7 +4,10 @@ + LIBGCC2_DEBUG_CFLAGS = -g0 + + LIB1ASMSRC = arm/lib1funcs.asm +-LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx ++LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \ ++ _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \ ++ _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \ ++ _fixsfsi _fixunssfsi + + # MULTILIB_OPTIONS = mhard-float/msoft-float + # MULTILIB_DIRNAMES = hard-float soft-float diff --git a/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-nolibfloat.patch b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-nolibfloat.patch new file mode 100644 index 000000000..43eed3ef2 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-nolibfloat.patch @@ -0,0 +1,24 @@ +# Dimitry Andric , 2004-05-01 +# +# * Removed the extra -lfloat option from LIBGCC_SPEC, since it isn't needed +# anymore. (The required functions are now in libgcc.) +# +# Fixes errors like +# arm-softfloat-linux-gnu/3.4.0/../../../../arm-softfloat-linux-gnu/bin/ld: cannot find -lfloat +# collect2: ld returned 1 exit status +# make[2]: *** [arm-softfloat-linux-gnu/gcc-3.4.0-glibc-2.3.2/build-glibc/iconvdata/ISO8859-1.so] Error 1 +# when building glibc-2.3.3 with gcc-3.4.0 for arm-softfloat + +diff -urNd gcc-3.4.0-orig/gcc/config/arm/linux-elf.h gcc-3.4.0/gcc/config/arm/linux-elf.h +--- gcc-3.4.0-orig/gcc/config/arm/linux-elf.h 2004-01-31 07:18:11.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/linux-elf.h 2004-05-01 19:19:06.935979200 +0200 +@@ -55,7 +73,7 @@ + %{shared:-lc} \ + %{!shared:%{profile:-lc_p}%{!profile:-lc}}" + +-#define LIBGCC_SPEC "%{msoft-float:-lfloat} -lgcc" ++#define LIBGCC_SPEC "-lgcc" + + /* Provide a STARTFILE_SPEC appropriate for GNU/Linux. Here we add + the GNU/Linux magical crtbegin.o file (see crtstuff.c) which + diff --git a/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-softfloat.patch b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-softfloat.patch new file mode 100644 index 000000000..f53d64b37 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.0-arm-softfloat.patch @@ -0,0 +1,256 @@ +# +# Submitted: +# +# Dimitry Andric , 2004-05-01 +# +# Description: +# +# Nicholas Pitre released this patch for gcc soft-float support here: +# http://lists.arm.linux.org.uk/pipermail/linux-arm/2003-October/006436.html +# +# This version has been adapted to work with gcc 3.4.0. +# +# The original patch doesn't distinguish between softfpa and softvfp modes +# in the way Nicholas Pitre probably meant. His description is: +# +# "Default is to use APCS-32 mode with soft-vfp. The old Linux default for +# floats can be achieved with -mhard-float or with the configure +# --with-float=hard option. If -msoft-float or --with-float=soft is used then +# software float support will be used just like the default but with the legacy +# big endian word ordering for double float representation instead." +# +# Which means the following: +# +# * If you compile without -mhard-float or -msoft-float, you should get +# software floating point, using the VFP format. The produced object file +# should have these flags in its header: +# +# private flags = 600: [APCS-32] [VFP float format] [software FP] +# +# * If you compile with -mhard-float, you should get hardware floating point, +# which always uses the FPA format. Object file header flags should be: +# +# private flags = 0: [APCS-32] [FPA float format] +# +# * If you compile with -msoft-float, you should get software floating point, +# using the FPA format. This is done for compatibility reasons with many +# existing distributions. Object file header flags should be: +# +# private flags = 200: [APCS-32] [FPA float format] [software FP] +# +# The original patch from Nicholas Pitre contained the following constructs: +# +# #define SUBTARGET_EXTRA_ASM_SPEC "%{!mcpu=*:-mcpu=xscale} \ +# %{mhard-float:-mfpu=fpa} \ +# %{!mhard-float: %{msoft-float:-mfpu=softfpa;:-mfpu=softvfp}}" +# +# However, gcc doesn't accept this ";:" notation, used in the 3rd line. This +# is probably the reason Robert Schwebel modified it to: +# +# #define SUBTARGET_EXTRA_ASM_SPEC "%{!mcpu=*:-mcpu=xscale} \ +# %{mhard-float:-mfpu=fpa} \ +# %{!mhard-float: %{msoft-float:-mfpu=softfpa -mfpu=softvfp}}" +# +# But this causes the following behaviour: +# +# * If you compile without -mhard-float or -msoft-float, the compiler generates +# software floating point instructions, but *nothing* is passed to the +# assembler, which results in an object file which has flags: +# +# private flags = 0: [APCS-32] [FPA float format] +# +# This is not correct! +# +# * If you compile with -mhard-float, the compiler generates hardware floating +# point instructions, and passes "-mfpu=fpa" to the assembler, which results +# in an object file which has the same flags as in the previous item, but now +# those *are* correct. +# +# * If you compile with -msoft-float, the compiler generates software floating +# point instructions, and passes "-mfpu=softfpa -mfpu=softvfp" (in that +# order) to the assembler, which results in an object file with flags: +# +# private flags = 600: [APCS-32] [VFP float format] [software FP] +# +# This is not correct, because the last "-mfpu=" option on the assembler +# command line determines the actual FPU convention used (which should be FPA +# in this case). +# +# Therefore, I modified this patch to get the desired behaviour. Every +# instance of the notation: +# +# %{msoft-float:-mfpu=softfpa -mfpu=softvfp} +# +# was changed to: +# +# %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp} +# +# I also did the following: +# +# * Modified all TARGET_DEFAULT macros I could find to include ARM_FLAG_VFP, to +# be consistent with Nicholas' original patch. +# * Removed any "msoft-float" or "mhard-float" from all MULTILIB_DEFAULTS +# macros I could find. I think that if you compile without any options, you +# would like to get the defaults. :) +# * Removed the extra -lfloat option from LIBGCC_SPEC, since it isn't needed +# anymore. (The required functions are now in libgcc.) + +diff -urNd gcc-3.4.0-orig/gcc/config/arm/coff.h gcc-3.4.0/gcc/config/arm/coff.h +--- gcc-3.4.0-orig/gcc/config/arm/coff.h 2004-02-24 15:25:22.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/coff.h 2004-05-01 19:07:06.059409600 +0200 +@@ -31,11 +31,16 @@ + #define TARGET_VERSION fputs (" (ARM/coff)", stderr) + + #undef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_SOFT_FLOAT | ARM_FLAG_APCS_32 | ARM_FLAG_APCS_FRAME | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_SOFT_FLOAT \ ++ | ARM_FLAG_VFP \ ++ | ARM_FLAG_APCS_32 \ ++ | ARM_FLAG_APCS_FRAME \ ++ | ARM_FLAG_MMU_TRAPS ) + + #ifndef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "marm", "mlittle-endian", "msoft-float", "mapcs-32", "mno-thumb-interwork" } ++ { "marm", "mlittle-endian", "mapcs-32", "mno-thumb-interwork" } + #endif + + /* This is COFF, but prefer stabs. */ +diff -urNd gcc-3.4.0-orig/gcc/config/arm/elf.h gcc-3.4.0/gcc/config/arm/elf.h +--- gcc-3.4.0-orig/gcc/config/arm/elf.h 2004-02-24 15:25:22.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/elf.h 2004-05-01 19:12:16.976486400 +0200 +@@ -46,7 +46,9 @@ + + #ifndef SUBTARGET_ASM_FLOAT_SPEC + #define SUBTARGET_ASM_FLOAT_SPEC "\ +-%{mapcs-float:-mfloat} %{msoft-float:-mfpu=softfpa}" ++%{mapcs-float:-mfloat} \ ++%{mhard-float:-mfpu=fpa} \ ++%{!mhard-float: %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp}}" + #endif + + #ifndef ASM_SPEC +@@ -106,12 +108,17 @@ + #endif + + #ifndef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_SOFT_FLOAT | ARM_FLAG_APCS_32 | ARM_FLAG_APCS_FRAME | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_SOFT_FLOAT \ ++ | ARM_FLAG_VFP \ ++ | ARM_FLAG_APCS_32 \ ++ | ARM_FLAG_APCS_FRAME \ ++ | ARM_FLAG_MMU_TRAPS ) + #endif + + #ifndef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "marm", "mlittle-endian", "msoft-float", "mapcs-32", "mno-thumb-interwork", "fno-leading-underscore" } ++ { "marm", "mlittle-endian", "mapcs-32", "mno-thumb-interwork", "fno-leading-underscore" } + #endif + + #define TARGET_ASM_FILE_START_APP_OFF true +diff -urNd gcc-3.4.0-orig/gcc/config/arm/linux-elf.h gcc-3.4.0/gcc/config/arm/linux-elf.h +--- gcc-3.4.0-orig/gcc/config/arm/linux-elf.h 2004-01-31 07:18:11.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/linux-elf.h 2004-05-01 19:19:06.935979200 +0200 +@@ -30,9 +30,27 @@ + /* Do not assume anything about header files. */ + #define NO_IMPLICIT_EXTERN_C + +-/* Default is to use APCS-32 mode. */ ++/* ++ * Default is to use APCS-32 mode with soft-vfp. ++ * The old Linux default for floats can be achieved with -mhard-float ++ * or with the configure --with-float=hard option. ++ * If -msoft-float or --with-float=soft is used then software float ++ * support will be used just like the default but with the legacy ++ * big endian word ordering for double float representation instead. ++ */ ++ + #undef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_APCS_32 | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_APCS_32 \ ++ | ARM_FLAG_SOFT_FLOAT \ ++ | ARM_FLAG_VFP \ ++ | ARM_FLAG_MMU_TRAPS ) ++ ++#undef SUBTARGET_EXTRA_ASM_SPEC ++#define SUBTARGET_EXTRA_ASM_SPEC "\ ++%{!mcpu=*:-mcpu=xscale} \ ++%{mhard-float:-mfpu=fpa} \ ++%{!mhard-float: %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp}}" + + #define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm6 + +@@ -40,7 +58,7 @@ + + #undef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "marm", "mlittle-endian", "mhard-float", "mapcs-32", "mno-thumb-interwork" } ++ { "marm", "mlittle-endian", "mapcs-32", "mno-thumb-interwork" } + + #define CPP_APCS_PC_DEFAULT_SPEC "-D__APCS_32__" + +@@ -55,7 +73,7 @@ + %{shared:-lc} \ + %{!shared:%{profile:-lc_p}%{!profile:-lc}}" + +-#define LIBGCC_SPEC "%{msoft-float:-lfloat} -lgcc" ++#define LIBGCC_SPEC "-lgcc" + + /* Provide a STARTFILE_SPEC appropriate for GNU/Linux. Here we add + the GNU/Linux magical crtbegin.o file (see crtstuff.c) which +diff -urNd gcc-3.4.0-orig/gcc/config/arm/t-linux gcc-3.4.0/gcc/config/arm/t-linux +--- gcc-3.4.0-orig/gcc/config/arm/t-linux 2003-09-20 23:09:07.000000000 +0200 ++++ gcc-3.4.0/gcc/config/arm/t-linux 2004-05-01 20:31:59.102846400 +0200 +@@ -4,7 +4,10 @@ + LIBGCC2_DEBUG_CFLAGS = -g0 + + LIB1ASMSRC = arm/lib1funcs.asm +-LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx ++LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \ ++ _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \ ++ _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \ ++ _fixsfsi _fixunssfsi + + # MULTILIB_OPTIONS = mhard-float/msoft-float + # MULTILIB_DIRNAMES = hard-float soft-float +diff -urNd gcc-3.4.0-orig/gcc/config/arm/unknown-elf.h gcc-3.4.0/gcc/config/arm/unknown-elf.h +--- gcc-3.4.0-orig/gcc/config/arm/unknown-elf.h 2004-02-24 15:25:22.000000000 +0100 ++++ gcc-3.4.0/gcc/config/arm/unknown-elf.h 2004-05-01 19:09:09.016212800 +0200 +@@ -30,7 +30,12 @@ + + /* Default to using APCS-32 and software floating point. */ + #ifndef TARGET_DEFAULT +-#define TARGET_DEFAULT (ARM_FLAG_SOFT_FLOAT | ARM_FLAG_APCS_32 | ARM_FLAG_APCS_FRAME | ARM_FLAG_MMU_TRAPS) ++#define TARGET_DEFAULT \ ++ ( ARM_FLAG_SOFT_FLOAT \ ++ | ARM_FLAG_VFP \ ++ | ARM_FLAG_APCS_32 \ ++ | ARM_FLAG_APCS_FRAME \ ++ | ARM_FLAG_MMU_TRAPS ) + #endif + + /* Now we define the strings used to build the spec file. */ +diff -urNd gcc-3.4.0-orig/gcc/config/arm/xscale-elf.h gcc-3.4.0/gcc/config/arm/xscale-elf.h +--- gcc-3.4.0-orig/gcc/config/arm/xscale-elf.h 2003-07-02 01:26:43.000000000 +0200 ++++ gcc-3.4.0/gcc/config/arm/xscale-elf.h 2004-05-01 20:15:36.620105600 +0200 +@@ -49,11 +49,12 @@ + endian, regardless of the endian-ness of the memory + system. */ + +-#define SUBTARGET_EXTRA_ASM_SPEC "%{!mcpu=*:-mcpu=xscale} \ +- %{mhard-float:-mfpu=fpa} \ +- %{!mhard-float: %{msoft-float:-mfpu=softfpa;:-mfpu=softvfp}}" ++#define SUBTARGET_EXTRA_ASM_SPEC "\ ++%{!mcpu=*:-mcpu=xscale} \ ++%{mhard-float:-mfpu=fpa} \ ++%{!mhard-float: %{msoft-float:-mfpu=softfpa} %{!msoft-float:-mfpu=softvfp}}" + + #ifndef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "mlittle-endian", "mno-thumb-interwork", "marm", "msoft-float" } ++ { "mlittle-endian", "mno-thumb-interwork", "marm" } + #endif diff --git a/meta/packages/gcc/gcc-3.4.4/gcc-3.4.1-uclibc-100-conf.patch b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.1-uclibc-100-conf.patch new file mode 100644 index 000000000..29e4c802e --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.1-uclibc-100-conf.patch @@ -0,0 +1,442 @@ +diff -urN gcc-3.4.1-dist/boehm-gc/configure gcc-3.4.1/boehm-gc/configure +--- gcc-3.4.1-dist/boehm-gc/configure 2004-07-01 14:14:03.000000000 -0500 ++++ gcc-3.4.1/boehm-gc/configure 2004-08-12 16:22:57.000000000 -0500 +@@ -1947,6 +1947,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +diff -urN gcc-3.4.1-dist/boehm-gc/ltconfig gcc-3.4.1/boehm-gc/ltconfig +--- gcc-3.4.1-dist/boehm-gc/ltconfig 2002-11-20 09:59:06.000000000 -0600 ++++ gcc-3.4.1/boehm-gc/ltconfig 2004-08-12 15:54:42.000000000 -0500 +@@ -1981,6 +1981,23 @@ + fi + ;; + ++linux-uclibc*) ++ version_type=linux ++ need_lib_prefix=no ++ need_version=no ++ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' ++ soname_spec='${libname}${release}.so$major' ++ finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' ++ shlibpath_var=LD_LIBRARY_PATH ++ shlibpath_overrides_runpath=no ++ deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ++ file_magic_cmd=/usr/bin/file ++ file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ++ # Assume using the uClibc dynamic linker. ++ dynamic_linker="uClibc ld.so" ++ ;; ++ + netbsd*) + version_type=sunos + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then +diff -urN gcc-3.4.1-dist/gcc/config/arm/linux-elf.h gcc-3.4.1/gcc/config/arm/linux-elf.h +--- gcc-3.4.1-dist/gcc/config/arm/linux-elf.h 2004-01-31 00:18:11.000000000 -0600 ++++ gcc-3.4.1/gcc/config/arm/linux-elf.h 2004-08-12 15:54:42.000000000 -0500 +@@ -81,6 +81,18 @@ + "%{!shared:crtend.o%s} %{shared:crtendS.o%s} crtn.o%s" + + #undef LINK_SPEC ++#ifdef USE_UCLIBC ++#define LINK_SPEC "%{h*} %{version:-v} \ ++ %{b} %{Wl,*:%*} \ ++ %{static:-Bstatic} \ ++ %{shared:-shared} \ ++ %{symbolic:-Bsymbolic} \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0} \ ++ -X \ ++ %{mbig-endian:-EB}" \ ++ SUBTARGET_EXTRA_LINK_SPEC ++#else + #define LINK_SPEC "%{h*} %{version:-v} \ + %{b} %{Wl,*:%*} \ + %{static:-Bstatic} \ +@@ -91,6 +103,7 @@ + -X \ + %{mbig-endian:-EB}" \ + SUBTARGET_EXTRA_LINK_SPEC ++#endif + + #define TARGET_OS_CPP_BUILTINS() LINUX_TARGET_OS_CPP_BUILTINS() + +diff -urN gcc-3.4.1-dist/gcc/config/cris/linux.h gcc-3.4.1/gcc/config/cris/linux.h +--- gcc-3.4.1-dist/gcc/config/cris/linux.h 2003-11-28 21:08:09.000000000 -0600 ++++ gcc-3.4.1/gcc/config/cris/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -79,6 +79,25 @@ + #undef CRIS_DEFAULT_CPU_VERSION + #define CRIS_DEFAULT_CPU_VERSION CRIS_CPU_NG + ++#ifdef USE_UCLIBC ++ ++#undef CRIS_SUBTARGET_VERSION ++#define CRIS_SUBTARGET_VERSION " - cris-axis-linux-uclibc" ++ ++#undef CRIS_LINK_SUBTARGET_SPEC ++#define CRIS_LINK_SUBTARGET_SPEC \ ++ "-mcrislinux\ ++ -rpath-link include/asm/../..%s\ ++ %{shared} %{static}\ ++ %{symbolic:-Bdynamic} %{shlib:-Bdynamic} %{static:-Bstatic}\ ++ %{!shared: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}} \ ++ %{!r:%{O2|O3: --gc-sections}}" ++ ++#else /* USE_UCLIBC */ ++ + #undef CRIS_SUBTARGET_VERSION + #define CRIS_SUBTARGET_VERSION " - cris-axis-linux-gnu" + +@@ -93,6 +112,8 @@ + %{!shared:%{!static:%{rdynamic:-export-dynamic}}}\ + %{!r:%{O2|O3: --gc-sections}}" + ++#endif /* USE_UCLIBC */ ++ + + /* Node: Run-time Target */ + +diff -urN gcc-3.4.1-dist/gcc/config/cris/t-linux-uclibc gcc-3.4.1/gcc/config/cris/t-linux-uclibc +--- gcc-3.4.1-dist/gcc/config/cris/t-linux-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.1/gcc/config/cris/t-linux-uclibc 2004-08-12 15:54:43.000000000 -0500 +@@ -0,0 +1,3 @@ ++T_CFLAGS = -DUSE_UCLIBC ++TARGET_LIBGCC2_CFLAGS += -fPIC ++CRTSTUFF_T_CFLAGS_S = $(TARGET_LIBGCC2_CFLAGS) +diff -urN gcc-3.4.1-dist/gcc/config/i386/linux.h gcc-3.4.1/gcc/config/i386/linux.h +--- gcc-3.4.1-dist/gcc/config/i386/linux.h 2003-11-28 21:08:10.000000000 -0600 ++++ gcc-3.4.1/gcc/config/i386/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -118,6 +118,15 @@ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.1}} \ + %{static:-static}}}" + #else ++#if defined USE_UCLIBC ++#define LINK_SPEC "-m elf_i386 %{shared:-shared} \ ++ %{!shared: \ ++ %{!ibcs: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}} \ ++ %{static:-static}}}" ++#else + #define LINK_SPEC "-m elf_i386 %{shared:-shared} \ + %{!shared: \ + %{!ibcs: \ +@@ -126,6 +135,7 @@ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ + %{static:-static}}}" + #endif ++#endif + + /* A C statement (sans semicolon) to output to the stdio stream + FILE the assembler definition of uninitialized global DECL named +diff -urN gcc-3.4.1-dist/gcc/config/mips/linux.h gcc-3.4.1/gcc/config/mips/linux.h +--- gcc-3.4.1-dist/gcc/config/mips/linux.h 2004-06-15 20:42:24.000000000 -0500 ++++ gcc-3.4.1/gcc/config/mips/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -109,6 +109,17 @@ + + /* Borrowed from sparc/linux.h */ + #undef LINK_SPEC ++#ifdef USE_UCLIBC ++#define LINK_SPEC \ ++ "%(endian_spec) \ ++ %{shared:-shared} \ ++ %{!shared: \ ++ %{!ibcs: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}} \ ++ %{static:-static}}}" ++#else + #define LINK_SPEC \ + "%(endian_spec) \ + %{shared:-shared} \ +@@ -118,6 +129,7 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}} \ + %{static:-static}}}" ++#endif + + #undef SUBTARGET_ASM_SPEC + #define SUBTARGET_ASM_SPEC "\ +diff -urN gcc-3.4.1-dist/gcc/config/rs6000/linux.h gcc-3.4.1/gcc/config/rs6000/linux.h +--- gcc-3.4.1-dist/gcc/config/rs6000/linux.h 2004-02-25 09:11:19.000000000 -0600 ++++ gcc-3.4.1/gcc/config/rs6000/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -61,7 +61,11 @@ + #define LINK_START_DEFAULT_SPEC "%(link_start_linux)" + + #undef LINK_OS_DEFAULT_SPEC ++#ifdef USE_UCLIBC ++#define LINK_OS_DEFAULT_SPEC "%(link_os_linux_uclibc)" ++#else + #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)" ++#endif + + #define LINK_GCC_C_SEQUENCE_SPEC \ + "%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}" +diff -urN gcc-3.4.1-dist/gcc/config/rs6000/sysv4.h gcc-3.4.1/gcc/config/rs6000/sysv4.h +--- gcc-3.4.1-dist/gcc/config/rs6000/sysv4.h 2004-06-10 01:39:50.000000000 -0500 ++++ gcc-3.4.1/gcc/config/rs6000/sysv4.h 2004-08-12 15:54:43.000000000 -0500 +@@ -947,6 +947,7 @@ + mcall-linux : %(link_os_linux) ; \ + mcall-gnu : %(link_os_gnu) ; \ + mcall-netbsd : %(link_os_netbsd) ; \ ++ mcall-linux-uclibc : %(link_os_linux_uclibc); \ + mcall-openbsd: %(link_os_openbsd) ; \ + : %(link_os_default) }" + +@@ -1124,6 +1125,10 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}}}" + ++#define LINK_OS_LINUX_UCLIBC_SPEC "-m elf32ppclinux %{!shared: %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}}" ++ + #if defined(HAVE_LD_EH_FRAME_HDR) + # define LINK_EH_SPEC "%{!static:--eh-frame-hdr} " + #endif +@@ -1290,6 +1295,7 @@ + { "link_os_sim", LINK_OS_SIM_SPEC }, \ + { "link_os_freebsd", LINK_OS_FREEBSD_SPEC }, \ + { "link_os_linux", LINK_OS_LINUX_SPEC }, \ ++ { "link_os_linux_uclibc", LINK_OS_LINUX_UCLIBC_SPEC }, \ + { "link_os_gnu", LINK_OS_GNU_SPEC }, \ + { "link_os_netbsd", LINK_OS_NETBSD_SPEC }, \ + { "link_os_openbsd", LINK_OS_OPENBSD_SPEC }, \ +diff -urN gcc-3.4.1-dist/gcc/config/sh/linux.h gcc-3.4.1/gcc/config/sh/linux.h +--- gcc-3.4.1-dist/gcc/config/sh/linux.h 2004-01-11 20:29:13.000000000 -0600 ++++ gcc-3.4.1/gcc/config/sh/linux.h 2004-08-12 15:54:43.000000000 -0500 +@@ -73,12 +73,21 @@ + #undef SUBTARGET_LINK_EMUL_SUFFIX + #define SUBTARGET_LINK_EMUL_SUFFIX "_linux" + #undef SUBTARGET_LINK_SPEC ++#ifdef USE_UCLIBC ++#define SUBTARGET_LINK_SPEC \ ++ "%{shared:-shared} \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}} \ ++ %{static:-static}" ++#else + #define SUBTARGET_LINK_SPEC \ + "%{shared:-shared} \ + %{!static: \ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ + %{static:-static}" ++#endif + + #undef LIB_SPEC + #define LIB_SPEC \ +diff -urN gcc-3.4.1-dist/gcc/config/sh/t-linux-uclibc gcc-3.4.1/gcc/config/sh/t-linux-uclibc +--- gcc-3.4.1-dist/gcc/config/sh/t-linux-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.1/gcc/config/sh/t-linux-uclibc 2004-08-12 15:54:43.000000000 -0500 +@@ -0,0 +1,13 @@ ++T_CFLAGS = -DUSE_UCLIBC ++ ++TARGET_LIBGCC2_CFLAGS = -fpic -DNO_FPSCR_VALUES ++LIB1ASMFUNCS_CACHE = _ic_invalidate ++ ++LIB2FUNCS_EXTRA= ++ ++MULTILIB_OPTIONS= $(MULTILIB_ENDIAN) m3e/m4 ++MULTILIB_DIRNAMES= ++MULTILIB_MATCHES = ++MULTILIB_EXCEPTIONS= ++ ++EXTRA_MULTILIB_PARTS= crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o +diff -urN gcc-3.4.1-dist/gcc/config/sh/t-sh64-uclibc gcc-3.4.1/gcc/config/sh/t-sh64-uclibc +--- gcc-3.4.1-dist/gcc/config/sh/t-sh64-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.1/gcc/config/sh/t-sh64-uclibc 2004-08-12 15:54:43.000000000 -0500 +@@ -0,0 +1,13 @@ ++EXTRA_MULTILIB_PARTS= crt1.o crti.o crtn.o crtbegin.o crtend.o ++ ++LIB1ASMFUNCS = \ ++ _sdivsi3 _sdivsi3_i4 _udivsi3 _udivsi3_i4 _set_fpscr \ ++ _shcompact_call_trampoline _shcompact_return_trampoline \ ++ _shcompact_incoming_args _ic_invalidate _nested_trampoline \ ++ _push_pop_shmedia_regs \ ++ _udivdi3 _divdi3 _umoddi3 _moddi3 ++ ++MULTILIB_OPTIONS = $(MULTILIB_ENDIAN) m5-32media-nofpu/m5-compact/m5-compact-nofpu/m5-64media/m5-64media-nofpu ++MULTILIB_DIRNAMES= $(MULTILIB_ENDIAN) nofpu compact nofpu/compact media64 nofpu/media64 ++MULTILIB_MATCHES= ++MULTILIB_EXCEPTIONS= +diff -urN gcc-3.4.1-dist/gcc/config/t-linux-uclibc gcc-3.4.1/gcc/config/t-linux-uclibc +--- gcc-3.4.1-dist/gcc/config/t-linux-uclibc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.1/gcc/config/t-linux-uclibc 2004-08-12 15:54:43.000000000 -0500 +@@ -0,0 +1,15 @@ ++T_CFLAGS = -DUSE_UCLIBC ++ ++# Compile crtbeginS.o and crtendS.o with pic. ++CRTSTUFF_T_CFLAGS_S = $(CRTSTUFF_T_CFLAGS) -fPIC ++# Compile libgcc2.a with pic. ++TARGET_LIBGCC2_CFLAGS = -fPIC ++ ++# Override t-slibgcc-elf-ver to export some libgcc symbols with ++# the symbol versions that glibc used. ++#SHLIB_MAPFILES += $(srcdir)/config/libgcc-glibc.ver ++ ++# Use unwind-dw2-fde ++LIB2ADDEH = $(srcdir)/unwind-dw2.c $(srcdir)/unwind-dw2-fde.c \ ++ $(srcdir)/unwind-sjlj.c $(srcdir)/gthr-gnat.c $(srcdir)/unwind-c.c ++LIB2ADDEHDEP = unwind.inc unwind-dw2-fde.h +diff -urN gcc-3.4.1-dist/gcc/config.gcc gcc-3.4.1/gcc/config.gcc +--- gcc-3.4.1-dist/gcc/config.gcc 2004-04-21 10:12:35.000000000 -0500 ++++ gcc-3.4.1/gcc/config.gcc 2004-08-12 15:59:46.000000000 -0500 +@@ -664,6 +664,12 @@ + extra_parts="" + use_collect2=yes + ;; ++arm*-*-linux-uclibc*) # ARM GNU/Linux with ELF - uClibc ++ tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" ++ tmake_file="t-slibgcc-elf-ver t-linux-uclibc arm/t-linux" ++ extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" ++ gnu_ld=yes ++ ;; + arm*-*-linux*) # ARM GNU/Linux with ELF + tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" + tmake_file="t-slibgcc-elf-ver t-linux arm/t-linux" +@@ -725,6 +731,10 @@ + tmake_file="cris/t-cris cris/t-elfmulti" + gas=yes + ;; ++cris-*-linux-uclibc*) ++ tm_file="dbxelf.h elfos.h svr4.h ${tm_file} linux.h cris/linux.h" ++ tmake_file="cris/t-cris t-slibgcc-elf-ver cris/t-linux-uclibc" ++ ;; + cris-*-linux*) + tm_file="dbxelf.h elfos.h svr4.h ${tm_file} linux.h cris/linux.h" + tmake_file="cris/t-cris t-slibgcc-elf-ver cris/t-linux" +@@ -988,6 +998,11 @@ + thread_file='single' + fi + ;; ++i[34567]86-*-linux*uclibc*) # Intel 80386's running GNU/Linux ++ # with ELF format using uClibc ++ tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h linux.h i386/linux.h" ++ tmake_file="t-slibgcc-elf-ver t-linux-uclibc i386/t-crtstuff" ++ ;; + i[34567]86-*-linux*) # Intel 80386's running GNU/Linux + # with ELF format using glibc 2 + # aka GNU/Linux C library 6 +@@ -1547,6 +1562,16 @@ + gnu_ld=yes + gas=yes + ;; ++mips*-*-linux-uclibc*) # Linux MIPS, either endian. uClibc ++ tm_file="dbxelf.h elfos.h svr4.h linux.h ${tm_file} mips/linux.h" ++ case ${target} in ++ mipsisa32*-*) ++ target_cpu_default="MASK_SOFT_FLOAT" ++ tm_defines="MIPS_ISA_DEFAULT=32" ++ ;; ++ esac ++ tmake_file="t-slibgcc-elf-ver t-linux-uclibc" ++ ;; + mips*-*-linux*) # Linux MIPS, either endian. + tm_file="dbxelf.h elfos.h svr4.h linux.h ${tm_file} mips/linux.h" + case ${target} in +@@ -1764,6 +1789,10 @@ + tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h rs6000/linuxspe.h" + tmake_file="rs6000/t-fprules rs6000/t-ppcos t-slibgcc-elf-ver t-linux rs6000/t-ppccomm" + ;; ++powerpc-*-linux-uclibc*) ++ tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h" ++ tmake_file="rs6000/t-fprules rs6000/t-ppcos t-slibgcc-elf-ver t-linux-uclibc rs6000/t-ppccomm" ++ ;; + powerpc-*-linux*) + tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h" + tmake_file="rs6000/t-fprules rs6000/t-ppcos t-slibgcc-elf-ver t-linux rs6000/t-ppccomm" +@@ -1916,7 +1945,7 @@ + tm_file="${tm_file} dbxelf.h elfos.h svr4.h sh/elf.h sh/embed-elf.h sh/rtemself.h rtems.h" + ;; + sh-*-linux* | sh[2346lbe]*-*-linux*) +- tmake_file="sh/t-sh sh/t-elf t-slibgcc-elf-ver t-linux" ++ tmake_file="sh/t-sh sh/t-elf t-slibgcc-elf-ver" + case ${target} in + sh*be-*-* | sh*eb-*-*) ;; + *) +@@ -1924,9 +1953,17 @@ + tmake_file="${tmake_file} sh/t-le" + ;; + esac +- tmake_file="${tmake_file} sh/t-linux" ++ case ${target} in ++ *-*-linux-uclibc*) tmake_file="${tmake_file} t-linux-uclibc sh/t-linux-uclibc" ;; ++ *) tmake_file="${tmake_file} t-linux sh/t-linux" ;; ++ esac + tm_file="${tm_file} dbxelf.h elfos.h svr4.h sh/elf.h sh/linux.h" + case ${target} in ++ sh64*-*-linux-uclibc*) ++ tmake_file="${tmake_file} sh/t-sh64-uclibc" ++ tm_file="${tm_file} sh/sh64.h" ++ extra_headers="shmedia.h ushmedia.h sshmedia.h" ++ ;; + sh64*) + tmake_file="${tmake_file} sh/t-sh64" + tm_file="${tm_file} sh/sh64.h" +diff -urN gcc-3.4.1-dist/libtool.m4 gcc-3.4.1/libtool.m4 +--- gcc-3.4.1-dist/libtool.m4 2004-05-18 04:08:37.000000000 -0500 ++++ gcc-3.4.1/libtool.m4 2004-08-12 15:54:43.000000000 -0500 +@@ -689,6 +689,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + [lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'] +diff -urN gcc-3.4.1-dist/ltconfig gcc-3.4.1/ltconfig +--- gcc-3.4.1-dist/ltconfig 2004-03-05 15:05:41.000000000 -0600 ++++ gcc-3.4.1/ltconfig 2004-08-12 15:55:48.000000000 -0500 +@@ -602,6 +602,7 @@ + + # Transform linux* to *-*-linux-gnu*, to support old configure scripts. + case $host_os in ++linux-uclibc*) ;; + linux-gnu*) ;; + linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'` + esac +@@ -1262,6 +1263,24 @@ + dynamic_linker='GNU/Linux ld.so' + ;; + ++linux-uclibc*) ++ version_type=linux ++ need_lib_prefix=no ++ need_version=no ++ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' ++ soname_spec='${libname}${release}.so$major' ++ finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' ++ shlibpath_var=LD_LIBRARY_PATH ++ shlibpath_overrides_runpath=no ++ # This implies no fast_install, which is unacceptable. ++ # Some rework will be needed to allow for fast_install ++ # before this can be enabled. ++ # Note: copied from linux-gnu, and may not be appropriate. ++ hardcode_into_libs=yes ++ # Assume using the uClibc dynamic linker. ++ dynamic_linker="uClibc ld.so" ++ ;; ++ + netbsd*) + need_lib_prefix=no + need_version=no diff --git a/meta/packages/gcc/gcc-3.4.4/gcc-3.4.1-uclibc-200-locale.patch b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.1-uclibc-200-locale.patch new file mode 100644 index 000000000..3fc4900b0 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc-3.4.1-uclibc-200-locale.patch @@ -0,0 +1,3246 @@ +diff -urN gcc-3.4.2-dist/libstdc++-v3/acinclude.m4 gcc-3.4.2/libstdc++-v3/acinclude.m4 +--- gcc-3.4.2-dist/libstdc++-v3/acinclude.m4 2004-07-15 12:42:45.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/acinclude.m4 2004-09-10 10:47:40.000000000 -0500 +@@ -996,7 +996,7 @@ + AC_MSG_CHECKING([for C locale to use]) + GLIBCXX_ENABLE(clocale,auto,[@<:@=MODEL@:>@], + [use MODEL for target locale package], +- [permit generic|gnu|ieee_1003.1-2001|yes|no|auto]) ++ [permit generic|gnu|ieee_1003.1-2001|uclibc|yes|no|auto]) + + # If they didn't use this option switch, or if they specified --enable + # with no specific model, we'll have to look for one. If they +@@ -1012,6 +1012,9 @@ + # Default to "generic". + if test $enable_clocale_flag = auto; then + case x${target_os} in ++ x*-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + xlinux* | xgnu* | xkfreebsd*-gnu | xknetbsd*-gnu) + AC_EGREP_CPP([_GLIBCXX_ok], [ + #include +@@ -1138,6 +1141,41 @@ + CTIME_CC=config/locale/generic/time_members.cc + CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h + ;; ++ uclibc) ++ AC_MSG_RESULT(uclibc) ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ AC_CHECK_PROG(check_msgfmt, msgfmt, yes, no) ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcxx_MOFILES="$glibcxx_MOFILES $ling.mo"; \ ++ glibcxx_POFILES="$glibcxx_POFILES $ling.po"; \ ++ done ++ AC_SUBST(glibcxx_MOFILES) ++ AC_SUBST(glibcxx_POFILES) ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_H=config/locale/ieee_1003.1-2001/codecvt_specializations.h ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + esac + + # This is where the testsuite looks for locale catalogs, using the +diff -urN gcc-3.4.2-dist/libstdc++-v3/aclocal.m4 gcc-3.4.2/libstdc++-v3/aclocal.m4 +--- gcc-3.4.2-dist/libstdc++-v3/aclocal.m4 2004-08-13 15:44:03.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/aclocal.m4 2004-09-10 10:47:40.000000000 -0500 +@@ -1025,6 +1025,9 @@ + # Default to "generic". + if test $enable_clocale_flag = auto; then + case x${target_os} in ++ x*-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + xlinux* | xgnu* | xkfreebsd*-gnu | xknetbsd*-gnu) + AC_EGREP_CPP([_GLIBCXX_ok], [ + #include +@@ -1151,6 +1154,41 @@ + CTIME_CC=config/locale/generic/time_members.cc + CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h + ;; ++ uclibc) ++ AC_MSG_RESULT(uclibc) ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ AC_CHECK_PROG(check_msgfmt, msgfmt, yes, no) ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcxx_MOFILES="$glibcxx_MOFILES $ling.mo"; \ ++ glibcxx_POFILES="$glibcxx_POFILES $ling.po"; \ ++ done ++ AC_SUBST(glibcxx_MOFILES) ++ AC_SUBST(glibcxx_POFILES) ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_H=config/locale/ieee_1003.1-2001/codecvt_specializations.h ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + esac + + # This is where the testsuite looks for locale catalogs, using the +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c++locale_internal.h gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c++locale_internal.h +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c++locale_internal.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c++locale_internal.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,59 @@ ++// Prototypes for GLIBC thread locale __-prefixed functions -*- C++ -*- ++ ++// Copyright (C) 2002, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// Written by Jakub Jelinek ++ ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning clean this up ++#endif ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ ++extern "C" __typeof(iswctype_l) __iswctype_l; ++extern "C" __typeof(nl_langinfo_l) __nl_langinfo_l; ++extern "C" __typeof(strcoll_l) __strcoll_l; ++extern "C" __typeof(strftime_l) __strftime_l; ++extern "C" __typeof(strtod_l) __strtod_l; ++extern "C" __typeof(strtof_l) __strtof_l; ++extern "C" __typeof(strtold_l) __strtold_l; ++extern "C" __typeof(strxfrm_l) __strxfrm_l; ++extern "C" __typeof(towlower_l) __towlower_l; ++extern "C" __typeof(towupper_l) __towupper_l; ++extern "C" __typeof(wcscoll_l) __wcscoll_l; ++extern "C" __typeof(wcsftime_l) __wcsftime_l; ++extern "C" __typeof(wcsxfrm_l) __wcsxfrm_l; ++extern "C" __typeof(wctype_l) __wctype_l; ++extern "C" __typeof(newlocale) __newlocale; ++extern "C" __typeof(freelocale) __freelocale; ++extern "C" __typeof(duplocale) __duplocale; ++extern "C" __typeof(uselocale) __uselocale; ++ ++#endif // GLIBC 2.3 and later +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c_locale.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c_locale.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c_locale.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c_locale.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,160 @@ ++// Wrapper for underlying C-language localization -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.8 Standard locale categories. ++// ++ ++// Written by Benjamin Kosnik ++ ++#include // For errno ++#include ++#include ++#include ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __strtol_l(S, E, B, L) strtol((S), (E), (B)) ++#define __strtoul_l(S, E, B, L) strtoul((S), (E), (B)) ++#define __strtoll_l(S, E, B, L) strtoll((S), (E), (B)) ++#define __strtoull_l(S, E, B, L) strtoull((S), (E), (B)) ++#define __strtof_l(S, E, L) strtof((S), (E)) ++#define __strtod_l(S, E, L) strtod((S), (E)) ++#define __strtold_l(S, E, L) strtold((S), (E)) ++#warning should dummy __newlocale check for C|POSIX ? ++#define __newlocale(a, b, c) NULL ++#define __freelocale(a) ((void)0) ++#define __duplocale(a) __c_locale() ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ __convert_to_v(const char* __s, float& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ float __f = __strtof_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && errno != ERANGE) ++ __v = __f; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, double& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ double __d = __strtod_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && errno != ERANGE) ++ __v = __d; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, long double& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ long double __ld = __strtold_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && errno != ERANGE) ++ __v = __ld; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ void ++ locale::facet::_S_create_c_locale(__c_locale& __cloc, const char* __s, ++ __c_locale __old) ++ { ++ __cloc = __newlocale(1 << LC_ALL, __s, __old); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ if (!__cloc) ++ { ++ // This named locale is not supported by the underlying OS. ++ __throw_runtime_error(__N("locale::facet::_S_create_c_locale " ++ "name not valid")); ++ } ++#endif ++ } ++ ++ void ++ locale::facet::_S_destroy_c_locale(__c_locale& __cloc) ++ { ++ if (_S_get_c_locale() != __cloc) ++ __freelocale(__cloc); ++ } ++ ++ __c_locale ++ locale::facet::_S_clone_c_locale(__c_locale& __cloc) ++ { return __duplocale(__cloc); } ++} // namespace std ++ ++namespace __gnu_cxx ++{ ++ const char* const category_names[6 + _GLIBCXX_NUM_CATEGORIES] = ++ { ++ "LC_CTYPE", ++ "LC_NUMERIC", ++ "LC_TIME", ++ "LC_COLLATE", ++ "LC_MONETARY", ++ "LC_MESSAGES", ++#if _GLIBCXX_NUM_CATEGORIES != 0 ++ "LC_PAPER", ++ "LC_NAME", ++ "LC_ADDRESS", ++ "LC_TELEPHONE", ++ "LC_MEASUREMENT", ++ "LC_IDENTIFICATION" ++#endif ++ }; ++} ++ ++namespace std ++{ ++ const char* const* const locale::_S_categories = __gnu_cxx::category_names; ++} // namespace std +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c_locale.h gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c_locale.h +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/c_locale.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/c_locale.h 2004-09-10 10:48:08.000000000 -0500 +@@ -0,0 +1,115 @@ ++// Wrapper for underlying C-language localization -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.8 Standard locale categories. ++// ++ ++// Written by Benjamin Kosnik ++ ++#ifndef _C_LOCALE_H ++#define _C_LOCALE_H 1 ++ ++#pragma GCC system_header ++ ++#include // get std::strlen ++#include // get std::snprintf or std::sprintf ++#include ++#include // For codecvt ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC_HAS_LOCALE__ ++#include // For codecvt using iconv, iconv_t ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++#include // For messages ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning what is _GLIBCXX_C_LOCALE_GNU for ++#endif ++#define _GLIBCXX_C_LOCALE_GNU 1 ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix categories ++#endif ++// #define _GLIBCXX_NUM_CATEGORIES 6 ++#define _GLIBCXX_NUM_CATEGORIES 0 ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++namespace __gnu_cxx ++{ ++ extern "C" __typeof(uselocale) __uselocale; ++} ++#endif ++ ++namespace std ++{ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ typedef __locale_t __c_locale; ++#else ++ typedef int* __c_locale; ++#endif ++ ++ // Convert numeric value of type _Tv to string and return length of ++ // string. If snprintf is available use it, otherwise fall back to ++ // the unsafe sprintf which, in general, can be dangerous and should ++ // be avoided. ++ template ++ int ++ __convert_from_v(char* __out, const int __size, const char* __fmt, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ _Tv __v, const __c_locale& __cloc, int __prec) ++ { ++ __c_locale __old = __gnu_cxx::__uselocale(__cloc); ++#else ++ _Tv __v, const __c_locale&, int __prec) ++ { ++# ifdef __UCLIBC_HAS_LOCALE__ ++ char* __old = std::setlocale(LC_ALL, NULL); ++ char* __sav = new char[std::strlen(__old) + 1]; ++ std::strcpy(__sav, __old); ++ std::setlocale(LC_ALL, "C"); ++# endif ++#endif ++ ++ const int __ret = std::snprintf(__out, __size, __fmt, __prec, __v); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __gnu_cxx::__uselocale(__old); ++#elif defined __UCLIBC_HAS_LOCALE__ ++ std::setlocale(LC_ALL, __sav); ++ delete [] __sav; ++#endif ++ return __ret; ++ } ++} ++ ++#endif +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/codecvt_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/codecvt_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/codecvt_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/codecvt_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,306 @@ ++// std::codecvt implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.1.5 - Template class codecvt ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++namespace std ++{ ++ // Specializations. ++#ifdef _GLIBCXX_USE_WCHAR_T ++ codecvt_base::result ++ codecvt:: ++ do_out(state_type& __state, const intern_type* __from, ++ const intern_type* __from_end, const intern_type*& __from_next, ++ extern_type* __to, extern_type* __to_end, ++ extern_type*& __to_next) const ++ { ++ result __ret = ok; ++ state_type __tmp_state(__state); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ ++ // wcsnrtombs is *very* fast but stops if encounters NUL characters: ++ // in case we fall back to wcrtomb and then continue, in a loop. ++ // NB: wcsnrtombs is a GNU extension ++ for (__from_next = __from, __to_next = __to; ++ __from_next < __from_end && __to_next < __to_end ++ && __ret == ok;) ++ { ++ const intern_type* __from_chunk_end = wmemchr(__from_next, L'\0', ++ __from_end - __from_next); ++ if (!__from_chunk_end) ++ __from_chunk_end = __from_end; ++ ++ __from = __from_next; ++ const size_t __conv = wcsnrtombs(__to_next, &__from_next, ++ __from_chunk_end - __from_next, ++ __to_end - __to_next, &__state); ++ if (__conv == static_cast(-1)) ++ { ++ // In case of error, in order to stop at the exact place we ++ // have to start again from the beginning with a series of ++ // wcrtomb. ++ for (; __from < __from_next; ++__from) ++ __to_next += wcrtomb(__to_next, *__from, &__tmp_state); ++ __state = __tmp_state; ++ __ret = error; ++ } ++ else if (__from_next && __from_next < __from_chunk_end) ++ { ++ __to_next += __conv; ++ __ret = partial; ++ } ++ else ++ { ++ __from_next = __from_chunk_end; ++ __to_next += __conv; ++ } ++ ++ if (__from_next < __from_end && __ret == ok) ++ { ++ extern_type __buf[MB_LEN_MAX]; ++ __tmp_state = __state; ++ const size_t __conv = wcrtomb(__buf, *__from_next, &__tmp_state); ++ if (__conv > static_cast(__to_end - __to_next)) ++ __ret = partial; ++ else ++ { ++ memcpy(__to_next, __buf, __conv); ++ __state = __tmp_state; ++ __to_next += __conv; ++ ++__from_next; ++ } ++ } ++ } ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ return __ret; ++ } ++ ++ codecvt_base::result ++ codecvt:: ++ do_in(state_type& __state, const extern_type* __from, ++ const extern_type* __from_end, const extern_type*& __from_next, ++ intern_type* __to, intern_type* __to_end, ++ intern_type*& __to_next) const ++ { ++ result __ret = ok; ++ state_type __tmp_state(__state); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ ++ // mbsnrtowcs is *very* fast but stops if encounters NUL characters: ++ // in case we store a L'\0' and then continue, in a loop. ++ // NB: mbsnrtowcs is a GNU extension ++ for (__from_next = __from, __to_next = __to; ++ __from_next < __from_end && __to_next < __to_end ++ && __ret == ok;) ++ { ++ const extern_type* __from_chunk_end; ++ __from_chunk_end = static_cast(memchr(__from_next, '\0', ++ __from_end ++ - __from_next)); ++ if (!__from_chunk_end) ++ __from_chunk_end = __from_end; ++ ++ __from = __from_next; ++ size_t __conv = mbsnrtowcs(__to_next, &__from_next, ++ __from_chunk_end - __from_next, ++ __to_end - __to_next, &__state); ++ if (__conv == static_cast(-1)) ++ { ++ // In case of error, in order to stop at the exact place we ++ // have to start again from the beginning with a series of ++ // mbrtowc. ++ for (;; ++__to_next, __from += __conv) ++ { ++ __conv = mbrtowc(__to_next, __from, __from_end - __from, ++ &__tmp_state); ++ if (__conv == static_cast(-1) ++ || __conv == static_cast(-2)) ++ break; ++ } ++ __from_next = __from; ++ __state = __tmp_state; ++ __ret = error; ++ } ++ else if (__from_next && __from_next < __from_chunk_end) ++ { ++ // It is unclear what to return in this case (see DR 382). ++ __to_next += __conv; ++ __ret = partial; ++ } ++ else ++ { ++ __from_next = __from_chunk_end; ++ __to_next += __conv; ++ } ++ ++ if (__from_next < __from_end && __ret == ok) ++ { ++ if (__to_next < __to_end) ++ { ++ // XXX Probably wrong for stateful encodings ++ __tmp_state = __state; ++ ++__from_next; ++ *__to_next++ = L'\0'; ++ } ++ else ++ __ret = partial; ++ } ++ } ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ return __ret; ++ } ++ ++ int ++ codecvt:: ++ do_encoding() const throw() ++ { ++ // XXX This implementation assumes that the encoding is ++ // stateless and is either single-byte or variable-width. ++ int __ret = 0; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ if (MB_CUR_MAX == 1) ++ __ret = 1; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __ret; ++ } ++ ++ int ++ codecvt:: ++ do_max_length() const throw() ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ // XXX Probably wrong for stateful encodings. ++ int __ret = MB_CUR_MAX; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __ret; ++ } ++ ++ int ++ codecvt:: ++ do_length(state_type& __state, const extern_type* __from, ++ const extern_type* __end, size_t __max) const ++ { ++ int __ret = 0; ++ state_type __tmp_state(__state); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ ++ // mbsnrtowcs is *very* fast but stops if encounters NUL characters: ++ // in case we advance past it and then continue, in a loop. ++ // NB: mbsnrtowcs is a GNU extension ++ ++ // A dummy internal buffer is needed in order for mbsnrtocws to consider ++ // its fourth parameter (it wouldn't with NULL as first parameter). ++ wchar_t* __to = static_cast(__builtin_alloca(sizeof(wchar_t) ++ * __max)); ++ while (__from < __end && __max) ++ { ++ const extern_type* __from_chunk_end; ++ __from_chunk_end = static_cast(memchr(__from, '\0', ++ __end ++ - __from)); ++ if (!__from_chunk_end) ++ __from_chunk_end = __end; ++ ++ const extern_type* __tmp_from = __from; ++ size_t __conv = mbsnrtowcs(__to, &__from, ++ __from_chunk_end - __from, ++ __max, &__state); ++ if (__conv == static_cast(-1)) ++ { ++ // In case of error, in order to stop at the exact place we ++ // have to start again from the beginning with a series of ++ // mbrtowc. ++ for (__from = __tmp_from;; __from += __conv) ++ { ++ __conv = mbrtowc(NULL, __from, __end - __from, ++ &__tmp_state); ++ if (__conv == static_cast(-1) ++ || __conv == static_cast(-2)) ++ break; ++ } ++ __state = __tmp_state; ++ __ret += __from - __tmp_from; ++ break; ++ } ++ if (!__from) ++ __from = __from_chunk_end; ++ ++ __ret += __from - __tmp_from; ++ __max -= __conv; ++ ++ if (__from < __end && __max) ++ { ++ // XXX Probably wrong for stateful encodings ++ __tmp_state = __state; ++ ++__from; ++ ++__ret; ++ --__max; ++ } ++ } ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ return __ret; ++ } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/collate_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/collate_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/collate_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/collate_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,80 @@ ++// std::collate implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.4.1.2 collate virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __strcoll_l(S1, S2, L) strcoll((S1), (S2)) ++#define __strxfrm_l(S1, S2, N, L) strxfrm((S1), (S2), (N)) ++#define __wcscoll_l(S1, S2, L) wcscoll((S1), (S2)) ++#define __wcsxfrm_l(S1, S2, N, L) wcsxfrm((S1), (S2), (N)) ++#endif ++ ++namespace std ++{ ++ // These are basically extensions to char_traits, and perhaps should ++ // be put there instead of here. ++ template<> ++ int ++ collate::_M_compare(const char* __one, const char* __two) const ++ { ++ int __cmp = __strcoll_l(__one, __two, _M_c_locale_collate); ++ return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0); ++ } ++ ++ template<> ++ size_t ++ collate::_M_transform(char* __to, const char* __from, ++ size_t __n) const ++ { return __strxfrm_l(__to, __from, __n, _M_c_locale_collate); } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ int ++ collate::_M_compare(const wchar_t* __one, ++ const wchar_t* __two) const ++ { ++ int __cmp = __wcscoll_l(__one, __two, _M_c_locale_collate); ++ return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0); ++ } ++ ++ template<> ++ size_t ++ collate::_M_transform(wchar_t* __to, const wchar_t* __from, ++ size_t __n) const ++ { return __wcsxfrm_l(__to, __from, __n, _M_c_locale_collate); } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/ctype_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/ctype_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/ctype_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/ctype_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,300 @@ ++// std::ctype implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.1.1.2 ctype virtual functions. ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __wctype_l(S, L) wctype((S)) ++#define __towupper_l(C, L) towupper((C)) ++#define __towlower_l(C, L) towlower((C)) ++#define __iswctype_l(C, M, L) iswctype((C), (M)) ++#endif ++ ++namespace std ++{ ++ // NB: The other ctype specializations are in src/locale.cc and ++ // various /config/os/* files. ++ template<> ++ ctype_byname::ctype_byname(const char* __s, size_t __refs) ++ : ctype(0, false, __refs) ++ { ++ if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0) ++ { ++ this->_S_destroy_c_locale(this->_M_c_locale_ctype); ++ this->_S_create_c_locale(this->_M_c_locale_ctype, __s); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ this->_M_toupper = this->_M_c_locale_ctype->__ctype_toupper; ++ this->_M_tolower = this->_M_c_locale_ctype->__ctype_tolower; ++ this->_M_table = this->_M_c_locale_ctype->__ctype_b; ++#endif ++ } ++ } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ ctype::__wmask_type ++ ctype::_M_convert_to_wmask(const mask __m) const ++ { ++ __wmask_type __ret; ++ switch (__m) ++ { ++ case space: ++ __ret = __wctype_l("space", _M_c_locale_ctype); ++ break; ++ case print: ++ __ret = __wctype_l("print", _M_c_locale_ctype); ++ break; ++ case cntrl: ++ __ret = __wctype_l("cntrl", _M_c_locale_ctype); ++ break; ++ case upper: ++ __ret = __wctype_l("upper", _M_c_locale_ctype); ++ break; ++ case lower: ++ __ret = __wctype_l("lower", _M_c_locale_ctype); ++ break; ++ case alpha: ++ __ret = __wctype_l("alpha", _M_c_locale_ctype); ++ break; ++ case digit: ++ __ret = __wctype_l("digit", _M_c_locale_ctype); ++ break; ++ case punct: ++ __ret = __wctype_l("punct", _M_c_locale_ctype); ++ break; ++ case xdigit: ++ __ret = __wctype_l("xdigit", _M_c_locale_ctype); ++ break; ++ case alnum: ++ __ret = __wctype_l("alnum", _M_c_locale_ctype); ++ break; ++ case graph: ++ __ret = __wctype_l("graph", _M_c_locale_ctype); ++ break; ++ default: ++ __ret = 0; ++ } ++ return __ret; ++ } ++ ++ wchar_t ++ ctype::do_toupper(wchar_t __c) const ++ { return __towupper_l(__c, _M_c_locale_ctype); } ++ ++ const wchar_t* ++ ctype::do_toupper(wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi) ++ { ++ *__lo = __towupper_l(*__lo, _M_c_locale_ctype); ++ ++__lo; ++ } ++ return __hi; ++ } ++ ++ wchar_t ++ ctype::do_tolower(wchar_t __c) const ++ { return __towlower_l(__c, _M_c_locale_ctype); } ++ ++ const wchar_t* ++ ctype::do_tolower(wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi) ++ { ++ *__lo = __towlower_l(*__lo, _M_c_locale_ctype); ++ ++__lo; ++ } ++ return __hi; ++ } ++ ++ bool ++ ctype:: ++ do_is(mask __m, wchar_t __c) const ++ { ++ // Highest bitmask in ctype_base == 10, but extra in "C" ++ // library for blank. ++ bool __ret = false; ++ const size_t __bitmasksize = 11; ++ for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur) ++ if (__m & _M_bit[__bitcur] ++ && __iswctype_l(__c, _M_wmask[__bitcur], _M_c_locale_ctype)) ++ { ++ __ret = true; ++ break; ++ } ++ return __ret; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_is(const wchar_t* __lo, const wchar_t* __hi, mask* __vec) const ++ { ++ for (; __lo < __hi; ++__vec, ++__lo) ++ { ++ // Highest bitmask in ctype_base == 10, but extra in "C" ++ // library for blank. ++ const size_t __bitmasksize = 11; ++ mask __m = 0; ++ for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur) ++ if (__iswctype_l(*__lo, _M_wmask[__bitcur], _M_c_locale_ctype)) ++ __m |= _M_bit[__bitcur]; ++ *__vec = __m; ++ } ++ return __hi; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_scan_is(mask __m, const wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi && !this->do_is(__m, *__lo)) ++ ++__lo; ++ return __lo; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_scan_not(mask __m, const char_type* __lo, const char_type* __hi) const ++ { ++ while (__lo < __hi && this->do_is(__m, *__lo) != 0) ++ ++__lo; ++ return __lo; ++ } ++ ++ wchar_t ++ ctype:: ++ do_widen(char __c) const ++ { return _M_widen[static_cast(__c)]; } ++ ++ const char* ++ ctype:: ++ do_widen(const char* __lo, const char* __hi, wchar_t* __dest) const ++ { ++ while (__lo < __hi) ++ { ++ *__dest = _M_widen[static_cast(*__lo)]; ++ ++__lo; ++ ++__dest; ++ } ++ return __hi; ++ } ++ ++ char ++ ctype:: ++ do_narrow(wchar_t __wc, char __dfault) const ++ { ++ if (__wc >= 0 && __wc < 128 && _M_narrow_ok) ++ return _M_narrow[__wc]; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ const int __c = wctob(__wc); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return (__c == EOF ? __dfault : static_cast(__c)); ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault, ++ char* __dest) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ if (_M_narrow_ok) ++ while (__lo < __hi) ++ { ++ if (*__lo >= 0 && *__lo < 128) ++ *__dest = _M_narrow[*__lo]; ++ else ++ { ++ const int __c = wctob(*__lo); ++ *__dest = (__c == EOF ? __dfault : static_cast(__c)); ++ } ++ ++__lo; ++ ++__dest; ++ } ++ else ++ while (__lo < __hi) ++ { ++ const int __c = wctob(*__lo); ++ *__dest = (__c == EOF ? __dfault : static_cast(__c)); ++ ++__lo; ++ ++__dest; ++ } ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __hi; ++ } ++ ++ void ++ ctype::_M_initialize_ctype() ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ wint_t __i; ++ for (__i = 0; __i < 128; ++__i) ++ { ++ const int __c = wctob(__i); ++ if (__c == EOF) ++ break; ++ else ++ _M_narrow[__i] = static_cast(__c); ++ } ++ if (__i == 128) ++ _M_narrow_ok = true; ++ else ++ _M_narrow_ok = false; ++ for (size_t __j = 0; ++ __j < sizeof(_M_widen) / sizeof(wint_t); ++__j) ++ _M_widen[__j] = btowc(__j); ++ ++ for (size_t __k = 0; __k <= 11; ++__k) ++ { ++ _M_bit[__k] = static_cast(_ISbit(__k)); ++ _M_wmask[__k] = _M_convert_to_wmask(_M_bit[__k]); ++ } ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ } ++#endif // _GLIBCXX_USE_WCHAR_T ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/messages_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/messages_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/messages_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/messages_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,100 @@ ++// std::messages implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.7.1.2 messages virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix gettext stuff ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++extern "C" char *__dcgettext(const char *domainname, ++ const char *msgid, int category); ++#undef gettext ++#define gettext(msgid) __dcgettext(NULL, msgid, LC_MESSAGES) ++#else ++#undef gettext ++#define gettext(msgid) (msgid) ++#endif ++ ++namespace std ++{ ++ // Specializations. ++ template<> ++ string ++ messages::do_get(catalog, int, int, const string& __dfault) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_messages); ++ const char* __msg = const_cast(gettext(__dfault.c_str())); ++ __uselocale(__old); ++ return string(__msg); ++#elif defined __UCLIBC_HAS_LOCALE__ ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_messages); ++ const char* __msg = gettext(__dfault.c_str()); ++ setlocale(LC_ALL, __old); ++ free(__old); ++ return string(__msg); ++#else ++ const char* __msg = gettext(__dfault.c_str()); ++ return string(__msg); ++#endif ++ } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ wstring ++ messages::do_get(catalog, int, int, const wstring& __dfault) const ++ { ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_messages); ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ __uselocale(__old); ++ return _M_convert_from_char(__msg); ++# elif defined __UCLIBC_HAS_LOCALE__ ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_messages); ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ setlocale(LC_ALL, __old); ++ free(__old); ++ return _M_convert_from_char(__msg); ++# else ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ return _M_convert_from_char(__msg); ++# endif ++ } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/messages_members.h gcc-3.4.2/libstdc++-v3/config/locale/uclibc/messages_members.h +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/messages_members.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/messages_members.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,118 @@ ++// std::messages implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.7.1.2 messages functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix prototypes for *textdomain funcs ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++extern "C" char *__textdomain(const char *domainname); ++extern "C" char *__bindtextdomain(const char *domainname, ++ const char *dirname); ++#else ++#undef __textdomain ++#undef __bindtextdomain ++#define __textdomain(D) ((void)0) ++#define __bindtextdomain(D,P) ((void)0) ++#endif ++ ++ // Non-virtual member functions. ++ template ++ messages<_CharT>::messages(size_t __refs) ++ : facet(__refs), _M_c_locale_messages(_S_get_c_locale()), ++ _M_name_messages(_S_get_c_name()) ++ { } ++ ++ template ++ messages<_CharT>::messages(__c_locale __cloc, const char* __s, ++ size_t __refs) ++ : facet(__refs), _M_c_locale_messages(_S_clone_c_locale(__cloc)), ++ _M_name_messages(__s) ++ { ++ char* __tmp = new char[std::strlen(__s) + 1]; ++ std::strcpy(__tmp, __s); ++ _M_name_messages = __tmp; ++ } ++ ++ template ++ typename messages<_CharT>::catalog ++ messages<_CharT>::open(const basic_string& __s, const locale& __loc, ++ const char* __dir) const ++ { ++ __bindtextdomain(__s.c_str(), __dir); ++ return this->do_open(__s, __loc); ++ } ++ ++ // Virtual member functions. ++ template ++ messages<_CharT>::~messages() ++ { ++ if (_M_name_messages != _S_get_c_name()) ++ delete [] _M_name_messages; ++ _S_destroy_c_locale(_M_c_locale_messages); ++ } ++ ++ template ++ typename messages<_CharT>::catalog ++ messages<_CharT>::do_open(const basic_string& __s, ++ const locale&) const ++ { ++ // No error checking is done, assume the catalog exists and can ++ // be used. ++ __textdomain(__s.c_str()); ++ return 0; ++ } ++ ++ template ++ void ++ messages<_CharT>::do_close(catalog) const ++ { } ++ ++ // messages_byname ++ template ++ messages_byname<_CharT>::messages_byname(const char* __s, size_t __refs) ++ : messages<_CharT>(__refs) ++ { ++ if (this->_M_name_messages != locale::facet::_S_get_c_name()) ++ delete [] this->_M_name_messages; ++ char* __tmp = new char[std::strlen(__s) + 1]; ++ std::strcpy(__tmp, __s); ++ this->_M_name_messages = __tmp; ++ ++ if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0) ++ { ++ this->_S_destroy_c_locale(this->_M_c_locale_messages); ++ this->_S_create_c_locale(this->_M_c_locale_messages, __s); ++ } ++ } +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/monetary_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/monetary_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/monetary_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/monetary_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,698 @@ ++// std::moneypunct implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.6.3.2 moneypunct virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning optimize this for uclibc ++#warning tailor for stub locale support ++#endif ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ // Construct and return valid pattern consisting of some combination of: ++ // space none symbol sign value ++ money_base::pattern ++ money_base::_S_construct_pattern(char __precedes, char __space, char __posn) ++ { ++ pattern __ret; ++ ++ // This insanely complicated routine attempts to construct a valid ++ // pattern for use with monyepunct. A couple of invariants: ++ ++ // if (__precedes) symbol -> value ++ // else value -> symbol ++ ++ // if (__space) space ++ // else none ++ ++ // none == never first ++ // space never first or last ++ ++ // Any elegant implementations of this are welcome. ++ switch (__posn) ++ { ++ case 0: ++ case 1: ++ // 1 The sign precedes the value and symbol. ++ __ret.field[0] = sign; ++ if (__space) ++ { ++ // Pattern starts with sign. ++ if (__precedes) ++ { ++ __ret.field[1] = symbol; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[1] = value; ++ __ret.field[3] = symbol; ++ } ++ __ret.field[2] = space; ++ } ++ else ++ { ++ // Pattern starts with sign and ends with none. ++ if (__precedes) ++ { ++ __ret.field[1] = symbol; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[1] = value; ++ __ret.field[2] = symbol; ++ } ++ __ret.field[3] = none; ++ } ++ break; ++ case 2: ++ // 2 The sign follows the value and symbol. ++ if (__space) ++ { ++ // Pattern either ends with sign. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[2] = symbol; ++ } ++ __ret.field[1] = space; ++ __ret.field[3] = sign; ++ } ++ else ++ { ++ // Pattern ends with sign then none. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[1] = symbol; ++ } ++ __ret.field[2] = sign; ++ __ret.field[3] = none; ++ } ++ break; ++ case 3: ++ // 3 The sign immediately precedes the symbol. ++ if (__precedes) ++ { ++ __ret.field[0] = sign; ++ __ret.field[1] = symbol; ++ if (__space) ++ { ++ __ret.field[2] = space; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[2] = value; ++ __ret.field[3] = none; ++ } ++ } ++ else ++ { ++ __ret.field[0] = value; ++ if (__space) ++ { ++ __ret.field[1] = space; ++ __ret.field[2] = sign; ++ __ret.field[3] = symbol; ++ } ++ else ++ { ++ __ret.field[1] = sign; ++ __ret.field[2] = symbol; ++ __ret.field[3] = none; ++ } ++ } ++ break; ++ case 4: ++ // 4 The sign immediately follows the symbol. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = sign; ++ if (__space) ++ { ++ __ret.field[2] = space; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[2] = value; ++ __ret.field[3] = none; ++ } ++ } ++ else ++ { ++ __ret.field[0] = value; ++ if (__space) ++ { ++ __ret.field[1] = space; ++ __ret.field[2] = symbol; ++ __ret.field[3] = sign; ++ } ++ else ++ { ++ __ret.field[1] = symbol; ++ __ret.field[2] = sign; ++ __ret.field[3] = none; ++ } ++ } ++ break; ++ default: ++ ; ++ } ++ return __ret; ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++ const char*) ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = '.'; ++ _M_data->_M_thousands_sep = ','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = ""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = ""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = ""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ _M_data->_M_atoms[__i] = money_base::_S_atoms[__i]; ++ } ++ else ++ { ++ // Named locale. ++ _M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT, ++ __cloc)); ++ _M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP, ++ __cloc)); ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ _M_data->_M_positive_sign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ _M_data->_M_positive_sign_size = strlen(_M_data->_M_positive_sign); ++ ++ char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc)); ++ if (!__nposn) ++ _M_data->_M_negative_sign = "()"; ++ else ++ _M_data->_M_negative_sign = __nl_langinfo_l(__NEGATIVE_SIGN, ++ __cloc); ++ _M_data->_M_negative_sign_size = strlen(_M_data->_M_negative_sign); ++ ++ // _Intl == true ++ _M_data->_M_curr_symbol = __nl_langinfo_l(__INT_CURR_SYMBOL, __cloc); ++ _M_data->_M_curr_symbol_size = strlen(_M_data->_M_curr_symbol); ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS, ++ __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__INT_P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__INT_P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__INT_P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__INT_N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__INT_N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ } ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++ const char*) ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = '.'; ++ _M_data->_M_thousands_sep = ','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = ""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = ""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = ""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ _M_data->_M_atoms[__i] = money_base::_S_atoms[__i]; ++ } ++ else ++ { ++ // Named locale. ++ _M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT, ++ __cloc)); ++ _M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP, ++ __cloc)); ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ _M_data->_M_positive_sign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ _M_data->_M_positive_sign_size = strlen(_M_data->_M_positive_sign); ++ ++ char __nposn = *(__nl_langinfo_l(__N_SIGN_POSN, __cloc)); ++ if (!__nposn) ++ _M_data->_M_negative_sign = "()"; ++ else ++ _M_data->_M_negative_sign = __nl_langinfo_l(__NEGATIVE_SIGN, ++ __cloc); ++ _M_data->_M_negative_sign_size = strlen(_M_data->_M_negative_sign); ++ ++ // _Intl == false ++ _M_data->_M_curr_symbol = __nl_langinfo_l(__CURRENCY_SYMBOL, __cloc); ++ _M_data->_M_curr_symbol_size = strlen(_M_data->_M_curr_symbol); ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ } ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { delete _M_data; } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { delete _M_data; } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const char*) ++#else ++ const char* __name) ++#endif ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = L'.'; ++ _M_data->_M_thousands_sep = L','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ // Use ctype::widen code without the facet... ++ unsigned char uc; ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ { ++ uc = static_cast(money_base::_S_atoms[__i]); ++ _M_data->_M_atoms[__i] = btowc(uc); ++ } ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(__cloc); ++#else ++ // Switch to named locale so that mbsrtowcs will work. ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, __name); ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this... should be monetary ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_data->_M_decimal_point = __cloc->decimal_point_wc; ++ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_data->_M_decimal_point = __global_locale->decimal_point_wc; ++ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ union __s_and_w { const char *__s; unsigned int __w; } __u; ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_DECIMAL_POINT_WC, __cloc); ++ _M_data->_M_decimal_point = static_cast(__u.__w); ++ ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_THOUSANDS_SEP_WC, __cloc); ++ _M_data->_M_thousands_sep = static_cast(__u.__w); ++#endif ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ ++ const char* __cpossign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ const char* __cnegsign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ const char* __ccurr = __nl_langinfo_l(__INT_CURR_SYMBOL, __cloc); ++ ++ wchar_t* __wcs_ps = 0; ++ wchar_t* __wcs_ns = 0; ++ const char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc)); ++ try ++ { ++ mbstate_t __state; ++ size_t __len = strlen(__cpossign); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ps = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ps, &__cpossign, __len, &__state); ++ _M_data->_M_positive_sign = __wcs_ps; ++ } ++ else ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = wcslen(_M_data->_M_positive_sign); ++ ++ __len = strlen(__cnegsign); ++ if (!__nposn) ++ _M_data->_M_negative_sign = L"()"; ++ else if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ns = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ns, &__cnegsign, __len, &__state); ++ _M_data->_M_negative_sign = __wcs_ns; ++ } ++ else ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = wcslen(_M_data->_M_negative_sign); ++ ++ // _Intl == true. ++ __len = strlen(__ccurr); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__ccurr, __len, &__state); ++ _M_data->_M_curr_symbol = __wcs; ++ } ++ else ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = wcslen(_M_data->_M_curr_symbol); ++ } ++ catch (...) ++ { ++ delete _M_data; ++ _M_data = 0; ++ delete __wcs_ps; ++ delete __wcs_ns; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ __throw_exception_again; ++ } ++ ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS, ++ __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__INT_P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__INT_P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__INT_P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__INT_N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__INT_N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const char*) ++#else ++ const char* __name) ++#endif ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = L'.'; ++ _M_data->_M_thousands_sep = L','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ // Use ctype::widen code without the facet... ++ unsigned char uc; ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ { ++ uc = static_cast(money_base::_S_atoms[__i]); ++ _M_data->_M_atoms[__i] = btowc(uc); ++ } ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(__cloc); ++#else ++ // Switch to named locale so that mbsrtowcs will work. ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, __name); ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this... should be monetary ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_data->_M_decimal_point = __cloc->decimal_point_wc; ++ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_data->_M_decimal_point = __global_locale->decimal_point_wc; ++ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ union __s_and_w { const char *__s; unsigned int __w; } __u; ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_DECIMAL_POINT_WC, __cloc); ++ _M_data->_M_decimal_point = static_cast(__u.__w); ++ ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_THOUSANDS_SEP_WC, __cloc); ++ _M_data->_M_thousands_sep = static_cast(__u.__w); ++#endif ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ ++ const char* __cpossign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ const char* __cnegsign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ const char* __ccurr = __nl_langinfo_l(__CURRENCY_SYMBOL, __cloc); ++ ++ wchar_t* __wcs_ps = 0; ++ wchar_t* __wcs_ns = 0; ++ const char __nposn = *(__nl_langinfo_l(__N_SIGN_POSN, __cloc)); ++ try ++ { ++ mbstate_t __state; ++ size_t __len; ++ __len = strlen(__cpossign); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ps = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ps, &__cpossign, __len, &__state); ++ _M_data->_M_positive_sign = __wcs_ps; ++ } ++ else ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = wcslen(_M_data->_M_positive_sign); ++ ++ __len = strlen(__cnegsign); ++ if (!__nposn) ++ _M_data->_M_negative_sign = L"()"; ++ else if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ns = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ns, &__cnegsign, __len, &__state); ++ _M_data->_M_negative_sign = __wcs_ns; ++ } ++ else ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = wcslen(_M_data->_M_negative_sign); ++ ++ // _Intl == true. ++ __len = strlen(__ccurr); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__ccurr, __len, &__state); ++ _M_data->_M_curr_symbol = __wcs; ++ } ++ else ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = wcslen(_M_data->_M_curr_symbol); ++ } ++ catch (...) ++ { ++ delete _M_data; ++ _M_data = 0; ++ delete __wcs_ps; ++ delete __wcs_ns; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ __throw_exception_again; ++ } ++ ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { ++ if (_M_data->_M_positive_sign_size) ++ delete [] _M_data->_M_positive_sign; ++ if (_M_data->_M_negative_sign_size ++ && wcscmp(_M_data->_M_negative_sign, L"()") != 0) ++ delete [] _M_data->_M_negative_sign; ++ if (_M_data->_M_curr_symbol_size) ++ delete [] _M_data->_M_curr_symbol; ++ delete _M_data; ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { ++ if (_M_data->_M_positive_sign_size) ++ delete [] _M_data->_M_positive_sign; ++ if (_M_data->_M_negative_sign_size ++ && wcscmp(_M_data->_M_negative_sign, L"()") != 0) ++ delete [] _M_data->_M_negative_sign; ++ if (_M_data->_M_curr_symbol_size) ++ delete [] _M_data->_M_curr_symbol; ++ delete _M_data; ++ } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/numeric_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/numeric_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/numeric_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/numeric_members.cc 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,183 @@ ++// std::numpunct implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.3.1.2 numpunct virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning tailor for stub locale support ++#endif ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ numpunct::_M_initialize_numpunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __numpunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_use_grouping = false; ++ ++ _M_data->_M_decimal_point = '.'; ++ _M_data->_M_thousands_sep = ','; ++ ++ for (size_t __i = 0; __i < __num_base::_S_oend; ++__i) ++ _M_data->_M_atoms_out[__i] = __num_base::_S_atoms_out[__i]; ++ ++ for (size_t __j = 0; __j < __num_base::_S_iend; ++__j) ++ _M_data->_M_atoms_in[__j] = __num_base::_S_atoms_in[__j]; ++ } ++ else ++ { ++ // Named locale. ++ _M_data->_M_decimal_point = *(__nl_langinfo_l(DECIMAL_POINT, ++ __cloc)); ++ _M_data->_M_thousands_sep = *(__nl_langinfo_l(THOUSANDS_SEP, ++ __cloc)); ++ ++ // Check for NULL, which implies no grouping. ++ if (_M_data->_M_thousands_sep == '\0') ++ _M_data->_M_grouping = ""; ++ else ++ _M_data->_M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ } ++ ++ // NB: There is no way to extact this info from posix locales. ++ // _M_truename = __nl_langinfo_l(YESSTR, __cloc); ++ _M_data->_M_truename = "true"; ++ _M_data->_M_truename_size = strlen(_M_data->_M_truename); ++ // _M_falsename = __nl_langinfo_l(NOSTR, __cloc); ++ _M_data->_M_falsename = "false"; ++ _M_data->_M_falsename_size = strlen(_M_data->_M_falsename); ++ } ++ ++ template<> ++ numpunct::~numpunct() ++ { delete _M_data; } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ void ++ numpunct::_M_initialize_numpunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __numpunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_use_grouping = false; ++ ++ _M_data->_M_decimal_point = L'.'; ++ _M_data->_M_thousands_sep = L','; ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_S_get_c_locale()); ++#endif ++ // Use ctype::widen code without the facet... ++ unsigned char uc; ++ for (size_t __i = 0; __i < __num_base::_S_oend; ++__i) ++ { ++ uc = static_cast(__num_base::_S_atoms_out[__i]); ++ _M_data->_M_atoms_out[__i] = btowc(uc); ++ } ++ ++ for (size_t __j = 0; __j < __num_base::_S_iend; ++__j) ++ { ++ uc = static_cast(__num_base::_S_atoms_in[__j]); ++ _M_data->_M_atoms_in[__j] = btowc(uc); ++ } ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_data->_M_decimal_point = __cloc->decimal_point_wc; ++ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_data->_M_decimal_point = __global_locale->decimal_point_wc; ++ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ union __s_and_w { const char *__s; unsigned int __w; } __u; ++ __u.__s = __nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc); ++ _M_data->_M_decimal_point = static_cast(__u.__w); ++ ++ __u.__s = __nl_langinfo_l(_NL_NUMERIC_THOUSANDS_SEP_WC, __cloc); ++ _M_data->_M_thousands_sep = static_cast(__u.__w); ++#endif ++ ++ if (_M_data->_M_thousands_sep == L'\0') ++ _M_data->_M_grouping = ""; ++ else ++ _M_data->_M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ } ++ ++ // NB: There is no way to extact this info from posix locales. ++ // _M_truename = __nl_langinfo_l(YESSTR, __cloc); ++ _M_data->_M_truename = L"true"; ++ _M_data->_M_truename_size = wcslen(_M_data->_M_truename); ++ // _M_falsename = __nl_langinfo_l(NOSTR, __cloc); ++ _M_data->_M_falsename = L"false"; ++ _M_data->_M_falsename_size = wcslen(_M_data->_M_falsename); ++ } ++ ++ template<> ++ numpunct::~numpunct() ++ { delete _M_data; } ++ #endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/time_members.cc gcc-3.4.2/libstdc++-v3/config/locale/uclibc/time_members.cc +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/time_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/time_members.cc 2004-09-10 10:48:00.000000000 -0500 +@@ -0,0 +1,356 @@ ++// std::time_get, std::time_put implementation, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.5.1.2 - time_get virtual functions ++// ISO C++ 14882: 22.2.5.3.2 - time_put virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning tailor for stub locale support ++#endif ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ __timepunct:: ++ _M_put(char* __s, size_t __maxlen, const char* __format, ++ const tm* __tm) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const size_t __len = __strftime_l(__s, __maxlen, __format, __tm, ++ _M_c_locale_timepunct); ++#else ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_timepunct); ++ const size_t __len = strftime(__s, __maxlen, __format, __tm); ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ // Make sure __s is null terminated. ++ if (__len == 0) ++ __s[0] = '\0'; ++ } ++ ++ template<> ++ void ++ __timepunct::_M_initialize_timepunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __timepunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_c_locale_timepunct = _S_get_c_locale(); ++ ++ _M_data->_M_date_format = "%m/%d/%y"; ++ _M_data->_M_date_era_format = "%m/%d/%y"; ++ _M_data->_M_time_format = "%H:%M:%S"; ++ _M_data->_M_time_era_format = "%H:%M:%S"; ++ _M_data->_M_date_time_format = ""; ++ _M_data->_M_date_time_era_format = ""; ++ _M_data->_M_am = "AM"; ++ _M_data->_M_pm = "PM"; ++ _M_data->_M_am_pm_format = ""; ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = "Sunday"; ++ _M_data->_M_day2 = "Monday"; ++ _M_data->_M_day3 = "Tuesday"; ++ _M_data->_M_day4 = "Wednesday"; ++ _M_data->_M_day5 = "Thursday"; ++ _M_data->_M_day6 = "Friday"; ++ _M_data->_M_day7 = "Saturday"; ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = "Sun"; ++ _M_data->_M_aday2 = "Mon"; ++ _M_data->_M_aday3 = "Tue"; ++ _M_data->_M_aday4 = "Wed"; ++ _M_data->_M_aday5 = "Thu"; ++ _M_data->_M_aday6 = "Fri"; ++ _M_data->_M_aday7 = "Sat"; ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = "January"; ++ _M_data->_M_month02 = "February"; ++ _M_data->_M_month03 = "March"; ++ _M_data->_M_month04 = "April"; ++ _M_data->_M_month05 = "May"; ++ _M_data->_M_month06 = "June"; ++ _M_data->_M_month07 = "July"; ++ _M_data->_M_month08 = "August"; ++ _M_data->_M_month09 = "September"; ++ _M_data->_M_month10 = "October"; ++ _M_data->_M_month11 = "November"; ++ _M_data->_M_month12 = "December"; ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = "Jan"; ++ _M_data->_M_amonth02 = "Feb"; ++ _M_data->_M_amonth03 = "Mar"; ++ _M_data->_M_amonth04 = "Apr"; ++ _M_data->_M_amonth05 = "May"; ++ _M_data->_M_amonth06 = "Jun"; ++ _M_data->_M_amonth07 = "Jul"; ++ _M_data->_M_amonth08 = "Aug"; ++ _M_data->_M_amonth09 = "Sep"; ++ _M_data->_M_amonth10 = "Oct"; ++ _M_data->_M_amonth11 = "Nov"; ++ _M_data->_M_amonth12 = "Dec"; ++ } ++ else ++ { ++ _M_c_locale_timepunct = _S_clone_c_locale(__cloc); ++ ++ _M_data->_M_date_format = __nl_langinfo_l(D_FMT, __cloc); ++ _M_data->_M_date_era_format = __nl_langinfo_l(ERA_D_FMT, __cloc); ++ _M_data->_M_time_format = __nl_langinfo_l(T_FMT, __cloc); ++ _M_data->_M_time_era_format = __nl_langinfo_l(ERA_T_FMT, __cloc); ++ _M_data->_M_date_time_format = __nl_langinfo_l(D_T_FMT, __cloc); ++ _M_data->_M_date_time_era_format = __nl_langinfo_l(ERA_D_T_FMT, __cloc); ++ _M_data->_M_am = __nl_langinfo_l(AM_STR, __cloc); ++ _M_data->_M_pm = __nl_langinfo_l(PM_STR, __cloc); ++ _M_data->_M_am_pm_format = __nl_langinfo_l(T_FMT_AMPM, __cloc); ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = __nl_langinfo_l(DAY_1, __cloc); ++ _M_data->_M_day2 = __nl_langinfo_l(DAY_2, __cloc); ++ _M_data->_M_day3 = __nl_langinfo_l(DAY_3, __cloc); ++ _M_data->_M_day4 = __nl_langinfo_l(DAY_4, __cloc); ++ _M_data->_M_day5 = __nl_langinfo_l(DAY_5, __cloc); ++ _M_data->_M_day6 = __nl_langinfo_l(DAY_6, __cloc); ++ _M_data->_M_day7 = __nl_langinfo_l(DAY_7, __cloc); ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = __nl_langinfo_l(ABDAY_1, __cloc); ++ _M_data->_M_aday2 = __nl_langinfo_l(ABDAY_2, __cloc); ++ _M_data->_M_aday3 = __nl_langinfo_l(ABDAY_3, __cloc); ++ _M_data->_M_aday4 = __nl_langinfo_l(ABDAY_4, __cloc); ++ _M_data->_M_aday5 = __nl_langinfo_l(ABDAY_5, __cloc); ++ _M_data->_M_aday6 = __nl_langinfo_l(ABDAY_6, __cloc); ++ _M_data->_M_aday7 = __nl_langinfo_l(ABDAY_7, __cloc); ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = __nl_langinfo_l(MON_1, __cloc); ++ _M_data->_M_month02 = __nl_langinfo_l(MON_2, __cloc); ++ _M_data->_M_month03 = __nl_langinfo_l(MON_3, __cloc); ++ _M_data->_M_month04 = __nl_langinfo_l(MON_4, __cloc); ++ _M_data->_M_month05 = __nl_langinfo_l(MON_5, __cloc); ++ _M_data->_M_month06 = __nl_langinfo_l(MON_6, __cloc); ++ _M_data->_M_month07 = __nl_langinfo_l(MON_7, __cloc); ++ _M_data->_M_month08 = __nl_langinfo_l(MON_8, __cloc); ++ _M_data->_M_month09 = __nl_langinfo_l(MON_9, __cloc); ++ _M_data->_M_month10 = __nl_langinfo_l(MON_10, __cloc); ++ _M_data->_M_month11 = __nl_langinfo_l(MON_11, __cloc); ++ _M_data->_M_month12 = __nl_langinfo_l(MON_12, __cloc); ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = __nl_langinfo_l(ABMON_1, __cloc); ++ _M_data->_M_amonth02 = __nl_langinfo_l(ABMON_2, __cloc); ++ _M_data->_M_amonth03 = __nl_langinfo_l(ABMON_3, __cloc); ++ _M_data->_M_amonth04 = __nl_langinfo_l(ABMON_4, __cloc); ++ _M_data->_M_amonth05 = __nl_langinfo_l(ABMON_5, __cloc); ++ _M_data->_M_amonth06 = __nl_langinfo_l(ABMON_6, __cloc); ++ _M_data->_M_amonth07 = __nl_langinfo_l(ABMON_7, __cloc); ++ _M_data->_M_amonth08 = __nl_langinfo_l(ABMON_8, __cloc); ++ _M_data->_M_amonth09 = __nl_langinfo_l(ABMON_9, __cloc); ++ _M_data->_M_amonth10 = __nl_langinfo_l(ABMON_10, __cloc); ++ _M_data->_M_amonth11 = __nl_langinfo_l(ABMON_11, __cloc); ++ _M_data->_M_amonth12 = __nl_langinfo_l(ABMON_12, __cloc); ++ } ++ } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ void ++ __timepunct:: ++ _M_put(wchar_t* __s, size_t __maxlen, const wchar_t* __format, ++ const tm* __tm) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __wcsftime_l(__s, __maxlen, __format, __tm, _M_c_locale_timepunct); ++ const size_t __len = __wcsftime_l(__s, __maxlen, __format, __tm, ++ _M_c_locale_timepunct); ++#else ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_timepunct); ++ const size_t __len = wcsftime(__s, __maxlen, __format, __tm); ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ // Make sure __s is null terminated. ++ if (__len == 0) ++ __s[0] = L'\0'; ++ } ++ ++ template<> ++ void ++ __timepunct::_M_initialize_timepunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __timepunct_cache; ++ ++#warning wide time stuff ++// if (!__cloc) ++ { ++ // "C" locale ++ _M_c_locale_timepunct = _S_get_c_locale(); ++ ++ _M_data->_M_date_format = L"%m/%d/%y"; ++ _M_data->_M_date_era_format = L"%m/%d/%y"; ++ _M_data->_M_time_format = L"%H:%M:%S"; ++ _M_data->_M_time_era_format = L"%H:%M:%S"; ++ _M_data->_M_date_time_format = L""; ++ _M_data->_M_date_time_era_format = L""; ++ _M_data->_M_am = L"AM"; ++ _M_data->_M_pm = L"PM"; ++ _M_data->_M_am_pm_format = L""; ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = L"Sunday"; ++ _M_data->_M_day2 = L"Monday"; ++ _M_data->_M_day3 = L"Tuesday"; ++ _M_data->_M_day4 = L"Wednesday"; ++ _M_data->_M_day5 = L"Thursday"; ++ _M_data->_M_day6 = L"Friday"; ++ _M_data->_M_day7 = L"Saturday"; ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = L"Sun"; ++ _M_data->_M_aday2 = L"Mon"; ++ _M_data->_M_aday3 = L"Tue"; ++ _M_data->_M_aday4 = L"Wed"; ++ _M_data->_M_aday5 = L"Thu"; ++ _M_data->_M_aday6 = L"Fri"; ++ _M_data->_M_aday7 = L"Sat"; ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = L"January"; ++ _M_data->_M_month02 = L"February"; ++ _M_data->_M_month03 = L"March"; ++ _M_data->_M_month04 = L"April"; ++ _M_data->_M_month05 = L"May"; ++ _M_data->_M_month06 = L"June"; ++ _M_data->_M_month07 = L"July"; ++ _M_data->_M_month08 = L"August"; ++ _M_data->_M_month09 = L"September"; ++ _M_data->_M_month10 = L"October"; ++ _M_data->_M_month11 = L"November"; ++ _M_data->_M_month12 = L"December"; ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = L"Jan"; ++ _M_data->_M_amonth02 = L"Feb"; ++ _M_data->_M_amonth03 = L"Mar"; ++ _M_data->_M_amonth04 = L"Apr"; ++ _M_data->_M_amonth05 = L"May"; ++ _M_data->_M_amonth06 = L"Jun"; ++ _M_data->_M_amonth07 = L"Jul"; ++ _M_data->_M_amonth08 = L"Aug"; ++ _M_data->_M_amonth09 = L"Sep"; ++ _M_data->_M_amonth10 = L"Oct"; ++ _M_data->_M_amonth11 = L"Nov"; ++ _M_data->_M_amonth12 = L"Dec"; ++ } ++#if 0 ++ else ++ { ++ _M_c_locale_timepunct = _S_clone_c_locale(__cloc); ++ ++ _M_data->_M_date_format = reinterpret_cast(__nl_langinfo_l(_NL_WD_FMT, __cloc)); ++ _M_data->_M_date_era_format = reinterpret_cast(__nl_langinfo_l(_NL_WERA_D_FMT, __cloc)); ++ _M_data->_M_time_format = reinterpret_cast(__nl_langinfo_l(_NL_WT_FMT, __cloc)); ++ _M_data->_M_time_era_format = reinterpret_cast(__nl_langinfo_l(_NL_WERA_T_FMT, __cloc)); ++ _M_data->_M_date_time_format = reinterpret_cast(__nl_langinfo_l(_NL_WD_T_FMT, __cloc)); ++ _M_data->_M_date_time_era_format = reinterpret_cast(__nl_langinfo_l(_NL_WERA_D_T_FMT, __cloc)); ++ _M_data->_M_am = reinterpret_cast(__nl_langinfo_l(_NL_WAM_STR, __cloc)); ++ _M_data->_M_pm = reinterpret_cast(__nl_langinfo_l(_NL_WPM_STR, __cloc)); ++ _M_data->_M_am_pm_format = reinterpret_cast(__nl_langinfo_l(_NL_WT_FMT_AMPM, __cloc)); ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_1, __cloc)); ++ _M_data->_M_day2 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_2, __cloc)); ++ _M_data->_M_day3 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_3, __cloc)); ++ _M_data->_M_day4 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_4, __cloc)); ++ _M_data->_M_day5 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_5, __cloc)); ++ _M_data->_M_day6 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_6, __cloc)); ++ _M_data->_M_day7 = reinterpret_cast(__nl_langinfo_l(_NL_WDAY_7, __cloc)); ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_1, __cloc)); ++ _M_data->_M_aday2 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_2, __cloc)); ++ _M_data->_M_aday3 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_3, __cloc)); ++ _M_data->_M_aday4 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_4, __cloc)); ++ _M_data->_M_aday5 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_5, __cloc)); ++ _M_data->_M_aday6 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_6, __cloc)); ++ _M_data->_M_aday7 = reinterpret_cast(__nl_langinfo_l(_NL_WABDAY_7, __cloc)); ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_1, __cloc)); ++ _M_data->_M_month02 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_2, __cloc)); ++ _M_data->_M_month03 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_3, __cloc)); ++ _M_data->_M_month04 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_4, __cloc)); ++ _M_data->_M_month05 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_5, __cloc)); ++ _M_data->_M_month06 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_6, __cloc)); ++ _M_data->_M_month07 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_7, __cloc)); ++ _M_data->_M_month08 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_8, __cloc)); ++ _M_data->_M_month09 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_9, __cloc)); ++ _M_data->_M_month10 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_10, __cloc)); ++ _M_data->_M_month11 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_11, __cloc)); ++ _M_data->_M_month12 = reinterpret_cast(__nl_langinfo_l(_NL_WMON_12, __cloc)); ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_1, __cloc)); ++ _M_data->_M_amonth02 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_2, __cloc)); ++ _M_data->_M_amonth03 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_3, __cloc)); ++ _M_data->_M_amonth04 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_4, __cloc)); ++ _M_data->_M_amonth05 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_5, __cloc)); ++ _M_data->_M_amonth06 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_6, __cloc)); ++ _M_data->_M_amonth07 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_7, __cloc)); ++ _M_data->_M_amonth08 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_8, __cloc)); ++ _M_data->_M_amonth09 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_9, __cloc)); ++ _M_data->_M_amonth10 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_10, __cloc)); ++ _M_data->_M_amonth11 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_11, __cloc)); ++ _M_data->_M_amonth12 = reinterpret_cast(__nl_langinfo_l(_NL_WABMON_12, __cloc)); ++ } ++#endif // 0 ++ } ++#endif ++} +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/time_members.h gcc-3.4.2/libstdc++-v3/config/locale/uclibc/time_members.h +--- gcc-3.4.2-dist/libstdc++-v3/config/locale/uclibc/time_members.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/locale/uclibc/time_members.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,68 @@ ++// std::time_get, std::time_put implementation, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.5.1.2 - time_get functions ++// ISO C++ 14882: 22.2.5.3.2 - time_put functions ++// ++ ++// Written by Benjamin Kosnik ++ ++ template ++ __timepunct<_CharT>::__timepunct(size_t __refs) ++ : facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL), ++ _M_name_timepunct(_S_get_c_name()) ++ { _M_initialize_timepunct(); } ++ ++ template ++ __timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs) ++ : facet(__refs), _M_data(__cache), _M_c_locale_timepunct(NULL), ++ _M_name_timepunct(_S_get_c_name()) ++ { _M_initialize_timepunct(); } ++ ++ template ++ __timepunct<_CharT>::__timepunct(__c_locale __cloc, const char* __s, ++ size_t __refs) ++ : facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL), ++ _M_name_timepunct(__s) ++ { ++ char* __tmp = new char[std::strlen(__s) + 1]; ++ std::strcpy(__tmp, __s); ++ _M_name_timepunct = __tmp; ++ _M_initialize_timepunct(__cloc); ++ } ++ ++ template ++ __timepunct<_CharT>::~__timepunct() ++ { ++ if (_M_name_timepunct != _S_get_c_name()) ++ delete [] _M_name_timepunct; ++ delete _M_data; ++ _S_destroy_c_locale(_M_c_locale_timepunct); ++ } +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_base.h gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_base.h +--- gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_base.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_base.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,58 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 1997, 1998, 1999, 2000, 2002, 2003 ++// Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// Information as gleaned from /usr/include/ctype.h ++ ++ struct ctype_base ++ { ++ // Note: In uClibc, the following two types depend on configuration. ++ ++ // Non-standard typedefs. ++ typedef const __ctype_touplow_t* __to_type; ++ ++ // NB: Offsets into ctype::_M_table force a particular size ++ // on the mask type. Because of this, we don't use an enum. ++ typedef __ctype_mask_t mask; ++ static const mask upper = _ISupper; ++ static const mask lower = _ISlower; ++ static const mask alpha = _ISalpha; ++ static const mask digit = _ISdigit; ++ static const mask xdigit = _ISxdigit; ++ static const mask space = _ISspace; ++ static const mask print = _ISprint; ++ static const mask graph = _ISalpha | _ISdigit | _ISpunct; ++ static const mask cntrl = _IScntrl; ++ static const mask punct = _ISpunct; ++ static const mask alnum = _ISalpha | _ISdigit; ++ }; +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_inline.h gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_inline.h +--- gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_inline.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_inline.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,69 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 2000, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*) ++// functions go in ctype.cc ++ ++ bool ++ ctype:: ++ is(mask __m, char __c) const ++ { return _M_table[static_cast(__c)] & __m; } ++ ++ const char* ++ ctype:: ++ is(const char* __low, const char* __high, mask* __vec) const ++ { ++ while (__low < __high) ++ *__vec++ = _M_table[static_cast(*__low++)]; ++ return __high; ++ } ++ ++ const char* ++ ctype:: ++ scan_is(mask __m, const char* __low, const char* __high) const ++ { ++ while (__low < __high ++ && !(_M_table[static_cast(*__low)] & __m)) ++ ++__low; ++ return __low; ++ } ++ ++ const char* ++ ctype:: ++ scan_not(mask __m, const char* __low, const char* __high) const ++ { ++ while (__low < __high ++ && (_M_table[static_cast(*__low)] & __m) != 0) ++ ++__low; ++ return __low; ++ } +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_noninline.h gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_noninline.h +--- gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/ctype_noninline.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/os/uclibc/ctype_noninline.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,92 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2004 ++// Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// Information as gleaned from /usr/include/ctype.h ++ ++ const ctype_base::mask* ++ ctype::classic_table() throw() ++ { return __C_ctype_b; } ++ ++ ctype::ctype(__c_locale, const mask* __table, bool __del, ++ size_t __refs) ++ : facet(__refs), _M_c_locale_ctype(_S_get_c_locale()), ++ _M_del(__table != 0 && __del), _M_widen_ok(0), _M_narrow_ok(0) ++ { ++ _M_toupper = __C_ctype_toupper; ++ _M_tolower = __C_ctype_tolower; ++ _M_table = __table ? __table : __C_ctype_b; ++ memset(_M_widen, 0, sizeof(_M_widen)); ++ memset(_M_narrow, 0, sizeof(_M_narrow)); ++ } ++ ++ ctype::ctype(const mask* __table, bool __del, size_t __refs) ++ : facet(__refs), _M_c_locale_ctype(_S_get_c_locale()), ++ _M_del(__table != 0 && __del), _M_widen_ok(0), _M_narrow_ok(0) ++ { ++ _M_toupper = __C_ctype_toupper; ++ _M_tolower = __C_ctype_tolower; ++ _M_table = __table ? __table : __C_ctype_b; ++ memset(_M_widen, 0, sizeof(_M_widen)); ++ memset(_M_narrow, 0, sizeof(_M_narrow)); ++ } ++ ++ char ++ ctype::do_toupper(char __c) const ++ { return _M_toupper[static_cast(__c)]; } ++ ++ const char* ++ ctype::do_toupper(char* __low, const char* __high) const ++ { ++ while (__low < __high) ++ { ++ *__low = _M_toupper[static_cast(*__low)]; ++ ++__low; ++ } ++ return __high; ++ } ++ ++ char ++ ctype::do_tolower(char __c) const ++ { return _M_tolower[static_cast(__c)]; } ++ ++ const char* ++ ctype::do_tolower(char* __low, const char* __high) const ++ { ++ while (__low < __high) ++ { ++ *__low = _M_tolower[static_cast(*__low)]; ++ ++__low; ++ } ++ return __high; ++ } +diff -urN gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/os_defines.h gcc-3.4.2/libstdc++-v3/config/os/uclibc/os_defines.h +--- gcc-3.4.2-dist/libstdc++-v3/config/os/uclibc/os_defines.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/config/os/uclibc/os_defines.h 2004-09-10 10:47:40.000000000 -0500 +@@ -0,0 +1,44 @@ ++// Specific definitions for GNU/Linux -*- C++ -*- ++ ++// Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++#ifndef _GLIBCXX_OS_DEFINES ++#define _GLIBCXX_OS_DEFINES 1 ++ ++// System-specific #define, typedefs, corrections, etc, go here. This ++// file will come before all others. ++ ++// This keeps isanum, et al from being propagated as macros. ++#define __NO_CTYPE 1 ++ ++#include ++ ++// We must not see the optimized string functions GNU libc defines. ++#define __NO_STRING_INLINES ++ ++#endif +diff -urN gcc-3.4.2-dist/libstdc++-v3/configure gcc-3.4.2/libstdc++-v3/configure +--- gcc-3.4.2-dist/libstdc++-v3/configure 2004-08-13 15:44:04.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/configure 2004-09-10 10:47:40.000000000 -0500 +@@ -3878,6 +3878,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +@@ -5545,6 +5550,9 @@ + # Default to "generic". + if test $enable_clocale_flag = auto; then + case x${target_os} in ++ xlinux-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + xlinux* | xgnu* | xkfreebsd*-gnu | xknetbsd*-gnu) + cat >conftest.$ac_ext <<_ACEOF + #line $LINENO "configure" +@@ -5759,6 +5767,77 @@ + CTIME_CC=config/locale/generic/time_members.cc + CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h + ;; ++ uclibc) ++ echo "$as_me:$LINENO: result: uclibc" >&5 ++echo "${ECHO_T}uclibc" >&6 ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ # Extract the first word of "msgfmt", so it can be a program name with args. ++set dummy msgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_prog_check_msgfmt+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ if test -n "$check_msgfmt"; then ++ ac_cv_prog_check_msgfmt="$check_msgfmt" # Let the user override the test. ++else ++as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_prog_check_msgfmt="yes" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_prog_check_msgfmt" && ac_cv_prog_check_msgfmt="no" ++fi ++fi ++check_msgfmt=$ac_cv_prog_check_msgfmt ++if test -n "$check_msgfmt"; then ++ echo "$as_me:$LINENO: result: $check_msgfmt" >&5 ++echo "${ECHO_T}$check_msgfmt" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcxx_MOFILES="$glibcxx_MOFILES $ling.mo"; \ ++ glibcxx_POFILES="$glibcxx_POFILES $ling.po"; \ ++ done ++ ++ ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_H=config/locale/ieee_1003.1-2001/codecvt_specializations.h ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + esac + + # This is where the testsuite looks for locale catalogs, using the +diff -urN gcc-3.4.2-dist/libstdc++-v3/configure.host gcc-3.4.2/libstdc++-v3/configure.host +--- gcc-3.4.2-dist/libstdc++-v3/configure.host 2004-08-27 14:52:30.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/configure.host 2004-09-10 10:47:40.000000000 -0500 +@@ -217,6 +217,12 @@ + ;; + esac + ++# Override for uClibc since linux-uclibc gets mishandled above. ++case "${host_os}" in ++ *-uclibc*) ++ os_include_dir="os/uclibc" ++ ;; ++esac + + # Set any OS-dependent and CPU-dependent bits. + # THIS TABLE IS SORTED. KEEP IT THAT WAY. +diff -urN gcc-3.4.2-dist/libstdc++-v3/crossconfig.m4 gcc-3.4.2/libstdc++-v3/crossconfig.m4 +--- gcc-3.4.2-dist/libstdc++-v3/crossconfig.m4 2004-07-06 20:23:49.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/crossconfig.m4 2004-09-10 10:47:40.000000000 -0500 +@@ -138,6 +138,99 @@ + ;; + esac + ;; ++ *-uclibc*) ++# Temporary hack until we implement the float versions of the libm funcs ++ AC_CHECK_HEADERS([nan.h ieeefp.h endian.h sys/isa_defs.h \ ++ machine/endian.h machine/param.h sys/machine.h sys/types.h \ ++ fp.h float.h endian.h inttypes.h locale.h float.h stdint.h]) ++ SECTION_FLAGS='-ffunction-sections -fdata-sections' ++ AC_SUBST(SECTION_FLAGS) ++ GLIBCXX_CHECK_LINKER_FEATURES ++ GLIBCXX_CHECK_COMPLEX_MATH_SUPPORT ++ GLIBCXX_CHECK_WCHAR_T_SUPPORT ++ ++ # For LFS. ++ AC_DEFINE(HAVE_INT64_T) ++ case "$target" in ++ *-uclinux*) ++ # Don't enable LFS with uClinux ++ ;; ++ *) ++ AC_DEFINE(_GLIBCXX_USE_LFS) ++ esac ++ ++ # For showmanyc_helper(). ++ AC_CHECK_HEADERS(sys/ioctl.h sys/filio.h) ++ GLIBCXX_CHECK_POLL ++ GLIBCXX_CHECK_S_ISREG_OR_S_IFREG ++ ++ # For xsputn_2(). ++ AC_CHECK_HEADERS(sys/uio.h) ++ GLIBCXX_CHECK_WRITEV ++ ++# AC_DEFINE(HAVE_ACOSF) ++# AC_DEFINE(HAVE_ASINF) ++# AC_DEFINE(HAVE_ATANF) ++# AC_DEFINE(HAVE_ATAN2F) ++ AC_DEFINE(HAVE_CEILF) ++ AC_DEFINE(HAVE_COPYSIGN) ++# AC_DEFINE(HAVE_COPYSIGNF) ++# AC_DEFINE(HAVE_COSF) ++# AC_DEFINE(HAVE_COSHF) ++# AC_DEFINE(HAVE_EXPF) ++# AC_DEFINE(HAVE_FABSF) ++ AC_DEFINE(HAVE_FINITE) ++ AC_DEFINE(HAVE_FINITEF) ++ AC_DEFINE(HAVE_FLOORF) ++# AC_DEFINE(HAVE_FMODF) ++# AC_DEFINE(HAVE_FREXPF) ++ AC_DEFINE(HAVE_HYPOT) ++# AC_DEFINE(HAVE_HYPOTF) ++ AC_DEFINE(HAVE_ISINF) ++ AC_DEFINE(HAVE_ISINFF) ++ AC_DEFINE(HAVE_ISNAN) ++ AC_DEFINE(HAVE_ISNANF) ++# AC_DEFINE(HAVE_LOGF) ++# AC_DEFINE(HAVE_LOG10F) ++# AC_DEFINE(HAVE_MODFF) ++# AC_DEFINE(HAVE_SINF) ++# AC_DEFINE(HAVE_SINHF) ++# AC_DEFINE(HAVE_SINCOS) ++# AC_DEFINE(HAVE_SINCOSF) ++ AC_DEFINE(HAVE_SQRTF) ++# AC_DEFINE(HAVE_TANF) ++# AC_DEFINE(HAVE_TANHF) ++ if test x"long_double_math_on_this_cpu" = x"yes"; then ++ AC_MSG_ERROR([long_double_math_on_this_cpu is yes!]) ++# AC_DEFINE(HAVE_ACOSL) ++# AC_DEFINE(HAVE_ASINL) ++# AC_DEFINE(HAVE_ATANL) ++# AC_DEFINE(HAVE_ATAN2L) ++# AC_DEFINE(HAVE_CEILL) ++# AC_DEFINE(HAVE_COPYSIGNL) ++# AC_DEFINE(HAVE_COSL) ++# AC_DEFINE(HAVE_COSHL) ++# AC_DEFINE(HAVE_EXPL) ++# AC_DEFINE(HAVE_FABSL) ++# AC_DEFINE(HAVE_FINITEL) ++# AC_DEFINE(HAVE_FLOORL) ++# AC_DEFINE(HAVE_FMODL) ++# AC_DEFINE(HAVE_FREXPL) ++# AC_DEFINE(HAVE_HYPOTL) ++# AC_DEFINE(HAVE_ISINFL) ++# AC_DEFINE(HAVE_ISNANL) ++# AC_DEFINE(HAVE_LOGL) ++# AC_DEFINE(HAVE_LOG10L) ++# AC_DEFINE(HAVE_MODFL) ++# AC_DEFINE(HAVE_POWL) ++# AC_DEFINE(HAVE_SINL) ++# AC_DEFINE(HAVE_SINHL) ++# AC_DEFINE(HAVE_SINCOSL) ++# AC_DEFINE(HAVE_SQRTL) ++# AC_DEFINE(HAVE_TANL) ++# AC_DEFINE(HAVE_TANHL) ++ fi ++ ;; + *-linux* | *-uclinux* | *-gnu* | *-kfreebsd*-gnu | *-knetbsd*-gnu) + AC_CHECK_HEADERS([nan.h ieeefp.h endian.h sys/isa_defs.h \ + machine/endian.h machine/param.h sys/machine.h sys/types.h \ +@@ -152,7 +245,7 @@ + AC_DEFINE(HAVE_INT64_T) + case "$target" in + *-uclinux*) +- # Don't enable LFS with uClibc ++ # Don't enable LFS with uClinux + ;; + *) + AC_DEFINE(_GLIBCXX_USE_LFS) +diff -urN gcc-3.4.2-dist/libstdc++-v3/include/c_compatibility/wchar.h gcc-3.4.2/libstdc++-v3/include/c_compatibility/wchar.h +--- gcc-3.4.2-dist/libstdc++-v3/include/c_compatibility/wchar.h 2003-12-08 21:51:45.000000000 -0600 ++++ gcc-3.4.2/libstdc++-v3/include/c_compatibility/wchar.h 2004-09-10 10:47:40.000000000 -0500 +@@ -101,7 +101,9 @@ + using std::wmemcpy; + using std::wmemmove; + using std::wmemset; ++#if _GLIBCXX_HAVE_WCSFTIME + using std::wcsftime; ++#endif + + #if _GLIBCXX_USE_C99 + using std::wcstold; +diff -urN gcc-3.4.2-dist/libstdc++-v3/include/c_std/std_cwchar.h gcc-3.4.2/libstdc++-v3/include/c_std/std_cwchar.h +--- gcc-3.4.2-dist/libstdc++-v3/include/c_std/std_cwchar.h 2004-07-20 03:52:12.000000000 -0500 ++++ gcc-3.4.2/libstdc++-v3/include/c_std/std_cwchar.h 2004-09-10 10:47:40.000000000 -0500 +@@ -179,7 +179,9 @@ + using ::wcscoll; + using ::wcscpy; + using ::wcscspn; ++#if _GLIBCXX_HAVE_WCSFTIME + using ::wcsftime; ++#endif + using ::wcslen; + using ::wcsncat; + using ::wcsncmp; diff --git a/meta/packages/gcc/gcc-3.4.4/gcc-uclibc-3.4.0-120-softfloat.patch b/meta/packages/gcc/gcc-3.4.4/gcc-uclibc-3.4.0-120-softfloat.patch new file mode 100644 index 000000000..f2431896c --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc-uclibc-3.4.0-120-softfloat.patch @@ -0,0 +1,14 @@ +--- gcc-3.3.2-old/configure.in 2003-08-09 01:57:21.000000000 -0500 ++++ gcc-3.3.2/configure.in 2004-01-15 12:46:29.000000000 -0600 +@@ -1418,6 +1418,11 @@ + fi + + FLAGS_FOR_TARGET= ++case " $targargs " in ++ *" --nfp "* | *" --without-float "*) ++ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -msoft-float' ++ ;; ++esac + case " $target_configdirs " in + *" newlib "*) + case " $targargs " in diff --git a/meta/packages/gcc/gcc-3.4.4/gcc34-arm-ldm-peephole.patch b/meta/packages/gcc/gcc-3.4.4/gcc34-arm-ldm-peephole.patch new file mode 100644 index 000000000..92ad25d09 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc34-arm-ldm-peephole.patch @@ -0,0 +1,79 @@ +--- gcc-3.4.0/gcc/config/arm/arm.md.arm-ldm-peephole 2004-01-13 08:24:37.000000000 -0500 ++++ gcc-3.4.0/gcc/config/arm/arm.md 2004-04-24 18:18:04.000000000 -0400 +@@ -8810,13 +8810,16 @@ + (set_attr "length" "4,8,8")] + ) + ++; Try to convert LDR+LDR+arith into [add+]LDM+arith ++; On XScale, LDM is always slower than two LDRs, so only do this if ++; optimising for size. + (define_insn "*arith_adjacentmem" + [(set (match_operand:SI 0 "s_register_operand" "=r") + (match_operator:SI 1 "shiftable_operator" + [(match_operand:SI 2 "memory_operand" "m") + (match_operand:SI 3 "memory_operand" "m")])) + (clobber (match_scratch:SI 4 "=r"))] +- "TARGET_ARM && adjacent_mem_locations (operands[2], operands[3])" ++ "TARGET_ARM && (!arm_tune_xscale || optimize_size) && adjacent_mem_locations (operands[2], operands[3])" + "* + { + rtx ldm[3]; +@@ -8851,6 +8854,8 @@ + } + if (val1 && val2) + { ++ /* This would be a loss on a Harvard core, but adjacent_mem_locations() ++ will prevent it from happening. */ + rtx ops[3]; + ldm[0] = ops[0] = operands[4]; + ops[1] = XEXP (XEXP (operands[2], 0), 0); +--- gcc-3.4.0/gcc/genpeep.c.arm-ldm-peephole 2003-07-05 01:27:22.000000000 -0400 ++++ gcc-3.4.0/gcc/genpeep.c 2004-04-24 18:18:04.000000000 -0400 +@@ -381,6 +381,7 @@ + printf ("#include \"recog.h\"\n"); + printf ("#include \"except.h\"\n\n"); + printf ("#include \"function.h\"\n\n"); ++ printf ("#include \"flags.h\"\n\n"); + + printf ("#ifdef HAVE_peephole\n"); + printf ("extern rtx peep_operand[];\n\n"); +--- gcc/gcc/config/arm/arm.c.orig 2005-06-02 22:40:40.000000000 +0100 ++++ gcc/gcc/config/arm/arm.c 2005-06-02 22:45:45.000000000 +0100 +@@ -4610,9 +4610,12 @@ + if (arm_eliminable_register (reg0)) + return 0; + ++ /* For Harvard cores, only accept pairs where one offset is zero. ++ See comment in load_multiple_sequence. */ + val_diff = val1 - val0; + return ((REGNO (reg0) == REGNO (reg1)) +- && (val_diff == 4 || val_diff == -4)); ++ && (val_diff == 4 || val_diff == -4)) ++ && (!arm_ld_sched || val0 == 0 || val1 == 0); + } + + return 0; +@@ -4857,6 +4860,11 @@ + *load_offset = unsorted_offsets[order[0]]; + } + ++ /* For XScale a two-word LDM is a performance loss, so only do this if ++ size is more important. See comments in arm_gen_load_multiple. */ ++ if (nops == 2 && arm_tune_xscale && !optimize_size) ++ return 0; ++ + if (unsorted_offsets[order[0]] == 0) + return 1; /* ldmia */ + +@@ -5083,6 +5091,11 @@ + *load_offset = unsorted_offsets[order[0]]; + } + ++ /* For XScale a two-word LDM is a performance loss, so only do this if ++ size is more important. See comments in arm_gen_load_multiple. */ ++ if (nops == 2 && arm_tune_xscale && !optimize_size) ++ return 0; ++ + if (unsorted_offsets[order[0]] == 0) + return 1; /* stmia */ + diff --git a/meta/packages/gcc/gcc-3.4.4/gcc34-arm-ldm.patch b/meta/packages/gcc/gcc-3.4.4/gcc34-arm-ldm.patch new file mode 100644 index 000000000..142052fdf --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc34-arm-ldm.patch @@ -0,0 +1,119 @@ +--- gcc-3.4.0/gcc/config/arm/arm.c.arm-ldm 2004-02-27 09:51:05.000000000 -0500 ++++ gcc-3.4.0/gcc/config/arm/arm.c 2004-04-24 18:16:25.000000000 -0400 +@@ -8520,6 +8520,26 @@ + return_used_this_function = 0; + } + ++/* Return the number (counting from 0) of ++ the least significant set bit in MASK. */ ++ ++#ifdef __GNUC__ ++inline ++#endif ++static int ++number_of_first_bit_set (mask) ++ int mask; ++{ ++ int bit; ++ ++ for (bit = 0; ++ (mask & (1 << bit)) == 0; ++ ++bit) ++ continue; ++ ++ return bit; ++} ++ + const char * + arm_output_epilogue (rtx sibling) + { +@@ -8753,27 +8773,47 @@ + saved_regs_mask |= (1 << PC_REGNUM); + } + +- /* Load the registers off the stack. If we only have one register +- to load use the LDR instruction - it is faster. */ +- if (saved_regs_mask == (1 << LR_REGNUM)) +- { +- /* The exception handler ignores the LR, so we do +- not really need to load it off the stack. */ +- if (eh_ofs) +- asm_fprintf (f, "\tadd\t%r, %r, #4\n", SP_REGNUM, SP_REGNUM); +- else +- asm_fprintf (f, "\tldr\t%r, [%r], #4\n", LR_REGNUM, SP_REGNUM); +- } +- else if (saved_regs_mask) ++ if (saved_regs_mask) + { +- if (saved_regs_mask & (1 << SP_REGNUM)) +- /* Note - write back to the stack register is not enabled +- (ie "ldmfd sp!..."). We know that the stack pointer is +- in the list of registers and if we add writeback the +- instruction becomes UNPREDICTABLE. */ +- print_multi_reg (f, "ldmfd\t%r", SP_REGNUM, saved_regs_mask); ++ /* Load the registers off the stack. If we only have one register ++ to load use the LDR instruction - it is faster. */ ++ if (bit_count (saved_regs_mask) == 1) ++ { ++ int reg = number_of_first_bit_set (saved_regs_mask); ++ ++ switch (reg) ++ { ++ case SP_REGNUM: ++ /* Mustn't use base writeback when loading SP. */ ++ asm_fprintf (f, "\tldr\t%r, [%r]\n", SP_REGNUM, SP_REGNUM); ++ break; ++ ++ case LR_REGNUM: ++ if (eh_ofs) ++ { ++ /* The exception handler ignores the LR, so we do ++ not really need to load it off the stack. */ ++ asm_fprintf (f, "\tadd\t%r, %r, #4\n", SP_REGNUM, SP_REGNUM); ++ break; ++ } ++ /* else fall through */ ++ ++ default: ++ asm_fprintf (f, "\tldr\t%r, [%r], #4\n", reg, SP_REGNUM); ++ break; ++ } ++ } + else +- print_multi_reg (f, "ldmfd\t%r!", SP_REGNUM, saved_regs_mask); ++ { ++ if (saved_regs_mask & (1 << SP_REGNUM)) ++ /* Note - write back to the stack register is not enabled ++ (ie "ldmfd sp!..."). We know that the stack pointer is ++ in the list of registers and if we add writeback the ++ instruction becomes UNPREDICTABLE. */ ++ print_multi_reg (f, "ldmfd\t%r", SP_REGNUM, saved_regs_mask); ++ else ++ print_multi_reg (f, "ldmfd\t%r!", SP_REGNUM, saved_regs_mask); ++ } + } + + if (current_function_pretend_args_size) +@@ -11401,22 +11441,6 @@ + } + } + +-/* Return the number (counting from 0) of +- the least significant set bit in MASK. */ +- +-inline static int +-number_of_first_bit_set (int mask) +-{ +- int bit; +- +- for (bit = 0; +- (mask & (1 << bit)) == 0; +- ++bit) +- continue; +- +- return bit; +-} +- + /* Generate code to return from a thumb function. + If 'reg_containing_return_addr' is -1, then the return address is + actually on the stack, at the stack pointer. */ diff --git a/meta/packages/gcc/gcc-3.4.4/gcc34-arm-tune.patch b/meta/packages/gcc/gcc-3.4.4/gcc34-arm-tune.patch new file mode 100644 index 000000000..cdb20bef9 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc34-arm-tune.patch @@ -0,0 +1,9 @@ +--- gcc-3.4.0/gcc/config/arm/linux-elf.h.arm-tune 2004-01-31 01:18:11.000000000 -0500 ++++ gcc-3.4.0/gcc/config/arm/linux-elf.h 2004-04-24 18:19:10.000000000 -0400 +@@ -126,3 +126,6 @@ + + #define LINK_GCC_C_SEQUENCE_SPEC \ + "%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}" ++ ++/* Tune for XScale. */ ++#define TARGET_TUNE_DEFAULT TARGET_CPU_xscale diff --git a/meta/packages/gcc/gcc-3.4.4/gcc34-configure.in.patch b/meta/packages/gcc/gcc-3.4.4/gcc34-configure.in.patch new file mode 100644 index 000000000..3d33bcb97 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc34-configure.in.patch @@ -0,0 +1,22 @@ +--- gcc-3.4.4/configure.in.orig 2005-08-09 19:57:51.504323183 -0700 ++++ gcc-3.4.4/configure.in 2005-08-09 20:00:12.073168623 -0700 +@@ -1907,7 +1907,7 @@ + *) gxx_include_dir=${with_gxx_include_dir} ;; + esac + +-FLAGS_FOR_TARGET= ++FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET" + case " $target_configdirs " in + *" newlib "*) + case " $target_configargs " in +--- gcc-3.4.4/configure.orig 2005-08-09 21:02:29.668360660 -0700 ++++ gcc-3.4.4/configure 2005-08-09 21:02:50.157649970 -0700 +@@ -2669,7 +2669,7 @@ + *) gxx_include_dir=${with_gxx_include_dir} ;; + esac + +-FLAGS_FOR_TARGET= ++FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET" + case " $target_configdirs " in + *" newlib "*) + case " $target_configargs " in diff --git a/meta/packages/gcc/gcc-3.4.4/gcc34-reverse-compare.patch b/meta/packages/gcc/gcc-3.4.4/gcc34-reverse-compare.patch new file mode 100644 index 000000000..c3c40dd18 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc34-reverse-compare.patch @@ -0,0 +1,32 @@ +--- gcc-3.4.0/gcc/flow.c.reverse-compare 2004-02-27 22:39:19.000000000 -0500 ++++ gcc-3.4.0/gcc/flow.c 2004-04-24 16:36:00.000000000 -0400 +@@ -1843,6 +1843,7 @@ + regset_head diff_head; + regset diff = INITIALIZE_REG_SET (diff_head); + basic_block bb_true, bb_false; ++ enum rtx_code reversed_code; + int i; + + /* Identify the successor blocks. */ +@@ -1889,8 +1890,11 @@ + if (GET_CODE (reg) == REG + && XEXP (cond_true, 1) == const0_rtx) + { +- rtx cond_false +- = gen_rtx_fmt_ee (reverse_condition (GET_CODE (cond_true)), ++ rtx cond_false; ++ reversed_code = reverse_condition (GET_CODE (cond_true)); ++ if (reversed_code == UNKNOWN) ++ goto skip; ++ cond_false = gen_rtx_fmt_ee (reversed_code, + GET_MODE (cond_true), XEXP (cond_true, 0), + XEXP (cond_true, 1)); + if (GET_CODE (XEXP (set_src, 1)) == PC) +@@ -1925,6 +1929,7 @@ + } + } + ++ skip: + FREE_REG_SET (diff); + } + #endif diff --git a/meta/packages/gcc/gcc-3.4.4/gcc34-thumb-support.patch b/meta/packages/gcc/gcc-3.4.4/gcc34-thumb-support.patch new file mode 100644 index 000000000..a4f156f8d --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/gcc34-thumb-support.patch @@ -0,0 +1,156 @@ +# This patch contains various fixes for the thumb code handling in GCC 3.4.4 +# +# Most of these are minor fixes to code which is either missing (Linux thumb +# div0, thumb clear instruction cache) or uses the wrong return mechanism +# (libffi) +# +# There is also a significant design problem with the _call_via_rx code - +# it cannot be in a shared library because a call via PLT simply won't +# work (for _call_via_ip) and is very inefficient anyway. +# +# This is fixed in uclibc simply by incorporating the code into crti.S +# (an extra 30 bytes for the 15 functions) even though not all link units +# require all the code - there is so little of it. That doesn't work with +# the crti.asm here because it is linked with libgcc.a which already defines +# these symbols +# +--- gcc-3.4.4/gcc/config/arm/t-linux.orig 2005-08-09 08:55:02.181797492 -0700 ++++ gcc-3.4.4/gcc/config/arm/t-linux 2005-08-09 08:58:22.766419486 -0700 +@@ -7,6 +7,7 @@ + LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \ + _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \ + _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \ ++ _call_via_rX \ + _fixsfsi _fixunssfsi + + # MULTILIB_OPTIONS = mhard-float/msoft-float +--- gcc-3.4.4/.pc/gcc34-thumb-support.patch/gcc/config/arm/lib1funcs.asm 2004-01-15 08:56:34.000000000 -0800 ++++ gcc-3.4.4/gcc/config/arm/lib1funcs.asm 2005-09-21 21:32:03.376927755 -0700 +@@ -811,13 +811,18 @@ + + /* Constants taken from and */ + #define SIGFPE 8 ++#if !defined __thumb__ + #define __NR_SYSCALL_BASE 0x900000 ++#else ++#define __NR_SYSCALL_BASE 0 ++#endif + #define __NR_getpid (__NR_SYSCALL_BASE+ 20) + #define __NR_kill (__NR_SYSCALL_BASE+ 37) + + .code 32 + FUNC_START div0 + ++#if ! defined __thumb__ + stmfd sp!, {r1, lr} + swi __NR_getpid + cmn r0, #1000 +@@ -825,6 +830,28 @@ + mov r1, #SIGFPE + swi __NR_kill + RETLDM r1 ++#else ++ push {r1, r7, lr} ++ mov r7, #__NR_getpid ++ swi 0 ++ @ above the compare is with -1000, but the standard syscall ++ @ macro checks for -1..-125 ++ add r0, #125 ++ bcs 90f ++ sub r0, #125 ++ mov r1, #SIGFPE ++ mov r7, #__NR_kill ++ swi 0 ++90: ++#if __ARM_ARCH__ > 4 ++ pop {r1, r7, pc} ++#else ++ @ on 4T that won't work ++ pop {r1, r7} ++ pop {r3} ++ bx r3 ++#endif ++#endif + + FUNC_END div0 + +@@ -845,14 +872,14 @@ + code here switches to the correct mode before executing the function. */ + + .text +- .align 0 ++ .align 1 + .force_thumb + + .macro call_via register + THUMB_FUNC_START _call_via_\register ++ .hidden SYM (_call_via_\register) + + bx \register +- nop + + SIZE (_call_via_\register) + .endm +@@ -903,6 +930,7 @@ + .code 16 + + THUMB_FUNC_START _interwork_call_via_\register ++ .hidden SYM (_interwork_call_via_\register) + + bx pc + nop +--- gcc-3.4.4/.pc/gcc34-thumb-support.patch/gcc/config/arm/linux-gas.h 2003-06-19 14:47:06.000000000 -0700 ++++ gcc-3.4.4/gcc/config/arm/linux-gas.h 2005-09-20 16:09:55.027862200 -0700 +@@ -56,6 +56,7 @@ + + /* Clear the instruction cache from `beg' to `end'. This makes an + inline system call to SYS_cacheflush. */ ++#if !defined(__thumb__) + #define CLEAR_INSN_CACHE(BEG, END) \ + { \ + register unsigned long _beg __asm ("a1") = (unsigned long) (BEG); \ +@@ -65,3 +66,18 @@ + : "=r" (_beg) \ + : "0" (_beg), "r" (_end), "r" (_flg)); \ + } ++#else ++#define CLEAR_INSN_CACHE(BEG, END) \ ++{ \ ++ register unsigned long _beg __asm ("a1") = (unsigned long) (BEG); \ ++ register unsigned long _end __asm ("a2") = (unsigned long) (END); \ ++ register unsigned long _flg __asm ("a3") = 0; \ ++ register unsigned long _swi __asm ("a4") = 0xf0002; \ ++ __asm __volatile ("push {r7}\n" \ ++ " mov r7,a4\n" \ ++ " swi 0 @ sys_cacheflush\n" \ ++ " pop {r7}\n" \ ++ : "=r" (_beg) \ ++ : "0" (_beg), "r" (_end), "r" (_flg), "r" (_swi)); \ ++} ++#endif +--- gcc-3.4.4/.pc/gcc34-thumb-support.patch/libffi/src/arm/sysv.S 2003-10-21 12:01:55.000000000 -0700 ++++ gcc-3.4.4/libffi/src/arm/sysv.S 2005-09-20 16:09:55.027862200 -0700 +@@ -41,6 +41,14 @@ + #define ENTRY(x) .globl CNAME(x); .type CNAME(x),%function; CNAME(x): + #endif + ++/* Get the correct return instruction */ ++#if defined(__ARM_ARCH_4T__) || defined(__ARM_ARCH_5__) \ ++ || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__) ++#define RET bx r ++#else ++#define RET mov pc, ++#endif ++ + .text + + # a1: ffi_prep_args +@@ -66,7 +74,7 @@ + + # And call + mov lr, pc +- mov pc, ip ++ RET ip + + # move first 4 parameters in registers + ldr a1, [sp, #0] diff --git a/meta/packages/gcc/gcc-3.4.4/sdk-libstdc++-includes.patch b/meta/packages/gcc/gcc-3.4.4/sdk-libstdc++-includes.patch new file mode 100644 index 000000000..4377c2143 --- /dev/null +++ b/meta/packages/gcc/gcc-3.4.4/sdk-libstdc++-includes.patch @@ -0,0 +1,22 @@ +--- gcc-3.4.1/libstdc++-v3/libmath/Makefile.am~ 2003-08-27 22:29:42.000000000 +0100 ++++ gcc-3.4.1/libstdc++-v3/libmath/Makefile.am 2004-07-22 16:41:45.152130128 +0100 +@@ -32,7 +32,7 @@ + + libmath_la_SOURCES = stubs.c + +-AM_CPPFLAGS = $(CANADIAN_INCLUDES) ++AM_CPPFLAGS = $(CANADIAN_INCLUDES) -I$(toplevel_srcdir)/include + + # Only compiling "C" sources in this directory. + LIBTOOL = @LIBTOOL@ --tag CC +--- gcc-3.4.1/libstdc++-v3/fragment.am.old 2004-07-22 18:24:58.024083656 +0100 ++++ gcc-3.4.1/libstdc++-v3/fragment.am 2004-07-22 18:24:59.019932264 +0100 +@@ -18,7 +18,7 @@ + $(WARN_FLAGS) $(WERROR) -fdiagnostics-show-location=once + + # -I/-D flags to pass when compiling. +-AM_CPPFLAGS = $(GLIBCXX_INCLUDES) ++AM_CPPFLAGS = $(GLIBCXX_INCLUDES) -I$(toplevel_srcdir)/include + + + diff --git a/meta/packages/gcc/gcc-4.0.2/100-uclibc-conf.patch b/meta/packages/gcc/gcc-4.0.2/100-uclibc-conf.patch new file mode 100644 index 000000000..35445522f --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/100-uclibc-conf.patch @@ -0,0 +1,556 @@ +From: +http://buildroot.uclibc.org/cgi-bin/viewcvs.cgi/*checkout*/trunk/buildroot/toolchain/gcc/4.0.2/100-uclibc-conf.patch?rev=13898 + +--- gcc-4.0.2/gcc/config/t-linux-uclibc ++++ gcc-4.0.2/gcc/config/t-linux-uclibc +@@ -0,0 +1,5 @@ ++# Remove glibc specific files added in t-linux ++SHLIB_MAPFILES := $(filter-out $(srcdir)/config/libgcc-glibc.ver, $(SHLIB_MAPFILES)) ++ ++# Use unwind-dw2-fde instead of unwind-dw2-fde-glibc ++LIB2ADDEH := $(subst unwind-dw2-fde-glibc.c,unwind-dw2-fde.c,$(LIB2ADDEH)) +--- gcc-4.0.2/gcc/config.gcc ++++ gcc-4.0.2/gcc/config.gcc +@@ -1778,7 +1778,7 @@ + ;; + sh-*-elf* | sh[12346l]*-*-elf* | sh*-*-kaos* | \ + sh-*-symbianelf* | sh[12346l]*-*-symbianelf* | \ +- sh-*-linux* | sh[346lbe]*-*-linux* | \ ++ sh*-*-linux* | sh[346lbe]*-*-linux* | \ + sh-*-netbsdelf* | shl*-*-netbsdelf* | sh5-*-netbsd* | sh5l*-*-netbsd* | \ + sh64-*-netbsd* | sh64l*-*-netbsd*) + tmake_file="${tmake_file} sh/t-sh sh/t-elf" +@@ -2234,10 +2234,16 @@ + *) + echo "*** Configuration ${target} not supported" 1>&2 + exit 1 + ;; + esac ++ ++# Rather than hook into each target, just do it after all the linux ++# targets have been processed ++case ${target} in ++*-linux-uclibc*) tm_defines="${tm_defines} USE_UCLIBC" ; tmake_file="${tmake_file} t-linux-uclibc" ++esac + + case ${target} in + i[34567]86-*-linux*aout* | i[34567]86-*-linux*libc1) + tmake_file="${tmake_file} i386/t-gmm_malloc" + ;; +--- gcc-4.0.2/gcc/config/alpha/linux-elf.h ++++ gcc-4.0.2/gcc/config/alpha/linux-elf.h +@@ -27,7 +27,11 @@ + #define SUBTARGET_EXTRA_SPECS \ + { "elf_dynamic_linker", ELF_DYNAMIC_LINKER }, + ++#ifdef USE_UCLIBC ++#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#else + #define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2" ++#endif + + #define LINK_SPEC "-m elf64alpha %{G*} %{relax:-relax} \ + %{O*:-O3} %{!O*:-O1} \ +--- gcc-4.0.2/gcc/config/arm/linux-elf.h ++++ gcc-4.0.2/gcc/config/arm/linux-elf.h +@@ -81,14 +81,19 @@ + #define ENDFILE_SPEC \ + "%{!shared:crtend.o%s} %{shared:crtendS.o%s} crtn.o%s" + ++#ifdef USE_UCLIBC ++#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#else ++#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2" ++#endif + #undef LINK_SPEC + #define LINK_SPEC "%{h*} %{version:-v} \ + %{b} %{Wl,*:%*} \ + %{static:-Bstatic} \ + %{shared:-shared} \ + %{symbolic:-Bsymbolic} \ + %{rdynamic:-export-dynamic} \ +- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2} \ ++ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "} \ + -X \ + %{mbig-endian:-EB}" \ + SUBTARGET_EXTRA_LINK_SPEC +--- gcc-4.0.2/gcc/config/cris/linux.h ++++ gcc-4.0.2/gcc/config/cris/linux.h +@@ -79,6 +79,25 @@ + #undef CRIS_DEFAULT_CPU_VERSION + #define CRIS_DEFAULT_CPU_VERSION CRIS_CPU_NG + ++#ifdef USE_UCLIBC ++ ++#undef CRIS_SUBTARGET_VERSION ++#define CRIS_SUBTARGET_VERSION " - cris-axis-linux-uclibc" ++ ++#undef CRIS_LINK_SUBTARGET_SPEC ++#define CRIS_LINK_SUBTARGET_SPEC \ ++ "-mcrislinux\ ++ -rpath-link include/asm/../..%s\ ++ %{shared} %{static}\ ++ %{symbolic:-Bdynamic} %{shlib:-Bdynamic} %{static:-Bstatic}\ ++ %{!shared: \ ++ %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}} \ ++ %{!r:%{O2|O3: --gc-sections}}" ++ ++#else /* USE_UCLIBC */ ++ + #undef CRIS_SUBTARGET_VERSION + #define CRIS_SUBTARGET_VERSION " - cris-axis-linux-gnu" + +@@ -93,6 +112,8 @@ + %{!shared:%{!static:%{rdynamic:-export-dynamic}}}\ + %{!r:%{O2|O3: --gc-sections}}" + ++#endif /* USE_UCLIBC */ ++ + + /* Node: Run-time Target */ + +--- gcc-4.0.2/gcc/config/i386/linux.h ++++ gcc-4.0.2/gcc/config/i386/linux.h +@@ -107,6 +107,11 @@ + #define LINK_EMULATION "elf_i386" + #define DYNAMIC_LINKER "/lib/ld-linux.so.2" + ++#ifdef USE_UCLIBC ++#undef DYNAMIC_LINKER ++#define DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#endif ++ + #undef SUBTARGET_EXTRA_SPECS + #define SUBTARGET_EXTRA_SPECS \ + { "link_emulation", LINK_EMULATION },\ +--- gcc-4.0.2/gcc/config/i386/linux64.h ++++ gcc-4.0.2/gcc/config/i386/linux64.h +@@ -54,14 +54,21 @@ + When the -shared link option is used a final link is not being + done. */ + ++#ifdef USE_UCLIBC ++#define ELF32_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#define ELF64_DYNAMIC_LINKER "/lib/ld64-uClibc.so.0" ++#else ++#define ELF32_DYNAMIC_LINKER "/lib/ld-linux.so.2" ++#define ELF64_DYNAMIC_LINKER "/lib64/ld-linux-x86-64.so.2" ++#endif + #undef LINK_SPEC + #define LINK_SPEC "%{!m32:-m elf_x86_64} %{m32:-m elf_i386} \ + %{shared:-shared} \ + %{!shared: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +- %{m32:%{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ +- %{!m32:%{!dynamic-linker:-dynamic-linker /lib64/ld-linux-x86-64.so.2}}} \ ++ %{m32:%{!dynamic-linker:-dynamic-linker " ELF32_DYNAMIC_LINKER "}} \ ++ %{!m32:%{!dynamic-linker:-dynamic-linker " ELF64_DYNAMIC_LINKER "}}} \ + %{static:-static}}" + + #define MULTILIB_DEFAULTS { "m64" } +--- gcc-4.0.2/gcc/config/ia64/linux.h ++++ gcc-4.0.2/gcc/config/ia64/linux.h +@@ -37,13 +37,18 @@ + /* Define this for shared library support because it isn't in the main + linux.h file. */ + ++#ifdef USE_UCLIBC ++#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#else ++#define ELF_DYNAMIC_LINKER "/lib/ld-linux-ia64.so.2" ++#endif + #undef LINK_SPEC + #define LINK_SPEC "\ + %{shared:-shared} \ + %{!shared: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +- %{!dynamic-linker:-dynamic-linker /lib/ld-linux-ia64.so.2}} \ ++ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \ + %{static:-static}}" + + +--- gcc-4.0.2/gcc/config/m68k/linux.h ++++ gcc-4.0.2/gcc/config/m68k/linux.h +@@ -127,12 +127,17 @@ + + /* If ELF is the default format, we should not use /lib/elf. */ + ++#ifdef USE_UCLIBC ++#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#else ++#define ELF_DYNAMIC_LINKER "/lib/ld.so.1" ++#endif + #undef LINK_SPEC + #define LINK_SPEC "-m m68kelf %{shared} \ + %{!shared: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +- %{!dynamic-linker*:-dynamic-linker /lib/ld.so.1}} \ ++ %{!dynamic-linker*:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \ + %{static}}" + + /* For compatibility with linux/a.out */ +--- gcc-4.0.2/gcc/config/mips/linux.h ++++ gcc-4.0.2/gcc/config/mips/linux.h +@@ -108,14 +108,19 @@ + + /* Borrowed from sparc/linux.h */ + #undef LINK_SPEC ++#ifdef USE_UCLIBC ++#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#else ++#define ELF_DYNAMIC_LINKER "/lib/ld.so.1" ++#endif + #define LINK_SPEC \ + "%(endian_spec) \ + %{shared:-shared} \ + %{!shared: \ + %{!ibcs: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +- %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}} \ ++ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \ + %{static:-static}}}" + + #undef SUBTARGET_ASM_SPEC +--- gcc-4.0.2/gcc/config/pa/pa-linux.h ++++ gcc-4.0.2/gcc/config/pa/pa-linux.h +@@ -82,13 +82,18 @@ + /* Define this for shared library support because it isn't in the main + linux.h file. */ + ++#ifdef USE_UCLIBC ++#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#else ++#define ELF_DYNAMIC_LINKER "/lib/ld.so.1" ++#endif + #undef LINK_SPEC + #define LINK_SPEC "\ + %{shared:-shared} \ + %{!shared: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +- %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}} \ ++ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \ + %{static:-static}}" + + /* glibc's profiling functions don't need gcc to allocate counters. */ +--- gcc-4.0.2/gcc/config/rs6000/linux.h ++++ gcc-4.0.2/gcc/config/rs6000/linux.h +@@ -69,7 +69,11 @@ + #define LINK_START_DEFAULT_SPEC "%(link_start_linux)" + + #undef LINK_OS_DEFAULT_SPEC ++#ifdef USE_UCLIBC ++#define LINK_OS_DEFAULT_SPEC "%(link_os_linux_uclibc)" ++#else + #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)" ++#endif + + #define LINK_GCC_C_SEQUENCE_SPEC \ + "%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}" +--- gcc-4.0.2/gcc/config/rs6000/sysv4.h ++++ gcc-4.0.2/gcc/config/rs6000/sysv4.h +@@ -949,6 +949,7 @@ + mcall-linux : %(link_os_linux) ; \ + mcall-gnu : %(link_os_gnu) ; \ + mcall-netbsd : %(link_os_netbsd) ; \ ++ mcall-linux-uclibc : %(link_os_linux_uclibc); \ + mcall-openbsd: %(link_os_openbsd) ; \ + : %(link_os_default) }" + +@@ -1127,6 +1128,10 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld.so.1}}}" + ++#define LINK_OS_LINUX_UCLIBC_SPEC "-m elf32ppclinux %{!shared: %{!static: \ ++ %{rdynamic:-export-dynamic} \ ++ %{!dynamic-linker:-dynamic-linker /lib/ld-uClibc.so.0}}}" ++ + #if defined(HAVE_LD_EH_FRAME_HDR) + # define LINK_EH_SPEC "%{!static:--eh-frame-hdr} " + #endif +@@ -1293,6 +1298,7 @@ + { "link_os_sim", LINK_OS_SIM_SPEC }, \ + { "link_os_freebsd", LINK_OS_FREEBSD_SPEC }, \ + { "link_os_linux", LINK_OS_LINUX_SPEC }, \ ++ { "link_os_linux_uclibc", LINK_OS_LINUX_UCLIBC_SPEC }, \ + { "link_os_gnu", LINK_OS_GNU_SPEC }, \ + { "link_os_netbsd", LINK_OS_NETBSD_SPEC }, \ + { "link_os_openbsd", LINK_OS_OPENBSD_SPEC }, \ +--- gcc-4.0.2/gcc/config/s390/linux.h ++++ gcc-4.0.2/gcc/config/s390/linux.h +@@ -77,6 +77,13 @@ + #define MULTILIB_DEFAULTS { "m31" } + #endif + ++#ifdef USE_UCLIBC ++#define ELF31_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#define ELF64_DYNAMIC_LINKER "/lib/ld64-uClibc.so.0" ++#else ++#define ELF31_DYNAMIC_LINKER "/lib/ld.so.1" ++#define ELF64_DYNAMIC_LINKER "/lib/ld64.so.1" ++#endif + #undef LINK_SPEC + #define LINK_SPEC \ + "%{m31:-m elf_s390}%{m64:-m elf64_s390} \ +@@ -86,8 +93,8 @@ + %{!static: \ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker: \ +- %{m31:-dynamic-linker /lib/ld.so.1} \ +- %{m64:-dynamic-linker /lib/ld64.so.1}}}}" ++ %{m31:-dynamic-linker " ELF31_DYNAMIC_LINKER "} \ ++ %{m64:-dynamic-linker " ELF64_DYNAMIC_LINKER "}}}}" + + + #define TARGET_ASM_FILE_END file_end_indicate_exec_stack +--- gcc-4.0.2/gcc/config/sh/linux.h ++++ gcc-4.0.2/gcc/config/sh/linux.h +@@ -67,11 +67,16 @@ + #undef SUBTARGET_LINK_EMUL_SUFFIX + #define SUBTARGET_LINK_EMUL_SUFFIX "_linux" + #undef SUBTARGET_LINK_SPEC ++#ifdef USE_UCLIBC ++#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#else ++#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2" ++#endif + #define SUBTARGET_LINK_SPEC \ + "%{shared:-shared} \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ ++ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \ + %{static:-static}" + + #undef LIB_SPEC +--- gcc-4.0.2/gcc/config/sparc/linux.h ++++ gcc-4.0.2/gcc/config/sparc/linux.h +@@ -130,14 +130,19 @@ + + /* If ELF is the default format, we should not use /lib/elf. */ + ++#ifdef USE_UCLIBC ++#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#else ++#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2" ++#endif + #undef LINK_SPEC + #define LINK_SPEC "-m elf32_sparc -Y P,/usr/lib %{shared:-shared} \ + %{!mno-relax:%{!r:-relax}} \ + %{!shared: \ + %{!ibcs: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ ++ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \ + %{static:-static}}}" + + /* The sun bundled assembler doesn't accept -Yd, (and neither does gas). +--- gcc-4.0.2/gcc/config/sparc/linux64.h ++++ gcc-4.0.2/gcc/config/sparc/linux64.h +@@ -167,12 +166,17 @@ + { "link_arch_default", LINK_ARCH_DEFAULT_SPEC }, \ + { "link_arch", LINK_ARCH_SPEC }, + ++#ifdef USE_UCLIBC ++#define ELF_DYNAMIC_LINKER "/lib/ld-uClibc.so.0" ++#else ++#define ELF_DYNAMIC_LINKER "/lib/ld-linux.so.2" ++#endif + #define LINK_ARCH32_SPEC "-m elf32_sparc -Y P,/usr/lib %{shared:-shared} \ + %{!shared: \ + %{!ibcs: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +- %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \ ++ %{!dynamic-linker:-dynamic-linker " ELF_DYNAMIC_LINKER "}} \ + %{static:-static}}} \ + " + +--- gcc-4.0.2/libtool.m4 ++++ gcc-4.0.2/libtool.m4 +@@ -682,6 +682,11 @@ + lt_cv_deplibs_check_method=pass_all + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + [lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'] +--- gcc-4.0.2/ltconfig ++++ gcc-4.0.2/ltconfig +@@ -603,6 +603,7 @@ + + # Transform linux* to *-*-linux-gnu*, to support old configure scripts. + case $host_os in ++linux-uclibc*) ;; + linux-gnu*) ;; + linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'` + esac +@@ -1274,6 +1275,23 @@ + dynamic_linker='GNU/Linux ld.so' + ;; + ++linux-uclibc*) ++ version_type=linux ++ need_lib_prefix=no ++ need_version=no ++ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so' ++ soname_spec='${libname}${release}.so$major' ++ finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' ++ shlibpath_var=LD_LIBRARY_PATH ++ shlibpath_overrides_runpath=no ++ # This implies no fast_install, which is unacceptable. ++ # Some rework will be needed to allow for fast_install ++ # before this can be enabled. ++ hardcode_into_libs=yes ++ # Assume using the uClibc dynamic linker. ++ dynamic_linker="uClibc ld.so" ++ ;; ++ + netbsd*) + need_lib_prefix=no + need_version=no +--- gcc-4.0.2/libffi/configure ++++ gcc-4.0.2/libffi/configure +@@ -3457,6 +3457,11 @@ + lt_cv_deplibs_check_method=pass_all + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +--- gcc-4.0.2/libgfortran/configure ++++ gcc-4.0.2/libgfortran/configure +@@ -3681,6 +3681,11 @@ + lt_cv_deplibs_check_method=pass_all + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +--- gcc-4.0.2/libjava/configure ++++ gcc-4.0.2/libjava/configure +@@ -4351,6 +4351,11 @@ + lt_cv_deplibs_check_method=pass_all + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +--- gcc-4.0.2/libmudflap/configure ++++ gcc-4.0.2/libmudflap/configure +@@ -5380,6 +5380,11 @@ + lt_cv_deplibs_check_method=pass_all + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +--- gcc-4.0.2/libobjc/configure ++++ gcc-4.0.2/libobjc/configure +@@ -3283,6 +3283,11 @@ + lt_cv_deplibs_check_method=pass_all + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +--- gcc-4.0.2/boehm-gc/configure ++++ gcc-4.0.2/boehm-gc/configure +@@ -4320,6 +4320,11 @@ + lt_cv_deplibs_check_method=pass_all + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +--- gcc-4.0.2/configure ++++ gcc-4.0.2/configure +@@ -1141,7 +1141,7 @@ + ;; + "") + case "${target}" in +- *-*-linux*-gnu | *-*-gnu* | *-*-k*bsd*-gnu) ++ *-*-linux*-gnu | *-*-gnu* | *-*-k*bsd*-gnu | *-*-linux-uclibc*) + # Enable libmudflap by default in GNU and friends. + ;; + *-*-freebsd*) +--- gcc-4.0.2/configure.in ++++ gcc-4.0.2/configure.in +@@ -350,7 +350,7 @@ + ;; + "") + case "${target}" in +- *-*-linux*-gnu | *-*-gnu* | *-*-k*bsd*-gnu) ++ *-*-linux*-gnu | *-*-gnu* | *-*-k*bsd*-gnu | *-*-linux-uclibc*) + # Enable libmudflap by default in GNU and friends. + ;; + *-*-freebsd*) +--- gcc-4.0.2/contrib/regression/objs-gcc.sh ++++ gcc-4.0.2/contrib/regression/objs-gcc.sh +@@ -105,6 +105,10 @@ + then + make all-gdb all-dejagnu all-ld || exit 1 + make install-gdb install-dejagnu install-ld || exit 1 ++elif [ $H_REAL_TARGET = $H_REAL_HOST -a $H_REAL_TARGET = i686-pc-linux-uclibc ] ++ then ++ make all-gdb all-dejagnu all-ld || exit 1 ++ make install-gdb install-dejagnu install-ld || exit 1 + elif [ $H_REAL_TARGET = $H_REAL_HOST ] ; then + make bootstrap || exit 1 + make install || exit 1 +--- gcc-4.0.2/zlib/configure ++++ gcc-4.0.2/zlib/configure +@@ -3426,6 +3426,11 @@ + lt_cv_deplibs_check_method=pass_all + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' diff --git a/meta/packages/gcc/gcc-4.0.2/200-uclibc-locale.patch b/meta/packages/gcc/gcc-4.0.2/200-uclibc-locale.patch new file mode 100644 index 000000000..8be03a544 --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/200-uclibc-locale.patch @@ -0,0 +1,3240 @@ +From: +http://buildroot.uclibc.org/cgi-bin/viewcvs.cgi/*checkout*/trunk/buildroot/toolchain/gcc/4.0.2/200-uclibc-locale.patch?rev=11715 + +diff -urN gcc-4.0.0-100/libstdc++-v3/acinclude.m4 gcc-4.0.0/libstdc++-v3/acinclude.m4 +--- gcc-4.0.0-100/libstdc++-v3/acinclude.m4 2005-04-30 13:06:53.000000000 -0500 ++++ gcc-4.0.0/libstdc++-v3/acinclude.m4 2005-04-28 20:19:01.000000000 -0500 +@@ -1104,7 +1104,7 @@ + AC_MSG_CHECKING([for C locale to use]) + GLIBCXX_ENABLE(clocale,auto,[@<:@=MODEL@:>@], + [use MODEL for target locale package], +- [permit generic|gnu|ieee_1003.1-2001|yes|no|auto]) ++ [permit generic|gnu|ieee_1003.1-2001|uclibc|yes|no|auto]) + + # If they didn't use this option switch, or if they specified --enable + # with no specific model, we'll have to look for one. If they +@@ -1120,6 +1120,9 @@ + # Default to "generic". + if test $enable_clocale_flag = auto; then + case ${target_os} in ++ *-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + linux* | gnu* | kfreebsd*-gnu | knetbsd*-gnu) + AC_EGREP_CPP([_GLIBCXX_ok], [ + #include +@@ -1263,6 +1266,40 @@ + CTIME_CC=config/locale/generic/time_members.cc + CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h + ;; ++ uclibc) ++ AC_MSG_RESULT(uclibc) ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ AC_CHECK_PROG(check_msgfmt, msgfmt, yes, no) ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcxx_MOFILES="$glibcxx_MOFILES $ling.mo"; \ ++ glibcxx_POFILES="$glibcxx_POFILES $ling.po"; \ ++ done ++ AC_SUBST(glibcxx_MOFILES) ++ AC_SUBST(glibcxx_POFILES) ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + esac + + # This is where the testsuite looks for locale catalogs, using the +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/c++locale_internal.h gcc-4.0.0/libstdc++-v3/config/locale/uclibc/c++locale_internal.h +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/c++locale_internal.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/c++locale_internal.h 2005-04-28 01:13:15.000000000 -0500 +@@ -0,0 +1,59 @@ ++// Prototypes for GLIBC thread locale __-prefixed functions -*- C++ -*- ++ ++// Copyright (C) 2002, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// Written by Jakub Jelinek ++ ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning clean this up ++#endif ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ ++extern "C" __typeof(iswctype_l) __iswctype_l; ++extern "C" __typeof(nl_langinfo_l) __nl_langinfo_l; ++extern "C" __typeof(strcoll_l) __strcoll_l; ++extern "C" __typeof(strftime_l) __strftime_l; ++extern "C" __typeof(strtod_l) __strtod_l; ++extern "C" __typeof(strtof_l) __strtof_l; ++extern "C" __typeof(strtold_l) __strtold_l; ++extern "C" __typeof(strxfrm_l) __strxfrm_l; ++extern "C" __typeof(towlower_l) __towlower_l; ++extern "C" __typeof(towupper_l) __towupper_l; ++extern "C" __typeof(wcscoll_l) __wcscoll_l; ++extern "C" __typeof(wcsftime_l) __wcsftime_l; ++extern "C" __typeof(wcsxfrm_l) __wcsxfrm_l; ++extern "C" __typeof(wctype_l) __wctype_l; ++extern "C" __typeof(newlocale) __newlocale; ++extern "C" __typeof(freelocale) __freelocale; ++extern "C" __typeof(duplocale) __duplocale; ++extern "C" __typeof(uselocale) __uselocale; ++ ++#endif // GLIBC 2.3 and later +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/c_locale.cc gcc-4.0.0/libstdc++-v3/config/locale/uclibc/c_locale.cc +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/c_locale.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/c_locale.cc 2005-04-28 01:13:15.000000000 -0500 +@@ -0,0 +1,160 @@ ++// Wrapper for underlying C-language localization -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.8 Standard locale categories. ++// ++ ++// Written by Benjamin Kosnik ++ ++#include // For errno ++#include ++#include ++#include ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __strtol_l(S, E, B, L) strtol((S), (E), (B)) ++#define __strtoul_l(S, E, B, L) strtoul((S), (E), (B)) ++#define __strtoll_l(S, E, B, L) strtoll((S), (E), (B)) ++#define __strtoull_l(S, E, B, L) strtoull((S), (E), (B)) ++#define __strtof_l(S, E, L) strtof((S), (E)) ++#define __strtod_l(S, E, L) strtod((S), (E)) ++#define __strtold_l(S, E, L) strtold((S), (E)) ++#warning should dummy __newlocale check for C|POSIX ? ++#define __newlocale(a, b, c) NULL ++#define __freelocale(a) ((void)0) ++#define __duplocale(a) __c_locale() ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ __convert_to_v(const char* __s, float& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ float __f = __strtof_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && errno != ERANGE) ++ __v = __f; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, double& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ double __d = __strtod_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && errno != ERANGE) ++ __v = __d; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ template<> ++ void ++ __convert_to_v(const char* __s, long double& __v, ios_base::iostate& __err, ++ const __c_locale& __cloc) ++ { ++ if (!(__err & ios_base::failbit)) ++ { ++ char* __sanity; ++ errno = 0; ++ long double __ld = __strtold_l(__s, &__sanity, __cloc); ++ if (__sanity != __s && errno != ERANGE) ++ __v = __ld; ++ else ++ __err |= ios_base::failbit; ++ } ++ } ++ ++ void ++ locale::facet::_S_create_c_locale(__c_locale& __cloc, const char* __s, ++ __c_locale __old) ++ { ++ __cloc = __newlocale(1 << LC_ALL, __s, __old); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ if (!__cloc) ++ { ++ // This named locale is not supported by the underlying OS. ++ __throw_runtime_error(__N("locale::facet::_S_create_c_locale " ++ "name not valid")); ++ } ++#endif ++ } ++ ++ void ++ locale::facet::_S_destroy_c_locale(__c_locale& __cloc) ++ { ++ if (_S_get_c_locale() != __cloc) ++ __freelocale(__cloc); ++ } ++ ++ __c_locale ++ locale::facet::_S_clone_c_locale(__c_locale& __cloc) ++ { return __duplocale(__cloc); } ++} // namespace std ++ ++namespace __gnu_cxx ++{ ++ const char* const category_names[6 + _GLIBCXX_NUM_CATEGORIES] = ++ { ++ "LC_CTYPE", ++ "LC_NUMERIC", ++ "LC_TIME", ++ "LC_COLLATE", ++ "LC_MONETARY", ++ "LC_MESSAGES", ++#if _GLIBCXX_NUM_CATEGORIES != 0 ++ "LC_PAPER", ++ "LC_NAME", ++ "LC_ADDRESS", ++ "LC_TELEPHONE", ++ "LC_MEASUREMENT", ++ "LC_IDENTIFICATION" ++#endif ++ }; ++} ++ ++namespace std ++{ ++ const char* const* const locale::_S_categories = __gnu_cxx::category_names; ++} // namespace std +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/c_locale.h gcc-4.0.0/libstdc++-v3/config/locale/uclibc/c_locale.h +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/c_locale.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/c_locale.h 2005-04-28 01:13:15.000000000 -0500 +@@ -0,0 +1,115 @@ ++// Wrapper for underlying C-language localization -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.8 Standard locale categories. ++// ++ ++// Written by Benjamin Kosnik ++ ++#ifndef _C_LOCALE_H ++#define _C_LOCALE_H 1 ++ ++#pragma GCC system_header ++ ++#include // get std::strlen ++#include // get std::snprintf or std::sprintf ++#include ++#include // For codecvt ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC_HAS_LOCALE__ ++#include // For codecvt using iconv, iconv_t ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++#include // For messages ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning what is _GLIBCXX_C_LOCALE_GNU for ++#endif ++#define _GLIBCXX_C_LOCALE_GNU 1 ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix categories ++#endif ++// #define _GLIBCXX_NUM_CATEGORIES 6 ++#define _GLIBCXX_NUM_CATEGORIES 0 ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++namespace __gnu_cxx ++{ ++ extern "C" __typeof(uselocale) __uselocale; ++} ++#endif ++ ++namespace std ++{ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ typedef __locale_t __c_locale; ++#else ++ typedef int* __c_locale; ++#endif ++ ++ // Convert numeric value of type _Tv to string and return length of ++ // string. If snprintf is available use it, otherwise fall back to ++ // the unsafe sprintf which, in general, can be dangerous and should ++ // be avoided. ++ template ++ int ++ __convert_from_v(char* __out, const int __size, const char* __fmt, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ _Tv __v, const __c_locale& __cloc, int __prec) ++ { ++ __c_locale __old = __gnu_cxx::__uselocale(__cloc); ++#else ++ _Tv __v, const __c_locale&, int __prec) ++ { ++# ifdef __UCLIBC_HAS_LOCALE__ ++ char* __old = std::setlocale(LC_ALL, NULL); ++ char* __sav = new char[std::strlen(__old) + 1]; ++ std::strcpy(__sav, __old); ++ std::setlocale(LC_ALL, "C"); ++# endif ++#endif ++ ++ const int __ret = std::snprintf(__out, __size, __fmt, __prec, __v); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __gnu_cxx::__uselocale(__old); ++#elif defined __UCLIBC_HAS_LOCALE__ ++ std::setlocale(LC_ALL, __sav); ++ delete [] __sav; ++#endif ++ return __ret; ++ } ++} ++ ++#endif +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/codecvt_members.cc gcc-4.0.0/libstdc++-v3/config/locale/uclibc/codecvt_members.cc +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/codecvt_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/codecvt_members.cc 2005-04-28 01:13:15.000000000 -0500 +@@ -0,0 +1,306 @@ ++// std::codecvt implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.1.5 - Template class codecvt ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++namespace std ++{ ++ // Specializations. ++#ifdef _GLIBCXX_USE_WCHAR_T ++ codecvt_base::result ++ codecvt:: ++ do_out(state_type& __state, const intern_type* __from, ++ const intern_type* __from_end, const intern_type*& __from_next, ++ extern_type* __to, extern_type* __to_end, ++ extern_type*& __to_next) const ++ { ++ result __ret = ok; ++ state_type __tmp_state(__state); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ ++ // wcsnrtombs is *very* fast but stops if encounters NUL characters: ++ // in case we fall back to wcrtomb and then continue, in a loop. ++ // NB: wcsnrtombs is a GNU extension ++ for (__from_next = __from, __to_next = __to; ++ __from_next < __from_end && __to_next < __to_end ++ && __ret == ok;) ++ { ++ const intern_type* __from_chunk_end = wmemchr(__from_next, L'\0', ++ __from_end - __from_next); ++ if (!__from_chunk_end) ++ __from_chunk_end = __from_end; ++ ++ __from = __from_next; ++ const size_t __conv = wcsnrtombs(__to_next, &__from_next, ++ __from_chunk_end - __from_next, ++ __to_end - __to_next, &__state); ++ if (__conv == static_cast(-1)) ++ { ++ // In case of error, in order to stop at the exact place we ++ // have to start again from the beginning with a series of ++ // wcrtomb. ++ for (; __from < __from_next; ++__from) ++ __to_next += wcrtomb(__to_next, *__from, &__tmp_state); ++ __state = __tmp_state; ++ __ret = error; ++ } ++ else if (__from_next && __from_next < __from_chunk_end) ++ { ++ __to_next += __conv; ++ __ret = partial; ++ } ++ else ++ { ++ __from_next = __from_chunk_end; ++ __to_next += __conv; ++ } ++ ++ if (__from_next < __from_end && __ret == ok) ++ { ++ extern_type __buf[MB_LEN_MAX]; ++ __tmp_state = __state; ++ const size_t __conv = wcrtomb(__buf, *__from_next, &__tmp_state); ++ if (__conv > static_cast(__to_end - __to_next)) ++ __ret = partial; ++ else ++ { ++ memcpy(__to_next, __buf, __conv); ++ __state = __tmp_state; ++ __to_next += __conv; ++ ++__from_next; ++ } ++ } ++ } ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ return __ret; ++ } ++ ++ codecvt_base::result ++ codecvt:: ++ do_in(state_type& __state, const extern_type* __from, ++ const extern_type* __from_end, const extern_type*& __from_next, ++ intern_type* __to, intern_type* __to_end, ++ intern_type*& __to_next) const ++ { ++ result __ret = ok; ++ state_type __tmp_state(__state); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ ++ // mbsnrtowcs is *very* fast but stops if encounters NUL characters: ++ // in case we store a L'\0' and then continue, in a loop. ++ // NB: mbsnrtowcs is a GNU extension ++ for (__from_next = __from, __to_next = __to; ++ __from_next < __from_end && __to_next < __to_end ++ && __ret == ok;) ++ { ++ const extern_type* __from_chunk_end; ++ __from_chunk_end = static_cast(memchr(__from_next, '\0', ++ __from_end ++ - __from_next)); ++ if (!__from_chunk_end) ++ __from_chunk_end = __from_end; ++ ++ __from = __from_next; ++ size_t __conv = mbsnrtowcs(__to_next, &__from_next, ++ __from_chunk_end - __from_next, ++ __to_end - __to_next, &__state); ++ if (__conv == static_cast(-1)) ++ { ++ // In case of error, in order to stop at the exact place we ++ // have to start again from the beginning with a series of ++ // mbrtowc. ++ for (;; ++__to_next, __from += __conv) ++ { ++ __conv = mbrtowc(__to_next, __from, __from_end - __from, ++ &__tmp_state); ++ if (__conv == static_cast(-1) ++ || __conv == static_cast(-2)) ++ break; ++ } ++ __from_next = __from; ++ __state = __tmp_state; ++ __ret = error; ++ } ++ else if (__from_next && __from_next < __from_chunk_end) ++ { ++ // It is unclear what to return in this case (see DR 382). ++ __to_next += __conv; ++ __ret = partial; ++ } ++ else ++ { ++ __from_next = __from_chunk_end; ++ __to_next += __conv; ++ } ++ ++ if (__from_next < __from_end && __ret == ok) ++ { ++ if (__to_next < __to_end) ++ { ++ // XXX Probably wrong for stateful encodings ++ __tmp_state = __state; ++ ++__from_next; ++ *__to_next++ = L'\0'; ++ } ++ else ++ __ret = partial; ++ } ++ } ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ return __ret; ++ } ++ ++ int ++ codecvt:: ++ do_encoding() const throw() ++ { ++ // XXX This implementation assumes that the encoding is ++ // stateless and is either single-byte or variable-width. ++ int __ret = 0; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ if (MB_CUR_MAX == 1) ++ __ret = 1; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __ret; ++ } ++ ++ int ++ codecvt:: ++ do_max_length() const throw() ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ // XXX Probably wrong for stateful encodings. ++ int __ret = MB_CUR_MAX; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __ret; ++ } ++ ++ int ++ codecvt:: ++ do_length(state_type& __state, const extern_type* __from, ++ const extern_type* __end, size_t __max) const ++ { ++ int __ret = 0; ++ state_type __tmp_state(__state); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_codecvt); ++#endif ++ ++ // mbsnrtowcs is *very* fast but stops if encounters NUL characters: ++ // in case we advance past it and then continue, in a loop. ++ // NB: mbsnrtowcs is a GNU extension ++ ++ // A dummy internal buffer is needed in order for mbsnrtocws to consider ++ // its fourth parameter (it wouldn't with NULL as first parameter). ++ wchar_t* __to = static_cast(__builtin_alloca(sizeof(wchar_t) ++ * __max)); ++ while (__from < __end && __max) ++ { ++ const extern_type* __from_chunk_end; ++ __from_chunk_end = static_cast(memchr(__from, '\0', ++ __end ++ - __from)); ++ if (!__from_chunk_end) ++ __from_chunk_end = __end; ++ ++ const extern_type* __tmp_from = __from; ++ size_t __conv = mbsnrtowcs(__to, &__from, ++ __from_chunk_end - __from, ++ __max, &__state); ++ if (__conv == static_cast(-1)) ++ { ++ // In case of error, in order to stop at the exact place we ++ // have to start again from the beginning with a series of ++ // mbrtowc. ++ for (__from = __tmp_from;; __from += __conv) ++ { ++ __conv = mbrtowc(NULL, __from, __end - __from, ++ &__tmp_state); ++ if (__conv == static_cast(-1) ++ || __conv == static_cast(-2)) ++ break; ++ } ++ __state = __tmp_state; ++ __ret += __from - __tmp_from; ++ break; ++ } ++ if (!__from) ++ __from = __from_chunk_end; ++ ++ __ret += __from - __tmp_from; ++ __max -= __conv; ++ ++ if (__from < __end && __max) ++ { ++ // XXX Probably wrong for stateful encodings ++ __tmp_state = __state; ++ ++__from; ++ ++__ret; ++ --__max; ++ } ++ } ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ ++ return __ret; ++ } ++#endif ++} +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/collate_members.cc gcc-4.0.0/libstdc++-v3/config/locale/uclibc/collate_members.cc +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/collate_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/collate_members.cc 2005-04-28 01:13:15.000000000 -0500 +@@ -0,0 +1,80 @@ ++// std::collate implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.4.1.2 collate virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __strcoll_l(S1, S2, L) strcoll((S1), (S2)) ++#define __strxfrm_l(S1, S2, N, L) strxfrm((S1), (S2), (N)) ++#define __wcscoll_l(S1, S2, L) wcscoll((S1), (S2)) ++#define __wcsxfrm_l(S1, S2, N, L) wcsxfrm((S1), (S2), (N)) ++#endif ++ ++namespace std ++{ ++ // These are basically extensions to char_traits, and perhaps should ++ // be put there instead of here. ++ template<> ++ int ++ collate::_M_compare(const char* __one, const char* __two) const ++ { ++ int __cmp = __strcoll_l(__one, __two, _M_c_locale_collate); ++ return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0); ++ } ++ ++ template<> ++ size_t ++ collate::_M_transform(char* __to, const char* __from, ++ size_t __n) const ++ { return __strxfrm_l(__to, __from, __n, _M_c_locale_collate); } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ int ++ collate::_M_compare(const wchar_t* __one, ++ const wchar_t* __two) const ++ { ++ int __cmp = __wcscoll_l(__one, __two, _M_c_locale_collate); ++ return (__cmp >> (8 * sizeof (int) - 2)) | (__cmp != 0); ++ } ++ ++ template<> ++ size_t ++ collate::_M_transform(wchar_t* __to, const wchar_t* __from, ++ size_t __n) const ++ { return __wcsxfrm_l(__to, __from, __n, _M_c_locale_collate); } ++#endif ++} +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/ctype_members.cc gcc-4.0.0/libstdc++-v3/config/locale/uclibc/ctype_members.cc +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/ctype_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/ctype_members.cc 2005-04-28 01:13:15.000000000 -0500 +@@ -0,0 +1,300 @@ ++// std::ctype implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.1.1.2 ctype virtual functions. ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __wctype_l(S, L) wctype((S)) ++#define __towupper_l(C, L) towupper((C)) ++#define __towlower_l(C, L) towlower((C)) ++#define __iswctype_l(C, M, L) iswctype((C), (M)) ++#endif ++ ++namespace std ++{ ++ // NB: The other ctype specializations are in src/locale.cc and ++ // various /config/os/* files. ++ template<> ++ ctype_byname::ctype_byname(const char* __s, size_t __refs) ++ : ctype(0, false, __refs) ++ { ++ if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0) ++ { ++ this->_S_destroy_c_locale(this->_M_c_locale_ctype); ++ this->_S_create_c_locale(this->_M_c_locale_ctype, __s); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ this->_M_toupper = this->_M_c_locale_ctype->__ctype_toupper; ++ this->_M_tolower = this->_M_c_locale_ctype->__ctype_tolower; ++ this->_M_table = this->_M_c_locale_ctype->__ctype_b; ++#endif ++ } ++ } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ ctype::__wmask_type ++ ctype::_M_convert_to_wmask(const mask __m) const ++ { ++ __wmask_type __ret; ++ switch (__m) ++ { ++ case space: ++ __ret = __wctype_l("space", _M_c_locale_ctype); ++ break; ++ case print: ++ __ret = __wctype_l("print", _M_c_locale_ctype); ++ break; ++ case cntrl: ++ __ret = __wctype_l("cntrl", _M_c_locale_ctype); ++ break; ++ case upper: ++ __ret = __wctype_l("upper", _M_c_locale_ctype); ++ break; ++ case lower: ++ __ret = __wctype_l("lower", _M_c_locale_ctype); ++ break; ++ case alpha: ++ __ret = __wctype_l("alpha", _M_c_locale_ctype); ++ break; ++ case digit: ++ __ret = __wctype_l("digit", _M_c_locale_ctype); ++ break; ++ case punct: ++ __ret = __wctype_l("punct", _M_c_locale_ctype); ++ break; ++ case xdigit: ++ __ret = __wctype_l("xdigit", _M_c_locale_ctype); ++ break; ++ case alnum: ++ __ret = __wctype_l("alnum", _M_c_locale_ctype); ++ break; ++ case graph: ++ __ret = __wctype_l("graph", _M_c_locale_ctype); ++ break; ++ default: ++ __ret = __wmask_type(); ++ } ++ return __ret; ++ } ++ ++ wchar_t ++ ctype::do_toupper(wchar_t __c) const ++ { return __towupper_l(__c, _M_c_locale_ctype); } ++ ++ const wchar_t* ++ ctype::do_toupper(wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi) ++ { ++ *__lo = __towupper_l(*__lo, _M_c_locale_ctype); ++ ++__lo; ++ } ++ return __hi; ++ } ++ ++ wchar_t ++ ctype::do_tolower(wchar_t __c) const ++ { return __towlower_l(__c, _M_c_locale_ctype); } ++ ++ const wchar_t* ++ ctype::do_tolower(wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi) ++ { ++ *__lo = __towlower_l(*__lo, _M_c_locale_ctype); ++ ++__lo; ++ } ++ return __hi; ++ } ++ ++ bool ++ ctype:: ++ do_is(mask __m, wchar_t __c) const ++ { ++ // Highest bitmask in ctype_base == 10, but extra in "C" ++ // library for blank. ++ bool __ret = false; ++ const size_t __bitmasksize = 11; ++ for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur) ++ if (__m & _M_bit[__bitcur] ++ && __iswctype_l(__c, _M_wmask[__bitcur], _M_c_locale_ctype)) ++ { ++ __ret = true; ++ break; ++ } ++ return __ret; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_is(const wchar_t* __lo, const wchar_t* __hi, mask* __vec) const ++ { ++ for (; __lo < __hi; ++__vec, ++__lo) ++ { ++ // Highest bitmask in ctype_base == 10, but extra in "C" ++ // library for blank. ++ const size_t __bitmasksize = 11; ++ mask __m = 0; ++ for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur) ++ if (__iswctype_l(*__lo, _M_wmask[__bitcur], _M_c_locale_ctype)) ++ __m |= _M_bit[__bitcur]; ++ *__vec = __m; ++ } ++ return __hi; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_scan_is(mask __m, const wchar_t* __lo, const wchar_t* __hi) const ++ { ++ while (__lo < __hi && !this->do_is(__m, *__lo)) ++ ++__lo; ++ return __lo; ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_scan_not(mask __m, const char_type* __lo, const char_type* __hi) const ++ { ++ while (__lo < __hi && this->do_is(__m, *__lo) != 0) ++ ++__lo; ++ return __lo; ++ } ++ ++ wchar_t ++ ctype:: ++ do_widen(char __c) const ++ { return _M_widen[static_cast(__c)]; } ++ ++ const char* ++ ctype:: ++ do_widen(const char* __lo, const char* __hi, wchar_t* __dest) const ++ { ++ while (__lo < __hi) ++ { ++ *__dest = _M_widen[static_cast(*__lo)]; ++ ++__lo; ++ ++__dest; ++ } ++ return __hi; ++ } ++ ++ char ++ ctype:: ++ do_narrow(wchar_t __wc, char __dfault) const ++ { ++ if (__wc >= 0 && __wc < 128 && _M_narrow_ok) ++ return _M_narrow[__wc]; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ const int __c = wctob(__wc); ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return (__c == EOF ? __dfault : static_cast(__c)); ++ } ++ ++ const wchar_t* ++ ctype:: ++ do_narrow(const wchar_t* __lo, const wchar_t* __hi, char __dfault, ++ char* __dest) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ if (_M_narrow_ok) ++ while (__lo < __hi) ++ { ++ if (*__lo >= 0 && *__lo < 128) ++ *__dest = _M_narrow[*__lo]; ++ else ++ { ++ const int __c = wctob(*__lo); ++ *__dest = (__c == EOF ? __dfault : static_cast(__c)); ++ } ++ ++__lo; ++ ++__dest; ++ } ++ else ++ while (__lo < __hi) ++ { ++ const int __c = wctob(*__lo); ++ *__dest = (__c == EOF ? __dfault : static_cast(__c)); ++ ++__lo; ++ ++__dest; ++ } ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ return __hi; ++ } ++ ++ void ++ ctype::_M_initialize_ctype() ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_ctype); ++#endif ++ wint_t __i; ++ for (__i = 0; __i < 128; ++__i) ++ { ++ const int __c = wctob(__i); ++ if (__c == EOF) ++ break; ++ else ++ _M_narrow[__i] = static_cast(__c); ++ } ++ if (__i == 128) ++ _M_narrow_ok = true; ++ else ++ _M_narrow_ok = false; ++ for (size_t __j = 0; ++ __j < sizeof(_M_widen) / sizeof(wint_t); ++__j) ++ _M_widen[__j] = btowc(__j); ++ ++ for (size_t __k = 0; __k <= 11; ++__k) ++ { ++ _M_bit[__k] = static_cast(_ISbit(__k)); ++ _M_wmask[__k] = _M_convert_to_wmask(_M_bit[__k]); ++ } ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#endif ++ } ++#endif // _GLIBCXX_USE_WCHAR_T ++} +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/messages_members.cc gcc-4.0.0/libstdc++-v3/config/locale/uclibc/messages_members.cc +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/messages_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/messages_members.cc 2005-04-28 01:13:15.000000000 -0500 +@@ -0,0 +1,100 @@ ++// std::messages implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.7.1.2 messages virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix gettext stuff ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++extern "C" char *__dcgettext(const char *domainname, ++ const char *msgid, int category); ++#undef gettext ++#define gettext(msgid) __dcgettext(NULL, msgid, LC_MESSAGES) ++#else ++#undef gettext ++#define gettext(msgid) (msgid) ++#endif ++ ++namespace std ++{ ++ // Specializations. ++ template<> ++ string ++ messages::do_get(catalog, int, int, const string& __dfault) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_messages); ++ const char* __msg = const_cast(gettext(__dfault.c_str())); ++ __uselocale(__old); ++ return string(__msg); ++#elif defined __UCLIBC_HAS_LOCALE__ ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_messages); ++ const char* __msg = gettext(__dfault.c_str()); ++ setlocale(LC_ALL, __old); ++ free(__old); ++ return string(__msg); ++#else ++ const char* __msg = gettext(__dfault.c_str()); ++ return string(__msg); ++#endif ++ } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ wstring ++ messages::do_get(catalog, int, int, const wstring& __dfault) const ++ { ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(_M_c_locale_messages); ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ __uselocale(__old); ++ return _M_convert_from_char(__msg); ++# elif defined __UCLIBC_HAS_LOCALE__ ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_messages); ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ setlocale(LC_ALL, __old); ++ free(__old); ++ return _M_convert_from_char(__msg); ++# else ++ char* __msg = gettext(_M_convert_to_char(__dfault)); ++ return _M_convert_from_char(__msg); ++# endif ++ } ++#endif ++} +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/messages_members.h gcc-4.0.0/libstdc++-v3/config/locale/uclibc/messages_members.h +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/messages_members.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/messages_members.h 2005-04-28 01:13:15.000000000 -0500 +@@ -0,0 +1,118 @@ ++// std::messages implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.7.1.2 messages functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix prototypes for *textdomain funcs ++#endif ++#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__ ++extern "C" char *__textdomain(const char *domainname); ++extern "C" char *__bindtextdomain(const char *domainname, ++ const char *dirname); ++#else ++#undef __textdomain ++#undef __bindtextdomain ++#define __textdomain(D) ((void)0) ++#define __bindtextdomain(D,P) ((void)0) ++#endif ++ ++ // Non-virtual member functions. ++ template ++ messages<_CharT>::messages(size_t __refs) ++ : facet(__refs), _M_c_locale_messages(_S_get_c_locale()), ++ _M_name_messages(_S_get_c_name()) ++ { } ++ ++ template ++ messages<_CharT>::messages(__c_locale __cloc, const char* __s, ++ size_t __refs) ++ : facet(__refs), _M_c_locale_messages(_S_clone_c_locale(__cloc)), ++ _M_name_messages(__s) ++ { ++ char* __tmp = new char[std::strlen(__s) + 1]; ++ std::strcpy(__tmp, __s); ++ _M_name_messages = __tmp; ++ } ++ ++ template ++ typename messages<_CharT>::catalog ++ messages<_CharT>::open(const basic_string& __s, const locale& __loc, ++ const char* __dir) const ++ { ++ __bindtextdomain(__s.c_str(), __dir); ++ return this->do_open(__s, __loc); ++ } ++ ++ // Virtual member functions. ++ template ++ messages<_CharT>::~messages() ++ { ++ if (_M_name_messages != _S_get_c_name()) ++ delete [] _M_name_messages; ++ _S_destroy_c_locale(_M_c_locale_messages); ++ } ++ ++ template ++ typename messages<_CharT>::catalog ++ messages<_CharT>::do_open(const basic_string& __s, ++ const locale&) const ++ { ++ // No error checking is done, assume the catalog exists and can ++ // be used. ++ __textdomain(__s.c_str()); ++ return 0; ++ } ++ ++ template ++ void ++ messages<_CharT>::do_close(catalog) const ++ { } ++ ++ // messages_byname ++ template ++ messages_byname<_CharT>::messages_byname(const char* __s, size_t __refs) ++ : messages<_CharT>(__refs) ++ { ++ if (this->_M_name_messages != locale::facet::_S_get_c_name()) ++ delete [] this->_M_name_messages; ++ char* __tmp = new char[std::strlen(__s) + 1]; ++ std::strcpy(__tmp, __s); ++ this->_M_name_messages = __tmp; ++ ++ if (std::strcmp(__s, "C") != 0 && std::strcmp(__s, "POSIX") != 0) ++ { ++ this->_S_destroy_c_locale(this->_M_c_locale_messages); ++ this->_S_create_c_locale(this->_M_c_locale_messages, __s); ++ } ++ } +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/monetary_members.cc gcc-4.0.0/libstdc++-v3/config/locale/uclibc/monetary_members.cc +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/monetary_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/monetary_members.cc 2005-04-28 01:23:02.000000000 -0500 +@@ -0,0 +1,692 @@ ++// std::moneypunct implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.6.3.2 moneypunct virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning optimize this for uclibc ++#warning tailor for stub locale support ++#endif ++ ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ // Construct and return valid pattern consisting of some combination of: ++ // space none symbol sign value ++ money_base::pattern ++ money_base::_S_construct_pattern(char __precedes, char __space, char __posn) ++ { ++ pattern __ret; ++ ++ // This insanely complicated routine attempts to construct a valid ++ // pattern for use with monyepunct. A couple of invariants: ++ ++ // if (__precedes) symbol -> value ++ // else value -> symbol ++ ++ // if (__space) space ++ // else none ++ ++ // none == never first ++ // space never first or last ++ ++ // Any elegant implementations of this are welcome. ++ switch (__posn) ++ { ++ case 0: ++ case 1: ++ // 1 The sign precedes the value and symbol. ++ __ret.field[0] = sign; ++ if (__space) ++ { ++ // Pattern starts with sign. ++ if (__precedes) ++ { ++ __ret.field[1] = symbol; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[1] = value; ++ __ret.field[3] = symbol; ++ } ++ __ret.field[2] = space; ++ } ++ else ++ { ++ // Pattern starts with sign and ends with none. ++ if (__precedes) ++ { ++ __ret.field[1] = symbol; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[1] = value; ++ __ret.field[2] = symbol; ++ } ++ __ret.field[3] = none; ++ } ++ break; ++ case 2: ++ // 2 The sign follows the value and symbol. ++ if (__space) ++ { ++ // Pattern either ends with sign. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[2] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[2] = symbol; ++ } ++ __ret.field[1] = space; ++ __ret.field[3] = sign; ++ } ++ else ++ { ++ // Pattern ends with sign then none. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = value; ++ } ++ else ++ { ++ __ret.field[0] = value; ++ __ret.field[1] = symbol; ++ } ++ __ret.field[2] = sign; ++ __ret.field[3] = none; ++ } ++ break; ++ case 3: ++ // 3 The sign immediately precedes the symbol. ++ if (__precedes) ++ { ++ __ret.field[0] = sign; ++ __ret.field[1] = symbol; ++ if (__space) ++ { ++ __ret.field[2] = space; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[2] = value; ++ __ret.field[3] = none; ++ } ++ } ++ else ++ { ++ __ret.field[0] = value; ++ if (__space) ++ { ++ __ret.field[1] = space; ++ __ret.field[2] = sign; ++ __ret.field[3] = symbol; ++ } ++ else ++ { ++ __ret.field[1] = sign; ++ __ret.field[2] = symbol; ++ __ret.field[3] = none; ++ } ++ } ++ break; ++ case 4: ++ // 4 The sign immediately follows the symbol. ++ if (__precedes) ++ { ++ __ret.field[0] = symbol; ++ __ret.field[1] = sign; ++ if (__space) ++ { ++ __ret.field[2] = space; ++ __ret.field[3] = value; ++ } ++ else ++ { ++ __ret.field[2] = value; ++ __ret.field[3] = none; ++ } ++ } ++ else ++ { ++ __ret.field[0] = value; ++ if (__space) ++ { ++ __ret.field[1] = space; ++ __ret.field[2] = symbol; ++ __ret.field[3] = sign; ++ } ++ else ++ { ++ __ret.field[1] = symbol; ++ __ret.field[2] = sign; ++ __ret.field[3] = none; ++ } ++ } ++ break; ++ default: ++ __ret = pattern(); ++ } ++ return __ret; ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++ const char*) ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = '.'; ++ _M_data->_M_thousands_sep = ','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = ""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = ""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = ""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ _M_data->_M_atoms[__i] = money_base::_S_atoms[__i]; ++ } ++ else ++ { ++ // Named locale. ++ _M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT, ++ __cloc)); ++ _M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP, ++ __cloc)); ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ _M_data->_M_positive_sign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ _M_data->_M_positive_sign_size = strlen(_M_data->_M_positive_sign); ++ ++ char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc)); ++ if (!__nposn) ++ _M_data->_M_negative_sign = "()"; ++ else ++ _M_data->_M_negative_sign = __nl_langinfo_l(__NEGATIVE_SIGN, ++ __cloc); ++ _M_data->_M_negative_sign_size = strlen(_M_data->_M_negative_sign); ++ ++ // _Intl == true ++ _M_data->_M_curr_symbol = __nl_langinfo_l(__INT_CURR_SYMBOL, __cloc); ++ _M_data->_M_curr_symbol_size = strlen(_M_data->_M_curr_symbol); ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS, ++ __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__INT_P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__INT_P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__INT_P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__INT_N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__INT_N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ } ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++ const char*) ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = '.'; ++ _M_data->_M_thousands_sep = ','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = ""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = ""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = ""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ _M_data->_M_atoms[__i] = money_base::_S_atoms[__i]; ++ } ++ else ++ { ++ // Named locale. ++ _M_data->_M_decimal_point = *(__nl_langinfo_l(__MON_DECIMAL_POINT, ++ __cloc)); ++ _M_data->_M_thousands_sep = *(__nl_langinfo_l(__MON_THOUSANDS_SEP, ++ __cloc)); ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ _M_data->_M_positive_sign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ _M_data->_M_positive_sign_size = strlen(_M_data->_M_positive_sign); ++ ++ char __nposn = *(__nl_langinfo_l(__N_SIGN_POSN, __cloc)); ++ if (!__nposn) ++ _M_data->_M_negative_sign = "()"; ++ else ++ _M_data->_M_negative_sign = __nl_langinfo_l(__NEGATIVE_SIGN, ++ __cloc); ++ _M_data->_M_negative_sign_size = strlen(_M_data->_M_negative_sign); ++ ++ // _Intl == false ++ _M_data->_M_curr_symbol = __nl_langinfo_l(__CURRENCY_SYMBOL, __cloc); ++ _M_data->_M_curr_symbol_size = strlen(_M_data->_M_curr_symbol); ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ } ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { delete _M_data; } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { delete _M_data; } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const char*) ++#else ++ const char* __name) ++#endif ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = L'.'; ++ _M_data->_M_thousands_sep = L','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ // Use ctype::widen code without the facet... ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ _M_data->_M_atoms[__i] = ++ static_cast(money_base::_S_atoms[__i]); ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(__cloc); ++#else ++ // Switch to named locale so that mbsrtowcs will work. ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, __name); ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this... should be monetary ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_data->_M_decimal_point = __cloc->decimal_point_wc; ++ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_data->_M_decimal_point = __global_locale->decimal_point_wc; ++ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ union { char *__s; wchar_t __w; } __u; ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_DECIMAL_POINT_WC, __cloc); ++ _M_data->_M_decimal_point = __u.__w; ++ ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_THOUSANDS_SEP_WC, __cloc); ++ _M_data->_M_thousands_sep = __u.__w; ++#endif ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ ++ const char* __cpossign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ const char* __cnegsign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ const char* __ccurr = __nl_langinfo_l(__INT_CURR_SYMBOL, __cloc); ++ ++ wchar_t* __wcs_ps = 0; ++ wchar_t* __wcs_ns = 0; ++ const char __nposn = *(__nl_langinfo_l(__INT_N_SIGN_POSN, __cloc)); ++ try ++ { ++ mbstate_t __state; ++ size_t __len = strlen(__cpossign); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ps = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ps, &__cpossign, __len, &__state); ++ _M_data->_M_positive_sign = __wcs_ps; ++ } ++ else ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = wcslen(_M_data->_M_positive_sign); ++ ++ __len = strlen(__cnegsign); ++ if (!__nposn) ++ _M_data->_M_negative_sign = L"()"; ++ else if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ns = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ns, &__cnegsign, __len, &__state); ++ _M_data->_M_negative_sign = __wcs_ns; ++ } ++ else ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = wcslen(_M_data->_M_negative_sign); ++ ++ // _Intl == true. ++ __len = strlen(__ccurr); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__ccurr, __len, &__state); ++ _M_data->_M_curr_symbol = __wcs; ++ } ++ else ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = wcslen(_M_data->_M_curr_symbol); ++ } ++ catch (...) ++ { ++ delete _M_data; ++ _M_data = 0; ++ delete __wcs_ps; ++ delete __wcs_ns; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ __throw_exception_again; ++ } ++ ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__INT_FRAC_DIGITS, ++ __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__INT_P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__INT_P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__INT_P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__INT_N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__INT_N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ } ++ ++ template<> ++ void ++ moneypunct::_M_initialize_moneypunct(__c_locale __cloc, ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const char*) ++#else ++ const char* __name) ++#endif ++ { ++ if (!_M_data) ++ _M_data = new __moneypunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_decimal_point = L'.'; ++ _M_data->_M_thousands_sep = L','; ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = 0; ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = 0; ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = 0; ++ _M_data->_M_frac_digits = 0; ++ _M_data->_M_pos_format = money_base::_S_default_pattern; ++ _M_data->_M_neg_format = money_base::_S_default_pattern; ++ ++ // Use ctype::widen code without the facet... ++ for (size_t __i = 0; __i < money_base::_S_end; ++__i) ++ _M_data->_M_atoms[__i] = ++ static_cast(money_base::_S_atoms[__i]); ++ } ++ else ++ { ++ // Named locale. ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __c_locale __old = __uselocale(__cloc); ++#else ++ // Switch to named locale so that mbsrtowcs will work. ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, __name); ++#endif ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this... should be monetary ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_data->_M_decimal_point = __cloc->decimal_point_wc; ++ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_data->_M_decimal_point = __global_locale->decimal_point_wc; ++ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ union { char *__s; wchar_t __w; } __u; ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_DECIMAL_POINT_WC, __cloc); ++ _M_data->_M_decimal_point = __u.__w; ++ ++ __u.__s = __nl_langinfo_l(_NL_MONETARY_THOUSANDS_SEP_WC, __cloc); ++ _M_data->_M_thousands_sep = __u.__w; ++#endif ++ _M_data->_M_grouping = __nl_langinfo_l(__MON_GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ ++ const char* __cpossign = __nl_langinfo_l(__POSITIVE_SIGN, __cloc); ++ const char* __cnegsign = __nl_langinfo_l(__NEGATIVE_SIGN, __cloc); ++ const char* __ccurr = __nl_langinfo_l(__CURRENCY_SYMBOL, __cloc); ++ ++ wchar_t* __wcs_ps = 0; ++ wchar_t* __wcs_ns = 0; ++ const char __nposn = *(__nl_langinfo_l(__N_SIGN_POSN, __cloc)); ++ try ++ { ++ mbstate_t __state; ++ size_t __len; ++ __len = strlen(__cpossign); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ps = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ps, &__cpossign, __len, &__state); ++ _M_data->_M_positive_sign = __wcs_ps; ++ } ++ else ++ _M_data->_M_positive_sign = L""; ++ _M_data->_M_positive_sign_size = wcslen(_M_data->_M_positive_sign); ++ ++ __len = strlen(__cnegsign); ++ if (!__nposn) ++ _M_data->_M_negative_sign = L"()"; ++ else if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ __wcs_ns = new wchar_t[__len]; ++ mbsrtowcs(__wcs_ns, &__cnegsign, __len, &__state); ++ _M_data->_M_negative_sign = __wcs_ns; ++ } ++ else ++ _M_data->_M_negative_sign = L""; ++ _M_data->_M_negative_sign_size = wcslen(_M_data->_M_negative_sign); ++ ++ // _Intl == true. ++ __len = strlen(__ccurr); ++ if (__len) ++ { ++ ++__len; ++ memset(&__state, 0, sizeof(mbstate_t)); ++ wchar_t* __wcs = new wchar_t[__len]; ++ mbsrtowcs(__wcs, &__ccurr, __len, &__state); ++ _M_data->_M_curr_symbol = __wcs; ++ } ++ else ++ _M_data->_M_curr_symbol = L""; ++ _M_data->_M_curr_symbol_size = wcslen(_M_data->_M_curr_symbol); ++ } ++ catch (...) ++ { ++ delete _M_data; ++ _M_data = 0; ++ delete __wcs_ps; ++ delete __wcs_ns; ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ __throw_exception_again; ++ } ++ ++ _M_data->_M_frac_digits = *(__nl_langinfo_l(__FRAC_DIGITS, __cloc)); ++ char __pprecedes = *(__nl_langinfo_l(__P_CS_PRECEDES, __cloc)); ++ char __pspace = *(__nl_langinfo_l(__P_SEP_BY_SPACE, __cloc)); ++ char __pposn = *(__nl_langinfo_l(__P_SIGN_POSN, __cloc)); ++ _M_data->_M_pos_format = _S_construct_pattern(__pprecedes, __pspace, ++ __pposn); ++ char __nprecedes = *(__nl_langinfo_l(__N_CS_PRECEDES, __cloc)); ++ char __nspace = *(__nl_langinfo_l(__N_SEP_BY_SPACE, __cloc)); ++ _M_data->_M_neg_format = _S_construct_pattern(__nprecedes, __nspace, ++ __nposn); ++ ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __uselocale(__old); ++#else ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ } ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { ++ if (_M_data->_M_positive_sign_size) ++ delete [] _M_data->_M_positive_sign; ++ if (_M_data->_M_negative_sign_size ++ && wcscmp(_M_data->_M_negative_sign, L"()") != 0) ++ delete [] _M_data->_M_negative_sign; ++ if (_M_data->_M_curr_symbol_size) ++ delete [] _M_data->_M_curr_symbol; ++ delete _M_data; ++ } ++ ++ template<> ++ moneypunct::~moneypunct() ++ { ++ if (_M_data->_M_positive_sign_size) ++ delete [] _M_data->_M_positive_sign; ++ if (_M_data->_M_negative_sign_size ++ && wcscmp(_M_data->_M_negative_sign, L"()") != 0) ++ delete [] _M_data->_M_negative_sign; ++ if (_M_data->_M_curr_symbol_size) ++ delete [] _M_data->_M_curr_symbol; ++ delete _M_data; ++ } ++#endif ++} +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/numeric_members.cc gcc-4.0.0/libstdc++-v3/config/locale/uclibc/numeric_members.cc +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/numeric_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/numeric_members.cc 2005-04-28 01:20:20.000000000 -0500 +@@ -0,0 +1,173 @@ ++// std::numpunct implementation details, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.3.1.2 numpunct virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#define _LIBC ++#include ++#undef _LIBC ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning tailor for stub locale support ++#endif ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ numpunct::_M_initialize_numpunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __numpunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_use_grouping = false; ++ ++ _M_data->_M_decimal_point = '.'; ++ _M_data->_M_thousands_sep = ','; ++ ++ for (size_t __i = 0; __i < __num_base::_S_oend; ++__i) ++ _M_data->_M_atoms_out[__i] = __num_base::_S_atoms_out[__i]; ++ ++ for (size_t __j = 0; __j < __num_base::_S_iend; ++__j) ++ _M_data->_M_atoms_in[__j] = __num_base::_S_atoms_in[__j]; ++ } ++ else ++ { ++ // Named locale. ++ _M_data->_M_decimal_point = *(__nl_langinfo_l(DECIMAL_POINT, ++ __cloc)); ++ _M_data->_M_thousands_sep = *(__nl_langinfo_l(THOUSANDS_SEP, ++ __cloc)); ++ ++ // Check for NULL, which implies no grouping. ++ if (_M_data->_M_thousands_sep == '\0') ++ _M_data->_M_grouping = ""; ++ else ++ _M_data->_M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ } ++ ++ // NB: There is no way to extact this info from posix locales. ++ // _M_truename = __nl_langinfo_l(YESSTR, __cloc); ++ _M_data->_M_truename = "true"; ++ _M_data->_M_truename_size = 4; ++ // _M_falsename = __nl_langinfo_l(NOSTR, __cloc); ++ _M_data->_M_falsename = "false"; ++ _M_data->_M_falsename_size = 5; ++ } ++ ++ template<> ++ numpunct::~numpunct() ++ { delete _M_data; } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ void ++ numpunct::_M_initialize_numpunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __numpunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_data->_M_grouping = ""; ++ _M_data->_M_grouping_size = 0; ++ _M_data->_M_use_grouping = false; ++ ++ _M_data->_M_decimal_point = L'.'; ++ _M_data->_M_thousands_sep = L','; ++ ++ // Use ctype::widen code without the facet... ++ for (size_t __i = 0; __i < __num_base::_S_oend; ++__i) ++ _M_data->_M_atoms_out[__i] = ++ static_cast(__num_base::_S_atoms_out[__i]); ++ ++ for (size_t __j = 0; __j < __num_base::_S_iend; ++__j) ++ _M_data->_M_atoms_in[__j] = ++ static_cast(__num_base::_S_atoms_in[__j]); ++ } ++ else ++ { ++ // Named locale. ++ // NB: In the GNU model wchar_t is always 32 bit wide. ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning fix this ++#endif ++#ifdef __UCLIBC__ ++# ifdef __UCLIBC_HAS_XLOCALE__ ++ _M_data->_M_decimal_point = __cloc->decimal_point_wc; ++ _M_data->_M_thousands_sep = __cloc->thousands_sep_wc; ++# else ++ _M_data->_M_decimal_point = __global_locale->decimal_point_wc; ++ _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc; ++# endif ++#else ++ union { char *__s; wchar_t __w; } __u; ++ __u.__s = __nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc); ++ _M_data->_M_decimal_point = __u.__w; ++ ++ __u.__s = __nl_langinfo_l(_NL_NUMERIC_THOUSANDS_SEP_WC, __cloc); ++ _M_data->_M_thousands_sep = __u.__w; ++#endif ++ ++ if (_M_data->_M_thousands_sep == L'\0') ++ _M_data->_M_grouping = ""; ++ else ++ _M_data->_M_grouping = __nl_langinfo_l(GROUPING, __cloc); ++ _M_data->_M_grouping_size = strlen(_M_data->_M_grouping); ++ } ++ ++ // NB: There is no way to extact this info from posix locales. ++ // _M_truename = __nl_langinfo_l(YESSTR, __cloc); ++ _M_data->_M_truename = L"true"; ++ _M_data->_M_truename_size = 4; ++ // _M_falsename = __nl_langinfo_l(NOSTR, __cloc); ++ _M_data->_M_falsename = L"false"; ++ _M_data->_M_falsename_size = 5; ++ } ++ ++ template<> ++ numpunct::~numpunct() ++ { delete _M_data; } ++ #endif ++} +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/time_members.cc gcc-4.0.0/libstdc++-v3/config/locale/uclibc/time_members.cc +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/time_members.cc 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/time_members.cc 2005-04-28 01:13:15.000000000 -0500 +@@ -0,0 +1,406 @@ ++// std::time_get, std::time_put implementation, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.5.1.2 - time_get virtual functions ++// ISO C++ 14882: 22.2.5.3.2 - time_put virtual functions ++// ++ ++// Written by Benjamin Kosnik ++ ++#include ++#include ++ ++#ifdef __UCLIBC_MJN3_ONLY__ ++#warning tailor for stub locale support ++#endif ++#ifndef __UCLIBC_HAS_XLOCALE__ ++#define __nl_langinfo_l(N, L) nl_langinfo((N)) ++#endif ++ ++namespace std ++{ ++ template<> ++ void ++ __timepunct:: ++ _M_put(char* __s, size_t __maxlen, const char* __format, ++ const tm* __tm) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ const size_t __len = __strftime_l(__s, __maxlen, __format, __tm, ++ _M_c_locale_timepunct); ++#else ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_timepunct); ++ const size_t __len = strftime(__s, __maxlen, __format, __tm); ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ // Make sure __s is null terminated. ++ if (__len == 0) ++ __s[0] = '\0'; ++ } ++ ++ template<> ++ void ++ __timepunct::_M_initialize_timepunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __timepunct_cache; ++ ++ if (!__cloc) ++ { ++ // "C" locale ++ _M_c_locale_timepunct = _S_get_c_locale(); ++ ++ _M_data->_M_date_format = "%m/%d/%y"; ++ _M_data->_M_date_era_format = "%m/%d/%y"; ++ _M_data->_M_time_format = "%H:%M:%S"; ++ _M_data->_M_time_era_format = "%H:%M:%S"; ++ _M_data->_M_date_time_format = ""; ++ _M_data->_M_date_time_era_format = ""; ++ _M_data->_M_am = "AM"; ++ _M_data->_M_pm = "PM"; ++ _M_data->_M_am_pm_format = ""; ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = "Sunday"; ++ _M_data->_M_day2 = "Monday"; ++ _M_data->_M_day3 = "Tuesday"; ++ _M_data->_M_day4 = "Wednesday"; ++ _M_data->_M_day5 = "Thursday"; ++ _M_data->_M_day6 = "Friday"; ++ _M_data->_M_day7 = "Saturday"; ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = "Sun"; ++ _M_data->_M_aday2 = "Mon"; ++ _M_data->_M_aday3 = "Tue"; ++ _M_data->_M_aday4 = "Wed"; ++ _M_data->_M_aday5 = "Thu"; ++ _M_data->_M_aday6 = "Fri"; ++ _M_data->_M_aday7 = "Sat"; ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = "January"; ++ _M_data->_M_month02 = "February"; ++ _M_data->_M_month03 = "March"; ++ _M_data->_M_month04 = "April"; ++ _M_data->_M_month05 = "May"; ++ _M_data->_M_month06 = "June"; ++ _M_data->_M_month07 = "July"; ++ _M_data->_M_month08 = "August"; ++ _M_data->_M_month09 = "September"; ++ _M_data->_M_month10 = "October"; ++ _M_data->_M_month11 = "November"; ++ _M_data->_M_month12 = "December"; ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = "Jan"; ++ _M_data->_M_amonth02 = "Feb"; ++ _M_data->_M_amonth03 = "Mar"; ++ _M_data->_M_amonth04 = "Apr"; ++ _M_data->_M_amonth05 = "May"; ++ _M_data->_M_amonth06 = "Jun"; ++ _M_data->_M_amonth07 = "Jul"; ++ _M_data->_M_amonth08 = "Aug"; ++ _M_data->_M_amonth09 = "Sep"; ++ _M_data->_M_amonth10 = "Oct"; ++ _M_data->_M_amonth11 = "Nov"; ++ _M_data->_M_amonth12 = "Dec"; ++ } ++ else ++ { ++ _M_c_locale_timepunct = _S_clone_c_locale(__cloc); ++ ++ _M_data->_M_date_format = __nl_langinfo_l(D_FMT, __cloc); ++ _M_data->_M_date_era_format = __nl_langinfo_l(ERA_D_FMT, __cloc); ++ _M_data->_M_time_format = __nl_langinfo_l(T_FMT, __cloc); ++ _M_data->_M_time_era_format = __nl_langinfo_l(ERA_T_FMT, __cloc); ++ _M_data->_M_date_time_format = __nl_langinfo_l(D_T_FMT, __cloc); ++ _M_data->_M_date_time_era_format = __nl_langinfo_l(ERA_D_T_FMT, ++ __cloc); ++ _M_data->_M_am = __nl_langinfo_l(AM_STR, __cloc); ++ _M_data->_M_pm = __nl_langinfo_l(PM_STR, __cloc); ++ _M_data->_M_am_pm_format = __nl_langinfo_l(T_FMT_AMPM, __cloc); ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = __nl_langinfo_l(DAY_1, __cloc); ++ _M_data->_M_day2 = __nl_langinfo_l(DAY_2, __cloc); ++ _M_data->_M_day3 = __nl_langinfo_l(DAY_3, __cloc); ++ _M_data->_M_day4 = __nl_langinfo_l(DAY_4, __cloc); ++ _M_data->_M_day5 = __nl_langinfo_l(DAY_5, __cloc); ++ _M_data->_M_day6 = __nl_langinfo_l(DAY_6, __cloc); ++ _M_data->_M_day7 = __nl_langinfo_l(DAY_7, __cloc); ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = __nl_langinfo_l(ABDAY_1, __cloc); ++ _M_data->_M_aday2 = __nl_langinfo_l(ABDAY_2, __cloc); ++ _M_data->_M_aday3 = __nl_langinfo_l(ABDAY_3, __cloc); ++ _M_data->_M_aday4 = __nl_langinfo_l(ABDAY_4, __cloc); ++ _M_data->_M_aday5 = __nl_langinfo_l(ABDAY_5, __cloc); ++ _M_data->_M_aday6 = __nl_langinfo_l(ABDAY_6, __cloc); ++ _M_data->_M_aday7 = __nl_langinfo_l(ABDAY_7, __cloc); ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = __nl_langinfo_l(MON_1, __cloc); ++ _M_data->_M_month02 = __nl_langinfo_l(MON_2, __cloc); ++ _M_data->_M_month03 = __nl_langinfo_l(MON_3, __cloc); ++ _M_data->_M_month04 = __nl_langinfo_l(MON_4, __cloc); ++ _M_data->_M_month05 = __nl_langinfo_l(MON_5, __cloc); ++ _M_data->_M_month06 = __nl_langinfo_l(MON_6, __cloc); ++ _M_data->_M_month07 = __nl_langinfo_l(MON_7, __cloc); ++ _M_data->_M_month08 = __nl_langinfo_l(MON_8, __cloc); ++ _M_data->_M_month09 = __nl_langinfo_l(MON_9, __cloc); ++ _M_data->_M_month10 = __nl_langinfo_l(MON_10, __cloc); ++ _M_data->_M_month11 = __nl_langinfo_l(MON_11, __cloc); ++ _M_data->_M_month12 = __nl_langinfo_l(MON_12, __cloc); ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = __nl_langinfo_l(ABMON_1, __cloc); ++ _M_data->_M_amonth02 = __nl_langinfo_l(ABMON_2, __cloc); ++ _M_data->_M_amonth03 = __nl_langinfo_l(ABMON_3, __cloc); ++ _M_data->_M_amonth04 = __nl_langinfo_l(ABMON_4, __cloc); ++ _M_data->_M_amonth05 = __nl_langinfo_l(ABMON_5, __cloc); ++ _M_data->_M_amonth06 = __nl_langinfo_l(ABMON_6, __cloc); ++ _M_data->_M_amonth07 = __nl_langinfo_l(ABMON_7, __cloc); ++ _M_data->_M_amonth08 = __nl_langinfo_l(ABMON_8, __cloc); ++ _M_data->_M_amonth09 = __nl_langinfo_l(ABMON_9, __cloc); ++ _M_data->_M_amonth10 = __nl_langinfo_l(ABMON_10, __cloc); ++ _M_data->_M_amonth11 = __nl_langinfo_l(ABMON_11, __cloc); ++ _M_data->_M_amonth12 = __nl_langinfo_l(ABMON_12, __cloc); ++ } ++ } ++ ++#ifdef _GLIBCXX_USE_WCHAR_T ++ template<> ++ void ++ __timepunct:: ++ _M_put(wchar_t* __s, size_t __maxlen, const wchar_t* __format, ++ const tm* __tm) const ++ { ++#ifdef __UCLIBC_HAS_XLOCALE__ ++ __wcsftime_l(__s, __maxlen, __format, __tm, _M_c_locale_timepunct); ++ const size_t __len = __wcsftime_l(__s, __maxlen, __format, __tm, ++ _M_c_locale_timepunct); ++#else ++ char* __old = strdup(setlocale(LC_ALL, NULL)); ++ setlocale(LC_ALL, _M_name_timepunct); ++ const size_t __len = wcsftime(__s, __maxlen, __format, __tm); ++ setlocale(LC_ALL, __old); ++ free(__old); ++#endif ++ // Make sure __s is null terminated. ++ if (__len == 0) ++ __s[0] = L'\0'; ++ } ++ ++ template<> ++ void ++ __timepunct::_M_initialize_timepunct(__c_locale __cloc) ++ { ++ if (!_M_data) ++ _M_data = new __timepunct_cache; ++ ++#warning wide time stuff ++// if (!__cloc) ++ { ++ // "C" locale ++ _M_c_locale_timepunct = _S_get_c_locale(); ++ ++ _M_data->_M_date_format = L"%m/%d/%y"; ++ _M_data->_M_date_era_format = L"%m/%d/%y"; ++ _M_data->_M_time_format = L"%H:%M:%S"; ++ _M_data->_M_time_era_format = L"%H:%M:%S"; ++ _M_data->_M_date_time_format = L""; ++ _M_data->_M_date_time_era_format = L""; ++ _M_data->_M_am = L"AM"; ++ _M_data->_M_pm = L"PM"; ++ _M_data->_M_am_pm_format = L""; ++ ++ // Day names, starting with "C"'s Sunday. ++ _M_data->_M_day1 = L"Sunday"; ++ _M_data->_M_day2 = L"Monday"; ++ _M_data->_M_day3 = L"Tuesday"; ++ _M_data->_M_day4 = L"Wednesday"; ++ _M_data->_M_day5 = L"Thursday"; ++ _M_data->_M_day6 = L"Friday"; ++ _M_data->_M_day7 = L"Saturday"; ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ _M_data->_M_aday1 = L"Sun"; ++ _M_data->_M_aday2 = L"Mon"; ++ _M_data->_M_aday3 = L"Tue"; ++ _M_data->_M_aday4 = L"Wed"; ++ _M_data->_M_aday5 = L"Thu"; ++ _M_data->_M_aday6 = L"Fri"; ++ _M_data->_M_aday7 = L"Sat"; ++ ++ // Month names, starting with "C"'s January. ++ _M_data->_M_month01 = L"January"; ++ _M_data->_M_month02 = L"February"; ++ _M_data->_M_month03 = L"March"; ++ _M_data->_M_month04 = L"April"; ++ _M_data->_M_month05 = L"May"; ++ _M_data->_M_month06 = L"June"; ++ _M_data->_M_month07 = L"July"; ++ _M_data->_M_month08 = L"August"; ++ _M_data->_M_month09 = L"September"; ++ _M_data->_M_month10 = L"October"; ++ _M_data->_M_month11 = L"November"; ++ _M_data->_M_month12 = L"December"; ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ _M_data->_M_amonth01 = L"Jan"; ++ _M_data->_M_amonth02 = L"Feb"; ++ _M_data->_M_amonth03 = L"Mar"; ++ _M_data->_M_amonth04 = L"Apr"; ++ _M_data->_M_amonth05 = L"May"; ++ _M_data->_M_amonth06 = L"Jun"; ++ _M_data->_M_amonth07 = L"Jul"; ++ _M_data->_M_amonth08 = L"Aug"; ++ _M_data->_M_amonth09 = L"Sep"; ++ _M_data->_M_amonth10 = L"Oct"; ++ _M_data->_M_amonth11 = L"Nov"; ++ _M_data->_M_amonth12 = L"Dec"; ++ } ++#if 0 ++ else ++ { ++ _M_c_locale_timepunct = _S_clone_c_locale(__cloc); ++ ++ union { char *__s; wchar_t *__w; } __u; ++ ++ __u.__s = __nl_langinfo_l(_NL_WD_FMT, __cloc); ++ _M_data->_M_date_format = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WERA_D_FMT, __cloc); ++ _M_data->_M_date_era_format = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WT_FMT, __cloc); ++ _M_data->_M_time_format = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WERA_T_FMT, __cloc); ++ _M_data->_M_time_era_format = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WD_T_FMT, __cloc); ++ _M_data->_M_date_time_format = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WERA_D_T_FMT, __cloc); ++ _M_data->_M_date_time_era_format = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WAM_STR, __cloc); ++ _M_data->_M_am = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WPM_STR, __cloc); ++ _M_data->_M_pm = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WT_FMT_AMPM, __cloc); ++ _M_data->_M_am_pm_format = __u.__w; ++ ++ // Day names, starting with "C"'s Sunday. ++ __u.__s = __nl_langinfo_l(_NL_WDAY_1, __cloc); ++ _M_data->_M_day1 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WDAY_2, __cloc); ++ _M_data->_M_day2 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WDAY_3, __cloc); ++ _M_data->_M_day3 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WDAY_4, __cloc); ++ _M_data->_M_day4 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WDAY_5, __cloc); ++ _M_data->_M_day5 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WDAY_6, __cloc); ++ _M_data->_M_day6 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WDAY_7, __cloc); ++ _M_data->_M_day7 = __u.__w; ++ ++ // Abbreviated day names, starting with "C"'s Sun. ++ __u.__s = __nl_langinfo_l(_NL_WABDAY_1, __cloc); ++ _M_data->_M_aday1 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABDAY_2, __cloc); ++ _M_data->_M_aday2 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABDAY_3, __cloc); ++ _M_data->_M_aday3 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABDAY_4, __cloc); ++ _M_data->_M_aday4 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABDAY_5, __cloc); ++ _M_data->_M_aday5 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABDAY_6, __cloc); ++ _M_data->_M_aday6 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABDAY_7, __cloc); ++ _M_data->_M_aday7 = __u.__w; ++ ++ // Month names, starting with "C"'s January. ++ __u.__s = __nl_langinfo_l(_NL_WMON_1, __cloc); ++ _M_data->_M_month01 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_2, __cloc); ++ _M_data->_M_month02 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_3, __cloc); ++ _M_data->_M_month03 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_4, __cloc); ++ _M_data->_M_month04 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_5, __cloc); ++ _M_data->_M_month05 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_6, __cloc); ++ _M_data->_M_month06 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_7, __cloc); ++ _M_data->_M_month07 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_8, __cloc); ++ _M_data->_M_month08 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_9, __cloc); ++ _M_data->_M_month09 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_10, __cloc); ++ _M_data->_M_month10 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_11, __cloc); ++ _M_data->_M_month11 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WMON_12, __cloc); ++ _M_data->_M_month12 = __u.__w; ++ ++ // Abbreviated month names, starting with "C"'s Jan. ++ __u.__s = __nl_langinfo_l(_NL_WABMON_1, __cloc); ++ _M_data->_M_amonth01 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_2, __cloc); ++ _M_data->_M_amonth02 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_3, __cloc); ++ _M_data->_M_amonth03 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_4, __cloc); ++ _M_data->_M_amonth04 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_5, __cloc); ++ _M_data->_M_amonth05 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_6, __cloc); ++ _M_data->_M_amonth06 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_7, __cloc); ++ _M_data->_M_amonth07 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_8, __cloc); ++ _M_data->_M_amonth08 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_9, __cloc); ++ _M_data->_M_amonth09 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_10, __cloc); ++ _M_data->_M_amonth10 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_11, __cloc); ++ _M_data->_M_amonth11 = __u.__w; ++ __u.__s = __nl_langinfo_l(_NL_WABMON_12, __cloc); ++ _M_data->_M_amonth12 = __u.__w; ++ } ++#endif // 0 ++ } ++#endif ++} +diff -urN gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/time_members.h gcc-4.0.0/libstdc++-v3/config/locale/uclibc/time_members.h +--- gcc-4.0.0-100/libstdc++-v3/config/locale/uclibc/time_members.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/locale/uclibc/time_members.h 2004-05-22 18:46:31.000000000 -0500 +@@ -0,0 +1,68 @@ ++// std::time_get, std::time_put implementation, GNU version -*- C++ -*- ++ ++// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.2.5.1.2 - time_get functions ++// ISO C++ 14882: 22.2.5.3.2 - time_put functions ++// ++ ++// Written by Benjamin Kosnik ++ ++ template ++ __timepunct<_CharT>::__timepunct(size_t __refs) ++ : facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL), ++ _M_name_timepunct(_S_get_c_name()) ++ { _M_initialize_timepunct(); } ++ ++ template ++ __timepunct<_CharT>::__timepunct(__cache_type* __cache, size_t __refs) ++ : facet(__refs), _M_data(__cache), _M_c_locale_timepunct(NULL), ++ _M_name_timepunct(_S_get_c_name()) ++ { _M_initialize_timepunct(); } ++ ++ template ++ __timepunct<_CharT>::__timepunct(__c_locale __cloc, const char* __s, ++ size_t __refs) ++ : facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL), ++ _M_name_timepunct(__s) ++ { ++ char* __tmp = new char[std::strlen(__s) + 1]; ++ std::strcpy(__tmp, __s); ++ _M_name_timepunct = __tmp; ++ _M_initialize_timepunct(__cloc); ++ } ++ ++ template ++ __timepunct<_CharT>::~__timepunct() ++ { ++ if (_M_name_timepunct != _S_get_c_name()) ++ delete [] _M_name_timepunct; ++ delete _M_data; ++ _S_destroy_c_locale(_M_c_locale_timepunct); ++ } +diff -urN gcc-4.0.0-100/libstdc++-v3/config/os/uclibc/ctype_base.h gcc-4.0.0/libstdc++-v3/config/os/uclibc/ctype_base.h +--- gcc-4.0.0-100/libstdc++-v3/config/os/uclibc/ctype_base.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/os/uclibc/ctype_base.h 2005-04-28 01:10:27.000000000 -0500 +@@ -0,0 +1,64 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 1997, 1998, 1999, 2000, 2002, 2003, 2004 ++// Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++/** @file ctype_base.h ++ * This is an internal header file, included by other library headers. ++ * You should not attempt to use it directly. ++ */ ++ ++// Information as gleaned from /usr/include/ctype.h ++ ++ /// @brief Base class for ctype. ++ struct ctype_base ++ { ++ // Note: In uClibc, the following two types depend on configuration. ++ ++ // Non-standard typedefs. ++ typedef const __ctype_touplow_t* __to_type; ++ ++ // NB: Offsets into ctype::_M_table force a particular size ++ // on the mask type. Because of this, we don't use an enum. ++ typedef __ctype_mask_t mask; ++ static const mask upper = _ISupper; ++ static const mask lower = _ISlower; ++ static const mask alpha = _ISalpha; ++ static const mask digit = _ISdigit; ++ static const mask xdigit = _ISxdigit; ++ static const mask space = _ISspace; ++ static const mask print = _ISprint; ++ static const mask graph = _ISalpha | _ISdigit | _ISpunct; ++ static const mask cntrl = _IScntrl; ++ static const mask punct = _ISpunct; ++ static const mask alnum = _ISalpha | _ISdigit; ++ }; +diff -urN gcc-4.0.0-100/libstdc++-v3/config/os/uclibc/ctype_inline.h gcc-4.0.0/libstdc++-v3/config/os/uclibc/ctype_inline.h +--- gcc-4.0.0-100/libstdc++-v3/config/os/uclibc/ctype_inline.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/os/uclibc/ctype_inline.h 2002-06-24 00:49:19.000000000 -0500 +@@ -0,0 +1,69 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 2000, 2002 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// ctype bits to be inlined go here. Non-inlinable (ie virtual do_*) ++// functions go in ctype.cc ++ ++ bool ++ ctype:: ++ is(mask __m, char __c) const ++ { return _M_table[static_cast(__c)] & __m; } ++ ++ const char* ++ ctype:: ++ is(const char* __low, const char* __high, mask* __vec) const ++ { ++ while (__low < __high) ++ *__vec++ = _M_table[static_cast(*__low++)]; ++ return __high; ++ } ++ ++ const char* ++ ctype:: ++ scan_is(mask __m, const char* __low, const char* __high) const ++ { ++ while (__low < __high ++ && !(_M_table[static_cast(*__low)] & __m)) ++ ++__low; ++ return __low; ++ } ++ ++ const char* ++ ctype:: ++ scan_not(mask __m, const char* __low, const char* __high) const ++ { ++ while (__low < __high ++ && (_M_table[static_cast(*__low)] & __m) != 0) ++ ++__low; ++ return __low; ++ } +diff -urN gcc-4.0.0-100/libstdc++-v3/config/os/uclibc/ctype_noninline.h gcc-4.0.0/libstdc++-v3/config/os/uclibc/ctype_noninline.h +--- gcc-4.0.0-100/libstdc++-v3/config/os/uclibc/ctype_noninline.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/os/uclibc/ctype_noninline.h 2005-04-28 01:10:27.000000000 -0500 +@@ -0,0 +1,92 @@ ++// Locale support -*- C++ -*- ++ ++// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2004 ++// Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++// ++// ISO C++ 14882: 22.1 Locales ++// ++ ++// Information as gleaned from /usr/include/ctype.h ++ ++ const ctype_base::mask* ++ ctype::classic_table() throw() ++ { return __C_ctype_b; } ++ ++ ctype::ctype(__c_locale, const mask* __table, bool __del, ++ size_t __refs) ++ : facet(__refs), _M_c_locale_ctype(_S_get_c_locale()), ++ _M_del(__table != 0 && __del), _M_widen_ok(0), _M_narrow_ok(0) ++ { ++ _M_toupper = __C_ctype_toupper; ++ _M_tolower = __C_ctype_tolower; ++ _M_table = __table ? __table : __C_ctype_b; ++ memset(_M_widen, 0, sizeof(_M_widen)); ++ memset(_M_narrow, 0, sizeof(_M_narrow)); ++ } ++ ++ ctype::ctype(const mask* __table, bool __del, size_t __refs) ++ : facet(__refs), _M_c_locale_ctype(_S_get_c_locale()), ++ _M_del(__table != 0 && __del), _M_widen_ok(0), _M_narrow_ok(0) ++ { ++ _M_toupper = __C_ctype_toupper; ++ _M_tolower = __C_ctype_tolower; ++ _M_table = __table ? __table : __C_ctype_b; ++ memset(_M_widen, 0, sizeof(_M_widen)); ++ memset(_M_narrow, 0, sizeof(_M_narrow)); ++ } ++ ++ char ++ ctype::do_toupper(char __c) const ++ { return _M_toupper[static_cast(__c)]; } ++ ++ const char* ++ ctype::do_toupper(char* __low, const char* __high) const ++ { ++ while (__low < __high) ++ { ++ *__low = _M_toupper[static_cast(*__low)]; ++ ++__low; ++ } ++ return __high; ++ } ++ ++ char ++ ctype::do_tolower(char __c) const ++ { return _M_tolower[static_cast(__c)]; } ++ ++ const char* ++ ctype::do_tolower(char* __low, const char* __high) const ++ { ++ while (__low < __high) ++ { ++ *__low = _M_tolower[static_cast(*__low)]; ++ ++__low; ++ } ++ return __high; ++ } +diff -urN gcc-4.0.0-100/libstdc++-v3/config/os/uclibc/os_defines.h gcc-4.0.0/libstdc++-v3/config/os/uclibc/os_defines.h +--- gcc-4.0.0-100/libstdc++-v3/config/os/uclibc/os_defines.h 1969-12-31 18:00:00.000000000 -0600 ++++ gcc-4.0.0/libstdc++-v3/config/os/uclibc/os_defines.h 2005-04-28 01:10:27.000000000 -0500 +@@ -0,0 +1,44 @@ ++// Specific definitions for GNU/Linux -*- C++ -*- ++ ++// Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc. ++// ++// This file is part of the GNU ISO C++ Library. This library is free ++// software; you can redistribute it and/or modify it under the ++// terms of the GNU General Public License as published by the ++// Free Software Foundation; either version 2, or (at your option) ++// any later version. ++ ++// This library is distributed in the hope that it will be useful, ++// but WITHOUT ANY WARRANTY; without even the implied warranty of ++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++// GNU General Public License for more details. ++ ++// You should have received a copy of the GNU General Public License along ++// with this library; see the file COPYING. If not, write to the Free ++// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, ++// USA. ++ ++// As a special exception, you may use this file as part of a free software ++// library without restriction. Specifically, if other files instantiate ++// templates or use macros or inline functions from this file, or you compile ++// this file and link it with other files to produce an executable, this ++// file does not by itself cause the resulting executable to be covered by ++// the GNU General Public License. This exception does not however ++// invalidate any other reasons why the executable file might be covered by ++// the GNU General Public License. ++ ++#ifndef _GLIBCXX_OS_DEFINES ++#define _GLIBCXX_OS_DEFINES 1 ++ ++// System-specific #define, typedefs, corrections, etc, go here. This ++// file will come before all others. ++ ++// This keeps isanum, et al from being propagated as macros. ++#define __NO_CTYPE 1 ++ ++#include ++ ++// We must not see the optimized string functions GNU libc defines. ++#define __NO_STRING_INLINES ++ ++#endif +diff -urN gcc-4.0.0-100/libstdc++-v3/configure gcc-4.0.0/libstdc++-v3/configure +--- gcc-4.0.0-100/libstdc++-v3/configure 2005-04-30 13:06:53.683055232 -0500 ++++ gcc-4.0.0/libstdc++-v3/configure 2005-04-30 12:24:24.000000000 -0500 +@@ -3998,6 +3998,11 @@ + lt_cv_deplibs_check_method=pass_all + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +@@ -5672,7 +5677,7 @@ + enableval="$enable_clocale" + + case "$enableval" in +- generic|gnu|ieee_1003.1-2001|yes|no|auto) ;; ++ generic|gnu|ieee_1003.1-2001|uclibc|yes|no|auto) ;; + *) { { echo "$as_me:$LINENO: error: Unknown argument to enable/disable clocale" >&5 + echo "$as_me: error: Unknown argument to enable/disable clocale" >&2;} + { (exit 1); exit 1; }; } ;; +@@ -5697,6 +5702,9 @@ + # Default to "generic". + if test $enable_clocale_flag = auto; then + case ${target_os} in ++ linux-uclibc*) ++ enable_clocale_flag=uclibc ++ ;; + linux* | gnu* | kfreebsd*-gnu | knetbsd*-gnu) + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ +@@ -5927,6 +5935,76 @@ + CTIME_CC=config/locale/generic/time_members.cc + CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h + ;; ++ uclibc) ++ echo "$as_me:$LINENO: result: uclibc" >&5 ++echo "${ECHO_T}uclibc" >&6 ++ ++ # Declare intention to use gettext, and add support for specific ++ # languages. ++ # For some reason, ALL_LINGUAS has to be before AM-GNU-GETTEXT ++ ALL_LINGUAS="de fr" ++ ++ # Don't call AM-GNU-GETTEXT here. Instead, assume glibc. ++ # Extract the first word of "msgfmt", so it can be a program name with args. ++set dummy msgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_prog_check_msgfmt+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ if test -n "$check_msgfmt"; then ++ ac_cv_prog_check_msgfmt="$check_msgfmt" # Let the user override the test. ++else ++as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_prog_check_msgfmt="yes" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_prog_check_msgfmt" && ac_cv_prog_check_msgfmt="no" ++fi ++fi ++check_msgfmt=$ac_cv_prog_check_msgfmt ++if test -n "$check_msgfmt"; then ++ echo "$as_me:$LINENO: result: $check_msgfmt" >&5 ++echo "${ECHO_T}$check_msgfmt" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ if test x"$check_msgfmt" = x"yes" && test x"$enable_nls" = x"yes"; then ++ USE_NLS=yes ++ fi ++ # Export the build objects. ++ for ling in $ALL_LINGUAS; do \ ++ glibcxx_MOFILES="$glibcxx_MOFILES $ling.mo"; \ ++ glibcxx_POFILES="$glibcxx_POFILES $ling.po"; \ ++ done ++ ++ ++ ++ CLOCALE_H=config/locale/uclibc/c_locale.h ++ CLOCALE_CC=config/locale/uclibc/c_locale.cc ++ CCODECVT_CC=config/locale/uclibc/codecvt_members.cc ++ CCOLLATE_CC=config/locale/uclibc/collate_members.cc ++ CCTYPE_CC=config/locale/uclibc/ctype_members.cc ++ CMESSAGES_H=config/locale/uclibc/messages_members.h ++ CMESSAGES_CC=config/locale/uclibc/messages_members.cc ++ CMONEY_CC=config/locale/uclibc/monetary_members.cc ++ CNUMERIC_CC=config/locale/uclibc/numeric_members.cc ++ CTIME_H=config/locale/uclibc/time_members.h ++ CTIME_CC=config/locale/uclibc/time_members.cc ++ CLOCALE_INTERNAL_H=config/locale/uclibc/c++locale_internal.h ++ ;; + esac + + # This is where the testsuite looks for locale catalogs, using the +diff -urN gcc-4.0.0-100/libstdc++-v3/configure.host gcc-4.0.0/libstdc++-v3/configure.host +--- gcc-4.0.0-100/libstdc++-v3/configure.host 2005-04-30 13:06:53.688054472 -0500 ++++ gcc-4.0.0/libstdc++-v3/configure.host 2005-04-28 20:20:32.000000000 -0500 +@@ -249,6 +249,12 @@ + ;; + esac + ++# Override for uClibc since linux-uclibc gets mishandled above. ++case "${host_os}" in ++ *-uclibc*) ++ os_include_dir="os/uclibc" ++ ;; ++esac + + # Set any OS-dependent and CPU-dependent bits. + # THIS TABLE IS SORTED. KEEP IT THAT WAY. +diff -urN gcc-4.0.0-100/libstdc++-v3/crossconfig.m4 gcc-4.0.0/libstdc++-v3/crossconfig.m4 +--- gcc-4.0.0-100/libstdc++-v3/crossconfig.m4 2005-04-30 13:06:53.689054320 -0500 ++++ gcc-4.0.0/libstdc++-v3/crossconfig.m4 2005-04-28 20:27:15.000000000 -0500 +@@ -142,6 +142,98 @@ + ;; + esac + ;; ++ *-uclibc*) ++# Temporary hack until we implement the float versions of the libm funcs ++ AC_CHECK_HEADERS([nan.h ieeefp.h endian.h sys/isa_defs.h \ ++ machine/endian.h machine/param.h sys/machine.h sys/types.h \ ++ fp.h float.h endian.h inttypes.h locale.h float.h stdint.h]) ++ SECTION_FLAGS='-ffunction-sections -fdata-sections' ++ AC_SUBST(SECTION_FLAGS) ++ GLIBCXX_CHECK_LINKER_FEATURES ++ GLIBCXX_CHECK_COMPLEX_MATH_SUPPORT ++ GLIBCXX_CHECK_WCHAR_T_SUPPORT ++ ++ # For LFS. ++ AC_DEFINE(HAVE_INT64_T) ++ case "$target" in ++ *-uclinux*) ++ # Don't enable LFS with uClinux ++ ;; ++ *) ++ AC_DEFINE(_GLIBCXX_USE_LFS) ++ esac ++ ++ # For showmanyc_helper(). ++ AC_CHECK_HEADERS(sys/ioctl.h sys/filio.h) ++ GLIBCXX_CHECK_POLL ++ GLIBCXX_CHECK_S_ISREG_OR_S_IFREG ++ ++ # For xsputn_2(). ++ AC_CHECK_HEADERS(sys/uio.h) ++ GLIBCXX_CHECK_WRITEV ++ ++# AC_DEFINE(HAVE_ACOSF) ++# AC_DEFINE(HAVE_ASINF) ++# AC_DEFINE(HAVE_ATANF) ++# AC_DEFINE(HAVE_ATAN2F) ++ AC_DEFINE(HAVE_CEILF) ++ AC_DEFINE(HAVE_COPYSIGN) ++# AC_DEFINE(HAVE_COPYSIGNF) ++# AC_DEFINE(HAVE_COSF) ++# AC_DEFINE(HAVE_COSHF) ++# AC_DEFINE(HAVE_EXPF) ++# AC_DEFINE(HAVE_FABSF) ++ AC_DEFINE(HAVE_FINITE) ++ AC_DEFINE(HAVE_FINITEF) ++ AC_DEFINE(HAVE_FLOORF) ++# AC_DEFINE(HAVE_FMODF) ++# AC_DEFINE(HAVE_FREXPF) ++ AC_DEFINE(HAVE_HYPOT) ++# AC_DEFINE(HAVE_HYPOTF) ++ AC_DEFINE(HAVE_ISINF) ++ AC_DEFINE(HAVE_ISINFF) ++ AC_DEFINE(HAVE_ISNAN) ++ AC_DEFINE(HAVE_ISNANF) ++# AC_DEFINE(HAVE_LOGF) ++# AC_DEFINE(HAVE_LOG10F) ++# AC_DEFINE(HAVE_MODFF) ++# AC_DEFINE(HAVE_SINF) ++# AC_DEFINE(HAVE_SINHF) ++# AC_DEFINE(HAVE_SINCOS) ++# AC_DEFINE(HAVE_SINCOSF) ++ AC_DEFINE(HAVE_SQRTF) ++# AC_DEFINE(HAVE_TANF) ++# AC_DEFINE(HAVE_TANHF) ++ if test x"long_double_math_on_this_cpu" = x"yes"; then ++# AC_DEFINE(HAVE_ACOSL) ++# AC_DEFINE(HAVE_ASINL) ++# AC_DEFINE(HAVE_ATANL) ++# AC_DEFINE(HAVE_ATAN2L) ++# AC_DEFINE(HAVE_CEILL) ++# AC_DEFINE(HAVE_COPYSIGNL) ++# AC_DEFINE(HAVE_COSL) ++# AC_DEFINE(HAVE_COSHL) ++# AC_DEFINE(HAVE_EXPL) ++# AC_DEFINE(HAVE_FABSL) ++# AC_DEFINE(HAVE_FINITEL) ++# AC_DEFINE(HAVE_FLOORL) ++# AC_DEFINE(HAVE_FMODL) ++# AC_DEFINE(HAVE_FREXPL) ++# AC_DEFINE(HAVE_HYPOTL) ++# AC_DEFINE(HAVE_ISINFL) ++# AC_DEFINE(HAVE_ISNANL) ++# AC_DEFINE(HAVE_LOGL) ++# AC_DEFINE(HAVE_LOG10L) ++# AC_DEFINE(HAVE_MODFL) ++# AC_DEFINE(HAVE_POWL) ++# AC_DEFINE(HAVE_SINL) ++# AC_DEFINE(HAVE_SINHL) ++# AC_DEFINE(HAVE_SINCOSL) ++# AC_DEFINE(HAVE_SQRTL) ++# AC_DEFINE(HAVE_TANL) ++# AC_DEFINE(HAVE_TANHL) ++ fi ++ ;; + *-linux* | *-uclinux* | *-gnu* | *-kfreebsd*-gnu | *-knetbsd*-gnu) + AC_CHECK_HEADERS([nan.h ieeefp.h endian.h sys/isa_defs.h \ + machine/endian.h machine/param.h sys/machine.h sys/types.h \ +@@ -156,7 +248,7 @@ + AC_DEFINE(HAVE_INT64_T) + case "$target" in + *-uclinux*) +- # Don't enable LFS with uClibc ++ # Don't enable LFS with uClinux + ;; + *) + AC_DEFINE(_GLIBCXX_USE_LFS) +diff -urN gcc-4.0.0-100/libstdc++-v3/include/c_compatibility/wchar.h gcc-4.0.0/libstdc++-v3/include/c_compatibility/wchar.h +--- gcc-4.0.0-100/libstdc++-v3/include/c_compatibility/wchar.h 2005-04-30 13:06:53.690054168 -0500 ++++ gcc-4.0.0/libstdc++-v3/include/c_compatibility/wchar.h 2005-04-28 20:15:56.000000000 -0500 +@@ -101,7 +101,9 @@ + using std::wmemcpy; + using std::wmemmove; + using std::wmemset; ++#if _GLIBCXX_HAVE_WCSFTIME + using std::wcsftime; ++#endif + + #if _GLIBCXX_USE_C99 + using std::wcstold; +diff -urN gcc-4.0.0-100/libstdc++-v3/include/c_std/std_cwchar.h gcc-4.0.0/libstdc++-v3/include/c_std/std_cwchar.h +--- gcc-4.0.0-100/libstdc++-v3/include/c_std/std_cwchar.h 2005-04-30 13:06:53.691054016 -0500 ++++ gcc-4.0.0/libstdc++-v3/include/c_std/std_cwchar.h 2005-04-28 20:15:56.000000000 -0500 +@@ -179,7 +179,9 @@ + using ::wcscoll; + using ::wcscpy; + using ::wcscspn; ++#if _GLIBCXX_HAVE_WCSFTIME + using ::wcsftime; ++#endif + using ::wcslen; + using ::wcsncat; + using ::wcsncmp; diff --git a/meta/packages/gcc/gcc-4.0.2/301-missing-execinfo_h.patch b/meta/packages/gcc/gcc-4.0.2/301-missing-execinfo_h.patch new file mode 100644 index 000000000..886759381 --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/301-missing-execinfo_h.patch @@ -0,0 +1,14 @@ +From: +http://buildroot.uclibc.org/cgi-bin/viewcvs.cgi/*checkout*/trunk/buildroot/toolchain/gcc/4.0.2/301-missing-execinfo_h.patch?rev=11715 + +--- gcc-4.0.0/boehm-gc/include/gc.h-orig 2005-04-28 22:28:57.000000000 -0500 ++++ gcc-4.0.0/boehm-gc/include/gc.h 2005-04-28 22:30:38.000000000 -0500 +@@ -500,7 +500,7 @@ + #ifdef __linux__ + # include + # if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2) \ +- && !defined(__ia64__) ++ && !defined(__ia64__) && !defined(__UCLIBC__) + # ifndef GC_HAVE_BUILTIN_BACKTRACE + # define GC_HAVE_BUILTIN_BACKTRACE + # endif diff --git a/meta/packages/gcc/gcc-4.0.2/302-c99-snprintf.patch b/meta/packages/gcc/gcc-4.0.2/302-c99-snprintf.patch new file mode 100644 index 000000000..5159a52cd --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/302-c99-snprintf.patch @@ -0,0 +1,14 @@ +From: +http://buildroot.uclibc.org/cgi-bin/viewcvs.cgi/*checkout*/trunk/buildroot/toolchain/gcc/4.0.2/302-c99-snprintf.patch?rev=11715 + +--- gcc-4.0.0/libstdc++-v3/include/c_std/std_cstdio.h-orig 2005-04-29 00:08:41.000000000 -0500 ++++ gcc-4.0.0/libstdc++-v3/include/c_std/std_cstdio.h 2005-04-29 00:08:45.000000000 -0500 +@@ -142,7 +142,7 @@ + using ::vsprintf; + } + +-#if _GLIBCXX_USE_C99 ++#if _GLIBCXX_USE_C99 || defined(__UCLIBC__) + + #undef snprintf + #undef vfscanf diff --git a/meta/packages/gcc/gcc-4.0.2/303-c99-complex-ugly-hack.patch b/meta/packages/gcc/gcc-4.0.2/303-c99-complex-ugly-hack.patch new file mode 100644 index 000000000..0ba0a89b4 --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/303-c99-complex-ugly-hack.patch @@ -0,0 +1,15 @@ +From: +http://buildroot.uclibc.org/cgi-bin/viewcvs.cgi/*checkout*/trunk/buildroot/toolchain/gcc/4.0.2/303-c99-complex-ugly-hack.patch?rev=11715 + +--- gcc-4.0.0/libstdc++-v3/configure-old 2005-04-30 22:04:48.061603912 -0500 ++++ gcc-4.0.0/libstdc++-v3/configure 2005-04-30 22:06:13.678588152 -0500 +@@ -7194,6 +7194,9 @@ + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + #include ++#ifdef __UCLIBC__ ++#error ugly hack to make sure configure test fails here for cross until uClibc supports the complex funcs ++#endif + int + main () + { diff --git a/meta/packages/gcc/gcc-4.0.2/800-arm-bigendian.patch b/meta/packages/gcc/gcc-4.0.2/800-arm-bigendian.patch new file mode 100644 index 000000000..e5fc41348 --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/800-arm-bigendian.patch @@ -0,0 +1,70 @@ +From: +http://buildroot.uclibc.org/cgi-bin/viewcvs.cgi/trunk/buildroot/toolchain/gcc/4.0.2/800-arm-bigendian.patch?rev=14828&view=markup + +By Lennert Buytenhek +Adds support for arm*b-linux* big-endian ARM targets + +See http://gcc.gnu.org/PR16350 + +--- gcc-4.0.3/gcc/config/arm/linux-elf.h ++++ gcc-4.0.3/gcc/config/arm/linux-elf.h +@@ -31,19 +31,33 @@ + /* Do not assume anything about header files. */ + #define NO_IMPLICIT_EXTERN_C + ++/* ++ * 'config.gcc' defines TARGET_BIG_ENDIAN_DEFAULT as 1 for arm*b-* ++ * (big endian) configurations. ++ */ ++#if TARGET_BIG_ENDIAN_DEFAULT ++#define TARGET_ENDIAN_DEFAULT ARM_FLAG_BIG_END ++#define TARGET_ENDIAN_OPTION "mbig-endian" ++#define TARGET_LINKER_EMULATION "armelfb_linux" ++#else ++#define TARGET_ENDIAN_DEFAULT 0 ++#define TARGET_ENDIAN_OPTION "mlittle-endian" ++#define TARGET_LINKER_EMULATION "armelf_linux" ++#endif ++ + #undef TARGET_DEFAULT_FLOAT_ABI + #define TARGET_DEFAULT_FLOAT_ABI ARM_FLOAT_ABI_HARD + + #undef TARGET_DEFAULT +-#define TARGET_DEFAULT (0) ++#define TARGET_DEFAULT (TARGET_ENDIAN_DEFAULT) + + #define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm6 + +-#define SUBTARGET_EXTRA_LINK_SPEC " -m armelf_linux -p" ++#define SUBTARGET_EXTRA_LINK_SPEC " -m " TARGET_LINKER_EMULATION " -p" + + #undef MULTILIB_DEFAULTS + #define MULTILIB_DEFAULTS \ +- { "marm", "mlittle-endian", "mhard-float", "mno-thumb-interwork" } ++ { "marm", TARGET_ENDIAN_OPTION, "mhard-float", "mno-thumb-interwork" } + + /* The GNU C++ standard library requires that these macros be defined. */ + #undef CPLUSPLUS_CPP_SPEC +@@ -90,7 +104,7 @@ + %{rdynamic:-export-dynamic} \ + %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2} \ + -X \ +- %{mbig-endian:-EB}" \ ++ %{mbig-endian:-EB} %{mlittle-endian:-EL}" \ + SUBTARGET_EXTRA_LINK_SPEC + + #define TARGET_OS_CPP_BUILTINS() \ +--- gcc-4.0.3/gcc/config.gcc ++++ gcc-4.0.3/gcc/config.gcc +@@ -672,6 +672,11 @@ + ;; + arm*-*-linux*) # ARM GNU/Linux with ELF + tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" ++ case $target in ++ arm*b-*) ++ tm_defines="TARGET_BIG_ENDIAN_DEFAULT=1 $tm_defines" ++ ;; ++ esac + tmake_file="${tmake_file} arm/t-arm arm/t-linux" + extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" + gnu_ld=yes diff --git a/meta/packages/gcc/gcc-4.0.2/arm-nolibfloat.patch b/meta/packages/gcc/gcc-4.0.2/arm-nolibfloat.patch new file mode 100644 index 000000000..c4897c033 --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/arm-nolibfloat.patch @@ -0,0 +1,24 @@ +# Dimitry Andric , 2004-05-01 +# +# * Removed the extra -lfloat option from LIBGCC_SPEC, since it isn't needed +# anymore. (The required functions are now in libgcc.) +# +# Fixes errors like +# arm-softfloat-linux-gnu/3.4.0/../../../../arm-softfloat-linux-gnu/bin/ld: cannot find -lfloat +# collect2: ld returned 1 exit status +# make[2]: *** [arm-softfloat-linux-gnu/gcc-3.4.0-glibc-2.3.2/build-glibc/iconvdata/ISO8859-1.so] Error 1 +# when building glibc-2.3.3 with gcc-3.4.0 for arm-softfloat + +Index: gcc-4.0.2/gcc/config/arm/linux-elf.h +=================================================================== +--- gcc-4.0.2.orig/gcc/config/arm/linux-elf.h 2005-03-04 16:14:01.000000000 +0000 ++++ gcc-4.0.2/gcc/config/arm/linux-elf.h 2005-11-11 18:02:54.000000000 +0000 +@@ -56,7 +56,7 @@ + %{shared:-lc} \ + %{!shared:%{profile:-lc_p}%{!profile:-lc}}" + +-#define LIBGCC_SPEC "%{msoft-float:-lfloat} %{mfloat-abi=soft*:-lfloat} -lgcc" ++#define LIBGCC_SPEC "-lgcc" + + /* Provide a STARTFILE_SPEC appropriate for GNU/Linux. Here we add + the GNU/Linux magical crtbegin.o file (see crtstuff.c) which diff --git a/meta/packages/gcc/gcc-4.0.2/arm-softfloat.patch b/meta/packages/gcc/gcc-4.0.2/arm-softfloat.patch new file mode 100644 index 000000000..c86c83ed1 --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/arm-softfloat.patch @@ -0,0 +1,16 @@ +Index: gcc-4.0.2/gcc/config/arm/t-linux +=================================================================== +--- gcc-4.0.2.orig/gcc/config/arm/t-linux 2004-05-15 12:41:35.000000000 +0000 ++++ gcc-4.0.2/gcc/config/arm/t-linux 2005-11-11 16:07:53.000000000 +0000 +@@ -4,7 +4,10 @@ + LIBGCC2_DEBUG_CFLAGS = -g0 + + LIB1ASMSRC = arm/lib1funcs.asm +-LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx ++LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \ ++ _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \ ++ _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \ ++ _fixsfsi _fixunssfsi _floatdidf _floatdisf + + # MULTILIB_OPTIONS = mhard-float/msoft-float + # MULTILIB_DIRNAMES = hard-float soft-float diff --git a/meta/packages/gcc/gcc-4.0.2/ldflags.patch b/meta/packages/gcc/gcc-4.0.2/ldflags.patch new file mode 100644 index 000000000..1196bf0c8 --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/ldflags.patch @@ -0,0 +1,22 @@ +--- gcc-4.0.0/Makefile.tpl.old 2005-06-10 13:05:09.000000000 +0100 ++++ gcc-4.0.0/Makefile.tpl 2005-06-10 13:05:10.000000000 +0100 +@@ -339,7 +339,7 @@ + NM = @NM@ + + LD = @LD@ +-LDFLAGS = ++LDFLAGS = @LDFLAGS@ + + RANLIB = @RANLIB@ + +--- gcc-4.0.0/Makefile.in.old 2005-06-10 17:13:12.000000000 +0100 ++++ gcc-4.0.0/Makefile.in 2005-06-10 17:13:22.000000000 +0100 +@@ -336,7 +336,7 @@ + NM = @NM@ + + LD = @LD@ +-LDFLAGS = ++LDFLAGS = @LDFLAGS@ + + RANLIB = @RANLIB@ + diff --git a/meta/packages/gcc/gcc-4.0.2/zecke-host-cpp-ac-hack.patch b/meta/packages/gcc/gcc-4.0.2/zecke-host-cpp-ac-hack.patch new file mode 100644 index 000000000..3f26dce71 --- /dev/null +++ b/meta/packages/gcc/gcc-4.0.2/zecke-host-cpp-ac-hack.patch @@ -0,0 +1,140 @@ +gcc (AC_CHECK_HEADERS) is using $CPP to check if the header pass +the precompiler, if compiling with $CC failed. +Sadly $CC is xgcc of gcc, and $CPP is 'gcc -E'. And as you build +on a glibc machine, precompiling of the headers (execinfo.h and +iconv.h will succeed). As a dirty hack we will handle this case +as failure. +This fixes the libmudflap build for uclibc which lacks execinfo.h +but has HAVE_EXECINFO_H defined + +Index: gcc-4.0.2/libmudflap/configure +=================================================================== +--- gcc-4.0.2.orig/libmudflap/configure 2006-04-30 16:57:47.000000000 +0200 ++++ gcc-4.0.2/libmudflap/configure 2006-04-30 17:00:59.000000000 +0200 +@@ -3719,6 +3719,8 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ # hack, hack, hack ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 + echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +@@ -3731,6 +3733,8 @@ + echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} + { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 + echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: Zecke says do not trust the wrong cpp! Ignoring." >&5 ++echo "$as_me: WARNING: $ac_header: Zecke says do not trust the wrong cpp! Ignoring." >&2;} + ( + cat <<\_ASBOX + ## ------------------------------------- ## +Index: gcc-4.0.2/libstdc++-v3/configure +=================================================================== +--- gcc-4.0.2.orig/libstdc++-v3/configure 2006-04-30 16:57:53.000000000 +0200 ++++ gcc-4.0.2/libstdc++-v3/configure 2006-04-30 22:59:00.000000000 +0200 +@@ -30513,6 +30513,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -30525,6 +30526,8 @@ + echo "$as_me: WARNING: iconv.h: proceeding with the preprocessor's result" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: in the future, the compiler will take precedence" >&5 + echo "$as_me: WARNING: iconv.h: in the future, the compiler will take precedence" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: Zecke says do not trust the wrong cpp! Ignoring." >&5 ++echo "$as_me: WARNING: $ac_header: Zecke says do not trust the wrong cpp! Ignoring." >&2;} + ( + cat <<\_ASBOX + ## ----------------------------------------- ## +@@ -53622,6 +53625,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -75885,6 +75889,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -78600,6 +78605,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -80969,6 +80975,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -83214,6 +83221,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -86227,6 +86235,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -88425,6 +88434,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -90672,6 +90682,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -93280,6 +93291,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -94996,6 +95008,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 +@@ -97337,6 +97350,7 @@ + ac_header_preproc=yes + ;; + no:yes:* ) ++ ac_header_preproc=no + { echo "$as_me:$LINENO: WARNING: iconv.h: present but cannot be compiled" >&5 + echo "$as_me: WARNING: iconv.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: iconv.h: check for missing prerequisite headers?" >&5 diff --git a/meta/packages/gcc/gcc-cross-initial_3.3.4.bb b/meta/packages/gcc/gcc-cross-initial_3.3.4.bb new file mode 100644 index 000000000..e3b365da1 --- /dev/null +++ b/meta/packages/gcc/gcc-cross-initial_3.3.4.bb @@ -0,0 +1,28 @@ +SECTION = "devel" +include gcc-cross_${PV}.bb + +DEPENDS = "virtual/${TARGET_PREFIX}binutils" +DEPENDS += "${@['virtual/${TARGET_PREFIX}libc-initial',''][bb.data.getVar('TARGET_ARCH', d, 1) in ['arm', 'armeb', 'mips', 'mipsel']]}" +PROVIDES = "virtual/${TARGET_PREFIX}gcc-initial" + +# This is intended to be a -very- basic config +EXTRA_OECONF = "--with-local-prefix=${CROSS_DIR}/${TARGET_SYS} \ + --with-newlib \ + --disable-shared \ + --disable-threads \ + --disable-multilib \ + --disable-__cxa_atexit \ + --enable-languages=c \ + --enable-target-optspace \ + --program-prefix=${TARGET_PREFIX} \ + ${@get_gcc_fpu_setting(bb, d)}" + +do_stage_prepend () { + mkdir -p ${CROSS_DIR}/lib/gcc-lib/${TARGET_SYS}/${PV} + ln -sf libgcc.a ${CROSS_DIR}/lib/gcc-lib/${TARGET_SYS}/${PV}/libgcc_eh.a +} + +# Override the method from gcc-cross so we don't try to install libgcc +do_install () { + oe_runmake 'DESTDIR=${D}' install +} diff --git a/meta/packages/gcc/gcc-cross-initial_3.4.3.bb b/meta/packages/gcc/gcc-cross-initial_3.4.3.bb new file mode 100644 index 000000000..48c80864e --- /dev/null +++ b/meta/packages/gcc/gcc-cross-initial_3.4.3.bb @@ -0,0 +1,28 @@ +include gcc-cross_${PV}.bb + +DEPENDS = "virtual/${TARGET_PREFIX}binutils" +DEPENDS += "${@['virtual/${TARGET_PREFIX}libc-initial',''][bb.data.getVar('TARGET_ARCH', d, 1) in ['arm', 'armeb', 'mips', 'mipsel']]}" +PROVIDES = "virtual/${TARGET_PREFIX}gcc-initial" +PACKAGES = "" + +# This is intended to be a -very- basic config +EXTRA_OECONF = "--with-local-prefix=${CROSS_DIR}/${TARGET_SYS} \ + --with-newlib \ + --disable-shared \ + --disable-threads \ + --disable-multilib \ + --disable-__cxa_atexit \ + --enable-languages=c \ + --enable-target-optspace \ + --program-prefix=${TARGET_PREFIX} \ + ${@get_gcc_fpu_setting(bb, d)}" + +do_stage_prepend () { + mkdir -p ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV} + ln -sf libgcc.a ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/libgcc_eh.a +} + +# Override the method from gcc-cross so we don't try to install libgcc +do_install () { + oe_runmake 'DESTDIR=${D}' install +} diff --git a/meta/packages/gcc/gcc-cross-initial_3.4.4.bb b/meta/packages/gcc/gcc-cross-initial_3.4.4.bb new file mode 100644 index 000000000..48c80864e --- /dev/null +++ b/meta/packages/gcc/gcc-cross-initial_3.4.4.bb @@ -0,0 +1,28 @@ +include gcc-cross_${PV}.bb + +DEPENDS = "virtual/${TARGET_PREFIX}binutils" +DEPENDS += "${@['virtual/${TARGET_PREFIX}libc-initial',''][bb.data.getVar('TARGET_ARCH', d, 1) in ['arm', 'armeb', 'mips', 'mipsel']]}" +PROVIDES = "virtual/${TARGET_PREFIX}gcc-initial" +PACKAGES = "" + +# This is intended to be a -very- basic config +EXTRA_OECONF = "--with-local-prefix=${CROSS_DIR}/${TARGET_SYS} \ + --with-newlib \ + --disable-shared \ + --disable-threads \ + --disable-multilib \ + --disable-__cxa_atexit \ + --enable-languages=c \ + --enable-target-optspace \ + --program-prefix=${TARGET_PREFIX} \ + ${@get_gcc_fpu_setting(bb, d)}" + +do_stage_prepend () { + mkdir -p ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV} + ln -sf libgcc.a ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/libgcc_eh.a +} + +# Override the method from gcc-cross so we don't try to install libgcc +do_install () { + oe_runmake 'DESTDIR=${D}' install +} diff --git a/meta/packages/gcc/gcc-cross-initial_4.0.2.bb b/meta/packages/gcc/gcc-cross-initial_4.0.2.bb new file mode 100644 index 000000000..68dafe3f1 --- /dev/null +++ b/meta/packages/gcc/gcc-cross-initial_4.0.2.bb @@ -0,0 +1,29 @@ +include gcc-cross_${PV}.bb + +DEPENDS = "virtual/${TARGET_PREFIX}binutils" +DEPENDS += "${@['virtual/${TARGET_PREFIX}libc-initial',''][bb.data.getVar('TARGET_ARCH', d, 1) in ['arm', 'armeb', 'mips', 'mipsel']]}" +PROVIDES = "virtual/${TARGET_PREFIX}gcc-initial" +PACKAGES = "" + +# This is intended to be a -very- basic config +EXTRA_OECONF = "--with-local-prefix=${CROSS_DIR}/${TARGET_SYS} \ + --with-newlib \ + --disable-shared \ + --disable-threads \ + --disable-multilib \ + --disable-__cxa_atexit \ + --disable-libmudflap \ + --enable-languages=c \ + --enable-target-optspace \ + --program-prefix=${TARGET_PREFIX} \ + ${@get_gcc_fpu_setting(bb, d)}" + +do_stage_prepend () { + mkdir -p ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV} + ln -sf libgcc.a ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/libgcc_eh.a +} + +# Override the method from gcc-cross so we don't try to install libgcc +do_install () { + oe_runmake 'DESTDIR=${D}' install +} diff --git a/meta/packages/gcc/gcc-cross-initial_csl-arm-2005q3.bb b/meta/packages/gcc/gcc-cross-initial_csl-arm-2005q3.bb new file mode 100644 index 000000000..48c80864e --- /dev/null +++ b/meta/packages/gcc/gcc-cross-initial_csl-arm-2005q3.bb @@ -0,0 +1,28 @@ +include gcc-cross_${PV}.bb + +DEPENDS = "virtual/${TARGET_PREFIX}binutils" +DEPENDS += "${@['virtual/${TARGET_PREFIX}libc-initial',''][bb.data.getVar('TARGET_ARCH', d, 1) in ['arm', 'armeb', 'mips', 'mipsel']]}" +PROVIDES = "virtual/${TARGET_PREFIX}gcc-initial" +PACKAGES = "" + +# This is intended to be a -very- basic config +EXTRA_OECONF = "--with-local-prefix=${CROSS_DIR}/${TARGET_SYS} \ + --with-newlib \ + --disable-shared \ + --disable-threads \ + --disable-multilib \ + --disable-__cxa_atexit \ + --enable-languages=c \ + --enable-target-optspace \ + --program-prefix=${TARGET_PREFIX} \ + ${@get_gcc_fpu_setting(bb, d)}" + +do_stage_prepend () { + mkdir -p ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV} + ln -sf libgcc.a ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/libgcc_eh.a +} + +# Override the method from gcc-cross so we don't try to install libgcc +do_install () { + oe_runmake 'DESTDIR=${D}' install +} diff --git a/meta/packages/gcc/gcc-cross_3.3.4.bb b/meta/packages/gcc/gcc-cross_3.3.4.bb new file mode 100644 index 000000000..597b47fba --- /dev/null +++ b/meta/packages/gcc/gcc-cross_3.3.4.bb @@ -0,0 +1,13 @@ +SECTION = "devel" +include gcc_${PV}.bb +include gcc-paths-cross.inc +inherit cross +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/gcc-${PV}" + +PR="r3" + +DEPENDS = "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}libc-for-gcc" +PROVIDES = "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}g++" + +include gcc3-build-cross.inc +include gcc-package-cross.inc \ No newline at end of file diff --git a/meta/packages/gcc/gcc-cross_3.4.3.bb b/meta/packages/gcc/gcc-cross_3.4.3.bb new file mode 100644 index 000000000..a5d1bda17 --- /dev/null +++ b/meta/packages/gcc/gcc-cross_3.4.3.bb @@ -0,0 +1,16 @@ +include gcc_${PV}.bb +# path mangling, needed by the cross packaging +include gcc-paths-cross.inc +inherit cross +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/gcc-${PV}" +# NOTE: split PR. If the main .oe changes something that affects its *build* +# remember to increment this one too. +PR = "r10" + +DEPENDS = "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}libc-for-gcc" +PROVIDES = "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}g++" + +# cross build +include gcc3-build-cross.inc +# cross packaging +include gcc-package-cross.inc diff --git a/meta/packages/gcc/gcc-cross_3.4.4.bb b/meta/packages/gcc/gcc-cross_3.4.4.bb new file mode 100644 index 000000000..d965e5b39 --- /dev/null +++ b/meta/packages/gcc/gcc-cross_3.4.4.bb @@ -0,0 +1,16 @@ +include gcc_${PV}.bb +# path mangling, needed by the cross packaging +include gcc-paths-cross.inc +inherit cross +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/gcc-${PV}" +# NOTE: split PR. If the main .oe changes something that affects its *build* +# remember to increment this one too. +PR = "r3" + +DEPENDS = "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}libc-for-gcc" +PROVIDES = "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}g++" + +# cross build +include gcc3-build-cross.inc +# cross packaging +include gcc-package-cross.inc diff --git a/meta/packages/gcc/gcc-cross_4.0.2.bb b/meta/packages/gcc/gcc-cross_4.0.2.bb new file mode 100644 index 000000000..6e299e829 --- /dev/null +++ b/meta/packages/gcc/gcc-cross_4.0.2.bb @@ -0,0 +1,16 @@ +include gcc_${PV}.bb +# path mangling, needed by the cross packaging +include gcc-paths-cross.inc +inherit cross +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/gcc-${PV}" +# NOTE: split PR. If the main .oe changes something that affects its *build* +# remember to increment this one too. +PR = "r1" + +DEPENDS = "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}libc-for-gcc gmp-native mpfr-native" +PROVIDES = "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}g++" + +# cross build +include gcc3-build-cross.inc +# cross packaging +include gcc-package-cross.inc diff --git a/meta/packages/gcc/gcc-cross_csl-arm-2005q3.bb b/meta/packages/gcc/gcc-cross_csl-arm-2005q3.bb new file mode 100644 index 000000000..93c58aca5 --- /dev/null +++ b/meta/packages/gcc/gcc-cross_csl-arm-2005q3.bb @@ -0,0 +1,15 @@ +include gcc_csl-arm-2005q3.bb +# path mangling, needed by the cross packaging +include gcc-paths-cross.inc +inherit cross +# NOTE: split PR. If the main .oe changes something that affects its *build* +# remember to increment this one too. +PR = "r0" + +DEPENDS = "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}libc-for-gcc" +PROVIDES = "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}g++" + +# cross build +include gcc3-cross-build.inc +# cross packaging +include gcc-package-cross.inc diff --git a/meta/packages/gcc/gcc-csl-arm/15342.patch b/meta/packages/gcc/gcc-csl-arm/15342.patch new file mode 100644 index 000000000..d0f3e72d4 --- /dev/null +++ b/meta/packages/gcc/gcc-csl-arm/15342.patch @@ -0,0 +1,22 @@ +--- gcc/gcc/regrename.c~ 2004-01-14 17:55:20.000000000 +0000 ++++ gcc/gcc/regrename.c 2005-02-28 07:24:25.893015200 +0000 +@@ -671,7 +671,8 @@ + + case SET: + scan_rtx (insn, &SET_SRC (x), class, action, OP_IN, 0); +- scan_rtx (insn, &SET_DEST (x), class, action, OP_OUT, 0); ++ scan_rtx (insn, &SET_DEST (x), class, action, ++ GET_CODE (PATTERN (insn)) == COND_EXEC ? OP_INOUT : OP_OUT, 0); + return; + + case STRICT_LOW_PART: +@@ -696,7 +697,8 @@ + abort (); + + case CLOBBER: +- scan_rtx (insn, &SET_DEST (x), class, action, OP_OUT, 1); ++ scan_rtx (insn, &SET_DEST (x), class, action, ++ GET_CODE (PATTERN (insn)) == COND_EXEC ? OP_INOUT : OP_OUT, 0); + return; + + case EXPR_LIST: diff --git a/meta/packages/gcc/gcc-csl-arm/gcc-3.4.0-arm-lib1asm.patch b/meta/packages/gcc/gcc-csl-arm/gcc-3.4.0-arm-lib1asm.patch new file mode 100644 index 000000000..cf17da6a0 --- /dev/null +++ b/meta/packages/gcc/gcc-csl-arm/gcc-3.4.0-arm-lib1asm.patch @@ -0,0 +1,24 @@ +# Fixes errors like the following when building glibc (or any other executable +# or shared library) when using gcc 3.4.0 for ARM with softfloat: +# +# .../libc_pic.os(.text+0x15834): In function `__modf': undefined reference to `__subdf3' +# .../libc_pic.os(.text+0x158b8): In function `__modf': undefined reference to `__subdf3' +# .../libc_pic.os(.text+0x1590c): In function `scalbn': undefined reference to `__muldf3' +# .../libc_pic.os(.text+0x15e94): In function `__ldexpf': undefined reference to `__eqsf2' +# .../libc_pic.os(.text+0xcee4c): In function `monstartup': undefined reference to `__fixsfsi' + +diff -urNd gcc-3.4.0-orig/gcc/config/arm/t-linux gcc-3.4.0/gcc/config/arm/t-linux +--- gcc-3.4.0-orig/gcc/config/arm/t-linux 2003-09-20 23:09:07.000000000 +0200 ++++ gcc-3.4.0/gcc/config/arm/t-linux 2004-05-01 20:31:59.102846400 +0200 +@@ -4,7 +4,10 @@ + LIBGCC2_DEBUG_CFLAGS = -g0 + + LIB1ASMSRC = arm/lib1funcs.asm +-LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx ++LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \ ++ _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \ ++ _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \ ++ _fixsfsi _fixunssfsi _floatdidf _floatdisf + + # MULTILIB_OPTIONS = mhard-float/msoft-float + # MULTILIB_DIRNAMES = hard-float soft-float diff --git a/meta/packages/gcc/gcc-csl-arm/gcc34-arm-tune.patch b/meta/packages/gcc/gcc-csl-arm/gcc34-arm-tune.patch new file mode 100644 index 000000000..cdb20bef9 --- /dev/null +++ b/meta/packages/gcc/gcc-csl-arm/gcc34-arm-tune.patch @@ -0,0 +1,9 @@ +--- gcc-3.4.0/gcc/config/arm/linux-elf.h.arm-tune 2004-01-31 01:18:11.000000000 -0500 ++++ gcc-3.4.0/gcc/config/arm/linux-elf.h 2004-04-24 18:19:10.000000000 -0400 +@@ -126,3 +126,6 @@ + + #define LINK_GCC_C_SEQUENCE_SPEC \ + "%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}" ++ ++/* Tune for XScale. */ ++#define TARGET_TUNE_DEFAULT TARGET_CPU_xscale diff --git a/meta/packages/gcc/gcc-csl-arm/gcc_optab_arm.patch b/meta/packages/gcc/gcc-csl-arm/gcc_optab_arm.patch new file mode 100644 index 000000000..fa21b2655 --- /dev/null +++ b/meta/packages/gcc/gcc-csl-arm/gcc_optab_arm.patch @@ -0,0 +1,95 @@ +ARM is the only architecture that has a helper function that returns +an unbiased result. This fix is trivial enough that we can show it +doesn't effect any of the other arches. Can we consider this a +regression fix since it used to work until the helper was added :} + +Tested with no regressions on x86_64-pc-linux-gnu and arm-none-eabi. + +Cheers, +Carlos. +-- +Carlos O'Donell +CodeSourcery +carlos@codesourcery.com +(650) 331-3385 x716 + +gcc/ + +2006-01-27 Carlos O'Donell + + * optabs.c (prepare_cmp_insn): If unbaised and unsigned then bias + the comparison routine return. + +gcc/testsuite/ + +2006-01-27 Carlos O'Donell + + * gcc.dg/unsigned-long-compare.c: New test. + +Index: gcc/optabs.c +=================================================================== +--- 1/gcc/optabs.c (revision 110300) ++++ 2/gcc/optabs.c (working copy) +@@ -3711,18 +3711,24 @@ + result = emit_library_call_value (libfunc, NULL_RTX, LCT_CONST_MAKE_BLOCK, + word_mode, 2, x, mode, y, mode); + ++ /* There are two kinds of comparison routines. Biased routines ++ return 0/1/2, and unbiased routines return -1/0/1. Other parts ++ of gcc expect that the comparison operation is equivalent ++ to the modified comparison. For signed comparisons compare the ++ result against 1 in the unbiased case, and zero in the biased ++ case. For unsigned comparisons always compare against 1 after ++ biasing the unbased result by adding 1. This gives us a way to ++ represent LTU. */ + *px = result; + *pmode = word_mode; +- if (TARGET_LIB_INT_CMP_BIASED) +- /* Integer comparison returns a result that must be compared +- against 1, so that even if we do an unsigned compare +- afterward, there is still a value that can represent the +- result "less than". */ +- *py = const1_rtx; +- else ++ *py = const1_rtx; ++ ++ if (!TARGET_LIB_INT_CMP_BIASED) + { +- *py = const0_rtx; +- *punsignedp = 1; ++ if (*punsignedp) ++ *px = plus_constant (result, 1); ++ else ++ *py = const0_rtx; + } + return; + } +Index: gcc/testsuite/gcc.dg/unsigned-long-compare.c +=================================================================== +--- 1/gcc/testsuite/gcc.dg/unsigned-long-compare.c (revision 0) ++++ 2/gcc/testsuite/gcc.dg/unsigned-long-compare.c (revision 0) +@@ -0,0 +1,24 @@ ++/* Copyright (C) 2006 Free Software Foundation, Inc. */ ++/* Contributed by Carlos O'Donell on 2006-01-27 */ ++ ++/* Test a division corner case where the expression simplifies ++ to a comparison, and the optab expansion is wrong. The optab ++ expansion emits a function whose return is unbiased and needs ++ adjustment. */ ++/* Origin: Carlos O'Donell */ ++/* { dg-do run { target arm-*-*eabi* } } */ ++/* { dg-options "" } */ ++#include ++ ++#define BIG_CONSTANT 0xFFFFFFFF80000000ULL ++ ++int main (void) ++{ ++ unsigned long long OneULL = 1ULL; ++ unsigned long long result; ++ ++ result = OneULL / BIG_CONSTANT; ++ if (result) ++ abort (); ++ exit (0); ++} diff --git a/meta/packages/gcc/gcc-csl-arm/no-libfloat.patch b/meta/packages/gcc/gcc-csl-arm/no-libfloat.patch new file mode 100644 index 000000000..e5d12cfb4 --- /dev/null +++ b/meta/packages/gcc/gcc-csl-arm/no-libfloat.patch @@ -0,0 +1,11 @@ +--- gcc/gcc/config/arm/linux-elf.h.old 2005-04-20 00:46:28.923375320 +0100 ++++ gcc/gcc/config/arm/linux-elf.h 2005-04-20 00:46:34.181575952 +0100 +@@ -56,7 +56,7 @@ + %{shared:-lc} \ + %{!shared:%{profile:-lc_p}%{!profile:-lc}}" + +-#define LIBGCC_SPEC "%{msoft-float:-lfloat} %{mfloat-abi=soft*:-lfloat} -lgcc" ++#define LIBGCC_SPEC "-lgcc" + + /* Provide a STARTFILE_SPEC appropriate for GNU/Linux. Here we add + the GNU/Linux magical crtbegin.o file (see crtstuff.c) which diff --git a/meta/packages/gcc/gcc-csl-arm/pic-without-sl.patch b/meta/packages/gcc/gcc-csl-arm/pic-without-sl.patch new file mode 100644 index 000000000..9a49794da --- /dev/null +++ b/meta/packages/gcc/gcc-csl-arm/pic-without-sl.patch @@ -0,0 +1,303 @@ +Index: gcc/config/arm/arm-protos.h +=================================================================== +RCS file: /cvsroot/gcc/gcc/gcc/config/arm/arm-protos.h,v +retrieving revision 1.60.4.20 +diff -u -r1.60.4.20 arm-protos.h +--- gcc/config/arm/arm-protos.h 29 Mar 2005 03:00:11 -0000 1.60.4.20 ++++ gcc/config/arm/arm-protos.h 23 Apr 2005 04:41:06 -0000 +@@ -64,6 +64,7 @@ + extern enum reg_class vfp_secondary_reload_class (enum machine_mode, rtx); + extern int tls_symbolic_operand (rtx, enum machine_mode); + extern bool arm_tls_operand_p (rtx x); ++extern bool arm_pc_pic_operand_p (rtx x); + + /* Predicates. */ + extern int s_register_operand (rtx, enum machine_mode); +Index: gcc/config/arm/arm.c +=================================================================== +RCS file: /cvsroot/gcc/gcc/gcc/config/arm/arm.c,v +retrieving revision 1.303.2.79 +diff -u -r1.303.2.79 arm.c +--- gcc/config/arm/arm.c 12 Apr 2005 06:17:07 -0000 1.303.2.79 ++++ gcc/config/arm/arm.c 23 Apr 2005 04:41:09 -0000 +@@ -1003,7 +1003,7 @@ + + /* If stack checking is disabled, we can use r10 as the PIC register, + which keeps r9 available. */ +- if (flag_pic) ++ if (0 && flag_pic) + arm_pic_register = TARGET_APCS_STACK ? 9 : 10; + + if (TARGET_APCS_FLOAT) +@@ -3120,6 +3120,10 @@ + rtx + legitimize_pic_address (rtx orig, enum machine_mode mode, rtx reg) + { ++ if (GET_CODE (orig) == UNSPEC ++ && XINT (orig, 1) == UNSPEC_GOTSLOTPC) ++ abort (); ++ + if (GET_CODE (orig) == SYMBOL_REF + || GET_CODE (orig) == LABEL_REF) + { +@@ -3149,27 +3153,80 @@ + else + address = reg; + +- if (TARGET_ARM) +- emit_insn (gen_pic_load_addr_arm (address, orig)); +- else +- emit_insn (gen_pic_load_addr_thumb (address, orig)); ++ if (arm_pic_register != INVALID_REGNUM) ++ { ++ /* Using GP-based PIC addressing. */ ++ if (TARGET_ARM) ++ emit_insn (gen_pic_load_addr_arm (address, orig)); ++ else ++ emit_insn (gen_pic_load_addr_thumb (address, orig)); ++ ++ if ((GET_CODE (orig) == LABEL_REF ++ || (GET_CODE (orig) == SYMBOL_REF && ++ SYMBOL_REF_LOCAL_P (orig))) ++ && NEED_GOT_RELOC) ++ pic_ref = gen_rtx_PLUS (Pmode, pic_offset_table_rtx, address); ++ else ++ { ++ pic_ref = gen_rtx_MEM (Pmode, ++ gen_rtx_PLUS (Pmode, pic_offset_table_rtx, ++ address)); ++ RTX_UNCHANGING_P (pic_ref) = 1; ++ } + +- if ((GET_CODE (orig) == LABEL_REF +- || (GET_CODE (orig) == SYMBOL_REF && +- SYMBOL_REF_LOCAL_P (orig))) +- && NEED_GOT_RELOC) +- pic_ref = gen_rtx_PLUS (Pmode, pic_offset_table_rtx, address); ++ current_function_uses_pic_offset_table = 1; ++ } + else + { +- pic_ref = gen_rtx_MEM (Pmode, +- gen_rtx_PLUS (Pmode, pic_offset_table_rtx, +- address)); +- RTX_UNCHANGING_P (pic_ref) = 1; ++ /* Using PC-based PIC addressing. */ ++ rtx label, tmp; ++ int offset; ++ ++ label = gen_label_rtx (); ++ offset = TARGET_ARM ? 8 : 4; ++ ++ if (GET_CODE (orig) == LABEL_REF ++ || (GET_CODE (orig) == SYMBOL_REF && SYMBOL_REF_LOCAL_P (orig))) ++ { ++ /* This symbol is defined locally. We don't need a GOT entry. */ ++ tmp = gen_rtx_MINUS (Pmode, gen_rtx_UNSPEC (Pmode, gen_rtvec (1, orig), UNSPEC_PIC_SYM), gen_rtx_PLUS (Pmode, ++ gen_rtx_LABEL_REF (Pmode, label), ++ GEN_INT (offset))); ++ ++ load_tls_operand (tmp, address); ++ ++ if (TARGET_ARM) ++ emit_insn (gen_pic_add_dot_plus_eight (address, label)); ++ else ++ emit_insn (gen_pic_add_dot_plus_four (address, label)); ++ } ++ else ++ { ++ rtx x = gen_rtx_UNSPEC (Pmode, gen_rtvec (1, orig), UNSPEC_GOTSLOTPC); ++ rtx dummy_label; ++ ++ dummy_label = gen_label_rtx (); ++ LABEL_PRESERVE_P (dummy_label) = 1; ++ LABEL_NUSES (dummy_label) = 1; ++ ++ tmp = gen_rtx_MINUS (Pmode, x, gen_rtx_PLUS (Pmode, ++ gen_rtx_LABEL_REF (Pmode, label), ++ GEN_INT (offset))); ++ ++ load_tls_operand (tmp, address); ++ ++ if (TARGET_ARM) ++ emit_insn (gen_tls_load_dot_plus_eight (address, address, label, dummy_label)); ++ else ++ emit_insn (gen_tls_load_dot_plus_four (address, address, label, dummy_label)); ++ } ++ ++ pic_ref = address; + } + + insn = emit_move_insn (reg, pic_ref); + #endif +- current_function_uses_pic_offset_table = 1; ++ + /* Put a REG_EQUAL note on this insn, so that it can be optimized + by loop. */ + REG_NOTES (insn) = gen_rtx_EXPR_LIST (REG_EQUAL, orig, +@@ -3179,11 +3236,17 @@ + else if (GET_CODE (orig) == CONST) + { + rtx base, offset; ++ bool minus = FALSE; + + if (GET_CODE (XEXP (orig, 0)) == PLUS + && XEXP (XEXP (orig, 0), 0) == pic_offset_table_rtx) + return orig; + ++ if (GET_CODE (XEXP (orig, 0)) == MINUS ++ && GET_CODE (XEXP (XEXP (orig, 0), 0)) == UNSPEC ++ && XINT (XEXP (XEXP (orig, 0), 0), 1) == UNSPEC_GOTSLOTPC) ++ return orig; ++ + if (GET_CODE (XEXP (orig, 0)) == UNSPEC) + return orig; + +@@ -3201,6 +3264,13 @@ + offset = legitimize_pic_address (XEXP (XEXP (orig, 0), 1), Pmode, + base == reg ? 0 : reg); + } ++ else if (GET_CODE (XEXP (orig, 0)) == MINUS) ++ { ++ minus = TRUE; ++ base = legitimize_pic_address (XEXP (XEXP (orig, 0), 0), Pmode, reg); ++ offset = legitimize_pic_address (XEXP (XEXP (orig, 0), 1), Pmode, ++ base == reg ? 0 : reg); ++ } + else + abort (); + +@@ -3228,7 +3298,7 @@ + return reg; + } + +- return gen_rtx_PLUS (Pmode, base, offset); ++ return minus ? gen_rtx_MINUS (Pmode, base, offset) : gen_rtx_PLUS (Pmode, base, offset); + } + + return orig; +@@ -3267,7 +3337,7 @@ + rtx l1, pic_tmp, pic_tmp2, pic_rtx; + rtx global_offset_table; + +- if (current_function_uses_pic_offset_table == 0 || TARGET_SINGLE_PIC_BASE) ++ if (current_function_uses_pic_offset_table == 0 || TARGET_SINGLE_PIC_BASE || arm_pic_register == INVALID_REGNUM) + return; + + if (!flag_pic) +@@ -3341,8 +3411,11 @@ + static int + pcrel_constant_p (rtx x) + { ++ if (GET_CODE (x) == CONST) ++ return pcrel_constant_p (XEXP (x, 0)); ++ + if (GET_CODE (x) == MINUS) +- return symbol_mentioned_p (XEXP (x, 0)) && label_mentioned_p (XEXP (x, 1)); ++ return (((GET_CODE (XEXP (x, 0)) == UNSPEC && XINT (XEXP (x, 0), 1) == UNSPEC_PIC_SYM)) || symbol_mentioned_p (XEXP (x, 0))) && label_mentioned_p (XEXP (x, 1)); + + if (GET_CODE (x) == UNSPEC + && XINT (x, 1) == UNSPEC_TLS +@@ -3946,12 +4019,32 @@ + return SYMBOL_REF_TLS_MODEL (op); + } + ++bool ++arm_pc_pic_operand_p (rtx op) ++{ ++ if (GET_CODE (op) == CONST ++ && GET_CODE (XEXP (op, 0)) == MINUS ++ && GET_CODE (XEXP (XEXP (op, 0), 0)) == UNSPEC ++ && XINT (XEXP (XEXP (op, 0), 0), 1) == UNSPEC_GOTSLOTPC) ++ return 1; ++ ++ if (GET_CODE (op) == CONST ++ && GET_CODE (XEXP (op, 0)) == MINUS ++ && GET_CODE (XEXP (XEXP (op, 0), 0)) == UNSPEC ++ && XINT (XEXP (XEXP (op, 0), 0), 1) == UNSPEC_PIC_SYM) ++ return 1; ++ ++ return 0; ++} ++ + /* Valid input to a move instruction. */ + int + move_input_operand (rtx op, enum machine_mode mode) + { + if (tls_symbolic_operand (op, mode)) + return 0; ++ if (pcrel_constant_p (op)) ++ return 1; + return general_operand (op, mode); + } + +@@ -15634,11 +15727,34 @@ + return TRUE; + } + ++static bool ++arm_emit_got_decoration (FILE *fp, rtx x) ++{ ++ rtx val; ++ ++ val = XVECEXP (x, 0, 0); ++ ++ fputs ("_gotslotpc_(", fp); ++ ++ output_addr_const (fp, val); ++ ++ fputc (')', fp); ++ ++ return TRUE; ++} ++ + bool + arm_output_addr_const_extra (FILE *fp, rtx x) + { + if (GET_CODE (x) == UNSPEC && XINT (x, 1) == UNSPEC_TLS) + return arm_emit_tls_decoration (fp, x); ++ else if (GET_CODE (x) == UNSPEC && XINT (x, 1) == UNSPEC_GOTSLOTPC) ++ return arm_emit_got_decoration (fp, x); ++ else if (GET_CODE (x) == UNSPEC && XINT (x, 1) == UNSPEC_PIC_SYM) ++ { ++ output_addr_const (fp, XVECEXP (x, 0, 0)); ++ return TRUE; ++ } + else if (GET_CODE (x) == CONST_VECTOR) + return arm_emit_vector_const (fp, x); + +Index: gcc/config/arm/arm.md +=================================================================== +RCS file: /cvsroot/gcc/gcc/gcc/config/arm/arm.md,v +retrieving revision 1.145.2.31 +diff -u -r1.145.2.31 arm.md +--- gcc/config/arm/arm.md 28 Mar 2005 19:04:37 -0000 1.145.2.31 ++++ gcc/config/arm/arm.md 23 Apr 2005 04:41:11 -0000 +@@ -88,6 +88,7 @@ + (UNSPEC_WMADDS 18) ; Used by the intrinsic form of the iWMMXt WMADDS instruction. + (UNSPEC_WMADDU 19) ; Used by the intrinsic form of the iWMMXt WMADDU instruction. + (UNSPEC_TLS 20) ; A symbol that has been treated properly for TLS usage. ++ (UNSPEC_GOTSLOTPC 21) + ] + ) + +@@ -4179,7 +4180,8 @@ + && (CONSTANT_P (operands[1]) + || symbol_mentioned_p (operands[1]) + || label_mentioned_p (operands[1])) +- && ! tls_mentioned_p (operands[1])) ++ && ! tls_mentioned_p (operands[1]) ++ && ! arm_pc_pic_operand_p (operands[1])) + operands[1] = legitimize_pic_address (operands[1], SImode, + (no_new_pseudos ? operands[0] : 0)); + } +@@ -4412,7 +4414,8 @@ + (mem:SI (unspec:SI [(plus:SI (match_dup 0) + (const (plus:SI (pc) (const_int 8))))] + UNSPEC_PIC_BASE))) +- (use (label_ref (match_operand 1 "" "")))])] ++ (use (label_ref (match_operand 1 "" ""))) ++ (use (label_ref (match_operand 1 "" "")))])] + "" + ) + diff --git a/meta/packages/gcc/gcc-package-cross.inc b/meta/packages/gcc/gcc-package-cross.inc new file mode 100644 index 000000000..4b1f8f68e --- /dev/null +++ b/meta/packages/gcc/gcc-package-cross.inc @@ -0,0 +1,77 @@ +# Packages emitted by our gcc-cross builds. +# +INHIBIT_PACKAGE_STRIP ?= "" +HAS_G2C ?= "yes" +HAS_GFORTRAN ?= "no" +OLD_INHIBIT_PACKAGE_STRIP := "${INHIBIT_PACKAGE_STRIP}" +INHIBIT_PACKAGE_STRIP = "1" + +PACKAGES = "libgcc libstdc++ libg2c libg2c-dev libgfortran libgfortran-dev" + +PACKAGE_ARCH_libg2c = "${TARGET_ARCH}" +PACKAGE_ARCH_libg2c-dev = "${TARGET_ARCH}" +PACKAGE_ARCH_libgfortran = "${TARGET_ARCH}" +PACKAGE_ARCH_libgfortran-dev = "${TARGET_ARCH}" + +# Called from within gcc-cross, so libdir is set wrong +FILES_libg2c = "${target_libdir}/libg2c.so.*" +FILES_libg2c-dev = "${target_libdir}/libg2c.so \ + ${target_libdir}/libg2c.a \ + ${target_libdir}/libfrtbegin.a" + +FILES_libgfortran = "${target_libdir}/libgfortran.so.*" +FILES_libgfortran-dev = "${target_libdir}/libgfortran.a \ + ${target_libdir}/libgfortran.so \ + ${target_libdir}/libgfortranbegin.a" + +PACKAGE_ARCH_libgcc = "${TARGET_ARCH}" +FILES_libgcc = "${target_base_libdir}/libgcc_s.so.1" + +PACKAGE_ARCH_libstdc++ = "${TARGET_ARCH}" +PACKAGE_ARCH_libstdc++-dev = "${TARGET_ARCH}" +FILES_libstdc++ = "${target_libdir}/libstdc++.so.*" +FILES_libstdc++-dev = "${target_includedir}/c++/${PV} \ + ${target_libdir}/libstdc++.so \ + ${target_libdir}/libstdc++.la \ + ${target_libdir}/libstdc++.a \ + ${target_libdir}/libsupc++.la \ + ${target_libdir}/libsupc++.a" + +python do_package() { + if bb.data.getVar('DEBIAN_NAMES', d, 1): + bb.data.setVar('PKG_libgcc', 'libgcc1', d) + bb.build.exec_func('package_do_package', d) +} + +do_install () { + oe_runmake 'DESTDIR=${D}' install + + # Move libgcc_s into /lib + mkdir -p ${D}${target_base_libdir} + if [ -f ${D}${target_base_libdir}/libgcc_s.so.? ]; then + # Already in the right location + : + elif [ -f ${D}${prefix}/lib/libgcc_s.so.? ]; then + mv -f ${D}${prefix}/lib/libgcc_s.so.* ${D}${target_base_libdir} + else + mv -f ${D}${prefix}/*/lib/libgcc_s.so.* ${D}${target_base_libdir} + fi + + # Move libstdc++ and libg2c into libdir (resetting our prefix to /usr + mkdir -p ${D}${target_libdir} + mv -f ${D}${prefix}/*/lib/libstdc++.so.* ${D}${target_libdir} + if [ "${HAS_G2C}" = "yes" ]; then + mv -f ${D}${prefix}/*/lib/libg2c.so.* ${D}${target_libdir} + fi + if [ "${HAS_GFORTRAN}" = "yes" ]; then + mv -f ${D}${prefix}/*/lib/libgfortran*.so.* ${D}${target_libdir} + fi + + # Manually run the target stripper since we won't get it run by + # the packaging. + if [ "x${OLD_INHIBIT_PACKAGE_STRIP}" != "x1" ]; then + ${TARGET_PREFIX}strip ${D}${target_libdir}/libstdc++.so.* + ${TARGET_PREFIX}strip ${D}${target_libdir}/libg2c.so.* + ${TARGET_PREFIX}strip ${D}${target_base_libdir}/libgcc_s.so.* + fi +} diff --git a/meta/packages/gcc/gcc-package.inc b/meta/packages/gcc/gcc-package.inc new file mode 100644 index 000000000..4dcc72e87 --- /dev/null +++ b/meta/packages/gcc/gcc-package.inc @@ -0,0 +1,111 @@ +gcclibdir ?= "${libdir}/gcc" +BINV ?= "${PV}" + +# libgcc libstdc++ libg2c are listed in our FILES_*, but are actually +# packaged in the respective cross packages. +PACKAGES = "${PN} ${PN}-symlinks \ + g++ g++-symlinks \ + cpp cpp-symlinks \ + g77 g77-symlinks \ + gcov gcov-symlinks \ + libstdc++-dev libg2c-dev \ + ${PN}-doc" + +FILES_${PN} = "${bindir}/${TARGET_PREFIX}gcc \ + ${bindir}/${TARGET_PREFIX}gccbug \ + ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/cc1 \ + ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/collect2 \ + ${gcclibdir}/${TARGET_SYS}/${BINV}/*.o \ + ${gcclibdir}/${TARGET_SYS}/${BINV}/specs \ + ${gcclibdir}/${TARGET_SYS}/${BINV}/lib* \ + ${gcclibdir}/${TARGET_SYS}/${BINV}/include" +FILES_${PN}-symlinks = "${bindir}/cc \ + ${bindir}/gcc \ + ${bindir}/gccbug" + +FILES_g77 = "${bindir}/${TARGET_PREFIX}g77 \ + ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/f771" +FILES_g77-symlinks = "${bindir}/g77 \ + ${bindir}/f77" + +FILES_cpp = "${bindir}/${TARGET_PREFIX}cpp \ + ${base_libdir}/cpp" +FILES_cpp-symlinks = "${bindir}/cpp" + +FILES_gcov = "${bindir}/${TARGET_PREFIX}gcov" +FILES_gcov-symlinks = "${bindir}/gcov" + +PACKAGE_ARCH_libg2c-dev = "${TARGET_ARCH}" +# Called from within gcc-cross, so libdir is set wrong +FILES_libg2c-dev = "${libdir}/libg2c.so \ + ${libdir}/libg2c.a \ + ${libdir}/libfrtbegin.a" + +FILES_g++ = "${bindir}/${TARGET_PREFIX}g++ \ + ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/cc1plus" +FILES_g++-symlinks = "${bindir}/c++ \ + ${bindir}/g++" + +PACKAGE_ARCH_libstdc++-dev = "${TARGET_ARCH}" +FILES_libstdc++-dev = "${includedir}/c++/${BINV} \ + ${libdir}/libstdc++.so \ + ${libdir}/libstdc++.la \ + ${libdir}/libstdc++.a \ + ${libdir}/libsupc++.la \ + ${libdir}/libsupc++.a" + +FILES_${PN}-doc = "${infodir} \ + ${mandir} \ + ${gcclibdir}/${TARGET_SYS}/${BINV}/include/README" + + +do_install () { + autotools_do_install + + # Cleanup some of the ${libdir}{,exec}/gcc stuff ... + rm -r ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/install-tools + rm -r ${D}${libexecdir}/gcc/${TARGET_SYS}/${BINV}/install-tools + + # Hack around specs file assumptions + sed -i -e '/^*cross_compile:$/ { n; s/1/0/; }' ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/specs &>/dev/null || true + + # Move libgcc_s into /lib + mkdir -p ${D}${base_libdir} + mv ${D}${libdir}/libgcc_s.so.* ${D}${base_libdir} + rm ${D}${libdir}/libgcc_s.so + ln -sf `echo ${libdir}/gcc/${TARGET_SYS}/${BINV} \ + | tr -s / \ + | sed -e 's,^/,,' -e 's,[^/]*,..,g'`/lib/libgcc_s.so.1 \ + ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/libgcc_s.so + + # We don't need libtool libraries + rm ${D}${libdir}/libg2c.la &>/dev/null || true + + + # Cleanup manpages.. + rm -r ${D}${mandir}/man7 + + # We use libiberty from binutils + rm ${D}${libdir}/libiberty.a + + cd ${D}${bindir} + + # We care about g++ not c++ + rm *c++ + + # We don't care about the gcc- ones for this + rm *gcc-?.?* + + # These sometimes show up, they are strange, we remove them + rm -f ${TARGET_ARCH}-*${TARGET_ARCH}-* + + # Symlinks so we can use these trivially on the target + ln -sf ${TARGET_SYS}-g77 g77 + ln -sf ${TARGET_SYS}-g++ g++ + ln -sf ${TARGET_SYS}-gcc gcc + ln -sf g77 f77 + ln -sf g++ c++ + ln -sf gcc cc + ln -sf ${bindir}/${TARGET_SYS}-cpp ${D}${base_libdir}/cpp + ln -sf ${bindir}/${TARGET_SYS}-cpp ${D}${bindir}/cpp +} diff --git a/meta/packages/gcc/gcc-paths-cross.inc b/meta/packages/gcc/gcc-paths-cross.inc new file mode 100644 index 000000000..3c08b1805 --- /dev/null +++ b/meta/packages/gcc/gcc-paths-cross.inc @@ -0,0 +1,7 @@ +# Note that we use := here, and require that this +# is included at the correct point (before inheriting +# cross) to ensure that libdir and includedir are +# target paths, not CROSS_DIR paths. +target_libdir := "${libdir}" +target_includedir := "${includedir}" +target_base_libdir := "${base_libdir}" diff --git a/meta/packages/gcc/gcc3-build-cross.inc b/meta/packages/gcc/gcc3-build-cross.inc new file mode 100644 index 000000000..384886c76 --- /dev/null +++ b/meta/packages/gcc/gcc3-build-cross.inc @@ -0,0 +1,47 @@ +USE_NLS = '${@base_conditional( "TARGET_OS", "linux-uclibc", "no", "", d )}' + +EXTRA_OECONF_PATHS = "--with-local-prefix=${CROSS_DIR}/${TARGET_SYS} \ + --with-gxx-include-dir=${CROSS_DIR}/${TARGET_SYS}/include/c++" + +do_configure_prepend () { + rm -f ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/libgcc_eh.a +} + +do_compile_prepend () { + export CC="${BUILD_CC}" + export AR_FOR_TARGET="${TARGET_SYS}-ar" + export RANLIB_FOR_TARGET="${TARGET_SYS}-ranlib" + export LD_FOR_TARGET="${TARGET_SYS}-ld" + export NM_FOR_TARGET="${TARGET_SYS}-nm" + export CC_FOR_TARGET="${CCACHE} ${TARGET_SYS}-gcc ${TARGET_CC_ARCH}" +} + +do_stage_append () { + for d in info man share/doc share/locale ; do + rm -rf ${CROSS_DIR}/$d + done + + # These aren't useful on the cross toolchain + rm -f ${CROSS_DIR}/bin/*gcov + rm -f ${CROSS_DIR}/bin/*gccbug + + # Fix a few include links so cross builds are happier + if [ ! -e ${STAGING_INCDIR}/c++ ]; then + mkdir -p ${STAGING_INCDIR} + ln -sf ${CROSS_DIR}/${TARGET_SYS}/include/c++ \ + ${STAGING_INCDIR}/ + fi + + # We use libiberty from binutils + rm -f ${CROSS_DIR}/lib/libiberty.a + + # We probably don't need these + rmdir ${CROSS_DIR}/include || : + + # We don't really need to keep this around + # rm -rf ${CROSS_DIR}/share but leave java there + for d in share/man share/info; + do + rm -rf ${CROSS_DIR}/$d + done +} diff --git a/meta/packages/gcc/gcc3-build.inc b/meta/packages/gcc/gcc3-build.inc new file mode 100644 index 000000000..8048b45fb --- /dev/null +++ b/meta/packages/gcc/gcc3-build.inc @@ -0,0 +1,95 @@ +MIRRORS_prepend () { +${GNU_MIRROR}/gcc/releases/ ftp://gcc.gnu.org/pub/gcc/releases/ +${GNU_MIRROR}/gcc/ http://mirrors.rcn.net/pub/sourceware/gcc/releases/ +${GNU_MIRROR}/gcc/releases/ http://gcc.get-software.com/releases/ +${GNU_MIRROR}/gcc/ http://gcc.get-software.com/releases/ +} + +gcclibdir ?= "${libdir}/gcc" +S = "${WORKDIR}/gcc-${PV}" +B = "${S}/build.${HOST_SYS}.${TARGET_SYS}" +BINV ?= "${PV}" + +# gcj doesn't work on some architectures +JAVA = ",java" +JAVA_arm = "" +JAVA_armeb = "" +JAVA_mipsel = "" +JAVA_sh3 = "" +# gcc4-build sets this to f95 +FORTRAN ?= "f77" +LANGUAGES ?= "c,c++,${FORTRAN}${JAVA}" + +EXTRA_OECONF = "${@['--enable-clocale=generic', ''][bb.data.getVar('USE_NLS', d, 1) != 'no']} \ + --with-gnu-ld \ + --enable-shared \ + --enable-target-optspace \ + --enable-languages=${LANGUAGES} \ + --enable-threads=posix \ + --enable-multilib \ + --enable-c99 \ + --enable-long-long \ + --enable-symvers=gnu \ + --enable-libstdcxx-pch \ + --program-prefix=${TARGET_PREFIX} \ + ${EXTRA_OECONF_PATHS} \ + ${EXTRA_OECONF_DEP}" + +EXTRA_OECONF_PATHS = " \ + --with-local-prefix=${prefix}/local \ + --with-gxx-include-dir=${includedir}/c++/${BINV}" + +EXTRA_OECONF_DEP = "" +EXTRA_OECONF_uclibc = "--disable-__cxa_atexit" +EXTRA_OECONF_glibc = "--enable-__cxa_atexit" +EXTRA_OECONF += "${@get_gcc_fpu_setting(bb, d)}" +CPPFLAGS = "" + +# Used by configure to define additional values for FLAGS_FOR_TARGET - +# passed to all the compilers. +ARCH_FLAGS_FOR_TARGET = "" +#NOTE: not tested on other platforms, the following is probably correct +# everywhere! +ARCH_FLAGS_FOR_TARGET_slugos = "${TARGET_CC_ARCH}" +ARCH_FLAGS_FOR_TARGET_unslung = "${TARGET_CC_ARCH}" +EXTRA_OEMAKE += "ARCH_FLAGS_FOR_TARGET='${ARCH_FLAGS_FOR_TARGET}'" + +def get_gcc_fpu_setting(bb, d): + if bb.data.getVar('TARGET_FPU', d, 1) in [ 'soft' ]: + return "--with-float=soft" + return "" + +python __anonymous () { + import bb, re + if (re.match('linux-uclibc$', bb.data.getVar('TARGET_OS', d, 1)) != None): + bb.data.setVar('EXTRA_OECONF_DEP', '${EXTRA_OECONF_uclibc}', d) + elif (re.match('linux$', bb.data.getVar('TARGET_OS', d, 1)) != None): + bb.data.setVar('EXTRA_OECONF_DEP', '${EXTRA_OECONF_glibc}', d) +} + +do_configure () { + # Setup these vars for cross building only + # ... because foo_FOR_TARGET apparently gets misinterpreted inside the + # gcc build stuff when the build is producing a cross compiler - i.e. + # when the 'current' target is the 'host' system, and the host is not + # the target (because the build is actually making a cross compiler!) + if [ "${BUILD_SYS}" != "${HOST_SYS}" ]; then + export CC_FOR_TARGET="${CC}" + export GCC_FOR_TARGET="${CC}" + export CXX_FOR_TARGET="${CXX}" + export AS_FOR_TARGET="${HOST_PREFIX}as" + export LD_FOR_TARGET="${HOST_PREFIX}ld" + export NM_FOR_TARGET="${HOST_PREFIX}nm" + export AR_FOR_TARGET="${HOST_PREFIX}ar" + export RANLIB_FOR_TARGET="${HOST_PREFIX}ranlib" + fi + export CC_FOR_BUILD="${BUILD_CC}" + export CXX_FOR_BUILD="${BUILD_CXX}" + export CFLAGS_FOR_BUILD="${BUILD_CFLAGS}" + export CPPFLAGS_FOR_BUILD="${BUILD_CPPFLAGS}" + export CXXFLAGS_FOR_BUILD="${BUILD_CXXFLAGS}" + export LDFLAGS_FOR_BUILD="${BUILD_LDFLAGS}" + export ARCH_FLAGS_FOR_TARGET="${ARCH_FLAGS_FOR_TARGET}" + (cd ${S} && gnu-configize) || die "failure running gnu-configize" + oe_runconf +} diff --git a/meta/packages/gcc/gcc4-build.inc b/meta/packages/gcc/gcc4-build.inc new file mode 100644 index 000000000..8b80f4820 --- /dev/null +++ b/meta/packages/gcc/gcc4-build.inc @@ -0,0 +1,6 @@ +FORTRAN = "f95" +HAS_GFORTRAN = "yes" +HAS_G2C = "no" + +include gcc3-build.inc + diff --git a/meta/packages/gcc/gcc_3.3.4.bb b/meta/packages/gcc/gcc_3.3.4.bb new file mode 100644 index 000000000..dc3a66cd2 --- /dev/null +++ b/meta/packages/gcc/gcc_3.3.4.bb @@ -0,0 +1,176 @@ +SECTION = "devel" +PR = "r2" +inherit autotools gettext + +DESCRIPTION = "The GNU cc and gcc C compilers." +HOMEPAGE = "http://www.gnu.org/software/gcc/" +LICENSE = "GPL" +MAINTAINER = "Gerald Britton " + +# libgcc libstdc++ libg2c are listed in our FILES_*, but are actually +# packaged in the respective cross packages. +PACKAGES = "${PN} ${PN}-symlinks \ + ${PN}-c++ ${PN}-c++-symlinks \ + ${PN}-f77 ${PN}-f77-symlinks \ + libstdc++-dev libg2c-dev \ + ${PN}-doc" + +FILES_${PN} = "${bindir}/${TARGET_PREFIX}gcc \ + ${bindir}/${TARGET_PREFIX}cpp \ + ${bindir}/${TARGET_PREFIX}gcov \ + ${bindir}/${TARGET_PREFIX}gccbug \ + ${libdir}/gcc-lib/${TARGET_SYS}/${PV}/cc1 \ + ${libdir}/gcc-lib/${TARGET_SYS}/${PV}/collect2 \ + ${libdir}/gcc-lib/${TARGET_SYS}/${PV}/crt* \ + ${libdir}/gcc-lib/${TARGET_SYS}/${PV}/specs \ + ${libdir}/gcc-lib/${TARGET_SYS}/${PV}/lib* \ + ${libdir}/gcc-lib/${TARGET_SYS}/${PV}/include" + +FILES_${PN}-symlinks = "${bindir}/cc \ + ${bindir}/gcc \ + ${bindir}/cpp \ + ${bindir}/gcov \ + ${bindir}/gccbug" + +FILES_${PN}-c++ = "${bindir}/${TARGET_PREFIX}g++ \ + ${libdir}/gcc-lib/${TARGET_SYS}/${PV}/cc1plus" + +FILES_${PN}-c++-symlinks = "${bindir}/c++ \ + ${bindir}/g++" + +PACKAGE_ARCH_libgcc = "${TARGET_ARCH}" +FILES_libgcc = "/lib/libgcc_s.so.*" + +PACKAGE_ARCH_libstdc++ = "${TARGET_ARCH}" +PACKAGE_ARCH_libstdc++-dev = "${TARGET_ARCH}" +# Called from within gcc-cross, so libdir is set wrong +#FILES_libstdc++ = "${libdir}/libstdc++.so.*" +FILES_libstdc++ = "${libdir}/libstdc++.so.*" + +FILES_libstdc++-dev = "${includedir}/c++/${PV} \ + ${libdir}/libstdc++.so \ + ${libdir}/libstdc++.la \ + ${libdir}/libstdc++.a \ + ${libdir}/libsupc++.la \ + ${libdir}/libsupc++.a" + +FILES_${PN}-doc = "${infodir} \ + ${mandir} \ + ${libdir}/gcc-lib/${TARGET_SYS}/${PV}/include/README" + +SRC_URI = "${GNU_MIRROR}/gcc/releases/gcc-${PV}/gcc-${PV}.tar.bz2 \ + file://arm-gotoff.dpatch;patch=1;pnum=0 \ + file://arm-ldm.dpatch;patch=1;pnum=0 \ + file://arm-tune.patch;patch=1;pnum=0 \ + file://arm-ldm-peephole.patch;patch=1;pnum=0 \ + file://libibery-crosstool.patch;patch=1;pnum=1 \ + file://reverse-compare.patch;patch=1 \ + file://gcc34-15089.patch;patch=1 \ + file://gcc-uclibc-3.3-100-conf.patch;patch=1 \ + file://gcc-uclibc-3.3-110-conf.patch;patch=1 \ + file://gcc-uclibc-3.3-120-softfloat.patch;patch=1 \ + file://gcc-uclibc-3.3-200-code.patch;patch=1 \ + file://bash3.patch;patch=1" + +PREMIRRORS_prepend () { +${GNU_MIRROR}/gcc/releases/ ftp://gcc.gnu.org/pub/gcc/releases/ +${GNU_MIRROR}/gcc/releases/ http://gcc.get-software.com/releases/ +} + +S = "${WORKDIR}/gcc-${PV}" +B = "${S}/build.${HOST_SYS}.${TARGET_SYS}" + +EXTRA_OECONF = "${@['--enable-clocale=generic', ''][bb.data.getVar('USE_NLS', d, 1) != 'no']} \ + --with-gnu-ld \ + --enable-shared \ + --enable-multilib \ + --enable-target-optspace \ + --enable-languages=c,c++,f77 \ + --enable-threads=posix \ + --enable-c99 \ + --enable-long-long \ + --enable-symvers=gnu \ + --program-prefix=${TARGET_PREFIX} \ + ${EXTRA_OECONF_PATHS} \ + ${EXTRA_OECONF_DEP}" + +EXTRA_OECONF_PATHS = "--with-local-prefix=${prefix}/local \ + --with-gxx-include-dir=${includedir}/c++/${PV}" + +EXTRA_OECONF_DEP = "" +EXTRA_OECONF_uclibc = "--disable-__cxa_atexit" +EXTRA_OECONF_glibc = "--enable-__cxa_atexit" +EXTRA_OECONF += "${@get_gcc_fpu_setting(bb, d)}" + +def get_gcc_fpu_setting(bb, d): + if bb.data.getVar('TARGET_FPU', d, 1) in [ 'soft' ]: + return "--with-float=soft" + return "" + +python __anonymous () { + import bb, re + if (re.match('linux-uclibc$', bb.data.getVar('TARGET_OS', d, 1)) != None): + bb.data.setVar('EXTRA_OECONF_DEP', '${EXTRA_OECONF_uclibc}', d) + elif (re.match('linux$', bb.data.getVar('TARGET_OS', d, 1)) != None): + bb.data.setVar('EXTRA_OECONF_DEP', '${EXTRA_OECONF_glibc}', d) +} + +do_configure () { + # Setup these vars for cross building only + if [ "${BUILD_SYS}" != "${HOST_SYS}" ]; then + export CC_FOR_TARGET="${CCACHE} ${HOST_PREFIX}gcc" + export GCC_FOR_TARGET="${CCACHE} ${HOST_PREFIX}gcc" + export CXX_FOR_TARGET="${CCACHE} ${HOST_PREFIX}g++" + export AS_FOR_TARGET="${HOST_PREFIX}as" + export LD_FOR_TARGET="${HOST_PREFIX}ld" + export NM_FOR_TARGET="${HOST_PREFIX}nm" + export AR_FOR_TARGET="${HOST_PREFIX}ar" + export RANLIB_FOR_TARGET="${HOST_PREFIX}ranlib" + fi + (cd ${S} && gnu-configize) || die "failure running gnu-configize" + oe_runconf +} + +do_install () { + autotools_do_install + + # Cleanup some of the gcc-lib stuff + rm -rf ${D}${libdir}/gcc-lib/${TARGET_SYS}/${PV}/install-tools + + # Move libgcc_s into /lib + mkdir -p ${D}${base_libdir} + mv -f ${D}${libdir}/libgcc_s.so.* ${D}${base_libdir} + rm -f ${D}${libdir}/libgcc_s.so + ln -sf `echo ${libdir}/gcc-lib/${TARGET_SYS}/${PV} | tr -s / | + sed -e 's,^/,,' -e 's,[^/]*,..,g'`/lib/libgcc_s.so.? \ + ${D}${libdir}/gcc-lib/${TARGET_SYS}/${PV}/libgcc_s.so + + # Cleanup manpages.. + rm -rf ${D}${mandir}/man7 + mv ${D}${mandir}/man1/cpp.1 \ + ${D}${mandir}/man1/${TARGET_SYS}-cpp.1 + mv ${D}${mandir}/man1/gcov.1 \ + ${D}${mandir}/man1/${TARGET_SYS}-gcov.1 + + # We use libiberty from binutils + rm -f ${D}${libdir}/libiberty.a + + cd ${D}${bindir} + + # We care about g++ not c++ + rm -f *c++ + + # We don't care about the gcc- ones for this + rm -f *gcc-?.?* + + # These sometimes show up, they are strange, we remove them + rm -f ${TARGET_ARCH}-*${TARGET_ARCH}-* + + # Symlinks so we can use these trivially on the target + ln -sf ${TARGET_SYS}-g77 g77 + ln -sf ${TARGET_SYS}-g++ g++ + ln -sf ${TARGET_SYS}-gcc gcc + ln -sf g77 f77 + ln -sf g++ c++ + ln -sf gcc cc +} diff --git a/meta/packages/gcc/gcc_3.4.3.bb b/meta/packages/gcc/gcc_3.4.3.bb new file mode 100644 index 000000000..c92746be5 --- /dev/null +++ b/meta/packages/gcc/gcc_3.4.3.bb @@ -0,0 +1,27 @@ +PR = "r11" +DESCRIPTION = "The GNU cc and gcc C compilers." +HOMEPAGE = "http://www.gnu.org/software/gcc/" +SECTION = "devel" +LICENSE = "GPL" +MAINTAINER = "Gerald Britton " + +inherit autotools gettext + +include gcc-package.inc + +SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \ + file://gcc34-reverse-compare.patch;patch=1 \ + file://gcc34-arm-ldm.patch;patch=1 \ + file://gcc34-arm-ldm-peephole.patch;patch=1 \ + file://gcc34-arm-tune.patch;patch=1 \ + file://gcc-3.4.1-uclibc-100-conf.patch;patch=1 \ + file://gcc-3.4.1-uclibc-200-locale.patch;patch=1 \ + file://gcc-3.4.0-arm-lib1asm.patch;patch=1 \ + file://gcc-3.4.0-arm-nolibfloat.patch;patch=1 \ + file://gcc-3.4.0-arm-bigendian.patch;patch=1 \ + file://gcc-3.4.0-arm-bigendian-uclibc.patch;patch=1 \ + file://GCC3.4.0VisibilityPatch.diff;patch=1 \ + file://15342.patch;patch=1 \ + file://always-fixincperm.patch;patch=1" + +include gcc3-build.inc diff --git a/meta/packages/gcc/gcc_3.4.4.bb b/meta/packages/gcc/gcc_3.4.4.bb new file mode 100644 index 000000000..5be603f2c --- /dev/null +++ b/meta/packages/gcc/gcc_3.4.4.bb @@ -0,0 +1,30 @@ +PR = "r5" +DESCRIPTION = "The GNU cc and gcc C compilers." +HOMEPAGE = "http://www.gnu.org/software/gcc/" +SECTION = "devel" +LICENSE = "GPL" +MAINTAINER = "Gerald Britton " + +inherit autotools gettext + +include gcc-package.inc + +SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \ + file://gcc34-reverse-compare.patch;patch=1 \ + file://gcc34-arm-ldm.patch;patch=1 \ + file://gcc34-arm-ldm-peephole.patch;patch=1 \ + file://gcc34-arm-tune.patch;patch=1 \ + file://gcc-3.4.1-uclibc-100-conf.patch;patch=1 \ + file://gcc-3.4.1-uclibc-200-locale.patch;patch=1 \ + file://gcc-3.4.0-arm-lib1asm.patch;patch=1 \ + file://gcc-3.4.0-arm-nolibfloat.patch;patch=1 \ + file://gcc-3.4.0-arm-bigendian.patch;patch=1 \ + file://gcc-3.4.0-arm-bigendian-uclibc.patch;patch=1 \ + file://GCC3.4.0VisibilityPatch.diff;patch=1 \ + file://15342.patch;patch=1 \ + file://always-fixincperm.patch;patch=1" + +SRC_URI += "file://gcc34-configure.in.patch;patch=1" +SRC_URI += "file://gcc34-thumb-support.patch;patch=1" + +include gcc3-build.inc diff --git a/meta/packages/gcc/gcc_4.0.2.bb b/meta/packages/gcc/gcc_4.0.2.bb new file mode 100644 index 000000000..f4eeb9bde --- /dev/null +++ b/meta/packages/gcc/gcc_4.0.2.bb @@ -0,0 +1,28 @@ +DESCRIPTION = "The GNU cc and gcc C compilers." +HOMEPAGE = "http://www.gnu.org/software/gcc/" +SECTION = "devel" +LICENSE = "GPL" +MAINTAINER = "Gerald Britton " +DEPENDS = "mpfr gmp" +PR = "r1" + +inherit autotools gettext + +include gcc-package.inc + +SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \ + file://arm-nolibfloat.patch;patch=1 \ + file://arm-softfloat.patch;patch=1 \ + file://ldflags.patch;patch=1" + +# uclibc patches below +SRC_URI_append = " file://100-uclibc-conf.patch;patch=1 \ + file://200-uclibc-locale.patch;patch=1 \ + file://301-missing-execinfo_h.patch;patch=1 \ + file://302-c99-snprintf.patch;patch=1 \ + file://303-c99-complex-ugly-hack.patch;patch=1 \ + file://800-arm-bigendian.patch;patch=1 \ + file://zecke-host-cpp-ac-hack.patch;patch=1 " + + +include gcc4-build.inc diff --git a/meta/packages/gcc/gcc_csl-arm-2005q3.bb b/meta/packages/gcc/gcc_csl-arm-2005q3.bb new file mode 100644 index 000000000..62bacda14 --- /dev/null +++ b/meta/packages/gcc/gcc_csl-arm-2005q3.bb @@ -0,0 +1,27 @@ +DESCRIPTION = "The GNU cc and gcc C compilers." +HOMEPAGE = "http://www.gnu.org/software/gcc/" +SECTION = "devel" +LICENSE = "GPL" +BINV = "3.4.4" +PV = "3.4.4+csl-arm-2005q3" +PR = "r1" + +FILESDIR = "${FILE_DIRNAME}/gcc-csl-arm" + +inherit autotools gettext + +include gcc-package.inc + +SRC_URI = "http://www.codesourcery.com/public/gnu_toolchain/arm/2005q3-2/arm-2005q3-2-arm-none-linux-gnueabi.src.tar.bz2 \ + file://gcc_optab_arm.patch;patch=1" + +do_unpack2() { + cd ${WORKDIR} + tar -xvjf ./arm-2005q3-2-arm-none-linux-gnueabi/gcc-2005q3-2.tar.bz2 +} + +addtask unpack2 after do_unpack before do_patch + +include gcc3-build.inc + +S = "${WORKDIR}/gcc-2005q3" diff --git a/meta/packages/gdb/files/gdbserver-cflags-last.diff b/meta/packages/gdb/files/gdbserver-cflags-last.diff new file mode 100644 index 000000000..42bd740a7 --- /dev/null +++ b/meta/packages/gdb/files/gdbserver-cflags-last.diff @@ -0,0 +1,13 @@ +--- gdb/gdbserver/Makefile.in.orig 2004-10-05 18:52:56.298419032 +0200 ++++ gdb/gdbserver/Makefile.in 2004-10-05 18:53:10.442268840 +0200 +@@ -97,8 +97,8 @@ + CFLAGS = @CFLAGS@ + + # INTERNAL_CFLAGS is the aggregate of all other *CFLAGS macros. +-INTERNAL_CFLAGS = $(WARN_CFLAGS) ${CFLAGS} ${GLOBAL_CFLAGS} \ +- ${PROFILE_CFLAGS} ${INCLUDE_CFLAGS} ${BFD_CFLAGS} ++INTERNAL_CFLAGS = $(WARN_CFLAGS) ${GLOBAL_CFLAGS} \ ++ ${PROFILE_CFLAGS} ${INCLUDE_CFLAGS} ${BFD_CFLAGS} ${CFLAGS} + + # LDFLAGS is specifically reserved for setting from the command line + # when running make. diff --git a/meta/packages/gdb/files/kill_arm_map_symbols.patch b/meta/packages/gdb/files/kill_arm_map_symbols.patch new file mode 100644 index 000000000..177142192 --- /dev/null +++ b/meta/packages/gdb/files/kill_arm_map_symbols.patch @@ -0,0 +1,24 @@ +Index: gdb-6.3/gdb/arm-tdep.c +=================================================================== +--- gdb-6.3.orig/gdb/arm-tdep.c 2004-08-03 02:02:20.000000000 +0000 ++++ gdb-6.3/gdb/arm-tdep.c 2005-11-09 15:13:29.000000000 +0000 +@@ -2491,6 +2491,19 @@ + static void + arm_elf_make_msymbol_special(asymbol *sym, struct minimal_symbol *msym) + { ++ ++ /* FIXME: We want gdb to ignore the ARM ELF mapping symbols when ++ displaying disassembly so we use this horrible hack here to ++ artifically set their address to the highest possible value. ++ This is wrong of course, and it prevents the symbols from being ++ used for their intended purpose - to distinguish between ARM ++ and THUMB code. So we ought to find a better way to do this. */ ++ if (bfd_asymbol_name (sym) ++ && bfd_asymbol_name (sym)[0] == '$' ++ && bfd_asymbol_name (sym)[1] != 0 ++ && bfd_asymbol_name (sym)[2] == 0) ++ SYMBOL_VALUE_ADDRESS(msym) = (CORE_ADDR) 0x7ffffffc; ++ + /* Thumb symbols are of type STT_LOPROC, (synonymous with + STT_ARM_TFUNC). */ + if (ELF_ST_TYPE (((elf_symbol_type *)sym)->internal_elf_sym.st_info) diff --git a/meta/packages/gdb/files/libiberty-cross.patch b/meta/packages/gdb/files/libiberty-cross.patch new file mode 100644 index 000000000..0d1897f9e --- /dev/null +++ b/meta/packages/gdb/files/libiberty-cross.patch @@ -0,0 +1,630 @@ +--- libiberty/configure.in.old 2004-03-31 21:25:25.000000000 +0100 ++++ libiberty/configure.in 2004-03-31 21:18:02.000000000 +0100 +@@ -100,6 +100,7 @@ + AC_CHECK_TOOL(RANLIB, ranlib, :) + + LIB_AC_PROG_CC ++AC_PROG_CC_WORKS + + AC_PROG_CC_C_O + # autoconf is lame and doesn't give us any substitution variable for this. +@@ -402,7 +403,6 @@ + + # We haven't set the list of objects yet. Use the standard autoconf + # tests. This will only work if the compiler works. +- AC_PROG_CC_WORKS + AC_REPLACE_FUNCS($funcs) + libiberty_AC_FUNC_C_ALLOCA + AC_FUNC_VFORK + +--- libiberty/configure.old 2003-06-19 21:05:35.000000000 +0100 ++++ libiberty/configure 2004-03-31 21:35:12.000000000 +0100 +@@ -1000,13 +1000,60 @@ + fi + + ++echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 ++echo "configure:1005: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ++ ++ac_ext=c ++# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. ++ac_cpp='$CPP $CPPFLAGS' ++ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' ++ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' ++cross_compiling=$ac_cv_prog_cc_cross ++ ++cat > conftest.$ac_ext << EOF ++ ++#line 1016 "configure" ++#include "confdefs.h" ++ ++main(){return(0);} ++EOF ++if { (eval echo configure:1021: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++ ac_cv_prog_cc_works=yes ++ # If we can't run a trivial program, we are probably using a cross compiler. ++ if (./conftest; exit) 2>/dev/null; then ++ ac_cv_prog_cc_cross=no ++ else ++ ac_cv_prog_cc_cross=yes ++ fi ++else ++ echo "configure: failed program was:" >&5 ++ cat conftest.$ac_ext >&5 ++ ac_cv_prog_cc_works=no ++fi ++rm -fr conftest* ++ac_ext=c ++# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. ++ac_cpp='$CPP $CPPFLAGS' ++ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' ++ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' ++cross_compiling=$ac_cv_prog_cc_cross ++ ++echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 ++if test $ac_cv_prog_cc_works = no; then ++ { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } ++fi ++echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 ++echo "configure:1047: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 ++echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 ++cross_compiling=$ac_cv_prog_cc_cross ++ + + if test "x$CC" != xcc; then + echo $ac_n "checking whether $CC and cc understand -c and -o together""... $ac_c" 1>&6 +-echo "configure:1007: checking whether $CC and cc understand -c and -o together" >&5 ++echo "configure:1054: checking whether $CC and cc understand -c and -o together" >&5 + else + echo $ac_n "checking whether cc understands -c and -o together""... $ac_c" 1>&6 +-echo "configure:1010: checking whether cc understands -c and -o together" >&5 ++echo "configure:1057: checking whether cc understands -c and -o together" >&5 + fi + set dummy $CC; ac_cc="`echo $2 | + sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`" +@@ -1018,16 +1065,16 @@ + # We do the test twice because some compilers refuse to overwrite an + # existing .o file with -o, though they will create one. + ac_try='${CC-cc} -c conftest.c -o conftest.o 1>&5' +-if { (eval echo configure:1022: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } && +- test -f conftest.o && { (eval echo configure:1023: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; ++if { (eval echo configure:1069: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } && ++ test -f conftest.o && { (eval echo configure:1070: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; + then + eval ac_cv_prog_cc_${ac_cc}_c_o=yes + if test "x$CC" != xcc; then + # Test first that cc exists at all. +- if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:1028: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then ++ if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:1075: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then + ac_try='cc -c conftest.c -o conftest.o 1>&5' +- if { (eval echo configure:1030: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } && +- test -f conftest.o && { (eval echo configure:1031: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; ++ if { (eval echo configure:1077: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } && ++ test -f conftest.o && { (eval echo configure:1078: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; + then + # cc works too. + : +@@ -1063,7 +1110,7 @@ + + + echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6 +-echo "configure:1067: checking for POSIXized ISC" >&5 ++echo "configure:1114: checking for POSIXized ISC" >&5 + if test -d /etc/conf/kconfig.d && + grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1 + then +@@ -1084,12 +1131,12 @@ + fi + + echo $ac_n "checking for working const""... $ac_c" 1>&6 +-echo "configure:1088: checking for working const" >&5 ++echo "configure:1135: checking for working const" >&5 + if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1189: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_const=yes + else +@@ -1159,21 +1206,21 @@ + fi + + echo $ac_n "checking for inline""... $ac_c" 1>&6 +-echo "configure:1163: checking for inline" >&5 ++echo "configure:1210: checking for inline" >&5 + if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + ac_cv_c_inline=no + for ac_kw in inline __inline__ __inline; do + cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1224: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_inline=$ac_kw; break + else +@@ -1199,14 +1246,14 @@ + esac + + echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 +-echo "configure:1203: checking whether byte ordering is bigendian" >&5 ++echo "configure:1250: checking whether byte ordering is bigendian" >&5 + if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + ac_cv_c_bigendian=unknown + # See if sys/param.h defines the BYTE_ORDER macro. + cat > conftest.$ac_ext < + #include +@@ -1217,11 +1264,11 @@ + #endif + ; return 0; } + EOF +-if { (eval echo configure:1221: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1268: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + # It does; now see whether it defined to BIG_ENDIAN or not. + cat > conftest.$ac_ext < + #include +@@ -1232,7 +1279,7 @@ + #endif + ; return 0; } + EOF +-if { (eval echo configure:1236: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1283: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_bigendian=yes + else +@@ -1252,7 +1299,7 @@ + echo $ac_n "cross-compiling... " 2>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null ++if { (eval echo configure:1316: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null + then + ac_cv_c_bigendian=no + else +@@ -1283,7 +1330,7 @@ + echo "$ac_t""$ac_cv_c_bigendian" 1>&6 + if test $ac_cv_c_bigendian = unknown; then + echo $ac_n "checking to probe for byte ordering""... $ac_c" 1>&6 +-echo "configure:1287: checking to probe for byte ordering" >&5 ++echo "configure:1334: checking to probe for byte ordering" >&5 + + cat >conftest.c <&6 +-echo "configure:1356: checking for a BSD compatible install" >&5 ++echo "configure:1403: checking for a BSD compatible install" >&5 + if test -z "$INSTALL"; then + if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +@@ -1413,7 +1460,7 @@ + # able to link anything, it had better be able to at least compile + # something. + echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 +-echo "configure:1417: checking how to run the C preprocessor" >&5 ++echo "configure:1464: checking how to run the C preprocessor" >&5 + # On Suns, sometimes $CPP names a directory. + if test -n "$CPP" && test -d "$CPP"; then + CPP= +@@ -1428,13 +1475,13 @@ + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. + cat > conftest.$ac_ext < + Syntax Error + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1438: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1485: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + : +@@ -1445,13 +1492,13 @@ + rm -rf conftest* + CPP="${CC-cc} -E -traditional-cpp" + cat > conftest.$ac_ext < + Syntax Error + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1455: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1502: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + : +@@ -1462,13 +1509,13 @@ + rm -rf conftest* + CPP="${CC-cc} -nologo -E" + cat > conftest.$ac_ext < + Syntax Error + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1472: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1519: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + : +@@ -1496,17 +1543,17 @@ + do + ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` + echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +-echo "configure:1500: checking for $ac_hdr" >&5 ++echo "configure:1547: checking for $ac_hdr" >&5 + if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1510: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1557: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + rm -rf conftest* +@@ -1533,12 +1580,12 @@ + done + + echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6 +-echo "configure:1537: checking for sys/wait.h that is POSIX.1 compatible" >&5 ++echo "configure:1584: checking for sys/wait.h that is POSIX.1 compatible" >&5 + if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #include +@@ -1554,7 +1601,7 @@ + s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; + ; return 0; } + EOF +-if { (eval echo configure:1558: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1605: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_header_sys_wait_h=yes + else +@@ -1575,12 +1622,12 @@ + fi + + echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 +-echo "configure:1579: checking whether time.h and sys/time.h may both be included" >&5 ++echo "configure:1626: checking whether time.h and sys/time.h may both be included" >&5 + if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #include +@@ -1589,7 +1636,7 @@ + struct tm *tp; + ; return 0; } + EOF +-if { (eval echo configure:1593: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1640: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_header_time=yes + else +@@ -1611,19 +1658,19 @@ + + + echo $ac_n "checking whether errno must be declared""... $ac_c" 1>&6 +-echo "configure:1615: checking whether errno must be declared" >&5 ++echo "configure:1662: checking whether errno must be declared" >&5 + if eval "test \"`echo '$''{'libiberty_cv_declare_errno'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + int main() { + int x = errno; + ; return 0; } + EOF +-if { (eval echo configure:1627: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:1674: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + libiberty_cv_declare_errno=no + else +@@ -1645,12 +1692,12 @@ + + + echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 +-echo "configure:1649: checking for ANSI C header files" >&5 ++echo "configure:1696: checking for ANSI C header files" >&5 + if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #include +@@ -1658,7 +1705,7 @@ + #include + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:1662: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:1709: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + rm -rf conftest* +@@ -1675,7 +1722,7 @@ + if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat > conftest.$ac_ext < + EOF +@@ -1693,7 +1740,7 @@ + if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat > conftest.$ac_ext < + EOF +@@ -1714,7 +1761,7 @@ + : + else + cat > conftest.$ac_ext < + #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +@@ -1725,7 +1772,7 @@ + exit (0); } + + EOF +-if { (eval echo configure:1729: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null ++if { (eval echo configure:1776: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null + then + : + else +@@ -1749,12 +1796,12 @@ + fi + + echo $ac_n "checking for uintptr_t""... $ac_c" 1>&6 +-echo "configure:1753: checking for uintptr_t" >&5 ++echo "configure:1800: checking for uintptr_t" >&5 + if eval "test \"`echo '$''{'ac_cv_type_uintptr_t'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #if STDC_HEADERS +@@ -1790,12 +1837,12 @@ + + + echo $ac_n "checking for pid_t""... $ac_c" 1>&6 +-echo "configure:1794: checking for pid_t" >&5 ++echo "configure:1841: checking for pid_t" >&5 + if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext < + #if STDC_HEADERS +@@ -1895,12 +1942,12 @@ + realpath canonicalize_file_name + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:1899: checking for $ac_func" >&5 ++echo "configure:1946: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:1974: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -2152,53 +2199,6 @@ + + # We haven't set the list of objects yet. Use the standard autoconf + # tests. This will only work if the compiler works. +- echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 +-echo "configure:2157: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +- +-ac_ext=c +-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. +-ac_cpp='$CPP $CPPFLAGS' +-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' +-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' +-cross_compiling=$ac_cv_prog_cc_cross +- +-cat > conftest.$ac_ext << EOF +- +-#line 2168 "configure" +-#include "confdefs.h" +- +-main(){return(0);} +-EOF +-if { (eval echo configure:2173: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +- ac_cv_prog_cc_works=yes +- # If we can't run a trivial program, we are probably using a cross compiler. +- if (./conftest; exit) 2>/dev/null; then +- ac_cv_prog_cc_cross=no +- else +- ac_cv_prog_cc_cross=yes +- fi +-else +- echo "configure: failed program was:" >&5 +- cat conftest.$ac_ext >&5 +- ac_cv_prog_cc_works=no +-fi +-rm -fr conftest* +-ac_ext=c +-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. +-ac_cpp='$CPP $CPPFLAGS' +-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' +-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' +-cross_compiling=$ac_cv_prog_cc_cross +- +-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 +-if test $ac_cv_prog_cc_works = no; then +- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } +-fi +-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 +-echo "configure:2199: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 +-cross_compiling=$ac_cv_prog_cc_cross +- + for ac_func in $funcs + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +@@ -2900,7 +2900,7 @@ + esac + + +-for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h ++for ac_hdr in unistd.h + do + ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` + echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +@@ -3032,24 +3032,11 @@ + #include + #include + +-#if HAVE_SYS_TYPES_H +-# include +-#endif +- +-#if HAVE_STDLIB_H +-# include +-#endif +- +-#if HAVE_SYS_STAT_H +-# include +-#endif +- +-#if HAVE_UNISTD_H +-# include +-#endif +- + /* This mess was copied from the GNU getpagesize.h. */ + #ifndef HAVE_GETPAGESIZE ++# ifdef HAVE_UNISTD_H ++# include ++# endif + + /* Assume that all systems that can run configure have sys/param.h. */ + # ifndef HAVE_SYS_PARAM_H +@@ -3157,7 +3144,7 @@ + } + + EOF +-if { (eval echo configure:3161: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null ++if { (eval echo configure:3148: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null + then + ac_cv_func_mmap_fixed_mapped=yes + else +@@ -3181,7 +3168,7 @@ + + + echo $ac_n "checking for working strncmp""... $ac_c" 1>&6 +-echo "configure:3185: checking for working strncmp" >&5 ++echo "configure:3172: checking for working strncmp" >&5 + if eval "test \"`echo '$''{'ac_cv_func_strncmp_works'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else +@@ -3189,7 +3176,7 @@ + ac_cv_func_strncmp_works=no + else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null ++if { (eval echo configure:3244: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null + then + ac_cv_func_strncmp_works=yes + else diff --git a/meta/packages/gdb/files/sim-install.patch b/meta/packages/gdb/files/sim-install.patch new file mode 100644 index 000000000..3c88c4c05 --- /dev/null +++ b/meta/packages/gdb/files/sim-install.patch @@ -0,0 +1,34 @@ +--- gdb-6.1/sim/common/Makefile.in~ 2004-01-15 21:25:06.000000000 +0000 ++++ gdb-6.1/sim/common/Makefile.in 2004-07-22 17:07:46.237809032 +0100 +@@ -34,7 +34,7 @@ + + datadir = @datadir@ + mandir = @mandir@ +-man1dir = $(mandir)/man1 ++man1dir = $(DESTDIR)$(mandir)/man1 + infodir = @infodir@ + includedir = @includedir@ + + +--- gdb-6.1/sim/common/Make-common.in~sim-install.patch 2003-09-08 18:24:59.000000000 +0100 ++++ gdb-6.1/sim/common/Make-common.in 2004-07-22 17:56:18.947423032 +0100 +@@ -581,14 +581,14 @@ + + install-common: installdirs + n=`echo run | sed '$(program_transform_name)'`; \ +- $(INSTALL_PROGRAM) run$(EXEEXT) $(bindir)/$$n$(EXEEXT) ++ $(INSTALL_PROGRAM) run$(EXEEXT) $(DESTDIR)$(bindir)/$$n$(EXEEXT) + n=`echo libsim.a | sed s/libsim.a/lib$(target_alias)-sim.a/`; \ +- $(INSTALL_DATA) libsim.a $(libdir)/$$n ; \ +- ( cd $(libdir) ; $(RANLIB) $$n ) ++ $(INSTALL_DATA) libsim.a $(DESTDIR)$(libdir)/$$n ; \ ++ ( cd $(DESTDIR)$(libdir) ; $(RANLIB) $$n ) + + installdirs: +- $(SHELL) $(srcdir)/../../mkinstalldirs $(bindir) +- $(SHELL) $(srcdir)/../../mkinstalldirs $(libdir) ++ $(SHELL) $(srcdir)/../../mkinstalldirs $(DESTDIR)$(bindir) ++ $(SHELL) $(srcdir)/../../mkinstalldirs $(DESTDIR)$(libdir) + + check: + cd ../testsuite && $(MAKE) check RUNTESTFLAGS="$(RUNTESTFLAGS)" diff --git a/meta/packages/gdb/files/uclibc.patch b/meta/packages/gdb/files/uclibc.patch new file mode 100644 index 000000000..3d6b7ba18 --- /dev/null +++ b/meta/packages/gdb/files/uclibc.patch @@ -0,0 +1,194 @@ +--- binutils-2.15.91.0.1/bfd/config.bfd~binutils-2.15.90.0.3-uclibc-100-conf ++++ binutils-2.15.91.0.1/bfd/config.bfd +@@ -128,7 +128,7 @@ + targ_defvec=ecoffalpha_little_vec + targ_selvecs=bfd_elf64_alpha_vec + ;; +- alpha*-*-linux-gnu* | alpha*-*-elf*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc* | alpha*-*-elf*) + targ_defvec=bfd_elf64_alpha_vec + targ_selvecs=ecoffalpha_little_vec + ;; +@@ -138,7 +138,7 @@ + alpha*-*-*) + targ_defvec=ecoffalpha_little_vec + ;; +- ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf* | ia64*-*-kfreebsd*-gnu) ++ ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf* | ia64*-*-linux-uclibc* | ia64*-*-kfreebsd*-gnu) + targ_defvec=bfd_elf64_ia64_little_vec + targ_selvecs="bfd_elf64_ia64_big_vec bfd_efi_app_ia64_vec" + ;; +@@ -215,7 +215,7 @@ + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec + ;; +- armeb-*-elf | arm*b-*-linux-gnu*) ++ armeb-*-elf | arm*b-*-linux-gnu* | arm*b-*-linux-uclibc*) + targ_defvec=bfd_elf32_bigarm_vec + targ_selvecs=bfd_elf32_littlearm_vec + ;; +@@ -223,8 +223,8 @@ + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec + ;; +- arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-conix* | \ +- arm*-*-uclinux* | arm-*-kfreebsd*-gnu | arm-*-vxworks) ++ arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-linux-uclibc* | \ ++ arm*-*-conix* | arm*-*-uclinux* | arm-*-kfreebsd*-gnu | arm-*-vxworks) + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec + ;; +@@ -367,7 +367,7 @@ + ;; + + #ifdef BFD64 +- hppa*64*-*-linux-gnu*) ++ hppa*64*-*-linux-gnu* | hppa*64*-*-linux-uclibc*) + targ_defvec=bfd_elf64_hppa_linux_vec + targ_selvecs=bfd_elf64_hppa_vec + ;; +@@ -378,7 +378,7 @@ + ;; + #endif + +- hppa*-*-linux-gnu* | hppa*-*-netbsd*) ++ hppa*-*-linux-gnu* | hppa*-*-netbsd* | hppa*-*-linux-uclibc*) + targ_defvec=bfd_elf32_hppa_linux_vec + targ_selvecs=bfd_elf32_hppa_vec + ;; +@@ -501,7 +501,7 @@ + targ_selvecs=bfd_elf32_i386_vec + targ_underscore=yes + ;; +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + targ_defvec=bfd_elf32_i386_vec + targ_selvecs="i386linux_vec bfd_efi_app_ia32_vec" + targ64_selvecs=bfd_elf64_x86_64_vec +@@ -515,7 +515,7 @@ + targ_defvec=bfd_elf64_x86_64_vec + targ_selvecs="bfd_elf32_i386_vec i386netbsd_vec i386coff_vec bfd_efi_app_ia32_vec" + ;; +- x86_64-*-linux-gnu*) ++ x86_64-*-linux-gnu* | x86_64-*-linux-uclibc*) + targ_defvec=bfd_elf64_x86_64_vec + targ_selvecs="bfd_elf32_i386_vec i386linux_vec bfd_efi_app_ia32_vec" + ;; +@@ -690,7 +690,7 @@ + targ_selvecs=bfd_elf32_m68k_vec + targ_underscore=yes + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + targ_defvec=bfd_elf32_m68k_vec + targ_selvecs=m68klinux_vec + ;; +@@ -966,7 +966,8 @@ + ;; + #endif + powerpc-*-*bsd* | powerpc-*-elf* | powerpc-*-sysv4* | powerpc-*-eabi* | \ +- powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-rtems* | \ ++ powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-linux-uclibc* | \ ++ powerpc-*-rtems* | \ + powerpc-*-chorus* | powerpc-*-vxworks* | powerpc-*-windiss*) + targ_defvec=bfd_elf32_powerpc_vec + targ_selvecs="rs6000coff_vec bfd_elf32_powerpcle_vec ppcboot_vec" +@@ -1003,8 +1004,8 @@ + targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec" + ;; + powerpcle-*-elf* | powerpcle-*-sysv4* | powerpcle-*-eabi* | \ +- powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-vxworks* |\ +- powerpcle-*-rtems*) ++ powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-linux-uclibc* |\ ++ powerpcle-*-vxworks* | powerpcle-*-rtems*) + targ_defvec=bfd_elf32_powerpcle_vec + targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec" + targ64_selvecs="bfd_elf64_powerpc_vec bfd_elf64_powerpcle_vec" +@@ -1165,7 +1166,7 @@ + targ_selvecs="bfd_elf32_sparc_vec sunos_big_vec" + targ_underscore=yes + ;; +- sparc-*-linux-gnu*) ++ sparc-*-linux-gnu* | sparc-*-linux-uclibc*) + targ_defvec=bfd_elf32_sparc_vec + targ_selvecs="sparclinux_vec bfd_elf64_sparc_vec sunos_big_vec" + ;; +@@ -1212,7 +1213,7 @@ + targ_defvec=sunos_big_vec + targ_underscore=yes + ;; +- sparc64-*-linux-gnu*) ++ sparc64-*-linux-gnu* | sparc64-*-linux-uclibc*) + targ_defvec=bfd_elf64_sparc_vec + targ_selvecs="bfd_elf32_sparc_vec sparclinux_vec sunos_big_vec" + ;; +--- binutils-2.15.91.0.1/bfd/configure~binutils-2.15.90.0.3-uclibc-100-conf ++++ binutils-2.15.91.0.1/bfd/configure +@@ -1687,6 +1687,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +@@ -5266,7 +5271,7 @@ + alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu) + COREFILE='' + ;; +- alpha*-*-linux-gnu*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/alphalinux.h"' + ;; +@@ -5326,7 +5331,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386mach3.h"' + ;; +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386linux.h"' + ;; +@@ -5364,7 +5369,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/hp300bsd.h"' + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/m68klinux.h"' + ;; +--- binutils-2.15.91.0.1/bfd/configure.in~binutils-2.15.90.0.3-uclibc-100-conf ++++ binutils-2.15.91.0.1/bfd/configure.in +@@ -164,7 +164,7 @@ + alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu) + COREFILE='' + ;; +- alpha*-*-linux-gnu*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/alphalinux.h"' + ;; +@@ -245,7 +245,7 @@ + TRAD_HEADER='"hosts/i386mach3.h"' + ;; + changequote(,)dnl +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + changequote([,])dnl + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386linux.h"' +@@ -286,7 +286,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/hp300bsd.h"' + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/m68klinux.h"' + ;; diff --git a/meta/packages/gdb/gdb-6.3/uclibc.patch b/meta/packages/gdb/gdb-6.3/uclibc.patch new file mode 100644 index 000000000..b3981202f --- /dev/null +++ b/meta/packages/gdb/gdb-6.3/uclibc.patch @@ -0,0 +1,194 @@ +--- gdb-6.3/bfd/config.bfd.orig 2004-10-15 06:47:11.000000000 +0100 ++++ gdb-6.3/bfd/config.bfd 2005-01-05 19:30:32.000000000 +0000 +@@ -129,7 +129,7 @@ + targ_defvec=ecoffalpha_little_vec + targ_selvecs=bfd_elf64_alpha_vec + ;; +- alpha*-*-linux-gnu* | alpha*-*-elf*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc* | alpha*-*-elf*) + targ_defvec=bfd_elf64_alpha_vec + targ_selvecs=ecoffalpha_little_vec + ;; +@@ -139,7 +139,7 @@ + alpha*-*-*) + targ_defvec=ecoffalpha_little_vec + ;; +- ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf* | ia64*-*-kfreebsd*-gnu) ++ ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf* | ia64*-*-linux-uclibc* | ia64*-*-kfreebsd*-gnu) + targ_defvec=bfd_elf64_ia64_little_vec + targ_selvecs="bfd_elf64_ia64_big_vec bfd_efi_app_ia64_vec" + ;; +@@ -216,7 +216,7 @@ + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec + ;; +- armeb-*-elf | arm*b-*-linux-gnu*) ++ armeb-*-elf | arm*b-*-linux-gnu* | arm*b-*-linux-uclibc*) + targ_defvec=bfd_elf32_bigarm_vec + targ_selvecs=bfd_elf32_littlearm_vec + ;; +@@ -224,8 +224,8 @@ + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec + ;; +- arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-conix* | \ +- arm*-*-uclinux* | arm-*-kfreebsd*-gnu | arm-*-vxworks | \ ++ arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-linux-uclibc* | \ ++ arm*-*-conix* | arm*-*-uclinux* | arm-*-kfreebsd*-gnu | arm-*-vxworks | \ + arm*-*-eabi* ) + targ_defvec=bfd_elf32_littlearm_vec + targ_selvecs=bfd_elf32_bigarm_vec +@@ -378,7 +378,7 @@ + ;; + + #ifdef BFD64 +- hppa*64*-*-linux-gnu*) ++ hppa*64*-*-linux-gnu* | hppa*64*-*-linux-uclibc*) + targ_defvec=bfd_elf64_hppa_linux_vec + targ_selvecs=bfd_elf64_hppa_vec + ;; +@@ -389,7 +389,7 @@ + ;; + #endif + +- hppa*-*-linux-gnu*) ++ hppa*-*-linux-gnu* | hppa*-*-linux-uclibc*) + targ_defvec=bfd_elf32_hppa_linux_vec + targ_selvecs=bfd_elf32_hppa_vec + ;; +@@ -522,7 +522,7 @@ + targ_selvecs=bfd_elf32_i386_vec + targ_underscore=yes + ;; +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + targ_defvec=bfd_elf32_i386_vec + targ_selvecs="i386linux_vec bfd_efi_app_ia32_vec" + targ64_selvecs=bfd_elf64_x86_64_vec +@@ -536,7 +536,7 @@ + targ_defvec=bfd_elf64_x86_64_vec + targ_selvecs="bfd_elf32_i386_vec i386netbsd_vec i386coff_vec bfd_efi_app_ia32_vec" + ;; +- x86_64-*-linux-gnu*) ++ x86_64-*-linux-gnu* | x86_64-*-linux-uclibc*) + targ_defvec=bfd_elf64_x86_64_vec + targ_selvecs="bfd_elf32_i386_vec i386linux_vec bfd_efi_app_ia32_vec" + ;; +@@ -711,7 +711,7 @@ + targ_selvecs=bfd_elf32_m68k_vec + targ_underscore=yes + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + targ_defvec=bfd_elf32_m68k_vec + targ_selvecs=m68klinux_vec + ;; +@@ -987,7 +987,8 @@ + ;; + #endif + powerpc-*-*bsd* | powerpc-*-elf* | powerpc-*-sysv4* | powerpc-*-eabi* | \ +- powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-rtems* | \ ++ powerpc-*-solaris2* | powerpc-*-linux-gnu* | powerpc-*-linux-uclibc* | \ ++ powerpc-*-rtems* | \ + powerpc-*-chorus* | powerpc-*-vxworks* | powerpc-*-windiss*) + targ_defvec=bfd_elf32_powerpc_vec + targ_selvecs="rs6000coff_vec bfd_elf32_powerpcle_vec ppcboot_vec" +@@ -1024,8 +1025,8 @@ + targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec" + ;; + powerpcle-*-elf* | powerpcle-*-sysv4* | powerpcle-*-eabi* | \ +- powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-vxworks* |\ +- powerpcle-*-rtems*) ++ powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-linux-uclibc* |\ ++ powerpcle-*-vxworks* | powerpcle-*-rtems*) + targ_defvec=bfd_elf32_powerpcle_vec + targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec" + targ64_selvecs="bfd_elf64_powerpc_vec bfd_elf64_powerpcle_vec" +@@ -1192,7 +1193,7 @@ + targ_selvecs="bfd_elf32_sparc_vec sunos_big_vec" + targ_underscore=yes + ;; +- sparc-*-linux-gnu*) ++ sparc-*-linux-gnu* | sparc-*-linux-uclibc*) + targ_defvec=bfd_elf32_sparc_vec + targ_selvecs="sparclinux_vec bfd_elf64_sparc_vec sunos_big_vec" + ;; +@@ -1239,7 +1240,7 @@ + targ_defvec=sunos_big_vec + targ_underscore=yes + ;; +- sparc64-*-linux-gnu*) ++ sparc64-*-linux-gnu* | sparc64-*-linux-uclibc*) + targ_defvec=bfd_elf64_sparc_vec + targ_selvecs="bfd_elf32_sparc_vec sparclinux_vec sunos_big_vec" + ;; +--- gdb-6.3/bfd/configure.in.orig 2004-10-08 15:53:59.000000000 +0100 ++++ gdb-6.3/bfd/configure.in 2005-01-05 19:28:50.000000000 +0000 +@@ -163,7 +163,7 @@ + alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu) + COREFILE='' + ;; +- alpha*-*-linux-gnu*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/alphalinux.h"' + ;; +@@ -248,7 +248,7 @@ + TRAD_HEADER='"hosts/i386mach3.h"' + ;; + changequote(,)dnl +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + changequote([,])dnl + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386linux.h"' +@@ -289,7 +289,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/hp300bsd.h"' + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/m68klinux.h"' + ;; +--- gdb-6.3/bfd/configure.orig 2004-10-08 15:53:56.000000000 +0100 ++++ gdb-6.3/bfd/configure 2005-01-05 19:29:27.000000000 +0000 +@@ -3583,6 +3583,11 @@ + lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` + ;; + ++linux-uclibc*) ++ lt_cv_deplibs_check_method=pass_all ++ lt_cv_file_magic_test_file=`echo /lib/libuClibc-*.so` ++ ;; ++ + netbsd* | knetbsd*-gnu) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$' +@@ -9914,7 +9919,7 @@ + alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu) + COREFILE='' + ;; +- alpha*-*-linux-gnu*) ++ alpha*-*-linux-gnu* | alpha*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/alphalinux.h"' + ;; +@@ -9978,7 +9983,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386mach3.h"' + ;; +- i[3-7]86-*-linux-gnu*) ++ i[3-7]86-*-linux-gnu* | i[3-7]86-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/i386linux.h"' + ;; +@@ -10016,7 +10021,7 @@ + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/hp300bsd.h"' + ;; +- m68*-*-linux-gnu*) ++ m68*-*-linux-gnu* | m68*-*-linux-uclibc*) + COREFILE=trad-core.lo + TRAD_HEADER='"hosts/m68klinux.h"' + ;; diff --git a/meta/packages/gdb/gdb-cross_6.3.bb b/meta/packages/gdb/gdb-cross_6.3.bb new file mode 100644 index 000000000..a6823b637 --- /dev/null +++ b/meta/packages/gdb/gdb-cross_6.3.bb @@ -0,0 +1,36 @@ +LICENSE = "GPL" +DESCRIPTION = "gdb - GNU debugger" +SECTION = "base" +PRIORITY = "optional" +MAINTAINER = "Phil Blundell " +DEPENDS = "ncurses-native" + +inherit autotools sdk + +S = "${WORKDIR}/gdb-${PV}" +SRC_URI = "${GNU_MIRROR}/gdb/gdb-${PV}.tar.gz \ + file://sim-install.patch;patch=1" + +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/gdb-${PV}" + +export CC_FOR_BUILD = "${BUILD_CC}" +export CXX_FOR_BUILD = "${BUILD_CXX}" +export CPP_FOR_BUILD = "${BUILD_CPP}" +export CFLAGS_FOR_BUILD = "${BUILD_CFLAGS}" +export CXXFLAGS_FOR_BUILD = "${BUILD_CXXFLAGS}" +export CPPFLAGS_FOR_BUILD = "${BUILD_CPPFLAGS}" + +EXTRA_OEMAKE = "'SUBDIRS=intl mmalloc libiberty opcodes bfd sim gdb etc utils' LDFLAGS='${BUILD_LDFLAGS}'" + +EXTRA_OECONF = "--with-curses --with-readline" + +do_configure () { +# override this function to avoid the autoconf/automake/aclocal/autoheader +# calls for now + gnu-configize + oe_runconf +} + +do_stage() { + : +} diff --git a/meta/packages/gdb/gdb_6.3.bb b/meta/packages/gdb/gdb_6.3.bb new file mode 100644 index 000000000..3e755cee6 --- /dev/null +++ b/meta/packages/gdb/gdb_6.3.bb @@ -0,0 +1,50 @@ +DESCRIPTION = "gdb - GNU debugger" +HOMEPAGE = "http://www.gnu.org/software/gdb/" +LICENSE="GPL" +SECTION = "devel" +PRIORITY = "optional" +MAINTAINER = "Pawel Osiczko " +DEPENDS = "ncurses readline" +RDEPENDS_openmn = "libthread-db1" +PR = "r2" + +PACKAGES =+ 'gdbserver ' +FILES_gdbserver = '${bindir}/gdbserver' + +inherit autotools gettext + +SRC_URI = "${GNU_MIRROR}/gdb/gdb-${PV}.tar.gz \ + file://uclibc.patch;patch=1 \ + file://kill_arm_map_symbols.patch;patch=1 \ + file://gdbserver-cflags-last.diff;patch=1;pnum=0" + +LDFLAGS_append = " -s" +export CC_FOR_BUILD = "${BUILD_CC}" +export CXX_FOR_BUILD = "${BUILD_CXX}" +export CPP_FOR_BUILD = "${BUILD_CPP}" +export CFLAGS_FOR_BUILD = "${BUILD_CFLAGS}" +export CXXFLAGS_FOR_BUILD = "${BUILD_CXXFLAGS}" +export CPPFLAGS_FOR_BUILD = "${BUILD_CPPFLAGS}" +export CFLAGS_append=" -L${STAGING_LIBDIR}" +EXTRA_OEMAKE = "'SUBDIRS=intl mmalloc libiberty opcodes bfd sim gdb etc utils'" + +EXTRA_OECONF = "--disable-gdbtk --disable-tui --disable-x \ + --with-curses --disable-multilib --with-readline --disable-sim \ + --program-prefix=''" + +S = "${WORKDIR}/gdb-${PV}" +B = "${WORKDIR}/build-${TARGET_SYS}" + +do_configure () { +# override this function to avoid the autoconf/automake/aclocal/autoheader +# calls for now + (cd ${S} && gnu-configize) || die "failure in running gnu-configize" + CPPFLAGS="" oe_runconf +} + +do_install () { + make -C bfd/doc chew LDFLAGS= CFLAGS=-O2 + oe_runmake DESTDIR='${D}' install + install -d ${D}${bindir} + install -m 0755 gdb/gdbserver/gdbserver ${D}${bindir} +} diff --git a/meta/packages/gdbm/gdbm-1.8.3/libtool-mode.patch b/meta/packages/gdbm/gdbm-1.8.3/libtool-mode.patch new file mode 100644 index 000000000..c56bac2ca --- /dev/null +++ b/meta/packages/gdbm/gdbm-1.8.3/libtool-mode.patch @@ -0,0 +1,20 @@ +--- gdbm-1.8.3/Makefile.in.orig 2006-02-16 15:17:25.000000000 +0000 ++++ gdbm-1.8.3/Makefile.in 2006-02-16 15:18:08.000000000 +0000 +@@ -131,7 +131,7 @@ + $(srcdir)/mkinstalldirs $(DESTDIR)$(libdir) \ + $(DESTDIR)$(includedir) $(DESTDIR)$(man3dir) \ + $(DESTDIR)$(infodir) +- $(LIBTOOL) $(INSTALL) -c libgdbm.la $(DESTDIR)$(libdir)/libgdbm.la ++ $(LIBTOOL) --mode=install $(INSTALL) -c libgdbm.la $(DESTDIR)$(libdir)/libgdbm.la + $(INSTALL_DATA) gdbm.h \ + $(DESTDIR)$(includedir)/gdbm.h + $(INSTALL_DATA) $(srcdir)/gdbm.3 \ +@@ -142,7 +142,7 @@ + install-compat: + $(srcdir)/mkinstalldirs $(DESTDIR)$(libdir) \ + $(DESTDIR)$(includedir) +- $(LIBTOOL) $(INSTALL) -c libgdbm_compat.la \ ++ $(LIBTOOL) --mode=install $(INSTALL) -c libgdbm_compat.la \ + $(DESTDIR)$(libdir)/libgdbm_compat.la + $(INSTALL_DATA) $(srcdir)/dbm.h \ + $(DESTDIR)$(includedir)/dbm.h diff --git a/meta/packages/gdbm/gdbm-1.8.3/makefile.patch b/meta/packages/gdbm/gdbm-1.8.3/makefile.patch new file mode 100644 index 000000000..5350c5372 --- /dev/null +++ b/meta/packages/gdbm/gdbm-1.8.3/makefile.patch @@ -0,0 +1,59 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- gdbm-1.8.3/Makefile.in~makefile ++++ gdbm-1.8.3/Makefile.in +@@ -22,6 +22,7 @@ + TEXI2DVI = texi2dvi + + DEFS = ++DESTDIR = + + # Where the system [n]dbm routines are... + LIBS = @LIBS@ -lc +@@ -127,26 +128,26 @@ + progs: $(PROGS) + + install: libgdbm.la gdbm.h gdbm.info +- $(srcdir)/mkinstalldirs $(INSTALL_ROOT)$(libdir) \ +- $(INSTALL_ROOT)$(includedir) $(INSTALL_ROOT)$(man3dir) \ +- $(INSTALL_ROOT)$(infodir) +- $(LIBTOOL) $(INSTALL) -c libgdbm.la $(INSTALL_ROOT)$(libdir)/libgdbm.la +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) gdbm.h \ +- $(INSTALL_ROOT)$(includedir)/gdbm.h +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) $(srcdir)/gdbm.3 \ +- $(INSTALL_ROOT)$(man3dir)/gdbm.3 +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) $(srcdir)/gdbm.info \ +- $(INSTALL_ROOT)$(infodir)/gdbm.info ++ $(srcdir)/mkinstalldirs $(DESTDIR)$(libdir) \ ++ $(DESTDIR)$(includedir) $(DESTDIR)$(man3dir) \ ++ $(DESTDIR)$(infodir) ++ $(LIBTOOL) $(INSTALL) -c libgdbm.la $(DESTDIR)$(libdir)/libgdbm.la ++ $(INSTALL_DATA) gdbm.h \ ++ $(DESTDIR)$(includedir)/gdbm.h ++ $(INSTALL_DATA) $(srcdir)/gdbm.3 \ ++ $(DESTDIR)$(man3dir)/gdbm.3 ++ $(INSTALL_DATA) $(srcdir)/gdbm.info \ ++ $(DESTDIR)$(infodir)/gdbm.info + + install-compat: +- $(srcdir)/mkinstalldirs $(INSTALL_ROOT)$(libdir) \ +- $(INSTALL_ROOT)$(includedir) ++ $(srcdir)/mkinstalldirs $(DESTDIR)$(libdir) \ ++ $(DESTDIR)$(includedir) + $(LIBTOOL) $(INSTALL) -c libgdbm_compat.la \ +- $(INSTALL_ROOT)$(libdir)/libgdbm_compat.la +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) $(srcdir)/dbm.h \ +- $(INSTALL_ROOT)$(includedir)/dbm.h +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) $(srcdir)/ndbm.h \ +- $(INSTALL_ROOT)$(includedir)/ndbm.h ++ $(DESTDIR)$(libdir)/libgdbm_compat.la ++ $(INSTALL_DATA) $(srcdir)/dbm.h \ ++ $(DESTDIR)$(includedir)/dbm.h ++ $(INSTALL_DATA) $(srcdir)/ndbm.h \ ++ $(DESTDIR)$(includedir)/ndbm.h + + #libgdbm.a: $(OBJS) gdbm.h + # rm -f libgdbm.a diff --git a/meta/packages/gdbm/gdbm-native-1.8.3/makefile.patch b/meta/packages/gdbm/gdbm-native-1.8.3/makefile.patch new file mode 100644 index 000000000..5350c5372 --- /dev/null +++ b/meta/packages/gdbm/gdbm-native-1.8.3/makefile.patch @@ -0,0 +1,59 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- gdbm-1.8.3/Makefile.in~makefile ++++ gdbm-1.8.3/Makefile.in +@@ -22,6 +22,7 @@ + TEXI2DVI = texi2dvi + + DEFS = ++DESTDIR = + + # Where the system [n]dbm routines are... + LIBS = @LIBS@ -lc +@@ -127,26 +128,26 @@ + progs: $(PROGS) + + install: libgdbm.la gdbm.h gdbm.info +- $(srcdir)/mkinstalldirs $(INSTALL_ROOT)$(libdir) \ +- $(INSTALL_ROOT)$(includedir) $(INSTALL_ROOT)$(man3dir) \ +- $(INSTALL_ROOT)$(infodir) +- $(LIBTOOL) $(INSTALL) -c libgdbm.la $(INSTALL_ROOT)$(libdir)/libgdbm.la +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) gdbm.h \ +- $(INSTALL_ROOT)$(includedir)/gdbm.h +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) $(srcdir)/gdbm.3 \ +- $(INSTALL_ROOT)$(man3dir)/gdbm.3 +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) $(srcdir)/gdbm.info \ +- $(INSTALL_ROOT)$(infodir)/gdbm.info ++ $(srcdir)/mkinstalldirs $(DESTDIR)$(libdir) \ ++ $(DESTDIR)$(includedir) $(DESTDIR)$(man3dir) \ ++ $(DESTDIR)$(infodir) ++ $(LIBTOOL) $(INSTALL) -c libgdbm.la $(DESTDIR)$(libdir)/libgdbm.la ++ $(INSTALL_DATA) gdbm.h \ ++ $(DESTDIR)$(includedir)/gdbm.h ++ $(INSTALL_DATA) $(srcdir)/gdbm.3 \ ++ $(DESTDIR)$(man3dir)/gdbm.3 ++ $(INSTALL_DATA) $(srcdir)/gdbm.info \ ++ $(DESTDIR)$(infodir)/gdbm.info + + install-compat: +- $(srcdir)/mkinstalldirs $(INSTALL_ROOT)$(libdir) \ +- $(INSTALL_ROOT)$(includedir) ++ $(srcdir)/mkinstalldirs $(DESTDIR)$(libdir) \ ++ $(DESTDIR)$(includedir) + $(LIBTOOL) $(INSTALL) -c libgdbm_compat.la \ +- $(INSTALL_ROOT)$(libdir)/libgdbm_compat.la +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) $(srcdir)/dbm.h \ +- $(INSTALL_ROOT)$(includedir)/dbm.h +- $(INSTALL_DATA) -o $(BINOWN) -g $(BINGRP) $(srcdir)/ndbm.h \ +- $(INSTALL_ROOT)$(includedir)/ndbm.h ++ $(DESTDIR)$(libdir)/libgdbm_compat.la ++ $(INSTALL_DATA) $(srcdir)/dbm.h \ ++ $(DESTDIR)$(includedir)/dbm.h ++ $(INSTALL_DATA) $(srcdir)/ndbm.h \ ++ $(DESTDIR)$(includedir)/ndbm.h + + #libgdbm.a: $(OBJS) gdbm.h + # rm -f libgdbm.a diff --git a/meta/packages/gdbm/gdbm-native_1.8.3.bb b/meta/packages/gdbm/gdbm-native_1.8.3.bb new file mode 100644 index 000000000..adfc0459c --- /dev/null +++ b/meta/packages/gdbm/gdbm-native_1.8.3.bb @@ -0,0 +1,17 @@ +DESCRIPTION = "GNU dbm is a set of database routines that use extensible hashing." +HOMEPAGE = "http://www.gnu.org/software/gdbm/gdbm.html" +SECTION = "libs" +PRIORITY = "optional" +LICENSE = "GPL" +PR = "r2" + +SRC_URI = "${GNU_MIRROR}/gdbm/gdbm-${PV}.tar.gz \ + file://makefile.patch;patch=1" +S = "${WORKDIR}/gdbm-${PV}" + +inherit autotools native + +do_stage () { + oe_libinstall -so -a libgdbm ${STAGING_LIBDIR} + install -m 0644 ${S}/gdbm.h ${STAGING_INCDIR}/ +} diff --git a/meta/packages/gdbm/gdbm_1.8.3.bb b/meta/packages/gdbm/gdbm_1.8.3.bb new file mode 100644 index 000000000..ecef5fc41 --- /dev/null +++ b/meta/packages/gdbm/gdbm_1.8.3.bb @@ -0,0 +1,17 @@ +DESCRIPTION = "GNU dbm is a set of database routines that use extensible hashing." +HOMEPAGE = "http://www.gnu.org/software/gdbm/gdbm.html" +SECTION = "libs" +PRIORITY = "optional" +LICENSE = "GPL" +PR = "r2" + +SRC_URI = "${GNU_MIRROR}/gdbm/gdbm-${PV}.tar.gz \ + file://makefile.patch;patch=1 \ + file://libtool-mode.patch;patch=1" + +inherit autotools + +do_stage () { + oe_libinstall -so -a libgdbm ${STAGING_LIBDIR} + install -m 0644 ${S}/gdbm.h ${STAGING_INCDIR}/ +} diff --git a/meta/packages/genext2fs/genext2fs-1.3/autosize.patch b/meta/packages/genext2fs/genext2fs-1.3/autosize.patch new file mode 100644 index 000000000..a4318a6ee --- /dev/null +++ b/meta/packages/genext2fs/genext2fs-1.3/autosize.patch @@ -0,0 +1,339 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- genext2fs-1.3.orig/genext2fs.c~autosize.patch ++++ genext2fs-1.3.orig/genext2fs.c +@@ -4,6 +4,11 @@ + // ext2 filesystem generator for embedded systems + // Copyright (C) 2000 Xavier Bestel + // ++// 'du' portions taken from coreutils/du.c in busybox: ++// Copyright (C) 1999,2000 by Lineo, inc. and John Beppu ++// Copyright (C) 1999,2000,2001 by John Beppu ++// Copyright (C) 2002 Edward Betts ++// + // This program is free software; you can redistribute it and/or + // modify it under the terms of the GNU General Public License + // as published by the Free Software Foundation; version +@@ -79,9 +84,93 @@ + #include + #include + #include ++#include ++#include ++ ++#define HASH_SIZE 311 /* Should be prime */ ++#define hash_inode(i) ((i) % HASH_SIZE) ++ ++typedef struct ino_dev_hash_bucket_struct { ++ struct ino_dev_hash_bucket_struct *next; ++ ino_t ino; ++ dev_t dev; ++ char name[1]; ++} ino_dev_hashtable_bucket_t; ++ ++static ino_dev_hashtable_bucket_t *ino_dev_hashtable[HASH_SIZE]; ++ ++struct stats { ++ unsigned long nblocks; ++ unsigned long ninodes; ++}; ++ ++int is_in_ino_dev_hashtable(const struct stat *statbuf, char **name) ++{ ++ ino_dev_hashtable_bucket_t *bucket; ++ ++ bucket = ino_dev_hashtable[hash_inode(statbuf->st_ino)]; ++ while (bucket != NULL) { ++ if ((bucket->ino == statbuf->st_ino) && ++ (bucket->dev == statbuf->st_dev)) ++ { ++ if (name) *name = bucket->name; ++ return 1; ++ } ++ bucket = bucket->next; ++ } ++ return 0; ++} ++ ++/* Add statbuf to statbuf hash table */ ++void add_to_ino_dev_hashtable(const struct stat *statbuf, const char *name) ++{ ++ int i; ++ size_t s; ++ ino_dev_hashtable_bucket_t *bucket; ++ ++ i = hash_inode(statbuf->st_ino); ++ s = name ? strlen(name) : 0; ++ bucket = malloc(sizeof(ino_dev_hashtable_bucket_t) + s); ++ bucket->ino = statbuf->st_ino; ++ bucket->dev = statbuf->st_dev; ++ if (name) ++ strcpy(bucket->name, name); ++ else ++ bucket->name[0] = '\0'; ++ bucket->next = ino_dev_hashtable[i]; ++ ino_dev_hashtable[i] = bucket; ++} ++ ++/* Clear statbuf hash table */ ++void reset_ino_dev_hashtable(void) ++{ ++ int i; ++ ino_dev_hashtable_bucket_t *bucket; ++ ++ for (i = 0; i < HASH_SIZE; i++) { ++ while (ino_dev_hashtable[i] != NULL) { ++ bucket = ino_dev_hashtable[i]->next; ++ free(ino_dev_hashtable[i]); ++ ino_dev_hashtable[i] = bucket; ++ } ++ } ++} + ++static int count_ino_in_hashtable(void) ++{ ++ long count = 0; ++ int i; + ++ for (i = 0; i < HASH_SIZE; i++) { ++ ino_dev_hashtable_bucket_t *bucket = ino_dev_hashtable[i]; ++ while (bucket != NULL) { ++ count++; ++ bucket = bucket->next; ++ } ++ } + ++ return count; ++} + + // block size + +@@ -1178,6 +1267,38 @@ + return n; + } + ++void stats_from_dir(struct stats *stats) ++{ ++ DIR *dh; ++ struct dirent *dent; ++ struct stat st; ++ if(!(dh = opendir("."))) ++ perror_msg_and_die("."); ++ while((dent = readdir(dh))) ++ { ++ if((!strcmp(dent->d_name, ".")) || (!strcmp(dent->d_name, ".."))) ++ continue; ++ lstat(dent->d_name, &st); ++ if (S_ISLNK(st.st_mode)) { ++ stats->ninodes++; ++ } else if (S_ISDIR(st.st_mode)) { ++ if(chdir(dent->d_name) < 0) ++ perror_msg_and_die(dent->d_name); ++ stats->ninodes++; ++ stats_from_dir(stats); ++ chdir(".."); ++ } else { ++ if (!is_in_ino_dev_hashtable(&st, NULL)) { ++ add_to_ino_dev_hashtable(&st, NULL); ++ stats->nblocks += (st.st_blocks >> 1); ++ stats->ninodes++; ++ } ++ } ++ } ++ closedir(dh); ++ reset_ino_dev_hashtable(); ++} ++ + // adds a tree of entries to the filesystem from current dir + void add2fs_from_dir(filesystem *fs, uint32 this_nod) + { +@@ -1436,7 +1557,6 @@ + free_blocks_per_group = nbblocks_per_group - overhead_per_group; + } + nbblocks = nbblocks_per_group * nbgroups + 1; +- + + if(!(fs = (filesystem*)calloc(nbblocks, BLOCKSIZE))) + error_msg_and_die("not enough memory for filesystem"); +@@ -1891,6 +2011,7 @@ + Regular files must exist in the target root directory. If a char, + block, fifo, or directory does not exist, it will be created. + */ ++ + static int interpret_table_entry(filesystem *fs, char *line) + { + char type, *name = NULL, *tmp, *dir, *bname; +@@ -2026,6 +2147,52 @@ + return 0; + } + ++static int stats_from_table_entry(char *line, struct stats *stats) ++{ ++ char type, *name = NULL, *tmp, *dir, *bname; ++ unsigned long mode = 0755, uid = 0, gid = 0, major = 0, minor = 0; ++ unsigned long start = 0, increment = 1, count = 0; ++ inode *entry; ++ ++ if (sscanf (line, "%" SCANF_PREFIX "s %c %lo %lu %lu %lu %lu %lu %lu %lu", ++ SCANF_STRING(name), &type, &mode, &uid, &gid, &major, &minor, ++ &start, &increment, &count) < 0) ++ { ++ return 1; ++ } ++ ++ if (!strcmp(name, "/")) { ++ error_msg_and_die("Device table entries require absolute paths"); ++ } ++ ++ tmp = xstrdup(name); ++ bname = xstrdup(basename(tmp)); ++ free(tmp); ++ switch (type) { ++ case 'd': ++ stats->ninodes++; ++ break; ++ case 'c': ++ case 'b': ++ if (count > 0) { ++ dev_t rdev; ++ char *dname; ++ unsigned long i; ++ for (i = start; i < count; i++) { ++ asprintf(&dname, "%s%lu", bname, i); ++ stats->ninodes++; ++ free(dname); ++ } ++ } else { ++ stats->ninodes++; ++ } ++ break; ++ } ++ free(bname); ++ free(name); ++ return 0; ++} ++ + static int parse_device_table(filesystem *root, FILE * file) + { + char *line; +@@ -2070,6 +2237,45 @@ + return status; + } + ++static int stats_from_dev_table(FILE *file, struct stats *stats) ++{ ++ char *line; ++ int status = 0; ++ size_t length = 0; ++ ++ /* Looks ok so far. The general plan now is to read in one ++ * line at a time, check for leading comment delimiters ('#'), ++ * then try and parse the line as a device table. If we fail ++ * to parse things, try and help the poor fool to fix their ++ * device table with a useful error msg... */ ++ line = NULL; ++ while (getline(&line, &length, file) != -1) { ++ /* First trim off any whitespace */ ++ int len = strlen(line); ++ ++ /* trim trailing whitespace */ ++ while (len > 0 && isspace(line[len - 1])) ++ line[--len] = '\0'; ++ /* trim leading whitespace */ ++ memmove(line, &line[strspn(line, " \n\r\t\v")], len); ++ ++ /* How long are we after trimming? */ ++ len = strlen(line); ++ ++ /* If this is NOT a comment line, try to interpret it */ ++ if (len && *line != '#') { ++ if (stats_from_table_entry(line, stats)) ++ status = 1; ++ } ++ ++ free(line); ++ line = NULL; ++ } ++ fclose(file); ++ ++ return status; ++} ++ + /* + Local Variables: + c-file-style: "linux" +@@ -2112,6 +2318,8 @@ + int nbblocks = -1; + int nbinodes = -1; + int nbresrvd = -1; ++ int tmp_nbblocks = -1; ++ int tmp_nbinodes = -1; + char * fsout = "-"; + char * fsin = 0; + char * dopt[MAX_DOPT]; +@@ -2128,6 +2336,7 @@ + int c; + struct stat sb; + FILE *devtable = NULL; ++ struct stats stats; + + app_name = argv[0]; + while((c = getopt(argc, argv, "x:d:b:i:r:g:e:zvhD:f:qUP")) != EOF) +@@ -2184,6 +2393,7 @@ + default: + exit(1); + } ++ + if(optind < (argc - 1)) + error_msg_and_die("too many arguments"); + if(optind == (argc - 1)) +@@ -2201,6 +2411,46 @@ + } + else + { ++ stats.ninodes = 0; ++ stats.nblocks = 0; ++ for(i = 0; i < didx; i++) ++ { ++ struct stat st; ++ char *pdir; ++ stat(dopt[i], &st); ++ switch(st.st_mode & S_IFMT) ++ { ++ case S_IFDIR: ++ if(!(pdir = getcwd(0, GETCWD_SIZE))) ++ perror_msg_and_die(dopt[i]); ++ if(chdir(dopt[i]) < 0) ++ perror_msg_and_die(dopt[i]); ++ stats_from_dir(&stats); ++ if(chdir(pdir) < 0) ++ perror_msg_and_die(pdir); ++ free(pdir); ++ break; ++ default: ++ error_msg_and_die("%s is neither a file nor a directory", dopt[i]); ++ } ++ } ++ ++ if(devtable) ++ stats_from_dev_table(devtable, &stats); ++ ++ tmp_nbinodes = stats.ninodes + EXT2_FIRST_INO + 1; ++ tmp_nbblocks = stats.nblocks; ++ ++ if(tmp_nbblocks > nbblocks) ++ { ++ printf("Number of blocks too low, increasing to %d\n",tmp_nbblocks); ++ nbblocks = tmp_nbblocks; ++ } ++ if(tmp_nbinodes > nbinodes) ++ { ++ printf("Number of inodes too low, increasing to %d\n",tmp_nbinodes); ++ nbinodes = tmp_nbinodes; ++ } + if(nbblocks == -1) + error_msg_and_die("filesystem size unspecified"); + if(nbinodes == -1) diff --git a/meta/packages/genext2fs/genext2fs-1.3/misc.patch b/meta/packages/genext2fs/genext2fs-1.3/misc.patch new file mode 100644 index 000000000..e5849eb79 --- /dev/null +++ b/meta/packages/genext2fs/genext2fs-1.3/misc.patch @@ -0,0 +1,2143 @@ +--- genext2fs-1.3.orig/Makefile ++++ genext2fs-1.3/Makefile +@@ -0,0 +1,25 @@ ++all: genext2fs ++INSTALL=install ++ ++install: ++ $(INSTALL) -d $(DESTDIR)/usr/bin/ ++ $(INSTALL) -m 755 genext2fs $(DESTDIR)/usr/bin/ ++ $(INSTALL) -d $(DESTDIR)/usr/share/man/man8/ ++ $(INSTALL) -m 644 genext2fs.8 $(DESTDIR)/usr/share/man/man8/ ++ ++clean: ++ -rm genext2fs ++ rm -rf test ext2.img ++ ++check: all ++ mkdir -p test ++ dd if=/dev/zero of=test/zero count=1 ++ ./genext2fs -b 4096 -d test ext2.img ++ ++ md5=`md5sum ext2.img | cut -f 1 -d " "`; \ ++ if [ "$$md5" != "a736fce6d45ea3631b01fd7b8f623131" ] ; then \ ++ echo "test failed."; \ ++ else \ ++ echo "test succeeded."; \ ++ fi ++ +diff -urN genext2fs-1.3.orig/dev.txt genext2fs-1.3/dev.txt +--- genext2fs-1.3.orig/dev.txt 2000-09-28 09:03:19.000000000 -0600 ++++ genext2fs-1.3/dev.txt 1969-12-31 17:00:00.000000000 -0700 +@@ -1,94 +0,0 @@ +-drwx /dev +-crw- 10,190 /dev/lcd +-crw- 10,191 /dev/splc781 +-crw- 4,0 /dev/console +-crw- 5,64 /dev/cua0 +-crw- 5,65 /dev/cua1 +-crw- 5,66 /dev/cua2 +-crw- 5,70 /dev/cua6 +-crw- 5,71 /dev/cua7 +-crw- 5,72 /dev/cua8 +-crw- 5,73 /dev/cua9 +-crw- 29,0 /dev/fb0 +-crw- 29,32 /dev/fb1 +-crw- 1,2 /dev/kmem +-crw- 1,1 /dev/mem +-crw- 1,3 /dev/null +-crw- 2,2 /dev/ptyp2 +-crw- 2,3 /dev/ptyp3 +-crw- 2,5 /dev/ptyp5 +-crw- 2,4 /dev/ptyp4 +-crw- 10,178 /dev/triokb +-crw- 2,0 /dev/ptyp0 +-crw- 2,6 /dev/ptyp6 +-crw- 2,7 /dev/ptyp7 +-crw- 2,8 /dev/ptyp8 +-crw- 2,9 /dev/ptyp9 +-crw- 2,10 /dev/ptypa +-crw- 2,11 /dev/ptypb +-crw- 2,12 /dev/ptypc +-crw- 2,13 /dev/ptypd +-crw- 2,14 /dev/ptype +-crw- 2,15 /dev/ptypf +-brw- 1,0 /dev/ram0 +-brw- 1,1 /dev/ram1 +-brw- 1,2 /dev/ram2 +-brw- 1,3 /dev/ram3 +-br-- 31,0 /dev/rom0 +-brw- 31,1 /dev/rom1 +-brw- 31,2 /dev/rom2 +-brw- 31,3 /dev/rom3 +-crw- 5,0 /dev/tty +-crw- 4,0 /dev/tty0 +-crwx 4,1 /dev/tty1 +-crwx 4,2 /dev/tty2 +-crwx 4,3 /dev/tty3 +-crwx 4,4 /dev/tty4 +-crw- 4,5 /dev/tty5 +-crwx 4,6 /dev/tty6 +-crw- 4,7 /dev/tty7 +-crw- 4,8 /dev/tty8 +-crw- 4,9 /dev/tty9 +-crw- 4,64 /dev/ttyS0 +-crw- 4,65 /dev/ttyS1 +-crw- 4,66 /dev/ttyS2 +-crw- 4,67 /dev/ttyS3 +-crw- 4,68 /dev/ttyS4 +-crw- 4,69 /dev/ttyS5 +-crw- 4,70 /dev/ttyS6 +-crw- 4,71 /dev/ttyS7 +-crw- 4,72 /dev/ttyS8 +-crw- 4,73 /dev/ttyS9 +-crw- 3,0 /dev/ttyp0 +-crw- 3,1 /dev/ttyp1 +-crw- 3,2 /dev/ttyp2 +-crw- 3,3 /dev/ttyp3 +-crw- 3,4 /dev/ttyp4 +-crw- 3,5 /dev/ttyp5 +-crw- 3,6 /dev/ttyp6 +-crw- 3,7 /dev/ttyp7 +-crw- 3,8 /dev/ttyp8 +-crw- 3,9 /dev/ttyp9 +-crw- 3,10 /dev/ttypa +-crw- 3,11 /dev/ttypb +-crw- 3,12 /dev/ttypc +-crw- 3,13 /dev/ttypd +-crw- 3,14 /dev/ttype +-crw- 3,15 /dev/ttypf +-crw- 1,5 /dev/zero +-crwx 10,111 /dev/dtedrv +-crwx 4,110 /dev/ttyM +-crw- 77,1 /dev/tssnd +-crw- 77,2 /dev/tstone +-crw- 2,1 /dev/ptyp1 +-crwx 10,180 /dev/triohook +-crw- 90,0 /dev/mtd0 +-brw- 44,0 /dev/ftl0 +-crw- 10,175 /dev/tporta +-crw- 10,176 /dev/tportb +-crwx 10,100 /dev/softmodem +-crwx 10,101 /dev/softmodem_signals +-crwx 10,181 /dev/triovoice +-crw- 5,67 /dev/cua3 +-crw- 5,68 /dev/cua4 +-crw- 5,69 /dev/cua5 +diff -urN genext2fs-1.3.orig/device_table.txt genext2fs-1.3/device_table.txt +--- genext2fs-1.3.orig/device_table.txt 1969-12-31 17:00:00.000000000 -0700 ++++ genext2fs-1.3/device_table.txt 2003-04-21 01:41:42.000000000 -0600 +@@ -0,0 +1,129 @@ ++# When building a target filesystem, it is desirable to not have to ++# become root and then run 'mknod' a thousand times. Using a device ++# table you can create device nodes and directories "on the fly". ++# ++# This is a sample device table file for use with genext2fs. You can ++# do all sorts of interesting things with a device table file. For ++# example, if you want to adjust the permissions on a particular file ++# you can just add an entry like: ++# /sbin/foobar f 2755 0 0 - - - - - ++# and (assuming the file /sbin/foobar exists) it will be made setuid ++# root (regardless of what its permissions are on the host filesystem. ++# Furthermore, you can use a single table entry to create a many device ++# minors. For example, if I wanted to create /dev/hda and /dev/hda[0-15] ++# I could just use the following two table entries: ++# /dev/hda b 640 0 0 3 0 0 0 - ++# /dev/hda b 640 0 0 3 1 1 1 15 ++# ++# Device table entries take the form of: ++# ++# where name is the file name, type can be one of: ++# f A regular file ++# d Directory ++# c Character special device file ++# b Block special device file ++# p Fifo (named pipe) ++# uid is the user id for the target file, gid is the group id for the ++# target file. The rest of the entries (major, minor, etc) apply only ++# to device special files. ++ ++# Have fun ++# -Erik Andersen ++# ++ ++# ++/dev d 755 0 0 - - - - - ++/dev/mem c 640 0 0 1 1 0 0 - ++/dev/kmem c 640 0 0 1 2 0 0 - ++/dev/null c 640 0 0 1 3 0 0 - ++/dev/zero c 640 0 0 1 5 0 0 - ++/dev/random c 640 0 0 1 8 0 0 - ++/dev/urandom c 640 0 0 1 9 0 0 - ++/dev/tty c 666 0 0 5 0 0 0 - ++/dev/tty c 666 0 0 4 0 0 1 6 ++/dev/console c 640 0 0 5 1 0 0 - ++/dev/ram b 640 0 0 1 1 0 0 - ++/dev/ram b 640 0 0 1 0 0 1 4 ++/dev/loop b 640 0 0 7 0 0 1 2 ++/dev/ptmx c 666 0 0 5 2 0 0 - ++#/dev/ttyS c 640 0 0 4 64 0 1 4 ++#/dev/psaux c 640 0 0 10 1 0 0 - ++#/dev/rtc c 640 0 0 10 135 0 0 - ++ ++# Adjust permissions on some normal files ++#/etc/shadow f 600 0 0 - - - - - ++#/bin/tinylogin f 4755 0 0 - - - - - ++ ++# User-mode Linux stuff ++/dev/ubda b 640 0 0 98 0 0 0 - ++/dev/ubda b 640 0 0 98 1 1 1 15 ++ ++# IDE Devices ++/dev/hda b 640 0 0 3 0 0 0 - ++/dev/hda b 640 0 0 3 1 1 1 15 ++/dev/hdb b 640 0 0 3 64 0 0 - ++/dev/hdb b 640 0 0 3 65 1 1 15 ++#/dev/hdc b 640 0 0 22 0 0 0 - ++#/dev/hdc b 640 0 0 22 1 1 1 15 ++#/dev/hdd b 640 0 0 22 64 0 0 - ++#/dev/hdd b 640 0 0 22 65 1 1 15 ++#/dev/hde b 640 0 0 33 0 0 0 - ++#/dev/hde b 640 0 0 33 1 1 1 15 ++#/dev/hdf b 640 0 0 33 64 0 0 - ++#/dev/hdf b 640 0 0 33 65 1 1 15 ++#/dev/hdg b 640 0 0 34 0 0 0 - ++#/dev/hdg b 640 0 0 34 1 1 1 15 ++#/dev/hdh b 640 0 0 34 64 0 0 - ++#/dev/hdh b 640 0 0 34 65 1 1 15 ++ ++# SCSI Devices ++#/dev/sda b 640 0 0 8 0 0 0 - ++#/dev/sda b 640 0 0 8 1 1 1 15 ++#/dev/sdb b 640 0 0 8 16 0 0 - ++#/dev/sdb b 640 0 0 8 17 1 1 15 ++#/dev/sdc b 640 0 0 8 32 0 0 - ++#/dev/sdc b 640 0 0 8 33 1 1 15 ++#/dev/sdd b 640 0 0 8 48 0 0 - ++#/dev/sdd b 640 0 0 8 49 1 1 15 ++#/dev/sde b 640 0 0 8 64 0 0 - ++#/dev/sde b 640 0 0 8 65 1 1 15 ++#/dev/sdf b 640 0 0 8 80 0 0 - ++#/dev/sdf b 640 0 0 8 81 1 1 15 ++#/dev/sdg b 640 0 0 8 96 0 0 - ++#/dev/sdg b 640 0 0 8 97 1 1 15 ++#/dev/sdh b 640 0 0 8 112 0 0 - ++#/dev/sdh b 640 0 0 8 113 1 1 15 ++#/dev/sg c 640 0 0 21 0 0 1 15 ++#/dev/scd b 640 0 0 11 0 0 1 15 ++#/dev/st c 640 0 0 9 0 0 1 8 ++#/dev/nst c 640 0 0 9 128 0 1 8 ++#/dev/st c 640 0 0 9 32 1 1 4 ++#/dev/st c 640 0 0 9 64 1 1 4 ++#/dev/st c 640 0 0 9 96 1 1 4 ++ ++# Floppy disk devices ++#/dev/fd b 640 0 0 2 0 0 1 2 ++#/dev/fd0d360 b 640 0 0 2 4 0 0 - ++#/dev/fd1d360 b 640 0 0 2 5 0 0 - ++#/dev/fd0h1200 b 640 0 0 2 8 0 0 - ++#/dev/fd1h1200 b 640 0 0 2 9 0 0 - ++#/dev/fd0u1440 b 640 0 0 2 28 0 0 - ++#/dev/fd1u1440 b 640 0 0 2 29 0 0 - ++#/dev/fd0u2880 b 640 0 0 2 32 0 0 - ++#/dev/fd1u2880 b 640 0 0 2 33 0 0 - ++ ++# All the proprietary cdrom devices in the world ++#/dev/aztcd b 640 0 0 29 0 0 0 - ++#/dev/bpcd b 640 0 0 41 0 0 0 - ++#/dev/capi20 c 640 0 0 68 0 0 1 2 ++#/dev/cdu31a b 640 0 0 15 0 0 0 - ++#/dev/cdu535 b 640 0 0 24 0 0 0 - ++#/dev/cm206cd b 640 0 0 32 0 0 0 - ++#/dev/sjcd b 640 0 0 18 0 0 0 - ++#/dev/sonycd b 640 0 0 15 0 0 0 - ++#/dev/gscd b 640 0 0 16 0 0 0 - ++#/dev/sbpcd b 640 0 0 25 0 0 0 - ++#/dev/sbpcd b 640 0 0 25 0 0 1 4 ++#/dev/mcd b 640 0 0 23 0 0 0 - ++#/dev/optcd b 640 0 0 17 0 0 0 - ++ +diff -urN genext2fs-1.3.orig/genext2fs.8 genext2fs-1.3/genext2fs.8 +--- genext2fs-1.3.orig/genext2fs.8 1969-12-31 17:00:00.000000000 -0700 ++++ genext2fs-1.3/genext2fs.8 2003-04-21 01:41:42.000000000 -0600 +@@ -0,0 +1,125 @@ ++.\" Hey, EMACS: -*- nroff -*- ++.\" First parameter, NAME, should be all caps ++.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection ++.\" other parameters are allowed: see man(7), man(1) ++.TH GENEXT2FS 8 "July 14, 2001" ++.\" Please adjust this date whenever revising the manpage. ++.\" ++.\" Some roff macros, for reference: ++.\" .nh disable hyphenation ++.\" .hy enable hyphenation ++.\" .ad l left justify ++.\" .ad b justify to both left and right margins ++.\" .nf disable filling ++.\" .fi enable filling ++.\" .br insert line break ++.\" .sp insert n+1 empty lines ++.\" for manpage-specific macros, see man(7) ++.SH NAME ++genext2fs \- ext2 filesystem generator for embedded systems ++.SH SYNOPSIS ++.B genext2fs ++.RI [ options ] " image" ++.SH DESCRIPTION ++\fBgenext2fs\fP generates an ext2 filesystem ++as a normal (non-root) user. It doesn't require you to mount ++the image file to copy files on it. It doesn't even require ++you to be the superuser to make device nodes. ++.SH OPTIONS ++.TP ++.BI -x \ image ++Use this image as a starting point ++.TP ++.BI -d \ directory ++Add this directory as source ++.TP ++.BI -f \ FILE ++.TP ++.BI -D \ FILE ++Uses the named FILE as a device table file, to create device ++nodes and directories "on the fly". ++.TP ++.BI -b \ blocks ++Size in blocks ++.TP ++.BI -i \ inodes ++Number of inodes ++.TP ++.BI -r \ reserved ++Number of reserved blocks ++.TP ++.BI -g \ path ++Generate a block map file for this path ++.TP ++.BI -e \ value ++Fill unallocated blocks with value ++.TP ++.BI -z ++Make files with holes ++.TP ++.BI -U ++Squash owners making all files be owned by root ++.TP ++.BI -P ++Squash permissions on all files ++.TP ++.BI -q ++Squash permissions and owners (same as -P -U) ++.TP ++.BI -v ++Print resulting filesystem structure ++.TP ++.BI -h ++Display help ++.TP ++.SH EXAMPLES ++ ++.EX ++.B ++ genext2fs -b 1440 -d src /dev/fd0 ++.EE ++ ++All files in the ++.I src ++directory will be written to ++.B /dev/fd0 ++as a new ext2 filesystem image. You can then mount the floppy as ++usual. ++ ++.EX ++.B ++ genext2fs -b 1024 -d src -D device_table.txt flashdisk.img ++.EE ++ ++This example builds a filesystem from all the files in ++.I src ++, then device nodes are created based on the content the device_table file ++.I dev.txt. ++An example device file follows: ++ ++.EX ++ # ++ /dev d 755 0 0 - - - - - ++ /dev/mem c 640 0 0 1 1 0 0 - ++ /dev/tty c 666 0 0 5 0 0 0 - ++ /dev/tty c 666 0 0 4 0 0 1 6 ++ /dev/loop b 640 0 0 7 0 0 1 2 ++ /dev/hda b 640 0 0 3 0 0 0 - ++ /dev/hda b 640 0 0 3 1 1 1 16 ++.EE ++ ++This device table creates the /dev directory, a character device ++node /dev/mem (major 1, minor 1), it also creates /dev/tty, ++/dev/tty[0-5], /dev/loop[0-1], /dev/hda, and /dev/hda0 to /dev/hda15 ++.SH BUGS ++\fBgenext2fs\fP does not support hard links. Hard links present in the input ++tree will be represented as separate files in the ext2 image. ++ ++.SH SEE ALSO ++.BR mkfs (8), ++.BR genromfs (8), ++.BR mkisofs (8). ++.br ++.SH AUTHOR ++This manual page was written by David Kimdon , ++for the Debian GNU/Linux system (but may be used by others). +diff -urN genext2fs-1.3.orig/genext2fs.c genext2fs-1.3/genext2fs.c +--- genext2fs-1.3.orig/genext2fs.c 2001-06-18 02:11:32.000000000 -0600 ++++ genext2fs-1.3/genext2fs.c 2003-04-21 01:48:35.000000000 -0600 +@@ -1,3 +1,4 @@ ++/* vi: set sw=8 ts=8: */ + // genext2fs.c + // + // ext2 filesystem generator for embedded systems +@@ -26,6 +27,22 @@ + // Bugfix: getcwd values for Solaris xavier.gueguen@col.bsf.alcatel.fr + // Bugfix: ANSI scanf for non-GNU C xavier.gueguen@col.bsf.alcatel.fr + // 28 Jun 2001 Bugfix: getcwd differs for Solaris/GNU mike@sowbug.com ++// 23 Mar 2002 Bugfix: test for IFCHR or IFBLK was flawed ++// 10 Oct 2002 Added comments,makefile targets, vsundar@ixiacom.com ++// endianess swap assert check. ++// Copyright (C) 2002 Ixia communications ++// 12 Oct 2002 Added support for triple indirection vsundar@ixiacom.com ++// Copyright (C) 2002 Ixia communications ++// 14 Oct 2002 Added support for groups vsundar@ixiacom.com ++// Copyright (C) 2002 Ixia communications ++// 5 Jan 2003 Bugfixes: reserved inodes should be set vsundar@usc.edu ++// only in the first group; directory names ++// need to be null padded at the end; and ++// number of blocks per group should be a ++// multiple of 8. Updated md5 values. ++// 6 Jan 2003 Erik Andersen added ++// mkfs.jffs2 compatible device table support, ++// along with -q, -P, -U + + + // `genext2fs' is a mean to generate an ext2 filesystem +@@ -33,10 +50,6 @@ + // the image file to copy files on it. It doesn't even require + // you to be the superuser to make device nodes. + // +-// Warning ! `genext2fs' has been designed for embedded +-// systems. As such, it will generate a filesystem for single-user +-// usage: all files/directories/etc... will belong to UID/GID 0 +-// + // Example usage: + // + // # genext2fs -b 1440 -d srcdir /dev/fd0 +@@ -45,21 +58,15 @@ + // a new ext2 filesystem image. You can then mount the floppy as + // usual. + // +-// # genext2fs -b 1024 -d builddir -f devices.txt flashdisk.img ++// # genext2fs -b 1024 -d builddir -D device_table.txt flashdisk.img + // + // This one would build a filesystem from all the files in builddir, +-// then would read a devices list and make apropriate nodes. The +-// format for the device list is: +-// +-// drwx /dev +-// crw- 10,190 /dev/lcd +-// brw- 1,0 /dev/ram0 +-// +-// This device list builds the /dev directory, a character device +-// node /dev/lcd (major 10, minor 190) and a block device node +-// /dev/ram0 (major 1, minor 0) ++// then would read the device_table.txt file and make apropriate nodes. ++// The format for the device table file is covered in detail in the sample ++// device_table.txt file provided with the genext2fs source. + + ++#define _GNU_SOURCE + #include + #include + #include +@@ -67,6 +74,11 @@ + #include + #include + #include ++#include ++#include ++#include ++#include ++#include + + + +@@ -76,10 +88,14 @@ + #define BLOCKSIZE 1024 + #define BLOCKS_PER_GROUP 8192 + #define BYTES_PER_INODE (8*BLOCKSIZE) ++/* Percentage of blocks that are reserved.*/ + #define RESERVED_INODES 5/100 + + + // inode block size (why is it != BLOCKSIZE ?!?) ++/* The field i_blocks in the ext2 inode stores the number of data blocks ++ but in terms of 512 bytes. That is what INODE_BLOCKSIZE represents. ++ INOBLK is the number of such blocks in an actual disk block */ + + #define INODE_BLOCKSIZE 512 + #define INOBLK (BLOCKSIZE / INODE_BLOCKSIZE) +@@ -147,6 +163,39 @@ + + #define OP_HOLES 0x01 // make files with holes + ++/* Defines for accessing group details */ ++ ++// Number of groups in the filesystem ++#define GRP_NBGROUPS(fs) ( ((fs)->sb.s_blocks_count-1)/(fs)->sb.s_blocks_per_group ) ++ ++// Get group block bitmap (bbm) given the group number ++#define GRP_GET_GROUP_BBM(fs,grp) ( get_blk((fs),(fs)->gd[(grp)].bg_block_bitmap) ) ++ ++// Get group inode bitmap (ibm) given the group number ++#define GRP_GET_GROUP_IBM(fs,grp) ( get_blk((fs),(fs)->gd[(grp)].bg_inode_bitmap) ) ++ ++// Given an inode number find the group it belongs to ++#define GRP_GROUP_OF_INODE(fs,nod) ( ((nod)-1) / (fs)->sb.s_inodes_per_group) ++ ++//Given an inode number get the inode bitmap that covers it ++#define GRP_GET_INODE_BITMAP(fs,nod) \ ++ ( GRP_GET_GROUP_IBM((fs),GRP_GROUP_OF_INODE((fs),(nod))) ) ++ ++//Given an inode number find its offset within the inode bitmap that covers it ++#define GRP_IBM_OFFSET(fs,nod) \ ++ ( (nod) - GRP_GROUP_OF_INODE((fs),(nod))*(fs)->sb.s_inodes_per_group ) ++ ++// Given a block number find the group it belongs to ++#define GRP_GROUP_OF_BLOCK(fs,blk) ( ((blk)-1) / (fs)->sb.s_blocks_per_group) ++ ++//Given a block number get the block bitmap that covers it ++#define GRP_GET_BLOCK_BITMAP(fs,blk) \ ++ ( GRP_GET_GROUP_BBM((fs),GRP_GROUP_OF_BLOCK((fs),(blk))) ) ++ ++//Given a block number find its offset within the block bitmap that covers it ++#define GRP_BBM_OFFSET(fs,blk) \ ++ ( (blk) - GRP_GROUP_OF_BLOCK((fs),(blk))*(fs)->sb.s_blocks_per_group ) ++ + + // used types + +@@ -287,7 +336,6 @@ + { + groupdescriptor_decl + uint32 bg_reserved[3]; +- uint32 bg_pad_to_bk[(BLOCKSIZE-32)/sizeof(uint32)]; + } groupdescriptor; + + typedef struct +@@ -304,6 +352,32 @@ + + typedef uint8 block[BLOCKSIZE]; + ++/* blockwalker fields: ++ The blockwalker is used to access all the blocks of a file (including ++ the indirection blocks) through repeated calls to walk_bw. ++ ++ bpdir -> index into the inode->i_block[]. Indicates level of indirection. ++ bnum -> total number of blocks so far accessed. including indirection ++ blocks. ++ bpind,bpdind,bptind -> index into indirection blocks. ++ ++ bpind, bpdind, bptind do *NOT* index into single, double and triple ++ indirect blocks resp. as you might expect from their names. Instead ++ they are in order the 1st, 2nd & 3rd index to be used ++ ++ As an example.. ++ To access data block number 70000: ++ bpdir: 15 (we are doing triple indirection) ++ bpind: 0 ( index into the triple indirection block) ++ bpdind: 16 ( index into the double indirection block) ++ bptind: 99 ( index into the single indirection block) ++ 70000 = 12 + 256 + 256*256 + 16*256 + 100 (indexing starts from zero) ++ ++ So,for double indirection bpind will index into the double indirection ++ block and bpdind into the single indirection block. For single indirection ++ only bpind will be used. ++*/ ++ + typedef struct + { + uint32 bnum; +@@ -313,15 +387,14 @@ + uint32 bptind; + } blockwalker; + ++ ++/* Filesystem structure that support groups */ + #if BLOCKSIZE == 1024 + typedef struct + { + block zero; // The famous block 0 + superblock sb; // The superblock +- groupdescriptor gd; // The group desciptor +- block bbm; // The block bitmap +- block ibm; // The inode bitmap +- inode itab[0]; // The inode table ++ groupdescriptor gd[0]; // The group descriptors + } filesystem; + #else + #error UNHANDLED BLOCKSIZE +@@ -389,25 +462,113 @@ + #undef udecl32 + #undef utdecl32 + +-char * argv0; ++static char * app_name; ++static int squash_uids = 0; ++static int squash_perms = 0; ++static const char *const memory_exhausted = "memory exhausted"; + + // error (un)handling +-inline void errexit(const char *fmt, ...) ++static void verror_msg(const char *s, va_list p) + { +- va_list ap; +- fprintf(stderr, "%s: ", argv0); +- va_start(ap, fmt); +- vfprintf(stderr, fmt, ap); +- va_end(ap); +- fprintf(stderr, "\n"); +- exit(1); ++ fflush(stdout); ++ fprintf(stderr, "%s: ", app_name); ++ vfprintf(stderr, s, p); ++} ++static void error_msg(const char *s, ...) ++{ ++ va_list p; ++ va_start(p, s); ++ verror_msg(s, p); ++ va_end(p); ++ putc('\n', stderr); ++} ++ ++static void error_msg_and_die(const char *s, ...) ++{ ++ va_list p; ++ va_start(p, s); ++ verror_msg(s, p); ++ va_end(p); ++ putc('\n', stderr); ++ exit(EXIT_FAILURE); ++} ++ ++static void vperror_msg(const char *s, va_list p) ++{ ++ int err = errno; ++ if (s == 0) ++ s = ""; ++ verror_msg(s, p); ++ if (*s) ++ s = ": "; ++ fprintf(stderr, "%s%s\n", s, strerror(err)); ++} ++ ++#if 0 ++static void perror_msg(const char *s, ...) ++{ ++ va_list p; ++ va_start(p, s); ++ vperror_msg(s, p); ++ va_end(p); ++} ++#endif ++static void perror_msg_and_die(const char *s, ...) ++{ ++ va_list p; ++ va_start(p, s); ++ vperror_msg(s, p); ++ va_end(p); ++ exit(EXIT_FAILURE); + } + +-inline void pexit(const char * fname) ++static FILE *xfopen(const char *path, const char *mode) + { +- fprintf(stderr, "%s: ", argv0); +- perror(fname); +- exit(1); ++ FILE *fp; ++ if ((fp = fopen(path, mode)) == NULL) ++ perror_msg_and_die("%s", path); ++ return fp; ++} ++ ++static char *xstrdup(const char *s) ++{ ++ char *t; ++ ++ if (s == NULL) ++ return NULL; ++ t = strdup(s); ++ if (t == NULL) ++ error_msg_and_die(memory_exhausted); ++ return t; ++} ++ ++extern void *xrealloc(void *ptr, size_t size) ++{ ++ ptr = realloc(ptr, size); ++ if (ptr == NULL && size != 0) ++ error_msg_and_die(memory_exhausted); ++ return ptr; ++} ++ ++static char *xreadlink(const char *path) ++{ ++ static const int GROWBY = 80; /* how large we will grow strings by */ ++ ++ char *buf = NULL; ++ int bufsize = 0, readsize = 0; ++ ++ do { ++ buf = xrealloc(buf, bufsize += GROWBY); ++ readsize = readlink(path, buf, bufsize); /* 1st try */ ++ if (readsize == -1) { ++ perror_msg_and_die("%s:%s", app_name, path); ++ } ++ } ++ while (bufsize < readsize + 1); ++ ++ buf[readsize] = '\0'; ++ ++ return buf; + } + + // printf helper macro +@@ -423,7 +584,7 @@ + { + } + +-// rounds a quantity up to a blocksize ++/* Rounds qty upto a multiple of siz. siz should be a power of 2 */ + uint32 rndup(uint32 qty, uint32 siz) + { + return (qty + (siz - 1)) & ~(siz - 1); +@@ -444,7 +605,13 @@ + // return a given inode from a filesystem + inline inode * get_nod(filesystem *fs, uint32 nod) + { +- return &fs->itab[nod-1]; ++ int grp,offset; ++ inode *itab; ++ ++ offset = GRP_IBM_OFFSET(fs,nod); ++ grp = GRP_GROUP_OF_INODE(fs,nod); ++ itab = (inode *)get_blk(fs, fs->gd[grp].bg_inode_table); ++ return itab+offset-1; + } + + // allocate a given block/inode in the bitmap +@@ -479,29 +646,57 @@ + } + + // allocate a block +-uint32 alloc_blk(filesystem *fs) ++uint32 alloc_blk(filesystem *fs, uint32 nod) + { +- uint32 bk; +- if(!(bk = allocate(fs->bbm, 0))) +- errexit("couldn't allocate a block (no free space)"); +- if(!(fs->gd.bg_free_blocks_count--)) +- errexit("group descr. free blocks count == 0 (corrupted fs?)"); ++ uint32 bk=0; ++ uint32 grp,nbgroups; ++ ++ grp = nod/fs->sb.s_inodes_per_group; ++ nbgroups = ( fs->sb.s_blocks_count - fs->sb.s_first_data_block + fs->sb.s_blocks_per_group -1 ) / ++ fs->sb.s_blocks_per_group; ++ if(!(bk = allocate(get_blk(fs,fs->gd[grp].bg_block_bitmap), 0))) { ++ for(grp=0;grpgd[grp].bg_block_bitmap),0); ++ grp--; ++ } ++ if (!bk) ++ error_msg_and_die("couldn't allocate a block (no free space)"); ++ if(!(fs->gd[grp].bg_free_blocks_count--)) ++ error_msg_and_die("group descr %d. free blocks count == 0 (corrupted fs?)",grp); + if(!(fs->sb.s_free_blocks_count--)) +- errexit("superblock free blocks count == 0 (corrupted fs?)"); +- return bk; ++ error_msg_and_die("superblock free blocks count == 0 (corrupted fs?)"); ++ return fs->sb.s_blocks_per_group*grp + bk; + } + + // allocate an inode + uint32 alloc_nod(filesystem *fs) + { +- uint32 nod; +- if(!(nod = allocate(fs->ibm, 0))) +- errexit("couldn't allocate an inode (no free inode)"); +- if(!(fs->gd.bg_free_inodes_count--)) +- errexit("group descr. free blocks count == 0 (corrupted fs?)"); ++ uint32 nod=0,best_group=0; ++ uint32 grp,nbgroups,avefreei; ++ ++ nbgroups = ( fs->sb.s_blocks_count - fs->sb.s_first_data_block + fs->sb.s_blocks_per_group -1 ) / ++ fs->sb.s_blocks_per_group; ++ ++ /* Distribute inodes amongst all the blocks */ ++ /* For every block group with more than average number of free inodes */ ++ /* find the one with the most free blocks and allocate node there */ ++ /* Idea from find_group_dir in fs/ext2/ialloc.c in 2.4.19 kernel */ ++ /* We do it for all inodes. */ ++ avefreei = fs->sb.s_free_inodes_count / nbgroups; ++ for(grp=0;grpgd[grp].bg_free_inodes_count < avefreei) ++ continue; ++ if (!best_group || ++ fs->gd[grp].bg_free_blocks_count > fs->gd[best_group].bg_free_blocks_count) ++ best_group = grp; ++ } ++ if (!(nod = allocate(get_blk(fs,fs->gd[best_group].bg_inode_bitmap),0))) ++ error_msg_and_die("couldn't allocate an inode (no free inode)"); ++ if(!(fs->gd[best_group].bg_free_inodes_count--)) ++ error_msg_and_die("group descr. free blocks count == 0 (corrupted fs?)"); + if(!(fs->sb.s_free_inodes_count--)) +- errexit("superblock free blocks count == 0 (corrupted fs?)"); +- return nod; ++ error_msg_and_die("superblock free blocks count == 0 (corrupted fs?)"); ++ return fs->sb.s_inodes_per_group*best_group+nod; + } + + // print a bitmap allocation +@@ -546,14 +741,14 @@ + { + bkref = &get_nod(fs, nod)->i_block[bw->bpdir = 0]; + if(extend) // allocate first block +- *bkref = hole ? 0 : alloc_blk(fs); ++ *bkref = hole ? 0 : alloc_blk(fs,nod); + } + // direct block + else if(bw->bpdir < EXT2_NDIR_BLOCKS) + { + bkref = &get_nod(fs, nod)->i_block[++bw->bpdir]; + if(extend) // allocate block +- *bkref = hole ? 0 : alloc_blk(fs); ++ *bkref = hole ? 0 : alloc_blk(fs,nod); + } + // first block in indirect block + else if(bw->bpdir == EXT2_NDIR_BLOCKS) +@@ -562,11 +757,11 @@ + bw->bpdir = EXT2_IND_BLOCK; + bw->bpind = 0; + if(extend) // allocate indirect block +- get_nod(fs, nod)->i_block[bw->bpdir] = alloc_blk(fs); ++ get_nod(fs, nod)->i_block[bw->bpdir] = alloc_blk(fs,nod); + b = (uint32*)get_blk(fs, get_nod(fs, nod)->i_block[bw->bpdir]); + bkref = &b[bw->bpind]; + if(extend) // allocate first block +- *bkref = hole ? 0 : alloc_blk(fs); ++ *bkref = hole ? 0 : alloc_blk(fs,nod); + } + // block in indirect block + else if((bw->bpdir == EXT2_IND_BLOCK) && (bw->bpind < BLOCKSIZE/4 - 1)) +@@ -575,7 +770,7 @@ + b = (uint32*)get_blk(fs, get_nod(fs, nod)->i_block[bw->bpdir]); + bkref = &b[bw->bpind]; + if(extend) // allocate block +- *bkref = hole ? 0 : alloc_blk(fs); ++ *bkref = hole ? 0 : alloc_blk(fs,nod); + } + // first block in first indirect block in first double indirect block + else if(bw->bpdir == EXT2_IND_BLOCK) +@@ -585,14 +780,14 @@ + bw->bpind = 0; + bw->bpdind = 0; + if(extend) // allocate double indirect block +- get_nod(fs, nod)->i_block[bw->bpdir] = alloc_blk(fs); ++ get_nod(fs, nod)->i_block[bw->bpdir] = alloc_blk(fs,nod); + b = (uint32*)get_blk(fs, get_nod(fs, nod)->i_block[bw->bpdir]); + if(extend) // allocate first indirect block +- b[bw->bpind] = alloc_blk(fs); ++ b[bw->bpind] = alloc_blk(fs,nod); + b = (uint32*)get_blk(fs, b[bw->bpind]); + bkref = &b[bw->bpdind]; + if(extend) // allocate first block +- *bkref = hole ? 0 : alloc_blk(fs); ++ *bkref = hole ? 0 : alloc_blk(fs,nod); + } + // block in indirect block in double indirect block + else if((bw->bpdir == EXT2_DIND_BLOCK) && (bw->bpdind < BLOCKSIZE/4 - 1)) +@@ -602,7 +797,7 @@ + b = (uint32*)get_blk(fs, b[bw->bpind]); + bkref = &b[bw->bpdind]; + if(extend) // allocate block +- *bkref = hole ? 0 : alloc_blk(fs); ++ *bkref = hole ? 0 : alloc_blk(fs,nod); + } + // first block in indirect block in double indirect block + else if((bw->bpdir == EXT2_DIND_BLOCK) && (bw->bpind < BLOCKSIZE/4 - 1)) +@@ -612,20 +807,100 @@ + bw->bpind++; + b = (uint32*)get_blk(fs, get_nod(fs, nod)->i_block[bw->bpdir]); + if(extend) // allocate indirect block +- b[bw->bpind] = alloc_blk(fs); ++ b[bw->bpind] = alloc_blk(fs,nod); + b = (uint32*)get_blk(fs, b[bw->bpind]); + bkref = &b[bw->bpdind]; + if(extend) // allocate first block +- *bkref = hole ? 0 : alloc_blk(fs); ++ *bkref = hole ? 0 : alloc_blk(fs,nod); ++ } ++ ++ /* Adding support for triple indirection */ ++ /* Just starting triple indirection. Allocate the indirection ++ blocks and the first data block ++ */ ++ else if (bw->bpdir == EXT2_DIND_BLOCK) ++ { ++ bw->bnum += 3; ++ bw->bpdir = EXT2_TIND_BLOCK; ++ bw->bpind = 0; ++ bw->bpdind = 0; ++ bw->bptind = 0; ++ if(extend) // allocate triple indirect block ++ get_nod(fs, nod)->i_block[bw->bpdir] = alloc_blk(fs,nod); ++ b = (uint32*)get_blk(fs, get_nod(fs, nod)->i_block[bw->bpdir]); ++ if(extend) // allocate first double indirect block ++ b[bw->bpind] = alloc_blk(fs,nod); ++ b = (uint32*)get_blk(fs, b[bw->bpind]); ++ if(extend) // allocate first indirect block ++ b[bw->bpdind] = alloc_blk(fs,nod); ++ b = (uint32*)get_blk(fs, b[bw->bpdind]); ++ bkref = &b[bw->bptind]; ++ if(extend) // allocate first data block ++ *bkref = hole ? 0 : alloc_blk(fs,nod); ++ } ++ /* Still processing a single indirect block down the indirection ++ chain.Allocate a data block for it ++ */ ++ else if ( (bw->bpdir == EXT2_TIND_BLOCK) && ++ (bw->bptind < BLOCKSIZE/4 -1) ) ++ { ++ bw->bptind++; ++ b = (uint32*)get_blk(fs, get_nod(fs, nod)->i_block[bw->bpdir]); ++ b = (uint32*)get_blk(fs, b[bw->bpind]); ++ b = (uint32*)get_blk(fs, b[bw->bpdind]); ++ bkref = &b[bw->bptind]; ++ if(extend) // allocate data block ++ *bkref = hole ? 0 : alloc_blk(fs,nod); ++ } ++ /* Finished processing a single indirect block. But still in the ++ same double indirect block. Allocate new single indirect block ++ for it and a data block ++ */ ++ else if ( (bw->bpdir == EXT2_TIND_BLOCK) && ++ (bw->bpdind < BLOCKSIZE/4 -1) ) ++ { ++ bw->bnum++; ++ bw->bptind = 0; ++ bw->bpdind++; ++ b = (uint32*)get_blk(fs, get_nod(fs, nod)->i_block[bw->bpdir]); ++ b = (uint32*)get_blk(fs, b[bw->bpind]); ++ if (extend) // allocate single indirect block ++ b[bw->bpdind] = alloc_blk(fs,nod); ++ b = (uint32*)get_blk(fs, b[bw->bpdind]); ++ bkref = &b[bw->bptind]; ++ if(extend) // allocate first data block ++ *bkref = hole ? 0 : alloc_blk(fs,nod); ++ } ++ /* Finished processing a double indirect block. Allocate the next ++ double indirect block and the single,data blocks for it ++ */ ++ else if ( (bw->bpdir == EXT2_TIND_BLOCK) && ++ (bw->bpind < BLOCKSIZE/4 - 1) ) ++ { ++ bw->bnum += 2; ++ bw->bpdind = 0; ++ bw->bptind = 0; ++ bw->bpind++; ++ b = (uint32*)get_blk(fs, get_nod(fs, nod)->i_block[bw->bpdir]); ++ if(extend) // allocate double indirect block ++ b[bw->bpind] = alloc_blk(fs,nod); ++ b = (uint32*)get_blk(fs, b[bw->bpind]); ++ if(extend) // allocate single indirect block ++ b[bw->bpdind] = alloc_blk(fs,nod); ++ b = (uint32*)get_blk(fs, b[bw->bpdind]); ++ bkref = &b[bw->bptind]; ++ if(extend) // allocate first block ++ *bkref = hole ? 0 : alloc_blk(fs,nod); + } +- // I don't do triple indirect - it's such a small filesystem ... + else +- errexit("file too big ! blocks list for inode %d extends past double indirect blocks!", nod); ++ error_msg_and_die("file too big !"); ++ /* End change for walking triple indirection */ ++ + if(*bkref) + { + bw->bnum++; +- if(!allocated(fs->bbm, *bkref)) +- errexit("[block %d of inode %d is unallocated !]", *bkref, nod); ++ if(!allocated(GRP_GET_BLOCK_BITMAP(fs,*bkref), GRP_BBM_OFFSET(fs,*bkref))) ++ error_msg_and_die("[block %d of inode %d is unallocated !]", *bkref, nod); + } + if(extend) + get_nod(fs, nod)->i_blocks = bw->bnum * INOBLK; +@@ -663,23 +938,40 @@ + } + + // link an entry (inode #) to a directory +-void add2dir(filesystem *fs, uint32 dnod, uint32 nod, const char* name) ++void add2dir(filesystem *fs, uint32 dnod, uint32 nod, const char* name, uint32 mode, uid_t uid, gid_t gid, time_t ctime) + { + blockwalker bw; + uint32 bk; + uint8 *b; + directory *d; + int reclen, nlen; +- if((get_nod(fs, dnod)->i_mode & FM_IFMT) != FM_IFDIR) +- errexit("can't add '%s' to a non-directory", name); ++ inode *node; ++ inode *pnode; ++ ++ /* Squash all permissions so files are owned by root ++ * and file permissions have group/other perms removed */ ++ if (squash_uids) { ++ uid = gid = 0; ++ } ++ if (squash_perms) { ++ if (!S_ISLNK(mode)) { ++ mode &= ~(S_IWGRP | S_IWOTH); ++ mode &= ~(S_ISUID | S_ISGID); ++ } ++ } ++ ++ pnode = get_nod(fs, dnod); ++ ++ if(!S_ISDIR(pnode->i_mode)) ++ error_msg_and_die("can't add '%s' to a non-directory", name); + if(!*name) +- errexit("bad name '%s' (not meaningful)", name); ++ error_msg_and_die("bad name '%s' (not meaningful)", name); + if(strchr(name, '/')) +- errexit("bad name '%s' (contains a slash)", name); ++ error_msg_and_die("bad name '%s' (contains a slash)", name); + nlen = strlen(name); + reclen = sizeof(directory) + rndup(nlen, 4); + if(reclen > BLOCKSIZE) +- errexit("bad name '%s' (too long)", name); ++ error_msg_and_die("bad name '%s' (too long)", name); + init_bw(fs, dnod, &bw); + while((bk = walk_bw(fs, dnod, &bw, 0, 0)) != WALK_END) // for all blocks in dir + { +@@ -691,9 +983,16 @@ + if((!d->d_inode) && (d->d_rec_len >= reclen)) + { + d->d_inode = nod; +- get_nod(fs, nod)->i_links_count++; ++ node = get_nod(fs, nod); ++ node->i_links_count++; + d->d_name_len = nlen; +- strncpy(d->d_name, name, nlen); ++ strncpy(d->d_name, name, rndup(nlen,4)); ++ node->i_mode = mode; ++ node->i_uid = uid; ++ node->i_gid = gid; ++ node->i_atime = ctime; ++ node->i_ctime = ctime; ++ node->i_mtime = ctime; + return; + } + // if entry with enough room (last one?), shrink it & use it +@@ -705,9 +1004,16 @@ + d = (directory*) (((int8*)d) + d->d_rec_len); + d->d_rec_len = reclen; + d->d_inode = nod; +- get_nod(fs, nod)->i_links_count++; ++ node = get_nod(fs, nod); ++ node->i_links_count++; + d->d_name_len = nlen; +- strncpy(d->d_name, name, nlen); ++ strncpy(d->d_name, name, rndup(nlen,4)); ++ node->i_mode = mode; ++ node->i_uid = uid; ++ node->i_gid = gid; ++ node->i_atime = ctime; ++ node->i_ctime = ctime; ++ node->i_mtime = ctime; + return; + } + } +@@ -716,10 +1022,17 @@ + b = get_workblk(); + d = (directory*)b; + d->d_inode = nod; +- get_nod(fs, nod)->i_links_count++; ++ node = get_nod(fs, nod); ++ node->i_links_count++; + d->d_rec_len = BLOCKSIZE; + d->d_name_len = nlen; +- strncpy(d->d_name, name, nlen); ++ strncpy(d->d_name, name, rndup(nlen,4)); ++ node->i_mode = mode; ++ node->i_uid = uid; ++ node->i_gid = gid; ++ node->i_atime = ctime; ++ node->i_ctime = ctime; ++ node->i_mtime = ctime; + extend_blk(fs, dnod, b, 1); + get_nod(fs, dnod)->i_size += BLOCKSIZE; + free_workblk(b); +@@ -747,7 +1060,7 @@ + // find the inode of a full path + uint32 find_path(filesystem *fs, uint32 nod, const char * name) + { +- char *p, *n, *n2 = strdup(name); ++ char *p, *n, *n2 = xstrdup(name); + n = n2; + while(*n == '/') + { +@@ -770,27 +1083,32 @@ + } + + // make a full-fledged directory (i.e. with "." & "..") +-uint32 mkdir_fs(filesystem *fs, uint32 parent_nod, const char *name, uint32 mode) ++uint32 mkdir_fs(filesystem *fs, uint32 parent_nod, const char *name, uint32 mode, ++ uid_t uid, gid_t gid, time_t ctime) + { + uint32 nod; + if((nod = find_dir(fs, parent_nod, name))) + return nod; + nod = alloc_nod(fs); +- get_nod(fs, nod)->i_mode = FM_IFDIR | mode; +- add2dir(fs, parent_nod, nod, name); +- add2dir(fs, nod, nod, "."); +- add2dir(fs, nod, parent_nod, ".."); +- fs->gd.bg_used_dirs_count++; ++ if (!(mode & FM_IFDIR)) ++ mode |= FM_IFDIR; ++ add2dir(fs, parent_nod, nod, name, mode, uid, gid, ctime); ++ add2dir(fs, nod, nod, ".", mode, uid, gid, ctime); ++ add2dir(fs, nod, parent_nod, "..", mode, uid, gid, ctime); ++ fs->gd[GRP_GROUP_OF_INODE(fs,nod)].bg_used_dirs_count++; + return nod; + } + + // make a symlink +-uint32 mklink_fs(filesystem *fs, uint32 parent_nod, const char *name, size_t size, uint8 * b) ++uint32 mklink_fs(filesystem *fs, uint32 parent_nod, const char *name, size_t size, ++ uint8 * b, uid_t uid, gid_t gid, time_t ctime) + { ++ uint32 mode; + uint32 nod = alloc_nod(fs); ++ mode = FM_IFLNK | FM_IRWXU | FM_IRWXG | FM_IRWXO; + get_nod(fs, nod)->i_mode = FM_IFLNK | FM_IRWXU | FM_IRWXG | FM_IRWXO; + get_nod(fs, nod)->i_size = size; +- add2dir(fs, parent_nod, nod, name); ++ add2dir(fs, parent_nod, nod, name, mode, uid, gid, ctime); + if(size <= 4 * (EXT2_TIND_BLOCK+1)) + { + strncpy((char*)get_nod(fs, nod)->i_block, (char*)b, size); +@@ -801,15 +1119,15 @@ + } + + // make a file from a FILE* +-uint32 mkfile_fs(filesystem *fs, uint32 parent_nod, const char *name, uint32 mode, size_t size, FILE *f) ++uint32 mkfile_fs(filesystem *fs, uint32 parent_nod, const char *name, uint32 mode, size_t size, FILE *f, uid_t uid, gid_t gid, time_t ctime) + { + uint8 * b; + uint32 nod = alloc_nod(fs); +- get_nod(fs, nod)->i_mode = FM_IFREG | mode; ++ mode |= FM_IFREG; + get_nod(fs, nod)->i_size = size; +- add2dir(fs, parent_nod, nod, name); ++ add2dir(fs, parent_nod, nod, name, mode, uid, gid, ctime); + if(!(b = (uint8*)malloc(rndup(size, BLOCKSIZE)))) +- errexit("not enough mem to read file '%s'", name); ++ error_msg_and_die("not enough mem to read file '%s'", name); + memset(b, 0,rndup(size, BLOCKSIZE)); + if(f) + fread(b, size, 1, f); +@@ -824,6 +1142,15 @@ + uint32 get_mode(struct stat *st) + { + uint32 mode = 0; ++ ++ /* Squash file permissions as needed */ ++ if (squash_perms) { ++ if (!S_ISLNK(mode)) { ++ st->st_mode &= ~(S_IWGRP | S_IWOTH); ++ st->st_mode &= ~(S_ISUID | S_ISGID); ++ } ++ } ++ + if(st->st_mode & S_IRUSR) + mode |= FM_IRUSR | FM_IRGRP | FM_IROTH; + if(st->st_mode & S_IWUSR) +@@ -833,30 +1160,17 @@ + return mode; + } + +-// retrieves a mode info from a string +-uint32 get_modestr(const char *p) +-{ +- uint32 mode = 0; +- if(p[0] == 'r') +- mode |= FM_IRUSR | FM_IRGRP | FM_IROTH; +- if(p[1] == 'w') +- mode |= FM_IWUSR | FM_IWGRP | FM_IWOTH; +- if(p[2] == 'x' || p[2] == 's') +- mode |= FM_IXUSR | FM_IXGRP | FM_IXOTH; +- return mode; +-} +- + // basename of a path - free me + char * basename(const char * fullpath) + { + char * p = strrchr(fullpath, '/'); +- return strdup(p ? p + 1 : fullpath); ++ return xstrdup(p ? p + 1 : fullpath); + } + + // dirname of a path - free me + char * dirname(const char * fullpath) + { +- char * p, * n = strdup(fullpath); ++ char * p, * n = xstrdup(fullpath); + if((p = strrchr(n, '/'))) + *(p+1) = 0; + else +@@ -864,66 +1178,6 @@ + return n; + } + +-// adds entries to the filesystem from a text file +-void add2fs_from_file(filesystem *fs, uint32 this_nod, FILE * fh) +-{ +- uint32 mode; +- uint32 nod, nod2; +- char cmod[11], *path, *name, *dir; +- int major, minor; +- while(fscanf(fh, "%10s", cmod)) +- { +- if(feof(fh)) +- break; +- mode = get_modestr(cmod + 1); +- switch(*cmod) +- { +- case 'd': +- fscanf(fh, "%" SCANF_PREFIX "s\n", SCANF_STRING(path)); +- break; +- case 'c': +- mode |= FM_IFCHR; +- fscanf(fh, "%i, %i %" SCANF_PREFIX "s\n", &major, &minor, SCANF_STRING(path)); +- break; +- case 'b': +- mode |= FM_IFBLK; +- fscanf(fh, "%i, %i %" SCANF_PREFIX "s\n", &major, &minor, SCANF_STRING(path)); +- break; +- case '#': +- while(fgetc(fh) != '\n'); +- continue; +- default: +- errexit("malformed text input file"); +- } +- name = basename(path); +- dir = dirname(path); +- free(path); +- if(!(nod = find_path(fs, this_nod, dir))) +- errexit("can't find directory '%s' to create '%s''", dir, name); +- free(dir); +- if((!strcmp(name, ".")) || (!strcmp(name, ".."))) +- { +- free(name); +- continue; +- } +- switch(*cmod) +- { +- case 'd': +- mkdir_fs(fs, nod, name, mode); +- break; +- case 'c': +- case 'b': +- nod2 = alloc_nod(fs); +- get_nod(fs, nod2)->i_mode = mode; +- ((uint8*)get_nod(fs, nod2)->i_block)[0] = minor; +- ((uint8*)get_nod(fs, nod2)->i_block)[1] = major; +- add2dir(fs, nod, nod2, name); +- break; +- } +- free(name); +- } +-} +- + // adds a tree of entries to the filesystem from current dir + void add2fs_from_dir(filesystem *fs, uint32 this_nod) + { +@@ -934,7 +1188,7 @@ + struct stat st; + uint8 *b; + if(!(dh = opendir("."))) +- pexit("."); ++ perror_msg_and_die("."); + while((dent = readdir(dh))) + { + if((!strcmp(dent->d_name, ".")) || (!strcmp(dent->d_name, ".."))) +@@ -948,31 +1202,27 @@ + get_nod(fs, nod)->i_mode = (((st.st_mode & S_IFMT) == S_IFCHR) ? FM_IFCHR : FM_IFBLK) | get_mode(&st); + ((uint8*)get_nod(fs, nod)->i_block)[0] = (st.st_rdev & 0xff); + ((uint8*)get_nod(fs, nod)->i_block)[1] = (st.st_rdev >> 8); +- add2dir(fs, this_nod, nod, dent->d_name); ++ add2dir(fs, this_nod, nod, dent->d_name, st.st_mode, st.st_uid, st.st_gid, st.st_ctime); + break; + case S_IFLNK: +- if(!(b = (uint8*)malloc(rndup(st.st_size, BLOCKSIZE)))) +- errexit("out of memory"); +- if(readlink(dent->d_name, (char*)b, st.st_size) < 0) +- pexit(dent->d_name); +- mklink_fs(fs, this_nod, dent->d_name, st.st_size, b); ++ b = xreadlink(dent->d_name); ++ mklink_fs(fs, this_nod, dent->d_name, st.st_size, b, st.st_uid, st.st_gid, st.st_ctime); + free(b); + break; + case S_IFREG: +- if(!(fh = fopen(dent->d_name, "r"))) +- pexit(dent->d_name); +- mkfile_fs(fs, this_nod, dent->d_name, get_mode(&st), st.st_size, fh); ++ fh = xfopen(dent->d_name, "r"); ++ mkfile_fs(fs, this_nod, dent->d_name, st.st_mode, st.st_size, fh, st.st_uid, st.st_gid, st.st_ctime); + fclose(fh); + break; + case S_IFDIR: +- nod = mkdir_fs(fs, this_nod, dent->d_name, get_mode(&st)); ++ nod = mkdir_fs(fs, this_nod, dent->d_name, st.st_mode, st.st_uid, st.st_gid, st.st_ctime); + if(chdir(dent->d_name) < 0) +- pexit(dent->d_name); ++ perror_msg_and_die(dent->d_name); + add2fs_from_dir(fs, nod); + chdir(".."); + break; + default: +- fprintf(stderr, "ignoring entry %s", dent->d_name); ++ error_msg("ignoring entry %s", dent->d_name); + } + } + closedir(dh); +@@ -981,9 +1231,11 @@ + // endianness swap of x-indirect blocks + void swap_goodblocks(filesystem *fs, inode *nod) + { +- int i; ++ int i,j,done=0; ++ uint32 *b,*b2; ++ + int nblk = nod->i_blocks / INOBLK; +- if((nod->i_size && !nblk) || (nod->i_mode & (FM_IFBLK | FM_IFCHR))) ++ if((nod->i_size && !nblk) || ((nod->i_mode & FM_IFBLK) == FM_IFBLK) || ((nod->i_mode & FM_IFCHR) == FM_IFCHR)) + for(i = 0; i <= EXT2_TIND_BLOCK; i++) + nod->i_block[i] = swab32(nod->i_block[i]); + if(nblk <= EXT2_IND_BLOCK) +@@ -991,20 +1243,55 @@ + swap_block(get_blk(fs, nod->i_block[EXT2_IND_BLOCK])); + if(nblk <= EXT2_IND_BLOCK + BLOCKSIZE/4) + return; ++ /* Currently this will fail b'cos the number of blocks as stored ++ in i_blocks also includes the indirection blocks (see ++ walk_bw). But this function assumes that i_blocks only ++ stores the count of data blocks ( Actually according to ++ "Understanding the Linux Kernel" (Table 17-3 p502 1st Ed) ++ i_blocks IS supposed to store the count of data blocks). so ++ with a file of size 268K nblk would be 269.The above check ++ will be false even though double indirection hasn't been ++ started.This is benign as 0 means block 0 which has been ++ zeroed out and therefore points back to itself from any offset ++ */ ++ assert(nod->i_block[EXT2_DIND_BLOCK] != 0); + for(i = 0; i < BLOCKSIZE/4; i++) ++ /* Should this be... ++ if(nblk > EXT2_IND_BLOCK + BLOCKSIZE/4 + (BLOCKSIZE/4)*i ) ++ */ + if(nblk > EXT2_IND_BLOCK + BLOCKSIZE/4 + i) + swap_block(get_blk(fs, ((uint32*)get_blk(fs, nod->i_block[EXT2_DIND_BLOCK]))[i])); + swap_block(get_blk(fs, nod->i_block[EXT2_DIND_BLOCK])); + if(nblk <= EXT2_IND_BLOCK + BLOCKSIZE/4 + BLOCKSIZE/4 * BLOCKSIZE/4) + return; +- errexit("too big file on the filesystem"); ++ /* Adding support for triple indirection */ ++ b = (uint32*)get_blk(fs,nod->i_block[EXT2_TIND_BLOCK]); ++ for(i=0;i < BLOCKSIZE/4 && !done ; i++) { ++ b2 = (uint32*)get_blk(fs,b[i]); ++ for(j=0; j ( EXT2_IND_BLOCK + BLOCKSIZE/4 + ++ (BLOCKSIZE/4)*(BLOCKSIZE/4) + ++ i*(BLOCKSIZE/4)*(BLOCKSIZE/4) + ++ j*(BLOCKSIZE/4)) ) ++ swap_block(get_blk(fs,b2[j])); ++ else { ++ done = 1; ++ break; ++ } ++ } ++ swap_block((uint8 *)b2); ++ } ++ swap_block((uint8 *)b); ++ return; + } + + void swap_badblocks(filesystem *fs, inode *nod) + { +- int i; ++ int i,j,done=0; ++ uint32 *b,*b2; ++ + int nblk = nod->i_blocks / INOBLK; +- if((nod->i_size && !nblk) || (nod->i_mode & (FM_IFBLK | FM_IFCHR))) ++ if((nod->i_size && !nblk) || ((nod->i_mode & FM_IFBLK) == FM_IFBLK) || ((nod->i_mode & FM_IFCHR) == FM_IFCHR)) + for(i = 0; i <= EXT2_TIND_BLOCK; i++) + nod->i_block[i] = swab32(nod->i_block[i]); + if(nblk <= EXT2_IND_BLOCK) +@@ -1012,13 +1299,34 @@ + swap_block(get_blk(fs, nod->i_block[EXT2_IND_BLOCK])); + if(nblk <= EXT2_IND_BLOCK + BLOCKSIZE/4) + return; ++ /* See comment in swap_goodblocks */ ++ assert(nod->i_block[EXT2_DIND_BLOCK] != 0); + swap_block(get_blk(fs, nod->i_block[EXT2_DIND_BLOCK])); + for(i = 0; i < BLOCKSIZE/4; i++) ++ /* See comment in swap_goodblocks */ + if(nblk > EXT2_IND_BLOCK + BLOCKSIZE/4 + i) + swap_block(get_blk(fs, ((uint32*)get_blk(fs, nod->i_block[EXT2_DIND_BLOCK]))[i])); + if(nblk <= EXT2_IND_BLOCK + BLOCKSIZE/4 + BLOCKSIZE/4 * BLOCKSIZE/4) + return; +- errexit("too big file on the filesystem"); ++ /* Adding support for triple indirection */ ++ b = (uint32*)get_blk(fs,nod->i_block[EXT2_TIND_BLOCK]); ++ swap_block((uint8 *)b); ++ for(i=0;i < BLOCKSIZE/4 && !done ; i++) { ++ b2 = (uint32*)get_blk(fs,b[i]); ++ swap_block((uint8 *)b2); ++ for(j=0; j ( EXT2_IND_BLOCK + BLOCKSIZE/4 + ++ (BLOCKSIZE/4)*(BLOCKSIZE/4) + ++ i*(BLOCKSIZE/4)*(BLOCKSIZE/4) + ++ j*(BLOCKSIZE/4)) ) ++ swap_block(get_blk(fs,b2[j])); ++ else { ++ done = 1; ++ break; ++ } ++ } ++ } ++ return; + } + + // endianness swap of the whole filesystem +@@ -1045,7 +1353,8 @@ + swap_goodblocks(fs, nod); + swap_nod(nod); + } +- swap_gd(&fs->gd); ++ for(i=0;igd[i])); + swap_sb(&fs->sb); + } + +@@ -1053,7 +1362,8 @@ + { + int i; + swap_sb(&fs->sb); +- swap_gd(&fs->gd); ++ for(i=0;igd[i])); + for(i = 1; i < fs->sb.s_inodes_count; i++) + { + inode *nod = get_nod(fs, i); +@@ -1084,53 +1394,118 @@ + directory *d; + uint8 * b; + uint32 nod; ++ uint32 nbgroups,nbinodes_per_group,overhead_per_group,free_blocks, ++ free_blocks_per_group,nbblocks_per_group; ++ uint32 gd,itbl,ibmpos,bbmpos,itblpos; ++ int j; ++ uint8 *bbm,*ibm; ++ inode *itab0; + + if(nbblocks < 16) // totally arbitrary +- errexit("too small filesystem"); +- if(nbblocks >BLOCKS_PER_GROUP) // I build only one group +- errexit("too big filesystem"); ++ error_msg_and_die("too small filesystem"); ++ ++ /* nbblocks is the total number of blocks in the system. First ++ * calculate how much overhead blocks - inode table blocks,bitmap ++ * blocks,group descriptor blocks etc. - are needed assuming each ++ * group has BLOCKS_PER_GROUP blocks.Then recalculate nbblocks with ++ * this figure. Each group has the same number of blocks. So the fs ++ * has a size atleast the given value but usually rounded off to a i ++ * higher number. ++ */ ++ nbgroups = rndup(nbblocks,BLOCKS_PER_GROUP)/ BLOCKS_PER_GROUP; ++ nbinodes_per_group = nbinodes/nbgroups +1; ++ nbinodes_per_group = rndup(nbinodes_per_group, BLOCKSIZE/sizeof(inode)); ++ if (nbinodes_per_group < 16) ++ nbinodes_per_group = 16; //minimum number b'cos the first 10 are reserved ++ overhead_per_group = 3 /*super block,ibm,bbm*/ ++ + /* No. of blocks that the inodes occupy */ ++ nbinodes_per_group *sizeof(inode)/BLOCKSIZE ++ + /* No. of blocks that group descriptors occupy */ ++ rndup(nbgroups*sizeof(groupdescriptor),BLOCKSIZE)/BLOCKSIZE; ++ free_blocks = nbblocks - overhead_per_group * nbgroups - 1 /*boot block */; ++ free_blocks_per_group = free_blocks/nbgroups; ++ if (free_blocks > free_blocks_per_group * nbgroups) ++ free_blocks_per_group++; ++ nbblocks_per_group = free_blocks_per_group + overhead_per_group; ++ /* e2fsck complains if nbblocks_per_group is not a multiple of 8 */ ++ nbblocks_per_group = rndup(nbblocks_per_group,8); ++ free_blocks_per_group = nbblocks_per_group - overhead_per_group; ++ if (nbblocks_per_group > BLOCKS_PER_GROUP) { ++ /* Can this happen ? */ ++ nbblocks_per_group = BLOCKS_PER_GROUP; ++ free_blocks_per_group = nbblocks_per_group - overhead_per_group; ++ } ++ nbblocks = nbblocks_per_group * nbgroups + 1; ++ ++ + if(!(fs = (filesystem*)calloc(nbblocks, BLOCKSIZE))) +- errexit("not enough memory for filesystem"); ++ error_msg_and_die("not enough memory for filesystem"); + + // create the superblock for an empty filesystem +- fs->sb.s_inodes_count = rndup(nbinodes, BLOCKSIZE/sizeof(inode)); ++ fs->sb.s_inodes_count = nbinodes_per_group * nbgroups; + fs->sb.s_blocks_count = nbblocks; + fs->sb.s_r_blocks_count = nbresrvd; +- fs->sb.s_free_blocks_count = nbblocks; ++ fs->sb.s_free_blocks_count = free_blocks_per_group*nbgroups; + fs->sb.s_free_inodes_count = fs->sb.s_inodes_count - EXT2_FIRST_INO + 1; + fs->sb.s_first_data_block = (BLOCKSIZE == 1024); + fs->sb.s_log_block_size = BLOCKSIZE >> 11; + fs->sb.s_log_frag_size = BLOCKSIZE >> 11; +- fs->sb.s_blocks_per_group = BLOCKS_PER_GROUP; +- fs->sb.s_frags_per_group = BLOCKS_PER_GROUP; +- fs->sb.s_inodes_per_group = fs->sb.s_inodes_count; ++ fs->sb.s_blocks_per_group = nbblocks_per_group; ++ fs->sb.s_frags_per_group = nbblocks_per_group; ++ fs->sb.s_inodes_per_group = nbinodes_per_group; + fs->sb.s_magic = EXT2_MAGIC_NUMBER; + + // set up groupdescriptors +- fs->sb.s_free_blocks_count -= 5 + fs->sb.s_inodes_count * sizeof(inode) / BLOCKSIZE; +- fs->gd.bg_free_blocks_count = fs->sb.s_free_blocks_count; +- fs->gd.bg_free_inodes_count = fs->sb.s_free_inodes_count; +- fs->gd.bg_used_dirs_count = 1; +- fs->gd.bg_block_bitmap = 3; +- fs->gd.bg_inode_bitmap = 4; +- fs->gd.bg_inode_table = 5; +- +- // mark non-filesystem blocks and inodes as allocated +- for(i = fs->sb.s_blocks_count; i <= BLOCKSIZE * 8; i++) +- allocate(fs->bbm, i); +- for(i = fs->sb.s_inodes_count + 1; i <= BLOCKSIZE * 8; i++) +- allocate(fs->ibm, i); +- +- // mark system blocsk and inodes as allocated +- for(i = 1; i <= 4 + fs->sb.s_inodes_count * sizeof(inode) / BLOCKSIZE; i++) +- allocate(fs->bbm, i); +- for(i = 1; i < EXT2_FIRST_INO; i++) +- allocate(fs->ibm, i); +- +- // make root inode and directory +- fs->itab[EXT2_ROOT_INO-1].i_mode = FM_IFDIR | FM_IRWXU | FM_IRWXG | FM_IRWXO; +- fs->itab[EXT2_ROOT_INO-1].i_size = BLOCKSIZE; +- fs->itab[EXT2_ROOT_INO-1].i_links_count = 2; ++ gd = rndup(nbgroups*sizeof(groupdescriptor),BLOCKSIZE)/BLOCKSIZE; ++ itbl = nbinodes_per_group*sizeof(inode)/BLOCKSIZE; ++ for(i = 0,bbmpos=2+gd,ibmpos=3+gd,itblpos =4+gd; ++ igd[i].bg_free_blocks_count = free_blocks_per_group; ++ fs->gd[i].bg_free_inodes_count = nbinodes_per_group; ++ fs->gd[i].bg_used_dirs_count = 0; ++ fs->gd[i].bg_block_bitmap = bbmpos; ++ fs->gd[i].bg_inode_bitmap = ibmpos; ++ fs->gd[i].bg_inode_table = itblpos; ++ } ++ ++ /* Mark non-filesystem blocks and inodes as allocated */ ++ /* Mark system blocks and inodes as allocated */ ++ for(i = 0; igd[i].bg_block_bitmap); ++ //non-filesystem blocks. ++ for(j=fs->sb.s_blocks_per_group + 1; j <= BLOCKSIZE * 8; j++) ++ allocate(bbm, j); ++ //system blocks ++ for(j = 1; j <= 3+gd+itbl; j++) ++ allocate(bbm, j); ++ ++ /* Inode bitmap */ ++ ibm = get_blk(fs,fs->gd[i].bg_inode_bitmap); ++ //non-filesystem inodes ++ for(j = fs->sb.s_inodes_per_group+1; j <= BLOCKSIZE * 8; j++) ++ allocate(ibm, j); ++ } ++ ++ /* We have groups now. Add the root filesystem in group 0 */ ++ /* Also allocate the system inodes in group 0 and update */ ++ /* directory count and inode count for group 0 */ ++ ++ ibm = get_blk(fs,fs->gd[0].bg_inode_bitmap); ++ for(j = 1; j < EXT2_FIRST_INO; j++) { ++ allocate(ibm, j); ++ fs->gd[0].bg_free_inodes_count--; ++ } ++ fs->gd[0].bg_used_dirs_count = 1; ++ itab0 = (inode *)get_blk(fs,fs->gd[0].bg_inode_table); ++ itab0[EXT2_ROOT_INO-1].i_mode = FM_IFDIR | FM_IRWXU | FM_IRWXG | FM_IRWXO; ++ itab0[EXT2_ROOT_INO-1].i_size = BLOCKSIZE; ++ itab0[EXT2_ROOT_INO-1].i_links_count = 2; ++ + b = get_workblk(); + d = (directory*)b; + d->d_inode = EXT2_ROOT_INO; +@@ -1147,9 +1522,14 @@ + // make lost+found directory and reserve blocks + if(fs->sb.s_r_blocks_count) + { +- nod = mkdir_fs(fs, EXT2_ROOT_INO, "lost+found", FM_IRWXU | FM_IRWXG | FM_IRWXO); ++ nod = mkdir_fs(fs, EXT2_ROOT_INO, "lost+found", S_IRWXU|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH, 0, 0, time(NULL)); + memset(b, 0, BLOCKSIZE); + ((directory*)b)->d_rec_len = BLOCKSIZE; ++ /* We run into problems with e2fsck if directory lost+found grows ++ * bigger than this. Need to find out why this happens - sundar ++ */ ++ if (fs->sb.s_r_blocks_count > 2049 ) ++ fs->sb.s_r_blocks_count=2049; + for(i = 1; i < fs->sb.s_r_blocks_count; i++) + extend_blk(fs, nod, b, 1); + get_nod(fs, nod)->i_size = fs->sb.s_r_blocks_count * BLOCKSIZE; +@@ -1170,24 +1550,24 @@ + // loads a filesystem from disk + filesystem * load_fs(FILE * fh, int swapit) + { +- size_t fssize; ++ size_t fssize = 0; + filesystem *fs; + if((fseek(fh, 0, SEEK_END) < 0) || ((fssize = ftell(fh)) < 0)) +- pexit("input filesystem image"); ++ perror_msg_and_die("input filesystem image"); + rewind(fh); + fssize = (fssize + BLOCKSIZE - 1) / BLOCKSIZE; + if(fssize < 16) // totally arbitrary +- errexit("too small filesystem"); +- if(fssize > BLOCKS_PER_GROUP) // I build only one group +- errexit("too big filesystem"); ++ error_msg_and_die("too small filesystem"); ++/* if(fssize > BLOCKS_PER_GROUP) // I build only one group ++ error_msg_and_die("too big filesystem"); */ + if(!(fs = (filesystem*)calloc(fssize, BLOCKSIZE))) +- errexit("not enough memory for filesystem"); ++ error_msg_and_die("not enough memory for filesystem"); + if(fread(fs, BLOCKSIZE, fssize, fh) != fssize) +- pexit("input filesystem image"); ++ perror_msg_and_die("input filesystem image"); + if(swapit) + swap_badfs(fs); + if(fs->sb.s_rev_level || (fs->sb.s_magic != EXT2_MAGIC_NUMBER)) +- errexit("not a suitable ext2 filesystem"); ++ error_msg_and_die("not a suitable ext2 filesystem"); + return fs; + } + +@@ -1230,9 +1610,9 @@ + while((bk = walk_bw(fs, nod, &bw, 0, 0)) != WALK_END) + { + if(fsize <= 0) +- errexit("wrong size while saving inode %d", nod); ++ error_msg_and_die("wrong size while saving inode %d", nod); + if(fwrite(get_blk(fs, bk), (fsize > BLOCKSIZE) ? BLOCKSIZE : fsize, 1, f) != 1) +- errexit("error while saving inode %d", nod); ++ error_msg_and_die("error while saving inode %d", nod); + fsize -= BLOCKSIZE; + } + } +@@ -1250,7 +1630,7 @@ + { + int i, j; + if(fsize <= 0) +- errexit("wrong size while saving inode %d", nod); ++ error_msg_and_die("wrong size while saving inode %d", nod); + b = get_blk(fs, bk); + for(i = 0; i < 64; i++) + { +@@ -1406,7 +1786,7 @@ + s = (nod >= EXT2_FIRST_INO) ? "normal" : "unknown reserved"; + } + printf("inode %d (%s, %d links): ", nod, s, get_nod(fs, nod)->i_links_count); +- if(!allocated(fs->ibm, nod)) ++ if(!allocated(GRP_GET_INODE_BITMAP(fs,nod), GRP_IBM_OFFSET(fs,nod))) + { + printf("unallocated\n"); + return; +@@ -1440,24 +1820,46 @@ + default: + list_blocks(fs, nod); + } ++ printf("Done with inode %d\n",nod); + } + + // describes various fields in a filesystem + void print_fs(filesystem *fs) + { +- int i; +- printf("%d blocks (%d free, %d reserved), first data block: %d\n", fs->sb.s_blocks_count, fs->sb.s_free_blocks_count, fs->sb.s_r_blocks_count, fs->sb.s_first_data_block); +- printf("%d inodes (%d free)\n", fs->sb.s_inodes_count, fs->sb.s_free_inodes_count); +- printf("block size = %d, frag size = %d\n", fs->sb.s_log_block_size ? (fs->sb.s_log_block_size << 11) : 1024, fs->sb.s_log_frag_size ? (fs->sb.s_log_frag_size << 11) : 1024); +- printf("%d blocks per group, %d frags per group, %d inodes per group\n", fs->sb.s_blocks_per_group, fs->sb.s_frags_per_group, fs->sb.s_inodes_per_group); +- printf("block bitmap: block %d, inode bitmap: block %d, inode table: block %d\n", fs->gd.bg_block_bitmap, fs->gd.bg_inode_bitmap, fs->gd.bg_inode_table); +- printf("block bitmap allocation:\n"); +- print_bm(fs->bbm, fs->sb.s_blocks_count); +- printf("inode bitmap allocation:\n"); +- print_bm(fs->ibm, fs->sb.s_inodes_count); +- for(i=1; i<=fs->sb.s_inodes_count; i++) +- if(allocated(fs->ibm, i)) +- print_inode(fs, i); ++ int i,j; ++ uint8 *ibm; ++ ++ printf("%d blocks (%d free, %d reserved), first data block: %d\n", ++ fs->sb.s_blocks_count, fs->sb.s_free_blocks_count, ++ fs->sb.s_r_blocks_count, fs->sb.s_first_data_block); ++ printf("%d inodes (%d free)\n", fs->sb.s_inodes_count, ++ fs->sb.s_free_inodes_count); ++ printf("block size = %d, frag size = %d\n", ++ fs->sb.s_log_block_size ? (fs->sb.s_log_block_size << 11) : 1024, ++ fs->sb.s_log_frag_size ? (fs->sb.s_log_frag_size << 11) : 1024); ++ printf("Number of groups: %d\n",GRP_NBGROUPS(fs)); ++ printf("%d blocks per group,%d frags per group,%d inodes per group\n", ++ fs->sb.s_blocks_per_group, fs->sb.s_frags_per_group, ++ fs->sb.s_inodes_per_group); ++ printf("Size of inode table: %d blocks\n", ++ fs->sb.s_inodes_per_group * sizeof(inode)/BLOCKSIZE); ++ for (i = 0; i < GRP_NBGROUPS(fs); i++) { ++ printf("Group No: %d\n", i); ++ printf("block bitmap: block %d,inode bitmap: block %d, inode table: block %d\n", ++ fs->gd[i].bg_block_bitmap, fs->gd[i].bg_inode_bitmap, ++ fs->gd[i].bg_inode_table); ++ printf("Free blocks count: %d\n",fs->gd[i].bg_free_blocks_count); ++ printf("Free inodes count: %d\n",fs->gd[i].bg_free_inodes_count); ++ printf("Used dir count: %d\n",fs->gd[i].bg_used_dirs_count); ++ printf("block bitmap allocation:\n"); ++ print_bm(GRP_GET_GROUP_BBM(fs, i),fs->sb.s_blocks_per_group); ++ printf("inode bitmap allocation:\n"); ++ ibm = GRP_GET_GROUP_IBM(fs, i); ++ print_bm(ibm, fs->sb.s_inodes_per_group); ++ for (j = 1; j <= fs->sb.s_inodes_per_group; j++) ++ if (allocated(ibm, j)) ++ print_inode(fs, i*fs->sb.s_inodes_per_group + j); ++ } + } + + void dump_fs(filesystem *fs, FILE * fh, int swapit) +@@ -1467,31 +1869,234 @@ + if(swapit) + swap_goodfs(fs); + if(fwrite(fs, BLOCKSIZE, nbblocks, fh) < nbblocks) +- pexit("output filesystem image"); ++ perror_msg_and_die("output filesystem image"); + if(swapit) + swap_badfs(fs); + } + ++/* device table entries take the form of: ++ ++ /dev/mem c 640 0 0 1 1 0 0 - ++ ++ type can be one of: ++ f A regular file ++ d Directory ++ c Character special device file ++ b Block special device file ++ p Fifo (named pipe) ++ ++ I don't bother with symlinks (permissions are irrelevant), hard ++ links (special cases of regular files), or sockets (why bother). ++ ++ Regular files must exist in the target root directory. If a char, ++ block, fifo, or directory does not exist, it will be created. ++*/ ++static int interpret_table_entry(filesystem *fs, char *line) ++{ ++ char type, *name = NULL, *tmp, *dir, *bname; ++ unsigned long mode = 0755, uid = 0, gid = 0, major = 0, minor = 0; ++ unsigned long start = 0, increment = 1, count = 0; ++ inode *entry; ++ uint32 nod, parent; ++ ++ if (sscanf (line, "%" SCANF_PREFIX "s %c %lo %lu %lu %lu %lu %lu %lu %lu", ++ SCANF_STRING(name), &type, &mode, &uid, &gid, &major, &minor, ++ &start, &increment, &count) < 0) ++ { ++ return 1; ++ } ++ ++ if (!strcmp(name, "/")) { ++ error_msg_and_die("Device table entries require absolute paths"); ++ } ++ ++ /* Check if this file already exists... */ ++ switch (type) { ++ case 'd': ++ mode |= S_IFDIR; ++ break; ++ case 'f': ++ mode |= S_IFREG; ++ break; ++ case 'p': ++ mode |= S_IFIFO; ++ break; ++ case 'c': ++ mode |= S_IFCHR; ++ break; ++ case 'b': ++ mode |= S_IFBLK; ++ break; ++ default: ++ error_msg_and_die("Unsupported file type"); ++ } ++ nod = 0; ++ if (count==0) ++ nod = find_path(fs, EXT2_ROOT_INO, name); ++ if (nod) { ++ /* Ok, we just need to fixup an existing entry ++ * and we will be all done... */ ++ entry = get_nod(fs, nod); ++ entry->i_uid = uid; ++ entry->i_gid = gid; ++ entry->i_mode = mode; ++ if (major) { ++ dev_t rdev = makedev(major, minor); ++ ((uint8*)entry->i_block)[0] = (rdev & 0xff); ++ ((uint8*)entry->i_block)[1] = (rdev >> 8); ++ } ++ } else { ++ /* Try and find our parent now */ ++ tmp = xstrdup(name); ++ dir = dirname(tmp); ++ parent = find_path(fs, EXT2_ROOT_INO, dir); ++ free(tmp); ++ if (!parent) { ++ error_msg ("skipping device_table entry '%s': no parent directory!", name); ++ free(name); ++ return 1; ++ } ++ ++ tmp = xstrdup(name); ++ bname = xstrdup(basename(tmp)); ++ free(tmp); ++ switch (type) { ++ case 'd': ++ mkdir_fs(fs, parent, bname, mode|FM_IFDIR, uid, gid, time(NULL)); ++ break; ++ case 'f': ++#if 0 ++ { ++ // This is a bit odd.. This will try to include ++ // the file of the same name from your _build_ ++ // system... Probably a very bad idea.... ++ struct stat st; ++ FILE *fh = xfopen(name, "r"); ++ lstat(name, &st); ++ mkfile_fs(fs, parent, bname, mode|FM_IFREG, st.st_size, fh, uid, gid, st.st_ctime); ++ fclose(fh); ++ } ++#else ++ error_msg("ignoring entry %s", name); ++#endif ++ break; ++ case 'p': ++ error_msg("ignoring entry %s", name); ++ break; ++ case 'c': ++ case 'b': ++ if (count > 0) { ++ dev_t rdev; ++ char *dname; ++ unsigned long i; ++ for (i = start; i < count; i++) { ++ asprintf(&dname, "%s%lu", bname, i); ++ nod = find_path(fs, EXT2_ROOT_INO, dname); ++ if (nod) { ++ /* We just need to fixup an existing entry */ ++ entry = get_nod(fs, nod); ++ } else { ++ nod = alloc_nod(fs); ++ add2dir(fs, parent, nod, dname, mode, uid, gid, time(NULL)); ++ entry = get_nod(fs, nod); ++ } ++ entry->i_uid = uid; ++ entry->i_gid = gid; ++ entry->i_mode = mode; ++ rdev = makedev(major, minor + (i * increment - start)); ++ ((uint8*)entry->i_block)[0] = (rdev & 0xff); ++ ((uint8*)entry->i_block)[1] = (rdev >> 8); ++ free(dname); ++ } ++ } else { ++ dev_t rdev = makedev(major, minor); ++ nod = alloc_nod(fs); ++ add2dir(fs, parent, nod, bname, mode, uid, gid, time(NULL)); ++ entry = get_nod(fs, nod); ++ ((uint8*)entry->i_block)[0] = (rdev & 0xff); ++ ((uint8*)entry->i_block)[1] = (rdev >> 8); ++ } ++ break; ++ default: ++ error_msg_and_die("Unsupported file type"); ++ } ++ free(bname); ++ } ++ free(name); ++ return 0; ++} ++ ++static int parse_device_table(filesystem *root, FILE * file) ++{ ++ char *line; ++ int status = 0; ++ size_t length = 0; ++ ++ /* Turn off squash, since we must ensure that values ++ * entered via the device table are not squashed */ ++ squash_uids = 0; ++ squash_perms = 0; ++ ++ /* Looks ok so far. The general plan now is to read in one ++ * line at a time, check for leading comment delimiters ('#'), ++ * then try and parse the line as a device table. If we fail ++ * to parse things, try and help the poor fool to fix their ++ * device table with a useful error msg... */ ++ line = NULL; ++ while (getline(&line, &length, file) != -1) { ++ /* First trim off any whitespace */ ++ int len = strlen(line); ++ ++ /* trim trailing whitespace */ ++ while (len > 0 && isspace(line[len - 1])) ++ line[--len] = '\0'; ++ /* trim leading whitespace */ ++ memmove(line, &line[strspn(line, " \n\r\t\v")], len); ++ ++ /* How long are we after trimming? */ ++ len = strlen(line); ++ ++ /* If this is NOT a comment line, try to interpret it */ ++ if (len && *line != '#') { ++ if (interpret_table_entry(root, line)) ++ status = 1; ++ } ++ ++ free(line); ++ line = NULL; ++ } ++ fclose(file); ++ ++ return status; ++} ++ ++/* ++Local Variables: ++c-file-style: "linux" ++c-basic-offset: 4 ++tab-width: 4 ++End: ++*/ ++ + void showhelp(void) + { + fprintf(stderr, "Usage: %s [options] image\n" + "Create an ext2 filesystem image from directories/files\n\n" +- " -x image Use this image as a starting point\n" +- " -d directory Add this directory as source\n" +- " -f file Add nodes (e.g. devices) from this spec file\n" +- " -b blocks Size in blocks\n" +- " -i inodes Number of inodes\n" +- " -r reserved Number of reserved blocks\n" +- " -g path Generate a block map file for this path\n" +- " -e value Fill unallocated blocks with value\n" +- " -z Make files with holes\n" +- " -v Print resulting filesystem structure\n" +- " -h Show this help\n\n" +- "Example of spec file:\n" +- "drwx /dev\n" +- "crw- 10,190 /dev/lcd\n" +- "brw- 1,0 /dev/ram0\n\n" +- "Report bugs to xavier.bestel@free.fr\n", argv0); ++ " -x image Use this image as a starting point\n" ++ " -d directory Add this directory as source\n" ++ " -b blocks Size in blocks\n" ++ " -i inodes Number of inodes\n" ++ " -r reserved Number of reserved blocks\n" ++ " -g path Generate a block map file for this path\n" ++ " -e value Fill unallocated blocks with value\n" ++ " -z Make files with holes\n" ++ " -D,-f Use the named FILE as a device table file\n" ++ " -q Squash permissions and owners making all files be owned by root\n" ++ " -U Squash owners making all files be owned by root\n" ++ " -P Squash permissions on all files\n" ++ " -v Print resulting filesystem structure\n" ++ " -h Show this help\n\n" ++ "Report bugs to xavier.bestel@free.fr\n", app_name); + } + + #define MAX_DOPT 128 +@@ -1521,21 +2126,17 @@ + filesystem *fs; + int i; + int c; ++ struct stat sb; ++ FILE *devtable = NULL; + +- argv0 = argv[0]; +- if(argc <= 1) +- { +- showhelp(); +- exit(1); +- } +- while((c = getopt(argc, argv, "x:f:d:b:i:r:g:e:zvh")) != EOF) ++ app_name = argv[0]; ++ while((c = getopt(argc, argv, "x:d:b:i:r:g:e:zvhD:f:qUP")) != EOF) + switch(c) + { + case 'x': + fsin = optarg; + break; + case 'd': +- case 'f': + dopt[didx++] = optarg; + break; + case 'b': +@@ -1556,6 +2157,24 @@ + case 'z': + holes = 1; + break; ++ case 'f': ++ case 'D': ++ devtable = xfopen(optarg, "r"); ++ if (fstat(fileno(devtable), &sb) < 0) ++ perror_msg_and_die(optarg); ++ if (sb.st_size < 10) ++ error_msg_and_die("%s: not a proper device table file", optarg); ++ break; ++ case 'q': ++ squash_uids = 1; ++ squash_perms = 1; ++ break; ++ case 'U': ++ squash_uids = 1; ++ break; ++ case 'P': ++ squash_perms = 1; ++ break; + case 'v': + verbose = 1; + break; +@@ -1566,16 +2185,14 @@ + exit(1); + } + if(optind < (argc - 1)) +- errexit("too many arguments"); ++ error_msg_and_die("too many arguments"); + if(optind == (argc - 1)) + fsout = argv[optind]; + if(fsin) + { + if(strcmp(fsin, "-")) + { +- FILE * fh = fopen(fsin, "r"); +- if(!fh) +- pexit(fsin); ++ FILE * fh = xfopen(fsin, "r"); + fs = load_fs(fh, bigendian); + fclose(fh); + } +@@ -1585,7 +2202,7 @@ + else + { + if(nbblocks == -1) +- errexit("filesystem size unspecified"); ++ error_msg_and_die("filesystem size unspecified"); + if(nbinodes == -1) + nbinodes = nbblocks * BLOCKSIZE / rndup(BYTES_PER_INODE, BLOCKSIZE); + if(nbresrvd == -1) +@@ -1595,35 +2212,30 @@ + for(i = 0; i < didx; i++) + { + struct stat st; +- FILE *fh; + char *pdir; + stat(dopt[i], &st); + switch(st.st_mode & S_IFMT) + { +- case S_IFREG: +- if(!(fh = fopen(dopt[i], "r"))) +- pexit(dopt[i]); +- add2fs_from_file(fs, EXT2_ROOT_INO, fh); +- fclose(fh); +- break; + case S_IFDIR: + if(!(pdir = getcwd(0, GETCWD_SIZE))) +- pexit(dopt[i]); ++ perror_msg_and_die(dopt[i]); + if(chdir(dopt[i]) < 0) +- pexit(dopt[i]); ++ perror_msg_and_die(dopt[i]); + add2fs_from_dir(fs, EXT2_ROOT_INO); + if(chdir(pdir) < 0) +- pexit(pdir); ++ perror_msg_and_die(pdir); + free(pdir); + break; + default: +- errexit("%s in neither a file nor a directory", dopt[i]); ++ error_msg_and_die("%s is neither a file nor a directory", dopt[i]); + } + } + if(emptyval) + for(i = 1; i < fs->sb.s_blocks_count; i++) +- if(!allocated(fs->bbm, i)) ++ if(!allocated(GRP_GET_BLOCK_BITMAP(fs,i),GRP_BBM_OFFSET(fs,i))) + memset(get_blk(fs, i), emptyval, BLOCKSIZE); ++ if(devtable) ++ parse_device_table(fs, devtable); + if(verbose) + print_fs(fs); + for(i = 0; i < gidx; i++) +@@ -1633,21 +2245,18 @@ + char *p; + FILE *fh; + if(!(nod = find_path(fs, EXT2_ROOT_INO, gopt[i]))) +- errexit("path %s not found in filesystem", gopt[i]); ++ error_msg_and_die("path %s not found in filesystem", gopt[i]); + while((p = strchr(gopt[i], '/'))) + *p = '_'; + snprintf(fname, MAX_FILENAME-1, "%s.blk", gopt[i]); +- if(!(fh = fopen(fname, "w"))) +- pexit(fname); ++ fh = xfopen(fname, "w"); + fprintf(fh, "%d:", get_nod(fs, nod)->i_size); + flist_blocks(fs, nod, fh); + fclose(fh); + } + if(strcmp(fsout, "-")) + { +- FILE * fh = fopen(fsout, "w"); +- if(!fh) +- pexit(fsout); ++ FILE * fh = xfopen(fsout, "w"); + dump_fs(fs, fh, bigendian); + fclose(fh); + } +diff -urN genext2fs-1.3.orig/test-mount.sh genext2fs-1.3/test-mount.sh +diff -urN genext2fs-1.3.orig/test.sh genext2fs-1.3/test.sh diff --git a/meta/packages/genext2fs/genext2fs-native_1.3.bb b/meta/packages/genext2fs/genext2fs-native_1.3.bb new file mode 100644 index 000000000..b840a3010 --- /dev/null +++ b/meta/packages/genext2fs/genext2fs-native_1.3.bb @@ -0,0 +1,11 @@ +include genext2fs_${PV}.bb +inherit native +FILESPATH = "${@base_set_filespath([ '${FILE_DIRNAME}/genext2fs-${PV}', '${FILE_DIRNAME}/genext2fs', '${FILE_DIRNAME}/files', '${FILE_DIRNAME}' ], d)}" + +do_stage () { + install -m 0755 genext2fs ${STAGING_BINDIR}/ +} + +do_install () { + : +} diff --git a/meta/packages/genext2fs/genext2fs.inc b/meta/packages/genext2fs/genext2fs.inc new file mode 100644 index 000000000..c2984bccd --- /dev/null +++ b/meta/packages/genext2fs/genext2fs.inc @@ -0,0 +1,4 @@ +LICENSE = "GPL" +DESCRIPTION = "A tool to generate an ext2 filesystem \ +as a normal (non-root) user." +SECTION = "console/utils" diff --git a/meta/packages/genext2fs/genext2fs_1.3.bb b/meta/packages/genext2fs/genext2fs_1.3.bb new file mode 100644 index 000000000..d32d17ae0 --- /dev/null +++ b/meta/packages/genext2fs/genext2fs_1.3.bb @@ -0,0 +1,15 @@ +include genext2fs.inc + +PR = "r3" + +SRC_URI = "${DEBIAN_MIRROR}/main/g/genext2fs/genext2fs_${PV}.orig.tar.gz \ + file://misc.patch;patch=1" +S = "${WORKDIR}/genext2fs-${PV}.orig" + +do_compile () { + oe_runmake +} + +do_install () { + oe_runmake 'DESTDIR=${D}' install +} diff --git a/meta/packages/gettext/gettext-0.14.1/fixchicken.patch b/meta/packages/gettext/gettext-0.14.1/fixchicken.patch new file mode 100644 index 000000000..4174f6d74 --- /dev/null +++ b/meta/packages/gettext/gettext-0.14.1/fixchicken.patch @@ -0,0 +1,26 @@ +Index: gettext-tools/m4/csharpcomp.m4 +=================================================================== +RCS file: /cvs/gettext/gettext/gettext-tools/m4/csharpcomp.m4,v +retrieving revision 1.4 +retrieving revision 1.6 +diff -u -r1.4 -r1.6 +--- a/gettext-tools/m4/csharpcomp.m4 30 Jan 2004 11:01:18 -0000 1.4 ++++ a/gettext-tools/m4/csharpcomp.m4 26 May 2004 12:15:23 -0000 1.6 +@@ -1,4 +1,4 @@ +-# csharpcomp.m4 serial 2 (gettext-0.14.1) ++# csharpcomp.m4 serial 4 (gettext-0.15) + dnl Copyright (C) 2003-2004 Free Software Foundation, Inc. + dnl This file is free software, distributed under the terms of the GNU + dnl General Public License. As a special exception to the GNU General +@@ -43,7 +43,8 @@ + ;; + sscli) + if test -n "$HAVE_CSC_IN_PATH" \ +- && csc -help >/dev/null 2>/dev/null; then ++ && csc -help >/dev/null 2>/dev/null \ ++ && { if csc -help 2>/dev/null | grep -i chicken > /dev/null; then false; else true; fi; }; then + HAVE_CSC=1 + ac_result="csc" + break + + diff --git a/meta/packages/gettext/gettext-0.14.1/gettext-vpath.patch b/meta/packages/gettext/gettext-0.14.1/gettext-vpath.patch new file mode 100644 index 000000000..8251ac0e7 --- /dev/null +++ b/meta/packages/gettext/gettext-0.14.1/gettext-vpath.patch @@ -0,0 +1,11 @@ +--- gettext-0.14.1/gettext-runtime/intl/Makefile.in~ 2004-04-09 13:23:40.000000000 +0100 ++++ gettext-0.14.1/gettext-runtime/intl/Makefile.in 2004-04-09 13:22:05.000000000 +0100 +@@ -24,7 +24,7 @@ + srcdir = $(top_srcdir)/../gettext-runtime/intl + top_srcdir = /var/tmp/oe-tmp.pb/base/gettext-0.14.1-r0/gettext-0.14.1/gettext-tools + top_builddir = .. +-VPATH = $(srcdir) ++#VPATH = $(srcdir) + + prefix = /usr + exec_prefix = /usr diff --git a/meta/packages/gettext/gettext-native_0.14.1.bb b/meta/packages/gettext/gettext-native_0.14.1.bb new file mode 100644 index 000000000..07c9361a1 --- /dev/null +++ b/meta/packages/gettext/gettext-native_0.14.1.bb @@ -0,0 +1,53 @@ +include gettext_${PV}.bb +S = "${WORKDIR}/gettext-${PV}" +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/gettext-${PV}" +inherit native +PROVIDES = "" + +M4 = "\ +lib-ld.m4 \ +lib-link.m4 \ +lib-prefix.m4 \ +codeset.m4 \ +gettext.m4 \ +glibc21.m4 \ +iconv.m4 \ +intdiv0.m4 \ +intmax.m4 \ +inttypes.m4 \ +inttypes_h.m4 \ +inttypes-pri.m4 \ +isc-posix.m4 \ +lcmessage.m4 \ +longdouble.m4 \ +longlong.m4 \ +nls.m4 \ +po.m4 \ +printf-posix.m4 \ +progtest.m4 \ +signed.m4 \ +size_max.m4 \ +stdint_h.m4 \ +uintmax_t.m4 \ +ulonglong.m4 \ +wchar_t.m4 \ +wint_t.m4 \ +xsize.m4 \ +" + +do_stage_append() { + for i in ${M4}; do + src="gettext-runtime/m4/$i" + if [ ! -f $src ]; then + src="gettext-tools/m4/$i" + fi + if [ ! -f $src ]; then + src="autoconf-lib-link/m4/$i" + fi + if [ ! -f $src ]; then + echo "can't find $i" >&2 + exit 1 + fi + install -m 0644 $src ${STAGING_DATADIR}/aclocal/$i + done +} diff --git a/meta/packages/gettext/gettext_0.14.1.bb b/meta/packages/gettext/gettext_0.14.1.bb new file mode 100644 index 000000000..9e2222aa0 --- /dev/null +++ b/meta/packages/gettext/gettext_0.14.1.bb @@ -0,0 +1,33 @@ +DESCRIPTION = "The GNU internationalization library." +HOMEPAGE = "http://www.gnu.org/software/gettext/gettext.html" +SECTION = "libs" +LICENSE = "GPL" +PR = "r3" +PROVIDES = "virtual/libintl" + +SRC_URI = "${GNU_MIRROR}/gettext/gettext-${PV}.tar.gz \ + file://gettext-vpath.patch;patch=1;pnum=1 \ + file://fixchicken.patch;patch=1;pnum=1" + +PARALLEL_MAKE = "" + +inherit autotools + +EXTRA_OECONF += "--without-lisp" +acpaths = '-I ${S}/autoconf-lib-link/m4/ \ + -I ${S}/gettext-runtime/m4 \ + -I ${S}/gettext-tools/m4' + +do_configure_prepend() { + rm -f ${S}/config/m4/libtool.m4 + install -m 0644 ${STAGING_DATADIR}/aclocal/libtool.m4 ${S}/config/m4/ +} + +do_stage () { + autotools_stage_includes + oe_libinstall -so -C gettext-tools/lib libgettextlib ${STAGING_LIBDIR}/ + oe_libinstall -so -C gettext-tools/src libgettextpo ${STAGING_LIBDIR}/ + oe_libinstall -so -C gettext-tools/src libgettextsrc ${STAGING_LIBDIR}/ + oe_libinstall -so -C gettext-tools/intl libintl ${STAGING_LIBDIR}/ + oe_libinstall -so -C gettext-runtime/lib libasprintf ${STAGING_LIBDIR}/ +} diff --git a/meta/packages/glib-2.0/files/atomic_fix.patch b/meta/packages/glib-2.0/files/atomic_fix.patch new file mode 100644 index 000000000..ddc7ada77 --- /dev/null +++ b/meta/packages/glib-2.0/files/atomic_fix.patch @@ -0,0 +1,16 @@ +Index: glib-2.10.3/glib/gthread.c +=================================================================== +--- glib-2.10.3.orig/glib/gthread.c 2005-12-01 16:34:26.000000000 +0000 ++++ glib-2.10.3/glib/gthread.c 2006-07-06 08:17:18.000000000 +0100 +@@ -164,10 +164,10 @@ + _g_messages_thread_init_nomessage (); + + /* we may run full-fledged initializers from here */ ++ _g_atomic_thread_init (); + _g_convert_thread_init (); + _g_rand_thread_init (); + _g_main_thread_init (); +- _g_atomic_thread_init (); + _g_utils_thread_init (); + #ifdef G_OS_WIN32 + _g_win32_thread_init (); diff --git a/meta/packages/glib-2.0/files/glib-gettextize-dir.patch b/meta/packages/glib-2.0/files/glib-gettextize-dir.patch new file mode 100644 index 000000000..989211c92 --- /dev/null +++ b/meta/packages/glib-2.0/files/glib-gettextize-dir.patch @@ -0,0 +1,11 @@ +--- glib-2.6.2/glib-gettextize.in.old 2005-02-15 02:43:17.000000000 +0000 ++++ glib-2.6.2/glib-gettextize.in 2005-02-15 02:43:18.000000000 +0000 +@@ -43,7 +43,7 @@ + + # Directory where the sources are stored. + prefix=@prefix@ +-gettext_dir=@prefix@/share/glib-2.0/gettext ++gettext_dir=@datadir@/glib-2.0/gettext + + while test $# -gt 0; do + case "$1" in diff --git a/meta/packages/glib-2.0/files/glibconfig-sysdefs.h b/meta/packages/glib-2.0/files/glibconfig-sysdefs.h new file mode 100644 index 000000000..1329e7f21 --- /dev/null +++ b/meta/packages/glib-2.0/files/glibconfig-sysdefs.h @@ -0,0 +1,6 @@ +#define GLIB_SYSDEF_POLLIN =1 +#define GLIB_SYSDEF_POLLOUT =4 +#define GLIB_SYSDEF_POLLPRI =2 +#define GLIB_SYSDEF_POLLERR =8 +#define GLIB_SYSDEF_POLLHUP =16 +#define GLIB_SYSDEF_POLLNVAL =32 diff --git a/meta/packages/glib-2.0/files/glibinclude.patch b/meta/packages/glib-2.0/files/glibinclude.patch new file mode 100644 index 000000000..5413e50e0 --- /dev/null +++ b/meta/packages/glib-2.0/files/glibinclude.patch @@ -0,0 +1,18 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- glib-2.0-2.4.6-r1/glib-2.4.6/glib/Makefile.am~glibinclude.patch ++++ glib-2.0-2.4.6-r1/glib-2.4.6/glib/Makefile.am +@@ -157,8 +157,8 @@ + gprintf.h + + install-data-local: install-ms-lib install-libtool-import-lib +- @if test -f $(glibincludedir)/glist.h ; then \ +- echo "*** Old headers found in $(glibincludedir). You should remove the" ; \ ++ @if test -f $(DESTDIR)$(glibincludedir)/glist.h ; then \ ++ echo "*** Old headers found in $(DESTDIR)$(glibincludedir). You should remove the" ; \ + echo "*** contents of this directory and type 'make install' again." ; \ + false ; \ + fi diff --git a/meta/packages/glib-2.0/glib-2.0-native-2.10.3/glib-gettextize-dir.patch b/meta/packages/glib-2.0/glib-2.0-native-2.10.3/glib-gettextize-dir.patch new file mode 100644 index 000000000..efe332557 --- /dev/null +++ b/meta/packages/glib-2.0/glib-2.0-native-2.10.3/glib-gettextize-dir.patch @@ -0,0 +1,11 @@ +--- glib-2.10.3/glib-gettextize.in.old 2006-06-21 12:46:45.000000000 +0100 ++++ glib-2.10.3/glib-gettextize.in 2006-06-21 12:48:14.000000000 +0100 +@@ -49,7 +49,7 @@ + ;; + esac + +-gettext_dir=$prefix/share/glib-2.0/gettext ++gettext_dir=@datadir@/glib-2.0/gettext + + while test $# -gt 0; do + case "$1" in diff --git a/meta/packages/glib-2.0/glib-2.0-native_2.10.3.bb b/meta/packages/glib-2.0/glib-2.0-native_2.10.3.bb new file mode 100644 index 000000000..402ec2d39 --- /dev/null +++ b/meta/packages/glib-2.0/glib-2.0-native_2.10.3.bb @@ -0,0 +1,55 @@ +DESCRIPTION = "GLib is a general-purpose utility library, \ +which provides many useful data types, macros, \ +type conversions, string utilities, file utilities, a main \ +loop abstraction, and so on. It works on many \ +UNIX-like platforms, Windows, OS/2 and BeOS." +LICENSE = "LGPL" +SECTION = "libs" +PRIORITY = "optional" +DEPENDS += "gtk-doc-native" +PR="r1" + +EXTRA_OECONF = "--disable-debug" + +SRC_URI = "http://download.gnome.org/sources/glib/2.10//glib-${PV}.tar.bz2 \ + file://glib-gettextize-dir.patch;patch=1 \ + file://atomic_fix.patch;patch=1 \ + file://glibconfig-sysdefs.h" + +S = "${WORKDIR}/glib-${PV}" + +inherit autotools pkgconfig native gettext + +python () { + if bb.data.getVar("USE_NLS", d, 1) == "no": + raise bb.parse.SkipPackage("${PN} requires native language support.") +} + +acpaths = "" +do_configure_prepend () { + install -m 0644 ${WORKDIR}/glibconfig-sysdefs.h . +} + +do_stage () { + install -m 0755 gobject/glib-mkenums ${STAGING_BINDIR}/ + install -m 0755 gobject/.libs/glib-genmarshal ${STAGING_BINDIR}/ + install -m 0755 glib-gettextize ${STAGING_BINDIR}/ + oe_libinstall -so -C glib libglib-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gmodule libgmodule-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gthread libgthread-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gobject libgobject-2.0 ${STAGING_LIBDIR} + autotools_stage_includes + install -d ${STAGING_INCDIR}/glib-2.0/glib + install -m 0755 ${S}/glibconfig.h ${STAGING_INCDIR}/glib-2.0/glibconfig.h + install -d ${STAGING_DATADIR}/aclocal + install -m 0644 ${S}/m4macros/glib-2.0.m4 ${STAGING_DATADIR}/aclocal/glib-2.0.m4 + install -m 0644 ${S}/m4macros/glib-gettext.m4 ${STAGING_DATADIR}/aclocal/glib-gettext.m4 + install -d ${STAGING_DATADIR}/glib-2.0/gettext/po + install -m 0755 mkinstalldirs ${STAGING_DATADIR}/glib-2.0/gettext/ + install -m 0644 po/Makefile.in.in ${STAGING_DATADIR}/glib-2.0/gettext/po/ +} + +do_install () { + : +} + diff --git a/meta/packages/glib-2.0/glib-2.0-native_2.12.0.bb b/meta/packages/glib-2.0/glib-2.0-native_2.12.0.bb new file mode 100644 index 000000000..768f2777d --- /dev/null +++ b/meta/packages/glib-2.0/glib-2.0-native_2.12.0.bb @@ -0,0 +1,54 @@ +DESCRIPTION = "GLib is a general-purpose utility library, \ +which provides many useful data types, macros, \ +type conversions, string utilities, file utilities, a main \ +loop abstraction, and so on. It works on many \ +UNIX-like platforms, Windows, OS/2 and BeOS." +LICENSE = "LGPL" +SECTION = "libs" +PRIORITY = "optional" +DEPENDS += "gtk-doc-native" +PR="r1" + +EXTRA_OECONF = "--disable-debug" + +SRC_URI = "http://download.gnome.org/sources/glib/2.12/glib-${PV}.tar.bz2 \ + file://glib-gettextize-dir.patch;patch=1 \ + file://glibconfig-sysdefs.h" + +S = "${WORKDIR}/glib-${PV}" + +inherit autotools pkgconfig native gettext + +python () { + if bb.data.getVar("USE_NLS", d, 1) == "no": + raise bb.parse.SkipPackage("${PN} requires native language support.") +} + +acpaths = "" +do_configure_prepend () { + install -m 0644 ${WORKDIR}/glibconfig-sysdefs.h . +} + +do_stage () { + install -m 0755 gobject/glib-mkenums ${STAGING_BINDIR}/ + install -m 0755 gobject/.libs/glib-genmarshal ${STAGING_BINDIR}/ + install -m 0755 glib-gettextize ${STAGING_BINDIR}/ + oe_libinstall -so -C glib libglib-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gmodule libgmodule-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gthread libgthread-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gobject libgobject-2.0 ${STAGING_LIBDIR} + autotools_stage_includes + install -d ${STAGING_INCDIR}/glib-2.0/glib + install -m 0755 ${S}/glibconfig.h ${STAGING_INCDIR}/glib-2.0/glibconfig.h + install -d ${STAGING_DATADIR}/aclocal + install -m 0644 ${S}/m4macros/glib-2.0.m4 ${STAGING_DATADIR}/aclocal/glib-2.0.m4 + install -m 0644 ${S}/m4macros/glib-gettext.m4 ${STAGING_DATADIR}/aclocal/glib-gettext.m4 + install -d ${STAGING_DATADIR}/glib-2.0/gettext/po + install -m 0755 mkinstalldirs ${STAGING_DATADIR}/glib-2.0/gettext/ + install -m 0644 po/Makefile.in.in ${STAGING_DATADIR}/glib-2.0/gettext/po/ +} + +do_install () { + : +} + diff --git a/meta/packages/glib-2.0/glib-2.0-native_2.6.5.bb b/meta/packages/glib-2.0/glib-2.0-native_2.6.5.bb new file mode 100644 index 000000000..785261e7c --- /dev/null +++ b/meta/packages/glib-2.0/glib-2.0-native_2.6.5.bb @@ -0,0 +1,49 @@ +DESCRIPTION = "GLib is a general-purpose utility library, \ +which provides many useful data types, macros, \ +type conversions, string utilities, file utilities, a main \ +loop abstraction, and so on. It works on many \ +UNIX-like platforms, Windows, OS/2 and BeOS." +LICENSE = "LGPL" +SECTION = "libs" +PRIORITY = "optional" +MAINTAINER = "Philip Blundell " +DEPENDS = "gtk-doc-native" +PR = "r3" + +EXTRA_OECONF = "--disable-debug" + +SRC_URI = "ftp://ftp.gtk.org/pub/gtk/v2.6/glib-${PV}.tar.bz2 \ + file://glib-gettextize-dir.patch;patch=1 \ + file://glibconfig-sysdefs.h" + +S = "${WORKDIR}/glib-${PV}" + +inherit autotools pkgconfig native gettext + +acpaths = "" +do_configure_prepend () { + install -m 0644 ${WORKDIR}/glibconfig-sysdefs.h . +} + +do_stage () { + install -m 0755 gobject/glib-mkenums ${STAGING_BINDIR}/ + install -m 0755 gobject/.libs/glib-genmarshal ${STAGING_BINDIR}/ + install -m 0755 glib-gettextize ${STAGING_BINDIR}/ + oe_libinstall -so -C glib libglib-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gmodule libgmodule-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gthread libgthread-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gobject libgobject-2.0 ${STAGING_LIBDIR} + autotools_stage_includes + install -d ${STAGING_INCDIR}/glib-2.0/glib + install -m 0755 ${S}/glibconfig.h ${STAGING_INCDIR}/glib-2.0/glibconfig.h + install -d ${STAGING_DATADIR}/aclocal + install -m 0644 ${S}/m4macros/glib-2.0.m4 ${STAGING_DATADIR}/aclocal/glib-2.0.m4 + install -m 0644 ${S}/m4macros/glib-gettext.m4 ${STAGING_DATADIR}/aclocal/glib-gettext.m4 + install -d ${STAGING_DATADIR}/glib-2.0/gettext/po + install -m 0755 mkinstalldirs ${STAGING_DATADIR}/glib-2.0/gettext/ + install -m 0644 po/Makefile.in.in ${STAGING_DATADIR}/glib-2.0/gettext/po/ +} + +do_install () { + : +} diff --git a/meta/packages/glib-2.0/glib-2.0_2.10.3.bb b/meta/packages/glib-2.0/glib-2.0_2.10.3.bb new file mode 100644 index 000000000..df0f3bd82 --- /dev/null +++ b/meta/packages/glib-2.0/glib-2.0_2.10.3.bb @@ -0,0 +1,48 @@ +DESCRIPTION = "GLib is a general-purpose utility library, \ +which provides many useful data types, macros, \ +type conversions, string utilities, file utilities, a main \ +loop abstraction, and so on. It works on many \ +UNIX-like platforms, Windows, OS/2 and BeOS." +LICENSE = "LGPL" +SECTION = "libs" +PRIORITY = "optional" +DEPENDS += "glib-2.0-native gtk-doc" +DEPENDS += "virtual/libiconv virtual/libintl" +PACKAGES =+ "glib-2.0-utils " +PR = "r3" + +LEAD_SONAME = "libglib-2.0.*" +FILES_glib-2.0-utils = "${bindir}/*" + +EXTRA_OECONF = "--disable-debug" + +SRC_URI = "http://download.gnome.org/sources/glib/2.10//glib-${PV}.tar.bz2 \ + file://atomic_fix.patch;patch=1 \ + file://glibconfig-sysdefs.h" + +S = "${WORKDIR}/glib-${PV}" + +inherit autotools pkgconfig gettext + +python () { + if bb.data.getVar("USE_NLS", d, 1) == "no": + raise bb.parse.SkipPackage("${PN} requires native language support.") +} + +acpaths = "" +do_configure_prepend () { + install -m 0644 ${WORKDIR}/glibconfig-sysdefs.h . +} + +do_stage () { + oe_libinstall -so -C glib libglib-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gmodule libgmodule-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gthread libgthread-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gobject libgobject-2.0 ${STAGING_LIBDIR} + autotools_stage_includes + install -d ${STAGING_INCDIR}/glib-2.0/glib + install -m 0755 ${S}/glibconfig.h ${STAGING_INCDIR}/glib-2.0/glibconfig.h + install -d ${STAGING_DATADIR}/aclocal + install -m 0644 ${S}/m4macros/glib-2.0.m4 ${STAGING_DATADIR}/aclocal/glib-2.0.m4 + install -m 0644 ${S}/m4macros/glib-gettext.m4 ${STAGING_DATADIR}/aclocal/glib-gettext.m4 +} diff --git a/meta/packages/glib-2.0/glib-2.0_2.12.0.bb b/meta/packages/glib-2.0/glib-2.0_2.12.0.bb new file mode 100644 index 000000000..31d7347a0 --- /dev/null +++ b/meta/packages/glib-2.0/glib-2.0_2.12.0.bb @@ -0,0 +1,47 @@ +DESCRIPTION = "GLib is a general-purpose utility library, \ +which provides many useful data types, macros, \ +type conversions, string utilities, file utilities, a main \ +loop abstraction, and so on. It works on many \ +UNIX-like platforms, Windows, OS/2 and BeOS." +LICENSE = "LGPL" +SECTION = "libs" +PRIORITY = "optional" +DEPENDS += "glib-2.0-native gtk-doc" +DEPENDS += "virtual/libiconv virtual/libintl" +PACKAGES =+ "glib-2.0-utils " +PR = "r1" + +LEAD_SONAME = "libglib-2.0.*" +FILES_glib-2.0-utils = "${bindir}/*" + +EXTRA_OECONF = "--disable-debug" + +SRC_URI = "http://download.gnome.org/sources/glib/2.12/glib-${PV}.tar.bz2 \ + file://glibconfig-sysdefs.h" + +S = "${WORKDIR}/glib-${PV}" + +inherit autotools pkgconfig gettext + +python () { + if bb.data.getVar("USE_NLS", d, 1) == "no": + raise bb.parse.SkipPackage("${PN} requires native language support.") +} + +acpaths = "" +do_configure_prepend () { + install -m 0644 ${WORKDIR}/glibconfig-sysdefs.h . +} + +do_stage () { + oe_libinstall -so -C glib libglib-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gmodule libgmodule-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gthread libgthread-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gobject libgobject-2.0 ${STAGING_LIBDIR} + autotools_stage_includes + install -d ${STAGING_INCDIR}/glib-2.0/glib + install -m 0755 ${S}/glibconfig.h ${STAGING_INCDIR}/glib-2.0/glibconfig.h + install -d ${STAGING_DATADIR}/aclocal + install -m 0644 ${S}/m4macros/glib-2.0.m4 ${STAGING_DATADIR}/aclocal/glib-2.0.m4 + install -m 0644 ${S}/m4macros/glib-gettext.m4 ${STAGING_DATADIR}/aclocal/glib-gettext.m4 +} diff --git a/meta/packages/glib-2.0/glib-2.0_2.6.4.bb b/meta/packages/glib-2.0/glib-2.0_2.6.4.bb new file mode 100644 index 000000000..2765cc0a6 --- /dev/null +++ b/meta/packages/glib-2.0/glib-2.0_2.6.4.bb @@ -0,0 +1,49 @@ +DESCRIPTION = "GLib is a general-purpose utility library, \ +which provides many useful data types, macros, \ +type conversions, string utilities, file utilities, a main \ +loop abstraction, and so on. It works on many \ +UNIX-like platforms, Windows, OS/2 and BeOS." +LICENSE = "LGPL" +SECTION = "libs" +PRIORITY = "optional" +MAINTAINER = "Philip Blundell " +DEPENDS += "glib-2.0-native gtk-doc" +DEPENDS += "virtual/libiconv virtual/libintl" +PACKAGES =+ "glib-2.0-utils " +PR = "r0" + +LEAD_SONAME = "libglib-2.0.*" +FILES_glib-2.0-utils = "${bindir}/*" + +EXTRA_OECONF = "--disable-debug" + +SRC_URI = "ftp://ftp.gtk.org/pub/gtk/v2.6/glib-${PV}.tar.bz2 \ + file://glibinclude.patch;patch=1;pnum=2 \ + file://glibconfig-sysdefs.h" + +S = "${WORKDIR}/glib-${PV}" + +inherit autotools pkgconfig gettext + +python () { + if bb.data.getVar("USE_NLS", d, 1) == "no": + raise bb.parse.SkipPackage("${PN} requires native language support.") +} + +acpaths = "" +do_configure_prepend () { + install -m 0644 ${WORKDIR}/glibconfig-sysdefs.h . +} + +do_stage () { + oe_libinstall -so -C glib libglib-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gmodule libgmodule-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gthread libgthread-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gobject libgobject-2.0 ${STAGING_LIBDIR} + autotools_stage_includes + install -d ${STAGING_INCDIR}/glib-2.0/glib + install -m 0755 ${S}/glibconfig.h ${STAGING_INCDIR}/glib-2.0/glibconfig.h + install -d ${STAGING_DATADIR}/aclocal + install -m 0644 ${S}/m4macros/glib-2.0.m4 ${STAGING_DATADIR}/aclocal/glib-2.0.m4 + install -m 0644 ${S}/m4macros/glib-gettext.m4 ${STAGING_DATADIR}/aclocal/glib-gettext.m4 +} diff --git a/meta/packages/glib-2.0/glib-2.0_2.8.6.bb b/meta/packages/glib-2.0/glib-2.0_2.8.6.bb new file mode 100644 index 000000000..e0f171ea4 --- /dev/null +++ b/meta/packages/glib-2.0/glib-2.0_2.8.6.bb @@ -0,0 +1,49 @@ +DESCRIPTION = "GLib is a general-purpose utility library, \ +which provides many useful data types, macros, \ +type conversions, string utilities, file utilities, a main \ +loop abstraction, and so on. It works on many \ +UNIX-like platforms, Windows, OS/2 and BeOS." +LICENSE = "LGPL" +SECTION = "libs" +PRIORITY = "optional" +MAINTAINER = "Philip Blundell " +DEPENDS += "glib-2.0-native gtk-doc" +DEPENDS += "virtual/libiconv virtual/libintl" +PACKAGES =+ "glib-2.0-utils " +PR = "r1" + +LEAD_SONAME = "libglib-2.0.*" +FILES_glib-2.0-utils = "${bindir}/*" + +EXTRA_OECONF = "--disable-debug" +# --with-libiconv=gnu" + +SRC_URI = "ftp://ftp.gtk.org/pub/gtk/v2.8/glib-${PV}.tar.bz2 \ + file://glibconfig-sysdefs.h" + +S = "${WORKDIR}/glib-${PV}" + +inherit autotools pkgconfig gettext + +python () { + if bb.data.getVar("USE_NLS", d, 1) == "no": + raise bb.parse.SkipPackage("${PN} requires native language support.") +} + +acpaths = "" +do_configure_prepend () { + install -m 0644 ${WORKDIR}/glibconfig-sysdefs.h . +} + +do_stage () { + oe_libinstall -so -C glib libglib-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gmodule libgmodule-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gthread libgthread-2.0 ${STAGING_LIBDIR} + oe_libinstall -so -C gobject libgobject-2.0 ${STAGING_LIBDIR} + autotools_stage_includes + install -d ${STAGING_INCDIR}/glib-2.0/glib + install -m 0755 ${S}/glibconfig.h ${STAGING_INCDIR}/glib-2.0/glibconfig.h + install -d ${STAGING_DATADIR}/aclocal + install -m 0644 ${S}/m4macros/glib-2.0.m4 ${STAGING_DATADIR}/aclocal/glib-2.0.m4 + install -m 0644 ${S}/m4macros/glib-gettext.m4 ${STAGING_DATADIR}/aclocal/glib-gettext.m4 +} diff --git a/meta/packages/glibc/files/5090_all_stubs-rule-fix.patch b/meta/packages/glibc/files/5090_all_stubs-rule-fix.patch new file mode 100644 index 000000000..c445a5296 --- /dev/null +++ b/meta/packages/glibc/files/5090_all_stubs-rule-fix.patch @@ -0,0 +1,39 @@ +Index: Makerules +=================================================================== +RCS file: /cvs/glibc/libc/Makerules,v +retrieving revision 1.430 +diff -u -r1.430 Makerules +--- libc/Makerules 5 Mar 2005 19:24:32 -0000 1.430 ++++ libc/Makerules 22 Apr 2005 18:31:27 -0000 +@@ -1390,15 +1390,26 @@ + $(addprefix $(objpfx),$(extra-objs)) + $(objpfx)stubs: $(objs-for-stubs) + ifneq (,$(strip $(objs-for-stubs))) +- $(OBJDUMP) -h $^ | \ +- $(AWK) '/\.gnu\.glibc-stub\./ { \ +- sub(/\.gnu\.glibc-stub\./, "", $$2); \ +- stubs[$$2] = 1; } \ +- END { for (s in stubs) print "#define __stub_" s }' > $@T ++ $(stub-obj-list) ++ cat $@L | xargs \ ++ $(OBJDUMP) -h | \ ++ $(AWK) '/\.gnu\.glibc-stub\./ { \ ++ sub(/\.gnu\.glibc-stub\./, "", $$2); \ ++ stubs[$$2] = 1; } \ ++ END { for (s in stubs) print "#define __stub_" s }' \ ++ > $@T ++ -rm -f $@L + mv -f $@T $@ + else + > $@ + endif ++ ++define stub-obj-list ++-@rm -f $@L ++-@echo "Generating stub obj list..." ++$(foreach file,$^, ++@echo >> $@L '$(file)') ++endef + + # This information is not used for making distributions any more. + # But it's used by MakeTAGS for making TAGS files and the .pot files. diff --git a/meta/packages/glibc/files/etc/ld.so.conf b/meta/packages/glibc/files/etc/ld.so.conf new file mode 100644 index 000000000..fb1aab516 --- /dev/null +++ b/meta/packages/glibc/files/etc/ld.so.conf @@ -0,0 +1,3 @@ +/usr/local/lib +/opt/QtPalmtop/lib +/usr/X11R6/lib diff --git a/meta/packages/glibc/files/fhs-linux-paths.patch b/meta/packages/glibc/files/fhs-linux-paths.patch new file mode 100644 index 000000000..1f32f6d7f --- /dev/null +++ b/meta/packages/glibc/files/fhs-linux-paths.patch @@ -0,0 +1,11 @@ +--- glibc-2.1.1/sysdeps/unix/sysv/linux/paths.h~ Thu May 27 13:16:33 1999 ++++ glibc-2.1.1/sysdeps/unix/sysv/linux/paths.h Thu May 27 13:17:55 1999 +@@ -71,7 +71,7 @@ + /* Provide trailing slash, since mostly used for building pathnames. */ + #define _PATH_DEV "/dev/" + #define _PATH_TMP "/tmp/" +-#define _PATH_VARDB "/var/db/" ++#define _PATH_VARDB "/var/lib/misc/" + #define _PATH_VARRUN "/var/run/" + #define _PATH_VARTMP "/var/tmp/" + diff --git a/meta/packages/glibc/files/generate-supported.mk b/meta/packages/glibc/files/generate-supported.mk new file mode 100644 index 000000000..d2a28c2dc --- /dev/null +++ b/meta/packages/glibc/files/generate-supported.mk @@ -0,0 +1,11 @@ +#!/usr/bin/make + +include $(IN) + +all: + rm -f $(OUT) + touch $(OUT) + for locale in $(SUPPORTED-LOCALES); do \ + [ $$locale = true ] && continue; \ + echo $$locale | sed 's,/, ,' >> $(OUT); \ + done diff --git a/meta/packages/glibc/glibc-2.4/arm-longlong.patch b/meta/packages/glibc/glibc-2.4/arm-longlong.patch new file mode 100644 index 000000000..320a55524 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/arm-longlong.patch @@ -0,0 +1,58 @@ +--- glibc-2.4/stdlib/longlong.h.ark 2006-03-11 22:49:27.000000000 +0100 ++++ glibc-2.4/stdlib/longlong.h 2006-03-11 22:55:12.000000000 +0100 +@@ -206,6 +206,14 @@ + "rI" ((USItype) (bh)), \ + "r" ((USItype) (al)), \ + "rI" ((USItype) (bl)) __CLOBBER_CC) ++/* v3m and all higher arches have long multiply support. */ ++#if !defined(__ARM_ARCH_2__) && !defined(__ARM_ARCH_3__) ++#define umul_ppmm(xh, xl, a, b) \ ++ __asm__ ("umull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b)) ++#define UMUL_TIME 5 ++#define smul_ppmm(xh, xl, a, b) \ ++ __asm__ ("smull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b)) ++#else + #define umul_ppmm(xh, xl, a, b) \ + {register USItype __t0, __t1, __t2; \ + __asm__ ("%@ Inlined umul_ppmm\n" \ +@@ -227,7 +235,13 @@ + : "r" ((USItype) (a)), \ + "r" ((USItype) (b)) __CLOBBER_CC );} + #define UMUL_TIME 20 ++#endif + #define UDIV_TIME 100 ++#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__) ++#define count_leading_zeros(COUNT,X) ((COUNT) = __builtin_clz (X)) ++#define COUNT_LEADING_ZEROS_0 32 ++#endif ++ + #endif /* __arm__ */ + + #if defined (__hppa) && W_TYPE_SIZE == 32 +--- glibc-2.4/ports/sysdeps/arm/mp_clz_tab.c.ark 2006-03-11 22:56:43.000000000 +0100 ++++ glibc-2.4/ports/sysdeps/arm/mp_clz_tab.c 2006-03-11 22:58:19.000000000 +0100 +@@ -0,0 +1,24 @@ ++/* __clz_tab -- support for longlong.h ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__) ++/* Nothing required. */ ++#else ++#include ++#endif diff --git a/meta/packages/glibc/glibc-2.4/arm-memcpy.patch b/meta/packages/glibc/glibc-2.4/arm-memcpy.patch new file mode 100644 index 000000000..bc2b3dab8 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/arm-memcpy.patch @@ -0,0 +1,758 @@ +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ sysdeps/arm/memmove.S 2004-03-20 18:37:23.000000000 +0000 +@@ -0,0 +1,251 @@ ++/* ++ * Optimized memmove implementation for ARM processors ++ * ++ * Author: Nicolas Pitre ++ * Created: Dec 23, 2003 ++ * Copyright: (C) MontaVista Software, Inc. ++ * ++ * This file is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Lesser General Public ++ * License as published by the Free Software Foundation; either ++ * version 2.1 of the License, or (at your option) any later version. ++ * ++ * This file is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Lesser General Public License for more details. ++ */ ++ ++#include ++ ++ ++/* ++ * Endian independent macros for shifting bytes within registers. ++ */ ++#ifndef __ARMEB__ ++#define pull lsr ++#define push lsl ++#else ++#define pull lsl ++#define push lsr ++#endif ++ ++/* ++ * Enable data preload for architectures that support it (ARMv5 and above) ++ */ ++#if defined(__ARM_ARCH_5__) || \ ++ defined(__ARM_ARCH_5T__) || \ ++ defined(__ARM_ARCH_5TE__) ++#define PLD(code...) code ++#else ++#define PLD(code...) ++#endif ++ ++ ++/* char * memmove (char *dst, const char *src) */ ++ENTRY(memmove) ++ subs ip, r0, r1 ++ cmphi r2, ip ++ bls memcpy(PLT) ++ ++ stmfd sp!, {r0, r4, lr} ++ add r1, r1, r2 ++ add r0, r0, r2 ++ subs r2, r2, #4 ++ blt 25f ++ ands ip, r0, #3 ++ PLD( pld [r1, #-4] ) ++ bne 26f ++ ands ip, r1, #3 ++ bne 27f ++ ++19: subs r2, r2, #4 ++ blt 24f ++ subs r2, r2, #8 ++ blt 23f ++ subs r2, r2, #16 ++ blt 22f ++ ++ PLD( pld [r1, #-32] ) ++ PLD( subs r2, r2, #96 ) ++ stmfd sp!, {r5 - r8} ++ PLD( blt 21f ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, r1, #31 ) ++ PLD( pld [r1, #-64] ) ++ PLD( beq 20f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #-96] ) ++ PLD( blt 20f ) ++ PLD( cmp ip, #16 ) ++ PLD( sub r2, r2, ip ) ++ PLD( ldmgedb r1!, {r3 - r6} ) ++ PLD( stmgedb r0!, {r3 - r6} ) ++ PLD( beq 20f ) ++ PLD( and ip, ip, #15 ) ++ PLD( cmp ip, #8 ) ++ PLD( ldr r3, [r1, #-4]! ) ++ PLD( ldrge r4, [r1, #-4]! ) ++ PLD( ldrgt r5, [r1, #-4]! ) ++ PLD( str r3, [r0, #-4]! ) ++ PLD( strge r4, [r0, #-4]! ) ++ PLD( strgt r5, [r0, #-4]! ) ++ ++20: PLD( pld [r1, #-96] ) ++ PLD( pld [r1, #-128] ) ++21: ldmdb r1!, {r3, r4, ip, lr} ++ subs r2, r2, #32 ++ stmdb r0!, {r3, r4, ip, lr} ++ ldmdb r1!, {r3, r4, ip, lr} ++ stmgedb r0!, {r3, r4, ip, lr} ++ ldmgedb r1!, {r3, r4, ip, lr} ++ stmgedb r0!, {r3, r4, ip, lr} ++ ldmgedb r1!, {r3, r4, ip, lr} ++ subges r2, r2, #32 ++ stmdb r0!, {r3, r4, ip, lr} ++ bge 20b ++ PLD( cmn r2, #96 ) ++ PLD( bge 21b ) ++ PLD( add r2, r2, #96 ) ++ tst r2, #31 ++ ldmfd sp!, {r5 - r8} ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ tst r2, #16 ++22: ldmnedb r1!, {r3, r4, ip, lr} ++ stmnedb r0!, {r3, r4, ip, lr} ++ ++ tst r2, #8 ++23: ldmnedb r1!, {r3, r4} ++ stmnedb r0!, {r3, r4} ++ ++ tst r2, #4 ++24: ldrne r3, [r1, #-4]! ++ strne r3, [r0, #-4]! ++ ++25: ands r2, r2, #3 ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ cmp r2, #2 ++ ldrb r3, [r1, #-1] ++ ldrgeb r4, [r1, #-2] ++ ldrgtb ip, [r1, #-3] ++ strb r3, [r0, #-1] ++ strgeb r4, [r0, #-2] ++ strgtb ip, [r0, #-3] ++ ldmfd sp!, {r0, r4, pc} ++ ++26: cmp ip, #2 ++ ldrb r3, [r1, #-1]! ++ ldrgeb r4, [r1, #-1]! ++ ldrgtb lr, [r1, #-1]! ++ strb r3, [r0, #-1]! ++ strgeb r4, [r0, #-1]! ++ strgtb lr, [r0, #-1]! ++ subs r2, r2, ip ++ blt 25b ++ ands ip, r1, #3 ++ beq 19b ++ ++27: bic r1, r1, #3 ++ cmp ip, #2 ++ ldr r3, [r1] ++ beq 35f ++ blt 36f ++ ++ ++ .macro backward_copy_shift push pull ++ ++ cmp r2, #12 ++ PLD( pld [r1, #-4] ) ++ blt 33f ++ subs r2, r2, #28 ++ stmfd sp!, {r5 - r9} ++ blt 31f ++ ++ PLD( subs r2, r2, #96 ) ++ PLD( pld [r1, #-32] ) ++ PLD( blt 30f ) ++ PLD( pld [r1, #-64] ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, r1, #31 ) ++ PLD( pld [r1, #-96] ) ++ PLD( beq 29f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #-128] ) ++ PLD( blt 29f ) ++ PLD( sub r2, r2, ip ) ++28: PLD( mov r4, r3, push #\push ) ++ PLD( ldr r3, [r1, #-4]! ) ++ PLD( subs ip, ip, #4 ) ++ PLD( orr r4, r4, r3, pull #\pull ) ++ PLD( str r4, [r0, #-4]! ) ++ PLD( bgt 28b ) ++ ++29: PLD( pld [r1, #-128] ) ++30: mov lr, r3, push #\push ++ ldmdb r1!, {r3 - r9, ip} ++ subs r2, r2, #32 ++ orr lr, lr, ip, pull #\pull ++ mov ip, ip, push #\push ++ orr ip, ip, r9, pull #\pull ++ mov r9, r9, push #\push ++ orr r9, r9, r8, pull #\pull ++ mov r8, r8, push #\push ++ orr r8, r8, r7, pull #\pull ++ mov r7, r7, push #\push ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb r0!, {r4 - r9, ip, lr} ++ bge 29b ++ PLD( cmn r2, #96 ) ++ PLD( bge 30b ) ++ PLD( add r2, r2, #96 ) ++ cmn r2, #16 ++ blt 32f ++31: mov r7, r3, push #\push ++ ldmdb r1!, {r3 - r6} ++ sub r2, r2, #16 ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb r0!, {r4 - r7} ++32: adds r2, r2, #28 ++ ldmfd sp!, {r5 - r9} ++ blt 34f ++33: mov r4, r3, push #\push ++ ldr r3, [r1, #-4]! ++ subs r2, r2, #4 ++ orr r4, r4, r3, pull #\pull ++ str r4, [r0, #-4]! ++ bge 33b ++34: ++ .endm ++ ++ ++ backward_copy_shift push=8 pull=24 ++ add r1, r1, #3 ++ b 25b ++ ++35: backward_copy_shift push=16 pull=16 ++ add r1, r1, #2 ++ b 25b ++ ++36: backward_copy_shift push=24 pull=8 ++ add r1, r1, #1 ++ b 25b ++ ++ .size memmove, . - memmove ++END(memmove) ++libc_hidden_builtin_def (memmove) +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ sysdeps/arm/bcopy.S 2004-03-20 18:37:48.000000000 +0000 +@@ -0,0 +1,255 @@ ++/* ++ * Optimized memmove implementation for ARM processors ++ * ++ * Author: Nicolas Pitre ++ * Created: Dec 23, 2003 ++ * Copyright: (C) MontaVista Software, Inc. ++ * ++ * This file is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Lesser General Public ++ * License as published by the Free Software Foundation; either ++ * version 2.1 of the License, or (at your option) any later version. ++ * ++ * This file is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Lesser General Public License for more details. ++ */ ++ ++#include ++ ++ ++/* ++ * Endian independent macros for shifting bytes within registers. ++ */ ++#ifndef __ARMEB__ ++#define pull lsr ++#define push lsl ++#else ++#define pull lsl ++#define push lsr ++#endif ++ ++/* ++ * Enable data preload for architectures that support it (ARMv5 and above) ++ */ ++#if defined(__ARM_ARCH_5__) || \ ++ defined(__ARM_ARCH_5T__) || \ ++ defined(__ARM_ARCH_5TE__) ++#define PLD(code...) code ++#else ++#define PLD(code...) ++#endif ++ ++dst .req r1 ++src .req r0 ++ ++/* void *bcopy (const char *src, char *dst, size_t size) */ ++ENTRY(bcopy) ++ subs ip, dst, src ++ cmphi r2, ip ++ movls r3, r0 ++ movls r0, r1 ++ movls r1, r3 ++ bls memcpy(PLT) ++ ++ stmfd sp!, {r4, lr} ++ add src, src, r2 ++ add dst, dst, r2 ++ subs r2, r2, #4 ++ blt 25f ++ ands ip, dst, #3 ++ PLD( pld [src, #-4] ) ++ bne 26f ++ ands ip, src, #3 ++ bne 27f ++ ++19: subs r2, r2, #4 ++ blt 24f ++ subs r2, r2, #8 ++ blt 23f ++ subs r2, r2, #16 ++ blt 22f ++ ++ PLD( pld [src, #-32] ) ++ PLD( subs r2, r2, #96 ) ++ stmfd sp!, {r5 - r8} ++ PLD( blt 21f ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, src, #31 ) ++ PLD( pld [src, #-64] ) ++ PLD( beq 20f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [src, #-96] ) ++ PLD( blt 20f ) ++ PLD( cmp ip, #16 ) ++ PLD( sub r2, r2, ip ) ++ PLD( ldmgedb src!, {r3 - r6} ) ++ PLD( stmgedb dst!, {r3 - r6} ) ++ PLD( beq 20f ) ++ PLD( and ip, ip, #15 ) ++ PLD( cmp ip, #8 ) ++ PLD( ldr r3, [src, #-4]! ) ++ PLD( ldrge r4, [src, #-4]! ) ++ PLD( ldrgt r5, [src, #-4]! ) ++ PLD( str r3, [dst, #-4]! ) ++ PLD( strge r4, [dst, #-4]! ) ++ PLD( strgt r5, [dst, #-4]! ) ++ ++20: PLD( pld [src, #-96] ) ++ PLD( pld [src, #-128] ) ++21: ldmdb src!, {r3, r4, ip, lr} ++ subs r2, r2, #32 ++ stmdb dst!, {r3, r4, ip, lr} ++ ldmdb src!, {r3, r4, ip, lr} ++ stmgedb dst!, {r3, r4, ip, lr} ++ ldmgedb src!, {r3, r4, ip, lr} ++ stmgedb dst!, {r3, r4, ip, lr} ++ ldmgedb src!, {r3, r4, ip, lr} ++ subges r2, r2, #32 ++ stmdb dst!, {r3, r4, ip, lr} ++ bge 20b ++ PLD( cmn r2, #96 ) ++ PLD( bge 21b ) ++ PLD( add r2, r2, #96 ) ++ tst r2, #31 ++ ldmfd sp!, {r5 - r8} ++ ldmeqfd sp!, {r4, pc} ++ ++ tst r2, #16 ++22: ldmnedb src!, {r3, r4, ip, lr} ++ stmnedb dst!, {r3, r4, ip, lr} ++ ++ tst r2, #8 ++23: ldmnedb src!, {r3, r4} ++ stmnedb dst!, {r3, r4} ++ ++ tst r2, #4 ++24: ldrne r3, [src, #-4]! ++ strne r3, [dst, #-4]! ++ ++25: ands r2, r2, #3 ++ ldmeqfd sp!, {dst, r4, pc} ++ ++ cmp r2, #2 ++ ldrb r3, [src, #-1] ++ ldrgeb r4, [src, #-2] ++ ldrgtb ip, [src, #-3] ++ strb r3, [dst, #-1] ++ strgeb r4, [dst, #-2] ++ strgtb ip, [dst, #-3] ++ ldmfd sp!, {dst, r4, pc} ++ ++26: cmp ip, #2 ++ ldrb r3, [src, #-1]! ++ ldrgeb r4, [src, #-1]! ++ ldrgtb lr, [src, #-1]! ++ strb r3, [dst, #-1]! ++ strgeb r4, [dst, #-1]! ++ strgtb lr, [dst, #-1]! ++ subs r2, r2, ip ++ blt 25b ++ ands ip, src, #3 ++ beq 19b ++ ++27: bic src, src, #3 ++ cmp ip, #2 ++ ldr r3, [src] ++ beq 35f ++ blt 36f ++ ++ ++ .macro backward_copy_shift push pull ++ ++ cmp r2, #12 ++ PLD( pld [src, #-4] ) ++ blt 33f ++ subs r2, r2, #28 ++ stmfd sp!, {r5 - r9} ++ blt 31f ++ ++ PLD( subs r2, r2, #96 ) ++ PLD( pld [src, #-32] ) ++ PLD( blt 30f ) ++ PLD( pld [src, #-64] ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, src, #31 ) ++ PLD( pld [src, #-96] ) ++ PLD( beq 29f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [src, #-128] ) ++ PLD( blt 29f ) ++ PLD( sub r2, r2, ip ) ++28: PLD( mov r4, r3, push #\push ) ++ PLD( ldr r3, [src, #-4]! ) ++ PLD( subs ip, ip, #4 ) ++ PLD( orr r4, r4, r3, pull #\pull ) ++ PLD( str r4, [dst, #-4]! ) ++ PLD( bgt 28b ) ++ ++29: PLD( pld [src, #-128] ) ++30: mov lr, r3, push #\push ++ ldmdb src!, {r3 - r9, ip} ++ subs r2, r2, #32 ++ orr lr, lr, ip, pull #\pull ++ mov ip, ip, push #\push ++ orr ip, ip, r9, pull #\pull ++ mov r9, r9, push #\push ++ orr r9, r9, r8, pull #\pull ++ mov r8, r8, push #\push ++ orr r8, r8, r7, pull #\pull ++ mov r7, r7, push #\push ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb dst!, {r4 - r9, ip, lr} ++ bge 29b ++ PLD( cmn r2, #96 ) ++ PLD( bge 30b ) ++ PLD( add r2, r2, #96 ) ++ cmn r2, #16 ++ blt 32f ++31: mov r7, r3, push #\push ++ ldmdb src!, {r3 - r6} ++ sub r2, r2, #16 ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb dst!, {r4 - r7} ++32: adds r2, r2, #28 ++ ldmfd sp!, {r5 - r9} ++ blt 34f ++33: mov r4, r3, push #\push ++ ldr r3, [src, #-4]! ++ subs r2, r2, #4 ++ orr r4, r4, r3, pull #\pull ++ str r4, [dst, #-4]! ++ bge 33b ++34: ++ .endm ++ ++ ++ backward_copy_shift push=8 pull=24 ++ add src, src, #3 ++ b 25b ++ ++35: backward_copy_shift push=16 pull=16 ++ add src, src, #2 ++ b 25b ++ ++36: backward_copy_shift push=24 pull=8 ++ add src, src, #1 ++ b 25b ++ ++ .size bcopy, . - bcopy ++END(bcopy) + +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ sysdeps/arm/memcpy.S 2004-05-02 14:33:22.000000000 +0100 +@@ -0,0 +1,242 @@ ++/* ++ * Optimized memcpy implementation for ARM processors ++ * ++ * Author: Nicolas Pitre ++ * Created: Dec 23, 2003 ++ * Copyright: (C) MontaVista Software, Inc. ++ * ++ * This file is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Lesser General Public ++ * License as published by the Free Software Foundation; either ++ * version 2.1 of the License, or (at your option) any later version. ++ * ++ * This file is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Lesser General Public License for more details. ++ */ ++ ++#include ++ ++ ++/* ++ * Endian independent macros for shifting bytes within registers. ++ */ ++#ifndef __ARMEB__ ++#define pull lsr ++#define push lsl ++#else ++#define pull lsl ++#define push lsr ++#endif ++ ++/* ++ * Enable data preload for architectures that support it (ARMv5 and above) ++ */ ++#if defined(__ARM_ARCH_5__) || \ ++ defined(__ARM_ARCH_5T__) || \ ++ defined(__ARM_ARCH_5TE__) ++#define PLD(code...) code ++#else ++#define PLD(code...) ++#endif ++ ++ ++/* char * memcpy (char *dst, const char *src) */ ++ ++ENTRY(memcpy) ++ subs r2, r2, #4 ++ stmfd sp!, {r0, r4, lr} ++ blt 7f ++ ands ip, r0, #3 ++ PLD( pld [r1, #0] ) ++ bne 8f ++ ands ip, r1, #3 ++ bne 9f ++ ++1: subs r2, r2, #4 ++ blt 6f ++ subs r2, r2, #8 ++ blt 5f ++ subs r2, r2, #16 ++ blt 4f ++ ++ PLD( subs r2, r2, #65 ) ++ stmfd sp!, {r5 - r8} ++ PLD( blt 3f ) ++ PLD( pld [r1, #32] ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, r1, #31 ) ++ PLD( pld [r1, #64] ) ++ PLD( beq 2f ) ++ PLD( rsb ip, ip, #32 ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #96] ) ++ PLD( blt 2f ) ++ PLD( cmp ip, #16 ) ++ PLD( sub r2, r2, ip ) ++ PLD( ldmgeia r1!, {r3 - r6} ) ++ PLD( stmgeia r0!, {r3 - r6} ) ++ PLD( beq 2f ) ++ PLD( and ip, ip, #15 ) ++ PLD( cmp ip, #8 ) ++ PLD( ldr r3, [r1], #4 ) ++ PLD( ldrge r4, [r1], #4 ) ++ PLD( ldrgt r5, [r1], #4 ) ++ PLD( str r3, [r0], #4 ) ++ PLD( strge r4, [r0], #4 ) ++ PLD( strgt r5, [r0], #4 ) ++ ++2: PLD( pld [r1, #96] ) ++3: ldmia r1!, {r3 - r8, ip, lr} ++ subs r2, r2, #32 ++ stmia r0!, {r3 - r8, ip, lr} ++ bge 2b ++ PLD( cmn r2, #65 ) ++ PLD( bge 3b ) ++ PLD( add r2, r2, #65 ) ++ tst r2, #31 ++ ldmfd sp!, {r5 - r8} ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ tst r2, #16 ++4: ldmneia r1!, {r3, r4, ip, lr} ++ stmneia r0!, {r3, r4, ip, lr} ++ ++ tst r2, #8 ++5: ldmneia r1!, {r3, r4} ++ stmneia r0!, {r3, r4} ++ ++ tst r2, #4 ++6: ldrne r3, [r1], #4 ++ strne r3, [r0], #4 ++ ++7: ands r2, r2, #3 ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ cmp r2, #2 ++ ldrb r3, [r1], #1 ++ ldrgeb r4, [r1], #1 ++ ldrgtb ip, [r1] ++ strb r3, [r0], #1 ++ strgeb r4, [r0], #1 ++ strgtb ip, [r0] ++ ldmfd sp!, {r0, r4, pc} ++ ++8: rsb ip, ip, #4 ++ cmp ip, #2 ++ ldrb r3, [r1], #1 ++ ldrgeb r4, [r1], #1 ++ ldrgtb lr, [r1], #1 ++ strb r3, [r0], #1 ++ strgeb r4, [r0], #1 ++ strgtb lr, [r0], #1 ++ subs r2, r2, ip ++ blt 7b ++ ands ip, r1, #3 ++ beq 1b ++ ++9: bic r1, r1, #3 ++ cmp ip, #2 ++ ldr lr, [r1], #4 ++ beq 17f ++ bgt 18f ++ ++ ++ .macro forward_copy_shift pull push ++ ++ cmp r2, #12 ++ PLD( pld [r1, #0] ) ++ blt 15f ++ subs r2, r2, #28 ++ stmfd sp!, {r5 - r9} ++ blt 13f ++ ++ PLD( subs r2, r2, #97 ) ++ PLD( blt 12f ) ++ PLD( pld [r1, #32] ) ++ ++ PLD( @ cache alignment ) ++ PLD( rsb ip, r1, #36 ) ++ PLD( pld [r1, #64] ) ++ PLD( ands ip, ip, #31 ) ++ PLD( pld [r1, #96] ) ++ PLD( beq 11f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #128] ) ++ PLD( blt 11f ) ++ PLD( sub r2, r2, ip ) ++10: PLD( mov r3, lr, pull #\pull ) ++ PLD( ldr lr, [r1], #4 ) ++ PLD( subs ip, ip, #4 ) ++ PLD( orr r3, r3, lr, push #\push ) ++ PLD( str r3, [r0], #4 ) ++ PLD( bgt 10b ) ++ ++11: PLD( pld [r1, #128] ) ++12: mov r3, lr, pull #\pull ++ ldmia r1!, {r4 - r9, ip, lr} ++ subs r2, r2, #32 ++ orr r3, r3, r4, push #\push ++ mov r4, r4, pull #\pull ++ orr r4, r4, r5, push #\push ++ mov r5, r5, pull #\pull ++ orr r5, r5, r6, push #\push ++ mov r6, r6, pull #\pull ++ orr r6, r6, r7, push #\push ++ mov r7, r7, pull #\pull ++ orr r7, r7, r8, push #\push ++ mov r8, r8, pull #\pull ++ orr r8, r8, r9, push #\push ++ mov r9, r9, pull #\pull ++ orr r9, r9, ip, push #\push ++ mov ip, ip, pull #\pull ++ orr ip, ip, lr, push #\push ++ stmia r0!, {r3 - r9, ip} ++ bge 11b ++ PLD( cmn r2, #97 ) ++ PLD( bge 12b ) ++ PLD( add r2, r2, #97 ) ++ cmn r2, #16 ++ blt 14f ++13: mov r3, lr, pull #\pull ++ ldmia r1!, {r4 - r6, lr} ++ sub r2, r2, #16 ++ orr r3, r3, r4, push #\push ++ mov r4, r4, pull #\pull ++ orr r4, r4, r5, push #\push ++ mov r5, r5, pull #\pull ++ orr r5, r5, r6, push #\push ++ mov r6, r6, pull #\pull ++ orr r6, r6, lr, push #\push ++ stmia r0!, {r3 - r6} ++14: adds r2, r2, #28 ++ ldmfd sp!, {r5 - r9} ++ blt 16f ++15: mov r3, lr, pull #\pull ++ ldr lr, [r1], #4 ++ subs r2, r2, #4 ++ orr r3, r3, lr, push #\push ++ str r3, [r0], #4 ++ bge 15b ++16: ++ .endm ++ ++ ++ forward_copy_shift pull=8 push=24 ++ sub r1, r1, #3 ++ b 7b ++ ++17: forward_copy_shift pull=16 push=16 ++ sub r1, r1, #2 ++ b 7b ++ ++18: forward_copy_shift pull=24 push=8 ++ sub r1, r1, #1 ++ b 7b ++ ++ .size memcpy, . - memcpy ++END(memcpy) ++libc_hidden_builtin_def (memcpy) ++ diff --git a/meta/packages/glibc/glibc-2.4/dl-cache-libcmp.patch b/meta/packages/glibc/glibc-2.4/dl-cache-libcmp.patch new file mode 100644 index 000000000..2fedfa6db --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/dl-cache-libcmp.patch @@ -0,0 +1,10 @@ +--- glibc-2.4/elf/Versions.ark 2006-03-11 23:30:09.000000000 +0100 ++++ glibc-2.4/elf/Versions 2006-03-11 23:31:44.000000000 +0100 +@@ -63,5 +63,7 @@ + _dl_debug_state; + # Pointer protection. + __pointer_chk_guard; ++ # for ldconfig ++ _dl_cache_libcmp; + } + } diff --git a/meta/packages/glibc/glibc-2.4/dyn-ldconfig-20041128.patch b/meta/packages/glibc/glibc-2.4/dyn-ldconfig-20041128.patch new file mode 100644 index 000000000..451b6d4af --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/dyn-ldconfig-20041128.patch @@ -0,0 +1,22 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- libc/elf/Makefile~dyn-ldconfig-20041128 ++++ libc/elf/Makefile +@@ -118,12 +118,13 @@ + + ifeq (yes,$(use-ldconfig)) + ifeq (yes,$(build-shared)) +-others-static += ldconfig ++#others-static += ldconfig + others += ldconfig + install-rootsbin += ldconfig + + ldconfig-modules := cache readlib xmalloc xstrdup chroot_canon + extra-objs += $(ldconfig-modules:=.o) ++CPPFLAGS-readlib.c = -DNOT_IN_libc=1 + + # To find xmalloc.c and xstrdup.c + vpath %.c ../locale/programs diff --git a/meta/packages/glibc/glibc-2.4/dyn-ldconfig.patch b/meta/packages/glibc/glibc-2.4/dyn-ldconfig.patch new file mode 100644 index 000000000..1041965d0 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/dyn-ldconfig.patch @@ -0,0 +1,62 @@ +--- elf/Makefile 13 Mar 2003 21:50:57 -0000 1.258 ++++ elf/Makefile 27 Mar 2003 20:36:07 -0000 +@@ -109,12 +109,13 @@ + + ifeq (yes,$(use-ldconfig)) + ifeq (yes,$(build-shared)) +-others-static += ldconfig ++#others-static += ldconfig + others += ldconfig + install-rootsbin += ldconfig + + ldconfig-modules := cache readlib xmalloc xstrdup chroot_canon + extra-objs += $(ldconfig-modules:=.o) ++CPPFLAGS-readlib.c = -DNOT_IN_libc=1 + + # To find xmalloc.c and xstrdup.c + vpath %.c ../locale/programs +--- elf/ldconfig.c 13 Jan 2003 08:53:14 -0000 1.31 ++++ elf/ldconfig.c 27 Mar 2003 20:36:09 -0000 +@@ -149,6 +149,9 @@ + static int + is_hwcap_platform (const char *name) + { ++#if 1 ++ return 0; ++#else + int hwcap_idx = _dl_string_hwcap (name); + + if (hwcap_idx != -1 && ((1 << hwcap_idx) & hwcap_mask)) +@@ -164,6 +167,7 @@ + #endif + + return 0; ++#endif + } + + /* Get hwcap (including platform) encoding of path. */ +@@ -175,6 +179,7 @@ + uint64_t hwcap = 0; + uint64_t h; + ++#if 0 + size_t len; + + len = strlen (str); +@@ -210,6 +215,7 @@ + *ptr = '\0'; + } + ++#endif + free (str); + return hwcap; + } +--- elf/Versions.old 2004-06-26 13:18:35.000000000 +0100 ++++ elf/Versions 2004-06-26 14:41:09.000000000 +0100 +@@ -54,5 +54,6 @@ + _dl_get_tls_static_info; _dl_allocate_tls_init; + _dl_tls_setup; _dl_rtld_di_serinfo; + _dl_make_stack_executable; ++ _dl_cache_libcmp; + } + } diff --git a/meta/packages/glibc/glibc-2.4/etc/ld.so.conf b/meta/packages/glibc/glibc-2.4/etc/ld.so.conf new file mode 100644 index 000000000..3f9b41aab --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/etc/ld.so.conf @@ -0,0 +1,3 @@ +/usr/local/lib +/opt/QtPalmtop/lib + diff --git a/meta/packages/glibc/glibc-2.4/fixup-aeabi-syscalls.patch b/meta/packages/glibc/glibc-2.4/fixup-aeabi-syscalls.patch new file mode 100644 index 000000000..fb733b919 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/fixup-aeabi-syscalls.patch @@ -0,0 +1,329 @@ +Fix up ARM EABI for removed syscalls +http://sourceware.org/ml/libc-ports/2006-03/msg00029.html + +Index: glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/socket.S +=================================================================== +--- glibc.orig/ports/sysdeps/unix/sysv/linux/arm/eabi/socket.S 2006-03-21 15:58:10.000000000 -0500 ++++ /dev/null 1970-01-01 00:00:00.000000000 +0000 +@@ -1,131 +0,0 @@ +-/* Copyright (C) 1995, 1996, 1997, 1998, 2003, 2005 +- Free Software Foundation, Inc. +- This file is part of the GNU C Library. +- +- The GNU C Library is free software; you can redistribute it and/or +- modify it under the terms of the GNU Lesser General Public +- License as published by the Free Software Foundation; either +- version 2.1 of the License, or (at your option) any later version. +- +- The GNU C Library is distributed in the hope that it will be useful, +- but WITHOUT ANY WARRANTY; without even the implied warranty of +- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +- Lesser General Public License for more details. +- +- You should have received a copy of the GNU Lesser General Public +- License along with the GNU C Library; if not, write to the Free +- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA +- 02111-1307 USA. */ +- +-#include +-#include +- +-#define P(a, b) P2(a, b) +-#define P2(a, b) a##b +- +- .text +-/* The socket-oriented system calls are handled unusally in Linux. +- They are all gated through the single `socketcall' system call number. +- `socketcall' takes two arguments: the first is the subcode, specifying +- which socket function is being called; and the second is a pointer to +- the arguments to the specific function. +- +- The .S files for the other calls just #define socket and #include this. */ +- +-#ifndef __socket +-# ifndef NO_WEAK_ALIAS +-# define __socket P(__,socket) +-# else +-# define __socket socket +-# endif +-#endif +- +-#define PUSHARGS_1 str a1, [sp, $-8]!; .pad #8 +-#define PUSHARGS_2 stmfd sp!, {a1, a2}; .pad #8 +-#define PUSHARGS_3 stmfd sp!, {a1, a2, a3, a4}; .pad #16 /* a4 pushed for padding */ +-#define PUSHARGS_4 stmfd sp!, {a1, a2, a3, a4}; .pad #16 +-#define PUSHARGS_5 stmfd sp!, {a1, a2, a3, a4}; .pad #16 /* Caller has already pushed arg 5 */ +-#define PUSHARGS_6 stmfd sp!, {a1, a2, a3, a4}; .pad #16 +- +-#define POPARGS_1 add sp, sp, #8 +-#define POPARGS_2 add sp, sp, #8 +-#define POPARGS_3 add sp, sp, #16 +-#define POPARGS_4 add sp, sp, #16 +-#define POPARGS_5 add sp, sp, #16 +-#define POPARGS_6 add sp, sp, #16 +- +-#ifndef NARGS +-#define NARGS 3 /* If we were called with no wrapper, this is really socket() */ +-#endif +- +-#if defined NEED_CANCELLATION && defined CENABLE +- PSEUDO_PROLOGUE +-#endif +- +-.globl __socket +-ENTRY (__socket) +- .fnstart +- +- /* This code previously moved sp into ip and stored the args using +- stmdb ip!, {a1-a4}. It did not modify sp, so the stack never had +- to be restored after the syscall completed. It saved an +- instruction and meant no stack cleanup work was required. +- +- This will not work in the case of a socket call being interrupted +- by a signal. If the signal handler uses any stack the arguments +- to socket will be trashed. The results of a restart of any +- socket call are then unpredictable. */ +- +- /* Push args onto the stack. */ +- P(PUSHARGS_,NARGS) +- +-#if defined NEED_CANCELLATION && defined CENABLE +- SINGLE_THREAD_P +- bne 1f +-#endif +- +- /* Do the system call trap. */ +- mov a1, $P(SOCKOP_,socket) +- mov a2, sp +- DO_CALL (socketcall, 0) +- +- /* Pop args off the stack */ +- P(POPARGS_,NARGS) +- +- /* r0 is < 0 if there was an error. */ +- cmn r0, $124 +- RETINSTR(cc, r14) +- b PLTJMP(SYSCALL_ERROR) +- +-#if defined NEED_CANCELLATION && defined CENABLE +-1: +- stmfd sp!, {r7, lr} +- .save {r7, lr} +- CENABLE +- mov ip, r0 +- +- mov r0, #P(SOCKOP_,socket) +- add r1, sp, #8 +- mov r7, #SYS_ify(socketcall) +- swi 0x0 +- +- mov r7, r0 +- mov r0, ip +- CDISABLE +- mov r0, r7 +- ldmfd sp!, {r7, lr} +- +- P(POPARGS_,NARGS) +- +- /* r0 is < 0 if there was an error. */ +- cmn r0, $124 +- RETINSTR(cc, r14) +- b PLTJMP(SYSCALL_ERROR) +-#endif +- +- .fnend +-PSEUDO_END (__socket) +- +-#ifndef NO_WEAK_ALIAS +-weak_alias (__socket, socket) +-#endif +Index: glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/syscalls.list +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/syscalls.list 2006-03-21 15:58:46.000000000 -0500 +@@ -0,0 +1,34 @@ ++# File name Caller Syscall name # args Strong name Weak names ++ ++# semaphore and shm system calls ++msgctl - msgctl i:iip __msgctl msgctl ++msgget - msgget i:ii __msgget msgget ++msgrcv - msgrcv Ci:ibnii __msgrcv msgrcv ++msgsnd - msgsnd Ci:ibni __msgsnd msgsnd ++shmat - shmat i:ipi __shmat shmat ++shmctl - shmctl i:iip __shmctl shmctl ++shmdt - shmdt i:s __shmdt shmdt ++shmget - shmget i:iii __shmget shmget ++semop - semop i:ipi __semop semop ++semtimedop - semtimedop i:ipip semtimedop ++semget - semget i:iii __semget semget ++semctl - semctl i:iiii __semctl semctl ++ ++# proper socket implementations: ++accept - accept Ci:iBN __libc_accept __accept accept ++bind - bind i:ipi __bind bind ++connect - connect Ci:ipi __libc_connect __connect_internal __connect connect ++getpeername - getpeername i:ipp __getpeername getpeername ++getsockname - getsockname i:ipp __getsockname getsockname ++getsockopt - getsockopt i:iiiBN __getsockopt getsockopt ++listen - listen i:ii __listen listen ++recv - recv Ci:ibni __libc_recv __recv recv ++recvfrom - recvfrom Ci:ibniBN __libc_recvfrom __recvfrom recvfrom ++recvmsg - recvmsg Ci:ipi __libc_recvmsg __recvmsg recvmsg ++send - send Ci:ibni __libc_send __send send ++sendmsg - sendmsg Ci:ipi __libc_sendmsg __sendmsg sendmsg ++sendto - sendto Ci:ibnibn __libc_sendto __sendto sendto ++setsockopt - setsockopt i:iiibn __setsockopt setsockopt ++shutdown - shutdown i:ii __shutdown shutdown ++socket - socket i:iii __socket socket ++socketpair - socketpair i:iiif __socketpair socketpair +Index: glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/linuxthreads/sysdep-cancel.h +=================================================================== +--- glibc.orig/ports/sysdeps/unix/sysv/linux/arm/eabi/linuxthreads/sysdep-cancel.h 2006-03-21 15:58:10.000000000 -0500 ++++ glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/linuxthreads/sysdep-cancel.h 2006-03-21 15:58:46.000000000 -0500 +@@ -53,9 +53,9 @@ + UNDOARGS_##args; \ + cmn r0, $4096; + +-/* DOARGS pushes four bytes on the stack for five arguments, and nothing +- otherwise. In order to preserve doubleword alignment, sometimes we must +- save an extra register. */ ++/* DOARGS pushes four bytes on the stack for five arguments, eight bytes for ++ six arguments, and nothing for fewer. In order to preserve doubleword ++ alignment, sometimes we must save an extra register. */ + + # define DOCARGS_0 stmfd sp!, {r7, lr} + # define UNDOCARGS_0 +@@ -81,6 +81,10 @@ + # define UNDOCARGS_5 ldmfd sp!, {r0, r1, r2, r3} + # define RESTORE_LR_5 ldmfd sp!, {r4, r7, lr} + ++# define DOCARGS_6 stmfd sp!, {r0, r1, r2, r3, r7, lr} ++# define UNDOCARGS_6 ldmfd sp!, {r0, r1, r2, r3} ++# define RESTORE_LR_6 RESTORE_LR_0 ++ + # ifdef IS_IN_libpthread + # define CENABLE bl PLTJMP(__pthread_enable_asynccancel) + # define CDISABLE bl PLTJMP(__pthread_disable_asynccancel) +Index: glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/nptl/sysdep-cancel.h +=================================================================== +--- glibc.orig/ports/sysdeps/unix/sysv/linux/arm/eabi/nptl/sysdep-cancel.h 2006-03-21 15:58:10.000000000 -0500 ++++ glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/nptl/sysdep-cancel.h 2006-03-21 15:58:46.000000000 -0500 +@@ -64,9 +64,9 @@ + UNDOARGS_##args; \ + cmn r0, $4096; + +-/* DOARGS pushes four bytes on the stack for five arguments, and nothing +- otherwise. In order to preserve doubleword alignment, sometimes we must +- save an extra register. */ ++/* DOARGS pushes four bytes on the stack for five arguments, eight bytes for ++ six arguments, and nothing for fewer. In order to preserve doubleword ++ alignment, sometimes we must save an extra register. */ + + # define RESTART_UNWIND .fnend; .fnstart; .save {r7, lr} + +@@ -94,6 +94,10 @@ + # define UNDOCARGS_5 ldmfd sp!, {r0, r1, r2, r3}; .fnend; .fnstart; .save {r4}; .save {r7, lr}; .pad #4 + # define RESTORE_LR_5 ldmfd sp!, {r4, r7, lr} + ++# define DOCARGS_6 .save {r4, r5}; stmfd sp!, {r0, r1, r2, r3, r7, lr}; .save {r7, lr}; .pad #20 ++# define UNDOCARGS_6 ldmfd sp!, {r0, r1, r2, r3}; .fnend; .fnstart; .save {r4, r5}; .save {r7, lr} ++# define RESTORE_LR_6 RESTORE_LR_0 ++ + # ifdef IS_IN_libpthread + # define CENABLE bl PLTJMP(__pthread_enable_asynccancel) + # define CDISABLE bl PLTJMP(__pthread_disable_asynccancel) +Index: glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/sysdep.h +=================================================================== +--- glibc.orig/ports/sysdeps/unix/sysv/linux/arm/eabi/sysdep.h 2006-03-21 15:58:10.000000000 -0500 ++++ glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/sysdep.h 2006-03-21 15:58:46.000000000 -0500 +@@ -1,4 +1,4 @@ +-/* Copyright (C) 2005 ++/* Copyright (C) 2005, 2006 + Free Software Foundation, Inc. + + This file is part of the GNU C Library. +@@ -29,6 +29,12 @@ + # error Kernel headers are too old + #endif + ++/* Don't use stime, even if the kernel headers define it. We have ++ settimeofday, and some EABI kernels have removed stime. Similarly ++ use setitimer to implement alarm. */ ++#undef __NR_stime ++#undef __NR_alarm ++ + /* The ARM EABI user interface passes the syscall number in r7, instead + of in the swi. This is more efficient, because the kernel does not need + to fetch the swi from memory to find out the number; which can be painful +Index: glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/umount.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/ports/sysdeps/unix/sysv/linux/arm/eabi/umount.c 2006-03-21 15:58:46.000000000 -0500 +@@ -0,0 +1,31 @@ ++/* Copyright (C) 2000, 2001 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ Contributed by David Huggins-Daines , 2000. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++/* Since we don't have an oldumount system call, do what the kernel ++ does down here. */ ++ ++extern long int __umount2 (const char *name, int flags); ++ ++long int ++__umount (const char *name) ++{ ++ return __umount2 (name, 0); ++} ++ ++weak_alias (__umount, umount); +Index: glibc/ports/sysdeps/unix/sysv/linux/arm/kernel-features.h +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/ports/sysdeps/unix/sysv/linux/arm/kernel-features.h 2006-03-20 17:26:58.000000000 -0500 +@@ -0,0 +1,31 @@ ++/* Set flags signalling availability of kernel features based on given ++ kernel version number. ++ Copyright (C) 2006 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++/* The utimes syscall was added before 2.6.1. */ ++#if __LINUX_KERNEL_VERSION >= 132609 ++# define __ASSUME_UTIMES 1 ++#endif ++ ++/* The new getrlimit syscall was added sometime before 2.4.6. */ ++#if __LINUX_KERNEL_VERSION >= 132102 ++#define __ASSUME_NEW_GETRLIMIT_SYSCALL 1 ++#endif ++ ++#include_next diff --git a/meta/packages/glibc/glibc-2.4/generic-bits_select.h b/meta/packages/glibc/glibc-2.4/generic-bits_select.h new file mode 100644 index 000000000..47e7dedc3 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/generic-bits_select.h @@ -0,0 +1,35 @@ +/* Copyright (C) 1997, 1998, 2001 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, write to the Free + Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA + 02111-1307 USA. */ + +#ifndef _SYS_SELECT_H +# error "Never use directly; include instead." +#endif + + +/* We don't use `memset' because this would require a prototype and + the array isn't too big. */ +#define __FD_ZERO(s) \ + do { \ + unsigned int __i; \ + fd_set *__arr = (s); \ + for (__i = 0; __i < sizeof (fd_set) / sizeof (__fd_mask); ++__i) \ + __FDS_BITS (__arr)[__i] = 0; \ + } while (0) +#define __FD_SET(d, s) (__FDS_BITS (s)[__FDELT(d)] |= __FDMASK(d)) +#define __FD_CLR(d, s) (__FDS_BITS (s)[__FDELT(d)] &= ~__FDMASK(d)) +#define __FD_ISSET(d, s) ((__FDS_BITS (s)[__FDELT(d)] & __FDMASK(d)) != 0) diff --git a/meta/packages/glibc/glibc-2.4/generic-bits_time.h b/meta/packages/glibc/glibc-2.4/generic-bits_time.h new file mode 100644 index 000000000..b3184d1de --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/generic-bits_time.h @@ -0,0 +1,75 @@ +/* System-dependent timing definitions. Generic version. + Copyright (C) 1996,1997,1999-2002,2003 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, write to the Free + Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA + 02111-1307 USA. */ + +/* + * Never include this file directly; use instead. + */ + +#ifndef __need_timeval +# ifndef _BITS_TIME_H +# define _BITS_TIME_H 1 + +/* ISO/IEC 9899:1990 7.12.1: + The macro `CLOCKS_PER_SEC' is the number per second of the value + returned by the `clock' function. */ +/* CAE XSH, Issue 4, Version 2: + The value of CLOCKS_PER_SEC is required to be 1 million on all + XSI-conformant systems. */ +# define CLOCKS_PER_SEC 1000000l + +# if !defined __STRICT_ANSI__ && !defined __USE_XOPEN2K +/* Even though CLOCKS_PER_SEC has such a strange value CLK_TCK + presents the real value for clock ticks per second for the system. */ +# include +extern long int __sysconf (int); +# define CLK_TCK ((__clock_t) __sysconf (2)) /* 2 is _SC_CLK_TCK */ +# endif + +# ifdef __USE_POSIX199309 +/* Identifier for system-wide realtime clock. */ +# define CLOCK_REALTIME 0 +/* Monotonic system-wide clock. */ +# define CLOCK_MONOTONIC 1 +/* High-resolution timer from the CPU. */ +# define CLOCK_PROCESS_CPUTIME_ID 2 +/* Thread-specific CPU-time clock. */ +# define CLOCK_THREAD_CPUTIME_ID 3 + +/* Flag to indicate time is absolute. */ +# define TIMER_ABSTIME 1 +# endif + +# endif /* bits/time.h */ +#endif + +#ifdef __need_timeval +# undef __need_timeval +# ifndef _STRUCT_TIMEVAL +# define _STRUCT_TIMEVAL 1 +# include + +/* A time value that is accurate to the nearest + microsecond but also has a range of years. */ +struct timeval + { + __time_t tv_sec; /* Seconds. */ + __suseconds_t tv_usec; /* Microseconds. */ + }; +# endif /* struct timeval */ +#endif /* need timeval */ diff --git a/meta/packages/glibc/glibc-2.4/generic-bits_types.h b/meta/packages/glibc/glibc-2.4/generic-bits_types.h new file mode 100644 index 000000000..65c8a9fe9 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/generic-bits_types.h @@ -0,0 +1,200 @@ +/* bits/types.h -- definitions of __*_t types underlying *_t types. + Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, write to the Free + Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA + 02111-1307 USA. */ + +/* + * Never include this file directly; use instead. + */ + +#ifndef _BITS_TYPES_H +#define _BITS_TYPES_H 1 + +#include +#include + +#define __need_size_t +#include + +/* Convenience types. */ +typedef unsigned char __u_char; +typedef unsigned short int __u_short; +typedef unsigned int __u_int; +typedef unsigned long int __u_long; + +/* Fixed-size types, underlying types depend on word size and compiler. */ +typedef signed char __int8_t; +typedef unsigned char __uint8_t; +typedef signed short int __int16_t; +typedef unsigned short int __uint16_t; +typedef signed int __int32_t; +typedef unsigned int __uint32_t; +#if __WORDSIZE == 64 +typedef signed long int __int64_t; +typedef unsigned long int __uint64_t; +#elif defined __GLIBC_HAVE_LONG_LONG +__extension__ typedef signed long long int __int64_t; +__extension__ typedef unsigned long long int __uint64_t; +#endif + +/* quad_t is also 64 bits. */ +#if __WORDSIZE == 64 +typedef long int __quad_t; +typedef unsigned long int __u_quad_t; +#elif defined __GLIBC_HAVE_LONG_LONG +__extension__ typedef long long int __quad_t; +__extension__ typedef unsigned long long int __u_quad_t; +#else +typedef struct +{ + long __val[2]; +} __quad_t; +typedef struct +{ + __u_long __val[2]; +} __u_quad_t; +#endif + + +/* The machine-dependent file defines __*_T_TYPE + macros for each of the OS types we define below. The definitions + of those macros must use the following macros for underlying types. + We define __S_TYPE and __U_TYPE for the signed and unsigned + variants of each of the following integer types on this machine. + + 16 -- "natural" 16-bit type (always short) + 32 -- "natural" 32-bit type (always int) + 64 -- "natural" 64-bit type (long or long long) + LONG32 -- 32-bit type, traditionally long + QUAD -- 64-bit type, always long long + WORD -- natural type of __WORDSIZE bits (int or long) + LONGWORD -- type of __WORDSIZE bits, traditionally long + + We distinguish WORD/LONGWORD, 32/LONG32, and 64/QUAD so that the + conventional uses of `long' or `long long' type modifiers match the + types we define, even when a less-adorned type would be the same size. + This matters for (somewhat) portably writing printf/scanf formats for + these types, where using the appropriate l or ll format modifiers can + make the typedefs and the formats match up across all GNU platforms. If + we used `long' when it's 64 bits where `long long' is expected, then the + compiler would warn about the formats not matching the argument types, + and the programmer changing them to shut up the compiler would break the + program's portability. + + Here we assume what is presently the case in all the GCC configurations + we support: long long is always 64 bits, long is always word/address size, + and int is always 32 bits. */ + +#define __S16_TYPE short int +#define __U16_TYPE unsigned short int +#define __S32_TYPE int +#define __U32_TYPE unsigned int +#define __SLONGWORD_TYPE long int +#define __ULONGWORD_TYPE unsigned long int +#if __WORDSIZE == 32 +# define __SQUAD_TYPE __quad_t +# define __UQUAD_TYPE __u_quad_t +# define __SWORD_TYPE int +# define __UWORD_TYPE unsigned int +# define __SLONG32_TYPE long int +# define __ULONG32_TYPE unsigned long int +# define __S64_TYPE __quad_t +# define __U64_TYPE __u_quad_t +/* We want __extension__ before typedef's that use nonstandard base types + such as `long long' in C89 mode. */ +# define __STD_TYPE __extension__ typedef +#elif __WORDSIZE == 64 +# define __SQUAD_TYPE long int +# define __UQUAD_TYPE unsigned long int +# define __SWORD_TYPE long int +# define __UWORD_TYPE unsigned long int +# define __SLONG32_TYPE int +# define __ULONG32_TYPE unsigned int +# define __S64_TYPE long int +# define __U64_TYPE unsigned long int +/* No need to mark the typedef with __extension__. */ +# define __STD_TYPE typedef +#else +# error +#endif +#include /* Defines __*_T_TYPE macros. */ + + +__STD_TYPE __DEV_T_TYPE __dev_t; /* Type of device numbers. */ +__STD_TYPE __UID_T_TYPE __uid_t; /* Type of user identifications. */ +__STD_TYPE __GID_T_TYPE __gid_t; /* Type of group identifications. */ +__STD_TYPE __INO_T_TYPE __ino_t; /* Type of file serial numbers. */ +__STD_TYPE __INO64_T_TYPE __ino64_t; /* Type of file serial numbers (LFS).*/ +__STD_TYPE __MODE_T_TYPE __mode_t; /* Type of file attribute bitmasks. */ +__STD_TYPE __NLINK_T_TYPE __nlink_t; /* Type of file link counts. */ +__STD_TYPE __OFF_T_TYPE __off_t; /* Type of file sizes and offsets. */ +__STD_TYPE __OFF64_T_TYPE __off64_t; /* Type of file sizes and offsets (LFS). */ +__STD_TYPE __PID_T_TYPE __pid_t; /* Type of process identifications. */ +__STD_TYPE __FSID_T_TYPE __fsid_t; /* Type of file system IDs. */ +__STD_TYPE __CLOCK_T_TYPE __clock_t; /* Type of CPU usage counts. */ +__STD_TYPE __RLIM_T_TYPE __rlim_t; /* Type for resource measurement. */ +__STD_TYPE __RLIM64_T_TYPE __rlim64_t; /* Type for resource measurement (LFS). */ +__STD_TYPE __ID_T_TYPE __id_t; /* General type for IDs. */ +__STD_TYPE __TIME_T_TYPE __time_t; /* Seconds since the Epoch. */ +__STD_TYPE __USECONDS_T_TYPE __useconds_t; /* Count of microseconds. */ +__STD_TYPE __SUSECONDS_T_TYPE __suseconds_t; /* Signed count of microseconds. */ + +__STD_TYPE __DADDR_T_TYPE __daddr_t; /* The type of a disk address. */ +__STD_TYPE __SWBLK_T_TYPE __swblk_t; /* Type of a swap block maybe? */ +__STD_TYPE __KEY_T_TYPE __key_t; /* Type of an IPC key. */ + +/* Clock ID used in clock and timer functions. */ +__STD_TYPE __CLOCKID_T_TYPE __clockid_t; + +/* Timer ID returned by `timer_create'. */ +__STD_TYPE __TIMER_T_TYPE __timer_t; + +/* Type to represent block size. */ +__STD_TYPE __BLKSIZE_T_TYPE __blksize_t; + +/* Types from the Large File Support interface. */ + +/* Type to count number of disk blocks. */ +__STD_TYPE __BLKCNT_T_TYPE __blkcnt_t; +__STD_TYPE __BLKCNT64_T_TYPE __blkcnt64_t; + +/* Type to count file system blocks. */ +__STD_TYPE __FSBLKCNT_T_TYPE __fsblkcnt_t; +__STD_TYPE __FSBLKCNT64_T_TYPE __fsblkcnt64_t; + +/* Type to count file system nodes. */ +__STD_TYPE __FSFILCNT_T_TYPE __fsfilcnt_t; +__STD_TYPE __FSFILCNT64_T_TYPE __fsfilcnt64_t; + +__STD_TYPE __SSIZE_T_TYPE __ssize_t; /* Type of a byte count, or error. */ + +/* These few don't really vary by system, they always correspond + to one of the other defined types. */ +typedef __off64_t __loff_t; /* Type of file sizes and offsets (LFS). */ +typedef __quad_t *__qaddr_t; +typedef char *__caddr_t; + +/* Duplicates info from stdint.h but this is used in unistd.h. */ +__STD_TYPE __SWORD_TYPE __intptr_t; + +/* Duplicate info from sys/socket.h. */ +__STD_TYPE __U32_TYPE __socklen_t; + + +#undef __STD_TYPE + +#endif /* bits/types.h */ diff --git a/meta/packages/glibc/glibc-2.4/generic-bits_typesizes.h b/meta/packages/glibc/glibc-2.4/generic-bits_typesizes.h new file mode 100644 index 000000000..e9226c417 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/generic-bits_typesizes.h @@ -0,0 +1,66 @@ +/* bits/typesizes.h -- underlying types for *_t. Generic version. + Copyright (C) 2002, 2003 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, write to the Free + Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA + 02111-1307 USA. */ + +#ifndef _BITS_TYPES_H +# error "Never include directly; use instead." +#endif + +#ifndef _BITS_TYPESIZES_H +#define _BITS_TYPESIZES_H 1 + +/* See for the meaning of these macros. This file exists so + that need not vary across different GNU platforms. */ + +#define __DEV_T_TYPE __UQUAD_TYPE +#define __UID_T_TYPE __U32_TYPE +#define __GID_T_TYPE __U32_TYPE +#define __INO_T_TYPE __ULONGWORD_TYPE +#define __INO64_T_TYPE __UQUAD_TYPE +#define __MODE_T_TYPE __U32_TYPE +#define __NLINK_T_TYPE __UWORD_TYPE +#define __OFF_T_TYPE __SLONGWORD_TYPE +#define __OFF64_T_TYPE __SQUAD_TYPE +#define __PID_T_TYPE __S32_TYPE +#define __RLIM_T_TYPE __ULONGWORD_TYPE +#define __RLIM64_T_TYPE __UQUAD_TYPE +#define __BLKCNT_T_TYPE __SLONGWORD_TYPE +#define __BLKCNT64_T_TYPE __SQUAD_TYPE +#define __FSBLKCNT_T_TYPE __ULONGWORD_TYPE +#define __FSBLKCNT64_T_TYPE __UQUAD_TYPE +#define __FSFILCNT_T_TYPE __ULONGWORD_TYPE +#define __FSFILCNT64_T_TYPE __UQUAD_TYPE +#define __ID_T_TYPE __U32_TYPE +#define __CLOCK_T_TYPE __SLONGWORD_TYPE +#define __TIME_T_TYPE __SLONGWORD_TYPE +#define __USECONDS_T_TYPE __U32_TYPE +#define __SUSECONDS_T_TYPE __SLONGWORD_TYPE +#define __DADDR_T_TYPE __S32_TYPE +#define __SWBLK_T_TYPE __SLONGWORD_TYPE +#define __KEY_T_TYPE __S32_TYPE +#define __CLOCKID_T_TYPE __S32_TYPE +#define __TIMER_T_TYPE void * +#define __BLKSIZE_T_TYPE __SLONGWORD_TYPE +#define __FSID_T_TYPE struct { int __val[2]; } +#define __SSIZE_T_TYPE __SWORD_TYPE + +/* Number of descriptors that can fit in an `fd_set'. */ +#define __FD_SETSIZE 1024 + + +#endif /* bits/typesizes.h */ diff --git a/meta/packages/glibc/glibc-2.4/glibc-2.4-compile.patch b/meta/packages/glibc/glibc-2.4/glibc-2.4-compile.patch new file mode 100644 index 000000000..ea9f55ae7 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/glibc-2.4-compile.patch @@ -0,0 +1,29 @@ +--- glibc-2.4/csu/libc-start.c.ark 2006-03-13 03:07:15.000000000 +0100 ++++ glibc-2.4/csu/libc-start.c 2006-03-13 03:08:51.000000000 +0100 +@@ -59,6 +59,11 @@ + # define LIBC_START_MAIN BP_SYM (__libc_start_main) + #endif + ++#ifdef SHARED ++#include ++extern struct pthread_functions __libc_pthread_functions; ++#endif ++ + #ifdef MAIN_AUXVEC_ARG + /* main gets passed a pointer to the auxiliary. */ + # define MAIN_AUXVEC_DECL , void * +--- glibc-2.4/nscd/Makefile.ark 2006-03-13 14:05:47.000000000 +0100 ++++ glibc-2.4/nscd/Makefile 2006-03-13 14:06:12.000000000 +0100 +@@ -67,8 +67,10 @@ + # contains only the basic kernel interface headers, not something like + # libselinux. So the simplest thing is to presume that the standard + # system headers will be ok for this file. +-$(objpfx)nscd_stat.o: sysincludes = # nothing +-$(objpfx)selinux.o: sysincludes = # nothing ++# Except, of course, this breaks crosscompiling with kernel headers in ++# a nonstandard location... ++#$(objpfx)nscd_stat.o: sysincludes = # nothing ++#$(objpfx)selinux.o: sysincludes = # nothing + + distribute := nscd.h nscd-client.h dbg_log.h \ + $(addsuffix .c, $(filter-out xmalloc,$(all-nscd-modules))) \ diff --git a/meta/packages/glibc/glibc-2.4/ldsocache-varrun.patch b/meta/packages/glibc/glibc-2.4/ldsocache-varrun.patch new file mode 100644 index 000000000..9994d4f87 --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/ldsocache-varrun.patch @@ -0,0 +1,18 @@ +This patch moves ld.so.cache from /etc to /var/run. This is for devices +where /etc is JFFS2 or CRAMFS but /var is a ramdisk. + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- libc/sysdeps/generic/dl-cache.h~ldsocache-varrun ++++ libc/sysdeps/generic/dl-cache.h +@@ -29,7 +29,7 @@ + #endif + + #ifndef LD_SO_CACHE +-# define LD_SO_CACHE SYSCONFDIR "/ld.so.cache" ++# define LD_SO_CACHE "/var/run/ld.so.cache" + #endif + + #ifndef add_system_dir diff --git a/meta/packages/glibc/glibc-2.4/nptl-crosscompile.patch b/meta/packages/glibc/glibc-2.4/nptl-crosscompile.patch new file mode 100644 index 000000000..18a46ad4f --- /dev/null +++ b/meta/packages/glibc/glibc-2.4/nptl-crosscompile.patch @@ -0,0 +1,26 @@ +--- glibc-2.4/nptl/sysdeps/pthread/configure.in.ark 2006-03-12 00:41:40.000000000 +0100 ++++ glibc-2.4/nptl/sysdeps/pthread/configure.in 2006-03-12 00:44:08.000000000 +0100 +@@ -45,5 +45,6 @@ + AC_MSG_ERROR([the compiler must support C cleanup handling]) + fi + else +- AC_MSG_ERROR(forced unwind support is required) ++ AC_MSG_WARN([forced unwind support is required, can't be verified while crosscompiling]) ++ AC_DEFINE(HAVE_FORCED_UNWIND) + fi +--- glibc-2.4/nptl/sysdeps/pthread/configure.ark 2006-03-12 00:42:47.000000000 +0100 ++++ glibc-2.4/nptl/sysdeps/pthread/configure 2006-03-12 00:44:08.000000000 +0100 +@@ -153,7 +153,10 @@ + { (exit 1); exit 1; }; } + fi + else +- { { echo "$as_me:$LINENO: error: forced unwind support is required" >&5 +-echo "$as_me: error: forced unwind support is required" >&2;} +- { (exit 1); exit 1; }; } ++ { echo "$as_me:$LINENO: WARNING: forced unwind support is required, can't be verified while crosscompiling" >&5 ++echo "$as_me: WARNING: forced unwind support is required, can't be verified while crosscompiling" >&2;} ++ cat >>confdefs.h <<\_ACEOF ++#define HAVE_FORCED_UNWIND 1 ++_ACEOF ++ + fi diff --git a/meta/packages/glibc/glibc-cvs-2.3.5/arm-audit.patch b/meta/packages/glibc/glibc-cvs-2.3.5/arm-audit.patch new file mode 100644 index 000000000..2404f755e --- /dev/null +++ b/meta/packages/glibc/glibc-cvs-2.3.5/arm-audit.patch @@ -0,0 +1,58 @@ +2005-05-09 Daniel Jacobowitz + Mark Mitchell + + * sysdeps/generic/ldsodefs.h (struct audit_ifaces): Add ARM entries. + * elf/tst-auditmod1.c: Add ARM definitions. + +Index: glibc/sysdeps/generic/ldsodefs.h +=================================================================== +--- glibc.orig/sysdeps/generic/ldsodefs.h 2005-04-05 17:36:52.000000000 -0400 ++++ glibc/sysdeps/generic/ldsodefs.h 2005-05-06 15:54:44.000000000 -0400 +@@ -203,6 +203,8 @@ struct La_sparc32_regs; + struct La_sparc32_retval; + struct La_sparc64_regs; + struct La_sparc64_retval; ++struct La_arm_regs; ++struct La_arm_retval; + + struct audit_ifaces + { +@@ -284,6 +286,10 @@ struct audit_ifaces + const struct La_sparc64_regs *, + unsigned int *, const char *name, + long int *framesizep); ++ Elf32_Addr (*arm_gnu_pltenter) (Elf32_Sym *, unsigned int, uintptr_t *, ++ uintptr_t *, struct La_arm_regs *, ++ unsigned int *, const char *name, ++ long int *framesizep); + }; + union + { +@@ -352,6 +358,9 @@ struct audit_ifaces + const struct La_sparc32_regs *, + struct La_sparc32_retval *, + const char *); ++ unsigned int (*arm_gnu_pltexit) (Elf32_Sym *, unsigned int, uintptr_t *, ++ uintptr_t *, const struct La_arm_regs *, ++ struct La_arm_retval *, const char *); + }; + unsigned int (*objclose) (uintptr_t *); + +Index: glibc/elf/tst-auditmod1.c +=================================================================== +--- glibc.orig/elf/tst-auditmod1.c 2005-04-05 17:36:53.000000000 -0400 ++++ glibc/elf/tst-auditmod1.c 2005-05-06 15:53:28.000000000 -0400 +@@ -192,6 +192,12 @@ la_symbind64 (Elf64_Sym *sym, unsigned i + # define La_regs La_sparc64_regs + # define La_retval La_sparc64_retval + # define int_retval lrv_reg[0] ++#elif __arm__ ++# define pltenter la_arm_gnu_pltenter ++# define pltext la_arm_gnu_pltexit ++# define La_regs La_arm_regs ++# define La_retval La_arm_retval ++# define int_retval lrv_reg[0] + #else + # error "architecture specific code needed" + #endif + diff --git a/meta/packages/glibc/glibc-cvs-2.3.5/arm-audit2.patch b/meta/packages/glibc/glibc-cvs-2.3.5/arm-audit2.patch new file mode 100644 index 000000000..855632c53 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs-2.3.5/arm-audit2.patch @@ -0,0 +1,18 @@ +Index: ports/sysdeps/arm/dl-machine.h +=================================================================== +RCS file: /cvs/glibc/ports/sysdeps/arm/dl-machine.h,v +retrieving revision 1.53 +diff -u -r1.53 dl-machine.h +--- libc/ports/sysdeps/arm/dl-machine.h 10 Jun 2005 11:33:52 -0000 1.53 ++++ libc/ports/sysdeps/arm/dl-machine.h 11 Jun 2005 08:58:04 -0000 +@@ -243,6 +243,10 @@ + Prelinked libraries may use Elf32_Rela though. */ + #define ELF_MACHINE_NO_RELA defined RTLD_BOOTSTRAP + ++/* Names of the architecture-specific auditing callback functions. */ ++#define ARCH_LA_PLTENTER arm_gnu_pltenter ++#define ARCH_LA_PLTEXIT arm_gnu_pltexit ++ + #ifdef RESOLVE_MAP + + /* Deal with an out-of-range PC24 reloc. */ diff --git a/meta/packages/glibc/glibc-cvs-2.3.5/arm-longlong.patch b/meta/packages/glibc/glibc-cvs-2.3.5/arm-longlong.patch new file mode 100644 index 000000000..a0b2ed003 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs-2.3.5/arm-longlong.patch @@ -0,0 +1,59 @@ +--- stdlib/longlong.h~ 2002-09-29 18:45:58.000000000 +0100 ++++ stdlib/longlong.h 2004-03-20 19:16:44.000000000 +0000 +@@ -210,6 +210,14 @@ + "rI" ((USItype) (bh)), \ + "r" ((USItype) (al)), \ + "rI" ((USItype) (bl))) ++/* v3m and all higher arches have long multiply support. */ ++#if !defined(__ARM_ARCH_2__) && !defined(__ARM_ARCH_3__) ++#define umul_ppmm(xh, xl, a, b) \ ++ __asm__ ("umull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b)) ++#define UMUL_TIME 5 ++#define smul_ppmm(xh, xl, a, b) \ ++ __asm__ ("smull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b)) ++#else + #define umul_ppmm(xh, xl, a, b) \ + {register USItype __t0, __t1, __t2; \ + __asm__ ("%@ Inlined umul_ppmm\n" \ +@@ -231,7 +239,14 @@ + : "r" ((USItype) (a)), \ + "r" ((USItype) (b)));} + #define UMUL_TIME 20 ++#endif + #define UDIV_TIME 100 ++ ++#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__) ++#define count_leading_zeros(COUNT,X) ((COUNT) = __builtin_clz (X)) ++#define COUNT_LEADING_ZEROS_0 32 ++#endif ++ + #endif /* __arm__ */ + + #if defined (__hppa) && W_TYPE_SIZE == 32 +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ ports/sysdeps/arm/mp_clz_tab.c 2004-03-20 19:24:26.000000000 +0000 +@@ -0,0 +1,24 @@ ++/* __clz_tab -- support for longlong.h ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__) ++/* Nothing required. */ ++#else ++#include ++#endif diff --git a/meta/packages/glibc/glibc-cvs-2.3.5/arm-memcpy.patch b/meta/packages/glibc/glibc-cvs-2.3.5/arm-memcpy.patch new file mode 100644 index 000000000..db1120058 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs-2.3.5/arm-memcpy.patch @@ -0,0 +1,758 @@ +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ libc/ports/sysdeps/arm/memmove.S 2004-03-20 18:37:23.000000000 +0000 +@@ -0,0 +1,251 @@ ++/* ++ * Optimized memmove implementation for ARM processors ++ * ++ * Author: Nicolas Pitre ++ * Created: Dec 23, 2003 ++ * Copyright: (C) MontaVista Software, Inc. ++ * ++ * This file is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Lesser General Public ++ * License as published by the Free Software Foundation; either ++ * version 2.1 of the License, or (at your option) any later version. ++ * ++ * This file is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Lesser General Public License for more details. ++ */ ++ ++#include ++ ++ ++/* ++ * Endian independent macros for shifting bytes within registers. ++ */ ++#ifndef __ARMEB__ ++#define pull lsr ++#define push lsl ++#else ++#define pull lsl ++#define push lsr ++#endif ++ ++/* ++ * Enable data preload for architectures that support it (ARMv5 and above) ++ */ ++#if defined(__ARM_ARCH_5__) || \ ++ defined(__ARM_ARCH_5T__) || \ ++ defined(__ARM_ARCH_5TE__) ++#define PLD(code...) code ++#else ++#define PLD(code...) ++#endif ++ ++ ++/* char * memmove (char *dst, const char *src) */ ++ENTRY(memmove) ++ subs ip, r0, r1 ++ cmphi r2, ip ++ bls memcpy(PLT) ++ ++ stmfd sp!, {r0, r4, lr} ++ add r1, r1, r2 ++ add r0, r0, r2 ++ subs r2, r2, #4 ++ blt 25f ++ ands ip, r0, #3 ++ PLD( pld [r1, #-4] ) ++ bne 26f ++ ands ip, r1, #3 ++ bne 27f ++ ++19: subs r2, r2, #4 ++ blt 24f ++ subs r2, r2, #8 ++ blt 23f ++ subs r2, r2, #16 ++ blt 22f ++ ++ PLD( pld [r1, #-32] ) ++ PLD( subs r2, r2, #96 ) ++ stmfd sp!, {r5 - r8} ++ PLD( blt 21f ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, r1, #31 ) ++ PLD( pld [r1, #-64] ) ++ PLD( beq 20f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #-96] ) ++ PLD( blt 20f ) ++ PLD( cmp ip, #16 ) ++ PLD( sub r2, r2, ip ) ++ PLD( ldmgedb r1!, {r3 - r6} ) ++ PLD( stmgedb r0!, {r3 - r6} ) ++ PLD( beq 20f ) ++ PLD( and ip, ip, #15 ) ++ PLD( cmp ip, #8 ) ++ PLD( ldr r3, [r1, #-4]! ) ++ PLD( ldrge r4, [r1, #-4]! ) ++ PLD( ldrgt r5, [r1, #-4]! ) ++ PLD( str r3, [r0, #-4]! ) ++ PLD( strge r4, [r0, #-4]! ) ++ PLD( strgt r5, [r0, #-4]! ) ++ ++20: PLD( pld [r1, #-96] ) ++ PLD( pld [r1, #-128] ) ++21: ldmdb r1!, {r3, r4, ip, lr} ++ subs r2, r2, #32 ++ stmdb r0!, {r3, r4, ip, lr} ++ ldmdb r1!, {r3, r4, ip, lr} ++ stmgedb r0!, {r3, r4, ip, lr} ++ ldmgedb r1!, {r3, r4, ip, lr} ++ stmgedb r0!, {r3, r4, ip, lr} ++ ldmgedb r1!, {r3, r4, ip, lr} ++ subges r2, r2, #32 ++ stmdb r0!, {r3, r4, ip, lr} ++ bge 20b ++ PLD( cmn r2, #96 ) ++ PLD( bge 21b ) ++ PLD( add r2, r2, #96 ) ++ tst r2, #31 ++ ldmfd sp!, {r5 - r8} ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ tst r2, #16 ++22: ldmnedb r1!, {r3, r4, ip, lr} ++ stmnedb r0!, {r3, r4, ip, lr} ++ ++ tst r2, #8 ++23: ldmnedb r1!, {r3, r4} ++ stmnedb r0!, {r3, r4} ++ ++ tst r2, #4 ++24: ldrne r3, [r1, #-4]! ++ strne r3, [r0, #-4]! ++ ++25: ands r2, r2, #3 ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ cmp r2, #2 ++ ldrb r3, [r1, #-1] ++ ldrgeb r4, [r1, #-2] ++ ldrgtb ip, [r1, #-3] ++ strb r3, [r0, #-1] ++ strgeb r4, [r0, #-2] ++ strgtb ip, [r0, #-3] ++ ldmfd sp!, {r0, r4, pc} ++ ++26: cmp ip, #2 ++ ldrb r3, [r1, #-1]! ++ ldrgeb r4, [r1, #-1]! ++ ldrgtb lr, [r1, #-1]! ++ strb r3, [r0, #-1]! ++ strgeb r4, [r0, #-1]! ++ strgtb lr, [r0, #-1]! ++ subs r2, r2, ip ++ blt 25b ++ ands ip, r1, #3 ++ beq 19b ++ ++27: bic r1, r1, #3 ++ cmp ip, #2 ++ ldr r3, [r1] ++ beq 35f ++ blt 36f ++ ++ ++ .macro backward_copy_shift push pull ++ ++ cmp r2, #12 ++ PLD( pld [r1, #-4] ) ++ blt 33f ++ subs r2, r2, #28 ++ stmfd sp!, {r5 - r9} ++ blt 31f ++ ++ PLD( subs r2, r2, #96 ) ++ PLD( pld [r1, #-32] ) ++ PLD( blt 30f ) ++ PLD( pld [r1, #-64] ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, r1, #31 ) ++ PLD( pld [r1, #-96] ) ++ PLD( beq 29f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #-128] ) ++ PLD( blt 29f ) ++ PLD( sub r2, r2, ip ) ++28: PLD( mov r4, r3, push #\push ) ++ PLD( ldr r3, [r1, #-4]! ) ++ PLD( subs ip, ip, #4 ) ++ PLD( orr r4, r4, r3, pull #\pull ) ++ PLD( str r4, [r0, #-4]! ) ++ PLD( bgt 28b ) ++ ++29: PLD( pld [r1, #-128] ) ++30: mov lr, r3, push #\push ++ ldmdb r1!, {r3 - r9, ip} ++ subs r2, r2, #32 ++ orr lr, lr, ip, pull #\pull ++ mov ip, ip, push #\push ++ orr ip, ip, r9, pull #\pull ++ mov r9, r9, push #\push ++ orr r9, r9, r8, pull #\pull ++ mov r8, r8, push #\push ++ orr r8, r8, r7, pull #\pull ++ mov r7, r7, push #\push ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb r0!, {r4 - r9, ip, lr} ++ bge 29b ++ PLD( cmn r2, #96 ) ++ PLD( bge 30b ) ++ PLD( add r2, r2, #96 ) ++ cmn r2, #16 ++ blt 32f ++31: mov r7, r3, push #\push ++ ldmdb r1!, {r3 - r6} ++ sub r2, r2, #16 ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb r0!, {r4 - r7} ++32: adds r2, r2, #28 ++ ldmfd sp!, {r5 - r9} ++ blt 34f ++33: mov r4, r3, push #\push ++ ldr r3, [r1, #-4]! ++ subs r2, r2, #4 ++ orr r4, r4, r3, pull #\pull ++ str r4, [r0, #-4]! ++ bge 33b ++34: ++ .endm ++ ++ ++ backward_copy_shift push=8 pull=24 ++ add r1, r1, #3 ++ b 25b ++ ++35: backward_copy_shift push=16 pull=16 ++ add r1, r1, #2 ++ b 25b ++ ++36: backward_copy_shift push=24 pull=8 ++ add r1, r1, #1 ++ b 25b ++ ++ .size memmove, . - memmove ++END(memmove) ++libc_hidden_builtin_def (memmove) +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ libc/ports/sysdeps/arm/bcopy.S 2004-03-20 18:37:48.000000000 +0000 +@@ -0,0 +1,255 @@ ++/* ++ * Optimized memmove implementation for ARM processors ++ * ++ * Author: Nicolas Pitre ++ * Created: Dec 23, 2003 ++ * Copyright: (C) MontaVista Software, Inc. ++ * ++ * This file is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Lesser General Public ++ * License as published by the Free Software Foundation; either ++ * version 2.1 of the License, or (at your option) any later version. ++ * ++ * This file is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Lesser General Public License for more details. ++ */ ++ ++#include ++ ++ ++/* ++ * Endian independent macros for shifting bytes within registers. ++ */ ++#ifndef __ARMEB__ ++#define pull lsr ++#define push lsl ++#else ++#define pull lsl ++#define push lsr ++#endif ++ ++/* ++ * Enable data preload for architectures that support it (ARMv5 and above) ++ */ ++#if defined(__ARM_ARCH_5__) || \ ++ defined(__ARM_ARCH_5T__) || \ ++ defined(__ARM_ARCH_5TE__) ++#define PLD(code...) code ++#else ++#define PLD(code...) ++#endif ++ ++dst .req r1 ++src .req r0 ++ ++/* void *bcopy (const char *src, char *dst, size_t size) */ ++ENTRY(bcopy) ++ subs ip, dst, src ++ cmphi r2, ip ++ movls r3, r0 ++ movls r0, r1 ++ movls r1, r3 ++ bls memcpy(PLT) ++ ++ stmfd sp!, {r4, lr} ++ add src, src, r2 ++ add dst, dst, r2 ++ subs r2, r2, #4 ++ blt 25f ++ ands ip, dst, #3 ++ PLD( pld [src, #-4] ) ++ bne 26f ++ ands ip, src, #3 ++ bne 27f ++ ++19: subs r2, r2, #4 ++ blt 24f ++ subs r2, r2, #8 ++ blt 23f ++ subs r2, r2, #16 ++ blt 22f ++ ++ PLD( pld [src, #-32] ) ++ PLD( subs r2, r2, #96 ) ++ stmfd sp!, {r5 - r8} ++ PLD( blt 21f ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, src, #31 ) ++ PLD( pld [src, #-64] ) ++ PLD( beq 20f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [src, #-96] ) ++ PLD( blt 20f ) ++ PLD( cmp ip, #16 ) ++ PLD( sub r2, r2, ip ) ++ PLD( ldmgedb src!, {r3 - r6} ) ++ PLD( stmgedb dst!, {r3 - r6} ) ++ PLD( beq 20f ) ++ PLD( and ip, ip, #15 ) ++ PLD( cmp ip, #8 ) ++ PLD( ldr r3, [src, #-4]! ) ++ PLD( ldrge r4, [src, #-4]! ) ++ PLD( ldrgt r5, [src, #-4]! ) ++ PLD( str r3, [dst, #-4]! ) ++ PLD( strge r4, [dst, #-4]! ) ++ PLD( strgt r5, [dst, #-4]! ) ++ ++20: PLD( pld [src, #-96] ) ++ PLD( pld [src, #-128] ) ++21: ldmdb src!, {r3, r4, ip, lr} ++ subs r2, r2, #32 ++ stmdb dst!, {r3, r4, ip, lr} ++ ldmdb src!, {r3, r4, ip, lr} ++ stmgedb dst!, {r3, r4, ip, lr} ++ ldmgedb src!, {r3, r4, ip, lr} ++ stmgedb dst!, {r3, r4, ip, lr} ++ ldmgedb src!, {r3, r4, ip, lr} ++ subges r2, r2, #32 ++ stmdb dst!, {r3, r4, ip, lr} ++ bge 20b ++ PLD( cmn r2, #96 ) ++ PLD( bge 21b ) ++ PLD( add r2, r2, #96 ) ++ tst r2, #31 ++ ldmfd sp!, {r5 - r8} ++ ldmeqfd sp!, {r4, pc} ++ ++ tst r2, #16 ++22: ldmnedb src!, {r3, r4, ip, lr} ++ stmnedb dst!, {r3, r4, ip, lr} ++ ++ tst r2, #8 ++23: ldmnedb src!, {r3, r4} ++ stmnedb dst!, {r3, r4} ++ ++ tst r2, #4 ++24: ldrne r3, [src, #-4]! ++ strne r3, [dst, #-4]! ++ ++25: ands r2, r2, #3 ++ ldmeqfd sp!, {dst, r4, pc} ++ ++ cmp r2, #2 ++ ldrb r3, [src, #-1] ++ ldrgeb r4, [src, #-2] ++ ldrgtb ip, [src, #-3] ++ strb r3, [dst, #-1] ++ strgeb r4, [dst, #-2] ++ strgtb ip, [dst, #-3] ++ ldmfd sp!, {dst, r4, pc} ++ ++26: cmp ip, #2 ++ ldrb r3, [src, #-1]! ++ ldrgeb r4, [src, #-1]! ++ ldrgtb lr, [src, #-1]! ++ strb r3, [dst, #-1]! ++ strgeb r4, [dst, #-1]! ++ strgtb lr, [dst, #-1]! ++ subs r2, r2, ip ++ blt 25b ++ ands ip, src, #3 ++ beq 19b ++ ++27: bic src, src, #3 ++ cmp ip, #2 ++ ldr r3, [src] ++ beq 35f ++ blt 36f ++ ++ ++ .macro backward_copy_shift push pull ++ ++ cmp r2, #12 ++ PLD( pld [src, #-4] ) ++ blt 33f ++ subs r2, r2, #28 ++ stmfd sp!, {r5 - r9} ++ blt 31f ++ ++ PLD( subs r2, r2, #96 ) ++ PLD( pld [src, #-32] ) ++ PLD( blt 30f ) ++ PLD( pld [src, #-64] ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, src, #31 ) ++ PLD( pld [src, #-96] ) ++ PLD( beq 29f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [src, #-128] ) ++ PLD( blt 29f ) ++ PLD( sub r2, r2, ip ) ++28: PLD( mov r4, r3, push #\push ) ++ PLD( ldr r3, [src, #-4]! ) ++ PLD( subs ip, ip, #4 ) ++ PLD( orr r4, r4, r3, pull #\pull ) ++ PLD( str r4, [dst, #-4]! ) ++ PLD( bgt 28b ) ++ ++29: PLD( pld [src, #-128] ) ++30: mov lr, r3, push #\push ++ ldmdb src!, {r3 - r9, ip} ++ subs r2, r2, #32 ++ orr lr, lr, ip, pull #\pull ++ mov ip, ip, push #\push ++ orr ip, ip, r9, pull #\pull ++ mov r9, r9, push #\push ++ orr r9, r9, r8, pull #\pull ++ mov r8, r8, push #\push ++ orr r8, r8, r7, pull #\pull ++ mov r7, r7, push #\push ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb dst!, {r4 - r9, ip, lr} ++ bge 29b ++ PLD( cmn r2, #96 ) ++ PLD( bge 30b ) ++ PLD( add r2, r2, #96 ) ++ cmn r2, #16 ++ blt 32f ++31: mov r7, r3, push #\push ++ ldmdb src!, {r3 - r6} ++ sub r2, r2, #16 ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb dst!, {r4 - r7} ++32: adds r2, r2, #28 ++ ldmfd sp!, {r5 - r9} ++ blt 34f ++33: mov r4, r3, push #\push ++ ldr r3, [src, #-4]! ++ subs r2, r2, #4 ++ orr r4, r4, r3, pull #\pull ++ str r4, [dst, #-4]! ++ bge 33b ++34: ++ .endm ++ ++ ++ backward_copy_shift push=8 pull=24 ++ add src, src, #3 ++ b 25b ++ ++35: backward_copy_shift push=16 pull=16 ++ add src, src, #2 ++ b 25b ++ ++36: backward_copy_shift push=24 pull=8 ++ add src, src, #1 ++ b 25b ++ ++ .size bcopy, . - bcopy ++END(bcopy) + +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ libc/ports/sysdeps/arm/memcpy.S 2004-05-02 14:33:22.000000000 +0100 +@@ -0,0 +1,242 @@ ++/* ++ * Optimized memcpy implementation for ARM processors ++ * ++ * Author: Nicolas Pitre ++ * Created: Dec 23, 2003 ++ * Copyright: (C) MontaVista Software, Inc. ++ * ++ * This file is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Lesser General Public ++ * License as published by the Free Software Foundation; either ++ * version 2.1 of the License, or (at your option) any later version. ++ * ++ * This file is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Lesser General Public License for more details. ++ */ ++ ++#include ++ ++ ++/* ++ * Endian independent macros for shifting bytes within registers. ++ */ ++#ifndef __ARMEB__ ++#define pull lsr ++#define push lsl ++#else ++#define pull lsl ++#define push lsr ++#endif ++ ++/* ++ * Enable data preload for architectures that support it (ARMv5 and above) ++ */ ++#if defined(__ARM_ARCH_5__) || \ ++ defined(__ARM_ARCH_5T__) || \ ++ defined(__ARM_ARCH_5TE__) ++#define PLD(code...) code ++#else ++#define PLD(code...) ++#endif ++ ++ ++/* char * memcpy (char *dst, const char *src) */ ++ ++ENTRY(memcpy) ++ subs r2, r2, #4 ++ stmfd sp!, {r0, r4, lr} ++ blt 7f ++ ands ip, r0, #3 ++ PLD( pld [r1, #0] ) ++ bne 8f ++ ands ip, r1, #3 ++ bne 9f ++ ++1: subs r2, r2, #4 ++ blt 6f ++ subs r2, r2, #8 ++ blt 5f ++ subs r2, r2, #16 ++ blt 4f ++ ++ PLD( subs r2, r2, #65 ) ++ stmfd sp!, {r5 - r8} ++ PLD( blt 3f ) ++ PLD( pld [r1, #32] ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, r1, #31 ) ++ PLD( pld [r1, #64] ) ++ PLD( beq 2f ) ++ PLD( rsb ip, ip, #32 ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #96] ) ++ PLD( blt 2f ) ++ PLD( cmp ip, #16 ) ++ PLD( sub r2, r2, ip ) ++ PLD( ldmgeia r1!, {r3 - r6} ) ++ PLD( stmgeia r0!, {r3 - r6} ) ++ PLD( beq 2f ) ++ PLD( and ip, ip, #15 ) ++ PLD( cmp ip, #8 ) ++ PLD( ldr r3, [r1], #4 ) ++ PLD( ldrge r4, [r1], #4 ) ++ PLD( ldrgt r5, [r1], #4 ) ++ PLD( str r3, [r0], #4 ) ++ PLD( strge r4, [r0], #4 ) ++ PLD( strgt r5, [r0], #4 ) ++ ++2: PLD( pld [r1, #96] ) ++3: ldmia r1!, {r3 - r8, ip, lr} ++ subs r2, r2, #32 ++ stmia r0!, {r3 - r8, ip, lr} ++ bge 2b ++ PLD( cmn r2, #65 ) ++ PLD( bge 3b ) ++ PLD( add r2, r2, #65 ) ++ tst r2, #31 ++ ldmfd sp!, {r5 - r8} ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ tst r2, #16 ++4: ldmneia r1!, {r3, r4, ip, lr} ++ stmneia r0!, {r3, r4, ip, lr} ++ ++ tst r2, #8 ++5: ldmneia r1!, {r3, r4} ++ stmneia r0!, {r3, r4} ++ ++ tst r2, #4 ++6: ldrne r3, [r1], #4 ++ strne r3, [r0], #4 ++ ++7: ands r2, r2, #3 ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ cmp r2, #2 ++ ldrb r3, [r1], #1 ++ ldrgeb r4, [r1], #1 ++ ldrgtb ip, [r1] ++ strb r3, [r0], #1 ++ strgeb r4, [r0], #1 ++ strgtb ip, [r0] ++ ldmfd sp!, {r0, r4, pc} ++ ++8: rsb ip, ip, #4 ++ cmp ip, #2 ++ ldrb r3, [r1], #1 ++ ldrgeb r4, [r1], #1 ++ ldrgtb lr, [r1], #1 ++ strb r3, [r0], #1 ++ strgeb r4, [r0], #1 ++ strgtb lr, [r0], #1 ++ subs r2, r2, ip ++ blt 7b ++ ands ip, r1, #3 ++ beq 1b ++ ++9: bic r1, r1, #3 ++ cmp ip, #2 ++ ldr lr, [r1], #4 ++ beq 17f ++ bgt 18f ++ ++ ++ .macro forward_copy_shift pull push ++ ++ cmp r2, #12 ++ PLD( pld [r1, #0] ) ++ blt 15f ++ subs r2, r2, #28 ++ stmfd sp!, {r5 - r9} ++ blt 13f ++ ++ PLD( subs r2, r2, #97 ) ++ PLD( blt 12f ) ++ PLD( pld [r1, #32] ) ++ ++ PLD( @ cache alignment ) ++ PLD( rsb ip, r1, #36 ) ++ PLD( pld [r1, #64] ) ++ PLD( ands ip, ip, #31 ) ++ PLD( pld [r1, #96] ) ++ PLD( beq 11f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #128] ) ++ PLD( blt 11f ) ++ PLD( sub r2, r2, ip ) ++10: PLD( mov r3, lr, pull #\pull ) ++ PLD( ldr lr, [r1], #4 ) ++ PLD( subs ip, ip, #4 ) ++ PLD( orr r3, r3, lr, push #\push ) ++ PLD( str r3, [r0], #4 ) ++ PLD( bgt 10b ) ++ ++11: PLD( pld [r1, #128] ) ++12: mov r3, lr, pull #\pull ++ ldmia r1!, {r4 - r9, ip, lr} ++ subs r2, r2, #32 ++ orr r3, r3, r4, push #\push ++ mov r4, r4, pull #\pull ++ orr r4, r4, r5, push #\push ++ mov r5, r5, pull #\pull ++ orr r5, r5, r6, push #\push ++ mov r6, r6, pull #\pull ++ orr r6, r6, r7, push #\push ++ mov r7, r7, pull #\pull ++ orr r7, r7, r8, push #\push ++ mov r8, r8, pull #\pull ++ orr r8, r8, r9, push #\push ++ mov r9, r9, pull #\pull ++ orr r9, r9, ip, push #\push ++ mov ip, ip, pull #\pull ++ orr ip, ip, lr, push #\push ++ stmia r0!, {r3 - r9, ip} ++ bge 11b ++ PLD( cmn r2, #97 ) ++ PLD( bge 12b ) ++ PLD( add r2, r2, #97 ) ++ cmn r2, #16 ++ blt 14f ++13: mov r3, lr, pull #\pull ++ ldmia r1!, {r4 - r6, lr} ++ sub r2, r2, #16 ++ orr r3, r3, r4, push #\push ++ mov r4, r4, pull #\pull ++ orr r4, r4, r5, push #\push ++ mov r5, r5, pull #\pull ++ orr r5, r5, r6, push #\push ++ mov r6, r6, pull #\pull ++ orr r6, r6, lr, push #\push ++ stmia r0!, {r3 - r6} ++14: adds r2, r2, #28 ++ ldmfd sp!, {r5 - r9} ++ blt 16f ++15: mov r3, lr, pull #\pull ++ ldr lr, [r1], #4 ++ subs r2, r2, #4 ++ orr r3, r3, lr, push #\push ++ str r3, [r0], #4 ++ bge 15b ++16: ++ .endm ++ ++ ++ forward_copy_shift pull=8 push=24 ++ sub r1, r1, #3 ++ b 7b ++ ++17: forward_copy_shift pull=16 push=16 ++ sub r1, r1, #2 ++ b 7b ++ ++18: forward_copy_shift pull=24 push=8 ++ sub r1, r1, #1 ++ b 7b ++ ++ .size memcpy, . - memcpy ++END(memcpy) ++libc_hidden_builtin_def (memcpy) ++ diff --git a/meta/packages/glibc/glibc-cvs-2.3.5/arm-no-hwcap.patch b/meta/packages/glibc/glibc-cvs-2.3.5/arm-no-hwcap.patch new file mode 100644 index 000000000..d3263a7dc --- /dev/null +++ b/meta/packages/glibc/glibc-cvs-2.3.5/arm-no-hwcap.patch @@ -0,0 +1,11 @@ +--- libc/ports/sysdeps/unix/sysv/linux/arm/dl-procinfo.h.orig 2005-12-11 14:49:51 +0100 ++++ libc/ports/sysdeps/unix/sysv/linux/arm/dl-procinfo.h 2005-12-11 14:51:28 +0100 +@@ -64,7 +64,7 @@ + HWCAP_ARM_VFP = 1 << 6, + HWCAP_ARM_EDSP = 1 << 7, + +- HWCAP_IMPORTANT = (HWCAP_ARM_HALF | HWCAP_ARM_FAST_MULT) ++ HWCAP_IMPORTANT = HWCAP_ARM_FAST_MULT + }; + + static inline int diff --git a/meta/packages/glibc/glibc-cvs-2.3.5/dl-cache-libcmp.patch b/meta/packages/glibc/glibc-cvs-2.3.5/dl-cache-libcmp.patch new file mode 100644 index 000000000..c74ebf6c0 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs-2.3.5/dl-cache-libcmp.patch @@ -0,0 +1,10 @@ +--- libc/elf/Versions.old 2005-06-27 13:38:25.000000000 +0100 ++++ libc/elf/Versions 2005-06-27 14:03:54.000000000 +0100 +@@ -56,5 +56,7 @@ + _dl_make_stack_executable; + # Only here for gdb while a better method is developed. + _dl_debug_state; ++ # for ldconfig ++ _dl_cache_libcmp; + } + } diff --git a/meta/packages/glibc/glibc-cvs-2.3.5/dyn-ldconfig-20041128.patch b/meta/packages/glibc/glibc-cvs-2.3.5/dyn-ldconfig-20041128.patch new file mode 100644 index 000000000..451b6d4af --- /dev/null +++ b/meta/packages/glibc/glibc-cvs-2.3.5/dyn-ldconfig-20041128.patch @@ -0,0 +1,22 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- libc/elf/Makefile~dyn-ldconfig-20041128 ++++ libc/elf/Makefile +@@ -118,12 +118,13 @@ + + ifeq (yes,$(use-ldconfig)) + ifeq (yes,$(build-shared)) +-others-static += ldconfig ++#others-static += ldconfig + others += ldconfig + install-rootsbin += ldconfig + + ldconfig-modules := cache readlib xmalloc xstrdup chroot_canon + extra-objs += $(ldconfig-modules:=.o) ++CPPFLAGS-readlib.c = -DNOT_IN_libc=1 + + # To find xmalloc.c and xstrdup.c + vpath %.c ../locale/programs diff --git a/meta/packages/glibc/glibc-cvs-2.3.5/ldsocache-varrun.patch b/meta/packages/glibc/glibc-cvs-2.3.5/ldsocache-varrun.patch new file mode 100644 index 000000000..9994d4f87 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs-2.3.5/ldsocache-varrun.patch @@ -0,0 +1,18 @@ +This patch moves ld.so.cache from /etc to /var/run. This is for devices +where /etc is JFFS2 or CRAMFS but /var is a ramdisk. + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- libc/sysdeps/generic/dl-cache.h~ldsocache-varrun ++++ libc/sysdeps/generic/dl-cache.h +@@ -29,7 +29,7 @@ + #endif + + #ifndef LD_SO_CACHE +-# define LD_SO_CACHE SYSCONFDIR "/ld.so.cache" ++# define LD_SO_CACHE "/var/run/ld.so.cache" + #endif + + #ifndef add_system_dir diff --git a/meta/packages/glibc/glibc-cvs/arm-ioperm.patch b/meta/packages/glibc/glibc-cvs/arm-ioperm.patch new file mode 100644 index 000000000..ae9423ef5 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/arm-ioperm.patch @@ -0,0 +1,13 @@ +--- sysdeps/unix/sysv/linux/arm/ioperm.c 20 Feb 2003 22:22:35 -0000 1.6 ++++ sysdeps/unix/sysv/linux/arm/ioperm.c 24 Oct 2003 20:59:38 -0000 +@@ -100,8 +100,8 @@ + { + char systype[256]; + int i, n; +- static int iobase_name[] = { CTL_BUS, BUS_ISA, BUS_ISA_PORT_BASE }; +- static int ioshift_name[] = { CTL_BUS, BUS_ISA, BUS_ISA_PORT_SHIFT }; ++ static int iobase_name[] = { CTL_BUS, CTL_BUS_ISA, BUS_ISA_PORT_BASE }; ++ static int ioshift_name[] = { CTL_BUS, CTL_BUS_ISA, BUS_ISA_PORT_SHIFT }; + size_t len = sizeof(io.base); + + if (! sysctl (iobase_name, 3, &io.io_base, &len, NULL, 0) diff --git a/meta/packages/glibc/glibc-cvs/arm-longlong.patch b/meta/packages/glibc/glibc-cvs/arm-longlong.patch new file mode 100644 index 000000000..dfb9309b7 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/arm-longlong.patch @@ -0,0 +1,59 @@ +--- stdlib/longlong.h~ 2002-09-29 18:45:58.000000000 +0100 ++++ stdlib/longlong.h 2004-03-20 19:16:44.000000000 +0000 +@@ -210,6 +210,14 @@ + "rI" ((USItype) (bh)), \ + "r" ((USItype) (al)), \ + "rI" ((USItype) (bl))) ++/* v3m and all higher arches have long multiply support. */ ++#if !defined(__ARM_ARCH_2__) && !defined(__ARM_ARCH_3__) ++#define umul_ppmm(xh, xl, a, b) \ ++ __asm__ ("umull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b)) ++#define UMUL_TIME 5 ++#define smul_ppmm(xh, xl, a, b) \ ++ __asm__ ("smull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b)) ++#else + #define umul_ppmm(xh, xl, a, b) \ + {register USItype __t0, __t1, __t2; \ + __asm__ ("%@ Inlined umul_ppmm\n" \ +@@ -231,7 +239,14 @@ + : "r" ((USItype) (a)), \ + "r" ((USItype) (b)));} + #define UMUL_TIME 20 ++#endif + #define UDIV_TIME 100 ++ ++#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__) ++#define count_leading_zeros(COUNT,X) ((COUNT) = __builtin_clz (X)) ++#define COUNT_LEADING_ZEROS_0 32 ++#endif ++ + #endif /* __arm__ */ + + #if defined (__hppa) && W_TYPE_SIZE == 32 +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ sysdeps/arm/mp_clz_tab.c 2004-03-20 19:24:26.000000000 +0000 +@@ -0,0 +1,24 @@ ++/* __clz_tab -- support for longlong.h ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__) ++/* Nothing required. */ ++#else ++#include ++#endif diff --git a/meta/packages/glibc/glibc-cvs/arm-machine-gmon.patch b/meta/packages/glibc/glibc-cvs/arm-machine-gmon.patch new file mode 100644 index 000000000..0fa789d86 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/arm-machine-gmon.patch @@ -0,0 +1,11 @@ +--- sysdeps/arm/machine-gmon.h~ 2001-07-06 00:55:48.000000000 -0400 ++++ sysdeps/arm/machine-gmon.h 2004-04-25 03:56:20.000000000 -0400 +@@ -35,7 +35,7 @@ + static void mcount_internal (u_long frompc, u_long selfpc); + + #define _MCOUNT_DECL(frompc, selfpc) \ +-static void mcount_internal (u_long frompc, u_long selfpc) ++static __attribute__((used)) void mcount_internal (u_long frompc, u_long selfpc) + + /* This macro/func MUST save r0, r1 because the compiler inserts + blind calls to _mount(), ignoring the fact that _mcount may diff --git a/meta/packages/glibc/glibc-cvs/arm-memcpy.patch b/meta/packages/glibc/glibc-cvs/arm-memcpy.patch new file mode 100644 index 000000000..bc2b3dab8 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/arm-memcpy.patch @@ -0,0 +1,758 @@ +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ sysdeps/arm/memmove.S 2004-03-20 18:37:23.000000000 +0000 +@@ -0,0 +1,251 @@ ++/* ++ * Optimized memmove implementation for ARM processors ++ * ++ * Author: Nicolas Pitre ++ * Created: Dec 23, 2003 ++ * Copyright: (C) MontaVista Software, Inc. ++ * ++ * This file is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Lesser General Public ++ * License as published by the Free Software Foundation; either ++ * version 2.1 of the License, or (at your option) any later version. ++ * ++ * This file is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Lesser General Public License for more details. ++ */ ++ ++#include ++ ++ ++/* ++ * Endian independent macros for shifting bytes within registers. ++ */ ++#ifndef __ARMEB__ ++#define pull lsr ++#define push lsl ++#else ++#define pull lsl ++#define push lsr ++#endif ++ ++/* ++ * Enable data preload for architectures that support it (ARMv5 and above) ++ */ ++#if defined(__ARM_ARCH_5__) || \ ++ defined(__ARM_ARCH_5T__) || \ ++ defined(__ARM_ARCH_5TE__) ++#define PLD(code...) code ++#else ++#define PLD(code...) ++#endif ++ ++ ++/* char * memmove (char *dst, const char *src) */ ++ENTRY(memmove) ++ subs ip, r0, r1 ++ cmphi r2, ip ++ bls memcpy(PLT) ++ ++ stmfd sp!, {r0, r4, lr} ++ add r1, r1, r2 ++ add r0, r0, r2 ++ subs r2, r2, #4 ++ blt 25f ++ ands ip, r0, #3 ++ PLD( pld [r1, #-4] ) ++ bne 26f ++ ands ip, r1, #3 ++ bne 27f ++ ++19: subs r2, r2, #4 ++ blt 24f ++ subs r2, r2, #8 ++ blt 23f ++ subs r2, r2, #16 ++ blt 22f ++ ++ PLD( pld [r1, #-32] ) ++ PLD( subs r2, r2, #96 ) ++ stmfd sp!, {r5 - r8} ++ PLD( blt 21f ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, r1, #31 ) ++ PLD( pld [r1, #-64] ) ++ PLD( beq 20f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #-96] ) ++ PLD( blt 20f ) ++ PLD( cmp ip, #16 ) ++ PLD( sub r2, r2, ip ) ++ PLD( ldmgedb r1!, {r3 - r6} ) ++ PLD( stmgedb r0!, {r3 - r6} ) ++ PLD( beq 20f ) ++ PLD( and ip, ip, #15 ) ++ PLD( cmp ip, #8 ) ++ PLD( ldr r3, [r1, #-4]! ) ++ PLD( ldrge r4, [r1, #-4]! ) ++ PLD( ldrgt r5, [r1, #-4]! ) ++ PLD( str r3, [r0, #-4]! ) ++ PLD( strge r4, [r0, #-4]! ) ++ PLD( strgt r5, [r0, #-4]! ) ++ ++20: PLD( pld [r1, #-96] ) ++ PLD( pld [r1, #-128] ) ++21: ldmdb r1!, {r3, r4, ip, lr} ++ subs r2, r2, #32 ++ stmdb r0!, {r3, r4, ip, lr} ++ ldmdb r1!, {r3, r4, ip, lr} ++ stmgedb r0!, {r3, r4, ip, lr} ++ ldmgedb r1!, {r3, r4, ip, lr} ++ stmgedb r0!, {r3, r4, ip, lr} ++ ldmgedb r1!, {r3, r4, ip, lr} ++ subges r2, r2, #32 ++ stmdb r0!, {r3, r4, ip, lr} ++ bge 20b ++ PLD( cmn r2, #96 ) ++ PLD( bge 21b ) ++ PLD( add r2, r2, #96 ) ++ tst r2, #31 ++ ldmfd sp!, {r5 - r8} ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ tst r2, #16 ++22: ldmnedb r1!, {r3, r4, ip, lr} ++ stmnedb r0!, {r3, r4, ip, lr} ++ ++ tst r2, #8 ++23: ldmnedb r1!, {r3, r4} ++ stmnedb r0!, {r3, r4} ++ ++ tst r2, #4 ++24: ldrne r3, [r1, #-4]! ++ strne r3, [r0, #-4]! ++ ++25: ands r2, r2, #3 ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ cmp r2, #2 ++ ldrb r3, [r1, #-1] ++ ldrgeb r4, [r1, #-2] ++ ldrgtb ip, [r1, #-3] ++ strb r3, [r0, #-1] ++ strgeb r4, [r0, #-2] ++ strgtb ip, [r0, #-3] ++ ldmfd sp!, {r0, r4, pc} ++ ++26: cmp ip, #2 ++ ldrb r3, [r1, #-1]! ++ ldrgeb r4, [r1, #-1]! ++ ldrgtb lr, [r1, #-1]! ++ strb r3, [r0, #-1]! ++ strgeb r4, [r0, #-1]! ++ strgtb lr, [r0, #-1]! ++ subs r2, r2, ip ++ blt 25b ++ ands ip, r1, #3 ++ beq 19b ++ ++27: bic r1, r1, #3 ++ cmp ip, #2 ++ ldr r3, [r1] ++ beq 35f ++ blt 36f ++ ++ ++ .macro backward_copy_shift push pull ++ ++ cmp r2, #12 ++ PLD( pld [r1, #-4] ) ++ blt 33f ++ subs r2, r2, #28 ++ stmfd sp!, {r5 - r9} ++ blt 31f ++ ++ PLD( subs r2, r2, #96 ) ++ PLD( pld [r1, #-32] ) ++ PLD( blt 30f ) ++ PLD( pld [r1, #-64] ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, r1, #31 ) ++ PLD( pld [r1, #-96] ) ++ PLD( beq 29f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #-128] ) ++ PLD( blt 29f ) ++ PLD( sub r2, r2, ip ) ++28: PLD( mov r4, r3, push #\push ) ++ PLD( ldr r3, [r1, #-4]! ) ++ PLD( subs ip, ip, #4 ) ++ PLD( orr r4, r4, r3, pull #\pull ) ++ PLD( str r4, [r0, #-4]! ) ++ PLD( bgt 28b ) ++ ++29: PLD( pld [r1, #-128] ) ++30: mov lr, r3, push #\push ++ ldmdb r1!, {r3 - r9, ip} ++ subs r2, r2, #32 ++ orr lr, lr, ip, pull #\pull ++ mov ip, ip, push #\push ++ orr ip, ip, r9, pull #\pull ++ mov r9, r9, push #\push ++ orr r9, r9, r8, pull #\pull ++ mov r8, r8, push #\push ++ orr r8, r8, r7, pull #\pull ++ mov r7, r7, push #\push ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb r0!, {r4 - r9, ip, lr} ++ bge 29b ++ PLD( cmn r2, #96 ) ++ PLD( bge 30b ) ++ PLD( add r2, r2, #96 ) ++ cmn r2, #16 ++ blt 32f ++31: mov r7, r3, push #\push ++ ldmdb r1!, {r3 - r6} ++ sub r2, r2, #16 ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb r0!, {r4 - r7} ++32: adds r2, r2, #28 ++ ldmfd sp!, {r5 - r9} ++ blt 34f ++33: mov r4, r3, push #\push ++ ldr r3, [r1, #-4]! ++ subs r2, r2, #4 ++ orr r4, r4, r3, pull #\pull ++ str r4, [r0, #-4]! ++ bge 33b ++34: ++ .endm ++ ++ ++ backward_copy_shift push=8 pull=24 ++ add r1, r1, #3 ++ b 25b ++ ++35: backward_copy_shift push=16 pull=16 ++ add r1, r1, #2 ++ b 25b ++ ++36: backward_copy_shift push=24 pull=8 ++ add r1, r1, #1 ++ b 25b ++ ++ .size memmove, . - memmove ++END(memmove) ++libc_hidden_builtin_def (memmove) +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ sysdeps/arm/bcopy.S 2004-03-20 18:37:48.000000000 +0000 +@@ -0,0 +1,255 @@ ++/* ++ * Optimized memmove implementation for ARM processors ++ * ++ * Author: Nicolas Pitre ++ * Created: Dec 23, 2003 ++ * Copyright: (C) MontaVista Software, Inc. ++ * ++ * This file is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Lesser General Public ++ * License as published by the Free Software Foundation; either ++ * version 2.1 of the License, or (at your option) any later version. ++ * ++ * This file is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Lesser General Public License for more details. ++ */ ++ ++#include ++ ++ ++/* ++ * Endian independent macros for shifting bytes within registers. ++ */ ++#ifndef __ARMEB__ ++#define pull lsr ++#define push lsl ++#else ++#define pull lsl ++#define push lsr ++#endif ++ ++/* ++ * Enable data preload for architectures that support it (ARMv5 and above) ++ */ ++#if defined(__ARM_ARCH_5__) || \ ++ defined(__ARM_ARCH_5T__) || \ ++ defined(__ARM_ARCH_5TE__) ++#define PLD(code...) code ++#else ++#define PLD(code...) ++#endif ++ ++dst .req r1 ++src .req r0 ++ ++/* void *bcopy (const char *src, char *dst, size_t size) */ ++ENTRY(bcopy) ++ subs ip, dst, src ++ cmphi r2, ip ++ movls r3, r0 ++ movls r0, r1 ++ movls r1, r3 ++ bls memcpy(PLT) ++ ++ stmfd sp!, {r4, lr} ++ add src, src, r2 ++ add dst, dst, r2 ++ subs r2, r2, #4 ++ blt 25f ++ ands ip, dst, #3 ++ PLD( pld [src, #-4] ) ++ bne 26f ++ ands ip, src, #3 ++ bne 27f ++ ++19: subs r2, r2, #4 ++ blt 24f ++ subs r2, r2, #8 ++ blt 23f ++ subs r2, r2, #16 ++ blt 22f ++ ++ PLD( pld [src, #-32] ) ++ PLD( subs r2, r2, #96 ) ++ stmfd sp!, {r5 - r8} ++ PLD( blt 21f ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, src, #31 ) ++ PLD( pld [src, #-64] ) ++ PLD( beq 20f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [src, #-96] ) ++ PLD( blt 20f ) ++ PLD( cmp ip, #16 ) ++ PLD( sub r2, r2, ip ) ++ PLD( ldmgedb src!, {r3 - r6} ) ++ PLD( stmgedb dst!, {r3 - r6} ) ++ PLD( beq 20f ) ++ PLD( and ip, ip, #15 ) ++ PLD( cmp ip, #8 ) ++ PLD( ldr r3, [src, #-4]! ) ++ PLD( ldrge r4, [src, #-4]! ) ++ PLD( ldrgt r5, [src, #-4]! ) ++ PLD( str r3, [dst, #-4]! ) ++ PLD( strge r4, [dst, #-4]! ) ++ PLD( strgt r5, [dst, #-4]! ) ++ ++20: PLD( pld [src, #-96] ) ++ PLD( pld [src, #-128] ) ++21: ldmdb src!, {r3, r4, ip, lr} ++ subs r2, r2, #32 ++ stmdb dst!, {r3, r4, ip, lr} ++ ldmdb src!, {r3, r4, ip, lr} ++ stmgedb dst!, {r3, r4, ip, lr} ++ ldmgedb src!, {r3, r4, ip, lr} ++ stmgedb dst!, {r3, r4, ip, lr} ++ ldmgedb src!, {r3, r4, ip, lr} ++ subges r2, r2, #32 ++ stmdb dst!, {r3, r4, ip, lr} ++ bge 20b ++ PLD( cmn r2, #96 ) ++ PLD( bge 21b ) ++ PLD( add r2, r2, #96 ) ++ tst r2, #31 ++ ldmfd sp!, {r5 - r8} ++ ldmeqfd sp!, {r4, pc} ++ ++ tst r2, #16 ++22: ldmnedb src!, {r3, r4, ip, lr} ++ stmnedb dst!, {r3, r4, ip, lr} ++ ++ tst r2, #8 ++23: ldmnedb src!, {r3, r4} ++ stmnedb dst!, {r3, r4} ++ ++ tst r2, #4 ++24: ldrne r3, [src, #-4]! ++ strne r3, [dst, #-4]! ++ ++25: ands r2, r2, #3 ++ ldmeqfd sp!, {dst, r4, pc} ++ ++ cmp r2, #2 ++ ldrb r3, [src, #-1] ++ ldrgeb r4, [src, #-2] ++ ldrgtb ip, [src, #-3] ++ strb r3, [dst, #-1] ++ strgeb r4, [dst, #-2] ++ strgtb ip, [dst, #-3] ++ ldmfd sp!, {dst, r4, pc} ++ ++26: cmp ip, #2 ++ ldrb r3, [src, #-1]! ++ ldrgeb r4, [src, #-1]! ++ ldrgtb lr, [src, #-1]! ++ strb r3, [dst, #-1]! ++ strgeb r4, [dst, #-1]! ++ strgtb lr, [dst, #-1]! ++ subs r2, r2, ip ++ blt 25b ++ ands ip, src, #3 ++ beq 19b ++ ++27: bic src, src, #3 ++ cmp ip, #2 ++ ldr r3, [src] ++ beq 35f ++ blt 36f ++ ++ ++ .macro backward_copy_shift push pull ++ ++ cmp r2, #12 ++ PLD( pld [src, #-4] ) ++ blt 33f ++ subs r2, r2, #28 ++ stmfd sp!, {r5 - r9} ++ blt 31f ++ ++ PLD( subs r2, r2, #96 ) ++ PLD( pld [src, #-32] ) ++ PLD( blt 30f ) ++ PLD( pld [src, #-64] ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, src, #31 ) ++ PLD( pld [src, #-96] ) ++ PLD( beq 29f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [src, #-128] ) ++ PLD( blt 29f ) ++ PLD( sub r2, r2, ip ) ++28: PLD( mov r4, r3, push #\push ) ++ PLD( ldr r3, [src, #-4]! ) ++ PLD( subs ip, ip, #4 ) ++ PLD( orr r4, r4, r3, pull #\pull ) ++ PLD( str r4, [dst, #-4]! ) ++ PLD( bgt 28b ) ++ ++29: PLD( pld [src, #-128] ) ++30: mov lr, r3, push #\push ++ ldmdb src!, {r3 - r9, ip} ++ subs r2, r2, #32 ++ orr lr, lr, ip, pull #\pull ++ mov ip, ip, push #\push ++ orr ip, ip, r9, pull #\pull ++ mov r9, r9, push #\push ++ orr r9, r9, r8, pull #\pull ++ mov r8, r8, push #\push ++ orr r8, r8, r7, pull #\pull ++ mov r7, r7, push #\push ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb dst!, {r4 - r9, ip, lr} ++ bge 29b ++ PLD( cmn r2, #96 ) ++ PLD( bge 30b ) ++ PLD( add r2, r2, #96 ) ++ cmn r2, #16 ++ blt 32f ++31: mov r7, r3, push #\push ++ ldmdb src!, {r3 - r6} ++ sub r2, r2, #16 ++ orr r7, r7, r6, pull #\pull ++ mov r6, r6, push #\push ++ orr r6, r6, r5, pull #\pull ++ mov r5, r5, push #\push ++ orr r5, r5, r4, pull #\pull ++ mov r4, r4, push #\push ++ orr r4, r4, r3, pull #\pull ++ stmdb dst!, {r4 - r7} ++32: adds r2, r2, #28 ++ ldmfd sp!, {r5 - r9} ++ blt 34f ++33: mov r4, r3, push #\push ++ ldr r3, [src, #-4]! ++ subs r2, r2, #4 ++ orr r4, r4, r3, pull #\pull ++ str r4, [dst, #-4]! ++ bge 33b ++34: ++ .endm ++ ++ ++ backward_copy_shift push=8 pull=24 ++ add src, src, #3 ++ b 25b ++ ++35: backward_copy_shift push=16 pull=16 ++ add src, src, #2 ++ b 25b ++ ++36: backward_copy_shift push=24 pull=8 ++ add src, src, #1 ++ b 25b ++ ++ .size bcopy, . - bcopy ++END(bcopy) + +--- /dev/null 2004-02-02 20:32:13.000000000 +0000 ++++ sysdeps/arm/memcpy.S 2004-05-02 14:33:22.000000000 +0100 +@@ -0,0 +1,242 @@ ++/* ++ * Optimized memcpy implementation for ARM processors ++ * ++ * Author: Nicolas Pitre ++ * Created: Dec 23, 2003 ++ * Copyright: (C) MontaVista Software, Inc. ++ * ++ * This file is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Lesser General Public ++ * License as published by the Free Software Foundation; either ++ * version 2.1 of the License, or (at your option) any later version. ++ * ++ * This file is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Lesser General Public License for more details. ++ */ ++ ++#include ++ ++ ++/* ++ * Endian independent macros for shifting bytes within registers. ++ */ ++#ifndef __ARMEB__ ++#define pull lsr ++#define push lsl ++#else ++#define pull lsl ++#define push lsr ++#endif ++ ++/* ++ * Enable data preload for architectures that support it (ARMv5 and above) ++ */ ++#if defined(__ARM_ARCH_5__) || \ ++ defined(__ARM_ARCH_5T__) || \ ++ defined(__ARM_ARCH_5TE__) ++#define PLD(code...) code ++#else ++#define PLD(code...) ++#endif ++ ++ ++/* char * memcpy (char *dst, const char *src) */ ++ ++ENTRY(memcpy) ++ subs r2, r2, #4 ++ stmfd sp!, {r0, r4, lr} ++ blt 7f ++ ands ip, r0, #3 ++ PLD( pld [r1, #0] ) ++ bne 8f ++ ands ip, r1, #3 ++ bne 9f ++ ++1: subs r2, r2, #4 ++ blt 6f ++ subs r2, r2, #8 ++ blt 5f ++ subs r2, r2, #16 ++ blt 4f ++ ++ PLD( subs r2, r2, #65 ) ++ stmfd sp!, {r5 - r8} ++ PLD( blt 3f ) ++ PLD( pld [r1, #32] ) ++ ++ PLD( @ cache alignment ) ++ PLD( ands ip, r1, #31 ) ++ PLD( pld [r1, #64] ) ++ PLD( beq 2f ) ++ PLD( rsb ip, ip, #32 ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #96] ) ++ PLD( blt 2f ) ++ PLD( cmp ip, #16 ) ++ PLD( sub r2, r2, ip ) ++ PLD( ldmgeia r1!, {r3 - r6} ) ++ PLD( stmgeia r0!, {r3 - r6} ) ++ PLD( beq 2f ) ++ PLD( and ip, ip, #15 ) ++ PLD( cmp ip, #8 ) ++ PLD( ldr r3, [r1], #4 ) ++ PLD( ldrge r4, [r1], #4 ) ++ PLD( ldrgt r5, [r1], #4 ) ++ PLD( str r3, [r0], #4 ) ++ PLD( strge r4, [r0], #4 ) ++ PLD( strgt r5, [r0], #4 ) ++ ++2: PLD( pld [r1, #96] ) ++3: ldmia r1!, {r3 - r8, ip, lr} ++ subs r2, r2, #32 ++ stmia r0!, {r3 - r8, ip, lr} ++ bge 2b ++ PLD( cmn r2, #65 ) ++ PLD( bge 3b ) ++ PLD( add r2, r2, #65 ) ++ tst r2, #31 ++ ldmfd sp!, {r5 - r8} ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ tst r2, #16 ++4: ldmneia r1!, {r3, r4, ip, lr} ++ stmneia r0!, {r3, r4, ip, lr} ++ ++ tst r2, #8 ++5: ldmneia r1!, {r3, r4} ++ stmneia r0!, {r3, r4} ++ ++ tst r2, #4 ++6: ldrne r3, [r1], #4 ++ strne r3, [r0], #4 ++ ++7: ands r2, r2, #3 ++ ldmeqfd sp!, {r0, r4, pc} ++ ++ cmp r2, #2 ++ ldrb r3, [r1], #1 ++ ldrgeb r4, [r1], #1 ++ ldrgtb ip, [r1] ++ strb r3, [r0], #1 ++ strgeb r4, [r0], #1 ++ strgtb ip, [r0] ++ ldmfd sp!, {r0, r4, pc} ++ ++8: rsb ip, ip, #4 ++ cmp ip, #2 ++ ldrb r3, [r1], #1 ++ ldrgeb r4, [r1], #1 ++ ldrgtb lr, [r1], #1 ++ strb r3, [r0], #1 ++ strgeb r4, [r0], #1 ++ strgtb lr, [r0], #1 ++ subs r2, r2, ip ++ blt 7b ++ ands ip, r1, #3 ++ beq 1b ++ ++9: bic r1, r1, #3 ++ cmp ip, #2 ++ ldr lr, [r1], #4 ++ beq 17f ++ bgt 18f ++ ++ ++ .macro forward_copy_shift pull push ++ ++ cmp r2, #12 ++ PLD( pld [r1, #0] ) ++ blt 15f ++ subs r2, r2, #28 ++ stmfd sp!, {r5 - r9} ++ blt 13f ++ ++ PLD( subs r2, r2, #97 ) ++ PLD( blt 12f ) ++ PLD( pld [r1, #32] ) ++ ++ PLD( @ cache alignment ) ++ PLD( rsb ip, r1, #36 ) ++ PLD( pld [r1, #64] ) ++ PLD( ands ip, ip, #31 ) ++ PLD( pld [r1, #96] ) ++ PLD( beq 11f ) ++ PLD( cmp r2, ip ) ++ PLD( pld [r1, #128] ) ++ PLD( blt 11f ) ++ PLD( sub r2, r2, ip ) ++10: PLD( mov r3, lr, pull #\pull ) ++ PLD( ldr lr, [r1], #4 ) ++ PLD( subs ip, ip, #4 ) ++ PLD( orr r3, r3, lr, push #\push ) ++ PLD( str r3, [r0], #4 ) ++ PLD( bgt 10b ) ++ ++11: PLD( pld [r1, #128] ) ++12: mov r3, lr, pull #\pull ++ ldmia r1!, {r4 - r9, ip, lr} ++ subs r2, r2, #32 ++ orr r3, r3, r4, push #\push ++ mov r4, r4, pull #\pull ++ orr r4, r4, r5, push #\push ++ mov r5, r5, pull #\pull ++ orr r5, r5, r6, push #\push ++ mov r6, r6, pull #\pull ++ orr r6, r6, r7, push #\push ++ mov r7, r7, pull #\pull ++ orr r7, r7, r8, push #\push ++ mov r8, r8, pull #\pull ++ orr r8, r8, r9, push #\push ++ mov r9, r9, pull #\pull ++ orr r9, r9, ip, push #\push ++ mov ip, ip, pull #\pull ++ orr ip, ip, lr, push #\push ++ stmia r0!, {r3 - r9, ip} ++ bge 11b ++ PLD( cmn r2, #97 ) ++ PLD( bge 12b ) ++ PLD( add r2, r2, #97 ) ++ cmn r2, #16 ++ blt 14f ++13: mov r3, lr, pull #\pull ++ ldmia r1!, {r4 - r6, lr} ++ sub r2, r2, #16 ++ orr r3, r3, r4, push #\push ++ mov r4, r4, pull #\pull ++ orr r4, r4, r5, push #\push ++ mov r5, r5, pull #\pull ++ orr r5, r5, r6, push #\push ++ mov r6, r6, pull #\pull ++ orr r6, r6, lr, push #\push ++ stmia r0!, {r3 - r6} ++14: adds r2, r2, #28 ++ ldmfd sp!, {r5 - r9} ++ blt 16f ++15: mov r3, lr, pull #\pull ++ ldr lr, [r1], #4 ++ subs r2, r2, #4 ++ orr r3, r3, lr, push #\push ++ str r3, [r0], #4 ++ bge 15b ++16: ++ .endm ++ ++ ++ forward_copy_shift pull=8 push=24 ++ sub r1, r1, #3 ++ b 7b ++ ++17: forward_copy_shift pull=16 push=16 ++ sub r1, r1, #2 ++ b 7b ++ ++18: forward_copy_shift pull=24 push=8 ++ sub r1, r1, #1 ++ b 7b ++ ++ .size memcpy, . - memcpy ++END(memcpy) ++libc_hidden_builtin_def (memcpy) ++ diff --git a/meta/packages/glibc/glibc-cvs/arm-no-hwcap.patch b/meta/packages/glibc/glibc-cvs/arm-no-hwcap.patch new file mode 100644 index 000000000..17bfdcd12 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/arm-no-hwcap.patch @@ -0,0 +1,11 @@ +--- sysdeps/unix/sysv/linux/arm/dl-procinfo.h Mon Jul 23 12:57:23 2001 ++++ sysdeps/unix/sysv/linux/arm/dl-procinfo.h Sun Feb 10 06:37:00 2002 +@@ -67,7 +67,7 @@ + HWCAP_ARM_VFP = 1 << 6, + HWCAP_ARM_EDSP = 1 << 7, + +- HWCAP_IMPORTANT = (HWCAP_ARM_HALF | HWCAP_ARM_FAST_MULT) ++ HWCAP_IMPORTANT = HWCAP_ARM_FAST_MULT + }; + + static inline int diff --git a/meta/packages/glibc/glibc-cvs/dyn-ldconfig-20041128.patch b/meta/packages/glibc/glibc-cvs/dyn-ldconfig-20041128.patch new file mode 100644 index 000000000..451b6d4af --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/dyn-ldconfig-20041128.patch @@ -0,0 +1,22 @@ + +# +# Patch managed by http://www.holgerschurig.de/patcher.html +# + +--- libc/elf/Makefile~dyn-ldconfig-20041128 ++++ libc/elf/Makefile +@@ -118,12 +118,13 @@ + + ifeq (yes,$(use-ldconfig)) + ifeq (yes,$(build-shared)) +-others-static += ldconfig ++#others-static += ldconfig + others += ldconfig + install-rootsbin += ldconfig + + ldconfig-modules := cache readlib xmalloc xstrdup chroot_canon + extra-objs += $(ldconfig-modules:=.o) ++CPPFLAGS-readlib.c = -DNOT_IN_libc=1 + + # To find xmalloc.c and xstrdup.c + vpath %.c ../locale/programs diff --git a/meta/packages/glibc/glibc-cvs/dyn-ldconfig.patch b/meta/packages/glibc/glibc-cvs/dyn-ldconfig.patch new file mode 100644 index 000000000..1041965d0 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/dyn-ldconfig.patch @@ -0,0 +1,62 @@ +--- elf/Makefile 13 Mar 2003 21:50:57 -0000 1.258 ++++ elf/Makefile 27 Mar 2003 20:36:07 -0000 +@@ -109,12 +109,13 @@ + + ifeq (yes,$(use-ldconfig)) + ifeq (yes,$(build-shared)) +-others-static += ldconfig ++#others-static += ldconfig + others += ldconfig + install-rootsbin += ldconfig + + ldconfig-modules := cache readlib xmalloc xstrdup chroot_canon + extra-objs += $(ldconfig-modules:=.o) ++CPPFLAGS-readlib.c = -DNOT_IN_libc=1 + + # To find xmalloc.c and xstrdup.c + vpath %.c ../locale/programs +--- elf/ldconfig.c 13 Jan 2003 08:53:14 -0000 1.31 ++++ elf/ldconfig.c 27 Mar 2003 20:36:09 -0000 +@@ -149,6 +149,9 @@ + static int + is_hwcap_platform (const char *name) + { ++#if 1 ++ return 0; ++#else + int hwcap_idx = _dl_string_hwcap (name); + + if (hwcap_idx != -1 && ((1 << hwcap_idx) & hwcap_mask)) +@@ -164,6 +167,7 @@ + #endif + + return 0; ++#endif + } + + /* Get hwcap (including platform) encoding of path. */ +@@ -175,6 +179,7 @@ + uint64_t hwcap = 0; + uint64_t h; + ++#if 0 + size_t len; + + len = strlen (str); +@@ -210,6 +215,7 @@ + *ptr = '\0'; + } + ++#endif + free (str); + return hwcap; + } +--- elf/Versions.old 2004-06-26 13:18:35.000000000 +0100 ++++ elf/Versions 2004-06-26 14:41:09.000000000 +0100 +@@ -54,5 +54,6 @@ + _dl_get_tls_static_info; _dl_allocate_tls_init; + _dl_tls_setup; _dl_rtld_di_serinfo; + _dl_make_stack_executable; ++ _dl_cache_libcmp; + } + } diff --git a/meta/packages/glibc/glibc-cvs/eabi-patch-1 b/meta/packages/glibc/glibc-cvs/eabi-patch-1 new file mode 100644 index 000000000..9b1fd408d --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/eabi-patch-1 @@ -0,0 +1,88 @@ +From libc-alpha-return-17227-listarch-libc-alpha=sources dot redhat dot com at sources dot redhat dot com Tue Mar 22 15:57:25 2005 +Return-Path: +Delivered-To: listarch-libc-alpha at sources dot redhat dot com +Received: (qmail 12343 invoked by alias); 22 Mar 2005 15:57:24 -0000 +Mailing-List: contact libc-alpha-help at sources dot redhat dot com; run by ezmlm +Precedence: bulk +List-Subscribe: +List-Archive: +List-Post: +List-Help: , +Sender: libc-alpha-owner at sources dot redhat dot com +Delivered-To: mailing list libc-alpha at sources dot redhat dot com +Received: (qmail 12264 invoked from network); 22 Mar 2005 15:57:19 -0000 +Received: from unknown (HELO nevyn.them.org) (66.93.172.17) + by sourceware dot org with SMTP; 22 Mar 2005 15:57:19 -0000 +Received: from drow by nevyn.them.org with local (Exim 4.50 #1 (Debian)) + id 1DDll5-0006ip-R3; Tue, 22 Mar 2005 10:57:31 -0500 +Date: Tue, 22 Mar 2005 10:57:31 -0500 +From: Daniel Jacobowitz +To: libc-alpha at sources dot redhat dot com +Cc: Phil Blundell +Subject: Common bits for the ARM EABI port +Message-ID: <20050322155731.GA25613@nevyn.them.org> +Mail-Followup-To: libc-alpha at sources dot redhat dot com, + Phil Blundell +Mime-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +Content-Disposition: inline +User-Agent: Mutt/1.5.6+20040907i + +The changes to common files for the ARM EABI port; search the new directory, +use GLIBC_2.4 as a base version, and generate ld-linux.so.3 (so that old and +new ABI libraries can be installed on the same system, in case someone needs +to do that). Generic ARM changes coming up next. + +I noticed that the "configure: Regenerated" messages are often left out of +glibc changelogs; should I skip them? + +-- +Daniel Jacobowitz +CodeSourcery, LLC + +2005-03-22 Daniel Jacobowitz + + * configure.in: Add arm*-*-linux-gnueabi support. Remove + unused arm32 entry from $machine. + * configure: Regenerated. + * shlib-versions: Add arm*-*-linux-gnueabi. + +Index: glibc/configure.in +=================================================================== +--- glibc.orig/configure.in 2005-03-18 17:10:34.000000000 -0500 ++++ glibc/configure.in 2005-03-21 10:04:41.000000000 -0500 +@@ -423,7 +423,12 @@ changequote(,)dnl + test -n "$base_machine" || case "$machine" in + a29k | am29000) base_machine=a29k machine=a29k ;; + alpha*) base_machine=alpha machine=alpha/$machine ;; +-arm*) base_machine=arm machine=arm/arm32/$machine ;; ++arm*) base_machine=arm ++ case $config_os in ++ linux-gnueabi) machine=arm/eabi/$machine ;; ++ *) machine=arm/$machine ;; ++ esac ++ ;; + c3[012]) base_machine=cx0 machine=cx0/c30 ;; + c4[04]) base_machine=cx0 machine=cx0/c40 ;; + hppa*64*) base_machine=hppa machine=hppa/hppa64 ;; +Index: glibc/shlib-versions +=================================================================== +--- glibc.orig/shlib-versions 2005-02-13 21:53:05.000000000 -0500 ++++ glibc/shlib-versions 2005-03-21 10:06:54.000000000 -0500 +@@ -31,6 +31,7 @@ cris-.*-linux.* DEFAULT GLIBC_2.2 + x86_64-.*-linux.* DEFAULT GLIBC_2.2.5 + powerpc64-.*-linux.* DEFAULT GLIBC_2.3 + .*-.*-gnu-gnu.* DEFAULT GLIBC_2.2.6 ++arm.*-.*-linux-gnueabi DEFAULT GLIBC_2.4 + + # Configuration WORDSIZE[32|64] Alternate configuration + # ------------- ---------- ----------------------- +@@ -80,6 +81,7 @@ i.86-.*-linux.* ld=ld-linux.so.2 + sparc64-.*-linux.* ld=ld-linux.so.2 GLIBC_2.2 + sparc.*-.*-linux.* ld=ld-linux.so.2 + alpha.*-.*-linux.* ld=ld-linux.so.2 ++arm.*-.*-linux-gnueabi ld=ld-linux.so.3 + arm.*-.*-linux.* ld=ld-linux.so.2 + sh.*-.*-linux.* ld=ld-linux.so.2 GLIBC_2.2 + ia64-.*-linux.* ld=ld-linux-ia64.so.2 GLIBC_2.2 + diff --git a/meta/packages/glibc/glibc-cvs/eabi-patch-2 b/meta/packages/glibc/glibc-cvs/eabi-patch-2 new file mode 100644 index 000000000..955a9bb51 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/eabi-patch-2 @@ -0,0 +1,2446 @@ +From libc-alpha-return-17231-listarch-libc-alpha=sources dot redhat dot com at sources dot redhat dot com Tue Mar 22 17:39:38 2005 +Return-Path: +Delivered-To: listarch-libc-alpha at sources dot redhat dot com +Received: (qmail 15063 invoked by alias); 22 Mar 2005 17:39:38 -0000 +Mailing-List: contact libc-alpha-help at sources dot redhat dot com; run by ezmlm +Precedence: bulk +List-Subscribe: +List-Archive: +List-Post: +List-Help: , +Sender: libc-alpha-owner at sources dot redhat dot com +Delivered-To: mailing list libc-alpha at sources dot redhat dot com +Received: (qmail 13714 invoked from network); 22 Mar 2005 17:38:53 -0000 +Received: from unknown (HELO nevyn.them.org) (66.93.172.17) + by sourceware dot org with SMTP; 22 Mar 2005 17:38:53 -0000 +Received: from drow by nevyn.them.org with local (Exim 4.50 #1 (Debian)) + id 1DDnLP-00007R-0B; Tue, 22 Mar 2005 12:39:07 -0500 +Date: Tue, 22 Mar 2005 12:39:06 -0500 +From: Daniel Jacobowitz +To: libc-alpha at sources dot redhat dot com, Phil Blundell +Subject: Re: Remainder of ARM EABI support +Message-ID: <20050322173906.GA316@nevyn.them.org> +Mail-Followup-To: libc-alpha at sources dot redhat dot com, + Phil Blundell +References: <20050322162137.GA26662@nevyn.them.org> +Mime-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +Content-Disposition: inline +In-Reply-To: <20050322162137 dot GA26662 at nevyn dot them dot org> +User-Agent: Mutt/1.5.6+20040907i + +On Tue, Mar 22, 2005 at 11:21:37AM -0500, Daniel Jacobowitz wrote: +> This patch is the remaining pieces of ARM EABI support, the +> arm*-*-linux-gnueabi target. +> +> Highlights of the new ABI compared to the old one: +> - Eight byte stack alignment instead of four. +> - VFP floating point support instead of FPA; there's actually hardware +> which supports VFP... +> - More standard structure layout. The old ABI (APCS) always rounded +> structures up to 32-bit alignment even if they contained only chars; +> it also aligned 64-bit fields to four bytes. +> - Some types have been grown to accomodate modern ARM cores, particularly +> jmp_buf. +> +> The EABI also defines some additional symbols that a C library has to +> define, which allow "portable" ARM objects to be linked to multiple C +> libraries even if certain implementation-defined constants differ. +> They're added to ARM-specific files in libc_nonshared.a. +> +> Most of the contents of sysdeps/unix/sysv/linux/arm/eabi are wrappers for +> syscalls whose types have changed between the old and new ABI. The kernel +> developers are discussing an EABI syscall interface, but for now the swi +> based syscalls take the same argument types they used to for APCS. Only +> a handful of syscalls are affected. + +My track record is not very good this morning; I apologize. I sent the +wrong version of the patch. This one includes a couple of VFP fixes +left out of the last posting, and a complete changelog. + +-- +Daniel Jacobowitz +CodeSourcery, LLC + +2005-03-22 Daniel Jacobowitz + Mark Mitchell + Paul Brook + + * sysdeps/arm/eabi/Makefile, sysdeps/arm/eabi/Versions, + sysdeps/arm/eabi/aeabi_assert.c, sysdeps/arm/eabi/aeabi_atexit.c, + sysdeps/arm/eabi/aeabi_errno_addr.c, sysdeps/arm/eabi/aeabi_lcsts.c, + sysdeps/arm/eabi/aeabi_localeconv.c, sysdeps/arm/eabi/aeabi_math.c, + sysdeps/arm/eabi/aeabi_mb_cur_max.c, + sysdeps/arm/eabi/aeabi_sighandlers.S, + sysdeps/arm/eabi/aeabi_unwind_cpp_pr1.c, + sysdeps/arm/eabi/bits/huge_val.h, sysdeps/arm/eabi/bits/setjmp.h, + sysdeps/arm/eabi/find_exidx.c, sysdeps/arm/eabi/fpu/__longjmp.S, + sysdeps/arm/eabi/fpu/bits/fenv.h, sysdeps/arm/eabi/fpu/fclrexcpt.c, + sysdeps/arm/eabi/fpu/fegetround.c, sysdeps/arm/eabi/fpu/fesetenv.c, + sysdeps/arm/eabi/fpu/fesetround.c, sysdeps/arm/eabi/fpu/fpu_control.h, + sysdeps/arm/eabi/fpu/feholdexcpt.c, + sysdeps/arm/eabi/fpu/fraiseexcpt.c, + sysdeps/arm/eabi/fpu/setjmp.S, + sysdeps/unix/sysv/linux/arm/eabi/configure, + sysdeps/unix/sysv/linux/arm/eabi/configure.in, + sysdeps/unix/sysv/linux/arm/eabi/epoll_ctl.c, + sysdeps/unix/sysv/linux/arm/eabi/epoll_wait.c, + sysdeps/unix/sysv/linux/arm/eabi/fstatfs64.c, + sysdeps/unix/sysv/linux/arm/eabi/fxstat64.c, + sysdeps/unix/sysv/linux/arm/eabi/kernel_stat.h, + sysdeps/unix/sysv/linux/arm/eabi/lxstat64.c, + sysdeps/unix/sysv/linux/arm/eabi/oldgetrlimit.c, + sysdeps/unix/sysv/linux/arm/eabi/oldsetrlimit.c, + sysdeps/unix/sysv/linux/arm/eabi/semop.c, + sysdeps/unix/sysv/linux/arm/eabi/semtimedop.c, + sysdeps/unix/sysv/linux/arm/eabi/statfs64.c, + sysdeps/unix/sysv/linux/arm/eabi/uname.c, + sysdeps/unix/sysv/linux/arm/eabi/xstat64.c, + sysdeps/unix/sysv/linux/arm/eabi/xstatconv.c, + sysdeps/unix/sysv/linux/arm/eabi/xstatconv.h: New files. + + +Index: glibc/sysdeps/arm/eabi/Makefile +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/Makefile 2005-03-22 11:53:10.049703870 -0500 +@@ -0,0 +1,15 @@ ++ifeq ($(subdir),csu) ++aeabi_constants = aeabi_lcsts aeabi_sighandlers aeabi_math ++aeabi_routines = aeabi_assert aeabi_localeconv aeabi_errno_addr \ ++ aeabi_mb_cur_max aeabi_atexit ++ ++sysdep_routines += $(aeabi_constants) $(aeabi_routines) ++static-only-routines += $(aeabi_constants) $(aeabi_routines) ++endif ++ ++ifeq ($(subdir),elf) ++sysdep_routines += aeabi_unwind_cpp_pr1 find_exidx ++shared-only-routines += aeabi_unwind_cpp_pr1 ++sysdep-rtld-routines += aeabi_unwind_cpp_pr1 ++endif ++ +Index: glibc/sysdeps/arm/eabi/Versions +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/Versions 2005-03-22 11:53:10.049703870 -0500 +@@ -0,0 +1,6 @@ ++libc { ++ GLIBC_2.4 { ++ # Helper routines ++ __gnu_Unwind_Find_exidx; ++ } ++} +Index: glibc/sysdeps/arm/eabi/aeabi_assert.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/aeabi_assert.c 2005-03-22 11:53:10.049703870 -0500 +@@ -0,0 +1,27 @@ ++/* Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++ ++void attribute_hidden ++__aeabi_assert (const char *assertion, const char *file, ++ unsigned int line) ++{ ++ __assert_fail (assertion, file, line, NULL); ++} +Index: glibc/sysdeps/arm/eabi/aeabi_atexit.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/aeabi_atexit.c 2005-03-22 11:53:10.050703627 -0500 +@@ -0,0 +1,28 @@ ++/* Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++ ++/* Register a function to be called by exit or when a shared library ++ is unloaded. This routine is like __cxa_atexit, but uses the ++ calling sequence required by the ARM EABI. */ ++int attribute_hidden ++__aeabi_atexit (void *arg, void (*func) (void *), void *d) ++{ ++ return __cxa_atexit (func, arg, d); ++} +Index: glibc/sysdeps/arm/eabi/aeabi_errno_addr.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/aeabi_errno_addr.c 2005-03-22 11:53:10.050703627 -0500 +@@ -0,0 +1,26 @@ ++/* Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++ ++attribute_hidden ++volatile int * ++__aeabi_errno_addr (void) ++{ ++ return &errno; ++} +Index: glibc/sysdeps/arm/eabi/aeabi_lcsts.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/aeabi_lcsts.c 2005-03-22 11:53:10.050703627 -0500 +@@ -0,0 +1,67 @@ ++/* Link-time constants for ARM EABI. ++ Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++/* The ARM EABI requires that we provide ISO compile-time constants as ++ link-time constants. Some portable applications may reference these. */ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++#define eabi_constant2(X,Y) const int __aeabi_##X attribute_hidden = Y ++#define eabi_constant(X) const int __aeabi_##X attribute_hidden = X ++ ++eabi_constant (EDOM); ++eabi_constant (ERANGE); ++eabi_constant (EILSEQ); ++ ++eabi_constant (MB_LEN_MAX); ++ ++eabi_constant (LC_COLLATE); ++eabi_constant (LC_CTYPE); ++eabi_constant (LC_MONETARY); ++eabi_constant (LC_NUMERIC); ++eabi_constant (LC_TIME); ++eabi_constant (LC_ALL); ++ ++/* The value of __aeabi_JMP_BUF_SIZE is the number of doublewords in a ++ jmp_buf. */ ++eabi_constant2 (JMP_BUF_SIZE, sizeof (jmp_buf) / 8); ++ ++eabi_constant (SIGABRT); ++eabi_constant (SIGFPE); ++eabi_constant (SIGILL); ++eabi_constant (SIGINT); ++eabi_constant (SIGSEGV); ++eabi_constant (SIGTERM); ++ ++eabi_constant2 (IOFBF, _IOFBF); ++eabi_constant2 (IOLBF, _IOLBF); ++eabi_constant2 (IONBF, _IONBF); ++eabi_constant (BUFSIZ); ++eabi_constant (FOPEN_MAX); ++eabi_constant (TMP_MAX); ++eabi_constant (FILENAME_MAX); ++eabi_constant (L_tmpnam); ++ ++eabi_constant (CLOCKS_PER_SEC); +Index: glibc/sysdeps/arm/eabi/aeabi_localeconv.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/aeabi_localeconv.c 2005-03-22 11:53:10.050703627 -0500 +@@ -0,0 +1,26 @@ ++/* Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++ ++attribute_hidden ++struct lconv * ++__aeabi_localeconv (void) ++{ ++ return localeconv (); ++} +Index: glibc/sysdeps/arm/eabi/aeabi_math.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/aeabi_math.c 2005-03-22 11:53:10.050703627 -0500 +@@ -0,0 +1,25 @@ ++/* Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++ ++const double __aeabi_HUGE_VAL attribute_hidden = HUGE_VAL; ++const long double __aeabi_HUGE_VALL attribute_hidden = HUGE_VALL; ++const float __aeabi_HUGE_VALF attribute_hidden = HUGE_VALF; ++const float __aeabi_INFINITY attribute_hidden = INFINITY; ++const float __aeabi_NAN attribute_hidden = NAN; +Index: glibc/sysdeps/arm/eabi/aeabi_mb_cur_max.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/aeabi_mb_cur_max.c 2005-03-22 11:53:10.051703385 -0500 +@@ -0,0 +1,28 @@ ++/* Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++ ++int attribute_hidden ++__aeabi_MB_CUR_MAX (void) ++{ ++ return MB_CUR_MAX; ++} +Index: glibc/sysdeps/arm/eabi/aeabi_sighandlers.S +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/aeabi_sighandlers.S 2005-03-22 11:53:10.051703385 -0500 +@@ -0,0 +1,37 @@ ++/* Link-time constants for ARM EABI - signal handlers. ++ Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++/* The ARM EABI defines these as "functions". */ ++ ++#include ++ ++ .global __aeabi_SIG_DFL ++ .hidden __aeabi_SIG_DFL ++ .type __aeabi_SIG_DFL, %function ++ .set __aeabi_SIG_DFL, 0 ++ ++ .global __aeabi_SIG_IGN ++ .hidden __aeabi_SIG_IGN ++ .type __aeabi_SIG_IGN, %function ++ .set __aeabi_SIG_IGN, 1 ++ ++ .global __aeabi_SIG_ERR ++ .hidden __aeabi_SIG_ERR ++ .type __aeabi_SIG_ERR, %function ++ .set __aeabi_SIG_ERR, -1 +Index: glibc/sysdeps/arm/eabi/aeabi_unwind_cpp_pr1.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/aeabi_unwind_cpp_pr1.c 2005-03-22 11:53:10.051703385 -0500 +@@ -0,0 +1,28 @@ ++/* Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++/* Because some objects in ld.so and libc.so are built with ++ -fexceptions, we end up with references to this personality ++ routine. However, these libraries are not linked against ++ libgcc_eh.a, so we need a dummy definition. This routine will ++ never actually be called. */ ++ ++void ++__aeabi_unwind_cpp_pr1 (void) ++{ ++} +Index: glibc/sysdeps/arm/eabi/bits/huge_val.h +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/bits/huge_val.h 2005-03-22 11:53:10.051703385 -0500 +@@ -0,0 +1,55 @@ ++/* `HUGE_VAL' constant for IEEE 754 machines (where it is infinity). ++ Used by and functions for overflow. ++ Copyright (C) 1992, 1995, 1996, 1997, 1999, 2000, 2004 ++ Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#ifndef _MATH_H ++# error "Never use directly; include instead." ++#endif ++ ++/* IEEE positive infinity (-HUGE_VAL is negative infinity). */ ++ ++#if __GNUC_PREREQ(3,3) ++# define HUGE_VAL (__builtin_huge_val()) ++#elif __GNUC_PREREQ(2,96) ++# define HUGE_VAL (__extension__ 0x1.0p2047) ++#elif defined __GNUC__ ++ ++# define HUGE_VAL \ ++ (__extension__ \ ++ ((union { unsigned __l __attribute__((__mode__(__DI__))); double __d; }) \ ++ { __l: 0x7ff0000000000000ULL }).__d) ++ ++#else /* not GCC */ ++ ++# include ++ ++typedef union { unsigned char __c[8]; double __d; } __huge_val_t; ++ ++# if __BYTE_ORDER == __BIG_ENDIAN ++# define __HUGE_VAL_bytes { 0x7f, 0xf0, 0, 0, 0, 0, 0, 0 } ++# endif ++# if __BYTE_ORDER == __LITTLE_ENDIAN ++# define __HUGE_VAL_bytes { 0, 0, 0, 0, 0, 0, 0xf0, 0x7f } ++# endif ++ ++static __huge_val_t __huge_val = { __HUGE_VAL_bytes }; ++# define HUGE_VAL (__huge_val.__d) ++ ++#endif /* GCC. */ +Index: glibc/sysdeps/arm/eabi/bits/setjmp.h +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/bits/setjmp.h 2005-03-22 11:53:10.052703143 -0500 +@@ -0,0 +1,45 @@ ++/* Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++/* Define the machine-dependent type `jmp_buf'. ARM EABI version. */ ++ ++#ifndef _BITS_SETJMP_H ++#define _BITS_SETJMP_H 1 ++ ++#if !defined _SETJMP_H && !defined _PTHREAD_H ++# error "Never include directly; use instead." ++#endif ++ ++#ifndef _ASM ++/* The exact set of registers saved may depend on the particular core ++ in use, as some coprocessor registers may need to be saved. The C ++ Library ABI requires that the buffer be 8-byte aligned, and ++ recommends that the buffer contain 64 words. The first 28 words ++ are occupied by v1-v6, sl, fp, sp, pc, d8-d15, and fpscr. (Note ++ that d8-15 require 17 words, due to the use of fstmx.) */ ++typedef int __jmp_buf[64] __attribute__((aligned (8))); ++#endif ++ ++#define __JMP_BUF_SP 8 ++ ++/* Test if longjmp to JMPBUF would unwind the frame ++ containing a local variable at ADDRESS. */ ++#define _JMPBUF_UNWINDS(jmpbuf, address) \ ++ ((void *) (address) < (void *) (jmpbuf[__JMP_BUF_SP])) ++ ++#endif +Index: glibc/sysdeps/arm/eabi/find_exidx.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/find_exidx.c 2005-03-22 11:53:10.052703143 -0500 +@@ -0,0 +1,80 @@ ++/* Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++ ++struct unw_eh_callback_data ++{ ++ _Unwind_Ptr pc; ++ _Unwind_Ptr exidx_start; ++ int exidx_len; ++}; ++ ++ ++/* Callback to determins if the PC lies within an object, and remember the ++ location of the exception index table if it does. */ ++ ++static int ++find_exidx_callback (struct dl_phdr_info * info, size_t size, void * ptr) ++{ ++ struct unw_eh_callback_data * data; ++ const ElfW(Phdr) *phdr; ++ int i; ++ int match; ++ _Unwind_Ptr load_base; ++ ++ data = (struct unw_eh_callback_data *) ptr; ++ load_base = info->dlpi_addr; ++ phdr = info->dlpi_phdr; ++ ++ match = 0; ++ for (i = info->dlpi_phnum; i > 0; i--, phdr++) ++ { ++ if (phdr->p_type == PT_LOAD) ++ { ++ _Unwind_Ptr vaddr = phdr->p_vaddr + load_base; ++ if (data->pc >= vaddr && data->pc < vaddr + phdr->p_memsz) ++ match = 1; ++ } ++ else if (phdr->p_type == PT_ARM_EXIDX) ++ { ++ data->exidx_start = (_Unwind_Ptr) (phdr->p_vaddr + load_base); ++ data->exidx_len = phdr->p_memsz; ++ } ++ } ++ ++ return match; ++} ++ ++ ++/* Find the exception index table containing PC. */ ++ ++_Unwind_Ptr ++__gnu_Unwind_Find_exidx (_Unwind_Ptr pc, int * pcount) ++{ ++ struct unw_eh_callback_data data; ++ ++ data.pc = pc; ++ data.exidx_start = 0; ++ if (dl_iterate_phdr (find_exidx_callback, &data) <= 0) ++ return 0; ++ ++ *pcount = data.exidx_len / 8; ++ return data.exidx_start; ++} +Index: glibc/sysdeps/arm/eabi/fpu/__longjmp.S +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/__longjmp.S 2005-03-22 11:53:10.052703143 -0500 +@@ -0,0 +1,43 @@ ++/* longjmp for ARM. ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#define _SETJMP_H ++#define _ASM ++#include ++ ++/* __longjmp(jmpbuf, val) */ ++ ++ENTRY (__longjmp) ++ mov ip, r0 /* save jmp_buf pointer */ ++ ++ movs r0, r1 /* get the return value in place */ ++ moveq r0, #1 /* can't let setjmp() return zero! */ ++ ++ /* Restore the integer registers. */ ++ LOADREGS(ia, ip!, {v1-v6, sl, fp, sp, lr}) ++ ++ /* Restore the VFP registers. */ ++ fldmiax ip!, {d8-d15} ++ /* Restore the floating-point status register. */ ++ ldr r1, [ip], #4 ++ fmxr fpscr, r1 ++ ++ DO_RET(lr) ++END (__longjmp) +Index: glibc/sysdeps/arm/eabi/fpu/bits/fenv.h +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/bits/fenv.h 2005-03-22 12:34:55.511467536 -0500 +@@ -0,0 +1,74 @@ ++/* Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#ifndef _FENV_H ++# error "Never use directly; include instead." ++#endif ++ ++/* Define bits representing exceptions in the FPU status word. */ ++enum ++ { ++ FE_INVALID = 1, ++#define FE_INVALID FE_INVALID ++ FE_DIVBYZERO = 2, ++#define FE_DIVBYZERO FE_DIVBYZERO ++ FE_OVERFLOW = 4, ++#define FE_OVERFLOW FE_OVERFLOW ++ FE_UNDERFLOW = 8, ++#define FE_UNDERFLOW FE_UNDERFLOW ++ FE_INEXACT = 16, ++#define FE_INEXACT FE_INEXACT ++ }; ++ ++/* Amount to shift by to convert an exception to a mask bit. */ ++#define FE_EXCEPT_SHIFT 8 ++ ++/* All supported exceptions. */ ++#define FE_ALL_EXCEPT \ ++ (FE_INVALID | FE_DIVBYZERO | FE_OVERFLOW | FE_UNDERFLOW | FE_INEXACT) ++ ++/* VFP supports all of the four defined rounding modes. */ ++enum ++ { ++ FE_TONEAREST = 0, ++#define FE_TONEAREST FE_TONEAREST ++ FE_UPWARD = 0x400000, ++#define FE_UPWARD FE_UPWARD ++ FE_DOWNWARD = 0x800000, ++#define FE_DOWNWARD FE_DOWNWARD ++ FE_TOWARDZERO = 0xc00000 ++#define FE_TOWARDZERO FE_TOWARDZERO ++ }; ++ ++/* Type representing exception flags. */ ++typedef unsigned int fexcept_t; ++ ++/* Type representing floating-point environment. */ ++typedef struct ++ { ++ unsigned int __cw; ++ } ++fenv_t; ++ ++/* If the default argument is used we use this value. */ ++#define FE_DFL_ENV ((fenv_t *) -1l) ++ ++#ifdef __USE_GNU ++/* Floating-point environment where none of the exceptions are masked. */ ++# define FE_NOMASK_ENV ((__const fenv_t *) -2) ++#endif +Index: glibc/sysdeps/arm/eabi/fpu/fclrexcpt.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/fclrexcpt.c 2005-03-22 11:53:10.053702900 -0500 +@@ -0,0 +1,50 @@ ++/* Clear given exceptions in current floating-point environment. ++ Copyright (C) 1997,98,99,2000,01 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++ ++int ++__feclearexcept (int excepts) ++{ ++ unsigned long int temp; ++ ++ /* Mask out unsupported bits/exceptions. */ ++ excepts &= FE_ALL_EXCEPT; ++ ++ /* Get the current floating point status. */ ++ _FPU_GETCW (temp); ++ ++ /* Clear the relevant bits. */ ++ temp = (temp & ~FE_ALL_EXCEPT) | (temp & FE_ALL_EXCEPT & ~excepts); ++ ++ /* Put the new data in effect. */ ++ _FPU_SETCW (temp); ++ ++ /* Success. */ ++ return 0; ++} ++ ++#include ++#if SHLIB_COMPAT (libm, GLIBC_2_1, GLIBC_2_2) ++strong_alias (__feclearexcept, __old_feclearexcept) ++compat_symbol (libm, __old_feclearexcept, feclearexcept, GLIBC_2_1); ++#endif ++ ++versioned_symbol (libm, __feclearexcept, feclearexcept, GLIBC_2_2); +Index: glibc/sysdeps/arm/eabi/fpu/fegetround.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/fegetround.c 2005-03-22 11:53:10.053702900 -0500 +@@ -0,0 +1,32 @@ ++/* Return current rounding direction. ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++ ++int ++fegetround (void) ++{ ++ unsigned int temp; ++ ++ /* Get the current environment. */ ++ _FPU_GETCW (temp); ++ ++ return temp & FE_TOWARDZERO; ++} +Index: glibc/sysdeps/arm/eabi/fpu/fesetenv.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/fesetenv.c 2005-03-22 12:34:55.521465156 -0500 +@@ -0,0 +1,46 @@ ++/* Install given floating-point environment. ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++ ++int ++__fesetenv (const fenv_t *envp) ++{ ++ unsigned int temp; ++ ++ _FPU_GETCW (temp); ++ temp &= _FPU_RESERVED; ++ ++ if (envp == FE_DFL_ENV) ++ temp |= _FPU_DEFAULT; ++ else if (envp == FE_NOMASK_ENV) ++ temp |= _FPU_IEEE; ++ else ++ temp |= envp->__cw & ~_FPU_RESERVED; ++ ++ _FPU_SETCW (temp); ++ ++ /* Success. */ ++ return 0; ++} ++ ++#include ++libm_hidden_ver (__fesetenv, fesetenv) ++versioned_symbol (libm, __fesetenv, fesetenv, GLIBC_2_2); +Index: glibc/sysdeps/arm/eabi/fpu/fesetround.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/fesetround.c 2005-03-22 11:53:10.053702900 -0500 +@@ -0,0 +1,41 @@ ++/* Set current rounding direction. ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++ ++int ++fesetround (int round) ++{ ++ fpu_control_t temp; ++ ++ switch (round) ++ { ++ case FE_TONEAREST: ++ case FE_UPWARD: ++ case FE_DOWNWARD: ++ case FE_TOWARDZERO: ++ _FPU_GETCW (temp); ++ temp = (temp & ~FE_TOWARDZERO) | round; ++ _FPU_SETCW (temp); ++ return 0; ++ default: ++ return 1; ++ } ++} +Index: glibc/sysdeps/arm/eabi/fpu/fpu_control.h +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/fpu_control.h 2005-03-22 12:34:55.521465156 -0500 +@@ -0,0 +1,47 @@ ++/* FPU control word definitions. ARM VFP version. ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#ifndef _FPU_CONTROL_H ++#define _FPU_CONTROL_H ++ ++/* masking of interrupts */ ++#define _FPU_MASK_IM 0x00000100 /* invalid operation */ ++#define _FPU_MASK_ZM 0x00000200 /* divide by zero */ ++#define _FPU_MASK_OM 0x00000400 /* overflow */ ++#define _FPU_MASK_UM 0x00000800 /* underflow */ ++#define _FPU_MASK_PM 0x00001000 /* inexact */ ++ ++/* Some bits in the FPSCR are not yet defined. They must be preserved when ++ modifying the contents. */ ++#define _FPU_RESERVED 0x0e08e0e0 ++#define _FPU_DEFAULT 0x00000000 ++/* Default + exceptions enabled. */ ++#define _FPU_IEEE (_FPU_DEFAULT | 0x00001f00) ++ ++/* Type of the control word. */ ++typedef unsigned int fpu_control_t; ++ ++/* Macros for accessing the hardware control word. */ ++#define _FPU_GETCW(cw) __asm__ __volatile__ ("fmrx %0, fpscr" : "=r" (cw)) ++#define _FPU_SETCW(cw) __asm__ __volatile__ ("fmxr fpscr, %0" : : "r" (cw)) ++ ++/* Default control word set at startup. */ ++extern fpu_control_t __fpu_control; ++ ++#endif /* _FPU_CONTROL_H */ +Index: glibc/sysdeps/arm/eabi/fpu/setjmp.S +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/setjmp.S 2005-03-22 11:53:10.054702658 -0500 +@@ -0,0 +1,39 @@ ++/* setjmp for ARM. ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#define _SETJMP_H ++#define _ASM ++#include ++ ++ENTRY (__sigsetjmp) ++ mov ip, r0 ++ ++ /* Store the integer registers. */ ++ stmia ip!, {v1-v6, sl, fp, sp, lr} ++ ++ /* Store the VFP registers. */ ++ fstmiax ip!, {d8-d15} ++ /* Store the floating-point status register. */ ++ fmrx r2, fpscr ++ str r2, [ip], #4 ++ ++ /* Make a tail call to __sigjmp_save; it takes the same args. */ ++ B PLTJMP(C_SYMBOL_NAME(__sigjmp_save)) ++END (__sigsetjmp) +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/configure +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/configure 2005-03-22 11:53:10.054702658 -0500 +@@ -0,0 +1,5 @@ ++# This file is generated from configure.in by Autoconf. DO NOT EDIT! ++ # Local configure fragment for sysdeps/unix/sysv/linux/arm/eabi. ++ ++arch_minimum_kernel=2.4.17 ++libc_cv_gcc_unwind_find_fde=no +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/configure.in +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/configure.in 2005-03-22 11:53:10.054702658 -0500 +@@ -0,0 +1,5 @@ ++GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory. ++# Local configure fragment for sysdeps/unix/sysv/linux/arm/eabi. ++ ++arch_minimum_kernel=2.4.17 ++libc_cv_gcc_unwind_find_fde=no +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/epoll_ctl.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/epoll_ctl.c 2005-03-22 11:53:10.054702658 -0500 +@@ -0,0 +1,37 @@ ++/* epoll_ctl wrapper for ARM EABI. ++ Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++ ++#include ++ ++int ++epoll_ctl (int __epfd, int __op, int __fd, struct epoll_event *__event) ++{ ++ struct kernel_epoll_event k_event; ++ ++ k_event.events = __event->events; ++ memcpy (&k_event.data, &__event->data, sizeof (k_event.data)); ++ ++ return INLINE_SYSCALL (epoll_ctl, 4, __epfd, __op, __fd, &k_event); ++} ++ ++libc_hidden_def (epoll_ctl) +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/epoll_wait.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/epoll_wait.c 2005-03-22 11:53:10.055702416 -0500 +@@ -0,0 +1,54 @@ ++/* epoll_ctl wrapper for ARM EABI. ++ Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++ ++#include ++ ++int ++epoll_wait (int __epfd, struct epoll_event *__events, ++ int __maxevents, int __timeout); ++{ ++ struct kernel_epoll_event *k_events; ++ int result; ++ ++ k_events = malloc (sizeof (struct kernel_epoll_event) * __maxevents); ++ if (k_events == NULL) ++ { ++ __set_errno (ENOMEM); ++ return -1; ++ } ++ ++ result = INLINE_SYSCALL (epoll_wait, 4, __epfd, __events, k_events, ++ __timeout); ++ ++ for (i = 0; i < result; i++) ++ { ++ __events[i].events = k_events[i].events; ++ memcpy (&__events[i].data, &k_events[i].data, sizeof (k_events[i].data)); ++ } ++ ++ free (k_events); ++ return result; ++} ++ ++libc_hidden_def (epoll_wait) +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/fstatfs64.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/fstatfs64.c 2005-03-22 11:53:10.055702416 -0500 +@@ -0,0 +1,76 @@ ++/* Return information about the filesystem on which FD resides. ++ Copyright (C) 1996,1997,1998,1999,2000,2003,2005 ++ Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++#include ++ ++/* Defined in statfs64.c. */ ++extern int __no_statfs64 attribute_hidden; ++ ++/* Return information about the filesystem on which FD resides. */ ++int ++__fstatfs64 (int fd, struct statfs64 *buf) ++{ ++#ifdef __NR_fstatfs64 ++# if __ASSUME_STATFS64 == 0 ++ if (! __no_statfs64) ++# endif ++ { ++ /* The EABI structure is the same as the old ABI structure, except ++ that it has four additional bytes of padding - at the end. We can ++ ignore them. */ ++ int result = INLINE_SYSCALL (fstatfs64, 3, fd, sizeof (*buf) - 4, buf); ++ ++# if __ASSUME_STATFS64 == 0 ++ if (result == 0 || errno != ENOSYS) ++# endif ++ return result; ++ ++# if __ASSUME_STATFS64 == 0 ++ __no_statfs64 = 1; ++# endif ++ } ++#endif ++ ++#if __ASSUME_STATFS64 == 0 ++ struct statfs buf32; ++ ++ if (__fstatfs (fd, &buf32) < 0) ++ return -1; ++ ++ buf->f_type = buf32.f_type; ++ buf->f_bsize = buf32.f_bsize; ++ buf->f_blocks = buf32.f_blocks; ++ buf->f_bfree = buf32.f_bfree; ++ buf->f_bavail = buf32.f_bavail; ++ buf->f_files = buf32.f_files; ++ buf->f_ffree = buf32.f_ffree; ++ buf->f_fsid = buf32.f_fsid; ++ buf->f_namelen = buf32.f_namelen; ++ buf->f_frsize = buf32.f_frsize; ++ memcpy (buf->f_spare, buf32.f_spare, sizeof (buf32.f_spare)); ++ ++ return 0; ++#endif ++} ++weak_alias (__fstatfs64, fstatfs64) +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/fxstat64.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/fxstat64.c 2005-03-22 11:53:10.055702416 -0500 +@@ -0,0 +1,100 @@ ++/* fxstat64 using old-style Unix fstat system call. ++ Copyright (C) 1997-2002, 2003, 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++ ++#include ++#include ++#include ++ ++#include "kernel-features.h" ++ ++#if __ASSUME_STAT64_SYSCALL == 0 ++# include ++#endif ++ ++#ifdef __NR_fstat64 ++# if __ASSUME_STAT64_SYSCALL == 0 ++/* The variable is shared between all wrappers around *stat64 calls. */ ++extern int __have_no_stat64; ++# endif ++#endif ++ ++/* Get information about the file FD in BUF. */ ++ ++int ++___fxstat64 (int vers, int fd, struct stat64 *buf) ++{ ++ int result; ++ struct kernel_stat64 kbuf64; ++ ++#if __ASSUME_STAT64_SYSCALL > 0 ++ result = INLINE_SYSCALL (fstat64, 2, fd, CHECK_1 (&kbuf64)); ++ if (result == 0) ++ result = __xstat64_kernel64_conv (vers, &kbuf64, buf); ++# if defined _HAVE_STAT64___ST_INO && __ASSUME_ST_INO_64_BIT == 0 ++ if (__builtin_expect (!result, 1) && buf->__st_ino != (__ino_t) buf->st_ino) ++ buf->st_ino = buf->__st_ino; ++# endif ++ return result; ++#else ++ struct kernel_stat kbuf; ++# if defined __NR_fstat64 ++ if (! __have_no_stat64) ++ { ++ int saved_errno = errno; ++ result = INLINE_SYSCALL (fstat64, 2, fd, CHECK_1 (&kbuf64)); ++ ++ if (result != -1 || errno != ENOSYS) ++ { ++ if (result == 0) ++ result = __xstat64_kernel64_conv (vers, &kbuf64, buf); ++# if defined _HAVE_STAT64___ST_INO && __ASSUME_ST_INO_64_BIT == 0 ++ if (!result && buf->__st_ino != (__ino_t)buf->st_ino) ++ buf->st_ino = buf->__st_ino; ++# endif ++ return result; ++ } ++ ++ __set_errno (saved_errno); ++ __have_no_stat64 = 1; ++ } ++# endif ++ result = INLINE_SYSCALL (fstat, 2, fd, __ptrvalue (&kbuf)); ++ if (result == 0) ++ result = __xstat64_conv (vers, &kbuf, buf); ++ ++ return result; ++#endif ++} ++ ++#include ++ ++#if SHLIB_COMPAT(libc, GLIBC_2_1, GLIBC_2_2) ++versioned_symbol (libc, ___fxstat64, __fxstat64, GLIBC_2_2); ++strong_alias (___fxstat64, __old__fxstat64) ++compat_symbol (libc, __old__fxstat64, __fxstat64, GLIBC_2_1); ++hidden_ver (___fxstat64, __fxstat64) ++#else ++strong_alias (___fxstat64, __fxstat64) ++hidden_def (__fxstat64) ++#endif +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/kernel_stat.h +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/kernel_stat.h 2005-03-22 11:53:10.056702174 -0500 +@@ -0,0 +1,59 @@ ++/* Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++ ++/* kernel_stat64 is just like stat64, except packed. The EABI aligns ++ st_size to an eight byte boundary but the old ABI only aligns it to ++ four. Similarly st_blocks. */ ++struct kernel_stat64 ++ { ++ __dev_t st_dev; /* Device. */ ++ unsigned int __pad1; ++ ++ __ino_t __st_ino; /* 32bit file serial number. */ ++ __mode_t st_mode; /* File mode. */ ++ __nlink_t st_nlink; /* Link count. */ ++ __uid_t st_uid; /* User ID of the file's owner. */ ++ __gid_t st_gid; /* Group ID of the file's group.*/ ++ __dev_t st_rdev; /* Device number, if device. */ ++ unsigned int __pad2; ++ __off64_t st_size; /* Size of file, in bytes. */ ++ __blksize_t st_blksize; /* Optimal block size for I/O. */ ++ ++ __blkcnt64_t st_blocks; /* Number 512-byte blocks allocated. */ ++#ifdef __USE_MISC ++ /* Nanosecond resolution timestamps are stored in a format ++ equivalent to 'struct timespec'. This is the type used ++ whenever possible but the Unix namespace rules do not allow the ++ identifier 'timespec' to appear in the header. ++ Therefore we have to handle the use of this header in strictly ++ standard-compliant sources special. */ ++ struct timespec st_atim; /* Time of last access. */ ++ struct timespec st_mtim; /* Time of last modification. */ ++ struct timespec st_ctim; /* Time of last status change. */ ++#else ++ __time_t st_atime; /* Time of last access. */ ++ unsigned long int st_atimensec; /* Nscecs of last access. */ ++ __time_t st_mtime; /* Time of last modification. */ ++ unsigned long int st_mtimensec; /* Nsecs of last modification. */ ++ __time_t st_ctime; /* Time of last status change. */ ++ unsigned long int st_ctimensec; /* Nsecs of last status change. */ ++#endif ++ __ino64_t st_ino; /* File serial number. */ ++ } __attribute__ ((packed,aligned(4))); +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/lxstat64.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/lxstat64.c 2005-03-22 11:53:10.056702174 -0500 +@@ -0,0 +1,99 @@ ++/* lxstat64 using old-style Unix lstat system call. ++ Copyright (C) 1997-2002, 2003, 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++ ++#include ++#include ++#include ++ ++#include "kernel-features.h" ++ ++#if __ASSUME_STAT64_SYSCALL == 0 ++# include ++#endif ++ ++#ifdef __NR_lstat64 ++# if __ASSUME_STAT64_SYSCALL == 0 ++/* The variable is shared between all wrappers around *stat64 calls. */ ++extern int __have_no_stat64; ++# endif ++#endif ++ ++/* Get information about the file NAME in BUF. */ ++int ++___lxstat64 (int vers, const char *name, struct stat64 *buf) ++{ ++ int result; ++ struct kernel_stat64 kbuf64; ++ ++#ifdef __ASSUME_STAT64_SYSCALL ++ result = INLINE_SYSCALL (lstat64, 2, CHECK_STRING (name), CHECK_1 (&kbuf64)); ++ if (result == 0) ++ result = __xstat64_kernel64_conv (vers, &kbuf64, buf); ++# if defined _HAVE_STAT64___ST_INO && __ASSUME_ST_INO_64_BIT == 0 ++ if (__builtin_expect (!result, 1) && buf->__st_ino != (__ino_t) buf->st_ino) ++ buf->st_ino = buf->__st_ino; ++# endif ++ return result; ++#else ++ struct kernel_stat kbuf; ++# ifdef __NR_lstat64 ++ if (! __have_no_stat64) ++ { ++ int saved_errno = errno; ++ result = INLINE_SYSCALL (lstat64, 2, CHECK_STRING (name), CHECK_1 (&kbuf64)); ++ ++ if (result != -1 || errno != ENOSYS) ++ { ++ if (result == 0) ++ result = __xstat64_kernel64_conv (vers, &kbuf64, buf); ++# if defined _HAVE_STAT64___ST_INO && __ASSUME_ST_INO_64_BIT == 0 ++ if (!result && buf->__st_ino != (__ino_t) buf->st_ino) ++ buf->st_ino = buf->__st_ino; ++# endif ++ return result; ++ } ++ ++ __set_errno (saved_errno); ++ __have_no_stat64 = 1; ++ } ++# endif ++ result = INLINE_SYSCALL (lstat, 2, CHECK_STRING (name), __ptrvalue (&kbuf)); ++ if (result == 0) ++ result = __xstat64_conv (vers, &kbuf, buf); ++ ++ return result; ++#endif ++} ++ ++#include ++ ++#if SHLIB_COMPAT(libc, GLIBC_2_1, GLIBC_2_2) ++versioned_symbol (libc, ___lxstat64, __lxstat64, GLIBC_2_2); ++strong_alias (___lxstat64, __old__lxstat64) ++compat_symbol (libc, __old__lxstat64, __lxstat64, GLIBC_2_1); ++hidden_ver (___lxstat64, __lxstat64) ++#else ++strong_alias (___lxstat64, __lxstat64); ++hidden_def (__lxstat64) ++#endif +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/oldgetrlimit.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/oldgetrlimit.c 2005-03-22 11:53:10.056702174 -0500 +@@ -0,0 +1 @@ ++/* Empty. */ +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/oldsetrlimit.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/oldsetrlimit.c 2005-03-22 11:53:10.056702174 -0500 +@@ -0,0 +1 @@ ++/* Empty. */ +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/semop.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/semop.c 2005-03-22 11:53:10.056702174 -0500 +@@ -0,0 +1,67 @@ ++/* Copyright (C) 1995, 1997, 1998, 1999, 2000, 2005 ++ Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ Contributed by Ulrich Drepper , August 1995. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++struct kernel_sembuf ++{ ++ unsigned short int sem_num; /* semaphore number */ ++ short int sem_op; /* semaphore operation */ ++ short int sem_flg; /* operation flag */ ++ short int __pad1; ++}; ++ ++/* Perform user-defined atomical operation of array of semaphores. */ ++ ++int ++semop (semid, sops, nsops) ++ int semid; ++ struct sembuf *sops; ++ size_t nsops; ++{ ++ struct kernel_sembuf *ksops = alloca (sizeof (sops[0]) * nsops); ++ size_t i; ++ int result; ++ ++ for (i = 0; i < nsops; i++) ++ { ++ ksops[i].sem_num = sops[i].sem_num; ++ ksops[i].sem_op = sops[i].sem_op; ++ ksops[i].sem_flg = sops[i].sem_flg; ++ } ++ ++ result = INLINE_SYSCALL (ipc, 5, IPCOP_semop, ++ semid, (int) nsops, 0, CHECK_N (ksops, nsops)); ++ ++ for (i = 0; i < nsops; i++) ++ { ++ sops[i].sem_num = ksops[i].sem_num; ++ sops[i].sem_op = ksops[i].sem_op; ++ sops[i].sem_flg = ksops[i].sem_flg; ++ } ++ ++ return result; ++} +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/semtimedop.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/semtimedop.c 2005-03-22 11:53:10.057701931 -0500 +@@ -0,0 +1,69 @@ ++/* Copyright (C) 1995, 1997, 1998, 1999, 2000, 2005 ++ Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ Contributed by Ulrich Drepper , August 1995. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++struct kernel_sembuf ++{ ++ unsigned short int sem_num; /* semaphore number */ ++ short int sem_op; /* semaphore operation */ ++ short int sem_flg; /* operation flag */ ++ short int __pad1; ++}; ++ ++/* Perform user-defined atomical operation of array of semaphores. */ ++ ++int ++semtimedop (semid, sops, nsops, timeout) ++ int semid; ++ struct sembuf *sops; ++ size_t nsops; ++ const struct timespec *timeout; ++{ ++ struct kernel_sembuf *ksops = alloca (sizeof (sops[0]) * nsops); ++ size_t i; ++ int result; ++ ++ for (i = 0; i < nsops; i++) ++ { ++ ksops[i].sem_num = sops[i].sem_num; ++ ksops[i].sem_op = sops[i].sem_op; ++ ksops[i].sem_flg = sops[i].sem_flg; ++ } ++ ++ result = INLINE_SYSCALL (ipc, 6, IPCOP_semtimedop, ++ semid, (int) nsops, 0, CHECK_N (sops, nsops), ++ timeout); ++ ++ for (i = 0; i < nsops; i++) ++ { ++ sops[i].sem_num = ksops[i].sem_num; ++ sops[i].sem_op = ksops[i].sem_op; ++ sops[i].sem_flg = ksops[i].sem_flg; ++ } ++ ++ return result; ++} +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/statfs64.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/statfs64.c 2005-03-22 11:53:10.057701931 -0500 +@@ -0,0 +1,77 @@ ++/* Return information about the filesystem on which FILE resides. ++ Copyright (C) 1996-2000,2003,2004,2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++#include ++ ++ ++# if __ASSUME_STATFS64 == 0 ++int __no_statfs64 attribute_hidden; ++#endif ++ ++/* Return information about the filesystem on which FILE resides. */ ++int ++__statfs64 (const char *file, struct statfs64 *buf) ++{ ++#ifdef __NR_statfs64 ++# if __ASSUME_STATFS64 == 0 ++ if (! __no_statfs64) ++# endif ++ { ++ /* The EABI structure is the same as the old ABI structure, except ++ that it has four additional bytes of padding - at the end. We can ++ ignore them. */ ++ int result = INLINE_SYSCALL (statfs64, 3, file, sizeof (*buf) - 4, buf); ++ ++# if __ASSUME_STATFS64 == 0 ++ if (result == 0 || errno != ENOSYS) ++# endif ++ return result; ++ ++# if __ASSUME_STATFS64 == 0 ++ __no_statfs64 = 1; ++# endif ++ } ++#endif ++ ++#if __ASSUME_STATFS64 == 0 ++ struct statfs buf32; ++ ++ if (__statfs (file, &buf32) < 0) ++ return -1; ++ ++ buf->f_type = buf32.f_type; ++ buf->f_bsize = buf32.f_bsize; ++ buf->f_blocks = buf32.f_blocks; ++ buf->f_bfree = buf32.f_bfree; ++ buf->f_bavail = buf32.f_bavail; ++ buf->f_files = buf32.f_files; ++ buf->f_ffree = buf32.f_ffree; ++ buf->f_fsid = buf32.f_fsid; ++ buf->f_namelen = buf32.f_namelen; ++ buf->f_frsize = buf32.f_frsize; ++ memcpy (buf->f_spare, buf32.f_spare, sizeof (buf32.f_spare)); ++ ++ return 0; ++#endif ++} ++weak_alias (__statfs64, statfs64) +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/uname.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/uname.c 2005-03-22 11:53:10.057701931 -0500 +@@ -0,0 +1,43 @@ ++/* Copyright (C) 2005 ++ Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++#include ++ ++/* The kernel's struct utsname is two bytes larger than a userland struct ++ utsname due to the APCS structure size boundary. */ ++ ++int ++__uname (struct utsname *__name) ++{ ++ char buf[sizeof (struct utsname) + 2]; ++ int result = INLINE_SYSCALL (uname, 1, buf); ++ ++ if (result == 0) ++ memcpy (__name, buf, sizeof (struct utsname)); ++ ++ return result; ++} ++ ++libc_hidden_def (__uname) ++strong_alias (__uname, uname) ++libc_hidden_weak (uname) +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/xstat64.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/xstat64.c 2005-03-22 11:53:10.058701689 -0500 +@@ -0,0 +1,103 @@ ++/* xstat64 using old-style Unix stat system call. ++ Copyright (C) 1991, 1995-2002, 2003, 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++#include ++ ++#include ++#include ++#include ++ ++#include "kernel-features.h" ++ ++#if __ASSUME_STAT64_SYSCALL == 0 ++# include ++#endif ++ ++#ifdef __NR_stat64 ++# if __ASSUME_STAT64_SYSCALL == 0 ++/* The variable is shared between all wrappers around *stat64 calls. ++ This is the definition. */ ++int __have_no_stat64; ++# endif ++#endif ++ ++/* Get information about the file NAME in BUF. */ ++ ++int ++___xstat64 (int vers, const char *name, struct stat64 *buf) ++{ ++ int result; ++ struct kernel_stat64 kbuf64; ++ ++#if __ASSUME_STAT64_SYSCALL > 0 ++ result = INLINE_SYSCALL (stat64, 2, CHECK_STRING (name), CHECK_1 (&kbuf64)); ++ if (result == 0) ++ result = __xstat64_kernel64_conv (vers, &kbuf64, buf); ++# if defined _HAVE_STAT64___ST_INO && __ASSUME_ST_INO_64_BIT == 0 ++ if (__builtin_expect (!result, 1) && buf->__st_ino != (__ino_t) buf->st_ino) ++ buf->st_ino = buf->__st_ino; ++# endif ++ return result; ++#else ++ struct kernel_stat kbuf; ++# if defined __NR_stat64 ++ if (! __have_no_stat64) ++ { ++ int saved_errno = errno; ++ result = INLINE_SYSCALL (stat64, 2, CHECK_STRING (name), CHECK_1 (&kbuf64)); ++ ++ if (result != -1 || errno != ENOSYS) ++ { ++ if (result == 0) ++ result = __xstat64_kernel64_conv (vers, &kbuf64, buf); ++# if defined _HAVE_STAT64___ST_INO && __ASSUME_ST_INO_64_BIT == 0 ++ if (!result && buf->__st_ino != (__ino_t) buf->st_ino) ++ buf->st_ino = buf->__st_ino; ++# endif ++ return result; ++ } ++ ++ __set_errno (saved_errno); ++ __have_no_stat64 = 1; ++ } ++# endif ++ ++ result = INLINE_SYSCALL (stat, 2, CHECK_STRING (name), __ptrvalue (&kbuf)); ++ if (result == 0) ++ result = __xstat64_conv (vers, &kbuf, buf); ++ ++ return result; ++#endif ++} ++ ++ ++#include ++ ++#if SHLIB_COMPAT(libc, GLIBC_2_1, GLIBC_2_2) ++versioned_symbol (libc, ___xstat64, __xstat64, GLIBC_2_2); ++strong_alias (___xstat64, __old__xstat64) ++compat_symbol (libc, __old__xstat64, __xstat64, GLIBC_2_1); ++hidden_ver (___xstat64, __xstat64) ++#else ++strong_alias (___xstat64, __xstat64) ++hidden_def (__xstat64) ++#endif +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/xstatconv.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/xstatconv.c 2005-03-22 11:53:10.058701689 -0500 +@@ -0,0 +1,341 @@ ++/* Convert between the kernel's `struct stat' format, and libc's. ++ Copyright (C) 1991,1995-1997,2000,2002,2003 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++ ++#ifdef STAT_IS_KERNEL_STAT ++ ++/* Dummy. */ ++struct kernel_stat; ++ ++#else ++ ++#include ++ ++ ++#if !defined __ASSUME_STAT64_SYSCALL || defined XSTAT_IS_XSTAT64 ++int ++__xstat_conv (int vers, struct kernel_stat *kbuf, void *ubuf) ++{ ++ switch (vers) ++ { ++ case _STAT_VER_KERNEL: ++ /* Nothing to do. The struct is in the form the kernel expects. ++ We should have short-circuted before we got here, but for ++ completeness... */ ++ *(struct kernel_stat *) ubuf = *kbuf; ++ break; ++ ++ case _STAT_VER_LINUX: ++ { ++ struct stat *buf = ubuf; ++ ++ /* Convert to current kernel version of `struct stat'. */ ++ buf->st_dev = kbuf->st_dev; ++#ifdef _HAVE_STAT___PAD1 ++ buf->__pad1 = 0; ++#endif ++ buf->st_ino = kbuf->st_ino; ++ buf->st_mode = kbuf->st_mode; ++ buf->st_nlink = kbuf->st_nlink; ++ buf->st_uid = kbuf->st_uid; ++ buf->st_gid = kbuf->st_gid; ++ buf->st_rdev = kbuf->st_rdev; ++#ifdef _HAVE_STAT___PAD2 ++ buf->__pad2 = 0; ++#endif ++ buf->st_size = kbuf->st_size; ++ buf->st_blksize = kbuf->st_blksize; ++ buf->st_blocks = kbuf->st_blocks; ++#ifdef _HAVE_STAT_NSEC ++ buf->st_atim.tv_sec = kbuf->st_atim.tv_sec; ++ buf->st_atim.tv_nsec = kbuf->st_atim.tv_nsec; ++ buf->st_mtim.tv_sec = kbuf->st_mtim.tv_sec; ++ buf->st_mtim.tv_nsec = kbuf->st_mtim.tv_nsec; ++ buf->st_ctim.tv_sec = kbuf->st_ctim.tv_sec; ++ buf->st_ctim.tv_nsec = kbuf->st_ctim.tv_nsec; ++#else ++ buf->st_atime = kbuf->st_atime; ++ buf->st_mtime = kbuf->st_mtime; ++ buf->st_ctime = kbuf->st_ctime; ++#endif ++#ifdef _HAVE_STAT___UNUSED1 ++ buf->__unused1 = 0; ++#endif ++#ifdef _HAVE_STAT___UNUSED2 ++ buf->__unused2 = 0; ++#endif ++#ifdef _HAVE_STAT___UNUSED3 ++ buf->__unused3 = 0; ++#endif ++#ifdef _HAVE_STAT___UNUSED4 ++ buf->__unused4 = 0; ++#endif ++#ifdef _HAVE_STAT___UNUSED5 ++ buf->__unused5 = 0; ++#endif ++ } ++ break; ++ ++ default: ++ __set_errno (EINVAL); ++ return -1; ++ } ++ ++ return 0; ++} ++#endif ++ ++int ++__xstat64_conv (int vers, struct kernel_stat *kbuf, void *ubuf) ++{ ++#ifdef XSTAT_IS_XSTAT64 ++ return __xstat_conv (vers, kbuf, ubuf); ++#else ++ switch (vers) ++ { ++ case _STAT_VER_LINUX: ++ { ++ struct stat64 *buf = ubuf; ++ ++ /* Convert to current kernel version of `struct stat64'. */ ++ buf->st_dev = kbuf->st_dev; ++#ifdef _HAVE_STAT64___PAD1 ++ buf->__pad1 = 0; ++#endif ++ buf->st_ino = kbuf->st_ino; ++#ifdef _HAVE_STAT64___ST_INO ++ buf->__st_ino = kbuf->st_ino; ++#endif ++ buf->st_mode = kbuf->st_mode; ++ buf->st_nlink = kbuf->st_nlink; ++ buf->st_uid = kbuf->st_uid; ++ buf->st_gid = kbuf->st_gid; ++ buf->st_rdev = kbuf->st_rdev; ++#ifdef _HAVE_STAT64___PAD2 ++ buf->__pad2 = 0; ++#endif ++ buf->st_size = kbuf->st_size; ++ buf->st_blksize = kbuf->st_blksize; ++ buf->st_blocks = kbuf->st_blocks; ++#ifdef _HAVE_STAT64_NSEC ++ buf->st_atim.tv_sec = kbuf->st_atim.tv_sec; ++ buf->st_atim.tv_nsec = kbuf->st_atim.tv_nsec; ++ buf->st_mtim.tv_sec = kbuf->st_mtim.tv_sec; ++ buf->st_mtim.tv_nsec = kbuf->st_mtim.tv_nsec; ++ buf->st_ctim.tv_sec = kbuf->st_ctim.tv_sec; ++ buf->st_ctim.tv_nsec = kbuf->st_ctim.tv_nsec; ++#else ++ buf->st_atime = kbuf->st_atime; ++ buf->st_mtime = kbuf->st_mtime; ++ buf->st_ctime = kbuf->st_ctime; ++#endif ++#ifdef _HAVE_STAT64___UNUSED1 ++ buf->__unused1 = 0; ++#endif ++#ifdef _HAVE_STAT64___UNUSED2 ++ buf->__unused2 = 0; ++#endif ++#ifdef _HAVE_STAT64___UNUSED3 ++ buf->__unused3 = 0; ++#endif ++#ifdef _HAVE_STAT64___UNUSED4 ++ buf->__unused4 = 0; ++#endif ++#ifdef _HAVE_STAT64___UNUSED5 ++ buf->__unused5 = 0; ++#endif ++ } ++ break; ++ ++ /* If struct stat64 is different from struct stat then ++ _STAT_VER_KERNEL does not make sense. */ ++ case _STAT_VER_KERNEL: ++ default: ++ __set_errno (EINVAL); ++ return -1; ++ } ++ ++ return 0; ++#endif ++} ++ ++int ++__xstat32_conv (int vers, void *kbuf_, struct stat *buf) ++{ ++ struct kernel_stat64 *kbuf = kbuf_; ++ ++ switch (vers) ++ { ++ case _STAT_VER_LINUX: ++ { ++ /* Convert current kernel version of `struct stat64' to ++ `struct stat'. */ ++ buf->st_dev = kbuf->st_dev; ++#ifdef _HAVE_STAT___PAD1 ++ buf->__pad1 = 0; ++#endif ++#ifdef _HAVE_STAT64___ST_INO ++# if __ASSUME_ST_INO_64_BIT == 0 ++ if (kbuf->st_ino == 0) ++ buf->st_ino = kbuf->__st_ino; ++ else ++# endif ++ { ++ buf->st_ino = kbuf->st_ino; ++ if (sizeof (buf->st_ino) != sizeof (kbuf->st_ino) ++ && buf->st_ino != kbuf->st_ino) ++ { ++ __set_errno (EOVERFLOW); ++ return -1; ++ } ++ } ++#else ++ buf->st_ino = kbuf->st_ino; ++ if (sizeof (buf->st_ino) != sizeof (kbuf->st_ino) ++ && buf->st_ino != kbuf->st_ino) ++ { ++ __set_errno (EOVERFLOW); ++ return -1; ++ } ++#endif ++ buf->st_mode = kbuf->st_mode; ++ buf->st_nlink = kbuf->st_nlink; ++ buf->st_uid = kbuf->st_uid; ++ buf->st_gid = kbuf->st_gid; ++ buf->st_rdev = kbuf->st_rdev; ++#ifdef _HAVE_STAT___PAD2 ++ buf->__pad2 = 0; ++#endif ++ buf->st_size = kbuf->st_size; ++ /* Check for overflow. */ ++ if (sizeof (buf->st_size) != sizeof (kbuf->st_size) ++ && buf->st_size != kbuf->st_size) ++ { ++ __set_errno (EOVERFLOW); ++ return -1; ++ } ++ buf->st_blksize = kbuf->st_blksize; ++ buf->st_blocks = kbuf->st_blocks; ++ /* Check for overflow. */ ++ if (sizeof (buf->st_blocks) != sizeof (kbuf->st_blocks) ++ && buf->st_blocks != kbuf->st_blocks) ++ { ++ __set_errno (EOVERFLOW); ++ return -1; ++ } ++#ifdef _HAVE_STAT_NSEC ++ buf->st_atim.tv_sec = kbuf->st_atim.tv_sec; ++ buf->st_atim.tv_nsec = kbuf->st_atim.tv_nsec; ++ buf->st_mtim.tv_sec = kbuf->st_mtim.tv_sec; ++ buf->st_mtim.tv_nsec = kbuf->st_mtim.tv_nsec; ++ buf->st_ctim.tv_sec = kbuf->st_ctim.tv_sec; ++ buf->st_ctim.tv_nsec = kbuf->st_ctim.tv_nsec; ++#else ++ buf->st_atime = kbuf->st_atime; ++ buf->st_mtime = kbuf->st_mtime; ++ buf->st_ctime = kbuf->st_ctime; ++#endif ++ ++#ifdef _HAVE_STAT___UNUSED1 ++ buf->__unused1 = 0; ++#endif ++#ifdef _HAVE_STAT___UNUSED2 ++ buf->__unused2 = 0; ++#endif ++#ifdef _HAVE_STAT___UNUSED3 ++ buf->__unused3 = 0; ++#endif ++#ifdef _HAVE_STAT___UNUSED4 ++ buf->__unused4 = 0; ++#endif ++#ifdef _HAVE_STAT___UNUSED5 ++ buf->__unused5 = 0; ++#endif ++ } ++ break; ++ ++ /* If struct stat64 is different from struct stat then ++ _STAT_VER_KERNEL does not make sense. */ ++ case _STAT_VER_KERNEL: ++ default: ++ __set_errno (EINVAL); ++ return -1; ++ } ++ ++ return 0; ++} ++ ++int ++__xstat64_kernel64_conv (int vers, void *kbuf_, struct stat64 *buf) ++{ ++ struct kernel_stat64 *kbuf = kbuf_; ++ ++ switch (vers) ++ { ++ case _STAT_VER_LINUX: ++ { ++ /* Convert current kernel version of `struct stat64' to ++ user version of `struct stat64'. */ ++ buf->st_dev = kbuf->st_dev; ++#ifdef _HAVE_STAT64___PAD1 ++ buf->__pad1 = kbuf->__pad1; ++#endif ++#ifdef _HAVE_STAT64___ST_INO ++ buf->__st_ino = kbuf->__st_ino; ++#endif ++ buf->st_mode = kbuf->st_mode; ++ buf->st_nlink = kbuf->st_nlink; ++ buf->st_uid = kbuf->st_uid; ++ buf->st_gid = kbuf->st_gid; ++ buf->st_rdev = kbuf->st_rdev; ++#ifdef _HAVE_STAT64___PAD2 ++ buf->__pad2 = kbuf->__pad2; ++#endif ++ buf->st_size = kbuf->st_size; ++ buf->st_blksize = kbuf->st_blksize; ++ buf->st_blocks = kbuf->st_blocks; ++#ifdef _HAVE_STAT64_NSEC ++ buf->st_atim.tv_sec = kbuf->st_atim.tv_sec; ++ buf->st_atim.tv_nsec = kbuf->st_atim.tv_nsec; ++ buf->st_mtim.tv_sec = kbuf->st_mtim.tv_sec; ++ buf->st_mtim.tv_nsec = kbuf->st_mtim.tv_nsec; ++ buf->st_ctim.tv_sec = kbuf->st_ctim.tv_sec; ++ buf->st_ctim.tv_nsec = kbuf->st_ctim.tv_nsec; ++#else ++ buf->st_atime = kbuf->st_atime; ++ buf->st_mtime = kbuf->st_mtime; ++ buf->st_ctime = kbuf->st_ctime; ++#endif ++ buf->st_ino = kbuf->st_ino; ++ } ++ break; ++ ++ case _STAT_VER_KERNEL: ++ default: ++ __set_errno (EINVAL); ++ return -1; ++ } ++ ++ return 0; ++} ++ ++#endif +Index: glibc/sysdeps/unix/sysv/linux/arm/eabi/xstatconv.h +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/unix/sysv/linux/arm/eabi/xstatconv.h 2005-03-22 11:53:10.058701689 -0500 +@@ -0,0 +1,28 @@ ++/* Convert between the kernel's `struct stat' format, and libc's. ++ Copyright (C) 1991,1995-1997,2000,2002,2003 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include "kernel-features.h" ++ ++#ifndef STAT_IS_KERNEL_STAT ++extern int __xstat_conv (int vers, struct kernel_stat *kbuf, void *ubuf); ++extern int __xstat64_conv (int vers, struct kernel_stat *kbuf, void *ubuf); ++#endif ++extern int __xstat32_conv (int vers, void *kbuf, struct stat *buf); ++extern int __xstat64_kernel64_conv (int vers, struct kernel_stat64 *kbuf, ++ struct stat64 *buf); +Index: glibc/sysdeps/arm/eabi/fpu/fraiseexcpt.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/fraiseexcpt.c 2005-03-22 12:34:55.522464918 -0500 +@@ -0,0 +1,67 @@ ++/* Raise given exceptions. ++ Copyright (C) 2004 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++#include ++ ++int ++feraiseexcept (int excepts) ++{ ++ float dummy; ++ int fpscr; ++ ++ /* Raise exceptions represented by EXPECTS. But we must raise only ++ one signal at a time. It is important that if the overflow/underflow ++ exception and the inexact exception are given at the same time, ++ the overflow/underflow exception follows the inexact exception. After ++ each exception we read from the fpscr, to force the exception to be ++ raised immediately. */ ++ ++ /* First: invalid exception. */ ++ if (FE_INVALID & excepts) ++ __asm__ __volatile__ ("fdivs %0,%2,%3\n\tfmrx %1, fpscr" ++ : "=w" (dummy), "=r" (fpscr) : "w" (0.0f), "w" (0.0f) ); ++ ++ /* Next: division by zero. */ ++ if (FE_DIVBYZERO & excepts) ++ __asm__ __volatile__ ("fdivs %0,%2,%3\n\tfmrx %1, fpscr" ++ : "=w" (dummy), "=r" (fpscr) : "w" (1.0f), "w" (0.0f) ); ++ ++ /* Next: overflow. */ ++ if (FE_OVERFLOW & excepts) ++ /* There's no way to raise overflow without also raising inexact. */ ++ __asm__ __volatile__ ("fadds %0,%2,%3\n\tfmrx %1, fpscr" ++ : "=w" (dummy), "=r" (fpscr) : "w" (FLT_MAX), "w" (1.0e32f) ); ++ ++ /* Next: underflow. */ ++ if (FE_UNDERFLOW & excepts) ++ __asm__ __volatile__ ("fdivs %0,%2,%3\n\tfmrx %1, fpscr" ++ : "=w" (dummy), "=r" (fpscr) : "w" (FLT_MIN), "w" (3.0f) ); ++ ++ /* Last: inexact. */ ++ if (FE_INEXACT & excepts) ++ __asm__ __volatile__ ("fdivs %0,%2,%3\n\tfmrx %1, fpscr" ++ : "=w" (dummy), "=r" (fpscr) : "w" (2.0f), "w" (3.0f) ); ++ ++ /* Success. */ ++ return 0; ++} ++ ++libm_hidden_def (feraiseexcept) +Index: glibc/sysdeps/arm/eabi/fpu/feholdexcpt.c +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/eabi/fpu/feholdexcpt.c 2005-03-22 12:34:55.521465156 -0500 +@@ -0,0 +1,41 @@ ++/* Store current floating-point environment and clear exceptions. ++ Copyright (C) 1997, 1998, 1999 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#include ++#include ++ ++int ++feholdexcept (fenv_t *envp) ++{ ++ unsigned long int temp; ++ ++ /* Store the environment. */ ++ _FPU_GETCW(temp); ++ envp->__cw = temp; ++ ++ /* Now set all exceptions to non-stop. */ ++ temp &= ~(FE_ALL_EXCEPT << FE_EXCEPT_SHIFT); ++ ++ /* And clear all exception flags. */ ++ temp &= ~FE_ALL_EXCEPT; ++ ++ _FPU_SETCW(temp); ++ ++ return 0; ++} + diff --git a/meta/packages/glibc/glibc-cvs/eabi-patch-3 b/meta/packages/glibc/glibc-cvs/eabi-patch-3 new file mode 100644 index 000000000..9bd549ec2 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/eabi-patch-3 @@ -0,0 +1,430 @@ +From libc-alpha-return-17228-listarch-libc-alpha=sources dot redhat dot com at sources dot redhat dot com Tue Mar 22 16:08:31 2005 +Return-Path: +Delivered-To: listarch-libc-alpha at sources dot redhat dot com +Received: (qmail 20972 invoked by alias); 22 Mar 2005 16:08:29 -0000 +Mailing-List: contact libc-alpha-help at sources dot redhat dot com; run by ezmlm +Precedence: bulk +List-Subscribe: +List-Archive: +List-Post: +List-Help: , +Sender: libc-alpha-owner at sources dot redhat dot com +Delivered-To: mailing list libc-alpha at sources dot redhat dot com +Received: (qmail 20165 invoked from network); 22 Mar 2005 16:08:06 -0000 +Received: from unknown (HELO nevyn.them.org) (66.93.172.17) + by sourceware dot org with SMTP; 22 Mar 2005 16:08:06 -0000 +Received: from drow by nevyn.them.org with local (Exim 4.50 #1 (Debian)) + id 1DDlvX-0006tE-Bh; Tue, 22 Mar 2005 11:08:19 -0500 +Date: Tue, 22 Mar 2005 11:08:19 -0500 +From: Daniel Jacobowitz +To: libc-alpha at sources dot redhat dot com +Cc: Phil Blundell +Subject: ARM EABI support - changes to existing ARM code +Message-ID: <20050322160819.GA26216@nevyn.them.org> +Mail-Followup-To: libc-alpha at sources dot redhat dot com, + Phil Blundell +Mime-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +Content-Disposition: inline +User-Agent: Mutt/1.5.6+20040907i + +This patch updates the common ARM files for EABI support. The changes are: + - Old ARM ABI targets always use FPA (mixed-endian) byte ordering. EABI + targets always use VFP byte ordering for doubles, which is standard + ieee754 layout. Removing the arm-specific ieee754.h doesn't break FPA; + it was a specialized version of the common header, which handles FPA + but also handles VFP. + - The stack needs to be aligned to eight bytes instead of just four, + including in mmap2 and when shifting _dl_argv. + - We need some markers around _start to indicate end-of-stack for the + unwinder - ARM EABI does not use either SJLJ exceptions or DWARF-2 + exceptions. It uses a table based format which seems to be not + quite completely unlike DWARF-2. + +Do these changes look OK? + +-- +Daniel Jacobowitz +CodeSourcery, LLC + +2005-03-22 Daniel Jacobowitz + + * sysdeps/arm/bits/endian.h (__FLOAT_WORD_ORDER): Handle VFP. + * sysdeps/arm/gmp-mparam.h (IEEE_DOUBLE_BIG_ENDIAN, + IEEE_DOUBLE_MIXED_ENDIAN): Handle big-endian and VFP. + * sysdeps/arm/ieee754.h: Remove. + + * sysdeps/arm/dl-machine.h (_dl_start_user): Align the stack to eight + bytes even when shifting arguments. + * sysdeps/arm/dl-sysdep.h: New file. + + * sysdeps/arm/elf/start.S (_start): If not using SJLJ exceptions, include + EABI unwind markers to terminate unwinding. + + * sysdeps/unix/sysv/linux/arm/mmap64.S: Handle big-endian byte ordering + and EABI stack layout. + +Index: glibc/sysdeps/arm/bits/endian.h +=================================================================== +--- glibc.orig/sysdeps/arm/bits/endian.h 2005-03-22 10:26:27.092978200 -0500 ++++ glibc/sysdeps/arm/bits/endian.h 2005-03-22 10:27:39.457490903 -0500 +@@ -9,4 +9,9 @@ + #else + #define __BYTE_ORDER __LITTLE_ENDIAN + #endif ++ ++#ifdef __VFP_FP__ ++#define __FLOAT_WORD_ORDER __BYTE_ORDER ++#else + #define __FLOAT_WORD_ORDER __BIG_ENDIAN ++#endif +Index: glibc/sysdeps/arm/dl-machine.h +=================================================================== +--- glibc.orig/sysdeps/arm/dl-machine.h 2005-03-22 10:26:27.092978200 -0500 ++++ glibc/sysdeps/arm/dl-machine.h 2005-03-22 10:27:39.457490903 -0500 +@@ -156,22 +156,19 @@ _dl_start_user:\n\ + add sl, pc, sl\n\ + .L_GOT_GOT:\n\ + ldr r4, [sl, r4]\n\ +- @ get the original arg count\n\ +- ldr r1, [sp]\n\ + @ save the entry point in another register\n\ + mov r6, r0\n\ +- @ adjust the stack pointer to skip the extra args\n\ +- add sp, sp, r4, lsl #2\n\ +- @ subtract _dl_skip_args from original arg count\n\ +- sub r1, r1, r4\n\ ++ @ get the original arg count\n\ ++ ldr r1, [sp]\n\ + @ get the argv address\n\ + add r2, sp, #4\n\ +- @ store the new argc in the new stack location\n\ +- str r1, [sp]\n\ ++ @ Fix up the stack if necessary.\n\ ++ cmp r4, #0\n\ ++ bne .L_fixup_stack\n\ ++.L_done_fixup:\n\ + @ compute envp\n\ + add r3, r2, r1, lsl #2\n\ + add r3, r3, #4\n\ +-\n\ + @ now we call _dl_init\n\ + ldr r0, .L_LOADED\n\ + ldr r0, [sl, r0]\n\ +@@ -182,12 +179,45 @@ _dl_start_user:\n\ + add r0, sl, r0\n\ + @ jump to the user_s entry point\n\ + " BX(r6) "\n\ ++\n\ ++ @ iWMMXt and EABI targets require the stack to be eight byte\n\ ++ @ aligned - shuffle arguments etc.\n\ ++.L_fixup_stack:\n\ ++ @ subtract _dl_skip_args from original arg count\n\ ++ sub r1, r1, r4\n\ ++ @ store the new argc in the new stack location\n\ ++ str r1, [sp]\n\ ++ @ find the first unskipped argument\n\ ++ mov r3, r2\n\ ++ add r4, r2, r4, lsl #2\n\ ++ @ shuffle argv down\n\ ++1: ldr r5, [r4], #4\n\ ++ str r5, [r3], #4\n\ ++ cmp r5, #0\n\ ++ bne 1b\n\ ++ @ shuffle envp down\n\ ++1: ldr r5, [r4], #4\n\ ++ str r5, [r3], #4\n\ ++ cmp r5, #0\n\ ++ bne 1b\n\ ++ @ shuffle auxv down\n\ ++1: ldmia r4!, {r0, r5}\n\ ++ stmia r3!, {r0, r5}\n\ ++ cmp r0, #0\n\ ++ bne 1b\n\ ++ @ Update _dl_argv\n\ ++ ldr r3, .L_ARGV\n\ ++ str r2, [sl, r3]\n\ ++ b .L_done_fixup\n\ ++\n\ + .L_GET_GOT:\n\ + .word _GLOBAL_OFFSET_TABLE_ - .L_GOT_GOT - 4\n\ + .L_SKIP_ARGS:\n\ + .word _dl_skip_args(GOTOFF)\n\ + .L_FINI_PROC:\n\ + .word _dl_fini(GOTOFF)\n\ ++.L_ARGV:\n\ ++ .word _dl_argv(GOTOFF)\n\ + .L_LOADED:\n\ + .word _rtld_local(GOTOFF)\n\ + .previous\n\ +Index: glibc/sysdeps/arm/dl-sysdep.h +=================================================================== +--- /dev/null 1970-01-01 00:00:00.000000000 +0000 ++++ glibc/sysdeps/arm/dl-sysdep.h 2005-03-22 10:27:39.458490675 -0500 +@@ -0,0 +1,41 @@ ++/* System-specific settings for dynamic linker code. ARM version. ++ Copyright (C) 2004, 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++#ifndef _DL_SYSDEP_H ++#define _DL_SYSDEP_H 1 ++ ++/* This macro must be defined to either 0 or 1. ++ ++ If 1, then an errno global variable hidden in ld.so will work right with ++ all the errno-using libc code compiled for ld.so, and there is never a ++ need to share the errno location with libc. This is appropriate only if ++ all the libc functions that ld.so uses are called without PLT and always ++ get the versions linked into ld.so rather than the libc ones. */ ++ ++#ifdef IS_IN_rtld ++# define RTLD_PRIVATE_ERRNO 1 ++#else ++# define RTLD_PRIVATE_ERRNO 0 ++#endif ++ ++/* _dl_argv cannot be attribute_relro, because _dl_start_user ++ might write into it after _dl_start returns. */ ++#define DL_ARGV_NOT_RELRO 1 ++ ++#endif /* dl-sysdep.h */ +Index: glibc/sysdeps/arm/elf/start.S +=================================================================== +--- glibc.orig/sysdeps/arm/elf/start.S 2005-03-22 10:26:27.096977288 -0500 ++++ glibc/sysdeps/arm/elf/start.S 2005-03-22 11:00:35.178522707 -0500 +@@ -1,5 +1,6 @@ + /* Startup code for ARM & ELF +- Copyright (C) 1995, 1996, 1997, 1998, 2001, 2002 Free Software Foundation, Inc. ++ Copyright (C) 1995, 1996, 1997, 1998, 2001, 2002, 2005 ++ Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or +@@ -62,6 +63,10 @@ + .globl _start + .type _start,#function + _start: ++#if !defined(__USING_SJLJ_EXCEPTIONS__) ++ /* Protect against unhandled exceptions. */ ++ .fnstart ++#endif + /* Fetch address of fini */ + ldr ip, =__libc_csu_fini + +@@ -93,6 +98,11 @@ _start: + /* should never get here....*/ + bl abort + ++#if !defined(__USING_SJLJ_EXCEPTIONS__) ++ .cantunwind ++ .fnend ++#endif ++ + /* Define a symbol for the first piece of initialized data. */ + .data + .globl __data_start +Index: glibc/sysdeps/arm/gmp-mparam.h +=================================================================== +--- glibc.orig/sysdeps/arm/gmp-mparam.h 2005-03-22 10:26:27.092978200 -0500 ++++ glibc/sysdeps/arm/gmp-mparam.h 2005-03-22 11:00:42.795683773 -0500 +@@ -1,6 +1,6 @@ + /* gmp-mparam.h -- Compiler/machine parameter header file. + +-Copyright (C) 1991, 1993, 1994, 1995 Free Software Foundation, Inc. ++Copyright (C) 1991, 1993, 1994, 1995, 2005 Free Software Foundation, Inc. + + This file is part of the GNU MP Library. + +@@ -26,5 +26,13 @@ MA 02111-1307, USA. */ + #define BITS_PER_SHORTINT 16 + #define BITS_PER_CHAR 8 + +-#define IEEE_DOUBLE_BIG_ENDIAN 0 +-#define IEEE_DOUBLE_MIXED_ENDIAN 1 ++#if defined(__ARMEB__) ++# define IEEE_DOUBLE_MIXED_ENDIAN 0 ++# define IEEE_DOUBLE_BIG_ENDIAN 1 ++#elif defined(__VFP_FP__) ++# define IEEE_DOUBLE_MIXED_ENDIAN 0 ++# define IEEE_DOUBLE_BIG_ENDIAN 0 ++#else ++# define IEEE_DOUBLE_BIG_ENDIAN 0 ++# define IEEE_DOUBLE_MIXED_ENDIAN 1 ++#endif +Index: glibc/sysdeps/arm/ieee754.h +=================================================================== +--- glibc.orig/sysdeps/arm/ieee754.h 2005-03-22 10:26:27.092978200 -0500 ++++ /dev/null 1970-01-01 00:00:00.000000000 +0000 +@@ -1,115 +0,0 @@ +-/* Copyright (C) 1992, 1995, 1996, 1998 Free Software Foundation, Inc. +- This file is part of the GNU C Library. +- +- The GNU C Library is free software; you can redistribute it and/or +- modify it under the terms of the GNU Lesser General Public +- License as published by the Free Software Foundation; either +- version 2.1 of the License, or (at your option) any later version. +- +- The GNU C Library is distributed in the hope that it will be useful, +- but WITHOUT ANY WARRANTY; without even the implied warranty of +- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +- Lesser General Public License for more details. +- +- You should have received a copy of the GNU Lesser General Public +- License along with the GNU C Library; if not, write to the Free +- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA +- 02111-1307 USA. */ +- +-#ifndef _IEEE754_H +- +-#define _IEEE754_H 1 +-#include +- +-#include +- +-__BEGIN_DECLS +- +-union ieee754_float +- { +- float f; +- +- /* This is the IEEE 754 single-precision format. */ +- struct +- { +- unsigned int mantissa:23; +- unsigned int exponent:8; +- unsigned int negative:1; +- } ieee; +- +- /* This format makes it easier to see if a NaN is a signalling NaN. */ +- struct +- { +- unsigned int mantissa:22; +- unsigned int quiet_nan:1; +- unsigned int exponent:8; +- unsigned int negative:1; +- } ieee_nan; +- }; +- +-#define IEEE754_FLOAT_BIAS 0x7f /* Added to exponent. */ +- +- +-union ieee754_double +- { +- double d; +- +- /* This is the IEEE 754 double-precision format. */ +- struct +- { +- unsigned int mantissa0:20; +- unsigned int exponent:11; +- unsigned int negative:1; +- unsigned int mantissa1:32; +- } ieee; +- +- /* This format makes it easier to see if a NaN is a signalling NaN. */ +- struct +- { +- unsigned int mantissa0:19; +- unsigned int quiet_nan:1; +- unsigned int exponent:11; +- unsigned int negative:1; +- unsigned int mantissa1:32; +- } ieee_nan; +- }; +- +-#define IEEE754_DOUBLE_BIAS 0x3ff /* Added to exponent. */ +- +- +-/* The following two structures are correct for `new' floating point systems but +- wrong for the old FPPC. The only solution seems to be to avoid their use on +- old hardware. */ +- +-union ieee854_long_double +- { +- long double d; +- +- /* This is the IEEE 854 double-extended-precision format. */ +- struct +- { +- unsigned int exponent:15; +- unsigned int empty:16; +- unsigned int negative:1; +- unsigned int mantissa1:32; +- unsigned int mantissa0:32; +- } ieee; +- +- /* This is for NaNs in the IEEE 854 double-extended-precision format. */ +- struct +- { +- unsigned int exponent:15; +- unsigned int empty:16; +- unsigned int negative:1; +- unsigned int mantissa1:32; +- unsigned int mantissa0:30; +- unsigned int quiet_nan:1; +- unsigned int one:1; +- } ieee_nan; +- }; +- +-#define IEEE854_LONG_DOUBLE_BIAS 0x3fff +- +-__END_DECLS +- +-#endif /* ieee754.h */ +Index: glibc/sysdeps/unix/sysv/linux/arm/mmap64.S +=================================================================== +--- glibc.orig/sysdeps/unix/sysv/linux/arm/mmap64.S 2005-03-22 10:26:27.097977060 -0500 ++++ glibc/sysdeps/unix/sysv/linux/arm/mmap64.S 2005-03-22 11:00:53.051209928 -0500 +@@ -1,4 +1,4 @@ +-/* Copyright (C) 2000, 2003 Free Software Foundation, Inc. ++/* Copyright (C) 2000, 2003, 2005 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or +@@ -23,13 +23,28 @@ + + #include "kernel-features.h" + ++#ifdef __ARM_EABI__ ++# define INITIAL_OFFSET 8 ++#else ++# define INITIAL_OFFSET 4 ++#endif ++ ++#ifdef __ARMEB__ ++# define LOW_OFFSET INITIAL_OFFSET + 4 ++/* The initial + 4 is for the stack postdecrement. */ ++# define HIGH_OFFSET 4 + INITIAL_OFFSET + 0 ++#else ++# define LOW_OFFSET INITIAL_OFFSET + 0 ++# define HIGH_OFFSET 4 + INITIAL_OFFSET + 4 ++#endif ++ + /* The mmap2 system call takes six arguments, all in registers. */ + .text + ENTRY (__mmap64) + #ifdef __NR_mmap2 +- ldr ip, [sp, $4] @ offset low part ++ ldr ip, [sp, $LOW_OFFSET] @ offset low part + str r5, [sp, #-4]! +- ldr r5, [sp, $12] @ offset high part ++ ldr r5, [sp, $HIGH_OFFSET] @ offset high part + str r4, [sp, #-4]! + movs r4, ip, lsl $20 @ check that offset is page-aligned + mov ip, ip, lsr $12 + diff --git a/meta/packages/glibc/glibc-cvs/eabi-patch-4 b/meta/packages/glibc/glibc-cvs/eabi-patch-4 new file mode 100644 index 000000000..45166ef96 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/eabi-patch-4 @@ -0,0 +1,64 @@ +From libc-alpha-return-17230-listarch-libc-alpha=sources dot redhat dot com at sources dot redhat dot com Tue Mar 22 16:25:01 2005 +Return-Path: +Delivered-To: listarch-libc-alpha at sources dot redhat dot com +Received: (qmail 7764 invoked by alias); 22 Mar 2005 16:24:20 -0000 +Mailing-List: contact libc-alpha-help at sources dot redhat dot com; run by ezmlm +Precedence: bulk +List-Subscribe: +List-Archive: +List-Post: +List-Help: , +Sender: libc-alpha-owner at sources dot redhat dot com +Delivered-To: mailing list libc-alpha at sources dot redhat dot com +Received: (qmail 7316 invoked from network); 22 Mar 2005 16:23:45 -0000 +Received: from unknown (HELO nevyn.them.org) (66.93.172.17) + by sourceware dot org with SMTP; 22 Mar 2005 16:23:45 -0000 +Received: from drow by nevyn.them.org with local (Exim 4.50 #1 (Debian)) + id 1DDmAg-000798-P7 + for ; Tue, 22 Mar 2005 11:23:58 -0500 +Date: Tue, 22 Mar 2005 11:23:58 -0500 +From: Daniel Jacobowitz +To: libc-alpha at sources dot redhat dot com +Subject: Re: Define PT_ARM_EXIDX +Message-ID: <20050322162358.GA27424@nevyn.them.org> +Mail-Followup-To: libc-alpha at sources dot redhat dot com +References: <20050322155140.GA25312@nevyn.them.org> +Mime-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +Content-Disposition: inline +In-Reply-To: <20050322155140 dot GA25312 at nevyn dot them dot org> +User-Agent: Mutt/1.5.6+20040907i + +On Tue, Mar 22, 2005 at 10:51:40AM -0500, Daniel Jacobowitz wrote: +> The ARM EABI uses a program header to locate exception tables for shared +> objects, just like PT_GNU_EH_FRAME. But the format is a little different, +> and the header is above PT_LOPROC because it was assigned by a processor +> vendor. This just adds the constant to elf/elf.h. + +Oops, Ulrich pointed out that I put the constant in the wrong place. + +-- +Daniel Jacobowitz +CodeSourcery, LLC + +2005-03-22 Daniel Jacobowitz + + * elf/elf.h (PT_ARM_EXIDX): Define. + +Index: glibc/elf/elf.h +=================================================================== +--- glibc.orig/elf/elf.h 2005-03-22 11:21:34.961464117 -0500 ++++ glibc/elf/elf.h 2005-03-22 11:22:49.872172922 -0500 +@@ -2138,7 +2138,11 @@ typedef Elf32_Addr Elf32_Conflict; + #define PF_ARM_SB 0x10000000 /* Segment contains the location + addressed by the static base */ + ++/* Processor specific values for the Phdr p_type field. */ ++#define PT_ARM_EXIDX 0x70000001 /* .ARM.exidx segment */ ++ + /* ARM relocs. */ ++ + #define R_ARM_NONE 0 /* No reloc */ + #define R_ARM_PC24 1 /* PC relative 26 bit branch */ + #define R_ARM_ABS32 2 /* Direct 32 bit */ + diff --git a/meta/packages/glibc/glibc-cvs/etc/ld.so.conf b/meta/packages/glibc/glibc-cvs/etc/ld.so.conf new file mode 100644 index 000000000..3f9b41aab --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/etc/ld.so.conf @@ -0,0 +1,3 @@ +/usr/local/lib +/opt/QtPalmtop/lib + diff --git a/meta/packages/glibc/glibc-cvs/glibc-fp-byteorder.patch b/meta/packages/glibc/glibc-cvs/glibc-fp-byteorder.patch new file mode 100644 index 000000000..f20432ea8 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/glibc-fp-byteorder.patch @@ -0,0 +1,203 @@ +Taken from http://sources.redhat.com/ml/crossgcc/2004-02/msg00104.html +Author: addsub@eyou.com +Target: ARM + +Fixes http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/execute/920501-8.c +and makes printf("%f", 1.0) work. + +Lennert Buytenhek wrote in http://sources.redhat.com/ml/crossgcc/2004-09/msg00115.html : + It ... fixes the 'printf("%f\n", 0.5); prints 0.000000' and general 'floating point + is broken' on my big-endian hardfloat FPA ARM platform. ... + It's definitely needed for hardfloat. So I'd think it's needed for + big-endian systems in any case, and for VFP on little-endian systems + too. Someone would have to verify that though. + +Lennert Buytenhek wrote in http://sources.redhat.com/ml/crossgcc/2004-09/msg00123.html + I just had a look at glibc-20040830, and [this patch] is still needed and useful + for this version. glibc-20040830 out-of-the-box still contains the + following wrong assumptions: + - sysdeps/arm/bits/endian.h: float word order is big endian (which it is + not on vfp systems) + - sysdeps/arm/gmp-mparam.h: IEEE doubles are mixed endian (which they + are not on big endian systems, neither on vfp systems) + - sysdeps/arm/ieee754.h: IEEE doubles are in little endian byte order + (which they are not on big endian systems) + [This patch] seems the right solution for all of these issues. + +Dimitry Andric wrote in http://sources.redhat.com/ml/crossgcc/2004-09/msg00132.html : + It's even needed for glibc CVS, AFAICS. + The patch hunk which modifies glibc.new/sysdeps/arm/bits/endian.h + (currently at version 1.4) is only needed for proper VFP operation. + But the hunk which modifies sysdeps/arm/gmp-mparam.h, and the hunk + that deletes sysdeps/arm/ieee754.h (yes, this IS correct), are needed + for proper operation of *any* FP model on big endian ARM. + +See also discussion in followups to +http://sources.redhat.com/ml/crossgcc/2004-05/msg00245.html) + +Message-ID: <276985760.37584@eyou.com> +Received: from unknown (HELO eyou.com) (172.16.2.2) + by 0.0.0.0 with SMTP; Tue, 17 Feb 2004 10:42:40 +0800 +Received: (qmail 8238 invoked by uid 65534); 17 Feb 2004 10:42:38 +0800 +Date: 17 Feb 2004 10:42:38 +0800 +Message-ID: <20040217104238.8237.qmail@eyou.com> +From: "add" +To: dank@kegel.com +Reply-To: "add" +Subject: Re:   problem while building arm vfp softfloat gcc ` + +Hi, Dan, This is a patch I applied to my glibc-2.3.2, then my softfloat +toolchain can printf("%f\n",1.0). So you may have a try of this + + +diff -uNrp glibc.old/sysdeps/arm/bits/endian.h glibc.new/sysdeps/arm/bits/endian.h +--- glibc.old/sysdeps/arm/bits/endian.h 1999-04-12 11:59:13.000000000 -0400 ++++ glibc.new/sysdeps/arm/bits/endian.h 2004-02-12 09:15:13.000000000 -0500 +@@ -9,4 +9,9 @@ + #else + #define __BYTE_ORDER __LITTLE_ENDIAN + #endif ++ ++#ifdef __VFP_FP__ ++#define __FLOAT_WORD_ORDER __BYTE_ORDER ++#else + #define __FLOAT_WORD_ORDER __BIG_ENDIAN ++#endif +diff -uNrp glibc.old/sysdeps/arm/gmp-mparam.h glibc.new/sysdeps/arm/gmp-mparam.h +--- glibc.old/sysdeps/arm/gmp-mparam.h 2001-07-07 15:21:19.000000000 -0400 ++++ glibc.new/sysdeps/arm/gmp-mparam.h 2004-02-12 09:15:13.000000000 -0500 +@@ -26,5 +26,13 @@ MA 02111-1307, USA. */ + #define BITS_PER_SHORTINT 16 + #define BITS_PER_CHAR 8 + +-#define IEEE_DOUBLE_BIG_ENDIAN 0 +-#define IEEE_DOUBLE_MIXED_ENDIAN 1 ++#if defined(__ARMEB__) ++# define IEEE_DOUBLE_MIXED_ENDIAN 0 ++# define IEEE_DOUBLE_BIG_ENDIAN 1 ++#elif defined(__VFP_FP__) ++# define IEEE_DOUBLE_MIXED_ENDIAN 0 ++# define IEEE_DOUBLE_BIG_ENDIAN 0 ++#else ++# define IEEE_DOUBLE_BIG_ENDIAN 0 ++# define IEEE_DOUBLE_MIXED_ENDIAN 1 ++#endif +diff -uNrp glibc.old/sysdeps/arm/ieee754.h glibc.new/sysdeps/arm/ieee754.h +--- glibc.old/sysdeps/arm/ieee754.h 2001-07-07 15:21:19.000000000 -0400 ++++ glibc.new/sysdeps/arm/ieee754.h 1969-12-31 19:00:00.000000000 -0500 +@@ -1,115 +0,0 @@ +-/* Copyright (C) 1992, 1995, 1996, 1998 Free Software Foundation, Inc. +- This file is part of the GNU C Library. +- +- The GNU C Library is free software; you can redistribute it and/or +- modify it under the terms of the GNU Lesser General Public +- License as published by the Free Software Foundation; either +- version 2.1 of the License, or (at your option) any later version. +- +- The GNU C Library is distributed in the hope that it will be useful, +- but WITHOUT ANY WARRANTY; without even the implied warranty of +- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +- Lesser General Public License for more details. +- +- You should have received a copy of the GNU Lesser General Public +- License along with the GNU C Library; if not, write to the Free +- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA +- 02111-1307 USA. */ +- +-#ifndef _IEEE754_H +- +-#define _IEEE754_H 1 +-#include +- +-#include +- +-__BEGIN_DECLS +- +-union ieee754_float +- { +- float f; +- +- /* This is the IEEE 754 single-precision format. */ +- struct +- { +- unsigned int mantissa:23; +- unsigned int exponent:8; +- unsigned int negative:1; +- } ieee; +- +- /* This format makes it easier to see if a NaN is a signalling NaN. */ +- struct +- { +- unsigned int mantissa:22; +- unsigned int quiet_nan:1; +- unsigned int exponent:8; +- unsigned int negative:1; +- } ieee_nan; +- }; +- +-#define IEEE754_FLOAT_BIAS 0x7f /* Added to exponent. */ +- +- +-union ieee754_double +- { +- double d; +- +- /* This is the IEEE 754 double-precision format. */ +- struct +- { +- unsigned int mantissa0:20; +- unsigned int exponent:11; +- unsigned int negative:1; +- unsigned int mantissa1:32; +- } ieee; +- +- /* This format makes it easier to see if a NaN is a signalling NaN. */ +- struct +- { +- unsigned int mantissa0:19; +- unsigned int quiet_nan:1; +- unsigned int exponent:11; +- unsigned int negative:1; +- unsigned int mantissa1:32; +- } ieee_nan; +- }; +- +-#define IEEE754_DOUBLE_BIAS 0x3ff /* Added to exponent. */ +- +- +-/* The following two structures are correct for `new' floating point systems but +- wrong for the old FPPC. The only solution seems to be to avoid their use on +- old hardware. */ +- +-union ieee854_long_double +- { +- long double d; +- +- /* This is the IEEE 854 double-extended-precision format. */ +- struct +- { +- unsigned int exponent:15; +- unsigned int empty:16; +- unsigned int negative:1; +- unsigned int mantissa1:32; +- unsigned int mantissa0:32; +- } ieee; +- +- /* This is for NaNs in the IEEE 854 double-extended-precision format. */ +- struct +- { +- unsigned int exponent:15; +- unsigned int empty:16; +- unsigned int negative:1; +- unsigned int mantissa1:32; +- unsigned int mantissa0:30; +- unsigned int quiet_nan:1; +- unsigned int one:1; +- } ieee_nan; +- }; +- +-#define IEEE854_LONG_DOUBLE_BIAS 0x3fff +- +-__END_DECLS +- +-#endif /* ieee754.h */ diff --git a/meta/packages/glibc/glibc-cvs/ldconfig.patch b/meta/packages/glibc/glibc-cvs/ldconfig.patch new file mode 100644 index 000000000..c60b9b143 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/ldconfig.patch @@ -0,0 +1,37 @@ +--- elf/ldconfig.c 2003-07-08 23:26:27.000000000 +0900 ++++ elf/ldconfig.c.debian 2003-07-08 23:29:43.000000000 +0900 +@@ -920,26 +920,24 @@ + { + FILE *file = NULL; + char *line = NULL; +- const char *canon; ++ const char *canon = filename; + size_t len = 0; ++ int file_fd; + + if (opt_chroot) + { + canon = chroot_canon (opt_chroot, filename); +- if (canon) +- file = fopen (canon, "r"); +- else ++ if (!canon) + canon = filename; + } +- else +- { +- canon = filename; +- file = fopen (filename, "r"); +- } ++ ++ if ((file_fd = open(canon, O_RDONLY | O_EXCL, 0022)) != -1) ++ file = fdopen (file_fd, "r"); + + if (file == NULL) + { +- error (0, errno, _("Can't open configuration file %s"), canon); ++ if (opt_verbose) ++ error (0, errno, _("Can't open configuration file %s"), canon); + if (canon != filename) + free ((char *) canon); + return; diff --git a/meta/packages/glibc/glibc-cvs/ldd.patch b/meta/packages/glibc/glibc-cvs/ldd.patch new file mode 100644 index 000000000..01719dbe0 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/ldd.patch @@ -0,0 +1,38 @@ +--- elf/ldd.bash.in~ Tue Apr 3 21:43:31 2001 ++++ elf/ldd.bash.in Tue Apr 3 21:54:15 2001 +@@ -32,6 +32,7 @@ + warn= + bind_now= + verbose= ++filename_magic_regex="((^|/)lib|.so$)" + + while test $# -gt 0; do + case "$1" in +@@ -123,8 +124,11 @@ + echo "ldd: ${file}:" $"No such file or directory" >&2 + result=1 + elif test -r "$file"; then +- test -x "$file" || echo 'ldd:' $"\ +-warning: you do not have execution permission for" "\`$file'" >&2 ++ if test ! -x "$file" && eval echo "$file" \ ++ | egrep -v "$filename_magic_regex" > /dev/null; then ++ echo 'ldd:' $"warning: you do not have execution permission for"\ ++ "\`$file'" >&2 ++ fi + RTLD= + for rtld in ${RTLDLIST}; do + if test -x $rtld; then +@@ -143,7 +147,12 @@ + fi + case $ret in + 0) +- eval $add_env '"$file"' || result=1 ++ if [ ! -x "$file" ] && eval file -L "$file" 2>/dev/null \ ++ | sed 10q | egrep "$file_magic_regex" > /dev/null; then ++ eval $add_env ${RTLD} '"$file"' || result=1 ++ else ++ eval $add_env '"$file"' || result=1 ++ fi + ;; + 1) + # This can be a non-ELF binary or no binary at all. diff --git a/meta/packages/glibc/glibc-cvs/ldsocache-varrun.patch b/meta/packages/glibc/glibc-cvs/ldsocache-varrun.patch new file mode 100644 index 000000000..9994d4f87 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/ldsocache-varrun.patch @@ -0,0 +1,18 @@ +This patch moves ld.so.cache from /etc to /var/run. This is for devices +where /etc is JFFS2 or CRAMFS but /var is a ramdisk. + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- libc/sysdeps/generic/dl-cache.h~ldsocache-varrun ++++ libc/sysdeps/generic/dl-cache.h +@@ -29,7 +29,7 @@ + #endif + + #ifndef LD_SO_CACHE +-# define LD_SO_CACHE SYSCONFDIR "/ld.so.cache" ++# define LD_SO_CACHE "/var/run/ld.so.cache" + #endif + + #ifndef add_system_dir diff --git a/meta/packages/glibc/glibc-cvs/makeconfig.patch b/meta/packages/glibc/glibc-cvs/makeconfig.patch new file mode 100644 index 000000000..4365878e9 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/makeconfig.patch @@ -0,0 +1,15 @@ +--- Makeconfig~ 2001/09/12 18:49:45 1.265 ++++ Makeconfig 2001/10/07 20:56:17 +@@ -532,10 +532,11 @@ + $(subst $(empty) ,:,$(strip $(patsubst -Wl$(comma)-rpath-link=%, %,\ + $(filter -Wl$(comma)-rpath-link=%,\ + $(sysdep-LDFLAGS))))) ++ld_envlib_path = $(shell test x$$LD_LIBRARY_PATH = x || echo -n :$$LD_LIBRARY_PATH) + run-program-prefix = $(if $(filter $(notdir $(built-program-file)),\ + $(tests-static)),, \ + $(elf-objpfx)$(rtld-installed-name) \ +- --library-path $(rpath-link)$(patsubst %,:%,$(sysdep-library-path))) ++ --library-path $(rpath-link)$(patsubst %,:%,$(sysdep-library-path))$(ld_envlib_path)) + else + run-program-prefix = + endif diff --git a/meta/packages/glibc/glibc-cvs/mips-no-throw.patch b/meta/packages/glibc/glibc-cvs/mips-no-throw.patch new file mode 100644 index 000000000..99a316eea --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/mips-no-throw.patch @@ -0,0 +1,22 @@ +--- sysdeps/unix/sysv/linux/mips/bits/socket.h.orig 2004-09-15 14:27:06.342572280 +0200 ++++ sysdeps/unix/sysv/linux/mips/bits/socket.h 2004-09-15 14:27:28.162255184 +0200 +@@ -261,7 +261,7 @@ + # define _EXTERN_INLINE extern __inline + # endif + _EXTERN_INLINE struct cmsghdr * +-__cmsg_nxthdr (struct msghdr *__mhdr, struct cmsghdr *__cmsg) __THROW ++__cmsg_nxthdr (struct msghdr *__mhdr, struct cmsghdr *__cmsg) + { + if ((size_t) __cmsg->cmsg_len < sizeof (struct cmsghdr)) + /* The kernel header does this so there may be a reason. */ +--- sysdeps/unix/sysv/linux/mips/sys/tas.h.orig 2004-09-15 14:27:41.809180536 +0200 ++++ sysdeps/unix/sysv/linux/mips/sys/tas.h 2004-09-15 14:27:53.245441960 +0200 +@@ -35,7 +35,7 @@ + # endif + + _EXTERN_INLINE int +-_test_and_set (int *p, int v) __THROW ++_test_and_set (int *p, int v) + { + int r, t; + diff --git a/meta/packages/glibc/glibc-cvs/noinfo.patch b/meta/packages/glibc/glibc-cvs/noinfo.patch new file mode 100644 index 000000000..6aa0e64d9 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/noinfo.patch @@ -0,0 +1,52 @@ +--- glibc-2.3.2/manual/Makefile~noinfo ++++ glibc-2.3.2/manual/Makefile +@@ -25,7 +25,7 @@ + INSTALL_INFO = install-info + + .PHONY: all dvi pdf info html +-all: dvi ++all: + dvi: libc.dvi + pdf: libc.pdf + +@@ -41,7 +41,7 @@ + TEXI2PDF = texi2dvi --pdf + + ifneq ($(strip $(MAKEINFO)),:) +-all: info ++all: + info: libc.info dir-add.info + endif + +@@ -176,28 +176,14 @@ + -rm -f top-menu.texi chapters.texi + + .PHONY: install subdir_install installdirs install-data +-install-data subdir_install: install ++install-data subdir_install: + ifneq ($(strip $(MAKEINFO)),:) + # There are two variants of install-info out there. The GNU version + # knows about the INFO-DIR-SECTION tag, the Debian version doesn't. + ifneq ($(OLD_DEBIAN_INSTALL_INFO),yes) +-install: $(inst_infodir)/libc.info dir-add.info +- @if $(SHELL) -c '$(INSTALL_INFO) --version' >/dev/null 2>&1; then \ +- test -f $(inst_infodir)/dir || $(INSTALL_DATA) dir $(inst_infodir);\ +- $(INSTALL_INFO) --info-dir=$(inst_infodir) $(inst_infodir)/libc.info;\ +- $(INSTALL_INFO) --info-dir=$(inst_infodir) dir-add.info;\ +- else : ; fi ++install: + else +-install: $(inst_infodir)/libc.info dir-add.info +- @if $(SHELL) -c '$(INSTALL_INFO) --version' >/dev/null 2>&1; then \ +- test -f $(inst_infodir)/dir || $(INSTALL_DATA) dir $(inst_infodir);\ +- $(INSTALL_INFO) --info-dir=$(inst_infodir) \ +- --section '^GNU Libraries:' 'GNU Libraries:' \ +- $(inst_infodir)/libc.info;\ +- $(INSTALL_INFO) --info-dir=$(inst_infodir) \ +- --section '^GNU C Library functions:' 'GNU C Library functions:' \ +- dir-add.info;\ +- else : ; fi ++install: + endif + endif + # Catchall implicit rule for other installation targets from the parent. diff --git a/meta/packages/glibc/glibc-cvs/trampoline.patch b/meta/packages/glibc/glibc-cvs/trampoline.patch new file mode 100644 index 000000000..86cfc0a53 --- /dev/null +++ b/meta/packages/glibc/glibc-cvs/trampoline.patch @@ -0,0 +1,560 @@ +From libc-alpha-return-16890-listarch-libc-alpha=sources dot redhat dot com at sources dot redhat dot com Wed Jan 19 18:02:53 2005 +Return-Path: +Delivered-To: listarch-libc-alpha at sources dot redhat dot com +Received: (qmail 26073 invoked by alias); 19 Jan 2005 18:02:41 -0000 +Mailing-List: contact libc-alpha-help at sources dot redhat dot com; run by ezmlm +Precedence: bulk +List-Subscribe: +List-Archive: +List-Post: +List-Help: , +Sender: libc-alpha-owner at sources dot redhat dot com +Delivered-To: mailing list libc-alpha at sources dot redhat dot com +Received: (qmail 25420 invoked from network); 19 Jan 2005 18:01:47 -0000 +Received: from unknown (HELO mail.codesourcery.com) (65.74.133.9) + by sourceware dot org with SMTP; 19 Jan 2005 18:01:47 -0000 +Received: (qmail 7456 invoked from network); 19 Jan 2005 18:01:44 -0000 +Received: from localhost (HELO ?192.168.0.100?) (mitchell@127.0.0.1) + by mail dot codesourcery dot com with SMTP; 19 Jan 2005 18:01:44 -0000 +Message-ID: <41EEA082.1020000@codesourcery.com> +Date: Wed, 19 Jan 2005 10:01:38 -0800 +From: Mark Mitchell +Organization: CodeSourcery, LLC +User-Agent: Mozilla Thunderbird 0.9 (Windows/20041103) +MIME-Version: 1.0 +To: Daniel Jacobowitz +CC: libc-alpha at sources dot redhat dot com +Subject: Re: PATCH: ARM dl-trampoline.S +References: <200501191631.j0JGVVRA002591@sirius.codesourcery.com> <20050119170217.GA3137@nevyn.them.org> +In-Reply-To: <20050119170217 dot GA3137 at nevyn dot them dot org> +Content-Type: multipart/mixed; + boundary="------------050601050507020101060100" + +This is a multi-part message in MIME format. +--------------050601050507020101060100 +Content-Type: text/plain; charset=ISO-8859-1; format=flowed +Content-Transfer-Encoding: 7bit + +Daniel Jacobowitz wrote: +> On Wed, Jan 19, 2005 at 08:31:31AM -0800, Mark Mitchell wrote: +> +>>This patch updates the ARM port for the recent dl-trampoline.S and +>>link.h changes. OK to apply? +> +> +> Did you test this? I'm pretty sure that RESOLVE_MAP returns a link +> map, unlike RESOLVE. + +No, I didn't test -- except by building glibc. (There are other +problems at the moment, AFAICT, with actually running the library on ARM.) + +However, you're definitely correct -- good catch! -- and, in fact, in +looking at my logs I see compiler warnings about the mismatched type +assignment. Here is a more plausible version. How about this one? + +Thanks, + +-- +Mark Mitchell +CodeSourcery, LLC +mark@codesourcery.com +(916) 791-8304 + +--------------050601050507020101060100 +Content-Type: text/plain; + name="glibc.patch" +Content-Transfer-Encoding: 7bit +Content-Disposition: inline; + filename="glibc.patch" + +2005-01-19 Mark Mitchell + + * elf/tst-auditmod1.c: Add ARM support. + * sysdeps/arm/dl-machine.h (ELF_MACHINE_RUNTIME_TRAMPOLINE): + Remove. + (RESOLVE): Do not use it; use ... + (RESOLVE_MAP): ... instead. + (ARCH_LA_PLTENTER): Define. + (ARCH_LA_PLTEXIT): Likewise. + (elf_machine_rel): Use RESOLVE_MAP, not RESOLVE. + (elf_machine_rela): Likewise. + * sysdeps/arm/dl-trampoline.S: New file. + * sysdeps/arm/bits/link.h: Likewise. + * sysdeps/generic/ldsodefs.h (struct La_arm_regs): Declare. + (struct audit_ifaces): Add ARM functions. + +Index: elf/tst-auditmod1.c +=================================================================== +RCS file: /cvs/glibc/libc/elf/tst-auditmod1.c,v +retrieving revision 1.7 +diff -c -5 -p -r1.7 tst-auditmod1.c +*** elf/tst-auditmod1.c 16 Jan 2005 06:24:59 -0000 1.7 +--- elf/tst-auditmod1.c 19 Jan 2005 17:54:32 -0000 +*************** la_symbind64 (Elf64_Sym *sym, unsigned i +*** 100,110 **** + symname, (long int) sym->st_value, ndx, *flags); + + return sym->st_value; + } + +! #ifdef __i386__ + # define pltenter la_i86_gnu_pltenter + # define pltexit la_i86_gnu_pltexit + # define La_regs La_i86_regs + # define La_retval La_i86_retval + # define int_retval lrv_eax +--- 100,116 ---- + symname, (long int) sym->st_value, ndx, *flags); + + return sym->st_value; + } + +! #ifdef __arm__ +! # define pltenter la_arm_gnu_plteneter +! # define pltext la_arm_gnu_pltexit +! # define La_regs La_arm_regs +! # define La_retval La_arm_retval +! # define int_retval lvr_r0 +! #elif defined __i386__ + # define pltenter la_i86_gnu_pltenter + # define pltexit la_i86_gnu_pltexit + # define La_regs La_i86_regs + # define La_retval La_i86_retval + # define int_retval lrv_eax +Index: sysdeps/arm/dl-trampoline.S +=================================================================== +RCS file: sysdeps/arm/dl-trampoline.S +diff -N sysdeps/arm/dl-trampoline.S +*** /dev/null 1 Jan 1970 00:00:00 -0000 +--- sysdeps/arm/dl-trampoline.S 19 Jan 2005 17:54:32 -0000 +*************** +*** 0 **** +--- 1,135 ---- ++ /* PLT trampolines. ARM version. ++ Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++ #include ++ ++ #if defined(__USE_BX__) ++ #define BX(x) bx x ++ #else ++ #define BX(x) mov pc, x ++ #endif ++ ++ #ifndef PROF ++ .text ++ .globl _dl_runtime_resolve ++ .type _dl_runtime_resolve, #function ++ .align 2 ++ _dl_runtime_resolve: ++ @ we get called with ++ @ stack[0] contains the return address from this call ++ @ ip contains &GOT[n+3] (pointer to function) ++ @ lr points to &GOT[2] ++ ++ @ stack arguments ++ stmdb sp!,{r0-r3} ++ ++ @ get pointer to linker struct ++ ldr r0, [lr, #-4] ++ ++ @ prepare to call _dl_fixup() ++ @ change &GOT[n+3] into 8*n NOTE: reloc are 8 bytes each ++ sub r1, ip, lr ++ sub r1, r1, #4 ++ add r1, r1, r1 ++ ++ @ call fixup routine ++ bl _dl_fixup ++ ++ @ save the return ++ mov ip, r0 ++ ++ @ get arguments and return address back ++ ldmia sp!, {r0-r3,lr} ++ ++ @ jump to the newly found address ++ BX(ip) ++ ++ .size _dl_runtime_resolve, .-_dl_runtime_resolve ++ ++ .globl _dl_runtime_profile ++ .type _dl_runtime_profile, #function ++ .align 2 ++ _dl_runtime_profile: ++ @ stack arguments ++ stmdb sp!, {r0-r3} ++ ++ @ get pointer to linker struct ++ ldr r0, [lr, #-4] ++ ++ @ prepare to call _dl_profile_fixup() ++ @ change &GOT[n+3] into 8*n NOTE: reloc are 8 bytes each ++ sub r1, ip, lr ++ sub r1, r1, #4 ++ add r1, r1, r1 ++ ++ @ call profiling fixup routine ++ bl _dl_profile_fixup ++ ++ @ save the return ++ mov ip, r0 ++ ++ @ get arguments and return address back ++ ldmia sp!, {r0-r3,lr} ++ ++ @ jump to the newly found address ++ BX(ip) ++ ++ .size _dl_runtime_resolve, .-_dl_runtime_resolve ++ .previous ++ #else ++ .text ++ .globl _dl_runtime_resolve ++ .globl _dl_runtime_profile ++ .type _dl_runtime_resolve, #function ++ .type _dl_runtime_profile, #function ++ .align 2 ++ _dl_runtime_resolve: ++ _dl_runtime_profile: ++ @ we get called with ++ @ stack[0] contains the return address from this call ++ @ ip contains &GOT[n+3] (pointer to function) ++ @ lr points to &GOT[2] ++ ++ @ stack arguments ++ stmdb sp!, {r0-r3} ++ ++ @ get pointer to linker struct ++ ldr r0, [lr, #-4] ++ ++ @ prepare to call _dl_fixup() ++ @ change &GOT[n+3] into 8*n NOTE: reloc are 8 bytes each ++ sub r1, ip, lr ++ sub r1, r1, #4 ++ add r1, r1, r1 ++ ++ @ call profiling fixup routine ++ bl _dl_fixup ++ ++ @ save the return ++ mov ip, r0 ++ ++ @ get arguments and return address back ++ ldmia sp!, {r0-r3,lr} ++ ++ @ jump to the newly found address ++ BX(ip) ++ ++ .size _dl_runtime_profile, .-_dl_runtime_profile ++ .previous ++ #endif +Index: sysdeps/arm/bits/link.h +=================================================================== +RCS file: /cvs/glibc/libc/sysdeps/arm/bits/link.h,v +retrieving revision 1.2 +diff -c -5 -p -r1.2 link.h +*** sysdeps/arm/bits/link.h 6 Jan 2005 22:40:20 -0000 1.2 +--- sysdeps/arm/bits/link.h 19 Jan 2005 17:54:32 -0000 +*************** +*** 0 **** +--- 1,57 ---- ++ /* Copyright (C) 2005 Free Software Foundation, Inc. ++ This file is part of the GNU C Library. ++ ++ The GNU C Library is free software; you can redistribute it and/or ++ modify it under the terms of the GNU Lesser General Public ++ License as published by the Free Software Foundation; either ++ version 2.1 of the License, or (at your option) any later version. ++ ++ The GNU C Library is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ Lesser General Public License for more details. ++ ++ You should have received a copy of the GNU Lesser General Public ++ License along with the GNU C Library; if not, write to the Free ++ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA ++ 02111-1307 USA. */ ++ ++ #ifndef _LINK_H ++ # error "Never include directly; use instead." ++ #endif ++ ++ ++ /* Registers for entry into PLT on ARM. */ ++ typedef struct La_arm_regs ++ { ++ uint32_t lvr_r0; ++ uint32_t lvr_r1; ++ uint32_t lvr_r2; ++ uint32_t lvr_r3; ++ } La_arm_regs; ++ ++ /* Return values for calls from PLT on ARM. */ ++ typedef struct La_arm_retval ++ { ++ uint32_t lvr_r0; ++ uint32_t lvr_r1; ++ } La_arm_retval; ++ ++ ++ __BEGIN_DECLS ++ ++ extern Elf32_Addr la_arm_gnu_pltenter (Elf32_Sym *__sym, unsigned int __ndx, ++ uintptr_t *__refcook, ++ uintptr_t *__defcook, ++ La_arm_regs *__regs, ++ unsigned int *__flags, ++ const char *__symname, ++ long int *__framesizep); ++ extern unsigned int la_arm_gnu_pltexit (Elf32_Sym *__sym, unsigned int __ndx, ++ uintptr_t *__refcook, ++ uintptr_t *__defcook, ++ const La_arm_regs *__inregs, ++ La_arm_retval *__outregs, ++ const char *symname); ++ ++ __END_DECLS +Index: sysdeps/generic/ldsodefs.h +=================================================================== +RCS file: /cvs/glibc/libc/sysdeps/generic/ldsodefs.h,v +retrieving revision 1.112 +diff -c -5 -p -r1.112 ldsodefs.h +*** sysdeps/generic/ldsodefs.h 16 Jan 2005 02:07:29 -0000 1.112 +--- sysdeps/generic/ldsodefs.h 19 Jan 2005 17:54:32 -0000 +*************** enum allowmask +*** 173,182 **** +--- 173,183 ---- + allow_ldso = 8 + }; + + + /* Type for list of auditing interfaces. */ ++ struct La_arm_regs; + struct La_i86_regs; + struct La_i86_retval; + struct La_x86_64_regs; + struct La_x86_64_retval; + struct La_ppc32_regs; +*************** struct audit_ifaces +*** 202,211 **** +--- 203,216 ---- + uintptr_t (*symbind64) (Elf64_Sym *, unsigned int, uintptr_t *, + uintptr_t *, unsigned int *, const char *); + }; + union + { ++ Elf32_Addr (*arm_gnu_pltenter) (Elf32_Sym *, unsigned int, uintptr_t *, ++ uintptr_t *, struct La_arm_regs *, ++ unsigned int *, const char *name, ++ long int *framesizep); + Elf32_Addr (*i86_gnu_pltenter) (Elf32_Sym *, unsigned int, uintptr_t *, + uintptr_t *, struct La_i86_regs *, + unsigned int *, const char *name, + long int *framesizep); + Elf64_Addr (*x86_64_gnu_pltenter) (Elf64_Sym *, unsigned int, uintptr_t *, +*************** struct audit_ifaces +*** 229,238 **** +--- 234,246 ---- + unsigned int *, const char *name, + long int *framesizep); + }; + union + { ++ unsigned int (*arm_gnu_pltexit) (Elf32_Sym *, unsigned int, uintptr_t *, ++ uintptr_t *, const struct La_arm_regs *, ++ struct La_i86_retval *, const char *); + unsigned int (*i86_gnu_pltexit) (Elf32_Sym *, unsigned int, uintptr_t *, + uintptr_t *, const struct La_i86_regs *, + struct La_i86_retval *, const char *); + unsigned int (*x86_64_gnu_pltexit) (Elf64_Sym *, unsigned int, uintptr_t *, + uintptr_t *, + +--------------050601050507020101060100-- + +diff -u -r1.52 dl-machine.h +--- sysdeps/arm/dl-machine.h 15 Mar 2005 22:57:26 -0000 1.52 ++++ sysdeps/arm/dl-machine.h 22 Apr 2005 03:38:15 -0000 +@@ -129,119 +129,6 @@ + #define BX(x) "mov\tpc, " #x + #endif + +-#ifndef PROF +-# define ELF_MACHINE_RUNTIME_TRAMPOLINE asm ("\ +- .text\n\ +- .globl _dl_runtime_resolve\n\ +- .type _dl_runtime_resolve, #function\n\ +- .align 2\n\ +-_dl_runtime_resolve:\n\ +- @ we get called with\n\ +- @ stack[0] contains the return address from this call\n\ +- @ ip contains &GOT[n+3] (pointer to function)\n\ +- @ lr points to &GOT[2]\n\ +-\n\ +- @ stack arguments\n\ +- stmdb sp!,{r0-r3}\n\ +-\n\ +- @ get pointer to linker struct\n\ +- ldr r0, [lr, #-4]\n\ +-\n\ +- @ prepare to call fixup()\n\ +- @ change &GOT[n+3] into 8*n NOTE: reloc are 8 bytes each\n\ +- sub r1, ip, lr\n\ +- sub r1, r1, #4\n\ +- add r1, r1, r1\n\ +-\n\ +- @ call fixup routine\n\ +- bl fixup\n\ +-\n\ +- @ save the return\n\ +- mov ip, r0\n\ +-\n\ +- @ get arguments and return address back\n\ +- ldmia sp!, {r0-r3,lr}\n\ +-\n\ +- @ jump to the newly found address\n\ +- " BX(ip) "\n\ +-\n\ +- .size _dl_runtime_resolve, .-_dl_runtime_resolve\n\ +-\n\ +- .globl _dl_runtime_profile\n\ +- .type _dl_runtime_profile, #function\n\ +- .align 2\n\ +-_dl_runtime_profile:\n\ +- @ stack arguments\n\ +- stmdb sp!, {r0-r3}\n\ +-\n\ +- @ get pointer to linker struct\n\ +- ldr r0, [lr, #-4]\n\ +-\n\ +- @ prepare to call fixup()\n\ +- @ change &GOT[n+3] into 8*n NOTE: reloc are 8 bytes each\n\ +- sub r1, ip, lr\n\ +- sub r1, r1, #4\n\ +- add r1, r1, r1\n\ +-\n\ +- @ call profiling fixup routine\n\ +- bl profile_fixup\n\ +-\n\ +- @ save the return\n\ +- mov ip, r0\n\ +-\n\ +- @ get arguments and return address back\n\ +- ldmia sp!, {r0-r3,lr}\n\ +-\n\ +- @ jump to the newly found address\n\ +- " BX(ip) "\n\ +-\n\ +- .size _dl_runtime_resolve, .-_dl_runtime_resolve\n\ +- .previous\n\ +-"); +-#else // PROF +-# define ELF_MACHINE_RUNTIME_TRAMPOLINE asm ("\ +- .text\n\ +- .globl _dl_runtime_resolve\n\ +- .globl _dl_runtime_profile\n\ +- .type _dl_runtime_resolve, #function\n\ +- .type _dl_runtime_profile, #function\n\ +- .align 2\n\ +-_dl_runtime_resolve:\n\ +-_dl_runtime_profile:\n\ +- @ we get called with\n\ +- @ stack[0] contains the return address from this call\n\ +- @ ip contains &GOT[n+3] (pointer to function)\n\ +- @ lr points to &GOT[2]\n\ +-\n\ +- @ stack arguments\n\ +- stmdb sp!, {r0-r3}\n\ +-\n\ +- @ get pointer to linker struct\n\ +- ldr r0, [lr, #-4]\n\ +-\n\ +- @ prepare to call fixup()\n\ +- @ change &GOT[n+3] into 8*n NOTE: reloc are 8 bytes each\n\ +- sub r1, ip, lr\n\ +- sub r1, r1, #4\n\ +- add r1, r1, r1\n\ +-\n\ +- @ call profiling fixup routine\n\ +- bl fixup\n\ +-\n\ +- @ save the return\n\ +- mov ip, r0\n\ +-\n\ +- @ get arguments and return address back\n\ +- ldmia sp!, {r0-r3,lr}\n\ +-\n\ +- @ jump to the newly found address\n\ +- " BX(ip) "\n\ +-\n\ +- .size _dl_runtime_profile, .-_dl_runtime_profile\n\ +- .previous\n\ +-"); +-#endif //PROF +- + /* Mask identifying addresses reserved for the user program, + where the dynamic linker should not map anything. */ + #define ELF_MACHINE_USER_ADDRESS_MASK 0xf8000000UL +@@ -348,6 +235,10 @@ + return value; + } + ++/* Names of the architecture-specific auditing callback functions. */ ++#define ARCH_LA_PLTENTER arm_gnu_pltenter ++#define ARCH_LA_PLTEXIT arm_gnu_pltexit ++ + #endif /* !dl_machine_h */ + + +@@ -355,7 +246,7 @@ + Prelinked libraries may use Elf32_Rela though. */ + #define ELF_MACHINE_NO_RELA defined RTLD_BOOTSTRAP + +-#ifdef RESOLVE ++#ifdef RESOLVE_MAP + + /* Deal with an out-of-range PC24 reloc. */ + static Elf32_Addr +@@ -425,7 +316,8 @@ + #endif + { + const Elf32_Sym *const refsym = sym; +- Elf32_Addr value = RESOLVE (&sym, version, r_type); ++ struct link_map *sym_map = RESOLVE_MAP (&sym, version, r_type); ++ Elf32_Addr value = sym == NULL ? 0 : sym_map->l_addr + sym->st_value; + if (sym) + value += sym->st_value; + +@@ -535,7 +427,8 @@ + # ifndef RESOLVE_CONFLICT_FIND_MAP + const Elf32_Sym *const refsym = sym; + # endif +- Elf32_Addr value = RESOLVE (&sym, version, r_type); ++ struct link_map *sym_map = RESOLVE_MAP (&sym, version, r_type); ++ Elf32_Addr value = sym == NULL ? 0 : sym_map->l_addr + sym->st_value; + if (sym) + value += sym->st_value; + +@@ -637,4 +530,4 @@ + _dl_reloc_bad_type (map, r_type, 1); + } + +-#endif /* RESOLVE */ ++#endif /* RESOLVE_MAP */ diff --git a/meta/packages/glibc/glibc-initial_2.4.bb b/meta/packages/glibc/glibc-initial_2.4.bb new file mode 100644 index 000000000..422e8b711 --- /dev/null +++ b/meta/packages/glibc/glibc-initial_2.4.bb @@ -0,0 +1,46 @@ +SECTION = "libs" +include glibc_${PV}.bb + +DEPENDS = "linux-libc-headers" +PROVIDES = "virtual/${TARGET_PREFIX}libc-initial" +FILESPATH = "${@base_set_filespath([ '${FILE_DIRNAME}/glibc-cvs', '${FILE_DIRNAME}/glibc', '${FILE_DIRNAME}/files', '${FILE_DIRNAME}' ], d)}" + +PACKAGES = "" + +do_configure () { + sed -ie 's,{ (exit 1); exit 1; }; },{ (exit 0); }; },g' ${S}/configure + chmod +x ${S}/configure + CC="${BUILD_CC}" CPP="${BUILD_CPP}" LD="${BUILD_LD}" ${S}/configure --host=${TARGET_SYS} --build=${BUILD_SYS} \ + --without-cvs --disable-sanity-checks \ + --with-headers=${CROSS_DIR}/${TARGET_SYS}/include \ + --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_stage () { + oe_runmake cross-compiling=yes install_root=${CROSS_DIR}/${TARGET_SYS} prefix="" install-headers + + # 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 ${CROSS_DIR}/${TARGET_SYS}/include/gnu + touch ${CROSS_DIR}/${TARGET_SYS}/include/gnu/stubs.h + cp ${S}/include/features.h ${CROSS_DIR}/${TARGET_SYS}/include/features.h +} + +do_install () { + : +} diff --git a/meta/packages/glibc/glibc-intermediate_2.4.bb b/meta/packages/glibc/glibc-intermediate_2.4.bb new file mode 100644 index 000000000..819cd0950 --- /dev/null +++ b/meta/packages/glibc/glibc-intermediate_2.4.bb @@ -0,0 +1,14 @@ +SECTION = "libs" +include glibc_${PV}.bb + +DEFAULT_PREFERENCE = "-1" + +do_install () { + : +} + +PACKAGES = "" +PROVIDES = "virtual/${TARGET_PREFIX}libc-for-gcc" +DEPENDS = "virtual/${TARGET_PREFIX}gcc-initial linux-libc-headers" +GLIBC_ADDONS = "nptl,ports" +GLIBC_EXTRA_OECONF = "" diff --git a/meta/packages/glibc/glibc-package.bbclass b/meta/packages/glibc/glibc-package.bbclass new file mode 100644 index 000000000..d6decfb70 --- /dev/null +++ b/meta/packages/glibc/glibc-package.bbclass @@ -0,0 +1,300 @@ +# +# For now, we will skip building of a gcc package if it is a uclibc one +# and our build is not a uclibc one, and we skip a glibc one if our build +# is a uclibc build. +# +# See the note in gcc/gcc_3.4.0.oe +# + +python __anonymous () { + import bb, re + uc_os = (re.match('.*uclibc$', bb.data.getVar('TARGET_OS', d, 1)) != None) + if uc_os: + raise bb.parse.SkipPackage("incompatible with target %s" % + bb.data.getVar('TARGET_OS', d, 1)) +} + +# Binary locales are generated at build time if ENABLE_BINARY_LOCALE_GENERATION +# is set. The idea is to avoid running localedef on the target (at first boot) +# to decrease initial boot time and avoid localedef being killed by the OOM +# killer which used to effectively break i18n on machines with < 128MB RAM. + +# default to disabled until qemu works for everyone +ENABLE_BINARY_LOCALE_GENERATION ?= "0" + +# BINARY_LOCALE_ARCHES is a space separated list of regular expressions +BINARY_LOCALE_ARCHES ?= "arm.*" + +PACKAGES = "glibc catchsegv sln nscd ldd localedef glibc-utils glibc-dev glibc-doc glibc-locale libsegfault glibc-extra-nss glibc-thread-db glibc-pcprofile" +PACKAGES_DYNAMIC = "glibc-gconv-* glibc-charmap-* glibc-localedata-*" + +libc_baselibs = "/lib/libc* /lib/libm* /lib/ld* /lib/libpthread* /lib/libresolv* /lib/librt* /lib/libutil* /lib/libnsl* /lib/libnss_files* /lib/libnss_compat* /lib/libnss_dns* /lib/libdl* /lib/libanl* /lib/libBrokenLocale*" + +FILES_${PN} = "${sysconfdir} ${libc_baselibs} /sbin/ldconfig ${libexecdir} ${datadir}/zoneinfo" +FILES_ldd = "${bindir}/ldd" +FILES_libsegfault = "/lib/libSegFault*" +FILES_glibc-extra-nss = "/lib/libnss*" +FILES_sln = "/sbin/sln" +FILES_glibc-dev_append = " ${libdir}/*.o ${bindir}/rpcgen" +FILES_nscd = "${sbindir}/nscd*" +FILES_glibc-utils = "${bindir} ${sbindir}" +FILES_glibc-gconv = "${libdir}/gconv" +FILES_catchsegv = "${bindir}/catchsegv" +RDEPENDS_catchsegv = "libsegfault" +FILES_glibc-pcprofile = "/lib/libpcprofile.so" +FILES_glibc-thread-db = "/lib/libthread_db*" +FILES_localedef = "${bindir}/localedef" +RPROVIDES_glibc-dev += "libc-dev" + +DESCRIPTION_sln = "glibc: create symbolic links between files" +DESCRIPTION_nscd = "glibc: name service cache daemon for passwd, group, and hosts" +DESCRIPTION_glibc-extra-nss = "glibc: nis, nisplus and hesiod search services" +DESCRIPTION_ldd = "glibc: print shared library dependencies" +DESCRIPTION_localedef = "glibc: compile locale definition files" +DESCRIPTION_glibc-utils = "glibc: misc utilities like iconf, local, gencat, tzselect, rpcinfo, ..." + +def get_glibc_fpu_setting(bb, d): + if bb.data.getVar('TARGET_FPU', d, 1) in [ 'soft' ]: + return "--without-fp" + return "" + +EXTRA_OECONF += "${@get_glibc_fpu_setting(bb, d)}" + +OVERRIDES_append = ":${TARGET_ARCH}-${TARGET_OS}" +EXTRA_OECONF_append_arm-linuxeabi = " --without-fp" + +do_install() { + oe_runmake install_root=${D} install + for r in ${rpcsvc}; do + h=`echo $r|sed -e's,\.x$,.h,'` + install -m 0644 ${S}/sunrpc/rpcsvc/$h ${D}/${includedir}/rpcsvc/ + done + install -m 0644 ${WORKDIR}/etc/ld.so.conf ${D}/${sysconfdir}/ + install -d ${D}${libdir}/locale + make -f ${WORKDIR}/generate-supported.mk IN="${S}/localedata/SUPPORTED" OUT="${WORKDIR}/SUPPORTED" + # get rid of some broken files... + for i in ${GLIBC_BROKEN_LOCALES}; do + grep -v $i ${WORKDIR}/SUPPORTED > ${WORKDIR}/SUPPORTED.tmp + mv ${WORKDIR}/SUPPORTED.tmp ${WORKDIR}/SUPPORTED + done + rm -f ${D}/etc/rpc +} + +TMP_LOCALE="/tmp/locale/${libdir}/locale" + +locale_base_postinst() { +#!/bin/sh + +if [ "x$D" != "x" ]; then + exit 1 +fi + +rm -rf ${TMP_LOCALE} +mkdir -p ${TMP_LOCALE} +if [ -f ${libdir}/locale/locale-archive ]; then + cp ${libdir}/locale/locale-archive ${TMP_LOCALE}/ +fi +localedef --inputfile=${datadir}/i18n/locales/%s --charmap=%s --prefix=/tmp/locale %s +mv ${TMP_LOCALE}/locale-archive ${libdir}/locale/ +rm -rf ${TMP_LOCALE} +} + +locale_base_postrm() { +#!/bin/sh + +rm -rf ${TMP_LOCALE} +mkdir -p ${TMP_LOCALE} +if [ -f ${libdir}/locale/locale-archive ]; then + cp ${libdir}/locale/locale-archive ${TMP_LOCALE}/ +fi +localedef --delete-from-archive --inputfile=${datadir}/locales/%s --charmap=%s --prefix=/tmp/locale %s +mv ${TMP_LOCALE}/locale-archive ${libdir}/locale/ +rm -rf ${TMP_LOCALE} +} + +python __anonymous () { + enabled = bb.data.getVar("ENABLE_BINARY_LOCALE_GENERATION", d, 1) + + if enabled and int(enabled): + import re + + target_arch = bb.data.getVar("TARGET_ARCH", d, 1) + binary_arches = bb.data.getVar("BINARY_LOCALE_ARCHES", d, 1) or "" + + for regexp in binary_arches.split(" "): + r = re.compile(regexp) + + if r.match(target_arch): + depends = bb.data.getVar("DEPENDS", d, 1) + depends = "%s qemu-native" % depends + bb.data.setVar("DEPENDS", depends, d) + bb.data.setVar("GLIBC_INTERNAL_USE_BINARY_LOCALE", "1", d) + break +} + +do_prep_locale_tree() { + treedir=${WORKDIR}/locale-tree + rm -rf $treedir + mkdir -p $treedir/bin $treedir/lib $treedir/${datadir} $treedir/${libdir}/locale + cp -a ${D}${datadir}/i18n $treedir/${datadir}/i18n + # unzip to avoid parsing errors + for i in $treedir/${datadir}/i18n/charmaps/*gz; do + gunzip $i + done + cp -a ${STAGING_LIBDIR}/* $treedir/lib + if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.* ]; then + cp -a ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.* $treedir/lib + fi + install -m 0755 ${D}${bindir}/localedef $treedir/bin +} + +do_collect_bins_from_locale_tree() { + treedir=${WORKDIR}/locale-tree + + mkdir -p ${D}${libdir} + cp -a $treedir/${libdir}/locale ${D}${libdir} +} + +python package_do_split_gconvs () { + import os, re + if (bb.data.getVar('PACKAGE_NO_GCONV', d, 1) == '1'): + bb.note("package requested not splitting gconvs") + return + + if not bb.data.getVar('PACKAGES', d, 1): + return + + libdir = bb.data.getVar('libdir', d, 1) + if not libdir: + bb.error("libdir not defined") + return + datadir = bb.data.getVar('datadir', d, 1) + if not datadir: + bb.error("datadir not defined") + return + + gconv_libdir = os.path.join(libdir, "gconv") + charmap_dir = os.path.join(datadir, "i18n", "charmaps") + locales_dir = os.path.join(datadir, "i18n", "locales") + binary_locales_dir = os.path.join(libdir, "locale") + + do_split_packages(d, gconv_libdir, file_regex='^(.*)\.so$', output_pattern='glibc-gconv-%s', description='gconv module for character set %s', extra_depends='glibc-gconv') + + do_split_packages(d, charmap_dir, file_regex='^(.*)\.gz$', output_pattern='glibc-charmap-%s', description='character map for %s encoding', extra_depends='') + + def calc_locale_deps(fn, pkg, file_regex, output_pattern, group): + deps = [] + f = open(fn, "r") + c_re = re.compile('^copy "(.*)"') + i_re = re.compile('^include "(\w+)".*') + for l in f.readlines(): + m = c_re.match(l) or i_re.match(l) + if m: + dp = legitimize_package_name('glibc-localedata-%s' % m.group(1)) + if not dp in deps: + deps.append(dp) + f.close() + if deps != []: + bb.data.setVar('RDEPENDS_%s' % pkg, " ".join(deps), d) + + use_bin = bb.data.getVar("GLIBC_INTERNAL_USE_BINARY_LOCALE", d, 1) + if use_bin: + do_split_packages(d, locales_dir, file_regex='(.*)', output_pattern='glibc-localedata-%s', description='locale definition for %s', hook=calc_locale_deps, extra_depends='', aux_files_pattern_verbatim=binary_locales_dir + '/%s') + else: + do_split_packages(d, locales_dir, file_regex='(.*)', output_pattern='glibc-localedata-%s', description='locale definition for %s', hook=calc_locale_deps, extra_depends='') + bb.note("generation of binary locales disabled. this may break i18n!") + bb.data.setVar('PACKAGES', bb.data.getVar('PACKAGES', d) + ' glibc-gconv', d) + + f = open(os.path.join(bb.data.getVar('WORKDIR', d, 1), "SUPPORTED"), "r") + supported = f.readlines() + f.close() + + dot_re = re.compile("(.*)\.(.*)") + + # Collate the locales by base and encoding + encodings = {} + for l in supported: + l = l[:-1] + (locale, charset) = l.split(" ") + m = dot_re.match(locale) + if m: + locale = m.group(1) + if not encodings.has_key(locale): + encodings[locale] = [] + encodings[locale].append(charset) + + def output_locale_source(name, locale, encoding): + pkgname = 'locale-base-' + legitimize_package_name(name) + + bb.data.setVar('RDEPENDS_%s' % pkgname, 'localedef glibc-localedata-%s glibc-charmap-%s' % (legitimize_package_name(locale), legitimize_package_name(encoding)), d) + rprovides = 'virtual-locale-%s' % legitimize_package_name(name) + m = re.match("(.*)_(.*)", name) + if m: + rprovides += ' virtual-locale-%s' % m.group(1) + bb.data.setVar('RPROVIDES_%s' % pkgname, rprovides, d) + bb.data.setVar('PACKAGES', '%s %s' % (pkgname, bb.data.getVar('PACKAGES', d, 1)), d) + bb.data.setVar('ALLOW_EMPTY_%s' % pkgname, '1', d) + bb.data.setVar('pkg_postinst_%s' % pkgname, bb.data.getVar('locale_base_postinst', d, 1) % (locale, encoding, locale), d) + bb.data.setVar('pkg_postrm_%s' % pkgname, bb.data.getVar('locale_base_postrm', d, 1) % (locale, encoding, locale), d) + + def output_locale_binary(name, locale, encoding): + target_arch = bb.data.getVar("TARGET_ARCH", d, 1) + qemu = "qemu-%s" % target_arch + pkgname = 'locale-base-' + legitimize_package_name(name) + + bb.data.setVar('RDEPENDS_%s' % pkgname, 'glibc-localedata-%s glibc-charmap-%s' % (legitimize_package_name(locale), legitimize_package_name(encoding)), d) + rprovides = 'virtual-locale-%s' % legitimize_package_name(name) + m = re.match("(.*)_(.*)", name) + if m: + rprovides += ' virtual-locale-%s' % m.group(1) + bb.data.setVar('RPROVIDES_%s' % pkgname, rprovides, d) + bb.data.setVar('ALLOW_EMPTY_%s' % pkgname, '1', d) + bb.data.setVar('PACKAGES', '%s %s' % (pkgname, bb.data.getVar('PACKAGES', d, 1)), d) + + treedir = os.path.join(bb.data.getVar("WORKDIR", d, 1), "locale-tree") + path = bb.data.getVar("PATH", d, 1) + i18npath = os.path.join(treedir, datadir, "i18n") + + localedef_opts = "--force --old-style --no-archive --prefix=%s --inputfile=%s/i18n/locales/%s --charmap=%s %s" % (treedir, datadir, locale, encoding, locale) + cmd = "PATH=\"%s\" I18NPATH=\"%s\" %s -L %s %s/bin/localedef %s" % (path, i18npath, qemu, treedir, treedir, localedef_opts) + bb.note("generating locale %s (%s)" % (locale, encoding)) + if os.system(cmd): + raise bb.build.FuncFailed("localedef returned an error.") + + def output_locale(name, locale, encoding): + use_bin = bb.data.getVar("GLIBC_INTERNAL_USE_BINARY_LOCALE", d, 1) + if use_bin: + output_locale_binary(name, locale, encoding) + else: + output_locale_source(name, locale, encoding) + + use_bin = bb.data.getVar("GLIBC_INTERNAL_USE_BINARY_LOCALE", d, 1) + if use_bin: + bb.note("preparing tree for binary locale generation") + bb.build.exec_func("do_prep_locale_tree", d) + + # Reshuffle names so that UTF-8 is preferred over other encodings + for l in encodings.keys(): + if len(encodings[l]) == 1: + output_locale(l, l, encodings[l][0]) + else: + if "UTF-8" in encodings[l]: + output_locale(l, l, "UTF-8") + encodings[l].remove("UTF-8") + for e in encodings[l]: + output_locale('%s-%s' % (l, e), l, e) + + use_bin = bb.data.getVar("GLIBC_INTERNAL_USE_BINARY_LOCALE", d, 1) + if use_bin: + bb.note("collecting binary locales from locale tree") + bb.build.exec_func("do_collect_bins_from_locale_tree", d) +} + +# We want to do this indirection so that we can safely 'return' +# from the called function even though we're prepending +python populate_packages_prepend () { + if bb.data.getVar('DEBIAN_NAMES', d, 1): + bb.data.setVar('PKG_glibc', 'libc6', d) + bb.data.setVar('PKG_glibc-dev', 'libc6-dev', d) + bb.build.exec_func('package_do_split_gconvs', d) +} diff --git a/meta/packages/glibc/glibc_2.3.5+cvs20050627.bb b/meta/packages/glibc/glibc_2.3.5+cvs20050627.bb new file mode 100644 index 000000000..c8f1d5684 --- /dev/null +++ b/meta/packages/glibc/glibc_2.3.5+cvs20050627.bb @@ -0,0 +1,175 @@ +DESCRIPTION = "GNU C Library" +HOMEPAGE = "http://www.gnu.org/software/libc/libc.html" +LICENSE = "LGPL" +SECTION = "libs" +PRIORITY = "required" +MAINTAINER = "Phil Blundell " + +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/glibc-cvs-2.3.5" +SRCDATE = "20050627" +PR = "r3" + +GLIBC_ADDONS ?= "ports,linuxthreads" +GLIBC_EXTRA_OECONF ?= "" + +GLIBC_BROKEN_LOCALES = "sid_ET tr_TR mn_MN" + +# +# For now, we will skip building of a gcc package if it is a uclibc one +# and our build is not a uclibc one, and we skip a glibc one if our build +# is a uclibc build. +# +# See the note in gcc/gcc_3.4.0.oe +# + +python __anonymous () { + import bb, re + uc_os = (re.match('.*uclibc$', bb.data.getVar('TARGET_OS', d, 1)) != None) + if uc_os: + raise bb.parse.SkipPackage("incompatible with target %s" % + bb.data.getVar('TARGET_OS', d, 1)) +} + +# nptl needs unwind support in gcc, which can't be built without glibc. +PROVIDES = "virtual/libc ${@['virtual/${TARGET_PREFIX}libc-for-gcc', '']['nptl' in '${GLIBC_ADDONS}']}" +PROVIDES += "virtual/libintl virtual/libiconv" +DEPENDS = "${@['virtual/${TARGET_PREFIX}gcc-initial', 'virtual/${TARGET_PREFIX}gcc']['nptl' in '${GLIBC_ADDONS}']} linux-libc-headers" +RDEPENDS_${PN}-dev = "linux-libc-headers-dev" +INHIBIT_DEFAULT_DEPS = "1" + +# file://noinfo.patch;patch=1 +# file://ldconfig.patch;patch=1;pnum=0 +# file://arm-machine-gmon.patch;patch=1;pnum=0 \ +# \ +# file://arm-ioperm.patch;patch=1;pnum=0 \ +# file://ldd.patch;patch=1;pnum=0 \ +SRC_URI = "http://familiar.handhelds.org/source/v0.8.3/stash_libc_sources.redhat.com__20050627.tar.gz \ + http://familiar.handhelds.org/source/v0.8.3/stash_ports_sources.redhat.com__20050627.tar.gz \ + file://arm-audit.patch;patch=1 \ + file://arm-audit2.patch;patch=1 \ + file://arm-no-hwcap.patch;patch=1 \ + file://arm-memcpy.patch;patch=1 \ + file://arm-longlong.patch;patch=1;pnum=0 \ + file://fhs-linux-paths.patch;patch=1 \ + file://dl-cache-libcmp.patch;patch=1 \ + file://ldsocache-varrun.patch;patch=1 \ + file://5090_all_stubs-rule-fix.patch;patch=1 \ + file://etc/ld.so.conf \ + file://generate-supported.mk" + +# seems to fail on tls platforms +SRC_URI_append_arm = " file://dyn-ldconfig-20041128.patch;patch=1" + +S = "${WORKDIR}/libc" +B = "${WORKDIR}/build-${TARGET_SYS}" + +inherit autotools + +EXTRA_OECONF = "--enable-kernel=${OLDEST_KERNEL} \ + --without-cvs --disable-profile --disable-debug --without-gd \ + --enable-clocale=gnu \ + --enable-add-ons=${GLIBC_ADDONS} \ + --with-headers=${CROSS_DIR}/${TARGET_SYS}/include \ + --without-selinux \ + ${GLIBC_EXTRA_OECONF}" + +EXTRA_OECONF += "${@get_glibc_fpu_setting(bb, d)}" + +def get_glibc_fpu_setting(bb, d): + if bb.data.getVar('TARGET_FPU', d, 1) in [ 'soft' ]: + return "--without-fp" + return "" + +do_munge() { + # Integrate ports into tree + mv ${WORKDIR}/ports ${S} + + # http://www.handhelds.org/hypermail/oe/51/5135.html + # Some files were moved around between directories on + # 2005-12-21, which means that any attempt to check out + # from CVS using a datestamp older than that will be doomed. + # + # This is a workaround for that problem. + rm -rf ${S}/bits +} + +addtask munge before do_patch after do_unpack + +do_configure () { +# override this function to avoid the autoconf/automake/aclocal/autoheader +# calls for now +# don't pass CPPFLAGS into configure, since it upsets the kernel-headers +# version check and doesn't really help with anything + if [ -z "`which rpcgen`" ]; then + echo "rpcgen not found. Install glibc-devel." + exit 1 + fi + (cd ${S} && gnu-configize) || die "failure in running gnu-configize" + CPPFLAGS="" oe_runconf +} + +rpcsvc = "bootparam_prot.x nlm_prot.x rstat.x \ + yppasswd.x klm_prot.x rex.x sm_inter.x mount.x \ + rusers.x spray.x nfs_prot.x rquota.x key_prot.x" + +do_compile () { + # -Wl,-rpath-link /lib in LDFLAGS can cause breakage if another glibc is in staging + unset LDFLAGS + base_do_compile + ( + cd ${S}/sunrpc/rpcsvc + for r in ${rpcsvc}; do + h=`echo $r|sed -e's,\.x$,.h,'` + rpcgen -h $r -o $h || oewarn "unable to generate header for $r" + done + ) +} + +do_stage() { + rm -f ${STAGING_LIBDIR}/libc.so.6 + oe_runmake 'install_root=${STAGING_DIR}/${HOST_SYS}' \ + 'includedir=/include' 'libdir=/lib' 'slibdir=/lib' \ + '${STAGING_LIBDIR}/libc.so.6' \ + install-headers install-lib + + install -d ${STAGING_INCDIR}/gnu \ + ${STAGING_INCDIR}/bits \ + ${STAGING_INCDIR}/rpcsvc + install -m 0644 ${S}/include/gnu/stubs.h ${STAGING_INCDIR}/gnu/ + install -m 0644 ${B}/bits/stdio_lim.h ${STAGING_INCDIR}/bits/ + install -m 0644 misc/syscall-list.h ${STAGING_INCDIR}/bits/syscall.h + for r in ${rpcsvc}; do + h=`echo $r|sed -e's,\.x$,.h,'` + install -m 0644 ${S}/sunrpc/rpcsvc/$h ${STAGING_INCDIR}/rpcsvc/ + done + for i in libc.a libc_pic.a libc_nonshared.a; do + install -m 0644 ${B}/$i ${STAGING_LIBDIR}/ || die "failed to install $i" + done + echo 'GROUP ( libpthread.so.0 libpthread_nonshared.a )' > ${STAGING_LIBDIR}/libpthread.so + echo 'GROUP ( libc.so.6 libc_nonshared.a )' > ${STAGING_LIBDIR}/libc.so + + rm -f ${CROSS_DIR}/${TARGET_SYS}/lib/libc.so.6 + oe_runmake 'install_root=${CROSS_DIR}/${TARGET_SYS}' \ + 'includedir=/include' 'libdir=/lib' 'slibdir=/lib' \ + '${CROSS_DIR}/${TARGET_SYS}/lib/libc.so.6' \ + install-headers install-lib + + install -d ${CROSS_DIR}/${TARGET_SYS}/include/gnu \ + ${CROSS_DIR}/${TARGET_SYS}/include/bits \ + ${CROSS_DIR}/${TARGET_SYS}/include/rpcsvc + install -m 0644 ${S}/include/gnu/stubs.h ${CROSS_DIR}/${TARGET_SYS}/include/gnu/ + install -m 0644 ${B}/bits/stdio_lim.h ${CROSS_DIR}/${TARGET_SYS}/include/bits/ + install -m 0644 misc/syscall-list.h ${CROSS_DIR}/${TARGET_SYS}/include/bits/syscall.h + for r in ${rpcsvc}; do + h=`echo $r|sed -e's,\.x$,.h,'` + install -m 0644 ${S}/sunrpc/rpcsvc/$h ${CROSS_DIR}/${TARGET_SYS}/include/rpcsvc/ + done + + for i in libc.a libc_pic.a libc_nonshared.a; do + install -m 0644 ${B}/$i ${CROSS_DIR}/${TARGET_SYS}/lib/ || die "failed to install $i" + done + echo 'GROUP ( libpthread.so.0 libpthread_nonshared.a )' > ${CROSS_DIR}/${TARGET_SYS}/lib/libpthread.so + echo 'GROUP ( libc.so.6 libc_nonshared.a )' > ${CROSS_DIR}/${TARGET_SYS}/lib/libc.so +} + +include glibc-package.bbclass diff --git a/meta/packages/glibc/glibc_2.4.bb b/meta/packages/glibc/glibc_2.4.bb new file mode 100644 index 000000000..faaf27ced --- /dev/null +++ b/meta/packages/glibc/glibc_2.4.bb @@ -0,0 +1,201 @@ +DESCRIPTION = "GNU C Library" +HOMEPAGE = "http://www.gnu.org/software/libc/libc.html" +LICENSE = "LGPL" +SECTION = "libs" +PRIORITY = "required" +DEFAULT_PREFERENCE = "-1" +PR = "r4" + +FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/glibc-2.4" + +GLIBC_ADDONS ?= "ports,nptl,libidn" +GLIBC_EXTRA_OECONF ?= "" + +GLIBC_BROKEN_LOCALES = "sid_ET tr_TR mn_MN" + +# +# For now, we will skip building of a gcc package if it is a uclibc one +# and our build is not a uclibc one, and we skip a glibc one if our build +# is a uclibc build. +# +# See the note in gcc/gcc_3.4.0.oe +# + +python __anonymous () { + import bb, re + uc_os = (re.match('.*uclibc$', bb.data.getVar('TARGET_OS', d, 1)) != None) + if uc_os: + raise bb.parse.SkipPackage("incompatible with target %s" % + bb.data.getVar('TARGET_OS', d, 1)) +} + +# nptl needs unwind support in gcc, which can't be built without glibc. +PROVIDES = "virtual/libc ${@['virtual/${TARGET_PREFIX}libc-for-gcc', '']['nptl' in '${GLIBC_ADDONS}']}" +PROVIDES += "virtual/libintl virtual/libiconv" +DEPENDS = "${@['virtual/${TARGET_PREFIX}gcc-initial', 'virtual/${TARGET_PREFIX}gcc']['nptl' in '${GLIBC_ADDONS}']} linux-libc-headers" +RDEPENDS_${PN}-dev = "linux-libc-headers-dev" +INHIBIT_DEFAULT_DEPS = "1" + +# file://noinfo.patch;patch=1 +# file://ldconfig.patch;patch=1;pnum=0 +# file://arm-machine-gmon.patch;patch=1;pnum=0 \ +# \ +# file://arm-ioperm.patch;patch=1;pnum=0 \ +# file://ldd.patch;patch=1;pnum=0 \ +SRC_URI = "ftp://ftp.gnu.org/pub/gnu/glibc/glibc-2.4.tar.bz2 \ + ftp://ftp.gnu.org/pub/gnu/glibc/glibc-ports-2.4.tar.bz2 \ + ftp://ftp.gnu.org/pub/gnu/glibc/glibc-libidn-2.4.tar.bz2 \ + file://arm-memcpy.patch;patch=1 \ + file://arm-longlong.patch;patch=1 \ + file://fhs-linux-paths.patch;patch=1 \ + file://dl-cache-libcmp.patch;patch=1 \ + file://ldsocache-varrun.patch;patch=1 \ + file://nptl-crosscompile.patch;patch=1 \ + file://glibc-2.4-compile.patch;patch=1 \ + file://fixup-aeabi-syscalls.patch;patch=1 \ + file://generic-bits_select.h \ + file://generic-bits_types.h \ + file://generic-bits_typesizes.h \ + file://generic-bits_time.h \ + file://etc/ld.so.conf \ + file://generate-supported.mk" + +S = "${WORKDIR}/glibc-2.4" +B = "${WORKDIR}/build-${TARGET_SYS}" + +inherit autotools + +EXTRA_OECONF = "--enable-kernel=${OLDEST_KERNEL} \ + --without-cvs --disable-profile --disable-debug --without-gd \ + --enable-clocale=gnu \ + --enable-add-ons=${GLIBC_ADDONS} \ + --with-headers=${STAGING_INCDIR} \ + --without-selinux \ + ${GLIBC_EXTRA_OECONF}" + +EXTRA_OECONF += "${@get_glibc_fpu_setting(bb, d)}" + +def get_glibc_fpu_setting(bb, d): + if bb.data.getVar('TARGET_FPU', d, 1) in [ 'soft' ]: + return "--without-fp" + return "" + +do_munge() { + # Integrate ports and libidn into tree + mv ${WORKDIR}/glibc-ports-${PV} ${S}/ports + mv ${WORKDIR}/glibc-libidn-${PV} ${S}/libidn + + # Ports isn't really working... Fix it + # Some of this is rather dirty, but it seems to be the only + # quick way to get this cruft to compile + rm -rf ${S}/ports/sysdeps/unix/sysv/linux/arm/linuxthreads + ln -s nptl ${S}/ports/sysdeps/unix/sysv/linux/arm/linuxthreads + cp ${S}/sysdeps/unix/sysv/linux/i386/bits/wchar.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/ + cp ${S}/sysdeps/wordsize-32/bits/wordsize.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/ + cp ${WORKDIR}/generic-bits_select.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/select.h + cp ${WORKDIR}/generic-bits_types.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/types.h + cp ${WORKDIR}/generic-bits_typesizes.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/typesizes.h + cp ${WORKDIR}/generic-bits_time.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/time.h + # Copy in generic stuff for not yet implemented headers + for i in ${S}/bits/*.h; do + F=`basename $i` + [ "$F" = "local_lim.h" ] && continue + [ "$F" = "errno.h" ] && continue + test -e ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/$F || test -e ${S}/ports/sysdeps/arm/bits/$F || test -e ${S}/sysdeps/unix/sysv/linux/bits/$F || test -e ${S}/sysdeps/ieee754/bits/$F || cp $i ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/ + done + # This is harmful; we need to get the one from nptl/sysdeps/pthreads + rm -f ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/libc-lock.h + # Obsoleted by sysdeps/arm/{fpu,eabi}/bits/fenv.h + rm -f ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/fenv.h + # Obsoleted by sysdeps/gnu/bits/utmp.h + rm -f ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/utmp.h + + # http://www.handhelds.org/hypermail/oe/51/5135.html + # Some files were moved around between directories on + # 2005-12-21, which means that any attempt to check out + # from CVS using a datestamp older than that will be doomed. + # + # This is a workaround for that problem. + rm -rf ${S}/bits +} + +addtask munge before do_patch after do_unpack + +do_configure () { +# override this function to avoid the autoconf/automake/aclocal/autoheader +# calls for now +# don't pass CPPFLAGS into configure, since it upsets the kernel-headers +# version check and doesn't really help with anything + if [ -z "`which rpcgen`" ]; then + echo "rpcgen not found. Install glibc-devel." + exit 1 + fi + (cd ${S} && gnu-configize) || die "failure in running gnu-configize" + CPPFLAGS="" oe_runconf +} + +rpcsvc = "bootparam_prot.x nlm_prot.x rstat.x \ + yppasswd.x klm_prot.x rex.x sm_inter.x mount.x \ + rusers.x spray.x nfs_prot.x rquota.x key_prot.x" + +do_compile () { + # -Wl,-rpath-link /lib in LDFLAGS can cause breakage if another glibc is in staging + unset LDFLAGS + base_do_compile + ( + cd ${S}/sunrpc/rpcsvc + for r in ${rpcsvc}; do + h=`echo $r|sed -e's,\.x$,.h,'` + rpcgen -h $r -o $h || oewarn "unable to generate header for $r" + done + ) +} + +do_stage() { + rm -f ${STAGING_LIBDIR}/libc.so.6 + oe_runmake 'install_root=${STAGING_DIR}/${HOST_SYS}' \ + 'includedir=/include' 'libdir=/lib' 'slibdir=/lib' \ + '${STAGING_LIBDIR}/libc.so.6' \ + install-headers install-lib + + install -d ${STAGING_INCDIR}/gnu \ + ${STAGING_INCDIR}/bits \ + ${STAGING_INCDIR}/rpcsvc + install -m 0644 ${S}/include/gnu/stubs.h ${STAGING_INCDIR}/gnu/ + install -m 0644 ${B}/bits/stdio_lim.h ${STAGING_INCDIR}/bits/ + install -m 0644 misc/syscall-list.h ${STAGING_INCDIR}/bits/syscall.h + for r in ${rpcsvc}; do + h=`echo $r|sed -e's,\.x$,.h,'` + install -m 0644 ${S}/sunrpc/rpcsvc/$h ${STAGING_INCDIR}/rpcsvc/ + done + for i in libc.a libc_pic.a libc_nonshared.a; do + install -m 0644 ${B}/$i ${STAGING_LIBDIR}/ || die "failed to install $i" + done + echo 'GROUP ( libpthread.so.0 libpthread_nonshared.a )' > ${STAGING_LIBDIR}/libpthread.so + echo 'GROUP ( libc.so.6 libc_nonshared.a )' > ${STAGING_LIBDIR}/libc.so + + rm -f ${CROSS_DIR}/${TARGET_SYS}/lib/libc.so.6 + oe_runmake 'install_root=${CROSS_DIR}/${TARGET_SYS}' \ + 'includedir=/include' 'libdir=/lib' 'slibdir=/lib' \ + '${CROSS_DIR}/${TARGET_SYS}/lib/libc.so.6' \ + install-headers install-lib + + install -d ${CROSS_DIR}/${TARGET_SYS}/include/gnu \ + ${CROSS_DIR}/${TARGET_SYS}/include/bits \ + ${CROSS_DIR}/${TARGET_SYS}/include/rpcsvc + install -m 0644 ${S}/include/gnu/stubs.h ${CROSS_DIR}/${TARGET_SYS}/include/gnu/ + install -m 0644 ${B}/bits/stdio_lim.h ${CROSS_DIR}/${TARGET_SYS}/include/bits/ + install -m 0644 misc/syscall-list.h ${CROSS_DIR}/${TARGET_SYS}/include/bits/syscall.h + for r in ${rpcsvc}; do + h=`echo $r|sed -e's,\.x$,.h,'` + install -m 0644 ${S}/sunrpc/rpcsvc/$h ${CROSS_DIR}/${TARGET_SYS}/include/rpcsvc/ + done + + for i in libc.a libc_pic.a libc_nonshared.a; do + install -m 0644 ${B}/$i ${CROSS_DIR}/${TARGET_SYS}/lib/ || die "failed to install $i" + done + echo 'GROUP ( libpthread.so.0 libpthread_nonshared.a )' > ${CROSS_DIR}/${TARGET_SYS}/lib/libpthread.so + echo 'GROUP ( libc.so.6 libc_nonshared.a )' > ${CROSS_DIR}/${TARGET_SYS}/lib/libc.so +} + +include glibc-package.bbclass diff --git a/meta/packages/gmp/gmp-4.1.2/amd64.patch b/meta/packages/gmp/gmp-4.1.2/amd64.patch new file mode 100644 index 000000000..bbede7fcc --- /dev/null +++ b/meta/packages/gmp/gmp-4.1.2/amd64.patch @@ -0,0 +1,16 @@ +Index: gmp-4.1.2/longlong.h +=================================================================== +--- gmp-4.1.2.orig/longlong.h 2005-06-24 13:38:06.787570452 -0700 ++++ gmp-4.1.2/longlong.h 2005-06-24 13:38:31.539556496 -0700 +@@ -715,8 +715,10 @@ + } while (0) + #define count_trailing_zeros(count, x) \ + do { \ ++ UDItype __cbtmp; \ + ASSERT ((x) != 0); \ +- __asm__ ("bsfq %1,%0" : "=r" (count) : "rm" ((UDItype)(x))); \ ++ __asm__ ("bsfq %1,%0" : "=r" (__cbtmp) : "rm" ((UDItype)(x))); \ ++ (count) = __cbtmp; \ + } while (0) + #endif /* x86_64 */ + diff --git a/meta/packages/gmp/gmp-4.1.2/configure.patch b/meta/packages/gmp/gmp-4.1.2/configure.patch new file mode 100644 index 000000000..94ad97e91 --- /dev/null +++ b/meta/packages/gmp/gmp-4.1.2/configure.patch @@ -0,0 +1,864 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- gmp-4.1.2/mpfr/Makefile.am~configure 2002-05-15 20:27:52.000000000 -0400 ++++ gmp-4.1.2/mpfr/Makefile.am 2004-01-25 12:53:19.000000000 -0500 +@@ -28,7 +28,7 @@ + SUBDIRS = tests + + INCLUDES = -I$(top_srcdir) +-CFLAGS = @MPFR_CFLAGS@ ++AM_CFLAGS = @MPFR_CFLAGS@ + LIBS = @MPFR_LIBS@ + + if WANT_MPFR +--- gmp-4.1.2/mpfr/tests/Makefile.am~configure 2002-11-24 17:00:42.000000000 -0500 ++++ gmp-4.1.2/mpfr/tests/Makefile.am 2004-01-25 12:53:19.000000000 -0500 +@@ -22,7 +22,7 @@ + AUTOMAKE_OPTIONS = gnu no-dependencies $(top_builddir)/ansi2knr + + INCLUDES = -I$(top_srcdir) -I$(top_srcdir)/mpfr +-CFLAGS = @MPFR_CFLAGS@ ++AM_CFLAGS = @MPFR_CFLAGS@ + LIBS = @MPFR_LIBS@ + + LDADD = ../libmpfr.a $(top_builddir)/libgmp.la +--- gmp-4.1.2/configure.in~configure 2002-12-23 15:52:09.000000000 -0500 ++++ gmp-4.1.2/configure.in 2004-01-25 12:53:19.000000000 -0500 +@@ -26,15 +26,16 @@ + + + AC_REVISION($Revision: 1.425.2.17 $) +-AC_PREREQ(2.52) +-AC_INIT(gmp-impl.h) +-m4_pattern_forbid([^[ \t]*GMP_]) +-m4_pattern_forbid([^[ \t]*MPFR_CONFIGS]) +-m4_pattern_allow(GMP_LDFLAGS) +-m4_pattern_allow(GMP_LIMB_BITS) +-m4_pattern_allow(GMP_MPARAM_H_SUGGEST) +-m4_pattern_allow(GMP_NAIL_BITS) +-m4_pattern_allow(GMP_NUMB_BITS) ++AC_PREREQ(2.57) ++AC_INIT ++AC_CONFIG_SRCDIR([gmp-impl.h]) ++ ++ ++ ++ ++ ++ ++ + + # If --target is not used then $target_alias is empty, but if say + # "./configure athlon-pc-freebsd3.5" is used, then all three of +@@ -56,7 +57,7 @@ + GMP_DEFINE_RAW("define_not_for_expansion(\`HAVE_HOST_CPU_$tmp_host')", POST) + + AM_INIT_AUTOMAKE(gmp, GMP_VERSION) +-AM_CONFIG_HEADER(config.h:config.in) ++AC_CONFIG_HEADERS([config.h:config.in]) + AM_MAINTAINER_MODE + + +@@ -201,7 +202,7 @@ + # After GMP specific searches and tests, the standard autoconf AC_PROG_CC is + # called. User selections of CC etc are respected. + # +-# Care is taken not to use macros like AC_TRY_COMPILE during the GMP ++# Care is taken not to use macros like AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[],[]) during the GMP + # pre-testing, since they of course depend on AC_PROG_CC, and also some of + # them cache their results, which is not wanted. + # +@@ -288,7 +289,7 @@ + # FIXME: We'd like to prefer an ANSI compiler, perhaps by preferring + # c89 over cc here. But note that on HP-UX c89 provides a castrated + # environment, and would want to be excluded somehow. Maybe +-# AC_PROG_CC_STDC already does enough to stick cc into ANSI mode and ++# already does enough to stick cc into ANSI mode and + # we don't need to worry. + # + cclist="gcc cc" +@@ -1010,7 +1011,7 @@ + CFLAGS_or_unset=${CFLAGS-'(unset)'} + CPPFLAGS_or_unset=${CPPFLAGS-'(unset)'} + +-cat >&AC_FD_CC <&AS_MESSAGE_LOG_FD() <&AC_FD_CC ++ echo "CXXFLAGS chosen by autoconf: $CXXFLAGS" >&AS_MESSAGE_LOG_FD() + cxxflags_ac_prog_cxx=$CXXFLAGS + cxxflags_list=ac_prog_cxx + +@@ -1409,7 +1410,7 @@ + fi + + +-cat >&AC_FD_CC <&AS_MESSAGE_LOG_FD() </dev/null]), + [^.*$1[ ]+],[]), +@@ -86,7 +86,7 @@ + dnl autoconf time. Two digits like 3.0 if patchlevel <= 0, or three digits + dnl like 3.0.1 if patchlevel > 0. + +-define(GMP_VERSION, ++define([GMP_VERSION], + [GMP_HEADER_GETVAL(__GNU_MP_VERSION,gmp-h.in)[]dnl + .GMP_HEADER_GETVAL(__GNU_MP_VERSION_MINOR,gmp-h.in)[]dnl + ifelse(m4_eval(GMP_HEADER_GETVAL(__GNU_MP_VERSION_PATCHLEVEL,gmp-h.in) > 0),1, +@@ -97,13 +97,13 @@ + dnl ------------------------------ + dnl Setup an AC_SUBST of HAVE_FUNC_01 for each argument. + +-AC_DEFUN(GMP_SUBST_CHECK_FUNCS, ++AC_DEFUN([GMP_SUBST_CHECK_FUNCS], + [m4_if([$1],,, + [_GMP_SUBST_CHECK_FUNCS(ac_cv_func_[$1],HAVE_[]m4_translit([$1],[a-z],[A-Z])_01) + GMP_SUBST_CHECK_FUNCS(m4_shift($@))])]) + + dnl Called: _GMP_SUBST_CHECK_FUNCS(cachvar,substvar) +-AC_DEFUN(_GMP_SUBST_CHECK_FUNCS, ++AC_DEFUN([_GMP_SUBST_CHECK_FUNCS], + [case $[$1] in + yes) AC_SUBST([$2],1) ;; + no) [$2]=0 ;; +@@ -115,14 +115,14 @@ + dnl ---------------------------------- + dnl Setup an AC_SUBST of HAVE_FOO_H_01 for each argument. + +-AC_DEFUN(GMP_SUBST_CHECK_HEADERS, ++AC_DEFUN([GMP_SUBST_CHECK_HEADERS], + [m4_if([$1],,, + [_GMP_SUBST_CHECK_HEADERS(ac_cv_header_[]m4_translit([$1],[./],[__]), + HAVE_[]m4_translit([$1],[a-z./],[A-Z__])_01) + GMP_SUBST_CHECK_HEADERS(m4_shift($@))])]) + + dnl Called: _GMP_SUBST_CHECK_HEADERS(cachvar,substvar) +-AC_DEFUN(_GMP_SUBST_CHECK_HEADERS, ++AC_DEFUN([_GMP_SUBST_CHECK_HEADERS], + [case $[$1] in + yes) AC_SUBST([$2],1) ;; + no) [$2]=0 ;; +@@ -145,12 +145,12 @@ + dnl would test whether $major.$minor.$subminor is greater than or equal to + dnl 10.3.1. + +-AC_DEFUN(GMP_COMPARE_GE, ++AC_DEFUN([GMP_COMPARE_GE], + [gmp_compare_ge=no + GMP_COMPARE_GE_INTERNAL($@) + ]) + +-AC_DEFUN(GMP_COMPARE_GE_INTERNAL, ++AC_DEFUN([GMP_COMPARE_GE_INTERNAL], + [ifelse(len([$3]),0, + [if test -n "$1" && test "$1" -ge $2; then + gmp_compare_ge=yes +@@ -184,7 +184,7 @@ + dnl for instance to random.o (and others) on vax-dec-ultrix4.5. Naturally + dnl a user-selected $AR_FLAGS is left unchanged. + +-AC_DEFUN(GMP_PROG_AR, ++AC_DEFUN([GMP_PROG_AR], + [dnl Want to establish $AR before libtool initialization. + AC_BEFORE([$0],[AC_PROG_LIBTOOL]) + gmp_user_AR=$AR +@@ -212,7 +212,7 @@ + dnl CC_FOR_BUILD is used without testing. CC_FOR_BUILD is the new name for + dnl a build system compiler, see configfsf.guess. + +-AC_DEFUN(GMP_PROG_HOST_CC, ++AC_DEFUN([GMP_PROG_HOST_CC], + [AC_BEFORE([$0],[AC_PROG_LIBTOOL]) + AC_REQUIRE([AC_PROG_CC]) + AC_CACHE_CHECK([for HOST_CC build system compiler], +@@ -255,7 +255,7 @@ + dnl FIXME: This can be removed and just AM_PROG_LEX used, one that macro + dnl works properly. + +-AC_DEFUN(GMP_PROG_LEX, ++AC_DEFUN([GMP_PROG_LEX], + [AC_REQUIRE([AC_PROG_LEX]) + if test "$LEX" = :; then + LEX=${am_missing_run}flex +@@ -273,7 +273,7 @@ + dnl + dnl See mpn/asm-defs.m4 for details on the known bad m4s. + +-AC_DEFUN(GMP_PROG_M4, ++AC_DEFUN([GMP_PROG_M4], + [AC_ARG_VAR(M4,[m4 macro processor]) + AC_CACHE_CHECK([for suitable m4], + gmp_cv_prog_m4, +@@ -340,7 +340,7 @@ + dnl Enhancement: Maybe this could be in GMP_PROG_M4, and attempt to prefer + dnl an m4 with a working m4wrap, if it can be found. + +-AC_DEFUN(GMP_M4_M4WRAP_SPURIOUS, ++AC_DEFUN([GMP_M4_M4WRAP_SPURIOUS], + [AC_REQUIRE([GMP_PROG_M4]) + AC_CACHE_CHECK([if m4wrap produces spurious output], + gmp_cv_m4_m4wrap_spurious, +@@ -374,7 +374,7 @@ + dnl A user-selected $NM is always left unchanged. AC_PROG_NM is still run + dnl to get the "checking" message printed though. + +-AC_DEFUN(GMP_PROG_NM, ++AC_DEFUN([GMP_PROG_NM], + [dnl Make sure we're the first to call AC_PROG_NM, so our extra flags are + dnl used by everyone. + AC_BEFORE([$0],[AC_PROG_NM]) +@@ -426,7 +426,7 @@ + dnl will run is that a plain native "./configure" falls back on ABI=32, but + dnl ABI=64 is still available as a cross-compile. + +-AC_DEFUN(GMP_PROG_CC_WORKS, ++AC_DEFUN([GMP_PROG_CC_WORKS], + [AC_MSG_CHECKING([compiler $1]) + cat >conftest.c <conftest.c <