Squashed 'yocto-poky/' changes from b1f23d1..8358e54

Upgrade subtree to Yocto-2.1.

6c1c013 build-appliance-image: Update to krogoth head revision
5f84d65 syslinux.bbclass: Remove APPEND from variable dependency
d9dd864 bitbake: toaster-tests: tests for build dashboard
1cf8f21 bitbake: toaster: add modal to select custom image for editing
a40a3e6 bitbake: toaster: add build dashboard buttons to edit/create custom images
e65c980 bitbake: toaster-tests: make helper click on input before entering text
484cbf8 bitbake: toaster-tests: add tests for new custom image page
437b728 bitbake: toaster: prevent exception when Project.release is null
cfc22d3 bitbake: toaster: only prevent duplicate custom image names within a project
3036413 bitbake: toaster: disable/enable "Add layer" button according to input's content
040dbf6 bitbake: toaster: fix sorting after hiding a column in build tables
1b11b79 bitbake: toaster: ensure ToasterTable headings are reset when order by changes
9855840 image.bbclass: The wrong name is being used for the debug filesystem
38c7e2d image_types: Ensure rootfs dependencies cover DEBUGFS
0c3eaa7 syslinux.bbclass: The AUTO_SYSLINUXMENU value needs to be boolean
9c8a049 perf: pass DESTDIR in EXTRA_OEMAKE
9de7324 buildtools-tarball: set INHIBIT_DEFAULT_DEPS
ef09105 xf86-video-omapfb: remove EXTRA_OECONF_armv7a
c2f7da2 base.bbclass: Introduce PACKAGECONFIG_CONFARGS variable
e1c6890 git: update to 2.7.4
98bf7de license.bbclass: do write_deploy_manifest in image postprocessing
519600c devtool: sdk-update: fix handling of UNINATIVE_CHECKSUM changes
c7980b6 bitbake: main: fix processing of BBEVENTLOG
ee25d0e toasterconf.json: Update for krogoth release
b8e5de2 toasterconf.json: Remove fido from supported configurations
c59771e toasterconf.json: Update for krogoth release
d0bce0b toasterconf.json: Remove fido from supported configurations
d25eea3 poky-tiny.conf: set PREFERRED_VERSION_linux-yocto-tiny to 4.4
9f970b6 dev-manual, profile-manual, ref-manual: Purging Oprofile stuff
1d93104 ref-manual: Added description for the testsdk.bbclass.
db47094 ref-manual: Updated the remove-libtool.bbclass description.
a16eeca ref-manual: Added gobject-introspection.bbclass description.
3e761b4 ref-manual: Added reference for npm.bbclass.
5e50157 ref-manual: Fixed typo in the nopackages.bbclass description
f7b68c7 ref-manual: Added description for bash-completion.bbclass
ece900a ref-manual: Added nopackages.bbclass description. Fixed stray typo.
9143e9e ref-manual: Added description for the INSTALL_TIMEZONE_FILE variable.
6391dbf ref-manual: Updated the PREFERRED_PROVIDER variable with a note.
6d86f7a ref-manual: Dropped references to the autotools_stage class
4d5ff5e ref-manual, dev-manual: Scrubbed boot-directdisk and bootimg classes
cd2aaaa ref-manual: Updated the uninative.bbclass description.
e975d26 documentation: Converted "meta-yocto" to "meta-poky"
84452ee bsp-guide: Updated yocto-bsp create example output.
e00a62c ref-manual: Added the migration section for 2.1
02db9e6 yocto-project-qs, ref-manual: Upgraded minimum Git requirement
989841f ref-manual: Added rootfs-postcommands class description.
d06b343 ref-manual: Updated the EXTRA_OEMAKE variable description.
ecb2eb6 dev-manual: Updated "Additional Implementation Details" section
004b939 bitbake: lib/bb/utils: add docstring for contains()
524d04c ca-certificates: support Toybox
ecaf12e oetest: make console output more verbose
4946ecf dhcp: CVE-2016-2774
c219c6d buildtools-tarball: fix perl being included when building with ipk
9fe7738 buildtools-tarball.bb: fix unexpected operator
ed07f43 lib/oeqa/selftest/base.py: Correct a reference to meta/lib/oeqa/selftest
8953d83 oe-selftest: Correct the usage examples
dee47ad devtool: sdk-update: reset git metadata on update
396e64d build-appliance-image: Load TUN at startup
55068b1 default-providers.inc: set openssl PREFERRED_PROVIDER to openssl
74ab080 bind: CVE-2016-2088
d488d78 rpm: Disable __sync_add_and_fetch_8 on nios2
9d2d1ae kernel: fitimage: Fix do_deploy taskhash mismatch
4693593 images: zero out the rootfs_extra_space in initramfs images
8beb671 ext-sdk-prepare.py: exclude do_rm_work from unexpected output; create unit test
0262bc5 bitbake: bitbake-user-manual: Updated the 'bitbake -h' output example.
890ccd3 bitbake: bitbake-user-manual: Updated "Conditional Metadata" section
20a0121 bitbake: bitbake-user-manual: Updated discussion about using "inherit"
9f374c4 bitbake: providers: Add PREFERRED_RPROVIDER support
4b8b110 bitbake: providers: We don't depend on previous build results
8e7282c bitbake: cooker/knotty: Prefix parse logs with filename being parsed
1131303 bitbake: cooker: pass exception to finishAsyncCommand
ffa2ca0 fs-perms.txt: fix ROOT_HOME's permission
fd66a38 Revert "fs-perms.txt: fix ROOT_HOME's permission"
9ec9557 buildstats: Fix tracebacks for early task failures
7f9d01e default-providers: Update to use PREFERRED_RPROVIDER
76f4bbc oeqa/selftest/sstatetests: fix no-op sstate test
6326812 buildhistory: don't alter SDK creation stamps
bb40b5e dhcp: Enable update-rc.d service
27e202f meta/classes/qemu.bbclass: set -cpu of ppce5500/ppce6500 to e500mc
7c5823a shadow: Disable syslog for more commands
60a8719 devtool: upgrade: handle recipes where source is not first entry in SRC_URI
8353557 devtool: update-recipe: handle where SRC_URI is appended to with +=
aab3c8d linux-yocto: make aufs4 optional
d75d2be linux-yocto: tiny and pin ctrl config updates
8547cbf linux-yocto/4.4: BXT enablement
ffad386 linux-yocto/4.1: mainline SPI backports
4ba33a3 linux-yocto/4.4: gpio-pca953x: fix the "drive" property cannot read/write
86571db devtool: don't copy .git when building the eSDK
83eac65 package.bbclass: improve permission handling
eeae2ac fs-perms.txt: fix ROOT_HOME's permission
1db3dc8 runqemu: let ramfs equal to cpio.gz
a8c8e81 gcc-common.inc: String format tweak for available tunes
a7c426a pbzip2: fix LIC_FILES_CHKSUM following 1.1.12 -> 1.1.13 upgrade
1229009 pbzip2: don't skip do_configure
1e4ee30 useradd_base.bbclass: remove flock option '-w'
cb45ef3 matchbox-keyboard: Hide desktop launcher
69e20ca npm.bbclass: Stop packagenames containing underscores from being generated
c3c55478 bind: CVE-2016-1285 CVE-2016-1286
c4387a8 image.bbclass: add DEB_{PRE, POST}PROCESS_COMMANDS to rootfs_command_variables list
967bc74 rootfs.py: apply ROOTFS_POSTINSTALL_COMMAND to all package formats
f7352ca wic: fix bug in handling fsoptions
b2f5de5 buildtools-tarball.bb: set TOOLCHAIN_NEED_CONFIGSITE_CACHE to null
a460b04 rpm: more verbose errors in rpmTempFile
a43991d rootfs-postcommands: handle broken links when writing manifest
2c81e17 socat: Use c_ispeed and c_ospeed based upon libc
5c8124d archiver: Improve debug output
e912c46 kbd: remove uclibc-stdarg.patch
965fd3c image.bbclass: use max() instead of indexing booleans
6d85874 linux-yocto-tiny: fix KBRANCH
440d949 sudo: fix pam config on systemd systems
3fd5a6d sysvinit: make lastb.1 an alternative
175263e lib/oe/lsb: sanitise the distro identifier
9262d2f package.bbclass: handle links in sorted order
29cf263 sanity: allow sftp and ssh mirrors
f503317 toaster.bbclass: improve package information collection
88f4178 rsync: remove upstream's rebuild logic
8d59d06 rsync: pass cached configure values through the right variable
384e41c rsync: don't install acinclude.m4
e80800e Revert "oeqa/selftest/wic: add test case for sparse images"
45c0763 Revert "wic/utils/partitionedfs.py: assemble .wic images as sparse files"
e0e5426 bitbake: runqueue: Improve 'mulitiple .bb files are due to be built' message
380004b archiver: Ensure sstate-inputdir directory is created
3ad70a5 linux-yocto-tiny: fix COMPATIBLE_MACHINE
0e59727 glib-2.0: Put glib-compile-schemas back in -utils
d27ca36 oeqa/runexported.py: Fix exported test
85dbd7b oeqa/selftest/sstatetests: split 32/64 build host from no-op action tests
57be6dd util-linux: take ownership of hwclock if installed
acc1f96 meta: remove redundant ac_cv_sizeof_off_t assignments
92759d8 meta/site: remove sizeof_off_t
5602f64 archiver: Fix ASSUME_PROVIDED issues
fab626c distrodata: Exclude DATETIME reference from sstate checksum
faaeaf9 build-appliance-image: Support for VirtualBox guest additions
778121a local.conf.sample: Make it possible to override EXTRA_IMAGE_FEATURES
f947c27 poky.conf: add Fedora 23 to supported distros
f33a110 maintainers.inc: remove adt-installer
83d4fab local.conf.sample: remove reference to adt
52cfdb6 bitbake: toaster: fixes for customimage package not found
dae4ffb bitbake: data_smart: Restrict expansion regexp to not include : characters
7e739ac bitbake: tests/utils.py: test origvalue in a callback matches what is expected
e1e459e bitbake: lib/bb/utils.py: Fix a bug in edit_metadata() that could corrupt vars
43150ab oeqa/selftest/wic: add test case for sparse images
29bc2f7 wic/utils/partitionedfs.py: assemble .wic images as sparse files
7fdb061 image-vm.bbclass/image_types.bbclass: IMAGE_NAME -> IMAGE_LINK_NAME
04e1978 image_types.bbclass: fix elf
513ea49 image_types.bbclass: set nodesize for btrfs
bad434b libxml2: fix AM_PATH_XML2
9fe3d01 useradd_base.bbclass: prevent variable expansion in $opts
fb8e5f9 extrausers.bbclass: drop retry count for perform_user/group* calls
f737af4 build-perf-test: add eSDK installed size to metrics
50f5ca3 rpm: brace expansion is a bashism
66ecbd3 openssl.inc: minor packaging cleanup
e38ec0c systemd-systemctl-native: fix unit detection
4019058 apr-util: fix path in rules.mk for nativesdk
bdf453f bdwgc: installed-vs-shipped for nativesdk
12ca8df libsolv: fix installed-vs-shipped for nativesdk
c88c894 desktop-file-utils-native: disable emacs
d4f6c0e toaster: add DL_DIR and SSTATE_DIR to oe toasterconf
69b3f87 toaster.bbclass: strip task from the target
aa45c75 x11-common: Add PACKAGECONFIG for screen blanking
d366a33 opkg-utils: re-do find/ls code to not fail on filenames with spaces
5e360ca image-live.bbclass: fix iso + efi only
f5adb23 Add missing runtime dependency to python-pygobject
0720425 devtool: Create unlocked-sigs.inc containing items in the workspace
64cca7e sstatesig.py: Add a method to "unlock" recipes
1cb99dd populate_sdk_ext.bbclass: Enable locked sigs errors
2431ed7 sstatesig.py: Improve the SIGGEN_LOCKEDSIGS_TASKSIG_CHECK message
7e90280 sstatesig.py: Split single locked sigs check into multiple checks
7ce800c toasterconf.json: Set default distro to nodistro
1b7b548 dev-manual: Updated poky-floating-revisions file snippit example.
8d9e233 dev-manual: set correct task name for do_kernel_configme
6971029 poky-floating-revisions: Fix typo
14e2b90 toasterconf.json: Add DL_DIR and SSTATE_DIR to poky toasterconf
296dfbc build-appliance-image: Update to master head revision
00c4c9b poky: Convetion is 2.1, not 2.1.0
8cd1dec build-appliance-image: Update to master head revision
ecd58bb poky.conf: Bump version for 2.1.0 krogoth release
e955b5d bitbake: Update version to 1.30.0
4fd14e3 build-appliance-image: Update to master head revision
133224f documentation: Fixed references using the DISTRO_NAME variable
3831ca0 documentation: Updated release date in manual history tables.
b590fab dev-manual, ref-manual, sdk-manual: Removing oprofile references.
d2084cc Makefile: Removed adt-manual support
2677098 mega-manual: Removed the adt title .PNG file.
d9b4c80 README: Updated to remove the ADT manual and add the SDK manual.
9796cbb mega-manual.sed: Removed adt-manual processing
aa4b72b yocto-project-qs: Updated the minnowboard example.
f2505af poky.ent: Added lower-case distro name variable.
ee42a9b kernel-dev: Applied review comments to "Adding Recipe-Space Kernel Features"
d57fe7c ref-manual: Updated the PREFERRED_VERSION variable description.
53bade8 dev-manual: Added new section describing hardware and non-hardware config
763ae4e ref-manual: Updated verbiage on proxy handling
a1295ed ref-manual: Updated PREFERRED_VERSION variable description
879eec2 ref-manual: Updated debugging tips and tricks
23dbf81 kernel-dev: Added new "Adding Recipe-Space Kernel Features" section.
f30bfe9 kernel-dev: Updated the "Kernel Metadata Location" section.
53729bc sdk-manual: Removed three sections of writer notes.
9f0c571 sdk-manual: Applied review edits.
d4bdafa sdk-manual: Added sections in Appendix B.
d94fa00 dev-manual, profile-manual: Removed oprofile section and link
4f3dfa8 bitbake: bitbake: update LICENSE file with QUnit details
013984d bitbake: tests: browser Add test to run the js unit tests
7609888 bitbake: toaster: views jsunittest Add MACHINE and an extra layer to test project
fbc2c5d bitbake: toaster: tests Set MACHINE for the test projects
cb6b4eb bitbake: toaster: Add quint to project so that it can be used offline
18cb7fe bitbake: toaster: add rev dep column to image detail pages
7a309d9 bitbake: buildinfohelper: work around unicode exceptions
860cba8 bitbake: toasterui: update build in internal state
acb9407 bitbake: buildinfohelper: fix KeyError
52c8740 bitbake: toaster: get bitbake location from BBBASEDIR
f5d3ef6 bitbake: toaster: export BBBASEDIR variable
71ff9b9 bitbake: toaster: update projectconf.html for DL_DIR and SSTATE_DIR
705d44f bitbake: toaster: update view to support DL_DIR and SSTATE_DIR
4aafcae bitbake: toaster: use empty token
5ce4665 bitbake: toaster: runbuilds Clean up runbuilds
55b6fab bitbake: toaster: runbuilds Make runbuilds aware of the build CANCELLED state
f4cee88 bitbake: toaster: models Exclude the CANCELLED builds from get_number_of_builds
296d373 bitbake: toaster: mrb_section template Add build cancel button
f1b49dc bitbake: toaster: tables BuildsTable exclude cancelled builds
22242ae bitbake: buildinfohelper: Add handler for cancelling a build
9dcb9cb bitbake: toaster: bldcontrol models Add a cancelling state the BuildRequest
dfa8510 bitbake: toaster: models Add cancelled state to build outcome
5f862bb bitbake: toaster: update BuildEnvironmentController and BitbakeController
0db62c5 bitbake: toaster: libtoaster Update implementation of startABuild and cancelABuild
afab95c bitbake: toaster: xhr Update the implementation of the build cancellation request
eead032 bitbake: toaster: Move xhr calls for starting and stopping builds
f5aa970 bitbake: toaster: bldcontrol Add forceShutDown function to BitbakeController
d6992a8 bitbake: toasterui: shutdown on BuildCompleted event
c4ae028 bitbake: toaster: use bash explicitly
4adddfd bitbake: toaster: fix jethro build
b1a919a bitbake: toaster: update conf/local.conf
590a815 bitbake: toaster: stop bitbake server after the build
a8f6001 bitbake: toaster: add new parameter to _shellcmd
a43a16b bitbake: toaster: reimplement triggerBuild
ab18c20 bitbake: toaster: modified setLayers API
22fba9b bitbake: toaster: add brbe parameter to triggerBuild
829a0bd bitbake: toaster: remove release API
7068e8a bitbake: toaster: remove startBBServer API
9d4c62d bitbake: toasterui: fix brbe reporting
5bcce68 bitbake: buildinfohelper: improve handling of providermap
61b6b98 bitbake: uievent: improve BBUIEventQueue code
0b0d754 bitbake: toasterui: add brbe parameter to buildinfohelper
94ac3f0 bitbake: toaster: set BITBAKE_UI environment variable
e23a23b bitbake: toaster: get rid of noui option
f77baec bitbake: toaster: don't start bitbake server
4127fef image_types: use compress framework to produce checksums for images
60786b8 runqemu-gen-tapdevs: Add note about NetworkManager & tap devices
634aeed libtool: fix contaminated path to lt_truncate_bin
298d875 create-pull-request: fix for newer git
4faeff9 wget: fix build when len(TMPDIR) == 410
b667f4d sanity.bbclass: fix a hardcode in check_path_length()
94b3583 grub: remove unused 0001-Fix-build-with-glibc-2.20.patch
ef163ab glibc: remove unused CVE patches
b050ab2 clutter-gst-3.0: remove unused enable-tests.patch
064ebd5 cmake: remove unused dont-run-cross-binaries.patch
a71db4c tcl: remove unused fix-configure.patch
476eeea rpm: remove two unused patch
3d56864 ffmpeg, gstreamer1.0-libav: add textrel INSANE_SKIPs
8cc10a9 ffmpeg: Make configure options explicit
45c1944 bzip2: set correct soname
cbe33ec useradd.bbclass: remove user/group created by the package in clean* task
c115740 bitbake: fetch2/git.py: remove .indirectiondir workaround
4f07c22 bitbake: persist_data: Return str instead of unicode for sqlite3 text queries
d8f1f42 scripts/oe-selftest: avoid the creation of coverage file when coverage not installed
6e5e225 scripts/oe-selftest: remove coverage file if any coverage option is given
5edfec4 scripts/oe-selftest: remove unneeded coverage warning
8109e93 patch.bbclass: remove useless path assignment
7963613 gstreamer: remove now-redundant expansion in do_split_packages
37f4f5b package: do_split_packages: expand variables in extra_depends
2ed2089 xf86-video-intel: Add patch to fix some poor image quality
c1436b3 sanity: Increase minimum git version to 1.8.3.1
672545b scripts/oe-buildenv-internal: Fix regression in BB_ENV_EXTRAWHITE setting
f7fed7c license.bbclass: fix warnings when run in unprivileged "container" env
43071a0 externalsrc: avoid race in temporary git index file
f4f1d20 scripts/lib/bsp/help.py: Typo in help for yocto-bsp create
1bd2c8e bdwgc: use github repo for source location
0e6743b xf86-video-intel: Add patch to allow UXA to build
21e31c2 package_manager.py: better error handling in opkg's package listing
f2d5e20 systemd: make systemd-serialgetty optional
e699404 ncurses: reorder PACKAGES
f94ad4d bluez5.inc: remove obsolete workaround
a0cd8c0 buildtools-tarball: Add texinfo (for makeinfo)
9877795 cogl: fix G-I .typelib installation
b13184c classes/buildhistory: fix grammar in comments
e5c0a9f classes/buildhistory: fix filtering of depends-nokernel.dot
4d364f2 classes/buildhistory: optimise getting package size list
af5f423 bitbake: siggen: Ensure tainted stamps are accounted for with writing custom stamps
47e9e12 bitbake: siggen: Fix nostamp taint handling
8033627 bitbake: siggen: Add checksum recalculation/checking code
3e1b5e0 bitbake: siggen: Fix check calculation problem with file_checksums
39b637c bitbake: siggen: Drop misleading duplicate method
2c722e2 bitbake: tests/fetch.py: Improve unit tests for trusted network check
cf6d12d bitbake: fetch2: BB_ALLOWED_NETWORKS should not care about port numbers
158575c bitbake: toaster: orm better detect requires during CustomImageRecipe generation
c634473 bitbake: toaster: Correct typo on build form help text
c9ad1e6 bitbake: toaster: buildinfohelper Add additional metadata to the built layer
072a0b3 poky: Exclude DATE from DISTRO/SDK_VERSION checksums
f3c029f build-appliance-image: Exclude DDATETIME from task signature
7833eb4 image-vm: Exclude DISK_SIGNATURE_GENERATED from task signature
85ff4ff populate_sdk_ext: Exclude BBTASKDEPDATA from task signature
66412ab opkg-utils: opkg-build exit when fail to list files.
6b8f8a4 kernel-yocto: enforce SRC_URI specified branch
6ebd43c linux-yocto/4.4: UVC: Add support for R200 depth camera
6d2299f linux-yocto/4.4: fix PAT for 32bit x86
5559301 Revert "linux-yocto: Work around PAT issue on qemux86"
686c74f linux-yocto-dev: bump to v4.6-rcX
b3ba813 linux-yocto/4.1: ahci: backport AHCI runtime PM
8f7bbea linux-yocto/4.4: gpio-pca953x: add PCAL9535 interrupt support
4a50c05 linux-yocto/4.1: telemetry and dmaengine backports
31a10cb wic/isoimage-isohybrid.py: change cpio generated uid&gid to root
5cabf3b wic/isoimage-isohybrid.py: use glob to find initramfs location
5c60c36 bluez5: add ptest support
fc8b24d oe/patch: print cleaner error message when patch fails to apply
bf14014 oe/patch: more detailed error reporting
a2bf9e3 insane.bbclass: avoid false positives on library location
1f2f43c grub-efi.bbclass: use GRUB_ROOT rather than APPEND for root device
bf58526 bitbake.conf: Add BB_WORKERCONTEXT to HASHBASE_WHITELIST
1c1e851 gdb-cross-canadian: use PACKAGECONFIG for python and readline
370a50a base: Fixup PACKAGECONFIG incorrect mappings
dea3423 classes/packagegroup: Refactor code to be simpler
5defbcd default-distrovars.inc: remove libassuan from LGPLv2_WHITELIST_GPL-3.0
58d8123 libassuan: use package specific licensing
1f2a01b init-install-efi.sh: remove all root=foo from grub.cfg
3ce7d8c init-install.sh: fix disk_size
46eed0a ltp: fix test_proc_kill hanging
207ee90 ltp: add periodic output for memcg stress test
feafad1 epiphany: Depend on intltool-native for configure
2510239 image: Fix debugfs image type recursion loop
7dcb4c4 bitbake: toaster: tests Migrate landing page tests to Selenium
5b848fa bitbake: toaster: tests Migrate all projects page tests to Selenium
f2a38ea bitbake: toaster: tests Migrate project builds page tests to Selenium
961cd90 bitbake: toaster: tests Migrate all builds page and project page tests to Selenium
f859a3d bitbake: toaster: tests Migrate to Selenium for UI tests
965c72c yocto-bsp: Set correct default branches and branches base for i386, qemu and x86_64 archs
d110eba selftest/signing: Use packagedata to obtain PR value for signing test
34f11b5 lib/oe/packagedata: Add import os
0012b90 base.bbclass: avoid duplicate call to d.getVar('LICENSE', True)
efe73cb base.bbclass: drop obsolete HOSTTOOLS_WHITELIST_GPL-3.0
5293b83 man: use BUILD_CC and target include files for configure
5121705 scripts, lib: Don't limit traceback lengths to arbitrary values
3168134 bitbake: bitbake: Don't limit traceback lengths to arbitrary values
88ea0b9 image-vm.bbclass: remove invalid code
4d1df2c image-live.bbclass/image-vm.bbclass: remove duplicated code
d6d7526 bootimg.bbclass: merge it into image-live.bbclass
723fa56 boot-directdisk.bbclass: merge it into image-vm.bbclass
9e588481 man: fix several annoying compile/build warnings
aa13b97 image.bbclass: Make unneeded packages for a read-only rootfs configurable
4dde12f relocate_sdk: additional error checks
22bd875 systemd: fix build with gcrypt PACKAGECONFIG disabled
4b77909 devtool: modify: call shutdown on tinfoil when done
43da712 toolchain-shar-extract.sh: ensure all_proxy is allowed through
2aec71e oe-publish-sdk: exclude sstate-cache if publishing minimal SDK
8ef7016 oe-publish-sdk: prevent specifying a directory for the SDK argument
591b97c classes/populate_sdk_ext: support setting vars from environment at build time
c37d542 scripts, lib: Don't limit traceback lengths to arbitrary values
8049f25 pyton-numpy: Add definition of off_t size
b75505e image-live.bbclass: DEPENDS on syslinux
3ece012 ldconfig-native: Fix ELF flags on 64-bit binaries
d492aec recipes-support/rng-tools: Change runlevel start from S to 2, 3, 4, 5.
ab5c62e oeqa/runtime/parselogs.py: Add systemd unit circular dependencies errors.
9be3fb2 systemd-serialgetty: allow baud rate overriding
cf6788c psmisc: Remove including sys/user.h and __WORDSIZE
ede11b6 selftest: Added testcase decorator to tests
ccfe48c linux-yocto: add overlayfs feature
6ae0224 linux-yocto/4.4: broxton and usb type-c backports
e1ae3ee linux-yocto/4.4: drm/i915/skl: Fix DMC load on Skylake J0 and K0
0a1d621 linux-yocto/4.1: Intel Broxton: pwm backports
6ce8802 linux-yocto/4.1: Apollo Lake/Broxton mmc backports
a256628 linux-yocto/4.1: i2c: designware: Backport i2c patches
fbd209d linux-yocto/4.1: device property backports
ccf1b33 linux-yocto/qemuarm64: enable 32 bit compatibility
dacf9f2 linux-yocto/4.1: SMBus/iTCO backports
ab6fd48 default-distrovars.inc: remove gnutls + libtasn1 from LGPLv2_WHITELIST_GPL-3.0
2123a7e sanity.bbclass: Use pythonexception to raise real exceptions without backtraces
6af88d8 sanity: Require bitbake 1.29.1
1b2df6e uninative: Switch md5sum -> sha256
f719386 bitbake: cookerdata.py: remove slash in the end
e26087f bitbake: Bump version to 1.29.1
d73da22 bitbake: build/utils: Allow python functions to execute with real exception handling
672c07d bitbake: fetch2: Ensure that incorrect checksumed files are always renamed
2554be4 bitbake: cooker: fix CookerParser.shutdown()
53b5dc0 gcc: Fix musl ldso name for mips64
dd31bca selftest/buildoptions.py: use INHERIT +=
71db079 archiver.bbclass: addtask do_deploy_archives_setscene
1ca71e5 bitbake: cooker: Ensure bbappend order is deterministic
292c3e8 bitbake: checksum: In FileChecksumCache don't follow directory symlinks
326fc29 gcc-5.3/gcc-4.9: -fdebug-prefix-map support to remap relative path
9e20f94 ptest-runner_2.0.bb: Update recipe to point git.yoctoproject.org repo.
437841c man: fix src/Makefile to work with parallel make
abb5b46 oeqa/selftest/bbtests: Test bbappend order
ddbeb56 bitbake: cookerdata: Improve handling of ParseError
6dff639 gcc: Backport fixes for musl ssp configuration
ab20659 siteinfo: Fix musl 64bit targets
cd16b65 musl: Update to tip
0883aff buildhistory.bbclass: create image directory when needed
c093f7c runqemu: fix for iso
f1f9f89 init-live.sh: fix overlay fs
4e7eaed init-live.sh: fix ROOT_MOUNT
1622077 no-static-libs.inc: build static libusb1-native
b3e4a31 sstatesig: Ensure we keep native depends for allarch recipes
528a890 oe-selftest: generate .env only in test_image_env
21823cb build-appliance-image: Update to master head revision
7d251f7 build-appliance-image: Fix permissions
60656d0 bitbake: fetch2/wget.py: _check_latest_version_by_dir fix prefix detection
45ee2b1 bitbake: fetch2/wget.py: _check_latest_version_by_dir use group names
55cd35b conf/bitbake.conf package.bbclass: fix dbg package not contain sources while -fdebug-prefix-map used
e2b919c externalsrc: remove nostamp from do_configure
bbfc210 externalsrc: do not use do_configure[nostamp] for git srctrees
9ee403b archiver.bbclass: Just archive gcc-source for all gcc recipes
37683ef oeqa/utils/ftools: improve remove_from_file algorithm
3a934a8 scripts:/oe-selftest: Use timestamp instead of test names in coverage data file
71304d8 xcursor-transparent-theme: upgrade to latest git revision
7c5343a gdb: Fix build on mips64/musl
856be1f libunwind: Fix build on mips/mips64 for musl targets
dd61341 toolchain-shar-extract.sh: check the length for target_sdk_dir
c3c793b relocate_sdk: fixed .gccrelocprefix section handling
cc97d57 glib-2.0: Fix packaging
cef8bc9 gio-module-cache: Add class for Gio modules
0cda9d8 glib-2.0: Install gio-querymodules in main package
9ac1b6f oe-git-proxy: support username / password in http proxy
a15541d oe-git-proxy: also check all_proxy and http_proxy env variables
92b2bc5 wic: Update after task ordering changes
d6cb46c image.bbclass: run wicenv task only for wic images
5cb7705 wic: fix type of no-table option
1209eb2 matchbox-desktop: Do not close desktop on alt-F4
0361676 rootfs-postcommands: don't write manifest when IMAGE_MANIFEST empty
abd5b24 bitbake.conf: rename 'gobject-introspection-data' machine feature to 'qemu-usermode'
f81065f selftest/devtool: Update after make PROVIDER changes
25a04ee make, remake: make them properly exclude each other
f3a92ff kernel.bbclass: consider .csp firmware files
0569b69 tzdata: update to 2016c
a7e726a tzcode: update to 2016c
201d9d3 icecc.bbclass: replace icc with icecc
da00f6c icecc.bbclass: expand package arch
3f1702c icecc.bbclass: add icc_is_allarch inherit check
39170fe classes/sanity: use proper multi-line string literals
33a6135 oe-buildenv-internal: simplify derivation of BB_ENV_EXTRAWHITE
c6ab828 u-boot.inc: Add sub-dir support for SPL_BINARY
ddedab4 quilt: run ptest as normal user
afa4d5e site: Cache config vars for ccache
04344eb gdb-cross: use PACKAGECONFIG for python and readline
5005cab add !meta-poky to .gitignore file
1dd9348 scripts/lib/bsp/help.py: Add missing options to yocto-bsp help and usage
54eca75 poky-sanity.bbclass: update conf/templateconf.cfg for existing installations
2b992f3 site.conf.sample: fix reference to oe-git-proxy script
af63b49 conf-notes: remove reference to adt-installer
1d219ce linux-yocto: Update SRCREV for genericx86* for 4.4
8d4f43e linux-yocto: Update SRCREV for genericx86* for 4.1
84d5924 bitbake: fetch2: Handle lockfiles for file:// urls redirected to mirrors
b036afb bitbake: toaster: get all dependents for pkg for removal
9bf98a9 bitbake: toaster: new customise package-remove modal dlg
d5a419d bitbake: toaster: show full list of dependents to remove
fda94f4 bitbake: bitbake: fetch2/gitsm: Fix fetch when the repository contains nested submodules
1341c17 pseudo: backport a patch to fix xattr removal
07f0af3 uninative: don't try to relocate static binaries
c3c0d0a lib/oe/qa: add method to check if static or dynamic linked
10b6037 uninative: ensure patchelf errors are visible
86d7e44 libmad: remove use of obsolete _thumb over-ride
e7395c8 perf: package python modules into perf-python
b47225f perf: fix python scripts QA errors
ea8b914 linux-yocto/4.1: MFD backports
b6563a1 linux-yocto/4.1: device property : Backport device property patches
46baceb linux-yocto: ktypes/standard: Add tmpfs-posix-acl feature
bdf6b20 linux-firmware: Break out some additional firmware
6d8141f linux-firmware: Clean-up and sync license data
cea2a21 linux-firmware: Collapse iwlwifi firmware blobs for 7260 and 7265
3b3fe1d linux-firmware: Update to latest HEAD
d7cf2c3 archiver.bbclass: Fix tar name for git repositories
2cb4cb7 archiver.bbclass: Fix gcc-source corner case
c29eea0 archiver.bbclass: Fix use of ARCHIVER_WORKDIR and ARCHIVER_OUTDIR
8b7ee6e archiver.bbclass: Don't expand python functions in dumpdata
bc100b3 bind: /var/cache/bind
04d883c sysvinit: downgrade ALTERNATIVE_PRIORITY[mountpoint]
688d9a6 util-linux: split out util-linux-mountpoint
85ff75d gconf: fix buildpaths QA issue
7f7c9ab python-pygobject: use Python 2 instead of Python 3
e33124f sanity.bbclass: check host tool dependencies on change in NATIVELSBSTRING
4fe64d7 libunwind: Fix build with fstack-protector on musl
4aa08b8 ltp: Fix build on x86/musl
959b7f2 package.bbclass: Treat .node files same as .so when checking what to strip
e0bc781 bootimg.bbclass: only inherit syslinux when pcbios
1b1de89 grub-efi.bbclass: make it can build vm and live together
4ebaeb2 bootimg.bbclass: fix settings for grub-efi.bbclass
af1f77a pixz: Fix build on big-endian/musl systems
421289c sanity.bbclass cleanup
93e411e matchbox-wm: Update to fix XChangeProperty datatype issue
c843022 matchbox-panel-2: Fix Home-button icon load issue
01f6818 gstreamer1.0: fix introspection support also for git recipes
171adb1 gstreamer1.0-plugins-bad: fix incorrect handling of Cflags in gstreamer-gl.pc file
6462d08 x86-base.inc: suggest the latest kernel
c5c9ed6 at: fix configure option with/without-selinux
9b2b1f0 no-static-libs: just like target and native, nativesk-libcap doesn't like unrecognised options
bf90d0c linux-firmware: package firmware for Marvell 88W8688
cd17ab0 tune-arm926ejs: Handle missing thumb suffix
5b70c7e nativesdk-coreutils: a lot of warnings fixed
b47c53b runqemu-internal: split the code into functions
fae732f runqemu-internal: cleanup unsed code
e469bb7 runqemu: simplify checking for iso and ramfs
3610329 runqemu: add support for qcow2 and vdi
d85ca4a runqemu: remove ISO and RAMFS from help text
58bc854 runqemu: simplify the checking for vm images
6716eb2 runqemu: fix ROOTFS for vmdk
258cfa8 python(3): Disable tkinter
5988b5c selftest/signing.py: RPM_GPG_PASSPHRASE_FILE -> RPM_GPG_PASSPHRASE
3e5c5fe gpg_sign.py: get rid of pexpect
05d7e0d rpm: check _gpg_passphrase before ask for input
13a31b1 oe-publish-sdk: fix remote publishing
9926425 oe-publish-sdk: improve help output slightly
905286c oe-publish-sdk: drop SDK installer file from published output
0523378 devtool: add: create git repository if URL specified as positional argument
11c1d30 devtool: add: delete externalsrc files on npm recipe do_install
552a68a devtool: configure-help: fix error if do_configure not already run
eab3f06 bitbake.conf: whitelist proxy variables in config hash
58d2e56 classes/populate_sdk_ext: parse metadata on minimal SDK install
0684572 devtool: sdk-install: add option to allow building from source
50addfb classes/distutils*: don't hide logs when setup script fails
0ec30c7 classes/packagegroup: drop complementary -ptest if ptest not in DISTRO_FEATURES
d96ea29 classes/packagegroup: fix dbg/dev/ptest complementary packages
b58e5b1 bitbake: bitbake: xmlrpc: set single use mode differently
2df514b sdk-manual: Added note for running remote apps with SSH port forw enabled.
12f5c25 poky.ent: Added code name for 2.1 release to the variable
64241e0 sdk-manual: Applied more review edits to the manual per Eggleton.
b44d9e5 ref-manual: Created distrodata and checkpkg tasks, updated distrodata class
54050ff sdk-manual: Applied 2nd round of review edits.
6db8cbc sdk-manual: Applied review edits to the manual.
922eaeb sdk-manual: Updated the SDK devtool modify flow diagram.
2bbf77a dev-manual: Fixed a grammar error
286b76f sdk-manual, mega-manual: Updated the SDK devtool modify diagram
c3946bc dev-manual, profile-manual, ref-manual: Updates to remove meta-toolchain
7233e35 sdk-manual: Edits to add extensible SDK configuration sections.
b31bf7c ref-manual, sdk-manual: Changed section heading.
670735e ref-manual: Added some SDK manual support to introduction
266742b profile-manual: Updated screen output for oe-init-build-env
0654224 kernel-dev: Changed a link from an example to in-text.
19e3648 dev-manual: Edits from a 2.1 read-through.
a389684 poky.ent: Fixed a typo in one of the variables "ftar" to "tar"
b5d3065 poky.ent, bsp-guide: Removed eMenlow example and updated 2.1 variables
884b528 yocto-project-qs: Performed a read-through edit.
4b42385 poky.ent: Updated copyright year and version variables.
ae48b1f mega-manual: Added two new sections for the sdk manual
815d686 sdk-manual: Added some intro stuff about the SDK
4c5157f ref-manual: Resolving a conflict
4306f7f sdk-manual, mega-manual: Added new figure for Eclipse flow.
0bb6e48 sdk-manual: WIP on the book.
5a64701 sdk-manual, mega-manual, Makefile: Added new figures
32629e0 Makefile: Resolving a conflict
af40e9a sdk-manual: Added a new figure for installed extensible sdk directory.
62477889 sdk-manual: Applied some "red" text formatting to indicate notes
7ab8afa Makefile: Added the ".png" part to a figure I forgot.
fc43555 sdk-manual: Added a red-text "role" to the style sheet.
d07100d sdk-manual: Added new section detailing installed SDK directory.
b750729 sdk-manual-customization: Fixed XSL Appendix numbering parameter
ad7a994 Makefile: Updated the figure list for the mega-manual.
890f721 sdk-manual: WIP - Various small edits as WIP
f15f96c sdk-manual: New content for outline purposes.
4643b04 sdk-manual: Updated with two new appendices for new files.
d05566b sdk-manual: Added sdk-environment.png diagram.
0936eed sdk-manual: Added two appendix files to SDK Manual.
6996a1c Makefile: Added sdk-environment.png to figure list for SDK Manual
6cdb356 toaster-manual: Edits to a previous patch.
77594c0 mega-manual, Makefile: Added support for three new toaster figures.
00fe95d toaster-manual: Explain the local release
d06c7b8 documentation: remove all references to Hob
be8af37 ref-manual: Updated COREBASE_FILES variable.
5c7e5aa bitbake: bitbake-user-manual: include/require checks current directory
7ec8f28 bitbake: bitbake-user-manual: Updated the "inherit Directive" section.
75cba54 bitbake: bitbake-user-manual: Updated the copyright year to 2016
2918b50 bitbake: toasterui: remove ParseStarted from the event list
ab2abd4 bitbake: toasterui: Remove the excessive exception logging
d8137be bitbake: cache: Make BB_DONT_CACHE variable external
1d1aaa2 bitbake: toaster: orm generate CustomImageRecipe contents try secondary path
5c49230 bitbake: toaster: localhostbecontroller put generated layer in the builddir
b60c994 bitbake: toaster: localhostbecontroller Allow file:/// uri type for git repo
3025092 bitbake: toaster: orm Add a constant for the CustomImageRecipe's layer name
3df6551 bitbake: toaster: localhostbecontroller Don't clear out toaster custom layer dir
2f2f784 parselogs: add new whitelist entries to address 4.4.3 issues
8037ba4 bitbake: bb/tests/fetch: Update cups url
dab6d59 oe-buildenv-internal: Correct the sed expression which updates $PATH
068afc5 tzdata: update to 2016b
e140272 tzcode: update to 2016b
c0b3667 ffmpeg: Remove RSUGGEST=mplayer
e528a0a lttng-tools: Remove lttng-ust from PACKAGECONFIG for musl
42b9bdf packagegroup: Disable packages not available on musl
f148a2e world-broken: Add packages broken on musl
624ca6a siteinfo: Move apr configure cache to common-linux
90234f1 parselogs: add new whitelist entries to address 4.4.3 issues
13a2a3f u-boot: Upgrade to 2016.03 release
ecf3396 grub: add -Wno-error=trampolines to native CFLAGS
07515b0 dhcpd: create dhcpd user for dhcp dameon
b9ad80d valgrind: fix buildpath QA issue
7985006 gcc-5.3/gcc-4.9:Reuse -fdebug-prefix-map to replace -ffile-prefix-map
2faa718 gcc-5.3/gcc-4.9:replace build path with target path in __FILE__
76f10fd oe-buildenv-internal: Some clean up
4d1efc3 oe-buildenv-internal: Add variables individually to BB_ENV_EXTRAWHITE
39ac332 oe-buildenv-internal: Add paths to $PATH individually
dd5f2f7 oe-init-build-env*: Make them actually return failures
ea28de6 oe-init-build-env*: Remove unnecessary differences between the scripts
51aa00f oe-init-build-env*: Update/correct comment about specifying arguments
16fb9b8 oe-init-build-env*: Allow $OEROOT to be predefined
3173979 bluez5: allow D-Bus to spawn obexd in systems without systemd
10ef68f oeqa: remove RPM 4 self test
d915965 lib/package_manager: remove RPM4 support code
03fce73 smartpm: remove rpm4 patch
1e9de52 rpm: remove RPM 4
a7dd04d grub: fix documentation rebuilds
ee4f61b oe-selftest: Fixed --list-tests-by tag option
068e898 gcc-runtime.inc: set LICENSE for all gcc-runtime packages
788dfdd ParaTypeFFL-1.3: Add license file
62ddde6 externalsrc: use shared stamp directory if B=S
1969332 rpm: fix error when 'lua' is enabled
a31301e matchbox-keyboard: Update to latest HEAD to fix 64bit issue
40a55f1 oeqa/selftest/buildoptions: test read-only-rootfs
f64fdd2 oeqa/selftest/sstatetests: verify more variables don't impact the hash
ac347da gobject-introspection.bbclass: wrap comments at 80 columns
ae63b88 qemuarm64.conf: don't clear MACHINE_FEATURES
cad415d sanity.bbclass: allow customizing config file update error messages
96a5cb4 sanity.bbclass: fix success message when config file was updated
805aca8 sanity.bbclass: expand error messages for version checks
7d6801c lighttpd: fix /usr/lib/mod_cgi.so: undefined symbol: chunkqueue_written
5f7b9f0 valgrind: Disable nios2 support
aaaccc4 systemtap: Disable nios2 support
5857b20 lttng-modules: Add nios2 support
26248cd kexec: Disable on nios2
3e4d99b packagegroup-core-sdk: Disable sanitizers for nios2
797ffc8 bdgwc: Backport nios2 support
238e2c1 libatomic-ops: Backport nios2 support
7e83af3 selftest/buildoptions: Renamed one test case
0d9f515 python-numpy: Fix build on musl
e1f3f4c socat: Access c_ispeed and c_ospeed via APIs
bb4e6e0 watchdog: Disable nfs on musl targets
f00cca8 bdwgc: Check for getcontext() API during configure
51464e7 devtool: change config symlink name to .config.new
8c0148f systemd: Fix and expand ptests
427e369 oeqa/utils/testexport.py: add functionality for exporting binaries
2191623 init-live : make it easier to add custom boot targets
57a525c useradd_base.bbclass: replace retry logic with flock
5d06f00 image.bbclass: track ROOTFS_POSTUNINSTALL_COMMAND in do_rootfs vardeps
6129d86 eudev: split eudev-hwdb from eudev
9aa27fe openssl: don't move libcrypto to base_libdir
370419e xcb-util-image: Fix build with clang
8727975 musl: Update to get mips64 port
4653fdd dhcp: enable gentle shutdown
e382d96 coreutils: fix reporting 'unknown' by `uname -p' and `uname -i'
3b8cd1d ncurses_6: Improve installation
9cc65ed Revert "selftest: Added MACHINE = "qemux86" to tests that use runqemu"
3c5ee61 busybox: Drop -r passthrough patch
2c666af linux-yocto/4.1: usb: add usb_otg_caps to usb_gadget structure.
8dc9162 linux-yocto/4.1: Intel Broxton and Sunrisepoint-H: pinctrl and drm
99ad4c9 linux-yocto/4.1: powercap/RAPL: Backport powercap/RAPL
c4f544e linux-yocto/4.1: Thermal: Enable Broxton SoC thermal reporting device
123c2c6 linux-yocto/4.1: usb backports for Apollo Lake/Broxton
600b700 recipetool: create: don't create extra files directory unconditionally
8debfea local.conf.sample: Disable prelink by default
efa0881 oeqa/selftest/recipetool: Fix test_recipetool_create_simple
c9d269c Revert "packagegroup-core-x11-sato: add python-pygobject and gtk+3"
d24a39a oeqa/recipetool: Fix syntax error
55a1e52 oeqa/recipetool: Improve debugging output by adding dirlist
637b3c8 uninative: Add a fix for icu-native to use the correct ABI
9dbfbe9 scripts/oe-selftest: Add short names to most common options
681a452 gcc: Fix the license on GNU OpenMP
15c5b2a Revert "gcc: Fix the license on GNU OpenMP"
d5cdb48 perl: fix missing dependency for perl-misc
0eb52b9 classes/buildhistory: record a few more variables for extensible SDK
cbb4c5b package-deb: Ignore circular dependencies
fcc7ff0 package_deb: Fix python runtime error
9155b24 python-numpy: fix buildpaths QA issue
9e69963 python: move ast module into python-core
1a35166 xserver: require sufficiently new libdrm
36bf666 package_manager.py: Fix race condition in OpkgIndexer.write_index()
35be679 scripts/oe-selftest: Add search expression matching to run/list options
4489ef1 glib-2.0: relocate the GIO module directory for native builds
cf3402e image-buildinfo.bbclass: fix performance problems
e2fe28c linux-yocto/4.4: gpio-pca953x: add "drive" property
3d45853 python3: fix do_configure check platform triplet error
03b167d ncurses_6: Fix an install race condition
09eab6b build-appliance: make the inclusion of downloaded sources optional
8ea5cdc builder: remove hob from autostart
ff5d9f7 Revert "gstreamer1.0-plugins-XXX: move inherit gettext into common .inc file"
c99da8d musl: disable building of gobject introspection data
0dea50e machine/include/arch-x86: Make x32 ABI not supporting gobject-introspection-data
8c14c74 bitbake.conf: add 'gobject-introspection-data' to DISTRO/MACHINE_FEATURES_BACKFILL
2e27994 packagegroup-core-x11-sato: add python-pygobject and gtk+3
8b1fa2a webkitgtk: enable gobject introspection
7bd32b9 recipes-gnome: fix introspection support
efd37c5 python-pygobject: update to 3.18.2
ff3500b gnomebase.bbclass: do not disable gobject introspection
ac5cc0c gstreamer: enable gobject introspection
03cd714 libsoup-2.4: enable gobject introspection
c1d67e4 clutter: enable gobject introspection
0ec412b gtk+3: enable gobject-introspection
d6f8028 gtk+: enable gobject introspection
0d1e4b2 avahi: enable gobject-introspection
d2e0dc1 python-pygtk: remove the recipe
0c6d7cb avahi-ui: remove the dependency on python-pygtk by disabling avahi-discover
4fbf761 vala.bbclass: remove pre-packaged vapigen.m4 from tarballs
235455d vala: enable the use of vapigen by packages with vala support
d1b96f1 gobject-introspection.bbclass: add a class that enables gobject introspection
96b5847 gtk-doc-stub: remove introspection stubs
3a1d9fb gobject-introspection: Override GIO_MODULE_DIR when scanning
10e9977 gobject-introspection: add the recipe
3c66619 bitbake: fetch2/npm: fix ud.registry so that alternative registries can be handled
0155472 ref-manual: Updated "Application Development SDK" section.
4438460 ref-manual: Applied review edits to several SDK variables.
3c727ff ref-manual: Updated "Cross-Development Toolchain Development" section.
af1517c ref-manual: Updated "Build History SDK Information" section.
d9fc04b dev-manual, mega-manual: Updated "Application Development SDK" section.
357aa33 ref-manual, mega-manual: Updated "SDK Generation" section.
54490c0 ref-manual: Added several extensible SDK variables to glossary.
6dfd441 ref-manual: Updated IMAGE_PKGTYPE variable.
77f002c ref-manual: Updated "Cross-Development Toolchain Generation"
ee90cc6 ref-manual: Updated the "Build History SDK Information" section.
53dd8a0 dev-manual: Moved "Optionally Using an External Toolchain" to Tasks chapter.
9d76cfe meta: toolchain-shar-relocate.sh: Fix for extracting SDK in the same directory as SDK script.
054abad nettle: The variable named p in the patch file was incorrectly named.
93a5417 valgrind: Make dep on glibc-utils conditional on TCLIBC = glibc
40c9774 make 4.1: fix segfault when ttyname fails
7f27713 gcc: Disable libitm for MicroBlaze
81d58d6 sign_package_feed: add feed signature type
42f612c package_manager: sign IPK package feeds
c637783 signing-keys: create ipk package
14e809e gpg_sign: export_pubkey: add signature type support
0b088e0 gpg_sign: detach_sign: fix gpg > 2.1 STDIN file descriptor
2fccd8a gpg_sign: add local ipk package signing functionality
6bd6a2b systemd: add comment stating that resolved needs gcrypt
a5fd57d selftest/bblayers.py: Remove harcoded recipe files
dce7290 selftest/prservice.py: Sanitize package version when looking for stamp
cbd87f3 lsof: update UPSTREAM_CHECK_URI
57fb05a eudev: provide UPSTREAM_CHECK_URI
3f8d5bf toaster.bbclass: show packages that were setscened into existence too
39e1351 gcc: Fix the license on GNU OpenMP
c6aeef3 linux-yocto/4.4: Galileo updates
37b61b0 siteinfo: Add ppc64le support.
0265fcc nettle: disable static for 2.7.1
8660cd1 nettle: Security fix CVE-2015-8804
dae5715 nettle: Security fix CVE-2015-8803 and CVE-2015-8805
24aea3a glib-2.0: silence warnings when parsing headers for introspection
3331992 qemu: Limit paths searched during user mode emulation
b578a06 image-mklibs: handle position independent binaries
c706b5e libpam: define limits.conf as CONFFILES of package libpam-runtime
82dec46 perl-rdepends: Remove circular dependencies
815c36f rpm: Sync CVS to regular version
775f22e rpm: Fix musl integration with RPM5
001bdef gcc: Disable libitm for nios2
d53413d bitbake: server/process: Try connecting 4 times before giving up
0f01059 bitbake: toaster: models List only have the specified project's imported layers
0dcab02 bitbake: toaster: rework task buildstats storage and display
cc74a8a bitbake: toaster: use force_bytes to display non-ascii project names
aebc22d bitbake: fetch2: Make SRC_URI[md5sum] and SRC_URI[sha256sum] expand their values
d405f97 bitbake: xmlrpc: fix bug in setting XMLRPCServer.single_use
c50bdb3 bitbake: fetch2/npm: add missing URL argument to ParameterError
fbf27c4 bitbake: fetch2/npm: properly handle npm dependencies
ef6a451 bitbake: fetch2/npm: fix errors with some version specifications
ad50ce9 populate_sdk_ext: Correct commit 8b81bb56c69aabdea984352f8e267a9783c0bdbc
bc0e99d recipetool: create: shrinkwrap and lockdown npm modules
309b2e6 recipetool: create: support creation of additional files by plugins
2279eb2 recipetool: create: check if npm available if npm:// URL specified
9145500 recipetool: create: split npm module dependencies into packages
d46827c recipetool: create: add license file crunching
3fd244b recipetool: create: match *LICENSE* as a license file
2b6a352 recipetool: create: improve mapping for autotools program macros
1607fac recipetool: create: be more tolerant of spacing in configure.ac
9dca5c8 lib/sstatesig: skip shared_workdir when checking locked sigs
142bad3 python3: fix patching get_python_lib() in distutils/sysconfig.py
50d07e9 python3-native: use the previous version of python-config script
5dce2e3 qemu.bbclass: add qemu_wrapper_cmdline()
8b5afcd db: remove the NO_UPDATE_REASON and replace it a comment about RPM
5699c67 rpmresolve: It is not necessary to manually specify -lpopt
8ea55ba rpm: A number of the patches have been submitted upstream
6833c5d rpm: Enable specific crypto and digest settings via variables
59a4d99 security_flags.inc: Special flags are needed for RPM
007c284 rpm: Uprev to rpm-5.4.16 (pre) and rpm-5.4+cvs to current CVS head
a27ca6d yocto-bsp: Update templates to 4.4 kernel
2d0933c conf/distro/include: drop old recipes
1fd183e bblayers.conf.sample: remove BBLAYERS_NON_REMOVABLE
477b8fb poky: Enable uninative
1b7cc9c linux-yocto/4.4: explicitly enable ftrace in tracing fragment
aee7482 linux-yocto/4.4: iwlwifi: mvm: don't allow sched scans without matches to be started
2408f49 linux-yocto/kernel-meta: ktype refactoring: move DEBUG_KERNEL, EXPERT and EMBEDDED
9ac029b xmlto: tell xmlto where cp is
6d89b52 toaster.bbclass: improve how we gather buildstats for Toaster
4dd3e40 image-prelink: use STAGING_*_NATIVE variables
2193e9d strace: Backport fixes for compiling with clang
ee8ff42 ghostscript: 9.16 -> 9.18
3f5725c fontconfig: Revert changes made to FcConfigAppFontAddDir() recently
433d866 populate_sdk_ext: Make populate_sdk_ext nostamp
e186d6d systemd: binfmt should be added to SYSTEMD_PACKAGES only if binfmt is enabled
b051a95 license.bbclass: fix host contamination warnings for license files
f8a9774 oeqa/selftest/buildoptions: Test build does not fail without git rev
656aeff busybox.inc: add tail symlink so busybox can commit suicide cleanly
a321f4e avahi-ui: add dbus to PACKAGECONFIG
1bd4b72 avahi: add missing intltool-native build dependency
72f9e39 avahi: make dbus optional but default
424466b oe-setup-builddir: tidy up local.conf and bblayers.conf commentary
07919e9 net-tools: Add SCTP option support
e8254bc tune-corei7.inc: Fix PACKAGE_EXTRA_ARCHS for corei7-32
5346675 eudev: remove redundant udev_run assignment
adad264 xcursor-transparent-theme: use a version glob in the selftest bbappend
946d00c populate_sdk_ext: Update after uninative changes
ba57ba1 image.bbclass: support chaining compression (aka conversion) commands
5ac3dc7 image.bbclass: fix incomplete .rootfs customization
3322fa7 bitbake: toasterui: fix warning 'Unknown event'
621cbc8 bitbake: toasterui: exit on final events
8e138b7 bitbake: toasterui: make toasterui to work in build mode
0a61306 bitbake: toasterui: check if setEventMask succeeded
ac941ac bitbake: command: make setEventMask readonly
dd3da9a bitbake: toasterui: update list of events
f56fa5d bitbake: toasterui: reformat list of events
a71d32a bitbake: toaster: remove sshbecontroller module
3db71b4 bitbake: toaster: don't use sshbecontroller
790b2d1 bitbake: toaster: raise NotImplementedError
96535ba bitbake: toaster: bring back the strict directive
5b8b399 bitbake: toaster: change 'revision' to 'Git revision'
07ead98 bitbake: toaster: views api Package info return both kinds of RDEPENDS
9cda2ab bitbake: toaster: fixup dependency excludes for customimage
a54cebe bitbake: fetch2/npm: ignore unknown headers in tarballs
0cd1be1 bitbake: fetch2/npm: handle alternative dependency syntax
d999927 bitbake: fetch2/npm: fix indentation
26ee4dd image creation: allow overriding .rootfs suffix
e43fcdf scripts/hob: drop
59b4cef classes/packageinfo: remove
bbf2a5d conf/documentation.conf: remove BBLAYERS_NON_REMOVABLE
7054882 yocto-uninative: Add common include for uninative
d2c96ca mtools: Drop GCONV_PATH manipulation
d27644e uninative: Handle relocate of GCONV_PATH in libc
0523499 uninative: Add checksum support
73265d1 uninative: Refactor common code
4feb00d uninative: Use CXX11 ABI for interoperation between gcc4 and gcc5
013dd24 uninative: correctly enable uninative
034618d glibc: Add relocation of GCONV_PATH
8dca343 uninative-tarball: Add glibc-gconv-iso8859-1 for guile
1f50f29 dkpg: Use tar everywhere (not gtar)
b158d6c gtk3+: Add missing DEPENDS on wayland-native
e395e81 tune-cortexa17.inc: apply changes similar to a15
ea53d1e sstate: Allow late expansion of NATIVELSBSTRING
bd3a1d5 linux-yocto: Update SRCREV for genericx86* for 4.4
70c6df2 linux-yocto: Update SRCREV for genericx86* for 4.1
ae85c4b linuxloader/image-prelink/image-mklibs: Fix non-standard path prelinking
0b84897 insane/prelink: Handle nonstandard library paths
6b564ae ext-sdk-prepare: Catch setscene tasks which should have run but didn't
d8efd2e createrepo: Fix stat floating timestamps
ce5a9df xmlto: ensure /bin/bash is used as bash
70b4f36 openssl: add a patch to fix parallel builds
1632742 xdg-utils: remove trailing whitespace in multiline string
816391a btrfs-tools: Add libgcc to RDEPENDS
e467156 bitbake.conf: Add libgcc-native to ASSUME_PROVIDED
a91713f net-tools: Override CFLAGS/LDFLAGS in do_install too
fb0c3c5 nspr: Fix build regression on musl from last upgrade
37f5fb9 gdb: fix builds with internal readline and no static libraries
6518db4 feature-arm-thumb.inc: Fix thumb tune override warning
afb1d09 recipetool: create: fix support for AX_CHECK_LIBRARY
463fd5e formfactor: assume a keyboard is plugged in
e2107f5 acl: Fix re pattern in test cases
82a8064 gcc-runtime.inc: disable libitm for little endian MIPS too
25d9c4e devtool: add build-sdk subcommand
41eb36d devtool: build-image: rename module
82d0c8a oeqa/buildoptions: Improve unsafe references tests
4284fdf insane.bbclass: make the checking stricter for unsafe references in scripts
5cd71fe yocto-project-qs: Updated flow to mention Toaster
cd041b7 dev-manual: Applied review comments to the devshell section.
f54fe56 ref-manual: Updates for nativesdk clarifications.
a882267 dev-manual: Fixed typo in the devshell section.
70c7e36 dev-manual: Created devtool upgrade section.
b2b22d5 dev-manual, mega-manual, Makefile: Added support for new upgrade flow
0b7d8a4 dev-manual, mega-manual: Updated the workspace directory structure image
050e021 dev-manual: Applied review changes to the devtool section.
09ecf38 dev-manual, mega-manual: Updated three figures for devtool
f33ffaa dev-manual: Applied more review comments to the section.
fe70eb2 dev-manual, mega-manual: Updated the devtool modify flow diagram.
eb3b414 dev-manual, mega-manual: Updated the devtool add flow diagram.
4c5bd3f dev-manual, mega-manual: Updated the devtool workspace figure.
9cee16b dev-manual: Applied review comments to the devtool section
c678d1a dev-manual: Updated the devtool add section.
a09238a dev-manual, mega-manual: Updated devtool add flow diagram
7699f0a dev-manual: Added section for devtool modify flow
1eecaea dev-manual, mega-manual: Added new figure for devtool modify flow
9582da6 dev-manual: Edits to the devtool-add section.
740369f dev-manual, mega-manual: Updated the devtool add flow figure
a848e9f dev-manual, mega-manual: Updated the workflow layer content figure.
34e08b3 dev-manual: Added new "writernotes" style.
17a21e6 Makefile, dev-manual, mega-manual: Added new figure support
d346c35 dev-manual: Applied review comments to devshell section.
3b41049 ref-manual, dev-manual: Clarifying "native" and "sdknative"
a1970eb dev-manual: Updated devshell section.
a58cde0 toaster-manual: Updated how manage.py createsuperuser command is run
c5b4f69 ref-manual, dev-manual: Clarification of "native" and "sdknative"
952bcc7 toaster-manual: Removed prompts for json file.
34c75fa ref-manual: Updated the S variable description with feedback
2b2ced0 ref-manual: Updated the staging.bbclass description
b9dddd5 ref-manual: Updated the S variable description.
41e9f7c dev-manual, ref-manual: Updated licensing text information.
5066fbc ref-manual: Added order information for conf file parsing.
ad6b2f2 toaster-manual: Removed typo - double "allow" words.
c8c533e ref-manual: Updated the do_populate_sysroot task.
2a3942b dev-manual: Updated section on adding license text.
77b3d06 ref-manual: Updated the S variable entry in the glossary.
a1a4808 toaster-manual: Applied a patch to weed out build mode (modes).
353b755 bitbake: bitbake-user-manual: Added expand() function to list.
638ad17 bitbake: bitbake-user-manual: Added note for Python variable ref expansion.
da22add bitbake: bitbake-user-manual: Enhance environment variable discussion.
f11de9d e2fsprogs: do not enable non-stable features by default
b04280a sdk_update.py: Enable local sdk-update tests
14dd07c sdk.py: Fix undefined variable
c12e919 eudev: recipe formatting improvements
73a43fc openssl: Security fix Drown via 1.0.2g update
ed14aef layer.conf: Update after replacement of udev with eudev
e72233a bootimg: set default value for LABELS variable
4eaef67 sanity: Do not mistake meta-yocto-bsp for meta-yocto
86759de sanity.bbclass: remove conflict checking for image vm and live
bb1c719 syslinux.bbclass: make vm and live can be built together
5c5c13d recipetool: create: add basic support for new npm fetcher/class
2be37a9 recipetool: create: add basic support for generating linux kernel recipes
5cf15ff recipetool: create: add support for out-of-tree kernel modules
937ecd0 bitbake: toaster: cleanup of bin/toaster startup code
a7d1b95 bitbake: ui: remove the puccho ui
a9dc72f bitbake: hob: removal of hob ui and associated ui files
27468db bitbake: fetch2/npm: Add missing ParameterError import
44e3461 bitbake: npm: in cases where shrinkwrap resolved a git URL, ignore it and grab dist.tarball
2a73181 bitbake: fetch2: Fix unpack for absolute file urls
865d2fe bitbake: fetch2: fixes copying of file://dir; subdir=foo, bug 6128 and bug 6129
fb437d3 meta-yocto-bsp: bump to linux-yocto 4.4 for the non-x86 BSPs
fbedac4 maintainers.inc: Add new eudev package and change maintainership for udev
0138874 gcc: Add support for atomic opertions (libitm) where available
70153b4 classes/externalsrc: fix symlinking if symlink exists pointing to another path
eac4061 populate_sdk_ext: Only write LCONF_VERSION to bblayers if it is set
c366343 automake: don't delete .pyc files
d6e63be cracklib: fix Python packaging
a005d25 populate_sdk_base: handle empty SDK_PACKAGING_FUNC
ec3be9f linux-yocto/4.4: update to 4.4.3
6ed16ff linux-yocto/4.1: iwlwifi: mvm: don't allow sched scans without matches to be started
2497e80 linux-yocto/4.4: update to -stable 4.4.2
aa2c1f7 linux-yocto: braswell: Remove feature and move DRM_I915_PRELIMINARY_HW_SUPPORT option
702701d linux-yocto/4.4: yaffs2 build fixes
c2152b8 linux-yocto/4.1: update to 4.1.18
45d4cd7 linux-yocto/4.1: clkdev updates
79ecef6 linux-yocto/4.1: Galileo updates
5f61693 usbutils: Fix for new eudev implementation
c89b777 libgudev: Fix for new eudev implementation
3e5e540 eudev: Replaces udev with eudev for compatibility when using sysvinit on newer kernels
674e55f populate_sdk_ext: Delete the buildtools tar file after installation
d8acef2 libarchive: Set xattrs after setting times
431c1e1 combo-layer: handle empty commits during "init --history"
695cc45 classes/populate_sdk_ext: prepend to PATH rather than appending
b145480 classes/module: allow substitution of the modules_install target name
b03936c grub2.inc: drop bogus dependency on xz
7328765 grub2.inc: avoid passing -isystem to native builds
576587d grub2.inc: dont export TARGET_CFLAGS etc to grub2 configure
97a3322 harfbuzz: update 1.2.1 -> 1.2.3
edf93a0 gstreamer1.0-plugins-bad.inc: limit ARM_INSTRUCTION_SET over-rides to armv4/armv5
89140b0 dhcp: CVE-2015-8605
6ccd8cd sato/images: Add ptest image
f38debb layer.conf: Whitelist cantarell-fonts fontconfig dependency
b307937 pango: make ${PN}-ptest RDEPENDS on cantarell-fonts
0c80f29 cantarell-fonts: Add recipe
4006a7f sanity: Fix int verses string reference
2e27c4b bitbake: fetch2/npm: Enable fetcher
1c060d7 pseudo: Increase number of retries
030d920 bitbake: providers: Fix PREFERRED_VERSION lookup for '_' in PN
c679a3d bitbake: fetch2: Skip lockfiles and donestamps for local files
d01042e bitbake: fetch2/__init__.py: Error if lockfile path invalid
ab7b7bf bitbake: fetch2/__init__: Fix decodeurl to better handle urls without paths
06b4d8f bitbake: fetch2/wget: Set localfile for directories
8d7e799 genericx86-common: Update PREFERRED_VERSION_linux-yocto to 4.4
65d6a62 gstreamer1.0-plugins-bad.inc: enable webp PACKAGECONFIG by default
cd00748 gettext: Delete libintl.la file from install
b33efa9 systemctl: handle RequiredBy dependencies
8caa592 ffmpeg: add bzlib, lzma and xv PACKAGECONFIGs
0011760 rootfs-postcommands: fix ssh_allow_empty_password checking
96f5f89 musl: Add linux-libc-headers to deps
3354878 mesa: Fix build on musl
7651342 dosfstools_2.11: fix build following removal of -e from EXTRA_OEMAKE
6c8abea uclibc support for rng-tools
c7e5a38 oeqa/sdkext: Add sdk_update.SDKUpdateTest class.
738bd1a classes/testsdk: Pass tcname to SDK and SDKExt contexts
2a410b2 classes/testsdk: Move the removal of bitbake PATH to eSDK context only
eb1f8b9 classes/testsdk: Move code for avoid PATHs to oeqa.utils
55d4849 gstreamer1.0-plugins-XXX: control orc PACKAGECONFIG via GSTREAMER_ORC
083c63d boost.inc: fix BJAM_OPTS --build-dir option
f4e17c6 shared-mime-info: update to 1.6
4ffdfdf vala: update to 0.30.1
f53f374 python-git: update to 1.0.2
ec73437 pax-utils: update to 1.1.5
447ddb9 nettle: update to 3.2
26a3d25 ncurses: update to revision 20160213
dc42d30 libdrm: update to 2.4.67
0296e0a gtk+3: update to 3.18.8
e08ad62 gtk-icon-utils-native: update to 3.18.8
9daf153 git: update to 2.7.2
927dfaf gnupg: update to 2.1.11
2c39358 clutter-gst-3.0: update to 3.0.16
b8a1e59 ccache: update to 3.2.4
4d4aa1f libsolv: update to 0.6.19
8c2e420 ffmpeg: update to 3.0
afce247 nspr: update to 4.12
b19dbe5 pcmanfm: update to 1.2.4
6b41608 libfm: update to 1.2.4
325a9d3 epiphany: update to 3.18.4
d4da534 wic: don't throw away our created swap partition
5f82d17 automake: set test-driver path relative to top_builddir
b41862d uninative-tarball: respect SDKMACHINE when building
4d1c14f boost.inc: enable more verbose build logs
7f84ad0 gstreamer1.0-plugins-XXX: move inherit gettext into common .inc file
2ce48e6 gstreamer1.0.inc: add explicit PACKAGECONFIG init
935d88a gstreamer1.0-libav: move LIBAV_EXTRA_CONFIGURE_COMMON_ARG into .inc
3a8ff19 gstreamer1.0-libav_git: add --ranlib option to LIBAV_EXTRA_CONFIGURE_COMMON_ARG
b8bdb99 boost.inc: limit ARM_INSTRUCTION_SET over-rides to armv4/armv5
9ca8f30 populate_sdk_ext: Add images to SDK_INSTALL_TARGETS
07dc765 boot-directdisk.bbclass: drop IS_VM chechking
a87574c image-live/boot-directdisk.bbclass: remove AUTO_SYSLINUXCFG
76eb815 testimage.bbclass: reuse generic test suites
6571a84 testimage.bbclass: add generic, image test suites
8c45747 gconf: remove redundant dependencies
a74c389 gtk-doc-stub: don't inherit autotools
2269f90 os-release: sanitise VERSION_ID field
9d86b26 apr-util: add ldap crypto and sqlite3 to PACKAGECONFIG
d8d2f57 apr-util: fix loadable module packaging
77cfa2b glibc.inc: improve optimisation level sanity checking
04c4719 rsync: add native variant
2c20fe4 core-tools-profile: add lttng tools for aarch64
8a0b997 lttng-ust: add support for aarch64_be
6081c35 liburcu: add support for aarch64_be
07a3c71 harfbuzz: add explicit dependency on fontconfig
73cc8b8 harfbuzz: update 1.2.0 -> 1.2.1
bb151b8 fontconfig: Don't add font directories from host
e9f5134 musl: Upgrade to 1.1.14
bf4d380 oe-selftest: devtool: add an additional test for devtool upgrade
4bae2f2 oe-selftest: devtool: rework devtool upgrade test
10290f2 devtool: upgrade: print new recipe name
5cd3be3 devtool: upgrade: drop PR on upgrade
e6f684b devtool: upgrade: eliminate unnecessary datastore copy
860574e devtool: upgrade: fix several issues with extraction of new source
66a781c devtool: upgrade: fix constructing new branch from tarball releases
d30cc76 devtool: upgrade: fix renaming of recipe if PV is not in name
75eeeab devtool: upgrade: fix moving version-specific files directory
81ebb0b devtool: upgrade: fix version argument checking
e953b57 devtool: upgrade: drop superfluous call to validate_pn
492b1eb devtool: upgrade: make source tree path optional
942ae25 devtool: modify: fix source tree default name when mapping virtuals
e2334e1 devtool: add: tweak auto-determining name failure message
55ae566 uninative.bbclass: if the loader can't be found disable instead of failing
50b8740 uninative: use check_output instead of Popen directly
4495e8b lib/oe/qa: add explicit exception for 'file isn't an ELF'
4553bb1 libdrm: fix build with uclibc
4e5a871 strace: fix ptest execution
e8e0489 clutter-1.0: Fix confgure test errors found by clang
b748f40 oeqa/parselogs: Updated whitelist
4b32351 buildstats.bbclass: Don't assume /proc/<pid>/io present
07e1f10 sysvinit-inittab: Move start_getty scrip to base_bindir.
8d07e14 oeqa/selftest/prservice: Added new TC: check pr-server starts and stop correctly on localhost.
d2a563c oe-selftest: Add support for lib/oeqa/selftest subdirectories
7f58b92 musl: Upgrade to 1.1.14
73bf792 devtool: update-recipe: create config fragment
2fbd1d7 devtool: sync: update kernel config
26f951b git: fix installed-vs-shipped QA Issue
033db24 btrfs-tools: fix symlink creation multiple times
9af773f bison/gettext: add --with-bisonlocaledir to assign BISON_LOCALEDIR
b14e2ae gcc: use relative path for configure script
1f00fb2 depmodwrapper-cross: nopackages to avoid QA [buildpaths] issue
00a6f5a oeqa/utils: added new network module
3f7aa6f scripts/oe-selftest: Use site.USER_SITE to run coverage configuration code for sub-process
1c6c76e scripts/oe-selftest: Add filtering to the coverage data gathered by oe-selftest
4a21827 oeqa/selftest/signing: Added test for locked signatures
604dc1c package: check inherit instead of PN to decide if a recipe is a packagegroup
b4df005 tune-cortexa9.inc: add vfpv3 tunes
889a5cc mirrors/own-mirrors/sanity: Updates after npm fetcher addition
28d17cf npm.bbclass: Add npm class to match fetcher
bc5a1d1 base: Add nodejs-native dependency for npm:// urls
9d5483c meta-yocto: Rename to meta-poky to better match its purpose
ab3a718 adt-installer: Drop since its replaced by the extensible SDK
c1c6a9d sanity: Improve configuration upgrade capabilities (support meta-yocto -> poky transition)
2587101 image: Run do_rootfs_wicenv after do_image
e0fd964 bitbake: toaster: change 'delete layer' to 'remove layer'
6e82820 bitbake: toaster: rename 'run again' button
c8dd72c bitbake: toaster: fix banner after customimage package add
149f574 bitbake: toaster: custom breadcrumb for the default project
4a12865 bitbake: prserv: Add dump_db()
bdb51ab bitbake: toaster: remove custom images from Image Recipes
98d462c bitbake: toaster: show suffix for image files and basename for artifact files
88b5660 bitbake: toaster: add missing link to image recipe details
25b179d bitbake: toaster: adjust the search field width
a97081b bitbake: toaster: make 'configuration' the first tab
e1fc319 bitbake: toaster: link to configuration in all breadcrumbs
df2808f bitbake: toaster: reduce max height of modal dialogs
6c51f08 bitbake: toaster: disable add layer button on click
d4a663a bitbake: toaster: apply error class to name field
48f0ae2 bitbake: toaster: fix custom image name form
07eb4f2 bitbake: toaster: comment out project release change
12ade9b bitbake: fetch2/npm: Add mirroring support for npm fetcher
ca5b6d6 bitbake: fetch2/npm: Add npm fetcher
813bd1f bitbake: utils.py: Add sha1_file call
7bb9e8d signing-keys: Make signing keys the only publisher of keys
64ab17b systemd: Upgrade to 229
44248af harfbuzz: update to version 1.2.0
f4f5573 perf: add sysroot handling to subcmd
7a95c2c oeqa/selftest/buildoptions: build -minimal instead of -sato images
2980ac0 bitbake.conf: add findutils-native to ASSUME_PROVIDED
2e152ff findutils: upgrade to 4.6.0
951ce18 mesa: add missing space to RRECOMMENDS append
2305610 uclibc: Do not use immediate expansion operator
aab3900 security_flags: Disable ssp when compiling uclibc
afb954e rpm: fix building rpm 5 with internal beecrypt
069cdbe alsa-lib: topology: Add missing include sys/stat.h
b879aed libsdl2: Fix patch after upgrade
3d4f71d gstreamer1.0-libav_git: update 1.7.1 -> 1.7.2
9d83a3e gstreamer1.0-plugins-ugly_git: update 1.7.1 -> 1.7.2
6456a6f gstreamer1.0-plugins-bad_git: update 1.7.1 -> 1.7.2
821498f gstreamer1.0-plugins-good_git: update 1.7.1 -> 1.7.2
04e77c1 gstreamer1.0-plugins-base_git: update 1.7.1 -> 1.7.2
e67c91d gstreamer1.0_git: update 1.7.1 -> 1.7.2
ea8c34e libnewt: Fix build with PIE flags
66a833a pseudo: Fix build when security flags are enabled
91a1baa glibc: Upgrade to 2.23
c1f9507 no-static-libs: remove eglinfo
0ab67d6 freetype: use autotools instead of a manual do_configure
4883ccc classes/populate_sdk_ext: add a better config extension mechanism
524ee08 recipetool: create: improve CMake package mapping
7b6e5b0 recipetool: create: add additional extension mechanisms
b2d4472 devtool: modify: tweak help description for behaviour change
a8e0e5e devtool: deploy-target: preserve existing files
2059a34 devtool: undeploy-target: support undeploying all recipes
b95c72c devtool: deploy-target: write deployed files list to target
62989ef devtool: sdk-update: tweak command-line handling of updateserver
cada5a8 devtool: (un)deploy-target: add help descriptions
6bd88e6 scripts/lib/argparse_oe: tweak title above options
32ef523 devtool: categorise and order subcommands in help output
9f7df76 devtool: update-recipe: don't show workspace recipe warning if no update
51972ed devtool: reset: fix preserving patches/other files next to recipes
e54f9c1 devtool / recipetool: use common code for launching editor
dd35f69 devtool: minor fix for error message
41242a2 staging.bbclass: remove trail slash from SYSROOT_DESTDIR
aeb8964 terminal.bbclass: import oe.terminal for oe.terminal.prioritized()
bee556a recipe_sanity.bbclass: skip DataSmart in recipe_sanity_eh()
2d293bd image.bbclass: fix circular dependency when IMAGE_FSTYPES append hddimg
a332360 toolchain-scripts.bbclass: add three other path to PATH in env.sh
4d2910f libsoup-2.4: disable libsoup-gnome by default
619f6c6 libsoup-2.4: prevent PACKAGECONFIG dependant package renaming
13e726f libsoup-2.4: minor formatting improvements
dd0ef3c populate_sdk_ext.bbclass: Add SDK_RECRDEP_TASKS variable
4c5c40d devtool: Don't recursively look for .devtoolbase in --basepath
0220180 populate_sdk_ext: Don't ignore SDK_TARGETS value
8c0ba8d bitbake: toaster: toastergui Fix invalid char test and implementation
913e9b1 bitbake: toaster: PackagesTable show only installed packages
94bca58 bitbake: toaster: toastergui unit tests convert to use fixtures
8796ac8 bitbake: toaster: SoftwareRecipesTable apply default order_by
8469e58 bitbake: toaster: orm migrations Sort out migrations mess
78b6109 cml1/sstate: Fix missing getVar parameter
7e19f88 linux-yocto/4.1: capabilities backports
54bfbcc waf.bbclass: Remove --disable-static from EXTRA_OECONF
51fc304 gcc-5.3: backport fix for PR-target-65358
ed20c6c epiphany: Add libxml2-native to DEPENDS
2021f63 libsdl2: update to 2.0.4
947b3bf cmake: Update to 3.4.3.
4699483 sstate.bbclass: use oe.gpg_sign for gpg signing
db7c7c2 oe/gpg_sign: add 'passphrase' argument to detach_sign method
e845b75 sign_rpm.bbclass: do not store key details in signer instance
d5be866 oe/gpg_sign: add 'armor' argument to detach_sign()
03554b7 oe/gpg_sign: add verify() method
af7e516 ruby: break out ri-docs and rdoc into separate packages
8bcf139 insane.bbclass: print more info for build-deps and file-rdeps
5f3dfea curl: re-enable proxy support by default
1f61888 libtool: Don't hardcode grep paths
a3b996a cml1.bbclass: fix do_menuconfig
91bfe50 cups: upgrade to 2.1.3
eeac0a9 coreutils: upgrade to 8.25
01dc859 findutils: upgrade to 4.5.19
bf7d5f6 diffstat: upgrade to 1.61
247f3b4 grep: upgrade to 2.23
4e5e501 bitbake: data_smart: Drop default expand=False to getVarFlag [API change]
c7610aa bitbake: data_smart: Drop default expand=False to getVar [API change]
4f0ab27 bitbake: SignatureGeneratorBasic: make checksum cache file configurable
0cdf193 bitbake: MultiProcessCache: make cache filename configurable
ca552bb bitbake: FileChecksumCache: add get_checksums() method
8f61f2d bitbake: bb/runqueue: save task file dependency cache onto disk
5177b1e bitbake: SignatureGenerator: add method for saving the file checksum cache
97617fd bitbake: bb/cache: drop some unused arguments
5a87d8c bitbake: Allow Hob to run images on a custom simulator, other than qemu
7fc38ea gma500-gfx-check: Fixes infinite calling to modprobe gma500_gfx
be7b52a pulseaudio: 6.0 -> 8.0
c52b8f6 alsa-plugins: 1.0.29 -> 1.1.0
a231a4e alsa-utils: 1.0.29 -> 1.1.0
1adbb73 alsa-tools: 1.0.29 -> 1.1.0
3a82e2e avahi: update to version 0.6.32
14daeb5 no-static-libs.inc: Add libcap-native
c001863 libsdl2: Fix build with static libraries disabled
a46dc87 uboot-inc: Backport patch to fix Beaglebone Black bootloader
c7355b9 busybox: drop patches that are not valid anymore
47d0119 pcmciautils: Update SRC_URI
f37ac5b debianutils: Upgrade 4.5.1 -> 4.7
adfcaf2 busybox: Add musl config for _git recipe
46824dc debianutils: Fix SRC_URI to use debian snapshot
3df8701 nfs-utils: bugfix: adjust name of statd service unit
c15bf55 musl: Upgrade to 1.1.13+
07e7879 dpkg: Update to 1.18.4
5794b56 glew: upgrade to 1.13.0.
aea0746 glew: rewrite to use upstream build system
0b1c324 socat: Fix build with musl
04c6a48 binutils: Fix useless rpaths QA warning
eb6d14e image/populate_sdk: seprate variables to fix dependency
c9e5e34 gcc: Backport nios2 r31 fix
012460d sqlite3: update 3.10.2 -> 3.11.0
f770a6e insane: wrap autotools checks in inherits_class(autotools) checks
35011d9 cmake: don't inherit autotools
9cd64ed oeqa/selftest/bbtests: Test bitbake --setscene-only option
7e5b451 glew: don't put our CFLAGS into the pkgconfig file
b1145cc dbus: update large file patch
fad63e3 coreutils: fix problem with acl for 6.9 version
351039f gcc-4.9/5.3: Ignore -fdebug-prefix-map in producer string
7a11650 bitbake.conf: use target path as compile dir in debugging info
ef30119 glibc: Security fix CVE-2015-7547
c834ebc glibc: CVE-2015-8776
842177a glibc: CVE-2015-9761
efa1ae5 glibc: CVE-2015-8779
aefe1fa glibc: CVE-2015-8777.patch
152914f oeqa/parselogs: Whitelist dmi firmware failure message in 4.4 kernels
683ea31 rng-tools: Fix underquoted m4 and libgcrypt floating dependency
7a700f5 lib/qa.py: raise ValueError if file isn't an ELF
334e1b5 lib/oe/qa: ELFFile: check that a path is a file before opening it
11359e9 rng-tools: fix the build with musl
a258589 bitbake: bb.ui.knotty: prefix task messages with recipe/task
4bf8b21 bitbake: Move bb.{debug,note,..} into their own logging domain
3b35de3 layer.conf: Add gstreamer1.0-meta-base to SIGGEN_EXCLUDERECIPES_ABISAFE
14e9385 sstate: Add ca-certificates-native to postinst recipes list
73e53e4 nss: define RPATH variable for nss-native
6e4e9f7 Revert "lsbinitscripts: fix the path for mountpoint"
6db39e1 libunwind: Fix build on ppc
47896a7 dbus-glib: 0.104 -> 0.106
93d8fc1 conf/no-static-libs: add explicit rule for libical
637b44c runtime/systemd: Fix for boot time string parse error
ef5b8b4 security_flags: Add SECURITY_CFLAGS to TARGET_CC_ARCH for binutils
1387785 binutils: Use tip of 2.26 branch
da13f0b buildhistory.bbclass: remove out-dated information on request
a56da4a Remove obsolete references to exmap
8b21720 bitbake: knotty: Set exit failure code on runQueueTaskFailed events
a9223e2 bitbake: taskdata: Fix traceback issue with missing provider
7593756 bitbake: cooker: Improve cache handling
9cb38c1 poky: Disable static libs by default
f852014 bitbake.conf: Remove unhelpful default value for EXTRA_OEMAKE
b050c50 apmd: fix build with static libraries disabled
d585a71 oeqa: Update to handle domain specific references in build logs
9300749 libpng12: Handle no static libs
67ea65e ed_0.5: Handle --disable-static option
438d6d6 conf/distro/include: Add no-static-libs.inc
2eb19cc classes/buildhistory: fix for python function parsing change
1a3204c valgrind: Fix build with musl
e8b0da1 rpm: Fix build with musl
48144e0 gstreamer1.0-meta-base: Mark as machine specific due to COMBINED_FEATURES
ff8ca89 gdb-cross-canadian: Add missing virtual/* DEPENDS
120a160 e2fsprogs: Update to upstream version of a patch
5394ada gdb: Rationalise PACKAGECONFIG
ce0f8ab insane: Add --disable-static to UNKNOWN_CONFIGURE_WHITELIST
94abdb2 linux-yocto: Work around PAT issue on qemux86
6fb493a libgcrypt: update 1.6.4 -> 1.6.5
bf9ad22 musl: Upgrade to tip of tree
5d156bc oe-selftest: don't use specific tasks
80e8928 oe-selftest: pylinted wic tests
9b6dc9b wic-image-minimal: use uuid for root partition
ab7cb65 wic: fix processing of --use-uuid
51e0a8a oe-selftest: add new wic testcase
2100f82 wic-image-minimal: update .wks to boot by qemu
4b26601 wic-image-minimal: change IMAGE_FSTYPES
f799e21 oeqa/targetcontrol: support wic image type
7066f16 oeqa/targetcontrol: make ssh control optional
0ade658 qemurunner: add parameter to method 'start'
d083fec oe-selftest: remove unused parameter
c26a9c3 runqemu: support path/to/<image>-<machine>.wic
c7f0578 runqemu: don't set KERNEL for wic images
2c3a009 runqemu: add support for wic images
64d2f13 scripts/sstate-cache-management.sh: Change wording
6740dd5 qemu.inc: Add rng-tools to qemu images
ce3df21 rng-tools: Import recipe from meta-openembedded
36b43b2 lib/oe/terminal: set workdir for konsole terminal
03e1950 mmc-utils: upgrade to latest git version
b5b8003 ltp: Upgrade to 20160126 and fix build on musl
f6b3957 initscripts: start urandom after populate-volatiles
85ac8eb initscripts: populate-volatiles.sh: add mount-bind feature
be5b72c libdrm: don't detect components that have been disabled
5fc5996 buildhistory: Fix regex to handle versions without spaces
7c3d4c0 debian: Fix superfluous setting for RPROVIDES
2eba066 autotools: Fix interaction with bitbake -b
9c8fee9 autotools: Correct dependency search logic error
971fafb maintainers.inc: include libjpeg-turbo and mmc-utils
4e0b334 scripts/runqemu-internal: Work around qemux86 PAT bugs in linux 4.4.1
283a302 sanity: Bump minimum version to 1.29.0
1c2d632 bitbake: Bump version post release to 1.29.0
a12dcc4 base.bbclass: fix support for gitsm://
bc72f64 linux-yocto: Update SRCREV for genericx86* for 4.4
be89a1d linux-yocto: Update SRCREV for genericx86* for 4.1
4a8d20a poky: update qemu* to prefer 4.4 kernel
d255f4f linux-yocto/4.1: galileo backports and support
fdcb373 linux-yocto/4.1: update to v4.1.17
5688cab linux-yocto/4.4: update to v4.4.1
f9f93ae bitbake: cooker: gracefully shutdown parsers
1f7f077 bitbake: buildinfohelper: unset brbe variable when build finishes
9a6cb10 nativesdk-buildtools-perl-dummy.bb: Fix variable expansion in python code
5e978d7 classes/testsdk: do_testsdkext avoid STAGING_DIR/BASE_WORKDIR in PATH
f56e9aa freetype: update 2.6.2 -> 2.6.3
1ba1aa3 freetype: minor formatting improvements
0d5e611 piglit: upgrade SRCREV
72c6b62 libbsd: Security fix and update 0.8.2
78be954 gstreamer1.0-plugins-bad_git: fix gst_structure_get() etc compiler warnings
fdd8979 gstreamer1.0-plugins-good_git: fix gst_structure_get() compiler warning
a23a50e python-setuptools: Add python-compile on RDEPENDS
914ff14 qemu: Security fix CVE-2016-2198
0938353 qemu: Security fix CVE-2016-2197
1f3e1d1 curl: add PACKAGECONFIG options for less common / legacy protocols
19045ba toaster: tests Remove symlinks from toasteruitest folder
738a9b7 classes/sanity: check_perl_modules provide output when fail
e64ce73 oe-selftest: devtool: add another devtool add test
a5095d1 recipetool: create: set S when we set SRC_URI from local git repo
ca5a36c recipetool: create: convert http git URLs that don't end in .git but contain /git/
4c71afb recipetool: create: ensure URL parameters don't make it into the name
86f3464 devtool: add: fix adding from a local source directory
fa50153 devtool: modify: make -x the default behaviour
f767757 recipetool: create: determine name/version from github/bitbucket URLs
d94c7e3 recipetool: create: support cmake find_library directive
ddfe744 devtool: commit for extra tasks that modify source when extracting
e36cb6c classes/externalsrc: create symlinks for workdir and logs
20034c3 classes/externalsrc: disable rm_work when active
c38f253 uninative.bbclass: capture stdout/err from patchelf-uninative
9065222 db: update HOMEPAGE
f0d5478 mdadm: update to version 3.4
79d5041 iproute2: update to version 4.4.0
21e3b2a image_types_uboot: add cpio.gz.uboot to supported IMAGE_TYPES
6fab5fc recipetool.newappend: add -e/--edit argument
252f97e liburcu: Add nios2 support
e72ab70 strace: Fix build for arc, metag, nios2, or1k, tile
691277f udhcpc: specify full path for ip command calls
f141f0b alsa-lib: avoid including <sys/poll.h> directly
a1ad3d0 oprofile: Add nios2 support
fd7dd07 nspr: Add nios2 support
954dc45 guile: Fix nios2 support
611e3d8 binutils: Repair nios2 PLT and GP handling
027eac5 gstreamer1.0-meta-base: make gstreamer1.0-plugins-base-alsa conditional
056d82c curl: drop obsolete pkgconfig_fix.patch
0e62f01 iproute2: update to version 4.4.0
216e618 quota: update to version 4.03
25d2956 oeqa/selftest/sstatetests.py: check that PARALLEL_MAKE doesn't change signatures
2966016 bitbake.conf: remove unused ALLOWED_FLAGS
3bdeda5 libproxy: remove GPLv3 logic and spurious exports
86994fd libproxy: add PACKAGECONFIG control for gnome3
033d754 libproxy: replace PACKAGECONFIG equivalent with the real thing
e65a29e openssh: Properly skip ptrace test if tools are missing
e1a1e0b openssh: Fix regex that sets sftp-server path for tests
d7faf67 insane.bbclass: Support MicroBlaze with musl
9937c93 hdparm: Explicitly set EXTRA_OEMAKE as required
7475c4c qemu: Security fix CVE-2016-1568
4857511 xserver-xorg: Add PACKAGECONFIG for crypto libraries
34798fa mesa: upgrade 10.6.3 -> 11.1.1
7edea7c initrdscripts: fix mmc device as install target
c3ef2bb libsoup-2.4: Remove unnecessary gnutls dependency
04454b2 wpa-supplicant: Only depend on libgcrypt when needed
4de0ee6 systemd: Don't depend on gcrypt unnecessarily
0da96bf buildstats.bbclass: remove dead URL from comment
326592d Remove obsolete references to exmap
a0cc1c3 curl: update 7.47.0 -> 7.47.1
a0d3eb9 sign_package_feed.bbclass: fix task dependencies
8cb1e83 oe/gpg_sign: fix incorrect variable name
902a68f meta/conf/layer.conf: adapt to more flexible initramfs-framework RDEPENDS
5b2b343 tune-corei7.inc: tell qemu to emulate a matching processor
5b70ee4 pixz: fix upstream version check
62a6f97 webkitgtk: update to 2.10.7
1cd6912 libwnck3: update to 3.14.1
e53eef9 iso-codes: update to 3.65
30cf8aa bash-completion: fix upstream version check
8098256 gstreamer1.0: fix upstream check for unstable versions from git
c24b0ab ffmpeg: update to 2.8.6
9237097 python: merge python-elementtree into python-xml
5ac4172 piglit: add missing dependency on python-xml
4d3ca42 systemd: tighten timesyncd and journal-gateway user accounts
6be3031 systemd: extend PACKAGECONFIG flags
85728ec systemd: rename systemd-zsh to systemd-zsh-completion
22a2866 systemd: move some tools into systemd-extra-utils package
9909104 classes/useradd: handle whitespace only USERADD/GROUPADD/GROUPMEMS
e485686 systemd: realign packages list
41d0f83 systemd: move bash completion into separate package
9a80afd nettle.inc: drop duplicate LIC_FILES_CHKSUM and SRC_URI hashes
72ec267 gdb: drop unnecessary CC_FOR_BUILD etc exports
00d6b67 gdb: build fix for MIPS + musl libc
40e4e8c strace: build fix for MIPS + musl libc
299b426 uclibc: fetch from master branch not 1.0
4ac4d28 uclibc-ng: Bump up to 1.0.12 release
70bfd4c musl: Upgrade to tip of tree
d1496b4 e2fsprogs: Fix multiple xattr handling
9d4b526 cdrtools-native: Explicitly set EXTRA_OEMAKE as required
864797a oeqa/prservice: Fix whitespace problem
7cd8351 pseudo: uprev to 1.7.5
246b02e ptest-runner: Explicitly set EXTRA_OEMAKE as required
7932525 unzip: Explicitly set EXTRA_OEMAKE as required
4ef055c sysklogd: Explicitly set EXTRA_OEMAKE as required
625066b stat: Explicitly set EXTRA_OEMAKE as required
07e81c8 pigz: Explicitly set EXTRA_OEMAKE as required
936223b iputils: Explicitly set EXTRA_OEMAKE as required
1e3fdbb ed: Explicitly set EXTRA_OEMAKE as required
ef36b6f gptfdisk: Explicitly set EXTRA_OEMAKE as required
59ee206 dmidecode: Explicitly set EXTRA_OEMAKE as required
d17758a libacpi: Explicitly set EXTRA_OEMAKE as required
44e8d0f apmd: Explicitly set EXTRA_OEMAKE as required
961d898 perl: Explicitly set EXTRA_OEMAKE as required
ecb9c34 oeqa: Improve test failure messages
ae2f3a3 sstate: Ensure populate_lic sstate objects are cleaned
26f26e5 package_deb: Ensure allarch deb packages aren't target specific
b3a2065 base: Make do_cleansstate nostamp
37357ab classes/testimage: Fix exportTests function.
f895a61 classes/testsdk: Add help information on how to run tests.
e22fbce oeqa/sdkext/devtool.py: Add location test to ensure that devtool is the eSDK one.
92d0cc5 oeqa/sdkext: Add devtool basic tests for eSDK.
a619ea2 oeqa/oetest: Fix compatibility SDK tests using eSDK.
062dbd6 classes/populate_sdk_ext: Add SDK_EXT_TARGET_MANIFEST and SDK_EXT_HOST_MANIFEST
4cfdf17 testsdkext: Add skeleton for support Extensible SDK tests.
5580d7b classes/testsdk: Add compatibility SDK testsuite to eSDK
7181da7 oeqa/oetest: oeSDKTest when run a command redirect env output to null
f3c2ce2 classes/testsdk: Add function run_test_context
3577c35 oetest.py/TestContext: Move loadTests and runTests inside it.
8009418 testimage/testsdk: Move get test suites routine inside TestContext.
b588b80 testimage/testsdk: Modularize TestContext.
59791d1 toolchain-shar-extract.sh: Add proxy variable to new env.
abd8158 classes/testsdk: Add call to export_proxies on testsdkext.
42f2ac4 classes/testsdk: Add testsdkext task only install.
90590ab get_test_suites: Add sdkext type for load test suites.
2ecc319 populate_sdk_ext: Set TOOLCHAINEXT_OUTPUTNAME.
7b459be classes/testimage: Add defeault inherit for testsdk.
24326a9 classes/testsdk: Add new class testsdk.
3d1d30b testimage: Modularize helper functions for get test lists.
8b5ee36 bitbake.conf/base: Improve handling of SRCPV
947e526 oeqa: setup bitbake logger after tinfoil.shutdown
400f530 bitbake: build: Improve python execution tracebacks
aece748 bitbake: build/data: Don't expand python functions before execution [API change]
e39cfb1 bitbake: cooker: Don't expand python functions in variable dumps
f652b6b bitbake: data: Don't expand python functions for variable dependencies
d3e0c44 bitbake: data_smart: Avoid expanding anonymous python functions
e0eb2ea bitbake: toaster: models Remove manual transaction control from lsupdates
48622e1 bitbake: toaster: build section Improve display of builds when > 1 targets
4d0ba0f bitbake: toaster: templates make build data breadcrumb consistent
99184d7 bitbake: BBHandler/ast: Merge handMethod and handleMethodFlags
6ba69b4 bitbake: utils: Drop datastore function inspection during exception
f8a44b1 bitbake: cooker: extended dot styling
30c132b bitbake: toaster: Enable Image Customisation feature
5e14a8f bitbake: toaster: xhr_customrecipe_packages Add dependencies to included packages
749f5a6 bitbake: toaster: orm generate_recipe_content only exclude locale packages
6269411 bitbake: toaster: customrecipe page Add last successful build link and conditionals
8d5b61e bitbake: toaster: models Add update_package_list for CustomImageRecipe
86db0bd bitbake: toaster: orm Add last_updated field to CustomImageRecipe
18d8b17 bitbake: toaster: models add get_last_successful_built_target method
8885b7b bitbake: toaster: pkg_dependencies_popover just show direct dependencies
40f6eff bitbake: toaster: models add all_depends method for Package_DependencyManager
a8ab1c6 bitbake: toaster: buildinfohelper CustomImagePackage update dependency info
0fee829 bitbake: toaster: newcustomimage_modal add frontend name validation
cb6d290 bitbake: toaster: API CustomImageRecipe check the recipe name supplied is valid
5634a25 bitbake: toaster: views CustomRecipe API add size information to the package lists
6fbceb0 bitbake: toaster: models Invalidate ToasterTables cache when a m2m field changes
998f9af bitbake: toaster: customrecipe Add dependency tracking to package selection
9976e4f bitbake: toaster: tables move template logic into the pkg_add_rm_btn
d77c247 bitbake: toaster: CustomImageRecipe generate overwrite IMAGE_FEATURES
481dc11 bitbake: toaster: make locale packages uneditable in custom image page
a757d39 bitbake: toaster: include locale and packagegroup packages in custom image
baac458 bitbake: toaster: update custom image package table filters
efbffe3 bitbake: toaster: move recent builds query to model
b514785 bitbake: toaster: update customimagerecipe migration
df58f5b bitbake: toaster: add merge migration to resolve conflict
38f4913 bitbake: toaster: orm generate_recipe_file_contents Handler for require recipe
769017e bitbake: toaster: project builds Poll the server to get latest progress for build
971d65c bitbake: toaster: localhostbectrl Update the dirpath of customrecipe's base layer
6d9f342 bitbake: toaster: tables Check layer presence in project for customise_btn
76c0008 bitbake: toaster: toastergui tests Add addtional data to the setUp for new tables
70a078e bitbake: toaster: tables SelectPackagesTable rename recipe_id to custrecipeid
7e4c231 bitbake: toaster: toastergui tests Update package test to use CustomImagePackage
4b3c9d6 bitbake: toaster: customrecipe Add further front end features using new API
b213907 bitbake: toaster: xhr_customrecipe_packages add GET info for package response
a9668ee bitbake: toaster: xhr_customrecipe_id change to use CustomImagePackage
439314c bitbake: toaster: API allow CustomImageRecipe to be updated after creation
9ea4de6 bitbake: toaster: tables Change SelectPackagesTable to use ProjectPackage
20f400b bitbake: toaster: tables add recipe download link to CustomImagesTable
1c9ce1c bitbake: toaster: newcustomimage_modal use libtoaster method for new CustomRecipe
8b1d043 bitbake: toaster: libtoaster Add createCustomRecipe method
32048fa bitbake: toaster: orm Add convenience method to get all pkgs in a CustomImageRecipe
c80b7df bitbake: toaster: orm get_project_layer_versions to return layer_version objects
796e348 bitbake: toaster: toastergui tests Add unit test for download custom recipe
04d8c94 bitbake: toaster: toastergui tests Update to reflect changes to CustomImageRecipe
4e8a0aa bitbake: toaster: views xhr_customrecipe_packages clean up API
66b5608 bitbake: toaster: toastertable remove title from Show all in table
ce72896 bitbake: toaster: Add recipe details page
5f52614 bitbake: toaster: newcustomimage Move modal dialog out of newcustomimage template
2a3dd32 bitbake: toaster: Continue front end features to custom image recipe page.
d6e7e4a bitbake: toaster: tables Add table for Packages and update SelectPackagesTable
43f0a05 bitbake: toaster: views Add view to download custom recipe
2cf55af bitbake: toaster: move CustomImageRecipe generation to API entry point
c402ac2 bitbake: toaster: orm add CustomImageRecipe generate contents function
a6e4f94 bitbake: toaster: buildinfohelper Add the concept of CustomImagePackage
e1bfe1c bitbake: toaster: orm: Add db migration for new CustomImagePackage table
f760a78 bitbake: toaster: orm Add CustomImagePackage table
4117af2 bitbake: toaster: orm: Add db migration for new CustomImageRecipe inheritance change
1f10289 bitbake: toaster: orm make CustomImageRecipe inherit from Recipe
648753b bitbake: toaster: orm Add sum of dependencies size function to PackageDependencyManager
a92fc30 bitbake: toaster: tablejs Add an event handler to manually trigger a data reload
4c82878 bitbake: toaster: ToasterTables simplify filter function move common part to widget
3e1e8e6 bitbake: toaster: models fall back to a sensible string for no vcs reference
14d09c8 bitbake: toaster: localhostbecontroller CustomRecipe now base_recipe is Recipe
7d5d8d0 scripts/lib/bsp/engine: trailing whitespace cleanup
dfeda17 scripts/lib/bsp/engine: fix path separator
d482d84 maintainers: remove gtk-theme-torturer and gnome-mime-data
d0d85a4 bitbake: bb/fetch2: Move export_proxies function from wget to utils.
7226ce2 glibc-locale: fix QA warning
4a2f42f formfactor: add machconfig for Beaglebone
eb53c54 sstatetests: Fix after change to sstate populate_lic SWSPEC
a43b9ef gstreamer1.0-plugins-base: move freetype dependency into 1.6.3 recipe
fb4f05b gstreamer1.0-plugins-base_git: update to git master 1.7.1-79-g6414289
fc81c80 gstreamer1.0-plugins-bad_git: avoid including <sys/poll.h> directly
3f02474 gstreamer1.0-plugins-good_git: avoid including <sys/poll.h> directly
9b0a74a gstreamer1.0: avoid including <sys/poll.h> directly
f9e565e gmp_4.2.1: fix build for MIPS
6d570c8 gmp.inc: limit ARM_INSTRUCTION_SET over-rides to armv4/armv5
3aecdd9 gmp: move BBCLASSEXTEND = "native nativesdk" from gmp.inc into 6.1.0 recipe
263a65d gmp: move SRC_URI out of gmp.inc + minor reformatting
aacae25 image_types.bbclass: Embed IMAGE_NAME in ubinize config file
9c0d4ec toolchain-scripts: drop PYTHONHOME
6560f80 python: set PYTHONHOME for nativesdk
92ae4e2 gcc: musl related fixes for ppc/secure-plt and gthr
9e5222c gcc: Assume libssp and dl_iterate_phdr on musl
281bd41 security_flags: wipe security flags for gcc/glibc and related libraries
61a5875 security_flags: use -fstack-protector-strong
a07f2fd security_flags: ensure security flags only apply to target builds
8d57d1d gcc: Fix build on musl with -fstack-protector
eb134c6 isoimage-isohybrid.py: fix cpio working directory
8bedf76 glib-2.0: use the system libpcre
1ae132e libpcre: enable unicode properties by default
3adb8d5 python3: remove optimize by default patch
1df1ac9 security_flags.inc: don't do -pie for syslinux
562c75c neon: convert to PACKAGECONFIG
6228cf8 bitbake: toaster: reinstate ID on edit columns button
916c73d bitbake: cooker: shutdown cooker parser on shutdown
8857498 bitbake: fetch2/osc: Clean up old variable syntax
54da829 bitbake: fetch2/osc: Remove hardcoded url
c57ba52 cross-localedef-native: add ABI breaking glibc patch
0cc825f uninative: Improve error handling
576a248 patchelf: Add patch to handle large files
bbdbe00 package_manager.py: fix python indentation bug (opkg)
ea40a0b populate_sdk_ext: Make populate_sdk_ext depend on sdk_extra_conf
4f7656a populate_sdk_ext: Add support for a "minimal" type
71bb332 populate_sdk_ext: Don't set sdk_update_targets in the config
5b7a43e toolchain-scripts.bbclass: Use PYTHONPATH instead of PYTHONHOME
f1f8447 copy_buildsystem.py: Pass the nativelsb argument to gen-lockedsig-cache
b130805 gnome-mime-data: remove
12d5fa8 gtk-theme-torturer: remove from oe-core
659d755 openssl.inc: drop obsolete mtx-1 and mtx-2 over-rides
32b498c scripts/devtool: Add getVarFlag expand argument
ed5daa1 bitbake.conf/native/nativesdk: Set PKG_CONFIG_SYSTEM_ at top level
8fa2d52 pango: unset LDFLAGS when building gen_all_unicode
edfaa04 pango: merge bb and inc
00ccf51 e2fsprogs: Ensure we use the right mke2fs.conf when restoring from sstate
66a6ec2 nativesdk: Set PKG_CONFIG_SYSTEM_ variables
34e95b0 local.conf.sample.extended: Document HOW-TO enable systemd or busbox for init system
077d32e local.conf.sample: Remove trailing whitespaces
6ae662a bitbake: parse/ast: Mark anonymous functions as python functions
9913fd8 bitbake: codeparser: Improve handling of data.expand() dependencies
4628fe1 bitbake: lib/bb: Add expansion parameter to getVarFlag
b98866d bitbake: fetch2/gitsm: Fix when repository change submodules
390c2c1 bitbake: data_smart: Add missing expand parameter to getVar call
56454f6 bitbake: bitbake: prserv: do not clear umask when daemonizing
abf8a8f bitbake: bitbake: prserv: SIGTERM handling hung process
be032fc bitbake: bitbake: prserv: -wal and -shm sqlite lost when daemonizing
1e95ebd poky-tiny: Use musl for default system C library
6594bd5 maintainers.inc: Set me as Maintainer of QEMU.
86851d5 insane: Fix populate_sysroot sanity test path
d09a25e socat: upgrade to 1.7.3.1
fad264b libffi: move from recipes-gnome to recipes-support
d3753dd libffi: ensure sysroot paths are not in libffi.pc
c72614b syslinux: remove LDFLAGS manipulation
8ad11fc lttng-tools: Fix ptest installed la files
66ed16b gnutls: update 3.4.8 -> 3.4.9
149cb17 python-distutils: add missing dependency on python-email
3473962 nss-myhostname: Fix build on musl
42e37d7 linux-firmware: update to latest revision 52442afee
ce1bed7 license.bbclass: add LICENSE_CREATE_PACKAGE to perform_packagecopy vardeps
e43504b i2c-tools: point SRC_URI at Yocto source mirrors
2d7622c gnutls.inc: allow libidn support to be controlled via PACKAGECONFIG
60ebe1c gnutls.inc: add gmp to DEPENDS
935aa96 gnutls.inc: minor formatting improvements
3fa1c54 Revert "kernel/kernel-arch: Explicitly mapping between i386/x86_64 and x86 for kernel ARCH"
0b82af2 wic: isoimage-isohybrid: check for syslinux-native
9699441 formfactor: add machconfig for qemumips64
4701dc9 ncurses: use closing curly brackets in FILES_${PN}-tools variable
9d9f233 util-linux: Change ALTERNATIVE_PRIORITY above busybox
8f2306c mktemp: lower the priority of standalone mktemp package
6251846 libxsettings-client: drop obsolete disable_Os_option.patch
7894633 wic: default to empty bootloader config
090fb51 copy_buildsystem: add ability to exclude layers
8dc600f toaster.bbclass: reinstate scan for artifacts in the sdk directory
eee675b toaster.bbclass: attach image file scan postfunc to do_image_complete
0c0b072 meta: add ASSUME_PROVIDED dependency on wget-native for http fetches
f926610 gtk+3: Tweak getVar to use True, not 1
7fa6eeb classes/lib: Add expand parameter to getVarFlag
252e645 python-pycurl: remove unnecessary exports
9fd214d sstate: Fix SSTATE_SWSPEC only used by populate_lic tasks
4ea6a64 package.bbclass: Add data expansion to do_split_packages()
6ab5001 busybox/gtk/perl/base-passwd: Ensure data is correctly expanded
e8860f7 ref-manual: Fixed typo in FAQ 14.15 section.
9d2925e ref-manual: Updated FAQ entry regarding Proxy for SOCKS
29a44da ref-manual: Fixed type in LICENSE_CREATE_PACKAGE variable description
4181e58 ref-manual: Updated warning regarding libexecdir
0d8bd7d ref-manual: Added description for LICENSE_CREATE_PACKAGE variable.
6aca5b8 ref-manual: Added remove-libtool class
5e2201e toaster-manual: Updated the "Installation" to have TOASTER_DIR information
3aa162a p11-kit: fix packaging warnings
60c9759 piglit: don't use /tmp to write generated sources to
b33e440 libical: Work around hardcoded paths in pkgconfig file
a131b6e documentation.conf: align the documentation for DEBUG_OPTIMIZATION and FULL_OPTIMIZATION with bitbake.conf
974a8c0 pciutils: Explicitly set EXTRA_OEMAKE as required
2d3e6f3 openssl: Explicitly set EXTRA_OEMAKE as required
b07e161 dbus: add user sessions support
877eae1 dbus: use ${systemd_system_unitdir}
6010088 populate_sdk_ext: Add SSTATE_MIRRORS to config blacklist
70ec867 insane: add test for -dev packaging containing real libraries
38d6f1f python3: set INSANE_SKIP as libpython3.so is a trampoline library
4ac4023 p11-kit: fix module packaging
9a27010 libnl: package the libnl-cli modules in libnl-cli
111af1d remove-libtool: add new class
333dce4 gtk-immodules-cache.bbclass: fix immodules-cache path
b1e41f4 Revert "matchbox-keyboard: export GTK_IM_MODULE_FILE location"
ac1f311 directfb: use Yocto source mirrors for SRC_URI
4d80f7a gcc-configure-common.inc: drop --enable-target-optspace from configure
654eddc machine/include: drop tune-cortexm*.inc and tune-cortexr4.inc
322015a liboil: drop recipe from oe-core
41d50f9 boost: Fix build on soft-float ABI arm systems
07a91a6 libnss-mdns: Check for nss.h before using
1b34f55 db: Use cross libtool
64089c6 libtool-cross: Unset pre|post dep objects
457f417 docbook-xsl-stylesheets: create a link for easy refer
1ba62f9 pth: Remove dead code
a4a5d1f3 bitbake: cooker, bitbake-worker: Fix spelling of "received"
8f6b9c7 bitbake: cooker: Only start as many parse threads as we need
602da7c bitbake: knotty: Don't show errors for universe provider issues
1dd2d76 linux-yocto: Adds new genericx86 and genericx86-64 SRCREVs for kernel 4.4
b8fa9d3 poky: Add poky-world-exclude.inc and add qwt-as
5503a22 sstate: Revert using -m option to tar in sstate
6023798 libarchive-native: Disable libxml2 support
b09b054 pcmciautils: Fix makefile race
89df5f1 binutils: Use target provided zlib
c85c54f binutils: Upgrade to 2.26
ba2fdcd native.bbclass: Set CXXFLAGS from BUILD_CXXFLAGS not BUILD_CFLAGS
2394b15 gstreamer1.0-plugins-base: Add video crop supporting when convert frame
2724908 gstreamer1.0-plugins-bad: Fix memory leak of navigation thread
db81fc9 lib/oe/package_manager: remove package feed lists
c43da12 externalsrc: use shared CONFIGURESTAMPFILE if B=S
c6b8227 Make sure that the directory for CONFIGURESTAMPFILE exists
ca06179 autotools.bbclass: use oe_runmake instead of ${MAKE}
f4f9f2f gcc, qemuppc: Explicitly disable forcing SPE flags
691f7e4 pango.inc: misc dependency fixes
70efb8d pango.inc: limit ptest specific do_compile_prepend to target builds
c1273d4 systemtap_git.inc: do not immediate expand SELECTED_OPTIMIZATION
e631be2 glibc.inc: do not immediate expand SELECTED_OPTIMIZATION
770d9ff mkelfimage: fix target cflags leaks to host
c936bf0 base: Move COMPATIBLE_MACHINE out the scope of SOURCE_MIRROR_FETCH
3072361 bitbake: bitbake: BBUIHelper: Remove function findServerDetails
28c041c bitbake: fetch2: Simplify logic in verify_checksum()
5375e64 bitbake: bitbake: Set process names to be meaninful
5b234d1 bitbake: utils: Add ability to change the process name
0b06924 bitbake: data.py: avoid double newlines at the end of functions in emit_var()
68600ae bitbake: build.py: minor shell_trap_code() formatting tweaks
423a264 conf/distro/poky.conf: use example.com for connectivity check
6c058ce curl: update 7.46.0 -> 7.47.0 ( CVE-2016-0754 CVE-2016-0755 )
adbe63d openssl: update 1.0.2e -> 1.0.2f ( CVE-2016-0701 CVE-2015-3197 )
85b6679 autotools.bbclass: don't create subshell to delete configure scripts
2f1bcc1 sstate: Add back packagedata on packagedata dependencies
346b225 libical: update to 2.0.0
b696bb3 kexec: package kdump init script/configuration file correctly
51cebbf connman: fix crash with iptables 1.6
7f54fab autotools_stage.bbclass: remove it
07c4bc1 gdb-common.inc: add PACKAGECONFIG for readline
5869e35 tzdata: update to 2016a
c9cc707 tzcode: update to 2016a
aff2f58 glibc-testing.inc: drop pruning of PATCH_GET from the testglibc script
dfb9d41 gcc-cross.inc: drop pruning of PATCH_GET from the testgcc script
9e7d929 bitbake.conf: stop exporting PATCH_GET = "0"
5410aff sstate: Improve handling of useradd dependencies
9823802 gtk-icon-utils-native: Drop problematic dependency
6c04e0d glib.inc: limit ARM_INSTRUCTION_SET over-rides to armv4/armv5
83476b5 glib-2.0: drop add-march-i486-into-CFLAGS-automatically.patch
fab76ae glib-2.0: refresh configure-libtool.patch
593dcd4 systemd: fix systemctl enable script for template units
3c90507 glib: use bash-completion.bbclass
d88ed5d kmod: use bash-completion.bbclass
0f3780c git: use bash-completion.bbclass
9d20661 util-linux: use bash-completion.bbclass
0e5b0bf dbus-glib: use bash-completion.bbclass
9cddc0a bash-completion.bbclass: add class
ddb786c bash-completion: move in recipe from meta-oe
74e2f68 ffmpeg: add a recipe, and remove the libav recipe
eb7e554 lib/oe/patch: Make GitApplyTree._applypatch() support read-only .git/hooks
3ed566e gcc: fix hidden weak symbols by removing buggy gcc patch
51d9ba6 dpkg: fix CVE-2015-0860
f80d16e qemu.bbclass: clarify QEMU_EXTRAOPTIONS
3dca294 pango.inc: drop obsolete dependency on qemu-native
a16e9a2f dbus: upgrade to 1.10.6
7081458 buildhistory: fix the check for existence of a git repo
d74325e connman: tidy up connman-conf usage
79f4495 connman-conf: convert to systemd oneshot
5c35883 bitbake-whatchanged: avoid double do_ task name prefix
7881c02 netbase: add ipv6 host to /etc/hosts
93fcee6 linux-yocto/4.4: CVEs and preempt-rt update
07c182f linux-yocto/4.1: update to 4.1.16
7003698 gstreamer1.0-plugins-bad: fix compiler warnings with -Os in 1.7.1
6e90145 gstreamer1.0-plugins-good: fix compiler warnings with -Os in 1.7.1
3cd70c8 libsoup-2.4: add glib-2.0-native dependency
d5b3b97 libtirpc: remove stray .orig file from Use-netbsd-queue.h.patch
209066c ptest-runner: Add ptest-runner_2.0 recipe.
4953e26 musl: Upgrade to tip of tree
52413d0 libdrm: Refresh patch to match upstream submission
66e215f fts: Correct LIC_FILES_CHKSUM
be4c446 pth: Delete
df95988 elfutils: Fix build with uclibc/musl
047ad2c grub: Backport fix for largefile detection/use
956be0c oeqa/runtime/rpm: be more verbose if test_rpm_query_nonroot fails
3b5288f libc-package.bbclass: add LOCALE_UTF8_IS_DEFAULT
4f3ef90 ref-manual: Updated the BBMASK variable description.
b2b7214 dev-manual: Restored ptest-runner2 to ptest-runner
d484e58 ref-manual: Removed obsolete do_deploy statement from "Shared State"
7705b87 toaster-manual: Updated instructions for production setup.
4b4a8a6 ref-manual: Updated the SDK figure.
d7481ce ref-manual: Added do_image and do_image_complete tasks
d39e9d1 ref-manual: Rewrite of "Image Generation" and devtool text.
1e7735e ref-manual, mega-manual: Updated the Image Creation figure
fded4fa ref-manual: Updated configuration of auto.conf in closer look
9f192c8 dev-manual: Updated the devtool help examples.
4bbd39d dev-manual: Grammar fix to kickstart section.
75078dd dev-manual: Updated wic reference section
9ed7881 poky-ent: Grouped Fedora perl packages for niceness
3ac0416 local.conf.sample.extended: Update the info about BBMASK
d61d290 bitbake: bitbake-user-manual-ref-variables: Update the help for BBMASK
a948f52 bitbake: cooker: Allow BBMASK to contain multiple regular expressions
e82101a bitbake: bitbake-user-manual-metadata: Updated 'dir' flag
100d6c2 bitbake: bitbake-user-manual: Updated the example BitBake directory
11be341 documentation.conf: Update the help for BBMASK
3d2c0f5 cmake: update to 3.4.2
4364850 at-spi2-core: update to 2.18.3
c763940 webkitgtk: update to 2.10.5
1e95815 libsecret: update to 0.18.4
9259a43 freetype: update to 2.6.2
5ec6dbb gdk-pixbuf: update to 2.32.3
9c84fbc glib-2.0: update to 2.46.2
bd7278c gtk+3: update to 3.18.6
d609cd5 gtk+: update to 2.24.29
6197313 gtk-icon-utils-native: update to 3.18.6
1556f0e libsoup-2.4: update to 2.52.2
dff038a waffle: update to 1.5.2
89bd19f vala: update to 0.30.0
6c02099 rxvt-unicode: update to 9.22
245af2b btrfs-tools: Disable backtrace on musl
fa01d37 bsd-headers: Fix LICENCE and dev package RDEPENDS
05e11a5 gdb: Fix build failures on musl
72c1aa2 ltp: Add rdep on ldd
1d0332d argp-standalone: Fix build when S != B
9f22898 bitbake: fetch2/wget: fallback to GET if HEAD is rejected in checkstatus()
d11cc29 busybox: fix stop -vs- start typo in rcS script
9f4b088 mtools: keep v3.9.9 recipe in sync with the v4.0.18 version
2c14be3 gen-lockedsig-cache: fix bad destination path joining
9dea876 distutils-common-base: do not set PACKAGES - use defaults from bitbake.conf
4ead707 insane: remove unused variable assignment
44e9c3b meta: fix capitalisation in Upstream-Status
06b4572 pixman: only check even upstream versions
0f74387 gcr: check only even upstream versions
a2848ee avahi: Add patch to fix Win10 mDNS issues
04ef34f xf86-input-libinput: initial add 0.16.0
8a2dfa1 image.bbclass: check INITRAMFS_MAXSIZE
962cc37 systemd: make TEST_DIR configurable
9967746 bind: update to 9.10.3-P3
cac47db uninative: handle UNINATIVE_URL being file:///
9995814 uninative: fix path to patchelf-uninative
2495dfa scripts/wipe-sysroot: also delete uninative sysroot
bb97157 meta/lib: new module for handling GPG signing
aadb879 devtool: extract: use the correct datastore for builddir
fa801e7 busybox: backport upstream truncate open mode fix
6996b26 gstreamer1.0-plugins-base.inc: drop obsolete dependency on liboil
1c4a8cc e2fsprogs: disable blkid
0de8766 pango.inc: drop obsolete FULL_OPTIMIZATION over-ride
89a7ed5 devtool: add configure-help subcommand
84720c8 devtool: properly handle bb.build.FuncFailed when extracting source
c3f0f7b devtool: add: warn if modified recipe found in attic directory
e559b66 devtool: build-image: allow specifying packages to add to image
e00eac8 devtool: move edit-recipe to a separate module
6720bda image: Don't create tasks with '.' in the name
88ca227 rootfs-postcommands: fix allow-empty-password on read-only rootfs
fdac363 kernel: Clean DEPLOYDIR before do_deploy runs
c2231de gcc-cross-canadian: Add missing DEPENDS on virtual/${HOST_PREFIX}gcc-crosssdk
5fdedb6 libtirpc: Drop unneeded xz-native dependency
7a98fb7 libuser: Drop unneeded xz-native dependency
72f98ba bitbake: toaster: Update UI test runner
c192bd6 Revert "xz: Allow to work with ASSUME_PROVIDED xz-native"
6df607b acpid: upgrade to 2.0.26
7a52f67 build-perf-test.sh: add eSDK testing
5c367ec build-perf-test.sh: more generic timing function
44fee2b python3-pip: Upgrade to 8.0.0
9d95a9d orc: update HOMEPAGE
0c1c93e gstreamer1.0-plugins.inc: drop obsolete ${S}/po/Makefile.in.in workaround
be145ad busybox: Add support for busybox-init
716fa93 pulseaudio.inc: drop obsolete dependency on liboil
55bfaa2 sqlite3: update 3.10.0 -> 3.10.2
6bb1dd1 sqlite3.inc: add PACKAGECONFIG to support building against libedit
39f6a9e sqlite3.inc: dynamically link the sqlite3 command-line utility
9b2835e sqlite: formatting improvements, move more stuff into sqlite3.inc
89ed462 sqlite3.inc: drop obsolete config_BUILD_CC, etc exports
6188419 sqlite3.inc: fix readline PACKAGECONFIG
939de8d sqlite3: fix the parallel build fix patch
a304b82 weston: Add missing DEPENDS on wayland-native
4a5458f bitbake: fetch2: Don't show checksum warnings if a single checksum was supplied
e66599f uninative: Fix conflicts with normal sysroot
4833bee insane: Drop do_stage test
861c916 populate_sdk: Use pixz instead of xz
a1c35f3 lib/oe/sdk: Partially revert "sdk.py: fix conflicts of packages"
29c5eda uninative: Add fetch capability
b54fa25 pixz: Add 1.0.6
d47572d xz: Allow to work with ASSUME_PROVIDED xz-native
0aeb33f lib/oe/package_manager: prevent testing an undefined variable
c1f4e92 recipetool: create: better fix for fetch error handling
10c8d14 recipetool: create: fix extraction of name from URLs ending in /
b307e0a recipetool: create: extract SRC_URI from local git repositories
50e40fc devtool / recipetool: support specifying a subdirectory within the fetched source
7e1691d recipetool: create: strip quotes from values extracted from CMakeLists.txt
477fa84 gen-lockedsig-cache: copy correct native sstate into ext SDK
204e4ab toolchain-shar-extract.sh: improve behaviour when xz is not installed
979c8fb classes/populate_sdk*: add dependencies on script files
f220abc classes/populate_sdk_ext: drop ext-sdk-prepare.py when installing
b435225 devtool: add sdk-install subcommand
44d1a2a devtool: sdk-update: improve SDK update process robustness
3360baa devtool: sdk-update: improve temp directory handling
d193531 devtool: build: ensure pkgdata is written out
d3a4f72 classes/populate_sdk_ext: add option to bring in pkgdata for world
a9dfced linux-libc-headers: Port patches for linux-headers for musl
3cffa6d libsolv: Update to 0.6.17+
d9134cf glib-2.0: Fix locale location on musl
527cd95 syslinux: Set LD to avoid using build host ld
136db70 binutils: Fix gold linking errors due to unresolved R_ARM_MOVW_ABS_NC
704e342 puzzles: Silence warning on arm with clang
bee65f9 eglinfo: Fix build on raspberrypi
6296c0f mdadm: Fix build with musl
67eef11 gpgme: Define __error_t_defined on musl
368e838 console-tools: Fix header inclusion when not using glibc
5a8c935 uclibc: Update to 1.0.11
1113d58 unfs3: Depend on libtirpc when building on musl
2ecfc02 guile: Fix build with musl
2df08b8 bsd-headers: Package cdefs.h
29deaf0 musl: Create ld.so as a relative symlink
2d028b3 fts: Fix linker hash-style option
8dd1aa8 dosfstools: Correct cross-compile CFLAGS and fix build with musl
21550d1 nss: Undefine HAVE_SYS_CDEFS_H
92e6a7a apmd: Fix build with musl
5d661c5 pcmciautils: Fix parallel build and include sys/types.h
86795ff kexec-tools: Define _GNU_SOURCE for getting loff_t definition
ff8006f systemd: Skip parsing on musl based targets
f2856a1 oprofile: fix build with musl
226c450 portmap: Point to tirpc headers and libraries on musl
5512c2f nfs-utils: Disable tcp-wrappers for musl
06d0204 bsd-headers,musl: Add recipe for bsd missing features
c2c9202 tcf-agent: Implement canonicalize_file_name() for musl as well
f294813 chkconfig: Avoid using caddr_t
b2aca09 nspr: Drop older glibc code
c0976fc irda-utils: Fix header inclusions
a3f9721 iproute2: Fix build with musl
22333f0 libuser: Fix build when secure getenv is not there
ea9dc99 iputils: Use member based initialization for mrghdr struct
b207868 pax: Fix build with musl
1076499 tar: Fix build for musl based targets
e451023 rt-tests: Fix build with non-gcc compilers
68da390 webkitgtk: Fix build with clang/musl
da81635 console-tools: Include sys/types.h for u_char and u_short defs
205a07a sysklogd: untangle header inclusion maze
9f40dba babeltrace: Add missing header for MAXNAMLEN define
2458850 libunwind: backtrace APIs are glibc specific
abdfacb apt: Add support for building for musl targets
ec187d3 puzzles: Zero'ise structs before use
3cd0a8c dpkg: Add musleabi to known architectures
aaa8516 xinetd: Fix build with musl
93fb408 watchdog: Fix build with musl
7509ffd gzip: Fix build with musl
1d28cbc directfb: Fix build with musl
7b6b312 net-tools: Link with libintl on uclibc
ee1bfdb parted: Fix build with uclibc
ed5da2a mtools: Fix build with uclibc
5384f08 gnutls: Link with libuargp on uclibc
493e557 guile: Fix build with uclibc
1636f6f packagegroup-self-hosted.bb: Move glibc-gconv-ibm850 to glibc only case
3e7d7ab util-linux: Fix ptest builds on musl
77825f8 gnutls: Link with libargp on musl and depend on argp-standalone
1a6fe71 argp-standalone: Add recipe
a7d780c gdk-pixbuf: Fix latent build issue exposed by musl
f2cf5d3 xserver-xorg: Fix build with musl
b8de631 libcgroup: Add dependency on fts when building on musl
87c3e98 connman: include config.h for HAVE_STRUCT_IN6_PKTINFO_IPI6_ADDR
cc55fc7 fts: Add recipe
6e3950b tcp-wrappers: Fix build with musl
68f88a5 ppp: Fix build with musl
4972edd blktrace: Include <sys/types.h for dev_t
d629fa1 powertop: Include right headers for timval struct
063dc38 update-alternatives: when warning about alt_link==alt_target, say what PN
6baafa1 python-setuptools: Unify and upgrade python-setuptools and python3-setuptools to 19.4
f0e500e gstreamer1.0-libav: update git recipe to 1.7.1
90cbdfb gstreamer1.0-plugins-ugly: update git recipe to 1.7.1
6752484 gstreamer1.0-plugins-bad: update git recipe to 1.7.1
ad8f201 gstreamer1.0-plugins-good: update git recipe to 1.7.1
2ca9f20 gstreamer1.0-plugins-base: update git recipe to 1.7.1
3c7f2b8 gstreamer1.0: update git recipe to 1.7.1
7c810d0 gstreamer1.0-libav: update 1.6.2 -> 1.6.3
a4b8e9a gstreamer1.0-plugins-ugly: update 1.6.2 -> 1.6.3
8170e06 gstreamer1.0-plugins-bad: update 1.6.2 -> 1.6.3
497ebc9 gstreamer1.0-plugins-good: update 1.6.2 -> 1.6.3
3d87902 gstreamer1.0-plugins-base: update 1.6.2 -> 1.6.3
1e256ee gstreamer1.0: update 1.6.2 -> 1.6.3
dacf2aa gst-plugins-package.inc: drop perl RDEPEND for XXX-apps packages
676275f gstreamer1.0-plugins.inc: don't set base SRC_URI via python
852f098 gstreamer1.0-plugins.inc: drop obsolete lib-link.m4 workaround
a32ac26 gstreamer1.0-plugins-bad.inc: update hls dependency gnutls -> nettle
97e0752 gstreamer1.0-plugins-bad.inc: don't set ${S} or apply version specific patch
78e9361 gstreamer1.0-plugins-good.inc: remove duplicate --disable-examples
0edabfd gstreamer1.0-plugins.inc: convert GSTREAMER_1_0_DEBUG to a PACKAGECONFIG
81cd227 gstreamer1.0-plugins.inc: add missing glib-2.0-native dependency
a0b1e66 gstreamer1.0.inc: add missing glib-2.0-native dependency
e5fb79d gstreamer1.0-rtsp-server.inc: minor formatting improvements
434aa8e gstreamer1.0-omx: minor formatting improvements + update HOMEPAGE
69bcd33 gstreamer1.0-libav: minor formatting improvements + update HOMEPAGE
1d6e61a gstreamer1.0-plugins-ugly: minor formatting improvements
c45ce26 gstreamer1.0-plugins-bad: minor formatting improvements
c1ea981 gstreamer1.0-plugins-good: minor formatting improvements
beb8091 gstreamer1.0-plugins-base: minor formatting improvements
61f30b4 gstreamer1.0-plugins.inc: minor formatting improvements
981145a gstreamer1.0: minor formatting improvements
9f1a943 gst-plugins-package.inc: minor formatting improvements
9e08b69 gst-player: minor formatting improvements
a8ed2c8 valgrind: remove unused valgrind-remove-rpath.patch
e24123d emptytest: exclude from world builds
6808035 build-appliance-image: bump version to 14.0.0
eb418c3 insane.bbclass: fix package_qa_walk()
e185004 insane.bbclass: print all the QA messages
95fa36e weston: upgrade 1.8.0 -> 1.9.0
1bc0c89 wayland: upgrade 1.8.1 -> 1.9.0
03dae8e glib-2.0: fix the ptest
68c5e6d insane.bbclass:buildpaths: ignore ipkg/dpkg's CONTROL dir
258676b sstate: display the sysroot name when cleaning for clarity
f35b2e2 bitbake: set default libexecdir to $prefix/libexec
40f0c2d gawk: fix libexecdir/libdir/BPN confusion
2458f41 mesa: update SRC_URI
fdb12f9 e2fsprogs: set PV to 1.42.99+1.43+git${SRCPV}
9cf1ec0 valgrind: avoid neon for targets which don't support it
b191f58 valgrind: re-enable ARM intdiv and vcvt_fixed_float_VFP tests
b0b3412 valgrind: let valgrind determine its own optimisation flags
92abb5f meta/files/toolchain-shar-relocate.sh: Detect different python binaries and select one that exists.
924e2c3 python-nose: upgrade to 1.3.7
02440b5 python-native: Make python-native also RPROVIDE python-unittest-native
b7ca05d linux-libc-headers: update to 4.4
f73ee59 libpng12: upgrade to 1.2.56
3a59486 libpng: upgrade to 1.6.21
63a49f8 libtirpc: remove redundant va_list patch
55a8df2 perl: Upgrade to 5.22.1
a840588 oeqa/selftest/signing: use temporary rpmdb
65c1de9 kexec-tools: inherit update-rc.d
ba837f1 autotools: don't output the full config.log on configure failure
3e3cb62 bitbake.conf: Remove horrible variable expansion hacks
b963efb mesa: add missing wayland-native build dependency
9dd6c81 maintainers.inc: Correct maintainership for several packages
bd1a534 bitbake: toaster: run bitbake server with --read option
76a281c bitbake: taskdata: add the ability to access world targets list
11a1f49 bitbake: cache.py: check existence before add to cachedata.rproviders
05c1775 bitbake: taskdata.py: add RuntimeProviders to close matches
cf9cb65 bitbake: data_smart: Don't show exceptions for EOL literals
b80219e udev: Add 2 patches to support 4.4 kernel
1013385 gcc-runtime.inc: provide libquadmath
60b237f kexec: update supported architecture list
92a0032 strace: update 4.10 -> 4.11
0aa8169 strace: fix ARCH definition in tests/Makefile
2408149 strace: remove need for git-version-gen script
9ca6a5f strace: fix --disable-aio configure option
dd90f32 strace: drop unnecessary dependency on acl
aadae7b libnewt: Fix linking error due missing symbols
571289d lib/oe/package_manager.py: Remove list() from PkgsList class
6ebda8e lib/oe/rootfs: Use list_pkgs() instead of list()
03075f6 lib/oe/utils: Add function format_pkg_list()
c708411 lib/oe/package_manager: Add list_pkgs() to PkgsList class
113e136 python3: Minor upgrade 3.5.0 -> 3.5.1
918149d python-numpy: upgrade to 1.10.4
eae7584 swig: upgrade to 3.0.8
21f7677 python-scons: upgrade to 2.4.1
7721652 python-pycurl: upgrade to 7.21.5
2ef401f python-mako: upgrade to 1.0.3
2a608cc python-setuptools: Upgrade to 19.2
6395bc8 python3-setuptools: upgrade to 19.2
40738af python: Upgrade 2.7.9 > 2.7.11
35855a0 wic: pylinted ksparser module
e3b3bcf wic: add help for 'include' command
bfaabe5 wic: move parts of canned .wks into common.wks.inc
50a3dc5 wic: implement search of includes
15ea180 wic: refactor get_boot_config
d304162 wic: ksparser: add support for include
3fc6aaa wic: do not remove build dir in source plugins
8d34eea wic: use unique partition number
43b4058 wic: move wks parsing code to KickStart._parse
3860640 nss: update to 3.21
ea39ad0 libjpeg-turbo: fix upstream version check (sort of)
48a8a89 libical: fix upstream version check
c6f71c5 gnutls: update to 3.4.8
7a80f84 sysstat: fix upstream version check
2aabf9a pbzip2: update to 1.1.13
77aee28 ncurses: fix upstream version check
56e4ff6 libsolv: fix upstream version check
d46bc77 e2fsprogs: fix upstream version check
0436e3f build-appliance-image: bump version to 14.0
a206a19 btrfs-tools: update to 4.4
a1790bc bootchart2: update to 0.14.8
68c7113 poky.conf: Delete BB_SIGNATURE_HANDLER settings
0916235 rpm: remove bashisms: [ x == x ] -> [ x = x ]
2dbd61f uclibc: remove a use of immediate expansion and oe_filter_out ()
32eeb00 gcc-runtime: switch to removal override syntax to modify CXXFLAGS
c886a78 bitbake: tests/codeparser.py: Add filename/lineno flags to test variable
f130033 bitbake: toaster: write variables to toaster.conf
1835768 sstate: replace verbose manifest removal with a single count
d4c721a libdrm: Upgrade 2.4.65 -> 2.4.66
b5508a8 slang: Add dependency on ncurses
27b2df2 valgrind: make it explicit that valgrind supports armv7a and above
5dc38a3 sign_rpm.bbclass: fix task dependencies
27c39c4 opkg-utils: store alternatives in nonarch_libdir
77fde15 security_flags.inc: remove obsolete workarounds for curl
31ce027 cups: update systemd support
a4b48c2 coreutils: Add xattr PACKAGECONFIG
7a0b1c1 oeqa/runtime/parselogs: use -F to search fixed strings for grep
b8e11e2 libinput: Upgrade 0.21.0 -> 1.1.4
a9f2e87 postinst-intercepts: always use set -e
de0848f maintainers: mark Khem as nominal owner for uclibc
3235f5e formfactor: remove unused beagleboard configuration
6c64700 alsa-state: remove beagleboard configuration
f0d47a6 bitbake: Revert "runqueue.py: Ensure one setscene function doesn't mask out another which needs to run"
9e867ef sstate: Add packagedata to list of tasks not to recurse
5e881c1 classes/populate_sdk_ext: fix task dependency regression
2e9f092 image: Handle image types containing '-' correctly
0612ca4 oe-selftest: devtool: fix test_devtool_add_library if python was built first
c1492c4 recipetool: create: add a couple more license checksums
2c8c9fe recipetool: create: add basic support for extracting dependencies from cmake
3eb397f recipetool: create: force GL libraries to virtual/*
726dbda recipetool: create: move dependency mapping code to RecipeHandler
788e4bb recipetool: create: fix overzealous mapping of git URLs
ece0a2e recipetool: create: support additional autoconf macros from autoconf-archive
903d471 recipetool: create: detect flex/bison dependency
a66f4ac recipetool: create: pick up boost macros in configure.ac
dbe91a3 recipetool: create: improve extraction of pkg-config / lib deps
e7bedb9 wic: rename kickstarter.py -> ksparser.py
3bb6ea6 wic: override ArgumentParser.error
d652203 wic: removed unused imports
d2090a6 wic: improve processing of parseing errors
1ed97cc wic: catch KickStartError
bda77fd wic: add custom exception KickStartError
ef211a5 bootimg/image-vm/image-live: Improve image dependencies
0910bc6 image: Always run do_rootfs_wicenv
12e37e7 selftest/buildhistory: Improve test to remove sources of error
05716dd bootimg/image: Enhance bootimg to respect RM_OLD_IMAGE
1c869a9 rootfs-postcommands: Ensure license manifests respect RM_OLD_IMAGE
d27491b image: Ensure we don't expand TMPDIR in image commands
ce8a206 image: Fix instability of do_image_* checksums
fb1654f image: Fix wic environment issues
1da8f52 insane: Start to clean up do_configure_qa code
dd28695 insane: Clean up horrible return value processing code
839fb18 e2fsprogs: fix PV
b1236dc e2fsprogs: add PACKAGECONFIG for fuse
f98e11c bitbake: toastergui: make artifact download more robust
68f3e1e bitbake: toasterui: log OSErrorException metadata events
fb94754 bitbake: toasterui: listen for bb.event.MetadataEvent
a2f23fa openssh: CVE-2016-1907
320a319 license.bbclass: fix license manifest
4339a82 wic/help.py: document requirements for valid fstab generation
d688df8 glib-2.0: add dependency glib-2.0-native back
76e35f1 kernel-yocto.bbclass: move do_kernel_link_vmlinux() into kernel.bbclass
d453fa1 kernel-yocto.bbclass: remove do_kernel_link_vmlinux from SRCTREECOVEREDTASKS
2b92f88 libarchive: Add bsdtar and bsdcpio packages
e246905 toaster.bbclass: Separate artifact dump from image file dump
4f481bc pax-utils: 1.0.5 -> 1.1.4
f9974f2 sqlite3: upgrade to version 3.10.0
cd7910d connman: upgrade to 1.31
b9169b7 python3: add missing dependency on PN-misc to PN-modules
4b4dea7 useradd-staticids.bbclass: Remove unnecessary spaces
4f2c352 useradd-staticids.bbclass: Read passwd/group files before parsing
4cbdb15 useradd-staticids.bbclass: Simplify the logic for when to add groups
b18e40c useradd-staticids.bbclass: Simplify some logic
b689aa0 useradd-staticids.bbclass: Make --no-user-group have effect
c03ea8d useradd-staticids.bbclass: Treat mutually exclusive options as such
af8b005 wic: get rid of 2 getters
2573e28 wic: get rid of set_size and set_source_file setters
5cd222b wic: get rid of get_rootfs and set_rootfs
4d5d5dd wic: get rid of get_timeout getter
26fb2a1 wic: adjust code for new data structure
c827238 wic: remove pykickstart code
c15ea82 wic: use new kickstart parser
f572f44 wic: add kickstart parser module
e5e1905 wic: add partition module
180f170 alsa-lib: 1.0.29 -> 1.1.0
a8c25af matchbox-keyboard: export GTK_IM_MODULE_FILE location
d75cb1f xf86-input-evdev: upgrade to 2.10.1
2283732 menu-cache: upgrade to 1.0.1
ec7e406 libxi: upgrade to 1.7.6
86f3f25 librsvg: upgrade to 2.40.13
72dd806 libgpg-error: upgrade to 1.21
3c02fe0 libevdev: upgrade to 1.4.6
33e9930 libcroco: upgrade to 0.6.11
5b63c44 gsettings-desktop-schemas: upgrade to 3.19.3
dfff167 gpgme: upgrade to 1.6.0
5abb691 u-boot: Update to 2016.01 release
e9280d1 linux-yocto: introduce v4.4 standard/preempt-rt/standard kernel
8c3276e e2fsprogs: 1.42.9 -> 1.43 (master)
b248e55 bitbake.conf: rename python-native-runtime
65d0bfc net-tools_1.60-26.bb: Fix do_patch dependency error
99923fc ncurses: 5.9 0 -> 6.0
44d283a autotools.bbclass: use relative path to run configure script
b2f1de3 glibc-initial.inc: use relative path to run configure
0fe6e2d bitbake: toaster: increase timeout
a5f34bc poky.ent: Added "perl-bignum" package for Fedora
afc6cba dev-manual: Updated "Running ptset" section
ec047ad yocto-project-qs: Updated the "Next Steps" section
57ddbe8 ref-manual: Removed all variables related to "QMAKE"
7814b33 ref-manual: Updates to cull out qt4 stuff.
bf81969 toaster-manual: Updates on how to start Toaster.
798e8b8 bitbake: toastergui: code formatting and clean-up
c4b5011 bitbake: toaster tests: fix Django tests for new ToasterTable pages
88a262c bitbake: toastergui: remove unused views and template code
059a274 bitbake: toastergui: fix error and warning counts for builds
4103e0c bitbake: toastergui: make "Apply" button state depend on filter range
6c2d88f bitbake: toastergui: mute label for filter actions with no records
f08730a bitbake: toastergui: set default visible and hideable columns
112f374 bitbake: toastergui: serialise decimals correctly
e024aab bitbake: toastergui: streamline construction of filter objects
fcb20f9 bitbake: toastergui: ensure filter_value updates
f9c46f5 bitbake: toastergui: don't hide all elements with .col class
eaae82a bitbake: toastergui: convert project builds page to ToasterTable
33b011c bitbake: toastergui: implement "today" and "yesterday" filters
f8d383d bitbake: toastergui: implement date range filters for builds
b929889 bitbake: toastergui: show recent builds on all builds page
1a4b203 bitbake: toastergui: switch off filter highlights when inactive
809046c bitbake: toastergui: refactor ToasterTable filtering
294579b bitbake: toastergui: convert all builds page to ToasterTable
6c12ca7 bitbake: toastergui: use event delegates for hover help elements
ef93dce bitbake: toastergui: switch projects/ view to ToasterTable
417f1d3 bitbake: toaster: check inferred file suffixes against list of known types
c02ee05 bitbake: toaster: move image file suffix list to model
d29e4cd bitbake: toastergui: use ToasterTable for projects page
b1256db openssh: update to 7.1p2
c0e9f2d kernel/kernel-arch: Explicitly mapping between i386/x86_64 and x86 for kernel ARCH
f8508de bitbake: Revert "fetch/git: Change to use clearer ssh url syntax for broken servers"
b567235 image/image-live: Add back IMAGE_TYPES_MASKED support
e914e2a image.bbclass: Handle image base type dependency properly
ad32f65 autoconf: add missing perl-module-file-find to RDEPENDS
d83dfe6 ca-certificates: update to 20160104
4440560 epiphany: upgrade to 3.18.3
dcf54b4 iso-codes: upgrade to 3.64
d7bee35 lighttpd: upgrade to 1.4.39
08c8923 libwebp: upgrade to 0.5.0
cf0aea7 classes/populate_sdk_ext: avoid unnecessary sstate being brought in
ea29bec insane/package: Fix cases where QA errors aren't fatal
2e620a4 classes/populate_sdk_ext: check that extensible SDK prepared correctly
4685c33 classes/buildhistory: save auto.conf and bblayers.conf for extensible SDK
39f6472 classes/populate_sdk_ext: support auto.conf
91877aa classes/populate_sdk_ext.bbclass: handle if local.conf doesn't end with a newline
764c927 util-linux: create util-linux-runuser iff pam in DISTRO_FEATURES
95dce70 rsync: 3.1.1 -> 3.1.2
38aa0fc less: 479 -> 481
4cb2269 iputils: s20121221 -> s20151218
fe47dd7 wget: 1.17 -> 1.17.1
79886e9 git: 2.5.0 -> 2.7.0
d3e16b8 file: 5.24 -> 5.25
3549abc autogen-native: 5.18.5 -> 5.18.6
fb14627 curl: upgrade to 7.46
eaf88d7 xz: upgrade to 5.2.2
8516ff7 sysstat: upgrade to 11.2.0
ae73be1 at: upgrade to 3.18
21efab7 kmod: upgrade to 22
c88efae resolvconf: upgrade to 1.78
6729889 pciutils: upgrade to 3.4.1
edd319c gnupg: 2.1.7 -> 2.1.10
78b58b8 help2man-native: 1.47.1 -> 1.47.3
ac0e0d5 man-pages: 4.02 -> 4.04
1e0cbb9 libgcrypt: 1.6.3 -> 1.6.4
372c23d xmlto: 0.0.26 -> 0.0.28
aaafe33 elfutils: 0.163 -> 0.164
38901a7 dhcp: 4.3.2 -> 4.3.3
ea05e05 image.bbclass: Unconditional includes of populate_sdk_ext fails
c08f272 tcmode-default.inc: Fix preferred provider nativesdk-sdk_prefix-libc-initial
5d2f783 dhcp: search libxml2 for bind
b69652d tzdata: remove bashism
7c7c249 harfbuzz: update 1.1.2 -> 1.1.3
84623dc libpostproc: duplicate armv7a over-rides for armv7ve
1744198 libav.inc: duplicate armv7a over-rides for armv7ve
102dfa1 gcc-configure-common.inc: duplicate armv7a over-ride for armv7ve
b08dfb5 subversion: Upgrade 1.9.2 -> 1.9.3
d6fae0c lttng-ust: Upgrade to 2.7.1
a9cc9b5 lttng-tools: Upgrade to 2.7.1
6b02575 lttng-modules: Upgrade to 2.7.1
a378430 gdb: upgrade to 7.10.1
92cc02f linux-yocto: Update Genericx86* BSPs to 4.1.15
da43a56 bitbake: Revert "fetch2/local.py: avoid using PREMIRROR"
96a34e7 conf/distro/poky-tiny: correctly disable python in opkg-utils
1724ffd bitbake: fetch2/git.py: Add missing "errno" module import.
74fa824 bitbake: bitbake: clean up stamp-base related codes
f3f769a local.conf.sample: add qemumips64
43328fe bitbake: runqueue: Fix setscene task dependencies
7b905ca bitbake: toaster: settings Add uid to the toaster cache dir
dff7a27 bitbake: toaster: show 'satisfied via' text for reverse deps
89f4932 bitbake: toaster: show 'satisfied via' text for build deps
febb898 bitbake: toaster: show list of provides for the recipe
2ff4ccb bitbake: buildinfohelper: add provides info to the db
16a81fb bitbake: toaster: add Provider model
6a28ed3 bitbake: buildinfohelper: use providermap
f2b7252 bitbake: cooker: add providermap to dep_tree
7e380d4 bitbake: taskdata: refactor get_providermap
46731da bitbake: main/runqueue: Add --setscene-only option to bitbake
34f8db9 update_font_cache: only scan system font directories
e5c011b Add "CVE:" tag to current patches in OE-core
f04fb88 scripts/create-pull-request: fix git request-pull syntax
928ceb6 qt4: fix-for-mips-n32.patch: remove it
c4a3258 util-linux: create util-linux-runuser package
554ca68 valgrind: include aarch64 in COMPATIBLE_HOST
0ce775a valgrind: update to 3.11.0
21a94f6 valgrind: don't restrict to armv7a
b8ebac9 DpkgRootfs: Fix logcheck_error false-positive when use multilib
e265fbb package_deb.bbclass: add 'Multi-Arch: foreign' tag to allarch packages
4aeb69d package_manager.py: fixes for multilib deb packaging builds
9ea7428 package_deb.bbclass, cross-canadian.bbclass: DPKG_ARCH mapping function
72e6932 connman.inc: add missing RDEPENDS
675ff42 meta: rename perl-native-runtime
3f4fb39 dbus: support large-file for stat64
0d5e41f freetype: enable out-of-tree builds, and use host zlib
8f2ab19 bluez5: upgrade to 5.37
11f5a42 cogl-1.0: fix may be used uninitialized error
235606f oeqa/runtime/logrotate: fix hardcoded root directory
cce6c3e oeqa/runtime/smart: fix hardcoded root directory
cd2cf1f boost: update to 1.60.0
afc0255 bitbake.conf: remove 'stamp-base'
c8fef7f gcc5: Fix build on NIOS2
eda3947 rpmresolve.c: Fix unfreed pointers that keep DB opened
3c8a451 tzdata: Make /etc/timezone optional
b80da02 systemd: arrange for volatile /etc/resolv.conf
5548a76 systemd: add myhostname to nsswitch.conf
d6bc841 opkg-utils: add update-alternatives PACKAGECONFIG
c3b96ff linux-dtb.inc: use absolute upd-alt paths
3ad08c0 uclibc: Upgrade to 1.0.10
74c3667 populate_sdk_ext: Pass excluded_targets as a list to prune_lockedsigs
e306d54 populate_sdk_ext: Change to include siginfo and non sstate task sigs
e1a558a populate_sdk: Switch from bzip2 to xz
3341f3f classes: Fix do_rootfs references
0a4e1f9 image: Create separate tasks for rootfs construction
fdced52 image: Move pre/post process commands to bbclass
cdc0aee image.bbclass: Separate out image generation into a new task, do_image
0269219 populate_sdk_ext: Use new --setscene-only option to bitbake instead of workarounds
1ee0842 sstatesig: Handle special case of gcc-source shared-workdir for printdiff
d93c212 bitbake.conf: add virtual/libiconv-native to ASSUME_PROVIDED
b2fe2a8 devtool: build: support using BBCLASSEXTENDed names
38ed039 devtool: reset: support recipes with BBCLASSEXTEND
532f429 devtool: refactor code for getting local recipe file
ec90168 devtool: add: support adding a native variant
99e3872 devtool: reset: do clean for multiple recipes at once with -a
5ef716c recipetool: create: support creating standalone native/nativesdk recipes
1e503c0 recipetool: create: lower case name when determining from filename
4deed25 devtool: sdk-update: add option to skip preparation step
d586a11 devtool: sdk-update: fix error checking
c1b7d83 devtool: sdk-update: fix metadata update step
efead10 devtool: sdk-update: fix not using updateserver config file option
9348c91 classes/populate_sdk_ext: disable signature warnings
d44dcd7 classes/populate_sdk_ext: fix cascading from preparation failure
d11051c scripts/oe-publish-sdk: add missing call to git update-server-info
fbc2147 libbsd: upgrade to 0.8.1
221d864 bitbake: fetch/git: Change to use clearer ssh url syntax for broken servers
46d62d0 bitbake: knotty: Use non-interactive mode as fallback for dumb terminals
bfa7859 bitbake: cooker: fix findFilesMatchingInDir documentation
3d42737 bitbake: cooker: use in instead of count
0e83229 maintainers.inc: remove x11vnc
d914c7f meta-yocto: drop qt4 references
0f3ad7c scripts/yocto-layer: Avoids duplication of "meta-" prefix
220ef32 poky-lsb/poky-tiny: update preferred kernel to 4.1
b82e228 yocto-bsp: remove 3.14 and 3.19 bbappends
685daeb conf/local.conf.sample: comment out ASSUME_PROVIDED=libsdl-native
2c5e7e0 image: Really remove lockfiles flag
a500e3a boost: ensure boost to remain an empty metapackage
b151506 image_types.bbclass: Rebuild when WICVARS change
eb4159c gccmakedep: fix buildpaths qa check
f54e53c bash: fix buildpaths qa check error
6d111c8 testimage: remove VNC test, x11vnc isn't in oe-core anymore
8bec5c5 x11vnc: remove all references to moved package
8f865e2 x11vnc: move recipe to meta-oe
ae1fc96 classes/buildhistory: actually use KiB in extensible SDK sizes files
84f66b5 x11vnc: move recipe to meta-oe
c44599d readline: move inputrc into readline
f29d642 tune-*: use mcpu instead of mtune for ARM tunes
c6a1991 arch-armv7ve: add tune include for armv7ve and use it from cortexa7 and cortexa15
21d61fa cortexa{7,15,17}: add VFPv4 tunes
7f2cb68 feature-arm-vfp.inc: Further simplify with TUNE_CCARGS_MFLOAT
e9b2ffc feature-arm-{neon,vfp}.inc: refactor and fix issues
45f726c arch-armv7a.inc: add vfpv4 support also to softfp and big endiand tunes
ebe8358 arch-armv7a.inc: Fix PACKAGE_EXTRA_ARCHS for tune-armv7atb-vfpv3, tune-armv7atb-vfpv3d16, cortexa7thf-neon-vfpv4
9280a8e arch-armv5.inc: drop duplicate ARMPKGSFX_DSP and PACKAGE_EXTRA_ARCHS_tune-armv5tehf-vfp
46d6b0e arch-armv[456]*.inc: improve indentation like armv7a
860663a arm/arch-arm*, tune-cortexa*, tune-thunderx.inc, powerpac/arch-powerpc64.inc: Use normal assignment
8c483a1 arch-armv7a, tune-cortexa*: improve indentation
7498b91 arch-armv7a, tune-cortexa*: improve comment VFP -> HF
bb9b581 arch-armv7a: add missing space before ?=
15f8344 tune-cortexr4.inc: fix PACKAGE_EXTRA_ARCHS
e2736f7 sanity.bbclass: add more information to error message about TUNE_PKGARCH missing in PACKAGE_ARCHS
b68d947 mkefidisk.sh: add boot log on console
62d7c97 mkefidisk.sh: add startup script for automated boot
5aa3b93 oeqa/selftest/recipetool: update for libjpeg-turbo migration
ffa7469 libjpeg: Replace libjpeg with libjpeg-turbo
29d273f python3: fix installed-vs-shipped when 64bit + multilib
db7cee6 pulseaudio: add PACKAGECONFIG for lirc
b900ec8 sstate-sysroot-cruft.sh: Extend the whitelist
20843fa iptables: upgrade to 1.6.0
c2bda6c scripts/oe-selftest: Allow to run tests on random/all MACHINEs
8e1435e selftest: Added testcase decorators for 2 tests
32f332c oe-selftest: New option --list-tests
17d886b oe-selftest: Improved --list-classes when determining test names
4ec2da7 selftest: moved tc test_buildhistory_does_not_change_signatures
02d259c scripts/oe-selftest: Remove extra coverage data added to unittests
30c06a4 expat: CVE-2015-1283
315bdc8 packagegroup-core-x11-sato: enable pcmanfm on mips
a3e26f9 wic: rawcopy: Copy source file to build folder
d6e0da4 grub2: Fix CVE-2015-8370
bb663b0 systemd: enable compatibility libraries by default
3fea163 systemd: add more compression and importd PACKAGECONFIGs
d462b70 gcc-sanitizers: link directly against sysroot libstc++
3eb6135 openjade: Fix build if not installing libtool .la files
6308c47 valgrind: Define __UCLIBC__ for uclibc based systems
3d19a1e security_flags.inc: disable -fstack-protector-XXX for valgrind
807ed8a meta/conf/layer.conf: bump layer version due to Qt4 removal
4fb3e05 packagegroup-core-lsb: treat qt4 packages same as qt3 packages
8b11ed8 qt4: remove recipes and classes
0baadc8 toaster-manual: Updates to toaster use chapter.
908bbff ref-manual: Updated the list of supported image types.
5d27451 dev-manual: Added the --configfile bootloader option.
7b3b1f9 dev-manual: Added three new wic option descriptions.
eeffa64 dev-manual: Added the --overhead-factor wic option description.
2beb19b dev-manual: Added the --extra-space wic option description.
95851df dev-manual: Added wic --notable option description.
88a2794 dev-manual:
8bdc707 sdk-manual: Initial Manual framework
f1f7625 bsp-guide: Updated the license statement.
6686a31 dev-manual: Correction to the KVM stuff in the runqemu commands.
ccc830d documentation: Prepare for 2.1 builds
7af9314 mega-manual: Added four new figures for GUI example.
f8185ff bitbake: ast: Add filename/lineno to mapped functions
a178c5a bitbake: main: kill server without queue setup
773700d bitbake: xmplrpc: split connect method
05b4fbc bitbake: uievent: refactor retry loop
ebc169c bitbake: uievent: get rid of EventHandler attribute
4e0de6e bitbake: uievent: add error to registerEventHandler return
01419d5 bitbake: cooker: add state.get_name method
763506d bitbake: fetch2/__init__.py: Add support for 7-Zip
f5bfc1c bitbake: utils: Remove double compile from better_compile
b4141f6 bitbake: fetch2/local.py: avoid using PREMIRROR
1ad3595 bitbake: siggen: Change exception note into a warning
4ba49ac bitbake: data: Drop misleading ExpansionError exception
2c94311 bitbake: cooker: Drop useless parsing exception
a16b543 bitbake: data: Pass lineno/filename data from build_dependencies
958f0ff bitbake: codeparser: Add support for correct linenumbers
db4376e udev-extraconf: introduce multiple blacklist files for more complex setups
a8fb429 uclibc: disable parallel builds
401c632 image: Condense do_rootfs function/flags
0051510 image/rootfs-postcommands: Separate out post rootfs commands to separate class
3428edd image: Remove pointless rootfs lock
eb5bb0e packagegroup-core-boot:replace busybox to variable
cc7bb6c initramfs-framework_1.0:replace busybox for variable.
d9ffa59 core-image-minimal-initramfs: replace base-utils
9349f42 base-utils:flexible dependency for command utilities
c44b76a orc: Add missing PACKAGES_DYNAMIC
2cd061a bluez5: include the patch only for 5.36
4c35473 meta-yocto-bsp: remove 3.14 and 3.19 bbappends
6af8981 meta-yocto-bsp: Remove uvesafb (v86d) from generic x86 features
614e9ec qemu: add PACKAGECONFIG for Nettle crypto support
09705a4 oeqa/selftest: support sets in devtool comparisons
4b543f7 packagegroup-core-x11-sato: include pulseaudio-misc
23302ee devtool: use cp instead of shutil.copytree
d6e7b5b xorg-lib: allow native building without x11 DISTRO_FEATURES
4cba706 busybox: generalize recipe to work with arbitrary install directories
9d001ae cairo: update 1.14.4 -> 1.14.6
6d561fb libdrm: Upgrade to 2.4.65
0f516f0 image-vm.bbclass: uses IMAGE_LINK_NAME
c851096 image-live.bbclass: uses IMAGE_LINK_NAME
907b87d rpm: Generate per distribution and multilib macro files
c910789 package_manager.py: add debugging support for rpm scriptlet execution
8dd27ef xinput-calibrator: get screen geometry when calibrating
e8d36f4 scripts: hand the TEMPLATECONF local over to setup-builddir
0f4fb26 util-linux: Fix floating dependency upon 'readline'
2cb434a linux-firmware: package Broadcom BCM43340 firmware
f70d46f rpcbind: Fix build with libtirpc 1.0.1
866c693 libtirpc: upgrade to 1.0.1
5754b83 gstreamer1.0-libav: upgrade to version 1.6.2
6ac601f gstreamer1.0-rtsp-server: upgrade to version 1.6.2
3ac3d33 gstreamer1.0-plugins-ugly: upgrade to version 1.6.2
823b623 gstreamer1.0-plugins-bad: upgrade to version 1.6.2
6d13f30 gstreamer1.0-plugins-good: upgrade to version 1.6.2
05896a5 gstreamer1.0-plugins-base: upgrade to version 1.6.2
a8eb77b gstreamer1.0: upgrade to version 1.6.2
dd5756b mirrors: add archive.apache.org to Apache mirrors
cfbd804 guile: remove redundant replacement of .pc file
c2e8079 bind: 9.10.2-P4 -> 9.10.3-P2
7204a0f libsndfile1: enable FLAC/Ogg/Vorbis support
35bd254 buildhistory: improve support for extensible SDK
ea0abcd buildhistory: fix not recording SDK information
b6d191d scripts/oe-selftest: Add support for selftest log with timestamp
ab79287 selftest: Added MACHINE = "qemux86" to tests that use runqemu
b09080d ncurses: fixes wrong paths in BINCONFIG
8df88fb xcb: don't build-depend on python-native
d7759a5 tcmode-default: Use glibc for nativesdk version even on uclibc and musl
a7eadc3 qemu: upgrade to 2.5.0
9988ab3 webkitgtk: update to 2.10.4
cedb027 epiphany: update to 3.18.2
6e27dd8 libwebp: update to 0.4.4
efcf4b4 libsecret: update to 0.18.3
0112274 gnome-desktop3: update to 3.18.2
88a656e gcr: update to 3.18.0
883193a linux-yocto: remove 3.14 and 3.19 recipes
4487e3a kernel-yocto: fix checkout bare-cloned kernel repositories
5161944 linux-yocto/4.1: update to v4.1.15
a462d16 linux-yocto-dev: bump to 4.4-rcX
862b3b3 lttng-modules: fix build issue against kernel 4.4
9563aa8 yaffs2: fix checkpoint functionality
cefc24d mobile-broadband-provider-info: update to tagged release 20151214
04aa27c icu: fix upstream version check
2865e5f btrfs-tools: update to 4.3.1
5beb3bc iso-codes: update to 3.63
503c08d kexec-tools: update to 2.0.11
4fa2e4b lighttpd: update to 1.4.38
f7a7796 tiff: update to 4.0.6
2498065 libassuan: update to 2.4.2
f2192fa msmtp: update to 1.6.3
7fc3066 liburcu: update to 0.9.1
10d14bc trace-cmd: update to 2.6
fc774e9 python3-pip: update to 7.1.2
c3330aa pytnon-pexpect: update to 4.0.1
aa90b5d ifupdown: update to 0.8.2
4c98105 gptfdisk: update to 1.0.1
edde9af cryptodev: update to 1.8
9da9308 oe-selftest: devtool: add more explicit check for ls output
c2435b1 oe-selftest: add tests for simple devtool add / recipetool create URL case
8916731 recipetool: create: fix error when extracting source to a specified directory
fe28c25 recipetool: create: improve autotools support
498e483 devtool: sync: tweak help / messages
b272c51 devtool: reset: print message about leaving source tree behind
95a234e devtool: status: list recipe file within workspace if one exists
e116739 devtool: modify: default source tree path
110f433 devtool: add: allow specifying URL as positional argument
ceaa4bf devtool: add: figure out recipe name from recipetool
ee0d5a1 devtool: add: allow source tree to be omitted
0d8751f scripts/lib/argparse_oe: handle intermixing of optional positional arguments
1bd7793 devtool: update-recipe: use correct method to get bbappend filename
2074654 devtool: split out function for naming bbappend
6acbdc9 devtool: add: tweak help text
316b57b devtool: edit-recipe: add new subcommand
ebe5f0b recipetool: create: basic extraction of name/version from filename
db5f964 recipetool: create: support extracting name and version from build scripts
6a7661b recipetool: create: set up priority system for recipe handlers
38803e3 recipetool: create: detect when specified URL returns a web page
e78a039 recipetool: create: prevent attempting to unpack entire DL_DIR
e61645b recipetool: create: minor fix for potential issue in python handling
ae2141b recipetool: create: fix do_install handling for makefile-only software
c2f1742 recipetool: create: avoid traceback on fetch error
470f20b recipetool: create: handle https://....git URLs
8e0a84c scripts: print usage in argparse-using scripts when a command-line error occurs
548d433 directfb.inc: enable bfd linker workaround for all arm targets
2381f4a devtool: sdk-update: fix traceback without update server set
7540550 classes/populate_sdk_ext: error out of install if buildtools install fails
ecce3d3 classes/populate_sdk_ext: hide build configuration in devtool build* output
fd84d0f classes/base: don't print header if BUILDCFG_HEADER not set
a4f496a classes/populate_sdk_ext: use uninative to set NATIVELSBSTRING
a6f8a3f toaster.bbclass: fix TypeError when parsing build stats
937b7fd libxcb: Add a workaround for gcc5 bug on mips
86c8b8b flex: update to 2.6.0
dad130b opkg: upgrade to v0.3.1
d2b770c systemd: remove merge conflicts accidently left in
ca69643 wic/help.py: document that mountpoint is optional for part command
5628dde pixman: check neon support via TUNE_FEATURES, not the _armv7a over-ride
9a74388 xdg-utils: Do not build the in-script documentation
520b37d gettext: Upgrade 0.19.4 -> 0.19.6
cae0e0f gcc-configure-common.inc: add gcc-runtime ABI fixes for armv7m and armv7r
cba8fb3 tune-cortexr4.inc: provide an _armv7r over-ride via MACHINEOVERRIDES
fd10723 tune-cortexm3.inc: provide an _armv7m over-ride via MACHINEOVERRIDES
b6fe440 feature-arm-thumb.inc: drop 'no-thumb-interwork' tuning feature
1d5a4cf feature-arm-thumb.inc: drop legacy _thumb and _thumb-interwork over-rides
ca64c16 feature-arm-thumb.inc: drop ARM -vs- thumb comments
95a79a5 rpm: Fix support for db5 and db6
75cec07 oe-buildenv-internal: fix return code
606c9e7 staging.bbclass: make already-stripped can be skipped
647e0e4 buildhistory-collect-srcrevs: hide empty sections
d4b5a1f selftest/buildhistory.py: Test buildhistory does not change sigs
4b83f1f gcc5: Upgrade gcc-5.2 -> gcc-5.3
0381b78 bitbake: event/utils/methodpool: Add a cache of compiled code objects
c61c1eb bitbake: BBHandler: Improve IN_PYTHON_EOF handling
2a94194 bitbake.conf: Add filename and lineno to BB_SIGNATURE_EXCLUDE_FLAGS
5f40691 bitbake: toaster: remove 2 confusing parameters
3960b6e bitbake: toaster: move setting of default values
b194c0c bitbake: toaster: move startup checks to a better place
064d2c7 bitbake: toaster: remove 2 unused functions
c505f24 bitbake: toaster: remove addtoConfiguration function
c7e4404 bitbake: toaster: updated header of the toaster script
af34920 bitbake: toaster: add MANAGE variable
563b786 bitbake: toaster: remove unused variable
aa3cc12 bitbake: toaster: split long lines, add/remove whitespace
8e4acac bitbake: toaster: check if address:port is in use
847b935 bitbake: toaster: implement checksocket command
9f3681d buildstats-summary/toaster: Cope with removal of get_bn()
522dcaa bitbake: knotty: Improve exception error message
01d67bf bitbake: knotty: Fix row/column function return value issue
6c12efa bitbake: buildinfohelper: Update for buildstats layout change
28ea1a1 bitbake: fetch: use orig localpath when calling orig method
5cb6d83 bitbake: utils: Improve traceback from better_exec internal errors
0019edc bitbake: ast/event/utils: Improve tracebacks to include file and line numbers more correctly
b14ccb2 bitbake: runqueue: Add support for <task>- syntax
5069ab6 m4: Drop unused/unreferenced patch
d7e766b toaster: Update for buildstats changes
adfdca4 buildstats: Improve to add getrusage data and corrected IO stats
3187647 buildstats: Separate out the build and task data to allow improvements
38a2553 buildstats: Clean up e.data and bb.data references
7b1e48f buildstats: Drop get_bn/set_pn and just use BUILDNAME
7837162 buildstats: Drop disk data from buildstats
030c033 nativesdk-buildtools-perl-dummy: Bump PR
e6f2761 combo-layer: Stop using filterdiff
f1f3716 meta: more removals of redunant FILES_${PN}-dbg
5fb8fea clutter-gst-3.0: add dependency on libgudev
54f01ca systemd: Upgrade to 228
63bdadc uclibc: Switch to using uclibc-ng
0b5cddd cdrtools-native: update to 3.01 final
c4dfb92 grep: update to 2.22
d8608bc procps: update to 3.3.11
52f6a01 babeltrace: update to 1.3.1
0c705d6 powertop: update to 2.8
516d8c9 nfs-utils: update to 1.3.3
9c39a4f systemtap: update to 2.9
fef0ec6 kbd: update to 2.0.3
8668e17 gmp: update to 6.1.0
86e02d0 docbook-xsl-stylesheets: fix UPSTREAM_CHECK_REGEX
f065766 mtd-utils: update to 1.5.2
5d32aeb unfs3: update to r497
4e653b5 python-numpy: update to 1.10.1
90b7212 libxml-simple-perl: update to 2.22
689db13 dmidecode: update to 3.0
d301451 cpio: update to 2.12
2bea006 puzzles: update to current commit
2d04c83 gnutls: update to 3.4.7
cf1eb2b libidn: add native and nativesdk support
dd58b3b libpng: Update SRC_URI to use GENTOO_MIRROR
b763668 libpng12: Upgrade 1.2.54 -> 1.2.55
91c92fc libical: Upgrade 1.0.0 -> 1.0.1
5c6ff26 libxslt: use proper SRC_URI
a444eb5 kexec-tools: added the script kdump
be9f7f9 ltp: Upgrade 20150420 -> 20150903
81f1e41 musl: Update to latest 1.1.12 release
c529e66 util-linux: Upgrade to 2.27.1
bdbc5ee packagegroup-core-sdk: Disable sanitizers for uclibc
692853d libsolv: add new recipe
8bba7de curl: upgrade to 7.45
2e3a172 libsndfile1: 1.0.25 -> 1.0.26
df18352 wget: Upgrade 1.16.3 -> 1.17
81eb101 unifdef: upgrade to 2.11
19c76ad sstate-sysroot-cruft: Add php, python, lua, fontcache generated files to whitelist
f80f8ba oeqa/selftest: Added testcase decorators for 2 testcases
a5dd1dd uninative.bbclass: Choose the correct loader based on BUILD_ARCH
388e580 license: Fix BB_TASKDEPDATA references
f19e8de coreutils/procps: Revert priority change since coreutils > busybox
455ff32 meta: more removals of redunant FILES_${PN}-dbg
e0890b6 meta: Drop now pointless manual -dbg packaging
b7766e4 package: Add auto package splitting of .debug files
89f13c7 meta/conf/toasterconf.json: remove SDKMACHINE variable as it no longer used
03d715e bitbake: toaster: tables Set a default order for the software recipes table
4ff0d60 bitbake: toaster: rework checking of Django version
4a78416 bitbake: toaster: monkey patch Queryset
c1c8eff bitbake: toaster: removed extra calls of migrate
507aafb bitbake: toaster: work around 'database is locked' error
322b470 bitbake: toaster: fixed format strings
84daa40 bitbake: toaster: use OneToOneField instead of ForeignKey
c464f34 bitbake: toaster: Amend regex for MySQL database URLs
f001a4a bitbake: toaster: Remove compatible_layerversions() method
0adffdf bitbake: toaster: Check Django version against toaster-requirements.txt
8d058cf bitbake: toaster: Update deprecated manage.py command
717c636 bitbake: toaster: Prevent deprecation warnings for RedirectView
0f602c1 bitbake: toaster: Update API used to make runbuilds methods run in transactions
93f5738 bitbake: toaster: rename get_query_set -> get_queryset
23c4806 bitbake: toaster: Start Django machinery for database access
7a0c45e bitbake: toaster: Create default project with get_or_create* method
9de8dfa bitbake: toaster: Fix references to app paths
535fc9b bitbake: toaster: Remove South migrations
8ca4664 bitbake: toaster: Upgrade to Django 1.8.6 and remove South
b322dec bitbake: toasterui: process SetBRBE event
0274b68 bitbake: toaster: trigger SetBRBE event
fdb8e74 bitbake: toaster: implement BitbakeController.triggerEvent
5de3800 bitbake: event: Fix subprocess event error traceback failures
0da1d71 nopackages: Add class for recipes which don't generate packages
5003d14 sstate: Ensure populate_lic dependencies are not followed
48aad51 populate_sdk_ext/sign_rpm/sign_package_feed: Add missing getVar parameter
98dcdcb autoconf: Disable macro which causes excessive delays when using dash as sh
28fa304 automake: Remove delays in configure scripts using automake
f5e681d site/common-linux: Add some macros to avoid sleeps during configure
93adf46 meta-yocto/conf/toasterconf.json: remove SDKMACHINE variable as it no longer used
b3d6872 lttng-tools: Revert wrong enforcement of Python 3.0 use
2c11bdd attr: Add patch to account for use of internal glibc header
f1c034b libpam: Fix build with musl
33bab59 openssl: Add musl configuration support
c4207ee busybox: Add config for musl
083d9d1 gettext: Delete libintl.h and charset.alias
3a0797f sysvinit: Fix build with musl
fd21402 musl: Add recipe
781d34f mtools: Use proper glibc override to add glibc packages to recommendations
1b90d67 squashfs-tools: Define FNM_EXTMATCH if not defined
36a709a mtd-utils: Backport and create patches to support musl
41fd73f gdb: Fix build with musl
1ee97d8 autoconf: Add musl support
a2ea58b gcc: Add support for building musl configuration
37c74e2 gstreamer1.0: Split bash completion information into separate package
fc32a3b attr: add attr dependency to attr-ptest
9205f0a valgrind: import Debian link_tool patch for MIPS
c27bbb4 slang: update upstream URI to (official) jedsoft.org
21e35df subversion: update to 1.9.2
39260c3 json-c: add manual upstream version check
4ff0017 mirrors: replace references to archive.apache.org
1672a18 mobile-broadband-provider-info: update to current commit
b699b15 nspr: update to 4.11
dec8d20 python-setuptools: update to 18.7.1
b3535e2 openssl: update to 1.0.2e
fce2ee7 dropbear.inc: drop legacy CFLAGS and LD tweaks
f87063b dropbear: update 2015.70 -> 2015.71
a520495 texinfo: don't create dependency on INHERIT variable
2b2774b sudo: upgrade to 1.8.15
5eb0e90 linux-firmware: update to latest revision bbe4917
c147782 bluez5: upgrade to 5.36
64c3a09 sudo: remove libdir INSANE_SKIP
b407a80 libsdl: expand PACKAGECONFIG and enable native builds
39facf9 buildtools-tarball.bb: 32bit tools need pseudo 32bit library
bc26a7d rpm: fix file conflicts for MIPS64 N32
01c0285 rpm: Enable MIPS64 N32 transactions
a742586 bash: fix testcase run-coproc/run-execscript/run-test/run-heredoc failed
a6bb872 cpio: fix test case of symlink-bad-length
787d82b linux-libc-headers: update default KORG_ARCHIVE_COMPRESSION bz2 -> xz
94c0332 linux-libc-headers.inc: remove '-e MAKEFLAGS=' from EXTRA_OEMAKE
c7ad779 gcc-4.9: import patch fixing compilation in thumb mode
1260ded gcc-5.2: import patch fixing compilation in thumb mode
b4db53a dropbear: Upgrade 2015.68 -> 2015.70
e0162c1 gcc-cross-initial: make dependency on gnu-config-native and autoconf-native explicit
fccb128 weston-init: add a native systemd unit file
a1fa8d9 python: Fix cross compiling issue
c9fdc1b icu: Upgrade 55.1 -> 56.1
95909bc kernel.bbclass: drop unnecessary 'eval' from kernel_do_configure()
ec79a19 insane: in libdir test allow libraries in libexecdir
9c0186f rootfs.py: Change logic to unistall packages
23083e7 oeqa/systemd: get runtest target boot time and log
c6330a2 oeqa/systemd: journalctl helper function
220a78b scripts: oe-selftest Added new features.
98d2485 oe-buildenv-internal: preserve existing BB_ENV_EXTRAWHITE
9cab798 toolchain-shar-extract.sh: fix ~ not working in path
f27401d nativesdk-buildtools-perl-dummy: properly set PACKAGE_ARCH
5e3e2e0 poky.conf: Bump for 2.1 development
7e8ff7b bitbake: toaster: toasterui Add ParseStarted/ParseProgress events to mask
f823601 build-appliance-image: Update to master head revision
992e577 linux-yocto: Update genericx86* BSPs to v4.1.13
b4f6950 cmake: Add nios2 support
27b9f04 boost: adjust hard-coded path after python3 upgrade
639cadd sdk.py / OpkgSdk: remove_packaging_data() after install
fd4894f devtool: extract: update SRCTREECOVEREDTASKS for kernel
34f1d81 devtool: extract: copy kernel config to srctree
6650357 lib/oe/package_manager: Introducing PACKAGE_FEED_BASE_PATHS/PACKAGE_FEED_ARCHS
d7baeb5 selftest/wic.py: Add test for custom bootloader config
8612f26 directdisk-bootloader-config.wks: Add example for custom bootloader config
c59dc3b wic/help.py: Document the new option "configfile"
7033873 wic: Allow to use a custom config for bootloaders
f95f729 wic/utils/misc.py: Added function to search for files in canned-wks
9773faa wic: Prepare wicboot to allow custom bootloader config
4515186 package_ipk: allow to specify OPKG_ARGS in local.conf
7cf7156 systemd.bbclass: Allow enabling of parameterised services
551cda0 base: check for existing prefix when expanding names in PACKAGECONFIG
c093fd8 linux-yocto/4.1: Fix kernel oops on qemuarm boot
cda3905 toolchain-shar-extract.sh: ensure cleaned environment will work for ext SDK
f9384b0 bitbake: knotty: Enforce terminal line limit to stop crazy scrolling
7a775a1 initramfs-framework: create directory /var/run
2861399 libpcre: drop UPSTREAM_CHECK_ variables
35c28e3 libpcre: upgrade to 8.38
d50ef65 libpng: update 1.6.19 -> 1.6.20 (CVE-2015-8126)
2b736f2 ghostscript: add dependency for pnglibconf.h
976f0e3 package_regex.inc: split the rest of the entries to their recipes
74bfa62 package_regex.inc: split entries which blacklist specific versions to their recipes
75c6929 package_regex.inc: split sourceforge related entries to their own recipes
cefeac2 package_regex.inc: split PyPi related entries to their own recipes
aa5df2a package_regex.inc: split Debian-related entries into their own recipes
12ba5cc package_regex.inc: split GITTAGREGEX entries into recipe files
642e92f package_regex.inc: split entries with odd-even versioning into their own recipes
96eac69 package_regex.inc: deprecate the file
b0bbea5 gstreamer: really fix the helper install race
b822216 neard: fix libdir/libexecdir confusion
cbfccc6 glibc: fix libdir/libexecdir path confusion
d0577f9 sudo: handle libexecdir != libdir/PN.
6f837cc util-linux: Add ptest
dbd02bd libav: Correctly handle prefix=""
fda9859 libav: Add PACKAGECONFIG options: avdevice, avfilter, avplay, gpl
7ba85f1 libav: Remove deprecated --disable-avserver
2739ed0 busybox: backport upstream fixes for unzip
6decbbb qt4-4.8.7: fix build for mips n32
f1e8938 gstreamer1.0: Convert tests and valgrind config opts to PACKAGECONFIGs
11b9524 cracklib: fix for base_libdir == libdir
d9f73ca libbsd: Upgrade to 0.8.0
10d6dc4 libcroco: Upgrade 0.6.8 -> 0.6.9
79b823a shared-mime-info: Upgrade 1.4 -> 1.5
f6ec8a4 xdg-utils: Upgrade to 1.1.1
a3f63f9 gsettings-desktop-schemas: Upgrade 2.16.1 -> 3.18.1
754f6b6 gnome-common: Upgrade 3.14.0 -> 3.18.0
75aba18 clutter-gtk-1.0: Upgrade 1.6.2 -> 1.6.6
c6a6212 clutter-gst-3.0: Upgrade 3.0.8 -> 3.0.14
2da6cd5 clutter-1.0: Upgrade 1.24.2
148c953 cogl-1.0: Upgrade 1.20.0 -> 1.22.0
f54d4e4 ghostscript: Add NIOS2 support
21ba42b harfbuzz: update 1.1.0 -> 1.1.2
058b91e xvideo-tests: move to the latest release
70d459c scripts/oe-pkgdata-util: sort the packages in list-pkg-files
80e3919 wic: insert local Python paths at front
9d788d7 toolchain-scripts.bbclass: unset command_not_found_handle
82ab99f waf.bbclass: remove unused parameter from get_waf_parallel_make()
68d3dfe toolchain-shar-extract.sh: proper fix for additional env setup scripts
0c5d239 base: Improve handling of switching virtual/x providers
3745479 bitbake: bitbake: rename REGEX, REGEX_URI, and GITTAGREGEX.
dd282d4 bitbake: toaster: return back 'New project' button
2a8e970 bitbake: toaster: tests Update UI tests to work with 2.0 changes
fe8a0a3 bitbake: toaster: tests Automated build-mode backend tests
0497b57 bitbake: toaster: unset environment variables
8b7a548 bitbake: toaster: get rid of complicated heuristics
556b8b6 bitbake: toaster: remove SDKMACHINE from project variables
4186f5b bitbake: toaster: stop using toaster-pre.conf
361faa3 bitbake: toaster: remove writeConfFile API
fcbba5a bitbake: toaster: set varibales on bitbake server
993bc7e bitbake: toaster: implement BitbakeController.getVariable
53e981e bitbake: toaster: buildinfohelper Broaden the toaster created recipe data case
57e5f24 bitbake: toaster: do not create duplicate HelpText objects
4c1e5ec bitbake: toaster: remove usage of BUILD_MODE variable
9902895 bitbake: toaster: do not terminate bb server
58765a8 bitbake: toaster: remove stopBBServer API
95a3cf7 bitbake: toaster: reimplemented startBBServer method
76d53b5 bitbake: toaster: remove _setupBE function
87b2f95 bitbake: toaster: implement 'toaster restart-bitbake'
891484a bitbake: toaster: implement start_bitbake function
bf25471 bitbake: toaster: implement stop_bitbake function
7c2b225 bitbake: toaster: update brbe and project attributes
de812d0 bitbake: toaster: start 'manage.py runbuilds' in the script
28e8ccf bitbake: toaster: make runbuilds to loop
a3871a3 bitbake: toaster: use parent of the build dir
2a96d35 bitbake: toaster: check for toaster configuration later
d87a534 bitbake: toaster: remove unused variable
dc6a489 bitbake: toaster: change toasterconf.json logic to use TEMPLATECONF, like oe-setup-builddir
5a42c2d bitbake: toaster: run bitbake the same way
cac91db bitbake: toaster: set DATABASE_URL in toaster script
a464bf2 bitbake: toaster: implement get-dburl command
e473151 bitbake: toaster: don't allow to run toaster as a script
4de214f bitbake: lib/bb/utils: improve edit_bblayers_conf() handling of bblayers.conf formatting
0debb11 bitbake: lib/bb/utils: fix error in edit_metadata() when deleting first line
9d19dd9 bitbake: wget.py: parse only <a> tags
71ede7b bitbake: toaster: toastergui tests Add generic test for ToasterTables widget
34b22cf bitbake: toaster: tables Fix invalid field name on NewCustomImagesTable
1c59846 bitbake: toaster: tables Add default_orderby field where it was missing or unset
d82c541 bitbake: toaster: CustomImageRecipe add search_allowed_fields to this model
bdf6241 bitbake: toaster: machines table Fix missing layers information needed for filter
b90a8dc bitbake: toaster: tablejs Make sure click handlers consume click event
c075bcf bitbake: toaster: projectpage Make sure build targets are space separated
698c74c libsdl: remove redundant configure_tweak patch
35945fd iw: upgrade to version 4.3
15969ae gstreamer1.0-plugins-good: fix PACKAGECONFIG for gudev and add one for v4l2 and libv4l2
e601b38 gstreamer1.0-plugins-bad: fix dependencies for uvch264 PACKAGECONFIG
ddf2501 gudev: Add from meta-oe
e406fa8 lsb: fix installed-vs-shipped for mips
39ecdce rpm: fix for N32 MIPS64
09b4da6 glibc/0029-fix-getmnt-empty-lines.patch: fix getmntent()
1781a9a init-install-efi: fix script for eMMC installation
f808747 init-install-efi: fix script for gummiboot loader
2a55036 linux-firmware: rtl8192cx: Add latest available firmware
b60af3b libsdl2: add missing dependency on libxkbcommon for PACKAGECONFIG[wayland]
ed31874 libxml2: upgrade to 2.9.3
ecb1c71 libxml2: merge pointless bb/inc split
19a626d openssh: redesign ssh-agent.sh regression test case
81b59e7 gcr: Require x11 DISTRO_FEATURE
934e486 psplash: update to latest git version
ccb2a57 sysvinit-inittab: Add wrapper script to verify console exists
b7f610d linux-yocto/4.1: Bluetooth:Fix the connection fail of 6lowpan over BT LE
d08e761 linux-yocto-rt/4.1: update to -rt15
6aa464c linux-yocto/4.1: fsl-mpc8315e-rdb: Enable EEPROM
bd29006 linux-yocto/4.1: update to v4.1.13
5561407 uClibc: enable utmp for shadow compatibility
533fc01 glibc: Backported a patch to fix glibc's bug(18589)
598e372 ncurses: update SRC_URI
51b64ee openssl: enable parallel make
88e45cd busybox: enable resize applet
87de4a1 busybox: disable support for mounting NFS file systems on Linux < 2.6.23
73cc839 busybox: update 1.23.2 -> 1.24.1
f8ac408 busybox: re-order defconfig to align with busybox 1.24.1
3648a37 busybox.inc: remove '-e MAKEFLAGS=' from EXTRA_OEMAKE
bf28ea9 busybox.inc: set CC=${CC} via make command line
f21dce1 busybox.inc: fix CONFIG_EXTRA_CFLAGS configmangle
6167669 busybox.inc: don't set .config CROSS_COMPILER_PREFIX
e1ecccd busybox: move EXTRA_OEMAKE etc into busybox.inc
0e63300 busybox.inc: don't export EXTRA_OEMAKE
3735776 busybox_git: Enable getopt applet
b1774f4 harfbuzz: update 1.0.6 -> 1.1.0
31f803a sqlite3: update 3.9.0 -> 3.9.2
7e3474c readline: apply missing upstream patches
99b9d52 readline: prepare for readline6.3 upstream patches
e0b6d0c dbus: merge .bb and .inc
d99958a pulseaudio: Fix HDMI profile selection
2ba954f initscripts: hide the error in case system is not writeable
4ed84ff nativesdk-buildtools-perl-dummy: fix rebuilding when SDKMACHINE changes
b8fdd09 xf86-video-vmware: Add vmwgfx PACKAGECONFIG option
dfd5c4d pkgconfig: merge .bb and .inc
61c6887 pkgconfig: upgrade to version 0.29
744e89f ofono: upgrade to version 1.17
996f843 libxml2: remove legacy LDFLAGS += "-ldl" workaround
dedabc1 apr: fix LTFLAGS to make it work with ccache
9470956 iproute2: install bridge tool by default
1b8f6a2 lttng-tools: add libgcc to RDEPENDS
22dd6e7 lttng-tools: Upgrade to 2.7 release
ef73f21 lttng-tools: Drop unused patch
c375976 lttng-ust: Upgrade to 2.7 release
f5c1b57 lttng-modules: Upgrade to 2.7 release
8d708a5 libunistring: upgrade to version 0.9.6
f840e59 libtasn1: upgrade to 4.7
012ca02 wpa-supplicant: upgrade to 2.5
872e153 mesa: Make gl libraries RRECOMMEND mesa-megadriver
a62fa23 directfb.inc: force bfd linker for armv7a
9b075ca libpng12: update to 1.2.54
6d1eb34 libpng: update to 1.6.19
92a881f orc: update to 0.4.24
2f479b1 libpcap: update to 1.7.4
bd4058f apr-util: add missing RDEPENDS for ptest
1408642 iproute2: update to 4.3.0
e677c25 ruby-native: Depend on openssl-native
9e37812 db: fix race issue for libdb-6.0.la
c19036a pango: use ptest-gnome
43b29d9 gst-plugins-bad: improve FILES variables
9fc877f gstreamer1.0-plugins-base: add PACKAGECONFIG for libvisual
7a2bb0d python3: fix building nativesdk-python3
2268a70 python3: Upgrade from 3.4.3 to 3.5
ed8d1be python-git: Add missing dependency
dee2a8c guile, mailx, gcc, opensp, gstreamer1.0-libav, libunwind: disable thumb where it fails for qemuarm
c0b822f icu: force arm mode
f42ef3f rpcbind: Security Advisory - rpcbind - CVE-2015-7236
04034e7 subversion: fix CVE-2015-3187
f91aedf subversion: fix CVE-2015-3184
40cd228 oeqa/sshcontrol: don't source profile
d39192a oeqa/runtime/multilib: refactor ELF class extraction
cc34104 oe-selftest: Enable code coverage on unit tests
06859de meta/conf/machine: use ' inside quoted values
6be94ec runqemu-internal: Replace wacom-tablet with tablet for usbdevice
0cc3810 recipetool: make plugin registration function name consistent with devtool
b381f80 recipetool: add setvar subcommand
1fbd760 lib/oe/recipeutils: refactor patch_recipe_file() to use edit_metadata()
0b850cb devtool: clarify help text
5001f23 devtool: build: enable showing default task in help
f79022d devtool: build: use bbappend to set PARALLEL_MAKE
21481bc lib/oe/recipeutils: check in validate_pn() for names instead of filenames
671f41e devtool: ensure we change back to the original dir on error
74505b4 devtool: search: print SUMMARY value
3f46af2 devtool: drop unused plugin_init() functions
176211a devtool: package: use DEPLOY_DIR_<pkgtype> to get deploy directory
0fe7426 devtool: disable creating workspace for extract and search subcommands
a360fa7 lib/oe/patch: improve extraction of patch header
f79cc4d devtool: upgrade: provide a means to update the source branch
b4d4d21 devtool: upgrade: fetch remote repository before checking out new revision
9b7d45c devtool: upgrade: remove erroneous error when not renaming recipe
9a70444 devtool: upgrade: fix updating PV and SRCREV
6a52c73 devtool: upgrade: fix removing other recipes from workspace on reset
44ef78a devtool: include do_patch in SRCTREECOVEREDTASKS
804f5b8 image.py: avoid mkdir race when building multiple images
312862f package_manager.py: define info_dir and status_file when OPKGLIBDIR isn't the default
b00f734 image.py: Avoid creating empty .env file in _write_wic_env
a88505b lib/oe/terminal: use C locale when determining version
8d784ba toolchain-shar-extract.sh: Ensure it's ran in clean environment
7f3c20f toolchain-shar-extract.sh: do not allow $ in paths for ext SDK
2d21e5d create-pull-request: handle empty ODIR
c63b36f scripts/gen-lockedsig-cache: improve output
67af6d6 wic: exec_native_cmd: implement support for pseudo
8ffba25 toolchain-shar-relocate: don't assume last state of env_setup_script is good
b8ee7ae sanity: don't enforce DISPLAY for testimage
b364183 oeqa/qemurunner: pass nographic to runqemu if DISPLAY isn't set
46755cc base: add automatic dependency on lzip-native for .lz SRC_URI
6ea39c2 base: decode SRC_URI before adding implicit fetch dependencies
eded9c2 buildhistory.bbclass: support extending the content of the build history
d95df11 license.bbclass: Create image license manifest
efdab52 license.bbclass: Add function get_deployed_files
cc0d044 license.bbclass: Added function get_deployed_dependencies
d45e10e license.bbclass: Added get_boot_dependencies function
8b1e7bc license.bbclass: Split license create manifest
1a210e6 license.bbclass: Write recipeinfo file in license folder
74c7cd5 populate_sdk_ext.bbclass: Be more permissive on the name of the buildtools
5ba6382 populate_sdk_base: Add sysroot symlink check
7fed655 classes/populate_sdk_ext: fail if SDK_ARCH != BUILD_ARCH
2948169 classes/populate_sdk_ext: tweak reporting of workspace exclusion
28a2ea7 classes/populate_sdk_ext: make it clear when SDK installation has failed
124c6aa classes/populate_sdk_ext: tidy up preparation log file writing
d348624 boot-directdisk.bbclass: remove HDDIMG before create
03f15e5 sstate: Ensure siginfo and sig files are also touched
615ccae weston: Add PACKAGECONFIG option for colord CMS
cdad67c opkg: add cache filename length fixes
2ec77de openjade-native: statically link local libs
29747d4 sysklogd: inhibit updatercd for non-sysvinit
add3451 connman: depend on readline
7a557a2 latencytop: obey LDFLAGS
8aeec87 tcf-agent: obey LDFLAGS
9025d2e blkspace: fix ldflags for iowatcher
1732a8a bluez5: enable sysvinit support
160fdd8 sysprof: use packageconfig for the gui
425d020 mc: upgrade to 4.8.15
7386647 packagegroup-core-directfb: Don't depend on pango-modules
ac5ed8e xkeyboard-config: Upgrade 2.15 -> 2.16
3a71fab xkbcomp: Upgrade 1.3.0 -> 1.3.1
b7cb308 xinput: Upgrade 1.6.1 -> 1.6.2
05eca73 xf86-video-omap: Upgrade 0.4.3 -> 0.4.4
cfcc5e5 xf86-input-synaptics: Upgrade 1.8.2 -> 1.8.3
4c9256f xf86-input-evdev: Upgrade 2.9.2 -> 2.10.0
96ddcc5 xorg-driver-input: add xorg configuration to FILES
a1003f5 xserver-xorg: Upgrade 1.17.2 -> 1.18.0
a336b8a libxcb: Remove unused git-version of the recipe
05ba0db libxcb: Upgrade 1.11 -> 1.11.1
44233d3 pixman: Upgrade 0.32.6 -> 0.32.8
7ab0466 libxi: Upgrade 1.7.4 -> 1.7.5
63feef0 gtk-icon-utils-native: Upgrade 3.16.6 -> 3.18.2
38924d9 package_regex.inc: Add gtk-icon-utils-native
060b482 gtk+3: Upgrade 3.16.6 -> 3.18.2
4f3d2b3 adwaita-icon-theme: Upgrade 3.16.2.1 -> 3.18.0
c8849ac librsvg: Upgrade 2.40.10 -> 2.40.11
81769ca pango: add RPROVIDES for removed packages
c9b06f5 pango: Upgrade 1.36.8 -> 1.38.1
ced8d49 gdk-pixbuf: Upgrade 2.30.8 -> 2.32.1
918c773 libsoup-2.4: Upgrade 2.50.0 -> 2.52.1
5bd9305 at-spi2-atk: Upgrade 2.16.0 -> 2.18.1
8eb0c8f atk-spi2-core: Upgrade 2.16.0 -> 2.18.1
78130eb atk: Upgrade 2.16.0 -> 2.18.0
e7141ab glib-networking: Upgrade 2.44.0 -> 2.46.1
fcd7494 glib-2.0: build dependency cleanup
5357764 glib-2.0: Enable more tests while cross-compiling
1e271af glib-2.0: Upgrade 2.44.1 -> 2.46.1
bc1be07 qemu: Backport malloc-trace disabling
bca5a7a logrotate: do not move binary logrotate to /usr/bin
0069c0d systemd: drop unneeded $D check in prerm
cd1f2b4 systemd: chown hwdb.bin to root:root for do_rootfs
7ca8cd9 systemd: for valgrind, define VALGRIND=1
46fa8ab systemd: make coredump a PACKAGECONFIG
ac34784 systemd: add machine-id to conffiles
04937cc systemd: ignore .so filenames in systemd-doc
6821854 systemd: fix Upstream-Status tag
82107b1 mdadm: fix CFLAGS and ptest issues
d8adfd2 gcc-4.9: Fix various _FOR_BUILD and related variables
8ae27fa devtool: add sync command
6bfa1dc boost.inc: remove unused parameter from get_boost_parallel_make()
16d7bfd wireless-tools: remove unused files
ee923bf gstreamer1.0: fix install race
0ae52c8 gcc-multilib-config: make aarch64 support multilib
8514d21 libxml2: fix CVE-2015-7942 and CVE-2015-8035
e864f71 terminal: Open a new window instead of split on older tmux versions (<1.9)
5056581 flex: fix test-bison-yylval and test-bison-yylloc failed
c54540e gdbm 1.8.3: install libgdbm_compat
b9f87ed harfbuzz: update to 1.0.6
3f75537 ethtool: bump version to 4.2
9a4da3c openssl: fix ptest issues
9163a5d base-files: stage /etc/skel
d60c5ff mktemp: raise the priority to avoid conflicting with coreutils
b06eacd libunwind: fix build for qemuarm
c4acace gma500_gfx: Avoid inserting gma500_gfx module for certain devices
6c3f680 libsndfile: fix CVE-2014-9756
aa07eb1 python-pycurl: update version to 7.19.5.2
696aa7e rt-tests: upgrade to version 0.96
6ec7dc2 rpcbind: don't use '-w' for starting rpcbind
eddd88f libsecret: add dependency on intltool-native
2e8efb1 openssl: use subdir= instead of moving files in do_configure_prepend()
036d2dc openssl: sanity check that the bignum module is present
cf366d8 libsdl2: require GLES when building Wayland support
4b38be6 meta: add some missing Upstream-Status tags to patches
42c75cd weston: delete unused patch
521fac6 glibc: fix Upstream-Status tag
44a7bbc linux-firmware: package Broadcom BCM4339 firmware
f9d51cd libusb1: fix make install race
cb01f6d libusb1: upgrade from 1.0.19 to 1.0.20
b4e6f63 perl: fix spaces in brackets while using CC version
a59d019 u-boot: Update to 2015.10 release
e67c5b0 bitbake-prserv-tool: check file name
4e2c5e1 recipetool.append: don't choke on a trailing ; in a url
a35f79d yocto-bsp: Set SRCREV meta/machine revisions to AUTOREV
9d585b5 yocto-bsp: Set KTYPE to user selected base branch
1542c2a yocto-bsp: Typo on the file extension
f674ffa yocto-bsp: Avoid duplication of user patches ({{=machine}}-user-patches.scc)
49a465c package_manager.py: Delete installed_pkgs.txt file
ace895d rootfs.py: Stop using installed_pkgs.txt
ccb1616 lib/oe/distro_check: don't set empty proxy keys
8137a84 lib/oe/copy_buildsystem: Don't expand BB_TASKDEPDATA
a6c68d8 oeqa/selftest/sstatetests: prettier output for allarch test
92328b4 oeqa/selftest/signing: Added new test for signing sstate.
fbb03a8 oeqa/selftest/signing: New test for Signing packages in the package feeds.
13a4c38 qemu.bbclass: fix vardeps of QEMU_OPTIONS
51bd011 qemu.bbclass: correct the fsl ppc QEMU_EXTRAOPTIONS
753f31e autotools: Allow recipe-individual configure scripts
e281791 allarch: Force TARGET_*FLAGS variable values
e28e17e distro/maintainers.inc: include stress package details
76d2e46 image_types: improve wks path specification
70ae7a6 insane.bbclass: Avoid libdir QA check if PACKAGE_DEBUG_SPLIT_STYLE='debug-file-directory'
cf0dfdb classes/cpan-base: fix libdir for nativesdk
a205c4c bbclass: fix spelling mistakes
cf218e5 rootfs_*.bbclass: don't add BUILDNAME to do_rootfs vardepsexclude
7d8616c insane: Don't depend on BB_TASKDEPDATA
a9cc27e kernel: fix race condition between compile_kernelmodules and shared_workdir
fecb077 classes: Ensure pass setVar/setVarFlag strings, not integers
9167f20 classes/license: fix intermittent license collection warning
43c8867 classes/metadata_scm: fix git errors showing up on non-git repositories
59b27d5 sstate: respect GPG_BIN and GPG_HOME
4415dc5 archiver.bbclass: add bbappend when do_ar_recipe kernel and gcc packages
2f0ff3a archiver.bbclass: fix previous issue regarding work-shared for linux-yocto
0cc4eef waf.bbclass: filter out non -j from PARALLEL_MAKE
95719b0 ptest-gnome: extend EXTRA_OECONF in all builds, not just target
1b25a70 yocto-project-qs, ref-manual, poky.ent: CentOS Package updates
2e649d7 dev-manual: Updated runqemu command options list
bd62289 toaster-manual: Removed SDKMACHINE from the json file example.
c674cd7 ref-manual: Updated list of supported distros.
33d8cff ref-manual: Updated the GCC 5 migration section for 2.0
d9aabf9 gcc: Drop 4.8
2cb1aee layer.conf: Correct gcc-cross dependency
88f9310 bitbake: toaster: builds pages Fix the download cooker log link
d04af8b bitbake: toaster: project pages Link to image recipes table in notifications
70465c7 bitbake: toaster: tests: Re-write some cases to make them more maintainable
536b73f bitbake: data_smart: Only support lowercase OVERRIDES
fb01a66 bitbake: fetch2: Remove crazy code in unpack
7db88aa bitbake: parse: Don't try to expand __base_depends/__depends
4c04ce0 bitbake: cache: Don't try to expand __inherit_data
9d8e36a bitbake: toaster: localhostbectrl Pass DATABASE_URL in via the process environment
4677d8b bitbake: toaster: Remove the new-build-input button widget
55f4494 bitbake: toaster: projecttopbar Use the project in context to get num builds
e9d4962 bitbake: toaster: projectpage Disable/Enable build input if we have 0 layers
5fa4c73 bitbake: toaster: orm Fix get_number_of_builds to count all apart from IN_PROGRESS
c4032f4 bitbake: codeparser: Only load the codeparser cache once
e3b66c1 maintainers: mass reassign and cleanup
37ddd3e Revert "local.conf.sample: Disable image-prelink by default"
9cc221d yocto-bsp: Default kernel version to 4.1 on x86_64
7100c42 scripts: runqemu: remove QEMUARCH from help message
f47e4ad cairo: update 1.14.2 -> 1.14.4
603b4de cairo.inc: drop obsolete CFLAGS += "-ffat-lto-objects" workaround
e8833a6 cmake: update 3.3.1 -> 3.3.2
8b2b068 oe-selftest: add test for bitbake-layers show-recipes
480bbae oeqa/selftest/layerappend: fix test if build directory is not inside COREBASE
a301f6e oeqa/selftest/devtool: fix test if build directory is not inside COREBASE
fd6bf77 classes/distrodata: split SRC_URI properly before determining type
7cebff6 classes/buildhistory: split package history values only once
10fc534 conf/distro/include: drop old recipes from include files
37cfd80 gitignore: fix overzealous exclusion
1f6599b meta: Fix typos in Upstream-Status labels
7cace4c meta/conf/layer.conf: fix typo
ca8e1e5 texinfo-dummy-native: set SUMMARY instead of DESCRIPTION
64cd113 gstreamer1.0-meta-base: set SUMMARY instead of DESCRIPTION
1d42d59 mmc-utils: set SUMMARY instead of DESCRIPTION
6692540 swig: set SUMMARY instead of DESCRIPTION
47ae8eb alsa-plugins: set SUMMARY instead of DESCRIPTION
eac5fa9 tzcode-native: set SUMMARY instead of DESCRIPTION
0a30a1f linux-yocto.inc: set SUMMARY instead of DESCRIPTION
19e1a73 python-nose: add SUMMARY
b5f58c1 stress: add SUMMARY
5f9392a libunwind: add SUMMARY
1460e01 gptfdisk: add SUMMARY
0821c36 verify-homepage: fix recipe file selection
0c48921 verify-homepage: tidy up output and comments
0e348e7 verify-homepage: get expanded HOMEPAGE value
caaca00 verify-homepage: use scriptpath to find bitbake path
649b6bc libaio: don't disable linking to the system libraries
11a9c24 runqemu: don't specify IP when starting a VNC server
3b95964 qemurunner: Remove the timeout in run_serial
bbd6d07 libxslt: CVE-2015-7995
a0d2ea9 gstreamer1.0-rtsp-server: upgrade to version 1.6.1
2459ec2 gstreamer1.0-libav: upgrade to version 1.6.1
bce06e7 gstreamer1.0-plugins-ugly: upgrade to version 1.6.1
0ec3c62 gstreamer1.0-plugins-bad: upgrade to version 1.6.1
ba1bc63 gstreamer1.0-plugins-good: upgrade to version 1.6.1
4a55d12 gstreamer1.0-plugins-base: upgrade to version 1.6.1
8360f23 gstreamer1.0: upgrade to version 1.6.1
8800033 prelink: Fix various prelink issues on IA32, ARM, and MIPS.
920fb96 gcc: Update default Power GCC settings to use secure-plt
7b1763a glibc: Fix ld.so / prelink interface for ELF_RTYPE_CLASS_EXTERN_PROTECTED_DATA
e63e191 qemurunner: Enable timestamps on kernel boot-up
a1ca788 openssl: fix mips64 configure support
5a10a6f at: modify sources in do_patch
78e0598 unzip: rename patch to reflect CVE fix
b80935a readline: rename patch to contain CVE reference
86d84ff qemu: upgrade to 2.4.0.1
4f0d756 gnome-desktop-testing: fix ptest output format
834de84 default-distrovars: remove less from WHITELIST_GPL-3.0
29bba95 lsof: don't export EXTRA_OEMAKE
3d37768 cmake.bbclass: don't duplicate CMAKE_C_FLAGS in CMAKE_C_FLAGS_RELEASE
efc07c2 rm_work.bbclass: Exclude do_rootfs stamp removal
5f9d16b cairo: fix license for cairo-script-interpreter
7328479 openssh: enable X11Forwarding if distro feature x11 is set
adeb820 acpid: Upgrade to 2.0.25
781dfd8 libidn: 1.30 -> 1.32
351c69a sqlite: 3.8.10.2 -> 3.9.0
c0fe43c rt-tests: bump to v0.94
cf972f9 gbm: Fix "configure: error: gbm requires --enable-dri"
17733cc xinetd: install xinetd supported services configuration
aa1844e combo-layer: introduce ability to exclude component from mass update
dcc446f linux-dtb.inc: refactor common code to function get_real_dtb_path_in_kernel
af9c7a4 linux-dtb.inc: refactor common code to function normalize_dtb
7eecb81 linux-dtb.inc: explicit test for empty string not needed
54df911 ptest-runner: Allow running of specific tests
54325b2 oeqa/testimage: Add support for test folder export.
ecbe135 oeqa/runtime/multilib: run the arch tests on connmand not connman-applet
2d1071e oeqa/runtime: remove dmesg test
42a5378 nfs-utils/statd: fix a segfault
77e3246 qemu: enable user mode for mips64 and mips64el
70600fb gnupg: fix find-version for beta checking
ab123ef rpm: define EM_AARCH64 for debugedit
af8c136 xserver-xorg: drop empty ${PN}-security-policy package
b667067 xserver-xorg: add Xwayland RRECOMMENDS
80f4d71 weston: add a PACKAGECONFIG option for xwayland support
883ab0f systemd: make dbus an optional build time dependency
2c5047f weston: add PACKAGECONFIG to build with systemd-login support
65ffeb5 systemd: add PACKAGECONFIG to build with compatibility libraries
4b29c80 os-release: put double-quotes around variable contents
0f516a5 cpio: fix testcase symlink-bad-lengths [ LIN8-947 ]
bceb9cb cpio: Fix symlink-bad-length test for 64-bit [ LIN8-947 ] architectures.
0ff3fc7 gtk+3: fix ALTERNATIVE_PRIORITY conflict with gtk+
eca12a6 coreutils: fix ALTERNATIVE_PRIORITY conflict with procps and mktemp
8de5315 util-linux: fix ALTERNATIVE_PRIORITY conflict with ncurses procps and e2fsprogs
3befb43 console-tools: fix ALTERNATIVE_PRIORITY conflict with kbd
5385ea8 debianutils: fix ALTERNATIVE_PRIORITY conflict with which
3a0bd40 linux-dtb.inc: use same variable name DTB for all elements of KERNEL_DEVICETREE
a879312 linux-dtb.inc: remove unneeded 'cd'
a23d1ca webkitgtk: Add upstream patch to fix build problem
69836e8 python: don't append -D__SOFTFP__ to TARGET_CC_ARCH for armv6/armv7a
38d1d63 prexport.bbclass: avoid export for native and crosssdk
d3da006 recipes: add distro_features_check for some packages
63690f0 scons.bbclass: SCons packages don't require do_configure
bffdc65 busybox: Schedule mdev after mountall
13ce7c2 busybox: Fix mdev block device automounting
b09f0f2 libarchive: rename patch to reflect CVE
116360f binutils: Fix XLP / Octeon 3 instruction clash
fd4f4d2 binutils: Fix octeon3 disassembly patch
REVERT: b1f23d1 build-appliance-image: Update to jethro head revision
REVERT: 7fe17a2 qemu: Security fix CVE-2016-2198
REVERT: 50700a7 qemu: Security fix CVE-2016-2197
REVERT: 1f0e615 libgcrypt: Security fix CVE-2015-7511
REVERT: dc5f155 uclibc: Security fix CVE-2016-2225
REVERT: ef13511 uclibc: Security fix CVE-2016-2224
REVERT: ae57ea0 libbsd: Security fix CVE-2016-2090
REVERT: eb9666a glibc: Security fix CVE-2015-7547
REVERT: 5b12268 build-appliance-image: Update to jethro head revision
REVERT: a3a374a curl: Secuirty fix CVE-2016-0755
REVERT: f4341a9 curl: Security fix CVE-2016-0754
REVERT: 35f4306 nettle: Security fix CVE-2015-8804
REVERT: 3e8a07b nettle: Security fix CVE-2015-8803 and CVE-2015-8805
REVERT: 5ffc326 socat: Security fix CVE-2016-2217
REVERT: 5cc5f99 libpng: Security fix CVE-2015-8472
REVERT: 21a816c libpng: Security fix CVE-2015-8126
REVERT: 6a0fbfa foomatic-filters: Security fixes CVE-2015-8327
REVERT: d57aaf7 foomatic-filters: Security fix CVE-2015-8560
REVERT: 941874a build-appliance-image: Update to jethro head revision
REVERT: d74a3cb cross-localedef-native: add ABI breaking glibc patch
REVERT: 12fae23 build-appliance-image: Update to jethro head revision
REVERT: 67ac9d6 e2fsprogs: Ensure we use the right mke2fs.conf when restoring from sstate
REVERT: 5812fc9 build-appliance-image: Update to jethro head revision
REVERT: 3de2492 ref-manual: Updated host package install requirements CentOS
REVERT: 79de8cf toaster-manual: Updated the "Installation" to have TOASTER_DIR information
REVERT: a23d262 toaster-manual: Updated instructions for production setup.
REVERT: b6def81 linux-yocto: Update SRCREV for genericx86* for 4.1, fixes CVE-2016-0728
REVERT: db0f8ac linux-yocto: Update SRCREV for genericx86* for 3.19, fixes CVE-2016-0728
REVERT: c8122a0 linux-yocto: Update SRCREV for genericx86* for 3.14, fixes CVE-2016-0728
REVERT: cdeb241 meta-yocto-bsp: Remove uvesafb (v86d) from generic x86 features
REVERT: 52cd219 yocto-bsp: Set SRCREV meta/machine revisions to AUTOREV
REVERT: a88d6cb yocto-bsp: Set KTYPE to user selected base branch
REVERT: 4e74b36 yocto-bsp: Avoid duplication of user patches ({{=machine}}-user-patches.scc)
REVERT: 6680773 yocto-bsp: Default kernel version to 4.1 on x86_64
REVERT: 4c075e7 piglit: don't use /tmp to write generated sources to
REVERT: ee52ac6 gen-lockedsig-cache: fix bad destination path joining
REVERT: e9f95df linux-yocto: Update SRCREV for qemux86* for 4.1, fixes CVE-2016-0728
REVERT: e63bab1 linux-yocto: Update SRCREV for qemux86* for 3.19, fixes CVE-2016-0728
REVERT: 64a4920 linux-yocto: Update SRCREV for qemux86* for 3.14, fixes CVE-2016-0728
REVERT: 5b043da libpng12: update URL that no longer exists
REVERT: 655c8a5 libpng: update URL that no longer exists
REVERT: 96fda8c busybox: fix build of last applet
REVERT: ae037d9 ghostscript: add dependency for pnglibconf.h
REVERT: 26eb877 gcr: Require x11 DISTRO_FEATURE
REVERT: e632cdb uClibc: enable utmp for shadow compatibility
REVERT: e8c9613 git: Security fix CVE-2015-7545
REVERT: 108ea6d glibc-locale: fix QA warning
REVERT: 9a88c1d grub: Security fix CVE-2015-8370
REVERT: 443b09a gdk-pixbuf: Security fix CVE-2015-7674
REVERT: 6c91068 librsvg: Security fix CVE-2015-7558
REVERT: 9fd2349 bind: Security fix CVE-2015-8461
REVERT: 5a40d9f bind: Security fix CVE-2015-8000
REVERT: 1bbf183 libxml2: Security fix CVE-2015-8710
REVERT: 2ec6d1d libxml2: Security fix CVE-2015-8241
REVERT: 55aafb5 dpkg: Security fix CVE-2015-0860
REVERT: 029948b tzdata: update to 2016a
REVERT: 2bcf141 tzcode: update to 2016a
REVERT: cc3a391 kernel-yocto: fix checkout bare-cloned kernel repositories
REVERT: 049be17 libpcre: bug fixes include security
REVERT: 5e94ac7 qemu: Security fix CVE-2015-7295
REVERT: 7ee1828 qemu: Security fix CVE-2016-1568
REVERT: ca6ec2e qemu: Security fix CVE-2015-8345
REVERT: b55a677 qemu: Security fix CVE-2015-7512
REVERT: 4922f47 qemu: Security fix CVE-2015-7504
REVERT: 3ec0e95 qemu: Security fix CVE-2015-8504
REVERT: 942ce53 openssl: Security fix CVE-2016-0701
REVERT: ce8ae1c openssl: Security fix CVE-2015-3197
REVERT: 080e027 tiff: Security fix CVE-2015-8784
REVERT: c6ae9c1 tiff: Security fix CVE-2015-8781
REVERT: 049b7db bind: CVE-2015-8704 and CVE-2015-8705
REVERT: d632a92 rpmresolve.c: Fix unfreed pointers that keep DB opened
REVERT: 5b993ed openssh: CVE-2016-1907
REVERT: 27ee5b4 glibc: CVE-2015-8776
REVERT: a4134af glibc: CVE-2015-9761
REVERT: e10ec6f glibc: CVE-2015-8779
REVERT: a5a965d glibc: CVE-2015-8777.patch
REVERT: 2fb7ee2 bitbake: toaster: make runbuilds loop
REVERT: b9ad87b nativesdk-buildtools-perl-dummy: Bump PR
REVERT: 0a1c63a nativesdk-buildtools-perl-dummy: properly set PACKAGE_ARCH
REVERT: d4b400e nativesdk-buildtools-perl-dummy: fix rebuilding when SDKMACHINE changes
REVERT: 8c8c4ed Revert "gstreamer1.0-plugins-good.inc: add gudev back to PACKAGECONFIG"
REVERT: b832202 Revert "gstreamer: Deal with merge conflict which breaks systemd builds"
REVERT: dd0ba9e build-appliance-image: Update to jethro head revision
REVERT: 325d205 gstreamer: Deal with merge conflict which breaks systemd builds
REVERT: 53b114b build-appliance-image: Update to jethro head revision
REVERT: 02be35d poky.conf: Bump version for 2.0.1 jethro release
REVERT: f5551f8 ref-manual: Updated the list of supported image types.
REVERT: aa179ae dev-manual: Added three new wic option descriptions.
REVERT: 20007c8 dev-manual: Added the --overhead-factor wic option description.
REVERT: 2dd7f46 dev-manual: Added the --extra-space wic option description.
REVERT: 81cc737 dev-manual: Added wic --notable option description.
REVERT: 2b1dce5 dev-manual:
REVERT: a6f5293 kernel/kernel-arch: Explicitly mapping between i386/x86_64 and x86 for kernel ARCH
REVERT: e79a538 openssh: update to 7.1p2
REVERT: b171076 devtool: reset: do clean for multiple recipes at once with -a
REVERT: 255115f devtool: sdk-update: fix error checking
REVERT: 3f69105 devtool: sdk-update: fix metadata update step
REVERT: 5ba94af devtool: sdk-update: fix not using updateserver config file option
REVERT: d03d145 classes/populate_sdk_ext: disable signature warnings
REVERT: 00ff950 classes/populate_sdk_ext: fix cascading from preparation failure
REVERT: 22446c6 scripts/oe-publish-sdk: add missing call to git update-server-info
REVERT: 8597a61 devtool: use cp instead of shutil.copytree
REVERT: 95cc641 buildhistory: fix not recording SDK information
REVERT: 84d48ac recipetool: create: fix error when extracting source to a specified directory
REVERT: 4369329 recipetool: create: detect when specified URL returns a web page
REVERT: 4c3191f recipetool: create: prevent attempting to unpack entire DL_DIR
REVERT: caca77e recipetool: create: fix do_install handling for makefile-only software
REVERT: 383159e recipetool: create: avoid traceback on fetch error
REVERT: be40baa recipetool: create: handle https://....git URLs
REVERT: a897bfd devtool: sdk-update: fix traceback without update server set
REVERT: 9c4b61e classes/populate_sdk_ext: error out of install if buildtools install fails
REVERT: 4c07dd2 gstreamer1.0-plugins-good.inc: add gudev back to PACKAGECONFIG
REVERT: 83b72d8 linux-yocto: Update Genericx86* BSP to 4.1.15 kernel
REVERT: 44639bd libaio: don't disable linking to the system libraries
REVERT: a0be9bd linux-yocto/4.1: update to v4.1.15
REVERT: 53f0290 libxml2: security fix CVE-2015-5312
REVERT: f4b0c49 libxml2: security fix CVE-2015-8242
REVERT: fb409c9 libxml2: security fix CVE-2015-7500
REVERT: 55d097a libxml2: security fix CVE-2015-7499
REVERT: 8e6b2d6 libxml2: security fix CVE-2015-7497
REVERT: 332eb1d libxml2: security fix CVE-2015-7498
REVERT: cbc4e83 libxml2: security fix CVE-2015-8035
REVERT: c4b71e1 libxml2: security fix CVE-2015-7942
REVERT: fdea03d libxml2: security fix CVE-2015-8317
REVERT: 6fc1109 libxml2: security fix CVE-2015-7941
REVERT: 9eb4ce0 openssl: fix for CVE-2015-3195
REVERT: 6880f82 openssl: fix for CVE-2015-3194
REVERT: 7dcaa84 openssl: fix for CVE-2015-3193
REVERT: 435139b logrotate: do not move binary logrotate to /usr/bin
REVERT: 5f49c0a cairo: fix license for cairo-script-interpreter
REVERT: a29ec81 glibc: Fix ld.so / prelink interface for ELF_RTYPE_CLASS_EXTERN_PROTECTED_DATA
REVERT: b1e980f gcc: Update default Power GCC settings to use secure-plt
REVERT: ed82690 prelink: Fix various prelink issues on IA32, ARM, and MIPS.
REVERT: 9a620da autotools: Allow recipe-individual configure scripts
REVERT: f828071 toolchain-scripts.bbclass: unset command_not_found_handle
REVERT: 49858bd devtool: upgrade: fetch remote repository before checking out new revision
REVERT: d213452 devtool: upgrade: remove erroneous error when not renaming recipe
REVERT: fec97f6 devtool: upgrade: fix updating PV and SRCREV
REVERT: 3b4f659 devtool: upgrade: fix removing other recipes from workspace on reset
REVERT: 61a7de0 devtool: include do_patch in SRCTREECOVEREDTASKS
REVERT: 82c0072 toolchain-shar-extract.sh: do not allow $ in paths for ext SDK
REVERT: f181e72 scripts/gen-lockedsig-cache: improve output
REVERT: 4b5d4ca toolchain-shar-extract.sh: proper fix for additional env setup scripts
REVERT: d2ea8f1 toolchain-shar-relocate: don't assume last state of env_setup_script is good
REVERT: 02ef437 populate_sdk_ext.bbclass: Be more permissive on the name of the buildtools
REVERT: 3653b17 classes/populate_sdk_ext: fail if SDK_ARCH != BUILD_ARCH
REVERT: 8879571 classes/populate_sdk_ext: tweak reporting of workspace exclusion
REVERT: eeda3c6 classes/populate_sdk_ext: make it clear when SDK installation has failed
REVERT: dee9fbe classes/populate_sdk_ext: tidy up preparation log file writing
REVERT: d001d46 classes/license: fix intermittent license collection warning
REVERT: 777451c classes/metadata_scm: fix git errors showing up on non-git repositories
REVERT: cb0ca72 oeqa/selftest/layerappend: fix test if build directory is not inside COREBASE
REVERT: 8970ad6 oeqa/selftest/devtool: fix test if build directory is not inside COREBASE
REVERT: 4f7fdd0 classes/distrodata: split SRC_URI properly before determining type
REVERT: 3b7df55 uninative.bbclass: Choose the correct loader based on BUILD_ARCH
REVERT: f3d7c3f openssl: sanity check that the bignum module is present
REVERT: 96b1b5c glibc: Backported a patch to fix glibc's bug(18589)
REVERT: 7aecb57 directfb.inc: force bfd linker for armv7a
REVERT: 75ca2c8 texinfo: don't create dependency on INHERIT variable
REVERT: 02c7b3f package_manager.py: define info_dir and status_file when OPKGLIBDIR isn't the default
REVERT: 003c94f libsdl2: require GLES when building Wayland support
REVERT: ad6db01 gst-plugins-bad: add PACKAGECONFIGs for voamrwbenc, voaacenc, resindvd
REVERT: f0d87fe gstreamer1.0-plugins-good: fix PACKAGECONFIG for gudev and add one for v4l2 and libv4l2
REVERT: 35f34a6 gstreamer1.0-plugins-bad: fix dependencies for uvch264 PACKAGECONFIG
REVERT: 3b77e20 gstreamer1.0-plugins-{base,good}: update PACKAGECONFIGs
REVERT: e2d4412 libunwind: fix build for qemuarm
REVERT: ef69078 guile, mailx, gcc, opensp, gstreamer1.0-libav, libunwind: disable thumb where it fails for qemuarm
REVERT: 4700e40 icu: force arm mode
REVERT: 743ee04 libxcb: Add a workaround for gcc5 bug on mips
REVERT: 8a3deca bitbake: fetch: use orig localpath when calling orig method
REVERT: 0073b23 yocto-bsp: Typo on the file extension
REVERT: 71dbbcd bsp-guide: Updated the license statement.
REVERT: 41f1026 dev-manual: Correction to the KVM stuff in the runqemu commands.
REVERT: 38e3c6e mega-manual: Added four new figures for GUI example.
REVERT: b99ec28 poky.ent: Fixed POKYVERSION variable.
REVERT: c670dc7 yocto-project-qs, ref-manual, poky.ent: CentOS Package updates
REVERT: b968190 dev-manual: Updated runqemu command options list
REVERT: 1278753 toaster-manual: Removed SDKMACHINE from the json file example.
REVERT: 7b25b70 ref-manual: Updated list of supported distros.
REVERT: d9423fb ref-manual: Updated the GCC 5 migration section for 2.0
REVERT: 347347a bitbake: lib/bb/utils: improve edit_bblayers_conf() handling of bblayers.conf formatting
REVERT: 5935783 bitbake: lib/bb/utils: fix error in edit_metadata() when deleting first line
REVERT: 7fdad70 rpcbind: Security Advisory - rpcbind - CVE-2015-7236
REVERT: 0cb2fa5 subversion: fix CVE-2015-3187
REVERT: 5b52e9b subversion: fix CVE-2015-3184
REVERT: 59bdde4 linux-firmware: rtl8192cx: Add latest available firmware
REVERT: 8ad2bcc init-install-efi: fix script for gummiboot loader
REVERT: c3087bd init-install-efi: fix script for eMMC installation
REVERT: d2bf9fb pulseaudio: Fix HDMI profile selection
REVERT: 0556c58 allarch: Force TARGET_*FLAGS variable values
REVERT: e683dac libsndfile: fix CVE-2014-9756
REVERT: 092757e libxslt: CVE-2015-7995
REVERT: dab5555 unzip: rename patch to reflect CVE fix
REVERT: 1753d4a readline: rename patch to contain CVE reference
REVERT: 9dd3422 libarchive: rename patch to reflect CVE
REVERT: 1401976 binutils: Fix octeon3 disassembly patch
REVERT: a54a0db opkg: add cache filename length fixes

git-subtree-dir: yocto-poky
git-subtree-split: 8358e543ab95a1d2b1d19c1e944275daa17378c1
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/yocto-poky/meta/recipes-devtools/apt/apt.inc b/yocto-poky/meta/recipes-devtools/apt/apt.inc
index 3248b9a..78ef5a7 100644
--- a/yocto-poky/meta/recipes-devtools/apt/apt.inc
+++ b/yocto-poky/meta/recipes-devtools/apt/apt.inc
@@ -11,11 +11,16 @@
            file://nodoc.patch \
            file://disable-configure-in-makefile.patch \
            file://disable-test.patch \
+           file://0001-environment.mak-musl-based-systems-can-generate-shar.patch \
            "
 SRC_URI[md5sum] = "6505c4297b338adb2087ce87bbc4a276"
 SRC_URI[sha256sum] = "3fb1de9598363c416591d49e3c285458e095b035e6c06d5b944a54e15fc9b543"
 LIC_FILES_CHKSUM = "file://COPYING.GPL;md5=0636e73ff0215e8d672dc4c32c317bb3"
 
+# the package is taken from snapshots.debian.org; that source is static and goes stale
+# so we check the latest upstream from a directory that does get updated
+UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/a/apt/"
+
 inherit autotools gettext
 
 EXTRA_AUTORECONF = "--exclude=autopoint,autoheader"
@@ -24,5 +29,3 @@
     rm -rf ${S}/buildlib/config.sub
     rm -rf ${S}/buildlib/config.guess
 }
-
-FILES_${PN}-dbg += "${libdir}/apt/methods/.debug/"
diff --git a/yocto-poky/meta/recipes-devtools/apt/apt/0001-environment.mak-musl-based-systems-can-generate-shar.patch b/yocto-poky/meta/recipes-devtools/apt/apt/0001-environment.mak-musl-based-systems-can-generate-shar.patch
new file mode 100644
index 0000000..042372b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/apt/apt/0001-environment.mak-musl-based-systems-can-generate-shar.patch
@@ -0,0 +1,29 @@
+From 2f8aa21ace375c18977ed908b291c80a210a93c6 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 31 Dec 2015 08:06:12 +0000
+Subject: [PATCH] environment.mak: musl based systems can generate shared
+ objects too
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ buildlib/environment.mak.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/buildlib/environment.mak.in b/buildlib/environment.mak.in
+index b0a8d9d..3a52344 100644
+--- a/buildlib/environment.mak.in
++++ b/buildlib/environment.mak.in
+@@ -68,7 +68,7 @@ NEED_SOCKLEN_T_DEFINE = @NEED_SOCKLEN_T_DEFINE@
+ 
+ # Shared library things
+ HOST_OS = @host_os@
+-ifneq ($(words $(filter gnu% linux-gnu% kfreebsd-gnu% %-gnu,$(HOST_OS))),0)
++ifneq ($(words $(filter gnu% linux-gnu% kfreebsd-gnu% %-gnu linux-musl%,$(HOST_OS))),0)
+    SONAME_MAGIC=-Wl,-soname -Wl,
+    LFLAGS_SO=
+ else
+-- 
+2.6.4
+
diff --git a/yocto-poky/meta/recipes-devtools/apt/apt_1.0.10.1.bb b/yocto-poky/meta/recipes-devtools/apt/apt_1.0.10.1.bb
index bf77e2a..85c0d56 100644
--- a/yocto-poky/meta/recipes-devtools/apt/apt_1.0.10.1.bb
+++ b/yocto-poky/meta/recipes-devtools/apt/apt_1.0.10.1.bb
@@ -1,4 +1,4 @@
-DEPENDS = "curl db"
+DEPENDS = "curl db zlib"
 RDEPENDS_${PN} = "dpkg bash debianutils"
 require apt.inc
 
@@ -6,6 +6,7 @@
 
 PACKAGECONFIG ??= "lzma"
 PACKAGECONFIG[lzma] = "ac_cv_lib_lzma_lzma_easy_encoder=yes,ac_cv_lib_lzma_lzma_easy_encoder=no,xz"
+PACKAGECONFIG[bz2] = "ac_cv_lib_bz2_BZ2_bzopen=yes,ac_cv_lib_bz2_BZ2_bzopen=no,bzip2"
 
 FILES_${PN} += "${bindir}/apt-key"
 apt-manpages += "doc/apt-key.8"
diff --git a/yocto-poky/meta/recipes-devtools/autoconf/autoconf.inc b/yocto-poky/meta/recipes-devtools/autoconf/autoconf.inc
index 78b77e8..b4e3356 100644
--- a/yocto-poky/meta/recipes-devtools/autoconf/autoconf.inc
+++ b/yocto-poky/meta/recipes-devtools/autoconf/autoconf.inc
@@ -20,6 +20,7 @@
 		  perl-module-file-glob \
 		  perl-module-file-path \
 		  perl-module-file-stat \
+		  perl-module-file-find \
 		  perl-module-getopt-long \
 		  perl-module-io-file \
 		  perl-module-posix \
diff --git a/yocto-poky/meta/recipes-devtools/autoconf/autoconf/add_musl_config.patch b/yocto-poky/meta/recipes-devtools/autoconf/autoconf/add_musl_config.patch
new file mode 100644
index 0000000..a9094d2
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/autoconf/autoconf/add_musl_config.patch
@@ -0,0 +1,26 @@
+backport http://git.savannah.gnu.org/cgit/config.git/commit/config.sub?id=062587eaa891396c936555ae51f7e77eeb71a5fe
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport
+Index: autoconf-2.69/build-aux/config.sub
+===================================================================
+--- autoconf-2.69.orig/build-aux/config.sub
++++ autoconf-2.69/build-aux/config.sub
+@@ -123,7 +123,7 @@ esac
+ maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
+ case $maybe_os in
+   nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
+-  linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
++  linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
+   knetbsd*-gnu* | netbsd*-gnu* | \
+   kopensolaris*-gnu* | \
+   storm-chaos* | os2-emx* | rtmk-nova*)
+@@ -1360,7 +1360,7 @@ case $os in
+ 	      | -chorusos* | -chorusrdb* | -cegcc* \
+ 	      | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
+ 	      | -mingw32* | -linux-gnu* | -linux-android* \
+-	      | -linux-newlib* | -linux-uclibc* \
++	      | -linux-newlib* | -linux-musl* | -linux-uclibc* \
+ 	      | -uxpv* | -beos* | -mpeix* | -udk* \
+ 	      | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
+ 	      | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
diff --git a/yocto-poky/meta/recipes-devtools/autoconf/autoconf/performance.patch b/yocto-poky/meta/recipes-devtools/autoconf/autoconf/performance.patch
new file mode 100644
index 0000000..1842fe9
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/autoconf/autoconf/performance.patch
@@ -0,0 +1,60 @@
+The check for solaris 'print' causes significant problems on a linux machine
+with dash as /bin/sh since it triggers the execution of "print" which on some 
+linux systems is a perl script which is part of mailcap. Worse, this perl 
+script calls "which file" and if successful ignores the path file was found 
+in and just runs "file" without a path. Each exection causes PATH to be searched.
+
+Simply assuming the shell's printf function works cuts out all the fork overhead
+and when parallel tasks are running, this overhead appears to be significant.
+
+RP
+2015/11/28
+Upstream-Status: Inappropriate
+
+Index: autoconf-2.69/lib/m4sugar/m4sh.m4
+===================================================================
+--- autoconf-2.69.orig/lib/m4sugar/m4sh.m4
++++ autoconf-2.69/lib/m4sugar/m4sh.m4
+@@ -1045,40 +1045,8 @@ m4_defun([_AS_ECHO_PREPARE],
+ [[as_nl='
+ '
+ export as_nl
+-# Printing a long string crashes Solaris 7 /usr/bin/printf.
+-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
+-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
+-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
+-# Prefer a ksh shell builtin over an external printf program on Solaris,
+-# but without wasting forks for bash or zsh.
+-if test -z "$BASH_VERSION$ZSH_VERSION" \
+-    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
+-  as_echo='print -r --'
+-  as_echo_n='print -rn --'
+-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
+-  as_echo='printf %s\n'
+-  as_echo_n='printf %s'
+-else
+-  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
+-    as_echo_body='eval /usr/ucb/echo -n "$][1$as_nl"'
+-    as_echo_n='/usr/ucb/echo -n'
+-  else
+-    as_echo_body='eval expr "X$][1" : "X\\(.*\\)"'
+-    as_echo_n_body='eval
+-      arg=$][1;
+-      case $arg in @%:@(
+-      *"$as_nl"*)
+-	expr "X$arg" : "X\\(.*\\)$as_nl";
+-	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
+-      esac;
+-      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
+-    '
+-    export as_echo_n_body
+-    as_echo_n='sh -c $as_echo_n_body as_echo'
+-  fi
+-  export as_echo_body
+-  as_echo='sh -c $as_echo_body as_echo'
+-fi
++as_echo='printf %s\n'
++as_echo_n='printf %s'
+ ]])# _AS_ECHO_PREPARE
+ 
+ 
diff --git a/yocto-poky/meta/recipes-devtools/autoconf/autoconf_2.69.bb b/yocto-poky/meta/recipes-devtools/autoconf/autoconf_2.69.bb
index 809007f..adb6ad7 100644
--- a/yocto-poky/meta/recipes-devtools/autoconf/autoconf_2.69.bb
+++ b/yocto-poky/meta/recipes-devtools/autoconf/autoconf_2.69.bb
@@ -13,6 +13,8 @@
             file://remove-usr-local-lib-from-m4.patch \
             file://preferbash.patch \
             file://autotest-automake-result-format.patch \
+            file://add_musl_config.patch \
+            file://performance.patch \
            "
 
 SRC_URI[md5sum] = "82d05e03b93e45f5a39b828dc9c6c29b"
diff --git a/yocto-poky/meta/recipes-devtools/autogen/autogen-native_5.18.5.bb b/yocto-poky/meta/recipes-devtools/autogen/autogen-native_5.18.6.bb
similarity index 83%
rename from yocto-poky/meta/recipes-devtools/autogen/autogen-native_5.18.5.bb
rename to yocto-poky/meta/recipes-devtools/autogen/autogen-native_5.18.6.bb
index 2a28512..d77b827 100644
--- a/yocto-poky/meta/recipes-devtools/autogen/autogen-native_5.18.5.bb
+++ b/yocto-poky/meta/recipes-devtools/autogen/autogen-native_5.18.6.bb
@@ -14,8 +14,11 @@
            file://redirect-output-dir.patch \
 "
 
-SRC_URI[md5sum] = "385d7c7dfbe60babbee261c054923a53"
-SRC_URI[sha256sum] = "7bbdb73b5518baf64c6d3739fb2ecc66d2cccda888ce5ad573abe235ab5d96ba"
+SRC_URI[md5sum] = "fdee403e524c0af3ded6b3becb365671"
+SRC_URI[sha256sum] = "2fc7f12a5ecb3b1e8bd4364aa906b837cff01f80edb7d2fb38ed8b9dfbcd3271"
+
+UPSTREAM_CHECK_URI = "http://ftp.gnu.org/gnu/autogen/"
+UPSTREAM_CHECK_REGEX = "rel(?P<pver>\d+(\.\d+)+)/"
 
 DEPENDS = "guile-native libtool-native libxml2-native"
 
diff --git a/yocto-poky/meta/recipes-devtools/autogen/autogen/increase-timeout-limit.patch b/yocto-poky/meta/recipes-devtools/autogen/autogen/increase-timeout-limit.patch
index 3d4c1d6..9efd7e5 100644
--- a/yocto-poky/meta/recipes-devtools/autogen/autogen/increase-timeout-limit.patch
+++ b/yocto-poky/meta/recipes-devtools/autogen/autogen/increase-timeout-limit.patch
@@ -12,22 +12,19 @@
  1 file changed, 3 insertions(+), 3 deletions(-)
 
 diff --git a/configure.ac b/configure.ac
-index 0af7c18..5544f59 100644
+index 58a848b..170dd9e 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -175,9 +175,9 @@ config_end_time=`date +%s 2>/dev/null`
- time_delta=`expr ${config_end_time} - ${config_start_time} 2>/dev/null`
+@@ -178,9 +178,9 @@ time_delta=`expr ${config_end_time} - ${config_start_time} 2>/dev/null`
+ if test -z "${AG_TIMEOUT}"
+ then
+   if test -z "${time_delta}"
+-  then time_delta=10
+-  elif test ${time_delta} -lt 5
+-  then time_delta=5 ; fi
++  then time_delta=60
++  elif test ${time_delta} -lt 30
++  then time_delta=30 ; fi
  
- if test -z "${time_delta}"
--then time_delta=10
--elif test ${time_delta} -lt 5
--then time_delta=5 ; fi
-+then time_delta=60
-+elif test ${time_delta} -lt 30
-+then time_delta=30 ; fi
- 
- AG_TIMEOUT=${time_delta}
- ]
--- 
-1.7.9.5
-
+   AG_TIMEOUT=${time_delta}
+ fi
diff --git a/yocto-poky/meta/recipes-devtools/autogen/autogen/redirect-output-dir.patch b/yocto-poky/meta/recipes-devtools/autogen/autogen/redirect-output-dir.patch
index de126ed..fc5a71b 100644
--- a/yocto-poky/meta/recipes-devtools/autogen/autogen/redirect-output-dir.patch
+++ b/yocto-poky/meta/recipes-devtools/autogen/autogen/redirect-output-dir.patch
@@ -1,6 +1,6 @@
 [PATCH] redirect the dir of mklibsrc-log.tx
 
-Upstream-Statue: Pending
+Upstream-Status: Pending
 
 redirect mklibsrc-log.tx to builddir, not /tmp; otherwise mklibsrc-log.tx
 maybe unable to be written if other users is building autogen at the same time.
diff --git a/yocto-poky/meta/recipes-devtools/automake/automake.inc b/yocto-poky/meta/recipes-devtools/automake/automake.inc
index a1debd8..4f9b5f7 100644
--- a/yocto-poky/meta/recipes-devtools/automake/automake.inc
+++ b/yocto-poky/meta/recipes-devtools/automake/automake.inc
@@ -10,6 +10,9 @@
 inherit autotools texinfo
 
 do_configure() {
+	# We can end up patching macros, which would then mean autoreconf
+	# Cheat by saying everything is up to date.
+	touch ${S}/aclocal.m4 ${S}/Makefile.in ${S}/configure
 	oe_runconf
 }
 
diff --git a/yocto-poky/meta/recipes-devtools/automake/automake/new_rt_path_for_test-driver.patch b/yocto-poky/meta/recipes-devtools/automake/automake/new_rt_path_for_test-driver.patch
new file mode 100644
index 0000000..2c6594f
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/automake/automake/new_rt_path_for_test-driver.patch
@@ -0,0 +1,36 @@
+Set relative to top_builddir path in Makefile to access test-driver
+
+Signed-off-by: Adrian Calianu <adrian.calianu@enea.com>
+Upstream-Status: Pending
+Bug-Report: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=19042
+
+--- a/bin/automake.in
++++ b/bin/automake.in
+@@ -272,6 +272,9 @@
+ # $AM_CONFIG_AUX_DIR is prefixed with $(top_srcdir), so it can be used
+ # in Makefiles.
+ my $am_config_aux_dir = '';
++# Directory used at runtime like running test-driver that should not
++# depend on $(top_srcdir)
++my $am_config_rt_aux_dir = '';
+
+ # Directory to search for AC_LIBSOURCE files, as set by AC_CONFIG_LIBOBJ_DIR
+ # in configure.ac.
+@@ -4700,7 +4703,7 @@
+     {
+       require_conf_file ("parallel-tests", FOREIGN, 'test-driver');
+       define_variable ("${pfx}LOG_DRIVER",
+-                       "\$(SHELL) $am_config_aux_dir/test-driver",
++                       "\$(SHELL) $am_config_rt_aux_dir/test-driver",
+                        INTERNAL);
+     }
+   my $driver = '$(' . $pfx . 'LOG_DRIVER)';
+@@ -7284,6 +7287,10 @@
+   $am_config_aux_dir =
+     '$(top_srcdir)' . ($config_aux_dir eq '.' ? "" : "/$config_aux_dir");
+   $am_config_aux_dir =~ s,/*$,,;
++
++  $am_config_rt_aux_dir =
++    '$(top_builddir)' . ($config_aux_dir eq '.' ? "" : "/$config_aux_dir");
++  $am_config_rt_aux_dir =~ s,/*$,,;
+ }
diff --git a/yocto-poky/meta/recipes-devtools/automake/automake/performance.patch b/yocto-poky/meta/recipes-devtools/automake/automake/performance.patch
new file mode 100644
index 0000000..3e6d569
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/automake/automake/performance.patch
@@ -0,0 +1,73 @@
+By default automake puts "sleep 1" into the start of configure scripts
+which adds pointless delays to them. Rather than do this, lets just assume 
+our systems are sane.
+
+RP
+2015/12/7
+Upstream-Status: Inappropriate
+
+Index: automake-1.15/m4/sanity.m4
+===================================================================
+--- automake-1.15.orig/m4/sanity.m4
++++ automake-1.15/m4/sanity.m4
+@@ -23,60 +23,5 @@ case $srcdir in
+     AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
+ esac
+ 
+-# Do 'set' in a subshell so we don't clobber the current shell's
+-# arguments.  Must try -L first in case configure is actually a
+-# symlink; some systems play weird games with the mod time of symlinks
+-# (eg FreeBSD returns the mod time of the symlink's containing
+-# directory).
+-if (
+-   am_has_slept=no
+-   for am_try in 1 2; do
+-     echo "timestamp, slept: $am_has_slept" > conftest.file
+-     set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
+-     if test "$[*]" = "X"; then
+-	# -L didn't work.
+-	set X `ls -t "$srcdir/configure" conftest.file`
+-     fi
+-     if test "$[*]" != "X $srcdir/configure conftest.file" \
+-	&& test "$[*]" != "X conftest.file $srcdir/configure"; then
+-
+-	# If neither matched, then we have a broken ls.  This can happen
+-	# if, for instance, CONFIG_SHELL is bash and it inherits a
+-	# broken ls alias from the environment.  This has actually
+-	# happened.  Such a system could not be considered "sane".
+-	AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
+-  alias in your environment])
+-     fi
+-     if test "$[2]" = conftest.file || test $am_try -eq 2; then
+-       break
+-     fi
+-     # Just in case.
+-     sleep 1
+-     am_has_slept=yes
+-   done
+-   test "$[2]" = conftest.file
+-   )
+-then
+-   # Ok.
+-   :
+-else
+-   AC_MSG_ERROR([newly created file is older than distributed files!
+-Check your system clock])
+-fi
+ AC_MSG_RESULT([yes])
+-# If we didn't sleep, we still need to ensure time stamps of config.status and
+-# generated files are strictly newer.
+-am_sleep_pid=
+-if grep 'slept: no' conftest.file >/dev/null 2>&1; then
+-  ( sleep 1 ) &
+-  am_sleep_pid=$!
+-fi
+-AC_CONFIG_COMMANDS_PRE(
+-  [AC_MSG_CHECKING([that generated files are newer than configure])
+-   if test -n "$am_sleep_pid"; then
+-     # Hide warnings about reused PIDs.
+-     wait $am_sleep_pid 2>/dev/null
+-   fi
+-   AC_MSG_RESULT([done])])
+-rm -f conftest.file
+ ])
diff --git a/yocto-poky/meta/recipes-devtools/automake/automake/py-compile-compile-only-optimized-byte-code.patch b/yocto-poky/meta/recipes-devtools/automake/automake/py-compile-compile-only-optimized-byte-code.patch
deleted file mode 100644
index f8334a7..0000000
--- a/yocto-poky/meta/recipes-devtools/automake/automake/py-compile-compile-only-optimized-byte-code.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-Upstream-Status: Inappropriate [embedded specific]
-
-* OE-Core's python creates the same binary output
-  for both pyc and pyo, so disable the creation of
-  pyc files by automake.
-
-Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
-
-Updated for automake-1.12.6
-
-Signed-off-by: Marko Lindqvist <cazfi74@gmail.com>
-
-diff -Nurd automake-1.12.6/lib/py-compile automake-1.12.6/lib/py-compile
---- automake-1.12.6/lib/py-compile	2012-12-13 21:57:31.000000000 +0200
-+++ automake-1.12.6/lib/py-compile	2012-12-27 19:34:01.426015140 +0200
-@@ -115,26 +115,6 @@
-     filetrans="filepath = os.path.normpath('$destdir' + os.sep + path)"
- fi
- 
--$PYTHON -c "
--import sys, os, py_compile, imp
--
--files = '''$files'''
--
--sys.stdout.write('Byte-compiling python modules...\n')
--for file in files.split():
--    $pathtrans
--    $filetrans
--    if not os.path.exists(filepath) or not (len(filepath) >= 3
--                                            and filepath[-3:] == '.py'):
--	    continue
--    sys.stdout.write(file)
--    sys.stdout.flush()
--    if hasattr(imp, 'get_tag'):
--        py_compile.compile(filepath, imp.cache_from_source(filepath), path)
--    else:
--        py_compile.compile(filepath, filepath + 'c', path)
--sys.stdout.write('\n')" || exit $?
--
- # this will fail for python < 1.5, but that doesn't matter ...
- $PYTHON -O -c "
- import sys, os, py_compile, imp
diff --git a/yocto-poky/meta/recipes-devtools/automake/automake_1.15.bb b/yocto-poky/meta/recipes-devtools/automake/automake_1.15.bb
index c33dc22..a3c72fd 100644
--- a/yocto-poky/meta/recipes-devtools/automake/automake_1.15.bb
+++ b/yocto-poky/meta/recipes-devtools/automake/automake_1.15.bb
@@ -16,11 +16,12 @@
     perl-module-threads \
     perl-module-vars "
 
-RDEPENDS_${PN}_class-native = "autoconf-native perl-native-runtime"
+RDEPENDS_${PN}_class-native = "autoconf-native hostperl-runtime-native"
 
 SRC_URI += " file://python-libdir.patch \
-            file://py-compile-compile-only-optimized-byte-code.patch \
-            file://buildtest.patch"
+            file://buildtest.patch \
+            file://performance.patch \
+            file://new_rt_path_for_test-driver.patch"
 
 SRC_URI[md5sum] = "716946a105ca228ab545fc37a70df3a3"
 SRC_URI[sha256sum] = "7946e945a96e28152ba5a6beb0625ca715c6e32ac55f2e353ef54def0c8ed924"
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils-2.25.1.inc b/yocto-poky/meta/recipes-devtools/binutils/binutils-2.26.inc
similarity index 75%
rename from yocto-poky/meta/recipes-devtools/binutils/binutils-2.25.1.inc
rename to yocto-poky/meta/recipes-devtools/binutils/binutils-2.26.inc
index f3817fa..6d535fc 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils-2.25.1.inc
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils-2.26.inc
@@ -16,7 +16,9 @@
 
 BINUPV = "${@binutils_branch_version(d)}"
 
-SRCREV = "2bd25930221dea4bf33c13a89c111514491440e2"
+UPSTREAM_CHECK_GITTAGREGEX = "binutils-(?P<pver>\d+_(\d_?)*)"
+
+SRCREV = "71fa566a9cf2597b60a58c1d7c148bab637454a6"
 SRC_URI = "\
      git://sourceware.org/git/binutils-gdb.git;branch=binutils-${BINUPV}-branch;protocol=git \
      file://0002-configure-widen-the-regexp-for-SH-architectures.patch \
@@ -26,16 +28,13 @@
      file://0006-Use-libtool-2.4.patch \
      file://0007-Add-the-armv5e-architecture-to-binutils.patch \
      file://0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch \
-     file://0009-Upstream-Status-Inappropriate-distribution-codesourc.patch \
+     file://0009-warn-for-uses-of-system-directories-when-cross-linki.patch \
      file://0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch \
      file://0011-Change-default-emulation-for-mips64-linux.patch \
-     file://0012-Add-XLP-instructions-support.patch \
-     file://0013-Fix-an-internal-error-in-do_print_to_mapfile-seen-wi.patch \
-     file://0014-gold-arm-Skip-pic-check-for-R_ARM_REL32.patch \
-     file://0015-Fix-dynamic-list-so-that-symbols-not-in-the-list-are.patch \
-     file://binutils-octeon3.patch \
-     file://add-thunderx-support-for-gas.patch \
-     "
+     file://0012-Add-support-for-Netlogic-XLP.patch \
+     file://0013-Fix-GOT-address-computations-in-initial-PLT-entries-.patch \
+     file://0014-Correct-nios2-_gp-address-computation.patch \
+"
 S  = "${WORKDIR}/git"
 
 do_configure_prepend () {
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils-cross-canadian_2.25.1.bb b/yocto-poky/meta/recipes-devtools/binutils/binutils-cross-canadian_2.26.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/binutils/binutils-cross-canadian_2.25.1.bb
rename to yocto-poky/meta/recipes-devtools/binutils/binutils-cross-canadian_2.26.bb
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils-cross_2.25.1.bb b/yocto-poky/meta/recipes-devtools/binutils/binutils-cross_2.26.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/binutils/binutils-cross_2.25.1.bb
rename to yocto-poky/meta/recipes-devtools/binutils/binutils-cross_2.26.bb
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils-crosssdk_2.25.1.bb b/yocto-poky/meta/recipes-devtools/binutils/binutils-crosssdk_2.26.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/binutils/binutils-crosssdk_2.25.1.bb
rename to yocto-poky/meta/recipes-devtools/binutils/binutils-crosssdk_2.26.bb
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils.inc b/yocto-poky/meta/recipes-devtools/binutils/binutils.inc
index a304867..43e2aa2 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils.inc
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils.inc
@@ -13,6 +13,12 @@
 
 DEPENDS = "flex-native bison-native zlib-native gnu-config-native autoconf-native"
 
+#
+# we need chrpath > 0.14 and some distros like centos 7 still have older chrpath
+#
+DEPENDS_append_class-target = " chrpath-replacement-native"
+EXTRANATIVEPATH_append_class-target = " chrpath-native"
+
 inherit autotools gettext multilib_header texinfo
 
 FILES_${PN} = " \
@@ -51,6 +57,7 @@
 	strings \
 	strip \
 "
+USE_ALTERNATIVES_FOR_remove_mips = "ld.gold dwp"
 
 python do_package_prepend() {
     make_alts = d.getVar("USE_ALTERNATIVES_FOR", True) or ""
@@ -61,8 +68,6 @@
         d.setVarFlag('ALTERNATIVE_LINK_NAME', alt, bindir + "/" + alt)
 }
 
-# FILES_${PN}-dbg = "${prefix}/${TARGET_SYS}/bin/.debug ${prefix}/${libdir}/.debug"
-
 B = "${S}/build.${HOST_SYS}.${TARGET_SYS}"
 
 EXTRA_OECONF = "--program-prefix=${TARGET_PREFIX} \
@@ -113,6 +118,10 @@
 	done
 }
 
+do_compile_append_class-target() {
+	chrpath -d ${B}/binutils/elfedit
+	chrpath -d ${B}/binutils/readelf
+}
 do_install () {
 	autotools_do_install
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0001-Generate-relocatable-SDKs.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0001-Generate-relocatable-SDKs.patch
index 1e80c1f..91f9017 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0001-Generate-relocatable-SDKs.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0001-Generate-relocatable-SDKs.patch
@@ -1,7 +1,7 @@
-From f71ecf251f84b4bbc9b7a832d5cd4a8bae95d83b Mon Sep 17 00:00:00 2001
+From 3c75355342a8562ccb65b8bbbe81a0495fec5c57 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:58:54 +0000
-Subject: [PATCH 01/13] Generate relocatable SDKs
+Subject: [PATCH 01/14] Generate relocatable SDKs
 
 This patch will modify the ELF linker scripts so that the crosssdk
 linker will generate binaries with a 4096 bytes PT_INTERP section. When the binaries
@@ -18,7 +18,7 @@
  2 files changed, 5 insertions(+), 2 deletions(-)
 
 diff --git a/ld/genscripts.sh b/ld/genscripts.sh
-index 499607a..075dd04 100755
+index a84d233..d12c4e2 100755
 --- a/ld/genscripts.sh
 +++ b/ld/genscripts.sh
 @@ -277,6 +277,7 @@ DATA_ALIGNMENT_u="${DATA_ALIGNMENT_u-${DATA_ALIGNMENT_r}}"
@@ -43,10 +43,10 @@
  LD_FLAG=
  DATA_ALIGNMENT=${DATA_ALIGNMENT_}
 diff --git a/ld/scripttempl/elf.sc b/ld/scripttempl/elf.sc
-index 4368fd9..9f01e8c 100644
+index ec78c90..f9e7a31 100644
 --- a/ld/scripttempl/elf.sc
 +++ b/ld/scripttempl/elf.sc
-@@ -131,8 +131,8 @@ if test -n "${COMMONPAGESIZE}"; then
+@@ -136,8 +136,8 @@ if test -n "${COMMONPAGESIZE}"; then
    DATA_SEGMENT_END=". = DATA_SEGMENT_END (.);"
    DATA_SEGMENT_RELRO_END=". = DATA_SEGMENT_RELRO_END (${SEPARATE_GOTPLT-0}, .);"
  fi
@@ -58,5 +58,5 @@
  if test -z "$PLT"; then
    IPLT=".iplt         ${RELOCATING-0} : { *(.iplt) }"
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0002-configure-widen-the-regexp-for-SH-architectures.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0002-configure-widen-the-regexp-for-SH-architectures.patch
index 34e21d1..4a202d0 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0002-configure-widen-the-regexp-for-SH-architectures.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0002-configure-widen-the-regexp-for-SH-architectures.patch
@@ -1,7 +1,7 @@
-From dfbcfb0d71765b337e63562299a943043928d2d2 Mon Sep 17 00:00:00 2001
+From b1ae604880562ed065f614a745d3f8922838bc5a Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:07:33 +0000
-Subject: [PATCH 02/13] configure: widen the regexp for SH architectures
+Subject: [PATCH 02/14] configure: widen the regexp for SH architectures
 
 gprof needs to know about uclibc
 
@@ -14,10 +14,10 @@
  2 files changed, 7 insertions(+), 2 deletions(-)
 
 diff --git a/configure b/configure
-index 87677bc..e9f2f13 100755
+index 34b66f7..85414ab 100755
 --- a/configure
 +++ b/configure
-@@ -3341,7 +3341,7 @@ case "${target}" in
+@@ -3445,7 +3445,7 @@ case "${target}" in
      ;;
    s390-*-* | s390x-*-*)
      ;;
@@ -26,7 +26,7 @@
      ;;
    sh64-*-* | sh5*-*-*)
      ;;
-@@ -3812,7 +3812,7 @@ case "${target}" in
+@@ -3939,7 +3939,7 @@ case "${target}" in
    or1k*-*-*)
      noconfigdirs="$noconfigdirs gdb"
      ;;
@@ -36,7 +36,7 @@
        sh*-*-elf)
           ;;
 diff --git a/gprof/configure b/gprof/configure
-index b09c8fb..79961c5 100755
+index 693b927..d4db554 100755
 --- a/gprof/configure
 +++ b/gprof/configure
 @@ -5869,6 +5869,11 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu)
@@ -52,5 +52,5 @@
    if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
      lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0003-Point-scripts-location-to-libdir.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0003-Point-scripts-location-to-libdir.patch
index f5ce767..2c70ecd 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0003-Point-scripts-location-to-libdir.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0003-Point-scripts-location-to-libdir.patch
@@ -1,7 +1,7 @@
-From dfb1412da67bbfe3e993d107d0b5e392f44141ab Mon Sep 17 00:00:00 2001
+From 01808e8ef8ee709c8218d962601c18a63a063a1f Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:09:58 +0000
-Subject: [PATCH 03/13] Point scripts location to libdir
+Subject: [PATCH 03/14] Point scripts location to libdir
 
 Upstream-Status: Inappropriate [debian patch]
 
@@ -12,10 +12,10 @@
  2 files changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/ld/Makefile.am b/ld/Makefile.am
-index 9575f1f..84df0bf 100644
+index 0b3b049..3871c74 100644
 --- a/ld/Makefile.am
 +++ b/ld/Makefile.am
-@@ -54,7 +54,7 @@ endif
+@@ -57,7 +57,7 @@ endif
  # 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.
@@ -25,10 +25,10 @@
  EMUL = @EMUL@
  EMULATION_OFILES = @EMULATION_OFILES@
 diff --git a/ld/Makefile.in b/ld/Makefile.in
-index 9f56ca1..272860f 100644
+index ed98f87..530e4c9 100644
 --- a/ld/Makefile.in
 +++ b/ld/Makefile.in
-@@ -388,7 +388,7 @@ AM_CFLAGS = $(WARN_CFLAGS)
+@@ -413,7 +413,7 @@ AM_CFLAGS = $(WARN_CFLAGS) $(ELF_CLFAGS)
  # 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.
@@ -38,5 +38,5 @@
  BFDDIR = $(BASEDIR)/bfd
  INCDIR = $(BASEDIR)/include
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0004-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0004-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch
index e3cd2a4..8f0a402 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0004-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0004-Only-generate-an-RPATH-entry-if-LD_RUN_PATH-is-not-e.patch
@@ -1,7 +1,7 @@
-From 3126608b8c95a792ade56cf62a531d935d391c50 Mon Sep 17 00:00:00 2001
+From c008c7f97c1cf487749c6c375820a1f3b3c6c53d Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:27:17 +0000
-Subject: [PATCH 04/13] Only generate an RPATH entry if LD_RUN_PATH is not
+Subject: [PATCH 04/14] Only generate an RPATH entry if LD_RUN_PATH is not
  empty
 
 for cases where -rpath isn't specified. debian (#151024)
@@ -15,10 +15,10 @@
  1 file changed, 4 insertions(+)
 
 diff --git a/ld/emultempl/elf32.em b/ld/emultempl/elf32.em
-index 36dee8e..07bea52 100644
+index 0405d4f..73c5447 100644
 --- a/ld/emultempl/elf32.em
 +++ b/ld/emultempl/elf32.em
-@@ -1198,6 +1198,8 @@ fragment <<EOF
+@@ -1242,6 +1242,8 @@ fragment <<EOF
  	      && command_line.rpath == NULL)
  	    {
  	      lib_path = (const char *) getenv ("LD_RUN_PATH");
@@ -27,7 +27,7 @@
  	      if (gld${EMULATION_NAME}_search_needed (lib_path, &n,
  						      force))
  		break;
-@@ -1461,6 +1463,8 @@ gld${EMULATION_NAME}_before_allocation (void)
+@@ -1523,6 +1525,8 @@ gld${EMULATION_NAME}_before_allocation (void)
    rpath = command_line.rpath;
    if (rpath == NULL)
      rpath = (const char *) getenv ("LD_RUN_PATH");
@@ -37,5 +37,5 @@
    for (abfd = link_info.input_bfds; abfd; abfd = abfd->link.next)
      if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0005-Explicitly-link-with-libm-on-uclibc.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0005-Explicitly-link-with-libm-on-uclibc.patch
index 9bbd93e..92ead7f 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0005-Explicitly-link-with-libm-on-uclibc.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0005-Explicitly-link-with-libm-on-uclibc.patch
@@ -1,7 +1,7 @@
-From f1703bcc7a5c507e471e2630b5a2de129100315a Mon Sep 17 00:00:00 2001
+From 6a41635e29c4a6c064b1f66e79a8fe2026f4361b Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:32:49 +0000
-Subject: [PATCH 05/13] Explicitly link with libm on uclibc
+Subject: [PATCH 05/14] Explicitly link with libm on uclibc
 
 Description:
 
@@ -31,10 +31,10 @@
  1 file changed, 6 insertions(+)
 
 diff --git a/gas/configure.tgt b/gas/configure.tgt
-index 9abc768..1d92f55 100644
+index 0b490d4..086e0d2 100644
 --- a/gas/configure.tgt
 +++ b/gas/configure.tgt
-@@ -477,6 +477,12 @@ case ${generic_target} in
+@@ -487,6 +487,12 @@ case ${generic_target} in
    *-*-netware)				fmt=elf em=netware ;;
  esac
  
@@ -48,5 +48,5 @@
    aarch64 | alpha | arm | i386 | ia64 | microblaze | mips | ns32k | or1k | or1knd | pdp11 | ppc | sparc | z80 | z8k)
      bfd_gas=yes
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0006-Use-libtool-2.4.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0006-Use-libtool-2.4.patch
index 62967ef..e54ab1b 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0006-Use-libtool-2.4.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0006-Use-libtool-2.4.patch
@@ -1,35 +1,36 @@
-From 03eb9b4fe583e88a22fd8c25b43fbd9bafe21af6 Mon Sep 17 00:00:00 2001
+From da70f0876cdd8ed703d9ed1524212ccfefb09ef3 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 2 Mar 2015 01:34:41 +0000
-Subject: [PATCH 06/13] Use libtool 2.4
+Date: Sun, 14 Feb 2016 17:04:07 +0000
+Subject: [PATCH 06/14] Use libtool 2.4
 
-So we can get libtool sysroot support
-
-Upstream-Status: Pending
+get libtool sysroot support
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
- bfd/configure        | 1320 +++++++++++++++++------
+Upstream-Status: Pending
+
+ bfd/configure        | 1322 +++++++++++++++++------
  bfd/configure.ac     |    2 +-
- binutils/configure   | 1318 +++++++++++++++++------
- configure            |    2 +-
- gas/configure        | 1318 +++++++++++++++++------
- gprof/configure      | 1323 +++++++++++++++++------
- ld/configure         | 1701 +++++++++++++++++++++--------
- libtool.m4           | 1086 +++++++++++++------
+ binutils/configure   | 1320 +++++++++++++++++------
+ configure            |    4 +-
+ gas/configure        | 1320 +++++++++++++++++------
+ gprof/configure      | 1325 +++++++++++++++++------
+ ld/configure         | 1695 +++++++++++++++++++++--------
+ libtool.m4           | 1080 +++++++++++++------
  ltmain.sh            | 2925 +++++++++++++++++++++++++++++++++-----------------
  ltoptions.m4         |    2 +-
  ltversion.m4         |   12 +-
  lt~obsolete.m4       |    2 +-
- opcodes/configure    | 1320 +++++++++++++++++------
+ opcodes/configure    | 1322 +++++++++++++++++------
  opcodes/configure.ac |    2 +-
- 14 files changed, 8952 insertions(+), 3381 deletions(-)
+ zlib/configure       | 1320 +++++++++++++++++------
+ 15 files changed, 9944 insertions(+), 3709 deletions(-)
 
 diff --git a/bfd/configure b/bfd/configure
-index 85e6b82..3d3dd88 100755
+index 7411c6d..eae743e 100755
 --- a/bfd/configure
 +++ b/bfd/configure
-@@ -668,6 +668,9 @@ OTOOL
+@@ -670,6 +670,9 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -39,7 +40,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -780,6 +783,7 @@ enable_static
+@@ -782,6 +785,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -47,7 +48,7 @@
  enable_libtool_lock
  enable_plugins
  enable_largefile
-@@ -1456,6 +1460,8 @@ Optional Packages:
+@@ -1458,6 +1462,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
@@ -56,7 +57,7 @@
    --with-mmap             try using mmap for BFD input files if available
    --with-separate-debug-dir=DIR
                            Look for global separate debug info in DIR
-@@ -5386,8 +5392,8 @@ esac
+@@ -5388,8 +5394,8 @@ esac
  
  
  
@@ -67,7 +68,7 @@
  
  
  
-@@ -5427,7 +5433,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -5429,7 +5435,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -76,7 +77,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -6113,8 +6119,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -6115,8 +6121,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -87,7 +88,7 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -6163,6 +6169,80 @@ esac
+@@ -6165,6 +6171,80 @@ esac
  
  
  
@@ -168,7 +169,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
  if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -6179,6 +6259,11 @@ case $reload_flag in
+@@ -6181,6 +6261,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -180,7 +181,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -6347,7 +6432,8 @@ mingw* | pw32*)
+@@ -6349,7 +6434,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -190,7 +191,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -6501,6 +6587,21 @@ esac
+@@ -6503,6 +6589,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -212,7 +213,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -6516,9 +6617,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -6518,9 +6619,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
  
  
  
@@ -377,7 +378,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
  if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -6534,7 +6788,7 @@ do
+@@ -6536,7 +6790,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
    if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
@@ -386,7 +387,7 @@
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6554,11 +6808,15 @@ $as_echo "no" >&6; }
+@@ -6556,11 +6810,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -405,7 +406,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
  if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6574,7 +6832,7 @@ do
+@@ -6576,7 +6834,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
    if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
@@ -414,7 +415,7 @@
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6593,6 +6851,10 @@ else
+@@ -6595,6 +6853,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -425,7 +426,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6604,16 +6866,72 @@ ac_tool_warned=yes ;;
+@@ -6606,16 +6868,72 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -502,7 +503,7 @@
  
  
  
-@@ -6955,8 +7273,8 @@ esac
+@@ -6957,8 +7275,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -513,7 +514,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -6992,6 +7310,7 @@ for ac_symprfx in "" "_"; do
+@@ -6994,6 +7312,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -521,7 +522,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -7033,6 +7352,18 @@ _LT_EOF
+@@ -7035,6 +7354,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -540,7 +541,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -7044,7 +7375,7 @@ _LT_EOF
+@@ -7046,7 +7377,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -549,7 +550,7 @@
    const char *name;
    void       *address;
  }
-@@ -7070,8 +7401,8 @@ static const void *lt_preloaded_setup() {
+@@ -7072,8 +7403,8 @@ static const void *lt_preloaded_setup() {
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -560,7 +561,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -7081,8 +7412,8 @@ _LT_EOF
+@@ -7083,8 +7414,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -571,7 +572,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -7119,6 +7450,16 @@ else
+@@ -7121,6 +7452,16 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -588,7 +589,7 @@
  
  
  
-@@ -7140,6 +7481,45 @@ fi
+@@ -7142,6 +7483,45 @@ fi
  
  
  
@@ -634,7 +635,7 @@
  # Check whether --enable-libtool-lock was given.
  if test "${enable_libtool_lock+set}" = set; then :
    enableval=$enable_libtool_lock;
-@@ -7346,6 +7726,123 @@ esac
+@@ -7348,6 +7728,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -758,7 +759,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -7909,6 +8406,8 @@ _LT_EOF
+@@ -7911,6 +8408,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -767,7 +768,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -8073,7 +8572,8 @@ fi
+@@ -8075,7 +8574,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -777,7 +778,7 @@
  
  
  
-@@ -8162,7 +8662,7 @@ aix3*)
+@@ -8164,7 +8664,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -786,7 +787,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -8460,8 +8960,6 @@ fi
+@@ -8462,8 +8962,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -795,7 +796,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8627,6 +9125,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8629,6 +9127,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -808,7 +809,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8689,7 +9193,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8691,7 +9195,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -817,7 +818,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -8746,13 +9250,17 @@ case $host_os in
+@@ -8748,13 +9252,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -841,7 +842,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -8813,6 +9321,11 @@ fi
+@@ -8815,6 +9323,11 @@ fi
  
  
  
@@ -853,7 +854,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -9163,7 +9676,8 @@ _LT_EOF
+@@ -9165,7 +9678,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -863,16 +864,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -9211,7 +9725,7 @@ _LT_EOF
-       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- 	 && test "$tmp_diet" = no
-       then
--	tmp_addflag=
-+	tmp_addflag=' $pic_flag'
- 	tmp_sharedflag='-shared'
- 	case $cc_basename,$host_cpu in
-         pgcc*)				# Portland Group C compiler
-@@ -9262,12 +9776,12 @@ _LT_EOF
+@@ -9264,12 +9778,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -887,7 +879,7 @@
  	  fi
  	  ;;
  	esac
-@@ -9281,8 +9795,8 @@ _LT_EOF
+@@ -9283,8 +9797,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -898,7 +890,7 @@
        fi
        ;;
  
-@@ -9300,8 +9814,8 @@ _LT_EOF
+@@ -9302,8 +9816,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -909,7 +901,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9347,8 +9861,8 @@ _LT_EOF
+@@ -9349,8 +9863,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -920,7 +912,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9478,7 +9992,13 @@ _LT_EOF
+@@ -9480,7 +9994,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -935,7 +927,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -9491,22 +10011,29 @@ main ()
+@@ -9493,22 +10013,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -978,7 +970,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9518,7 +10045,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9520,7 +10047,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -993,7 +985,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -9531,22 +10064,29 @@ main ()
+@@ -9533,22 +10066,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -1036,7 +1028,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9591,20 +10131,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9593,20 +10133,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
        # no search path for DLLs.
@@ -1114,7 +1106,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9665,7 +10248,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9667,7 +10250,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -1123,7 +1115,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9673,7 +10256,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9675,7 +10258,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -1132,7 +1124,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9689,7 +10272,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9691,7 +10274,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -1141,7 +1133,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -9713,10 +10296,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9715,10 +10298,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -1154,7 +1146,7 @@
  	  ;;
  	esac
        else
-@@ -9795,23 +10378,36 @@ fi
+@@ -9797,23 +10380,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -1199,7 +1191,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -9896,7 +10492,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9898,7 +10494,7 @@ rm -f core conftest.err conftest.$ac_objext \
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -1208,7 +1200,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -9915,9 +10511,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9917,9 +10513,9 @@ rm -f core conftest.err conftest.$ac_objext \
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -1220,7 +1212,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -10493,8 +11089,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10495,8 +11091,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -1232,7 +1224,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10527,13 +11124,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10529,13 +11126,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -1305,7 +1297,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10625,7 +11280,7 @@ haiku*)
+@@ -10627,7 +11282,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -1314,7 +1306,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -11465,10 +12120,10 @@ else
+@@ -11423,7 +12078,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11426 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11467,10 +12122,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -1327,7 +1328,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11571,10 +12226,10 @@ else
+@@ -11529,7 +12184,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11532 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11573,10 +12228,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -1340,7 +1350,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -15163,7 +15818,7 @@ SHARED_LDFLAGS=
+@@ -15121,7 +15776,7 @@ SHARED_LDFLAGS=
  if test "$enable_shared" = "yes"; then
    x=`sed -n -e 's/^[ 	]*PICFLAG[ 	]*=[ 	]*//p' < ../libiberty/Makefile | sed -n '$p'`
    if test -n "$x"; then
@@ -1349,7 +1359,7 @@
    fi
  
  # More hacks to build DLLs on Windows.
-@@ -16780,13 +17435,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -16746,13 +17401,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -1370,7 +1380,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -16801,14 +17463,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -16767,14 +17429,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -1389,7 +1399,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -16841,12 +17506,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -16807,12 +17472,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -1403,7 +1413,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -16901,8 +17566,13 @@ reload_flag \
+@@ -16867,8 +17532,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -1417,7 +1427,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -16912,12 +17582,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -16878,12 +17548,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -1433,7 +1443,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -16933,7 +17605,6 @@ no_undefined_flag \
+@@ -16899,7 +17571,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -1441,7 +1451,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -16969,6 +17640,7 @@ module_cmds \
+@@ -16935,6 +17606,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -1449,7 +1459,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -17748,7 +18420,8 @@ $as_echo X"$file" |
+@@ -17714,7 +18386,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -1459,7 +1469,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -17851,19 +18524,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -17817,19 +18490,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -1503,7 +1513,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -17893,6 +18589,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -17859,6 +18555,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -1516,7 +1526,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -17902,6 +18604,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -17868,6 +18570,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -1526,7 +1536,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -18016,12 +18721,12 @@ with_gcc=$GCC
+@@ -17982,12 +18687,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -1542,7 +1552,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -18108,9 +18813,6 @@ inherit_rpath=$inherit_rpath
+@@ -18074,9 +18779,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -1552,7 +1562,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -18126,6 +18828,9 @@ include_expsyms=$lt_include_expsyms
+@@ -18092,6 +18794,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -1562,7 +1572,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -18158,210 +18863,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -18124,210 +18829,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -1937,10 +1947,10 @@
    chmod +x "$ofile"
  
 diff --git a/bfd/configure.ac b/bfd/configure.ac
-index ba98e39..88063cf 100644
+index 6f5e85f..44bd02c 100644
 --- a/bfd/configure.ac
 +++ b/bfd/configure.ac
-@@ -564,7 +564,7 @@ changequote(,)dnl
+@@ -567,7 +567,7 @@ changequote(,)dnl
    x=`sed -n -e 's/^[ 	]*PICFLAG[ 	]*=[ 	]*//p' < ../libiberty/Makefile | sed -n '$p'`
  changequote([,])dnl
    if test -n "$x"; then
@@ -1950,10 +1960,10 @@
  
  # More hacks to build DLLs on Windows.
 diff --git a/binutils/configure b/binutils/configure
-index be4b81c..6606a5f 100755
+index d4f3e1e..a6df5bb 100755
 --- a/binutils/configure
 +++ b/binutils/configure
-@@ -655,8 +655,11 @@ OTOOL
+@@ -657,8 +657,11 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -1965,7 +1975,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -767,6 +770,7 @@ enable_static
+@@ -769,6 +772,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -1973,16 +1983,16 @@
  enable_libtool_lock
  enable_plugins
  enable_largefile
-@@ -1439,6 +1443,8 @@ Optional Packages:
+@@ -1441,6 +1445,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
 +  --with-libtool-sysroot=DIR Search for dependent libraries within DIR
 +                        (or the compiler's sysroot if not specified).
-   --with-zlib             include zlib support (auto/yes/no) default=auto
+   --with-system-zlib      use installed libz
    --with-gnu-ld           assume the C compiler uses GNU ld default=no
    --with-libiconv-prefix[=DIR]  search for libiconv in DIR/include and DIR/lib
-@@ -5153,8 +5159,8 @@ esac
+@@ -5155,8 +5161,8 @@ esac
  
  
  
@@ -1993,7 +2003,7 @@
  
  
  
-@@ -5194,7 +5200,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -5196,7 +5202,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -2002,7 +2012,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -5880,8 +5886,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -5882,8 +5888,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -2013,7 +2023,7 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -5930,6 +5936,80 @@ esac
+@@ -5932,6 +5938,80 @@ esac
  
  
  
@@ -2094,7 +2104,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
  if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -5946,6 +6026,11 @@ case $reload_flag in
+@@ -5948,6 +6028,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -2106,7 +2116,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -6114,7 +6199,8 @@ mingw* | pw32*)
+@@ -6116,7 +6201,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -2116,7 +2126,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -6268,6 +6354,21 @@ esac
+@@ -6270,6 +6356,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -2138,7 +2148,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -6283,9 +6384,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -6285,9 +6386,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
  
  
  
@@ -2152,9 +2162,7 @@
 +
 +
 +
- if test -n "$ac_tool_prefix"; then
--  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
--set dummy ${ac_tool_prefix}ar; ac_word=$2
++if test -n "$ac_tool_prefix"; then
 +  # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
 +set dummy ${ac_tool_prefix}dlltool; ac_word=$2
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
@@ -2295,7 +2303,9 @@
 +
 +
 +
-+if test -n "$ac_tool_prefix"; then
+ if test -n "$ac_tool_prefix"; then
+-  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
+-set dummy ${ac_tool_prefix}ar; ac_word=$2
 +  for ac_prog in ar
 +  do
 +    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
@@ -2303,7 +2313,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
  if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -6301,7 +6555,7 @@ do
+@@ -6303,7 +6557,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
    if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
@@ -2312,7 +2322,7 @@
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6321,11 +6575,15 @@ $as_echo "no" >&6; }
+@@ -6323,11 +6577,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -2331,7 +2341,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
  if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6341,7 +6599,7 @@ do
+@@ -6343,7 +6601,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
    if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
@@ -2340,7 +2350,7 @@
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6360,6 +6618,10 @@ else
+@@ -6362,6 +6620,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -2351,7 +2361,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6371,16 +6633,72 @@ ac_tool_warned=yes ;;
+@@ -6373,12 +6635,10 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -2363,17 +2373,13 @@
 -test -z "$AR_FLAGS" && AR_FLAGS=cru
 +: ${AR=ar}
 +: ${AR_FLAGS=cru}
-+
-+
-+
-+
-+
-+
-+
-+
-+
-+
-+
+ 
+ 
+ 
+@@ -6390,6 +6650,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
+ 
+ 
+ 
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
 +$as_echo_n "checking for archiver @FILE support... " >&6; }
 +if test "${lt_cv_ar_at_file+set}" = set; then :
@@ -2386,7 +2392,7 @@
 +int
 +main ()
 +{
- 
++
 +  ;
 +  return 0;
 +}
@@ -2412,23 +2418,30 @@
 +        fi
 +      fi
 +      rm -f conftest.* libconftest.a
- 
++
 +fi
 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- 
++
 +fi
 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
 +$as_echo "$lt_cv_ar_at_file" >&6; }
- 
++
 +if test "x$lt_cv_ar_at_file" = xno; then
 +  archiver_list_spec=
 +else
 +  archiver_list_spec=$lt_cv_ar_at_file
 +fi
- 
- 
- 
-@@ -6722,8 +7040,8 @@ esac
++
++
++
++
++
++
++
+ if test -n "$ac_tool_prefix"; then
+   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
+ set dummy ${ac_tool_prefix}strip; ac_word=$2
+@@ -6724,8 +7042,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -2439,7 +2452,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -6759,6 +7077,7 @@ for ac_symprfx in "" "_"; do
+@@ -6761,6 +7079,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -2447,7 +2460,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -6800,6 +7119,18 @@ _LT_EOF
+@@ -6802,6 +7121,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -2466,7 +2479,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -6811,7 +7142,7 @@ _LT_EOF
+@@ -6813,7 +7144,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -2475,7 +2488,7 @@
    const char *name;
    void       *address;
  }
-@@ -6837,8 +7168,8 @@ static const void *lt_preloaded_setup() {
+@@ -6839,8 +7170,8 @@ static const void *lt_preloaded_setup() {
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -2486,7 +2499,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -6848,8 +7179,8 @@ _LT_EOF
+@@ -6850,8 +7181,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -2497,7 +2510,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -6886,6 +7217,20 @@ else
+@@ -6888,6 +7219,21 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -2515,10 +2528,11 @@
 +
 +
 +
++
  
  
  
-@@ -6905,6 +7250,41 @@ fi
+@@ -6906,6 +7252,40 @@ fi
  
  
  
@@ -2556,11 +2570,10 @@
 +$as_echo "${lt_sysroot:-no}" >&6; }
 +
 +
-+
  
  
- # Check whether --enable-libtool-lock was given.
-@@ -7113,6 +7493,123 @@ esac
+ 
+@@ -7115,6 +7495,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -2684,7 +2697,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -7676,6 +8173,8 @@ _LT_EOF
+@@ -7678,6 +8175,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -2693,7 +2706,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -7871,7 +8370,8 @@ fi
+@@ -7873,7 +8372,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -2703,7 +2716,7 @@
  
  
  
-@@ -7960,7 +8460,7 @@ aix3*)
+@@ -7962,7 +8462,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -2712,7 +2725,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -8258,8 +8758,6 @@ fi
+@@ -8260,8 +8760,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -2721,7 +2734,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8425,6 +8923,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8427,6 +8925,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -2734,7 +2747,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8487,7 +8991,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8489,7 +8993,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -2743,7 +2756,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -8544,13 +9048,17 @@ case $host_os in
+@@ -8546,13 +9050,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -2767,7 +2780,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -8611,6 +9119,11 @@ fi
+@@ -8613,6 +9121,11 @@ fi
  
  
  
@@ -2779,7 +2792,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -8961,7 +9474,8 @@ _LT_EOF
+@@ -8963,7 +9476,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -2789,16 +2802,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -9009,7 +9523,7 @@ _LT_EOF
-       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- 	 && test "$tmp_diet" = no
-       then
--	tmp_addflag=
-+	tmp_addflag=' $pic_flag'
- 	tmp_sharedflag='-shared'
- 	case $cc_basename,$host_cpu in
-         pgcc*)				# Portland Group C compiler
-@@ -9060,12 +9574,12 @@ _LT_EOF
+@@ -9062,12 +9576,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -2813,7 +2817,7 @@
  	  fi
  	  ;;
  	esac
-@@ -9079,8 +9593,8 @@ _LT_EOF
+@@ -9081,8 +9595,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -2824,7 +2828,7 @@
        fi
        ;;
  
-@@ -9098,8 +9612,8 @@ _LT_EOF
+@@ -9100,8 +9614,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -2835,7 +2839,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9145,8 +9659,8 @@ _LT_EOF
+@@ -9147,8 +9661,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -2846,7 +2850,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9276,7 +9790,13 @@ _LT_EOF
+@@ -9278,7 +9792,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -2861,7 +2865,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -9289,22 +9809,29 @@ main ()
+@@ -9291,22 +9811,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -2904,7 +2908,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9316,7 +9843,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9318,7 +9845,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -2919,7 +2923,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -9329,22 +9862,29 @@ main ()
+@@ -9331,22 +9864,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -2962,7 +2966,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9389,20 +9929,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9391,20 +9931,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
        # no search path for DLLs.
@@ -3040,7 +3044,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9463,7 +10046,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9465,7 +10048,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -3049,7 +3053,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9471,7 +10054,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9473,7 +10056,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -3058,7 +3062,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9487,7 +10070,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9489,7 +10072,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -3067,7 +3071,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -9511,10 +10094,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9513,10 +10096,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -3080,7 +3084,7 @@
  	  ;;
  	esac
        else
-@@ -9593,23 +10176,36 @@ fi
+@@ -9595,23 +10178,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -3125,7 +3129,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -9694,7 +10290,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9696,7 +10292,7 @@ rm -f core conftest.err conftest.$ac_objext \
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -3134,7 +3138,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -9713,9 +10309,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9715,9 +10311,9 @@ rm -f core conftest.err conftest.$ac_objext \
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -3146,7 +3150,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -10291,8 +10887,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10293,8 +10889,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -3158,7 +3162,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10325,13 +10922,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10327,13 +10924,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -3231,7 +3235,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10423,7 +11078,7 @@ haiku*)
+@@ -10425,7 +11080,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -3240,7 +3244,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -11263,10 +11918,10 @@ else
+@@ -11221,7 +11876,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11224 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11265,10 +11920,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -3253,7 +3266,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11369,10 +12024,10 @@ else
+@@ -11327,7 +11982,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11330 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11371,10 +12026,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -3266,7 +3288,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -15373,13 +16028,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -15355,13 +16010,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -3287,7 +3309,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -15394,14 +16056,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -15376,14 +16038,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -3306,7 +3328,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -15434,12 +16099,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -15416,12 +16081,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -3320,7 +3342,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -15494,8 +16159,13 @@ reload_flag \
+@@ -15476,8 +16141,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -3334,7 +3356,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -15505,12 +16175,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -15487,12 +16157,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -3350,7 +3372,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -15526,7 +16198,6 @@ no_undefined_flag \
+@@ -15508,7 +16180,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -3358,7 +3380,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -15562,6 +16233,7 @@ module_cmds \
+@@ -15544,6 +16215,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -3366,7 +3388,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -16319,7 +16991,8 @@ $as_echo X"$file" |
+@@ -16301,7 +16973,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -3376,7 +3398,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -16422,19 +17095,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -16404,19 +17077,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -3420,7 +3442,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -16464,6 +17160,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -16446,6 +17142,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -3433,7 +3455,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -16473,6 +17175,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -16455,6 +17157,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -3443,7 +3465,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -16587,12 +17292,12 @@ with_gcc=$GCC
+@@ -16569,12 +17274,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -3459,7 +3481,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -16679,9 +17384,6 @@ inherit_rpath=$inherit_rpath
+@@ -16661,9 +17366,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -3469,7 +3491,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -16697,6 +17399,9 @@ include_expsyms=$lt_include_expsyms
+@@ -16679,6 +17381,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -3479,7 +3501,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -16729,210 +17434,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -16711,210 +17416,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -3854,23 +3876,32 @@
    chmod +x "$ofile"
  
 diff --git a/configure b/configure
-index e9f2f13..cbccb18 100755
+index 85414ab..34b66f7 100755
 --- a/configure
 +++ b/configure
-@@ -8041,7 +8041,7 @@ case " $build_configdirs " in
-     # For an installed makeinfo, we require it to be from texinfo 4.7 or
-     # higher, else we use the "missing" dummy.
-     if ${MAKEINFO} --version \
--       | egrep 'texinfo[^0-9]*(4\.([7-9]|[1-9][0-9])|[5-9]|[1-9][0-9])' >/dev/null 2>&1; then
-+       | egrep 'texinfo[^0-9]*([1-3][0-9]|4.[4-9]|4.[1-9][0-9]+|[5-9])' >/dev/null 2>&1; then
-       :
-     else
-       MAKEINFO="$MISSING makeinfo"
+@@ -3445,7 +3445,7 @@ case "${target}" in
+     ;;
+   s390-*-* | s390x-*-*)
+     ;;
+-  sh*-*-* | sh[34]*-*-*)
++  sh-*-* | sh[34]*-*-*)
+     ;;
+   sh64-*-* | sh5*-*-*)
+     ;;
+@@ -3939,7 +3939,7 @@ case "${target}" in
+   or1k*-*-*)
+     noconfigdirs="$noconfigdirs gdb"
+     ;;
+-  sh*-*-* | sh64-*-*)
++  sh-*-* | sh64-*-*)
+     case "${target}" in
+       sh*-*-elf)
+          ;;
 diff --git a/gas/configure b/gas/configure
-index e9ba550..074886f 100755
+index dd9c953..89f18b3 100755
 --- a/gas/configure
 +++ b/gas/configure
-@@ -645,8 +645,11 @@ OTOOL
+@@ -647,8 +647,11 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -3882,7 +3913,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -757,6 +760,7 @@ enable_static
+@@ -759,6 +762,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -3890,16 +3921,16 @@
  enable_libtool_lock
  enable_plugins
  enable_largefile
-@@ -1422,6 +1426,8 @@ Optional Packages:
+@@ -1430,6 +1434,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
 +  --with-libtool-sysroot=DIR Search for dependent libraries within DIR
 +                        (or the compiler's sysroot if not specified).
-   --with-zlib             include zlib support (auto/yes/no) default=auto
+   --with-system-zlib      use installed libz
  
  Some influential environment variables:
-@@ -4901,8 +4907,8 @@ esac
+@@ -4909,8 +4915,8 @@ esac
  
  
  
@@ -3910,7 +3941,7 @@
  
  
  
-@@ -4942,7 +4948,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -4950,7 +4956,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -3919,7 +3950,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -5628,8 +5634,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -5636,8 +5642,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -3930,7 +3961,7 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -5678,6 +5684,80 @@ esac
+@@ -5686,6 +5692,80 @@ esac
  
  
  
@@ -4011,7 +4042,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
  if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -5694,6 +5774,11 @@ case $reload_flag in
+@@ -5702,6 +5782,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -4023,7 +4054,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -5862,7 +5947,8 @@ mingw* | pw32*)
+@@ -5870,7 +5955,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -4033,7 +4064,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -6016,6 +6102,21 @@ esac
+@@ -6024,6 +6110,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -4055,7 +4086,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -6031,9 +6132,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -6039,9 +6140,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
  
  
  
@@ -4220,7 +4251,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
  if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -6049,7 +6303,7 @@ do
+@@ -6057,7 +6311,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
    if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
@@ -4229,7 +4260,7 @@
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6069,11 +6323,15 @@ $as_echo "no" >&6; }
+@@ -6077,11 +6331,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -4248,7 +4279,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
  if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6089,7 +6347,7 @@ do
+@@ -6097,7 +6355,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
    if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
@@ -4257,7 +4288,7 @@
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6108,6 +6366,10 @@ else
+@@ -6116,6 +6374,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -4268,7 +4299,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6119,12 +6381,10 @@ ac_tool_warned=yes ;;
+@@ -6127,12 +6389,10 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -4283,7 +4314,7 @@
  
  
  
-@@ -6136,6 +6396,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
+@@ -6144,6 +6404,64 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
  
  
  
@@ -4348,7 +4379,7 @@
  if test -n "$ac_tool_prefix"; then
    # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
  set dummy ${ac_tool_prefix}strip; ac_word=$2
-@@ -6470,8 +6788,8 @@ esac
+@@ -6478,8 +6796,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -4359,7 +4390,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -6507,6 +6825,7 @@ for ac_symprfx in "" "_"; do
+@@ -6515,6 +6833,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -4367,7 +4398,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -6548,6 +6867,18 @@ _LT_EOF
+@@ -6556,6 +6875,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -4386,7 +4417,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -6559,7 +6890,7 @@ _LT_EOF
+@@ -6567,7 +6898,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -4395,7 +4426,7 @@
    const char *name;
    void       *address;
  }
-@@ -6585,8 +6916,8 @@ static const void *lt_preloaded_setup() {
+@@ -6593,8 +6924,8 @@ static const void *lt_preloaded_setup() {
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -4406,7 +4437,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -6596,8 +6927,8 @@ _LT_EOF
+@@ -6604,8 +6935,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -4417,7 +4448,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -6634,6 +6965,21 @@ else
+@@ -6642,6 +6973,21 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -4439,7 +4470,7 @@
  
  
  
-@@ -6652,6 +6998,40 @@ fi
+@@ -6660,6 +7006,40 @@ fi
  
  
  
@@ -4480,7 +4511,7 @@
  
  
  
-@@ -6861,6 +7241,123 @@ esac
+@@ -6869,6 +7249,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -4604,7 +4635,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -7424,6 +7921,8 @@ _LT_EOF
+@@ -7432,6 +7929,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -4613,7 +4644,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -7619,7 +8118,8 @@ fi
+@@ -7627,7 +8126,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -4623,7 +4654,7 @@
  
  
  
-@@ -7708,7 +8208,7 @@ aix3*)
+@@ -7716,7 +8216,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -4632,7 +4663,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -8006,8 +8506,6 @@ fi
+@@ -8014,8 +8514,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -4641,7 +4672,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8173,6 +8671,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8181,6 +8679,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -4654,7 +4685,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8235,7 +8739,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8243,7 +8747,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -4663,7 +4694,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -8292,13 +8796,17 @@ case $host_os in
+@@ -8300,13 +8804,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -4687,7 +4718,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -8359,6 +8867,11 @@ fi
+@@ -8367,6 +8875,11 @@ fi
  
  
  
@@ -4699,7 +4730,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -8709,7 +9222,8 @@ _LT_EOF
+@@ -8717,7 +9230,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -4709,16 +4740,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -8757,7 +9271,7 @@ _LT_EOF
-       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- 	 && test "$tmp_diet" = no
-       then
--	tmp_addflag=
-+	tmp_addflag=' $pic_flag'
- 	tmp_sharedflag='-shared'
- 	case $cc_basename,$host_cpu in
-         pgcc*)				# Portland Group C compiler
-@@ -8808,12 +9322,12 @@ _LT_EOF
+@@ -8816,12 +9330,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -4733,7 +4755,7 @@
  	  fi
  	  ;;
  	esac
-@@ -8827,8 +9341,8 @@ _LT_EOF
+@@ -8835,8 +9349,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -4744,7 +4766,7 @@
        fi
        ;;
  
-@@ -8846,8 +9360,8 @@ _LT_EOF
+@@ -8854,8 +9368,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -4755,7 +4777,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -8893,8 +9407,8 @@ _LT_EOF
+@@ -8901,8 +9415,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -4766,7 +4788,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9024,7 +9538,13 @@ _LT_EOF
+@@ -9032,7 +9546,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -4781,7 +4803,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -9037,22 +9557,29 @@ main ()
+@@ -9045,22 +9565,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -4824,7 +4846,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9064,7 +9591,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9072,7 +9599,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -4839,7 +4861,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -9077,22 +9610,29 @@ main ()
+@@ -9085,22 +9618,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -4882,7 +4904,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9137,20 +9677,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9145,20 +9685,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
        # no search path for DLLs.
@@ -4960,7 +4982,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9211,7 +9794,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9219,7 +9802,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -4969,7 +4991,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9219,7 +9802,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9227,7 +9810,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -4978,7 +5000,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9235,7 +9818,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9243,7 +9826,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -4987,7 +5009,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -9259,10 +9842,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9267,10 +9850,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -5000,7 +5022,7 @@
  	  ;;
  	esac
        else
-@@ -9341,23 +9924,36 @@ fi
+@@ -9349,23 +9932,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -5045,7 +5067,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -9442,7 +10038,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9450,7 +10046,7 @@ rm -f core conftest.err conftest.$ac_objext \
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -5054,7 +5076,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -9461,9 +10057,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -9469,9 +10065,9 @@ rm -f core conftest.err conftest.$ac_objext \
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -5066,7 +5088,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -10039,8 +10635,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10047,8 +10643,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -5078,7 +5100,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10073,13 +10670,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10081,13 +10678,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -5151,7 +5173,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10171,7 +10826,7 @@ haiku*)
+@@ -10179,7 +10834,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -5160,7 +5182,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -11011,10 +11666,10 @@ else
+@@ -10975,7 +11630,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 10978 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11019,10 +11674,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -5173,7 +5204,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11117,10 +11772,10 @@ else
+@@ -11081,7 +11736,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11084 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -11125,10 +11780,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -5186,7 +5226,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -15274,13 +15929,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -15276,13 +15931,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -5207,7 +5247,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -15295,14 +15957,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -15297,14 +15959,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -5226,7 +5266,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -15335,12 +16000,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -15337,12 +16002,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -5240,7 +5280,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -15395,8 +16060,13 @@ reload_flag \
+@@ -15397,8 +16062,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -5254,7 +5294,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -15406,12 +16076,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -15408,12 +16078,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -5270,7 +5310,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -15427,7 +16099,6 @@ no_undefined_flag \
+@@ -15429,7 +16101,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -5278,7 +5318,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -15463,6 +16134,7 @@ module_cmds \
+@@ -15465,6 +16136,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -5286,7 +5326,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -16227,7 +16899,8 @@ $as_echo X"$file" |
+@@ -16229,7 +16901,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -5296,7 +5336,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -16330,19 +17003,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -16332,19 +17005,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -5340,7 +5380,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -16372,6 +17068,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -16374,6 +17070,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -5353,7 +5393,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -16381,6 +17083,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -16383,6 +17085,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -5363,7 +5403,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -16495,12 +17200,12 @@ with_gcc=$GCC
+@@ -16497,12 +17202,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -5379,7 +5419,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -16587,9 +17292,6 @@ inherit_rpath=$inherit_rpath
+@@ -16589,9 +17294,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -5389,7 +5429,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -16605,6 +17307,9 @@ include_expsyms=$lt_include_expsyms
+@@ -16607,6 +17309,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -5399,7 +5439,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -16637,210 +17342,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -16639,210 +17344,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -5774,7 +5814,7 @@
    chmod +x "$ofile"
  
 diff --git a/gprof/configure b/gprof/configure
-index 79961c5..c4f6ac9 100755
+index d4db554..78b292c 100755
 --- a/gprof/configure
 +++ b/gprof/configure
 @@ -629,8 +629,11 @@ OTOOL
@@ -6628,15 +6668,6 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -8692,7 +9201,7 @@ _LT_EOF
-       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- 	 && test "$tmp_diet" = no
-       then
--	tmp_addflag=
-+	tmp_addflag=' $pic_flag'
- 	tmp_sharedflag='-shared'
- 	case $cc_basename,$host_cpu in
-         pgcc*)				# Portland Group C compiler
 @@ -8743,12 +9252,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
@@ -7079,6 +7110,15 @@
    hardcode_into_libs=yes
    ;;
  
+@@ -10902,7 +11552,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 10900 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
 @@ -10946,10 +11596,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
@@ -7092,6 +7132,15 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
+@@ -11008,7 +11658,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11006 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
 @@ -11052,10 +11702,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
@@ -7693,10 +7742,10 @@
    chmod +x "$ofile"
  
 diff --git a/ld/configure b/ld/configure
-index 4408b0d..2fbaebf 100755
+index 8095b71..eb4f0d7 100755
 --- a/ld/configure
 +++ b/ld/configure
-@@ -654,8 +654,11 @@ OTOOL
+@@ -657,8 +657,11 @@ OTOOL
  LIPO
  NMEDIT
  DSYMUTIL
@@ -7708,7 +7757,7 @@
  OBJDUMP
  LN_S
  NM
-@@ -776,6 +779,7 @@ enable_static
+@@ -779,6 +782,7 @@ enable_static
  with_pic
  enable_fast_install
  with_gnu_ld
@@ -7716,7 +7765,7 @@
  enable_libtool_lock
  enable_plugins
  enable_largefile
-@@ -1453,6 +1457,8 @@ Optional Packages:
+@@ -1458,6 +1462,8 @@ Optional Packages:
    --with-pic              try to use only PIC/non-PIC objects [default=use
                            both]
    --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
@@ -7724,8 +7773,8 @@
 +                        (or the compiler's sysroot if not specified).
    --with-lib-path=dir1:dir2...  set default LIB_PATH
    --with-sysroot=DIR Search for usr/lib et al within DIR.
-   --with-zlib             include zlib support (auto/yes/no) default=auto
-@@ -5645,8 +5651,8 @@ esac
+ 
+@@ -5649,8 +5655,8 @@ esac
  
  
  
@@ -7736,7 +7785,7 @@
  
  
  
-@@ -5686,7 +5692,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+@@ -5690,7 +5696,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
  $as_echo_n "checking how to print strings... " >&6; }
  # Test print first, because it will be a builtin if present.
@@ -7745,7 +7794,7 @@
     test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
    ECHO='print -r --'
  elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
-@@ -6372,8 +6378,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+@@ -6376,8 +6382,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
  # Try some XSI features
  xsi_shell=no
  ( _lt_dummy="a/b/c"
@@ -7756,7 +7805,7 @@
      && eval 'test $(( 1 + 1 )) -eq 2 \
      && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
    && xsi_shell=yes
-@@ -6422,6 +6428,80 @@ esac
+@@ -6426,6 +6432,80 @@ esac
  
  
  
@@ -7837,7 +7886,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
  $as_echo_n "checking for $LD option to reload object files... " >&6; }
  if test "${lt_cv_ld_reload_flag+set}" = set; then :
-@@ -6438,6 +6518,11 @@ case $reload_flag in
+@@ -6442,6 +6522,11 @@ case $reload_flag in
  esac
  reload_cmds='$LD$reload_flag -o $output$reload_objs'
  case $host_os in
@@ -7849,7 +7898,7 @@
    darwin*)
      if test "$GCC" = yes; then
        reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
-@@ -6606,7 +6691,8 @@ mingw* | pw32*)
+@@ -6610,7 +6695,8 @@ mingw* | pw32*)
      lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
      lt_cv_file_magic_cmd='func_win32_libid'
    else
@@ -7859,7 +7908,7 @@
      lt_cv_file_magic_cmd='$OBJDUMP -f'
    fi
    ;;
-@@ -6760,6 +6846,21 @@ esac
+@@ -6764,6 +6850,21 @@ esac
  fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
  $as_echo "$lt_cv_deplibs_check_method" >&6; }
@@ -7881,7 +7930,7 @@
  file_magic_cmd=$lt_cv_file_magic_cmd
  deplibs_check_method=$lt_cv_deplibs_check_method
  test -z "$deplibs_check_method" && deplibs_check_method=unknown
-@@ -6775,9 +6876,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -6779,9 +6880,162 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
  
  
  
@@ -8046,7 +8095,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
  if test "${ac_cv_prog_AR+set}" = set; then :
-@@ -6793,7 +7047,7 @@ do
+@@ -6797,7 +7051,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
    if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
@@ -8055,7 +8104,7 @@
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6813,11 +7067,15 @@ $as_echo "no" >&6; }
+@@ -6817,11 +7071,15 @@ $as_echo "no" >&6; }
  fi
  
  
@@ -8074,7 +8123,7 @@
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  $as_echo_n "checking for $ac_word... " >&6; }
  if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
-@@ -6833,7 +7091,7 @@ do
+@@ -6837,7 +7095,7 @@ do
    test -z "$as_dir" && as_dir=.
      for ac_exec_ext in '' $ac_executable_extensions; do
    if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
@@ -8083,7 +8132,7 @@
      $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
      break 2
    fi
-@@ -6852,6 +7110,10 @@ else
+@@ -6856,6 +7114,10 @@ else
  $as_echo "no" >&6; }
  fi
  
@@ -8094,7 +8143,7 @@
    if test "x$ac_ct_AR" = x; then
      AR="false"
    else
-@@ -6863,12 +7125,12 @@ ac_tool_warned=yes ;;
+@@ -6867,12 +7129,12 @@ ac_tool_warned=yes ;;
  esac
      AR=$ac_ct_AR
    fi
@@ -8111,7 +8160,7 @@
  
  
  
-@@ -6878,6 +7140,62 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
+@@ -6882,6 +7144,62 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
  
  
  
@@ -8174,7 +8223,7 @@
  
  
  if test -n "$ac_tool_prefix"; then
-@@ -7214,8 +7532,8 @@ esac
+@@ -7218,8 +7536,8 @@ esac
  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  
  # Transform an extracted symbol line into symbol name and symbol address
@@ -8185,7 +8234,7 @@
  
  # Handle CRLF in mingw tool chain
  opt_cr=
-@@ -7251,6 +7569,7 @@ for ac_symprfx in "" "_"; do
+@@ -7255,6 +7573,7 @@ for ac_symprfx in "" "_"; do
    else
      lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
    fi
@@ -8193,7 +8242,7 @@
  
    # Check to see that the pipe works correctly.
    pipe_works=no
-@@ -7292,6 +7611,18 @@ _LT_EOF
+@@ -7296,6 +7615,18 @@ _LT_EOF
        if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
  	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
  	  cat <<_LT_EOF > conftest.$ac_ext
@@ -8212,7 +8261,7 @@
  #ifdef __cplusplus
  extern "C" {
  #endif
-@@ -7303,7 +7634,7 @@ _LT_EOF
+@@ -7307,7 +7638,7 @@ _LT_EOF
  	  cat <<_LT_EOF >> conftest.$ac_ext
  
  /* The mapping between symbol names and symbols.  */
@@ -8221,7 +8270,7 @@
    const char *name;
    void       *address;
  }
-@@ -7329,8 +7660,8 @@ static const void *lt_preloaded_setup() {
+@@ -7333,8 +7664,8 @@ static const void *lt_preloaded_setup() {
  _LT_EOF
  	  # Now try linking the two files.
  	  mv conftest.$ac_objext conftstm.$ac_objext
@@ -8232,7 +8281,7 @@
  	  LIBS="conftstm.$ac_objext"
  	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
  	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
-@@ -7340,8 +7671,8 @@ _LT_EOF
+@@ -7344,8 +7675,8 @@ _LT_EOF
    test $ac_status = 0; } && test -s conftest${ac_exeext}; then
  	    pipe_works=yes
  	  fi
@@ -8243,7 +8292,7 @@
  	else
  	  echo "cannot find nm_test_func in $nlist" >&5
  	fi
-@@ -7378,6 +7709,19 @@ else
+@@ -7382,6 +7713,19 @@ else
  $as_echo "ok" >&6; }
  fi
  
@@ -8263,7 +8312,7 @@
  
  
  
-@@ -7398,6 +7742,42 @@ fi
+@@ -7402,6 +7746,42 @@ fi
  
  
  
@@ -8306,7 +8355,7 @@
  
  # Check whether --enable-libtool-lock was given.
  if test "${enable_libtool_lock+set}" = set; then :
-@@ -7605,6 +7985,123 @@ esac
+@@ -7609,6 +7989,123 @@ esac
  
  need_locks="$enable_libtool_lock"
  
@@ -8430,7 +8479,7 @@
  
    case $host_os in
      rhapsody* | darwin*)
-@@ -8168,6 +8665,8 @@ _LT_EOF
+@@ -8172,6 +8669,8 @@ _LT_EOF
        $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
        echo "$AR cru libconftest.a conftest.o" >&5
        $AR cru libconftest.a conftest.o 2>&5
@@ -8439,7 +8488,7 @@
        cat > conftest.c << _LT_EOF
  int main() { return 0;}
  _LT_EOF
-@@ -8236,6 +8735,16 @@ done
+@@ -8240,6 +8739,16 @@ done
  
  
  
@@ -8456,7 +8505,7 @@
  
  
  # Set options
-@@ -8364,7 +8873,8 @@ fi
+@@ -8368,7 +8877,8 @@ fi
  LIBTOOL_DEPS="$ltmain"
  
  # Always use our own libtool.
@@ -8466,7 +8515,7 @@
  
  
  
-@@ -8453,7 +8963,7 @@ aix3*)
+@@ -8457,7 +8967,7 @@ aix3*)
  esac
  
  # Global variables:
@@ -8475,7 +8524,7 @@
  can_build_shared=yes
  
  # All known linkers require a `.a' archive for static linking (except MSVC,
-@@ -8751,8 +9261,6 @@ fi
+@@ -8755,8 +9265,6 @@ fi
  lt_prog_compiler_pic=
  lt_prog_compiler_static=
  
@@ -8484,7 +8533,7 @@
  
    if test "$GCC" = yes; then
      lt_prog_compiler_wl='-Wl,'
-@@ -8918,6 +9426,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8922,6 +9430,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
  	lt_prog_compiler_pic='--shared'
  	lt_prog_compiler_static='--static'
  	;;
@@ -8497,7 +8546,7 @@
        pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
          # Portland Group compilers (*not* the Pentium gcc compiler,
  	# which looks to be a dead project)
-@@ -8980,7 +9494,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -8984,7 +9498,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
        lt_prog_compiler_pic='-KPIC'
        lt_prog_compiler_static='-Bstatic'
        case $cc_basename in
@@ -8506,7 +8555,7 @@
  	lt_prog_compiler_wl='-Qoption ld ';;
        *)
  	lt_prog_compiler_wl='-Wl,';;
-@@ -9037,13 +9551,17 @@ case $host_os in
+@@ -9041,13 +9555,17 @@ case $host_os in
      lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
      ;;
  esac
@@ -8530,7 +8579,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -9104,6 +9622,11 @@ fi
+@@ -9108,6 +9626,11 @@ fi
  
  
  
@@ -8542,7 +8591,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -9454,7 +9977,8 @@ _LT_EOF
+@@ -9458,7 +9981,8 @@ _LT_EOF
        allow_undefined_flag=unsupported
        always_export_symbols=no
        enable_shared_with_static_runtimes=yes
@@ -8552,16 +8601,7 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -9502,7 +10026,7 @@ _LT_EOF
-       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- 	 && test "$tmp_diet" = no
-       then
--	tmp_addflag=
-+	tmp_addflag=' $pic_flag'
- 	tmp_sharedflag='-shared'
- 	case $cc_basename,$host_cpu in
-         pgcc*)				# Portland Group C compiler
-@@ -9553,12 +10077,12 @@ _LT_EOF
+@@ -9557,12 +10081,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
  	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
@@ -8576,7 +8616,7 @@
  	  fi
  	  ;;
  	esac
-@@ -9572,8 +10096,8 @@ _LT_EOF
+@@ -9576,8 +10100,8 @@ _LT_EOF
  	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  	wlarc=
        else
@@ -8587,7 +8627,7 @@
        fi
        ;;
  
-@@ -9591,8 +10115,8 @@ _LT_EOF
+@@ -9595,8 +10119,8 @@ _LT_EOF
  
  _LT_EOF
        elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -8598,7 +8638,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9638,8 +10162,8 @@ _LT_EOF
+@@ -9642,8 +10166,8 @@ _LT_EOF
  
      *)
        if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
@@ -8609,7 +8649,7 @@
        else
  	ld_shlibs=no
        fi
-@@ -9769,7 +10293,13 @@ _LT_EOF
+@@ -9773,7 +10297,13 @@ _LT_EOF
  	allow_undefined_flag='-berok'
          # Determine the default libpath from the value encoded in an
          # empty executable.
@@ -8624,7 +8664,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -9782,22 +10312,29 @@ main ()
+@@ -9786,22 +10316,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -8667,7 +8707,7 @@
  
          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
          archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
-@@ -9809,7 +10346,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9813,7 +10350,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	else
  	 # Determine the default libpath from the value encoded in an
  	 # empty executable.
@@ -8682,7 +8722,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -9822,22 +10365,29 @@ main ()
+@@ -9826,22 +10369,29 @@ main ()
  _ACEOF
  if ac_fn_c_try_link "$LINENO"; then :
  
@@ -8725,7 +8765,7 @@
  
  	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
  	  # Warning - without using the other run time loading flags,
-@@ -9881,21 +10431,64 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9885,21 +10435,64 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
        # When not using gcc, we currently assume that we are using
        # Microsoft Visual C++.
        # hardcode_libdir_flag_spec is actually meaningless, as there is
@@ -8805,7 +8845,7 @@
        ;;
  
      darwin* | rhapsody*)
-@@ -9956,7 +10549,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9960,7 +10553,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
      freebsd* | dragonfly*)
@@ -8814,7 +8854,7 @@
        hardcode_libdir_flag_spec='-R$libdir'
        hardcode_direct=yes
        hardcode_shlibpath_var=no
-@@ -9964,7 +10557,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9968,7 +10561,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      hpux9*)
        if test "$GCC" = yes; then
@@ -8823,7 +8863,7 @@
        else
  	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
        fi
-@@ -9980,7 +10573,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -9984,7 +10577,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
      hpux10*)
        if test "$GCC" = yes && test "$with_gnu_ld" = no; then
@@ -8832,7 +8872,7 @@
        else
  	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
        fi
-@@ -10004,10 +10597,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -10008,10 +10601,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  	  ;;
  	ia64*)
@@ -8845,7 +8885,7 @@
  	  ;;
  	esac
        else
-@@ -10086,23 +10679,36 @@ fi
+@@ -10090,23 +10683,36 @@ fi
  
      irix5* | irix6* | nonstopux*)
        if test "$GCC" = yes; then
@@ -8890,7 +8930,7 @@
        else
  	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
  	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
-@@ -10187,7 +10793,7 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -10191,7 +10797,7 @@ rm -f core conftest.err conftest.$ac_objext \
      osf4* | osf5*)	# as osf3* with the addition of -msym flag
        if test "$GCC" = yes; then
  	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
@@ -8899,7 +8939,7 @@
  	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
        else
  	allow_undefined_flag=' -expect_unresolved \*'
-@@ -10206,9 +10812,9 @@ rm -f core conftest.err conftest.$ac_objext \
+@@ -10210,9 +10816,9 @@ rm -f core conftest.err conftest.$ac_objext \
        no_undefined_flag=' -z defs'
        if test "$GCC" = yes; then
  	wlarc='${wl}'
@@ -8911,7 +8951,7 @@
        else
  	case `$CC -V 2>&1` in
  	*"Compilers 5.0"*)
-@@ -10784,8 +11390,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10788,8 +11394,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -8923,7 +8963,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -10818,13 +11425,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -10822,13 +11429,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -8996,7 +9036,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -10916,7 +11581,7 @@ haiku*)
+@@ -10920,7 +11585,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -9005,16 +9045,16 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -11712,7 +12377,7 @@ else
+@@ -11716,7 +12381,7 @@ else
    lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
    lt_status=$lt_dlunknown
    cat > conftest.$ac_ext <<_LT_EOF
--#line 11715 "configure"
+-#line 11719 "configure"
 +#line $LINENO "configure"
  #include "confdefs.h"
  
  #if HAVE_DLFCN_H
-@@ -11756,10 +12421,10 @@ else
+@@ -11760,10 +12425,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -9027,16 +9067,16 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -11818,7 +12483,7 @@ else
+@@ -11822,7 +12487,7 @@ else
    lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
    lt_status=$lt_dlunknown
    cat > conftest.$ac_ext <<_LT_EOF
--#line 11821 "configure"
+-#line 11825 "configure"
 +#line $LINENO "configure"
  #include "confdefs.h"
  
  #if HAVE_DLFCN_H
-@@ -11862,10 +12527,10 @@ else
+@@ -11866,10 +12531,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
  #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
@@ -9049,7 +9089,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -12257,6 +12922,7 @@ $RM -r conftest*
+@@ -12261,6 +12926,7 @@ $RM -r conftest*
  
    # Allow CC to be a program name with arguments.
    lt_save_CC=$CC
@@ -9057,7 +9097,7 @@
    lt_save_LD=$LD
    lt_save_GCC=$GCC
    GCC=$GXX
-@@ -12274,6 +12940,7 @@ $RM -r conftest*
+@@ -12278,6 +12944,7 @@ $RM -r conftest*
    fi
    test -z "${LDCXX+set}" || LD=$LDCXX
    CC=${CXX-"c++"}
@@ -9065,18 +9105,7 @@
    compiler=$CC
    compiler_CXX=$CC
    for cc_temp in $compiler""; do
-@@ -12413,8 +13080,8 @@ with_gnu_ld=$lt_cv_prog_gnu_ld
-       # Check if GNU C++ uses GNU ld as the underlying linker, since the
-       # archiving commands below assume that GNU ld is being used.
-       if test "$with_gnu_ld" = yes; then
--        archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
--        archive_expsym_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-+        archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
-+        archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- 
-         hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
-         export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
-@@ -12556,7 +13223,13 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
+@@ -12560,7 +13227,13 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
            allow_undefined_flag_CXX='-berok'
            # Determine the default libpath from the value encoded in an empty
            # executable.
@@ -9091,7 +9120,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -12569,22 +13242,29 @@ main ()
+@@ -12573,22 +13246,29 @@ main ()
  _ACEOF
  if ac_fn_cxx_try_link "$LINENO"; then :
  
@@ -9134,7 +9163,7 @@
  
            hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
  
-@@ -12597,7 +13277,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -12601,7 +13281,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
            else
  	    # Determine the default libpath from the value encoded in an
  	    # empty executable.
@@ -9149,7 +9178,7 @@
  /* end confdefs.h.  */
  
  int
-@@ -12610,22 +13296,29 @@ main ()
+@@ -12614,22 +13300,29 @@ main ()
  _ACEOF
  if ac_fn_cxx_try_link "$LINENO"; then :
  
@@ -9192,7 +9221,7 @@
  
  	    hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
  	    # Warning - without using the other run time loading flags,
-@@ -12668,29 +13361,75 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -12672,29 +13365,75 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
          ;;
  
        cygwin* | mingw* | pw32* | cegcc*)
@@ -9291,7 +9320,7 @@
        darwin* | rhapsody*)
  
  
-@@ -12796,7 +13535,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -12800,7 +13539,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
              ;;
            *)
              if test "$GXX" = yes; then
@@ -9300,7 +9329,7 @@
              else
                # FIXME: insert proper C++ library support
                ld_shlibs_CXX=no
-@@ -12867,10 +13606,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -12871,10 +13610,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	            archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
  	            ;;
  	          ia64*)
@@ -9313,7 +9342,7 @@
  	            ;;
  	        esac
  	      fi
-@@ -12911,9 +13650,9 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -12915,9 +13654,9 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
            *)
  	    if test "$GXX" = yes; then
  	      if test "$with_gnu_ld" = no; then
@@ -9325,7 +9354,7 @@
  	      fi
  	    fi
  	    link_all_deplibs_CXX=yes
-@@ -12983,20 +13722,20 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -12987,20 +13726,20 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	      prelink_cmds_CXX='tpldir=Template.dir~
  		rm -rf $tpldir~
  		$CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
@@ -9350,7 +9379,7 @@
  	      ;;
  	    *) # Version 6 and above use weak symbols
  	      archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
-@@ -13191,7 +13930,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13195,7 +13934,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	          archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  		  ;;
  	        *)
@@ -9359,7 +9388,7 @@
  		  ;;
  	      esac
  
-@@ -13237,7 +13976,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13241,7 +13980,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  
        solaris*)
          case $cc_basename in
@@ -9368,7 +9397,7 @@
  	    # Sun C++ 4.2, 5.x and Centerline C++
              archive_cmds_need_lc_CXX=yes
  	    no_undefined_flag_CXX=' -zdefs'
-@@ -13278,9 +14017,9 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+@@ -13282,9 +14021,9 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
  	    if test "$GXX" = yes && test "$with_gnu_ld" = no; then
  	      no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
  	      if $CC --version | $GREP -v '^2\.7' > /dev/null; then
@@ -9380,7 +9409,7 @@
  
  	        # Commands to make compiler produce verbose output that lists
  	        # what "hidden" libraries, object files and flags are used when
-@@ -13415,6 +14154,13 @@ private:
+@@ -13419,6 +14158,13 @@ private:
  };
  _LT_EOF
  
@@ -9394,7 +9423,7 @@
  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
    (eval $ac_compile) 2>&5
    ac_status=$?
-@@ -13428,7 +14174,7 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
+@@ -13432,7 +14178,7 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
    pre_test_object_deps_done=no
  
    for p in `eval "$output_verbose_link_cmd"`; do
@@ -9403,7 +9432,7 @@
  
      -L* | -R* | -l*)
         # Some compilers place space between "-{L,R}" and the path.
-@@ -13437,13 +14183,22 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
+@@ -13441,13 +14187,22 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
            test $p = "-R"; then
  	 prev=$p
  	 continue
@@ -9430,7 +9459,7 @@
  	   # Internal compiler library paths should come after those
  	   # provided the user.  The postdeps already come after the
  	   # user supplied libs so there is no need to process them.
-@@ -13463,8 +14218,10 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
+@@ -13467,8 +14222,10 @@ if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
  	   postdeps_CXX="${postdeps_CXX} ${prev}${p}"
  	 fi
         fi
@@ -9441,7 +9470,7 @@
      *.$objext)
         # This assumes that the test object file only shows up
         # once in the compiler output.
-@@ -13500,6 +14257,7 @@ else
+@@ -13504,6 +14261,7 @@ else
  fi
  
  $RM -f confest.$objext
@@ -9449,7 +9478,7 @@
  
  # PORTME: override above test on systems where it is broken
  case $host_os in
-@@ -13535,7 +14293,7 @@ linux*)
+@@ -13539,7 +14297,7 @@ linux*)
  
  solaris*)
    case $cc_basename in
@@ -9458,7 +9487,7 @@
      # The more standards-conforming stlport4 library is
      # incompatible with the Cstd library. Avoid specifying
      # it if it's in CXXFLAGS. Ignore libCrun as
-@@ -13600,8 +14358,6 @@ fi
+@@ -13604,8 +14362,6 @@ fi
  lt_prog_compiler_pic_CXX=
  lt_prog_compiler_static_CXX=
  
@@ -9467,7 +9496,7 @@
  
    # C++ specific cases for pic, static, wl, etc.
    if test "$GXX" = yes; then
-@@ -13706,6 +14462,11 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -13710,6 +14466,11 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
  	  ;;
  	esac
  	;;
@@ -9479,7 +9508,7 @@
        dgux*)
  	case $cc_basename in
  	  ec++*)
-@@ -13858,7 +14619,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+@@ -13862,7 +14623,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
  	;;
        solaris*)
  	case $cc_basename in
@@ -9488,7 +9517,7 @@
  	    # Sun C++ 4.2, 5.x and Centerline C++
  	    lt_prog_compiler_pic_CXX='-KPIC'
  	    lt_prog_compiler_static_CXX='-Bstatic'
-@@ -13923,10 +14684,17 @@ case $host_os in
+@@ -13927,10 +14688,17 @@ case $host_os in
      lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC"
      ;;
  esac
@@ -9509,7 +9538,7 @@
  
  #
  # Check to make sure the PIC flag actually works.
-@@ -13984,6 +14752,8 @@ fi
+@@ -13988,6 +14756,8 @@ fi
  
  
  
@@ -9518,7 +9547,7 @@
  #
  # Check to make sure the static flag actually works.
  #
-@@ -14161,6 +14931,7 @@ fi
+@@ -14165,6 +14935,7 @@ fi
  $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
  
    export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
@@ -9526,7 +9555,7 @@
    case $host_os in
    aix[4-9]*)
      # If we're using GNU nm, then we don't want the "-C" option.
-@@ -14175,15 +14946,20 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
+@@ -14179,15 +14950,20 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
      ;;
    pw32*)
      export_symbols_cmds_CXX="$ltdll_cmds"
@@ -9552,7 +9581,7 @@
  
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
  $as_echo "$ld_shlibs_CXX" >&6; }
-@@ -14446,8 +15222,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -14450,8 +15226,9 @@ cygwin* | mingw* | pw32* | cegcc*)
    need_version=no
    need_lib_prefix=no
  
@@ -9564,7 +9593,7 @@
      library_names_spec='$libname.dll.a'
      # DLL is installed to $(libdir)/../bin by postinstall_cmds
      postinstall_cmds='base_file=`basename \${file}`~
-@@ -14479,13 +15256,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+@@ -14483,13 +15260,71 @@ cygwin* | mingw* | pw32* | cegcc*)
        library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
        ;;
      esac
@@ -9637,7 +9666,7 @@
    # FIXME: first we should search . and the directory the executable is in
    shlibpath_var=PATH
    ;;
-@@ -14576,7 +15411,7 @@ haiku*)
+@@ -14580,7 +15415,7 @@ haiku*)
    soname_spec='${libname}${release}${shared_ext}$major'
    shlibpath_var=LIBRARY_PATH
    shlibpath_overrides_runpath=yes
@@ -9646,7 +9675,7 @@
    hardcode_into_libs=yes
    ;;
  
-@@ -15035,6 +15870,7 @@ fi
+@@ -15039,6 +15874,7 @@ fi
    fi # test -n "$compiler"
  
    CC=$lt_save_CC
@@ -9654,7 +9683,7 @@
    LDCXX=$LD
    LD=$lt_save_LD
    GCC=$lt_save_GCC
-@@ -17807,13 +18643,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -17953,13 +18789,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -9675,7 +9704,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -17828,14 +18671,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -17974,14 +18817,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -9694,7 +9723,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -17868,12 +18714,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -18014,12 +18860,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -9708,7 +9737,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -17912,8 +18758,8 @@ old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote
+@@ -18058,8 +18904,8 @@ old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote
  compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`'
  GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`'
  lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`'
@@ -9718,7 +9747,7 @@
  lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`'
  lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`'
  archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`'
-@@ -17940,12 +18786,12 @@ hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_
+@@ -18086,12 +18932,12 @@ hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_
  hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`'
  inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`'
@@ -9732,7 +9761,7 @@
  file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`'
  hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`'
  compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`'
-@@ -17983,8 +18829,13 @@ reload_flag \
+@@ -18129,8 +18975,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -9746,7 +9775,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -17994,12 +18845,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -18140,12 +18991,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -9762,7 +9791,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -18015,7 +18868,6 @@ no_undefined_flag \
+@@ -18161,7 +19014,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -9770,7 +9799,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -18037,8 +18889,8 @@ LD_CXX \
+@@ -18183,8 +19035,8 @@ LD_CXX \
  reload_flag_CXX \
  compiler_CXX \
  lt_prog_compiler_no_builtin_flag_CXX \
@@ -9780,7 +9809,7 @@
  lt_prog_compiler_static_CXX \
  lt_cv_prog_compiler_c_o_CXX \
  export_dynamic_flag_spec_CXX \
-@@ -18050,7 +18902,6 @@ no_undefined_flag_CXX \
+@@ -18196,7 +19048,6 @@ no_undefined_flag_CXX \
  hardcode_libdir_flag_spec_CXX \
  hardcode_libdir_flag_spec_ld_CXX \
  hardcode_libdir_separator_CXX \
@@ -9788,7 +9817,7 @@
  exclude_expsyms_CXX \
  include_expsyms_CXX \
  file_list_spec_CXX \
-@@ -18084,6 +18935,7 @@ module_cmds \
+@@ -18230,6 +19081,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -9796,7 +9825,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -18098,7 +18950,8 @@ archive_expsym_cmds_CXX \
+@@ -18244,7 +19096,8 @@ archive_expsym_cmds_CXX \
  module_cmds_CXX \
  module_expsym_cmds_CXX \
  export_symbols_cmds_CXX \
@@ -9806,7 +9835,7 @@
      case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
      *[\\\\\\\`\\"\\\$]*)
        eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
-@@ -18891,7 +19744,8 @@ $as_echo X"$file" |
+@@ -19037,7 +19890,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -9816,7 +9845,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -18994,19 +19848,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -19140,19 +19994,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -9860,7 +9889,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -19036,6 +19913,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -19182,6 +20059,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -9873,7 +9902,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -19045,6 +19928,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -19191,6 +20074,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -9883,7 +9912,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -19159,12 +20045,12 @@ with_gcc=$GCC
+@@ -19305,12 +20191,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -9899,7 +9928,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -19251,9 +20137,6 @@ inherit_rpath=$inherit_rpath
+@@ -19397,9 +20283,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -9909,7 +9938,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -19269,6 +20152,9 @@ include_expsyms=$lt_include_expsyms
+@@ -19415,6 +20298,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -9919,7 +9948,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -19315,210 +20201,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -19461,210 +20347,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -10293,7 +10322,7 @@
      (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
    chmod +x "$ofile"
  
-@@ -19546,12 +20391,12 @@ with_gcc=$GCC_CXX
+@@ -19692,12 +20537,12 @@ with_gcc=$GCC_CXX
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
  
@@ -10309,7 +10338,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static_CXX
  
-@@ -19638,9 +20483,6 @@ inherit_rpath=$inherit_rpath_CXX
+@@ -19784,9 +20629,6 @@ inherit_rpath=$inherit_rpath_CXX
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs_CXX
  
@@ -10319,7 +10348,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols_CXX
  
-@@ -19656,6 +20498,9 @@ include_expsyms=$lt_include_expsyms_CXX
+@@ -19802,6 +20644,9 @@ include_expsyms=$lt_include_expsyms_CXX
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds_CXX
  
@@ -10330,7 +10359,7 @@
  file_list_spec=$lt_file_list_spec_CXX
  
 diff --git a/libtool.m4 b/libtool.m4
-index 797468f..02b15b3 100644
+index 4b2d30a..008d331 100644
 --- a/libtool.m4
 +++ b/libtool.m4
 @@ -1,7 +1,8 @@
@@ -11052,15 +11081,6 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -4459,7 +4731,7 @@ _LT_EOF
-       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- 	 && test "$tmp_diet" = no
-       then
--	tmp_addflag=
-+	tmp_addflag=' $pic_flag'
- 	tmp_sharedflag='-shared'
- 	case $cc_basename,$host_cpu in
-         pgcc*)				# Portland Group C compiler
 @@ -4510,12 +4782,12 @@ _LT_EOF
  	  _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
  	  _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
@@ -11347,17 +11367,6 @@
    compiler=$CC
    _LT_TAGVAR(compiler, $1)=$CC
    _LT_CC_BASENAME([$compiler])
-@@ -5525,8 +5858,8 @@ if test "$_lt_caught_CXX_error" != yes; then
-       # Check if GNU C++ uses GNU ld as the underlying linker, since the
-       # archiving commands below assume that GNU ld is being used.
-       if test "$with_gnu_ld" = yes; then
--        _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
--        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-+        _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
-+        _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- 
-         _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
-         _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
 @@ -5667,7 +6000,7 @@ if test "$_lt_caught_CXX_error" != yes; then
            _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
            # Determine the default libpath from the value encoded in an empty
@@ -17433,7 +17442,7 @@
  # These exist entirely to fool aclocal when bootstrapping libtool.
  #
 diff --git a/opcodes/configure b/opcodes/configure
-index c9c04ce..31141d9 100755
+index eedb184..d3076e1 100755
 --- a/opcodes/configure
 +++ b/opcodes/configure
 @@ -648,6 +648,9 @@ OTOOL
@@ -18270,15 +18279,6 @@
  
        if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
          archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
-@@ -8936,7 +9450,7 @@ _LT_EOF
-       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- 	 && test "$tmp_diet" = no
-       then
--	tmp_addflag=
-+	tmp_addflag=' $pic_flag'
- 	tmp_sharedflag='-shared'
- 	case $cc_basename,$host_cpu in
-         pgcc*)				# Portland Group C compiler
 @@ -8987,12 +9501,12 @@ _LT_EOF
  	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
  	  hardcode_libdir_flag_spec=
@@ -18721,6 +18721,15 @@
    hardcode_into_libs=yes
    ;;
  
+@@ -11146,7 +11801,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11149 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
 @@ -11190,10 +11845,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
@@ -18734,6 +18743,15 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
+@@ -11252,7 +11907,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 11255 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
 @@ -11296,10 +11951,10 @@ else
  /* When -fvisbility=hidden is used, assume the code has been annotated
     correspondingly for the symbols needed.  */
@@ -18747,7 +18765,7 @@
  int main ()
  {
    void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-@@ -12450,7 +13105,7 @@ if test "$enable_shared" = "yes"; then
+@@ -12462,7 +13117,7 @@ if test "$enable_shared" = "yes"; then
  # since libbfd may not pull in the entirety of libiberty.
    x=`sed -n -e 's/^[ 	]*PICFLAG[ 	]*=[ 	]*//p' < ../libiberty/Makefile | sed -n '$p'`
    if test -n "$x"; then
@@ -18756,7 +18774,7 @@
    fi
  
    case "${host}" in
-@@ -13422,13 +14077,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+@@ -13436,13 +14091,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
  lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
  lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
  lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
@@ -18777,7 +18795,7 @@
  STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
  RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
  old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-@@ -13443,14 +14105,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+@@ -13457,14 +14119,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
  lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
@@ -18796,7 +18814,7 @@
  DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
  NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
  LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-@@ -13483,12 +14148,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+@@ -13497,12 +14162,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
  hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
  inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
  link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
@@ -18810,7 +18828,7 @@
  file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
  variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
  need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-@@ -13543,8 +14208,13 @@ reload_flag \
+@@ -13557,8 +14222,13 @@ reload_flag \
  OBJDUMP \
  deplibs_check_method \
  file_magic_cmd \
@@ -18824,7 +18842,7 @@
  STRIP \
  RANLIB \
  CC \
-@@ -13554,12 +14224,14 @@ lt_cv_sys_global_symbol_pipe \
+@@ -13568,12 +14238,14 @@ lt_cv_sys_global_symbol_pipe \
  lt_cv_sys_global_symbol_to_cdecl \
  lt_cv_sys_global_symbol_to_c_name_address \
  lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
@@ -18840,7 +18858,7 @@
  DSYMUTIL \
  NMEDIT \
  LIPO \
-@@ -13575,7 +14247,6 @@ no_undefined_flag \
+@@ -13589,7 +14261,6 @@ no_undefined_flag \
  hardcode_libdir_flag_spec \
  hardcode_libdir_flag_spec_ld \
  hardcode_libdir_separator \
@@ -18848,7 +18866,7 @@
  exclude_expsyms \
  include_expsyms \
  file_list_spec \
-@@ -13611,6 +14282,7 @@ module_cmds \
+@@ -13625,6 +14296,7 @@ module_cmds \
  module_expsym_cmds \
  export_symbols_cmds \
  prelink_cmds \
@@ -18856,7 +18874,7 @@
  postinstall_cmds \
  postuninstall_cmds \
  finish_cmds \
-@@ -14367,7 +15039,8 @@ $as_echo X"$file" |
+@@ -14381,7 +15053,8 @@ $as_echo X"$file" |
  # NOTE: Changes made to this file will be lost: look at ltmain.sh.
  #
  #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
@@ -18866,7 +18884,7 @@
  #   Written by Gordon Matzigkeit, 1996
  #
  #   This file is part of GNU Libtool.
-@@ -14470,19 +15143,42 @@ SP2NL=$lt_lt_SP2NL
+@@ -14484,19 +15157,42 @@ SP2NL=$lt_lt_SP2NL
  # turn newlines into spaces.
  NL2SP=$lt_lt_NL2SP
  
@@ -18910,7 +18928,7 @@
  # A symbol stripping program.
  STRIP=$lt_STRIP
  
-@@ -14512,6 +15208,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+@@ -14526,6 +15222,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
  # Transform the output of nm in a C name address pair when lib prefix is needed.
  global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
  
@@ -18923,7 +18941,7 @@
  # The name of the directory that contains temporary libtool files.
  objdir=$objdir
  
-@@ -14521,6 +15223,9 @@ MAGIC_CMD=$MAGIC_CMD
+@@ -14535,6 +15237,9 @@ MAGIC_CMD=$MAGIC_CMD
  # Must we lock files when doing compilation?
  need_locks=$lt_need_locks
  
@@ -18933,7 +18951,7 @@
  # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
  DSYMUTIL=$lt_DSYMUTIL
  
-@@ -14635,12 +15340,12 @@ with_gcc=$GCC
+@@ -14649,12 +15354,12 @@ with_gcc=$GCC
  # Compiler flag to turn off builtin functions.
  no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
  
@@ -18949,7 +18967,7 @@
  # Compiler flag to prevent dynamic linking.
  link_static_flag=$lt_lt_prog_compiler_static
  
-@@ -14727,9 +15432,6 @@ inherit_rpath=$inherit_rpath
+@@ -14741,9 +15446,6 @@ inherit_rpath=$inherit_rpath
  # Whether libtool must link a program against all its dependency libraries.
  link_all_deplibs=$link_all_deplibs
  
@@ -18959,7 +18977,7 @@
  # Set to "yes" if exported symbols are required.
  always_export_symbols=$always_export_symbols
  
-@@ -14745,6 +15447,9 @@ include_expsyms=$lt_include_expsyms
+@@ -14759,6 +15461,9 @@ include_expsyms=$lt_include_expsyms
  # Commands necessary for linking programs (against libraries) with templates.
  prelink_cmds=$lt_prelink_cmds
  
@@ -18969,7 +18987,7 @@
  # Specify filename containing input files.
  file_list_spec=$lt_file_list_spec
  
-@@ -14777,210 +15482,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+@@ -14791,210 +15496,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
    # if finds mixed CR/LF and LF-only lines.  Since sed operates in
    # text mode, it properly converts lines to CR/LF.  This bash problem
    # is reportedly fixed, but why not run on old versions too?
@@ -19344,7 +19362,7 @@
    chmod +x "$ofile"
  
 diff --git a/opcodes/configure.ac b/opcodes/configure.ac
-index b93e855..43ba976 100644
+index 07e3162..c0c75d4 100644
 --- a/opcodes/configure.ac
 +++ b/opcodes/configure.ac
 @@ -167,7 +167,7 @@ changequote(,)dnl
@@ -19356,6 +19374,1922 @@
    fi
  
    case "${host}" in
+diff --git a/zlib/configure b/zlib/configure
+index 8378857..7584940 100755
+--- a/zlib/configure
++++ b/zlib/configure
+@@ -614,8 +614,11 @@ OTOOL
+ LIPO
+ NMEDIT
+ DSYMUTIL
++MANIFEST_TOOL
+ RANLIB
++ac_ct_AR
+ AR
++DLLTOOL
+ OBJDUMP
+ LN_S
+ NM
+@@ -736,6 +739,7 @@ enable_static
+ with_pic
+ enable_fast_install
+ with_gnu_ld
++with_libtool_sysroot
+ enable_libtool_lock
+ enable_host_shared
+ '
+@@ -1384,6 +1388,8 @@ Optional Packages:
+   --with-pic              try to use only PIC/non-PIC objects [default=use
+                           both]
+   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
++  --with-libtool-sysroot=DIR Search for dependent libraries within DIR
++                        (or the compiler's sysroot if not specified).
+ 
+ Some influential environment variables:
+   CC          C compiler command
+@@ -3907,8 +3913,8 @@ esac
+ 
+ 
+ 
+-macro_version='2.2.7a'
+-macro_revision='1.3134'
++macro_version='2.4'
++macro_revision='1.3293'
+ 
+ 
+ 
+@@ -3948,7 +3954,7 @@ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
+ $as_echo_n "checking how to print strings... " >&6; }
+ # Test print first, because it will be a builtin if present.
+-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
++if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
+    test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
+   ECHO='print -r --'
+ elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
+@@ -4764,8 +4770,8 @@ $as_echo_n "checking whether the shell understands some XSI constructs... " >&6;
+ # Try some XSI features
+ xsi_shell=no
+ ( _lt_dummy="a/b/c"
+-  test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
+-      = c,a/b,, \
++  test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
++      = c,a/b,b/c, \
+     && eval 'test $(( 1 + 1 )) -eq 2 \
+     && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
+   && xsi_shell=yes
+@@ -4814,6 +4820,80 @@ esac
+ 
+ 
+ 
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
++$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
++if test "${lt_cv_to_host_file_cmd+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  case $host in
++  *-*-mingw* )
++    case $build in
++      *-*-mingw* ) # actually msys
++        lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
++        ;;
++      *-*-cygwin* )
++        lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
++        ;;
++      * ) # otherwise, assume *nix
++        lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
++        ;;
++    esac
++    ;;
++  *-*-cygwin* )
++    case $build in
++      *-*-mingw* ) # actually msys
++        lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
++        ;;
++      *-*-cygwin* )
++        lt_cv_to_host_file_cmd=func_convert_file_noop
++        ;;
++      * ) # otherwise, assume *nix
++        lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
++        ;;
++    esac
++    ;;
++  * ) # unhandled hosts (and "normal" native builds)
++    lt_cv_to_host_file_cmd=func_convert_file_noop
++    ;;
++esac
++
++fi
++
++to_host_file_cmd=$lt_cv_to_host_file_cmd
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
++$as_echo "$lt_cv_to_host_file_cmd" >&6; }
++
++
++
++
++
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
++$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
++if test "${lt_cv_to_tool_file_cmd+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  #assume ordinary cross tools, or native build.
++lt_cv_to_tool_file_cmd=func_convert_file_noop
++case $host in
++  *-*-mingw* )
++    case $build in
++      *-*-mingw* ) # actually msys
++        lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
++        ;;
++    esac
++    ;;
++esac
++
++fi
++
++to_tool_file_cmd=$lt_cv_to_tool_file_cmd
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
++$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
++
++
++
++
++
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
+ $as_echo_n "checking for $LD option to reload object files... " >&6; }
+ if test "${lt_cv_ld_reload_flag+set}" = set; then :
+@@ -4830,6 +4910,11 @@ case $reload_flag in
+ esac
+ reload_cmds='$LD$reload_flag -o $output$reload_objs'
+ case $host_os in
++  cygwin* | mingw* | pw32* | cegcc*)
++    if test "$GCC" != yes; then
++      reload_cmds=false
++    fi
++    ;;
+   darwin*)
+     if test "$GCC" = yes; then
+       reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
+@@ -4998,7 +5083,8 @@ mingw* | pw32*)
+     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
+     lt_cv_file_magic_cmd='func_win32_libid'
+   else
+-    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
++    # Keep this pattern in sync with the one in func_win32_libid.
++    lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
+     lt_cv_file_magic_cmd='$OBJDUMP -f'
+   fi
+   ;;
+@@ -5152,6 +5238,21 @@ esac
+ fi
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
+ $as_echo "$lt_cv_deplibs_check_method" >&6; }
++
++file_magic_glob=
++want_nocaseglob=no
++if test "$build" = "$host"; then
++  case $host_os in
++  mingw* | pw32*)
++    if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
++      want_nocaseglob=yes
++    else
++      file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
++    fi
++    ;;
++  esac
++fi
++
+ file_magic_cmd=$lt_cv_file_magic_cmd
+ deplibs_check_method=$lt_cv_deplibs_check_method
+ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+@@ -5167,9 +5268,163 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown
+ 
+ 
+ 
++
++
++
++
++
++
++
++
++
++
+ if test -n "$ac_tool_prefix"; then
+-  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
+-set dummy ${ac_tool_prefix}ar; ac_word=$2
++  # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
++set dummy ${ac_tool_prefix}dlltool; ac_word=$2
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
++$as_echo_n "checking for $ac_word... " >&6; }
++if test "${ac_cv_prog_DLLTOOL+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  if test -n "$DLLTOOL"; then
++  ac_cv_prog_DLLTOOL="$DLLTOOL" # 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 { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
++    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
++    break 2
++  fi
++done
++  done
++IFS=$as_save_IFS
++
++fi
++fi
++DLLTOOL=$ac_cv_prog_DLLTOOL
++if test -n "$DLLTOOL"; then
++  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
++$as_echo "$DLLTOOL" >&6; }
++else
++  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
++$as_echo "no" >&6; }
++fi
++
++
++fi
++if test -z "$ac_cv_prog_DLLTOOL"; then
++  ac_ct_DLLTOOL=$DLLTOOL
++  # Extract the first word of "dlltool", so it can be a program name with args.
++set dummy dlltool; ac_word=$2
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
++$as_echo_n "checking for $ac_word... " >&6; }
++if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  if test -n "$ac_ct_DLLTOOL"; then
++  ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # 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 { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
++    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
++    break 2
++  fi
++done
++  done
++IFS=$as_save_IFS
++
++fi
++fi
++ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
++if test -n "$ac_ct_DLLTOOL"; then
++  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
++$as_echo "$ac_ct_DLLTOOL" >&6; }
++else
++  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
++$as_echo "no" >&6; }
++fi
++
++  if test "x$ac_ct_DLLTOOL" = x; then
++    DLLTOOL="false"
++  else
++    case $cross_compiling:$ac_tool_warned in
++yes:)
++{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
++$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
++ac_tool_warned=yes ;;
++esac
++    DLLTOOL=$ac_ct_DLLTOOL
++  fi
++else
++  DLLTOOL="$ac_cv_prog_DLLTOOL"
++fi
++
++test -z "$DLLTOOL" && DLLTOOL=dlltool
++
++
++
++
++
++
++
++
++
++
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
++$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
++if test "${lt_cv_sharedlib_from_linklib_cmd+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  lt_cv_sharedlib_from_linklib_cmd='unknown'
++
++case $host_os in
++cygwin* | mingw* | pw32* | cegcc*)
++  # two different shell functions defined in ltmain.sh
++  # decide which to use based on capabilities of $DLLTOOL
++  case `$DLLTOOL --help 2>&1` in
++  *--identify-strict*)
++    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
++    ;;
++  *)
++    lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
++    ;;
++  esac
++  ;;
++*)
++  # fallback: assume linklib IS sharedlib
++  lt_cv_sharedlib_from_linklib_cmd="$ECHO"
++  ;;
++esac
++
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
++$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
++sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
++test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
++
++
++
++
++
++
++
++
++if test -n "$ac_tool_prefix"; then
++  for ac_prog in ar
++  do
++    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
++set dummy $ac_tool_prefix$ac_prog; ac_word=$2
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+ $as_echo_n "checking for $ac_word... " >&6; }
+ if test "${ac_cv_prog_AR+set}" = set; then :
+@@ -5185,7 +5440,7 @@ do
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+-    ac_cv_prog_AR="${ac_tool_prefix}ar"
++    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+   fi
+@@ -5205,11 +5460,15 @@ $as_echo "no" >&6; }
+ fi
+ 
+ 
++    test -n "$AR" && break
++  done
+ fi
+-if test -z "$ac_cv_prog_AR"; then
++if test -z "$AR"; then
+   ac_ct_AR=$AR
+-  # Extract the first word of "ar", so it can be a program name with args.
+-set dummy ar; ac_word=$2
++  for ac_prog in ar
++do
++  # Extract the first word of "$ac_prog", so it can be a program name with args.
++set dummy $ac_prog; ac_word=$2
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+ $as_echo_n "checking for $ac_word... " >&6; }
+ if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
+@@ -5225,7 +5484,7 @@ do
+   test -z "$as_dir" && as_dir=.
+     for ac_exec_ext in '' $ac_executable_extensions; do
+   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+-    ac_cv_prog_ac_ct_AR="ar"
++    ac_cv_prog_ac_ct_AR="$ac_prog"
+     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+     break 2
+   fi
+@@ -5244,6 +5503,10 @@ else
+ $as_echo "no" >&6; }
+ fi
+ 
++
++  test -n "$ac_ct_AR" && break
++done
++
+   if test "x$ac_ct_AR" = x; then
+     AR="false"
+   else
+@@ -5255,16 +5518,72 @@ ac_tool_warned=yes ;;
+ esac
+     AR=$ac_ct_AR
+   fi
+-else
+-  AR="$ac_cv_prog_AR"
+ fi
+ 
+-test -z "$AR" && AR=ar
+-test -z "$AR_FLAGS" && AR_FLAGS=cru
++: ${AR=ar}
++: ${AR_FLAGS=cru}
++
++
++
++
++
++
++
++
++
++
++
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
++$as_echo_n "checking for archiver @FILE support... " >&6; }
++if test "${lt_cv_ar_at_file+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  lt_cv_ar_at_file=no
++   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
++/* end confdefs.h.  */
++
++int
++main ()
++{
+ 
++  ;
++  return 0;
++}
++_ACEOF
++if ac_fn_c_try_compile "$LINENO"; then :
++  echo conftest.$ac_objext > conftest.lst
++      lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
++      { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
++  (eval $lt_ar_try) 2>&5
++  ac_status=$?
++  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
++  test $ac_status = 0; }
++      if test "$ac_status" -eq 0; then
++	# Ensure the archiver fails upon bogus file names.
++	rm -f conftest.$ac_objext libconftest.a
++	{ { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
++  (eval $lt_ar_try) 2>&5
++  ac_status=$?
++  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
++  test $ac_status = 0; }
++	if test "$ac_status" -ne 0; then
++          lt_cv_ar_at_file=@
++        fi
++      fi
++      rm -f conftest.* libconftest.a
+ 
++fi
++rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ 
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
++$as_echo "$lt_cv_ar_at_file" >&6; }
+ 
++if test "x$lt_cv_ar_at_file" = xno; then
++  archiver_list_spec=
++else
++  archiver_list_spec=$lt_cv_ar_at_file
++fi
+ 
+ 
+ 
+@@ -5606,8 +5925,8 @@ esac
+ lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
+ 
+ # Transform an extracted symbol line into symbol name and symbol address
+-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (void *) \&\2},/p'"
+-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
++lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (void *) \&\2},/p'"
++lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
+ 
+ # Handle CRLF in mingw tool chain
+ opt_cr=
+@@ -5643,6 +5962,7 @@ for ac_symprfx in "" "_"; do
+   else
+     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[	 ]\($symcode$symcode*\)[	 ][	 ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
+   fi
++  lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
+ 
+   # Check to see that the pipe works correctly.
+   pipe_works=no
+@@ -5684,6 +6004,18 @@ _LT_EOF
+       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
+ 	if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
+ 	  cat <<_LT_EOF > conftest.$ac_ext
++/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
++#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
++/* DATA imports from DLLs on WIN32 con't be const, because runtime
++   relocations are performed -- see ld's documentation on pseudo-relocs.  */
++# define LT_DLSYM_CONST
++#elif defined(__osf__)
++/* This system does not cope well with relocations in const data.  */
++# define LT_DLSYM_CONST
++#else
++# define LT_DLSYM_CONST const
++#endif
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+@@ -5695,7 +6027,7 @@ _LT_EOF
+ 	  cat <<_LT_EOF >> conftest.$ac_ext
+ 
+ /* The mapping between symbol names and symbols.  */
+-const struct {
++LT_DLSYM_CONST struct {
+   const char *name;
+   void       *address;
+ }
+@@ -5721,8 +6053,8 @@ static const void *lt_preloaded_setup() {
+ _LT_EOF
+ 	  # Now try linking the two files.
+ 	  mv conftest.$ac_objext conftstm.$ac_objext
+-	  lt_save_LIBS="$LIBS"
+-	  lt_save_CFLAGS="$CFLAGS"
++	  lt_globsym_save_LIBS=$LIBS
++	  lt_globsym_save_CFLAGS=$CFLAGS
+ 	  LIBS="conftstm.$ac_objext"
+ 	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
+ 	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
+@@ -5732,8 +6064,8 @@ _LT_EOF
+   test $ac_status = 0; } && test -s conftest${ac_exeext}; then
+ 	    pipe_works=yes
+ 	  fi
+-	  LIBS="$lt_save_LIBS"
+-	  CFLAGS="$lt_save_CFLAGS"
++	  LIBS=$lt_globsym_save_LIBS
++	  CFLAGS=$lt_globsym_save_CFLAGS
+ 	else
+ 	  echo "cannot find nm_test_func in $nlist" >&5
+ 	fi
+@@ -5770,6 +6102,19 @@ else
+ $as_echo "ok" >&6; }
+ fi
+ 
++# Response file support.
++if test "$lt_cv_nm_interface" = "MS dumpbin"; then
++  nm_file_list_spec='@'
++elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
++  nm_file_list_spec='@'
++fi
++
++
++
++
++
++
++
+ 
+ 
+ 
+@@ -5790,6 +6135,41 @@ fi
+ 
+ 
+ 
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
++$as_echo_n "checking for sysroot... " >&6; }
++
++# Check whether --with-libtool-sysroot was given.
++if test "${with_libtool_sysroot+set}" = set; then :
++  withval=$with_libtool_sysroot;
++else
++  with_libtool_sysroot=no
++fi
++
++
++lt_sysroot=
++case ${with_libtool_sysroot} in #(
++ yes)
++   if test "$GCC" = yes; then
++     lt_sysroot=`$CC --print-sysroot 2>/dev/null`
++   fi
++   ;; #(
++ /*)
++   lt_sysroot=`echo "$with_libtool_sysroot" | sed -e "$sed_quote_subst"`
++   ;; #(
++ no|'')
++   ;; #(
++ *)
++   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libtool_sysroot}" >&5
++$as_echo "${with_libtool_sysroot}" >&6; }
++   as_fn_error "The sysroot must be an absolute path." "$LINENO" 5
++   ;;
++esac
++
++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
++$as_echo "${lt_sysroot:-no}" >&6; }
++
++
++
+ 
+ 
+ # Check whether --enable-libtool-lock was given.
+@@ -6001,6 +6381,123 @@ esac
+ 
+ need_locks="$enable_libtool_lock"
+ 
++if test -n "$ac_tool_prefix"; then
++  # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
++set dummy ${ac_tool_prefix}mt; ac_word=$2
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
++$as_echo_n "checking for $ac_word... " >&6; }
++if test "${ac_cv_prog_MANIFEST_TOOL+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  if test -n "$MANIFEST_TOOL"; then
++  ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # 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 { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++    ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
++    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
++    break 2
++  fi
++done
++  done
++IFS=$as_save_IFS
++
++fi
++fi
++MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
++if test -n "$MANIFEST_TOOL"; then
++  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
++$as_echo "$MANIFEST_TOOL" >&6; }
++else
++  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
++$as_echo "no" >&6; }
++fi
++
++
++fi
++if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
++  ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
++  # Extract the first word of "mt", so it can be a program name with args.
++set dummy mt; ac_word=$2
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
++$as_echo_n "checking for $ac_word... " >&6; }
++if test "${ac_cv_prog_ac_ct_MANIFEST_TOOL+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  if test -n "$ac_ct_MANIFEST_TOOL"; then
++  ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # 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 { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
++    ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
++    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
++    break 2
++  fi
++done
++  done
++IFS=$as_save_IFS
++
++fi
++fi
++ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
++if test -n "$ac_ct_MANIFEST_TOOL"; then
++  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
++$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
++else
++  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
++$as_echo "no" >&6; }
++fi
++
++  if test "x$ac_ct_MANIFEST_TOOL" = x; then
++    MANIFEST_TOOL=":"
++  else
++    case $cross_compiling:$ac_tool_warned in
++yes:)
++{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
++$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
++ac_tool_warned=yes ;;
++esac
++    MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
++  fi
++else
++  MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
++fi
++
++test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
++$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
++if test "${lt_cv_path_mainfest_tool+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  lt_cv_path_mainfest_tool=no
++  echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
++  $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
++  cat conftest.err >&5
++  if $GREP 'Manifest Tool' conftest.out > /dev/null; then
++    lt_cv_path_mainfest_tool=yes
++  fi
++  rm -f conftest*
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
++$as_echo "$lt_cv_path_mainfest_tool" >&6; }
++if test "x$lt_cv_path_mainfest_tool" != xyes; then
++  MANIFEST_TOOL=:
++fi
++
++
++
++
++
+ 
+   case $host_os in
+     rhapsody* | darwin*)
+@@ -6567,6 +7064,8 @@ _LT_EOF
+       $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
+       echo "$AR cru libconftest.a conftest.o" >&5
+       $AR cru libconftest.a conftest.o 2>&5
++      echo "$RANLIB libconftest.a" >&5
++      $RANLIB libconftest.a 2>&5
+       cat > conftest.c << _LT_EOF
+ int main() { return 0;}
+ _LT_EOF
+@@ -7030,7 +7529,8 @@ fi
+ LIBTOOL_DEPS="$ltmain"
+ 
+ # Always use our own libtool.
+-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
++LIBTOOL='$(SHELL) $(top_builddir)'
++LIBTOOL="$LIBTOOL/${host_alias}-libtool"
+ 
+ 
+ 
+@@ -7119,7 +7619,7 @@ aix3*)
+ esac
+ 
+ # Global variables:
+-ofile=libtool
++ofile=${host_alias}-libtool
+ can_build_shared=yes
+ 
+ # All known linkers require a `.a' archive for static linking (except MSVC,
+@@ -7417,8 +7917,6 @@ fi
+ lt_prog_compiler_pic=
+ lt_prog_compiler_static=
+ 
+-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
+-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+ 
+   if test "$GCC" = yes; then
+     lt_prog_compiler_wl='-Wl,'
+@@ -7584,6 +8082,12 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+ 	lt_prog_compiler_pic='--shared'
+ 	lt_prog_compiler_static='--static'
+ 	;;
++      nagfor*)
++	# NAG Fortran compiler
++	lt_prog_compiler_wl='-Wl,-Wl,,'
++	lt_prog_compiler_pic='-PIC'
++	lt_prog_compiler_static='-Bstatic'
++	;;
+       pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
+         # Portland Group compilers (*not* the Pentium gcc compiler,
+ 	# which looks to be a dead project)
+@@ -7646,7 +8150,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
+       lt_prog_compiler_pic='-KPIC'
+       lt_prog_compiler_static='-Bstatic'
+       case $cc_basename in
+-      f77* | f90* | f95*)
++      f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
+ 	lt_prog_compiler_wl='-Qoption ld ';;
+       *)
+ 	lt_prog_compiler_wl='-Wl,';;
+@@ -7703,13 +8207,17 @@ case $host_os in
+     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
+     ;;
+ esac
+-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
+-$as_echo "$lt_prog_compiler_pic" >&6; }
+-
+-
+-
+-
+ 
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
++$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
++if test "${lt_cv_prog_compiler_pic+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
++$as_echo "$lt_cv_prog_compiler_pic" >&6; }
++lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
+ 
+ #
+ # Check to make sure the PIC flag actually works.
+@@ -7770,6 +8278,11 @@ fi
+ 
+ 
+ 
++
++
++
++
++
+ #
+ # Check to make sure the static flag actually works.
+ #
+@@ -8120,7 +8633,8 @@ _LT_EOF
+       allow_undefined_flag=unsupported
+       always_export_symbols=no
+       enable_shared_with_static_runtimes=yes
+-      export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
++      export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
++      exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
+ 
+       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
+         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
+@@ -8219,12 +8733,12 @@ _LT_EOF
+ 	  whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
+ 	  hardcode_libdir_flag_spec=
+ 	  hardcode_libdir_flag_spec_ld='-rpath $libdir'
+-	  archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
++	  archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
+ 	  if test "x$supports_anon_versioning" = xyes; then
+ 	    archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
+ 	      cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
+ 	      echo "local: *; };" >> $output_objdir/$libname.ver~
+-	      $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
++	      $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
+ 	  fi
+ 	  ;;
+ 	esac
+@@ -8238,8 +8752,8 @@ _LT_EOF
+ 	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
+ 	wlarc=
+       else
+-	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+-	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
++	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
++	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+       fi
+       ;;
+ 
+@@ -8257,8 +8771,8 @@ _LT_EOF
+ 
+ _LT_EOF
+       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
+-	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+-	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
++	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
++	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+       else
+ 	ld_shlibs=no
+       fi
+@@ -8304,8 +8818,8 @@ _LT_EOF
+ 
+     *)
+       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
+-	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+-	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
++	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
++	archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+       else
+ 	ld_shlibs=no
+       fi
+@@ -8435,7 +8949,13 @@ _LT_EOF
+ 	allow_undefined_flag='-berok'
+         # Determine the default libpath from the value encoded in an
+         # empty executable.
+-        if test x$gcc_no_link = xyes; then
++        if test "${lt_cv_aix_libpath+set}" = set; then
++  aix_libpath=$lt_cv_aix_libpath
++else
++  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  if test x$gcc_no_link = xyes; then
+   as_fn_error "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
+ fi
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+@@ -8451,22 +8971,29 @@ main ()
+ _ACEOF
+ if ac_fn_c_try_link "$LINENO"; then :
+ 
+-lt_aix_libpath_sed='
+-    /Import File Strings/,/^$/ {
+-	/^0/ {
+-	    s/^0  *\(.*\)$/\1/
+-	    p
+-	}
+-    }'
+-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+-# Check for a 64-bit object if we didn't find anything.
+-if test -z "$aix_libpath"; then
+-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+-fi
++  lt_aix_libpath_sed='
++      /Import File Strings/,/^$/ {
++	  /^0/ {
++	      s/^0  *\([^ ]*\) *$/\1/
++	      p
++	  }
++      }'
++  lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
++  # Check for a 64-bit object if we didn't find anything.
++  if test -z "$lt_cv_aix_libpath_"; then
++    lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
++  fi
+ fi
+ rm -f core conftest.err conftest.$ac_objext \
+     conftest$ac_exeext conftest.$ac_ext
+-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
++  if test -z "$lt_cv_aix_libpath_"; then
++    lt_cv_aix_libpath_="/usr/lib:/lib"
++  fi
++
++fi
++
++  aix_libpath=$lt_cv_aix_libpath_
++fi
+ 
+         hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
+         archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+@@ -8478,7 +9005,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+ 	else
+ 	 # Determine the default libpath from the value encoded in an
+ 	 # empty executable.
+-	 if test x$gcc_no_link = xyes; then
++	 if test "${lt_cv_aix_libpath+set}" = set; then
++  aix_libpath=$lt_cv_aix_libpath
++else
++  if test "${lt_cv_aix_libpath_+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  if test x$gcc_no_link = xyes; then
+   as_fn_error "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
+ fi
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+@@ -8494,22 +9027,29 @@ main ()
+ _ACEOF
+ if ac_fn_c_try_link "$LINENO"; then :
+ 
+-lt_aix_libpath_sed='
+-    /Import File Strings/,/^$/ {
+-	/^0/ {
+-	    s/^0  *\(.*\)$/\1/
+-	    p
+-	}
+-    }'
+-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+-# Check for a 64-bit object if we didn't find anything.
+-if test -z "$aix_libpath"; then
+-  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+-fi
++  lt_aix_libpath_sed='
++      /Import File Strings/,/^$/ {
++	  /^0/ {
++	      s/^0  *\([^ ]*\) *$/\1/
++	      p
++	  }
++      }'
++  lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
++  # Check for a 64-bit object if we didn't find anything.
++  if test -z "$lt_cv_aix_libpath_"; then
++    lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
++  fi
+ fi
+ rm -f core conftest.err conftest.$ac_objext \
+     conftest$ac_exeext conftest.$ac_ext
+-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
++  if test -z "$lt_cv_aix_libpath_"; then
++    lt_cv_aix_libpath_="/usr/lib:/lib"
++  fi
++
++fi
++
++  aix_libpath=$lt_cv_aix_libpath_
++fi
+ 
+ 	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
+ 	  # Warning - without using the other run time loading flags,
+@@ -8554,20 +9094,63 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+       # Microsoft Visual C++.
+       # hardcode_libdir_flag_spec is actually meaningless, as there is
+       # no search path for DLLs.
+-      hardcode_libdir_flag_spec=' '
+-      allow_undefined_flag=unsupported
+-      # Tell ltmain to make .lib files, not .a files.
+-      libext=lib
+-      # Tell ltmain to make .dll files, not .so files.
+-      shrext_cmds=".dll"
+-      # FIXME: Setting linknames here is a bad hack.
+-      archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
+-      # The linker will automatically build a .lib file if we build a DLL.
+-      old_archive_from_new_cmds='true'
+-      # FIXME: Should let the user specify the lib program.
+-      old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
+-      fix_srcfile_path='`cygpath -w "$srcfile"`'
+-      enable_shared_with_static_runtimes=yes
++      case $cc_basename in
++      cl*)
++	# Native MSVC
++	hardcode_libdir_flag_spec=' '
++	allow_undefined_flag=unsupported
++	always_export_symbols=yes
++	file_list_spec='@'
++	# Tell ltmain to make .lib files, not .a files.
++	libext=lib
++	# Tell ltmain to make .dll files, not .so files.
++	shrext_cmds=".dll"
++	# FIXME: Setting linknames here is a bad hack.
++	archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
++	archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
++	    sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
++	  else
++	    sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
++	  fi~
++	  $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
++	  linknames='
++	# The linker will not automatically build a static lib if we build a DLL.
++	# _LT_TAGVAR(old_archive_from_new_cmds, )='true'
++	enable_shared_with_static_runtimes=yes
++	export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
++	# Don't use ranlib
++	old_postinstall_cmds='chmod 644 $oldlib'
++	postlink_cmds='lt_outputfile="@OUTPUT@"~
++	  lt_tool_outputfile="@TOOL_OUTPUT@"~
++	  case $lt_outputfile in
++	    *.exe|*.EXE) ;;
++	    *)
++	      lt_outputfile="$lt_outputfile.exe"
++	      lt_tool_outputfile="$lt_tool_outputfile.exe"
++	      ;;
++	  esac~
++	  if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
++	    $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
++	    $RM "$lt_outputfile.manifest";
++	  fi'
++	;;
++      *)
++	# Assume MSVC wrapper
++	hardcode_libdir_flag_spec=' '
++	allow_undefined_flag=unsupported
++	# Tell ltmain to make .lib files, not .a files.
++	libext=lib
++	# Tell ltmain to make .dll files, not .so files.
++	shrext_cmds=".dll"
++	# FIXME: Setting linknames here is a bad hack.
++	archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
++	# The linker will automatically build a .lib file if we build a DLL.
++	old_archive_from_new_cmds='true'
++	# FIXME: Should let the user specify the lib program.
++	old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
++	enable_shared_with_static_runtimes=yes
++	;;
++      esac
+       ;;
+ 
+     darwin* | rhapsody*)
+@@ -8628,7 +9211,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+ 
+     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
+     freebsd* | dragonfly*)
+-      archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
++      archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+       hardcode_libdir_flag_spec='-R$libdir'
+       hardcode_direct=yes
+       hardcode_shlibpath_var=no
+@@ -8636,7 +9219,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+ 
+     hpux9*)
+       if test "$GCC" = yes; then
+-	archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
++	archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
+       else
+ 	archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
+       fi
+@@ -8652,7 +9235,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+ 
+     hpux10*)
+       if test "$GCC" = yes && test "$with_gnu_ld" = no; then
+-	archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
++	archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+       else
+ 	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
+       fi
+@@ -8676,10 +9259,10 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
+ 	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+ 	  ;;
+ 	ia64*)
+-	  archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
++	  archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
+ 	  ;;
+ 	*)
+-	  archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
++	  archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+ 	  ;;
+ 	esac
+       else
+@@ -8758,26 +9341,39 @@ fi
+ 
+     irix5* | irix6* | nonstopux*)
+       if test "$GCC" = yes; then
+-	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
++	archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+ 	# Try to use the -exported_symbol ld option, if it does not
+ 	# work, assume that -exports_file does not work either and
+ 	# implicitly export all symbols.
+-        save_LDFLAGS="$LDFLAGS"
+-        LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
+-        if test x$gcc_no_link = xyes; then
++	# This should be the same for all languages, so no per-tag cache variable.
++	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
++$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
++if test "${lt_cv_irix_exported_symbol+set}" = set; then :
++  $as_echo_n "(cached) " >&6
++else
++  save_LDFLAGS="$LDFLAGS"
++	   LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
++	   if test x$gcc_no_link = xyes; then
+   as_fn_error "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5
+ fi
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h.  */
+-int foo(void) {}
++int foo (void) { return 0; }
+ _ACEOF
+ if ac_fn_c_try_link "$LINENO"; then :
+-  archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
+-
++  lt_cv_irix_exported_symbol=yes
++else
++  lt_cv_irix_exported_symbol=no
+ fi
+ rm -f core conftest.err conftest.$ac_objext \
+     conftest$ac_exeext conftest.$ac_ext
+-        LDFLAGS="$save_LDFLAGS"
++           LDFLAGS="$save_LDFLAGS"
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
++$as_echo "$lt_cv_irix_exported_symbol" >&6; }
++	if test "$lt_cv_irix_exported_symbol" = yes; then
++          archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
++	fi
+       else
+ 	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
+ 	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
+@@ -8862,7 +9458,7 @@ rm -f core conftest.err conftest.$ac_objext \
+     osf4* | osf5*)	# as osf3* with the addition of -msym flag
+       if test "$GCC" = yes; then
+ 	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
+-	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
++	archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
+ 	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
+       else
+ 	allow_undefined_flag=' -expect_unresolved \*'
+@@ -8881,9 +9477,9 @@ rm -f core conftest.err conftest.$ac_objext \
+       no_undefined_flag=' -z defs'
+       if test "$GCC" = yes; then
+ 	wlarc='${wl}'
+-	archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
++	archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+ 	archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
+-	  $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
++	  $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
+       else
+ 	case `$CC -V 2>&1` in
+ 	*"Compilers 5.0"*)
+@@ -9459,8 +10055,9 @@ cygwin* | mingw* | pw32* | cegcc*)
+   need_version=no
+   need_lib_prefix=no
+ 
+-  case $GCC,$host_os in
+-  yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
++  case $GCC,$cc_basename in
++  yes,*)
++    # gcc
+     library_names_spec='$libname.dll.a'
+     # DLL is installed to $(libdir)/../bin by postinstall_cmds
+     postinstall_cmds='base_file=`basename \${file}`~
+@@ -9493,13 +10090,71 @@ cygwin* | mingw* | pw32* | cegcc*)
+       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
+       ;;
+     esac
++    dynamic_linker='Win32 ld.exe'
++    ;;
++
++  *,cl*)
++    # Native MSVC
++    libname_spec='$name'
++    soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
++    library_names_spec='${libname}.dll.lib'
++
++    case $build_os in
++    mingw*)
++      sys_lib_search_path_spec=
++      lt_save_ifs=$IFS
++      IFS=';'
++      for lt_path in $LIB
++      do
++        IFS=$lt_save_ifs
++        # Let DOS variable expansion print the short 8.3 style file name.
++        lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
++        sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
++      done
++      IFS=$lt_save_ifs
++      # Convert to MSYS style.
++      sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
++      ;;
++    cygwin*)
++      # Convert to unix form, then to dos form, then back to unix form
++      # but this time dos style (no spaces!) so that the unix form looks
++      # like /cygdrive/c/PROGRA~1:/cygdr...
++      sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
++      sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
++      sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
++      ;;
++    *)
++      sys_lib_search_path_spec="$LIB"
++      if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
++        # It is most probably a Windows format PATH.
++        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
++      else
++        sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
++      fi
++      # FIXME: find the short name or the path components, as spaces are
++      # common. (e.g. "Program Files" -> "PROGRA~1")
++      ;;
++    esac
++
++    # DLL is installed to $(libdir)/../bin by postinstall_cmds
++    postinstall_cmds='base_file=`basename \${file}`~
++      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
++      dldir=$destdir/`dirname \$dlpath`~
++      test -d \$dldir || mkdir -p \$dldir~
++      $install_prog $dir/$dlname \$dldir/$dlname'
++    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
++      dlpath=$dir/\$dldll~
++       $RM \$dlpath'
++    shlibpath_overrides_runpath=yes
++    dynamic_linker='Win32 link.exe'
+     ;;
+ 
+   *)
++    # Assume MSVC wrapper
+     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
++    dynamic_linker='Win32 ld.exe'
+     ;;
+   esac
+-  dynamic_linker='Win32 ld.exe'
+   # FIXME: first we should search . and the directory the executable is in
+   shlibpath_var=PATH
+   ;;
+@@ -9591,7 +10246,7 @@ haiku*)
+   soname_spec='${libname}${release}${shared_ext}$major'
+   shlibpath_var=LIBRARY_PATH
+   shlibpath_overrides_runpath=yes
+-  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib'
++  sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
+   hardcode_into_libs=yes
+   ;;
+ 
+@@ -10405,7 +11060,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 10408 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -10449,10 +11104,10 @@ else
+ /* When -fvisbility=hidden is used, assume the code has been annotated
+    correspondingly for the symbols needed.  */
+ #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
+-void fnord () __attribute__((visibility("default")));
++int fnord () __attribute__((visibility("default")));
+ #endif
+ 
+-void fnord () { int i=42; }
++int fnord () { return 42; }
+ int main ()
+ {
+   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
+@@ -10511,7 +11166,7 @@ else
+   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
+   lt_status=$lt_dlunknown
+   cat > conftest.$ac_ext <<_LT_EOF
+-#line 10514 "configure"
++#line $LINENO "configure"
+ #include "confdefs.h"
+ 
+ #if HAVE_DLFCN_H
+@@ -10555,10 +11210,10 @@ else
+ /* When -fvisbility=hidden is used, assume the code has been annotated
+    correspondingly for the symbols needed.  */
+ #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
+-void fnord () __attribute__((visibility("default")));
++int fnord () __attribute__((visibility("default")));
+ #endif
+ 
+-void fnord () { int i=42; }
++int fnord () { return 42; }
+ int main ()
+ {
+   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
+@@ -11990,13 +12645,20 @@ exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
+ lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
+ lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
+ lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
++lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
++lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
+ reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
+ reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
+ OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
+ deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
+ file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
++file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
++want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
++DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
++sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
+ AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
+ AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
++archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
+ STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
+ RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
+ old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
+@@ -12011,14 +12673,17 @@ lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$de
+ lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
+ lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
+ lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
++nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
++lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
+ objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
+ MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
+ lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
+-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
+ lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
++lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
+ lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
+ lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
+ need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
++MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
+ DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
+ NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
+ LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
+@@ -12051,12 +12716,12 @@ hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_q
+ hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
+ inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
+ link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
+-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
+ always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
+ export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
+ exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
+ include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
+ prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
++postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
+ file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
+ variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
+ need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
+@@ -12111,8 +12776,13 @@ reload_flag \
+ OBJDUMP \
+ deplibs_check_method \
+ file_magic_cmd \
++file_magic_glob \
++want_nocaseglob \
++DLLTOOL \
++sharedlib_from_linklib_cmd \
+ AR \
+ AR_FLAGS \
++archiver_list_spec \
+ STRIP \
+ RANLIB \
+ CC \
+@@ -12122,12 +12792,14 @@ lt_cv_sys_global_symbol_pipe \
+ lt_cv_sys_global_symbol_to_cdecl \
+ lt_cv_sys_global_symbol_to_c_name_address \
+ lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
++nm_file_list_spec \
+ lt_prog_compiler_no_builtin_flag \
+-lt_prog_compiler_wl \
+ lt_prog_compiler_pic \
++lt_prog_compiler_wl \
+ lt_prog_compiler_static \
+ lt_cv_prog_compiler_c_o \
+ need_locks \
++MANIFEST_TOOL \
+ DSYMUTIL \
+ NMEDIT \
+ LIPO \
+@@ -12143,7 +12815,6 @@ no_undefined_flag \
+ hardcode_libdir_flag_spec \
+ hardcode_libdir_flag_spec_ld \
+ hardcode_libdir_separator \
+-fix_srcfile_path \
+ exclude_expsyms \
+ include_expsyms \
+ file_list_spec \
+@@ -12179,6 +12850,7 @@ module_cmds \
+ module_expsym_cmds \
+ export_symbols_cmds \
+ prelink_cmds \
++postlink_cmds \
+ postinstall_cmds \
+ postuninstall_cmds \
+ finish_cmds \
+@@ -12768,7 +13440,8 @@ $as_echo X"$file" |
+ # NOTE: Changes made to this file will be lost: look at ltmain.sh.
+ #
+ #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
+-#                 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
++#                 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
++#                 Inc.
+ #   Written by Gordon Matzigkeit, 1996
+ #
+ #   This file is part of GNU Libtool.
+@@ -12871,19 +13544,42 @@ SP2NL=$lt_lt_SP2NL
+ # turn newlines into spaces.
+ NL2SP=$lt_lt_NL2SP
+ 
++# convert \$build file names to \$host format.
++to_host_file_cmd=$lt_cv_to_host_file_cmd
++
++# convert \$build files to toolchain format.
++to_tool_file_cmd=$lt_cv_to_tool_file_cmd
++
+ # An object symbol dumper.
+ OBJDUMP=$lt_OBJDUMP
+ 
+ # Method to check whether dependent libraries are shared objects.
+ deplibs_check_method=$lt_deplibs_check_method
+ 
+-# Command to use when deplibs_check_method == "file_magic".
++# Command to use when deplibs_check_method = "file_magic".
+ file_magic_cmd=$lt_file_magic_cmd
+ 
++# How to find potential files when deplibs_check_method = "file_magic".
++file_magic_glob=$lt_file_magic_glob
++
++# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
++want_nocaseglob=$lt_want_nocaseglob
++
++# DLL creation program.
++DLLTOOL=$lt_DLLTOOL
++
++# Command to associate shared and link libraries.
++sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
++
+ # The archiver.
+ AR=$lt_AR
++
++# Flags to create an archive.
+ AR_FLAGS=$lt_AR_FLAGS
+ 
++# How to feed a file listing to the archiver.
++archiver_list_spec=$lt_archiver_list_spec
++
+ # A symbol stripping program.
+ STRIP=$lt_STRIP
+ 
+@@ -12913,6 +13609,12 @@ global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
+ # Transform the output of nm in a C name address pair when lib prefix is needed.
+ global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
+ 
++# Specify filename containing input files for \$NM.
++nm_file_list_spec=$lt_nm_file_list_spec
++
++# The root where to search for dependent libraries,and in which our libraries should be installed.
++lt_sysroot=$lt_sysroot
++
+ # The name of the directory that contains temporary libtool files.
+ objdir=$objdir
+ 
+@@ -12922,6 +13624,9 @@ MAGIC_CMD=$MAGIC_CMD
+ # Must we lock files when doing compilation?
+ need_locks=$lt_need_locks
+ 
++# Manifest tool.
++MANIFEST_TOOL=$lt_MANIFEST_TOOL
++
+ # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
+ DSYMUTIL=$lt_DSYMUTIL
+ 
+@@ -13036,12 +13741,12 @@ with_gcc=$GCC
+ # Compiler flag to turn off builtin functions.
+ no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
+ 
+-# How to pass a linker flag through the compiler.
+-wl=$lt_lt_prog_compiler_wl
+-
+ # Additional compiler flags for building library objects.
+ pic_flag=$lt_lt_prog_compiler_pic
+ 
++# How to pass a linker flag through the compiler.
++wl=$lt_lt_prog_compiler_wl
++
+ # Compiler flag to prevent dynamic linking.
+ link_static_flag=$lt_lt_prog_compiler_static
+ 
+@@ -13128,9 +13833,6 @@ inherit_rpath=$inherit_rpath
+ # Whether libtool must link a program against all its dependency libraries.
+ link_all_deplibs=$link_all_deplibs
+ 
+-# Fix the shell variable \$srcfile for the compiler.
+-fix_srcfile_path=$lt_fix_srcfile_path
+-
+ # Set to "yes" if exported symbols are required.
+ always_export_symbols=$always_export_symbols
+ 
+@@ -13146,6 +13848,9 @@ include_expsyms=$lt_include_expsyms
+ # Commands necessary for linking programs (against libraries) with templates.
+ prelink_cmds=$lt_prelink_cmds
+ 
++# Commands necessary for finishing linking programs.
++postlink_cmds=$lt_postlink_cmds
++
+ # Specify filename containing input files.
+ file_list_spec=$lt_file_list_spec
+ 
+@@ -13178,210 +13883,169 @@ ltmain="$ac_aux_dir/ltmain.sh"
+   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
+   # text mode, it properly converts lines to CR/LF.  This bash problem
+   # is reportedly fixed, but why not run on old versions too?
+-  sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
+-    || (rm -f "$cfgfile"; exit 1)
+-
+-  case $xsi_shell in
+-  yes)
+-    cat << \_LT_EOF >> "$cfgfile"
+-
+-# func_dirname file append nondir_replacement
+-# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
+-# otherwise set result to NONDIR_REPLACEMENT.
+-func_dirname ()
+-{
+-  case ${1} in
+-    */*) func_dirname_result="${1%/*}${2}" ;;
+-    *  ) func_dirname_result="${3}" ;;
+-  esac
+-}
+-
+-# func_basename file
+-func_basename ()
+-{
+-  func_basename_result="${1##*/}"
+-}
+-
+-# func_dirname_and_basename file append nondir_replacement
+-# perform func_basename and func_dirname in a single function
+-# call:
+-#   dirname:  Compute the dirname of FILE.  If nonempty,
+-#             add APPEND to the result, otherwise set result
+-#             to NONDIR_REPLACEMENT.
+-#             value returned in "$func_dirname_result"
+-#   basename: Compute filename of FILE.
+-#             value retuned in "$func_basename_result"
+-# Implementation must be kept synchronized with func_dirname
+-# and func_basename. For efficiency, we do not delegate to
+-# those functions but instead duplicate the functionality here.
+-func_dirname_and_basename ()
+-{
+-  case ${1} in
+-    */*) func_dirname_result="${1%/*}${2}" ;;
+-    *  ) func_dirname_result="${3}" ;;
+-  esac
+-  func_basename_result="${1##*/}"
+-}
+-
+-# func_stripname prefix suffix name
+-# strip PREFIX and SUFFIX off of NAME.
+-# PREFIX and SUFFIX must not contain globbing or regex special
+-# characters, hashes, percent signs, but SUFFIX may contain a leading
+-# dot (in which case that matches only a dot).
+-func_stripname ()
+-{
+-  # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
+-  # positional parameters, so assign one to ordinary parameter first.
+-  func_stripname_result=${3}
+-  func_stripname_result=${func_stripname_result#"${1}"}
+-  func_stripname_result=${func_stripname_result%"${2}"}
+-}
+-
+-# func_opt_split
+-func_opt_split ()
+-{
+-  func_opt_split_opt=${1%%=*}
+-  func_opt_split_arg=${1#*=}
+-}
+-
+-# func_lo2o object
+-func_lo2o ()
+-{
+-  case ${1} in
+-    *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
+-    *)    func_lo2o_result=${1} ;;
+-  esac
+-}
+-
+-# func_xform libobj-or-source
+-func_xform ()
+-{
+-  func_xform_result=${1%.*}.lo
+-}
+-
+-# func_arith arithmetic-term...
+-func_arith ()
+-{
+-  func_arith_result=$(( $* ))
+-}
+-
+-# func_len string
+-# STRING may not start with a hyphen.
+-func_len ()
+-{
+-  func_len_result=${#1}
+-}
+-
+-_LT_EOF
+-    ;;
+-  *) # Bourne compatible functions.
+-    cat << \_LT_EOF >> "$cfgfile"
+-
+-# func_dirname file append nondir_replacement
+-# Compute the dirname of FILE.  If nonempty, add APPEND to the result,
+-# otherwise set result to NONDIR_REPLACEMENT.
+-func_dirname ()
+-{
+-  # Extract subdirectory from the argument.
+-  func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
+-  if test "X$func_dirname_result" = "X${1}"; then
+-    func_dirname_result="${3}"
+-  else
+-    func_dirname_result="$func_dirname_result${2}"
+-  fi
+-}
+-
+-# func_basename file
+-func_basename ()
+-{
+-  func_basename_result=`$ECHO "${1}" | $SED "$basename"`
+-}
+-
+-
+-# func_stripname prefix suffix name
+-# strip PREFIX and SUFFIX off of NAME.
+-# PREFIX and SUFFIX must not contain globbing or regex special
+-# characters, hashes, percent signs, but SUFFIX may contain a leading
+-# dot (in which case that matches only a dot).
+-# func_strip_suffix prefix name
+-func_stripname ()
+-{
+-  case ${2} in
+-    .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
+-    *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
+-  esac
+-}
+-
+-# sed scripts:
+-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
+-my_sed_long_arg='1s/^-[^=]*=//'
+-
+-# func_opt_split
+-func_opt_split ()
+-{
+-  func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
+-  func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
+-}
+-
+-# func_lo2o object
+-func_lo2o ()
+-{
+-  func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
+-}
+-
+-# func_xform libobj-or-source
+-func_xform ()
+-{
+-  func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
+-}
+-
+-# func_arith arithmetic-term...
+-func_arith ()
+-{
+-  func_arith_result=`expr "$@"`
+-}
+-
+-# func_len string
+-# STRING may not start with a hyphen.
+-func_len ()
+-{
+-  func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
+-}
+-
+-_LT_EOF
+-esac
+-
+-case $lt_shell_append in
+-  yes)
+-    cat << \_LT_EOF >> "$cfgfile"
+-
+-# func_append var value
+-# Append VALUE to the end of shell variable VAR.
+-func_append ()
+-{
+-  eval "$1+=\$2"
+-}
+-_LT_EOF
+-    ;;
+-  *)
+-    cat << \_LT_EOF >> "$cfgfile"
+-
+-# func_append var value
+-# Append VALUE to the end of shell variable VAR.
+-func_append ()
+-{
+-  eval "$1=\$$1\$2"
+-}
+-
+-_LT_EOF
+-    ;;
+-  esac
+-
+-
+-  sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
+-    || (rm -f "$cfgfile"; exit 1)
+-
+-  mv -f "$cfgfile" "$ofile" ||
++  sed '$q' "$ltmain" >> "$cfgfile" \
++     || (rm -f "$cfgfile"; exit 1)
++
++  if test x"$xsi_shell" = xyes; then
++  sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
++func_dirname ()\
++{\
++\    case ${1} in\
++\      */*) func_dirname_result="${1%/*}${2}" ;;\
++\      *  ) func_dirname_result="${3}" ;;\
++\    esac\
++} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_basename ()$/,/^} # func_basename /c\
++func_basename ()\
++{\
++\    func_basename_result="${1##*/}"\
++} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
++func_dirname_and_basename ()\
++{\
++\    case ${1} in\
++\      */*) func_dirname_result="${1%/*}${2}" ;;\
++\      *  ) func_dirname_result="${3}" ;;\
++\    esac\
++\    func_basename_result="${1##*/}"\
++} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
++func_stripname ()\
++{\
++\    # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
++\    # positional parameters, so assign one to ordinary parameter first.\
++\    func_stripname_result=${3}\
++\    func_stripname_result=${func_stripname_result#"${1}"}\
++\    func_stripname_result=${func_stripname_result%"${2}"}\
++} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
++func_split_long_opt ()\
++{\
++\    func_split_long_opt_name=${1%%=*}\
++\    func_split_long_opt_arg=${1#*=}\
++} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
++func_split_short_opt ()\
++{\
++\    func_split_short_opt_arg=${1#??}\
++\    func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
++} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
++func_lo2o ()\
++{\
++\    case ${1} in\
++\      *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
++\      *)    func_lo2o_result=${1} ;;\
++\    esac\
++} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_xform ()$/,/^} # func_xform /c\
++func_xform ()\
++{\
++    func_xform_result=${1%.*}.lo\
++} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_arith ()$/,/^} # func_arith /c\
++func_arith ()\
++{\
++    func_arith_result=$(( $* ))\
++} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_len ()$/,/^} # func_len /c\
++func_len ()\
++{\
++    func_len_result=${#1}\
++} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++fi
++
++if test x"$lt_shell_append" = xyes; then
++  sed -e '/^func_append ()$/,/^} # func_append /c\
++func_append ()\
++{\
++    eval "${1}+=\\${2}"\
++} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
++func_append_quoted ()\
++{\
++\    func_quote_for_eval "${2}"\
++\    eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
++} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
++  && mv -f "$cfgfile.tmp" "$cfgfile" \
++    || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++test 0 -eq $? || _lt_function_replace_fail=:
++
++
++  # Save a `func_append' function call where possible by direct use of '+='
++  sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
++    && mv -f "$cfgfile.tmp" "$cfgfile" \
++      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++  test 0 -eq $? || _lt_function_replace_fail=:
++else
++  # Save a `func_append' function call even when '+=' is not available
++  sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
++    && mv -f "$cfgfile.tmp" "$cfgfile" \
++      || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
++  test 0 -eq $? || _lt_function_replace_fail=:
++fi
++
++if test x"$_lt_function_replace_fail" = x":"; then
++  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
++$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
++fi
++
++
++   mv -f "$cfgfile" "$ofile" ||
+     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
+   chmod +x "$ofile"
+ 
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0007-Add-the-armv5e-architecture-to-binutils.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0007-Add-the-armv5e-architecture-to-binutils.patch
index a037634..cb3f83b 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0007-Add-the-armv5e-architecture-to-binutils.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0007-Add-the-armv5e-architecture-to-binutils.patch
@@ -1,7 +1,7 @@
-From 743f42aaecb1ab89eba0eaf5e88ed67bbf3ba304 Mon Sep 17 00:00:00 2001
+From 4ff9dbe13f38e4fea24fbcc9879cf7352c0561ff Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:37:10 +0000
-Subject: [PATCH 07/13] Add the armv5e architecture to binutils
+Subject: [PATCH 07/14] Add the armv5e architecture to binutils
 
 Binutils has a comment that indicates it is supposed to match gcc for
 all of the support "-march=" settings, but it was lacking the armv5e setting.
@@ -19,10 +19,10 @@
  1 file changed, 1 insertion(+)
 
 diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
-index 2db6c2d..ab48168 100644
+index 3bd4bc9..5d99921 100644
 --- a/gas/config/tc-arm.c
 +++ b/gas/config/tc-arm.c
-@@ -24463,6 +24463,7 @@ static const struct arm_arch_option_table arm_archs[] =
+@@ -24791,6 +24791,7 @@ static const struct arm_arch_option_table arm_archs[] =
    ARM_ARCH_OPT ("armv4t",	ARM_ARCH_V4T,	 FPU_ARCH_FPA),
    ARM_ARCH_OPT ("armv4txm",	ARM_ARCH_V4TxM,	 FPU_ARCH_FPA),
    ARM_ARCH_OPT ("armv5",	ARM_ARCH_V5,	 FPU_ARCH_VFP),
@@ -31,5 +31,5 @@
    ARM_ARCH_OPT ("armv5txm",	ARM_ARCH_V5TxM,	 FPU_ARCH_VFP),
    ARM_ARCH_OPT ("armv5te",	ARM_ARCH_V5TE,	 FPU_ARCH_VFP),
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch
index 0ae68fc..f8382f8 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0008-don-t-let-the-distro-compiler-point-to-the-wrong-ins.patch
@@ -1,7 +1,7 @@
-From 4d3a9f6db604055348332b56889d466c058fa5f3 Mon Sep 17 00:00:00 2001
+From cb36d94dbd521752e6444418af500e139a26eabb Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:39:01 +0000
-Subject: [PATCH 08/13] don't let the distro compiler point to the wrong
+Subject: [PATCH 08/14] don't let the distro compiler point to the wrong
  installation location
 
 Thanks to RP for helping find the source code causing the issue.
@@ -17,10 +17,10 @@
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/libiberty/Makefile.in b/libiberty/Makefile.in
-index 9b87720..ff43f53 100644
+index 7d7e2f4..1aaaf0e 100644
 --- a/libiberty/Makefile.in
 +++ b/libiberty/Makefile.in
-@@ -361,7 +361,8 @@ install-strip: install
+@@ -364,7 +364,8 @@ install-strip: install
  # multilib-specific flags, it's overridden by FLAGS_TO_PASS from the
  # default multilib, so we have to take CFLAGS into account as well,
  # since it will be passed the multilib flags.
@@ -31,5 +31,5 @@
  	if test -n "${target_header_dir}"; then \
  		${mkinstalldirs} $(DESTDIR)$(libdir)/$(MULTIOSDIR); \
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0009-Upstream-Status-Inappropriate-distribution-codesourc.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0009-warn-for-uses-of-system-directories-when-cross-linki.patch
similarity index 82%
rename from yocto-poky/meta/recipes-devtools/binutils/binutils/0009-Upstream-Status-Inappropriate-distribution-codesourc.patch
rename to yocto-poky/meta/recipes-devtools/binutils/binutils/0009-warn-for-uses-of-system-directories-when-cross-linki.patch
index f800796..d3f510b 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0009-Upstream-Status-Inappropriate-distribution-codesourc.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0009-warn-for-uses-of-system-directories-when-cross-linki.patch
@@ -1,15 +1,7 @@
-From e02e119b278c3f404e97669e7180cac944134c91 Mon Sep 17 00:00:00 2001
+From 4daa841ce16ba52b717bdff9eb1dfc4f19638814 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 2 Mar 2015 01:41:04 +0000
-Subject: [PATCH 09/13] Upstream-Status: Inappropriate [distribution:
- codesourcery]
-
-Patch originally created by Mark Hatle, forward-ported to
-binutils 2.21 by Scott Garman.
-
-purpose:  warn for uses of system directories when cross linking
-
-Code Merged from Sourcery G++ binutils 2.19 - 4.4-277
+Date: Fri, 15 Jan 2016 06:31:09 +0000
+Subject: [PATCH 09/14] warn for uses of system directories when cross linking
 
 2008-07-02  Joseph Myers  <joseph@codesourcery.com>
 
@@ -57,8 +49,10 @@
 Signed-off-by: Scott Garman <scott.a.garman@intel.com>
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
+Upstream-Status: Pending
+
  ld/config.in    |  3 +++
- ld/configure    | 14 ++++++++++++++
+ ld/configure    | 16 ++++++++++++++++
  ld/configure.ac | 10 ++++++++++
  ld/ld.h         |  8 ++++++++
  ld/ld.texinfo   | 12 ++++++++++++
@@ -66,13 +60,13 @@
  ld/ldlex.h      |  2 ++
  ld/ldmain.c     |  2 ++
  ld/lexsup.c     | 16 ++++++++++++++++
- 9 files changed, 84 insertions(+)
+ 9 files changed, 86 insertions(+)
 
 diff --git a/ld/config.in b/ld/config.in
-index 2ab4844..766d23c 100644
+index 276fb77..35c58eb 100644
 --- a/ld/config.in
 +++ b/ld/config.in
-@@ -11,6 +11,9 @@
+@@ -14,6 +14,9 @@
     language is requested. */
  #undef ENABLE_NLS
  
@@ -83,18 +77,18 @@
  #undef EXTRA_SHLIB_EXTENSION
  
 diff --git a/ld/configure b/ld/configure
-index 2fbaebf..5726a08 100755
+index eb4f0d7..e9054b4 100755
 --- a/ld/configure
 +++ b/ld/configure
-@@ -787,6 +787,7 @@ with_lib_path
+@@ -790,6 +790,7 @@ with_lib_path
  enable_targets
  enable_64_bit_bfd
  with_sysroot
 +enable_poison_system_directories
  enable_gold
  enable_got
- enable_werror
-@@ -1443,6 +1444,8 @@ Optional Features:
+ enable_compressed_debug_sections
+@@ -1446,6 +1447,8 @@ Optional Features:
    --disable-largefile     omit support for large files
    --enable-targets        alternative target configurations
    --enable-64-bit-bfd     64-bit support (on hosts with narrower word sizes)
@@ -103,8 +97,8 @@
    --enable-gold[=ARG]     build gold [ARG={default,yes,no}]
    --enable-got=<type>     GOT handling scheme (target, single, negative,
                            multigot)
-@@ -16323,7 +16326,18 @@ else
- fi
+@@ -16306,6 +16309,19 @@ fi
+ 
  
  
 +# Check whether --enable-poison-system-directories was given.
@@ -115,18 +109,19 @@
 +fi
 +
 +if test "x${enable_poison_system_directories}" = "xyes"; then
- 
++
 +$as_echo "#define ENABLE_POISON_SYSTEM_DIRECTORIES 1" >>confdefs.h
 +
 +fi
- 
- # Check whether --enable-got was given.
- if test "${enable_got+set}" = set; then :
++
+ # Check whether --enable-gold was given.
+ if test "${enable_gold+set}" = set; then :
+   enableval=$enable_gold; case "${enableval}" in
 diff --git a/ld/configure.ac b/ld/configure.ac
-index 1bddfc9..e9edb7f 100644
+index e28f38e..7b474e7 100644
 --- a/ld/configure.ac
 +++ b/ld/configure.ac
-@@ -94,6 +94,16 @@ AC_SUBST(use_sysroot)
+@@ -95,6 +95,16 @@ AC_SUBST(use_sysroot)
  AC_SUBST(TARGET_SYSTEM_ROOT)
  AC_SUBST(TARGET_SYSTEM_ROOT_DEFINE)
  
@@ -144,12 +139,12 @@
  dnl "install_as_default" is set to false if gold is the default linker.
  dnl "installed_linker" is the installed BFD linker name.
 diff --git a/ld/ld.h b/ld/ld.h
-index f773ce7..adba0f6 100644
+index d84ec4e..3476b26 100644
 --- a/ld/ld.h
 +++ b/ld/ld.h
-@@ -161,6 +161,14 @@ typedef struct {
-   /* If TRUE we'll just print the default output on stdout.  */
-   bfd_boolean print_output_format;
+@@ -164,6 +164,14 @@ typedef struct {
+   /* If set, display the target memory usage (per memory region).  */
+   bfd_boolean print_memory_usage;
  
 +  /* If TRUE (the default) warn for uses of system directories when
 +     cross linking.  */
@@ -163,10 +158,10 @@
    enum endian_enum endian;
  
 diff --git a/ld/ld.texinfo b/ld/ld.texinfo
-index 502582c..dae168a 100644
+index 2389661..d06112b 100644
 --- a/ld/ld.texinfo
 +++ b/ld/ld.texinfo
-@@ -2212,6 +2212,18 @@ string identifying the original linked file does not change.
+@@ -2338,6 +2338,18 @@ string identifying the original linked file does not change.
  
  Passing @code{none} for @var{style} disables the setting from any
  @code{--build-id} options earlier on the command line.
@@ -186,7 +181,7 @@
  
  @c man end
 diff --git a/ld/ldfile.c b/ld/ldfile.c
-index 782ed7f..19a9ab4 100644
+index 96f9ecc..af231c0 100644
 --- a/ld/ldfile.c
 +++ b/ld/ldfile.c
 @@ -114,6 +114,23 @@ ldfile_add_library_path (const char *name, bfd_boolean cmdline)
@@ -214,23 +209,23 @@
  
  /* Try to open a BFD for a lang_input_statement.  */
 diff --git a/ld/ldlex.h b/ld/ldlex.h
-index e3e9b24..29487a3 100644
+index 6f11e7b..0ca3110 100644
 --- a/ld/ldlex.h
 +++ b/ld/ldlex.h
-@@ -140,6 +140,8 @@ enum option_values
-   OPTION_IGNORE_UNRESOLVED_SYMBOL,
-   OPTION_PUSH_STATE,
-   OPTION_POP_STATE,
+@@ -144,6 +144,8 @@ enum option_values
+   OPTION_PRINT_MEMORY_USAGE,
+   OPTION_REQUIRE_DEFINED_SYMBOL,
+   OPTION_ORPHAN_HANDLING,
 +  OPTION_NO_POISON_SYSTEM_DIRECTORIES,
 +  OPTION_ERROR_POISON_SYSTEM_DIRECTORIES,
  };
  
  /* The initial parser states.  */
 diff --git a/ld/ldmain.c b/ld/ldmain.c
-index 818d108..54c49f2 100644
+index bb0b9cc..a23c56c 100644
 --- a/ld/ldmain.c
 +++ b/ld/ldmain.c
-@@ -266,6 +266,8 @@ main (int argc, char **argv)
+@@ -257,6 +257,8 @@ main (int argc, char **argv)
    command_line.warn_mismatch = TRUE;
    command_line.warn_search_mismatch = TRUE;
    command_line.check_section_addresses = -1;
@@ -240,12 +235,12 @@
    /* We initialize DEMANGLING based on the environment variable
       COLLECT_NO_DEMANGLE.  The gcc collect2 program will demangle the
 diff --git a/ld/lexsup.c b/ld/lexsup.c
-index 4812c97..21b49df 100644
+index e2fb212..a2064f1 100644
 --- a/ld/lexsup.c
 +++ b/ld/lexsup.c
-@@ -513,6 +513,14 @@ static const struct ld_option ld_options[] =
-   { {"pop-state", no_argument, NULL, OPTION_POP_STATE},
-     '\0', NULL, N_("Pop state of flags governing input file handling"),
+@@ -530,6 +530,14 @@ static const struct ld_option ld_options[] =
+   { {"orphan-handling", required_argument, NULL, OPTION_ORPHAN_HANDLING},
+     '\0', N_("=MODE"), N_("Control how orphan sections are handled."),
      TWO_DASHES },
 +  { {"no-poison-system-directories", no_argument, NULL,
 +     OPTION_NO_POISON_SYSTEM_DIRECTORIES},
@@ -258,9 +253,9 @@
  };
  
  #define OPTION_COUNT ARRAY_SIZE (ld_options)
-@@ -1474,6 +1482,14 @@ parse_args (unsigned argc, char **argv)
- 	      free (oldp);
- 	    }
+@@ -1550,6 +1558,14 @@ parse_args (unsigned argc, char **argv)
+ 	    einfo (_("%P%F: invalid argument to option"
+ 		     " \"--orphan-handling\"\n"));
  	  break;
 +
 +	case OPTION_NO_POISON_SYSTEM_DIRECTORIES:
@@ -274,5 +269,5 @@
      }
  
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch
index 5451e74..4074241 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0010-Fix-rpath-in-libtool-when-sysroot-is-enabled.patch
@@ -1,7 +1,7 @@
-From edbee9a68e1c2e11c059668aa1d13001d9f3de06 Mon Sep 17 00:00:00 2001
+From bb9eb09411ddcef515f0f7ad7c29214b0766e960 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:42:38 +0000
-Subject: [PATCH 10/13] Fix rpath in libtool when sysroot is enabled
+Subject: [PATCH 10/14] Fix rpath in libtool when sysroot is enabled
 
 Enabling sysroot support in libtool exposed a bug where the final
 library had an RPATH encoded into it which still pointed to the
@@ -48,5 +48,5 @@
  	    if test -z "$hardcode_libdirs"; then
  	      hardcode_libdirs="$libdir"
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0011-Change-default-emulation-for-mips64-linux.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0011-Change-default-emulation-for-mips64-linux.patch
index d9d57ee..c0d2d71 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0011-Change-default-emulation-for-mips64-linux.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0011-Change-default-emulation-for-mips64-linux.patch
@@ -1,7 +1,7 @@
-From 2a5e8813d3c5db3e2b7d9dfa2ab27cccd5111e53 Mon Sep 17 00:00:00 2001
+From af1b4ee69b4fd617b88127ed40c3ca7351a9532f Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 2 Mar 2015 01:44:14 +0000
-Subject: [PATCH 11/13] Change default emulation for mips64*-*-linux
+Subject: [PATCH 11/14] Change default emulation for mips64*-*-linux
 
 we change the default emulations to be N64 instead of N32
 
@@ -14,10 +14,10 @@
  2 files changed, 8 insertions(+), 8 deletions(-)
 
 diff --git a/bfd/config.bfd b/bfd/config.bfd
-index 7bcb92a..03d2c6f 100644
+index c5688cb..5c27b49 100644
 --- a/bfd/config.bfd
 +++ b/bfd/config.bfd
-@@ -1062,12 +1062,12 @@ case "${targ}" in
+@@ -1087,12 +1087,12 @@ case "${targ}" in
      targ_selvecs="mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec mips_ecoff_be_vec mips_ecoff_le_vec"
      ;;
    mips64*el-*-linux*)
@@ -35,10 +35,10 @@
    mips*el-*-linux*)
      targ_defvec=mips_elf32_trad_le_vec
 diff --git a/ld/configure.tgt b/ld/configure.tgt
-index 24e36d1..740b2ea 100644
+index 6b6bbf2..b45b1e5 100644
 --- a/ld/configure.tgt
 +++ b/ld/configure.tgt
-@@ -476,11 +476,11 @@ mips*el-*-vxworks*)	targ_emul=elf32elmipvxworks
+@@ -509,11 +509,11 @@ mips*el-*-vxworks*)	targ_emul=elf32elmipvxworks
  mips*-*-vxworks*)	targ_emul=elf32ebmipvxworks
  		        targ_extra_emuls="elf32elmipvxworks" ;;
  mips*-*-windiss)	targ_emul=elf32mipswindiss ;;
@@ -55,5 +55,5 @@
  mips*el-*-linux-*)	targ_emul=elf32ltsmip
  			targ_extra_emuls="elf32btsmip elf32ltsmipn32 elf64ltsmip elf32btsmipn32 elf64btsmip"
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0012-Add-XLP-instructions-support.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0012-Add-support-for-Netlogic-XLP.patch
similarity index 81%
rename from yocto-poky/meta/recipes-devtools/binutils/binutils/0012-Add-XLP-instructions-support.patch
rename to yocto-poky/meta/recipes-devtools/binutils/binutils/0012-Add-support-for-Netlogic-XLP.patch
index c56ff91..af7f12f 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0012-Add-XLP-instructions-support.patch
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0012-Add-support-for-Netlogic-XLP.patch
@@ -1,37 +1,22 @@
-From 448329ea097447aee73d050045295c5a0ae8519e Mon Sep 17 00:00:00 2001
+From 9f967c555b3fda64af4549ae252a0fba00120529 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 2 Mar 2015 01:51:05 +0000
-Subject: [PATCH 12/13] Add XLP instructions support
+Date: Sun, 14 Feb 2016 17:06:19 +0000
+Subject: [PATCH 12/14] Add support for Netlogic XLP
 
-From 26adb06ce515aadfec08ce13109b4b98287f677b Mon Sep 17 00:00:00 2001
-From: Nebu Philips <nphilips@netlogicmicro.com>
-Date: Fri, 30 Jul 2010 15:10:03 -0700
-Subject: [PATCH] Add support for Netlogic XLP
+Patch From: Nebu Philips <nphilips@netlogicmicro.com>
 
 Using the mipsisa64r2nlm target, add support for XLP from
 Netlogic. Also, update vendor name to NLM wherever applicable.
----
- bfd/aoutx.h           |    1 +
- bfd/archures.c        |    1 +
- bfd/bfd-in2.h         |    1 +
- bfd/config.bfd        |    5 +++++
- bfd/cpu-mips.c        |    6 ++++--
- bfd/elfxx-mips.c      |    8 ++++++++
- binutils/readelf.c    |    1 +
- gas/config/tc-mips.c  |    4 +++-
- gas/configure         |    3 +++
- gas/configure.tgt     |    2 +-
- include/elf/mips.h    |    1 +
- include/opcode/mips.h |   10 ++++++++--
- ld/configure.tgt      |    2 ++
- opcodes/mips-dis.c    |   12 +++++-------
- opcodes/mips-opc.c    |   33 +++++++++++++++++++++------------
- 15 files changed, 65 insertions(+), 25 deletions(-)
 
-Upstream-Status: Pending
+Use 0x00000080 for INSN_XLP, the value 0x00000040 has already been
+assigned to INSN_OCTEON3
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Baoshan Pang <baoshan.pang@windriver.com>
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 ---
+Upstream-Status: Pending
+
  bfd/aoutx.h           |  1 +
  bfd/archures.c        |  1 +
  bfd/bfd-in2.h         |  1 +
@@ -50,7 +35,7 @@
  15 files changed, 65 insertions(+), 25 deletions(-)
 
 diff --git a/bfd/aoutx.h b/bfd/aoutx.h
-index 9385a98..a88df99 100644
+index f78b910..d0d8dd3 100644
 --- a/bfd/aoutx.h
 +++ b/bfd/aoutx.h
 @@ -802,6 +802,7 @@ NAME (aout, machine_type) (enum bfd_architecture arch,
@@ -62,34 +47,34 @@
  	  arch_flags = M_MIPS2;
  	  break;
 diff --git a/bfd/archures.c b/bfd/archures.c
-index c9fd6c8..547bd09 100644
+index 51068b9..727741f 100644
 --- a/bfd/archures.c
 +++ b/bfd/archures.c
-@@ -180,6 +180,7 @@ DESCRIPTION
- .#define bfd_mach_mips_octeonp		6601
+@@ -181,6 +181,7 @@ DESCRIPTION
  .#define bfd_mach_mips_octeon2		6502
+ .#define bfd_mach_mips_octeon3          6503
  .#define bfd_mach_mips_xlr              887682   {* decimal 'XLR'  *}
 +.#define bfd_mach_mips_xlp              887680   {* decimal 'XLP'  *}
  .#define bfd_mach_mipsisa32             32
  .#define bfd_mach_mipsisa32r2           33
  .#define bfd_mach_mipsisa32r3           34
 diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h
-index c7a2bb5..413b773 100644
+index 779ffbf..bf5a565 100644
 --- a/bfd/bfd-in2.h
 +++ b/bfd/bfd-in2.h
-@@ -1967,6 +1967,7 @@ enum bfd_architecture
- #define bfd_mach_mips_octeonp          6601
+@@ -1993,6 +1993,7 @@ enum bfd_architecture
  #define bfd_mach_mips_octeon2          6502
+ #define bfd_mach_mips_octeon3          6503
  #define bfd_mach_mips_xlr              887682   /* decimal 'XLR'  */
 +#define bfd_mach_mips_xlp              887680   /* decimal 'XLP'  */
  #define bfd_mach_mipsisa32             32
  #define bfd_mach_mipsisa32r2           33
  #define bfd_mach_mipsisa32r3           34
 diff --git a/bfd/config.bfd b/bfd/config.bfd
-index 03d2c6f..27086db 100644
+index 5c27b49..d553039 100644
 --- a/bfd/config.bfd
 +++ b/bfd/config.bfd
-@@ -1041,6 +1041,11 @@ case "${targ}" in
+@@ -1066,6 +1066,11 @@ case "${targ}" in
      targ_defvec=mips_elf32_le_vec
      targ_selvecs="mips_elf32_be_vec mips_elf64_be_vec mips_elf64_le_vec"
      ;;
@@ -102,12 +87,12 @@
      targ_defvec=mips_elf32_be_vec
      targ_selvecs="mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec"
 diff --git a/bfd/cpu-mips.c b/bfd/cpu-mips.c
-index b617aaa..19a99d1 100644
+index 8a9475d..de7e5a3 100644
 --- a/bfd/cpu-mips.c
 +++ b/bfd/cpu-mips.c
-@@ -103,7 +103,8 @@ enum
-   I_mipsocteonp,
+@@ -104,7 +104,8 @@ enum
    I_mipsocteon2,
+   I_mipsocteon3,
    I_xlr,
 -  I_micromips
 +  I_micromips,
@@ -115,9 +100,9 @@
  };
  
  #define NN(index) (&arch_info_struct[(index) + 1])
-@@ -153,7 +154,8 @@ static const bfd_arch_info_type arch_info_struct[] =
-   N (64, 64, bfd_mach_mips_octeonp,"mips:octeon+",  FALSE, NN(I_mipsocteonp)),
+@@ -155,7 +156,8 @@ static const bfd_arch_info_type arch_info_struct[] =
    N (64, 64, bfd_mach_mips_octeon2,"mips:octeon2",  FALSE, NN(I_mipsocteon2)),
+   N (64, 64, bfd_mach_mips_octeon3, "mips:octeon3",  FALSE, NN(I_mipsocteon3)),
    N (64, 64, bfd_mach_mips_xlr, "mips:xlr",       FALSE, NN(I_xlr)),
 -  N (64, 64, bfd_mach_mips_micromips,"mips:micromips",FALSE,0)
 +  N (64, 64, bfd_mach_mips_micromips,"mips:micromips",FALSE,NN(I_micromips)),
@@ -126,10 +111,10 @@
  
  /* The default architecture is mips:3000, but with a machine number of
 diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
-index 0df7abf..d268e86 100644
+index 1f2f4a3..700afd3 100644
 --- a/bfd/elfxx-mips.c
 +++ b/bfd/elfxx-mips.c
-@@ -6608,6 +6608,9 @@ _bfd_elf_mips_mach (flagword flags)
+@@ -6605,6 +6605,9 @@ _bfd_elf_mips_mach (flagword flags)
      case E_MIPS_MACH_XLR:
        return bfd_mach_mips_xlr;
  
@@ -139,7 +124,7 @@
      default:
        switch (flags & EF_MIPS_ARCH)
  	{
-@@ -11878,6 +11881,10 @@ mips_set_isa_flags (bfd *abfd)
+@@ -11901,6 +11904,10 @@ mips_set_isa_flags (bfd *abfd)
        val = E_MIPS_ARCH_64R2 | E_MIPS_MACH_OCTEON2;
        break;
  
@@ -150,7 +135,7 @@
      case bfd_mach_mipsisa32:
        val = E_MIPS_ARCH_32;
        break;
-@@ -14765,6 +14772,7 @@ static const struct mips_mach_extension mips_mach_extensions[] =
+@@ -13931,6 +13938,7 @@ static const struct mips_mach_extension mips_mach_extensions[] =
    { bfd_mach_mips_octeonp, bfd_mach_mips_octeon },
    { bfd_mach_mips_octeon, bfd_mach_mipsisa64r2 },
    { bfd_mach_mips_loongson_3a, bfd_mach_mipsisa64r2 },
@@ -159,10 +144,10 @@
    /* MIPS64 extensions.  */
    { bfd_mach_mipsisa64r2, bfd_mach_mipsisa64 },
 diff --git a/binutils/readelf.c b/binutils/readelf.c
-index 0c00b2f..6e9d5e4 100644
+index d5dd46f..66810cc 100644
 --- a/binutils/readelf.c
 +++ b/binutils/readelf.c
-@@ -2898,6 +2898,7 @@ get_machine_flags (unsigned e_flags, unsigned e_machine)
+@@ -3140,6 +3140,7 @@ get_machine_flags (unsigned e_flags, unsigned e_machine)
  	    case E_MIPS_MACH_OCTEON2: strcat (buf, ", octeon2"); break;
  	    case E_MIPS_MACH_OCTEON3: strcat (buf, ", octeon3"); break;
  	    case E_MIPS_MACH_XLR:  strcat (buf, ", xlr"); break;
@@ -171,10 +156,10 @@
  	    /* We simply ignore the field in this case to avoid confusion:
  	       MIPS ELF does not specify EF_MIPS_MACH, it is a GNU
 diff --git a/gas/config/tc-mips.c b/gas/config/tc-mips.c
-index c3e3e2a..8d64344 100644
+index a2d45a4..75902c0 100644
 --- a/gas/config/tc-mips.c
 +++ b/gas/config/tc-mips.c
-@@ -551,6 +551,7 @@ static int mips_32bitmode = 0;
+@@ -552,6 +552,7 @@ static int mips_32bitmode = 0;
     || mips_opts.arch == CPU_RM7000                    \
     || mips_opts.arch == CPU_VR5500                    \
     || mips_opts.micromips                             \
@@ -182,7 +167,7 @@
     )
  
  /* Whether the processor uses hardware interlocks to protect reads
-@@ -580,6 +581,7 @@ static int mips_32bitmode = 0;
+@@ -581,6 +582,7 @@ static int mips_32bitmode = 0;
      && mips_opts.isa != ISA_MIPS3)                    \
     || mips_opts.arch == CPU_R4300                     \
     || mips_opts.micromips                             \
@@ -190,20 +175,20 @@
     )
  
  /* Whether the processor uses hardware interlocks to protect reads
-@@ -18682,7 +18684,7 @@ static const struct mips_cpu_info mips_cpu_info_table[] =
+@@ -18702,7 +18704,7 @@ static const struct mips_cpu_info mips_cpu_info_table[] =
    /* Broadcom XLP.
       XLP is mostly like XLR, with the prominent exception that it is
       MIPS64R2 rather than MIPS64.  */
 -  { "xlp",	      0, 0,			ISA_MIPS64R2, CPU_XLR },
 +  { "xlp",	      0, 0,			ISA_MIPS64R2, CPU_XLP },
  
-   /* End marker */
-   { NULL, 0, 0, 0, 0 }
+   /* i6400.  */
+   { "i6400",	      0, ASE_MSA,		ISA_MIPS64R6, CPU_MIPS64R6},
 diff --git a/gas/configure b/gas/configure
-index 074886f..8091f2f 100755
+index 89f18b3..86b19ae 100755
 --- a/gas/configure
 +++ b/gas/configure
-@@ -12808,6 +12808,9 @@ _ACEOF
+@@ -12851,6 +12851,9 @@ _ACEOF
  	  mipsisa64r6 | mipsisa64r6el)
  	    mips_cpu=mips64r6
  	    ;;
@@ -214,10 +199,10 @@
  	    mips_cpu=r3900
  	    ;;
 diff --git a/gas/configure.tgt b/gas/configure.tgt
-index 1d92f55..06e8b4f 100644
+index 086e0d2..2b71270 100644
 --- a/gas/configure.tgt
 +++ b/gas/configure.tgt
-@@ -332,7 +332,7 @@ case ${generic_target} in
+@@ -339,7 +339,7 @@ case ${generic_target} in
    mips-*-sysv4*MP* | mips-*-gnu*)	fmt=elf em=tmips ;;
    mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
  					fmt=elf em=tmips ;;
@@ -227,7 +212,7 @@
    mips-*-openbsd*)			fmt=elf em=tmips ;;
  
 diff --git a/include/elf/mips.h b/include/elf/mips.h
-index 2ed6acd..e541f50 100644
+index 57de3bc..9ba141d 100644
 --- a/include/elf/mips.h
 +++ b/include/elf/mips.h
 @@ -285,6 +285,7 @@ END_RELOC_NUMBERS (R_MIPS_maxext)
@@ -239,10 +224,10 @@
  #define E_MIPS_MACH_OCTEON3	0x008e0000
  #define E_MIPS_MACH_5400	0x00910000
 diff --git a/include/opcode/mips.h b/include/opcode/mips.h
-index ef26167..ef53ec6 100644
+index 9318fcc..9be5645 100644
 --- a/include/opcode/mips.h
 +++ b/include/opcode/mips.h
-@@ -1227,8 +1227,10 @@ static const unsigned int mips_isa_table[] = {
+@@ -1228,8 +1228,10 @@ static const unsigned int mips_isa_table[] = {
  #define INSN_LOONGSON_2F          0x80000000
  /* Loongson 3A.  */
  #define INSN_LOONGSON_3A          0x00000400
@@ -251,19 +236,19 @@
 +/* Netlogic Xlr instruction */
 +#define INSN_XLR		0x00000020
 +/* Netlogic XlP instruction */
-+#define INSN_XLP		0x00000040
++#define INSN_XLP		0x00000080
  
  /* DSP ASE */
  #define ASE_DSP			0x00000001
-@@ -1324,6 +1326,7 @@ static const unsigned int mips_isa_table[] = {
- #define CPU_OCTEONP	6601
+@@ -1326,6 +1328,7 @@ static const unsigned int mips_isa_table[] = {
  #define CPU_OCTEON2	6502
+ #define CPU_OCTEON3	6503
  #define CPU_XLR     	887682   	/* decimal 'XLR'   */
 +#define CPU_XLP         887680      /* decimal 'XLP'   */
  
  /* Return true if the given CPU is included in INSN_* mask MASK.  */
  
-@@ -1398,6 +1401,9 @@ cpu_is_member (int cpu, unsigned int mask)
+@@ -1403,6 +1406,9 @@ cpu_is_member (int cpu, unsigned int mask)
        return ((mask & INSN_ISA_MASK) == INSN_ISA32R6)
  	     || ((mask & INSN_ISA_MASK) == INSN_ISA64R6);
  
@@ -274,10 +259,10 @@
        return FALSE;
      }
 diff --git a/ld/configure.tgt b/ld/configure.tgt
-index 740b2ea..4df13a7 100644
+index b45b1e5..fb2f36a 100644
 --- a/ld/configure.tgt
 +++ b/ld/configure.tgt
-@@ -462,6 +462,8 @@ mips*el-sde-elf*)	targ_emul=elf32ltsmip
+@@ -495,6 +495,8 @@ mips*el-sde-elf*)	targ_emul=elf32ltsmip
  mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
  			targ_emul=elf32btsmip
  			targ_extra_emuls="elf32ltsmip elf32btsmipn32 elf64btsmip elf32ltsmipn32 elf64ltsmip" ;;
@@ -287,10 +272,10 @@
  			targ_extra_emuls="elf32lr5900"
  			targ_extra_libpath=$targ_extra_emuls ;;
 diff --git a/opcodes/mips-dis.c b/opcodes/mips-dis.c
-index 1eb1d45..d6881af 100644
+index 8200920..40d9fe2 100644
 --- a/opcodes/mips-dis.c
 +++ b/opcodes/mips-dis.c
-@@ -655,13 +655,11 @@ const struct mips_arch_choice mips_arch_choices[] =
+@@ -648,13 +648,11 @@ const struct mips_arch_choice mips_arch_choices[] =
      mips_cp0sel_names_xlr, ARRAY_SIZE (mips_cp0sel_names_xlr),
      mips_cp1_names_mips3264, mips_hwr_names_numeric },
  
@@ -305,25 +290,25 @@
 +    ISA_MIPS64R2 | INSN_XLP, 0,
 +    mips_cp0_names_mips3264r2,
 +    mips_cp0sel_names_mips3264r2, ARRAY_SIZE (mips_cp0sel_names_mips3264r2),
-+    mips_hwr_names_mips3264r2 },
++    mips_cp1_names_mips3264, mips_hwr_names_mips3264r2 },
  
    /* This entry, mips16, is here only for ISA/processor selection; do
       not print its name.  */
 diff --git a/opcodes/mips-opc.c b/opcodes/mips-opc.c
-index 2c3bbad..9785a7e 100644
+index 402f887..3764836 100644
 --- a/opcodes/mips-opc.c
 +++ b/opcodes/mips-opc.c
-@@ -319,7 +319,8 @@ decode_mips_operand (const char *p)
- #define IOCT	(INSN_OCTEON | INSN_OCTEONP | INSN_OCTEON2)
- #define IOCTP	(INSN_OCTEONP | INSN_OCTEON2)
- #define IOCT2	INSN_OCTEON2
+@@ -320,7 +320,8 @@ decode_mips_operand (const char *p)
+ #define IOCTP	(INSN_OCTEONP | INSN_OCTEON2 | INSN_OCTEON3)
+ #define IOCT2	(INSN_OCTEON2 | INSN_OCTEON3)
+ #define IOCT3	INSN_OCTEON3
 -#define XLR     INSN_XLR
 +#define XLR	INSN_XLR
 +#define XLP	INSN_XLP
  #define IVIRT	ASE_VIRT
  #define IVIRT64	ASE_VIRT64
  
-@@ -956,6 +957,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -957,6 +958,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"clo",			"U,s",		0x70000021, 0xfc0007ff, WR_1|RD_2,		0,		I32|N55,	0,	I37 },
  {"clz",			"d,s",		0x00000050, 0xfc1f07ff, WR_1|RD_2,		0,		I37,		0,	0 },
  {"clz",			"U,s",		0x70000020, 0xfc0007ff, WR_1|RD_2,		0,		I32|N55,	0,	I37 },
@@ -331,7 +316,7 @@
  /* ctc0 is at the bottom of the table.  */
  {"ctc1",		"t,G",		0x44c00000, 0xffe007ff,	RD_1|WR_CC|CM,		0,		I1,		0,	0 },
  {"ctc1",		"t,S",		0x44c00000, 0xffe007ff,	RD_1|WR_CC|CM,		0,		I1,		0,	0 },
-@@ -988,12 +990,13 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -989,12 +991,13 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"daddiu",		"t,r,j",	0x64000000, 0xfc000000, WR_1|RD_2,		0,		I3,		0,	0 },
  {"daddu",		"d,v,t",	0x0000002d, 0xfc0007ff, WR_1|RD_2|RD_3,		0,		I3,		0,	0 },
  {"daddu",		"t,r,I",	0,    (int) M_DADDU_I,	INSN_MACRO,		0,		I3,		0,	0 },
@@ -346,7 +331,7 @@
  /* dctr and dctw are used on the r5000.  */
  {"dctr",		"o(b)",	 	0xbc050000, 0xfc1f0000, RD_2,			0,		I3,		0,	0 },
  {"dctw",		"o(b)",		0xbc090000, 0xfc1f0000, RD_2,			0,		I3,		0,	0 },
-@@ -1065,6 +1068,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1066,6 +1069,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"dmfc0",		"t,G,H",	0x40200000, 0xffe007f8,	WR_1|RD_C0|LC,		0,		I64,		0,	0 },
  {"dmfgc0",		"t,G",		0x40600100, 0xffe007ff, WR_1|RD_C0|LC,		0,		0,		IVIRT64, 0 },
  {"dmfgc0",		"t,G,H",	0x40600100, 0xffe007f8, WR_1|RD_C0|LC,		0,		0,		IVIRT64, 0 },
@@ -354,7 +339,7 @@
  {"dmt",			"",		0x41600bc1, 0xffffffff, TRAP,			0,		0,		MT32,	0 },
  {"dmt",			"t",		0x41600bc1, 0xffe0ffff, WR_1|TRAP,		0,		0,		MT32,	0 },
  {"dmtc0",		"t,G",		0x40a00000, 0xffe007ff,	RD_1|WR_C0|WR_CC|CM,	0,		I3,		0,	EE },
-@@ -1080,6 +1084,8 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1081,6 +1085,8 @@ const struct mips_opcode mips_builtin_opcodes[] =
  /* dmfc3 is at the bottom of the table.  */
  /* dmtc3 is at the bottom of the table.  */
  {"dmuh",		"d,s,t",	0x000000dc, 0xfc0007ff, WR_1|RD_2|RD_3,		0,		I69,		0,	0 },
@@ -363,7 +348,7 @@
  {"dmul",		"d,s,t",	0x0000009c, 0xfc0007ff, WR_1|RD_2|RD_3,		0,		I69,		0,	0 },
  {"dmul",		"d,v,t",	0x70000003, 0xfc0007ff, WR_1|RD_2|RD_3|WR_HILO,	0,		IOCT,		0,	0 },
  {"dmul",		"d,v,t",	0,    (int) M_DMUL,	INSN_MACRO,		0,		I3,		0,	M32|I69 },
-@@ -1229,9 +1235,9 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1234,9 +1240,9 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"ld",			"s,-b(+R)",	0xec180000, 0xfc1c0000, WR_1,			RD_pc,		I69,		0,	0 },
  {"ld",			"t,A(b)",	0,    (int) M_LD_AB,	INSN_MACRO,		0,		I1,		0,	0 },
  {"ld",			"t,o(b)",	0xdc000000, 0xfc000000, WR_1|RD_3|LM,		0,		I3,		0,	0 },
@@ -376,7 +361,7 @@
  {"ldc1",		"T,o(b)",	0xd4000000, 0xfc000000, WR_1|RD_3|CLD|FP_D,	0,		I2,		0,	SF },
  {"ldc1",		"E,o(b)",	0xd4000000, 0xfc000000, WR_1|RD_3|CLD|FP_D,	0,		I2,		0,	SF },
  {"ldc1",		"T,A(b)",	0,    (int) M_LDC1_AB,	INSN_MACRO,		INSN2_M_FP_D,	I2,		0,	SF },
-@@ -1396,7 +1402,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1401,7 +1407,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"mflo",		"d,9",		0x00000012, 0xff9f07ff, WR_1|RD_LO,		0,		0,		D32,	0 },
  {"mflo1",		"d",		0x70000012, 0xffff07ff,	WR_1|RD_LO,		0,		EE,		0,	0 },
  {"mflhxu",		"d",		0x00000052, 0xffff07ff,	WR_1|MOD_HILO,		0,		0,		SMT,	0 },
@@ -385,7 +370,7 @@
  {"mfsa",		"d",		0x00000028, 0xffff07ff,	WR_1,			0,		EE,		0,	0 },
  {"min.ob",		"X,Y,Q",	0x78000006, 0xfc20003f,	WR_1|RD_2|RD_3|FP_D,	0,		SB1,		MX,	0 },
  {"min.ob",		"D,S,Q",	0x48000006, 0xfc20003f,	WR_1|RD_2|RD_3|FP_D,	0,		N54,		0,	0 },
-@@ -1441,10 +1447,13 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1446,10 +1452,13 @@ const struct mips_opcode mips_builtin_opcodes[] =
  /* move is at the top of the table.  */
  {"msgn.qh",		"X,Y,Q",	0x78200000, 0xfc20003f,	WR_1|RD_2|RD_3|FP_D,	0,		0,		MX,	0 },
  {"msgsnd",		"t",		0,    (int) M_MSGSND,	INSN_MACRO,		0,		XLR,		0,	0 },
@@ -401,16 +386,16 @@
  {"msub.d",		"D,R,S,T",	0x4c000029, 0xfc00003f, WR_1|RD_2|RD_3|RD_4|FP_D, 0,		I4_33,		0,	I37 },
  {"msub.d",		"D,S,T",	0x46200019, 0xffe0003f,	WR_1|RD_2|RD_3|FP_D,	0,		IL2E,		0,	0 },
  {"msub.d",		"D,S,T",	0x72200019, 0xffe0003f,	WR_1|RD_2|RD_3|FP_D,	0,		IL2F,		0,	0 },
-@@ -1494,7 +1503,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1499,7 +1508,7 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"mtlo",		"s,7",		0x00000013, 0xfc1fe7ff, RD_1|WR_LO,		0,		0,		D32,	0 },
  {"mtlo1",		"s",		0x70000013, 0xfc1fffff,	RD_1|WR_LO,		0,		EE,		0,	0 },
  {"mtlhx",		"s",		0x00000053, 0xfc1fffff,	RD_1|MOD_HILO,		0,		0,		SMT,	0 },
 -{"mtcr",		"t,s",		0x70000019, 0xfc00ffff, RD_1|RD_2,		0,		XLR,		0,	0 },
 +{"mtcr",		"t,s",		0x70000019, 0xfc00ffff, RD_1,			0,		XLR|XLP,	0,	0 },
  {"mtm0",		"s",		0x70000008, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
+ {"mtm0",    		"s,t",		0x70000008, 0xfc00ffff, RD_1|RD_2,		0,		IOCT3,		0,	0 },
  {"mtm1",		"s",		0x7000000c, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
- {"mtm2",		"s",		0x7000000d, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
-@@ -1924,9 +1933,9 @@ const struct mips_opcode mips_builtin_opcodes[] =
+@@ -1936,9 +1945,9 @@ const struct mips_opcode mips_builtin_opcodes[] =
  {"suxc1",		"S,t(b)",	0x4c00000d, 0xfc0007ff, RD_1|RD_2|RD_3|SM|FP_D,	0,		I5_33|N55,	0,	I37},
  {"sw",			"t,o(b)",	0xac000000, 0xfc000000,	RD_1|RD_3|SM,		0,		I1,		0,	0 },
  {"sw",			"t,A(b)",	0,    (int) M_SW_AB,	INSN_MACRO,		0,		I1,		0,	0 },
@@ -424,5 +409,5 @@
  {"swc0",		"E,A(b)",	0,    (int) M_SWC0_AB,	INSN_MACRO,		0,		I1,		0,	IOCT|IOCTP|IOCT2|I37 },
  {"swc1",		"T,o(b)",	0xe4000000, 0xfc000000,	RD_1|RD_3|SM|FP_S,	0,		I1,		0,	0 },
 -- 
-2.1.4
+2.7.1
 
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0013-Fix-GOT-address-computations-in-initial-PLT-entries-.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0013-Fix-GOT-address-computations-in-initial-PLT-entries-.patch
new file mode 100644
index 0000000..24af120
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0013-Fix-GOT-address-computations-in-initial-PLT-entries-.patch
@@ -0,0 +1,72 @@
+From 9619a608528383a44ccc1637ae939b5f3e97adc5 Mon Sep 17 00:00:00 2001
+From: Sandra Loosemore <sandra@codesourcery.com>
+Date: Wed, 9 Dec 2015 16:13:58 -0800
+Subject: [PATCH 13/14] Fix GOT address computations in initial PLT entries for
+ nios2.
+
+2015-12-09  Sandra Loosemore  <sandra@codesourcery.com>
+
+	bfd/
+	* elf32-nios2.c (nios2_elf32_finish_dynamic_sections): Correct
+	%hiadj/%lo computations for _GLOBAL_OFFSET_TABLE_ in initial
+	PLT entries.  Assert alignment requirements.
+
+Signed-off-by: Marek Vasut <marex@denx.de>
+Upstream-Status: Backport
+---
+ bfd/elf32-nios2.c | 23 ++++++++++++++++-------
+ 1 file changed, 16 insertions(+), 7 deletions(-)
+
+diff --git a/bfd/elf32-nios2.c b/bfd/elf32-nios2.c
+index 6b29d8b..1c54320 100644
+--- a/bfd/elf32-nios2.c
++++ b/bfd/elf32-nios2.c
+@@ -5383,12 +5383,17 @@ nios2_elf32_finish_dynamic_sections (bfd *output_bfd,
+ 				 + sgotplt->output_offset);
+ 	  if (bfd_link_pic (info))
+ 	    {
+-	      bfd_vma corrected = got_address - (splt->output_section->vma
+-						 + splt->output_offset + 4);
++	      bfd_vma got_pcrel = got_address - (splt->output_section->vma
++						 + splt->output_offset);
++	      /* Both GOT and PLT must be aligned to a 16-byte boundary
++		 for the two loads to share the %hiadj part.  The 4-byte
++		 offset for nextpc is accounted for in the %lo offsets
++		 on the loads.  */
++	      BFD_ASSERT ((got_pcrel & 0xf) == 0);
+ 	      nios2_elf32_install_data (splt, nios2_so_plt0_entry, 0, 6);
+-	      nios2_elf32_install_imm16 (splt, 4, hiadj (corrected));
+-	      nios2_elf32_install_imm16 (splt, 12, (corrected & 0xffff) + 4);
+-	      nios2_elf32_install_imm16 (splt, 16, (corrected & 0xffff) + 8);
++	      nios2_elf32_install_imm16 (splt, 4, hiadj (got_pcrel));
++	      nios2_elf32_install_imm16 (splt, 12, got_pcrel & 0xffff);
++	      nios2_elf32_install_imm16 (splt, 16, (got_pcrel + 4) & 0xffff);
+ 	    }
+ 	  else
+ 	    {
+@@ -5404,6 +5409,10 @@ nios2_elf32_finish_dynamic_sections (bfd *output_bfd,
+ 			    6 | ((res_size - (res_offset + 4)) << 6),
+ 			    splt->contents + res_offset);
+ 
++	      /* The GOT must be aligned to a 16-byte boundary for the
++		 two loads to share the same %hiadj part.  */
++	      BFD_ASSERT ((got_address & 0xf) == 0);
++
+ 	      nios2_elf32_install_data (splt, nios2_plt0_entry, res_size, 7);
+ 	      nios2_elf32_install_imm16 (splt, res_size, hiadj (res_start));
+ 	      nios2_elf32_install_imm16 (splt, res_size + 4,
+@@ -5411,9 +5420,9 @@ nios2_elf32_finish_dynamic_sections (bfd *output_bfd,
+ 	      nios2_elf32_install_imm16 (splt, res_size + 12,
+ 					 hiadj (got_address));
+ 	      nios2_elf32_install_imm16 (splt, res_size + 16,
+-					 (got_address & 0xffff) + 4);
++					 (got_address + 4) & 0xffff);
+ 	      nios2_elf32_install_imm16 (splt, res_size + 20,
+-					 (got_address & 0xffff) + 8);
++					 (got_address + 8) & 0xffff);
+ 	    }
+ 	}
+     }
+-- 
+2.7.1
+
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0013-Fix-an-internal-error-in-do_print_to_mapfile-seen-wi.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0013-Fix-an-internal-error-in-do_print_to_mapfile-seen-wi.patch
deleted file mode 100644
index aee01c0..0000000
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0013-Fix-an-internal-error-in-do_print_to_mapfile-seen-wi.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 8e8f77ec2b6262e7d10af54700c340173d957267 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 27 Feb 2015 09:05:49 +0000
-Subject: [PATCH 13/13] Fix an internal error in do_print_to_mapfile seen with
- gold on arm
-
-This is due to missing implementation of do_print_to_mapfile for
-atrributea section (ARM.attributes), it started to show up after fix
-for PR gold/16980 was installed
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Submitted
----
- gold/attributes.h | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/gold/attributes.h b/gold/attributes.h
-index 2aa7a78..3d126e6 100644
---- a/gold/attributes.h
-+++ b/gold/attributes.h
-@@ -387,6 +387,10 @@ class Output_attributes_section_data : public Output_section_data
-   { }
- 
-  protected:
-+  // Write to a map file.
-+  void
-+  do_print_to_mapfile(Mapfile* mapfile) const
-+  { mapfile->print_output_data(this, _("** attributes")); }
-   // Write the data to the output file.
-   void
-   do_write(Output_file*);
--- 
-2.1.4
-
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0014-Correct-nios2-_gp-address-computation.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0014-Correct-nios2-_gp-address-computation.patch
new file mode 100644
index 0000000..86eeded
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils/0014-Correct-nios2-_gp-address-computation.patch
@@ -0,0 +1,106 @@
+From 27f155fd0ab4ba954366643dbfdc3c7104933794 Mon Sep 17 00:00:00 2001
+From: Sandra Loosemore <sandra@codesourcery.com>
+Date: Sun, 27 Dec 2015 12:30:26 -0800
+Subject: [PATCH 14/14] Correct nios2 _gp address computation.
+
+2015-12-27  Sandra Loosemore  <sandra@codesourcery.com>
+
+	bfd/
+	* elf32-nios2.c (nios2_elf_assign_gp): Correct computation of _gp
+	address.
+	(nios2_elf32_relocate_section): Tidy code for R_NIOS2_GPREL error
+	messages.
+
+Signed-off-by: Marek Vasut <marex@denx.de>
+Upstream-Status: Backport
+---
+ bfd/elf32-nios2.c | 31 +++++++++++++++++++++----------
+ 1 file changed, 21 insertions(+), 10 deletions(-)
+
+diff --git a/bfd/elf32-nios2.c b/bfd/elf32-nios2.c
+index 1c54320..babecf3 100644
+--- a/bfd/elf32-nios2.c
++++ b/bfd/elf32-nios2.c
+@@ -3086,7 +3086,15 @@ lookup:
+ 	case bfd_link_hash_defined:
+ 	case bfd_link_hash_defweak:
+ 	  gp_found = TRUE;
+-	  *pgp = lh->u.def.value;
++	  {
++	    asection *sym_sec = lh->u.def.section;
++	    bfd_vma sym_value = lh->u.def.value;
++
++	    if (sym_sec->output_section)
++	      sym_value = (sym_value + sym_sec->output_offset
++			   + sym_sec->output_section->vma);
++	    *pgp = sym_value;
++	  }
+ 	  break;
+ 	case bfd_link_hash_indirect:
+ 	case bfd_link_hash_warning:
+@@ -3719,7 +3727,6 @@ nios2_elf32_relocate_section (bfd *output_bfd,
+       struct elf32_nios2_link_hash_entry *eh;
+       bfd_vma relocation;
+       bfd_vma gp;
+-      bfd_vma reloc_address;
+       bfd_reloc_status_type r = bfd_reloc_ok;
+       const char *name = NULL;
+       int r_type;
+@@ -3762,12 +3769,6 @@ nios2_elf32_relocate_section (bfd *output_bfd,
+       if (bfd_link_relocatable (info))
+ 	continue;
+ 
+-      if (sec && sec->output_section)
+-	reloc_address = (sec->output_section->vma + sec->output_offset
+-			 + rel->r_offset);
+-      else
+-	reloc_address = 0;
+-
+       if (howto)
+ 	{
+ 	  switch (howto->type)
+@@ -3816,6 +3817,15 @@ nios2_elf32_relocate_section (bfd *output_bfd,
+ 	      /* Turns an absolute address into a gp-relative address.  */
+ 	      if (!nios2_elf_assign_gp (output_bfd, &gp, info))
+ 		{
++		  bfd_vma reloc_address;
++
++		  if (sec && sec->output_section)
++		    reloc_address = (sec->output_section->vma
++				     + sec->output_offset
++				     + rel->r_offset);
++		  else
++		    reloc_address = 0;
++
+ 		  format = _("global pointer relative relocation at address "
+ 			     "0x%08x when _gp not defined\n");
+ 		  sprintf (msgbuf, format, reloc_address);
+@@ -3825,7 +3835,7 @@ nios2_elf32_relocate_section (bfd *output_bfd,
+ 	      else
+ 		{
+ 		  bfd_vma symbol_address = rel->r_addend + relocation;
+-		  relocation = relocation + rel->r_addend - gp;
++		  relocation = symbol_address - gp;
+ 		  rel->r_addend = 0;
+ 		  if (((signed) relocation < -32768
+ 		       || (signed) relocation > 32767)
+@@ -3833,6 +3843,8 @@ nios2_elf32_relocate_section (bfd *output_bfd,
+ 			  || h->root.type == bfd_link_hash_defined
+ 			  || h->root.type == bfd_link_hash_defweak))
+ 		    {
++		      if (h)
++			name = h->root.root.string;
+ 		      format = _("Unable to reach %s (at 0x%08x) from the "
+ 				 "global pointer (at 0x%08x) because the "
+ 				 "offset (%d) is out of the allowed range, "
+@@ -3848,7 +3860,6 @@ nios2_elf32_relocate_section (bfd *output_bfd,
+ 						  rel->r_offset, relocation,
+ 						  rel->r_addend);
+ 		}
+-
+ 	      break;
+ 	    case R_NIOS2_UJMP:
+ 	      r = nios2_elf32_do_ujmp_relocate (input_bfd, howto,
+-- 
+2.7.1
+
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0014-gold-arm-Skip-pic-check-for-R_ARM_REL32.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0014-gold-arm-Skip-pic-check-for-R_ARM_REL32.patch
deleted file mode 100644
index e024302..0000000
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0014-gold-arm-Skip-pic-check-for-R_ARM_REL32.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From ebe26d855452d07e0152bd78d4966475d2de1de8 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 5 Mar 2015 07:30:31 +0000
-Subject: [PATCH] gold/arm: Skip pic check for R_ARM_REL32
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- gold/arm.cc | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/gold/arm.cc b/gold/arm.cc
-index 6c472bb..fb80435 100644
---- a/gold/arm.cc
-+++ b/gold/arm.cc
-@@ -7829,6 +7829,7 @@ Target_arm<big_endian>::Scan::check_non_pic(Relobj* object,
-     case elfcpp::R_ARM_TLS_DTPMOD32:
-     case elfcpp::R_ARM_TLS_DTPOFF32:
-     case elfcpp::R_ARM_TLS_TPOFF32:
-+    case elfcpp::R_ARM_REL32:
-       return;
- 
-     default:
--- 
-2.1.4
-
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/0015-Fix-dynamic-list-so-that-symbols-not-in-the-list-are.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/0015-Fix-dynamic-list-so-that-symbols-not-in-the-list-are.patch
deleted file mode 100644
index ee49c38..0000000
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/0015-Fix-dynamic-list-so-that-symbols-not-in-the-list-are.patch
+++ /dev/null
@@ -1,131 +0,0 @@
-From e9c1bdad269c0c3352eebcc9481ed65144001b0b Mon Sep 17 00:00:00 2001
-From: Cary Coutant <ccoutant@google.com>
-Date: Mon, 16 Feb 2015 22:15:12 -0800
-Subject: [PATCH] Fix --dynamic-list so that symbols not in the list are still
- exported.
-
-In PR 13577, the complaint was that -Bsymbolic was overriding the binding
-behavior for symbols listed in the --dynamic-list by setting the DT_SYMBOLIC
-tag in the dynamic table. In reading the Gnu ld manual, I decided that
---dynamic-list should be mutually exclusive of -Bsymbolic, and modified
-gold so that --dynamic-list would treat symbols listed as preemptible,
-and all other symbols as internally bound. I was wrong.
-
-PR 16992 shows that with --dynamic-list (and not -Bsymbolic), a symbol
-not listed in the dynamic list is being internally bound within the
-shared library, but because it's still in the dynamic symbol table, we
-expose it to a COPY relocation, and things go really bad from there.
-
-(I can reproduce the same failure, simply by turning on -Bsymbolic-functions
-with the Gnu linker. Even though the symbol is bound internally, it's
-still exported to the dynamic symbol table, and is exposed to a COPY
-relocation.)
-
-I've backed out part of the fix for PR 13577, and -Bsymbolic (or
--Bsymbolic-functions) can now be used with --dynamic-list, but if the
-two are used together, we do not set DT_SYMBOLIC or DF_SYMBOLIC
-(this matches Gnu ld behavior). We now treat symbols listed in the
-dynamic list as premptible, but we do not automatically treat symbols
-not listed there as non-premptible.
-
-gold/
-	PR gold/13577
-	PR gold/16992
-	* layout.cc (Layout::finish_dynamic_section): Don't set DT_SYMBOLIC or
-	DF_SYMBOLIC if --dynamic-list option is used.
-	* options.cc (General_options::finalize): --dynamic-list is not
-	mutually exclusive with -Bsymbolic.
-	* symtab.h (Symbol::is_preemptible): Don't exclude dynamic symbols not
-	listed in --dynamic-list.
-	* testsuite/Makefile.am (dynamic_list_lib2.so): Add
-	-Bsymbolic-functions.
-	* testsuite/Makefile.in: Regenerate.
----
-Upstream-Status: Backport
-
- gold/ChangeLog             | 14 ++++++++++++++
- gold/layout.cc             |  3 ++-
- gold/options.cc            |  7 -------
- gold/symtab.h              |  6 ++----
- gold/testsuite/Makefile.am |  2 +-
- gold/testsuite/Makefile.in |  2 +-
- 6 files changed, 20 insertions(+), 14 deletions(-)
-
-diff --git a/gold/layout.cc b/gold/layout.cc
-index bcdaac8..7836640 100644
---- a/gold/layout.cc
-+++ b/gold/layout.cc
-@@ -4873,7 +4873,8 @@ Layout::finish_dynamic_section(const Input_objects* input_objects,
-     flags |= elfcpp::DF_STATIC_TLS;
-   if (parameters->options().origin())
-     flags |= elfcpp::DF_ORIGIN;
--  if (parameters->options().Bsymbolic())
-+  if (parameters->options().Bsymbolic()
-+      && !parameters->options().have_dynamic_list())
-     {
-       flags |= elfcpp::DF_SYMBOLIC;
-       // Add DT_SYMBOLIC for compatibility with older loaders.
-diff --git a/gold/options.cc b/gold/options.cc
-index 7eb8f27..7f1f69e 100644
---- a/gold/options.cc
-+++ b/gold/options.cc
-@@ -1200,13 +1200,6 @@ General_options::finalize()
-   // in the path, as appropriate.
-   this->add_sysroot();
- 
--  // --dynamic-list overrides -Bsymbolic and -Bsymbolic-functions.
--  if (this->have_dynamic_list())
--    {
--      this->set_Bsymbolic(false);
--      this->set_Bsymbolic_functions(false);
--    }
--
-   // Now that we've normalized the options, check for contradictory ones.
-   if (this->shared() && this->is_static())
-     gold_fatal(_("-shared and -static are incompatible"));
-diff --git a/gold/symtab.h b/gold/symtab.h
-index aa0cb68..9413360 100644
---- a/gold/symtab.h
-+++ b/gold/symtab.h
-@@ -604,10 +604,8 @@ class Symbol
-     if (parameters->options().in_dynamic_list(this->name()))
-       return true;
- 
--    // If the user used -Bsymbolic or provided a --dynamic-list script,
--    // then nothing (else) is preemptible.
--    if (parameters->options().Bsymbolic()
--        || parameters->options().have_dynamic_list())
-+    // If the user used -Bsymbolic, then nothing (else) is preemptible.
-+    if (parameters->options().Bsymbolic())
-       return false;
- 
-     // If the user used -Bsymbolic-functions, then functions are not
-diff --git a/gold/testsuite/Makefile.am b/gold/testsuite/Makefile.am
-index f767c21..7b73f9d 100644
---- a/gold/testsuite/Makefile.am
-+++ b/gold/testsuite/Makefile.am
-@@ -1518,7 +1518,7 @@ dynamic_list_lib1.o: dynamic_list_lib1.cc
- 	$(CXXCOMPILE) -c -fpic -o $@ $<
- 
- dynamic_list_lib2.so: gcctestdir/ld dynamic_list_lib2.o $(srcdir)/dynamic_list_2.t
--	$(CXXLINK) -Bgcctestdir/ -shared -Wl,--dynamic-list,$(srcdir)/dynamic_list_2.t dynamic_list_lib2.o
-+	$(CXXLINK) -Bgcctestdir/ -shared -Wl,-Bsymbolic-functions -Wl,--dynamic-list,$(srcdir)/dynamic_list_2.t dynamic_list_lib2.o
- dynamic_list_lib2.o: dynamic_list_lib2.cc
- 	$(CXXCOMPILE) -c -fpic -o $@ $<
- 
-diff --git a/gold/testsuite/Makefile.in b/gold/testsuite/Makefile.in
-index 217e472..b4ae3fd 100644
---- a/gold/testsuite/Makefile.in
-+++ b/gold/testsuite/Makefile.in
-@@ -5319,7 +5319,7 @@ uninstall-am:
- @GCC_TRUE@@NATIVE_LINKER_TRUE@	$(CXXCOMPILE) -c -fpic -o $@ $<
- 
- @GCC_TRUE@@NATIVE_LINKER_TRUE@dynamic_list_lib2.so: gcctestdir/ld dynamic_list_lib2.o $(srcdir)/dynamic_list_2.t
--@GCC_TRUE@@NATIVE_LINKER_TRUE@	$(CXXLINK) -Bgcctestdir/ -shared -Wl,--dynamic-list,$(srcdir)/dynamic_list_2.t dynamic_list_lib2.o
-+@GCC_TRUE@@NATIVE_LINKER_TRUE@	$(CXXLINK) -Bgcctestdir/ -shared -Wl,-Bsymbolic-functions -Wl,--dynamic-list,$(srcdir)/dynamic_list_2.t dynamic_list_lib2.o
- @GCC_TRUE@@NATIVE_LINKER_TRUE@dynamic_list_lib2.o: dynamic_list_lib2.cc
- @GCC_TRUE@@NATIVE_LINKER_TRUE@	$(CXXCOMPILE) -c -fpic -o $@ $<
- 
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/add-thunderx-support-for-gas.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/add-thunderx-support-for-gas.patch
deleted file mode 100644
index 0f6875e..0000000
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/add-thunderx-support-for-gas.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-Add thunderx support to gas
-
-Upstream-Status: Submitted [https://sourceware.org/ml/binutils/2014-10/msg00170.html]
-
-Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
-
-Author: Andrew Pinski <apinski@cavium.com>
-Date: Mon, 20 Oct 2014 11:42:58 -0700
-
-    This patch adds -mcpu=thunderx support to gas.
-
-diff -Naurp git_org/gas/config/tc-aarch64.c git/gas/config/tc-aarch64.c
---- git_org/gas/config/tc-aarch64.c	2015-09-07 02:13:51.988973523 -0700
-+++ git/gas/config/tc-aarch64.c	2015-09-07 02:15:21.705981540 -0700
-@@ -7206,6 +7206,7 @@ static const struct aarch64_cpu_option_t
- 				 AARCH64_FEATURE_CRC), "Cortex-A57"},
-   {"cortex-a72", AARCH64_FEATURE (AARCH64_ARCH_V8,
- 				  AARCH64_FEATURE_CRC), "Cortex-A72"},
-+  {"thunderx",		AARCH64_ARCH_V8, "Cavium ThunderX"},				  
-   {"exynos-m1", AARCH64_FEATURE (AARCH64_ARCH_V8,
- 				 AARCH64_FEATURE_CRC | AARCH64_FEATURE_CRYPTO),
- 				 "Samsung Exynos M1"},
-diff -Naurp git_org/gas/doc/c-aarch64.texi git/gas/doc/c-aarch64.texi
---- git_org/gas/doc/c-aarch64.texi	2015-09-07 02:13:51.969973522 -0700
-+++ git/gas/doc/c-aarch64.texi	2015-09-07 02:16:03.364985262 -0700
-@@ -58,6 +58,7 @@ on the target processor.  The following
- @code{cortex-a53},
- @code{cortex-a57},
- @code{cortex-a72},
-+@code{thunderx},
- @code{exynos-m1},
- @code{xgene1},
- and
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils/binutils-octeon3.patch b/yocto-poky/meta/recipes-devtools/binutils/binutils/binutils-octeon3.patch
deleted file mode 100644
index 4e8c69f..0000000
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils/binutils-octeon3.patch
+++ /dev/null
@@ -1,272 +0,0 @@
-Upstream-Status: Backport
-
-https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commit;h=2c62985659da21a3fe16062d211a7158f79ad2e9
-
-Signed-off-By: Armin Kuster <akuster@mvista.com>
-
-Index: git/bfd/archures.c
-===================================================================
---- git.orig/bfd/archures.c
-+++ git/bfd/archures.c
-@@ -179,6 +179,7 @@ DESCRIPTION
- .#define bfd_mach_mips_octeon		6501
- .#define bfd_mach_mips_octeonp		6601
- .#define bfd_mach_mips_octeon2		6502
-+.#define bfd_mach_mips_octeon3		6503
- .#define bfd_mach_mips_xlr              887682   {* decimal 'XLR'  *}
- .#define bfd_mach_mips_xlp              887680   {* decimal 'XLP'  *}
- .#define bfd_mach_mipsisa32             32
-Index: git/bfd/bfd-in2.h
-===================================================================
---- git.orig/bfd/bfd-in2.h
-+++ git/bfd/bfd-in2.h
-@@ -1969,6 +1969,7 @@ enum bfd_architecture
- #define bfd_mach_mips_octeon           6501
- #define bfd_mach_mips_octeonp          6601
- #define bfd_mach_mips_octeon2          6502
-+#define bfd_mach_mips_octeon3          6503
- #define bfd_mach_mips_xlr              887682   /* decimal 'XLR'  */
- #define bfd_mach_mips_xlp              887680   /* decimal 'XLP'  */
- #define bfd_mach_mipsisa32             32
-Index: git/bfd/cpu-mips.c
-===================================================================
---- git.orig/bfd/cpu-mips.c
-+++ git/bfd/cpu-mips.c
-@@ -102,6 +102,7 @@ enum
-   I_mipsocteon,
-   I_mipsocteonp,
-   I_mipsocteon2,
-+  I_mipsocteon3,
-   I_xlr,
-   I_micromips,
-   I_xlp
-@@ -153,6 +154,7 @@ static const bfd_arch_info_type arch_inf
-   N (64, 64, bfd_mach_mips_octeon,"mips:octeon",  FALSE, NN(I_mipsocteon)),
-   N (64, 64, bfd_mach_mips_octeonp,"mips:octeon+",  FALSE, NN(I_mipsocteonp)),
-   N (64, 64, bfd_mach_mips_octeon2,"mips:octeon2",  FALSE, NN(I_mipsocteon2)),
-+  N (64, 64, bfd_mach_mips_octeon3,"mips:octeon3",  FALSE, NN(I_mipsocteon3)),
-   N (64, 64, bfd_mach_mips_xlr, "mips:xlr",       FALSE, NN(I_xlr)),
-   N (64, 64, bfd_mach_mips_micromips,"mips:micromips",FALSE,NN(I_micromips)),
-   N (64, 64, bfd_mach_mips_xlp, "mips:xlp",      FALSE, 0)
-Index: git/bfd/elfxx-mips.c
-===================================================================
---- git.orig/bfd/elfxx-mips.c
-+++ git/bfd/elfxx-mips.c
-@@ -6604,6 +6604,9 @@ _bfd_elf_mips_mach (flagword flags)
-     case E_MIPS_MACH_LS3A:
-       return bfd_mach_mips_loongson_3a;
- 
-+    case E_MIPS_MACH_OCTEON3:
-+      return bfd_mach_mips_octeon3;
-+
-     case E_MIPS_MACH_OCTEON2:
-       return bfd_mach_mips_octeon2;
- 
-@@ -11878,6 +11881,10 @@ mips_set_isa_flags (bfd *abfd)
-       val = E_MIPS_ARCH_64R2 | E_MIPS_MACH_OCTEON;
-       break;
- 
-+    case bfd_mach_mips_octeon3:
-+      val = E_MIPS_ARCH_64R2 | E_MIPS_MACH_OCTEON3;
-+      break;
-+
-     case bfd_mach_mips_xlr:
-       val = E_MIPS_ARCH_64 | E_MIPS_MACH_XLR;
-       break;
-@@ -14773,6 +14780,7 @@ struct mips_mach_extension
- static const struct mips_mach_extension mips_mach_extensions[] =
- {
-   /* MIPS64r2 extensions.  */
-+  { bfd_mach_mips_octeon3, bfd_mach_mips_octeon2 },
-   { bfd_mach_mips_octeon2, bfd_mach_mips_octeonp },
-   { bfd_mach_mips_octeonp, bfd_mach_mips_octeon },
-   { bfd_mach_mips_octeon, bfd_mach_mipsisa64r2 },
-Index: git/gas/config/tc-mips.c
-===================================================================
---- git.orig/gas/config/tc-mips.c
-+++ git/gas/config/tc-mips.c
-@@ -306,7 +306,7 @@ static unsigned int file_ase_explicit;
- unsigned long mips_gprmask;
- unsigned long mips_cprmask[4];
- 
--/* True if any MIPS16 code was produced.  */
-+/* 2True if any MIPS16 code was produced.  */
- static int file_ase_mips16;
- 
- #define ISA_SUPPORTS_MIPS16E (mips_opts.isa == ISA_MIPS32		\
-@@ -510,7 +510,8 @@ static int mips_32bitmode = 0;
- #define CPU_HAS_ROR(CPU)	CPU_HAS_DROR (CPU)
- 
- /* True if CPU is in the Octeon family */
--#define CPU_IS_OCTEON(CPU) ((CPU) == CPU_OCTEON || (CPU) == CPU_OCTEONP || (CPU) == CPU_OCTEON2)
-+#define CPU_IS_OCTEON(CPU) ((CPU) == CPU_OCTEON || (CPU) == CPU_OCTEONP \
-+                           || (CPU) == CPU_OCTEON2 || (CPU) == CPU_OCTEON3)
- 
- /* True if CPU has seq/sne and seqi/snei instructions.  */
- #define CPU_HAS_SEQ(CPU)	(CPU_IS_OCTEON (CPU))
-@@ -18677,6 +18678,7 @@ static const struct mips_cpu_info mips_c
-   { "octeon",	      0, 0,			ISA_MIPS64R2, CPU_OCTEON },
-   { "octeon+",	      0, 0,			ISA_MIPS64R2, CPU_OCTEONP },
-   { "octeon2",	      0, 0,			ISA_MIPS64R2, CPU_OCTEON2 },
-+  { "octeon3",        0, ASE_VIRT | ASE_VIRT64, ISA_MIPS64R2, CPU_OCTEON3 },
- 
-   /* RMI Xlr */
-   { "xlr",	      0, 0,			ISA_MIPS64,   CPU_XLR },
-Index: git/gas/doc/c-mips.texi
-===================================================================
---- git.orig/gas/doc/c-mips.texi
-+++ git/gas/doc/c-mips.texi
-@@ -382,6 +382,7 @@ loongson3a,
- octeon,
- octeon+,
- octeon2,
-+octeon3,
- xlr,
- xlp
- @end quotation
-Index: git/gas/testsuite/gas/mips/mips.exp
-===================================================================
---- git.orig/gas/testsuite/gas/mips/mips.exp
-+++ git/gas/testsuite/gas/mips/mips.exp
-@@ -1102,6 +1102,7 @@ if { [istarget mips*-*-vxworks*] } {
-     run_list_test_arches "octeon-ill"	[mips_arch_list_matching octeon]
-     run_dump_test_arches "octeon-pref"	[mips_arch_list_matching octeon]
-     run_dump_test_arches "octeon2"	[mips_arch_list_matching octeon2]
-+    run_dump_test_arches "octeon3"	[mips_arch_list_matching octeon3]
- 
-     run_dump_test "smartmips"
-     run_dump_test_arches "mips32-dsp"	[mips_arch_list_matching mips32r2 \
-Index: git/gas/testsuite/gas/mips/octeon3.d
-===================================================================
---- /dev/null
-+++ git/gas/testsuite/gas/mips/octeon3.d
-@@ -0,0 +1,20 @@
-+#objdump: -d -r --show-raw-insn
-+#name: MIPS octeon3 instructions
-+
-+.*: +file format .*mips.*
-+
-+Disassembly of section .text:
-+
-+[0-9a-f]+ <foo>:
-+.*:    71ec0008        mtm0    t3,t0
-+.*:    71a40008        mtm0    t1,a0
-+.*:    7083000c        mtm1    a0,v1
-+.*:    70e1000c        mtm1    a3,at
-+.*:    7022000d        mtm2    at,v0
-+.*:    7083000c        mtm1    a0,v1
-+.*:    70a20009        mtp0    a1,v0
-+.*:    70c40009        mtp0    a2,a0
-+.*:    7083000a        mtp1    a0,v1
-+.*:    70e1000a        mtp1    a3,at
-+.*:    7022000b        mtp2    at,v0
-+.*:    7083000a        mtp1    a0,v1
-Index: git/gas/testsuite/gas/mips/octeon3.s
-===================================================================
---- /dev/null
-+++ git/gas/testsuite/gas/mips/octeon3.s
-@@ -0,0 +1,22 @@
-++       .text
-+       .set noreorder
-+       .set noat
-+
-+foo:
-+        mtm0 $15,$12
-+        mtm0 $13,$4
-+
-+        mtm1 $4,$3
-+        mtm1 $7,$1
-+
-+        mtm2 $1,$2
-+        mtm1 $4,$3
-+
-+        mtp0 $5,$2
-+        mtp0 $6,$4
-+
-+        mtp1 $4,$3
-+        mtp1 $7,$1
-+
-+        mtp2 $1,$2
-+        mtp1 $4,$3
-Index: git/include/opcode/mips.h
-===================================================================
---- git.orig/include/opcode/mips.h
-+++ git/include/opcode/mips.h
-@@ -1196,6 +1196,7 @@ static const unsigned int mips_isa_table
- #define INSN_OCTEON		  0x00000800
- #define INSN_OCTEONP		  0x00000200
- #define INSN_OCTEON2		  0x00000100
-+#define INSN_OCTEON3		  0x00000040
- 
- /* MIPS R5900 instruction */
- #define INSN_5900                 0x00004000
-@@ -1325,6 +1326,7 @@ static const unsigned int mips_isa_table
- #define CPU_OCTEON	6501
- #define CPU_OCTEONP	6601
- #define CPU_OCTEON2	6502
-+#define CPU_OCTEON3	6503
- #define CPU_XLR     	887682   	/* decimal 'XLR'   */
- #define CPU_XLP         887680      /* decimal 'XLP'   */
- 
-@@ -1391,6 +1393,9 @@ cpu_is_member (int cpu, unsigned int mas
-     case CPU_OCTEON2:
-       return (mask & INSN_OCTEON2) != 0;
- 
-+    case CPU_OCTEON3:
-+      return (mask & INSN_OCTEON3) != 0;
-+
-     case CPU_XLR:
-       return (mask & INSN_XLR) != 0;
- 
-Index: git/opcodes/mips-dis.c
-===================================================================
---- git.orig/opcodes/mips-dis.c
-+++ git/opcodes/mips-dis.c
-@@ -649,6 +649,11 @@ const struct mips_arch_choice mips_arch_
-     ISA_MIPS64R2 | INSN_OCTEON2, 0, mips_cp0_names_numeric,
-     NULL, 0, mips_cp1_names_mips3264, mips_hwr_names_numeric },
- 
-+  { "octeon3",   1, bfd_mach_mips_octeon3, CPU_OCTEON3,
-+    ISA_MIPS64R2 | INSN_OCTEON3, ASE_VIRT | ASE_VIRT64,
-+    mips_cp0_names_numeric,
-+    NULL, 0, mips_cp1_names_mips3264, mips_hwr_names_numeric },
-+
-   { "xlr", 1, bfd_mach_mips_xlr, CPU_XLR,
-     ISA_MIPS64 | INSN_XLR, 0,
-     mips_cp0_names_xlr,
-Index: git/opcodes/mips-opc.c
-===================================================================
---- git.orig/opcodes/mips-opc.c
-+++ git/opcodes/mips-opc.c
-@@ -316,9 +316,10 @@ decode_mips_operand (const char *p)
- #define N5	(INSN_5400 | INSN_5500)
- #define N54	INSN_5400
- #define N55	INSN_5500
--#define IOCT	(INSN_OCTEON | INSN_OCTEONP | INSN_OCTEON2)
--#define IOCTP	(INSN_OCTEONP | INSN_OCTEON2)
--#define IOCT2	INSN_OCTEON2
-+#define IOCT	(INSN_OCTEON | INSN_OCTEONP | INSN_OCTEON2 | INSN_OCTEON3)
-+#define IOCTP	(INSN_OCTEONP | INSN_OCTEON2 | INSN_OCTEON3)
-+#define IOCT2	(INSN_OCTEON2 | INSN_OCTEON3)
-+#define IOCT3  INSN_OCTEON3
- #define XLR	INSN_XLR
- #define XLP	INSN_XLP
- #define IVIRT	ASE_VIRT
-@@ -1505,11 +1506,17 @@ const struct mips_opcode mips_builtin_op
- {"mtlhx",		"s",		0x00000053, 0xfc1fffff,	RD_1|MOD_HILO,		0,		0,		SMT,	0 },
- {"mtcr",		"t,s",		0x70000019, 0xfc00ffff, RD_1,			0,		XLR|XLP,	0,	0 },
- {"mtm0",		"s",		0x70000008, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
-+{"mtm0",                "s,t",          0x70000008, 0xfc00ffff, RD_1|RD_2,              0,              IOCT3,          0,      0 },
- {"mtm1",		"s",		0x7000000c, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
-+{"mtm1",                "s,t",          0x7000000c, 0xfc00ffff, RD_1|RD_2,              0,              IOCT3,          0,      0 },
- {"mtm2",		"s",		0x7000000d, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
-+{"mtm2",                "s,t",          0x7000000d, 0xfc00ffff, RD_1|RD_2,              0,              IOCT3,          0,      0 },
- {"mtp0",		"s",		0x70000009, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
-+{"mtp0",                "s,t",          0x70000009, 0xfc00ffff, RD_1|RD_2,              0,              IOCT3,          0,      0 },
- {"mtp1",		"s",		0x7000000a, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
-+{"mtp1",                "s,t",          0x7000000a, 0xfc00ffff, RD_1|RD_2,              0,              IOCT3,          0,      0 },
- {"mtp2",		"s",		0x7000000b, 0xfc1fffff, RD_1,			0,		IOCT,		0,	0 },
-+{"mtp2",                "s,t",          0x7000000b, 0xfc00ffff, RD_1|RD_2,              0,              IOCT3,          0,      0 },
- {"mtsa",		"s",		0x00000029, 0xfc1fffff,	RD_1,			0,		EE,		0,	0 },
- {"mtsab",		"s,j",		0x04180000, 0xfc1f0000,	RD_1,			0,		EE,		0,	0 },
- {"mtsah",		"s,j",		0x04190000, 0xfc1f0000,	RD_1,			0,		EE,		0,	0 },
diff --git a/yocto-poky/meta/recipes-devtools/binutils/binutils_2.25.1.bb b/yocto-poky/meta/recipes-devtools/binutils/binutils_2.26.bb
similarity index 96%
rename from yocto-poky/meta/recipes-devtools/binutils/binutils_2.25.1.bb
rename to yocto-poky/meta/recipes-devtools/binutils/binutils_2.26.bb
index 6f42671..b70ffbf 100644
--- a/yocto-poky/meta/recipes-devtools/binutils/binutils_2.25.1.bb
+++ b/yocto-poky/meta/recipes-devtools/binutils/binutils_2.26.bb
@@ -7,6 +7,7 @@
                 --enable-install-libbfd \
                 --enable-install-libiberty \
                 --enable-shared \
+                --with-system-zlib \
                 "
 
 EXTRA_OECONF_class-native = "--enable-targets=all \
diff --git a/yocto-poky/meta/recipes-devtools/bison/bison/add-with-bisonlocaledir.patch b/yocto-poky/meta/recipes-devtools/bison/bison/add-with-bisonlocaledir.patch
new file mode 100644
index 0000000..35c0f6f
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/bison/bison/add-with-bisonlocaledir.patch
@@ -0,0 +1,58 @@
+From 41fdca818cdc7bd686c31aff4088b89280d71a42 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 17 Feb 2016 22:01:28 -0500
+Subject: [PATCH] m4/bison-i18n.m4: add --with-bisonlocaledir to assign
+ BISON_LOCALEDIR
+
+The variable BISON_LOCALEDIR is assigned only by the output of
+'bison --print-localedir', we add option --with-bisonlocaledir
+to assign it explicitly. It is helpful for user to split the
+native compile and cross compile.
+
+For backward compatibility, if option not used, it still
+make use of the output of 'bison --print-localedir'.
+
+Upstream-Status: Submitted [bison-patches@gnu.org]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ m4/bison-i18n.m4 | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
+diff --git a/m4/bison-i18n.m4 b/m4/bison-i18n.m4
+index 8e57caf..c36f498 100644
+--- a/m4/bison-i18n.m4
++++ b/m4/bison-i18n.m4
+@@ -16,11 +16,16 @@ dnl sets BISON_LOCALEDIR to indicate where to find the bison-runtime.mo files
+ dnl and defines YYENABLE_NLS if there are bison-runtime.mo files at all.
+ AC_DEFUN([BISON_I18N],
+ [
++  dnl Default is not to set bisonlocaledir
++  AC_ARG_WITH([bisonlocaledir],
++    [  --with-bisonlocaledir   sets BISON_LOCALEDIR to indicate where to find the bison-runtime.mo files],
++    BISON_LOCALEDIR=$withval,
++    BISON_LOCALEDIR=)
++
+   if test -z "$USE_NLS"; then
+     echo "The BISON-I18N macro is used without being preceded by AM-GNU-GETTEXT." 1>&2
+     exit 1
+   fi
+-  BISON_LOCALEDIR=
+   BISON_USE_NLS=no
+   if test "$USE_NLS" = yes; then
+     dnl Determine bison's localedir.
+@@ -28,9 +33,10 @@ AC_DEFUN([BISON_I18N],
+     dnl But even is YACC is called "yacc", it may be a script that invokes bison
+     dnl and accepts the --print-localedir option.
+     dnl YACC's default value is empty; BISON's default value is :.
+-    if (${YACC-${BISON-:}} --print-localedir) >/dev/null 2>&1; then
++    if test -z "$BISON_LOCALEDIR" -a ${YACC-${BISON-:}} --print-localedir >/dev/null 2>&1; then
+       BISON_LOCALEDIR=`${YACC-${BISON-:}} --print-localedir`
+     fi
++    AC_MSG_RESULT([$BISON_LOCALEDIR])
+     AC_SUBST([BISON_LOCALEDIR])
+     if test -n "$BISON_LOCALEDIR"; then
+       dnl There is no need to enable internationalization if the user doesn't
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/bison/bison_3.0.4.bb b/yocto-poky/meta/recipes-devtools/bison/bison_3.0.4.bb
index 708e9a3..cffcd88 100644
--- a/yocto-poky/meta/recipes-devtools/bison/bison_3.0.4.bb
+++ b/yocto-poky/meta/recipes-devtools/bison/bison_3.0.4.bb
@@ -14,6 +14,7 @@
            file://0001-Unset-need_charset_alias-when-building-for-musl.patch \
            file://dont-depend-on-help2man.patch.patch \
            file://0001-src-local.mk-fix-parallel-issue.patch \
+           file://add-with-bisonlocaledir.patch \
 "
 
 # No point in hardcoding path to m4, just use PATH
diff --git a/yocto-poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.7.bb b/yocto-poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.8.bb
similarity index 98%
rename from yocto-poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.7.bb
rename to yocto-poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.8.bb
index 4b0a980..86c614a 100644
--- a/yocto-poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.7.bb
+++ b/yocto-poky/meta/recipes-devtools/bootchart2/bootchart2_0.14.8.bb
@@ -88,12 +88,14 @@
 LICENSE = "GPL-3.0"
 LIC_FILES_CHKSUM = "file://COPYING;md5=44ac4678311254db62edf8fd39cb8124"
 
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.\d+)*)"
+
 SRC_URI = "git://github.com/mmeeks/bootchart.git \
            file://bootchartd_stop.sh \
           "
 
 S = "${WORKDIR}/git"
-SRCREV = "6f050b65ae9f266645f04f0aecab9efb88375f1c"
+SRCREV = "48e0071048564c6af75ab969e842d6dec808da09"
 
 inherit systemd
 inherit update-rc.d
@@ -148,7 +150,6 @@
 FILES_${PN} += "${base_libdir}/bootchart/bootchart-collector"
 FILES_${PN} += "${base_libdir}/bootchart/tmpfs"
 FILES_${PN} += "${libdir}"
-FILES_${PN}-dbg += "${base_libdir}/bootchart/.debug"
 FILES_${PN}-doc += "${datadir}/docs"
 
 RCONFLICTS_${PN} = "bootchart"
diff --git a/yocto-poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/fix-symlink-creation-multiple-times.patch b/yocto-poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/fix-symlink-creation-multiple-times.patch
new file mode 100644
index 0000000..a945496
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/btrfs-tools/btrfs-tools/fix-symlink-creation-multiple-times.patch
@@ -0,0 +1,46 @@
+From 05ab78e9183575e38f342e05a056cb7bcd1e52e1 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 18 Feb 2016 20:41:28 -0500
+Subject: [PATCH] btrfs-progs: fix symlink creation multiple times
+
+The rule to create symlink in Makefile caused parallel issue:
+$ make -j 40 DESTDIR=/image install BUILD_VERBOSE=1
+...
+  1     [LN]     libbtrfs.so.0
+  2     [LN]     libbtrfs.so
+  3 ln -s -f libbtrfs.so.0.1 libbtrfs.so.0
+  4 ln -s -f libbtrfs.so.0.1 libbtrfs.so.0
+  5 ln -s -f libbtrfs.so.0.1 libbtrfs.so
+  6 ln -s -f libbtrfs.so.0.1 libbtrfs.so
+...
+
+It failed occasionally:
+...
+|symlinkat: couldn't stat 'git/libbtrfs.so' even though symlink
+creation succeeded (No such file or directory).
+|ln: failed to create symbolic link 'libbtrfs.so': No such file or directory
+...
+
+Upstream-Status: Submitted [linux-btrfs@vger.kernel.org]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ Makefile.in | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 1f4002e..16eeaf9 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -236,8 +236,7 @@ $(libs_static): $(libbtrfs_objects)
+ 
+ $(lib_links):
+ 	@echo "    [LN]     $@"
+-	$(Q)$(LN_S) -f libbtrfs.so.0.1 libbtrfs.so.0
+-	$(Q)$(LN_S) -f libbtrfs.so.0.1 libbtrfs.so
++	$(Q)$(LN_S) -f libbtrfs.so.0.1 $@
+ 
+ # keep intermediate files from the below implicit rules around
+ .PRECIOUS: $(addsuffix .o,$(progs))
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.1.2.bb b/yocto-poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.4.bb
similarity index 81%
rename from yocto-poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.1.2.bb
rename to yocto-poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.4.bb
index 37c622b..32e7bae 100644
--- a/yocto-poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.1.2.bb
+++ b/yocto-poky/meta/recipes-devtools/btrfs-tools/btrfs-tools_4.4.bb
@@ -11,15 +11,19 @@
 LIC_FILES_CHKSUM = "file://COPYING;md5=fcb02dc552a041dee27e4b85c7396067"
 SECTION = "base"
 DEPENDS = "util-linux attr e2fsprogs lzo acl"
+RDEPENDS_${PN} = "libgcc"
 
-SRCREV = "7f1328ccb5d159efe850d4eaea9b49bbe8c4181e"
+SRCREV = "21258fab2caeade405a15ba932d373b364aa6e8c"
 SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/kdave/btrfs-progs.git \
            file://fix-parallel.patch \
+           file://fix-symlink-creation-multiple-times.patch \
 "
 
 inherit autotools-brokensep pkgconfig
 
 EXTRA_OECONF += "--disable-documentation"
+EXTRA_OECONF_append_libc-musl = " --disable-backtrace "
+
 
 do_configure_prepend() {
       sh autogen.sh
diff --git a/yocto-poky/meta/recipes-devtools/ccache/ccache_3.2.3.bb b/yocto-poky/meta/recipes-devtools/ccache/ccache_3.2.3.bb
deleted file mode 100644
index 97f557a..0000000
--- a/yocto-poky/meta/recipes-devtools/ccache/ccache_3.2.3.bb
+++ /dev/null
@@ -1,10 +0,0 @@
-require ccache.inc
-
-LICENSE = "GPLv3+"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=b3c337e7664559a789d9f7a93e5283c1"
-
-SRCREV = "4cad46e8ee0053144bb00919f0dadd20c1f87013"
-
-SRC_URI += "file://0001-Fix-regression-in-recent-change-related-to-zlib-in-n.patch \
-            file://0002-dev.mk.in-fix-file-name-too-long.patch \
-"
diff --git a/yocto-poky/meta/recipes-devtools/ccache/ccache_3.2.4.bb b/yocto-poky/meta/recipes-devtools/ccache/ccache_3.2.4.bb
new file mode 100644
index 0000000..fd45e41
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/ccache/ccache_3.2.4.bb
@@ -0,0 +1,10 @@
+require ccache.inc
+
+LICENSE = "GPLv3+"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=b3c337e7664559a789d9f7a93e5283c1"
+
+SRCREV = "2254797f1c5cfb83c4272da7b138f7f47218eb7d"
+
+SRC_URI += " \
+            file://0002-dev.mk.in-fix-file-name-too-long.patch \
+"
diff --git a/yocto-poky/meta/recipes-devtools/ccache/files/0001-Fix-regression-in-recent-change-related-to-zlib-in-n.patch b/yocto-poky/meta/recipes-devtools/ccache/files/0001-Fix-regression-in-recent-change-related-to-zlib-in-n.patch
deleted file mode 100644
index f5bd9aa..0000000
--- a/yocto-poky/meta/recipes-devtools/ccache/files/0001-Fix-regression-in-recent-change-related-to-zlib-in-n.patch
+++ /dev/null
@@ -1,73 +0,0 @@
-From f74c76107933046309861680b741adc67ac2a34e Mon Sep 17 00:00:00 2001
-From: Joel Rosdahl <joel@rosdahl.net>
-Date: Mon, 17 Aug 2015 19:05:14 +0200
-Subject: [PATCH] Fix regression in recent change related to zlib in
- nonstandard location
-
-To allow for specifying a -L flag in LDFLAGS and have it take effect for
--lz, 0220de9c8ebfb18caae2ac1aa163d060e98ceade put -lz in extra_libs
-instead of extra_ldflags. However, extra_libs is supposed to contain
-paths to libraries which are prerequisites of the ccache link rule, and
-some older versions of make got confused by seeing -lz as a
-prerequisite.
-
-This fix is to revert 0220de9c8ebfb18caae2ac1aa163d060e98ceade and
-instead make sure that LDFLAGS comes before extra_ldflags.
-
-Upstream-Status: Backport
----
- Makefile.in  |  2 +-
- NEWS.txt     | 10 ++++++++++
- configure.ac |  2 +-
- 3 files changed, 12 insertions(+), 2 deletions(-)
-
-diff --git a/Makefile.in b/Makefile.in
-index e7515b1..d3621cd 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -20,7 +20,7 @@ RANLIB = @RANLIB@
- 
- all_cflags = $(CFLAGS)
- all_cppflags = @DEFS@ @extra_cppflags@ -DSYSCONFDIR=$(sysconfdir) -I. -I$(srcdir) $(CPPFLAGS)
--all_ldflags = @extra_ldflags@ $(LDFLAGS)
-+all_ldflags = $(LDFLAGS) @extra_ldflags@
- extra_libs = @extra_libs@
- 
- base_sources = \
-diff --git a/NEWS.txt b/NEWS.txt
-index f13feeb..eaeadf6 100644
---- a/NEWS.txt
-+++ b/NEWS.txt
-@@ -2,6 +2,16 @@ ccache news
- ===========
- 
- 
-+Unreleased 3.2.4
-+----------------
-+
-+Bug fixes
-+~~~~~~~~~
-+
-+- Fixed build error related to zlib on systems with older make versions
-+  (regression in ccache 3.2.3).
-+
-+
- ccache 3.2.3
- ------------
- Release date: 2015-08-16
-diff --git a/configure.ac b/configure.ac
-index 8d8ce92..9e65588 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -120,7 +120,7 @@ if test x${use_bundled_zlib} = xyes; then
-     extra_libs="zlib/libz.a"
-     mkdir -p zlib
- else
--    extra_libs="-lz"
-+    extra_ldflags="-lz"
- fi
- 
- dnl Linking on Windows needs ws2_32
--- 
-2.1.4
-
diff --git a/yocto-poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01a31.bb b/yocto-poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01.bb
similarity index 61%
rename from yocto-poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01a31.bb
rename to yocto-poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01.bb
index d0f36e2..ff4d5ac 100644
--- a/yocto-poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01a31.bb
+++ b/yocto-poky/meta/recipes-devtools/cdrtools/cdrtools-native_3.01.bb
@@ -7,15 +7,20 @@
 LICENSE = "GPLv2 & CDDL-1.0 & LGPLv2.1+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=32f68170be424c2cd64804337726b312"
 
-SRC_URI = "${SOURCEFORGE_MIRROR}/project/cdrtools/alpha/cdrtools-${PV}.tar.bz2"
+SRC_URI = "${SOURCEFORGE_MIRROR}/project/cdrtools/cdrtools-${REALPV}.tar.bz2"
 
-SRC_URI[md5sum] = "78172557894f469b4584d008e93ec469"
-SRC_URI[sha256sum] = "183b5c12777779e78d8b69461aae52401f863768e7e7391d60730006f8cadc5a"
+SRC_URI[md5sum] = "7d45c5b7e1f78d85d1583b361aee6e8b"
+SRC_URI[sha256sum] = "ed282eb6276c4154ce6a0b5dee0bdb81940d0cbbfc7d03f769c4735ef5f5860f"
 
-S = "${WORKDIR}/cdrtools-3.01"
+EXTRA_OEMAKE = "-e MAKEFLAGS="
 
 inherit native
 
+PV = "3.01a31+really3.01"
+REALPV = "3.01"
+
+S = "${WORKDIR}/${BPN}-${REALPV}"
+
 do_install() {
 	make install GMAKE_NOWARN=true INS_BASE=${prefix} DESTDIR=${D}
 }
diff --git a/yocto-poky/meta/recipes-devtools/chrpath/chrpath_0.16.bb b/yocto-poky/meta/recipes-devtools/chrpath/chrpath_0.16.bb
index 0a3b06e..e115eb5 100644
--- a/yocto-poky/meta/recipes-devtools/chrpath/chrpath_0.16.bb
+++ b/yocto-poky/meta/recipes-devtools/chrpath/chrpath_0.16.bb
@@ -13,6 +13,8 @@
 SRC_URI[md5sum] = "2bf8d1d1ee345fc8a7915576f5649982"
 SRC_URI[sha256sum] = "bb0d4c54bac2990e1bdf8132f2c9477ae752859d523e141e72b3b11a12c26e7b"
 
+UPSTREAM_CHECK_URI = "http://alioth.debian.org/frs/?group_id=31052"
+
 inherit autotools
 
 # We don't have a staged chrpath-native for ensuring our binary is
diff --git a/yocto-poky/meta/recipes-devtools/cmake/cmake-native_3.3.1.bb b/yocto-poky/meta/recipes-devtools/cmake/cmake-native_3.4.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/cmake/cmake-native_3.3.1.bb
rename to yocto-poky/meta/recipes-devtools/cmake/cmake-native_3.4.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/cmake/cmake.inc b/yocto-poky/meta/recipes-devtools/cmake/cmake.inc
index 57e93ac..968d003 100644
--- a/yocto-poky/meta/recipes-devtools/cmake/cmake.inc
+++ b/yocto-poky/meta/recipes-devtools/cmake/cmake.inc
@@ -11,13 +11,16 @@
 
 CMAKE_MAJOR_VERSION = "${@'.'.join(d.getVar('PV',1).split('.')[0:2])}"
 
-SRC_URI = "http://www.cmake.org/files/v${CMAKE_MAJOR_VERSION}/cmake-${PV}.tar.gz \
+SRC_URI = "https://cmake.org/files/v${CMAKE_MAJOR_VERSION}/cmake-${PV}.tar.gz \
            file://support-oe-qt4-tools-names.patch \
            file://qt4-fail-silent.patch \
+           file://0001-Add-NIOS2-CPU-support.patch \
            "
 
-SRC_URI[md5sum] = "52638576f4e1e621fed6c3410d3a1b12"
-SRC_URI[sha256sum] = "cd65022c6a0707f1c7112f99e9c981677fdd5518f7ddfa0f778d4cee7113e3d6"
+SRC_URI[md5sum] = "4cb3ff35b2472aae70f542116d616e63"
+SRC_URI[sha256sum] = "b73f8c1029611df7ed81796bf5ca8ba0ef41c6761132340c73ffe42704f980fa"
+
+UPSTREAM_CHECK_REGEX = "cmake-(?P<pver>\d+(\.\d+)+)\.tar"
 
 inherit autotools
 
diff --git a/yocto-poky/meta/recipes-devtools/cmake/cmake/0001-Add-NIOS2-CPU-support.patch b/yocto-poky/meta/recipes-devtools/cmake/cmake/0001-Add-NIOS2-CPU-support.patch
new file mode 100644
index 0000000..6e0ab9f
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/cmake/cmake/0001-Add-NIOS2-CPU-support.patch
@@ -0,0 +1,50 @@
+From 3f8c3d3011ea192da2c761560b615f55763715ef Mon Sep 17 00:00:00 2001
+From: Marek Vasut <marex@denx.de>
+Date: Thu, 26 Nov 2015 21:31:04 +0100
+Subject: [PATCH] Add NIOS2 CPU support
+
+Add necessary bits to support the NIOS2 little-endian CPU.
+
+Signed-off-by: Marek Vasut <marex@denx.de>
+Cc: Ley Foon Tan <lftan@altera.com>
+Cc: Thomas Chou <thomas@wytron.com.tw>
+Cc: Walter Goossens <waltergoossens@home.nl>
+Upstream-Status: Submitted
+---
+ Source/kwsys/CPU.h.in    | 4 ++++
+ Utilities/KWIML/ABI.h.in | 4 ++++
+ 2 files changed, 8 insertions(+)
+
+diff --git a/Source/kwsys/CPU.h.in b/Source/kwsys/CPU.h.in
+index 884d71a..66ffbb1 100644
+--- a/Source/kwsys/CPU.h.in
++++ b/Source/kwsys/CPU.h.in
+@@ -88,6 +88,10 @@
+ #elif defined(__mips) || defined(__mips__) || defined(__MIPS__)
+ # define @KWSYS_NAMESPACE@_CPU_ENDIAN_ID @KWSYS_NAMESPACE@_CPU_ENDIAN_ID_BIG
+ 
++/* NIOS2 */
++#elif defined(__NIOS2__) || defined(__NIOS2) || defined(__nios2__)
++# define @KWSYS_NAMESPACE@_CPU_ENDIAN_ID @KWSYS_NAMESPACE@_CPU_ENDIAN_ID_LITTLE
++
+ /* OpenRISC 1000 */
+ #elif defined(__or1k__)
+ # define @KWSYS_NAMESPACE@_CPU_ENDIAN_ID @KWSYS_NAMESPACE@_CPU_ENDIAN_ID_BIG
+diff --git a/Utilities/KWIML/ABI.h.in b/Utilities/KWIML/ABI.h.in
+index 6300ada..87b6e96 100644
+--- a/Utilities/KWIML/ABI.h.in
++++ b/Utilities/KWIML/ABI.h.in
+@@ -398,6 +398,10 @@ suppression macro @KWIML@_ABI_NO_VERIFY was defined.
+ #elif defined(__mips) || defined(__mips__) || defined(__MIPS__)
+ # define @KWIML@_ABI_ENDIAN_ID @KWIML@_ABI_ENDIAN_ID_BIG
+ 
++/* NIOS2 */
++#elif defined(__NIOS2__) || defined(__NIOS2) || defined(__nios2__)
++# define @KWIML@_ABI_ENDIAN_ID @KWIML@_ABI_ENDIAN_ID_LITTLE
++
+ /* OpenRISC 1000 */
+ #elif defined(__or1k__)
+ # define @KWIML@_ABI_ENDIAN_ID @KWIML@_ABI_ENDIAN_ID_BIG
+-- 
+2.6.2
+
diff --git a/yocto-poky/meta/recipes-devtools/cmake/cmake/dont-run-cross-binaries.patch b/yocto-poky/meta/recipes-devtools/cmake/cmake/dont-run-cross-binaries.patch
deleted file mode 100644
index 0c059f1..0000000
--- a/yocto-poky/meta/recipes-devtools/cmake/cmake/dont-run-cross-binaries.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-cmake: don't run cross-binaries on host machine
-
-When doing the cross build we obviously cannot run those binaries on
-host since they can be binary incompatible.
-
-Upstream-Status: Inappropriate [embedded specific]
-
-Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
-
-Index: cmake-2.8.10.1/CMakeLists.txt
-===================================================================
---- cmake-2.8.10.1.orig/CMakeLists.txt
-+++ cmake-2.8.10.1/CMakeLists.txt
-@@ -588,7 +588,8 @@ mark_as_advanced(CMAKE_STRICT)
- 
- # build the remaining subdirectories
- add_subdirectory(Source)
--add_subdirectory(Utilities)
-+# Come on! Running the cross-binaries on host is not a good idea.
-+#add_subdirectory(Utilities)
- add_subdirectory(Tests)
- 
- if(BUILD_TESTING)
diff --git a/yocto-poky/meta/recipes-devtools/cmake/cmake_3.3.1.bb b/yocto-poky/meta/recipes-devtools/cmake/cmake_3.4.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/cmake/cmake_3.3.1.bb
rename to yocto-poky/meta/recipes-devtools/cmake/cmake_3.4.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils-native_0.22.bb b/yocto-poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils-native_0.22.bb
index 6f73564..f899cd2 100644
--- a/yocto-poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils-native_0.22.bb
+++ b/yocto-poky/meta/recipes-devtools/desktop-file-utils/desktop-file-utils-native_0.22.bb
@@ -14,3 +14,5 @@
 inherit autotools native
 
 S = "${WORKDIR}/desktop-file-utils-${PV}"
+
+EXTRA_OECONF += "ac_cv_prog_EMACS=no"
diff --git a/yocto-poky/meta/recipes-devtools/diffstat/diffstat_1.60.bb b/yocto-poky/meta/recipes-devtools/diffstat/diffstat_1.61.bb
similarity index 84%
rename from yocto-poky/meta/recipes-devtools/diffstat/diffstat_1.60.bb
rename to yocto-poky/meta/recipes-devtools/diffstat/diffstat_1.61.bb
index 25ba4da..0ec41c3 100644
--- a/yocto-poky/meta/recipes-devtools/diffstat/diffstat_1.60.bb
+++ b/yocto-poky/meta/recipes-devtools/diffstat/diffstat_1.61.bb
@@ -11,8 +11,8 @@
            file://run-ptest \
 "
 
-SRC_URI[md5sum] = "ba889da4c06b547aa2d78fa96800ae6f"
-SRC_URI[sha256sum] = "2032e418b43bae70d548e32da901ebc4ac12972381de1314bebde0b126fb0123"
+SRC_URI[md5sum] = "c048a32d55d8bd6724f382baf41f325f"
+SRC_URI[sha256sum] = "25359e0c27183f997b36c9202583b5dc2df390c20e22a92606af4bf7856a55ee"
 
 S = "${WORKDIR}/diffstat-${PV}"
 
diff --git a/yocto-poky/meta/recipes-devtools/dmidecode/dmidecode_2.12.bb b/yocto-poky/meta/recipes-devtools/dmidecode/dmidecode_2.12.bb
deleted file mode 100644
index 4c16556..0000000
--- a/yocto-poky/meta/recipes-devtools/dmidecode/dmidecode_2.12.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-SUMMARY = "DMI (Desktop Management Interface) table related utilities"
-HOMEPAGE = "http://www.nongnu.org/dmidecode/"
-LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=393a5ca445f6965873eca0259a17f833"
-
-SRC_URI = "${SAVANNAH_NONGNU_MIRROR}/dmidecode/${BP}.tar.bz2"
-
-COMPATIBLE_HOST = "(i.86|x86_64|aarch64|arm|powerpc|powerpc64).*-linux"
-
-do_install() {
-	oe_runmake DESTDIR="${D}" install
-}
-
-do_unpack_extra() {
-	sed -i -e '/^prefix/s:/usr/local:${exec_prefix}:' ${S}/Makefile
-}
-addtask unpack_extra after do_unpack before do_patch
-
-SRC_URI[md5sum] = "a406f3cbb27736491698697beeddb781"
-SRC_URI[sha256sum] = "913ff3055d563a62a420789b8ee33b038de9afa18ea61254760ddf8ab87a5088"
diff --git a/yocto-poky/meta/recipes-devtools/dmidecode/dmidecode_3.0.bb b/yocto-poky/meta/recipes-devtools/dmidecode/dmidecode_3.0.bb
new file mode 100644
index 0000000..109a9d2
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/dmidecode/dmidecode_3.0.bb
@@ -0,0 +1,23 @@
+SUMMARY = "DMI (Desktop Management Interface) table related utilities"
+HOMEPAGE = "http://www.nongnu.org/dmidecode/"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+SRC_URI = "${SAVANNAH_NONGNU_MIRROR}/dmidecode/${BP}.tar.xz"
+
+COMPATIBLE_HOST = "(i.86|x86_64|aarch64|arm|powerpc|powerpc64).*-linux"
+
+EXTRA_OEMAKE = "-e MAKEFLAGS="
+
+do_install() {
+	oe_runmake DESTDIR="${D}" install
+}
+
+do_unpack_extra() {
+	sed -i -e '/^prefix/s:/usr/local:${exec_prefix}:' ${S}/Makefile
+}
+addtask unpack_extra after do_unpack before do_patch
+
+SRC_URI[md5sum] = "281ee572d45c78eca73a14834c495ffd"
+SRC_URI[sha256sum] = "7ec35bb193729c1d593a1460b59d82d24b89102ab23fd0416e6cf4325d077e45"
+
diff --git a/yocto-poky/meta/recipes-devtools/docbook-dsssl-stylesheets/docbook-dsssl-stylesheets-native_1.79.bb b/yocto-poky/meta/recipes-devtools/docbook-dsssl-stylesheets/docbook-dsssl-stylesheets-native_1.79.bb
index 461b48f..b7791f3 100644
--- a/yocto-poky/meta/recipes-devtools/docbook-dsssl-stylesheets/docbook-dsssl-stylesheets-native_1.79.bb
+++ b/yocto-poky/meta/recipes-devtools/docbook-dsssl-stylesheets/docbook-dsssl-stylesheets-native_1.79.bb
@@ -13,6 +13,9 @@
 SRC_URI[md5sum] = "bc192d23266b9a664ca0aba4a7794c7c"
 SRC_URI[sha256sum] = "2f329e120bee9ef42fbdd74ddd60e05e49786c5a7953a0ff4c680ae6bdf0e2bc"
 
+UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/docbook/files/docbook-dsssl/"
+UPSTREAM_CHECK_REGEX = "/docbook-dsssl/(?P<pver>(\d+[\.\-_]*)+)/"
+
 S = "${WORKDIR}/docbook-dsssl-${PV}"
 
 inherit native
diff --git a/yocto-poky/meta/recipes-devtools/docbook-sgml-dtd/docbook-sgml-dtd-3.1-native_3.1.bb b/yocto-poky/meta/recipes-devtools/docbook-sgml-dtd/docbook-sgml-dtd-3.1-native_3.1.bb
index a7df4f9..a3ee5d8 100644
--- a/yocto-poky/meta/recipes-devtools/docbook-sgml-dtd/docbook-sgml-dtd-3.1-native_3.1.bb
+++ b/yocto-poky/meta/recipes-devtools/docbook-sgml-dtd/docbook-sgml-dtd-3.1-native_3.1.bb
@@ -16,6 +16,9 @@
 SRC_URI[md5sum] = "432749c0c806dbae81c8bcb70da3b5d3"
 SRC_URI[sha256sum] = "20261d2771b9a052abfa3d8fab1aa62be05791a010281c566f9073bf0e644538"
 
+UPSTREAM_CHECK_URI = "http://www.docbook.org/sgml/"
+UPSTREAM_CHECK_REGEX = "(?P<pver>3\..+)/"
+
 do_compile() {
 	# Refer to http://www.linuxfromscratch.org/blfs/view/stable/pst/sgml-dtd-3.html
 	# for details.
diff --git a/yocto-poky/meta/recipes-devtools/docbook-sgml-dtd/docbook-sgml-dtd-4.1-native_4.1.bb b/yocto-poky/meta/recipes-devtools/docbook-sgml-dtd/docbook-sgml-dtd-4.1-native_4.1.bb
index 88c9396..be59680 100644
--- a/yocto-poky/meta/recipes-devtools/docbook-sgml-dtd/docbook-sgml-dtd-4.1-native_4.1.bb
+++ b/yocto-poky/meta/recipes-devtools/docbook-sgml-dtd/docbook-sgml-dtd-4.1-native_4.1.bb
@@ -16,6 +16,9 @@
 SRC_URI[md5sum] = "489f6ff2a2173eb1e14216c10533ede2"
 SRC_URI[sha256sum] = "deaafcf0a3677692e7ad4412c0e41c1db3e9da6cdcdb3dd32b2cc1f9c97d6311"
 
+UPSTREAM_CHECK_URI = "http://www.docbook.org/sgml/"
+UPSTREAM_CHECK_REGEX = "(?P<pver>4\.1(\.\d+)*)/"
+
 do_compile() {
 	# Refer to http://www.linuxfromscratch.org/blfs/view/stable/pst/sgml-dtd.html
 	# for details.
diff --git a/yocto-poky/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.78.1.bb b/yocto-poky/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.78.1.bb
index 2a1bdc4..52de3ab 100644
--- a/yocto-poky/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.78.1.bb
+++ b/yocto-poky/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.78.1.bb
@@ -11,6 +11,10 @@
 SRC_URI[md5sum] = "6dd0f89131cc35bf4f2ed105a1c17771"
 SRC_URI[sha256sum] = "c98f7296ab5c8ccd2e0bc07634976a37f50847df2d8a59bdb1e157664700b467"
 
+UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/docbook/files/docbook-xsl/"
+# Reject versions ending in .0 as those are release candidates
+UPSTREAM_CHECK_REGEX = "/docbook-xsl/(?P<pver>(\d+[\.\-_]*)+(?!\.0)\.\d+)/"
+
 S = "${WORKDIR}/docbook-xsl-${PV}"
 
 inherit allarch
@@ -30,7 +34,8 @@
 do_install () {
 	# Refer to http://www.linuxfromscratch.org/blfs/view/stable/pst/docbook-xsl.html
 	# for details.
-	install -v -m755 -d ${D}${datadir}/xml/docbook/xsl-stylesheets-1.78.1
+	install -v -m755 -d ${D}${datadir}/xml/docbook/xsl-stylesheets-${PV}
+	ln -s xsl-stylesheets-${PV} ${D}${datadir}/xml/docbook/xsl-stylesheets
 
 	cp -v -R VERSION common eclipse epub extensions fo highlighting html \
 		htmlhelp images javahelp lib manpages params profiling \
diff --git a/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools/0001-mkfs.fat-fix-incorrect-int-type.patch b/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools/0001-mkfs.fat-fix-incorrect-int-type.patch
new file mode 100644
index 0000000..3497ca5
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools/0001-mkfs.fat-fix-incorrect-int-type.patch
@@ -0,0 +1,46 @@
+From 3b95786af13e28157d889bd90a384ee255f2d91d Mon Sep 17 00:00:00 2001
+From: "Yann E. MORIN" <yann.morin.1998@free.fr>
+Date: Sun, 16 Aug 2015 15:55:43 +0200
+Subject: [PATCH] mkfs.fat: fix incorrect int type
+
+u_int32_t is not a stanard type, while uint32_t is. This fixes builds
+with the musl C library, which only defines so-called "clean" headers;
+build failures are like (back-quotes and elision manually added for
+readability):
+
+    http://autobuild.buildroot.org/results/a09/a0923d7f6d4dbae02eba4c5024bbdae3a52aa85a/build-end.log
+
+    /home/peko/autobuild/instance-1/output/host/usr/bin/x86_64-linux-gcc -D_LARGEFILE_SOURCE \
+        -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64   -Os  -D_GNU_SOURCE -D_LARGEFILE_SOURCE \
+        -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64  -c -o mkfs.fat.o src/mkfs.fat.c
+    src/mkfs.fat.c: In function 'main':
+    src/mkfs.fat.c:1415:18: error: 'u_int32_t' undeclared (first use in this function)
+         volume_id = (u_int32_t) ((create_timeval.tv_sec << 20) | create_timeval.tv_usec); [...]
+                      ^
+    src/mkfs.fat.c:1415:18: note: each undeclared identifier is reported only once for each
+    function it appears in
+
+Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
+Signed-off-by: Andreas Bombe <aeb@debian.org>
+---
+Upstream-Status: Backport
+
+ src/mkfs.fat.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/mkfs.fat.c b/src/mkfs.fat.c
+index b38d116..dddbe24 100644
+--- a/src/mkfs.fat.c
++++ b/src/mkfs.fat.c
+@@ -1412,7 +1412,7 @@ int main(int argc, char **argv)
+ 
+     gettimeofday(&create_timeval, NULL);
+     create_time = create_timeval.tv_sec;
+-    volume_id = (u_int32_t) ((create_timeval.tv_sec << 20) | create_timeval.tv_usec);	/* Default volume ID = creation time, fudged for more uniqueness */
++    volume_id = (uint32_t) ((create_timeval.tv_sec << 20) | create_timeval.tv_usec);	/* Default volume ID = creation time, fudged for more uniqueness */
+     check_atari();
+ 
+     printf("mkfs.fat " VERSION " (" VERSION_DATE ")\n");
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools/largefile.patch b/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools/largefile.patch
new file mode 100644
index 0000000..7f7d835
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools/largefile.patch
@@ -0,0 +1,19 @@
+defer setting largefile flags to build makery
+in a cross build we can not do runtime config tests
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Inappropriate[Cross compile Specific]
+Index: dosfstools-3.0.28/Makefile
+===================================================================
+--- dosfstools-3.0.28.orig/Makefile
++++ dosfstools-3.0.28/Makefile
+@@ -27,8 +27,7 @@ SBINDIR = $(PREFIX)/sbin
+ DOCDIR = $(PREFIX)/share/doc
+ MANDIR = $(PREFIX)/share/man
+ 
+-#OPTFLAGS = -O2 -fomit-frame-pointer -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
+-OPTFLAGS = -O2 -fomit-frame-pointer -D_GNU_SOURCE $(shell getconf LFS_CFLAGS)
++OPTFLAGS = -O2 -fomit-frame-pointer
+ #WARNFLAGS = -Wall -pedantic -std=c99
+ WARNFLAGS = -Wall -Wextra -Wno-sign-compare -Wno-missing-field-initializers -Wmissing-prototypes -Wstrict-prototypes -Wwrite-strings
+ DEBUGFLAGS = -g
diff --git a/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools_2.11.bb b/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools_2.11.bb
index beec488..176504d 100644
--- a/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools_2.11.bb
+++ b/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools_2.11.bb
@@ -2,7 +2,7 @@
 # Copyright (C) 2004-2006, Advanced Micro Devices, Inc.  All Rights Reserved
 # Released under the MIT license (see packages/COPYING)
 SUMMARY = "DOS FAT Filesystem Utilities"
-HOMEPAGE = "http://daniel-baumann.ch/software/dosfstools/"
+HOMEPAGE = "https://github.com/dosfstools/dosfstools"
 
 SECTION = "base"
 LICENSE = "GPLv2"
@@ -18,21 +18,17 @@
            file://include-linux-types.patch \
            file://nofat32_autoselect.patch \
            file://fix_populated_dosfs_creation.patch \
-	   file://0001-Include-fcntl.h-for-getting-loff_t-definition.patch \
-	   "
+           file://0001-Include-fcntl.h-for-getting-loff_t-definition.patch \
+"
 
 SRC_URI[md5sum] = "407d405ade410f7597d364ab5dc8c9f6"
 SRC_URI[sha256sum] = "0eac6d12388b3d9ed78684529c1b0d9346fa2abbe406c4d4a3eb5a023c98a484"
 
-# Makefile sets this, but we clobber its CFLAGS, so
-# add this in here to for sure allow for big files.
-#
-CFLAGS_append = " -D_FILE_OFFSET_BITS=64"
-CFLAGS_append_libc-musl = " -D_GNU_SOURCE"
+CFLAGS += "-D_GNU_SOURCE ${@bb.utils.contains('DISTRO_FEATURES', 'largefile', '-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64', '', d)}"
+
+EXTRA_OEMAKE = "CC='${CC}' CFLAGS='${CFLAGS}' LDFLAGS='${LDFLAGS}'"
 
 do_install () {
 	oe_runmake "PREFIX=${D}" "SBINDIR=${D}${base_sbindir}" \
 		   "MANDIR=${D}${mandir}/man8" install
 }
-
-BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools_3.0.28.bb b/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools_3.0.28.bb
index ac131cb..6fc3e41 100644
--- a/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools_3.0.28.bb
+++ b/yocto-poky/meta/recipes-devtools/dosfstools/dosfstools_3.0.28.bb
@@ -9,10 +9,17 @@
 LICENSE = "GPLv3"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
 
-SRC_URI = "https://github.com/dosfstools/dosfstools/releases/download/v3.0.28/dosfstools-3.0.28.tar.xz"
+SRC_URI = "https://github.com/dosfstools/dosfstools/releases/download/v3.0.28/dosfstools-3.0.28.tar.xz \
+           file://largefile.patch \
+           file://0001-mkfs.fat-fix-incorrect-int-type.patch \
+          "
 SRC_URI[md5sum] = "6a047a6c65186b9ebb1853709adb36db"
 SRC_URI[sha256sum] = "ee95913044ecf2719b63ea11212917649709a6e53209a72d622135aaa8517ee2"
 
+UPSTREAM_CHECK_URI = "https://github.com/dosfstools/dosfstools/releases"
+
+CFLAGS += "-D_GNU_SOURCE ${@bb.utils.contains('DISTRO_FEATURES', 'largefile', '-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64', '', d)}"
+
 FILES_${PN} = "${base_sbindir}"
 FILES_${PN}-doc = "${mandir} ${docdir}"
 
diff --git a/yocto-poky/meta/recipes-devtools/dpkg/dpkg.inc b/yocto-poky/meta/recipes-devtools/dpkg/dpkg.inc
index 6eec2cd..3d9e7e3 100644
--- a/yocto-poky/meta/recipes-devtools/dpkg/dpkg.inc
+++ b/yocto-poky/meta/recipes-devtools/dpkg/dpkg.inc
@@ -34,7 +34,7 @@
 		--without-selinux \
 		"
 
-EXTRA_OECONF_append_class-target = " TAR=tar"
+EXTRA_OECONF += "TAR=tar"
 
 do_configure () {
     echo >> ${S}/m4/compiler.m4
diff --git a/yocto-poky/meta/recipes-devtools/dpkg/dpkg/0001-When-running-do_package_write_deb-we-have-trees-of-h.patch b/yocto-poky/meta/recipes-devtools/dpkg/dpkg/0001-When-running-do_package_write_deb-we-have-trees-of-h.patch
index 6967ef4..49ef853 100644
--- a/yocto-poky/meta/recipes-devtools/dpkg/dpkg/0001-When-running-do_package_write_deb-we-have-trees-of-h.patch
+++ b/yocto-poky/meta/recipes-devtools/dpkg/dpkg/0001-When-running-do_package_write_deb-we-have-trees-of-h.patch
@@ -1,7 +1,7 @@
-From d14ffd786993da60ca84c4812da8a6594a8c764e Mon Sep 17 00:00:00 2001
+From e391bdba238d1371fc5b67cdae08b06eb5ada5c2 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Wed, 26 Aug 2015 15:48:13 +0300
-Subject: [PATCH 1/5] When running do_package_write_deb, we have trees of
+Subject: [PATCH] When running do_package_write_deb, we have trees of
  hardlinked files such as the dbg source files in ${PN}-dbg. If something
  makes another copy of one of those files (or deletes one), the number of
  links a file has changes and tar can notice this, e.g.:
@@ -19,23 +19,43 @@
 Upstream-Status: Inappropriate
 RP 2015/3/27
 ---
- dpkg-deb/build.c | 11 ++++++++---
- 1 file changed, 8 insertions(+), 3 deletions(-)
+ dpkg-deb/build.c | 12 ++++++++----
+ 1 file changed, 8 insertions(+), 4 deletions(-)
 
 diff --git a/dpkg-deb/build.c b/dpkg-deb/build.c
-index ea3d861..1589927 100644
+index 2ddeec6..af363f0 100644
 --- a/dpkg-deb/build.c
 +++ b/dpkg-deb/build.c
-@@ -458,7 +458,7 @@ do_build(const char *const *argv)
+@@ -452,7 +452,7 @@ static void
+ tarball_pack(const char *dir, filenames_feed_func *tar_filenames_feeder,
+              struct compress_params *tar_compress_params, int fd_out)
+ {
+-  int pipe_filenames[2], pipe_tarball[2];
++  int pipe_filenames[2], pipe_tarball[2], rc;
+   pid_t pid_tar, pid_comp;
+ 
+   /* Fork off a tar. We will feed it a list of filenames on stdin later. */
+@@ -493,7 +493,9 @@ tarball_pack(const char *dir, filenames_feed_func *tar_filenames_feeder,
+   /* All done, clean up wait for tar and <compress> to finish their job. */
+   close(pipe_filenames[1]);
+   subproc_reap(pid_comp, _("<compress> from tar -cf"), 0);
+-  subproc_reap(pid_tar, "tar -cf", 0);
++  rc = subproc_reap(pid_tar, "tar -cf", SUBPROC_RETERROR);
++  if (rc && rc != 1)
++    ohshite(_("subprocess %s returned error exit status %d"), "tar -cf", rc);
+ }
+ 
+ /**
+@@ -509,7 +511,7 @@ do_build(const char *const *argv)
    char *debar;
    char *tfbuf;
    int arfd;
--  int p1[2], p2[2], gzfd;
-+  int p1[2], p2[2], gzfd, rc;
+-  int p1[2], gzfd;
++  int p1[2], gzfd, rc;
    pid_t c1, c2;
  
    /* Decode our arguments. */
-@@ -538,7 +538,9 @@ do_build(const char *const *argv)
+@@ -590,7 +592,9 @@ do_build(const char *const *argv)
    }
    close(p1[0]);
    subproc_reap(c2, _("<compress> from tar -cf"), 0);
@@ -46,18 +66,6 @@
  
    if (lseek(gzfd, 0, SEEK_SET))
      ohshite(_("failed to rewind temporary file (%s)"), _("control member"));
-@@ -626,7 +628,10 @@ do_build(const char *const *argv)
-   /* All done, clean up wait for tar and <compress> to finish their job. */
-   close(p1[1]);
-   subproc_reap(c2, _("<compress> from tar -cf"), 0);
--  subproc_reap(c1, "tar -cf", 0);
-+  rc = subproc_reap(c1, "tar -cf", SUBPROC_RETERROR);
-+  if (rc && rc != 1)
-+    ohshite(_("subprocess %s returned error exit status %d"), "tar -cf", rc);
-+
-   /* Okay, we have data.tar as well now, add it to the ar wrapper. */
-   if (deb_format.major == 2) {
-     char datamember[16 + 1];
 -- 
-2.1.4
+2.7.0
 
diff --git a/yocto-poky/meta/recipes-devtools/dpkg/dpkg/0006-add-musleabi-to-known-target-tripets.patch b/yocto-poky/meta/recipes-devtools/dpkg/dpkg/0006-add-musleabi-to-known-target-tripets.patch
new file mode 100644
index 0000000..a6b0088
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/dpkg/dpkg/0006-add-musleabi-to-known-target-tripets.patch
@@ -0,0 +1,42 @@
+From f8910022dc3ec622272f168cd0022dbdf6dff93a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 30 Dec 2015 23:05:41 +0000
+Subject: [PATCH] add musleabi to known target tripets
+
+helps compiling dpkg for musl/arm-softfloat
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ ostable      | 1 +
+ triplettable | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/ostable b/ostable
+index 3bb6819..d0ffdc7 100644
+--- a/ostable
++++ b/ostable
+@@ -15,6 +15,7 @@
+ uclibceabi-linux	linux-uclibceabi	linux[^-]*-uclibceabi
+ uclibc-linux		linux-uclibc		linux[^-]*-uclibc
+ musleabihf-linux	linux-musleabihf	linux[^-]*-musleabihf
++musleabi-linux		linux-musleabi		linux[^-]*-musleabi
+ musl-linux		linux-musl		linux[^-]*-musl
+ gnueabihf-linux		linux-gnueabihf		linux[^-]*-gnueabihf
+ gnueabi-linux		linux-gnueabi		linux[^-]*-gnueabi
+diff --git a/triplettable b/triplettable
+index 1213584..70d24c1 100644
+--- a/triplettable
++++ b/triplettable
+@@ -6,6 +6,7 @@
+ uclibceabi-linux-arm	uclibc-linux-armel
+ uclibc-linux-<cpu>	uclibc-linux-<cpu>
+ musleabihf-linux-arm	musl-linux-armhf
++musleabi-linux-arm	musl-linux-armel
+ musl-linux-<cpu>	musl-linux-<cpu>
+ gnueabihf-linux-arm	armhf
+ gnueabi-linux-arm	armel
+-- 
+2.6.4
+
diff --git a/yocto-poky/meta/recipes-devtools/dpkg/dpkg/CVE-2015-0860.patch b/yocto-poky/meta/recipes-devtools/dpkg/dpkg/CVE-2015-0860.patch
deleted file mode 100644
index 1f259d3..0000000
--- a/yocto-poky/meta/recipes-devtools/dpkg/dpkg/CVE-2015-0860.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From f1aac7d933819569bf6f347c3c0d5a64a90bbce0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Hanno=20B=C3=B6ck?= <hanno@hboeck.de>
-Date: Thu, 19 Nov 2015 20:03:10 +0100
-Subject: [PATCH] dpkg-deb: Fix off-by-one write access on ctrllenbuf variable
-
-This affects old format .deb packages.
-
-Fixes: CVE-2015-0860
-Warned-by: afl
-Signed-off-by: Guillem Jover <guillem@debian.org>
-
-Upstream-Status: Backport
-
-https://anonscm.debian.org/cgit/dpkg/dpkg.git/commit/?h=wheezy&id=f1aac7d933819569bf6f347c3c0d5a64a90bbce0
-
-CVE: CVE-2015-0860
-
-hand merge Changelog
-
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- debian/changelog   | 3 +++
- dpkg-deb/extract.c | 2 +-
- 2 files changed, 4 insertions(+), 1 deletion(-)
-
-Index: dpkg-1.18.2/dpkg-deb/extract.c
-===================================================================
---- dpkg-1.18.2.orig/dpkg-deb/extract.c
-+++ dpkg-1.18.2/dpkg-deb/extract.c
-@@ -247,7 +247,7 @@ extracthalf(const char *debar, const cha
-     if (errstr)
-       ohshit(_("archive has invalid format version: %s"), errstr);
- 
--    r = read_line(arfd, ctrllenbuf, 1, sizeof(ctrllenbuf));
-+    r = read_line(arfd, ctrllenbuf, 1, sizeof(ctrllenbuf) - 1);
-     if (r < 0)
-       read_fail(r, debar, _("archive control member size"));
-     if (sscanf(ctrllenbuf, "%jd%c%d", &ctrllennum, &nlc, &dummy) != 2 ||
-Index: dpkg-1.18.2/ChangeLog
-===================================================================
---- dpkg-1.18.2.orig/ChangeLog
-+++ dpkg-1.18.2/ChangeLog
-@@ -1,3 +1,8 @@
-+[ Guillem Jover ]
-+  * Fix an off-by-one write access in dpkg-deb when parsing the old format
-+    .deb control member size. Thanks to Hanno Böck <hanno@hboeck.de>.
-+    Fixes CVE-2015-0860.
-+
- commit 5459d330c73cdcfd1327bc93c0ebddc2da4a3a3a (HEAD -> master, tag: 1.18.2)
- Author: Guillem Jover <guillem@debian.org>
- Date:   Mon Aug 3 15:41:05 2015 +0200
diff --git a/yocto-poky/meta/recipes-devtools/dpkg/dpkg_1.18.2.bb b/yocto-poky/meta/recipes-devtools/dpkg/dpkg_1.18.4.bb
similarity index 70%
rename from yocto-poky/meta/recipes-devtools/dpkg/dpkg_1.18.2.bb
rename to yocto-poky/meta/recipes-devtools/dpkg/dpkg_1.18.4.bb
index 2fc096d..7876944 100644
--- a/yocto-poky/meta/recipes-devtools/dpkg/dpkg_1.18.2.bb
+++ b/yocto-poky/meta/recipes-devtools/dpkg/dpkg_1.18.4.bb
@@ -1,20 +1,20 @@
 require dpkg.inc
 LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
 
+SRC_URI_append_class-native =" file://glibc2.5-sync_file_range.patch "
 SRC_URI += "file://noman.patch \
             file://remove-tar-no-timestamp.patch \
             file://fix-abs-redefine.patch \
             file://arch_pm.patch \
             file://dpkg-configure.service \
-            file://glibc2.5-sync_file_range.patch \
             file://add_armeb_triplet_entry.patch \
 	    file://0002-Adapt-to-linux-wrs-kernel-version-which-has-characte.patch \
 	    file://0003-Our-pre-postinsts-expect-D-to-be-set-when-running-in.patch \
 	    file://0004-The-lutimes-function-doesn-t-work-properly-for-all-s.patch \
 	    file://0005-dpkg-compiler.m4-remove-Wvla.patch \
-        file://CVE-2015-0860.patch \
+	    file://0006-add-musleabi-to-known-target-tripets.patch \
            "
 
-SRC_URI[md5sum] = "63b9d869081ec49adeef6c5ff62d6576"
-SRC_URI[sha256sum] = "11484f2a73d027d696e720a60380db71978bb5c06cd88fe30c291e069ac457a4"
+SRC_URI[md5sum] = "e95b513c89693f6ec3ab53b6b1c3defd"
+SRC_URI[sha256sum] = "fe89243868888ce715bf45861f26264f767d4e4dbd0d6f1a26ce60bbbbf106da"
 
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc
index bcd9ba7..09e4ea5 100644
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc
+++ b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs.inc
@@ -19,7 +19,9 @@
 SECTION = "base"
 DEPENDS = "util-linux"
 
-SRC_URI = "${SOURCEFORGE_MIRROR}/e2fsprogs/e2fsprogs-${PV}.tar.gz \
-           file://mkdir.patch"
+SRC_URI = "git://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git"
+S = "${WORKDIR}/git"
 
-inherit autotools gettext texinfo pkgconfig multilib_header
+inherit autotools gettext texinfo pkgconfig multilib_header update-alternatives ptest
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-e2fsprogs-fix-cross-compilation-problem.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-e2fsprogs-fix-cross-compilation-problem.patch
deleted file mode 100644
index 73043be..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-e2fsprogs-fix-cross-compilation-problem.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-Upstream-Status: Pending
-
-Subject: e2fsprogs: fix cross compilation problem
-
-The checking of types in parse-types.sh doesn't make much sense in a
-cross-compilation environment, because the generated binary is executed
-on build machine.
-
-So even if asm_types.h has got correct statements for types, it's possible
-that the generated binary will report an error. Because these types are for
-the target machine.
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- config/parse-types.sh |    6 ++++--
- configure.in          |    6 +++++-
- 2 files changed, 9 insertions(+), 3 deletions(-)
-
-diff --git a/config/parse-types.sh b/config/parse-types.sh
-index 5076f6c..24d2a99 100755
---- a/config/parse-types.sh
-+++ b/config/parse-types.sh
-@@ -118,8 +118,10 @@ if ./asm_types
- then
-     true
- else
--    echo "Problem detected with asm_types.h"
--    echo "" > asm_types.h
-+    if [ "${CROSS_COMPILE}" != "1" ]; then
-+	echo "Problem detected with asm_types.h"
-+	echo "" > asm_types.h
-+    fi
- fi
- rm asm_types.c asm_types
- 
-diff --git a/configure.in b/configure.in
-index 68adf0d..ed1697b 100644
---- a/configure.in
-+++ b/configure.in
-@@ -953,7 +953,11 @@ AC_SUBST(SIZEOF_LONG)
- AC_SUBST(SIZEOF_LONG_LONG)
- AC_SUBST(SIZEOF_OFF_T)
- AC_C_BIGENDIAN
--BUILD_CC="$BUILD_CC" CPP="$CPP" /bin/sh $ac_aux_dir/parse-types.sh
-+if test $cross_compiling = no; then
-+  BUILD_CC="$BUILD_CC" CPP="$CPP" /bin/sh $ac_aux_dir/parse-types.sh
-+else
-+  CROSS_COMPILE="1" BUILD_CC="$BUILD_CC" CPP="$CPP" /bin/sh $ac_aux_dir/parse-types.sh
-+fi
- ASM_TYPES_HEADER=./asm_types.h
- AC_SUBST_FILE(ASM_TYPES_HEADER)
- dnl
--- 
-1.7.9.5
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-libext2fs-fix-potential-buffer-overflow-in-closefs.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-libext2fs-fix-potential-buffer-overflow-in-closefs.patch
deleted file mode 100644
index 72f77cc..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-libext2fs-fix-potential-buffer-overflow-in-closefs.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 49d0fe2a14f2a23da2fe299643379b8c1d37df73 Mon Sep 17 00:00:00 2001
-From: Theodore Ts'o <tytso@mit.edu>
-Date: Fri, 6 Feb 2015 12:46:39 -0500
-Subject: [PATCH] libext2fs: fix potential buffer overflow in closefs()
-
-Upstream-Status: Backport
-
-The bug fix in f66e6ce4446: "libext2fs: avoid buffer overflow if
-s_first_meta_bg is too big" had a typo in the fix for
-ext2fs_closefs().  In practice most of the security exposure was from
-the openfs path, since this meant if there was a carefully crafted
-file system, buffer overrun would be triggered when the file system was
-opened.
-
-However, if corrupted file system didn't trip over some corruption
-check, and then the file system was modified via tune2fs or debugfs,
-such that the superblock was marked dirty and then written out via the
-closefs() path, it's possible that the buffer overrun could be
-triggered when the file system is closed.
-
-Also clear up a signed vs unsigned warning while we're at it.
-
-Thanks to Nick Kralevich <nnk@google.com> for asking me to look at
-compiler warning in the code in question, which led me to notice the
-bug in f66e6ce4446.
-
-Addresses: CVE-2015-1572
-
-Signed-off-by: Theodore Ts'o <tytso@mit.edu>
----
- lib/ext2fs/closefs.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/lib/ext2fs/closefs.c b/lib/ext2fs/closefs.c
-index 1f99113..ab5b2fb 100644
---- a/lib/ext2fs/closefs.c
-+++ b/lib/ext2fs/closefs.c
-@@ -287,7 +287,7 @@ errcode_t ext2fs_flush2(ext2_filsys fs, int flags)
- 	dgrp_t		j;
- #endif
- 	char	*group_ptr;
--	int	old_desc_blocks;
-+	blk64_t	old_desc_blocks;
- 	struct ext2fs_numeric_progress_struct progress;
- 
- 	EXT2_CHECK_MAGIC(fs, EXT2_ET_MAGIC_EXT2FS_FILSYS);
-@@ -346,7 +346,7 @@ errcode_t ext2fs_flush2(ext2_filsys fs, int flags)
- 	group_ptr = (char *) group_shadow;
- 	if (fs->super->s_feature_incompat & EXT2_FEATURE_INCOMPAT_META_BG) {
- 		old_desc_blocks = fs->super->s_first_meta_bg;
--		if (old_desc_blocks > fs->super->s_first_meta_bg)
-+		if (old_desc_blocks > fs->desc_blocks)
- 			old_desc_blocks = fs->desc_blocks;
- 	} else
- 		old_desc_blocks = fs->desc_blocks;
--- 
-2.1.0
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-mke2fs-add-the-ability-to-copy-files-from-a-given-di.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-mke2fs-add-the-ability-to-copy-files-from-a-given-di.patch
deleted file mode 100644
index 9ea413e..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0001-mke2fs-add-the-ability-to-copy-files-from-a-given-di.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-From c98fec004f077e566b9dfa20b25e3b86cb462a2e Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Tue, 24 Dec 2013 01:41:08 -0500
-Subject: [PATCH 01/11] mke2fs: add the ability to copy files from a given
- directory
-
-We will add a -d option which will be used for adding the files from a
-given directory to the filesystem, it is similiar to genext2fs, but
-genext2fs doesn't fully support ext4.
-
-* We already have the basic operations in debugfs:
-  - Copy regular file
-  - Create directory
-  - Create symlink
-  - Create special file
-
-  We will move these operations into create_inode.h and create_inode.c,
-  then let both mke2fs and debugfs use them.
-
-* What we need to do are:
-  - Copy the given directory recursively, this will be done by the
-    populate_fs()
-  - Set the owner, mode and other informations
-  - Handle the hard links
-
-TODO:
-  - The libext2fs can't create the socket file (S_IFSOCK), do we have a
-    plan to support it ?
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/create_inode.c |   26 ++++++++++++++++++++++++++
- misc/create_inode.h |   17 +++++++++++++++++
- 2 files changed, 43 insertions(+)
- create mode 100644 misc/create_inode.c
- create mode 100644 misc/create_inode.h
-
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-new file mode 100644
-index 0000000..46aaa60
---- /dev/null
-+++ b/misc/create_inode.c
-@@ -0,0 +1,26 @@
-+#include "create_inode.h"
-+
-+/* Make a special file which is block, character and fifo */
-+errcode_t do_mknod_internal(ext2_ino_t cwd, const char *name, struct stat *st)
-+{
-+}
-+
-+/* Make a symlink name -> target */
-+errcode_t do_symlink_internal(ext2_ino_t cwd, const char *name, char *target)
-+{
-+}
-+
-+/* Make a directory in the fs */
-+errcode_t do_mkdir_internal(ext2_ino_t cwd, const char *name, struct stat *st)
-+{
-+}
-+
-+/* Copy the native file to the fs */
-+errcode_t do_write_internal(ext2_ino_t cwd, const char *src, const char *dest)
-+{
-+}
-+
-+/* Copy files from source_dir to fs */
-+errcode_t populate_fs(ext2_ino_t parent_ino, const char *source_dir)
-+{
-+}
-diff --git a/misc/create_inode.h b/misc/create_inode.h
-new file mode 100644
-index 0000000..9fc97fa
---- /dev/null
-+++ b/misc/create_inode.h
-@@ -0,0 +1,17 @@
-+#include <sys/types.h>
-+#include <sys/stat.h>
-+#include <fcntl.h>
-+#include "et/com_err.h"
-+#include "e2p/e2p.h"
-+#include "ext2fs/ext2fs.h"
-+#include "nls-enable.h"
-+
-+ext2_filsys    current_fs;
-+ext2_ino_t     root;
-+
-+/* For populating the filesystem */
-+extern errcode_t populate_fs(ext2_ino_t parent_ino, const char *source_dir);
-+extern errcode_t do_mknod_internal(ext2_ino_t cwd, const char *name, struct stat *st);
-+extern errcode_t do_symlink_internal(ext2_ino_t cwd, const char *name, char *target);
-+extern errcode_t do_mkdir_internal(ext2_ino_t cwd, const char *name, struct stat *st);
-+extern errcode_t do_write_internal(ext2_ino_t cwd, const char *src, const char *dest);
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0002-misc-create_inode.c-copy-files-recursively.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0002-misc-create_inode.c-copy-files-recursively.patch
deleted file mode 100644
index 9bff644..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0002-misc-create_inode.c-copy-files-recursively.patch
+++ /dev/null
@@ -1,135 +0,0 @@
-From 08dfbaf4e3f704232ff46d78c0758a6cfe3961c8 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 23 Dec 2013 02:59:10 -0500
-Subject: [PATCH 02/11] misc/create_inode.c: copy files recursively
-
-Use opendir() and readdir() to read the native directory, then use
-lstat() to identify the file type and call the corresponding function to
-add the file to the filesystem, call the populate_fs() recursively if it
-is a directory.
-
-NOTE: the libext2fs can't create the socket file.
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/create_inode.c |   97 +++++++++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 97 insertions(+)
-
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-index 46aaa60..b68b910 100644
---- a/misc/create_inode.c
-+++ b/misc/create_inode.c
-@@ -1,5 +1,13 @@
- #include "create_inode.h"
- 
-+#if __STDC_VERSION__ < 199901L
-+# if __GNUC__ >= 2
-+#  define __func__ __FUNCTION__
-+# else
-+#  define __func__ "<unknown>"
-+# endif
-+#endif
-+
- /* Make a special file which is block, character and fifo */
- errcode_t do_mknod_internal(ext2_ino_t cwd, const char *name, struct stat *st)
- {
-@@ -23,4 +31,93 @@ errcode_t do_write_internal(ext2_ino_t cwd, const char *src, const char *dest)
- /* Copy files from source_dir to fs */
- errcode_t populate_fs(ext2_ino_t parent_ino, const char *source_dir)
- {
-+	const char	*name;
-+	DIR		*dh;
-+	struct dirent	*dent;
-+	struct stat	st;
-+	char		ln_target[PATH_MAX];
-+	ext2_ino_t	ino;
-+	errcode_t	retval;
-+	int		read_cnt;
-+
-+	root = EXT2_ROOT_INO;
-+
-+	if (chdir(source_dir) < 0) {
-+		com_err(__func__, errno,
-+			_("while changing working directory to \"%s\""), source_dir);
-+		return errno;
-+	}
-+
-+	if (!(dh = opendir("."))) {
-+		com_err(__func__, errno,
-+			_("while openning directory \"%s\""), source_dir);
-+		return errno;
-+	}
-+
-+	while((dent = readdir(dh))) {
-+		if((!strcmp(dent->d_name, ".")) || (!strcmp(dent->d_name, "..")))
-+			continue;
-+		lstat(dent->d_name, &st);
-+		name = dent->d_name;
-+
-+		switch(st.st_mode & S_IFMT) {
-+			case S_IFCHR:
-+			case S_IFBLK:
-+			case S_IFIFO:
-+				if ((retval = do_mknod_internal(parent_ino, name, &st))) {
-+					com_err(__func__, retval,
-+						_("while creating special file \"%s\""), name);
-+					return retval;
-+				}
-+				break;
-+			case S_IFSOCK:
-+				/* FIXME: there is no make socket function atm. */
-+				com_err(__func__, 0,
-+					_("ignoring socket file \"%s\""), name);
-+				continue;
-+			case S_IFLNK:
-+				if((read_cnt = readlink(name, ln_target, sizeof(ln_target))) == -1) {
-+					com_err(__func__, errno,
-+						_("while trying to readlink \"%s\""), name);
-+					return errno;
-+				}
-+				ln_target[read_cnt] = '\0';
-+				if ((retval = do_symlink_internal(parent_ino, name, ln_target))) {
-+					com_err(__func__, retval,
-+						_("while writing symlink\"%s\""), name);
-+					return retval;
-+				}
-+				break;
-+			case S_IFREG:
-+				if ((retval = do_write_internal(parent_ino, name, name))) {
-+					com_err(__func__, retval,
-+						_("while writing file \"%s\""), name);
-+					return retval;
-+				}
-+				break;
-+			case S_IFDIR:
-+				if ((retval = do_mkdir_internal(parent_ino, name, &st))) {
-+					com_err(__func__, retval,
-+						_("while making dir \"%s\""), name);
-+					return retval;
-+				}
-+				if ((retval = ext2fs_namei(current_fs, root, parent_ino, name, &ino))) {
-+					com_err(name, retval, 0);
-+						return retval;
-+				}
-+				/* Populate the dir recursively*/
-+				retval = populate_fs(ino, name);
-+				if (retval) {
-+					com_err(__func__, retval, _("while adding dir \"%s\""), name);
-+					return retval;
-+				}
-+				chdir("..");
-+				break;
-+			default:
-+				com_err(__func__, 0,
-+					_("ignoring entry \"%s\""), name);
-+		}
-+	}
-+	closedir(dh);
-+	return retval;
- }
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0003-misc-create_inode.c-create-special-file.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0003-misc-create_inode.c-create-special-file.patch
deleted file mode 100644
index 3847b6e..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0003-misc-create_inode.c-create-special-file.patch
+++ /dev/null
@@ -1,103 +0,0 @@
-From ae7d33823bfc330e08b25c5fe4d25838ef7c77ce Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 23 Dec 2013 03:13:28 -0500
-Subject: [PATCH 03/11] misc/create_inode.c: create special file
-
-The do_mknod_internal() is used for creating special file which is
-block, character and fifo, most of the code are from debugfs/debugfs.c,
-the debugfs/debugfs.c will be modified to use this function.
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/create_inode.c |   72 +++++++++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 72 insertions(+)
-
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-index b68b910..4da8aff 100644
---- a/misc/create_inode.c
-+++ b/misc/create_inode.c
-@@ -11,6 +11,78 @@
- /* Make a special file which is block, character and fifo */
- errcode_t do_mknod_internal(ext2_ino_t cwd, const char *name, struct stat *st)
- {
-+	ext2_ino_t		ino;
-+	errcode_t 		retval;
-+	struct ext2_inode	inode;
-+	unsigned long		major, minor, mode;
-+	int			filetype;
-+
-+	switch(st->st_mode & S_IFMT) {
-+		case S_IFCHR:
-+			mode = LINUX_S_IFCHR;
-+			filetype = EXT2_FT_CHRDEV;
-+			break;
-+		case S_IFBLK:
-+			mode = LINUX_S_IFBLK;
-+			filetype =  EXT2_FT_BLKDEV;
-+			break;
-+		case S_IFIFO:
-+			mode = LINUX_S_IFIFO;
-+			filetype = EXT2_FT_FIFO;
-+			break;
-+	}
-+
-+	if (!(current_fs->flags & EXT2_FLAG_RW)) {
-+		com_err(__func__, 0, "Filesystem opened read/only");
-+		return -1;
-+	}
-+	retval = ext2fs_new_inode(current_fs, cwd, 010755, 0, &ino);
-+	if (retval) {
-+		com_err(__func__, retval, 0);
-+		return retval;
-+	}
-+
-+#ifdef DEBUGFS
-+	printf("Allocated inode: %u\n", ino);
-+#endif
-+	retval = ext2fs_link(current_fs, cwd, name, ino, filetype);
-+	if (retval == EXT2_ET_DIR_NO_SPACE) {
-+		retval = ext2fs_expand_dir(current_fs, cwd);
-+		if (retval) {
-+			com_err(__func__, retval, "while expanding directory");
-+			return retval;
-+		}
-+		retval = ext2fs_link(current_fs, cwd, name, ino, filetype);
-+	}
-+	if (retval) {
-+		com_err(name, retval, 0);
-+		return -1;
-+	}
-+        if (ext2fs_test_inode_bitmap2(current_fs->inode_map, ino))
-+		com_err(__func__, 0, "Warning: inode already set");
-+	ext2fs_inode_alloc_stats2(current_fs, ino, +1, 0);
-+	memset(&inode, 0, sizeof(inode));
-+	inode.i_mode = mode;
-+	inode.i_atime = inode.i_ctime = inode.i_mtime =
-+		current_fs->now ? current_fs->now : time(0);
-+
-+	major = major(st->st_rdev);
-+	minor = minor(st->st_rdev);
-+
-+	if ((major < 256) && (minor < 256)) {
-+		inode.i_block[0] = major * 256 + minor;
-+		inode.i_block[1] = 0;
-+	} else {
-+		inode.i_block[0] = 0;
-+		inode.i_block[1] = (minor & 0xff) | (major << 8) | ((minor & ~0xff) << 12);
-+	}
-+	inode.i_links_count = 1;
-+
-+	retval = ext2fs_write_new_inode(current_fs, ino, &inode);
-+	if (retval)
-+		com_err(__func__, retval, "while creating inode %u", ino);
-+
-+	return retval;
- }
- 
- /* Make a symlink name -> target */
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0004-misc-create_inode.c-create-symlink.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0004-misc-create_inode.c-create-symlink.patch
deleted file mode 100644
index 83d198c..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0004-misc-create_inode.c-create-symlink.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-From 09d3049776882167f7249ee26265b4163d7222c1 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 23 Dec 2013 03:19:55 -0500
-Subject: [PATCH 04/11] misc/create_inode.c: create symlink
-
-The do_symlink_internal() is used for creating symlinks, most of the
-code are from debugfs/debugfs.c, the debugfs/debugfs.c will be modified
-to use this function.
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/create_inode.c |   32 ++++++++++++++++++++++++++++++++
- 1 file changed, 32 insertions(+)
-
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-index 4da8aff..f845103 100644
---- a/misc/create_inode.c
-+++ b/misc/create_inode.c
-@@ -88,6 +88,38 @@ errcode_t do_mknod_internal(ext2_ino_t cwd, const char *name, struct stat *st)
- /* Make a symlink name -> target */
- errcode_t do_symlink_internal(ext2_ino_t cwd, const char *name, char *target)
- {
-+	char			*cp;
-+	ext2_ino_t		parent_ino;
-+	errcode_t		retval;
-+	struct ext2_inode	inode;
-+	struct stat		st;
-+
-+	cp = strrchr(name, '/');
-+	if (cp) {
-+		*cp = 0;
-+		if ((retval =  ext2fs_namei(current_fs, root, cwd, name, &parent_ino))){
-+			com_err(name, retval, 0);
-+			return retval;
-+		}
-+		name = cp+1;
-+	} else
-+		parent_ino = cwd;
-+
-+try_again:
-+	retval = ext2fs_symlink(current_fs, parent_ino, 0, name, target);
-+	if (retval == EXT2_ET_DIR_NO_SPACE) {
-+		retval = ext2fs_expand_dir(current_fs, parent_ino);
-+		if (retval) {
-+			com_err("do_symlink_internal", retval, "while expanding directory");
-+			return retval;
-+		}
-+		goto try_again;
-+	}
-+	if (retval) {
-+		com_err("ext2fs_symlink", retval, 0);
-+		return retval;
-+	}
-+
- }
- 
- /* Make a directory in the fs */
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0005-misc-create_inode.c-copy-regular-file.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0005-misc-create_inode.c-copy-regular-file.patch
deleted file mode 100644
index 7935cd8..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0005-misc-create_inode.c-copy-regular-file.patch
+++ /dev/null
@@ -1,224 +0,0 @@
-From 2973c74afaa532f3f72639b463322b2523519c20 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 23 Dec 2013 03:28:12 -0500
-Subject: [PATCH 05/11] misc/create_inode.c: copy regular file
-
-The do_write_internal() is used for copying file from native fs to
-target, most of the code are from debugfs/debugfs.c, the
-debugfs/debugfs.c will be modified to use this function.
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/create_inode.c |  183 +++++++++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 183 insertions(+)
-
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-index f845103..98f4a93 100644
---- a/misc/create_inode.c
-+++ b/misc/create_inode.c
-@@ -8,6 +8,16 @@
- # endif
- #endif
- 
-+/* 64KiB is the minimium blksize to best minimize system call overhead. */
-+#ifndef IO_BUFSIZE
-+#define IO_BUFSIZE 64*1024
-+#endif
-+
-+/* Block size for `st_blocks' */
-+#ifndef S_BLKSIZE
-+#define S_BLKSIZE 512
-+#endif
-+
- /* Make a special file which is block, character and fifo */
- errcode_t do_mknod_internal(ext2_ino_t cwd, const char *name, struct stat *st)
- {
-@@ -127,9 +137,182 @@ errcode_t do_mkdir_internal(ext2_ino_t cwd, const char *name, struct stat *st)
- {
- }
- 
-+static errcode_t copy_file(int fd, ext2_ino_t newfile, int bufsize, int make_holes)
-+{
-+	ext2_file_t	e2_file;
-+	errcode_t	retval;
-+	int		got;
-+	unsigned int	written;
-+	char		*buf;
-+	char		*ptr;
-+	char		*zero_buf;
-+	int		cmp;
-+
-+	retval = ext2fs_file_open(current_fs, newfile,
-+				  EXT2_FILE_WRITE, &e2_file);
-+	if (retval)
-+		return retval;
-+
-+	retval = ext2fs_get_mem(bufsize, &buf);
-+	if (retval) {
-+		com_err("copy_file", retval, "can't allocate buffer\n");
-+		return retval;
-+	}
-+
-+	/* This is used for checking whether the whole block is zero */
-+	retval = ext2fs_get_memzero(bufsize, &zero_buf);
-+	if (retval) {
-+		com_err("copy_file", retval, "can't allocate buffer\n");
-+		ext2fs_free_mem(&buf);
-+		return retval;
-+	}
-+
-+	while (1) {
-+		got = read(fd, buf, bufsize);
-+		if (got == 0)
-+			break;
-+		if (got < 0) {
-+			retval = errno;
-+			goto fail;
-+		}
-+		ptr = buf;
-+
-+		/* Sparse copy */
-+		if (make_holes) {
-+			/* Check whether all is zero */
-+			cmp = memcmp(ptr, zero_buf, got);
-+			if (cmp == 0) {
-+				 /* The whole block is zero, make a hole */
-+				retval = ext2fs_file_lseek(e2_file, got, EXT2_SEEK_CUR, NULL);
-+				if (retval)
-+					goto fail;
-+				got = 0;
-+			}
-+		}
-+
-+		/* Normal copy */
-+		while (got > 0) {
-+			retval = ext2fs_file_write(e2_file, ptr,
-+						   got, &written);
-+			if (retval)
-+				goto fail;
-+
-+			got -= written;
-+			ptr += written;
-+		}
-+	}
-+	ext2fs_free_mem(&buf);
-+	ext2fs_free_mem(&zero_buf);
-+	retval = ext2fs_file_close(e2_file);
-+	return retval;
-+
-+fail:
-+	ext2fs_free_mem(&buf);
-+	ext2fs_free_mem(&zero_buf);
-+	(void) ext2fs_file_close(e2_file);
-+	return retval;
-+}
-+
- /* Copy the native file to the fs */
- errcode_t do_write_internal(ext2_ino_t cwd, const char *src, const char *dest)
- {
-+	int		fd;
-+	struct stat	statbuf;
-+	ext2_ino_t	newfile;
-+	errcode_t	retval;
-+	struct ext2_inode inode;
-+	int		bufsize = IO_BUFSIZE;
-+	int		make_holes = 0;
-+
-+	fd = open(src, O_RDONLY);
-+	if (fd < 0) {
-+		com_err(src, errno, 0);
-+		return errno;
-+	}
-+	if (fstat(fd, &statbuf) < 0) {
-+		com_err(src, errno, 0);
-+		close(fd);
-+		return errno;
-+	}
-+
-+	retval = ext2fs_namei(current_fs, root, cwd, dest, &newfile);
-+	if (retval == 0) {
-+		com_err(__func__, 0, "The file '%s' already exists\n", dest);
-+		close(fd);
-+		return retval;
-+	}
-+
-+	retval = ext2fs_new_inode(current_fs, cwd, 010755, 0, &newfile);
-+	if (retval) {
-+		com_err(__func__, retval, 0);
-+		close(fd);
-+		return retval;
-+	}
-+#ifdef DEBUGFS
-+	printf("Allocated inode: %u\n", newfile);
-+#endif
-+	retval = ext2fs_link(current_fs, cwd, dest, newfile,
-+				EXT2_FT_REG_FILE);
-+	if (retval == EXT2_ET_DIR_NO_SPACE) {
-+		retval = ext2fs_expand_dir(current_fs, cwd);
-+		if (retval) {
-+			com_err(__func__, retval, "while expanding directory");
-+			close(fd);
-+			return retval;
-+		}
-+		retval = ext2fs_link(current_fs, cwd, dest, newfile,
-+					EXT2_FT_REG_FILE);
-+	}
-+	if (retval) {
-+		com_err(dest, retval, 0);
-+		close(fd);
-+		return retval;
-+	}
-+        if (ext2fs_test_inode_bitmap2(current_fs->inode_map, newfile))
-+		com_err(__func__, 0, "Warning: inode already set");
-+	ext2fs_inode_alloc_stats2(current_fs, newfile, +1, 0);
-+	memset(&inode, 0, sizeof(inode));
-+	inode.i_mode = (statbuf.st_mode & ~LINUX_S_IFMT) | LINUX_S_IFREG;
-+	inode.i_atime = inode.i_ctime = inode.i_mtime =
-+		current_fs->now ? current_fs->now : time(0);
-+	inode.i_links_count = 1;
-+	inode.i_size = statbuf.st_size;
-+	if (current_fs->super->s_feature_incompat &
-+	    EXT3_FEATURE_INCOMPAT_EXTENTS) {
-+		int i;
-+		struct ext3_extent_header *eh;
-+
-+		eh = (struct ext3_extent_header *) &inode.i_block[0];
-+		eh->eh_depth = 0;
-+		eh->eh_entries = 0;
-+		eh->eh_magic = ext2fs_cpu_to_le16(EXT3_EXT_MAGIC);
-+		i = (sizeof(inode.i_block) - sizeof(*eh)) /
-+			sizeof(struct ext3_extent);
-+		eh->eh_max = ext2fs_cpu_to_le16(i);
-+		inode.i_flags |= EXT4_EXTENTS_FL;
-+	}
-+
-+	if ((retval = ext2fs_write_new_inode(current_fs, newfile, &inode))) {
-+		com_err(__func__, retval, "while creating inode %u", newfile);
-+		close(fd);
-+		return retval;
-+	}
-+	if (LINUX_S_ISREG(inode.i_mode)) {
-+		if (statbuf.st_blocks < statbuf.st_size / S_BLKSIZE) {
-+			make_holes = 1;
-+			/*
-+			 * Use I/O blocksize as buffer size when
-+			 * copying sparse files.
-+			 */
-+			bufsize = statbuf.st_blksize;
-+		}
-+		retval = copy_file(fd, newfile, bufsize, make_holes);
-+		if (retval)
-+			com_err("copy_file", retval, 0);
-+	}
-+	close(fd);
-+
-+	return 0;
- }
- 
- /* Copy files from source_dir to fs */
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0006-misc-create_inode.c-create-directory.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0006-misc-create_inode.c-create-directory.patch
deleted file mode 100644
index 5c7ca9c..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0006-misc-create_inode.c-create-directory.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From c8d1c43be24489036137f8fdebcfccc208f7cc8b Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 23 Dec 2013 03:34:14 -0500
-Subject: [PATCH 06/11] misc/create_inode.c: create directory
-
-The do_mkdir_internal() is used for making dir on the target fs, most of
-the code are from debugfs/debugfs.c, the debugfs/debugfs.c will be
-modified to use this function.
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/create_inode.c |   31 +++++++++++++++++++++++++++++++
- 1 file changed, 31 insertions(+)
-
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-index 98f4a93..6a8c92a 100644
---- a/misc/create_inode.c
-+++ b/misc/create_inode.c
-@@ -135,6 +135,37 @@ try_again:
- /* Make a directory in the fs */
- errcode_t do_mkdir_internal(ext2_ino_t cwd, const char *name, struct stat *st)
- {
-+	char			*cp;
-+	ext2_ino_t		parent_ino, ino;
-+	errcode_t		retval;
-+	struct ext2_inode	inode;
-+
-+
-+	cp = strrchr(name, '/');
-+	if (cp) {
-+		*cp = 0;
-+		if ((retval =  ext2fs_namei(current_fs, root, cwd, name, &parent_ino))){
-+			com_err(name, retval, 0);
-+			return retval;
-+		}
-+		name = cp+1;
-+	} else
-+		parent_ino = cwd;
-+
-+try_again:
-+	retval = ext2fs_mkdir(current_fs, parent_ino, 0, name);
-+	if (retval == EXT2_ET_DIR_NO_SPACE) {
-+		retval = ext2fs_expand_dir(current_fs, parent_ino);
-+		if (retval) {
-+			com_err(__func__, retval, "while expanding directory");
-+			return retval;
-+		}
-+		goto try_again;
-+	}
-+	if (retval) {
-+		com_err("ext2fs_mkdir", retval, 0);
-+		return retval;
-+	}
- }
- 
- static errcode_t copy_file(int fd, ext2_ino_t newfile, int bufsize, int make_holes)
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0007-misc-create_inode.c-set-owner-mode-time-for-the-inod.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0007-misc-create_inode.c-set-owner-mode-time-for-the-inod.patch
deleted file mode 100644
index f296393..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0007-misc-create_inode.c-set-owner-mode-time-for-the-inod.patch
+++ /dev/null
@@ -1,81 +0,0 @@
-From 2b1f6e6b386703a5d7e60b7d8b72746f3d31a8bc Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 23 Dec 2013 03:39:56 -0500
-Subject: [PATCH 07/11] misc/create_inode.c: set owner/mode/time for the inode
-
-Set the uid, gid, mode and time for inode.
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/create_inode.c |   45 +++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 45 insertions(+)
-
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-index 6a8c92a..aad7354 100644
---- a/misc/create_inode.c
-+++ b/misc/create_inode.c
-@@ -18,6 +18,40 @@
- #define S_BLKSIZE 512
- #endif
- 
-+/* Fill the uid, gid, mode and time for the inode */
-+static void fill_inode(struct ext2_inode *inode, struct stat *st)
-+{
-+	if (st != NULL) {
-+		inode->i_uid = st->st_uid;
-+		inode->i_gid = st->st_gid;
-+		inode->i_mode |= st->st_mode;
-+		inode->i_atime = st->st_atime;
-+		inode->i_mtime = st->st_mtime;
-+		inode->i_ctime = st->st_ctime;
-+	}
-+}
-+
-+/* Set the uid, gid, mode and time for the inode */
-+errcode_t set_inode_extra(ext2_ino_t cwd, ext2_ino_t ino, struct stat *st)
-+{
-+	errcode_t		retval;
-+	struct ext2_inode	inode;
-+
-+	retval = ext2fs_read_inode(current_fs, ino, &inode);
-+        if (retval) {
-+		com_err(__func__, retval, "while reading inode %u", ino);
-+		return retval;
-+	}
-+
-+	fill_inode(&inode, st);
-+
-+	retval = ext2fs_write_inode(current_fs, ino, &inode);
-+	if (retval) {
-+		com_err(__func__, retval, "while writing inode %u", ino);
-+		return retval;
-+	}
-+}
-+
- /* Make a special file which is block, character and fifo */
- errcode_t do_mknod_internal(ext2_ino_t cwd, const char *name, struct stat *st)
- {
-@@ -435,6 +469,17 @@ errcode_t populate_fs(ext2_ino_t parent_ino, const char *source_dir)
- 				com_err(__func__, 0,
- 					_("ignoring entry \"%s\""), name);
- 		}
-+
-+		if ((retval =  ext2fs_namei(current_fs, root, parent_ino, name, &ino))){
-+			com_err(name, retval, 0);
-+			return retval;
-+		}
-+
-+		if ((retval = set_inode_extra(parent_ino, ino, &st))) {
-+			com_err(__func__, retval,
-+				_("while setting inode for \"%s\""), name);
-+			return retval;
-+		}
- 	}
- 	closedir(dh);
- 	return retval;
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0008-mke2fs.c-add-an-option-d-root-directory.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0008-mke2fs.c-add-an-option-d-root-directory.patch
deleted file mode 100644
index 1f98673..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0008-mke2fs.c-add-an-option-d-root-directory.patch
+++ /dev/null
@@ -1,168 +0,0 @@
-From df856929e42bd4f3bdc8d4f59ee82ae8b28532e6 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Tue, 24 Dec 2013 01:50:45 -0500
-Subject: [PATCH 08/11] mke2fs.c: add an option: -d root-directory
-
-This option is used for adding the files from a given directory (the
-root-directory) to the filesystem, it is similiar to genext2fs, but
-genext2fs doesn't fully support ext4.
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/Makefile.in |   14 ++++++++++----
- misc/mke2fs.c    |   32 +++++++++++++++++++++++---------
- 2 files changed, 33 insertions(+), 13 deletions(-)
-
-diff --git a/misc/Makefile.in b/misc/Makefile.in
-index 553c361..8253723 100644
---- a/misc/Makefile.in
-+++ b/misc/Makefile.in
-@@ -42,7 +42,8 @@ LPROGS=		@E2INITRD_PROG@
- 
- TUNE2FS_OBJS=	tune2fs.o util.o
- MKLPF_OBJS=	mklost+found.o
--MKE2FS_OBJS=	mke2fs.o util.o profile.o prof_err.o default_profile.o
-+MKE2FS_OBJS=	mke2fs.o util.o profile.o prof_err.o default_profile.o \
-+			create_inode.o
- CHATTR_OBJS=	chattr.o
- LSATTR_OBJS=	lsattr.o
- UUIDGEN_OBJS=	uuidgen.o
-@@ -60,7 +61,8 @@ E2FREEFRAG_OBJS= e2freefrag.o
- PROFILED_TUNE2FS_OBJS=	profiled/tune2fs.o profiled/util.o
- PROFILED_MKLPF_OBJS=	profiled/mklost+found.o
- PROFILED_MKE2FS_OBJS=	profiled/mke2fs.o profiled/util.o profiled/profile.o \
--			profiled/prof_err.o profiled/default_profile.o
-+			profiled/prof_err.o profiled/default_profile.o \
-+			profiled/create_inode.o
- PROFILED_CHATTR_OBJS=	profiled/chattr.o
- PROFILED_LSATTR_OBJS=	profiled/lsattr.o
- PROFILED_UUIDGEN_OBJS=	profiled/uuidgen.o
-@@ -82,7 +84,7 @@ SRCS=	$(srcdir)/tune2fs.c $(srcdir)/mklost+found.c $(srcdir)/mke2fs.c \
- 		$(srcdir)/uuidgen.c $(srcdir)/blkid.c $(srcdir)/logsave.c \
- 		$(srcdir)/filefrag.c $(srcdir)/base_device.c \
- 		$(srcdir)/ismounted.c $(srcdir)/../e2fsck/profile.c \
--		$(srcdir)/e2undo.c $(srcdir)/e2freefrag.c
-+		$(srcdir)/e2undo.c $(srcdir)/e2freefrag.c $(srcdir)/create_inode.c
- 
- LIBS= $(LIBEXT2FS) $(LIBCOM_ERR) 
- DEPLIBS= $(LIBEXT2FS) $(DEPLIBCOM_ERR)
-@@ -630,7 +632,7 @@ mke2fs.o: $(srcdir)/mke2fs.c $(top_builddir)/lib/config.h \
-  $(top_srcdir)/lib/ext2fs/ext2_ext_attr.h $(top_srcdir)/lib/ext2fs/bitops.h \
-  $(top_srcdir)/lib/e2p/e2p.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
-  $(srcdir)/util.h profile.h prof_err.h $(top_srcdir)/version.h \
-- $(srcdir)/nls-enable.h $(top_srcdir)/lib/quota/mkquota.h \
-+ $(srcdir)/nls-enable.h $(top_srcdir)/lib/quota/mkquota.h $(srcdir)/create_inode.h\
-  $(top_srcdir)/lib/quota/quotaio.h $(top_srcdir)/lib/quota/dqblk_v2.h \
-  $(top_srcdir)/lib/quota/quotaio_tree.h $(top_srcdir)/lib/../e2fsck/dict.h
- chattr.o: $(srcdir)/chattr.c $(top_builddir)/lib/config.h \
-@@ -710,3 +712,7 @@ e2freefrag.o: $(srcdir)/e2freefrag.c $(top_builddir)/lib/config.h \
-  $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_builddir)/lib/ext2fs/ext2_err.h \
-  $(top_srcdir)/lib/ext2fs/ext2_ext_attr.h $(top_srcdir)/lib/ext2fs/bitops.h \
-  $(srcdir)/e2freefrag.h
-+create_inode.o: $(srcdir)/create_inode.h $(srcdir)/create_inode.c \
-+ $(top_builddir)/lib/config.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
-+ $(top_srcdir)/lib/et/com_err.h $(top_srcdir)/lib/e2p/e2p.h \
-+ $(srcdir)/nls-enable.h
-diff --git a/misc/mke2fs.c b/misc/mke2fs.c
-index 2e8ba60..578b62d 100644
---- a/misc/mke2fs.c
-+++ b/misc/mke2fs.c
-@@ -22,7 +22,6 @@
- #include <stdio.h>
- #include <string.h>
- #include <strings.h>
--#include <fcntl.h>
- #include <ctype.h>
- #include <time.h>
- #ifdef __linux__
-@@ -44,24 +43,19 @@ extern int optind;
- #include <errno.h>
- #endif
- #include <sys/ioctl.h>
--#include <sys/types.h>
--#include <sys/stat.h>
- #include <libgen.h>
- #include <limits.h>
- #include <blkid/blkid.h>
- 
- #include "ext2fs/ext2_fs.h"
- #include "ext2fs/ext2fsP.h"
--#include "et/com_err.h"
- #include "uuid/uuid.h"
--#include "e2p/e2p.h"
--#include "ext2fs/ext2fs.h"
- #include "util.h"
- #include "profile.h"
- #include "prof_err.h"
- #include "../version.h"
--#include "nls-enable.h"
- #include "quota/mkquota.h"
-+#include "create_inode.h"
- 
- #define STRIDE_LENGTH 8
- 
-@@ -105,6 +99,7 @@ static char *mount_dir;
- char *journal_device;
- static int sync_kludge;	/* Set using the MKE2FS_SYNC env. option */
- static char **fs_types;
-+const char *root_dir;  /* Copy files from the specified directory */
- 
- static profile_t	profile;
- 
-@@ -116,7 +111,8 @@ static void usage(void)
- 	fprintf(stderr, _("Usage: %s [-c|-l filename] [-b block-size] "
- 	"[-C cluster-size]\n\t[-i bytes-per-inode] [-I inode-size] "
- 	"[-J journal-options]\n"
--	"\t[-G flex-group-size] [-N number-of-inodes]\n"
-+	"\t[-G flex-group-size] [-N number-of-inodes] "
-+	"[-d root-directory]\n"
- 	"\t[-m reserved-blocks-percentage] [-o creator-os]\n"
- 	"\t[-g blocks-per-group] [-L volume-label] "
- 	"[-M last-mounted-directory]\n\t[-O feature[,...]] "
-@@ -1394,7 +1390,7 @@ profile_error:
- 	}
- 
- 	while ((c = getopt (argc, argv,
--		    "b:cg:i:jl:m:no:qr:s:t:vC:DE:FG:I:J:KL:M:N:O:R:ST:U:V")) != EOF) {
-+		    "b:cg:i:jl:m:no:qr:s:t:d:vC:DE:FG:I:J:KL:M:N:O:R:ST:U:V")) != EOF) {
- 		switch (c) {
- 		case 'b':
- 			blocksize = parse_num_blocks2(optarg, -1);
-@@ -1582,6 +1578,9 @@ profile_error:
- 		case 'U':
- 			fs_uuid = optarg;
- 			break;
-+		case 'd':
-+			root_dir = optarg;
-+			break;
- 		case 'v':
- 			verbose = 1;
- 			break;
-@@ -2726,6 +2725,21 @@ no_journal:
- 				       EXT4_FEATURE_RO_COMPAT_QUOTA))
- 		create_quota_inodes(fs);
- 
-+	/* Copy files from the specified directory */
-+	if (root_dir) {
-+		if (!quiet)
-+			printf("%s", _("Copying files into the device: "));
-+
-+		current_fs = fs;
-+		root = EXT2_ROOT_INO;
-+		retval = populate_fs(root, root_dir);
-+		if (retval)
-+			fprintf(stderr, "%s",
-+				_("\nError while populating file system"));
-+		else if (!quiet)
-+			printf("%s", _("done\n"));
-+	}
-+
- 	if (!quiet)
- 		printf("%s", _("Writing superblocks and "
- 		       "filesystem accounting information: "));
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0009-misc-create_inode.c-handle-hardlinks.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0009-misc-create_inode.c-handle-hardlinks.patch
deleted file mode 100644
index a330ee4..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0009-misc-create_inode.c-handle-hardlinks.patch
+++ /dev/null
@@ -1,210 +0,0 @@
-From d83dc950b3ec1fbde33b23d42c5154091a74f4d9 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 23 Dec 2013 03:44:03 -0500
-Subject: [PATCH 09/11] misc/create_inode.c: handle hardlinks
-
-Create the inode and save the native inode number when we meet the hard
-link (st_nlink > 1) at the first time, use ext2fs_link() to link the
-name to the target inode number when we meet the same native inode
-number again.
-
-This algorithm is referred from the genext2fs.
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/create_inode.c |   88 +++++++++++++++++++++++++++++++++++++++++++++++++++
- misc/create_inode.h |   18 +++++++++++
- misc/mke2fs.c       |   12 +++++++
- 3 files changed, 118 insertions(+)
-
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-index aad7354..763504d 100644
---- a/misc/create_inode.c
-+++ b/misc/create_inode.c
-@@ -18,6 +18,44 @@
- #define S_BLKSIZE 512
- #endif
- 
-+/* For saving the hard links */
-+int hdlink_cnt = HDLINK_CNT;
-+
-+/* Link an inode number to a directory */
-+static errcode_t add_link(ext2_ino_t parent_ino, ext2_ino_t ino, const char *name)
-+{
-+	struct ext2_inode	inode;
-+	errcode_t		retval;
-+
-+	retval = ext2fs_read_inode(current_fs, ino, &inode);
-+        if (retval) {
-+		com_err(__func__, retval, "while reading inode %u", ino);
-+		return retval;
-+	}
-+
-+	retval = ext2fs_link(current_fs, parent_ino, name, ino, inode.i_flags);
-+	if (retval == EXT2_ET_DIR_NO_SPACE) {
-+		retval = ext2fs_expand_dir(current_fs, parent_ino);
-+		if (retval) {
-+			com_err(__func__, retval, "while expanding directory");
-+			return retval;
-+		}
-+		retval = ext2fs_link(current_fs, parent_ino, name, ino, inode.i_flags);
-+	}
-+	if (retval) {
-+		com_err(__func__, retval, "while linking %s", name);
-+		return retval;
-+	}
-+
-+	inode.i_links_count++;
-+
-+	retval = ext2fs_write_inode(current_fs, ino, &inode);
-+	if (retval)
-+		com_err(__func__, retval, "while writing inode %u", ino);
-+
-+	return retval;
-+}
-+
- /* Fill the uid, gid, mode and time for the inode */
- static void fill_inode(struct ext2_inode *inode, struct stat *st)
- {
-@@ -278,6 +316,17 @@ fail:
- 	return retval;
- }
- 
-+int is_hardlink(ext2_ino_t ino)
-+{
-+	int i;
-+
-+	for(i = 0; i < hdlinks.count; i++) {
-+		if(hdlinks.hdl[i].src_ino == ino)
-+			return i;
-+	}
-+	return -1;
-+}
-+
- /* Copy the native file to the fs */
- errcode_t do_write_internal(ext2_ino_t cwd, const char *src, const char *dest)
- {
-@@ -388,9 +437,11 @@ errcode_t populate_fs(ext2_ino_t parent_ino, const char *source_dir)
- 	struct dirent	*dent;
- 	struct stat	st;
- 	char		ln_target[PATH_MAX];
-+	unsigned int	save_inode;
- 	ext2_ino_t	ino;
- 	errcode_t	retval;
- 	int		read_cnt;
-+	int		hdlink;
- 
- 	root = EXT2_ROOT_INO;
- 
-@@ -412,6 +463,22 @@ errcode_t populate_fs(ext2_ino_t parent_ino, const char *source_dir)
- 		lstat(dent->d_name, &st);
- 		name = dent->d_name;
- 
-+		/* Check for hardlinks */
-+		save_inode = 0;
-+		if (!S_ISDIR(st.st_mode) && !S_ISLNK(st.st_mode) && st.st_nlink > 1) {
-+			hdlink = is_hardlink(st.st_ino);
-+			if (hdlink >= 0) {
-+				retval = add_link(parent_ino,
-+						hdlinks.hdl[hdlink].dst_ino, name);
-+				if (retval) {
-+					com_err(__func__, retval, "while linking %s", name);
-+					return retval;
-+				}
-+				continue;
-+			} else
-+				save_inode = 1;
-+		}
-+
- 		switch(st.st_mode & S_IFMT) {
- 			case S_IFCHR:
- 			case S_IFBLK:
-@@ -480,6 +547,27 @@ errcode_t populate_fs(ext2_ino_t parent_ino, const char *source_dir)
- 				_("while setting inode for \"%s\""), name);
- 			return retval;
- 		}
-+
-+		/* Save the hardlink ino */
-+		if (save_inode) {
-+			/*
-+			 * Check whether need more memory, and we don't need
-+			 * free() since the lifespan will be over after the fs
-+			 * populated.
-+			 */
-+			if (hdlinks.count == hdlink_cnt) {
-+				if ((hdlinks.hdl = realloc (hdlinks.hdl,
-+						(hdlink_cnt + HDLINK_CNT) *
-+						sizeof (struct hdlink_s))) == NULL) {
-+					com_err(name, errno, "Not enough memory");
-+					return errno;
-+				}
-+				hdlink_cnt += HDLINK_CNT;
-+			}
-+			hdlinks.hdl[hdlinks.count].src_ino = st.st_ino;
-+			hdlinks.hdl[hdlinks.count].dst_ino = ino;
-+			hdlinks.count++;
-+		}
- 	}
- 	closedir(dh);
- 	return retval;
-diff --git a/misc/create_inode.h b/misc/create_inode.h
-index 9fc97fa..2b6d429 100644
---- a/misc/create_inode.h
-+++ b/misc/create_inode.h
-@@ -6,9 +6,27 @@
- #include "ext2fs/ext2fs.h"
- #include "nls-enable.h"
- 
-+struct hdlink_s
-+{
-+	ext2_ino_t src_ino;
-+	ext2_ino_t dst_ino;
-+};
-+
-+struct hdlinks_s
-+{
-+	int count;
-+	struct hdlink_s *hdl;
-+};
-+
-+struct hdlinks_s hdlinks;
-+
- ext2_filsys    current_fs;
- ext2_ino_t     root;
- 
-+/* For saving the hard links */
-+#define HDLINK_CNT     4
-+extern int hdlink_cnt;
-+
- /* For populating the filesystem */
- extern errcode_t populate_fs(ext2_ino_t parent_ino, const char *source_dir);
- extern errcode_t do_mknod_internal(ext2_ino_t cwd, const char *name, struct stat *st);
-diff --git a/misc/mke2fs.c b/misc/mke2fs.c
-index 578b62d..a63f0b7 100644
---- a/misc/mke2fs.c
-+++ b/misc/mke2fs.c
-@@ -2730,6 +2730,18 @@ no_journal:
- 		if (!quiet)
- 			printf("%s", _("Copying files into the device: "));
- 
-+		/*
-+		 * Allocate memory for the hardlinks, we don't need free()
-+		 * since the lifespan will be over after the fs populated.
-+		 */
-+		if ((hdlinks.hdl = (struct hdlink_s *)
-+				malloc(hdlink_cnt * sizeof(struct hdlink_s))) == NULL) {
-+			fprintf(stderr, "%s", _("\nNot enough memory\n"));
-+			retval = ext2fs_close(fs);
-+			return retval;
-+		}
-+
-+		hdlinks.count = 0;
- 		current_fs = fs;
- 		root = EXT2_ROOT_INO;
- 		retval = populate_fs(root, root_dir);
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0010-debugfs-use-the-functions-in-misc-create_inode.c.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0010-debugfs-use-the-functions-in-misc-create_inode.c.patch
deleted file mode 100644
index 2a6ca8f..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0010-debugfs-use-the-functions-in-misc-create_inode.c.patch
+++ /dev/null
@@ -1,496 +0,0 @@
-From db89992fab2215f52dce4c595a39271b4ff3000b Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 23 Dec 2013 04:22:22 -0500
-Subject: [PATCH 10/11] debugfs: use the functions in misc/create_inode.c
-
-* Use the functions in misc/create_inode.c, and remove the duplicated
-  code.
-
-* The CREATE_INODE_DEPS in the debugfs/Makefile.in is used for recording
-  create_inode.o's depends which is from misc/Makefile.in, we have to
-  recompile create_inode.o because we need it to print more messages when
-  it is used by debugfs, just like we recompile e2freefrag.o, but it seems
-  that the e2freefrag.o's depends in debugfs/Makefile.in is incorrect, it
-  would not rebuild when its depends (e.g.: lib/config.h) is changed,
-  which would cause unexpected errors. Make duplicated code in
-  debugfs/Makefile.in and misc/Makefile.in is not a good idea, maybe we'd
-  better define CREATE_INODE_DEPS in the top Makefile, I'd like to send
-  another patch and fix the e2freefrag if you are fine with it.
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- debugfs/Makefile.in |   17 ++-
- debugfs/debugfs.c   |  305 +++------------------------------------------------
- debugfs/debugfs.h   |    1 +
- 3 files changed, 31 insertions(+), 292 deletions(-)
-
-diff --git a/debugfs/Makefile.in b/debugfs/Makefile.in
-index bf037e0..f51b78e 100644
---- a/debugfs/Makefile.in
-+++ b/debugfs/Makefile.in
-@@ -18,7 +18,7 @@ MK_CMDS=	_SS_DIR_OVERRIDE=../lib/ss ../lib/ss/mk_cmds
- 
- DEBUG_OBJS= debug_cmds.o debugfs.o util.o ncheck.o icheck.o ls.o \
- 	lsdel.o dump.o set_fields.o logdump.o htree.o unused.o e2freefrag.o \
--	filefrag.o extent_cmds.o extent_inode.o zap.o
-+	filefrag.o extent_cmds.o extent_inode.o zap.o create_inode.o
- 
- RO_DEBUG_OBJS= ro_debug_cmds.o ro_debugfs.o util.o ncheck.o icheck.o ls.o \
- 	lsdel.o logdump.o htree.o e2freefrag.o filefrag.o extent_cmds.o \
-@@ -28,7 +28,13 @@ SRCS= debug_cmds.c $(srcdir)/debugfs.c $(srcdir)/util.c $(srcdir)/ls.c \
- 	$(srcdir)/ncheck.c $(srcdir)/icheck.c $(srcdir)/lsdel.c \
- 	$(srcdir)/dump.c $(srcdir)/set_fields.c ${srcdir}/logdump.c \
- 	$(srcdir)/htree.c $(srcdir)/unused.c ${srcdir}/../misc/e2freefrag.c \
--	$(srcdir)/filefrag.c $(srcdir)/extent_inode.c $(srcdir)/zap.c
-+	$(srcdir)/filefrag.c $(srcdir)/extent_inode.c $(srcdir)/zap.c \
-+	$(srcdir)/../misc/create_inode.c
-+
-+CREATE_INODE_DEPS= $(srcdir)/../misc/create_inode.h \
-+	$(srcdir)/../misc/create_inode.c $(top_builddir)/lib/config.h \
-+	$(srcdir)/../lib/ext2fs/ext2fs.h $(srcdir)/../lib/et/com_err.h \
-+	$(srcdir)/../lib/e2p/e2p.h $(srcdir)/../misc/nls-enable.h
- 
- LIBS= $(LIBEXT2FS) $(LIBE2P) $(LIBSS) $(LIBCOM_ERR) $(LIBBLKID) \
- 	$(LIBUUID)
-@@ -81,6 +87,11 @@ e2freefrag.o: $(srcdir)/../misc/e2freefrag.c
- 	$(E) "	CC $@"
- 	$(Q) $(CC) -c $(ALL_CFLAGS) -I$(srcdir) $< -DDEBUGFS -o $@
- 
-+create_inode.o: $(CREATE_INODE_DEPS)
-+	$(E) "	CC $@"
-+	$(Q) $(CC) -c $(ALL_CFLAGS) -I$(srcdir) \
-+		 $(srcdir)/../misc/create_inode.c -DDEBUGFS -o $@
-+
- debugfs.8: $(DEP_SUBSTITUTE) $(srcdir)/debugfs.8.in
- 	$(E) "	SUBST $@"
- 	$(Q) $(SUBSTITUTE_UPTIME) $(srcdir)/debugfs.8.in debugfs.8
-@@ -142,7 +153,7 @@ debugfs.o: $(srcdir)/debugfs.c $(top_srcdir)/lib/et/com_err.h \
-  $(top_srcdir)/lib/ext2fs/ext2_ext_attr.h $(top_srcdir)/lib/ext2fs/bitops.h \
-  $(top_srcdir)/lib/e2p/e2p.h $(top_srcdir)/version.h $(srcdir)/jfs_user.h \
-  $(top_srcdir)/lib/ext2fs/kernel-jbd.h $(top_srcdir)/lib/ext2fs/jfs_compat.h \
-- $(top_srcdir)/lib/ext2fs/kernel-list.h
-+ $(top_srcdir)/lib/ext2fs/kernel-list.h $(top_srcdir)/misc/util.h
- util.o: $(srcdir)/util.c $(srcdir)/debugfs.h \
-  $(top_srcdir)/lib/ext2fs/ext2_fs.h $(top_builddir)/lib/ext2fs/ext2_types.h \
-  $(top_srcdir)/lib/ext2fs/ext2fs.h $(top_srcdir)/lib/ext2fs/ext3_extents.h \
-diff --git a/debugfs/debugfs.c b/debugfs/debugfs.c
-index 9c215f7..62e9f44 100644
---- a/debugfs/debugfs.c
-+++ b/debugfs/debugfs.c
-@@ -25,8 +25,6 @@ extern char *optarg;
- #include <errno.h>
- #endif
- #include <fcntl.h>
--#include <sys/types.h>
--#include <sys/stat.h>
- 
- #include "debugfs.h"
- #include "uuid/uuid.h"
-@@ -41,22 +39,11 @@ extern char *optarg;
- #define BUFSIZ 8192
- #endif
- 
--/* 64KiB is the minimium blksize to best minimize system call overhead. */
--#ifndef IO_BUFSIZE
--#define IO_BUFSIZE 64*1024
--#endif
--
--/* Block size for `st_blocks' */
--#ifndef S_BLKSIZE
--#define S_BLKSIZE 512
--#endif
--
- ss_request_table *extra_cmds;
- const char *debug_prog_name;
- int sci_idx;
- 
--ext2_filsys	current_fs = NULL;
--ext2_ino_t	root, cwd;
-+ext2_ino_t	cwd;
- 
- static void open_filesystem(char *device, int open_flags, blk64_t superblock,
- 			    blk64_t blocksize, int catastrophic,
-@@ -1576,189 +1563,24 @@ void do_find_free_inode(int argc, char *argv[])
- }
- 
- #ifndef READ_ONLY
--static errcode_t copy_file(int fd, ext2_ino_t newfile, int bufsize, int make_holes)
--{
--	ext2_file_t	e2_file;
--	errcode_t	retval;
--	int		got;
--	unsigned int	written;
--	char		*buf;
--	char		*ptr;
--	char		*zero_buf;
--	int		cmp;
--
--	retval = ext2fs_file_open(current_fs, newfile,
--				  EXT2_FILE_WRITE, &e2_file);
--	if (retval)
--		return retval;
--
--	retval = ext2fs_get_mem(bufsize, &buf);
--	if (retval) {
--		com_err("copy_file", retval, "can't allocate buffer\n");
--		return retval;
--	}
--
--	/* This is used for checking whether the whole block is zero */
--	retval = ext2fs_get_memzero(bufsize, &zero_buf);
--	if (retval) {
--		com_err("copy_file", retval, "can't allocate buffer\n");
--		ext2fs_free_mem(&buf);
--		return retval;
--	}
--
--	while (1) {
--		got = read(fd, buf, bufsize);
--		if (got == 0)
--			break;
--		if (got < 0) {
--			retval = errno;
--			goto fail;
--		}
--		ptr = buf;
--
--		/* Sparse copy */
--		if (make_holes) {
--			/* Check whether all is zero */
--			cmp = memcmp(ptr, zero_buf, got);
--			if (cmp == 0) {
--				 /* The whole block is zero, make a hole */
--				retval = ext2fs_file_lseek(e2_file, got, EXT2_SEEK_CUR, NULL);
--				if (retval)
--					goto fail;
--				got = 0;
--			}
--		}
--
--		/* Normal copy */
--		while (got > 0) {
--			retval = ext2fs_file_write(e2_file, ptr,
--						   got, &written);
--			if (retval)
--				goto fail;
--
--			got -= written;
--			ptr += written;
--		}
--	}
--	ext2fs_free_mem(&buf);
--	ext2fs_free_mem(&zero_buf);
--	retval = ext2fs_file_close(e2_file);
--	return retval;
--
--fail:
--	ext2fs_free_mem(&buf);
--	ext2fs_free_mem(&zero_buf);
--	(void) ext2fs_file_close(e2_file);
--	return retval;
--}
--
--
- void do_write(int argc, char *argv[])
- {
--	int		fd;
--	struct stat	statbuf;
--	ext2_ino_t	newfile;
- 	errcode_t	retval;
--	struct ext2_inode inode;
--	int		bufsize = IO_BUFSIZE;
--	int		make_holes = 0;
- 
- 	if (common_args_process(argc, argv, 3, 3, "write",
- 				"<native file> <new file>", CHECK_FS_RW))
- 		return;
- 
--	fd = open(argv[1], O_RDONLY);
--	if (fd < 0) {
--		com_err(argv[1], errno, 0);
--		return;
--	}
--	if (fstat(fd, &statbuf) < 0) {
--		com_err(argv[1], errno, 0);
--		close(fd);
--		return;
--	}
--
--	retval = ext2fs_namei(current_fs, root, cwd, argv[2], &newfile);
--	if (retval == 0) {
--		com_err(argv[0], 0, "The file '%s' already exists\n", argv[2]);
--		close(fd);
--		return;
--	}
--
--	retval = ext2fs_new_inode(current_fs, cwd, 010755, 0, &newfile);
--	if (retval) {
-+	if ((retval = do_write_internal(cwd, argv[1], argv[2])))
- 		com_err(argv[0], retval, 0);
--		close(fd);
--		return;
--	}
--	printf("Allocated inode: %u\n", newfile);
--	retval = ext2fs_link(current_fs, cwd, argv[2], newfile,
--			     EXT2_FT_REG_FILE);
--	if (retval == EXT2_ET_DIR_NO_SPACE) {
--		retval = ext2fs_expand_dir(current_fs, cwd);
--		if (retval) {
--			com_err(argv[0], retval, "while expanding directory");
--			close(fd);
--			return;
--		}
--		retval = ext2fs_link(current_fs, cwd, argv[2], newfile,
--				     EXT2_FT_REG_FILE);
--	}
--	if (retval) {
--		com_err(argv[2], retval, 0);
--		close(fd);
--		return;
--	}
--        if (ext2fs_test_inode_bitmap2(current_fs->inode_map,newfile))
--		com_err(argv[0], 0, "Warning: inode already set");
--	ext2fs_inode_alloc_stats2(current_fs, newfile, +1, 0);
--	memset(&inode, 0, sizeof(inode));
--	inode.i_mode = (statbuf.st_mode & ~LINUX_S_IFMT) | LINUX_S_IFREG;
--	inode.i_atime = inode.i_ctime = inode.i_mtime =
--		current_fs->now ? current_fs->now : time(0);
--	inode.i_links_count = 1;
--	inode.i_size = statbuf.st_size;
--	if (current_fs->super->s_feature_incompat &
--	    EXT3_FEATURE_INCOMPAT_EXTENTS) {
--		int i;
--		struct ext3_extent_header *eh;
--
--		eh = (struct ext3_extent_header *) &inode.i_block[0];
--		eh->eh_depth = 0;
--		eh->eh_entries = 0;
--		eh->eh_magic = ext2fs_cpu_to_le16(EXT3_EXT_MAGIC);
--		i = (sizeof(inode.i_block) - sizeof(*eh)) /
--			sizeof(struct ext3_extent);
--		eh->eh_max = ext2fs_cpu_to_le16(i);
--		inode.i_flags |= EXT4_EXTENTS_FL;
--	}
--	if (debugfs_write_new_inode(newfile, &inode, argv[0])) {
--		close(fd);
--		return;
--	}
--	if (LINUX_S_ISREG(inode.i_mode)) {
--		if (statbuf.st_blocks < statbuf.st_size / S_BLKSIZE) {
--			make_holes = 1;
--			/*
--			 * Use I/O blocksize as buffer size when
--			 * copying sparse files.
--			 */
--			bufsize = statbuf.st_blksize;
--		}
--		retval = copy_file(fd, newfile, bufsize, make_holes);
--		if (retval)
--			com_err("copy_file", retval, 0);
--	}
--	close(fd);
- }
- 
- void do_mknod(int argc, char *argv[])
- {
- 	unsigned long	mode, major, minor;
--	ext2_ino_t	newfile;
- 	errcode_t 	retval;
--	struct ext2_inode inode;
- 	int		filetype, nr;
-+	struct stat	st;
- 
- 	if (check_fs_open(argv[0]))
- 		return;
-@@ -1767,115 +1589,50 @@ void do_mknod(int argc, char *argv[])
- 		com_err(argv[0], 0, "Usage: mknod <name> [p| [c|b] <major> <minor>]");
- 		return;
- 	}
-+
- 	mode = minor = major = 0;
- 	switch (argv[2][0]) {
- 		case 'p':
--			mode = LINUX_S_IFIFO;
--			filetype = EXT2_FT_FIFO;
-+			st.st_mode = S_IFIFO;
- 			nr = 3;
- 			break;
- 		case 'c':
--			mode = LINUX_S_IFCHR;
--			filetype = EXT2_FT_CHRDEV;
-+			st.st_mode = S_IFCHR;
- 			nr = 5;
- 			break;
- 		case 'b':
--			mode = LINUX_S_IFBLK;
--			filetype = EXT2_FT_BLKDEV;
-+			st.st_mode = S_IFBLK;
- 			nr = 5;
- 			break;
- 		default:
--			filetype = 0;
- 			nr = 0;
- 	}
-+
- 	if (nr == 5) {
- 		major = strtoul(argv[3], argv+3, 0);
- 		minor = strtoul(argv[4], argv+4, 0);
- 		if (major > 65535 || minor > 65535 || argv[3][0] || argv[4][0])
- 			nr = 0;
- 	}
-+
- 	if (argc != nr)
- 		goto usage;
--	if (check_fs_read_write(argv[0]))
--		return;
--	retval = ext2fs_new_inode(current_fs, cwd, 010755, 0, &newfile);
--	if (retval) {
-+
-+	st.st_rdev = makedev(major, minor);
-+	if ((retval = do_mknod_internal(cwd, argv[1], &st)))
- 		com_err(argv[0], retval, 0);
--		return;
--	}
--	printf("Allocated inode: %u\n", newfile);
--	retval = ext2fs_link(current_fs, cwd, argv[1], newfile, filetype);
--	if (retval == EXT2_ET_DIR_NO_SPACE) {
--		retval = ext2fs_expand_dir(current_fs, cwd);
--		if (retval) {
--			com_err(argv[0], retval, "while expanding directory");
--			return;
--		}
--		retval = ext2fs_link(current_fs, cwd, argv[1], newfile,
--				     filetype);
--	}
--	if (retval) {
--		com_err(argv[1], retval, 0);
--		return;
--	}
--        if (ext2fs_test_inode_bitmap2(current_fs->inode_map,newfile))
--		com_err(argv[0], 0, "Warning: inode already set");
--	ext2fs_inode_alloc_stats2(current_fs, newfile, +1, 0);
--	memset(&inode, 0, sizeof(inode));
--	inode.i_mode = mode;
--	inode.i_atime = inode.i_ctime = inode.i_mtime =
--		current_fs->now ? current_fs->now : time(0);
--	if ((major < 256) && (minor < 256)) {
--		inode.i_block[0] = major*256+minor;
--		inode.i_block[1] = 0;
--	} else {
--		inode.i_block[0] = 0;
--		inode.i_block[1] = (minor & 0xff) | (major << 8) | ((minor & ~0xff) << 12);
--	}
--	inode.i_links_count = 1;
--	if (debugfs_write_new_inode(newfile, &inode, argv[0]))
--		return;
- }
- 
- void do_mkdir(int argc, char *argv[])
- {
--	char	*cp;
--	ext2_ino_t	parent;
--	char	*name;
- 	errcode_t retval;
- 
- 	if (common_args_process(argc, argv, 2, 2, "mkdir",
- 				"<filename>", CHECK_FS_RW))
- 		return;
- 
--	cp = strrchr(argv[1], '/');
--	if (cp) {
--		*cp = 0;
--		parent = string_to_inode(argv[1]);
--		if (!parent) {
--			com_err(argv[1], ENOENT, 0);
--			return;
--		}
--		name = cp+1;
--	} else {
--		parent = cwd;
--		name = argv[1];
--	}
--
--try_again:
--	retval = ext2fs_mkdir(current_fs, parent, 0, name);
--	if (retval == EXT2_ET_DIR_NO_SPACE) {
--		retval = ext2fs_expand_dir(current_fs, parent);
--		if (retval) {
--			com_err(argv[0], retval, "while expanding directory");
--			return;
--		}
--		goto try_again;
--	}
--	if (retval) {
--		com_err("ext2fs_mkdir", retval, 0);
--		return;
--	}
-+	if ((retval = do_mkdir_internal(cwd, argv[1], NULL)))
-+		com_err(argv[0], retval, 0);
- 
- }
- 
-@@ -2270,44 +2027,14 @@ void do_punch(int argc, char *argv[])
- 
- void do_symlink(int argc, char *argv[])
- {
--	char		*cp;
--	ext2_ino_t	parent;
--	char		*name, *target;
- 	errcode_t	retval;
- 
- 	if (common_args_process(argc, argv, 3, 3, "symlink",
- 				"<filename> <target>", CHECK_FS_RW))
- 		return;
- 
--	cp = strrchr(argv[1], '/');
--	if (cp) {
--		*cp = 0;
--		parent = string_to_inode(argv[1]);
--		if (!parent) {
--			com_err(argv[1], ENOENT, 0);
--			return;
--		}
--		name = cp+1;
--	} else {
--		parent = cwd;
--		name = argv[1];
--	}
--	target = argv[2];
--
--try_again:
--	retval = ext2fs_symlink(current_fs, parent, 0, name, target);
--	if (retval == EXT2_ET_DIR_NO_SPACE) {
--		retval = ext2fs_expand_dir(current_fs, parent);
--		if (retval) {
--			com_err(argv[0], retval, "while expanding directory");
--			return;
--		}
--		goto try_again;
--	}
--	if (retval) {
--		com_err("ext2fs_symlink", retval, 0);
--		return;
--	}
-+	if ((retval = do_symlink_internal(cwd, argv[1], argv[2])))
-+		com_err(argv[0], retval, 0);
- 
- }
- 
-diff --git a/debugfs/debugfs.h b/debugfs/debugfs.h
-index 6b4f6ef..2d464c1 100644
---- a/debugfs/debugfs.h
-+++ b/debugfs/debugfs.h
-@@ -5,6 +5,7 @@
- #include "ss/ss.h"
- #include "ext2fs/ext2_fs.h"
- #include "ext2fs/ext2fs.h"
-+#include "../misc/create_inode.h"
- 
- #ifdef __STDC__
- #define NOARGS void
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0011-mke2fs.8.in-update-the-manual-for-the-d-option.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0011-mke2fs.8.in-update-the-manual-for-the-d-option.patch
deleted file mode 100644
index ddd2cb8..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0011-mke2fs.8.in-update-the-manual-for-the-d-option.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 89fca439f1b58595f2f424598a27869f8c7bd815 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Mon, 23 Dec 2013 04:43:18 -0500
-Subject: [PATCH 11/11] mke2fs.8.in: update the manual for the -d option
-
-Update the manual for the -d option
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Reviewed-by: Darren Hart <dvhart@linux.intel.com>
----
- misc/mke2fs.8.in |    7 +++++++
- 1 file changed, 7 insertions(+)
-
-diff --git a/misc/mke2fs.8.in b/misc/mke2fs.8.in
-index fea50da..b1ca486 100644
---- a/misc/mke2fs.8.in
-+++ b/misc/mke2fs.8.in
-@@ -52,6 +52,10 @@ mke2fs \- create an ext2/ext3/ext4 filesystem
- .I number-of-inodes
- ]
- [
-+.B \-d
-+.I root-directory
-+]
-+[
- .B \-n
- ]
- [
-@@ -502,6 +506,9 @@ the
- ratio).  This allows the user to specify the number
- of desired inodes directly.
- .TP
-+.BI \-d " root-directory"
-+Add the files from the root-directory to the filesystem.
-+.TP
- .BI \-o " creator-os"
- Overrides the default value of the "creator operating system" field of the
- filesystem.  The creator field is set by default to the name of the OS the
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0012-Fix-musl-build-failures.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0012-Fix-musl-build-failures.patch
deleted file mode 100644
index 0b8008d..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/0012-Fix-musl-build-failures.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From c6ff7feb9038d6e8aaffe2e69b205ad5fa33df2f Mon Sep 17 00:00:00 2001
-From: Paul Barker <paul@paulbarker.me.uk>
-Date: Mon, 18 Aug 2014 21:02:56 +0200
-Subject: [PATCH] Fix musl build failures
-
-In lib/ext2fs/unix_io.c, __u64 should be used instead of __uint64_t. This type
-is guaranteed by the e2fsprogs build system.
-(795c02def3681a99cc792a5ebc162d06f8a1eeb7)
-
-In misc/create_inode.c, <limits.h> is needed for the definition of PATH_MAX.
-(bbccc6f3c6a106721fb6f1ef4df6bc32c7986235)
-
-Both of these fixes have been made upstream with the git commit IDs given but
-those are larger commits containing other changes not needed here.
-
-Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
-
-Upstream-Status: Backport
----
- lib/ext2fs/unix_io.c | 6 +++---
- misc/create_inode.c  | 1 +
- 2 files changed, 4 insertions(+), 3 deletions(-)
-
-diff --git a/lib/ext2fs/unix_io.c b/lib/ext2fs/unix_io.c
-index 19be630..0cc0f52 100644
---- a/lib/ext2fs/unix_io.c
-+++ b/lib/ext2fs/unix_io.c
-@@ -931,10 +931,10 @@ static errcode_t unix_discard(io_channel channel, unsigned long long block,
- 
- 	if (channel->flags & CHANNEL_FLAGS_BLOCK_DEVICE) {
- #ifdef BLKDISCARD
--		__uint64_t range[2];
-+		__u64 range[2];
- 
--		range[0] = (__uint64_t)(block) * channel->block_size;
--		range[1] = (__uint64_t)(count) * channel->block_size;
-+		range[0] = (__u64)(block) * channel->block_size;
-+		range[1] = (__u64)(count) * channel->block_size;
- 
- 		ret = ioctl(data->dev, BLKDISCARD, &range);
- #else
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-index 6d8de04..fcec5aa 100644
---- a/misc/create_inode.c
-+++ b/misc/create_inode.c
-@@ -1,4 +1,5 @@
- #include "create_inode.h"
-+#include <limits.h>
- 
- #if __STDC_VERSION__ < 199901L
- # if __GNUC__ >= 2
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/CVE-2015-0247.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/CVE-2015-0247.patch
deleted file mode 100644
index 4de67c9..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/CVE-2015-0247.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From f66e6ce4446738c2c7f43d41988a3eb73347e2f5 Mon Sep 17 00:00:00 2001
-From: Theodore Ts'o <tytso@mit.edu>
-Date: Sat, 9 Aug 2014 12:24:54 -0400
-Subject: libext2fs: avoid buffer overflow if s_first_meta_bg is too big
-
-If s_first_meta_bg is greater than the of number block group
-descriptor blocks, then reading or writing the block group descriptors
-will end up overruning the memory buffer allocated for the
-descriptors.  Fix this by limiting first_meta_bg to no more than
-fs->desc_blocks.  This doesn't correct the bad s_first_meta_bg value,
-but it avoids causing the e2fsprogs userspace programs from
-potentially crashing.
-
-Fixes CVE-2015-0247
-Upstream-Status: Backport
-
-Signed-off-by: Theodore Ts'o <tytso@mit.edu>
-Signed-off-by: Sona Sarmadi <sona.sarmadi@enea.com>
-
-diff --git a/lib/ext2fs/closefs.c b/lib/ext2fs/closefs.c
-index 4599eef..1f99113 100644
---- a/lib/ext2fs/closefs.c
-+++ b/lib/ext2fs/closefs.c
-@@ -344,9 +344,11 @@ errcode_t ext2fs_flush2(ext2_filsys fs, int flags)
- 	 * superblocks and group descriptors.
- 	 */
- 	group_ptr = (char *) group_shadow;
--	if (fs->super->s_feature_incompat & EXT2_FEATURE_INCOMPAT_META_BG)
-+	if (fs->super->s_feature_incompat & EXT2_FEATURE_INCOMPAT_META_BG) {
- 		old_desc_blocks = fs->super->s_first_meta_bg;
--	else
-+		if (old_desc_blocks > fs->super->s_first_meta_bg)
-+			old_desc_blocks = fs->desc_blocks;
-+	} else
- 		old_desc_blocks = fs->desc_blocks;
- 
- 	ext2fs_numeric_progress_init(fs, &progress, NULL,
-diff --git a/lib/ext2fs/openfs.c b/lib/ext2fs/openfs.c
-index a1a3517..ba501e6 100644
---- a/lib/ext2fs/openfs.c
-+++ b/lib/ext2fs/openfs.c
-@@ -378,9 +378,11 @@ errcode_t ext2fs_open2(const char *name, const char *io_options,
- #ifdef WORDS_BIGENDIAN
- 	groups_per_block = EXT2_DESC_PER_BLOCK(fs->super);
- #endif
--	if (fs->super->s_feature_incompat & EXT2_FEATURE_INCOMPAT_META_BG)
-+	if (fs->super->s_feature_incompat & EXT2_FEATURE_INCOMPAT_META_BG) {
- 		first_meta_bg = fs->super->s_first_meta_bg;
--	else
-+		if (first_meta_bg > fs->desc_blocks)
-+			first_meta_bg = fs->desc_blocks;
-+	} else
- 		first_meta_bg = fs->desc_blocks;
- 	if (first_meta_bg) {
- 		retval = io_channel_read_blk(fs->io, group_block +
--- 
-cgit v0.10.2
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch
new file mode 100644
index 0000000..656fb6e
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch
@@ -0,0 +1,34 @@
+From 0a392baf1874964651115d9f77b0daa6851d1daa Mon Sep 17 00:00:00 2001
+From: Jonathan Liu <net147@gmail.com>
+Date: Tue, 1 Mar 2016 14:28:01 +1100
+Subject: [PATCH] Revert "mke2fs: enable the metadata_csum and 64bit features
+ by default"
+
+This reverts commit cd27af3ecb83e8fd1e3eaa14994284a1818c7c15 as we
+don't want to enable features by default that are not supported by
+the latest stable e2fsprogs release.
+
+Upstream-Status: Inappropriate [configuration]
+
+Signed-off-by: Jonathan Liu <net147@gmail.com>
+---
+ misc/mke2fs.conf.in | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/misc/mke2fs.conf.in b/misc/mke2fs.conf.in
+index a049d61..106ee80 100644
+--- a/misc/mke2fs.conf.in
++++ b/misc/mke2fs.conf.in
+@@ -11,7 +11,8 @@
+ 		features = has_journal
+ 	}
+ 	ext4 = {
+-		features = has_journal,extent,huge_file,flex_bg,metadata_csum,64bit,dir_nlink,extra_isize
++		features = has_journal,extent,huge_file,flex_bg,uninit_bg,dir_nlink,extra_isize
++		auto_64-bit_support = 1
+ 		inode_size = 256
+ 	}
+ 	ext4dev = {
+-- 
+2.7.2
+
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/cache_inode.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/cache_inode.patch
deleted file mode 100644
index f9ef8e5..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/cache_inode.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-The comment to this function says:
-
-"""
-  * Stupid algorithm --- we now just search forward starting from the
-  * goal.  Should put in a smarter one someday....
-"""
-
-This adds in a rather hacky algorthim which starts where we finished
-searching previously using a static variable rather than starting 
-from scratch if a hint isn't provided.
-
-This was after noticing that mkfs.ext4 -F X -d Y was spending *lots*
-of time in ext2fs_new_block2 called from ext2fs_bmap from ext2fs_file_write().
-
-Numbers wise, this took a core-image-sato-sdk mkfs time from over 
-8 minutes to around 35 seconds.
-
-Upstream-Status: Pending
-
-RP 2015/02/20
-
-Index: e2fsprogs-1.42.9/lib/ext2fs/alloc.c
-===================================================================
---- e2fsprogs-1.42.9.orig/lib/ext2fs/alloc.c
-+++ e2fsprogs-1.42.9/lib/ext2fs/alloc.c
-@@ -160,6 +160,8 @@ errcode_t ext2fs_new_inode(ext2_filsys f
- 	return 0;
- }
- 
-+static blk64_t last_goal = 0;
-+
- /*
-  * Stupid algorithm --- we now just search forward starting from the
-  * goal.  Should put in a smarter one someday....
-@@ -170,6 +172,9 @@ errcode_t ext2fs_new_block2(ext2_filsys
- 	blk64_t	i;
- 	int	c_ratio;
- 
-+        if (!goal)
-+            goal = last_goal;
-+
- 	EXT2_CHECK_MAGIC(fs, EXT2_ET_MAGIC_EXT2FS_FILSYS);
- 
- 	if (!map)
-@@ -194,6 +199,7 @@ errcode_t ext2fs_new_block2(ext2_filsys
- 
- 		if (!ext2fs_fast_test_block_bitmap2(map, i)) {
- 			*ret = i;
-+			last_goal = i;
- 			return 0;
- 		}
- 		i = (i + c_ratio) & ~(c_ratio - 1);
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/copy-in-create-hardlinks-with-the-correct-directory-.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/copy-in-create-hardlinks-with-the-correct-directory-.patch
deleted file mode 100644
index f549693..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/copy-in-create-hardlinks-with-the-correct-directory-.patch
+++ /dev/null
@@ -1,81 +0,0 @@
-From 2dcf8e92bc39e05b3c799f53fe911c024aee4375 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Fri, 23 Oct 2015 03:21:05 -0700
-Subject: [PATCH] copy-in: create hardlinks with the correct directory
- filetype
-
-When we're creating hard links via ext2fs_link, the (misnamed?) flags
-argument specifies the filetype for the directory entry.  This is
-*derived* from i_mode, so provide a translator.  Otherwise, fsck will
-complain about unset file types.
-
-Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
-Signed-off-by: Theodore Ts'o <tytso@mit.edu>
-
-Upstream-Status: Backport
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- misc/create_inode.c |   33 +++++++++++++++++++++++++++++++--
- 1 file changed, 31 insertions(+), 2 deletions(-)
-
-diff --git a/misc/create_inode.c b/misc/create_inode.c
-index fcec5aa..b8565da 100644
---- a/misc/create_inode.c
-+++ b/misc/create_inode.c
-@@ -22,6 +22,33 @@
- /* For saving the hard links */
- int hdlink_cnt = HDLINK_CNT;
- 
-+static int ext2_file_type(unsigned int mode)
-+{
-+	if (LINUX_S_ISREG(mode))
-+		return EXT2_FT_REG_FILE;
-+
-+	if (LINUX_S_ISDIR(mode))
-+		return EXT2_FT_DIR;
-+
-+	if (LINUX_S_ISCHR(mode))
-+		return EXT2_FT_CHRDEV;
-+
-+	if (LINUX_S_ISBLK(mode))
-+		return EXT2_FT_BLKDEV;
-+
-+	if (LINUX_S_ISLNK(mode))
-+		return EXT2_FT_SYMLINK;
-+
-+	if (LINUX_S_ISFIFO(mode))
-+		return EXT2_FT_FIFO;
-+
-+	if (LINUX_S_ISSOCK(mode))
-+		return EXT2_FT_SOCK;
-+
-+	return 0;
-+}
-+
-+
- /* Link an inode number to a directory */
- static errcode_t add_link(ext2_ino_t parent_ino, ext2_ino_t ino, const char *name)
- {
-@@ -34,14 +61,16 @@ static errcode_t add_link(ext2_ino_t parent_ino, ext2_ino_t ino, const char *nam
- 		return retval;
- 	}
- 
--	retval = ext2fs_link(current_fs, parent_ino, name, ino, inode.i_flags);
-+	retval = ext2fs_link(current_fs, parent_ino, name, ino,
-+	             ext2_file_type(inode.i_mode));
- 	if (retval == EXT2_ET_DIR_NO_SPACE) {
- 		retval = ext2fs_expand_dir(current_fs, parent_ino);
- 		if (retval) {
- 			com_err(__func__, retval, "while expanding directory");
- 			return retval;
- 		}
--		retval = ext2fs_link(current_fs, parent_ino, name, ino, inode.i_flags);
-+		retval = ext2fs_link(current_fs, parent_ino, name, ino,
-+	                     ext2_file_type(inode.i_mode));
- 	}
- 	if (retval) {
- 		com_err(__func__, retval, "while linking %s", name);
--- 
-1.7.9.5
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/fix-icache.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/fix-icache.patch
deleted file mode 100644
index d38cc4d..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/fix-icache.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-inode.c: only update the icache for ext2_inode
-
-We only read the cache when:
-
-bufsize == sizeof(struct ext2_inode)
-
-then we should only update the cache in the same condition, otherwise
-there would be errors, for example:
-
-cache[0]: cached ino 14 when bufsize = 128 by ext2fs_write_inode_full()
-cache[1]: cached ino 14 when bufsize = 156 by ext2fs_read_inode_full()
-
-Then update the cache:
-cache[0]: cached ino 15 when bufsize = 156 by ext2fs_read_inode_full()
-
-Then the ino 14 would hit the cache[1] when bufsize = 128 (but it was
-cached by bufsize = 156), so there would be errors.
-
-Upstream-Status: Submitted
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- lib/ext2fs/inode.c | 20 ++++++++++++--------
- 1 file changed, 12 insertions(+), 8 deletions(-)
-
-diff --git a/lib/ext2fs/inode.c b/lib/ext2fs/inode.c
---- a/lib/ext2fs/inode.c
-+++ b/lib/ext2fs/inode.c
-@@ -612,10 +612,12 @@ errcode_t ext2fs_read_inode_full(ext2_filsys fs, ext2_ino_t ino,
- #endif
- 
- 	/* Update the inode cache */
--	fs->icache->cache_last = (fs->icache->cache_last + 1) %
--		fs->icache->cache_size;
--	fs->icache->cache[fs->icache->cache_last].ino = ino;
--	fs->icache->cache[fs->icache->cache_last].inode = *inode;
-+	if (bufsize == sizeof(struct ext2_inode)) {
-+		fs->icache->cache_last = (fs->icache->cache_last + 1) %
-+			fs->icache->cache_size;
-+		fs->icache->cache[fs->icache->cache_last].ino = ino;
-+		fs->icache->cache[fs->icache->cache_last].inode = *inode;
-+	}
- 
- 	return 0;
- }
-@@ -648,10 +650,12 @@ errcode_t ext2fs_write_inode_full(ext2_filsys fs, ext2_ino_t ino,
- 
- 	/* Check to see if the inode cache needs to be updated */
- 	if (fs->icache) {
--		for (i=0; i < fs->icache->cache_size; i++) {
--			if (fs->icache->cache[i].ino == ino) {
--				fs->icache->cache[i].inode = *inode;
--				break;
-+		if (bufsize == sizeof(struct ext2_inode)) {
-+			for (i=0; i < fs->icache->cache_size; i++) {
-+				if (fs->icache->cache[i].ino == ino) {
-+					fs->icache->cache[i].inode = *inode;
-+					break;
-+				}
- 			}
- 		}
- 	} else {
--- 
-1.8.1.2
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/misc-mke2fs.c-return-error-when-failed-to-populate-fs.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/misc-mke2fs.c-return-error-when-failed-to-populate-fs.patch
deleted file mode 100644
index cba0ce0..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/misc-mke2fs.c-return-error-when-failed-to-populate-fs.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From e4ffd6fe975888d306b5f700ba54af18b59f6759 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Thu, 20 Mar 2014 11:10:21 +0800
-Subject: [PATCH] misc/mke2fs.c: return error when failed to populate filesystem
-
-We need return retval when "mke2fs -d" failed, otherwise the "$?" would
-be 0 which is misleading.
-
-Upstream-Status: Submitted
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- misc/mke2fs.c | 7 ++++---
- 1 file changed, 4 insertions(+), 3 deletions(-)
-
-diff --git a/misc/mke2fs.c b/misc/mke2fs.c
-index a63f0b7..846190e 100644
---- a/misc/mke2fs.c
-+++ b/misc/mke2fs.c
-@@ -2745,10 +2745,11 @@ no_journal:
- 		current_fs = fs;
- 		root = EXT2_ROOT_INO;
- 		retval = populate_fs(root, root_dir);
--		if (retval)
-+		if (retval) {
- 			fprintf(stderr, "%s",
--				_("\nError while populating file system"));
--		else if (!quiet)
-+				_("\nError while populating file system\n"));
-+			return retval;
-+		} else if (!quiet)
- 			printf("%s", _("done\n"));
- 	}
- 
--- 
-1.8.3.1
-
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/mkdir.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/mkdir.patch
index aa7a298..2a3aeff 100644
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/mkdir.patch
+++ b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/mkdir.patch
@@ -2,29 +2,17 @@
 
 Signed-off-by: Mei Lei <lei.mei@intel.com>
 
-Index: e2fsprogs-1.41.5/po/Makefile.in.in
-===================================================================
---- e2fsprogs-1.41.5.orig/po/Makefile.in.in	2009-02-14 13:49:08.000000000 +0000
-+++ e2fsprogs-1.41.5/po/Makefile.in.in	2009-08-19 17:52:31.000000000 +0100
-@@ -30,7 +30,7 @@
- INSTALL = @INSTALL@
- INSTALL_DATA = @INSTALL_DATA@
- MKINSTALLDIRS = @MKINSTALLDIRS@
--mkinstalldirs = $(SHELL) $(MKINSTALLDIRS)
-+mkinstalldirs = $(MKINSTALLDIRS)
- 
- GMSGFMT = @GMSGFMT@
- MSGFMT = @MSGFMT@
-Index: e2fsprogs-1.41.5/configure.in
-===================================================================
---- e2fsprogs-1.41.5.orig/configure.in	2009-08-19 17:53:50.000000000 +0100
-+++ e2fsprogs-1.41.5/configure.in	2009-08-19 17:48:38.000000000 +0100
-@@ -970,6 +970,8 @@
+diff --git a/configure.ac b/configure.ac
+index c1fe224..f5ac628 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1374,7 +1374,8 @@ if test -n "$WITH_DIET_LIBC" ; then
+ 	INCLUDES="$INCLUDES -D_REENTRANT"
  fi
- AC_SUBST(BUILD_CFLAGS)
- AC_SUBST(BUILD_LDFLAGS)
+ AC_SUBST(INCLUDES)
+-AM_MKINSTALLDIRS
 +MKINSTALLDIRS="mkdir -p"
 +AC_SUBST(MKINSTALLDIRS)
  dnl
- dnl Make our output files, being sure that we create the some miscellaneous 
- dnl directories
+ dnl Build CFLAGS
+ dnl
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/ptest.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/ptest.patch
index b8a53e9..ef1ce58 100644
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/ptest.patch
+++ b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/ptest.patch
@@ -1,17 +1,17 @@
-Index: e2fsprogs-1.42.9/tests/Makefile.in
-===================================================================
---- e2fsprogs-1.42.9.orig/tests/Makefile.in
-+++ e2fsprogs-1.42.9/tests/Makefile.in
-@@ -18,7 +18,7 @@ test_one: $(srcdir)/test_one.in Makefile
+diff --git a/tests/Makefile.in b/tests/Makefile.in
+index 60cf655..ce220f1 100644
+--- a/tests/Makefile.in
++++ b/tests/Makefile.in
+@@ -18,7 +18,7 @@ test_one: $(srcdir)/test_one.in Makefile mke2fs.conf
  	@echo "#!/bin/sh" > test_one
- @HTREE_CMT@	@echo "HTREE=y" >> test_one
- @QUOTA_CMT@	@echo "QUOTA=y" >> test_one
+ 	@echo "HTREE=y" >> test_one
+ 	@echo "QUOTA=y" >> test_one
 -	@echo "SRCDIR=@srcdir@" >> test_one
 +	@echo "SRCDIR=/usr/lib/e2fsprogs/ptest/test" >> test_one
  	@echo "DIFF_OPTS=@UNI_DIFF_OPTS@" >> test_one
  	@cat $(srcdir)/test_one.in >> test_one
  	@chmod +x test_one
-@@ -26,7 +26,7 @@ test_one: $(srcdir)/test_one.in Makefile
+@@ -26,7 +26,7 @@ test_one: $(srcdir)/test_one.in Makefile mke2fs.conf
  test_script: test_one test_script.in Makefile mke2fs.conf
  	@echo "Creating test_script..."
  	@echo "#!/bin/sh" > test_script
@@ -20,11 +20,11 @@
  	@cat $(srcdir)/test_script.in >> test_script
  	@chmod +x test_script
  
-Index: e2fsprogs-1.42.9/tests/test_config
-===================================================================
---- e2fsprogs-1.42.9.orig/tests/test_config
-+++ e2fsprogs-1.42.9/tests/test_config
-@@ -3,23 +3,23 @@
+diff --git a/tests/test_config b/tests/test_config
+index 7f39157..c815a44 100644
+--- a/tests/test_config
++++ b/tests/test_config
+@@ -3,24 +3,24 @@
  #
  
  unset LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER LC_TELEPHONE LC_TIME PAGER
@@ -54,13 +54,14 @@
 +RESIZE2FS_EXE="/sbin/resize2fs"
  RESIZE2FS="$USE_VALGRIND $RESIZE2FS_EXE"
 -E2UNDO_EXE="../misc/e2undo"
++E2UNDO_EXE="/sbin/e2undo"
+ E2UNDO="$USE_VALGRIND $E2UNDO_EXE"
 -TEST_REL=../tests/progs/test_rel
 -TEST_ICOUNT=../tests/progs/test_icount
 -CRCSUM=../tests/progs/crcsum
-+E2UNDO_EXE="/sbin/e2undo"
 +TEST_REL=./progs/test_rel
 +TEST_ICOUNT=./progs/test_icount
 +CRCSUM=./progs/crcsum
- LD_LIBRARY_PATH=../lib:../lib/ext2fs:../lib/e2p:../lib/et:../lib/ss
- DYLD_LIBRARY_PATH=../lib:../lib/ext2fs:../lib/e2p:../lib/et:../lib/ss
- export LD_LIBRARY_PATH
+ CLEAN_OUTPUT="sed -f $cmd_dir/filter.sed"
+ LD_LIBRARY_PATH=../lib:../lib/ext2fs:../lib/e2p:../lib/et:../lib/ss:${LD_LIBRARY_PATH}
+ DYLD_LIBRARY_PATH=../lib:../lib/ext2fs:../lib/e2p:../lib/et:../lib/ss:${DYLD_LIBRARY_PATH}
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/xattr_ordering.patch b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/xattr_ordering.patch
new file mode 100644
index 0000000..782a7b1
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs/xattr_ordering.patch
@@ -0,0 +1,219 @@
+From: "Darrick J. Wong" <darrick.wong@oracle.com>
+To: tytso@mit.edu, darrick.wong@oracle.com
+Cc: linux-ext4@vger.kernel.org, Darren Hart <dvhart@linux.intel.com>,
+ Richard Purdie <richard.purdie@linuxfoundation.org>
+Date: Sat, 13 Feb 2016 14:38:24 -0800
+Message-ID: <20160213223824.25381.8002.stgit@birch.djwong.org>
+In-Reply-To: <20160213223725.25381.20929.stgit@birch.djwong.org>
+References: <20160213223725.25381.20929.stgit@birch.djwong.org>
+User-Agent: StGit/0.17.1-dirty
+MIME-Version: 1.0
+Content-Type: text/plain; charset="utf-8"
+X-Source-IP: aserv0022.oracle.com [141.146.126.234]
+X-Evolution-Source: 1358860361.4566.33@ted
+Content-Transfer-Encoding: 8bit
+
+Richard Purdie reports that libext2fs doesn't sort attribute keys in
+the xattr block correctly, causing the kernel to return -ENODATA when
+querying attributes that should be there.  Therefore, sort attributes
+so that whatever ends up in the xattr block is sorted according to
+what the kernel expects.
+
+Cc: Darren Hart <dvhart@linux.intel.com>
+Reported-by: Richard Purdie <richard.purdie@linuxfoundation.org>
+Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
+---
+ lib/ext2fs/ext_attr.c        |   24 +++++++++++-
+ tests/d_xattr_sorting/expect |   29 ++++++++++++++
+ tests/d_xattr_sorting/name   |    1 
+ tests/d_xattr_sorting/script |   86 ++++++++++++++++++++++++++++++++++++++++++
+ 4 files changed, 139 insertions(+), 1 deletion(-)
+ create mode 100644 tests/d_xattr_sorting/expect
+ create mode 100644 tests/d_xattr_sorting/name
+ create mode 100644 tests/d_xattr_sorting/script
+
+Upstream-Status: Submitted
+
+
+diff --git a/lib/ext2fs/ext_attr.c b/lib/ext2fs/ext_attr.c
+index 0a4f8c0..b121837 100644
+--- a/lib/ext2fs/ext_attr.c
++++ b/lib/ext2fs/ext_attr.c
+@@ -254,10 +254,15 @@ static struct ea_name_index ea_names[] = {
+ 	{0, NULL},
+ };
+ 
++static int find_ea_index(char *fullname, char **name, int *index);
++
+ /* Push empty attributes to the end and inlinedata to the front. */
+ static int attr_compare(const void *a, const void *b)
+ {
+ 	const struct ext2_xattr *xa = a, *xb = b;
++	char *xa_suffix, *xb_suffix;
++	int xa_idx, xb_idx;
++	int cmp;
+ 
+ 	if (xa->name == NULL)
+ 		return +1;
+@@ -267,7 +272,24 @@ static int attr_compare(const void *a, const void *b)
+ 		return -1;
+ 	else if (!strcmp(xb->name, "system.data"))
+ 		return +1;
+-	return 0;
++
++	/*
++	 * Duplicate the kernel's sorting algorithm because xattr blocks
++	 * require sorted keys.
++	 */
++	xa_suffix = xa->name;
++	xb_suffix = xb->name;
++	xa_idx = xb_idx = 0;
++	find_ea_index(xa->name, &xa_suffix, &xa_idx);
++	find_ea_index(xb->name, &xb_suffix, &xb_idx);
++	cmp = xa_idx - xb_idx;
++	if (cmp)
++		return cmp;
++	cmp = strlen(xa_suffix) - strlen(xb_suffix);
++	if (cmp)
++		return cmp;
++	cmp = strcmp(xa_suffix, xb_suffix);
++	return cmp;
+ }
+ 
+ static const char *find_ea_prefix(int index)
+diff --git a/tests/d_xattr_sorting/expect b/tests/d_xattr_sorting/expect
+new file mode 100644
+index 0000000..17da663
+--- /dev/null
++++ b/tests/d_xattr_sorting/expect
+@@ -0,0 +1,29 @@
++debugfs sort extended attributes
++mke2fs -Fq -b 1024 test.img 512
++Exit status is 0
++ea_set / security.SMEG64 -f /tmp/b
++Exit status is 0
++ea_set / security.imb -f /tmp/b
++Exit status is 0
++ea_set / user.moo cow
++Exit status is 0
++ea_list /
++Extended attributes:
++  user.moo = "cow" (3)
++  security.imb = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" (256)
++  security.SMEG64 = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" (256)
++Exit status is 0
++ea_get / security.imb
++xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
++Exit status is 0
++ea_get / nosuchea
++ea_get: Extended attribute key not found while getting extended attribute
++Exit status is 0
++e2fsck -yf -N test_filesys
++Pass 1: Checking inodes, blocks, and sizes
++Pass 2: Checking directory structure
++Pass 3: Checking directory connectivity
++Pass 4: Checking reference counts
++Pass 5: Checking group summary information
++test_filesys: 11/64 files (0.0% non-contiguous), 29/512 blocks
++Exit status is 0
+diff --git a/tests/d_xattr_sorting/name b/tests/d_xattr_sorting/name
+new file mode 100644
+index 0000000..dde8926
+--- /dev/null
++++ b/tests/d_xattr_sorting/name
+@@ -0,0 +1 @@
++sort extended attributes in debugfs
+diff --git a/tests/d_xattr_sorting/script b/tests/d_xattr_sorting/script
+new file mode 100644
+index 0000000..30c189a
+--- /dev/null
++++ b/tests/d_xattr_sorting/script
+@@ -0,0 +1,86 @@
++if test -x $DEBUGFS_EXE; then
++
++OUT=$test_name.log
++EXP=$test_dir/expect
++VERIFY_FSCK_OPT=-yf
++
++TEST_DATA=$test_name.tmp
++VERIFY_DATA=$test_name.ver.tmp
++
++echo "debugfs sort extended attributes" > $OUT
++
++dd if=/dev/zero of=$TMPFILE bs=1k count=512 > /dev/null 2>&1
++
++echo "mke2fs -Fq -b 1024 test.img 512" >> $OUT
++
++$MKE2FS -Fq $TMPFILE 512 > /dev/null 2>&1
++status=$?
++echo Exit status is $status >> $OUT
++
++perl -e 'print "x" x 256;' > /tmp/b
++
++echo "ea_set / security.SMEG64 -f /tmp/b" > $OUT.new
++$DEBUGFS -w -R "ea_set / security.SMEG64 -f /tmp/b" $TMPFILE >> $OUT.new 2>&1
++status=$?
++echo Exit status is $status >> $OUT.new
++sed -f $cmd_dir/filter.sed $OUT.new >> $OUT
++
++echo "ea_set / security.imb -f /tmp/b" > $OUT.new
++$DEBUGFS -w -R "ea_set / security.imb -f /tmp/b" $TMPFILE >> $OUT.new 2>&1
++status=$?
++echo Exit status is $status >> $OUT.new
++sed -f $cmd_dir/filter.sed $OUT.new >> $OUT
++
++echo "ea_set / user.moo cow" > $OUT.new
++$DEBUGFS -w -R "ea_set / user.moo cow" $TMPFILE >> $OUT.new 2>&1
++status=$?
++echo Exit status is $status >> $OUT.new
++sed -f $cmd_dir/filter.sed $OUT.new >> $OUT
++
++rm -rf /tmp/b
++
++echo "ea_list /" > $OUT.new
++$DEBUGFS -w -R "ea_list /" $TMPFILE >> $OUT.new 2>&1
++status=$?
++echo Exit status is $status >> $OUT.new
++sed -f $cmd_dir/filter.sed $OUT.new >> $OUT
++
++echo "ea_get / security.imb" > $OUT.new
++$DEBUGFS -w -R "ea_get / security.imb" $TMPFILE >> $OUT.new 2>&1
++status=$?
++echo Exit status is $status >> $OUT.new
++sed -f $cmd_dir/filter.sed $OUT.new >> $OUT
++
++echo "ea_get / nosuchea" > $OUT.new
++$DEBUGFS -w -R "ea_get / nosuchea" $TMPFILE >> $OUT.new 2>&1
++status=$?
++echo Exit status is $status >> $OUT.new
++sed -f $cmd_dir/filter.sed $OUT.new >> $OUT
++
++echo e2fsck $VERIFY_FSCK_OPT -N test_filesys > $OUT.new
++$FSCK $VERIFY_FSCK_OPT -N test_filesys $TMPFILE >> $OUT.new 2>&1
++status=$?
++echo Exit status is $status >> $OUT.new
++sed -f $cmd_dir/filter.sed $OUT.new >> $OUT
++
++#
++# Do the verification
++#
++
++rm -f $TMPFILE $OUT.new
++cmp -s $OUT $EXP
++status=$?
++
++if [ "$status" = 0 ] ; then
++	echo "$test_name: $test_description: ok"
++	touch $test_name.ok
++else
++	echo "$test_name: $test_description: failed"
++	diff $DIFF_OPTS $EXP $OUT > $test_name.failed
++fi
++
++unset VERIFY_FSCK_OPT NATIVE_FSCK_OPT OUT EXP TEST_DATA VERIFY_DATA
++
++else #if test -x $DEBUGFS_EXE; then
++	echo "$test_name: $test_description: skipped"
++fi
+
+
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.9.bb b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.9.bb
deleted file mode 100644
index a8edeef..0000000
--- a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.9.bb
+++ /dev/null
@@ -1,132 +0,0 @@
-require e2fsprogs.inc
-
-RECIPE_NO_UPDATE_REASON = "Updating backported patches to 1.42.13 is too much pain. Let's wait until 1.43 is released."
-
-SRC_URI += "file://acinclude.m4 \
-            file://remove.ldconfig.call.patch \
-            file://fix-icache.patch \
-            file://quiet-debugfs.patch \
-            file://0001-mke2fs-add-the-ability-to-copy-files-from-a-given-di.patch \
-            file://0002-misc-create_inode.c-copy-files-recursively.patch \
-            file://0003-misc-create_inode.c-create-special-file.patch \
-            file://0004-misc-create_inode.c-create-symlink.patch \
-            file://0005-misc-create_inode.c-copy-regular-file.patch \
-            file://0006-misc-create_inode.c-create-directory.patch \
-            file://0007-misc-create_inode.c-set-owner-mode-time-for-the-inod.patch \
-            file://0008-mke2fs.c-add-an-option-d-root-directory.patch \
-            file://0009-misc-create_inode.c-handle-hardlinks.patch \
-            file://0010-debugfs-use-the-functions-in-misc-create_inode.c.patch \
-            file://0011-mke2fs.8.in-update-the-manual-for-the-d-option.patch \
-            file://0012-Fix-musl-build-failures.patch \
-            file://0001-e2fsprogs-fix-cross-compilation-problem.patch \
-            file://misc-mke2fs.c-return-error-when-failed-to-populate-fs.patch \
-            file://cache_inode.patch \
-            file://CVE-2015-0247.patch \
-            file://0001-libext2fs-fix-potential-buffer-overflow-in-closefs.patch \
-            file://copy-in-create-hardlinks-with-the-correct-directory-.patch \
-"
-
-SRC_URI[md5sum] = "3f8e41e63b432ba114b33f58674563f7"
-SRC_URI[sha256sum] = "2f92ac06e92fa00f2ada3ee67dad012d74d685537527ad1241d82f2d041f2802"
-
-EXTRA_OECONF += "--libdir=${base_libdir} --sbindir=${base_sbindir} --enable-elf-shlibs --disable-libuuid --disable-uuidd --enable-verbose-makecmds"
-EXTRA_OECONF_darwin = "--libdir=${base_libdir} --sbindir=${base_sbindir} --enable-bsd-shlibs"
-
-do_configure_prepend () {
-	cp ${WORKDIR}/acinclude.m4 ${S}/
-}
-
-do_install () {
-	oe_runmake 'DESTDIR=${D}' install
-	oe_runmake 'DESTDIR=${D}' install-libs
-	# We use blkid from util-linux now so remove from here
-	rm -f ${D}${base_libdir}/libblkid*
-	rm -rf ${D}${includedir}/blkid
-	rm -f ${D}${base_libdir}/pkgconfig/blkid.pc
-	rm -f ${D}${base_sbindir}/blkid
-	rm -f ${D}${base_sbindir}/fsck
-	rm -f ${D}${base_sbindir}/findfs
-
-	# e2initrd_helper and the pkgconfig files belong in libdir
-	if [ ! ${D}${libdir} -ef ${D}${base_libdir} ]; then
-		install -d ${D}${libdir}
-		mv ${D}${base_libdir}/e2initrd_helper ${D}${libdir}
-		mv ${D}${base_libdir}/pkgconfig ${D}${libdir}
-	fi
-
-	oe_multilib_header ext2fs/ext2_types.h
-	install -d ${D}${base_bindir}
-	mv ${D}${bindir}/chattr ${D}${base_bindir}/chattr.e2fsprogs
-
-	install -v -m 755 ${S}/contrib/populate-extfs.sh ${D}${base_sbindir}/
-}
-
-# Need to find the right mke2fs.conf file
-e2fsprogs_conf_fixup () {
-	for i in mke2fs mkfs.ext2 mkfs.ext3 mkfs.ext4 mkfs.ext4dev; do
-		create_wrapper ${D}${base_sbindir}/$i MKE2FS_CONFIG=${sysconfdir}/mke2fs.conf
-	done
-}
-
-do_install_append_class-target() {
-	# Clean host path in compile_et, mk_cmds
-	sed -i -e "s,ET_DIR=\"${S}/lib/et\",ET_DIR=\"${datadir}/et\",g" ${D}${bindir}/compile_et
-	sed -i -e "s,SS_DIR=\"${S}/lib/ss\",SS_DIR=\"${datadir}/ss\",g" ${D}${bindir}/mk_cmds
-}
-
-do_install_append_class-native() {
-	e2fsprogs_conf_fixup
-}
-
-do_install_append_class-nativesdk() {
-	e2fsprogs_conf_fixup
-}
-
-RDEPENDS_e2fsprogs = "e2fsprogs-badblocks"
-RRECOMMENDS_e2fsprogs = "e2fsprogs-mke2fs e2fsprogs-e2fsck"
-
-PACKAGES =+ "e2fsprogs-e2fsck e2fsprogs-mke2fs e2fsprogs-tune2fs e2fsprogs-badblocks e2fsprogs-resize2fs"
-PACKAGES =+ "libcomerr libss libe2p libext2fs"
-
-FILES_e2fsprogs-resize2fs = "${base_sbindir}/resize2fs*"
-FILES_e2fsprogs-e2fsck = "${base_sbindir}/e2fsck ${base_sbindir}/fsck.ext*"
-FILES_e2fsprogs-mke2fs = "${base_sbindir}/mke2fs ${base_sbindir}/mkfs.ext* ${sysconfdir}/mke2fs.conf"
-FILES_e2fsprogs-tune2fs = "${base_sbindir}/tune2fs ${base_sbindir}/e2label"
-FILES_e2fsprogs-badblocks = "${base_sbindir}/badblocks"
-FILES_libcomerr = "${base_libdir}/libcom_err.so.*"
-FILES_libss = "${base_libdir}/libss.so.*"
-FILES_libe2p = "${base_libdir}/libe2p.so.*"
-FILES_libext2fs = "${libdir}/e2initrd_helper ${base_libdir}/libext2fs.so.*"
-FILES_${PN}-dev += "${datadir}/*/*.awk ${datadir}/*/*.sed ${base_libdir}/*.so"
-
-BBCLASSEXTEND = "native nativesdk"
-
-inherit update-alternatives
-
-ALTERNATIVE_${PN} = "chattr"
-ALTERNATIVE_PRIORITY = "100"
-ALTERNATIVE_LINK_NAME[chattr] = "${base_bindir}/chattr"
-ALTERNATIVE_TARGET[chattr] = "${base_bindir}/chattr.e2fsprogs"
-
-ALTERNATIVE_${PN}-doc = "libblkid.3 blkid.8 findfs.8 fsck.8"
-ALTERNATIVE_LINK_NAME[libblkid.3] = "${mandir}/man3/libblkid.3"
-ALTERNATIVE_LINK_NAME[blkid.8] = "${mandir}/man8/blkid.8"
-ALTERNATIVE_LINK_NAME[findfs.8] = "${mandir}/man8/findfs.8"
-ALTERNATIVE_LINK_NAME[fsck.8] = "${mandir}/man8/fsck.8"
-
-inherit ptest
-SRC_URI += "file://run-ptest"
-SRC_URI += "file://ptest.patch"
-
-RDEPENDS_${PN}-ptest += "${PN} ${PN}-tune2fs coreutils procps"
-#RDEPENDS_${PN}-ptest += "expect"
-
-do_compile_ptest() {
-	oe_runmake -C ${B}/tests
-}
-
-do_install_ptest() {
-	cp -a ${B}/tests ${D}${PTEST_PATH}/test
-	cp -a ${S}/tests/* ${D}${PTEST_PATH}/test
-	sed -e 's!../e2fsck/e2fsck!e2fsck!g' -i ${D}${PTEST_PATH}/test/*/expect*
-}
diff --git a/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_git.bb b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_git.bb
new file mode 100644
index 0000000..9cde8e4
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/e2fsprogs/e2fsprogs_git.bb
@@ -0,0 +1,111 @@
+require e2fsprogs.inc
+
+SRC_URI += "file://acinclude.m4 \
+            file://remove.ldconfig.call.patch \
+            file://quiet-debugfs.patch \
+            file://run-ptest \
+            file://ptest.patch \
+            file://mkdir.patch \
+            file://xattr_ordering.patch \
+            file://Revert-mke2fs-enable-the-metadata_csum-and-64bit-fea.patch \
+"
+
+SRCREV = "0f26747167cc9d82df849b0aad387bf824f04544"
+PV = "1.42.99+1.43+git${SRCPV}"
+UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+\.\d+(\.\d+)*)$"
+
+EXTRA_OECONF += "--libdir=${base_libdir} --sbindir=${base_sbindir} \
+                --enable-elf-shlibs --disable-libuuid --disable-uuidd \
+                --disable-libblkid --enable-verbose-makecmds"
+
+EXTRA_OECONF_darwin = "--libdir=${base_libdir} --sbindir=${base_sbindir} --enable-bsd-shlibs"
+
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[fuse] = '--enable-fuse2fs,--disable-fuse2fs,fuse'
+
+do_configure_prepend () {
+	cp ${WORKDIR}/acinclude.m4 ${S}/
+}
+
+do_install () {
+	oe_runmake 'DESTDIR=${D}' install
+	oe_runmake 'DESTDIR=${D}' install-libs
+	# We use blkid from util-linux now so remove from here
+	rm -f ${D}${base_libdir}/libblkid*
+	rm -rf ${D}${includedir}/blkid
+	rm -f ${D}${base_libdir}/pkgconfig/blkid.pc
+	rm -f ${D}${base_sbindir}/blkid
+	rm -f ${D}${base_sbindir}/fsck
+	rm -f ${D}${base_sbindir}/findfs
+
+	# e2initrd_helper and the pkgconfig files belong in libdir
+	if [ ! ${D}${libdir} -ef ${D}${base_libdir} ]; then
+		install -d ${D}${libdir}
+		mv ${D}${base_libdir}/e2initrd_helper ${D}${libdir}
+		mv ${D}${base_libdir}/pkgconfig ${D}${libdir}
+	fi
+
+	oe_multilib_header ext2fs/ext2_types.h
+	install -d ${D}${base_bindir}
+	mv ${D}${bindir}/chattr ${D}${base_bindir}/chattr.e2fsprogs
+
+	install -v -m 755 ${S}/contrib/populate-extfs.sh ${D}${base_sbindir}/
+}
+
+# Need to find the right mke2fs.conf file
+e2fsprogs_conf_fixup () {
+	for i in mke2fs mkfs.ext2 mkfs.ext3 mkfs.ext4 mkfs.ext4dev; do
+		create_wrapper ${D}${base_sbindir}/$i MKE2FS_CONFIG=${sysconfdir}/mke2fs.conf
+	done
+}
+
+do_install_append_class-target() {
+	# Clean host path in compile_et, mk_cmds
+	sed -i -e "s,ET_DIR=\"${S}/lib/et\",ET_DIR=\"${datadir}/et\",g" ${D}${bindir}/compile_et
+	sed -i -e "s,SS_DIR=\"${S}/lib/ss\",SS_DIR=\"${datadir}/ss\",g" ${D}${bindir}/mk_cmds
+}
+
+do_install_append_class-native() {
+	e2fsprogs_conf_fixup
+}
+
+do_install_append_class-nativesdk() {
+	e2fsprogs_conf_fixup
+}
+
+RDEPENDS_e2fsprogs = "e2fsprogs-badblocks"
+RRECOMMENDS_e2fsprogs = "e2fsprogs-mke2fs e2fsprogs-e2fsck"
+
+PACKAGES =+ "e2fsprogs-e2fsck e2fsprogs-mke2fs e2fsprogs-tune2fs e2fsprogs-badblocks e2fsprogs-resize2fs"
+PACKAGES =+ "libcomerr libss libe2p libext2fs"
+
+FILES_e2fsprogs-resize2fs = "${base_sbindir}/resize2fs*"
+FILES_e2fsprogs-e2fsck = "${base_sbindir}/e2fsck ${base_sbindir}/fsck.ext*"
+FILES_e2fsprogs-mke2fs = "${base_sbindir}/mke2fs ${base_sbindir}/mkfs.ext* ${sysconfdir}/mke2fs.conf"
+FILES_e2fsprogs-tune2fs = "${base_sbindir}/tune2fs ${base_sbindir}/e2label"
+FILES_e2fsprogs-badblocks = "${base_sbindir}/badblocks"
+FILES_libcomerr = "${base_libdir}/libcom_err.so.*"
+FILES_libss = "${base_libdir}/libss.so.*"
+FILES_libe2p = "${base_libdir}/libe2p.so.*"
+FILES_libext2fs = "${libdir}/e2initrd_helper ${base_libdir}/libext2fs.so.*"
+FILES_${PN}-dev += "${datadir}/*/*.awk ${datadir}/*/*.sed ${base_libdir}/*.so"
+
+ALTERNATIVE_${PN} = "chattr"
+ALTERNATIVE_PRIORITY = "100"
+ALTERNATIVE_LINK_NAME[chattr] = "${base_bindir}/chattr"
+ALTERNATIVE_TARGET[chattr] = "${base_bindir}/chattr.e2fsprogs"
+
+ALTERNATIVE_${PN}-doc = "fsck.8"
+ALTERNATIVE_LINK_NAME[fsck.8] = "${mandir}/man8/fsck.8"
+
+RDEPENDS_${PN}-ptest += "${PN} ${PN}-tune2fs coreutils procps bash"
+
+do_compile_ptest() {
+	oe_runmake -C ${B}/tests
+}
+
+do_install_ptest() {
+	cp -a ${B}/tests ${D}${PTEST_PATH}/test
+	cp -a ${S}/tests/* ${D}${PTEST_PATH}/test
+	sed -e 's!../e2fsck/e2fsck!e2fsck!g' -i ${D}${PTEST_PATH}/test/*/expect*
+}
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.148/elf_begin.c-CVE-2014-9447-fix.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.148/elf_begin.c-CVE-2014-9447-fix.patch
index 84e8ddc..deba45f 100644
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.148/elf_begin.c-CVE-2014-9447-fix.patch
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.148/elf_begin.c-CVE-2014-9447-fix.patch
@@ -7,6 +7,7 @@
  https://git.fedorahosted.org/cgit/elfutils.git/commit/?id=147018e729e7c22eeabf15b82d26e4bf68a0d18e
 
 Upstream-Status: Backport
+CVE: CVE-2014-9447
 
 Signed-off-by: Li Xin <lixin.fnst@cn.fujitsu.com>
 ---
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/arm_func_value.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/arm_func_value.patch
deleted file mode 100644
index 2fe4df6..0000000
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/arm_func_value.patch
+++ /dev/null
@@ -1,165 +0,0 @@
-From: Mark Wielaard <mjw@redhat.com>
-Date: Sun, 15 Jun 2014 11:30:35 +0200
-Subject: libebl: Add sym_func_value hook.
-
-The ARM EABI says that the zero bit of function symbol st_value indicates
-whether the symbol points to a THUMB or ARM function. Add a new ebl hook
-to adjust the st_value in such a case so that we get the actual value that
-the symbol points to. It isn't easily possible to reuse the existing
-resolve_sym_value for this purpose, so we end up with another hook that
-can be used from dwfl_module_getsym and elflint.
-
-Rebase arm_func_value.patch from 0.159 to 0.160
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- backends/arm_init.c          |    1 +
- backends/arm_symbol.c        |    8 ++++++++
- libdwfl/dwfl_module_getsym.c |    2 +-
- libebl/Makefile.am           |    3 ++-
- libebl/ebl-hooks.h           |    3 +++
- libebl/eblsymfuncval.c       |   43 ++++++++++++++++++++++++++++++++++++++++++
- libebl/libebl.h              |   11 +++++++++++
- 7 files changed, 69 insertions(+), 2 deletions(-)
-
-diff --git a/backends/arm_init.c b/backends/arm_init.c
-index 7171186..9f03630 100644
---- a/backends/arm_init.c
-+++ b/backends/arm_init.c
-@@ -78,6 +78,7 @@ arm_init (elf, machine, eh, ehlen)
-     eh->return_value_location = arm_return_value_location_hard;
-   HOOK (eh, abi_cfi);
-   HOOK (eh, check_reloc_target_type);
-+  HOOK (eh, sym_func_value);
-   HOOK (eh, symbol_type_name);
- 
-   /* We only unwind the core integer registers.  */
-diff --git a/backends/arm_symbol.c b/backends/arm_symbol.c
-index da4a50a..ccea03b 100644
---- a/backends/arm_symbol.c
-+++ b/backends/arm_symbol.c
-@@ -130,6 +130,14 @@ arm_check_reloc_target_type (Ebl *ebl __attribute__ ((unused)), Elf64_Word sh_ty
-   return sh_type == SHT_ARM_EXIDX;
- }
- 
-+/* ARM EABI says that the low bit indicates whether the function
-+   symbol value is a THUMB function or not.  Mask it off.  */
-+GElf_Addr
-+arm_sym_func_value (Ebl *ebl __attribute__ ((unused)), GElf_Addr val)
-+{
-+  return val & ~(GElf_Addr)1;
-+}
-+
- const char *
- arm_symbol_type_name (int type,
- 		      char *buf __attribute__ ((unused)),
-diff --git a/libdwfl/dwfl_module_getsym.c b/libdwfl/dwfl_module_getsym.c
-index 42d2b67..fb192d7 100644
---- a/libdwfl/dwfl_module_getsym.c
-+++ b/libdwfl/dwfl_module_getsym.c
-@@ -119,7 +119,7 @@ __libdwfl_getsym (Dwfl_Module *mod, int ndx, GElf_Sym *sym, GElf_Addr *addr,
-      descriptors).  */
- 
-   char *ident;
--  GElf_Addr st_value = sym->st_value & ebl_func_addr_mask (mod->ebl);
-+  GElf_Addr st_value = ebl_sym_func_value (mod->ebl, sym->st_value);
-   *resolved = false;
-   if (! adjust_st_value && mod->e_type != ET_REL && alloc
-       && (GELF_ST_TYPE (sym->st_info) == STT_FUNC
-diff --git a/libebl/Makefile.am b/libebl/Makefile.am
-index ec4477b..889c21b 100644
---- a/libebl/Makefile.am
-+++ b/libebl/Makefile.am
-@@ -55,7 +55,8 @@ gen_SOURCES = eblopenbackend.c eblclosebackend.c eblstrtab.c \
- 	      eblsysvhashentrysize.c eblauxvinfo.c eblcheckobjattr.c \
- 	      ebl_check_special_section.c ebl_syscall_abi.c eblabicfi.c \
- 	      eblstother.c eblinitreg.c ebldwarftoregno.c eblnormalizepc.c \
--	      eblunwind.c eblresolvesym.c eblcheckreloctargettype.c
-+	      eblunwind.c eblresolvesym.c eblcheckreloctargettype.c \
-+	      eblsymfuncval.c
- 
- libebl_a_SOURCES = $(gen_SOURCES)
- 
-diff --git a/libebl/ebl-hooks.h b/libebl/ebl-hooks.h
-index 2e31446..9df945d 100644
---- a/libebl/ebl-hooks.h
-+++ b/libebl/ebl-hooks.h
-@@ -191,5 +191,8 @@ bool EBLHOOK(unwind) (Ebl *ebl, Dwarf_Addr pc, ebl_tid_registers_t *setfunc,
-    (e.g. function descriptor resolving)  */
- bool EBLHOOK(resolve_sym_value) (Ebl *ebl, GElf_Addr *addr);
- 
-+/* Returns the real value of a symbol function address or offset.  */
-+GElf_Addr EBLHOOK(sym_func_value) (Ebl *ebl, GElf_Addr val);
-+
- /* Destructor for ELF backend handle.  */
- void EBLHOOK(destr) (struct ebl *);
-diff --git a/libebl/eblsymfuncval.c b/libebl/eblsymfuncval.c
-new file mode 100644
-index 0000000..c0b322f
---- /dev/null
-+++ b/libebl/eblsymfuncval.c
-@@ -0,0 +1,43 @@
-+/* Turn a symbol function value into a real function address or offset.
-+   Copyright (C) 2014 Red Hat, Inc.
-+   This file is part of elfutils.
-+
-+   This file is free software; you can redistribute it and/or modify
-+   it under the terms of either
-+
-+     * the GNU Lesser General Public License as published by the Free
-+       Software Foundation; either version 3 of the License, or (at
-+       your option) any later version
-+
-+   or
-+
-+     * 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
-+
-+   or both in parallel, as here.
-+
-+   elfutils 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 copies of the GNU General Public License and
-+   the GNU Lesser General Public License along with this program.  If
-+   not, see <http://www.gnu.org/licenses/>.  */
-+
-+#ifdef HAVE_CONFIG_H
-+# include <config.h>
-+#endif
-+
-+#include <libeblP.h>
-+#include <assert.h>
-+
-+GElf_Addr
-+ebl_sym_func_value (Ebl *ebl, GElf_Addr val)
-+{
-+  if (ebl == NULL || ebl->sym_func_value == NULL)
-+    return val;
-+
-+  return ebl->sym_func_value (ebl, val);
-+}
-diff --git a/libebl/libebl.h b/libebl/libebl.h
-index 7dbf460..96c076b 100644
---- a/libebl/libebl.h
-+++ b/libebl/libebl.h
-@@ -472,6 +472,17 @@ extern bool ebl_unwind (Ebl *ebl, Dwarf_Addr pc, ebl_tid_registers_t *setfunc,
- extern bool ebl_resolve_sym_value (Ebl *ebl, GElf_Addr *addr)
-    __nonnull_attribute__ (2);
- 
-+/* Returns the real value of a symbol function address or offset
-+   (e.g. when the st_value contains some flag bits that need to be
-+   masked off).  This is different from ebl_resolve_sym_value which
-+   only works for actual symbol addresses (in non-ET_REL files) that
-+   might resolve to an address in a different section.
-+   ebl_sym_func_value is called to turn the given value into the a
-+   real address or offset (the original value might not be a real
-+   address).  This works for both ET_REL when the value is a section
-+   offset or ET_EXEC or ET_DYN symbol values, which are addresses.  */
-+extern GElf_Addr ebl_sym_func_value (Ebl *ebl, GElf_Addr val);
-+
- #ifdef __cplusplus
- }
- #endif
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/arm_unwind_ret_mask.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/arm_unwind_ret_mask.patch
deleted file mode 100644
index 8abb36b..0000000
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/arm_unwind_ret_mask.patch
+++ /dev/null
@@ -1,83 +0,0 @@
-From: Mark Wielaard <mjw@redhat.com>
-Date: Sun, 15 Jun 2014 12:30:02 +0200
-Subject: libebl: Add ebl_unwind_ret_mask.
-
-Another ARM oddity. A return value address in an unwind will contain an
-extra bit to indicate whether to return to a regular ARM or THUMB function.
-Add a new ebl function to return a mask to use to get the actual return
-address during an unwind ebl_unwind_ret_mask.
-
-Rebase arm_unwind_ret_mask.patch from 0.159 to 0.160
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- backends/arm_init.c | 3 +++
- libebl/eblinitreg.c | 8 ++++++++
- libebl/libebl.h     | 4 ++++
- libebl/libeblP.h    | 6 ++++++
- 4 files changed, 21 insertions(+)
-
-diff --git a/backends/arm_init.c b/backends/arm_init.c
-index 2266829..f8df042 100644
---- a/backends/arm_init.c
-+++ b/backends/arm_init.c
-@@ -87,5 +87,8 @@ arm_init (elf, machine, eh, ehlen)
-   /* Bit zero encodes whether an function address is THUMB or ARM. */
-   eh->func_addr_mask = ~(GElf_Addr)1;
- 
-+  /* Bit zero encodes whether to return to a THUMB or ARM function. */
-+  eh->unwind_ret_mask = ~(GElf_Addr)1;
-+
-   return MODVERSION;
- }
-diff --git a/libebl/eblinitreg.c b/libebl/eblinitreg.c
-index 5729b3c..ca681c0 100644
---- a/libebl/eblinitreg.c
-+++ b/libebl/eblinitreg.c
-@@ -56,3 +56,11 @@ ebl_func_addr_mask (Ebl *ebl)
-   return ((ebl == NULL || ebl->func_addr_mask == 0)
- 	  ? ~(GElf_Addr)0 : ebl->func_addr_mask);
- }
-+
-+GElf_Addr
-+ebl_unwind_ret_mask (Ebl *ebl)
-+{
-+  return ((ebl == NULL || ebl->unwind_ret_mask == 0)
-+	  ? ~(GElf_Addr)0 : ebl->unwind_ret_mask);
-+}
-+
-diff --git a/libebl/libebl.h b/libebl/libebl.h
-index 40cf635..be70027 100644
---- a/libebl/libebl.h
-+++ b/libebl/libebl.h
-@@ -420,6 +420,10 @@ extern size_t ebl_frame_nregs (Ebl *ebl)
-    tables) is needed.  */
- extern GElf_Addr ebl_func_addr_mask (Ebl *ebl);
- 
-+/* Mask to use for unwind return address in case the architecture adds
-+   some extra non-address bits to it.  */
-+extern GElf_Addr ebl_unwind_ret_mask (Ebl *ebl);
-+
- /* Convert *REGNO as is in DWARF to a lower range suitable for
-    Dwarf_Frame->REGS indexing.  */
- extern bool ebl_dwarf_to_regno (Ebl *ebl, unsigned *regno)
-diff --git a/libebl/libeblP.h b/libebl/libeblP.h
-index dbd67f3..e18ace6 100644
---- a/libebl/libeblP.h
-+++ b/libebl/libeblP.h
-@@ -70,6 +70,12 @@ struct ebl
-      otherwise it should be the actual mask to use.  */
-   GElf_Addr func_addr_mask;
- 
-+  /* Mask to use to get the return address from an unwind in case the
-+     architecture adds some extra non-address bits to it.  When not
-+     initialized (0) then ebl_unwind_ret_mask will return ~0, otherwise
-+     it should be the actual mask to use.  */
-+  GElf_Addr unwind_ret_mask;
-+
-   /* Function descriptor load address and table as used by
-      ebl_resolve_sym_value if available for this arch.  */
-   GElf_Addr fd_addr;
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/non_linux.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/non_linux.patch
deleted file mode 100644
index 35b1b38..0000000
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/non_linux.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-Index: elfutils-0.159/libdwfl/linux-pid-attach.c
-===================================================================
---- elfutils-0.159.orig/libdwfl/linux-pid-attach.c
-+++ elfutils-0.159/libdwfl/linux-pid-attach.c
-@@ -393,6 +393,16 @@ pid_getthread (Dwfl *dwfl __attribute__
-   return false;
- }
- 
-+bool
-+internal_function
-+__libdwfl_ptrace_attach (pid_t tid __attribute__ ((unused)),
-+			 bool *tid_was_stoppedp __attribute__ ((unused)))
-+{
-+  errno = ENOSYS;
-+  __libdwfl_seterrno (DWFL_E_ERRNO);
-+  return false;
-+}
-+
- static bool
- pid_memory_read (Dwfl *dwfl __attribute__ ((unused)),
-                  Dwarf_Addr addr __attribute__ ((unused)),
-@@ -419,6 +429,13 @@ pid_detach (Dwfl *dwfl __attribute__ ((u
- {
- }
- 
-+void
-+internal_function
-+__libdwfl_ptrace_detach (pid_t tid __attribute__ ((unused)),
-+			 bool tid_was_stopped __attribute__ ((unused)))
-+{
-+}
-+
- static void
- pid_thread_detach (Dwfl_Thread *thread __attribute__ ((unused)),
- 		  void *thread_arg __attribute__ ((unused)))
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/redhat-portability.diff b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/redhat-portability.diff
deleted file mode 100644
index a0ff07d..0000000
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/redhat-portability.diff
+++ /dev/null
@@ -1,1021 +0,0 @@
-Rebase to 1.162
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- ChangeLog                   |   30 +++++++++++++++++++++
- backends/ChangeLog          |   12 +++++++++
- backends/Makefile.am        |    2 +-
- config/ChangeLog            |    4 +++
- config/eu.am                |   14 +++++++---
- configure.ac                |   61 +++++++++++++++++++++++++++++++++++++++++--
- lib/ChangeLog               |    8 ++++++
- lib/eu-config.h             |   10 +++++++
- libasm/ChangeLog            |    5 ++++
- libcpu/ChangeLog            |    8 ++++++
- libcpu/i386_disasm.c        |    1 +
- libdw/ChangeLog             |   13 +++++++++
- libdw/dwarf_begin_elf.c     |    8 ++++++
- libdw/libdw.h               |    2 +-
- libdwfl/ChangeLog           |   20 ++++++++++++++
- libdwfl/linux-core-attach.c |   29 ++++++++++++++++++++
- libdwfl/linux-pid-attach.c  |   14 ++++++++++
- libebl/ChangeLog            |    5 ++++
- libelf/ChangeLog            |   10 +++++++
- libelf/common.h             |    4 +--
- libelf/gnuhash_xlate.h      |    6 +++--
- src/ChangeLog               |   30 +++++++++++++++++++++
- src/Makefile.am             |    5 ++++
- src/addr2line.c             |    4 +--
- src/findtextrel.c           |    6 ++++-
- src/ld.h                    |    2 ++
- src/readelf.c               |   15 +++++++----
- src/strings.c               |   11 ++++++++
- src/strip.c                 |    6 +++++
- tests/ChangeLog             |   14 ++++++++++
- tests/Makefile.am           |    1 +
- tests/backtrace.c           |    1 +
- tests/line2addr.c           |    2 +-
- 33 files changed, 343 insertions(+), 20 deletions(-)
-
-diff --git a/ChangeLog b/ChangeLog
-index d829783..89bfd24 100644
---- a/ChangeLog
-+++ b/ChangeLog
-@@ -253,6 +253,8 @@
- 
- 2012-01-24  Mark Wielaard  <mjw@redhat.com>
- 
-+	* configure.ac: Wrap AC_COMPILE_IFELSE sources in AC_LANG_SOURCE.
-+
- 	* COPYING: Fix address. Updated version from gnulib.
- 
- 2012-01-23  Mark Wielaard  <mjw@redhat.com>
-@@ -271,6 +273,9 @@
- 
- 2011-10-08  Mike Frysinger  <vapier@gentoo.org>
- 
-+	* configure.ac (--disable-werror): Handle it, controlling BUILD_WERROR
-+	automake option.
-+
- 	* configure.ac: Fix use of AC_ARG_ENABLE to handle $enableval correctly.
- 
- 2011-10-02  Ulrich Drepper  <drepper@gmail.com>
-@@ -292,6 +297,10 @@
- 
- 	* configure.ac (LOCALEDIR, DATADIRNAME): Removed.
- 
-+2009-11-22  Roland McGrath  <roland@redhat.com>
-+
-+	* configure.ac: Use sed and expr instead of modern bash extensions.
-+
- 2009-09-21  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* configure.ac: Update for more modern autoconf.
-@@ -300,6 +309,10 @@
- 
- 	* configure.ac (zip_LIBS): Check for liblzma too.
- 
-+2009-08-17  Roland McGrath  <roland@redhat.com>
-+
-+	* configure.ac: Check for -fgnu89-inline; add it to WEXTRA if it works.
-+
- 2009-04-19  Roland McGrath  <roland@redhat.com>
- 
- 	* configure.ac (eu_version): Round down here, not in version.h macros.
-@@ -311,6 +324,8 @@
- 
- 2009-01-23  Roland McGrath  <roland@redhat.com>
- 
-+	* configure.ac: Check for __builtin_popcount.
-+
- 	* configure.ac (zlib check): Check for gzdirect, need zlib >= 1.2.2.3.
- 
- 	* configure.ac (__thread check): Use AC_LINK_IFELSE, in case of
-@@ -391,6 +406,10 @@
- 	* configure.ac: Add dummy automake conditional to get dependencies
- 	for non-generic linker right.  See src/Makefile.am.
- 
-+2005-11-22  Roland McGrath  <roland@redhat.com>
-+
-+	* configure.ac: Check for --as-needed linker option.
-+
- 2005-11-18  Roland McGrath  <roland@redhat.com>
- 
- 	* Makefile.am (DISTCHECK_CONFIGURE_FLAGS): New variable.
-@@ -438,6 +457,17 @@
- 	* Makefile.am (all_SUBDIRS): Add libdwfl.
- 	* configure.ac: Write libdwfl/Makefile.
- 
-+2005-05-31  Roland McGrath  <roland@redhat.com>
-+
-+	* configure.ac (WEXTRA): Check for -Wextra and set this substitution.
-+
-+	* configure.ac: Check for struct stat st_?tim members.
-+	* src/strip.c (process_file): Use st_?time if st_?tim are not there.
-+
-+	* configure.ac: Check for futimes function.
-+	* src/strip.c (handle_elf) [! HAVE_FUTIMES]: Use utimes instead.
-+	(handle_ar) [! HAVE_FUTIMES]: Likewise.
-+
- 2005-05-19  Roland McGrath  <roland@redhat.com>
- 
- 	* configure.ac [AH_BOTTOM] (INTDECL, _INTDECL): New macros.
-diff --git a/backends/ChangeLog b/backends/ChangeLog
-index fe61d9c..9599623 100644
---- a/backends/ChangeLog
-+++ b/backends/ChangeLog
-@@ -498,6 +498,10 @@
- 	* ppc_attrs.c (ppc_check_object_attribute): Handle tag
- 	GNU_Power_ABI_Struct_Return.
- 
-+2009-01-23  Roland McGrath  <roland@redhat.com>
-+
-+	* Makefile.am (libebl_%.so): Use $(LD_AS_NEEDED).
-+
- 2008-10-04  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* i386_reloc.def: Fix entries for TLS_GOTDESC, TLS_DESC_CALL, and
-@@ -825,6 +829,11 @@
- 	* sparc_init.c: Likewise.
- 	* x86_64_init.c: Likewise.
- 
-+2005-11-22  Roland McGrath  <roland@redhat.com>
-+
-+	* Makefile.am (LD_AS_NEEDED): New variable, substituted by configure.
-+	(libebl_%.so rule): Use it in place of -Wl,--as-needed.
-+
- 2005-11-19  Roland McGrath  <roland@redhat.com>
- 
- 	* ppc64_reloc.def: REL30 -> ADDR30.
-@@ -847,6 +856,9 @@
- 	* Makefile.am (uninstall): Don't try to remove $(pkgincludedir).
- 	(CLEANFILES): Add libebl_$(m).so.
- 
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it in place of -Wextra.
-+
- 	* ppc_reloc.def: Update bits per Alan Modra <amodra@bigpond.net.au>.
- 	* ppc64_reloc.def: Likewise.
- 
-diff --git a/backends/Makefile.am b/backends/Makefile.am
-index 21d7bd2..fe920c9 100644
---- a/backends/Makefile.am
-+++ b/backends/Makefile.am
-@@ -119,7 +119,7 @@ libebl_%.so libebl_%.map: libebl_%_pic.a $(libelf) $(libdw)
- 	$(LINK) -shared -o $(@:.map=.so) \
- 		-Wl,--whole-archive $< $(cpu_$*) -Wl,--no-whole-archive \
- 		-Wl,--version-script,$(@:.so=.map) \
--		-Wl,-z,defs -Wl,--as-needed $(libelf) $(libdw)
-+		-Wl,-z,defs $(LD_AS_NEEDED) $(libelf) $(libdw)
- 	@$(textrel_check)
- 
- libebl_i386.so: $(cpu_i386)
-diff --git a/config/ChangeLog b/config/ChangeLog
-index 64b58e1..63b3e90 100644
---- a/config/ChangeLog
-+++ b/config/ChangeLog
-@@ -106,6 +106,10 @@
- 
- 	* known-dwarf.awk: Use gawk.
- 
-+2011-10-08  Mike Frysinger  <vapier@gentoo.org>
-+
-+	* eu.am [BUILD_WERROR]: Conditionalize -Werror use on this.
-+
- 2010-07-02  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* elfutils.spec.in: Add more BuildRequires.
-diff --git a/config/eu.am b/config/eu.am
-index 70d32de..65af085 100644
---- a/config/eu.am
-+++ b/config/eu.am
-@@ -1,6 +1,6 @@
- ## Common automake fragments for elfutils subdirectory makefiles.
- ##
--## Copyright (C) 2010, 2014 Red Hat, Inc.
-+## Copyright (C) 2010-2011, 2014 Red Hat, Inc.
- ##
- ## This file is part of elfutils.
- ##
-@@ -29,6 +29,9 @@
- ## not, see <http://www.gnu.org/licenses/>.
- ##
- 
-+WEXTRA = @WEXTRA@
-+LD_AS_NEEDED = @LD_AS_NEEDED@
-+
- DEFS = -D_GNU_SOURCE -DHAVE_CONFIG_H -DLOCALEDIR='"${localedir}"'
- AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I..
- 
-@@ -38,12 +41,17 @@ STACK_USAGE_WARNING=-Wstack-usage=262144
- else
- STACK_USAGE_WARNING=
- endif
--AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \
-+AM_CFLAGS = -std=gnu99 -Wall -Wshadow \
- 	    $(if $($(*F)_no_Werror),,-Werror) \
--	    $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \
-+	    $(if $($(*F)_no_Wunused),,-Wunused $(WEXTRA)) \
-+	    $(if $($(*F)_no_Wformat),-Wno-format,-Wformat=2) \
- 	    $(if $($(*F)_no_Wstack_usage),,$(STACK_USAGE_WARNING)) \
- 	    $($(*F)_CFLAGS)
- 
-+if BUILD_WERROR
-+AM_CFLAGS += $(if $($(*F)_no_Werror),,-Werror)
-+endif
-+
- COMPILE.os = $(filter-out -fprofile-arcs -ftest-coverage, $(COMPILE))
- 
- DEFS.os = -DPIC -DSHARED
-diff --git a/configure.ac b/configure.ac
-index bc9ff56..27a1ef3 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -106,6 +106,55 @@ CFLAGS="$old_CFLAGS"])
- AS_IF([test "x$ac_cv_c99" != xyes],
-       AC_MSG_ERROR([gcc with GNU99 support required]))
- 
-+AC_CACHE_CHECK([for -Wextra option to $CC], ac_cv_cc_wextra, [dnl
-+old_CFLAGS="$CFLAGS"
-+CFLAGS="$CFLAGS -Wextra"
-+AC_COMPILE_IFELSE([AC_LANG_SOURCE([void foo (void) { }])],
-+		  ac_cv_cc_wextra=yes, ac_cv_cc_wextra=no)
-+CFLAGS="$old_CFLAGS"])
-+AC_SUBST(WEXTRA)
-+AS_IF([test "x$ac_cv_cc_wextra" = xyes], [WEXTRA=-Wextra], [WEXTRA=-W])
-+
-+AC_CACHE_CHECK([for -fgnu89-inline option to $CC], ac_cv_cc_gnu89_inline, [dnl
-+old_CFLAGS="$CFLAGS"
-+CFLAGS="$CFLAGS -fgnu89-inline -Werror"
-+AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-+void foo (void)
-+{
-+  inline void bar (void) {}
-+  bar ();
-+}
-+extern inline void baz (void) {}
-+])], ac_cv_cc_gnu89_inline=yes, ac_cv_cc_gnu89_inline=no)
-+CFLAGS="$old_CFLAGS"])
-+AS_IF([test "x$ac_cv_cc_gnu89_inline" = xyes],
-+      [WEXTRA="${WEXTRA:+$WEXTRA }-fgnu89-inline"])
-+
-+AC_CACHE_CHECK([for --as-needed linker option],
-+	       ac_cv_as_needed, [dnl
-+cat > conftest.c <<EOF
-+int main (void) { return 0; }
-+EOF
-+if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS
-+			    -fPIC -shared -o conftest.so conftest.c
-+			    -Wl,--as-needed 1>&AS_MESSAGE_LOG_FD])
-+then
-+  ac_cv_as_needed=yes
-+else
-+  ac_cv_as_needed=no
-+fi
-+rm -f conftest*])
-+AS_IF([test "x$ac_cv_as_needed" = xyes],
-+      [LD_AS_NEEDED=-Wl,--as-needed], [LD_AS_NEEDED=])
-+AC_SUBST(LD_AS_NEEDED)
-+
-+AC_CACHE_CHECK([for __builtin_popcount], ac_cv_popcount, [dnl
-+AC_LINK_IFELSE([AC_LANG_PROGRAM([], [[exit (__builtin_popcount (127));]])],
-+	       ac_cv_popcount=yes, ac_cv_popcount=no)])
-+AS_IF([test "x$ac_cv_popcount" = xyes],
-+      [AC_DEFINE([HAVE_BUILTIN_POPCOUNT], [1], [Have __builtin_popcount.])])
-+
-+
- AC_CACHE_CHECK([for __thread support], ac_cv_tls, [dnl
- # Use the same flags that we use for our DSOs, so the test is representative.
- # Some old compiler/linker/libc combinations fail some ways and not others.
-@@ -122,7 +171,10 @@ static __thread int a; int foo (int b) { return a + b; }]],
- CFLAGS="$save_CFLAGS"
- LDFLAGS="$save_LDFLAGS"])
- AS_IF([test "x$ac_cv_tls" != xyes],
--      AC_MSG_ERROR([__thread support required]))
-+      [AS_IF([test "$use_locks" = yes],
-+	     [AC_MSG_ERROR([--enable-thread-safety requires __thread support])],
-+	     [AC_DEFINE([__thread], [/* empty: no multi-thread support */],
-+			[Stubbed out if missing compiler support.])])])
- 
- dnl This test must come as early as possible after the compiler configuration
- dnl tests, because the choice of the file model can (in principle) affect
-@@ -224,6 +276,11 @@ AM_CONDITIONAL(USE_VALGRIND, test "$use_valgrind" = yes)
- AM_CONDITIONAL(BUILD_STATIC, [dnl
- test "$use_gprof" = yes -o "$use_gcov" = yes])
- 
-+AC_ARG_ENABLE([werror],
-+AS_HELP_STRING([--disable-werror],[do not build with -Werror]),
-+	       [enable_werror=$enableval], [enable_werror=yes])
-+AM_CONDITIONAL(BUILD_WERROR, test "$enable_werror" = yes)
-+
- AC_ARG_ENABLE([tests-rpath],
- AS_HELP_STRING([--enable-tests-rpath],[build $ORIGIN-using rpath into tests]),
- 	       [tests_use_rpath=$enableval], [tests_use_rpath=no])
-@@ -388,7 +445,7 @@ case "$eu_version" in
- esac
- 
- # Round up to the next release API (x.y) version.
--eu_version=$(( (eu_version + 999) / 1000 ))
-+eu_version=`expr \( $eu_version + 999 \) / 1000`
- 
- dnl Unique ID for this build.
- MODVERSION="Build for ${LIBEBL_SUBDIR} ${eu_version} ${ac_cv_build}"
-diff --git a/lib/ChangeLog b/lib/ChangeLog
-index d04bf17..720c98d 100644
---- a/lib/ChangeLog
-+++ b/lib/ChangeLog
-@@ -73,6 +73,9 @@
- 
- 2009-01-23  Roland McGrath  <roland@redhat.com>
- 
-+	* eu-config.h [! HAVE_BUILTIN_POPCOUNT]
-+	(__builtin_popcount): New inline function.
-+
- 	* eu-config.h: Add multiple inclusion protection.
- 
- 2009-01-17  Ulrich Drepper  <drepper@redhat.com>
-@@ -129,6 +132,11 @@
- 	* Makefile.am (libeu_a_SOURCES): Add it.
- 	* system.h: Declare crc32_file.
- 
-+2005-02-07  Roland McGrath  <roland@redhat.com>
-+
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it in place of -Wextra.
-+
- 2005-04-30  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* Makefile.am: Use -ffunction-sections for xmalloc.c.
-diff --git a/lib/eu-config.h b/lib/eu-config.h
-index 400cdc6..872f6bc 100644
---- a/lib/eu-config.h
-+++ b/lib/eu-config.h
-@@ -163,6 +163,16 @@ asm (".section predict_data, \"aw\"; .previous\n"
- /* This macro is used by the tests conditionalize for standalone building.  */
- #define ELFUTILS_HEADER(name) <lib##name.h>
- 
-+#ifndef HAVE_BUILTIN_POPCOUNT
-+# define __builtin_popcount hakmem_popcount
-+static inline unsigned int __attribute__ ((unused))
-+hakmem_popcount (unsigned int x)
-+{
-+  /* HAKMEM 169 */
-+  unsigned int n = x - ((x >> 1) & 033333333333) - ((x >> 2) & 011111111111);
-+  return ((n + (n >> 3)) & 030707070707) % 63;
-+}
-+#endif	/* HAVE_BUILTIN_POPCOUNT */
- 
- #ifdef SYMBOL_VERSIONING
- # define OLD_VERSION(name, version) \
-diff --git a/libasm/ChangeLog b/libasm/ChangeLog
-index 9b25af9..32b9fd0 100644
---- a/libasm/ChangeLog
-+++ b/libasm/ChangeLog
-@@ -87,6 +87,11 @@
- 	* asm_error.c: Add new error ASM_E_IOERROR.
- 	* libasmP.h: Add ASM_E_IOERROR definition.
- 
-+2005-05-31  Roland McGrath  <roland@redhat.com>
-+
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it in place of -Wextra.
-+
- 2005-02-15  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* Makefile.am (AM_CFLAGS): Add -Wunused -Wextra -Wformat=2.
-diff --git a/libcpu/ChangeLog b/libcpu/ChangeLog
-index a20f440..5ea23b7 100644
---- a/libcpu/ChangeLog
-+++ b/libcpu/ChangeLog
-@@ -51,6 +51,9 @@
- 
- 2009-01-23  Roland McGrath  <roland@redhat.com>
- 
-+	* i386_disasm.c (i386_disasm): Add abort after assert-constant for old
-+	compilers that don't realize it's noreturn.
-+
- 	* Makefile.am (i386_parse_CFLAGS): Use quotes around command
- 	substitution that can produce leading whitespace.
- 
-@@ -380,6 +383,11 @@
- 	* defs/i386.doc: New file.
- 	* defs/x86_64: New file.
- 
-+2005-04-04  Roland McGrath  <roland@redhat.com>
-+
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it instead of -Wextra.
-+
- 2005-02-15  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* Makefile (AM_CFLAGS): Add -Wunused -Wextra -Wformat=2.
-diff --git a/libcpu/i386_disasm.c b/libcpu/i386_disasm.c
-index 832241f..c7a0df0 100644
---- a/libcpu/i386_disasm.c
-+++ b/libcpu/i386_disasm.c
-@@ -822,6 +822,7 @@ i386_disasm (const uint8_t **startp, const uint8_t *end, GElf_Addr addr,
- 
- 			default:
- 			  assert (! "INVALID not handled");
-+			  abort ();
- 			}
- 		    }
- 		  else
-diff --git a/libdw/ChangeLog b/libdw/ChangeLog
-index 487e34a..06c737b 100644
---- a/libdw/ChangeLog
-+++ b/libdw/ChangeLog
-@@ -889,6 +889,10 @@
- 
- 	* Makefile.am (known-dwarf.h): Run gawk on config/known-dwarf.awk.
- 
-+2011-07-20  Mark Wielaard  <mjw@redhat.com>
-+
-+	* dwarf_begin_elf.c: Add fallback for be64toh if not defined.
-+
- 2011-07-14  Mark Wielaard  <mjw@redhat.com>
- 
- 	* libdw.h (dwarf_offdie): Fix documentation to mention .debug_info.
-@@ -1248,6 +1252,10 @@
- 
- 	* dwarf_hasattr_integrate.c: Integrate DW_AT_specification too.
- 
-+2009-08-17  Roland McGrath  <roland@redhat.com>
-+
-+	* libdw.h: Disable extern inlines for GCC 4.2.
-+
- 2009-08-10  Roland McGrath  <roland@redhat.com>
- 
- 	* dwarf_getscopevar.c: Use dwarf_diename.
-@@ -2016,6 +2024,11 @@
- 
- 2005-05-31  Roland McGrath  <roland@redhat.com>
- 
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it in place of -Wextra.
-+
-+2005-05-31  Roland McGrath  <roland@redhat.com>
-+
- 	* dwarf_formref_die.c (dwarf_formref_die): Add CU header offset to
- 	formref offset.
- 
-diff --git a/libdw/dwarf_begin_elf.c b/libdw/dwarf_begin_elf.c
-index 4e0d590..a6616a1 100644
---- a/libdw/dwarf_begin_elf.c
-+++ b/libdw/dwarf_begin_elf.c
-@@ -47,6 +47,14 @@
- #if USE_ZLIB
- # include <endian.h>
- # define crc32		loser_crc32
-+# ifndef be64toh
-+#  include <byteswap.h>
-+#  if __BYTE_ORDER == __LITTLE_ENDIAN
-+#   define be64toh(x) bswap_64 (x)
-+#  else
-+#   define be64toh(x) (x)
-+#  endif
-+# endif
- # include <zlib.h>
- # undef crc32
- #endif
-diff --git a/libdw/libdw.h b/libdw/libdw.h
-index 473e1a2..5a511cd 100644
---- a/libdw/libdw.h
-+++ b/libdw/libdw.h
-@@ -1004,7 +1004,7 @@ extern Dwarf_OOM dwarf_new_oom_handler (Dwarf *dbg, Dwarf_OOM handler);
- 
- 
- /* Inline optimizations.  */
--#ifdef __OPTIMIZE__
-+#if defined __OPTIMIZE__ && !(__GNUC__ == 4 && __GNUC_MINOR__ == 2)
- /* Return attribute code of given attribute.  */
- __libdw_extern_inline unsigned int
- dwarf_whatattr (Dwarf_Attribute *attr)
-diff --git a/libdwfl/ChangeLog b/libdwfl/ChangeLog
-index a5253e2..59abfac 100644
---- a/libdwfl/ChangeLog
-+++ b/libdwfl/ChangeLog
-@@ -704,6 +704,21 @@
- 	(dwfl_module_addrsym) (i_to_symfile): New function.
- 	(dwfl_module_addrsym) (search_table): Use it.
- 
-+2013-11-09  Jan Kratochvil  <jan.kratochvil@redhat.com>
-+
-+	Older OS compatibility bits.
-+	* linux-core-attach.c (be64toh, le64toh, be32toh, le32toh): Provide
-+	fallbacks if not defined by system.
-+
-+2013-11-09  Jan Kratochvil  <jan.kratochvil@redhat.com>
-+
-+	Handle T-stopped detach for old kernels.
-+	* linux-pid-attach.c (struct pid_arg): New field stopped.
-+	(ptrace_attach): New parameter stoppedp.  Set it appropriately.
-+	(pid_set_initial_registers): Pass the new field.
-+	(pid_thread_detach): Handle the case of STOPPED for old kernels.
-+	(__libdwfl_attach_state_for_pid): Initialize STOPPED.
-+
- 2013-11-07  Jan Kratochvil  <jan.kratochvil@redhat.com>
- 	    Mark Wielaard  <mjw@redhat.com>
- 
-@@ -2469,6 +2484,11 @@
- 
- 2005-07-21  Roland McGrath  <roland@redhat.com>
- 
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it in place of -Wextra.
-+
-+2005-07-21  Roland McGrath  <roland@redhat.com>
-+
- 	* Makefile.am (noinst_HEADERS): Add loc2c.c.
- 
- 	* test2.c (main): Check sscanf result to quiet warning.
-diff --git a/libdwfl/linux-core-attach.c b/libdwfl/linux-core-attach.c
-index 5a7b3b3..d05ac7e 100644
---- a/libdwfl/linux-core-attach.c
-+++ b/libdwfl/linux-core-attach.c
-@@ -29,6 +29,35 @@
- #include "libdwflP.h"
- #include <fcntl.h>
- #include "system.h"
-+#include <endian.h>
-+#include <byteswap.h>
-+#if __BYTE_ORDER == __LITTLE_ENDIAN
-+# ifndef be64toh
-+#  define be64toh(x) bswap_64 (x)
-+# endif
-+# ifndef le64toh
-+#  define le64toh(x) (x)
-+# endif
-+# ifndef be32toh
-+#  define be32toh(x) bswap_32 (x)
-+# endif
-+# ifndef le32toh
-+#  define le32toh(x) (x)
-+# endif
-+#else
-+# ifndef be64toh
-+#  define be64toh(x) (x)
-+# endif
-+# ifndef le64toh
-+#  define le64toh(x) bswap_64 (x)
-+# endif
-+# ifndef be32toh
-+#  define be32toh(x) (x)
-+# endif
-+# ifndef le32toh
-+#  define le32toh(x) bswap_32 (x)
-+# endif
-+#endif
- 
- #include "../libdw/memory-access.h"
- 
-diff --git a/libdwfl/linux-pid-attach.c b/libdwfl/linux-pid-attach.c
-index ae71702..076b2c3 100644
---- a/libdwfl/linux-pid-attach.c
-+++ b/libdwfl/linux-pid-attach.c
-@@ -255,6 +255,11 @@ void
- internal_function
- __libdwfl_ptrace_detach (pid_t tid, bool tid_was_stopped)
- {
-+  // Older kernels (tested kernel-2.6.18-348.12.1.el5.x86_64) need special
-+  // handling of the detachment to keep the process State: T (stopped).
-+  if (tid_was_stopped)
-+    syscall (__NR_tkill, tid, SIGSTOP);
-+
-   /* This handling is needed only on older Linux kernels such as
-      2.6.32-358.23.2.el6.ppc64.  Later kernels such as
-      3.11.7-200.fc19.x86_64 remember the T (stopped) state
-@@ -262,6 +267,15 @@ __libdwfl_ptrace_detach (pid_t tid, bool tid_was_stopped)
-      PTRACE_DETACH.  */
-   ptrace (PTRACE_DETACH, tid, NULL,
- 	  (void *) (intptr_t) (tid_was_stopped ? SIGSTOP : 0));
-+
-+  if (tid_was_stopped)
-+    {
-+      // Wait till the SIGSTOP settles down.
-+      int i;
-+      for (i = 0; i < 100000; i++)
-+	if (linux_proc_pid_is_stopped (tid))
-+	  break;
-+    }
- }
- 
- static void
-diff --git a/libebl/ChangeLog b/libebl/ChangeLog
-index 51ae60f..aee0217 100644
---- a/libebl/ChangeLog
-+++ b/libebl/ChangeLog
-@@ -780,6 +780,11 @@
- 	* Makefile.am (libebl_*_so_SOURCES): Set to $(*_SRCS) so dependency
- 	tracking works right.
- 
-+2005-05-31  Roland McGrath  <roland@redhat.com>
-+
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it in place of -Wextra.
-+
- 2005-05-21  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* libebl_x86_64.map: Add x86_64_core_note.
-diff --git a/libelf/ChangeLog b/libelf/ChangeLog
-index 30017cd..9ca9c73 100644
---- a/libelf/ChangeLog
-+++ b/libelf/ChangeLog
-@@ -398,6 +398,11 @@
- 
- 	* elf-knowledge.h (SECTION_STRIP_P): Remove < SHT_NUM check.
- 
-+2011-03-10  Roland McGrath  <roland@redhat.com>
-+
-+	* gnuhash_xlate.h (elf_cvt_gnuhash): Avoid post-increment in bswap_32
-+	argument, since some implementations are buggy macros.
-+
- 2011-02-26  Mark Wielaard  <mjw@redhat.com>
- 
- 	* elf_end.c (elf_end): Call rwlock_unlock before rwlock_fini.
-@@ -1075,6 +1080,11 @@
- 
- 	* elf.h: Update from glibc.
- 
-+2005-05-31  Roland McGrath  <roland@redhat.com>
-+
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it in place of -Wextra.
-+
- 2005-05-08  Roland McGrath  <roland@redhat.com>
- 
- 	* elf_begin.c (read_file) [_MUDFLAP]: Don't use mmap for now.
-diff --git a/libelf/common.h b/libelf/common.h
-index 744f1bb..185ea59 100644
---- a/libelf/common.h
-+++ b/libelf/common.h
-@@ -139,7 +139,7 @@ libelf_release_all (Elf *elf)
-   (Var) = (sizeof (Var) == 1						      \
- 	   ? (unsigned char) (Var)					      \
- 	   : (sizeof (Var) == 2						      \
--	      ? bswap_16 (Var)						      \
-+	      ? (unsigned short int) bswap_16 (Var)			      \
- 	      : (sizeof (Var) == 4					      \
- 		 ? bswap_32 (Var)					      \
- 		 : bswap_64 (Var))))
-@@ -148,7 +148,7 @@ libelf_release_all (Elf *elf)
-   (Dst) = (sizeof (Var) == 1						      \
- 	   ? (unsigned char) (Var)					      \
- 	   : (sizeof (Var) == 2						      \
--	      ? bswap_16 (Var)						      \
-+	      ? (unsigned short int) bswap_16 (Var)			      \
- 	      : (sizeof (Var) == 4					      \
- 		 ? bswap_32 (Var)					      \
- 		 : bswap_64 (Var))))
-diff --git a/libelf/gnuhash_xlate.h b/libelf/gnuhash_xlate.h
-index 04d9ca1..3e25936 100644
---- a/libelf/gnuhash_xlate.h
-+++ b/libelf/gnuhash_xlate.h
-@@ -1,5 +1,5 @@
- /* Conversion functions for versioning information.
--   Copyright (C) 2006, 2007 Red Hat, Inc.
-+   Copyright (C) 2006-2011 Red Hat, Inc.
-    This file is part of elfutils.
-    Written by Ulrich Drepper <drepper@redhat.com>, 2006.
- 
-@@ -69,7 +69,9 @@ elf_cvt_gnuhash (void *dest, const void *src, size_t len, int encode)
-   dest32 = (Elf32_Word *) &dest64[bitmask_words];
-   while (len >= 4)
-     {
--      *dest32++ = bswap_32 (*src32++);
-+      *dest32 = bswap_32 (*src32);
-+      ++dest32;
-+      ++src32;
-       len -= 4;
-     }
- }
-diff --git a/src/ChangeLog b/src/ChangeLog
-index 15e6fae..78535c8 100644
---- a/src/ChangeLog
-+++ b/src/ChangeLog
-@@ -1598,8 +1598,16 @@
- 	* readelf.c (attr_callback): Use print_block only when we don't use
- 	print_ops.
- 
-+2009-08-17  Roland McGrath  <roland@redhat.com>
-+
-+	* ld.h: Disable extern inlines for GCC 4.2.
-+
- 2009-08-14  Roland McGrath  <roland@redhat.com>
- 
-+	* strings.c (read_block): Conditionalize posix_fadvise use
-+	on [POSIX_FADV_SEQUENTIAL].
-+	From Petr Salinger <Petr.Salinger@seznam.cz>.
-+
- 	* ar.c (do_oper_extract): Use pathconf instead of statfs.
- 
- 2009-08-01  Ulrich Drepper  <drepper@redhat.com>
-@@ -1763,6 +1771,8 @@
- 	* readelf.c (print_debug_frame_section): Use t instead of j formats
- 	for ptrdiff_t OFFSET.
- 
-+	* addr2line.c (handle_address): Use %a instead of %m for compatibility.
-+
- 2009-01-21  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* elflint.c (check_program_header): Fix typo in .eh_frame_hdr section
-@@ -1946,6 +1956,11 @@
- 	that matches its PT_LOAD's p_flags &~ PF_W.  On sparc, PF_X really
- 	is valid in RELRO.
- 
-+2008-03-01  Roland McGrath  <roland@redhat.com>
-+
-+	* readelf.c (dump_archive_index): Tweak portability hack
-+	to match [__GNUC__ < 4] too.
-+
- 2008-02-29  Roland McGrath  <roland@redhat.com>
- 
- 	* readelf.c (print_attributes): Add a cast.
-@@ -2197,6 +2212,8 @@
- 
- 	* readelf.c (hex_dump): Fix rounding error in whitespace calculation.
- 
-+	* Makefile.am (readelf_no_Werror): New variable.
-+
- 2007-10-15  Roland McGrath  <roland@redhat.com>
- 
- 	* make-debug-archive.in: New file.
-@@ -2636,6 +2653,10 @@
- 	* elflint.c (valid_e_machine): Add EM_ALPHA.
- 	Reported by Christian Aichinger <Greek0@gmx.net>.
- 
-+	* strings.c (map_file): Define POSIX_MADV_SEQUENTIAL to
-+	MADV_SEQUENTIAL if undefined.  	Don't call posix_madvise
-+	if neither is defined.
-+
- 2006-08-08  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* elflint.c (check_dynamic): Don't require DT_HASH for DT_SYMTAB.
-@@ -2712,6 +2733,10 @@
- 	* Makefile.am: Add hacks to create dependency files for non-generic
- 	linker.
- 
-+2006-04-05  Roland McGrath  <roland@redhat.com>
-+
-+	* strings.c (MAP_POPULATE): Define to 0 if undefined.
-+
- 2006-06-12  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* ldgeneric.c (ld_generic_generate_sections): Don't create .interp
-@@ -3060,6 +3085,11 @@
- 	* readelf.c (print_debug_loc_section): Fix indentation for larger
- 	address size.
- 
-+2005-05-31  Roland McGrath  <roland@redhat.com>
-+
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it in place of -Wextra.
-+
- 2005-05-30  Roland McGrath  <roland@redhat.com>
- 
- 	* readelf.c (print_debug_line_section): Print section offset of each
-diff --git a/src/Makefile.am b/src/Makefile.am
-index dbac3eb..9028aa1 100644
---- a/src/Makefile.am
-+++ b/src/Makefile.am
-@@ -90,6 +90,11 @@ endif
- ldgeneric_no_Wunused = yes
- ldgeneric_no_Wstack_usage = yes
- 
-+# Buggy old compilers or libc headers.
-+readelf_no_Werror = yes
-+strings_no_Werror = yes
-+addr2line_no_Wformat = yes
-+
- # Bad, bad stack usage...
- readelf_no_Wstack_usage = yes
- nm_no_Wstack_usage = yes
-diff --git a/src/addr2line.c b/src/addr2line.c
-index 0ce854f..d2d0c8c 100644
---- a/src/addr2line.c
-+++ b/src/addr2line.c
-@@ -622,10 +622,10 @@ handle_address (const char *string, Dwfl *dwfl)
-       bool parsed = false;
-       int i, j;
-       char *name = NULL;
--      if (sscanf (string, "(%m[^)])%" PRIiMAX "%n", &name, &addr, &i) == 2
-+      if (sscanf (string, "(%a[^)])%" PRIiMAX "%n", &name, &addr, &i) == 2
- 	  && string[i] == '\0')
- 	parsed = adjust_to_section (name, &addr, dwfl);
--      switch (sscanf (string, "%m[^-+]%n%" PRIiMAX "%n", &name, &i, &addr, &j))
-+      switch (sscanf (string, "%a[^-+]%n%" PRIiMAX "%n", &name, &i, &addr, &j))
- 	{
- 	default:
- 	  break;
-diff --git a/src/findtextrel.c b/src/findtextrel.c
-index 264a06b..d7de202 100644
---- a/src/findtextrel.c
-+++ b/src/findtextrel.c
-@@ -502,7 +502,11 @@ ptrcompare (const void *p1, const void *p2)
- 
- 
- static void
--check_rel (size_t nsegments, struct segments segments[nsegments],
-+check_rel (size_t nsegments, struct segments segments[
-+#if __GNUC__ >= 4
-+						      nsegments
-+#endif
-+	   ],
- 	   GElf_Addr addr, Elf *elf, Elf_Scn *symscn, Dwarf *dw,
- 	   const char *fname, bool more_than_one, void **knownsrcs)
- {
-diff --git a/src/ld.h b/src/ld.h
-index 29f4031..8695c31 100644
---- a/src/ld.h
-+++ b/src/ld.h
-@@ -1114,6 +1114,7 @@ extern bool dynamically_linked_p (void);
- 
- /* Checked whether the symbol is undefined and referenced from a DSO.  */
- extern bool linked_from_dso_p (struct scninfo *scninfo, size_t symidx);
-+#if defined __OPTIMIZE__ && !(__GNUC__ == 4 && __GNUC_MINOR__ == 2)
- #ifdef __GNUC_STDC_INLINE__
- __attribute__ ((__gnu_inline__))
- #endif
-@@ -1131,5 +1132,6 @@ linked_from_dso_p (struct scninfo *scninfo, size_t symidx)
- 
-   return sym->defined && sym->in_dso;
- }
-+#endif	/* Optimizing and not GCC 4.2.  */
- 
- #endif	/* ld.h */
-diff --git a/src/readelf.c b/src/readelf.c
-index b4cb3a8..606d220 100644
---- a/src/readelf.c
-+++ b/src/readelf.c
-@@ -4364,10 +4364,12 @@ listptr_base (struct listptr *p)
-   return base;
- }
- 
-+static const char *listptr_name;
-+
- static int
--compare_listptr (const void *a, const void *b, void *arg)
-+compare_listptr (const void *a, const void *b)
- {
--  const char *name = arg;
-+  const char *const name = listptr_name;
-   struct listptr *p1 = (void *) a;
-   struct listptr *p2 = (void *) b;
- 
-@@ -4463,8 +4465,11 @@ static void
- sort_listptr (struct listptr_table *table, const char *name)
- {
-   if (table->n > 0)
--    qsort_r (table->table, table->n, sizeof table->table[0],
--	     &compare_listptr, (void *) name);
-+    {
-+      listptr_name = name;
-+      qsort (table->table, table->n, sizeof table->table[0],
-+	     &compare_listptr);
-+    }
- }
- 
- static bool
-@@ -9561,7 +9566,7 @@ dump_archive_index (Elf *elf, const char *fname)
- 	  if (unlikely (elf_rand (elf, as_off) == 0)
- 	      || unlikely ((subelf = elf_begin (-1, ELF_C_READ_MMAP, elf))
- 			   == NULL))
--#if __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 7)
-+#if __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 7) || __GNUC__ < 4
- 	    while (1)
- #endif
- 	      error (EXIT_FAILURE, 0,
-diff --git a/src/strings.c b/src/strings.c
-index b2bce7b..fe0ab6c 100644
---- a/src/strings.c
-+++ b/src/strings.c
-@@ -43,6 +43,10 @@
- 
- #include <system.h>
- 
-+#ifndef MAP_POPULATE
-+# define MAP_POPULATE 0
-+#endif
-+
- 
- /* Prototypes of local functions.  */
- static int read_fd (int fd, const char *fname, off64_t fdlen);
-@@ -489,8 +493,13 @@ map_file (int fd, off64_t start_off, off64_t fdlen, size_t *map_sizep)
- 		    fd, start_off);
-       if (mem != MAP_FAILED)
- 	{
-+#if !defined POSIX_MADV_SEQUENTIAL && defined MADV_SEQUENTIAL
-+# define POSIX_MADV_SEQUENTIAL MADV_SEQUENTIAL
-+#endif
-+#ifdef POSIX_MADV_SEQUENTIAL
- 	  /* We will go through the mapping sequentially.  */
- 	  (void) posix_madvise (mem, map_size, POSIX_MADV_SEQUENTIAL);
-+#endif
- 	  break;
- 	}
-       if (errno != EINVAL && errno != ENOMEM)
-@@ -581,9 +590,11 @@ read_block (int fd, const char *fname, off64_t fdlen, off64_t from, off64_t to)
-       elfmap_off = from & ~(ps - 1);
-       elfmap_base = elfmap = map_file (fd, elfmap_off, fdlen, &elfmap_size);
- 
-+#ifdef POSIX_FADV_SEQUENTIAL
-       if (unlikely (elfmap == MAP_FAILED))
- 	/* Let the kernel know we are going to read everything in sequence.  */
- 	(void) posix_fadvise (fd, 0, 0, POSIX_FADV_SEQUENTIAL);
-+#endif
-     }
- 
-   if (unlikely (elfmap == MAP_FAILED))
-diff --git a/src/strip.c b/src/strip.c
-index 5e69334..8bd1790 100644
---- a/src/strip.c
-+++ b/src/strip.c
-@@ -44,6 +44,12 @@
- #include <libebl.h>
- #include <system.h>
- 
-+#ifdef HAVE_FUTIMES
-+# define FUTIMES(fd, fname, tvp) futimes (fd, tvp)
-+#else
-+# define FUTIMES(fd, fname, tvp) utimes (fname, tvp)
-+#endif
-+
- typedef uint8_t GElf_Byte;
- 
- /* Name and version of program.  */
-diff --git a/tests/ChangeLog b/tests/ChangeLog
-index 19878ac..6815028 100644
---- a/tests/ChangeLog
-+++ b/tests/ChangeLog
-@@ -609,6 +609,13 @@
- 
- 2013-12-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
- 
-+	Handle T-stopped detach for old kernels.
-+	* backtrace.c: Include sys/syscall.h.
-+	(linux_proc_pid_is_stopped): New function.
-+	(ptrace_detach_stopped): Handle old kernels.
-+
-+2013-12-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
-+
- 	* Makefile.am (check_PROGRAMS): Add backtrace, backtrace-child,
- 	backtrace-data and backtrace-dwarf.
- 	(BUILT_SOURCES, clean-local, backtrace-child-biarch): New.
-@@ -1473,6 +1480,8 @@
- 
- 2008-01-21  Roland McGrath  <roland@redhat.com>
- 
-+	* line2addr.c (main): Revert last change.
-+
- 	* testfile45.S.bz2: Add tests for cltq, cqto.
- 	* testfile45.expect.bz2: Adjust.
- 
-@@ -2181,6 +2190,11 @@
- 	* Makefile.am (TESTS): Add run-elflint-test.sh.
- 	(EXTRA_DIST): Add run-elflint-test.sh and testfile18.bz2.
- 
-+2005-05-31  Roland McGrath  <roland@redhat.com>
-+
-+	* Makefile.am (WEXTRA): New variable, substituted by configure.
-+	(AM_CFLAGS): Use it in place of -Wextra.
-+
- 2005-05-24  Ulrich Drepper  <drepper@redhat.com>
- 
- 	* get-files.c (main): Use correct format specifier.
-diff --git a/tests/Makefile.am b/tests/Makefile.am
-index 425f8cd..69760a4 100644
---- a/tests/Makefile.am
-+++ b/tests/Makefile.am
-@@ -382,6 +382,7 @@ get_lines_LDADD = $(libdw) $(libelf)
- get_files_LDADD = $(libdw) $(libelf)
- get_aranges_LDADD = $(libdw) $(libelf)
- allfcts_LDADD = $(libdw) $(libelf)
-+line2addr_no_Wformat = yes
- line2addr_LDADD = $(libdw) $(argp_LDADD)
- addrscopes_LDADD = $(libdw) $(argp_LDADD)
- funcscopes_LDADD = $(libdw) $(argp_LDADD)
-diff --git a/tests/backtrace.c b/tests/backtrace.c
-index abd56ab..6a7c661 100644
---- a/tests/backtrace.c
-+++ b/tests/backtrace.c
-@@ -36,6 +36,7 @@
- #include <fcntl.h>
- #include <string.h>
- #include <argp.h>
-+#include <sys/syscall.h>
- #include ELFUTILS_HEADER(dwfl)
- 
- #ifndef __linux__
-diff --git a/tests/line2addr.c b/tests/line2addr.c
-index e0d65d3..7c171b9 100644
---- a/tests/line2addr.c
-+++ b/tests/line2addr.c
-@@ -124,7 +124,7 @@ main (int argc, char *argv[])
-     {
-       struct args a = { .arg = argv[cnt] };
- 
--      switch (sscanf (a.arg, "%m[^:]:%d", &a.file, &a.line))
-+      switch (sscanf (a.arg, "%a[^:]:%d", &a.file, &a.line))
- 	{
- 	default:
- 	case 0:
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/scanf-format.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/scanf-format.patch
deleted file mode 100644
index c08519c..0000000
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/scanf-format.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From: Kurt Roeckx <kurt@roeckx.be>
-Subject: Use %m[ instead of %a[ in scanf()
-
-%a was a gnu extention, but C99 made this a float.  So it got
-changed to %m (supported by glibc 2.7), but %a[ and %as are
-still supported by glibc.  The portability branch changed this
-from %m to %a again since that's supported by more versions of
-glibc.  However gcc gives a warning about this using -Wformat
-and we have a new enough libc to use %m.
-
-Index: elfutils-0.153/src/addr2line.c
-===================================================================
---- elfutils-0.153.orig/src/addr2line.c	2012-02-24 22:29:50.000000000 +0000
-+++ elfutils-0.153/src/addr2line.c	2012-02-24 22:29:52.000000000 +0000
-@@ -455,10 +455,10 @@
-       bool parsed = false;
-       int i, j;
-       char *name = NULL;
--      if (sscanf (string, "(%a[^)])%" PRIiMAX "%n", &name, &addr, &i) == 2
-+      if (sscanf (string, "(%m[^)])%" PRIiMAX "%n", &name, &addr, &i) == 2
- 	  && string[i] == '\0')
- 	parsed = adjust_to_section (name, &addr, dwfl);
--      switch (sscanf (string, "%a[^-+]%n%" PRIiMAX "%n", &name, &i, &addr, &j))
-+      switch (sscanf (string, "%m[^-+]%n%" PRIiMAX "%n", &name, &i, &addr, &j))
- 	{
- 	default:
- 	  break;
-Index: elfutils-0.153/tests/line2addr.c
-===================================================================
---- elfutils-0.153.orig/tests/line2addr.c	2012-02-24 22:29:50.000000000 +0000
-+++ elfutils-0.153/tests/line2addr.c	2012-02-24 22:29:52.000000000 +0000
-@@ -132,7 +132,7 @@
-     {
-       struct args a = { .arg = argv[cnt] };
- 
--      switch (sscanf (a.arg, "%a[^:]:%d", &a.file, &a.line))
-+      switch (sscanf (a.arg, "%m[^:]:%d", &a.file, &a.line))
- 	{
- 	default:
- 	case 0:
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/uclibc-support-for-elfutils-0.161.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/uclibc-support-for-elfutils-0.161.patch
deleted file mode 100644
index f1533bf..0000000
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/uclibc-support-for-elfutils-0.161.patch
+++ /dev/null
@@ -1,106 +0,0 @@
-From 3daec2dd11a04955f95e8f65a48820103d84dbec Mon Sep 17 00:00:00 2001
-From: Junling Zheng <zhengjunling@huawei.com>
-Date: Thu, 9 Apr 2015 12:12:49 +0000
-Subject: [PATCH] uclibc support for elfutils 0.161
-
-on uclibc systems libintl and libuargp are separate from libc.
-so they need to be specified on commandline when we use proxy-libintl
-then libintl is a static archive so it should be listed last since
-elfutils does not respect disable-nls we need to link in libintl
-
-We add a new option --enable-uclibc which will be used to control
-the uclibc specific configurations during build.
-
-Upstream-Status: Inappropriate [uclibc specific]
-
-Signed-off-by: Khem Raj <raj.khem>
-Signed-off-by: Junling Zheng <zhengjunling@huawei.com>
-[Junling Zheng:
- - adjust context
-]
----
- configure.ac       | 8 ++++++++
- libcpu/Makefile.am | 4 ++++
- libdw/Makefile.am  | 7 ++++++-
- libelf/Makefile.am | 5 +++++
- 4 files changed, 23 insertions(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index a1ad6db..81fc33f 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -70,6 +70,14 @@ AS_IF([test "$use_locks" = yes],
- 
- AH_TEMPLATE([USE_LOCKS], [Defined if libraries should be thread-safe.])
- 
-+AC_ARG_ENABLE([uclibc],
-+AS_HELP_STRING([--enable-uclibc], [Use uclibc for system libraries]),
-+use_uclibc=yes, use_uclibc=no)
-+AM_CONDITIONAL(USE_UCLIBC, test "$use_uclibc" = yes)
-+AS_IF([test "$use_uclibc" = yes], [AC_DEFINE(USE_UCLIBC)])
-+
-+AH_TEMPLATE([USE_UCLIBC], [Defined if uclibc libraries are used.])
-+
- AC_PROG_CC
- AC_PROG_RANLIB
- AC_PROG_YACC
-diff --git a/libcpu/Makefile.am b/libcpu/Makefile.am
-index 3beccf3..9ba6c04 100644
---- a/libcpu/Makefile.am
-+++ b/libcpu/Makefile.am
-@@ -80,6 +80,10 @@ i386_parse_CFLAGS = -DNMNES="`wc -l < i386.mnemonics`"
- i386_lex.o: i386_parse.h
- i386_gendis_LDADD = $(libeu) -lm
- 
-+if USE_UCLIBC
-+i386_gendis_LDADD += -luargp -lintl
-+endif
-+
- i386_parse.h: i386_parse.c ;
- 
- EXTRA_DIST = defs/i386
-diff --git a/libdw/Makefile.am b/libdw/Makefile.am
-index 887da6b..d31b428 100644
---- a/libdw/Makefile.am
-+++ b/libdw/Makefile.am
-@@ -102,6 +102,11 @@ endif
- libdw_pic_a_SOURCES =
- am_libdw_pic_a_OBJECTS = $(libdw_a_SOURCES:.c=.os)
- 
-+libdw_so_LDLIBS =
-+if USE_UCLIBC
-+libdw_so_LDLIBS += -lintl -luargp
-+endif
-+
- libdw_so_SOURCES =
- libdw.so$(EXEEXT): $(srcdir)/libdw.map libdw_pic.a ../libdwelf/libdwelf_pic.a \
- 	  ../libdwfl/libdwfl_pic.a ../libebl/libebl.a \
-@@ -112,7 +117,7 @@ libdw.so$(EXEEXT): $(srcdir)/libdw.map libdw_pic.a ../libdwelf/libdwelf_pic.a \
- 		-Wl,--enable-new-dtags,-rpath,$(pkglibdir) \
- 		-Wl,--version-script,$<,--no-undefined \
- 		-Wl,--whole-archive $(filter-out $<,$^) -Wl,--no-whole-archive\
--		-ldl $(zip_LIBS)
-+		-ldl $(zip_LIBS) $(libdw_so_LDLIBS)
- 	@$(textrel_check)
- 	ln -fs $@ $@.$(VERSION)
- 
-diff --git a/libelf/Makefile.am b/libelf/Makefile.am
-index afcb2aa..02836a1 100644
---- a/libelf/Makefile.am
-+++ b/libelf/Makefile.am
-@@ -93,7 +93,12 @@ libelf_a_SOURCES = elf_version.c elf_hash.c elf_error.c elf_fill.c \
- libelf_pic_a_SOURCES =
- am_libelf_pic_a_OBJECTS = $(libelf_a_SOURCES:.c=.os)
- 
-+
- libelf_so_LDLIBS =
-+if USE_UCLIBC
-+libelf_so_LDLIBS += -lintl -luargp
-+endif
-+
- if USE_LOCKS
- libelf_so_LDLIBS += -lpthread
- endif
--- 
-1.8.3.4
-
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-Ignore-differences-between-mips-machine-identifiers.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-Ignore-differences-between-mips-machine-identifiers.patch
new file mode 100644
index 0000000..3f110f9
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-Ignore-differences-between-mips-machine-identifiers.patch
@@ -0,0 +1,34 @@
+From 77cb4a53c270d5854d3af24f19547bc3de825233 Mon Sep 17 00:00:00 2001
+From: James Cowgill <james410@cowgill.org.uk>
+Date: Mon, 5 Jan 2015 15:16:58 +0000
+Subject: [PATCH 1/3] Ignore differences between mips machine identifiers
+
+Little endian binaries actually use EM_MIPS so you can't tell the endianness
+from the elf machine id. Also, the EM_MIPS_RS3_LE machine is dead anyway (the
+kernel will not load binaries containing it).
+
+Signed-off-by: James Cowgill <james410@cowgill.org.uk>
+---
+ backends/mips_init.c | 6 +-----
+ 1 file changed, 1 insertion(+), 5 deletions(-)
+
+diff --git a/backends/mips_init.c b/backends/mips_init.c
+index 7429a89..d10e940 100644
+--- a/backends/mips_init.c
++++ b/backends/mips_init.c
+@@ -46,11 +46,7 @@ mips_init (elf, machine, eh, ehlen)
+     return NULL;
+ 
+   /* We handle it.  */
+-  if (machine == EM_MIPS)
+-    eh->name = "MIPS R3000 big-endian";
+-  else if (machine == EM_MIPS_RS3_LE)
+-    eh->name = "MIPS R3000 little-endian";
+-
++  eh->name = "MIPS";
+   mips_init_reloc (eh);
+   HOOK (eh, reloc_simple_type);
+   HOOK (eh, return_value_location);
+-- 
+2.1.4
+
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-build-Provide-alternatives-for-glibc-assumptions-hel.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-build-Provide-alternatives-for-glibc-assumptions-hel.patch
new file mode 100644
index 0000000..c8d1c89
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-build-Provide-alternatives-for-glibc-assumptions-hel.patch
@@ -0,0 +1,1163 @@
+From 4b0fe80b3951f044c1c1b14d1d7f5f0b8ab67507 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 31 Dec 2015 06:35:34 +0000
+Subject: [PATCH] build: Provide alternatives for glibc assumptions helps
+ compiling it on musl
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ Makefile.am                      |  2 +-
+ lib/color.c                      |  2 +-
+ lib/crc32_file.c                 |  4 +++-
+ lib/fixedsizehash.h              |  4 ++--
+ lib/system.h                     | 11 +++++++++++
+ lib/xmalloc.c                    |  2 +-
+ libasm/asm_end.c                 |  2 +-
+ libasm/asm_newscn.c              |  2 +-
+ libcpu/i386_gendis.c             |  2 +-
+ libcpu/i386_lex.c                |  2 +-
+ libcpu/i386_parse.c              |  2 +-
+ libdw/Makefile.am                |  2 +-
+ libdw/libdw_alloc.c              |  3 ++-
+ libdwfl/Makefile.am              |  2 ++
+ libdwfl/dwfl_build_id_find_elf.c |  3 ++-
+ libdwfl/dwfl_error.c             |  4 +++-
+ libdwfl/dwfl_module_getdwarf.c   |  1 +
+ libdwfl/find-debuginfo.c         |  2 +-
+ libdwfl/libdwfl_crc32_file.c     | 10 ++++++++++
+ libdwfl/linux-kernel-modules.c   |  1 +
+ libebl/eblopenbackend.c          |  2 +-
+ libebl/eblwstrtab.c              |  2 +-
+ libelf/elf.h                     |  9 ++++++---
+ libelf/libelf.h                  |  1 +
+ libelf/libelfP.h                 |  1 +
+ src/addr2line.c                  |  2 +-
+ src/ar.c                         |  2 +-
+ src/arlib.c                      |  2 +-
+ src/arlib2.c                     |  2 +-
+ src/elfcmp.c                     |  2 +-
+ src/elflint.c                    |  2 +-
+ src/findtextrel.c                |  2 +-
+ src/i386_ld.c                    |  2 +-
+ src/ld.c                         |  2 +-
+ src/ldgeneric.c                  |  2 +-
+ src/ldlex.c                      |  2 +-
+ src/ldscript.c                   |  2 +-
+ src/nm.c                         |  2 +-
+ src/objdump.c                    |  2 +-
+ src/ranlib.c                     |  2 +-
+ src/readelf.c                    |  2 +-
+ src/size.c                       |  2 +-
+ src/stack.c                      |  2 +-
+ src/strings.c                    |  2 +-
+ src/strip.c                      |  2 +-
+ src/unstrip.c                    |  2 +-
+ tests/addrscopes.c               |  2 +-
+ tests/allregs.c                  |  2 +-
+ tests/backtrace-data.c           |  2 +-
+ tests/backtrace-dwarf.c          |  2 +-
+ tests/backtrace.c                |  2 +-
+ tests/buildid.c                  |  2 +-
+ tests/debugaltlink.c             |  2 +-
+ tests/debuglink.c                |  2 +-
+ tests/deleted.c                  |  2 +-
+ tests/dwfl-addr-sect.c           |  2 +-
+ tests/dwfl-bug-addr-overflow.c   |  2 +-
+ tests/dwfl-bug-fd-leak.c         |  2 +-
+ tests/dwfl-bug-getmodules.c      |  2 +-
+ tests/dwfl-report-elf-align.c    |  2 +-
+ tests/dwfllines.c                |  2 +-
+ tests/dwflmodtest.c              |  2 +-
+ tests/dwflsyms.c                 |  2 +-
+ tests/early-offscn.c             |  2 +-
+ tests/ecp.c                      |  2 +-
+ tests/find-prologues.c           |  2 +-
+ tests/funcretval.c               |  2 +-
+ tests/funcscopes.c               |  2 +-
+ tests/getsrc_die.c               |  2 +-
+ tests/line2addr.c                |  2 +-
+ tests/low_high_pc.c              |  2 +-
+ tests/md5-sha1-test.c            |  2 +-
+ tests/rdwrmmap.c                 |  2 +-
+ tests/saridx.c                   |  2 +-
+ tests/sectiondump.c              |  2 +-
+ tests/varlocs.c                  |  2 +-
+ tests/vdsosyms.c                 |  2 +-
+ 77 files changed, 109 insertions(+), 73 deletions(-)
+
+Index: elfutils-0.164/Makefile.am
+===================================================================
+--- elfutils-0.164.orig/Makefile.am
++++ elfutils-0.164/Makefile.am
+@@ -24,7 +24,7 @@ pkginclude_HEADERS = version.h
+ 
+ # Add doc back when we have some real content.
+ SUBDIRS = config m4 lib libelf libebl libdwelf libdwfl libdw libcpu libasm \
+-	  backends src po tests
++	  backends po tests
+ 
+ EXTRA_DIST = elfutils.spec GPG-KEY NOTES CONTRIBUTING \
+ 	     COPYING COPYING-GPLV2 COPYING-LGPLV3
+Index: elfutils-0.164/lib/color.c
+===================================================================
+--- elfutils-0.164.orig/lib/color.c
++++ elfutils-0.164/lib/color.c
+@@ -32,7 +32,7 @@
+ #endif
+ 
+ #include <argp.h>
+-#include <error.h>
++#include <err.h>
+ #include <libintl.h>
+ #include <stdlib.h>
+ #include <string.h>
+Index: elfutils-0.164/lib/crc32_file.c
+===================================================================
+--- elfutils-0.164.orig/lib/crc32_file.c
++++ elfutils-0.164/lib/crc32_file.c
+@@ -30,12 +30,14 @@
+ # include <config.h>
+ #endif
+ 
+-#include "system.h"
+ #include <errno.h>
+ #include <unistd.h>
++#include <stdint.h>
+ #include <sys/stat.h>
+ #include <sys/mman.h>
+ 
++#include "system.h"
++
+ int
+ crc32_file (int fd, uint32_t *resp)
+ {
+Index: elfutils-0.164/lib/fixedsizehash.h
+===================================================================
+--- elfutils-0.164.orig/lib/fixedsizehash.h
++++ elfutils-0.164/lib/fixedsizehash.h
+@@ -30,12 +30,12 @@
+ #include <errno.h>
+ #include <stdlib.h>
+ #include <string.h>
+-#include <sys/cdefs.h>
+ #include <sys/param.h>
+ 
+ #include <system.h>
+ 
+-#define CONCAT(t1,t2) __CONCAT (t1,t2)
++#define CONCAT1(x,y) x##y
++#define CONCAT(x,y) CONCAT1(x,y)
+ 
+ /* Before including this file the following macros must be defined:
+ 
+Index: elfutils-0.164/lib/system.h
+===================================================================
+--- elfutils-0.164.orig/lib/system.h
++++ elfutils-0.164/lib/system.h
+@@ -49,6 +49,16 @@
+ #else
+ # error "Unknown byte order"
+ #endif
++#ifndef TEMP_FAILURE_RETRY
++#define TEMP_FAILURE_RETRY(expression) \
++  (__extension__							      \
++    ({ long int __result;						      \
++       do __result = (long int) (expression);				      \
++       while (__result == -1L && errno == EINTR);			      \
++       __result; }))
++#endif
++
++#define error(status, errno, ...) err(status, __VA_ARGS__)
+ 
+ extern void *xmalloc (size_t) __attribute__ ((__malloc__));
+ extern void *xcalloc (size_t, size_t) __attribute__ ((__malloc__));
+Index: elfutils-0.164/lib/xmalloc.c
+===================================================================
+--- elfutils-0.164.orig/lib/xmalloc.c
++++ elfutils-0.164/lib/xmalloc.c
+@@ -30,7 +30,7 @@
+ # include <config.h>
+ #endif
+ 
+-#include <error.h>
++#include <err.h>
+ #include <libintl.h>
+ #include <stddef.h>
+ #include <stdlib.h>
+Index: elfutils-0.164/libasm/asm_end.c
+===================================================================
+--- elfutils-0.164.orig/libasm/asm_end.c
++++ elfutils-0.164/libasm/asm_end.c
+@@ -32,7 +32,7 @@
+ #endif
+ 
+ #include <assert.h>
+-#include <error.h>
++#include <err.h>
+ #include <libintl.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+Index: elfutils-0.164/libasm/asm_newscn.c
+===================================================================
+--- elfutils-0.164.orig/libasm/asm_newscn.c
++++ elfutils-0.164/libasm/asm_newscn.c
+@@ -32,7 +32,7 @@
+ #endif
+ 
+ #include <assert.h>
+-#include <error.h>
++#include <err.h>
+ #include <libintl.h>
+ #include <stdlib.h>
+ #include <string.h>
+Index: elfutils-0.164/libcpu/i386_gendis.c
+===================================================================
+--- elfutils-0.164.orig/libcpu/i386_gendis.c
++++ elfutils-0.164/libcpu/i386_gendis.c
+@@ -31,7 +31,7 @@
+ # include <config.h>
+ #endif
+ 
+-#include <error.h>
++#include <err.h>
+ #include <errno.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+Index: elfutils-0.164/libcpu/i386_lex.c
+===================================================================
+--- elfutils-0.164.orig/libcpu/i386_lex.c
++++ elfutils-0.164/libcpu/i386_lex.c
+@@ -571,7 +571,7 @@ char *i386_text;
+ #endif
+ 
+ #include <ctype.h>
+-#include <error.h>
++#include <err.h>
+ #include <libintl.h>
+ 
+ #include <system.h>
+Index: elfutils-0.164/libcpu/i386_parse.c
+===================================================================
+--- elfutils-0.164.orig/libcpu/i386_parse.c
++++ elfutils-0.164/libcpu/i386_parse.c
+@@ -107,7 +107,7 @@
+ #include <assert.h>
+ #include <ctype.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <inttypes.h>
+ #include <libintl.h>
+ #include <math.h>
+Index: elfutils-0.164/libdw/Makefile.am
+===================================================================
+--- elfutils-0.164.orig/libdw/Makefile.am
++++ elfutils-0.164/libdw/Makefile.am
+@@ -117,7 +117,7 @@ libdw.so$(EXEEXT): $(srcdir)/libdw.map l
+ 		-Wl,--enable-new-dtags,-rpath,$(pkglibdir) \
+ 		-Wl,--version-script,$<,--no-undefined \
+ 		-Wl,--whole-archive $(filter-out $<,$^) -Wl,--no-whole-archive\
+-		-ldl $(argp_LDADD) $(zip_LIBS) $(libdw_so_LDLIBS)
++		-ldl $(argp_LDADD) $(zip_LIBS) $(libdw_so_LDLIBS) -lfts -largp
+ 	@$(textrel_check)
+ 	$(AM_V_at)ln -fs $@ $@.$(VERSION)
+ 
+Index: elfutils-0.164/libdw/libdw_alloc.c
+===================================================================
+--- elfutils-0.164.orig/libdw/libdw_alloc.c
++++ elfutils-0.164/libdw/libdw_alloc.c
+@@ -31,11 +31,12 @@
+ # include <config.h>
+ #endif
+ 
+-#include <error.h>
++#include <err.h>
+ #include <errno.h>
+ #include <stdlib.h>
+ #include <sys/param.h>
+ #include "libdwP.h"
++#include "system.h"
+ 
+ 
+ void *
+Index: elfutils-0.164/libdwfl/Makefile.am
+===================================================================
+--- elfutils-0.164.orig/libdwfl/Makefile.am
++++ elfutils-0.164/libdwfl/Makefile.am
+@@ -86,6 +86,8 @@ libelf = ../libelf/libelf.so
+ libebl = ../libebl/libebl.a
+ libeu = ../lib/libeu.a
+ 
++LDADD = -lfts
++
+ libdwfl_pic_a_SOURCES =
+ am_libdwfl_pic_a_OBJECTS = $(libdwfl_a_SOURCES:.c=.os)
+ 
+Index: elfutils-0.164/libdwfl/dwfl_build_id_find_elf.c
+===================================================================
+--- elfutils-0.164.orig/libdwfl/dwfl_build_id_find_elf.c
++++ elfutils-0.164/libdwfl/dwfl_build_id_find_elf.c
+@@ -27,6 +27,7 @@
+    not, see <http://www.gnu.org/licenses/>.  */
+ 
+ #include "libdwflP.h"
++#include "system.h"
+ #include <inttypes.h>
+ #include <fcntl.h>
+ #include <unistd.h>
+@@ -94,7 +95,7 @@ __libdwfl_open_by_build_id (Dwfl_Module
+ 	{
+ 	  if (*file_name != NULL)
+ 	    free (*file_name);
+-	  *file_name = canonicalize_file_name (name);
++	  *file_name = realpath (name, NULL);
+ 	  if (*file_name == NULL)
+ 	    {
+ 	      *file_name = name;
+Index: elfutils-0.164/libdwfl/dwfl_error.c
+===================================================================
+--- elfutils-0.164.orig/libdwfl/dwfl_error.c
++++ elfutils-0.164/libdwfl/dwfl_error.c
+@@ -140,6 +140,7 @@ __libdwfl_seterrno (Dwfl_Error error)
+ const char *
+ dwfl_errmsg (int error)
+ {
++  static __thread char s[64] = "";
+   if (error == 0 || error == -1)
+     {
+       int last_error = global_error;
+@@ -154,7 +155,8 @@ dwfl_errmsg (int error)
+   switch (error &~ 0xffff)
+     {
+     case OTHER_ERROR (ERRNO):
+-      return strerror_r (error & 0xffff, "bad", 0);
++      strerror_r (error & 0xffff, s, sizeof(s));
++      return s;
+     case OTHER_ERROR (LIBELF):
+       return elf_errmsg (error & 0xffff);
+     case OTHER_ERROR (LIBDW):
+Index: elfutils-0.164/libdwfl/dwfl_module_getdwarf.c
+===================================================================
+--- elfutils-0.164.orig/libdwfl/dwfl_module_getdwarf.c
++++ elfutils-0.164/libdwfl/dwfl_module_getdwarf.c
+@@ -31,6 +31,7 @@
+ #include <fcntl.h>
+ #include <string.h>
+ #include <unistd.h>
++#include "system.h"
+ #include "../libdw/libdwP.h"	/* DWARF_E_* values are here.  */
+ #include "../libelf/libelfP.h"
+ 
+Index: elfutils-0.164/libdwfl/find-debuginfo.c
+===================================================================
+--- elfutils-0.164.orig/libdwfl/find-debuginfo.c
++++ elfutils-0.164/libdwfl/find-debuginfo.c
+@@ -372,7 +372,7 @@ dwfl_standard_find_debuginfo (Dwfl_Modul
+       /* If FILE_NAME is a symlink, the debug file might be associated
+ 	 with the symlink target name instead.  */
+ 
+-      char *canon = canonicalize_file_name (file_name);
++      char *canon = realpath (file_name, NULL);
+       if (canon != NULL && strcmp (file_name, canon))
+ 	fd = find_debuginfo_in_path (mod, canon,
+ 				     debuglink_file, debuglink_crc,
+Index: elfutils-0.164/libdwfl/libdwfl_crc32_file.c
+===================================================================
+--- elfutils-0.164.orig/libdwfl/libdwfl_crc32_file.c
++++ elfutils-0.164/libdwfl/libdwfl_crc32_file.c
+@@ -31,6 +31,16 @@
+ 
+ #define crc32_file attribute_hidden __libdwfl_crc32_file
+ #define crc32 __libdwfl_crc32
++
++#ifndef TEMP_FAILURE_RETRY
++#define TEMP_FAILURE_RETRY(expression) \
++  (__extension__							      \
++    ({ long int __result;						      \
++       do __result = (long int) (expression);				      \
++       while (__result == -1L && errno == EINTR);			      \
++       __result; }))
++#endif
++
+ #define LIB_SYSTEM_H	1
+ #include <libdwflP.h>
+ #include "../lib/crc32_file.c"
+Index: elfutils-0.164/libdwfl/linux-kernel-modules.c
+===================================================================
+--- elfutils-0.164.orig/libdwfl/linux-kernel-modules.c
++++ elfutils-0.164/libdwfl/linux-kernel-modules.c
+@@ -34,6 +34,7 @@
+ #include <config.h>
+ 
+ #include "libdwflP.h"
++#include "system.h"
+ #include <inttypes.h>
+ #include <errno.h>
+ #include <stdio.h>
+Index: elfutils-0.164/libebl/eblopenbackend.c
+===================================================================
+--- elfutils-0.164.orig/libebl/eblopenbackend.c
++++ elfutils-0.164/libebl/eblopenbackend.c
+@@ -32,7 +32,7 @@
+ 
+ #include <assert.h>
+ #include <dlfcn.h>
+-#include <error.h>
++#include <err.h>
+ #include <libelfP.h>
+ #include <dwarf.h>
+ #include <stdlib.h>
+Index: elfutils-0.164/libebl/eblwstrtab.c
+===================================================================
+--- elfutils-0.164.orig/libebl/eblwstrtab.c
++++ elfutils-0.164/libebl/eblwstrtab.c
+@@ -305,7 +305,7 @@ copystrings (struct Ebl_WStrent *nodep,
+ 
+   /* Process the current node.  */
+   nodep->offset = *offsetp;
+-  *freep = wmempcpy (*freep, nodep->string, nodep->len);
++  *freep = wmemcpy (*freep, nodep->string, nodep->len) + nodep->len;
+   *offsetp += nodep->len * sizeof (wchar_t);
+ 
+   for (subs = nodep->next; subs != NULL; subs = subs->next)
+Index: elfutils-0.164/libelf/elf.h
+===================================================================
+--- elfutils-0.164.orig/libelf/elf.h
++++ elfutils-0.164/libelf/elf.h
+@@ -21,7 +21,9 @@
+ 
+ #include <features.h>
+ 
+-__BEGIN_DECLS
++#ifdef __cplusplus
++extern "C" {
++#endif
+ 
+ /* Standard ELF types.  */
+ 
+@@ -3552,7 +3554,8 @@ enum
+ 
+ #define R_TILEGX_NUM		130
+ 
+-
+-__END_DECLS
++#ifdef __cplusplus
++}
++#endif
+ 
+ #endif	/* elf.h */
+Index: elfutils-0.164/libelf/libelf.h
+===================================================================
+--- elfutils-0.164.orig/libelf/libelf.h
++++ elfutils-0.164/libelf/libelf.h
+@@ -29,6 +29,7 @@
+ #ifndef _LIBELF_H
+ #define _LIBELF_H 1
+ 
++#include <fcntl.h>
+ #include <stdint.h>
+ #include <sys/types.h>
+ 
+Index: elfutils-0.164/libelf/libelfP.h
+===================================================================
+--- elfutils-0.164.orig/libelf/libelfP.h
++++ elfutils-0.164/libelf/libelfP.h
+@@ -36,6 +36,7 @@
+ 
+ #include <ar.h>
+ #include <gelf.h>
++#include <libelf.h>
+ 
+ #include <errno.h>
+ #include <stdint.h>
+Index: elfutils-0.164/src/addr2line.c
+===================================================================
+--- elfutils-0.164.orig/src/addr2line.c
++++ elfutils-0.164/src/addr2line.c
+@@ -23,7 +23,7 @@
+ #include <argp.h>
+ #include <assert.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <inttypes.h>
+ #include <libdwfl.h>
+Index: elfutils-0.164/src/ar.c
+===================================================================
+--- elfutils-0.164.orig/src/ar.c
++++ elfutils-0.164/src/ar.c
+@@ -22,7 +22,7 @@
+ 
+ #include <argp.h>
+ #include <assert.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <libintl.h>
+Index: elfutils-0.164/src/arlib.c
+===================================================================
+--- elfutils-0.164.orig/src/arlib.c
++++ elfutils-0.164/src/arlib.c
+@@ -21,7 +21,7 @@
+ #endif
+ 
+ #include <assert.h>
+-#include <error.h>
++#include <err.h>
+ #include <gelf.h>
+ #include <libintl.h>
+ #include <stdio.h>
+Index: elfutils-0.164/src/arlib2.c
+===================================================================
+--- elfutils-0.164.orig/src/arlib2.c
++++ elfutils-0.164/src/arlib2.c
+@@ -20,7 +20,7 @@
+ # include <config.h>
+ #endif
+ 
+-#include <error.h>
++#include <err.h>
+ #include <libintl.h>
+ #include <limits.h>
+ #include <string.h>
+Index: elfutils-0.164/src/elfcmp.c
+===================================================================
+--- elfutils-0.164.orig/src/elfcmp.c
++++ elfutils-0.164/src/elfcmp.c
+@@ -23,7 +23,7 @@
+ #include <argp.h>
+ #include <assert.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <locale.h>
+ #include <libintl.h>
+Index: elfutils-0.164/src/elflint.c
+===================================================================
+--- elfutils-0.164.orig/src/elflint.c
++++ elfutils-0.164/src/elflint.c
+@@ -24,7 +24,7 @@
+ #include <assert.h>
+ #include <byteswap.h>
+ #include <endian.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <inttypes.h>
+Index: elfutils-0.164/src/findtextrel.c
+===================================================================
+--- elfutils-0.164.orig/src/findtextrel.c
++++ elfutils-0.164/src/findtextrel.c
+@@ -23,7 +23,7 @@
+ #include <argp.h>
+ #include <assert.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <libdw.h>
+Index: elfutils-0.164/src/i386_ld.c
+===================================================================
+--- elfutils-0.164.orig/src/i386_ld.c
++++ elfutils-0.164/src/i386_ld.c
+@@ -20,7 +20,7 @@
+ #endif
+ 
+ #include <assert.h>
+-#include <error.h>
++#include <err.h>
+ #include <libintl.h>
+ #include <stdlib.h>
+ #include <string.h>
+Index: elfutils-0.164/src/ld.c
+===================================================================
+--- elfutils-0.164.orig/src/ld.c
++++ elfutils-0.164/src/ld.c
+@@ -21,7 +21,7 @@
+ 
+ #include <argp.h>
+ #include <assert.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <libelf.h>
+ #include <libintl.h>
+Index: elfutils-0.164/src/ldgeneric.c
+===================================================================
+--- elfutils-0.164.orig/src/ldgeneric.c
++++ elfutils-0.164/src/ldgeneric.c
+@@ -23,7 +23,7 @@
+ #include <ctype.h>
+ #include <dlfcn.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <fnmatch.h>
+ #include <gelf.h>
+Index: elfutils-0.164/src/ldlex.c
+===================================================================
+--- elfutils-0.164.orig/src/ldlex.c
++++ elfutils-0.164/src/ldlex.c
+@@ -1099,7 +1099,7 @@ char *ldtext;
+ #include <assert.h>
+ #include <ctype.h>
+ #include <elf.h>
+-#include <error.h>
++#include <err.h>
+ #include <inttypes.h>
+ #include <libintl.h>
+ #include <stdbool.h>
+Index: elfutils-0.164/src/ldscript.c
+===================================================================
+--- elfutils-0.164.orig/src/ldscript.c
++++ elfutils-0.164/src/ldscript.c
+@@ -95,7 +95,7 @@
+ #endif
+ 
+ #include <assert.h>
+-#include <error.h>
++#include <err.h>
+ #include <libintl.h>
+ #include <stdbool.h>
+ #include <stdint.h>
+Index: elfutils-0.164/src/nm.c
+===================================================================
+--- elfutils-0.164.orig/src/nm.c
++++ elfutils-0.164/src/nm.c
+@@ -26,7 +26,7 @@
+ #include <ctype.h>
+ #include <dwarf.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <inttypes.h>
+Index: elfutils-0.164/src/objdump.c
+===================================================================
+--- elfutils-0.164.orig/src/objdump.c
++++ elfutils-0.164/src/objdump.c
+@@ -21,7 +21,7 @@
+ #endif
+ 
+ #include <argp.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <inttypes.h>
+ #include <libintl.h>
+Index: elfutils-0.164/src/ranlib.c
+===================================================================
+--- elfutils-0.164.orig/src/ranlib.c
++++ elfutils-0.164/src/ranlib.c
+@@ -24,7 +24,7 @@
+ #include <argp.h>
+ #include <assert.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <libintl.h>
+Index: elfutils-0.164/src/readelf.c
+===================================================================
+--- elfutils-0.164.orig/src/readelf.c
++++ elfutils-0.164/src/readelf.c
+@@ -25,7 +25,7 @@
+ #include <ctype.h>
+ #include <dwarf.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <inttypes.h>
+Index: elfutils-0.164/src/size.c
+===================================================================
+--- elfutils-0.164.orig/src/size.c
++++ elfutils-0.164/src/size.c
+@@ -21,7 +21,7 @@
+ #endif
+ 
+ #include <argp.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <inttypes.h>
+Index: elfutils-0.164/src/stack.c
+===================================================================
+--- elfutils-0.164.orig/src/stack.c
++++ elfutils-0.164/src/stack.c
+@@ -18,7 +18,7 @@
+ #include <config.h>
+ #include <assert.h>
+ #include <argp.h>
+-#include <error.h>
++#include <err.h>
+ #include <stdlib.h>
+ #include <inttypes.h>
+ #include <stdio.h>
+Index: elfutils-0.164/src/strings.c
+===================================================================
+--- elfutils-0.164.orig/src/strings.c
++++ elfutils-0.164/src/strings.c
+@@ -25,7 +25,7 @@
+ #include <ctype.h>
+ #include <endian.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <inttypes.h>
+Index: elfutils-0.164/src/strip.c
+===================================================================
+--- elfutils-0.164.orig/src/strip.c
++++ elfutils-0.164/src/strip.c
+@@ -24,7 +24,7 @@
+ #include <assert.h>
+ #include <byteswap.h>
+ #include <endian.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <libelf.h>
+Index: elfutils-0.164/src/unstrip.c
+===================================================================
+--- elfutils-0.164.orig/src/unstrip.c
++++ elfutils-0.164/src/unstrip.c
+@@ -31,7 +31,7 @@
+ #include <argp.h>
+ #include <assert.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <fnmatch.h>
+ #include <libintl.h>
+Index: elfutils-0.164/tests/addrscopes.c
+===================================================================
+--- elfutils-0.164.orig/tests/addrscopes.c
++++ elfutils-0.164/tests/addrscopes.c
+@@ -25,7 +25,7 @@
+ #include <stdio_ext.h>
+ #include <locale.h>
+ #include <stdlib.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ 
+ 
+Index: elfutils-0.164/tests/allregs.c
+===================================================================
+--- elfutils-0.164.orig/tests/allregs.c
++++ elfutils-0.164/tests/allregs.c
+@@ -21,7 +21,7 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+-#include <error.h>
++#include <err.h>
+ #include <locale.h>
+ #include <argp.h>
+ #include <assert.h>
+Index: elfutils-0.164/tests/backtrace-data.c
+===================================================================
+--- elfutils-0.164.orig/tests/backtrace-data.c
++++ elfutils-0.164/tests/backtrace-data.c
+@@ -27,7 +27,7 @@
+ #include <dirent.h>
+ #include <stdlib.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <unistd.h>
+ #include <dwarf.h>
+ #if defined(__x86_64__) && defined(__linux__)
+Index: elfutils-0.164/tests/backtrace-dwarf.c
+===================================================================
+--- elfutils-0.164.orig/tests/backtrace-dwarf.c
++++ elfutils-0.164/tests/backtrace-dwarf.c
+@@ -22,7 +22,7 @@
+ #include <stdio_ext.h>
+ #include <locale.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <unistd.h>
+ #include <sys/ptrace.h>
+ #include <sys/types.h>
+Index: elfutils-0.164/tests/backtrace.c
+===================================================================
+--- elfutils-0.164.orig/tests/backtrace.c
++++ elfutils-0.164/tests/backtrace.c
+@@ -24,7 +24,7 @@
+ #include <dirent.h>
+ #include <stdlib.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <unistd.h>
+ #include <dwarf.h>
+ #ifdef __linux__
+Index: elfutils-0.164/tests/buildid.c
+===================================================================
+--- elfutils-0.164.orig/tests/buildid.c
++++ elfutils-0.164/tests/buildid.c
+@@ -23,7 +23,7 @@
+ #include ELFUTILS_HEADER(elf)
+ #include ELFUTILS_HEADER(dwelf)
+ #include <stdio.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ #include <stdlib.h>
+ #include <sys/types.h>
+Index: elfutils-0.164/tests/debugaltlink.c
+===================================================================
+--- elfutils-0.164.orig/tests/debugaltlink.c
++++ elfutils-0.164/tests/debugaltlink.c
+@@ -23,7 +23,7 @@
+ #include ELFUTILS_HEADER(dw)
+ #include ELFUTILS_HEADER(dwelf)
+ #include <stdio.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ #include <stdlib.h>
+ #include <sys/types.h>
+Index: elfutils-0.164/tests/debuglink.c
+===================================================================
+--- elfutils-0.164.orig/tests/debuglink.c
++++ elfutils-0.164/tests/debuglink.c
+@@ -21,7 +21,7 @@
+ #include <errno.h>
+ #include ELFUTILS_HEADER(dwelf)
+ #include <stdio.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ #include <stdlib.h>
+ #include <sys/types.h>
+Index: elfutils-0.164/tests/deleted.c
+===================================================================
+--- elfutils-0.164.orig/tests/deleted.c
++++ elfutils-0.164/tests/deleted.c
+@@ -21,7 +21,7 @@
+ #include <unistd.h>
+ #include <assert.h>
+ #include <stdio.h>
+-#include <error.h>
++#include <err.h>
+ #include <errno.h>
+ #ifdef __linux__
+ #include <sys/prctl.h>
+Index: elfutils-0.164/tests/dwfl-addr-sect.c
+===================================================================
+--- elfutils-0.164.orig/tests/dwfl-addr-sect.c
++++ elfutils-0.164/tests/dwfl-addr-sect.c
+@@ -23,7 +23,7 @@
+ #include <stdio_ext.h>
+ #include <stdlib.h>
+ #include <string.h>
+-#include <error.h>
++#include <err.h>
+ #include <locale.h>
+ #include <argp.h>
+ #include ELFUTILS_HEADER(dwfl)
+Index: elfutils-0.164/tests/dwfl-bug-addr-overflow.c
+===================================================================
+--- elfutils-0.164.orig/tests/dwfl-bug-addr-overflow.c
++++ elfutils-0.164/tests/dwfl-bug-addr-overflow.c
+@@ -20,7 +20,7 @@
+ #include <inttypes.h>
+ #include <stdio.h>
+ #include <stdio_ext.h>
+-#include <error.h>
++#include <err.h>
+ #include <locale.h>
+ #include ELFUTILS_HEADER(dwfl)
+ 
+Index: elfutils-0.164/tests/dwfl-bug-fd-leak.c
+===================================================================
+--- elfutils-0.164.orig/tests/dwfl-bug-fd-leak.c
++++ elfutils-0.164/tests/dwfl-bug-fd-leak.c
+@@ -24,7 +24,7 @@
+ #include <dirent.h>
+ #include <stdlib.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <unistd.h>
+ #include <dwarf.h>
+ #include <sys/resource.h>
+Index: elfutils-0.164/tests/dwfl-bug-getmodules.c
+===================================================================
+--- elfutils-0.164.orig/tests/dwfl-bug-getmodules.c
++++ elfutils-0.164/tests/dwfl-bug-getmodules.c
+@@ -18,7 +18,7 @@
+ #include <config.h>
+ #include ELFUTILS_HEADER(dwfl)
+ 
+-#include <error.h>
++#include <err.h>
+ 
+ static const Dwfl_Callbacks callbacks =
+   {
+Index: elfutils-0.164/tests/dwfl-report-elf-align.c
+===================================================================
+--- elfutils-0.164.orig/tests/dwfl-report-elf-align.c
++++ elfutils-0.164/tests/dwfl-report-elf-align.c
+@@ -20,7 +20,7 @@
+ #include <inttypes.h>
+ #include <stdio.h>
+ #include <stdio_ext.h>
+-#include <error.h>
++#include <err.h>
+ #include <locale.h>
+ #include <string.h>
+ #include <stdlib.h>
+Index: elfutils-0.164/tests/dwfllines.c
+===================================================================
+--- elfutils-0.164.orig/tests/dwfllines.c
++++ elfutils-0.164/tests/dwfllines.c
+@@ -27,7 +27,7 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+-#include <error.h>
++#include <err.h>
+ 
+ int
+ main (int argc, char *argv[])
+Index: elfutils-0.164/tests/dwflmodtest.c
+===================================================================
+--- elfutils-0.164.orig/tests/dwflmodtest.c
++++ elfutils-0.164/tests/dwflmodtest.c
+@@ -23,7 +23,7 @@
+ #include <stdio_ext.h>
+ #include <stdlib.h>
+ #include <string.h>
+-#include <error.h>
++#include <err.h>
+ #include <locale.h>
+ #include <argp.h>
+ #include ELFUTILS_HEADER(dwfl)
+Index: elfutils-0.164/tests/dwflsyms.c
+===================================================================
+--- elfutils-0.164.orig/tests/dwflsyms.c
++++ elfutils-0.164/tests/dwflsyms.c
+@@ -25,7 +25,7 @@
+ #include <stdio.h>
+ #include <stdio_ext.h>
+ #include <stdlib.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ 
+ static const char *
+Index: elfutils-0.164/tests/early-offscn.c
+===================================================================
+--- elfutils-0.164.orig/tests/early-offscn.c
++++ elfutils-0.164/tests/early-offscn.c
+@@ -19,7 +19,7 @@
+ #endif
+ 
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <stdio.h>
+Index: elfutils-0.164/tests/ecp.c
+===================================================================
+--- elfutils-0.164.orig/tests/ecp.c
++++ elfutils-0.164/tests/ecp.c
+@@ -20,7 +20,7 @@
+ #endif
+ 
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <stdlib.h>
+Index: elfutils-0.164/tests/find-prologues.c
+===================================================================
+--- elfutils-0.164.orig/tests/find-prologues.c
++++ elfutils-0.164/tests/find-prologues.c
+@@ -25,7 +25,7 @@
+ #include <stdio_ext.h>
+ #include <locale.h>
+ #include <stdlib.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ #include <fnmatch.h>
+ 
+Index: elfutils-0.164/tests/funcretval.c
+===================================================================
+--- elfutils-0.164.orig/tests/funcretval.c
++++ elfutils-0.164/tests/funcretval.c
+@@ -25,7 +25,7 @@
+ #include <stdio_ext.h>
+ #include <locale.h>
+ #include <stdlib.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ #include <fnmatch.h>
+ 
+Index: elfutils-0.164/tests/funcscopes.c
+===================================================================
+--- elfutils-0.164.orig/tests/funcscopes.c
++++ elfutils-0.164/tests/funcscopes.c
+@@ -25,7 +25,7 @@
+ #include <stdio_ext.h>
+ #include <locale.h>
+ #include <stdlib.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ #include <fnmatch.h>
+ 
+Index: elfutils-0.164/tests/getsrc_die.c
+===================================================================
+--- elfutils-0.164.orig/tests/getsrc_die.c
++++ elfutils-0.164/tests/getsrc_die.c
+@@ -19,7 +19,7 @@
+ #endif
+ 
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <inttypes.h>
+ #include <libelf.h>
+Index: elfutils-0.164/tests/line2addr.c
+===================================================================
+--- elfutils-0.164.orig/tests/line2addr.c
++++ elfutils-0.164/tests/line2addr.c
+@@ -26,7 +26,7 @@
+ #include <locale.h>
+ #include <stdlib.h>
+ #include <string.h>
+-#include <error.h>
++#include <err.h>
+ 
+ 
+ static void
+Index: elfutils-0.164/tests/low_high_pc.c
+===================================================================
+--- elfutils-0.164.orig/tests/low_high_pc.c
++++ elfutils-0.164/tests/low_high_pc.c
+@@ -25,7 +25,7 @@
+ #include <stdio_ext.h>
+ #include <locale.h>
+ #include <stdlib.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ #include <fnmatch.h>
+ 
+Index: elfutils-0.164/tests/md5-sha1-test.c
+===================================================================
+--- elfutils-0.164.orig/tests/md5-sha1-test.c
++++ elfutils-0.164/tests/md5-sha1-test.c
+@@ -19,7 +19,7 @@
+ #endif
+ 
+ #include <string.h>
+-#include <error.h>
++#include <err.h>
+ 
+ #include "md5.h"
+ #include "sha1.h"
+Index: elfutils-0.164/tests/rdwrmmap.c
+===================================================================
+--- elfutils-0.164.orig/tests/rdwrmmap.c
++++ elfutils-0.164/tests/rdwrmmap.c
+@@ -19,7 +19,7 @@
+ #endif
+ 
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <stdio.h>
+ #include <fcntl.h>
+ #include <unistd.h>
+Index: elfutils-0.164/tests/saridx.c
+===================================================================
+--- elfutils-0.164.orig/tests/saridx.c
++++ elfutils-0.164/tests/saridx.c
+@@ -17,7 +17,7 @@
+ 
+ #include <config.h>
+ 
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <stdio.h>
+Index: elfutils-0.164/tests/sectiondump.c
+===================================================================
+--- elfutils-0.164.orig/tests/sectiondump.c
++++ elfutils-0.164/tests/sectiondump.c
+@@ -18,7 +18,7 @@
+ #include <config.h>
+ 
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <fcntl.h>
+ #include <gelf.h>
+ #include <inttypes.h>
+Index: elfutils-0.164/tests/varlocs.c
+===================================================================
+--- elfutils-0.164.orig/tests/varlocs.c
++++ elfutils-0.164/tests/varlocs.c
+@@ -25,7 +25,7 @@
+ #include <dwarf.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+-#include <error.h>
++#include <err.h>
+ #include <string.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
+Index: elfutils-0.164/tests/vdsosyms.c
+===================================================================
+--- elfutils-0.164.orig/tests/vdsosyms.c
++++ elfutils-0.164/tests/vdsosyms.c
+@@ -18,7 +18,7 @@
+ #include <config.h>
+ #include <assert.h>
+ #include <errno.h>
+-#include <error.h>
++#include <err.h>
+ #include <inttypes.h>
+ #include <stdio.h>
+ #include <string.h>
+Index: elfutils-0.164/libelf/elf_getarsym.c
+===================================================================
+--- elfutils-0.164.orig/libelf/elf_getarsym.c
++++ elfutils-0.164/libelf/elf_getarsym.c
+@@ -302,7 +302,7 @@ elf_getarsym (Elf *elf, size_t *ptr)
+ 		arsym[cnt].as_off = (*u32)[cnt];
+ 
+ 	      arsym[cnt].as_hash = _dl_elf_hash (str_data);
+-	      str_data = rawmemchr (str_data, '\0') + 1;
++	      str_data = memchr (str_data, '\0', SIZE_MAX) + 1;
+ 	    }
+ 
+ 	  /* At the end a special entry.  */
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/0001-elf_getarsym-Silence-Werror-maybe-uninitialized-fals.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-elf_getarsym-Silence-Werror-maybe-uninitialized-fals.patch
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/0001-elf_getarsym-Silence-Werror-maybe-uninitialized-fals.patch
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-elf_getarsym-Silence-Werror-maybe-uninitialized-fals.patch
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/0001-fix-a-stack-usage-warning.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-fix-a-stack-usage-warning.patch
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/0001-fix-a-stack-usage-warning.patch
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-fix-a-stack-usage-warning.patch
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/0001-remove-the-unneed-checking.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-remove-the-unneed-checking.patch
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/0001-remove-the-unneed-checking.patch
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0001-remove-the-unneed-checking.patch
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch
new file mode 100644
index 0000000..72125c9
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0002-Add-support-for-mips64-abis-in-mips_retval.c.patch
@@ -0,0 +1,168 @@
+From fdaab18a65ed2529656baa64cb6169f34d7e507b Mon Sep 17 00:00:00 2001
+From: James Cowgill <james410@cowgill.org.uk>
+Date: Mon, 5 Jan 2015 15:17:01 +0000
+Subject: [PATCH 2/3] Add support for mips64 abis in mips_retval.c
+
+Signed-off-by: James Cowgill <james410@cowgill.org.uk>
+---
+ backends/mips_retval.c | 104 ++++++++++++++++++++++++++++++++++++++++++++-----
+ 1 file changed, 94 insertions(+), 10 deletions(-)
+
+diff --git a/backends/mips_retval.c b/backends/mips_retval.c
+index 33f12a7..d5c6ef0 100644
+--- a/backends/mips_retval.c
++++ b/backends/mips_retval.c
+@@ -91,6 +91,8 @@ enum mips_abi find_mips_abi(Elf *elf)
+     default:
+       if ((elf_flags & EF_MIPS_ABI2))
+ 	return MIPS_ABI_N32;
++      else if ((ehdr->e_ident[EI_CLASS] == ELFCLASS64))
++	return MIPS_ABI_N64;
+     }
+ 
+   /* GCC creates a pseudo-section whose name describes the ABI.  */
+@@ -195,6 +197,57 @@ static const Dwarf_Op loc_aggregate[] =
+   };
+ #define nloc_aggregate 1
+ 
++/* Test if a struct member is a float */
++static int is_float_child(Dwarf_Die *childdie)
++{
++  /* Test if this is actually a struct member */
++  if (dwarf_tag(childdie) != DW_TAG_member)
++    return 0;
++
++  /* Get type of member */
++  Dwarf_Attribute attr_mem;
++  Dwarf_Die child_type_mem;
++  Dwarf_Die *child_typedie =
++    dwarf_formref_die(dwarf_attr_integrate(childdie,
++                                           DW_AT_type,
++                                           &attr_mem), &child_type_mem);
++
++  if (dwarf_tag(child_typedie) != DW_TAG_base_type)
++    return 0;
++
++  /* Get base subtype */
++  Dwarf_Word encoding;
++  if (dwarf_formudata (dwarf_attr_integrate (child_typedie,
++                                             DW_AT_encoding,
++                                             &attr_mem), &encoding) != 0)
++    return 0;
++
++  return encoding == DW_ATE_float;
++}
++
++/* Returns the number of fpregs which can be returned in the given struct */
++static int get_struct_fpregs(Dwarf_Die *structtypedie)
++{
++  Dwarf_Die child_mem;
++  int fpregs = 0;
++
++  /* Get first structure member */
++  if (dwarf_child(structtypedie, &child_mem) != 0)
++    return 0;
++
++  do
++    {
++      /* Ensure this register is a float */
++      if (!is_float_child(&child_mem))
++        return 0;
++
++      fpregs++;
++    }
++  while (dwarf_siblingof (&child_mem, &child_mem) == 0);
++
++  return fpregs;
++}
++
+ int
+ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+ {
+@@ -240,6 +293,7 @@ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+       tag = dwarf_tag (typedie);
+     }
+ 
++  Dwarf_Word size;
+   switch (tag)
+     {
+     case -1:
+@@ -258,8 +312,6 @@ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+     case DW_TAG_enumeration_type:
+     case DW_TAG_pointer_type:
+     case DW_TAG_ptr_to_member_type:
+-      {
+-        Dwarf_Word size;
+ 	if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_byte_size,
+ 					 &attr_mem), &size) != 0)
+ 	  {
+@@ -289,7 +341,7 @@ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+ 		if (size <= 4*regsize && abi == MIPS_ABI_O32)
+                   return nloc_fpregquad;
+ 
+-		goto aggregate;
++		goto large;
+ 	      }
+ 	  }
+ 	*locp = ABI_LOC(loc_intreg, regsize);
+@@ -298,18 +350,50 @@ mips_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+ 	if (size <= 2*regsize)
+ 	  return nloc_intregpair;
+ 
+-	/* Else fall through. Shouldn't happen though (at least with gcc) */
+-      }
++	/* Else pass in memory. Shouldn't happen though (at least with gcc) */
++	goto large;
+ 
+     case DW_TAG_structure_type:
+     case DW_TAG_class_type:
+     case DW_TAG_union_type:
+-    case DW_TAG_array_type:
+-    aggregate:
+-      /* XXX TODO: Can't handle structure return with other ABI's yet :-/ */
+-      if ((abi != MIPS_ABI_O32) && (abi != MIPS_ABI_O64))
+-        return -2;
++      /* Handle special cases for structures <= 128 bytes in newer ABIs */
++      if (abi == MIPS_ABI_EABI32 || abi == MIPS_ABI_EABI64 ||
++          abi == MIPS_ABI_N32 || abi == MIPS_ABI_N64)
++        {
++          if (dwarf_aggregate_size (typedie, &size) == 0 && size <= 16)
++            {
++              /*
++               * Special case in N64 / N32 -
++               * structures containing only floats are returned in fp regs.
++               * Everything else is returned in integer regs.
++               */
++              if (tag != DW_TAG_union_type &&
++                  (abi == MIPS_ABI_N32 || abi == MIPS_ABI_N64))
++                {
++                  int num_fpregs = get_struct_fpregs(typedie);
++                  if (num_fpregs == 1 || num_fpregs == 2)
++                    {
++                      *locp = loc_fpreg;
++                      if (num_fpregs == 1)
++                        return nloc_fpreg;
++                      else
++                        return nloc_fpregpair;
++                    }
++                }
++
++              *locp = loc_intreg;
++              if (size <= 8)
++                return nloc_intreg;
++              else
++                return nloc_intregpair;
++            }
++        }
++
++      /* Fallthrough to handle large types */
+ 
++    case DW_TAG_array_type:
++    large:
++      /* Return large structures in memory */
+       *locp = loc_aggregate;
+       return nloc_aggregate;
+     }
+-- 
+2.1.4
+
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0003-Add-mips-n64-relocation-format-hack.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0003-Add-mips-n64-relocation-format-hack.patch
new file mode 100644
index 0000000..14b7985
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/0003-Add-mips-n64-relocation-format-hack.patch
@@ -0,0 +1,226 @@
+From 59d4b8c48e5040af7e02b34eb26ea602ec82a38e Mon Sep 17 00:00:00 2001
+From: James Cowgill <james410@cowgill.org.uk>
+Date: Mon, 5 Jan 2015 15:17:02 +0000
+Subject: [PATCH 3/3] Add mips n64 relocation format hack
+
+MIPSEL N64 ELF files use a slightly different format for storing relocation
+entries which is incompatible with the normal R_SYM / R_INFO macros.
+To workaround this, we rearrange the bytes in the relocation's r_info field
+when reading and writing the relocations.
+
+This patch also ensures that strip.c sets the correct value of e_machine
+before manipulating relocations so that these changes take effect.
+
+Signed-off-by: James Cowgill <james410@cowgill.org.uk>
+---
+ libelf/gelf_getrel.c      | 25 +++++++++++++++++++++++--
+ libelf/gelf_getrela.c     | 25 +++++++++++++++++++++++--
+ libelf/gelf_update_rel.c  | 20 +++++++++++++++++++-
+ libelf/gelf_update_rela.c | 20 +++++++++++++++++++-
+ src/strip.c               | 17 +++++++++++++++++
+ 5 files changed, 101 insertions(+), 6 deletions(-)
+
+Index: elfutils-0.164/libelf/gelf_getrel.c
+===================================================================
+--- elfutils-0.164.orig/libelf/gelf_getrel.c
++++ elfutils-0.164/libelf/gelf_getrel.c
+@@ -36,6 +36,7 @@
+ 
+ #include "libelfP.h"
+ 
++#define EF_MIPS_ABI	0x0000F000
+ 
+ GElf_Rel *
+ gelf_getrel (Elf_Data *data, int ndx, GElf_Rel *dst)
+@@ -89,8 +90,28 @@ gelf_getrel (Elf_Data *data, int ndx, GE
+ 	  result = NULL;
+ 	}
+       else
+-	result = memcpy (dst, &((Elf64_Rel *) data_scn->d.d_buf)[ndx],
+-			 sizeof (Elf64_Rel));
++        {
++          GElf_Ehdr hdr;
++          result = memcpy (dst, &((Elf64_Rel *) data_scn->d.d_buf)[ndx],
++                           sizeof (Elf64_Rel));
++
++          if (gelf_getehdr(scn->elf, &hdr) != NULL &&
++              hdr.e_ident[EI_DATA] == ELFDATA2LSB &&
++              hdr.e_machine == EM_MIPS &&
++              (hdr.e_flags & EF_MIPS_ABI) == 0)
++            {
++              /*
++               * The relocation format is mangled on MIPSEL N64
++               *  We'll adjust it so at least R_SYM will work on it
++               */
++              GElf_Xword r_info = dst->r_info;
++              dst->r_info = (r_info << 32) |
++                            ((r_info >> 8) & 0xFF000000) |
++                            ((r_info >> 24) & 0x00FF0000) |
++                            ((r_info >> 40) & 0x0000FF00) |
++                            ((r_info >> 56) & 0x000000FF);
++            }
++        }
+     }
+ 
+   rwlock_unlock (scn->elf->lock);
+Index: elfutils-0.164/libelf/gelf_getrela.c
+===================================================================
+--- elfutils-0.164.orig/libelf/gelf_getrela.c
++++ elfutils-0.164/libelf/gelf_getrela.c
+@@ -36,6 +36,7 @@
+ 
+ #include "libelfP.h"
+ 
++#define EF_MIPS_ABI	0x0000F000
+ 
+ GElf_Rela *
+ gelf_getrela (Elf_Data *data, int ndx, GElf_Rela *dst)
+@@ -90,8 +91,28 @@ gelf_getrela (Elf_Data *data, int ndx, G
+ 	  result = NULL;
+ 	}
+       else
+-	result = memcpy (dst, &((Elf64_Rela *) data_scn->d.d_buf)[ndx],
+-			 sizeof (Elf64_Rela));
++        {
++          GElf_Ehdr hdr;
++          result = memcpy (dst, &((Elf64_Rela *) data_scn->d.d_buf)[ndx],
++                           sizeof (Elf64_Rela));
++
++          if (gelf_getehdr(scn->elf, &hdr) != NULL &&
++              hdr.e_ident[EI_DATA] == ELFDATA2LSB &&
++              hdr.e_machine == EM_MIPS &&
++              (hdr.e_flags & EF_MIPS_ABI) == 0)
++            {
++              /*
++               * The relocation format is mangled on MIPSEL N64
++               *  We'll adjust it so at least R_SYM will work on it
++               */
++              GElf_Xword r_info = dst->r_info;
++              dst->r_info = (r_info << 32) |
++                            ((r_info >> 8) & 0xFF000000) |
++                            ((r_info >> 24) & 0x00FF0000) |
++                            ((r_info >> 40) & 0x0000FF00) |
++                            ((r_info >> 56) & 0x000000FF);
++            }
++        }
+     }
+ 
+   rwlock_unlock (scn->elf->lock);
+Index: elfutils-0.164/libelf/gelf_update_rel.c
+===================================================================
+--- elfutils-0.164.orig/libelf/gelf_update_rel.c
++++ elfutils-0.164/libelf/gelf_update_rel.c
+@@ -36,6 +36,7 @@
+ 
+ #include "libelfP.h"
+ 
++#define EF_MIPS_ABI	0x0000F000
+ 
+ int
+ gelf_update_rel (Elf_Data *dst, int ndx, GElf_Rel *src)
+@@ -86,6 +87,9 @@ gelf_update_rel (Elf_Data *dst, int ndx,
+     }
+   else
+     {
++      GElf_Ehdr hdr;
++      GElf_Rel value = *src;
++
+       /* Check whether we have to resize the data buffer.  */
+       if (INVALID_NDX (ndx, Elf64_Rel, &data_scn->d))
+ 	{
+@@ -93,7 +97,21 @@ gelf_update_rel (Elf_Data *dst, int ndx,
+ 	  goto out;
+ 	}
+ 
+-      ((Elf64_Rel *) data_scn->d.d_buf)[ndx] = *src;
++      if (gelf_getehdr(scn->elf, &hdr) != NULL &&
++          hdr.e_ident[EI_DATA] == ELFDATA2LSB &&
++          hdr.e_machine == EM_MIPS &&
++          (hdr.e_flags & EF_MIPS_ABI) == 0)
++        {
++          /* Undo the MIPSEL N64 hack from gelf_getrel */
++          GElf_Xword r_info = value.r_info;
++          value.r_info = (r_info >> 32) |
++                         ((r_info << 8) &  0x000000FF00000000) |
++                         ((r_info << 24) & 0x0000FF0000000000) |
++                         ((r_info << 40) & 0x00FF000000000000) |
++                         ((r_info << 56) & 0xFF00000000000000);
++        }
++
++      ((Elf64_Rel *) data_scn->d.d_buf)[ndx] = value;
+     }
+ 
+   result = 1;
+Index: elfutils-0.164/libelf/gelf_update_rela.c
+===================================================================
+--- elfutils-0.164.orig/libelf/gelf_update_rela.c
++++ elfutils-0.164/libelf/gelf_update_rela.c
+@@ -36,6 +36,7 @@
+ 
+ #include "libelfP.h"
+ 
++#define EF_MIPS_ABI	0x0000F000
+ 
+ int
+ gelf_update_rela (Elf_Data *dst, int ndx, GElf_Rela *src)
+@@ -89,6 +90,9 @@ gelf_update_rela (Elf_Data *dst, int ndx
+     }
+   else
+     {
++      GElf_Ehdr hdr;
++      GElf_Rela value = *src;
++
+       /* Check whether we have to resize the data buffer.  */
+       if (INVALID_NDX (ndx, Elf64_Rela, &data_scn->d))
+ 	{
+@@ -96,7 +100,21 @@ gelf_update_rela (Elf_Data *dst, int ndx
+ 	  goto out;
+ 	}
+ 
+-      ((Elf64_Rela *) data_scn->d.d_buf)[ndx] = *src;
++      if (gelf_getehdr(scn->elf, &hdr) != NULL &&
++          hdr.e_ident[EI_DATA] == ELFDATA2LSB &&
++          hdr.e_machine == EM_MIPS &&
++          (hdr.e_flags & EF_MIPS_ABI) == 0)
++        {
++          /* Undo the MIPSEL N64 hack from gelf_getrel */
++          GElf_Xword r_info = value.r_info;
++          value.r_info = (r_info >> 32) |
++                         ((r_info << 8) &  0x000000FF00000000) |
++                         ((r_info << 24) & 0x0000FF0000000000) |
++                         ((r_info << 40) & 0x00FF000000000000) |
++                         ((r_info << 56) & 0xFF00000000000000);
++        }
++
++      ((Elf64_Rela *) data_scn->d.d_buf)[ndx] = value;
+     }
+ 
+   result = 1;
+Index: elfutils-0.164/src/strip.c
+===================================================================
+--- elfutils-0.164.orig/src/strip.c
++++ elfutils-0.164/src/strip.c
+@@ -546,6 +546,23 @@ handle_elf (int fd, Elf *elf, const char
+       goto fail;
+     }
+ 
++  /* Copy identity part of the ELF header now */
++  newehdr = gelf_getehdr (newelf, &newehdr_mem);
++  if (newehdr == NULL)
++    INTERNAL_ERROR (fname);
++
++  memcpy (newehdr->e_ident, ehdr->e_ident, EI_NIDENT);
++  newehdr->e_type = ehdr->e_type;
++  newehdr->e_machine = ehdr->e_machine;
++  newehdr->e_version = ehdr->e_version;
++
++  if (gelf_update_ehdr (newelf, newehdr) == 0)
++    {
++      error (0, 0, gettext ("%s: error while creating ELF header: %s"),
++	     fname, elf_errmsg (-1));
++      return 1;
++    }
++
+   /* Copy over the old program header if needed.  */
+   if (ehdr->e_type != ET_REL)
+     for (cnt = 0; cnt < phnum; ++cnt)
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/aarch64_uio.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/aarch64_uio.patch
new file mode 100644
index 0000000..38dc57b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/aarch64_uio.patch
@@ -0,0 +1,47 @@
+Fix build on aarch64/musl
+
+Errors
+
+invalid operands to binary & (have 'long double' and 'unsigned int')
+
+error: redefinition
+ of 'struct iovec'
+ struct iovec { void *iov_base; size_t iov_len; };
+        ^
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Index: elfutils-0.163/backends/aarch64_initreg.c
+===================================================================
+--- elfutils-0.163.orig/backends/aarch64_initreg.c
++++ elfutils-0.163/backends/aarch64_initreg.c
+@@ -33,7 +33,7 @@
+ #include "system.h"
+ #include <assert.h>
+ #ifdef __aarch64__
+-# include <linux/uio.h>
++# include <sys/uio.h>
+ # include <sys/user.h>
+ # include <sys/ptrace.h>
+ /* Deal with old glibc defining user_pt_regs instead of user_regs_struct.  */
+@@ -82,7 +82,7 @@ aarch64_set_initial_registers_tid (pid_t
+ 
+   Dwarf_Word dwarf_fregs[32];
+   for (int r = 0; r < 32; r++)
+-    dwarf_fregs[r] = fregs.vregs[r] & 0xFFFFFFFF;
++    dwarf_fregs[r] = (unsigned int)fregs.vregs[r] & 0xFFFFFFFF;
+ 
+   if (! setfunc (64, 32, dwarf_fregs, arg))
+     return false;
+Index: elfutils-0.163/backends/arm_initreg.c
+===================================================================
+--- elfutils-0.163.orig/backends/arm_initreg.c
++++ elfutils-0.163/backends/arm_initreg.c
+@@ -37,7 +37,7 @@
+ #endif
+ 
+ #ifdef __aarch64__
+-# include <linux/uio.h>
++# include <sys/uio.h>
+ # include <sys/user.h>
+ # include <sys/ptrace.h>
+ /* Deal with old glibc defining user_pt_regs instead of user_regs_struct.  */
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/arm_backend.diff b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/arm_backend.diff
similarity index 82%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/arm_backend.diff
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/arm_backend.diff
index c97c4e4..9d47f95 100644
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/arm_backend.diff
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/arm_backend.diff
@@ -1,26 +1,8 @@
-From 0db1687eee0b4d16ccbc40db5a06b574fca6614c Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Fri, 14 Nov 2014 15:25:42 +0800
-Subject: [PATCH] Rebase arm_backend.diff from 0.159 to 0.160
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- backends/arm_init.c                 |  18 ++++-
- backends/arm_regs.c                 | 132 ++++++++++++++++++++++++++++++++++++
- backends/arm_retval.c               |  44 +++++++++++-
- backends/libebl_arm.h               |   9 +++
- libelf/elf.h                        |  11 +++
- tests/run-addrcfi.sh                |  93 ++++++++++++++++++++++++-
- tests/run-allregs.sh                |  95 +++++++++++++++++++++++++-
- tests/run-readelf-mixed-corenote.sh |  11 ++-
- 8 files changed, 401 insertions(+), 12 deletions(-)
- create mode 100644 backends/libebl_arm.h
-
-diff --git a/backends/arm_init.c b/backends/arm_init.c
-index 3283c97..8b57d3f 100644
---- a/backends/arm_init.c
-+++ b/backends/arm_init.c
-@@ -35,21 +35,32 @@
+Index: elfutils-0.164/backends/arm_init.c
+===================================================================
+--- elfutils-0.164.orig/backends/arm_init.c
++++ elfutils-0.164/backends/arm_init.c
+@@ -35,20 +35,31 @@
  #define RELOC_PREFIX	R_ARM_
  #include "libebl_CPU.h"
  
@@ -31,12 +13,11 @@
  
  
  const char *
- arm_init (elf, machine, eh, ehlen)
--     Elf *elf __attribute__ ((unused));
-+     Elf *elf;
-      GElf_Half machine __attribute__ ((unused));
-      Ebl *eh;
-      size_t ehlen;
+-arm_init (Elf *elf __attribute__ ((unused)),
++arm_init (Elf *elf,
+ 	  GElf_Half machine __attribute__ ((unused)),
+ 	  Ebl *eh,
+ 	  size_t ehlen)
  {
 +  int soft_float = 0;
 +
@@ -54,7 +35,7 @@
    /* We handle it.  */
    eh->name = "ARM";
    arm_init_reloc (eh);
-@@ -61,7 +72,10 @@ arm_init (elf, machine, eh, ehlen)
+@@ -60,7 +71,10 @@ arm_init (Elf *elf __attribute__ ((unuse
    HOOK (eh, core_note);
    HOOK (eh, auxv_info);
    HOOK (eh, check_object_attribute);
@@ -65,11 +46,11 @@
 +    eh->return_value_location = arm_return_value_location_hard;
    HOOK (eh, abi_cfi);
    HOOK (eh, check_reloc_target_type);
- 
-diff --git a/backends/arm_regs.c b/backends/arm_regs.c
-index 21c5ad3..4ee1039 100644
---- a/backends/arm_regs.c
-+++ b/backends/arm_regs.c
+   HOOK (eh, symbol_type_name);
+Index: elfutils-0.164/backends/arm_regs.c
+===================================================================
+--- elfutils-0.164.orig/backends/arm_regs.c
++++ elfutils-0.164/backends/arm_regs.c
 @@ -31,6 +31,7 @@
  #endif
  
@@ -78,7 +59,7 @@
  #include <dwarf.h>
  
  #define BACKEND arm_
-@@ -76,6 +77,9 @@ arm_register_info (Ebl *ebl __attribute__ ((unused)),
+@@ -76,6 +77,9 @@ arm_register_info (Ebl *ebl __attribute_
        break;
  
      case 16 + 0 ... 16 + 7:
@@ -88,7 +69,7 @@
        regno += 96 - 16;
        /* Fall through.  */
      case 96 + 0 ... 96 + 7:
-@@ -87,11 +91,139 @@ arm_register_info (Ebl *ebl __attribute__ ((unused)),
+@@ -87,11 +91,139 @@ arm_register_info (Ebl *ebl __attribute_
        namelen = 2;
        break;
  
@@ -228,10 +209,10 @@
        *setname = "VFP";
        *type = DW_ATE_float;
        *bits = 64;
-diff --git a/backends/arm_retval.c b/backends/arm_retval.c
-index 7aced74..052132e 100644
---- a/backends/arm_retval.c
-+++ b/backends/arm_retval.c
+Index: elfutils-0.164/backends/arm_retval.c
+===================================================================
+--- elfutils-0.164.orig/backends/arm_retval.c
++++ elfutils-0.164/backends/arm_retval.c
 @@ -48,6 +48,13 @@ static const Dwarf_Op loc_intreg[] =
  #define nloc_intreg	1
  #define nloc_intregs(n)	(2 * (n))
@@ -258,39 +239,37 @@
  {
    /* Start with the function's type, and get the DW_AT_type attribute,
       which is the type of the return value.  */
-@@ -98,14 +106,31 @@ arm_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+@@ -98,6 +106,21 @@ arm_return_value_location (Dwarf_Die *fu
  	    else
  	      return -1;
  	  }
 +	if (tag == DW_TAG_base_type)
-+	{
-+	  Dwarf_Word encoding;
-+	  if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_encoding,
-+	                       &attr_mem), &encoding) != 0)
-+	    return -1;
++	  {
++	    Dwarf_Word encoding;
++	    if (dwarf_formudata (dwarf_attr_integrate (typedie, DW_AT_encoding,
++				 &attr_mem), &encoding) != 0)
++	      return -1;
 +
-+	  if ((encoding == DW_ATE_float) && !soft_float)
-+	    {
-+	      *locp = loc_fpreg;
-+	      if (size <= 8)
-+		return nloc_fpreg;
-+	      goto aggregate;
-+	    }
-+	}
++	    if ((encoding == DW_ATE_float) && !soft_float)
++	      {
++		*locp = loc_fpreg;
++		if (size <= 8)
++		  return nloc_fpreg;
++		goto aggregate;
++	      }
++	  }
  	if (size <= 16)
  	  {
  	  intreg:
- 	    *locp = loc_intreg;
- 	    return size <= 4 ? nloc_intreg : nloc_intregs ((size + 3) / 4);
+@@ -106,6 +129,7 @@ arm_return_value_location (Dwarf_Die *fu
  	  }
-+	  /* fall through. */
  
        aggregate:
 +	/* XXX TODO sometimes aggregates are returned in r0 (-mabi=aapcs) */
  	*locp = loc_aggregate;
  	return nloc_aggregate;
        }
-@@ -125,3 +150,18 @@ arm_return_value_location (Dwarf_Die *functypedie, const Dwarf_Op **locp)
+@@ -125,3 +149,18 @@ arm_return_value_location (Dwarf_Die *fu
       DWARF and might be valid.  */
    return -2;
  }
@@ -309,26 +288,11 @@
 +   return arm_return_value_location_ (functypedie, locp, 0);
 +}
 +
-diff --git a/backends/libebl_arm.h b/backends/libebl_arm.h
-new file mode 100644
-index 0000000..c00770c
---- /dev/null
-+++ b/backends/libebl_arm.h
-@@ -0,0 +1,9 @@
-+#ifndef _LIBEBL_ARM_H
-+#define _LIBEBL_ARM_H 1
-+
-+#include <libdw.h>
-+
-+extern int arm_return_value_location_soft(Dwarf_Die *, const Dwarf_Op **locp);
-+extern int arm_return_value_location_hard(Dwarf_Die *, const Dwarf_Op **locp);
-+
-+#endif
-diff --git a/libelf/elf.h b/libelf/elf.h
-index a3cce3e..0891674 100644
---- a/libelf/elf.h
-+++ b/libelf/elf.h
-@@ -2346,6 +2346,9 @@ typedef Elf32_Addr Elf32_Conflict;
+Index: elfutils-0.164/libelf/elf.h
+===================================================================
+--- elfutils-0.164.orig/libelf/elf.h
++++ elfutils-0.164/libelf/elf.h
+@@ -2450,6 +2450,9 @@ enum
  #define EF_ARM_EABI_VER4	0x04000000
  #define EF_ARM_EABI_VER5	0x05000000
  
@@ -338,7 +302,7 @@
  /* Additional symbol types for Thumb.  */
  #define STT_ARM_TFUNC		STT_LOPROC /* A Thumb function.  */
  #define STT_ARM_16BIT		STT_HIPROC /* A Thumb label.  */
-@@ -2363,12 +2366,19 @@ typedef Elf32_Addr Elf32_Conflict;
+@@ -2467,12 +2470,19 @@ enum
  
  /* Processor specific values for the Phdr p_type field.  */
  #define PT_ARM_EXIDX		(PT_LOPROC + 1)	/* ARM unwind segment.  */
@@ -358,7 +322,7 @@
  
  /* AArch64 relocs.  */
  
-@@ -2647,6 +2657,7 @@ typedef Elf32_Addr Elf32_Conflict;
+@@ -2765,6 +2775,7 @@ enum
  					   TLS block (LDR, STR).  */
  #define R_ARM_TLS_IE12GP	111	/* 12 bit GOT entry relative
  					   to GOT origin (LDR).  */
@@ -366,122 +330,25 @@
  #define R_ARM_ME_TOO		128	/* Obsolete.  */
  #define R_ARM_THM_TLS_DESCSEQ	129
  #define R_ARM_THM_TLS_DESCSEQ16	129
-diff --git a/tests/run-addrcfi.sh b/tests/run-addrcfi.sh
-index 5d33246..78464a8 100755
---- a/tests/run-addrcfi.sh
-+++ b/tests/run-addrcfi.sh
-@@ -2530,6 +2530,38 @@ dwarf_cfi_addrframe (.eh_frame): no matching address range
- 	FPA reg21 (f5): undefined
- 	FPA reg22 (f6): undefined
- 	FPA reg23 (f7): undefined
-+	VFP reg64 (s0): undefined
-+	VFP reg65 (s1): undefined
-+	VFP reg66 (s2): undefined
-+	VFP reg67 (s3): undefined
-+	VFP reg68 (s4): undefined
-+	VFP reg69 (s5): undefined
-+	VFP reg70 (s6): undefined
-+	VFP reg71 (s7): undefined
-+	VFP reg72 (s8): undefined
-+	VFP reg73 (s9): undefined
-+	VFP reg74 (s10): undefined
-+	VFP reg75 (s11): undefined
-+	VFP reg76 (s12): undefined
-+	VFP reg77 (s13): undefined
-+	VFP reg78 (s14): undefined
-+	VFP reg79 (s15): undefined
-+	VFP reg80 (s16): undefined
-+	VFP reg81 (s17): undefined
-+	VFP reg82 (s18): undefined
-+	VFP reg83 (s19): undefined
-+	VFP reg84 (s20): undefined
-+	VFP reg85 (s21): undefined
-+	VFP reg86 (s22): undefined
-+	VFP reg87 (s23): undefined
-+	VFP reg88 (s24): undefined
-+	VFP reg89 (s25): undefined
-+	VFP reg90 (s26): undefined
-+	VFP reg91 (s27): undefined
-+	VFP reg92 (s28): undefined
-+	VFP reg93 (s29): undefined
-+	VFP reg94 (s30): undefined
-+	VFP reg95 (s31): undefined
- 	FPA reg96 (f0): undefined
- 	FPA reg97 (f1): undefined
- 	FPA reg98 (f2): undefined
-@@ -2538,7 +2570,66 @@ dwarf_cfi_addrframe (.eh_frame): no matching address range
- 	FPA reg101 (f5): undefined
- 	FPA reg102 (f6): undefined
- 	FPA reg103 (f7): undefined
--	integer reg128 (spsr): undefined
-+	MMX reg104 (wcgr0): undefined
-+	MMX reg105 (wcgr1): undefined
-+	MMX reg106 (wcgr2): undefined
-+	MMX reg107 (wcgr3): undefined
-+	MMX reg108 (wcgr4): undefined
-+	MMX reg109 (wcgr5): undefined
-+	MMX reg110 (wcgr6): undefined
-+	MMX reg111 (wcgr7): undefined
-+	MMX reg112 (wr0): undefined
-+	MMX reg113 (wr1): undefined
-+	MMX reg114 (wr2): undefined
-+	MMX reg115 (wr3): undefined
-+	MMX reg116 (wr4): undefined
-+	MMX reg117 (wr5): undefined
-+	MMX reg118 (wr6): undefined
-+	MMX reg119 (wr7): undefined
-+	MMX reg120 (wr8): undefined
-+	MMX reg121 (wr9): undefined
-+	MMX reg122 (wr10): undefined
-+	MMX reg123 (wr11): undefined
-+	MMX reg124 (wr12): undefined
-+	MMX reg125 (wr13): undefined
-+	MMX reg126 (wr14): undefined
-+	MMX reg127 (wr15): undefined
-+	state reg128 (spsr): undefined
-+	state reg129 (spsr_fiq): undefined
-+	state reg130 (spsr_irq): undefined
-+	state reg131 (spsr_abt): undefined
-+	state reg132 (spsr_und): undefined
-+	state reg133 (spsr_svc): undefined
-+	integer reg144 (r8_usr): undefined
-+	integer reg145 (r9_usr): undefined
-+	integer reg146 (r10_usr): undefined
-+	integer reg147 (r11_usr): undefined
-+	integer reg148 (r12_usr): undefined
-+	integer reg149 (r13_usr): undefined
-+	integer reg150 (r14_usr): undefined
-+	integer reg151 (r8_fiq): undefined
-+	integer reg152 (r9_fiq): undefined
-+	integer reg153 (r10_fiq): undefined
-+	integer reg154 (r11_fiq): undefined
-+	integer reg155 (r12_fiq): undefined
-+	integer reg156 (r13_fiq): undefined
-+	integer reg157 (r14_fiq): undefined
-+	integer reg158 (r13_irq): undefined
-+	integer reg159 (r14_irq): undefined
-+	integer reg160 (r13_abt): undefined
-+	integer reg161 (r14_abt): undefined
-+	integer reg162 (r13_und): undefined
-+	integer reg163 (r14_und): undefined
-+	integer reg164 (r13_svc): undefined
-+	integer reg165 (r14_svc): undefined
-+	MMX reg192 (wc0): undefined
-+	MMX reg193 (wc1): undefined
-+	MMX reg194 (wc2): undefined
-+	MMX reg195 (wc3): undefined
-+	MMX reg196 (wc4): undefined
-+	MMX reg197 (wc5): undefined
-+	MMX reg198 (wc6): undefined
-+	MMX reg199 (wc7): undefined
- 	VFP reg256 (d0): undefined
- 	VFP reg257 (d1): undefined
- 	VFP reg258 (d2): undefined
-diff --git a/tests/run-allregs.sh b/tests/run-allregs.sh
-index 6f3862e..13557d5 100755
---- a/tests/run-allregs.sh
-+++ b/tests/run-allregs.sh
-@@ -2671,7 +2671,28 @@ integer registers:
+Index: elfutils-0.164/backends/libebl_arm.h
+===================================================================
+--- /dev/null
++++ elfutils-0.164/backends/libebl_arm.h
+@@ -0,0 +1,9 @@
++#ifndef _LIBEBL_ARM_H
++#define _LIBEBL_ARM_H 1
++
++#include <libdw.h>
++
++extern int arm_return_value_location_soft(Dwarf_Die *, const Dwarf_Op **locp);
++extern int arm_return_value_location_hard(Dwarf_Die *, const Dwarf_Op **locp);
++
++#endif
+Index: elfutils-0.164/tests/run-allregs.sh
+===================================================================
+--- elfutils-0.164.orig/tests/run-allregs.sh
++++ elfutils-0.164/tests/run-allregs.sh
+@@ -2672,7 +2672,28 @@ integer registers:
  	 13: sp (sp), address 32 bits
  	 14: lr (lr), address 32 bits
  	 15: pc (pc), address 32 bits
@@ -511,7 +378,7 @@
  FPA registers:
  	 16: f0 (f0), float 96 bits
  	 17: f1 (f1), float 96 bits
-@@ -2689,7 +2710,72 @@ FPA registers:
+@@ -2690,7 +2711,72 @@ FPA registers:
  	101: f5 (f5), float 96 bits
  	102: f6 (f6), float 96 bits
  	103: f7 (f7), float 96 bits
@@ -584,7 +451,7 @@
  	256: d0 (d0), float 64 bits
  	257: d1 (d1), float 64 bits
  	258: d2 (d2), float 64 bits
-@@ -2722,6 +2808,13 @@ VFP registers:
+@@ -2723,6 +2809,13 @@ VFP registers:
  	285: d29 (d29), float 64 bits
  	286: d30 (d30), float 64 bits
  	287: d31 (d31), float 64 bits
@@ -598,11 +465,11 @@
  EOF
  
  # See run-readelf-mixed-corenote.sh for instructions to regenerate
-diff --git a/tests/run-readelf-mixed-corenote.sh b/tests/run-readelf-mixed-corenote.sh
-index 01e4594..9a8a380 100755
---- a/tests/run-readelf-mixed-corenote.sh
-+++ b/tests/run-readelf-mixed-corenote.sh
-@@ -30,12 +30,11 @@ Note segment of 892 bytes at offset 0x274:
+Index: elfutils-0.164/tests/run-readelf-mixed-corenote.sh
+===================================================================
+--- elfutils-0.164.orig/tests/run-readelf-mixed-corenote.sh
++++ elfutils-0.164/tests/run-readelf-mixed-corenote.sh
+@@ -31,12 +31,11 @@ Note segment of 892 bytes at offset 0x27
      pid: 11087, ppid: 11063, pgrp: 11087, sid: 11063
      utime: 0.000000, stime: 0.010000, cutime: 0.000000, cstime: 0.000000
      orig_r0: -1, fpvalid: 1
@@ -620,6 +487,114 @@
    CORE                 124  PRPSINFO
      state: 0, sname: R, zomb: 0, nice: 0, flag: 0x00400500
      uid: 0, gid: 0, pid: 11087, ppid: 11063, pgrp: 11087, sid: 11063
--- 
-1.9.1
-
+Index: elfutils-0.164/tests/run-addrcfi.sh
+===================================================================
+--- elfutils-0.164.orig/tests/run-addrcfi.sh
++++ elfutils-0.164/tests/run-addrcfi.sh
+@@ -3554,6 +3554,38 @@ dwarf_cfi_addrframe (.eh_frame): no matc
+ 	FPA reg21 (f5): undefined
+ 	FPA reg22 (f6): undefined
+ 	FPA reg23 (f7): undefined
++	VFP reg64 (s0): undefined
++	VFP reg65 (s1): undefined
++	VFP reg66 (s2): undefined
++	VFP reg67 (s3): undefined
++	VFP reg68 (s4): undefined
++	VFP reg69 (s5): undefined
++	VFP reg70 (s6): undefined
++	VFP reg71 (s7): undefined
++	VFP reg72 (s8): undefined
++	VFP reg73 (s9): undefined
++	VFP reg74 (s10): undefined
++	VFP reg75 (s11): undefined
++	VFP reg76 (s12): undefined
++	VFP reg77 (s13): undefined
++	VFP reg78 (s14): undefined
++	VFP reg79 (s15): undefined
++	VFP reg80 (s16): undefined
++	VFP reg81 (s17): undefined
++	VFP reg82 (s18): undefined
++	VFP reg83 (s19): undefined
++	VFP reg84 (s20): undefined
++	VFP reg85 (s21): undefined
++	VFP reg86 (s22): undefined
++	VFP reg87 (s23): undefined
++	VFP reg88 (s24): undefined
++	VFP reg89 (s25): undefined
++	VFP reg90 (s26): undefined
++	VFP reg91 (s27): undefined
++	VFP reg92 (s28): undefined
++	VFP reg93 (s29): undefined
++	VFP reg94 (s30): undefined
++	VFP reg95 (s31): undefined
+ 	FPA reg96 (f0): undefined
+ 	FPA reg97 (f1): undefined
+ 	FPA reg98 (f2): undefined
+@@ -3562,7 +3594,66 @@ dwarf_cfi_addrframe (.eh_frame): no matc
+ 	FPA reg101 (f5): undefined
+ 	FPA reg102 (f6): undefined
+ 	FPA reg103 (f7): undefined
+-	integer reg128 (spsr): undefined
++	MMX reg104 (wcgr0): undefined
++	MMX reg105 (wcgr1): undefined
++	MMX reg106 (wcgr2): undefined
++	MMX reg107 (wcgr3): undefined
++	MMX reg108 (wcgr4): undefined
++	MMX reg109 (wcgr5): undefined
++	MMX reg110 (wcgr6): undefined
++	MMX reg111 (wcgr7): undefined
++	MMX reg112 (wr0): undefined
++	MMX reg113 (wr1): undefined
++	MMX reg114 (wr2): undefined
++	MMX reg115 (wr3): undefined
++	MMX reg116 (wr4): undefined
++	MMX reg117 (wr5): undefined
++	MMX reg118 (wr6): undefined
++	MMX reg119 (wr7): undefined
++	MMX reg120 (wr8): undefined
++	MMX reg121 (wr9): undefined
++	MMX reg122 (wr10): undefined
++	MMX reg123 (wr11): undefined
++	MMX reg124 (wr12): undefined
++	MMX reg125 (wr13): undefined
++	MMX reg126 (wr14): undefined
++	MMX reg127 (wr15): undefined
++	state reg128 (spsr): undefined
++	state reg129 (spsr_fiq): undefined
++	state reg130 (spsr_irq): undefined
++	state reg131 (spsr_abt): undefined
++	state reg132 (spsr_und): undefined
++	state reg133 (spsr_svc): undefined
++	integer reg144 (r8_usr): undefined
++	integer reg145 (r9_usr): undefined
++	integer reg146 (r10_usr): undefined
++	integer reg147 (r11_usr): undefined
++	integer reg148 (r12_usr): undefined
++	integer reg149 (r13_usr): undefined
++	integer reg150 (r14_usr): undefined
++	integer reg151 (r8_fiq): undefined
++	integer reg152 (r9_fiq): undefined
++	integer reg153 (r10_fiq): undefined
++	integer reg154 (r11_fiq): undefined
++	integer reg155 (r12_fiq): undefined
++	integer reg156 (r13_fiq): undefined
++	integer reg157 (r14_fiq): undefined
++	integer reg158 (r13_irq): undefined
++	integer reg159 (r14_irq): undefined
++	integer reg160 (r13_abt): undefined
++	integer reg161 (r14_abt): undefined
++	integer reg162 (r13_und): undefined
++	integer reg163 (r14_und): undefined
++	integer reg164 (r13_svc): undefined
++	integer reg165 (r14_svc): undefined
++	MMX reg192 (wc0): undefined
++	MMX reg193 (wc1): undefined
++	MMX reg194 (wc2): undefined
++	MMX reg195 (wc3): undefined
++	MMX reg196 (wc4): undefined
++	MMX reg197 (wc5): undefined
++	MMX reg198 (wc6): undefined
++	MMX reg199 (wc7): undefined
+ 	VFP reg256 (d0): undefined
+ 	VFP reg257 (d1): undefined
+ 	VFP reg258 (d2): undefined
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/fixheadercheck.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/fixheadercheck.patch
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/fixheadercheck.patch
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/fixheadercheck.patch
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/hppa_backend.diff b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/hppa_backend.diff
similarity index 93%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/hppa_backend.diff
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/hppa_backend.diff
index d51a720..4545671 100644
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/hppa_backend.diff
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/hppa_backend.diff
@@ -1,8 +1,8 @@
-Index: elfutils-0.158/backends/parisc_init.c
+Index: elfutils-0.164/backends/parisc_init.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/parisc_init.c	2014-04-21 11:12:12.228150280 +0000
-@@ -0,0 +1,74 @@
+--- /dev/null
++++ elfutils-0.164/backends/parisc_init.c
+@@ -0,0 +1,73 @@
 +/* Initialization of PA-RISC specific backend library.
 +   Copyright (C) 2002, 2005, 2006 Red Hat, Inc.
 +   This file is part of Red Hat elfutils.
@@ -43,11 +43,10 @@
 +
 +
 +const char *
-+parisc_init (elf, machine, eh, ehlen)
-+     Elf *elf __attribute__ ((unused));
-+     GElf_Half machine __attribute__ ((unused));
-+     Ebl *eh;
-+     size_t ehlen;
++parisc_init (Elf *elf __attribute__ ((unused)),
++     GElf_Half machine __attribute__ ((unused)),
++     Ebl *eh,
++     size_t ehlen)
 +{
 +  int pa64 = 0;
 +
@@ -77,10 +76,10 @@
 +
 +  return MODVERSION;
 +}
-Index: elfutils-0.158/backends/parisc_regs.c
+Index: elfutils-0.164/backends/parisc_regs.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/parisc_regs.c	2014-04-21 11:12:12.228150280 +0000
+--- /dev/null
++++ elfutils-0.164/backends/parisc_regs.c
 @@ -0,0 +1,159 @@
 +/* Register names and numbers for PA-RISC DWARF.
 +   Copyright (C) 2005, 2006 Red Hat, Inc.
@@ -241,10 +240,10 @@
 +  name[namelen++] = '\0';
 +  return namelen;
 +}
-Index: elfutils-0.158/backends/parisc_reloc.def
+Index: elfutils-0.164/backends/parisc_reloc.def
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/parisc_reloc.def	2014-04-21 11:12:12.228150280 +0000
+--- /dev/null
++++ elfutils-0.164/backends/parisc_reloc.def
 @@ -0,0 +1,128 @@
 +/* List the relocation types for PA-RISC.  -*- C -*-
 +   Copyright (C) 2005 Red Hat, Inc.
@@ -374,10 +373,10 @@
 +RELOC_TYPE (TLS_DTPMOD64,	DYN)
 +
 +#define NO_RELATIVE_RELOC       1
-Index: elfutils-0.158/backends/parisc_retval.c
+Index: elfutils-0.164/backends/parisc_retval.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/parisc_retval.c	2014-04-21 11:12:12.228150280 +0000
+--- /dev/null
++++ elfutils-0.164/backends/parisc_retval.c
 @@ -0,0 +1,213 @@
 +/* Function return value location for Linux/PA-RISC ABI.
 +   Copyright (C) 2005 Red Hat, Inc.
@@ -592,10 +591,10 @@
 +  return parisc_return_value_location_ (functypedie, locp, 1);
 +}
 +
-Index: elfutils-0.158/backends/parisc_symbol.c
+Index: elfutils-0.164/backends/parisc_symbol.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/parisc_symbol.c	2014-04-21 11:12:12.228150280 +0000
+--- /dev/null
++++ elfutils-0.164/backends/parisc_symbol.c
 @@ -0,0 +1,112 @@
 +/* PA-RISC specific symbolic name handling.
 +   Copyright (C) 2002, 2005 Red Hat, Inc.
@@ -709,10 +708,10 @@
 +      return ELF_T_NUM;
 +    }
 +}
-Index: elfutils-0.158/backends/libebl_parisc.h
+Index: elfutils-0.164/backends/libebl_parisc.h
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/libebl_parisc.h	2014-04-21 11:12:12.228150280 +0000
+--- /dev/null
++++ elfutils-0.164/backends/libebl_parisc.h
 @@ -0,0 +1,9 @@
 +#ifndef _LIBEBL_HPPA_H
 +#define _LIBEBL_HPPA_H 1
@@ -723,11 +722,11 @@
 +extern int parisc_return_value_location_64(Dwarf_Die *, const Dwarf_Op **locp);
 +
 +#endif
-Index: elfutils-0.158/backends/Makefile.am
+Index: elfutils-0.164/backends/Makefile.am
 ===================================================================
---- elfutils-0.158.orig/backends/Makefile.am	2014-04-21 11:12:12.252149737 +0000
-+++ elfutils-0.158/backends/Makefile.am	2014-04-21 11:13:11.910801105 +0000
-@@ -33,11 +33,12 @@
+--- elfutils-0.164.orig/backends/Makefile.am
++++ elfutils-0.164/backends/Makefile.am
+@@ -33,11 +33,12 @@ AM_CPPFLAGS += -I$(top_srcdir)/libebl -I
  
  
  modules = i386 sh x86_64 ia64 alpha arm aarch64 sparc ppc ppc64 s390 \
@@ -742,7 +741,7 @@
  noinst_LIBRARIES = $(libebl_pic)
  noinst_DATA = $(libebl_pic:_pic.a=.so)
  
-@@ -116,6 +117,9 @@
+@@ -111,6 +112,9 @@ tilegx_SRCS = tilegx_init.c tilegx_symbo
  libebl_tilegx_pic_a_SOURCES = $(tilegx_SRCS)
  am_libebl_tilegx_pic_a_OBJECTS = $(tilegx_SRCS:.c=.os)
  
@@ -752,11 +751,11 @@
  
  libebl_%.so libebl_%.map: libebl_%_pic.a $(libelf) $(libdw)
  	@rm -f $(@:.so=.map)
-Index: elfutils-0.158/libelf/elf.h
+Index: elfutils-0.164/libelf/elf.h
 ===================================================================
---- elfutils-0.158.orig/libelf/elf.h	2014-04-21 11:12:12.252149737 +0000
-+++ elfutils-0.158/libelf/elf.h	2014-04-21 11:12:12.228150280 +0000
-@@ -1814,16 +1814,24 @@
+--- elfutils-0.164.orig/libelf/elf.h
++++ elfutils-0.164/libelf/elf.h
+@@ -1912,16 +1912,24 @@ enum
  #define R_PARISC_PCREL17F	12	/* 17 bits of rel. address.  */
  #define R_PARISC_PCREL14R	14	/* Right 14 bits of rel. address.  */
  #define R_PARISC_DPREL21L	18	/* Left 21 bits of rel. address.  */
@@ -781,7 +780,7 @@
  #define R_PARISC_LTOFF_FPTR32	57	/* 32 bits LT-rel. function pointer. */
  #define R_PARISC_LTOFF_FPTR21L	58	/* LT-rel. fct ptr, left 21 bits. */
  #define R_PARISC_LTOFF_FPTR14R	62	/* LT-rel. fct ptr, right 14 bits. */
-@@ -1832,6 +1840,7 @@
+@@ -1930,6 +1938,7 @@ enum
  #define R_PARISC_PLABEL21L	66	/* Left 21 bits of fdesc address.  */
  #define R_PARISC_PLABEL14R	70	/* Right 14 bits of fdesc address.  */
  #define R_PARISC_PCREL64	72	/* 64 bits PC-rel. address.  */
@@ -789,7 +788,7 @@
  #define R_PARISC_PCREL22F	74	/* 22 bits PC-rel. address.  */
  #define R_PARISC_PCREL14WR	75	/* PC-rel. address, right 14 bits.  */
  #define R_PARISC_PCREL14DR	76	/* PC rel. address, right 14 bits.  */
-@@ -1857,6 +1866,8 @@
+@@ -1955,6 +1964,8 @@ enum
  #define R_PARISC_LTOFF16WF	102	/* 16 bits LT-rel. address.  */
  #define R_PARISC_LTOFF16DF	103	/* 16 bits LT-rel. address.  */
  #define R_PARISC_SECREL64	104	/* 64 bits section rel. address.  */
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/kfreebsd_path.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/kfreebsd_path.patch
new file mode 100644
index 0000000..ba454ee
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/kfreebsd_path.patch
@@ -0,0 +1,15 @@
+--- elfutils/tests/run-native-test.sh.orig
++++ elfutils/tests/run-native-test.sh
+@@ -78,6 +78,12 @@
+   test $native -eq 0 || testrun "$@" -p $native > /dev/null
+ }
+ 
++# On the Debian buildds, GNU/kFreeBSD linprocfs /proc/$PID/maps does
++# not give absolute paths due to sbuild's bind mounts (bug #570805)
++# therefore the next two test programs are expected to fail with
++# "cannot attach to process: Function not implemented".
++[ "$(uname)" = "GNU/kFreeBSD" ] && exit 77
++
+ native_test ${abs_builddir}/allregs
+ native_test ${abs_builddir}/funcretval
+ 
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/m68k_backend.diff b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/m68k_backend.diff
similarity index 89%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/m68k_backend.diff
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/m68k_backend.diff
index f5b566f..d73855b 100644
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/m68k_backend.diff
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/m68k_backend.diff
@@ -6,11 +6,11 @@
 by Thorsten Glaser
 
 
-Index: elfutils-0.158/backends/m68k_init.c
+Index: elfutils-0.164/backends/m68k_init.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/m68k_init.c	2014-04-21 11:14:23.813175704 +0000
-@@ -0,0 +1,50 @@
+--- /dev/null
++++ elfutils-0.164/backends/m68k_init.c
+@@ -0,0 +1,49 @@
 +/* Initialization of m68k specific backend library.
 +   Copyright (C) 2007 Kurt Roeckx <kurt@roeckx.be>
 +
@@ -42,11 +42,10 @@
 +
 +
 +const char *
-+m68k_init (elf, machine, eh, ehlen)
-+     Elf *elf __attribute__ ((unused));
-+     GElf_Half machine __attribute__ ((unused));
-+     Ebl *eh;
-+     size_t ehlen;
++m68k_init (Elf *elf __attribute__ ((unused)),
++     GElf_Half machine __attribute__ ((unused)),
++     Ebl *eh,
++     size_t ehlen)
 +{
 +  /* Check whether the Elf_BH object has a sufficent size.  */
 +  if (ehlen < sizeof (Ebl))
@@ -61,10 +60,10 @@
 +
 +  return MODVERSION;
 +}
-Index: elfutils-0.158/backends/m68k_regs.c
+Index: elfutils-0.164/backends/m68k_regs.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/m68k_regs.c	2014-04-21 11:14:23.813175704 +0000
+--- /dev/null
++++ elfutils-0.164/backends/m68k_regs.c
 @@ -0,0 +1,106 @@
 +/* Register names and numbers for m68k DWARF.
 +   Copyright (C) 2007 Kurt Roeckx <kurt@roeckx.be>
@@ -172,10 +171,10 @@
 +	return namelen;
 +}
 +
-Index: elfutils-0.158/backends/m68k_reloc.def
+Index: elfutils-0.164/backends/m68k_reloc.def
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/m68k_reloc.def	2014-04-21 11:14:23.813175704 +0000
+--- /dev/null
++++ elfutils-0.164/backends/m68k_reloc.def
 @@ -0,0 +1,45 @@
 +/* List the relocation types for m68k.  -*- C -*-
 +   Copyright (C) 2007 Kurt Roeckx <kurt@roeckx.be>
@@ -222,11 +221,11 @@
 +RELOC_TYPE (GNU_VTINHERIT,	REL)
 +RELOC_TYPE (GNU_VTENTRY,	REL)
 +
-Index: elfutils-0.158/libelf/elf.h
+Index: elfutils-0.164/libelf/elf.h
 ===================================================================
---- elfutils-0.158.orig/libelf/elf.h	2014-04-21 11:14:23.813175704 +0000
-+++ elfutils-0.158/libelf/elf.h	2014-04-21 11:14:23.813175704 +0000
-@@ -1157,6 +1157,9 @@
+--- elfutils-0.164.orig/libelf/elf.h
++++ elfutils-0.164/libelf/elf.h
+@@ -1158,6 +1158,9 @@ typedef struct
  #define R_68K_GLOB_DAT	20		/* Create GOT entry */
  #define R_68K_JMP_SLOT	21		/* Create PLT entry */
  #define R_68K_RELATIVE	22		/* Adjust by program base */
@@ -236,11 +235,11 @@
  #define R_68K_TLS_GD32      25          /* 32 bit GOT offset for GD */
  #define R_68K_TLS_GD16      26          /* 16 bit GOT offset for GD */
  #define R_68K_TLS_GD8       27          /* 8 bit GOT offset for GD */
-Index: elfutils-0.158/backends/Makefile.am
+Index: elfutils-0.164/backends/Makefile.am
 ===================================================================
---- elfutils-0.158.orig/backends/Makefile.am	2014-04-21 11:14:23.813175704 +0000
-+++ elfutils-0.158/backends/Makefile.am	2014-04-21 11:14:48.344621167 +0000
-@@ -33,12 +33,12 @@
+--- elfutils-0.164.orig/backends/Makefile.am
++++ elfutils-0.164/backends/Makefile.am
+@@ -33,12 +33,12 @@ AM_CPPFLAGS += -I$(top_srcdir)/libebl -I
  
  
  modules = i386 sh x86_64 ia64 alpha arm aarch64 sparc ppc ppc64 s390 \
@@ -255,7 +254,7 @@
  noinst_LIBRARIES = $(libebl_pic)
  noinst_DATA = $(libebl_pic:_pic.a=.so)
  
-@@ -125,6 +125,10 @@
+@@ -120,6 +120,10 @@ mips_SRCS = mips_init.c mips_symbol.c mi
  libebl_mips_pic_a_SOURCES = $(mips_SRCS)
  am_libebl_mips_pic_a_OBJECTS = $(mips_SRCS:.c=.os)
  
@@ -265,11 +264,11 @@
 +
  libebl_%.so libebl_%.map: libebl_%_pic.a $(libelf) $(libdw)
  	@rm -f $(@:.so=.map)
- 	echo 'ELFUTILS_$(PACKAGE_VERSION) { global: $*_init; local: *; };' \
-Index: elfutils-0.158/backends/m68k_symbol.c
+ 	$(AM_V_at)echo 'ELFUTILS_$(PACKAGE_VERSION) { global: $*_init; local: *; };' \
+Index: elfutils-0.164/backends/m68k_symbol.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/m68k_symbol.c	2014-04-21 11:14:23.813175704 +0000
+--- /dev/null
++++ elfutils-0.164/backends/m68k_symbol.c
 @@ -0,0 +1,43 @@
 +/* m68k specific symbolic name handling.
 +   Copyright (C) 2007 Kurt Roeckx <kurt@roeckx.be>
@@ -314,10 +313,10 @@
 +      return ELF_T_NUM;
 +    }
 +}
-Index: elfutils-0.158/backends/m68k_retval.c
+Index: elfutils-0.164/backends/m68k_retval.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/m68k_retval.c	2014-04-21 11:14:23.813175704 +0000
+--- /dev/null
++++ elfutils-0.164/backends/m68k_retval.c
 @@ -0,0 +1,172 @@
 +/* Function return value location for Linux/m68k ABI.
 +   Copyright (C) 2005-2010 Red Hat, Inc.
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/mips_backend.diff b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/mips_backend.diff
similarity index 92%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/mips_backend.diff
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/mips_backend.diff
index d73a3f2..de1237b 100644
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/mips_backend.diff
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/mips_backend.diff
@@ -1,8 +1,8 @@
-Index: elfutils-0.158/backends/mips_init.c
+Index: elfutils-0.164/backends/mips_init.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/mips_init.c	2014-04-21 11:13:36.910235965 +0000
-@@ -0,0 +1,60 @@
+--- /dev/null
++++ elfutils-0.164/backends/mips_init.c
+@@ -0,0 +1,59 @@
 +/* Initialization of mips specific backend library.
 +   Copyright (C) 2006 Red Hat, Inc.
 +   This file is part of Red Hat elfutils.
@@ -40,11 +40,10 @@
 +#include "common-reloc.c"
 +
 +const char *
-+mips_init (elf, machine, eh, ehlen)
-+     Elf *elf __attribute__ ((unused));
-+     GElf_Half machine __attribute__ ((unused));
-+     Ebl *eh;
-+     size_t ehlen;
++mips_init (Elf *elf __attribute__ ((unused)),
++     GElf_Half machine __attribute__ ((unused)),
++     Ebl *eh,
++     size_t ehlen)
 +{
 +  /* Check whether the Elf_BH object has a sufficent size.  */
 +  if (ehlen < sizeof (Ebl))
@@ -63,10 +62,10 @@
 +
 +  return MODVERSION;
 +}
-Index: elfutils-0.158/backends/mips_regs.c
+Index: elfutils-0.164/backends/mips_regs.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/mips_regs.c	2014-04-21 11:13:36.910235965 +0000
+--- /dev/null
++++ elfutils-0.164/backends/mips_regs.c
 @@ -0,0 +1,104 @@
 +/* Register names and numbers for MIPS DWARF.
 +   Copyright (C) 2006 Red Hat, Inc.
@@ -172,10 +171,10 @@
 +  name[namelen++] = '\0';
 +  return namelen;
 +}
-Index: elfutils-0.158/backends/mips_reloc.def
+Index: elfutils-0.164/backends/mips_reloc.def
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/mips_reloc.def	2014-04-21 11:13:36.910235965 +0000
+--- /dev/null
++++ elfutils-0.164/backends/mips_reloc.def
 @@ -0,0 +1,79 @@
 +/* List the relocation types for mips.  -*- C -*-
 +   Copyright (C) 2006 Red Hat, Inc.
@@ -256,10 +255,10 @@
 +
 +#define NO_COPY_RELOC 1
 +#define NO_RELATIVE_RELOC 1
-Index: elfutils-0.158/backends/mips_retval.c
+Index: elfutils-0.164/backends/mips_retval.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/mips_retval.c	2014-04-21 11:13:36.910235965 +0000
+--- /dev/null
++++ elfutils-0.164/backends/mips_retval.c
 @@ -0,0 +1,321 @@
 +/* Function return value location for Linux/mips ABI.
 +   Copyright (C) 2005 Red Hat, Inc.
@@ -582,10 +581,10 @@
 +     DWARF and might be valid.  */
 +  return -2;
 +}
-Index: elfutils-0.158/backends/mips_symbol.c
+Index: elfutils-0.164/backends/mips_symbol.c
 ===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ elfutils-0.158/backends/mips_symbol.c	2014-04-21 11:13:36.910235965 +0000
+--- /dev/null
++++ elfutils-0.164/backends/mips_symbol.c
 @@ -0,0 +1,52 @@
 +/* MIPS specific symbolic name handling.
 +   Copyright (C) 2002, 2003, 2005 Red Hat, Inc.
@@ -639,11 +638,11 @@
 +      return ELF_T_NUM;
 +    }
 +}
-Index: elfutils-0.158/libebl/eblopenbackend.c
+Index: elfutils-0.164/libebl/eblopenbackend.c
 ===================================================================
---- elfutils-0.158.orig/libebl/eblopenbackend.c	2014-04-21 11:13:36.914235875 +0000
-+++ elfutils-0.158/libebl/eblopenbackend.c	2014-04-21 11:13:36.910235965 +0000
-@@ -71,6 +71,8 @@
+--- elfutils-0.164.orig/libebl/eblopenbackend.c
++++ elfutils-0.164/libebl/eblopenbackend.c
+@@ -71,6 +71,8 @@ static const struct
    { "sparc", "elf_sparc", "sparc", 5, EM_SPARC, 0, 0 },
    { "sparc", "elf_sparcv8plus", "sparc", 5, EM_SPARC32PLUS, 0, 0 },
    { "s390", "ebl_s390", "s390", 4, EM_S390, 0, 0 },
@@ -652,11 +651,11 @@
  
    { "m32", "elf_m32", "m32", 3, EM_M32, 0, 0 },
    { "m68k", "elf_m68k", "m68k", 4, EM_68K, 0, 0 },
-Index: elfutils-0.158/backends/common-reloc.c
+Index: elfutils-0.164/backends/common-reloc.c
 ===================================================================
---- elfutils-0.158.orig/backends/common-reloc.c	2014-04-21 11:13:36.914235875 +0000
-+++ elfutils-0.158/backends/common-reloc.c	2014-04-21 11:13:36.910235965 +0000
-@@ -112,11 +112,13 @@
+--- elfutils-0.164.orig/backends/common-reloc.c
++++ elfutils-0.164/backends/common-reloc.c
+@@ -125,11 +125,13 @@ EBLHOOK(reloc_valid_use) (Elf *elf, int
  }
  
  
@@ -670,7 +669,7 @@
  
  bool
  EBLHOOK(none_reloc_p) (int reloc)
-@@ -138,7 +140,9 @@
+@@ -151,7 +153,9 @@ EBLHOOK(init_reloc) (Ebl *ebl)
    ebl->reloc_type_name = EBLHOOK(reloc_type_name);
    ebl->reloc_type_check = EBLHOOK(reloc_type_check);
    ebl->reloc_valid_use = EBLHOOK(reloc_valid_use);
@@ -680,11 +679,11 @@
    ebl->none_reloc_p = EBLHOOK(none_reloc_p);
  #ifndef NO_RELATIVE_RELOC
    ebl->relative_reloc_p = EBLHOOK(relative_reloc_p);
-Index: elfutils-0.158/backends/Makefile.am
+Index: elfutils-0.164/backends/Makefile.am
 ===================================================================
---- elfutils-0.158.orig/backends/Makefile.am	2014-04-21 11:13:36.914235875 +0000
-+++ elfutils-0.158/backends/Makefile.am	2014-04-21 11:14:10.841468934 +0000
-@@ -33,12 +33,12 @@
+--- elfutils-0.164.orig/backends/Makefile.am
++++ elfutils-0.164/backends/Makefile.am
+@@ -33,12 +33,12 @@ AM_CPPFLAGS += -I$(top_srcdir)/libebl -I
  
  
  modules = i386 sh x86_64 ia64 alpha arm aarch64 sparc ppc ppc64 s390 \
@@ -699,7 +698,7 @@
  noinst_LIBRARIES = $(libebl_pic)
  noinst_DATA = $(libebl_pic:_pic.a=.so)
  
-@@ -121,6 +121,10 @@
+@@ -116,6 +116,10 @@ parisc_SRCS = parisc_init.c parisc_symbo
  libebl_parisc_pic_a_SOURCES = $(parisc_SRCS)
  am_libebl_parisc_pic_a_OBJECTS = $(parisc_SRCS:.c=.os)
  
@@ -709,4 +708,4 @@
 +
  libebl_%.so libebl_%.map: libebl_%_pic.a $(libelf) $(libdw)
  	@rm -f $(@:.so=.map)
- 	echo 'ELFUTILS_$(PACKAGE_VERSION) { global: $*_init; local: *; };' \
+ 	$(AM_V_at)echo 'ELFUTILS_$(PACKAGE_VERSION) { global: $*_init; local: *; };' \
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/mips_readelf_w.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/mips_readelf_w.patch
similarity index 75%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/mips_readelf_w.patch
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/mips_readelf_w.patch
index 8e669e7..930d6f6 100644
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/mips_readelf_w.patch
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/mips_readelf_w.patch
@@ -6,11 +6,11 @@
 Upstreams wants a change where this is handled by a hook that needs
 to be filled in by the backend for the arch.
 
-Index: elfutils-0.153/src/readelf.c
+Index: elfutils-0.164/src/readelf.c
 ===================================================================
---- elfutils-0.153.orig/src/readelf.c	2012-08-10 22:01:55.000000000 +0200
-+++ elfutils-0.153/src/readelf.c	2012-09-18 21:46:27.000000000 +0200
-@@ -7364,7 +7364,8 @@
+--- elfutils-0.164.orig/src/readelf.c
++++ elfutils-0.164/src/readelf.c
+@@ -8218,7 +8218,8 @@ print_debug (Dwfl_Module *dwflmod, Ebl *
        GElf_Shdr shdr_mem;
        GElf_Shdr *shdr = gelf_getshdr (scn, &shdr_mem);
  
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/shadow.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/shadow.patch
new file mode 100644
index 0000000..d31961f
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/shadow.patch
@@ -0,0 +1,23 @@
+Fix control path where we have str as uninitialized string
+
+| /home/ubuntu/work/oe/openembedded-core/build/tmp-musl/work/i586-oe-linux-musl/elfutils/0.164-r0/elfutils-0.164/libcpu/i386_disasm.c: In function 'i386_disasm':
+| /home/ubuntu/work/oe/openembedded-core/build/tmp-musl/work/i586-oe-linux-musl/elfutils/0.164-r0/elfutils-0.164/libcpu/i386_disasm.c:310:5: error: 'str' may be used uninitialized in this function [-Werror=maybe-uninitialized]
+|      memcpy (buf + bufcnt, _str, _len);           \
+|      ^
+| /home/ubuntu/work/oe/openembedded-core/build/tmp-musl/work/i586-oe-linux-musl/elfutils/0.164-r0/elfutils-0.164/libcpu/i386_disasm.c:709:17: note: 'str' was declared here
+|      const char *str;
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Pending
+Index: elfutils-0.164/libcpu/i386_disasm.c
+===================================================================
+--- elfutils-0.164.orig/libcpu/i386_disasm.c
++++ elfutils-0.164/libcpu/i386_disasm.c
+@@ -821,6 +821,7 @@ i386_disasm (const uint8_t **startp, con
+ 			    }
+ 
+ 			default:
++			  str = "";
+ 			  assert (! "INVALID not handled");
+ 			}
+ 		    }
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/testsuite-ignore-elflint.diff b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/testsuite-ignore-elflint.diff
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.163/testsuite-ignore-elflint.diff
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/testsuite-ignore-elflint.diff
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/uclibc-support.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/uclibc-support.patch
new file mode 100644
index 0000000..966b70f
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils-0.164/uclibc-support.patch
@@ -0,0 +1,129 @@
+From 3daec2dd11a04955f95e8f65a48820103d84dbec Mon Sep 17 00:00:00 2001
+From: Junling Zheng <zhengjunling@huawei.com>
+Date: Thu, 9 Apr 2015 12:12:49 +0000
+Subject: [PATCH] uclibc support for elfutils 0.161
+
+on uclibc systems libintl and libuargp are separate from libc.
+so they need to be specified on commandline when we use proxy-libintl
+then libintl is a static archive so it should be listed last since
+elfutils does not respect disable-nls we need to link in libintl
+
+We add a new option --enable-uclibc which will be used to control
+the uclibc specific configurations during build.
+
+Upstream-Status: Inappropriate [uclibc specific]
+
+Signed-off-by: Khem Raj <raj.khem>
+Signed-off-by: Junling Zheng <zhengjunling@huawei.com>
+[Junling Zheng:
+ - adjust context
+]
+---
+ configure.ac       | 8 ++++++++
+ libcpu/Makefile.am | 4 ++++
+ libdw/Makefile.am  | 7 ++++++-
+ libelf/Makefile.am | 5 +++++
+ 4 files changed, 23 insertions(+), 1 deletion(-)
+
+Index: elfutils-0.164/configure.ac
+===================================================================
+--- elfutils-0.164.orig/configure.ac
++++ elfutils-0.164/configure.ac
+@@ -66,6 +66,14 @@ AS_IF([test "$use_locks" = yes],
+ 
+ AH_TEMPLATE([USE_LOCKS], [Defined if libraries should be thread-safe.])
+ 
++AC_ARG_ENABLE([uclibc],
++AS_HELP_STRING([--enable-uclibc], [Use uclibc for system libraries]),
++use_uclibc=yes, use_uclibc=no)
++AM_CONDITIONAL(USE_UCLIBC, test "$use_uclibc" = yes)
++AS_IF([test "$use_uclibc" = yes], [AC_DEFINE(USE_UCLIBC)])
++
++AH_TEMPLATE([USE_UCLIBC], [Defined if uclibc libraries are used.])
++
+ AC_PROG_CC
+ AC_PROG_RANLIB
+ AC_PROG_YACC
+@@ -291,18 +299,13 @@ AC_LINK_IFELSE(
+ )
+ 
+ dnl If our libc doesn't provide argp, then test for libargp
+-if test "$libc_has_argp" = "false" ; then
+-	AC_MSG_WARN("libc does not have argp")
+-	AC_CHECK_LIB([argp], [argp_parse], [have_argp="true"], [have_argp="false"])
+-
+-	if test "$have_argp" = "false"; then
+-		AC_MSG_ERROR("no libargp found")
+-	else
+-		argp_LDADD="-largp"
+-	fi
+-else
+-	argp_LDADD=""
+-fi
++AS_IF([test "x$libc_has_argp" = "xfalse"],
++	[AC_MSG_WARN("libc does not have argp")
++	AC_CHECK_LIB([argp], [argp_parse], [have_argp="true" argp_LDADD="-largp"], [have_argp="false"])], [argp_LDADD=""])
++
++AS_IF([test "x$libc_has_argp" = "xfalse" -a "x$have_argp" = "xfalse"],
++	AC_CHECK_LIB([uargp], [argp_parse], [have_uargp="true" argp_LDADD="-luargp"], [have_uargp="false"])], [argp_LDADD=""])
++
+ AC_SUBST([argp_LDADD])
+ 
+ dnl The directories with content.
+Index: elfutils-0.164/libcpu/Makefile.am
+===================================================================
+--- elfutils-0.164.orig/libcpu/Makefile.am
++++ elfutils-0.164/libcpu/Makefile.am
+@@ -80,6 +80,10 @@ i386_parse_CFLAGS = -DNMNES="`wc -l < i3
+ i386_lex.o: i386_parse.h
+ i386_gendis_LDADD = $(libeu) -lm
+ 
++if USE_UCLIBC
++i386_gendis_LDADD += -lintl
++endif
++
+ i386_parse.h: i386_parse.c ;
+ 
+ EXTRA_DIST = defs/i386
+Index: elfutils-0.164/libdw/Makefile.am
+===================================================================
+--- elfutils-0.164.orig/libdw/Makefile.am
++++ elfutils-0.164/libdw/Makefile.am
+@@ -102,6 +102,11 @@ endif
+ libdw_pic_a_SOURCES =
+ am_libdw_pic_a_OBJECTS = $(libdw_a_SOURCES:.c=.os)
+ 
++libdw_so_LDLIBS =
++if USE_UCLIBC
++libdw_so_LDLIBS += -lintl
++endif
++
+ libdw_so_SOURCES =
+ libdw.so$(EXEEXT): $(srcdir)/libdw.map libdw_pic.a ../libdwelf/libdwelf_pic.a \
+ 	  ../libdwfl/libdwfl_pic.a ../libebl/libebl.a \
+@@ -112,7 +117,7 @@ libdw.so$(EXEEXT): $(srcdir)/libdw.map l
+ 		-Wl,--enable-new-dtags,-rpath,$(pkglibdir) \
+ 		-Wl,--version-script,$<,--no-undefined \
+ 		-Wl,--whole-archive $(filter-out $<,$^) -Wl,--no-whole-archive\
+-		-ldl $(argp_LDADD) $(zip_LIBS)
++		-ldl $(argp_LDADD) $(zip_LIBS) $(libdw_so_LDLIBS)
+ 	@$(textrel_check)
+ 	$(AM_V_at)ln -fs $@ $@.$(VERSION)
+ 
+Index: elfutils-0.164/libelf/Makefile.am
+===================================================================
+--- elfutils-0.164.orig/libelf/Makefile.am
++++ elfutils-0.164/libelf/Makefile.am
+@@ -93,7 +93,12 @@ libelf_a_SOURCES = elf_version.c elf_has
+ libelf_pic_a_SOURCES =
+ am_libelf_pic_a_OBJECTS = $(libelf_a_SOURCES:.c=.os)
+ 
++
+ libelf_so_LDLIBS =
++if USE_UCLIBC
++libelf_so_LDLIBS += -lintl
++endif
++
+ if USE_LOCKS
+ libelf_so_LDLIBS += -lpthread
+ endif
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils/mempcpy.patch b/yocto-poky/meta/recipes-devtools/elfutils/elfutils/mempcpy.patch
deleted file mode 100644
index 24e31fa..0000000
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils/mempcpy.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-
-uclibc does not export __mempcpy like glibc so we alias it here.
-This patch may make sense for upstream but elfutils uses more
-glibc specific features like obstack_printf which are missing in
-uclibc they need to be fixed along to make it work all the way
-
-Upstream-Status: Inappropriate[Elfutils uses more glibc specific features]
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Index: elfutils-0.148/libelf/elf_begin.c
-===================================================================
---- elfutils-0.148.orig/libelf/elf_begin.c
-+++ elfutils-0.148/libelf/elf_begin.c
-@@ -68,6 +68,9 @@
- #include "libelfP.h"
- #include "common.h"
- 
-+#ifdef __UCLIBC__
-+#define __mempcpy mempcpy
-+#endif
- 
- /* Create descriptor for archive in memory.  */
- static inline Elf *
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.148.bb b/yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.148.bb
index 0d8490d..ff53257 100644
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.148.bb
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.148.bb
@@ -27,7 +27,6 @@
         file://elf_additions.diff \
         file://elfutils-fsize.patch \
         file://remove-unused.patch \
-        file://mempcpy.patch \
         file://fix_for_gcc-4.7.patch \
         file://dso-link-change.patch \
         file://nm-Fix-size-passed-to-snprintf-for-invalid-sh_name-case.patch \
diff --git a/yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.163.bb b/yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.164.bb
similarity index 78%
rename from yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.163.bb
rename to yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.164.bb
index e391813..4964c05 100644
--- a/yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.163.bb
+++ b/yocto-poky/meta/recipes-devtools/elfutils/elfutils_0.164.bb
@@ -4,40 +4,40 @@
 LICENSE = "(GPLv3 & Elfutils-Exception)"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
 DEPENDS = "libtool bzip2 zlib virtual/libintl"
+DEPENDS_append_libc-musl = " argp-standalone fts "
 
 SRC_URI = "https://fedorahosted.org/releases/e/l/elfutils/${PV}/${BP}.tar.bz2"
 
-SRC_URI[md5sum] = "77ce87f259987d2e54e4d87b86cbee41"
-SRC_URI[sha256sum] = "7c774f1eef329309f3b05e730bdac50013155d437518a2ec0e24871d312f2e23"
+SRC_URI[md5sum] = "2e4536c1c48034f188a80789a59114d8"
+SRC_URI[sha256sum] = "9683c025928a12d06b7fe812928aa6235249e22d197d086f7084606a48165900"
 
 SRC_URI += "\
-        file://mempcpy.patch \
         file://dso-link-change.patch \
         file://Fix_elf_cvt_gunhash.patch \
         file://fixheadercheck.patch \
         file://0001-elf_getarsym-Silence-Werror-maybe-uninitialized-fals.patch \
         file://0001-remove-the-unneed-checking.patch \
         file://0001-fix-a-stack-usage-warning.patch \
+        file://aarch64_uio.patch \
+        file://shadow.patch \
 "
 
 # pick the patch from debian
-# http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.159-4.debian.tar.xz
+# http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.164-1.debian.tar.xz
 SRC_URI += "\
-        file://redhat-portability.diff \
         file://hppa_backend.diff \
         file://arm_backend.diff \
         file://mips_backend.diff \
         file://m68k_backend.diff \
         file://testsuite-ignore-elflint.diff \
-        file://scanf-format.patch \
         file://mips_readelf_w.patch \
-        file://arm_func_value.patch \
-        file://arm_unwind_ret_mask.patch \
-        file://non_linux.patch \
+        file://kfreebsd_path.patch \
+        file://0001-Ignore-differences-between-mips-machine-identifiers.patch \
+        file://0002-Add-support-for-mips64-abis-in-mips_retval.c.patch \
+        file://0003-Add-mips-n64-relocation-format-hack.patch \
+        file://uclibc-support.patch \
 "
-
-# Only apply when building uclibc based target recipe
-SRC_URI_append_libc-uclibc = " file://uclibc-support-for-elfutils-0.161.patch"
+SRC_URI_append_libc-musl = " file://0001-build-Provide-alternatives-for-glibc-assumptions-hel.patch "
 
 # The buildsystem wants to generate 2 .h files from source using a binary it just built,
 # which can not pass the cross compiling, so let's work around it by adding 2 .h files
@@ -51,7 +51,7 @@
 
 do_install_append() {
 	if [ "${TARGET_ARCH}" != "x86_64" ] && [ -z `echo "${TARGET_ARCH}"|grep 'i.86'` ];then
-		rm ${D}${bindir}/eu-objdump
+		rm -f ${D}${bindir}/eu-objdump
 	fi
 }
 
@@ -63,6 +63,8 @@
 EXTRA_OEMAKE_class-native = ""
 EXTRA_OEMAKE_class-nativesdk = ""
 
+ALLOW_EMPTY_${PN}_libc-musl = "1"
+
 BBCLASSEXTEND = "native nativesdk"
 
 # Package utilities separately
diff --git a/yocto-poky/meta/recipes-devtools/expect/expect_5.45.bb b/yocto-poky/meta/recipes-devtools/expect/expect_5.45.bb
index 3c2aab4..b4dfe15 100644
--- a/yocto-poky/meta/recipes-devtools/expect/expect_5.45.bb
+++ b/yocto-poky/meta/recipes-devtools/expect/expect_5.45.bb
@@ -29,6 +29,9 @@
 SRC_URI[md5sum] = "44e1a4f4c877e9ddc5a542dfa7ecc92b"
 SRC_URI[sha256sum] = "b28dca90428a3b30e650525cdc16255d76bb6ccd65d448be53e620d95d5cc040"
 
+UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/expect/files/Expect/"
+UPSTREAM_CHECK_REGEX = "/Expect/(?P<pver>(\d+[\.\-_]*)+)/"
+
 S = "${WORKDIR}/${BPN}${PV}"
 
 do_install_append() {
@@ -48,9 +51,6 @@
                 "
 EXTRA_OEMAKE_install = " 'SCRIPTS=' "
 
-FILES_${PN}-dbg += "${libdir}/${BPN}${PV}/.debug \
-                    ${libdir}/.debug \
-                   "
 FILES_${PN}-dev = "${libdir_native}/expect${PV}/libexpect*.so \
                    ${includedir}/expect.h \
                    ${includedir}/expect_tcl.h \
diff --git a/yocto-poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.0.bb b/yocto-poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.1.bb
similarity index 64%
rename from yocto-poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.0.bb
rename to yocto-poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.1.bb
index f4b0e32..8fab28f 100644
--- a/yocto-poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.0.bb
+++ b/yocto-poky/meta/recipes-devtools/fdisk/gptfdisk_1.0.1.bb
@@ -1,3 +1,4 @@
+SUMMARY = "Utility for modifying GPT disk partitioning"
 DESCRIPTION = "GPT fdisk is a disk partitioning tool loosely modeled on Linux fdisk, but used for modifying GUID Partition Table (GPT) disks. The related FixParts utility fixes some common problems on Master Boot Record (MBR) disks."
 
 LICENSE = "GPLv2"
@@ -6,8 +7,13 @@
 DEPENDS = "util-linux popt ncurses"
 
 SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${PV}/${BP}.tar.gz"
-SRC_URI[md5sum] = "2061f917af084215898d4fea04d8388f"
-SRC_URI[sha256sum] = "5b66956743a799fc0471cdb032665c1391e82f9c5b3f1d7d726d29fe2ba01d6c"
+SRC_URI[md5sum] = "d7f3d306b083123bcc6f5941efade586"
+SRC_URI[sha256sum] = "864c8aee2efdda50346804d7e6230407d5f42a8ae754df70404dd8b2fdfaeac7"
+
+UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/gptfdisk/files/gptfdisk/"
+UPSTREAM_CHECK_REGEX = "/gptfdisk/(?P<pver>(\d+[\.\-_]*)+)/"
+
+EXTRA_OEMAKE = "-e MAKEFLAGS="
 
 do_install() {
     install -d ${D}${sbindir}
diff --git a/yocto-poky/meta/recipes-devtools/file/file_5.24.bb b/yocto-poky/meta/recipes-devtools/file/file_5.25.bb
similarity index 89%
rename from yocto-poky/meta/recipes-devtools/file/file_5.24.bb
rename to yocto-poky/meta/recipes-devtools/file/file_5.25.bb
index d04f121..68bad69 100644
--- a/yocto-poky/meta/recipes-devtools/file/file_5.24.bb
+++ b/yocto-poky/meta/recipes-devtools/file/file_5.25.bb
@@ -11,13 +11,16 @@
 DEPENDS = "zlib file-replacement-native"
 DEPENDS_class-native = "zlib-native"
 
+# Blacklist a bogus tag in upstream check
+UPSTREAM_CHECK_GITTAGREGEX = "FILE(?P<pver>(?!6_23).+)"
+
 SRC_URI = "git://github.com/file/file.git \
         file://debian-742262.patch \
         file://0001-Add-P-prompt-into-Usage-info.patch \
         file://host-file.patch \
         "
 
-SRCREV = "3c0874be4d3232d672b20f513451a39cfd7c585a"
+SRCREV = "f45db89ddc91692b662fffbabbdafc7bc4c00f5e"
 S = "${WORKDIR}/git"
 
 inherit autotools
diff --git a/yocto-poky/meta/recipes-devtools/flex/files/run-ptest b/yocto-poky/meta/recipes-devtools/flex/files/run-ptest
deleted file mode 100755
index bffba16..0000000
--- a/yocto-poky/meta/recipes-devtools/flex/files/run-ptest
+++ /dev/null
@@ -1,29 +0,0 @@
-#!/bin/sh
-
-test1="test-alloc-extra test-array-nr test-array-r test-basic-nr test-basic-r test-extended test-quotes \
-test-bison-nr test-bison-yylloc test-bison-yylval test-c++-basic test-c-cpp-nr test-prefix-nr test-ccl \
-test-c-cpp-r test-c++-multiple-scanners test-mem-r test-mem-nr test-debug-nr test-linedir-r test-noansi-r \
-test-yyextra test-header-r test-noansi-nr test-debug-r TEMPLATE test-top test-header-nr test-prefix-r"
-test2="test-multiple-scanners-nr test-posixly-correct test-posix test-string-r test-string-nr"
-test3="test-pthread test-include-by-push test-include-by-buffer test-include-by-reentrant"
-test4="test-lineno-nr test-lineno-r test-lineno-trailing"
-test5="test-c++-yywrap test-rescan-r test-rescan-nr"
-test6="test-reject-nr test-reject-r"
-test7="test-reject-ser test-reject-ver"
-test8="test-multiple-scanners-r"
-
-output() {
-  if [ $? -eq 0 ]; \
-    then echo "PASS: $i"; \
-    else echo "FAIL: $i"; \
-  fi;
-}
-
-for i in $test1; do $i/$i < $i/test.input >/dev/null; output; done
-for i in $test2; do $i/$i >/dev/null; output; done
-for i in $test3; do cd $i; ./$i test-1.input >/dev/null; output; cd ..; done
-for i in $test4; do test `$i/$i < $i/test.input` -eq `$i/$i 1 < $i/test.input` >/dev/null; output; done
-for i in $test5; do $i/$i $i/test.input >/dev/null; output; done
-for i in $test6; do test-reject/$i < test-reject/test.input >/dev/null; output; done
-for i in $test7; do test-reject/$i test-reject/$i.tables < test-reject/test.input >/dev/null; output; done
-cd $test8; ./$test8 >/dev/null; i=$test8 output
diff --git a/yocto-poky/meta/recipes-devtools/flex/flex.inc b/yocto-poky/meta/recipes-devtools/flex/flex.inc
deleted file mode 100644
index a4a26e2..0000000
--- a/yocto-poky/meta/recipes-devtools/flex/flex.inc
+++ /dev/null
@@ -1,44 +0,0 @@
-SUMMARY = "Flex (The Fast Lexical Analyzer)"
-DESCRIPTION = "Flex is a fast lexical analyser generator.  Flex is a tool for generating programs that recognize \
-lexical patterns in text."
-HOMEPAGE = "http://sourceforge.net/projects/flex/"
-
-SECTION = "devel"
-LICENSE = "BSD"
-DEPENDS += "${@'bison-native flex-native' if '${PTEST_ENABLED}' == '1' else ''}"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/flex/flex-${PV}.tar.bz2 \
-           file://run-ptest \
-"
-
-inherit autotools gettext texinfo ptest
-
-
-M4 = "${bindir}/m4"
-M4_class-native = "${STAGING_BINDIR_NATIVE}/m4"
-
-EXTRA_OECONF += "ac_cv_path_M4=${M4}"
-EXTRA_OEMAKE += "m4=${STAGING_BINDIR_NATIVE}/m4"
-
-do_install_append_class-native() {
-	create_wrapper ${D}/${bindir}/flex M4=${M4}
-}
-
-do_install_append_class-nativesdk() {
-	create_wrapper ${D}/${bindir}/flex M4=${M4}
-}
-
-RDEPENDS_${PN} += "m4"
-
-do_compile_ptest() {
-	for i in `find ${S}/tests/ -type d |grep -Ev "concatenated-options|reject|table-opts" | awk -F/ '{print $NF}'`; \
-	  do oe_runmake -C ${S}/tests/$i -f ${B}/tests/$i/Makefile top_builddir=${B} FLEX=flex $i; \
-	done
-	oe_runmake -C ${S}/tests/test-reject -f ${B}/tests/test-reject/Makefile top_builddir=${B} FLEX=flex test-reject-nr test-reject-r test-reject-ser test-reject-ver
-}
-
-do_install_ptest() {
-	for i in `find ${S}/tests/ -type d | awk -F/ '{print $NF}'`; \
-	  do cp -r ${S}/tests/$i ${D}${PTEST_PATH}; \
-	done
-}
diff --git a/yocto-poky/meta/recipes-devtools/flex/flex/0001-tests-add-a-target-for-building-tests-without-runnin.patch b/yocto-poky/meta/recipes-devtools/flex/flex/0001-tests-add-a-target-for-building-tests-without-runnin.patch
new file mode 100644
index 0000000..556c240
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/flex/flex/0001-tests-add-a-target-for-building-tests-without-runnin.patch
@@ -0,0 +1,28 @@
+From b4aa18d939fc0c8825fa584dfcee1a7da61099cf Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Thu, 10 Dec 2015 16:09:26 +0200
+Subject: [PATCH] tests: add a target for building tests without running them
+
+Upstream-Status: Inappropriate [oe specific]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ tests/Makefile.am | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/tests/Makefile.am b/tests/Makefile.am
+index 4ac3c17..0025cfe 100644
+--- a/tests/Makefile.am
++++ b/tests/Makefile.am
+@@ -21,6 +21,9 @@
+ 
+ TESTS = $(check_PROGRAMS) options.cn
+ 
++# This allows building tests without running them
++buildtests: $(TESTS)
++
+ # The script testwrapper.sh will run most tests as is. A couple tests
+ # in the suite end in .reject, .table and the like so that we can pass
+ # different arguments to the test runner. We list those extensions so
+-- 
+2.6.2
+
diff --git a/yocto-poky/meta/recipes-devtools/flex/flex/disable-tests.patch b/yocto-poky/meta/recipes-devtools/flex/flex/disable-tests.patch
new file mode 100644
index 0000000..4dc801d
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/flex/flex/disable-tests.patch
@@ -0,0 +1,19 @@
+Due to automake stupidity the Makefile in tests/ has an 'all' target that
+depends on $(BUILD_SOURCES), which means when building flex parts of the test
+suite are built even if they're not needed, resulting in flex needing
+flex-native and bison-native to build.
+
+This patch removes the tests directory from SUBDIRS and will be conditionally
+applied by the recipe.
+
+Upstream-Status: Inappropriate
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+diff --git a/Makefile.am b/Makefile.am
+index 076ccad..0574d7b 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -55,3 +55,2 @@ SUBDIRS = \
+ 	po \
+-	tests \
+ 	tools
diff --git a/yocto-poky/meta/recipes-devtools/flex/files/do_not_create_pdf_doc.patch b/yocto-poky/meta/recipes-devtools/flex/flex/do_not_create_pdf_doc.patch
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/flex/files/do_not_create_pdf_doc.patch
rename to yocto-poky/meta/recipes-devtools/flex/flex/do_not_create_pdf_doc.patch
diff --git a/yocto-poky/meta/recipes-devtools/flex/flex/run-ptest b/yocto-poky/meta/recipes-devtools/flex/flex/run-ptest
new file mode 100755
index 0000000..19db337
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/flex/flex/run-ptest
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+# make would want to rebuild some files with a compiler otherwise :-/
+make FLEX=/usr/bin/flex -t check-TESTS || true
+make FLEX=/usr/bin/flex check-TESTS
diff --git a/yocto-poky/meta/recipes-devtools/flex/flex_2.5.39.bb b/yocto-poky/meta/recipes-devtools/flex/flex_2.5.39.bb
deleted file mode 100644
index 7485743..0000000
--- a/yocto-poky/meta/recipes-devtools/flex/flex_2.5.39.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-require flex.inc
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=e4742cf92e89040b39486a6219b68067"
-BBCLASSEXTEND = "native nativesdk"
-
-SRC_URI += "file://do_not_create_pdf_doc.patch"
-
-SRC_URI[md5sum] = "77d44c6bb8c0705e0017ab9a84a1502b"
-SRC_URI[sha256sum] = "add2b55f3bc38cb512b48fad7d72f43b11ef244487ff25fc00aabec1e32b617f"
diff --git a/yocto-poky/meta/recipes-devtools/flex/flex_2.6.0.bb b/yocto-poky/meta/recipes-devtools/flex/flex_2.6.0.bb
new file mode 100644
index 0000000..8285426
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/flex/flex_2.6.0.bb
@@ -0,0 +1,55 @@
+SUMMARY = "Flex (The Fast Lexical Analyzer)"
+DESCRIPTION = "Flex is a fast lexical analyser generator.  Flex is a tool for generating programs that recognize \
+lexical patterns in text."
+HOMEPAGE = "http://sourceforge.net/projects/flex/"
+SECTION = "devel"
+LICENSE = "BSD"
+
+DEPENDS = "${@bb.utils.contains('PTEST_ENABLED', '1', 'bison-native flex-native', '', d)}"
+BBCLASSEXTEND = "native nativesdk"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=e4742cf92e89040b39486a6219b68067"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/flex/flex-${PV}.tar.bz2 \
+           file://run-ptest \
+           file://do_not_create_pdf_doc.patch \
+           file://0001-tests-add-a-target-for-building-tests-without-runnin.patch \
+           ${@bb.utils.contains('PTEST_ENABLED', '1', '', 'file://disable-tests.patch', d)} \
+           "
+
+SRC_URI[md5sum] = "266270f13c48ed043d95648075084d59"
+SRC_URI[sha256sum] = "24e611ef5a4703a191012f80c1027dc9d12555183ce0ecd46f3636e587e9b8e9"
+
+UPSTREAM_CHECK_REGEX = "flex-(?P<pver>\d+(\.\d+)+)\.tar"
+
+inherit autotools gettext texinfo ptest
+
+M4 = "${bindir}/m4"
+M4_class-native = "${STAGING_BINDIR_NATIVE}/m4"
+EXTRA_OECONF += "ac_cv_path_M4=${M4}"
+EXTRA_OEMAKE += "m4=${STAGING_BINDIR_NATIVE}/m4"
+
+EXTRA_OEMAKE += "${@bb.utils.contains('PTEST_ENABLED', '1', 'FLEX=${STAGING_BINDIR_NATIVE}/flex', '', d)}"
+
+do_install_append_class-native() {
+	create_wrapper ${D}/${bindir}/flex M4=${M4}
+}
+
+do_install_append_class-nativesdk() {
+	create_wrapper ${D}/${bindir}/flex M4=${M4}
+}
+
+RDEPENDS_${PN} += "m4"
+RDEPENDS_${PN}-ptest += "bash gawk"
+
+do_compile_ptest() {
+	oe_runmake -C ${B}/tests -f ${B}/tests/Makefile top_builddir=${B} INCLUDES=-I${S}/src buildtests
+}
+
+do_install_ptest() {
+	mkdir -p ${D}${PTEST_PATH}/build-aux/
+	cp ${S}/build-aux/test-driver ${D}${PTEST_PATH}/build-aux/
+	cp -r ${S}/tests/* ${D}${PTEST_PATH}
+	cp -r ${B}/tests/* ${D}${PTEST_PATH}
+	sed -e 's/^Makefile:/_Makefile:/' -e 's/^srcdir = \(.*\)/srcdir = ./' -e 's/^top_srcdir = \(.*\)/top_srcdir = ./'  -i ${D}${PTEST_PATH}/Makefile
+}
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8.inc
deleted file mode 100644
index b3e1c33..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8.inc
+++ /dev/null
@@ -1,119 +0,0 @@
-require gcc-common.inc
-
-# Third digit in PV should be incremented after a minor release
-
-PV = "4.8.4"
-
-# BINV should be incremented to a revision after a minor gcc release
-
-BINV = "4.8.4"
-
-FILESEXTRAPATHS =. "${FILE_DIRNAME}/gcc-4.8:"
-
-DEPENDS =+ "mpfr gmp libmpc zlib"
-NATIVEDEPS = "mpfr-native gmp-native libmpc-native zlib-native"
-
-LICENSE = "GPL-3.0-with-GCC-exception & GPLv3"
-
-LIC_FILES_CHKSUM = "\
-    file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
-    file://COPYING3;md5=d32239bcb673463ab874e80d47fae504 \
-    file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
-    file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
-    file://COPYING.RUNTIME;md5=fe60d87048567d4fe8c8a0ed2448bcc8 \
-"
-
-SRC_URI = "\
-    ${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
-    file://0002-uclibc-conf.patch \
-    file://0003-gcc-uclibc-locale-ctype_touplow_t.patch \
-    file://0004-uclibc-locale.patch \
-    file://0005-uclibc-locale-no__x.patch \
-    file://0006-uclibc-locale-wchar_fix.patch \
-    file://0007-uclibc-locale-update.patch \
-    file://0008-missing-execinfo_h.patch \
-    file://0009-c99-snprintf.patch \
-    file://0010-c99-complex-ugly-hack.patch \
-    file://0011-index_macro.patch \
-    file://0012-libmudflap-susv3-legacy.patch \
-    file://0013-libstdc-namespace.patch \
-    file://0014-sh-pr24836.patch \
-    file://0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch \
-    file://0016-gcc-poison-system-directories.patch \
-    file://0017-gcc-poison-dir-extend.patch \
-    file://0018-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch \
-    file://0019-64-bit-multilib-hack.patch \
-    file://0020-optional-libstdc.patch \
-    file://0021-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch \
-    file://0022-COLLECT_GCC_OPTIONS.patch \
-    file://0023-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch \
-    file://0024-PR-target-32219.patch \
-    file://0025-fortran-cross-compile-hack.patch \
-    file://0026-libgcc-sjlj-check.patch \
-    file://0027-cpp-honor-sysroot.patch \
-    file://0028-MIPS64-Default-to-N64-ABI.patch \
-    file://0029-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch \
-    file://0030-gcc-Fix-argument-list-too-long-error.patch \
-    file://0031-Disable-sdt.patch \
-    file://0032-libtool.patch \
-    file://0033-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch \
-    file://0034-Use-the-multilib-config-files-from-B-instead-of-usin.patch \
-    file://0035-wcast-qual-PR-55383.patch \
-    file://0038-gcc-4.8-build-args.patch \
-    file://0040-fix-g++-sysroot.patch \
-    file://0041-libtool-avoid-libdir.patch \
-    file://0042-pr57748.patch \
-    file://0043-cpp.patch \
-    file://0044-gengtypes.patch \
-    file://0046-libatomic-deptracking.patch \
-    file://0047-repomembug.patch \
-    file://0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch \
-    file://target-gcc-includedir.patch \
-    file://0051-gcc-483-universal-initializer-no-warning.patch \
-"
-SRC_URI[md5sum] = "5a84a30839b2aca22a2d723de2a626ec"
-SRC_URI[sha256sum] = "4a80aa23798b8e9b5793494b8c976b39b8d9aa2e53cd5ed5534aff662a7f8695"
-
-S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/gcc-${PV}"
-B = "${WORKDIR}/gcc-${PV}/build.${HOST_SYS}.${TARGET_SYS}"
-
-# Language Overrides
-FORTRAN = ""
-JAVA = ""
-
-LTO = "--enable-lto"
-
-EXTRA_OECONF_BASE = "\
-    ${LTO} \
-    --enable-libssp \
-    --disable-bootstrap \
-    --disable-libmudflap \
-    --with-system-zlib \
-    --with-linker-hash-style=${LINKER_HASH_STYLE} \
-    --enable-linker-build-id \
-    --with-ppl=no \
-    --with-cloog=no \
-    --enable-checking=release \
-    --enable-cheaders=c_global \
-"
-
-EXTRA_OECONF_INITIAL = "\
-    --disable-libmudflap \
-    --disable-libgomp \
-    --disable-libssp \
-    --disable-libquadmath \
-    --with-system-zlib \
-    --disable-lto \
-    --disable-plugin \
-    --enable-decimal-float=no \
-"
-
-EXTRA_OECONF_append_libc-uclibc = " --disable-decimal-float "
-
-EXTRA_OECONF_PATHS = "\ 
-    --with-gxx-include-dir=${STAGING_DIR_TARGET}${target_includedir}/c++/${BINV} \ 
-    --with-sysroot=${STAGING_DIR_TARGET} \ 
-    --with-build-sysroot=${STAGING_DIR_TARGET} \
-"
-
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
deleted file mode 100644
index e588011..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From bf3d96ae58fa180b8b468d25dc2e0209daca2751 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:37:11 +0400
-Subject: [PATCH 01/35] gcc-4.3.1: ARCH_FLAGS_FOR_TARGET
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Inappropriate [embedded specific]
----
- configure    |    2 +-
- configure.ac |    2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/configure b/configure
-index d809535..1b76c90 100755
---- a/configure
-+++ b/configure
-@@ -7439,7 +7439,7 @@ fi
- # for target_alias and gcc doesn't manage it consistently.
- target_configargs="--cache-file=./config.cache ${target_configargs}"
- 
--FLAGS_FOR_TARGET=
-+FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET"
- case " $target_configdirs " in
-  *" newlib "*)
-   case " $target_configargs " in
-diff --git a/configure.ac b/configure.ac
-index 48ec1aa..89d1d3f 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -2873,7 +2873,7 @@ fi
- # for target_alias and gcc doesn't manage it consistently.
- target_configargs="--cache-file=./config.cache ${target_configargs}"
- 
--FLAGS_FOR_TARGET=
-+FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET"
- case " $target_configdirs " in
-  *" newlib "*)
-   case " $target_configargs " in
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0002-uclibc-conf.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0002-uclibc-conf.patch
deleted file mode 100644
index dda3b10..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0002-uclibc-conf.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From d030973c872c00d916921d84deee0af2c0d38081 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:38:25 +0400
-Subject: [PATCH 02/35] uclibc-conf
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- contrib/regression/objs-gcc.sh |    4 ++++
- libjava/classpath/ltconfig     |    4 ++--
- 2 files changed, 6 insertions(+), 2 deletions(-)
-
-diff --git a/contrib/regression/objs-gcc.sh b/contrib/regression/objs-gcc.sh
-index 60b0497..6dc7ead 100755
---- a/contrib/regression/objs-gcc.sh
-+++ b/contrib/regression/objs-gcc.sh
-@@ -106,6 +106,10 @@ if [ $H_REAL_TARGET = $H_REAL_HOST -a $H_REAL_TARGET = i686-pc-linux-gnu ]
-  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
-diff --git a/libjava/classpath/ltconfig b/libjava/classpath/ltconfig
-index 743d951..ae4ea60 100755
---- a/libjava/classpath/ltconfig
-+++ b/libjava/classpath/ltconfig
-@@ -603,7 +603,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
- 
- # Transform linux* to *-*-linux-gnu*, to support old configure scripts.
- case $host_os in
--linux-gnu*) ;;
-+linux-gnu*|linux-uclibc*) ;;
- linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
- esac
- 
-@@ -1247,7 +1247,7 @@ linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*)
-   ;;
- 
- # This must be Linux ELF.
--linux-gnu*)
-+linux*)
-   version_type=linux
-   need_lib_prefix=no
-   need_version=no
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0003-gcc-uclibc-locale-ctype_touplow_t.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0003-gcc-uclibc-locale-ctype_touplow_t.patch
deleted file mode 100644
index 7098e99..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0003-gcc-uclibc-locale-ctype_touplow_t.patch
+++ /dev/null
@@ -1,87 +0,0 @@
-From d2d9dd756c4356d14dd7ae003856344cb4f37985 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:40:12 +0400
-Subject: [PATCH 03/35] gcc-uclibc-locale-ctype_touplow_t
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- libstdc++-v3/config/locale/generic/c_locale.cc |    5 +++++
- libstdc++-v3/config/locale/generic/c_locale.h  |    9 +++++++++
- libstdc++-v3/config/os/gnu-linux/ctype_base.h  |    9 +++++++++
- 3 files changed, 23 insertions(+)
-
-diff --git a/libstdc++-v3/config/locale/generic/c_locale.cc b/libstdc++-v3/config/locale/generic/c_locale.cc
-index 0d309a5..f2f1e1f 100644
---- a/libstdc++-v3/config/locale/generic/c_locale.cc
-+++ b/libstdc++-v3/config/locale/generic/c_locale.cc
-@@ -263,5 +263,10 @@ _GLIBCXX_END_NAMESPACE_VERSION
- #ifdef _GLIBCXX_LONG_DOUBLE_COMPAT
- #define _GLIBCXX_LDBL_COMPAT(dbl, ldbl) \
-   extern "C" void ldbl (void) __attribute__ ((alias (#dbl)))
-+#ifdef __UCLIBC__
-+// This is because __c_locale is of type __ctype_touplow_t* which is short on uclibc. for glibc its int*
-+_GLIBCXX_LDBL_COMPAT(_ZSt14__convert_to_vIdEvPKcRT_RSt12_Ios_IostateRKPs, _ZSt14__convert_to_vIeEvPKcRT_RSt12_Ios_IostateRKPs);
-+#else
- _GLIBCXX_LDBL_COMPAT(_ZSt14__convert_to_vIdEvPKcRT_RSt12_Ios_IostateRKPi, _ZSt14__convert_to_vIeEvPKcRT_RSt12_Ios_IostateRKPi);
-+#endif
- #endif // _GLIBCXX_LONG_DOUBLE_COMPAT
-diff --git a/libstdc++-v3/config/locale/generic/c_locale.h b/libstdc++-v3/config/locale/generic/c_locale.h
-index b5fd989..3da9a5d 100644
---- a/libstdc++-v3/config/locale/generic/c_locale.h
-+++ b/libstdc++-v3/config/locale/generic/c_locale.h
-@@ -40,13 +40,22 @@
- 
- #include <clocale>
- 
-+#ifdef __UCLIBC__
-+#include <features.h>
-+#include <ctype.h>
-+#endif
-+
- #define _GLIBCXX_NUM_CATEGORIES 0
- 
- namespace std _GLIBCXX_VISIBILITY(default)
- {
- _GLIBCXX_BEGIN_NAMESPACE_VERSION
- 
-+#ifdef __UCLIBC__
-+  typedef __ctype_touplow_t*	__c_locale;
-+#else
-   typedef int*			__c_locale;
-+#endif
- 
-   // Convert numeric value of type double and long double to string and
-   // return length of string.  If vsnprintf is available use it, otherwise
-diff --git a/libstdc++-v3/config/os/gnu-linux/ctype_base.h b/libstdc++-v3/config/os/gnu-linux/ctype_base.h
-index 2d8e978..14eb08f 100644
---- a/libstdc++-v3/config/os/gnu-linux/ctype_base.h
-+++ b/libstdc++-v3/config/os/gnu-linux/ctype_base.h
-@@ -33,6 +33,11 @@
- 
- // Information as gleaned from /usr/include/ctype.h
- 
-+#ifdef __UCLIBC__
-+#include <features.h>
-+#include <ctype.h>
-+#endif
-+
- namespace std _GLIBCXX_VISIBILITY(default)
- {
- _GLIBCXX_BEGIN_NAMESPACE_VERSION
-@@ -41,7 +46,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
-   struct ctype_base
-   {
-     // Non-standard typedefs.
-+#ifdef __UCLIBC__
-+    typedef const __ctype_touplow_t*	__to_type;
-+#else
-     typedef const int* 		__to_type;
-+#endif
- 
-     // NB: Offsets into ctype<char>::_M_table force a particular size
-     // on the mask type. Because of this, we don't use an enum.
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0004-uclibc-locale.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0004-uclibc-locale.patch
deleted file mode 100644
index 49f5f33..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0004-uclibc-locale.patch
+++ /dev/null
@@ -1,2862 +0,0 @@
-From a55c751a449c2cbf0b3fcc07aab1b86bf9661510 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:41:39 +0400
-Subject: [PATCH 04/35] uclibc-locale
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- libstdc++-v3/acinclude.m4                          |   37 ++
- .../config/locale/uclibc/c++locale_internal.h      |   63 ++
- libstdc++-v3/config/locale/uclibc/c_locale.cc      |  160 +++++
- libstdc++-v3/config/locale/uclibc/c_locale.h       |  117 ++++
- .../config/locale/uclibc/codecvt_members.cc        |  308 +++++++++
- .../config/locale/uclibc/collate_members.cc        |   80 +++
- libstdc++-v3/config/locale/uclibc/ctype_members.cc |  300 +++++++++
- .../config/locale/uclibc/messages_members.cc       |  100 +++
- .../config/locale/uclibc/messages_members.h        |  118 ++++
- .../config/locale/uclibc/monetary_members.cc       |  692 ++++++++++++++++++++
- .../config/locale/uclibc/numeric_members.cc        |  160 +++++
- libstdc++-v3/config/locale/uclibc/time_members.cc  |  406 ++++++++++++
- libstdc++-v3/config/locale/uclibc/time_members.h   |   68 ++
- libstdc++-v3/configure                             |   75 +++
- libstdc++-v3/include/c_compatibility/wchar.h       |    2 +
- libstdc++-v3/include/c_std/cwchar                  |    2 +
- 16 files changed, 2688 insertions(+)
- create mode 100644 libstdc++-v3/config/locale/uclibc/c++locale_internal.h
- create mode 100644 libstdc++-v3/config/locale/uclibc/c_locale.cc
- create mode 100644 libstdc++-v3/config/locale/uclibc/c_locale.h
- create mode 100644 libstdc++-v3/config/locale/uclibc/codecvt_members.cc
- create mode 100644 libstdc++-v3/config/locale/uclibc/collate_members.cc
- create mode 100644 libstdc++-v3/config/locale/uclibc/ctype_members.cc
- create mode 100644 libstdc++-v3/config/locale/uclibc/messages_members.cc
- create mode 100644 libstdc++-v3/config/locale/uclibc/messages_members.h
- create mode 100644 libstdc++-v3/config/locale/uclibc/monetary_members.cc
- create mode 100644 libstdc++-v3/config/locale/uclibc/numeric_members.cc
- create mode 100644 libstdc++-v3/config/locale/uclibc/time_members.cc
- create mode 100644 libstdc++-v3/config/locale/uclibc/time_members.h
-
-diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4
-index 0871a6a..326d7ef 100644
---- a/libstdc++-v3/acinclude.m4
-+++ b/libstdc++-v3/acinclude.m4
-@@ -1905,6 +1905,9 @@ AC_DEFUN([GLIBCXX_ENABLE_CLOCALE], [
-   # 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)
- 	enable_clocale_flag=gnu
- 	;;
-@@ -2069,6 +2072,40 @@ AC_DEFUN([GLIBCXX_ENABLE_CLOCALE], [
-       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 --git a/libstdc++-v3/config/locale/uclibc/c++locale_internal.h b/libstdc++-v3/config/locale/uclibc/c++locale_internal.h
-new file mode 100644
-index 0000000..2ae3e4a
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/c++locale_internal.h
-@@ -0,0 +1,63 @@
-+// Prototypes for GLIBC thread locale __-prefixed functions -*- C++ -*-
-+
-+// Copyright (C) 2002, 2004, 2005 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 <jakub@redhat.com>
-+
-+#include <bits/c++config.h>
-+#include <clocale>
-+
-+#ifdef __UCLIBC_MJN3_ONLY__
-+#warning clean this up
-+#endif
-+
-+#ifdef __UCLIBC_HAS_XLOCALE__
-+
-+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(newlocale) __newlocale;
-+extern "C" __typeof(freelocale) __freelocale;
-+extern "C" __typeof(duplocale) __duplocale;
-+extern "C" __typeof(uselocale) __uselocale;
-+
-+#ifdef _GLIBCXX_USE_WCHAR_T
-+extern "C" __typeof(iswctype_l) __iswctype_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;
-+#endif
-+
-+#endif // GLIBC 2.3 and later
-diff --git a/libstdc++-v3/config/locale/uclibc/c_locale.cc b/libstdc++-v3/config/locale/uclibc/c_locale.cc
-new file mode 100644
-index 0000000..5081dc1
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/c_locale.cc
-@@ -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 <bkoz@redhat.com>
-+
-+#include <cerrno>  // For errno
-+#include <locale>
-+#include <stdexcept>
-+#include <langinfo.h>
-+#include <bits/c++locale_internal.h>
-+
-+#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 --git a/libstdc++-v3/config/locale/uclibc/c_locale.h b/libstdc++-v3/config/locale/uclibc/c_locale.h
-new file mode 100644
-index 0000000..da07c1f
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/c_locale.h
-@@ -0,0 +1,117 @@
-+// Wrapper for underlying C-language localization -*- C++ -*-
-+
-+// Copyright (C) 2001, 2002, 2003, 2004, 2005 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 <bkoz@redhat.com>
-+
-+#ifndef _C_LOCALE_H
-+#define _C_LOCALE_H 1
-+
-+#pragma GCC system_header
-+
-+#include <cstring>              // get std::strlen
-+#include <cstdio>               // get std::snprintf or std::sprintf
-+#include <clocale>
-+#include <langinfo.h>		// For codecvt
-+#ifdef __UCLIBC_MJN3_ONLY__
-+#warning fix this
-+#endif
-+#ifdef __UCLIBC_HAS_LOCALE__
-+#include <iconv.h>		// For codecvt using iconv, iconv_t
-+#endif
-+#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__
-+#include <libintl.h> 		// 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<typename _Tv>
-+    int
-+    __convert_from_v(char* __out,
-+		     const int __size __attribute__ ((__unused__)),
-+		     const char* __fmt,
-+#ifdef __UCLIBC_HAS_XCLOCALE__
-+		     _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_XCLOCALE__
-+      __gnu_cxx::__uselocale(__old);
-+#elif defined __UCLIBC_HAS_LOCALE__
-+      std::setlocale(LC_ALL, __sav);
-+      delete [] __sav;
-+#endif
-+      return __ret;
-+    }
-+}
-+
-+#endif
-diff --git a/libstdc++-v3/config/locale/uclibc/codecvt_members.cc b/libstdc++-v3/config/locale/uclibc/codecvt_members.cc
-new file mode 100644
-index 0000000..64aa962
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/codecvt_members.cc
-@@ -0,0 +1,308 @@
-+// 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 <bkoz@redhat.com>
-+
-+#include <locale>
-+#include <cstdlib>  // For MB_CUR_MAX
-+#include <climits>  // For MB_LEN_MAX
-+#include <bits/c++locale_internal.h>
-+
-+namespace std
-+{
-+  // Specializations.
-+#ifdef _GLIBCXX_USE_WCHAR_T
-+  codecvt_base::result
-+  codecvt<wchar_t, char, mbstate_t>::
-+  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<size_t>(-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<size_t>(__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<wchar_t, char, mbstate_t>::
-+  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<const extern_type*>(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<size_t>(-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<size_t>(-1)
-+		    || __conv == static_cast<size_t>(-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<wchar_t, char, mbstate_t>::
-+  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<wchar_t, char, mbstate_t>::
-+  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<wchar_t, char, mbstate_t>::
-+  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<wchar_t*>(__builtin_alloca(sizeof(wchar_t)
-+							   * __max));
-+    while (__from < __end && __max)
-+      {
-+	const extern_type* __from_chunk_end;
-+	__from_chunk_end = static_cast<const extern_type*>(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<size_t>(-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<size_t>(-1)
-+		    || __conv == static_cast<size_t>(-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 --git a/libstdc++-v3/config/locale/uclibc/collate_members.cc b/libstdc++-v3/config/locale/uclibc/collate_members.cc
-new file mode 100644
-index 0000000..c2664a7
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/collate_members.cc
-@@ -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 <bkoz@redhat.com>
-+
-+#include <locale>
-+#include <bits/c++locale_internal.h>
-+
-+#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<char>::_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<char>::_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<wchar_t>::_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<wchar_t>::_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 --git a/libstdc++-v3/config/locale/uclibc/ctype_members.cc b/libstdc++-v3/config/locale/uclibc/ctype_members.cc
-new file mode 100644
-index 0000000..7294e3a
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/ctype_members.cc
-@@ -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 <bkoz@redhat.com>
-+
-+#define _LIBC
-+#include <locale>
-+#undef _LIBC
-+#include <bits/c++locale_internal.h>
-+
-+#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<char> specializations are in src/locale.cc and
-+  // various /config/os/* files.
-+  template<>
-+    ctype_byname<char>::ctype_byname(const char* __s, size_t __refs)
-+    : ctype<char>(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<wchar_t>::__wmask_type
-+  ctype<wchar_t>::_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<wchar_t>::do_toupper(wchar_t __c) const
-+  { return __towupper_l(__c, _M_c_locale_ctype); }
-+
-+  const wchar_t*
-+  ctype<wchar_t>::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<wchar_t>::do_tolower(wchar_t __c) const
-+  { return __towlower_l(__c, _M_c_locale_ctype); }
-+
-+  const wchar_t*
-+  ctype<wchar_t>::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<wchar_t>::
-+  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<wchar_t>::
-+  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<wchar_t>::
-+  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<wchar_t>::
-+  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<wchar_t>::
-+  do_widen(char __c) const
-+  { return _M_widen[static_cast<unsigned char>(__c)]; }
-+
-+  const char*
-+  ctype<wchar_t>::
-+  do_widen(const char* __lo, const char* __hi, wchar_t* __dest) const
-+  {
-+    while (__lo < __hi)
-+      {
-+	*__dest = _M_widen[static_cast<unsigned char>(*__lo)];
-+	++__lo;
-+	++__dest;
-+      }
-+    return __hi;
-+  }
-+
-+  char
-+  ctype<wchar_t>::
-+  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<char>(__c));
-+  }
-+
-+  const wchar_t*
-+  ctype<wchar_t>::
-+  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<char>(__c));
-+	    }
-+	  ++__lo;
-+	  ++__dest;
-+	}
-+    else
-+      while (__lo < __hi)
-+	{
-+	  const int __c = wctob(*__lo);
-+	  *__dest = (__c == EOF ? __dfault : static_cast<char>(__c));
-+	  ++__lo;
-+	  ++__dest;
-+	}
-+#ifdef __UCLIBC_HAS_XLOCALE__
-+    __uselocale(__old);
-+#endif
-+    return __hi;
-+  }
-+
-+  void
-+  ctype<wchar_t>::_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<char>(__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<mask>(_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 --git a/libstdc++-v3/config/locale/uclibc/messages_members.cc b/libstdc++-v3/config/locale/uclibc/messages_members.cc
-new file mode 100644
-index 0000000..13594d9
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/messages_members.cc
-@@ -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 <bkoz@redhat.com>
-+
-+#include <locale>
-+#include <bits/c++locale_internal.h>
-+
-+#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<char>::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<const char*>(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<wchar_t>::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 --git a/libstdc++-v3/config/locale/uclibc/messages_members.h b/libstdc++-v3/config/locale/uclibc/messages_members.h
-new file mode 100644
-index 0000000..1424078
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/messages_members.h
-@@ -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 <bkoz@redhat.com>
-+
-+#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<typename _CharT>
-+     messages<_CharT>::messages(size_t __refs)
-+     : facet(__refs), _M_c_locale_messages(_S_get_c_locale()),
-+     _M_name_messages(_S_get_c_name())
-+     { }
-+
-+  template<typename _CharT>
-+     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 _CharT>
-+    typename messages<_CharT>::catalog
-+    messages<_CharT>::open(const basic_string<char>& __s, const locale& __loc,
-+			   const char* __dir) const
-+    {
-+      __bindtextdomain(__s.c_str(), __dir);
-+      return this->do_open(__s, __loc);
-+    }
-+
-+  // Virtual member functions.
-+  template<typename _CharT>
-+    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 _CharT>
-+    typename messages<_CharT>::catalog
-+    messages<_CharT>::do_open(const basic_string<char>& __s,
-+			      const locale&) const
-+    {
-+      // No error checking is done, assume the catalog exists and can
-+      // be used.
-+      __textdomain(__s.c_str());
-+      return 0;
-+    }
-+
-+  template<typename _CharT>
-+    void
-+    messages<_CharT>::do_close(catalog) const
-+    { }
-+
-+   // messages_byname
-+   template<typename _CharT>
-+     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 --git a/libstdc++-v3/config/locale/uclibc/monetary_members.cc b/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-new file mode 100644
-index 0000000..aa52731
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-@@ -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 <bkoz@redhat.com>
-+
-+#define _LIBC
-+#include <locale>
-+#undef _LIBC
-+#include <bits/c++locale_internal.h>
-+
-+#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<char, true>::_M_initialize_moneypunct(__c_locale __cloc,
-+						     const char*)
-+    {
-+      if (!_M_data)
-+	_M_data = new __moneypunct_cache<char, true>;
-+
-+      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<char, false>::_M_initialize_moneypunct(__c_locale __cloc,
-+						      const char*)
-+    {
-+      if (!_M_data)
-+	_M_data = new __moneypunct_cache<char, false>;
-+
-+      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<char, true>::~moneypunct()
-+    { delete _M_data; }
-+
-+  template<>
-+    moneypunct<char, false>::~moneypunct()
-+    { delete _M_data; }
-+
-+#ifdef _GLIBCXX_USE_WCHAR_T
-+  template<>
-+    void
-+    moneypunct<wchar_t, true>::_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<wchar_t, true>;
-+
-+      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<wchar_t>(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<wchar_t, false>::_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<wchar_t, false>;
-+
-+    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<wchar_t>(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<wchar_t, true>::~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<wchar_t, false>::~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 --git a/libstdc++-v3/config/locale/uclibc/numeric_members.cc b/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-new file mode 100644
-index 0000000..883ec1a
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-@@ -0,0 +1,160 @@
-+// 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 <bkoz@redhat.com>
-+
-+#define _LIBC
-+#include <locale>
-+#undef _LIBC
-+#include <bits/c++locale_internal.h>
-+
-+#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<char>::_M_initialize_numpunct(__c_locale __cloc)
-+    {
-+      if (!_M_data)
-+	_M_data = new __numpunct_cache<char>;
-+
-+      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<char>::~numpunct()
-+    { delete _M_data; }
-+
-+#ifdef _GLIBCXX_USE_WCHAR_T
-+  template<>
-+    void
-+    numpunct<wchar_t>::_M_initialize_numpunct(__c_locale __cloc)
-+    {
-+      if (!_M_data)
-+	_M_data = new __numpunct_cache<wchar_t>;
-+
-+      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<wchar_t>(__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<wchar_t>(__num_base::_S_atoms_in[__j]);
-+	}
-+      else
-+	{
-+	  // Named locale.
-+	  // NB: In the GNU model wchar_t is always 32 bit wide.
-+	  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;
-+
-+	  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<wchar_t>::~numpunct()
-+    { delete _M_data; }
-+ #endif
-+}
-diff --git a/libstdc++-v3/config/locale/uclibc/time_members.cc b/libstdc++-v3/config/locale/uclibc/time_members.cc
-new file mode 100644
-index 0000000..e0707d7
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/time_members.cc
-@@ -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 <bkoz@redhat.com>
-+
-+#include <locale>
-+#include <bits/c++locale_internal.h>
-+
-+#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<char>::
-+    _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<char>::_M_initialize_timepunct(__c_locale __cloc)
-+    {
-+      if (!_M_data)
-+	_M_data = new __timepunct_cache<char>;
-+
-+      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<wchar_t>::
-+    _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<wchar_t>::_M_initialize_timepunct(__c_locale __cloc)
-+    {
-+      if (!_M_data)
-+	_M_data = new __timepunct_cache<wchar_t>;
-+
-+#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 --git a/libstdc++-v3/config/locale/uclibc/time_members.h b/libstdc++-v3/config/locale/uclibc/time_members.h
-new file mode 100644
-index 0000000..ba8e858
---- /dev/null
-+++ b/libstdc++-v3/config/locale/uclibc/time_members.h
-@@ -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 <bkoz@redhat.com>
-+
-+  template<typename _CharT>
-+    __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<typename _CharT>
-+    __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<typename _CharT>
-+    __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<typename _CharT>
-+    __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 --git a/libstdc++-v3/configure b/libstdc++-v3/configure
-index f40ddcf..c57a751 100755
---- a/libstdc++-v3/configure
-+++ b/libstdc++-v3/configure
-@@ -15822,6 +15822,9 @@ fi
-   # 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)
- 	enable_clocale_flag=gnu
- 	;;
-@@ -16079,6 +16082,78 @@ $as_echo "newlib" >&6; }
-       CTIME_CC=config/locale/generic/time_members.cc
-       CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h
-       ;;
-+    uclibc)
-+      { $as_echo "$as_me:${as_lineno-$LINENO}: result: uclibc" >&5
-+$as_echo "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
-+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-+$as_echo_n "checking for $ac_word... " >&6; }
-+if test "${ac_cv_prog_check_msgfmt+set}" = set; then :
-+  $as_echo_n "(cached) " >&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 { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-+    ac_cv_prog_check_msgfmt="yes"
-+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
-+    break 2
-+  fi
-+done
-+  done
-+IFS=$as_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
-+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $check_msgfmt" >&5
-+$as_echo "$check_msgfmt" >&6; }
-+else
-+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-+$as_echo "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 --git a/libstdc++-v3/include/c_compatibility/wchar.h b/libstdc++-v3/include/c_compatibility/wchar.h
-index 580d725..3fe61b8 100644
---- a/libstdc++-v3/include/c_compatibility/wchar.h
-+++ b/libstdc++-v3/include/c_compatibility/wchar.h
-@@ -101,7 +101,9 @@ using std::wmemcmp;
- 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 --git a/libstdc++-v3/include/c_std/cwchar b/libstdc++-v3/include/c_std/cwchar
-index 0e6b1fc..405aee2 100644
---- a/libstdc++-v3/include/c_std/cwchar
-+++ b/libstdc++-v3/include/c_std/cwchar
-@@ -175,7 +175,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
-   using ::wcscoll;
-   using ::wcscpy;
-   using ::wcscspn;
-+#if _GLIBCXX_HAVE_WCSFTIME
-   using ::wcsftime;
-+#endif
-   using ::wcslen;
-   using ::wcsncat;
-   using ::wcsncmp;
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0005-uclibc-locale-no__x.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0005-uclibc-locale-no__x.patch
deleted file mode 100644
index dcbbfe4..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0005-uclibc-locale-no__x.patch
+++ /dev/null
@@ -1,257 +0,0 @@
-From 6a3e8506a12c12728d8b29901defd738be43757f Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:42:36 +0400
-Subject: [PATCH 05/35] uclibc-locale-no__x
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- .../config/locale/uclibc/c++locale_internal.h      |   45 ++++++++++++++++++++
- libstdc++-v3/config/locale/uclibc/c_locale.cc      |   14 ------
- libstdc++-v3/config/locale/uclibc/c_locale.h       |    1 +
- .../config/locale/uclibc/collate_members.cc        |    7 ---
- libstdc++-v3/config/locale/uclibc/ctype_members.cc |    7 ---
- .../config/locale/uclibc/messages_members.cc       |    7 +--
- .../config/locale/uclibc/messages_members.h        |   18 +++-----
- .../config/locale/uclibc/monetary_members.cc       |    4 --
- .../config/locale/uclibc/numeric_members.cc        |    3 --
- libstdc++-v3/config/locale/uclibc/time_members.cc  |    3 --
- 10 files changed, 55 insertions(+), 54 deletions(-)
-
-diff --git a/libstdc++-v3/config/locale/uclibc/c++locale_internal.h b/libstdc++-v3/config/locale/uclibc/c++locale_internal.h
-index 2ae3e4a..e74fddf 100644
---- a/libstdc++-v3/config/locale/uclibc/c++locale_internal.h
-+++ b/libstdc++-v3/config/locale/uclibc/c++locale_internal.h
-@@ -60,4 +60,49 @@ extern "C" __typeof(wcsxfrm_l) __wcsxfrm_l;
- extern "C" __typeof(wctype_l) __wctype_l;
- #endif
- 
-+# define __nl_langinfo_l nl_langinfo_l
-+# define __strcoll_l strcoll_l
-+# define __strftime_l strftime_l
-+# define __strtod_l strtod_l
-+# define __strtof_l strtof_l
-+# define __strtold_l strtold_l
-+# define __strxfrm_l strxfrm_l
-+# define __newlocale newlocale
-+# define __freelocale freelocale
-+# define __duplocale duplocale
-+# define __uselocale uselocale
-+
-+# ifdef _GLIBCXX_USE_WCHAR_T
-+#  define __iswctype_l iswctype_l
-+#  define __towlower_l towlower_l
-+#  define __towupper_l towupper_l
-+#  define __wcscoll_l wcscoll_l
-+#  define __wcsftime_l wcsftime_l
-+#  define __wcsxfrm_l wcsxfrm_l
-+#  define __wctype_l wctype_l
-+# endif
-+
-+#else
-+# define __nl_langinfo_l(N, L)       nl_langinfo((N))
-+# define __strcoll_l(S1, S2, L)      strcoll((S1), (S2))
-+# define __strtod_l(S, E, L)         strtod((S), (E))
-+# define __strtof_l(S, E, L)         strtof((S), (E))
-+# define __strtold_l(S, E, L)        strtold((S), (E))
-+# define __strxfrm_l(S1, S2, N, L)   strxfrm((S1), (S2), (N))
-+# warning should dummy __newlocale check for C|POSIX ?
-+# define __newlocale(a, b, c)        NULL
-+# define __freelocale(a)             ((void)0)
-+# define __duplocale(a)              __c_locale()
-+//# define __uselocale ?
-+//
-+# ifdef _GLIBCXX_USE_WCHAR_T
-+#  define __iswctype_l(C, M, L)       iswctype((C), (M))
-+#  define __towlower_l(C, L)          towlower((C))
-+#  define __towupper_l(C, L)          towupper((C))
-+#  define __wcscoll_l(S1, S2, L)      wcscoll((S1), (S2))
-+//#  define __wcsftime_l(S, M, F, T, L)  wcsftime((S), (M), (F), (T))
-+#  define __wcsxfrm_l(S1, S2, N, L)   wcsxfrm((S1), (S2), (N))
-+#  define __wctype_l(S, L)            wctype((S))
-+# endif
-+
- #endif // GLIBC 2.3 and later
-diff --git a/libstdc++-v3/config/locale/uclibc/c_locale.cc b/libstdc++-v3/config/locale/uclibc/c_locale.cc
-index 5081dc1..21430d0 100644
---- a/libstdc++-v3/config/locale/uclibc/c_locale.cc
-+++ b/libstdc++-v3/config/locale/uclibc/c_locale.cc
-@@ -39,20 +39,6 @@
- #include <langinfo.h>
- #include <bits/c++locale_internal.h>
- 
--#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<>
-diff --git a/libstdc++-v3/config/locale/uclibc/c_locale.h b/libstdc++-v3/config/locale/uclibc/c_locale.h
-index da07c1f..4bca5f1 100644
---- a/libstdc++-v3/config/locale/uclibc/c_locale.h
-+++ b/libstdc++-v3/config/locale/uclibc/c_locale.h
-@@ -68,6 +68,7 @@ namespace __gnu_cxx
- {
-   extern "C" __typeof(uselocale) __uselocale;
- }
-+#define __uselocale uselocale
- #endif
- 
- namespace std
-diff --git a/libstdc++-v3/config/locale/uclibc/collate_members.cc b/libstdc++-v3/config/locale/uclibc/collate_members.cc
-index c2664a7..ec5c329 100644
---- a/libstdc++-v3/config/locale/uclibc/collate_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/collate_members.cc
-@@ -36,13 +36,6 @@
- #include <locale>
- #include <bits/c++locale_internal.h>
- 
--#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
-diff --git a/libstdc++-v3/config/locale/uclibc/ctype_members.cc b/libstdc++-v3/config/locale/uclibc/ctype_members.cc
-index 7294e3a..7b12861 100644
---- a/libstdc++-v3/config/locale/uclibc/ctype_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/ctype_members.cc
-@@ -38,13 +38,6 @@
- #undef _LIBC
- #include <bits/c++locale_internal.h>
- 
--#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<char> specializations are in src/locale.cc and
-diff --git a/libstdc++-v3/config/locale/uclibc/messages_members.cc b/libstdc++-v3/config/locale/uclibc/messages_members.cc
-index 13594d9..d7693b4 100644
---- a/libstdc++-v3/config/locale/uclibc/messages_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/messages_members.cc
-@@ -39,13 +39,10 @@
- #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)
-+#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__
-+#define gettext(msgid) dcgettext(NULL, msgid, LC_MESSAGES)
- #else
--#undef gettext
- #define gettext(msgid) (msgid)
- #endif
- 
-diff --git a/libstdc++-v3/config/locale/uclibc/messages_members.h b/libstdc++-v3/config/locale/uclibc/messages_members.h
-index 1424078..d89da33 100644
---- a/libstdc++-v3/config/locale/uclibc/messages_members.h
-+++ b/libstdc++-v3/config/locale/uclibc/messages_members.h
-@@ -36,15 +36,11 @@
- #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)
-+#ifndef __UCLIBC_HAS_GETTEXT_AWARENESS__
-+#undef textdomain
-+#undef bindtextdomain
-+#define textdomain(D)           ((void)0)
-+#define bindtextdomain(D,P)     ((void)0)
- #endif
- 
-   // Non-virtual member functions.
-@@ -70,7 +66,7 @@ extern "C" char *__bindtextdomain(const char *domainname,
-     messages<_CharT>::open(const basic_string<char>& __s, const locale& __loc,
- 			   const char* __dir) const
-     {
--      __bindtextdomain(__s.c_str(), __dir);
-+      bindtextdomain(__s.c_str(), __dir);
-       return this->do_open(__s, __loc);
-     }
- 
-@@ -90,7 +86,7 @@ extern "C" char *__bindtextdomain(const char *domainname,
-     {
-       // No error checking is done, assume the catalog exists and can
-       // be used.
--      __textdomain(__s.c_str());
-+      textdomain(__s.c_str());
-       return 0;
-     }
- 
-diff --git a/libstdc++-v3/config/locale/uclibc/monetary_members.cc b/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-index aa52731..2e6f80a 100644
---- a/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-@@ -43,10 +43,6 @@
- #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:
-diff --git a/libstdc++-v3/config/locale/uclibc/numeric_members.cc b/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-index 883ec1a..2c70642 100644
---- a/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-@@ -41,9 +41,6 @@
- #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
- {
-diff --git a/libstdc++-v3/config/locale/uclibc/time_members.cc b/libstdc++-v3/config/locale/uclibc/time_members.cc
-index e0707d7..d848ed5 100644
---- a/libstdc++-v3/config/locale/uclibc/time_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/time_members.cc
-@@ -40,9 +40,6 @@
- #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
- {
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0006-uclibc-locale-wchar_fix.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0006-uclibc-locale-wchar_fix.patch
deleted file mode 100644
index 3406859..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0006-uclibc-locale-wchar_fix.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From 225511a3aeb193a916b3999f0b640a392caa67cd Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:45:57 +0400
-Subject: [PATCH 06/35] uclibc-locale-wchar_fix
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- libstdc++-v3/config/locale/uclibc/monetary_members.cc |    4 ++--
- libstdc++-v3/config/locale/uclibc/numeric_members.cc  |   13 +++++++++++++
- 2 files changed, 15 insertions(+), 2 deletions(-)
-
-diff --git a/libstdc++-v3/config/locale/uclibc/monetary_members.cc b/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-index 2e6f80a..31ebb9f 100644
---- a/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-@@ -401,7 +401,7 @@ namespace std
- # ifdef __UCLIBC_HAS_XLOCALE__
- 	  _M_data->_M_decimal_point = __cloc->decimal_point_wc;
- 	  _M_data->_M_thousands_sep = __cloc->thousands_sep_wc;
--# else
-+# elif defined __UCLIBC_HAS_LOCALE__
- 	  _M_data->_M_decimal_point = __global_locale->decimal_point_wc;
- 	  _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc;
- # endif
-@@ -556,7 +556,7 @@ namespace std
- # ifdef __UCLIBC_HAS_XLOCALE__
- 	  _M_data->_M_decimal_point = __cloc->decimal_point_wc;
- 	  _M_data->_M_thousands_sep = __cloc->thousands_sep_wc;
--# else
-+# elif defined __UCLIBC_HAS_LOCALE__
- 	  _M_data->_M_decimal_point = __global_locale->decimal_point_wc;
- 	  _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc;
- # endif
-diff --git a/libstdc++-v3/config/locale/uclibc/numeric_members.cc b/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-index 2c70642..d5c8961 100644
---- a/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-@@ -127,12 +127,25 @@ namespace std
- 	{
- 	  // Named locale.
- 	  // NB: In the GNU model wchar_t is always 32 bit wide.
-+#ifdef __UCLIBC_MJN3_ONLY__
-+#warning fix this... should be numeric
-+#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;
-+# elif defined __UCLIBC_HAS_LOCALE__
-+	  _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 = "";
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0007-uclibc-locale-update.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0007-uclibc-locale-update.patch
deleted file mode 100644
index 5851123..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0007-uclibc-locale-update.patch
+++ /dev/null
@@ -1,542 +0,0 @@
-From 6ffe7c46f52d27864c3df3663e16ec9ddee71e8f Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:46:58 +0400
-Subject: [PATCH 07/35] uclibc-locale-update
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- .../config/locale/uclibc/c++locale_internal.h      |    3 +
- libstdc++-v3/config/locale/uclibc/c_locale.cc      |   74 +++++++++-----------
- libstdc++-v3/config/locale/uclibc/c_locale.h       |   42 ++++++-----
- libstdc++-v3/config/locale/uclibc/ctype_members.cc |   51 ++++++++++----
- .../config/locale/uclibc/messages_members.h        |   12 ++--
- .../config/locale/uclibc/monetary_members.cc       |   34 +++++----
- .../config/locale/uclibc/numeric_members.cc        |    5 ++
- libstdc++-v3/config/locale/uclibc/time_members.cc  |   18 +++--
- libstdc++-v3/config/locale/uclibc/time_members.h   |   17 +++--
- 9 files changed, 158 insertions(+), 98 deletions(-)
-
-diff --git a/libstdc++-v3/config/locale/uclibc/c++locale_internal.h b/libstdc++-v3/config/locale/uclibc/c++locale_internal.h
-index e74fddf..971a6b4 100644
---- a/libstdc++-v3/config/locale/uclibc/c++locale_internal.h
-+++ b/libstdc++-v3/config/locale/uclibc/c++locale_internal.h
-@@ -31,6 +31,9 @@
- 
- #include <bits/c++config.h>
- #include <clocale>
-+#include <cstdlib>
-+#include <cstring>
-+#include <cstddef>
- 
- #ifdef __UCLIBC_MJN3_ONLY__
- #warning clean this up
-diff --git a/libstdc++-v3/config/locale/uclibc/c_locale.cc b/libstdc++-v3/config/locale/uclibc/c_locale.cc
-index 21430d0..1b9d8e1 100644
---- a/libstdc++-v3/config/locale/uclibc/c_locale.cc
-+++ b/libstdc++-v3/config/locale/uclibc/c_locale.cc
-@@ -39,23 +39,20 @@
- #include <langinfo.h>
- #include <bits/c++locale_internal.h>
- 
--namespace std
--{
-+_GLIBCXX_BEGIN_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;
--	}
-+      char* __sanity;
-+      errno = 0;
-+      float __f = __strtof_l(__s, &__sanity, __cloc);
-+      if (__sanity != __s && errno != ERANGE)
-+	__v = __f;
-+      else
-+	__err |= ios_base::failbit;
-     }
- 
-   template<>
-@@ -63,16 +60,13 @@ namespace std
-     __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;
--	}
-+      char* __sanity;
-+      errno = 0;
-+      double __d = __strtod_l(__s, &__sanity, __cloc);
-+      if (__sanity != __s && errno != ERANGE)
-+	__v = __d;
-+      else
-+	__err |= ios_base::failbit;
-     }
- 
-   template<>
-@@ -80,16 +74,13 @@ namespace std
-     __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;
--	}
-+      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
-@@ -110,17 +101,18 @@ namespace std
-   void
-   locale::facet::_S_destroy_c_locale(__c_locale& __cloc)
-   {
--    if (_S_get_c_locale() != __cloc)
-+    if (__cloc && _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
--{
-+_GLIBCXX_END_NAMESPACE
-+
-+_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
-+
-   const char* const category_names[6 + _GLIBCXX_NUM_CATEGORIES] =
-     {
-       "LC_CTYPE",
-@@ -138,9 +130,11 @@ namespace __gnu_cxx
-       "LC_IDENTIFICATION"
- #endif
-     };
--}
- 
--namespace std
--{
-+_GLIBCXX_END_NAMESPACE
-+
-+_GLIBCXX_BEGIN_NAMESPACE(std)
-+
-   const char* const* const locale::_S_categories = __gnu_cxx::category_names;
--}  // namespace std
-+
-+_GLIBCXX_END_NAMESPACE
-diff --git a/libstdc++-v3/config/locale/uclibc/c_locale.h b/libstdc++-v3/config/locale/uclibc/c_locale.h
-index 4bca5f1..64a6d46 100644
---- a/libstdc++-v3/config/locale/uclibc/c_locale.h
-+++ b/libstdc++-v3/config/locale/uclibc/c_locale.h
-@@ -39,21 +39,23 @@
- #pragma GCC system_header
- 
- #include <cstring>              // get std::strlen
--#include <cstdio>               // get std::snprintf or std::sprintf
-+#include <cstdio>               // get std::vsnprintf or std::vsprintf
- #include <clocale>
- #include <langinfo.h>		// For codecvt
- #ifdef __UCLIBC_MJN3_ONLY__
- #warning fix this
- #endif
--#ifdef __UCLIBC_HAS_LOCALE__
-+#ifdef _GLIBCXX_USE_ICONV
- #include <iconv.h>		// For codecvt using iconv, iconv_t
- #endif
--#ifdef __UCLIBC_HAS_GETTEXT_AWARENESS__
--#include <libintl.h> 		// For messages
-+#ifdef HAVE_LIBINTL_H
-+#include <libintl.h>		// For messages
- #endif
-+#include <cstdarg>
- 
- #ifdef __UCLIBC_MJN3_ONLY__
- #warning what is _GLIBCXX_C_LOCALE_GNU for
-+// psm: used in os/gnu-linux/ctype_noninline.h
- #endif
- #define _GLIBCXX_C_LOCALE_GNU 1
- 
-@@ -78,23 +80,25 @@ namespace std
- #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
-+  // Convert numeric value of type double to string and return length of
-+  // string.  If vsnprintf is available use it, otherwise fall back to
-+  // the unsafe vsprintf which, in general, can be dangerous and should
-   // be avoided.
--  template<typename _Tv>
--    int
--    __convert_from_v(char* __out,
--		     const int __size __attribute__ ((__unused__)),
--		     const char* __fmt,
--#ifdef __UCLIBC_HAS_XCLOCALE__
--		     _Tv __v, const __c_locale& __cloc, int __prec)
-+    inline int
-+    __convert_from_v(const __c_locale&
-+#ifndef __UCLIBC_HAS_XCLOCALE__
-+	__cloc __attribute__ ((__unused__))
-+#endif
-+		     ,
-+		     char* __out,
-+		     const int __size,
-+		     const char* __fmt, ...)
-     {
-+      va_list __args;
-+#ifdef __UCLIBC_HAS_XCLOCALE__
-+
-       __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];
-@@ -103,7 +107,9 @@ namespace std
- # endif
- #endif
- 
--      const int __ret = std::snprintf(__out, __size, __fmt, __prec, __v);
-+      va_start(__args, __fmt);
-+      const int __ret = std::vsnprintf(__out, __size, __fmt, __args);
-+      va_end(__args);
- 
- #ifdef __UCLIBC_HAS_XCLOCALE__
-       __gnu_cxx::__uselocale(__old);
-diff --git a/libstdc++-v3/config/locale/uclibc/ctype_members.cc b/libstdc++-v3/config/locale/uclibc/ctype_members.cc
-index 7b12861..13e011d 100644
---- a/libstdc++-v3/config/locale/uclibc/ctype_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/ctype_members.cc
-@@ -33,16 +33,20 @@
- 
- // Written by Benjamin Kosnik <bkoz@redhat.com>
- 
-+#include <features.h>
-+#ifdef __UCLIBC_HAS_LOCALE__
- #define _LIBC
- #include <locale>
- #undef _LIBC
-+#else
-+#include <locale>
-+#endif
- #include <bits/c++locale_internal.h>
- 
--namespace std
--{
-+_GLIBCXX_BEGIN_NAMESPACE(std)
-+
-   // NB: The other ctype<char> specializations are in src/locale.cc and
-   // various /config/os/* files.
--  template<>
-     ctype_byname<char>::ctype_byname(const char* __s, size_t __refs)
-     : ctype<char>(0, false, __refs)
-     {
-@@ -57,6 +61,8 @@ namespace std
- #endif
- 	}
-     }
-+    ctype_byname<char>::~ctype_byname()
-+    { }
- 
- #ifdef _GLIBCXX_USE_WCHAR_T
-   ctype<wchar_t>::__wmask_type
-@@ -138,17 +144,33 @@ namespace std
-   ctype<wchar_t>::
-   do_is(mask __m, wchar_t __c) const
-   {
--    // Highest bitmask in ctype_base == 10, but extra in "C"
--    // library for blank.
-+    // The case of __m == ctype_base::space is particularly important,
-+    // due to its use in many istream functions.  Therefore we deal with
-+    // it first, exploiting the knowledge that on GNU systems _M_bit[5]
-+    // is the mask corresponding to ctype_base::space.  NB: an encoding
-+    // change would not affect correctness!
-+
-     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;
--	}
-+    if (__m == _M_bit[5])
-+      __ret = __iswctype_l(__c, _M_wmask[5], _M_c_locale_ctype);
-+    else
-+      {
-+	// Highest bitmask in ctype_base == 10, but extra in "C"
-+	// library for blank.
-+	const size_t __bitmasksize = 11;
-+	for (size_t __bitcur = 0; __bitcur <= __bitmasksize; ++__bitcur)
-+	  if (__m & _M_bit[__bitcur])
-+	    {
-+	      if (__iswctype_l(__c, _M_wmask[__bitcur], _M_c_locale_ctype))
-+		{
-+		  __ret = true;
-+		  break;
-+		}
-+	      else if (__m == _M_bit[__bitcur])
-+		break;
-+	    }
-+      }
-+
-     return __ret;
-   }
- 
-@@ -290,4 +312,5 @@ namespace std
- #endif
-   }
- #endif //  _GLIBCXX_USE_WCHAR_T
--}
-+
-+_GLIBCXX_END_NAMESPACE
-diff --git a/libstdc++-v3/config/locale/uclibc/messages_members.h b/libstdc++-v3/config/locale/uclibc/messages_members.h
-index d89da33..067657a 100644
---- a/libstdc++-v3/config/locale/uclibc/messages_members.h
-+++ b/libstdc++-v3/config/locale/uclibc/messages_members.h
-@@ -53,12 +53,16 @@
-   template<typename _CharT>
-      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)
-+     : facet(__refs), _M_c_locale_messages(NULL),
-+     _M_name_messages(NULL)
-      {
--       char* __tmp = new char[std::strlen(__s) + 1];
--       std::strcpy(__tmp, __s);
-+       const size_t __len = std::strlen(__s) + 1;
-+       char* __tmp = new char[__len];
-+       std::memcpy(__tmp, __s, __len);
-        _M_name_messages = __tmp;
-+
-+       // Last to avoid leaking memory if new throws.
-+       _M_c_locale_messages = _S_clone_c_locale(__cloc);
-      }
- 
-   template<typename _CharT>
-diff --git a/libstdc++-v3/config/locale/uclibc/monetary_members.cc b/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-index 31ebb9f..7679b9c 100644
---- a/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/monetary_members.cc
-@@ -33,9 +33,14 @@
- 
- // Written by Benjamin Kosnik <bkoz@redhat.com>
- 
-+#include <features.h>
-+#ifdef __UCLIBC_HAS_LOCALE__
- #define _LIBC
- #include <locale>
- #undef _LIBC
-+#else
-+#include <locale>
-+#endif
- #include <bits/c++locale_internal.h>
- 
- #ifdef __UCLIBC_MJN3_ONLY__
-@@ -206,7 +211,7 @@ namespace std
- 	  }
- 	break;
-       default:
--	;
-+	__ret = pattern();
-       }
-     return __ret;
-   }
-@@ -390,7 +395,9 @@ namespace std
- 	  __c_locale __old = __uselocale(__cloc);
- #else
- 	  // Switch to named locale so that mbsrtowcs will work.
--	  char* __old = strdup(setlocale(LC_ALL, NULL));
-+  	  char* __old = setlocale(LC_ALL, NULL);
-+          const size_t __llen = strlen(__old) + 1;
-+          char* __sav = new char[__llen];
- 	  setlocale(LC_ALL, __name);
- #endif
- 
-@@ -477,8 +484,8 @@ namespace std
- #ifdef __UCLIBC_HAS_XLOCALE__
- 	      __uselocale(__old);
- #else
--	      setlocale(LC_ALL, __old);
--	      free(__old);
-+	      setlocale(LC_ALL, __sav);
-+	      delete [] __sav;
- #endif
- 	      __throw_exception_again;
- 	    }
-@@ -498,8 +505,8 @@ namespace std
- #ifdef __UCLIBC_HAS_XLOCALE__
- 	  __uselocale(__old);
- #else
--	  setlocale(LC_ALL, __old);
--	  free(__old);
-+	  setlocale(LC_ALL, __sav);
-+	  delete [] __sav;
- #endif
- 	}
-     }
-@@ -545,8 +552,11 @@ namespace std
- 	  __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);
-+          char* __old = setlocale(LC_ALL, NULL);
-+          const size_t __llen = strlen(__old) + 1;
-+          char* __sav = new char[__llen];
-+          memcpy(__sav, __old, __llen);
-+          setlocale(LC_ALL, __name);
- #endif
- 
- #ifdef __UCLIBC_MJN3_ONLY__
-@@ -633,8 +643,8 @@ namespace std
- #ifdef __UCLIBC_HAS_XLOCALE__
- 	      __uselocale(__old);
- #else
--	      setlocale(LC_ALL, __old);
--	      free(__old);
-+	      setlocale(LC_ALL, __sav);
-+	      delete [] __sav;
- #endif
-               __throw_exception_again;
- 	    }
-@@ -653,8 +663,8 @@ namespace std
- #ifdef __UCLIBC_HAS_XLOCALE__
- 	  __uselocale(__old);
- #else
--	  setlocale(LC_ALL, __old);
--	  free(__old);
-+	  setlocale(LC_ALL, __sav);
-+	  delete [] __sav;
- #endif
- 	}
-     }
-diff --git a/libstdc++-v3/config/locale/uclibc/numeric_members.cc b/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-index d5c8961..8ae8969 100644
---- a/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/numeric_members.cc
-@@ -33,9 +33,14 @@
- 
- // Written by Benjamin Kosnik <bkoz@redhat.com>
- 
-+#include <features.h>
-+#ifdef __UCLIBC_HAS_LOCALE__
- #define _LIBC
- #include <locale>
- #undef _LIBC
-+#else
-+#include <locale>
-+#endif
- #include <bits/c++locale_internal.h>
- 
- #ifdef __UCLIBC_MJN3_ONLY__
-diff --git a/libstdc++-v3/config/locale/uclibc/time_members.cc b/libstdc++-v3/config/locale/uclibc/time_members.cc
-index d848ed5..f24d53e 100644
---- a/libstdc++-v3/config/locale/uclibc/time_members.cc
-+++ b/libstdc++-v3/config/locale/uclibc/time_members.cc
-@@ -53,11 +53,14 @@ namespace std
-       const size_t __len = __strftime_l(__s, __maxlen, __format, __tm,
- 					_M_c_locale_timepunct);
- #else
--      char* __old = strdup(setlocale(LC_ALL, NULL));
-+      char* __old = setlocale(LC_ALL, NULL);
-+      const size_t __llen = strlen(__old) + 1;
-+      char* __sav = new char[__llen];
-+      memcpy(__sav, __old, __llen);
-       setlocale(LC_ALL, _M_name_timepunct);
-       const size_t __len = strftime(__s, __maxlen, __format, __tm);
--      setlocale(LC_ALL, __old);
--      free(__old);
-+      setlocale(LC_ALL, __sav);
-+      delete [] __sav;
- #endif
-       // Make sure __s is null terminated.
-       if (__len == 0)
-@@ -207,11 +210,14 @@ namespace std
-       const size_t __len = __wcsftime_l(__s, __maxlen, __format, __tm,
- 					_M_c_locale_timepunct);
- #else
--      char* __old = strdup(setlocale(LC_ALL, NULL));
-+      char* __old = setlocale(LC_ALL, NULL);
-+      const size_t __llen = strlen(__old) + 1;
-+      char* __sav = new char[__llen];
-+      memcpy(__sav, __old, __llen);
-       setlocale(LC_ALL, _M_name_timepunct);
-       const size_t __len = wcsftime(__s, __maxlen, __format, __tm);
--      setlocale(LC_ALL, __old);
--      free(__old);
-+      setlocale(LC_ALL, __sav);
-+      delete [] __sav;
- #endif
-       // Make sure __s is null terminated.
-       if (__len == 0)
-diff --git a/libstdc++-v3/config/locale/uclibc/time_members.h b/libstdc++-v3/config/locale/uclibc/time_members.h
-index ba8e858..1665dde 100644
---- a/libstdc++-v3/config/locale/uclibc/time_members.h
-+++ b/libstdc++-v3/config/locale/uclibc/time_members.h
-@@ -50,12 +50,21 @@
-     __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)
-+    _M_name_timepunct(NULL)
-     {
--      char* __tmp = new char[std::strlen(__s) + 1];
--      std::strcpy(__tmp, __s);
-+      const size_t __len = std::strlen(__s) + 1;
-+      char* __tmp = new char[__len];
-+      std::memcpy(__tmp, __s, __len);
-       _M_name_timepunct = __tmp;
--      _M_initialize_timepunct(__cloc);
-+
-+      try
-+	{ _M_initialize_timepunct(__cloc); }
-+      catch(...)
-+	{
-+	  delete [] _M_name_timepunct;
-+	  __throw_exception_again;
-+	}
-+
-     }
- 
-   template<typename _CharT>
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0008-missing-execinfo_h.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0008-missing-execinfo_h.patch
deleted file mode 100644
index 2823809..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0008-missing-execinfo_h.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 9f2158451981cf0a80cfabdc79ae31bb6976a801 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:48:10 +0400
-Subject: [PATCH 08/35] missing-execinfo_h
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- boehm-gc/include/gc.h |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/boehm-gc/include/gc.h b/boehm-gc/include/gc.h
-index c51e017..a7ba8dc 100644
---- a/boehm-gc/include/gc.h
-+++ b/boehm-gc/include/gc.h
-@@ -503,7 +503,7 @@ GC_API GC_PTR GC_malloc_atomic_ignore_off_page GC_PROTO((size_t lb));
- #if defined(__linux__) || defined(__GLIBC__)
- # include <features.h>
- # 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
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0009-c99-snprintf.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0009-c99-snprintf.patch
deleted file mode 100644
index 7168778..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0009-c99-snprintf.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From e393e076f1ab82d25e1aa04d6edea27b41d3eb06 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:49:03 +0400
-Subject: [PATCH 09/35] c99-snprintf
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- libstdc++-v3/include/c_std/cstdio |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/libstdc++-v3/include/c_std/cstdio b/libstdc++-v3/include/c_std/cstdio
-index e85bd83..6af839a 100644
---- a/libstdc++-v3/include/c_std/cstdio
-+++ b/libstdc++-v3/include/c_std/cstdio
-@@ -139,7 +139,7 @@ namespace std
-   using ::vsprintf;
- } // namespace std
- 
--#if _GLIBCXX_USE_C99
-+#if _GLIBCXX_USE_C99 || defined(__UCLIBC__)
- 
- #undef snprintf
- #undef vfscanf
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0010-c99-complex-ugly-hack.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0010-c99-complex-ugly-hack.patch
deleted file mode 100644
index b628571..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0010-c99-complex-ugly-hack.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 73f69d806e2c9561a54995223431a1076cfd6164 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:49:57 +0400
-Subject: [PATCH 10/35] c99-complex-ugly-hack
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Inappropriate [embedded specific]
----
- libstdc++-v3/configure |    3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
-index c57a751..a1333e2 100755
---- a/libstdc++-v3/configure
-+++ b/libstdc++-v3/configure
-@@ -18734,6 +18734,9 @@ $as_echo_n "checking for ISO C99 support to TR1 in <complex.h>... " >&6; }
-     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h.  */
- #include <complex.h>
-+#ifdef __UCLIBC__
-+#error ugly hack to make sure configure test fails here for cross until uClibc supports the complex funcs
-+#endif
- int
- main ()
- {
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0011-index_macro.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0011-index_macro.patch
deleted file mode 100644
index 8ee79b0..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0011-index_macro.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From b037953e40312b45ab84ed0a3ad882bb5e413101 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:51:02 +0400
-Subject: [PATCH 11/35] index_macro
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- libstdc++-v3/include/ext/rope       |    3 +++
- libstdc++-v3/include/ext/ropeimpl.h |    3 +++
- 2 files changed, 6 insertions(+)
-
-diff --git a/libstdc++-v3/include/ext/rope b/libstdc++-v3/include/ext/rope
-index 38eb1e8..158d21a 100644
---- a/libstdc++-v3/include/ext/rope
-+++ b/libstdc++-v3/include/ext/rope
-@@ -55,6 +55,9 @@
- #include <bits/gthr.h>
- #include <tr1/functional>
- 
-+/* cope w/ index defined as macro, SuSv3 proposal */
-+#undef index
-+
- # ifdef __GC
- #   define __GC_CONST const
- # else
-diff --git a/libstdc++-v3/include/ext/ropeimpl.h b/libstdc++-v3/include/ext/ropeimpl.h
-index d7b5cbd..b9b3acb 100644
---- a/libstdc++-v3/include/ext/ropeimpl.h
-+++ b/libstdc++-v3/include/ext/ropeimpl.h
-@@ -48,6 +48,9 @@
- #include <ext/memory> // For uninitialized_copy_n
- #include <ext/numeric> // For power
- 
-+/* cope w/ index defined as macro, SuSv3 proposal */
-+#undef index
-+
- namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
- {
- _GLIBCXX_BEGIN_NAMESPACE_VERSION
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0012-libmudflap-susv3-legacy.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0012-libmudflap-susv3-legacy.patch
deleted file mode 100644
index 968d45e..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0012-libmudflap-susv3-legacy.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From a0cb13bdd98a941b81fdafe4cd96e4c569feb651 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:52:36 +0400
-Subject: [PATCH 12/35] libmudflap-susv3-legacy
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Inappropriate [embedded specific]
----
- libmudflap/mf-hooks2.c |   10 +++++-----
- 1 file changed, 5 insertions(+), 5 deletions(-)
-
-diff --git a/libmudflap/mf-hooks2.c b/libmudflap/mf-hooks2.c
-index 4af17df..a3c6b2f 100644
---- a/libmudflap/mf-hooks2.c
-+++ b/libmudflap/mf-hooks2.c
-@@ -424,7 +424,7 @@ WRAPPER2(void, bzero, void *s, size_t n)
- {
-   TRACE ("%s\n", __PRETTY_FUNCTION__);
-   MF_VALIDATE_EXTENT(s, n, __MF_CHECK_WRITE, "bzero region");
--  bzero (s, n);
-+  memset (s, 0, n);
- }
- 
- 
-@@ -434,7 +434,7 @@ WRAPPER2(void, bcopy, const void *src, void *dest, size_t n)
-   TRACE ("%s\n", __PRETTY_FUNCTION__);
-   MF_VALIDATE_EXTENT(src, n, __MF_CHECK_READ, "bcopy src");
-   MF_VALIDATE_EXTENT(dest, n, __MF_CHECK_WRITE, "bcopy dest");
--  bcopy (src, dest, n);
-+  memmove (dest, src, n);
- }
- 
- 
-@@ -444,7 +444,7 @@ WRAPPER2(int, bcmp, const void *s1, const void *s2, size_t n)
-   TRACE ("%s\n", __PRETTY_FUNCTION__);
-   MF_VALIDATE_EXTENT(s1, n, __MF_CHECK_READ, "bcmp 1st arg");
-   MF_VALIDATE_EXTENT(s2, n, __MF_CHECK_READ, "bcmp 2nd arg");
--  return bcmp (s1, s2, n);
-+  return n == 0 ? 0 : memcmp (s1, s2, n);
- }
- 
- 
-@@ -453,7 +453,7 @@ WRAPPER2(char *, index, const char *s, int c)
-   size_t n = strlen (s);
-   TRACE ("%s\n", __PRETTY_FUNCTION__);
-   MF_VALIDATE_EXTENT(s, CLAMPADD(n, 1), __MF_CHECK_READ, "index region");
--  return index (s, c);
-+  return strchr (s, c);
- }
- 
- 
-@@ -462,7 +462,7 @@ WRAPPER2(char *, rindex, const char *s, int c)
-   size_t n = strlen (s);
-   TRACE ("%s\n", __PRETTY_FUNCTION__);
-   MF_VALIDATE_EXTENT(s, CLAMPADD(n, 1), __MF_CHECK_READ, "rindex region");
--  return rindex (s, c);
-+  return strrchr (s, c);
- }
- 
- /* XXX:  stpcpy, memccpy */
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0013-libstdc-namespace.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0013-libstdc-namespace.patch
deleted file mode 100644
index 4a3efde..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0013-libstdc-namespace.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From 104e4d66208f2726b14d2f5eebce90700cbc83c8 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:54:02 +0400
-Subject: [PATCH 13/35] libstdc++-namespace
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- libstdc++-v3/config/locale/uclibc/messages_members.h |    4 +++-
- libstdc++-v3/config/locale/uclibc/time_members.h     |    4 +++-
- 2 files changed, 6 insertions(+), 2 deletions(-)
-
-diff --git a/libstdc++-v3/config/locale/uclibc/messages_members.h b/libstdc++-v3/config/locale/uclibc/messages_members.h
-index 067657a..dd76a6c 100644
---- a/libstdc++-v3/config/locale/uclibc/messages_members.h
-+++ b/libstdc++-v3/config/locale/uclibc/messages_members.h
-@@ -32,7 +32,8 @@
- //
- 
- // Written by Benjamin Kosnik <bkoz@redhat.com>
--
-+namespace std
-+{
- #ifdef __UCLIBC_MJN3_ONLY__
- #warning fix prototypes for *textdomain funcs
- #endif
-@@ -116,3 +117,4 @@
- 	   this->_S_create_c_locale(this->_M_c_locale_messages, __s);
- 	 }
-      }
-+}
-diff --git a/libstdc++-v3/config/locale/uclibc/time_members.h b/libstdc++-v3/config/locale/uclibc/time_members.h
-index 1665dde..905c433 100644
---- a/libstdc++-v3/config/locale/uclibc/time_members.h
-+++ b/libstdc++-v3/config/locale/uclibc/time_members.h
-@@ -33,7 +33,8 @@
- //
- 
- // Written by Benjamin Kosnik <bkoz@redhat.com>
--
-+namespace std
-+{
-   template<typename _CharT>
-     __timepunct<_CharT>::__timepunct(size_t __refs)
-     : facet(__refs), _M_data(NULL), _M_c_locale_timepunct(NULL),
-@@ -75,3 +76,4 @@
-       delete _M_data;
-       _S_destroy_c_locale(_M_c_locale_timepunct);
-     }
-+}
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0014-sh-pr24836.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0014-sh-pr24836.patch
deleted file mode 100644
index cb8fd52..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0014-sh-pr24836.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From edc9acb181810f234b6b9f7d2820b0e4f6a1eeaf Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:54:48 +0400
-Subject: [PATCH 14/35] sh-pr24836
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
-
-http://sourceforge.net/mailarchive/forum.php?thread_id=8959304&forum_id=5348
-http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24836
----
- gcc/configure    |    2 +-
- gcc/configure.ac |    2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/gcc/configure b/gcc/configure
-index e12a180..135bbf5 100755
---- a/gcc/configure
-+++ b/gcc/configure
-@@ -23378,7 +23378,7 @@ foo:	.long	25
- 	tls_first_minor=14
- 	tls_as_opt="-m64 -Aesame --fatal-warnings"
- 	;;
--  sh-*-* | sh[34]-*-*)
-+  sh-*-* | sh[34]*-*-*)
-     conftest_s='
- 	.section ".tdata","awT",@progbits
- foo:	.long	25
-diff --git a/gcc/configure.ac b/gcc/configure.ac
-index eba3577..6363a21 100644
---- a/gcc/configure.ac
-+++ b/gcc/configure.ac
-@@ -3141,7 +3141,7 @@ foo:	.long	25
- 	tls_first_minor=14
- 	tls_as_opt="-m64 -Aesame --fatal-warnings"
- 	;;
--  sh-*-* | sh[34]-*-*)
-+  sh-*-* | sh[34]*-*-*)
-     conftest_s='
- 	.section ".tdata","awT",@progbits
- foo:	.long	25
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch
deleted file mode 100644
index 1081222..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0015-arm-Use-TARGET_ENDIAN_OPTION-for-determining-MULTILI.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 50e5366005b0f6af27378e2a5c3cb9f9936a7e62 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:58:36 +0400
-Subject: [PATCH 15/35] arm: Use TARGET_ENDIAN_OPTION for determining
- MULTILIB_DEFAULTS
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- gcc/config/arm/linux-elf.h |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/gcc/config/arm/linux-elf.h b/gcc/config/arm/linux-elf.h
-index 488efa4..753dc3a 100644
---- a/gcc/config/arm/linux-elf.h
-+++ b/gcc/config/arm/linux-elf.h
-@@ -46,7 +46,7 @@
- 
- #undef  MULTILIB_DEFAULTS
- #define MULTILIB_DEFAULTS \
--	{ "marm", "mlittle-endian", "mfloat-abi=hard", "mno-thumb-interwork" }
-+	{ "marm", TARGET_ENDIAN_OPTION, "mfloat-abi=hard", "mno-thumb-interwork" }
- 
- /* Now we define the strings used to build the spec file.  */
- #undef  LIB_SPEC
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0016-gcc-poison-system-directories.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0016-gcc-poison-system-directories.patch
deleted file mode 100644
index c955e49..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0016-gcc-poison-system-directories.patch
+++ /dev/null
@@ -1,221 +0,0 @@
-From 160397ef3c3331099af028f1b8d3e085b07d88ad Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 08:59:00 +0400
-Subject: [PATCH 16/35] gcc: poison-system-directories
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Inappropriate [distribution: codesourcery]
----
- gcc/Makefile.in     |    2 +-
- gcc/common.opt      |    4 ++++
- gcc/config.in       |    6 ++++++
- gcc/configure       |   20 ++++++++++++++++++--
- gcc/configure.ac    |   10 ++++++++++
- gcc/doc/invoke.texi |    9 +++++++++
- gcc/gcc.c           |    2 ++
- gcc/incpath.c       |   19 +++++++++++++++++++
- 8 files changed, 69 insertions(+), 3 deletions(-)
-
-Index: gcc-4.8.4/gcc/Makefile.in
-===================================================================
---- gcc-4.8.4.orig/gcc/Makefile.in
-+++ gcc-4.8.4/gcc/Makefile.in
-@@ -2019,7 +2019,7 @@ attribs.o : attribs.c $(CONFIG_H) $(SYST
- 
- incpath.o: incpath.c incpath.h $(CONFIG_H) $(SYSTEM_H) $(CPPLIB_H) \
- 		intl.h prefix.h coretypes.h $(TM_H) cppdefault.h $(TARGET_H) \
--		$(MACHMODE_H)
-+		$(MACHMODE_H) $(FLAGS_H) toplev.h
- 
- CFLAGS-prefix.o += -DPREFIX=\"$(prefix)\" -DBASEVER=$(BASEVER_s)
- prefix.o: prefix.c $(CONFIG_H) $(SYSTEM_H) coretypes.h prefix.h \
-Index: gcc-4.8.4/gcc/common.opt
-===================================================================
---- gcc-4.8.4.orig/gcc/common.opt
-+++ gcc-4.8.4/gcc/common.opt
-@@ -595,6 +595,10 @@ Wpedantic
- Common Var(pedantic) Warning
- Issue warnings needed for strict compliance to the standard
- 
-+Wpoison-system-directories
-+Common Var(flag_poison_system_directories) Init(1) Warning
-+Warn for -I and -L options using system directories if cross compiling
-+
- Wshadow
- Common Var(warn_shadow) Warning
- Warn when one local variable shadows another
-Index: gcc-4.8.4/gcc/config.in
-===================================================================
---- gcc-4.8.4.orig/gcc/config.in
-+++ gcc-4.8.4/gcc/config.in
-@@ -138,6 +138,12 @@
- #endif
- 
- 
-+/* Define to warn for use of native system header directories */
-+#ifndef USED_FOR_TARGET
-+#undef ENABLE_POISON_SYSTEM_DIRECTORIES
-+#endif
-+
-+
- /* Define if you want all operations on RTL (the basic data structure of the
-    optimizer and back end) to be checked for dynamic type safety at runtime.
-    This is quite expensive. */
-Index: gcc-4.8.4/gcc/configure
-===================================================================
---- gcc-4.8.4.orig/gcc/configure
-+++ gcc-4.8.4/gcc/configure
-@@ -918,6 +918,7 @@ with_gc
- with_system_zlib
- enable_maintainer_mode
- enable_version_specific_runtime_libs
-+enable_poison_system_directories
- enable_plugin
- enable_libquadmath_support
- with_linker_hash_style
-@@ -1639,6 +1640,8 @@ Optional Features:
-   --enable-version-specific-runtime-libs
-                           specify that runtime libraries should be installed
-                           in a compiler-specific directory
-+  --enable-poison-system-directories
-+                          warn for use of native system header directories
-   --enable-plugin         enable plugin support
-   --disable-libquadmath-support
-                           disable libquadmath support for Fortran
-@@ -17847,7 +17850,7 @@ else
-   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
-   lt_status=$lt_dlunknown
-   cat > conftest.$ac_ext <<_LT_EOF
--#line 17850 "configure"
-+#line 17853 "configure"
- #include "confdefs.h"
- 
- #if HAVE_DLFCN_H
-@@ -17953,7 +17956,7 @@ else
-   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
-   lt_status=$lt_dlunknown
-   cat > conftest.$ac_ext <<_LT_EOF
--#line 17956 "configure"
-+#line 17959 "configure"
- #include "confdefs.h"
- 
- #if HAVE_DLFCN_H
-@@ -27219,6 +27222,19 @@ if test "${enable_version_specific_runti
- fi
- 
- 
-+# Check whether --enable-poison-system-directories was given.
-+if test "${enable_poison_system_directories+set}" = set; then :
-+  enableval=$enable_poison_system_directories;
-+else
-+  enable_poison_system_directories=no
-+fi
-+
-+if test "x${enable_poison_system_directories}" = "xyes"; then
-+
-+$as_echo "#define ENABLE_POISON_SYSTEM_DIRECTORIES 1" >>confdefs.h
-+
-+fi
-+
- # Substitute configuration variables
- 
- 
-Index: gcc-4.8.4/gcc/configure.ac
-===================================================================
---- gcc-4.8.4.orig/gcc/configure.ac
-+++ gcc-4.8.4/gcc/configure.ac
-@@ -5120,6 +5120,16 @@ AC_ARG_ENABLE(version-specific-runtime-l
-                 [specify that runtime libraries should be
-                  installed in a compiler-specific directory])])
- 
-+AC_ARG_ENABLE([poison-system-directories],
-+             AS_HELP_STRING([--enable-poison-system-directories],
-+                            [warn for use of native system header directories]),,
-+             [enable_poison_system_directories=no])
-+if test "x${enable_poison_system_directories}" = "xyes"; then
-+  AC_DEFINE([ENABLE_POISON_SYSTEM_DIRECTORIES],
-+           [1],
-+           [Define to warn for use of native system header directories])
-+fi
-+
- # Substitute configuration variables
- AC_SUBST(subdirs)
- AC_SUBST(srcdir)
-Index: gcc-4.8.4/gcc/doc/invoke.texi
-===================================================================
---- gcc-4.8.4.orig/gcc/doc/invoke.texi
-+++ gcc-4.8.4/gcc/doc/invoke.texi
-@@ -258,6 +258,7 @@ Objective-C and Objective-C++ Dialects}.
- -Woverlength-strings  -Wpacked  -Wpacked-bitfield-compat  -Wpadded @gol
- -Wparentheses  -Wpedantic-ms-format -Wno-pedantic-ms-format @gol
- -Wpointer-arith  -Wno-pointer-to-int-cast @gol
-+-Wno-poison-system-directories @gol
- -Wredundant-decls  -Wno-return-local-addr @gol
- -Wreturn-type  -Wsequence-point  -Wshadow @gol
- -Wsign-compare  -Wsign-conversion  -Wsizeof-pointer-memaccess @gol
-@@ -4022,6 +4023,14 @@ headers---for that, @option{-Wunknown-pr
-  for most targets, it is made up of code and thus requires the stack
-  to be made executable in order for the program to work properly.
- 
-+@item -Wno-poison-system-directories
-+@opindex Wno-poison-system-directories
-+Do not warn for @option{-I} or @option{-L} options using system
-+directories such as @file{/usr/include} when cross compiling.  This
-+option is intended for use in chroot environments when such
-+directories contain the correct headers and libraries for the target
-+system rather than the host.
-+
- @item -Wfloat-equal
- @opindex Wfloat-equal
- @opindex Wno-float-equal
-Index: gcc-4.8.4/gcc/gcc.c
-===================================================================
---- gcc-4.8.4.orig/gcc/gcc.c
-+++ gcc-4.8.4/gcc/gcc.c
-@@ -741,6 +741,8 @@ proper position among the other output f
-    "%{fuse-ld=*:-fuse-ld=%*}\
-     %X %{o*} %{e*} %{N} %{n} %{r}\
-     %{s} %{t} %{u*} %{z} %{Z} %{!nostdlib:%{!nostartfiles:%S}}\
-+    %{Wno-poison-system-directories:--no-poison-system-directories}\
-+    %{Werror=poison-system-directories:--error-poison-system-directories}\
-     %{static:} %{L*} %(mfwrap) %(link_libgcc) " SANITIZER_EARLY_SPEC " %o\
-     %{fopenmp|ftree-parallelize-loops=*:%:include(libgomp.spec)%(link_gomp)}\
-     %{fgnu-tm:%:include(libitm.spec)%(link_itm)}\
-Index: gcc-4.8.4/gcc/incpath.c
-===================================================================
---- gcc-4.8.4.orig/gcc/incpath.c
-+++ gcc-4.8.4/gcc/incpath.c
-@@ -28,6 +28,7 @@
- #include "intl.h"
- #include "incpath.h"
- #include "cppdefault.h"
-+#include "diagnostic-core.h"
- 
- /* Microsoft Windows does not natively support inodes.
-    VMS has non-numeric inodes.  */
-@@ -382,6 +383,24 @@ merge_include_chains (const char *sysroo
- 	}
-       fprintf (stderr, _("End of search list.\n"));
-     }
-+
-+#ifdef ENABLE_POISON_SYSTEM_DIRECTORIES
-+  if (flag_poison_system_directories)
-+    {
-+       struct cpp_dir *p;
-+
-+       for (p = heads[QUOTE]; p; p = p->next)
-+         {
-+          if ((!strncmp (p->name, "/usr/include", 12))
-+              || (!strncmp (p->name, "/usr/local/include", 18))
-+              || (!strncmp (p->name, "/usr/X11R6/include", 18)))
-+            warning (OPT_Wpoison_system_directories,
-+                     "include location \"%s\" is unsafe for "
-+                     "cross-compilation",
-+                     p->name);
-+         }
-+    }
-+#endif
- }
- 
- /* Use given -I paths for #include "..." but not #include <...>, and
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0017-gcc-poison-dir-extend.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0017-gcc-poison-dir-extend.patch
deleted file mode 100644
index 9e81efd..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0017-gcc-poison-dir-extend.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From e99c9c97266d6d3e8cac798aa91408250c4d60cf Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:00:34 +0400
-Subject: [PATCH 17/35] gcc-poison-dir-extend
-
-Add /sw/include and /opt/include based on the original
-zecke-no-host-includes.patch patch.  The original patch checked for
-/usr/include, /sw/include and /opt/include and then triggered a failure and
-aborted.
-
-Instead, we add the two missing items to the current scan.  If the user
-wants this to be a failure, they can add "-Werror=poison-system-directories".
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- gcc/incpath.c |    4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-diff --git a/gcc/incpath.c b/gcc/incpath.c
-index cd41c78..eac4a92 100644
---- a/gcc/incpath.c
-+++ b/gcc/incpath.c
-@@ -393,7 +393,9 @@ merge_include_chains (const char *sysroot, cpp_reader *pfile, int verbose)
-          {
-           if ((!strncmp (p->name, "/usr/include", 12))
-               || (!strncmp (p->name, "/usr/local/include", 18))
--              || (!strncmp (p->name, "/usr/X11R6/include", 18)))
-+              || (!strncmp (p->name, "/usr/X11R6/include", 18))
-+              || (!strncmp (p->name, "/sw/include", 11))
-+              || (!strncmp (p->name, "/opt/include", 12)))
-             warning (OPT_Wpoison_system_directories,
-                      "include location \"%s\" is unsafe for "
-                      "cross-compilation",
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0018-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0018-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
deleted file mode 100644
index a28cafd..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0018-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
+++ /dev/null
@@ -1,73 +0,0 @@
-From 56207fa2923e8edf774e98ffac82666091076be3 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:08:31 +0400
-Subject: [PATCH 18/35] gcc-4.3.3: SYSROOT_CFLAGS_FOR_TARGET
-
-Before committing, I noticed that PR/32161 was marked as a dup of PR/32009, but my previous patch did not fix it.
-
-This alternative patch is better because it lets you just use CFLAGS_FOR_TARGET to set the compilation flags for libgcc. Since bootstrapped target libraries are never compiled with the native compiler, it makes little sense to use different flags for stage1 and later stages. And it also makes little sense to use a different variable than CFLAGS_FOR_TARGET.
-
-Other changes I had to do include:
-
-- moving the creation of default CFLAGS_FOR_TARGET from Makefile.am to configure.ac, because otherwise the BOOT_CFLAGS are substituted into CFLAGS_FOR_TARGET (which is "-O2 -g $(CFLAGS)") via $(CFLAGS). It is also cleaner this way though.
-
-- passing the right CFLAGS to configure scripts as exported environment variables
-
-I also stopped passing LIBCFLAGS to configure scripts since they are unused in the whole src tree. And I updated the documentation as H-P reminded me to do.
-
-Bootstrapped/regtested i686-pc-linux-gnu, will commit to 4.4 shortly. Ok for 4.3?
-
-Signed-off-by: Paolo Bonzini  <bonzini@gnu.org>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- configure |   32 ++++++++++++++++++++++++++++++++
- 1 file changed, 32 insertions(+)
-
-diff --git a/configure b/configure
-index 1b76c90..e4dce7c 100755
---- a/configure
-+++ b/configure
-@@ -6772,6 +6772,38 @@ fi
- 
- 
- 
-+# During gcc bootstrap, if we use some random cc for stage1 then CFLAGS
-+# might be empty or "-g".  We don't require a C++ compiler, so CXXFLAGS
-+# might also be empty (or "-g", if a non-GCC C++ compiler is in the path).
-+# We want to ensure that TARGET libraries (which we know are built with
-+# gcc) are built with "-O2 -g", so include those options when setting
-+# CFLAGS_FOR_TARGET and CXXFLAGS_FOR_TARGET.
-+if test "x$CFLAGS_FOR_TARGET" = x; then
-+  CFLAGS_FOR_TARGET=$CFLAGS
-+  case " $CFLAGS " in
-+    *" -O2 "*) ;;
-+    *) CFLAGS_FOR_TARGET="-O2 $CFLAGS" ;;
-+  esac
-+  case " $CFLAGS " in
-+    *" -g "* | *" -g3 "*) ;;
-+    *) CFLAGS_FOR_TARGET="-g $CFLAGS" ;;
-+  esac
-+fi
-+
-+
-+if test "x$CXXFLAGS_FOR_TARGET" = x; then
-+  CXXFLAGS_FOR_TARGET=$CXXFLAGS
-+  case " $CXXFLAGS " in
-+    *" -O2 "*) ;;
-+    *) CXXFLAGS_FOR_TARGET="-O2 $CXXFLAGS" ;;
-+  esac
-+  case " $CXXFLAGS " in
-+    *" -g "* | *" -g3 "*) ;;
-+    *) CXXFLAGS_FOR_TARGET="-g $CXXFLAGS" ;;
-+  esac
-+fi
-+
-+
- # Handle --with-headers=XXX.  If the value is not "yes", the contents of
- # the named directory are copied to $(tooldir)/sys-include.
- if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0019-64-bit-multilib-hack.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0019-64-bit-multilib-hack.patch
deleted file mode 100644
index a975cfb..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0019-64-bit-multilib-hack.patch
+++ /dev/null
@@ -1,79 +0,0 @@
-From 18fde5740b09324dfb9cf41e9849672573ff5fa0 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:10:06 +0400
-Subject: [PATCH 19/35] 64-bit multilib hack.
-
-GCC has internal multilib handling code but it assumes a very specific rigid directory
-layout. The build system implementation of multilib layout is very generic and allows
-complete customisation of the library directories.
-
-This patch is a partial solution to allow any custom directories to be passed into gcc
-and handled correctly. It forces gcc to use the base_libdir (which is the current
-directory, "."). We need to do this for each multilib that is configured as we don't
-know which compiler options may be being passed into the compiler. Since we have a compiler
-per mulitlib at this point that isn't an issue.
-
-The one problem is the target compiler is only going to work for the default multlilib at
-this point. Ideally we'd figure out which multilibs were being enabled with which paths
-and be able to patch these entries with a complete set of correct paths but this we
-don't have such code at this point. This is something the target gcc recipe should do
-and override these platform defaults in its build config.
-
-RP 15/8/11
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Elvis Dowson <elvis.dowson@gmail.com>
-
-Upstream-Status: Pending
----
- gcc/config/i386/t-linux64   |    6 ++----
- gcc/config/mips/t-linux64   |   10 +++-------
- gcc/config/rs6000/t-linux64 |    5 ++---
- 3 files changed, 7 insertions(+), 14 deletions(-)
-
-Index: gcc-4.8.4/gcc/config/i386/t-linux64
-===================================================================
---- gcc-4.8.4.orig/gcc/config/i386/t-linux64
-+++ gcc-4.8.4/gcc/config/i386/t-linux64
-@@ -32,7 +32,5 @@
- #
- comma=,
- MULTILIB_OPTIONS    = $(subst $(comma),/,$(TM_MULTILIB_CONFIG))
--MULTILIB_DIRNAMES   = $(patsubst m%, %, $(subst /, ,$(MULTILIB_OPTIONS)))
--MULTILIB_OSDIRNAMES = m64=../lib64$(call if_multiarch,:x86_64-linux-gnu)
--MULTILIB_OSDIRNAMES+= m32=$(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)$(call if_multiarch,:i386-linux-gnu)
--MULTILIB_OSDIRNAMES+= mx32=../libx32$(call if_multiarch,:x86_64-linux-gnux32)
-+MULTILIB_DIRNAMES = . .
-+MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir))
-Index: gcc-4.8.4/gcc/config/mips/t-linux64
-===================================================================
---- gcc-4.8.4.orig/gcc/config/mips/t-linux64
-+++ gcc-4.8.4/gcc/config/mips/t-linux64
-@@ -17,10 +17,6 @@
- # <http://www.gnu.org/licenses/>.
- 
- MULTILIB_OPTIONS = mabi=n32/mabi=32/mabi=64
--MULTILIB_DIRNAMES = n32 32 64
--MIPS_EL = $(if $(filter %el, $(firstword $(subst -, ,$(target)))),el)
--MIPS_SOFT = $(if $(strip $(filter MASK_SOFT_FLOAT_ABI, $(target_cpu_default)) $(filter soft, $(with_float))),soft)
--MULTILIB_OSDIRNAMES = \
--	../lib32$(call if_multiarch,:mips64$(MIPS_EL)-linux-gnuabin32$(MIPS_SOFT)) \
--	../lib$(call if_multiarch,:mips$(MIPS_EL)-linux-gnu$(MIPS_SOFT)) \
--	../lib64$(call if_multiarch,:mips64$(MIPS_EL)-linux-gnuabi64$(MIPS_SOFT))
-+MULTILIB_DIRNAMES = . . .
-+MULTILIB_OSDIRNAMES = ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir))
-+
-Index: gcc-4.8.4/gcc/config/rs6000/t-linux64
-===================================================================
---- gcc-4.8.4.orig/gcc/config/rs6000/t-linux64
-+++ gcc-4.8.4/gcc/config/rs6000/t-linux64
-@@ -26,7 +26,6 @@
- # MULTILIB_OSDIRNAMES according to what is found on the target.
- 
- MULTILIB_OPTIONS    := m64/m32
--MULTILIB_DIRNAMES   := 64 32
-+MULTILIB_DIRNAMES   := . .
- MULTILIB_EXTRA_OPTS := 
--MULTILIB_OSDIRNAMES := m64=../lib64$(call if_multiarch,:powerpc64-linux-gnu)
--MULTILIB_OSDIRNAMES += m32=$(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib)$(call if_multiarch,:powerpc-linux-gnu)
-+MULTILIB_OSDIRNAMES := ../$(shell basename $(base_libdir)) ../$(shell basename $(base_libdir))
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0020-optional-libstdc.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0020-optional-libstdc.patch
deleted file mode 100644
index eff021e..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0020-optional-libstdc.patch
+++ /dev/null
@@ -1,102 +0,0 @@
-From 307c8ff3ef666b7bd5ac733863f2fbb27a9d521e Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:12:56 +0400
-Subject: [PATCH 20/35] optional libstdc
-
-gcc-runtime builds libstdc++ separately from gcc-cross-*. Its configure tests using g++
-will not run correctly since by default the linker will try to link against libstdc++
-which shouldn't exist yet. We need an option to disable -lstdc++
-option whilst leaving -lc, -lgcc and other automatic library dependencies added by gcc
-driver. This patch adds such an option which only disables the -lstdc++.
-
-A "standard" gcc build uses xgcc and hence avoids this. We should ask upstream how to
-do this officially, the likely answer is don't build libstdc++ separately.
-
-RP 29/6/10
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Inappropriate [embedded specific]
----
- gcc/c-family/c.opt  |    4 ++++
- gcc/cp/g++spec.c    |    1 +
- gcc/doc/invoke.texi |    9 +++++++--
- gcc/gcc.c           |    1 +
- 4 files changed, 13 insertions(+), 2 deletions(-)
-
-diff --git a/gcc/c-family/c.opt b/gcc/c-family/c.opt
-index 10ae84d..dc3ffdf 100644
---- a/gcc/c-family/c.opt
-+++ b/gcc/c-family/c.opt
-@@ -1299,6 +1299,10 @@ nostdinc++
- C++ ObjC++
- Do not search standard system include directories for C++
- 
-+nostdlib++
-+Driver
-+Do not link standard C++ runtime library
-+
- o
- C ObjC C++ ObjC++ Joined Separate
- ; Documented in common.opt
-diff --git a/gcc/cp/g++spec.c b/gcc/cp/g++spec.c
-index b896eea..f55216b 100644
---- a/gcc/cp/g++spec.c
-+++ b/gcc/cp/g++spec.c
-@@ -126,6 +126,7 @@ lang_specific_driver (struct cl_decoded_option **in_decoded_options,
-       switch (decoded_options[i].opt_index)
- 	{
- 	case OPT_nostdlib:
-+	case OPT_nostdlib__:
- 	case OPT_nodefaultlibs:
- 	  library = -1;
- 	  break;
-diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
-index a022622..f15c991 100644
---- a/gcc/doc/invoke.texi
-+++ b/gcc/doc/invoke.texi
-@@ -190,7 +190,7 @@ in the following sections.
- -frepo  -fno-rtti  -fstats  -ftemplate-backtrace-limit=@var{n} @gol
- -ftemplate-depth=@var{n} @gol
- -fno-threadsafe-statics -fuse-cxa-atexit  -fno-weak  -nostdinc++ @gol
---fno-default-inline  -fvisibility-inlines-hidden @gol
-+-nostdlib++ -fno-default-inline  -fvisibility-inlines-hidden @gol
- -fvisibility-ms-compat @gol
- -fext-numeric-literals @gol
- -Wabi  -Wconversion-null  -Wctor-dtor-privacy @gol
-@@ -453,7 +453,7 @@ Objective-C and Objective-C++ Dialects}.
- -nostartfiles  -nodefaultlibs  -nostdlib -pie -rdynamic @gol
- -s  -static -static-libgcc -static-libstdc++ @gol
- -static-libasan -static-libtsan @gol
---shared -shared-libgcc  -symbolic @gol
-+-shared -shared-libgcc  -symbolic -nostdlib++ @gol
- -T @var{script}  -Wl,@var{option}  -Xlinker @var{option} @gol
- -u @var{symbol}}
- 
-@@ -9886,6 +9886,11 @@ These entries are usually resolved by entries in
- libc.  These entry points should be supplied through some other
- mechanism when this option is specified.
- 
-+@item -nostdlib++
-+@opindex nostdlib++
-+Do not use the standard system C++ runtime libraries when linking.
-+Only the libraries you specify will be passed to the linker.
-+
- @cindex @option{-lgcc}, use with @option{-nostdlib}
- @cindex @option{-nostdlib} and unresolved references
- @cindex unresolved references and @option{-nostdlib}
-diff --git a/gcc/gcc.c b/gcc/gcc.c
-index efdb625..477752f 100644
---- a/gcc/gcc.c
-+++ b/gcc/gcc.c
-@@ -748,6 +748,7 @@ proper position among the other output files.  */
-     %(mflib) " STACK_SPLIT_SPEC "\
-     %{fprofile-arcs|fprofile-generate*|coverage:-lgcov} " SANITIZER_SPEC " \
-     %{!nostdlib:%{!nodefaultlibs:%(link_ssp) %(link_gcc_c_sequence)}}\
-+    %{!nostdlib++:}\
-     %{!nostdlib:%{!nostartfiles:%E}} %{T*} }}}}}}"
- #endif
- 
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0021-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0021-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
deleted file mode 100644
index eb3c61f..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0021-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From 004696e054ae9dc71d512cc755ccc4074fc62b2d Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:14:20 +0400
-Subject: [PATCH 21/35] gcc: disable MASK_RELAX_PIC_CALLS bit
-
-The new feature added after 4.3.3
-"http://www.pubbs.net/200909/gcc/94048-patch-add-support-for-rmipsjalr.html"
-will cause cc1plus eat up all the system memory when build webkit-gtk.
-The function mips_get_pic_call_symbol keeps on recursively calling itself.
-Disable this feature to walk aside the bug.
-
-Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Inappropriate [configuration]
----
- gcc/configure    |    7 -------
- gcc/configure.ac |    7 -------
- 2 files changed, 14 deletions(-)
-
-diff --git a/gcc/configure b/gcc/configure
-index b65d21d..bdab45a 100755
---- a/gcc/configure
-+++ b/gcc/configure
-@@ -25829,13 +25829,6 @@ $as_echo_n "checking assembler and linker for explicit JALR relocation... " >&6;
-         rm -f conftest.*
-       fi
-     fi
--    if test $gcc_cv_as_ld_jalr_reloc = yes; then
--      if test x$target_cpu_default = x; then
--        target_cpu_default=MASK_RELAX_PIC_CALLS
--      else
--        target_cpu_default="($target_cpu_default)|MASK_RELAX_PIC_CALLS"
--      fi
--    fi
-     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ld_jalr_reloc" >&5
- $as_echo "$gcc_cv_as_ld_jalr_reloc" >&6; }
- 
-diff --git a/gcc/configure.ac b/gcc/configure.ac
-index e226b85..5f5c909 100644
---- a/gcc/configure.ac
-+++ b/gcc/configure.ac
-@@ -4099,13 +4099,6 @@ x:
-         rm -f conftest.*
-       fi
-     fi
--    if test $gcc_cv_as_ld_jalr_reloc = yes; then
--      if test x$target_cpu_default = x; then
--        target_cpu_default=MASK_RELAX_PIC_CALLS
--      else
--        target_cpu_default="($target_cpu_default)|MASK_RELAX_PIC_CALLS"
--      fi
--    fi
-     AC_MSG_RESULT($gcc_cv_as_ld_jalr_reloc)
- 
-     AC_CACHE_CHECK([linker for .eh_frame personality relaxation],
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0022-COLLECT_GCC_OPTIONS.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0022-COLLECT_GCC_OPTIONS.patch
deleted file mode 100644
index 40c8abf..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0022-COLLECT_GCC_OPTIONS.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From 7f5c9dcc71c8b83a0b5596266cc4bdf0936e8e00 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:16:28 +0400
-Subject: [PATCH 22/35] COLLECT_GCC_OPTIONS
-
-This patch adds --sysroot into COLLECT_GCC_OPTIONS which is used to
-invoke collect2.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- gcc/gcc.c |    9 +++++++++
- 1 file changed, 9 insertions(+)
-
-diff --git a/gcc/gcc.c b/gcc/gcc.c
-index 477752f..51062aa 100644
---- a/gcc/gcc.c
-+++ b/gcc/gcc.c
-@@ -4098,6 +4098,15 @@ set_collect_gcc_options (void)
- 		sizeof ("COLLECT_GCC_OPTIONS=") - 1);
- 
-   first_time = TRUE;
-+#ifdef HAVE_LD_SYSROOT
-+  if (target_system_root_changed && target_system_root)
-+    {
-+      obstack_grow (&collect_obstack, "'--sysroot=", sizeof("'--sysroot=")-1);
-+      obstack_grow (&collect_obstack, target_system_root,strlen(target_system_root));
-+      obstack_grow (&collect_obstack, "'", 1);
-+      first_time = FALSE;
-+    }
-+#endif
-   for (i = 0; (int) i < n_switches; i++)
-     {
-       const char *const *args;
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0023-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0023-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
deleted file mode 100644
index 9e4435c..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0023-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
+++ /dev/null
@@ -1,88 +0,0 @@
-From 46d52439052f0876a92dcf8a0ab9c60d75c8030b Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:17:25 +0400
-Subject: [PATCH 23/35] Use the defaults.h in ${B} instead of ${S}, and t-oe
- in ${B}
-
-Use the defaults.h in ${B} instead of ${S}, and t-oe in ${B}, so that
-the source can be shared between gcc-cross-initial,
-gcc-cross-intermediate, gcc-cross, gcc-runtime, and also the sdk build.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- gcc/Makefile.in  |    2 +-
- gcc/configure    |    4 ++--
- gcc/configure.ac |    4 ++--
- gcc/mkconfig.sh  |    4 ++--
- 4 files changed, 7 insertions(+), 7 deletions(-)
-
-diff --git a/gcc/Makefile.in b/gcc/Makefile.in
-index 90a2bba..2320497 100644
---- a/gcc/Makefile.in
-+++ b/gcc/Makefile.in
-@@ -469,7 +469,7 @@ TARGET_SYSTEM_ROOT = @TARGET_SYSTEM_ROOT@
- TARGET_SYSTEM_ROOT_DEFINE = @TARGET_SYSTEM_ROOT_DEFINE@
- 
- xmake_file=@xmake_file@
--tmake_file=@tmake_file@
-+tmake_file=@tmake_file@ ./t-oe
- TM_ENDIAN_CONFIG=@TM_ENDIAN_CONFIG@
- TM_MULTILIB_CONFIG=@TM_MULTILIB_CONFIG@
- TM_MULTILIB_EXCEPTIONS_CONFIG=@TM_MULTILIB_EXCEPTIONS_CONFIG@
-diff --git a/gcc/configure b/gcc/configure
-index bdab45a..d587993 100755
---- a/gcc/configure
-+++ b/gcc/configure
-@@ -11539,8 +11539,8 @@ for f in $tm_file; do
-        tm_include_list="${tm_include_list} $f"
-        ;;
-     defaults.h )
--       tm_file_list="${tm_file_list} \$(srcdir)/$f"
--       tm_include_list="${tm_include_list} $f"
-+       tm_file_list="${tm_file_list} ./$f"
-+       tm_include_list="${tm_include_list} ./$f"
-        ;;
-     * )
-        tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
-diff --git a/gcc/configure.ac b/gcc/configure.ac
-index 5f5c909..5e5e84f 100644
---- a/gcc/configure.ac
-+++ b/gcc/configure.ac
-@@ -1720,8 +1720,8 @@ for f in $tm_file; do
-        tm_include_list="${tm_include_list} $f"
-        ;;
-     defaults.h )
--       tm_file_list="${tm_file_list} \$(srcdir)/$f"
--       tm_include_list="${tm_include_list} $f"
-+       tm_file_list="${tm_file_list} ./$f"
-+       tm_include_list="${tm_include_list} ./$f"
-        ;;
-     * )
-        tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
-diff --git a/gcc/mkconfig.sh b/gcc/mkconfig.sh
-index 29fdfc7..e048dce 100644
---- a/gcc/mkconfig.sh
-+++ b/gcc/mkconfig.sh
-@@ -77,7 +77,7 @@ if [ -n "$HEADERS" ]; then
-     if [ $# -ge 1 ]; then
- 	echo '#ifdef IN_GCC' >> ${output}T
- 	for file in "$@"; do
--	    if test x"$file" = x"defaults.h"; then
-+	    if test x"$file" = x"./defaults.h"; then
- 		postpone_defaults_h="yes"
- 	    else
- 		echo "# include \"$file\"" >> ${output}T
-@@ -103,7 +103,7 @@ esac
- 
- # If we postponed including defaults.h, add the #include now.
- if test x"$postpone_defaults_h" = x"yes"; then
--    echo "# include \"defaults.h\"" >> ${output}T
-+    echo "# include \"./defaults.h\"" >> ${output}T
- fi
- 
- # Add multiple inclusion protection guard, part two.
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0024-PR-target-32219.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0024-PR-target-32219.patch
deleted file mode 100644
index b47d841..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0024-PR-target-32219.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-From e0d15f4f8bf28c351b9215ca37f1caa24df0e1fd Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:18:54 +0400
-Subject: [PATCH 24/35] PR target/32219
-
-* varasm.c (default_binds_local_p_1): Weak data is not local.
-
-Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Backport
----
- gcc/testsuite/gcc.dg/visibility-21.c |   14 ++++++++++++++
- gcc/varasm.c                         |    9 ++++-----
- 2 files changed, 18 insertions(+), 5 deletions(-)
- create mode 100644 gcc/testsuite/gcc.dg/visibility-21.c
-
-diff --git a/gcc/testsuite/gcc.dg/visibility-21.c b/gcc/testsuite/gcc.dg/visibility-21.c
-new file mode 100644
-index 0000000..be7deda
---- /dev/null
-+++ b/gcc/testsuite/gcc.dg/visibility-21.c
-@@ -0,0 +1,14 @@
-+/* PR target/32219 */
-+/* { dg-do run } */
-+/* { dg-require-visibility "" } */
-+/* { dg-options "-fPIC" { target fpic } } */
-+
-+extern void f() __attribute__((weak,visibility("hidden")));
-+extern int puts( char const* );
-+int main()
-+{
-+	if (f)
-+		f();
-+	return 0;
-+}
-+
-diff --git a/gcc/varasm.c b/gcc/varasm.c
-index 6648103..fadba78 100644
---- a/gcc/varasm.c
-+++ b/gcc/varasm.c
-@@ -6675,6 +6675,10 @@ default_binds_local_p_1 (const_tree exp, int shlib)
-   /* Static variables are always local.  */
-   else if (! TREE_PUBLIC (exp))
-     local_p = true;
-+  /* hidden weak can't be overridden by something non-local, all
-+     that is possible is that it is not defined at all. */
-+  else if (DECL_WEAK (exp))
-+    local_p = false;
-   /* A variable is local if the user has said explicitly that it will
-      be.  */
-   else if ((DECL_VISIBILITY_SPECIFIED (exp)
-@@ -6688,11 +6692,6 @@ default_binds_local_p_1 (const_tree exp, int shlib)
-      local.  */
-   else if (DECL_VISIBILITY (exp) != VISIBILITY_DEFAULT)
-     local_p = true;
--  /* Default visibility weak data can be overridden by a strong symbol
--     in another module and so are not local.  */
--  else if (DECL_WEAK (exp)
--	   && !resolved_locally)
--    local_p = false;
-   /* If PIC, then assume that any global name can be overridden by
-      symbols resolved from other modules.  */
-   else if (shlib)
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0025-fortran-cross-compile-hack.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0025-fortran-cross-compile-hack.patch
deleted file mode 100644
index 0e7914d..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0025-fortran-cross-compile-hack.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From af8a56ea4e17b2909eff2c57704ab43ef24f28d3 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:20:01 +0400
-Subject: [PATCH 25/35] fortran cross-compile hack.
-
-* Fortran would have searched for arm-angstrom-gnueabi-gfortran but would have used
-used gfortan. For gcc_4.2.2.bb we want to use the gfortran compiler from our cross
-directory.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Inappropriate [embedded specific]
----
- libgfortran/configure    |    2 +-
- libgfortran/configure.ac |    2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/libgfortran/configure b/libgfortran/configure
-index 8385e96..b8f7a92 100755
---- a/libgfortran/configure
-+++ b/libgfortran/configure
-@@ -12704,7 +12704,7 @@ esac
- 
- # We need gfortran to compile parts of the library
- #AC_PROG_FC(gfortran)
--FC="$GFORTRAN"
-+#FC="$GFORTRAN"
- ac_ext=${ac_fc_srcext-f}
- ac_compile='$FC -c $FCFLAGS $ac_fcflags_srcext conftest.$ac_ext >&5'
- ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $ac_fcflags_srcext conftest.$ac_ext $LIBS >&5'
-diff --git a/libgfortran/configure.ac b/libgfortran/configure.ac
-index 7d97fed..3f9f484 100644
---- a/libgfortran/configure.ac
-+++ b/libgfortran/configure.ac
-@@ -227,7 +227,7 @@ AC_SUBST(enable_static)
- 
- # We need gfortran to compile parts of the library
- #AC_PROG_FC(gfortran)
--FC="$GFORTRAN"
-+#FC="$GFORTRAN"
- AC_PROG_FC(gfortran)
- 
- # extra LD Flags which are required for targets
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0026-libgcc-sjlj-check.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0026-libgcc-sjlj-check.patch
deleted file mode 100644
index d4efab9..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0026-libgcc-sjlj-check.patch
+++ /dev/null
@@ -1,74 +0,0 @@
-From 08c2398445e6cac282488f64ae6bf29cbcd8db23 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:20:50 +0400
-Subject: [PATCH 26/35] libgcc-sjlj-check
-
-ac_fn_c_try_compile doesnt seem to keep the intermediate files
-which are needed for sjlj test to pass since it greps into the
-generated file. So we run the compiler command using AC_TRY_COMMAND
-which then generates the needed .s file
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- libgcc/configure    |   10 ++++++----
- libgcc/configure.ac |   10 ++++------
- 2 files changed, 10 insertions(+), 10 deletions(-)
-
-diff --git a/libgcc/configure b/libgcc/configure
-index 1425df6..d18e3cb 100644
---- a/libgcc/configure
-+++ b/libgcc/configure
-@@ -4208,17 +4208,19 @@ void foo ()
- }
- 
- _ACEOF
--CFLAGS_hold=$CFLAGS
--CFLAGS="--save-temps -fexceptions"
- libgcc_cv_lib_sjlj_exceptions=unknown
--if ac_fn_c_try_compile; then :
-+if { ac_try='${CC-cc} -fexceptions -S conftest.c -o conftest.s 1>&5'
-+  { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
-+  (eval $ac_try) 2>&5
-+  ac_status=$?
-+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
-+  test $ac_status = 0; }; }; then
-   if grep _Unwind_SjLj_Resume conftest.s >/dev/null 2>&1; then
-     libgcc_cv_lib_sjlj_exceptions=yes
-   elif grep _Unwind_Resume conftest.s >/dev/null 2>&1; then
-     libgcc_cv_lib_sjlj_exceptions=no
-   fi
- fi
--CFLAGS=$CFLAGS_hold
- rm -f conftest*
- 
- fi
-diff --git a/libgcc/configure.ac b/libgcc/configure.ac
-index 8b7aba5..c7c9644 100644
---- a/libgcc/configure.ac
-+++ b/libgcc/configure.ac
-@@ -216,16 +216,14 @@ void foo ()
-   bar();
- }
- ])])
--CFLAGS_hold=$CFLAGS
--CFLAGS="--save-temps -fexceptions"
- libgcc_cv_lib_sjlj_exceptions=unknown
--AS_IF([ac_fn_c_try_compile],
--  [if grep _Unwind_SjLj_Resume conftest.s >/dev/null 2>&1; then
-+if AC_TRY_COMMAND(${CC-cc} -fexceptions -S conftest.c -o conftest.s 1>&AS_MESSAGE_LOG_FD); then
-+  if grep _Unwind_SjLj_Resume conftest.s >/dev/null 2>&1; then
-     libgcc_cv_lib_sjlj_exceptions=yes
-   elif grep _Unwind_Resume conftest.s >/dev/null 2>&1; then
-     libgcc_cv_lib_sjlj_exceptions=no
--  fi])
--CFLAGS=$CFLAGS_hold
-+  fi
-+fi
- rm -f conftest*
- ])
- 
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0027-cpp-honor-sysroot.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0027-cpp-honor-sysroot.patch
deleted file mode 100644
index 05e9521..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0027-cpp-honor-sysroot.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From a0f9bd09c816ad29ecf7c29d6c27f7df97710364 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:22:00 +0400
-Subject: [PATCH 27/35] cpp: honor sysroot.
-
-Currently, if the gcc toolchain is relocated and installed from sstate, then you try and compile
-preprocessed source (.i or .ii files), the compiler will try and access the builtin sysroot location
-rather than the --sysroot option specified on the commandline. If access to that directory is
-permission denied (unreadable), gcc will error.
-
-This happens when ccache is in use due to the fact it uses preprocessed source files.
-
-The fix below adds %I to the cpp-output spec macro so the default substitutions for -iprefix,
--isystem, -isysroot happen and the correct sysroot is used.
-
-[YOCTO #2074]
-
-RP 2012/04/13
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- gcc/cp/lang-specs.h |    2 +-
- gcc/gcc.c           |    2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/gcc/cp/lang-specs.h b/gcc/cp/lang-specs.h
-index a001c3e..1aae1e4 100644
---- a/gcc/cp/lang-specs.h
-+++ b/gcc/cp/lang-specs.h
-@@ -63,5 +63,5 @@ along with GCC; see the file COPYING3.  If not see
-   {".ii", "@c++-cpp-output", 0, 0, 0},
-   {"@c++-cpp-output",
-    "%{!M:%{!MM:%{!E:\
--    cc1plus -fpreprocessed %i %(cc1_options) %2\
-+    cc1plus -fpreprocessed %i %I %(cc1_options) %2\
-     %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0},
-diff --git a/gcc/gcc.c b/gcc/gcc.c
-index 51062aa..cf6b99e 100644
---- a/gcc/gcc.c
-+++ b/gcc/gcc.c
-@@ -1042,7 +1042,7 @@ static const struct compiler default_compilers[] =
-                     %W{o*:--output-pch=%*}}%V}}}}}}", 0, 0, 0},
-   {".i", "@cpp-output", 0, 0, 0},
-   {"@cpp-output",
--   "%{!M:%{!MM:%{!E:cc1 -fpreprocessed %i %(cc1_options) %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0},
-+   "%{!M:%{!MM:%{!E:cc1 -fpreprocessed %i %I %(cc1_options) %{!fsyntax-only:%(invoke_as)}}}}", 0, 0, 0},
-   {".s", "@assembler", 0, 0, 0},
-   {"@assembler",
-    "%{!M:%{!MM:%{!E:%{!S:as %(asm_debug) %(asm_options) %i %A }}}}", 0, 0, 0},
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0028-MIPS64-Default-to-N64-ABI.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0028-MIPS64-Default-to-N64-ABI.patch
deleted file mode 100644
index 2638720..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0028-MIPS64-Default-to-N64-ABI.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 301e18d4711db5925e767fad08dffa9cfe0a2f1f Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:23:08 +0400
-Subject: [PATCH 28/35] MIPS64: Default to N64 ABI
-
-MIPS64 defaults to n32 ABI, this patch makes it
-so that it defaults to N64 ABI
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Inappropriate [OE config specific]
----
- gcc/config.gcc |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/gcc/config.gcc b/gcc/config.gcc
-index 1a0be50..989c2fb 100644
---- a/gcc/config.gcc
-+++ b/gcc/config.gcc
-@@ -1797,7 +1797,7 @@ mips*-mti-linux*)
- mips64*-*-linux* | mipsisa64*-*-linux*)
- 	tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ${tm_file} mips/gnu-user.h mips/gnu-user64.h mips/linux64.h mips/linux-common.h"
- 	tmake_file="${tmake_file} mips/t-linux64"
--	tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_N32"
-+	tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_64"
- 	case ${target} in
- 		mips64el-st-linux-gnu)
- 			tm_file="${tm_file} mips/st.h"
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0029-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0029-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
deleted file mode 100644
index 0aa6d92..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0029-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
+++ /dev/null
@@ -1,209 +0,0 @@
-From 29d12344fb682a053de53eb08b95704cf3b67af2 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:24:50 +0400
-Subject: [PATCH 29/35] Define GLIBC_DYNAMIC_LINKER and UCLIBC_DYNAMIC_LINKER
- relative to SYSTEMLIBS_DIR
-
-This patch defines GLIBC_DYNAMIC_LINKER and UCLIBC_DYNAMIC_LINKER
-relative to SYSTEMLIBS_DIR which can be set in generated headers
-This breaks the assumption of hardcoded multilib in gcc
-Change is only for the supported architectures in OE including
-SH, sparc, alpha for possible future support (if any)
-
-Removes the do_headerfix task in metadata
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Inappropriate [OE configuration]
----
- gcc/config/alpha/linux-elf.h |    4 ++--
- gcc/config/arm/linux-eabi.h  |    4 ++--
- gcc/config/arm/linux-elf.h   |    2 +-
- gcc/config/i386/linux.h      |    2 +-
- gcc/config/i386/linux64.h    |    6 +++---
- gcc/config/mips/linux.h      |    2 +-
- gcc/config/mips/linux64.h    |    8 ++++----
- gcc/config/rs6000/linux64.h  |    8 ++++----
- gcc/config/sh/linux.h        |    2 +-
- gcc/config/sparc/linux.h     |    2 +-
- gcc/config/sparc/linux64.h   |    4 ++--
- 11 files changed, 22 insertions(+), 22 deletions(-)
-
-Index: gcc-4.8.4/gcc/config/alpha/linux-elf.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/alpha/linux-elf.h
-+++ gcc-4.8.4/gcc/config/alpha/linux-elf.h
-@@ -23,8 +23,8 @@ along with GCC; see the file COPYING3.
- #define EXTRA_SPECS \
- { "elf_dynamic_linker", ELF_DYNAMIC_LINKER },
- 
--#define GLIBC_DYNAMIC_LINKER	"/lib/ld-linux.so.2"
--#define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
-+#define GLIBC_DYNAMIC_LINKER	SYSTEMLIBS_DIR "ld-linux.so.2"
-+#define UCLIBC_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-uClibc.so.0"
- #if DEFAULT_LIBC == LIBC_UCLIBC
- #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
- #elif DEFAULT_LIBC == LIBC_GLIBC
-Index: gcc-4.8.4/gcc/config/arm/linux-eabi.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/arm/linux-eabi.h
-+++ gcc-4.8.4/gcc/config/arm/linux-eabi.h
-@@ -68,8 +68,8 @@
-    GLIBC_DYNAMIC_LINKER_DEFAULT and TARGET_DEFAULT_FLOAT_ABI.  */
- 
- #undef  GLIBC_DYNAMIC_LINKER
--#define GLIBC_DYNAMIC_LINKER_SOFT_FLOAT "/lib/ld-linux.so.3"
--#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT "/lib/ld-linux-armhf.so.3"
-+#define GLIBC_DYNAMIC_LINKER_SOFT_FLOAT SYSTEMLIBS_DIR "ld-linux.so.3"
-+#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT SYSTEMLIBS_DIR "ld-linux-armhf.so.3"
- #define GLIBC_DYNAMIC_LINKER_DEFAULT GLIBC_DYNAMIC_LINKER_SOFT_FLOAT
- 
- #define GLIBC_DYNAMIC_LINKER \
-Index: gcc-4.8.4/gcc/config/arm/linux-elf.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/arm/linux-elf.h
-+++ gcc-4.8.4/gcc/config/arm/linux-elf.h
-@@ -57,7 +57,7 @@
- 
- #define LIBGCC_SPEC "%{mfloat-abi=soft*:-lfloat} -lgcc"
- 
--#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
-+#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
- 
- #define LINUX_TARGET_LINK_SPEC  "%{h*} \
-    %{static:-Bstatic} \
-Index: gcc-4.8.4/gcc/config/i386/linux.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/i386/linux.h
-+++ gcc-4.8.4/gcc/config/i386/linux.h
-@@ -20,4 +20,4 @@ along with GCC; see the file COPYING3.
- <http://www.gnu.org/licenses/>.  */
- 
- #define GNU_USER_LINK_EMULATION "elf_i386"
--#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
-+#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
-Index: gcc-4.8.4/gcc/config/i386/linux64.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/i386/linux64.h
-+++ gcc-4.8.4/gcc/config/i386/linux64.h
-@@ -27,6 +27,6 @@ see the files COPYING3 and COPYING.RUNTI
- #define GNU_USER_LINK_EMULATION64 "elf_x86_64"
- #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64"
- 
--#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2"
--#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2"
--#define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2"
-+#define GLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-linux.so.2"
-+#define GLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-linux-x86-64.so.2"
-+#define GLIBC_DYNAMIC_LINKERX32 SYSTEMLIBS_DIR "ld-linux-x32.so.2"
-Index: gcc-4.8.4/gcc/config/mips/linux.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/mips/linux.h
-+++ gcc-4.8.4/gcc/config/mips/linux.h
-@@ -17,4 +17,4 @@ You should have received a copy of the G
- along with GCC; see the file COPYING3.  If not see
- <http://www.gnu.org/licenses/>.  */
- 
--#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
-+#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld.so.1"
-Index: gcc-4.8.4/gcc/config/mips/linux64.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/mips/linux64.h
-+++ gcc-4.8.4/gcc/config/mips/linux64.h
-@@ -22,10 +22,10 @@ along with GCC; see the file COPYING3.
- #define GNU_USER_LINK_EMULATION64 "elf64%{EB:b}%{EL:l}tsmip"
- #define GNU_USER_LINK_EMULATIONN32 "elf32%{EB:b}%{EL:l}tsmipn32"
- 
--#define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1"
--#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld.so.1"
--#define GLIBC_DYNAMIC_LINKERN32 "/lib32/ld.so.1"
--#define UCLIBC_DYNAMIC_LINKERN32 "/lib32/ld-uClibc.so.0"
-+#define GLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld.so.1"
-+#define GLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld.so.1"
-+#define GLIBC_DYNAMIC_LINKERN32 SYSTEMLIBS_DIR "ld.so.1"
-+#define UCLIBC_DYNAMIC_LINKERN32 SYSTEMLIBS_DIR "ld-uClibc.so.0"
- #define BIONIC_DYNAMIC_LINKERN32 "/system/bin/linker32"
- #define GNU_USER_DYNAMIC_LINKERN32 \
-   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKERN32, UCLIBC_DYNAMIC_LINKERN32, \
-Index: gcc-4.8.4/gcc/config/rs6000/linux64.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/rs6000/linux64.h
-+++ gcc-4.8.4/gcc/config/rs6000/linux64.h
-@@ -366,14 +366,14 @@ extern int dot_symbols;
- #undef	LINK_OS_DEFAULT_SPEC
- #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)"
- 
--#define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1"
-+#define GLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld.so.1"
- #ifdef LINUX64_DEFAULT_ABI_ELFv2
- #define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv1:/lib64/ld64.so.1;:/lib64/ld64.so.2}"
- #else
- #define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv2:/lib64/ld64.so.2;:/lib64/ld64.so.1}"
- #endif
--#define UCLIBC_DYNAMIC_LINKER32 "/lib/ld-uClibc.so.0"
--#define UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0"
-+#define UCLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-uClibc.so.0"
-+#define UCLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld64-uClibc.so.0"
- #if DEFAULT_LIBC == LIBC_UCLIBC
- #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
- #elif DEFAULT_LIBC == LIBC_GLIBC
-Index: gcc-4.8.4/gcc/config/sh/linux.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/sh/linux.h
-+++ gcc-4.8.4/gcc/config/sh/linux.h
-@@ -43,7 +43,7 @@ along with GCC; see the file COPYING3.
- 
- #define TARGET_ASM_FILE_END file_end_indicate_exec_stack
- 
--#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
-+#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
- 
- #undef SUBTARGET_LINK_EMUL_SUFFIX
- #define SUBTARGET_LINK_EMUL_SUFFIX "_linux"
-Index: gcc-4.8.4/gcc/config/sparc/linux.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/sparc/linux.h
-+++ gcc-4.8.4/gcc/config/sparc/linux.h
-@@ -83,7 +83,7 @@ extern const char *host_detect_local_cpu
-    When the -shared link option is used a final link is not being
-    done.  */
- 
--#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
-+#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
- 
- #undef  LINK_SPEC
- #define LINK_SPEC "-m elf32_sparc %{shared:-shared} \
-Index: gcc-4.8.4/gcc/config/sparc/linux64.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/sparc/linux64.h
-+++ gcc-4.8.4/gcc/config/sparc/linux64.h
-@@ -92,8 +92,8 @@ along with GCC; see the file COPYING3.
-    When the -shared link option is used a final link is not being
-    done.  */
- 
--#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2"
--#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux.so.2"
-+#define GLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-linux.so.2"
-+#define GLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-linux.so.2"
- 
- #ifdef SPARC_BI_ARCH
- 
-Index: gcc-4.8.4/gcc/config/linux.h
-===================================================================
---- gcc-4.8.4.orig/gcc/config/linux.h
-+++ gcc-4.8.4/gcc/config/linux.h
-@@ -73,10 +73,10 @@ see the files COPYING3 and COPYING.RUNTI
-    GLIBC_DYNAMIC_LINKER must be defined for each target using them, or
-    GLIBC_DYNAMIC_LINKER32 and GLIBC_DYNAMIC_LINKER64 for targets
-    supporting both 32-bit and 64-bit compilation.  */
--#define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
--#define UCLIBC_DYNAMIC_LINKER32 "/lib/ld-uClibc.so.0"
--#define UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0"
--#define UCLIBC_DYNAMIC_LINKERX32 "/lib/ldx32-uClibc.so.0"
-+#define UCLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-uClibc.so.0"
-+#define UCLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-uClibc.so.0"
-+#define UCLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld64-uClibc.so.0"
-+#define UCLIBC_DYNAMIC_LINKERX32 SYSTEMLIBS_DIR "ldx32-uClibc.so.0"
- #define BIONIC_DYNAMIC_LINKER "/system/bin/linker"
- #define BIONIC_DYNAMIC_LINKER32 "/system/bin/linker"
- #define BIONIC_DYNAMIC_LINKER64 "/system/bin/linker64"
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0030-gcc-Fix-argument-list-too-long-error.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0030-gcc-Fix-argument-list-too-long-error.patch
deleted file mode 100644
index 2ceaff6..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0030-gcc-Fix-argument-list-too-long-error.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From c1816c160156f99c34e6a0a0311bb0219326804e Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:26:37 +0400
-Subject: [PATCH 30/35] gcc: Fix argument list too long error.
-
-There would be an "Argument list too long" error when the
-build directory is longer than 200, this is caused by:
-
-headers=`echo $(PLUGIN_HEADERS) | tr ' ' '\012' | sort -u`
-
-The PLUGIN_HEADERS is too long before sort, so the "echo" can't handle
-it, use the $(sort list) of GNU make which can handle the too long list
-would fix the problem, the header would be short enough after sorted.
-The "tr ' ' '\012'" was used for translating the space to "\n", the
-$(sort list) doesn't need this.
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- gcc/Makefile.in |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/gcc/Makefile.in b/gcc/Makefile.in
-index 2320497..8562a62 100644
---- a/gcc/Makefile.in
-+++ b/gcc/Makefile.in
-@@ -4627,7 +4627,7 @@ install-plugin: installdirs lang.install-plugin s-header-vars install-gengtype
- # We keep the directory structure for files in config or c-family and .def
- # files. All other files are flattened to a single directory.
- 	$(mkinstalldirs) $(DESTDIR)$(plugin_includedir)
--	headers=`echo $(PLUGIN_HEADERS) | tr ' ' '\012' | sort -u`; \
-+	headers="$(sort $(PLUGIN_HEADERS))"; \
- 	srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`; \
- 	for file in $$headers; do \
- 	  if [ -f $$file ] ; then \
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0032-libtool.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0032-libtool.patch
deleted file mode 100644
index 3b3d1b6..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0032-libtool.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 6c715fcfa262adadca81c68a1f3f69aa3187a501 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:29:11 +0400
-Subject: [PATCH 32/35] libtool
-
-libstdc++ from gcc-runtime gets created with -rpath=/usr/lib/../lib for qemux86-64
-when running on am x86_64 build host.
-
-This patch stops this speading to libdir in the libstdc++.la file within libtool.
-Arguably, it shouldn't be passing this into libtool in the first place but
-for now this resolves the nastiest problems this causes.
-
-func_normal_abspath would resolve an empty path to `pwd` so we need
-to filter the zero case.
-
-RP 2012/8/24
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- ltmain.sh |    4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/ltmain.sh b/ltmain.sh
-index a03433f..46f47c2 100644
---- a/ltmain.sh
-+++ b/ltmain.sh
-@@ -6359,6 +6359,10 @@ func_mode_link ()
- 	func_warning "ignoring multiple \`-rpath's for a libtool library"
- 
-       install_libdir="$1"
-+      if test -n "$install_libdir"; then
-+	func_normal_abspath "$install_libdir"
-+	install_libdir=$func_normal_abspath_result
-+      fi
- 
-       oldlibs=
-       if test -z "$rpath"; then
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0033-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0033-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
deleted file mode 100644
index 199984d..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0033-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 97e4591c20310425e7aca0e6712a8d9480e7744c Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:30:32 +0400
-Subject: [PATCH 33/35] gcc: armv4: pass fix-v4bx to linker to support EABI.
-
-The LINK_SPEC for linux gets overwritten by linux-eabi.h which
-means the value of TARGET_FIX_V4BX_SPEC gets lost and as a result
-the option is not passed to linker when chosing march=armv4
-This patch redefines this in linux-eabi.h and reinserts it
-for eabi defaulting toolchains.
-
-We might want to send it upstream.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Pending
----
- gcc/config/arm/linux-eabi.h |    6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/gcc/config/arm/linux-eabi.h b/gcc/config/arm/linux-eabi.h
-index 80f454d..4db3eb9 100644
---- a/gcc/config/arm/linux-eabi.h
-+++ b/gcc/config/arm/linux-eabi.h
-@@ -77,10 +77,14 @@
-     %{mfloat-abi=soft*:" GLIBC_DYNAMIC_LINKER_SOFT_FLOAT "} \
-     %{!mfloat-abi=*:" GLIBC_DYNAMIC_LINKER_DEFAULT "}"
- 
-+/* For armv4 we pass --fix-v4bx to linker to support EABI */
-+#undef TARGET_FIX_V4BX_SPEC
-+#define TARGET_FIX_V4BX_SPEC "%{mcpu=arm8|mcpu=arm810|mcpu=strongarm*|march=armv4: --fix-v4bx}"
-+
- /* At this point, bpabi.h will have clobbered LINK_SPEC.  We want to
-    use the GNU/Linux version, not the generic BPABI version.  */
- #undef  LINK_SPEC
--#define LINK_SPEC BE8_LINK_SPEC						\
-+#define LINK_SPEC BE8_LINK_SPEC TARGET_FIX_V4BX_SPEC			\
-   LINUX_OR_ANDROID_LD (LINUX_TARGET_LINK_SPEC,				\
- 		       LINUX_TARGET_LINK_SPEC " " ANDROID_LINK_SPEC)
- 
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0034-Use-the-multilib-config-files-from-B-instead-of-usin.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0034-Use-the-multilib-config-files-from-B-instead-of-usin.patch
deleted file mode 100644
index 66b9f89..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0034-Use-the-multilib-config-files-from-B-instead-of-usin.patch
+++ /dev/null
@@ -1,102 +0,0 @@
-From fc5e4beaea856a2b486c770ad3addc0f5bb3100e Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:33:04 +0400
-Subject: [PATCH 34/35] Use the multilib config files from ${B} instead of
- using the ones from ${S}
-
-Use the multilib config files from ${B} instead of using the ones from ${S}
-so that the source can be shared between gcc-cross-initial,
-gcc-cross-intermediate, gcc-cross, gcc-runtime, and also the sdk build.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Signed-off-by: Constantin Musca <constantinx.musca@intel.com>
-
-Upstream-Status: Inappropriate [configuration]
----
- gcc/configure    |   22 ++++++++++++++++++----
- gcc/configure.ac |   22 ++++++++++++++++++----
- 2 files changed, 36 insertions(+), 8 deletions(-)
-
-diff --git a/gcc/configure b/gcc/configure
-index 8bc0c98..3cd0817 100755
---- a/gcc/configure
-+++ b/gcc/configure
-@@ -11519,10 +11519,20 @@ done
- tmake_file_=
- for f in ${tmake_file}
- do
--	if test -f ${srcdir}/config/$f
--	then
--		tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
--	fi
-+  case $f in
-+    */t-linux64 )
-+       if test -f ./config/$f
-+       then
-+         tmake_file_="${tmake_file_} ./config/$f"
-+       fi
-+       ;;
-+    * )
-+       if test -f ${srcdir}/config/$f
-+       then
-+         tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
-+       fi
-+       ;;
-+  esac
- done
- tmake_file="${tmake_file_}"
- 
-@@ -11533,6 +11543,10 @@ tm_file_list="options.h"
- tm_include_list="options.h insn-constants.h"
- for f in $tm_file; do
-   case $f in
-+    */linux64.h )
-+       tm_file_list="${tm_file_list} ./config/$f"
-+       tm_include_list="${tm_include_list} ./config/$f"
-+       ;;
-     ./* )
-        f=`echo $f | sed 's/^..//'`
-        tm_file_list="${tm_file_list} $f"
-diff --git a/gcc/configure.ac b/gcc/configure.ac
-index 5e5e84f..415a6df 100644
---- a/gcc/configure.ac
-+++ b/gcc/configure.ac
-@@ -1700,10 +1700,20 @@ done
- tmake_file_=
- for f in ${tmake_file}
- do
--	if test -f ${srcdir}/config/$f
--	then
--		tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
--	fi
-+  case $f in
-+    */t-linux64 )
-+       if test -f ./config/$f
-+       then
-+         tmake_file_="${tmake_file_} ./config/$f"
-+       fi
-+       ;;
-+    * )
-+       if test -f ${srcdir}/config/$f
-+       then
-+         tmake_file_="${tmake_file_} \$(srcdir)/config/$f"
-+       fi
-+       ;;
-+  esac
- done
- tmake_file="${tmake_file_}"
- 
-@@ -1714,6 +1724,10 @@ tm_file_list="options.h"
- tm_include_list="options.h insn-constants.h"
- for f in $tm_file; do
-   case $f in
-+    */linux64.h )
-+       tm_file_list="${tm_file_list} ./config/$f"
-+       tm_include_list="${tm_include_list} ./config/$f"
-+       ;;
-     ./* )
-        f=`echo $f | sed 's/^..//'`
-        tm_file_list="${tm_file_list} $f"
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0035-wcast-qual-PR-55383.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0035-wcast-qual-PR-55383.patch
deleted file mode 100644
index be4cf4a..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0035-wcast-qual-PR-55383.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-From deffdb0b2497a106061d3ea2c6a3fef4fba3445e Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:39:51 +0400
-Subject: [PATCH 35/35] wcast-qual PR/55383
-
-This is a backport from gcc bugzilla
-
-http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55383
-
-This commit fixes a wrong warning behavior. This bug which has no
-workaround other than disabling the warning.
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Backport
----
- gcc/c/c-typeck.c                          |    2 +-
- gcc/testsuite/c-c++-common/Wcast-qual-1.c |    6 +++---
- 2 files changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/gcc/c/c-typeck.c b/gcc/c/c-typeck.c
-index ddb6d39..c624120 100644
---- a/gcc/c/c-typeck.c
-+++ b/gcc/c/c-typeck.c
-@@ -4464,7 +4464,7 @@ handle_warn_cast_qual (location_t loc, tree type, tree otype)
-     /* There are qualifiers present in IN_OTYPE that are not present
-        in IN_TYPE.  */
-     warning_at (loc, OPT_Wcast_qual,
--		"cast discards %q#v qualifier from pointer target type",
-+		"cast discards %qv qualifier from pointer target type",
- 		discarded);
- 
-   if (added || discarded)
-diff --git a/gcc/testsuite/c-c++-common/Wcast-qual-1.c b/gcc/testsuite/c-c++-common/Wcast-qual-1.c
-index 640e4f0..56382c7 100644
---- a/gcc/testsuite/c-c++-common/Wcast-qual-1.c
-+++ b/gcc/testsuite/c-c++-common/Wcast-qual-1.c
-@@ -85,11 +85,11 @@ f3 (void ***bar)
- void
- f4 (void * const **bar)
- {
--  const void ***p9 = (const void ***) bar; /* { dg-warning "cast" } */
-+  const void ***p9 = (const void ***) bar; /* { dg-warning "cast discards .const. qualifier" } */
-   void * const **p11 = (void * const **) bar;
--  void ** const *p13 = (void ** const *) bar; /* { dg-warning "cast" } */
-+  void ** const *p13 = (void ** const *) bar; /* { dg-warning "cast discards .const. qualifier" } */
-   const void * const **p15 = (const void * const **) bar; /* { dg-warning "cast" } */
--  const void ** const *p17 = (const void ** const *) bar; /* { dg-warning "cast" } */
-+  const void ** const *p17 = (const void ** const *) bar; /* { dg-warning "cast discards .const. qualifier" } */
-   void * const * const * p19 = (void * const * const *) bar;
-   const void * const * const *p21 = (const void * const * const *) bar;
- }
--- 
-1.7.10.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0038-gcc-4.8-build-args.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0038-gcc-4.8-build-args.patch
deleted file mode 100644
index 7c8290f..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0038-gcc-4.8-build-args.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-When cross compiling a target gcc, target flags may be used on the host
-
-Configure identifies a number of warning flags (WARN_CFLAGS and
-WARN_CXXFLAGS) from the $CC value.  The cross compiler may be different
-from the host compiler and may not support the same set of flags.  This
-leads to problems such as:
-
-cc1plus: error: unrecognized command line option "-Wno-narrowing"
-cc1plus: error: unrecognized command line option "-Wno-overlength-strings"
-
-Work around this problem by removing the warning flags from the
-BUILD_CXXFLAGS value, in a way similar to the BUILD_CFLAGS.
-
-Upstream-Status: Pending
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
-Index: gcc-4.8.4/gcc/configure
-===================================================================
---- gcc-4.8.4.orig/gcc/configure
-+++ gcc-4.8.4/gcc/configure
-@@ -17864,7 +17864,7 @@ else
-   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
-   lt_status=$lt_dlunknown
-   cat > conftest.$ac_ext <<_LT_EOF
--#line 17853 "configure"
-+#line 17867 "configure"
- #include "confdefs.h"
- 
- #if HAVE_DLFCN_H
-@@ -17970,7 +17970,7 @@ else
-   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
-   lt_status=$lt_dlunknown
-   cat > conftest.$ac_ext <<_LT_EOF
--#line 17959 "configure"
-+#line 17973 "configure"
- #include "confdefs.h"
- 
- #if HAVE_DLFCN_H
-@@ -26918,18 +26918,15 @@ $as_echo "#define TARGET_LIBC_PROVIDES_S
- fi
- 
- # Test for <sys/sdt.h> on the target.
--
--{ $as_echo "$as_me:${as_lineno-$LINENO}: checking sys/sdt.h in the target C library" >&5
--$as_echo_n "checking sys/sdt.h in the target C library... " >&6; }
--have_sys_sdt_h=no
-+#GCC_TARGET_TEMPLATE([HAVE_SYS_SDT_H])
-+#AC_MSG_CHECKING(sys/sdt.h in the target C library)
-+#have_sys_sdt_h=no
- #if test -f $target_header_dir/sys/sdt.h; then
- #  have_sys_sdt_h=yes
--#
--#$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
--#
-+#  AC_DEFINE(HAVE_SYS_SDT_H, 1,
-+#            [Define if your target C library provides sys/sdt.h])
- #fi
--{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_sys_sdt_h" >&5
--$as_echo "$have_sys_sdt_h" >&6; }
-+#AC_MSG_RESULT($have_sys_sdt_h)
- 
- # Check if TFmode long double should be used by default or not.
- # Some glibc targets used DFmode long double, but with glibc 2.4
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0040-fix-g++-sysroot.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0040-fix-g++-sysroot.patch
deleted file mode 100644
index d50aa5c..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0040-fix-g++-sysroot.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-Portions of
-
-http://www.mail-archive.com/gcc-patches@gcc.gnu.org/msg26013.html
-
-are not upstreamed yet. So lets keep missing pieces.
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Index: gcc-4.8.1/gcc/configure.ac
-===================================================================
---- gcc-4.8.1.orig/gcc/configure.ac	2013-07-15 15:55:49.488399132 -0700
-+++ gcc-4.8.1/gcc/configure.ac	2013-07-15 16:02:31.772406679 -0700
-@@ -148,7 +148,9 @@
- if test "${with_sysroot+set}" = set; then
-   gcc_gxx_without_sysroot=`expr "${gcc_gxx_include_dir}" : "${with_sysroot}"'\(.*\)'`
-   if test "${gcc_gxx_without_sysroot}"; then
--    gcc_gxx_include_dir="${gcc_gxx_without_sysroot}"
-+    if test x${with_sysroot} != x/; then
-+      gcc_gxx_include_dir="${gcc_gxx_without_sysroot}"
-+    fi
-     gcc_gxx_include_dir_add_sysroot=1
-   fi
- fi
-Index: gcc-4.8.1/gcc/configure
-===================================================================
---- gcc-4.8.1.orig/gcc/configure	2013-07-15 15:55:49.472399132 -0700
-+++ gcc-4.8.1/gcc/configure	2013-07-15 16:02:31.780406680 -0700
-@@ -3325,7 +3325,9 @@
- if test "${with_sysroot+set}" = set; then
-   gcc_gxx_without_sysroot=`expr "${gcc_gxx_include_dir}" : "${with_sysroot}"'\(.*\)'`
-   if test "${gcc_gxx_without_sysroot}"; then
--    gcc_gxx_include_dir="${gcc_gxx_without_sysroot}"
-+    if test x${with_sysroot} != x/; then
-+      gcc_gxx_include_dir="${gcc_gxx_without_sysroot}"
-+    fi
-     gcc_gxx_include_dir_add_sysroot=1
-   fi
- fi
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0041-libtool-avoid-libdir.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0041-libtool-avoid-libdir.patch
deleted file mode 100644
index 2dd9610..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0041-libtool-avoid-libdir.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-Avoid using libdir from .la which usually points to a host path
-
-Upstream-Status: Inappropriate [embedded specific]
-Signed-off-by: Jonathan Liu <net147@gmail.com>
-
-diff --git a/ltmain.sh b/ltmain.sh
-index a03433f..1902a90 100644
---- a/ltmain.sh
-+++ b/ltmain.sh
-@@ -5628,6 +5628,9 @@ func_mode_link ()
- 	    absdir="$abs_ladir"
- 	    libdir="$abs_ladir"
- 	  else
-+	    # Instead of using libdir from .la which usually points to a host path,
-+	    # use the path the .la is contained in.
-+	    libdir="$abs_ladir"
- 	    dir="$libdir"
- 	    absdir="$libdir"
- 	  fi
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0042-pr57748.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0042-pr57748.patch
deleted file mode 100644
index 5356f72..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0042-pr57748.patch
+++ /dev/null
@@ -1,78 +0,0 @@
-Upstream-Status: Backport
-Signed-off-by: Khem Raj
-
-2013-08-01  Martin Jambor  <mjambor@suse.cz>
-
-	PR middle-end/57748
-	* stor-layout.c (compute_record_mode): Treat zero-sized array fields
-	like incomplete types.
-
-testsuite/
-	* gcc.dg/torture/pr57748.c: New test.
-
-
-Index: gcc-4.8.1/gcc/stor-layout.c
-===================================================================
---- gcc-4.8.1.orig/gcc/stor-layout.c	2013-04-28 10:29:18.000000000 -0700
-+++ gcc-4.8.1/gcc/stor-layout.c	2013-08-01 15:02:08.018006125 -0700
-@@ -1618,7 +1618,9 @@
- 		   && integer_zerop (TYPE_SIZE (TREE_TYPE (field)))))
- 	  || ! host_integerp (bit_position (field), 1)
- 	  || DECL_SIZE (field) == 0
--	  || ! host_integerp (DECL_SIZE (field), 1))
-+	  || ! host_integerp (DECL_SIZE (field), 1)
-+	  || (TREE_CODE (TREE_TYPE (field)) == ARRAY_TYPE
-+	      && tree_low_cst (DECL_SIZE (field), 1) == 0))
- 	return;
- 
-       /* If this field is the whole struct, remember its mode so
-Index: gcc-4.8.1/gcc/testsuite/gcc.dg/torture/pr57748.c
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ gcc-4.8.1/gcc/testsuite/gcc.dg/torture/pr57748.c	2013-08-01 15:02:08.062006126 -0700
-@@ -0,0 +1,45 @@
-+/* PR middle-end/57748 */
-+/* { dg-do run } */
-+
-+#include <stdlib.h>
-+
-+extern void abort (void);
-+
-+typedef long long V
-+  __attribute__ ((vector_size (2 * sizeof (long long)), may_alias));
-+
-+typedef struct S { V a; V b[0]; } P __attribute__((aligned (1)));
-+
-+struct __attribute__((packed)) T { char c; P s; };
-+
-+void __attribute__((noinline, noclone))
-+check (struct T *t)
-+{
-+  if (t->s.b[0][0] != 3 || t->s.b[0][1] != 4)
-+    abort ();
-+}
-+
-+int __attribute__((noinline, noclone))
-+get_i (void)
-+{
-+  return 0;
-+}
-+
-+void __attribute__((noinline, noclone))
-+foo (P *p)
-+{
-+  V a = { 3, 4 };
-+  int i = get_i();
-+  p->b[i] = a;
-+}
-+
-+int
-+main ()
-+{
-+  struct T *t = (struct T *) malloc (128);
-+
-+  foo (&t->s);
-+  check (t);
-+
-+  return 0;
-+}
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0043-cpp.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0043-cpp.patch
deleted file mode 100644
index eaf8646..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0043-cpp.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-The OE environment sets and exports CPP as being the target gcc. When building 
-gcc-cross-canadian for a mingw targetted sdk, the following can be found in
-build.x86_64-pokysdk-mingw32.i586-poky-linux/build-x86_64-linux/libiberty/config.log:
-
-configure:3641: checking for _FILE_OFFSET_BITS value needed for large files
-configure:3666: gcc  -c -isystem/media/build1/poky/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe  conftest.c >&5
-configure:3666: $? = 0
-configure:3698: result: no
-configure:3786: checking how to run the C preprocessor
-configure:3856: result: x86_64-pokysdk-mingw32-gcc -E --sysroot=/media/build1/poky/build/tmp/sysroots/x86_64-nativesdk-mingw32-pokysdk-mingw32
-configure:3876: x86_64-pokysdk-mingw32-gcc -E --sysroot=/media/build1/poky/build/tmp/sysroots/x86_64-nativesdk-mingw32-pokysdk-mingw32  conftest.c
-configure:3876: $? = 0
-
-Note this is a *build* target (in build-x86_64-linux) so it should be using 
-the host "gcc", not x86_64-pokysdk-mingw32-gcc. Since the mingw32 headers are 
-very different, using the wrong cpp is a real problem. It is leaking into 
-configure through the CPP variable. Ultimately this leads to build failures 
-related to not being able to include a process.h file for pem-unix.c.
-
-The fix is to ensure we export a sane CPP value into the build environment when
-using build targets. We could define a CPP_FOR_BUILD value which may be the version
-which needs to be upstreamed but for now, this fix is good enough to avoid the 
-problem.
-
-RP 22/08/2013
-
-Upstream-Status: Pending
-
-Index: gcc-4.8.1/Makefile.in
-===================================================================
---- gcc-4.8.1.orig/Makefile.in	2013-03-30 11:25:03.000000000 +0000
-+++ gcc-4.8.1/Makefile.in	2013-08-13 12:03:17.151988882 +0000
-@@ -149,6 +149,7 @@
- 	AR="$(AR_FOR_BUILD)"; export AR; \
- 	AS="$(AS_FOR_BUILD)"; export AS; \
- 	CC="$(CC_FOR_BUILD)"; export CC; \
-+	CPP="$(CC_FOR_BUILD) -E"; export CPP; \
- 	CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
- 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
- 	CXX="$(CXX_FOR_BUILD)"; export CXX; \
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0044-gengtypes.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0044-gengtypes.patch
deleted file mode 100644
index e38761d..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0044-gengtypes.patch
+++ /dev/null
@@ -1,97 +0,0 @@
-gengtype is generated for both the build system and the target. -DGENERATOR_FILE
-was added in the patch http://gcc.gnu.org/ml/gcc-patches/2012-07/msg00273.html
-and was applied to both versions of gengtype.
-
-Unfortunately the presence of this flag triggers the build configuration (bconfig.h) 
-to be included for the target build of gengtype. Compiling gengtype with the target 
-compiler and bconfig.h can result in errors if the build and target systems are 
-dissimilar. An example case this fails is cross compiling gcc on linux for a darwin 
-target system:
-
-In file included from /media/build1/poky/build/tmp/work-shared/gcc-4.8.1-r0/gcc-4.8.1/gcc/gengtype-parse.c:25:0:
-| /media/build1/poky/build/tmp/work-shared/gcc-4.8.1-r0/gcc-4.8.1/gcc/gengtype-parse.c: In function 'void parse_error(const char*, ...)':
-| /media/build1/poky/build/tmp/work-shared/gcc-4.8.1-r0/gcc-4.8.1/gcc/system.h:93:53: error: 'fputc_unlocked' was not declared in this scope
-|  #  define fputc(C, Stream) fputc_unlocked (C, Stream)
-
-which occurs since auto-build.h and auto-host.h have differnet values of
-HAVE_FPUTC_UNLOCKED:
-
-#define HAVE_FPUTC_UNLOCKED 1
-/* #undef HAVE_FPUTS_UNLOCKED */
-
-The obvious fix is to only include the flag on build/ targets which this patch does, however 
-this also leads to compile errors due to const_tree being undefined but used in double_int.h
-
-I added a GENERATOR_FILE2 flag to workaround those in the 
-target case and allow the build to succeed.
-
-Only the build/gengtypes should have the -DGENERATOR_FILE 
-
-RP 22/8/2013
-
-Upstream-Status: Pending
-
-Index: gcc-4.8.1/gcc/Makefile.in
-===================================================================
---- gcc-4.8.1.orig/gcc/Makefile.in	2013-08-19 11:40:36.844014424 +0000
-+++ gcc-4.8.1/gcc/Makefile.in	2013-08-19 11:40:37.784014402 +0000
-@@ -3903,27 +3903,29 @@
- 
- gengtype-lex.o build/gengtype-lex.o : gengtype-lex.c gengtype.h $(SYSTEM_H)
- gengtype-lex.o: $(CONFIG_H) $(BCONFIG_H)
--CFLAGS-gengtype-lex.o += -DGENERATOR_FILE
-+CFLAGS-build/gengtype-lex.o += -DGENERATOR_FILE
- build/gengtype-lex.o: $(BCONFIG_H)
- 
- gengtype-parse.o build/gengtype-parse.o : gengtype-parse.c gengtype.h \
-   $(SYSTEM_H)
- gengtype-parse.o: $(CONFIG_H)
--CFLAGS-gengtype-parse.o += -DGENERATOR_FILE
-+CFLAGS-build/gengtype-parse.o += -DGENERATOR_FILE
- build/gengtype-parse.o: $(BCONFIG_H)
- 
- gengtype-state.o build/gengtype-state.o: gengtype-state.c $(SYSTEM_H) \
-   gengtype.h errors.h double-int.h version.h $(HASHTAB_H) $(OBSTACK_H) \
-   $(XREGEX_H)
- gengtype-state.o: $(CONFIG_H)
--CFLAGS-gengtype-state.o += -DGENERATOR_FILE
-+CFLAGS-gengtype-state.o += -DGENERATOR_FILE2
-+CFLAGS-build/gengtype-state.o += -DGENERATOR_FILE
- build/gengtype-state.o: $(BCONFIG_H)
- 
- gengtype.o build/gengtype.o : gengtype.c $(SYSTEM_H) gengtype.h 	\
-   rtl.def insn-notes.def errors.h double-int.h version.h $(HASHTAB_H) \
-   $(OBSTACK_H) $(XREGEX_H)
- gengtype.o: $(CONFIG_H)
--CFLAGS-gengtype.o += -DGENERATOR_FILE
-+CFLAGS-gengtype.o += -DGENERATOR_FILE2
-+CFLAGS-build/gengtype.o += -DGENERATOR_FILE
- build/gengtype.o: $(BCONFIG_H)
- 
- build/genmddeps.o: genmddeps.c $(BCONFIG_H) $(SYSTEM_H) coretypes.h	\
-@@ -3988,7 +3990,7 @@
- # any system header is included.
- gengtype-lex.c : gengtype-lex.l
- 	-$(FLEX) $(FLEXFLAGS) -o$@ $< && { \
--	  echo '#include "bconfig.h"' > $@.tmp; \
-+	  echo '' > $@.tmp; \
- 	  cat $@ >> $@.tmp; \
- 	  mv $@.tmp $@; \
- 	}
-Index: gcc-4.8.1/gcc/double-int.h
-===================================================================
---- gcc-4.8.1.orig/gcc/double-int.h	2013-01-30 11:04:30.000000000 +0000
-+++ gcc-4.8.1/gcc/double-int.h	2013-08-19 11:41:51.564012719 +0000
-@@ -448,10 +448,12 @@
- 
- 
- #ifndef GENERATOR_FILE
-+#ifndef GENERATOR_FILE2
- /* Conversion to and from GMP integer representations.  */
- 
- void mpz_set_double_int (mpz_t, double_int, bool);
- double_int mpz_get_double_int (const_tree, mpz_t, bool);
- #endif
-+#endif
- 
- #endif /* DOUBLE_INT_H */
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0046-libatomic-deptracking.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0046-libatomic-deptracking.patch
deleted file mode 100644
index 6ea4f42..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0046-libatomic-deptracking.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-gcc 4.8 won't build with --disable-dependency-tracking since the *.Ppo files
-don't get created unless --enable-dependency-tracking is true.
-
-This patch ensures we only use those compiler options when its enabled.
-
-Upstream-Status: Submitted
-
-(Problem was already reported upstream, attached this patch there
-http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55930)
-
-RP 
-2012/09/22
-
-Index: gcc-4.8.1/libatomic/Makefile.am
-===================================================================
---- gcc-4.8.1.orig/libatomic/Makefile.am	2013-01-14 18:16:23.000000000 +0000
-+++ gcc-4.8.1/libatomic/Makefile.am	2013-09-22 10:38:18.904064750 +0000
-@@ -100,7 +100,8 @@
- IFUNC_DEF	= -DIFUNC_ALT=$(PAT_S)
- IFUNC_OPT	= $(word $(PAT_S),$(IFUNC_OPTIONS))
- 
--M_DEPS		= -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
-+@AMDEP_TRUE@M_DEPS		= -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
-+@AMDEP_FALSE@M_DEPS		= 
- M_SIZE		= -DN=$(PAT_N)
- M_IFUNC		= $(if $(PAT_S),$(IFUNC_DEF) $(IFUNC_OPT))
- M_FILE		= $(PAT_BASE)_n.c
-Index: gcc-4.8.1/libatomic/Makefile.in
-===================================================================
---- gcc-4.8.1.orig/libatomic/Makefile.in	2013-05-31 09:09:26.000000000 +0000
-+++ gcc-4.8.1/libatomic/Makefile.in	2013-09-22 10:40:42.520059917 +0000
-@@ -298,7 +298,8 @@
- PAT_S = $(word 3,$(PAT_SPLIT))
- IFUNC_DEF = -DIFUNC_ALT=$(PAT_S)
- IFUNC_OPT = $(word $(PAT_S),$(IFUNC_OPTIONS))
--M_DEPS = -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
-+@AMDEP_TRUE@M_DEPS = -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
-+@AMDEP_FALSE@M_DEPS = 
- M_SIZE = -DN=$(PAT_N)
- M_IFUNC = $(if $(PAT_S),$(IFUNC_DEF) $(IFUNC_OPT))
- M_FILE = $(PAT_BASE)_n.c
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0047-repomembug.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0047-repomembug.patch
deleted file mode 100644
index 9afd55c..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0047-repomembug.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-When compiling a project using -frepo, .rpo files are written alongside
-the .o file, the symbols either have O or C against them. During final linking,
-the objects can be recompiled with some of the entries tweaked/chosen by the 
-tlink.c code (visible with TLINK_VERBOSE=3), it does this by changing O -> C
-in the .rpo files.
-
-My tests showed that init_repo (cp/repo.c) was correctly calling 
-IDENTIFIER_REPO_CHOSEN against the right identifers and setting the
-chosen bit.
-
-By the time finish_repo() or emit_repo_p() were called, the pointer returned
-by get_identifier() for the symbol marked during init_repo had changed and
-the chosen bit was no longer set. This lead to linking bugs like:
-
-collect: relinking
-collect2: error: '_ZNK6sudoku5ClearINS_8SequenceEEclERS1_' was assigned to 'board.rpo', but was not defined during recompilation, or vice versa
-
-The problem is that the garbage collection is getting called before
-finish_repo() is called and ggc_protect_identifiers is set to false 
-so the identifiers are not preserved. They are recreated but the 
-chosen bits get wiped out which is why the pointer changes and the 
-chosen bit is not set.
-
-The fix is to change ggc_protect_identifiers *after* the finish_repo 
-calls are made.
-
-Reproduction is tricky since you need to trigger the garbage collector at
-just the right moment.
-
-RP 2013/10/9
-
-[YOCTO #5133]
-
-Upstream-Status: Pending
-
-Index: gcc-4.8.1/gcc/toplev.c
-===================================================================
---- gcc-4.8.1.orig/gcc/toplev.c	2013-03-28 08:29:51.000000000 +0000
-+++ gcc-4.8.1/gcc/toplev.c	2013-10-09 20:27:17.089228023 +0000
-@@ -551,11 +551,11 @@
-   if (flag_syntax_only || flag_wpa)
-     return;
- 
--  ggc_protect_identifiers = false;
--
-   /* This must also call finalize_compilation_unit.  */
-   lang_hooks.decls.final_write_globals ();
- 
-+  ggc_protect_identifiers = false;
-+
-   if (seen_error ())
-     return;
- 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch
deleted file mode 100644
index b98f8ff..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 9e0e19eac2562f73858602fe26e2044eb8b20c47 Mon Sep 17 00:00:00 2001
-From: Alexandru-Cezar Sardan <alexandru.sardan@freescale.com>
-Date: Wed, 5 Feb 2014 16:52:31 +0200
-Subject: [PATCH] Enable SPE & AltiVec generation on powepc*linux target
-
-When is configured with --target=powerpc-linux, the resulting GCC will 
-not be able to generate code for SPE targets (e500v1/v2).
-GCC configured with --target=powerpc-linuxspe will not be able to
-generate AltiVec instructions (for e6500).
-This patch modifies the configured file such that SPE or AltiVec code
-can be generated when gcc is configured with --target=powerpc-linux.
-The ABI and speciffic instructions can be selected through the
-"-mabi=spe or -mabi=altivec" and the "-mspe or -maltivec" parameters.
-
-Upstream-Status: Inappropriate [configuration]
-
-Signed-off-by: Alexandru-Cezar Sardan <alexandru.sardan@freescale.com>
----
- gcc/config.gcc |    7 ++++++-
- 1 file changed, 6 insertions(+), 1 deletion(-)
-
-diff --git a/gcc/config.gcc b/gcc/config.gcc
-index cb7a94e..d392c2b 100644
---- a/gcc/config.gcc
-+++ b/gcc/config.gcc
-@@ -2068,7 +2068,12 @@ powerpc-*-rtems*)
- 	tmake_file="rs6000/t-fprules rs6000/t-rtems t-rtems rs6000/t-ppccomm"
- 	;;
- powerpc*-*-linux*)
--	tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h rs6000/sysv4.h"
-+	case ${target} in
-+	    powerpc*-*-linux*spe* | powerpc*-*-linux*altivec*)
-+		tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h rs6000/sysv4.h" ;;
-+	    *)
-+		tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h rs6000/sysv4.h rs6000/linuxaltivec.h rs6000/linuxspe.h rs6000/e500.h" ;;
-+	esac
- 	extra_options="${extra_options} rs6000/sysv4.opt"
- 	tmake_file="rs6000/t-fprules rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm"
- 	case ${target} in
--- 
-1.7.9.5
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0051-gcc-483-universal-initializer-no-warning.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0051-gcc-483-universal-initializer-no-warning.patch
deleted file mode 100644
index fde227b..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0051-gcc-483-universal-initializer-no-warning.patch
+++ /dev/null
@@ -1,107 +0,0 @@
-Upstream-Status: Backport
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
----
-Fix for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53119
-wrong warning when using the universal zero initializer {0}
-
-Backported to GCC 4.8.3
-
-Subject: 2014-06-05  S. Gilles  <sgilles@terpmail.umd.edu>
-X-Git-Url: http://repo.or.cz/w/official-gcc.git/commitdiff_plain/95cdf3fdf2d440eb7775def8e35ab970651c33d9?hp=14a3093e9943937cbc63dfbf4d51ca60f8325b29
-git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@211289 138bc75d-0d04-0410-961f-82ee72b054a4
-
---- gcc-4.8.3.org/gcc/c/c-typeck.c	2014-08-03 20:52:09.257042137 +0200
-+++ gcc-4.8.3/gcc/c/c-typeck.c	2014-08-03 20:57:10.645042614 +0200
-@@ -62,9 +62,9 @@
-    if expr.original_code == SIZEOF_EXPR.  */
- tree c_last_sizeof_arg;
- 
--/* Nonzero if we've already printed a "missing braces around initializer"
--   message within this initializer.  */
--static int missing_braces_mentioned;
-+/* Nonzero if we might need to print a "missing braces around
-+   initializer" message within this initializer.  */
-+static int found_missing_braces;
- 
- static int require_constant_value;
- static int require_constant_elements;
-@@ -6379,6 +6379,9 @@
- /* 1 if this constructor is erroneous so far.  */
- static int constructor_erroneous;
- 
-+/* 1 if this constructor is the universal zero initializer { 0 }.  */
-+static int constructor_zeroinit;
-+
- /* Structure for managing pending initializer elements, organized as an
-    AVL tree.  */
- 
-@@ -6540,7 +6543,7 @@
-   constructor_stack = 0;
-   constructor_range_stack = 0;
- 
--  missing_braces_mentioned = 0;
-+  found_missing_braces = 0;
- 
-   spelling_base = 0;
-   spelling_size = 0;
-@@ -6635,6 +6638,7 @@
-   constructor_type = type;
-   constructor_incremental = 1;
-   constructor_designated = 0;
-+  constructor_zeroinit = 1;
-   designator_depth = 0;
-   designator_erroneous = 0;
- 
-@@ -6832,11 +6836,8 @@
- 	set_nonincremental_init (braced_init_obstack);
-     }
- 
--  if (implicit == 1 && warn_missing_braces && !missing_braces_mentioned)
--    {
--      missing_braces_mentioned = 1;
--      warning_init (OPT_Wmissing_braces, "missing braces around initializer");
--    }
-+  if (implicit == 1)
-+    found_missing_braces = 1;
- 
-   if (TREE_CODE (constructor_type) == RECORD_TYPE
- 	   || TREE_CODE (constructor_type) == UNION_TYPE)
-@@ -6969,16 +6970,23 @@
- 	}
-     }
- 
-+  if (vec_safe_length (constructor_elements) != 1)
-+    constructor_zeroinit = 0;
-+
-+  /* Warn when some structs are initialized with direct aggregation.  */
-+  if (!implicit && found_missing_braces && warn_missing_braces
-+      && !constructor_zeroinit)
-+    {
-+      warning_init (OPT_Wmissing_braces,
-+		    "missing braces around initializer");
-+    }
-+
-   /* Warn when some struct elements are implicitly initialized to zero.  */
-   if (warn_missing_field_initializers
-       && constructor_type
-       && TREE_CODE (constructor_type) == RECORD_TYPE
-       && constructor_unfilled_fields)
-     {
--	bool constructor_zeroinit =
--	 (vec_safe_length (constructor_elements) == 1
--	  && integer_zerop ((*constructor_elements)[0].value));
--
- 	/* Do not warn for flexible array members or zero-length arrays.  */
- 	while (constructor_unfilled_fields
- 	       && (!DECL_SIZE (constructor_unfilled_fields)
-@@ -8093,6 +8101,9 @@
-   designator_depth = 0;
-   designator_erroneous = 0;
- 
-+  if (!implicit && value.value && !integer_zerop (value.value))
-+    constructor_zeroinit = 0;
-+
-   /* Handle superfluous braces around string cst as in
-      char x[] = {"foo"}; */
-   if (string_flag
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/target-gcc-includedir.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/target-gcc-includedir.patch
deleted file mode 100644
index f48c66d..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/target-gcc-includedir.patch
+++ /dev/null
@@ -1,81 +0,0 @@
-Ensure target gcc headers can be included
-
-There are a few headers installed as part of the OpenEmbedded
-gcc-runtime target (omp.h, ssp/*.h). Being installed from a recipe
-built for the target architecture, these are within the target
-sysroot and not cross/nativesdk; thus they weren't able to be
-found by gcc with the existing search paths. Add support for
-picking up these headers under the sysroot supplied on the gcc
-command line in order to resolve this.
-
-Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
-
-Upstream-Status: Pending
-
---- a/gcc/Makefile.in	2014-12-23 11:57:33.327873331 +0000
-+++ b/gcc/Makefile.in	2015-01-21 11:32:35.447305394 +0000
-@@ -587,6 +587,7 @@
- 
- # Directory in which the compiler finds libraries etc.
- libsubdir = $(libdir)/gcc/$(target_noncanonical)/$(version)
-+libsubdir_target = gcc/$(target_noncanonical)/$(version)
- # Directory in which the compiler finds executables
- libexecsubdir = $(libexecdir)/gcc/$(target_noncanonical)/$(version)
- # Directory in which all plugin resources are installed
-@@ -2534,6 +2535,7 @@
- 
- PREPROCESSOR_DEFINES = \
-   -DGCC_INCLUDE_DIR=\"$(libsubdir)/include\" \
-+  -DGCC_INCLUDE_SUBDIR_TARGET=\"$(libsubdir_target)/include\" \
-   -DFIXED_INCLUDE_DIR=\"$(libsubdir)/include-fixed\" \
-   -DGPLUSPLUS_INCLUDE_DIR=\"$(gcc_gxx_include_dir)\" \
-   -DGPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT=$(gcc_gxx_include_dir_add_sysroot) \
---- a/gcc/cppdefault.c	2015-01-13 17:40:26.131012725 +0000
-+++ b/gcc/cppdefault.c	2015-01-21 11:30:08.928426492 +0000
-@@ -59,6 +59,10 @@
-     /* This is the dir for gcc's private headers.  */
-     { GCC_INCLUDE_DIR, "GCC", 0, 0, 0, 0 },
- #endif
-+#ifdef GCC_INCLUDE_SUBDIR_TARGET
-+    /* This is the dir for gcc's private headers under the specified sysroot.  */
-+    { STANDARD_STARTFILE_PREFIX_2 GCC_INCLUDE_SUBDIR_TARGET, "GCC", 0, 0, 1, 0 },
-+#endif
- #ifdef LOCAL_INCLUDE_DIR
-     /* /usr/local/include comes before the fixincluded header files.  */
-     { LOCAL_INCLUDE_DIR, 0, 0, 1, 1, 2 },
-diff --git a/gcc/defaults.h b/gcc/defaults.h
-index f94ae17..d98b40b 100644
---- a/gcc/defaults.h
-+++ b/gcc/defaults.h
-@@ -1390,4 +1390,13 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
- 
- #endif /* GCC_INSN_FLAGS_H  */
- 
-+/* Default prefixes to attach to command names.  */
-+
-+#ifndef STANDARD_STARTFILE_PREFIX_1
-+#define STANDARD_STARTFILE_PREFIX_1 "/lib/"
-+#endif
-+#ifndef STANDARD_STARTFILE_PREFIX_2
-+#define STANDARD_STARTFILE_PREFIX_2 "/usr/lib/"
-+#endif
-+
- #endif  /* ! GCC_DEFAULTS_H */
-diff --git a/gcc/gcc.c b/gcc/gcc.c
-index 9f0b781..174fca8 100644
---- a/gcc/gcc.c
-+++ b/gcc/gcc.c
-@@ -1189,13 +1189,6 @@ static const char *gcc_libexec_prefix;
- 
- /* Default prefixes to attach to command names.  */
- 
--#ifndef STANDARD_STARTFILE_PREFIX_1
--#define STANDARD_STARTFILE_PREFIX_1 "/lib/"
--#endif
--#ifndef STANDARD_STARTFILE_PREFIX_2
--#define STANDARD_STARTFILE_PREFIX_2 "/usr/lib/"
--#endif
--
- #ifdef CROSS_DIRECTORY_STRUCTURE  /* Don't use these prefixes for a cross compiler.  */
- #undef MD_EXEC_PREFIX
- #undef MD_STARTFILE_PREFIX
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9.inc
index 95b553c..7e03f31 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9.inc
@@ -47,7 +47,6 @@
     file://0021-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch \
     file://0022-COLLECT_GCC_OPTIONS.patch \
     file://0023-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch \
-    file://0024-PR-target-32219.patch \
     file://0025-fortran-cross-compile-hack.patch \
     file://0026-libgcc-sjlj-check.patch \
     file://0027-cpp-honor-sysroot.patch \
@@ -81,10 +80,22 @@
     file://0063-nativesdk-gcc-support.patch \
     file://0064-handle-target-sysroot-multilib.patch \
     file://0065-gcc-483-universal-initializer-no-warning.patch \
+    file://0066-cxxflags-for-build.patch \
+    file://0067-fix-arm-thumb.patch \
+    file://0067-gcc-musl-support.patch \
+    file://0068-musl-dynamic-linker.patch \
+    file://0069-musl-no-fixincludes.patch \
+    file://0070-libstdc-musl.patch \
+    file://0071-Ignore-fdebug-prefix-map-in-producer-string-by-Danie.patch \
+    file://0072-support-ffile-prefix-map.patch \
+    file://0073-Reuse-fdebug-prefix-map-to-replace-ffile-prefix-map.patch \
+    file://0074-fdebug-prefix-map-support-to-remap-relative-path.patch \
 "
 SRC_URI[md5sum] = "6f831b4d251872736e8e9cc09746f327"
 SRC_URI[sha256sum] = "2332b2a5a321b57508b9031354a8503af6fdfb868b8c1748d33028d100a8b67e"
 
+UPSTREAM_CHECK_REGEX = "gcc-(?P<pver>4\.9\.\d+).tar"
+
 S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/gcc-${PV}"
 B = "${WORKDIR}/gcc-${PV}/build.${HOST_SYS}.${TARGET_SYS}"
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0024-PR-target-32219.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0024-PR-target-32219.patch
deleted file mode 100644
index 45acf7f..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0024-PR-target-32219.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From e0d15f4f8bf28c351b9215ca37f1caa24df0e1fd Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:18:54 +0400
-Subject: [PATCH 24/35] PR target/32219
-
-* varasm.c (default_binds_local_p_1): Weak data is not local.
-
-Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Upstream-Status: Backport
----
- gcc/testsuite/gcc.dg/visibility-21.c |   14 ++++++++++++++
- gcc/varasm.c                         |    9 ++++-----
- 2 files changed, 18 insertions(+), 5 deletions(-)
- create mode 100644 gcc/testsuite/gcc.dg/visibility-21.c
-
-Index: gcc-4.9-20140316/gcc/varasm.c
-===================================================================
---- gcc-4.9-20140316.orig/gcc/varasm.c
-+++ gcc-4.9-20140316/gcc/varasm.c
-@@ -6771,6 +6771,10 @@ default_binds_local_p_1 (const_tree exp,
-   /* Static variables are always local.  */
-   else if (! TREE_PUBLIC (exp))
-     local_p = true;
-+  /* hidden weak can't be overridden by something non-local, all
-+     that is possible is that it is not defined at all. */
-+  else if (DECL_WEAK (exp))
-+    local_p = false;
-   /* A variable is local if the user has said explicitly that it will
-      be.  */
-   else if ((DECL_VISIBILITY_SPECIFIED (exp)
-@@ -6784,11 +6788,6 @@ default_binds_local_p_1 (const_tree exp,
-      local.  */
-   else if (DECL_VISIBILITY (exp) != VISIBILITY_DEFAULT)
-     local_p = true;
--  /* Default visibility weak data can be overridden by a strong symbol
--     in another module and so are not local.  */
--  else if (DECL_WEAK (exp)
--	   && !resolved_locally)
--    local_p = false;
-   /* If PIC, then assume that any global name can be overridden by
-      symbols resolved from other modules.  */
-   else if (shlib)
-Index: gcc-4.9-20140316/gcc/testsuite/gcc.dg/visibility-22.c
-===================================================================
---- /dev/null
-+++ gcc-4.9-20140316/gcc/testsuite/gcc.dg/visibility-22.c
-@@ -0,0 +1,13 @@
-+/* PR target/32219 */
-+/* { dg-do run } */
-+/* { dg-require-visibility "" } */
-+/* { dg-options "-fPIC" { target fpic } } */
-+
-+extern void f() __attribute__((weak,visibility("hidden")));
-+extern int puts( char const* );
-+int main()
-+{
-+  if (f)
-+    f();
-+  return 0;
-+}
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0042-cxxflags-for-build.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0066-cxxflags-for-build.patch
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0042-cxxflags-for-build.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0066-cxxflags-for-build.patch
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0067-fix-arm-thumb.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0067-fix-arm-thumb.patch
new file mode 100644
index 0000000..2f262e3
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0067-fix-arm-thumb.patch
@@ -0,0 +1,39 @@
+Upstream-Status: Accepted
+
+Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
+---
+
+2015-11-25  Vladimir Makarov  <vmakarov@redhat.com>
+
+	PR rtl-optimization/67954
+	* lra-constraints.c (curr_insn_transform): Add check on scratch
+	pseudo when change class to NO_REGS.  Add an assert.
+
+
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@230894 138bc75d-0d04-0410-961f-82ee72b054a4
+---
+
+diff --git a/gcc/lra-constraints.c b/gcc/lra-constraints.c
+index 4670e81..c62bf6a 100644
+--- a/gcc/lra-constraints.c
++++ b/gcc/lra-constraints.c
+@@ -3725,7 +3725,8 @@ curr_insn_transform (bool check_only_p)
+ 		 assigment pass and the scratch pseudo will be
+ 		 spilled.  Spilled scratch pseudos are transformed
+ 		 back to scratches at the LRA end.  */
+-	      && lra_former_scratch_operand_p (curr_insn, i))
++	      && lra_former_scratch_operand_p (curr_insn, i)
++	      && lra_former_scratch_p (REGNO (op)))
+ 	    {
+ 	      int regno = REGNO (op);
+ 	      lra_change_class (regno, NO_REGS, "      Change to", true);
+@@ -3734,6 +3735,8 @@ curr_insn_transform (bool check_only_p)
+ 		   spilled pseudo as there is only one such insn, the
+ 		   current one.  */
+ 		reg_renumber[regno] = -1;
++	      lra_assert (bitmap_single_bit_set_p
++			  (&lra_reg_info[REGNO (op)].insn_bitmap));
+ 	    }
+ 	  /* We can do an optional reload.  If the pseudo got a hard
+ 	     reg, we might improve the code through inheritance.  If
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0067-gcc-musl-support.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0067-gcc-musl-support.patch
new file mode 100644
index 0000000..9a0b5ad
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0067-gcc-musl-support.patch
@@ -0,0 +1,267 @@
+# HG changeset patch
+# Parent e5b4564f249f8634194bdabef4b3057d0e54ee97
+Adding -mmusl as a musl libc specifier, and the necessary hacks for it to know how to find musl's dynamic linker.
+Upstream-Status: backport [partial]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+
+Index: gcc-4.9.0/gcc/config.gcc
+===================================================================
+--- gcc-4.9.0.orig/gcc/config.gcc	2014-04-22 22:44:17.153567150 -0700
++++ gcc-4.9.0/gcc/config.gcc	2014-04-23 23:54:31.427357051 -0700
+@@ -594,7 +594,7 @@
+ esac
+ 
+ # Common C libraries.
+-tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3"
++tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3 LIBC_MUSL=4"
+ 
+ # 32-bit x86 processors supported by --with-arch=.  Each processor
+ # MUST be separated by exactly one space.
+@@ -719,6 +719,9 @@
+     *-*-*uclibc*)
+       tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC"
+       ;;
++    *-*-*musl*)
++      tm_defines="$tm_defines DEFAULT_LIBC=LIBC_MUSL"
++      ;;
+     *)
+       tm_defines="$tm_defines DEFAULT_LIBC=LIBC_GLIBC"
+       ;;
+@@ -2328,6 +2331,11 @@
+ 	    powerpc*-*-linux*paired*)
+ 		tm_file="${tm_file} rs6000/750cl.h" ;;
+ 	esac
++        case ${target} in
++	    *-linux*-musl*)
++		enable_secureplt=yes ;;
++	esac
++
+ 	if test x${enable_secureplt} = xyes; then
+ 		tm_file="rs6000/secureplt.h ${tm_file}"
+ 	fi
+Index: gcc-4.9.0/gcc/config/linux.h
+===================================================================
+--- gcc-4.9.0.orig/gcc/config/linux.h	2014-01-02 14:23:26.000000000 -0800
++++ gcc-4.9.0/gcc/config/linux.h	2014-04-24 00:11:29.034028895 -0700
+@@ -32,10 +32,12 @@
+ #define OPTION_GLIBC  (DEFAULT_LIBC == LIBC_GLIBC)
+ #define OPTION_UCLIBC (DEFAULT_LIBC == LIBC_UCLIBC)
+ #define OPTION_BIONIC (DEFAULT_LIBC == LIBC_BIONIC)
++#define OPTION_MUSL   (DEFAULT_LIBC == LIBC_MUSL)
+ #else
+ #define OPTION_GLIBC  (linux_libc == LIBC_GLIBC)
+ #define OPTION_UCLIBC (linux_libc == LIBC_UCLIBC)
+ #define OPTION_BIONIC (linux_libc == LIBC_BIONIC)
++#define OPTION_MUSL   (linux_libc == LIBC_MUSL)
+ #endif
+ 
+ #define GNU_USER_TARGET_OS_CPP_BUILTINS()			\
+@@ -53,18 +55,21 @@
+    uClibc or Bionic is the default C library and whether
+    -muclibc or -mglibc or -mbionic has been passed to change the default.  */
+ 
+-#define CHOOSE_DYNAMIC_LINKER1(LIBC1, LIBC2, LIBC3, LD1, LD2, LD3)	\
+-  "%{" LIBC2 ":" LD2 ";:%{" LIBC3 ":" LD3 ";:" LD1 "}}"
++#define CHOOSE_DYNAMIC_LINKER1(LIBC1, LIBC2, LIBC3, LIBC4, LD1, LD2, LD3, LD4)	\
++  "%{" LIBC2 ":" LD2 ";:%{" LIBC3 ":" LD3 ";:%{" LIBC4 ":" LD4 ";:" LD1 "}}}"
+ 
+ #if DEFAULT_LIBC == LIBC_GLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U, B) \
+-  CHOOSE_DYNAMIC_LINKER1 ("mglibc", "muclibc", "mbionic", G, U, B)
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++  CHOOSE_DYNAMIC_LINKER1 ("mglibc", "muclibc", "mbionic", "mmusl", G, U, B, M)
+ #elif DEFAULT_LIBC == LIBC_UCLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U, B) \
+-  CHOOSE_DYNAMIC_LINKER1 ("muclibc", "mglibc", "mbionic", U, G, B)
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++  CHOOSE_DYNAMIC_LINKER1 ("muclibc", "mglibc", "mbionic", "mmusl", U, G, B, M)
+ #elif DEFAULT_LIBC == LIBC_BIONIC
+-#define CHOOSE_DYNAMIC_LINKER(G, U, B) \
+-  CHOOSE_DYNAMIC_LINKER1 ("mbionic", "mglibc", "muclibc", B, G, U)
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++  CHOOSE_DYNAMIC_LINKER1 ("mbionic", "mglibc", "muclibc", "mmusl", B, G, U, M)
++#elif DEFAULT_LIBC == LIBC_MUSL
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++  CHOOSE_DYNAMIC_LINKER1 ("mmusl", "mglibc", "muclibc", "mbionic", M, G, U, B)
+ #else
+ #error "Unsupported DEFAULT_LIBC"
+ #endif /* DEFAULT_LIBC */
+@@ -84,16 +89,16 @@
+ 
+ #define GNU_USER_DYNAMIC_LINKER						\
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER,	\
+-			 BIONIC_DYNAMIC_LINKER)
++			 BIONIC_DYNAMIC_LINKER, MUSL_DYNAMIC_LINKER)
+ #define GNU_USER_DYNAMIC_LINKER32					\
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32, \
+-			 BIONIC_DYNAMIC_LINKER32)
++			 BIONIC_DYNAMIC_LINKER32, MUSL_DYNAMIC_LINKER32)
+ #define GNU_USER_DYNAMIC_LINKER64					\
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64, \
+-			 BIONIC_DYNAMIC_LINKER64)
++			 BIONIC_DYNAMIC_LINKER64, MUSL_DYNAMIC_LINKER64)
+ #define GNU_USER_DYNAMIC_LINKERX32					\
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKERX32, UCLIBC_DYNAMIC_LINKERX32, \
+-			 BIONIC_DYNAMIC_LINKERX32)
++			 BIONIC_DYNAMIC_LINKERX32, MUSL_DYNAMIC_LINKERX32)
+ 
+ /* Whether we have Bionic libc runtime */
+ #undef TARGET_HAS_BIONIC
+@@ -127,3 +132,74 @@
+ # define TARGET_LIBC_HAS_FUNCTION linux_libc_has_function
+ 
+ #endif
++
++/* musl avoids problematic includes by rearranging the include directories.
++ * Unfortunately, this is mostly duplicated from cppdefault.c */
++#if DEFAULT_LIBC == LIBC_MUSL
++#define INCLUDE_DEFAULTS_MUSL_GPP			\
++    { GPLUSPLUS_INCLUDE_DIR, "G++", 1, 1,		\
++      GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 0 },		\
++    { GPLUSPLUS_TOOL_INCLUDE_DIR, "G++", 1, 1,		\
++      GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 1 },		\
++    { GPLUSPLUS_BACKWARD_INCLUDE_DIR, "G++", 1, 1,	\
++      GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 0 },
++
++#ifdef LOCAL_INCLUDE_DIR
++#define INCLUDE_DEFAULTS_MUSL_LOCAL			\
++    { LOCAL_INCLUDE_DIR, 0, 0, 1, 1, 2 },		\
++    { LOCAL_INCLUDE_DIR, 0, 0, 1, 1, 0 },
++#else
++#define INCLUDE_DEFAULTS_MUSL_LOCAL
++#endif
++
++#ifdef PREFIX_INCLUDE_DIR
++#define INCLUDE_DEFAULTS_MUSL_PREFIX			\
++    { PREFIX_INCLUDE_DIR, 0, 0, 1, 0, 0},
++#else
++#define INCLUDE_DEFAULTS_MUSL_PREFIX
++#endif
++
++#ifdef CROSS_INCLUDE_DIR
++#define INCLUDE_DEFAULTS_MUSL_CROSS			\
++    { CROSS_INCLUDE_DIR, "GCC", 0, 0, 0, 0},
++#else
++#define INCLUDE_DEFAULTS_MUSL_CROSS
++#endif
++
++#ifdef TOOL_INCLUDE_DIR
++#define INCLUDE_DEFAULTS_MUSL_TOOL			\
++    { TOOL_INCLUDE_DIR, "BINUTILS", 0, 1, 0, 0},
++#else
++#define INCLUDE_DEFAULTS_MUSL_TOOL
++#endif
++
++#ifdef NATIVE_SYSTEM_HEADER_DIR
++#define INCLUDE_DEFAULTS_MUSL_NATIVE			\
++    { NATIVE_SYSTEM_HEADER_DIR, 0, 0, 0, 1, 2 },	\
++    { NATIVE_SYSTEM_HEADER_DIR, 0, 0, 0, 1, 0 },
++#else
++#define INCLUDE_DEFAULTS_MUSL_NATIVE
++#endif
++
++#if defined (CROSS_DIRECTORY_STRUCTURE) && !defined (TARGET_SYSTEM_ROOT)
++# undef INCLUDE_DEFAULTS_MUSL_LOCAL
++# define INCLUDE_DEFAULTS_MUSL_LOCAL
++# undef INCLUDE_DEFAULTS_MUSL_NATIVE
++# define INCLUDE_DEFAULTS_MUSL_NATIVE
++#else
++# undef INCLUDE_DEFAULTS_MUSL_CROSS
++# define INCLUDE_DEFAULTS_MUSL_CROSS
++#endif
++
++#undef INCLUDE_DEFAULTS
++#define INCLUDE_DEFAULTS				\
++  {							\
++    INCLUDE_DEFAULTS_MUSL_GPP				\
++    INCLUDE_DEFAULTS_MUSL_PREFIX			\
++    INCLUDE_DEFAULTS_MUSL_CROSS				\
++    INCLUDE_DEFAULTS_MUSL_TOOL				\
++    INCLUDE_DEFAULTS_MUSL_NATIVE			\
++    { GCC_INCLUDE_DIR, "GCC", 0, 1, 0, 0 },		\
++    { 0, 0, 0, 0, 0, 0 }				\
++  }
++#endif
+Index: gcc-4.9.0/gcc/config/linux.opt
+===================================================================
+--- gcc-4.9.0.orig/gcc/config/linux.opt	2014-01-02 14:23:26.000000000 -0800
++++ gcc-4.9.0/gcc/config/linux.opt	2014-04-22 22:44:17.280233817 -0700
+@@ -30,3 +30,7 @@
+ muclibc
+ Target Report RejectNegative Var(linux_libc,LIBC_UCLIBC) Negative(mbionic)
+ Use uClibc C library
++
++mmusl
++Target Report RejectNegative Var(linux_libc,LIBC_MUSL) Negative(mglibc)
++Use musl C library
+Index: gcc-4.9.0/gcc/ginclude/stddef.h
+===================================================================
+--- gcc-4.9.0.orig/gcc/ginclude/stddef.h	2014-01-02 14:23:26.000000000 -0800
++++ gcc-4.9.0/gcc/ginclude/stddef.h	2014-04-22 22:44:17.280233817 -0700
+@@ -181,6 +181,7 @@
+ #ifndef _GCC_SIZE_T
+ #ifndef _SIZET_
+ #ifndef __size_t
++#ifndef __DEFINED_size_t /* musl */
+ #define __size_t__	/* BeOS */
+ #define __SIZE_T__	/* Cray Unicos/Mk */
+ #define _SIZE_T
+@@ -197,6 +198,7 @@
+ #define ___int_size_t_h
+ #define _GCC_SIZE_T
+ #define _SIZET_
++#define __DEFINED_size_t /* musl */
+ #if (defined (__FreeBSD__) && (__FreeBSD__ >= 5)) \
+   || defined(__FreeBSD_kernel__)
+ /* __size_t is a typedef on FreeBSD 5, must not trash it. */
+@@ -214,6 +216,7 @@
+ typedef long ssize_t;
+ #endif /* __BEOS__ */
+ #endif /* !(defined (__GNUG__) && defined (size_t)) */
++#endif /* __DEFINED_size_t */
+ #endif /* __size_t */
+ #endif /* _SIZET_ */
+ #endif /* _GCC_SIZE_T */
+Index: gcc-4.9.0/gcc/config/rs6000/secureplt.h
+===================================================================
+--- gcc-4.9.0.orig/gcc/config/rs6000/secureplt.h	2014-01-02 14:23:26.000000000 -0800
++++ gcc-4.9.0/gcc/config/rs6000/secureplt.h	2014-04-23 23:55:15.114024175 -0700
+@@ -18,3 +18,4 @@
+ <http://www.gnu.org/licenses/>.  */
+ 
+ #define CC1_SECURE_PLT_DEFAULT_SPEC "-msecure-plt"
++#define LINK_SECURE_PLT_DEFAULT_SPEC "--secure-plt"
+Index: gcc-4.9.0/gcc/config/rs6000/sysv4.h
+===================================================================
+--- gcc-4.9.0.orig/gcc/config/rs6000/sysv4.h	2014-04-23 23:52:13.854023015 -0700
++++ gcc-4.9.0/gcc/config/rs6000/sysv4.h	2014-04-24 00:10:55.550695334 -0700
+@@ -538,6 +538,10 @@
+ #define CC1_SECURE_PLT_DEFAULT_SPEC ""
+ #endif
+ 
++#ifndef LINK_SECURE_PLT_DEFAULT_SPEC
++#define LINK_SECURE_PLT_DEFAULT_SPEC ""
++#endif
++
+ /* Pass -G xxx to the compiler.  */
+ #define	CC1_SPEC "%{G*} %(cc1_cpu)" \
+ "%{meabi: %{!mcall-*: -mcall-sysv }} \
+@@ -585,7 +589,8 @@
+ 
+ /* Override the default target of the linker.  */
+ #define	LINK_TARGET_SPEC \
+-  ENDIAN_SELECT("", " --oformat elf32-powerpcle", "")
++  ENDIAN_SELECT("", " --oformat elf32-powerpcle", "") \
++  "%{!mbss-plt: %{!msecure-plt: %(link_secure_plt_default)}}"
+ 
+ /* Any specific OS flags.  */
+ #define LINK_OS_SPEC "\
+@@ -894,6 +899,7 @@
+   { "link_os_openbsd",		LINK_OS_OPENBSD_SPEC },			\
+   { "link_os_default",		LINK_OS_DEFAULT_SPEC },			\
+   { "cc1_secure_plt_default",	CC1_SECURE_PLT_DEFAULT_SPEC },		\
++  { "link_secure_plt_default",	LINK_SECURE_PLT_DEFAULT_SPEC },		\
+   { "cpp_os_ads",		CPP_OS_ADS_SPEC },			\
+   { "cpp_os_yellowknife",	CPP_OS_YELLOWKNIFE_SPEC },		\
+   { "cpp_os_mvme",		CPP_OS_MVME_SPEC },			\
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0068-musl-dynamic-linker.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0068-musl-dynamic-linker.patch
new file mode 100644
index 0000000..605ac66
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0068-musl-dynamic-linker.patch
@@ -0,0 +1,205 @@
+# HG changeset patch
+# Parent 6738fd6f6fcc2a72f2ba527bda3325642af26885
+Support for arm-linux-musl.
+Upstream-Status: Backport [partial]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+
+Index: gcc-4.9.2/gcc/config/arm/linux-eabi.h
+===================================================================
+--- gcc-4.9.2.orig/gcc/config/arm/linux-eabi.h
++++ gcc-4.9.2/gcc/config/arm/linux-eabi.h
+@@ -81,6 +81,23 @@
+ #undef TARGET_FIX_V4BX_SPEC
+ #define TARGET_FIX_V4BX_SPEC "%{mcpu=arm8|mcpu=arm810|mcpu=strongarm*|march=armv4: --fix-v4bx}"
+ 
++/* For ARM musl currently supports four dynamic linkers:
++   - ld-musl-arm.so.1 - for the EABI-derived soft-float ABI
++   - ld-musl-armhf.so.1 - for the EABI-derived hard-float ABI
++   - ld-musl-armeb.so.1 - for the EABI-derived soft-float ABI, EB
++   - ld-musl-armebhf.so.1 - for the EABI-derived hard-float ABI, EB
++   musl does not support the legacy OABI mode.
++   All the dynamic linkers live in /lib.
++   We default to soft-float, EL. */
++#undef  MUSL_DYNAMIC_LINKER
++#if TARGET_BIG_ENDIAN_DEFAULT
++#define MUSL_DYNAMIC_LINKER_E "%{mlittle-endian:;:eb}"
++#else
++#define MUSL_DYNAMIC_LINKER_E "%{mbig-endian:eb}"
++#endif
++#define MUSL_DYNAMIC_LINKER \
++  SYSTEMLIBS_DIR "ld-musl-arm" MUSL_DYNAMIC_LINKER_E "%{mfloat-abi=hard:hf}.so.1"
++
+ /* At this point, bpabi.h will have clobbered LINK_SPEC.  We want to
+    use the GNU/Linux version, not the generic BPABI version.  */
+ #undef  LINK_SPEC
+Index: gcc-4.9.2/libitm/config/arm/hwcap.cc
+===================================================================
+--- gcc-4.9.2.orig/libitm/config/arm/hwcap.cc
++++ gcc-4.9.2/libitm/config/arm/hwcap.cc
+@@ -40,7 +40,11 @@ int GTM_hwcap HIDDEN = 0
+ 
+ #ifdef __linux__
+ #include <unistd.h>
++#ifdef __GLIBC__
+ #include <sys/fcntl.h>
++#else
++#include <fcntl.h>
++#endif
+ #include <elf.h>
+ 
+ static void __attribute__((constructor))
+Index: gcc-4.9.2/gcc/config/i386/linux.h
+===================================================================
+--- gcc-4.9.2.orig/gcc/config/i386/linux.h
++++ gcc-4.9.2/gcc/config/i386/linux.h
+@@ -21,3 +21,4 @@ along with GCC; see the file COPYING3.
+ 
+ #define GNU_USER_LINK_EMULATION "elf_i386"
+ #define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
++#define MUSL_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-musl-i386.so.1"
+Index: gcc-4.9.2/gcc/config/i386/linux64.h
+===================================================================
+--- gcc-4.9.2.orig/gcc/config/i386/linux64.h
++++ gcc-4.9.2/gcc/config/i386/linux64.h
+@@ -30,3 +30,8 @@ see the files COPYING3 and COPYING.RUNTI
+ #define GLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-linux.so.2"
+ #define GLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-linux-x86-64.so.2"
+ #define GLIBC_DYNAMIC_LINKERX32 SYSTEMLIBS_DIR "ld-linux-x32.so.2"
++
++#define MUSL_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-musl-i386.so.1"
++#define MUSL_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-musl-x86_64.so.1"
++#define MUSL_DYNAMIC_LINKERX32 SYSTEMLIBS_DIR "ld-musl-x32.so.1"
++
+Index: gcc-4.9.2/gcc/config/mips/linux.h
+===================================================================
+--- gcc-4.9.2.orig/gcc/config/mips/linux.h
++++ gcc-4.9.2/gcc/config/mips/linux.h
+@@ -23,3 +23,6 @@ along with GCC; see the file COPYING3.
+ #undef UCLIBC_DYNAMIC_LINKER
+ #define UCLIBC_DYNAMIC_LINKER \
+   "%{mnan=2008:" SYSTEMLIBS_DIR "ld-uClibc-mipsn8.so.0;:" SYSTEMLIBS_DIR "ld-uClibc.so.0}"
++
++#define MUSL_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-musl-mips.so.1"
++
+Index: gcc-4.9.2/gcc/config/mips/linux64.h
+===================================================================
+--- gcc-4.9.2.orig/gcc/config/mips/linux64.h
++++ gcc-4.9.2/gcc/config/mips/linux64.h
+@@ -39,6 +39,11 @@ along with GCC; see the file COPYING3.
+   "%{mnan=2008:" SYSTEMLIBS_DIR "ld-uClibc-mipsn8.so.0;:" SYSTEMLIBS_DIR "ld-uClibc.so.0}"
+ 
+ #define BIONIC_DYNAMIC_LINKERN32 "/system/bin/linker32"
++
++#define MUSL_DYNAMIC_LINKERN32 SYSTEMLIBS_DIR "ld-musl-mips.so.1"
++#define MUSL_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-musl-mips.so.1"
++#define MUSL_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-musl-mips.so.1"
++
+ #define GNU_USER_DYNAMIC_LINKERN32 \
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKERN32, UCLIBC_DYNAMIC_LINKERN32, \
+-			 BIONIC_DYNAMIC_LINKERN32)
++			 BIONIC_DYNAMIC_LINKERN32, MUSL_DYNAMIC_LINKERN32)
+Index: gcc-4.9.2/gcc/config/rs6000/linux64.h
+===================================================================
+--- gcc-4.9.2.orig/gcc/config/rs6000/linux64.h
++++ gcc-4.9.2/gcc/config/rs6000/linux64.h
+@@ -375,17 +375,22 @@ extern int dot_symbols;
+ #endif
+ #define UCLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-uClibc.so.0"
+ #define UCLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld64-uClibc.so.0"
++#define MUSL_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-musl-powerpc.so.1"
++#define MUSL_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-musl-powerpc64.so.1"
++
+ #if DEFAULT_LIBC == LIBC_UCLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{mmusl:" M ";:" U "}}"
+ #elif DEFAULT_LIBC == LIBC_GLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{muclibc:" U ";:" G "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{muclibc:" U ";:%{mmusl:" M ";:" G "}}"
++#elif DEFAULT_LIBC == LIBC_MUSL
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{muclibc:" U ";:" M "}}"
+ #else
+ #error "Unsupported DEFAULT_LIBC"
+ #endif
+ #define GNU_USER_DYNAMIC_LINKER32 \
+-  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32)
++  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32, MUSL_DYNAMIC_LINKER32)
+ #define GNU_USER_DYNAMIC_LINKER64 \
+-  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64)
++  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64, MUSL_DYNAMIC_LINKER64)
+ 
+ #undef  DEFAULT_ASM_ENDIAN
+ #if (TARGET_DEFAULT & MASK_LITTLE_ENDIAN)
+Index: gcc-4.9.2/gcc/config/rs6000/sysv4.h
+===================================================================
+--- gcc-4.9.2.orig/gcc/config/rs6000/sysv4.h
++++ gcc-4.9.2/gcc/config/rs6000/sysv4.h
+@@ -768,15 +768,19 @@ ENDIAN_SELECT(" -mbig", " -mlittle", DEF
+ 
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
+ #define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
++#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-powerpc.so.1"
++
+ #if DEFAULT_LIBC == LIBC_UCLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{mmusl:" M ";:" U "}}"
++#elif DEFAULT_LIBC == LIBC_MUSL
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{muclibc:" U ";:" M "}}"
+ #elif !defined (DEFAULT_LIBC) || DEFAULT_LIBC == LIBC_GLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{muclibc:" U ";:" G "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{muclibc:" U ";:%{mmusl:" M ";:" G "}}"
+ #else
+ #error "Unsupported DEFAULT_LIBC"
+ #endif
+ #define GNU_USER_DYNAMIC_LINKER \
+-  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER)
++  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER, MUSL_DYNAMIC_LINKER)
+ 
+ #define LINK_OS_LINUX_SPEC "-m elf32ppclinux %{!shared: %{!static: \
+   %{rdynamic:-export-dynamic} \
+Index: gcc-4.9.2/libitm/config/linux/x86/tls.h
+===================================================================
+--- gcc-4.9.2.orig/libitm/config/linux/x86/tls.h
++++ gcc-4.9.2/libitm/config/linux/x86/tls.h
+@@ -25,16 +25,19 @@
+ #ifndef LIBITM_X86_TLS_H
+ #define LIBITM_X86_TLS_H 1
+ 
+-#if defined(__GLIBC_PREREQ) && __GLIBC_PREREQ(2, 10)
++#if defined(__GLIBC_PREREQ)
++#if __GLIBC_PREREQ(2, 10)
+ /* Use slots in the TCB head rather than __thread lookups.
+    GLIBC has reserved words 10 through 13 for TM.  */
+ #define HAVE_ARCH_GTM_THREAD 1
+ #define HAVE_ARCH_GTM_THREAD_DISP 1
+ #endif
++#endif
+ 
+ #include "config/generic/tls.h"
+ 
+-#if defined(__GLIBC_PREREQ) && __GLIBC_PREREQ(2, 10)
++#if defined(__GLIBC_PREREQ)
++#if __GLIBC_PREREQ(2, 10)
+ namespace GTM HIDDEN {
+ 
+ #ifdef __x86_64__
+@@ -101,5 +104,6 @@ static inline void set_abi_disp(struct a
+ 
+ } // namespace GTM
+ #endif /* >= GLIBC 2.10 */
++#endif
+ 
+ #endif // LIBITM_X86_TLS_H
+Index: gcc-4.9.2/gcc/config/aarch64/aarch64-linux.h
+===================================================================
+--- gcc-4.9.2.orig/gcc/config/aarch64/aarch64-linux.h
++++ gcc-4.9.2/gcc/config/aarch64/aarch64-linux.h
+@@ -25,6 +25,8 @@
+ 
+ #define CPP_SPEC "%{pthread:-D_REENTRANT}"
+ 
++#define MUSL_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-musl-aarch64.so.1"
++
+ #define LINUX_TARGET_LINK_SPEC  "%{h*}		\
+    %{static:-Bstatic}				\
+    %{shared:-shared}				\
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0069-musl-no-fixincludes.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0069-musl-no-fixincludes.patch
new file mode 100644
index 0000000..e2b18a4
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0069-musl-no-fixincludes.patch
@@ -0,0 +1,21 @@
+# HG changeset patch
+# Parent 600a8a422ccaf5627ad1f5a138e7398df2b9e9d8
+Get rid of ever-broken fixincludes on musl.
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+
+Index: gcc-4.9-20140316/fixincludes/mkfixinc.sh
+===================================================================
+--- gcc-4.9-20140316.orig/fixincludes/mkfixinc.sh
++++ gcc-4.9-20140316/fixincludes/mkfixinc.sh
+@@ -19,7 +19,8 @@ case $machine in
+     powerpc-*-eabi*    | \
+     powerpc-*-rtems*   | \
+     powerpcle-*-eabisim* | \
+-    powerpcle-*-eabi* )
++    powerpcle-*-eabi* | \
++    *-musl* )
+ 	#  IF there is no include fixing,
+ 	#  THEN create a no-op fixer and exit
+ 	(echo "#! /bin/sh" ; echo "exit 0" ) > ${target}
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0070-libstdc-musl.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0070-libstdc-musl.patch
new file mode 100644
index 0000000..048e481
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0070-libstdc-musl.patch
@@ -0,0 +1,32 @@
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: gcc-4.9-20140316/libstdc++-v3/configure.host
+===================================================================
+--- gcc-4.9-20140316.orig/libstdc++-v3/configure.host	2014-03-26 01:12:19.466008193 -0700
++++ gcc-4.9-20140316/libstdc++-v3/configure.host	2014-03-26 01:43:48.222684357 -0700
+@@ -264,14 +264,24 @@
+     os_include_dir="os/bsd/freebsd"
+     ;;
+   gnu* | linux* | kfreebsd*-gnu | knetbsd*-gnu)
++    # check for musl by target
++    case "${host_os}" in
++      *-musl*)
++        os_include_dir="os/generic"
++        ;;
++      *)
+     if [ "$uclibc" = "yes" ]; then
+       os_include_dir="os/uclibc"
+     elif [ "$bionic" = "yes" ]; then
+       os_include_dir="os/bionic"
++    elif [ "$musl" = "yes" ]; then
++      os_include_dir="os/generic"
+     else
+       os_include_dir="os/gnu-linux"
+     fi
+     ;;
++    esac
++    ;;
+   hpux*)
+     os_include_dir="os/hpux"
+     ;;
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0071-Ignore-fdebug-prefix-map-in-producer-string-by-Danie.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0071-Ignore-fdebug-prefix-map-in-producer-string-by-Danie.patch
new file mode 100644
index 0000000..e8f79b5
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0071-Ignore-fdebug-prefix-map-in-producer-string-by-Danie.patch
@@ -0,0 +1,31 @@
+From 32593b38082ea65f4c82159254adf1e0dc2423be Mon Sep 17 00:00:00 2001
+From: bernds <bernds@138bc75d-0d04-0410-961f-82ee72b054a4>
+Date: Tue, 16 Feb 2016 03:15:15 -0500
+Subject: [PATCH] Ignore -fdebug-prefix-map in producer string (by Daniel Kahn
+ Gillmor)
+
+* dwarf2out.c (gen_producer_string): Ignore -fdebug-prefix-map.
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@231835 138bc75d-0d04-0410-961f-82ee72b054a4
+
+Upstream-Status: Backport
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ gcc/dwarf2out.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c
+index 3614c10..526f114 100644
+--- a/gcc/dwarf2out.c
++++ b/gcc/dwarf2out.c
+@@ -19670,6 +19670,7 @@ gen_producer_string (void)
+       case OPT_fpreprocessed:
+       case OPT_fltrans_output_list_:
+       case OPT_fresolution_:
++      case OPT_fdebug_prefix_map_:
+ 	/* Ignore these.  */
+ 	continue;
+       default:
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0072-support-ffile-prefix-map.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0072-support-ffile-prefix-map.patch
new file mode 100644
index 0000000..9809a6a
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0072-support-ffile-prefix-map.patch
@@ -0,0 +1,284 @@
+From e863be798ed13312a0faf0b961275f211a8123ab Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 17 Mar 2016 00:32:17 -0400
+Subject: [PATCH] gcc/libcpp: support -ffile-prefix-map=<old>=<new>
+
+Similar -fdebug-prefix-map, add option -ffile-prefix-map to map one
+directory name (old) to another (new) in __FILE__, __BASE_FILE__ and
+__builtin_FILE ().
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70268
+
+Upstream-Status: Submitted [gcc-patches@gcc.gnu.org]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ gcc/c-family/c-opts.c     |  6 ++++
+ gcc/c-family/c.opt        |  4 +++
+ gcc/dwarf2out.c           |  1 +
+ gcc/gimplify.c            |  2 ++
+ libcpp/Makefile.in        | 10 +++---
+ libcpp/file-map.c         | 92 +++++++++++++++++++++++++++++++++++++++++++++++
+ libcpp/include/file-map.h | 30 ++++++++++++++++
+ libcpp/macro.c            |  2 ++
+ 8 files changed, 142 insertions(+), 5 deletions(-)
+ create mode 100644 libcpp/file-map.c
+ create mode 100644 libcpp/include/file-map.h
+
+diff --git a/gcc/c-family/c-opts.c b/gcc/c-family/c-opts.c
+index dd5fd23..9c004a1 100644
+--- a/gcc/c-family/c-opts.c
++++ b/gcc/c-family/c-opts.c
+@@ -36,6 +36,7 @@ along with GCC; see the file COPYING3.  If not see
+ #include "options.h"
+ #include "plugin.h"		/* For PLUGIN_INCLUDE_FILE event.  */
+ #include "mkdeps.h"
++#include "file-map.h"
+ #include "c-target.h"
+ #include "tm.h"			/* For BYTES_BIG_ENDIAN,
+ 				   DOLLARS_IN_IDENTIFIERS,
+@@ -553,6 +554,11 @@ c_common_handle_option (size_t scode, const char *arg, int value,
+       cpp_opts->narrow_charset = arg;
+       break;
+ 
++    case OPT_ffile_prefix_map_:
++      if (add_file_prefix_map (arg) < 0)
++        error ("invalid argument %qs to -ffile-prefix-map", arg);
++      break;
++
+     case OPT_fwide_exec_charset_:
+       cpp_opts->wide_charset = arg;
+       break;
+diff --git a/gcc/c-family/c.opt b/gcc/c-family/c.opt
+index f295805..3a99662 100644
+--- a/gcc/c-family/c.opt
++++ b/gcc/c-family/c.opt
+@@ -928,6 +928,10 @@ fexec-charset=
+ C ObjC C++ ObjC++ Joined RejectNegative
+ -fexec-charset=<cset>	Convert all strings and character constants to character set <cset>
+ 
++ffile-prefix-map=
++C ObjC C++ ObjC++ Joined RejectNegative
++-ffile-prefix-map=<old=new>	Map one directory name to another in __FILE__, __BASE_FILE__ and __builtin_FILE ()
++
+ fextended-identifiers
+ C ObjC C++ ObjC++
+ Permit universal character names (\\u and \\U) in identifiers
+diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c
+index 99bf6e2..3e58cfd 100644
+--- a/gcc/dwarf2out.c
++++ b/gcc/dwarf2out.c
+@@ -19199,6 +19199,7 @@ gen_producer_string (void)
+       case OPT_fltrans_output_list_:
+       case OPT_fresolution_:
+       case OPT_fdebug_prefix_map_:
++      case OPT_ffile_prefix_map_:
+ 	/* Ignore these.  */
+ 	continue;
+       default:
+diff --git a/gcc/gimplify.c b/gcc/gimplify.c
+index 89e7334..a7a97c0 100644
+--- a/gcc/gimplify.c
++++ b/gcc/gimplify.c
+@@ -59,6 +59,7 @@ along with GCC; see the file COPYING3.  If not see
+ #include "omp-low.h"
+ #include "gimple-low.h"
+ #include "cilk.h"
++#include "file-map.h"
+ 
+ #include "langhooks-def.h"	/* FIXME: for lhd_set_decl_assembler_name */
+ #include "tree-pass.h"		/* FIXME: only for PROP_gimple_any */
+@@ -2288,6 +2289,7 @@ gimplify_call_expr (tree *expr_p, gimple_seq *pre_p, bool want_value)
+       case BUILT_IN_FILE:
+ 	{
+ 	  expanded_location loc = expand_location (EXPR_LOCATION (*expr_p));
++	  loc.file = remap_file_filename (loc.file);
+ 	  *expr_p = build_string_literal (strlen (loc.file) + 1, loc.file);
+ 	  return GS_OK;
+ 	}
+diff --git a/libcpp/Makefile.in b/libcpp/Makefile.in
+index 5561c97..5017256 100644
+--- a/libcpp/Makefile.in
++++ b/libcpp/Makefile.in
+@@ -84,12 +84,12 @@ DEPMODE = $(CXXDEPMODE)
+ 
+ 
+ libcpp_a_OBJS = charset.o directives.o directives-only.o errors.o \
+-	expr.o files.o identifiers.o init.o lex.o line-map.o macro.o \
+-	mkdeps.o pch.o symtab.o traditional.o
++	expr.o file-map.o files.o identifiers.o init.o lex.o line-map.o \
++	macro.o mkdeps.o pch.o symtab.o traditional.o
+ 
+ libcpp_a_SOURCES = charset.c directives.c directives-only.c errors.c \
+-	expr.c files.c identifiers.c init.c lex.c line-map.c macro.c \
+-	mkdeps.c pch.c symtab.c traditional.c
++	expr.c file-map.c files.c identifiers.c init.c lex.c line-map.c \
++	macro.c mkdeps.c pch.c symtab.c traditional.c
+ 
+ all: libcpp.a $(USED_CATALOGS)
+ 
+@@ -263,7 +263,7 @@ po/$(PACKAGE).pot: $(libcpp_a_SOURCES)
+ 
+ TAGS_SOURCES = $(libcpp_a_SOURCES) internal.h ucnid.h \
+     include/line-map.h include/symtab.h include/cpp-id-data.h \
+-    include/cpplib.h include/mkdeps.h system.h
++    include/cpplib.h include/mkdeps.h system.h include/file-map.h
+ 
+ TAGS: $(TAGS_SOURCES)
+ 	cd $(srcdir) && etags $(TAGS_SOURCES)
+diff --git a/libcpp/file-map.c b/libcpp/file-map.c
+new file mode 100644
+index 0000000..04e851b
+--- /dev/null
++++ b/libcpp/file-map.c
+@@ -0,0 +1,92 @@
++/* Map one directory name to another in __FILE__, __BASE_FILE__
++   and __builtin_FILE ().
++   Copyright (C) 2001-2016 Free Software Foundation, Inc.
++
++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 3, 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; see the file COPYING3.  If not see
++<http://www.gnu.org/licenses/>.
++
++ In other words, you are welcome to use, share and improve this program.
++ You are forbidden to forbid anyone else to use, share and improve
++ what you give them.   Help stamp out software-hoarding!  */
++
++#include "config.h"
++#include "system.h"
++#include "file-map.h"
++
++/* Structure recording the mapping from source file and directory
++   names at compile time to __FILE__ */
++typedef struct file_prefix_map
++{
++  const char *old_prefix;
++  const char *new_prefix;
++  size_t old_len;
++  size_t new_len;
++  struct file_prefix_map *next;
++} file_prefix_map;
++
++/* Linked list of such structures.  */
++static file_prefix_map *file_prefix_maps;
++
++/* Record prefix mapping of __FILE__.  ARG is the argument to
++   -ffile-prefix-map and must be of the form OLD=NEW.  */
++int
++add_file_prefix_map (const char *arg)
++{
++  file_prefix_map *map;
++  const char *p;
++
++  p = strchr (arg, '=');
++  if (!p)
++  {
++      fprintf(stderr, "invalid argument %qs to -ffile-prefix-map", arg);
++      return -1;
++  }
++  map = XNEW (file_prefix_map);
++  map->old_prefix = xstrndup (arg, p - arg);
++  map->old_len = p - arg;
++  p++;
++  map->new_prefix = xstrdup (p);
++  map->new_len = strlen (p);
++  map->next = file_prefix_maps;
++  file_prefix_maps = map;
++
++  return 0;
++}
++
++/* Perform user-specified mapping of __FILE__ prefixes.  Return
++   the new name corresponding to filename.  */
++
++const char *
++remap_file_filename (const char *filename)
++{
++  file_prefix_map *map;
++  char *s;
++  const char *name;
++  size_t name_len;
++
++  for (map = file_prefix_maps; map; map = map->next)
++    if (filename_ncmp (filename, map->old_prefix, map->old_len) == 0)
++      break;
++  if (!map)
++    return filename;
++  name = filename + map->old_len;
++  name_len = strlen (name) + 1;
++  s = (char *) alloca (name_len + map->new_len);
++  memcpy (s, map->new_prefix, map->new_len);
++  memcpy (s + map->new_len, name, name_len);
++
++  return xstrdup (s);
++}
++
++
+diff --git a/libcpp/include/file-map.h b/libcpp/include/file-map.h
+new file mode 100644
+index 0000000..e6f8cbf
+--- /dev/null
++++ b/libcpp/include/file-map.h
+@@ -0,0 +1,30 @@
++/* Map one directory name to another in __FILE__, __BASE_FILE__
++   and __builtin_FILE ().
++   Copyright (C) 2001-2016 Free Software Foundation, Inc.
++
++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 3, 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; see the file COPYING3.  If not see
++<http://www.gnu.org/licenses/>.
++
++ In other words, you are welcome to use, share and improve this program.
++ You are forbidden to forbid anyone else to use, share and improve
++ what you give them.   Help stamp out software-hoarding!  */
++
++#ifndef LIBCPP_FILE_MAP_H
++#define LIBCPP_FILE_MAP_H
++
++const char * remap_file_filename (const char *filename);
++
++int add_file_prefix_map (const char *arg);
++
++#endif /* !LIBCPP_FILE_MAP_H  */
+diff --git a/libcpp/macro.c b/libcpp/macro.c
+index 11e50f4..5c6f90e 100644
+--- a/libcpp/macro.c
++++ b/libcpp/macro.c
+@@ -26,6 +26,7 @@ along with this program; see the file COPYING3.  If not see
+ #include "system.h"
+ #include "cpplib.h"
+ #include "internal.h"
++#include "file-map.h"
+ 
+ typedef struct macro_arg macro_arg;
+ /* This structure represents the tokens of a macro argument.  These
+@@ -288,6 +289,7 @@ _cpp_builtin_macro_text (cpp_reader *pfile, cpp_hashnode *node)
+ 	    if (!name)
+ 	      abort ();
+ 	  }
++	name = remap_file_filename (name);
+ 	len = strlen (name);
+ 	buf = _cpp_unaligned_alloc (pfile, len * 2 + 3);
+ 	result = buf;
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0073-Reuse-fdebug-prefix-map-to-replace-ffile-prefix-map.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0073-Reuse-fdebug-prefix-map-to-replace-ffile-prefix-map.patch
new file mode 100644
index 0000000..94e45ed
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0073-Reuse-fdebug-prefix-map-to-replace-ffile-prefix-map.patch
@@ -0,0 +1,43 @@
+From 5e10baff84038d26dc3d59b2412ba1db92cb8274 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 17 Mar 2016 00:34:01 -0400
+Subject: [PATCH 2/2] Reuse -fdebug-prefix-map to replace -ffile-prefix-map
+
+The oe-core may use external toolchain to compile,
+which may not support -ffile-prefix-map.
+
+Since we use -fdebug-prefix-map to do the same thing,
+so we could reuse it to replace -ffile-prefix-map.
+
+Upstream-Status: Inappropriate[oe-core specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ gcc/opts-global.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/gcc/opts-global.c b/gcc/opts-global.c
+index 111884b..037f6c8 100644
+--- a/gcc/opts-global.c
++++ b/gcc/opts-global.c
+@@ -42,6 +42,7 @@ along with GCC; see the file COPYING3.  If not see
+ #include "toplev.h"
+ #include "tree-pass.h"
+ #include "context.h"
++#include "file-map.h"
+ 
+ typedef const char *const_char_p; /* For DEF_VEC_P.  */
+ 
+@@ -354,6 +355,9 @@ handle_common_deferred_options (void)
+ 
+ 	case OPT_fdebug_prefix_map_:
+ 	  add_debug_prefix_map (opt->arg);
++
++	  /* Reuse -fdebug-prefix-map to replace -ffile-prefix-map */
++	  add_file_prefix_map (opt->arg);
+ 	  break;
+ 
+ 	case OPT_fdump_:
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0074-fdebug-prefix-map-support-to-remap-relative-path.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0074-fdebug-prefix-map-support-to-remap-relative-path.patch
new file mode 100644
index 0000000..0b91fdb
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0074-fdebug-prefix-map-support-to-remap-relative-path.patch
@@ -0,0 +1,51 @@
+From 289ad2969a5966c603bf6928ce442db74c4cbb25 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 24 Mar 2016 11:23:14 -0400
+Subject: [PATCH] gcc/final.c: -fdebug-prefix-map support to remap sources with
+ relative path
+
+PR other/70428
+* final.c (remap_debug_filename): Use lrealpath to translate
+relative path before remapping
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70428
+Upstream-Status: Submitted [gcc-patches@gcc.gnu.org]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+diff --git a/gcc/final.c b/gcc/final.c
+index 55cf509..c3594c2 100644
+--- a/gcc/final.c
++++ b/gcc/final.c
+@@ -1554,16 +1554,25 @@ remap_debug_filename (const char *filename)
+   const char *name;
+   size_t name_len;
+ 
++  /* Support to remap filename with relative path  */
++  char *realpath = lrealpath (filename);
++  if (realpath == NULL)
++    return filename;
++
+   for (map = debug_prefix_maps; map; map = map->next)
+-    if (filename_ncmp (filename, map->old_prefix, map->old_len) == 0)
++    if (filename_ncmp (realpath, map->old_prefix, map->old_len) == 0)
+       break;
+   if (!map)
+-    return filename;
+-  name = filename + map->old_len;
++    {
++      free (realpath);
++      return filename;
++    }
++  name = realpath + map->old_len;
+   name_len = strlen (name) + 1;
+   s = (char *) alloca (name_len + map->new_len);
+   memcpy (s, map->new_prefix, map->new_len);
+   memcpy (s + map->new_len, name, name_len);
++  free (realpath);
+   return ggc_strdup (s);
+ }
+ 
+-- 
+2.7.4
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0024-Disable-sdt.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0024-Disable-sdt.patch
deleted file mode 100644
index 9f219ca..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0024-Disable-sdt.patch
+++ /dev/null
@@ -1,113 +0,0 @@
-From e136342d2f7c0bdb1cf4b57ad3440d3c9e710322 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 29 Mar 2013 09:28:10 +0400
-Subject: [PATCH 24/35] Disable sdt.
-
-We don't list dtrace in DEPENDS so we shouldn't be depending on this header.
-It may or may not exist from preivous builds though. To be determinstic, disable
-sdt.h usage always. This avoids build failures if the header is removed after configure
-but before libgcc is compiled for example.
-
-RP 2012/8/7
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
-Disable sdt for libstdc++-v3.
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-
-Upstream-Status: Inappropriate [hack]
----
- gcc/configure             | 12 ++++++------
- gcc/configure.ac          | 18 +++++++++---------
- libstdc++-v3/configure    |  6 +++---
- libstdc++-v3/configure.ac |  2 +-
- 4 files changed, 19 insertions(+), 19 deletions(-)
-
-diff --git a/gcc/configure b/gcc/configure
-index f059c2f..98853b3 100755
---- a/gcc/configure
-+++ b/gcc/configure
-@@ -27733,12 +27733,12 @@ fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking sys/sdt.h in the target C library" >&5
- $as_echo_n "checking sys/sdt.h in the target C library... " >&6; }
- have_sys_sdt_h=no
--if test -f $target_header_dir/sys/sdt.h; then
--  have_sys_sdt_h=yes
--
--$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
--
--fi
-+#if test -f $target_header_dir/sys/sdt.h; then
-+#  have_sys_sdt_h=yes
-+#
-+#$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
-+#
-+#fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_sys_sdt_h" >&5
- $as_echo "$have_sys_sdt_h" >&6; }
- 
-diff --git a/gcc/configure.ac b/gcc/configure.ac
-index 2e668a5..52cdcb8 100644
---- a/gcc/configure.ac
-+++ b/gcc/configure.ac
-@@ -5232,15 +5232,15 @@ if test x$gcc_cv_libc_provides_ssp = xyes; then
- fi
- 
- # Test for <sys/sdt.h> on the target.
--GCC_TARGET_TEMPLATE([HAVE_SYS_SDT_H])
--AC_MSG_CHECKING(sys/sdt.h in the target C library)
--have_sys_sdt_h=no
--if test -f $target_header_dir/sys/sdt.h; then
--  have_sys_sdt_h=yes
--  AC_DEFINE(HAVE_SYS_SDT_H, 1,
--            [Define if your target C library provides sys/sdt.h])
--fi
--AC_MSG_RESULT($have_sys_sdt_h)
-+#GCC_TARGET_TEMPLATE([HAVE_SYS_SDT_H])
-+#AC_MSG_CHECKING(sys/sdt.h in the target C library)
-+#have_sys_sdt_h=no
-+#if test -f $target_header_dir/sys/sdt.h; then
-+#  have_sys_sdt_h=yes
-+#  AC_DEFINE(HAVE_SYS_SDT_H, 1,
-+#            [Define if your target C library provides sys/sdt.h])
-+#fi
-+#AC_MSG_RESULT($have_sys_sdt_h)
- 
- # Check if TFmode long double should be used by default or not.
- # Some glibc targets used DFmode long double, but with glibc 2.4
-diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
-index fbad667..7d5a6c6 100755
---- a/libstdc++-v3/configure
-+++ b/libstdc++-v3/configure
-@@ -20897,11 +20897,11 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
- ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
- ac_compiler_gnu=$ac_cv_c_compiler_gnu
- 
--  if test $glibcxx_cv_sys_sdt_h = yes; then
-+#  if test $glibcxx_cv_sys_sdt_h = yes; then
- 
--$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
-+#$as_echo "#define HAVE_SYS_SDT_H 1" >>confdefs.h
- 
--  fi
-+#  fi
-   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $glibcxx_cv_sys_sdt_h" >&5
- $as_echo "$glibcxx_cv_sys_sdt_h" >&6; }
- 
-diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac
-index 7a7c1d8..b13eabc 100644
---- a/libstdc++-v3/configure.ac
-+++ b/libstdc++-v3/configure.ac
-@@ -229,7 +229,7 @@ GLIBCXX_CHECK_SC_NPROCESSORS_ONLN
- GLIBCXX_CHECK_SC_NPROC_ONLN
- GLIBCXX_CHECK_PTHREADS_NUM_PROCESSORS_NP
- GLIBCXX_CHECK_SYSCTL_HW_NCPU
--GLIBCXX_CHECK_SDT_H
-+#GLIBCXX_CHECK_SDT_H
- 
- # Check for available headers.
- AC_CHECK_HEADERS([endian.h execinfo.h float.h fp.h ieeefp.h inttypes.h \
--- 
-2.1.4
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0037-pr65779.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0037-pr65779.patch
deleted file mode 100644
index 1424673..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0037-pr65779.patch
+++ /dev/null
@@ -1,173 +0,0 @@
-List-Id: <gcc-patches.gcc.gnu.org>
-List-Archive: <http://gcc.gnu.org/ml/gcc-patches/>
-List-Post: <mailto:gcc-patches at gcc dot gnu dot org>
-List-Help: <mailto:gcc-patches-help at gcc dot gnu dot org>
-Date: Mon, 20 Apr 2015 12:40:49 +0930
-From: Alan Modra <amodra at gmail dot com>
-To: gcc-patches at gcc dot gnu dot org
-Subject: [Patch] pr65779 - [5/6 Regression] undefined local symbol on powerpc
-
-This patch removes bogus debug info left around by shrink-wrapping,
-which on some powerpc targets with just the right register allocation
-led to assembly errors.
-
-Bootstrapped and regression tested powerpc64-linux and x86_64-linux.
-
-https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65779
-
-gcc/
-	PR debug/65779
-	* shrink-wrap.c (insn_uses_reg): New function.
-	(move_insn_for_shrink_wrap): Remove debug insns using regs set
-	by the moved insn.
-gcc/testsuite/
-	* gcc.dg/pr65779.c: New.
-	
-Upstream-Status: Pending (from mailing list, not merged yet)
-
-Index: a/gcc/shrink-wrap.c
-===================================================================
---- a/gcc/shrink-wrap.c.orig
-+++ b/gcc/shrink-wrap.c
-@@ -182,6 +182,21 @@ live_edge_for_reg (basic_block bb, int r
-   return live_edge;
- }
- 
-+static bool
-+insn_uses_reg (rtx_insn *insn, unsigned int regno, unsigned int end_regno)
-+{
-+  df_ref use;
-+
-+  FOR_EACH_INSN_USE (use, insn)
-+    {
-+      rtx reg = DF_REF_REG (use);
-+
-+      if (REG_P (reg) && REGNO (reg) >= regno && REGNO (reg) < end_regno)
-+	return true;
-+    }
-+  return false;
-+}
-+
- /* Try to move INSN from BB to a successor.  Return true on success.
-    USES and DEFS are the set of registers that are used and defined
-    after INSN in BB.  SPLIT_P indicates whether a live edge from BB
-@@ -340,10 +355,15 @@ move_insn_for_shrink_wrap (basic_block b
-       *split_p = true;
-     }
- 
-+  vec<basic_block> live_bbs;
-+  if (MAY_HAVE_DEBUG_INSNS)
-+    live_bbs.create (5);
-   /* At this point we are committed to moving INSN, but let's try to
-      move it as far as we can.  */
-   do
-     {
-+      if (MAY_HAVE_DEBUG_INSNS)
-+	live_bbs.safe_push (bb);
-       live_out = df_get_live_out (bb);
-       live_in = df_get_live_in (next_block);
-       bb = next_block;
-@@ -426,6 +446,34 @@ move_insn_for_shrink_wrap (basic_block b
- 	SET_REGNO_REG_SET (bb_uses, i);
-     }
- 
-+  /* Remove debug insns using regs set by the insn we are moving.  */
-+  if (MAY_HAVE_DEBUG_INSNS)
-+    {
-+      while (!live_bbs.is_empty ())
-+	{
-+	  rtx_insn *dinsn;
-+	  basic_block tmp_bb = live_bbs.pop ();
-+
-+	  FOR_BB_INSNS_REVERSE (tmp_bb, dinsn)
-+	    {
-+	      if (dinsn == insn)
-+		break;
-+	      if (DEBUG_INSN_P (dinsn)
-+		  && insn_uses_reg (dinsn, dregno, end_dregno))
-+		{
-+		  if (*split_p)
-+		    /* If split, then we will be moving insn into a
-+		       newly created block immediately after the entry
-+		       block.  Move the debug info there too.  */
-+		    emit_debug_insn_after (PATTERN (dinsn), bb_note (bb));
-+		  delete_insn (dinsn);
-+		  break;
-+		}
-+	    }
-+	}
-+      live_bbs.release ();
-+    }
-+
-   emit_insn_after (PATTERN (insn), bb_note (bb));
-   delete_insn (insn);
-   return true;
-Index: b/gcc/testsuite/gcc.dg/pr65779.c
-===================================================================
---- /dev/null
-+++ b/gcc/testsuite/gcc.dg/pr65779.c
-@@ -0,0 +1,64 @@
-+/* { dg-do run } */
-+/* { dg-options "-O2 -g" } */
-+/* { dg-additional-options "-mrelocatable" { target powerpc-*-rtems* } } */
-+
-+unsigned long __attribute__ ((noinline))
-+adler32 (unsigned long adler, unsigned char *buf, unsigned int len)
-+{
-+  unsigned long s1 = adler & 0xffff;
-+  unsigned long s2 = (adler >> 16) & 0xffff;
-+  int k;
-+
-+  if (buf == 0)
-+    return 1L;
-+
-+  while (len > 0)
-+    {
-+      k = len < 5552 ? len : 5552;
-+      len -= k;
-+      while (k >= 16)
-+	{
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  s1 += *buf++; s2 += s1;
-+	  k -= 16;
-+	}
-+      if (k != 0)
-+	do
-+	  {
-+	    s1 += *buf++; s2 += s1;
-+	  } while (--k);
-+      s1 &= 0xffffffffUL;
-+      s2 &= 0xffffffffUL;
-+      s1 %= 65521L;
-+      s2 %= 65521L;
-+    }
-+  return (s2 << 16) | s1;
-+}
-+
-+unsigned char buf[] = { 0, 1, 2, 3, 4, 5, 6, 7,
-+			8, 9, 10, 11, 12, 13, 14, 15,
-+			0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87,
-+			0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f,
-+			0x55, 0xaa };
-+int
-+main ()
-+{
-+  unsigned long x = adler32 (0, buf, sizeof buf);
-+  if (x != 0x640409efUL)
-+    __builtin_abort ();
-+  return 0;
-+}
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3.inc
similarity index 70%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2.inc
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3.inc
index a6b385a..9808be1 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3.inc
@@ -2,15 +2,15 @@
 
 # Third digit in PV should be incremented after a minor release
 
-PV = "5.2.0"
+PV = "5.3.0"
 
 #SNAP = "5-20150405"
 
 # BINV should be incremented to a revision after a minor gcc release
 
-BINV = "5.2.0"
+BINV = "5.3.0"
 
-FILESEXTRAPATHS =. "${FILE_DIRNAME}/gcc-5.2:${FILE_DIRNAME}/gcc-5.2/backport:"
+FILESEXTRAPATHS =. "${FILE_DIRNAME}/gcc-5.3:${FILE_DIRNAME}/gcc-5.3/backport:"
 
 DEPENDS =+ "mpfr gmp libmpc zlib"
 NATIVEDEPS = "mpfr-native gmp-native libmpc-native zlib-native"
@@ -26,8 +26,6 @@
 "
 #BASEURI = "http://www.netgull.com/gcc/snapshots/${SNAP}/gcc-${SNAP}.tar.bz2"
 BASEURI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2"
-SRC_URI[md5sum] = "a51bcfeb3da7dd4c623e27207ed43467"
-SRC_URI[sha256sum] = "5f835b04b5f7dd4f4d2dc96190ec1621b8d89f2dc6f638f9f8bc1b1014ba8cad"
 
 SRC_URI = "\
            ${BASEURI} \
@@ -68,15 +66,35 @@
            file://0034-Don-t-search-host-directory-during-relink-if-inst_pr.patch \
            file://0035-Dont-link-the-plugins-with-libgomp-explicitly.patch \
            file://0036-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch \
-           file://0037-pr65779.patch \
-           file://0038-fix-g++-sysroot.patch \
+           file://0037-aarch64-Add-support-for-musl-ldso.patch \
+           file://0038-fix-g-sysroot.patch \
            file://0039-libcc1-fix-libcc1-s-install-path-and-rpath.patch \
-           file://0040-nativesdk-gcc-support.patch \
-           file://0041-handle-target-sysroot-multilib.patch \
-           file://0042-cxxflags-for-build.patch \
-          "
+           file://0040-handle-sysroot-support-for-nativesdk-gcc.patch \
+           file://0041-Search-target-sysroot-gcc-version-specific-dirs-with.patch \
+           file://0042-Fix-various-_FOR_BUILD-and-related-variables.patch \
+           file://0043-libstdc-Support-musl.patch \
+           file://0044-Adding-mmusl-as-a-musl-libc-specifier-and-the-necess.patch \
+           file://0045-Support-for-arm-linux-musl.patch \
+           file://0046-Get-rid-of-ever-broken-fixincludes-on-musl.patch \
+           file://0047-nios2-Define-MUSL_DYNAMIC_LINKER.patch \
+           file://0048-ssp_nonshared.patch \
+           file://0049-Disable-the-weak-reference-logic-in-gthr.h-for-os-ge.patch \
+           file://0050-powerpc-pass-secure-plt-to-the-linker.patch \
+           file://0051-Ignore-fdebug-prefix-map-in-producer-string-by-Danie.patch \
+           file://0052-nios2-use-ret-with-r31.patch \
+           file://0053-expr.c-PR-target-65358-Avoid-clobbering-partial-argu.patch \
+           file://0054-support-ffile-prefix-map.patch \
+           file://0055-Reuse-fdebug-prefix-map-to-replace-ffile-prefix-map.patch \
+           file://0056-Enable-libc-provide-ssp-and-gcc_cv_target_dl_iterate.patch \
+           file://0057-unwind-fix-for-musl.patch \
+           file://0058-fdebug-prefix-map-support-to-remap-relative-path.patch \
+"
 
 BACKPORTS = ""
+
+SRC_URI[md5sum] = "c9616fd448f980259c31de613e575719"
+SRC_URI[sha256sum] = "b84f5592e9218b73dbae612b5253035a7b34a9a1f7688d2e1bfaaf7267d5c4db"
+
 #S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/gcc-${SNAP}"
 S = "${TMPDIR}/work-shared/gcc-${PV}-${PR}/gcc-${PV}"
 B = "${WORKDIR}/gcc-${PV}/build.${HOST_SYS}.${TARGET_SYS}"
@@ -90,6 +108,7 @@
 EXTRA_OECONF_BASE = "\
     ${LTO} \
     --enable-libssp \
+    --enable-libitm \
     --disable-bootstrap \
     --disable-libmudflap \
     --with-system-zlib \
@@ -105,13 +124,14 @@
 EXTRA_OECONF_INITIAL = "\
     --disable-libmudflap \
     --disable-libgomp \
-    --disable-libssp \
+    --disable-libitm \
     --disable-libquadmath \
     --with-system-zlib \
     --disable-lto \
     --disable-plugin \
     --enable-decimal-float=no \
     --without-isl \
+    gcc_cv_libc_provides_ssp=yes \
 "
 
 EXTRA_OECONF_append_libc-uclibc = " --disable-decimal-float "
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
similarity index 84%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
index 2c766f4..1aead96 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0001-gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch
@@ -1,7 +1,7 @@
-From a0fee0cee3d4bd4aab1e3a8e04446f99d918c4ff Mon Sep 17 00:00:00 2001
+From 6029bb338305a5d1403ee23427ed8d58eae1ff53 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:37:11 +0400
-Subject: [PATCH 01/35] gcc-4.3.1: ARCH_FLAGS_FOR_TARGET
+Subject: [PATCH 01/46] gcc-4.3.1: ARCH_FLAGS_FOR_TARGET
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -12,7 +12,7 @@
  2 files changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/configure b/configure
-index 7616f88..50e7cbc 100755
+index a3f66ba..1cba3a9 100755
 --- a/configure
 +++ b/configure
 @@ -7464,7 +7464,7 @@ fi
@@ -25,7 +25,7 @@
   *" newlib "*)
    case " $target_configargs " in
 diff --git a/configure.ac b/configure.ac
-index 8c85a08..f34af7e 100644
+index 987dfab..d3adb95 100644
 --- a/configure.ac
 +++ b/configure.ac
 @@ -3104,7 +3104,7 @@ fi
@@ -38,5 +38,5 @@
   *" newlib "*)
    case " $target_configargs " in
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0002-uclibc-conf.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0002-uclibc-conf.patch
similarity index 93%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0002-uclibc-conf.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0002-uclibc-conf.patch
index 69d33a0..8d6aeb5 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0002-uclibc-conf.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0002-uclibc-conf.patch
@@ -1,7 +1,7 @@
-From 7635248a4c9b51d723d721acaeeb5f2f11957987 Mon Sep 17 00:00:00 2001
+From b67c3a844bccec1766a7ec120e2d18cdcbc5f114 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:38:25 +0400
-Subject: [PATCH 02/35] uclibc-conf
+Subject: [PATCH 02/46] uclibc-conf
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -49,5 +49,5 @@
    need_lib_prefix=no
    need_version=no
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0003-gcc-uclibc-locale-ctype_touplow_t.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0003-gcc-uclibc-locale-ctype_touplow_t.patch
similarity index 95%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0003-gcc-uclibc-locale-ctype_touplow_t.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0003-gcc-uclibc-locale-ctype_touplow_t.patch
index bca254d..bd03263 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0003-gcc-uclibc-locale-ctype_touplow_t.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0003-gcc-uclibc-locale-ctype_touplow_t.patch
@@ -1,7 +1,7 @@
-From 3aee58ad043af33ab00c9cd7bc88f0cade83f236 Mon Sep 17 00:00:00 2001
+From 9bcb3a1848ff0f8990301ca09a25b15c2cf90c6f Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:40:12 +0400
-Subject: [PATCH 03/35] gcc-uclibc-locale-ctype_touplow_t
+Subject: [PATCH 03/46] gcc-uclibc-locale-ctype_touplow_t
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -83,5 +83,5 @@
      // NB: Offsets into ctype<char>::_M_table force a particular size
      // on the mask type. Because of this, we don't use an enum.
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0004-uclibc-locale.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0004-uclibc-locale.patch
similarity index 99%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0004-uclibc-locale.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0004-uclibc-locale.patch
index 03947a7..656265a 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0004-uclibc-locale.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0004-uclibc-locale.patch
@@ -1,7 +1,7 @@
-From 9f73e06315c94629fb902bd94219667cf8307b8f Mon Sep 17 00:00:00 2001
+From bd9dd472d162fc72522f96f70f6391c7c63d2bf7 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:41:39 +0400
-Subject: [PATCH 04/35] uclibc-locale
+Subject: [PATCH 04/46] uclibc-locale
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -38,10 +38,10 @@
  create mode 100644 libstdc++-v3/config/locale/uclibc/time_members.h
 
 diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4
-index a1e301f..0fe9326 100644
+index 826ef86..79cc716 100644
 --- a/libstdc++-v3/acinclude.m4
 +++ b/libstdc++-v3/acinclude.m4
-@@ -1983,6 +1983,9 @@ AC_DEFUN([GLIBCXX_ENABLE_CLOCALE], [
+@@ -2029,6 +2029,9 @@ AC_DEFUN([GLIBCXX_ENABLE_CLOCALE], [
    # Default to "generic".
    if test $enable_clocale_flag = auto; then
      case ${target_os} in
@@ -51,7 +51,7 @@
        linux* | gnu* | kfreebsd*-gnu | knetbsd*-gnu)
  	enable_clocale_flag=gnu
  	;;
-@@ -2167,6 +2170,40 @@ AC_DEFUN([GLIBCXX_ENABLE_CLOCALE], [
+@@ -2213,6 +2216,40 @@ AC_DEFUN([GLIBCXX_ENABLE_CLOCALE], [
        CTIME_CC=config/locale/generic/time_members.cc
        CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h
        ;;
@@ -2737,10 +2737,10 @@
 +      _S_destroy_c_locale(_M_c_locale_timepunct);
 +    }
 diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
-index f5b28f4..fbad667 100755
+index 8cd4c76..217012e 100755
 --- a/libstdc++-v3/configure
 +++ b/libstdc++-v3/configure
-@@ -15913,6 +15913,9 @@ fi
+@@ -15918,6 +15918,9 @@ fi
    # Default to "generic".
    if test $enable_clocale_flag = auto; then
      case ${target_os} in
@@ -2750,7 +2750,7 @@
        linux* | gnu* | kfreebsd*-gnu | knetbsd*-gnu)
  	enable_clocale_flag=gnu
  	;;
-@@ -16191,6 +16194,78 @@ $as_echo "newlib" >&6; }
+@@ -16196,6 +16199,78 @@ $as_echo "newlib" >&6; }
        CTIME_CC=config/locale/generic/time_members.cc
        CLOCALE_INTERNAL_H=config/locale/generic/c++locale_internal.h
        ;;
@@ -2858,5 +2858,5 @@
    using ::wcsncat;
    using ::wcsncmp;
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0005-uclibc-locale-no__x.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0005-uclibc-locale-no__x.patch
similarity index 98%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0005-uclibc-locale-no__x.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0005-uclibc-locale-no__x.patch
index ac053ea..19a86a4 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0005-uclibc-locale-no__x.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0005-uclibc-locale-no__x.patch
@@ -1,7 +1,7 @@
-From a8e683917a3e8a6642639e65c06d4d4fc46cc8ab Mon Sep 17 00:00:00 2001
+From 72a1a4af3c18627f59aa5ba1f753a89011b4e4f0 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:42:36 +0400
-Subject: [PATCH 05/35] uclibc-locale-no__x
+Subject: [PATCH 05/46] uclibc-locale-no__x
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -253,5 +253,5 @@
  namespace std
  {
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0006-uclibc-locale-wchar_fix.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0006-uclibc-locale-wchar_fix.patch
similarity index 95%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0006-uclibc-locale-wchar_fix.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0006-uclibc-locale-wchar_fix.patch
index 9112a2b..d7dbe68 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0006-uclibc-locale-wchar_fix.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0006-uclibc-locale-wchar_fix.patch
@@ -1,7 +1,7 @@
-From cdb9e9c9440beb59bc20476eea5a9cf2538cd194 Mon Sep 17 00:00:00 2001
+From b1298344f0c221c382a95af689f7f3ecd864f531 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:45:57 +0400
-Subject: [PATCH 06/35] uclibc-locale-wchar_fix
+Subject: [PATCH 06/46] uclibc-locale-wchar_fix
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -64,5 +64,5 @@
  	  if (_M_data->_M_thousands_sep == L'\0')
  	    _M_data->_M_grouping = "";
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0007-uclibc-locale-update.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0007-uclibc-locale-update.patch
similarity index 99%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0007-uclibc-locale-update.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0007-uclibc-locale-update.patch
index 728b790..cde7499 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0007-uclibc-locale-update.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0007-uclibc-locale-update.patch
@@ -1,7 +1,7 @@
-From 244b9d1b5cc6d5382935192998531ee70afb262d Mon Sep 17 00:00:00 2001
+From e9d7cb62741c22d667fe56e98d50753d89aefdc3 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:46:58 +0400
-Subject: [PATCH 07/35] uclibc-locale-update
+Subject: [PATCH 07/46] uclibc-locale-update
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -538,5 +538,5 @@
  
    template<typename _CharT>
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0008-missing-execinfo_h.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0008-missing-execinfo_h.patch
similarity index 87%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0008-missing-execinfo_h.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0008-missing-execinfo_h.patch
index b2f6b18..9f87931 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0008-missing-execinfo_h.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0008-missing-execinfo_h.patch
@@ -1,7 +1,7 @@
-From 0a80f60de08bd5829ca1b3758f70a92b61dda143 Mon Sep 17 00:00:00 2001
+From 9b7442069eb68a42d2437181c1b2e710dd077e8b Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:48:10 +0400
-Subject: [PATCH 08/35] missing-execinfo_h
+Subject: [PATCH 08/46] missing-execinfo_h
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -24,5 +24,5 @@
  #     define GC_HAVE_BUILTIN_BACKTRACE
  #   endif
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0009-c99-snprintf.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0009-c99-snprintf.patch
similarity index 85%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0009-c99-snprintf.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0009-c99-snprintf.patch
index 525b2a1..6b236c6 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0009-c99-snprintf.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0009-c99-snprintf.patch
@@ -1,7 +1,7 @@
-From 7b7caf4305a54fa4dfdd0efd5bd41cb94cbcf43d Mon Sep 17 00:00:00 2001
+From fde97f80d2d931ed3fa4a86294799366b2359331 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:49:03 +0400
-Subject: [PATCH 09/35] c99-snprintf
+Subject: [PATCH 09/46] c99-snprintf
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -24,5 +24,5 @@
  #undef snprintf
  #undef vfscanf
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0010-gcc-poison-system-directories.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0010-gcc-poison-system-directories.patch
similarity index 91%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0010-gcc-poison-system-directories.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0010-gcc-poison-system-directories.patch
index 4e02ef8..2da8877 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0010-gcc-poison-system-directories.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0010-gcc-poison-system-directories.patch
@@ -1,7 +1,7 @@
-From d1e85a363ffcd259e9b0841b85ca10af2f31bd72 Mon Sep 17 00:00:00 2001
+From 7a90e62d557c78ae52006dff30c99006e10d9357 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 08:59:00 +0400
-Subject: [PATCH 10/35] gcc: poison-system-directories
+Subject: [PATCH 10/46] gcc: poison-system-directories
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
@@ -17,7 +17,7 @@
  7 files changed, 66 insertions(+)
 
 diff --git a/gcc/common.opt b/gcc/common.opt
-index b49ac46..783d231 100644
+index 1218a71..bfba114 100644
 --- a/gcc/common.opt
 +++ b/gcc/common.opt
 @@ -623,6 +623,10 @@ Wreturn-local-addr
@@ -32,7 +32,7 @@
  Common Var(warn_shadow) Warning
  Warn when one local variable shadows another
 diff --git a/gcc/config.in b/gcc/config.in
-index f2ed301..f290c6b 100644
+index 5335258..f079826 100644
 --- a/gcc/config.in
 +++ b/gcc/config.in
 @@ -168,6 +168,12 @@
@@ -49,10 +49,10 @@
     optimizer and back end) to be checked for dynamic type safety at runtime.
     This is quite expensive. */
 diff --git a/gcc/configure b/gcc/configure
-index 9523773..181748e 100755
+index 3c92795..34371a3 100755
 --- a/gcc/configure
 +++ b/gcc/configure
-@@ -932,6 +932,7 @@ with_system_zlib
+@@ -933,6 +933,7 @@ with_system_zlib
  enable_maintainer_mode
  enable_link_mutex
  enable_version_specific_runtime_libs
@@ -60,7 +60,7 @@
  enable_plugin
  enable_host_shared
  enable_libquadmath_support
-@@ -1661,6 +1662,8 @@ Optional Features:
+@@ -1670,6 +1671,8 @@ Optional Features:
    --enable-version-specific-runtime-libs
                            specify that runtime libraries should be installed
                            in a compiler-specific directory
@@ -69,7 +69,7 @@
    --enable-plugin         enable plugin support
    --enable-host-shared    build host code as shared libraries
    --disable-libquadmath-support
-@@ -28087,6 +28090,19 @@ if test "${enable_version_specific_runtime_libs+set}" = set; then :
+@@ -28211,6 +28214,19 @@ if test "${enable_version_specific_runtime_libs+set}" = set; then :
  fi
  
  
@@ -90,10 +90,10 @@
  
  
 diff --git a/gcc/configure.ac b/gcc/configure.ac
-index 68b0ee8..8b07078 100644
+index d414081..240d322 100644
 --- a/gcc/configure.ac
 +++ b/gcc/configure.ac
-@@ -5571,6 +5571,16 @@ AC_ARG_ENABLE(version-specific-runtime-libs,
+@@ -5654,6 +5654,16 @@ AC_ARG_ENABLE(version-specific-runtime-libs,
                  [specify that runtime libraries should be
                   installed in a compiler-specific directory])])
  
@@ -111,7 +111,7 @@
  AC_SUBST(subdirs)
  AC_SUBST(srcdir)
 diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
-index 520c2c5..0df8a47 100644
+index d3be589..c81b55b 100644
 --- a/gcc/doc/invoke.texi
 +++ b/gcc/doc/invoke.texi
 @@ -269,6 +269,7 @@ Objective-C and Objective-C++ Dialects}.
@@ -122,7 +122,7 @@
  -Wredundant-decls  -Wno-return-local-addr @gol
  -Wreturn-type  -Wsequence-point  -Wshadow  -Wno-shadow-ivar @gol
  -Wshift-count-negative -Wshift-count-overflow @gol
-@@ -4432,6 +4433,14 @@ made up of data only and thus requires no special treatment.  But, for
+@@ -4433,6 +4434,14 @@ made up of data only and thus requires no special treatment.  But, for
  most targets, it is made up of code and thus requires the stack to be
  made executable in order for the program to work properly.
  
@@ -188,5 +188,5 @@
  
  /* Use given -I paths for #include "..." but not #include <...>, and
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0011-gcc-poison-dir-extend.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0011-gcc-poison-dir-extend.patch
similarity index 92%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0011-gcc-poison-dir-extend.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0011-gcc-poison-dir-extend.patch
index 067d985..511e694 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0011-gcc-poison-dir-extend.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0011-gcc-poison-dir-extend.patch
@@ -1,7 +1,7 @@
-From f158fcc084e88b1d8d1ecf5b005d377765aef16e Mon Sep 17 00:00:00 2001
+From db406054de6b0967cd76cbb998f05b0c5af0bd94 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:00:34 +0400
-Subject: [PATCH 11/35] gcc-poison-dir-extend
+Subject: [PATCH 11/46] gcc-poison-dir-extend
 
 Add /sw/include and /opt/include based on the original
 zecke-no-host-includes.patch patch.  The original patch checked for
@@ -35,5 +35,5 @@
                       "include location \"%s\" is unsafe for "
                       "cross-compilation",
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0012-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0012-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
similarity index 94%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0012-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0012-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
index befca73..750bbc8 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0012-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0012-gcc-4.3.3-SYSROOT_CFLAGS_FOR_TARGET.patch
@@ -1,7 +1,7 @@
-From a54239cbdc6f93c6d74ea6b078f1470770c4f5aa Mon Sep 17 00:00:00 2001
+From 278d293c4cee9482a23aa3443741861ff2f67212 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:08:31 +0400
-Subject: [PATCH 12/35] gcc-4.3.3: SYSROOT_CFLAGS_FOR_TARGET
+Subject: [PATCH 12/46] gcc-4.3.3: SYSROOT_CFLAGS_FOR_TARGET
 
 Before committing, I noticed that PR/32161 was marked as a dup of PR/32009, but my previous patch did not fix it.
 
@@ -26,7 +26,7 @@
  1 file changed, 32 insertions(+)
 
 diff --git a/configure b/configure
-index 50e7cbc..6b97693 100755
+index 1cba3a9..9cae8da 100755
 --- a/configure
 +++ b/configure
 @@ -6733,6 +6733,38 @@ fi
@@ -69,5 +69,5 @@
  # the named directory are copied to $(tooldir)/sys-include.
  if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0013-64-bit-multilib-hack.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0013-64-bit-multilib-hack.patch
similarity index 96%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0013-64-bit-multilib-hack.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0013-64-bit-multilib-hack.patch
index 67c0661..45aaf4c 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0013-64-bit-multilib-hack.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0013-64-bit-multilib-hack.patch
@@ -1,7 +1,7 @@
-From d5151bebd079e981dc710f2a031830d89cb1e72e Mon Sep 17 00:00:00 2001
+From bdde4f5efa3c89ac7ee0bc05f322f27e3dabeab9 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:10:06 +0400
-Subject: [PATCH 13/35] 64-bit multilib hack.
+Subject: [PATCH 13/46] 64-bit multilib hack.
 
 GCC has internal multilib handling code but it assumes a very specific rigid directory
 layout. The build system implementation of multilib layout is very generic and allows
@@ -81,5 +81,5 @@
  rs6000-linux.o: $(srcdir)/config/rs6000/rs6000-linux.c
  	$(COMPILE) $<
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0014-optional-libstdc.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0014-optional-libstdc.patch
similarity index 93%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0014-optional-libstdc.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0014-optional-libstdc.patch
index 374fe43..73741f8 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0014-optional-libstdc.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0014-optional-libstdc.patch
@@ -1,7 +1,7 @@
-From d7b42d93d077b2523c26f0dff0b6c44fdfff9d3c Mon Sep 17 00:00:00 2001
+From a13763f8a1d413a432e7b40835a062f86208f29a Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:12:56 +0400
-Subject: [PATCH 14/35] optional libstdc
+Subject: [PATCH 14/46] optional libstdc
 
 gcc-runtime builds libstdc++ separately from gcc-cross-*. Its configure tests using g++
 will not run correctly since by default the linker will try to link against libstdc++
@@ -25,7 +25,7 @@
  4 files changed, 13 insertions(+), 1 deletion(-)
 
 diff --git a/gcc/c-family/c.opt b/gcc/c-family/c.opt
-index 983f4a8..96924f6 100644
+index 4162566..453ec8e 100644
 --- a/gcc/c-family/c.opt
 +++ b/gcc/c-family/c.opt
 @@ -1543,6 +1543,10 @@ nostdinc++
@@ -52,7 +52,7 @@
  	  library = -1;
  	  break;
 diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
-index 0df8a47..73856d0 100644
+index c81b55b..6d3f68c 100644
 --- a/gcc/doc/invoke.texi
 +++ b/gcc/doc/invoke.texi
 @@ -195,6 +195,7 @@ in the following sections.
@@ -72,7 +72,7 @@
  -T @var{script}  -Wl,@var{option}  -Xlinker @var{option} @gol
  -u @var{symbol} -z @var{keyword}}
  
-@@ -11185,6 +11186,11 @@ These entries are usually resolved by entries in
+@@ -11187,6 +11188,11 @@ These entries are usually resolved by entries in
  libc.  These entry points should be supplied through some other
  mechanism when this option is specified.
  
@@ -97,5 +97,5 @@
  #endif
  
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0015-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0015-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
similarity index 85%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0015-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0015-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
index 6cf1e3d..1b62ef8 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0015-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0015-gcc-disable-MASK_RELAX_PIC_CALLS-bit.patch
@@ -1,7 +1,7 @@
-From ad1592791698286b80626ddd5679ff2ef457ab76 Mon Sep 17 00:00:00 2001
+From 4bd21a1d63cfb14e261d90adc0c5d4f9462dc555 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:14:20 +0400
-Subject: [PATCH 15/35] gcc: disable MASK_RELAX_PIC_CALLS bit
+Subject: [PATCH 15/46] gcc: disable MASK_RELAX_PIC_CALLS bit
 
 The new feature added after 4.3.3
 "http://www.pubbs.net/200909/gcc/94048-patch-add-support-for-rmipsjalr.html"
@@ -19,10 +19,10 @@
  2 files changed, 14 deletions(-)
 
 diff --git a/gcc/configure b/gcc/configure
-index 181748e..9009064 100755
+index 34371a3..8caecdc 100755
 --- a/gcc/configure
 +++ b/gcc/configure
-@@ -26451,13 +26451,6 @@ $as_echo_n "checking assembler and linker for explicit JALR relocation... " >&6;
+@@ -26479,13 +26479,6 @@ $as_echo_n "checking assembler and linker for explicit JALR relocation... " >&6;
          rm -f conftest.*
        fi
      fi
@@ -37,10 +37,10 @@
  $as_echo "$gcc_cv_as_ld_jalr_reloc" >&6; }
  
 diff --git a/gcc/configure.ac b/gcc/configure.ac
-index 8b07078..c7a28b4 100644
+index 240d322..57819ff 100644
 --- a/gcc/configure.ac
 +++ b/gcc/configure.ac
-@@ -4361,13 +4361,6 @@ x:
+@@ -4384,13 +4384,6 @@ x:
          rm -f conftest.*
        fi
      fi
@@ -55,5 +55,5 @@
  
      AC_CACHE_CHECK([linker for .eh_frame personality relaxation],
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0016-COLLECT_GCC_OPTIONS.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0016-COLLECT_GCC_OPTIONS.patch
similarity index 89%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0016-COLLECT_GCC_OPTIONS.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0016-COLLECT_GCC_OPTIONS.patch
index 359de35..e6ae262 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0016-COLLECT_GCC_OPTIONS.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0016-COLLECT_GCC_OPTIONS.patch
@@ -1,7 +1,7 @@
-From 2b22ee2e44688f8a72b9af76a0431d86bac00d47 Mon Sep 17 00:00:00 2001
+From 92427ebb94dc66f8e64ebf3ffbcd6dd5ce0935c1 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:16:28 +0400
-Subject: [PATCH 16/35] COLLECT_GCC_OPTIONS
+Subject: [PATCH 16/46] COLLECT_GCC_OPTIONS
 
 This patch adds --sysroot into COLLECT_GCC_OPTIONS which is used to
 invoke collect2.
@@ -34,5 +34,5 @@
      {
        const char *const *args;
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0017-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0017-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
similarity index 91%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0017-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0017-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
index 8506131..b89a279 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0017-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0017-Use-the-defaults.h-in-B-instead-of-S-and-t-oe-in-B.patch
@@ -1,7 +1,7 @@
-From 12f467bc6d8953ba342fe5166b9a2f397b334794 Mon Sep 17 00:00:00 2001
+From b1f3118e439459c26a3e19c617b7b0c93745e77a Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:17:25 +0400
-Subject: [PATCH 17/35] Use the defaults.h in ${B} instead of ${S}, and t-oe in
+Subject: [PATCH 17/46] Use the defaults.h in ${B} instead of ${S}, and t-oe in
  ${B}
 
 Use the defaults.h in ${B} instead of ${S}, and t-oe in ${B}, so that
@@ -27,7 +27,7 @@
  4 files changed, 7 insertions(+), 7 deletions(-)
 
 diff --git a/gcc/Makefile.in b/gcc/Makefile.in
-index 4ab7405..661ae17 100644
+index 07c6f0a..e1e63e8 100644
 --- a/gcc/Makefile.in
 +++ b/gcc/Makefile.in
 @@ -502,7 +502,7 @@ TARGET_SYSTEM_ROOT = @TARGET_SYSTEM_ROOT@
@@ -40,10 +40,10 @@
  TM_MULTILIB_CONFIG=@TM_MULTILIB_CONFIG@
  TM_MULTILIB_EXCEPTIONS_CONFIG=@TM_MULTILIB_EXCEPTIONS_CONFIG@
 diff --git a/gcc/configure b/gcc/configure
-index 9009064..f059c2f 100755
+index 8caecdc..8ec3d40 100755
 --- a/gcc/configure
 +++ b/gcc/configure
-@@ -11841,8 +11841,8 @@ for f in $tm_file; do
+@@ -11850,8 +11850,8 @@ for f in $tm_file; do
         tm_include_list="${tm_include_list} $f"
         ;;
      defaults.h )
@@ -55,7 +55,7 @@
      * )
         tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
 diff --git a/gcc/configure.ac b/gcc/configure.ac
-index c7a28b4..2e668a5 100644
+index 57819ff..643a47e 100644
 --- a/gcc/configure.ac
 +++ b/gcc/configure.ac
 @@ -1832,8 +1832,8 @@ for f in $tm_file; do
@@ -92,5 +92,5 @@
  
  # Add multiple inclusion protection guard, part two.
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0018-fortran-cross-compile-hack.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0018-fortran-cross-compile-hack.patch
similarity index 87%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0018-fortran-cross-compile-hack.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0018-fortran-cross-compile-hack.patch
index da73392..e8ba325 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0018-fortran-cross-compile-hack.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0018-fortran-cross-compile-hack.patch
@@ -1,7 +1,7 @@
-From 95506b44c9ef4725fef52fa864d3d3fcf931e443 Mon Sep 17 00:00:00 2001
+From d11c73c1295565ff3766ae04e2a410a89fc84dd5 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:20:01 +0400
-Subject: [PATCH 18/35] fortran cross-compile hack.
+Subject: [PATCH 18/46] fortran cross-compile hack.
 
 * Fortran would have searched for arm-angstrom-gnueabi-gfortran but would have used
 used gfortan. For gcc_4.2.2.bb we want to use the gfortran compiler from our cross
@@ -16,7 +16,7 @@
  2 files changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/libgfortran/configure b/libgfortran/configure
-index e1592f7..76d19b3 100755
+index bb3107b..5d47e65 100755
 --- a/libgfortran/configure
 +++ b/libgfortran/configure
 @@ -12747,7 +12747,7 @@ esac
@@ -29,7 +29,7 @@
  ac_compile='$FC -c $FCFLAGS $ac_fcflags_srcext conftest.$ac_ext >&5'
  ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $ac_fcflags_srcext conftest.$ac_ext $LIBS >&5'
 diff --git a/libgfortran/configure.ac b/libgfortran/configure.ac
-index 35a8b39..6a0d8a9 100644
+index adafb3f..b4ade28 100644
 --- a/libgfortran/configure.ac
 +++ b/libgfortran/configure.ac
 @@ -240,7 +240,7 @@ AC_SUBST(enable_static)
@@ -42,5 +42,5 @@
  
  # extra LD Flags which are required for targets
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0019-libgcc-sjlj-check.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0019-libgcc-sjlj-check.patch
similarity index 92%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0019-libgcc-sjlj-check.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0019-libgcc-sjlj-check.patch
index ec5394a..01a4d1f 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0019-libgcc-sjlj-check.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0019-libgcc-sjlj-check.patch
@@ -1,7 +1,7 @@
-From 94f619cd3257e35e20a877640d0cb90c2b3efc15 Mon Sep 17 00:00:00 2001
+From 7b40212ed6c0c9fe4efe51f31bccd3d9f892f238 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:20:50 +0400
-Subject: [PATCH 19/35] libgcc-sjlj-check
+Subject: [PATCH 19/46] libgcc-sjlj-check
 
 ac_fn_c_try_compile doesnt seem to keep the intermediate files
 which are needed for sjlj test to pass since it greps into the
@@ -17,7 +17,7 @@
  2 files changed, 10 insertions(+), 10 deletions(-)
 
 diff --git a/libgcc/configure b/libgcc/configure
-index 08c9319..5ffaeb3 100644
+index 203d384..6aef3e7 100644
 --- a/libgcc/configure
 +++ b/libgcc/configure
 @@ -4570,17 +4570,19 @@ void foo ()
@@ -45,7 +45,7 @@
  
  fi
 diff --git a/libgcc/configure.ac b/libgcc/configure.ac
-index 1c405e8..f52975d 100644
+index a10a952..cc324f3 100644
 --- a/libgcc/configure.ac
 +++ b/libgcc/configure.ac
 @@ -255,16 +255,14 @@ void foo ()
@@ -70,5 +70,5 @@
  ])
  
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0020-cpp-honor-sysroot.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0020-cpp-honor-sysroot.patch
similarity index 94%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0020-cpp-honor-sysroot.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0020-cpp-honor-sysroot.patch
index 71bc68b..13f66d4 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0020-cpp-honor-sysroot.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0020-cpp-honor-sysroot.patch
@@ -1,7 +1,7 @@
-From 6e6283d645c83ca534219a02ae882a3d7be95ff1 Mon Sep 17 00:00:00 2001
+From 5f9759a85fff3d78e3f71ae01c970b10d326c406 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:22:00 +0400
-Subject: [PATCH 20/35] cpp: honor sysroot.
+Subject: [PATCH 20/46] cpp: honor sysroot.
 
 Currently, if the gcc toolchain is relocated and installed from sstate, then you try and compile
 preprocessed source (.i or .ii files), the compiler will try and access the builtin sysroot location
@@ -50,5 +50,5 @@
    {"@assembler",
     "%{!M:%{!MM:%{!E:%{!S:as %(asm_debug) %(asm_options) %i %A }}}}", 0, 0, 0},
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0021-MIPS64-Default-to-N64-ABI.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0021-MIPS64-Default-to-N64-ABI.patch
similarity index 85%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0021-MIPS64-Default-to-N64-ABI.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0021-MIPS64-Default-to-N64-ABI.patch
index caad489..c7cffe4 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0021-MIPS64-Default-to-N64-ABI.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0021-MIPS64-Default-to-N64-ABI.patch
@@ -1,7 +1,7 @@
-From 7f766fc47f9388dd0094852a43f1af2568b4b9b2 Mon Sep 17 00:00:00 2001
+From 34d22ab6cfd2dfe6dd171c8d0b31cafcdeb86298 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:23:08 +0400
-Subject: [PATCH 21/35] MIPS64: Default to N64 ABI
+Subject: [PATCH 21/46] MIPS64: Default to N64 ABI
 
 MIPS64 defaults to n32 ABI, this patch makes it
 so that it defaults to N64 ABI
@@ -14,10 +14,10 @@
  1 file changed, 5 insertions(+), 5 deletions(-)
 
 diff --git a/gcc/config.gcc b/gcc/config.gcc
-index cb08a5c..b155744 100644
+index c835734..dd0739d 100644
 --- a/gcc/config.gcc
 +++ b/gcc/config.gcc
-@@ -2011,29 +2011,29 @@ mips*-*-linux*)				# Linux MIPS, either endian.
+@@ -2017,29 +2017,29 @@ mips*-*-linux*)				# Linux MIPS, either endian.
  			default_mips_arch=mips32
  			;;
  		mips64el-st-linux-gnu)
@@ -53,5 +53,5 @@
  			;;
  	esac
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0022-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0022-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
similarity index 98%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0022-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0022-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
index 54520d0..6208351 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0022-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0022-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch
@@ -1,7 +1,7 @@
-From 4f94added8b7043642386b31ed4c3a1bd016f316 Mon Sep 17 00:00:00 2001
+From f6b41b62ea62a0f1447d9fc235f7fd2bbf3fe7c2 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:24:50 +0400
-Subject: [PATCH 22/35] Define GLIBC_DYNAMIC_LINKER and UCLIBC_DYNAMIC_LINKER
+Subject: [PATCH 22/46] Define GLIBC_DYNAMIC_LINKER and UCLIBC_DYNAMIC_LINKER
  relative to SYSTEMLIBS_DIR
 
 This patch defines GLIBC_DYNAMIC_LINKER and UCLIBC_DYNAMIC_LINKER
@@ -60,7 +60,7 @@
  
  #define GLIBC_DYNAMIC_LINKER \
 diff --git a/gcc/config/arm/linux-elf.h b/gcc/config/arm/linux-elf.h
-index 1279cba..1dde747 100644
+index 49ad954..a5ab559 100644
 --- a/gcc/config/arm/linux-elf.h
 +++ b/gcc/config/arm/linux-elf.h
 @@ -62,7 +62,7 @@
@@ -212,5 +212,5 @@
  #ifdef SPARC_BI_ARCH
  
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0023-gcc-Fix-argument-list-too-long-error.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0023-gcc-Fix-argument-list-too-long-error.patch
similarity index 85%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0023-gcc-Fix-argument-list-too-long-error.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0023-gcc-Fix-argument-list-too-long-error.patch
index b337df5..be91c9e 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0023-gcc-Fix-argument-list-too-long-error.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0023-gcc-Fix-argument-list-too-long-error.patch
@@ -1,7 +1,7 @@
-From 8db606205487ebb03eae788826faf64bd6918450 Mon Sep 17 00:00:00 2001
+From 9701f596bbe5bf51bbf48661bc515b45d4b6f4d2 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:26:37 +0400
-Subject: [PATCH 23/35] gcc: Fix argument list too long error.
+Subject: [PATCH 23/46] gcc: Fix argument list too long error.
 
 There would be an "Argument list too long" error when the
 build directory is longer than 200, this is caused by:
@@ -23,10 +23,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/gcc/Makefile.in b/gcc/Makefile.in
-index 661ae17..9470a92 100644
+index e1e63e8..7b49f88 100644
 --- a/gcc/Makefile.in
 +++ b/gcc/Makefile.in
-@@ -3255,7 +3255,7 @@ install-plugin: installdirs lang.install-plugin s-header-vars install-gengtype
+@@ -3262,7 +3262,7 @@ install-plugin: installdirs lang.install-plugin s-header-vars install-gengtype
  # We keep the directory structure for files in config or c-family and .def
  # files. All other files are flattened to a single directory.
  	$(mkinstalldirs) $(DESTDIR)$(plugin_includedir)
@@ -36,5 +36,5 @@
  	for file in $$headers; do \
  	  if [ -f $$file ] ; then \
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0031-Disable-sdt.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0024-Disable-sdt.patch
similarity index 88%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0031-Disable-sdt.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0024-Disable-sdt.patch
index 2c1d5e0..b23ce97 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.8/0031-Disable-sdt.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0024-Disable-sdt.patch
@@ -1,7 +1,7 @@
-From b85265bc94ec1beaf1d3b697c03db62991553467 Mon Sep 17 00:00:00 2001
+From 946e047614103e1f2982613c7aa5f76587500c0e Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:28:10 +0400
-Subject: [PATCH 31/35] Disable sdt.
+Subject: [PATCH 24/46] Disable sdt.
 
 We don't list dtrace in DEPENDS so we shouldn't be depending on this header.
 It may or may not exist from preivous builds though. To be determinstic, disable
@@ -25,10 +25,10 @@
  4 files changed, 19 insertions(+), 19 deletions(-)
 
 diff --git a/gcc/configure b/gcc/configure
-index 3c550a6..01c7626 100755
+index 8ec3d40..eaa3b07 100755
 --- a/gcc/configure
 +++ b/gcc/configure
-@@ -26812,12 +26812,12 @@ fi
+@@ -27857,12 +27857,12 @@ fi
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking sys/sdt.h in the target C library" >&5
  $as_echo_n "checking sys/sdt.h in the target C library... " >&6; }
  have_sys_sdt_h=no
@@ -48,10 +48,10 @@
  $as_echo "$have_sys_sdt_h" >&6; }
  
 diff --git a/gcc/configure.ac b/gcc/configure.ac
-index 3601ab6..06e501f 100644
+index 643a47e..9f6cacb 100644
 --- a/gcc/configure.ac
 +++ b/gcc/configure.ac
-@@ -4779,15 +4779,15 @@ if test x$gcc_cv_libc_provides_ssp = xyes; then
+@@ -5315,15 +5315,15 @@ if test x$gcc_cv_libc_provides_ssp = xyes; then
  fi
  
  # Test for <sys/sdt.h> on the target.
@@ -77,10 +77,10 @@
  # Check if TFmode long double should be used by default or not.
  # Some glibc targets used DFmode long double, but with glibc 2.4
 diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
-index 4953c9f..53a1145 100755
+index 217012e..81240b9 100755
 --- a/libstdc++-v3/configure
 +++ b/libstdc++-v3/configure
-@@ -20578,11 +20578,11 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+@@ -20964,11 +20964,11 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  ac_compiler_gnu=$ac_cv_c_compiler_gnu
  
@@ -96,10 +96,10 @@
  $as_echo "$glibcxx_cv_sys_sdt_h" >&6; }
  
 diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac
-index 73d430a..f2135e2 100644
+index 580fb8b..5a41083 100644
 --- a/libstdc++-v3/configure.ac
 +++ b/libstdc++-v3/configure.ac
-@@ -211,7 +211,7 @@ GLIBCXX_CHECK_SC_NPROCESSORS_ONLN
+@@ -230,7 +230,7 @@ GLIBCXX_CHECK_SC_NPROCESSORS_ONLN
  GLIBCXX_CHECK_SC_NPROC_ONLN
  GLIBCXX_CHECK_PTHREADS_NUM_PROCESSORS_NP
  GLIBCXX_CHECK_SYSCTL_HW_NCPU
@@ -109,5 +109,5 @@
  # Check for available headers.
  AC_CHECK_HEADERS([endian.h execinfo.h float.h fp.h ieeefp.h inttypes.h \
 -- 
-1.8.3.1
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0025-libtool.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0025-libtool.patch
similarity index 91%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0025-libtool.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0025-libtool.patch
index b8977d6..8d5eb97 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0025-libtool.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0025-libtool.patch
@@ -1,7 +1,7 @@
-From 1ca54967d8f67ab0eca772334e5c925a5e8c80cc Mon Sep 17 00:00:00 2001
+From f68c5b78751660505b22b46dad99240db0df3456 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:29:11 +0400
-Subject: [PATCH 25/35] libtool
+Subject: [PATCH 25/46] libtool
 
 libstdc++ from gcc-runtime gets created with -rpath=/usr/lib/../lib for qemux86-64
 when running on am x86_64 build host.
@@ -38,5 +38,5 @@
        oldlibs=
        if test -z "$rpath"; then
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0026-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0026-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
similarity index 91%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0026-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0026-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
index a8a652a..a22d95f 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0026-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0026-gcc-armv4-pass-fix-v4bx-to-linker-to-support-EABI.patch
@@ -1,7 +1,7 @@
-From 5f5ca57fcec4bafe3780371d1342acd40c608697 Mon Sep 17 00:00:00 2001
+From 4c75e349aa7abd1e285720328b23690636bea242 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:30:32 +0400
-Subject: [PATCH 26/35] gcc: armv4: pass fix-v4bx to linker to support EABI.
+Subject: [PATCH 26/46] gcc: armv4: pass fix-v4bx to linker to support EABI.
 
 The LINK_SPEC for linux gets overwritten by linux-eabi.h which
 means the value of TARGET_FIX_V4BX_SPEC gets lost and as a result
@@ -39,5 +39,5 @@
  		       LINUX_TARGET_LINK_SPEC " " ANDROID_LINK_SPEC)
  
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0027-Use-the-multilib-config-files-from-B-instead-of-usin.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0027-Use-the-multilib-config-files-from-B-instead-of-usin.patch
similarity index 89%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0027-Use-the-multilib-config-files-from-B-instead-of-usin.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0027-Use-the-multilib-config-files-from-B-instead-of-usin.patch
index 445da37..46815d1 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0027-Use-the-multilib-config-files-from-B-instead-of-usin.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0027-Use-the-multilib-config-files-from-B-instead-of-usin.patch
@@ -1,7 +1,7 @@
-From 484e8c1e8d43e626ee2ddbde9eb8e0af7a176aef Mon Sep 17 00:00:00 2001
+From 8217dd7fb318f9abc6564f67b424c433d8398d61 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 29 Mar 2013 09:33:04 +0400
-Subject: [PATCH 27/35] Use the multilib config files from ${B} instead of
+Subject: [PATCH 27/46] Use the multilib config files from ${B} instead of
  using the ones from ${S}
 
 Use the multilib config files from ${B} instead of using the ones from ${S}
@@ -18,10 +18,10 @@
  2 files changed, 36 insertions(+), 8 deletions(-)
 
 diff --git a/gcc/configure b/gcc/configure
-index 98853b3..d0ec50f 100755
+index eaa3b07..9b60aad 100755
 --- a/gcc/configure
 +++ b/gcc/configure
-@@ -11821,10 +11821,20 @@ done
+@@ -11830,10 +11830,20 @@ done
  tmake_file_=
  for f in ${tmake_file}
  do
@@ -46,7 +46,7 @@
  done
  tmake_file="${tmake_file_}"
  
-@@ -11835,6 +11845,10 @@ tm_file_list="options.h"
+@@ -11844,6 +11854,10 @@ tm_file_list="options.h"
  tm_include_list="options.h insn-constants.h"
  for f in $tm_file; do
    case $f in
@@ -58,7 +58,7 @@
         f=`echo $f | sed 's/^..//'`
         tm_file_list="${tm_file_list} $f"
 diff --git a/gcc/configure.ac b/gcc/configure.ac
-index 52cdcb8..3cf606a 100644
+index 9f6cacb..e1e54f2 100644
 --- a/gcc/configure.ac
 +++ b/gcc/configure.ac
 @@ -1812,10 +1812,20 @@ done
@@ -98,5 +98,5 @@
         f=`echo $f | sed 's/^..//'`
         tm_file_list="${tm_file_list} $f"
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0028-Avoid-using-libdir-from-.la-which-usually-points-to-.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0028-Avoid-using-libdir-from-.la-which-usually-points-to-.patch
similarity index 84%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0028-Avoid-using-libdir-from-.la-which-usually-points-to-.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0028-Avoid-using-libdir-from-.la-which-usually-points-to-.patch
index 4902e90..60ddd9c 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0028-Avoid-using-libdir-from-.la-which-usually-points-to-.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0028-Avoid-using-libdir-from-.la-which-usually-points-to-.patch
@@ -1,7 +1,7 @@
-From 112ca9f860114bc79273a79ed42722fdc9ded6ea Mon Sep 17 00:00:00 2001
+From 08a0e45b308fc97d06f5c3ef77a257e7a6bd1a48 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 20 Feb 2015 09:39:38 +0000
-Subject: [PATCH 28/35] Avoid using libdir from .la which usually points to a
+Subject: [PATCH 28/46] Avoid using libdir from .la which usually points to a
  host path
 
 Upstream-Status: Inappropriate [embedded specific]
@@ -27,5 +27,5 @@
  	    absdir="$libdir"
  	  fi
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0029-export-CPP.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0029-export-CPP.patch
similarity index 95%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0029-export-CPP.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0029-export-CPP.patch
index 0a05ae5..62195aa 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0029-export-CPP.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0029-export-CPP.patch
@@ -1,7 +1,7 @@
-From a983033f1327a692af55be8d1aa61aede18c4afb Mon Sep 17 00:00:00 2001
+From 95f494d1544857ad38949a7da37e2d7264475233 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 20 Feb 2015 09:40:59 +0000
-Subject: [PATCH 29/35] export CPP
+Subject: [PATCH 29/46] export CPP
 
 The OE environment sets and exports CPP as being the target gcc. When
 building gcc-cross-canadian for a mingw targetted sdk, the following can be found
@@ -49,5 +49,5 @@
  	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
  	CXX="$(CXX_FOR_BUILD)"; export CXX; \
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0030-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0030-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch
similarity index 68%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0030-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0030-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch
index 873dca9..5705187 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0030-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0030-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch
@@ -1,7 +1,7 @@
-From 3d870a184c05df1338db1870301c4144ba99fc3d Mon Sep 17 00:00:00 2001
+From 4ed8c1fd9dc05f7a9db9298a55396c8f0ff549a7 Mon Sep 17 00:00:00 2001
 From: Alexandru-Cezar Sardan <alexandru.sardan@freescale.com>
 Date: Wed, 5 Feb 2014 16:52:31 +0200
-Subject: [PATCH 30/35] Enable SPE & AltiVec generation on powepc*linux target
+Subject: [PATCH 30/46] Enable SPE & AltiVec generation on powepc*linux target
 
 When is configured with --target=powerpc-linux, the resulting GCC will
 not be able to generate code for SPE targets (e500v1/v2).
@@ -19,11 +19,11 @@
  gcc/config.gcc | 9 ++++++++-
  1 file changed, 8 insertions(+), 1 deletion(-)
 
-diff --git a/gcc/config.gcc b/gcc/config.gcc
-index b155744..0541b8a 100644
---- a/gcc/config.gcc
-+++ b/gcc/config.gcc
-@@ -2337,7 +2337,14 @@ powerpc-*-rtems*)
+Index: gcc-5.3.0/gcc/config.gcc
+===================================================================
+--- gcc-5.3.0.orig/gcc/config.gcc
++++ gcc-5.3.0/gcc/config.gcc
+@@ -2346,7 +2346,14 @@ powerpc-*-rtems*)
  	tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-rtems rs6000/t-ppccomm"
  	;;
  powerpc*-*-linux*)
@@ -39,6 +39,14 @@
  	extra_options="${extra_options} rs6000/sysv4.opt"
  	tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-ppccomm"
  	extra_objs="$extra_objs rs6000-linux.o"
--- 
-2.1.4
-
+Index: gcc-5.3.0/gcc/config/rs6000/linuxspe.h
+===================================================================
+--- gcc-5.3.0.orig/gcc/config/rs6000/linuxspe.h
++++ gcc-5.3.0/gcc/config/rs6000/linuxspe.h
+@@ -27,6 +27,3 @@
+ #undef	TARGET_DEFAULT
+ #define TARGET_DEFAULT MASK_STRICT_ALIGN
+ #endif
+-
+-#undef  ASM_DEFAULT_SPEC
+-#define	ASM_DEFAULT_SPEC "-mppc -mspe -me500"
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0031-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0031-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch
similarity index 91%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0031-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0031-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch
index f06cba8..f2bc664 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0031-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0031-Disable-the-MULTILIB_OSDIRNAMES-and-other-multilib-o.patch
@@ -1,7 +1,7 @@
-From a824cd3f45875f6c1c47ccdbf33534947bd2b587 Mon Sep 17 00:00:00 2001
+From bb6fea821483aa3259b34e101a39c993edd01411 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 20 Feb 2015 10:21:55 +0000
-Subject: [PATCH 31/35] Disable the MULTILIB_OSDIRNAMES and other multilib
+Subject: [PATCH 31/46] Disable the MULTILIB_OSDIRNAMES and other multilib
  options.
 
 Hard coding the MULTILIB_OSDIRNAMES with ../lib64 is causing problems on
@@ -38,5 +38,5 @@
 -MULTILIB_OSDIRNAMES += mabi.ilp32=../libilp32
 +#MULTILIB_OSDIRNAMES += mabi.ilp32=../libilp32
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0032-Ensure-target-gcc-headers-can-be-included.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0032-Ensure-target-gcc-headers-can-be-included.patch
similarity index 93%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0032-Ensure-target-gcc-headers-can-be-included.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0032-Ensure-target-gcc-headers-can-be-included.patch
index 4513306..89503ff 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0032-Ensure-target-gcc-headers-can-be-included.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0032-Ensure-target-gcc-headers-can-be-included.patch
@@ -1,7 +1,7 @@
-From e60090f7c537c84fd1b22307edd9f386228c7339 Mon Sep 17 00:00:00 2001
+From bb26f90f5e0accc3539f62b6fec663682959dd36 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 20 Feb 2015 10:25:11 +0000
-Subject: [PATCH 32/35] Ensure target gcc headers can be included
+Subject: [PATCH 32/46] Ensure target gcc headers can be included
 
 There are a few headers installed as part of the OpenEmbedded
 gcc-runtime target (omp.h, ssp/*.h). Being installed from a recipe
@@ -23,7 +23,7 @@
  4 files changed, 15 insertions(+), 7 deletions(-)
 
 diff --git a/gcc/Makefile.in b/gcc/Makefile.in
-index 9470a92..1497ede 100644
+index 7b49f88..cd5bc4a 100644
 --- a/gcc/Makefile.in
 +++ b/gcc/Makefile.in
 @@ -582,6 +582,7 @@ libexecdir = @libexecdir@
@@ -34,7 +34,7 @@
  # Directory in which the compiler finds executables
  libexecsubdir = $(libexecdir)/gcc/$(real_target_noncanonical)/$(version)$(accel_dir_suffix)
  # Directory in which all plugin resources are installed
-@@ -2603,6 +2604,7 @@ CFLAGS-intl.o += -DLOCALEDIR=\"$(localedir)\"
+@@ -2610,6 +2611,7 @@ CFLAGS-intl.o += -DLOCALEDIR=\"$(localedir)\"
  
  PREPROCESSOR_DEFINES = \
    -DGCC_INCLUDE_DIR=\"$(libsubdir)/include\" \
@@ -94,5 +94,5 @@
  #undef MD_EXEC_PREFIX
  #undef MD_STARTFILE_PREFIX
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0033-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0033-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch
similarity index 92%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0033-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0033-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch
index 519e413..19d480f 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0033-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0033-gcc-4.8-won-t-build-with-disable-dependency-tracking.patch
@@ -1,7 +1,7 @@
-From 997f9e939f85f651b22a48251cfb1444831d54ca Mon Sep 17 00:00:00 2001
+From 629fcc7d0075c9b4261da6435e122429fb028ec0 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 20 Feb 2015 11:17:19 +0000
-Subject: [PATCH 33/35] gcc 4.8+ won't build with --disable-dependency-tracking
+Subject: [PATCH 33/46] gcc 4.8+ won't build with --disable-dependency-tracking
 
 since the *.Ppo files don't get created unless --enable-dependency-tracking is true.
 
@@ -50,5 +50,5 @@
  M_IFUNC = $(if $(PAT_S),$(IFUNC_DEF) $(IFUNC_OPT))
  M_FILE = $(PAT_BASE)_n.c
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0034-Don-t-search-host-directory-during-relink-if-inst_pr.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0034-Don-t-search-host-directory-during-relink-if-inst_pr.patch
similarity index 87%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0034-Don-t-search-host-directory-during-relink-if-inst_pr.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0034-Don-t-search-host-directory-during-relink-if-inst_pr.patch
index 207cd7c..a453fa6 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0034-Don-t-search-host-directory-during-relink-if-inst_pr.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0034-Don-t-search-host-directory-during-relink-if-inst_pr.patch
@@ -1,7 +1,7 @@
-From c94da257a219873b946e08306141af7749679f67 Mon Sep 17 00:00:00 2001
+From a4efc9ca85734c283d4da09b628121e1c1f49c4e Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 3 Mar 2015 08:21:19 +0000
-Subject: [PATCH 34/35] Don't search host directory during "relink" if
+Subject: [PATCH 34/46] Don't search host directory during "relink" if
  $inst_prefix is provided
 
 http://lists.gnu.org/archive/html/libtool-patches/2011-01/msg00026.html
@@ -34,5 +34,5 @@
  		esac
  	      fi
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0035-Dont-link-the-plugins-with-libgomp-explicitly.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0035-Dont-link-the-plugins-with-libgomp-explicitly.patch
similarity index 96%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0035-Dont-link-the-plugins-with-libgomp-explicitly.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0035-Dont-link-the-plugins-with-libgomp-explicitly.patch
index b75f385..6ed589b 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0035-Dont-link-the-plugins-with-libgomp-explicitly.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0035-Dont-link-the-plugins-with-libgomp-explicitly.patch
@@ -1,7 +1,7 @@
-From 3a09545f3d18ce492ef55639215a072282de03d0 Mon Sep 17 00:00:00 2001
+From 5b0125a792842ae02df507bc55555661cb10f9a3 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sun, 8 Mar 2015 03:41:39 +0000
-Subject: [PATCH 35/35] Dont link the plugins with libgomp explicitly
+Subject: [PATCH 35/46] Dont link the plugins with libgomp explicitly
 
 They are dlopened by libgomp anyway. This fixes
 the libtool relink issue which causes issues during
@@ -79,5 +79,5 @@
 -libgomp_plugin_host_nonshm_la_LIBADD = libgomp.la
  libgomp_plugin_host_nonshm_la_LIBTOOLFLAGS = --tag=disable-static
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0036-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0036-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch
similarity index 82%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0036-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0036-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch
index b691946..41c0294 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0036-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0036-Use-SYSTEMLIBS_DIR-replacement-instead-of-hardcoding.patch
@@ -1,7 +1,7 @@
-From 861bcfd4ae814f351e0c668ee26d01d1331e0422 Mon Sep 17 00:00:00 2001
+From b0b0688176a9482777e9b2e98408bfc4505d31af Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 28 Apr 2015 23:15:27 -0700
-Subject: [PATCH 36/37] Use SYSTEMLIBS_DIR replacement instead of hardcoding
+Subject: [PATCH 36/46] Use SYSTEMLIBS_DIR replacement instead of hardcoding
  base_libdir
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
@@ -10,7 +10,7 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/gcc/config/aarch64/aarch64-linux.h b/gcc/config/aarch64/aarch64-linux.h
-index 9abb252..79525ee 100644
+index 257acf0..abeb948 100644
 --- a/gcc/config/aarch64/aarch64-linux.h
 +++ b/gcc/config/aarch64/aarch64-linux.h
 @@ -21,7 +21,7 @@
@@ -23,5 +23,5 @@
  #undef  ASAN_CC1_SPEC
  #define ASAN_CC1_SPEC "%{%:sanitize(address):-funwind-tables}"
 -- 
-2.1.4
+2.6.3
 
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0037-aarch64-Add-support-for-musl-ldso.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0037-aarch64-Add-support-for-musl-ldso.patch
new file mode 100644
index 0000000..30dbe74
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0037-aarch64-Add-support-for-musl-ldso.patch
@@ -0,0 +1,26 @@
+From 420ca64a86d560a77ee596a9774d672b08ca8278 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 28 Apr 2015 23:18:39 -0700
+Subject: [PATCH 37/46] aarch64: Add support for musl ldso
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/config/aarch64/aarch64-linux.h | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/gcc/config/aarch64/aarch64-linux.h b/gcc/config/aarch64/aarch64-linux.h
+index abeb948..f9e65fc 100644
+--- a/gcc/config/aarch64/aarch64-linux.h
++++ b/gcc/config/aarch64/aarch64-linux.h
+@@ -23,6 +23,8 @@
+ 
+ #define GLIBC_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+ 
++#define MUSL_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-musl-aarch64.so.1"
++
+ #undef  ASAN_CC1_SPEC
+ #define ASAN_CC1_SPEC "%{%:sanitize(address):-funwind-tables}"
+ 
+-- 
+2.6.3
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0038-fix-g++-sysroot.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0038-fix-g-sysroot.patch
similarity index 64%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0038-fix-g++-sysroot.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0038-fix-g-sysroot.patch
index f024dd5..9ba574a 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0038-fix-g++-sysroot.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0038-fix-g-sysroot.patch
@@ -1,3 +1,8 @@
+From 8df3e7007a22c9d6be5d5ae4b9b169c5c8431917 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 27 May 2015 17:06:06 -0700
+Subject: [PATCH 38/46] fix g++ sysroot
+
 Portions of
 
 http://www.mail-archive.com/gcc-patches@gcc.gnu.org/msg26013.html
@@ -11,12 +16,16 @@
 usr/include/xxxx rather than /usr/include/xxxx
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/configure    | 4 +++-
+ gcc/configure.ac | 4 +++-
+ 2 files changed, 6 insertions(+), 2 deletions(-)
 
-Index: gcc-4.8.1/gcc/configure.ac
-===================================================================
---- gcc-4.8.1.orig/gcc/configure.ac	2013-07-15 15:55:49.488399132 -0700
-+++ gcc-4.8.1/gcc/configure.ac	2013-07-15 16:02:31.772406679 -0700
-@@ -148,7 +148,9 @@
+diff --git a/gcc/configure b/gcc/configure
+index 9b60aad..6df594c 100755
+--- a/gcc/configure
++++ b/gcc/configure
+@@ -3375,7 +3375,9 @@ gcc_gxx_include_dir_add_sysroot=0
  if test "${with_sysroot+set}" = set; then
    gcc_gxx_without_sysroot=`expr "${gcc_gxx_include_dir}" : "${with_sysroot}"'\(.*\)'`
    if test "${gcc_gxx_without_sysroot}"; then
@@ -27,11 +36,11 @@
      gcc_gxx_include_dir_add_sysroot=1
    fi
  fi
-Index: gcc-4.8.1/gcc/configure
-===================================================================
---- gcc-4.8.1.orig/gcc/configure	2013-07-15 15:55:49.472399132 -0700
-+++ gcc-4.8.1/gcc/configure	2013-07-15 16:02:31.780406680 -0700
-@@ -3325,7 +3325,9 @@
+diff --git a/gcc/configure.ac b/gcc/configure.ac
+index e1e54f2..3bb2173 100644
+--- a/gcc/configure.ac
++++ b/gcc/configure.ac
+@@ -152,7 +152,9 @@ gcc_gxx_include_dir_add_sysroot=0
  if test "${with_sysroot+set}" = set; then
    gcc_gxx_without_sysroot=`expr "${gcc_gxx_include_dir}" : "${with_sysroot}"'\(.*\)'`
    if test "${gcc_gxx_without_sysroot}"; then
@@ -42,3 +51,6 @@
      gcc_gxx_include_dir_add_sysroot=1
    fi
  fi
+-- 
+2.6.3
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0039-libcc1-fix-libcc1-s-install-path-and-rpath.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0039-libcc1-fix-libcc1-s-install-path-and-rpath.patch
similarity index 90%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0039-libcc1-fix-libcc1-s-install-path-and-rpath.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0039-libcc1-fix-libcc1-s-install-path-and-rpath.patch
index 2f025c6..2e0df96 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0039-libcc1-fix-libcc1-s-install-path-and-rpath.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0039-libcc1-fix-libcc1-s-install-path-and-rpath.patch
@@ -1,7 +1,7 @@
-From acea0df9997a47f8b8224b6ca1618c8c9dfbe6d5 Mon Sep 17 00:00:00 2001
+From 1eede9e4a10d3532db826a6eeced695df3ad5b89 Mon Sep 17 00:00:00 2001
 From: Robert Yang <liezhi.yang@windriver.com>
 Date: Sun, 5 Jul 2015 20:25:18 -0700
-Subject: [PATCH] libcc1: fix libcc1's install path and rpath
+Subject: [PATCH 39/46] libcc1: fix libcc1's install path and rpath
 
 * Install libcc1.so and libcc1plugin.so into
   $(libexecdir)/gcc/$(target_noncanonical)/$(gcc_version), as what we
@@ -15,8 +15,8 @@
 
 Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
 ---
- libcc1/Makefile.am  |    4 ++--
- libcc1/Makefile.in  |    4 ++--
+ libcc1/Makefile.am | 4 ++--
+ libcc1/Makefile.in | 4 ++--
  2 files changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/libcc1/Makefile.am b/libcc1/Makefile.am
@@ -49,3 +49,6 @@
  @ENABLE_PLUGIN_TRUE@plugin_LTLIBRARIES = libcc1plugin.la
  @ENABLE_PLUGIN_TRUE@cc1lib_LTLIBRARIES = libcc1.la
  BUILT_SOURCES = compiler-name.h
+-- 
+2.6.3
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0040-nativesdk-gcc-support.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0040-handle-sysroot-support-for-nativesdk-gcc.patch
similarity index 92%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0040-nativesdk-gcc-support.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0040-handle-sysroot-support-for-nativesdk-gcc.patch
index fd81ae2..11e1310 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0040-nativesdk-gcc-support.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0040-handle-sysroot-support-for-nativesdk-gcc.patch
@@ -1,3 +1,8 @@
+From b41674d357c4ba320b9860e0f313d2f5a332f27d Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 7 Dec 2015 23:39:54 +0000
+Subject: [PATCH 40/46] handle sysroot support for nativesdk-gcc
+
 Being able to build a nativesdk gcc is useful, particularly in cases
 where the host compiler may be of an incompatible version (or a 32
 bit compiler is needed).
@@ -15,11 +20,18 @@
 b) Add other paths which need relocation into a .gccrelocprefix section
    which the relocation code will notice and adjust automatically.
 
-
 Upstream-Status: Inappropriate
 RP 2015/7/28
 
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/cppdefault.c | 50 +++++++++++++++++++++++++++++++++++++-------------
+ gcc/cppdefault.h |  3 ++-
+ gcc/gcc.c        | 20 ++++++++++++++------
+ 3 files changed, 53 insertions(+), 20 deletions(-)
+
 diff --git a/gcc/cppdefault.c b/gcc/cppdefault.c
+index 03a0287..f44c1d8 100644
 --- a/gcc/cppdefault.c
 +++ b/gcc/cppdefault.c
 @@ -35,6 +35,30 @@
@@ -123,6 +135,7 @@
      { 0, 0, 0, 0, 0, 0 }
    };
 diff --git a/gcc/cppdefault.h b/gcc/cppdefault.h
+index c98644f..4198669 100644
 --- a/gcc/cppdefault.h
 +++ b/gcc/cppdefault.h
 @@ -33,7 +33,8 @@
@@ -136,6 +149,7 @@
  				   (see update_path in prefix.c) */
    const char cplusplus;		/* Only look here if we're compiling C++.  */
 diff --git a/gcc/gcc.c b/gcc/gcc.c
+index 3ca27b9..2b7756e 100644
 --- a/gcc/gcc.c
 +++ b/gcc/gcc.c
 @@ -120,6 +120,8 @@ static const char *target_system_root = TARGET_SYSTEM_ROOT;
@@ -182,7 +196,7 @@
    = STANDARD_STARTFILE_PREFIX_2;
  
  /* A relative path to be used in finding the location of tools
-@@ -5550,6 +5553,11 @@ do_spec_1 (const char *spec, int inswitch, const char *soft_matched_part)
+@@ -5523,6 +5526,11 @@ do_spec_1 (const char *spec, int inswitch, const char *soft_matched_part)
  	      }
  	    break;
  
@@ -194,3 +208,6 @@
  	  case 'S':
  	    value = do_spec_1 (startfile_spec, 0, NULL);
  	    if (value != 0)
+-- 
+2.6.3
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0041-handle-target-sysroot-multilib.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0041-Search-target-sysroot-gcc-version-specific-dirs-with.patch
similarity index 73%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0041-handle-target-sysroot-multilib.patch
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0041-Search-target-sysroot-gcc-version-specific-dirs-with.patch
index 5356984..5a504a1 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.2/0041-handle-target-sysroot-multilib.patch
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0041-Search-target-sysroot-gcc-version-specific-dirs-with.patch
@@ -1,18 +1,24 @@
-Search target sysroot gcc version specific dirs with multilib.
+From 99cadb4d8415dd5a275d7d6410f20db33d0f8433 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 7 Dec 2015 23:41:45 +0000
+Subject: [PATCH 41/46] Search target sysroot gcc version specific dirs with
+ multilib.
 
 We install the gcc libraries (such as crtbegin.p) into
 <sysroot><libdir>/<target-sys>/5.2.0/
-which is a default search path for GCC (aka multi_suffix in the 
+which is a default search path for GCC (aka multi_suffix in the
 code below). <target-sys> is 'machine' in gcc's terminology. We use
-these directories so that multiple gcc versions could in theory 
+these directories so that multiple gcc versions could in theory
 co-exist on target.
 
-We only want to build one gcc-cross-canadian per arch and have this work 
+We only want to build one gcc-cross-canadian per arch and have this work
 for all multilibs. <target-sys> can be handled by mapping the multilib
-<target-sys> to the one used by gcc-cross-canadian, e.g. mips64-polkmllib32-linux 
+<target-sys> to the one used by gcc-cross-canadian, e.g.
+mips64-polkmllib32-linux
 is symlinked to by mips64-poky-linux.
 
-The default gcc search path in the target sysroot for a "lib64" mutlilib is:
+The default gcc search path in the target sysroot for a "lib64" mutlilib
+is:
 
 <sysroot>/lib32/mips64-poky-linux/5.2.0/
 <sysroot>/lib32/../lib64/
@@ -39,11 +45,16 @@
 Upstream-Status: Pending
 RP 2015/7/31
 
-Index: gcc-5.2.0/gcc/gcc.c
-===================================================================
---- gcc-5.2.0.orig/gcc/gcc.c
-+++ gcc-5.2.0/gcc/gcc.c
-@@ -2305,7 +2305,7 @@ for_each_path (const struct path_prefix
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/gcc.c | 29 ++++++++++++++++++++++++++++-
+ 1 file changed, 28 insertions(+), 1 deletion(-)
+
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index 2b7756e..8f53aea 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -2305,7 +2305,7 @@ for_each_path (const struct path_prefix *paths,
        if (path == NULL)
  	{
  	  len = paths->max_len + extra_space + 1;
@@ -52,7 +63,7 @@
  	  path = XNEWVEC (char, len);
  	}
  
-@@ -2317,6 +2317,33 @@ for_each_path (const struct path_prefix
+@@ -2317,6 +2317,33 @@ for_each_path (const struct path_prefix *paths,
  	  /* Look first in MACHINE/VERSION subdirectory.  */
  	  if (!skip_multi_dir)
  	    {
@@ -86,3 +97,6 @@
  	      memcpy (path + len, multi_suffix, suffix_len + 1);
  	      ret = callback (path, callback_info);
  	      if (ret)
+-- 
+2.6.3
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0042-Fix-various-_FOR_BUILD-and-related-variables.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0042-Fix-various-_FOR_BUILD-and-related-variables.patch
new file mode 100644
index 0000000..5af764b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0042-Fix-various-_FOR_BUILD-and-related-variables.patch
@@ -0,0 +1,137 @@
+From 78e77206902349c9256f06c3dd179197a39af2e1 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 7 Dec 2015 23:42:45 +0000
+Subject: [PATCH 42/46] Fix various _FOR_BUILD and related variables
+
+When doing a FOR_BUILD thing, you have to override CFLAGS with
+CFLAGS_FOR_BUILD. And if you use C++, you also have to override
+CXXFLAGS with CXXFLAGS_FOR_BUILD.
+Without this, when building for mingw, you end up trying to use
+the mingw headers for a host build.
+
+The same goes for other variables as well, such as CPPFLAGS,
+CPP, and GMPINC.
+
+Upstream-Status: Pending
+
+Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ Makefile.in      | 6 ++++++
+ Makefile.tpl     | 5 +++++
+ gcc/Makefile.in  | 2 +-
+ gcc/configure    | 2 +-
+ gcc/configure.ac | 2 +-
+ 5 files changed, 14 insertions(+), 3 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index a783e1e..8b6d3d2 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -152,6 +152,7 @@ BUILD_EXPORTS = \
+ 	CPP="$(CC_FOR_BUILD) -E"; export CPP; \
+ 	CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
+ 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
++	CPPFLAGS="$(CPPFLAGS_FOR_BUILD)"; export CPPFLAGS; \
+ 	CXX="$(CXX_FOR_BUILD)"; export CXX; \
+ 	CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
+ 	GCJ="$(GCJ_FOR_BUILD)"; export GCJ; \
+@@ -170,6 +171,9 @@ BUILD_EXPORTS = \
+ # built for the build system to override those in BASE_FLAGS_TO_PASS.
+ EXTRA_BUILD_FLAGS = \
+ 	CFLAGS="$(CFLAGS_FOR_BUILD)" \
++	CXXFLAGS="$(CXXFLAGS_FOR_BUILD)" \
++	CPP="$(CC_FOR_BUILD) -E" \
++	CPPFLAGS="$(CPPFLAGS_FOR_BUILD)" \
+ 	LDFLAGS="$(LDFLAGS_FOR_BUILD)"
+ 
+ # This is the list of directories to built for the host system.
+@@ -187,6 +191,7 @@ HOST_SUBDIR = @host_subdir@
+ HOST_EXPORTS = \
+ 	$(BASE_EXPORTS) \
+ 	CC="$(CC)"; export CC; \
++	CPP="$(CC) -E"; export CPP; \
+ 	ADA_CFLAGS="$(ADA_CFLAGS)"; export ADA_CFLAGS; \
+ 	CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+@@ -710,6 +715,7 @@ BASE_FLAGS_TO_PASS = \
+ 	"CC_FOR_BUILD=$(CC_FOR_BUILD)" \
+ 	"CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
+ 	"CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
++	"CXXFLAGS_FOR_BUILD=$(CXXFLAGS_FOR_BUILD)" \
+ 	"EXPECT=$(EXPECT)" \
+ 	"FLEX=$(FLEX)" \
+ 	"INSTALL=$(INSTALL)" \
+diff --git a/Makefile.tpl b/Makefile.tpl
+index 1ea1954..78a59c3 100644
+--- a/Makefile.tpl
++++ b/Makefile.tpl
+@@ -154,6 +154,7 @@ BUILD_EXPORTS = \
+ 	CC="$(CC_FOR_BUILD)"; export CC; \
+ 	CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
+ 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
++	CPPFLAGS="$(CPPFLAGS_FOR_BUILD)"; export CPPFLAGS; \
+ 	CXX="$(CXX_FOR_BUILD)"; export CXX; \
+ 	CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
+ 	GCJ="$(GCJ_FOR_BUILD)"; export GCJ; \
+@@ -172,6 +173,9 @@ BUILD_EXPORTS = \
+ # built for the build system to override those in BASE_FLAGS_TO_PASS.
+ EXTRA_BUILD_FLAGS = \
+ 	CFLAGS="$(CFLAGS_FOR_BUILD)" \
++	CXXFLAGS="$(CXXFLAGS_FOR_BUILD)" \
++	CPP="$(CC_FOR_BUILD) -E" \
++	CPPFLAGS="$(CPPFLAGS_FOR_BUILD)" \
+ 	LDFLAGS="$(LDFLAGS_FOR_BUILD)"
+ 
+ # This is the list of directories to built for the host system.
+@@ -189,6 +193,7 @@ HOST_SUBDIR = @host_subdir@
+ HOST_EXPORTS = \
+ 	$(BASE_EXPORTS) \
+ 	CC="$(CC)"; export CC; \
++	CPP="$(CC) -E"; export CPP; \
+ 	ADA_CFLAGS="$(ADA_CFLAGS)"; export ADA_CFLAGS; \
+ 	CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ 	CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+diff --git a/gcc/Makefile.in b/gcc/Makefile.in
+index cd5bc4a..98ae4f4 100644
+--- a/gcc/Makefile.in
++++ b/gcc/Makefile.in
+@@ -762,7 +762,7 @@ BUILD_LINKERFLAGS = $(BUILD_CXXFLAGS)
+ # Native linker and preprocessor flags.  For x-fragment overrides.
+ BUILD_LDFLAGS=@BUILD_LDFLAGS@
+ BUILD_CPPFLAGS= -I. -I$(@D) -I$(srcdir) -I$(srcdir)/$(@D) \
+-		-I$(srcdir)/../include @INCINTL@ $(CPPINC) $(CPPFLAGS)
++		-I$(srcdir)/../include @INCINTL@ $(CPPINC) $(CPPFLAGS_FOR_BUILD)
+ 
+ # Actual name to use when installing a native compiler.
+ GCC_INSTALL_NAME := $(shell echo gcc|sed '$(program_transform_name)')
+diff --git a/gcc/configure b/gcc/configure
+index 6df594c..fcb05e7 100755
+--- a/gcc/configure
++++ b/gcc/configure
+@@ -11521,7 +11521,7 @@ else
+ 	CC="${CC_FOR_BUILD}" CFLAGS="${CFLAGS_FOR_BUILD}" \
+ 	CXX="${CXX_FOR_BUILD}" CXXFLAGS="${CXXFLAGS_FOR_BUILD}" \
+ 	LD="${LD_FOR_BUILD}" LDFLAGS="${LDFLAGS_FOR_BUILD}" \
+-	GMPINC="" CPPFLAGS="${CPPFLAGS} -DGENERATOR_FILE" \
++	GMPINC="" CPPFLAGS="${CPPFLAGS_FOR_BUILD} -DGENERATOR_FILE" \
+ 	${realsrcdir}/configure \
+ 		--enable-languages=${enable_languages-all} \
+ 		--target=$target_alias --host=$build_alias --build=$build_alias
+diff --git a/gcc/configure.ac b/gcc/configure.ac
+index 3bb2173..923bc9a 100644
+--- a/gcc/configure.ac
++++ b/gcc/configure.ac
+@@ -1633,7 +1633,7 @@ else
+ 	CC="${CC_FOR_BUILD}" CFLAGS="${CFLAGS_FOR_BUILD}" \
+ 	CXX="${CXX_FOR_BUILD}" CXXFLAGS="${CXXFLAGS_FOR_BUILD}" \
+ 	LD="${LD_FOR_BUILD}" LDFLAGS="${LDFLAGS_FOR_BUILD}" \
+-	GMPINC="" CPPFLAGS="${CPPFLAGS} -DGENERATOR_FILE" \
++	GMPINC="" CPPFLAGS="${CPPFLAGS_FOR_BUILD} -DGENERATOR_FILE" \
+ 	${realsrcdir}/configure \
+ 		--enable-languages=${enable_languages-all} \
+ 		--target=$target_alias --host=$build_alias --build=$build_alias
+-- 
+2.6.3
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0043-libstdc-Support-musl.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0043-libstdc-Support-musl.patch
new file mode 100644
index 0000000..bad8402
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0043-libstdc-Support-musl.patch
@@ -0,0 +1,44 @@
+From df430b943a2df6b72054c808d4b93338a82562de Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 8 Dec 2015 08:23:34 +0000
+Subject: [PATCH 43/46] libstdc++: Support musl
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ libstdc++-v3/configure.host | 10 ++++++++++
+ 1 file changed, 10 insertions(+)
+
+diff --git a/libstdc++-v3/configure.host b/libstdc++-v3/configure.host
+index 640199c..1756444 100644
+--- a/libstdc++-v3/configure.host
++++ b/libstdc++-v3/configure.host
+@@ -274,14 +274,24 @@ case "${host_os}" in
+     os_include_dir="os/bsd/freebsd"
+     ;;
+   gnu* | linux* | kfreebsd*-gnu | knetbsd*-gnu)
++    # check for musl by target
++    case "${host_os}" in
++      *-musl*)
++        os_include_dir="os/generic"
++        ;;
++      *)
+     if [ "$uclibc" = "yes" ]; then
+       os_include_dir="os/uclibc"
+     elif [ "$bionic" = "yes" ]; then
+       os_include_dir="os/bionic"
++    elif [ "$musl" = "yes" ]; then
++      os_include_dir="os/generic"
+     else
+       os_include_dir="os/gnu-linux"
+     fi
+     ;;
++    esac
++    ;;
+   hpux*)
+     os_include_dir="os/hpux"
+     ;;
+-- 
+2.6.3
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0044-Adding-mmusl-as-a-musl-libc-specifier-and-the-necess.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0044-Adding-mmusl-as-a-musl-libc-specifier-and-the-necess.patch
new file mode 100644
index 0000000..b91c02d
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0044-Adding-mmusl-as-a-musl-libc-specifier-and-the-necess.patch
@@ -0,0 +1,270 @@
+From 0b54799d80fb859c7b142467e4d42c99db59df50 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 8 Dec 2015 08:30:35 +0000
+Subject: [PATCH 44/46] Adding -mmusl as a musl libc specifier, and the
+ necessary hacks for it to know how to find musl's dynamic linker.
+
+Upstream-Status: Backport [partial]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/config.gcc                |  10 ++++-
+ gcc/config/linux.h            | 100 +++++++++++++++++++++++++++++++++++++-----
+ gcc/config/linux.opt          |   4 ++
+ gcc/config/rs6000/secureplt.h |   1 +
+ gcc/config/rs6000/sysv4.h     |   5 +++
+ gcc/ginclude/stddef.h         |   3 ++
+ 6 files changed, 110 insertions(+), 13 deletions(-)
+
+diff --git a/gcc/config.gcc b/gcc/config.gcc
+index 3825bd5..39ce047 100644
+--- a/gcc/config.gcc
++++ b/gcc/config.gcc
+@@ -575,7 +575,7 @@ case ${target} in
+ esac
+ 
+ # Common C libraries.
+-tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3"
++tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3 LIBC_MUSL=4"
+ 
+ # 32-bit x86 processors supported by --with-arch=.  Each processor
+ # MUST be separated by exactly one space.
+@@ -720,6 +720,9 @@ case ${target} in
+     *-*-*uclibc*)
+       tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC"
+       ;;
++    *-*-*musl*)
++      tm_defines="$tm_defines DEFAULT_LIBC=LIBC_MUSL"
++      ;;
+     *)
+       tm_defines="$tm_defines DEFAULT_LIBC=LIBC_GLIBC"
+       ;;
+@@ -2420,6 +2423,11 @@ powerpc*-*-linux*)
+ 	    powerpc*-*-linux*paired*)
+ 		tm_file="${tm_file} rs6000/750cl.h" ;;
+ 	esac
++        case ${target} in
++	    *-linux*-musl*)
++		enable_secureplt=yes ;;
++	esac
++
+ 	if test x${enable_secureplt} = xyes; then
+ 		tm_file="rs6000/secureplt.h ${tm_file}"
+ 	fi
+diff --git a/gcc/config/linux.h b/gcc/config/linux.h
+index 22b9be5..ca9a17f 100644
+--- a/gcc/config/linux.h
++++ b/gcc/config/linux.h
+@@ -32,10 +32,12 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+ #define OPTION_GLIBC  (DEFAULT_LIBC == LIBC_GLIBC)
+ #define OPTION_UCLIBC (DEFAULT_LIBC == LIBC_UCLIBC)
+ #define OPTION_BIONIC (DEFAULT_LIBC == LIBC_BIONIC)
++#define OPTION_MUSL   (DEFAULT_LIBC == LIBC_MUSL)
+ #else
+ #define OPTION_GLIBC  (linux_libc == LIBC_GLIBC)
+ #define OPTION_UCLIBC (linux_libc == LIBC_UCLIBC)
+ #define OPTION_BIONIC (linux_libc == LIBC_BIONIC)
++#define OPTION_MUSL   (linux_libc == LIBC_MUSL)
+ #endif
+ 
+ #define GNU_USER_TARGET_OS_CPP_BUILTINS()			\
+@@ -53,18 +55,21 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+    uClibc or Bionic is the default C library and whether
+    -muclibc or -mglibc or -mbionic has been passed to change the default.  */
+ 
+-#define CHOOSE_DYNAMIC_LINKER1(LIBC1, LIBC2, LIBC3, LD1, LD2, LD3)	\
+-  "%{" LIBC2 ":" LD2 ";:%{" LIBC3 ":" LD3 ";:" LD1 "}}"
++#define CHOOSE_DYNAMIC_LINKER1(LIBC1, LIBC2, LIBC3, LIBC4, LD1, LD2, LD3, LD4)	\
++  "%{" LIBC2 ":" LD2 ";:%{" LIBC3 ":" LD3 ";:%{" LIBC4 ":" LD4 ";:" LD1 "}}}"
+ 
+ #if DEFAULT_LIBC == LIBC_GLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U, B) \
+-  CHOOSE_DYNAMIC_LINKER1 ("mglibc", "muclibc", "mbionic", G, U, B)
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++  CHOOSE_DYNAMIC_LINKER1 ("mglibc", "muclibc", "mbionic", "mmusl", G, U, B, M)
+ #elif DEFAULT_LIBC == LIBC_UCLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U, B) \
+-  CHOOSE_DYNAMIC_LINKER1 ("muclibc", "mglibc", "mbionic", U, G, B)
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++  CHOOSE_DYNAMIC_LINKER1 ("muclibc", "mglibc", "mbionic", "mmusl", U, G, B, M)
+ #elif DEFAULT_LIBC == LIBC_BIONIC
+-#define CHOOSE_DYNAMIC_LINKER(G, U, B) \
+-  CHOOSE_DYNAMIC_LINKER1 ("mbionic", "mglibc", "muclibc", B, G, U)
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++  CHOOSE_DYNAMIC_LINKER1 ("mbionic", "mglibc", "muclibc", "mmusl", B, G, U, M)
++#elif DEFAULT_LIBC == LIBC_MUSL
++#define CHOOSE_DYNAMIC_LINKER(G, U, B, M) \
++  CHOOSE_DYNAMIC_LINKER1 ("mmusl", "mglibc", "muclibc", "mbionic", M, G, U, B)
+ #else
+ #error "Unsupported DEFAULT_LIBC"
+ #endif /* DEFAULT_LIBC */
+@@ -84,16 +89,16 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+ 
+ #define GNU_USER_DYNAMIC_LINKER						\
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER,	\
+-			 BIONIC_DYNAMIC_LINKER)
++			 BIONIC_DYNAMIC_LINKER, MUSL_DYNAMIC_LINKER)
+ #define GNU_USER_DYNAMIC_LINKER32					\
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32, \
+-			 BIONIC_DYNAMIC_LINKER32)
++			 BIONIC_DYNAMIC_LINKER32, MUSL_DYNAMIC_LINKER32)
+ #define GNU_USER_DYNAMIC_LINKER64					\
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64, \
+-			 BIONIC_DYNAMIC_LINKER64)
++			 BIONIC_DYNAMIC_LINKER64, MUSL_DYNAMIC_LINKER64)
+ #define GNU_USER_DYNAMIC_LINKERX32					\
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKERX32, UCLIBC_DYNAMIC_LINKERX32, \
+-			 BIONIC_DYNAMIC_LINKERX32)
++			 BIONIC_DYNAMIC_LINKERX32, MUSL_DYNAMIC_LINKERX32)
+ 
+ /* Whether we have Bionic libc runtime */
+ #undef TARGET_HAS_BIONIC
+@@ -123,3 +128,74 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+ # define TARGET_LIBC_HAS_FUNCTION linux_libc_has_function
+ 
+ #endif
++
++/* musl avoids problematic includes by rearranging the include directories.
++ * Unfortunately, this is mostly duplicated from cppdefault.c */
++#if DEFAULT_LIBC == LIBC_MUSL
++#define INCLUDE_DEFAULTS_MUSL_GPP			\
++    { GPLUSPLUS_INCLUDE_DIR, "G++", 1, 1,		\
++      GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 0 },		\
++    { GPLUSPLUS_TOOL_INCLUDE_DIR, "G++", 1, 1,		\
++      GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 1 },		\
++    { GPLUSPLUS_BACKWARD_INCLUDE_DIR, "G++", 1, 1,	\
++      GPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT, 0 },
++
++#ifdef LOCAL_INCLUDE_DIR
++#define INCLUDE_DEFAULTS_MUSL_LOCAL			\
++    { LOCAL_INCLUDE_DIR, 0, 0, 1, 1, 2 },		\
++    { LOCAL_INCLUDE_DIR, 0, 0, 1, 1, 0 },
++#else
++#define INCLUDE_DEFAULTS_MUSL_LOCAL
++#endif
++
++#ifdef PREFIX_INCLUDE_DIR
++#define INCLUDE_DEFAULTS_MUSL_PREFIX			\
++    { PREFIX_INCLUDE_DIR, 0, 0, 1, 0, 0},
++#else
++#define INCLUDE_DEFAULTS_MUSL_PREFIX
++#endif
++
++#ifdef CROSS_INCLUDE_DIR
++#define INCLUDE_DEFAULTS_MUSL_CROSS			\
++    { CROSS_INCLUDE_DIR, "GCC", 0, 0, 0, 0},
++#else
++#define INCLUDE_DEFAULTS_MUSL_CROSS
++#endif
++
++#ifdef TOOL_INCLUDE_DIR
++#define INCLUDE_DEFAULTS_MUSL_TOOL			\
++    { TOOL_INCLUDE_DIR, "BINUTILS", 0, 1, 0, 0},
++#else
++#define INCLUDE_DEFAULTS_MUSL_TOOL
++#endif
++
++#ifdef NATIVE_SYSTEM_HEADER_DIR
++#define INCLUDE_DEFAULTS_MUSL_NATIVE			\
++    { NATIVE_SYSTEM_HEADER_DIR, 0, 0, 0, 1, 2 },	\
++    { NATIVE_SYSTEM_HEADER_DIR, 0, 0, 0, 1, 0 },
++#else
++#define INCLUDE_DEFAULTS_MUSL_NATIVE
++#endif
++
++#if defined (CROSS_DIRECTORY_STRUCTURE) && !defined (TARGET_SYSTEM_ROOT)
++# undef INCLUDE_DEFAULTS_MUSL_LOCAL
++# define INCLUDE_DEFAULTS_MUSL_LOCAL
++# undef INCLUDE_DEFAULTS_MUSL_NATIVE
++# define INCLUDE_DEFAULTS_MUSL_NATIVE
++#else
++# undef INCLUDE_DEFAULTS_MUSL_CROSS
++# define INCLUDE_DEFAULTS_MUSL_CROSS
++#endif
++
++#undef INCLUDE_DEFAULTS
++#define INCLUDE_DEFAULTS				\
++  {							\
++    INCLUDE_DEFAULTS_MUSL_GPP				\
++    INCLUDE_DEFAULTS_MUSL_PREFIX			\
++    INCLUDE_DEFAULTS_MUSL_CROSS				\
++    INCLUDE_DEFAULTS_MUSL_TOOL				\
++    INCLUDE_DEFAULTS_MUSL_NATIVE			\
++    { GCC_INCLUDE_DIR, "GCC", 0, 1, 0, 0 },		\
++    { 0, 0, 0, 0, 0, 0 }				\
++  }
++#endif
+diff --git a/gcc/config/linux.opt b/gcc/config/linux.opt
+index c054338..9334f74 100644
+--- a/gcc/config/linux.opt
++++ b/gcc/config/linux.opt
+@@ -30,3 +30,7 @@ Use GNU C library
+ muclibc
+ Target Report RejectNegative Var(linux_libc,LIBC_UCLIBC) Negative(mbionic)
+ Use uClibc C library
++
++mmusl
++Target Report RejectNegative Var(linux_libc,LIBC_MUSL) Negative(mglibc)
++Use musl C library
+diff --git a/gcc/config/rs6000/secureplt.h b/gcc/config/rs6000/secureplt.h
+index b463463..77edf2a 100644
+--- a/gcc/config/rs6000/secureplt.h
++++ b/gcc/config/rs6000/secureplt.h
+@@ -18,3 +18,4 @@ along with GCC; see the file COPYING3.  If not see
+ <http://www.gnu.org/licenses/>.  */
+ 
+ #define CC1_SECURE_PLT_DEFAULT_SPEC "-msecure-plt"
++#define LINK_SECURE_PLT_DEFAULT_SPEC "--secure-plt"
+diff --git a/gcc/config/rs6000/sysv4.h b/gcc/config/rs6000/sysv4.h
+index c6c31dc..7cd07e0 100644
+--- a/gcc/config/rs6000/sysv4.h
++++ b/gcc/config/rs6000/sysv4.h
+@@ -538,6 +538,10 @@ ENDIAN_SELECT(" -mbig", " -mlittle", DEFAULT_ASM_ENDIAN)
+ #define CC1_SECURE_PLT_DEFAULT_SPEC ""
+ #endif
+ 
++#ifndef LINK_SECURE_PLT_DEFAULT_SPEC
++#define LINK_SECURE_PLT_DEFAULT_SPEC ""
++#endif
++
+ /* Pass -G xxx to the compiler.  */
+ #undef CC1_SPEC
+ #define	CC1_SPEC "%{G*} %(cc1_cpu)" \
+@@ -889,6 +893,7 @@ ncrtn.o%s"
+   { "link_os_openbsd",		LINK_OS_OPENBSD_SPEC },			\
+   { "link_os_default",		LINK_OS_DEFAULT_SPEC },			\
+   { "cc1_secure_plt_default",	CC1_SECURE_PLT_DEFAULT_SPEC },		\
++  { "link_secure_plt_default",	LINK_SECURE_PLT_DEFAULT_SPEC },		\
+   { "cpp_os_ads",		CPP_OS_ADS_SPEC },			\
+   { "cpp_os_yellowknife",	CPP_OS_YELLOWKNIFE_SPEC },		\
+   { "cpp_os_mvme",		CPP_OS_MVME_SPEC },			\
+diff --git a/gcc/ginclude/stddef.h b/gcc/ginclude/stddef.h
+index f20a41b..eb879ef 100644
+--- a/gcc/ginclude/stddef.h
++++ b/gcc/ginclude/stddef.h
+@@ -184,6 +184,7 @@ typedef __PTRDIFF_TYPE__ ptrdiff_t;
+ #ifndef _GCC_SIZE_T
+ #ifndef _SIZET_
+ #ifndef __size_t
++#ifndef __DEFINED_size_t /* musl */
+ #define __size_t__	/* BeOS */
+ #define __SIZE_T__	/* Cray Unicos/Mk */
+ #define _SIZE_T
+@@ -200,6 +201,7 @@ typedef __PTRDIFF_TYPE__ ptrdiff_t;
+ #define ___int_size_t_h
+ #define _GCC_SIZE_T
+ #define _SIZET_
++#define __DEFINED_size_t /* musl */
+ #if (defined (__FreeBSD__) && (__FreeBSD__ >= 5)) \
+   || defined(__DragonFly__) \
+   || defined(__FreeBSD_kernel__)
+@@ -218,6 +220,7 @@ typedef __SIZE_TYPE__ size_t;
+ typedef long ssize_t;
+ #endif /* __BEOS__ */
+ #endif /* !(defined (__GNUG__) && defined (size_t)) */
++#endif /* __DEFINED_size_t */
+ #endif /* __size_t */
+ #endif /* _SIZET_ */
+ #endif /* _GCC_SIZE_T */
+-- 
+2.6.3
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0045-Support-for-arm-linux-musl.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0045-Support-for-arm-linux-musl.patch
new file mode 100644
index 0000000..3c1115a
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0045-Support-for-arm-linux-musl.patch
@@ -0,0 +1,216 @@
+From a6c649571d49c972e6d207577780ada7e9b6bad5 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 8 Dec 2015 08:31:52 +0000
+Subject: [PATCH 45/57] Support for arm-linux-musl.
+
+Fix musl ldso for all arches
+
+Upstream-Status: backport [partial]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ gcc/config/aarch64/aarch64-linux.h |  1 +
+ gcc/config/arm/linux-eabi.h        | 17 +++++++++++++++++
+ gcc/config/i386/linux.h            |  1 +
+ gcc/config/i386/linux64.h          |  5 +++++
+ gcc/config/mips/linux.h            |  8 +++++++-
+ gcc/config/rs6000/linux64.h        | 13 +++++++++----
+ gcc/config/rs6000/sysv4.h          | 10 +++++++---
+ libitm/config/arm/hwcap.cc         |  4 ++++
+ libitm/config/linux/x86/tls.h      |  8 ++++++--
+ 9 files changed, 57 insertions(+), 10 deletions(-)
+
+diff --git a/gcc/config/aarch64/aarch64-linux.h b/gcc/config/aarch64/aarch64-linux.h
+index f9e65fc..1b2d0c0 100644
+--- a/gcc/config/aarch64/aarch64-linux.h
++++ b/gcc/config/aarch64/aarch64-linux.h
+@@ -22,6 +22,7 @@
+ #define GCC_AARCH64_LINUX_H
+ 
+ #define GLIBC_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
++#define MUSL_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-musl-aarch64.so.1"
+ 
+ #define MUSL_DYNAMIC_LINKER  SYSTEMLIBS_DIR "ld-musl-aarch64.so.1"
+ 
+diff --git a/gcc/config/arm/linux-eabi.h b/gcc/config/arm/linux-eabi.h
+index 048a062..adb9c44 100644
+--- a/gcc/config/arm/linux-eabi.h
++++ b/gcc/config/arm/linux-eabi.h
+@@ -81,6 +81,23 @@
+ #undef TARGET_FIX_V4BX_SPEC
+ #define TARGET_FIX_V4BX_SPEC "%{mcpu=arm8|mcpu=arm810|mcpu=strongarm*|march=armv4: --fix-v4bx}"
+ 
++/* For ARM musl currently supports four dynamic linkers:
++   - ld-musl-arm.so.1 - for the EABI-derived soft-float ABI
++   - ld-musl-armhf.so.1 - for the EABI-derived hard-float ABI
++   - ld-musl-armeb.so.1 - for the EABI-derived soft-float ABI, EB
++   - ld-musl-armebhf.so.1 - for the EABI-derived hard-float ABI, EB
++   musl does not support the legacy OABI mode.
++   All the dynamic linkers live in /lib.
++   We default to soft-float, EL. */
++#undef  MUSL_DYNAMIC_LINKER
++#if TARGET_BIG_ENDIAN_DEFAULT
++#define MUSL_DYNAMIC_LINKER_E "%{mlittle-endian:;:eb}"
++#else
++#define MUSL_DYNAMIC_LINKER_E "%{mbig-endian:eb}"
++#endif
++#define MUSL_DYNAMIC_LINKER \
++  SYSTEMLIBS_DIR "ld-musl-arm" MUSL_DYNAMIC_LINKER_E "%{mfloat-abi=hard:hf}.so.1"
++
+ /* At this point, bpabi.h will have clobbered LINK_SPEC.  We want to
+    use the GNU/Linux version, not the generic BPABI version.  */
+ #undef  LINK_SPEC
+diff --git a/gcc/config/i386/linux.h b/gcc/config/i386/linux.h
+index 21ba2b2..e2b81e5 100644
+--- a/gcc/config/i386/linux.h
++++ b/gcc/config/i386/linux.h
+@@ -21,3 +21,4 @@ along with GCC; see the file COPYING3.  If not see
+ 
+ #define GNU_USER_LINK_EMULATION "elf_i386"
+ #define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux.so.2"
++#define MUSL_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-musl-i386.so.1"
+diff --git a/gcc/config/i386/linux64.h b/gcc/config/i386/linux64.h
+index 6185cce..5a3a977 100644
+--- a/gcc/config/i386/linux64.h
++++ b/gcc/config/i386/linux64.h
+@@ -30,3 +30,8 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+ #define GLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-linux.so.2"
+ #define GLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-linux-x86-64.so.2"
+ #define GLIBC_DYNAMIC_LINKERX32 SYSTEMLIBS_DIR "ld-linux-x32.so.2"
++
++#define MUSL_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-musl-i386.so.1"
++#define MUSL_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-musl-x86_64.so.1"
++#define MUSL_DYNAMIC_LINKERX32 SYSTEMLIBS_DIR "ld-musl-x32.so.1"
++
+diff --git a/gcc/config/mips/linux.h b/gcc/config/mips/linux.h
+index c306afb..b899388 100644
+--- a/gcc/config/mips/linux.h
++++ b/gcc/config/mips/linux.h
+@@ -21,6 +21,12 @@ along with GCC; see the file COPYING3.  If not see
+ #define GNU_USER_LINK_EMULATION64 "elf64%{EB:b}%{EL:l}tsmip"
+ #define GNU_USER_LINK_EMULATIONN32 "elf32%{EB:b}%{EL:l}tsmipn32"
+ 
++#undef MUSL_DYNAMIC_LINKER32
++#define MUSL_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-musl-mips%{EL:el}%{msoft-float:-sf}.so.1"
++#undef MUSL_DYNAMIC_LINKER64
++#define MUSL_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-musl-mips64%{EL:el}%{msoft-float:-sf}.so.1"
++#define MUSL_DYNAMIC_LINKERN32 SYSTEMLIBS_DIR "ld-musl-mipsn32%{EL:el}%{msoft-float:-sf}.so.1"
++
+ #define GLIBC_DYNAMIC_LINKER32 \
+   "%{mnan=2008:" SYSTEMLIBS_DIR "ld-linux-mipsn8.so.1;:" SYSTEMLIBS_DIR "ld.so.1}"
+ #define GLIBC_DYNAMIC_LINKER64 \
+@@ -40,4 +46,4 @@ along with GCC; see the file COPYING3.  If not see
+ #define BIONIC_DYNAMIC_LINKERN32 "/system/bin/linker32"
+ #define GNU_USER_DYNAMIC_LINKERN32 \
+   CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKERN32, UCLIBC_DYNAMIC_LINKERN32, \
+-                         BIONIC_DYNAMIC_LINKERN32)
++                         BIONIC_DYNAMIC_LINKERN32,  MUSL_DYNAMIC_LINKERN32)
+diff --git a/gcc/config/rs6000/linux64.h b/gcc/config/rs6000/linux64.h
+index 31c4338..679da4b 100644
+--- a/gcc/config/rs6000/linux64.h
++++ b/gcc/config/rs6000/linux64.h
+@@ -365,17 +365,22 @@ extern int dot_symbols;
+ #endif
+ #define UCLIBC_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-uClibc.so.0"
+ #define UCLIBC_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld64-uClibc.so.0"
++#define MUSL_DYNAMIC_LINKER32 SYSTEMLIBS_DIR "ld-musl-powerpc.so.1"
++#define MUSL_DYNAMIC_LINKER64 SYSTEMLIBS_DIR "ld-musl-powerpc64.so.1"
++
+ #if DEFAULT_LIBC == LIBC_UCLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{mmusl:" M ";:" U "}}"
+ #elif DEFAULT_LIBC == LIBC_GLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{muclibc:" U ";:" G "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{muclibc:" U ";:%{mmusl:" M ";:" G "}}"
++#elif DEFAULT_LIBC == LIBC_MUSL
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{muclibc:" U ";:" M "}}"
+ #else
+ #error "Unsupported DEFAULT_LIBC"
+ #endif
+ #define GNU_USER_DYNAMIC_LINKER32 \
+-  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32)
++  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER32, MUSL_DYNAMIC_LINKER32)
+ #define GNU_USER_DYNAMIC_LINKER64 \
+-  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64)
++  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64, MUSL_DYNAMIC_LINKER64)
+ 
+ #undef  DEFAULT_ASM_ENDIAN
+ #if (TARGET_DEFAULT & MASK_LITTLE_ENDIAN)
+diff --git a/gcc/config/rs6000/sysv4.h b/gcc/config/rs6000/sysv4.h
+index 7cd07e0..8794fa5 100644
+--- a/gcc/config/rs6000/sysv4.h
++++ b/gcc/config/rs6000/sysv4.h
+@@ -763,15 +763,19 @@ ENDIAN_SELECT(" -mbig", " -mlittle", DEFAULT_ASM_ENDIAN)
+ 
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
+ #define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
++#define MUSL_DYNAMIC_LINKER "/lib/ld-musl-powerpc.so.1"
++
+ #if DEFAULT_LIBC == LIBC_UCLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{mmusl:" M ";:" U "}}"
++#elif DEFAULT_LIBC == LIBC_MUSL
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{mglibc:" G ";:%{muclibc:" U ";:" M "}}"
+ #elif !defined (DEFAULT_LIBC) || DEFAULT_LIBC == LIBC_GLIBC
+-#define CHOOSE_DYNAMIC_LINKER(G, U) "%{muclibc:" U ";:" G "}"
++#define CHOOSE_DYNAMIC_LINKER(G, U, M) "%{muclibc:" U ";:%{mmusl:" M ";:" G "}}"
+ #else
+ #error "Unsupported DEFAULT_LIBC"
+ #endif
+ #define GNU_USER_DYNAMIC_LINKER \
+-  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER)
++  CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER, MUSL_DYNAMIC_LINKER)
+ 
+ #define LINK_OS_LINUX_SPEC "-m elf32ppclinux %{!shared: %{!static: \
+   %{rdynamic:-export-dynamic} \
+diff --git a/libitm/config/arm/hwcap.cc b/libitm/config/arm/hwcap.cc
+index a1c2cfd..dd4fad2 100644
+--- a/libitm/config/arm/hwcap.cc
++++ b/libitm/config/arm/hwcap.cc
+@@ -40,7 +40,11 @@ int GTM_hwcap HIDDEN = 0
+ 
+ #ifdef __linux__
+ #include <unistd.h>
++#ifdef __GLIBC__
+ #include <sys/fcntl.h>
++#else
++#include <fcntl.h>
++#endif
+ #include <elf.h>
+ 
+ static void __attribute__((constructor))
+diff --git a/libitm/config/linux/x86/tls.h b/libitm/config/linux/x86/tls.h
+index e731ab7..54ad8b6 100644
+--- a/libitm/config/linux/x86/tls.h
++++ b/libitm/config/linux/x86/tls.h
+@@ -25,16 +25,19 @@
+ #ifndef LIBITM_X86_TLS_H
+ #define LIBITM_X86_TLS_H 1
+ 
+-#if defined(__GLIBC_PREREQ) && __GLIBC_PREREQ(2, 10)
++#if defined(__GLIBC_PREREQ)
++#if __GLIBC_PREREQ(2, 10)
+ /* Use slots in the TCB head rather than __thread lookups.
+    GLIBC has reserved words 10 through 13 for TM.  */
+ #define HAVE_ARCH_GTM_THREAD 1
+ #define HAVE_ARCH_GTM_THREAD_DISP 1
+ #endif
++#endif
+ 
+ #include "config/generic/tls.h"
+ 
+-#if defined(__GLIBC_PREREQ) && __GLIBC_PREREQ(2, 10)
++#if defined(__GLIBC_PREREQ)
++#if __GLIBC_PREREQ(2, 10)
+ namespace GTM HIDDEN {
+ 
+ #ifdef __x86_64__
+@@ -101,5 +104,6 @@ static inline void set_abi_disp(struct abi_dispatch *x)
+ 
+ } // namespace GTM
+ #endif /* >= GLIBC 2.10 */
++#endif
+ 
+ #endif // LIBITM_X86_TLS_H
+-- 
+2.7.4
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0046-Get-rid-of-ever-broken-fixincludes-on-musl.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0046-Get-rid-of-ever-broken-fixincludes-on-musl.patch
new file mode 100644
index 0000000..ddb0fc4
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0046-Get-rid-of-ever-broken-fixincludes-on-musl.patch
@@ -0,0 +1,28 @@
+From 047116e8c9cbb340264f4f28db3f21a68ba57ff3 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 8 Dec 2015 08:32:24 +0000
+Subject: [PATCH 46/46] Get rid of ever-broken fixincludes on musl.
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ fixincludes/mkfixinc.sh | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/fixincludes/mkfixinc.sh b/fixincludes/mkfixinc.sh
+index 6653fedb..0d96c8c 100755
+--- a/fixincludes/mkfixinc.sh
++++ b/fixincludes/mkfixinc.sh
+@@ -19,7 +19,8 @@ case $machine in
+     powerpc-*-eabi*    | \
+     powerpc-*-rtems*   | \
+     powerpcle-*-eabisim* | \
+-    powerpcle-*-eabi* )
++    powerpcle-*-eabi* | \
++    *-musl* )
+ 	#  IF there is no include fixing,
+ 	#  THEN create a no-op fixer and exit
+ 	(echo "#! /bin/sh" ; echo "exit 0" ) > ${target}
+-- 
+2.6.3
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0047-nios2-Define-MUSL_DYNAMIC_LINKER.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0047-nios2-Define-MUSL_DYNAMIC_LINKER.patch
new file mode 100644
index 0000000..a1cfb9c
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0047-nios2-Define-MUSL_DYNAMIC_LINKER.patch
@@ -0,0 +1,28 @@
+From f5ca07132b9292d2045ca7204e9cbfde2e59d0bf Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 2 Feb 2016 10:26:10 -0800
+Subject: [PATCH 47/48] nios2: Define MUSL_DYNAMIC_LINKER
+
+Signed-off-by: Marek Vasut <marex@denx.de>
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ gcc/config/nios2/linux.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/gcc/config/nios2/linux.h b/gcc/config/nios2/linux.h
+index f43f655..5587ab3 100644
+--- a/gcc/config/nios2/linux.h
++++ b/gcc/config/nios2/linux.h
+@@ -30,6 +30,7 @@
+ #define CPP_SPEC "%{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}"
+ 
+ #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-nios2.so.1"
++#define MUSL_DYNAMIC_LINKER  "/lib/ld-musl-nios2.so.1"
+ 
+ #undef LINK_SPEC
+ #define LINK_SPEC LINK_SPEC_ENDIAN \
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0048-ssp_nonshared.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0048-ssp_nonshared.patch
new file mode 100644
index 0000000..5ddd40a
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0048-ssp_nonshared.patch
@@ -0,0 +1,29 @@
+From 3cb6013cf287ed9b1247ea37541e64b9810a121d Mon Sep 17 00:00:00 2001
+From: Szabolcs Nagy <nsz@port70.net>
+Date: Sat, 7 Nov 2015 14:58:40 +0000
+Subject: [PATCH 48/48] ssp_nonshared
+
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Pending
+
+ gcc/gcc.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/gcc/gcc.c b/gcc/gcc.c
+index 8f53aea..3ddc658 100644
+--- a/gcc/gcc.c
++++ b/gcc/gcc.c
+@@ -732,7 +732,8 @@ proper position among the other output files.  */
+ #ifndef LINK_SSP_SPEC
+ #ifdef TARGET_LIBC_PROVIDES_SSP
+ #define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all" \
+-		       "|fstack-protector-strong|fstack-protector-explicit:}"
++		       "|fstack-protector-strong|fstack-protector-explicit" \
++		       ":-lssp_nonshared}"
+ #else
+ #define LINK_SSP_SPEC "%{fstack-protector|fstack-protector-all" \
+ 		       "|fstack-protector-strong|fstack-protector-explicit" \
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0049-Disable-the-weak-reference-logic-in-gthr.h-for-os-ge.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0049-Disable-the-weak-reference-logic-in-gthr.h-for-os-ge.patch
new file mode 100644
index 0000000..0ea5143
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0049-Disable-the-weak-reference-logic-in-gthr.h-for-os-ge.patch
@@ -0,0 +1,78 @@
+From 553d8e3b9073ff3e0a9d2fac9b1823fb17ad247c Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 2 Feb 2016 21:00:18 -0800
+Subject: [PATCH 49/51] Disable the weak reference logic in gthr.h for
+ os/generic
+
+It does not work unless work arounds are there in gthr-posix.h
+
+origin of patch
+http://port70.net/~nsz/musl/gcc-5.3.0/0004-gthr.patch
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ libgfortran/acinclude.m4                    | 2 +-
+ libgfortran/configure                       | 2 +-
+ libstdc++-v3/config/os/generic/os_defines.h | 5 +++++
+ libstdc++-v3/configure.host                 | 3 +++
+ 4 files changed, 10 insertions(+), 2 deletions(-)
+
+diff --git a/libgfortran/acinclude.m4 b/libgfortran/acinclude.m4
+index ba890f9..30b8b1a6 100644
+--- a/libgfortran/acinclude.m4
++++ b/libgfortran/acinclude.m4
+@@ -100,7 +100,7 @@ void foo (void);
+ 	      [Define to 1 if the target supports #pragma weak])
+   fi
+   case "$host" in
+-    *-*-darwin* | *-*-hpux* | *-*-cygwin* | *-*-mingw* )
++    *-*-darwin* | *-*-hpux* | *-*-cygwin* | *-*-mingw* | *-*-musl* )
+       AC_DEFINE(GTHREAD_USE_WEAK, 0,
+ 		[Define to 0 if the target shouldn't use #pragma weak])
+       ;;
+diff --git a/libgfortran/configure b/libgfortran/configure
+index 5d47e65..cdf9695 100755
+--- a/libgfortran/configure
++++ b/libgfortran/configure
+@@ -26456,7 +26456,7 @@ $as_echo "#define SUPPORTS_WEAK 1" >>confdefs.h
+ 
+   fi
+   case "$host" in
+-    *-*-darwin* | *-*-hpux* | *-*-cygwin* | *-*-mingw* )
++    *-*-darwin* | *-*-hpux* | *-*-cygwin* | *-*-mingw* | *-*-musl* )
+ 
+ $as_echo "#define GTHREAD_USE_WEAK 0" >>confdefs.h
+ 
+diff --git a/libstdc++-v3/config/os/generic/os_defines.h b/libstdc++-v3/config/os/generic/os_defines.h
+index 45bf52a..103ec0e 100644
+--- a/libstdc++-v3/config/os/generic/os_defines.h
++++ b/libstdc++-v3/config/os/generic/os_defines.h
+@@ -33,4 +33,9 @@
+ // System-specific #define, typedefs, corrections, etc, go here.  This
+ // file will come before all others.
+ 
++// Disable the weak reference logic in gthr.h for os/generic because it
++// is broken on every platform unless there is implementation specific
++// workaround in gthr-posix.h and at link-time for static linking.
++#define _GLIBCXX_GTHREAD_USE_WEAK 0
++
+ #endif
+diff --git a/libstdc++-v3/configure.host b/libstdc++-v3/configure.host
+index 1756444..2a87bb8 100644
+--- a/libstdc++-v3/configure.host
++++ b/libstdc++-v3/configure.host
+@@ -273,6 +273,9 @@ case "${host_os}" in
+   freebsd*)
+     os_include_dir="os/bsd/freebsd"
+     ;;
++  linux-musl*)
++    os_include_dir="os/generic"
++    ;;
+   gnu* | linux* | kfreebsd*-gnu | knetbsd*-gnu)
+     # check for musl by target
+     case "${host_os}" in
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0050-powerpc-pass-secure-plt-to-the-linker.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0050-powerpc-pass-secure-plt-to-the-linker.patch
new file mode 100644
index 0000000..b2f2bbd
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0050-powerpc-pass-secure-plt-to-the-linker.patch
@@ -0,0 +1,66 @@
+From 4fa0cf03678f849917dcc3d149989b7fecdbe276 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 2 Feb 2016 21:10:00 -0800
+Subject: [PATCH 50/51] powerpc pass --secure-plt to the linker
+
+Secure-plt when enabled does not pass right options to linker
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+ gcc/config/rs6000/linux64.h | 4 ++++
+ gcc/config/rs6000/sysv4.h   | 2 ++
+ 2 files changed, 6 insertions(+)
+
+diff --git a/gcc/config/rs6000/linux64.h b/gcc/config/rs6000/linux64.h
+index 679da4b..3ca7cd7 100644
+--- a/gcc/config/rs6000/linux64.h
++++ b/gcc/config/rs6000/linux64.h
+@@ -174,20 +174,24 @@ extern int dot_symbols;
+ #undef	ASM_DEFAULT_SPEC
+ #undef	ASM_SPEC
+ #undef	LINK_OS_LINUX_SPEC
++#undef	LINK_SECURE_PLT_SPEC
+ 
+ #ifndef	RS6000_BI_ARCH
+ #define	ASM_DEFAULT_SPEC "-mppc64"
+ #define	ASM_SPEC	 "%(asm_spec64) %(asm_spec_common)"
+ #define	LINK_OS_LINUX_SPEC "%(link_os_linux_spec64)"
++#define	LINK_SECURE_PLT_SPEC ""
+ #else
+ #if DEFAULT_ARCH64_P
+ #define	ASM_DEFAULT_SPEC "-mppc%{!m32:64}"
+ #define	ASM_SPEC	 "%{m32:%(asm_spec32)}%{!m32:%(asm_spec64)} %(asm_spec_common)"
+ #define	LINK_OS_LINUX_SPEC "%{m32:%(link_os_linux_spec32)}%{!m32:%(link_os_linux_spec64)}"
++#define	LINK_SECURE_PLT_SPEC "%{m32: " LINK_SECURE_PLT_DEFAULT_SPEC "}"
+ #else
+ #define	ASM_DEFAULT_SPEC "-mppc%{m64:64}"
+ #define	ASM_SPEC	 "%{!m64:%(asm_spec32)}%{m64:%(asm_spec64)} %(asm_spec_common)"
+ #define	LINK_OS_LINUX_SPEC "%{!m64:%(link_os_linux_spec32)}%{m64:%(link_os_linux_spec64)}"
++#define	LINK_SECURE_PLT_SPEC "%{!m64: " LINK_SECURE_PLT_DEFAULT_SPEC "}"
+ #endif
+ #endif
+ 
+diff --git a/gcc/config/rs6000/sysv4.h b/gcc/config/rs6000/sysv4.h
+index 8794fa5..0835551 100644
+--- a/gcc/config/rs6000/sysv4.h
++++ b/gcc/config/rs6000/sysv4.h
+@@ -571,6 +571,7 @@ ENDIAN_SELECT(" -mbig", " -mlittle", DEFAULT_ASM_ENDIAN)
+                : %(link_start_default)     }"
+ 
+ #define LINK_START_DEFAULT_SPEC ""
++#define LINK_SECURE_PLT_SPEC LINK_SECURE_PLT_DEFAULT_SPEC
+ 
+ #undef	LINK_SPEC
+ #define	LINK_SPEC "\
+@@ -578,6 +579,7 @@ ENDIAN_SELECT(" -mbig", " -mlittle", DEFAULT_ASM_ENDIAN)
+ %{R*} \
+ %(link_shlib) \
+ %{!T*: %(link_start) } \
++%{!static: %{!mbss-plt: %(link_secure_plt_default)}} \
+ %(link_os)"
+ 
+ /* Shared libraries are not default.  */
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0051-Ignore-fdebug-prefix-map-in-producer-string-by-Danie.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0051-Ignore-fdebug-prefix-map-in-producer-string-by-Danie.patch
new file mode 100644
index 0000000..e8f79b5
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0051-Ignore-fdebug-prefix-map-in-producer-string-by-Danie.patch
@@ -0,0 +1,31 @@
+From 32593b38082ea65f4c82159254adf1e0dc2423be Mon Sep 17 00:00:00 2001
+From: bernds <bernds@138bc75d-0d04-0410-961f-82ee72b054a4>
+Date: Tue, 16 Feb 2016 03:15:15 -0500
+Subject: [PATCH] Ignore -fdebug-prefix-map in producer string (by Daniel Kahn
+ Gillmor)
+
+* dwarf2out.c (gen_producer_string): Ignore -fdebug-prefix-map.
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@231835 138bc75d-0d04-0410-961f-82ee72b054a4
+
+Upstream-Status: Backport
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ gcc/dwarf2out.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c
+index 3614c10..526f114 100644
+--- a/gcc/dwarf2out.c
++++ b/gcc/dwarf2out.c
+@@ -19670,6 +19670,7 @@ gen_producer_string (void)
+       case OPT_fpreprocessed:
+       case OPT_fltrans_output_list_:
+       case OPT_fresolution_:
++      case OPT_fdebug_prefix_map_:
+ 	/* Ignore these.  */
+ 	continue;
+       default:
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0052-nios2-use-ret-with-r31.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0052-nios2-use-ret-with-r31.patch
new file mode 100644
index 0000000..f3cb47f
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0052-nios2-use-ret-with-r31.patch
@@ -0,0 +1,103 @@
+From 1d67120d95c2c6e0ed4f7357d1cc62887eaba463 Mon Sep 17 00:00:00 2001
+From: sandra <sandra@138bc75d-0d04-0410-961f-82ee72b054a4>
+Date: Tue, 12 May 2015 15:57:22 +0000
+Subject: [PATCH] 2015-05-12  Chung-Lin Tang  <cltang@codesourcery.com>
+ Sandra Loosemore <sandra@codesourcery.com>
+
+	gcc/
+	* config/nios2/nios2.h (enum reg_class): Add IJMP_REGS enum
+	value.
+	(REG_CLASS_NAMES): Add "IJMP_REGS".
+	(REG_CLASS_CONTENTS): Add new entry for IJMP_REGS.
+	* config/nios2/nios2.md (indirect_jump,*tablejump): Adjust to
+	use new "c" register constraint.
+	* config/nios2/constraint.md (c): New register constraint
+	corresponding to IJMP_REGS.
+
+
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@223082 138bc75d-0d04-0410-961f-82ee72b054a4
+Signed-off-by: Marek Vasut <marex@denx.de>
+Upstream-Status: Backport [ git://gcc.gnu.org/git/gcc.git 1d67120d95c2c6e0ed4f7357d1cc62887eaba463 ]
+---
+ gcc/ChangeLog                   | 12 ++++++++++++
+ gcc/config/nios2/constraints.md |  3 +++
+ gcc/config/nios2/nios2.h        | 11 +++++++----
+ gcc/config/nios2/nios2.md       |  4 ++--
+ 4 files changed, 24 insertions(+), 6 deletions(-)
+
+diff --git a/gcc/config/nios2/constraints.md b/gcc/config/nios2/constraints.md
+index f4bd9f7..735f892 100644
+--- a/gcc/config/nios2/constraints.md
++++ b/gcc/config/nios2/constraints.md
+@@ -39,6 +39,9 @@
+ 
+ ;; Register constraints
+ 
++(define_register_constraint "c" "IJMP_REGS"
++  "A register suitable for an indirect jump.")
++
+ (define_register_constraint "j" "SIB_REGS"
+   "A register suitable for an indirect sibcall.")
+ 
+diff --git a/gcc/config/nios2/nios2.h b/gcc/config/nios2/nios2.h
+index 510ab5f..ac33978 100644
+--- a/gcc/config/nios2/nios2.h
++++ b/gcc/config/nios2/nios2.h
+@@ -173,6 +173,7 @@ enum reg_class
+ {
+   NO_REGS,
+   SIB_REGS,
++  IJMP_REGS,
+   GP_REGS,
+   ALL_REGS,
+   LIM_REG_CLASSES
+@@ -183,6 +184,7 @@ enum reg_class
+ #define REG_CLASS_NAMES   \
+   {  "NO_REGS",		  \
+      "SIB_REGS",	  \
++     "IJMP_REGS",	  \
+      "GP_REGS",           \
+      "ALL_REGS" }
+ 
+@@ -190,10 +192,11 @@ enum reg_class
+ 
+ #define REG_CLASS_CONTENTS			\
+   {						\
+-    /* NO_REGS  */ { 0, 0},			\
+-    /* SIB_REGS */ { 0xfe0c, 0},		\
+-    /* GP_REGS  */ {~0, 0},			\
+-    /* ALL_REGS */ {~0,~0}			\
++    /* NO_REGS    */ { 0, 0},			\
++    /* SIB_REGS   */ { 0xfe0c, 0},		\
++    /* IJMP_REGS  */ { 0x7fffffff, 0},		\
++    /* GP_REGS    */ {~0, 0},			\
++    /* ALL_REGS   */ {~0,~0}			\
+   }
+ 
+ 
+diff --git a/gcc/config/nios2/nios2.md b/gcc/config/nios2/nios2.md
+index 7b35d269..36ef101 100644
+--- a/gcc/config/nios2/nios2.md
++++ b/gcc/config/nios2/nios2.md
+@@ -697,7 +697,7 @@
+ ; check or adjust for overflow.
+ 
+ (define_insn "indirect_jump"
+-  [(set (pc) (match_operand:SI 0 "register_operand" "r"))]
++  [(set (pc) (match_operand:SI 0 "register_operand" "c"))]
+   ""
+   "jmp\\t%0"
+   [(set_attr "type" "control")])
+@@ -811,7 +811,7 @@
+ 
+ (define_insn "*tablejump"
+   [(set (pc)
+-        (match_operand:SI 0 "register_operand" "r"))
++        (match_operand:SI 0 "register_operand" "c"))
+    (use (label_ref (match_operand 1 "" "")))]
+   ""
+   "jmp\\t%0"
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0053-expr.c-PR-target-65358-Avoid-clobbering-partial-argu.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0053-expr.c-PR-target-65358-Avoid-clobbering-partial-argu.patch
new file mode 100644
index 0000000..c18f40e
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0053-expr.c-PR-target-65358-Avoid-clobbering-partial-argu.patch
@@ -0,0 +1,307 @@
+From 536b8318974495cde2b42c3c2742748e2b271be0 Mon Sep 17 00:00:00 2001
+From: ktkachov <ktkachov@138bc75d-0d04-0410-961f-82ee72b054a4>
+Date: Wed, 27 May 2015 13:25:01 +0000
+Subject: [PATCH] PR target/65358 Avoid clobbering partial argument during
+ sibcall
+
+	PR target/65358
+	* expr.c (memory_load_overlap): New function.
+	(emit_push_insn): When pushing partial args to the stack would
+	clobber the register part load the overlapping part into a pseudo
+	and put it into the hard reg after pushing.  Change return type
+	to bool.  Add bool argument.
+	* expr.h (emit_push_insn): Change return type to bool.
+	Add bool argument.
+	* calls.c (expand_call): Cancel sibcall optimization when encountering
+	partial argument on targets with ARGS_GROW_DOWNWARD and
+	!STACK_GROWS_DOWNWARD.
+	(emit_library_call_value_1): Update callsite of emit_push_insn.
+	(store_one_arg): Likewise.
+
+	PR target/65358
+	* gcc.dg/pr65358.c: New test.
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@223753 138bc75d-0d04-0410-961f-82ee72b054a4
+
+Upstream-Status: Backport from 6.0
+Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
+---
+ gcc/calls.c                    | 17 ++++++--
+ gcc/expr.c                     | 90 +++++++++++++++++++++++++++++++++++++-----
+ gcc/expr.h                     |  4 +-
+ gcc/testsuite/gcc.dg/pr65358.c | 33 ++++++++++++++++
+ 4 files changed, 129 insertions(+), 15 deletions(-)
+ create mode 100644 gcc/testsuite/gcc.dg/pr65358.c
+
+diff --git a/gcc/calls.c b/gcc/calls.c
+index ee8ea5f..2334381 100644
+--- a/gcc/calls.c
++++ b/gcc/calls.c
+@@ -3236,6 +3236,14 @@ expand_call (tree exp, rtx target, int ignore)
+ 	    {
+ 	      rtx_insn *before_arg = get_last_insn ();
+ 
++	     /* On targets with weird calling conventions (e.g. PA) it's
++		hard to ensure that all cases of argument overlap between
++		stack and registers work.  Play it safe and bail out.  */
++#if defined(ARGS_GROW_DOWNWARD) && !defined(STACK_GROWS_DOWNWARD)
++		  sibcall_failure = 1;
++		  break;
++#endif
++
+ 	      if (store_one_arg (&args[i], argblock, flags,
+ 				 adjusted_args_size.var != 0,
+ 				 reg_parm_stack_space)
+@@ -4279,7 +4287,7 @@ emit_library_call_value_1 (int retval, rtx orgfun, rtx value,
+ 			  partial, reg, 0, argblock,
+ 			  GEN_INT (argvec[argnum].locate.offset.constant),
+ 			  reg_parm_stack_space,
+-			  ARGS_SIZE_RTX (argvec[argnum].locate.alignment_pad));
++			  ARGS_SIZE_RTX (argvec[argnum].locate.alignment_pad), false);
+ 
+ 	  /* Now mark the segment we just used.  */
+ 	  if (ACCUMULATE_OUTGOING_ARGS)
+@@ -4886,10 +4894,11 @@ store_one_arg (struct arg_data *arg, rtx argblock, int flags,
+ 
+       /* This isn't already where we want it on the stack, so put it there.
+ 	 This can either be done with push or copy insns.  */
+-      emit_push_insn (arg->value, arg->mode, TREE_TYPE (pval), NULL_RTX,
++      if (!emit_push_insn (arg->value, arg->mode, TREE_TYPE (pval), NULL_RTX,
+ 		      parm_align, partial, reg, used - size, argblock,
+ 		      ARGS_SIZE_RTX (arg->locate.offset), reg_parm_stack_space,
+-		      ARGS_SIZE_RTX (arg->locate.alignment_pad));
++		      ARGS_SIZE_RTX (arg->locate.alignment_pad), true))
++	sibcall_failure = 1;
+ 
+       /* Unless this is a partially-in-register argument, the argument is now
+ 	 in the stack.  */
+@@ -5001,7 +5010,7 @@ store_one_arg (struct arg_data *arg, rtx argblock, int flags,
+       emit_push_insn (arg->value, arg->mode, TREE_TYPE (pval), size_rtx,
+ 		      parm_align, partial, reg, excess, argblock,
+ 		      ARGS_SIZE_RTX (arg->locate.offset), reg_parm_stack_space,
+-		      ARGS_SIZE_RTX (arg->locate.alignment_pad));
++		      ARGS_SIZE_RTX (arg->locate.alignment_pad), false);
+ 
+       /* Unless this is a partially-in-register argument, the argument is now
+ 	 in the stack.
+diff --git a/gcc/expr.c b/gcc/expr.c
+index 5c09550..24a6293 100644
+--- a/gcc/expr.c
++++ b/gcc/expr.c
+@@ -4121,12 +4121,35 @@ emit_single_push_insn (machine_mode mode, rtx x, tree type)
+ }
+ #endif
+ 
++/* If reading SIZE bytes from X will end up reading from
++   Y return the number of bytes that overlap.  Return -1
++   if there is no overlap or -2 if we can't determine
++   (for example when X and Y have different base registers).  */
++
++static int
++memory_load_overlap (rtx x, rtx y, HOST_WIDE_INT size)
++{
++  rtx tmp = plus_constant (Pmode, x, size);
++  rtx sub = simplify_gen_binary (MINUS, Pmode, tmp, y);
++
++  if (!CONST_INT_P (sub))
++    return -2;
++
++  HOST_WIDE_INT val = INTVAL (sub);
++
++  return IN_RANGE (val, 1, size) ? val : -1;
++}
++
+ /* Generate code to push X onto the stack, assuming it has mode MODE and
+    type TYPE.
+    MODE is redundant except when X is a CONST_INT (since they don't
+    carry mode info).
+    SIZE is an rtx for the size of data to be copied (in bytes),
+    needed only if X is BLKmode.
++   Return true if successful.  May return false if asked to push a
++   partial argument during a sibcall optimization (as specified by
++   SIBCALL_P) and the incoming and outgoing pointers cannot be shown
++   to not overlap.
+ 
+    ALIGN (in bits) is maximum alignment we can assume.
+ 
+@@ -4152,11 +4175,11 @@ emit_single_push_insn (machine_mode mode, rtx x, tree type)
+    for arguments passed in registers.  If nonzero, it will be the number
+    of bytes required.  */
+ 
+-void
++bool
+ emit_push_insn (rtx x, machine_mode mode, tree type, rtx size,
+ 		unsigned int align, int partial, rtx reg, int extra,
+ 		rtx args_addr, rtx args_so_far, int reg_parm_stack_space,
+-		rtx alignment_pad)
++		rtx alignment_pad, bool sibcall_p)
+ {
+   rtx xinner;
+   enum direction stack_direction
+@@ -4179,6 +4202,10 @@ emit_push_insn (rtx x, machine_mode mode, tree type, rtx size,
+ 
+   xinner = x;
+ 
++  int nregs = partial / UNITS_PER_WORD;
++  rtx *tmp_regs = NULL;
++  int overlapping = 0;
++
+   if (mode == BLKmode
+       || (STRICT_ALIGNMENT && align < GET_MODE_ALIGNMENT (mode)))
+     {
+@@ -4309,6 +4336,43 @@ emit_push_insn (rtx x, machine_mode mode, tree type, rtx size,
+ 	     PARM_BOUNDARY.  Assume the caller isn't lying.  */
+ 	  set_mem_align (target, align);
+ 
++	  /* If part should go in registers and pushing to that part would
++	     overwrite some of the values that need to go into regs, load the
++	     overlapping values into temporary pseudos to be moved into the hard
++	     regs at the end after the stack pushing has completed.
++	     We cannot load them directly into the hard regs here because
++	     they can be clobbered by the block move expansions.
++	     See PR 65358.  */
++
++	  if (partial > 0 && reg != 0 && mode == BLKmode
++	      && GET_CODE (reg) != PARALLEL)
++	    {
++	      overlapping = memory_load_overlap (XEXP (x, 0), temp, partial);
++	      if (overlapping > 0)
++	        {
++		  gcc_assert (overlapping % UNITS_PER_WORD == 0);
++		  overlapping /= UNITS_PER_WORD;
++
++		  tmp_regs = XALLOCAVEC (rtx, overlapping);
++
++		  for (int i = 0; i < overlapping; i++)
++		    tmp_regs[i] = gen_reg_rtx (word_mode);
++
++		  for (int i = 0; i < overlapping; i++)
++		    emit_move_insn (tmp_regs[i],
++				    operand_subword_force (target, i, mode));
++	        }
++	      else if (overlapping == -1)
++		overlapping = 0;
++	      /* Could not determine whether there is overlap.
++	         Fail the sibcall.  */
++	      else
++		{
++		  overlapping = 0;
++		  if (sibcall_p)
++		    return false;
++		}
++	    }
+ 	  emit_block_move (target, xinner, size, BLOCK_OP_CALL_PARM);
+ 	}
+     }
+@@ -4363,12 +4427,13 @@ emit_push_insn (rtx x, machine_mode mode, tree type, rtx size,
+ 	 has a size a multiple of a word.  */
+       for (i = size - 1; i >= not_stack; i--)
+ 	if (i >= not_stack + offset)
+-	  emit_push_insn (operand_subword_force (x, i, mode),
++	  if (!emit_push_insn (operand_subword_force (x, i, mode),
+ 			  word_mode, NULL_TREE, NULL_RTX, align, 0, NULL_RTX,
+ 			  0, args_addr,
+ 			  GEN_INT (args_offset + ((i - not_stack + skip)
+ 						  * UNITS_PER_WORD)),
+-			  reg_parm_stack_space, alignment_pad);
++			  reg_parm_stack_space, alignment_pad, sibcall_p))
++	    return false;
+     }
+   else
+     {
+@@ -4411,9 +4476,8 @@ emit_push_insn (rtx x, machine_mode mode, tree type, rtx size,
+ 	}
+     }
+ 
+-  /* If part should go in registers, copy that part
+-     into the appropriate registers.  Do this now, at the end,
+-     since mem-to-mem copies above may do function calls.  */
++  /* Move the partial arguments into the registers and any overlapping
++     values that we moved into the pseudos in tmp_regs.  */
+   if (partial > 0 && reg != 0)
+     {
+       /* Handle calls that pass values in multiple non-contiguous locations.
+@@ -4421,9 +4485,15 @@ emit_push_insn (rtx x, machine_mode mode, tree type, rtx size,
+       if (GET_CODE (reg) == PARALLEL)
+ 	emit_group_load (reg, x, type, -1);
+       else
+-	{
++        {
+ 	  gcc_assert (partial % UNITS_PER_WORD == 0);
+-	  move_block_to_reg (REGNO (reg), x, partial / UNITS_PER_WORD, mode);
++	  move_block_to_reg (REGNO (reg), x, nregs - overlapping, mode);
++
++	  for (int i = 0; i < overlapping; i++)
++	    emit_move_insn (gen_rtx_REG (word_mode, REGNO (reg)
++						    + nregs - overlapping + i),
++			    tmp_regs[i]);
++
+ 	}
+     }
+ 
+@@ -4432,6 +4502,8 @@ emit_push_insn (rtx x, machine_mode mode, tree type, rtx size,
+ 
+   if (alignment_pad && args_addr == 0)
+     anti_adjust_stack (alignment_pad);
++
++  return true;
+ }
+ 
+ /* Return X if X can be used as a subtarget in a sequence of arithmetic
+diff --git a/gcc/expr.h b/gcc/expr.h
+index 867852e..5fcc13f 100644
+--- a/gcc/expr.h
++++ b/gcc/expr.h
+@@ -218,8 +218,8 @@ extern rtx emit_move_resolve_push (machine_mode, rtx);
+ extern rtx push_block (rtx, int, int);
+ 
+ /* Generate code to push something onto the stack, given its mode and type.  */
+-extern void emit_push_insn (rtx, machine_mode, tree, rtx, unsigned int,
+-			    int, rtx, int, rtx, rtx, int, rtx);
++extern bool emit_push_insn (rtx, machine_mode, tree, rtx, unsigned int,
++			    int, rtx, int, rtx, rtx, int, rtx, bool);
+ 
+ /* Expand an assignment that stores the value of FROM into TO.  */
+ extern void expand_assignment (tree, tree, bool);
+diff --git a/gcc/testsuite/gcc.dg/pr65358.c b/gcc/testsuite/gcc.dg/pr65358.c
+new file mode 100644
+index 0000000..ba89fd4
+--- /dev/null
++++ b/gcc/testsuite/gcc.dg/pr65358.c
+@@ -0,0 +1,33 @@
++/* { dg-do run } */
++/* { dg-options "-O2" } */
++
++struct pack
++{
++  int fine;
++  int victim;
++  int killer;
++};
++
++int __attribute__ ((__noinline__, __noclone__))
++bar (int a, int b, struct pack p)
++{
++  if (a != 20 || b != 30)
++    __builtin_abort ();
++  if (p.fine != 40 || p.victim != 50 || p.killer != 60)
++    __builtin_abort ();
++  return 0;
++}
++
++int __attribute__ ((__noinline__, __noclone__))
++foo (int arg1, int arg2, int arg3, struct pack p)
++{
++  return bar (arg2, arg3, p);
++}
++
++int main (void)
++{
++  struct pack p = { 40, 50, 60 };
++
++  (void) foo (10, 20, 30, p);
++  return 0;
++}
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0054-support-ffile-prefix-map.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0054-support-ffile-prefix-map.patch
new file mode 100644
index 0000000..da16879
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0054-support-ffile-prefix-map.patch
@@ -0,0 +1,284 @@
+From ef7c2bda6b4c88f8007ed663b1108cd4651598c8 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 16 Mar 2016 02:27:43 -0400
+Subject: [PATCH] gcc/libcpp: support -ffile-prefix-map=<old>=<new>
+
+Similar -fdebug-prefix-map, add option -ffile-prefix-map to map one
+directory name (old) to another (new) in __FILE__, __BASE_FILE__ and
+__builtin_FILE ().
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70268
+
+Upstream-Status: Submitted [gcc-patches@gcc.gnu.org]
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ gcc/c-family/c-opts.c     |  6 ++++
+ gcc/c-family/c.opt        |  4 +++
+ gcc/dwarf2out.c           |  1 +
+ gcc/gimplify.c            |  2 ++
+ libcpp/Makefile.in        | 10 +++---
+ libcpp/file-map.c         | 92 +++++++++++++++++++++++++++++++++++++++++++++++
+ libcpp/include/file-map.h | 30 ++++++++++++++++
+ libcpp/macro.c            |  2 ++
+ 8 files changed, 142 insertions(+), 5 deletions(-)
+ create mode 100644 libcpp/file-map.c
+ create mode 100644 libcpp/include/file-map.h
+
+diff --git a/gcc/c-family/c-opts.c b/gcc/c-family/c-opts.c
+index 718a052..3f93c56 100644
+--- a/gcc/c-family/c-opts.c
++++ b/gcc/c-family/c-opts.c
+@@ -46,6 +46,7 @@ along with GCC; see the file COPYING3.  If not see
+ #include "opts.h"
+ #include "plugin.h"		/* For PLUGIN_INCLUDE_FILE event.  */
+ #include "mkdeps.h"
++#include "file-map.h"
+ #include "c-target.h"
+ #include "tm.h"			/* For BYTES_BIG_ENDIAN,
+ 				   DOLLARS_IN_IDENTIFIERS,
+@@ -510,6 +511,11 @@ c_common_handle_option (size_t scode, const char *arg, int value,
+       cpp_opts->narrow_charset = arg;
+       break;
+ 
++    case OPT_ffile_prefix_map_:
++      if (add_file_prefix_map (arg) < 0)
++        error ("invalid argument %qs to -ffile-prefix-map", arg);
++      break;
++
+     case OPT_fwide_exec_charset_:
+       cpp_opts->wide_charset = arg;
+       break;
+diff --git a/gcc/c-family/c.opt b/gcc/c-family/c.opt
+index 453ec8e..30ad053 100644
+--- a/gcc/c-family/c.opt
++++ b/gcc/c-family/c.opt
+@@ -1117,6 +1117,10 @@ fexec-charset=
+ C ObjC C++ ObjC++ Joined RejectNegative
+ -fexec-charset=<cset>	Convert all strings and character constants to character set <cset>
+ 
++ffile-prefix-map=
++C ObjC C++ ObjC++ Joined RejectNegative
++-ffile-prefix-map=<old=new>	Map one directory name to another in __FILE__, __BASE_FILE__ and __builtin_FILE ()
++
+ fextended-identifiers
+ C ObjC C++ ObjC++
+ Permit universal character names (\\u and \\U) in identifiers
+diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c
+index 526f114..438a475 100644
+--- a/gcc/dwarf2out.c
++++ b/gcc/dwarf2out.c
+@@ -19671,6 +19671,7 @@ gen_producer_string (void)
+       case OPT_fltrans_output_list_:
+       case OPT_fresolution_:
+       case OPT_fdebug_prefix_map_:
++      case OPT_ffile_prefix_map_:
+ 	/* Ignore these.  */
+ 	continue;
+       default:
+diff --git a/gcc/gimplify.c b/gcc/gimplify.c
+index c85f83a..1ffe1e1 100644
+--- a/gcc/gimplify.c
++++ b/gcc/gimplify.c
+@@ -87,6 +87,7 @@ along with GCC; see the file COPYING3.  If not see
+ #include "gimple-low.h"
+ #include "cilk.h"
+ #include "gomp-constants.h"
++#include "file-map.h"
+ 
+ #include "langhooks-def.h"	/* FIXME: for lhd_set_decl_assembler_name */
+ #include "tree-pass.h"		/* FIXME: only for PROP_gimple_any */
+@@ -2370,6 +2371,7 @@ gimplify_call_expr (tree *expr_p, gimple_seq *pre_p, bool want_value)
+       case BUILT_IN_FILE:
+ 	{
+ 	  const char *locfile = LOCATION_FILE (EXPR_LOCATION (*expr_p));
++	  locfile = remap_file_filename (locfile);
+ 	  *expr_p = build_string_literal (strlen (locfile) + 1, locfile);
+ 	  return GS_OK;
+ 	}
+diff --git a/libcpp/Makefile.in b/libcpp/Makefile.in
+index ad35563..c210ff9 100644
+--- a/libcpp/Makefile.in
++++ b/libcpp/Makefile.in
+@@ -84,12 +84,12 @@ DEPMODE = $(CXXDEPMODE)
+ 
+ 
+ libcpp_a_OBJS = charset.o directives.o directives-only.o errors.o \
+-	expr.o files.o identifiers.o init.o lex.o line-map.o macro.o \
+-	mkdeps.o pch.o symtab.o traditional.o
++	expr.o file-map.o files.o identifiers.o init.o lex.o line-map.o \
++	macro.o mkdeps.o pch.o symtab.o traditional.o
+ 
+ libcpp_a_SOURCES = charset.c directives.c directives-only.c errors.c \
+-	expr.c files.c identifiers.c init.c lex.c line-map.c macro.c \
+-	mkdeps.c pch.c symtab.c traditional.c
++	expr.c file-map.c files.c identifiers.c init.c lex.c line-map.c \
++	macro.c mkdeps.c pch.c symtab.c traditional.c
+ 
+ all: libcpp.a $(USED_CATALOGS)
+ 
+@@ -263,7 +263,7 @@ po/$(PACKAGE).pot: $(libcpp_a_SOURCES)
+ 
+ TAGS_SOURCES = $(libcpp_a_SOURCES) internal.h ucnid.h \
+     include/line-map.h include/symtab.h include/cpp-id-data.h \
+-    include/cpplib.h include/mkdeps.h system.h
++    include/cpplib.h include/mkdeps.h system.h include/file-map.h
+ 
+ TAGS: $(TAGS_SOURCES)
+ 	cd $(srcdir) && etags $(TAGS_SOURCES)
+diff --git a/libcpp/file-map.c b/libcpp/file-map.c
+new file mode 100644
+index 0000000..04e851b
+--- /dev/null
++++ b/libcpp/file-map.c
+@@ -0,0 +1,92 @@
++/* Map one directory name to another in __FILE__, __BASE_FILE__
++   and __builtin_FILE ().
++   Copyright (C) 2001-2016 Free Software Foundation, Inc.
++
++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 3, 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; see the file COPYING3.  If not see
++<http://www.gnu.org/licenses/>.
++
++ In other words, you are welcome to use, share and improve this program.
++ You are forbidden to forbid anyone else to use, share and improve
++ what you give them.   Help stamp out software-hoarding!  */
++
++#include "config.h"
++#include "system.h"
++#include "file-map.h"
++
++/* Structure recording the mapping from source file and directory
++   names at compile time to __FILE__ */
++typedef struct file_prefix_map
++{
++  const char *old_prefix;
++  const char *new_prefix;
++  size_t old_len;
++  size_t new_len;
++  struct file_prefix_map *next;
++} file_prefix_map;
++
++/* Linked list of such structures.  */
++static file_prefix_map *file_prefix_maps;
++
++/* Record prefix mapping of __FILE__.  ARG is the argument to
++   -ffile-prefix-map and must be of the form OLD=NEW.  */
++int
++add_file_prefix_map (const char *arg)
++{
++  file_prefix_map *map;
++  const char *p;
++
++  p = strchr (arg, '=');
++  if (!p)
++  {
++      fprintf(stderr, "invalid argument %qs to -ffile-prefix-map", arg);
++      return -1;
++  }
++  map = XNEW (file_prefix_map);
++  map->old_prefix = xstrndup (arg, p - arg);
++  map->old_len = p - arg;
++  p++;
++  map->new_prefix = xstrdup (p);
++  map->new_len = strlen (p);
++  map->next = file_prefix_maps;
++  file_prefix_maps = map;
++
++  return 0;
++}
++
++/* Perform user-specified mapping of __FILE__ prefixes.  Return
++   the new name corresponding to filename.  */
++
++const char *
++remap_file_filename (const char *filename)
++{
++  file_prefix_map *map;
++  char *s;
++  const char *name;
++  size_t name_len;
++
++  for (map = file_prefix_maps; map; map = map->next)
++    if (filename_ncmp (filename, map->old_prefix, map->old_len) == 0)
++      break;
++  if (!map)
++    return filename;
++  name = filename + map->old_len;
++  name_len = strlen (name) + 1;
++  s = (char *) alloca (name_len + map->new_len);
++  memcpy (s, map->new_prefix, map->new_len);
++  memcpy (s + map->new_len, name, name_len);
++
++  return xstrdup (s);
++}
++
++
+diff --git a/libcpp/include/file-map.h b/libcpp/include/file-map.h
+new file mode 100644
+index 0000000..e6f8cbf
+--- /dev/null
++++ b/libcpp/include/file-map.h
+@@ -0,0 +1,30 @@
++/* Map one directory name to another in __FILE__, __BASE_FILE__
++   and __builtin_FILE ().
++   Copyright (C) 2001-2016 Free Software Foundation, Inc.
++
++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 3, 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; see the file COPYING3.  If not see
++<http://www.gnu.org/licenses/>.
++
++ In other words, you are welcome to use, share and improve this program.
++ You are forbidden to forbid anyone else to use, share and improve
++ what you give them.   Help stamp out software-hoarding!  */
++
++#ifndef LIBCPP_FILE_MAP_H
++#define LIBCPP_FILE_MAP_H
++
++const char * remap_file_filename (const char *filename);
++
++int add_file_prefix_map (const char *arg);
++
++#endif /* !LIBCPP_FILE_MAP_H  */
+diff --git a/libcpp/macro.c b/libcpp/macro.c
+index 1e0a0b5..c3d330c 100644
+--- a/libcpp/macro.c
++++ b/libcpp/macro.c
+@@ -26,6 +26,7 @@ along with this program; see the file COPYING3.  If not see
+ #include "system.h"
+ #include "cpplib.h"
+ #include "internal.h"
++#include "file-map.h"
+ 
+ typedef struct macro_arg macro_arg;
+ /* This structure represents the tokens of a macro argument.  These
+@@ -297,6 +298,7 @@ _cpp_builtin_macro_text (cpp_reader *pfile, cpp_hashnode *node)
+ 	    if (!name)
+ 	      abort ();
+ 	  }
++	name = remap_file_filename (name);
+ 	len = strlen (name);
+ 	buf = _cpp_unaligned_alloc (pfile, len * 2 + 3);
+ 	result = buf;
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0055-Reuse-fdebug-prefix-map-to-replace-ffile-prefix-map.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0055-Reuse-fdebug-prefix-map-to-replace-ffile-prefix-map.patch
new file mode 100644
index 0000000..c7caed8
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0055-Reuse-fdebug-prefix-map-to-replace-ffile-prefix-map.patch
@@ -0,0 +1,43 @@
+From 14b79641ff6b0008aef7fbf7aa300daec11d1e78 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 16 Mar 2016 05:39:59 -0400
+Subject: [PATCH] Reuse -fdebug-prefix-map to replace -ffile-prefix-map
+
+The oe-core may use external toolchain to compile,
+which may not support -ffile-prefix-map.
+
+Since we use -fdebug-prefix-map to do the same thing,
+so we could reuse it to replace -ffile-prefix-map.
+
+Upstream-Status: Inappropriate[oe-core specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ gcc/opts-global.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/gcc/opts-global.c b/gcc/opts-global.c
+index b61bdcf..51bb177 100644
+--- a/gcc/opts-global.c
++++ b/gcc/opts-global.c
+@@ -50,6 +50,7 @@ along with GCC; see the file COPYING3.  If not see
+ #include "rtl.h"
+ #include "dbgcnt.h"
+ #include "debug.h"
++#include "file-map.h"
+ #include "hash-map.h"
+ #include "plugin-api.h"
+ #include "ipa-ref.h"
+@@ -378,6 +379,9 @@ handle_common_deferred_options (void)
+ 
+ 	case OPT_fdebug_prefix_map_:
+ 	  add_debug_prefix_map (opt->arg);
++
++	  /* Reuse -fdebug-prefix-map to replace -ffile-prefix-map */
++	  add_file_prefix_map (opt->arg);
+ 	  break;
+ 
+ 	case OPT_fdump_:
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0056-Enable-libc-provide-ssp-and-gcc_cv_target_dl_iterate.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0056-Enable-libc-provide-ssp-and-gcc_cv_target_dl_iterate.patch
new file mode 100644
index 0000000..9791342
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0056-Enable-libc-provide-ssp-and-gcc_cv_target_dl_iterate.patch
@@ -0,0 +1,85 @@
+From 5c7bd853c8703f65904083778712ef625c3f3814 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 27 Mar 2016 20:31:50 -0700
+Subject: [PATCH 56/57] Enable libc provide ssp and
+ gcc_cv_target_dl_iterate_phdr for musl
+
+        * configure.ac (gcc_cv_libc_provides_ssp): Add *-*-musl*.
+        (gcc_cv_target_dl_iterate_phdr): Add *-linux-musl*.
+        * configure: Regenerate.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Backport
+
+ gcc/configure    | 7 +++++++
+ gcc/configure.ac | 7 +++++++
+ 2 files changed, 14 insertions(+)
+
+diff --git a/gcc/configure b/gcc/configure
+index fcb05e7..81a449c 100755
+--- a/gcc/configure
++++ b/gcc/configure
+@@ -27814,6 +27814,9 @@ if test "${gcc_cv_libc_provides_ssp+set}" = set; then :
+ else
+   gcc_cv_libc_provides_ssp=no
+     case "$target" in
++       *-*-musl*)
++        # All versions of musl provide stack protector
++        gcc_cv_libc_provides_ssp=yes;;
+        *-*-linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu)
+       # glibc 2.4 and later provides __stack_chk_fail and
+       # either __stack_chk_guard, or TLS access to stack guard canary.
+@@ -27846,6 +27849,7 @@ fi
+ 	 # <http://gcc.gnu.org/ml/gcc/2008-10/msg00130.html>) and for now
+ 	 # simply assert that glibc does provide this, which is true for all
+ 	 # realistically usable GNU/Hurd configurations.
++	 # All supported versions of musl provide it as well
+ 	 gcc_cv_libc_provides_ssp=yes;;
+        *-*-darwin* | *-*-freebsd*)
+ 	 ac_fn_c_check_func "$LINENO" "__stack_chk_fail" "ac_cv_func___stack_chk_fail"
+@@ -27942,6 +27946,9 @@ case "$target" in
+       gcc_cv_target_dl_iterate_phdr=no
+     fi
+     ;;
++  *-linux-musl*)
++    gcc_cv_target_dl_iterate_phdr=yes
++    ;;
+ esac
+ 
+ if test x$gcc_cv_target_dl_iterate_phdr = xyes; then
+diff --git a/gcc/configure.ac b/gcc/configure.ac
+index 923bc9a..b08e3dc 100644
+--- a/gcc/configure.ac
++++ b/gcc/configure.ac
+@@ -5291,6 +5291,9 @@ AC_CACHE_CHECK(__stack_chk_fail in target C library,
+       gcc_cv_libc_provides_ssp,
+       [gcc_cv_libc_provides_ssp=no
+     case "$target" in
++       *-*-musl*)
++        # All versions of musl provide stack protector
++        gcc_cv_libc_provides_ssp=yes;;
+        *-*-linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu)
+       # glibc 2.4 and later provides __stack_chk_fail and
+       # either __stack_chk_guard, or TLS access to stack guard canary.
+@@ -5317,6 +5320,7 @@ AC_CACHE_CHECK(__stack_chk_fail in target C library,
+ 	 # <http://gcc.gnu.org/ml/gcc/2008-10/msg00130.html>) and for now
+ 	 # simply assert that glibc does provide this, which is true for all
+ 	 # realistically usable GNU/Hurd configurations.
++	 # All supported versions of musl provide it as well
+ 	 gcc_cv_libc_provides_ssp=yes;;
+        *-*-darwin* | *-*-freebsd*)
+ 	 AC_CHECK_FUNC(__stack_chk_fail,[gcc_cv_libc_provides_ssp=yes],
+@@ -5390,6 +5394,9 @@ case "$target" in
+       gcc_cv_target_dl_iterate_phdr=no
+     fi
+     ;;
++  *-linux-musl*)
++    gcc_cv_target_dl_iterate_phdr=yes
++    ;;
+ esac
+ GCC_TARGET_TEMPLATE([TARGET_DL_ITERATE_PHDR])
+ if test x$gcc_cv_target_dl_iterate_phdr = xyes; then
+-- 
+2.7.4
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0057-unwind-fix-for-musl.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0057-unwind-fix-for-musl.patch
new file mode 100644
index 0000000..c193587
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0057-unwind-fix-for-musl.patch
@@ -0,0 +1,42 @@
+From c5c33bf881a2aea355310dd90873ed39bc272b3c Mon Sep 17 00:00:00 2001
+From: ktkachov <ktkachov@138bc75d-0d04-0410-961f-82ee72b054a4>
+Date: Wed, 22 Apr 2015 14:20:01 +0000
+Subject: [PATCH 57/57] unwind fix for musl
+
+On behalf of szabolcs.nagy@arm.com
+
+2015-04-22  Gregor Richards  <gregor.richards@uwaterloo.ca>
+	    Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	* unwind-dw2-fde-dip.c (USE_PT_GNU_EH_FRAME): Define it on
+	Linux if target provides dl_iterate_phdr.
+
+git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@222328 138bc75d-0d04-0410-961f-82ee72b054a4
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Backport
+
+ libgcc/unwind-dw2-fde-dip.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+diff --git a/libgcc/unwind-dw2-fde-dip.c b/libgcc/unwind-dw2-fde-dip.c
+index e1e566b..137dced 100644
+--- a/libgcc/unwind-dw2-fde-dip.c
++++ b/libgcc/unwind-dw2-fde-dip.c
+@@ -59,6 +59,12 @@
+ 
+ #if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
+     && defined(TARGET_DL_ITERATE_PHDR) \
++    && defined(__linux__)
++# define USE_PT_GNU_EH_FRAME
++#endif
++
++#if !defined(inhibit_libc) && defined(HAVE_LD_EH_FRAME_HDR) \
++    && defined(TARGET_DL_ITERATE_PHDR) \
+     && (defined(__DragonFly__) || defined(__FreeBSD__))
+ # define ElfW __ElfN
+ # define USE_PT_GNU_EH_FRAME
+-- 
+2.7.4
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0058-fdebug-prefix-map-support-to-remap-relative-path.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0058-fdebug-prefix-map-support-to-remap-relative-path.patch
new file mode 100644
index 0000000..0b91fdb
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-5.3/0058-fdebug-prefix-map-support-to-remap-relative-path.patch
@@ -0,0 +1,51 @@
+From 289ad2969a5966c603bf6928ce442db74c4cbb25 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 24 Mar 2016 11:23:14 -0400
+Subject: [PATCH] gcc/final.c: -fdebug-prefix-map support to remap sources with
+ relative path
+
+PR other/70428
+* final.c (remap_debug_filename): Use lrealpath to translate
+relative path before remapping
+
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70428
+Upstream-Status: Submitted [gcc-patches@gcc.gnu.org]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+diff --git a/gcc/final.c b/gcc/final.c
+index 55cf509..c3594c2 100644
+--- a/gcc/final.c
++++ b/gcc/final.c
+@@ -1554,16 +1554,25 @@ remap_debug_filename (const char *filename)
+   const char *name;
+   size_t name_len;
+ 
++  /* Support to remap filename with relative path  */
++  char *realpath = lrealpath (filename);
++  if (realpath == NULL)
++    return filename;
++
+   for (map = debug_prefix_maps; map; map = map->next)
+-    if (filename_ncmp (filename, map->old_prefix, map->old_len) == 0)
++    if (filename_ncmp (realpath, map->old_prefix, map->old_len) == 0)
+       break;
+   if (!map)
+-    return filename;
+-  name = filename + map->old_len;
++    {
++      free (realpath);
++      return filename;
++    }
++  name = realpath + map->old_len;
+   name_len = strlen (name) + 1;
+   s = (char *) alloca (name_len + map->new_len);
+   memcpy (s, map->new_prefix, map->new_len);
+   memcpy (s + map->new_len, name, name_len);
++  free (realpath);
+   return ggc_strdup (s);
+ }
+ 
+-- 
+2.7.4
+
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-common.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-common.inc
index 6f2f224..e4fd4d6 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-common.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-common.inc
@@ -54,7 +54,7 @@
 def get_tune_parameters(tune, d):
     availtunes = d.getVar('AVAILTUNES', True)
     if tune not in availtunes.split():
-        bb.error('The tune: %s is not one of the available tunes: %s', tune or None, availtunes)
+        bb.error('The tune: %s is not one of the available tunes: %s' % (tune or None, availtunes))
 
     localdata = bb.data.createCopy(d)
     override = ':tune-' + tune
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-configure-common.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-configure-common.inc
index cee6f4a..f4f76bd 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-configure-common.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-configure-common.inc
@@ -14,13 +14,6 @@
 # gcc 3.x expects 'f77', 4.0 expects 'f95', 4.1 and 4.2 expect 'fortran'
 FORTRAN ?= ",f77"
 LANGUAGES ?= "c,c++${FORTRAN}${JAVA}"
-# disable --enable-target-optspace for powerpc SPE
-# at -Os libgcc.so.1 creates references into
-# hidden symbols in libgcc.a which linker complains
-# when linking shared libraries further in the build like (gnutls)
-
-SPECIAL_ARCH_LIST = "powerpc"
-OPTSPACE = '${@bb.utils.contains("SPECIAL_ARCH_LIST", "${TARGET_ARCH}", "", "--enable-target-optspace",d)}'
 
 EXTRA_OECONF_BASE ?= ""
 EXTRA_OECONF_PATHS ?= ""
@@ -42,7 +35,6 @@
     --enable-libstdcxx-pch \
     --program-prefix=${TARGET_PREFIX} \
     --without-local-prefix \
-    ${OPTSPACE} \
     ${EXTRA_OECONF_BASE} \
     ${EXTRA_OECONF_GCC_FLOAT} \
     ${EXTRA_OECONF_PATHS} \
@@ -72,6 +64,7 @@
 # features used in OE.
 EXTRA_OECONF_append_armv6 = " --with-arch=armv6"
 EXTRA_OECONF_append_armv7a = " --with-arch=armv7-a"
+EXTRA_OECONF_append_armv7ve = " --with-arch=armv7-a"
 
 EXTRA_OECONF_GCC_FLOAT ??= ""
 CPPFLAGS = ""
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian.inc
index 54e4881..ec1d281 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian.inc
@@ -3,7 +3,7 @@
 SUMMARY = "GNU cc and gcc C compilers (cross-canadian for ${TARGET_ARCH} target)"
 PN = "gcc-cross-canadian-${TRANSLATED_TARGET_ARCH}"
 
-DEPENDS = "virtual/${TARGET_PREFIX}gcc virtual/${HOST_PREFIX}binutils-crosssdk virtual/nativesdk-${HOST_PREFIX}libc-for-gcc nativesdk-gettext"
+DEPENDS = "virtual/${TARGET_PREFIX}gcc virtual/${HOST_PREFIX}gcc-crosssdk virtual/${HOST_PREFIX}binutils-crosssdk virtual/nativesdk-${HOST_PREFIX}libc-for-gcc nativesdk-gettext"
 
 GCCMULTILIB = "--enable-multilib"
 
@@ -84,11 +84,6 @@
 "
 INSANE_SKIP_${PN} += "dev-so"
 
-FILES_${PN}-dbg += " \
-    ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/.debug \
-    ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/plugin/.debug \
-"
-
 FILES_${PN}-doc = "\
     ${infodir} \
     ${mandir} \
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian_5.2.bb
deleted file mode 100644
index bf53c5c..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian_5.2.bb
+++ /dev/null
@@ -1,5 +0,0 @@
-require recipes-devtools/gcc/gcc-${PV}.inc
-require gcc-cross-canadian.inc
-
-
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-cross-canadian_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial.inc
index c0fa139..048b530 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial.inc
@@ -5,6 +5,9 @@
 INHIBIT_AUTOTOOLS_DEPS = "1"
 INHIBIT_DEFAULT_DEPS = "1"
 
+# We still need gnu-config-native
+DEPENDS_prepend = "gnu-config-native autoconf-native "
+
 PN = "gcc-cross-initial-${TARGET_ARCH}"
 
 CROSS_TARGET_SYS_DIR_append = ".${PN}"
@@ -19,7 +22,6 @@
     --disable-multilib \
     --disable-__cxa_atexit \
     --enable-languages=c \
-    ${OPTSPACE} \
     --program-prefix=${TARGET_PREFIX} \
     --with-sysroot=/not/exist \
     --with-build-sysroot=${GCCCROSS_BUILDSYSROOT} \
@@ -95,3 +97,4 @@
 do_populate_sysroot[sstate-inputdirs] = "${SYSROOT_DESTDIR}/${STAGING_DIR_HOST}/ ${SYSROOT_DESTDIR}/${STAGING_DIR_TARGET}/${target_base_libdir}/"
 do_populate_sysroot[sstate-outputdirs] = "${STAGING_DIR_HOST}/ ${STAGING_DIR_TCBOOTSTRAP}/${target_base_libdir}/"
 
+inherit nopackages
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial_5.2.bb
deleted file mode 100644
index 4c73e5c..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial_5.2.bb
+++ /dev/null
@@ -1,2 +0,0 @@
-require recipes-devtools/gcc/gcc-cross_${PV}.bb
-require gcc-cross-initial.inc
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-cross-initial_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross.inc
index aa10633..f479360 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross.inc
@@ -72,7 +72,6 @@
 	sed -i -e "/^'/d" ${B}/${TARGET_PREFIX}testgcc
 	sed -i -e "/^UID/d" ${B}/${TARGET_PREFIX}testgcc
 	sed -i -e "/^TERM/d" ${B}/${TARGET_PREFIX}testgcc
-	sed -i -e "/^PATCH_GET/d" ${B}/${TARGET_PREFIX}testgcc
 	sed -i -e "/^PKG_/d" ${B}/${TARGET_PREFIX}testgcc
 	sed -i -e "/^POSIXLY_/d" ${B}/${TARGET_PREFIX}testgcc
 	sed -i -e "/^PPID/d" ${B}/${TARGET_PREFIX}testgcc
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross_5.2.bb
deleted file mode 100644
index b43cca0..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross_5.2.bb
+++ /dev/null
@@ -1,3 +0,0 @@
-require recipes-devtools/gcc/gcc-${PV}.inc
-require gcc-cross.inc
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-cross_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-cross_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-cross_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-cross_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_5.2.bb
deleted file mode 100644
index fd90e11..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_5.2.bb
+++ /dev/null
@@ -1,3 +0,0 @@
-require recipes-devtools/gcc/gcc-cross-initial_${PV}.bb
-require gcc-crosssdk-initial.inc
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk-initial_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk_5.2.bb
deleted file mode 100644
index 40a6c4f..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk_5.2.bb
+++ /dev/null
@@ -1,2 +0,0 @@
-require recipes-devtools/gcc/gcc-cross_${PV}.bb
-require gcc-crosssdk.inc
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-crosssdk_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-multilib-config.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-multilib-config.inc
index 1c0a45a..a0a2ac0 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-multilib-config.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-multilib-config.inc
@@ -29,6 +29,9 @@
     bb.utils.remove(build_conf_dir, True)
     ml_globs = ('%s/*/t-linux64' % src_conf_dir,
                 '%s/*/linux64.h' % src_conf_dir,
+                '%s/aarch64/t-aarch64' % src_conf_dir,
+                '%s/aarch64/aarch64.h' % src_conf_dir,
+                '%s/aarch64/aarch64-cores.def' % src_conf_dir,
                 '%s/*/linux.h' % src_conf_dir,
                 '%s/linux.h' % src_conf_dir)
 
@@ -130,6 +133,8 @@
         'mips64'    : ['gcc/config/mips/t-linux64'],
         'powerpc'   : ['gcc/config/rs6000/t-linux64'],
         'powerpc64' : ['gcc/config/rs6000/t-linux64'],
+        'aarch64'   : ['gcc/config/aarch64/t-aarch64'],
+        'arm'       : ['gcc/config/aarch64/t-aarch64'],
     }
 
     gcc_header_config_files = {
@@ -140,6 +145,8 @@
         'mips64'    : ['gcc/config/mips/linux.h', 'gcc/config/mips/linux64.h'],
         'powerpc'   : ['gcc/config/rs6000/linux64.h'],
         'powerpc64' : ['gcc/config/rs6000/linux64.h'],
+        'aarch64'   : ['gcc/config/aarch64/aarch64.h'],
+        'arm'       : ['gcc/config/aarch64/aarch64.h'],
     }
 
     libdir32 = 'SYSTEMLIBS_DIR'
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-runtime.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-runtime.inc
index 690d780..8639c1c 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-runtime.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-runtime.inc
@@ -1,6 +1,10 @@
 require gcc-configure-common.inc
 
-CXXFLAGS := "${@oe_filter_out('-fvisibility-inlines-hidden', '${CXXFLAGS}', d)}"
+# Over-ride the LICENSE set by gcc-${PV}.inc to remove "& GPLv3"
+# All gcc-runtime packages are now covered by the runtime exception.
+LICENSE = "GPL-3.0-with-GCC-exception"
+
+CXXFLAGS_remove = "-fvisibility-inlines-hidden"
 
 EXTRA_OECONF_PATHS = "\
     --with-gxx-include-dir=${includedir}/c++/${BINV} \
@@ -10,7 +14,18 @@
 
 EXTRA_OECONF_append_linuxstdbase = " --enable-clocale=gnu"
 
-RUNTIMETARGET = "libssp libstdc++-v3 libgomp libatomic"
+RUNTIMELIBITM = "libitm"
+RUNTIMELIBITM_mips = ""
+RUNTIMELIBITM_mipsel = ""
+RUNTIMELIBITM_mips64 = ""
+RUNTIMELIBITM_mips64el = ""
+RUNTIMELIBITM_nios2 = ""
+RUNTIMELIBITM_microblaze = ""
+
+RUNTIMETARGET = "libssp libstdc++-v3 libgomp libatomic ${RUNTIMELIBITM} \
+    ${@bb.utils.contains_any('FORTRAN', [',fortran',',f77'], 'libquadmath', '', d)} \
+"
+
 #  ?
 # libiberty
 # libmudflap
@@ -27,7 +42,8 @@
 		mkdir -p ${B}/$target/$d/
 		cd ${B}/$target/$d/
 		chmod a+x ${S}/$d/configure
-		${S}/$d/configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
+		relpath=${@os.path.relpath("${S}/$d", "${B}/$target/$d")}
+		$relpath/configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
 	done
 }
 
@@ -46,6 +62,7 @@
 		oe_runmake 'DESTDIR=${D}' MULTIBUILDTOP=${B}/$target/$d/ install
 	done
 	rm -rf ${D}${infodir}/libgomp.info ${D}${infodir}/dir
+	rm -rf ${D}${infodir}/libitm.info ${D}${infodir}/dir
 	rm -rf ${D}${infodir}/libquadmath.info ${D}${infodir}/dir
 	if [ -d ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/finclude ]; then
 		rmdir --ignore-fail-on-non-empty -p ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/finclude
@@ -91,38 +108,11 @@
     libatomic \
     libatomic-dev \
     libatomic-staticdev \
+    libitm \
+    libitm-dev \
+    libitm-staticdev \
 "
 
-# Most libraries are licensed with the exception, but
-# one library is really GPLv3.
-#
-LICENSE_${PN}-dbg = "GPL-3.0-with-GCC-exception & GPLv3"
-LICENSE_libstdc++ = "GPL-3.0-with-GCC-exception"
-LICENSE_libstdc++-precompile-dev = "GPL-3.0-with-GCC-exception"
-LICENSE_libstdc++-dev = "GPL-3.0-with-GCC-exception"
-LICENSE_libstdc++-staticdev = "GPL-3.0-with-GCC-exception"
-LICENSE_libg2c = "GPL-3.0-with-GCC-exception"
-LICENSE_libg2c-dev = "GPL-3.0-with-GCC-exception"
-LICENSE_libssp = "GPL-3.0-with-GCC-exception"
-LICENSE_libssp-dev = "GPL-3.0-with-GCC-exception"
-LICENSE_libssp-staticdev = "GPL-3.0-with-GCC-exception"
-LICENSE_libgfortran = "GPL-3.0-with-GCC-exception"
-LICENSE_libgfortran-dev = "GPL-3.0-with-GCC-exception"
-LICENSE_libgfortran-staticdev = "GPL-3.0-with-GCC-exception"
-LICENSE_libmudflap = "GPL-3.0-with-GCC-exception"
-LICENSE_libmudflap-dev = "GPL-3.0-with-GCC-exception"
-LICENSE_libmudflap-staticdev = "GPL-3.0-with-GCC-exception"
-LICENSE_libquadmath = "GPL-3.0-with-GCC-exception"
-LICENSE_libquadmath-dev = "GPL-3.0-with-GCC-exception"
-LICENSE_libquadmath-staticdev = "GPL-3.0-with-GCC-exception"
-LICENSE_libatomic = "GPL-3.0-with-GCC-exception"
-LICENSE_libatomic-dev = "GPL-3.0-with-GCC-exception"
-LICENSE_libatomic-staticdev = "GPL-3.0-with-GCC-exception"
-
-LICENSE_libgomp = "GPLv3"
-LICENSE_libgomp-dev = "GPLv3"
-LICENSE_libgomp-staticdev = "GPLv3"
-
 # The base package doesn't exist, so we clear the recommends.
 RRECOMMENDS_${PN}-dbg = ""
 
@@ -143,11 +133,11 @@
 FILES_libstdc++-dev = "\
     ${includedir}/c++/ \
     ${libdir}/libstdc++.so \
-    ${libdir}/libstdc++.la \
+    ${libdir}/libstdc++*.la \
     ${libdir}/libsupc++.la \
 "
 FILES_libstdc++-staticdev = "\
-    ${libdir}/libstdc++.a \
+    ${libdir}/libstdc++*.a \
     ${libdir}/libsupc++.a \
 "
 
@@ -193,6 +183,14 @@
 "
 FILES_libatomic-staticdev = "${libdir}/libatomic.a"
 
+FILES_libitm = "${libdir}/libitm.so.*"
+FILES_libitm-dev = "\
+    ${libdir}/libitm.so \
+    ${libdir}/libitm.la \
+    ${libdir}/libitm.spec \
+"
+FILES_libitm-staticdev = "${libdir}/libitm.a"
+
 do_package_write_ipk[depends] += "virtual/${MLPREFIX}libc:do_packagedata"
 do_package_write_deb[depends] += "virtual/${MLPREFIX}libc:do_packagedata"
 do_package_write_rpm[depends] += "virtual/${MLPREFIX}libc:do_packagedata"
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-runtime_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-runtime_4.8.bb
deleted file mode 100644
index 497d691..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-runtime_4.8.bb
+++ /dev/null
@@ -1,3 +0,0 @@
-require recipes-devtools/gcc/gcc-${PV}.inc
-require gcc-runtime.inc
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-runtime_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-runtime_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-runtime_5.2.bb
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-runtime_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers.inc
index c987ccb..6091a0b 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers.inc
@@ -21,19 +21,15 @@
     echo "Configuring libsanitizer"
     rm -rf ${B}/$target/libsanitizer/
     mkdir -p ${B}/$target/libsanitizer/
-    # This is kind of gross, but it's an easy way to make configure happy
-    # without hacking it up to use the system stdc++ instead of the one it
-    # expects to be newly built.
-    rm -rf ${B}/$target/libstdc++-v3/
-    mkdir -p ${B}/$target/libstdc++-v3/src/
-    ln -s ${STAGING_LIBDIR}/libstdc++.la ${B}/$target/libstdc++-v3/src/
-    ln -s ${STAGING_LIBDIR}/libstdc++.so ${B}/$target/libstdc++-v3/src/
     cd ${B}/$target/libsanitizer/
     chmod a+x ${S}/libsanitizer/configure
-    ${S}/libsanitizer/configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
+    relpath=${@os.path.relpath("${S}/libsanitizer", "${B}/$target/libsanitizer")}
+    $relpath/configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
     # Easiest way to stop bad RPATHs getting into the library since we have a
     # broken libtool here
     sed -i -e 's/hardcode_into_libs=yes/hardcode_into_libs=no/' ${B}/$target/libsanitizer/libtool
+    # Link to the sysroot's libstdc++ instead of one gcc thinks it just built
+    sed -i -e '/LIBSTDCXX_RAW_CXX_\(CXXFLAGS\|LDFLAGS\)\s*=/d' ${B}/$target/libsanitizer/*/Makefile
 }
 
 do_compile () {
@@ -58,10 +54,9 @@
 
 BBCLASSEXTEND = "nativesdk"
 
-PACKAGES = "${PN}"
+PACKAGES = "${PN} ${PN}-dbg"
 PACKAGES += "libasan libubsan liblsan libtsan"
 PACKAGES += "libasan-dev libubsan-dev liblsan-dev libtsan-dev"
-PACKAGES += "libasan-dbg libubsan-dbg liblsan-dbg libtsan-dbg"
 PACKAGES += "libasan-staticdev libubsan-staticdev liblsan-staticdev libtsan-staticdev"
 
 RDEPENDS_libasan += "libstdc++"
@@ -84,7 +79,6 @@
 COMPATIBLE_HOST = '(x86_64|i.86|powerpc|arm).*-linux'
 
 FILES_libasan += "${libdir}/libasan.so.*"
-FILES_libasan-dbg += "${libdir}/.debug/libasan.so.*"
 FILES_libasan-dev += "\
     ${libdir}/libasan_preinit.o \
     ${libdir}/libasan.so \
@@ -93,7 +87,6 @@
 FILES_libasan-staticdev += "${libdir}/libasan.a"
 
 FILES_libubsan += "${libdir}/libubsan.so.*"
-FILES_libubsan-dbg += "${libdir}/.debug/libubsan.so.*"
 FILES_libubsan-dev += "\
     ${libdir}/libubsan.so \
     ${libdir}/libubsan.la \
@@ -101,7 +94,6 @@
 FILES_libubsan-staticdev += "${libdir}/libubsan.a"
 
 FILES_liblsan += "${libdir}/liblsan.so.*"
-FILES_liblsan-dbg += "${libdir}/.debug/liblsan.so.*"
 FILES_liblsan-dev += "\
     ${libdir}/liblsan.so \
     ${libdir}/liblsan.la \
@@ -109,7 +101,6 @@
 FILES_liblsan-staticdev += "${libdir}/liblsan.a"
 
 FILES_libtsan += "${libdir}/libtsan.so.*"
-FILES_libtsan-dbg += "${libdir}/.debug/libtsan.so.*"
 FILES_libtsan-dev += "\
     ${libdir}/libtsan.so \
     ${libdir}/libtsan.la \
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers_5.2.bb
deleted file mode 100644
index 601f666..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers_5.2.bb
+++ /dev/null
@@ -1,2 +0,0 @@
-require recipes-devtools/gcc/gcc-${PV}.inc
-require gcc-sanitizers.inc
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-sanitizers_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-source.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-source.inc
index 794fd4d..49bde92 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-source.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-source.inc
@@ -1,16 +1,12 @@
 deltask do_configure 
 deltask do_compile 
-deltask do_package 
-deltask do_package_write_rpm 
-deltask do_package_write_ipk 
-deltask do_package_write_deb
 deltask do_install 
 deltask do_populate_sysroot
 deltask do_populate_lic 
-deltask do_package_qa
-deltask do_packagedata
 deltask do_rm_work
 
+inherit nopackages
+
 PN = "gcc-source-${PV}"
 WORKDIR = "${TMPDIR}/work-shared/gcc-${PV}-${PR}"
 SSTATE_SWSPEC = "sstate:gcc::${PV}:${PR}::${SSTATE_VERSION}:"
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-source_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-source_5.2.bb
deleted file mode 100644
index b890fa3..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-source_5.2.bb
+++ /dev/null
@@ -1,4 +0,0 @@
-require recipes-devtools/gcc/gcc-${PV}.inc
-require recipes-devtools/gcc/gcc-source.inc
-
-EXCLUDE_FROM_WORLD = "1"
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-source_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc-source_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc-source_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/gcc-source_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-target.inc b/yocto-poky/meta/recipes-devtools/gcc/gcc-target.inc
index d62c15a..b8dabe5 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc-target.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-target.inc
@@ -44,10 +44,6 @@
 "
 INSANE_SKIP_${PN} += "dev-so"
 
-FILES_${PN}-dbg += "\
-    ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/.debug/ \
-    ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/plugin/.debug/ \
-"
 FILES_${PN}-dev = "\
     ${gcclibdir}/${TARGET_SYS}/${BINV}/lib*${SOLIBSDEV} \
     ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/lib*${SOLIBSDEV} \
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc_4.8.bb
deleted file mode 100644
index 2c618df..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/gcc_4.8.bb
+++ /dev/null
@@ -1,9 +0,0 @@
-require recipes-devtools/gcc/gcc-${PV}.inc
-require gcc-target.inc
-
-# Building with thumb enabled on armv4t fails with
-# | gcc-4.8.1-r0/gcc-4.8.1/gcc/cp/decl.c:7438:(.text.unlikely+0x2fa): relocation truncated to fit: R_ARM_THM_CALL against symbol `fancy_abort(char const*, int, char const*)' defined in .glue_7 section in linker stubs
-# | gcc-4.8.1-r0/gcc-4.8.1/gcc/cp/decl.c:7442:(.text.unlikely+0x318): additional relocation overflows omitted from the output
-ARM_INSTRUCTION_SET_armv4 = "arm"
-
-BBCLASSEXTEND = "nativesdk"
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/gcc_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/gcc_5.2.bb
rename to yocto-poky/meta/recipes-devtools/gcc/gcc_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgcc-common.inc b/yocto-poky/meta/recipes-devtools/gcc/libgcc-common.inc
index b09ea65..dae07e9 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/libgcc-common.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/libgcc-common.inc
@@ -12,7 +12,8 @@
 	mkdir -p ${B}/$target/${BPN}/
 	cd ${B}/${BPN}
 	chmod a+x ${S}/${BPN}/configure
-	${S}/${BPN}/configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
+	relpath=${@os.path.relpath("${S}/${BPN}", "${B}/${BPN}")}
+	$relpath/configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
 }
 
 do_compile () {
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgcc-initial.inc b/yocto-poky/meta/recipes-devtools/gcc/libgcc-initial.inc
index 4e92f00..59e8a62 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/libgcc-initial.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/libgcc-initial.inc
@@ -16,3 +16,4 @@
 
 do_populate_sysroot[sstate-outputdirs] = "${STAGING_DIR_TCBOOTSTRAP}/"
 
+inherit nopackages
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgcc-initial_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/libgcc-initial_5.2.bb
deleted file mode 100644
index 19f253f..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/libgcc-initial_5.2.bb
+++ /dev/null
@@ -1,2 +0,0 @@
-require recipes-devtools/gcc/gcc-${PV}.inc
-require libgcc-initial.inc
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgcc-initial_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/libgcc-initial_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/libgcc-initial_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/libgcc-initial_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgcc.inc b/yocto-poky/meta/recipes-devtools/gcc/libgcc.inc
index 95fa3f4..6837786 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/libgcc.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/libgcc.inc
@@ -21,8 +21,6 @@
     ${libdir}/${TARGET_SYS}/${BINV}* \
 "
 
-FILES_${PN}-dbg += "${base_libdir}/.debug/"
-
 LIBGCCBUILDTREENAME = "gcc-build-internal-"
 
 do_package[depends] += "virtual/${MLPREFIX}libc:do_packagedata"
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgcc_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/libgcc_5.2.bb
deleted file mode 100644
index a5152f2..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/libgcc_5.2.bb
+++ /dev/null
@@ -1,2 +0,0 @@
-require recipes-devtools/gcc/gcc-${PV}.inc
-require libgcc.inc
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgcc_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/libgcc_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/libgcc_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/libgcc_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgfortran.inc b/yocto-poky/meta/recipes-devtools/gcc/libgfortran.inc
index e42843d..58ceb2e 100644
--- a/yocto-poky/meta/recipes-devtools/gcc/libgfortran.inc
+++ b/yocto-poky/meta/recipes-devtools/gcc/libgfortran.inc
@@ -15,7 +15,8 @@
 	mkdir -p ${B}/$target/libgfortran/
 	cd ${B}/$target/libgfortran/
 	chmod a+x ${S}/libgfortran/configure
-	${S}/libgfortran/configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
+	relpath=${@os.path.relpath("${S}/libgfortran", "${B}/$target/libgfortran")}
+	$relpath/configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
 	# Easiest way to stop bad RPATHs getting into the library since we have a
 	# broken libtool here
 	sed -i -e 's/hardcode_into_libs=yes/hardcode_into_libs=no/' ${B}/$target/libgfortran/libtool
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgfortran_5.2.bb b/yocto-poky/meta/recipes-devtools/gcc/libgfortran_5.2.bb
deleted file mode 100644
index 71dd8b4..0000000
--- a/yocto-poky/meta/recipes-devtools/gcc/libgfortran_5.2.bb
+++ /dev/null
@@ -1,3 +0,0 @@
-require recipes-devtools/gcc/gcc-${PV}.inc
-require libgfortran.inc
-
diff --git a/yocto-poky/meta/recipes-devtools/gcc/libgfortran_4.8.bb b/yocto-poky/meta/recipes-devtools/gcc/libgfortran_5.3.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gcc/libgfortran_4.8.bb
rename to yocto-poky/meta/recipes-devtools/gcc/libgfortran_5.3.bb
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb-7.9.1.inc b/yocto-poky/meta/recipes-devtools/gdb/gdb-7.10.1.inc
similarity index 68%
rename from yocto-poky/meta/recipes-devtools/gdb/gdb-7.9.1.inc
rename to yocto-poky/meta/recipes-devtools/gdb/gdb-7.10.1.inc
index 1ca95af..a9267d5 100644
--- a/yocto-poky/meta/recipes-devtools/gdb/gdb-7.9.1.inc
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb-7.10.1.inc
@@ -4,6 +4,6 @@
 		    file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6 \
 		    file://COPYING.LIB;md5=9f604d8a4f8e74f4f5140845a21b6674"
 
-SRC_URI[md5sum] = "f3b97de919a9dba84490b2e076ec4cb0"
-SRC_URI[sha256sum] = "4994ad986726ac4128a6f1bd8020cd672e9a92aa76b80736563ef992992764ef"
+SRC_URI[md5sum] = "b93a2721393e5fa226375b42d567d90b"
+SRC_URI[sha256sum] = "ff14f8050e6484508c73cbfa63731e57901478490ca1672dc0b5e2b03f6af622"
 
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb-common.inc b/yocto-poky/meta/recipes-devtools/gdb/gdb-common.inc
index 166ba8e..0d28ee4 100644
--- a/yocto-poky/meta/recipes-devtools/gdb/gdb-common.inc
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb-common.inc
@@ -2,7 +2,7 @@
 HOMEPAGE = "http://www.gnu.org/software/gdb/"
 LICENSE = "GPLv3+"
 SECTION = "devel"
-DEPENDS = "expat zlib ncurses readline ${LTTNGUST}"
+DEPENDS = "expat zlib ncurses ${LTTNGUST}"
 
 LTTNGUST = "lttng-ust"
 LTTNGUST_aarch64 = ""
@@ -22,16 +22,11 @@
 		file://COPYING.LIB;md5=9f604d8a4f8e74f4f5140845a21b6674 \
 		file://COPYING3;md5=d32239bcb673463ab874e80d47fae504 \
 		file://COPYING3.LIB;md5=6a6a8e020838b23406c81b19c1d46df6"
+
 inherit autotools texinfo
 
 SRC_URI = "${GNU_MIRROR}/gdb/gdb-${PV}.tar.gz \
           "
-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}"
 
 B = "${WORKDIR}/build-${TARGET_SYS}"
 
@@ -40,13 +35,19 @@
 EXPAT = "--with-expat --with-libexpat-prefix=${STAGING_DIR_HOST}"
 
 EXTRA_OECONF = "--disable-gdbtk --disable-tui --disable-x --disable-werror \
-                --with-curses --disable-multilib --with-system-readline --disable-sim \
+                --with-curses --disable-multilib --disable-sim \
                 --without-lzma --without-guile \
                 ${GDBPROPREFIX} ${EXPAT} \
                 ${@bb.utils.contains('DISTRO_FEATURES', 'multiarch', '--enable-64-bit-bfd', '', d)} \
                 --disable-rpath \
                "
 
+PACKAGECONFIG ??= "readline"
+# Use --without-system-readline to compile with readline 5.
+PACKAGECONFIG[readline] = "--with-system-readline,--without-system-readline,readline"
+PACKAGECONFIG[python] = "--with-python=${WORKDIR}/python,--without-python,python,python python-codecs"
+PACKAGECONFIG[babeltrace] = "--with-babeltrace,--without-babeltrace,babeltrace"
+
 GDBPROPREFIX = "--program-prefix=''"
 
 do_configure () {
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb-cross-canadian.inc b/yocto-poky/meta/recipes-devtools/gdb/gdb-cross-canadian.inc
index 4fd60a6..6e42af1 100644
--- a/yocto-poky/meta/recipes-devtools/gdb/gdb-cross-canadian.inc
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb-cross-canadian.inc
@@ -5,13 +5,17 @@
 PN = "gdb-cross-canadian-${TRANSLATED_TARGET_ARCH}"
 BPN = "gdb"
 
-DEPENDS = "nativesdk-ncurses nativesdk-expat nativesdk-gettext nativesdk-readline nativesdk-python"
-RDEPENDS_${PN} += "nativesdk-python-core nativesdk-python-lang nativesdk-python-re \
-                   nativesdk-python-codecs nativesdk-python-netclient"
+DEPENDS = "nativesdk-ncurses nativesdk-expat nativesdk-gettext \
+           virtual/${HOST_PREFIX}gcc-crosssdk virtual/${HOST_PREFIX}binutils-crosssdk virtual/nativesdk-${HOST_PREFIX}libc-for-gcc"
 
 GDBPROPREFIX = "--program-prefix='${TARGET_PREFIX}'"
 
-EXTRA_OECONF_append = " --with-python=${WORKDIR}/python"
+# Overrides PACKAGECONFIG variables in gdb-common.inc
+PACKAGECONFIG ??= "python readline"
+PACKAGECONFIG[python] = "--with-python=${WORKDIR}/python,--without-python,nativesdk-python, \
+                         nativesdk-python-core nativesdk-python-lang nativesdk-python-re \
+                         nativesdk-python-codecs nativesdk-python-netclient"
+PACKAGECONFIG[readline] = "--with-system-readline,--without-system-readline,nativesdk-readline"
 
 SSTATE_DUPWHITELIST += "${STAGING_DATADIR}/gdb"
 
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb-cross-canadian_7.9.1.bb b/yocto-poky/meta/recipes-devtools/gdb/gdb-cross-canadian_7.10.1.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gdb/gdb-cross-canadian_7.9.1.bb
rename to yocto-poky/meta/recipes-devtools/gdb/gdb-cross-canadian_7.10.1.bb
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb-cross.inc b/yocto-poky/meta/recipes-devtools/gdb/gdb-cross.inc
index 6e44778..2468d23 100644
--- a/yocto-poky/meta/recipes-devtools/gdb/gdb-cross.inc
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb-cross.inc
@@ -1,10 +1,13 @@
 require gdb-common.inc
 
-DEPENDS = "expat-native ncurses-native readline-native python-native"
+DEPENDS = "expat-native ncurses-native"
 
 inherit pythonnative
 
-EXTRA_OECONF += "--with-python=${STAGING_BINDIR_NATIVE}/python-native/python"
+# Overrides PACKAGECONFIG variables in gdb-common.inc
+PACKAGECONFIG ??= "python readline"
+PACKAGECONFIG[python] = "--with-python=${STAGING_BINDIR_NATIVE}/python-native/python,--without-python,python-native"
+PACKAGECONFIG[readline] = "--with-system-readline,--without-system-readline,readline-native"
 
 do_compile_prepend() {
     export BUILD_SYS="${BUILD_SYS}"
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb-cross_7.9.1.bb b/yocto-poky/meta/recipes-devtools/gdb/gdb-cross_7.10.1.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/gdb/gdb-cross_7.9.1.bb
rename to yocto-poky/meta/recipes-devtools/gdb/gdb-cross_7.10.1.bb
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb.inc b/yocto-poky/meta/recipes-devtools/gdb/gdb.inc
index 88c0213..d9c864d 100644
--- a/yocto-poky/meta/recipes-devtools/gdb/gdb.inc
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb.inc
@@ -4,7 +4,11 @@
 
 SRC_URI += "file://0002-Change-order-of-CFLAGS.patch \
             file://0003-Add-support-for-Renesas-SH-sh4-architecture.patch \
-            file://fix-detection-of-64-bit-PPC-inferior-in-gdbserver.patch \
+            file://0001-Use-exported-definitions-of-SIGRTMIN.patch \
+            file://0001-include-sys-types.h-for-mode_t.patch \
+            file://0001-use-asm-sgidefs.h.patch \
+            file://force-readline-static.patch \
+            file://0001-mips-linux-nat-Define-_ABIO32-if-not-defined.patch \
            "
 #LDFLAGS_append = " -s"
 #export CFLAGS_append=" -L${STAGING_LIBDIR}"
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-Use-exported-definitions-of-SIGRTMIN.patch b/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-Use-exported-definitions-of-SIGRTMIN.patch
new file mode 100644
index 0000000..5f0c096
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-Use-exported-definitions-of-SIGRTMIN.patch
@@ -0,0 +1,54 @@
+From 2f97e89e9e4e5797d0d973e1d05c1f44c46b4912 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 5 Jun 2015 20:21:38 -0700
+Subject: [PATCH] Use exorted definitions of SIGRTMIN
+
+Define W_STOPCODE if not defined already
+
+__SIGRTMIN is internal to glibc and other libcs e.g. musl
+may not provide them
+
+Fixes
+https://sourceware.org/bugzilla/show_bug.cgi?id=13012
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Submitted
+
+ gdb/linux-nat.c     | 4 ++--
+ gdb/nat/linux-nat.h | 4 ++++
+ 2 files changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
+index 396c30c..50320ee 100644
+--- a/gdb/linux-nat.c
++++ b/gdb/linux-nat.c
+@@ -4856,10 +4856,10 @@ lin_thread_get_thread_signals (sigset_t *set)
+      fortunately they don't change!  */
+ 
+   if (restart == 0)
+-    restart = __SIGRTMIN;
++    restart = SIGRTMIN;
+ 
+   if (cancel == 0)
+-    cancel = __SIGRTMIN + 1;
++    cancel = SIGRTMIN + 1;
+ 
+   sigaddset (set, restart);
+   sigaddset (set, cancel);
+diff --git a/gdb/nat/linux-nat.h b/gdb/nat/linux-nat.h
+index 83a6d91..efbe0fd 100644
+--- a/gdb/nat/linux-nat.h
++++ b/gdb/nat/linux-nat.h
+@@ -25,4 +25,8 @@
+    instead SIGTRAP with bit 7 set.  */
+ #define SYSCALL_SIGTRAP (SIGTRAP | 0x80)
+ 
++#ifndef W_STOPCODE
++#define W_STOPCODE(sig) ((sig) << 8 | 0x7f)
++#endif
++
+ #endif /* LINUX_NAT_H */
+-- 
+2.1.4
+
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-include-sys-types.h-for-mode_t.patch b/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-include-sys-types.h-for-mode_t.patch
new file mode 100644
index 0000000..a0292e4
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-include-sys-types.h-for-mode_t.patch
@@ -0,0 +1,30 @@
+From acbee4edacb80b5eeaff2480712fe98e56443997 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 19 Jan 2016 18:18:52 -0800
+Subject: [PATCH] include sys/types.h for mode_t
+
+mode_t is used in target.h, so we need to include sys/types.h to get the
+defintion
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ gdb/gdbserver/target.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/gdb/gdbserver/target.h b/gdb/gdbserver/target.h
+index 9a40867..aaecab9 100644
+--- a/gdb/gdbserver/target.h
++++ b/gdb/gdbserver/target.h
+@@ -27,6 +27,7 @@
+ #include "target/waitstatus.h"
+ #include "mem-break.h"
+ #include "btrace-common.h"
++#include <sys/types.h>
+ 
+ struct emit_ops;
+ struct buffer;
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-mips-linux-nat-Define-_ABIO32-if-not-defined.patch b/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-mips-linux-nat-Define-_ABIO32-if-not-defined.patch
new file mode 100644
index 0000000..3173952
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-mips-linux-nat-Define-_ABIO32-if-not-defined.patch
@@ -0,0 +1,37 @@
+From e92f8932ef488de2a56db4299131ce6a4eb170bd Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 23 Mar 2016 06:30:09 +0000
+Subject: [PATCH] mips-linux-nat: Define _ABIO32 if not defined
+
+This helps building gdb on mips64 on musl, since
+musl does not provide sgidefs.h this define is
+only defined when GCC is using o32 ABI, in that
+case gcc emits it as built-in define and hence
+it works ok for mips32
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ gdb/mips-linux-nat.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/gdb/mips-linux-nat.c b/gdb/mips-linux-nat.c
+index fd5c705..753f29d 100644
+--- a/gdb/mips-linux-nat.c
++++ b/gdb/mips-linux-nat.c
+@@ -46,6 +46,11 @@
+ #define PTRACE_GET_THREAD_AREA 25
+ #endif
+ 
++/* musl does not define and relies on compiler built-in macros for it   */
++#ifndef _ABIO32
++#define _ABIO32 1
++#endif
++
+ /* Assume that we have PTRACE_GETREGS et al. support.  If we do not,
+    we'll clear this and use PTRACE_PEEKUSER instead.  */
+ static int have_ptrace_regsets = 1;
+-- 
+1.8.3.1
+
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-use-asm-sgidefs.h.patch b/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-use-asm-sgidefs.h.patch
new file mode 100644
index 0000000..eaec390
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb/0001-use-asm-sgidefs.h.patch
@@ -0,0 +1,35 @@
+From 677b5b56135141c0d259e370aacd0e11c810aa15 Mon Sep 17 00:00:00 2001
+From: Andre McCurdy <armccurdy@gmail.com>
+Date: Fri, 5 Feb 2016 14:00:00 -0800
+Subject: [PATCH] use <asm/sgidefs.h>
+
+Build fix for MIPS with musl libc
+
+The MIPS specific header <sgidefs.h> is provided by glibc and uclibc
+but not by musl. Regardless of the libc, the kernel headers provide
+<asm/sgidefs.h> which provides the same definitions, so use that
+instead.
+
+Upstream-Status: Pending
+
+Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+---
+ gdb/mips-linux-nat.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gdb/mips-linux-nat.c b/gdb/mips-linux-nat.c
+index a36bb63..fd5c705 100644
+--- a/gdb/mips-linux-nat.c
++++ b/gdb/mips-linux-nat.c
+@@ -31,7 +31,7 @@
+ #include "gdb_proc_service.h"
+ #include "gregset.h"
+ 
+-#include <sgidefs.h>
++#include <asm/sgidefs.h>
+ #include <sys/ptrace.h>
+ #include <asm/ptrace.h>
+ 
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb/fix-detection-of-64-bit-PPC-inferior-in-gdbserver.patch b/yocto-poky/meta/recipes-devtools/gdb/gdb/fix-detection-of-64-bit-PPC-inferior-in-gdbserver.patch
deleted file mode 100644
index 2854352..0000000
--- a/yocto-poky/meta/recipes-devtools/gdb/gdb/fix-detection-of-64-bit-PPC-inferior-in-gdbserver.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From 4fe67dbafa1bee679daecc12ed30621d5c2605de Mon Sep 17 00:00:00 2001
-From: Yao Qi <yao@codesourcery.com>
-Date: Mon, 11 May 2015 10:57:33 +0800
-Subject: [PATCH] Fix detection of 64-bit PPC inferior in gdbserver
-
-Issue #16775
-
-* gdbserver/linux-ppc-low.c (ppc_arch_setup): Change variable msr to type
-'unsigned long'.  Check bit 63 or bit 31 is one.
-
-https://sourceware.org/ml/gdb-patches/2014-12/msg00239.html
-Written by: Yao Qi <yao@codesourcery.com>
-
-Upstream-Status: Pending
-
-Signed-off-by: Yuanjie Huang <yuanjie.huang@windriver.com>
----
- gdb/gdbserver/linux-ppc-low.c | 11 +++++++----
- 1 file changed, 7 insertions(+), 4 deletions(-)
-
-diff --git a/gdb/gdbserver/linux-ppc-low.c b/gdb/gdbserver/linux-ppc-low.c
-index 63d4218..a62cf22 100644
---- a/gdb/gdbserver/linux-ppc-low.c
-+++ b/gdb/gdbserver/linux-ppc-low.c
-@@ -374,7 +374,7 @@ ppc_arch_setup (void)
- {
-   const struct target_desc *tdesc;
- #ifdef __powerpc64__
--  long msr;
-+  unsigned long msr;
-   struct regcache *regcache;
- 
-   /* On a 64-bit host, assume 64-bit inferior process with no
-@@ -384,13 +384,16 @@ ppc_arch_setup (void)
-   current_process ()->tdesc = tdesc;
-   ppc_hwcap = 0;
- 
--  /* Only if the high bit of the MSR is set, we actually have
--     a 64-bit inferior.  */
-+  /* We actually have a 64-bit inferior only if the certain bit of the
-+     MSR is set.  The PowerISA Book III-S MSR is different from the
-+     PowerISA Book III-E MSR.  The Book III-S MSR is 64 bits wide, and
-+     its MSR[SF] is the bit 0 of a 64-bit value.  Book III-E MSR is 32
-+     bits wide, and its MSR[CM] is the bit 0 of a 32-bit value.  */
-   regcache = new_register_cache (tdesc);
-   fetch_inferior_registers (regcache, find_regno (tdesc, "msr"));
-   collect_register_by_name (regcache, "msr", &msr);
-   free_register_cache (regcache);
--  if (msr < 0)
-+  if (msr & 0x8000000080000000)
-     {
-       ppc_get_hwcap (&ppc_hwcap);
-       if (ppc_hwcap & PPC_FEATURE_CELL)
--- 
-1.8.5.2.233.g932f7e4
-
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb/force-readline-static.patch b/yocto-poky/meta/recipes-devtools/gdb/gdb/force-readline-static.patch
new file mode 100644
index 0000000..d34ee8c
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb/force-readline-static.patch
@@ -0,0 +1,37 @@
+If gdb is configured with --disable-static then this is dutifully passed to
+readline which then disables libreadline.a, which causes a problem when gdb
+tries to link against that.
+
+To ensure that readline always builds static libraries, pass --enable-static to
+the sub-configure.
+
+Upstream-Status: Pending
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+diff --git a/Makefile.def b/Makefile.def
+index 4394188..05c661a 100644
+--- a/Makefile.def
++++ b/Makefile.def
+@@ -100,7 +100,8 @@ host_modules= { module= libiconv;
+ 		missing= install-html;
+ 		missing= install-info; };
+ host_modules= { module= m4; };
+-host_modules= { module= readline; };
++host_modules= { module= readline;
++                extra_configure_flags='--enable-static';};
+ host_modules= { module= sid; };
+ host_modules= { module= sim; };
+ host_modules= { module= texinfo; no_install= true; };
+diff --git a/Makefile.in b/Makefile.in
+index 61e0ab6..837f36e 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -24971,7 +24971,7 @@ configure-readline:
+ 	  $$s/$$module_srcdir/configure \
+ 	  --srcdir=$${topdir}/$$module_srcdir \
+ 	  $(HOST_CONFIGARGS) --build=${build_alias} --host=${host_alias} \
+-	  --target=${target_alias}  \
++	  --target=${target_alias} --enable-static \
+ 	  || exit 1
+ @endif readline
+ 
diff --git a/yocto-poky/meta/recipes-devtools/gdb/gdb_7.9.1.bb b/yocto-poky/meta/recipes-devtools/gdb/gdb_7.10.1.bb
similarity index 72%
rename from yocto-poky/meta/recipes-devtools/gdb/gdb_7.9.1.bb
rename to yocto-poky/meta/recipes-devtools/gdb/gdb_7.10.1.bb
index cd52e27..f897e12 100644
--- a/yocto-poky/meta/recipes-devtools/gdb/gdb_7.9.1.bb
+++ b/yocto-poky/meta/recipes-devtools/gdb/gdb_7.10.1.bb
@@ -3,10 +3,6 @@
 
 inherit python-dir
 
-PACKAGECONFIG ??= ""
-PACKAGECONFIG[python] = "--with-python=${WORKDIR}/python,--without-python,python,python python-codecs"
-PACKAGECONFIG[babeltrace] = "--with-babeltrace,--without-babeltrace,babeltrace"
-
 do_configure_prepend() {
 	if [ -n "${@bb.utils.contains('PACKAGECONFIG', 'python', 'python', '', d)}" ]; then
 		cat > ${WORKDIR}/python << EOF
diff --git a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0008-CVE-2015-7545-1.patch b/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0008-CVE-2015-7545-1.patch
deleted file mode 100644
index b552c09..0000000
--- a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0008-CVE-2015-7545-1.patch
+++ /dev/null
@@ -1,446 +0,0 @@
-From a5adaced2e13c135d5d9cc65be9eb95aa3bacedf Mon Sep 17 00:00:00 2001
-From: Jeff King <peff@peff.net>
-Date: Wed, 16 Sep 2015 13:12:52 -0400
-Subject: [PATCH] transport: add a protocol-whitelist environment variable
-
-If we are cloning an untrusted remote repository into a
-sandbox, we may also want to fetch remote submodules in
-order to get the complete view as intended by the other
-side. However, that opens us up to attacks where a malicious
-user gets us to clone something they would not otherwise
-have access to (this is not necessarily a problem by itself,
-but we may then act on the cloned contents in a way that
-exposes them to the attacker).
-
-Ideally such a setup would sandbox git entirely away from
-high-value items, but this is not always practical or easy
-to set up (e.g., OS network controls may block multiple
-protocols, and we would want to enable some but not others).
-
-We can help this case by providing a way to restrict
-particular protocols. We use a whitelist in the environment.
-This is more annoying to set up than a blacklist, but
-defaults to safety if the set of protocols git supports
-grows). If no whitelist is specified, we continue to default
-to allowing all protocols (this is an "unsafe" default, but
-since the minority of users will want this sandboxing
-effect, it is the only sensible one).
-
-A note on the tests: ideally these would all be in a single
-test file, but the git-daemon and httpd test infrastructure
-is an all-or-nothing proposition rather than a test-by-test
-prerequisite. By putting them all together, we would be
-unable to test the file-local code on machines without
-apache.
-
-Signed-off-by: Jeff King <peff@peff.net>
-Signed-off-by: Junio C Hamano <gitster@pobox.com>
-
-Upstream-Status: Backport
-
-http://archive.ubuntu.com/ubuntu/pool/main/g/git/git_2.5.0-1ubuntu0.1.debian.tar.xz
-
-CVE: CVE-2015-7545 #1
-Singed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- Documentation/git.txt          | 32 ++++++++++++++
- connect.c                      |  5 +++
- t/lib-proto-disable.sh         | 96 ++++++++++++++++++++++++++++++++++++++++++
- t/t5810-proto-disable-local.sh | 14 ++++++
- t/t5811-proto-disable-git.sh   | 20 +++++++++
- t/t5812-proto-disable-http.sh  | 20 +++++++++
- t/t5813-proto-disable-ssh.sh   | 20 +++++++++
- t/t5814-proto-disable-ext.sh   | 18 ++++++++
- transport-helper.c             |  2 +
- transport.c                    | 21 ++++++++-
- transport.h                    |  7 +++
- 11 files changed, 254 insertions(+), 1 deletion(-)
- create mode 100644 t/lib-proto-disable.sh
- create mode 100755 t/t5810-proto-disable-local.sh
- create mode 100755 t/t5811-proto-disable-git.sh
- create mode 100755 t/t5812-proto-disable-http.sh
- create mode 100755 t/t5813-proto-disable-ssh.sh
- create mode 100755 t/t5814-proto-disable-ext.sh
-
-Index: git-2.5.0/Documentation/git.txt
-===================================================================
---- git-2.5.0.orig/Documentation/git.txt	2015-12-11 12:46:48.975637719 -0500
-+++ git-2.5.0/Documentation/git.txt	2015-12-11 12:46:48.967637661 -0500
-@@ -1069,6 +1069,38 @@
- 	an operation has touched every ref (e.g., because you are
- 	cloning a repository to make a backup).
- 
-+`GIT_ALLOW_PROTOCOL`::
-+	If set, provide a colon-separated list of protocols which are
-+	allowed to be used with fetch/push/clone. This is useful to
-+	restrict recursive submodule initialization from an untrusted
-+	repository. Any protocol not mentioned will be disallowed (i.e.,
-+	this is a whitelist, not a blacklist). If the variable is not
-+	set at all, all protocols are enabled.  The protocol names
-+	currently used by git are:
-+
-+	  - `file`: any local file-based path (including `file://` URLs,
-+	    or local paths)
-+
-+	  - `git`: the anonymous git protocol over a direct TCP
-+	    connection (or proxy, if configured)
-+
-+	  - `ssh`: git over ssh (including `host:path` syntax,
-+	    `git+ssh://`, etc).
-+
-+	  - `rsync`: git over rsync
-+
-+	  - `http`: git over http, both "smart http" and "dumb http".
-+	    Note that this does _not_ include `https`; if you want both,
-+	    you should specify both as `http:https`.
-+
-+	  - any external helpers are named by their protocol (e.g., use
-+	    `hg` to allow the `git-remote-hg` helper)
-++
-+Note that this controls only git's internal protocol selection.
-+If libcurl is used (e.g., by the `http` transport), it may
-+redirect to other protocols. There is not currently any way to
-+restrict this.
-+
- 
- Discussion[[Discussion]]
- ------------------------
-Index: git-2.5.0/connect.c
-===================================================================
---- git-2.5.0.orig/connect.c	2015-12-11 12:46:48.975637719 -0500
-+++ git-2.5.0/connect.c	2015-12-11 12:46:48.967637661 -0500
-@@ -9,6 +9,7 @@
- #include "url.h"
- #include "string-list.h"
- #include "sha1-array.h"
-+#include "transport.h"
- 
- static char *server_capabilities;
- static const char *parse_feature_value(const char *, const char *, int *);
-@@ -694,6 +695,8 @@
- 		else
- 			target_host = xstrdup(hostandport);
- 
-+		transport_check_allowed("git");
-+
- 		/* These underlying connection commands die() if they
- 		 * cannot connect.
- 		 */
-@@ -727,6 +730,7 @@
- 			int putty, tortoiseplink = 0;
- 			char *ssh_host = hostandport;
- 			const char *port = NULL;
-+			transport_check_allowed("ssh");
- 			get_host_and_port(&ssh_host, &port);
- 
- 			if (!port)
-@@ -781,6 +785,7 @@
- 			/* remove repo-local variables from the environment */
- 			conn->env = local_repo_env;
- 			conn->use_shell = 1;
-+			transport_check_allowed("file");
- 		}
- 		argv_array_push(&conn->args, cmd.buf);
- 
-Index: git-2.5.0/t/lib-proto-disable.sh
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ git-2.5.0/t/lib-proto-disable.sh	2015-12-11 12:46:48.967637661 -0500
-@@ -0,0 +1,96 @@
-+# Test routines for checking protocol disabling.
-+
-+# test cloning a particular protocol
-+#   $1 - description of the protocol
-+#   $2 - machine-readable name of the protocol
-+#   $3 - the URL to try cloning
-+test_proto () {
-+	desc=$1
-+	proto=$2
-+	url=$3
-+
-+	test_expect_success "clone $1 (enabled)" '
-+		rm -rf tmp.git &&
-+		(
-+			GIT_ALLOW_PROTOCOL=$proto &&
-+			export GIT_ALLOW_PROTOCOL &&
-+			git clone --bare "$url" tmp.git
-+		)
-+	'
-+
-+	test_expect_success "fetch $1 (enabled)" '
-+		(
-+			cd tmp.git &&
-+			GIT_ALLOW_PROTOCOL=$proto &&
-+			export GIT_ALLOW_PROTOCOL &&
-+			git fetch
-+		)
-+	'
-+
-+	test_expect_success "push $1 (enabled)" '
-+		(
-+			cd tmp.git &&
-+			GIT_ALLOW_PROTOCOL=$proto &&
-+			export GIT_ALLOW_PROTOCOL &&
-+			git push origin HEAD:pushed
-+		)
-+	'
-+
-+	test_expect_success "push $1 (disabled)" '
-+		(
-+			cd tmp.git &&
-+			GIT_ALLOW_PROTOCOL=none &&
-+			export GIT_ALLOW_PROTOCOL &&
-+			test_must_fail git push origin HEAD:pushed
-+		)
-+	'
-+
-+	test_expect_success "fetch $1 (disabled)" '
-+		(
-+			cd tmp.git &&
-+			GIT_ALLOW_PROTOCOL=none &&
-+			export GIT_ALLOW_PROTOCOL &&
-+			test_must_fail git fetch
-+		)
-+	'
-+
-+	test_expect_success "clone $1 (disabled)" '
-+		rm -rf tmp.git &&
-+		(
-+			GIT_ALLOW_PROTOCOL=none &&
-+			export GIT_ALLOW_PROTOCOL &&
-+			test_must_fail git clone --bare "$url" tmp.git
-+		)
-+	'
-+}
-+
-+# set up an ssh wrapper that will access $host/$repo in the
-+# trash directory, and enable it for subsequent tests.
-+setup_ssh_wrapper () {
-+	test_expect_success 'setup ssh wrapper' '
-+		write_script ssh-wrapper <<-\EOF &&
-+		echo >&2 "ssh: $*"
-+		host=$1; shift
-+		cd "$TRASH_DIRECTORY/$host" &&
-+		eval "$*"
-+		EOF
-+		GIT_SSH="$PWD/ssh-wrapper" &&
-+		export GIT_SSH &&
-+		export TRASH_DIRECTORY
-+	'
-+}
-+
-+# set up a wrapper that can be used with remote-ext to
-+# access repositories in the "remote" directory of trash-dir,
-+# like "ext::fake-remote %S repo.git"
-+setup_ext_wrapper () {
-+	test_expect_success 'setup ext wrapper' '
-+		write_script fake-remote <<-\EOF &&
-+		echo >&2 "fake-remote: $*"
-+		cd "$TRASH_DIRECTORY/remote" &&
-+		eval "$*"
-+		EOF
-+		PATH=$TRASH_DIRECTORY:$PATH &&
-+		export TRASH_DIRECTORY
-+	'
-+}
-Index: git-2.5.0/t/t5810-proto-disable-local.sh
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ git-2.5.0/t/t5810-proto-disable-local.sh	2015-12-11 12:46:48.967637661 -0500
-@@ -0,0 +1,14 @@
-+#!/bin/sh
-+
-+test_description='test disabling of local paths in clone/fetch'
-+. ./test-lib.sh
-+. "$TEST_DIRECTORY/lib-proto-disable.sh"
-+
-+test_expect_success 'setup repository to clone' '
-+	test_commit one
-+'
-+
-+test_proto "file://" file "file://$PWD"
-+test_proto "path" file .
-+
-+test_done
-Index: git-2.5.0/t/t5811-proto-disable-git.sh
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ git-2.5.0/t/t5811-proto-disable-git.sh	2015-12-11 12:46:48.967637661 -0500
-@@ -0,0 +1,20 @@
-+#!/bin/sh
-+
-+test_description='test disabling of git-over-tcp in clone/fetch'
-+. ./test-lib.sh
-+. "$TEST_DIRECTORY/lib-proto-disable.sh"
-+. "$TEST_DIRECTORY/lib-git-daemon.sh"
-+start_git_daemon
-+
-+test_expect_success 'create git-accessible repo' '
-+	bare="$GIT_DAEMON_DOCUMENT_ROOT_PATH/repo.git" &&
-+	test_commit one &&
-+	git --bare init "$bare" &&
-+	git push "$bare" HEAD &&
-+	>"$bare/git-daemon-export-ok" &&
-+	git -C "$bare" config daemon.receivepack true
-+'
-+
-+test_proto "git://" git "$GIT_DAEMON_URL/repo.git"
-+
-+test_done
-Index: git-2.5.0/t/t5812-proto-disable-http.sh
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ git-2.5.0/t/t5812-proto-disable-http.sh	2015-12-11 12:46:48.967637661 -0500
-@@ -0,0 +1,20 @@
-+#!/bin/sh
-+
-+test_description='test disabling of git-over-http in clone/fetch'
-+. ./test-lib.sh
-+. "$TEST_DIRECTORY/lib-proto-disable.sh"
-+. "$TEST_DIRECTORY/lib-httpd.sh"
-+start_httpd
-+
-+test_expect_success 'create git-accessible repo' '
-+	bare="$HTTPD_DOCUMENT_ROOT_PATH/repo.git" &&
-+	test_commit one &&
-+	git --bare init "$bare" &&
-+	git push "$bare" HEAD &&
-+	git -C "$bare" config http.receivepack true
-+'
-+
-+test_proto "smart http" http "$HTTPD_URL/smart/repo.git"
-+
-+stop_httpd
-+test_done
-Index: git-2.5.0/t/t5813-proto-disable-ssh.sh
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ git-2.5.0/t/t5813-proto-disable-ssh.sh	2015-12-11 12:46:48.967637661 -0500
-@@ -0,0 +1,20 @@
-+#!/bin/sh
-+
-+test_description='test disabling of git-over-ssh in clone/fetch'
-+. ./test-lib.sh
-+. "$TEST_DIRECTORY/lib-proto-disable.sh"
-+
-+setup_ssh_wrapper
-+
-+test_expect_success 'setup repository to clone' '
-+	test_commit one &&
-+	mkdir remote &&
-+	git init --bare remote/repo.git &&
-+	git push remote/repo.git HEAD
-+'
-+
-+test_proto "host:path" ssh "remote:repo.git"
-+test_proto "ssh://" ssh "ssh://remote/$PWD/remote/repo.git"
-+test_proto "git+ssh://" ssh "git+ssh://remote/$PWD/remote/repo.git"
-+
-+test_done
-Index: git-2.5.0/t/t5814-proto-disable-ext.sh
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ git-2.5.0/t/t5814-proto-disable-ext.sh	2015-12-11 12:46:48.967637661 -0500
-@@ -0,0 +1,18 @@
-+#!/bin/sh
-+
-+test_description='test disabling of remote-helper paths in clone/fetch'
-+. ./test-lib.sh
-+. "$TEST_DIRECTORY/lib-proto-disable.sh"
-+
-+setup_ext_wrapper
-+
-+test_expect_success 'setup repository to clone' '
-+	test_commit one &&
-+	mkdir remote &&
-+	git init --bare remote/repo.git &&
-+	git push remote/repo.git HEAD
-+'
-+
-+test_proto "remote-helper" ext "ext::fake-remote %S repo.git"
-+
-+test_done
-Index: git-2.5.0/transport-helper.c
-===================================================================
---- git-2.5.0.orig/transport-helper.c	2015-12-11 12:46:48.975637719 -0500
-+++ git-2.5.0/transport-helper.c	2015-12-11 12:46:48.967637661 -0500
-@@ -1039,6 +1039,8 @@
- 	struct helper_data *data = xcalloc(1, sizeof(*data));
- 	data->name = name;
- 
-+	transport_check_allowed(name);
-+
- 	if (getenv("GIT_TRANSPORT_HELPER_DEBUG"))
- 		debug = 1;
- 
-Index: git-2.5.0/transport.c
-===================================================================
---- git-2.5.0.orig/transport.c	2015-12-11 12:46:48.975637719 -0500
-+++ git-2.5.0/transport.c	2015-12-11 12:46:48.967637661 -0500
-@@ -912,6 +912,20 @@
- 	return strchr(url, ':') - url;
- }
- 
-+void transport_check_allowed(const char *type)
-+{
-+	struct string_list allowed = STRING_LIST_INIT_DUP;
-+	const char *v = getenv("GIT_ALLOW_PROTOCOL");
-+
-+	if (!v)
-+		return;
-+
-+	string_list_split(&allowed, v, ':', -1);
-+	if (!unsorted_string_list_has_string(&allowed, type))
-+		die("transport '%s' not allowed", type);
-+	string_list_clear(&allowed, 0);
-+}
-+
- struct transport *transport_get(struct remote *remote, const char *url)
- {
- 	const char *helper;
-@@ -943,12 +957,14 @@
- 	if (helper) {
- 		transport_helper_init(ret, helper);
- 	} else if (starts_with(url, "rsync:")) {
-+		transport_check_allowed("rsync");
- 		ret->get_refs_list = get_refs_via_rsync;
- 		ret->fetch = fetch_objs_via_rsync;
- 		ret->push = rsync_transport_push;
- 		ret->smart_options = NULL;
- 	} else if (url_is_local_not_ssh(url) && is_file(url) && is_bundle(url, 1)) {
- 		struct bundle_transport_data *data = xcalloc(1, sizeof(*data));
-+		transport_check_allowed("file");
- 		ret->data = data;
- 		ret->get_refs_list = get_refs_from_bundle;
- 		ret->fetch = fetch_refs_from_bundle;
-@@ -960,7 +976,10 @@
- 		|| starts_with(url, "ssh://")
- 		|| starts_with(url, "git+ssh://")
- 		|| starts_with(url, "ssh+git://")) {
--		/* These are builtin smart transports. */
-+		/*
-+		 * These are builtin smart transports; "allowed" transports
-+		 * will be checked individually in git_connect.
-+		 */
- 		struct git_transport_data *data = xcalloc(1, sizeof(*data));
- 		ret->data = data;
- 		ret->set_option = NULL;
-Index: git-2.5.0/transport.h
-===================================================================
---- git-2.5.0.orig/transport.h	2015-12-11 12:46:48.975637719 -0500
-+++ git-2.5.0/transport.h	2015-12-11 12:46:48.971637690 -0500
-@@ -133,6 +133,13 @@
- /* Returns a transport suitable for the url */
- struct transport *transport_get(struct remote *, const char *);
- 
-+/*
-+ * Check whether a transport is allowed by the environment,
-+ * and die otherwise. type should generally be the URL scheme,
-+ * as described in Documentation/git.txt
-+ */
-+void transport_check_allowed(const char *type);
-+
- /* Transport options which apply to git:// and scp-style URLs */
- 
- /* The program to use on the remote side to send a pack */
diff --git a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0009-CVE-2015-7545-2.patch b/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0009-CVE-2015-7545-2.patch
deleted file mode 100644
index 8000e26..0000000
--- a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0009-CVE-2015-7545-2.patch
+++ /dev/null
@@ -1,112 +0,0 @@
-From 33cfccbbf35a56e190b79bdec5c85457c952a021 Mon Sep 17 00:00:00 2001
-From: Jeff King <peff@peff.net>
-Date: Wed, 16 Sep 2015 13:13:12 -0400
-Subject: [PATCH] submodule: allow only certain protocols for submodule fetches
-
-Some protocols (like git-remote-ext) can execute arbitrary
-code found in the URL. The URLs that submodules use may come
-from arbitrary sources (e.g., .gitmodules files in a remote
-repository). Let's restrict submodules to fetching from a
-known-good subset of protocols.
-
-Note that we apply this restriction to all submodule
-commands, whether the URL comes from .gitmodules or not.
-This is more restrictive than we need to be; for example, in
-the tests we run:
-
-  git submodule add ext::...
-
-which should be trusted, as the URL comes directly from the
-command line provided by the user. But doing it this way is
-simpler, and makes it much less likely that we would miss a
-case. And since such protocols should be an exception
-(especially because nobody who clones from them will be able
-to update the submodules!), it's not likely to inconvenience
-anyone in practice.
-
-Reported-by: Blake Burkhart <bburky@bburky.com>
-Signed-off-by: Jeff King <peff@peff.net>
-Signed-off-by: Junio C Hamano <gitster@pobox.com>
-
-Upstream-Status: Backport
-
-http://archive.ubuntu.com/ubuntu/pool/main/g/git/git_2.5.0-1ubuntu0.1.debian.tar.xz
-
-CVE: CVE-2015-7545 #2
-Singed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- git-submodule.sh            |  9 +++++++++
- t/t5815-submodule-protos.sh | 43 +++++++++++++++++++++++++++++++++++++++++++
- 2 files changed, 52 insertions(+)
- create mode 100755 t/t5815-submodule-protos.sh
-
-diff --git a/git-submodule.sh b/git-submodule.sh
-index 36797c3..78c2740 100755
---- a/git-submodule.sh
-+++ b/git-submodule.sh
-@@ -22,6 +22,15 @@ require_work_tree
- wt_prefix=$(git rev-parse --show-prefix)
- cd_to_toplevel
- 
-+# Restrict ourselves to a vanilla subset of protocols; the URLs
-+# we get are under control of a remote repository, and we do not
-+# want them kicking off arbitrary git-remote-* programs.
-+#
-+# If the user has already specified a set of allowed protocols,
-+# we assume they know what they're doing and use that instead.
-+: ${GIT_ALLOW_PROTOCOL=file:git:http:https:ssh}
-+export GIT_ALLOW_PROTOCOL
-+
- command=
- branch=
- force=
-diff --git a/t/t5815-submodule-protos.sh b/t/t5815-submodule-protos.sh
-new file mode 100755
-index 0000000..06f55a1
---- /dev/null
-+++ b/t/t5815-submodule-protos.sh
-@@ -0,0 +1,43 @@
-+#!/bin/sh
-+
-+test_description='test protocol whitelisting with submodules'
-+. ./test-lib.sh
-+. "$TEST_DIRECTORY"/lib-proto-disable.sh
-+
-+setup_ext_wrapper
-+setup_ssh_wrapper
-+
-+test_expect_success 'setup repository with submodules' '
-+	mkdir remote &&
-+	git init remote/repo.git &&
-+	(cd remote/repo.git && test_commit one) &&
-+	# submodule-add should probably trust what we feed it on the cmdline,
-+	# but its implementation is overly conservative.
-+	GIT_ALLOW_PROTOCOL=ssh git submodule add remote:repo.git ssh-module &&
-+	GIT_ALLOW_PROTOCOL=ext git submodule add "ext::fake-remote %S repo.git" ext-module &&
-+	git commit -m "add submodules"
-+'
-+
-+test_expect_success 'clone with recurse-submodules fails' '
-+	test_must_fail git clone --recurse-submodules . dst
-+'
-+
-+test_expect_success 'setup individual updates' '
-+	rm -rf dst &&
-+	git clone . dst &&
-+	git -C dst submodule init
-+'
-+
-+test_expect_success 'update of ssh allowed' '
-+	git -C dst submodule update ssh-module
-+'
-+
-+test_expect_success 'update of ext not allowed' '
-+	test_must_fail git -C dst submodule update ext-module
-+'
-+
-+test_expect_success 'user can override whitelist' '
-+	GIT_ALLOW_PROTOCOL=ext git -C dst submodule update ext-module
-+'
-+
-+test_done
diff --git a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0010-CVE-2015-7545-3.patch b/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0010-CVE-2015-7545-3.patch
deleted file mode 100644
index b6edc9d..0000000
--- a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0010-CVE-2015-7545-3.patch
+++ /dev/null
@@ -1,112 +0,0 @@
-From 5088d3b38775f8ac12d7f77636775b16059b67ef Mon Sep 17 00:00:00 2001
-From: Jeff King <peff@peff.net>
-Date: Tue, 22 Sep 2015 18:03:49 -0400
-Subject: [PATCH] transport: refactor protocol whitelist code
-
-The current callers only want to die when their transport is
-prohibited. But future callers want to query the mechanism
-without dying.
-
-Let's break out a few query functions, and also save the
-results in a static list so we don't have to re-parse for
-each query.
-
-Based-on-a-patch-by: Blake Burkhart <bburky@bburky.com>
-Signed-off-by: Jeff King <peff@peff.net>
-Signed-off-by: Junio C Hamano <gitster@pobox.com>
-
-Upstream-Status: Backport
-
-http://archive.ubuntu.com/ubuntu/pool/main/g/git/git_2.5.0-1ubuntu0.1.debian.tar.xz
-
-CVE: CVE-2015-7545 #3
-Singed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- transport.c | 38 ++++++++++++++++++++++++++++++--------
- transport.h | 15 +++++++++++++--
- 2 files changed, 43 insertions(+), 10 deletions(-)
-
-Index: git-2.5.0/transport.c
-===================================================================
---- git-2.5.0.orig/transport.c	2015-12-11 12:47:09.547784038 -0500
-+++ git-2.5.0/transport.c	2015-12-11 12:47:09.543784009 -0500
-@@ -912,18 +912,40 @@
- 	return strchr(url, ':') - url;
- }
- 
--void transport_check_allowed(const char *type)
-+static const struct string_list *protocol_whitelist(void)
- {
--	struct string_list allowed = STRING_LIST_INIT_DUP;
--	const char *v = getenv("GIT_ALLOW_PROTOCOL");
-+	static int enabled = -1;
-+	static struct string_list allowed = STRING_LIST_INIT_DUP;
-+
-+	if (enabled < 0) {
-+		const char *v = getenv("GIT_ALLOW_PROTOCOL");
-+		if (v) {
-+			string_list_split(&allowed, v, ':', -1);
-+			string_list_sort(&allowed);
-+			enabled = 1;
-+		} else {
-+			enabled = 0;
-+		}
-+	}
-+
-+	return enabled ? &allowed : NULL;
-+}
- 
--	if (!v)
--		return;
-+int is_transport_allowed(const char *type)
-+{
-+	const struct string_list *allowed = protocol_whitelist();
-+	return !allowed || string_list_has_string(allowed, type);
-+}
- 
--	string_list_split(&allowed, v, ':', -1);
--	if (!unsorted_string_list_has_string(&allowed, type))
-+void transport_check_allowed(const char *type)
-+{
-+	if (!is_transport_allowed(type))
- 		die("transport '%s' not allowed", type);
--	string_list_clear(&allowed, 0);
-+}
-+
-+int transport_restrict_protocols(void)
-+{
-+	return !!protocol_whitelist();
- }
- 
- struct transport *transport_get(struct remote *remote, const char *url)
-Index: git-2.5.0/transport.h
-===================================================================
---- git-2.5.0.orig/transport.h	2015-12-11 12:47:09.547784038 -0500
-+++ git-2.5.0/transport.h	2015-12-11 12:47:09.543784009 -0500
-@@ -134,12 +134,23 @@
- struct transport *transport_get(struct remote *, const char *);
- 
- /*
-+ * Check whether a transport is allowed by the environment. Type should
-+ * generally be the URL scheme, as described in Documentation/git.txt
-+ */
-+int is_transport_allowed(const char *type);
-+
-+/*
-  * Check whether a transport is allowed by the environment,
-- * and die otherwise. type should generally be the URL scheme,
-- * as described in Documentation/git.txt
-+ * and die otherwise.
-  */
- void transport_check_allowed(const char *type);
- 
-+/*
-+ * Returns true if the user has attempted to turn on protocol
-+ * restrictions at all.
-+ */
-+int transport_restrict_protocols(void);
-+
- /* Transport options which apply to git:// and scp-style URLs */
- 
- /* The program to use on the remote side to send a pack */
diff --git a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0011-CVE-2015-7545-4.patch b/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0011-CVE-2015-7545-4.patch
deleted file mode 100644
index 44dcd1e..0000000
--- a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0011-CVE-2015-7545-4.patch
+++ /dev/null
@@ -1,150 +0,0 @@
-Backport of:
-
-From f4113cac0c88b4f36ee6f3abf3218034440a68e3 Mon Sep 17 00:00:00 2001
-From: Blake Burkhart <bburky@bburky.com>
-Date: Tue, 22 Sep 2015 18:06:04 -0400
-Subject: [PATCH] http: limit redirection to protocol-whitelist
-
-Previously, libcurl would follow redirection to any protocol
-it was compiled for support with. This is desirable to allow
-redirection from HTTP to HTTPS. However, it would even
-successfully allow redirection from HTTP to SFTP, a protocol
-that git does not otherwise support at all. Furthermore
-git's new protocol-whitelisting could be bypassed by
-following a redirect within the remote helper, as it was
-only enforced at transport selection time.
-
-This patch limits redirects within libcurl to HTTP, HTTPS,
-FTP and FTPS. If there is a protocol-whitelist present, this
-list is limited to those also allowed by the whitelist. As
-redirection happens from within libcurl, it is impossible
-for an HTTP redirect to a protocol implemented within
-another remote helper.
-
-When the curl version git was compiled with is too old to
-support restrictions on protocol redirection, we warn the
-user if GIT_ALLOW_PROTOCOL restrictions were requested. This
-is a little inaccurate, as even without that variable in the
-environment, we would still restrict SFTP, etc, and we do
-not warn in that case. But anything else means we would
-literally warn every time git accesses an http remote.
-
-This commit includes a test, but it is not as robust as we
-would hope. It redirects an http request to ftp, and checks
-that curl complained about the protocol, which means that we
-are relying on curl's specific error message to know what
-happened. Ideally we would redirect to a working ftp server
-and confirm that we can clone without protocol restrictions,
-and not with them. But we do not have a portable way of
-providing an ftp server, nor any other protocol that curl
-supports (https is the closest, but we would have to deal
-with certificates).
-
-[jk: added test and version warning]
-
-Signed-off-by: Jeff King <peff@peff.net>
-Signed-off-by: Junio C Hamano <gitster@pobox.com>
-
-Upstream-Status: Backport
-
-http://archive.ubuntu.com/ubuntu/pool/main/g/git/git_2.5.0-1ubuntu0.1.debian.tar.xz
-
-CVE: CVE-2015-7545 #4
-Singed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- Documentation/git.txt         |  5 -----
- http.c                        | 17 +++++++++++++++++
- t/lib-httpd/apache.conf       |  1 +
- t/t5812-proto-disable-http.sh |  9 +++++++++
- 4 files changed, 27 insertions(+), 5 deletions(-)
-
-Index: git-2.5.0/Documentation/git.txt
-===================================================================
---- git-2.5.0.orig/Documentation/git.txt	2015-12-11 12:47:18.707849212 -0500
-+++ git-2.5.0/Documentation/git.txt	2015-12-11 12:47:18.703849183 -0500
-@@ -1095,11 +1095,6 @@
- 
- 	  - any external helpers are named by their protocol (e.g., use
- 	    `hg` to allow the `git-remote-hg` helper)
--+
--Note that this controls only git's internal protocol selection.
--If libcurl is used (e.g., by the `http` transport), it may
--redirect to other protocols. There is not currently any way to
--restrict this.
- 
- 
- Discussion[[Discussion]]
-Index: git-2.5.0/http.c
-===================================================================
---- git-2.5.0.orig/http.c	2015-12-11 12:47:18.707849212 -0500
-+++ git-2.5.0/http.c	2015-12-11 12:47:34.171959268 -0500
-@@ -8,6 +8,7 @@
- #include "credential.h"
- #include "version.h"
- #include "pkt-line.h"
-+#include "transport.h"
- #include "gettext.h"
- 
- int active_requests;
-@@ -340,6 +341,7 @@
- static CURL *get_curl_handle(void)
- {
- 	CURL *result = curl_easy_init();
-+	long allowed_protocols = 0;
- 
- 	if (!result)
- 		die("curl_easy_init failed");
-@@ -399,6 +401,21 @@
- #elif LIBCURL_VERSION_NUM >= 0x071101
- 	curl_easy_setopt(result, CURLOPT_POST301, 1);
- #endif
-+#if LIBCURL_VERSION_NUM >= 0x071304
-+	if (is_transport_allowed("http"))
-+		allowed_protocols |= CURLPROTO_HTTP;
-+	if (is_transport_allowed("https"))
-+		allowed_protocols |= CURLPROTO_HTTPS;
-+	if (is_transport_allowed("ftp"))
-+		allowed_protocols |= CURLPROTO_FTP;
-+	if (is_transport_allowed("ftps"))
-+		allowed_protocols |= CURLPROTO_FTPS;
-+	curl_easy_setopt(result, CURLOPT_REDIR_PROTOCOLS, allowed_protocols);
-+#else
-+	if (transport_restrict_protocols())
-+		warning("protocol restrictions not applied to curl redirects because\n"
-+			"your curl version is too old (>= 7.19.4)");
-+#endif
- 
- 	if (getenv("GIT_CURL_VERBOSE"))
- 		curl_easy_setopt(result, CURLOPT_VERBOSE, 1);
-Index: git-2.5.0/t/lib-httpd/apache.conf
-===================================================================
---- git-2.5.0.orig/t/lib-httpd/apache.conf	2015-12-11 12:47:18.707849212 -0500
-+++ git-2.5.0/t/lib-httpd/apache.conf	2015-12-11 12:47:18.703849183 -0500
-@@ -119,6 +119,7 @@
- RewriteRule ^/smart-redir-temp/(.*)$ /smart/$1 [R=302]
- RewriteRule ^/smart-redir-auth/(.*)$ /auth/smart/$1 [R=301]
- RewriteRule ^/smart-redir-limited/(.*)/info/refs$ /smart/$1/info/refs [R=301]
-+RewriteRule ^/ftp-redir/(.*)$ ftp://localhost:1000/$1 [R=302]
- 
- <IfDefine SSL>
- LoadModule ssl_module modules/mod_ssl.so
-Index: git-2.5.0/t/t5812-proto-disable-http.sh
-===================================================================
---- git-2.5.0.orig/t/t5812-proto-disable-http.sh	2015-12-11 12:47:18.707849212 -0500
-+++ git-2.5.0/t/t5812-proto-disable-http.sh	2015-12-11 12:47:18.703849183 -0500
-@@ -16,5 +16,14 @@
- 
- test_proto "smart http" http "$HTTPD_URL/smart/repo.git"
- 
-+test_expect_success 'curl redirects respect whitelist' '
-+	test_must_fail env GIT_ALLOW_PROTOCOL=http:https \
-+		git clone "$HTTPD_URL/ftp-redir/repo.git" 2>stderr &&
-+	{
-+		test_i18ngrep "ftp.*disabled" stderr ||
-+		test_i18ngrep "your curl version is too old"
-+	}
-+'
-+
- stop_httpd
- test_done
diff --git a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0012-CVE-2015-7545-5.patch b/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0012-CVE-2015-7545-5.patch
deleted file mode 100644
index 76d66ba..0000000
--- a/yocto-poky/meta/recipes-devtools/git/git-2.5.0/0012-CVE-2015-7545-5.patch
+++ /dev/null
@@ -1,69 +0,0 @@
-From b258116462399b318c86165c61a5c7123043cfd4 Mon Sep 17 00:00:00 2001
-From: Blake Burkhart <bburky@bburky.com>
-Date: Tue, 22 Sep 2015 18:06:20 -0400
-Subject: [PATCH] http: limit redirection depth
-
-By default, libcurl will follow circular http redirects
-forever. Let's put a cap on this so that somebody who can
-trigger an automated fetch of an arbitrary repository (e.g.,
-for CI) cannot convince git to loop infinitely.
-
-The value chosen is 20, which is the same default that
-Firefox uses.
-
-Signed-off-by: Jeff King <peff@peff.net>
-Signed-off-by: Junio C Hamano <gitster@pobox.com>
-
-Upstream-Status: Backport
-
-http://archive.ubuntu.com/ubuntu/pool/main/g/git/git_2.5.0-1ubuntu0.1.debian.tar.xz
-
-CVE: CVE-2015-7545 #5
-Singed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- http.c                        | 1 +
- t/lib-httpd/apache.conf       | 3 +++
- t/t5812-proto-disable-http.sh | 4 ++++
- 3 files changed, 8 insertions(+)
-
-Index: git-2.5.0/http.c
-===================================================================
---- git-2.5.0.orig/http.c	2015-12-11 12:48:02.900163824 -0500
-+++ git-2.5.0/http.c	2015-12-11 12:48:02.896163796 -0500
-@@ -396,6 +396,7 @@
- 	}
- 
- 	curl_easy_setopt(result, CURLOPT_FOLLOWLOCATION, 1);
-+	curl_easy_setopt(result, CURLOPT_MAXREDIRS, 20);
- #if LIBCURL_VERSION_NUM >= 0x071301
- 	curl_easy_setopt(result, CURLOPT_POSTREDIR, CURL_REDIR_POST_ALL);
- #elif LIBCURL_VERSION_NUM >= 0x071101
-Index: git-2.5.0/t/lib-httpd/apache.conf
-===================================================================
---- git-2.5.0.orig/t/lib-httpd/apache.conf	2015-12-11 12:48:02.900163824 -0500
-+++ git-2.5.0/t/lib-httpd/apache.conf	2015-12-11 12:48:02.896163796 -0500
-@@ -121,6 +121,9 @@
- RewriteRule ^/smart-redir-limited/(.*)/info/refs$ /smart/$1/info/refs [R=301]
- RewriteRule ^/ftp-redir/(.*)$ ftp://localhost:1000/$1 [R=302]
- 
-+RewriteRule ^/loop-redir/x-x-x-x-x-x-x-x-x-x-x-x-x-x-x-x-x-x-x-x-(.*) /$1 [R=302]
-+RewriteRule ^/loop-redir/(.*)$ /loop-redir/x-$1 [R=302]
-+
- <IfDefine SSL>
- LoadModule ssl_module modules/mod_ssl.so
- 
-Index: git-2.5.0/t/t5812-proto-disable-http.sh
-===================================================================
---- git-2.5.0.orig/t/t5812-proto-disable-http.sh	2015-12-11 12:48:02.900163824 -0500
-+++ git-2.5.0/t/t5812-proto-disable-http.sh	2015-12-11 12:48:02.896163796 -0500
-@@ -25,5 +25,9 @@
- 	}
- '
- 
-+test_expect_success 'curl limits redirects' '
-+	test_must_fail git clone "$HTTPD_URL/loop-redir/smart/repo.git"
-+'
-+
- stop_httpd
- test_done
diff --git a/yocto-poky/meta/recipes-devtools/git/git.inc b/yocto-poky/meta/recipes-devtools/git/git.inc
index 4da4a27..a1d0300 100644
--- a/yocto-poky/meta/recipes-devtools/git/git.inc
+++ b/yocto-poky/meta/recipes-devtools/git/git.inc
@@ -17,7 +17,7 @@
 		--without-tcltk \
 "
 
-inherit autotools-brokensep perlnative
+inherit autotools-brokensep perlnative bash-completion
 
 EXTRA_OEMAKE = "NO_PYTHON=1 CFLAGS='${CFLAGS}' LDFLAGS='${LDFLAGS}'"
 EXTRA_OEMAKE += "'PERL_PATH=/usr/bin/env perl'"
@@ -50,6 +50,8 @@
 
 	# ${libdir} is not applicable here, perl-native files are always
 	# installed to /usr/lib on both 32/64 bits targets.
+
+	mkdir -p ${D}${libdir}
 	mv ${D}${exec_prefix}/lib/perl-native/perl ${D}${libdir}
 	rmdir -p ${D}${exec_prefix}/lib/perl-native || true
 }
@@ -75,7 +77,6 @@
 }
 
 FILES_${PN} += "${datadir}/git-core ${libexecdir}/git-core/"
-FILES_${PN}-dbg += "${libexecdir}/git-core/.debug"
 
 PERLTOOLS = " \
     ${libexecdir}/git-core/git-add--interactive \
@@ -97,10 +98,6 @@
     ${datadir}/git-core/templates/hooks/pre-rebase.sample \
 "
 
-# Basic tab completion support
-PACKAGES =+ "${PN}-bash-completion"
-FILES_${PN}-bash-completion = "${datadir}/bash-completion/completions/*"
-
 # Git tools requiring perl
 PACKAGES =+ "${PN}-perltools"
 FILES_${PN}-perltools += " \
diff --git a/yocto-poky/meta/recipes-devtools/git/git_2.5.0.bb b/yocto-poky/meta/recipes-devtools/git/git_2.5.0.bb
deleted file mode 100644
index 792f258..0000000
--- a/yocto-poky/meta/recipes-devtools/git/git_2.5.0.bb
+++ /dev/null
@@ -1,19 +0,0 @@
-require git.inc
-
-EXTRA_OECONF += "ac_cv_snprintf_returns_bogus=no \
-                 ac_cv_fread_reads_directories=${ac_cv_fread_reads_directories=yes} \
-                 "
-EXTRA_OEMAKE += "NO_GETTEXT=1"
-
-SRC_URI[tarball.md5sum] = "3bc9b0a803ae8ec6c5316cc64f0b7f78"
-SRC_URI[tarball.sha256sum] = "8fa13ba8434ff83d24f57f831d55dbb9046434c266641180a37744facfce72ac"
-SRC_URI[manpages.md5sum] = "134b049e51420a336049aac21c88a75a"
-SRC_URI[manpages.sha256sum] = "745e4e797fe5061e781c880d370b1beb480199127da5acaf4e376e0b09d4d685"
-
-SRC_URI += "\
-    file://0008-CVE-2015-7545-1.patch \
-    file://0009-CVE-2015-7545-2.patch \
-    file://0010-CVE-2015-7545-3.patch \
-    file://0011-CVE-2015-7545-4.patch \
-    file://0012-CVE-2015-7545-5.patch \
-    "
diff --git a/yocto-poky/meta/recipes-devtools/git/git_2.7.4.bb b/yocto-poky/meta/recipes-devtools/git/git_2.7.4.bb
new file mode 100644
index 0000000..bc72793
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/git/git_2.7.4.bb
@@ -0,0 +1,11 @@
+require git.inc
+
+EXTRA_OECONF += "ac_cv_snprintf_returns_bogus=no \
+                 ac_cv_fread_reads_directories=${ac_cv_fread_reads_directories=yes} \
+                 "
+EXTRA_OEMAKE += "NO_GETTEXT=1"
+
+SRC_URI[tarball.md5sum] = "c64012d491e24c7d65cd389f75383d91"
+SRC_URI[tarball.sha256sum] = "7104c4f5d948a75b499a954524cb281fe30c6649d8abe20982936f75ec1f275b"
+SRC_URI[manpages.md5sum] = "58020dc13a5801c49f7986fef7027535"
+SRC_URI[manpages.sha256sum] = "0dfe1931ad302873470e0280248e3aa50502b5edd00dcc3e9c9173667b6fea6a"
diff --git a/yocto-poky/meta/recipes-devtools/gnu-config/gnu-config_20120814.bb b/yocto-poky/meta/recipes-devtools/gnu-config/gnu-config_20120814.bb
index eb7e420..0d05e79 100644
--- a/yocto-poky/meta/recipes-devtools/gnu-config/gnu-config_20120814.bb
+++ b/yocto-poky/meta/recipes-devtools/gnu-config/gnu-config_20120814.bb
@@ -4,7 +4,7 @@
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://config.guess;endline=39;md5=b79a4663475f4d724846463277817e0d"
 
-DEPENDS_class-native = "perl-native-runtime"
+DEPENDS_class-native = "hostperl-runtime-native"
 
 INHIBIT_DEFAULT_DEPS = "1"
 
diff --git a/yocto-poky/meta/recipes-devtools/gnu-config/gnu-config_git.bb b/yocto-poky/meta/recipes-devtools/gnu-config/gnu-config_git.bb
index 3d5f2b8..072726f 100644
--- a/yocto-poky/meta/recipes-devtools/gnu-config/gnu-config_git.bb
+++ b/yocto-poky/meta/recipes-devtools/gnu-config/gnu-config_git.bb
@@ -4,7 +4,7 @@
 LICENSE = "GPL-3.0-with-autoconf-exception"
 LIC_FILES_CHKSUM = "file://config.guess;beginline=7;endline=27;md5=9bac8b1743c2240ae07cce6e546ac2f2"
 
-DEPENDS_class-native = "perl-native-runtime"
+DEPENDS_class-native = "hostperl-runtime-native"
 
 INHIBIT_DEFAULT_DEPS = "1"
 
diff --git a/yocto-poky/meta/recipes-devtools/guile/files/0001-libguile-Check-for-strtol_l-during-configure.patch b/yocto-poky/meta/recipes-devtools/guile/files/0001-libguile-Check-for-strtol_l-during-configure.patch
new file mode 100644
index 0000000..24f073f
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/guile/files/0001-libguile-Check-for-strtol_l-during-configure.patch
@@ -0,0 +1,56 @@
+From 814d6fb6c1f4a544c8fd37f5a390ba020c2d8c85 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 10 Jan 2016 22:28:17 +0000
+Subject: [PATCH] libguile: Check for strtol_l during configure
+
+strtol_l is a gnu extention which may not be available on other linux
+libc implementations e.g. musl. Therefore check for this funciton and
+conditionalize the use of it.
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ configure.ac    | 5 +++--
+ libguile/i18n.c | 2 +-
+ 2 files changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 3969929..f8a6a1a 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -752,7 +752,8 @@ AC_CHECK_HEADERS([assert.h crt_externs.h])
+ #   truncate - not in mingw
+ #   isblank - available as a GNU extension or in C99
+ #   _NSGetEnviron - Darwin specific
+-#   strcoll_l, newlocale - GNU extensions (glibc), also available on Darwin
++#   strcoll_l, newlocale, strtol_l - GNU extensions (glibc),
++#                                    also available on Darwin
+ #   fork - unavailable on Windows
+ #   utimensat - posix.1-2008
+ #   sched_getaffinity, sched_setaffinity - GNU extensions (glibc)
+@@ -768,7 +769,7 @@ AC_CHECK_FUNCS([DINFINITY DQNAN cexp chsize clog clog10 ctermid		\
+   getgrent kill getppid getpgrp fork setitimer getitimer strchr strcmp	\
+   index bcopy memcpy rindex truncate unsetenv isblank _NSGetEnviron	\
+   strcoll strcoll_l newlocale utimensat sched_getaffinity		\
+-  sched_setaffinity sendfile])
++  sched_setaffinity sendfile strtol_l])
+ 
+ AM_CONDITIONAL([BUILD_ICE_9_POPEN],
+   [test "x$enable_posix" = "xyes" && test "x$ac_cv_func_fork" = "xyes"])
+diff --git a/libguile/i18n.c b/libguile/i18n.c
+index 97d44b0..9fb6976 100644
+--- a/libguile/i18n.c
++++ b/libguile/i18n.c
+@@ -1352,7 +1352,7 @@ SCM_DEFINE (scm_locale_string_to_integer, "locale-string->integer",
+ 
+   if (c_locale != NULL)
+     {
+-#ifdef USE_GNU_LOCALE_API
++#if defined(USE_GNU_LOCALE_API) && defined(HAVE_STRTOL_L)
+       c_result = strtol_l (c_str, &c_endptr, c_base, c_locale);
+ #else
+       RUN_IN_LOCALE_SECTION (c_locale,
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/guile/files/0002-Recognize-nios2-as-compilation-target.patch b/yocto-poky/meta/recipes-devtools/guile/files/0002-Recognize-nios2-as-compilation-target.patch
new file mode 100644
index 0000000..519585b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/guile/files/0002-Recognize-nios2-as-compilation-target.patch
@@ -0,0 +1,36 @@
+From 76155065c70b5ab65c6c805423183b360141db84 Mon Sep 17 00:00:00 2001
+From: Marek Vasut <marex@denx.de>
+Date: Thu, 28 Jan 2016 04:46:23 +0100
+Subject: [PATCH] Recognize nios2 as compilation target
+
+Signed-off-by: Marek Vasut <marex@denx.de>
+Upstream-Status: Submitted [ http://debbugs.gnu.org/cgi/bugreport.cgi?bug=22480 ]
+---
+ module/system/base/target.scm | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/module/system/base/target.scm b/module/system/base/target.scm
+index d60a8e0..d1f6cff 100644
+--- a/module/system/base/target.scm
++++ b/module/system/base/target.scm
+@@ -65,7 +65,7 @@
+       (cond ((string-match "^i[0-9]86$" cpu)
+              (endianness little))
+             ((member cpu '("x86_64" "ia64"
+-                           "powerpcle" "powerpc64le" "mipsel" "mips64el"))
++                           "powerpcle" "powerpc64le" "mipsel" "mips64el" "nios2"))
+              (endianness little))
+             ((member cpu '("sparc" "sparc64" "powerpc" "powerpc64" "spu"
+                            "mips" "mips64"))
+@@ -100,7 +100,7 @@
+ 
+           ((string-match "64$" cpu) 8)
+           ((string-match "64[lbe][lbe]$" cpu) 8)
+-          ((member cpu '("sparc" "powerpc" "mips" "mipsel")) 4)
++          ((member cpu '("sparc" "powerpc" "mips" "mipsel" "nios2")) 4)
+           ((string-match "^arm.*" cpu) 4)
+           (else (error "unknown CPU word size" cpu)))))
+ 
+-- 
+2.7.0.rc3
+
diff --git a/yocto-poky/meta/recipes-devtools/guile/files/remove_strcase_l_funcs.patch b/yocto-poky/meta/recipes-devtools/guile/files/remove_strcase_l_funcs.patch
new file mode 100644
index 0000000..e7a06fe
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/guile/files/remove_strcase_l_funcs.patch
@@ -0,0 +1,38 @@
+These unused functions cause build failures with uclibc since they reference __uclibc_locale_struct
+and this is exposed by uclibc API headers only if C locales are built, but for OE we build full locale
+support
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Pending
+Index: guile-2.0.11/libguile/i18n.c
+===================================================================
+--- guile-2.0.11.orig/libguile/i18n.c
++++ guile-2.0.11/libguile/i18n.c
+@@ -851,27 +851,6 @@ str_downcase (register char *dst, regist
+   *dst = '\0';
+ }
+ 
+-#ifdef USE_GNU_LOCALE_API
+-static inline void
+-str_upcase_l (register char *dst, register const char *src,
+-	      scm_t_locale locale)
+-{
+-  for (; *src != '\0'; src++, dst++)
+-    *dst = toupper_l (*src, locale);
+-  *dst = '\0';
+-}
+-
+-static inline void
+-str_downcase_l (register char *dst, register const char *src,
+-		scm_t_locale locale)
+-{
+-  for (; *src != '\0'; src++, dst++)
+-    *dst = tolower_l (*src, locale);
+-  *dst = '\0';
+-}
+-#endif
+-
+-
+ SCM_DEFINE (scm_string_locale_lt, "string-locale<?", 2, 1, 0,
+ 	    (SCM s1, SCM s2, SCM locale),
+ 	    "Compare strings @var{s1} and @var{s2} in a locale-dependent way."
diff --git a/yocto-poky/meta/recipes-devtools/guile/guile_2.0.11.bb b/yocto-poky/meta/recipes-devtools/guile/guile_2.0.11.bb
index 98b465b..6cefe66 100644
--- a/yocto-poky/meta/recipes-devtools/guile/guile_2.0.11.bb
+++ b/yocto-poky/meta/recipes-devtools/guile/guile_2.0.11.bb
@@ -23,6 +23,9 @@
            file://workaround-ice-ssa-corruption.patch \
            file://libguile-Makefile.am-hook.patch \
            file://libguile-VM-ASM_MUL-for-ARM-Add-earlyclobber.patch \
+           file://remove_strcase_l_funcs.patch \
+           file://0001-libguile-Check-for-strtol_l-during-configure.patch \
+           file://0002-Recognize-nios2-as-compilation-target.patch \
            "
 
 #           file://debian/0001-Change-guile-to-guile-X.Y-for-info-pages.patch
@@ -50,6 +53,13 @@
 EXTRA_OECONF_append_class-target = " --with-libunistring-prefix=${STAGING_LIBDIR} \
                                      --with-libgmp-prefix=${STAGING_LIBDIR} \
                                      --with-libltdl-prefix=${STAGING_LIBDIR}"
+EXTRA_OECONF_append_libc-uclibc = " guile_cv_use_csqrt=no "
+
+CFLAGS_append_libc-musl = " -DHAVE_GC_SET_FINALIZER_NOTIFIER \
+	                    -DHAVE_GC_GET_HEAP_USAGE_SAFE \
+	                    -DHAVE_GC_GET_FREE_SPACE_DIVISOR \
+	                    -DHAVE_GC_SET_FINALIZE_ON_DEMAND \
+                           "
 
 do_configure_prepend() {
 	mkdir -p po
@@ -57,19 +67,6 @@
 
 export GUILE_FOR_BUILD="${BUILD_SYS}-guile"
 
-do_compile_append() {
-	# just for target recipe
-	if [ "${PN}" = "guile" ]
-	then
-		sed -i -e s:${STAGING_DIR_TARGET}::g \
-	               -e s:/${TARGET_SYS}::g \
-	               -e s:-L/usr/lib::g \
-        	       -e s:-isystem/usr/include::g \
-	               -e s:,/usr/lib:,\$\{libdir\}:g \
-	                  meta/guile-2.0.pc
-	fi
-}
-
 do_install_append_class-native() {
 	install -m 0755  ${D}${bindir}/guile ${D}${bindir}/${HOST_SYS}-guile
 
@@ -83,8 +80,14 @@
 
 do_install_append_class-target() {
 	# cleanup buildpaths in scripts
-	sed -i -e 's:${STAGING_DIR_NATIVE}::' ${D}/usr/bin/guile-config
-	sed -i -e 's:${STAGING_DIR_HOST}::' ${D}/usr/bin/guile-snarf
+	sed -i -e 's:${STAGING_DIR_NATIVE}::' ${D}${bindir}/guile-config
+	sed -i -e 's:${STAGING_DIR_HOST}::' ${D}${bindir}/guile-snarf
+
+	sed -i -e 's:${STAGING_DIR_TARGET}::g' ${D}${libdir}/pkgconfig/guile-2.0.pc
+}
+
+do_install_append_libc-musl() {
+	rm -f ${D}${libdir}/charset.alias
 }
 
 SYSROOT_PREPROCESS_FUNCS = "guile_cross_config"
diff --git a/yocto-poky/meta/recipes-devtools/help2man/help2man-native_1.47.1.bb b/yocto-poky/meta/recipes-devtools/help2man/help2man-native_1.47.3.bb
similarity index 79%
rename from yocto-poky/meta/recipes-devtools/help2man/help2man-native_1.47.1.bb
rename to yocto-poky/meta/recipes-devtools/help2man/help2man-native_1.47.3.bb
index bc6d50e..232b0c3 100644
--- a/yocto-poky/meta/recipes-devtools/help2man/help2man-native_1.47.1.bb
+++ b/yocto-poky/meta/recipes-devtools/help2man/help2man-native_1.47.3.bb
@@ -6,8 +6,8 @@
 
 SRC_URI = "${GNU_MIRROR}/${BPN}/${BPN}-${PV}.tar.xz"
 
-SRC_URI[md5sum] = "cf7aaaeea40bff1176df825430694173"
-SRC_URI[sha256sum] = "c59b26f60cb06e45b00e729dea721e7a17220e2c17d800eb428271a750382b06"
+SRC_URI[md5sum] = "d1d44a7a7b2bd61755a2045d96ecaea0"
+SRC_URI[sha256sum] = "c232af6475ef65bee02770862a362f4c4c2e6c9967d39e987eb94cadcfc13856"
 
 inherit autotools native
 
diff --git a/yocto-poky/meta/recipes-devtools/i2c-tools/i2c-tools_3.1.2.bb b/yocto-poky/meta/recipes-devtools/i2c-tools/i2c-tools_3.1.2.bb
index 042695b..4d25542 100644
--- a/yocto-poky/meta/recipes-devtools/i2c-tools/i2c-tools_3.1.2.bb
+++ b/yocto-poky/meta/recipes-devtools/i2c-tools/i2c-tools_3.1.2.bb
@@ -3,7 +3,7 @@
 LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe"
 
-SRC_URI = "http://dl.lm-sensors.org/i2c-tools/releases/${BP}.tar.bz2 \
+SRC_URI = "http://downloads.yoctoproject.org/mirror/sources/${BP}.tar.bz2 \
            file://Module.mk \
 "
 SRC_URI[md5sum] = "7104a1043d11a5e2c7b131614eb1b962"
diff --git a/yocto-poky/meta/recipes-devtools/installer/adt-installer/adt_installer b/yocto-poky/meta/recipes-devtools/installer/adt-installer/adt_installer
deleted file mode 100755
index b8cfb2e..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/adt-installer/adt_installer
+++ /dev/null
@@ -1,420 +0,0 @@
-#!/bin/bash
-# Yocto ADT Installer
-#
-# Copyright 2010-2011 by Intel Corp.
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy 
-# of this software and associated documentation files (the "Software"), to deal 
-# in the Software without restriction, including without limitation the rights 
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 
-# copies of the Software, and to permit persons to whom the Software is 
-# furnished to do so, subject to the following conditions:
-
-# The above copyright notice and this permission notice shall be included in 
-# all copies or substantial portions of the Software.
-
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 
-# THE SOFTWARE.
-
-
-usage ()
-{
-
-  INST_ARCH=`uname -m`
-  INST_OS=`uname -o| tr '[A-Z]' '[a-z]'`
-  INST_KR=`uname -r| tr '[A-Z]' '[a-z]'`
-
-  echo_info "#########################################################################"
-  echo_info "# Welcome to Yocto Application Developement Tools (ADT) Installer"
-  echo_info "# "
-  echo_info "# Host Machine:\t\t\t\t"$INST_ARCH
-  echo_info "# OS info:\t\t\t\t$INST_KR"  
-  echo_info "# Yocto ADT version to be installed:\t$YOCTOADT_VERSION"
-  echo_info "# supported target architectures:\t$YOCTOADT_SUPPORTED_TARGETS"
-  echo_info "# supported target root_fs images:\t$YOCTOADT_SUPPORTED_ROOTFS"
-  echo_info "#########################################################################\n"
-
-  echo_info "Systemwide installation. Installation will occur under $INSTALL_FOLDER\n"
-  echo_info "############################################################################"
-  echo_info "# Your system installation configurations from adt_installer.conf"
-  echo_info "############################################################################"
-
-  echo_info "# Cross toolchains:\t\t$YOCTOADT_TARGETS"
-  echo_info "# Install Qemu:\t\t\t$YOCTOADT_QEMU"
-  echo_info "# Install NFS utilities:\t$YOCTOADT_NFS_UTIL"
-  #echo_info "# Install bitbake + UI:\t\t$YOCTOADT_BITBAKE"
-  #echo_info "# Install metadata:\t$YOCTOADT_METADATA"
-  #echo_info "############################################################################\n"
-
-    echo_info "\n##############################################################################"
-    echo_info "# Your rootfs image(s) and target sysroot selections from adt_installer.conf"
-    echo_info "##############################################################################"
-prompt=1
-for arch_type in $YOCTOADT_TARGETS; do
-  download_images $arch_type $prompt
-done
-    echo_info "############################################################################\n"
-  select_install_type
-}
-
-validate_config()
-{
-
-  for selected_arch_type in $YOCTOADT_TARGETS; do
-    found=0
-    select_machine_var="\$YOCTOADT_TARGET_MACHINE_$selected_arch_type"
-    select_machine=`eval echo $select_machine_var`
-    show_error_banner=0
-
-    for supported_arch_type in $YOCTOADT_SUPPORTED_TARGETS; do
-      if [ "$selected_arch_type" == "$supported_arch_type" ]; then
-        found=1
-        break
-      fi
-    done
-    if [ $found == 0 ]; then
-       echo_info "[ADT_INST] Error: YOCTADT_TARGETS in adt_installer.conf contains invalid entries: $YOCTOADT_TARGETS. Valid values are: $YOCTOADT_SUPPORTED_TARGETS"
-       show_error_banner=1
-    elif [ -z "$select_machine" ]; then
-       echo_info "[ADT_INST] Error: No MACHINE was defined for $selected_arch_type architecture! This is needed to install the toolchain and the correct environment settings."
-       echo_info "[ADT_INST] To do that, in adt-installer.conf, set the following variable: YOCTOADT_TARGET_MACHINE_$selected_arch_type"
-       show_error_banner=1
-    fi
-
-    if [ $show_error_banner == 1 ]; then
-       echo -e "\n#############################################################################"
-       echo -e "# Meet error(s) when installing Yocto ADT! Please check log file for details. "
-       echo -e "#############################################################################\n"
-       exit -1
-    fi
-  done
-
-  for arch_type in $YOCTOADT_SUPPORTED_TARGETS; do
-    #select_target_var="\$YOCTOADT_TARGET_$arch_type"
-    #select_target=`eval echo $select_target_var`
-
-    #if [ "$select_target" != "Y" ] || [ "$selected_target" != "y" ]; then
-    #  continue;
-    #fi
-
-    target_sysroot_image_var="\$YOCTOADT_TARGET_SYSROOT_IMAGE_$arch_type"
-    target_sysroot_image=`eval echo $target_sysroot_image_var`
-
-
-    select_rootfs_var="\$YOCTOADT_ROOTFS_$arch_type"
-    select_rootfs=`eval echo $select_rootfs_var`
-
-    if [ "$select_rootfs" == "" ] && [ "$target_sysroot_image" == "" ]; then
-       continue;
-    fi
-
-    for image_type in $select_rootfs; do
-#validate rootfs type defined in YOCTOADT_ROOTFS_{ARCH} is valid and in YOCTOADT_SUPPORTED_ROOTFS
-      found=0
-      for supported_rootfs_type in $YOCTOADT_SUPPORTED_ROOTFS; do
-        if [ "$image_type" == "$supported_rootfs_type" ]; then
-          found=1
-          break
-        fi
-      done
-      if [ $found == 0 ]; then
-#the rootfs type listed for downloading is not valid
-        echo_info "[ADT_INST] Error: Selected YOCTOADT_ROOTFS_$arch_type value: $image_type, is not valid! Valid values are: $YOCTOADT_SUPPORTED_ROOTFS "
-       echo -e "\n#############################################################################"
-       echo -e "# Meet error(s) when installing Yocto ADT! Please check log file for details. "
-       echo -e "#############################################################################\n"
-        exit -1
-      fi
-    done
-
-    found=0
-    for image_type in $select_rootfs; do
-#validate that rootfs to be extracted must be in the item: YOCTOADT_ROOTFS_${ARCH}
-      if [ "$target_sysroot_image" == "$image_type" ]; then
-        found=1
-        break
-      fi
-    done
-# the rootfs image to be extracted is not selected
-    if [ $found == 0 ]; then
-      echo_info "[ADT_INST] Error: YOCTOADT_TARGET_SYSROOT_IMAGE_$arch_type selection: $target_sysroot_image is not included in YOCTOADT_ROOTFS_$arch_type selections: $select_rootfs"
-      echo -e "\n#############################################################################"
-      echo -e "# Meet error(s) when installing Yocto ADT! Please check log file for details. "
-      echo -e "#############################################################################\n"
-      exit -1
-    fi
-  done
-}
-
-
-#detect opkg installed or not, for installing sdk, we will use
-#this installed local opkg
-install_opkg()
-{
-if [ ! -x "$LOCAL_OPKG_LOC/bin/opkg" ]; then
-  echo_info "OPKG is not setup, setting up opkg in local, which is required for installing yocto ADT...\n"
-
-  if [ -d $LOCAL_OPKG_LOC ]; then
-    echo_info "Deleting old OPKG folder, which doesn't contain executables... "
-    rm -rf $LOCAL_OPKG_LOC
-  fi
-
-  parent_folder=`pwd`
-  cd $LOCAL_OPKG_FOLDER
-  check_result
-
-  opkg_source_dir=`ls -d opkg-*`
-
-  if [ $opkg_source_dir == "" ]; then
-    echo_info "[ADT_INST] Error: OPKG source directory is not found!"
-    echo -e "\n#############################################################################"
-    echo -e "# Meet error(s) when installing Yocto ADT! Please check log file for details. "
-    echo -e "#############################################################################\n"
-    exit -1
-  fi
-
-  cd $opkg_source_dir
-  check_result
-
-  echo_info "Configure opkg ...\n"
-  autoreconf -i
-  ./configure --prefix=$parent_folder/$LOCAL_OPKG_LOC --enable-shared=no --disable-curl --disable-ssl-curl --disable-gpg >> $parent_folder/$YOCTOADT_INSTALL_LOG_FILE
-  check_result
-
-  echo_info "Make opkg ...\n"
-  make &>> $parent_folder/$YOCTOADT_INSTALL_LOG_FILE
-  check_result
-
-  echo_info "Make Install opkg ...\n"
-  make install &>> $parent_folder/$YOCTOADT_INSTALL_LOG_FILE
-  #if meet error when installing opkg, cancel the installation
-  check_result
-
-  cd $parent_folder
-  echo_info "Successfully installed OPKG.\n"
-fi
-}
-
-confirm_download()
-{
-#avoid repeated reminding
-if [ "$override_oldfile" == 1 ]; then
-  return $pre_result
-else
-  override_oldfile=1
-fi
-
-while true; do
-  #echo_info "[ADT_INST] Files [$1] already exists. If you continue downloading, old files will be overrided."
-  #echo_info "[ADT_INST] Further prompts will not be given if there're more existing files to be downloaded."
-  #echo_info "[ADT_INST] Do you want to continue downloading? Please enter Y/N:"
-  echo_info "\nFile [$1] already exists, which means you've downloaded the qemu kernel and rootfs file(s) before.  If you choose continue downloading, old files will be overridden."
-  echo_info "[ADT_INST] Do you want to continue downloading? Please enter Y/N:"
-  read YOCTOADT_INSTALL
-  YOCTOADT_INSTALL=`tr '[a-z]' '[A-Z]'<<<"$YOCTOADT_INSTALL"`
-  if [ "$YOCTOADT_INSTALL" == "Y" ]; then
-    pre_result=0
-    return 0
-  elif [ "$YOCTOADT_INSTALL" == "N" ]; then
-    pre_result=1
-    return 1
-  fi
-done
-}
-
-download_file()
-{
-local filename=`echo ${1##*/}`
-if [ -f "$LOCAL_DOWNLOAD/$filename" ]; then
-  confirm_download $filename
-  result="$?"
-  if [ ! "$result" == "0" ]; then
-    return
-  else
-    echo "Removing old file [$1]"
-    rm -rf "$LOCAL_DOWNLOAD/$filename" 
-  fi
-fi
-echo_info "Downloading file: $filename..."
-wget "$YOCTOADT_REPO/rootfs/$1" -P $LOCAL_DOWNLOAD --progress=bar:force 2>&1 | tee -a "$YOCTOADT_INSTALL_LOG_FILE" 
-}
-
-
-
-#Need three input params:
-# $1 arch_type(arm powerpc x86 mips)
-# $2 machine(qemuarm beagleboard)
-# $3 rootfs_image_type (a list of sdk sato minimal lsb)
-get_image()
-{
-  local machine=$2
- 
-  if [ "$1" == "x86" ] || [ "$1" == "x86_64" ]; then
-    kernel="bzImage-$machine.bin"
-  elif [ "$1" == "ppc" ] || [ "$1" == "mips" ]; then
-    kernel="vmlinux-$machine.bin"
-  else
-    kernel="zImage-$machine.bin"
-  fi
-
-  #echo_info "[ADT_INST] Downloading qemu kernel binary: $qemu_kernel"
-  download_file $machine/$kernel
-  check_result
-  
-  for image_type in $select_rootfs; do
-    #echo_info "[ADT_INST] Downloading rootfs file: core-image-$image_type-$machine.tar.bz2"
-    filename="core-image-$image_type-$machine.tar.bz2"
-    download_file $machine/$filename
-    check_result
-  done
-}
-
-download_images()
-{
-  select_rootfs_var="\$YOCTOADT_ROOTFS_$1"
-  select_sysroot_image_var="\$YOCTOADT_TARGET_SYSROOT_IMAGE_$1"
-  select_sysroot_var="\$YOCTOADT_TARGET_SYSROOT_LOC_$1"
-  select_machine_var="\$YOCTOADT_TARGET_MACHINE_$1"
-  select_rootfs=`eval echo $select_rootfs_var`
-  select_sysroot_image=`eval echo $select_sysroot_image_var`
-  select_sysroot=`eval echo $select_sysroot_var`
-  select_machine=`eval echo $select_machine_var`
-
-  if [ -n "$select_sysroot" ]; then
-    select_sysroot=`readlink -m $select_sysroot`
-  fi
-
-  if [ "$select_rootfs" != "" ]; then
-    if [ $2 ]; then
-    #echo_info "\n############################################################################"
-    #echo_info "# To be downloaded rootfs image details defined in adt_installer.conf"
-    #echo_info "############################################################################"
-    echo_info "# Target architecture:\t\t$1"
-    echo_info "# Target machine:\t\t$select_machine"
-    echo_info "# Root_fs images:\t\t$select_rootfs"
-    echo_info "# Target sysroot image:\t\t$select_sysroot_image"
-    echo_info "# Target sysroot loc:\t\t$select_sysroot"
-    echo_info "\n"
-    #echo_info "############################################################################\n"
-    else
-    get_image $1 $select_machine $select_rootfs
-    fi
-  fi
-}
-
-
-
-
-#Main body of installer
-
-clear
-
-run_path=`dirname $0`
-cd $run_path
-
-if [ ! -f "scripts/util" ]; then
-  echo -e "[ADT_INST] Error: Script file: util, can't be found under: $run_path!"
-  echo -e "\n#############################################################################"
-  echo -e "# Meet error(s) when installing Yocto ADT! Please check log file for details. "
-  echo -e "#############################################################################\n"
-  exit -1
-fi
-
-if [ ! -f "scripts/adt_installer_internal" ]; then
-  echo -e "[ADT_INST] Error: Script file: adt_installer_internal, can't be found under: $run_path!"
-  echo -e "\n#############################################################################"
-  echo -e "# Meet error(s) when installing Yocto ADT! Please check log file for details. "
-  echo -e "#############################################################################\n"
-  exit -1
-fi
-
-config_file="adt_installer.conf"
-if [ ! -f "$config_file" ]; then
-  echo_info "[ADT_INST] Error: Installation configuration file: adt_installer.conf is not found!\n"
-  echo_info "\n##################################################################################"
-  echo_info "# Meet error(s) when installing Yocto ADT. Please check log file for details. "
-  echo_info "##################################################################################\n"
-  exit -1
-fi
-
-. scripts/data_define
-. scripts/util
-
-
-if [ -f "$YOCTOADT_INSTALL_LOG_FILE" ]; then
-  rm $YOCTOADT_INSTALL_LOG_FILE
-fi
-
-echo -n "Please enter the install location (default: $DEFAULT_INSTALL_FOLDER): "
-read INSTALL_FOLDER
-
-if [ "$INSTALL_FOLDER" = "" ]; then
-    INSTALL_FOLDER=$DEFAULT_INSTALL_FOLDER
-fi
-
-eval INSTALL_FOLDER=$(printf "%q" "$INSTALL_FOLDER")
-if [ -d "$INSTALL_FOLDER" ]; then
-	export INSTALL_FOLDER=$(cd "$INSTALL_FOLDER"; pwd)
-else
-	export INSTALL_FOLDER=$(readlink -m "$INSTALL_FOLDER")
-fi
-
-if [ -n "$(echo $INSTALL_FOLDER|grep ' ')" ]; then
-       echo "The target directory path ($INSTALL_FOLDER) contains spaces. Abort!"
-       exit 1
-fi
-
-clear
-
-usage
-
-user_inst_type="$?"
-
-validate_config
-check_result
-
-#check adt_repo exist
-wget --spider $YOCTOADT_REPO 2>&1 | tee -a "$YOCTOADT_INSTALL_LOG_FILE"
-if grep -q "404 Not Found" $YOCTOADT_INSTALL_LOG_FILE; then
-  echo -e "[ADT_INST] Error: YOCTOADT_REPO does not exist: $YOCTOADT_REPO"
-  echo -e "\n#############################################################################"
-  echo -e "# Meet error(s) when installing Yocto ADT! Please check log file for details. "
-  echo -e "#############################################################################\n"
-  exit -1
-fi
-
-#firstly we need to install opkg host
-install_opkg
-
-#Create folders for holding rootfs/qemu images
-if [ ! -d "$LOCAL_DOWNLOAD" ]; then
-  echo_info "Creating new images downloading folder: $LOCAL_DOWNLOAD ..."
-  mkdir -p $LOCAL_DOWNLOAD
-fi
-
-#downloading required qemu images/rootfs
-if [ "$user_inst_type" == "0" ]; then
-  override_oldfile=1
-else
-  override_oldfile=0
-fi
-
-for arch_type in $YOCTOADT_TARGETS; do
-  download_images $arch_type
-done
-
-scripts/adt_installer_internal $user_inst_type
-
-result="$?"
-#echo_info "\n############################################################"
-if [ "$result" == "0" ]; then
-  echo_info "\n############################################################"
-  echo_info "# Yocto ADT has been successfully installed."
-  echo_info "############################################################\n"
-fi
-
diff --git a/yocto-poky/meta/recipes-devtools/installer/adt-installer/adt_installer.conf b/yocto-poky/meta/recipes-devtools/installer/adt-installer/adt_installer.conf
deleted file mode 100644
index 867fbd1..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/adt-installer/adt_installer.conf
+++ /dev/null
@@ -1,75 +0,0 @@
-# Yocto ADT Installer Configuration File
-#
-# Copyright 2010-2011 by Intel Corp.
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy 
-# of this software and associated documentation files (the "Software"), to deal 
-# in the Software without restriction, including without limitation the rights 
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 
-# copies of the Software, and to permit persons to whom the Software is 
-# furnished to do so, subject to the following conditions:
-
-# The above copyright notice and this permission notice shall be included in 
-# all copies or substantial portions of the Software.
-
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 
-# THE SOFTWARE.
-
-
-# Your yocto distro repository, this should include IPKG based packages and root filesystem files where the installation is based on
-
-YOCTOADT_REPO="ADTREPO"
-
-# The following are for system wide setup
-# Target architectures that you want to setup host cross dev environment for
-# valid values are: arm, x86, x86_64, ppc, mips with space separation between entries
-YOCTOADT_TARGETS="arm x86"
-# Whether install qemu or not, valid entries are: Y/N
-YOCTOADT_QEMU="Y"
-# Whether install user-mode nfs or not, valid entries are: Y/N.  If you want to use Yocto Eclipse plug-in as your dev IDE, you need to select both qemu and NFS
-YOCTOADT_NFS_UTIL="Y"
-
-# These 2 values will be supported in the furture installer
-#YOCTOADT_BITBAKE="Y"
-#YOCTOADT_METADATA="Y"
-
-#The followings are for setting up specific target architecture
-#YOCTOADT_ROOTFS_$arch is for specifying what root filesystem image files you want to download from the repository. The valid values to replace $arch are: arm, x86, x86_64, powerpc, mips.  The valid image files are: minimal, minimal-dev, sato, sato-dev, sato-sdk,lsb, lsb-dev, lsb-sdk.  If you want to download multiple images, the entries are space separated
-YOCTOADT_ROOTFS_arm="minimal sato-sdk"
-#Specify which root filesystem file to use to extract as target sysroot.  Please ensure the entry is in the list of downloaded root filesystem files that specified above in YOCTOADT_ROOTFS_$arch
-YOCTOADT_TARGET_SYSROOT_IMAGE_arm="sato-sdk"
-#The machine for which you want to download the image. Each machine might have
-#different compilation options in order to select certain hardware models or
-#configurations
-YOCTOADT_TARGET_MACHINE_arm="qemuarm"
-#The location where the target sysroot will be setup
-YOCTOADT_TARGET_SYSROOT_LOC_arm="$HOME/test-yocto/$YOCTOADT_TARGET_MACHINE_arm"
-
-
-#Here's a template for setting up target arch of x86 
-YOCTOADT_ROOTFS_x86="sato-sdk"
-YOCTOADT_TARGET_SYSROOT_IMAGE_x86="sato-sdk"
-YOCTOADT_TARGET_MACHINE_x86="qemux86"
-YOCTOADT_TARGET_SYSROOT_LOC_x86="$HOME/test-yocto/$YOCTOADT_TARGET_MACHINE_x86"
-
-#Here's some template of other arches, which you need to change the value in ""
-YOCTOADT_ROOTFS_x86_64="sato-sdk"
-YOCTOADT_TARGET_SYSROOT_IMAGE_x86_64="sato-sdk"
-YOCTOADT_TARGET_MACHINE_x86_64="qemux86-64"
-YOCTOADT_TARGET_SYSROOT_LOC_x86_64="$HOME/test-yocto/$YOCTOADT_TARGET_MACHINE_x86_64"
-
-YOCTOADT_ROOTFS_ppc="sato-sdk"
-YOCTOADT_TARGET_SYSROOT_IMAGE_ppc="sato-sdk"
-YOCTOADT_TARGET_MACHINE_ppc="qemuppc"
-YOCTOADT_TARGET_SYSROOT_LOC_ppc="$HOME/test-yocto/$YOCTOADT_TARGET_MACHINE_ppc"
-
-YOCTOADT_ROOTFS_mips="sato-sdk"
-YOCTOADT_TARGET_SYSROOT_IMAGE_mips="sato-sdk"
-YOCTOADT_TARGET_MACHINE_mips="qemumips"
-YOCTOADT_TARGET_SYSROOT_LOC_mips="$HOME/test-yocto/$YOCTOADT_TARGET_MACHINE_mips"
-
diff --git a/yocto-poky/meta/recipes-devtools/installer/adt-installer/opkg/conf/opkg-sdk-i686.conf b/yocto-poky/meta/recipes-devtools/installer/adt-installer/opkg/conf/opkg-sdk-i686.conf
deleted file mode 100644
index ba627b3..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/adt-installer/opkg/conf/opkg-sdk-i686.conf
+++ /dev/null
@@ -1,6 +0,0 @@
-arch all 1
-arch any 6
-arch noarch 11
-arch i686-nativesdk 16
-src yp-i686-nativesdk ADTREPO_URL/adt-ipk/i686-nativesdk
-src yp-i686-all ADTREPO_URL/adt-ipk/all
diff --git a/yocto-poky/meta/recipes-devtools/installer/adt-installer/opkg/conf/opkg-sdk-x86_64.conf b/yocto-poky/meta/recipes-devtools/installer/adt-installer/opkg/conf/opkg-sdk-x86_64.conf
deleted file mode 100644
index 10504a9..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/adt-installer/opkg/conf/opkg-sdk-x86_64.conf
+++ /dev/null
@@ -1,6 +0,0 @@
-arch all 1
-arch any 6
-arch noarch 11
-arch x86_64-nativesdk 16
-src yp-x86_64-nativesdk ADTREPO_URL/adt-ipk/x86_64-nativesdk
-src yp-x86_64-all ADTREPO_URL/adt-ipk/all
diff --git a/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/adt_installer_internal b/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/adt_installer_internal
deleted file mode 100755
index 6f5fb49..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/adt_installer_internal
+++ /dev/null
@@ -1,312 +0,0 @@
-#!/bin/bash
-
-# Yocto ADT Installer
-#
-# Copyright 2010-2011 by Intel Corp.
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy 
-# of this software and associated documentation files (the "Software"), to deal 
-# in the Software without restriction, including without limitation the rights 
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 
-# copies of the Software, and to permit persons to whom the Software is 
-# furnished to do so, subject to the following conditions:
-
-# The above copyright notice and this permission notice shall be included in 
-# all copies or substantial portions of the Software.
-
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 
-# THE SOFTWARE.
-
-parse_config()
-{
-  INST_ARCH=`uname -m`
-
-  case $INST_ARCH in 
-  i[3-6]86)
-    OPKG_CONFIG_FILE=$YOCTOADT_OPKG_CONF_FILE_32
-    OECORE_NATIVE_SYSROOT="$INSTALL_FOLDER/sysroots/$INST_ARCH$SDK_VENDOR-linux/"
-    ;;
-  x86_64)
-    OPKG_CONFIG_FILE=$YOCTOADT_OPKG_CONF_FILE_64
-    OECORE_NATIVE_SYSROOT="$INSTALL_FOLDER/sysroots/x86_64$SDK_VENDOR-linux/"
-    ;;
-  *)
-    echo_info "[ADT_INST] Error: Installation Machine is not supported!"
-    exit -1
-    ;;
-  esac
-}
-
-get_sudo_app()
-{
-  username=$(id -nu)
-
-  # find the owner of the parent
-  dir=$1
-  while [ 1 ]; do
-      if [ -d $dir ]; then
-          owner=$(stat -c %U $dir)
-          break
-     else
-          dir=$(dirname $dir)
-     fi
-  done
-
-  if [ "$owner" = "$username" ]; then
-      true
-  else
-      echo sudo
-  fi
-}
-
-# this function accepts arch_type (x86, x86_64, arm, ppc, mips) as the first
-# argument, returning the location of the target rootfs
-get_target_rootfs_location() {
-	[ -z "$1" ] && return
-
-	arch_type=$1
-	# rootfs extraction directory
-	target_sysroot_var="\$YOCTOADT_TARGET_SYSROOT_LOC_$arch_type"
-	target_sysroot=`eval echo $target_sysroot_var`
-
-	if [ "$target_sysroot" == "" ]; then
-		return
-	else
-		echo "`readlink -m $target_sysroot`"
-	fi
-}
-
-
-#let us install a qemu-native firstly
-#installation step 2
-install_native_sdk()
-{
-
-echo_info "\nStart installing selected native ADT for archs: $YOCTOADT_TARGETS..."
-
-# where the packages are installed.
-NATIVE_INSTALL_DIR=$INSTALL_FOLDER
-
-if [ -d "$INSTALL_FOLDER" ]; then
-  echo_info "\nNative ADT installation directory \"$INSTALL_FOLDER\" already exists! Continue installation will override its contents!"
-  confirm_install $1
-fi
-
-#Now begin to install native sdk and extract qemu rootfs which needs privilege rights
-#depending on the install location
-SUDO=$(get_sudo_app $NATIVE_INSTALL_DIR)
-if [ -n "$SUDO" ]; then
-  echo_info "#######################################################################"
-  echo_info "Please note from this point on installation requires sudo password ..."
-  echo_info "#######################################################################"
-fi
-
-#we need to make this directory firstly since opkg need to use it.
-OPKG_LOCK_DIR="$NATIVE_INSTALL_DIR/$OPKG_LIBDIR/opkg"
-if [ ! -d "$OPKG_LOCK_DIR" ]; then
-  $SUDO mkdir -p $OPKG_LOCK_DIR
-  echo_info "Successfully create directory $OPKG_LOCK_DIR. "
-#if user delete /opt/xxx, while dangling folders there, report error
-elif [ ! -d "$INSTALL_FOLDER" ]; then
-  echo_info "\nDangling opkg cache folder $OPKG_LOCK_DIR detected. Continue installation will remove the folder!"
-  confirm_install $1
-  $SUDO rm -rf $OPKG_LOCK_DIR
-  $SUDO mkdir -p $OPKG_LOCK_DIR
-#if user are updating installing, just let him/her go, give her/him prompt
-else
-  echo_info "ADT has already been installed. Will update its contents..."
-fi
-
-#first update repository
-if [ "x$SUDO" = "x" ]; then
-    OPKG_CMD="$LOCAL_OPKG_LOC/bin/opkg"
-else
-    OPKG_CMD="sudo -E $LOCAL_OPKG_LOC/bin/opkg"
-fi
-
-echo_info "Updating opkg..."
-$OPKG_CMD -f $OPKG_CONFIG_FILE -o $NATIVE_INSTALL_DIR update &>> $YOCTOADT_INSTALL_LOG_FILE
-check_result
-echo_info "opkg update process ended..."
-
-#install below must sdk-host packages
-OPKG_INSTALL_CMD="$OPKG_CMD "
-OPKG_INSTALL_NATIVE_CMD="$OPKG_INSTALL_CMD  --force-overwrite -f $OPKG_CONFIG_FILE -o $NATIVE_INSTALL_DIR install"
-
-BASE_HOSTSDK_PKGNAMES="pseudo opkg pkgconfig libtool autoconf automake"
-for pkg in $BASE_HOSTSDK_PKGNAMES; do
-  echo_info "Installing ${pkg} nativesdk ...\n"
-  $OPKG_INSTALL_NATIVE_CMD nativesdk-${pkg} &>> $YOCTOADT_INSTALL_LOG_FILE
-  check_result
-done
-
-for target_type in $YOCTOADT_TARGETS; do
-  machine_var="\$YOCTOADT_TARGET_MACHINE_$target_type"
-  machine=`eval echo $machine_var`
-  echo_info "Installing cross canadian packages for $machine ..."
-  $OPKG_INSTALL_NATIVE_CMD packagegroup-cross-canadian-$machine &>> $YOCTOADT_INSTALL_LOG_FILE
-  check_result
-
-  target_sysroot=`get_target_rootfs_location $target_type`
-  [ -z "$target_sysroot" ] && continue
-
-  # get the environment setup script paths: original (the one before relocation)
-  # and relocated
-  env_script_original=`$OPKG_CMD -f $OPKG_CONFIG_FILE -o $NATIVE_INSTALL_DIR files meta-environment-$machine|\
-							grep environment-setup`
-  env_script_relocated=$INSTALL_FOLDER/${env_script_original##*/}
-
-  # opkg will not install packagegroup-cross-canadian package if it was already
-  # installed. So, the environment script is in one place or the other.
-  [ -e "$INSTALL_FOLDER/$env_script_original" ] && env_script=$INSTALL_FOLDER/$env_script_original
-  [ -e "$env_script_original" ] && env_script=$env_script_original
-  [ -e "$env_script_relocated" ] && env_script=$env_script_relocated
-
-  $SUDO sed -i -e "s%SDKTARGETSYSROOT=.*%SDKTARGETSYSROOT=$target_sysroot%g" $env_script
-done
-
-if [ "$YOCTOADT_QEMU" == "Y" ] || [ "$YOCTOADT_QEMU" == "y" ]; then
-  echo_info "\nInstalling qemu native ..."
-  $OPKG_INSTALL_NATIVE_CMD nativesdk-qemu &>> $YOCTOADT_INSTALL_LOG_FILE
-  check_result
-  $OPKG_INSTALL_NATIVE_CMD nativesdk-qemu-helper &>> $YOCTOADT_INSTALL_LOG_FILE
-  check_result
-fi
-
-if [ "$YOCTOADT_NFS_UTIL" == "Y" ] || [ "$YOCTOADT_NFS_UTIL" == "y" ]; then
-  echo_info "\nInstalling unfs ..."
-  $OPKG_INSTALL_NATIVE_CMD nativesdk-unfs3 &>> $YOCTOADT_INSTALL_LOG_FILE
-  check_result
-fi
-
-# Lose the ./opt/${DISTRO}/${SDK_VERSION} part, we don't really need to keep
-# the entire directory structure. We could patch opkg to do that but it's far
-# simpler to do that here and achieve the same result.
-# This is done in two steps:
-if [ -d $NATIVE_INSTALL_DIR/$DEFAULT_INSTALL_FOLDER ]; then
-    # Step 1: copy ./opt/${DISTRO}/${SDK_VERSION} contents to $NATIVE_INSTALL_DIR.
-    # We cannot use move if $NATIVE_INSTALL_DIR is not empty (for example: contains
-    # another SDK)
-    $SUDO cp -r $NATIVE_INSTALL_DIR/$DEFAULT_INSTALL_FOLDER/* $NATIVE_INSTALL_DIR
-
-    # delete the source directory now
-    $SUDO rm -rf $NATIVE_INSTALL_DIR/$DEFAULT_INSTALL_FOLDER/*
-
-    # Step 2: Delete the ./opt/${DISTRO}/${SDK_VERSION} directories too, they should be empty
-    dir=$NATIVE_INSTALL_DIR/$DEFAULT_INSTALL_FOLDER
-    while [ "$dir" != "$NATIVE_INSTALL_DIR" ]; do
-        # if the user chose / as the install folder, then we should leave /opt in place
-        if [ "$dir" = "/opt" ]; then
-            break
-        fi
-
-        # try to delete the directory, only if it's empty
-        $SUDO rmdir $dir
-        if [ $? -ne 0 ]; then
-            break
-        fi
-
-        # go to the next directory
-        dir=$(dirname $dir)
-    done
-    # Step 3: Rewrite the *.list files to contain the correct paths
-    $SUDO find $NATIVE_INSTALL_DIR/var/lib/opkg -type f -exec sed -i -e '#^$DEFAULT_INSTALL_FOLDER#$NATIVE_INSTALL_DIR#' {} \;
-fi
-
-# Link the ld.so.cache file into the hosts filesystem
-if [ ! -f "$OECORE_NATIVE_SYSROOT/etc/ld.so.cache" ]; then
-echo_info "Link the ld.so.cache file into the host filesystem"
-$SUDO ln -s /etc/ld.so.cache $OECORE_NATIVE_SYSROOT/etc/ld.so.cache
-check_result
-fi
-
-# relocate binaries
-echo_info "\nRelocating binaries ..."
-escaped_sdkpath=$(echo $DEFAULT_INSTALL_FOLDER |sed -e "s:[\+\.]:\\\\\\\\\0:g")
-
-# We don't change the script in-place since we may want the user to re-run
-# adt-installer script
-sed -e "s:##DEFAULT_INSTALL_DIR##:$escaped_sdkpath:" scripts/relocate_sdk.py > scripts/relocate_sdk_tmp.py
-chmod +x scripts/relocate_sdk_tmp.py
-
-dl_path=$(find $OECORE_NATIVE_SYSROOT/lib -name "ld-linux*")
-executable_files=$(find $OECORE_NATIVE_SYSROOT -type f -perm /111)
-
-$SUDO scripts/relocate_sdk_tmp.py $INSTALL_FOLDER $dl_path $executable_files
-check_result
-
-# replace /opt/${DISTRO}/${SDK_VERSION} with the install folder in all configs
-env_setup_script=$(find $NATIVE_INSTALL_DIR/ -name "environment-setup-*")
-$SUDO sed -i -e "s:$DEFAULT_INSTALL_FOLDER:$NATIVE_INSTALL_DIR:g" $env_setup_script
-
-find $OECORE_NATIVE_SYSROOT -type f -exec file '{}' \; | grep ":.*\(ASCII\|script\|source\).*text" | \
-    cut -d':' -f1 | xargs $SUDO sed -i -e "s:$DEFAULT_INSTALL_FOLDER:$NATIVE_INSTALL_DIR:g"
-
-# change all symlinks pointing to /opt/${DISTRO}/${SDK_VERSION}
-for l in $(find $NATIVE_INSTALL_DIR -type l); do
-    $SUDO ln -sfn $(readlink $l|sed -e "s:$DEFAULT_INSTALL_FOLDER:$NATIVE_INSTALL_DIR:") $l
-done
-
-# find out all perl scripts in $OECORE_NATIVE_SYSROOT and modify them
-# replacing the host perl with SDK perl.
-for perl_script in $($SUDO grep -m 1 "^#!.*perl" -rl $OECORE_NATIVE_SYSROOT); do
-    $SUDO sed -i -e "s:^#! */usr/bin/perl.*:#! /usr/bin/env perl:g" -e \
-        "s: /usr/bin/perl: /usr/bin/env perl:g" $perl_script
-done
-
-echo_info "\nSuccessfully installed selected native ADT!"
-}
-
-#Need three input params, $1 -- arch_type(arm powerpc x86 mips) #2 -- user installation type
-#customer or scilent
-
-install_target()
-{
-
-target_sysroot=`get_target_rootfs_location $1`
-[ -z "$target_sysroot" ] && return 0
-
-target_sysroot_image_var="\$YOCTOADT_TARGET_SYSROOT_IMAGE_$1"
-target_sysroot_image=`eval echo $target_sysroot_image_var`
-if [ "$target_sysroot_image" == "" ]; then
-  echo_info "[ADT_INST] Error: YOCTOADT_TARGET_SYSROOT_IMAGE_$1 selection is empty, failed to create target sysroot!"
-  return 1
-fi
-
-echo_info "Installing target sysroot for arch: $1, rootfs type: $target_sysroot_image, location: $target_sysroot"
-
-target_machine_var="\$YOCTOADT_TARGET_MACHINE_$1"
-target_machine=`eval echo $target_machine_var`
-sysroot_image_name="core-image-$target_sysroot_image-$target_machine.tar.bz2"
-    #echo_info "Extracting rootfs: $sysroot_image_name, using pseudo..."
-
-# sudo password might be needed to install the target sysroot
-SUDO=$(get_sudo_app $target_sysroot)
-
-$SUDO scripts/extract_rootfs $sysroot_image_name $target_sysroot $OECORE_NATIVE_SYSROOT $user_inst_type
-check_result
-}
-
-
-#Main part
-. scripts/data_define
-. scripts/util
-
-parse_config
-
-#secondly we will start to install native tools
-user_inst_type=$1
-install_native_sdk $user_inst_type
-check_result
-
-for arch_type in $YOCTOADT_TARGETS; do
-  install_target $arch_type
-  check_result
-done
-
-
diff --git a/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/data_define b/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/data_define
deleted file mode 100644
index cfd6716..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/data_define
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/bin/bash
-
-# Yocto ADT Installer
-#
-# Copyright 2010-2011 by Intel Corp.
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy 
-# of this software and associated documentation files (the "Software"), to deal 
-# in the Software without restriction, including without limitation the rights 
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 
-# copies of the Software, and to permit persons to whom the Software is 
-# furnished to do so, subject to the following conditions:
-
-# The above copyright notice and this permission notice shall be included in 
-# all copies or substantial portions of the Software.
-
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 
-# THE SOFTWARE.
-
-config_file="adt_installer.conf"
-source `pwd`/$config_file
-
-LOCAL_OPKG_LOC="./opkg/build/opkg"
-LOCAL_OPKG_FOLDER="./opkg/build"
-
-# List all supported root fs types and target types,
-# it will be used in user configuration validity checking
-YOCTOADT_SUPPORTED_ROOTFS="minimal minimal-dev sato sato-dev sato-sdk lsb lsb-dev lsb-sdk"
-YOCTOADT_SUPPORTED_TARGETS="x86 x86_64 arm ppc mips"
-# Different host (32 bit or 64 bit) will have different opkg
-# configuration files
-YOCTOADT_OPKG_CONF_FILE_32="./opkg/conf/opkg-sdk-i686.conf"
-YOCTOADT_OPKG_CONF_FILE_64="./opkg/conf/opkg-sdk-x86_64.conf"
diff --git a/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/extract_rootfs b/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/extract_rootfs
deleted file mode 100755
index d1a595b..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/extract_rootfs
+++ /dev/null
@@ -1,67 +0,0 @@
-#!/bin/bash
-
-# Yocto ADT Installer
-#
-# Copyright 2010-2011 by Intel Corp.
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy 
-# of this software and associated documentation files (the "Software"), to deal 
-# in the Software without restriction, including without limitation the rights 
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 
-# copies of the Software, and to permit persons to whom the Software is 
-# furnished to do so, subject to the following conditions:
-
-# The above copyright notice and this permission notice shall be included in 
-# all copies or substantial portions of the Software.
-
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 
-# THE SOFTWARE.
-
-extract_rootfs()
-{
-
-  native_sysroot=$3
-  target_sysroot=$2
-  PSEUDO_COMMAND="$native_sysroot/usr/bin/pseudo"
-  TAR_OPTS="-xjf"
-  PSEUDO_OPTS="-P $native_sysroot/usr"
-
-
-  rm -rf $PSEUDO_LOCALSTATEDIR
-
-  if [ -d "$target_sysroot" ]; then
-    echo_info "\nTarget sysroot location: $target_sysroot, already exists! If you continue installation, this folder will be re-created."
-    confirm_install $4
-    rm -rf "$target_sysroot"
-  fi
-
-  if [ ! -d "$target_sysroot" ]; then
-    echo_info "Creating directory $target_sysroot..."
-    mkdir -p "$target_sysroot"
-  fi
-
-  pseudo_state_dir="$target_sysroot/../$(basename "$target_sysroot").pseudo_state"
-  mkdir -p "$pseudo_state_dir"
-  touch "$pseudo_state_dir/pseudo.pid"
-  PSEUDO_LOCALSTATEDIR="$pseudo_state_dir"
-  export PSEUDO_LOCALSTATEDIR
-
-  echo_info "Extracting rootfs: $1, using pseudo..."
-  $PSEUDO_COMMAND $PSEUDO_OPTS tar -C $2 "$TAR_OPTS" $LOCAL_DOWNLOAD/$1 &>> $YOCTOADT_INSTALL_LOG_FILE
-  check_result
-}
-
-#Main part
-. scripts/util
-
-#Parameter detail is listed below:
-#Param 4: Silent install or customize install
-#Param 3: OECORE_NATIVE_SYSROOT
-#Param 2: user defined rootfs extraction directory
-#param 1: sysroot image name
-extract_rootfs $1 $2 $3 $4
diff --git a/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/util b/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/util
deleted file mode 100644
index 9be7517..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/adt-installer/scripts/util
+++ /dev/null
@@ -1,104 +0,0 @@
-#!/bin/bash
-
-# Yocto ADT Installer
-#
-# Copyright 2010-2011 by Intel Corp.
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy 
-# of this software and associated documentation files (the "Software"), to deal 
-# in the Software without restriction, including without limitation the rights 
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 
-# copies of the Software, and to permit persons to whom the Software is 
-# furnished to do so, subject to the following conditions:
-
-# The above copyright notice and this permission notice shall be included in 
-# all copies or substantial portions of the Software.
-
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 
-# THE SOFTWARE.
-
-echo_info()
-{
-  echo -e $1 | tee -a $YOCTOADT_INSTALL_LOG_FILE
-}
-
-select_install_type()
-{
-# If choosing silent install, all older installation data will be
-# overriden without user's interaction
-while true; do
-  #echo_info "[ADT_INST] Silent install means overrides all existing older"
-  #echo_info "[ADT_INST] data and the installation needs least user interaction"
-  #echo_info "[ADT_INST] If you want to use silent installation, please enter S:"
-  #echo_info "[ADT_INST] If you want to customize installation, please enter C:"
-  #echo_info "[ADT_INST} If you want to exit current installation, please enter X:"
-  echo_info "There're two ways you can do installation: silent mode or interactive mode. To choose silent mode, which means you opt for the system to override the existing data under the specified installation directories without prompting for your confirmation.  Please be cautious with this selection which may trigger your losing data.  With the interactive mode, you have to closely monitor the installation process, since it will prompt you each step it needs to override some existing data.  To choose silent mode, please enter [S], for interactive mode, please enter [I] or [X] to exit the installation."
-  echo_info "[ADT_INST] Please enter your selections here:"
-  read YOCTOADT_SEL
-  YOCTOADT_SEL=`tr '[a-z]' '[A-Z]'<<<"$YOCTOADT_SEL"`
-  if [ "$YOCTOADT_SEL" == "S" ]; then
-    return "0"
-  elif [ "$YOCTOADT_SEL" == "I" ]; then
-    return "1"
-  elif [ "$YOCTOADT_SEL" == "X" ]; then
-    echo_info "\n############################################################"
-    echo_info "# User cancelled installation!"
-    echo_info "############################################################\n"
-    exit 1
-  fi
-done
-
-
-}
-
-confirm_install()
-{
-# below are prompt, make sure user still want to install even meet
-# some prompts
-
-#User likes to enjoy silent installation, we will not break his
-#installation process here
-if [ "$1" == "0" ]; then
-  return
-fi
-
-while true; do
-  echo_info "[ADT_INST] Do you want to continue installation? Please enter Y/N:"
-  read YOCTOADT_INSTALL
-  YOCTOADT_INSTALL=`tr '[a-z]' '[A-Z]'<<<"$YOCTOADT_INSTALL"`
-  if [ "$YOCTOADT_INSTALL" == "Y" ]; then
-    break
-  elif [ "$YOCTOADT_INSTALL" == "N" ]; then
-    echo_info "\n############################################################"
-    echo_info "# User cancelled installation!"
-    echo_info "############################################################\n"
-    exit 1
-  fi
-done
-}
-
-check_result()
-{
-  result=$?
-  if [ $result -eq 1 ]; then
-    exit -1
-  elif [  $result -ne 0 ]; then
-     echo_info "\n#############################################################################"
-     echo_info "# Meet error(s) when installing Yocto ADT! Please check log file for details. "
-     echo_info "#############################################################################\n"
-    exit -1
-  fi
-}
-
-# yocto adt installation log file
-YOCTOADT_INSTALL_LOG_FILE="adt_installer.log"
-# Temp folders holding qemu/rootfs downloaded images
-# It will be put into the installation folder
-LOCAL_DOWNLOAD="./download_image"
-
-
diff --git a/yocto-poky/meta/recipes-devtools/installer/adt-installer_1.0.bb b/yocto-poky/meta/recipes-devtools/installer/adt-installer_1.0.bb
deleted file mode 100644
index 4c2f097..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/adt-installer_1.0.bb
+++ /dev/null
@@ -1,94 +0,0 @@
-# Yocto ADT Installer bb file
-#
-# Copyright 2010-2012 by Intel Corp.
-#
-# Permission is hereby granted, free of charge, to any person obtaining a copy 
-# of this software and associated documentation files (the "Software"), to deal 
-# in the Software without restriction, including without limitation the rights 
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 
-# copies of the Software, and to permit persons to whom the Software is 
-# furnished to do so, subject to the following conditions:
-
-# The above copyright notice and this permission notice shall be included in 
-# all copies or substantial portions of the Software.
-
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 
-# THE SOFTWARE.
-
-
-SUMMARY = "Application Development Toolkit"
-DESCRIPTION = "Creates the Application Development Toolkit (ADT) installer tarball"
-HOMEPAGE = "http://www.yoctoproject.org/tools-resources/projects/application-development-toolkit-adt"
-LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=4d92cd373abda3937c2bc47fbc49d690 \
-                    file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
-LICENSE = "MIT"
-
-PACKAGES = ""
-INHIBIT_DEFAULT_DEPS = "1"
-
-PR = "r11"
-
-ADT_DEPLOY = "${DEPLOY_DIR}/sdk/"
-ADT_DIR = "${WORKDIR}/adt-installer/"
-S = "${WORKDIR}/opkg-${PV}"
-
-PV = "0.3.0"
-SRC_URI = "http://downloads.yoctoproject.org/releases/opkg/opkg-${PV}.tar.gz \
-           file://wget_cache.patch \
-           file://adt_installer \
-           file://scripts/adt_installer_internal \
-           file://scripts/util \
-           file://scripts/data_define \
-           file://scripts/extract_rootfs \
-           file://adt_installer.conf \
-           file://opkg/conf/opkg-sdk-x86_64.conf \
-           file://opkg/conf/opkg-sdk-i686.conf \
-	  "
-
-SRC_URI[md5sum] = "3412cdc71d78b98facc84b19331ec64e"
-SRC_URI[sha256sum] = "7f735d1cdb8ef3718fb0f9fba44ca0d9a5c90d3a7f014f37a6d2f9474f54988f"
-
-ADTREPO ?= "http://adtrepo.yoctoproject.org/${SDK_VERSION}"
-
-# This recipe makes no sense as a multilib
-MULTILIBS = ""
-
-do_populate_adt[umask] = "022"
-
-fakeroot do_populate_adt () {
-	cd ${WORKDIR}
-	mkdir -p ${ADT_DEPLOY}
-	rm -f ${ADT_DEPLOY}/adt_installer.tar.bz2
-	rm -rf ${ADT_DIR}
-	mkdir -p ${ADT_DIR}/opkg/build
-	cp -r opkg ${ADT_DIR}/
-	sed -i -e 's#ADTREPO_URL#${ADTREPO}#' ${ADT_DIR}/opkg/conf/*.conf
-	cp -r opkg-${PV} ${ADT_DIR}/opkg/build/
-	mv ${ADT_DIR}/opkg/build/opkg-${PV} ${ADT_DIR}/opkg/build/opkg-svn
-	rm -rf ${ADT_DIR}/opkg/build/opkg-svn/patches ${ADT_DIR}/opkg/build/opkg-svn/.pc
-	cp -r scripts ${ADT_DIR}/
-	cp adt_installer ${ADT_DIR}
-	cp adt_installer.conf ${ADT_DIR}
-	sed -i -e 's#ADTREPO#${ADTREPO}#' ${ADT_DIR}/adt_installer.conf
-	echo 'SDK_VENDOR=${SDK_VENDOR}' >> ${ADT_DIR}/scripts/data_define
-	echo 'DEFAULT_INSTALL_FOLDER=${SDKPATH}' >> ${ADT_DIR}/scripts/data_define
-	cp ${COREBASE}/scripts/relocate_sdk.py ${ADT_DIR}/scripts/
-	tar cfj adt_installer.tar.bz2 adt-installer
-	cp ${WORKDIR}/adt_installer.tar.bz2 ${ADT_DEPLOY}
-}
-
-do_configure[noexec] = "1"
-do_compile[noexec] = "1"
-do_package[noexec] = "1"
-do_packagedata[noexec] = "1"
-do_package_write_ipk[noexec] = "1"
-do_package_write_rpm[noexec] = "1"
-do_package_write_deb[noexec] = "1"
-do_poplulate_sysroot[noexec] = "1"
-
-addtask populate_adt before do_build after do_install
diff --git a/yocto-poky/meta/recipes-devtools/installer/files/wget_cache.patch b/yocto-poky/meta/recipes-devtools/installer/files/wget_cache.patch
deleted file mode 100644
index 9117510..0000000
--- a/yocto-poky/meta/recipes-devtools/installer/files/wget_cache.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
----
- libopkg/opkg_download_wget.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/libopkg/opkg_download_wget.c b/libopkg/opkg_download_wget.c
-index 9001493..18ef91e 100644
---- a/libopkg/opkg_download_wget.c
-+++ b/libopkg/opkg_download_wget.c
-@@ -50,6 +50,7 @@ int opkg_download_backend(const char *src, const char *dest,
- 
-     argv[i++] = "wget";
-     argv[i++] = "-q";
-+    argv[i++] = "--no-cache";
-     if (opkg_config->http_proxy || opkg_config->ftp_proxy) {
-         argv[i++] = "-Y";
-         argv[i++] = "on";
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/intltool/intltool.inc b/yocto-poky/meta/recipes-devtools/intltool/intltool.inc
index be77704..eb7ae00 100644
--- a/yocto-poky/meta/recipes-devtools/intltool/intltool.inc
+++ b/yocto-poky/meta/recipes-devtools/intltool/intltool.inc
@@ -4,6 +4,9 @@
 
 URLV="${@'.'.join(d.getVar('PV',1).split('.')[0:2])}"
 SRC_URI = "http://launchpad.net/${BPN}/trunk/${PV}/+download/${BP}.tar.gz"
+
+UPSTREAM_CHECK_URI = "https://launchpad.net/intltool/trunk/"
+
 S = "${WORKDIR}/intltool-${PV}"
 
 DEPENDS = "libxml-parser-perl-native"
diff --git a/yocto-poky/meta/recipes-devtools/json-c/json-c_0.12.bb b/yocto-poky/meta/recipes-devtools/json-c/json-c_0.12.bb
index cfef03d..1a5c394 100644
--- a/yocto-poky/meta/recipes-devtools/json-c/json-c_0.12.bb
+++ b/yocto-poky/meta/recipes-devtools/json-c/json-c_0.12.bb
@@ -11,6 +11,14 @@
 SRC_URI[md5sum] = "3ca4bbb881dfc4017e8021b5e0a8c491"
 SRC_URI[sha256sum] = "000c01b2b3f82dcb4261751eb71f1b084404fb7d6a282f06074d3c17078b9f3f"
 
+UPSTREAM_CHECK_REGEX = "json-c-(?P<pver>\d+(\.\d+)+).tar"
+# json-c releases page is fetching the list of releases in some weird XML format
+# from https://s3.amazonaws.com/json-c_releases and processes it with javascript :-/
+#UPSTREAM_CHECK_URI = "https://s3.amazonaws.com/json-c_releases/releases/index.html"
+RECIPE_UPSTREAM_VERSION = "0.12"
+RECIPE_UPSTREAM_DATE = "Apr 11, 2014"
+CHECK_DATE = "Dec 04, 2015"
+
 RPROVIDES_${PN} = "libjson"
 
 inherit autotools
diff --git a/yocto-poky/meta/recipes-devtools/libtool/libtool-2.4.6.inc b/yocto-poky/meta/recipes-devtools/libtool/libtool-2.4.6.inc
index de06ccb..f307a10 100644
--- a/yocto-poky/meta/recipes-devtools/libtool/libtool-2.4.6.inc
+++ b/yocto-poky/meta/recipes-devtools/libtool/libtool-2.4.6.inc
@@ -35,6 +35,8 @@
 inherit autotools texinfo
 EXTRA_AUTORECONF = "--exclude=libtoolize"
 
+CACHED_CONFIGUREVARS += "ac_cv_path_GREP=grep"
+
 DEPENDS = "libtool-native"
 
 PACKAGES =+ "libltdl"
diff --git a/yocto-poky/meta/recipes-devtools/libtool/libtool-cross_2.4.6.bb b/yocto-poky/meta/recipes-devtools/libtool/libtool-cross_2.4.6.bb
index 8478802..0204d34 100644
--- a/yocto-poky/meta/recipes-devtools/libtool/libtool-cross_2.4.6.bb
+++ b/yocto-poky/meta/recipes-devtools/libtool/libtool-cross_2.4.6.bb
@@ -16,7 +16,11 @@
 do_install () {
 	install -d ${D}${bindir_crossscripts}/
 	install -m 0755 ${HOST_SYS}-libtool ${D}${bindir_crossscripts}/${HOST_SYS}-libtool
-	install -d ${D}${bindir_crossscripts}/
+	sed -e 's@^\(predep_objects="\).*@\1"@' \
+	    -e 's@^\(postdep_objects="\).*@\1"@' \
+	    -i ${D}${bindir_crossscripts}/${HOST_SYS}-libtool
+	sed -i '/^archive_cmds=/s/\-nostdlib//g' ${D}${bindir_crossscripts}/${HOST_SYS}-libtool
+	sed -i '/^archive_expsym_cmds=/s/\-nostdlib//g' ${D}${bindir_crossscripts}/${HOST_SYS}-libtool
 	GREP='/bin/grep' SED='sed' ${S}/build-aux/inline-source libtoolize > ${D}${bindir_crossscripts}/libtoolize
 	chmod 0755 ${D}${bindir_crossscripts}/libtoolize
 	install -d ${D}${target_datadir}/libtool/build-aux/
diff --git a/yocto-poky/meta/recipes-devtools/libtool/libtool_2.4.6.bb b/yocto-poky/meta/recipes-devtools/libtool/libtool_2.4.6.bb
index 45f1b2f..3851ec7 100644
--- a/yocto-poky/meta/recipes-devtools/libtool/libtool_2.4.6.bb
+++ b/yocto-poky/meta/recipes-devtools/libtool/libtool_2.4.6.bb
@@ -10,6 +10,7 @@
 do_install_append () {
         sed -e 's@--sysroot=${STAGING_DIR_HOST}@@g' \
             -e 's@${STAGING_DIR_HOST}@@g' \
+            -e 's@${STAGING_DIR_NATIVE}@@g' \
             -e 's@^\(sys_lib_search_path_spec="\).*@\1${libdir} ${base_libdir}"@' \
             -e 's@^\(compiler_lib_search_dirs="\).*@\1${libdir} ${base_libdir}"@' \
             -e 's@^\(compiler_lib_search_path="\).*@\1${libdir} ${base_libdir}"@' \
diff --git a/yocto-poky/meta/recipes-devtools/m4/m4/make.patch b/yocto-poky/meta/recipes-devtools/m4/m4/make.patch
deleted file mode 100644
index 79fb415..0000000
--- a/yocto-poky/meta/recipes-devtools/m4/m4/make.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-Upstream-Status: Inappropriate [embedded specific]
-
-#
-# Patch managed by http://www.holgerschurig.de/patcher.html
-#
-
---- m4-1.4.2/doc/Makefile.in~make
-+++ m4-1.4.2/doc/Makefile.in
-@@ -57,9 +57,9 @@
- 	date > $(srcdir)/stamp-vti
- 
- install: all
--	$(srcdir)/../mkinstalldirs $(infodir)
-+	$(srcdir)/../mkinstalldirs $(DESTDIR)$(infodir)
- 	cd $(srcdir) && for file in m4.info*; do \
--	  $(INSTALL_DATA) $$file $(infodir)/$$file; \
-+	  $(INSTALL_DATA) $$file $(DESTDIR)$(infodir)/$$file; \
- 	done
- 
- uninstall:
---- m4-1.4.2/src/Makefile.in~make
-+++ m4-1.4.2/src/Makefile.in
-@@ -35,7 +35,7 @@
- prefix = @prefix@
- exec_prefix = @exec_prefix@
- transform = @program_transform_name@
--bindir = $(exec_prefix)/bin
-+bindir = @bindir@
- 
- COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)
- LINK = $(CC) $(LDFLAGS) -o $@
-@@ -84,8 +84,8 @@
- 	$(LINK) ansi2knr.o $(LIBS)
- 
- install: all
--	$(srcdir)/../mkinstalldirs $(bindir)
--	$(INSTALL_PROGRAM) m4 $(bindir)/`echo m4 | sed '$(transform)'`
-+	$(srcdir)/../mkinstalldirs $(DESTDIR)$(bindir)
-+	$(INSTALL_PROGRAM) m4 $(DESTDIR)$(bindir)/`echo m4 | sed '$(transform)'`
- 
- uninstall:
- 	rm -f $(bindir)/`echo m4 | sed '$(transform)'`
diff --git a/yocto-poky/meta/recipes-devtools/make/make-4.1/0001-main.c-main-SV-43434-Handle-NULL-returns-from-ttynam.patch b/yocto-poky/meta/recipes-devtools/make/make-4.1/0001-main.c-main-SV-43434-Handle-NULL-returns-from-ttynam.patch
new file mode 100644
index 0000000..7a5f4ba
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/make/make-4.1/0001-main.c-main-SV-43434-Handle-NULL-returns-from-ttynam.patch
@@ -0,0 +1,63 @@
+From 292da6f6867b75a5af7ddbb639a1feae022f438f Mon Sep 17 00:00:00 2001
+From: Paul Smith <psmith@gnu.org>
+Date: Mon, 20 Oct 2014 01:54:56 -0400
+Subject: [PATCH] * main.c (main): [SV 43434] Handle NULL returns from
+ ttyname().
+
+Upstream-Status: Backport
+
+From: http://git.savannah.gnu.org/cgit/make.git/commit/?id=292da6f6867b75a5af7ddbb639a1feae022f438f
+
+---
+ main.c    | 15 ++++++++++-----
+ makeint.h |  3 ++-
+ 2 files changed, 12 insertions(+), 6 deletions(-)
+
+diff --git a/main.c b/main.c
+index b2d169c..0cdb8a8 100644
+--- a/main.c
++++ b/main.c
+@@ -1429,13 +1429,18 @@ main (int argc, char **argv, char **envp)
+ #ifdef HAVE_ISATTY
+     if (isatty (fileno (stdout)))
+       if (! lookup_variable (STRING_SIZE_TUPLE ("MAKE_TERMOUT")))
+-        define_variable_cname ("MAKE_TERMOUT", TTYNAME (fileno (stdout)),
+-                               o_default, 0)->export = v_export;
+-
++        {
++          const char *tty = TTYNAME (fileno (stdout));
++          define_variable_cname ("MAKE_TERMOUT", tty ? tty : DEFAULT_TTYNAME,
++                                 o_default, 0)->export = v_export;
++        }
+     if (isatty (fileno (stderr)))
+       if (! lookup_variable (STRING_SIZE_TUPLE ("MAKE_TERMERR")))
+-        define_variable_cname ("MAKE_TERMERR", TTYNAME (fileno (stderr)),
+-                               o_default, 0)->export = v_export;
++        {
++          const char *tty = TTYNAME (fileno (stderr));
++          define_variable_cname ("MAKE_TERMERR", tty ? tty : DEFAULT_TTYNAME,
++                                 o_default, 0)->export = v_export;
++        }
+ #endif
+ 
+   /* Reset in case the switches changed our minds.  */
+diff --git a/makeint.h b/makeint.h
+index 6223936..2009f41 100644
+--- a/makeint.h
++++ b/makeint.h
+@@ -436,10 +436,11 @@ extern struct rlimit stack_limit;
+ /* The number of bytes needed to represent the largest integer as a string.  */
+ #define INTSTR_LENGTH         CSTRLEN ("18446744073709551616")
+ 
++#define DEFAULT_TTYNAME "true"
+ #ifdef HAVE_TTYNAME
+ # define TTYNAME(_f) ttyname (_f)
+ #else
+-# define TTYNAME(_f) "true"
++# define TTYNAME(_f) DEFAULT_TTYNAME
+ #endif
+ 
+ 
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/make/make.inc b/yocto-poky/meta/recipes-devtools/make/make.inc
index 57ea605..849b742 100644
--- a/yocto-poky/meta/recipes-devtools/make/make.inc
+++ b/yocto-poky/meta/recipes-devtools/make/make.inc
@@ -8,3 +8,5 @@
 SRC_URI = "${GNU_MIRROR}/make/make-${PV}.tar.bz2"
 
 inherit autotools gettext pkgconfig texinfo
+
+PROVIDES = "virtual/make"
diff --git a/yocto-poky/meta/recipes-devtools/make/make_4.1.bb b/yocto-poky/meta/recipes-devtools/make/make_4.1.bb
index a1b0d7c..78fe0b5 100644
--- a/yocto-poky/meta/recipes-devtools/make/make_4.1.bb
+++ b/yocto-poky/meta/recipes-devtools/make/make_4.1.bb
@@ -4,6 +4,8 @@
                     file://glob/COPYING.LIB;md5=4a770b67e6be0f60da244beb2de0fce4"
 require make.inc
 
+SRC_URI += "file://0001-main.c-main-SV-43434-Handle-NULL-returns-from-ttynam.patch"
+
 EXTRA_OECONF += "--without-guile"
 
 SRC_URI[md5sum] = "57a7a224a822f94789a587ccbcedff69"
diff --git a/yocto-poky/meta/recipes-devtools/mkelfimage/mkelfimage_git.bb b/yocto-poky/meta/recipes-devtools/mkelfimage/mkelfimage_git.bb
index e1c33a6..92435cd 100644
--- a/yocto-poky/meta/recipes-devtools/mkelfimage/mkelfimage_git.bb
+++ b/yocto-poky/meta/recipes-devtools/mkelfimage/mkelfimage_git.bb
@@ -14,8 +14,10 @@
 
 SRC_URI = "git://review.coreboot.org/p/coreboot;protocol=http \
            file://cross-compile.patch   \
-           file://fix-makefile-to-find-libz.patch   \
           "
+SRC_URI_append_class-native = " \
+           file://fix-makefile-to-find-libz.patch   \
+"
 
 CLEANBROKEN = "1"
 
diff --git a/yocto-poky/meta/recipes-devtools/mmc/mmc-utils/0001-mmc.h-don-t-include-asm-generic-int-ll64.h.patch b/yocto-poky/meta/recipes-devtools/mmc/mmc-utils/0001-mmc.h-don-t-include-asm-generic-int-ll64.h.patch
deleted file mode 100644
index 1724de5..0000000
--- a/yocto-poky/meta/recipes-devtools/mmc/mmc-utils/0001-mmc.h-don-t-include-asm-generic-int-ll64.h.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-Upstream-Status: Pending
-
-mmc.h: don't include <asm-generic/int-ll64.h>
-
-Including this file causes a compile failure for qemumips64.
-This file is not needed to be explicitly included, because it will be
-included by the <linux/mmc/ioctl.h> file if _MIPS_SZLONG is not 64.
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- mmc.h |    1 -
- 1 file changed, 1 deletion(-)
-
-diff --git a/mmc.h b/mmc.h
-index 9871d62..3df2cdf 100644
---- a/mmc.h
-+++ b/mmc.h
-@@ -14,7 +14,6 @@
-  * Boston, MA 021110-1307, USA.
-  */
- 
--#include <asm-generic/int-ll64.h>
- #include <linux/mmc/ioctl.h>
- #include <stdio.h>
- 
--- 
-1.7.9.5
-
diff --git a/yocto-poky/meta/recipes-devtools/mmc/mmc-utils_git.bb b/yocto-poky/meta/recipes-devtools/mmc/mmc-utils_git.bb
index 546f7f2..64b8910 100644
--- a/yocto-poky/meta/recipes-devtools/mmc/mmc-utils_git.bb
+++ b/yocto-poky/meta/recipes-devtools/mmc/mmc-utils_git.bb
@@ -1,21 +1,20 @@
-DESCRIPTION = "Userspace tools for MMC/SD devices"
+SUMMARY = "Userspace tools for MMC/SD devices"
 HOMEPAGE = "http://git.kernel.org/cgit/linux/kernel/git/cjb/mmc-utils.git/"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://mmc.c;beginline=1;endline=17;md5=d7747fc87f1eb22b946ef819969503f0"
 
 SRCBRANCH ?= "master"
-SRCREV = "f4eb241519f8d500ce6068a70d2389be39ac5189"
+SRCREV = "44f94b925894577f9ffcf2c418dd013a5e582648"
 
 PV = "0.1"
 
-SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc-utils.git;branch=${SRCBRANCH} \
-           file://0001-mmc.h-don-t-include-asm-generic-int-ll64.h.patch"
+SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc-utils.git;branch=${SRCBRANCH}"
 
 S = "${WORKDIR}/git"
 
-do_configure_prepend() {
-    sed -i "s:-Werror::g" ${S}/Makefile
-}
+CFLAGS_append_powerpc64 = " -D__SANE_USERSPACE_TYPES__"
+CFLAGS_append_mips64 = " -D__SANE_USERSPACE_TYPES__"
+CFLAGS_append_mips64n32 = " -D__SANE_USERSPACE_TYPES__"
 
 do_install() {
     install -d ${D}${bindir}
diff --git a/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-Fix-build-with-musl.patch b/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-Fix-build-with-musl.patch
new file mode 100644
index 0000000..305be52
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-Fix-build-with-musl.patch
@@ -0,0 +1,29 @@
+From e16fa28bc57c29923ab60af2ac343da83e1992d8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 6 Oct 2015 23:51:34 +0000
+Subject: [PATCH] Fix build with musl
+
+Upstream-Status: Pending
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ mkfs.jffs2.c  | 44 ++++++++++++++++++++++++++++++++++++++++++--
+ recv_image.c  |  1 -
+ serve_image.c |  1 -
+ 3 files changed, 42 insertions(+), 4 deletions(-)
+
+diff --git a/mkfs.jffs2.c b/mkfs.jffs2.c
+index f09c0b2..ed2dc43 100644
+--- a/mkfs.jffs2.c
++++ b/mkfs.jffs2.c
+@@ -72,6 +72,7 @@
+ #include <byteswap.h>
+ #include <crc32.h>
+ #include <inttypes.h>
++#include <limits.h>
+ 
+ #include "rbtree.h"
+ #include "common.h"
+-- 
+2.6.1
+
diff --git a/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch b/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch
deleted file mode 100644
index 2d36158..0000000
--- a/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From b856ff35c20124ceae40bbc4d32584df47618c96 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 25 Feb 2015 09:28:26 +0000
-Subject: [PATCH] hashtable: Remove duplicate hashtable_iterator_value/hashtable_iterator_key
-
-gcc5 is defaulting to gnu11 instead of gnu89 like previous versions
-as a result the semantics of 'extern inline' changes where in gnu89 for 'extern inline' no external
-visible function is generated,in c99 'external inline' generates externally visible function
-there is no equivalent in c99+ because redefinitions arent allowed
-but 'static inline' remains same for for c89 and c99+, thats why we change the semantics
-so we make the functions static inline, and achieve the same effect
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: pending
-
----
- mkfs.ubifs/hashtable/hashtable_itr.c | 12 ------------
- 1 file changed, 12 deletions(-)
-
-Index: git/mkfs.ubifs/hashtable/hashtable_itr.h
-===================================================================
---- git.orig/mkfs.ubifs/hashtable/hashtable_itr.h
-+++ git/mkfs.ubifs/hashtable/hashtable_itr.h
-@@ -28,7 +28,7 @@ hashtable_iterator(struct hashtable *h);
- /* hashtable_iterator_key
-  * - return the value of the (key,value) pair at the current position */
- 
--extern inline void *
-+static inline void *
- hashtable_iterator_key(struct hashtable_itr *i)
- {
-     return i->e->k;
-@@ -37,7 +37,7 @@ hashtable_iterator_key(struct hashtable_
- /*****************************************************************************/
- /* value - return the value of the (key,value) pair at the current position */
- 
--extern inline void *
-+static inline void *
- hashtable_iterator_value(struct hashtable_itr *i)
- {
-     return i->e->v;
-Index: git/mkfs.ubifs/hashtable/hashtable_itr.c
-===================================================================
---- git.orig/mkfs.ubifs/hashtable/hashtable_itr.c
-+++ git/mkfs.ubifs/hashtable/hashtable_itr.c
-@@ -35,18 +35,6 @@ hashtable_iterator(struct hashtable *h)
- }
- 
- /*****************************************************************************/
--/* key      - return the key of the (key,value) pair at the current position */
--/* value    - return the value of the (key,value) pair at the current position */
--
--void *
--hashtable_iterator_key(struct hashtable_itr *i)
--{ return i->e->k; }
--
--void *
--hashtable_iterator_value(struct hashtable_itr *i)
--{ return i->e->v; }
--
--/*****************************************************************************/
- /* advance - advance the iterator to the next element
-  *           returns zero if advanced to end of table */
- 
diff --git a/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/010-fix-rpmatch.patch b/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/010-fix-rpmatch.patch
new file mode 100644
index 0000000..7d783e7
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/mtd/mtd-utils/010-fix-rpmatch.patch
@@ -0,0 +1,24 @@
+Replace rpmatch() usage with checking first character of line
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+--- a/include/common.h
++++ b/include/common.h
+@@ -122,10 +122,12 @@
+ 		}
+ 
+ 		if (strcmp("\n", line) != 0) {
+-			switch (rpmatch(line)) {
+-			case 0: ret = false; break;
+-			case 1: ret = true; break;
+-			case -1:
++			switch (line[0]) {
++			case 'N':
++			case 'n': ret = false; break;
++			case 'Y':
++			case 'y': ret = true; break;
++			default:
+ 				puts("unknown response; please try again");
+ 				continue;
+ 			}
diff --git a/yocto-poky/meta/recipes-devtools/mtd/mtd-utils_git.bb b/yocto-poky/meta/recipes-devtools/mtd/mtd-utils_git.bb
index 17dca77..cd9ae06 100644
--- a/yocto-poky/meta/recipes-devtools/mtd/mtd-utils_git.bb
+++ b/yocto-poky/meta/recipes-devtools/mtd/mtd-utils_git.bb
@@ -7,16 +7,18 @@
 
 DEPENDS = "zlib lzo e2fsprogs util-linux"
 
-PV = "1.5.1+git${SRCPV}"
+PV = "1.5.2"
 
-SRCREV = "9f107132a6a073cce37434ca9cda6917dd8d866b"
+SRCREV = "aea36417067dade75192bafa03af70b6eb2677b1"
 SRC_URI = "git://git.infradead.org/mtd-utils.git \
            file://add-exclusion-to-mkfs-jffs2-git-2.patch \
            file://fix-armv7-neon-alignment.patch \
-           file://0001-hashtable-Remove-duplicate-hashtable_iterator_value-.patch \
            file://mtd-utils-fix-corrupt-cleanmarker-with-flash_erase--j-command.patch \
+           file://0001-Fix-build-with-musl.patch \
 "
 
+SRC_URI_append_libc-musl = " file://010-fix-rpmatch.patch "
+
 S = "${WORKDIR}/git/"
 
 # xattr support creates an additional compile-time dependency on acl because
diff --git a/yocto-poky/meta/recipes-devtools/mtools/mtools_3.9.9.bb b/yocto-poky/meta/recipes-devtools/mtools/mtools_3.9.9.bb
index c284a71..3423917 100644
--- a/yocto-poky/meta/recipes-devtools/mtools/mtools_3.9.9.bb
+++ b/yocto-poky/meta/recipes-devtools/mtools/mtools_3.9.9.bb
@@ -1,16 +1,15 @@
-# mtools OE build file
-# Copyright (C) 2004-2006, Advanced Micro Devices, Inc.  All Rights Reserved
-# Released under the MIT license (see packages/COPYING)
-
 SUMMARY = "Utilities to access MS-DOS disks without mounting them"
-DESCRIPTION = "Mtools is a collection of utilities for accessing MS-DOS disks from Unix without mounting them."
+DESCRIPTION = "Mtools is a collection of utilities to access MS-DOS disks from GNU and Unix without mounting them."
 HOMEPAGE = "http://www.gnu.org/software/mtools/"
+SECTION = "optional"
 LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=92b58ec77696788ce278b044d2a8e9d3"
 PR = "r6"
 
-RDEPENDS_${PN} = "glibc-gconv-ibm850"
-RRECOMMENDS_${PN} = "\
+DEPENDS += "virtual/libiconv"
+
+RDEPENDS_${PN}_libc-glibc = "glibc-gconv-ibm850"
+RRECOMMENDS_${PN}_libc-glibc = "\
 	glibc-gconv-ibm437 \
 	glibc-gconv-ibm737 \
 	glibc-gconv-ibm775 \
@@ -26,24 +25,22 @@
 	glibc-gconv-ibm866 \
 	glibc-gconv-ibm869 \
 	"
-
-#http://mtools.linux.lu/mtools-${PV}.tar.gz 
-SRC_URI = "http://downloads.yoctoproject.org/mirror/sources/mtools-${PV}.tar.gz \
-	file://mtools-makeinfo.patch \
-	file://mtools.patch \
-	file://no-x11.patch \
-	file://fix-broken-lz.patch \
-"
-
 SRC_URI[md5sum] = "3e68b857b4e1f3a6521d1dfefbd30a36"
 SRC_URI[sha256sum] = "af083a73425d664d4607ef6c6564fd9319a0e47ee7c105259a45356cb834690e"
 
-S = "${WORKDIR}/mtools-${PV}"
+#http://mtools.linux.lu/mtools-${PV}.tar.gz 
+SRC_URI = "http://downloads.yoctoproject.org/mirror/sources/mtools-${PV}.tar.gz \
+           file://mtools-makeinfo.patch \
+           file://mtools.patch \
+           file://no-x11.patch \
+           file://fix-broken-lz.patch"
 
 inherit autotools texinfo
 
 EXTRA_OECONF = "--without-x"
 
+LDFLAGS_append_libc-uclibc = " -liconv "
+
 BBCLASSEXTEND = "native nativesdk"
 
 PACKAGECONFIG ??= ""
diff --git a/yocto-poky/meta/recipes-devtools/mtools/mtools_4.0.18.bb b/yocto-poky/meta/recipes-devtools/mtools/mtools_4.0.18.bb
index 24c9d49..efde547 100644
--- a/yocto-poky/meta/recipes-devtools/mtools/mtools_4.0.18.bb
+++ b/yocto-poky/meta/recipes-devtools/mtools/mtools_4.0.18.bb
@@ -5,9 +5,10 @@
 LICENSE = "GPLv3"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
 
+DEPENDS += "virtual/libiconv"
 
-RDEPENDS_${PN} = "glibc-gconv-ibm850"
-RRECOMMENDS_${PN} = "\
+RDEPENDS_${PN}_libc-glibc = "glibc-gconv-ibm850"
+RRECOMMENDS_${PN}_libc-glibc = "\
 	glibc-gconv-ibm437 \
 	glibc-gconv-ibm737 \
 	glibc-gconv-ibm775 \
@@ -35,6 +36,8 @@
 
 EXTRA_OECONF = "--without-x"
 
+LDFLAGS_append_libc-uclibc = " -liconv "
+
 BBCLASSEXTEND = "native nativesdk"
 
 PACKAGECONFIG ??= ""
@@ -45,8 +48,3 @@
     mkdir -p ${D}/${bindir}
     mkdir -p ${D}/${datadir}
 }
-
-do_install_append_class-native () {
-    create_wrapper ${D}${bindir}/mcopy \
-        GCONV_PATH=${libdir}/gconv
-}
diff --git a/yocto-poky/meta/recipes-devtools/openjade/openjade-1.3.2/no-libtool.patch b/yocto-poky/meta/recipes-devtools/openjade/openjade-1.3.2/no-libtool.patch
new file mode 100644
index 0000000..2f57c00
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/openjade/openjade-1.3.2/no-libtool.patch
@@ -0,0 +1,20 @@
+The openjade build is fairly unique in auto-generating explicit dependencies to
+installed .la files.  As some distributions may delete these files unless
+clearly required, change the Makefile fragment to depend on the .so instead.
+
+Patch originally by Phil Blundell <philb@brightsign.biz>.
+
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+Upstream-Status: Inappropriate
+
+--- openjade-1.3.2/Makefile.prog.in~	2013-05-14 11:42:02.646782318 +0100
++++ openjade-1.3.2/Makefile.prog.in	2013-05-14 11:54:55.051728343 +0100
+@@ -12,7 +12,7 @@
+ 
+ ALL_LIBS = $(XLIBS) $(LIBS)
+ Makefile.lt:
+-	echo 'LT_LIBS='`echo $(ALL_LIBS) | sed 's/\.a\s/\.la /g' | sed s/\.a$$/\.la/` > Makefile.lt
++	echo 'LT_LIBS='`for d in $(ALL_LIBS); do case $$d in ../*) echo $$d | sed s/\.a$$/.la/g ;; *) echo $$d | sed s/\.a$$/.so/g ;; esac ; done` >Makefile.lt
+ 
+ PROG:=$(shell echo "$(PROG)" | sed '@program_transform_name@')
+ 
diff --git a/yocto-poky/meta/recipes-devtools/openjade/openjade-native_1.3.2.bb b/yocto-poky/meta/recipes-devtools/openjade/openjade-native_1.3.2.bb
index fa7aa62..bc25008 100644
--- a/yocto-poky/meta/recipes-devtools/openjade/openjade-native_1.3.2.bb
+++ b/yocto-poky/meta/recipes-devtools/openjade/openjade-native_1.3.2.bb
@@ -17,13 +17,20 @@
            file://msggen.pl.patch \
            file://reautoconf.patch \
 	   file://user-declared-default-constructor.patch \
-           file://fix-regex.patch"
+           file://fix-regex.patch \
+	   file://no-libtool.patch"
 
 SRC_URI[md5sum] = "7df692e3186109cc00db6825b777201e"
 SRC_URI[sha256sum] = "1d2d7996cc94f9b87d0c51cf0e028070ac177c4123ecbfd7ac1cb8d0b7d322d1"
 
+UPSTREAM_CHECK_URI = "http://openjade.sourceforge.net/download.html"
+
 inherit autotools-brokensep native
 
+# Statically link local libs to avoid gold link issue [YOCTO #2972]
+PACKAGECONFIG ?= "static-only-libs"
+PACKAGECONFIG[static-only-libs] = "--enable-static --disable-shared,--enable-static --enable-shared,,"
+
 EXTRA_OECONF = "--enable-spincludedir=${STAGING_INCDIR}/OpenSP \
                 --enable-splibdir=${STAGING_LIBDIR}"
 
@@ -57,14 +64,20 @@
 do_install() {
 	# Refer to http://www.linuxfromscratch.org/blfs/view/stable/pst/openjade.html
 	# for details.
-	install -d ${D}${bindir}	
-	install -m 0755 ${S}/jade/.libs/openjade ${D}${bindir}/openjade
+	install -d ${D}${bindir} ${D}${libdir}
+	if ${@bb.utils.contains('PACKAGECONFIG', 'static-only-libs', 'true', 'false', d)}; then
+		install -m 0755 jade/openjade ${D}${bindir}/openjade
+		oe_libinstall -a -C style libostyle ${D}${libdir}
+		oe_libinstall -a -C spgrove libospgrove ${D}${libdir}
+		oe_libinstall -a -C grove libogrove ${D}${libdir}
+	else
+		install -m 0755 jade/.libs/openjade ${D}${bindir}/openjade
+		oe_libinstall -a -so -C style libostyle ${D}${libdir}
+		oe_libinstall -a -so -C spgrove libospgrove ${D}${libdir}
+		oe_libinstall -a -so -C grove libogrove ${D}${libdir}
+	fi
 	ln -sf openjade ${D}${bindir}/jade
 
-	oe_libinstall -a -so -C style libostyle ${D}${libdir}
-	oe_libinstall -a -so -C spgrove libospgrove ${D}${libdir}
-	oe_libinstall -a -so -C grove libogrove ${D}${libdir}
-
 	install -d ${D}${datadir}/sgml/openjade-${PV}
 	install -m 644 dsssl/catalog ${D}${datadir}/sgml/openjade-${PV}
 	install -m 644 dsssl/*.dtd ${D}${datadir}/sgml/openjade-${PV}
diff --git a/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils/0001-opkg-build-re-do-find-ls-code-to-not-fail-on-filenam.patch b/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils/0001-opkg-build-re-do-find-ls-code-to-not-fail-on-filenam.patch
new file mode 100644
index 0000000..5cbb55a
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils/0001-opkg-build-re-do-find-ls-code-to-not-fail-on-filenam.patch
@@ -0,0 +1,56 @@
+From 8e424296ce2af4a5a7392c38a31f8723f9b9fbda Mon Sep 17 00:00:00 2001
+From: Denys Dmytriyenko <denys@ti.com>
+Date: Thu, 7 Apr 2016 20:43:13 -0400
+Subject: [PATCH] opkg-build: re-do find/ls code to not fail on filenames with
+ spaces
+
+Signed-off-by: Denys Dmytriyenko <denys@ti.com>
+---
+ opkg-build | 9 ++++-----
+ 1 file changed, 4 insertions(+), 5 deletions(-)
+
+diff --git a/opkg-build b/opkg-build
+index a9ccad2..07305b2 100755
+--- a/opkg-build
++++ b/opkg-build
+@@ -6,7 +6,6 @@
+ # 2003-04-25 rea@sr.unh.edu
+ #   Updated to work on Familiar Pre0.7rc1, with busybox tar.
+ #   Note it Requires: binutils-ar (since the busybox ar can't create)
+-#   For UID debugging it needs a better "find".
+ set -e
+ 
+ version=1.0
+@@ -47,12 +46,12 @@ pkg_appears_sane() {
+ 
+ 	PKG_ERROR=0
+ 
+-	tilde_files=`find . -name '*~'`
++	tilde_files=`find . -name '*~' -ls -printf '\\\n'`
+ 	if [ -n "$tilde_files" ]; then
+ 	    if [ "$noclean" = "1" ]; then
+ 		echo "*** Warning: The following files have names ending in '~'.
+ You probably want to remove them: " >&2
+-		ls -ld $tilde_files
++		echo -e $tilde_files
+ 		if [ $? -ne 0 ]; then
+ 			echo "*** Error: Fail to list files have names ending in '~'."
+ 			exit 1
+@@ -64,12 +63,12 @@ You probably want to remove them: " >&2
+ 	    fi
+ 	fi
+ 
+-	large_uid_files=`find . -uid +99 || true`
++	large_uid_files=`find . -uid +99 -ls -printf '\\\n' || true`
+ 
+ 	if [ "$ogargs" = "" ]  && [ -n "$large_uid_files" ]; then
+ 		echo "*** Warning: The following files have a UID greater than 99.
+ You probably want to chown these to a system user: " >&2
+-		ls -ld $large_uid_files
++		echo -e $large_uid_files
+ 		if [ $? -ne 0 ]; then
+ 			echo "*** Error: Fail to list files have a UID greater than 99."
+ 			exit 1
+-- 
+2.2.0
+
diff --git a/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils/opkg-build-Exit-when-fail-to-list-files.patch b/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils/opkg-build-Exit-when-fail-to-list-files.patch
new file mode 100644
index 0000000..6c66902
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils/opkg-build-Exit-when-fail-to-list-files.patch
@@ -0,0 +1,45 @@
+We have an issue when ls segfaults in some cases [1] so it's
+better to detect the failure at this level instead of continue
+the build process.
+
+[YOCTO #8926]
+
+Upstream-Status: Submitted [2]
+
+[1] https://bugzilla.yoctoproject.org/show_bug.cgi?id=8926#c0
+[2] https://groups.google.com/forum/#!topic/opkg-devel/cmX02bgHZms
+
+Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
+---
+ opkg-build | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/opkg-build b/opkg-build
+index 98008b6..a9ccad2 100755
+--- a/opkg-build
++++ b/opkg-build
+@@ -53,6 +53,10 @@ pkg_appears_sane() {
+ 		echo "*** Warning: The following files have names ending in '~'.
+ You probably want to remove them: " >&2
+ 		ls -ld $tilde_files
++		if [ $? -ne 0 ]; then
++			echo "*** Error: Fail to list files have names ending in '~'."
++			exit 1
++		fi
+ 		echo >&2
+ 	    else
+ 		echo "*** Removing the following files: $tilde_files"
+@@ -66,6 +70,10 @@ You probably want to remove them: " >&2
+ 		echo "*** Warning: The following files have a UID greater than 99.
+ You probably want to chown these to a system user: " >&2
+ 		ls -ld $large_uid_files
++		if [ $? -ne 0 ]; then
++			echo "*** Error: Fail to list files have a UID greater than 99."
++			exit 1
++		fi
+ 		echo >&2
+ 	fi
+ 	    
+-- 
+2.1.4
+
diff --git a/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils_git.bb b/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils_git.bb
index 5f518d2..8873b28 100644
--- a/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils_git.bb
+++ b/yocto-poky/meta/recipes-devtools/opkg-utils/opkg-utils_git.bb
@@ -5,13 +5,14 @@
 LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
                     file://opkg.py;beginline=1;endline=18;md5=15917491ad6bf7acc666ca5f7cc1e083"
-PROVIDES += "virtual/update-alternatives"
+PROVIDES += "${@bb.utils.contains('PACKAGECONFIG', 'update-alternatives', 'virtual/update-alternatives', '', d)}"
 
 SRCREV = "53274f087565fd45d8452c5367997ba6a682a37a"
 PV = "0.1.8+git${SRCPV}"
 
-SRC_URI = "git://git.yoctoproject.org/opkg-utils"
-
+SRC_URI = "git://git.yoctoproject.org/opkg-utils \
+           file://opkg-build-Exit-when-fail-to-list-files.patch \
+           file://0001-opkg-build-re-do-find-ls-code-to-not-fail-on-filenam.patch"
 SRC_URI_append_class-native = " file://tar_ignore_error.patch"
 
 S = "${WORKDIR}/git"
@@ -21,15 +22,21 @@
 PYTHONRDEPS = "python python-shell python-io python-math python-crypt python-logging python-fcntl python-subprocess python-pickle python-compression python-textutils python-stringold"
 PYTHONRDEPS_class-native = ""
 
-PACKAGECONFIG = "python"
+PACKAGECONFIG = "python update-alternatives"
 PACKAGECONFIG[python] = ",,,${PYTHONRDEPS}"
+PACKAGECONFIG[update-alternatives] = ",,,"
 
 do_install() {
 	oe_runmake PREFIX=${prefix} DESTDIR=${D} install
+	if ! ${@bb.utils.contains('PACKAGECONFIG', 'update-alternatives', 'true', 'false', d)}; then
+		rm -f "${D}${bindir}/update-alternatives"
+	fi
 }
 
 do_install_append_class-target() {
-	sed -i ${D}${bindir}/update-alternatives -e 's,/usr/bin,${bindir},g; s,/usr/lib,${libdir},g'
+	if [ -e "${D}${bindir}/update-alternatives" ]; then
+		sed -i ${D}${bindir}/update-alternatives -e 's,/usr/bin,${bindir},g; s,/usr/lib,${nonarch_libdir},g'
+	fi
 }
 
 PACKAGES =+ "update-alternatives-opkg"
diff --git a/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-configure.ac-use-pkg-config-for-libsolv.patch b/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-configure.ac-use-pkg-config-for-libsolv.patch
new file mode 100644
index 0000000..e67ec74
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-configure.ac-use-pkg-config-for-libsolv.patch
@@ -0,0 +1,36 @@
+From 2a43027f7ecf2bb3ce73f95bcf575c56bc495d07 Mon Sep 17 00:00:00 2001
+From: Alejandro del Castillo <alejandro.delcastillo@ni.com>
+Date: Wed, 9 Dec 2015 17:38:05 -0600
+Subject: [PATCH] configure.ac: use pkg-config for libsolv
+
+Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
+---
+ configure.ac | 12 +-----------
+ 1 file changed, 1 insertion(+), 11 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 52e1025..d17dc5c 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -159,17 +159,7 @@ if test "x$want_solver" != "xno"; then
+                  AC_MSG_ERROR(Specify which solver with --enable-solver=<SOLVER>)],
+             [libsolv],
+                 [AC_MSG_RESULT(libsolv)
+-
+-                SOLVER_CFLAGS="-I/usr/local/include/"
+-                SOLVER_LIBS="-lsolv -lsolvext"
+-                AC_CHECK_LIB([solv],
+-                             [solver_solve],
+-                             [],
+-                             [AC_MSG_ERROR(libsolv not found)])
+-                dnl TODO: remove previous 6 lines and uncomment line below to use
+-                dnl pkg-config once there is a release of libsolv with pkg-config:
+-                dnl PKG_CHECK_MODULES(SOLVER, libsolv)
+-
++                PKG_CHECK_MODULES(SOLVER, libsolv)
+                 AC_DEFINE(HAVE_SOLVER_LIBSOLV,1,[Define if you want to use libsolv])],
+             # default
+             [AC_MSG_RESULT(no)
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-libopkg-include-stdio.h-for-getting-FILE-defined.patch b/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-libopkg-include-stdio.h-for-getting-FILE-defined.patch
deleted file mode 100644
index acc1338..0000000
--- a/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-libopkg-include-stdio.h-for-getting-FILE-defined.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From 58f4d3d63cd6097154205ea7ee042005036659b3 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Thu, 10 Sep 2015 21:43:32 -0700
-Subject: [PATCH] libopkg: include stdio.h for getting FILE defined
-To: opkg-devel@googlegroups.com
-Cc: paul@paulbarker.me.uk
-
-For some libc(musl) stdio.h may not get included indirectly which means
-we need to mention it in explicit include list
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Submitted
-
- libopkg/opkg_verify.c | 1 +
- libopkg/pkg_src.c     | 1 +
- 2 files changed, 2 insertions(+)
-
-diff --git a/libopkg/opkg_verify.c b/libopkg/opkg_verify.c
-index 41dc3f4..a71591d 100644
---- a/libopkg/opkg_verify.c
-+++ b/libopkg/opkg_verify.c
-@@ -18,6 +18,7 @@
- 
- #include <malloc.h>
- #include <string.h>
-+#include <stdio.h>
- 
- #include "file_util.h"
- #include "opkg_conf.h"
-diff --git a/libopkg/pkg_src.c b/libopkg/pkg_src.c
-index e31ec21..6b49a00 100644
---- a/libopkg/pkg_src.c
-+++ b/libopkg/pkg_src.c
-@@ -20,6 +20,7 @@
- 
- #include <malloc.h>
- #include <unistd.h>
-+#include <stdio.h>
- 
- #include "file_util.h"
- #include "opkg_conf.h"
--- 
-2.5.1
-
diff --git a/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-libsolv_solver_set_arch_policy-use-correct-logic-dur.patch b/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-libsolv_solver_set_arch_policy-use-correct-logic-dur.patch
new file mode 100644
index 0000000..1ab1790
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-libsolv_solver_set_arch_policy-use-correct-logic-dur.patch
@@ -0,0 +1,35 @@
+From 3e562bed7dced25eb3e9174ca9395324b6c873c1 Mon Sep 17 00:00:00 2001
+From: Alejandro del Castillo <alejandro.delcastillo@ni.com>
+Date: Wed, 9 Dec 2015 13:36:14 -0600
+Subject: [PATCH] libsolv_solver_set_arch_policy: use correct logic during
+ archs resizing
+
+If there are more than INITIAL_ARCH_LIST_SIZE archs defined in the
+configuration, libsolv_solver_set_arch_policy crashes due to flawed
+logic when resizing the archs array.
+
+Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
+---
+ libopkg/opkg_solver_libsolv.c | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/libopkg/opkg_solver_libsolv.c b/libopkg/opkg_solver_libsolv.c
+index 1cdcf1f..b5af0fa 100644
+--- a/libopkg/opkg_solver_libsolv.c
++++ b/libopkg/opkg_solver_libsolv.c
+@@ -66,8 +66,10 @@ static void libsolv_solver_set_arch_policy(libsolv_solver_t *libsolv_solver)
+     nv_pair_list_elt_t *arch_info;
+ 
+     list_for_each_entry(arch_info, &opkg_config->arch_list.head, node) {
+-        if (arch_count > arch_list_size)
+-            archs = xrealloc(archs, arch_list_size *= 2);
++        if (arch_count >= arch_list_size) {
++            arch_list_size *= 2;
++            archs = xrealloc(archs, arch_list_size * sizeof(arch_data_t));
++        }
+ 
+         archs[arch_count].arch = ((nv_pair_t *)(arch_info->data))->name;
+         archs[arch_count].priority = atoi(((nv_pair_t *)
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-opkg_archive-add-support-for-empty-compressed-files.patch b/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-opkg_archive-add-support-for-empty-compressed-files.patch
deleted file mode 100644
index dabd196..0000000
--- a/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-opkg_archive-add-support-for-empty-compressed-files.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From bd32bb8646459508bb0b0ce54a14bd6fe0e19b75 Mon Sep 17 00:00:00 2001
-From: Alejandro del Castillo <alejandro.delcastillo@ni.com>
-Date: Thu, 27 Aug 2015 15:52:16 -0500
-Subject: [PATCH] opkg_archive: add support for empty compressed files
-
-Regression from 0.2.x: opkg used to support empty Package.gz files.
-
-Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
-
-Upstream-Status: Accepted
----
- libopkg/opkg_archive.c | 15 +++++++++++++--
- 1 file changed, 13 insertions(+), 2 deletions(-)
-
-diff --git a/libopkg/opkg_archive.c b/libopkg/opkg_archive.c
-index be903e4..7e91e48 100644
---- a/libopkg/opkg_archive.c
-+++ b/libopkg/opkg_archive.c
-@@ -121,6 +121,9 @@ static int copy_to_stream(struct archive *a, FILE * stream)
-     int eof;
-     size_t len = EXTRACT_BUFFER_LEN;
- 
-+    if (archive_format(a) == ARCHIVE_FORMAT_EMPTY)
-+        return 0;
-+
-     buffer = xmalloc(len);
- 
-     while (1) {
-@@ -654,6 +657,13 @@ static struct archive *open_compressed_file(const char *filename)
-         goto err_cleanup;
-     }
- 
-+    r = archive_read_support_format_empty(ar);
-+    if (r != ARCHIVE_OK) {
-+        opkg_msg(ERROR, "Empty format not supported: %s\n",
-+                 archive_error_string(ar));
-+        goto err_cleanup;
-+    }
-+
-     /* Open input file and prepare for reading. */
-     r = archive_read_open_filename(ar, filename, EXTRACT_BUFFER_LEN);
-     if (r != ARCHIVE_OK) {
-@@ -723,6 +733,7 @@ struct opkg_ar *ar_open_compressed_file(const char *filename)
- {
-     struct opkg_ar *ar;
-     struct archive_entry *entry;
-+    int eof;
- 
-     ar = (struct opkg_ar *)xmalloc(sizeof(struct opkg_ar));
- 
-@@ -737,8 +748,8 @@ struct opkg_ar *ar_open_compressed_file(const char *filename)
-      * header. We skip over this header here so that the caller doesn't need
-      * to know about it.
-      */
--    entry = read_header(ar->ar, NULL);
--    if (!entry)
-+    entry = read_header(ar->ar, &eof);
-+    if (!entry && !eof)
-         goto err_cleanup;
- 
-     return ar;
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-string_util-New-file-with-bin_to_hex-function.patch b/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-string_util-New-file-with-bin_to_hex-function.patch
deleted file mode 100644
index fb3ac46..0000000
--- a/yocto-poky/meta/recipes-devtools/opkg/opkg/0001-string_util-New-file-with-bin_to_hex-function.patch
+++ /dev/null
@@ -1,122 +0,0 @@
-From 646b80024567a6245c598be3374653fa1fa09a12 Mon Sep 17 00:00:00 2001
-From: Paul Barker <paul@paulbarker.me.uk>
-Date: Sat, 7 Nov 2015 10:23:49 +0000
-Subject: [PATCH 1/4] string_util: New file with bin_to_hex function
-
-This function does very simple conversion from binary data to a hex string.
-
-Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
-Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
-
-Upstream-Status: Accepted
----
- libopkg/Makefile.am   |  4 ++--
- libopkg/string_util.c | 42 ++++++++++++++++++++++++++++++++++++++++++
- libopkg/string_util.h | 24 ++++++++++++++++++++++++
- 3 files changed, 68 insertions(+), 2 deletions(-)
- create mode 100644 libopkg/string_util.c
- create mode 100644 libopkg/string_util.h
-
-diff --git a/libopkg/Makefile.am b/libopkg/Makefile.am
-index ee3fbee..3e62c24 100644
---- a/libopkg/Makefile.am
-+++ b/libopkg/Makefile.am
-@@ -13,7 +13,7 @@ opkg_headers = active_list.h cksum_list.h conffile.h conffile_list.h \
- 	pkg_depends.h pkg_dest.h pkg_dest_list.h pkg_extract.h pkg_hash.h \
- 	pkg_parse.h pkg_src.h pkg_src_list.h pkg_vec.h release.h \
- 	release_parse.h sha256.h sprintf_alloc.h str_list.h void_list.h \
--	xregex.h xsystem.h xfuncs.h opkg_verify.h
-+	xregex.h xsystem.h xfuncs.h opkg_verify.h string_util.h
- 
- opkg_sources = opkg_cmd.c opkg_configure.c opkg_download.c \
- 	opkg_install.c opkg_remove.c opkg_conf.c release.c \
-@@ -23,7 +23,7 @@ opkg_sources = opkg_cmd.c opkg_configure.c opkg_download.c \
- 	pkg_src.c pkg_src_list.c str_list.c void_list.c active_list.c \
- 	file_util.c opkg_message.c md5.c parse_util.c cksum_list.c \
- 	sprintf_alloc.c xregex.c xsystem.c xfuncs.c opkg_archive.c \
--	opkg_verify.c
-+	opkg_verify.c string_util.c
- 
- if HAVE_CURL
- opkg_sources += opkg_download_curl.c
-diff --git a/libopkg/string_util.c b/libopkg/string_util.c
-new file mode 100644
-index 0000000..822cab6
---- /dev/null
-+++ b/libopkg/string_util.c
-@@ -0,0 +1,42 @@
-+/* vi: set expandtab sw=4 sts=4: */
-+/* string_util.c - convenience routines for common string operations
-+
-+   Copyright (C) 2015 Paul Barker
-+
-+   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, 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.
-+*/
-+
-+#include "config.h"
-+
-+#include "string_util.h"
-+#include "xfuncs.h"
-+
-+char *bin_to_hex(const void *bin_data, size_t len)
-+{
-+    const unsigned char *src = (const unsigned char *)bin_data;
-+    char *buf = xmalloc(2 * len + 1);
-+    int i;
-+
-+    static const unsigned char bin2hex[16] = {
-+        '0', '1', '2', '3',
-+        '4', '5', '6', '7',
-+        '8', '9', 'a', 'b',
-+        'c', 'd', 'e', 'f'
-+    };
-+
-+    for (i = 0; i < len; i++) {
-+        buf[i * 2] = bin2hex[src[i] >> 4];
-+        buf[i * 2 + 1] = bin2hex[src[i] & 0xf];
-+    }
-+
-+    buf[len * 2] = '\0';
-+    return buf;
-+}
-diff --git a/libopkg/string_util.h b/libopkg/string_util.h
-new file mode 100644
-index 0000000..a920e2a
---- /dev/null
-+++ b/libopkg/string_util.h
-@@ -0,0 +1,24 @@
-+/* vi: set expandtab sw=4 sts=4: */
-+/* string_util.h - convenience routines for common file operations
-+
-+   Copyright (C) 2015 Paul Barker
-+
-+   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, 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.
-+*/
-+
-+#ifndef STRING_UTIL_H
-+#define STRING_UTIL_H
-+
-+#include <stddef.h>
-+
-+char *bin_to_hex(const void *bin_data, size_t len);
-+
-+#endif /* STRING_UTIL_H */
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/opkg/opkg/0002-md5-Add-md5_to_string-function.patch b/yocto-poky/meta/recipes-devtools/opkg/opkg/0002-md5-Add-md5_to_string-function.patch
deleted file mode 100644
index 3b823c6..0000000
--- a/yocto-poky/meta/recipes-devtools/opkg/opkg/0002-md5-Add-md5_to_string-function.patch
+++ /dev/null
@@ -1,110 +0,0 @@
-From ecad8afab377d8be95eeaafc08afa228c8e030c3 Mon Sep 17 00:00:00 2001
-From: Paul Barker <paul@paulbarker.me.uk>
-Date: Sat, 7 Nov 2015 10:23:50 +0000
-Subject: [PATCH 2/4] md5: Add md5_to_string function
-
-Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
-Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
-
-Upstream-Status: Accepted
----
- libopkg/file_util.c | 28 +++-------------------------
- libopkg/md5.c       |  7 +++++++
- libopkg/md5.h       |  3 +++
- 3 files changed, 13 insertions(+), 25 deletions(-)
-
-diff --git a/libopkg/file_util.c b/libopkg/file_util.c
-index 5eff469..cb3dbf0 100644
---- a/libopkg/file_util.c
-+++ b/libopkg/file_util.c
-@@ -349,27 +349,13 @@ int file_mkdir_hier(const char *path, long mode)
- 
- char *file_md5sum_alloc(const char *file_name)
- {
--    static const int md5sum_bin_len = 16;
--    static const int md5sum_hex_len = 32;
--
--    static const unsigned char bin2hex[16] = {
--        '0', '1', '2', '3',
--        '4', '5', '6', '7',
--        '8', '9', 'a', 'b',
--        'c', 'd', 'e', 'f'
--    };
--
--    int i, err;
-+    int err;
-     FILE *file;
--    char *md5sum_hex;
--    unsigned char md5sum_bin[md5sum_bin_len];
--
--    md5sum_hex = xcalloc(1, md5sum_hex_len + 1);
-+    unsigned char md5sum_bin[16];
- 
-     file = fopen(file_name, "r");
-     if (file == NULL) {
-         opkg_perror(ERROR, "Failed to open file %s", file_name);
--        free(md5sum_hex);
-         return NULL;
-     }
- 
-@@ -377,20 +363,12 @@ char *file_md5sum_alloc(const char *file_name)
-     if (err) {
-         opkg_msg(ERROR, "Could't compute md5sum for %s.\n", file_name);
-         fclose(file);
--        free(md5sum_hex);
-         return NULL;
-     }
- 
-     fclose(file);
- 
--    for (i = 0; i < md5sum_bin_len; i++) {
--        md5sum_hex[i * 2] = bin2hex[md5sum_bin[i] >> 4];
--        md5sum_hex[i * 2 + 1] = bin2hex[md5sum_bin[i] & 0xf];
--    }
--
--    md5sum_hex[md5sum_hex_len] = '\0';
--
--    return md5sum_hex;
-+    return md5_to_string(md5sum_bin);
- }
- 
- #ifdef HAVE_SHA256
-diff --git a/libopkg/md5.c b/libopkg/md5.c
-index d476b8b..bc2b229 100644
---- a/libopkg/md5.c
-+++ b/libopkg/md5.c
-@@ -30,6 +30,8 @@
- #include <string.h>
- #include <sys/types.h>
- 
-+#include "string_util.h"
-+
- #if USE_UNLOCKED_IO
- #include "unlocked-io.h"
- #endif
-@@ -431,3 +433,8 @@ void md5_process_block(const void *buffer, size_t len, struct md5_ctx *ctx)
-     ctx->C = C;
-     ctx->D = D;
- }
-+
-+char *md5_to_string(const void *md5sum_bin)
-+{
-+    return bin_to_hex(md5sum_bin, 16);
-+}
-diff --git a/libopkg/md5.h b/libopkg/md5.h
-index 01320f5..2a7274d 100644
---- a/libopkg/md5.h
-+++ b/libopkg/md5.h
-@@ -118,6 +118,9 @@ extern int __md5_stream(FILE * stream, void *resblock) __THROW;
- extern void *__md5_buffer(const char *buffer, size_t len,
-                           void *resblock) __THROW;
- 
-+/* Convert a binary md5sum value to an ASCII string. */
-+char *md5_to_string(const void *md5sum_bin);
-+
- #ifdef __cplusplus
- }
- #endif
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/opkg/opkg/0003-sha256-Add-sha256_to_string-function.patch b/yocto-poky/meta/recipes-devtools/opkg/opkg/0003-sha256-Add-sha256_to_string-function.patch
deleted file mode 100644
index 16e82d7..0000000
--- a/yocto-poky/meta/recipes-devtools/opkg/opkg/0003-sha256-Add-sha256_to_string-function.patch
+++ /dev/null
@@ -1,110 +0,0 @@
-From 92e8378103bba3b91f2dec4e6fda3e1755a7c0fd Mon Sep 17 00:00:00 2001
-From: Paul Barker <paul@paulbarker.me.uk>
-Date: Sat, 7 Nov 2015 10:23:51 +0000
-Subject: [PATCH 3/4] sha256: Add sha256_to_string function
-
-Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
-Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
-
-Upstream-Status: Accepted
----
- libopkg/file_util.c | 28 +++-------------------------
- libopkg/sha256.c    |  7 +++++++
- libopkg/sha256.h    |  3 +++
- 3 files changed, 13 insertions(+), 25 deletions(-)
-
-diff --git a/libopkg/file_util.c b/libopkg/file_util.c
-index cb3dbf0..864aedb 100644
---- a/libopkg/file_util.c
-+++ b/libopkg/file_util.c
-@@ -374,27 +374,13 @@ char *file_md5sum_alloc(const char *file_name)
- #ifdef HAVE_SHA256
- char *file_sha256sum_alloc(const char *file_name)
- {
--    static const int sha256sum_bin_len = 32;
--    static const int sha256sum_hex_len = 64;
--
--    static const unsigned char bin2hex[16] = {
--        '0', '1', '2', '3',
--        '4', '5', '6', '7',
--        '8', '9', 'a', 'b',
--        'c', 'd', 'e', 'f'
--    };
--
--    int i, err;
-+    int err;
-     FILE *file;
--    char *sha256sum_hex;
--    unsigned char sha256sum_bin[sha256sum_bin_len];
--
--    sha256sum_hex = xcalloc(1, sha256sum_hex_len + 1);
-+    unsigned char sha256sum_bin[32];
- 
-     file = fopen(file_name, "r");
-     if (file == NULL) {
-         opkg_perror(ERROR, "Failed to open file %s", file_name);
--        free(sha256sum_hex);
-         return NULL;
-     }
- 
-@@ -402,20 +388,12 @@ char *file_sha256sum_alloc(const char *file_name)
-     if (err) {
-         opkg_msg(ERROR, "Could't compute sha256sum for %s.\n", file_name);
-         fclose(file);
--        free(sha256sum_hex);
-         return NULL;
-     }
- 
-     fclose(file);
- 
--    for (i = 0; i < sha256sum_bin_len; i++) {
--        sha256sum_hex[i * 2] = bin2hex[sha256sum_bin[i] >> 4];
--        sha256sum_hex[i * 2 + 1] = bin2hex[sha256sum_bin[i] & 0xf];
--    }
--
--    sha256sum_hex[sha256sum_hex_len] = '\0';
--
--    return sha256sum_hex;
-+    return sha256_to_string(sha256sum_bin);
- }
- 
- #endif
-diff --git a/libopkg/sha256.c b/libopkg/sha256.c
-index 0816858..bceed72 100644
---- a/libopkg/sha256.c
-+++ b/libopkg/sha256.c
-@@ -29,6 +29,8 @@
- #include <stddef.h>
- #include <string.h>
- 
-+#include "string_util.h"
-+
- #if USE_UNLOCKED_IO
- #include "unlocked-io.h"
- #endif
-@@ -517,3 +519,8 @@ void sha256_process_block(const void *buffer, size_t len,
-         h = ctx->state[7] += h;
-     }
- }
-+
-+char *sha256_to_string(const void *sha256sum_bin)
-+{
-+    return bin_to_hex(sha256sum_bin, 32);
-+}
-diff --git a/libopkg/sha256.h b/libopkg/sha256.h
-index 734ab54..0d1e9e5 100644
---- a/libopkg/sha256.h
-+++ b/libopkg/sha256.h
-@@ -85,6 +85,9 @@ extern int sha224_stream(FILE * stream, void *resblock);
- extern void *sha256_buffer(const char *buffer, size_t len, void *resblock);
- extern void *sha224_buffer(const char *buffer, size_t len, void *resblock);
- 
-+/* Convert a binary sha256sum value to an ASCII string. */
-+char *sha256_to_string(const void *sha256sum_bin);
-+
- #ifdef __cplusplus
- }
- #endif
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/opkg/opkg/0004-opkg_download-Use-short-cache-file-name.patch b/yocto-poky/meta/recipes-devtools/opkg/opkg/0004-opkg_download-Use-short-cache-file-name.patch
deleted file mode 100644
index 7ea661d..0000000
--- a/yocto-poky/meta/recipes-devtools/opkg/opkg/0004-opkg_download-Use-short-cache-file-name.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-From 61636f15718edc7ea17b91f22f1d97b905eaf951 Mon Sep 17 00:00:00 2001
-From: Paul Barker <paul@paulbarker.me.uk>
-Date: Sat, 7 Nov 2015 10:23:52 +0000
-Subject: [PATCH 4/4] opkg_download: Use short cache file name
-
-Source URIs can be very long. The cache directory itself may already have a very
-long path, especially if we're installing packages into an offline rootfs.
-Therefore it's not a good idea to simply tag the source URI onto the cache
-directory path to create a cache file name.
-
-To create shorter cache file names which are deterministic and very likely to be
-unique, we use the md5sum of the source URI along with the basename of the
-source URI. The basename is length limited to ensure that it the resulting
-filename length is always reasonable.
-
-Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
-Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
-
-Upstream-Status: Accepted
----
- libopkg/opkg_download.c | 35 ++++++++++++++++++++++++++++-------
- 1 file changed, 28 insertions(+), 7 deletions(-)
-
-diff --git a/libopkg/opkg_download.c b/libopkg/opkg_download.c
-index e9b86a5..a37b10d 100644
---- a/libopkg/opkg_download.c
-+++ b/libopkg/opkg_download.c
-@@ -29,10 +29,18 @@
- #include "opkg_verify.h"
- #include "opkg_utils.h"
- 
-+#include "md5.h"
- #include "sprintf_alloc.h"
- #include "file_util.h"
- #include "xfuncs.h"
- 
-+/* Limit the short file name used to generate cache file names to 90 characters
-+ * so that when added to the md5sum (32 characters) and an underscore, the
-+ * resulting length is below 128 characters. The maximum file name length
-+ * differs between plaforms but 128 characters should be reasonable.
-+ */
-+#define MAX_SHORT_FILE_NAME_LENGTH 90
-+
- static int opkg_download_set_env()
- {
-     int r;
-@@ -135,15 +143,28 @@ int opkg_download_internal(const char *src, const char *dest,
-  */
- char *get_cache_location(const char *src)
- {
--    char *cache_name = xstrdup(src);
--    char *cache_location, *p;
-+    unsigned char md5sum_bin[16];
-+    char *md5sum_hex;
-+    char *cache_location;
-+    char *short_file_name;
-+    char *tmp = xstrdup(src);
- 
--    for (p = cache_name; *p; p++)
--        if (*p == '/')
--            *p = '_';
-+    md5_buffer(src, strlen(src), md5sum_bin);
-+    md5sum_hex = md5_to_string(md5sum_bin);
- 
--    sprintf_alloc(&cache_location, "%s/%s", opkg_config->cache_dir, cache_name);
--    free(cache_name);
-+    /* Generate a short file name which will be used along with an md5sum of the
-+     * full src URI in the cache file name. This short file name is limited to
-+     * MAX_SHORT_FILE_NAME_LENGTH to ensure that the total cache file name
-+     * length is reasonable.
-+     */
-+    short_file_name = basename(tmp);
-+    if (strlen(short_file_name) > MAX_SHORT_FILE_NAME_LENGTH)
-+        short_file_name[MAX_SHORT_FILE_NAME_LENGTH] = '\0';
-+
-+    sprintf_alloc(&cache_location, "%s/%s_%s", opkg_config->cache_dir,
-+                  md5sum_hex, short_file_name);
-+    free(md5sum_hex);
-+    free(tmp);
-     return cache_location;
- }
- 
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/opkg/opkg_0.3.0.bb b/yocto-poky/meta/recipes-devtools/opkg/opkg_0.3.1.bb
similarity index 81%
rename from yocto-poky/meta/recipes-devtools/opkg/opkg_0.3.0.bb
rename to yocto-poky/meta/recipes-devtools/opkg/opkg_0.3.1.bb
index 5ad3e92..577f495 100644
--- a/yocto-poky/meta/recipes-devtools/opkg/opkg_0.3.0.bb
+++ b/yocto-poky/meta/recipes-devtools/opkg/opkg_0.3.1.bb
@@ -14,17 +14,13 @@
 SRC_URI = "http://downloads.yoctoproject.org/releases/${BPN}/${BPN}-${PV}.tar.gz \
            file://opkg-configure.service \
            file://opkg.conf \
-           file://0001-opkg_archive-add-support-for-empty-compressed-files.patch \
-           file://0001-libopkg-include-stdio.h-for-getting-FILE-defined.patch \
            file://0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch \
-           file://0001-string_util-New-file-with-bin_to_hex-function.patch \
-           file://0002-md5-Add-md5_to_string-function.patch \
-           file://0003-sha256-Add-sha256_to_string-function.patch \
-           file://0004-opkg_download-Use-short-cache-file-name.patch \
+           file://0001-libsolv_solver_set_arch_policy-use-correct-logic-dur.patch \
+           file://0001-configure.ac-use-pkg-config-for-libsolv.patch \
 "
 
-SRC_URI[md5sum] = "3412cdc71d78b98facc84b19331ec64e"
-SRC_URI[sha256sum] = "7f735d1cdb8ef3718fb0f9fba44ca0d9a5c90d3a7f014f37a6d2f9474f54988f"
+SRC_URI[md5sum] = "43735e5dc1ebf46bd6ce56a7cdfdc720"
+SRC_URI[sha256sum] = "d2c6c02a8384ec21168a1f0a186cb5e9f577d1452f491d02ed3e56b2ea8b87df"
 
 inherit autotools pkgconfig systemd
 
@@ -41,6 +37,7 @@
 PACKAGECONFIG[openssl] = "--enable-openssl,--disable-openssl,openssl"
 PACKAGECONFIG[sha256] = "--enable-sha256,--disable-sha256"
 PACKAGECONFIG[pathfinder] = "--enable-pathfinder,--disable-pathfinder,pathfinder"
+PACKAGECONFIG[libsolv] = "--enable-solver=libsolv,--disable-solver,libsolv"
 
 do_install_append () {
 	install -d ${D}${sysconfdir}/opkg
diff --git a/yocto-poky/meta/recipes-devtools/orc/orc_0.4.23.bb b/yocto-poky/meta/recipes-devtools/orc/orc_0.4.24.bb
similarity index 73%
rename from yocto-poky/meta/recipes-devtools/orc/orc_0.4.23.bb
rename to yocto-poky/meta/recipes-devtools/orc/orc_0.4.24.bb
index d4257c3..520f88d 100644
--- a/yocto-poky/meta/recipes-devtools/orc/orc_0.4.23.bb
+++ b/yocto-poky/meta/recipes-devtools/orc/orc_0.4.24.bb
@@ -1,17 +1,19 @@
 SUMMARY = "Optimised Inner Loop Runtime Compiler"
-HOMEPAGE = "http://code.entropywave.com/projects/orc/"
+HOMEPAGE = "http://gstreamer.freedesktop.org/modules/orc.html"
 LICENSE = "BSD-2-Clause & BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://COPYING;md5=1400bd9d09e8af56b9ec982b3d85797e"
 
-SRC_URI = "http://gstreamer.freedesktop.org/src/orc/orc-${PV}.tar.xz;name=orc"
-SRC_URI[orc.md5sum] = "72e0612ace54d77aa2f7a006348ee81a"
-SRC_URI[orc.sha256sum] = "767eaebce2941737b43368225ec54598b3055ca78b4dc50c4092f5fcdc0bdfe7"
+SRC_URI = "http://gstreamer.freedesktop.org/src/orc/orc-${PV}.tar.xz"
+
+SRC_URI[md5sum] = "9e793ec34c0e20339659dd4bbbf62135"
+SRC_URI[sha256sum] = "338cd493b5247300149821c6312bdf7422a3593ae98691fc75d7e4fe727bd39b"
 
 inherit autotools pkgconfig
 
 BBCLASSEXTEND = "native nativesdk"
 
 PACKAGES =+ "orc-examples"
+PACKAGES_DYNAMIC += "^liborc-.*"
 FILES_orc-examples = "${libdir}/orc/*"
 FILES_${PN} = "${bindir}/*"
 
diff --git a/yocto-poky/meta/recipes-devtools/patchelf/patchelf/maxsize.patch b/yocto-poky/meta/recipes-devtools/patchelf/patchelf/maxsize.patch
new file mode 100644
index 0000000..cc04a89
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/patchelf/patchelf/maxsize.patch
@@ -0,0 +1,30 @@
+From f6886c2c33a1cf8771163919f3d20f6340c0ce38 Mon Sep 17 00:00:00 2001
+From: Eelco Dolstra <eelco.dolstra@logicblox.com>
+Date: Fri, 10 Jul 2015 18:12:37 +0200
+Subject: [PATCH] Quick fix for #47
+
+https://github.com/NixOS/patchelf/issues/47
+
+Avoid issues with holes in binaries such as qemu-pcc from qemu-native.
+
+Upstream-Status: Submitted
+RP
+2016/2/3
+
+---
+ src/patchelf.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/patchelf.cc b/src/patchelf.cc
+index 8566ed9..df75593 100644
+--- a/src/patchelf.cc
++++ b/src/patchelf.cc
+@@ -248,7 +248,7 @@ static void readFile(string fileName, mode_t * fileMode)
+     if (stat(fileName.c_str(), &st) != 0) error("stat");
+     fileSize = st.st_size;
+     *fileMode = st.st_mode;
+-    maxSize = fileSize + 8 * 1024 * 1024;
++    maxSize = fileSize + 64 * 1024 * 1024;
+ 
+     contents = (unsigned char *) malloc(fileSize + maxSize);
+     if (!contents) abort();
\ No newline at end of file
diff --git a/yocto-poky/meta/recipes-devtools/patchelf/patchelf_0.8.bb b/yocto-poky/meta/recipes-devtools/patchelf/patchelf_0.8.bb
index c1b87f5..8484a7e 100644
--- a/yocto-poky/meta/recipes-devtools/patchelf/patchelf_0.8.bb
+++ b/yocto-poky/meta/recipes-devtools/patchelf/patchelf_0.8.bb
@@ -1,4 +1,5 @@
-SRC_URI = "http://nixos.org/releases/${BPN}/${BPN}-${PV}/${BPN}-${PV}.tar.bz2"
+SRC_URI = "http://nixos.org/releases/${BPN}/${BPN}-${PV}/${BPN}-${PV}.tar.bz2 \
+           file://maxsize.patch"
 LICENSE = "GPLv3"
 SUMMARY = "Tool to allow editing of RPATH and interpreter fields in ELF binaries"
 
diff --git a/yocto-poky/meta/recipes-devtools/pax-utils/pax-utils_1.0.5.bb b/yocto-poky/meta/recipes-devtools/pax-utils/pax-utils_1.0.5.bb
deleted file mode 100644
index 0716a08..0000000
--- a/yocto-poky/meta/recipes-devtools/pax-utils/pax-utils_1.0.5.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-SUMMARY = "Security-focused ELF files checking tool"
-DESCRIPTION = "This is a small set of various PaX aware and related \
-utilities for ELF binaries. It can check ELF binary files and running \
-processes for issues that might be relevant when using ELF binaries \
-along with PaX, such as non-PIC code or executable stack and heap."
-HOMEPAGE = "http://www.gentoo.org/proj/en/hardened/pax-utils.xml"
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a"
-
-SRC_URI = "http://gentoo.osuosl.org/distfiles/pax-utils-${PV}.tar.xz"
-
-SRC_URI[md5sum] = "d731f5385682a7a62ee2e7b7dacc13a7"
-SRC_URI[sha256sum] = "f69a9938e4af7912d26d585094bc0203e43571a990fdd048319088a8b8ad906f"
-
-RDEPENDS_${PN} += "bash python"
-
-do_install() {
-    oe_runmake PREFIX=${D}${prefix} DESTDIR=${D} install
-}
-
-BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/pax-utils/pax-utils_1.1.5.bb b/yocto-poky/meta/recipes-devtools/pax-utils/pax-utils_1.1.5.bb
new file mode 100644
index 0000000..a887c03
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/pax-utils/pax-utils_1.1.5.bb
@@ -0,0 +1,35 @@
+SUMMARY = "Security-focused ELF files checking tool"
+DESCRIPTION = "This is a small set of various PaX aware and related \
+utilities for ELF binaries. It can check ELF binary files and running \
+processes for issues that might be relevant when using ELF binaries \
+along with PaX, such as non-PIC code or executable stack and heap."
+HOMEPAGE = "http://www.gentoo.org/proj/en/hardened/pax-utils.xml"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a"
+
+SRC_URI = "http://gentoo.osuosl.org/distfiles/pax-utils-${PV}.tar.xz \
+"
+
+SRC_URI[md5sum] = "bc3614322eaf88f167a608ae85d6b207"
+SRC_URI[sha256sum] = "2945b3e4df2e0dc95800bfbd3d88ab2243b2ee4ff064bbfc75734f6d9d986a89"
+
+RDEPENDS_${PN} += "bash"
+
+do_configure_prepend() {
+    touch ${S}/NEWS ${S}/AUTHORS ${S}/ChangeLog ${S}/README
+}
+
+do_install() {
+    oe_runmake PREFIX=${D}${prefix} DESTDIR=${D} install
+}
+
+BBCLASSEXTEND = "native"
+
+inherit autotools pkgconfig
+
+PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'largefile', 'largefile', '', d)} \
+"
+PACKAGECONFIG[libcap] = "--with-caps, --without-caps, libcap"
+PACKAGECONFIG[libseccomp] = "--with-seccomp, --without-seccomp, libseccomp"
+PACKAGECONFIG[largefile] = "--enable-largefile,--disable-largefile,,"
+PACKAGECONFIG[pyelftools] = "--with-python, --without-python,, pyelftools"
diff --git a/yocto-poky/meta/recipes-devtools/perl/libxml-parser-perl_2.44.bb b/yocto-poky/meta/recipes-devtools/perl/libxml-parser-perl_2.44.bb
index 9ccd417..9561a59 100644
--- a/yocto-poky/meta/recipes-devtools/perl/libxml-parser-perl_2.44.bb
+++ b/yocto-poky/meta/recipes-devtools/perl/libxml-parser-perl_2.44.bb
@@ -31,7 +31,5 @@
 	cpan_do_compile
 }
 
-FILES_${PN}-dbg += "${libdir}/perl/vendor_perl/*/auto/XML/Parser/Expat/.debug/"
-
 BBCLASSEXTEND="native"
 
diff --git a/yocto-poky/meta/recipes-devtools/perl/libxml-simple-perl_2.20.bb b/yocto-poky/meta/recipes-devtools/perl/libxml-simple-perl_2.22.bb
similarity index 77%
rename from yocto-poky/meta/recipes-devtools/perl/libxml-simple-perl_2.20.bb
rename to yocto-poky/meta/recipes-devtools/perl/libxml-simple-perl_2.22.bb
index 4721b4b..2243bb2 100644
--- a/yocto-poky/meta/recipes-devtools/perl/libxml-simple-perl_2.20.bb
+++ b/yocto-poky/meta/recipes-devtools/perl/libxml-simple-perl_2.22.bb
@@ -7,13 +7,13 @@
 HOMEPAGE = "http://search.cpan.org/~markov/XML-LibXML-Simple-0.93/lib/XML/LibXML/Simple.pod"
 SECTION = "libs"
 LICENSE = "Artistic-1.0 | GPL-1.0+"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=e7dbb3e2241fac8457967053fc1a1ddb"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=fa1187fceda00eee10b62961407ea7be"
 DEPENDS += "libxml-parser-perl"
 
 SRC_URI = "http://www.cpan.org/modules/by-module/XML/XML-Simple-${PV}.tar.gz"
 
-SRC_URI[md5sum] = "4d10964e123b76eca36678464daa63cd"
-SRC_URI[sha256sum] = "5cff13d0802792da1eb45895ce1be461903d98ec97c9c953bc8406af7294434a"
+SRC_URI[md5sum] = "0914abddfce749453ed89b54029f2643"
+SRC_URI[sha256sum] = "b9450ef22ea9644ae5d6ada086dc4300fa105be050a2030ebd4efd28c198eb49"
 
 S = "${WORKDIR}/XML-Simple-${PV}"
 
diff --git a/yocto-poky/meta/recipes-devtools/perl/perl-native_5.22.0.bb b/yocto-poky/meta/recipes-devtools/perl/perl-native_5.22.1.bb
similarity index 95%
rename from yocto-poky/meta/recipes-devtools/perl/perl-native_5.22.0.bb
rename to yocto-poky/meta/recipes-devtools/perl/perl-native_5.22.1.bb
index b4dda31..ed8222f 100644
--- a/yocto-poky/meta/recipes-devtools/perl/perl-native_5.22.0.bb
+++ b/yocto-poky/meta/recipes-devtools/perl/perl-native_5.22.1.bb
@@ -1,5 +1,7 @@
 require perl.inc
 
+EXTRA_OEMAKE = "-e MAKEFLAGS="
+
 SRC_URI += "\
            file://Configure-multilib.patch \
            file://perl-configpm-switch.patch \
@@ -11,8 +13,8 @@
            file://perl-PathTools-don-t-filter-out-blib-from-INC.patch \
           "
 
-SRC_URI[md5sum] = "ff0f09b17de426eff323426cb140ee79"
-SRC_URI[sha256sum] = "be83ead0c5c26cbbe626fa4bac1a4beabe23a9eebc15d35ba49ccde11878e196"
+SRC_URI[md5sum] = "6671e4829cbaf9cecafa9a84f141b0a3"
+SRC_URI[sha256sum] = "9e87317d693ce828095204be0d09af8d60b8785533fadea1a82b6f0e071e5c79"
 
 inherit native
 
diff --git a/yocto-poky/meta/recipes-devtools/perl/perl-rdepends_5.22.0.inc b/yocto-poky/meta/recipes-devtools/perl/perl-rdepends_5.22.1.inc
similarity index 99%
rename from yocto-poky/meta/recipes-devtools/perl/perl-rdepends_5.22.0.inc
rename to yocto-poky/meta/recipes-devtools/perl/perl-rdepends_5.22.1.inc
index 7f886f3..830ecce 100644
--- a/yocto-poky/meta/recipes-devtools/perl/perl-rdepends_5.22.0.inc
+++ b/yocto-poky/meta/recipes-devtools/perl/perl-rdepends_5.22.1.inc
@@ -7,12 +7,13 @@
 #2 find . -name \*.pm | xargs sed -i '/^=head/,/^=cut/d'
 #3 egrep -r "^\s*(\<use .*|\<require .*);?" perl-module-* --include="*.pm" 
 #| sed "s/\/.*\.pm: */ += /g;s/[\"\']//g;s/;.*/\"/g;s/+= .*\(require\|use\)\> */+= \"perl-module-/g;s/CPANPLUS::.*/cpanplus/g;s/CPAN::.*/cpan/g;s/::/-/g;s/ [^+\"].*//g;s/_/-/g;s/\.pl\"$/\"/;s/\"\?\$/\"/;s/(//;" | tr [:upper:] [:lower:] 
+#| awk '{if ($3 != "\x22"$1"\x22"){ print $0}}'
 #| grep -v -e "\-vms\-" -e module-5 -e "^$" -e "\\$" -e your -e tk -e autoperl -e html -e http -e parse-cpan -e perl-ostype -e ndbm-file -e module-mac -e fcgi -e lwp -e dbd -e dbix 
 #| sort -u 
 #| sed 's/^/RDEPENDS_/;s/perl-module-/${PN}-module-/g;s/module-\(module-\)/\1/g;s/\(module-load\)-conditional/\1/g;s/encode-configlocal/&-pm/;' 
 #| egrep -wv '=>|module-a|module-apache.?|module-apr|module-authen-sasl|module-b-asmdata|module-convert-ebcdic|module-devel-size|module-digest-perl-md5|module-dumpvalue|module-extutils-constant-aaargh56hash|module-extutils-xssymset|module-file-bsdglob|module-for|module-it|module-io-string|module-ipc-system-simple|module-lexical|module-local-lib|metadata|module-modperl-util|module-pluggable-object|module-test-builder-io-scalar|module-text-unidecode|module-win32|objects\sload|syscall.ph|systeminfo.ph|%s' > /tmp/perl-rdepends
 
-RDEPENDS_perl-misc += "perl"
+RDEPENDS_perl-misc += "perl perl-modules"
 RDEPENDS_${PN}-pod += "perl"
 
 # Some additional dependencies that the above doesn't manage to figure out
@@ -275,7 +276,6 @@
 RDEPENDS_${PN}-module-constant += "${PN}-module-strict"
 RDEPENDS_${PN}-module-constant += "${PN}-module-warnings-register"
 RDEPENDS_${PN}-module-corelist += "${PN}-module-list-util"
-RDEPENDS_${PN}-module-corelist += "${PN}-module-corelist"
 RDEPENDS_${PN}-module-corelist += "${PN}-module-strict"
 RDEPENDS_${PN}-module-corelist += "${PN}-module-vars"
 RDEPENDS_${PN}-module-corelist += "${PN}-module-version"
@@ -283,7 +283,6 @@
 RDEPENDS_${PN}-module-cpan += "${PN}-module-b"
 RDEPENDS_${PN}-module-cpan += "${PN}-module-carp"
 RDEPENDS_${PN}-module-cpan += "${PN}-module-config"
-RDEPENDS_${PN}-module-cpan += "${PN}-module-cpan"
 RDEPENDS_${PN}-module-cpan += "${PN}-module-cwd"
 RDEPENDS_${PN}-module-cpan += "${PN}-module-data-dumper"
 RDEPENDS_${PN}-module-cpan += "${PN}-module-dirhandle"
@@ -885,7 +884,6 @@
 RDEPENDS_${PN}-module-fatal += "${PN}-module-carp"
 RDEPENDS_${PN}-module-fatal += "${PN}-module-config"
 RDEPENDS_${PN}-module-fatal += "${PN}-module-constant"
-RDEPENDS_${PN}-module-fatal += "${PN}-module-fatal"
 RDEPENDS_${PN}-module-fatal += "${PN}-module-fcntl"
 RDEPENDS_${PN}-module-fatal += "${PN}-module-posix"
 RDEPENDS_${PN}-module-fatal += "${PN}-module-scalar-util"
@@ -1079,7 +1077,6 @@
 RDEPENDS_${PN}-module-i18n-langtags-list += "${PN}-module-strict"
 RDEPENDS_${PN}-module-i18n-langtags-list += "${PN}-module-vars"
 RDEPENDS_${PN}-module-i18n-langtags += "${PN}-module-exporter"
-RDEPENDS_${PN}-module-i18n-langtags += "${PN}-module-i18n-langtags"
 RDEPENDS_${PN}-module-i18n-langtags += "${PN}-module-strict"
 RDEPENDS_${PN}-module-i18n-langtags += "${PN}-module-vars"
 RDEPENDS_${PN}-module-io-compress-adapter-bzip2 += "${PN}-module-bytes"
@@ -1428,7 +1425,6 @@
 RDEPENDS_${PN}-module-load += "${PN}-module-file-spec"
 RDEPENDS_${PN}-module-load += "${PN}-module-locale-maketext-simple"
 RDEPENDS_${PN}-module-load += "${PN}-module-corelist"
-RDEPENDS_${PN}-module-load += "${PN}-module-load"
 RDEPENDS_${PN}-module-load += "${PN}-module-params-check"
 RDEPENDS_${PN}-module-load += "${PN}-module-strict"
 RDEPENDS_${PN}-module-load += "${PN}-module-vars"
@@ -2353,7 +2349,6 @@
 RDEPENDS_${PN}-module-test-more += "${PN}-module-scalar-util"
 RDEPENDS_${PN}-module-test-more += "${PN}-module-strict"
 RDEPENDS_${PN}-module-test-more += "${PN}-module-test-builder-module"
-RDEPENDS_${PN}-module-test-more += "${PN}-module-test-more"
 RDEPENDS_${PN}-module-test-more += "${PN}-module-warnings"
 RDEPENDS_${PN}-module-test += "${PN}-module-carp"
 RDEPENDS_${PN}-module-test += "${PN}-module-exporter"
diff --git a/yocto-poky/meta/recipes-devtools/perl/perl.inc b/yocto-poky/meta/recipes-devtools/perl/perl.inc
index 0d9716c..3313a94 100644
--- a/yocto-poky/meta/recipes-devtools/perl/perl.inc
+++ b/yocto-poky/meta/recipes-devtools/perl/perl.inc
@@ -6,3 +6,5 @@
 		    file://Artistic;md5=2e6fd2475335af892494fe1f7327baf3"
 
 SRC_URI = "http://www.cpan.org/src/5.0/${BP}.tar.xz"
+
+inherit upstream-version-is-even
diff --git a/yocto-poky/meta/recipes-devtools/perl/perl/Makefile.SH.patch b/yocto-poky/meta/recipes-devtools/perl/perl/Makefile.SH.patch
index 3de2331..edf49d6 100644
--- a/yocto-poky/meta/recipes-devtools/perl/perl/Makefile.SH.patch
+++ b/yocto-poky/meta/recipes-devtools/perl/perl/Makefile.SH.patch
@@ -5,10 +5,10 @@
  Makefile.SH |  145 +++++++++++++++++++++++++++--------------------------------
  1 file changed, 67 insertions(+), 78 deletions(-)
 
-diff --git a/Makefile.SH b/Makefile.SH
-index 034d812..67e08fd 100755
---- a/Makefile.SH
-+++ b/Makefile.SH
+Index: perl-5.22.1/Makefile.SH
+===================================================================
+--- perl-5.22.1.orig/Makefile.SH
++++ perl-5.22.1/Makefile.SH
 @@ -39,10 +39,10 @@ case "$useshrplib" in
  true)
  	# Prefix all runs of 'miniperl' and 'perl' with
@@ -67,6 +67,10 @@
 -all: $(FIRSTMAKEFILE) $(MINIPERL_EXE) $(generated_pods) $(private) $(unidatafiles) $(public) $(dynamic_ext) $(nonxs_ext) extras.make $(MANIFEST_SRT)
 -	@echo " ";
 -	@echo "	Everything is up to date. Type '$(MAKE) test' to run test suite."
+-
+-$(MANIFEST_SRT):	MANIFEST $(PERL_EXE)
+-	@$(RUN_PERL) Porting/manisort -q || (echo "WARNING: re-sorting MANIFEST"; \
+-	    $(RUN_PERL) Porting/manisort -q -o MANIFEST; sh -c true)
 +#all: $(FIRSTMAKEFILE) $(MINIPERL_EXE) $(generated_pods) $(private) $(unidatafiles) $(public) $(dynamic_ext) $(nonxs_ext) extras.make $(MANIFEST_SRT)
 +#	@echo " ";
 +#	@echo "	Everything is up to date. Type '$(MAKE) test' to run test suite."
@@ -76,10 +80,7 @@
 +more: $(generated_pods) $(private) $(public)
 +
 +more2: $(dynamic_ext)
- 
--$(MANIFEST_SRT):	MANIFEST $(PERL_EXE)
--	@$(RUN_PERL) Porting/manisort -q || (echo "WARNING: re-sorting MANIFEST"; \
--	    $(RUN_PERL) Porting/manisort -q -o MANIFEST; sh -c true)
++
 +more3: $(nonxs_ext)
 +
 +more4: extras.make $(MANIFEST_SRT)
@@ -144,7 +145,7 @@
  	./$(MINIPERLEXP) makedef.pl PLATFORM=os2 -DPERL_DLL=$(PERL_DLL) CC_FLAGS="$(OPTIMIZE)" > perl5.def
  
  !NO!SUBS!
-@@ -829,7 +829,7 @@ $(LIBPERL): $& $(obj) $(DYNALOADER) $(LIBPERLEXPORT)
+@@ -829,7 +829,7 @@ $(LIBPERL): $& $(obj) $(DYNALOADER) $(LI
  	true)
  		$spitshell >>$Makefile <<'!NO!SUBS!'
  	rm -f $@
@@ -175,7 +176,7 @@
  	$(MINIPERL) -f write_buildcustomize.pl    
  !NO!SUBS!
  		;;
-@@ -907,7 +911,9 @@ lib/buildcustomize.pl: $& $(mini_obj) write_buildcustomize.pl
+@@ -907,7 +911,9 @@ lib/buildcustomize.pl: $& $(mini_obj) wr
  	-@rm -f miniperl.xok
  	$(CC) $(CLDFLAGS) $(NAMESPACEFLAGS) -o $(MINIPERL_EXE) \
  	    $(mini_obj) $(libs)
@@ -186,7 +187,7 @@
  	$(MINIPERL) -f write_buildcustomize.pl
  !NO!SUBS!
  		;;
-@@ -918,7 +924,9 @@ lib/buildcustomize.pl: \$& \$(mini_obj) write_buildcustomize.pl
+@@ -918,7 +924,9 @@ lib/buildcustomize.pl: \$& \$(mini_obj)
  	-@rm -f miniperl.xok
  	-@rm \$(MINIPERL_EXE)
  	\$(LNS) \$(HOST_PERL) \$(MINIPERL_EXE)
@@ -197,7 +198,7 @@
  	\$(MINIPERL) -f write_buildcustomize.pl 'osname' "$osname"
  !GROK!THIS!
  		else
-@@ -927,7 +935,9 @@ lib/buildcustomize.pl: $& $(mini_obj) write_buildcustomize.pl
+@@ -927,7 +935,9 @@ lib/buildcustomize.pl: $& $(mini_obj) wr
  	-@rm -f miniperl.xok
  	$(CC) $(CLDFLAGS) -o $(MINIPERL_EXE) \
  	    $(mini_obj) $(libs)
@@ -217,7 +218,7 @@
  	-@for f in Makefile.PL PPPort_pm.PL PPPort_xs.PL ppport_h.PL; do \
  	(cd ext/Devel-PPPort && `pwd`/run.sh ../../$(MINIPERL_EXE) -I../../lib \$\$f); \
  	done
-@@ -981,7 +991,7 @@ makeppport: \$(MINIPERL_EXE) \$(CONFIGPM)
+@@ -981,7 +991,7 @@ makeppport: \$(MINIPERL_EXE) \$(CONFIGPM
  *)
  $spitshell >>$Makefile <<'!NO!SUBS!'
  .PHONY: makeppport
@@ -246,7 +247,7 @@
  	$(MINIPERL) lib/unicore/mktables -C lib/unicore -P pod -maketest -makelist -p
  #	Commented out so always runs, mktables looks at far more files than we
  #	can in this makefile to decide if needs to run or not
-@@ -1009,12 +1019,12 @@ uni.data: $(MINIPERL_EXE) $(CONFIGPM) lib/unicore/mktables $(nonxs_ext)
+@@ -1009,12 +1019,12 @@ uni.data: $(MINIPERL_EXE) $(CONFIGPM) li
  # $(PERL_EXE) and ext because pod_lib.pl needs Digest::MD5
  # But also this ensures that all extensions are built before we try to scan
  # them, which picks up Devel::PPPort's documentation.
@@ -262,9 +263,9 @@
  	$(MINIPERL) autodoc.pl
  
  pod/perlmodlib.pod: $(MINIPERL_EXE) pod/perlmodlib.PL MANIFEST
-@@ -1024,7 +1034,7 @@ pod/perl5220delta.pod: pod/perldelta.pod
- 	$(RMS) pod/perl5220delta.pod
- 	$(LNS) perldelta.pod pod/perl5220delta.pod
+@@ -1024,7 +1034,7 @@ pod/perl5221delta.pod: pod/perldelta.pod
+ 	$(RMS) pod/perl5221delta.pod
+ 	$(LNS) perldelta.pod pod/perl5221delta.pod
  
 -extra.pods: $(MINIPERL_EXE)
 +extra.pods:
@@ -300,11 +301,11 @@
  install.perl:	$(INSTALL_DEPENDENCE) installperl
 -	$(RUN_PERL) installperl --destdir=$(DESTDIR) $(INSTALLFLAGS) $(STRIPFLAGS)
 -	-@test ! -s extras.lst || PATH="`pwd`:\${PATH}" PERL5LIB="`pwd`/lib" \$(RUN_PERL) -Ilib -MCPAN -e '@ARGV&&install(@ARGV)' `cat extras.lst`
-+	./hostperl -Ifake_config_library -Ilib -MConfig installperl --destdir=$(DESTDIR) $(INSTALLFLAGS) $(STRIPFLAGS)
- 
+-
 -install.man:	all installman
 -	$(RUN_PERL) installman --destdir=$(DESTDIR) $(INSTALLFLAGS)
--
++	./hostperl -Ifake_config_library -Ilib -MConfig installperl --destdir=$(DESTDIR) $(INSTALLFLAGS) $(STRIPFLAGS)
+ 
 -# XXX Experimental. Hardwired values, but useful for testing.
 -# Eventually Configure could ask for some of these values.
 -install.html: all installhtml
@@ -337,7 +338,7 @@
  	$(MINIPERL) make_ext.pl $@ $(MAKE_EXT_ARGS) MAKE="$(MAKE)" LIBPERL_A=$(LIBPERL) LINKTYPE=static $(STATIC_LDFLAGS)
  
  n_dummy $(nonxs_ext):	$(MINIPERL_EXE) lib/buildcustomize.pl preplibrary FORCE
-@@ -1405,14 +1394,14 @@ test_prep_pre: preplibrary utilities $(nonxs_ext)
+@@ -1405,14 +1394,14 @@ test_prep_pre: preplibrary utilities $(n
  
  case "$targethost" in
  '') $spitshell >>$Makefile <<'!NO!SUBS!'
@@ -354,7 +355,7 @@
  	\$(dynamic_ext) \$(TEST_PERL_DLL) runtests \
  	\$(generated_pods)
  	$to libperl.*
-@@ -1465,7 +1454,7 @@ test_prep test-prep: test_prep_pre \$(MINIPERL_EXE) \$(unidatafiles) \$(PERL_EXE
+@@ -1465,7 +1454,7 @@ test_prep test-prep: test_prep_pre \$(MI
  esac
  
  $spitshell >>$Makefile <<'!NO!SUBS!'
@@ -363,12 +364,12 @@
  	$(MINIPERL) make_ext.pl $(dynamic_ext_re) MAKE="$(MAKE)" LIBPERL_A=$(LIBPERL) LINKTYPE=dynamic
  	cd t && (rm -f $(PERL_EXE); $(LNS) ../$(PERL_EXE) $(PERL_EXE))
  !NO!SUBS!
-@@ -1516,7 +1505,7 @@ $spitshell >>$Makefile <<'!NO!SUBS!'
+@@ -1526,7 +1515,7 @@ minitest_prep:
  
- # Can't depend on lib/Config.pm because that might be where miniperl
- # is crashing.
--minitest: $(MINIPERL_EXE)
-+minitest:
- 	-@test -f lib/Config.pm || $(MAKE) lib/Config.pm $(unidatafiles)
- 	@echo " "
- 	@echo "You may see some irrelevant test failures if you have been unable"
+ MINITEST_TESTS = base/*.t comp/*.t cmd/*.t run/*.t io/*.t re/*.t opbasic/*.t op/*.t uni/*.t perf/*.t
+ 
+-minitest: $(MINIPERL_EXE) minitest_prep
++minitest: minitest_prep
+ 	- cd t && $(RUN_PERL) TEST $(MINITEST_TESTS) </dev/tty
+ 
+ minitest-notty minitest_notty: $(MINIPERL_EXE) minitest_prep
diff --git a/yocto-poky/meta/recipes-devtools/perl/perl/config.sh b/yocto-poky/meta/recipes-devtools/perl/perl/config.sh
index 9fb5042..59e016e 100644
--- a/yocto-poky/meta/recipes-devtools/perl/perl/config.sh
+++ b/yocto-poky/meta/recipes-devtools/perl/perl/config.sh
@@ -14,7 +14,7 @@
 
 : Configure command line arguments.
 config_arg0='Configure'
-config_args='-des -Doptimize=-O2 -Dmyhostname=localhost -Dperladmin=root@localhost -Dcc=gcc -Dcf_by=Open Embedded -Dinstallprefix=@EXECPREFIX@ -Dprefix=@EXECPREFIX@ -Dvendorprefix=@EXECPREFIX@ -Dsiteprefix=@EXECPREFIX@ -Dotherlibdirs=@LIBDIR@/perl/5.22.0 -Duseshrplib -Dusethreads -Duseithreads -Duselargefiles -Ud_dosuid -Dd_semctl_semun -Ui_db -Ui_ndbm -Ui_gdbm -Di_shadow -Di_syslog -Dman3ext=3pm -Duseperlio -Dinstallusrbinperl -Ubincompat5005 -Uversiononly -Dpager=@USRBIN@/less -isr'
+config_args='-des -Doptimize=-O2 -Dmyhostname=localhost -Dperladmin=root@localhost -Dcc=gcc -Dcf_by=Open Embedded -Dinstallprefix=@EXECPREFIX@ -Dprefix=@EXECPREFIX@ -Dvendorprefix=@EXECPREFIX@ -Dsiteprefix=@EXECPREFIX@ -Dotherlibdirs=@LIBDIR@/perl/5.22.1 -Duseshrplib -Dusethreads -Duseithreads -Duselargefiles -Ud_dosuid -Dd_semctl_semun -Ui_db -Ui_ndbm -Ui_gdbm -Di_shadow -Di_syslog -Dman3ext=3pm -Duseperlio -Dinstallusrbinperl -Ubincompat5005 -Uversiononly -Dpager=@USRBIN@/less -isr'
 config_argc=28
 config_arg1='-des'
 config_arg2='-Doptimize=-O2'
@@ -26,7 +26,7 @@
 config_arg8='-Dprefix=@EXECPREFIX@'
 config_arg9='-Dvendorprefix=@EXECPREFIX@'
 config_arg10='-Dsiteprefix=@EXECPREFIX@'
-config_arg11='-Dotherlibdirs=@LIBDIR@/perl/5.22.0'
+config_arg11='-Dotherlibdirs=@LIBDIR@/perl/5.22.1'
 config_arg12='-Duseshrplib'
 config_arg13='-Dusethreads'
 config_arg14='-Duseithreads'
@@ -66,11 +66,11 @@
 api_revision='5'
 api_subversion='0'
 api_version='22'
-api_versionstring='5.22.0'
+api_versionstring='5.22.1'
 ar='ar'
-archlib='@LIBDIR@/perl/5.22.0/@ARCH@-thread-multi'
-archlibexp='@STAGINGDIR@@LIBDIR@/perl/5.22.0/@ARCH@-thread-multi'
-archlib_exp='@LIBDIR@/perl/5.22.0/@ARCH@-thread-multi'
+archlib='@LIBDIR@/perl/5.22.1/@ARCH@-thread-multi'
+archlibexp='@STAGINGDIR@@LIBDIR@/perl/5.22.1/@ARCH@-thread-multi'
+archlib_exp='@LIBDIR@/perl/5.22.1/@ARCH@-thread-multi'
 archname64=''
 archname='@ARCH@-thread-multi'
 archobjs=''
@@ -88,7 +88,7 @@
 cat='cat'
 cc='gcc'
 cccdlflags='-fPIC'
-ccdlflags='-Wl,-E -Wl,-rpath,@LIBDIR@/perl/5.22.0/@ARCH@-thread-multi/CORE'
+ccdlflags='-Wl,-E -Wl,-rpath,@LIBDIR@/perl/5.22.1/@ARCH@-thread-multi/CORE'
 ccflags='-D_REENTRANT -D_GNU_SOURCE -fwrapv -fno-strict-aliasing -pipe -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2'
 ccflags_uselargefiles='-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
 ccname='gcc'
@@ -834,7 +834,7 @@
 incpath=''
 inews=''
 initialinstalllocation='@USRBIN@'
-installarchlib='@LIBDIR@/perl/5.22.0/@ARCH@-thread-multi'
+installarchlib='@LIBDIR@/perl/5.22.1/@ARCH@-thread-multi'
 installbin='@USRBIN@'
 installhtml1dir=''
 installhtml3dir=''
@@ -842,23 +842,23 @@
 installman3dir=''
 installprefix='@EXECPREFIX@'
 installprefixexp='@EXECPREFIX@'
-installprivlib='@LIBDIR@/perl/5.22.0'
+installprivlib='@LIBDIR@/perl/5.22.1'
 installscript='@USRBIN@'
-installsitearch='@LIBDIR@/perl/site_perl/5.22.0/@ARCH@-thread-multi'
+installsitearch='@LIBDIR@/perl/site_perl/5.22.1/@ARCH@-thread-multi'
 installsitebin='@USRBIN@'
 installsitehtml1dir=''
 installsitehtml3dir=''
-installsitelib='@LIBDIR@/perl/site_perl/5.22.0'
+installsitelib='@LIBDIR@/perl/site_perl/5.22.1'
 installsiteman1dir=''
 installsiteman3dir=''
 installsitescript='@USRBIN@'
 installstyle='lib/perl'
 installusrbinperl='define'
-installvendorarch='@LIBDIR@/perl/vendor_perl/5.22.0/@ARCH@-thread-multi'
+installvendorarch='@LIBDIR@/perl/vendor_perl/5.22.1/@ARCH@-thread-multi'
 installvendorbin='@USRBIN@'
 installvendorhtml1dir=''
 installvendorhtml3dir=''
-installvendorlib='@LIBDIR@/perl/vendor_perl/5.22.0'
+installvendorlib='@LIBDIR@/perl/vendor_perl/5.22.1'
 installvendorman1dir=''
 installvendorman3dir=''
 installvendorscript='@USRBIN@'
@@ -957,7 +957,7 @@
 orderlib='false'
 osname='linux'
 osvers='3.19.5-yocto-standard'
-otherlibdirs='@LIBDIR@/perl/5.22.0'
+otherlibdirs='@LIBDIR@/perl/5.22.1'
 package='perl'
 pager='/usr/bin/less -isr'
 passcat='cat /etc/passwd'
@@ -978,8 +978,8 @@
 pr=''
 prefix='@EXECPREFIX@'
 prefixexp='@EXECPREFIX@'
-privlib='@LIBDIR@/perl/5.22.0'
-privlibexp='@LIBDIR@/perl/5.22.0'
+privlib='@LIBDIR@/perl/5.22.1'
+privlibexp='@LIBDIR@/perl/5.22.1'
 procselfexe='"/proc/self/exe"'
 prototype='define'
 ptrsize='8'
@@ -1045,17 +1045,17 @@
 sig_num_init='0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 6, 17, 29, 31, 0'
 sig_size='69'
 signal_t='void'
-sitearch='@LIBDIR@/perl/site_perl/5.22.0/@ARCH@-thread-multi'
-sitearchexp='@LIBDIR@/perl/site_perl/5.22.0/@ARCH@-thread-multi'
+sitearch='@LIBDIR@/perl/site_perl/5.22.1/@ARCH@-thread-multi'
+sitearchexp='@LIBDIR@/perl/site_perl/5.22.1/@ARCH@-thread-multi'
 sitebin='@USRBIN@'
 sitebinexp='@USRBIN@'
 sitehtml1dir=''
 sitehtml1direxp=''
 sitehtml3dir=''
 sitehtml3direxp=''
-sitelib='@LIBDIR@/perl/site_perl/5.22.0'
+sitelib='@LIBDIR@/perl/site_perl/5.22.1'
 sitelib_stem='@LIBDIR@/perl/site_perl'
-sitelibexp='@LIBDIR@/perl/site_perl/5.22.0'
+sitelibexp='@LIBDIR@/perl/site_perl/5.22.1'
 siteman1dir=''
 siteman1direxp=''
 siteman3dir=''
@@ -1174,17 +1174,17 @@
 uvuformat='"lu"'
 uvxformat='"lx"'
 vaproto='define'
-vendorarch='@LIBDIR@/perl/vendor_perl/5.22.0/@ARCH@-thread-multi'
-vendorarchexp='@LIBDIR@/perl/vendor_perl/5.22.0/@ARCH@-thread-multi'
+vendorarch='@LIBDIR@/perl/vendor_perl/5.22.1/@ARCH@-thread-multi'
+vendorarchexp='@LIBDIR@/perl/vendor_perl/5.22.1/@ARCH@-thread-multi'
 vendorbin='@USRBIN@'
 vendorbinexp='@USRBIN@'
 vendorhtml1dir=' '
 vendorhtml1direxp=''
 vendorhtml3dir=' '
 vendorhtml3direxp=''
-vendorlib='@LIBDIR@/perl/vendor_perl/5.22.0'
+vendorlib='@LIBDIR@/perl/vendor_perl/5.22.1'
 vendorlib_stem='@LIBDIR@/perl/vendor_perl'
-vendorlibexp='@LIBDIR@/perl/vendor_perl/5.22.0'
+vendorlibexp='@LIBDIR@/perl/vendor_perl/5.22.1'
 vendorman1dir=' '
 vendorman1direxp=''
 vendorman3dir=' '
@@ -1193,7 +1193,7 @@
 vendorprefixexp='@EXECPREFIX@'
 vendorscript='@USRBIN@'
 vendorscriptexp='@USRBIN@'
-version='5.22.0'
+version='5.22.1'
 version_patchlevel_string='version 22 subversion 0'
 versiononly='undef'
 vi=''
diff --git a/yocto-poky/meta/recipes-devtools/perl/perl/perl-errno-generation-gcc5.patch b/yocto-poky/meta/recipes-devtools/perl/perl/perl-errno-generation-gcc5.patch
index efbc55d..7379d8b 100644
--- a/yocto-poky/meta/recipes-devtools/perl/perl/perl-errno-generation-gcc5.patch
+++ b/yocto-poky/meta/recipes-devtools/perl/perl/perl-errno-generation-gcc5.patch
@@ -5,14 +5,25 @@
 systems with gcc 5, it is unlikely that it will work on any supported host. Switch out gccversion
 for the version extracted from $CC --version.
 
---- perl-5.22.0/ext/Errno/Errno_pm.PL	2015-10-19 18:01:20.622143786 -0400
-+++ perl-5.22.0-fixed/ext/Errno/Errno_pm.PL	2015-10-19 17:50:35.662137367 -0400
-@@ -224,9 +224,12 @@
+Jeremy Puhlman <jpuhlman@mvista.com>
+
+Fix spaces in brackets while running $CC --version
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ ext/Errno/Errno_pm.PL | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/ext/Errno/Errno_pm.PL b/ext/Errno/Errno_pm.PL
+index 1fd29d0..7976ea2 100644
+--- a/ext/Errno/Errno_pm.PL
++++ b/ext/Errno/Errno_pm.PL
+@@ -224,9 +224,13 @@ sub write_errno_pm {
  
      {	# BeOS (support now removed) did not enter this block
      # invoke CPP and read the output
 +        my $compiler = $ENV{'CC'};
 +        my $compiler_out = `$compiler --version`;
++        $compiler_out =~ s/\(.*\)/;/;
 +        my @compiler_version = split / /,$compiler_out; 
  
  	my $inhibit_linemarkers = '';
@@ -21,3 +32,6 @@
  	    # GCC 5.0 interleaves expanded macros with line numbers breaking
  	    # each line into multiple lines. RT#123784
  	    $inhibit_linemarkers = ' -P';
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/perl/perl_5.22.0.bb b/yocto-poky/meta/recipes-devtools/perl/perl_5.22.1.bb
similarity index 96%
rename from yocto-poky/meta/recipes-devtools/perl/perl_5.22.0.bb
rename to yocto-poky/meta/recipes-devtools/perl/perl_5.22.1.bb
index 9df8d04..bf8b3b6 100644
--- a/yocto-poky/meta/recipes-devtools/perl/perl_5.22.0.bb
+++ b/yocto-poky/meta/recipes-devtools/perl/perl_5.22.1.bb
@@ -71,8 +71,8 @@
             file://test/ext-DynaLoader-t-DynaLoader.t-fix-calling-dl_findfil.patch \
            "
 
-SRC_URI[md5sum] = "ff0f09b17de426eff323426cb140ee79"
-SRC_URI[sha256sum] = "be83ead0c5c26cbbe626fa4bac1a4beabe23a9eebc15d35ba49ccde11878e196"
+SRC_URI[md5sum] = "6671e4829cbaf9cecafa9a84f141b0a3"
+SRC_URI[sha256sum] = "9e87317d693ce828095204be0d09af8d60b8785533fadea1a82b6f0e071e5c79"
 
 inherit perlnative siteinfo
 
@@ -87,6 +87,8 @@
 export PERL_LIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/"
 export PERL_ARCHLIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/"
 
+EXTRA_OEMAKE = "-e MAKEFLAGS="
+
 # LDFLAGS for shared libraries
 export LDDLFLAGS = "${LDFLAGS} -shared"
 
@@ -304,13 +306,6 @@
                    ${libdir}/perl/${PV}/*/*.pod \
                    ${libdir}/perl/${PV}/*/*/*.pod "
 FILES_perl-misc = "${bindir}/*"
-FILES_${PN}-dbg += "${libdir}/perl/${PV}/auto/*/.debug \
-                    ${libdir}/perl/${PV}/auto/*/*/.debug \
-                    ${libdir}/perl/${PV}/auto/*/*/*/.debug \
-                    ${libdir}/perl/${PV}/CORE/.debug \
-                    ${libdir}/perl/${PV}/*/.debug \
-                    ${libdir}/perl/${PV}/*/*/.debug \
-                    ${libdir}/perl/${PV}/*/*/*/.debug "
 FILES_${PN}-doc = "${libdir}/perl/${PV}/*/*.txt \
                    ${libdir}/perl/${PV}/*/*/*.txt \
                    ${libdir}/perl/${PV}/auto/XS/Typemap \
@@ -356,7 +351,7 @@
     # modules. Don't attempt to use the result of do_split_packages() as some
     # modules are manually split (eg. perl-module-unicore).
     packages = filter(lambda p: 'perl-module-' in p, d.getVar('PACKAGES', True).split())
-    d.setVar("RRECOMMENDS_${PN}-modules", ' '.join(packages))
+    d.setVar(d.expand("RRECOMMENDS_${PN}-modules"), ' '.join(packages))
 }
 
 PACKAGES_DYNAMIC += "^perl-module-.*"
diff --git a/yocto-poky/meta/recipes-devtools/pkgconfig/pkgconfig.inc b/yocto-poky/meta/recipes-devtools/pkgconfig/pkgconfig.inc
deleted file mode 100644
index 55ab5c4..0000000
--- a/yocto-poky/meta/recipes-devtools/pkgconfig/pkgconfig.inc
+++ /dev/null
@@ -1,49 +0,0 @@
-SUMMARY = "Helper tool used when compiling"
-DESCRIPTION = "pkg-config is a helper tool used when compiling applications and libraries. It helps determined \
-the correct compiler/link options.  It is also language-agnostic."
-HOMEPAGE = "http://pkg-config.freedesktop.org/wiki/"
-BUGTRACKER = "http://bugs.freedesktop.org/buglist.cgi?product=pkg-config"
-SECTION = "console/utils"
-
-LICENSE = "GPLv2+"
-LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-
-DEPENDS = "glib-2.0"
-DEPENDS_class-native = ""
-DEPENDS_class-nativesdk = ""
-
-SRCREV = "40342dd0ead05d457a2a4e692cf865f50033a709"
-PV = "0.28+git${SRCPV}"
-SRC_URI = "git://anongit.freedesktop.org/pkg-config"
-
-S = "${WORKDIR}/git"
-
-inherit autotools
-
-EXTRA_OECONF = "--without-internal-glib"
-EXTRA_OECONF_class-native = "--with-internal-glib"
-EXTRA_OECONF_class-nativesdk = "--with-internal-glib"
-
-acpaths = "-I ."
-
-BBCLASSEXTEND = "native nativesdk"
-
-# Set an empty dev package to ensure the base PN package gets
-# the pkg.m4 macros, pkgconfig does not deliver any other -dev
-# files.
-FILES_${PN}-dev = ""
-FILES_${PN} += "${datadir}/aclocal/pkg.m4"
-
-# When using the RPM generated automatic package dependencies, some packages
-# will end up requiring 'pkgconfig(pkg-config)'.  Allow this behavior by
-# specifying an appropriate provide.
-RPROVIDES_${PN} += "pkgconfig(pkg-config)"
-
-# Install a pkg-config-native wrapper that will use the native sysroot instead
-# of the MACHINE sysroot, for using pkg-config when building native tools.
-do_install_append_class-native () {
-    sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \
-        -e "s|@LIBDIR_NATIVE@|${PKG_CONFIG_LIBDIR}|" \
-        < ${WORKDIR}/pkg-config-native.in > ${B}/pkg-config-native
-    install -m755 ${B}/pkg-config-native ${D}${bindir}/pkg-config-native
-}
diff --git a/yocto-poky/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb b/yocto-poky/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb
index eaa511a..d34f608 100644
--- a/yocto-poky/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb
+++ b/yocto-poky/meta/recipes-devtools/pkgconfig/pkgconfig_git.bb
@@ -1,6 +1,53 @@
-require pkgconfig.inc
+SUMMARY = "Helper tool used when compiling"
+DESCRIPTION = "pkg-config is a helper tool used when compiling applications and libraries. It helps determined \
+the correct compiler/link options.  It is also language-agnostic."
+HOMEPAGE = "http://pkg-config.freedesktop.org/wiki/"
+BUGTRACKER = "http://bugs.freedesktop.org/buglist.cgi?product=pkg-config"
+SECTION = "console/utils"
 
-SRC_URI += " \
-            file://pkg-config-native.in \
-            file://fix-glib-configure-libtool-usage.patch \
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
+
+DEPENDS = "glib-2.0"
+DEPENDS_class-native = ""
+DEPENDS_class-nativesdk = ""
+
+SRCREV = "5914edfe9604abfedd220103cbac382fc4d268bb"
+PV = "0.29+git${SRCPV}"
+
+SRC_URI = "git://anongit.freedesktop.org/pkg-config \
+           file://pkg-config-native.in \
+           file://fix-glib-configure-libtool-usage.patch \
            "
+
+S = "${WORKDIR}/git"
+
+inherit autotools
+
+EXTRA_OECONF = "--without-internal-glib"
+EXTRA_OECONF_class-native = "--with-internal-glib"
+EXTRA_OECONF_class-nativesdk = "--with-internal-glib"
+
+acpaths = "-I ."
+
+BBCLASSEXTEND = "native nativesdk"
+
+# Set an empty dev package to ensure the base PN package gets
+# the pkg.m4 macros, pkgconfig does not deliver any other -dev
+# files.
+FILES_${PN}-dev = ""
+FILES_${PN} += "${datadir}/aclocal/pkg.m4"
+
+# When using the RPM generated automatic package dependencies, some packages
+# will end up requiring 'pkgconfig(pkg-config)'.  Allow this behavior by
+# specifying an appropriate provide.
+RPROVIDES_${PN} += "pkgconfig(pkg-config)"
+
+# Install a pkg-config-native wrapper that will use the native sysroot instead
+# of the MACHINE sysroot, for using pkg-config when building native tools.
+do_install_append_class-native () {
+    sed -e "s|@PATH_NATIVE@|${PKG_CONFIG_PATH}|" \
+        -e "s|@LIBDIR_NATIVE@|${PKG_CONFIG_LIBDIR}|" \
+        < ${WORKDIR}/pkg-config-native.in > ${B}/pkg-config-native
+    install -m755 ${B}/pkg-config-native ${D}${bindir}/pkg-config-native
+}
diff --git a/yocto-poky/meta/recipes-devtools/pseudo/files/0001-configure-Prune-PIE-flags.patch b/yocto-poky/meta/recipes-devtools/pseudo/files/0001-configure-Prune-PIE-flags.patch
new file mode 100644
index 0000000..43504ea
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/pseudo/files/0001-configure-Prune-PIE-flags.patch
@@ -0,0 +1,44 @@
+From b5545c08e6c674c49aef14b47a56a3e92df4d2a7 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 17 Feb 2016 07:36:34 +0000
+Subject: [pseudo][PATCH] configure: Prune PIE flags
+
+LDFLAGS are not taken from environment and CFLAGS is used for LDFLAGS
+however when using security options -fpie and -pie options are coming
+as part of ARCH_FLAGS and they get into LDFLAGS of shared objects as
+well so we end up with conflicting options -shared -pie, which gold
+rejects outright and bfd linker lets the one appearning last in cmdline
+take effect. This create quite a unpleasant situation in OE when
+security flags are enabled and gold or not-gold options are used
+it errors out but errors are not same.
+
+Anyway, with this patch we filter pie options from ARCH_FLAGS
+ouright and take control of generating PIC objects
+
+Helps with errors like
+
+| /mnt/oe/build/tmp-glibc/sysroots/x86_64-linux/usr/libexec/x86_64-oe-linux/gcc/x86_64-oe-linux/5.3.0/ld: pseudo_client.o: relocation R_X86_64_PC32 against symbol `pseudo_util_debug_flags' can not be used when making a shared object; recompile with -fPIC
+| /mnt/oe/build/tmp-glibc/sysroots/x86_64-linux/usr/libexec/x86_64-oe-linux/gcc/x86_64-oe-linux/5.3.0/ld: final link failed: Bad value
+| collect2: error: ld returned 1 exit status
+| make: *** [lib/pseudo/lib64/libpseudo.so] Error 1
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Submitted
+
+ configure | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/configure b/configure
+index e5ef9ce..83b0890 100755
+--- a/configure
++++ b/configure
+@@ -339,3 +339,5 @@ sed -e '
+   s,@ARCH@,'"$opt_arch"',g
+   s,@BITS@,'"$opt_bits"',g
+ ' < Makefile.in > Makefile
++
++sed -i -e 's/\-[f]*pie//g' Makefile
+-- 
+1.8.3.1
+
diff --git a/yocto-poky/meta/recipes-devtools/pseudo/files/handle-remove-xattr.patch b/yocto-poky/meta/recipes-devtools/pseudo/files/handle-remove-xattr.patch
new file mode 100644
index 0000000..8b7f30c
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/pseudo/files/handle-remove-xattr.patch
@@ -0,0 +1,36 @@
+From a24cf102967a4966bfabe36c3542fb65f35bf539 Mon Sep 17 00:00:00 2001
+From: Peter Seebach <peter.seebach@windriver.com>
+Date: Wed, 23 Mar 2016 11:55:25 -0500
+Subject: actually handle remove_xattr correctly
+
+The path is required but wasn't being extracted from the client's message,
+resulting in xattr removal never working. This does not fully address some
+deeper problems with the xattr implementation, but at least the common
+removal case works.
+
+Upstream-Status: Backport
+
+Index: pseudo-1.7.5/ChangeLog.txt
+===================================================================
+--- pseudo-1.7.5.orig/ChangeLog.txt
++++ pseudo-1.7.5/ChangeLog.txt
+@@ -1,3 +1,7 @@
++2016-03-22:
++       * (seebs) extract path from message for remove_xattr so it
++         actually works.
++
+ 2016-02-09:
+         * (seebs) 1.7.5 release
+ 
+Index: pseudo-1.7.5/pseudo.c
+===================================================================
+--- pseudo-1.7.5.orig/pseudo.c
++++ pseudo-1.7.5/pseudo.c
+@@ -543,6 +543,7 @@ pseudo_op(pseudo_msg_t *msg, const char
+ 		case OP_GET_XATTR:
+ 		case OP_LIST_XATTR:
+ 		case OP_REPLACE_XATTR:
++		case OP_REMOVE_XATTR:
+ 		case OP_SET_XATTR:
+ 			/* In a rename there are two paths, null separated in msg->path */
+ 			initial_len = strlen(msg->path);
diff --git a/yocto-poky/meta/recipes-devtools/pseudo/files/moreretries.patch b/yocto-poky/meta/recipes-devtools/pseudo/files/moreretries.patch
new file mode 100644
index 0000000..c1e5552
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/pseudo/files/moreretries.patch
@@ -0,0 +1,19 @@
+Increase the number of retries in pseudo due to occasional slow
+server shutdowns.
+
+Upstream-Status: Pending
+RP 2016/2/28
+
+Index: pseudo-1.7.5/pseudo_client.c
+===================================================================
+--- pseudo-1.7.5.orig/pseudo_client.c
++++ pseudo-1.7.5/pseudo_client.c
+@@ -1214,7 +1214,7 @@ pseudo_client_setup(void) {
+ 	return 1;
+ }
+ 
+-#define PSEUDO_RETRIES 50
++#define PSEUDO_RETRIES 250
+ static pseudo_msg_t *
+ pseudo_client_request(pseudo_msg_t *msg, size_t len, const char *path) {
+ 	pseudo_msg_t *response = 0;
diff --git a/yocto-poky/meta/recipes-devtools/pseudo/pseudo.inc b/yocto-poky/meta/recipes-devtools/pseudo/pseudo.inc
index fe12258..0de7b36 100644
--- a/yocto-poky/meta/recipes-devtools/pseudo/pseudo.inc
+++ b/yocto-poky/meta/recipes-devtools/pseudo/pseudo.inc
@@ -10,7 +10,6 @@
 DEPENDS = "sqlite3 attr"
 
 FILES_${PN} = "${prefix}/lib/pseudo/lib*/libpseudo.so ${bindir}/* ${localstatedir}/pseudo ${prefix}/var/pseudo"
-FILES_${PN}-dbg += "${prefix}/lib/pseudo/lib*/.debug"
 INSANE_SKIP_${PN} += "libdir"
 INSANE_SKIP_${PN}-dbg += "libdir"
 
diff --git a/yocto-poky/meta/recipes-devtools/pseudo/pseudo_1.7.4.bb b/yocto-poky/meta/recipes-devtools/pseudo/pseudo_1.7.5.bb
similarity index 65%
rename from yocto-poky/meta/recipes-devtools/pseudo/pseudo_1.7.4.bb
rename to yocto-poky/meta/recipes-devtools/pseudo/pseudo_1.7.5.bb
index d68e0af..d90e644 100644
--- a/yocto-poky/meta/recipes-devtools/pseudo/pseudo_1.7.4.bb
+++ b/yocto-poky/meta/recipes-devtools/pseudo/pseudo_1.7.5.bb
@@ -2,12 +2,15 @@
 
 SRC_URI = " \
     http://downloads.yoctoproject.org/releases/pseudo/${BPN}-${PV}.tar.bz2 \
+    file://0001-configure-Prune-PIE-flags.patch \
     file://fallback-passwd \
     file://fallback-group \
+    file://moreretries.patch \
+    file://handle-remove-xattr.patch \
 "
 
-SRC_URI[md5sum] = "6e4b59a346d08d4a29133c335ea12052"
-SRC_URI[sha256sum] = "f33ff84da328f943155f22cfd49030ef4ad85ad35fc2d9419a203521b65c384c"
+SRC_URI[md5sum] = "c10209938f03128d0c193f041ff3596d"
+SRC_URI[sha256sum] = "fd89cadec984d3b8202aca465898b1bb4350e0d63ba9aa9ac899f6f50270e688"
 
 PSEUDO_EXTRA_OPTS ?= "--enable-force-async --without-passwd-fallback"
 
diff --git a/yocto-poky/meta/recipes-devtools/pseudo/pseudo_git.bb b/yocto-poky/meta/recipes-devtools/pseudo/pseudo_git.bb
index eb666c0..abff1cf 100644
--- a/yocto-poky/meta/recipes-devtools/pseudo/pseudo_git.bb
+++ b/yocto-poky/meta/recipes-devtools/pseudo/pseudo_git.bb
@@ -1,7 +1,7 @@
 require pseudo.inc
 
-SRCREV = "3bc3909fa70535c2ef876009dc58e577b10a7e0e"
-PV = "1.7.4+git${SRCPV}"
+SRCREV = "786c6d3813622d18e12d36c4aa722af6a417c8fa"
+PV = "1.7.5+git${SRCPV}"
 
 DEFAULT_PREFERENCE = "-1"
 
diff --git a/yocto-poky/meta/recipes-devtools/python/python-2.7-manifest.inc b/yocto-poky/meta/recipes-devtools/python/python-2.7-manifest.inc
index dd8d825..189689d 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-2.7-manifest.inc
+++ b/yocto-poky/meta/recipes-devtools/python/python-2.7-manifest.inc
@@ -5,9 +5,9 @@
 
  
 
-PROVIDES+="${PN}-2to3 ${PN}-argparse ${PN}-audio ${PN}-bsddb ${PN}-codecs ${PN}-compile ${PN}-compiler ${PN}-compression ${PN}-contextlib ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-dev ${PN}-difflib ${PN}-distutils ${PN}-distutils-staticdev ${PN}-doctest ${PN}-elementtree ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-hotshot ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-resource ${PN}-robotparser ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc ${PN}-zlib "
+PROVIDES+="${PN}-2to3 ${PN}-argparse ${PN}-audio ${PN}-bsddb ${PN}-codecs ${PN}-compile ${PN}-compiler ${PN}-compression ${PN}-contextlib ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-dev ${PN}-difflib ${PN}-distutils ${PN}-distutils-staticdev ${PN}-doctest ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-hotshot ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-plistlib ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-resource ${PN}-robotparser ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc ${PN}-zlib "
 
-PACKAGES="${PN}-dbg ${PN}-2to3 ${PN}-argparse ${PN}-audio ${PN}-bsddb ${PN}-codecs ${PN}-compile ${PN}-compiler ${PN}-compression ${PN}-contextlib ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-dev ${PN}-difflib ${PN}-distutils-staticdev ${PN}-distutils ${PN}-doctest ${PN}-elementtree ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-hotshot ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-resource ${PN}-robotparser ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc ${PN}-zlib ${PN}-modules"
+PACKAGES="${PN}-dbg ${PN}-2to3 ${PN}-argparse ${PN}-audio ${PN}-bsddb ${PN}-codecs ${PN}-compile ${PN}-compiler ${PN}-compression ${PN}-contextlib ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-dev ${PN}-difflib ${PN}-distutils-staticdev ${PN}-distutils ${PN}-doctest ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-hotshot ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-plistlib ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-resource ${PN}-robotparser ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc ${PN}-zlib ${PN}-modules"
 
 SUMMARY_${PN}-2to3="Python automated Python 2 to 3 code translator"
 RDEPENDS_${PN}-2to3="${PN}-core"
@@ -47,7 +47,7 @@
 
 SUMMARY_${PN}-core="Python interpreter and core modules"
 RDEPENDS_${PN}-core="${PN}-lang ${PN}-re"
-FILES_${PN}-core="${libdir}/python2.7/__future__.* ${libdir}/python2.7/_abcoll.* ${libdir}/python2.7/abc.* ${libdir}/python2.7/copy.* ${libdir}/python2.7/copy_reg.* ${libdir}/python2.7/ConfigParser.* ${libdir}/python2.7/genericpath.* ${libdir}/python2.7/getopt.* ${libdir}/python2.7/linecache.* ${libdir}/python2.7/new.* ${libdir}/python2.7/os.* ${libdir}/python2.7/posixpath.* ${libdir}/python2.7/struct.* ${libdir}/python2.7/warnings.* ${libdir}/python2.7/site.* ${libdir}/python2.7/stat.* ${libdir}/python2.7/UserDict.* ${libdir}/python2.7/UserList.* ${libdir}/python2.7/UserString.* ${libdir}/python2.7/lib-dynload/binascii.so ${libdir}/python2.7/lib-dynload/_struct.so ${libdir}/python2.7/lib-dynload/time.so ${libdir}/python2.7/lib-dynload/xreadlines.so ${libdir}/python2.7/types.* ${libdir}/python2.7/platform.* ${bindir}/python* ${libdir}/python2.7/_weakrefset.* ${libdir}/python2.7/sysconfig.* ${libdir}/python2.7/_sysconfigdata.* ${libdir}/python2.7/config/Makefile ${includedir}/python${PYTHON_MAJMIN}/pyconfig*.h ${libdir}/python${PYTHON_MAJMIN}/sitecustomize.py "
+FILES_${PN}-core="${libdir}/python2.7/__future__.* ${libdir}/python2.7/_abcoll.* ${libdir}/python2.7/abc.* ${libdir}/python2.7/ast.* ${libdir}/python2.7/copy.* ${libdir}/python2.7/copy_reg.* ${libdir}/python2.7/ConfigParser.* ${libdir}/python2.7/genericpath.* ${libdir}/python2.7/getopt.* ${libdir}/python2.7/linecache.* ${libdir}/python2.7/new.* ${libdir}/python2.7/os.* ${libdir}/python2.7/posixpath.* ${libdir}/python2.7/struct.* ${libdir}/python2.7/warnings.* ${libdir}/python2.7/site.* ${libdir}/python2.7/stat.* ${libdir}/python2.7/UserDict.* ${libdir}/python2.7/UserList.* ${libdir}/python2.7/UserString.* ${libdir}/python2.7/lib-dynload/binascii.so ${libdir}/python2.7/lib-dynload/_struct.so ${libdir}/python2.7/lib-dynload/time.so ${libdir}/python2.7/lib-dynload/xreadlines.so ${libdir}/python2.7/types.* ${libdir}/python2.7/platform.* ${bindir}/python* ${libdir}/python2.7/_weakrefset.* ${libdir}/python2.7/sysconfig.* ${libdir}/python2.7/_sysconfigdata.* ${libdir}/python2.7/config/Makefile ${includedir}/python${PYTHON_MAJMIN}/pyconfig*.h ${libdir}/python${PYTHON_MAJMIN}/sitecustomize.py "
 
 SUMMARY_${PN}-crypt="Python basic cryptographic and hashing support"
 RDEPENDS_${PN}-crypt="${PN}-core"
@@ -82,7 +82,7 @@
 FILES_${PN}-difflib="${libdir}/python2.7/difflib.* "
 
 SUMMARY_${PN}-distutils="Python Distribution Utilities"
-RDEPENDS_${PN}-distutils="${PN}-core"
+RDEPENDS_${PN}-distutils="${PN}-core ${PN}-email"
 FILES_${PN}-distutils="${libdir}/python2.7/config ${libdir}/python2.7/distutils "
 
 SUMMARY_${PN}-distutils-staticdev="Python distribution utilities (static libraries)"
@@ -93,10 +93,6 @@
 RDEPENDS_${PN}-doctest="${PN}-core ${PN}-lang ${PN}-io ${PN}-re ${PN}-unittest ${PN}-debugger ${PN}-difflib"
 FILES_${PN}-doctest="${libdir}/python2.7/doctest.* "
 
-SUMMARY_${PN}-elementtree="Python elementree"
-RDEPENDS_${PN}-elementtree="${PN}-core"
-FILES_${PN}-elementtree="${libdir}/python2.7/lib-dynload/_elementtree.so "
-
 SUMMARY_${PN}-email="Python email support"
 RDEPENDS_${PN}-email="${PN}-core ${PN}-io ${PN}-re ${PN}-mime ${PN}-audio ${PN}-image ${PN}-netclient"
 FILES_${PN}-email="${libdir}/python2.7/imaplib.* ${libdir}/python2.7/email "
@@ -185,6 +181,10 @@
 RDEPENDS_${PN}-pkgutil="${PN}-core"
 FILES_${PN}-pkgutil="${libdir}/python2.7/pkgutil.* "
 
+SUMMARY_${PN}-plistlib="Generate and parse Mac OS X .plist files"
+RDEPENDS_${PN}-plistlib="${PN}-core ${PN}-datetime ${PN}-io"
+FILES_${PN}-plistlib="${libdir}/python2.7/plistlib.* "
+
 SUMMARY_${PN}-pprint="Python pretty-print support"
 RDEPENDS_${PN}-pprint="${PN}-core ${PN}-io"
 FILES_${PN}-pprint="${libdir}/python2.7/pprint.* "
@@ -270,8 +270,8 @@
 FILES_${PN}-unixadmin="${libdir}/python2.7/lib-dynload/nis.so ${libdir}/python2.7/lib-dynload/grp.so ${libdir}/python2.7/lib-dynload/pwd.so ${libdir}/python2.7/getpass.* "
 
 SUMMARY_${PN}-xml="Python basic XML support"
-RDEPENDS_${PN}-xml="${PN}-core ${PN}-elementtree ${PN}-re"
-FILES_${PN}-xml="${libdir}/python2.7/lib-dynload/pyexpat.so ${libdir}/python2.7/xml ${libdir}/python2.7/xmllib.* "
+RDEPENDS_${PN}-xml="${PN}-core ${PN}-re"
+FILES_${PN}-xml="${libdir}/python2.7/lib-dynload/_elementtree.so ${libdir}/python2.7/lib-dynload/pyexpat.so ${libdir}/python2.7/xml ${libdir}/python2.7/xmllib.* "
 
 SUMMARY_${PN}-xmlrpc="Python XML-RPC support"
 RDEPENDS_${PN}-xmlrpc="${PN}-core ${PN}-xml ${PN}-netserver ${PN}-lang"
@@ -282,7 +282,7 @@
 FILES_${PN}-zlib="${libdir}/python2.7/lib-dynload/zlib.so "
 
 SUMMARY_${PN}-modules="All Python modules"
-RDEPENDS_${PN}-modules="${PN}-2to3 ${PN}-argparse ${PN}-audio ${PN}-bsddb ${PN}-codecs ${PN}-compile ${PN}-compiler ${PN}-compression ${PN}-contextlib ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-difflib ${PN}-distutils ${PN}-doctest ${PN}-elementtree ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-hotshot ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-resource ${PN}-robotparser ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc ${PN}-zlib  "
+RDEPENDS_${PN}-modules="${PN}-2to3 ${PN}-argparse ${PN}-audio ${PN}-bsddb ${PN}-codecs ${PN}-compile ${PN}-compiler ${PN}-compression ${PN}-contextlib ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-difflib ${PN}-distutils ${PN}-doctest ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-hotshot ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-plistlib ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-resource ${PN}-robotparser ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc ${PN}-zlib  "
 ALLOW_EMPTY_${PN}-modules = "1"
 
 
diff --git a/yocto-poky/meta/recipes-devtools/python/python-3.4-manifest.inc b/yocto-poky/meta/recipes-devtools/python/python-3.4-manifest.inc
deleted file mode 100644
index 97070b6..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-3.4-manifest.inc
+++ /dev/null
@@ -1,268 +0,0 @@
-
-# WARNING: This file is AUTO GENERATED: Manual edits will be lost next time I regenerate the file.
-# Generator: '../../../scripts/contrib/python/generate-manifest-3.4.py' Version 20140131 (C) 2002-2010 Michael 'Mickey' Lauer <mlauer@vanille-media.de>
-# Visit the Python for Embedded Systems Site => http://www.Vanille.de/projects/python.spy
-
- 
-
-PROVIDES+="${PN}-2to3 ${PN}-asyncio ${PN}-audio ${PN}-codecs ${PN}-compile ${PN}-compression ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-dev ${PN}-difflib ${PN}-distutils ${PN}-distutils-staticdev ${PN}-doctest ${PN}-elementtree ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-reprlib ${PN}-resource ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc "
-
-PACKAGES="${PN}-dbg ${PN}-2to3 ${PN}-asyncio ${PN}-audio ${PN}-codecs ${PN}-compile ${PN}-compression ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-dev ${PN}-difflib ${PN}-distutils-staticdev ${PN}-distutils ${PN}-doctest ${PN}-elementtree ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-reprlib ${PN}-resource ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc ${PN}-modules"
-
-SUMMARY_${PN}-2to3="Python automated Python 2 to 3 code translator"
-RDEPENDS_${PN}-2to3="${PN}-core"
-FILES_${PN}-2to3="${libdir}/python3.4/lib2to3 "
-
-SUMMARY_${PN}-asyncio="Python Asynchronous I/O, event loop, coroutines and tasks"
-RDEPENDS_${PN}-asyncio="${PN}-core"
-FILES_${PN}-asyncio="${libdir}/python3.4/asyncio "
-
-SUMMARY_${PN}-audio="Python Audio Handling"
-RDEPENDS_${PN}-audio="${PN}-core"
-FILES_${PN}-audio="${libdir}/python3.4/wave.* ${libdir}/python3.4/chunk.* ${libdir}/python3.4/sndhdr.* ${libdir}/python3.4/lib-dynload/ossaudiodev.*.so ${libdir}/python3.4/lib-dynload/audioop.*.so ${libdir}/python3.4/audiodev.* ${libdir}/python3.4/sunaudio.* ${libdir}/python3.4/sunau.* ${libdir}/python3.4/toaiff.* "
-
-SUMMARY_${PN}-codecs="Python codecs, encodings & i18n support"
-RDEPENDS_${PN}-codecs="${PN}-core ${PN}-lang"
-FILES_${PN}-codecs="${libdir}/python3.4/codecs.* ${libdir}/python3.4/encodings ${libdir}/python3.4/gettext.* ${libdir}/python3.4/locale.* ${libdir}/python3.4/lib-dynload/_locale.*.so ${libdir}/python3.4/lib-dynload/_codecs* ${libdir}/python3.4/lib-dynload/_multibytecodec.*.so ${libdir}/python3.4/lib-dynload/unicodedata.*.so ${libdir}/python3.4/stringprep.* ${libdir}/python3.4/xdrlib.* "
-
-SUMMARY_${PN}-compile="Python bytecode compilation support"
-RDEPENDS_${PN}-compile="${PN}-core"
-FILES_${PN}-compile="${libdir}/python3.4/py_compile.* ${libdir}/python3.4/compileall.* "
-
-SUMMARY_${PN}-compression="Python high-level compression support"
-RDEPENDS_${PN}-compression="${PN}-core ${PN}-codecs"
-FILES_${PN}-compression="${libdir}/python3.4/gzip.* ${libdir}/python3.4/zipfile.* ${libdir}/python3.4/tarfile.* ${libdir}/python3.4/lib-dynload/bz2.*.so "
-
-SUMMARY_${PN}-core="Python interpreter and core modules"
-RDEPENDS_${PN}-core="${PN}-lang ${PN}-re ${PN}-reprlib ${PN}-codecs ${PN}-io ${PN}-math"
-FILES_${PN}-core="${libdir}/python3.4/__future__.* ${libdir}/python3.4/_abcoll.* ${libdir}/python3.4/abc.* ${libdir}/python3.4/copy.* ${libdir}/python3.4/copyreg.* ${libdir}/python3.4/ConfigParser.* ${libdir}/python3.4/genericpath.* ${libdir}/python3.4/getopt.* ${libdir}/python3.4/linecache.* ${libdir}/python3.4/new.* ${libdir}/python3.4/os.* ${libdir}/python3.4/posixpath.* ${libdir}/python3.4/struct.* ${libdir}/python3.4/warnings.* ${libdir}/python3.4/site.* ${libdir}/python3.4/stat.* ${libdir}/python3.4/UserDict.* ${libdir}/python3.4/UserList.* ${libdir}/python3.4/UserString.* ${libdir}/python3.4/lib-dynload/binascii.*.so ${libdir}/python3.4/lib-dynload/_struct.*.so ${libdir}/python3.4/lib-dynload/time.*.so ${libdir}/python3.4/lib-dynload/xreadlines.*.so ${libdir}/python3.4/types.* ${libdir}/python3.4/platform.* ${bindir}/python* ${libdir}/python3.4/_weakrefset.* ${libdir}/python3.4/sysconfig.* ${libdir}/python3.4/_sysconfigdata.* ${libdir}/python3.4/config/Makefile ${includedir}/python${PYTHON_BINABI}/pyconfig*.h ${libdir}/python${PYTHON_MAJMIN}/collections ${libdir}/python${PYTHON_MAJMIN}/_collections_abc.* ${libdir}/python${PYTHON_MAJMIN}/_sitebuiltins.* ${libdir}/python${PYTHON_MAJMIN}/sitecustomize.py "
-
-SUMMARY_${PN}-crypt="Python basic cryptographic and hashing support"
-RDEPENDS_${PN}-crypt="${PN}-core"
-FILES_${PN}-crypt="${libdir}/python3.4/hashlib.* ${libdir}/python3.4/md5.* ${libdir}/python3.4/sha.* ${libdir}/python3.4/lib-dynload/crypt.*.so ${libdir}/python3.4/lib-dynload/_hashlib.*.so ${libdir}/python3.4/lib-dynload/_sha256.*.so ${libdir}/python3.4/lib-dynload/_sha512.*.so "
-
-SUMMARY_${PN}-ctypes="Python C types support"
-RDEPENDS_${PN}-ctypes="${PN}-core"
-FILES_${PN}-ctypes="${libdir}/python3.4/ctypes ${libdir}/python3.4/lib-dynload/_ctypes.*.so ${libdir}/python3.4/lib-dynload/_ctypes_test.*.so "
-
-SUMMARY_${PN}-curses="Python curses support"
-RDEPENDS_${PN}-curses="${PN}-core"
-FILES_${PN}-curses="${libdir}/python3.4/curses ${libdir}/python3.4/lib-dynload/_curses.*.so ${libdir}/python3.4/lib-dynload/_curses_panel.*.so "
-
-SUMMARY_${PN}-datetime="Python calendar and time support"
-RDEPENDS_${PN}-datetime="${PN}-core ${PN}-codecs"
-FILES_${PN}-datetime="${libdir}/python3.4/_strptime.* ${libdir}/python3.4/calendar.* ${libdir}/python3.4/lib-dynload/datetime.*.so "
-
-SUMMARY_${PN}-db="Python file-based database support"
-RDEPENDS_${PN}-db="${PN}-core"
-FILES_${PN}-db="${libdir}/python3.4/anydbm.* ${libdir}/python3.4/dumbdbm.* ${libdir}/python3.4/whichdb.* ${libdir}/python3.4/dbm ${libdir}/python3.4/lib-dynload/_dbm.*.so "
-
-SUMMARY_${PN}-debugger="Python debugger"
-RDEPENDS_${PN}-debugger="${PN}-core ${PN}-io ${PN}-lang ${PN}-re ${PN}-stringold ${PN}-shell ${PN}-pprint ${PN}-importlib ${PN}-pkgutil"
-FILES_${PN}-debugger="${libdir}/python3.4/bdb.* ${libdir}/python3.4/pdb.* "
-
-SUMMARY_${PN}-dev="Python development package"
-RDEPENDS_${PN}-dev="${PN}-core"
-FILES_${PN}-dev="${includedir} ${libdir}/lib*${SOLIBSDEV} ${libdir}/*.la ${libdir}/*.a ${libdir}/*.o ${libdir}/pkgconfig ${base_libdir}/*.a ${base_libdir}/*.o ${datadir}/aclocal ${datadir}/pkgconfig "
-
-SUMMARY_${PN}-difflib="Python helpers for computing deltas between objects"
-RDEPENDS_${PN}-difflib="${PN}-lang ${PN}-re"
-FILES_${PN}-difflib="${libdir}/python3.4/difflib.* "
-
-SUMMARY_${PN}-distutils="Python Distribution Utilities"
-RDEPENDS_${PN}-distutils="${PN}-core"
-FILES_${PN}-distutils="${libdir}/python3.4/config ${libdir}/python3.4/distutils "
-
-SUMMARY_${PN}-distutils-staticdev="Python distribution utilities (static libraries)"
-RDEPENDS_${PN}-distutils-staticdev="${PN}-distutils"
-FILES_${PN}-distutils-staticdev="${libdir}/python3.4/config/lib*.a "
-
-SUMMARY_${PN}-doctest="Python framework for running examples in docstrings"
-RDEPENDS_${PN}-doctest="${PN}-core ${PN}-lang ${PN}-io ${PN}-re ${PN}-unittest ${PN}-debugger ${PN}-difflib"
-FILES_${PN}-doctest="${libdir}/python3.4/doctest.* "
-
-SUMMARY_${PN}-elementtree="Python elementree"
-RDEPENDS_${PN}-elementtree="${PN}-core"
-FILES_${PN}-elementtree="${libdir}/python3.4/lib-dynload/_elementtree.*.so "
-
-SUMMARY_${PN}-email="Python email support"
-RDEPENDS_${PN}-email="${PN}-core ${PN}-io ${PN}-re ${PN}-mime ${PN}-audio ${PN}-image ${PN}-netclient"
-FILES_${PN}-email="${libdir}/python3.4/imaplib.* ${libdir}/python3.4/email "
-
-SUMMARY_${PN}-fcntl="Python's fcntl interface"
-RDEPENDS_${PN}-fcntl="${PN}-core"
-FILES_${PN}-fcntl="${libdir}/python3.4/lib-dynload/fcntl.*.so "
-
-SUMMARY_${PN}-gdbm="Python GNU database support"
-RDEPENDS_${PN}-gdbm="${PN}-core"
-FILES_${PN}-gdbm="${libdir}/python3.4/lib-dynload/_gdbm.*.so "
-
-SUMMARY_${PN}-html="Python HTML processing support"
-RDEPENDS_${PN}-html="${PN}-core"
-FILES_${PN}-html="${libdir}/python3.4/formatter.* ${libdir}/python3.4/htmlentitydefs.* ${libdir}/python3.4/htmllib.* ${libdir}/python3.4/markupbase.* ${libdir}/python3.4/sgmllib.* ${libdir}/python3.4/HTMLParser.* "
-
-SUMMARY_${PN}-idle="Python Integrated Development Environment"
-RDEPENDS_${PN}-idle="${PN}-core ${PN}-tkinter"
-FILES_${PN}-idle="${bindir}/idle ${libdir}/python3.4/idlelib "
-
-SUMMARY_${PN}-image="Python graphical image handling"
-RDEPENDS_${PN}-image="${PN}-core"
-FILES_${PN}-image="${libdir}/python3.4/colorsys.* ${libdir}/python3.4/imghdr.* ${libdir}/python3.4/lib-dynload/imageop.*.so ${libdir}/python3.4/lib-dynload/rgbimg.*.so "
-
-SUMMARY_${PN}-importlib="Python import implementation library"
-RDEPENDS_${PN}-importlib="${PN}-core"
-FILES_${PN}-importlib="${libdir}/python3.4/importlib "
-
-SUMMARY_${PN}-io="Python low-level I/O"
-RDEPENDS_${PN}-io="${PN}-core ${PN}-math"
-FILES_${PN}-io="${libdir}/python3.4/lib-dynload/_socket.*.so ${libdir}/python3.4/lib-dynload/_io.*.so ${libdir}/python3.4/lib-dynload/_ssl.*.so ${libdir}/python3.4/lib-dynload/select.*.so ${libdir}/python3.4/lib-dynload/termios.*.so ${libdir}/python3.4/lib-dynload/cStringIO.*.so ${libdir}/python3.4/pipes.* ${libdir}/python3.4/socket.* ${libdir}/python3.4/ssl.* ${libdir}/python3.4/tempfile.* ${libdir}/python3.4/StringIO.* ${libdir}/python3.4/io.* ${libdir}/python3.4/_pyio.* "
-
-SUMMARY_${PN}-json="Python JSON support"
-RDEPENDS_${PN}-json="${PN}-core ${PN}-math ${PN}-re"
-FILES_${PN}-json="${libdir}/python3.4/json ${libdir}/python3.4/lib-dynload/_json.*.so "
-
-SUMMARY_${PN}-lang="Python low-level language support"
-RDEPENDS_${PN}-lang="${PN}-core"
-FILES_${PN}-lang="${libdir}/python3.4/lib-dynload/_bisect.*.so ${libdir}/python3.4/lib-dynload/_collections.*.so ${libdir}/python3.4/lib-dynload/_heapq.*.so ${libdir}/python3.4/lib-dynload/_weakref.*.so ${libdir}/python3.4/lib-dynload/_functools.*.so ${libdir}/python3.4/lib-dynload/array.*.so ${libdir}/python3.4/lib-dynload/itertools.*.so ${libdir}/python3.4/lib-dynload/operator.*.so ${libdir}/python3.4/lib-dynload/parser.*.so ${libdir}/python3.4/atexit.* ${libdir}/python3.4/bisect.* ${libdir}/python3.4/code.* ${libdir}/python3.4/codeop.* ${libdir}/python3.4/collections.* ${libdir}/python3.4/_collections_abc.* ${libdir}/python3.4/dis.* ${libdir}/python3.4/functools.* ${libdir}/python3.4/heapq.* ${libdir}/python3.4/inspect.* ${libdir}/python3.4/keyword.* ${libdir}/python3.4/opcode.* ${libdir}/python3.4/symbol.* ${libdir}/python3.4/repr.* ${libdir}/python3.4/token.* ${libdir}/python3.4/tokenize.* ${libdir}/python3.4/traceback.* ${libdir}/python3.4/weakref.* "
-
-SUMMARY_${PN}-logging="Python logging support"
-RDEPENDS_${PN}-logging="${PN}-core ${PN}-io ${PN}-lang ${PN}-pickle ${PN}-stringold"
-FILES_${PN}-logging="${libdir}/python3.4/logging "
-
-SUMMARY_${PN}-mailbox="Python mailbox format support"
-RDEPENDS_${PN}-mailbox="${PN}-core ${PN}-mime"
-FILES_${PN}-mailbox="${libdir}/python3.4/mailbox.* "
-
-SUMMARY_${PN}-math="Python math support"
-RDEPENDS_${PN}-math="${PN}-core"
-FILES_${PN}-math="${libdir}/python3.4/lib-dynload/cmath.*.so ${libdir}/python3.4/lib-dynload/math.*.so ${libdir}/python3.4/lib-dynload/_random.*.so ${libdir}/python3.4/random.* ${libdir}/python3.4/sets.* "
-
-SUMMARY_${PN}-mime="Python MIME handling APIs"
-RDEPENDS_${PN}-mime="${PN}-core ${PN}-io"
-FILES_${PN}-mime="${libdir}/python3.4/mimetools.* ${libdir}/python3.4/uu.* ${libdir}/python3.4/quopri.* ${libdir}/python3.4/rfc822.* ${libdir}/python3.4/MimeWriter.* "
-
-SUMMARY_${PN}-mmap="Python memory-mapped file support"
-RDEPENDS_${PN}-mmap="${PN}-core ${PN}-io"
-FILES_${PN}-mmap="${libdir}/python3.4/lib-dynload/mmap.*.so "
-
-SUMMARY_${PN}-multiprocessing="Python multiprocessing support"
-RDEPENDS_${PN}-multiprocessing="${PN}-core ${PN}-io ${PN}-lang ${PN}-pickle ${PN}-threading ${PN}-ctypes ${PN}-mmap"
-FILES_${PN}-multiprocessing="${libdir}/python3.4/lib-dynload/_multiprocessing.*.so ${libdir}/python3.4/multiprocessing "
-
-SUMMARY_${PN}-netclient="Python Internet Protocol clients"
-RDEPENDS_${PN}-netclient="${PN}-core ${PN}-crypt ${PN}-datetime ${PN}-io ${PN}-lang ${PN}-logging ${PN}-mime"
-FILES_${PN}-netclient="${libdir}/python3.4/*Cookie*.* ${libdir}/python3.4/base64.* ${libdir}/python3.4/cookielib.* ${libdir}/python3.4/ftplib.* ${libdir}/python3.4/gopherlib.* ${libdir}/python3.4/hmac.* ${libdir}/python3.4/httplib.* ${libdir}/python3.4/mimetypes.* ${libdir}/python3.4/nntplib.* ${libdir}/python3.4/poplib.* ${libdir}/python3.4/smtplib.* ${libdir}/python3.4/telnetlib.* ${libdir}/python3.4/urllib ${libdir}/python3.4/uuid.* ${libdir}/python3.4/rfc822.* ${libdir}/python3.4/mimetools.* "
-
-SUMMARY_${PN}-netserver="Python Internet Protocol servers"
-RDEPENDS_${PN}-netserver="${PN}-core ${PN}-netclient ${PN}-shell ${PN}-threading"
-FILES_${PN}-netserver="${libdir}/python3.4/cgi.* ${libdir}/python3.4/*HTTPServer.* ${libdir}/python3.4/SocketServer.* "
-
-SUMMARY_${PN}-numbers="Python number APIs"
-RDEPENDS_${PN}-numbers="${PN}-core ${PN}-lang ${PN}-re"
-FILES_${PN}-numbers="${libdir}/python3.4/decimal.* ${libdir}/python3.4/fractions.* ${libdir}/python3.4/numbers.* "
-
-SUMMARY_${PN}-pickle="Python serialisation/persistence support"
-RDEPENDS_${PN}-pickle="${PN}-core ${PN}-codecs ${PN}-io ${PN}-re"
-FILES_${PN}-pickle="${libdir}/python3.4/pickle.* ${libdir}/python3.4/shelve.* ${libdir}/python3.4/lib-dynload/cPickle.*.so ${libdir}/python3.4/pickletools.* "
-
-SUMMARY_${PN}-pkgutil="Python package extension utility support"
-RDEPENDS_${PN}-pkgutil="${PN}-core"
-FILES_${PN}-pkgutil="${libdir}/python3.4/pkgutil.* "
-
-SUMMARY_${PN}-pprint="Python pretty-print support"
-RDEPENDS_${PN}-pprint="${PN}-core ${PN}-io"
-FILES_${PN}-pprint="${libdir}/python3.4/pprint.* "
-
-SUMMARY_${PN}-profile="Python basic performance profiling support"
-RDEPENDS_${PN}-profile="${PN}-core ${PN}-textutils"
-FILES_${PN}-profile="${libdir}/python3.4/profile.* ${libdir}/python3.4/pstats.* ${libdir}/python3.4/cProfile.* ${libdir}/python3.4/lib-dynload/_lsprof.*.so "
-
-SUMMARY_${PN}-pydoc="Python interactive help support"
-RDEPENDS_${PN}-pydoc="${PN}-core ${PN}-lang ${PN}-stringold ${PN}-re"
-FILES_${PN}-pydoc="${bindir}/pydoc ${libdir}/python3.4/pydoc.* ${libdir}/python3.4/pydoc_data "
-
-SUMMARY_${PN}-re="Python Regular Expression APIs"
-RDEPENDS_${PN}-re="${PN}-core"
-FILES_${PN}-re="${libdir}/python3.4/re.* ${libdir}/python3.4/sre.* ${libdir}/python3.4/sre_compile.* ${libdir}/python3.4/sre_constants* ${libdir}/python3.4/sre_parse.* "
-
-SUMMARY_${PN}-readline="Python readline support"
-RDEPENDS_${PN}-readline="${PN}-core"
-FILES_${PN}-readline="${libdir}/python3.4/lib-dynload/readline.*.so ${libdir}/python3.4/rlcompleter.* "
-
-SUMMARY_${PN}-reprlib="Python alternate repr() implementation"
-RDEPENDS_${PN}-reprlib="${PN}-core"
-FILES_${PN}-reprlib="${libdir}/python3.4/reprlib.py "
-
-SUMMARY_${PN}-resource="Python resource control interface"
-RDEPENDS_${PN}-resource="${PN}-core"
-FILES_${PN}-resource="${libdir}/python3.4/lib-dynload/resource.*.so "
-
-SUMMARY_${PN}-shell="Python shell-like functionality"
-RDEPENDS_${PN}-shell="${PN}-core ${PN}-re"
-FILES_${PN}-shell="${libdir}/python3.4/cmd.* ${libdir}/python3.4/commands.* ${libdir}/python3.4/dircache.* ${libdir}/python3.4/fnmatch.* ${libdir}/python3.4/glob.* ${libdir}/python3.4/popen2.* ${libdir}/python3.4/shlex.* ${libdir}/python3.4/shutil.* "
-
-SUMMARY_${PN}-smtpd="Python Simple Mail Transport Daemon"
-RDEPENDS_${PN}-smtpd="${PN}-core ${PN}-netserver ${PN}-email ${PN}-mime"
-FILES_${PN}-smtpd="${bindir}/smtpd.* ${libdir}/python3.4/smtpd.* "
-
-SUMMARY_${PN}-sqlite3="Python Sqlite3 database support"
-RDEPENDS_${PN}-sqlite3="${PN}-core ${PN}-datetime ${PN}-lang ${PN}-crypt ${PN}-io ${PN}-threading"
-FILES_${PN}-sqlite3="${libdir}/python3.4/lib-dynload/_sqlite3.*.so ${libdir}/python3.4/sqlite3/dbapi2.* ${libdir}/python3.4/sqlite3/__init__.* ${libdir}/python3.4/sqlite3/dump.* "
-
-SUMMARY_${PN}-sqlite3-tests="Python Sqlite3 database support tests"
-RDEPENDS_${PN}-sqlite3-tests="${PN}-core ${PN}-sqlite3"
-FILES_${PN}-sqlite3-tests="${libdir}/python3.4/sqlite3/test "
-
-SUMMARY_${PN}-stringold="Python string APIs [deprecated]"
-RDEPENDS_${PN}-stringold="${PN}-core ${PN}-re"
-FILES_${PN}-stringold="${libdir}/python3.4/lib-dynload/strop.*.so ${libdir}/python3.4/string.* ${libdir}/python3.4/stringold.* "
-
-SUMMARY_${PN}-subprocess="Python subprocess support"
-RDEPENDS_${PN}-subprocess="${PN}-core ${PN}-io ${PN}-re ${PN}-fcntl ${PN}-pickle"
-FILES_${PN}-subprocess="${libdir}/python3.4/subprocess.* "
-
-SUMMARY_${PN}-syslog="Python syslog interface"
-RDEPENDS_${PN}-syslog="${PN}-core"
-FILES_${PN}-syslog="${libdir}/python3.4/lib-dynload/syslog.*.so "
-
-SUMMARY_${PN}-terminal="Python terminal controlling support"
-RDEPENDS_${PN}-terminal="${PN}-core ${PN}-io"
-FILES_${PN}-terminal="${libdir}/python3.4/pty.* ${libdir}/python3.4/tty.* "
-
-SUMMARY_${PN}-tests="Python tests"
-RDEPENDS_${PN}-tests="${PN}-core"
-FILES_${PN}-tests="${libdir}/python3.4/test "
-
-SUMMARY_${PN}-textutils="Python option parsing, text wrapping and CSV support"
-RDEPENDS_${PN}-textutils="${PN}-core ${PN}-io ${PN}-re ${PN}-stringold"
-FILES_${PN}-textutils="${libdir}/python3.4/lib-dynload/_csv.*.so ${libdir}/python3.4/csv.* ${libdir}/python3.4/optparse.* ${libdir}/python3.4/textwrap.* "
-
-SUMMARY_${PN}-threading="Python threading & synchronization support"
-RDEPENDS_${PN}-threading="${PN}-core ${PN}-lang"
-FILES_${PN}-threading="${libdir}/python3.4/_threading_local.* ${libdir}/python3.4/dummy_thread.* ${libdir}/python3.4/dummy_threading.* ${libdir}/python3.4/mutex.* ${libdir}/python3.4/threading.* ${libdir}/python3.4/Queue.* "
-
-SUMMARY_${PN}-tkinter="Python Tcl/Tk bindings"
-RDEPENDS_${PN}-tkinter="${PN}-core"
-FILES_${PN}-tkinter="${libdir}/python3.4/lib-dynload/_tkinter.*.so ${libdir}/python3.4/lib-tk ${libdir}/python3.4/tkinter "
-
-SUMMARY_${PN}-unittest="Python unit testing framework"
-RDEPENDS_${PN}-unittest="${PN}-core ${PN}-stringold ${PN}-lang ${PN}-io ${PN}-difflib ${PN}-pprint ${PN}-shell"
-FILES_${PN}-unittest="${libdir}/python3.4/unittest/ "
-
-SUMMARY_${PN}-unixadmin="Python Unix administration support"
-RDEPENDS_${PN}-unixadmin="${PN}-core"
-FILES_${PN}-unixadmin="${libdir}/python3.4/lib-dynload/nis.*.so ${libdir}/python3.4/lib-dynload/grp.*.so ${libdir}/python3.4/lib-dynload/pwd.*.so ${libdir}/python3.4/getpass.* "
-
-SUMMARY_${PN}-xml="Python basic XML support"
-RDEPENDS_${PN}-xml="${PN}-core ${PN}-elementtree ${PN}-re"
-FILES_${PN}-xml="${libdir}/python3.4/lib-dynload/pyexpat.*.so ${libdir}/python3.4/xml ${libdir}/python3.4/xmllib.* "
-
-SUMMARY_${PN}-xmlrpc="Python XML-RPC support"
-RDEPENDS_${PN}-xmlrpc="${PN}-core ${PN}-xml ${PN}-netserver ${PN}-lang"
-FILES_${PN}-xmlrpc="${libdir}/python3.4/xmlrpclib.* ${libdir}/python3.4/SimpleXMLRPCServer.* ${libdir}/python3.4/DocXMLRPCServer.* ${libdir}/python3.4/xmlrpc "
-
-SUMMARY_${PN}-modules="All Python modules"
-RDEPENDS_${PN}-modules="${PN}-2to3 ${PN}-asyncio ${PN}-audio ${PN}-codecs ${PN}-compile ${PN}-compression ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-difflib ${PN}-distutils ${PN}-doctest ${PN}-elementtree ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-reprlib ${PN}-resource ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc  "
-ALLOW_EMPTY_${PN}-modules = "1"
-
-
diff --git a/yocto-poky/meta/recipes-devtools/python/python-3.5-manifest.inc b/yocto-poky/meta/recipes-devtools/python/python-3.5-manifest.inc
new file mode 100644
index 0000000..335c3ff
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python-3.5-manifest.inc
@@ -0,0 +1,264 @@
+
+# WARNING: This file is AUTO GENERATED: Manual edits will be lost next time I regenerate the file.
+# Generator: '../../../scripts/contrib/python/generate-manifest-3.5.py' Version 20140131 (C) 2002-2010 Michael 'Mickey' Lauer <mlauer@vanille-media.de>
+# Visit the Python for Embedded Systems Site => http://www.Vanille.de/projects/python.spy
+
+ 
+
+PROVIDES+="${PN}-2to3 ${PN}-asyncio ${PN}-audio ${PN}-codecs ${PN}-compile ${PN}-compression ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-dev ${PN}-difflib ${PN}-distutils ${PN}-distutils-staticdev ${PN}-doctest ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-reprlib ${PN}-resource ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc "
+
+PACKAGES="${PN}-dbg ${PN}-2to3 ${PN}-asyncio ${PN}-audio ${PN}-codecs ${PN}-compile ${PN}-compression ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-dev ${PN}-difflib ${PN}-distutils-staticdev ${PN}-distutils ${PN}-doctest ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-reprlib ${PN}-resource ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc ${PN}-modules"
+
+SUMMARY_${PN}-2to3="Python automated Python 2 to 3 code translator"
+RDEPENDS_${PN}-2to3="${PN}-core"
+FILES_${PN}-2to3="${libdir}/python3.5/lib2to3 "
+
+SUMMARY_${PN}-asyncio="Python Asynchronous I/O, event loop, coroutines and tasks"
+RDEPENDS_${PN}-asyncio="${PN}-core"
+FILES_${PN}-asyncio="${libdir}/python3.5/asyncio "
+
+SUMMARY_${PN}-audio="Python Audio Handling"
+RDEPENDS_${PN}-audio="${PN}-core"
+FILES_${PN}-audio="${libdir}/python3.5/wave.* ${libdir}/python3.5/chunk.* ${libdir}/python3.5/sndhdr.* ${libdir}/python3.5/lib-dynload/ossaudiodev.*.so ${libdir}/python3.5/lib-dynload/audioop.*.so ${libdir}/python3.5/audiodev.* ${libdir}/python3.5/sunaudio.* ${libdir}/python3.5/sunau.* ${libdir}/python3.5/toaiff.* "
+
+SUMMARY_${PN}-codecs="Python codecs, encodings & i18n support"
+RDEPENDS_${PN}-codecs="${PN}-core ${PN}-lang"
+FILES_${PN}-codecs="${libdir}/python3.5/codecs.* ${libdir}/python3.5/encodings ${libdir}/python3.5/gettext.* ${libdir}/python3.5/locale.* ${libdir}/python3.5/lib-dynload/_locale.*.so ${libdir}/python3.5/lib-dynload/_codecs* ${libdir}/python3.5/lib-dynload/_multibytecodec.*.so ${libdir}/python3.5/lib-dynload/unicodedata.*.so ${libdir}/python3.5/stringprep.* ${libdir}/python3.5/xdrlib.* "
+
+SUMMARY_${PN}-compile="Python bytecode compilation support"
+RDEPENDS_${PN}-compile="${PN}-core"
+FILES_${PN}-compile="${libdir}/python3.5/py_compile.* ${libdir}/python3.5/compileall.* "
+
+SUMMARY_${PN}-compression="Python high-level compression support"
+RDEPENDS_${PN}-compression="${PN}-core ${PN}-codecs"
+FILES_${PN}-compression="${libdir}/python3.5/gzip.* ${libdir}/python3.5/zipfile.* ${libdir}/python3.5/tarfile.* ${libdir}/python3.5/lib-dynload/bz2.*.so "
+
+SUMMARY_${PN}-core="Python interpreter and core modules"
+RDEPENDS_${PN}-core="${PN}-lang ${PN}-re ${PN}-reprlib ${PN}-codecs ${PN}-io ${PN}-math"
+FILES_${PN}-core="${libdir}/python3.5/__future__.* ${libdir}/python3.5/_abcoll.* ${libdir}/python3.5/abc.* ${libdir}/python3.5/ast.* ${libdir}/python3.5/copy.* ${libdir}/python3.5/copyreg.* ${libdir}/python3.5/ConfigParser.* ${libdir}/python3.5/genericpath.* ${libdir}/python3.5/getopt.* ${libdir}/python3.5/linecache.* ${libdir}/python3.5/new.* ${libdir}/python3.5/os.* ${libdir}/python3.5/posixpath.* ${libdir}/python3.5/struct.* ${libdir}/python3.5/warnings.* ${libdir}/python3.5/site.* ${libdir}/python3.5/stat.* ${libdir}/python3.5/UserDict.* ${libdir}/python3.5/UserList.* ${libdir}/python3.5/UserString.* ${libdir}/python3.5/lib-dynload/binascii.*.so ${libdir}/python3.5/lib-dynload/_struct.*.so ${libdir}/python3.5/lib-dynload/time.*.so ${libdir}/python3.5/lib-dynload/xreadlines.*.so ${libdir}/python3.5/types.* ${libdir}/python3.5/platform.* ${bindir}/python* ${libdir}/python3.5/_weakrefset.* ${libdir}/python3.5/sysconfig.* ${libdir}/python3.5/_sysconfigdata.* ${libdir}/python3.5/config/Makefile ${includedir}/python${PYTHON_BINABI}/pyconfig*.h ${libdir}/python${PYTHON_MAJMIN}/collections ${libdir}/python${PYTHON_MAJMIN}/_collections_abc.* ${libdir}/python${PYTHON_MAJMIN}/_sitebuiltins.* ${libdir}/python${PYTHON_MAJMIN}/sitecustomize.py "
+
+SUMMARY_${PN}-crypt="Python basic cryptographic and hashing support"
+RDEPENDS_${PN}-crypt="${PN}-core"
+FILES_${PN}-crypt="${libdir}/python3.5/hashlib.* ${libdir}/python3.5/md5.* ${libdir}/python3.5/sha.* ${libdir}/python3.5/lib-dynload/crypt.*.so ${libdir}/python3.5/lib-dynload/_hashlib.*.so ${libdir}/python3.5/lib-dynload/_sha256.*.so ${libdir}/python3.5/lib-dynload/_sha512.*.so "
+
+SUMMARY_${PN}-ctypes="Python C types support"
+RDEPENDS_${PN}-ctypes="${PN}-core"
+FILES_${PN}-ctypes="${libdir}/python3.5/ctypes ${libdir}/python3.5/lib-dynload/_ctypes.*.so ${libdir}/python3.5/lib-dynload/_ctypes_test.*.so "
+
+SUMMARY_${PN}-curses="Python curses support"
+RDEPENDS_${PN}-curses="${PN}-core"
+FILES_${PN}-curses="${libdir}/python3.5/curses ${libdir}/python3.5/lib-dynload/_curses.*.so ${libdir}/python3.5/lib-dynload/_curses_panel.*.so "
+
+SUMMARY_${PN}-datetime="Python calendar and time support"
+RDEPENDS_${PN}-datetime="${PN}-core ${PN}-codecs"
+FILES_${PN}-datetime="${libdir}/python3.5/_strptime.* ${libdir}/python3.5/calendar.* ${libdir}/python3.5/lib-dynload/datetime.*.so "
+
+SUMMARY_${PN}-db="Python file-based database support"
+RDEPENDS_${PN}-db="${PN}-core"
+FILES_${PN}-db="${libdir}/python3.5/anydbm.* ${libdir}/python3.5/dumbdbm.* ${libdir}/python3.5/whichdb.* ${libdir}/python3.5/dbm ${libdir}/python3.5/lib-dynload/_dbm.*.so "
+
+SUMMARY_${PN}-debugger="Python debugger"
+RDEPENDS_${PN}-debugger="${PN}-core ${PN}-io ${PN}-lang ${PN}-re ${PN}-stringold ${PN}-shell ${PN}-pprint ${PN}-importlib ${PN}-pkgutil"
+FILES_${PN}-debugger="${libdir}/python3.5/bdb.* ${libdir}/python3.5/pdb.* "
+
+SUMMARY_${PN}-dev="Python development package"
+RDEPENDS_${PN}-dev="${PN}-core"
+FILES_${PN}-dev="${includedir} ${libdir}/lib*${SOLIBSDEV} ${libdir}/*.la ${libdir}/*.a ${libdir}/*.o ${libdir}/pkgconfig ${base_libdir}/*.a ${base_libdir}/*.o ${datadir}/aclocal ${datadir}/pkgconfig "
+
+SUMMARY_${PN}-difflib="Python helpers for computing deltas between objects"
+RDEPENDS_${PN}-difflib="${PN}-lang ${PN}-re"
+FILES_${PN}-difflib="${libdir}/python3.5/difflib.* "
+
+SUMMARY_${PN}-distutils="Python Distribution Utilities"
+RDEPENDS_${PN}-distutils="${PN}-core ${PN}-email"
+FILES_${PN}-distutils="${libdir}/python3.5/config ${libdir}/python3.5/distutils "
+
+SUMMARY_${PN}-distutils-staticdev="Python distribution utilities (static libraries)"
+RDEPENDS_${PN}-distutils-staticdev="${PN}-distutils"
+FILES_${PN}-distutils-staticdev="${libdir}/python3.5/config/lib*.a "
+
+SUMMARY_${PN}-doctest="Python framework for running examples in docstrings"
+RDEPENDS_${PN}-doctest="${PN}-core ${PN}-lang ${PN}-io ${PN}-re ${PN}-unittest ${PN}-debugger ${PN}-difflib"
+FILES_${PN}-doctest="${libdir}/python3.5/doctest.* "
+
+SUMMARY_${PN}-email="Python email support"
+RDEPENDS_${PN}-email="${PN}-core ${PN}-io ${PN}-re ${PN}-mime ${PN}-audio ${PN}-image ${PN}-netclient"
+FILES_${PN}-email="${libdir}/python3.5/imaplib.* ${libdir}/python3.5/email "
+
+SUMMARY_${PN}-fcntl="Python's fcntl interface"
+RDEPENDS_${PN}-fcntl="${PN}-core"
+FILES_${PN}-fcntl="${libdir}/python3.5/lib-dynload/fcntl.*.so "
+
+SUMMARY_${PN}-gdbm="Python GNU database support"
+RDEPENDS_${PN}-gdbm="${PN}-core"
+FILES_${PN}-gdbm="${libdir}/python3.5/lib-dynload/_gdbm.*.so "
+
+SUMMARY_${PN}-html="Python HTML processing support"
+RDEPENDS_${PN}-html="${PN}-core"
+FILES_${PN}-html="${libdir}/python3.5/formatter.* ${libdir}/python3.5/htmlentitydefs.* ${libdir}/python3.5/htmllib.* ${libdir}/python3.5/markupbase.* ${libdir}/python3.5/sgmllib.* ${libdir}/python3.5/HTMLParser.* "
+
+SUMMARY_${PN}-idle="Python Integrated Development Environment"
+RDEPENDS_${PN}-idle="${PN}-core ${PN}-tkinter"
+FILES_${PN}-idle="${bindir}/idle ${libdir}/python3.5/idlelib "
+
+SUMMARY_${PN}-image="Python graphical image handling"
+RDEPENDS_${PN}-image="${PN}-core"
+FILES_${PN}-image="${libdir}/python3.5/colorsys.* ${libdir}/python3.5/imghdr.* ${libdir}/python3.5/lib-dynload/imageop.*.so ${libdir}/python3.5/lib-dynload/rgbimg.*.so "
+
+SUMMARY_${PN}-importlib="Python import implementation library"
+RDEPENDS_${PN}-importlib="${PN}-core"
+FILES_${PN}-importlib="${libdir}/python3.5/importlib "
+
+SUMMARY_${PN}-io="Python low-level I/O"
+RDEPENDS_${PN}-io="${PN}-core ${PN}-math"
+FILES_${PN}-io="${libdir}/python3.5/lib-dynload/_socket.*.so ${libdir}/python3.5/lib-dynload/_io.*.so ${libdir}/python3.5/lib-dynload/_ssl.*.so ${libdir}/python3.5/lib-dynload/select.*.so ${libdir}/python3.5/lib-dynload/termios.*.so ${libdir}/python3.5/lib-dynload/cStringIO.*.so ${libdir}/python3.5/pipes.* ${libdir}/python3.5/socket.* ${libdir}/python3.5/ssl.* ${libdir}/python3.5/tempfile.* ${libdir}/python3.5/StringIO.* ${libdir}/python3.5/io.* ${libdir}/python3.5/_pyio.* "
+
+SUMMARY_${PN}-json="Python JSON support"
+RDEPENDS_${PN}-json="${PN}-core ${PN}-math ${PN}-re"
+FILES_${PN}-json="${libdir}/python3.5/json ${libdir}/python3.5/lib-dynload/_json.*.so "
+
+SUMMARY_${PN}-lang="Python low-level language support"
+RDEPENDS_${PN}-lang="${PN}-core"
+FILES_${PN}-lang="${libdir}/python3.5/lib-dynload/_bisect.*.so ${libdir}/python3.5/lib-dynload/_collections.*.so ${libdir}/python3.5/lib-dynload/_heapq.*.so ${libdir}/python3.5/lib-dynload/_weakref.*.so ${libdir}/python3.5/lib-dynload/_functools.*.so ${libdir}/python3.5/lib-dynload/array.*.so ${libdir}/python3.5/lib-dynload/itertools.*.so ${libdir}/python3.5/lib-dynload/operator.*.so ${libdir}/python3.5/lib-dynload/parser.*.so ${libdir}/python3.5/atexit.* ${libdir}/python3.5/bisect.* ${libdir}/python3.5/code.* ${libdir}/python3.5/codeop.* ${libdir}/python3.5/collections.* ${libdir}/python3.5/_collections_abc.* ${libdir}/python3.5/dis.* ${libdir}/python3.5/functools.* ${libdir}/python3.5/heapq.* ${libdir}/python3.5/inspect.* ${libdir}/python3.5/keyword.* ${libdir}/python3.5/opcode.* ${libdir}/python3.5/symbol.* ${libdir}/python3.5/repr.* ${libdir}/python3.5/token.* ${libdir}/python3.5/tokenize.* ${libdir}/python3.5/traceback.* ${libdir}/python3.5/weakref.* "
+
+SUMMARY_${PN}-logging="Python logging support"
+RDEPENDS_${PN}-logging="${PN}-core ${PN}-io ${PN}-lang ${PN}-pickle ${PN}-stringold"
+FILES_${PN}-logging="${libdir}/python3.5/logging "
+
+SUMMARY_${PN}-mailbox="Python mailbox format support"
+RDEPENDS_${PN}-mailbox="${PN}-core ${PN}-mime"
+FILES_${PN}-mailbox="${libdir}/python3.5/mailbox.* "
+
+SUMMARY_${PN}-math="Python math support"
+RDEPENDS_${PN}-math="${PN}-core"
+FILES_${PN}-math="${libdir}/python3.5/lib-dynload/cmath.*.so ${libdir}/python3.5/lib-dynload/math.*.so ${libdir}/python3.5/lib-dynload/_random.*.so ${libdir}/python3.5/random.* ${libdir}/python3.5/sets.* "
+
+SUMMARY_${PN}-mime="Python MIME handling APIs"
+RDEPENDS_${PN}-mime="${PN}-core ${PN}-io"
+FILES_${PN}-mime="${libdir}/python3.5/mimetools.* ${libdir}/python3.5/uu.* ${libdir}/python3.5/quopri.* ${libdir}/python3.5/rfc822.* ${libdir}/python3.5/MimeWriter.* "
+
+SUMMARY_${PN}-mmap="Python memory-mapped file support"
+RDEPENDS_${PN}-mmap="${PN}-core ${PN}-io"
+FILES_${PN}-mmap="${libdir}/python3.5/lib-dynload/mmap.*.so "
+
+SUMMARY_${PN}-multiprocessing="Python multiprocessing support"
+RDEPENDS_${PN}-multiprocessing="${PN}-core ${PN}-io ${PN}-lang ${PN}-pickle ${PN}-threading ${PN}-ctypes ${PN}-mmap"
+FILES_${PN}-multiprocessing="${libdir}/python3.5/lib-dynload/_multiprocessing.*.so ${libdir}/python3.5/multiprocessing "
+
+SUMMARY_${PN}-netclient="Python Internet Protocol clients"
+RDEPENDS_${PN}-netclient="${PN}-core ${PN}-crypt ${PN}-datetime ${PN}-io ${PN}-lang ${PN}-logging ${PN}-mime"
+FILES_${PN}-netclient="${libdir}/python3.5/*Cookie*.* ${libdir}/python3.5/base64.* ${libdir}/python3.5/cookielib.* ${libdir}/python3.5/ftplib.* ${libdir}/python3.5/gopherlib.* ${libdir}/python3.5/hmac.* ${libdir}/python3.5/httplib.* ${libdir}/python3.5/mimetypes.* ${libdir}/python3.5/nntplib.* ${libdir}/python3.5/poplib.* ${libdir}/python3.5/smtplib.* ${libdir}/python3.5/telnetlib.* ${libdir}/python3.5/urllib ${libdir}/python3.5/uuid.* ${libdir}/python3.5/rfc822.* ${libdir}/python3.5/mimetools.* "
+
+SUMMARY_${PN}-netserver="Python Internet Protocol servers"
+RDEPENDS_${PN}-netserver="${PN}-core ${PN}-netclient ${PN}-shell ${PN}-threading"
+FILES_${PN}-netserver="${libdir}/python3.5/cgi.* ${libdir}/python3.5/*HTTPServer.* ${libdir}/python3.5/SocketServer.* "
+
+SUMMARY_${PN}-numbers="Python number APIs"
+RDEPENDS_${PN}-numbers="${PN}-core ${PN}-lang ${PN}-re"
+FILES_${PN}-numbers="${libdir}/python3.5/decimal.* ${libdir}/python3.5/fractions.* ${libdir}/python3.5/numbers.* "
+
+SUMMARY_${PN}-pickle="Python serialisation/persistence support"
+RDEPENDS_${PN}-pickle="${PN}-core ${PN}-codecs ${PN}-io ${PN}-re"
+FILES_${PN}-pickle="${libdir}/python3.5/pickle.* ${libdir}/python3.5/shelve.* ${libdir}/python3.5/lib-dynload/cPickle.*.so ${libdir}/python3.5/pickletools.* "
+
+SUMMARY_${PN}-pkgutil="Python package extension utility support"
+RDEPENDS_${PN}-pkgutil="${PN}-core"
+FILES_${PN}-pkgutil="${libdir}/python3.5/pkgutil.* "
+
+SUMMARY_${PN}-pprint="Python pretty-print support"
+RDEPENDS_${PN}-pprint="${PN}-core ${PN}-io"
+FILES_${PN}-pprint="${libdir}/python3.5/pprint.* "
+
+SUMMARY_${PN}-profile="Python basic performance profiling support"
+RDEPENDS_${PN}-profile="${PN}-core ${PN}-textutils"
+FILES_${PN}-profile="${libdir}/python3.5/profile.* ${libdir}/python3.5/pstats.* ${libdir}/python3.5/cProfile.* ${libdir}/python3.5/lib-dynload/_lsprof.*.so "
+
+SUMMARY_${PN}-pydoc="Python interactive help support"
+RDEPENDS_${PN}-pydoc="${PN}-core ${PN}-lang ${PN}-stringold ${PN}-re"
+FILES_${PN}-pydoc="${bindir}/pydoc ${libdir}/python3.5/pydoc.* ${libdir}/python3.5/pydoc_data "
+
+SUMMARY_${PN}-re="Python Regular Expression APIs"
+RDEPENDS_${PN}-re="${PN}-core"
+FILES_${PN}-re="${libdir}/python3.5/re.* ${libdir}/python3.5/sre.* ${libdir}/python3.5/sre_compile.* ${libdir}/python3.5/sre_constants* ${libdir}/python3.5/sre_parse.* "
+
+SUMMARY_${PN}-readline="Python readline support"
+RDEPENDS_${PN}-readline="${PN}-core"
+FILES_${PN}-readline="${libdir}/python3.5/lib-dynload/readline.*.so ${libdir}/python3.5/rlcompleter.* "
+
+SUMMARY_${PN}-reprlib="Python alternate repr() implementation"
+RDEPENDS_${PN}-reprlib="${PN}-core"
+FILES_${PN}-reprlib="${libdir}/python3.5/reprlib.py "
+
+SUMMARY_${PN}-resource="Python resource control interface"
+RDEPENDS_${PN}-resource="${PN}-core"
+FILES_${PN}-resource="${libdir}/python3.5/lib-dynload/resource.*.so "
+
+SUMMARY_${PN}-shell="Python shell-like functionality"
+RDEPENDS_${PN}-shell="${PN}-core ${PN}-re"
+FILES_${PN}-shell="${libdir}/python3.5/cmd.* ${libdir}/python3.5/commands.* ${libdir}/python3.5/dircache.* ${libdir}/python3.5/fnmatch.* ${libdir}/python3.5/glob.* ${libdir}/python3.5/popen2.* ${libdir}/python3.5/shlex.* ${libdir}/python3.5/shutil.* "
+
+SUMMARY_${PN}-smtpd="Python Simple Mail Transport Daemon"
+RDEPENDS_${PN}-smtpd="${PN}-core ${PN}-netserver ${PN}-email ${PN}-mime"
+FILES_${PN}-smtpd="${bindir}/smtpd.* ${libdir}/python3.5/smtpd.* "
+
+SUMMARY_${PN}-sqlite3="Python Sqlite3 database support"
+RDEPENDS_${PN}-sqlite3="${PN}-core ${PN}-datetime ${PN}-lang ${PN}-crypt ${PN}-io ${PN}-threading"
+FILES_${PN}-sqlite3="${libdir}/python3.5/lib-dynload/_sqlite3.*.so ${libdir}/python3.5/sqlite3/dbapi2.* ${libdir}/python3.5/sqlite3/__init__.* ${libdir}/python3.5/sqlite3/dump.* "
+
+SUMMARY_${PN}-sqlite3-tests="Python Sqlite3 database support tests"
+RDEPENDS_${PN}-sqlite3-tests="${PN}-core ${PN}-sqlite3"
+FILES_${PN}-sqlite3-tests="${libdir}/python3.5/sqlite3/test "
+
+SUMMARY_${PN}-stringold="Python string APIs [deprecated]"
+RDEPENDS_${PN}-stringold="${PN}-core ${PN}-re"
+FILES_${PN}-stringold="${libdir}/python3.5/lib-dynload/strop.*.so ${libdir}/python3.5/string.* ${libdir}/python3.5/stringold.* "
+
+SUMMARY_${PN}-subprocess="Python subprocess support"
+RDEPENDS_${PN}-subprocess="${PN}-core ${PN}-io ${PN}-re ${PN}-fcntl ${PN}-pickle"
+FILES_${PN}-subprocess="${libdir}/python3.5/subprocess.* "
+
+SUMMARY_${PN}-syslog="Python syslog interface"
+RDEPENDS_${PN}-syslog="${PN}-core"
+FILES_${PN}-syslog="${libdir}/python3.5/lib-dynload/syslog.*.so "
+
+SUMMARY_${PN}-terminal="Python terminal controlling support"
+RDEPENDS_${PN}-terminal="${PN}-core ${PN}-io"
+FILES_${PN}-terminal="${libdir}/python3.5/pty.* ${libdir}/python3.5/tty.* "
+
+SUMMARY_${PN}-tests="Python tests"
+RDEPENDS_${PN}-tests="${PN}-core"
+FILES_${PN}-tests="${libdir}/python3.5/test "
+
+SUMMARY_${PN}-textutils="Python option parsing, text wrapping and CSV support"
+RDEPENDS_${PN}-textutils="${PN}-core ${PN}-io ${PN}-re ${PN}-stringold"
+FILES_${PN}-textutils="${libdir}/python3.5/lib-dynload/_csv.*.so ${libdir}/python3.5/csv.* ${libdir}/python3.5/optparse.* ${libdir}/python3.5/textwrap.* "
+
+SUMMARY_${PN}-threading="Python threading & synchronization support"
+RDEPENDS_${PN}-threading="${PN}-core ${PN}-lang"
+FILES_${PN}-threading="${libdir}/python3.5/_threading_local.* ${libdir}/python3.5/dummy_thread.* ${libdir}/python3.5/dummy_threading.* ${libdir}/python3.5/mutex.* ${libdir}/python3.5/threading.* ${libdir}/python3.5/Queue.* "
+
+SUMMARY_${PN}-tkinter="Python Tcl/Tk bindings"
+RDEPENDS_${PN}-tkinter="${PN}-core"
+FILES_${PN}-tkinter="${libdir}/python3.5/lib-dynload/_tkinter.*.so ${libdir}/python3.5/lib-tk ${libdir}/python3.5/tkinter "
+
+SUMMARY_${PN}-unittest="Python unit testing framework"
+RDEPENDS_${PN}-unittest="${PN}-core ${PN}-stringold ${PN}-lang ${PN}-io ${PN}-difflib ${PN}-pprint ${PN}-shell"
+FILES_${PN}-unittest="${libdir}/python3.5/unittest/ "
+
+SUMMARY_${PN}-unixadmin="Python Unix administration support"
+RDEPENDS_${PN}-unixadmin="${PN}-core"
+FILES_${PN}-unixadmin="${libdir}/python3.5/lib-dynload/nis.*.so ${libdir}/python3.5/lib-dynload/grp.*.so ${libdir}/python3.5/lib-dynload/pwd.*.so ${libdir}/python3.5/getpass.* "
+
+SUMMARY_${PN}-xml="Python basic XML support"
+RDEPENDS_${PN}-xml="${PN}-core ${PN}-re"
+FILES_${PN}-xml="${libdir}/python3.5/lib-dynload/_elementtree.*.so ${libdir}/python3.5/lib-dynload/pyexpat.*.so ${libdir}/python3.5/xml ${libdir}/python3.5/xmllib.* "
+
+SUMMARY_${PN}-xmlrpc="Python XML-RPC support"
+RDEPENDS_${PN}-xmlrpc="${PN}-core ${PN}-xml ${PN}-netserver ${PN}-lang"
+FILES_${PN}-xmlrpc="${libdir}/python3.5/xmlrpclib.* ${libdir}/python3.5/SimpleXMLRPCServer.* ${libdir}/python3.5/DocXMLRPCServer.* ${libdir}/python3.5/xmlrpc "
+
+SUMMARY_${PN}-modules="All Python modules"
+RDEPENDS_${PN}-modules="${PN}-2to3 ${PN}-asyncio ${PN}-audio ${PN}-codecs ${PN}-compile ${PN}-compression ${PN}-core ${PN}-crypt ${PN}-ctypes ${PN}-curses ${PN}-datetime ${PN}-db ${PN}-debugger ${PN}-difflib ${PN}-distutils ${PN}-doctest ${PN}-email ${PN}-fcntl ${PN}-gdbm ${PN}-html ${PN}-idle ${PN}-image ${PN}-importlib ${PN}-io ${PN}-json ${PN}-lang ${PN}-logging ${PN}-mailbox ${PN}-math ${PN}-mime ${PN}-mmap ${PN}-multiprocessing ${PN}-netclient ${PN}-netserver ${PN}-numbers ${PN}-pickle ${PN}-pkgutil ${PN}-pprint ${PN}-profile ${PN}-pydoc ${PN}-re ${PN}-readline ${PN}-reprlib ${PN}-resource ${PN}-shell ${PN}-smtpd ${PN}-sqlite3 ${PN}-sqlite3-tests ${PN}-stringold ${PN}-subprocess ${PN}-syslog ${PN}-terminal ${PN}-tests ${PN}-textutils ${PN}-threading ${PN}-tkinter ${PN}-unittest ${PN}-unixadmin ${PN}-xml ${PN}-xmlrpc  "
+ALLOW_EMPTY_${PN}-modules = "1"
+
+
diff --git a/yocto-poky/meta/recipes-devtools/python/python-async_0.6.2.bb b/yocto-poky/meta/recipes-devtools/python/python-async_0.6.2.bb
index 5a17a1a..ad0a617 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-async_0.6.2.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-async_0.6.2.bb
@@ -8,6 +8,8 @@
 SRC_URI[md5sum] = "9b06b5997de2154f3bc0273f80bcef6b"
 SRC_URI[sha256sum] = "ac6894d876e45878faae493b0cf61d0e28ec417334448ac0a6ea2229d8343051"
 
+UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/async/"
+
 S = "${WORKDIR}/async-${PV}"
 
 inherit setuptools
diff --git a/yocto-poky/meta/recipes-devtools/python/python-git_1.0.1.bb b/yocto-poky/meta/recipes-devtools/python/python-git_1.0.2.bb
similarity index 68%
rename from yocto-poky/meta/recipes-devtools/python/python-git_1.0.1.bb
rename to yocto-poky/meta/recipes-devtools/python/python-git_1.0.2.bb
index a78d7c8..f00f805 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-git_1.0.1.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-git_1.0.2.bb
@@ -11,13 +11,16 @@
 
 SRC_URI = "http://pypi.python.org/packages/source/G/GitPython/GitPython-${PV}.tar.gz"
 
-SRC_URI[md5sum] = "4659644b42c41e5e5170c0cd83ed6422"
-SRC_URI[sha256sum] = "9c88c17bbcae2a445ff64024ef13526224f70e35e38c33416be5ceb56ca7f760"
+SRC_URI[md5sum] = "d92d96a8da0fc77cf141d3e16084e094"
+SRC_URI[sha256sum] = "85de72556781480a38897a77de5b458ae3838b0fd589593679a1b5f34d181d84"
+
+UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/GitPython/"
+UPSTREAM_CHECK_REGEX = "/GitPython/(?P<pver>(\d+[\.\-_]*)+)"
 
 S = "${WORKDIR}/GitPython-${PV}"
 
 inherit setuptools
 
-RDEPENDS_${PN} += "python-gitdb python-lang python-io python-shell python-math python-re python-subprocess python-stringold"
+RDEPENDS_${PN} += "python-gitdb python-lang python-io python-shell python-math python-re python-subprocess python-stringold python-unixadmin"
 
 BBCLASSEXTEND = "nativesdk"
diff --git a/yocto-poky/meta/recipes-devtools/python/python-gitdb_0.6.4.bb b/yocto-poky/meta/recipes-devtools/python/python-gitdb_0.6.4.bb
index f0083bd..c82df1e 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-gitdb_0.6.4.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-gitdb_0.6.4.bb
@@ -10,6 +10,8 @@
 SRC_URI[md5sum] = "44e4366b8bdfd306b075c3a52c96ae1a"
 SRC_URI[sha256sum] = "a3ebbc27be035a2e874ed904df516e35f4a29a778a764385de09de9e0f139658"
 
+UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/gitdb/"
+
 S = "${WORKDIR}/gitdb-${PV}"
 
 inherit distutils
diff --git a/yocto-poky/meta/recipes-devtools/python/python-mako_1.0.1.bb b/yocto-poky/meta/recipes-devtools/python/python-mako_1.0.3.bb
similarity index 64%
rename from yocto-poky/meta/recipes-devtools/python/python-mako_1.0.1.bb
rename to yocto-poky/meta/recipes-devtools/python/python-mako_1.0.3.bb
index 5d42b0c..9efd700 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-mako_1.0.1.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-mako_1.0.3.bb
@@ -5,8 +5,11 @@
 
 SRC_URI = "https://pypi.python.org/packages/source/M/Mako/Mako-${PV}.tar.gz"
 
-SRC_URI[md5sum] = "9f0aafd177b039ef67b90ea350497a54"
-SRC_URI[sha256sum] = "45f0869febea59dab7efd256fb451c377cbb7947bef386ff0bb44627c31a8d1c"
+SRC_URI[md5sum] = "a78f20f6366a8a0659ce5532f8614e53"
+SRC_URI[sha256sum] = "7644bc0ee35965d2e146dde31827b8982ed70a58281085fac42869a09764d38c"
+
+UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/mako/"
+UPSTREAM_CHECK_REGEX = "/Mako/(?P<pver>(\d+[\.\-_]*)+)"
 
 S = "${WORKDIR}/Mako-${PV}"
 
diff --git a/yocto-poky/meta/recipes-devtools/python/python-native_2.7.9.bb b/yocto-poky/meta/recipes-devtools/python/python-native_2.7.11.bb
similarity index 95%
rename from yocto-poky/meta/recipes-devtools/python/python-native_2.7.9.bb
rename to yocto-poky/meta/recipes-devtools/python/python-native_2.7.11.bb
index 34f5c29..4c204a4 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-native_2.7.9.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-native_2.7.11.bb
@@ -25,7 +25,7 @@
 
 inherit native
 
-RPROVIDES += "python-distutils-native python-compression-native python-textutils-native python-codecs-native python-core-native"
+RPROVIDES += "python-distutils-native python-compression-native python-textutils-native python-codecs-native python-core-native python-unittest-native"
 
 EXTRA_OECONF_append = " --bindir=${bindir}/${PN}"
 
diff --git a/yocto-poky/meta/recipes-devtools/python/python-nose_1.3.6.bb b/yocto-poky/meta/recipes-devtools/python/python-nose_1.3.6.bb
deleted file mode 100644
index d6e8fc1..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-nose_1.3.6.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-DESCRIPTION = "nose extends the test loading and running features of unittest, \
-making it easier to write, find and run tests."
-SECTION = "devel/python"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://lgpl.txt;md5=a6f89e2100d9b6cdffcea4f398e37343"
-
-SRC_URI = "http://pypi.python.org/packages/source/n/nose/nose-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "0ca546d81ca8309080fc80cb389e7a16"
-SRC_URI[sha256sum] = "f61e0909a743eed37b1207e38a8e7b4a2fe0a82185e36f2be252ef1b3f901758"
-
-S = "${WORKDIR}/nose-${PV}"
-
-inherit setuptools
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/yocto-poky/meta/recipes-devtools/python/python-nose_1.3.7.bb b/yocto-poky/meta/recipes-devtools/python/python-nose_1.3.7.bb
new file mode 100644
index 0000000..ec6158f
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python-nose_1.3.7.bb
@@ -0,0 +1,24 @@
+SUMMARY = "Extends Python unittest to make testing easier"
+DESCRIPTION = "nose extends the test loading and running features of unittest, \
+making it easier to write, find and run tests."
+SECTION = "devel/python"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://lgpl.txt;md5=a6f89e2100d9b6cdffcea4f398e37343"
+
+SRC_URI = "http://pypi.python.org/packages/source/n/nose/nose-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "4d3ad0ff07b61373d2cefc89c5d0b20b"
+SRC_URI[sha256sum] = "f1bffef9cbc82628f6e7d7b40d7e255aefaa1adb6a1b1d26c69a8b79e6208a98"
+
+UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/nose/"
+UPSTREAM_CHECK_REGEX = "/nose/(?P<pver>(\d+[\.\-_]*)+)"
+
+S = "${WORKDIR}/nose-${PV}"
+
+inherit setuptools
+
+RDEPENDS_${PN} = "\
+  python-unittest \
+  "
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/no-host-paths.patch b/yocto-poky/meta/recipes-devtools/python/python-numpy/0001-Don-t-search-usr-and-so-on-for-libraries-by-default-.patch
similarity index 69%
rename from yocto-poky/meta/recipes-devtools/python/python-numpy/no-host-paths.patch
rename to yocto-poky/meta/recipes-devtools/python/python-numpy/0001-Don-t-search-usr-and-so-on-for-libraries-by-default-.patch
index d745036..5b134ed 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-numpy/no-host-paths.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/0001-Don-t-search-usr-and-so-on-for-libraries-by-default-.patch
@@ -1,18 +1,27 @@
-Don't search /usr and so on for libraries by default to avoid host contamination.
+From cc2ce6d8b6a3e6e2c8874896c10897034a80cd4f Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Thu, 10 Dec 2015 13:20:30 +0200
+Subject: [PATCH] Don't search /usr and so on for libraries by default to avoid
+ host contamination.
 
 Upstream-Status: Inappropriate (As the code stands, this is a hack)
 Signed-off-by: Ross Burton <ross.burton@intel.com>
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ numpy/distutils/system_info.py | 50 +++++-------------------------------------
+ 1 file changed, 6 insertions(+), 44 deletions(-)
 
 diff --git a/numpy/distutils/system_info.py b/numpy/distutils/system_info.py
-index bac90fb..a63d796 100644
+index 9dd48e2..80e197a 100644
 --- a/numpy/distutils/system_info.py
 +++ b/numpy/distutils/system_info.py
-@@ -191,41 +191,12 @@ if sys.platform == 'win32':
+@@ -204,51 +204,13 @@ if sys.platform == 'win32':
      default_x11_lib_dirs = []
      default_x11_include_dirs = []
  else:
 -    default_lib_dirs = libpaths(['/usr/local/lib', '/opt/lib', '/usr/lib',
 -                                 '/opt/local/lib', '/sw/lib'], platform_bits)
+     default_runtime_dirs = []
 -    default_include_dirs = ['/usr/local/include',
 -                            '/opt/include', '/usr/include',
 -                            # path of umfpack under macports
@@ -35,17 +44,26 @@
 -                                             '/usr/include/X11'])
 -
 -    import subprocess as sp
+-    tmp = None
 -    try:
+-        # Explicitly open/close file to avoid ResourceWarning when
+-        # tests are run in debug mode Python 3.
+-        tmp = open(os.devnull, 'w')
 -        p = sp.Popen(["gcc", "-print-multiarch"], stdout=sp.PIPE,
--                stderr=open(os.devnull, 'w'))
--    except OSError:
--        pass # gcc is not installed
+-                stderr=tmp)
+-    except (OSError, DistutilsError):
+-        # OSError if gcc is not installed, or SandboxViolation (DistutilsError
+-        # subclass) if an old setuptools bug is triggered (see gh-3160).
+-        pass
 -    else:
 -        triplet = str(p.communicate()[0].decode().strip())
 -        if p.returncode == 0:
 -            # gcc supports the "-print-multiarch" option
 -            default_x11_lib_dirs += [os.path.join("/usr/lib/", triplet)]
 -            default_lib_dirs += [os.path.join("/usr/lib/", triplet)]
+-    finally:
+-        if tmp is not None:
+-            tmp.close()
 +    default_lib_dirs = libpaths(['/deadir/lib'], platform_bits)
 +    default_include_dirs = ['/deaddir/include']
 +    default_src_dirs = ['.', '/deaddir/src']
@@ -55,3 +73,6 @@
  
  if os.path.join(sys.prefix, 'lib') not in default_lib_dirs:
      default_lib_dirs.insert(0, os.path.join(sys.prefix, 'lib'))
+-- 
+2.6.2
+
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/aarch64/_numpyconfig.h b/yocto-poky/meta/recipes-devtools/python/python-numpy/aarch64/_numpyconfig.h
index be57ac2..191e5a1 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-numpy/aarch64/_numpyconfig.h
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/aarch64/_numpyconfig.h
@@ -20,10 +20,11 @@
 #define NPY_HAVE_COMPLEX_DOUBLE 1
 #define NPY_HAVE_COMPLEX_FLOAT 1
 #define NPY_HAVE_COMPLEX_LONG_DOUBLE 1
+#define NPY_ENABLE_SEPARATE_COMPILATION 1
 #define NPY_USE_C99_FORMATS 1
 #define NPY_VISIBILITY_HIDDEN __attribute__((visibility("hidden")))
 #define NPY_ABI_VERSION 0x01000009
-#define NPY_API_VERSION 0x00000007
+#define NPY_API_VERSION 0x0000000A
 
 #ifndef __STDC_FORMAT_MACROS
 #define __STDC_FORMAT_MACROS 1
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/add-glibc-check.patch b/yocto-poky/meta/recipes-devtools/python/python-numpy/add-glibc-check.patch
new file mode 100644
index 0000000..29768f3
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/add-glibc-check.patch
@@ -0,0 +1,36 @@
+Dont punish musl for glibc's trignometeric functions problems
+additionally ensure that glibc specific macros are not used
+unconditionally
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Pending
+Index: numpy-1.10.4/numpy/core/src/private/npy_config.h
+===================================================================
+--- numpy-1.10.4.orig/numpy/core/src/private/npy_config.h
++++ numpy-1.10.4/numpy/core/src/private/npy_config.h
+@@ -75,10 +75,12 @@
+ 
+ #if defined(HAVE_FEATURES_H)
+ #include <features.h>
++#ifdef __GLIBC__
+ #define TRIG_OK __GLIBC_PREREQ(2, 16)
+ #else
+ #define TRIG_OK 0
+ #endif
++#endif
+ 
+ #if !TRIG_OK
+ #undef HAVE_CASIN
+Index: numpy-1.10.4/numpy/core/src/npymath/ieee754.c.src
+===================================================================
+--- numpy-1.10.4.orig/numpy/core/src/npymath/ieee754.c.src
++++ numpy-1.10.4/numpy/core/src/npymath/ieee754.c.src
+@@ -612,7 +612,7 @@ void npy_set_floatstatus_invalid(void)
+ }
+ 
+ 
+-#elif defined(__GLIBC__) || defined(__APPLE__) || \
++#elif defined(__linux__) || defined(__APPLE__) || \
+       defined(__CYGWIN__) || defined(__MINGW32__) || \
+       (defined(__FreeBSD__) && (__FreeBSD_version >= 502114))
+ #  include <fenv.h>
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/mips/_numpyconfig.h b/yocto-poky/meta/recipes-devtools/python/python-numpy/mips/_numpyconfig.h
index c0c4285..05d2b8b 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-numpy/mips/_numpyconfig.h
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/mips/_numpyconfig.h
@@ -8,6 +8,7 @@
 #define NPY_SIZEOF_COMPLEX_DOUBLE 16
 #define NPY_SIZEOF_LONGDOUBLE 8
 #define NPY_SIZEOF_COMPLEX_LONGDOUBLE 16
+#define NPY_ENABLE_SEPARATE_COMPILATION 1
 #define NPY_SIZEOF_PY_INTPTR_T 4
 #define NPY_SIZEOF_PY_LONG_LONG 8
 #define NPY_SIZEOF_LONGLONG 8
@@ -23,7 +24,7 @@
 #define NPY_USE_C99_FORMATS 1
 #define NPY_VISIBILITY_HIDDEN __attribute__((visibility("hidden")))
 #define NPY_ABI_VERSION 0x01000009
-#define NPY_API_VERSION 0x00000007
+#define NPY_API_VERSION 0x0000000A
 
 #ifndef __STDC_FORMAT_MACROS
 #define __STDC_FORMAT_MACROS 1
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/mips64/_numpyconfig.h b/yocto-poky/meta/recipes-devtools/python/python-numpy/mips64/_numpyconfig.h
index be57ac2..8e2b5d0 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-numpy/mips64/_numpyconfig.h
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/mips64/_numpyconfig.h
@@ -8,6 +8,7 @@
 #define NPY_SIZEOF_COMPLEX_DOUBLE 16
 #define NPY_SIZEOF_LONGDOUBLE 16
 #define NPY_SIZEOF_COMPLEX_LONGDOUBLE 32
+#define NPY_ENABLE_SEPARATE_COMPILATION 1
 #define NPY_SIZEOF_PY_INTPTR_T 8
 #define NPY_SIZEOF_PY_LONG_LONG 8
 #define NPY_SIZEOF_LONGLONG 8
@@ -23,7 +24,7 @@
 #define NPY_USE_C99_FORMATS 1
 #define NPY_VISIBILITY_HIDDEN __attribute__((visibility("hidden")))
 #define NPY_ABI_VERSION 0x01000009
-#define NPY_API_VERSION 0x00000007
+#define NPY_API_VERSION 0x0000000A
 
 #ifndef __STDC_FORMAT_MACROS
 #define __STDC_FORMAT_MACROS 1
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/mips64n32/_numpyconfig.h b/yocto-poky/meta/recipes-devtools/python/python-numpy/mips64n32/_numpyconfig.h
index be57ac2..8e2b5d0 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-numpy/mips64n32/_numpyconfig.h
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/mips64n32/_numpyconfig.h
@@ -8,6 +8,7 @@
 #define NPY_SIZEOF_COMPLEX_DOUBLE 16
 #define NPY_SIZEOF_LONGDOUBLE 16
 #define NPY_SIZEOF_COMPLEX_LONGDOUBLE 32
+#define NPY_ENABLE_SEPARATE_COMPILATION 1
 #define NPY_SIZEOF_PY_INTPTR_T 8
 #define NPY_SIZEOF_PY_LONG_LONG 8
 #define NPY_SIZEOF_LONGLONG 8
@@ -23,7 +24,7 @@
 #define NPY_USE_C99_FORMATS 1
 #define NPY_VISIBILITY_HIDDEN __attribute__((visibility("hidden")))
 #define NPY_ABI_VERSION 0x01000009
-#define NPY_API_VERSION 0x00000007
+#define NPY_API_VERSION 0x0000000A
 
 #ifndef __STDC_FORMAT_MACROS
 #define __STDC_FORMAT_MACROS 1
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/powerpc/_numpyconfig.h b/yocto-poky/meta/recipes-devtools/python/python-numpy/powerpc/_numpyconfig.h
index 73cbfb1..0f45d5b 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-numpy/powerpc/_numpyconfig.h
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/powerpc/_numpyconfig.h
@@ -8,6 +8,7 @@
 #define NPY_SIZEOF_COMPLEX_DOUBLE 16
 #define NPY_SIZEOF_LONGDOUBLE 16
 #define NPY_SIZEOF_COMPLEX_LONGDOUBLE 32
+#define NPY_ENABLE_SEPARATE_COMPILATION 1
 #define NPY_SIZEOF_PY_INTPTR_T 4
 #define NPY_SIZEOF_PY_LONG_LONG 8
 #define NPY_SIZEOF_LONGLONG 8
@@ -23,7 +24,7 @@
 #define NPY_USE_C99_FORMATS 1
 #define NPY_VISIBILITY_HIDDEN __attribute__((visibility("hidden")))
 #define NPY_ABI_VERSION 0x01000009
-#define NPY_API_VERSION 0x00000007
+#define NPY_API_VERSION 0x0000000A
 
 #ifndef __STDC_FORMAT_MACROS
 #define __STDC_FORMAT_MACROS 1
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/powerpc64/_numpyconfig.h b/yocto-poky/meta/recipes-devtools/python/python-numpy/powerpc64/_numpyconfig.h
index be57ac2..8e2b5d0 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-numpy/powerpc64/_numpyconfig.h
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/powerpc64/_numpyconfig.h
@@ -8,6 +8,7 @@
 #define NPY_SIZEOF_COMPLEX_DOUBLE 16
 #define NPY_SIZEOF_LONGDOUBLE 16
 #define NPY_SIZEOF_COMPLEX_LONGDOUBLE 32
+#define NPY_ENABLE_SEPARATE_COMPILATION 1
 #define NPY_SIZEOF_PY_INTPTR_T 8
 #define NPY_SIZEOF_PY_LONG_LONG 8
 #define NPY_SIZEOF_LONGLONG 8
@@ -23,7 +24,7 @@
 #define NPY_USE_C99_FORMATS 1
 #define NPY_VISIBILITY_HIDDEN __attribute__((visibility("hidden")))
 #define NPY_ABI_VERSION 0x01000009
-#define NPY_API_VERSION 0x00000007
+#define NPY_API_VERSION 0x0000000A
 
 #ifndef __STDC_FORMAT_MACROS
 #define __STDC_FORMAT_MACROS 1
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/remove-build-path-in-comments.patch b/yocto-poky/meta/recipes-devtools/python/python-numpy/remove-build-path-in-comments.patch
new file mode 100644
index 0000000..eb8a71a
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/remove-build-path-in-comments.patch
@@ -0,0 +1,30 @@
+From c560abff71f98a39a7401f08c2c13dad9ae7f15f Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Thu, 25 Feb 2016 01:23:32 -0500
+Subject: [PATCH] remove build path in comments
+
+It has build path in comments, so remove it.
+
+Upstream-Status: Inappropriate [openembedded specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ numpy/distutils/misc_util.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/numpy/distutils/misc_util.py b/numpy/distutils/misc_util.py
+index 345e60f..dafb068 100644
+--- a/numpy/distutils/misc_util.py
++++ b/numpy/distutils/misc_util.py
+@@ -2254,7 +2254,7 @@ def generate_config_py(target):
+     from distutils.dir_util import mkpath
+     mkpath(os.path.dirname(target))
+     f = open(target, 'w')
+-    f.write('# This file is generated by %s\n' % (os.path.abspath(sys.argv[0])))
++    f.write('# This file is generated by %s\n' % (os.path.abspath(sys.argv[0]).replace(os.path.abspath('../'),'')))
+     f.write('# It contains system_info results at the time of building this package.\n')
+     f.write('__all__ = ["get_info","show"]\n\n')
+     for k, i in system_info.saved_results.items():
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy/x86-64/_numpyconfig.h b/yocto-poky/meta/recipes-devtools/python/python-numpy/x86-64/_numpyconfig.h
index be57ac2..b330361 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-numpy/x86-64/_numpyconfig.h
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy/x86-64/_numpyconfig.h
@@ -5,9 +5,11 @@
 #define NPY_SIZEOF_FLOAT 4
 #define NPY_SIZEOF_COMPLEX_FLOAT 8
 #define NPY_SIZEOF_DOUBLE 8
+#define NPY_SIZEOF_OFF_T 8
 #define NPY_SIZEOF_COMPLEX_DOUBLE 16
 #define NPY_SIZEOF_LONGDOUBLE 16
 #define NPY_SIZEOF_COMPLEX_LONGDOUBLE 32
+#define NPY_ENABLE_SEPARATE_COMPILATION 1
 #define NPY_SIZEOF_PY_INTPTR_T 8
 #define NPY_SIZEOF_PY_LONG_LONG 8
 #define NPY_SIZEOF_LONGLONG 8
@@ -23,7 +25,7 @@
 #define NPY_USE_C99_FORMATS 1
 #define NPY_VISIBILITY_HIDDEN __attribute__((visibility("hidden")))
 #define NPY_ABI_VERSION 0x01000009
-#define NPY_API_VERSION 0x00000007
+#define NPY_API_VERSION 0x0000000A
 
 #ifndef __STDC_FORMAT_MACROS
 #define __STDC_FORMAT_MACROS 1
diff --git a/yocto-poky/meta/recipes-devtools/python/python-numpy_1.7.0.bb b/yocto-poky/meta/recipes-devtools/python/python-numpy_1.10.4.bb
similarity index 82%
rename from yocto-poky/meta/recipes-devtools/python/python-numpy_1.7.0.bb
rename to yocto-poky/meta/recipes-devtools/python/python-numpy_1.10.4.bb
index 81cdfde..8a562dc 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-numpy_1.7.0.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-numpy_1.10.4.bb
@@ -1,11 +1,12 @@
 SUMMARY = "A sophisticated Numeric Processing Package for Python"
 SECTION = "devel/python"
 LICENSE = "PSF"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=f87832d854acbade6e9f5c601c8b30b1"
-PR = "r1"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=9f4e88b5748e8313caaf33d081ce65a3"
 
 SRC_URI = "${SOURCEFORGE_MIRROR}/numpy/numpy-${PV}.tar.gz \
-           file://no-host-paths.patch \
+           file://0001-Don-t-search-usr-and-so-on-for-libraries-by-default-.patch \
+           file://remove-build-path-in-comments.patch \
+           file://add-glibc-check.patch \
            ${CONFIGFILESURI} "
 
 CONFIGFILESURI ?= ""
@@ -70,8 +71,8 @@
 
 FILES_${PN}-staticdev += "${PYTHON_SITEPACKAGES_DIR}/numpy/core/lib/*.a"
 
-SRC_URI[md5sum] = "4fa54e40b6a243416f0248123b6ec332"
-SRC_URI[sha256sum] = "f4fa70b7edbab65ee6432eb63743f5489f1919c614632b20b2fb45aa7e682ac6"
+SRC_URI[md5sum] = "90bb9034652cefbada19cf7d141a6a61"
+SRC_URI[sha256sum] = "f7f91842056a7cf680b0eaf8cefc5e46c69e2521e651128d2e6aaaccec8652ae"
 
 # install what is needed for numpy.test()
 RDEPENDS_${PN} = "python-unittest \
@@ -92,6 +93,8 @@
                   python-email \
                   python-subprocess \
                   python-compression \
+                  python-ctypes \
+                  python-threading \
 "
 
 RDEPENDS_${PN}_class-native = ""
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pexpect_3.3.bb b/yocto-poky/meta/recipes-devtools/python/python-pexpect_4.0.1.bb
similarity index 60%
rename from yocto-poky/meta/recipes-devtools/python/python-pexpect_3.3.bb
rename to yocto-poky/meta/recipes-devtools/python/python-pexpect_4.0.1.bb
index cd80aeb..7f142a3 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-pexpect_3.3.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-pexpect_4.0.1.bb
@@ -2,11 +2,13 @@
 HOMEPAGE = "http://pexpect.readthedocs.org/"
 SECTION = "devel/python"
 LICENSE = "ISC"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=c25d9a0770ba69a9965acc894e9f3644"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=66c2378a96b307d56bfb3a9e58edafa8"
 
 SRC_URI = "https://pypi.python.org/packages/source/p/pexpect/pexpect-${PV}.tar.gz"
-SRC_URI[md5sum] = "0de72541d3f1374b795472fed841dce8"
-SRC_URI[sha256sum] = "dfea618d43e83cfff21504f18f98019ba520f330e4142e5185ef7c73527de5ba"
+SRC_URI[md5sum] = "056df81e6ca7081f1015b4b147b977b7"
+SRC_URI[sha256sum] = "232795ebcaaf2e120396dbbaa3a129eda51757eeaae1911558f4ef8ee414fc6c"
+
+UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/pexpect"
 
 S = "${WORKDIR}/pexpect-${PV}"
 
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pycurl/no-static-link.patch b/yocto-poky/meta/recipes-devtools/python/python-pycurl/no-static-link.patch
index c5349ee..212779c 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-pycurl/no-static-link.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python-pycurl/no-static-link.patch
@@ -1,12 +1,12 @@
 Upstream-Status: Pending
 
 Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
-
-Index: pycurl-7.19.3.1/setup.py
-===================================================================
---- pycurl-7.19.3.1.orig/setup.py	2014-07-16 12:57:24.065346887 +0000
-+++ pycurl-7.19.3.1/setup.py	2014-07-16 12:57:53.057347678 +0000
-@@ -147,7 +147,7 @@
+Signed-off-by: Maxin B. John <maxin.john@intel.com>
+---
+diff -Naur pycurl-7.19.5.2-orig/setup.py pycurl-7.19.5.2/setup.py
+--- pycurl-7.19.5.2-orig/setup.py	2015-11-02 15:42:24.000000000 +0200
++++ pycurl-7.19.5.2/setup.py	2015-11-02 17:59:36.121527273 +0200
+@@ -154,7 +154,7 @@
          optbuf = ''
          sslhintbuf = ''
          errtext = ''
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pycurl_7.19.5.1.bb b/yocto-poky/meta/recipes-devtools/python/python-pycurl_7.21.5.bb
similarity index 60%
rename from yocto-poky/meta/recipes-devtools/python/python-pycurl_7.19.5.1.bb
rename to yocto-poky/meta/recipes-devtools/python/python-pycurl_7.21.5.bb
index 0d0effe..7b41f6d 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-pycurl_7.19.5.1.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-pycurl_7.21.5.bb
@@ -2,9 +2,9 @@
 HOMEPAGE = "http://pycurl.sourceforge.net/"
 SECTION = "devel/python"
 LICENSE = "LGPLv2.1+ | MIT"
-LIC_FILES_CHKSUM = "file://README.rst;beginline=166;endline=181;md5=57e5ab0c0f964533fc59d93dec5695bb \
+LIC_FILES_CHKSUM = "file://README.rst;beginline=166;endline=182;md5=a84a1caa65b89d4584b693d3680062fb \
                     file://COPYING-LGPL;md5=3579a9fd0221d49a237aaa33492f988c \
-                    file://COPYING-MIT;md5=e8200955c773b2a0fd6cea36ea5e87be"
+                    file://COPYING-MIT;md5=b7e434aeb228ed731c00bcf177e79b19"
 
 DEPENDS = "curl python"
 RDEPENDS_${PN} = "python-core curl"
@@ -15,18 +15,12 @@
   file://no-static-link.patch \
 "
 
-SRC_URI[archive.md5sum] = "f44cd54256d7a643ab7b16e3f409b26b"
-SRC_URI[archive.sha256sum] = "6e9770f80459757f73bd71af82fbb29cd398b38388cdf1beab31ea91a331bc6c"
+SRC_URI[archive.md5sum] = "bca7bf47320082588db544ced2ba8717"
+SRC_URI[archive.sha256sum] = "8a1e0eb55573388275a1d6c2534ca4cfca5d7fa772b99b505c08fa149b27aed0"
 S = "${WORKDIR}/${SRCNAME}-${PV}"
 
 inherit distutils
 
-# need to export these variables for python-config to work
-export BUILD_SYS
-export HOST_SYS
-export STAGING_INCDIR
-export STAGING_LIBDIR
-
 BBCLASSEXTEND = "native"
 
 # Ensure the docstrings are generated as make clean will remove them
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygobject/0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch b/yocto-poky/meta/recipes-devtools/python/python-pygobject/0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch
new file mode 100644
index 0000000..a391f7e
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python-pygobject/0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch
@@ -0,0 +1,41 @@
+From 5e5350d730f85957a42c6d846d347d080e7dd996 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 23 Oct 2015 12:40:34 +0300
+Subject: [PATCH] configure.ac: add sysroot path to GI_DATADIR; don't set
+ introspection scanner and compiler paths
+
+Upstream-Status: Pending [review on oe-core maillist]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ configure.ac | 8 +-------
+ 1 file changed, 1 insertion(+), 7 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 2c0cfbd..cfcb3bf 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -194,7 +194,7 @@ PKG_CHECK_MODULES(GI,
+     gobject-introspection-1.0 >= introspection_required_version
+ )
+ 
+-GI_DATADIR=$($PKG_CONFIG --variable=gidatadir gobject-introspection-1.0)
++GI_DATADIR=$PKG_CONFIG_SYSROOT_DIR$($PKG_CONFIG --variable=gidatadir gobject-introspection-1.0)
+ AC_SUBST(GI_DATADIR)
+ 
+ if test "$enable_cairo" != no; then
+@@ -219,12 +219,6 @@ AC_ARG_WITH(common,
+     with_common=yes)
+ AM_CONDITIONAL(WITH_COMMON, test "$with_common" = "yes")
+ 
+-INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
+-INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
+-
+-AC_SUBST(INTROSPECTION_SCANNER)
+-AC_SUBST(INTROSPECTION_COMPILER)
+-
+ # compiler warnings, errors, required cflags, and code coverage support
+ GNOME_COMPILE_WARNINGS([maximum])
+ AC_MSG_CHECKING(for Gnome code coverage support)
+-- 
+2.1.4
+
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygobject/obsolete_automake_macros.patch b/yocto-poky/meta/recipes-devtools/python/python-pygobject/obsolete_automake_macros.patch
deleted file mode 100644
index c259112..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygobject/obsolete_automake_macros.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-Upstream-Status: Accepted [https://bugzilla.gnome.org/show_bug.cgi?id=691101]
-
-Signed-off-by: Marko Lindqvist <cazfi74@gmail.com>
-diff -Nurd pygobject-2.27.91/configure.ac pygobject-2.27.91/configure.ac
---- pygobject-2.27.91/configure.ac	2011-02-23 22:14:37.000000000 +0200
-+++ pygobject-2.27.91/configure.ac	2013-01-03 05:13:44.034949954 +0200
-@@ -35,7 +35,7 @@
- AC_DEFINE(PYGOBJECT_MICRO_VERSION, pygobject_micro_version, [pygobject micro version])
- AC_SUBST(PYGOBJECT_MICRO_VERSION, pygobject_micro_version)
-
--AM_CONFIG_HEADER(config.h)
-+AC_CONFIG_HEADERS(config.h)
- m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES(yes)])
- AM_INIT_AUTOMAKE(foreign)
- AM_MAINTAINER_MODE
-@@ -82,7 +82,6 @@
- m4_ifdef([LT_OUTPUT], [LT_OUTPUT])
- AC_ISC_POSIX
- AC_PROG_CC
--AM_PROG_CC_STDC
- AM_PROG_CC_C_O
-
- # check that we have the minimum version of python necisary to build
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygobject_2.28.3.bb b/yocto-poky/meta/recipes-devtools/python/python-pygobject_2.28.3.bb
deleted file mode 100644
index 81d37b4..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygobject_2.28.3.bb
+++ /dev/null
@@ -1,53 +0,0 @@
-SUMMARY = "Python GObject bindings"
-SECTION = "devel/python"
-LICENSE = "LGPLv2.1"
-
-RECIPE_NO_UPDATE_REASON = "Newer versions of python-pygobject depend on gobject-introspection which doesn't cross-compile"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
-DEPENDS = "python python-pygobject-native libffi glib-2.0"
-DEPENDS_class-native = "python-native libffi-native glib-2.0-native"
-RDEPENDS_class-native = ""
-
-MAJ_VER = "${@d.getVar('PV',1).split('.')[0]}.${@d.getVar('PV',1).split('.')[1]}"
-
-SRC_URI = "${GNOME_MIRROR}/pygobject/${MAJ_VER}/pygobject-${PV}.tar.bz2 \
-           file://obsolete_automake_macros.patch \
-"
-
-# libtool-native doesn't have fixinstall.patch applied which means
-# that libs get relinked at installation time. This triggers a 
-# relinking along the lines of:
-# gcc -L/tmp/foo/media/build1/poky/build/tmp/sysroots/x86_64-linux/usr/lib -lpyglib-2.0-python -o .libs/_glib.so
-# where /tmp/foo is DESTDIR and pyglib-2.0-python may be installed/reinstalled
-# at the same time as the gcc command runs.
-# If this happens between the handoff between gcc and ld, you can see:
-# /bin/ld: cannot find -lpyglib-2.0-python
-# Adding a dependency rule like  install-pyglibLTLIBRARIES: install-libLTLIBRARIES
-# would be ideal but automake can't cope with that without manually 
-# defining the whole function. Give up and disable parallel make in native builds.
-PARALLEL_MAKEINST_class-native = ""
-
-SRC_URI[md5sum] = "aa64900b274c4661a5c32e52922977f9"
-SRC_URI[sha256sum] = "7da88c169a56efccc516cebd9237da3fe518a343095a664607b368fe21df95b6"
-S = "${WORKDIR}/pygobject-${PV}"
-
-EXTRA_OECONF += "--disable-introspection"
-
-inherit autotools distutils-base pkgconfig
-
-# necessary to let the call for python-config succeed
-export BUILD_SYS
-export HOST_SYS
-export STAGING_INCDIR
-export STAGING_LIBDIR
-
-PACKAGES += "${PN}-lib"
-
-RDEPENDS_${PN} += "python-textutils"
-
-FILES_${PN} = "${libdir}/python*"
-FILES_${PN}-lib = "${libdir}/lib*.so.*"
-FILES_${PN}-dev += "${bindir} ${datadir}"
-
-BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygobject_3.18.2.bb b/yocto-poky/meta/recipes-devtools/python/python-pygobject_3.18.2.bb
new file mode 100644
index 0000000..a9871fe
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python-pygobject_3.18.2.bb
@@ -0,0 +1,25 @@
+SUMMARY = "Python GObject bindings"
+SECTION = "devel/python"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
+
+inherit autotools pkgconfig gnomebase distutils-base gobject-introspection
+
+DEPENDS += "python glib-2.0 gnome-common"
+
+SRCNAME="pygobject"
+SRC_URI = " \
+    http://ftp.gnome.org/pub/GNOME/sources/${SRCNAME}/${@gnome_verdir("${PV}")}/${SRCNAME}-${PV}.tar.xz \
+    file://0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch \
+"
+
+SRC_URI[md5sum] = "0a956f3e785e23b0f136832f2e57a862"
+SRC_URI[sha256sum] = "2a3cad1517916b74e131e6002c3824361aee0671ffb0d55ded119477fc1c2c5f"
+
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+BBCLASSEXTEND = "native"
+
+EXTRA_OECONF = "--disable-cairo --with-python=python2.7"
+
+RDEPENDS_${PN} += "python-setuptools python-importlib"
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygtk/acinclude.m4 b/yocto-poky/meta/recipes-devtools/python/python-pygtk/acinclude.m4
deleted file mode 100644
index 53518fb..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygtk/acinclude.m4
+++ /dev/null
@@ -1,90 +0,0 @@
-## this one is commonly used with AM_PATH_PYTHONDIR ...
-dnl AM_CHECK_PYMOD(MODNAME [,SYMBOL [,ACTION-IF-FOUND [,ACTION-IF-NOT-FOUND]]])
-dnl Check if a module containing a given symbol is visible to python.
-AC_DEFUN(AM_CHECK_PYMOD,
-[AC_REQUIRE([AM_PATH_PYTHON])
-py_mod_var=`echo $1['_']$2 | sed 'y%./+-%__p_%'`
-AC_MSG_CHECKING(for ifelse([$2],[],,[$2 in ])python module $1)
-AC_CACHE_VAL(py_cv_mod_$py_mod_var, [
-ifelse([$2],[], [prog="
-import sys
-try:
-        import $1
-except ImportError:
-        sys.exit(1)
-except:
-        sys.exit(0)
-sys.exit(0)"], [prog="
-import $1
-$1.$2"])
-if $PYTHON -c "$prog" 1>&AC_FD_CC 2>&AC_FD_CC
-  then
-    eval "py_cv_mod_$py_mod_var=yes"
-  else
-    eval "py_cv_mod_$py_mod_var=no"
-  fi
-])
-py_val=`eval "echo \`echo '$py_cv_mod_'$py_mod_var\`"`
-if test "x$py_val" != xno; then
-  AC_MSG_RESULT(yes)
-  ifelse([$3], [],, [$3
-])dnl
-else
-  AC_MSG_RESULT(no)
-  ifelse([$4], [],, [$4
-])dnl
-fi
-])
-
-dnl a macro to check for ability to create python extensions
-dnl  AM_CHECK_PYTHON_HEADERS([ACTION-IF-POSSIBLE], [ACTION-IF-NOT-POSSIBLE])
-dnl function also defines PYTHON_INCLUDES
-AC_DEFUN([AM_CHECK_PYTHON_HEADERS],
-[AC_REQUIRE([AM_PATH_PYTHON])
-AC_MSG_CHECKING(for headers required to compile python extensions)
-dnl deduce PYTHON_INCLUDES
-AC_ARG_WITH(python-includes,
-	[  --with-python-includes=DIR  path to Python includes], py_exec_prefix=$withval)
-if test x$py_exec_prefix != x; then
-PYTHON_INCLUDES="-I${py_exec_prefix}/include/python${PYTHON_VERSION}"
-else
-py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
-py_exec_prefix=`$PYTHON -c "import sys; print sys.exec_prefix"`
-PYTHON_INCLUDES="-I${py_prefix}/include/python${PYTHON_VERSION}"
-if test "$py_prefix" != "$py_exec_prefix"; then
-  PYTHON_INCLUDES="$PYTHON_INCLUDES -I${py_exec_prefix}/include/python${PYTHON_VERSION}"
-fi
-fi
-AC_SUBST(PYTHON_INCLUDES)
-dnl check if the headers exist:
-save_CPPFLAGS="$CPPFLAGS"
-CPPFLAGS="$CPPFLAGS $PYTHON_INCLUDES"
-AC_TRY_CPP([#include <Python.h>],dnl
-[AC_MSG_RESULT(found)
-$1],dnl
-[AC_MSG_RESULT(not found)
-$2])
-CPPFLAGS="$save_CPPFLAGS"
-])
-
-dnl
-dnl JH_ADD_CFLAG(FLAG)
-dnl checks whether the C compiler supports the given flag, and if so, adds
-dnl it to $CFLAGS.  If the flag is already present in the list, then the
-dnl check is not performed.
-AC_DEFUN([JH_ADD_CFLAG],
-[
-case " $CFLAGS " in
-*@<:@\	\ @:>@$1@<:@\	\ @:>@*)
-  ;;
-*)
-  save_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS $1"
-  AC_MSG_CHECKING([whether [$]CC understands $1])
-  AC_TRY_COMPILE([], [], [jh_has_option=yes], [jh_has_option=no])
-  AC_MSG_RESULT($jh_has_option)
-  if test $jh_has_option = no; then
-    CFLAGS="$save_CFLAGS"
-  fi
-  ;;
-esac])
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygtk/add-gtk-types.defs-into-gdk.c-dependence.patch b/yocto-poky/meta/recipes-devtools/python/python-pygtk/add-gtk-types.defs-into-gdk.c-dependence.patch
deleted file mode 100644
index df0f9cd..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygtk/add-gtk-types.defs-into-gdk.c-dependence.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-Upstream-Status: Submitted
-
-add gtk-types.defs into gdk.c dependence
-
-gdk.c depends on gtk-types.defs but
-gdk/Makefile.am miss this. This will cause
-build error sometimes when built
-with multi-jobbing, so add gtk-types.defs into
-gdk.c dependence.
-
-Signed-off-by: Song.Li <Song.Li@windriver.com>
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
----
- gtk/Makefile.am |    2 +-
- 1 files changed, 1 insertions(+), 1 deletions(-)
-
-diff --git a/gtk/Makefile.am b/gtk/Makefile.am
-index 7bb5d0c..4a88351 100644
---- a/gtk/Makefile.am
-+++ b/gtk/Makefile.am
-@@ -214,7 +214,7 @@ gtkunixprint.defs: $(GTKUNIXPRINT_DEFS) Makefile
- gtkunixprint-types.defs: $(GTKUNIXPRINT_TYPES_DEFS) Makefile
- 	$(CREATEDEFS) $@ $(GTKUNIXPRINT_TYPES_DEFS)
- 
--gdk.c: gdk-types.defs gdk.defs $(GDK_OVERRIDES)
-+gdk.c: gdk-types.defs gtk-types.defs gdk.defs $(GDK_OVERRIDES)
- gtk.c: gdk-types.defs gtk-types.defs gtk.defs gdk-types.defs $(GTK_OVERRIDES)
- _gtk_la_CFLAGS = $(PYCAIRO_CFLAGS) $(GTK_CFLAGS)
- _gtk_la_LDFLAGS = $(common_ldflags) -export-symbols-regex init_gtk
--- 
-1.7.4
-
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch b/yocto-poky/meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch
deleted file mode 100644
index 16c0e8e..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-
-Index: pygtk-2.24.0/gtk/gtkunixprint.override
-===================================================================
---- pygtk-2.24.0.orig/gtk/gtkunixprint.override
-+++ pygtk-2.24.0/gtk/gtkunixprint.override
-@@ -102,11 +102,6 @@ _wrap_gtk_print_job_get_surface(PyGObjec
-     if (pyg_error_check(&error))
-         return NULL;
- 
--#if PYCAIRO_VERSION_HEX >= 0x1010600
--    return PycairoSurface_FromSurface(cairo_surface_reference(surface), NULL);
--#else
--    return PycairoSurface_FromSurface(cairo_surface_reference(surface), NULL, NULL);
--#endif
- }
- %%
- override gtk_print_job_send kwargs
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygtk/fix-pygtk-2.0.pc.patch b/yocto-poky/meta/recipes-devtools/python/python-pygtk/fix-pygtk-2.0.pc.patch
deleted file mode 100644
index b615654..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygtk/fix-pygtk-2.0.pc.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-Index: pygtk-2.24.0/pygtk-2.0.pc.in
-===================================================================
---- pygtk-2.24.0.orig/pygtk-2.0.pc.in
-+++ pygtk-2.24.0/pygtk-2.0.pc.in
-@@ -1,5 +1,6 @@
- prefix=@prefix@
- exec_prefix=@exec_prefix@
-+libdir=@libdir@
- includedir=@includedir@
- datarootdir=@datarootdir@
- datadir=@datadir@
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygtk/nodocs.patch b/yocto-poky/meta/recipes-devtools/python/python-pygtk/nodocs.patch
deleted file mode 100644
index f07309a..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygtk/nodocs.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-Index: pygtk-2.17.0/Makefile.am
-===================================================================
---- pygtk-2.17.0.orig/Makefile.am
-+++ pygtk-2.17.0/Makefile.am
-@@ -4,7 +4,7 @@ if BUILD_GTK
-   GTK_SUBDIR = gtk
- endif
- 
--SUBDIRS = . $(GTK_SUBDIR) examples tests docs
-+SUBDIRS = . $(GTK_SUBDIR) examples tests
- 
- PLATFORM_VERSION = 2.0
- 
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch b/yocto-poky/meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch
deleted file mode 100644
index 833038e..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-Upstream-Status: Pending
-
-Index: pygtk-2.10.4/gtk/__init__.py
-===================================================================
---- pygtk-2.10.4.orig/gtk/__init__.py	2007-11-27 19:27:05.000000000 -0300
-+++ pygtk-2.10.4/gtk/__init__.py	2007-11-27 19:28:22.000000000 -0300
-@@ -78,7 +78,8 @@
- 
- keysyms = LazyModule('keysyms', locals())
- 
--_init()
-+if not hasattr(sys.modules['__main__'], 'python_launcher_enabled'):
-+    _init()
- 
- # CAPI
- _PyGtk_API = _gtk._PyGtk_API
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4 b/yocto-poky/meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4
deleted file mode 100644
index 53518fb..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4
+++ /dev/null
@@ -1,90 +0,0 @@
-## this one is commonly used with AM_PATH_PYTHONDIR ...
-dnl AM_CHECK_PYMOD(MODNAME [,SYMBOL [,ACTION-IF-FOUND [,ACTION-IF-NOT-FOUND]]])
-dnl Check if a module containing a given symbol is visible to python.
-AC_DEFUN(AM_CHECK_PYMOD,
-[AC_REQUIRE([AM_PATH_PYTHON])
-py_mod_var=`echo $1['_']$2 | sed 'y%./+-%__p_%'`
-AC_MSG_CHECKING(for ifelse([$2],[],,[$2 in ])python module $1)
-AC_CACHE_VAL(py_cv_mod_$py_mod_var, [
-ifelse([$2],[], [prog="
-import sys
-try:
-        import $1
-except ImportError:
-        sys.exit(1)
-except:
-        sys.exit(0)
-sys.exit(0)"], [prog="
-import $1
-$1.$2"])
-if $PYTHON -c "$prog" 1>&AC_FD_CC 2>&AC_FD_CC
-  then
-    eval "py_cv_mod_$py_mod_var=yes"
-  else
-    eval "py_cv_mod_$py_mod_var=no"
-  fi
-])
-py_val=`eval "echo \`echo '$py_cv_mod_'$py_mod_var\`"`
-if test "x$py_val" != xno; then
-  AC_MSG_RESULT(yes)
-  ifelse([$3], [],, [$3
-])dnl
-else
-  AC_MSG_RESULT(no)
-  ifelse([$4], [],, [$4
-])dnl
-fi
-])
-
-dnl a macro to check for ability to create python extensions
-dnl  AM_CHECK_PYTHON_HEADERS([ACTION-IF-POSSIBLE], [ACTION-IF-NOT-POSSIBLE])
-dnl function also defines PYTHON_INCLUDES
-AC_DEFUN([AM_CHECK_PYTHON_HEADERS],
-[AC_REQUIRE([AM_PATH_PYTHON])
-AC_MSG_CHECKING(for headers required to compile python extensions)
-dnl deduce PYTHON_INCLUDES
-AC_ARG_WITH(python-includes,
-	[  --with-python-includes=DIR  path to Python includes], py_exec_prefix=$withval)
-if test x$py_exec_prefix != x; then
-PYTHON_INCLUDES="-I${py_exec_prefix}/include/python${PYTHON_VERSION}"
-else
-py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
-py_exec_prefix=`$PYTHON -c "import sys; print sys.exec_prefix"`
-PYTHON_INCLUDES="-I${py_prefix}/include/python${PYTHON_VERSION}"
-if test "$py_prefix" != "$py_exec_prefix"; then
-  PYTHON_INCLUDES="$PYTHON_INCLUDES -I${py_exec_prefix}/include/python${PYTHON_VERSION}"
-fi
-fi
-AC_SUBST(PYTHON_INCLUDES)
-dnl check if the headers exist:
-save_CPPFLAGS="$CPPFLAGS"
-CPPFLAGS="$CPPFLAGS $PYTHON_INCLUDES"
-AC_TRY_CPP([#include <Python.h>],dnl
-[AC_MSG_RESULT(found)
-$1],dnl
-[AC_MSG_RESULT(not found)
-$2])
-CPPFLAGS="$save_CPPFLAGS"
-])
-
-dnl
-dnl JH_ADD_CFLAG(FLAG)
-dnl checks whether the C compiler supports the given flag, and if so, adds
-dnl it to $CFLAGS.  If the flag is already present in the list, then the
-dnl check is not performed.
-AC_DEFUN([JH_ADD_CFLAG],
-[
-case " $CFLAGS " in
-*@<:@\	\ @:>@$1@<:@\	\ @:>@*)
-  ;;
-*)
-  save_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS $1"
-  AC_MSG_CHECKING([whether [$]CC understands $1])
-  AC_TRY_COMPILE([], [], [jh_has_option=yes], [jh_has_option=no])
-  AC_MSG_RESULT($jh_has_option)
-  if test $jh_has_option = no; then
-    CFLAGS="$save_CFLAGS"
-  fi
-  ;;
-esac])
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygtk/update-dependences-of-defs.c.patch b/yocto-poky/meta/recipes-devtools/python/python-pygtk/update-dependences-of-defs.c.patch
deleted file mode 100644
index 3ed954e..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygtk/update-dependences-of-defs.c.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From dc024e9079bbffbb44436ba3e70a758ebad5520f Mon Sep 17 00:00:00 2001
-From: "Song.Li" <Song.Li@windriver.com>
-Date: Sat, 5 Jan 2013 14:55:59 +0800
-Subject: [PATCH] update dependences of defs.c in Makefile.am
-
-In gtk/Makefile.am, defs.c should dependes on gdk-types.defs and
-gtk-types.defs, otherwise it fails occasionally when parallel compile.
-The error message:
-"IOError: [Errno 2] No such file or directory: 'gtk-types.defs'"
-
-Add them to dependences of defs.c to fix this issue.
-
-Upstream-Status: Submitted
-https://bugzilla.gnome.org/show_bug.cgi?id=702706
-
-Signed-off-by: Song.Li <Song.Li@windriver.com>
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
-
----
- gtk/Makefile.am |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/gtk/Makefile.am b/gtk/Makefile.am
-index 7bb5d0c..91826cb 100644
---- a/gtk/Makefile.am
-+++ b/gtk/Makefile.am
-@@ -289,7 +289,7 @@ if HAVE_GIO_TYPES_DEFS
- extra_codegen_args += --register $(PYGOBJECT_DEFSDIR)/gio-types.defs
- endif
- 
--.defs.c: 
-+.defs.c: gdk-types.defs gtk-types.defs
- 	($(PYTHON) $(CODEGENDIR)/codegen.py \
- 	   $(PYGTK_CODEGEN_DEFINES) \
- 	    -I $(srcdir) \
--- 
-1.7.9.5
-
diff --git a/yocto-poky/meta/recipes-devtools/python/python-pygtk_2.24.0.bb b/yocto-poky/meta/recipes-devtools/python/python-pygtk_2.24.0.bb
deleted file mode 100644
index 79b3110..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-pygtk_2.24.0.bb
+++ /dev/null
@@ -1,55 +0,0 @@
-SUMMARY = "Python bindings for the GTK+ UI toolkit"
-SECTION = "devel/python"
-# needs gtk+ 2.17.x
-DEPENDS = "gtk+ libglade python-pycairo python-pygobject"
-RDEPENDS_${PN} = "python-shell python-pycairo python-pygobject"
-PROVIDES = "python-pygtk2"
-SRCNAME = "pygtk"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
-
-PR = "r1"
-
-SRC_URI = "ftp://ftp.gnome.org/pub/gnome/sources/pygtk/2.24/${SRCNAME}-${PV}.tar.bz2 \
-           file://add-gtk-types.defs-into-gdk.c-dependence.patch \
-           file://fix-gtkunixprint.patch \
-           file://prevent_to_get_display_during_import.patch \
-           file://nodocs.patch \
-	   file://fix-pygtk-2.0.pc.patch \
-           file://acinclude.m4 \
-           file://update-dependences-of-defs.c.patch"
-
-SRC_URI[md5sum] = "a1051d5794fd7696d3c1af6422d17a49"
-SRC_URI[sha256sum] = "cd1c1ea265bd63ff669e92a2d3c2a88eb26bcd9e5363e0f82c896e649f206912"
-
-S = "${WORKDIR}/${SRCNAME}-${PV}"
-
-EXTRA_OECONF = "--disable-docs --with-python-includes=${STAGING_INCDIR}/../"
-
-inherit autotools pkgconfig distutils-base distro_features_check
-
-ANY_OF_DISTRO_FEATURES = "${GTK2DISTROFEATURES}"
-
-do_configure_prepend() {
-	install -m 0644 ${WORKDIR}/acinclude.m4 ${S}/
-	sed -i \
-		-e s:'`$PKG_CONFIG --variable defsdir pygobject-2.0`':\"${STAGING_DATADIR}/pygobject/2.0/defs\":g \
-		-e s:'`$PKG_CONFIG --variable=pygtkincludedir pygobject-2.0`':\"${STAGING_INCDIR}/pygtk-2.0\":g \
-		-e s:'`$PKG_CONFIG --variable=datadir pygobject-2.0`':\"${STAGING_DATADIR}\":g \
-		-e s:'`$PKG_CONFIG --variable codegendir pygobject-2.0`':\"${STAGING_DATADIR}/pygobject/2.0/codegen\":g \
-		-e s:'`$PKG_CONFIG --variable=fixxref pygobject-2.0`':\"${STAGING_DATADIR}/pygobject/xsl/fixxref.py\":g \
-		${S}/configure.ac
-}
-
-# dirty fix #2: fix build system paths leaking in
-do_install_append() {
-	sed -i -e '1s|^#!.*python|#!/usr/bin/env python|' ${D}${bindir}/pygtk-demo
-}
-
-PACKAGES =+ "${PN}-demo"
-FILES_${PN}-demo = " ${bindir}/pygtk-demo ${libdir}/pygtk "
-RDEPENDS_${PN}-demo = "python-pygtk python-stringold python-lang"
-
-# todo: revamp packaging, package demo seperatly
-FILES_${PN}-dev += " ${libdir}/pygtk/2.0 ${bindir}/pygtk-* ${datadir}/pygtk/2.0"
-
diff --git a/yocto-poky/meta/recipes-devtools/python/python-scons-native_2.3.6.bb b/yocto-poky/meta/recipes-devtools/python/python-scons-native_2.4.1.bb
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/python/python-scons-native_2.3.6.bb
rename to yocto-poky/meta/recipes-devtools/python/python-scons-native_2.4.1.bb
diff --git a/yocto-poky/meta/recipes-devtools/python/python-scons_2.3.6.bb b/yocto-poky/meta/recipes-devtools/python/python-scons_2.3.6.bb
deleted file mode 100644
index c4ad7d3..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-scons_2.3.6.bb
+++ /dev/null
@@ -1,14 +0,0 @@
-SUMMARY = "Software Construction tool (make/autotools replacement)"
-SECTION = "devel/python"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=23bc1530c55e9f0d1b709056bcea237d"
-SRCNAME = "scons"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/scons/scons-${PV}.tar.gz"
-
-SRC_URI[md5sum] = "9c6a1c3c716cbe5f16515f163c91d928"
-SRC_URI[sha256sum] = "98adaa351d8f4e4068a5bf1894bdd7f85b390c8c3f80d437cf8bb266012404df"
-
-S = "${WORKDIR}/${SRCNAME}-${PV}"
-
-inherit distutils
diff --git a/yocto-poky/meta/recipes-devtools/python/python-scons_2.4.1.bb b/yocto-poky/meta/recipes-devtools/python/python-scons_2.4.1.bb
new file mode 100644
index 0000000..096cf5c
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python-scons_2.4.1.bb
@@ -0,0 +1,22 @@
+SUMMARY = "Software Construction tool (make/autotools replacement)"
+SECTION = "devel/python"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=23bc1530c55e9f0d1b709056bcea237d"
+SRCNAME = "scons"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/scons/scons-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "9a0ddf33d9839f04380e0fae87cc4b40"
+SRC_URI[sha256sum] = "8fc4f42928c69bcbb33e1be94b646f2c700b659693fabc778c192d4d22f753a7"
+
+UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/scons/files/scons/"
+UPSTREAM_CHECK_REGEX = "/scons/(?P<pver>(\d+[\.\-_]*)+)/"
+
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+inherit distutils
+
+RDEPENDS_${PN} = "\
+  python-fcntl \
+  python-io \
+  "
diff --git a/yocto-poky/meta/recipes-devtools/python/python-setuptools.inc b/yocto-poky/meta/recipes-devtools/python/python-setuptools.inc
new file mode 100644
index 0000000..0917e88
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python-setuptools.inc
@@ -0,0 +1,21 @@
+SUMMARY = "Download, build, install, upgrade, and uninstall Python packages"
+HOMEPAGE = "https://pypi.python.org/pypi/setuptools"
+SECTION = "devel/python"
+LICENSE = "PSF | ZPL-2.0"
+
+LIC_FILES_CHKSUM = "file://setup.py;beginline=78;endline=78;md5=8a314270dd7a8dbca741775415f1716e"
+
+SRCNAME = "setuptools"
+
+SRC_URI = "http://pypi.python.org/packages/source/s/${SRCNAME}/${SRCNAME}-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "c5a7d90c1e0acf8c4ec5c2bf31bc25b5"
+SRC_URI[sha256sum] = "214bf29933f47cf25e6faa569f710731728a07a19cae91ea64f826051f68a8cf"
+
+UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/setuptools"
+
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+do_install_prepend() {
+    install -d ${D}/${libdir}/${PYTHON_DIR}/site-packages
+}
diff --git a/yocto-poky/meta/recipes-devtools/python/python-setuptools_18.2.bb b/yocto-poky/meta/recipes-devtools/python/python-setuptools_18.2.bb
deleted file mode 100644
index 1de2b2e..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-setuptools_18.2.bb
+++ /dev/null
@@ -1,46 +0,0 @@
-SUMMARY = "Downloads, builds, installs, upgrades, and uninstalls Python packages"
-HOMEPAGE = "https://pypi.python.org/pypi/setuptools"
-SECTION = "devel/python"
-LICENSE = "Python-2.0 | ZPL-2.0"
-LIC_FILES_CHKSUM = "file://setup.py;beginline=78;endline=78;md5=8a314270dd7a8dbca741775415f1716e"
-
-SRCNAME = "setuptools"
-
-PROVIDES = "python-distribute"
-
-DEPENDS += "python"
-DEPENDS_class-native += "python-native"
-
-inherit distutils
-
-SRC_URI = "https://pypi.python.org/packages/source/s/setuptools/setuptools-${PV}.tar.gz"
-SRC_URI[md5sum] = "52b4e48939ef311d7204f8fe940764f4"
-SRC_URI[sha256sum] = "0994a58df27ea5dc523782a601357a2198b7493dcc99a30d51827a23585b5b1d"
-
-S = "${WORKDIR}/${SRCNAME}-${PV}"
-
-
-DISTUTILS_INSTALL_ARGS += "--install-lib=${D}${libdir}/${PYTHON_DIR}/site-packages"
-
-do_install_prepend() {
-    install -d ${D}/${libdir}/${PYTHON_DIR}/site-packages
-}
-
-RDEPENDS_${PN} = "\
-  python-stringold \
-  python-email \
-  python-shell \
-  python-distutils \
-  python-compression \
-"
-
-RDEPENDS_${PN}_class-native = "\
-  python-distutils \
-  python-compression \
-"
-
-RREPLACES_${PN} = "python-distribute"
-RPROVIDES_${PN} = "python-distribute"
-RCONFLICTS_${PN} = "python-distribute"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/yocto-poky/meta/recipes-devtools/python/python-setuptools_19.4.bb b/yocto-poky/meta/recipes-devtools/python/python-setuptools_19.4.bb
new file mode 100644
index 0000000..c172039
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python-setuptools_19.4.bb
@@ -0,0 +1,38 @@
+require python-setuptools.inc
+
+PROVIDES = "python-distribute"
+
+DEPENDS += "python"
+DEPENDS_class-native += "python-native"
+
+inherit distutils
+
+DISTUTILS_INSTALL_ARGS += "--install-lib=${D}${libdir}/${PYTHON_DIR}/site-packages"
+
+RDEPENDS_${PN} = "\
+  python-stringold \
+  python-email \
+  python-shell \
+  python-distutils \
+  python-compression \
+  python-pkgutil \
+  python-plistlib \
+  python-numbers \
+  python-html \
+  python-netserver \
+  python-ctypes \
+  python-subprocess \
+  python-unittest \
+  python-compile \
+"
+
+RDEPENDS_${PN}_class-native = "\
+  python-distutils \
+  python-compression \
+"
+
+RREPLACES_${PN} = "python-distribute"
+RPROVIDES_${PN} = "python-distribute"
+RCONFLICTS_${PN} = "python-distribute"
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/yocto-poky/meta/recipes-devtools/python/python-smartpm/smart-add-for-rpm-ignoresize-check.patch b/yocto-poky/meta/recipes-devtools/python/python-smartpm/smart-add-for-rpm-ignoresize-check.patch
index 8a27f25..fe98d07 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-smartpm/smart-add-for-rpm-ignoresize-check.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python-smartpm/smart-add-for-rpm-ignoresize-check.patch
@@ -17,14 +17,15 @@
  smart/backends/rpm/pm.py | 4 ++++
  1 file changed, 4 insertions(+)
 
-diff --git a/smart/backends/rpm/pm.py b/smart/backends/rpm/pm.py
-index 5da9ee6..f0488ec 100644
---- a/smart/backends/rpm/pm.py
-+++ b/smart/backends/rpm/pm.py
-@@ -241,6 +241,10 @@ class RPMPackageManager(PackageManager):
-         except AttributeError:
-             probfilter |= rpm.RPMPROB_FILTER_IGNOREARCH
- 
+Index: git/smart/backends/rpm/pm.py
+===================================================================
+--- git.orig/smart/backends/rpm/pm.py
++++ git/smart/backends/rpm/pm.py
+@@ -233,6 +233,11 @@ class RPMPackageManager(PackageManager):
+         if sysconf.get("rpm-order"):
+             ts.order()
+         probfilter = rpm.RPMPROB_FILTER_OLDPACKAGE
++
 +        if sysconf.get("rpm-ignoresize", False):
 +            probfilter |= rpm.RPMPROB_FILTER_DISKNODES
 +            probfilter |= rpm.RPMPROB_FILTER_DISKSPACE
@@ -32,6 +33,3 @@
          if force or reinstall:
              probfilter |= rpm.RPMPROB_FILTER_REPLACEPKG
              probfilter |= rpm.RPMPROB_FILTER_REPLACEOLDFILES
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/python/python-smartpm/smart-rpm4-fixes.patch b/yocto-poky/meta/recipes-devtools/python/python-smartpm/smart-rpm4-fixes.patch
deleted file mode 100644
index 708ffe6..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python-smartpm/smart-rpm4-fixes.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-
-This patch checks for rpm5 related functions in order to allow rpm4 
-to work correctly. Currently the rpm4 archscore and filter work
-differently enough that they need to be changed.
-
-Upstream-Status: Inappropriate [OE-Core Specific]
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-
-Index: smart-1.4.1/smart/backends/rpm/base.py
-===================================================================
---- smart-1.4.1.orig/smart/backends/rpm/base.py
-+++ smart-1.4.1/smart/backends/rpm/base.py
-@@ -338,10 +338,14 @@ class RPMObsoletes(Depends):
- 
- _SCOREMAP = {}
- def getArchScore(arch, _sm=_SCOREMAP):
--    if arch not in _sm:
--        score = rpm.archscore(arch)
--        _sm[arch] = score
--    return _sm.get(arch, 0)
-+    try:
-+        rpm.platformscore(arch)
-+        if arch not in _sm:
-+            score = rpm.archscore(arch)
-+            _sm[arch] = score
-+        return _sm.get(arch, 0)
-+    except AttributeError:
-+        return 1
- 
- # TODO: Embed color into nameprovides and obsoletes relations.
- _COLORMAP = {"noarch": 0, "x86_64": 2, "ppc64": 2, "s390x": 2, "sparc64": 2}
-Index: smart-1.4.1/smart/backends/rpm/pm.py
-===================================================================
---- smart-1.4.1.orig/smart/backends/rpm/pm.py
-+++ smart-1.4.1/smart/backends/rpm/pm.py
-@@ -235,6 +235,12 @@ class RPMPackageManager(PackageManager):
-         if sysconf.get("rpm-order"):
-             ts.order()
-         probfilter = rpm.RPMPROB_FILTER_OLDPACKAGE
-+        try:
-+            # Test for RPM5 function
-+            rpm.platformscore("")
-+        except AttributeError:
-+            probfilter |= rpm.RPMPROB_FILTER_IGNOREARCH
-+
-         if force or reinstall:
-             probfilter |= rpm.RPMPROB_FILTER_REPLACEPKG
-             probfilter |= rpm.RPMPROB_FILTER_REPLACEOLDFILES
diff --git a/yocto-poky/meta/recipes-devtools/python/python-smartpm_git.bb b/yocto-poky/meta/recipes-devtools/python/python-smartpm_git.bb
index d6c378b..d9a908d 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-smartpm_git.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-smartpm_git.bb
@@ -19,7 +19,6 @@
           file://smart-channelsdir.patch \
           file://smart-attempt.patch \
           file://smart-attempt-fix.patch \
-          file://smart-rpm4-fixes.patch \
           file://smart-add-for-rpm-ignoresize-check.patch \
           file://smart-already-installed-message.patch \
           file://smart-set-noprogress-for-pycurl.patch \
@@ -128,8 +127,6 @@
 
 FILES_smartpm = "${bindir}/smart"
 
-FILES_${PN}-dbg += "${libdir}/python*/site-packages/smart/backends/rpm/.debug"
-
 FILES_${PN}-backend-rpm = "${libdir}/python*/site-packages/smart/backends/rpm"
 
 FILES_${PN}-interface-qt4 = "${libdir}/python*/site-packages/smart/interfaces/qt4"
diff --git a/yocto-poky/meta/recipes-devtools/python/python-smmap_0.9.0.bb b/yocto-poky/meta/recipes-devtools/python/python-smmap_0.9.0.bb
index b658be8..5f9cf45 100644
--- a/yocto-poky/meta/recipes-devtools/python/python-smmap_0.9.0.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python-smmap_0.9.0.bb
@@ -11,6 +11,9 @@
 SRC_URI[md5sum] = "d7932d5ace206bf4ae15198cf36fb6ab"
 SRC_URI[sha256sum] = "0e2b62b497bd5f0afebc002eda4d90df9d209c30ef257e8673c90a6b5c119d62"
 
+UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/smmap/"
+UPSTREAM_CHECK_REGEX = "/smmap/(?P<pver>(\d+[\.\-_]*)+)"
+
 S = "${WORKDIR}/smmap-${PV}"
 
 inherit setuptools
diff --git a/yocto-poky/meta/recipes-devtools/python/python.inc b/yocto-poky/meta/recipes-devtools/python/python.inc
index 4d428f3..f4818c6 100644
--- a/yocto-poky/meta/recipes-devtools/python/python.inc
+++ b/yocto-poky/meta/recipes-devtools/python/python.inc
@@ -5,19 +5,21 @@
 # bump this on every change in contrib/python/generate-manifest-2.7.py
 INC_PR = "r1"
 
-LIC_FILES_CHKSUM = "file://LICENSE;md5=dff3d00f049545862992d2d097831a13"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=dd98d01d471fac8d8dbdd975229dba03"
 
 SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz"
 
-SRC_URI[md5sum] = "38d530f7efc373d64a8fb1637e3baaa7"
-SRC_URI[sha256sum] = "90d27e14ea7e03570026850e2e50ba71ad20b7eb31035aada1cf3def8f8d4916"
+SRC_URI[md5sum] = "1dbcc848b4cd8399a8199d000f9f823c"
+SRC_URI[sha256sum] = "962b4c45af50124ea61f11a30deb4342fc0bc21126790fa1d7f6c79809413f46"
+
+# python recipe is actually python 2.x
+# also, exclude pre-releases for both python 2.x and 3.x
+UPSTREAM_CHECK_REGEX = "[Pp]ython-(?P<pver>2(\.\d+)+).tar"
 
 PYTHON_MAJMIN = "2.7"
 
 inherit autotools
 
-PYTHONLSBOPTS_linuxstdbase = "ac_cv_sizeof_off_t=8"
-
 EXTRA_OECONF = "\
   --with-threads \
   --with-pymalloc \
diff --git a/yocto-poky/meta/recipes-devtools/python/python/add-CROSSPYTHONPATH-for-PYTHON_FOR_BUILD.patch b/yocto-poky/meta/recipes-devtools/python/python/add-CROSSPYTHONPATH-for-PYTHON_FOR_BUILD.patch
new file mode 100644
index 0000000..a97ff6b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python/add-CROSSPYTHONPATH-for-PYTHON_FOR_BUILD.patch
@@ -0,0 +1,28 @@
+configure.ac: add CROSSPYTHONPATH into PYTHONPATH for PYTHON_FOR_BUILD
+
+When building x86->x86 the system will try to execute .so and related items
+from the default PYTHONPATH.  This will fail if the target CPU contains
+instructions that the host CPU does not have, add CROSSPYTHONPATH
+into PYTHONPATH so we can prepend the list to find correct libs.
+
+Upstream-Status: Inappropriate [OE-Core integration specific]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+Index: Python-2.7.11/configure.ac
+===================================================================
+--- Python-2.7.11.orig/configure.ac
++++ Python-2.7.11/configure.ac
+@@ -33,7 +33,7 @@ if test "$cross_compiling" = yes; then
+ 	    AC_MSG_ERROR([python$PACKAGE_VERSION interpreter not found])
+ 	fi
+         AC_MSG_RESULT($interp)
+-	PYTHON_FOR_BUILD='_PYTHON_PROJECT_BASE=$(abs_builddir) _PYTHON_HOST_PLATFORM=$(_PYTHON_HOST_PLATFORM) PYTHONPATH=$(shell test -f pybuilddir.txt && echo $(abs_builddir)/`cat pybuilddir.txt`:)$(srcdir)/Lib:$(srcdir)/Lib/$(PLATDIR) '$interp
++	PYTHON_FOR_BUILD='_PYTHON_PROJECT_BASE=$(abs_builddir) _PYTHON_HOST_PLATFORM=$(_PYTHON_HOST_PLATFORM) PYTHONPATH=$(CROSSPYTHONPATH):$(shell test -f pybuilddir.txt && echo $(abs_builddir)/`cat pybuilddir.txt`:)$(srcdir)/Lib:$(srcdir)/Lib/plat-$(MACHDEP) '$interp
+     fi
+ elif test "$cross_compiling" = maybe; then
+     AC_MSG_ERROR([Cross compiling required --host=HOST-TUPLE and --build=ARCH])
diff --git a/yocto-poky/meta/recipes-devtools/python/python/avoid_warning_about_tkinter.patch b/yocto-poky/meta/recipes-devtools/python/python/avoid_warning_about_tkinter.patch
index 208c57c..3347321 100644
--- a/yocto-poky/meta/recipes-devtools/python/python/avoid_warning_about_tkinter.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python/avoid_warning_about_tkinter.patch
@@ -4,6 +4,7 @@
 
 Upstream-Status: Inappropriate [distribution]
 
+Also simply disable the tk module since its not in DEPENDS.
 Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
 
 Index: Python-2.7.2/setup.py
@@ -23,3 +24,16 @@
  
          return missing
  
+diff --git Python-3.5.1.orig/setup.py Python-3.5.1/setup.py
+index b4633b9..d7588c0 100644
+--- Python-3.5.1.orig/setup.py
++++ Python-3.5.1/setup.py
+@@ -1536,7 +1536,7 @@ class PyBuildExt(build_ext):
+         self.extensions.extend(exts)
+ 
+         # Call the method for detecting whether _tkinter can be compiled
+-        self.detect_tkinter(inc_dirs, lib_dirs)
++        # self.detect_tkinter(inc_dirs, lib_dirs)
+ 
+         # tkinter module will not be avalaible as yocto
+         # doesn't have tk integrated (yet)
diff --git a/yocto-poky/meta/recipes-devtools/python/python/check-if-target-is-64b-not-host.patch b/yocto-poky/meta/recipes-devtools/python/python/check-if-target-is-64b-not-host.patch
index 2b62db3..e6d6c65 100644
--- a/yocto-poky/meta/recipes-devtools/python/python/check-if-target-is-64b-not-host.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python/check-if-target-is-64b-not-host.patch
@@ -11,11 +11,11 @@
 
 Upstream-Status: Pending
 
-Index: Python-2.7.2/setup.py
+Index: Python-2.7.11/setup.py
 ===================================================================
---- Python-2.7.2.orig/setup.py	2012-03-25 01:10:41.540163187 +0200
-+++ Python-2.7.2/setup.py	2012-03-25 01:26:06.092539990 +0200
-@@ -23,6 +23,21 @@
+--- Python-2.7.11.orig/setup.py
++++ Python-2.7.11/setup.py
+@@ -35,6 +35,21 @@ COMPILED_WITH_PYDEBUG = ('--with-pydebug
  # This global variable is used to hold the list of modules to be disabled.
  disabled_module_list = []
  
@@ -37,16 +37,16 @@
  def add_dir_to_list(dirlist, dir):
      """Add the directory 'dir' to the list 'dirlist' (at the front) if
      1) 'dir' is not already in 'dirlist'
-@@ -628,7 +643,7 @@
+@@ -716,7 +731,7 @@ class PyBuildExt(build_ext):
          exts.append( Extension('audioop', ['audioop.c']) )
  
          # Disabled on 64-bit platforms
--        if sys.maxint != 9223372036854775807L:
+-        if sys.maxsize != 9223372036854775807L:
 +        if not target_is_64bit_platform():
              # Operations on images
              exts.append( Extension('imageop', ['imageop.c']) )
          else:
-@@ -1418,7 +1433,7 @@
+@@ -1545,7 +1560,7 @@ class PyBuildExt(build_ext):
                  missing.append('_codecs_%s' % loc)
  
          # Dynamic loading module
@@ -54,4 +54,4 @@
 +        if not target_is_64bit_platform():
              # This requires sizeof(int) == sizeof(long) == sizeof(char*)
              dl_inc = find_file('dlfcn.h', [], inc_dirs)
-             if (dl_inc is not None) and (platform not in ['atheos']):
+             if (dl_inc is not None) and (host_platform not in ['atheos']):
diff --git a/yocto-poky/meta/recipes-devtools/python/python3-native_3.4.3.bb b/yocto-poky/meta/recipes-devtools/python/python3-native_3.5.1.bb
similarity index 86%
rename from yocto-poky/meta/recipes-devtools/python/python3-native_3.4.3.bb
rename to yocto-poky/meta/recipes-devtools/python/python3-native_3.5.1.bb
index 464ff05..7bad11a 100644
--- a/yocto-poky/meta/recipes-devtools/python/python3-native_3.4.3.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python3-native_3.5.1.bb
@@ -1,7 +1,7 @@
 require recipes-devtools/python/python.inc
 
 PR = "${INC_PR}.0"
-PYTHON_MAJMIN = "3.4"
+PYTHON_MAJMIN = "3.5"
 DISTRO_SRC_URI ?= "file://sitecustomize.py"
 DISTRO_SRC_URI_linuxstdbase = ""
 SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz \
@@ -22,16 +22,19 @@
 file://0001-h2py-Fix-issue-13032-where-it-fails-with-UnicodeDeco.patch \
 file://sysroot-include-headers.patch \
 file://unixccompiler.patch \
-file://makerace.patch \
 ${DISTRO_SRC_URI} \
 file://sysconfig.py-add-_PYTHON_PROJECT_SRC.patch \
 file://setup.py-check-cross_compiling-when-get-FLAGS.patch \
+file://0001-Do-not-use-the-shell-version-of-python-config-that-w.patch \
 "
-SRC_URI[md5sum] = "7d092d1bba6e17f0d9bd21b49e441dd5"
-SRC_URI[sha256sum] = "b5b3963533768d5fc325a4d7a6bd6f666726002d696f1d399ec06b043ea996b8"
+SRC_URI[md5sum] = "e9ea6f2623fffcdd871b7b19113fde80"
+SRC_URI[sha256sum] = "c6d57c0c366d9060ab6c0cdf889ebf3d92711d466cc0119c441dbf2746f725c9"
 
 LIC_FILES_CHKSUM = "file://LICENSE;md5=dd98d01d471fac8d8dbdd975229dba03"
 
+# exclude pre-releases for both python 2.x and 3.x
+UPSTREAM_CHECK_REGEX = "[Pp]ython-(?P<pver>\d+(\.\d+)+).tar"
+
 S = "${WORKDIR}/Python-${PV}"
 
 EXTRANATIVEPATH += "bzip2-native"
diff --git a/yocto-poky/meta/recipes-devtools/python/python3-pip_6.1.1.bb b/yocto-poky/meta/recipes-devtools/python/python3-pip_8.0.0.bb
similarity index 61%
rename from yocto-poky/meta/recipes-devtools/python/python3-pip_6.1.1.bb
rename to yocto-poky/meta/recipes-devtools/python/python3-pip_8.0.0.bb
index 7bfc30e..834ecda 100644
--- a/yocto-poky/meta/recipes-devtools/python/python3-pip_6.1.1.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python3-pip_8.0.0.bb
@@ -2,7 +2,7 @@
 sHOMEPAGEsss = "https://pypi.python.org/pypi/pip"
 SECTION = "devel/python"
 LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=45665b53032c02b35e29ddab8e61fa91"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=25fba45109565f87de20bae85bc39452"
 
 SRCNAME = "pip"
 DEPENDS += "python3 python3-setuptools-native"
@@ -10,8 +10,10 @@
 SRC_URI = " \
   http://pypi.python.org/packages/source/p/${SRCNAME}/${SRCNAME}-${PV}.tar.gz \
 "
-SRC_URI[md5sum] = "6b19e0a934d982a5a4b798e957cb6d45"
-SRC_URI[sha256sum] = "89f3b626d225e08e7f20d85044afa40f612eb3284484169813dc2d0631f2a556"
+SRC_URI[md5sum] = "5601c4323464add1482291634142894d"
+SRC_URI[sha256sum] = "90112b296152f270cb8dddcd19b7b87488d9e002e8cf622e14c4da9c2f6319b1"
+
+UPSTREAM_CHECK_URI = "https://pypi.python.org/pypi/pip"
 
 S = "${WORKDIR}/${SRCNAME}-${PV}"
 
@@ -26,7 +28,13 @@
 # Use setuptools site.py instead, avoid shared state issue
 do_install_append() {
     rm ${D}/${libdir}/${PYTHON_DIR}/site-packages/site.py
-    rm ${D}/${libdir}/${PYTHON_DIR}/site-packages/__pycache__/site.cpython-34.pyc
+    rm ${D}/${libdir}/${PYTHON_DIR}/site-packages/__pycache__/site.cpython-*.pyc
+
+    # Install as pip3 and leave pip2 as default
+    rm ${D}/${bindir}/pip
+
+    # Installed eggs need to be passed directly to the interpreter via a pth file
+    echo "./${SRCNAME}-${PV}-py${PYTHON_BASEVERSION}.egg" > ${D}${PYTHON_SITEPACKAGES_DIR}/${SRCNAME}-${PV}.pth
 }
 
 RDEPENDS_${PN} = "\
diff --git a/yocto-poky/meta/recipes-devtools/python/python3-setuptools_18.2.bb b/yocto-poky/meta/recipes-devtools/python/python3-setuptools_18.2.bb
deleted file mode 100644
index dc0ac80..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python3-setuptools_18.2.bb
+++ /dev/null
@@ -1,55 +0,0 @@
-SUMMARY = "Download, build, install, upgrade, and uninstall Python packages"
-HOMEPAGE = "http://packages.python.org/setuptools"
-SECTION = "devel/python"
-LICENSE = "PSF"
-LIC_FILES_CHKSUM = "file://setup.py;beginline=78;endline=78;md5=8a314270dd7a8dbca741775415f1716e"
-
-SRCNAME = "setuptools"
-DEPENDS += "python3"
-DEPENDS_class-native += "python3-native"
-
-SRC_URI = " \
-  http://pypi.python.org/packages/source/s/${SRCNAME}/${SRCNAME}-${PV}.tar.gz \
-"
-SRC_URI[md5sum] = "52b4e48939ef311d7204f8fe940764f4"
-SRC_URI[sha256sum] = "0994a58df27ea5dc523782a601357a2198b7493dcc99a30d51827a23585b5b1d"
-
-S = "${WORKDIR}/${SRCNAME}-${PV}"
-
-inherit distutils3
-
-DISTUTILS_INSTALL_ARGS += "--install-lib=${D}${libdir}/${PYTHON_DIR}/site-packages"
-
-do_install_prepend() {
-    install -d ${D}/${libdir}/${PYTHON_DIR}/site-packages
-}
-#
-#  The installer puts the wrong path in the setuptools.pth file.  Correct it.
-#
-do_install_append() {
-    rm ${D}${PYTHON_SITEPACKAGES_DIR}/setuptools.pth
-    mv ${D}${bindir}/easy_install ${D}${bindir}/easy3_install
-    echo "./${SRCNAME}-${PV}-py${PYTHON_BASEVERSION}.egg" > ${D}${PYTHON_SITEPACKAGES_DIR}/setuptools.pth
-}
-
-RDEPENDS_${PN} = "\
-  python3-distutils \
-  python3-compression \
-"
-RDEPENDS_${PN}_class-target = "\
-  python3-ctypes \
-  python3-distutils \
-  python3-email \
-  python3-importlib \
-  python3-numbers \
-  python3-compression \
-  python3-shell \
-  python3-subprocess \
-  python3-textutils \
-  python3-pkgutil \
-  python3-threading \
-  python3-misc \
-  python3-unittest \
-  python3-xml \
-"
-BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/python/python3-setuptools_19.4.bb b/yocto-poky/meta/recipes-devtools/python/python3-setuptools_19.4.bb
new file mode 100644
index 0000000..fb2931c
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python3-setuptools_19.4.bb
@@ -0,0 +1,37 @@
+require python-setuptools.inc
+
+DEPENDS += "python3"
+DEPENDS_class-native += "python3-native"
+
+inherit distutils3
+
+DISTUTILS_INSTALL_ARGS += "--install-lib=${D}${libdir}/${PYTHON_DIR}/site-packages"
+
+# The installer puts the wrong path in the setuptools.pth file.  Correct it.
+do_install_append() {
+    rm ${D}${PYTHON_SITEPACKAGES_DIR}/setuptools.pth
+    mv ${D}${bindir}/easy_install ${D}${bindir}/easy3_install
+    echo "./${SRCNAME}-${PV}-py${PYTHON_BASEVERSION}.egg" > ${D}${PYTHON_SITEPACKAGES_DIR}/setuptools.pth
+}
+
+RDEPENDS_${PN} = "\
+  python3-distutils \
+  python3-compression \
+"
+RDEPENDS_${PN}_class-target = "\
+  python3-ctypes \
+  python3-distutils \
+  python3-email \
+  python3-importlib \
+  python3-numbers \
+  python3-compression \
+  python3-shell \
+  python3-subprocess \
+  python3-textutils \
+  python3-pkgutil \
+  python3-threading \
+  python3-misc \
+  python3-unittest \
+  python3-xml \
+"
+BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/000-cross-compile.patch b/yocto-poky/meta/recipes-devtools/python/python3/000-cross-compile.patch
index 2506a59..28fe70a 100644
--- a/yocto-poky/meta/recipes-devtools/python/python3/000-cross-compile.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python3/000-cross-compile.patch
@@ -9,9 +9,11 @@
  Makefile.pre.in |   25 +++++++++++++------------
  1 file changed, 13 insertions(+), 12 deletions(-)
 
---- a/Makefile.pre.in
-+++ b/Makefile.pre.in
-@@ -193,6 +193,7 @@ LIBOBJS=	@LIBOBJS@
+Index: Python-3.5.1/Makefile.pre.in
+===================================================================
+--- Python-3.5.1.orig/Makefile.pre.in
++++ Python-3.5.1/Makefile.pre.in
+@@ -220,6 +220,7 @@ LIBOBJS=	@LIBOBJS@
  
  PYTHON=		python$(EXE)
  BUILDPYTHON=	python$(BUILDEXE)
@@ -19,7 +21,7 @@
  
  PYTHON_FOR_BUILD=@PYTHON_FOR_BUILD@
  _PYTHON_HOST_PLATFORM=@_PYTHON_HOST_PLATFORM@
-@@ -239,6 +240,7 @@ LIBFFI_INCLUDEDIR=	@LIBFFI_INCLUDEDIR@
+@@ -276,6 +277,7 @@ LIBFFI_INCLUDEDIR=	@LIBFFI_INCLUDEDIR@
  ##########################################################################
  # Parser
  PGEN=		Parser/pgen$(EXE)
@@ -27,25 +29,25 @@
  
  PSRCS=		\
  		Parser/acceler.c \
-@@ -451,7 +453,7 @@ build_all_generate_profile:
+@@ -506,7 +508,7 @@ build_all_generate_profile:
  
  run_profile_task:
  	: # FIXME: can't run for a cross build
--	$(RUNSHARED) ./$(BUILDPYTHON) $(PROFILE_TASK)
-+	$(RUNSHARED) $(HOSTPYTHON) $(PROFILE_TASK)
+-	$(LLVM_PROF_FILE) $(RUNSHARED) ./$(BUILDPYTHON) $(PROFILE_TASK) || true
++	$(LLVM_PROF_FILE) $(RUNSHARED) $(HOSTPYTHON) $(PROFILE_TASK) || true
  
- build_all_use_profile:
- 	$(MAKE) all CFLAGS="$(CFLAGS) -fprofile-use -fprofile-correction"
-@@ -640,7 +642,7 @@ $(IO_OBJS): $(IO_H)
- $(GRAMMAR_H): $(GRAMMAR_INPUT) $(PGENSRCS)
+ build_all_merge_profile:
+ 	$(LLVM_PROF_MERGER)
+@@ -779,7 +781,7 @@ $(IO_OBJS): $(IO_H)
+ 
+ $(GRAMMAR_H): $(GRAMMAR_INPUT) $(PGEN)
  		@$(MKDIR_P) Include
- 		$(MAKE) $(PGEN)
 -		$(PGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
 +		$(HOSTPGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
- $(GRAMMAR_C): $(GRAMMAR_H) $(GRAMMAR_INPUT) $(PGENSRCS)
- 		$(MAKE) $(GRAMMAR_H)
+ $(GRAMMAR_C): $(GRAMMAR_H)
  		touch $(GRAMMAR_C)
-@@ -820,7 +822,7 @@ $(LIBRARY_OBJS) $(MODOBJS) Modules/pytho
+ 
+@@ -968,7 +970,7 @@ $(LIBRARY_OBJS) $(MODOBJS) Programs/pyth
  ######################################################################
  
  TESTOPTS=	$(EXTRATESTOPTS)
@@ -54,7 +56,7 @@
  TESTRUNNER=	$(TESTPYTHON) $(srcdir)/Tools/scripts/run_tests.py
  TESTTIMEOUT=	3600
  
-@@ -1229,7 +1231,7 @@ frameworkinstallstructure:	$(LDLIBRARY)
+@@ -1455,7 +1457,7 @@ frameworkinstallstructure:	$(LDLIBRARY)
  		fi; \
  	done
  	$(LN) -fsn include/python$(LDVERSION) $(DESTDIR)$(prefix)/Headers
@@ -63,7 +65,7 @@
  	$(LN) -fsn $(VERSION) $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Versions/Current
  	$(LN) -fsn Versions/Current/$(PYTHONFRAMEWORK) $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/$(PYTHONFRAMEWORK)
  	$(LN) -fsn Versions/Current/Headers $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Headers
-@@ -1288,7 +1290,7 @@ config.status:	$(srcdir)/configure
+@@ -1521,7 +1523,7 @@ config.status:	$(srcdir)/configure
  
  # Run reindent on the library
  reindent:
@@ -72,12 +74,12 @@
  
  # Rerun configure with the same options as it was run last time,
  # provided the config.status script exists
-@@ -1414,7 +1416,7 @@ funny:
+@@ -1656,7 +1658,7 @@ funny:
  
  # Perform some verification checks on any modified files.
- patchcheck:
+ patchcheck: all
 -	$(RUNSHARED) ./$(BUILDPYTHON) $(srcdir)/Tools/scripts/patchcheck.py
-+	$(RUNSHARED) $(HOSTPYTHON) $(srcdir)/Tools/scripts/patchcheck.py
++	$(RUNSHARED) ./$(HOSTPYTHON) $(srcdir)/Tools/scripts/patchcheck.py
  
  # Dependencies
  
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch b/yocto-poky/meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch
new file mode 100644
index 0000000..b7e0ac6
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch
@@ -0,0 +1,38 @@
+From 045c99b5f1eb6e4e0d8ad1ef9f0ba6574f738150 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 23 Oct 2015 12:25:09 +0300
+Subject: [PATCH] Do not use the shell version of python-config that was
+ introduced in 3.4
+
+Revert instead to the original python version: it has our tweaks and
+outputs directories correctly.
+
+Upstream-Status: Inappropriate [oe-specific]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ Makefile.pre.in | 9 +++------
+ 1 file changed, 3 insertions(+), 6 deletions(-)
+
+diff --git a/Makefile.pre.in b/Makefile.pre.in
+index d7fc9a0..47e60bc 100644
+--- a/Makefile.pre.in
++++ b/Makefile.pre.in
+@@ -1270,12 +1270,9 @@ python-config: $(srcdir)/Misc/python-config.in Misc/python-config.sh
+ 	sed -e "s,@EXENAME@,$(BINDIR)/python$(LDVERSION)$(EXE)," < $(srcdir)/Misc/python-config.in >python-config.py
+ 	# Replace makefile compat. variable references with shell script compat. ones; $(VAR) -> ${VAR}
+ 	sed -e 's,\$$(\([A-Za-z0-9_]*\)),\$$\{\1\},g' < Misc/python-config.sh >python-config
+-	# On Darwin, always use the python version of the script, the shell
+-	# version doesn't use the compiler customizations that are provided
+-	# in python (_osx_support.py).
+-	if test `uname -s` = Darwin; then \
+-		cp python-config.py python-config; \
+-	fi
++	# In OpenEmbedded, always use the python version of the script, the shell
++	# version is broken in multiple ways, and doesn't return correct directories
++	cp python-config.py python-config
+ 
+ 
+ # Install the include files
+-- 
+2.1.4
+
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/020-dont-compile-python-files.patch b/yocto-poky/meta/recipes-devtools/python/python3/020-dont-compile-python-files.patch
index 03ef286..819ba69 100644
--- a/yocto-poky/meta/recipes-devtools/python/python3/020-dont-compile-python-files.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python3/020-dont-compile-python-files.patch
@@ -8,9 +8,11 @@
  Makefile.pre.in |   16 ----------------
  1 file changed, 16 deletions(-)
 
---- a/Makefile.pre.in
-+++ b/Makefile.pre.in
-@@ -1078,24 +1078,6 @@ libinstall:	build_all $(srcdir)/Lib/$(PL
+Index: Python-3.5.0/Makefile.pre.in
+===================================================================
+--- Python-3.5.0.orig/Makefile.pre.in
++++ Python-3.5.0/Makefile.pre.in
+@@ -1262,33 +1262,6 @@ libinstall:	build_all $(srcdir)/Lib/$(PL
  		$(INSTALL_DATA) $(srcdir)/Modules/xxmodule.c \
  			$(DESTDIR)$(LIBDEST)/distutils/tests ; \
  	fi
@@ -24,7 +26,12 @@
 -		-d $(LIBDEST) -f \
 -		-x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \
 -		$(DESTDIR)$(LIBDEST)
--	-PYTHONPATH=$(DESTDIR)$(LIBDEST)  $(RUNSHARED) \
+-	-PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
+-		$(PYTHON_FOR_BUILD) -Wi -OO $(DESTDIR)$(LIBDEST)/compileall.py \
+-		-d $(LIBDEST) -f \
+-		-x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \
+-		$(DESTDIR)$(LIBDEST)
+-	-PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
 -		$(PYTHON_FOR_BUILD) -Wi $(DESTDIR)$(LIBDEST)/compileall.py \
 -		-d $(LIBDEST)/site-packages -f \
 -		-x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
@@ -32,6 +39,10 @@
 -		$(PYTHON_FOR_BUILD) -Wi -O $(DESTDIR)$(LIBDEST)/compileall.py \
 -		-d $(LIBDEST)/site-packages -f \
 -		-x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
+-	-PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
+-		$(PYTHON_FOR_BUILD) -Wi -OO $(DESTDIR)$(LIBDEST)/compileall.py \
+-		-d $(LIBDEST)/site-packages -f \
+-		-x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
  	-PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
  		$(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/Grammar.txt
  	-PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/04-default-is-optimized.patch b/yocto-poky/meta/recipes-devtools/python/python3/04-default-is-optimized.patch
deleted file mode 100644
index 3b8f264..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python3/04-default-is-optimized.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-Upstream-Status: Inappropriate [embedded specific]
-
-# when compiling for an embedded system, we need every bit of
-# performance we can get. default to optimized with the option
-# of opt-out.
-# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
-
-
-2012/05/01
-Signed-Off-By: Nitin A Kamble <nitin.a.kamble@intel.com>
-
-Rebased for 3.4.2 02/2015
-Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
-
-Index: Python-3.4.2/Python/compile.c
-===================================================================
---- Python-3.4.2.orig/Python/compile.c
-+++ Python-3.4.2/Python/compile.c
-@@ -30,7 +30,7 @@
- #include "symtable.h"
- #include "opcode.h"
- 
--int Py_OptimizeFlag = 0;
-+int Py_OptimizeFlag = 1;
- 
- #define DEFAULT_BLOCK_SIZE 16
- #define DEFAULT_BLOCKS 8
-Index: Python-3.4.2/Modules/main.c
-===================================================================
---- Python-3.4.2.orig/Modules/main.c
-+++ Python-3.4.2/Modules/main.c
-@@ -38,7 +38,7 @@ static wchar_t **orig_argv;
- static int  orig_argc;
- 
- /* command line options */
--#define BASE_OPTS L"bBc:dEhiIJm:OqRsStuvVW:xX:?"
-+#define BASE_OPTS L"bBc:dEhiIJm:NOqRsStuvVW:xX:?"
- 
- #define PROGRAM_OPTS BASE_OPTS
- 
-@@ -64,6 +64,7 @@ static char *usage_2 = "\
- -m mod : run library module as a script (terminates option list)\n\
- -O     : optimize generated bytecode slightly; also PYTHONOPTIMIZE=x\n\
- -OO    : remove doc-strings in addition to the -O optimizations\n\
-+-N     : do NOT optimize generated bytecode\n\
- -q     : don't print version and copyright messages on interactive startup\n\
- -s     : don't add user site directory to sys.path; also PYTHONNOUSERSITE\n\
- -S     : don't imply 'import site' on initialization\n\
-@@ -418,8 +419,8 @@ Py_Main(int argc, wchar_t **argv)
- 
-         /* case 'J': reserved for Jython */
- 
--        case 'O':
--            Py_OptimizeFlag++;
-+        case 'N':
-+            Py_OptimizeFlag=0;
-             break;
- 
-         case 'B':
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch b/yocto-poky/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch
index bf02df2..8b93c1c 100644
--- a/yocto-poky/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch
@@ -1,3 +1,8 @@
+From d4dd67daa1555bf13272cc071706338572539bad Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 14 May 2013 15:00:26 -0700
+Subject: [PATCH 01/20] python3: Add target and native recipes
+
 Upstream-Status: Inappropriate [embedded specific]
 
 02/2015 Rebased for Python 3.4.2
@@ -8,11 +13,12 @@
 # Signed-off-by: Khem Raj <raj.khem@gmail.com>
 # Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
 
-Index: Python-3.4.2/Lib/distutils/sysconfig.py
-===================================================================
---- Python-3.4.2.orig/Lib/distutils/sysconfig.py
-+++ Python-3.4.2/Lib/distutils/sysconfig.py
-@@ -16,10 +16,11 @@ import sys
+---
+diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py
+index 573724d..418b478 100644
+--- a/Lib/distutils/sysconfig.py
++++ b/Lib/distutils/sysconfig.py
+@@ -17,10 +17,11 @@ import sys
  from .errors import DistutilsPlatformError
  
  # These are needed in a couple of spots, so just compute them once.
@@ -27,8 +33,8 @@
 +
  
  # Path to the base directory of the project. On Windows the binary may
- # live in project/PCBuild9.  If we're dealing with an x64 Windows build,
-@@ -93,7 +94,9 @@ def get_python_inc(plat_specific=0, pref
+ # live in project/PCBuild/win32 or project/PCBuild/amd64.
+@@ -84,7 +85,9 @@ def get_python_inc(plat_specific=0, prefix=None):
      If 'prefix' is supplied, use it instead of sys.base_prefix or
      sys.base_exec_prefix -- i.e., ignore 'plat_specific'.
      """
@@ -39,20 +45,18 @@
          prefix = plat_specific and BASE_EXEC_PREFIX or BASE_PREFIX
      if os.name == "posix":
          if python_build:
-@@ -134,6 +137,12 @@ def get_python_lib(plat_specific=0, stan
+@@ -125,6 +128,10 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None):
      If 'prefix' is supplied, use it instead of sys.base_prefix or
      sys.base_exec_prefix -- i.e., ignore 'plat_specific'.
      """
++    lib_basename = os.environ['STAGING_LIBDIR'].split('/')[-1]
 +    if prefix is None and os.environ['STAGING_LIBDIR'] != "":
-+        lib_basename = os.environ['STAGING_LIBDIR'].split('/')[-1]
 +        prefix = os.environ['STAGING_LIBDIR'].rstrip(lib_basename)
-+    else:
-+        lib_basename = sys.lib
 +
      if prefix is None:
          if standard_lib:
              prefix = plat_specific and BASE_EXEC_PREFIX or BASE_PREFIX
-@@ -142,7 +151,7 @@ def get_python_lib(plat_specific=0, stan
+@@ -133,7 +140,7 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None):
  
      if os.name == "posix":
          libpython = os.path.join(prefix,
@@ -61,7 +65,7 @@
          if standard_lib:
              return libpython
          else:
-@@ -242,7 +251,7 @@ def get_config_h_filename():
+@@ -233,7 +240,7 @@ def get_config_h_filename():
      else:
          inc_dir = get_python_inc(plat_specific=1)
  
@@ -70,7 +74,7 @@
  
  
  def get_makefile_filename():
-@@ -251,7 +260,7 @@ def get_makefile_filename():
+@@ -242,7 +249,7 @@ def get_makefile_filename():
          return os.path.join(_sys_home or project_base, "Makefile")
      lib_dir = get_python_lib(plat_specific=0, standard_lib=1)
      config_file = 'config-{}{}'.format(get_python_version(), build_flags)
@@ -79,3 +83,6 @@
  
  
  def parse_config_h(fp, g=None):
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/avoid_warning_about_tkinter.patch b/yocto-poky/meta/recipes-devtools/python/python3/avoid_warning_about_tkinter.patch
index 208c57c..3347321 100644
--- a/yocto-poky/meta/recipes-devtools/python/python3/avoid_warning_about_tkinter.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python3/avoid_warning_about_tkinter.patch
@@ -4,6 +4,7 @@
 
 Upstream-Status: Inappropriate [distribution]
 
+Also simply disable the tk module since its not in DEPENDS.
 Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
 
 Index: Python-2.7.2/setup.py
@@ -23,3 +24,16 @@
  
          return missing
  
+diff --git Python-3.5.1.orig/setup.py Python-3.5.1/setup.py
+index b4633b9..d7588c0 100644
+--- Python-3.5.1.orig/setup.py
++++ Python-3.5.1/setup.py
+@@ -1536,7 +1536,7 @@ class PyBuildExt(build_ext):
+         self.extensions.extend(exts)
+ 
+         # Call the method for detecting whether _tkinter can be compiled
+-        self.detect_tkinter(inc_dirs, lib_dirs)
++        # self.detect_tkinter(inc_dirs, lib_dirs)
+ 
+         # tkinter module will not be avalaible as yocto
+         # doesn't have tk integrated (yet)
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/configure.ac-fix-LIBPL.patch b/yocto-poky/meta/recipes-devtools/python/python3/configure.ac-fix-LIBPL.patch
new file mode 100644
index 0000000..97214f9
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python3/configure.ac-fix-LIBPL.patch
@@ -0,0 +1,30 @@
+From 7c4f8d87473d6238c120ec6031b58f83a17a39a5 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Mon, 28 Dec 2015 22:52:06 -0800
+Subject: [PATCH] configure.ac: fix LIBPL
+
+Use LIBDIR rather than prefix/lib, so that it would work when lib64.
+
+Upstream-Status: Pending
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ configure.ac |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 63aef8e..aefb27f 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -4366,7 +4366,7 @@ AC_MSG_RESULT($LDVERSION)
+ 
+ dnl define LIBPL after ABIFLAGS and LDVERSION is defined.
+ AC_SUBST(PY_ENABLE_SHARED)
+-LIBPL='$(prefix)'"/lib/python${VERSION}/config-${LDVERSION}"
++LIBPL='$(LIBDIR)'"/python${VERSION}/config-${LDVERSION}"
+ AC_SUBST(LIBPL)
+ 
+ # Check whether right shifting a negative integer extends the sign bit
+-- 
+1.7.9.5
+
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/makerace.patch b/yocto-poky/meta/recipes-devtools/python/python3/makerace.patch
deleted file mode 100644
index d8a6892..0000000
--- a/yocto-poky/meta/recipes-devtools/python/python3/makerace.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-There is a race due to the execution of make inside the makefile:
-
-| gcc  -pthread -c -Wno-unused-result -DNDEBUG -g  -O3 -Wall -Wstrict-prototypes -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe   -I. -IInclude -I./Include -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -fPIC -DPy_BUILD_CORE -o Objects/obmalloc.o Objects/obmalloc.c
-| gcc  -pthread -c -Wno-unused-result -DNDEBUG -g  -O3 -Wall -Wstrict-prototypes -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe   -I. -IInclude -I./Include -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -fPIC -DPy_BUILD_CORE -o Parser/pgen.o Parser/pgen.c| gcc  -pthread -c -Wno-unused-result -DNDEBUG -g  -O3 -Wall -Wstrict-prototypes -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe   -I. -IInclude -I./Include -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -fPIC -DPy_BUILD_CORE -o Objects/obmalloc.o Objects/obmalloc.c
-| gcc  -pthread -c -Wno-unused-result -DNDEBUG -g  -O3 -Wall -Wstrict-prototypes -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -O2 -pipe   -I. -IInclude -I./Include -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -isystem/home/pokybuild/yocto-autobuilder-dev/yocto-slave/nightly-world/build/build/tmp/sysroots/x86_64-linux/usr/include -fPIC -DPy_BUILD_CORE -o Objects/obmalloc.o Objects/obmalloc.c
-| Objects/obmalloc.o: file not recognized: File truncated
-| collect2: error: ld returned 1 exit status
-| make[1]: *** [Parser/pgen] Error 1
-
-The easiest way to avoid this is to list the dependencies explictly.
-
-RP 28/2/2014
-
-Upstream-Status: Pending
-
-Index: Python-3.3.3/Makefile.pre.in
-===================================================================
---- Python-3.3.3.orig/Makefile.pre.in	2014-02-27 14:04:38.268339533 +0000
-+++ Python-3.3.3/Makefile.pre.in	2014-02-28 10:40:59.166361125 +0000
-@@ -676,7 +676,7 @@
- 
- $(IO_OBJS): $(IO_H)
- 
--$(GRAMMAR_H): $(GRAMMAR_INPUT) $(PGENSRCS)
-+$(GRAMMAR_H): $(GRAMMAR_INPUT) $(PGENSRCS) $(PGEN)
- 		@$(MKDIR_P) Include
- 		$(MAKE) $(PGEN)
- 		$(HOSTPGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/python-3.3-multilib.patch b/yocto-poky/meta/recipes-devtools/python/python3/python-3.3-multilib.patch
index b3e9860..44ec424 100644
--- a/yocto-poky/meta/recipes-devtools/python/python3/python-3.3-multilib.patch
+++ b/yocto-poky/meta/recipes-devtools/python/python3/python-3.3-multilib.patch
@@ -7,23 +7,24 @@
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
 
-Index: Python-3.4.2/Include/pythonrun.h
+Index: Python-3.5.0/Include/pythonrun.h
 ===================================================================
---- Python-3.4.2.orig/Include/pythonrun.h
-+++ Python-3.4.2/Include/pythonrun.h
-@@ -220,6 +220,8 @@ int _Py_CheckPython3();
- /* In their own files */
- PyAPI_FUNC(const char *) Py_GetVersion(void);
- PyAPI_FUNC(const char *) Py_GetPlatform(void);
+--- Python-3.5.0.orig/Include/pythonrun.h
++++ Python-3.5.0/Include/pythonrun.h
+@@ -23,6 +23,9 @@ typedef struct {
+ } PyCompilerFlags;
+ #endif
+ 
 +PyAPI_FUNC(const char *) Py_GetArch(void);
 +PyAPI_FUNC(const char *) Py_GetLib(void);
- PyAPI_FUNC(const char *) Py_GetCopyright(void);
- PyAPI_FUNC(const char *) Py_GetCompiler(void);
- PyAPI_FUNC(const char *) Py_GetBuildInfo(void);
-Index: Python-3.4.2/Lib/distutils/command/install.py
++
+ #ifndef Py_LIMITED_API
+ PyAPI_FUNC(int) PyRun_SimpleStringFlags(const char *, PyCompilerFlags *);
+ PyAPI_FUNC(int) PyRun_AnyFileFlags(FILE *, const char *, PyCompilerFlags *);
+Index: Python-3.5.0/Lib/distutils/command/install.py
 ===================================================================
---- Python-3.4.2.orig/Lib/distutils/command/install.py
-+++ Python-3.4.2/Lib/distutils/command/install.py
+--- Python-3.5.0.orig/Lib/distutils/command/install.py
++++ Python-3.5.0/Lib/distutils/command/install.py
 @@ -19,6 +19,8 @@ from site import USER_BASE
  from site import USER_SITE
  HAS_USER_SITE = True
@@ -42,11 +43,11 @@
          'headers': '$base/include/python$py_version_short$abiflags/$dist_name',
          'scripts': '$base/bin',
          'data'   : '$base',
-Index: Python-3.4.2/Lib/pydoc.py
+Index: Python-3.5.0/Lib/pydoc.py
 ===================================================================
---- Python-3.4.2.orig/Lib/pydoc.py
-+++ Python-3.4.2/Lib/pydoc.py
-@@ -394,7 +394,7 @@ class Doc:
+--- Python-3.5.0.orig/Lib/pydoc.py
++++ Python-3.5.0/Lib/pydoc.py
+@@ -393,7 +393,7 @@ class Doc:
  
          docloc = os.environ.get("PYTHONDOCS", self.PYTHONDOCS)
  
@@ -55,11 +56,11 @@
                                 "python%d.%d" %  sys.version_info[:2])
          if (isinstance(object, type(os)) and
              (object.__name__ in ('errno', 'exceptions', 'gc', 'imp',
-Index: Python-3.4.2/Lib/trace.py
+Index: Python-3.5.0/Lib/trace.py
 ===================================================================
---- Python-3.4.2.orig/Lib/trace.py
-+++ Python-3.4.2/Lib/trace.py
-@@ -751,10 +751,10 @@ def main(argv=None):
+--- Python-3.5.0.orig/Lib/trace.py
++++ Python-3.5.0/Lib/trace.py
+@@ -749,10 +749,10 @@ def main(argv=None):
                  # should I also call expanduser? (after all, could use $HOME)
  
                  s = s.replace("$prefix",
@@ -72,10 +73,10 @@
                                             "python" + sys.version[:3]))
                  s = os.path.normpath(s)
                  ignore_dirs.append(s)
-Index: Python-3.4.2/Makefile.pre.in
+Index: Python-3.5.0/Makefile.pre.in
 ===================================================================
---- Python-3.4.2.orig/Makefile.pre.in
-+++ Python-3.4.2/Makefile.pre.in
+--- Python-3.5.0.orig/Makefile.pre.in
++++ Python-3.5.0/Makefile.pre.in
 @@ -101,6 +101,8 @@ PY_CORE_CFLAGS=	$(PY_CFLAGS) $(PY_CFLAGS
  
  # Machine-dependent subdirectories
@@ -94,15 +95,15 @@
  ABIFLAGS=	@ABIFLAGS@
  
  # Detailed destination directories
-@@ -712,6 +714,7 @@ Modules/getpath.o: $(srcdir)/Modules/get
+@@ -729,6 +731,7 @@ Modules/getpath.o: $(srcdir)/Modules/get
  		-DEXEC_PREFIX='"$(exec_prefix)"' \
  		-DVERSION='"$(VERSION)"' \
  		-DVPATH='"$(VPATH)"' \
 +		-DARCH='"$(ARCH)"' -DLIB='"$(LIB)"' \
  		-o $@ $(srcdir)/Modules/getpath.c
  
- Modules/python.o: $(srcdir)/Modules/python.c
-@@ -780,7 +783,7 @@ $(AST_C): $(AST_H) $(AST_ASDL) $(ASDLGEN
+ Programs/python.o: $(srcdir)/Programs/python.c
+@@ -798,7 +801,7 @@ $(OPCODE_H): $(srcdir)/Lib/opcode.py $(O
  Python/compile.o Python/symtable.o Python/ast.o: $(GRAMMAR_H) $(AST_H)
  
  Python/getplatform.o: $(srcdir)/Python/getplatform.c
@@ -111,10 +112,10 @@
  
  Python/importdl.o: $(srcdir)/Python/importdl.c
  		$(CC) -c $(PY_CORE_CFLAGS) -I$(DLINCLDIR) -o $@ $(srcdir)/Python/importdl.c
-Index: Python-3.4.2/Modules/getpath.c
+Index: Python-3.5.0/Modules/getpath.c
 ===================================================================
---- Python-3.4.2.orig/Modules/getpath.c
-+++ Python-3.4.2/Modules/getpath.c
+--- Python-3.5.0.orig/Modules/getpath.c
++++ Python-3.5.0/Modules/getpath.c
 @@ -117,9 +117,11 @@
  #define EXEC_PREFIX PREFIX
  #endif
@@ -135,12 +136,12 @@
  static wchar_t *module_search_path = NULL;
 +static wchar_t *lib_python = L"" LIB_PYTHON;
  
- static void
- reduce(wchar_t *dir)
-Index: Python-3.4.2/Python/getplatform.c
+ /* Get file status. Encode the path to the locale encoding. */
+ 
+Index: Python-3.5.0/Python/getplatform.c
 ===================================================================
---- Python-3.4.2.orig/Python/getplatform.c
-+++ Python-3.4.2/Python/getplatform.c
+--- Python-3.5.0.orig/Python/getplatform.c
++++ Python-3.5.0/Python/getplatform.c
 @@ -10,3 +10,23 @@ Py_GetPlatform(void)
  {
  	return PLATFORM;
@@ -165,11 +166,11 @@
 +{
 +	return LIB;
 +}
-Index: Python-3.4.2/Python/sysmodule.c
+Index: Python-3.5.0/Python/sysmodule.c
 ===================================================================
---- Python-3.4.2.orig/Python/sysmodule.c
-+++ Python-3.4.2/Python/sysmodule.c
-@@ -1697,6 +1697,10 @@ _PySys_Init(void)
+--- Python-3.5.0.orig/Python/sysmodule.c
++++ Python-3.5.0/Python/sysmodule.c
+@@ -1767,6 +1767,10 @@ _PySys_Init(void)
                          PyUnicode_FromString(Py_GetCopyright()));
      SET_SYS_FROM_STRING("platform",
                          PyUnicode_FromString(Py_GetPlatform()));
@@ -180,11 +181,11 @@
      SET_SYS_FROM_STRING("executable",
                          PyUnicode_FromWideChar(
                                 Py_GetProgramFullPath(), -1));
-Index: Python-3.4.2/setup.py
+Index: Python-3.5.0/setup.py
 ===================================================================
---- Python-3.4.2.orig/setup.py
-+++ Python-3.4.2/setup.py
-@@ -454,7 +454,7 @@ class PyBuildExt(build_ext):
+--- Python-3.5.0.orig/setup.py
++++ Python-3.5.0/setup.py
+@@ -472,7 +472,7 @@ class PyBuildExt(build_ext):
          # directories (i.e. '.' and 'Include') must be first.  See issue
          # 10520.
          if not cross_compiling:
@@ -193,7 +194,7 @@
              add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
          # only change this for cross builds for 3.3, issues on Mageia
          if cross_compiling:
-@@ -512,8 +512,7 @@ class PyBuildExt(build_ext):
+@@ -530,8 +530,7 @@ class PyBuildExt(build_ext):
          # be assumed that no additional -I,-L directives are needed.
          if not cross_compiling:
              lib_dirs = self.compiler.library_dirs + [
@@ -203,7 +204,7 @@
                  ]
              inc_dirs = self.compiler.include_dirs + ['/usr/include']
          else:
-@@ -696,11 +695,11 @@ class PyBuildExt(build_ext):
+@@ -716,11 +715,11 @@ class PyBuildExt(build_ext):
              elif curses_library:
                  readline_libs.append(curses_library)
              elif self.compiler.find_library_file(lib_dirs +
@@ -217,10 +218,10 @@
                                     extra_link_args=readline_extra_link_args,
                                     libraries=readline_libs) )
          else:
-Index: Python-3.4.2/Lib/sysconfig.py
+Index: Python-3.5.0/Lib/sysconfig.py
 ===================================================================
---- Python-3.4.2.orig/Lib/sysconfig.py
-+++ Python-3.4.2/Lib/sysconfig.py
+--- Python-3.5.0.orig/Lib/sysconfig.py
++++ Python-3.5.0/Lib/sysconfig.py
 @@ -20,10 +20,10 @@ __all__ = [
  
  _INSTALL_SCHEMES = {
@@ -263,13 +264,13 @@
          'include': '{userbase}/include/python{py_version_short}',
          'scripts': '{userbase}/bin',
          'data': '{userbase}',
-Index: Python-3.4.2/configure.ac
+Index: Python-3.5.0/configure.ac
 ===================================================================
---- Python-3.4.2.orig/configure.ac
-+++ Python-3.4.2/configure.ac
-@@ -791,6 +791,41 @@ esac
- MULTIARCH=$($CC --print-multiarch 2>/dev/null)
- AC_SUBST(MULTIARCH)
+--- Python-3.5.0.orig/configure.ac
++++ Python-3.5.0/configure.ac
+@@ -858,6 +858,41 @@ PLATDIR=plat-$MACHDEP
+ AC_SUBST(PLATDIR)
+ AC_SUBST(PLATFORM_TRIPLET)
  
 +AC_SUBST(ARCH)
 +AC_MSG_CHECKING(ARCH)
@@ -307,32 +308,5 @@
 +esac
 +AC_MSG_RESULT($LIB)
  
- AC_SUBST(LIBRARY)
- AC_MSG_CHECKING(LIBRARY)
-Index: Python-3.4.2/Lib/site.py
-===================================================================
---- Python-3.4.2.orig/Lib/site.py
-+++ Python-3.4.2/Lib/site.py
-@@ -304,13 +304,19 @@ def getsitepackages(prefixes=None):
-         seen.add(prefix)
- 
-         if os.sep == '/':
--            sitepackages.append(os.path.join(prefix, "lib",
-+            sitepackages.append(os.path.join(prefix, sys.lib,
-                                         "python" + sys.version[:3],
-                                         "site-packages"))
--            sitepackages.append(os.path.join(prefix, "lib", "site-python"))
-+            if sys.lib != "lib":
-+                sitepackages.append(os.path.join(prefix, "lib",
-+                                        "python" + sys.version[:3],
-+                                        "site-packages"))
-+            sitepackages.append(os.path.join(prefix, sys.lib, "site-python"))
-+            if sys.lib != "lib":
-+                sitepackages.append(os.path.join(prefix, sys.lib, "site-python"))
-         else:
-             sitepackages.append(prefix)
--            sitepackages.append(os.path.join(prefix, "lib", "site-packages"))
-+            sitepackages.append(os.path.join(prefix, sys.lib, "site-packages"))
-         if sys.platform == "darwin":
-             # for framework builds *only* we add the standard Apple
-             # locations.
+ AC_MSG_CHECKING([for -Wl,--no-as-needed])
+ save_LDFLAGS="$LDFLAGS"
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/tweak-MULTIARCH-for-powerpc-linux-gnuspe.patch b/yocto-poky/meta/recipes-devtools/python/python3/tweak-MULTIARCH-for-powerpc-linux-gnuspe.patch
new file mode 100644
index 0000000..8d03727
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python3/tweak-MULTIARCH-for-powerpc-linux-gnuspe.patch
@@ -0,0 +1,52 @@
+From 5d6509313198ec9b686cad50b002212e4344004b Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Fri, 11 Mar 2016 01:15:45 -0500
+Subject: [PATCH] configure.ac: tweak MULTIARCH for powerpc-linux-gnuspe
+
+For p1022ds bsp, the MULTIARCH is powerpc-linux-gnuspev1 and
+python3 did not recognize the extra 'v1' which caused python3
+configure error for the platform triplet.
+
+Q:Why Python3 check platform triplet?
+
+A:Under Linux, GNU/KFreeBSD and the Hurd, C extensions now include
+the architecture triplet in the extension name, to make it easy to
+test builds for different ABIs in the same working tree.
+
+Here is the generated  C extensions which take platform triplet into account.
+...
+|image/usr/lib/python3.5/lib-dynload/_datetime.cpython-35m-powerpc-linux-gnuspe.so
+...
+
+https://bugs.python.org/issue22980
+https://www.python.org/dev/peps/pep-3149/
+https://bugs.python.org/review/22980/patch/14593/54808
+
+Upstream-Status: Pending
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ configure.ac | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/configure.ac b/configure.ac
+index 9eb3d22..c34a9a0 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -724,6 +724,13 @@ fi
+ 
+ 
+ MULTIARCH=$($CC --print-multiarch 2>/dev/null)
++
++# Tweak MULTIARCH
++if test x$MULTIARCH = xpowerpc-linux-gnuspev1
++then
++	MULTIARCH="powerpc-linux-gnuspe"
++fi
++
+ AC_SUBST(MULTIARCH)
+ 
+ AC_MSG_CHECKING([for the platform triplet based on compiler characteristics])
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/python/python3/use_packed_importlib.patch b/yocto-poky/meta/recipes-devtools/python/python3/use_packed_importlib.patch
new file mode 100644
index 0000000..6c4b0cd
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/python/python3/use_packed_importlib.patch
@@ -0,0 +1,31 @@
+
+Upstream-Status: Inappropriate [embedded specific] 
+  
+The binary _freeze_importlib is built and also used during build time to generate
+importlib*.h files, this is impossible to do on a cross-compile environment,
+this avoids executing the binary and forces it to use the packed importlib*.h files.
+
+ 
+Signed-Off-By: Alejandro Hernandez <alejandro.hernandez@linux.intel.com> 
+
+Index: Python-3.5.0/Makefile.pre.in
+===================================================================
+--- Python-3.5.0.orig/Makefile.pre.in
++++ Python-3.5.0/Makefile.pre.in
+@@ -700,12 +700,12 @@ Programs/_freeze_importlib.o: Programs/_
+ Programs/_freeze_importlib: Programs/_freeze_importlib.o $(LIBRARY_OBJS_OMIT_FROZEN)
+ 	$(LINKCC) $(PY_LDFLAGS) -o $@ Programs/_freeze_importlib.o $(LIBRARY_OBJS_OMIT_FROZEN) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST)
+ 
+-Python/importlib_external.h: $(srcdir)/Lib/importlib/_bootstrap_external.py Programs/_freeze_importlib
+-	./Programs/_freeze_importlib \
++#Python/importlib_external.h: $(srcdir)/Lib/importlib/_bootstrap_external.py Programs/_freeze_importlib
++#	./Programs/_freeze_importlib \
+ 		$(srcdir)/Lib/importlib/_bootstrap_external.py Python/importlib_external.h
+ 
+-Python/importlib.h: $(srcdir)/Lib/importlib/_bootstrap.py Programs/_freeze_importlib
+-	./Programs/_freeze_importlib \
++#Python/importlib.h: $(srcdir)/Lib/importlib/_bootstrap.py Programs/_freeze_importlib
++#	./Programs/_freeze_importlib \
+ 		$(srcdir)/Lib/importlib/_bootstrap.py Python/importlib.h
+ 
+ 
diff --git a/yocto-poky/meta/recipes-devtools/python/python3_3.4.3.bb b/yocto-poky/meta/recipes-devtools/python/python3_3.5.1.bb
similarity index 92%
rename from yocto-poky/meta/recipes-devtools/python/python3_3.4.3.bb
rename to yocto-poky/meta/recipes-devtools/python/python3_3.5.1.bb
index f61d278..2fbb3cb 100644
--- a/yocto-poky/meta/recipes-devtools/python/python3_3.4.3.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python3_3.5.1.bb
@@ -2,7 +2,7 @@
 
 DEPENDS = "python3-native libffi bzip2 db gdbm openssl readline sqlite3 zlib virtual/libintl xz"
 PR = "${INC_PR}.0"
-PYTHON_MAJMIN = "3.4"
+PYTHON_MAJMIN = "3.5"
 PYTHON_BINABI= "${PYTHON_MAJMIN}m"
 DISTRO_SRC_URI ?= "file://sitecustomize.py"
 DISTRO_SRC_URI_linuxstdbase = ""
@@ -17,13 +17,12 @@
 file://130-readline-setup.patch \
 file://150-fix-setupterm.patch \
 file://0001-h2py-Fix-issue-13032-where-it-fails-with-UnicodeDeco.patch \
-file://makerace.patch \
+file://tweak-MULTIARCH-for-powerpc-linux-gnuspe.patch \
 ${DISTRO_SRC_URI} \
 "
 
 SRC_URI += "\
             file://03-fix-tkinter-detection.patch \
-            file://04-default-is-optimized.patch \
             file://avoid_warning_about_tkinter.patch \
             file://cgi_py.patch \
             file://host_include_contamination.patch \
@@ -37,9 +36,14 @@
             file://sysconfig.py-add-_PYTHON_PROJECT_SRC.patch \
             file://setup.py-check-cross_compiling-when-get-FLAGS.patch \
             file://setup.py-find-libraries-in-staging-dirs.patch \
+            file://use_packed_importlib.patch \
+            file://configure.ac-fix-LIBPL.patch \
            "
-SRC_URI[md5sum] = "7d092d1bba6e17f0d9bd21b49e441dd5"
-SRC_URI[sha256sum] = "b5b3963533768d5fc325a4d7a6bd6f666726002d696f1d399ec06b043ea996b8"
+SRC_URI[md5sum] = "e9ea6f2623fffcdd871b7b19113fde80"
+SRC_URI[sha256sum] = "c6d57c0c366d9060ab6c0cdf889ebf3d92711d466cc0119c441dbf2746f725c9"
+
+# exclude pre-releases for both python 2.x and 3.x
+UPSTREAM_CHECK_REGEX = "[Pp]ython-(?P<pver>\d+(\.\d+)+).tar"
 
 LIC_FILES_CHKSUM = "file://LICENSE;md5=dd98d01d471fac8d8dbdd975229dba03"
 
@@ -56,11 +60,9 @@
                 ac_cv_file__dev_ptmx=yes \
                 ac_cv_file__dev_ptc=no \
 "
-# The 3 lines below are copied from the libffi recipe, ctypes ships its own copy of the libffi sources
-#Somehow gcc doesn't set __SOFTFP__ when passing -mfloatabi=softp :(
-TARGET_CC_ARCH_append_armv6 = " -D__SOFTFP__"
-TARGET_CC_ARCH_append_armv7a = " -D__SOFTFP__"
+
 TARGET_CC_ARCH += "-DNDEBUG -fno-inline"
+SDK_CC_ARCH += "-DNDEBUG -fno-inline"
 EXTRA_OEMAKE += "CROSS_COMPILE=yes"
 EXTRA_OECONF += "CROSSPYTHONPATH=${STAGING_LIBDIR_NATIVE}/python${PYTHON_MAJMIN}/lib-dynload/ --without-ensurepip"
 
@@ -209,13 +211,12 @@
 PACKAGES =+ "libpython3 libpython3-staticdev"
 FILES_libpython3 = "${libdir}/libpython*.so.*"
 FILES_libpython3-staticdev += "${libdir}/python${PYTHON_MAJMIN}/config-${PYTHON_BINABI}/libpython${PYTHON_BINABI}.a"
-
-# catch debug extensions (isn't that already in python-core-dbg?)
-FILES_${PN}-dbg += "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/.debug"
+INSANE_SKIP_${PN}-dev += "dev-elf"
 
 # catch all the rest (unsorted)
 PACKAGES += "${PN}-misc"
 RDEPENDS_${PN}-misc += "${PN}-core"
+RDEPENDS_${PN}-modules += "${PN}-misc"
 FILES_${PN}-misc = "${libdir}/python${PYTHON_MAJMIN}"
 
 # catch manpage
diff --git a/yocto-poky/meta/recipes-devtools/python/python_2.7.9.bb b/yocto-poky/meta/recipes-devtools/python/python_2.7.11.bb
similarity index 88%
rename from yocto-poky/meta/recipes-devtools/python/python_2.7.9.bb
rename to yocto-poky/meta/recipes-devtools/python/python_2.7.11.bb
index f7e2f27..606f153 100644
--- a/yocto-poky/meta/recipes-devtools/python/python_2.7.9.bb
+++ b/yocto-poky/meta/recipes-devtools/python/python_2.7.11.bb
@@ -26,6 +26,7 @@
   file://parallel-makeinst-create-bindir.patch \
   file://use_sysroot_ncurses_instead_of_host.patch \
   file://avoid_parallel_make_races_on_pgen.patch \
+  file://add-CROSSPYTHONPATH-for-PYTHON_FOR_BUILD.patch \
 "
 
 S = "${WORKDIR}/Python-${PV}"
@@ -34,13 +35,7 @@
 
 CONFIGUREOPTS += " --with-system-ffi "
 
-# The 3 lines below are copied from the libffi recipe, ctypes ships its own copy of the libffi sources
-#Somehow gcc doesn't set __SOFTFP__ when passing -mfloatabi=softp :(
-TARGET_CC_ARCH_append_armv6 = " -D__SOFTFP__"
-TARGET_CC_ARCH_append_armv7a = " -D__SOFTFP__"
-
-# The following is a hack until we drop ac_cv_sizeof_off_t from site files
-EXTRA_OECONF += "${@bb.utils.contains('DISTRO_FEATURES', 'largefile', 'ac_cv_sizeof_off_t=8', '', d)} ac_cv_file__dev_ptmx=yes ac_cv_file__dev_ptc=no"
+EXTRA_OECONF += "ac_cv_file__dev_ptmx=yes ac_cv_file__dev_ptc=no"
 
 do_configure_append() {
 	rm -f ${S}/Makefile.orig
@@ -127,7 +122,7 @@
 }
 
 do_install_append_class-nativesdk () {
-	create_wrapper ${D}${bindir}/python2.7 TERMINFO_DIRS='${sysconfdir}/terminfo:/etc/terminfo:/usr/share/terminfo:/usr/share/misc/terminfo:/lib/terminfo'
+	create_wrapper ${D}${bindir}/python2.7 PYTHONHOME='${prefix}' TERMINFO_DIRS='${sysconfdir}/terminfo:/etc/terminfo:/usr/share/terminfo:/usr/share/misc/terminfo:/lib/terminfo'
 }
 
 SSTATE_SCAN_FILES += "Makefile"
@@ -155,9 +150,6 @@
 PACKAGES =+ "lib${BPN}2"
 FILES_lib${BPN}2 = "${libdir}/libpython*.so.*"
 
-# catch debug extensions (isn't that already in python-core-dbg?)
-FILES_${PN}-dbg += "${libdir}/python${PYTHON_MAJMIN}/lib-dynload/.debug"
-
 # catch all the rest (unsorted)
 PACKAGES += "${PN}-misc"
 FILES_${PN}-misc = "${libdir}/python${PYTHON_MAJMIN}"
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu-targets.inc b/yocto-poky/meta/recipes-devtools/qemu/qemu-targets.inc
index 5c35655..a3e46a8 100644
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu-targets.inc
+++ b/yocto-poky/meta/recipes-devtools/qemu/qemu-targets.inc
@@ -7,7 +7,7 @@
     archs = d.getVar('QEMU_TARGETS', True).split()
     tos = d.getVar('HOST_OS', True)
     softmmuonly = ""
-    for arch in ['mips64', 'mips64el', 'ppcemb']:
+    for arch in ['ppcemb']:
         if arch in archs:
             softmmuonly += arch + "-softmmu,"
             archs.remove(arch)
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu.inc b/yocto-poky/meta/recipes-devtools/qemu/qemu.inc
index b17da2f..269c898 100644
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu.inc
+++ b/yocto-poky/meta/recipes-devtools/qemu/qemu.inc
@@ -21,7 +21,6 @@
     file://wacom.patch \
     file://add-ptest-in-makefile.patch \
     file://run-ptest \
-    file://cpus.c-qemu_mutex_lock_iothread-fix-race-condition-a.patch \
     "
 
 SRC_URI_append_class-native = "\
@@ -111,17 +110,18 @@
 PACKAGECONFIG[aio] = "--enable-linux-aio,--disable-linux-aio,libaio,"
 PACKAGECONFIG[xfs] = "--enable-xfsctl,--disable-xfsctl,xfsprogs,"
 PACKAGECONFIG[xen] = "--enable-xen,--disable-xen,xen,xen-libxenstore xen-libxenctrl xen-libxenguest"
-PACKAGECONFIG[vnc-tls] = "--enable-vnc --enable-vnc-tls,--disable-vnc-tls, gnutls,"
 PACKAGECONFIG[vnc-sasl] = "--enable-vnc --enable-vnc-sasl,--disable-vnc-sasl,cyrus-sasl,"
 PACKAGECONFIG[vnc-jpeg] = "--enable-vnc --enable-vnc-jpeg,--disable-vnc-jpeg,jpeg,"
 PACKAGECONFIG[vnc-png] = "--enable-vnc --enable-vnc-png,--disable-vnc-png,libpng,"
 PACKAGECONFIG[libcurl] = "--enable-curl,--disable-curl,libcurl,"
-PACKAGECONFIG[nss] = "--enable-smartcard-nss,--disable-smartcard-nss,nss,"
+PACKAGECONFIG[nss] = "--enable-smartcard,--disable-smartcard,nss,"
 PACKAGECONFIG[uuid] = "--enable-uuid,--disable-uuid,util-linux,"
 PACKAGECONFIG[curses] = "--enable-curses,--disable-curses,ncurses,"
 PACKAGECONFIG[gtk+] = "--enable-gtk --enable-vte,--disable-gtk --disable-vte,gtk+ libvte,"
 PACKAGECONFIG[libcap-ng] = "--enable-cap-ng,--disable-cap-ng,libcap-ng,"
 PACKAGECONFIG[ssh2] = "--enable-libssh2,--disable-libssh2,libssh2,"
+PACKAGECONFIG[gcrypt] = "--enable-gcrypt,--disable-gcrypt,gcrypt,"
+PACKAGECONFIG[nettle] = "--enable-nettle,--disable-nettle,nettle"
 PACKAGECONFIG[libusb] = "--enable-libusb,--disable-libusb,libusb1"
 PACKAGECONFIG[fdt] = "--enable-fdt,--disable-fdt,dtc"
 PACKAGECONFIG[alsa] = ",,alsa-lib"
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7295_1.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7295_1.patch
deleted file mode 100644
index d7ae871..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7295_1.patch
+++ /dev/null
@@ -1,63 +0,0 @@
-From ce317461573bac12b10d67699b4ddf1f97cf066c Mon Sep 17 00:00:00 2001
-From: Jason Wang <jasowang@redhat.com>
-Date: Fri, 25 Sep 2015 13:21:28 +0800
-Subject: [PATCH] virtio: introduce virtqueue_unmap_sg()
-
-Factor out sg unmapping logic. This will be reused by the patch that
-can discard descriptor.
-
-Cc: Michael S. Tsirkin <mst@redhat.com>
-Cc: Andrew James <andrew.james@hpe.com>
-Signed-off-by: Jason Wang <jasowang@redhat.com>
-Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
-Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
-
-Upstream-Status: Backport
-
-git.qemu.org/?p=qemu.git;a=commit;h=ce317461573bac12b10d67699b4ddf1f97cf066c
-
-CVE: CVE-2015-7295 patch #1
-[Yocto # 9013]
-
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- hw/virtio/virtio.c | 14 ++++++++++----
- 1 file changed, 10 insertions(+), 4 deletions(-)
-
-Index: qemu-2.4.0/hw/virtio/virtio.c
-===================================================================
---- qemu-2.4.0.orig/hw/virtio/virtio.c
-+++ qemu-2.4.0/hw/virtio/virtio.c
-@@ -243,14 +243,12 @@ int virtio_queue_empty(VirtQueue *vq)
-     return vring_avail_idx(vq) == vq->last_avail_idx;
- }
- 
--void virtqueue_fill(VirtQueue *vq, const VirtQueueElement *elem,
--                    unsigned int len, unsigned int idx)
-+static void virtqueue_unmap_sg(VirtQueue *vq, const VirtQueueElement *elem,
-+                               unsigned int len)
- {
-     unsigned int offset;
-     int i;
- 
--    trace_virtqueue_fill(vq, elem, len, idx);
--
-     offset = 0;
-     for (i = 0; i < elem->in_num; i++) {
-         size_t size = MIN(len - offset, elem->in_sg[i].iov_len);
-@@ -266,6 +264,14 @@ void virtqueue_fill(VirtQueue *vq, const
-         cpu_physical_memory_unmap(elem->out_sg[i].iov_base,
-                                   elem->out_sg[i].iov_len,
-                                   0, elem->out_sg[i].iov_len);
-+}
-+
-+void virtqueue_fill(VirtQueue *vq, const VirtQueueElement *elem,
-+                    unsigned int len, unsigned int idx)
-+{
-+    trace_virtqueue_fill(vq, elem, len, idx);
-+
-+    virtqueue_unmap_sg(vq, elem, len);
- 
-     idx = (idx + vring_used_idx(vq)) % vq->vring.num;
- 
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7295_2.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7295_2.patch
deleted file mode 100644
index 45dfab3..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7295_2.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 29b9f5efd78ae0f9cc02dd169b6e80d2c404bade Mon Sep 17 00:00:00 2001
-From: Jason Wang <jasowang@redhat.com>
-Date: Fri, 25 Sep 2015 13:21:29 +0800
-Subject: [PATCH] virtio: introduce virtqueue_discard()
-
-This patch introduces virtqueue_discard() to discard a descriptor and
-unmap the sgs. This will be used by the patch that will discard
-descriptor when packet is truncated.
-
-Cc: Michael S. Tsirkin <mst@redhat.com>
-Signed-off-by: Jason Wang <jasowang@redhat.com>
-Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
-Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
-Upstream-Status: Backport
-
-git.qemu.org/?p=qemu.git;a=commit;h=29b9f5efd78ae0f9cc02dd169b6e80d2c404bade
- 
-CVE: CVE-2015-7295 patch #2
-[Yocto # 9013]
-
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- hw/virtio/virtio.c         | 7 +++++++
- include/hw/virtio/virtio.h | 2 ++
- 2 files changed, 9 insertions(+)
-
-Index: qemu-2.4.0/hw/virtio/virtio.c
-===================================================================
---- qemu-2.4.0.orig/hw/virtio/virtio.c
-+++ qemu-2.4.0/hw/virtio/virtio.c
-@@ -266,6 +266,13 @@ static void virtqueue_unmap_sg(VirtQueue
-                                   0, elem->out_sg[i].iov_len);
- }
- 
-+void virtqueue_discard(VirtQueue *vq, const VirtQueueElement *elem,
-+                       unsigned int len)
-+{
-+    vq->last_avail_idx--;
-+    virtqueue_unmap_sg(vq, elem, len);
-+}
-+
- void virtqueue_fill(VirtQueue *vq, const VirtQueueElement *elem,
-                     unsigned int len, unsigned int idx)
- {
-Index: qemu-2.4.0/include/hw/virtio/virtio.h
-===================================================================
---- qemu-2.4.0.orig/include/hw/virtio/virtio.h
-+++ qemu-2.4.0/include/hw/virtio/virtio.h
-@@ -146,6 +146,8 @@ void virtio_del_queue(VirtIODevice *vdev
- void virtqueue_push(VirtQueue *vq, const VirtQueueElement *elem,
-                     unsigned int len);
- void virtqueue_flush(VirtQueue *vq, unsigned int count);
-+void virtqueue_discard(VirtQueue *vq, const VirtQueueElement *elem,
-+                       unsigned int len);
- void virtqueue_fill(VirtQueue *vq, const VirtQueueElement *elem,
-                     unsigned int len, unsigned int idx);
- 
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7295_3.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7295_3.patch
deleted file mode 100644
index 74442e3..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7295_3.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From 0cf33fb6b49a19de32859e2cdc6021334f448fb3 Mon Sep 17 00:00:00 2001
-From: Jason Wang <jasowang@redhat.com>
-Date: Fri, 25 Sep 2015 13:21:30 +0800
-Subject: [PATCH] virtio-net: correctly drop truncated packets
-
-When packet is truncated during receiving, we drop the packets but
-neither discard the descriptor nor add and signal used
-descriptor. This will lead several issues:
-
-- sg mappings are leaked
-- rx will be stalled if a lots of packets were truncated
-
-In order to be consistent with vhost, fix by discarding the descriptor
-in this case.
-
-Cc: Michael S. Tsirkin <mst@redhat.com>
-Signed-off-by: Jason Wang <jasowang@redhat.com>
-Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
-Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
-
-Upstream-Status: Backport
-
-git.qemu.org/?p=qemu.git;a=commit;h=0cf33fb6b49a19de32859e2cdc6021334f448fb3
-
-CVE: CVE-2015-7295 patch #3
-[Yocto # 9013]
-
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- hw/net/virtio-net.c | 8 +-------
- 1 file changed, 1 insertion(+), 7 deletions(-)
-
-Index: qemu-2.4.0/hw/net/virtio-net.c
-===================================================================
---- qemu-2.4.0.orig/hw/net/virtio-net.c
-+++ qemu-2.4.0/hw/net/virtio-net.c
-@@ -1086,13 +1086,7 @@ static ssize_t virtio_net_receive(NetCli
-          * must have consumed the complete packet.
-          * Otherwise, drop it. */
-         if (!n->mergeable_rx_bufs && offset < size) {
--#if 0
--            error_report("virtio-net truncated non-mergeable packet: "
--                         "i %zd mergeable %d offset %zd, size %zd, "
--                         "guest hdr len %zd, host hdr len %zd",
--                         i, n->mergeable_rx_bufs,
--                         offset, size, n->guest_hdr_len, n->host_hdr_len);
--#endif
-+            virtqueue_discard(q->rx_vq, &elem, total);
-             return size;
-         }
- 
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7504.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7504.patch
deleted file mode 100644
index 90a7947..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7504.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From 837f21aacf5a714c23ddaadbbc5212f9b661e3f7 Mon Sep 17 00:00:00 2001
-From: Prasad J Pandit <pjp@fedoraproject.org>
-Date: Fri, 20 Nov 2015 11:50:31 +0530
-Subject: [PATCH] net: pcnet: add check to validate receive data
- size(CVE-2015-7504)
-
-In loopback mode, pcnet_receive routine appends CRC code to the
-receive buffer. If the data size given is same as the buffer size,
-the appended CRC code overwrites 4 bytes after s->buffer. Added a
-check to avoid that.
-
-Reported by: Qinghao Tang <luodalongde@gmail.com>
-Cc: qemu-stable@nongnu.org
-Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
-Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
-Signed-off-by: Jason Wang <jasowang@redhat.com>
-
-Upstream-Status: Backport
-
-http://git.qemu.org/?p=qemu.git;a=commit;h=837f21aacf5a714c23ddaadbbc5212f9b661e3f7
-
-CVE: CVE-2015-7504
-[Yocto # 9013]
-
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- hw/net/pcnet.c | 8 +++++---
- 1 file changed, 5 insertions(+), 3 deletions(-)
-
-Index: qemu-2.4.0/hw/net/pcnet.c
-===================================================================
---- qemu-2.4.0.orig/hw/net/pcnet.c
-+++ qemu-2.4.0/hw/net/pcnet.c
-@@ -1085,7 +1085,7 @@ ssize_t pcnet_receive(NetClientState *nc
-                 uint32_t fcs = ~0;
-                 uint8_t *p = src;
- 
--                while (p != &src[size-4])
-+                while (p != &src[size])
-                     CRC(fcs, *p++);
-                 crc_err = (*(uint32_t *)p != htonl(fcs));
-             }
-@@ -1234,8 +1234,10 @@ static void pcnet_transmit(PCNetState *s
-         bcnt = 4096 - GET_FIELD(tmd.length, TMDL, BCNT);
- 
-         /* if multi-tmd packet outsizes s->buffer then skip it silently.
--           Note: this is not what real hw does */
--        if (s->xmit_pos + bcnt > sizeof(s->buffer)) {
-+         * Note: this is not what real hw does.
-+         * Last four bytes of s->buffer are used to store CRC FCS code.
-+         */
-+        if (s->xmit_pos + bcnt > sizeof(s->buffer) - 4) {
-             s->xmit_pos = -1;
-             goto txdone;
-         }
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7512.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7512.patch
deleted file mode 100644
index 50b8a6c..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-7512.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 8b98a2f07175d46c3f7217639bd5e03f2ec56343 Mon Sep 17 00:00:00 2001
-From: Jason Wang <jasowang@redhat.com>
-Date: Mon, 30 Nov 2015 15:00:06 +0800
-Subject: [PATCH] pcnet: fix rx buffer overflow(CVE-2015-7512)
-
-Backends could provide a packet whose length is greater than buffer
-size. Check for this and truncate the packet to avoid rx buffer
-overflow in this case.
-
-Cc: Prasad J Pandit <pjp@fedoraproject.org>
-Cc: qemu-stable@nongnu.org
-Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
-Signed-off-by: Jason Wang <jasowang@redhat.com>
-
-Upsteam_Status: Backport
-
-http://git.qemu.org/?p=qemu.git;a=commit;h=8b98a2f07175d46c3f7217639bd5e03f2ec56343
-
-CVE: CVE-2015-7512
-[Yocto # 9013]
-
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- hw/net/pcnet.c | 6 ++++++
- 1 file changed, 6 insertions(+)
-
-Index: qemu-2.4.0/hw/net/pcnet.c
-===================================================================
---- qemu-2.4.0.orig/hw/net/pcnet.c
-+++ qemu-2.4.0/hw/net/pcnet.c
-@@ -1065,6 +1065,12 @@ ssize_t pcnet_receive(NetClientState *nc
-             int pktcount = 0;
- 
-             if (!s->looptest) {
-+                if (size > 4092) {
-+#ifdef PCNET_DEBUG_RMD
-+                    fprintf(stderr, "pcnet: truncates rx packet.\n");
-+#endif
-+                    size = 4092;
-+                }
-                 memcpy(src, buf, size);
-                 /* no need to compute the CRC */
-                 src[size] = 0;
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-8345.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-8345.patch
deleted file mode 100644
index 310b458..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-8345.patch
+++ /dev/null
@@ -1,73 +0,0 @@
-From 00837731d254908a841d69298a4f9f077babaf24 Mon Sep 17 00:00:00 2001
-From: Stefan Weil <sw@weilnetz.de>
-Date: Fri, 20 Nov 2015 08:42:33 +0100
-Subject: [PATCH] eepro100: Prevent two endless loops
-
-http://lists.nongnu.org/archive/html/qemu-devel/2015-11/msg04592.html
-shows an example how an endless loop in function action_command can
-be achieved.
-
-During my code review, I noticed a 2nd case which can result in an
-endless loop.
-
-Reported-by: Qinghao Tang <luodalongde@gmail.com>
-Signed-off-by: Stefan Weil <sw@weilnetz.de>
-Signed-off-by: Jason Wang <jasowang@redhat.com>
-
-Upstream-Status: Backport
-
-http://git.qemu.org/?p=qemu.git;a=commit;h=00837731d254908a841d69298a4f9f077babaf24
-
-CVE: CVE-2015-8345
-[Yocto # 9013]
-
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- hw/net/eepro100.c | 16 ++++++++++++++++
- 1 file changed, 16 insertions(+)
-
-diff --git a/hw/net/eepro100.c b/hw/net/eepro100.c
-index 60333b7..685a478 100644
---- a/hw/net/eepro100.c
-+++ b/hw/net/eepro100.c
-@@ -774,6 +774,11 @@ static void tx_command(EEPRO100State *s)
- #if 0
-         uint16_t tx_buffer_el = lduw_le_pci_dma(&s->dev, tbd_address + 6);
- #endif
-+        if (tx_buffer_size == 0) {
-+            /* Prevent an endless loop. */
-+            logout("loop in %s:%u\n", __FILE__, __LINE__);
-+            break;
-+        }
-         tbd_address += 8;
-         TRACE(RXTX, logout
-             ("TBD (simplified mode): buffer address 0x%08x, size 0x%04x\n",
-@@ -855,6 +860,10 @@ static void set_multicast_list(EEPRO100State *s)
- 
- static void action_command(EEPRO100State *s)
- {
-+    /* The loop below won't stop if it gets special handcrafted data.
-+       Therefore we limit the number of iterations. */
-+    unsigned max_loop_count = 16;
-+
-     for (;;) {
-         bool bit_el;
-         bool bit_s;
-@@ -870,6 +879,13 @@ static void action_command(EEPRO100State *s)
- #if 0
-         bool bit_sf = ((s->tx.command & COMMAND_SF) != 0);
- #endif
-+
-+        if (max_loop_count-- == 0) {
-+            /* Prevent an endless loop. */
-+            logout("loop in %s:%u\n", __FILE__, __LINE__);
-+            break;
-+        }
-+
-         s->cu_offset = s->tx.link;
-         TRACE(OTHER,
-               logout("val=(cu start), status=0x%04x, command=0x%04x, link=0x%08x\n",
--- 
-2.3.5
-
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-8504.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-8504.patch
deleted file mode 100644
index 9e66021..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2015-8504.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From 4c65fed8bdf96780735dbdb92a8bd0d6b6526cc3 Mon Sep 17 00:00:00 2001
-From: Prasad J Pandit <pjp@fedoraproject.org>
-Date: Thu, 3 Dec 2015 18:54:17 +0530
-Subject: [PATCH] ui: vnc: avoid floating point exception
-
-While sending 'SetPixelFormat' messages to a VNC server,
-the client could set the 'red-max', 'green-max' and 'blue-max'
-values to be zero. This leads to a floating point exception in
-write_png_palette while doing frame buffer updates.
-
-Reported-by: Lian Yihan <lianyihan@360.cn>
-Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
-Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
-Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-
-Upstream-Status: Backport
-
-http://git.qemu.org/?p=qemu.git;a=commitdiff;h=4c65fed8bdf96780735dbdb92a8
-
-CVE: CVE-2015-8504
-[Yocto # 9013]
-
-Signed-off-by: Armin Kuster <akuster@mvista.com>
-
----
- ui/vnc.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-Index: qemu-2.4.0/ui/vnc.c
-===================================================================
---- qemu-2.4.0.orig/ui/vnc.c
-+++ qemu-2.4.0/ui/vnc.c
-@@ -2189,15 +2189,15 @@ static void set_pixel_format(VncState *v
-         return;
-     }
- 
--    vs->client_pf.rmax = red_max;
-+    vs->client_pf.rmax = red_max ? red_max : 0xFF;
-     vs->client_pf.rbits = hweight_long(red_max);
-     vs->client_pf.rshift = red_shift;
-     vs->client_pf.rmask = red_max << red_shift;
--    vs->client_pf.gmax = green_max;
-+    vs->client_pf.gmax = green_max ? green_max : 0xFF;
-     vs->client_pf.gbits = hweight_long(green_max);
-     vs->client_pf.gshift = green_shift;
-     vs->client_pf.gmask = green_max << green_shift;
--    vs->client_pf.bmax = blue_max;
-+    vs->client_pf.bmax = blue_max ? blue_max : 0xFF;
-     vs->client_pf.bbits = hweight_long(blue_max);
-     vs->client_pf.bshift = blue_shift;
-     vs->client_pf.bmask = blue_max << blue_shift;
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2016-1568.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2016-1568.patch
index 9c40ffb..56fd346 100644
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2016-1568.patch
+++ b/yocto-poky/meta/recipes-devtools/qemu/qemu/CVE-2016-1568.patch
@@ -32,11 +32,11 @@
  hw/ide/ahci.c | 1 +
  1 file changed, 1 insertion(+)
 
-Index: qemu-2.4.0/hw/ide/ahci.c
+Index: qemu-2.5.0/hw/ide/ahci.c
 ===================================================================
---- qemu-2.4.0.orig/hw/ide/ahci.c
-+++ qemu-2.4.0/hw/ide/ahci.c
-@@ -898,6 +898,7 @@ static void ncq_err(NCQTransferState *nc
+--- qemu-2.5.0.orig/hw/ide/ahci.c
++++ qemu-2.5.0/hw/ide/ahci.c
+@@ -910,6 +910,7 @@ static void ncq_err(NCQTransferState *nc
      ide_state->error = ABRT_ERR;
      ide_state->status = READY_STAT | ERR_STAT;
      ncq_tfs->drive->port_regs.scr_err |= (1 << ncq_tfs->tag);
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/cpus.c-qemu_mutex_lock_iothread-fix-race-condition-a.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/cpus.c-qemu_mutex_lock_iothread-fix-race-condition-a.patch
deleted file mode 100644
index 45dffab..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/cpus.c-qemu_mutex_lock_iothread-fix-race-condition-a.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-Upstream-Status: Submitted
-
-From f354b9333408d411854af058cc44cceda60b4473 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?An=C3=ADbal=20Lim=C3=B3n?= <anibal.limon@linux.intel.com>
-Date: Thu, 3 Sep 2015 14:07:34 -0500
-Subject: [PATCH] cpus.c: qemu_mutex_lock_iothread fix race condition at cpu
- thread init
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-When QEMU starts the RCU thread executes qemu_mutex_lock_thread
-causing error "qemu:qemu_cpu_kick_thread: No such process" and exits.
-
-This isn't occur frequently but in glibc the thread id can exist and
-this not guarantee that the thread is on active/running state. If is
-inserted a sleep(1) after newthread assignment [1] the issue appears.
-
-So not make assumption that thread exist if first_cpu->thread is set
-then change the validation of cpu to created that is set into cpu
-threads (kvm, tcg, dummy).
-
-[1] https://sourceware.org/git/?p=glibc.git;a=blob;f=nptl/pthread_create.c;h=d10f4ea8004e1d8f3a268b95cc0f8d93b8d89867;hb=HEAD#l621
-
-Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
----
- cpus.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/cpus.c b/cpus.c
-index 7e4786e..05e5400 100644
---- a/cpus.c
-+++ b/cpus.c
-@@ -1171,7 +1171,7 @@ void qemu_mutex_lock_iothread(void)
-      * TCG code execution.
-      */
-     if (!tcg_enabled() || qemu_in_vcpu_thread() ||
--        !first_cpu || !first_cpu->thread) {
-+        !first_cpu || !first_cpu->created) {
-         qemu_mutex_lock(&qemu_global_mutex);
-         atomic_dec(&iothread_requesting_mutex);
-     } else {
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/pathlimit.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/pathlimit.patch
new file mode 100644
index 0000000..57ab981
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/qemu/qemu/pathlimit.patch
@@ -0,0 +1,137 @@
+By default qemu builds a complete list of directories within the user
+emulation sysroot (-L option). The OE sysroot directory is large and
+this is confusing, for example it indexes all pkgdata. In particular this
+confuses strace of qemu binaries with tons of irrelevant paths.
+
+This patch stops the code indexing up front and instead only indexes
+things if/as/when it needs to. This drastically reduces the files it
+reads and reduces memory usage and cleans up strace.
+
+It would also avoid the infinite directory traversal bug in [YOCTO #6996]
+although the code could still be vulnerable if it parsed those specific 
+paths.
+
+RP
+2016/3/9
+Upstream-Status: Pending
+
+Index: qemu-2.5.0/util/path.c
+===================================================================
+--- qemu-2.5.0.orig/util/path.c
++++ qemu-2.5.0/util/path.c
+@@ -19,6 +19,7 @@ struct pathelem
+     char *name;
+     /* Full path name, eg. /usr/gnemul/x86-linux/lib. */
+     char *pathname;
++    int populated_entries;
+     struct pathelem *parent;
+     /* Children */
+     unsigned int num_entries;
+@@ -49,6 +50,7 @@ static struct pathelem *new_entry(const
+     new->name = g_strdup(name);
+     new->pathname = g_strdup_printf("%s/%s", root, name);
+     new->num_entries = 0;
++    new->populated_entries = 0;
+     return new;
+ }
+ 
+@@ -57,15 +59,16 @@ static struct pathelem *new_entry(const
+ /* Not all systems provide this feature */
+ #if defined(DT_DIR) && defined(DT_UNKNOWN) && defined(DT_LNK)
+ # define dirent_type(dirent) ((dirent)->d_type)
+-# define is_dir_maybe(type) \
+-    ((type) == DT_DIR || (type) == DT_UNKNOWN || (type) == DT_LNK)
++# define is_not_dir(type) \
++    ((type) != DT_DIR && (type) != DT_UNKNOWN && (type) != DT_LNK)
+ #else
+ # define dirent_type(dirent) (1)
+-# define is_dir_maybe(type)  (type)
++# define is_not_dir(type)  (0)
+ #endif
+ 
+ static struct pathelem *add_dir_maybe(struct pathelem *path)
+ {
++    unsigned int i;
+     DIR *dir;
+ 
+     if ((dir = opendir(path->pathname)) != NULL) {
+@@ -78,6 +81,11 @@ static struct pathelem *add_dir_maybe(st
+         }
+         closedir(dir);
+     }
++
++    for (i = 0; i < path->num_entries; i++)
++        (path->entries[i])->parent = path;
++
++    path->populated_entries = 1;
+     return path;
+ }
+ 
+@@ -93,26 +101,16 @@ static struct pathelem *add_entry(struct
+     e = &root->entries[root->num_entries-1];
+ 
+     *e = new_entry(root->pathname, root, name);
+-    if (is_dir_maybe(type)) {
+-        *e = add_dir_maybe(*e);
++    if (is_not_dir(type)) {
++        (*e)->populated_entries = 1;
+     }
+ 
+     return root;
+ }
+ 
+-/* This needs to be done after tree is stabilized (ie. no more reallocs!). */
+-static void set_parents(struct pathelem *child, struct pathelem *parent)
+-{
+-    unsigned int i;
+-
+-    child->parent = parent;
+-    for (i = 0; i < child->num_entries; i++)
+-        set_parents(child->entries[i], child);
+-}
+-
+ /* FIXME: Doesn't handle DIR/.. where DIR is not in emulated dir. */
+ static const char *
+-follow_path(const struct pathelem *cursor, const char *name)
++follow_path(struct pathelem *cursor, struct pathelem **source, const char *name)
+ {
+     unsigned int i, namelen;
+ 
+@@ -123,14 +121,18 @@ follow_path(const struct pathelem *curso
+         return cursor->pathname;
+ 
+     if (strneq(name, namelen, ".."))
+-        return follow_path(cursor->parent, name + namelen);
++        return follow_path(cursor->parent, &cursor->parent, name + namelen);
+ 
+     if (strneq(name, namelen, "."))
+-        return follow_path(cursor, name + namelen);
++        return follow_path(cursor, source, name + namelen);
++
++    if (!cursor->populated_entries)
++        *source = add_dir_maybe(cursor);
++        cursor = *source;
+ 
+     for (i = 0; i < cursor->num_entries; i++)
+         if (strneq(name, namelen, cursor->entries[i]->name))
+-            return follow_path(cursor->entries[i], name + namelen);
++            return follow_path(cursor->entries[i], &cursor->entries[i], name + namelen);
+ 
+     /* Not found */
+     return NULL;
+@@ -164,8 +166,6 @@ void init_paths(const char *prefix)
+         g_free(base->name);
+         g_free(base);
+         base = NULL;
+-    } else {
+-        set_parents(base, base);
+     }
+ }
+ 
+@@ -177,5 +177,5 @@ const char *path(const char *name)
+     if (!base || !name || name[0] != '/')
+         return name;
+ 
+-    return follow_path(base, name) ?: name;
++    return follow_path(base, &base, name) ?: name;
+ }
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix.patch
deleted file mode 100644
index e37e777..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix.patch
+++ /dev/null
@@ -1,74 +0,0 @@
-The smc91c111.c driver appears to have several issues. The can_receive()
-function can return that the driver is ready when rx_fifo has not been 
-freed yet. There is also no sanity check of rx_fifo() in _receive() which
-can lead to corruption of the rx_fifo array.
-
-release_packet() can also call qemu_flush_queued_packets() before rx_fifo 
-has been cleaned up, resulting in cases where packets are submitted
-for which there is not yet any space.
-
-This patch therefore:
-
-* fixes the logic in can_receive()
-* adds logic to receive() as a sanity check
-* moves the flush() calls to the correct places where data is ready
-  to be received
-
-Upstream-Status: Pending [discussion in progress on mailing list]
-RP 2015/9/7
-
-Index: qemu-2.4.0/hw/net/smc91c111.c
-===================================================================
---- qemu-2.4.0.orig/hw/net/smc91c111.c
-+++ qemu-2.4.0/hw/net/smc91c111.c
-@@ -185,7 +185,6 @@ static void smc91c111_release_packet(smc
-     s->allocated &= ~(1 << packet);
-     if (s->tx_alloc == 0x80)
-         smc91c111_tx_alloc(s);
--    qemu_flush_queued_packets(qemu_get_queue(s->nic));
- }
- 
- /* Flush the TX FIFO.  */
-@@ -237,9 +236,11 @@ static void smc91c111_do_tx(smc91c111_st
-             }
-         }
- #endif
--        if (s->ctr & CTR_AUTO_RELEASE)
-+        if (s->ctr & CTR_AUTO_RELEASE) {
-             /* Race?  */
-             smc91c111_release_packet(s, packetnum);
-+            qemu_flush_queued_packets(qemu_get_queue(s->nic));
-+        }
-         else if (s->tx_fifo_done_len < NUM_PACKETS)
-             s->tx_fifo_done[s->tx_fifo_done_len++] = packetnum;
-         qemu_send_packet(qemu_get_queue(s->nic), p, len);
-@@ -379,9 +380,11 @@ static void smc91c111_writeb(void *opaqu
-                     smc91c111_release_packet(s, s->rx_fifo[0]);
-                 }
-                 smc91c111_pop_rx_fifo(s);
-+                qemu_flush_queued_packets(qemu_get_queue(s->nic));
-                 break;
-             case 5: /* Release.  */
-                 smc91c111_release_packet(s, s->packet_num);
-+                qemu_flush_queued_packets(qemu_get_queue(s->nic));
-                 break;
-             case 6: /* Add to TX FIFO.  */
-                 smc91c111_queue_tx(s, s->packet_num);
-@@ -642,7 +642,7 @@ static int smc91c111_can_receive(NetClie
- 
-     if ((s->rcr & RCR_RXEN) == 0 || (s->rcr & RCR_SOFT_RST))
-         return 1;
--    if (s->allocated == (1 << NUM_PACKETS) - 1)
-+    if ((s->allocated == (1 << NUM_PACKETS) - 1) || (s->rx_fifo_len == NUM_PACKETS))
-         return 0;
-     return 1;
- }
-@@ -671,6 +671,8 @@ static ssize_t smc91c111_receive(NetClie
-     /* TODO: Flag overrun and receive errors.  */
-     if (packetsize > 2048)
-         return -1;
-+    if  (s->rx_fifo_len == NUM_PACKETS)
-+        return -1;    
-     packetnum = smc91c111_allocate_packet(s);
-     if (packetnum == 0x80)
-         return -1;
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix1.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix1.patch
deleted file mode 100644
index bd1223a..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix1.patch
+++ /dev/null
@@ -1,85 +0,0 @@
-From: Peter Crosthwaite <crosthwaitepeter@gmail.com>
-Subject: [RFT PATCH v1 1/3] net: smc91c111: guard flush_queued_packets() on
- can_rx()
-Date: Thu, 10 Sep 2015 21:23:43 -0700
-
-Check that the core can once again receive packets before asking the
-net layer to do a flush. This will make it more convenient to flush
-packets when adding new conditions to can_receive.
-
-Add missing if braces while moving the can_receive() core code.
-
-Signed-off-by: Peter Crosthwaite <crosthwaite.peter@gmail.com>
-
-Upstream-Status: Submitted
-
----
-
- hw/net/smc91c111.c | 30 ++++++++++++++++++++++--------
- 1 file changed, 22 insertions(+), 8 deletions(-)
-
-Index: qemu-2.4.0/hw/net/smc91c111.c
-===================================================================
---- qemu-2.4.0.orig/hw/net/smc91c111.c
-+++ qemu-2.4.0/hw/net/smc91c111.c
-@@ -124,6 +124,24 @@ static void smc91c111_update(smc91c111_s
-     qemu_set_irq(s->irq, level);
- }
- 
-+static int smc91c111_can_receive(smc91c111_state *s)
-+{
-+    if ((s->rcr & RCR_RXEN) == 0 || (s->rcr & RCR_SOFT_RST)) {
-+        return 1;
-+    }
-+    if (s->allocated == (1 << NUM_PACKETS) - 1) {
-+        return 0;
-+    }
-+    return 1;
-+}
-+
-+static inline void smc91c111_flush_queued_packets(smc91c111_state *s)
-+{
-+    if (smc91c111_can_receive(s)) {
-+        qemu_flush_queued_packets(qemu_get_queue(s->nic));
-+    }
-+}
-+
- /* Try to allocate a packet.  Returns 0x80 on failure.  */
- static int smc91c111_allocate_packet(smc91c111_state *s)
- {
-@@ -185,7 +203,7 @@ static void smc91c111_release_packet(smc
-     s->allocated &= ~(1 << packet);
-     if (s->tx_alloc == 0x80)
-         smc91c111_tx_alloc(s);
--    qemu_flush_queued_packets(qemu_get_queue(s->nic));
-+    smc91c111_flush_queued_packets(s);
- }
- 
- /* Flush the TX FIFO.  */
-@@ -636,15 +654,11 @@ static uint32_t smc91c111_readl(void *op
-     return val;
- }
- 
--static int smc91c111_can_receive(NetClientState *nc)
-+static int smc91c111_can_receive_nc(NetClientState *nc)
- {
-     smc91c111_state *s = qemu_get_nic_opaque(nc);
- 
--    if ((s->rcr & RCR_RXEN) == 0 || (s->rcr & RCR_SOFT_RST))
--        return 1;
--    if (s->allocated == (1 << NUM_PACKETS) - 1)
--        return 0;
--    return 1;
-+    return smc91c111_can_receive(s);
- }
- 
- static ssize_t smc91c111_receive(NetClientState *nc, const uint8_t *buf, size_t size)
-@@ -739,7 +753,7 @@ static const MemoryRegionOps smc91c111_m
- static NetClientInfo net_smc91c111_info = {
-     .type = NET_CLIENT_OPTIONS_KIND_NIC,
-     .size = sizeof(NICState),
--    .can_receive = smc91c111_can_receive,
-+    .can_receive = smc91c111_can_receive_nc,
-     .receive = smc91c111_receive,
- };
- 
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix2.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix2.patch
deleted file mode 100644
index 018aed5..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix2.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From: Peter Crosthwaite <crosthwaitepeter@gmail.com>
-X-Google-Original-From: Peter Crosthwaite <crosthwaite.peter@gmail.com>
-To: qemu-devel@nongnu.org
-Cc: peter.maydell@linaro.org, richard.purdie@linuxfoundation.org
-Subject: [RFT PATCH v1 2/3] net: smc91c111: gate can_receive() on rx FIFO
- having a slot
-Date: Thu, 10 Sep 2015 21:23:57 -0700
-
-Return false from can_receive() when the FIFO doesn't have a free RX
-slot. This fixes a bug in the current code where the allocated buffer
-is freed before the fifo pop, triggering a premature flush of queued RX
-packets. It also will handle a corner case, where the guest manually
-frees the allocated buffer before popping the rx FIFO (hence it is not
-enough to just delay the flush_queued_packets()).
-
-Reported-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-Signed-off-by: Peter Crosthwaite <crosthwaite.peter@gmail.com>
-
-Upstream-Status: Submitted
----
-
- hw/net/smc91c111.c | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-Index: qemu-2.4.0/hw/net/smc91c111.c
-===================================================================
---- qemu-2.4.0.orig/hw/net/smc91c111.c
-+++ qemu-2.4.0/hw/net/smc91c111.c
-@@ -129,7 +129,8 @@ static int smc91c111_can_receive(smc91c1
-     if ((s->rcr & RCR_RXEN) == 0 || (s->rcr & RCR_SOFT_RST)) {
-         return 1;
-     }
--    if (s->allocated == (1 << NUM_PACKETS) - 1) {
-+    if (s->allocated == (1 << NUM_PACKETS) - 1 ||
-+        s->rx_fifo_len == NUM_PACKETS) {
-         return 0;
-     }
-     return 1;
-@@ -182,6 +183,7 @@ static void smc91c111_pop_rx_fifo(smc91c
-     } else {
-         s->int_level &= ~INT_RCV;
-     }
-+    smc91c111_flush_queued_packets(s);
-     smc91c111_update(s);
- }
- 
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix3.patch b/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix3.patch
deleted file mode 100644
index 9e865f7..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu/smc91c111_fix3.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From: Peter Crosthwaite <crosthwaitepeter@gmail.com>
-To: qemu-devel@nongnu.org
-Cc: peter.maydell@linaro.org, richard.purdie@linuxfoundation.org
-Subject: [RFT PATCH v1 3/3] net: smc91c111: flush packets on RCR register
- changes
-Date: Thu, 10 Sep 2015 21:24:12 -0700
-
-The SOFT_RST or RXEN in the control register can be used as a condition
-to unblock the net layer via can_receive(). So check for possible
-flushes on RCR changes. This will drop all pending packets on soft
-reset or disable which is the functional intent of the can_receive()
-logic.
-
-Signed-off-by: Peter Crosthwaite <crosthwaite.peter@gmail.com>
-
-Upstream-Status: Submitted
----
-
- hw/net/smc91c111.c | 1 +
- 1 file changed, 1 insertion(+)
-
-Index: qemu-2.4.0/hw/net/smc91c111.c
-===================================================================
---- qemu-2.4.0.orig/hw/net/smc91c111.c
-+++ qemu-2.4.0/hw/net/smc91c111.c
-@@ -331,6 +331,7 @@ static void smc91c111_writeb(void *opaqu
-             if (s->rcr & RCR_SOFT_RST) {
-                 smc91c111_reset(DEVICE(s));
-             }
-+            smc91c111_flush_queued_packets(s);
-             return;
-         case 10: case 11: /* RPCR */
-             /* Ignored */
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu_2.4.0.bb b/yocto-poky/meta/recipes-devtools/qemu/qemu_2.4.0.bb
deleted file mode 100644
index 8d47b16..0000000
--- a/yocto-poky/meta/recipes-devtools/qemu/qemu_2.4.0.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-require qemu.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=441c28d2cf86e15a37fa47e15a72fbac \
-                    file://COPYING.LIB;endline=24;md5=c04def7ae38850e7d3ef548588159913"
-
-SRC_URI += "file://configure-fix-Darwin-target-detection.patch \
-            file://qemu-enlarge-env-entry-size.patch \
-            file://Qemu-Arm-versatilepb-Add-memory-size-checking.patch \
-            file://smc91c111_fix1.patch \
-            file://smc91c111_fix2.patch \
-            file://smc91c111_fix3.patch \
-            file://no-valgrind.patch \
-            file://CVE-2015-8504.patch \
-            file://CVE-2015-7504.patch \
-            file://CVE-2015-7512.patch \
-            file://CVE-2015-8345.patch \
-            file://CVE-2016-1568.patch \
-            file://CVE-2015-7295_1.patch \
-            file://CVE-2015-7295_2.patch \
-            file://CVE-2015-7295_3.patch \
-            file://CVE-2016-2197.patch \
-            file://CVE-2016-2198.patch \
-           "
-SRC_URI_prepend = "http://wiki.qemu-project.org/download/${BP}.tar.bz2"
-SRC_URI[md5sum] = "186ee8194140a484a455f8e3c74589f4"
-SRC_URI[sha256sum] = "72b0b991bbcc540663a019e1e8c4f714053b691dda32c9b9ee80b25f367e6620"
-
-COMPATIBLE_HOST_class-target_mips64 = "null"
-
-do_install_append() {
-    # Prevent QA warnings about installed ${localstatedir}/run
-    if [ -d ${D}${localstatedir}/run ]; then rmdir ${D}${localstatedir}/run; fi
-}
diff --git a/yocto-poky/meta/recipes-devtools/qemu/qemu_2.5.0.bb b/yocto-poky/meta/recipes-devtools/qemu/qemu_2.5.0.bb
new file mode 100644
index 0000000..e9d9a8d
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/qemu/qemu_2.5.0.bb
@@ -0,0 +1,24 @@
+require qemu.inc
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=441c28d2cf86e15a37fa47e15a72fbac \
+                    file://COPYING.LIB;endline=24;md5=c04def7ae38850e7d3ef548588159913"
+
+SRC_URI += "file://configure-fix-Darwin-target-detection.patch \
+            file://qemu-enlarge-env-entry-size.patch \
+            file://Qemu-Arm-versatilepb-Add-memory-size-checking.patch \
+            file://no-valgrind.patch \
+            file://CVE-2016-1568.patch \
+            file://CVE-2016-2197.patch \
+            file://CVE-2016-2198.patch \
+            file://pathlimit.patch \
+           "
+SRC_URI_prepend = "http://wiki.qemu-project.org/download/${BP}.tar.bz2"
+SRC_URI[md5sum] = "f469f2330bbe76e3e39db10e9ac4f8db"
+SRC_URI[sha256sum] = "3443887401619fe33bfa5d900a4f2d6a79425ae2b7e43d5b8c36eb7a683772d4"
+
+COMPATIBLE_HOST_class-target_mips64 = "null"
+
+do_install_append() {
+    # Prevent QA warnings about installed ${localstatedir}/run
+    if [ -d ${D}${localstatedir}/run ]; then rmdir ${D}${localstatedir}/run; fi
+}
diff --git a/yocto-poky/meta/recipes-devtools/quilt/quilt.inc b/yocto-poky/meta/recipes-devtools/quilt/quilt.inc
index 837b36b..4e393c4 100644
--- a/yocto-poky/meta/recipes-devtools/quilt/quilt.inc
+++ b/yocto-poky/meta/recipes-devtools/quilt/quilt.inc
@@ -8,6 +8,7 @@
         file://install.patch \
         file://run-ptest \
         file://Makefile \
+	file://test.sh \
 "
 
 SRC_URI[md5sum] = "fc0310db5868a0873d602d4332a76d43"
@@ -50,8 +51,9 @@
 	tar -cf - bin/ --exclude \*.in | ( cd ${D}${PTEST_PATH} && tar -xf - )
 	tar -cf - compat/ --exclude \*.in | ( cd ${D}${PTEST_PATH} && tar -xf - )
 	tar -cf - quilt/ --exclude \*.in | ( cd ${D}${PTEST_PATH} && tar -xf - )
-	tar -cf - test/ --exclude mail.test --exclude delete.test | ( cd ${D}${PTEST_PATH} && tar -xf - )
+	tar -cf - test/ --exclude mail.test --exclude delete.test | ( cd ${D}${PTEST_PATH} && tar -xf - && chmod 777 test)
 	cp ${WORKDIR}/Makefile ${D}${PTEST_PATH}
+	cp ${WORKDIR}/test.sh ${D}${PTEST_PATH}
 }
 
 RDEPENDS_${PN}-ptest = "make file sed gawk diffutils findutils ed perl \
diff --git a/yocto-poky/meta/recipes-devtools/quilt/quilt/run-ptest b/yocto-poky/meta/recipes-devtools/quilt/quilt/run-ptest
index 958a9df..4b808ae 100755
--- a/yocto-poky/meta/recipes-devtools/quilt/quilt/run-ptest
+++ b/yocto-poky/meta/recipes-devtools/quilt/quilt/run-ptest
@@ -1,5 +1,8 @@
 #!/bin/sh
 
+THIS_SH=/bin/sh
 ln -sf /bin/ed /usr/bin/ed
-for i in `ls test/*.test |awk -F. '{print $1}' |awk -F/ '{print $2}'`; do make check-$i; if [ $? -eq 0 ]; then echo PASS: $i.test; else echo FAIL: $i.test; fi; done
+/usr/sbin/adduser --disabled-password quilttest
+su -c "${THIS_SH} ./test.sh" quilttest
+/usr/sbin/deluser quilttest
 rm -f /usr/bin/ed
diff --git a/yocto-poky/meta/recipes-devtools/quilt/quilt/test.sh b/yocto-poky/meta/recipes-devtools/quilt/quilt/test.sh
new file mode 100755
index 0000000..6563e4a
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/quilt/quilt/test.sh
@@ -0,0 +1 @@
+for i in `ls test/*.test |awk -F. '{print $1}' |awk -F/ '{print $2}'`; do make check-$i; if [ $? -eq 0 ]; then echo PASS: $i.test; else echo FAIL: $i.test; fi; done
diff --git a/yocto-poky/meta/recipes-devtools/remake/remake_4.1+dbg-1.1.bb b/yocto-poky/meta/recipes-devtools/remake/remake_4.1+dbg-1.1.bb
index c61913d..8eab7e3 100644
--- a/yocto-poky/meta/recipes-devtools/remake/remake_4.1+dbg-1.1.bb
+++ b/yocto-poky/meta/recipes-devtools/remake/remake_4.1+dbg-1.1.bb
@@ -4,6 +4,7 @@
                     file://glob/COPYING.LIB;md5=4a770b67e6be0f60da244beb2de0fce4"
 require remake.inc
 
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(\d+(\.\d+)+)\+dbg.+)"
 SRC_URI += "file://version-remake.texi.patch \
            "
 SRCREV = "cf54641d50a0165bb17622b3e9770f426ccbc561"
@@ -14,7 +15,7 @@
 # By default only "gettext-minimal-native" is added
 # when inherit gettext.
 DEPENDS_class-native += "gettext-native"
-PROVIDES += "make"
+PROVIDES += "virtual/make"
 
 do_configure_prepend() {
     # remove the default LINGUAS since we are not going to generate languages
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/add_RPMSENSE_MISSINGOK_to_rpmmodule.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/add_RPMSENSE_MISSINGOK_to_rpmmodule.patch
deleted file mode 100644
index b877870..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/add_RPMSENSE_MISSINGOK_to_rpmmodule.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-Upstream-Status: Inappropriate [OE-Specific]
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-Signed-off-by: Ronan Le Martret <ronan.lemartret@open.eurogiciel.org> 
-
-diff --git a/python/rpmmodule.c b/python/rpmmodule.c
-index a4fe217..728c66c 100644
---- a/python/rpmmodule.c
-+++ b/python/rpmmodule.c
-@@ -396,6 +396,10 @@ static int initModule(PyObject *m)
-     REGISTER_ENUM(RPMSENSE_STRONG);
-     REGISTER_ENUM(RPMSENSE_CONFIG);
- 
-+#if defined(RPM_VENDOR_OE)
-+    REGISTER_ENUM(RPMSENSE_MISSINGOK);
-+#endif
-+
-     REGISTER_ENUM(RPMTRANS_FLAG_TEST);
-     REGISTER_ENUM(RPMTRANS_FLAG_BUILD_PROBS);
-     REGISTER_ENUM(RPMTRANS_FLAG_NOSCRIPTS);
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/disable_shortcircuited.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/disable_shortcircuited.patch
deleted file mode 100644
index 7a646de..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/disable_shortcircuited.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-Upstream-Status: Pending
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-Signed-off-by: Ronan Le Martret <ronan.lemartret@open.eurogiciel.org>
-
-
-Index: rpm-4.11.2/build/pack.c
-===================================================================
---- rpm-4.11.2.orig/build/pack.c
-+++ rpm-4.11.2/build/pack.c
-@@ -571,9 +571,9 @@ rpmRC packageBinaries(rpmSpec spec, cons
- 	    headerPutBin(pkg->header, RPMTAG_SOURCEPKGID, spec->sourcePkgId,16);
- 	}
- 
--	if (cheating) {
--	    (void) rpmlibNeedsFeature(pkg, "ShortCircuited", "4.9.0-1");
--	}
-+//	if (cheating) {
-+//	    (void) rpmlibNeedsFeature(pkg, "ShortCircuited", "4.9.0-1");
-+//	}
- 	
- 	{   char *binFormat = rpmGetPath("%{_rpmfilename}", NULL);
- 	    char *binRpm, *binDir;
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/fix_libdir.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/fix_libdir.patch
deleted file mode 100644
index be0626c..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/fix_libdir.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-Upstream-Status: Inappropriate [OE-Core specific]
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-Signed-off-by: Ronan Le Martret <ronan.lemartret@open.eurogiciel.org>
-
-
-diff --git a/installplatform b/installplatform
-index 8c3eba0..fa15e91 100755
---- a/installplatform
-+++ b/installplatform
-@@ -112,7 +112,7 @@ for ARCH in noarch `grep ^arch_canon $RPMRC | cut -d: -f2`; do
-   [ -z "$CANONARCH" ] && continue
- 
-   if [ "$OS" = "linux" ] && [ "$CANONCOLOR" = 3 ]; then
--      LIB=${LIB}64
-+      LIB=${LIB}
-   fi
- 
-   PPD="${DESTDIR}/${platformdir}/${ARCH}-${OS}"
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/pythondeps.sh b/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/pythondeps.sh
deleted file mode 100755
index 083b174..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/pythondeps.sh
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/sh
-
-[ $# -ge 1 ] || {
-    cat > /dev/null
-    exit 0
-}
-
-case $1 in
--R|--requires)
-    shift
-    grep "/usr/\(lib[^/]*\|share\)/python[^/]*/" >/dev/null && echo "python"
-    exit 0
-    ;;
-esac
-
-exit 0
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/remove-db3-from-configure.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/remove-db3-from-configure.patch
deleted file mode 100644
index 2640e54..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/remove-db3-from-configure.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-
-Disable configuring the db3 directory since we will be using the
-external DB provided as part of OE-Core already, no need to have
-duplicate database code.
-
-Upstream-Status: Inappropriate [OE-Core Specific]
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-
-Index: rpm-4.11.2/configure.ac
-===================================================================
---- rpm-4.11.2.orig/configure.ac
-+++ rpm-4.11.2/configure.ac
-@@ -825,9 +825,9 @@ AC_SUBST(RPMCONFIGDIR)
- 
- AC_SUBST(OBJDUMP)
- 
--if test "$with_external_db" = no; then
--    AC_CONFIG_SUBDIRS(db3)
--fi
-+#if test "$with_external_db" = no; then
-+#    AC_CONFIG_SUBDIRS(db3)
-+#fi
- 
- AM_CONDITIONAL([WITH_INTERNAL_DB],[test "$with_external_db" = no])
- AM_CONDITIONAL([DOXYGEN],[test "$DOXYGEN" != no])
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/remove-dir-check.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/remove-dir-check.patch
deleted file mode 100644
index f1ecab7..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/remove-dir-check.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-Upstream-Status: Pending
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-Signed-off-by: Ronan Le Martret <ronan.lemartret@open.eurogiciel.org>
-
-
-Index: rpm-4.11.2/build/files.c
-===================================================================
---- rpm-4.11.2.orig/build/files.c
-+++ rpm-4.11.2/build/files.c
-@@ -1321,12 +1321,6 @@ static rpmRC addFile(FileList fl, const
- 	}
-     }
- 
--    /* Error out when a non-directory is specified as one in spec */
--    if (fl->cur.isDir && (statp == &statbuf) && !S_ISDIR(statp->st_mode)) {
--	rpmlog(RPMLOG_ERR, _("Not a directory: %s\n"), diskPath);
--	goto exit;
--    }
--
-     /* Don't recurse into explicit %dir, don't double-recurse from fts */
-     if ((fl->cur.isDir != 1) && (statp == &statbuf) && S_ISDIR(statp->st_mode)) {
- 	return recurseDir(fl, diskPath);
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/rpm-scriptetexechelp.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/rpm-scriptetexechelp.patch
deleted file mode 100644
index 9333dea..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/rpm-scriptetexechelp.patch
+++ /dev/null
@@ -1,194 +0,0 @@
-Upstream-Status: Inappropriate [OE-Core]
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-Signed-off-by: Ronan Le Martret <ronan.lemartret@open.eurogiciel.org>
-
-
-Index: rpm-4.11.2/lib/psm.c
-===================================================================
---- rpm-4.11.2.orig/lib/psm.c
-+++ rpm-4.11.2/lib/psm.c
-@@ -421,7 +421,8 @@ static rpmRC runScript(rpmpsm psm, ARGV_
- 
-     rpmswEnter(rpmtsOp(psm->ts, RPMTS_OP_SCRIPTLETS), 0);
-     rc = rpmScriptRun(script, arg1, arg2, sfd,
--		      prefixes, warn_only, selinux);
-+		      prefixes, warn_only, selinux, rpmtsRootDir(psm->ts) );
-+
-     rpmswExit(rpmtsOp(psm->ts, RPMTS_OP_SCRIPTLETS), 0);
- 
-     /* Map warn-only errors to "notfound" for script stop callback */
-@@ -958,15 +959,49 @@ static rpmRC rpmpsmStage(rpmpsm psm, pkg
-     case PSM_DESTROY:
- 	break;
-     case PSM_SCRIPT:	/* Run current package scriptlets. */
-+#ifdef RPM_VENDOR_OE
-+        {
-+        const char * scriptletWrapper = rpmExpand("%{?_cross_scriptlet_wrapper}", NULL);
-+	if (scriptletWrapper && *scriptletWrapper)
-+	     (void) rpmChrootOut();
-+#endif
-+
- 	rc = runInstScript(psm);
-+#ifdef RPM_VENDOR_OE
-+	if (scriptletWrapper && *scriptletWrapper)
-+	     (void) rpmChrootIn();
-+        }
-+#endif
- 	break;
-     case PSM_TRIGGERS:
- 	/* Run triggers in other package(s) this package sets off. */
-+#ifdef RPM_VENDOR_OE
-+        {
-+        const char * scriptletWrapper = rpmExpand("%{?_cross_scriptlet_wrapper}", NULL);
-+	if (scriptletWrapper && *scriptletWrapper)
-+	     (void) rpmChrootOut();
-+#endif
- 	rc = runTriggers(psm);
-+#ifdef RPM_VENDOR_OE
-+	if (scriptletWrapper && *scriptletWrapper)
-+	     (void) rpmChrootIn();
-+        }
-+#endif
- 	break;
-     case PSM_IMMED_TRIGGERS:
- 	/* Run triggers in this package other package(s) set off. */
-+#ifdef RPM_VENDOR_OE
-+	{
-+            const char * scriptletWrapper = rpmExpand("%{?_cross_scriptlet_wrapper}", NULL);
-+	    if (scriptletWrapper && *scriptletWrapper)
-+	     (void) rpmChrootOut();
-+#endif
- 	rc = runImmedTriggers(psm);
-+#ifdef RPM_VENDOR_OE
-+	    if (scriptletWrapper && *scriptletWrapper)
-+	     (void) rpmChrootIn();
-+	}
-+#endif
- 	break;
- 
-     case PSM_RPMDB_ADD: {
-Index: rpm-4.11.2/lib/rpmscript.c
-===================================================================
---- rpm-4.11.2.orig/lib/rpmscript.c
-+++ rpm-4.11.2/lib/rpmscript.c
-@@ -92,7 +92,7 @@ static rpmRC runLuaScript(int selinux, A
- static const char * const SCRIPT_PATH = "PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin";
- 
- static void doScriptExec(int selinux, ARGV_const_t argv, ARGV_const_t prefixes,
--			FD_t scriptFd, FD_t out)
-+			FD_t scriptFd, FD_t out, char * rootDir )
- {
-     int pipes[2];
-     int flag;
-@@ -158,13 +158,12 @@ static void doScriptExec(int selinux, AR
- 	    setenv("RPM_INSTALL_PREFIX", *pf, 1);
- 	}
-     }
--	
--    if (chdir("/") == 0) {
-+    if (chdir(rootDir) == 0) {
- 	/* XXX Don't mtrace into children. */
- 	unsetenv("MALLOC_CHECK_");
- 
- 	/* Permit libselinux to do the scriptlet exec. */
--	if (selinux == 1) {	
-+	if (selinux == 1) {
- 	    xx = rpm_execcon(0, argv[0], argv, environ);
- 	}
- 
-@@ -175,12 +174,12 @@ static void doScriptExec(int selinux, AR
-     _exit(127); /* exit 127 for compatibility with bash(1) */
- }
- 
--static char * writeScript(const char *cmd, const char *script)
-+static char * writeScript(const char *cmd, const char *script, char * rootDir)
- {
-     char *fn = NULL;
-     size_t slen = strlen(script);
-     int ok = 0;
--    FD_t fd = rpmMkTempFile("/", &fn);
-+    FD_t fd = rpmMkTempFile(rootDir, &fn);
- 
-     if (Ferror(fd))
- 	goto exit;
-@@ -204,7 +203,7 @@ exit:
-  */
- static rpmRC runExtScript(int selinux, ARGV_const_t prefixes,
- 		   const char *sname, rpmlogLvl lvl, FD_t scriptFd,
--		   ARGV_t * argvp, const char *script, int arg1, int arg2)
-+		   ARGV_t * argvp, const char *script, int arg1, int arg2,char * rootDir)
- {
-     FD_t out = NULL;
-     char * fn = NULL;
-@@ -215,7 +214,7 @@ static rpmRC runExtScript(int selinux, A
-     rpmlog(RPMLOG_DEBUG, "%s: scriptlet start\n", sname);
- 
-     if (script) {
--	fn = writeScript(*argvp[0], script);
-+	fn = writeScript(*argvp[0], script, rootDir);
- 	if (fn == NULL) {
- 	    rpmlog(RPMLOG_ERR,
- 		   _("Couldn't create temporary file for %s: %s\n"),
-@@ -258,7 +257,7 @@ static rpmRC runExtScript(int selinux, A
-     } else if (pid == 0) {/* Child */
- 	rpmlog(RPMLOG_DEBUG, "%s: execv(%s) pid %d\n",
- 	       sname, *argvp[0], (unsigned)getpid());
--	doScriptExec(selinux, *argvp, prefixes, scriptFd, out);
-+	doScriptExec(selinux, *argvp, prefixes, scriptFd, out, rootDir);
-     }
- 
-     do {
-@@ -297,13 +296,27 @@ exit:
- }
- 
- rpmRC rpmScriptRun(rpmScript script, int arg1, int arg2, FD_t scriptFd,
--		   ARGV_const_t prefixes, int warn_only, int selinux)
-+		   ARGV_const_t prefixes, int warn_only, int selinux, char * rootDir)
- {
-     ARGV_t args = NULL;
-     rpmlogLvl lvl = warn_only ? RPMLOG_WARNING : RPMLOG_ERR;
-     rpmRC rc;
--
--    if (script == NULL) return RPMRC_OK;
-+#ifdef RPM_VENDOR_OE
-+    const char * scriptletWrapper = rpmExpand("%{?_cross_scriptlet_wrapper}", NULL);
-+#endif
-+ 
-+     if (script == NULL) return RPMRC_OK;
-+#ifdef RPM_VENDOR_OE
-+    if (scriptletWrapper && *scriptletWrapper) {
-+       argvAdd(&args, scriptletWrapper);
-+
-+       if ( rootDir ) {
-+         argvAdd(&args, rootDir);
-+       } else {
-+         argvAdd(&args, "/");
-+       }
-+    }
-+#endif
- 
-     /* construct a new argv as we can't modify the one from header */
-     if (script->args) {
-@@ -315,7 +328,7 @@ rpmRC rpmScriptRun(rpmScript script, int
-     if (rstreq(args[0], "<lua>")) {
- 	rc = runLuaScript(selinux, prefixes, script->descr, lvl, scriptFd, &args, script->body, arg1, arg2);
-     } else {
--	rc = runExtScript(selinux, prefixes, script->descr, lvl, scriptFd, &args, script->body, arg1, arg2);
-+	rc = runExtScript(selinux, prefixes, script->descr, lvl, scriptFd, &args, script->body, arg1, arg2, rootDir);
-     }
-     argvFree(args);
- 
-Index: rpm-4.11.2/lib/rpmscript.h
-===================================================================
---- rpm-4.11.2.orig/lib/rpmscript.h
-+++ rpm-4.11.2/lib/rpmscript.h
-@@ -29,7 +29,7 @@ rpmScript rpmScriptFree(rpmScript script
- 
- RPM_GNUC_INTERNAL
- rpmRC rpmScriptRun(rpmScript script, int arg1, int arg2, FD_t scriptFd,
--                   ARGV_const_t prefixes, int warn_only, int selinux);
-+                   ARGV_const_t prefixes, int warn_only, int selinux, char * rootDir);
- 
- RPM_GNUC_INTERNAL
- rpmTagVal rpmScriptTag(rpmScript script);
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/support-suggests-tag.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/support-suggests-tag.patch
deleted file mode 100644
index 3da6085..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/support-suggests-tag.patch
+++ /dev/null
@@ -1,384 +0,0 @@
-
-Upstream-Status: Pending
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-Signed-off-by: Ronan Le Martret <ronan.lemartret@open.eurogiciel.org>
-
-diff --git a/build/pack.c b/build/pack.c
-index b6b2bea..5c3d8df 100644
---- a/build/pack.c
-+++ b/build/pack.c
-@@ -273,8 +273,10 @@ static rpmTagVal depevrtags[] = {
-     RPMTAG_CONFLICTVERSION,
-     RPMTAG_ORDERVERSION,
-     RPMTAG_TRIGGERVERSION,
--    RPMTAG_SUGGESTSVERSION,
--    RPMTAG_ENHANCESVERSION,
-+    RPMTAG_SUGGESTVERSION,
-+    RPMTAG_ENHANCEVERSION,
-+    RPMTAG_RECOMMENDVERSION,
-+    RPMTAG_SUPPLEMENTVERSION,
-     0
- };
- 
-diff --git a/build/parsePreamble.c b/build/parsePreamble.c
-index 5772bef..cbbbee3 100644
---- a/build/parsePreamble.c
-+++ b/build/parsePreamble.c
-@@ -821,6 +821,10 @@ static rpmRC handlePreambleTag(rpmSpec spec, Package pkg, rpmTagVal tag,
- 	}
- 	/* fallthrough */
-     case RPMTAG_PREREQ:
-+    case RPMTAG_RECOMMENDFLAGS:
-+    case RPMTAG_SUGGESTFLAGS:
-+    case RPMTAG_SUPPLEMENTFLAGS:
-+    case RPMTAG_ENHANCEFLAGS:
-     case RPMTAG_CONFLICTFLAGS:
-     case RPMTAG_OBSOLETEFLAGS:
-     case RPMTAG_PROVIDEFLAGS:
-@@ -922,6 +926,10 @@ static struct PreambleRec_s const preambleList[] = {
-     {RPMTAG_ICON,		0, 0, LEN_AND_STR("icon")},
-     {RPMTAG_PROVIDEFLAGS,	0, 0, LEN_AND_STR("provides")},
-     {RPMTAG_REQUIREFLAGS,	2, 0, LEN_AND_STR("requires")},
-+    {RPMTAG_RECOMMENDFLAGS,	0, 0, LEN_AND_STR("recommends")},
-+    {RPMTAG_SUGGESTFLAGS,	0, 0, LEN_AND_STR("suggests")},
-+    {RPMTAG_SUPPLEMENTFLAGS,	0, 0, LEN_AND_STR("supplements")},
-+    {RPMTAG_ENHANCEFLAGS,	0, 0, LEN_AND_STR("enhances")},
-     {RPMTAG_PREREQ,		2, 1, LEN_AND_STR("prereq")},
-     {RPMTAG_CONFLICTFLAGS,	0, 0, LEN_AND_STR("conflicts")},
-     {RPMTAG_OBSOLETEFLAGS,	0, 0, LEN_AND_STR("obsoletes")},
-diff --git a/build/parseReqs.c b/build/parseReqs.c
-index ba080a1..1427111 100644
---- a/build/parseReqs.c
-+++ b/build/parseReqs.c
-@@ -61,6 +61,18 @@ rpmRC parseRCPOT(rpmSpec spec, Package pkg, const char *field, rpmTagVal tagN,
- 	nametag = RPMTAG_REQUIRENAME;
- 	tagflags |= RPMSENSE_ANY;
- 	break;
-+    case RPMTAG_RECOMMENDFLAGS:
-+	nametag = RPMTAG_RECOMMENDNAME;
-+	break;
-+    case RPMTAG_SUGGESTFLAGS:
-+	nametag = RPMTAG_SUGGESTNAME;
-+	break;
-+    case RPMTAG_SUPPLEMENTFLAGS:
-+	nametag = RPMTAG_SUPPLEMENTNAME;
-+	break;
-+    case RPMTAG_ENHANCEFLAGS:
-+	nametag = RPMTAG_ENHANCENAME;
-+	break;
-     case RPMTAG_PROVIDEFLAGS:
- 	nametag = RPMTAG_PROVIDENAME;
- 	break;
-diff --git a/build/reqprov.c b/build/reqprov.c
-index a368f42..c270af6 100644
---- a/build/reqprov.c
-+++ b/build/reqprov.c
-@@ -81,6 +81,30 @@ int addReqProv(Package pkg, rpmTagVal tagN,
- 	extra = Flags & RPMSENSE_TRIGGER;
- 	dsp = &pkg->triggers;
- 	break;
-+    case RPMTAG_RECOMMENDNAME:
-+	versiontag = RPMTAG_RECOMMENDVERSION;
-+	flagtag = RPMTAG_RECOMMENDFLAGS;
-+	extra = Flags & _ALL_REQUIRES_MASK;
-+	dsp = &pkg->recommends;
-+	break;
-+    case RPMTAG_SUGGESTNAME:
-+	versiontag = RPMTAG_SUGGESTVERSION;
-+	flagtag = RPMTAG_SUGGESTFLAGS;
-+	extra = Flags & _ALL_REQUIRES_MASK;
-+	dsp = &pkg->suggests;
-+	break;
-+    case RPMTAG_SUPPLEMENTNAME:
-+	versiontag = RPMTAG_SUPPLEMENTVERSION;
-+	flagtag = RPMTAG_SUPPLEMENTFLAGS;
-+	extra = Flags & _ALL_REQUIRES_MASK;
-+	dsp = &pkg->supplements;
-+	break;
-+    case RPMTAG_ENHANCENAME:
-+	versiontag = RPMTAG_ENHANCEVERSION;
-+	flagtag = RPMTAG_ENHANCEFLAGS;
-+	extra = Flags & _ALL_REQUIRES_MASK;
-+	dsp = &pkg->enhances;
-+	break;
-     case RPMTAG_REQUIRENAME:
-     default:
- 	tagN = RPMTAG_REQUIRENAME;
-diff --git a/build/rpmbuild_internal.h b/build/rpmbuild_internal.h
-index a9e4c7c..0a1977f 100644
---- a/build/rpmbuild_internal.h
-+++ b/build/rpmbuild_internal.h
-@@ -93,6 +93,10 @@ struct Package_s {
-     rpmds ds;			/*!< Requires: N = EVR */
-     rpmds requires;
-     rpmds provides;
-+    rpmds recommends;
-+    rpmds suggests;
-+    rpmds supplements;
-+    rpmds enhances;
-     rpmds conflicts;
-     rpmds obsoletes;
-     rpmds triggers;
-diff --git a/build/spec.c b/build/spec.c
-index 703ec78..7ae2120 100644
---- a/build/spec.c
-+++ b/build/spec.c
-@@ -139,6 +139,11 @@ static Package freePackage(Package pkg)
-     pkg->ds = rpmdsFree(pkg->ds);
-     pkg->requires = rpmdsFree(pkg->requires);
-     pkg->provides = rpmdsFree(pkg->provides);
-+    pkg->recommends = rpmdsFree(pkg->recommends);
-+    pkg->suggests = rpmdsFree(pkg->suggests);
-+    pkg->supplements = rpmdsFree(pkg->supplements);
-+    pkg->enhances = rpmdsFree(pkg->enhances);
-+
-     pkg->conflicts = rpmdsFree(pkg->conflicts);
-     pkg->obsoletes = rpmdsFree(pkg->obsoletes);
-     pkg->triggers = rpmdsFree(pkg->triggers);
-diff --git a/lib/rpmds.c b/lib/rpmds.c
-index 7a51167..1e5dda0 100644
---- a/lib/rpmds.c
-+++ b/lib/rpmds.c
-@@ -52,6 +52,22 @@ static int dsType(rpmTagVal tag,
- 	t = "Requires";
- 	evr = RPMTAG_REQUIREVERSION;
- 	f = RPMTAG_REQUIREFLAGS;
-+    } else if (tag == RPMTAG_SUPPLEMENTNAME) {
-+	t = "Supplements";
-+	evr = RPMTAG_SUPPLEMENTVERSION;
-+	f = RPMTAG_SUPPLEMENTFLAGS;
-+    } else if (tag == RPMTAG_ENHANCENAME) {
-+	t = "Enhances";
-+	evr = RPMTAG_ENHANCEVERSION;
-+	f = RPMTAG_ENHANCEFLAGS;
-+    } else if (tag == RPMTAG_RECOMMENDNAME) {
-+	t = "Recommends";
-+	evr = RPMTAG_RECOMMENDVERSION;
-+	f = RPMTAG_RECOMMENDFLAGS;
-+    } else if (tag == RPMTAG_SUGGESTNAME) {
-+	t = "Suggests";
-+	evr = RPMTAG_SUGGESTVERSION;
-+	f = RPMTAG_SUGGESTFLAGS;
-     } else if (tag == RPMTAG_CONFLICTNAME) {
- 	t = "Conflicts";
- 	evr = RPMTAG_CONFLICTVERSION;
-diff --git a/lib/rpmtag.h b/lib/rpmtag.h
-index 64b03f1..b943229 100644
---- a/lib/rpmtag.h
-+++ b/lib/rpmtag.h
-@@ -217,14 +217,14 @@ typedef enum rpmTag_e {
-     RPMTAG_PRETRANSPROG		= 1153,	/* s[] */
-     RPMTAG_POSTTRANSPROG	= 1154,	/* s[] */
-     RPMTAG_DISTTAG		= 1155,	/* s */
--    RPMTAG_SUGGESTSNAME		= 1156,	/* s[] extension (unimplemented) */
--#define	RPMTAG_SUGGESTS RPMTAG_SUGGESTSNAME	/* s[] (unimplemented) */
--    RPMTAG_SUGGESTSVERSION	= 1157,	/* s[] extension (unimplemented) */
--    RPMTAG_SUGGESTSFLAGS	= 1158,	/* i[] extension (unimplemented) */
--    RPMTAG_ENHANCESNAME		= 1159,	/* s[] extension placeholder (unimplemented) */
--#define	RPMTAG_ENHANCES RPMTAG_ENHANCESNAME	/* s[] (unimplemented) */
--    RPMTAG_ENHANCESVERSION	= 1160,	/* s[] extension placeholder (unimplemented) */
--    RPMTAG_ENHANCESFLAGS	= 1161,	/* i[] extension placeholder (unimplemented) */
-+    RPMTAG_OLDSUGGESTSNAME	= 1156,	/* s[] (unimplemented) */
-+#define	RPMTAG_OLDSUGGESTS RPMTAG_OLDSUGGESTSNAME /* s[] (unimplemented) */
-+    RPMTAG_OLDSUGGESTSVERSION	= 1157,	/* s[] (unimplemented) */
-+    RPMTAG_OLDSUGGESTSFLAGS	= 1158,	/* i[] (unimplemented) */
-+    RPMTAG_OLDENHANCESNAME		= 1159,	/* s[] (unimplemented) */
-+#define	RPMTAG_OLDENHANCES RPMTAG_OLDENHANCESNAME /* s[] (unimplemented) */
-+    RPMTAG_OLDENHANCESVERSION	= 1160,	/* s[] (unimplemented) */
-+    RPMTAG_OLDENHANCESFLAGS	= 1161,	/* i[] (unimplemented) */
-     RPMTAG_PRIORITY		= 1162, /* i[] extension placeholder (unimplemented) */
-     RPMTAG_CVSID		= 1163, /* s (unimplemented) */
- #define	RPMTAG_SVNID	RPMTAG_CVSID	/* s (unimplemented) */
-@@ -261,6 +261,7 @@ typedef enum rpmTag_e {
-     RPMTAG_BUILDOBSOLETES	= 1194, /* internal (unimplemented) */
-     RPMTAG_DBINSTANCE		= 1195, /* i extension */
-     RPMTAG_NVRA			= 1196, /* s extension */
-+
-     /* tags 1997-4999 reserved */
-     RPMTAG_FILENAMES		= 5000, /* s[] extension */
-     RPMTAG_FILEPROVIDE		= 5001, /* s[] extension */
-@@ -307,6 +308,26 @@ typedef enum rpmTag_e {
-     RPMTAG_OBSOLETENEVRS	= 5043, /* s[] extension */
-     RPMTAG_CONFLICTNEVRS	= 5044, /* s[] extension */
-     RPMTAG_FILENLINKS		= 5045,	/* i[] extension */
-+    RPMTAG_RECOMMENDNAME	= 5046,	/* s[] */
-+#define	RPMTAG_RECOMMENDS RPMTAG_RECOMMENDNAME	/* s[] */
-+    RPMTAG_RECOMMENDVERSION	= 5047,	/* s[] */
-+    RPMTAG_RECOMMENDFLAGS	= 5048,	/* i[] */
-+    RPMTAG_SUGGESTNAME		= 5049,	/* s[] */
-+#define	RPMTAG_SUGGESTS RPMTAG_SUGGESTNAME	/* s[] */
-+    RPMTAG_SUGGESTVERSION	= 5050,	/* s[] extension */
-+    RPMTAG_SUGGESTFLAGS		= 5051,	/* i[] extension */
-+    RPMTAG_SUPPLEMENTNAME	= 5052,	/* s[] */
-+#define	RPMTAG_SUPPLEMENTS RPMTAG_SUPPLEMENTNAME /* s[] */
-+    RPMTAG_SUPPLEMENTVERSION	= 5053,	/* s[] */
-+    RPMTAG_SUPPLEMENTFLAGS	= 5054,	/* i[] */
-+    RPMTAG_ENHANCENAME		= 5055,	/* s[] */
-+#define	RPMTAG_ENHANCES RPMTAG_ENHANCENAME	/* s[] */
-+    RPMTAG_ENHANCEVERSION	= 5056,	/* s[] */
-+    RPMTAG_ENHANCEFLAGS		= 5057,	/* i[] */
-+    RPMTAG_RECOMMENDNEVRS	= 5058, /* s[] extension */
-+    RPMTAG_SUGGESTNEVRS		= 5059, /* s[] extension */
-+    RPMTAG_SUPPLEMENTNEVRS	= 5060, /* s[] extension */
-+    RPMTAG_ENHANCENEVRS		= 5061, /* s[] extension */
- 
-     RPMTAG_FIRSTFREE_TAG	/*!< internal */
- } rpmTag;
-diff --git a/lib/tagexts.c b/lib/tagexts.c
-index 29b2bae..e940310 100644
---- a/lib/tagexts.c
-+++ b/lib/tagexts.c
-@@ -761,6 +761,26 @@ static int requirenevrsTag(Header h, rpmtd td, headerGetFlags hgflags)
-     return depnevrsTag(h, td, hgflags, RPMTAG_REQUIRENAME);
- }
- 
-+static int recommendnevrsTag(Header h, rpmtd td, headerGetFlags hgflags)
-+{
-+    return depnevrsTag(h, td, hgflags, RPMTAG_RECOMMENDNAME);
-+}
-+
-+static int suggestnevrsTag(Header h, rpmtd td, headerGetFlags hgflags)
-+{
-+    return depnevrsTag(h, td, hgflags, RPMTAG_SUGGESTNAME);
-+}
-+
-+static int supplementnevrsTag(Header h, rpmtd td, headerGetFlags hgflags)
-+{
-+    return depnevrsTag(h, td, hgflags, RPMTAG_SUPPLEMENTNAME);
-+}
-+
-+static int enhancenevrsTag(Header h, rpmtd td, headerGetFlags hgflags)
-+{
-+    return depnevrsTag(h, td, hgflags, RPMTAG_ENHANCENAME);
-+}
-+
- static int providenevrsTag(Header h, rpmtd td, headerGetFlags hgflags)
- {
-     return depnevrsTag(h, td, hgflags, RPMTAG_PROVIDENAME);
-@@ -823,6 +843,10 @@ static const struct headerTagFunc_s rpmHeaderTagExtensions[] = {
-     { RPMTAG_EPOCHNUM,		epochnumTag },
-     { RPMTAG_INSTFILENAMES,	instfilenamesTag },
-     { RPMTAG_REQUIRENEVRS,	requirenevrsTag },
-+    { RPMTAG_RECOMMENDNEVRS,	recommendnevrsTag},
-+    { RPMTAG_SUGGESTNEVRS,	suggestnevrsTag},
-+    { RPMTAG_SUPPLEMENTNEVRS,	supplementnevrsTag},
-+    { RPMTAG_ENHANCENEVRS,	enhancenevrsTag},
-     { RPMTAG_PROVIDENEVRS,	providenevrsTag },
-     { RPMTAG_OBSOLETENEVRS,	obsoletenevrsTag },
-     { RPMTAG_CONFLICTNEVRS,	conflictnevrsTag },
-diff --git a/rpmpopt.in b/rpmpopt.in
-index 805599e..036ab4e 100644
---- a/rpmpopt.in
-+++ b/rpmpopt.in
-@@ -67,6 +67,19 @@ rpm	alias --requires	--qf \
- 	--POPTdesc=$"list capabilities required by package(s)"
- rpm	alias -R --requires
- 
-+rpm	alias --recommends	--qf \
-+  "[%|VERBOSE?{%{RECOMMENDFLAGS:deptype}: }:{}|%{RECOMMENDNEVRS}\n]" \
-+	--POPTdesc=$"list capabilities recommended by package(s)"
-+rpm	alias --suggests	--qf \
-+  "[%|VERBOSE?{%{SUGGESTFLAGS:deptype}: }:{}|%{SUGGESTNEVRS}\n]" \
-+	--POPTdesc=$"list capabilities suggested by package(s)"
-+rpm	alias --supplements	--qf \
-+  "[%|VERBOSE?{%{SUPPLEMENTFLAGS:deptype}: }:{}|%{SUPPLEMENTNEVRS}\n]" \
-+	--POPTdesc=$"list capabilities supplemented by package(s)"
-+rpm	alias --enhances	--qf \
-+  "[%|VERBOSE?{%{ENHANCEFLAGS:deptype}: }:{}|%{ENHANCENEVRS}\n]" \
-+	--POPTdesc=$"list capabilities enhanced by package(s)"
-+
- rpm	alias --info --qf '\
- Name        : %{NAME}\n\
- %|EPOCH?{Epoch       : %{EPOCH}\n}|\
-diff --git a/tests/data/SPECS/deptest.spec b/tests/data/SPECS/deptest.spec
-index cb4cbbd..7c47f6d 100644
---- a/tests/data/SPECS/deptest.spec
-+++ b/tests/data/SPECS/deptest.spec
-@@ -10,6 +10,10 @@ BuildArch:	noarch
- %{?provs:Provides: %{provs}}
- %{?cfls:Conflicts: %{cfls}}
- %{?obs:Obsoletes: %{obs}}
-+%{?recs:Recommends: %{recs}}
-+%{?sugs:Suggests: %{sugs}}
-+%{?sups:Supplements: %{sups}}
-+%{?ens:Enhances: %{ens}}
- 
- %description
- %{summary}
-diff --git a/tests/rpmbuild.at b/tests/rpmbuild.at
-index 6230903..c4c954c 100644
---- a/tests/rpmbuild.at
-+++ b/tests/rpmbuild.at
-@@ -185,3 +185,25 @@ lrwxrwxrwx /opt/globtest/linkgood
- ],
- [])
- AT_CLEANUP
-+
-+# ------------------------------
-+# Check if weak and reverse requires can be built
-+AT_SETUP([Weak and reverse requires])
-+AT_KEYWORDS([build])
-+AT_CHECK([
-+
-+runroot rpmbuild -bb --quiet \
-+	--define "pkg weakdeps" \
-+	--define "recs foo > 1.2.3" \
-+	--define "sugs bar >= 0.1.2" \
-+	--define "sups baz" \
-+	--define "ens zap = 3" \
-+	  /data/SPECS/deptest.spec
-+
-+runroot rpm -qp --qf "[%{supplementname}\n]" /build/RPMS/noarch/deptest-weakdeps-1.0-1.noarch.rpm
-+],
-+[0],
-+[baz
-+],
-+[ignore])
-+AT_CLEANUP
-diff --git a/tests/rpmgeneral.at b/tests/rpmgeneral.at
-index 13131e2..80cca63 100644
---- a/tests/rpmgeneral.at
-+++ b/tests/rpmgeneral.at
-@@ -79,6 +79,11 @@ DISTTAG
- DISTURL
- DSAHEADER
- E
-+ENHANCEFLAGS
-+ENHANCENAME
-+ENHANCENEVRS
-+ENHANCES
-+ENHANCEVERSION
- EPOCH
- EPOCHNUM
- EVR
-@@ -199,6 +204,11 @@ PROVIDES
- PROVIDEVERSION
- PUBKEYS
- R
-+RECOMMENDFLAGS
-+RECOMMENDNAME
-+RECOMMENDNEVRS
-+RECOMMENDS
-+RECOMMENDVERSION
- RECONTEXTS
- RELEASE
- REMOVETID
-@@ -219,7 +229,17 @@ SOURCE
- SOURCEPACKAGE
- SOURCEPKGID
- SOURCERPM
-+SUGGESTFLAGS
-+SUGGESTNAME
-+SUGGESTNEVRS
-+SUGGESTS
-+SUGGESTVERSION
- SUMMARY
-+SUPPLEMENTFLAGS
-+SUPPLEMENTNAME
-+SUPPLEMENTNEVRS
-+SUPPLEMENTS
-+SUPPLEMENTVERSION
- TRIGGERCONDS
- TRIGGERFLAGS
- TRIGGERINDEX
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/use-pkgconfig-for-python.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/use-pkgconfig-for-python.patch
deleted file mode 100644
index 8d84cf8..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm-4.11.2/use-pkgconfig-for-python.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-
-Use pkgconfig to get the correct include paths
-
-Upstream-Status: Pending
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-Signed-off-by: Ronan Le Martret <ronan.lemartret@open.eurogiciel.org>
-
-diff --git a/configure.ac b/configure.ac
-index e97f727..8179f44 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -540,10 +540,10 @@ esac],
- 
- AS_IF([test "$enable_python" = yes],[
-   AM_PATH_PYTHON([2.6],[
--    WITH_PYTHON_INCLUDE=`${PYTHON} -c 'from distutils.sysconfig import *; import sys; sys.stdout.write(get_python_inc())'`
-+    WITH_PYTHON_INCLUDE=$(${PKG_CONFIG} --cflags-only-I  python)
-     WITH_PYTHON_SUBPACKAGE=1
-     save_CPPFLAGS="$CPPFLAGS"
--    CPPFLAGS="$CPPFLAGS -I$WITH_PYTHON_INCLUDE"
-+    CPPFLAGS="$CPPFLAGS $WITH_PYTHON_INCLUDE"
-     AC_CHECK_HEADER([Python.h],[],
-       [AC_MSG_ERROR([missing Python.h])
-       ])
-diff --git a/python/Makefile.am b/python/Makefile.am
-index fff51ae..f37cb9d 100644
---- a/python/Makefile.am
-+++ b/python/Makefile.am
-@@ -4,7 +4,7 @@ EXTRA_DIST = rpm/__init__.py rpm/transaction.py
- 
- AM_CPPFLAGS = -I$(top_builddir)/include/
- AM_CPPFLAGS += -I$(top_srcdir)/python
--AM_CPPFLAGS += -I@WITH_PYTHON_INCLUDE@
-+AM_CPPFLAGS += @WITH_PYTHON_INCLUDE@
- 
- pkgpyexec_LTLIBRARIES = _rpmmodule.la _rpmbmodule.la _rpmsmodule.la
- pkgpyexec_DATA = rpm/__init__.py rpm/transaction.py
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-Disable-__sync_add_and_fetch_8-on-nios2.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-Disable-__sync_add_and_fetch_8-on-nios2.patch
new file mode 100644
index 0000000..e9b73b8
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-Disable-__sync_add_and_fetch_8-on-nios2.patch
@@ -0,0 +1,30 @@
+From 06967a50f20095f5ca30b8214f4c98ba0f5262bf Mon Sep 17 00:00:00 2001
+From: Marek Vasut <marex@denx.de>
+Date: Sun, 3 Apr 2016 06:55:25 +0200
+Subject: [PATCH] Disable __sync_add_and_fetch_8 on nios2
+
+The NIOS2 softcore does not implement the __sync_add_and_fetch_8,
+so disable it accordingly.
+
+Signed-off-by: Marek Vasut <marex@denx.de>
+Upstream-Status: Submitted
+---
+ rpmio/bson.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/rpmio/bson.h b/rpmio/bson.h
+index 57023f1..60c7d02 100644
+--- a/rpmio/bson.h
++++ b/rpmio/bson.h
+@@ -880,7 +880,7 @@ BSON_END_DECLS
+ BSON_BEGIN_DECLS
+ 
+ /* Some architectures do not support __sync_add_and_fetch_8 */
+-#if (__mips == 32) || (defined(__PPC__) && !defined(__GCC_HAVE_SYNC_COMPARE_AND_SWAP_8))
++#if (__mips == 32) || (__nios2__) || (defined(__PPC__) && !defined(__GCC_HAVE_SYNC_COMPARE_AND_SWAP_8))
+ # define __BSON_NEED_ATOMIC_64 1
+ #endif
+ 
+-- 
+2.8.0.rc3
+
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-define-EM_AARCH64.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-define-EM_AARCH64.patch
new file mode 100644
index 0000000..c9fb268
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-define-EM_AARCH64.patch
@@ -0,0 +1,35 @@
+[PATCH] define EM_AARCH64
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+EM_AARCH64 maybe not be defined due to old version elf.h, and lead to
+that debugedit can not work on aarch64 elf object files, since there is
+no other dependence, except these two macro, define them to make
+debugedit work on aarch64 elf files.
+
+Signed-off-by: Roy Li <rongqing.li@windriver.com>
+---
+ tools/debugedit.c | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/tools/debugedit.c b/tools/debugedit.c
+index de693ed..d16a641 100644
+--- a/tools/debugedit.c
++++ b/tools/debugedit.c
+@@ -35,6 +35,13 @@
+ 
+ #include <gelf.h>
+ 
++#ifndef EM_AARCH64
++#define EM_AARCH64      183             /* ARM AARCH64 */
++#endif
++#ifndef R_AARCH64_ABS32
++#define R_AARCH64_ABS32 258
++#endif 
++
+ /* some defines taken from the dwarf standard */
+ 
+ #define DW_TAG_compile_unit	0x11
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-rpm-Fix-build-on-musl.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-rpm-Fix-build-on-musl.patch
new file mode 100644
index 0000000..70dd4ff
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-rpm-Fix-build-on-musl.patch
@@ -0,0 +1,294 @@
+From 0af17c2ae86c1e8e42b96f6dface08f535bb55ad Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 14 Feb 2016 08:33:24 +0000
+Subject: [PATCH] rpm: Fix build on musl
+
+Provide alternatives to assumptions about glibc
+on linux
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Updated to 5.4.16 (CVS)
+
+The patch will likely need additional rework before it can be accepted upsteam
+due to the way MUSL changes are patched in.
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+---
+Upstream-Status: Pending
+
+ lib/poptALL.c          |    2 ++
+ rpmio/fts.c            |    4 ++++
+ rpmio/poptIO.c         |    2 ++
+ rpmqv.c                |    2 ++
+ system.h               |   13 ++++++-------
+ tools/debugedit.c      |   47 +++++++++++++++++++++++++++++++++++++++++++++++
+ tools/rpm2cpio.c       |    2 ++
+ tools/rpmcache.c       |    2 ++
+ tools/rpmcmp.c         |    2 ++
+ tools/rpmdeps-oecore.c |    2 ++
+ tools/rpmdeps.c        |    2 ++
+ tools/rpmdigest.c      |    2 ++
+ tools/rpmfind.c        |    6 +++---
+ 13 files changed, 78 insertions(+), 10 deletions(-)
+
+Index: rpm-5.4.15/rpmio/fts.c
+===================================================================
+--- rpm-5.4.15.orig/rpmio/fts.c
++++ rpm-5.4.15/rpmio/fts.c
+@@ -124,6 +124,10 @@ static char sccsid[] = "@(#)fts.c	8.6 (B
+ #   define __fxstat64(_stat_ver, _fd, _sbp)    fstat((_fd), (_sbp))
+ #endif
+ 
++#ifndef _STAT_VER
++#   define _STAT_VER      0
++#endif
++
+ #if !defined(_D_EXACT_NAMLEN)
+ #   define _D_EXACT_NAMLEN(d) (strlen((d)->d_name))
+ #endif
+Index: rpm-5.4.15/tools/debugedit.c
+===================================================================
+--- rpm-5.4.15.orig/tools/debugedit.c
++++ rpm-5.4.15/tools/debugedit.c
+@@ -22,7 +22,12 @@
+ #include <byteswap.h>
+ #include <endian.h>
+ #include <errno.h>
++#ifdef __GLIBC__
+ #include <error.h>
++#else
++#include <stdarg.h>
++void error(int, int, const char *, ...);
++#endif
+ #include <limits.h>
+ #include <string.h>
+ #include <stdlib.h>
+@@ -1535,6 +1540,48 @@ handle_build_id (DSO *dso, Elf_Data *bui
+     puts (hex);
+   }
+ }
++#ifndef __GLIBC__
++extern char *__progname;
++
++void (*error_print_progname)(void) = 0;
++unsigned int error_message_count = 0;
++int error_one_per_line = 0;
++
++static void eprint(int status, int e, const char *file, unsigned int line, const char *fmt, va_list ap)
++{
++       if (file && error_one_per_line) {
++               static const char *oldfile;
++               static unsigned int oldline;
++               if (line == oldline && strcmp(file, oldfile) == 0)
++                       return;
++               oldfile = file;
++               oldline = line;
++       }
++       if (error_print_progname)
++               error_print_progname();
++       else
++               fprintf(stderr, "%s: ", __progname);
++       if (file)
++               fprintf(stderr, "%s:%u: ", file, line);
++       vfprintf(stderr, fmt, ap);
++      if (e)
++               fprintf(stderr, ": %s", strerror(e));
++       putc('\n', stderr);
++       fflush(stderr);
++       error_message_count++;
++       if (status)
++               exit(status);
++}
++
++void error(int status, int e, const char *fmt, ...)
++{
++       va_list ap;
++       va_start(ap,fmt);
++       eprint(status, e, 0, 0, fmt, ap);
++       va_end(ap);
++}
++
++#endif
+ 
+ /* It avoided the segment fault while file's bss offset have a large number.
+    See https://bugzilla.redhat.com/show_bug.cgi?id=1019707
+Index: rpm-5.4.15/tools/rpmfind.c
+===================================================================
+--- rpm-5.4.15.orig/tools/rpmfind.c
++++ rpm-5.4.15/tools/rpmfind.c
+@@ -1175,7 +1175,7 @@ find_parsenum(PLAN *plan, const char *op
+      * and endchar points to the beginning of the string we know we have
+      * a syntax error.
+      */
+-#if defined(__sun)
++#if defined(__sun) || !defined(__GLIBC_)
+     value = strtoll(str, &endchar, 10);
+ #else
+     value = strtoq(str, &endchar, 10);
+@@ -1215,7 +1215,7 @@ find_parsetime(PLAN *plan, const char *o
+ 	break;
+     }
+ 
+-#if defined(__sun)
++#if defined(__sun) || !defined(__GLIBC_)
+     value = strtoll(str, &unit, 10);
+ #else
+     value = strtoq(str, &unit, 10);
+@@ -1253,7 +1253,7 @@ find_parsetime(PLAN *plan, const char *o
+ 	str = unit + 1;
+ 	if (*str == '\0')	/* EOS */
+ 	    break;
+-#if defined(__sun)
++#if defined(__sun) || !defined(__GLIBC_)
+ 	value = strtoll(str, &unit, 10);
+ #else
+ 	value = strtoq(str, &unit, 10);
+Index: rpm-5.4.15/system.h
+===================================================================
+--- rpm-5.4.15.orig/system.h
++++ rpm-5.4.15/system.h
+@@ -372,16 +372,15 @@ extern int _tolower(int) __THROW	/*@*/;
+ #define	__progname	__assert_program_name
+ #endif
+ #define	setprogname(pn)
++/*@unchecked@*/
++extern const char *__progname;
+ #else
+-#define	__progname	program_name
+-#define	setprogname(pn)	\
+-  { if ((__progname = strrchr(pn, '/')) != NULL) __progname++; \
+-    else __progname = pn;		\
+-  }
+-#endif
++#define	setprogname(pn)
++#define	progname	__progname
+ 
+ /*@unchecked@*/
+-extern const char *__progname;
++extern char *__progname;
++#endif
+ 
+ /* -- Retrofit missing prototypes (if needed). */
+ #ifdef __cplusplus
+Index: rpm-5.4.15/rpmio/poptIO.c
+===================================================================
+--- rpm-5.4.15.orig/rpmio/poptIO.c
++++ rpm-5.4.15/rpmio/poptIO.c
+@@ -65,7 +65,9 @@ extern int _rpmsvn_debug;
+ GENfree(rpmioP)
+ #endif	/* __cplusplus */
+ 
++#ifdef __GLIBC__
+ const char *__progname;
++#endif
+ 
+ #if !defined(POPT_ARGFLAG_TOGGLE)	/* XXX compat with popt < 1.15 */
+ #define	POPT_ARGFLAG_TOGGLE	0
+Index: rpm-5.4.15/lib/poptALL.c
+===================================================================
+--- rpm-5.4.15.orig/lib/poptALL.c
++++ rpm-5.4.15/lib/poptALL.c
+@@ -4,7 +4,9 @@
+  */
+ 
+ #include "system.h"
++#ifdef __GLIBC__
+ extern const char *__progname;
++#endif
+ 
+ #if defined(RPM_VENDOR_WINDRIVER)
+ const char *__usrlibrpm = USRLIBRPM;
+Index: rpm-5.4.15/tools/rpm2cpio.c
+===================================================================
+--- rpm-5.4.15.orig/tools/rpm2cpio.c
++++ rpm-5.4.15/tools/rpm2cpio.c
+@@ -1,7 +1,9 @@
+ /* rpmarchive: spit out the main archive portion of a package */
+ 
+ #include "system.h"
++#ifdef __GLIBC__
+ const char *__progname;
++#endif
+ 
+ #include <rpmio.h>
+ #include <rpmiotypes.h>	/* XXX fnpyKey */
+Index: rpm-5.4.15/tools/rpmcache.c
+===================================================================
+--- rpm-5.4.15.orig/tools/rpmcache.c
++++ rpm-5.4.15/tools/rpmcache.c
+@@ -3,7 +3,9 @@
+  */
+ 
+ #include "system.h"
++#ifdef __GLIBC__
+ const char *__progname;
++#endif
+ 
+ #include <fnmatch.h>
+ #include <fts.h>
+Index: rpm-5.4.15/tools/rpmdeps-oecore.c
+===================================================================
+--- rpm-5.4.15.orig/tools/rpmdeps-oecore.c
++++ rpm-5.4.15/tools/rpmdeps-oecore.c
+@@ -1,5 +1,7 @@
+ #include "system.h"
++#ifdef __GLIBC__
+ const char *__progname;
++#endif
+ 
+ #include <rpmio.h>
+ #include <rpmiotypes.h>
+Index: rpm-5.4.15/tools/rpmdeps.c
+===================================================================
+--- rpm-5.4.15.orig/tools/rpmdeps.c
++++ rpm-5.4.15/tools/rpmdeps.c
+@@ -1,5 +1,7 @@
+ #include "system.h"
++#ifdef __GLIBC__
+ const char *__progname;
++#endif
+ 
+ #include <rpmio.h>
+ #include <rpmiotypes.h>
+Index: rpm-5.4.15/tools/rpmdigest.c
+===================================================================
+--- rpm-5.4.15.orig/tools/rpmdigest.c
++++ rpm-5.4.15/tools/rpmdigest.c
+@@ -1,6 +1,8 @@
+ #include "system.h"
++#ifdef __GLIBC__
+ /*@unchecked@*/
+ extern const char * __progname;
++#endif
+ 
+ #define	_RPMIOB_INTERNAL
+ #include <rpmiotypes.h>
+Index: rpm-5.4.15/tools/rpmcmp.c
+===================================================================
+--- rpm-5.4.15.orig/tools/rpmcmp.c
++++ rpm-5.4.15/tools/rpmcmp.c
+@@ -13,8 +13,10 @@
+ 
+ #include "debug.h"
+ 
++#ifdef __GLIBC__
+ const char *__progname;
+ #define	progname	__progname
++#endif
+ 
+ static int pointRpmEVR(ARGV_t av)
+ {
+Index: rpm-5.4.15/rpmqv.c
+===================================================================
+--- rpm-5.4.15.orig/rpmqv.c
++++ rpm-5.4.15/rpmqv.c
+@@ -1,5 +1,7 @@
+ #include "system.h"
++#ifdef __GLIBC__
+ extern const char *__progname;
++#endif
+ 
+ /* Copyright (C) 1998-2002 - Red Hat, Inc. */
+ 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-using-poptParseArgvString-to-parse-the-_gpg_check_pa.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-using-poptParseArgvString-to-parse-the-_gpg_check_pa.patch
index 23bc336..7128250 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-using-poptParseArgvString-to-parse-the-_gpg_check_pa.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/0001-using-poptParseArgvString-to-parse-the-_gpg_check_pa.patch
@@ -4,7 +4,7 @@
 Subject: [PATCH] using poptParseArgvString to parse the
  _gpg_check_password_cmd
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Both __gpg_check_password_cmd and __gpg_sign_cmd include "%{_gpg_name}", but
 strace shows that gpg_name has a quote when run _gpg_check_password,
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/debugedit-segv.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/debugedit-segv.patch
index beef5ed..c83c8b5 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/debugedit-segv.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/debugedit-segv.patch
@@ -11,38 +11,40 @@
 Also the process (...) function was modified to verify the data is not
 NULL as well.  This is an extra check and is not strictly necessary.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
-Index: rpm-5.4.14/tools/debugedit.c
+Index: rpm/tools/debugedit.c
 ===================================================================
---- rpm-5.4.14.orig/tools/debugedit.c
-+++ rpm-5.4.14/tools/debugedit.c
-@@ -1445,21 +1445,24 @@ handle_build_id (DSO *dso, Elf_Data *bui
-     auto inline void process (const void *data, size_t size)
-     {
-       memchunk chunk = { .data = (void *) data, .size = size };
--      hashFunctionContextUpdateMC (&ctx, &chunk);
-+      if (data != NULL && size != 0)
-+        hashFunctionContextUpdateMC (&ctx, &chunk);
-     }
-     union
-     {
+--- rpm.orig/tools/debugedit.c
++++ rpm/tools/debugedit.c
+@@ -1403,7 +1403,8 @@ static inline void process (hashFunction
+ 		const void *data, size_t size)
+ {
+     memchunk chunk = { .data = (void *) data, .size = size };
+-    hashFunctionContextUpdateMC (ctx, &chunk);
++    if (data != NULL && size != 0)
++      hashFunctionContextUpdateMC (ctx, &chunk);
+ }
+ 
+ /* Compute a fresh build ID bit-string from the editted file contents.  */
+@@ -1456,14 +1457,16 @@ handle_build_id (DSO *dso, Elf_Data *bui
        GElf_Ehdr ehdr;
        GElf_Phdr phdr;
        GElf_Shdr shdr;
 -    } u;
 -    Elf_Data x = { .d_version = EV_CURRENT, .d_buf = &u };
-+    } u1, u2;
-+    Elf_Data src  = { .d_version = EV_CURRENT, .d_buf = &u1 };
-+    Elf_Data dest = { .d_version = EV_CURRENT, .d_buf = &u2 };
- 
+-
 -    x.d_type = ELF_T_EHDR;
 -    x.d_size = sizeof u.ehdr;
 -    u.ehdr = dso->ehdr;
 -    u.ehdr.e_phoff = u.ehdr.e_shoff = 0;
 -    if (elf64_xlatetom (&x, &x, dso->ehdr.e_ident[EI_DATA]) == NULL)
++    } u1, u2;
++    Elf_Data src  = { .d_version = EV_CURRENT, .d_buf = &u1 };
++    Elf_Data dest = { .d_version = EV_CURRENT, .d_buf = &u2 };
++
 +    src.d_type = ELF_T_EHDR;
 +    src.d_size = sizeof u1.ehdr;
 +    dest.d_size = sizeof u2.ehdr;
@@ -52,7 +54,7 @@
        {
        bad:
  	fprintf (stderr, "Failed to compute header checksum: %s\n",
-@@ -1467,29 +1470,31 @@ handle_build_id (DSO *dso, Elf_Data *bui
+@@ -1471,29 +1474,31 @@ handle_build_id (DSO *dso, Elf_Data *bui
  	exit (1);
        }
  
@@ -69,8 +71,8 @@
 -	if (elf64_xlatetom (&x, &x, dso->ehdr.e_ident[EI_DATA]) == NULL)
 +	if (elf64_xlatetom (&dest, &src, dso->ehdr.e_ident[EI_DATA]) == NULL)
  	  goto bad;
--	process (x.d_buf, x.d_size);
-+	process (dest.d_buf, dest.d_size);
+-	process (&ctx, x.d_buf, x.d_size);
++	process (&ctx, dest.d_buf, dest.d_size);
        }
  
 -    x.d_type = ELF_T_SHDR;
@@ -88,8 +90,8 @@
 +	  u1.shdr.sh_offset = 0;
 +	  if (elf64_xlatetom (&dest, &src, dso->ehdr.e_ident[EI_DATA]) == NULL)
  	    goto bad;
--	  process (x.d_buf, x.d_size);
-+	  process (dest.d_buf, dest.d_size);
+-	  process (&ctx, x.d_buf, x.d_size);
++	  process (&ctx, dest.d_buf, dest.d_size);
  
 -	  if (u.shdr.sh_type != SHT_NOBITS)
 +	  if (u1.shdr.sh_type != SHT_NOBITS)
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/debugedit-valid-file-to-fix-segment-fault.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/debugedit-valid-file-to-fix-segment-fault.patch
index f7c3100..8040482 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/debugedit-valid-file-to-fix-segment-fault.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/debugedit-valid-file-to-fix-segment-fault.patch
@@ -14,7 +14,7 @@
 with ELF_C_RDWR and ELF_F_LAYOUT set to enlarge the above file, it
 could make sure the file is safe for the following elf operations.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
 ---
  tools/debugedit.c | 25 +++++++++++++++++++++++++
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/fstack-protector-configure-check.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/fstack-protector-configure-check.patch
deleted file mode 100644
index 976af48..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/fstack-protector-configure-check.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Some options checked in this loop are needing linking to find out
-if the option can be used or not e.g. -fstack-protector which needs
-libssp to be staged and available for compiler to link against
-Therefore we change the compile only check to compile and link check
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-Upstream-Status: Pending
-
-Index: rpm-5.4.14/configure.ac
-===================================================================
---- rpm-5.4.14.orig/configure.ac
-+++ rpm-5.4.14/configure.ac
-@@ -201,7 +201,7 @@ dnl # GNU GCC (usually "gcc")
-  my_save_cflags="$CFLAGS"
-  CFLAGS=$c
-  AC_MSG_CHECKING([whether GCC supports $c])
-- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([])],
-+ AC_LINK_IFELSE([AC_LANG_PROGRAM([])],
-     [AC_MSG_RESULT([yes])]
-     [my_cflags=$c],
-     [AC_MSG_RESULT([no])]
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/header-include-fix.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/header-include-fix.patch
index 5ffb187..e72df45 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/header-include-fix.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/header-include-fix.patch
@@ -1,4 +1,14 @@
-Upstream-Status: Pending
+Update two rpm headers to include other headers.
+
+Using rpmdb.h w/o including errno.h may result in a warning.
+
+Using rpmtag.h w/o also adding stdint.h will result in numerous failures
+about unknown types on modern compilers.
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Qing He <qing.he@intel.com>
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
 Index: rpm-5.4.14/rpmdb/rpmdb.h
 ===================================================================
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/makefile-am-exec-hook.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/makefile-am-exec-hook.patch
index 8fab9eb..5d936db 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/makefile-am-exec-hook.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/makefile-am-exec-hook.patch
@@ -14,7 +14,7 @@
 install-pkgbinPROGRAMS. This means install-pkgbinPROGRAMS will only be run once
 so there whould be any file contention.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Morgan Little <morgan.little@windriver.com>
 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/popt-disable-auto-stack-protector.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/popt-disable-auto-stack-protector.patch
new file mode 100644
index 0000000..bcad8dc
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/popt-disable-auto-stack-protector.patch
@@ -0,0 +1,27 @@
+popt: Disable default stack protection on internal version of popt
+
+Upstream-Status: Inappropriate [configuration]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/popt/configure.ac
+===================================================================
+--- rpm-5.4.15.orig/popt/configure.ac
++++ rpm-5.4.15/popt/configure.ac
+@@ -123,7 +123,6 @@ AS_IF([test "x$popt_gcc_warnings" = xyes
+   popt_CFLAGS_ADD([-Wjump-misses-init],[POPT_CFLAGS])
+   popt_CFLAGS_ADD([-Wno-format-nonliteral],[POPT_CFLAGS])
+   popt_CFLAGS_ADD([-Wframe-larger-than=$MAX_STACK_SIZE],[POPT_CFLAGS])
+-  popt_CFLAGS_ADD([-fstack-protector-all],[POPT_CFLAGS])
+   popt_CFLAGS_ADD([-fasynchronous-unwind-tables],[POPT_CFLAGS])
+   popt_CFLAGS_ADD([-fdiagnostics-show-option],[POPT_CFLAGS])
+   popt_CFLAGS_ADD([-funit-at-a-time],[POPT_CFLAGS])
+@@ -203,7 +202,7 @@ AC_SUBST([POPT_LDFLAGS])
+ # -fno-delete-null-pointer as the kernel does http://patchwork.kernel.org/patch/36060/
+ # GNU GCC (usually "gcc")
+ AS_IF([test "x$GCC" != x],
+- [ for c in -fno-delete-null-pointer-checks -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector -fexceptions
++ [ for c in -fno-delete-null-pointer-checks -fexceptions
+    do
+   	popt_CFLAGS_ADD([$c], [POPT_CFLAGS])
+    done
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/python-rpm-rpmsense.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/python-rpm-rpmsense.patch
index a538a60..590f58d 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/python-rpm-rpmsense.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/python-rpm-rpmsense.patch
@@ -4,30 +4,28 @@
 want to see the MISSINGOK value so we can avoid recommended packages causing
 failures.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
-Index: rpm-5.4.14/python/rpmmodule.c
+Index: rpm/python/rpmmodule.c
 ===================================================================
---- rpm-5.4.14.orig/python/rpmmodule.c
-+++ rpm-5.4.14/python/rpmmodule.c
-@@ -494,12 +494,16 @@ void init_rpm(void)
-     REGISTER_ENUM(RPMSENSE_EQUAL);
-     REGISTER_ENUM(RPMSENSE_NOTEQUAL);
-     REGISTER_ENUM(RPMSENSE_FIND_REQUIRES);
--#if defined(RPM_VENDOR_MANDRIVA)
-+#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_WINDRIVER) || defined(RPM_VENDOR_OE)
+--- rpm.orig/python/rpmmodule.c
++++ rpm/python/rpmmodule.c
+@@ -525,12 +525,15 @@ static int initModule(PyObject *m)
      REGISTER_ENUM(RPMSENSE_PREREQ);
+     REGISTER_ENUM(RPMSENSE_PRETRANS);
+     REGISTER_ENUM(RPMSENSE_INTERP);
++#else
++ #if defined(RPM_VENDOR_WINDRIVER) || defined(RPM_VENDOR_OE)
      REGISTER_ENUM(RPMSENSE_SCRIPT_PRE);
      REGISTER_ENUM(RPMSENSE_SCRIPT_POST);
      REGISTER_ENUM(RPMSENSE_SCRIPT_PREUN);
--    REGISTER_ENUM(RPMSENSE_SCRIPT_POSTUN)
-+    REGISTER_ENUM(RPMSENSE_SCRIPT_POSTUN);
-+#endif
-+
-+#if defined(RPM_VENDOR_WINDRIVER) || defined(RPM_VENDOR_OE)
+     REGISTER_ENUM(RPMSENSE_SCRIPT_POSTUN);
+     REGISTER_ENUM(RPMSENSE_SCRIPT_VERIFY);
+-#else
 +    REGISTER_ENUM(RPMSENSE_MISSINGOK);
++ #endif
+     REGISTER_ENUM(RPMSENSE_NOTEQUAL);
  #endif
- 
-     REGISTER_ENUM(RPMDEPS_FLAG_NOUPGRADE);
+     REGISTER_ENUM(RPMSENSE_FIND_REQUIRES);
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-CVE-2013-6435.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-CVE-2013-6435.patch
deleted file mode 100644
index b107e8f..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-CVE-2013-6435.patch
+++ /dev/null
@@ -1,109 +0,0 @@
-From 08105acda1da63d32fbb18596a3d6c3e0aa106d1 Mon Sep 17 00:00:00 2001
-From: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com>
-Date: Wed, 10 Jun 2015 14:36:56 +0000
-Subject: [PATCH 2/2] rpm: CVE-2013-6435
-
-Upstream-Status: Backport
-
-Reference:
-https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2013-6435
-
-Description:
-It was found that RPM wrote file contents to the target installation
-directory under a temporary name, and verified its cryptographic signature
-only after the temporary file has been written completely. Under certain
-conditions, the system interprets the unverified temporary file contents
-and extracts commands from it. This could allow an attacker to modify
-signed RPM files in such a way that they would execute code chosen
-by the attacker during package installation.
-
-Original Patch:
-https://bugzilla.redhat.com/attachment.cgi?id=956207
-
-Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com>
----
- lib/fsm.c     |  2 +-
- rpmio/rpmio.c | 18 ++++++++++++++----
- 2 files changed, 15 insertions(+), 5 deletions(-)
-
-diff --git a/lib/fsm.c b/lib/fsm.c
-index 1ee7e67..094eb1d 100644
---- a/lib/fsm.c
-+++ b/lib/fsm.c
-@@ -726,7 +726,7 @@ static int expandRegular(FSM_t fsm, rpmpsm psm, rpmcpio_t archive, int nodigest)
- {
-     FD_t wfd = NULL;
-     const struct stat * st = &fsm->sb;
--    rpm_loff_t left = st->st_size;
-+    rpm_loff_t left = rpmfiFSizeIndex(fsmGetFi(fsm), fsm->ix);
-     const unsigned char * fidigest = NULL;
-     pgpHashAlgo digestalgo = 0;
-     int rc = 0;
-diff --git a/rpmio/rpmio.c b/rpmio/rpmio.c
-index cd223e8..0b12e31 100644
---- a/rpmio/rpmio.c
-+++ b/rpmio/rpmio.c
-@@ -1309,15 +1309,19 @@ int Fclose(FD_t fd)
-  * - bzopen:	[1-9] is block size (modulo 100K)
-  * - bzopen:	's' is smallmode
-  * - HACK:	'.' terminates, rest is type of I/O
-+ * -            'U' sets *mode to zero (no permissions) instead of 0666
-  */
- static void cvtfmode (const char *m,
- 				char *stdio, size_t nstdio,
- 				char *other, size_t nother,
--				const char **end, int * f)
-+				const char **end, int *f, mode_t *mode)
- {
-     int flags = 0;
-     char c;
- 
-+    if (mode)
-+    *mode = 0666;
-+
-     switch (*m) {
-     case 'a':
- 	flags |= O_WRONLY | O_CREAT | O_APPEND;
-@@ -1357,6 +1361,10 @@ static void cvtfmode (const char *m,
- 	    if (--nstdio > 0) *stdio++ = c;
- 	    continue;
- 	    break;
-+	case 'U':
-+	    if (mode)
-+		*mode = 0;
-+	    break;
- 	default:
- 	    if (--nother > 0) *other++ = c;
- 	    continue;
-@@ -1385,7 +1393,8 @@ fprintf(stderr, "*** Fdopen(%p,%s) %s\n", fd, fmode, fdbg(fd));
-     if (fd == NULL || fmode == NULL)
- 	return NULL;
- 
--    cvtfmode(fmode, stdio, sizeof(stdio), other, sizeof(other), &end, NULL);
-+    cvtfmode(fmode, stdio, sizeof(stdio), other, sizeof(other), &end, NULL,
-+        NULL);
-     if (stdio[0] == '\0')
- 	return NULL;
-     zstdio[0] = '\0';
-@@ -1436,7 +1445,7 @@ FD_t Fopen(const char *path, const char *fmode)
- {
-     char stdio[20], other[20];
-     const char *end = NULL;
--    mode_t perms = 0666;
-+    mode_t perms;
-     int flags = 0;
-     FD_t fd;
- 
-@@ -1444,7 +1453,8 @@ FD_t Fopen(const char *path, const char *fmode)
- 	return NULL;
- 
-     stdio[0] = '\0';
--    cvtfmode(fmode, stdio, sizeof(stdio), other, sizeof(other), &end, &flags);
-+    cvtfmode(fmode, stdio, sizeof(stdio), other, sizeof(other), &end, &flags,
-+        &perms);
-     if (stdio[0] == '\0')
- 	return NULL;
- 
--- 
-1.8.4.5
-
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-CVE-2014-8118.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-CVE-2014-8118.patch
deleted file mode 100644
index bf1795c..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-CVE-2014-8118.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 71c812edf1431a9967bd99ba6ffa6ab89eb7ec7c Mon Sep 17 00:00:00 2001
-From: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com>
-Date: Wed, 10 Jun 2015 12:56:55 +0000
-Subject: [PATCH 1/2] rpm: CVE-2014-8118
-
-Upstream-Status: Backport
-
-Reference:
-https://bugzilla.redhat.com/show_bug.cgi?id=1168715
-
-Description:
-It was found that RPM could encounter an integer overflow,
-leading to a stack-based overflow, while parsing a crafted
-CPIO header in the payload section of an RPM file.  This could
-allow an attacker to modify signed RPM files in such a way that
-they would execute code chosen by the attacker during package
-installation.
-
-Original Patch:
-https://bugzilla.redhat.com/attachment.cgi?id=962159
-
-Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com>
----
- lib/cpio.c | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/lib/cpio.c b/lib/cpio.c
-index 382eeb6..74ddd9c 100644
---- a/lib/cpio.c
-+++ b/lib/cpio.c
-@@ -296,6 +296,9 @@ int rpmcpioHeaderRead(rpmcpio_t cpio, char ** path, struct stat * st)
-     st->st_rdev = makedev(major, minor);
- 
-     GET_NUM_FIELD(hdr.namesize, nameSize);
-+    if (nameSize <= 0 || nameSize > 4096) {
-+        return CPIOERR_BAD_HEADER;
-+    }
- 
-     *path = xmalloc(nameSize + 1);
-     read = Fread(*path, nameSize, 1, cpio->fd);
--- 
-1.8.4.5
-
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-atomic-ops.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-atomic-ops.patch
new file mode 100644
index 0000000..cc241f4
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-atomic-ops.patch
@@ -0,0 +1,73 @@
+Some architectures do not have __sync_add_and_fetch_8 implemented.
+
+MIPS (32-bit) and some PPC systems do not have sync_add_and_fetch_8.
+
+Provide an alternative.  This alternative function is based on code from:
+  https://github.com/mongodb/libbson/blob/master/src/bson/bson-atomic.c
+
+Code is under an Apache 2.0 License.
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/rpmio/bson.h
+===================================================================
+--- rpm-5.4.15.orig/rpmio/bson.h
++++ rpm-5.4.15/rpmio/bson.h
+@@ -879,10 +879,18 @@ BSON_END_DECLS
+ 
+ BSON_BEGIN_DECLS
+ 
++/* Some architectures do not support __sync_add_and_fetch_8 */
++#if (__mips == 32) || (defined(__PPC__) && !defined(__GCC_HAVE_SYNC_COMPARE_AND_SWAP_8))
++# define __BSON_NEED_ATOMIC_64 1
++#endif
+ 
+ #if defined(__GNUC__)
+ # define bson_atomic_int_add(p, v)   (__sync_add_and_fetch(p, v))
+-# define bson_atomic_int64_add(p, v) (__sync_add_and_fetch_8(p, v))
++#ifndef __BSON_NEED_ATOMIC_64
++#  define bson_atomic_int64_add(p, v) (__sync_add_and_fetch_8(p, v))
++# else
++   int64_t bson_atomic_int64_add (volatile int64_t *p, int64_t n);
++# endif
+ # define bson_memory_barrier         __sync_synchronize
+ #elif defined(_MSC_VER) || defined(_WIN32)
+ # define bson_atomic_int_add(p, v)   (InterlockedExchangeAdd((long int *)(p), v))
+Index: rpm-5.4.15/rpmio/bson.c
+===================================================================
+--- rpm-5.4.15.orig/rpmio/bson.c
++++ rpm-5.4.15/rpmio/bson.c
+@@ -3863,13 +3863,30 @@ _bson_context_get_oid_seq64_threadsafe (
+ #elif defined BSON_OS_WIN32
+    uint64_t seq = InterlockedIncrement64 ((int64_t *)&context->seq64);
+ #else
+-   uint64_t seq = __sync_fetch_and_add_8 (&context->seq64, 1);
++   uint64_t seq = bson_atomic_int64_add (&context->seq64, 1);
+ #endif
+ 
+    seq = BSON_UINT64_TO_BE (seq);
+    memcpy (&oid->bytes[4], &seq, 8);
+ }
+ 
++#ifdef __BSON_NEED_ATOMIC_64
++#include <pthread.h>
++static pthread_mutex_t gSync64 = PTHREAD_MUTEX_INITIALIZER;
++int64_t
++bson_atomic_int64_add (volatile int64_t *p,
++                       int64_t           n)
++{
++   int64_t ret;
++
++   pthread_mutex_lock (&gSync64);
++   *p += n;
++   ret = *p;
++   pthread_mutex_unlock (&gSync64);
++
++   return ret;
++}
++#endif
+ 
+ /**
+  * bson_context_new:
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-autogen-force.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-autogen-force.patch
new file mode 100644
index 0000000..258a7f6
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-autogen-force.patch
@@ -0,0 +1,78 @@
+In order to enable musl or other libc support, force update the config.guess
+
+In order to reliably replace config.guess and config.sub, we need to remove
+them prior to the call to automake.  Adding the --force-missing is likely
+not necessary, but matching normal OE autoreconf usage.
+
+Upstream-Status: Inappropriate [configuration]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/autogen.sh
+===================================================================
+--- rpm-5.4.15.orig/autogen.sh
++++ rpm-5.4.15/autogen.sh
+@@ -73,7 +73,8 @@ rm -f aclocal.m4
+ aclocal -I m4
+ autoheader -I m4
+ echo "---> generate files via GNU automake (automake)"
+-automake -Wall -Wno-override -a -c
++rm -f config.guess config.sub
++automake -Wall -Wno-override -a -c --force-missing
+ echo "---> generate files via GNU autoconf (autoconf)"
+ autoconf -I m4
+ echo "<=== rpm"
+Index: rpm-5.4.15/beecrypt/autogen.sh
+===================================================================
+--- rpm-5.4.15.orig/beecrypt/autogen.sh
++++ rpm-5.4.15/beecrypt/autogen.sh
+@@ -25,6 +25,7 @@ libtoolize () {
+ 
+ libtoolize --force --copy
+ aclocal
+-automake -a -c
++rm -f config.guess config.sub
++automake -a -c --force-missing
+ autoconf
+ autoheader
+Index: rpm-5.4.15/libtpm/autogen.sh
+===================================================================
+--- rpm-5.4.15.orig/libtpm/autogen.sh
++++ rpm-5.4.15/libtpm/autogen.sh
+@@ -46,7 +46,8 @@ echo "---> generate files via GNU autoco
+ aclocal
+ autoheader
+ echo "---> generate files via GNU automake (automake)"
+-automake -Wall -Wno-override -a -c
++rm -f config.guess config.sub
++automake -Wall -Wno-override -a -c --force-missing
+ echo "---> generate files via GNU autoconf (autoconf)"
+ autoconf
+ 
+Index: rpm-5.4.15/neon/autogen.sh
+===================================================================
+--- rpm-5.4.15.orig/neon/autogen.sh
++++ rpm-5.4.15/neon/autogen.sh
+@@ -63,7 +63,8 @@ echo "---> generate files via GNU autoco
+ ${ACLOCAL:-aclocal} -I macros
+ ${AUTOHEADER:-autoheader}
+ echo "---> generate files via GNU automake (automake)"
+-${AUTOMAKE:-automake} -Wall -Wno-override -a -c
++rm -f config.guess config.sub
++${AUTOMAKE:-automake} -Wall -Wno-override -a -c --force-missing
+ echo "---> generate files via GNU autoconf (autoconf)"
+ ${AUTOCONF:-autoconf} -Wall
+ 
+Index: rpm-5.4.15/syck/autogen.sh
+===================================================================
+--- rpm-5.4.15.orig/syck/autogen.sh
++++ rpm-5.4.15/syck/autogen.sh
+@@ -40,6 +40,7 @@ echo "---> generate files via GNU autoco
+ aclocal
+ autoheader
+ echo "---> generate files via GNU automake (automake)"
+-automake -Wall -Wno-override -a -c
++rm -f config.guess config.sub
++automake -Wall -Wno-override -a -c --force-missing
+ echo "---> generate files via GNU autoconf (autoconf)"
+ autoconf
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-canonarch.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-canonarch.patch
index 41ab498..81fc849 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-canonarch.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-canonarch.patch
@@ -14,7 +14,7 @@
   <arch>-<vendor>-<os>
   <arch>-<vendor>-<os>-<extension>
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-db5-or-db6.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-db5-or-db6.patch
index 77020a3..5d08d27 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-db5-or-db6.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-db5-or-db6.patch
@@ -1,23 +1,29 @@
-Support both db5 and db6.
+From 7bad268de8b32281e2a12ccd88038b3ec5eb1be3 Mon Sep 17 00:00:00 2001
+From: Yuanjie Huang <Yuanjie.Huang@windriver.com>
+Date: Tue, 15 Dec 2015 18:50:21 +0800
+Subject: [PATCH] Support both db5 and db6.
 
 Upstream-Status: Inappropriate [configuration]
 
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+Signed-off-by: Yuanjie Huang <Yuanjie.Huang@windriver.com>
+---
+ configure.ac | 103 ++++++++++++++++++++++++++++++++++++++++++++++-------------
+ 1 file changed, 81 insertions(+), 22 deletions(-)
 
 Index: rpm/configure.ac
 ===================================================================
 --- rpm.orig/configure.ac
 +++ rpm/configure.ac
-@@ -547,8 +547,6 @@ else
+@@ -871,8 +871,6 @@ else
      MYPATH=$PATH
  fi
  
--DBXY=db60
+-DBXY=db61
 -
  AC_PATH_PROG(__BASH, bash, %{_bindir}/bash, $MYPATH)
  AC_PATH_PROG(__BZIP2, bzip2, %{_bindir}/bzip2, $MYPATH)
  AC_PATH_PROG(__CAT, cat, /bin/cat, $MYPATH)
-@@ -560,22 +558,6 @@ AC_PATH_PROG(__CMAKE, cmake, %{_bindir}/
+@@ -884,22 +882,6 @@ AC_PATH_PROG(__CMAKE, cmake, %{_bindir}/
  AC_PATH_PROG(__CPIO, cpio, /bin/cpio, $MYPATH)
  AC_PATH_PROG(__CURL, curl, %{_bindir}/curl, $MYPATH)
  AC_PATH_PROG(__CVS, cvs, %{_bindir}/cvs, $MYPATH)
@@ -40,7 +46,7 @@
  AC_PATH_PROG(__DIFF, diff, /bin/diff, $MYPATH)
  AC_PATH_PROG(__DITTO, ditto, %{_bindir}/ditto, $MYPATH)
  AC_PATH_PROG(__FILE, file, %{_bindir}/file, $MYPATH)
-@@ -1604,13 +1586,18 @@ RPM_CHECK_LIB(
+@@ -2050,13 +2032,46 @@ RPM_CHECK_LIB(
  
  dnl # Berkeley-DB & SQLite
  DBLIBSRCS=""
@@ -48,68 +54,74 @@
 +
  # XXX won't handle --includedir override
 -CPPFLAGS="${CPPFLAGS} -I${prefix}/include/${DBXY}"
+-RPM_CHECK_LIB(
 +CPPFLAGS_save="${CPPFLAGS}"
-+CPPFLAGS="${CPPFLAGS_save} -I${prefix}/include/db-6.0"
++CPPFLAGS="${CPPFLAGS_save}"
 +with_db_save="${with_db}"
- RPM_CHECK_LIB(
++
++AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
++#include <db.h>
++]],
++[[
++#if DB_VERSION_MAJOR < 6
++#error DB_VERSION_MAJOR is below 6
++#endif
++]])],
++[RPM_CHECK_LIB(
      [Berkeley-DB], [db],
-     [db-6.0], [db_create], [db.h],
+     [db-6.1], [db_create], [db.h],
 -    [yes,external], [db3],
 +    [yes,external], [db6],
      [ DBLIBSRCS="$DBLIBSRCS db3.c"
-+      DBXY=db60
++      DBXY=db61
++      AM_CONDITIONAL(WITH_DB, [ true ])
++      AM_CONDITIONAL(WITH_DB_INTERNAL, [ test ".$RPM_CHECK_LIB_LOCATION" = .internal ])
++      if test ".$RPM_CHECK_LIB_LOCATION" = .internal; then
++          AC_DEFINE(HAVE_DB_H, 1, [Have <db.h> header])
++      else
++          WITH_DB_SUBDIR=""
++      fi
++    ],
++    [ AM_CONDITIONAL(WITH_DB, [ false ])
++      AM_CONDITIONAL(WITH_DB_INTERNAL, [ false ])
++    ])],
++[with_db="${with_db_save}"
++ CPPFLAGS="${CPPFLAGS_save}"
++ RPM_CHECK_LIB(
++    [Berkeley-DB], [db],
++    [db-5.3], [db_create], [db.h],
++    [yes,external], [db53],
++    [ DBLIBSRCS="$DBLIBSRCS db3.c"
++      DBXY=db53
        AM_CONDITIONAL(WITH_DB, [ true ])
        AM_CONDITIONAL(WITH_DB_INTERNAL, [ test ".$RPM_CHECK_LIB_LOCATION" = .internal ])
        if test ".$RPM_CHECK_LIB_LOCATION" = .internal; then
-@@ -1619,10 +1606,32 @@ RPM_CHECK_LIB(
-           WITH_DB_SUBDIR=""
-       fi
-     ],
--    [ AM_CONDITIONAL(WITH_DB, [ false ])
--      AM_CONDITIONAL(WITH_DB_INTERNAL, [ false ])
-+    [ # Reset a few variables to fresh
-+      with_db="${with_db_save}"
-+      CPPFLAGS="${CPPFLAGS_save} -I${prefix}/include/db-5.3"
-+      RPM_CHECK_LIB(
-+        [Berkeley-DB], [db],
-+        [db-5.3], [db_create], [db.h],
-+        [yes,external], [db53],
-+        [ DBLIBSRCS="$DBLIBSRCS db3.c"
-+          DBXY=db53
-+          AM_CONDITIONAL(WITH_DB, [ true ])
-+          AM_CONDITIONAL(WITH_DB_INTERNAL, [ test ".$RPM_CHECK_LIB_LOCATION" = .internal ])
-+          if test ".$RPM_CHECK_LIB_LOCATION" = .internal; then
-+              AC_DEFINE(HAVE_DB_H, 1, [Have <db.h> header])
-+          else
-+              WITH_DB_SUBDIR=""
-+          fi
-+        ],
-+        [ AM_CONDITIONAL(WITH_DB, [ false ])
-+          AM_CONDITIONAL(WITH_DB_INTERNAL, [ false ])
-+        ])
+@@ -2068,6 +2083,11 @@ RPM_CHECK_LIB(
+     [ AM_CONDITIONAL(WITH_DB, [ false ])
+       AM_CONDITIONAL(WITH_DB_INTERNAL, [ false ])
      ])
- 
-+if test ".$ac_cv_lib_db_6_0_db_create" != .yes -a ".$ac_cv_lib_db_5_3_db_create" != .yes; then
++])
++
++if test ".$ac_cv_lib_db_6_1_db_create" != .yes -a ".$ac_cv_lib_db_5_3_db_create" != .yes; then
 +    CPPFLAGS="${CPPFLAGS_save}"
 +fi
-+
+ 
  dnl # Sqlite external
  RPM_CHECK_LIB(
-     [SQLite], [sqlite],
-@@ -1633,10 +1642,11 @@ RPM_CHECK_LIB(
+@@ -2078,10 +2098,11 @@ RPM_CHECK_LIB(
+     [])
  
- dnl # Sqlite 3.7.0.1 from db-5.1.19
- dnl XXX error: `db3' is already registered with AC_CONFIG_SUBDIRS.
-+if test ".$ac_cv_lib_db_6_0_db_create" = .yes; then
+ dnl # Sqlite 3.8.3.1 from db-6.1.19
++if test ".$ac_cv_lib_db_6_1_db_create" = .yes; then
  RPM_CHECK_LIB(
      [Berkeley-DB (+SQLite3)], [dbsql],
-     [db_sql-6.0], [sqlite3_open], [dbsql.h],
+     [db_sql-6.1], [sqlite3_open], [dbsql.h],
 -    [yes,external], [db3/sql],
 +    [yes,external], [db6/sql],
      [
        AM_CONDITIONAL(WITH_DBSQL, [ true ])
        AC_DEFINE(WITH_SQLITE, 1, [Define as 1 if building with SQLite library])
-@@ -1650,12 +1660,50 @@ RPM_CHECK_LIB(
+@@ -2095,12 +2116,50 @@ RPM_CHECK_LIB(
      ], [
        AM_CONDITIONAL(WITH_DBSQL, [ false ])
      ])
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-db60.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-db60.patch
new file mode 100644
index 0000000..b4df8b7
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-db60.patch
@@ -0,0 +1,56 @@
+Set the DB 6 version to match oe-core db 6.0.30
+
+Upstream-Status: Inappropriate [configuration]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm/configure.ac
+===================================================================
+--- rpm.orig/configure.ac
++++ rpm/configure.ac
+@@ -2049,10 +2049,10 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+ ]])],
+ [RPM_CHECK_LIB(
+     [Berkeley-DB], [db],
+-    [db-6.1], [db_create], [db.h],
++    [db-6.0], [db_create], [db.h],
+     [yes,external], [db6],
+     [ DBLIBSRCS="$DBLIBSRCS db3.c"
+-      DBXY=db61
++      DBXY=db60
+       AM_CONDITIONAL(WITH_DB, [ true ])
+       AM_CONDITIONAL(WITH_DB_INTERNAL, [ test ".$RPM_CHECK_LIB_LOCATION" = .internal ])
+       if test ".$RPM_CHECK_LIB_LOCATION" = .internal; then
+@@ -2085,7 +2085,7 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+     ])
+ ])
+ 
+-if test ".$ac_cv_lib_db_6_1_db_create" != .yes -a ".$ac_cv_lib_db_5_3_db_create" != .yes; then
++if test ".$ac_cv_lib_db_6_0_db_create" != .yes -a ".$ac_cv_lib_db_5_3_db_create" != .yes; then
+     CPPFLAGS="${CPPFLAGS_save}"
+ fi
+ 
+@@ -2097,11 +2097,11 @@ RPM_CHECK_LIB(
+     [ DBLIBSRCS="$DBLIBSRCS sqlite.c" ],
+     [])
+ 
+-dnl # Sqlite 3.8.3.1 from db-6.1.19
+-if test ".$ac_cv_lib_db_6_1_db_create" = .yes; then
++dnl # Sqlite 3.8.3.1 from db-6.0.30
++if test ".$ac_cv_lib_db_6_0_db_create" = .yes; then
+ RPM_CHECK_LIB(
+     [Berkeley-DB (+SQLite3)], [dbsql],
+-    [db_sql-6.1], [sqlite3_open], [dbsql.h],
++    [db_sql-6.0], [sqlite3_open], [dbsql.h],
+     [yes,external], [db6/sql],
+     [
+       AM_CONDITIONAL(WITH_DBSQL, [ true ])
+@@ -2253,7 +2253,7 @@ AC_SUBST(WITH_RUBY_CPPFLAGS)
+ AC_SUBST(WITH_RUBY_SUBDIR)
+ AC_SUBST(WITH_RUBY_VENDORARCHDIR)
+ 
+-dnl # Java prerequisites (swiped from db-6.1.19/dist/aclocal_java et al)
++dnl # Java prerequisites (swiped from db-6.0.30/dist/aclocal_java et al)
+ WITH_JAVA=no
+ AC_ARG_WITH([java],
+     AS_HELP_STRING([--with-java], [build RPM with java support]),
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-disable-Wno-override-init.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-disable-Wno-override-init.patch
deleted file mode 100644
index 8b5f8d6..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-disable-Wno-override-init.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 70d881873b443c9bad502db9665595455d4f0ac9 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Tue, 8 Jul 2014 07:41:10 +0800
-Subject: [PATCH] configure.ac: disable -Wno-override-init
-
-Fixed rpm-native.do_configure error on CentOS 5.x:
-
-cc1: error: unrecognized command line option "-Wno-override-init"
-
-Upstream-Status: Pending
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index adeffe0..6746b4c 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -163,7 +163,7 @@ AC_ARG_ENABLE(build-warnings,
- # XXX gcc-4.2 on Mac OS X hasn't
- #            CFLAGS="$CFLAGS -Wno-unused-but-set-variable"
- # XXX rpmio/set.c needs this
--            CFLAGS="$CFLAGS -Wno-override-init"
-+#            CFLAGS="$CFLAGS -Wno-override-init"
-         elif test ".`$CC -V 2>&1 | grep 'Sun C'`" != .; then
-             dnl # Sun Studio (usually "cc")
-             CFLAGS="$CFLAGS -v"
---
-1.8.2.1
-
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-disable-auto-stack-protector.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-disable-auto-stack-protector.patch
new file mode 100644
index 0000000..124606c
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-disable-auto-stack-protector.patch
@@ -0,0 +1,24 @@
+Make security switches manual settings
+
+RPM checks for the availability of the stack protector switch and
+transactional-memory support.  If supported it unconditionally
+enables the compiler options which can cause errors if the support has
+not been built into the compiler.
+
+Upstream-Status: Inappropriate [configuration]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/configure.ac
+===================================================================
+--- rpm-5.4.15.orig/configure.ac
++++ rpm-5.4.15/configure.ac
+@@ -425,7 +425,7 @@ dnl #  rpm_CFLAGS_ADD([-fstack-arrays],[
+ dnl # build RPM instrumented for extra optimization/security (GCC only)
+ dnl # --- other optimizations
+   rpm_CFLAGS_ADD([-fexceptions], [RPM_CFLAGS])
+-  rpm_CFLAGS_ADD([-D_FORTIFY_SOURCE=2 -fstack-protector], [RPM_CFLAGS])
++dnl  rpm_CFLAGS_ADD([-D_FORTIFY_SOURCE=2 -fstack-protector], [RPM_CFLAGS])
+ dnl #  rpm_CFLAGS_ADD([-fstack-protector-all],[RPM_CFLAGS])
+ 
+      if test \( ".`$CC --version 2>&1 | grep 'GCC'`" != . \); then
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-disable-blaketest.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-disable-blaketest.patch
new file mode 100644
index 0000000..adbef6d
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-disable-blaketest.patch
@@ -0,0 +1,28 @@
+rpmio: Disable building of the tblake2 test(s).
+
+There is some type of a dependency fault here that can occasionally result in:
+
+gcc: error: tblake2b.o: No such file or directory
+or
+gcc: error: tblake2bp.o: No such file or directory
+
+These items are simply test cases that are not packaged, so they can be
+safely disabled to resolve the dependency issue.
+
+Upstream-Status: Inappropriate [workaround]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/rpmio/Makefile.am
+===================================================================
+--- rpm-5.4.15.orig/rpmio/Makefile.am
++++ rpm-5.4.15/rpmio/Makefile.am
+@@ -29,7 +29,7 @@ EXTRA_PROGRAMS += bsdiff bspatch pcrsed
+ 	tmire todbc toid tperl tpython tput trpmio tsexp tsvn tsw ttcl \
+ 	dumpasn1 lookup3 trel twitter github tmicrojson duk
+ 
+-noinst_PROGRAMS += b2sum tset tblake2b tblake2bp tblake2s tblake2sp tgfs
++#noinst_PROGRAMS += b2sum tset tblake2b tblake2bp tblake2s tblake2sp tgfs
+ if WITH_LIBGIT2
+ noinst_PROGRAMS += tgit
+ else
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-logio-cp.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-logio-cp.patch
index 27a0a8d..290ec1a 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-logio-cp.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-logio-cp.patch
@@ -1,7 +1,7 @@
 Occasionally the cp -p fails with a non-zero return code.  This will cause
 the system abort the build.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-lua-tests-compilation-failure.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-lua-tests-compilation-failure.patch
new file mode 100644
index 0000000..1a08243
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-lua-tests-compilation-failure.patch
@@ -0,0 +1,43 @@
+Upstream-Status: Pending
+
+Subject: lua: fix to build test libs correctly
+
+This patch fixes errors like below.
+
+  | gcc: error: lib21.c: No such file or directory
+  | gcc: fatal error: no input files
+
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ lua/tests/libs/Makefile.am | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/lua/tests/libs/Makefile.am b/lua/tests/libs/Makefile.am
+index 19d1a0b..1e5de72 100644
+--- a/lua/tests/libs/Makefile.am
++++ b/lua/tests/libs/Makefile.am
+@@ -28,16 +28,16 @@ clean:
+ 	rm -f lib1.so lib11.so lib2.so lib21.so lib2-v2.so
+ 
+ lib1.so: lib1.c
+-	$(CC) $(CFLAGS) -o lib1.so lib1.c
++	$(CC) $(CFLAGS) -o lib1.so $(top_srcdir)/lua/tests/libs/lib1.c
+ 
+ lib11.so: lib11.c
+-	$(CC) $(CFLAGS) -o lib11.so lib11.c
++	$(CC) $(CFLAGS) -o lib11.so $(top_srcdir)/lua/tests/libs/lib11.c
+ 
+ lib2.so: lib2.c
+-	$(CC) $(CFLAGS) -o lib2.so lib2.c
++	$(CC) $(CFLAGS) -o lib2.so $(top_srcdir)/lua/tests/libs/lib2.c
+ 
+ lib21.so: lib21.c
+-	$(CC) $(CFLAGS) -o lib21.so lib21.c
++	$(CC) $(CFLAGS) -o lib21.so $(top_srcdir)/lua/tests/libs/lib21.c
+ 
+ lib2-v2.so: lib2.so
+ 	mv lib2.so ./lib2-v2.so
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-parseEmbedded.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-parseEmbedded.patch
new file mode 100644
index 0000000..c57f24c
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-fix-parseEmbedded.patch
@@ -0,0 +1,27 @@
+Fix an issue where parseEmbedded is not defined, but is still used.
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm/rpmio/macro.c
+===================================================================
+--- rpm.orig/rpmio/macro.c
++++ rpm/rpmio/macro.c
+@@ -1616,8 +1616,6 @@ exit:
+  * @retval *avp		invocation args
+  * @return		script string
+  */
+-#if defined(WITH_AUGEAS) || defined(WITH_FICL) || defined(WITH_MOZJS) || defined(WITH_JNIEMBED) || defined(WITH_PERLEMBED) || defined(WITH_PYTHONEMBED) || defined(WITH_RUBYEMBED) || defined(WITH_MRUBY_EMBED) || defined(WITH_SQLITE) || defined(WITH_SQUIRREL) || defined(WITH_TCL)
+-
+ static char _FIXME_embedded_interpreter_eval_returned_null[] =
+     "FIXME: embedded interpreter eval returned null.";
+ 
+@@ -1668,7 +1666,6 @@ bingo:
+     script[nb] = '\0';
+     return script;
+ }
+-#endif
+ 
+ /**
+  * The main macro recursion loop.
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-gnu-atomic.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-gnu-atomic.patch
new file mode 100644
index 0000000..36a418f
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-gnu-atomic.patch
@@ -0,0 +1,64 @@
+configure.ac: Check if the current compiler supports the transactions
+
+Some distributions appear to have compilers that are built without support
+for transactions, even though they are GCC 4.7 or newer.
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/configure.ac
+===================================================================
+--- rpm-5.4.15.orig/configure.ac
++++ rpm-5.4.15/configure.ac
+@@ -425,9 +425,34 @@ dnl # --- other optimizations
+   rpm_CFLAGS_ADD([-D_FORTIFY_SOURCE=2 -fstack-protector], [RPM_CFLAGS])
+ dnl #  rpm_CFLAGS_ADD([-fstack-protector-all],[RPM_CFLAGS])
+ 
+-     if test \( ".`$CC --version 2>&1 | grep 'GCC'`" != . \); then
+-         rpm_CFLAGS_ADD([-fgnu-tm], [RPM_CFLAGS])
+-     fi
++dnl # Check if the current gcc supports -fgnu-tm and __transaction_atomic
++AC_MSG_CHECKING([If the compiler supports __transaction_atomic])
++save_CFLAGS="$CFLAGS"
++save_LDFLAGS="$LDFLAGS"
++CFLAGS="${CFLAGS} -fgnu-tm -litm"
++LDFLAGS="${LDFLAGS} -litm"
++AC_LINK_IFELSE([AC_LANG_SOURCE([[
++int
++main()
++{
++#if !__clang__ &&  ((__GNUC__ == 4 && __GNUC_MINOR__ >= 7) || (__GNUC__ > 4)) /* XXX gud enuf? */
++        int i = 0;
++        __transaction_atomic { i++; }
++#else
++# error Compiler does not support __transaction_atomic
++#endif
++        return 0;
++}
++]])], [
++        AC_DEFINE([HAVE_GNUC_TM_ATOMIC], [1],
++                [Define to 1 if the compiler supports __transaction_atomic.])
++        AC_MSG_RESULT([yes])
++], [
++	CFLAGS="$save_CFLAGS"
++	LDFLAGS="$save_LDFLAGS"
++	AC_MSG_RESULT([no])
++])
++
+ 
+ dnl # --- options below are added to RPM_CFLAGS but _NOT_ added to CFLAGS
+             CPPFLAGS="$CPPFLAGS $RPM_CPPFLAGS"
+Index: rpm-5.4.15/rpmio/rpmutil.h
+===================================================================
+--- rpm-5.4.15.orig/rpmio/rpmutil.h
++++ rpm-5.4.15/rpmio/rpmutil.h
+@@ -105,7 +105,7 @@
+ #  define RPM_GNUC_INTERNAL
+ #endif
+ 
+-#if !__clang__ &&  __GNUC__ == 4 && __GNUC_MINOR__ >= 7	/* XXX gud enuf? */
++#ifdef HAVE_GNUC_TM_ATOMIC
+ #  define RPM_GNUC_TM_SAFE	__attribute__((transaction_safe))
+ #  define RPM_GNUC_TM_PURE	__attribute__((transaction_pure))
+ #  define RPM_GNUC_TM_CALLABLE	__attribute__((transaction_callable))
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-hardlink-segfault-fix.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-hardlink-segfault-fix.patch
index 5deb232..057925f 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-hardlink-segfault-fix.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-hardlink-segfault-fix.patch
@@ -8,7 +8,7 @@
 
 RP 2014/6/10
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Index: rpm-5.4.14/lib/fsm.c
 ===================================================================
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-keccak-sse-intrin.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-keccak-sse-intrin.patch
new file mode 100644
index 0000000..72884d4
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-keccak-sse-intrin.patch
@@ -0,0 +1,27 @@
+rpm - rpmio/keccak.c: make SSE/MMX dependent upon gcc config
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/rpmio/keccak.c
+===================================================================
+--- rpm-5.4.15.orig/rpmio/keccak.c
++++ rpm-5.4.15/rpmio/keccak.c
+@@ -17,9 +17,13 @@ http://keccak.noekeon.org/
+ #if OPTIMIZED == 64
+ /* ===== "KeccakOpt64-settings.h" */
+ #define Unrolling 18
+-//#define UseBebigokimisa
+-#define UseSSE
+-//#define UseMMX
++#if defined(__SSE2__)
++ #define UseSSE
++#elif defined(__MMX__)
++ #define UseMMX
++#else
++ #define UseBebigokimisa
++#endif
+ /* ===== */
+ #endif
+ 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lib-transaction.c-fix-file-conflicts-for-mips64-N32.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lib-transaction.c-fix-file-conflicts-for-mips64-N32.patch
new file mode 100644
index 0000000..1a48db6
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lib-transaction.c-fix-file-conflicts-for-mips64-N32.patch
@@ -0,0 +1,52 @@
+From 67ec7531e6297200eaa97ef917d49b0a75876cb4 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Wed, 2 Dec 2015 00:56:07 -0800
+Subject: [PATCH] lib/transaction.c: fix file conflicts for MIPS64 N32
+
+The following error can occur:
+  smart install libc6-2.22-r0.1@lib32_mips32r2octeon3 libc6-dbg-2.22-r0.1@lib32_mips32r2octeon3
+error: file /sbin/ldconfig conflicts between attempted installs of libc6-2.22-r0.1.lib32_mips32r2octeon3 and libc6-2.22-r0.1.octeon3_n32
+error: file /sbin/.debug/ldconfig conflicts between attempted installs of libc6-dbg-2.22-r0.1.lib32_mips32r2octeon3 and libc6-dbg-2.22-r0.1.octeon3_n32
+
+This was because:
+transactions_color = 001 (ELF32) & 010 (ELF64) & 100 (ELF32 N32 MIPS64)
+FColor = Current file color (001) & transaction_color (111)
+oFcolor = Previous file color (100) & transaction_color (111)
+
+There are two places where the conflict comparisons occur.  In both places
+the 'else' clause was too restrictive (opposite of the 'positive' clause).
+This caused the system to only permit a binary comparison - "new preferred" or
+"old preferred".  It did not permissing "neither preferred".  By removing the
+else comparison the system will now perform a 'last-in-wins' resolution when
+"neither is preferred".
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+---
+ lib/transaction.c |    3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+Index: rpm-5.4.14/lib/transaction.c
+===================================================================
+--- rpm-5.4.14.orig/lib/transaction.c
++++ rpm-5.4.14/lib/transaction.c
+@@ -154,7 +154,7 @@ static int handleInstInstalledFile(const
+ 		fi->actions[fx] = FA_SKIPCOLOR;
+ #endif
+ 		rConflicts = 0;
+-	    } else if (FColor & prefcolor) {
++	    } else {
+ #ifdef	REFERENCE
+ 		rpmfsSetAction(fs, fx, FA_CREATE);
+ #else
+@@ -420,7 +420,7 @@ assert(otherFi != NULL);
+ 			fi->actions[i] = FA_SKIPCOLOR;
+ 			rConflicts = 0;
+ 		    } else
+-		    if (FColor == 0 && oFColor == 0) {
++		    {
+ 			/* ... otherwise, do both, last in wins. */
+ 			otherFi->actions[otherFileNum] = FA_CREATE;
+ 			fi->actions[i] = FA_CREATE;
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-libsql-fix.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-libsql-fix.patch
index 042e412..e87e02b 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-libsql-fix.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-libsql-fix.patch
@@ -2,7 +2,7 @@
 The problem is that it hasn't been installed yet!  So small change causes
 the libtool to instead use the build version.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lsb-compatibility.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lsb-compatibility.patch
index 790a662..a87518b 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lsb-compatibility.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lsb-compatibility.patch
@@ -5,7 +5,7 @@
 we also want to generate a perceived platform based on the valid rpm contents
 of arch and os.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lua-fix-print.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lua-fix-print.patch
deleted file mode 100644
index 7ab49e9..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-lua-fix-print.patch
+++ /dev/null
@@ -1,104 +0,0 @@
-Lua 'print' statement is not working properly inside of RPM 5
-
-The print statement should capture the output and send it to the script
-processing engine, and not display it directly to the screen.
-
-This patch is from: http://rpm5.org/cvs/patchset?cn=17671
-
-Upstream-Status: backport (patchset 17671 from rpm5.org)
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
-Index: rpm-5.4.14/CHANGES
-===================================================================
---- rpm-5.4.14.orig/CHANGES
-+++ rpm-5.4.14/CHANGES
-@@ -1,3 +1,4 @@
-+    - jbj: lua: fix: resurrect output capture with lua-5.2.
-     - jbj: verify: fix: broken logic for %ghost avoidance (Mark Hatle).
- 
- 5.4.13 -> 5.4.14:
-Index: rpm-5.4.14/rpmio/rpmlua.c
-===================================================================
---- rpm-5.4.14.orig/rpmio/rpmlua.c
-+++ rpm-5.4.14/rpmio/rpmlua.c
-@@ -175,7 +175,7 @@ rpmlua rpmluaNew(void)
-     };
-     /*@=readonlytrans =nullassign @*/
-     /*@observer@*/ /*@unchecked@*/
--    const luaL_Reg *lib = lualibs;
-+    const luaL_Reg *lib;
-     char *path_buf;
-     char *path_next;
-     char *path;
-@@ -190,31 +190,34 @@ rpmlua rpmluaNew(void)
- 
-     luaL_openlibs(L);
- 
--    for (; lib->name; lib++) {
-+    for (lib = lualibs; lib->name; lib++) {
- 	luaL_requiref(L, lib->name, lib->func, 1);
-+	lua_pop(L, 1);
-     }
- 
-     {	const char * _lua_path = rpmGetPath(rpmluaPath, NULL);
-  	if (_lua_path != NULL) {
-+#if defined(LUA_GLOBALSINDEX)
- 	    lua_pushliteral(L, "LUA_PATH");
- 	    lua_pushstring(L, _lua_path);
-+	    lua_rawset(L, LUA_GLOBALSINDEX);
-+#else
-+	    lua_pushstring(L, _lua_path);
-+	    lua_setglobal(L, "LUA_PATH");
-+#endif
- 	    _lua_path = _free(_lua_path);
- 	}
-     }
- 
- #if defined(LUA_GLOBALSINDEX)
--    lua_rawset(L, LUA_GLOBALSINDEX);
--#else
--    lua_pushglobaltable(L);
--#endif
-     lua_pushliteral(L, "print");
-     lua_pushcfunction(L, rpm_print);
--
--#if defined(LUA_GLOBALSINDEX)
-     lua_rawset(L, LUA_GLOBALSINDEX);
- #else
--    lua_pushglobaltable(L);
-+    lua_pushcfunction(L, rpm_print);
-+    lua_setglobal(L, "print");
- #endif
-+
-     rpmluaSetData(lua, "lua", lua);
- 
-     /* load all standard RPM Lua script files */
-@@ -351,6 +354,9 @@ void rpmluaSetVar(rpmlua _lua, rpmluav v
- #if defined(LUA_GLOBALSINDEX)
- 	if (lua->pushsize == 0)
- 	    lua_pushvalue(L, LUA_GLOBALSINDEX);
-+#else
-+	if (lua->pushsize == 0)
-+	    lua_pushglobaltable(L);
- #endif
- 	if (pushvar(L, var->keyType, &var->key) != -1) {
- 	    if (pushvar(L, var->valueType, &var->value) != -1)
-@@ -1039,14 +1045,15 @@ static int rpm_print (lua_State *L)
-     lua_getglobal(L, "tostring");
-     for (i = 1; i <= n; i++) {
- 	const char *s;
-+	size_t l;
- 	lua_pushvalue(L, -1);  /* function to be called */
- 	lua_pushvalue(L, i);   /* value to print */
- 	lua_call(L, 1, 1);
--	s = lua_tostring(L, -1);  /* get result */
-+	s = lua_tolstring(L, -1, &l);  /* get result */
- 	if (s == NULL)
- 	    return luaL_error(L, "`tostring' must return a string to `print'");
- 	if (lua->storeprint) {
--	    size_t sl = lua_rawlen(L, -1);
-+	    size_t sl = l;
- 	    if ((size_t)(lua->printbufused+sl+1) > lua->printbufsize) {
- 		lua->printbufsize += sl+512;
- 		lua->printbuf = (char *) xrealloc(lua->printbuf, lua->printbufsize);
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-macros.in-disable-external-key-server.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-macros.in-disable-external-key-server.patch
index 07a0cfa..a08412a 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-macros.in-disable-external-key-server.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-macros.in-disable-external-key-server.patch
@@ -12,16 +12,20 @@
 
 Signed-off-by: yzhu1 <yanjun.zhu@windriver.com>
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
---- a/macros/macros.in
-+++ b/macros/macros.in
-@@ -546,8 +546,8 @@ $_arbitrary_tags_tests	Foo:Bar
+Index: rpm/macros/macros.in
+===================================================================
+--- rpm.orig/macros/macros.in
++++ rpm/macros/macros.in
+@@ -563,10 +563,10 @@ $_arbitrary_tags_tests	Foo:Bar
+ 
  # Horowitz Key Protocol server configuration
  #
+-%_hkp_keyserver         hkp://keys.rpm5.org
++#%_hkp_keyserver         hkp://keys.rpm5.org
  #%_hkp_keyserver         hkp://keys.n3npq.net
--%_hkp_keyserver         hkp://pool.sks-keyservers.net
+ #%_hkp_keyserver         hkp://pool.sks-keyservers.net
 -%_hkp_keyserver_query   %{_hkp_keyserver}/pks/lookup?op=get&search=
-+#%_hkp_keyserver         hkp://pool.sks-keyservers.net
 +#%_hkp_keyserver_query   %{_hkp_keyserver}/pks/lookup?op=get&search=
  
  
- %_nssdb_path	/etc/pki/nssdb
+ # NSS_InitContext() parameter configuration
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-mongodb-sasl.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-mongodb-sasl.patch
new file mode 100644
index 0000000..6c3e471
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-mongodb-sasl.patch
@@ -0,0 +1,69 @@
+Fix errors when building with sasl2 disabled
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm/rpmio/mongoc.c
+===================================================================
+--- rpm.orig/rpmio/mongoc.c
++++ rpm/rpmio/mongoc.c
+@@ -39,8 +39,10 @@
+ # include <winerror.h>
+ #endif
+ 
++#ifdef HAVE_LIBSASL2
+ #include <sasl/sasl.h>
+ #include <sasl/saslutil.h>
++#endif
+ 
+ #include <openssl/bio.h>
+ #include <openssl/ssl.h>
+@@ -14228,6 +14230,7 @@ mongoc_read_prefs_copy (const mongoc_rea
+    return ret;
+ }
+ 
++#ifdef MONGOC_ENABLE_SASL
+ /*==============================================================*/
+ /* --- mongoc-sasl.c */
+ 
+@@ -14555,6 +14558,7 @@ _mongoc_sasl_step (mongoc_sasl_t *sasl,
+ 
+    return true;
+ }
++#endif
+ 
+ /*==============================================================*/
+ /* --- mongoc-socket.c */
+Index: rpm/rpmio/mongoc.h
+===================================================================
+--- rpm.orig/rpmio/mongoc.h
++++ rpm/rpmio/mongoc.h
+@@ -38,8 +38,10 @@
+ # include <sys/un.h>
+ #endif
+ 
++#ifdef HAVE_LIBSASL2
+ #include <sasl/sasl.h>
+ #include <sasl/saslutil.h>
++#endif
+ 
+ #include <openssl/bio.h>
+ #include <openssl/ssl.h>
+@@ -2455,6 +2457,8 @@ BSON_END_DECLS
+ /*==============================================================*/
+ /* --- mongoc-sasl-private.h */
+ 
++#ifdef MONGOC_ENABLE_SASL
++
+ BSON_BEGIN_DECLS
+ 
+ 
+@@ -2498,6 +2502,7 @@ bool _mongoc_sasl_step             (mong
+ 
+ 
+ BSON_END_DECLS
++#endif
+ 
+ /*==============================================================*/
+ /* --- mongoc-ssl-private.h */
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-no-loopmsg.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-no-loopmsg.patch
index ab6ed2c..e58cc13 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-no-loopmsg.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-no-loopmsg.patch
@@ -1,6 +1,6 @@
 lib/order.c: Make the dependency loop messages into debug msgs
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-opendb-before-verifyscript-to-avoid-null-point.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-opendb-before-verifyscript-to-avoid-null-point.patch
index 07d586a..e219124 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-opendb-before-verifyscript-to-avoid-null-point.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-opendb-before-verifyscript-to-avoid-null-point.patch
@@ -6,7 +6,7 @@
 fault because of null point(rpmtsGetRdb(ts) == NULL and rpmtsGetRdb(ts)->db_txn).
 So we open rpmdb to avoid bad input when find headerIsEntry true.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
 Index: rpm-5.4.14/lib/verify.c
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-packageorigin.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-packageorigin.patch
index c15e124..57fc6ce 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-packageorigin.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-packageorigin.patch
@@ -2,7 +2,7 @@
 
 Written by jbj at rpm5.org
 
-Upstream-Status: Inappropriate [not author]
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-payload-use-hashed-inode.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-payload-use-hashed-inode.patch
index 9cd02a0..af643b1 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-payload-use-hashed-inode.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-payload-use-hashed-inode.patch
@@ -17,7 +17,7 @@
 
 RP 2014/6/10
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Index: rpm-5.4.14/build/files.c
 ===================================================================
@@ -124,23 +124,3 @@
      }
  
      ui32 = fl->totalFileSize;
-Index: rpm-5.4.14/lib/fsm.c
-===================================================================
---- rpm-5.4.14.orig/lib/fsm.c
-+++ rpm-5.4.14/lib/fsm.c
-@@ -904,6 +904,7 @@ int fsmMapAttrs(IOSM_t fsm)
- 
-     if (fi && i >= 0 && i < (int) fi->fc) {
- 	mode_t perms = (S_ISDIR(st->st_mode) ? fi->dperms : fi->fperms);
-+	ino_t finalInode = (fi->finodes ? (ino_t)fi->finodes[i] : 0);
- 	mode_t finalMode = (fi->fmodes ? (mode_t)fi->fmodes[i] : perms);
- 	dev_t finalRdev = (dev_t)(fi->frdevs ? fi->frdevs[i] : 0);
- 	rpmuint32_t finalMtime = (fi->fmtimes ? fi->fmtimes[i] : 0);
-@@ -943,6 +944,7 @@ int fsmMapAttrs(IOSM_t fsm)
- 	    if ((S_ISCHR(st->st_mode) || S_ISBLK(st->st_mode))
- 	    && st->st_nlink == 0)
- 		st->st_nlink = 1;
-+	    st->st_ino = finalInode;
- 	    st->st_rdev = finalRdev;
- 	    st->st_mtime = finalMtime;
- 	}
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-pkgconfigdeps.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-pkgconfigdeps.patch
index 5d182ad..656de86 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-pkgconfigdeps.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-pkgconfigdeps.patch
@@ -9,14 +9,14 @@
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
-Index: rpm-5.4.14/scripts/pkgconfigdeps.sh
+Index: rpm/scripts/pkgconfigdeps.sh
 ===================================================================
---- rpm-5.4.14.orig/scripts/pkgconfigdeps.sh
-+++ rpm-5.4.14/scripts/pkgconfigdeps.sh
+--- rpm.orig/scripts/pkgconfigdeps.sh
++++ rpm/scripts/pkgconfigdeps.sh
 @@ -18,8 +18,8 @@ case $1 in
      *.pc)
  	# Query the dependencies of the package.
- 	DIR=`dirname ${filename}`
+ 	DIR=$(dirname ${filename})
 -	PKG_CONFIG_PATH="$DIR:$DIR/../../share/pkgconfig"
 -	export PKG_CONFIG_PATH
 +	PKG_CONFIG_LIBDIR="$DIR:$DIR/../../share/pkgconfig"
@@ -27,7 +27,7 @@
 @@ -42,8 +42,8 @@ case $1 in
  	[ -n "$oneshot" ] && echo "$oneshot"; oneshot=""
  	# Query the dependencies of the package.
- 	DIR=`dirname ${filename}`
+ 	DIR=$(dirname ${filename})
 -	PKG_CONFIG_PATH="$DIR:$DIR/../../share/pkgconfig"
 -	export PKG_CONFIG_PATH
 +	PKG_CONFIG_LIBDIR="$DIR:$DIR/../../share/pkgconfig"
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform-file-fix.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform-file-fix.patch
index f26a6e7..200964f 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform-file-fix.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform-file-fix.patch
@@ -2,7 +2,7 @@
 to match when computing an arch score, use it just for getting
 information about the platform (cpu/vendor/os). Fixes #3864.
 
-Upstream-Status: Inappropriate [embedded specific]
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Index: rpm-5.4.14/lib/rpmrc.c
 ===================================================================
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform.patch
index 11fd039..3b40fea 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform.patch
@@ -1,6 +1,6 @@
 Fix up platform and related sysinfo file loading.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 This ensures that RPM knows the compatible set of package types at all times.
 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform2.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform2.patch
index fed54e5..b9675c7 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform2.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-platform2.patch
@@ -1,7 +1,5 @@
 Fix up platform and related sysinfo file loading (part 2).
 
-Upstream-Status: Pending
-
 We need to ensure that we set the _gnu flag somehow.  We do this by reading
 from the platform file, and setting a new _platform_gnu and related vars.
 
@@ -11,6 +9,8 @@
 versions have not been defined.  This preserves existing behavior, but
 ensures reasonable defaults are always available.
 
+Upstream-Status: Submitted [RPM5 maintainer]
+
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
 Index: rpm-5.4.14/lib/rpmrc.c
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-py-init.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-py-init.patch
index 07d407d..92ef1dc 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-py-init.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-py-init.patch
@@ -11,15 +11,17 @@
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
-Index: rpm-5.4.14/python/rpmmodule.c
+Index: rpm/python/rpmmodule.c
 ===================================================================
---- rpm-5.4.14.orig/python/rpmmodule.c
-+++ rpm-5.4.14/python/rpmmodule.c
-@@ -392,7 +392,8 @@ void init_rpm(void)
-     if (Py_AtExit(rpm_exithook) == -1)
- 	return;
+--- rpm.orig/python/rpmmodule.c
++++ rpm/python/rpmmodule.c
+@@ -382,9 +382,8 @@ static int initModule(PyObject *m)
+     /* XXX add --noparentdirs --nolinktos to rpmtsCheck() */
+     global_depFlags = (RPMDEPS_FLAG_NOPARENTDIRS | RPMDEPS_FLAG_NOLINKTOS);
  
--    rpmReadConfigFiles(NULL, NULL);
+-    /* failure to initialize rpm (crypto and all) is rather fatal too... */
+-    if (rpmReadConfigFiles(NULL, NULL) == -1)
+-	return 0;
 +    const char *argv[1] = {"rpmmodule", 0};
 +    rpmcliInit(1, argv, NULL);
  
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-python-AddErase.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-python-AddErase.patch
new file mode 100644
index 0000000..df6f472
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-python-AddErase.patch
@@ -0,0 +1,35 @@
+rpm/python: The RPM5 API requires a hdrNum to be passed in
+
+The former behavior of passing in -1 as the hdrNum resulting in erase
+operations that did not complete, but also did not error.  Changing to
+using the header instance resolves this problem.
+
+Upstream-Status: Pending
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/python/rpmts-py.c
+===================================================================
+--- rpm-5.4.15.orig/python/rpmts-py.c
++++ rpm-5.4.15/python/rpmts-py.c
+@@ -241,12 +241,19 @@ static PyObject *
+ rpmts_AddErase(rpmtsObject * s, PyObject * args)
+ {
+     Header h;
++    uint32_t hdrNum;
+ 
+     if (!PyArg_ParseTuple(args, "O&:AddErase", hdrFromPyObject, &h))
+         return NULL;
+ 
+-SPEW((stderr, "*** %s(%p,%p) ts %p\n", __FUNCTION__, s, h, s->ts));
++    hdrNum = headerGetInstance(h);
++
++SPEW((stderr, "*** %s(%p,%p) ts %p hdrNum %ld\n", __FUNCTION__, s, h, s->ts, hdrNum));
++#ifdef REFERENCE /* this doesn't work, RPM5 requires a unique hdrNum */
+     return PyBool_FromLong(rpmtsAddEraseElement(s->ts, h, -1) == 0);
++#else
++    return PyBool_FromLong(rpmtsAddEraseElement(s->ts, h, hdrNum) == 0);
++#endif
+ }
+ 
+ static int
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-python-restore-origin.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-python-restore-origin.patch
new file mode 100644
index 0000000..7a473db
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-python-restore-origin.patch
@@ -0,0 +1,49 @@
+Fix an issue where the PACKAGEORIGIN is not properly stored.
+
+Restore the rpmtsCallback fdSetOpen call and related code.
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm/python/rpmts-py.c
+===================================================================
+--- rpm.orig/python/rpmts-py.c
++++ rpm/python/rpmts-py.c
+@@ -672,6 +672,8 @@ rpmtsCallback(const void * hd, const rpm
+     Header h = (Header) hd;
+     struct rpmtsCallbackType_s * cbInfo = data;
+     PyObject * pkgObj = (PyObject *) pkgKey;
++    PyObject * oh = NULL;
++    const char * origin = NULL;
+     PyObject * args, * result;
+     static FD_t fd;
+ 
+@@ -693,8 +695,16 @@ rpmtsCallback(const void * hd, const rpm
+ 	    pkgObj = Py_None;
+ 	    Py_INCREF(pkgObj);
+ 	}
+-    } else
++    } else {
+ 	Py_INCREF(pkgObj);
++	/* XXX yum has (h, rpmloc) tuple as pkgKey. Extract the path. */
++	if (!(PyTuple_Check(pkgObj) && PyArg_ParseTuple(pkgObj, "|Os", &oh, &origin)))
++	    origin = NULL;
++	/* XXX clean up the path, yum paths start "//..." */
++	if (origin && origin[0] == '/' && origin[1] == '/')
++	    origin++;
++    }
++
+ 
+     PyEval_RestoreThread(cbInfo->_save);
+ 
+@@ -723,6 +733,9 @@ SPEW((stderr, "\t%p = fdDup(%d)\n", fd,
+ 
+ 	fcntl(Fileno(fd), F_SETFD, FD_CLOEXEC);
+ 
++	if (origin != NULL)
++	    (void) fdSetOpen(fd, origin, 0, 0);
++
+ 	return fd;
+     } else
+     if (what == RPMCALLBACK_INST_CLOSE_FILE) {
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-python-tagname.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-python-tagname.patch
new file mode 100644
index 0000000..dfb5513
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-python-tagname.patch
@@ -0,0 +1,24 @@
+rpm-python-module: Change the extension tag from PyCObject to PyInt
+
+Use the tagValue to determine the custom PyInt value to use for the extension
+tag.  Without this, any custom tag extensions will be returned in a format
+that the tagNumFromPyObject and related functions like hdr_subscript will
+failed to process.  Usually the failure is error: expected a string or integer
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/python/rpmmodule.c
+===================================================================
+--- rpm-5.4.15.orig/python/rpmmodule.c
++++ rpm-5.4.15/python/rpmmodule.c
+@@ -316,7 +316,7 @@ static void addRpmTags(PyObject *module)
+     {
+ 	if (ext->name == NULL || ext->type != HEADER_EXT_TAG)
+ 	    continue;
+-	PyDict_SetItemString(d, (char *) ext->name, to=PyCObject_FromVoidPtr((void *)ext, NULL));
++	PyDict_SetItemString(d, (char *) ext->name, to=PyInt_FromLong(tagValue(ext->name)));
+ 	Py_XDECREF(to);
+         PyDict_SetItem(dict, to, o=PyString_FromString(ext->name + 7));
+ 	Py_XDECREF(o);
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-remove-sykcparse-decl.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-remove-sykcparse-decl.patch
deleted file mode 100644
index 769016b..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-remove-sykcparse-decl.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Index: rpm-5.4.14/syck/lib/syck.h
-===================================================================
---- rpm-5.4.14.orig/syck/lib/syck.h
-+++ rpm-5.4.14/syck/lib/syck.h
-@@ -621,9 +621,6 @@ long syck_seq_count( SyckNode *seq )
-  */
- void syckerror( char *msg )
- 	/*@*/;
--int syckparse( void * )
--	/*@globals fileSystem @*/
--	/*@modifies fileSystem @*/;
- /* XXX union YYSTYPE *sycklval has issues on Mac OS X. */
- int sycklex( void *_sycklval, SyckParser *parser )
- 	/*@modifies _sycklval, parser @*/;
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-resolvedep.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-resolvedep.patch
index 56a243d..526106d 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-resolvedep.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-resolvedep.patch
@@ -3,7 +3,7 @@
 When looking up a missing dependencies, such as /bin/sh, we need to lookup
 in both the providename and filepaths DB, not just the filepaths DB.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmdb-grammar.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmdb-grammar.patch
new file mode 100644
index 0000000..71dae49
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmdb-grammar.patch
@@ -0,0 +1,124 @@
+Disable various items that do not cross compile well.
+
+Upstream-Status: Inappropriate [Configuration]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm/rpmdb/Makefile.am
+===================================================================
+--- rpm.orig/rpmdb/Makefile.am
++++ rpm/rpmdb/Makefile.am
+@@ -34,10 +34,10 @@ EXTRA_DIST = \
+ 	db3.c sqlite.c db_emu.h librpmdb.vers bdb.sql libsqldb.c \
+ 	logio.awk logio.src logio_recover_template logio_template logio.c \
+ 	logio_rec.c logio_auto.c logio_autop.c logio_auto.h \
+-	qf.l qf.y qf.inp tqf.l tqf.y tqf.inp grammar.y scanner.l json1.js
++	tqf.l tqf.y tqf.inp grammar.y scanner.l json1.js
+ 
+-EXTRA_PROGRAMS = qfcalc qfgraph logio tjfn tqf # tbdb
+-noinst_PROGRAMS = json
++EXTRA_PROGRAMS = qfcalc qfgraph logio # tjfn tqf tbdb
++noinst_PROGRAMS = # json
+ 
+ RPMMISC_LDADD_COMMON = \
+ 	$(top_builddir)/misc/librpmmisc.la \
+@@ -321,54 +321,39 @@ BUILT_SOURCES += .syntastic_c_config
+ .syntastic_c_config: Makefile
+ 	@echo $(COMPILE) | tr ' ' '\n' | sed -e '1d' > $@
+ 
+-tjfn_SOURCES = tjfn.c
+-tjfn_LDADD = $(mylibs)
+-
+-LEX =	flex
+-LFLAGS=	-d -T -v -8 -b --yylineno --reentrant --bison-bridge --perf-report
+-YACC =	bison
+-YFLAGS=	-Dapi.pure -t -d -v --report=all
+-
+-BUILT_SOURCES += Jgrammar.c Jgrammar.h Jscanner.c
+-Jgrammar.c: grammar.y
+-	$(YACC) $(YFLAGS) -o $@ $<
+-Jscanner.c: scanner.l
+-	$(LEX) -R -o $@ $<
+-json_SOURCES = Jgrammar.c Jscanner.c json.c
+-
+-testjson: json1.js json
+-	./json json1.js
+-
+-BUILT_SOURCES += Qgrammar.c Qgrammar.h Qscanner.c
+-Qgrammar.c: qf.y
+-	$(YACC) $(YFLAGS) -o $@ $<
+-Qscanner.c: qf.l
+-	$(LEX) -R -o $@ $<
+-qfcalc_SOURCES = Qgrammar.c Qscanner.c interpreter.c
+-qfgraph_SOURCES = Qgrammar.c Qscanner.c graph.c
+-
+-testqf: qfcalc qfgraph
+-	./qfcalc < qf.inp
+-	./qfgraph < qf.inp
+-
+-BUILT_SOURCES += Tgrammar.c Tgrammar.h Tscanner.c
+-Tgrammar.c Tgrammar.h: tqf.y
+-	$(YACC) $(YFLAGS) -o $@ $<
+-Tscanner.c Tscanner.h: tqf.l
+-	$(LEX) --prefix="Tyy" $(LFLAGS) -o $@ $<
+-tqf_SOURCES =	Tgrammar.c Tscanner.c tgraph.c
+-tqf_CFLAGS =	$(CFLAGS) -fsanitize=address # -DTSCANNER_MAIN
+-tqf_LDADD =	../lib/librpm.la \
+-		./librpmdb.la \
+-		../popt/libpopt.la
+-
+-testdir =	$(abs_top_builddir)/tests
+-foo: tqf
+-	-../libtool --mode=execute \
+-	    ./tqf \
+-		--dbpath=$(testdir) \
+-		-r $(testdir)/fodder/*.rpm \
+-		   $(testdir)/fodder/fmtmod.qf
++#tjfn_SOURCES = tjfn.c
++#tjfn_LDADD = $(mylibs)
++#
++#LFLAGS=	-d -T -v -8 -b --yylineno --reentrant --bison-bridge --perf-report
++#
++#BUILT_SOURCES += Jgrammar.c Jgrammar.h Jscanner.c
++#Jgrammar.c Jgrammar.h: grammar.y
++#	$(YACC) $(YFLAGS) -t -d -v -o $@ $<
++#Jscanner.c: scanner.l
++#	$(LEX) -R -o $@ $<
++#json_SOURCES = Jgrammar.c Jscanner.c json.c
++#
++#testjson: json1.js json
++#	./json json1.js
++#
++#BUILT_SOURCES += Tgrammar.c Tgrammar.h Tscanner.c
++#Tgrammar.c Tgrammar.h: tqf.y
++#	$(YACC) $(YFLAGS) -t -d -v -o $@ $<
++#Tscanner.c Tscanner.h: tqf.l
++#	$(LEX) --prefix="Tyy" $(LFLAGS) -o $@ $<
++#tqf_SOURCES =	Tgrammar.c Tscanner.c tgraph.c
++#tqf_CFLAGS =	$(CFLAGS) -fsanitize=address # -DTSCANNER_MAIN
++#tqf_LDADD =	../lib/librpm.la \
++#		./librpmdb.la \
++#		../popt/libpopt.la
++
++#testdir =	$(abs_top_builddir)/tests
++#foo: tqf
++#	-../libtool --mode=execute \
++#	    ./tqf \
++#		--dbpath=$(testdir) \
++#		-r $(testdir)/fodder/*.rpm \
++#		   $(testdir)/fodder/fmtmod.qf
+ 
+ #tbdb_SOURCES = tbdb.c bdb.c
+ #tbdb_LDADD = $(mylibs)
+Index: rpm/configure.ac
+===================================================================
+--- rpm.orig/configure.ac
++++ rpm/configure.ac
+@@ -119,6 +119,7 @@ AC_PROG_MAKE_SET
+ AC_PROG_LIBTOOL
+ AC_PROG_RANLIB
+ AC_PROG_YACC
++AM_PROG_LEX
+ 
+ AC_PATH_PROG(AS, as, as)
+ 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmfc.c-fix-for-N32-MIPS64.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmfc.c-fix-for-N32-MIPS64.patch
new file mode 100644
index 0000000..b9a2cbc
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmfc.c-fix-for-N32-MIPS64.patch
@@ -0,0 +1,34 @@
+From 16dc683aa50be9789d1674734b06a8a955ff22ad Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Thu, 26 Nov 2015 01:36:40 -0800
+Subject: [PATCH] lib/rpmfc.c: fix for N32 MIPS64
+
+It is 'N32 MIPS64', not 'N32 MIPS32' as command file shows:
+$ file image/usr/bin/getent
+getent: ELF 32-bit MSB executable, MIPS, N32 MIPS64 [snip]
+
+And "rpm -qp --filecolor" was wrong (it was 1, but should be 4).
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ lib/rpmfc.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/lib/rpmfc.c b/lib/rpmfc.c
+index fde00c7..49779f8 100644
+--- a/lib/rpmfc.c
++++ b/lib/rpmfc.c
+@@ -575,7 +575,7 @@ static struct rpmfcTokens_s rpmfcTokens[] = {
+   { " not stripped",		RPMFC_NOTSTRIPPED },
+   { " archive",			RPMFC_ARCHIVE },
+ 
+-  { "MIPS, N32 MIPS32",		RPMFC_ELFMIPSN32|RPMFC_INCLUDE },
++  { "MIPS, N32 MIPS64",		RPMFC_ELFMIPSN32|RPMFC_INCLUDE },
+   { "ELF 32-bit",		RPMFC_ELF32|RPMFC_INCLUDE },
+   { "ELF 64-bit",		RPMFC_ELF64|RPMFC_INCLUDE },
+ 
+-- 
+1.7.9.5
+
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmio-headers.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmio-headers.patch
new file mode 100644
index 0000000..9364576
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmio-headers.patch
@@ -0,0 +1,19 @@
+Fix a typo in the rpmio Makefile.am
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm/rpmio/Makefile.am
+===================================================================
+--- rpm.orig/rpmio/Makefile.am
++++ rpm/rpmio/Makefile.am
+@@ -121,7 +121,7 @@ luaLPATHdir =	${pkgsharedir)/lua
+ 
+ pkgincdir = $(pkgincludedir)$(WITH_PATH_VERSIONED_SUFFIX)
+ pkginc_HEADERS = argv.h mire.h rpmzlog.h yarn.h \
+-	rpmbf.h rpmcb.h rpmio.h rpmlog.h rpmiotypes.h rpmmacro.h
++	rpmbf.h rpmcb.h rpmio.h rpmlog.h rpmiotypes.h rpmmacro.h \
+ 	rpmpgp.h rpmsw.h rpmutil.h
+ noinst_HEADERS = \
+ 	ar.h bcon.h bson.h cpio.h crc.h envvar.h fnmatch.h fts.h glob.h iosm.h \
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmpgp-fix.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmpgp-fix.patch
deleted file mode 100644
index d8feed7..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmpgp-fix.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-rpmpgp.c: Add missing if defs around crypto implementations
-
-Without these, the system will error trying to find the correct crypto 
-library to use.
-
-Upstream-Status: Pending
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-
-Index: rpm/rpmio/rpmpgp.c
-===================================================================
---- rpm.orig/rpmio/rpmpgp.c
-+++ rpm/rpmio/rpmpgp.c
-@@ -1339,16 +1339,26 @@ int pgpExportPubkey(pgpDig dig)
- {
-     int rc = 0;		/* assume failure */
- 
-+#if defined(WITH_BEECRYPT)
-     if (pgpImplVecs == &rpmbcImplVecs)
- 	rc = rpmbcExportPubkey(dig);
-+#endif
-+#if defined(WITH_SSL)
-     if (pgpImplVecs == &rpmsslImplVecs)
- 	rc = rpmsslExportPubkey(dig);
-+#endif
-+#if defined(WITH_NSS)
-     if (pgpImplVecs == &rpmnssImplVecs)
- 	rc = rpmnssExportPubkey(dig);
-+#endif
-+#if defined(WITH_GCRYPT)
-     if (pgpImplVecs == &rpmgcImplVecs)
- 	rc = rpmgcExportPubkey(dig);
-+#endif
-+#if defined(WITH_TOMCRYPT)
-     if (pgpImplVecs == &rpmltcImplVecs)
- 	rc = rpmltcExportPubkey(dig);
-+#endif
-     return rc;
- }
- 
-@@ -1356,16 +1366,26 @@ int pgpExportSignature(pgpDig dig, DIGES
- {
-     int rc = 0;		/* assume failure */
- 
-+#if defined(WITH_BEECRYPT)
-     if (pgpImplVecs == &rpmbcImplVecs)
- 	rc = rpmbcExportSignature(dig, ctx);
-+#endif
-+#if defined(WITH_SSL)
-     if (pgpImplVecs == &rpmsslImplVecs)
- 	rc = rpmsslExportSignature(dig, ctx);
-+#endif
-+#if defined(WITH_NSS)
-     if (pgpImplVecs == &rpmnssImplVecs)
- 	rc = rpmnssExportSignature(dig, ctx);
-+#endif
-+#if defined(WITH_GCRYPT)
-     if (pgpImplVecs == &rpmgcImplVecs)
- 	rc = rpmgcExportSignature(dig, ctx);
-+#endif
-+#if defined(WITH_TOMCRYPT)
-     if (pgpImplVecs == &rpmltcImplVecs)
- 	rc = rpmltcExportSignature(dig, ctx);
-+#endif
-     return rc;
- }
- 
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmpgp-popt.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmpgp-popt.patch
new file mode 100644
index 0000000..915d7ef
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-rpmpgp-popt.patch
@@ -0,0 +1,26 @@
+rpmpgp.h: We do not require the popt header in order to use rpmpgp functions
+
+This can cause failures if the internal libpopt is used, as it's header is
+not exported.
+
+Upstream-Status: Pending
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.14/rpmio/rpmpgp.h
+===================================================================
+--- rpm-5.4.14.orig/rpmio/rpmpgp.h
++++ rpm-5.4.14/rpmio/rpmpgp.h
+@@ -11,11 +11,11 @@
+  */
+ 
+ #include <string.h>
+-#include <popt.h>
+ #include <rpmiotypes.h>
+ #include <yarn.h>
+ 
+ #if defined(_RPMPGP_INTERNAL)
++#include <popt.h>
+ #include <rpmsw.h>
+ 
+ /*@unchecked@*/
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-scriptletexechelper.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-scriptletexechelper.patch
index f825372..b55fe22 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-scriptletexechelper.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-scriptletexechelper.patch
@@ -12,22 +12,21 @@
 
 Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
 
-Index: rpm-5.4.14/lib/psm.c
+Index: rpm/lib/psm.c
 ===================================================================
---- rpm-5.4.14.orig/lib/psm.c
-+++ rpm-5.4.14/lib/psm.c
-@@ -806,6 +806,10 @@ static rpmRC runScript(rpmpsm psm, Heade
+--- rpm.orig/lib/psm.c
++++ rpm/lib/psm.c
+@@ -846,6 +846,9 @@ static rpmRC runScript(rpmpsm psm, Heade
+     pid_t pid;
      int xx;
      int i;
- 
 +#ifdef RPM_VENDOR_OE
 +    const char * scriptletWrapper = rpmExpand("%{?_cross_scriptlet_wrapper}", NULL);
 +#endif
-+    
-     if (psm->sstates != NULL && ix >= 0 && ix < RPMSCRIPT_MAX)
- 	ssp = psm->sstates + ix;
-     if (ssp != NULL)
-@@ -872,14 +876,29 @@ assert(he->p.str != NULL);
+ 
+ #ifdef	__clang__
+ #pragma clang diagnostic push
+@@ -923,14 +926,29 @@ assert(he->p.str != NULL);
  		(F_ISSET(psm, UNORDERED) ? "a" : ""));
  
      if (Phe->p.argv == NULL) {
@@ -63,7 +62,7 @@
  	ldconfig_done = (ldconfig_path && !strcmp(argv[0], ldconfig_path)
  		? 1 : 0);
      }
-@@ -930,7 +949,12 @@ assert(he->p.str != NULL);
+@@ -981,7 +999,12 @@ assert(he->p.str != NULL);
  	    goto exit;
  
  	if (rpmIsDebug() &&
@@ -77,7 +76,7 @@
  	{
  	    static const char set_x[] = "set -x\n";
  	    nw = Fwrite(set_x, sizeof(set_x[0]), sizeof(set_x)-1, fd);
-@@ -1065,12 +1089,22 @@ assert(he->p.str != NULL);
+@@ -1116,12 +1139,22 @@ assert(he->p.str != NULL);
  
  	{   const char * rootDir = rpmtsRootDir(ts);
  	    if (!rpmtsChrootDone(ts) && rootDir != NULL &&
@@ -100,7 +99,7 @@
  	    xx = Chdir("/");
  	    rpmlog(RPMLOG_DEBUG, D_("%s: %s(%s)\texecv(%s) pid %d\n"),
  			psm->stepName, sln, NVRA,
-@@ -2985,6 +3019,13 @@ assert(psm->te != NULL);
+@@ -3052,6 +3085,13 @@ assert(psm->te != NULL);
      case PSM_SCRIPT:	/* Run current package scriptlets. */
  	/* XXX running %verifyscript/%sanitycheck doesn't have psm->te */
      {	rpmtxn _parent = (psm && psm->te ? psm->te->txn : NULL);
@@ -114,7 +113,7 @@
  	xx = rpmtxnBegin(rpmtsGetRdb(ts), _parent, NULL);
  	rc = runInstScript(psm);
  	if (rc)
-@@ -2992,11 +3033,24 @@ assert(psm->te != NULL);
+@@ -3059,11 +3099,24 @@ assert(psm->te != NULL);
  	else
  	     xx = rpmtxnCommit(rpmtsGetRdb(ts)->db_txn);
  	rpmtsGetRdb(ts)->db_txn = NULL;
@@ -139,7 +138,7 @@
  	break;
      case PSM_IMMED_TRIGGERS:
  	/* Run triggers in this package other package(s) set off. */
-@@ -3006,7 +3060,18 @@ assert(psm->te != NULL);
+@@ -3073,7 +3126,18 @@ assert(psm->te != NULL);
  	    F_SET(psm, GOTTRIGGERS);
  	}
  	if (psm->triggers != NULL)
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-syck-fix-gram.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-syck-fix-gram.patch
new file mode 100644
index 0000000..d6493c1
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-syck-fix-gram.patch
@@ -0,0 +1,1081 @@
+Fix the syck/lib/gram.y
+
+This resolves a problem during compilation:
+
+../../../rpm/syck/lib/gram.y:66:27: error: 'parser' undeclared (first use in this function)
+            ((SyckParser *)parser)->root = syck_hdlr_add_node( (SyckParser *)parser, $1 );
+                           ^
+../../../rpm/syck/lib/gram.y:66:27: note: each undeclared identifier is reported only once for each function it appears in
+../../../rpm/syck/lib/syck.c: In function 'syck_parse':
+../../../rpm/syck/lib/syck.c:516:5: warning: implicit declaration of function 'syckparse' [-Wimplicit-function-declaration]
+     syckparse( p );
+     ^
+
+This patch was generated by reverting the grammer back to a previous
+version.
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm/syck/lib/gram.y
+===================================================================
+--- rpm.orig/syck/lib/gram.y
++++ rpm/syck/lib/gram.y
+@@ -9,18 +9,10 @@
+ 
+ %start doc
+ %pure-parser
+-%parse-param {void* parser}
+-%lex-param {void* parser}
+ 
+ 
+ %{
+ 
+-#define YYDEBUG 1
+-#define YYERROR_VERBOSE 1
+-#ifndef YYSTACK_USE_ALLOCA
+-#define YYSTACK_USE_ALLOCA 0
+-#endif
+-
+ #include "system.h"
+ #include "syck.h"
+ #include "debug.h"
+@@ -28,6 +20,9 @@
+ void apply_seq_in_map( SyckParser *parser, SyckNode *n )
+ 	/*@*/;
+ 
++#define YYPARSE_PARAM   parser
++#define YYLEX_PARAM     parser
++
+ #define NULL_NODE(parser, node) \
+         SyckNode *node = syck_new_str( "", scalar_plain ); \
+         if ( ((SyckParser *)parser)->taguri_expansion == 1 ) \
+Index: rpm/syck/lib/Makefile.am
+===================================================================
+--- rpm.orig/syck/lib/Makefile.am
++++ rpm/syck/lib/Makefile.am
+@@ -49,25 +49,25 @@ SYCK_SPLINT_SRCS = \
+ 	token.c \
+ 	implicit.c
+ 
+-#gram.c:	gram.y
+-#	$(YACC) -d -t -v -p syck -o $@ $<
+-#	-@if test -f gram.c; then \
+-#	{ echo "/*@-globs -mods -modnomods -moduncon -modunconnomods @*/";\
+-#	  echo "/*@-noeffect -noeffectuncon @*/";\
+-#	  echo "/*@-nullassign @*/";\
+-#	  echo "/*@-readonlytrans @*/";\
+-#	  echo "/*@-uniondef @*/";\
+-#	  echo "/*@-warnlintcomments @*/";\
+-#	  cat gram.c;\
+-#	  echo "/*@=warnlintcomments @*/";\
+-#	  echo "/*@=uniondef @*/";\
+-#	  echo "/*@=readonlytrans @*/";\
+-#	  echo "/*@=nullassign @*/";\
+-#	  echo "/*@=noeffect =noeffectuncon @*/";\
+-#	  echo "/*@=globs =mods =modnomods =moduncon =modunconnomods @*/";\
+-#	} > _gram.c ;\
+-#	  mv -f _gram.c gram.c; \
+-#	fi
++gram.c:	gram.y
++	$(YACC) -d -t -v -p syck -o $@ $<
++	-@if test -f gram.c; then \
++	{ echo "/*@-globs -mods -modnomods -moduncon -modunconnomods @*/";\
++	  echo "/*@-noeffect -noeffectuncon @*/";\
++	  echo "/*@-nullassign @*/";\
++	  echo "/*@-readonlytrans @*/";\
++	  echo "/*@-uniondef @*/";\
++	  echo "/*@-warnlintcomments @*/";\
++	  cat gram.c;\
++	  echo "/*@=warnlintcomments @*/";\
++	  echo "/*@=uniondef @*/";\
++	  echo "/*@=readonlytrans @*/";\
++	  echo "/*@=nullassign @*/";\
++	  echo "/*@=noeffect =noeffectuncon @*/";\
++	  echo "/*@=globs =mods =modnomods =moduncon =modunconnomods @*/";\
++	} > _gram.c ;\
++	  mv -f _gram.c gram.c; \
++	fi
+ 
+ BUILT_SOURCES = gram.c gram.h
+ 
+Index: rpm/syck/lib/implicit.c
+===================================================================
+--- rpm.orig/syck/lib/implicit.c
++++ rpm/syck/lib/implicit.c
+@@ -19,11 +19,6 @@
+ #define YYLIMIT     limit
+ #define YYFILL(n)
+ 
+-#ifdef  __clang__
+-#pragma clang diagnostic push
+-#pragma clang diagnostic ignored "-Wempty-body"
+-#endif
+-
+ void
+ try_tag_implicit( SyckNode *n, int taguri )
+ {
+@@ -3000,8 +2995,4 @@ yy270:	++YYCURSOR;
+ 
+ }
+ 
+-#ifdef  __clang__
+-#pragma clang diagnostic pop
+-#endif
+-
+ /*@=noret@*/
+Index: rpm/syck/lib/syck.c
+===================================================================
+--- rpm.orig/syck/lib/syck.c
++++ rpm/syck/lib/syck.c
+@@ -519,7 +519,7 @@ syck_parse( SyckParser *p )
+ }
+ 
+ void
+-syck_default_error_handler( SyckParser *p, const char *msg )
++syck_default_error_handler( SyckParser *p, char *msg )
+ {
+     printf( "Error at [Line %d, Col %ld]: %s\n", 
+         p->linect,
+Index: rpm/syck/lib/syck.h
+===================================================================
+--- rpm.orig/syck/lib/syck.h
++++ rpm/syck/lib/syck.h
+@@ -175,7 +175,7 @@ typedef struct _syck_str SyckIoStr;
+ typedef struct _syck_level SyckLevel;
+ 
+ typedef SYMID (*SyckNodeHandler)(SyckParser *p, SyckNode *n);
+-typedef void (*SyckErrorHandler)(SyckParser *p, const char *);
++typedef void (*SyckErrorHandler)(SyckParser *p, char *);
+ typedef SyckNode * (*SyckBadAnchorHandler)(SyckParser *p, char *);
+ typedef long (*SyckIoFileRead)(char *, SyckIoFile *, long, long); 
+ typedef long (*SyckIoStrRead)(char *, SyckIoStr *, long, long);
+@@ -546,7 +546,7 @@ long syck_parser_readlen( SyckParser *p,
+ SYMID syck_parse( SyckParser *p )
+ 	/*@globals fileSystem @*/
+ 	/*@modifies p, fileSystem @*/;
+-void syck_default_error_handler( SyckParser *p, const char * )
++void syck_default_error_handler( SyckParser *p, char * )
+ 	/*@globals fileSystem @*/
+ 	/*@modifies p, fileSystem @*/;
+ SYMID syck_yaml2byte_handler( SyckParser *p, SyckNode *n )
+@@ -619,7 +619,7 @@ long syck_seq_count( SyckNode *seq )
+ /*
+  * Lexer prototypes
+  */
+-void syckerror( void *, const char *msg )
++void syckerror( char *msg )
+ 	/*@*/;
+ /* XXX union YYSTYPE *sycklval has issues on Mac OS X. */
+ int sycklex( void *_sycklval, SyckParser *parser )
+Index: rpm/syck/lib/token.c
+===================================================================
+--- rpm.orig/syck/lib/token.c
++++ rpm/syck/lib/token.c
+@@ -270,11 +270,11 @@ sycklex( void * _sycklval, SyckParser *p
+         return sycklex_yaml_utf8( sycklval, parser );
+ 
+         case syck_yaml_utf16:
+-            syckerror( parser, "UTF-16 is not currently supported in Syck.\nPlease contribute code to help this happen!" );
++            syckerror( "UTF-16 is not currently supported in Syck.\nPlease contribute code to help this happen!" );
+         break;
+ 
+         case syck_yaml_utf32:
+-            syckerror( parser, "UTF-32 is not currently supported in Syck.\nPlease contribute code to help this happen!" );
++            syckerror( "UTF-32 is not currently supported in Syck.\nPlease contribute code to help this happen!" );
+         break;
+ 
+         case syck_bytecode_utf8:
+@@ -2739,15 +2739,14 @@ syckwrap(void)
+ }
+ 
+ void 
+-syckerror( void *p, const char *msg )
++syckerror( char *msg )
+ {
+-    SyckParser * parser = (SyckParser *)p;
+ /*@-mods@*/
+-    if ( parser->error_handler == NULL )
+-        parser->error_handler = syck_default_error_handler;
++    if ( syck_parser_ptr->error_handler == NULL )
++        syck_parser_ptr->error_handler = syck_default_error_handler;
+ 
+-    parser->root = parser->root_on_error;
++    syck_parser_ptr->root = syck_parser_ptr->root_on_error;
+ /*@=mods@*/
+-    (parser->error_handler)(parser, msg);
++    (syck_parser_ptr->error_handler)(syck_parser_ptr, msg);
+ }
+ 
+Index: rpm/syck/lib/bytecode.c
+===================================================================
+--- rpm.orig/syck/lib/bytecode.c
++++ rpm/syck/lib/bytecode.c
+@@ -1,10 +1,10 @@
+-/* Generated by re2c 0.9.12 on Tue Mar 14 00:14:53 2006 */
++/* Generated by re2c 0.13.5 on Tue Feb 23 12:04:00 2016 */
+ #line 1 "bytecode.re"
+ /*
+  * bytecode.re
+  *
+  * $Author: why $
+- * $Date: 2005-09-20 08:21:06 +0300 (Tue, 20 Sep 2005) $
++ * $Date: 2005/09/20 05:21:06 $
+  *
+  * Copyright (C) 2003 why the lucky stiff
+  */
+@@ -27,14 +27,11 @@
+ #define YYLINEPTR   parser->lineptr
+ #define YYLINECTPTR parser->linectptr
+ #define YYLINE      parser->linect
+-#define YYFILL(n)   (void) syck_parser_read(parser)
++#define YYFILL(n)   syck_parser_read(parser)
+ 
+-/*@unchecked@*/ /*@null@*/
+ extern SyckParser *syck_parser_ptr;
+ 
+-/*@null@*/
+-char *get_inline( SyckParser *parser )
+-	/*@modifies parser @*/;
++char *get_inline( SyckParser *parser );
+ 
+ /*
+  * Repositions the cursor at `n' offset from the token start.
+@@ -137,14 +134,12 @@ char *get_inline( SyckParser *parser )
+  */
+ int
+ sycklex_bytecode_utf8( YYSTYPE *sycklval, SyckParser *parser )
+-	/*@globals syck_parser_ptr @*/
+-	/*@modifies sycklval, parser, syck_parser_ptr @*/
+ {
+     SyckLevel *lvl;
+     syck_parser_ptr = parser;
+     if ( YYCURSOR == NULL ) 
+     {
+-        (void) syck_parser_read( parser );
++        syck_parser_read( parser );
+     }
+ 
+     if ( parser->force_token != 0 )
+@@ -171,42 +166,37 @@ sycklex_bytecode_utf8( YYSTYPE *sycklval
+ #line 165 "<stdout>"
+ {
+ 	YYCTYPE yych;
+-	unsigned int yyaccept = 0;
+-	goto yy0;
+-	/*@notreached@*/
+-	++YYCURSOR;
+-yy0:
+-	if((YYLIMIT - YYCURSOR) < 3) YYFILL(3);
++
++	if ((YYLIMIT - YYCURSOR) < 3) YYFILL(3);
+ 	yych = *YYCURSOR;
+-	switch(yych){
++	switch (yych) {
+ 	case 0x00:	goto yy2;
+ 	case 'D':	goto yy3;
+ 	default:	goto yy5;
+ 	}
+-yy2:	YYCURSOR = YYMARKER;
+-	switch(yyaccept){
+-	case 0:	goto yy4;
+-	}
+-yy3:	yyaccept = 0;
++yy2:
++	YYCURSOR = YYMARKER;
++	goto yy4;
++yy3:
+ 	yych = *(YYMARKER = ++YYCURSOR);
+-	switch(yych){
+-	case 0x0A:	goto yy6;
+-	case 0x0D:	goto yy8;
++	switch (yych) {
++	case '\n':	goto yy6;
++	case '\r':	goto yy8;
+ 	default:	goto yy4;
+ 	}
+ yy4:
+ #line 199 "bytecode.re"
+-{   YYPOS(0);
++	{   YYPOS(0);
+             goto Document;
+         }
+-#line 195 "<stdout>"
+-yy5:	yych = *++YYCURSOR;
++#line 191 "<stdout>"
++yy5:
++	yych = *++YYCURSOR;
+ 	goto yy4;
+-yy6:	++YYCURSOR;
+-	goto yy7;
+-yy7:
++yy6:
++	++YYCURSOR;
+ #line 186 "bytecode.re"
+-{   if ( lvl->status == syck_lvl_header )
++	{   if ( lvl->status == syck_lvl_header )
+             {
+                 CHK_NL(YYCURSOR);
+                 goto Directive;
+@@ -218,10 +208,11 @@ yy7:
+                 return 0;
+             }
+         }
+-#line 214 "<stdout>"
+-yy8:	++YYCURSOR;
+-	switch((yych = *YYCURSOR)) {
+-	case 0x0A:	goto yy6;
++#line 210 "<stdout>"
++yy8:
++	++YYCURSOR;
++	switch ((yych = *YYCURSOR)) {
++	case '\n':	goto yy6;
+ 	default:	goto yy2;
+ 	}
+ }
+@@ -239,19 +230,15 @@ Document:
+         YYTOKEN = YYCURSOR;
+ 
+ 
+-#line 235 "<stdout>"
++#line 232 "<stdout>"
+ {
+ 	YYCTYPE yych;
+-	goto yy9;
+-	/*@notreached@*/
+-	++YYCURSOR;
+-yy9:
+-	if((YYLIMIT - YYCURSOR) < 3) YYFILL(3);
++	if ((YYLIMIT - YYCURSOR) < 3) YYFILL(3);
+ 	yych = *YYCURSOR;
+-	switch(yych){
++	switch (yych) {
+ 	case 0x00:	goto yy30;
+-	case 0x0A:	goto yy27;
+-	case 0x0D:	goto yy29;
++	case '\n':	goto yy27;
++	case '\r':	goto yy29;
+ 	case 'A':	goto yy19;
+ 	case 'D':	goto yy12;
+ 	case 'E':	goto yy16;
+@@ -264,71 +251,73 @@ yy9:
+ 	case 'c':	goto yy25;
+ 	default:	goto yy11;
+ 	}
+-yy11:yy12:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy41;
+-	case 0x0D:	goto yy44;
++yy11:
++yy12:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy41;
++	case '\r':	goto yy44;
+ 	default:	goto yy11;
+ 	}
+-yy13:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy41;
+-	case 0x0D:	goto yy43;
++yy13:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy41;
++	case '\r':	goto yy43;
+ 	default:	goto yy11;
+ 	}
+-yy14:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy38;
+-	case 0x0D:	goto yy40;
++yy14:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy38;
++	case '\r':	goto yy40;
+ 	default:	goto yy11;
+ 	}
+-yy15:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy35;
+-	case 0x0D:	goto yy37;
++yy15:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy35;
++	case '\r':	goto yy37;
+ 	default:	goto yy11;
+ 	}
+-yy16:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy32;
+-	case 0x0D:	goto yy34;
++yy16:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy32;
++	case '\r':	goto yy34;
+ 	default:	goto yy11;
+ 	}
+-yy17:	++YYCURSOR;
+-	goto yy18;
+-yy18:
++yy17:
++	++YYCURSOR;
+ #line 288 "bytecode.re"
+-{   ADD_BYTE_LEVEL(lvl, lvl->spaces + 1, syck_lvl_str); 
++	{   ADD_BYTE_LEVEL(lvl, lvl->spaces + 1, syck_lvl_str); 
+             goto Scalar;
+         }
+-#line 296 "<stdout>"
+-yy19:	++YYCURSOR;
+-	goto yy20;
+-yy20:
++#line 295 "<stdout>"
++yy19:
++	++YYCURSOR;
+ #line 292 "bytecode.re"
+-{   ADD_BYTE_LEVEL(lvl, lvl->spaces + 1, syck_lvl_open);
++	{   ADD_BYTE_LEVEL(lvl, lvl->spaces + 1, syck_lvl_open);
+             sycklval->name = get_inline( parser );
+             syck_hdlr_remove_anchor( parser, sycklval->name );
+             CHK_NL(YYCURSOR);
+             return YAML_ANCHOR;
+         }
+-#line 307 "<stdout>"
+-yy21:	++YYCURSOR;
+-	goto yy22;
+-yy22:
++#line 305 "<stdout>"
++yy21:
++	++YYCURSOR;
+ #line 299 "bytecode.re"
+-{   ADD_BYTE_LEVEL(lvl, lvl->spaces + 1, syck_lvl_str);
++	{   ADD_BYTE_LEVEL(lvl, lvl->spaces + 1, syck_lvl_str);
+             sycklval->name = get_inline( parser );
+             POP_LEVEL();
+             if ( *( YYCURSOR - 1 ) == '\n' ) YYCURSOR--;
+             return YAML_ALIAS;
+         }
+-#line 318 "<stdout>"
+-yy23:	++YYCURSOR;
+-	goto yy24;
+-yy24:
++#line 315 "<stdout>"
++yy23:
++	++YYCURSOR;
+ #line 306 "bytecode.re"
+-{   char *qstr;
++	{   char *qstr;
+             ADD_BYTE_LEVEL(lvl, lvl->spaces + 1, syck_lvl_open);
+             qstr = get_inline( parser );
+             CHK_NL(YYCURSOR);
+@@ -387,18 +376,16 @@ yy24:
+             sycklval->name = qstr;
+             return YAML_TAGURI;
+         }
+-#line 382 "<stdout>"
+-yy25:	++YYCURSOR;
+-	goto yy26;
+-yy26:
++#line 378 "<stdout>"
++yy25:
++	++YYCURSOR;
+ #line 366 "bytecode.re"
+-{   goto Comment; }
+-#line 388 "<stdout>"
+-yy27:	++YYCURSOR;
+-	goto yy28;
+-yy28:
++	{   goto Comment; }
++#line 383 "<stdout>"
++yy27:
++	++YYCURSOR;
+ #line 368 "bytecode.re"
+-{   CHK_NL(YYCURSOR);
++	{   CHK_NL(YYCURSOR);
+             if ( lvl->status == syck_lvl_seq )
+             {
+                 return YAML_INDENT; 
+@@ -410,26 +397,25 @@ yy28:
+             }
+             goto Document;
+         }
+-#line 405 "<stdout>"
+-yy29:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy27;
++#line 399 "<stdout>"
++yy29:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy27;
+ 	default:	goto yy11;
+ 	}
+-yy30:	++YYCURSOR;
+-	goto yy31;
+-yy31:
++yy30:
++	++YYCURSOR;
+ #line 381 "bytecode.re"
+-{   ENSURE_YAML_IEND(lvl, -1);
++	{   ENSURE_YAML_IEND(lvl, -1);
+             YYPOS(0);
+             return 0;
+         }
+-#line 419 "<stdout>"
+-yy32:	++YYCURSOR;
+-	goto yy33;
+-yy33:
++#line 413 "<stdout>"
++yy32:
++	++YYCURSOR;
+ #line 252 "bytecode.re"
+-{   if ( lvl->status == syck_lvl_seq && lvl->ncount == 0 )
++	{   if ( lvl->status == syck_lvl_seq && lvl->ncount == 0 )
+             {
+                 lvl->ncount++;
+                 YYPOS(0);
+@@ -464,17 +450,17 @@ yy33:
+             CHK_NL(YYCURSOR);
+             return YAML_IEND;
+         }
+-#line 459 "<stdout>"
+-yy34:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy32;
++#line 452 "<stdout>"
++yy34:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy32;
+ 	default:	goto yy11;
+ 	}
+-yy35:	++YYCURSOR;
+-	goto yy36;
+-yy36:
++yy35:
++	++YYCURSOR;
+ #line 237 "bytecode.re"
+-{   int complex = 0;
++	{   int complex = 0;
+             if ( lvl->ncount % 2 == 0 && ( lvl->status == syck_lvl_map || lvl->status == syck_lvl_seq ) )
+             {
+                 complex = 1;
+@@ -488,17 +474,17 @@ yy36:
+             }
+             return YAML_IOPEN;
+         }
+-#line 483 "<stdout>"
+-yy37:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy35;
++#line 476 "<stdout>"
++yy37:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy35;
+ 	default:	goto yy11;
+ 	}
+-yy38:	++YYCURSOR;
+-	goto yy39;
+-yy39:
++yy38:
++	++YYCURSOR;
+ #line 222 "bytecode.re"
+-{   int complex = 0;
++	{   int complex = 0;
+             if ( lvl->ncount % 2 == 0 && ( lvl->status == syck_lvl_map || lvl->status == syck_lvl_seq ) )
+             {
+                 complex = 1;
+@@ -512,29 +498,31 @@ yy39:
+             }
+             return YAML_IOPEN;
+         }
+-#line 507 "<stdout>"
+-yy40:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy38;
++#line 500 "<stdout>"
++yy40:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy38;
+ 	default:	goto yy11;
+ 	}
+-yy41:	++YYCURSOR;
+-	goto yy42;
+-yy42:
++yy41:
++	++YYCURSOR;
+ #line 217 "bytecode.re"
+-{   ENSURE_YAML_IEND(lvl, -1);
++	{   ENSURE_YAML_IEND(lvl, -1);
+                 YYPOS(0);
+                 return 0;
+             }
+-#line 521 "<stdout>"
+-yy43:	yych = *++YYCURSOR;
+-	switch(yych){
+-	case 0x0A:	goto yy41;
++#line 514 "<stdout>"
++yy43:
++	yych = *++YYCURSOR;
++	switch (yych) {
++	case '\n':	goto yy41;
+ 	default:	goto yy11;
+ 	}
+-yy44:	++YYCURSOR;
+-	switch((yych = *YYCURSOR)) {
+-	case 0x0A:	goto yy41;
++yy44:
++	++YYCURSOR;
++	switch ((yych = *YYCURSOR)) {
++	case '\n':	goto yy41;
+ 	default:	goto yy11;
+ 	}
+ }
+@@ -548,28 +536,22 @@ Directive:
+         YYTOKEN = YYCURSOR;
+ 
+ 
+-#line 543 "<stdout>"
++#line 538 "<stdout>"
+ {
+ 	YYCTYPE yych;
+-	unsigned int yyaccept = 0;
+-	goto yy45;
+-	/*@notreached@*/
+-	++YYCURSOR;
+-yy45:
+-	if((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
++	if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
+ 	yych = *YYCURSOR;
+-	switch(yych){
++	switch (yych) {
+ 	case 0x00:	goto yy47;
+ 	case 'V':	goto yy48;
+ 	default:	goto yy50;
+ 	}
+-yy47:	YYCURSOR = YYMARKER;
+-	switch(yyaccept){
+-	case 0:	goto yy49;
+-	}
+-yy48:	yyaccept = 0;
++yy47:
++	YYCURSOR = YYMARKER;
++	goto yy49;
++yy48:
+ 	yych = *(YYMARKER = ++YYCURSOR);
+-	switch(yych){
++	switch (yych) {
+ 	case '.':
+ 	case '/':
+ 	case '0':
+@@ -619,7 +601,8 @@ yy48:	yyaccept = 0;
+ 	case '\\':
+ 	case ']':
+ 	case '^':
+-	case '_':	case 'a':
++	case '_':
++	case 'a':
+ 	case 'b':
+ 	case 'c':
+ 	case 'd':
+@@ -649,17 +632,18 @@ yy48:	yyaccept = 0;
+ 	}
+ yy49:
+ #line 399 "bytecode.re"
+-{   YYCURSOR = YYTOKEN;
++	{   YYCURSOR = YYTOKEN;
+                return YAML_DOCSEP;
+            }
+-#line 646 "<stdout>"
+-yy50:	yych = *++YYCURSOR;
++#line 637 "<stdout>"
++yy50:
++	yych = *++YYCURSOR;
+ 	goto yy49;
+-yy51:	++YYCURSOR;
+-	if((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
++yy51:
++	++YYCURSOR;
++	if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
+ 	yych = *YYCURSOR;
+-	goto yy52;
+-yy52:	switch(yych){
++	switch (yych) {
+ 	case '.':
+ 	case '/':
+ 	case '0':
+@@ -671,7 +655,8 @@ yy52:	switch(yych){
+ 	case '6':
+ 	case '7':
+ 	case '8':
+-	case '9':	case ';':
++	case '9':
++	case ';':
+ 	case '<':
+ 	case '=':
+ 	case '>':
+@@ -707,7 +692,8 @@ yy52:	switch(yych){
+ 	case '\\':
+ 	case ']':
+ 	case '^':
+-	case '_':	case 'a':
++	case '_':
++	case 'a':
+ 	case 'b':
+ 	case 'c':
+ 	case 'd':
+@@ -736,8 +722,9 @@ yy52:	switch(yych){
+ 	case ':':	goto yy53;
+ 	default:	goto yy47;
+ 	}
+-yy53:	yych = *++YYCURSOR;
+-	switch(yych){
++yy53:
++	yych = *++YYCURSOR;
++	switch (yych) {
+ 	case '.':
+ 	case '/':
+ 	case '0':
+@@ -787,7 +774,8 @@ yy53:	yych = *++YYCURSOR;
+ 	case '\\':
+ 	case ']':
+ 	case '^':
+-	case '_':	case 'a':
++	case '_':
++	case 'a':
+ 	case 'b':
+ 	case 'c':
+ 	case 'd':
+@@ -815,13 +803,13 @@ yy53:	yych = *++YYCURSOR;
+ 	case 'z':	goto yy54;
+ 	default:	goto yy47;
+ 	}
+-yy54:	++YYCURSOR;
+-	if((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
++yy54:
++	++YYCURSOR;
++	if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
+ 	yych = *YYCURSOR;
+-	goto yy55;
+-yy55:	switch(yych){
+-	case 0x0A:	goto yy56;
+-	case 0x0D:	goto yy58;
++	switch (yych) {
++	case '\n':	goto yy56;
++	case '\r':	goto yy58;
+ 	case '.':
+ 	case '/':
+ 	case '0':
+@@ -871,7 +859,8 @@ yy55:	switch(yych){
+ 	case '\\':
+ 	case ']':
+ 	case '^':
+-	case '_':	case 'a':
++	case '_':
++	case 'a':
+ 	case 'b':
+ 	case 'c':
+ 	case 'd':
+@@ -899,16 +888,16 @@ yy55:	switch(yych){
+ 	case 'z':	goto yy54;
+ 	default:	goto yy47;
+ 	}
+-yy56:	++YYCURSOR;
+-	goto yy57;
+-yy57:
++yy56:
++	++YYCURSOR;
+ #line 396 "bytecode.re"
+-{   CHK_NL(YYCURSOR);
++	{   CHK_NL(YYCURSOR);
+                goto Directive; }
+-#line 899 "<stdout>"
+-yy58:	++YYCURSOR;
+-	switch((yych = *YYCURSOR)) {
+-	case 0x0A:	goto yy56;
++#line 895 "<stdout>"
++yy58:
++	++YYCURSOR;
++	switch ((yych = *YYCURSOR)) {
++	case '\n':	goto yy56;
+ 	default:	goto yy47;
+ 	}
+ }
+@@ -922,40 +911,40 @@ Comment:
+         YYTOKEN = YYCURSOR;
+ 
+ 
+-#line 916 "<stdout>"
++#line 913 "<stdout>"
+ {
+ 	YYCTYPE yych;
+-	goto yy59;
+-	/*@notreached@*/
+-	++YYCURSOR;
+-yy59:
+-	if((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
++	if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
+ 	yych = *YYCURSOR;
+-	switch(yych){
++	switch (yych) {
+ 	case 0x00:	goto yy61;
+-	case 0x0A:	goto yy62;
+-	case 0x0D:	goto yy64;
++	case '\n':	goto yy62;
++	case '\r':	goto yy64;
+ 	default:	goto yy66;
+ 	}
+-yy61:yy62:	++YYCURSOR;
+-	goto yy63;
++yy61:
++yy62:
++	++YYCURSOR;
+ yy63:
+ #line 412 "bytecode.re"
+-{   CHK_NL(YYCURSOR);
++	{   CHK_NL(YYCURSOR);
+                 goto Document; }
+-#line 936 "<stdout>"
+-yy64:	++YYCURSOR;
+-	switch((yych = *YYCURSOR)) {
+-	case 0x0A:	goto yy67;
++#line 931 "<stdout>"
++yy64:
++	++YYCURSOR;
++	switch ((yych = *YYCURSOR)) {
++	case '\n':	goto yy67;
+ 	default:	goto yy65;
+ 	}
+ yy65:
+ #line 415 "bytecode.re"
+-{   goto Comment; }
+-#line 945 "<stdout>"
+-yy66:	yych = *++YYCURSOR;
++	{   goto Comment; }
++#line 941 "<stdout>"
++yy66:
++	yych = *++YYCURSOR;
+ 	goto yy65;
+-yy67:	++YYCURSOR;
++yy67:
++	++YYCURSOR;
+ 	yych = *YYCURSOR;
+ 	goto yy63;
+ }
+@@ -977,23 +966,20 @@ Scalar2:
+     tok = YYCURSOR;
+ 
+ 
+-#line 970 "<stdout>"
++#line 968 "<stdout>"
+ {
+ 	YYCTYPE yych;
+-	goto yy68;
+-	/*@notreached@*/
+-	++YYCURSOR;
+-yy68:
+-	if((YYLIMIT - YYCURSOR) < 3) YYFILL(3);
++	if ((YYLIMIT - YYCURSOR) < 3) YYFILL(3);
+ 	yych = *YYCURSOR;
+-	switch(yych){
++	switch (yych) {
+ 	case 0x00:	goto yy74;
+-	case 0x0A:	goto yy70;
+-	case 0x0D:	goto yy72;
++	case '\n':	goto yy70;
++	case '\r':	goto yy72;
+ 	default:	goto yy76;
+ 	}
+-yy70:	++YYCURSOR;
+-	switch((yych = *YYCURSOR)) {
++yy70:
++	++YYCURSOR;
++	switch ((yych = *YYCURSOR)) {
+ 	case 'C':	goto yy78;
+ 	case 'N':	goto yy80;
+ 	case 'Z':	goto yy83;
+@@ -1001,50 +987,51 @@ yy70:	++YYCURSOR;
+ 	}
+ yy71:
+ #line 461 "bytecode.re"
+-{   YYCURSOR = tok;
++	{   YYCURSOR = tok;
+             goto ScalarEnd; 
+         }
+-#line 996 "<stdout>"
+-yy72:	++YYCURSOR;
+-	switch((yych = *YYCURSOR)) {
+-	case 0x0A:	goto yy77;
++#line 992 "<stdout>"
++yy72:
++	++YYCURSOR;
++	switch ((yych = *YYCURSOR)) {
++	case '\n':	goto yy77;
+ 	default:	goto yy73;
+ 	}
+ yy73:
+ #line 469 "bytecode.re"
+-{   CAT(str, cap, idx, tok[0]);
++	{   CAT(str, cap, idx, tok[0]);
+             goto Scalar2; 
+         }
+-#line 1007 "<stdout>"
+-yy74:	++YYCURSOR;
+-	goto yy75;
+-yy75:
++#line 1004 "<stdout>"
++yy74:
++	++YYCURSOR;
+ #line 465 "bytecode.re"
+-{   YYCURSOR = tok;
++	{   YYCURSOR = tok;
+             goto ScalarEnd;
+         }
+-#line 1015 "<stdout>"
+-yy76:	yych = *++YYCURSOR;
++#line 1011 "<stdout>"
++yy76:
++	yych = *++YYCURSOR;
+ 	goto yy73;
+-yy77:	yych = *++YYCURSOR;
+-	switch(yych){
++yy77:
++	yych = *++YYCURSOR;
++	switch (yych) {
+ 	case 'C':	goto yy78;
+ 	case 'N':	goto yy80;
+ 	case 'Z':	goto yy83;
+ 	default:	goto yy71;
+ 	}
+-yy78:	++YYCURSOR;
+-	goto yy79;
+-yy79:
++yy78:
++	++YYCURSOR;
+ #line 435 "bytecode.re"
+-{   CHK_NL(tok+1);
++	{   CHK_NL(tok+1);
+             goto Scalar2; }
+-#line 1031 "<stdout>"
+-yy80:	++YYCURSOR;
+-	if(YYLIMIT == YYCURSOR) YYFILL(1);
++#line 1028 "<stdout>"
++yy80:
++	++YYCURSOR;
++	if (YYLIMIT <= YYCURSOR) YYFILL(1);
+ 	yych = *YYCURSOR;
+-	goto yy81;
+-yy81:	switch(yych){
++	switch (yych) {
+ 	case '0':
+ 	case '1':
+ 	case '2':
+@@ -1059,7 +1046,7 @@ yy81:	switch(yych){
+ 	}
+ yy82:
+ #line 438 "bytecode.re"
+-{   CHK_NL(tok+1);
++	{   CHK_NL(tok+1);
+             if ( tok + 2 < YYCURSOR )
+             {
+                 char *count = tok + 2;
+@@ -1076,16 +1063,15 @@ yy82:
+             }
+             goto Scalar2;
+         }
+-#line 1068 "<stdout>"
+-yy83:	++YYCURSOR;
+-	goto yy84;
+-yy84:
++#line 1065 "<stdout>"
++yy83:
++	++YYCURSOR;
+ #line 456 "bytecode.re"
+-{   CHK_NL(tok+1);
++	{   CHK_NL(tok+1);
+             CAT(str, cap, idx, '\0');
+             goto Scalar2; 
+         }
+-#line 1077 "<stdout>"
++#line 1073 "<stdout>"
+ }
+ #line 473 "bytecode.re"
+ 
+@@ -1122,50 +1108,48 @@ Inline:
+         tok = YYCURSOR;
+ 
+ 
+-#line 1114 "<stdout>"
++#line 1110 "<stdout>"
+ {
+ 	YYCTYPE yych;
+-	goto yy85;
+-	/*@notreached@*/
+-	++YYCURSOR;
+-yy85:
+-	if((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
++	if ((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
+ 	yych = *YYCURSOR;
+-	switch(yych){
++	switch (yych) {
+ 	case 0x00:	goto yy91;
+-	case 0x0A:	goto yy87;
+-	case 0x0D:	goto yy89;
++	case '\n':	goto yy87;
++	case '\r':	goto yy89;
+ 	default:	goto yy93;
+ 	}
+-yy87:	++YYCURSOR;
+-	goto yy88;
++yy87:
++	++YYCURSOR;
+ yy88:
+ #line 508 "bytecode.re"
+-{   CHK_NL(YYCURSOR);
++	{   CHK_NL(YYCURSOR);
+                 return str; }
+-#line 1134 "<stdout>"
+-yy89:	++YYCURSOR;
+-	switch((yych = *YYCURSOR)) {
+-	case 0x0A:	goto yy94;
++#line 1127 "<stdout>"
++yy89:
++	++YYCURSOR;
++	switch ((yych = *YYCURSOR)) {
++	case '\n':	goto yy94;
+ 	default:	goto yy90;
+ 	}
+ yy90:
+ #line 515 "bytecode.re"
+-{   CAT(str, cap, idx, tok[0]);
++	{   CAT(str, cap, idx, tok[0]);
+                 goto Inline; 
+             }
+-#line 1145 "<stdout>"
+-yy91:	++YYCURSOR;
+-	goto yy92;
+-yy92:
++#line 1139 "<stdout>"
++yy91:
++	++YYCURSOR;
+ #line 511 "bytecode.re"
+-{   YYCURSOR = tok;
++	{   YYCURSOR = tok;
+                 return str;
+             }
+-#line 1153 "<stdout>"
+-yy93:	yych = *++YYCURSOR;
++#line 1146 "<stdout>"
++yy93:
++	yych = *++YYCURSOR;
+ 	goto yy90;
+-yy94:	++YYCURSOR;
++yy94:
++	++YYCURSOR;
+ 	yych = *YYCURSOR;
+ 	goto yy88;
+ }
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tag-generate-endian-conversion-fix.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tag-generate-endian-conversion-fix.patch
index 683275c..5fb40b6 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tag-generate-endian-conversion-fix.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tag-generate-endian-conversion-fix.patch
@@ -6,7 +6,7 @@
 
 This patch resolves it by taking the byte order that host uses.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Ming Liu <ming.liu@windriver.com>
 ---
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tagname-type.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tagname-type.patch
new file mode 100644
index 0000000..9eb675b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tagname-type.patch
@@ -0,0 +1,25 @@
+rpmdb/tagname.c: Add the 0x54aafb71 (filenames) type to rpmTagGetType
+
+There is already a workaround in the _tagName function to show that the
+special 'filenames' item is value.  This adds a similar patch to the
+_tagType to return the proper type, otherwise it comes back as a simple
+RPM_STRING_ARRAY_TYPE which limits the response to the first element.
+
+Upstream-Status: Submitted [RPM5 maintainer]
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.15/rpmdb/tagname.c
+===================================================================
+--- rpm-5.4.15.orig/rpmdb/tagname.c
++++ rpm-5.4.15/rpmdb/tagname.c
+@@ -353,6 +353,9 @@ static unsigned int _tagType(rpmTag tag)
+     case RPMDBI_RECNO:
+     case RPMDBI_HEAP:
+ 	break;
++    /* XXX make sure that h.['filenames'] in python "works". */
++    case 0x54aafb71:
++	return (RPM_STRING_ARRAY_TYPE + RPM_ARRAY_RETURN_TYPE);
+     default:
+ 	if (_rpmTags.byValue == NULL)
+ 	    break;
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tools-mtree-LDFLAGS.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tools-mtree-LDFLAGS.patch
index cb85beb..72d3509 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tools-mtree-LDFLAGS.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpm-tools-mtree-LDFLAGS.patch
@@ -1,5 +1,5 @@
 Source: None
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 Author: Khem Raj <raj.khem@gmail.com>
 Date: 2011-03-03
 Description:
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmatch.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmatch.patch
index 20d13aa..9bbf580 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmatch.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmatch.patch
@@ -1,31 +1,23 @@
-Add configure check for rpmatch() and 
-creates a compatable macro if it is not provided by the C library.
+Create a compatable macro if rpmatch() is not provided by the C library.
+
+This uses an existing configure check.
 
 This is needed for uclibc since it does not have the above function
 implemented.
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
-Index: rpm-5.4.14/configure.ac
+Updated to rpm 5.4.15+.
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm/system.h
 ===================================================================
---- rpm-5.4.14.orig/configure.ac
-+++ rpm-5.4.14/configure.ac
-@@ -943,7 +943,7 @@ AC_CHECK_FUNCS([dnl
-     ftok getaddrinfo getattrlist getcwd getdelim getline getmode getnameinfo dnl
-     getpassphrase getxattr getwd iconv inet_aton lchflags lchmod lchown dnl
-     lgetxattr lsetxattr lutimes madvise mempcpy mkdtemp mkstemp mtrace dnl
--    posix_fadvise posix_fallocate putenv realpath regcomp secure_getenv __secure_getenv dnl
-+    posix_fadvise posix_fallocate putenv realpath regcomp rpmatch secure_getenv __secure_getenv dnl
-     setattrlist setenv setlocale setmode setxattr dnl
-     sigaddset sigdelset sigemptyset sighold sigrelse sigpause dnl
-     sigprocmask sigsuspend sigaction dnl
-Index: rpm-5.4.14/system.h
-===================================================================
---- rpm-5.4.14.orig/system.h
-+++ rpm-5.4.14/system.h
-@@ -353,6 +353,14 @@ extern int _tolower(int) __THROW	/*@*/;
+--- rpm.orig/system.h
++++ rpm/system.h
+@@ -358,6 +358,14 @@ extern int _tolower(int) __THROW	/*@*/;
  #include <libgen.h>
  #endif
  
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmdb-more-verbose-error-logging-in-rpmTempFile.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmdb-more-verbose-error-logging-in-rpmTempFile.patch
new file mode 100644
index 0000000..809e54e
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmdb-more-verbose-error-logging-in-rpmTempFile.patch
@@ -0,0 +1,53 @@
+rpmdb: more verbose error logging in rpmTempFile()
+
+Upstream-Status: Inappropriate [debugging]
+
+Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
+
+diff --git a/rpmdb/signature.c b/rpmdb/signature.c
+index dce6c4e..a1d0f06 100644
+--- a/rpmdb/signature.c
++++ b/rpmdb/signature.c
+@@ -37,6 +37,7 @@ int rpmTempFile(const char * prefix, const char ** fnptr, void * fdptr)
+     int temput;
+     FD_t fd = NULL;
+     unsigned int ran;
++    int ret = 0;
+ 
+     if (!prefix) prefix = "";
+ 
+@@ -44,8 +45,11 @@ int rpmTempFile(const char * prefix, const char ** fnptr, void * fdptr)
+     if (!_initialized) {
+ 	_initialized = 1;
+ 	tempfn = rpmGenPath(prefix, tpmacro, NULL);
+-	if (rpmioMkpath(tempfn, 0755, (uid_t) -1, (gid_t) -1))
+-	    goto errxit;
++        ret = rpmioMkpath(tempfn, 0755, (uid_t) -1, (gid_t) -1);
++        if (ret) {
++            rpmlog(RPMLOG_ERR, _("error creating temporary directory %s: %d\n"), tempfn, ret);
++            goto errxit;
++        }
+     }
+ 
+     /* XXX should probably use mkstemp here */
+@@ -68,12 +72,16 @@ int rpmTempFile(const char * prefix, const char ** fnptr, void * fdptr)
+ #endif
+ 
+ 	temput = urlPath(tempfn, &tfn);
+-	if (*tfn == '\0') goto errxit;
++	if (*tfn == '\0') {
++            rpmlog(RPMLOG_ERR, _("error creating tempfile: empty filename\n"));
++            goto errxit;
++        }
+ 
+ 	switch (temput) {
+ 	case URL_IS_DASH:
+ 	case URL_IS_HKP:
+ 	case URL_IS_MONGO:	/* XXX FIXME */
++            rpmlog(RPMLOG_ERR, _("error creating temporary file, invalid uri type: %d\n"), temput);
+ 	    goto errxit;
+ 	    /*@notreached@*/ /*@switchbreak@*/ break;
+ 	case URL_IS_HTTPS:
+-- 
+2.6.6
+
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmqv.c-check-_gpg_passphrase-before-ask-for-input.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmqv.c-check-_gpg_passphrase-before-ask-for-input.patch
new file mode 100644
index 0000000..c68681c
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmqv.c-check-_gpg_passphrase-before-ask-for-input.patch
@@ -0,0 +1,70 @@
+From bb48dbc88a58bc05a43d71a3375fb05358119ec5 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Sun, 20 Mar 2016 20:20:16 -0700
+Subject: [PATCH] rpmqv.c: check _gpg_passphrase before ask for input
+
+rpm always asked for pass phrasae when add signature, which made it
+can't work non-interactively, this patch fix the problem. It will work
+non-interactively if _gpg_passphrase is defined, and work as before if
+not.
+
+Upstream-Status: Pending
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ macros/macros.in |    7 +++++--
+ rpmqv.c          |   17 ++++++++++-------
+ 2 files changed, 15 insertions(+), 9 deletions(-)
+
+diff --git a/macros/macros.in b/macros/macros.in
+index 2e5b07d..01b3aad 100644
+--- a/macros/macros.in
++++ b/macros/macros.in
+@@ -520,15 +520,18 @@ $_arbitrary_tags_tests	Foo:Bar
+ #	Macro(s) to hold the arguments passed to GPG/PGP for package
+ #	signing and verification.
+ #
++
++%_gpg_passphrase_way %{?_gpg_passphrase:--passphrase "%{_gpg_passphrase}"}%{!?_gpg_passphrase:--passphrase-fd 3}
++
+ %__gpg_check_password_cmd	%{__gpg} \
+-	gpg --batch --no-verbose --passphrase-fd 3 -u "%{_gpg_name}" -so -
++	gpg --batch --no-verbose %{_gpg_passphrase_way} -u "%{_gpg_name}" -so -
+ #%__pgp_check_password_cmd	%{__pgp} \
+ #	pgp +batchmode=on +verbose=0 "%{_pgp_name}" -sf
+ #%__pgp5_check_password_cmd	%{__pgp} \
+ #	pgps +batchmode=on +verbose=0 +armor=off "%{_pgp_name}" -f
+ 
+ %__gpg_sign_cmd			%{__gpg} \
+-	gpg --batch --no-verbose --no-armor --passphrase-fd 3 --no-secmem-warning \
++	gpg --batch --no-verbose --no-armor %{_gpg_passphrase_way}  --no-secmem-warning \
+ 	-u "%{_gpg_name}" -sbo %{__signature_filename} %{__plaintext_filename}
+ #%__pgp_sign_cmd			%{__pgp} \
+ #	pgp +batchmode=on +verbose=0 +armor=off \
+diff --git a/rpmqv.c b/rpmqv.c
+index b306486..7604396 100644
+--- a/rpmqv.c
++++ b/rpmqv.c
+@@ -831,13 +831,16 @@ int main(int argc, const char ** argv)
+ #endif
+ 	    )
+ 	    {
+-		passPhrase = Getpass(_("Enter pass phrase: "));
+-		if (rpmCheckPassPhrase(passPhrase)) {
+-		    fprintf(stderr, _("Pass phrase check failed\n"));
+-		    ec = EXIT_FAILURE;
+-		    goto exit;
++		passPhrase = rpmExpand("%{?_gpg_passphrase}", NULL);
++		if (passPhrase == NULL || passPhrase[0] == '\0') {
++			passPhrase = Getpass(_("Enter pass phrase: "));
++			if (rpmCheckPassPhrase(passPhrase)) {
++			    fprintf(stderr, _("Pass phrase check failed\n"));
++			    ec = EXIT_FAILURE;
++			    goto exit;
++			}
++			fprintf(stderr, _("Pass phrase is good.\n"));
+ 		}
+-		fprintf(stderr, _("Pass phrase is good.\n"));
+ 		/* XXX Getpass() should realloc instead. */
+ 		passPhrase = xstrdup(passPhrase);
+ 	    }
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
index f08bd68..b2437a8 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/rpmqv_cc_b_gone.patch
@@ -1,4 +1,7 @@
-rpm: compile rpmqv.c instead of rpmqv.cc
+From e8bae261615e19ff8a28683765c9539cfb22a086 Mon Sep 17 00:00:00 2001
+From: Joe Slater <jslater@windriver.com>
+Date: Thu, 17 Jul 2014 18:14:54 -0700
+Subject: [PATCH 1/9] rpm: compile rpmqv.c instead of rpmqv.cc
 
 Some versions of gcc, 4.4.5 for example, will put a reference to __gxx_personality_v0
 into rpm.o and rpmbuild.o.  This means we must link with g++, and the Makefile we
@@ -10,23 +13,38 @@
 
    When linking with g++ is really necessary, the upstream package will do that.
 
-Signed-off-by: Joe Slater <joe.slater@windriver.com>
+Also instead of symlinking files in two places, which can and does race in
+parallel builds, simply refer to the file's full location [RB]
 
+Signed-off-by: Joe Slater <joe.slater@windriver.com>
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+---
+ Makefile.am | 6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index 1dade0a..55f8669 100644
 --- a/Makefile.am
 +++ b/Makefile.am
-@@ -127,13 +127,13 @@ rpm_SOURCES =		build.c
+@@ -201,15 +201,13 @@ rpm_SOURCES =		build.c
  rpm_LDFLAGS =		@LDFLAGS_STATIC@ $(LDFLAGS)
  rpm_LDADD =		rpm.o $(myLDADD)
  rpm.o:	$(top_srcdir)/rpmqv.c
--	$(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c $(top_srcdir)/rpmqv.cc
-+	$(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c $(top_srcdir)/rpmqv.c
+-	ln -sf $< rpmqv.cc
+-	$(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c rpmqv.cc
++	$(COMPILE) -DIAM_RPMBT -DIAM_RPMDB -DIAM_RPMEIU -DIAM_RPMK -DIAM_RPMQV -o $@ -c $^
  
  rpmbuild_SOURCES =	build.c
  rpmbuild_LDFLAGS =	@LDFLAGS_STATIC@ $(LDFLAGS)
  rpmbuild_LDADD =	rpmbuild.o $(myLDADD)
- rpmbuild.o: $(top_srcdir)/rpmqv.c
--	$(COMPILE) -DIAM_RPMBT -o $@ -c $(top_srcdir)/rpmqv.cc
-+	$(COMPILE) -DIAM_RPMBT -o $@ -c $(top_srcdir)/rpmqv.c
+ rpmbuild.o:	$(top_srcdir)/rpmqv.c
+-	ln -sf $< rpmqv.cc
+-	$(COMPILE) -DIAM_RPMBT -o $@ -c rpmqv.cc
++	$(COMPILE) -DIAM_RPMBT -o $@ -c $^
  
- .PHONY:	splint
- splint:
+ .syntastic_c_config: Makefile
+ 	@echo $(COMPILE) | tr ' ' '\n' | sed -e '1d' > $@
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/uclibc-support.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/uclibc-support.patch
index 8870adb..dc7b048 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/uclibc-support.patch
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm/uclibc-support.patch
@@ -1,13 +1,13 @@
 Define the x* wrappers for uclibc as well
 
-Upstream-Status: Pending
+Upstream-Status: Submitted [RPM5 maintainer]
 
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 
-Index: rpm-5.4.14/rpmio/rpmio.h
+Index: rpm/rpmio/rpmio.h
 ===================================================================
---- rpm-5.4.14.orig/rpmio/rpmio.h
-+++ rpm-5.4.14/rpmio/rpmio.h
+--- rpm.orig/rpmio/rpmio.h
++++ rpm/rpmio/rpmio.h
 @@ -23,7 +23,8 @@
   */
  /*@{*/
@@ -18,11 +18,11 @@
  #define USE_COOKIE_SEEK_POINTER 1
  typedef _IO_off64_t 	_libio_off_t;
  typedef _libio_off_t *	_libio_pos_t;
-Index: rpm-5.4.14/system.h
+Index: rpm/system.h
 ===================================================================
---- rpm-5.4.14.orig/system.h
-+++ rpm-5.4.14/system.h
-@@ -481,7 +481,7 @@ extern void muntrace (void)
+--- rpm.orig/system.h
++++ rpm/system.h
+@@ -489,7 +489,7 @@ extern void muntrace (void)
  #endif /* defined(__LCLINT__) */
  
  /* Memory allocation via macro defs to get meaningful locations from mtrace() */
@@ -31,11 +31,11 @@
  #define	xmalloc(_size) 		(malloc(_size) ? : vmefail(_size))
  #define	xcalloc(_nmemb, _size)	(calloc((_nmemb), (_size)) ? : vmefail(_size))
  #define	xrealloc(_ptr, _size)	(realloc((_ptr), (_size)) ? : vmefail(_size))
-Index: rpm-5.4.14/lib/librpm.vers
+Index: rpm/lib/librpm.vers
 ===================================================================
---- rpm-5.4.14.orig/lib/librpm.vers
-+++ rpm-5.4.14/lib/librpm.vers
-@@ -405,6 +405,10 @@ LIBRPM_0
+--- rpm.orig/lib/librpm.vers
++++ rpm/lib/librpm.vers
+@@ -406,6 +406,10 @@ LIBRPM_0
      specedit;
      strict_erasures;
      XrpmtsiInit;
@@ -46,14 +46,14 @@
    local:
      *;
  };
-Index: rpm-5.4.14/rpmio/librpmio.vers
+Index: rpm/rpmio/librpmio.vers
 ===================================================================
---- rpm-5.4.14.orig/rpmio/librpmio.vers
-+++ rpm-5.4.14/rpmio/librpmio.vers
-@@ -1056,6 +1056,10 @@ LIBRPMIO_0
-     mongo_write_concern_set_mode;
-     mongo_write_concern_set_w;
-     mongo_write_concern_set_wtimeout;
+--- rpm.orig/rpmio/librpmio.vers
++++ rpm/rpmio/librpmio.vers
+@@ -1455,6 +1455,10 @@ LIBRPMIO_0
+     _mongoc_write_result_init;
+     _mongoc_write_result_merge;
+     _mongoc_write_result_merge_legacy;
 +    xmalloc;
 +    xrealloc;
 +    xcalloc;
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm/verify-fix-broken-logic-for-ghost-avoidance-Mark-Hat.patch b/yocto-poky/meta/recipes-devtools/rpm/rpm/verify-fix-broken-logic-for-ghost-avoidance-Mark-Hat.patch
deleted file mode 100644
index 71045ae..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm/verify-fix-broken-logic-for-ghost-avoidance-Mark-Hat.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From 9e7b72ee0c994609975981e135fc18d0387aefb6 Mon Sep 17 00:00:00 2001
-From: jbj <jbj>
-Date: Wed, 14 May 2014 21:19:41 +0000
-Subject: [PATCH] - verify: fix: broken logic for %ghost avoidance (Mark
- Hatle).
-
-Upstream-Status: Backport
-
-Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
----
- CHANGES      | 1 +
- lib/verify.c | 3 +--
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-Index: rpm-5.4.14/CHANGES
-===================================================================
---- rpm-5.4.14.orig/CHANGES
-+++ rpm-5.4.14/CHANGES
-@@ -1,3 +1,5 @@
-+    - jbj: verify: fix: broken logic for %ghost avoidance (Mark Hatle).
-+
- 5.4.13 -> 5.4.14:
-     - mooney: use __sun instead of __sun__ in #define (lp#1243472).
-     - mooney: rpmconstant: ensure linkage w Oracle Studio 12.3 (lp#1243469).
-Index: rpm-5.4.14/lib/verify.c
-===================================================================
---- rpm-5.4.14.orig/lib/verify.c
-+++ rpm-5.4.14/lib/verify.c
-@@ -588,8 +588,7 @@ uint32_t fc = rpmfiFC(fi);
- 	    continue;
- 
- 	/* If not verifying %ghost, skip ghost files. */
--	/* XXX the broken!!! logic disables %ghost queries always. */
--	if (!(FF_ISSET(qva->qva_fflags, GHOST) && FF_ISSET(fflags, GHOST)))
-+	if (!FF_ISSET(qva->qva_fflags, GHOST) && FF_ISSET(fflags, GHOST))
- 	    continue;
- 
- 	/* Gather per-file data into a carrier. */
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm_4.11.2.bb b/yocto-poky/meta/recipes-devtools/rpm/rpm_4.11.2.bb
deleted file mode 100644
index f4a2110..0000000
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm_4.11.2.bb
+++ /dev/null
@@ -1,138 +0,0 @@
-SUMMARY = "The RPM package management system"
-DESCRIPTION = "The RPM Package Manager (RPM) is a powerful command line driven \
-package management system capable of installing, uninstalling, \
-verifying, querying, and updating software packages. Each software \
-package consists of an archive of files along with information about \
-the package like its version, a description, etc."
-
-SUMMARY_${PN}-dev = "Development files for manipulating RPM packages"
-DESCRIPTION_${PN}-dev = "This package contains the RPM C library and header files. These \
-development files will simplify the process of writing programs that \
-manipulate RPM packages and databases. These files are intended to \
-simplify the process of creating graphical package managers or any \
-other tools that need an intimate knowledge of RPM packages in order \
-to function."
-
-SUMMARY_python-rpm = "Python bindings for apps which will manupulate RPM packages"
-DESCRIPTION_python-rpm = "The rpm-python package contains a module that permits applications \
-written in the Python programming language to use the interface \
-supplied by the RPM Package Manager libraries."
-
-HOMEPAGE = "http://www.rpm.org"
-LICENSE = "GPL-2.0+"
-LIC_FILES_CHKSUM ??= "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6"
-
-DEPENDS = "db libxml2 xz findutils file popt nss bzip2 elfutils attr zlib acl gzip python"
-DEPENDS_append_class-native = " file-replacement-native"
-
-SRC_URI += "http://rpm.org/releases/rpm-4.11.x/${BP}.tar.bz2 \
-            file://use-pkgconfig-for-python.patch \
-            file://remove-db3-from-configure.patch \
-            file://add_RPMSENSE_MISSINGOK_to_rpmmodule.patch \
-            file://support-suggests-tag.patch \
-            file://remove-dir-check.patch \
-            file://disable_shortcircuited.patch \
-            file://fix_libdir.patch \
-            file://rpm-scriptetexechelp.patch \
-            file://pythondeps.sh \
-            file://rpm-CVE-2014-8118.patch \
-            file://rpm-CVE-2013-6435.patch \
-           "
-
-SRC_URI[md5sum] = "876ac9948a88367054f8ddb5c0e87173"
-SRC_URI[sha256sum] = "403f8de632b33846ce5746f429c21a60f40dff9dcb56f1b4118f37a0652a48d4"
-
-PR = "r1"
-
-inherit autotools
-inherit pythonnative
-inherit pkgconfig
-inherit gettext
-
-EXTRA_OECONF += "--host=${HOST_SYS} \
-                 --program-prefix= \
-                 --prefix=${prefix} \
-                 --exec-prefix=${prefix} \
-                 --bindir=${prefix}/bin \
-                 --sbindir=${prefix}/sbin \
-                 --sysconfdir=${sysconfdir} \
-                 --datadir=${prefix}/share \
-                 --includedir=${prefix}/include \
-                 --libdir=${prefix}/lib \
-                 --libexecdir=${prefix}/libexec \
-                 --localstatedir=${localstatedir} \
-                 --sharedstatedir=${prefix}/com \
-                 --mandir=${mandir} \
-                 --infodir=${infodir} \
-                 --disable-dependency-tracking \
-                 --with-acl \
-                 --without-lua \
-                 --without-cap \
-                 --enable-shared \
-                 --enable-python \
-                 --with-external-db \
-                "
-
-CPPFLAGS_append = " `pkg-config --cflags nss`"
-LDFLAGS_append = " -Wl,-Bsymbolic-functions -ffunction-sections"
-CCFLAGS_append = " -fPIC "
-CXXFLAGS_append = " -fPIC "
-CFLAGS_append = " -fPIC -DRPM_VENDOR_WINDRIVER -DRPM_VENDOR_POKY -DRPM_VENDOR_OE "
-
-do_configure_prepend() {
-    rm -rf sqlite
-    rm -f m4/libtool.m4
-    rm -f m4/lt*.m4
-    rm -rf db3/configure*
-}
-
-do_install_append() {
-    mv ${D}/${base_bindir}/rpm ${D}/${bindir}/
-    rmdir ${D}/${base_bindir}
-    rm -f ${D}${prefix}/lib/*.la
-    rm -f ${D}${prefix}/lib/rpm-plugins/*.la
-    rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/*.{a,la}
-    rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/rpm/*.{a,la}
-    rm -fr ${D}/var
-    install -d ${D}${prefix}/lib/rpm/bin
-    ln -s ../debugedit ${D}${prefix}/lib/rpm/bin/debugedit
-    ln -s ../rpmdeps ${D}${prefix}/lib/rpm/bin/rpmdeps-oecore
-    install -m 0755 ${WORKDIR}/pythondeps.sh ${D}/${libdir}/rpm/pythondeps.sh
-}
-
-pkg_postinst_${PN}() {
-
-    [ "x\$D" == "x" ] && ldconfig
-    test -f ${localstatedir}/lib/rpm/Packages || rpm --initdb
-    rm -f ${localstatedir}/lib/rpm/Filemd5s \
-          ${localstatedir}/lib/rpm/Filedigests \
-          ${localstatedir}/lib/rpm/Requireversion \
-          ${localstatedir}/lib/rpm/Provideversion
-
-}
-
-pkg_postrm_${PN}() {
-    [ "x\$D" == "x" ] && ldconfig
-
-}
-
-PACKAGES += "python-${PN}"
-PROVIDES += "python-rpm"
-
-FILES_${PN} +=  "${libdir}/rpm \
-                 ${libdir}/rpm-plugins/exec.so \
-                "
-RDEPENDS_${PN} = "base-files run-postinsts"
-RDEPENDS_${PN}_class-native = ""
-
-FILES_${PN}-dbg += "${libdir}/rpm/.debug/* \
-                    ${libdir}/rpm-plugins/.debug/* \
-                    ${libdir}/python2.7/site-packages/rpm/.debug/* \
-                   "
-
-FILES_${PN}-dev += "${libdir}/python2.7/site-packages/rpm/*.la"
-
-FILES_python-${PN} = "${libdir}/python2.7/site-packages/rpm/*"
-RDEPENDS_python-${PN} = "${PN} python"
-
-BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm_5.4+cvs.bb b/yocto-poky/meta/recipes-devtools/rpm/rpm_5.4+cvs.bb
index 951b251..0991f6d 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm_5.4+cvs.bb
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm_5.4+cvs.bb
@@ -34,24 +34,22 @@
 written in the Perl programming language to use the interface \
 supplied by the RPM Package Manager libraries."
 
-SUMMARY_perl-module-rpm-dev = "Development components for perl bindings"
-DESCRIPTION_perl-modules-rpm-dev = "Development items such as man pages for use with the Perl \
-language bindings."
-
 HOMEPAGE = "http://rpm5.org/"
-LICENSE = "LGPLv2.1"
+LICENSE = "LGPLv2.1 & Apache-2.0"
 LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1"
+LIC_FILES_CHKSUM += "file://rpmio/mongo.c;begin=5;end=18;md5=d8327ba2c71664c059143e6d333b8901"
 
-DEPENDS = "libpcre attr acl popt ossp-uuid file byacc-native"
+# We must have gettext-native, we need gettextize, which may not be provided
+DEPENDS = "libpcre attr acl ossp-uuid file byacc-native gettext-native"
 DEPENDS_append_class-native = " file-replacement-native"
 
-S = "${WORKDIR}/rpm"
-
 # Apply various fixups that are unique to the CVS environment
 do_fixup_unpack () {
-	ln -sf ../syck ${S}/syck || :
-	ln -sf ../lua ${S}/lua || :
-	ln ${S}/rpmqv.c ${S}/rpmqv.cc || :
+	# 'ln' isn't reliable, and 'mv' could break later builds
+	rm -rf ${S}/syck ; cp -r ${WORKDIR}/syck ${S}/.
+	rm -rf ${S}/lua ; cp -r ${WORKDIR}/lua ${S}/.
+	rm -rf ${S}/popt ; cp -r ${WORKDIR}/popt ${S}/.
+	rm -rf ${S}/beecrypt ; cp -r ${WORKDIR}/beecrypt ${S}/.
 }
 
 addtask fixup_unpack after do_unpack before do_patch
@@ -60,45 +58,34 @@
 # community work in progress.
 DEFAULT_PREFERENCE = "-1"
 
+S = "${WORKDIR}/rpm"
+
 # rpm2cpio is a shell script, which is part of the rpm src.rpm.  It is needed
 # in order to extract the distribution SRPM into a format we can extract...
 SRC_URI = "cvs://anonymous@rpm5.org/cvs;tag=rpm-5_4;module=rpm \
 	   cvs://anonymous@rpm5.org/cvs;tag=rpm-5_4;module=syck \
 	   cvs://anonymous@rpm5.org/cvs;tag=rpm-5_4;module=lua \
-	   file://rpm-log-auto-rm.patch \
-	   file://rpm-db-reduce.patch \
+	   cvs://anonymous@rpm5.org/cvs;tag=rpm-5_4;module=popt \
+	   cvs://anonymous@rpm5.org/cvs;tag=rpm-5_4;module=beecrypt \
 	   file://perfile_rpmdeps.sh \
-	   file://rpm-autogen.patch \
-	   file://rpm-libsql-fix.patch \
+	   file://pythondeps.sh \
+"
+
+# Bug fixes
+SRC_URI += " \
 	   file://header-include-fix.patch \
+	   file://rpm-libsql-fix.patch \
 	   file://rpm-platform.patch \
-	   file://rpm-showrc.patch \
+	   file://rpm-platform2.patch \
 	   file://rpm-tools-mtree-LDFLAGS.patch \
-	   file://rpm-fileclass.patch \
 	   file://rpm-canonarch.patch \
 	   file://rpm-no-loopmsg.patch \
-	   file://rpm-scriptletexechelper.patch \
-	   file://pythondeps.sh \
-	   file://rpmdeps-oecore.patch \
 	   file://rpm-resolvedep.patch \
-	   file://rpm-no-perl-urpm.patch \
-	   file://rpm-macros.patch \
-	   file://rpm-lua.patch \
-	   file://rpm-ossp-uuid.patch \
 	   file://rpm-packageorigin.patch \
-	   file://rpm-pkgconfigdeps.patch \
 	   file://uclibc-support.patch \
 	   file://rpmatch.patch \
-	   file://fstack-protector-configure-check.patch \
-	   file://dbconvert.patch \
-	   file://rpm-uuid-include.patch \
 	   file://makefile-am-exec-hook.patch \
-	   file://rpm-db_buffer_small.patch \
-	   file://rpm-py-init.patch \
 	   file://python-rpm-rpmsense.patch \
-	   file://rpm-reloc-macros.patch \
-	   file://rpm-platform2.patch \
-	   file://rpm-remove-sykcparse-decl.patch \
 	   file://debugedit-segv.patch \
 	   file://debugedit-valid-file-to-fix-segment-fault.patch \
 	   file://rpm-platform-file-fix.patch \
@@ -107,12 +94,63 @@
 	   file://rpm-hardlink-segfault-fix.patch \
 	   file://rpm-payload-use-hashed-inode.patch \
 	   file://rpm-fix-logio-cp.patch \
-	   file://rpm-db5-or-db6.patch \
-	   file://rpm-rpmpgp-fix.patch \
-	   file://rpm-disable-Wno-override-init.patch \
-	   file://rpm-realpath.patch \
-	  "
+	   file://0001-using-poptParseArgvString-to-parse-the-_gpg_check_pa.patch \
+	   file://rpm-opendb-before-verifyscript-to-avoid-null-point.patch \
+	   file://0001-define-EM_AARCH64.patch \
+	   file://rpm-rpmfc.c-fix-for-N32-MIPS64.patch \
+	   file://rpm-lib-transaction.c-fix-file-conflicts-for-mips64-N32.patch \
+	   file://rpm-mongodb-sasl.patch \
+	   file://rpm-fix-parseEmbedded.patch \
+	   file://rpm-rpmio-headers.patch \
+	   file://rpm-python-restore-origin.patch \
+	   file://rpm-keccak-sse-intrin.patch \
+	   file://rpm-atomic-ops.patch \
+	   file://rpm-gnu-atomic.patch \
+	   file://rpm-tagname-type.patch \
+	   file://rpm-python-tagname.patch \
+	   file://rpm-python-AddErase.patch \
+	   file://rpm-rpmpgp-popt.patch \
+	   file://0001-Disable-__sync_add_and_fetch_8-on-nios2.patch \
+"
 
+# OE specific changes
+SRC_URI += " \
+	   file://rpm-log-auto-rm.patch \
+	   file://rpm-db-reduce.patch \
+	   file://rpm-autogen.patch \
+	   file://rpm-showrc.patch \
+	   file://rpm-fileclass.patch \
+	   file://rpm-scriptletexechelper.patch \
+	   file://rpmdeps-oecore.patch \
+	   file://rpm-no-perl-urpm.patch \
+	   file://rpm-macros.patch \
+	   file://rpm-lua.patch \
+	   file://rpm-ossp-uuid.patch \
+	   file://rpm-uuid-include.patch \
+	   file://rpm-pkgconfigdeps.patch \
+	   file://no-ldflags-in-pkgconfig.patch \
+	   file://dbconvert.patch \
+	   file://rpm-db_buffer_small.patch \
+	   file://rpm-py-init.patch \
+	   file://rpm-reloc-macros.patch \
+	   file://rpm-db5-or-db6.patch \
+	   file://rpm-db60.patch \
+	   file://rpmqv_cc_b_gone.patch \
+	   file://rpm-realpath.patch \
+	   file://rpm-check-rootpath-reasonableness.patch \
+	   file://rpm-macros.in-disable-external-key-server.patch \
+	   file://configure.ac-check-for-both-gpg2-and-gpg.patch \
+	   file://rpm-disable-auto-stack-protector.patch \
+	   file://popt-disable-auto-stack-protector.patch \
+	   file://rpm-syck-fix-gram.patch \
+	   file://rpm-rpmdb-grammar.patch \
+	   file://rpm-disable-blaketest.patch \
+	   file://rpm-autogen-force.patch \
+"
+
+SRC_URI_append_libc-musl = "\
+           file://0001-rpm-Fix-build-on-musl.patch \
+"
 # Uncomment the following line to enable platform score debugging
 # This is useful when identifying issues with Smart being unable
 # to process certain package feeds.
@@ -122,16 +160,87 @@
 
 acpaths = "-I ${S}/db/dist/aclocal -I ${S}/db/dist/aclocal_java"
 
+# The local distribution macro directory
+distromacrodir = "${libdir}/rpm/poky"
+
 # Specify the default rpm macros in terms of adjustable variables
-rpm_macros = "%{_usrlibrpm}/macros:%{_usrlibrpm}/poky/macros:%{_usrlibrpm}/poky/%{_target}/macros:%{_etcrpm}/macros.*:%{_etcrpm}/macros:%{_etcrpm}/%{_target}/macros:~/.oerpmmacros"
-rpm_macros_class-native = "%{_usrlibrpm}/macros:%{_usrlibrpm}/poky/macros:%{_usrlibrpm}/poky/%{_target}/macros:~/.oerpmmacros"
-rpm_macros_class-nativesdk = "%{_usrlibrpm}/macros:%{_usrlibrpm}/poky/macros:%{_usrlibrpm}/poky/%{_target}/macros:~/.oerpmmacros"
+rpm_macros = "%{_usrlibrpm}/macros:%{_usrlibrpm}/${DISTRO}/macros:%{_usrlibrpm}/${DISTRO}/%{_target}/macros:%{_etcrpm}/macros.*:%{_etcrpm}/macros:%{_etcrpm}/%{_target}/macros:~/.oerpmmacros"
+rpm_macros_class-native = "%{_usrlibrpm}/macros:%{_usrlibrpm}/${DISTRO}/macros:%{_usrlibrpm}/${DISTRO}/%{_target}/macros:~/.oerpmmacros"
+rpm_macros_class-nativesdk = "%{_usrlibrpm}/macros:%{_usrlibrpm}/${DISTRO}/macros:%{_usrlibrpm}/${DISTRO}/%{_target}/macros:~/.oerpmmacros"
 
 # sqlite lua tcl augeas nss gcrypt neon xz xar keyutils perl selinux
 
+# Set the digest algorithm used for verifying file integrity
+# If this value changes, and two different packages have different values
+# the "same file" validation (two packages have a non-conflict file)
+# will fail.  This may lead to upgrade problems.  You should treat this
+# value as a distribution wide setting, and only change it when you intend
+# a full system upgrade!
+#
+# Defined file digest algorithm values (note: not all are available!):
+#       1       MD5 (legacy RPM default)
+#       2       SHA1
+#       3       RIPEMD-160
+#       5       MD2
+#       6       TIGER-192
+#       8       SHA256
+#       9       SHA384
+#       10      SHA512
+#       11      SHA224
+#       104     MD4
+#       105     RIPEMD-128
+#       106     CRC-32
+#       107     ADLER-32
+#       108     CRC-64 (ECMA-182 polynomial, untested uint64_t problems)
+#       109     Jenkins lookup3.c hashlittle()
+#       111     RIPEMD-256
+#       112     RIPEMD-320
+#       188     BLAKE2B
+#       189     BLAKE2BP
+#       190     BLAKE2S
+#       191     BLAKE2SP
+RPM_FILE_DIGEST_ALGO ?= "1"
+
+# All packages build with RPM5 contain a non-repudiable signature.
+# The purpose of this signature is not to show authenticity of a package,
+# but instead act as a secondary package wide validation that shows it
+# wasn't damaged by accident in transport.  (When later you sign the package, 
+# this signature may or may not be replaced as there are three signature 
+# slots, one for DSA/RSA, one for ECSDA, and one reserved.)
+#
+# There is a known issue w/ RSA signatures that if they start with an 0x00
+# the signing and validation may fail.
+#
+# The following is the list of choices for the non-rpudiable signature
+# (note: not all of these are implemented):
+#       DSA             (default)
+#       RSA             (implies SHA1)
+#       ECDSA           (implies SHA256)
+#       DSA/SHA1
+#       DSA/SHA224
+#       DSA/SHA256
+#       DSA/SHA384
+#       DSA/SHA512
+#       RSA/SHA1
+#       RSA/SHA224
+#       RSA/SHA256
+#       RSA/SHA384
+#       RSA/SHA512
+#       ECDSA/SHA224    (using NIST P-224)
+#       ECDSA/SHA256    (using NIST P-256)
+#       ECDSA/SHA384    (using NIST P-384)
+#       ECDSA/SHA512    (using NIST P-521)
+RPM_SELF_SIGN_ALGO ?= "DSA"
+
 # Note: perl and sqlite w/o db specified does not currently work.
 #       tcl, augeas, nss, gcrypt, xar and keyutils support is untested.
-PACKAGECONFIG ??= "db bzip2 zlib beecrypt openssl libelf python"
+PACKAGECONFIG ??= "db bzip2 zlib popt openssl libelf python"
+
+# Note: switching to internal popt may not work, as it will generate
+# a shared library which will intentionally not be packaged.
+#
+# If you intend to use the internal version, additional work may be required.
+PACKAGECONFIG[popt] = "--with-popt=external,--with-popt=internal,popt,"
 
 PACKAGECONFIG[bzip2] = "--with-bzip2,--without-bzip2,bzip2,"
 PACKAGECONFIG[xz] = "--with-xz,--without-xz,xz,"
@@ -158,10 +267,17 @@
 
 PACKAGECONFIG[sqlite] = "--with-sqlite,--without-sqlite,sqlite3,"
 
-PACKAGECONFIG[beecrypt] = "--with-beecrypt=external,--without-beecrypt,beecrypt,"
-PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl,"
-PACKAGECONFIG[nss] = "--with-nss,--without-nss,nss,"
-PACKAGECONFIG[gcrypt] = "--with-gcrypt,--without-gcrypt,gcrypt,"
+# This switch simply disables external beecrypt, RPM5 always uses beecrypt
+# for base64 processing and various digest algorithms.
+# Beecrypt is only the preferred crypto engine if it's the only engine enabled.
+PACKAGECONFIG[beecrypt] = "--with-beecrypt=external,--with-beecrypt=internal,beecrypt,"
+
+# --with-usecrypto= setting defined the item as the preferred system
+# crypto engine, which will take priority over the included beecrypt
+PACKAGECONFIG[openssl] = "--with-openssl --with-usecrypto=openssl,--without-openssl,openssl,"
+PACKAGECONFIG[nss] = "--with-nss --with-usecrypto=nss,--without-nss,nss,"
+PACKAGECONFIG[gcrypt] = "--with-gcrypt --with-usecrypto=gcrypt,--without-gcrypt,gcrypt,"
+
 PACKAGECONFIG[keyutils] = "--with-keyutils,--without-keyutils,keyutils,"
 PACKAGECONFIG[libelf] = "--with-libelf,--without-libelf,elfutils,"
 
@@ -192,7 +308,6 @@
 		--with-uuid \
 		--with-attr \
 		--with-acl \
-		--with-popt=external \
 		--with-pthreads \
 		--without-cudf \
 		--without-ficl \
@@ -204,6 +319,7 @@
 		--without-gpsee \
 		--without-ruby \
 		--without-squirrel \
+		--without-sasl2 \
 		--with-build-extlibdep \
 		--with-build-maxextlibdep \
 		--without-valgrind \
@@ -223,7 +339,7 @@
 
 LDFLAGS_append_libc-uclibc = "-lrt -lpthread"
 
-PACKAGES = "${PN}-dbg ${PN} ${PN}-doc ${PN}-libs ${PN}-dev ${PN}-staticdev ${PN}-common ${PN}-build python-rpm-dbg python-rpm-staticdev python-rpm-dev python-rpm perl-module-rpm perl-module-rpm-dev ${PN}-locale"
+PACKAGES = "${PN}-dbg ${PN} ${PN}-doc ${PN}-libs ${PN}-dev ${PN}-staticdev ${PN}-common ${PN}-build python-rpm perl-module-rpm ${PN}-locale"
 
 SOLIBS = "5.4.so"
 
@@ -258,10 +374,6 @@
 		${bindir}/rpm2cpio.real \
 		"
 
-FILES_${PN}-dbg += "${libdir}/rpm/.debug \
-		${libdir}/rpm/bin/.debug \
-		"
-
 FILES_${PN}-common = "${bindir}/rpm2cpio \
 		${bindir}/gendiff \
 		${sysconfdir}/rpm \
@@ -345,25 +457,21 @@
 		${libdir}/rpm/vpkg-provides.sh \
 		${libdir}/rpm/vpkg-provides2.sh \
 		${libdir}/rpm/perfile_rpmdeps.sh \
+		${distromacrodir} \
 		"
 RDEPENDS_${PN} = "base-files run-postinsts"
 RDEPENDS_${PN}_class-native = ""
 RDEPENDS_${PN}_class-nativesdk = ""
 RDEPENDS_${PN}-build = "file bash perl"
 
-RDEPENDS_python-rpm = "${PN}"
+RDEPENDS_python-rpm = "${PN} python"
 
-FILES_python-rpm-dbg = "${libdir}/python*/site-packages/rpm/.debug/_*"
-FILES_python-rpm-dev = "${libdir}/python*/site-packages/rpm/*.la"
-FILES_python-rpm-staticdev = "${libdir}/python*/site-packages/rpm/*.a"
 FILES_python-rpm = "${libdir}/python*/site-packages/rpm"
+PROVIDES += "python-rpm"
 
 FILES_perl-module-rpm = "${libdir}/perl/*/* \
 		"
 
-FILES_perl-module-rpm-dev = "${prefix}/share/man/man3/RPM* \
-		"
-
 RDEPENDS_${PN}-dev += "bash"
 
 FILES_${PN}-dev = "${includedir}/rpm \
@@ -392,6 +500,7 @@
 		${libdir}/librpmmisc.a \
 		${libdir}/librpmbuild.a \
 		${libdir}/rpm/lib/liblua.a \
+		${libdir}/python*/site-packages/rpm/*.a \
 		"
 
 do_configure() {
@@ -412,12 +521,20 @@
 }
 
 do_install_append() {
+	# Configure -distribution wide- package crypto settings
+	# If these change, effectively all packages have to be upgraded!
+	sed -i -e 's,%_build_file_digest_algo.*,%_build_sign ${RPM_FILE_DIGEST_ALGO},' ${D}/${libdir}/rpm/macros.rpmbuild
+	sed -i -e 's,%_build_sign.*,%_build_sign ${RPM_SELF_SIGN_ALGO},' ${D}/${libdir}/rpm/macros.rpmbuild
+
 	sed -i -e 's,%__scriptlet_requires,#%%__scriptlet_requires,' ${D}/${libdir}/rpm/macros
 	sed -i -e 's,%__perl_provides,#%%__perl_provides,' ${D}/${libdir}/rpm/macros ${D}/${libdir}/rpm/macros.d/*
 	sed -i -e 's,%__perl_requires,#%%__perl_requires,' ${D}/${libdir}/rpm/macros ${D}/${libdir}/rpm/macros.d/*
 	sed -i -e 's,%_repackage_all_erasures[^_].*,%_repackage_all_erasures 0,' ${D}/${libdir}/rpm/macros
 	sed -i -e 's,^#%_openall_before_chroot.*,%_openall_before_chroot\t1,' ${D}/${libdir}/rpm/macros
 
+	# Enable MIPS64 N32 transactions.  (This is a no-op on non-MIPS targets.)
+	sed -i -e 's,%_transaction_color[^_].*,%_transaction_color 7,' ${D}/${libdir}/rpm/macros
+
 	# Enable Debian style arbitrary tags...
 	sed -i -e 's,%_arbitrary_tags[^_].*,%_arbitrary_tags %{_arbitrary_tags_debian},' ${D}/${libdir}/rpm/macros
 
@@ -452,16 +569,15 @@
 	rm -f ${D}/${mandir}/man1/lz*.1
 	rm -f ${D}/${libdir}/pkgconfig/liblzma*
 
-	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/*.{a,la}
-	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/rpm/*.{a,la}
+	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/*.a
+	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/*.la
+	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/rpm/*.a
+	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/rpm/*.la
 
 	#find ${D}/${libdir}/perl5 -type f -a \( -name perllocal.pod -o -name .packlist \
 	#	-o \( -name '*.bs' -a -empty \) \) -exec rm -f {} ';'
 	#find ${D}/${libdir}/perl5 -type d -depth -exec rmdir {} 2>/dev/null ';'
 
-	# We don't want the default macro set
-	rm -rf ${D}/${libdir}/rpm/{i[3456]86*,athlon*,pentium*,x86_64*,alpha*,sparc*,ia64*,ppc*,s390*,armv[34][lb]*,armv[345]*,mips*,noarch*}
-
 	rm -f ${D}/${libdir}/rpm/dbconvert.sh
 
 	rm -f ${D}/${libdir}/rpm/libsqldb.*
@@ -489,6 +605,91 @@
 
 }
 
+do_install_append_class-target() {
+	# Create and install distribution specific macros
+	mkdir -p ${D}/${distromacrodir}
+	cat << EOF > ${D}/${distromacrodir}/macros
+%_defaultdocdir		${docdir}
+
+%_prefix                ${prefix}
+%_exec_prefix           ${exec_prefix}
+%_datarootdir           ${datadir}
+%_bindir                ${bindir}
+%_sbindir               ${sbindir}
+%_libexecdir            %{_libdir}/%{name}
+%_datadir               ${datadir}
+%_sysconfdir            ${sysconfdir}
+%_sharedstatedir        ${sharedstatedir}
+%_localstatedir         ${localstatedir}
+%_lib                   lib
+%_libdir                %{_exec_prefix}/%{_lib}
+%_includedir            ${includedir}
+%_oldincludedir         ${oldincludedir}
+%_infodir               ${infodir}
+%_mandir                ${mandir}
+%_localedir             %{_libdir}/locale
+EOF
+
+	# Create and install multilib specific macros
+	${@multilib_rpmmacros(d)}
+}
+
+do_install_append_class-native () {
+	sed -i -e 's|^#!.*/usr/bin/python|#! /usr/bin/env nativepython|' ${D}/${libdir}/python2.7/site-packages/rpm/transaction.py
+}
+
+do_install_append_class-nativesdk () {
+	sed -i -e 's|^#!.*/usr/bin/python|#! /usr/bin/env python|' ${D}/${libdir}/python2.7/site-packages/rpm/transaction.py
+}
+
+def multilib_rpmmacros(d):
+    localdata = d.createCopy()
+    # We need to clear the TOOLCHAIN_OPTIONS (--sysroot)
+    localdata.delVar('TOOLCHAIN_OPTIONS')
+
+    # Set 'localdata' values to be consistent with 'd' values.
+    localdata.setVar('distromacrodir', d.getVar('distromacrodir', True))
+    localdata.setVar('WORKDIR', d.getVar('WORKDIR', True))
+
+    ret = gen_arch_macro(localdata)
+
+    variants = d.getVar("MULTILIB_VARIANTS", True) or ""
+    for item in variants.split():
+        # Load overrides from 'd' to avoid having to reset the value...
+        localdata = d.createCopy()
+        overrides = d.getVar("OVERRIDES", False) + ":virtclass-multilib-" + item
+        localdata.setVar("OVERRIDES", overrides)
+        localdata.setVar("MLPREFIX", item + "-")
+        bb.data.update_data(localdata)
+        ret += gen_arch_macro(localdata)
+    return ret
+
+def gen_arch_macro(d):
+    # Generate shell script to produce the file as part of do_install
+    val  = "mkdir -p ${D}/${distromacrodir}/${TARGET_ARCH}-${TARGET_OS}\n"
+    val += "cat << EOF > ${D}/${distromacrodir}/${TARGET_ARCH}-${TARGET_OS}/macros\n"
+    val += "%_lib               ${baselib}\n"
+    val += "%_libdir            ${libdir}\n"
+    val += "%_localedir         ${localedir}\n"
+    val += "\n"
+    val += "# Toolchain configuration\n"
+    val += "%TOOLCHAIN_OPTIONS  %{nil}\n"
+    val += "%__ar               ${@d.getVar('AR', True).replace('$','%')}\n"
+    val += "%__as               ${@d.getVar('AS', True).replace('$','%')}\n"
+    val += "%__cc               ${@d.getVar('CC', True).replace('$','%')}\n"
+    val += "%__cpp              ${@d.getVar('CPP', True).replace('$','%')}\n"
+    val += "%__cxx              ${@d.getVar('CXX', True).replace('$','%')}\n"
+    val += "%__ld               ${@d.getVar('LD', True).replace('$','%')}\n"
+    val += "%__nm               ${@d.getVar('NM', True).replace('$','%')}\n"
+    val += "%__objcopy          ${@d.getVar('OBJCOPY', True).replace('$','%')}\n"
+    val += "%__objdump          ${@d.getVar('OBJDUMP', True).replace('$','%')}\n"
+    val += "%__ranlib           ${@d.getVar('RANLIB', True).replace('$','%')}\n"
+    val += "%__strip            ${@d.getVar('STRIP', True).replace('$','%')}\n"
+    val += "EOF\n"
+    val += "\n"
+    return d.expand(val)
+
+
 add_native_wrapper() {
         create_wrapper ${D}/${bindir}/rpm \
 		RPM_USRLIBRPM='`dirname $''realpath`'/${@os.path.relpath(d.getVar('libdir', True), d.getVar('bindir', True))}/rpm \
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpm_5.4.14.bb b/yocto-poky/meta/recipes-devtools/rpm/rpm_5.4.16.bb
similarity index 63%
rename from yocto-poky/meta/recipes-devtools/rpm/rpm_5.4.14.bb
rename to yocto-poky/meta/recipes-devtools/rpm/rpm_5.4.16.bb
index 73b3734..cbdca88 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpm_5.4.14.bb
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpm_5.4.16.bb
@@ -5,8 +5,6 @@
 package consists of an archive of files along with information about \
 the package like its version, a description, etc."
 
-RECIPE_NO_UPDATE_REASON = "5.4.15 has a package database issue: http://lists.openembedded.org/pipermail/openembedded-core/2015-August/109187.html"
-
 SUMMARY_${PN}-libs = "Libraries for manipulating RPM packages"
 DESCRIPTION_${PN}-libs = "This package contains the RPM shared libraries."
 
@@ -37,83 +35,142 @@
 supplied by the RPM Package Manager libraries."
 
 HOMEPAGE = "http://rpm5.org/"
-LICENSE = "LGPLv2.1"
+LICENSE = "LGPLv2.1 & Apache-2.0"
 LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1"
+LIC_FILES_CHKSUM += "file://rpmio/mongo.c;begin=5;end=18;md5=d8327ba2c71664c059143e6d333b8901"
 
-DEPENDS = "libpcre attr acl popt ossp-uuid file byacc-native"
+# We must have gettext-native, we need gettextize, which may not be provided
+DEPENDS = "libpcre attr acl ossp-uuid file byacc-native gettext-native"
 DEPENDS_append_class-native = " file-replacement-native"
 
 # rpm2cpio is a shell script, which is part of the rpm src.rpm.  It is needed
 # in order to extract the distribution SRPM into a format we can extract...
-SRC_URI = "http://www.rpm5.org/files/rpm/rpm-5.4/rpm-5.4.14-0.20131024.src.rpm;extract=rpm-5.4.14.tar.gz \
-	   file://rpm-log-auto-rm.patch \
-	   file://rpm-db-reduce.patch \
+
+# There is no official 5.4.16 release yet, so start w/ 5.4.15 and patch it
+# based on CVS
+S = "${WORKDIR}/rpm-5.4.15"
+
+SRC_URI = "http://www.rpm5.org/files/rpm/rpm-5.4/rpm-5.4.15-0.20140824.src.rpm;name=srpm;extract=rpm-5.4.15.tar.gz \
+	   http://downloads.yoctoproject.org/releases/rpm5/rpm-5.4.15-to-5.4.16-20160225.patch.gz;name=rpm-patch \
+	   http://downloads.yoctoproject.org/releases/rpm5/syck-5.4.15-to-5.4.16-20160225.patch.gz;name=syck-patch \
+	   http://downloads.yoctoproject.org/releases/rpm5/beecrypt-5.4.15-to-5.4.16-20160225.patch.gz;name=beecrypt-patch \
+	   http://downloads.yoctoproject.org/releases/rpm5/lua-5.4.15-to-5.4.16-20160225.patch.gz;name=lua-patch \
 	   file://perfile_rpmdeps.sh \
-	   file://rpm-autogen.patch \
-	   file://rpm-libsql-fix.patch \
+	   file://pythondeps.sh \
+"
+
+SRC_URI[srpm.md5sum] = "d53782842ac11b3100a43fb2958c9bc0"
+SRC_URI[srpm.sha256sum] = "d4ae5e9ed5df8ab9931b660f491418d20ab5c4d72eb17ed9055b80b71ef6c4ee"
+
+SRC_URI[rpm-patch.md5sum] = "8b7deb1c9574d3d47ed8ba8c690fd8bf"
+SRC_URI[rpm-patch.sha256sum] = "1c1983d001b04eaa23eb2c8d9598b9d0899acb0a89f54a2d4c4e974086fd17a5"
+
+SRC_URI[syck-patch.md5sum] = "f31d7a32105a364688354419ec3559e4"
+SRC_URI[syck-patch.sha256sum] = "4dd1d04489206d8b5d1970f2a8d143a002f2895cefbe15d73459785096545e8a"
+
+SRC_URI[beecrypt-patch.md5sum] = "9e71ee3ccb0a52985a071dd250279132"
+SRC_URI[beecrypt-patch.sha256sum] ="df7c0708a7fab9bdf6d46194519b42e736f99cb0599dcc1c3c1bf1b228705cde"
+
+SRC_URI[lua-patch.md5sum] = "ca10d03d83b1fc1c31a0b50819534cd7"
+SRC_URI[lua-patch.sha256sum] = "6bde435cc827a7d4b2520e8f3e1c9bd2ca74375de0a4402aa99ef4d48eab9a7e"
+
+# Bug fixes
+SRC_URI += " \
 	   file://header-include-fix.patch \
+	   file://rpm-libsql-fix.patch \
 	   file://rpm-platform.patch \
-	   file://rpm-showrc.patch \
+	   file://rpm-platform2.patch \
 	   file://rpm-tools-mtree-LDFLAGS.patch \
-	   file://rpm-fileclass.patch \
 	   file://rpm-canonarch.patch \
 	   file://rpm-no-loopmsg.patch \
-	   file://rpm-scriptletexechelper.patch \
-	   file://pythondeps.sh \
-	   file://rpmdeps-oecore.patch \
 	   file://rpm-resolvedep.patch \
-	   file://rpm-no-perl-urpm.patch \
-	   file://rpm-macros.patch \
-	   file://rpm-lua.patch \
-	   file://rpm-ossp-uuid.patch \
 	   file://rpm-packageorigin.patch \
-	   file://rpm-pkgconfigdeps.patch \
 	   file://uclibc-support.patch \
 	   file://rpmatch.patch \
-	   file://fstack-protector-configure-check.patch \
-	   file://dbconvert.patch \
-	   file://rpm-uuid-include.patch \
 	   file://makefile-am-exec-hook.patch \
-	   file://rpm-db_buffer_small.patch \
-	   file://rpm-py-init.patch \
 	   file://python-rpm-rpmsense.patch \
-	   file://rpm-reloc-macros.patch \
-	   file://rpm-platform2.patch \
-	   file://rpm-remove-sykcparse-decl.patch \
 	   file://debugedit-segv.patch \
 	   file://debugedit-valid-file-to-fix-segment-fault.patch \
 	   file://rpm-platform-file-fix.patch \
 	   file://rpm-lsb-compatibility.patch \
 	   file://rpm-tag-generate-endian-conversion-fix.patch \
-	   file://verify-fix-broken-logic-for-ghost-avoidance-Mark-Hat.patch \
 	   file://rpm-hardlink-segfault-fix.patch \
 	   file://rpm-payload-use-hashed-inode.patch \
 	   file://rpm-fix-logio-cp.patch \
+	   file://0001-using-poptParseArgvString-to-parse-the-_gpg_check_pa.patch \
+	   file://rpm-opendb-before-verifyscript-to-avoid-null-point.patch \
+	   file://0001-define-EM_AARCH64.patch \
+	   file://rpm-rpmfc.c-fix-for-N32-MIPS64.patch \
+	   file://rpm-lib-transaction.c-fix-file-conflicts-for-mips64-N32.patch \
+	   file://rpm-mongodb-sasl.patch \
+	   file://rpm-fix-parseEmbedded.patch \
+	   file://rpm-rpmio-headers.patch \
+	   file://rpm-python-restore-origin.patch \
+	   file://rpm-keccak-sse-intrin.patch \
+	   file://rpm-atomic-ops.patch \
+	   file://rpm-gnu-atomic.patch \
+	   file://rpm-tagname-type.patch \
+	   file://rpm-python-tagname.patch \
+	   file://rpm-python-AddErase.patch \
+	   file://rpm-rpmpgp-popt.patch \
+	   file://rpm-fix-lua-tests-compilation-failure.patch \
+	   file://rpmqv.c-check-_gpg_passphrase-before-ask-for-input.patch \
+	   file://0001-Disable-__sync_add_and_fetch_8-on-nios2.patch \
+"
+
+# OE specific changes
+SRC_URI += " \
+	   file://rpm-log-auto-rm.patch \
+	   file://rpm-db-reduce.patch \
+	   file://rpm-autogen.patch \
+	   file://rpm-showrc.patch \
+	   file://rpm-fileclass.patch \
+	   file://rpm-scriptletexechelper.patch \
+	   file://rpmdeps-oecore.patch \
+	   file://rpm-no-perl-urpm.patch \
+	   file://rpm-macros.patch \
+	   file://rpm-lua.patch \
+	   file://rpm-ossp-uuid.patch \
+	   file://rpm-uuid-include.patch \
+	   file://rpm-pkgconfigdeps.patch \
+	   file://no-ldflags-in-pkgconfig.patch \
+	   file://dbconvert.patch \
+	   file://rpm-db_buffer_small.patch \
+	   file://rpm-py-init.patch \
+	   file://rpm-reloc-macros.patch \
 	   file://rpm-db5-or-db6.patch \
-	   file://rpm-disable-Wno-override-init.patch \
+	   file://rpm-db60.patch \
 	   file://rpmqv_cc_b_gone.patch \
 	   file://rpm-realpath.patch \
-	   file://0001-using-poptParseArgvString-to-parse-the-_gpg_check_pa.patch \
-	   file://no-ldflags-in-pkgconfig.patch \
-	   file://rpm-lua-fix-print.patch \
 	   file://rpm-check-rootpath-reasonableness.patch \
 	   file://rpm-macros.in-disable-external-key-server.patch \
-	   file://rpm-opendb-before-verifyscript-to-avoid-null-point.patch \
 	   file://configure.ac-check-for-both-gpg2-and-gpg.patch \
-	  "
+	   file://rpm-disable-auto-stack-protector.patch \
+	   file://popt-disable-auto-stack-protector.patch \
+	   file://rpm-syck-fix-gram.patch \
+	   file://rpm-rpmdb-grammar.patch \
+	   file://rpm-disable-blaketest.patch \
+	   file://rpm-autogen-force.patch \
+	   file://rpmdb-more-verbose-error-logging-in-rpmTempFile.patch \
+"
 
+SRC_URI_append_libc-musl = "\
+           file://0001-rpm-Fix-build-on-musl.patch \
+"
 # Uncomment the following line to enable platform score debugging
 # This is useful when identifying issues with Smart being unable
 # to process certain package feeds.
 #SRC_URI += "file://rpm-debug-platform.patch"
 
-SRC_URI[md5sum] = "25093d399a0b5d1342d24900a91b347d"
-SRC_URI[sha256sum] = "676e3ab41f72e3b504e04109cfb565a300742f56a7da084f202013b30eeae467"
+UPSTREAM_CHECK_REGEX = "rpm-(?P<pver>(\d+[\.\-_]*)+)-.*$"
 
 inherit autotools gettext
 
 acpaths = "-I ${S}/db/dist/aclocal -I ${S}/db/dist/aclocal_java"
 
+# The local distribution macro directory
+distromacrodir = "${libdir}/rpm/poky"
+
 # Specify the default rpm macros in terms of adjustable variables
 rpm_macros = "%{_usrlibrpm}/macros:%{_usrlibrpm}/${DISTRO}/macros:%{_usrlibrpm}/${DISTRO}/%{_target}/macros:%{_etcrpm}/macros.*:%{_etcrpm}/macros:%{_etcrpm}/%{_target}/macros:~/.oerpmmacros"
 rpm_macros_class-native = "%{_usrlibrpm}/macros:%{_usrlibrpm}/${DISTRO}/macros:%{_usrlibrpm}/${DISTRO}/%{_target}/macros:~/.oerpmmacros"
@@ -121,9 +178,77 @@
 
 # sqlite lua tcl augeas nss gcrypt neon xz xar keyutils perl selinux
 
+# Set the digest algorithm used for verifying file integrity
+# If this value changes, and two different packages have different values
+# the "same file" validation (two packages have a non-conflict file)
+# will fail.  This may lead to upgrade problems.  You should treat this
+# value as a distribution wide setting, and only change it when you intend
+# a full system upgrade!
+#
+# Defined file digest algorithm values (note: not all are available!):
+#       1       MD5 (legacy RPM default)
+#       2       SHA1
+#       3       RIPEMD-160
+#       5       MD2
+#       6       TIGER-192
+#       8       SHA256
+#       9       SHA384
+#       10      SHA512
+#       11      SHA224
+#       104     MD4
+#       105     RIPEMD-128
+#       106     CRC-32
+#       107     ADLER-32
+#       108     CRC-64 (ECMA-182 polynomial, untested uint64_t problems)
+#       109     Jenkins lookup3.c hashlittle()
+#       111     RIPEMD-256
+#       112     RIPEMD-320
+#       188     BLAKE2B
+#       189     BLAKE2BP
+#       190     BLAKE2S
+#       191     BLAKE2SP
+RPM_FILE_DIGEST_ALGO ?= "1"
+
+# All packages build with RPM5 contain a non-repudiable signature.
+# The purpose of this signature is not to show authenticity of a package,
+# but instead act as a secondary package wide validation that shows it
+# wasn't damaged by accident in transport.  (When later you sign the package, 
+# this signature may or may not be replaced as there are three signature 
+# slots, one for DSA/RSA, one for ECSDA, and one reserved.)
+#
+# There is a known issue w/ RSA signatures that if they start with an 0x00
+# the signing and validation may fail.
+#
+# The following is the list of choices for the non-rpudiable signature
+# (note: not all of these are implemented):
+#       DSA             (default)
+#       RSA             (implies SHA1)
+#       ECDSA           (implies SHA256)
+#       DSA/SHA1
+#       DSA/SHA224
+#       DSA/SHA256
+#       DSA/SHA384
+#       DSA/SHA512
+#       RSA/SHA1
+#       RSA/SHA224
+#       RSA/SHA256
+#       RSA/SHA384
+#       RSA/SHA512
+#       ECDSA/SHA224    (using NIST P-224)
+#       ECDSA/SHA256    (using NIST P-256)
+#       ECDSA/SHA384    (using NIST P-384)
+#       ECDSA/SHA512    (using NIST P-521)
+RPM_SELF_SIGN_ALGO ?= "DSA"
+
 # Note: perl and sqlite w/o db specified does not currently work.
 #       tcl, augeas, nss, gcrypt, xar and keyutils support is untested.
-PACKAGECONFIG ??= "db bzip2 zlib beecrypt openssl libelf python"
+PACKAGECONFIG ??= "db bzip2 zlib popt openssl libelf python"
+
+# Note: switching to internal popt may not work, as it will generate
+# a shared library which will intentionally not be packaged.
+#
+# If you intend to use the internal version, additional work may be required.
+PACKAGECONFIG[popt] = "--with-popt=external,--with-popt=internal,popt,"
 
 PACKAGECONFIG[bzip2] = "--with-bzip2,--without-bzip2,bzip2,"
 PACKAGECONFIG[xz] = "--with-xz,--without-xz,xz,"
@@ -150,10 +275,17 @@
 
 PACKAGECONFIG[sqlite] = "--with-sqlite,--without-sqlite,sqlite3,"
 
-PACKAGECONFIG[beecrypt] = "--with-beecrypt=external,--without-beecrypt,beecrypt,"
-PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl,"
-PACKAGECONFIG[nss] = "--with-nss,--without-nss,nss,"
-PACKAGECONFIG[gcrypt] = "--with-gcrypt,--without-gcrypt,gcrypt,"
+# This switch simply disables external beecrypt, RPM5 always uses beecrypt
+# for base64 processing and various digest algorithms.
+# Beecrypt is only the preferred crypto engine if it's the only engine enabled.
+PACKAGECONFIG[beecrypt] = "--with-beecrypt=external,--with-beecrypt=internal,beecrypt,"
+
+# --with-usecrypto= setting defined the item as the preferred system
+# crypto engine, which will take priority over the included beecrypt
+PACKAGECONFIG[openssl] = "--with-openssl --with-usecrypto=openssl,--without-openssl,openssl,"
+PACKAGECONFIG[nss] = "--with-nss --with-usecrypto=nss,--without-nss,nss,"
+PACKAGECONFIG[gcrypt] = "--with-gcrypt --with-usecrypto=gcrypt,--without-gcrypt,gcrypt,"
+
 PACKAGECONFIG[keyutils] = "--with-keyutils,--without-keyutils,keyutils,"
 PACKAGECONFIG[libelf] = "--with-libelf,--without-libelf,elfutils,"
 
@@ -184,7 +316,6 @@
 		--with-uuid \
 		--with-attr \
 		--with-acl \
-		--with-popt=external \
 		--with-pthreads \
 		--without-cudf \
 		--without-ficl \
@@ -196,6 +327,7 @@
 		--without-gpsee \
 		--without-ruby \
 		--without-squirrel \
+		--without-sasl2 \
 		--with-build-extlibdep \
 		--with-build-maxextlibdep \
 		--without-valgrind \
@@ -250,11 +382,6 @@
 		${bindir}/rpm2cpio.real \
 		"
 
-FILES_${PN}-dbg += "${libdir}/rpm/.debug \
-		${libdir}/rpm/bin/.debug \
-		${libdir}/python*/site-packages/rpm/.debug/_* \
-		"
-
 FILES_${PN}-common = "${bindir}/rpm2cpio \
 		${bindir}/gendiff \
 		${sysconfdir}/rpm \
@@ -338,13 +465,14 @@
 		${libdir}/rpm/vpkg-provides.sh \
 		${libdir}/rpm/vpkg-provides2.sh \
 		${libdir}/rpm/perfile_rpmdeps.sh \
+		${distromacrodir} \
 		"
 RDEPENDS_${PN} = "base-files run-postinsts"
 RDEPENDS_${PN}_class-native = ""
 RDEPENDS_${PN}_class-nativesdk = ""
 RDEPENDS_${PN}-build = "file bash perl"
 
-RDEPENDS_python-rpm = "${PN}"
+RDEPENDS_python-rpm = "${PN} python"
 
 FILES_python-rpm = "${libdir}/python*/site-packages/rpm"
 PROVIDES += "python-rpm"
@@ -370,6 +498,7 @@
 		${libdir}/rpm/lib/liblua.la \
 		${libdir}/pkgconfig/rpm.pc \
 		${libdir}/rpm/rpmdb_loadcvt \
+		${libdir}/rpm/include \
 		"
 
 FILES_${PN}-staticdev = " \
@@ -401,12 +530,20 @@
 }
 
 do_install_append() {
+	# Configure -distribution wide- package crypto settings
+	# If these change, effectively all packages have to be upgraded!
+	sed -i -e 's,%_build_file_digest_algo.*,%_build_sign ${RPM_FILE_DIGEST_ALGO},' ${D}/${libdir}/rpm/macros.rpmbuild
+	sed -i -e 's,%_build_sign.*,%_build_sign ${RPM_SELF_SIGN_ALGO},' ${D}/${libdir}/rpm/macros.rpmbuild
+
 	sed -i -e 's,%__scriptlet_requires,#%%__scriptlet_requires,' ${D}/${libdir}/rpm/macros
 	sed -i -e 's,%__perl_provides,#%%__perl_provides,' ${D}/${libdir}/rpm/macros ${D}/${libdir}/rpm/macros.d/*
 	sed -i -e 's,%__perl_requires,#%%__perl_requires,' ${D}/${libdir}/rpm/macros ${D}/${libdir}/rpm/macros.d/*
 	sed -i -e 's,%_repackage_all_erasures[^_].*,%_repackage_all_erasures 0,' ${D}/${libdir}/rpm/macros
 	sed -i -e 's,^#%_openall_before_chroot.*,%_openall_before_chroot\t1,' ${D}/${libdir}/rpm/macros
 
+	# Enable MIPS64 N32 transactions.  (This is a no-op on non-MIPS targets.)
+	sed -i -e 's,%_transaction_color[^_].*,%_transaction_color 7,' ${D}/${libdir}/rpm/macros
+
 	# Enable Debian style arbitrary tags...
 	sed -i -e 's,%_arbitrary_tags[^_].*,%_arbitrary_tags %{_arbitrary_tags_debian},' ${D}/${libdir}/rpm/macros
 
@@ -441,16 +578,15 @@
 	rm -f ${D}/${mandir}/man1/lz*.1
 	rm -f ${D}/${libdir}/pkgconfig/liblzma*
 
-	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/*.{a,la}
-	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/rpm/*.{a,la}
+	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/*.a
+	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/*.la
+	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/rpm/*.a
+	rm -f ${D}/${libdir}/python%{with_python_version}/site-packages/rpm/*.la
 
 	#find ${D}/${libdir}/perl5 -type f -a \( -name perllocal.pod -o -name .packlist \
 	#	-o \( -name '*.bs' -a -empty \) \) -exec rm -f {} ';'
 	#find ${D}/${libdir}/perl5 -type d -depth -exec rmdir {} 2>/dev/null ';'
 
-	# We don't want the default macro set
-	rm -rf ${D}/${libdir}/rpm/{i[3456]86*,athlon*,pentium*,x86_64*,alpha*,sparc*,ia64*,ppc*,s390*,armv[34][lb]*,armv[345]*,mips*,noarch*}
-
 	rm -f ${D}/${libdir}/rpm/dbconvert.sh
 
 	rm -f ${D}/${libdir}/rpm/libsqldb.*
@@ -478,6 +614,91 @@
 
 }
 
+do_install_append_class-target() {
+	# Create and install distribution specific macros
+	mkdir -p ${D}/${distromacrodir}
+	cat << EOF > ${D}/${distromacrodir}/macros
+%_defaultdocdir		${docdir}
+
+%_prefix                ${prefix}
+%_exec_prefix           ${exec_prefix}
+%_datarootdir           ${datadir}
+%_bindir                ${bindir}
+%_sbindir               ${sbindir}
+%_libexecdir            %{_libdir}/%{name}
+%_datadir               ${datadir}
+%_sysconfdir            ${sysconfdir}
+%_sharedstatedir        ${sharedstatedir}
+%_localstatedir         ${localstatedir}
+%_lib                   lib
+%_libdir                %{_exec_prefix}/%{_lib}
+%_includedir            ${includedir}
+%_oldincludedir         ${oldincludedir}
+%_infodir               ${infodir}
+%_mandir                ${mandir}
+%_localedir             %{_libdir}/locale
+EOF
+
+	# Create and install multilib specific macros
+	${@multilib_rpmmacros(d)}
+}
+
+do_install_append_class-native () {
+	sed -i -e 's|^#!.*/usr/bin/python|#! /usr/bin/env nativepython|' ${D}/${libdir}/python2.7/site-packages/rpm/transaction.py
+}
+
+do_install_append_class-nativesdk () {
+	sed -i -e 's|^#!.*/usr/bin/python|#! /usr/bin/env python|' ${D}/${libdir}/python2.7/site-packages/rpm/transaction.py
+}
+
+def multilib_rpmmacros(d):
+    localdata = d.createCopy()
+    # We need to clear the TOOLCHAIN_OPTIONS (--sysroot)
+    localdata.delVar('TOOLCHAIN_OPTIONS')
+
+    # Set 'localdata' values to be consistent with 'd' values.
+    localdata.setVar('distromacrodir', d.getVar('distromacrodir', True))
+    localdata.setVar('WORKDIR', d.getVar('WORKDIR', True))
+
+    ret = gen_arch_macro(localdata)
+
+    variants = d.getVar("MULTILIB_VARIANTS", True) or ""
+    for item in variants.split():
+        # Load overrides from 'd' to avoid having to reset the value...
+        localdata = d.createCopy()
+        overrides = d.getVar("OVERRIDES", False) + ":virtclass-multilib-" + item
+        localdata.setVar("OVERRIDES", overrides)
+        localdata.setVar("MLPREFIX", item + "-")
+        bb.data.update_data(localdata)
+        ret += gen_arch_macro(localdata)
+    return ret
+
+def gen_arch_macro(d):
+    # Generate shell script to produce the file as part of do_install
+    val  = "mkdir -p ${D}/${distromacrodir}/${TARGET_ARCH}-${TARGET_OS}\n"
+    val += "cat << EOF > ${D}/${distromacrodir}/${TARGET_ARCH}-${TARGET_OS}/macros\n"
+    val += "%_lib               ${baselib}\n"
+    val += "%_libdir            ${libdir}\n"
+    val += "%_localedir         ${localedir}\n"
+    val += "\n"
+    val += "# Toolchain configuration\n"
+    val += "%TOOLCHAIN_OPTIONS  %{nil}\n"
+    val += "%__ar               ${@d.getVar('AR', True).replace('$','%')}\n"
+    val += "%__as               ${@d.getVar('AS', True).replace('$','%')}\n"
+    val += "%__cc               ${@d.getVar('CC', True).replace('$','%')}\n"
+    val += "%__cpp              ${@d.getVar('CPP', True).replace('$','%')}\n"
+    val += "%__cxx              ${@d.getVar('CXX', True).replace('$','%')}\n"
+    val += "%__ld               ${@d.getVar('LD', True).replace('$','%')}\n"
+    val += "%__nm               ${@d.getVar('NM', True).replace('$','%')}\n"
+    val += "%__objcopy          ${@d.getVar('OBJCOPY', True).replace('$','%')}\n"
+    val += "%__objdump          ${@d.getVar('OBJDUMP', True).replace('$','%')}\n"
+    val += "%__ranlib           ${@d.getVar('RANLIB', True).replace('$','%')}\n"
+    val += "%__strip            ${@d.getVar('STRIP', True).replace('$','%')}\n"
+    val += "EOF\n"
+    val += "\n"
+    return d.expand(val)
+
+
 add_native_wrapper() {
         create_wrapper ${D}/${bindir}/rpm \
 		RPM_USRLIBRPM='`dirname $''realpath`'/${@os.path.relpath(d.getVar('libdir', True), d.getVar('bindir', True))}/rpm \
diff --git a/yocto-poky/meta/recipes-devtools/rpm/rpmresolve_1.0.bb b/yocto-poky/meta/recipes-devtools/rpm/rpmresolve_1.0.bb
index 04a55fd..0c13a67 100644
--- a/yocto-poky/meta/recipes-devtools/rpm/rpmresolve_1.0.bb
+++ b/yocto-poky/meta/recipes-devtools/rpm/rpmresolve_1.0.bb
@@ -11,7 +11,7 @@
 S = "${WORKDIR}"
 
 do_compile() {
-	${CC} ${CFLAGS} -ggdb -I${STAGING_INCDIR}/rpm ${LDFLAGS} rpmresolve.c -o rpmresolve -lrpmbuild -lrpm -lrpmio -lrpmdb -lpopt
+	${CC} ${CFLAGS} -ggdb -I${STAGING_INCDIR}/rpm ${LDFLAGS} rpmresolve.c -o rpmresolve -lrpmbuild -lrpm -lrpmio -lrpmdb
 }
 
 do_install() {
diff --git a/yocto-poky/meta/recipes-devtools/rsync/files/acinclude.m4 b/yocto-poky/meta/recipes-devtools/rsync/files/acinclude.m4
deleted file mode 100644
index 735b41d..0000000
--- a/yocto-poky/meta/recipes-devtools/rsync/files/acinclude.m4
+++ /dev/null
@@ -1,95 +0,0 @@
-dnl verbatim renamed from aclocal.m4 in rsync_3.0.7
-dnl 07/06/2010 - qhe
-
-dnl AC_VALIDATE_CACHE_SYSTEM_TYPE[(cmd)]
-dnl if the cache file is inconsistent with the current host,
-dnl target and build system types, execute CMD or print a default
-dnl error message.
-AC_DEFUN(AC_VALIDATE_CACHE_SYSTEM_TYPE, [
-    AC_REQUIRE([AC_CANONICAL_SYSTEM])
-    AC_MSG_CHECKING([config.cache system type])
-    if { test x"${ac_cv_host_system_type+set}" = x"set" &&
-         test x"$ac_cv_host_system_type" != x"$host"; } ||
-       { test x"${ac_cv_build_system_type+set}" = x"set" &&
-         test x"$ac_cv_build_system_type" != x"$build"; } ||
-       { test x"${ac_cv_target_system_type+set}" = x"set" &&
-         test x"$ac_cv_target_system_type" != x"$target"; }; then
-	AC_MSG_RESULT([different])
-	ifelse($#, 1, [$1],
-		[AC_MSG_ERROR(["you must remove config.cache and restart configure"])])
-    else
-	AC_MSG_RESULT([same])
-    fi
-    ac_cv_host_system_type="$host"
-    ac_cv_build_system_type="$build"
-    ac_cv_target_system_type="$target"
-])
-
-dnl Check for socklen_t: historically on BSD it is an int, and in
-dnl POSIX 1g it is a type of its own, but some platforms use different
-dnl types for the argument to getsockopt, getpeername, etc.  So we
-dnl have to test to find something that will work.
-
-dnl This is no good, because passing the wrong pointer on C compilers is
-dnl likely to only generate a warning, not an error.  We don't call this at
-dnl the moment.
-
-AC_DEFUN([TYPE_SOCKLEN_T],
-[
-   AC_CHECK_TYPE([socklen_t], ,[
-      AC_MSG_CHECKING([for socklen_t equivalent])
-      AC_CACHE_VAL([rsync_cv_socklen_t_equiv],
-      [
-         # Systems have either "struct sockaddr *" or
-         # "void *" as the second argument to getpeername
-         rsync_cv_socklen_t_equiv=
-         for arg2 in "struct sockaddr" void; do
-            for t in int size_t unsigned long "unsigned long"; do
-               AC_TRY_COMPILE([
-#include <sys/types.h>
-#include <sys/socket.h>
-
-                  int getpeername (int, $arg2 *, $t *);
-               ],[
-                  $t len;
-                  getpeername(0,0,&len);
-               ],[
-                  rsync_cv_socklen_t_equiv="$t"
-                  break
-               ])
-            done
-         done
-
-         if test "x$rsync_cv_socklen_t_equiv" = x; then
-            AC_MSG_ERROR([Cannot find a type to use in place of socklen_t])
-         fi
-      ])
-      AC_MSG_RESULT($rsync_cv_socklen_t_equiv)
-      AC_DEFINE_UNQUOTED(socklen_t, $rsync_cv_socklen_t_equiv,
-			[type to use in place of socklen_t if not defined])],
-      [#include <sys/types.h>
-#include <sys/socket.h>])
-])
-
-dnl AC_HAVE_TYPE(TYPE,INCLUDES)
-AC_DEFUN([AC_HAVE_TYPE], [
-AC_REQUIRE([AC_HEADER_STDC])
-cv=`echo "$1" | sed 'y%./+- %__p__%'`
-AC_MSG_CHECKING(for $1)
-AC_CACHE_VAL([ac_cv_type_$cv],
-AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
-AC_INCLUDES_DEFAULT
-$2]],
-[[$1 foo;]])],
-[eval "ac_cv_type_$cv=yes"],
-[eval "ac_cv_type_$cv=no"]))dnl
-ac_foo=`eval echo \\$ac_cv_type_$cv`
-AC_MSG_RESULT($ac_foo)
-if test "$ac_foo" = yes; then
-  ac_tr_hdr=HAVE_`echo $1 | sed 'y%abcdefghijklmnopqrstuvwxyz./- %ABCDEFGHIJKLMNOPQRSTUVWXYZ____%'`
-if false; then
-	AC_CHECK_TYPES($1)
-fi
-  AC_DEFINE_UNQUOTED($ac_tr_hdr, 1, [Define if you have type `$1'])
-fi
-])
diff --git a/yocto-poky/meta/recipes-devtools/rsync/files/makefile-no-rebuild.patch b/yocto-poky/meta/recipes-devtools/rsync/files/makefile-no-rebuild.patch
new file mode 100644
index 0000000..3d27fe7
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rsync/files/makefile-no-rebuild.patch
@@ -0,0 +1,69 @@
+Remove the Makefile rules to reinvoke autoconf, they're not out-of-tree safe and
+generally overcomplicated, and we ensure that autoreconf is invoked if required.
+
+Upstream-Status: Inappropriate
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+diff --git a/Makefile.in b/Makefile.in
+index 151247d..8f3fdb6 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -141,58 +141,6 @@ gen: conf proto.h man
+ gensend: gen
+ 	rsync -aivzc $(GENFILES) $${SAMBA_HOST-samba.org}:/home/ftp/pub/rsync/generated-files/
+ 
+-conf:
+-	cd $(srcdir) && $(MAKE) -f prepare-source.mak conf
+-
+-aclocal.m4: $(srcdir)/m4/*.m4
+-	aclocal -I $(srcdir)/m4
+-
+-configure.sh config.h.in: configure.ac aclocal.m4
+-	@if test -f configure.sh; then cp -p configure.sh configure.sh.old; else touch configure.sh.old; fi
+-	@if test -f config.h.in; then cp -p config.h.in config.h.in.old; else touch config.h.in.old; fi
+-	autoconf -o configure.sh
+-	autoheader && touch config.h.in
+-	@if diff configure.sh configure.sh.old >/dev/null 2>&1; then \
+-	    echo "configure.sh is unchanged."; \
+-	    rm configure.sh.old; \
+-	else \
+-	    echo "configure.sh has CHANGED."; \
+-	fi
+-	@if diff config.h.in config.h.in.old >/dev/null 2>&1; then \
+-	    echo "config.h.in is unchanged."; \
+-	    rm config.h.in.old; \
+-	else \
+-	    echo "config.h.in has CHANGED."; \
+-	fi
+-	@if test -f configure.sh.old -o -f config.h.in.old; then \
+-	    if test "$(MAKECMDGOALS)" = reconfigure; then \
+-		echo 'Continuing with "make reconfigure".'; \
+-	    else \
+-		echo 'You may need to run:'; \
+-		echo '  make reconfigure'; \
+-		exit 1; \
+-	    fi \
+-	fi
+-
+-reconfigure: configure.sh
+-	./config.status --recheck
+-	./config.status
+-
+-Makefile: Makefile.in config.status configure.sh config.h.in
+-	@if test -f Makefile; then cp -p Makefile Makefile.old; else touch Makefile.old; fi
+-	@./config.status
+-	@if diff Makefile Makefile.old >/dev/null 2>&1; then \
+-	    echo "Makefile is unchanged."; \
+-	    rm Makefile.old; \
+-	else \
+-	    if test "$(MAKECMDGOALS)" = reconfigure; then \
+-		echo 'Continuing with "make reconfigure".'; \
+-	    else \
+-		echo "Makefile updated -- rerun your make command."; \
+-		exit 1; \
+-	    fi \
+-	fi
+-
+ rsync-ssl: $(srcdir)/rsync-ssl.in Makefile
+ 	sed 's;\@bindir\@;$(bindir);g' <$(srcdir)/rsync-ssl.in >rsync-ssl
+ 	@chmod +x rsync-ssl
diff --git a/yocto-poky/meta/recipes-devtools/rsync/rsync-2.6.9/rsync-2.6.9-fname-obo.patch b/yocto-poky/meta/recipes-devtools/rsync/rsync-2.6.9/rsync-2.6.9-fname-obo.patch
index f054452..bea325e 100644
--- a/yocto-poky/meta/recipes-devtools/rsync/rsync-2.6.9/rsync-2.6.9-fname-obo.patch
+++ b/yocto-poky/meta/recipes-devtools/rsync/rsync-2.6.9/rsync-2.6.9-fname-obo.patch
@@ -1,4 +1,5 @@
 Upstream-Status: Backport [ The patch is rsync-2.6.9 specific ]
+CVE: CVE-2007-4091
 
 The patch is from https://issues.rpath.com/browse/RPL-1647 and is used to
 address http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2007-4091
diff --git a/yocto-poky/meta/recipes-devtools/rsync/rsync-3.1.1/0001-Complain-if-an-inc-recursive-path-is-not-right-for-i.patch b/yocto-poky/meta/recipes-devtools/rsync/rsync-3.1.1/0001-Complain-if-an-inc-recursive-path-is-not-right-for-i.patch
deleted file mode 100644
index 5ece542..0000000
--- a/yocto-poky/meta/recipes-devtools/rsync/rsync-3.1.1/0001-Complain-if-an-inc-recursive-path-is-not-right-for-i.patch
+++ /dev/null
@@ -1,135 +0,0 @@
-From 962f8b90045ab331fc04c9e65f80f1a53e68243b Mon Sep 17 00:00:00 2001
-From: Wayne Davison <wayned@samba.org>
-Date: Wed, 31 Dec 2014 12:41:03 -0800
-Subject: [PATCH] Complain if an inc-recursive path is not right for its dir.
- This ensures that a malicious sender can't use a just-sent symlink as a
- trasnfer path.
-
-Upstream-Status: BackPort
-
-Fix the CVE-2014-9512, rsync 3.1.1 allows remote attackers to write to arbitrary
-files via a symlink attack on a file in the synchronization path.
-
-BackPort and fix this patch to make it able to apply to source code
-
-Signed-off-by: Roy Li <rongqing.li@windriver.com>
----
- flist.c | 22 ++++++++++++++++++++--
- io.c    |  2 +-
- main.c  |  4 ++--
- rsync.c |  2 +-
- proto.h | 2 +-
- 6 files changed, 31 insertions(+), 8 deletions(-)
-
-diff --git a/flist.c b/flist.c
-index c24672e..92e4b65 100644
---- a/flist.c
-+++ b/flist.c
-@@ -2435,8 +2435,9 @@ struct file_list *send_file_list(int f, int argc, char *argv[])
- 	return flist;
- }
- 
--struct file_list *recv_file_list(int f)
-+struct file_list *recv_file_list(int f, int dir_ndx)
- {
-+	const char *good_dirname = NULL;
- 	struct file_list *flist;
- 	int dstart, flags;
- 	int64 start_read;
-@@ -2492,6 +2493,23 @@ struct file_list *recv_file_list(int f)
- 		flist_expand(flist, 1);
- 		file = recv_file_entry(f, flist, flags);
- 
-+		if (inc_recurse) {
-+			static const char empty_dir[] = "\0";
-+			const char *cur_dir = file->dirname ? file->dirname : empty_dir;
-+			if (relative_paths && *cur_dir == '/')
-+				cur_dir++;
-+			if (cur_dir != good_dirname) {
-+				const char *d = dir_ndx >= 0 ? f_name(dir_flist->files[dir_ndx], NULL) : empty_dir;
-+				if (strcmp(cur_dir, d) != 0) {
-+					rprintf(FERROR,
-+						"ABORTING due to invalid dir prefix from sender: %s (should be: %s)\n",
-+						cur_dir, d);
-+					exit_cleanup(RERR_PROTOCOL);
-+				}
-+				good_dirname = cur_dir;
-+			}
-+		}
-+
- 		if (S_ISREG(file->mode)) {
- 			/* Already counted */
- 		} else if (S_ISDIR(file->mode)) {
-@@ -2615,7 +2633,7 @@ void recv_additional_file_list(int f)
- 			rprintf(FINFO, "[%s] receiving flist for dir %d\n",
- 				who_am_i(), ndx);
- 		}
--		flist = recv_file_list(f);
-+		flist = recv_file_list(f, ndx);
- 		flist->parent_ndx = ndx;
- 	}
- }
-diff --git a/io.c b/io.c
-index b9a9bd0..a868fa9 100644
---- a/io.c
-+++ b/io.c
-@@ -1685,7 +1685,7 @@ void wait_for_receiver(void)
- 				rprintf(FINFO, "[%s] receiving flist for dir %d\n",
- 					who_am_i(), ndx);
- 			}
--			flist = recv_file_list(iobuf.in_fd);
-+			flist = recv_file_list(iobuf.in_fd, ndx);
- 			flist->parent_ndx = ndx;
- #ifdef SUPPORT_HARD_LINKS
- 			if (preserve_hard_links)
-diff --git a/main.c b/main.c
-index e7a13f7..713b818 100644
---- a/main.c
-+++ b/main.c
-@@ -1009,7 +1009,7 @@ static void do_server_recv(int f_in, int f_out, int argc, char *argv[])
- 		filesfrom_fd = -1;
- 	}
- 
--	flist = recv_file_list(f_in);
-+	flist = recv_file_list(f_in, -1);
- 	if (!flist) {
- 		rprintf(FERROR,"server_recv: recv_file_list error\n");
- 		exit_cleanup(RERR_FILESELECT);
-@@ -1183,7 +1183,7 @@ int client_run(int f_in, int f_out, pid_t pid, int argc, char *argv[])
- 
- 	if (write_batch && !am_server)
- 		start_write_batch(f_in);
--	flist = recv_file_list(f_in);
-+	flist = recv_file_list(f_in, -1);
- 	if (inc_recurse && file_total == 1)
- 		recv_additional_file_list(f_in);
- 
-diff --git a/rsync.c b/rsync.c
-index 68ff6b1..c3ecc51 100644
---- a/rsync.c
-+++ b/rsync.c
-@@ -364,7 +364,7 @@ int read_ndx_and_attrs(int f_in, int f_out, int *iflag_ptr, uchar *type_ptr,
- 		}
- 		/* Send all the data we read for this flist to the generator. */
- 		start_flist_forward(ndx);
--		flist = recv_file_list(f_in);
-+		flist = recv_file_list(f_in, ndx);
- 		flist->parent_ndx = ndx;
- 		stop_flist_forward();
- 	}
-diff --git a/proto.h b/proto.h
-index 22fc539..247c558 100644
---- a/proto.h
-+++ b/proto.h
-@@ -89,7 +89,7 @@ struct file_struct *make_file(const char *fname, struct file_list *flist,
- void unmake_file(struct file_struct *file);
- void send_extra_file_list(int f, int at_least);
- struct file_list *send_file_list(int f, int argc, char *argv[]);
--struct file_list *recv_file_list(int f);
-+struct file_list *recv_file_list(int f, int dir_ndx);
- void recv_additional_file_list(int f);
- int flist_find(struct file_list *flist, struct file_struct *f);
- int flist_find_ignore_dirness(struct file_list *flist, struct file_struct *f);
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/rsync/rsync-3.1.1/rsync.git-eac858085.patch b/yocto-poky/meta/recipes-devtools/rsync/rsync-3.1.1/rsync.git-eac858085.patch
deleted file mode 100644
index 1fcac49..0000000
--- a/yocto-poky/meta/recipes-devtools/rsync/rsync-3.1.1/rsync.git-eac858085.patch
+++ /dev/null
@@ -1,101 +0,0 @@
-From eac858085e3ac94ec0ab5061d11f52652c90a869 Mon Sep 17 00:00:00 2001
-From: Wayne Davison <wayned@samba.org>
-Date: Mon, 11 May 2015 12:36:20 -0700
-Subject: [PATCH 1/1] Add compat flag to allow proper seed checksum order.
- Fixes the equivalent of librsync's CVE-2014-8242 issue.
-
-Upstream-Status: Backport
-
-Signed-off-by: Roy Li <rongqing.li@windriver.com>
----
- checksum.c | 17 +++++++++++++----
- compat.c   |  5 +++++
- options.c  |  1 +
- 3 files changed, 19 insertions(+), 4 deletions(-)
-
-diff --git a/checksum.c b/checksum.c
-index a1c2aa2..933b514 100644
---- a/checksum.c
-+++ b/checksum.c
-@@ -23,6 +23,7 @@
- 
- extern int checksum_seed;
- extern int protocol_version;
-+extern int proper_seed_order;
- 
- /*
-   a simple 32 bit checksum that can be upadted from either end
-@@ -54,10 +55,18 @@ void get_checksum2(char *buf, int32 len, char *sum)
- 	if (protocol_version >= 30) {
- 		uchar seedbuf[4];
- 		md5_begin(&m);
--		md5_update(&m, (uchar *)buf, len);
--		if (checksum_seed) {
--			SIVALu(seedbuf, 0, checksum_seed);
--			md5_update(&m, seedbuf, 4);
-+		if (proper_seed_order) {
-+			if (checksum_seed) {
-+				SIVALu(seedbuf, 0, checksum_seed);
-+				md5_update(&m, seedbuf, 4);
-+			}
-+			md5_update(&m, (uchar *)buf, len);
-+		} else {
-+			md5_update(&m, (uchar *)buf, len);
-+			if (checksum_seed) {
-+				SIVALu(seedbuf, 0, checksum_seed);
-+				md5_update(&m, seedbuf, 4);
-+			}
- 		}
- 		md5_result(&m, (uchar *)sum);
- 	} else {
-diff --git a/compat.c b/compat.c
-index 2454937..f89d466 100644
---- a/compat.c
-+++ b/compat.c
-@@ -27,6 +27,7 @@ int inc_recurse = 0;
- int compat_flags = 0;
- int use_safe_inc_flist = 0;
- int want_xattr_optim = 0;
-+int proper_seed_order = 0;
- 
- extern int am_server;
- extern int am_sender;
-@@ -78,6 +79,7 @@ int filesfrom_convert = 0;
- #define CF_SYMLINK_ICONV (1<<2)
- #define CF_SAFE_FLIST	 (1<<3)
- #define CF_AVOID_XATTR_OPTIM (1<<4)
-+#define CF_CHKSUM_SEED_FIX (1<<5)
- 
- static const char *client_info;
- 
-@@ -271,12 +273,15 @@ void setup_protocol(int f_out,int f_in)
- 				compat_flags |= CF_SAFE_FLIST;
- 			if (local_server || strchr(client_info, 'x') != NULL)
- 				compat_flags |= CF_AVOID_XATTR_OPTIM;
-+			if (local_server || strchr(client_info, 'C') != NULL)
-+				compat_flags |= CF_CHKSUM_SEED_FIX;
- 			write_byte(f_out, compat_flags);
- 		} else
- 			compat_flags = read_byte(f_in);
- 		/* The inc_recurse var MUST be set to 0 or 1. */
- 		inc_recurse = compat_flags & CF_INC_RECURSE ? 1 : 0;
- 		want_xattr_optim = protocol_version >= 31 && !(compat_flags & CF_AVOID_XATTR_OPTIM);
-+		proper_seed_order = compat_flags & CF_CHKSUM_SEED_FIX ? 1 : 0;
- 		if (am_sender) {
- 			receiver_symlink_times = am_server
- 			    ? strchr(client_info, 'L') != NULL
-diff --git a/options.c b/options.c
-index 19c2b7d..4128b59 100644
---- a/options.c
-+++ b/options.c
-@@ -2503,6 +2503,7 @@ void server_options(char **args, int *argc_p)
- #endif
- 		argstr[x++] = 'f'; /* flist I/O-error safety support */
- 		argstr[x++] = 'x'; /* xattr hardlink optimization not desired */
-+		argstr[x++] = 'C'; /* support checksum seed order fix */
- 	}
- 
- 	if (x >= (int)sizeof argstr) { /* Not possible... */
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/rsync/rsync_3.1.1.bb b/yocto-poky/meta/recipes-devtools/rsync/rsync_3.1.1.bb
deleted file mode 100644
index c74cdda..0000000
--- a/yocto-poky/meta/recipes-devtools/rsync/rsync_3.1.1.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-require rsync.inc
-
-
-SRC_URI += "file://acinclude.m4 \
-            file://0001-Complain-if-an-inc-recursive-path-is-not-right-for-i.patch \
-            file://rsync.git-eac858085.patch \
-"
-
-SRC_URI[md5sum] = "43bd6676f0b404326eee2d63be3cdcfe"
-SRC_URI[sha256sum] = "7de4364fcf5fe42f3bdb514417f1c40d10bbca896abe7e7f2c581c6ea08a2621"
-
-PACKAGECONFIG ??= "acl attr"
-PACKAGECONFIG[acl] = "--enable-acl-support,--disable-acl-support,acl,"
-PACKAGECONFIG[attr] = "--enable-xattr-support,--disable-xattr-support,attr,"
-
-# rsync 3.0 uses configure.sh instead of configure, and
-# makefile checks the existence of configure.sh
-do_configure_prepend () {
-	rm -f ${S}/configure ${S}/configure.sh
-	cp -f ${WORKDIR}/acinclude.m4 ${S}/
-
-	# By default, if crosscompiling, rsync disables a number of
-	# capabilities, hardlinking symlinks and special files (i.e. devices)
-	export rsync_cv_can_hardlink_special=yes
-	export rsync_cv_can_hardlink_symlink=yes
-}
-
-do_configure_append () {
-	cp -f ${S}/configure ${S}/configure.sh
-}
diff --git a/yocto-poky/meta/recipes-devtools/rsync/rsync_3.1.2.bb b/yocto-poky/meta/recipes-devtools/rsync/rsync_3.1.2.bb
new file mode 100644
index 0000000..9637ed4
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/rsync/rsync_3.1.2.bb
@@ -0,0 +1,26 @@
+require rsync.inc
+
+SRC_URI += "file://makefile-no-rebuild.patch"
+
+SRC_URI[md5sum] = "0f758d7e000c0f7f7d3792610fad70cb"
+SRC_URI[sha256sum] = "ecfa62a7fa3c4c18b9eccd8c16eaddee4bd308a76ea50b5c02a5840f09c0a1c2"
+
+PACKAGECONFIG ??= "acl attr"
+PACKAGECONFIG[acl] = "--enable-acl-support,--disable-acl-support,acl,"
+PACKAGECONFIG[attr] = "--enable-xattr-support,--disable-xattr-support,attr,"
+
+# By default, if crosscompiling, rsync disables a number of
+# capabilities, hardlinking symlinks and special files (i.e. devices)
+CACHED_CONFIGUREVARS += "rsync_cv_can_hardlink_special=yes rsync_cv_can_hardlink_symlink=yes"
+
+# rsync 3.0 uses configure.sh instead of configure, and
+# makefile checks the existence of configure.sh
+do_configure_prepend () {
+	rm -f ${S}/configure ${S}/configure.sh
+}
+
+do_configure_append () {
+	cp -f ${S}/configure ${S}/configure.sh
+}
+
+BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/ruby/ruby.inc b/yocto-poky/meta/recipes-devtools/ruby/ruby.inc
index 17aa789..313e752 100644
--- a/yocto-poky/meta/recipes-devtools/ruby/ruby.inc
+++ b/yocto-poky/meta/recipes-devtools/ruby/ruby.inc
@@ -15,7 +15,7 @@
 "
 
 DEPENDS = "ruby-native zlib openssl tcl libyaml db gdbm readline"
-DEPENDS_class-native = "libyaml-native"
+DEPENDS_class-native = "openssl-native libyaml-native"
 
 SHRT_VER = "${@oe.utils.trim_version("${PV}", 2)}"
 SRC_URI = "http://cache.ruby-lang.org/pub/ruby/${SHRT_VER}/ruby-${PV}.tar.gz \
diff --git a/yocto-poky/meta/recipes-devtools/ruby/ruby_2.2.2.bb b/yocto-poky/meta/recipes-devtools/ruby/ruby_2.2.2.bb
index 78c943c..6715023 100644
--- a/yocto-poky/meta/recipes-devtools/ruby/ruby_2.2.2.bb
+++ b/yocto-poky/meta/recipes-devtools/ruby/ruby_2.2.2.bb
@@ -31,12 +31,16 @@
     oe_runmake 'DESTDIR=${D}' install
 }
 
-FILES_${PN} += "${datadir}/rubygems \
-                ${datadir}/ri"
+PACKAGES =+ "${PN}-ri-docs ${PN}-rdoc"
 
-FILES_${PN}-dbg += "${libdir}/ruby/*/.debug \
-                    ${libdir}/ruby/*/*/.debug \
-                    ${libdir}/ruby/*/*/*/.debug \
-                    ${libdir}/ruby/*/*/*/*/.debug"
+SUMMARY_${PN}-ri-docs = "ri (Ruby Interactive) documentation for the Ruby standard library"
+RDEPENDS_${PN}-ri-docs = "${PN}"
+FILES_${PN}-ri-docs += "${datadir}/ri"
+
+SUMMARY_${PN}-rdoc = "RDoc documentation generator from Ruby source"
+RDEPENDS_${PN}-rdoc = "${PN}"
+FILES_${PN}-rdoc += "${libdir}/ruby/*/rdoc ${bindir}/rdoc"
+
+FILES_${PN} += "${datadir}/rubygems"
 
 BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/sgmlspl/sgmlspl-native_git.bb b/yocto-poky/meta/recipes-devtools/sgmlspl/sgmlspl-native_git.bb
index 5e3460f..01581c1 100644
--- a/yocto-poky/meta/recipes-devtools/sgmlspl/sgmlspl-native_git.bb
+++ b/yocto-poky/meta/recipes-devtools/sgmlspl/sgmlspl-native_git.bb
@@ -4,6 +4,7 @@
 LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=18810669f13b87348459e611d31ab760"
 
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(\d+(\.\d+)+))"
 SRC_URI = "git://github.com/gitpan/SGMLSpm \
           "
 
diff --git a/yocto-poky/meta/recipes-devtools/squashfs-tools/squashfs-tools/fix-compat.patch b/yocto-poky/meta/recipes-devtools/squashfs-tools/squashfs-tools/fix-compat.patch
new file mode 100644
index 0000000..d545146
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/squashfs-tools/squashfs-tools/fix-compat.patch
@@ -0,0 +1,63 @@
+Define FNM_EXTMATCH if not defined its glibc specific define
+include missing sys/stat.h for stat* function declarations
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: squashfs-tools/action.c
+===================================================================
+--- squashfs-tools.orig/action.c
++++ squashfs-tools/action.c
+@@ -44,6 +44,10 @@
+ #include "action.h"
+ #include "error.h"
+ 
++#if !defined(FNM_EXTMATCH)
++#define FNM_EXTMATCH 0
++#endif
++
+ /*
+  * code to parse actions
+  */
+Index: squashfs-tools/mksquashfs.c
+===================================================================
+--- squashfs-tools.orig/mksquashfs.c
++++ squashfs-tools/mksquashfs.c
+@@ -1286,6 +1286,10 @@ void write_dir(squashfs_inode *inode, st
+ 		dir_size + 3, directory_block, directory_offset, NULL, NULL,
+ 		dir, 0);
+ 
++#if !defined(FNM_EXTMATCH)
++#define FNM_EXTMATCH 0
++#endif
++
+ #ifdef SQUASHFS_TRACE
+ 	{
+ 		unsigned char *dirp;
+Index: squashfs-tools/pseudo.c
+===================================================================
+--- squashfs-tools.orig/pseudo.c
++++ squashfs-tools/pseudo.c
+@@ -32,6 +32,7 @@
+ #include <stdlib.h>
+ #include <sys/types.h>
+ #include <sys/wait.h>
++#include <sys/stat.h>
+ #include <ctype.h>
+ 
+ #include "pseudo.h"
+Index: squashfs-tools/unsquashfs.c
+===================================================================
+--- squashfs-tools.orig/unsquashfs.c
++++ squashfs-tools/unsquashfs.c
+@@ -38,6 +38,10 @@
+ #include <limits.h>
+ #include <ctype.h>
+ 
++#ifndef FNM_EXTMATCH
++#define FNM_EXTMATCH 0
++#endif
++
+ struct cache *fragment_cache, *data_cache;
+ struct queue *to_reader, *to_inflate, *to_writer, *from_writer;
+ pthread_t *thread, *inflator_thread;
diff --git a/yocto-poky/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb b/yocto-poky/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb
index 7aebd00..33ed09a 100644
--- a/yocto-poky/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb
+++ b/yocto-poky/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb
@@ -13,6 +13,7 @@
 SRC_URI = "git://github.com/plougher/squashfs-tools.git;protocol=https \
            http://downloads.sourceforge.net/sevenzip/lzma465.tar.bz2;name=lzma \
            file://0001-mksquashfs.c-get-inline-functions-work-with-C99.patch;striplevel=2 \
+           file://fix-compat.patch \
 "
 SRC_URI[lzma.md5sum] = "29d5ffd03a5a3e51aef6a74e9eafb759"
 SRC_URI[lzma.sha256sum] = "c935fd04dd8e0e8c688a3078f3675d699679a90be81c12686837e0880aa0fa1e"
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/0001-Add-linux-aarch64-arch_regs.h.patch b/yocto-poky/meta/recipes-devtools/strace/strace/0001-Add-linux-aarch64-arch_regs.h.patch
deleted file mode 100644
index 0853959..0000000
--- a/yocto-poky/meta/recipes-devtools/strace/strace/0001-Add-linux-aarch64-arch_regs.h.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From f85854131c8265f2eb59c714dcea5c4b3dc09bed Mon Sep 17 00:00:00 2001
-From: Koen Kooi <koen.kooi@linaro.org>
-Date: Wed, 15 Apr 2015 14:29:37 +0200
-Subject: [PATCH] Add linux/aarch64/arch_regs.h
-
-It is missing from the tarball, but it is present in git for v4.10
-
-Signed-off-by: Koen Kooi <koen.kooi@linaro.org>
-Upstream-Status: Pending
----
- linux/aarch64/arch_regs.h | 2 ++
- 1 file changed, 2 insertions(+)
- create mode 100644 linux/aarch64/arch_regs.h
-
-diff --git a/linux/aarch64/arch_regs.h b/linux/aarch64/arch_regs.h
-new file mode 100644
-index 0000000..9a5e33e
---- /dev/null
-+++ b/linux/aarch64/arch_regs.h
-@@ -0,0 +1,2 @@
-+extern uint64_t *const aarch64_sp_ptr;
-+extern uint32_t *const arm_sp_ptr;
--- 
-1.9.3
-
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/0001-Move-gcc-compat-macros-to-gcc_compat.h.patch b/yocto-poky/meta/recipes-devtools/strace/strace/0001-Move-gcc-compat-macros-to-gcc_compat.h.patch
new file mode 100644
index 0000000..aa61e15
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/0001-Move-gcc-compat-macros-to-gcc_compat.h.patch
@@ -0,0 +1,176 @@
+From f32126ba790dd4e61d43a2140b24f02426297bb6 Mon Sep 17 00:00:00 2001
+From: "Dmitry V. Levin" <ldv@altlinux.org>
+Date: Thu, 31 Dec 2015 14:19:41 +0000
+Subject: [PATCH] Move gcc compat macros to gcc_compat.h
+
+* defs.h: Include "gcc_compat.h".
+(GNUC_PREREQ, ATTRIBUTE_NORETURN, ATTRIBUTE_FORMAT,
+ATTRIBUTE_ALIGNED, ATTRIBUTE_PACKED, ATTRIBUTE_MALLOC,
+ATTRIBUTE_NOINLINE, ATTRIBUTE_ALLOC_SIZE): Move ...
+* gcc_compat.h: ... here.
+* Makefile.am (strace_SOURCES): Add gcc_compat.h.
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport
+
+ Makefile.am  |  1 +
+ defs.h       | 43 +----------------------------------
+ gcc_compat.h | 73 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ 3 files changed, 75 insertions(+), 42 deletions(-)
+ create mode 100644 gcc_compat.h
+
+diff --git a/Makefile.am b/Makefile.am
+index ab52778..d43608d 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -97,6 +97,7 @@ strace_SOURCES =	\
+ 	flock.c		\
+ 	flock.h		\
+ 	futex.c		\
++	gcc_compat.h	\
+ 	get_robust_list.c \
+ 	getcpu.c	\
+ 	getcwd.c	\
+diff --git a/defs.h b/defs.h
+index 283ab1f..bae212c 100644
+--- a/defs.h
++++ b/defs.h
+@@ -55,6 +55,7 @@
+ #include <sys/syscall.h>
+ 
+ #include "mpers_type.h"
++#include "gcc_compat.h"
+ 
+ #ifndef HAVE_STRERROR
+ const char *strerror(int);
+@@ -68,48 +69,6 @@ const char *strerror(int);
+ extern char *stpcpy(char *dst, const char *src);
+ #endif
+ 
+-#if defined __GNUC__ && defined __GNUC_MINOR__
+-# define GNUC_PREREQ(maj, min)	\
+-	((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
+-#else
+-# define __attribute__(x)	/* empty */
+-# define GNUC_PREREQ(maj, min)	0
+-#endif
+-
+-#if GNUC_PREREQ(2, 5)
+-# define ATTRIBUTE_NORETURN	__attribute__((__noreturn__))
+-#else
+-# define ATTRIBUTE_NORETURN	/* empty */
+-#endif
+-
+-#if GNUC_PREREQ(2, 7)
+-# define ATTRIBUTE_FORMAT(args)	__attribute__((__format__ args))
+-# define ATTRIBUTE_ALIGNED(arg)	__attribute__((__aligned__(arg)))
+-# define ATTRIBUTE_PACKED	__attribute__((__packed__))
+-#else
+-# define ATTRIBUTE_FORMAT(args)	/* empty */
+-# define ATTRIBUTE_ALIGNED(arg)	/* empty */
+-# define ATTRIBUTE_PACKED	/* empty */
+-#endif
+-
+-#if GNUC_PREREQ(3, 0)
+-# define ATTRIBUTE_MALLOC	__attribute__((__malloc__))
+-#else
+-# define ATTRIBUTE_MALLOC	/* empty */
+-#endif
+-
+-#if GNUC_PREREQ(3, 1)
+-# define ATTRIBUTE_NOINLINE	__attribute__((__noinline__))
+-#else
+-# define ATTRIBUTE_NOINLINE	/* empty */
+-#endif
+-
+-#if GNUC_PREREQ(4, 3)
+-# define ATTRIBUTE_ALLOC_SIZE(args)	__attribute__((__alloc_size__ args))
+-#else
+-# define ATTRIBUTE_ALLOC_SIZE(args)	/* empty */
+-#endif
+-
+ #ifndef offsetof
+ # define offsetof(type, member)	\
+ 	(((char *) &(((type *) NULL)->member)) - ((char *) (type *) NULL))
+diff --git a/gcc_compat.h b/gcc_compat.h
+new file mode 100644
+index 0000000..1f2c835
+--- /dev/null
++++ b/gcc_compat.h
+@@ -0,0 +1,73 @@
++/*
++ * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
++ * 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. The name of the author may not be used to endorse or promote products
++ *    derived from this software without specific prior written permission.
++ *
++ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``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 AUTHOR 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.
++ */
++
++#ifndef GCC_COMPAT_H_
++#define GCC_COMPAT_H_
++
++#if defined __GNUC__ && defined __GNUC_MINOR__
++# define GNUC_PREREQ(maj, min)	\
++	((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
++#else
++# define __attribute__(x)	/* empty */
++# define GNUC_PREREQ(maj, min)	0
++#endif
++
++#if GNUC_PREREQ(2, 5)
++# define ATTRIBUTE_NORETURN	__attribute__((__noreturn__))
++#else
++# define ATTRIBUTE_NORETURN	/* empty */
++#endif
++
++#if GNUC_PREREQ(2, 7)
++# define ATTRIBUTE_FORMAT(args)	__attribute__((__format__ args))
++# define ATTRIBUTE_ALIGNED(arg)	__attribute__((__aligned__(arg)))
++# define ATTRIBUTE_PACKED	__attribute__((__packed__))
++#else
++# define ATTRIBUTE_FORMAT(args)	/* empty */
++# define ATTRIBUTE_ALIGNED(arg)	/* empty */
++# define ATTRIBUTE_PACKED	/* empty */
++#endif
++
++#if GNUC_PREREQ(3, 0)
++# define ATTRIBUTE_MALLOC	__attribute__((__malloc__))
++#else
++# define ATTRIBUTE_MALLOC	/* empty */
++#endif
++
++#if GNUC_PREREQ(3, 1)
++# define ATTRIBUTE_NOINLINE	__attribute__((__noinline__))
++#else
++# define ATTRIBUTE_NOINLINE	/* empty */
++#endif
++
++#if GNUC_PREREQ(4, 3)
++# define ATTRIBUTE_ALLOC_SIZE(args)	__attribute__((__alloc_size__ args))
++#else
++# define ATTRIBUTE_ALLOC_SIZE(args)	/* empty */
++#endif
++
++#endif
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/0001-arc-metag-nios2-or1k-tile-fix-build.patch b/yocto-poky/meta/recipes-devtools/strace/strace/0001-arc-metag-nios2-or1k-tile-fix-build.patch
new file mode 100644
index 0000000..a9d3203
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/0001-arc-metag-nios2-or1k-tile-fix-build.patch
@@ -0,0 +1,117 @@
+From dd1a80c8d213eed95fe55b7ebcb07ee165dd8e4b Mon Sep 17 00:00:00 2001
+From: "Dmitry V. Levin" <ldv@altlinux.org>
+Date: Thu, 24 Dec 2015 15:40:55 +0000
+Subject: [PATCH] arc, metag, nios2, or1k, tile: fix build
+
+Fix build regression introduced by commit
+34683e3926d8c2daa368afb805da422ee7043396.
+
+* linux/32/syscallent.h: Add sys_ prefix to ARCH_mmap and mmap.
+* linux/arc/syscallent.h: Add sys_ prefix to ARCH_mmap and mmap_pgoff.
+* linux/nios2/syscallent.h: Likewise.
+* linux/or1k/syscallent.h: Likewise.
+* linux/tile/syscallent1.h: Add sys_ prefix to ARCH_mmap and sys_mmap_4koff.
+* pathtrace.c (pathtrace_match): Handle SEN_ARCH_mmap.
+* NEWS: Mention this build fix.
+
+Reported-by: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
+Signed-off-by: Marek Vasut <marex@denx.de>
+Upstream-Status: Backport
+---
+ NEWS                     | 3 +++
+ linux/32/syscallent.h    | 6 +++---
+ linux/arc/syscallent.h   | 2 +-
+ linux/nios2/syscallent.h | 2 +-
+ linux/or1k/syscallent.h  | 2 +-
+ linux/tile/syscallent1.h | 2 +-
+ pathtrace.c              | 1 +
+ 7 files changed, 11 insertions(+), 7 deletions(-)
+
+diff --git a/NEWS b/NEWS
+index fe40ca4..09263eb 100644
+--- a/NEWS
++++ b/NEWS
+@@ -1,3 +1,9 @@
++Noteworthy changes in release ?.?? (????-??-??)
++===============================================
++
++* Bug fixes
++  * Fixed build on arc, metag, nios2, or1k, and tile architectures.
++
+ Noteworthy changes in release 4.11 (2015-12-21)
+ ===============================================
+ 
+diff --git a/linux/32/syscallent.h b/linux/32/syscallent.h
+index 5f997e7..e6f895c 100644
+--- a/linux/32/syscallent.h
++++ b/linux/32/syscallent.h
+@@ -1,5 +1,5 @@
+-#ifndef ARCH_mmap
+-# define ARCH_mmap mmap
++#ifndef sys_ARCH_mmap
++# define sys_ARCH_mmap sys_mmap
+ #endif
+ [  0] = { 2,	0,		SEN(io_setup),			"io_setup"		},
+ [  1] = { 1,	0,		SEN(io_destroy),		"io_destroy"		},
+@@ -276,5 +276,5 @@
+ [283] = { 2,	0,		SEN(membarrier),		"membarrier",		},
+ [284] = { 3,	TM,		SEN(mlock2),			"mlock2"		},
+ 
+-#undef ARCH_mmap
++#undef sys_ARCH_mmap
+ #undef ARCH_WANT_SYNC_FILE_RANGE2
+diff --git a/linux/arc/syscallent.h b/linux/arc/syscallent.h
+index 5847dc4..1100008 100644
+--- a/linux/arc/syscallent.h
++++ b/linux/arc/syscallent.h
+@@ -1,4 +1,4 @@
+-#define ARCH_mmap mmap_pgoff
++#define sys_ARCH_mmap sys_mmap_pgoff
+ #include "32/syscallent.h"
+ [244] = { 3,	0,	SEN(printargs),	"arc_cacheflush"},
+ [245] = { 1,	0,	SEN(printargs),	"arc_settls"	},
+diff --git a/linux/nios2/syscallent.h b/linux/nios2/syscallent.h
+index 8a4b70e..01efe3a 100644
+--- a/linux/nios2/syscallent.h
++++ b/linux/nios2/syscallent.h
+@@ -1,4 +1,4 @@
+-#define ARCH_mmap mmap_pgoff
++#define sys_ARCH_mmap sys_mmap_pgoff
+ #include "32/syscallent.h"
+ [244] = {4,    0,	SEN(cacheflush), "cacheflush"},
+ [245 ... 259] = { },
+diff --git a/linux/or1k/syscallent.h b/linux/or1k/syscallent.h
+index ed84b3b..351fe25 100644
+--- a/linux/or1k/syscallent.h
++++ b/linux/or1k/syscallent.h
+@@ -1,4 +1,4 @@
+-#define ARCH_mmap mmap_pgoff
++#define sys_ARCH_mmap sys_mmap_pgoff
+ #include "32/syscallent.h"
+ [244] = { 3,	NF,	SEN(or1k_atomic),	"or1k_atomic"	},
+ [245 ... 259] = { },
+diff --git a/linux/tile/syscallent1.h b/linux/tile/syscallent1.h
+index c86f059..28dbab4 100644
+--- a/linux/tile/syscallent1.h
++++ b/linux/tile/syscallent1.h
+@@ -1,4 +1,4 @@
+-#define ARCH_mmap mmap_4koff
++#define sys_ARCH_mmap sys_mmap_4koff
+ #define ARCH_WANT_SYNC_FILE_RANGE2 1
+ #include "32/syscallent.h"
+ [244] = { 1,	0,	SEN(printargs),	"cmpxchg_badaddr"	},
+diff --git a/pathtrace.c b/pathtrace.c
+index d530ec2..e72cdf7 100644
+--- a/pathtrace.c
++++ b/pathtrace.c
+@@ -216,6 +216,7 @@ pathtrace_match(struct tcb *tcp)
+ 	case SEN_mmap:
+ 	case SEN_mmap_4koff:
+ 	case SEN_mmap_pgoff:
++	case SEN_ARCH_mmap:
+ 		/* x, x, x, x, fd */
+ 		return fdmatch(tcp, tcp->u_arg[4]);
+ 
+-- 
+2.6.4
+
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/0001-scm_rights-fd.test-rewrite-without-fork.patch b/yocto-poky/meta/recipes-devtools/strace/strace/0001-scm_rights-fd.test-rewrite-without-fork.patch
new file mode 100644
index 0000000..c4e645b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/0001-scm_rights-fd.test-rewrite-without-fork.patch
@@ -0,0 +1,198 @@
+From 3fdcdd47c6a67585123a0a0c8fffabcc9f79a3a2 Mon Sep 17 00:00:00 2001
+From: "Dmitry V. Levin" <ldv@altlinux.org>
+Date: Tue, 12 Jan 2016 14:47:12 +0000
+Subject: [PATCH] scm_rights-fd.test: rewrite without fork
+
+* tests/scm_rights.c (main): Rewrite without fork.
+Place all objects passed to sendmsg and recvmsg at the end
+of memory pages followed by inaccessible pages.
+* tests/scm_rights-fd.test: Update.
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport
+
+ tests/scm_rights-fd.test |  12 ++---
+ tests/scm_rights.c       | 122 ++++++++++++++++++++++-------------------------
+ 2 files changed, 63 insertions(+), 71 deletions(-)
+
+diff --git a/tests/scm_rights-fd.test b/tests/scm_rights-fd.test
+index a32ef36..48c5028 100755
+--- a/tests/scm_rights-fd.test
++++ b/tests/scm_rights-fd.test
+@@ -49,18 +49,18 @@ touch -- "$file" ||
+ 	framework_skip_ 'failed to create a file'
+ 
+ run_prog ./scm_rights /dev/zero
+-run_strace_merge -y -x -enetwork $args "$file"
++run_strace -y -x -enetwork $args "$file"
+ 
++sample='\\xf1\\xf2\\xf3\\xf4\\xf5\\xf6\\xf7\\xf8\\xf9\\xfa\\xfb\\xfc\\xfd\\xfe\\xff'
+ n='[1-9][0-9]*'
+-msg='\{msg_name\(0\)=NULL, msg_iov\(1\)=\[\{"\\x00\\x00\\x00\\x00[^"]*", '"$n"'\}\], msg_controllen='"$n"
+-rights='\{cmsg_len='"$n"', cmsg_level=SOL_SOCKET, cmsg_type=SCM_RIGHTS, \[3</dev/null>, 4</dev/zero>, 5</[^}>]*/(A\\n){127}Z>\]\}'
++msg='\{msg_name\(0\)=NULL, msg_iov\(1\)=\[\{"'"$sample"'", 15\}\], msg_controllen='"$n"
++rights='\{cmsg_len='"$n"', cmsg_level=SOL_SOCKET, cmsg_type=SCM_RIGHTS, \[4</dev/null>, 5</dev/zero>, 6</[^}>]*/(A\\n){127}Z>\]\}'
+ creds='\{cmsg_len='"$n"', cmsg_level=SOL_SOCKET, cmsg_type=SCM_CREDENTIALS, \{pid='"$n"', uid=[0-9]+, gid=[0-9]+\}\}'
+-prefix='[1-9][0-9]* +[0-9]+:[0-9]+:[0-9]+\.[0-9]+ +'
+ EXPECTED="$LOG.expected"
+ 
+ cat > "$EXPECTED" << __EOF__
+-${prefix}sendmsg\\(1<socket:\\[[0-9]+\\]>, $msg, \\[$rights\\], msg_flags=0\\}, 0\\) += $n
+-${prefix}recvmsg\\(0<socket:\\[[0-9]+\\]>, $msg, \\[$creds, $rights\\], msg_flags=0\\}, 0\\) += $n
++sendmsg\\(3<socket:\\[[0-9]+\\]>, $msg, \\[$rights\\], msg_flags=0\\}, 0\\) = 15
++recvmsg\\(0<socket:\\[[0-9]+\\]>, $msg, \\[$creds, $rights\\], msg_flags=0\\}, 0\\) = 15
+ __EOF__
+ 
+ match_grep "$LOG" "$EXPECTED"
+diff --git a/tests/scm_rights.c b/tests/scm_rights.c
+index 1e5e850..00af4d5 100644
+--- a/tests/scm_rights.c
++++ b/tests/scm_rights.c
+@@ -27,26 +27,39 @@
+ 
+ #include "tests.h"
+ #include <assert.h>
+-#include <string.h>
+-#include <stdlib.h>
+-#include <unistd.h>
+ #include <errno.h>
+ #include <fcntl.h>
++#include <stdlib.h>
++#include <string.h>
++#include <unistd.h>
+ #include <sys/socket.h>
+-#include <sys/wait.h>
+ 
+ int main(int ac, const char **av)
+ {
+-	int i;
+-	int data = 0;
+-	struct iovec iov = {
+-		.iov_base = &data,
+-		.iov_len = sizeof(iov)
+-	};
++	assert(ac > 0);
++	int fds[ac];
++
++	static const char sample[] =
++		"\xf1\xf2\xf3\xf4\xf5\xf6\xf7\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff";
++	const unsigned int data_size = sizeof(sample) - 1;
++	void *data = tail_alloc(data_size);
++	memcpy(data, sample, data_size);
++
++	struct iovec *iov = tail_alloc(sizeof(struct iovec));
++	iov->iov_base = data;
++	iov->iov_len = data_size;
+ 
+-	while ((i = open("/dev/null", O_RDWR)) < 3)
++	struct msghdr *mh = tail_alloc(sizeof(struct msghdr));
++	memset(mh, 0, sizeof(*mh));
++	mh->msg_iov = iov;
++	mh->msg_iovlen = 1;
++
++	int i;
++	while ((i = open("/dev/null", O_RDWR)) <= ac + 2)
+ 		assert(i >= 0);
+-	(void) close(3);
++	while (i > 2)
++		assert(close(i--) == 0);
++	assert(close(0) == 0);
+ 
+ 	int sv[2];
+ 	if (socketpair(AF_UNIX, SOCK_STREAM, 0, sv))
+@@ -55,60 +68,39 @@ int main(int ac, const char **av)
+ 	if (setsockopt(sv[0], SOL_SOCKET, SO_PASSCRED, &one, sizeof(one)))
+ 		perror_msg_and_skip("setsockopt");
+ 
+-	pid_t pid = fork();
+-	if (pid < 0)
+-		perror_msg_and_fail("fork");
+-
+-	if (pid) {
+-		assert(close(sv[0]) == 0);
+-		assert(dup2(sv[1], 1) == 1);
+-		assert(close(sv[1]) == 0);
+-
+-		int fds[ac];
+-		assert((fds[0] = open("/dev/null", O_RDWR)) == 3);
+-		for (i = 1; i < ac; ++i)
+-			assert((fds[i] = open(av[i], O_RDONLY)) == i + 3);
+-
+-		union {
+-			struct cmsghdr cmsg;
+-			char buf[CMSG_LEN(sizeof(fds))];
+-		} control;
+-
+-		control.cmsg.cmsg_level = SOL_SOCKET;
+-		control.cmsg.cmsg_type = SCM_RIGHTS;
+-		control.cmsg.cmsg_len = CMSG_LEN(sizeof(fds));
+-		memcpy(CMSG_DATA(&control.cmsg), fds, sizeof(fds));
+-
+-		struct msghdr mh = {
+-			.msg_iov = &iov,
+-			.msg_iovlen = 1,
+-			.msg_control = &control,
+-			.msg_controllen = sizeof(control)
+-		};
+-
+-		assert(sendmsg(1, &mh, 0) == sizeof(iov));
+-		assert(close(1) == 0);
+-
+-                int status;
+-		assert(waitpid(pid, &status, 0) == pid);
+-		assert(status == 0);
+-	} else {
+-		assert(close(sv[1]) == 0);
+-		assert(dup2(sv[0], 0) == 0);
+-		assert(close(sv[0]) == 0);
+-
+-		struct cmsghdr control[4 + ac * sizeof(int) / sizeof(struct cmsghdr)];
+-
+-		struct msghdr mh = {
+-			.msg_iov = &iov,
+-			.msg_iovlen = 1,
+-			.msg_control = control,
+-			.msg_controllen = sizeof(control)
+-		};
+-
+-		assert(recvmsg(0, &mh, 0) == sizeof(iov));
+-		assert(close(0) == 0);
++	assert((fds[0] = open("/dev/null", O_RDWR)) == 4);
++	for (i = 1; i < ac; ++i)
++		assert((fds[i] = open(av[i], O_RDONLY)) == i + 4);
++
++	unsigned int cmsg_size = CMSG_SPACE(sizeof(fds));
++	struct cmsghdr *cmsg = tail_alloc(cmsg_size);
++	memset(cmsg, 0, cmsg_size);
++	cmsg->cmsg_level = SOL_SOCKET;
++	cmsg->cmsg_type = SCM_RIGHTS;
++	cmsg->cmsg_len = CMSG_LEN(sizeof(fds));
++	memcpy(CMSG_DATA(cmsg), fds, sizeof(fds));
++
++	mh->msg_control = cmsg;
++	mh->msg_controllen = cmsg_size;
++
++	assert(sendmsg(sv[1], mh, 0) == (int) data_size);
++
++	assert(close(sv[1]) == 0);
++	assert(open("/dev/null", O_RDWR) == sv[1]);
++
++	for (i = 0; i < ac; ++i) {
++		assert(close(fds[i]) == 0);
++		fds[i] = 0;
+ 	}
+ 
++	cmsg_size += CMSG_SPACE(sizeof(struct ucred));
++	cmsg = tail_alloc(cmsg_size);
++	memset(cmsg, 0, cmsg_size);
++	mh->msg_control = cmsg;
++	mh->msg_controllen = cmsg_size;
++
++	assert(recvmsg(0, mh, 0) == (int) data_size);
++	assert(close(0) == 0);
++
+ 	return 0;
+ }
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/0001-tests-introduce-libtests.patch b/yocto-poky/meta/recipes-devtools/strace/strace/0001-tests-introduce-libtests.patch
new file mode 100644
index 0000000..1575ecd
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/0001-tests-introduce-libtests.patch
@@ -0,0 +1,306 @@
+From 87e6b230fff800eb768b68b2e5173ebbe83fd3ef Mon Sep 17 00:00:00 2001
+From: "Dmitry V. Levin" <ldv@altlinux.org>
+Date: Sat, 2 Jan 2016 12:05:14 +0000
+Subject: [PATCH] tests: introduce libtests
+
+Introduce tests/libtests.a with common functions for use in tests.
+
+* tests/tests.h: New file.
+* tests/error_msg.c: Likewise.
+* tests/tail_alloc.c: Likewise.
+* tests/get_page_size.c: Likewise.
+* tests/Makefile.am (libtests_a_SOURCES, libtests_a_CPPFLAGS,
+check_LIBRARIES, LDADD): New variables.
+(clock_xettime_LDADD, filter_unavailable_LDADD, mq_LDADD,
+pc_LDADD, times_LDADD): Add $(LDADD).
+* tests/.gitignore: Add libtests.a.
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport
+
+ tests/.gitignore      |  1 +
+ tests/Makefile.am     | 20 ++++++++++----
+ tests/error_msg.c     | 74 +++++++++++++++++++++++++++++++++++++++++++++++++++
+ tests/get_page_size.c | 13 +++++++++
+ tests/tail_alloc.c    | 52 ++++++++++++++++++++++++++++++++++++
+ tests/tests.h         | 62 ++++++++++++++++++++++++++++++++++++++++++
+ 6 files changed, 217 insertions(+), 5 deletions(-)
+ create mode 100644 tests/error_msg.c
+ create mode 100644 tests/get_page_size.c
+ create mode 100644 tests/tail_alloc.c
+ create mode 100644 tests/tests.h
+
+diff --git a/tests/Makefile.am b/tests/Makefile.am
+index 386a2c2..62d0e56 100644
+--- a/tests/Makefile.am
++++ b/tests/Makefile.am
+@@ -40,6 +40,16 @@ AM_CPPFLAGS = $(ARCH_MFLAGS) \
+ 	      -I$(top_srcdir)
+ AM_LDFLAGS = $(ARCH_MFLAGS)
+ 
++libtests_a_SOURCES = \
++	get_page_size.c \
++	error_msg.c \
++	tail_alloc.c \
++	tests.h \
++	# end of libtests_a_SOURCES
++libtests_a_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
++check_LIBRARIES = libtests.a
++LDADD = libtests.a
++
+ check_PROGRAMS = \
+ 	_newselect \
+ 	adjtimex \
+@@ -146,19 +156,19 @@ check_PROGRAMS = \
+ 	xettimeofday \
+ 	# end of check_PROGRAMS
+ 
+-clock_xettime_LDADD = -lrt
+-filter_unavailable_LDADD = -lpthread
++clock_xettime_LDADD = -lrt $(LDADD)
++filter_unavailable_LDADD = -lpthread $(LDADD)
+ fstat64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+ fstatat64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+ ftruncate64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+ lstat64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+ mmap64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+-mq_LDADD = -lrt
++mq_LDADD = -lrt $(LDADD)
+ newfstatat_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+-pc_LDADD = $(dl_LIBS)
++pc_LDADD = $(dl_LIBS) $(LDADD)
+ stat64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+ statfs_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+-times_LDADD = -lrt
++times_LDADD = -lrt $(LDADD)
+ truncate64_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+ uio_CPPFLAGS = $(AM_CPPFLAGS) -D_FILE_OFFSET_BITS=64
+ stack_fcall_SOURCES = stack-fcall.c \
+diff --git a/tests/error_msg.c b/tests/error_msg.c
+new file mode 100644
+index 0000000..3fd3411
+--- /dev/null
++++ b/tests/error_msg.c
+@@ -0,0 +1,74 @@
++/*
++ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
++ * 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. The name of the author may not be used to endorse or promote products
++ *    derived from this software without specific prior written permission.
++ *
++ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``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 AUTHOR 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.
++ */
++
++#include "tests.h"
++#include <errno.h>
++#include <stdarg.h>
++#include <stdio.h>
++#include <stdlib.h>
++#include <string.h>
++
++void
++perror_msg_and_fail(const char *fmt, ...)
++{
++	int err_no = errno;
++	va_list p;
++
++	va_start(p, fmt);
++	vfprintf(stderr, fmt, p);
++	if (err_no)
++		fprintf(stderr, ": %s\n", strerror(err_no));
++	else
++		putc('\n', stderr);
++	exit(1);
++}
++
++void
++error_msg_and_skip(const char *fmt, ...)
++{
++	va_list p;
++
++	va_start(p, fmt);
++	vfprintf(stderr, fmt, p);
++	putc('\n', stderr);
++	exit(77);
++}
++
++void
++perror_msg_and_skip(const char *fmt, ...)
++{
++	int err_no = errno;
++	va_list p;
++
++	va_start(p, fmt);
++	vfprintf(stderr, fmt, p);
++	if (err_no)
++		fprintf(stderr, ": %s\n", strerror(err_no));
++	else
++		putc('\n', stderr);
++	exit(77);
++}
+diff --git a/tests/get_page_size.c b/tests/get_page_size.c
+new file mode 100644
+index 0000000..aeea861
+--- /dev/null
++++ b/tests/get_page_size.c
+@@ -0,0 +1,13 @@
++#include "tests.h"
++#include <unistd.h>
++
++size_t
++get_page_size(void)
++{
++	static size_t page_size;
++
++	if (!page_size)
++		page_size = sysconf(_SC_PAGESIZE);
++
++	return page_size;
++}
+diff --git a/tests/tail_alloc.c b/tests/tail_alloc.c
+new file mode 100644
+index 0000000..2b8b14e
+--- /dev/null
++++ b/tests/tail_alloc.c
+@@ -0,0 +1,52 @@
++/*
++ * Copyright (c) 2015-2016 Dmitry V. Levin <ldv@altlinux.org>
++ * 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. The name of the author may not be used to endorse or promote products
++ *    derived from this software without specific prior written permission.
++ *
++ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``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 AUTHOR 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.
++ */
++
++#include "tests.h"
++#include <string.h>
++#include <sys/mman.h>
++
++void *
++tail_alloc(const size_t size)
++{
++	const size_t page_size = get_page_size();
++	const size_t len = (size + page_size - 1) & -page_size;
++	const size_t alloc_size = len + 2 * page_size;
++
++	void *p = mmap(NULL, alloc_size, PROT_READ | PROT_WRITE,
++		       MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
++	if (MAP_FAILED == p)
++		perror_msg_and_fail("mmap(%zu)", alloc_size);
++
++	void *start_work = p + page_size;
++	void *tail_guard = start_work + len;
++
++	if (munmap(p, page_size) || munmap(tail_guard, page_size))
++		perror_msg_and_fail("munmap");
++
++	memset(start_work, 0xff, len);
++	return tail_guard - size;
++}
+diff --git a/tests/tests.h b/tests/tests.h
+new file mode 100644
+index 0000000..91fa24e
+--- /dev/null
++++ b/tests/tests.h
+@@ -0,0 +1,62 @@
++/*
++ * Copyright (c) 2016 Dmitry V. Levin <ldv@altlinux.org>
++ * 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. The name of the author may not be used to endorse or promote products
++ *    derived from this software without specific prior written permission.
++ *
++ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``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 AUTHOR 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.
++ */
++
++#ifndef TESTS_H_
++# define TESTS_H_
++
++# ifdef HAVE_CONFIG_H
++#  include "config.h"
++# endif
++
++# include <sys/types.h>
++# include "gcc_compat.h"
++
++/* Cached sysconf(_SC_PAGESIZE). */
++size_t get_page_size(void);
++
++/* Print message and strerror(errno) to stderr, then exit(1). */
++void perror_msg_and_fail(const char *, ...)
++	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
++/* Print message to stderr, then exit(77). */
++void error_msg_and_skip(const char *, ...)
++	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
++/* Print message and strerror(errno) to stderr, then exit(77). */
++void perror_msg_and_skip(const char *, ...)
++	ATTRIBUTE_FORMAT((printf, 1, 2)) ATTRIBUTE_NORETURN;
++
++/*
++ * Allocate memory that ends on the page boundary.
++ * Pages allocated by this call are preceeded by an unmapped page
++ * and followed also by an unmapped page.
++ */
++void *tail_alloc(const size_t)
++	ATTRIBUTE_MALLOC ATTRIBUTE_ALLOC_SIZE((1));
++
++# define SKIP_MAIN_UNDEFINED(arg) \
++	int main(void) { error_msg_and_skip("undefined: %s", arg); }
++
++#endif
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/0001-tests-scm_rights.c-use-libtests.patch b/yocto-poky/meta/recipes-devtools/strace/strace/0001-tests-scm_rights.c-use-libtests.patch
new file mode 100644
index 0000000..3fbab8b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/0001-tests-scm_rights.c-use-libtests.patch
@@ -0,0 +1,54 @@
+From 339a15b619b479c63cafba21d5fc359e613d9ee8 Mon Sep 17 00:00:00 2001
+From: "Dmitry V. Levin" <ldv@altlinux.org>
+Date: Mon, 4 Jan 2016 23:53:31 +0000
+Subject: [PATCH] tests/scm_rights.c: use libtests
+
+* tests/scm_rights.c (main): Use perror_msg_and_fail and perror_msg_and_skip.
+---
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Backport
+
+ tests/scm_rights.c | 12 ++++++++----
+ 1 file changed, 8 insertions(+), 4 deletions(-)
+
+diff --git a/tests/scm_rights.c b/tests/scm_rights.c
+index c41444f..1e5e850 100644
+--- a/tests/scm_rights.c
++++ b/tests/scm_rights.c
+@@ -1,5 +1,5 @@
+ /*
+- * Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
++ * Copyright (c) 2014-2016 Dmitry V. Levin <ldv@altlinux.org>
+  * All rights reserved.
+  *
+  * Redistribution and use in source and binary forms, with or without
+@@ -25,6 +25,7 @@
+  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+  */
+ 
++#include "tests.h"
+ #include <assert.h>
+ #include <string.h>
+ #include <stdlib.h>
+@@ -48,12 +49,15 @@ int main(int ac, const char **av)
+ 	(void) close(3);
+ 
+ 	int sv[2];
+-	assert(socketpair(AF_UNIX, SOCK_STREAM, 0, sv) == 0);
++	if (socketpair(AF_UNIX, SOCK_STREAM, 0, sv))
++		perror_msg_and_skip("socketpair");
+ 	int one = 1;
+-	assert(setsockopt(sv[0], SOL_SOCKET, SO_PASSCRED, &one, sizeof(one)) == 0);
++	if (setsockopt(sv[0], SOL_SOCKET, SO_PASSCRED, &one, sizeof(one)))
++		perror_msg_and_skip("setsockopt");
+ 
+ 	pid_t pid = fork();
+-	assert(pid >= 0);
++	if (pid < 0)
++		perror_msg_and_fail("fork");
+ 
+ 	if (pid) {
+ 		assert(close(sv[0]) == 0);
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/Include-linux-ioctl.h-for-_IOC_-macros.patch b/yocto-poky/meta/recipes-devtools/strace/strace/Include-linux-ioctl.h-for-_IOC_-macros.patch
deleted file mode 100644
index d9346a8..0000000
--- a/yocto-poky/meta/recipes-devtools/strace/strace/Include-linux-ioctl.h-for-_IOC_-macros.patch
+++ /dev/null
@@ -1,69 +0,0 @@
-Upstream-Status: Backport
-
-  http://sourceforge.net/p/strace/code/ci/3460dc486d333231998de0f19918204aacee9ae3
-
-Expected to be released officially as part of strace 4.11
-
-Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
-
-From 3460dc486d333231998de0f19918204aacee9ae3 Mon Sep 17 00:00:00 2001
-From: Felix Janda <felix.janda@posteo.de>
-Date: Sat, 28 Mar 2015 18:40:13 +0100
-Subject: [PATCH] Include <linux/ioctl.h> for _IOC_* macros
-
-Fix a compilation failure with musl libc.
-
-* evdev.c: Include <linux/ioctl.h>.
-* ioctl.c: Include <linux/ioctl.h> instead of <asm/ioctl.h>.
-* ioctlsort.c: Likewise.
-
-Reported-by: Dima Krasner <dima@dimakrasner.com>
-Acked-by: Mike Frysinger <vapier@gentoo.org>
----
- evdev.c     | 2 ++
- ioctl.c     | 2 +-
- ioctlsort.c | 2 +-
- 3 files changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/evdev.c b/evdev.c
-index 9a7430d..e06f9c1 100644
---- a/evdev.c
-+++ b/evdev.c
-@@ -28,6 +28,8 @@
- 
- #include "defs.h"
- 
-+#include <linux/ioctl.h>
-+
- #ifdef HAVE_LINUX_INPUT_H
- #include <linux/input.h>
- #include "xlat/evdev_abs.h"
-diff --git a/ioctl.c b/ioctl.c
-index 46f8334..c67d048 100644
---- a/ioctl.c
-+++ b/ioctl.c
-@@ -29,7 +29,7 @@
-  */
- 
- #include "defs.h"
--#include <asm/ioctl.h>
-+#include <linux/ioctl.h>
- #include "xlat/ioctl_dirs.h"
- 
- #ifdef HAVE_LINUX_INPUT_H
-diff --git a/ioctlsort.c b/ioctlsort.c
-index 333556c..9c31691 100644
---- a/ioctlsort.c
-+++ b/ioctlsort.c
-@@ -33,7 +33,7 @@
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
--#include <asm/ioctl.h>
-+#include <linux/ioctl.h>
- 
- struct ioctlent {
- 	const char *info;
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/Include-sys-stat.h-for-S_I-macros.patch b/yocto-poky/meta/recipes-devtools/strace/strace/Include-sys-stat.h-for-S_I-macros.patch
deleted file mode 100644
index 0b072fe..0000000
--- a/yocto-poky/meta/recipes-devtools/strace/strace/Include-sys-stat.h-for-S_I-macros.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-Upstream-Status: Backport
-
-  http://sourceforge.net/p/strace/code/ci/d34e00b293942b1012ddc49ed3ab379a32337611
-
-Expected to be released officially as part of strace 4.11
-
-Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
-
-From d34e00b293942b1012ddc49ed3ab379a32337611 Mon Sep 17 00:00:00 2001
-From: Felix Janda <felix.janda@posteo.de>
-Date: Sat, 28 Mar 2015 18:21:09 +0100
-Subject: [PATCH] Include <sys/stat.h> for S_I* macros
-
-Fix a compilation failure with musl libc.
-
-* mknod.c: Include <sys/stat.h>.
-* printmode.c: Likewise.
-
-Reported-by: Dima Krasner <dima@dimakrasner.com>
-Acked-by: Mike Frysinger <vapier@gentoo.org>
----
- mknod.c     | 1 +
- printmode.c | 1 +
- 2 files changed, 2 insertions(+)
-
-diff --git a/mknod.c b/mknod.c
-index 07e9a45..1463232 100644
---- a/mknod.c
-+++ b/mknod.c
-@@ -1,6 +1,7 @@
- #include "defs.h"
- 
- #include <fcntl.h>
-+#include <sys/stat.h>
- 
- #ifdef MAJOR_IN_SYSMACROS
- # include <sys/sysmacros.h>
-diff --git a/printmode.c b/printmode.c
-index 4df1b9f..a721936 100644
---- a/printmode.c
-+++ b/printmode.c
-@@ -1,6 +1,7 @@
- #include "defs.h"
- 
- #include <fcntl.h>
-+#include <sys/stat.h>
- 
- #include "xlat/modetypes.h"
- 
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/Makefile-ptest.patch b/yocto-poky/meta/recipes-devtools/strace/strace/Makefile-ptest.patch
index f360301..824031e 100644
--- a/yocto-poky/meta/recipes-devtools/strace/strace/Makefile-ptest.patch
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/Makefile-ptest.patch
@@ -10,32 +10,32 @@
  2 files changed, 19 insertions(+), 1 deletion(-)
 
 diff --git a/configure.ac b/configure.ac
-index e73958c..5f0dfee 100644
+index 0209bac..b969e25 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -6,7 +6,7 @@ AC_INIT([strace],
+@@ -36,7 +36,7 @@ AC_INIT([strace],
  AC_CONFIG_SRCDIR([strace.c])
  AC_CONFIG_AUX_DIR([.])
  AC_CONFIG_HEADERS([config.h])
--AM_INIT_AUTOMAKE([foreign dist-xz no-dist-gzip silent-rules parallel-tests])
-+AM_INIT_AUTOMAKE([foreign dist-xz no-dist-gzip silent-rules serial-tests])
+-AM_INIT_AUTOMAKE([foreign nostdinc dist-xz no-dist-gzip silent-rules parallel-tests])
++AM_INIT_AUTOMAKE([foreign nostdinc dist-xz no-dist-gzip silent-rules serial-tests])
  AM_MAINTAINER_MODE
  AC_CANONICAL_HOST
  
 diff --git a/tests/Makefile.am b/tests/Makefile.am
-index ff5e136..984bdb6 100644
+index 0f23b4b..429f7e9 100644
 --- a/tests/Makefile.am
 +++ b/tests/Makefile.am
-@@ -101,3 +101,21 @@ EXTRA_DIST = init.sh run.sh \
- 	     $(TESTS)
+@@ -332,3 +332,21 @@ ksysent.h: $(srcdir)/ksysent.sed
  
- CLEANFILES = $(TESTS:=.tmp)
+ BUILT_SOURCES = ksysent.h
+ CLEANFILES = ksysent.h $(TESTS:=.tmp)
 +
 +buildtest-TESTS: $(check_PROGRAMS) $(TESTS)
 +
 +install-ptest:
 +	install $(BUILDDIR)/strace $(DESTDIR)
-+	install "$(srcdir)/.."/strace-log-merge $(DESTDIR)
++	install $(srcdir)/../strace-log-merge $(DESTDIR)
 +	install -d $(DESTDIR)/$(TESTDIR)
 +	cp $(BUILDDIR)/$(TESTDIR)/Makefile $(DESTDIR)/$(TESTDIR)
 +	sed -i -e 's/^Makefile:/_Makefile:/' $(DESTDIR)/$(TESTDIR)/Makefile
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/disable-git-version-gen.patch b/yocto-poky/meta/recipes-devtools/strace/strace/disable-git-version-gen.patch
new file mode 100644
index 0000000..7bc1436
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/disable-git-version-gen.patch
@@ -0,0 +1,20 @@
+The git-version-gen script is not included in tarball releases,
+so we need to avoid attempts to call it when running autoreconf.
+
+Upstream-Status: Inappropriate [configuration]
+
+Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+
+Index: strace-4.10/configure.ac
+===================================================================
+--- strace-4.10.orig/configure.ac
++++ strace-4.10/configure.ac
+@@ -1,7 +1,7 @@
+ dnl Process this file with autoconf to create configure.  Use autoreconf.
+ AC_PREREQ(2.57)
+ AC_INIT([strace],
+-	m4_esyscmd([./git-version-gen .tarball-version]),
++	m4_esyscmd_s([cat .tarball-version]),
+ 	[strace-devel@lists.sourceforge.net])
+ AC_CONFIG_SRCDIR([strace.c])
+ AC_CONFIG_AUX_DIR([.])
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/git-version-gen b/yocto-poky/meta/recipes-devtools/strace/strace/git-version-gen
deleted file mode 100755
index 8fee74e..0000000
--- a/yocto-poky/meta/recipes-devtools/strace/strace/git-version-gen
+++ /dev/null
@@ -1,225 +0,0 @@
-#!/bin/sh
-# Print a version string.
-scriptversion=2012-12-31.23; # UTC
-
-# Copyright (C) 2007-2013 Free Software Foundation, Inc.
-#
-# 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 3 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, see <http://www.gnu.org/licenses/>.
-
-# This script is derived from GIT-VERSION-GEN from GIT: http://git.or.cz/.
-# It may be run two ways:
-# - from a git repository in which the "git describe" command below
-#   produces useful output (thus requiring at least one signed tag)
-# - from a non-git-repo directory containing a .tarball-version file, which
-#   presumes this script is invoked like "./git-version-gen .tarball-version".
-
-# In order to use intra-version strings in your project, you will need two
-# separate generated version string files:
-#
-# .tarball-version - present only in a distribution tarball, and not in
-#   a checked-out repository.  Created with contents that were learned at
-#   the last time autoconf was run, and used by git-version-gen.  Must not
-#   be present in either $(srcdir) or $(builddir) for git-version-gen to
-#   give accurate answers during normal development with a checked out tree,
-#   but must be present in a tarball when there is no version control system.
-#   Therefore, it cannot be used in any dependencies.  GNUmakefile has
-#   hooks to force a reconfigure at distribution time to get the value
-#   correct, without penalizing normal development with extra reconfigures.
-#
-# .version - present in a checked-out repository and in a distribution
-#   tarball.  Usable in dependencies, particularly for files that don't
-#   want to depend on config.h but do want to track version changes.
-#   Delete this file prior to any autoconf run where you want to rebuild
-#   files to pick up a version string change; and leave it stale to
-#   minimize rebuild time after unrelated changes to configure sources.
-#
-# As with any generated file in a VC'd directory, you should add
-# /.version to .gitignore, so that you don't accidentally commit it.
-# .tarball-version is never generated in a VC'd directory, so needn't
-# be listed there.
-#
-# Use the following line in your configure.ac, so that $(VERSION) will
-# automatically be up-to-date each time configure is run (and note that
-# since configure.ac no longer includes a version string, Makefile rules
-# should not depend on configure.ac for version updates).
-#
-# AC_INIT([GNU project],
-#         m4_esyscmd([build-aux/git-version-gen .tarball-version]),
-#         [bug-project@example])
-#
-# Then use the following lines in your Makefile.am, so that .version
-# will be present for dependencies, and so that .version and
-# .tarball-version will exist in distribution tarballs.
-#
-# EXTRA_DIST = $(top_srcdir)/.version
-# BUILT_SOURCES = $(top_srcdir)/.version
-# $(top_srcdir)/.version:
-#	echo $(VERSION) > $@-t && mv $@-t $@
-# dist-hook:
-#	echo $(VERSION) > $(distdir)/.tarball-version
-
-
-me=$0
-
-version="git-version-gen $scriptversion
-
-Copyright 2011 Free Software Foundation, Inc.
-There is NO warranty.  You may redistribute this software
-under the terms of the GNU General Public License.
-For more information about these matters, see the files named COPYING."
-
-usage="\
-Usage: $me [OPTION]... \$srcdir/.tarball-version [TAG-NORMALIZATION-SED-SCRIPT]
-Print a version string.
-
-Options:
-
-   --prefix           prefix of git tags (default 'v')
-   --fallback         fallback version to use if \"git --version\" fails
-
-   --help             display this help and exit
-   --version          output version information and exit
-
-Running without arguments will suffice in most cases."
-
-prefix=v
-fallback=
-
-while test $# -gt 0; do
-  case $1 in
-    --help) echo "$usage"; exit 0;;
-    --version) echo "$version"; exit 0;;
-    --prefix) shift; prefix="$1";;
-    --fallback) shift; fallback="$1";;
-    -*)
-      echo "$0: Unknown option '$1'." >&2
-      echo "$0: Try '--help' for more information." >&2
-      exit 1;;
-    *)
-      if test "x$tarball_version_file" = x; then
-        tarball_version_file="$1"
-      elif test "x$tag_sed_script" = x; then
-        tag_sed_script="$1"
-      else
-        echo "$0: extra non-option argument '$1'." >&2
-        exit 1
-      fi;;
-  esac
-  shift
-done
-
-if test "x$tarball_version_file" = x; then
-    echo "$usage"
-    exit 1
-fi
-
-tag_sed_script="${tag_sed_script:-s/x/x/}"
-
-nl='
-'
-
-# Avoid meddling by environment variable of the same name.
-v=
-v_from_git=
-
-# First see if there is a tarball-only version file.
-# then try "git describe", then default.
-if test -f $tarball_version_file
-then
-    v=`cat $tarball_version_file` || v=
-    case $v in
-        *$nl*) v= ;; # reject multi-line output
-        [0-9]*) ;;
-        *) v= ;;
-    esac
-    test "x$v" = x \
-        && echo "$0: WARNING: $tarball_version_file is missing or damaged" 1>&2
-fi
-
-if test "x$v" != x
-then
-    : # use $v
-# Otherwise, if there is at least one git commit involving the working
-# directory, and "git describe" output looks sensible, use that to
-# derive a version string.
-elif test "`git log -1 --pretty=format:x . 2>&1`" = x \
-    && v=`git describe --abbrev=4 --match="$prefix*" HEAD 2>/dev/null \
-          || git describe --abbrev=4 HEAD 2>/dev/null` \
-    && v=`printf '%s\n' "$v" | sed "$tag_sed_script"` \
-    && case $v in
-         $prefix[0-9]*) ;;
-         *) (exit 1) ;;
-       esac
-then
-    # Is this a new git that lists number of commits since the last
-    # tag or the previous older version that did not?
-    #   Newer: v6.10-77-g0f8faeb
-    #   Older: v6.10-g0f8faeb
-    case $v in
-        *-*-*) : git describe is okay three part flavor ;;
-        *-*)
-            : git describe is older two part flavor
-            # Recreate the number of commits and rewrite such that the
-            # result is the same as if we were using the newer version
-            # of git describe.
-            vtag=`echo "$v" | sed 's/-.*//'`
-            commit_list=`git rev-list "$vtag"..HEAD 2>/dev/null` \
-                || { commit_list=failed;
-                     echo "$0: WARNING: git rev-list failed" 1>&2; }
-            numcommits=`echo "$commit_list" | wc -l`
-            v=`echo "$v" | sed "s/\(.*\)-\(.*\)/\1-$numcommits-\2/"`;
-            test "$commit_list" = failed && v=UNKNOWN
-            ;;
-    esac
-
-    # Change the first '-' to a '.', so version-comparing tools work properly.
-    # Remove the "g" in git describe's output string, to save a byte.
-    v=`echo "$v" | sed 's/-/.0./;s/\(.*\)-g/\1-/'`;
-    v_from_git=1
-elif test "x$fallback" = x || git --version >/dev/null 2>&1; then
-    v=UNKNOWN
-else
-    v=$fallback
-fi
-
-v=`echo "$v" |sed "s/^$prefix//"`
-
-# Test whether to append the "-dirty" suffix only if the version
-# string we're using came from git.  I.e., skip the test if it's "UNKNOWN"
-# or if it came from .tarball-version.
-if test "x$v_from_git" != x; then
-  # Don't declare a version "dirty" merely because a time stamp has changed.
-  git update-index --refresh > /dev/null 2>&1
-
-  dirty=`exec 2>/dev/null;git diff-index --name-only HEAD` || dirty=
-  case "$dirty" in
-      '') ;;
-      *) # Append the suffix only if there isn't one already.
-          case $v in
-            *-dirty) ;;
-            *) v="$v-dirty" ;;
-          esac ;;
-  esac
-fi
-
-# Omit the trailing newline, so that m4_esyscmd can use the result directly.
-echo "$v" | tr -d "$nl"
-
-# Local variables:
-# eval: (add-hook 'write-file-hooks 'time-stamp)
-# time-stamp-start: "scriptversion="
-# time-stamp-format: "%:y-%02m-%02d.%02H"
-# time-stamp-time-zone: "UTC"
-# time-stamp-end: "; # UTC"
-# End:
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/more-robust-test-for-m32-mx32-compile-support.patch b/yocto-poky/meta/recipes-devtools/strace/strace/more-robust-test-for-m32-mx32-compile-support.patch
new file mode 100644
index 0000000..756cd8b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/more-robust-test-for-m32-mx32-compile-support.patch
@@ -0,0 +1,46 @@
+From 154af50ed7ed8b91838d713052ebf29b0b14f765 Mon Sep 17 00:00:00 2001
+From: Andre McCurdy <armccurdy@gmail.com>
+Date: Mon, 18 Jan 2016 11:00:00 -0800
+Subject: [PATCH] mpers.m4: more robust test for -m32/-mx32 compile support
+
+When using the default OE toolchain for x86-64, the basic checks for
+-m32 and -mx32 compile support in mpers.m4 pass but later attempts to
+actually use the toolchain with -m32 fail, e.g.
+
+ | In file included from /home/andre/build/tmp/sysroots/qemux86-64/usr/include/sys/syscall.h:31:0,
+ |                  from ../strace-4.11/defs.h:55,
+ |                  from mpers-m32/kernel_dirent.c:32:
+ | /home/andre/build/tmp/sysroots/qemux86-64/usr/include/bits/syscall.h:41:29: fatal error: bits/syscall-32.h: No such file or directory
+
+Make the mpers.m4 tests more robust so that configure correctly
+detects the limitations of the OE toolchain.
+
+Upstream-Status: Pending
+
+Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+---
+ m4/mpers.m4 | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/m4/mpers.m4 b/m4/mpers.m4
+index 1fe8a8e..d72c717 100644
+--- a/m4/mpers.m4
++++ b/m4/mpers.m4
+@@ -53,12 +53,14 @@ case "$arch" in
+ 	CFLAGS="$CFLAGS CFLAG $IFLAG"
+ 	AC_CACHE_CHECK([for CFLAG compile support], [st_cv_cc],
+ 		[AC_COMPILE_IFELSE([AC_LANG_SOURCE([[#include <stdint.h>
++						     #include <sys/syscall.h>
+ 						     int main(){return 0;}]])],
+ 				   [st_cv_cc=yes],
+ 				   [st_cv_cc=no])])
+ 	if test $st_cv_cc = yes; then
+ 		AC_CACHE_CHECK([for CFLAG runtime support], [st_cv_runtime],
+ 			[AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdint.h>
++							 #include <sys/syscall.h>
+ 							 int main(){return 0;}]])],
+ 				       [st_cv_runtime=yes],
+ 				       [st_cv_runtime=no],
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/strace-add-configure-options.patch b/yocto-poky/meta/recipes-devtools/strace/strace/strace-add-configure-options.patch
deleted file mode 100644
index e48e4b3..0000000
--- a/yocto-poky/meta/recipes-devtools/strace/strace/strace-add-configure-options.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-Add options "aio" and "acl" to enable/disable libaio and acl support.
-
-Upstream-Status: Pending
-
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
-Signed-off-by: Chong Lu <Chong.Lu@windriver.com>
----
- configure.ac |   26 ++++++++++++++++++++++++++
- 1 file changed, 26 insertions(+)
-
-diff --git a/configure.ac b/configure.ac
-index e73958c..9099370 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -270,6 +270,18 @@ AC_CHECK_HEADERS(m4_normalize([
- 	sys/vfs.h
- 	sys/xattr.h
- ]))
-+
-+AC_ARG_ENABLE([acl],
-+	[AS_HELP_STRING([--enable-acl], [turn on acl support])],
-+	[case $enableval in
-+	yes)
-+		AC_CHECK_HEADERS([sys/acl.h])
-+		;;
-+	no)  ;;
-+	*)   AC_MSG_ERROR([bad value $enableval for aio option]) ;;
-+	esac]
-+)
-+
- AC_CHECK_HEADERS([linux/icmp.h linux/in6.h linux/netlink.h linux/if_packet.h],
-                  [], [], [#include <stddef.h>
- #include <sys/socket.h>
-@@ -745,6 +757,20 @@ if test "x$ac_cv_lib_dl_dladdr" = xyes; then
- fi
- AC_SUBST(dl_LIBS)
- 
-+AC_ARG_ENABLE([aio],
-+	[AS_HELP_STRING([--enable-aio], [turn on libaio support])],
-+	[case $enableval in
-+	yes)
-+	AC_CHECK_HEADERS([libaio.h], [
-+		AC_CHECK_MEMBERS([struct iocb.u.c.flags],,, [#include <libaio.h>])
-+		AC_CHECK_DECLS([IO_CMD_PWRITE, IO_CMD_PWRITEV],,, [#include <libaio.h>])
-+	])
-+	;;
-+	no)  ;;
-+	*)   AC_MSG_ERROR([bad value $enableval for aio option]) ;;
-+	esac]
-+)
-+
- AC_PATH_PROG([PERL], [perl])
- 
- dnl stack trace with libunwind
---
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/update-gawk-paths.patch b/yocto-poky/meta/recipes-devtools/strace/strace/update-gawk-paths.patch
new file mode 100644
index 0000000..bfc7f34
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/update-gawk-paths.patch
@@ -0,0 +1,118 @@
+From 3836518c46bd5bb3e71371b1b18274bf2d487133 Mon Sep 17 00:00:00 2001
+From: Andre McCurdy <armccurdy@gmail.com>
+Date: Mon, 18 Jan 2016 11:01:00 -0800
+Subject: [PATCH] update gawk paths, /bin/gawk -> /usr/bin/gawk
+
+The default path to gawk is /usr/bin/gawk, so update test scripts etc
+from #!/bin/gawk to #!/usr/bin/gawk. Fixes missing RDPENDS QA tests:
+
+  WARNING: QA Issue: /usr/lib/strace/ptest/tests/unix-yy-accept.awk_strace-ptest contained in package strace-ptest requires /bin/gawk, but no providers found in its RDEPENDS [file-rdeps]
+
+Upstream-Status: Inappropriate [configuration]
+
+Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+---
+ mpers.awk                 | 2 +-
+ tests/caps.awk            | 2 +-
+ tests/match.awk           | 2 +-
+ tests/net-yy-accept.awk   | 2 +-
+ tests/net-yy-connect.awk  | 2 +-
+ tests/sigaction.awk       | 2 +-
+ tests/uid.awk             | 2 +-
+ tests/unix-yy-accept.awk  | 2 +-
+ tests/unix-yy-connect.awk | 2 +-
+ 9 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/mpers.awk b/mpers.awk
+index 73bf0b0..50e6c16 100644
+--- a/mpers.awk
++++ b/mpers.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
+ # Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+diff --git a/tests/caps.awk b/tests/caps.awk
+index bad8b0f..845f37c 100644
+--- a/tests/caps.awk
++++ b/tests/caps.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ # All rights reserved.
+diff --git a/tests/match.awk b/tests/match.awk
+index abfbae9..f2740bf 100644
+--- a/tests/match.awk
++++ b/tests/match.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ # All rights reserved.
+diff --git a/tests/net-yy-accept.awk b/tests/net-yy-accept.awk
+index fed3e30..e916ab0 100644
+--- a/tests/net-yy-accept.awk
++++ b/tests/net-yy-accept.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # Copyright (c) 2014 Masatake YAMATO <yamato@redhat.com>
+ # Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+diff --git a/tests/net-yy-connect.awk b/tests/net-yy-connect.awk
+index f4dcf91..b3cec8c 100644
+--- a/tests/net-yy-connect.awk
++++ b/tests/net-yy-connect.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # Copyright (c) 2014 Masatake YAMATO <yamato@redhat.com>
+ # Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+diff --git a/tests/sigaction.awk b/tests/sigaction.awk
+index 5c6b6d0..3e14464 100644
+--- a/tests/sigaction.awk
++++ b/tests/sigaction.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ # All rights reserved.
+diff --git a/tests/uid.awk b/tests/uid.awk
+index a56c5be..67b0749 100644
+--- a/tests/uid.awk
++++ b/tests/uid.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+ # All rights reserved.
+diff --git a/tests/unix-yy-accept.awk b/tests/unix-yy-accept.awk
+index 4ed60e4..2a9d9c0 100644
+--- a/tests/unix-yy-accept.awk
++++ b/tests/unix-yy-accept.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # Copyright (c) 2014 Masatake YAMATO <yamato@redhat.com>
+ # Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+diff --git a/tests/unix-yy-connect.awk b/tests/unix-yy-connect.awk
+index 262bf2e..c809dfa 100644
+--- a/tests/unix-yy-connect.awk
++++ b/tests/unix-yy-connect.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # Copyright (c) 2014 Masatake YAMATO <yamato@redhat.com>
+ # Copyright (c) 2014-2015 Dmitry V. Levin <ldv@altlinux.org>
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace/use-asm-sgidefs.h.patch b/yocto-poky/meta/recipes-devtools/strace/strace/use-asm-sgidefs.h.patch
new file mode 100644
index 0000000..db83d11
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace/use-asm-sgidefs.h.patch
@@ -0,0 +1,51 @@
+From 2995245d7e3f46e8b3995002995ebd28beca7d55 Mon Sep 17 00:00:00 2001
+From: Andre McCurdy <armccurdy@gmail.com>
+Date: Fri, 5 Feb 2016 14:00:00 -0800
+Subject: [PATCH] use <asm/sgidefs.h>
+
+Build fix for MIPS with musl libc.
+
+The MIPS specific header <sgidefs.h> is provided by glibc and uclibc
+but not by musl. Regardless of the libc, the kernel headers provide
+<asm/sgidefs.h> which provides the same definitions, so use that
+instead.
+
+Upstream-Status: Pending
+
+Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+---
+ configure.ac | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 1524b9b..287e03d 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -196,20 +196,20 @@ AC_SUBST(arch_mx32)
+ if test "$arch" = mips; then
+ 	AC_CACHE_CHECK([for _MIPS_SIM], [st_cv__MIPS_SIM],
+ 		       [AC_COMPUTE_INT([st_cv__MIPS_SIM], [_MIPS_SIM],
+-				       [#include <sgidefs.h>],
++				       [#include <asm/sgidefs.h>],
+ 				       [AC_MSG_ERROR([_MIPS_SIM cannot be determined])])])
+ 
+ 	AC_CACHE_CHECK([for MIPS ABI], [st_cv_mips_abi],
+ 		[AC_COMPILE_IFELSE(
+-			[AC_LANG_PROGRAM([[#include <sgidefs.h>]],
++			[AC_LANG_PROGRAM([[#include <asm/sgidefs.h>]],
+ 					 [[int i[_MIPS_SIM == _MIPS_SIM_ABI32 ? 1 : - 1];]])],
+ 			[st_cv_mips_abi=o32],
+ 		[AC_COMPILE_IFELSE(
+-			[AC_LANG_PROGRAM([[#include <sgidefs.h>]],
++			[AC_LANG_PROGRAM([[#include <asm/sgidefs.h>]],
+ 					 [[int i[_MIPS_SIM == _MIPS_SIM_NABI32 ? 1 : - 1];]])],
+ 			[st_cv_mips_abi=n32],
+ 		[AC_COMPILE_IFELSE(
+-			[AC_LANG_PROGRAM([[#include <sgidefs.h>]],
++			[AC_LANG_PROGRAM([[#include <asm/sgidefs.h>]],
+ 					 [[int i[_MIPS_SIM == _MIPS_SIM_ABI64 ? 1 : - 1];]])],
+ 			[st_cv_mips_abi=n64],
+ 			[st_cv_mips_abi=unknown])])])])
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace_4.10.bb b/yocto-poky/meta/recipes-devtools/strace/strace_4.10.bb
deleted file mode 100644
index 20b7e3d..0000000
--- a/yocto-poky/meta/recipes-devtools/strace/strace_4.10.bb
+++ /dev/null
@@ -1,52 +0,0 @@
-SUMMARY = "System call tracing tool"
-HOMEPAGE = "http://strace.sourceforge.net"
-SECTION = "console/utils"
-LICENSE = "BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=124500c21e856f0912df29295ba104c7"
-
-SRC_URI = "${SOURCEFORGE_MIRROR}/strace/strace-${PV}.tar.xz \
-           file://0001-Add-linux-aarch64-arch_regs.h.patch \
-           file://git-version-gen \
-           file://strace-add-configure-options.patch \
-           file://Makefile-ptest.patch \
-           file://run-ptest \
-           file://Include-sys-stat.h-for-S_I-macros.patch \
-           file://Include-linux-ioctl.h-for-_IOC_-macros.patch \
-          "
-
-SRC_URI[md5sum] = "107a5be455493861189e9b57a3a51912"
-SRC_URI[sha256sum] = "e6180d866ef9e76586b96e2ece2bfeeb3aa23f5cc88153f76e9caedd65e40ee2"
-
-inherit autotools ptest bluetooth
-RDEPENDS_${PN}-ptest += "make coreutils grep gawk"
-
-PACKAGECONFIG_class-target ??= "\
-    libaio ${@bb.utils.contains('DISTRO_FEATURES', 'acl', 'acl', '', d)} \
-    ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \
-"
-
-PACKAGECONFIG[libaio] = "--enable-aio,--disable-aio,libaio"
-PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl"
-PACKAGECONFIG[libunwind] = "--with-libunwind, --without-libunwind, libunwind"
-PACKAGECONFIG[bluez] = "ac_cv_header_bluetooth_bluetooth_h=yes,ac_cv_header_bluetooth_bluetooth_h=no,${BLUEZ}"
-
-TESTDIR = "tests"
-
-do_configure_prepend() {
-	cp ${WORKDIR}/git-version-gen ${S}
-}
-
-do_install_append() {
-	# We don't ship strace-graph here because it needs perl
-	rm ${D}${bindir}/strace-graph
-}
-
-do_compile_ptest() {
-	oe_runmake -C ${TESTDIR} buildtest-TESTS OS=linux ARCH="${TARGET_ARCH}"
-}
-
-do_install_ptest() {
-	oe_runmake -C ${TESTDIR} install-ptest BUILDDIR=${B} DESTDIR=${D}${PTEST_PATH} TESTDIR=${TESTDIR}
-}
-
-BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/strace/strace_4.11.bb b/yocto-poky/meta/recipes-devtools/strace/strace_4.11.bb
new file mode 100644
index 0000000..7391388
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/strace/strace_4.11.bb
@@ -0,0 +1,51 @@
+SUMMARY = "System call tracing tool"
+HOMEPAGE = "http://strace.sourceforge.net"
+SECTION = "console/utils"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=124500c21e856f0912df29295ba104c7"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/strace/strace-${PV}.tar.xz \
+           file://disable-git-version-gen.patch \
+           file://more-robust-test-for-m32-mx32-compile-support.patch \
+           file://update-gawk-paths.patch \
+           file://use-asm-sgidefs.h.patch \
+           file://0001-arc-metag-nios2-or1k-tile-fix-build.patch \
+           file://Makefile-ptest.patch \
+           file://0001-tests-scm_rights.c-use-libtests.patch \
+           file://0001-scm_rights-fd.test-rewrite-without-fork.patch \
+           file://0001-Move-gcc-compat-macros-to-gcc_compat.h.patch \
+           file://0001-tests-introduce-libtests.patch \
+           file://run-ptest \
+          "
+
+SRC_URI[md5sum] = "a15d2555a7febb56d00c6e1a51c655dc"
+SRC_URI[sha256sum] = "e86a5f6cd8f941f67f3e4b28f4e60f3d9185c951cf266404533210a2e5cd8152"
+
+inherit autotools ptest bluetooth
+
+RDEPENDS_${PN}-ptest += "make coreutils grep gawk sed"
+
+PACKAGECONFIG_class-target ??= "\
+    ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \
+"
+
+PACKAGECONFIG[bluez] = "ac_cv_header_bluetooth_bluetooth_h=yes,ac_cv_header_bluetooth_bluetooth_h=no,${BLUEZ}"
+PACKAGECONFIG[libunwind] = "--with-libunwind,--without-libunwind,libunwind"
+
+TESTDIR = "tests"
+
+do_install_append() {
+	# We don't ship strace-graph here because it needs perl
+	rm ${D}${bindir}/strace-graph
+}
+
+do_compile_ptest() {
+	oe_runmake -C ${TESTDIR} buildtest-TESTS
+}
+
+do_install_ptest() {
+	oe_runmake -C ${TESTDIR} install-ptest BUILDDIR=${B} DESTDIR=${D}${PTEST_PATH} TESTDIR=${TESTDIR}
+	sed -i -e '/^src/s/strace.*[1-9]/ptest/' ${D}/${PTEST_PATH}/${TESTDIR}/Makefile
+}
+
+BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/libtool2.patch b/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/libtool2.patch
deleted file mode 100644
index 5cd572b..0000000
--- a/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/libtool2.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Upstream-Status: Inappropriate [embedded specific]
-
---- a/configure.ac	2011-10-20 21:56:02.230663987 +0200
-+++ b/configure.ac	2011-08-17 15:01:30.000000000 +0200
-@@ -227,8 +227,8 @@
-   LIBTOOL="$sh_libtool"
-   SVN_LIBTOOL="$sh_libtool"
- else
--  sh_libtool="$abs_builddir/libtool"
--  SVN_LIBTOOL="\$(SHELL) $sh_libtool"
-+  sh_libtool="$abs_builddir/$host_alias-libtool"
-+  SVN_LIBTOOL="\$(SHELL) \$(abs_builddir)/$host_alias-libtool"
- fi
- AC_SUBST(SVN_LIBTOOL)
- 
diff --git a/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/serf.m4-Regex-modified-to-allow-D-in-paths.patch b/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/serf.m4-Regex-modified-to-allow-D-in-paths.patch
deleted file mode 100644
index 140e522..0000000
--- a/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/serf.m4-Regex-modified-to-allow-D-in-paths.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From f1b6e49f12a18eabe88eb732b578a16281d09499 Mon Sep 17 00:00:00 2001
-From: Jose Lamego <jose.a.lamego@linux.intel.com>
-Date: Thu, 2 Jul 2015 11:37:43 +0000
-Subject: [PATCH] serf.m4: Regex modified to allow '-D' in paths
-
-Upstream-Status: Accepted
-
-The patch is merged by subversion upstream with replacing '[[:space:]]' with ' '.
-
-http://svn.apache.org/viewvc/subversion/trunk/build/ac-macros/serf.m4?r1=1594156&r2=1689824  
-
-Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
----
- build/ac-macros/serf.m4 | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/build/ac-macros/serf.m4 b/build/ac-macros/serf.m4
-index ae11e75..ff8cbae 100644
---- a/build/ac-macros/serf.m4
-+++ b/build/ac-macros/serf.m4
-@@ -143,7 +143,7 @@ AC_DEFUN(SVN_SERF_PKG_CONFIG,
-         if $PKG_CONFIG $serf_major --atleast-version=$serf_check_version; then
-           AC_MSG_RESULT([yes])
-           serf_found=yes
--          SVN_SERF_INCLUDES=[`$PKG_CONFIG $serf_major --cflags | $SED -e 's/-D[^ ]*//g'`]
-+          SVN_SERF_INCLUDES=[`$PKG_CONFIG $serf_major --cflags | $SED -e 's/[[:space:]]-D[^ ]*//g' -e 's/^-D[^ ]*//g'`]
-           SVN_SERF_LIBS=`$PKG_CONFIG $serf_major --libs` 
-           break
-         else
--- 
-1.8.4.5
-
diff --git a/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/subversion-CVE-2015-3184.patch b/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/subversion-CVE-2015-3184.patch
deleted file mode 100644
index 0663bd2..0000000
--- a/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/subversion-CVE-2015-3184.patch
+++ /dev/null
@@ -1,2094 +0,0 @@
-Fix CVE-2015-3184
-
-Patch is from:
-http://subversion.apache.org/security/CVE-2015-3184-advisory.txt
-
-Upstream-Status: Backport
-
-Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
-
-Index: Makefile.in
-===================================================================
---- a/Makefile.in	(revision 1691883)
-+++ b/Makefile.in	(working copy)
-@@ -357,6 +357,7 @@ TEST_SHLIB_VAR_SWIG_RB=\
-   fi;
- 
- APXS = @APXS@
-+HTTPD_VERSION = @HTTPD_VERSION@
- 
- PYTHON = @PYTHON@
- PERL = @PERL@
-@@ -509,6 +510,9 @@ check: bin @TRANSFORM_LIBTOOL_SCRIPTS@ $(TEST_DEPS
- 	  if test "$(HTTP_LIBRARY)" != ""; then                              \
- 	    flags="--http-library $(HTTP_LIBRARY) $$flags";                  \
- 	  fi;                                                                \
-+	  if test "$(HTTPD_VERSION)" != ""; then                              \
-+	    flags="--httpd-version $(HTTPD_VERSION) $$flags";                  \
-+	  fi;                                                                \
- 	  if test "$(SERVER_MINOR_VERSION)" != ""; then                      \
- 	    flags="--server-minor-version $(SERVER_MINOR_VERSION) $$flags";  \
- 	  fi;                                                                \
-Index: build/ac-macros/apache.m4
-===================================================================
---- a/build/ac-macros/apache.m4	(revision 1691883)
-+++ b/build/ac-macros/apache.m4	(working copy)
-@@ -160,6 +160,20 @@ if test -n "$APXS" && test "$APXS" != "no"; then
-     BUILD_APACHE_RULE=apache-mod
-     INSTALL_APACHE_RULE=install-mods-shared
-     INSTALL_APACHE_MODS=true
-+    HTTPD="`$APXS -q sbindir`/`$APXS -q PROGNAME`"
-+    if ! test -e $HTTPD ; then
-+      HTTPD="`$APXS -q bindir`/`$APXS -q PROGNAME`"
-+    fi
-+    HTTPD_VERSION=["`$HTTPD -v | $SED -e 's@^.*/\([0-9.]*\)\(.*$\)@\1@ ; 1q'`"]
-+    AC_ARG_ENABLE(broken-httpd-auth,
-+      AS_HELP_STRING([--enable-broken-httpd-auth],
-+                     [Allow building against httpd 2.4 with broken auth]),
-+      [broken_httpd_auth=$enableval],[broken_httpd_auth=no])
-+    if test "$enable_broken_httpd_auth" = "yes"; then
-+      AC_MSG_NOTICE([Building with broken httpd auth])
-+      AC_DEFINE(SVN_ALLOW_BROKEN_HTTPD_AUTH, 1,
-+                [Defined to allow building against httpd 2.4 with broken auth])
-+    fi
- 
-     case $host in
-       *-*-cygwin*)
-@@ -178,6 +192,7 @@ AC_SUBST(APACHE_LDFLAGS)
- AC_SUBST(APACHE_INCLUDES)
- AC_SUBST(APACHE_LIBEXECDIR)
- AC_SUBST(INSTALL_APACHE_MODS)
-+AC_SUBST(HTTPD_VERSION)
- 
- # there aren't any flags that interest us ...
- #if test -n "$APXS" && test "$APXS" != "no"; then
-Index: build/run_tests.py
-===================================================================
---- a/build/run_tests.py	(revision 1691883)
-+++ b/build/run_tests.py	(working copy)
-@@ -29,6 +29,7 @@
-             [--fs-type=<fs-type>] [--fsfs-packing] [--fsfs-sharding=<n>]
-             [--list] [--milestone-filter=<regex>] [--mode-filter=<type>]
-             [--server-minor-version=<version>] [--http-proxy=<host>:<port>]
-+            [--httpd-version=<version>]
-             [--config-file=<file>] [--ssl-cert=<file>]
-             <abs_srcdir> <abs_builddir>
-             <prog ...>
-@@ -125,7 +126,7 @@ class TestHarness:
-                fsfs_sharding=None, fsfs_packing=None,
-                list_tests=None, svn_bin=None, mode_filter=None,
-                milestone_filter=None, set_log_level=None, ssl_cert=None,
--               http_proxy=None):
-+               http_proxy=None, httpd_version=None):
-     '''Construct a TestHarness instance.
- 
-     ABS_SRCDIR and ABS_BUILDDIR are the source and build directories.
-@@ -178,6 +179,7 @@ class TestHarness:
-     self.log = None
-     self.ssl_cert = ssl_cert
-     self.http_proxy = http_proxy
-+    self.httpd_version = httpd_version
-     if not sys.stdout.isatty() or sys.platform == 'win32':
-       TextColors.disable()
- 
-@@ -481,6 +483,8 @@ class TestHarness:
-       svntest.main.options.ssl_cert = self.ssl_cert
-     if self.http_proxy is not None:
-       svntest.main.options.http_proxy = self.http_proxy
-+    if self.httpd_version is not None:
-+      svntest.main.options.httpd_version = self.httpd_version
- 
-     svntest.main.options.srcdir = self.srcdir
- 
-@@ -645,7 +649,7 @@ def main():
-                             'enable-sasl', 'parallel', 'config-file=',
-                             'log-to-stdout', 'list', 'milestone-filter=',
-                             'mode-filter=', 'set-log-level=', 'ssl-cert=',
--                            'http-proxy='])
-+                            'http-proxy=', 'httpd-version='])
-   except getopt.GetoptError:
-     args = []
- 
-@@ -656,9 +660,9 @@ def main():
-   base_url, fs_type, verbose, cleanup, enable_sasl, http_library, \
-     server_minor_version, fsfs_sharding, fsfs_packing, parallel, \
-     config_file, log_to_stdout, list_tests, mode_filter, milestone_filter, \
--    set_log_level, ssl_cert, http_proxy = \
-+    set_log_level, ssl_cert, http_proxy, httpd_version = \
-             None, None, None, None, None, None, None, None, None, None, None, \
--            None, None, None, None, None, None, None
-+            None, None, None, None, None, None, None, None
-   for opt, val in opts:
-     if opt in ['-u', '--url']:
-       base_url = val
-@@ -696,6 +700,8 @@ def main():
-       ssl_cert = val
-     elif opt in ['--http-proxy']:
-       http_proxy = val
-+    elif opt in ['--httpd-version']:
-+      httpd_version = val
-     else:
-       raise getopt.GetoptError
- 
-@@ -712,7 +718,7 @@ def main():
-                    fsfs_sharding, fsfs_packing, list_tests,
-                    mode_filter=mode_filter, milestone_filter=milestone_filter,
-                    set_log_level=set_log_level, ssl_cert=ssl_cert,
--                   http_proxy=http_proxy)
-+                   http_proxy=http_proxy, httpd_version=httpd_version)
- 
-   failed = th.run(args[2:])
-   if failed:
-Index: subversion/mod_authz_svn/mod_authz_svn.c
-===================================================================
---- a/subversion/mod_authz_svn/mod_authz_svn.c	(revision 1691883)
-+++ b/subversion/mod_authz_svn/mod_authz_svn.c	(working copy)
-@@ -48,6 +48,23 @@
- #include "svn_dirent_uri.h"
- #include "private/svn_fspath.h"
- 
-+/* The apache headers define these and they conflict with our definitions. */
-+#ifdef PACKAGE_BUGREPORT
-+#undef PACKAGE_BUGREPORT
-+#endif
-+#ifdef PACKAGE_NAME
-+#undef PACKAGE_NAME
-+#endif
-+#ifdef PACKAGE_STRING
-+#undef PACKAGE_STRING
-+#endif
-+#ifdef PACKAGE_TARNAME
-+#undef PACKAGE_TARNAME
-+#endif
-+#ifdef PACKAGE_VERSION
-+#undef PACKAGE_VERSION
-+#endif
-+#include "svn_private_config.h"
- 
- #ifdef APLOG_USE_MODULE
- APLOG_USE_MODULE(authz_svn);
-@@ -67,6 +84,30 @@ typedef struct authz_svn_config_rec {
-   const char *force_username_case;
- } authz_svn_config_rec;
- 
-+#if AP_MODULE_MAGIC_AT_LEAST(20060110,0) /* version where
-+                                            ap_some_auth_required breaks */
-+#  if AP_MODULE_MAGIC_AT_LEAST(20120211,47) /* first version with
-+                                               force_authn hook and
-+                                               ap_some_authn_required() which
-+                                               allows us to work without
-+                                               ap_some_auth_required() */
-+#    define USE_FORCE_AUTHN 1
-+#    define IN_SOME_AUTHN_NOTE "authz_svn-in-some-authn"
-+#    define FORCE_AUTHN_NOTE "authz_svn-force-authn"
-+#  else
-+     /* ap_some_auth_required() is busted and no viable alternative exists */
-+#    ifndef SVN_ALLOW_BROKEN_HTTPD_AUTH
-+#      error This version of httpd has a security hole with mod_authz_svn
-+#    else
-+       /* user wants to build anyway */
-+#      define USE_FORCE_AUTHN 0
-+#    endif
-+#  endif
-+#else
-+   /* old enough that ap_some_auth_required() still works */
-+#  define USE_FORCE_AUTHN 0
-+#endif
-+
- /*
-  * Configuration
-  */
-@@ -819,9 +860,51 @@ access_checker(request_rec *r)
-                                                     &authz_svn_module);
-   const char *repos_path = NULL;
-   const char *dest_repos_path = NULL;
--  int status;
-+  int status, authn_required;
- 
-+#if USE_FORCE_AUTHN
-+  /* Use the force_authn() hook available in 2.4.x to work securely
-+   * given that ap_some_auth_required() is no longer functional for our
-+   * purposes in 2.4.x.
-+   */
-+  int authn_configured;
-+
-   /* We are not configured to run */
-+  if (!conf->anonymous || apr_table_get(r->notes, IN_SOME_AUTHN_NOTE)
-+      || (! (conf->access_file || conf->repo_relative_access_file)))
-+    return DECLINED;
-+
-+  /* Authentication is configured */
-+  authn_configured = ap_auth_type(r) != NULL;
-+  if (authn_configured)
-+    {
-+      /* If the user is trying to authenticate, let him.  It doesn't
-+       * make much sense to grant anonymous access but deny authenticated
-+       * users access, even though you can do that with '$anon' in the
-+       * access file.
-+       */
-+      if (apr_table_get(r->headers_in,
-+                        (PROXYREQ_PROXY == r->proxyreq)
-+                        ? "Proxy-Authorization" : "Authorization"))
-+        {
-+          /* Set the note to force authn regardless of what access_checker_ex
-+             hook requires */
-+          apr_table_setn(r->notes, FORCE_AUTHN_NOTE, (const char*)1);
-+
-+          /* provide the proper return so the access_checker hook doesn't
-+           * prevent the code from continuing on to the other auth hooks */
-+          if (ap_satisfies(r) != SATISFY_ANY)
-+            return OK;
-+          else
-+            return HTTP_FORBIDDEN;
-+        }
-+    }    
-+
-+#else
-+  /* Support for older versions of httpd that have a working
-+   * ap_some_auth_required() */
-+
-+  /* We are not configured to run */
-   if (!conf->anonymous
-       || (! (conf->access_file || conf->repo_relative_access_file)))
-     return DECLINED;
-@@ -834,9 +917,10 @@ access_checker(request_rec *r)
-       if (ap_satisfies(r) != SATISFY_ANY)
-         return DECLINED;
- 
--      /* If the user is trying to authenticate, let him.  If anonymous
--       * access is allowed, so is authenticated access, by definition
--       * of the meaning of '*' in the access file.
-+      /* If the user is trying to authenticate, let him.  It doesn't
-+       * make much sense to grant anonymous access but deny authenticated
-+       * users access, even though you can do that with '$anon' in the
-+       * access file.
-        */
-       if (apr_table_get(r->headers_in,
-                         (PROXYREQ_PROXY == r->proxyreq)
-@@ -848,6 +932,7 @@ access_checker(request_rec *r)
-           return HTTP_FORBIDDEN;
-         }
-     }
-+#endif
- 
-   /* If anon access is allowed, return OK */
-   status = req_check_access(r, conf, &repos_path, &dest_repos_path);
-@@ -856,7 +941,26 @@ access_checker(request_rec *r)
-       if (!conf->authoritative)
-         return DECLINED;
- 
-+#if USE_FORCE_AUTHN
-+      if (authn_configured) {
-+          /* We have to check to see if authn is required because if so we must
-+           * return UNAUTHORIZED (401) rather than FORBIDDEN (403) since returning
-+           * the 403 leaks information about what paths may exist to
-+           * unauthenticated users.  We must set a note here in order
-+           * to use ap_some_authn_rquired() without triggering an infinite
-+           * loop since the call will trigger this function to be called again. */
-+          apr_table_setn(r->notes, IN_SOME_AUTHN_NOTE, (const char*)1);
-+          authn_required = ap_some_authn_required(r);
-+          apr_table_unset(r->notes, IN_SOME_AUTHN_NOTE);
-+          if (authn_required)
-+            {
-+              ap_note_auth_failure(r);
-+              return HTTP_UNAUTHORIZED;
-+            }
-+      }
-+#else
-       if (!ap_some_auth_required(r))
-+#endif
-         log_access_verdict(APLOG_MARK, r, 0, repos_path, dest_repos_path);
- 
-       return HTTP_FORBIDDEN;
-@@ -937,6 +1041,17 @@ auth_checker(request_rec *r)
-   return OK;
- }
- 
-+#if USE_FORCE_AUTHN
-+static int
-+force_authn(request_rec *r)
-+{
-+  if (apr_table_get(r->notes, FORCE_AUTHN_NOTE))
-+    return OK;
-+
-+  return DECLINED;
-+}
-+#endif
-+
- /*
-  * Module flesh
-  */
-@@ -953,6 +1068,9 @@ register_hooks(apr_pool_t *p)
-    * give SSLOptions +FakeBasicAuth a chance to work. */
-   ap_hook_check_user_id(check_user_id, mod_ssl, NULL, APR_HOOK_FIRST);
-   ap_hook_auth_checker(auth_checker, NULL, NULL, APR_HOOK_FIRST);
-+#if USE_FORCE_AUTHN
-+  ap_hook_force_authn(force_authn, NULL, NULL, APR_HOOK_FIRST);
-+#endif
-   ap_register_provider(p,
-                        AUTHZ_SVN__SUBREQ_BYPASS_PROV_GRP,
-                        AUTHZ_SVN__SUBREQ_BYPASS_PROV_NAME,
-Index: subversion/tests/cmdline/README
-===================================================================
---- a/subversion/tests/cmdline/README	(revision 1691883)
-+++ b/subversion/tests/cmdline/README	(working copy)
-@@ -83,6 +83,133 @@ paths adjusted appropriately:
-      Require valid-user
-    </Location>
- 
-+   <Location /authz-test-work/anon>
-+     DAV               svn
-+     SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+     AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+     SVNListParentPath On
-+     # This may seem unnecessary but granting access to everyone here is necessary
-+     # to exercise a bug with httpd 2.3.x+.  The "Require all granted" syntax is
-+     # new to 2.3.x+ which we can detect with the mod_authz_core.c module
-+     # signature.  Use the "Allow from all" syntax with older versions for symmetry.
-+     <IfModule mod_authz_core.c>
-+       Require all granted
-+     </IfModule>
-+     <IfModule !mod_authz_core.c>
-+       Allow from all
-+     </IfMOdule>
-+   </Location>
-+   <Location /authz-test-work/mixed>
-+     DAV               svn
-+     SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+     AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+     SVNListParentPath On
-+     AuthType          Basic
-+     AuthName          "Subversion Repository"
-+     AuthUserFile /usr/local/apache2/conf/users
-+     Require           valid-user
-+     Satisfy Any
-+   </Location>
-+   <Location /authz-test-work/mixed-noauthwhenanon>
-+     DAV               svn
-+     SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+     AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+     SVNListParentPath On
-+     AuthType          Basic
-+     AuthName          "Subversion Repository"
-+     AuthUserFile /usr/local/apache2/conf/users
-+     Require           valid-user
-+     AuthzSVNNoAuthWhenAnonymousAllowed On
-+   </Location>
-+   <Location /authz-test-work/authn>
-+     DAV               svn
-+     SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+     AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+     SVNListParentPath On
-+     AuthType          Basic
-+     AuthName          "Subversion Repository"
-+     AuthUserFile /usr/local/apache2/conf/users
-+     Require           valid-user
-+   </Location>
-+   <Location /authz-test-work/authn-anonoff>
-+     DAV               svn
-+     SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+     AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+     SVNListParentPath On
-+     AuthType          Basic
-+     AuthName          "Subversion Repository"
-+     AuthUserFile /usr/local/apache2/conf/users
-+     Require           valid-user
-+     AuthzSVNAnonymous Off
-+   </Location>
-+   <Location /authz-test-work/authn-lcuser>
-+     DAV               svn
-+     SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+     AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+     SVNListParentPath On
-+     AuthType          Basic
-+     AuthName          "Subversion Repository"
-+     AuthUserFile /usr/local/apache2/conf/users
-+     Require           valid-user
-+     AuthzForceUsernameCase Lower
-+   </Location>
-+   <Location /authz-test-work/authn-lcuser>
-+     DAV               svn
-+     SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+     AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+     SVNListParentPath On
-+     AuthType          Basic
-+     AuthName          "Subversion Repository"
-+     AuthUserFile /usr/local/apache2/conf/users
-+     Require           valid-user
-+     AuthzForceUsernameCase Lower
-+   </Location>
-+   <Location /authz-test-work/authn-group>
-+     DAV               svn
-+     SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+     AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+     SVNListParentPath On
-+     AuthType          Basic
-+     AuthName          "Subversion Repository"
-+     AuthUserFile /usr/local/apache2/conf/users
-+     AuthGroupFile /usr/local/apache2/conf/groups
-+     Require           group random
-+     AuthzSVNAuthoritative Off
-+   </Location>
-+   <IfModule mod_authz_core.c>
-+     <Location /authz-test-work/sallrany>
-+       DAV               svn
-+       SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+       AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+       SVNListParentPath On
-+       AuthType          Basic
-+       AuthName          "Subversion Repository"
-+       AuthUserFile /usr/local/apache2/conf/users
-+       AuthzSendForbiddenOnFailure On
-+       Satisfy All
-+       <RequireAny>
-+         Require valid-user
-+         Require expr req('ALLOW') == '1'
-+       </RequireAny>
-+     </Location>
-+     <Location /authz-test-work/sallrall>
-+       DAV               svn
-+       SVNParentPath /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/local_tmp
-+       AuthzSVNAccessFile /home/yourusernamehere/projects/svn/subversion/tests/cmdline/svn-test-work/authz
-+       SVNListParentPath On
-+       AuthType          Basic
-+       AuthName          "Subversion Repository"
-+       AuthUserFile /usr/local/apache2/conf/users
-+       AuthzSendForbiddenOnFailure On
-+       Satisfy All
-+       <RequireAll>
-+         Require valid-user
-+         Require expr req('ALLOW') == '1'
-+       </RequireAll>
-+     </Location>
-+   </IfModule>
-+
-+
-    RedirectMatch permanent ^/svn-test-work/repositories/REDIRECT-PERM-(.*)$ /svn-test-work/repositories/$1
-    RedirectMatch           ^/svn-test-work/repositories/REDIRECT-TEMP-(.*)$ /svn-test-work/repositories/$1
- 
-@@ -101,8 +228,17 @@ just drop the following 2-line snippet into the
- ----------------------------
- jrandom:xCGl35kV9oWCY
- jconstant:xCGl35kV9oWCY
-+JRANDOM:xCGl35kV9oWCY
-+JCONSTANT:xCGl35kV9oWCY
- ----------------------------
- 
-+and these lines into the
-+/usr/local/apache/conf/groups file:
-+----------------------------
-+random: jrandom
-+constant: jconstant
-+----------------------------
-+
- Now, (re)start Apache and run the tests over mod_dav_svn.
- 
- You can run a test script over DAV:
-@@ -138,6 +274,8 @@ Note [1]: It would be quite too much to expect tho
-           ----------------------------
-           jrandom:$apr1$3p1.....$FQW6RceW5QhJ2blWDQgKn0
-           jconstant:$apr1$jp1.....$Usrqji1c9H6AbOxOGAzzb0
-+          JRANDOM:$apr1$3p1.....$FQW6RceW5QhJ2blWDQgKn0
-+          JCONSTANT:$apr1$jp1.....$Usrqji1c9H6AbOxOGAzzb0
-           ----------------------------
- 
- 
-Index: subversion/tests/cmdline/davautocheck.sh
-===================================================================
---- a/subversion/tests/cmdline/davautocheck.sh	(revision 1691883)
-+++ b/subversion/tests/cmdline/davautocheck.sh	(working copy)
-@@ -289,8 +289,6 @@ LOAD_MOD_AUTHN_CORE="$(get_loadmodule_config mod_a
-     || fail "Authn_Core module not found."
- LOAD_MOD_AUTHZ_CORE="$(get_loadmodule_config mod_authz_core)" \
-     || fail "Authz_Core module not found."
--LOAD_MOD_AUTHZ_HOST="$(get_loadmodule_config mod_authz_host)" \
--    || fail "Authz_Host module not found."
- LOAD_MOD_UNIXD=$(get_loadmodule_config mod_unixd) \
-     || fail "UnixD module not found"
- }
-@@ -298,6 +296,10 @@ LOAD_MOD_AUTHN_FILE="$(get_loadmodule_config mod_a
-     || fail "Authn_File module not found."
- LOAD_MOD_AUTHZ_USER="$(get_loadmodule_config mod_authz_user)" \
-     || fail "Authz_User module not found."
-+LOAD_MOD_AUTHZ_GROUPFILE="$(get_loadmodule_config mod_authz_groupfile)" \
-+    || fail "Authz_GroupFile module not found."
-+LOAD_MOD_AUTHZ_HOST="$(get_loadmodule_config mod_authz_host)" \
-+    || fail "Authz_Host module not found."
- }
- if [ ${APACHE_MPM:+set} ]; then
-     LOAD_MOD_MPM=$(get_loadmodule_config mod_mpm_$APACHE_MPM) \
-@@ -328,6 +330,7 @@ HTTPD_ERROR_LOG="$HTTPD_ROOT/error_log"
- HTTPD_MIME_TYPES="$HTTPD_ROOT/mime.types"
- BASE_URL="http://localhost:$HTTPD_PORT"
- HTTPD_USERS="$HTTPD_ROOT/users"
-+HTTPD_GROUPS="$HTTPD_ROOT/groups"
- 
- mkdir "$HTTPD_ROOT" \
-   || fail "couldn't create temporary directory '$HTTPD_ROOT'"
-@@ -388,6 +391,14 @@ fi
- say "Adding users for lock authentication"
- $HTPASSWD -bc $HTTPD_USERS jrandom   rayjandom
- $HTPASSWD -b  $HTTPD_USERS jconstant rayjandom
-+$HTPASSWD -b  $HTTPD_USERS JRANDOM   rayjandom
-+$HTPASSWD -b  $HTTPD_USERS JCONSTANT rayjandom
-+ 
-+say "Adding groups for mod_authz_svn tests"
-+cat > "$HTTPD_GROUPS" <<__EOF__
-+random: jrandom
-+constant: jconstant
-+__EOF__
- 
- touch $HTTPD_MIME_TYPES
- 
-@@ -405,7 +416,9 @@ $LOAD_MOD_AUTHN_CORE
- $LOAD_MOD_AUTHN_FILE
- $LOAD_MOD_AUTHZ_CORE
- $LOAD_MOD_AUTHZ_USER
-+$LOAD_MOD_AUTHZ_GROUPFILE
- $LOAD_MOD_AUTHZ_HOST
-+$LOAD_MOD_ACCESS_COMPAT
- LoadModule          authz_svn_module "$MOD_AUTHZ_SVN"
- 
- __EOF__
-@@ -497,6 +510,161 @@ CustomLog           "$HTTPD_ROOT/ops" "%t %u %{SVN
-   SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-   ${SVN_PATH_AUTHZ_LINE}
- </Location>
-+<Location /authz-test-work/anon>
-+  DAV               svn
-+  SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+  AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+  SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+  SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+  SVNListParentPath On
-+  # This may seem unnecessary but granting access to everyone here is necessary
-+  # to exercise a bug with httpd 2.3.x+.  The "Require all granted" syntax is
-+  # new to 2.3.x+ which we can detect with the mod_authz_core.c module
-+  # signature.  Use the "Allow from all" syntax with older versions for symmetry.
-+  <IfModule mod_authz_core.c>
-+    Require all granted
-+  </IfModule>
-+  <IfModule !mod_authz_core.c>
-+    Allow from all
-+  </IfMOdule>
-+  ${SVN_PATH_AUTHZ_LINE}
-+</Location>
-+<Location /authz-test-work/mixed>
-+  DAV               svn
-+  SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+  AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+  SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+  SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+  SVNListParentPath On
-+  AuthType          Basic
-+  AuthName          "Subversion Repository"
-+  AuthUserFile      $HTTPD_USERS
-+  Require           valid-user
-+  Satisfy Any
-+  ${SVN_PATH_AUTHZ_LINE}
-+</Location>
-+<Location /authz-test-work/mixed-noauthwhenanon>
-+  DAV               svn
-+  SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+  AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+  SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+  SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+  SVNListParentPath On
-+  AuthType          Basic
-+  AuthName          "Subversion Repository"
-+  AuthUserFile      $HTTPD_USERS
-+  Require           valid-user
-+  AuthzSVNNoAuthWhenAnonymousAllowed On
-+  SVNPathAuthz On
-+</Location>
-+<Location /authz-test-work/authn>
-+  DAV               svn
-+  SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+  AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+  SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+  SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+  SVNListParentPath On
-+  AuthType          Basic
-+  AuthName          "Subversion Repository"
-+  AuthUserFile      $HTTPD_USERS
-+  Require           valid-user
-+  ${SVN_PATH_AUTHZ_LINE}
-+</Location>
-+<Location /authz-test-work/authn-anonoff>
-+  DAV               svn
-+  SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+  AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+  SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+  SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+  SVNListParentPath On
-+  AuthType          Basic
-+  AuthName          "Subversion Repository"
-+  AuthUserFile      $HTTPD_USERS
-+  Require           valid-user
-+  AuthzSVNAnonymous Off
-+  SVNPathAuthz On
-+</Location>
-+<Location /authz-test-work/authn-lcuser>
-+  DAV               svn
-+  SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+  AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+  SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+  SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+  SVNListParentPath On
-+  AuthType          Basic
-+  AuthName          "Subversion Repository"
-+  AuthUserFile      $HTTPD_USERS
-+  Require           valid-user
-+  AuthzForceUsernameCase Lower
-+  ${SVN_PATH_AUTHZ_LINE}
-+</Location>
-+<Location /authz-test-work/authn-lcuser>
-+  DAV               svn
-+  SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+  AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+  SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+  SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+  SVNListParentPath On
-+  AuthType          Basic
-+  AuthName          "Subversion Repository"
-+  AuthUserFile      $HTTPD_USERS
-+  Require           valid-user
-+  AuthzForceUsernameCase Lower
-+  ${SVN_PATH_AUTHZ_LINE}
-+</Location>
-+<Location /authz-test-work/authn-group>
-+  DAV               svn
-+  SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+  AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+  SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+  SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+  SVNListParentPath On
-+  AuthType          Basic
-+  AuthName          "Subversion Repository"
-+  AuthUserFile      $HTTPD_USERS
-+  AuthGroupFile     $HTTPD_GROUPS
-+  Require           group random
-+  AuthzSVNAuthoritative Off
-+  SVNPathAuthz On
-+</Location>
-+<IfModule mod_authz_core.c>
-+  <Location /authz-test-work/sallrany>
-+    DAV               svn
-+    SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+    AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+    SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+    SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+    SVNListParentPath On
-+    AuthType          Basic
-+    AuthName          "Subversion Repository"
-+    AuthUserFile      $HTTPD_USERS
-+    AuthzSendForbiddenOnFailure On
-+    Satisfy All
-+    <RequireAny>
-+      Require valid-user
-+      Require expr req('ALLOW') == '1'
-+    </RequireAny>
-+    ${SVN_PATH_AUTHZ_LINE}
-+  </Location>
-+  <Location /authz-test-work/sallrall>
-+    DAV               svn
-+    SVNParentPath     "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/local_tmp"
-+    AuthzSVNAccessFile "$ABS_BUILDDIR/subversion/tests/cmdline/svn-test-work/authz"
-+    SVNAdvertiseV2Protocol ${ADVERTISE_V2_PROTOCOL}
-+    SVNCacheRevProps  ${CACHE_REVPROPS_SETTING}
-+    SVNListParentPath On
-+    AuthType          Basic
-+    AuthName          "Subversion Repository"
-+    AuthUserFile      $HTTPD_USERS
-+    AuthzSendForbiddenOnFailure On
-+    Satisfy All
-+    <RequireAll>
-+      Require valid-user
-+      Require expr req('ALLOW') == '1'
-+    </RequireAll>
-+    ${SVN_PATH_AUTHZ_LINE}
-+  </Location>
-+</IfModule>
- RedirectMatch permanent ^/svn-test-work/repositories/REDIRECT-PERM-(.*)\$ /svn-test-work/repositories/\$1
- RedirectMatch           ^/svn-test-work/repositories/REDIRECT-TEMP-(.*)\$ /svn-test-work/repositories/\$1
- __EOF__
-Index: subversion/tests/cmdline/mod_authz_svn_tests.py
-===================================================================
---- a/subversion/tests/cmdline/mod_authz_svn_tests.py	(nonexistent)
-+++ b/subversion/tests/cmdline/mod_authz_svn_tests.py	(working copy)
-@@ -0,0 +1,1073 @@
-+#!/usr/bin/env python
-+#
-+#  mod_authz_svn_tests.py:  testing mod_authz_svn
-+#
-+#  Subversion is a tool for revision control.
-+#  See http://subversion.apache.org for more information.
-+#
-+# ====================================================================
-+#    Licensed to the Apache Software Foundation (ASF) under one
-+#    or more contributor license agreements.  See the NOTICE file
-+#    distributed with this work for additional information
-+#    regarding copyright ownership.  The ASF licenses this file
-+#    to you under the Apache License, Version 2.0 (the
-+#    "License"); you may not use this file except in compliance
-+#    with the License.  You may obtain a copy of the License at
-+#
-+#      http://www.apache.org/licenses/LICENSE-2.0
-+#
-+#    Unless required by applicable law or agreed to in writing,
-+#    software distributed under the License is distributed on an
-+#    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-+#    KIND, either express or implied.  See the License for the
-+#    specific language governing permissions and limitations
-+#    under the License.
-+######################################################################
-+
-+# General modules
-+import os, re, logging
-+
-+logger = logging.getLogger()
-+
-+# Our testing module
-+import svntest
-+
-+# (abbreviation)
-+Skip = svntest.testcase.Skip_deco
-+SkipUnless = svntest.testcase.SkipUnless_deco
-+XFail = svntest.testcase.XFail_deco
-+Issues = svntest.testcase.Issues_deco
-+Issue = svntest.testcase.Issue_deco
-+Wimp = svntest.testcase.Wimp_deco
-+
-+ls_of_D_no_H = '''<html><head><title>repos - Revision 1: /A/D</title></head>
-+<body>
-+ <h2>repos - Revision 1: /A/D</h2>
-+ <ul>
-+  <li><a href="../">..</a></li>
-+  <li><a href="G/">G/</a></li>
-+  <li><a href="gamma">gamma</a></li>
-+ </ul>
-+</body></html>'''
-+
-+ls_of_D_H = '''<html><head><title>repos - Revision 1: /A/D</title></head>
-+<body>
-+ <h2>repos - Revision 1: /A/D</h2>
-+ <ul>
-+  <li><a href="../">..</a></li>
-+  <li><a href="G/">G/</a></li>
-+  <li><a href="H/">H/</a></li>
-+  <li><a href="gamma">gamma</a></li>
-+ </ul>
-+</body></html>'''
-+
-+ls_of_H = '''<html><head><title>repos - Revision 1: /A/D/H</title></head>
-+<body>
-+ <h2>repos - Revision 1: /A/D/H</h2>
-+ <ul>
-+  <li><a href="../">..</a></li>
-+  <li><a href="chi">chi</a></li>
-+  <li><a href="omega">omega</a></li>
-+  <li><a href="psi">psi</a></li>
-+ </ul>
-+</body></html>'''
-+
-+user1 = svntest.main.wc_author
-+user1_upper = user1.upper()
-+user1_pass = svntest.main.wc_passwd
-+user1_badpass = 'XXX'
-+assert user1_pass != user1_badpass, "Passwords can't match"
-+user2 = svntest.main.wc_author2
-+user2_upper = user2.upper()
-+user2_pass = svntest.main.wc_passwd
-+user2_badpass = 'XXX'
-+assert user2_pass != user2_badpass, "Passwords can't match"
-+
-+def write_authz_file(sbox):
-+    svntest.main.write_authz_file(sbox, {
-+                                          '/':  '$anonymous = r\n' +
-+                                                'jrandom = rw\n' +
-+                                                'jconstant = rw',
-+                                          '/A/D/H': '$anonymous =\n' +
-+                                                    '$authenticated =\n' +
-+                                                    'jrandom = rw'
-+                                        })
-+
-+def write_authz_file_groups(sbox):
-+    authz_name = sbox.authz_name()
-+    svntest.main.write_authz_file(sbox,{
-+                                         '/':  '* =',
-+                                       })
-+
-+def verify_get(test_area_url, path, user, pw,
-+               expected_status, expected_body, headers):
-+  import httplib
-+  from urlparse import urlparse
-+  import base64
-+
-+  req_url = test_area_url + path
-+
-+  loc = urlparse(req_url)
-+
-+  if loc.scheme == 'http':
-+    h = httplib.HTTPConnection(loc.hostname, loc.port)
-+  else:
-+    h = httplib.HTTPSConnection(loc.hostname, loc.port)
-+
-+  if headers is None:
-+    headers = {}
-+
-+  if user and pw:
-+      auth_info = user + ':' + pw
-+      headers['Authorization'] = 'Basic ' + base64.b64encode(auth_info)
-+  else:
-+      auth_info = "anonymous"
-+
-+  h.request('GET', req_url, None, headers)
-+
-+  r = h.getresponse()
-+
-+  actual_status = r.status
-+  if expected_status and expected_status != actual_status:
-+
-+      logger.warn("Expected status '" + str(expected_status) +
-+                  "' but got '" + str(actual_status) +
-+                  "' on url '" + req_url + "' (" +
-+                  auth_info + ").")
-+      raise svntest.Failure
-+
-+  if expected_body:
-+      actual_body = r.read()
-+      if expected_body != actual_body:
-+        logger.warn("Expected body:")
-+        logger.warn(expected_body)
-+        logger.warn("But got:")
-+        logger.warn(actual_body)
-+        logger.warn("on url '" + req_url + "' (" + auth_info + ").")
-+        raise svntest.Failure
-+
-+def verify_gets(test_area_url, tests):
-+  for test in tests:
-+      verify_get(test_area_url, test['path'], test.get('user'), test.get('pw'),
-+                 test['status'], test.get('body'), test.get('headers'))
-+
-+
-+######################################################################
-+# Tests
-+#
-+#   Each test must return on success or raise on failure.
-+
-+
-+#----------------------------------------------------------------------
-+
-+
-+@SkipUnless(svntest.main.is_ra_type_dav)
-+def anon(sbox):
-+  "test anonymous access"
-+  sbox.build(read_only = True, create_wc = False)
-+
-+  test_area_url = sbox.repo_url.replace('/svn-test-work/local_tmp/repos',
-+                                        '/authz-test-work/anon')
-+
-+  write_authz_file(sbox)
-+
-+  anon_tests = ( 
-+                 { 'path': '', 'status': 301 },
-+                 { 'path': '/', 'status': 200 },
-+                 { 'path': '/repos', 'status': 301 },
-+                 { 'path': '/repos/', 'status': 200 },
-+                 { 'path': '/repos/A', 'status': 301 },
-+                 { 'path': '/repos/A/', 'status': 200 },
-+                 { 'path': '/repos/A/D', 'status': 301 },
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H },
-+                 { 'path': '/repos/A/D/gamma', 'status': 200 },
-+                 { 'path': '/repos/A/D/H', 'status': 403 },
-+                 { 'path': '/repos/A/D/H/', 'status': 403 },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403 },
-+                 # auth isn't configured so nothing should change when passing
-+                 # authn details
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+               )
-+
-+  verify_gets(test_area_url, anon_tests)
-+
-+
-+@SkipUnless(svntest.main.is_ra_type_dav)
-+def mixed(sbox):
-+  "test mixed anonymous and authenticated access"
-+  sbox.build(read_only = True, create_wc = False)
-+
-+  test_area_url = sbox.repo_url.replace('/svn-test-work/local_tmp/repos',
-+                                        '/authz-test-work/mixed')
-+
-+  write_authz_file(sbox)
-+
-+  mixed_tests = (
-+                 { 'path': '', 'status': 301,  },
-+                 { 'path': '/', 'status': 200,  },
-+                 { 'path': '/repos', 'status': 301,  },
-+                 { 'path': '/repos/', 'status': 200,  },
-+                 { 'path': '/repos/A', 'status': 301,  },
-+                 { 'path': '/repos/A/', 'status': 200,  },
-+                 { 'path': '/repos/A/D', 'status': 301,  },
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   },
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, },
-+                 { 'path': '/repos/A/D/H', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, },
-+                 # auth is configured and user1 is allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_H,
-+                   'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 200, 'body': ls_of_H, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 # try with the wrong password for user1
-+                 { 'path': '', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 # auth is configured and user2 is not allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 # try with the wrong password for user2
-+                 { 'path': '', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 )
-+
-+  verify_gets(test_area_url, mixed_tests)
-+
-+@SkipUnless(svntest.main.is_ra_type_dav)
-+@XFail(svntest.main.is_httpd_authz_provider_enabled)
-+# uses the AuthzSVNNoAuthWhenAnonymousAllowed On directive
-+# this is broken with httpd 2.3.x+ since it requires the auth system to accept
-+# r->user == NULL and there is a test for this in server/request.c now.  It
-+# was intended as a workaround for the lack of Satisfy Any in 2.3.x+ which
-+# was resolved by httpd with mod_access_compat in 2.3.x+.
-+def mixed_noauthwhenanon(sbox):
-+  "test mixed with noauthwhenanon directive"
-+  sbox.build(read_only = True, create_wc = False)
-+
-+  test_area_url = sbox.repo_url.replace('/svn-test-work/local_tmp/repos',
-+                                        '/authz-test-work/mixed-noauthwhenanon')
-+
-+  write_authz_file(sbox)
-+
-+  noauthwhenanon_tests = (
-+                 { 'path': '', 'status': 301,  },
-+                 { 'path': '/', 'status': 200,  },
-+                 { 'path': '/repos', 'status': 301,  },
-+                 { 'path': '/repos/', 'status': 200,  },
-+                 { 'path': '/repos/A', 'status': 301,  },
-+                 { 'path': '/repos/A/', 'status': 200,  },
-+                 { 'path': '/repos/A/D', 'status': 301,  },
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   },
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, },
-+                 { 'path': '/repos/A/D/H', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, },
-+                 # auth is configured and user1 is allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_H,
-+                   'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 200, 'body': ls_of_H, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 # try with the wrong password for user1
-+                 # note that unlike doing this with Satisfy Any this case
-+                 # actually provides anon access when provided with an invalid
-+                 # password
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 # auth is configured and user2 is not allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 # try with the wrong password for user2
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 )
-+
-+  verify_gets(test_area_url, noauthwhenanon_tests)
-+
-+
-+@SkipUnless(svntest.main.is_ra_type_dav)
-+def authn(sbox):
-+  "test authenticated only access"
-+  sbox.build(read_only = True, create_wc = False)
-+
-+  test_area_url = sbox.repo_url.replace('/svn-test-work/local_tmp/repos',
-+                                        '/authz-test-work/authn')
-+
-+  write_authz_file(sbox)
-+
-+  authn_tests = (
-+                 { 'path': '', 'status': 401,  },
-+                 { 'path': '/', 'status': 401,  },
-+                 { 'path': '/repos', 'status': 401,  },
-+                 { 'path': '/repos/', 'status': 401,  },
-+                 { 'path': '/repos/A', 'status': 401,  },
-+                 { 'path': '/repos/A/', 'status': 401,  },
-+                 { 'path': '/repos/A/D', 'status': 401,  },
-+                 { 'path': '/repos/A/D/', 'status': 401, },
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, },
-+                 { 'path': '/repos/A/D/H', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, },
-+                 # auth is configured and user1 is allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_H,
-+                   'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 200, 'body': ls_of_H, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 # try with upper case username for user1
-+                 { 'path': '', 'status': 301, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 # try with the wrong password for user1
-+                 { 'path': '', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 # auth is configured and user2 is not allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 # try with upper case username for user2
-+                 { 'path': '', 'status': 301, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/', 'status': 200, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 # try with the wrong password for user2
-+                 { 'path': '', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 )
-+
-+  verify_gets(test_area_url, authn_tests)
-+
-+@SkipUnless(svntest.main.is_ra_type_dav)
-+def authn_anonoff(sbox):
-+  "test authenticated only access with anonoff"
-+  sbox.build(read_only = True, create_wc = False)
-+
-+  test_area_url = sbox.repo_url.replace('/svn-test-work/local_tmp/repos',
-+                                        '/authz-test-work/authn-anonoff')
-+
-+  write_authz_file(sbox)
-+
-+  anonoff_tests = (
-+                 { 'path': '', 'status': 401,  },
-+                 { 'path': '/', 'status': 401,  },
-+                 { 'path': '/repos', 'status': 401,  },
-+                 { 'path': '/repos/', 'status': 401,  },
-+                 { 'path': '/repos/A', 'status': 401,  },
-+                 { 'path': '/repos/A/', 'status': 401,  },
-+                 { 'path': '/repos/A/D', 'status': 401,  },
-+                 { 'path': '/repos/A/D/', 'status': 401, },
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, },
-+                 { 'path': '/repos/A/D/H', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, },
-+                 # auth is configured and user1 is allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_H,
-+                   'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 200, 'body': ls_of_H, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 # try with upper case username for user1
-+                 { 'path': '', 'status': 301, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user1_upper, 'pw': user1_pass},
-+                 # try with the wrong password for user1
-+                 { 'path': '', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 # auth is configured and user2 is not allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 # try with upper case username for user2
-+                 { 'path': '', 'status': 301, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/', 'status': 200, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 # try with the wrong password for user2
-+                 { 'path': '', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 )
-+
-+  verify_gets(test_area_url, anonoff_tests)
-+
-+@SkipUnless(svntest.main.is_ra_type_dav)
-+def authn_lcuser(sbox):
-+  "test authenticated only access with lcuser"
-+  sbox.build(read_only = True, create_wc = False)
-+
-+  test_area_url = sbox.repo_url.replace('/svn-test-work/local_tmp/repos',
-+                                        '/authz-test-work/authn-lcuser')
-+
-+  write_authz_file(sbox)
-+
-+  lcuser_tests = (
-+                 # try with upper case username for user1 (works due to lcuser option)
-+                 { 'path': '', 'status': 301, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_H,
-+                   'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 301, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 200, 'body': ls_of_H, 'user': user1_upper, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 200, 'user': user1_upper, 'pw': user1_pass},
-+                 # try with upper case username for user2 (works due to lcuser option)
-+                 { 'path': '', 'status': 301, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/', 'status': 200, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2_upper, 'pw': user2_pass},
-+                 )
-+
-+  verify_gets(test_area_url, lcuser_tests)
-+
-+# authenticated access only by group - a excuse to use AuthzSVNAuthoritative Off
-+# this is terribly messed up, Require group runs after mod_authz_svn.
-+# so if mod_authz_svn grants the access then it doesn't matter what the group
-+# requirement says.  If we reject the access then you can use the AuthzSVNAuthoritative Off
-+# directive to fall through to the group check.  Overall the behavior of setups like this
-+# is almost guaranteed to not be what users expect.
-+@SkipUnless(svntest.main.is_ra_type_dav)
-+def authn_group(sbox):
-+  "test authenticated only access via groups"
-+  sbox.build(read_only = True, create_wc = False)
-+
-+  test_area_url = sbox.repo_url.replace('/svn-test-work/local_tmp/repos',
-+                                        '/authz-test-work/authn-group')
-+
-+  # Can't use write_authz_file() as most tests because we want to deny all
-+  # access with mod_authz_svn so the tests fall through to the group handling
-+  authz_name = sbox.authz_name()
-+  svntest.main.write_authz_file(sbox, {
-+                                        '/':  '* =',
-+                                      })
-+
-+  group_tests = (
-+                 { 'path': '', 'status': 401, },
-+                 { 'path': '/', 'status': 401, },
-+                 { 'path': '/repos', 'status': 401, },
-+                 { 'path': '/repos/', 'status': 401, },
-+                 { 'path': '/repos/A', 'status': 401, },
-+                 { 'path': '/repos/A/', 'status': 401, },
-+                 { 'path': '/repos/A/D', 'status': 401, },
-+                 { 'path': '/repos/A/D/', 'status': 401, },
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, },
-+                 { 'path': '/repos/A/D/H', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, },
-+                 # auth is configured and user1 is allowed access repo including H
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_H,
-+                   'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 200, 'body': ls_of_H, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 )
-+
-+  verify_gets(test_area_url, group_tests)
-+
-+# This test exists to validate our behavior when used with the new authz
-+# provider system introduced in httpd 2.3.x.  The Satisfy directive
-+# determines how older authz hooks are combined and the RequireA(ll|ny)
-+# blocks handles how new authz providers are combined.  The overall results of
-+# all the authz providers (combined per the Require* blocks) are then
-+# combined with the other authz hooks via the Satisfy directive.
-+# Meaning this test requires that mod_authz_svn says yes and there is
-+# either a valid user or the ALLOW header is 1.  The header may seem
-+# like a silly test but it's easier to excercise than say a host directive
-+# in a repeatable test.
-+@SkipUnless(svntest.main.is_httpd_authz_provider_enabled)
-+def authn_sallrany(sbox):
-+  "test satisfy all require any config"
-+  sbox.build(read_only = True, create_wc = False)
-+
-+  test_area_url = sbox.repo_url.replace('/svn-test-work/local_tmp/repos',
-+                                        '/authz-test-work/sallrany')
-+
-+  write_authz_file(sbox)
-+
-+  allow_header = { 'ALLOW': '1' }
-+
-+  sallrany_tests = (
-+                 #anon access isn't allowed without ALLOW header
-+                 { 'path': '', 'status': 401, },
-+                 { 'path': '/', 'status': 401, },
-+                 { 'path': '/repos', 'status': 401, },
-+                 { 'path': '/repos/', 'status': 401, },
-+                 { 'path': '/repos/A', 'status': 401, },
-+                 { 'path': '/repos/A/', 'status': 401, },
-+                 { 'path': '/repos/A/D', 'status': 401, },
-+                 { 'path': '/repos/A/D/', 'status': 401, },
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, },
-+                 { 'path': '/repos/A/D/H', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, },
-+                 # auth is configured and user1 is allowed access repo including H
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_H,
-+                   'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 301, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 200, 'body': ls_of_H, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 200, 'user': user1, 'pw': user1_pass},
-+                 # try with the wrong password for user1
-+                 { 'path': '', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user1, 'pw': user1_badpass},
-+                 # auth is configured and user2 is not allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 # try with the wrong password for user2
-+                 { 'path': '', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user2, 'pw': user2_badpass},
-+                 # anon is allowed with the ALLOW header
-+                 { 'path': '', 'status': 301, 'headers': allow_header },
-+                 { 'path': '/', 'status': 200, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 301, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 200, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 301, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 200, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 301, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'headers': allow_header },
-+                 # these 3 tests return 403 instead of 401 becasue the config allows
-+                 # the anon user with the ALLOW header without any auth and the old hook
-+                 # system has no way of knowing it should return 401 since authentication is
-+                 # configured and can change the behavior.  It could decide to return 401 just on
-+                 # the basis of authentication being configured but then that leaks info in other
-+                 # cases so it's better for this case to be "broken".
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'headers': allow_header },
-+                 # auth is configured and user1 is allowed access repo including H
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_H,
-+                   'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 200, 'body': ls_of_H, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 # try with the wrong password for user1
-+                 { 'path': '', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 # auth is configured and user2 is not allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 # try with the wrong password for user2
-+                 { 'path': '', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+
-+                 )
-+
-+  verify_gets(test_area_url, sallrany_tests)
-+
-+# See comments on authn_sallrany test for some background on the interaction
-+# of Satisfy Any and the newer Require blocks.
-+@SkipUnless(svntest.main.is_httpd_authz_provider_enabled)
-+def authn_sallrall(sbox):
-+  "test satisfy all require all config"
-+  sbox.build(read_only = True, create_wc = False)
-+
-+  test_area_url = sbox.repo_url.replace('/svn-test-work/local_tmp/repos',
-+                                        '/authz-test-work/sallrall')
-+
-+  write_authz_file(sbox)
-+
-+  allow_header = { 'ALLOW': '1' }
-+
-+  sallrall_tests = (
-+                 #anon access isn't allowed without ALLOW header
-+                 { 'path': '', 'status': 403, },
-+                 { 'path': '/', 'status': 403, },
-+                 { 'path': '/repos', 'status': 403, },
-+                 { 'path': '/repos/', 'status': 403, },
-+                 { 'path': '/repos/A', 'status': 403, },
-+                 { 'path': '/repos/A/', 'status': 403, },
-+                 { 'path': '/repos/A/D', 'status': 403, },
-+                 { 'path': '/repos/A/D/', 'status': 403, },
-+                 { 'path': '/repos/A/D/gamma', 'status': 403, },
-+                 { 'path': '/repos/A/D/H', 'status': 403, },
-+                 { 'path': '/repos/A/D/H/', 'status': 403, },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, },
-+                 # auth is configured but no access is allowed without the ALLOW header
-+                 { 'path': '', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user1, 'pw': user1_pass},
-+                 # try with the wrong password for user1
-+                 { 'path': '', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user1, 'pw': user1_badpass},
-+                 # auth is configured but no access is allowed without the ALLOW header
-+                 { 'path': '', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_pass},
-+                 # try with the wrong password for user2
-+                 { 'path': '', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/gamma', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_badpass},
-+                 # anon is not allowed even with ALLOW header
-+                 { 'path': '', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'headers': allow_header },
-+                 # auth is configured and user1 is allowed access repo including H
-+                 { 'path': '', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_H,
-+                   'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H', 'status': 301, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 200, 'body': ls_of_H, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 200, 'user': user1, 'pw': user1_pass, 'headers': allow_header },
-+                 # try with the wrong password for user1
-+                 { 'path': '', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user1, 'pw': user1_badpass, 'headers': allow_header },
-+                 # auth is configured and user2 is not allowed access to H
-+                 { 'path': '', 'status': 301, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/', 'status': 200, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 301, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 200, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 301, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 200, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 301, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 200, 'body': ls_of_D_no_H,
-+                   'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 200, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H', 'status': 403, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 403, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 403, 'user': user2, 'pw': user2_pass, 'headers': allow_header },
-+                 # try with the wrong password for user2
-+                 { 'path': '', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/gamma', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+                 { 'path': '/repos/A/D/H/chi', 'status': 401, 'user': user2, 'pw': user2_badpass, 'headers': allow_header },
-+
-+                 )
-+
-+  verify_gets(test_area_url, sallrall_tests)
-+
-+
-+########################################################################
-+# Run the tests
-+
-+
-+# list all tests here, starting with None:
-+test_list = [ None,
-+              anon,
-+              mixed,
-+              mixed_noauthwhenanon,
-+              authn,
-+              authn_anonoff,
-+              authn_lcuser,
-+              authn_group,
-+              authn_sallrany,
-+              authn_sallrall,
-+             ]
-+serial_only = True
-+
-+if __name__ == '__main__':
-+  svntest.main.run_tests(test_list)
-+  # NOTREACHED
-+
-+
-+### End of file.
-
-Property changes on: subversion/tests/cmdline/mod_authz_svn_tests.py
-___________________________________________________________________
-Added: svn:eol-style
-## -0,0 +1 ##
-+native
-\ No newline at end of property
-Index: subversion/tests/cmdline/svntest/main.py
-===================================================================
---- a/subversion/tests/cmdline/svntest/main.py	(revision 1691883)
-+++ b/subversion/tests/cmdline/svntest/main.py	(working copy)
-@@ -1378,6 +1378,30 @@ def is_plaintext_password_storage_disabled():
-     return False
-   return True
- 
-+
-+# https://issues.apache.org/bugzilla/show_bug.cgi?id=56480
-+# https://issues.apache.org/bugzilla/show_bug.cgi?id=55397
-+__mod_dav_url_quoting_broken_versions = frozenset([
-+    '2.2.27',
-+    '2.2.26',
-+    '2.2.25',
-+    '2.4.9',
-+    '2.4.8',
-+    '2.4.7',
-+    '2.4.6',
-+    '2.4.5',
-+])
-+def is_mod_dav_url_quoting_broken():
-+    if is_ra_type_dav():
-+        return (options.httpd_version in __mod_dav_url_quoting_broken_versions)
-+    return None
-+
-+def is_httpd_authz_provider_enabled():
-+    if is_ra_type_dav():
-+      v = options.httpd_version.split('.')
-+      return (v[0] == '2' and int(v[1]) >= 3) or int(v[0]) > 2
-+    return None
-+
- ######################################################################
- 
- 
-@@ -1435,6 +1459,8 @@ class TestSpawningThread(threading.Thread):
-       args.append('--ssl-cert=' + options.ssl_cert)
-     if options.http_proxy:
-       args.append('--http-proxy=' + options.http_proxy)
-+    if options.httpd_version:
-+      args.append('--httpd-version=' + options.httpd_version)
- 
-     result, stdout_lines, stderr_lines = spawn_process(command, 0, False, None,
-                                                        *args)
-@@ -1600,6 +1626,12 @@ class TestRunner:
-       sandbox.cleanup_test_paths()
-     return exit_code
- 
-+def is_httpd_authz_provider_enabled():
-+    if is_ra_type_dav():
-+      v = options.httpd_version.split('.')
-+      return (v[0] == '2' and int(v[1]) >= 3) or int(v[0]) > 2
-+    return None
-+
- ######################################################################
- # Main testing functions
- 
-@@ -1780,6 +1812,8 @@ def _create_parser():
-                     help='Path to SSL server certificate.')
-   parser.add_option('--http-proxy', action='store',
-                     help='Use the HTTP Proxy at hostname:port.')
-+  parser.add_option('--httpd-version', action='store',
-+                    help='Assume HTTPD is this version.')
-   parser.add_option('--tools-bin', action='store', dest='tools_bin',
-                     help='Use the svn tools installed in this path')
- 
-Index: win-tests.py
-===================================================================
---- a/win-tests.py	(revision 1691883)
-+++ b/win-tests.py	(working copy)
-@@ -481,6 +481,7 @@ class Httpd:
-     self.httpd_config = os.path.join(self.root, 'httpd.conf')
-     self.httpd_users = os.path.join(self.root, 'users')
-     self.httpd_mime_types = os.path.join(self.root, 'mime.types')
-+    self.httpd_groups = os.path.join(self.root, 'groups')
-     self.abs_builddir = abs_builddir
-     self.abs_objdir = abs_objdir
-     self.service_name = 'svn-test-httpd-' + str(httpd_port)
-@@ -494,6 +495,7 @@ class Httpd:
-     create_target_dir(self.root_dir)
- 
-     self._create_users_file()
-+    self._create_groups_file()
-     self._create_mime_types_file()
-     self._create_dontdothat_file()
- 
-@@ -540,6 +542,8 @@ class Httpd:
-     if self.httpd_ver >= 2.2:
-       fp.write(self._sys_module('auth_basic_module', 'mod_auth_basic.so'))
-       fp.write(self._sys_module('authn_file_module', 'mod_authn_file.so'))
-+      fp.write(self._sys_module('authz_groupfile_module', 'mod_authz_groupfile.so'))
-+      fp.write(self._sys_module('authz_host_module', 'mod_authz_host.so'))
-     else:
-       fp.write(self._sys_module('auth_module', 'mod_auth.so'))
-     fp.write(self._sys_module('alias_module', 'mod_alias.so'))
-@@ -562,6 +566,7 @@ class Httpd:
-     # Define two locations for repositories
-     fp.write(self._svn_repo('repositories'))
-     fp.write(self._svn_repo('local_tmp'))
-+    fp.write(self._svn_authz_repo())
- 
-     # And two redirects for the redirect tests
-     fp.write('RedirectMatch permanent ^/svn-test-work/repositories/'
-@@ -592,7 +597,18 @@ class Httpd:
-                                     'jrandom', 'rayjandom'])
-     os.spawnv(os.P_WAIT, htpasswd, ['htpasswd.exe', '-bp',  self.httpd_users,
-                                     'jconstant', 'rayjandom'])
-+    os.spawnv(os.P_WAIT, htpasswd, ['htpasswd.exe', '-bp',  self.httpd_users,
-+                                    'JRANDOM', 'rayjandom'])
-+    os.spawnv(os.P_WAIT, htpasswd, ['htpasswd.exe', '-bp',  self.httpd_users,
-+                                    'JCONSTANT', 'rayjandom'])
- 
-+  def _create_groups_file(self):
-+    "Create groups for mod_authz_svn tests"
-+    fp = open(self.httpd_groups, 'w')
-+    fp.write('random: jrandom\n')
-+    fp.write('constant: jconstant\n')
-+    fp.close()
-+
-   def _create_mime_types_file(self):
-     "Create empty mime.types file"
-     fp = open(self.httpd_mime_types, 'w')
-@@ -652,6 +668,153 @@ class Httpd:
-       '  DontDoThatConfigFile ' + self._quote(self.dontdothat_file) + '\n' \
-       '</Location>\n'
- 
-+  def _svn_authz_repo(self):
-+    local_tmp = os.path.join(self.abs_builddir,
-+                             CMDLINE_TEST_SCRIPT_NATIVE_PATH,
-+                             'svn-test-work', 'local_tmp')
-+    return \
-+      '<Location /authz-test-work/anon>' + '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  <IfModule mod_authz_core.c>' + '\n' \
-+      '    Require all granted' + '\n' \
-+      '  </IfModule>' + '\n' \
-+      '  <IfModule !mod_authz_core.c>' + '\n' \
-+      '    Allow from all' + '\n' \
-+      '  </IfModule>' + '\n' \
-+      '  SVNPathAuthz ' + self.path_authz_option + '\n' \
-+      '</Location>' + '\n' \
-+      '<Location /authz-test-work/mixed>' + '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  AuthType          Basic' + '\n' \
-+      '  AuthName          "Subversion Repository"' + '\n' \
-+      '  AuthUserFile    ' + self._quote(self.httpd_users) + '\n' \
-+      '  Require           valid-user' + '\n' \
-+      '  Satisfy Any' + '\n' \
-+      '  SVNPathAuthz ' + self.path_authz_option + '\n' \
-+      '</Location>' + '\n' \
-+      '<Location /authz-test-work/mixed-noauthwhenanon>' + '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  AuthType          Basic' + '\n' \
-+      '  AuthName          "Subversion Repository"' + '\n' \
-+      '  AuthUserFile    ' + self._quote(self.httpd_users) + '\n' \
-+      '  Require           valid-user' + '\n' \
-+      '  AuthzSVNNoAuthWhenAnonymousAllowed On' + '\n' \
-+      '  SVNPathAuthz On' + '\n' \
-+      '</Location>' + '\n' \
-+      '<Location /authz-test-work/authn>' + '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  AuthType          Basic' + '\n' \
-+      '  AuthName          "Subversion Repository"' + '\n' \
-+      '  AuthUserFile    ' + self._quote(self.httpd_users) + '\n' \
-+      '  Require           valid-user' + '\n' \
-+      '  SVNPathAuthz ' + self.path_authz_option + '\n' \
-+      '</Location>' + '\n' \
-+      '<Location /authz-test-work/authn-anonoff>' + '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  AuthType          Basic' + '\n' \
-+      '  AuthName          "Subversion Repository"' + '\n' \
-+      '  AuthUserFile    ' + self._quote(self.httpd_users) + '\n' \
-+      '  Require           valid-user' + '\n' \
-+      '  AuthzSVNAnonymous Off' + '\n' \
-+      '  SVNPathAuthz On' + '\n' \
-+      '</Location>' + '\n' \
-+      '<Location /authz-test-work/authn-lcuser>' + '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  AuthType          Basic' + '\n' \
-+      '  AuthName          "Subversion Repository"' + '\n' \
-+      '  AuthUserFile    ' + self._quote(self.httpd_users) + '\n' \
-+      '  Require           valid-user' + '\n' \
-+      '  AuthzForceUsernameCase Lower' + '\n' \
-+      '  SVNPathAuthz ' + self.path_authz_option + '\n' \
-+      '</Location>' + '\n' \
-+      '<Location /authz-test-work/authn-lcuser>' + '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  AuthType          Basic' + '\n' \
-+      '  AuthName          "Subversion Repository"' + '\n' \
-+      '  AuthUserFile    ' + self._quote(self.httpd_users) + '\n' \
-+      '  Require           valid-user' + '\n' \
-+      '  AuthzForceUsernameCase Lower' + '\n' \
-+      '  SVNPathAuthz ' + self.path_authz_option + '\n' \
-+      '</Location>' + '\n' \
-+      '<Location /authz-test-work/authn-group>' + '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  AuthType          Basic' + '\n' \
-+      '  AuthName          "Subversion Repository"' + '\n' \
-+      '  AuthUserFile    ' + self._quote(self.httpd_users) + '\n' \
-+      '  AuthGroupFile    ' + self._quote(self.httpd_groups) + '\n' \
-+      '  Require           group random' + '\n' \
-+      '  AuthzSVNAuthoritative Off' + '\n' \
-+      '  SVNPathAuthz On' + '\n' \
-+      '</Location>' + '\n' \
-+      '<IfModule mod_authz_core.c>' + '\n' \
-+      '<Location /authz-test-work/sallrany>' + '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  AuthType          Basic' + '\n' \
-+      '  AuthName          "Subversion Repository"' + '\n' \
-+      '  AuthUserFile    ' + self._quote(self.httpd_users) + '\n' \
-+      '  AuthzSendForbiddenOnFailure On' + '\n' \
-+      '  Satisfy All' + '\n' \
-+      '  <RequireAny>' + '\n' \
-+      '    Require valid-user' + '\n' \
-+      '    Require expr req(\'ALLOW\') == \'1\'' + '\n' \
-+      '  </RequireAny>' + '\n' \
-+      '  SVNPathAuthz ' + self.path_authz_option + '\n' \
-+      '</Location>' + '\n' \
-+      '<Location /authz-test-work/sallrall>'+ '\n' \
-+      '  DAV               svn' + '\n' \
-+      '  SVNParentPath     ' + local_tmp + '\n' \
-+      '  AuthzSVNAccessFile ' + self._quote(self.authz_file) + '\n' \
-+      '  SVNAdvertiseV2Protocol ' + self.httpv2_option + '\n' \
-+      '  SVNListParentPath On' + '\n' \
-+      '  AuthType          Basic' + '\n' \
-+      '  AuthName          "Subversion Repository"' + '\n' \
-+      '  AuthUserFile    ' + self._quote(self.httpd_users) + '\n' \
-+      '  AuthzSendForbiddenOnFailure On' + '\n' \
-+      '  Satisfy All' + '\n' \
-+      '  <RequireAll>' + '\n' \
-+      '    Require valid-user' + '\n' \
-+      '    Require expr req(\'ALLOW\') == \'1\'' + '\n' \
-+      '  </RequireAll>' + '\n' \
-+      '  SVNPathAuthz ' + self.path_authz_option + '\n' \
-+      '</Location>' + '\n' \
-+      '</IfModule>' + '\n' \
-+
-   def start(self):
-     if self.service:
-       self._start_service()
-@@ -786,6 +949,10 @@ if not test_javahl:
-     log_file = os.path.join(abs_builddir, log)
-     fail_log_file = os.path.join(abs_builddir, faillog)
- 
-+  if run_httpd:
-+    httpd_version = "%.1f" % daemon.httpd_ver
-+  else:
-+    httpd_version = None
-   th = run_tests.TestHarness(abs_srcdir, abs_builddir,
-                              log_file,
-                              fail_log_file,
-@@ -795,6 +962,7 @@ if not test_javahl:
-                              fsfs_sharding, fsfs_packing,
-                              list_tests, svn_bin, mode_filter,
-                              milestone_filter,
-+                             httpd_version=httpd_version,
-                              set_log_level=log_level, ssl_cert=ssl_cert)
-   old_cwd = os.getcwd()
-   try:
diff --git a/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/subversion-CVE-2015-3187.patch b/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/subversion-CVE-2015-3187.patch
deleted file mode 100644
index 494e11c..0000000
--- a/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/subversion-CVE-2015-3187.patch
+++ /dev/null
@@ -1,346 +0,0 @@
-Fix CVE-2015-3187
-
-Patch is from:
-http://subversion.apache.org/security/CVE-2015-3187-advisory.txt
-
-Upstream-Status: Backport
-
-Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
-
-Index: subversion/libsvn_repos/rev_hunt.c
-===================================================================
---- a/subversion/libsvn_repos/rev_hunt.c	(revision 1685077)
-+++ b/subversion/libsvn_repos/rev_hunt.c	(working copy)
-@@ -726,23 +726,6 @@ svn_repos_trace_node_locations(svn_fs_t *fs,
-       if (! prev_path)
-         break;
- 
--      if (authz_read_func)
--        {
--          svn_boolean_t readable;
--          svn_fs_root_t *tmp_root;
--
--          SVN_ERR(svn_fs_revision_root(&tmp_root, fs, revision, currpool));
--          SVN_ERR(authz_read_func(&readable, tmp_root, path,
--                                  authz_read_baton, currpool));
--          if (! readable)
--            {
--              svn_pool_destroy(lastpool);
--              svn_pool_destroy(currpool);
--
--              return SVN_NO_ERROR;
--            }
--        }
--
-       /* Assign the current path to all younger revisions until we reach
-          the copy target rev. */
-       while ((revision_ptr < revision_ptr_end)
-@@ -765,6 +748,20 @@ svn_repos_trace_node_locations(svn_fs_t *fs,
-       path = prev_path;
-       revision = prev_rev;
- 
-+      if (authz_read_func)
-+        {
-+          svn_boolean_t readable;
-+          SVN_ERR(svn_fs_revision_root(&root, fs, revision, currpool));
-+          SVN_ERR(authz_read_func(&readable, root, path,
-+                                  authz_read_baton, currpool));
-+          if (!readable)
-+            {
-+              svn_pool_destroy(lastpool);
-+              svn_pool_destroy(currpool);
-+              return SVN_NO_ERROR;
-+            }
-+        }
-+
-       /* Clear last pool and switch. */
-       svn_pool_clear(lastpool);
-       tmppool = lastpool;
-Index: subversion/tests/cmdline/authz_tests.py
-===================================================================
---- a/subversion/tests/cmdline/authz_tests.py	(revision 1685077)
-+++ b/subversion/tests/cmdline/authz_tests.py	(working copy)
-@@ -609,8 +609,10 @@ def authz_log_and_tracing_test(sbox):
- 
-   ## cat
- 
-+  expected_err2 = ".*svn: E195012: Unable to find repository location.*"
-+
-   # now see if we can look at the older version of rho
--  svntest.actions.run_and_verify_svn(None, None, expected_err,
-+  svntest.actions.run_and_verify_svn(None, None, expected_err2,
-                                      'cat', '-r', '2', D_url+'/rho')
- 
-   if sbox.repo_url.startswith('http'):
-@@ -627,10 +629,11 @@ def authz_log_and_tracing_test(sbox):
-   svntest.actions.run_and_verify_svn(None, None, expected_err,
-                                      'diff', '-r', 'HEAD', G_url+'/rho')
- 
--  svntest.actions.run_and_verify_svn(None, None, expected_err,
-+  # diff treats the unreadable path as indicating an add so no error
-+  svntest.actions.run_and_verify_svn(None, None, [],
-                                      'diff', '-r', '2', D_url+'/rho')
- 
--  svntest.actions.run_and_verify_svn(None, None, expected_err,
-+  svntest.actions.run_and_verify_svn(None, None, [],
-                                      'diff', '-r', '2:4', D_url+'/rho')
- 
- # test whether read access is correctly granted and denied
-Index: subversion/tests/libsvn_repos/repos-test.c
-===================================================================
---- a/subversion/tests/libsvn_repos/repos-test.c	(revision 1685077)
-+++ b/subversion/tests/libsvn_repos/repos-test.c	(working copy)
-@@ -3524,6 +3524,245 @@ test_load_r0_mergeinfo(const svn_test_opts_t *opts
-   return SVN_NO_ERROR;
- }
- 
-+static svn_error_t *
-+mkdir_delete_copy(svn_repos_t *repos,
-+                  const char *src,
-+                  const char *dst,
-+                  apr_pool_t *pool)
-+{
-+  svn_fs_t *fs = svn_repos_fs(repos);
-+  svn_revnum_t youngest_rev;
-+  svn_fs_txn_t *txn;
-+  svn_fs_root_t *txn_root, *rev_root;
-+
-+  SVN_ERR(svn_fs_youngest_rev(&youngest_rev, fs, pool));
-+  
-+  SVN_ERR(svn_fs_begin_txn(&txn, fs, youngest_rev, pool));
-+  SVN_ERR(svn_fs_txn_root(&txn_root, txn, pool));
-+  SVN_ERR(svn_fs_make_dir(txn_root, "A/T", pool));
-+  SVN_ERR(svn_repos_fs_commit_txn(NULL, repos, &youngest_rev, txn, pool));
-+
-+  SVN_ERR(svn_fs_begin_txn(&txn, fs, youngest_rev, pool));
-+  SVN_ERR(svn_fs_txn_root(&txn_root, txn, pool));
-+  SVN_ERR(svn_fs_delete(txn_root, "A/T", pool));
-+  SVN_ERR(svn_repos_fs_commit_txn(NULL, repos, &youngest_rev, txn, pool));
-+
-+  SVN_ERR(svn_fs_begin_txn(&txn, fs, youngest_rev, pool));
-+  SVN_ERR(svn_fs_txn_root(&txn_root, txn, pool));
-+  SVN_ERR(svn_fs_revision_root(&rev_root, fs, youngest_rev - 1, pool));
-+  SVN_ERR(svn_fs_copy(rev_root, src, txn_root, dst, pool));
-+  SVN_ERR(svn_repos_fs_commit_txn(NULL, repos, &youngest_rev, txn, pool));
-+
-+  return SVN_NO_ERROR;
-+}
-+
-+struct authz_read_baton_t {
-+  apr_hash_t *paths;
-+  apr_pool_t *pool;
-+  const char *deny;
-+};
-+
-+static svn_error_t *
-+authz_read_func(svn_boolean_t *allowed,
-+                svn_fs_root_t *root,
-+                const char *path,
-+                void *baton,
-+                apr_pool_t *pool)
-+{
-+  struct authz_read_baton_t *b = baton;
-+
-+  if (b->deny && !strcmp(b->deny, path))
-+    *allowed = FALSE;
-+  else
-+    *allowed = TRUE;
-+
-+  svn_hash_sets(b->paths, apr_pstrdup(b->pool, path), (void*)1);
-+
-+  return SVN_NO_ERROR;
-+}
-+
-+static svn_error_t *
-+verify_locations(apr_hash_t *actual,
-+                 apr_hash_t *expected,
-+                 apr_hash_t *checked,
-+                 apr_pool_t *pool)
-+{
-+  apr_hash_index_t *hi;
-+
-+  for (hi = apr_hash_first(pool, expected); hi; hi = apr_hash_next(hi))
-+    {
-+      const svn_revnum_t *rev = svn__apr_hash_index_key(hi);
-+      const char *path = apr_hash_get(actual, rev, sizeof(svn_revnum_t));
-+
-+      if (!path)
-+        return svn_error_createf(SVN_ERR_TEST_FAILED, NULL,
-+                                 "expected %s for %d found (null)",
-+                                 (char*)svn__apr_hash_index_val(hi),
-+                                 (int)*rev);
-+      else if (strcmp(path, svn__apr_hash_index_val(hi)))
-+        return svn_error_createf(SVN_ERR_TEST_FAILED, NULL,
-+                                 "expected %s for %d found %s",
-+                                 (char*)svn__apr_hash_index_val(hi),
-+                                 (int)*rev, path);
-+
-+    }
-+
-+  for (hi = apr_hash_first(pool, actual); hi; hi = apr_hash_next(hi))
-+    {
-+      const svn_revnum_t *rev = svn__apr_hash_index_key(hi);
-+      const char *path = apr_hash_get(expected, rev, sizeof(svn_revnum_t));
-+
-+      if (!path)
-+        return svn_error_createf(SVN_ERR_TEST_FAILED, NULL,
-+                                 "found %s for %d expected (null)",
-+                                 (char*)svn__apr_hash_index_val(hi),
-+                                 (int)*rev);
-+      else if (strcmp(path, svn__apr_hash_index_val(hi)))
-+        return svn_error_createf(SVN_ERR_TEST_FAILED, NULL,
-+                                 "found %s for %d expected %s",
-+                                 (char*)svn__apr_hash_index_val(hi),
-+                                 (int)*rev, path);
-+
-+      if (!svn_hash_gets(checked, path))
-+        return svn_error_createf(SVN_ERR_TEST_FAILED, NULL,
-+                                 "did not check %s", path);
-+    }
-+
-+  return SVN_NO_ERROR;
-+}
-+
-+static void
-+set_expected(apr_hash_t *expected,
-+             svn_revnum_t rev,
-+             const char *path,
-+             apr_pool_t *pool)
-+{
-+  svn_revnum_t *rp = apr_palloc(pool, sizeof(svn_revnum_t));
-+  *rp = rev;
-+  apr_hash_set(expected, rp, sizeof(svn_revnum_t), path);
-+}
-+
-+static svn_error_t *
-+trace_node_locations_authz(const svn_test_opts_t *opts,
-+                           apr_pool_t *pool)
-+{
-+  svn_repos_t *repos;
-+  svn_fs_t *fs;
-+  svn_revnum_t youngest_rev = 0;
-+  svn_fs_txn_t *txn;
-+  svn_fs_root_t *txn_root;
-+  struct authz_read_baton_t arb;
-+  apr_array_header_t *revs = apr_array_make(pool, 10, sizeof(svn_revnum_t));
-+  apr_hash_t *locations;
-+  apr_hash_t *expected = apr_hash_make(pool);
-+  int i;
-+
-+  /* Create test repository. */
-+  SVN_ERR(svn_test__create_repos(&repos, "test-repo-trace-node-locations-authz",
-+                                 opts, pool));
-+  fs = svn_repos_fs(repos);
-+
-+  /* r1 create A */
-+  SVN_ERR(svn_fs_begin_txn(&txn, fs, youngest_rev, pool));
-+  SVN_ERR(svn_fs_txn_root(&txn_root, txn, pool));
-+  SVN_ERR(svn_fs_make_dir(txn_root, "A", pool));
-+  SVN_ERR(svn_fs_make_file(txn_root, "A/f", pool));
-+  SVN_ERR(svn_test__set_file_contents(txn_root, "A/f", "foobar", pool));
-+  SVN_ERR(svn_repos_fs_commit_txn(NULL, repos, &youngest_rev, txn, pool));
-+
-+  /* r4 copy A to B */
-+  SVN_ERR(mkdir_delete_copy(repos, "A", "B", pool));
-+
-+  /* r7 copy B to C */
-+  SVN_ERR(mkdir_delete_copy(repos, "B", "C", pool));
-+
-+  /* r10 copy C to D */
-+  SVN_ERR(mkdir_delete_copy(repos, "C", "D", pool));
-+
-+  SVN_ERR(svn_fs_youngest_rev(&youngest_rev, fs, pool));
-+  SVN_ERR_ASSERT(youngest_rev == 10);
-+
-+  arb.paths = apr_hash_make(pool);
-+  arb.pool = pool;
-+  arb.deny = NULL;
-+
-+  apr_array_clear(revs);
-+  for (i = 0; i <= youngest_rev; ++i)
-+    APR_ARRAY_PUSH(revs, svn_revnum_t) = i;
-+  set_expected(expected, 10, "/D/f", pool);
-+  set_expected(expected, 8, "/C/f", pool);
-+  set_expected(expected, 7, "/C/f", pool);
-+  set_expected(expected, 5, "/B/f", pool);
-+  set_expected(expected, 4, "/B/f", pool);
-+  set_expected(expected, 2, "/A/f", pool);
-+  set_expected(expected, 1, "/A/f", pool);
-+  apr_hash_clear(arb.paths);
-+  SVN_ERR(svn_repos_trace_node_locations(fs, &locations, "D/f", 10, revs,
-+                                         authz_read_func, &arb, pool));
-+  SVN_ERR(verify_locations(locations, expected, arb.paths, pool));
-+
-+  apr_array_clear(revs);
-+  for (i = 1; i <= youngest_rev; ++i)
-+    APR_ARRAY_PUSH(revs, svn_revnum_t) = i;
-+  apr_hash_clear(arb.paths);
-+  SVN_ERR(svn_repos_trace_node_locations(fs, &locations, "D/f", 10, revs,
-+                                         authz_read_func, &arb, pool));
-+  SVN_ERR(verify_locations(locations, expected, arb.paths, pool));
-+
-+  apr_array_clear(revs);
-+  for (i = 2; i <= youngest_rev; ++i)
-+    APR_ARRAY_PUSH(revs, svn_revnum_t) = i;
-+  set_expected(expected, 1, NULL, pool);
-+  apr_hash_clear(arb.paths);
-+  SVN_ERR(svn_repos_trace_node_locations(fs, &locations, "D/f", 10, revs,
-+                                         authz_read_func, &arb, pool));
-+  SVN_ERR(verify_locations(locations, expected, arb.paths, pool));
-+
-+  apr_array_clear(revs);
-+  for (i = 3; i <= youngest_rev; ++i)
-+    APR_ARRAY_PUSH(revs, svn_revnum_t) = i;
-+  set_expected(expected, 2, NULL, pool);
-+  apr_hash_clear(arb.paths);
-+  SVN_ERR(svn_repos_trace_node_locations(fs, &locations, "D/f", 10, revs,
-+                                         authz_read_func, &arb, pool));
-+  SVN_ERR(verify_locations(locations, expected, arb.paths, pool));
-+
-+  apr_array_clear(revs);
-+  for (i = 6; i <= youngest_rev; ++i)
-+    APR_ARRAY_PUSH(revs, svn_revnum_t) = i;
-+  set_expected(expected, 5, NULL, pool);
-+  set_expected(expected, 4, NULL, pool);
-+  apr_hash_clear(arb.paths);
-+  SVN_ERR(svn_repos_trace_node_locations(fs, &locations, "D/f", 10, revs,
-+                                         authz_read_func, &arb, pool));
-+  SVN_ERR(verify_locations(locations, expected, arb.paths, pool));
-+
-+  arb.deny = "/B/f";
-+  apr_array_clear(revs);
-+  for (i = 0; i <= youngest_rev; ++i)
-+    APR_ARRAY_PUSH(revs, svn_revnum_t) = i;
-+  apr_hash_clear(arb.paths);
-+  SVN_ERR(svn_repos_trace_node_locations(fs, &locations, "D/f", 10, revs,
-+                                         authz_read_func, &arb, pool));
-+  SVN_ERR(verify_locations(locations, expected, arb.paths, pool));
-+
-+  apr_array_clear(revs);
-+  for (i = 6; i <= youngest_rev; ++i)
-+    APR_ARRAY_PUSH(revs, svn_revnum_t) = i;
-+  apr_hash_clear(arb.paths);
-+  SVN_ERR(svn_repos_trace_node_locations(fs, &locations, "D/f", 10, revs,
-+                                         authz_read_func, &arb, pool));
-+  SVN_ERR(verify_locations(locations, expected, arb.paths, pool));
-+
-+  APR_ARRAY_PUSH(revs, svn_revnum_t) = 0;
-+  apr_hash_clear(arb.paths);
-+  SVN_ERR(svn_repos_trace_node_locations(fs, &locations, "D/f", 10, revs,
-+                                         authz_read_func, &arb, pool));
-+  SVN_ERR(verify_locations(locations, expected, arb.paths, pool));
-+
-+  return SVN_NO_ERROR;
-+}
-+
- /* The test table.  */
- 
- struct svn_test_descriptor_t test_funcs[] =
-@@ -3573,5 +3812,7 @@ struct svn_test_descriptor_t test_funcs[] =
-                        "test dumping with r0 mergeinfo"),
-     SVN_TEST_OPTS_PASS(test_load_r0_mergeinfo,
-                        "test loading with r0 mergeinfo"),
-+    SVN_TEST_OPTS_PASS(trace_node_locations_authz,
-+                       "authz for svn_repos_trace_node_locations"),
-     SVN_TEST_NULL
-   };
diff --git a/yocto-poky/meta/recipes-devtools/subversion/subversion/0001-Fix-libtool-name-in-configure.ac.patch b/yocto-poky/meta/recipes-devtools/subversion/subversion/0001-Fix-libtool-name-in-configure.ac.patch
new file mode 100644
index 0000000..5a1b10b
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/subversion/subversion/0001-Fix-libtool-name-in-configure.ac.patch
@@ -0,0 +1,29 @@
+From cbcfe0399347989e45a8fb695f55c855d6b3da72 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Mon, 7 Dec 2015 17:11:02 +0200
+Subject: [PATCH] Fix libtool name in configure.ac
+
+Upstream-Status: Inappropriate [embedded specific]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ configure.ac | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 4ed66d4..ceb64f9 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -221,8 +221,8 @@ if test "$experimental_libtool" = "yes"; then
+   LIBTOOL="$sh_libtool"
+   SVN_LIBTOOL="$sh_libtool"
+ else
+-  sh_libtool="$abs_builddir/libtool"
+-  SVN_LIBTOOL="\$(SHELL) \"$sh_libtool\""
++  sh_libtool="$abs_builddir/$host_alias-libtool"
++  SVN_LIBTOOL="\$(SHELL) \$(abs_builddir)/$host_alias-libtool"
+ fi
+ AC_SUBST(SVN_LIBTOOL)
+ 
+-- 
+2.6.2
+
diff --git a/yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/disable_macos.patch b/yocto-poky/meta/recipes-devtools/subversion/subversion/disable_macos.patch
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/subversion/subversion-1.8.13/disable_macos.patch
rename to yocto-poky/meta/recipes-devtools/subversion/subversion/disable_macos.patch
diff --git a/yocto-poky/meta/recipes-devtools/subversion/subversion/serf.m4-Regex-modified-to-allow-D-in-paths.patch b/yocto-poky/meta/recipes-devtools/subversion/subversion/serf.m4-Regex-modified-to-allow-D-in-paths.patch
new file mode 100644
index 0000000..9fed3cf
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/subversion/subversion/serf.m4-Regex-modified-to-allow-D-in-paths.patch
@@ -0,0 +1,32 @@
+From f1b6e49f12a18eabe88eb732b578a16281d09499 Mon Sep 17 00:00:00 2001
+From: Jose Lamego <jose.a.lamego@linux.intel.com>
+Date: Thu, 2 Jul 2015 11:37:43 +0000
+Subject: [PATCH] serf.m4: Regex modified to allow '-D' in paths
+
+Upstream-Status: Accepted
+
+The patch is merged by subversion upstream with replacing '[[:space:]]' with ' '.
+
+http://svn.apache.org/viewvc/subversion/trunk/build/ac-macros/serf.m4?r1=1594156&r2=1689824  
+
+Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
+---
+ build/ac-macros/serf.m4 | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/build/ac-macros/serf.m4 b/build/ac-macros/serf.m4
+index ae11e75..ff8cbae 100644
+--- a/build/ac-macros/serf.m4
++++ b/build/ac-macros/serf.m4
+@@ -168,7 +168,7 @@
+         if $PKG_CONFIG $serf_pc_arg --atleast-version=$serf_check_version; then
+           AC_MSG_RESULT([yes])
+           serf_found=yes
+-          SVN_SERF_INCLUDES=[`$PKG_CONFIG $serf_pc_arg --cflags | $SED -e 's/-D[^ ]*//g'`]
++          SVN_SERF_INCLUDES=[`$PKG_CONFIG $serf_pc_arg --cflags | $SED -e 's/ -D[^ ]*//g' -e 's/^-D[^ ]*//g'`]
+           SVN_SERF_LIBS=`$PKG_CONFIG $serf_pc_arg --libs-only-l` 
+           dnl don't use --libs-only-L because then we might miss some options
+           LDFLAGS=["$LDFLAGS `$PKG_CONFIG $serf_pc_arg --libs | $SED -e 's/-l[^ ]*//g'`"]
+-- 
+1.8.4.5
+
diff --git a/yocto-poky/meta/recipes-devtools/subversion/subversion_1.8.13.bb b/yocto-poky/meta/recipes-devtools/subversion/subversion_1.9.3.bb
similarity index 90%
rename from yocto-poky/meta/recipes-devtools/subversion/subversion_1.8.13.bb
rename to yocto-poky/meta/recipes-devtools/subversion/subversion_1.9.3.bb
index 68934b7..a19a675 100644
--- a/yocto-poky/meta/recipes-devtools/subversion/subversion_1.8.13.bb
+++ b/yocto-poky/meta/recipes-devtools/subversion/subversion_1.9.3.bb
@@ -11,16 +11,14 @@
 inherit gettext pythonnative
 
 SRC_URI = "${APACHE_MIRROR}/${BPN}/${BPN}-${PV}.tar.bz2 \
-           file://libtool2.patch \
            file://disable_macos.patch \
            file://serf.m4-Regex-modified-to-allow-D-in-paths.patch \
-           file://subversion-CVE-2015-3184.patch \
-           file://subversion-CVE-2015-3187.patch \
-"
-SRC_URI[md5sum] = "4413417b529d7bdf82f74e50df02e88b"
-SRC_URI[sha256sum] = "1099cc68840753b48aedb3a27ebd1e2afbcc84ddb871412e5d500e843d607579"
+           file://0001-Fix-libtool-name-in-configure.ac.patch \
+           "
+SRC_URI[md5sum] = "243036eb28b50ce517fc228eb3250add"
+SRC_URI[sha256sum] = "8bbf6bb125003d88ee1c22935a36b7b1ab7d957e0c8b5fbfe5cb6310b6e86ae0"
 
-LIC_FILES_CHKSUM = "file://LICENSE;md5=1c2f0119e478700b5428e26386cff923"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=af81ae49ba359e70626c05e9bf313709"
 
 PACKAGECONFIG[sasl] = "--with-sasl,--without-sasl,cyrus-sasl"
 PACKAGECONFIG[gnome-keyring] = "--with-gnome-keyring,--without-gnome-keyring,glib-2.0 gnome-keyring"
diff --git a/yocto-poky/meta/recipes-devtools/swig/swig.inc b/yocto-poky/meta/recipes-devtools/swig/swig.inc
index 9821fa5..9da40df 100644
--- a/yocto-poky/meta/recipes-devtools/swig/swig.inc
+++ b/yocto-poky/meta/recipes-devtools/swig/swig.inc
@@ -1,4 +1,4 @@
-DESCRIPTION = "SWIG - Simplified Wrapper and Interface Generator"
+SUMMARY = "SWIG - Simplified Wrapper and Interface Generator"
 HOMEPAGE = "http://swig.sourceforge.net/"
 LICENSE = "BSD & GPLv3"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=e7807a6282784a7dde4c846626b08fc6 \
diff --git a/yocto-poky/meta/recipes-devtools/swig/swig_3.0.6.bb b/yocto-poky/meta/recipes-devtools/swig/swig_3.0.6.bb
deleted file mode 100644
index 2a0917e..0000000
--- a/yocto-poky/meta/recipes-devtools/swig/swig_3.0.6.bb
+++ /dev/null
@@ -1,8 +0,0 @@
-require ${BPN}.inc
-
-SRC_URI += "file://0001-Use-proc-self-exe-for-swig-swiglib-on-non-Win32-plat.patch \
-            file://0001-configure-use-pkg-config-for-pcre-detection.patch \
-           "
-SRC_URI[md5sum] = "df43ae271642bcfa61c1e59f970f9963"
-SRC_URI[sha256sum] = "c67f63ea11956106e4cda66416d5020330dc4ce2ee45057d39a9494ce33eca05"
-
diff --git a/yocto-poky/meta/recipes-devtools/swig/swig_3.0.8.bb b/yocto-poky/meta/recipes-devtools/swig/swig_3.0.8.bb
new file mode 100644
index 0000000..c1b820e
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/swig/swig_3.0.8.bb
@@ -0,0 +1,8 @@
+require ${BPN}.inc
+
+SRC_URI += "file://0001-Use-proc-self-exe-for-swig-swiglib-on-non-Win32-plat.patch \
+            file://0001-configure-use-pkg-config-for-pcre-detection.patch \
+           "
+SRC_URI[md5sum] = "c96a1d5ecb13d38604d7e92148c73c97"
+SRC_URI[sha256sum] = "58a475dbbd4a4d7075e5fe86d4e54c9edde39847cdb96a3053d87cb64a23a453"
+
diff --git a/yocto-poky/meta/recipes-devtools/syslinux/syslinux_6.03.bb b/yocto-poky/meta/recipes-devtools/syslinux/syslinux_6.03.bb
index 8534528..ab8a51a 100644
--- a/yocto-poky/meta/recipes-devtools/syslinux/syslinux_6.03.bb
+++ b/yocto-poky/meta/recipes-devtools/syslinux/syslinux_6.03.bb
@@ -37,8 +37,6 @@
 	BINDIR=${bindir} SBINDIR=${sbindir} LIBDIR=${libdir} \
 	DATADIR=${datadir} MANDIR=${mandir} INCDIR=${includedir} \
 "
-# syslinux uses $LD for linking, strip `-Wl,' so it can work
-export LDFLAGS = "`echo $LDFLAGS | sed 's/-Wl,//g'`"
 
 do_configure() {
 	# drop win32 targets or build fails
@@ -59,11 +57,11 @@
 
 	# Rebuild only the installer; keep precompiled bootloaders
 	# as per author's request (doc/distrib.txt)
-	oe_runmake CC="${CC} ${CFLAGS}" LDFLAGS="${LDFLAGS}" firmware="bios" installer
+	oe_runmake CC="${CC} ${CFLAGS}" LD="${LD}" LDFLAGS="${LDFLAGS}" firmware="bios" installer
 }
 
 do_install() {
-	oe_runmake CC="${CC} ${CFLAGS}" install INSTALLROOT="${D}" firmware="bios"
+	oe_runmake CC="${CC} ${CFLAGS}" LD="${LD}" install INSTALLROOT="${D}" firmware="bios"
 
 	install -d ${D}${datadir}/syslinux/
 	install -m 644 ${S}/bios/core/ldlinux.sys ${D}${datadir}/syslinux/
diff --git a/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent/0001-canonicalize_file_name-is-specific-to-glibc.patch b/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent/0001-canonicalize_file_name-is-specific-to-glibc.patch
new file mode 100644
index 0000000..5f93c46
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent/0001-canonicalize_file_name-is-specific-to-glibc.patch
@@ -0,0 +1,46 @@
+From 23a3759b74d081b3b2849b0d37a0e5219f37813e Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 7 Jan 2016 22:37:48 +0000
+Subject: [PATCH] canonicalize_file_name is specific to glibc
+
+When on Linux and not using glibc then we need to define
+canonicalize_file_name() API, therefore add a check for finding out if
+its not glibc
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ agent/tcf/framework/mdep.c | 2 +-
+ agent/tcf/framework/mdep.h | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/agent/tcf/framework/mdep.c b/agent/tcf/framework/mdep.c
+index 2b52ca8..7d09655 100644
+--- a/agent/tcf/framework/mdep.c
++++ b/agent/tcf/framework/mdep.c
+@@ -1042,7 +1042,7 @@ char * canonicalize_file_name(const char * path) {
+     return strdup(res);
+ }
+ 
+-#elif defined(__UCLIBC__)
++#elif defined(__UCLIBC__) || !defined(__GLIBC__)
+ 
+ char * canonicalize_file_name(const char * path) {
+     return realpath(path, NULL);
+diff --git a/agent/tcf/framework/mdep.h b/agent/tcf/framework/mdep.h
+index 1e718a2..187c399 100644
+--- a/agent/tcf/framework/mdep.h
++++ b/agent/tcf/framework/mdep.h
+@@ -276,7 +276,7 @@ extern int loc_clock_gettime(int, struct timespec *);
+ 
+ #define O_BINARY 0
+ 
+-#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__APPLE__)
++#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__APPLE__) || !defined(__GLIBC__)
+ #  define O_LARGEFILE 0
+ extern char ** environ;
+ extern char * canonicalize_file_name(const char * path);
+-- 
+2.7.0
+
diff --git a/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent/ldflags.patch b/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent/ldflags.patch
new file mode 100644
index 0000000..c03c55d
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent/ldflags.patch
@@ -0,0 +1,28 @@
+Upstream-Status: Pending
+
+From d92af0483c20365fd0af740d0baef8870b4aa374 Mon Sep 17 00:00:00 2001
+From: Abdur Rehman <abdur_rehman@mentor.com>
+Date: Wed, 26 Aug 2015 19:18:11 +0500
+Subject: [PATCH] tcf-agent: obey LDFLAGS
+
+Signed-off-by: Abdur Rehman <abdur_rehman@mentor.com>
+---
+ Makefile.inc |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Makefile.inc b/Makefile.inc
+index 959028f..3148942 100644
+--- a/Makefile.inc
++++ b/Makefile.inc
+@@ -96,7 +96,7 @@ NO_LINK_F	?= -c
+ # Linker definition and flags
+ 
+ LINK		?= $(CC)
+-LINK_FLAGS	?= $(CFLAGS)
++LINK_FLAGS	?= $(LDFLAGS) $(CFLAGS)
+ LINK_OUT_F	?= $(OUT_OBJ_F)
+ 
+ # Archiver definition and flags
+-- 
+1.7.9.5
+
diff --git a/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb b/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
index f8fd390..ab2fcd7 100644
--- a/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
+++ b/yocto-poky/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
@@ -8,8 +8,11 @@
 SRCREV = "b9a735e9c7cf82f80d412b7ab15d08b89d5a4ccc"
 PV = "1.3.0+git${SRCPV}"
 
+UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(\d+(\.\d+)+))"
 SRC_URI = "git://git.eclipse.org/gitroot/tcf/org.eclipse.tcf.agent.git;branch=1.3_mars_bugfix \
            file://fix_ranlib.patch \
+           file://ldflags.patch \
+           file://0001-canonicalize_file_name-is-specific-to-glibc.patch;striplevel=2 \
            file://tcf-agent.init \
            file://tcf-agent.service \
           "
diff --git a/yocto-poky/meta/recipes-devtools/tcltk/tcl/fix-configure.patch b/yocto-poky/meta/recipes-devtools/tcltk/tcl/fix-configure.patch
deleted file mode 100644
index b692a0e..0000000
--- a/yocto-poky/meta/recipes-devtools/tcltk/tcl/fix-configure.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-Upstream-Status: Pending
-
-Index: unix/tcl.m4
-===================================================================
---- tcl8.4.11/unix.orig/tcl.m4
-+++ tcl8.4.11/unix/tcl.m4
-@@ -845,7 +845,7 @@ AC_DEFUN(SC_CONFIG_CFLAGS, [
- 	    # results, and the version is kept in special file).
- 	
- 	    if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
--		system=MP-RAS-`awk '{print $3}' /etc/.relid'`
-+		system=MP-RAS-`awk '{print $3}' /etc/.relid`
- 	    fi
- 	    if test "`uname -s`" = "AIX" ; then
- 		system=AIX-`uname -v`.`uname -r`
-@@ -2250,7 +2250,7 @@ AC_DEFUN(SC_BLOCKING_STYLE, [
- 	    # results, and the version is kept in special file).
- 	
- 	    if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
--		system=MP-RAS-`awk '{print $3}' /etc/.relid'`
-+		system=MP-RAS-`awk '{print $3}' /etc/.relid`
- 	    fi
- 	    if test "`uname -s`" = "AIX" ; then
- 		system=AIX-`uname -v`.`uname -r`
-Index: unix/configure
-===================================================================
---- tcl8.4.11/unix.orig/configure
-+++ tcl8.4.11/unix/configure
-@@ -2130,7 +2130,7 @@ echo "configure:2121: checking system ve
- 	    # results, and the version is kept in special file).
- 	
- 	    if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
--		system=MP-RAS-`awk '{print }' /etc/.relid'`
-+		system=MP-RAS-`awk '{print }' /etc/.relid`
- 	    fi
- 	    if test "`uname -s`" = "AIX" ; then
- 		system=AIX-`uname -v`.`uname -r`
-@@ -7608,7 +7608,7 @@ echo "configure:7600: checking FIONBIO v
- 	    # results, and the version is kept in special file).
- 	
- 	    if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
--		system=MP-RAS-`awk '{print }' /etc/.relid'`
-+		system=MP-RAS-`awk '{print }' /etc/.relid`
- 	    fi
- 	    if test "`uname -s`" = "AIX" ; then
- 		system=AIX-`uname -v`.`uname -r`
diff --git a/yocto-poky/meta/recipes-devtools/tcltk/tcl/fix_issue_with_old_distro_glibc.patch b/yocto-poky/meta/recipes-devtools/tcltk/tcl/fix_issue_with_old_distro_glibc.patch
index be27341..5b5de07 100644
--- a/yocto-poky/meta/recipes-devtools/tcltk/tcl/fix_issue_with_old_distro_glibc.patch
+++ b/yocto-poky/meta/recipes-devtools/tcltk/tcl/fix_issue_with_old_distro_glibc.patch
@@ -1,4 +1,4 @@
-Upstream-Status: inappropriate [embedded specific]
+Upstream-Status: Inappropriate [embedded specific]
 
 Fixes tcl target recipe build on old distros which have glibc older than 2.14
 
diff --git a/yocto-poky/meta/recipes-devtools/unfs3/unfs3/fix_warnings.patch b/yocto-poky/meta/recipes-devtools/unfs3/unfs3/fix_warnings.patch
deleted file mode 100644
index cda8655..0000000
--- a/yocto-poky/meta/recipes-devtools/unfs3/unfs3/fix_warnings.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-exports.*: fix warnings.
-
-Fix these warnings:
-lex.yy.c:1207: warning: 'yyunput' defined but not used
-lex.yy.c:1248: warning: 'input' defined but not used
-exports.y: In function 'set_hostname':
-exports.y:334: warning: large integer implicitly truncated to unsigned type
-exports.y: In function 'set_ipaddr':
-exports.y:350: warning: large integer implicitly truncated to unsigned type
-
-Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
-
-Upstream-Status: Submitted http://sourceforge.net/p/unfs3/bugs/5/
-
----
- Config/exports.l |    3 +++
- Config/exports.y |    6 ++++--
- 2 files changed, 7 insertions(+), 2 deletions(-)
-
---- a/Config/exports.l
-+++ b/Config/exports.l
-@@ -48,6 +48,9 @@ NETCOMP [0-9]{1,2}
- NET {IP}"/"{NETCOMP}
- OLDNET {IP}"/"{IP}
- 
-+%option nounput
-+%option noinput
-+
- %%
- 
- ^{WHITE}*\n		{ /* eat empty line */ }
---- a/Config/exports.y
-+++ b/Config/exports.y
-@@ -331,7 +331,8 @@ static void set_hostname(const char *nam
- 	if (ent) {
- 		memcpy(&cur_host.addr, ent->h_addr_list[0],
- 		       sizeof(struct in_addr));
--		cur_host.mask.s_addr = ~0UL;
-+		cur_host.mask.s_addr = 0;
-+		cur_host.mask.s_addr = ~cur_host.mask.s_addr;
- 	} else {
- 		logmsg(LOG_CRIT, "could not resolve hostname '%s'", name);
- 		e_error = TRUE;
-@@ -347,7 +348,8 @@ static void set_ipaddr(const char *addr)
- 	
- 	if (!inet_aton(addr, &cur_host.addr))
- 		e_error = TRUE;
--	cur_host.mask.s_addr = ~0UL;
-+	cur_host.mask.s_addr = 0;
-+	cur_host.mask.s_addr = ~cur_host.mask.s_addr;
- }
- 
- /*
diff --git a/yocto-poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r490.bb b/yocto-poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r497.bb
similarity index 83%
rename from yocto-poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r490.bb
rename to yocto-poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r497.bb
index 5130895..eba1139 100644
--- a/yocto-poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r490.bb
+++ b/yocto-poky/meta/recipes-devtools/unfs3/unfs3_0.9.22.r497.bb
@@ -4,32 +4,33 @@
 LIC_FILES_CHKSUM = "file://LICENSE;md5=9475885294e17c0cc0067820d042792e"
 
 # SVN support for upstream version check isn't implemented yet
-RECIPE_UPSTREAM_VERSION = "0.9.22.r495"
-RECIPE_UPSTREAM_DATE = "Feb 05, 2015"
-CHECK_DATE = "Jun 10, 2015"
+RECIPE_UPSTREAM_VERSION = "0.9.22.r497"
+RECIPE_UPSTREAM_DATE = "Oct 08, 2015"
+CHECK_DATE = "Dec 10, 2015"
 
 DEPENDS = "flex-native bison-native flex"
+DEPENDS_append_libc-musl = " libtirpc "
 DEPENDS_append_class-nativesdk += "flex-nativesdk"
 
-SRC_URI[md5sum] = "3687acc4ee992e536472365dd99712a7"
-SRC_URI[sha256sum] = "274b43ada9c6eea1da26eb7010d72889c5278984ba0b50dff4e093057d4d64f8"
-
-MOD_PV = "490"
+MOD_PV = "497"
 S = "${WORKDIR}/trunk"
-SRC_URI = "svn://svn.code.sf.net/p/unfs3/code;module=trunk;rev=${MOD_PV} \
+SRC_URI = "svn://svn.code.sf.net/p/unfs3/code;module=trunk;rev=${MOD_PV};protocol=http \
            file://unfs3_parallel_build.patch \
            file://alternate_rpc_ports.patch \
            file://fix_pid_race_parent_writes_child_pid.patch \
            file://fix_compile_warning.patch \
            file://rename_fh_cache.patch \
            file://relative_max_socket_path_len.patch \
-           file://fix_warnings.patch \
            file://tcp_no_delay.patch \
           "
+SRC_URI[md5sum] = "3687acc4ee992e536472365dd99712a7"
+SRC_URI[sha256sum] = "274b43ada9c6eea1da26eb7010d72889c5278984ba0b50dff4e093057d4d64f8"
+
 BBCLASSEXTEND = "native nativesdk"
 
 inherit autotools
 EXTRA_OECONF_append_class-native = " --sbindir=${bindir}"
+CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc"
 
 # Turn off these header detects else the inode search
 # will walk entire file systems and this is a real problem
diff --git a/yocto-poky/meta/recipes-devtools/unifdef/unifdef_2.10.bb b/yocto-poky/meta/recipes-devtools/unifdef/unifdef_2.10.bb
deleted file mode 100644
index b8a0079..0000000
--- a/yocto-poky/meta/recipes-devtools/unifdef/unifdef_2.10.bb
+++ /dev/null
@@ -1,15 +0,0 @@
-SUMMARY = "Selectively remove #ifdef statements from sources"
-SECTION = "devel"
-LICENSE = "BSD-2-Clause"
-
-LIC_FILES_CHKSUM = "file://unifdef.c;endline=32;md5=2cc23f0382a6f560f6a9ecf4e040c0da"
-
-SRC_URI = "http://dotat.at/prog/${BPN}/${BP}.tar.xz"
-SRC_URI[md5sum] = "bb5d895e5ebbba5c5cc0c2771cf97ebe"
-SRC_URI[sha256sum] = "3b9b2b6b1952e9b9c1b9f734edec270689a35bdbf33ae66b50e19b2ed0d2df06"
-
-do_install() {
-	oe_runmake install DESTDIR=${D} prefix=${prefix}
-}
-
-BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/unifdef/unifdef_2.11.bb b/yocto-poky/meta/recipes-devtools/unifdef/unifdef_2.11.bb
new file mode 100644
index 0000000..1d13b9a
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/unifdef/unifdef_2.11.bb
@@ -0,0 +1,17 @@
+SUMMARY = "Selectively remove #ifdef statements from sources"
+SECTION = "devel"
+LICENSE = "BSD-2-Clause"
+HOMEPAGE = "http://dotat.at/prog/unifdef/"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=78fc6c2c1dc4f18c891ed5b7a469fe32 \
+                    file://unifdef.c;endline=32;md5=aaec84d8b68d8b6dea71f45e9949ebfe"
+
+SRC_URI = "http://dotat.at/prog/${BPN}/${BP}.tar.xz"
+SRC_URI[md5sum] = "337053fd8a7d9ab3adf5e50f88af95b7"
+SRC_URI[sha256sum] = "828ffc270ac262b88fe011136acef2780c05b0dc3c5435d005651740788d4537"
+
+do_install() {
+	oe_runmake install DESTDIR=${D} prefix=${prefix}
+}
+
+BBCLASSEXTEND = "native"
diff --git a/yocto-poky/meta/recipes-devtools/vala/vala.inc b/yocto-poky/meta/recipes-devtools/vala/vala.inc
index 63056fd..2a8875f 100644
--- a/yocto-poky/meta/recipes-devtools/vala/vala.inc
+++ b/yocto-poky/meta/recipes-devtools/vala/vala.inc
@@ -3,6 +3,9 @@
 Vala compiles to plain C and has no runtime environment nor penalities whatsoever."
 SECTION = "devel"
 DEPENDS = "bison-native flex-native libxslt-native glib-2.0"
+
+# vala-native contains a native version of vapigen, which we use instead of the target one
+DEPENDS_append_class-target = " vala-native"
 BBCLASSEXTEND = "native"
 HOMEPAGE = "http://vala-project.org"
 LICENSE = "LGPLv2.1"
@@ -11,8 +14,38 @@
 SHRT_VER = "${@d.getVar('PV',1).split('.')[0]}.${@d.getVar('PV',1).split('.')[1]}"
 
 SRC_URI = "http://ftp.gnome.org/pub/GNOME/sources/${BPN}/${SHRT_VER}/${BP}.tar.xz"
-inherit autotools pkgconfig
+inherit autotools pkgconfig upstream-version-is-even
 
 FILES_${PN} += "${datadir}/${BPN}-${SHRT_VER}/vapi ${libdir}/${BPN}-${SHRT_VER}/"
 FILES_${PN}-doc += "${datadir}/devhelp"
-FILES_${PN}-dbg += "${libdir}/${BPN}-${SHRT_VER}/.debug"
+
+do_configure_prepend_class-target() {
+        # Write out a vapigen wrapper that will be provided by pkg-config file installed in target sysroot
+        # The wrapper will call a native vapigen
+        cat > ${B}/vapigen-wrapper << EOF
+#!/bin/sh
+vapigen-${SHRT_VER} "\$@"
+EOF
+        chmod +x ${B}/vapigen-wrapper
+}
+
+# Vapigen wrapper needs to be available system-wide, because it will be used
+# to build vapi files from all other packages with vala support
+do_install_append_class-target() {
+        install -d ${D}${bindir}/
+        install ${B}/vapigen-wrapper ${D}${bindir}/
+}
+
+
+SYSROOT_PREPROCESS_FUNCS_append_class-target += "vapigen_sysroot_preprocess"
+
+vapigen_sysroot_preprocess() {
+        # Put vapigen wrapper into target sysroot so that it can be used when building vapi files.
+        sysroot_stage_dir ${D}${bindir} ${SYSROOT_DESTDIR}${bindir}
+
+        # Also, tweak the vapigen name in vapigen pkgconfig file, so that it picks up our
+        # wrapper.
+        sed -i \
+           -e "s|vapigen=.*|vapigen=${bindir}/vapigen-wrapper|" \
+           ${SYSROOT_DESTDIR}${datadir}/pkgconfig/vapigen-${SHRT_VER}.pc
+}
diff --git a/yocto-poky/meta/recipes-devtools/vala/vala/0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch b/yocto-poky/meta/recipes-devtools/vala/vala/0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch
new file mode 100644
index 0000000..ecab0fc
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/vala/vala/0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch
@@ -0,0 +1,38 @@
+From dbb1c58e86f2af4613f3ac9571d9b163d4bca675 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 23 Oct 2015 16:13:54 +0300
+Subject: [PATCH] vapigen.m4: use $PKG_CONFIG_SYSROOT_DIR
+
+This is necessary in cross-compiling environments, where directories
+returned by pkg-config should be prefixed with sysroot location.
+
+Upstream-Status: Pending [review in oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ vapigen/vapigen.m4 | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/vapigen/vapigen.m4 b/vapigen/vapigen.m4
+index 2c435e7..6228991 100644
+--- a/vapigen/vapigen.m4
++++ b/vapigen/vapigen.m4
+@@ -82,12 +82,12 @@ AC_DEFUN([VAPIGEN_CHECK],
+ 
+   AS_CASE([$enable_vala],
+     [yes], [
+-      VAPIGEN=`$PKG_CONFIG --variable=vapigen $vapigen_pkg_name`
+-      VAPIGEN_MAKEFILE=`$PKG_CONFIG --variable=datadir $vapigen_pkg_name`/vala/Makefile.vapigen
++      VAPIGEN=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=vapigen $vapigen_pkg_name`
++      VAPIGEN_MAKEFILE=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=datadir $vapigen_pkg_name`/vala/Makefile.vapigen
+       AS_IF([test "x$2" = "x"], [
+-          VAPIGEN_VAPIDIR=`$PKG_CONFIG --variable=vapidir $vapigen_pkg_name`
++          VAPIGEN_VAPIDIR=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=vapidir $vapigen_pkg_name`
+         ], [
+-          VAPIGEN_VAPIDIR=`$PKG_CONFIG --variable=vapidir_versioned $vapigen_pkg_name`
++          VAPIGEN_VAPIDIR=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=vapidir_versioned $vapigen_pkg_name`
+         ])
+     ])
+ 
+-- 
+2.1.4
+
diff --git a/yocto-poky/meta/recipes-devtools/vala/vala_0.28.0.bb b/yocto-poky/meta/recipes-devtools/vala/vala_0.28.0.bb
deleted file mode 100644
index 120906c..0000000
--- a/yocto-poky/meta/recipes-devtools/vala/vala_0.28.0.bb
+++ /dev/null
@@ -1,6 +0,0 @@
-require ${BPN}.inc
-
-SRC_URI += " file://0001-git-version-gen-don-t-append-dirty-if-we-re-not-in-g.patch"
-
-SRC_URI[md5sum] = "8d4ceac3451a0d5497e7be38e5e4c2ad"
-SRC_URI[sha256sum] = "0d9e3bd3f82145664875f7c29b2f544ba92d2814f75412948f774c0727fc977f"
diff --git a/yocto-poky/meta/recipes-devtools/vala/vala_0.30.1.bb b/yocto-poky/meta/recipes-devtools/vala/vala_0.30.1.bb
new file mode 100644
index 0000000..6394afc
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/vala/vala_0.30.1.bb
@@ -0,0 +1,8 @@
+require ${BPN}.inc
+
+SRC_URI += " file://0001-git-version-gen-don-t-append-dirty-if-we-re-not-in-g.patch \
+             file://0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch \
+"
+
+SRC_URI[md5sum] = "cc2eb2384fc10038b643753d734a5a51"
+SRC_URI[sha256sum] = "23add78e5c6a5e6df019d4a885c9c79814c9e0b957519ec8a4f4d826c4e5df2c"
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0001-Remove-tests-that-fail-to-build-on-some-PPC32-config.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0001-Remove-tests-that-fail-to-build-on-some-PPC32-config.patch
new file mode 100644
index 0000000..a78e195
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0001-Remove-tests-that-fail-to-build-on-some-PPC32-config.patch
@@ -0,0 +1,51 @@
+From 9762fd23e1f1db66d4b977c694a17d3bca3fe99a Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 8 Jan 2016 16:36:29 +0200
+Subject: [PATCH] Remove tests that fail to build on some PPC32 configurations
+
+Failures are documented here:
+http://errors.yoctoproject.org/Errors/Search/?items=10&query=862d702fbb99e484631315aa44b9e46f8fc567da&filter=valgrind&type=recipe
+
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+Upstream-Status: Pending
+---
+ memcheck/tests/ppc32/Makefile.am | 2 +-
+ none/tests/ppc32/Makefile.am     | 4 ++--
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/memcheck/tests/ppc32/Makefile.am b/memcheck/tests/ppc32/Makefile.am
+index 26b95a2..8f05743 100644
+--- a/memcheck/tests/ppc32/Makefile.am
++++ b/memcheck/tests/ppc32/Makefile.am
+@@ -10,7 +10,7 @@ EXTRA_DIST = $(noinst_SCRIPTS) \
+ 	power_ISA2_07.stderr.exp power_ISA2_07.vgtest
+ 
+ check_PROGRAMS = \
+-	power_ISA2_05 power_ISA2_07
++	power_ISA2_07
+ 
+ power_ISA2_05_CFLAGS = $(AM_CFLAGS) $(WERROR) -Winline -Wall -Wshadow -g \
+ 		-I$(top_srcdir)/include @FLAG_M32@
+diff --git a/none/tests/ppc32/Makefile.am b/none/tests/ppc32/Makefile.am
+index 196239e..0fe3425 100644
+--- a/none/tests/ppc32/Makefile.am
++++ b/none/tests/ppc32/Makefile.am
+@@ -50,13 +50,13 @@ EXTRA_DIST = \
+ 
+ check_PROGRAMS = \
+ 	allexec \
+-	lsw jm-insns round \
++	lsw \
+ 	test_isa_2_06_part1 test_isa_2_06_part2 test_isa_2_06_part3 \
+ 	test_dfp1 test_dfp2 test_dfp3 test_dfp4 test_dfp5 \
+ 	test_isa_2_07_part1 test_isa_2_07_part2 \
+ 	test_tm test_touch_tm ldst_multiple data-cache-instructions \
+ 	test_fx test_gx \
+-	testVMX twi tw xlc_dbl_u32 power5+_round power6_bcmp \
++	twi tw xlc_dbl_u32 power6_bcmp \
+ 	bug129390-ppc32 bug139050-ppc32 \
+ 	ldstrev mftocrf mcrfs
+ 
+-- 
+2.6.4
+
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0001-fix-build-for-musl-targets.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0001-fix-build-for-musl-targets.patch
new file mode 100644
index 0000000..dc6feff
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0001-fix-build-for-musl-targets.patch
@@ -0,0 +1,69 @@
+From 1b1a024efd18d44294e184e792c1e039cab02bfe Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 14 Feb 2016 09:14:12 +0000
+Subject: [PATCH] fix build for musl targets
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+Upstream-Status: Pending
+
+ configure.ac             | 2 --
+ coregrind/vg_preloaded.c | 2 +-
+ include/pub_tool_redir.h | 7 +++++--
+ 3 files changed, 6 insertions(+), 5 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 9366dc7..679f514 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1066,8 +1066,6 @@ case "${GLIBC_VERSION}" in
+ 	;;
+      2.0|2.1|*)
+ 	AC_MSG_RESULT([unsupported version ${GLIBC_VERSION}])
+-	AC_MSG_ERROR([Valgrind requires glibc version 2.2 or later,])
+-	AC_MSG_ERROR([Darwin libc, Bionic libc or Solaris libc])
+ 	;;
+ esac
+ 
+diff --git a/coregrind/vg_preloaded.c b/coregrind/vg_preloaded.c
+index 2ea7a7a..e49c832 100644
+--- a/coregrind/vg_preloaded.c
++++ b/coregrind/vg_preloaded.c
+@@ -56,7 +56,7 @@
+ void VG_NOTIFY_ON_LOAD(freeres)( void );
+ void VG_NOTIFY_ON_LOAD(freeres)( void )
+ {
+-#  if !defined(__UCLIBC__) \
++#  if !defined(__UCLIBC__) && defined(__GLIBC__) \
+       && !defined(VGPV_arm_linux_android) \
+       && !defined(VGPV_x86_linux_android) \
+       && !defined(VGPV_mips32_linux_android) \
+diff --git a/include/pub_tool_redir.h b/include/pub_tool_redir.h
+index bac00d7..fbb2ef2 100644
+--- a/include/pub_tool_redir.h
++++ b/include/pub_tool_redir.h
+@@ -242,8 +242,7 @@
+ /* --- Soname of the standard C library. --- */
+ 
+ #if defined(VGO_linux) || defined(VGO_solaris)
+-#  define  VG_Z_LIBC_SONAME  libcZdsoZa              // libc.so*
+-
++#  define  VG_Z_LIBC_SONAME  libcZdZa                // libc.*
+ #elif defined(VGO_darwin) && (DARWIN_VERS <= DARWIN_10_6)
+ #  define  VG_Z_LIBC_SONAME  libSystemZdZaZddylib    // libSystem.*.dylib
+ 
+@@ -274,7 +273,11 @@
+ /* --- Soname of the pthreads library. --- */
+ 
+ #if defined(VGO_linux)
++# if defined(__GLIBC__) || defined(__UCLIBC__)
+ #  define  VG_Z_LIBPTHREAD_SONAME  libpthreadZdsoZd0     // libpthread.so.0
++# else
++#  define  VG_Z_LIBPTHREAD_SONAME  libcZdZa              // libc.*
++#endif
+ #elif defined(VGO_darwin)
+ #  define  VG_Z_LIBPTHREAD_SONAME  libSystemZdZaZddylib  // libSystem.*.dylib
+ #elif defined(VGO_solaris)
+-- 
+2.7.1
+
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0001-valgrind-Enable-rt_sigpending-syscall-on-ppc64-linux.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0001-valgrind-Enable-rt_sigpending-syscall-on-ppc64-linux.patch
deleted file mode 100644
index 56bb5f5..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0001-valgrind-Enable-rt_sigpending-syscall-on-ppc64-linux.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 1a8006f56342dae9f7100a3c33d80873676e0404 Mon Sep 17 00:00:00 2001
-From: Li Zhou <li.zhou@windriver.com>
-Date: Mon, 24 Aug 2015 03:55:18 -0400
-Subject: [PATCH] valgrind: Enable rt_sigpending syscall on ppc64 linux
-
-New Revision: 15133
-Enable rt_sigpending syscall on ppc64 linux.
-Patch from Thomas Huth <thuth@redhat.com>
-
-Get the patch from valgrind upstream:
-http://valgrind.10908.n7.nabble.com/Valgrind-r15133-in-trunk-NEWS-coregrind-m-syswrap-syswrap-ppc64-linux-c-td54589.html
-
-Upstream-Status: backport
-
-Signed-off-by: Li Zhou <li.zhou@windriver.com>
----
- coregrind/m_syswrap/syswrap-ppc64-linux.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/coregrind/m_syswrap/syswrap-ppc64-linux.c b/coregrind/m_syswrap/syswrap-ppc64-linux.c
-index 5946ee1..8aaa1d7 100644
---- a/coregrind/m_syswrap/syswrap-ppc64-linux.c
-+++ b/coregrind/m_syswrap/syswrap-ppc64-linux.c
-@@ -887,7 +887,7 @@ static SyscallTableEntry syscall_table[] = {
-    LINXY(__NR_rt_sigaction,      sys_rt_sigaction),       // 173
-    LINXY(__NR_rt_sigprocmask,    sys_rt_sigprocmask),     // 174
- 
--// _____(__NR_rt_sigpending,     sys_rt_sigpending),      // 175
-+   LINXY(__NR_rt_sigpending,     sys_rt_sigpending),      // 175
-    LINXY(__NR_rt_sigtimedwait,   sys_rt_sigtimedwait),    // 176
-    LINXY(__NR_rt_sigqueueinfo,   sys_rt_sigqueueinfo),    // 177
-    LINX_(__NR_rt_sigsuspend,     sys_rt_sigsuspend),      // 178
--- 
-1.9.1
-
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0002-remove-rpath.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0002-remove-rpath.patch
new file mode 100644
index 0000000..e9112da
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0002-remove-rpath.patch
@@ -0,0 +1,35 @@
+From f96cf1f4eaa72860ab8b5e18ad10fdc704d78c5f Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Tue, 15 Dec 2015 15:01:34 +0200
+Subject: [PATCH 2/5] remove rpath
+
+Upstream-Status: Inappropriate [embedded config]
+Signed-off-by: Saul Wold <sgw@linux.intel.com>
+---
+ none/tests/Makefile.am | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/none/tests/Makefile.am b/none/tests/Makefile.am
+index 54f2a7e..25b0f49 100644
+--- a/none/tests/Makefile.am
++++ b/none/tests/Makefile.am
+@@ -326,7 +326,6 @@ threadederrno_CFLAGS	+= --std=c99
+ endif
+ tls_SOURCES		= tls.c tls2.c
+ tls_DEPENDENCIES	= tls.so tls2.so
+-tls_LDFLAGS		= -Wl,-rpath,$(abs_top_builddir)/none/tests
+ tls_LDADD		= tls.so tls2.so -lpthread
+ tls_so_SOURCES		= tls_so.c
+ tls_so_DEPENDENCIES	= tls2.so
+@@ -334,7 +333,7 @@ if VGCONF_OS_IS_DARWIN
+  tls_so_LDFLAGS		= -dynamic -dynamiclib -all_load -fpic
+  tls_so_LDADD		= `pwd`/tls2.so
+ else
+- tls_so_LDFLAGS		= -Wl,-rpath,$(abs_top_builddir)/none/tests -shared -fPIC
++ tls_so_LDFLAGS		= -shared -fPIC
+  tls_so_LDADD		= tls2.so
+ endif
+ tls_so_CFLAGS		= $(AM_CFLAGS) -fPIC
+-- 
+2.6.2
+
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0004-Fix-out-of-tree-builds.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0004-Fix-out-of-tree-builds.patch
new file mode 100644
index 0000000..ed313d6
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0004-Fix-out-of-tree-builds.patch
@@ -0,0 +1,175 @@
+From 38ae233b6893a4eec7f9ed6d8ad02392bca8eaed Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Tue, 15 Dec 2015 15:31:50 +0200
+Subject: [PATCH 1/2] Fix out of tree builds.
+
+The paths to these files need to be fully specified in
+the out of tree build case. glibc-2.X.supp is a generated file so the full path
+is deliberately not specified in that case.
+
+RP 2013/03/23
+
+Upstream-Status: Pending
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ configure.ac | 64 ++++++++++++++++++++++++++++++------------------------------
+ 1 file changed, 32 insertions(+), 32 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 8ab7f9b..9366dc7 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -377,44 +377,44 @@ case "${host_os}" in
+ 	     9.*)
+ 		  AC_MSG_RESULT([Darwin 9.x (${kernel}) / Mac OS X 10.5 Leopard])
+ 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_5, [Darwin / Mac OS X version])
+-		  DEFAULT_SUPP="darwin9.supp ${DEFAULT_SUPP}"
+-		  DEFAULT_SUPP="darwin9-drd.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin9.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin9-drd.supp ${DEFAULT_SUPP}"
+ 		  ;;
+ 	     10.*)
+ 		  AC_MSG_RESULT([Darwin 10.x (${kernel}) / Mac OS X 10.6 Snow Leopard])
+ 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_6, [Darwin / Mac OS X version])
+-		  DEFAULT_SUPP="darwin10.supp ${DEFAULT_SUPP}"
+-		  DEFAULT_SUPP="darwin10-drd.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin10.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
+ 		  ;;
+ 	     11.*)
+ 		  AC_MSG_RESULT([Darwin 11.x (${kernel}) / Mac OS X 10.7 Lion])
+ 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_7, [Darwin / Mac OS X version])
+-		  DEFAULT_SUPP="darwin11.supp ${DEFAULT_SUPP}"
+-		  DEFAULT_SUPP="darwin10-drd.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin11.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
+ 		  ;;
+ 	     12.*)
+ 		  AC_MSG_RESULT([Darwin 12.x (${kernel}) / Mac OS X 10.8 Mountain Lion])
+ 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_8, [Darwin / Mac OS X version])
+-		  DEFAULT_SUPP="darwin12.supp ${DEFAULT_SUPP}"
+-		  DEFAULT_SUPP="darwin10-drd.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin12.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
+ 		  ;;
+ 	     13.*)
+ 		  AC_MSG_RESULT([Darwin 13.x (${kernel}) / Mac OS X 10.9 Mavericks])
+ 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_9, [Darwin / Mac OS X version])
+-		  DEFAULT_SUPP="darwin13.supp ${DEFAULT_SUPP}"
+-		  DEFAULT_SUPP="darwin10-drd.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin13.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
+ 		  ;;
+ 	     14.*)
+ 		  AC_MSG_RESULT([Darwin 14.x (${kernel}) / Mac OS X 10.10 Yosemite])
+ 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_10, [Darwin / Mac OS X version])
+-		  DEFAULT_SUPP="darwin14.supp ${DEFAULT_SUPP}"
+-		  DEFAULT_SUPP="darwin10-drd.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin14.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
+ 		  ;;
+ 	     15.*)
+ 		  AC_MSG_RESULT([Darwin 15.x (${kernel}) / Mac OS X 10.11 El Capitan])
+ 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_11, [Darwin / Mac OS X version])
+-		  DEFAULT_SUPP="darwin15.supp ${DEFAULT_SUPP}"
+-		  DEFAULT_SUPP="darwin10-drd.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin15.supp ${DEFAULT_SUPP}"
++		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
+ 		  ;;
+              *) 
+ 		  AC_MSG_RESULT([unsupported (${kernel})])
+@@ -426,13 +426,13 @@ case "${host_os}" in
+      solaris2.11*)
+         AC_MSG_RESULT([ok (${host_os})])
+         VGCONF_OS="solaris"
+-        DEFAULT_SUPP="solaris11.supp ${DEFAULT_SUPP}"
++        DEFAULT_SUPP="$srcdir/solaris11.supp ${DEFAULT_SUPP}"
+         ;;
+ 
+      solaris2.12*)
+         AC_MSG_RESULT([ok (${host_os})])
+         VGCONF_OS="solaris"
+-        DEFAULT_SUPP="solaris12.supp ${DEFAULT_SUPP}"
++        DEFAULT_SUPP="$srcdir/solaris12.supp ${DEFAULT_SUPP}"
+         ;;
+ 
+      *) 
+@@ -1015,29 +1015,29 @@ AC_MSG_CHECKING([the glibc version])
+ case "${GLIBC_VERSION}" in
+      2.2)
+ 	AC_MSG_RESULT(${GLIBC_VERSION} family)
+-	DEFAULT_SUPP="glibc-2.2.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.2-LinuxThreads-helgrind.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.2.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.2-LinuxThreads-helgrind.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
+ 	;;
+      2.[[3-6]])
+ 	AC_MSG_RESULT(${GLIBC_VERSION} family)
+-	DEFAULT_SUPP="glibc-${GLIBC_VERSION}.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-${GLIBC_VERSION}.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
+ 	;;
+      2.[[7-9]])
+ 	AC_MSG_RESULT(${GLIBC_VERSION} family)
+ 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
+ 	;;
+      2.10|2.11)
+ 	AC_MSG_RESULT(${GLIBC_VERSION} family)
+ 	AC_DEFINE([GLIBC_MANDATORY_STRLEN_REDIRECT], 1,
+ 		  [Define to 1 if strlen() has been optimized heavily (amd64 glibc >= 2.10)])
+ 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
+ 	;;
+      2.*)
+ 	AC_MSG_RESULT(${GLIBC_VERSION} family)
+@@ -1046,8 +1046,8 @@ case "${GLIBC_VERSION}" in
+ 	AC_DEFINE([GLIBC_MANDATORY_INDEX_AND_STRLEN_REDIRECT], 1,
+ 		  [Define to 1 if index() and strlen() have been optimized heavily (x86 glibc >= 2.12)])
+ 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
+-	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
+ 	;;
+      darwin)
+ 	AC_MSG_RESULT(Darwin)
+@@ -1057,7 +1057,7 @@ case "${GLIBC_VERSION}" in
+      bionic)
+ 	AC_MSG_RESULT(Bionic)
+ 	AC_DEFINE([BIONIC_LIBC], 1, [Define to 1 if you're using Bionic])
+-	DEFAULT_SUPP="bionic.supp ${DEFAULT_SUPP}"
++	DEFAULT_SUPP="$srcdir/bionic.supp ${DEFAULT_SUPP}"
+ 	;;
+      solaris)
+ 	AC_MSG_RESULT(Solaris)
+@@ -1079,11 +1079,11 @@ if test "$VGCONF_OS" != "solaris"; then
+     # attempt to detect whether such libraries are installed on the
+     # build machine (or even if any X facilities are present); just
+     # add the suppressions antidisirregardless.
+-    DEFAULT_SUPP="xfree-4.supp ${DEFAULT_SUPP}"
+-    DEFAULT_SUPP="xfree-3.supp ${DEFAULT_SUPP}"
++    DEFAULT_SUPP="$srcdir/xfree-4.supp ${DEFAULT_SUPP}"
++    DEFAULT_SUPP="$srcdir/xfree-3.supp ${DEFAULT_SUPP}"
+ 
+     # Add glibc and X11 suppressions for exp-sgcheck
+-    DEFAULT_SUPP="exp-sgcheck.supp ${DEFAULT_SUPP}"
++    DEFAULT_SUPP="$srcdir/exp-sgcheck.supp ${DEFAULT_SUPP}"
+ fi
+ 
+ 
+-- 
+2.6.2
+
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/add-ptest.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0005-Modify-vg_test-wrapper-to-support-PTEST-formats.patch
similarity index 79%
rename from yocto-poky/meta/recipes-devtools/valgrind/valgrind/add-ptest.patch
rename to yocto-poky/meta/recipes-devtools/valgrind/valgrind/0005-Modify-vg_test-wrapper-to-support-PTEST-formats.patch
index 225f843..f5ac989 100644
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/add-ptest.patch
+++ b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/0005-Modify-vg_test-wrapper-to-support-PTEST-formats.patch
@@ -1,4 +1,7 @@
-Modify vg_test wrapper to support PTEST formats
+From f49f27f1bc67d07440b0ac9a7d767a8ea1589bfe Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Tue, 15 Dec 2015 15:50:44 +0200
+Subject: [PATCH 5/5] Modify vg_test wrapper to support PTEST formats
 
 Change the valgrind regression test script vg_regtest to
 support the yocto ptest stdout reporting format.  The commit adds
@@ -15,51 +18,50 @@
 
 Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
 Signed-off-by: Tudor Florea <tudor.florea@enea.com>
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ tests/vg_regtest.in | 75 +++++++++++++++++++++++++++++++++++++++--------------
+ 1 file changed, 55 insertions(+), 20 deletions(-)
 
 diff --git a/tests/vg_regtest.in b/tests/vg_regtest.in
-index 224385f..3e0383b 100755
+index a441f42..cb05b52 100755
 --- a/tests/vg_regtest.in
 +++ b/tests/vg_regtest.in
-@@ -39,11 +39,11 @@
- #               --valgrind.)
- #   --keep-unfiltered: keep a copy of the unfiltered output/error output
- #     of each test by adding an extension .unfiltered.out
--#
- #   --outer-valgrind: run this valgrind under the given outer valgrind.
- #     This valgrind must be configured with --enable-inner.
- #   --outer-tool: tool to use by the outer valgrind (default memcheck).
- #   --outer-args: use this as outer tool args.
+@@ -47,6 +47,7 @@
+ #   --loop-till-fail: loops on the test(s) till one fail, then exit
+ #              This is useful to obtain detailed trace or --keep-unfiltered
+ #              output of a non deterministic test failure
 +#   --yocto-ptest: output in yocto ptest format
  #
  # The easiest way is to run all tests in valgrind/ with (assuming you installed
  # in $PREFIX):
-@@ -126,7 +126,7 @@ use strict;
- my $usage="\n"
+@@ -139,7 +140,7 @@ my $usage="\n"
       . "Usage:\n"
       . "   vg_regtest [--all, --valgrind, --valgrind-lib, --keep-unfiltered\n"
--     . "                 --outer-valgrind, --outer-tool, --outer-args]\n"
-+     . "                 --outer-valgrind, --outer-tool, --outer-args, --yocto-ptest]\n"
+      . "                 --outer-valgrind, --outer-tool, --outer-args\n"
+-     . "                 --loop-till-fail]\n"
++     . "                 --loop-till-fail, --yocto-ptest]\n"
       . "   Use EXTRA_REGTEST_OPTS to supply extra args for all tests\n"
       . "\n";
  
-@@ -170,6 +170,7 @@ my $outer_args;
- 
+@@ -186,6 +187,7 @@ my $outer_args;
  my $valgrind_lib = "$tests_dir/.in_place";
  my $keepunfiltered = 0;
+ my $looptillfail = 0;
 +my $yoctoptest = 0;
  
  # default filter is the one named "filter_stderr" in the test's directory
  my $default_stderr_filter = "filter_stderr";
-@@ -226,6 +227,8 @@ sub process_command_line()
-                 $valgrind_lib = $1;
-             } elsif ($arg =~ /^--keep-unfiltered$/) {
+@@ -244,6 +246,8 @@ sub process_command_line()
                  $keepunfiltered = 1;
+             } elsif ($arg =~ /^--loop-till-fail$/) {
+                 $looptillfail = 1;
 +            } elsif ($arg =~ /^--yocto-ptest$/) {
 +                $yoctoptest = 1;
              } else {
                  die $usage;
              }
-@@ -340,13 +343,28 @@ sub read_vgtest_file($)
+@@ -365,13 +369,28 @@ sub read_vgtest_file($)
  #----------------------------------------------------------------------------
  # Since most of the program time is spent in system() calls, need this to
  # propagate a Ctrl-C enabling us to quit.
@@ -93,12 +95,12 @@
  # if $keepunfiltered, copies $1 to $1.unfiltered.out
  # renames $0 tp $1
  sub filtered_rename($$) 
-@@ -394,19 +412,21 @@ sub do_diffs($$$$)
+@@ -419,23 +438,25 @@ sub do_diffs($$$$)
                  # A match;  remove .out and any previously created .diff files.
                  unlink("$name.$mid.out");
                  unlink(<$name.$mid.diff*>);
 -                return;
-+                return 0;
++                return 1;
              }
          }
      }
@@ -107,7 +109,11 @@
 +    print "*** $name failed ($mid) ***\n" if ($yoctoptest == 0) ;
      push(@failures, sprintf("%-40s ($mid)", "$fullname"));
      $num_failures{$mid}++;
-+    return 1;
+     if ($looptillfail == 1) {
+        print "Failure encountered, stopping to loop\n";
+        exit 1
+     }
++    return 0;
  }
  
  sub do_one_test($$) 
@@ -117,7 +123,7 @@
      $vgtest =~ /^(.*)\.vgtest/;
      my $name = $1;
      my $fullname = "$dir/$name"; 
-@@ -425,7 +445,11 @@ sub do_one_test($$)
+@@ -454,7 +475,11 @@ sub do_one_test($$)
          } elsif (256 == $prereq_res) {
              # Nb: weird Perl-ism -- exit code of '1' is seen by Perl as 256...
              # Prereq failed, skip.
@@ -130,8 +136,8 @@
              return;
          } else {
              # Bad prereq; abort.
-@@ -438,7 +462,7 @@ sub do_one_test($$)
-     if (defined $progB) {
+@@ -472,7 +497,7 @@ sub do_one_test($$)
+         }
          # If there is a progB, let's start it in background:
          printf("%-16s valgrind $extraopts $vgopts $prog $args (progB: $progB $argsB)\n",
 -               "$name:");
@@ -139,7 +145,7 @@
          # progB.done used to detect child has finished. See below.
          # Note: redirection of stdout and stderr is before $progB to allow argsB
          # to e.g. redirect stdoutB to stderrB
-@@ -452,7 +476,8 @@ sub do_one_test($$)
+@@ -488,7 +513,8 @@ sub do_one_test($$)
                       . "touch progB.done)  &");
          }
      } else {
@@ -147,9 +153,9 @@
 +        printf("%-16s valgrind $extraopts $vgopts $prog $args\n", "$name:")
 +            if ($yoctoptest == 0);
      }
-  
-     # Pass the appropriate --tool option for the directory (can be overridden
-@@ -487,7 +512,7 @@ sub do_one_test($$)
+ 
+     # Collect environment variables, if any.
+@@ -529,7 +555,7 @@ sub do_one_test($$)
      # Find all the .stdout.exp files.  If none, use /dev/null.
      my @stdout_exps = <$name.stdout.exp*>;
      @stdout_exps = ( "/dev/null" ) if (0 == scalar @stdout_exps);
@@ -158,7 +164,7 @@
  
      # Filter stderr
      $stderr_filter_args = $name if (! defined $stderr_filter_args);
-@@ -496,7 +521,7 @@ sub do_one_test($$)
+@@ -538,7 +564,7 @@ sub do_one_test($$)
      # Find all the .stderr.exp files.  At least one must exist.
      my @stderr_exps = <$name.stderr.exp*>;
      (0 != scalar @stderr_exps) or die "Could not find `$name.stderr.exp*'\n";
@@ -167,7 +173,7 @@
  
      if (defined $progB) {
          # wait for the child to be finished
-@@ -520,7 +545,7 @@ sub do_one_test($$)
+@@ -562,7 +588,7 @@ sub do_one_test($$)
          # Find all the .stdoutB.exp files.  If none, use /dev/null.
          my @stdoutB_exps = <$name.stdoutB.exp*>;
          @stdoutB_exps = ( "/dev/null" ) if (0 == scalar @stdoutB_exps);
@@ -176,7 +182,7 @@
          
          # Filter stderr
          $stderrB_filter_args = $name if (! defined $stderrB_filter_args);
-@@ -529,7 +554,7 @@ sub do_one_test($$)
+@@ -571,7 +597,7 @@ sub do_one_test($$)
          # Find all the .stderrB.exp files.  At least one must exist.
          my @stderrB_exps = <$name.stderrB.exp*>;
          (0 != scalar @stderrB_exps) or die "Could not find `$name.stderrB.exp*'\n";
@@ -185,7 +191,7 @@
      }
  
      # Maybe do post-test check
-@@ -541,7 +566,7 @@ sub do_one_test($$)
+@@ -583,7 +609,7 @@ sub do_one_test($$)
  	    # Find all the .post.exp files.  If none, use /dev/null.
  	    my @post_exps = <$name.post.exp*>;
  	    @post_exps = ( "/dev/null" ) if (0 == scalar @post_exps);
@@ -194,7 +200,7 @@
  	}
      }
   
-@@ -550,6 +575,13 @@ sub do_one_test($$)
+@@ -592,6 +618,13 @@ sub do_one_test($$)
              print("(cleanup operation failed: $cleanup)\n");
      }
  
@@ -208,7 +214,7 @@
      $num_tests_done++;
  }
  
-@@ -589,7 +621,7 @@ sub test_one_dir($$)
+@@ -631,7 +664,7 @@ sub test_one_dir($$)
      my $found_tests = (0 != (grep { $_ =~ /\.vgtest$/ } @fs));
  
      if ($found_tests) {
@@ -217,7 +223,7 @@
      }
      foreach my $f (@fs) {
          if (-d $f) {
-@@ -599,7 +631,7 @@ sub test_one_dir($$)
+@@ -641,7 +674,7 @@ sub test_one_dir($$)
          }
      }
      if ($found_tests) {
@@ -226,7 +232,7 @@
      }
  
      chdir("..");
-@@ -625,10 +657,12 @@ sub summarise_results
+@@ -667,10 +700,12 @@ sub summarise_results
             $num_failures{"stdout"},   plural($num_failures{"stdout"}),
             $num_failures{"stderrB"},  plural($num_failures{"stderrB"}),
             $num_failures{"stdoutB"},  plural($num_failures{"stdoutB"}),
@@ -241,3 +247,6 @@
      }
      print "\n";
  }
+-- 
+2.6.2
+
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/11_mips-link-tool.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/11_mips-link-tool.patch
new file mode 100644
index 0000000..ecb33b8
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/11_mips-link-tool.patch
@@ -0,0 +1,37 @@
+Debian fix for MIPS: mmap(0x400000, 32768) failed in UME with error 22 (Invalid argument)
+
+  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=777704
+
+Upstream-Status: Pending
+
+Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+
+
+Description: Disable the MIPS linker workarounds when using -Ttext-section
+Origin: vendor
+Bug-Debian: http://bugs.debian.org/777704
+Author: James Cowgill <james410@cowgill.org.uk>
+Last-Update: 2015-04-25
+
+--- a/coregrind/link_tool_exe_linux.in
++++ b/coregrind/link_tool_exe_linux.in
+@@ -76,12 +76,13 @@
+ my $arch = substr($x, 0, index($x, "'"));
+ 
+ my $extra_args;
+-if (($arch eq 'mips') || ($arch eq 'mipsel')
+-    || ($arch eq 'mipsisa32r2el')) {
+-   $extra_args = "-static -Wl,--section-start=.reginfo=$ala";
+-} elsif (($arch eq 'mips64') || ($arch eq 'mips64el') ||
+-         ($arch eq 'mipsisa64el')) {
+-   $extra_args = "-static -Wl,--section-start=.MIPS.options=$ala";
++if ($arch =~ /^mips/ && "@FLAG_T_TEXT@" eq '-Ttext') {
++   # We only need to use the special mips options when using -Ttext
++   if ($arch =~ /^mips(64|isa64)/) {
++      $extra_args = "-static -Wl,--section-start=.MIPS.options=$ala";
++   } else {
++      $extra_args = "-static -Wl,--section-start=.reginfo=$ala";
++   }
+ } else {
+    $extra_args = "-static -Wl,@FLAG_T_TEXT@=$ala";
+ }
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/avoid-neon-for-targets-which-don-t-support-it.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/avoid-neon-for-targets-which-don-t-support-it.patch
new file mode 100644
index 0000000..5fcfec0
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/avoid-neon-for-targets-which-don-t-support-it.patch
@@ -0,0 +1,33 @@
+From 8facc29c3c56e6cf9cfef70986cf73876044a3fb Mon Sep 17 00:00:00 2001
+From: Andre McCurdy <armccurdy@gmail.com>
+Date: Tue, 19 Jan 2016 16:42:36 -0800
+Subject: [PATCH] avoid neon for targets which don't support it
+
+The sh-mem-random.c test app tries to use neon loads and stores to
+test 64-bit float copies when building for ARM. Allow it to do so if
+possible, but fallback to C when building for ARM targets which don't
+support neon.
+
+Upstream-Status: Pending
+
+Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+---
+ memcheck/tests/sh-mem-random.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/memcheck/tests/sh-mem-random.c b/memcheck/tests/sh-mem-random.c
+index ae82248..816e139 100644
+--- a/memcheck/tests/sh-mem-random.c
++++ b/memcheck/tests/sh-mem-random.c
+@@ -191,7 +191,7 @@ void do_test_at ( U1* arr )
+                "emms"
+                : : "r"(arr+dst), "r"(arr+src) : "memory"
+             );
+-#elif defined(__linux__) && defined(__arm__) && !defined(__aarch64__)
++#elif defined(__linux__) && defined(__arm__) && defined(__ARM_NEON__) && !defined(__aarch64__)
+             /* On arm32, many compilers generate a 64-bit float move
+                using two 32 bit integer registers, which completely
+                defeats this test.  Hence force a 64-bit NEON load and
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/enable.building.on.4.x.kernel.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/enable.building.on.4.x.kernel.patch
deleted file mode 100644
index 300f2f1..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/enable.building.on.4.x.kernel.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-Enable building valgrind on host with 4.x kernel.
-
-For OpenEmbedded builds we should be checking something like
-OLDEST_KERNEL instead of `uname -r`, but this is good enough for now.
-
-Building on 4.x* currently fails with:
-  configure:5556: checking for the kernel version
-  configure:5579: result: unsupported (4.0.0-rc3-00111-gaffb817)
-  configure:5581: error: Valgrind works on kernels 2.4, 2.6
-
-Upstream-Status: Pending
-Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
-
---- valgrind-3.9.0/configure.ac.orig	2015-03-13 19:17:01.247310868 +0100
-+++ valgrind-3.9.0/configure.ac	2015-03-13 19:19:27.388316108 +0100
-@@ -276,9 +276,9 @@
-         kernel=`uname -r`
- 
-         case "${kernel}" in
--             2.6.*|3.*) 
--        	    AC_MSG_RESULT([2.6.x/3.x family (${kernel})])
--        	    AC_DEFINE([KERNEL_2_6], 1, [Define to 1 if you're using Linux 2.6.x or Linux 3.x])
-+             2.6.*|3.*|4.*) 
-+        	    AC_MSG_RESULT([2.6.x/3.x/4.x family (${kernel})])
-+        	    AC_DEFINE([KERNEL_2_6], 1, [Define to 1 if you're using Linux 2.6.x or Linux 3.x or Linux 4.x])
-         	    ;;
- 
-              2.4.*) 
-@@ -288,7 +288,7 @@
- 
-              *) 
-         	    AC_MSG_RESULT([unsupported (${kernel})])
--        	    AC_MSG_ERROR([Valgrind works on kernels 2.4, 2.6])
-+        	    AC_MSG_ERROR([Valgrind works on kernels 2.4, 2.6, 3.x, 4.x])
-         	    ;;
-         esac
- 
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/force-nostabs.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/force-nostabs.patch
deleted file mode 100644
index 849dfc5..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/force-nostabs.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-Suppress building ptest apps with the -gstabs option
-
-Force the configure tests for -gstabs compiler support to fail so that
-the regression tests don't try to build with the -gstabs option.
-Otherwise, the valgrind build when ptest is enabled fails with the
-error:
-    Stabs debuginfo not supported:
-    ../package/usr/lib/valgrind/ptest/memcheck/tests/deep_templates
-    ERROR: Function failed: split_and_strip_files
-
-Upstream-Status: Inappropriate [gstabs support is appropriate upstream,
-        but not for this distro]
-
-Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
-
-diff --git a/configure.ac b/configure.ac
-index 755dfb9..cc8b5e1 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -1743,22 +1743,7 @@ AM_CONDITIONAL(DWARF4, test x$ac_have_dwarf4 = xyes)
- CFLAGS=$safe_CFLAGS
- 
- 
--# does this compiler support -gstabs ?
--
--AC_MSG_CHECKING([if gcc accepts -gstabs])
--
--safe_CFLAGS=$CFLAGS
--CFLAGS="-gstabs"
--AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[
--  return 0;
--]])], [
--ac_have_gstabs=yes
--AC_MSG_RESULT([yes])
--], [
- ac_have_gstabs=no
--AC_MSG_RESULT([no])
--])
--CFLAGS=$safe_CFLAGS
- AM_CONDITIONAL([HAVE_GSTABS], [test x$ac_have_gstabs = xyes])
- 
- 
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/glibc.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/glibc.patch
deleted file mode 100644
index 863499d..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/glibc.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-Backport of glibc 2.19 and 2.20 and 2.21 support.
-
-Upstream-Status: Backport
-Signed-off-by: Ross Burton <ross.burton@intel.com>
-
-Index: valgrind-3.10.1/configure.ac
-===================================================================
---- valgrind-3.10.1.orig/configure.ac
-+++ valgrind-3.10.1/configure.ac
-@@ -1018,6 +1018,34 @@ case "${GLIBC_VERSION}" in
- 	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
- 	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-+     2.19)
-+	AC_MSG_RESULT(2.19 family)
-+	AC_DEFINE([GLIBC_2_19], 1, [Define to 1 if you're using glibc 2.19.x])
-+	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	;;
-+     2.20)
-+	AC_MSG_RESULT(2.20 family)
-+	AC_DEFINE([GLIBC_2_20], 1, [Define to 1 if you're using glibc 2.20.x])
-+	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	;;
-+     2.21)
-+	AC_MSG_RESULT(2.21 family)
-+	AC_DEFINE([GLIBC_2_21], 1, [Define to 1 if you're using glibc 2.21.x])
-+	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	;;
-+     2.22)
-+	AC_MSG_RESULT(2.22 family)
-+	AC_DEFINE([GLIBC_2_22], 1, [Define to 1 if you're using glibc 2.22.x])
-+	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	;;
-      darwin)
- 	AC_MSG_RESULT(Darwin)
- 	AC_DEFINE([DARWIN_LIBC], 1, [Define to 1 if you're using Darwin])
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/pass-maltivec-only-if-it-supported.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/pass-maltivec-only-if-it-supported.patch
deleted file mode 100644
index f8167cb..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/pass-maltivec-only-if-it-supported.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-Upstream-Status: Backport
-
-r14566 | florian | 2014-09-24 17:02:54 -0500 (Wed, 24 Sep 2014) | 4 lines
-
-The testbuckets none/tests/ppc{32,64} did not build in case the
-toolchain did not support -maltivec -mabi=altivec.
-This should work now. Fixes BZ #338731
-
-Index: none/tests/ppc32/Makefile.am
-===================================================================
---- a/none/tests/ppc32/Makefile.am	(revision 14565)
-+++ b/none/tests/ppc32/Makefile.am	(revision 14566)
-@@ -72,8 +72,12 @@
- allexec_CFLAGS		= $(AM_CFLAGS) @FLAG_W_NO_NONNULL@
- 
- if HAS_ALTIVEC
-+BUILD_FLAG_ALTIVEC = -maltivec
-+BUILD_FLAG_ABI_ALTIVEC = -mabi=altivec
- ALTIVEC_FLAG = -DHAS_ALTIVEC
- else
-+BUILD_FLAG_ALTIVEC =
-+BUILD_FLAG_ABI_ALTIVEC =
- ALTIVEC_FLAG =
- endif
- 
-@@ -101,11 +105,12 @@
- ISA_2_07_FLAG =
- endif
- 
--jm_insns_CFLAGS = $(AM_CFLAGS) -Winline -Wall -O -g -mregnames -maltivec \
--			@FLAG_M32@ $(ALTIVEC_FLAG)
-+jm_insns_CFLAGS = $(AM_CFLAGS) -Winline -Wall -O -g -mregnames \
-+			@FLAG_M32@ $(ALTIVEC_FLAG) $(BUILD_FLAG_ALTIVEC)
- 
--testVMX_CFLAGS  = $(AM_CFLAGS) -O -g -Wall -maltivec -mabi=altivec -DALTIVEC \
--			-DGCC_COMPILER @FLAG_M32@
-+testVMX_CFLAGS  = $(AM_CFLAGS) -O -g -Wall -DALTIVEC \
-+			-DGCC_COMPILER @FLAG_M32@  $(BUILD_FLAG_ALTIVEC) \
-+			$(BUILD_FLAG_ABI_ALTIVEC)
- 
- test_isa_2_06_part1_CFLAGS = $(AM_CFLAGS) -Winline -Wall -O -g -mregnames $(VSX_FLAG) \
- 			@FLAG_M32@ $(ALTIVEC_FLAG) $(BUILD_FLAG_VSX)
-Index: none/tests/ppc64/Makefile.am
-===================================================================
---- a/none/tests/ppc64/Makefile.am	(revision 14565)
-+++ b/none/tests/ppc64/Makefile.am	(revision 14566)
-@@ -50,8 +50,10 @@
- allexec_CFLAGS		= $(AM_CFLAGS) @FLAG_W_NO_NONNULL@
- 
- if HAS_ALTIVEC
-+BUILD_FLAG_ALTIVEC = -maltivec
- ALTIVEC_FLAG = -DHAS_ALTIVEC
- else
-+BUILD_FLAG_ALTIVEC =
- ALTIVEC_FLAG =
- endif
- 
-@@ -88,8 +90,8 @@
- test_isa_2_06_part3_CFLAGS = $(AM_CFLAGS) -Winline -Wall -O -g -mregnames $(VSX_FLAG) \
- 			@FLAG_M64@ $(ALTIVEC_FLAG) $(BUILD_FLAG_VSX)
- 
--jm_insns_CFLAGS = $(AM_CFLAGS) -Winline -Wall -O -g -mregnames -maltivec \
--			@FLAG_M64@ $(ALTIVEC_FLAG)
-+jm_insns_CFLAGS = $(AM_CFLAGS) -Winline -Wall -O -g -mregnames \
-+			@FLAG_M64@ $(ALTIVEC_FLAG) $(BUILD_FLAG_ALTIVEC)
- 
- test_dfp1_CFLAGS = $(AM_CFLAGS) -Winline -Wall -O -g -mregnames $(DFP_FLAG) \
- 			@FLAG_M64@ $(BUILD_FLAGS_DFP)
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/remove-arm-variant-specific.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/remove-arm-variant-specific.patch
deleted file mode 100644
index 2319ab9..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/remove-arm-variant-specific.patch
+++ /dev/null
@@ -1,66 +0,0 @@
-Remove arm tests that don't compile
-
-Upstream-Status: Pending
-
-Corrects the original commit for the patch that removed ARM ptest CFLAGS
-settings. Since the flags could be set by a user, the flags should
-be kept in place during compilation.  By keeping the original up-stream
-CFLAGS for the tests, then additional tests successfully compile
-for all tested ARM tunings.
-
-However, there were still two tests listed below that did not compile
-for any beaglebone tuning that is valid for valgrind. With the updated
-patch, the set of excluded ARM ptests and their respective build
-failures are:
-  intdiv - fails for all beaglebone tunings with 2 errors:
-  {standard input}:(40 or 41): Error: selected processor does not
-       support Thumb mode `udiv r3,r9,r10'
-  {standard input}:(72 or 73): Error: selected processor does not
-       support Thumb mode `sdiv r3,r9,r10'
-
-  vcvt_fixed_float_VFP - fails for all beaglebone tunings in one of
-  two ways:
-    with neon tuning (-mfpu=neon) fails with Internal Compiler Error
-    without neon tuning fails with 3 errors:
-    {standard input}:33: Error: selected FPU does not support
-      instruction -- `vcvt.f32.s32 s15,s15,#1'
-    {standard input}:58: Error: selected FPU does not support
-      instruction -- `vcvt.f32.s32 s15,s15,#32'
-    {standard input}:136: Error: selected FPU does not support
-      instruction -- `vcvt.f32.u32 s15,s15,#1'
-
-After applying this commit, the valgrind ARM ptests compile without
-errors for tunings:
-  armv7[t][hf][b][-neon] cortexa8[t][hf][-neon]
-where the tuning [option] was successfully compiled, both with
-and without the 'option', and in combination with all other options.
-
-Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
-
-Index: valgrind-3.10.1/none/tests/arm/Makefile.am
-===================================================================
---- valgrind-3.10.1.orig/none/tests/arm/Makefile.am	2015-05-19 15:11:59.224842927 -0500
-+++ valgrind-3.10.1/none/tests/arm/Makefile.am	2015-05-19 15:14:20.808847028 -0500
-@@ -17,9 +17,13 @@
- 	vfp.stdout.exp vfp.stderr.exp vfp.vgtest \
- 	vfpv4_fma.stdout.exp vfpv4_fma.stderr.exp vfpv4_fma.vgtest
- 
-+# Remove the following tests which cause compiler errors for all tunings
-+#  available for beagle bone (see remove-arm-variant-specific.patch):
-+#	intdiv
-+#	vcvt_fixed_float_VFP
-+
- check_PROGRAMS = \
- 	allexec \
--	intdiv \
- 	ldrt \
- 	ldrt_arm \
- 	neon128 \
-@@ -27,7 +31,6 @@
- 	v6intARM \
- 	v6intThumb \
- 	v6media \
--	vcvt_fixed_float_VFP \
- 	vfp \
- 	vfpv4_fma
- 
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/remove-ppc-tests-failing-build.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/remove-ppc-tests-failing-build.patch
deleted file mode 100644
index 1c640ff..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/remove-ppc-tests-failing-build.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-Remove test apps not building with ppc and PTEST
-
-For mpc8316-rdb in none/tests/ppc32, the oe compiler options are
-inconsistent with the imposed test compiler options generating errors
-as follows:
-test_isa_2_07_part1
-test_isa_2_07_part2
-test_tm
-test_touch_tm
-    : unrecognized command line option '-mhtm'
-
-jm-insns
-testVMX
-    : AltiVec not supported in this target
-
-For the following tests, their inline assembler is inconsistent with
-the ppce300c3 variant:
-round.c:393
-power5+_round.c:98
-    : impossible constraint in 'asm'
-
-For the following tests, with both mpc8316-rdb and with qemuppc bsp,
-the inline assember is inconsistent with the oe compiler machine
-tuning:
-In memcheck/tests/ppc32
- power_ISA2_05.c:56
-In none/tests/ppc32
- test_dfp1.c:85
- test_dfp2.c:160
- test_dfp3.c:157
- test_dfp4.c:73
- test_dfp5.c:73
-    : impossible constraint in 'asm'
-
-Upstream-Status: Pending
-
-Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
-
-Index: valgrind-3.10.0/memcheck/tests/ppc32/Makefile.am
-===================================================================
---- valgrind-3.10.0.orig/memcheck/tests/ppc32/Makefile.am
-+++ valgrind-3.10.0/memcheck/tests/ppc32/Makefile.am
-@@ -7,8 +7,7 @@ EXTRA_DIST = $(noinst_SCRIPTS) \
- 	power_ISA2_05.stderr.exp power_ISA2_05.stdout.exp power_ISA2_05.vgtest \
- 	power_ISA2_05.stdout.exp_Without_FPPO
- 
--check_PROGRAMS = \
--	power_ISA2_05
-+check_PROGRAMS = 
- 
- power_ISA2_05_CFLAGS = $(AM_CFLAGS) $(WERROR) -Winline -Wall -Wshadow -g \
- 		-I$(top_srcdir)/include @FLAG_M32@
-Index: valgrind-3.10.0/none/tests/ppc32/Makefile.am
-===================================================================
---- valgrind-3.10.0.orig/none/tests/ppc32/Makefile.am
-+++ valgrind-3.10.0/none/tests/ppc32/Makefile.am
-@@ -52,16 +52,8 @@ check_PROGRAMS = \
- 	allexec \
- 	bug129390-ppc32 \
- 	bug139050-ppc32 \
--	ldstrev lsw jm-insns mftocrf mcrfs round test_fx test_gx \
--	testVMX twi tw xlc_dbl_u32 power5+_round power6_bcmp \
--	test_isa_2_06_part1 \
--	test_isa_2_06_part2 \
--	test_isa_2_06_part3 \
--	test_dfp1 test_dfp2 test_dfp3 test_dfp4 test_dfp5 \
--	test_isa_2_07_part1 \
--	test_isa_2_07_part2 \
--	test_tm \
--	test_touch_tm \
-+	ldstrev lsw mftocrf mcrfs test_fx test_gx \
-+	twi tw xlc_dbl_u32 power6_bcmp \
- 	ldst_multiple \
- 	data-cache-instructions
- 
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/sepbuildfix.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/sepbuildfix.patch
deleted file mode 100644
index 5db0ef8..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/sepbuildfix.patch
+++ /dev/null
@@ -1,235 +0,0 @@
-Fix out of tree builds. The paths to these files need to be fully specified in
-the out of tree build case. glibc-2.X.supp is a generated file so the full path
-is deliberately not specified in that case.
-
-RP 2013/03/23
-
-Upstream-Status: Pending
-
-Index: valgrind-3.9.0/configure.ac
-===================================================================
---- valgrind-3.9.0.orig/configure.ac
-+++ valgrind-3.9.0/configure.ac
-@@ -325,26 +325,26 @@ case "${host_os}" in
- 	     9.*)
- 		  AC_MSG_RESULT([Darwin 9.x (${kernel}) / Mac OS X 10.5 Leopard])
- 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_5, [Darwin / Mac OS X version])
--		  DEFAULT_SUPP="darwin9.supp ${DEFAULT_SUPP}"
--		  DEFAULT_SUPP="darwin9-drd.supp ${DEFAULT_SUPP}"
-+		  DEFAULT_SUPP="$srcdir/darwin9.supp ${DEFAULT_SUPP}"
-+		  DEFAULT_SUPP="$srcdir/darwin9-drd.supp ${DEFAULT_SUPP}"
- 		  ;;
- 	     10.*)
- 		  AC_MSG_RESULT([Darwin 10.x (${kernel}) / Mac OS X 10.6 Snow Leopard])
- 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_6, [Darwin / Mac OS X version])
--		  DEFAULT_SUPP="darwin10.supp ${DEFAULT_SUPP}"
--		  DEFAULT_SUPP="darwin10-drd.supp ${DEFAULT_SUPP}"
-+		  DEFAULT_SUPP="$srcdir/darwin10.supp ${DEFAULT_SUPP}"
-+		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
- 		  ;;
- 	     11.*)
- 		  AC_MSG_RESULT([Darwin 11.x (${kernel}) / Mac OS X 10.7 Lion])
- 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_7, [Darwin / Mac OS X version])
--		  DEFAULT_SUPP="darwin11.supp ${DEFAULT_SUPP}"
--		  DEFAULT_SUPP="darwin10-drd.supp ${DEFAULT_SUPP}"
-+		  DEFAULT_SUPP="$srcdir/darwin11.supp ${DEFAULT_SUPP}"
-+		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
- 		  ;;
- 	     12.*)
- 		  AC_MSG_RESULT([Darwin 12.x (${kernel}) / Mac OS X 10.8 Mountain Lion])
- 		  AC_DEFINE([DARWIN_VERS], DARWIN_10_8, [Darwin / Mac OS X version])
--		  DEFAULT_SUPP="darwin12.supp ${DEFAULT_SUPP}"
--		  DEFAULT_SUPP="darwin10-drd.supp ${DEFAULT_SUPP}"
-+		  DEFAULT_SUPP="$srcdir/darwin12.supp ${DEFAULT_SUPP}"
-+		  DEFAULT_SUPP="$srcdir/darwin10-drd.supp ${DEFAULT_SUPP}"
- 		  ;;
-              *) 
- 		  AC_MSG_RESULT([unsupported (${kernel})])
-@@ -799,124 +799,124 @@ case "${GLIBC_VERSION}" in
-      2.2)
- 	AC_MSG_RESULT(2.2 family)
- 	AC_DEFINE([GLIBC_2_2], 1, [Define to 1 if you're using glibc 2.2.x])
--	DEFAULT_SUPP="glibc-2.2.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.2-LinuxThreads-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.2.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.2-LinuxThreads-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
- 
-      2.3)
- 	AC_MSG_RESULT(2.3 family)
- 	AC_DEFINE([GLIBC_2_3], 1, [Define to 1 if you're using glibc 2.3.x])
--	DEFAULT_SUPP="glibc-2.3.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.3.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
- 
-      2.4)
- 	AC_MSG_RESULT(2.4 family)
- 	AC_DEFINE([GLIBC_2_4], 1, [Define to 1 if you're using glibc 2.4.x])
--	DEFAULT_SUPP="glibc-2.4.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.4.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
- 
-      2.5)
- 	AC_MSG_RESULT(2.5 family)
- 	AC_DEFINE([GLIBC_2_5], 1, [Define to 1 if you're using glibc 2.5.x])
--	DEFAULT_SUPP="glibc-2.5.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.5.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.6)
- 	AC_MSG_RESULT(2.6 family)
- 	AC_DEFINE([GLIBC_2_6], 1, [Define to 1 if you're using glibc 2.6.x])
--	DEFAULT_SUPP="glibc-2.6.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.6.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.7)
- 	AC_MSG_RESULT(2.7 family)
- 	AC_DEFINE([GLIBC_2_7], 1, [Define to 1 if you're using glibc 2.7.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.8)
- 	AC_MSG_RESULT(2.8 family)
- 	AC_DEFINE([GLIBC_2_8], 1, [Define to 1 if you're using glibc 2.8.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.9)
- 	AC_MSG_RESULT(2.9 family)
- 	AC_DEFINE([GLIBC_2_9], 1, [Define to 1 if you're using glibc 2.9.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.10)
- 	AC_MSG_RESULT(2.10 family)
- 	AC_DEFINE([GLIBC_2_10], 1, [Define to 1 if you're using glibc 2.10.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.11)
- 	AC_MSG_RESULT(2.11 family)
- 	AC_DEFINE([GLIBC_2_11], 1, [Define to 1 if you're using glibc 2.11.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-         ;;
-      2.12)
- 	AC_MSG_RESULT(2.12 family)
- 	AC_DEFINE([GLIBC_2_12], 1, [Define to 1 if you're using glibc 2.12.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.13)
- 	AC_MSG_RESULT(2.13 family)
- 	AC_DEFINE([GLIBC_2_13], 1, [Define to 1 if you're using glibc 2.13.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.14)
- 	AC_MSG_RESULT(2.14 family)
- 	AC_DEFINE([GLIBC_2_14], 1, [Define to 1 if you're using glibc 2.14.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.15)
- 	AC_MSG_RESULT(2.15 family)
- 	AC_DEFINE([GLIBC_2_15], 1, [Define to 1 if you're using glibc 2.15.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.16)
- 	AC_MSG_RESULT(2.16 family)
- 	AC_DEFINE([GLIBC_2_16], 1, [Define to 1 if you're using glibc 2.16.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.17)
- 	AC_MSG_RESULT(2.17 family)
- 	AC_DEFINE([GLIBC_2_17], 1, [Define to 1 if you're using glibc 2.17.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      2.18)
- 	AC_MSG_RESULT(2.18 family)
- 	AC_DEFINE([GLIBC_2_18], 1, [Define to 1 if you're using glibc 2.18.x])
- 	DEFAULT_SUPP="glibc-2.X.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
--	DEFAULT_SUPP="glibc-2.X-drd.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.34567-NPTL-helgrind.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/glibc-2.X-drd.supp ${DEFAULT_SUPP}"
- 	;;
-      darwin)
- 	AC_MSG_RESULT(Darwin)
-@@ -926,7 +926,7 @@ case "${GLIBC_VERSION}" in
-      bionic)
- 	AC_MSG_RESULT(Bionic)
- 	AC_DEFINE([BIONIC_LIBC], 1, [Define to 1 if you're using Bionic])
--	DEFAULT_SUPP="bionic.supp ${DEFAULT_SUPP}"
-+	DEFAULT_SUPP="$srcdir/bionic.supp ${DEFAULT_SUPP}"
- 	;;
- 
-      *)
-@@ -943,11 +943,11 @@ AC_SUBST(GLIBC_VERSION)
- # attempt to detect whether such libraries are installed on the
- # build machine (or even if any X facilities are present); just
- # add the suppressions antidisirregardless.
--DEFAULT_SUPP="xfree-4.supp ${DEFAULT_SUPP}"
--DEFAULT_SUPP="xfree-3.supp ${DEFAULT_SUPP}"
-+DEFAULT_SUPP="$srcdir/xfree-4.supp ${DEFAULT_SUPP}"
-+DEFAULT_SUPP="$srcdir/xfree-3.supp ${DEFAULT_SUPP}"
- 
- # Add glibc and X11 suppressions for exp-sgcheck
--DEFAULT_SUPP="exp-sgcheck.supp ${DEFAULT_SUPP}"
-+DEFAULT_SUPP="$srcdir/exp-sgcheck.supp ${DEFAULT_SUPP}"
- 
- 
- #----------------------------------------------------------------------------
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/use-appropriate-march-mcpu-mfpu-for-ARM-test-apps.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/use-appropriate-march-mcpu-mfpu-for-ARM-test-apps.patch
new file mode 100644
index 0000000..adea405
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/use-appropriate-march-mcpu-mfpu-for-ARM-test-apps.patch
@@ -0,0 +1,44 @@
+From d134dafc2f11e0d247420a0ba360bcdef77b4093 Mon Sep 17 00:00:00 2001
+From: Andre McCurdy <armccurdy@gmail.com>
+Date: Tue, 19 Jan 2016 16:00:00 -0800
+Subject: [PATCH] use appropriate -march/-mcpu/-mfpu for ARM test apps
+
+Ensure that test apps in none/tests/arm are compiled with appropriate
+-march/-mcpu/-mfpu flags to support the instructions being tested.
+The aim is to build all tests, even ones which may not run correctly
+on all target CPUs.
+
+For tests requiring armv7ve instructions, ensure that we set both
+-march=armv7ve and -mcpu=cortex-a15 (since some TUNE_CCARGS may set
+-march=armv7-a and adding -mcpu=cortex-a15 alone is not enough to
+over-ride that).
+
+See similar cases in none/tests/arm/Makefile.am
+
+Upstream-Status: Pending
+
+Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
+---
+ none/tests/arm/Makefile.am | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/none/tests/arm/Makefile.am b/none/tests/arm/Makefile.am
+index 4507a20..825290f 100644
+--- a/none/tests/arm/Makefile.am
++++ b/none/tests/arm/Makefile.am
+@@ -62,8 +62,10 @@ neon64_CFLAGS     = $(AM_CFLAGS) -g -O0 -mcpu=cortex-a8 \
+ 			-mfpu=neon \
+ 			-mthumb
+ 
+-intdiv_CFLAGS	  = $(AM_CFLAGS) -g -mcpu=cortex-a15 -mthumb
++intdiv_CFLAGS	  = $(AM_CFLAGS) -g -march=armv7ve -mcpu=cortex-a15 -mthumb
+ ldrt_CFLAGS	  = $(AM_CFLAGS) -g -mcpu=cortex-a8 -mthumb
+ ldrt_arm_CFLAGS	  = $(AM_CFLAGS) -g -mcpu=cortex-a8 -marm
+ 
+-vfpv4_fma_CFLAGS  = $(AM_CFLAGS) -g -O0 -mcpu=cortex-a15 -mfpu=vfpv4 -marm
++vcvt_fixed_float_VFP_CFLAGS = $(AM_CFLAGS) -g -mcpu=cortex-a8 -mfpu=vfpv3
++
++vfpv4_fma_CFLAGS  = $(AM_CFLAGS) -g -O0 -march=armv7ve -mcpu=cortex-a15 -mfpu=vfpv4 -marm
+-- 
+1.9.1
+
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/valgrind-remove-rpath.patch b/yocto-poky/meta/recipes-devtools/valgrind/valgrind/valgrind-remove-rpath.patch
deleted file mode 100644
index f72e9ca..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind/valgrind-remove-rpath.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-
-Upstream-Status: Inappropriate [embedded config]
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-
-Index: valgrind-3.10.0/none/tests/Makefile.am
-===================================================================
---- valgrind-3.10.0.orig/none/tests/Makefile.am
-+++ valgrind-3.10.0/none/tests/Makefile.am
-@@ -280,7 +280,6 @@ threaded_fork_LDADD	= -lpthread
- threadederrno_LDADD	= -lpthread
- tls_SOURCES		= tls.c tls2.c
- tls_DEPENDENCIES	= tls.so tls2.so
--tls_LDFLAGS		= -Wl,-rpath,$(abs_top_builddir)/none/tests
- tls_LDADD		= tls.so tls2.so -lpthread
- tls_so_SOURCES		= tls_so.c
- tls_so_DEPENDENCIES	= tls2.so
-@@ -288,7 +287,7 @@ if VGCONF_OS_IS_DARWIN
-  tls_so_LDFLAGS		= -dynamic -dynamiclib -all_load -fpic
-  tls_so_LDADD		= `pwd`/tls2.so
- else
-- tls_so_LDFLAGS		= -Wl,-rpath,$(abs_top_builddir)/none/tests -shared -fPIC
-+ tls_so_LDFLAGS		= -shared -fPIC
-  tls_so_LDADD		= tls2.so
- endif
- tls_so_CFLAGS		= $(AM_CFLAGS) -fPIC
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind_3.10.1.bb b/yocto-poky/meta/recipes-devtools/valgrind/valgrind_3.10.1.bb
deleted file mode 100644
index 86ba979..0000000
--- a/yocto-poky/meta/recipes-devtools/valgrind/valgrind_3.10.1.bb
+++ /dev/null
@@ -1,105 +0,0 @@
-SUMMARY = "Valgrind memory debugger and instrumentation framework"
-HOMEPAGE = "http://valgrind.org/"
-BUGTRACKER = "http://valgrind.org/support/bug_reports.html"
-LICENSE = "GPLv2 & GPLv2+ & BSD"
-LIC_FILES_CHKSUM = "file://COPYING;md5=c46082167a314d785d012a244748d803 \
-                    file://include/pub_tool_basics.h;beginline=1;endline=29;md5=e7071929a50d4b0fc27a3014b315b0f7 \
-                    file://include/valgrind.h;beginline=1;endline=56;md5=92df8a1bde56fe2af70931ff55f6622f \
-                    file://COPYING.DOCS;md5=8fdeb5abdb235a08e76835f8f3260215"
-
-X11DEPENDS = "virtual/libx11"
-DEPENDS = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '${X11DEPENDS}', '', d)} \
-           ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'boost', '', d)} \
-        "
-
-SRC_URI = "http://www.valgrind.org/downloads/valgrind-${PV}.tar.bz2 \
-           file://fixed-perl-path.patch \
-           file://Added-support-for-PPC-instructions-mfatbu-mfatbl.patch \
-           file://sepbuildfix.patch \
-           file://glibc.patch \
-           file://force-nostabs.patch \
-           file://remove-arm-variant-specific.patch \
-           file://remove-ppc-tests-failing-build.patch \
-           file://valgrind-remove-rpath.patch \
-           file://enable.building.on.4.x.kernel.patch \
-           file://add-ptest.patch \
-           file://pass-maltivec-only-if-it-supported.patch \
-           file://run-ptest \
-           file://0001-valgrind-Enable-rt_sigpending-syscall-on-ppc64-linux.patch \
-          "
-
-SRC_URI[md5sum] = "60ddae962bc79e7c95cfc4667245707f"
-SRC_URI[sha256sum] = "fa253dc26ddb661b6269df58144eff607ea3f76a9bcfe574b0c7726e1dfcb997"
-
-COMPATIBLE_HOST = '(i.86|x86_64|mips|powerpc|powerpc64).*-linux'
-COMPATIBLE_HOST_armv7a = 'arm.*-linux'
-
-PR = "r1"
-
-inherit autotools ptest
-
-EXTRA_OECONF = "--enable-tls --without-mpicc"
-EXTRA_OECONF_armv7a = "--enable-tls -host=armv7-none-linux-gnueabi --without-mpicc"
-EXTRA_OECONF += "${@['--enable-only32bit','--enable-only64bit'][d.getVar('SITEINFO_BITS', True) != '32']}"
-EXTRA_OEMAKE = "-w"
-
-do_install_append () {
-    install -m 644 ${B}/default.supp ${D}/${libdir}/valgrind/
-}
-
-RDEPENDS_${PN} += "perl"
-
-FILES_${PN}-dbg += "${libdir}/${PN}/*/.debug/*"
-
-# valgrind needs debug information for ld.so at runtime in order to
-# redirect functions like strlen.
-RRECOMMENDS_${PN} += "${TCLIBC}-dbg"
-
-RDEPENDS_${PN}-ptest += " sed perl glibc-utils perl-module-file-glob"
-
-do_compile_ptest() {
-    oe_runmake check CFLAGS="${CFLAGS} -O0" CXXFLAGS="${CXXFLAGS} -O0"
-}
-
-
-do_install_ptest() {
-    chmod +x ${B}/tests/vg_regtest
-
-    # The test application binaries are not automatically installed.
-    # Grab them from the build directory.
-    #
-    # The regression tests require scripts and data files that are not
-    # copied to the build directory.  They must be copied from the
-    # source directory. 
-    saved_dir=$PWD
-    for parent_dir in ${S} ${B} ; do
-        cd $parent_dir
-
-        # exclude shell or the package won't install
-        rm -rf none/tests/shell* 2>/dev/null
-
-        subdirs="tests cachegrind/tests callgrind/tests drd/tests helgrind/tests massif/tests memcheck/tests none/tests"
-
-        # Get the vg test scripts, filters, and expected files
-        for dir in $subdirs ; do
-            find $dir | cpio -pvdu ${D}${PTEST_PATH}
-        done
-        cd $saved_dir
-    done
-
-    # clean out build artifacts before building the rpm
-    find ${D}${PTEST_PATH} \
-         \( -name "Makefile*" \
-        -o -name "*.o" \
-        -o -name "*.c" \
-        -o -name "*.S" \
-        -o -name "*.h" \) \
-        -exec rm {} \;
-
-    # needed by massif tests
-    cp ${B}/massif/ms_print ${D}${PTEST_PATH}/massif/ms_print
-
-    # handle multilib
-    sed -i s:@libdir@:${libdir}:g ${D}${PTEST_PATH}/run-ptest
-}
-
diff --git a/yocto-poky/meta/recipes-devtools/valgrind/valgrind_3.11.0.bb b/yocto-poky/meta/recipes-devtools/valgrind/valgrind_3.11.0.bb
new file mode 100644
index 0000000..51c88bf
--- /dev/null
+++ b/yocto-poky/meta/recipes-devtools/valgrind/valgrind_3.11.0.bb
@@ -0,0 +1,118 @@
+SUMMARY = "Valgrind memory debugger and instrumentation framework"
+HOMEPAGE = "http://valgrind.org/"
+BUGTRACKER = "http://valgrind.org/support/bug_reports.html"
+LICENSE = "GPLv2 & GPLv2+ & BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+                    file://include/pub_tool_basics.h;beginline=1;endline=29;md5=ebb8e640ef633f940c425686c873f9fa \
+                    file://include/valgrind.h;beginline=1;endline=56;md5=4b5e24908e53016ea561c45f4234a327 \
+                    file://COPYING.DOCS;md5=24ea4c7092233849b4394699333b5c56"
+
+X11DEPENDS = "virtual/libx11"
+DEPENDS = "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '${X11DEPENDS}', '', d)} \
+           ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', 'boost', '', d)} \
+        "
+
+SRC_URI = "http://www.valgrind.org/downloads/valgrind-${PV}.tar.bz2 \
+           file://fixed-perl-path.patch \
+           file://Added-support-for-PPC-instructions-mfatbu-mfatbl.patch \
+           file://run-ptest \
+           file://11_mips-link-tool.patch \
+           file://0002-remove-rpath.patch \
+           file://0004-Fix-out-of-tree-builds.patch \
+           file://0005-Modify-vg_test-wrapper-to-support-PTEST-formats.patch \
+           file://0001-Remove-tests-that-fail-to-build-on-some-PPC32-config.patch \
+           file://use-appropriate-march-mcpu-mfpu-for-ARM-test-apps.patch \
+           file://avoid-neon-for-targets-which-don-t-support-it.patch \
+"
+SRC_URI_append_libc-musl = "\
+           file://0001-fix-build-for-musl-targets.patch \
+"
+SRC_URI[md5sum] = "4ea62074da73ae82e0162d6550d3f129"
+SRC_URI[sha256sum] = "6c396271a8c1ddd5a6fb9abe714ea1e8a86fce85b30ab26b4266aeb4c2413b42"
+
+COMPATIBLE_HOST = '(i.86|x86_64|arm|aarch64|mips|powerpc|powerpc64).*-linux'
+
+# valgrind supports armv7 and above
+COMPATIBLE_HOST_armv4 = 'null'
+COMPATIBLE_HOST_armv5 = 'null'
+COMPATIBLE_HOST_armv6 = 'null'
+
+inherit autotools ptest
+
+EXTRA_OECONF = "--enable-tls --without-mpicc"
+EXTRA_OECONF += "${@['--enable-only32bit','--enable-only64bit'][d.getVar('SITEINFO_BITS', True) != '32']}"
+
+# valgrind checks host_cpu "armv7*)", so we need to over-ride the autotools.bbclass default --host option
+EXTRA_OECONF_append_arm = " --host=armv7${HOST_VENDOR}-${HOST_OS}"
+
+EXTRA_OEMAKE = "-w"
+
+# valgrind likes to control its own optimisation flags. It generally defaults
+# to -O2 but uses -O0 for some specific test apps etc. Passing our own flags
+# (via CFLAGS) means we interfere with that. Only pass DEBUG_FLAGS to it
+# which fixes build path issue in DWARF.
+SELECTED_OPTIMIZATION = "${DEBUG_FLAGS}"
+
+CFLAGS_append_libc-uclibc = " -D__UCLIBC__ "
+
+do_install_append () {
+    install -m 644 ${B}/default.supp ${D}/${libdir}/valgrind/
+}
+
+RDEPENDS_${PN} += "perl"
+
+# valgrind needs debug information for ld.so at runtime in order to
+# redirect functions like strlen.
+RRECOMMENDS_${PN} += "${TCLIBC}-dbg"
+
+RDEPENDS_${PN}-ptest += " sed perl perl-module-file-glob"
+RDEPENDS_${PN}-ptest_append_libc-glibc = " glibc-utils"
+
+# One of the tests contains a bogus interpreter path on purpose, and QA
+# check complains about it
+INSANE_SKIP_${PN}-ptest += "file-rdeps"
+
+do_compile_ptest() {
+    oe_runmake check
+}
+
+do_install_ptest() {
+    chmod +x ${B}/tests/vg_regtest
+
+    # The test application binaries are not automatically installed.
+    # Grab them from the build directory.
+    #
+    # The regression tests require scripts and data files that are not
+    # copied to the build directory.  They must be copied from the
+    # source directory. 
+    saved_dir=$PWD
+    for parent_dir in ${S} ${B} ; do
+        cd $parent_dir
+
+        # exclude shell or the package won't install
+        rm -rf none/tests/shell* 2>/dev/null
+
+        subdirs="tests cachegrind/tests callgrind/tests drd/tests helgrind/tests massif/tests memcheck/tests none/tests"
+
+        # Get the vg test scripts, filters, and expected files
+        for dir in $subdirs ; do
+            find $dir | cpio -pvdu ${D}${PTEST_PATH}
+        done
+        cd $saved_dir
+    done
+
+    # clean out build artifacts before building the rpm
+    find ${D}${PTEST_PATH} \
+         \( -name "Makefile*" \
+        -o -name "*.o" \
+        -o -name "*.c" \
+        -o -name "*.S" \
+        -o -name "*.h" \) \
+        -exec rm {} \;
+
+    # needed by massif tests
+    cp ${B}/massif/ms_print ${D}${PTEST_PATH}/massif/ms_print
+
+    # handle multilib
+    sed -i s:@libdir@:${libdir}:g ${D}${PTEST_PATH}/run-ptest
+}
diff --git a/yocto-poky/meta/recipes-devtools/xmlto/xmlto-0.0.26/configure.in-drop-the-test-of-xmllint-and-xsltproc.patch b/yocto-poky/meta/recipes-devtools/xmlto/xmlto-0.0.28/configure.in-drop-the-test-of-xmllint-and-xsltproc.patch
similarity index 100%
rename from yocto-poky/meta/recipes-devtools/xmlto/xmlto-0.0.26/configure.in-drop-the-test-of-xmllint-and-xsltproc.patch
rename to yocto-poky/meta/recipes-devtools/xmlto/xmlto-0.0.28/configure.in-drop-the-test-of-xmllint-and-xsltproc.patch
diff --git a/yocto-poky/meta/recipes-devtools/xmlto/xmlto_0.0.26.bb b/yocto-poky/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb
similarity index 81%
rename from yocto-poky/meta/recipes-devtools/xmlto/xmlto_0.0.26.bb
rename to yocto-poky/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb
index a7a0183..71f873f 100644
--- a/yocto-poky/meta/recipes-devtools/xmlto/xmlto_0.0.26.bb
+++ b/yocto-poky/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb
@@ -9,8 +9,8 @@
            file://configure.in-drop-the-test-of-xmllint-and-xsltproc.patch \
            file://catalog.xml \
 "
-SRC_URI[md5sum] = "0cca8be787ba01e00c618cb390c988b9"
-SRC_URI[sha256sum] = "cfd8d2a26077be1d5566dfe22dd66099ae4f4600dea97d6e113a2cc5b8708977"
+SRC_URI[md5sum] = "a1fefad9d83499a15576768f60f847c6"
+SRC_URI[sha256sum] = "2f986b7c9a0e9ac6728147668e776d405465284e13c74d4146c9cbc51fd8aad3"
 
 inherit autotools
 
@@ -27,7 +27,7 @@
 
 BBCLASSEXTEND = "native"
 
-EXTRA_OECONF_append = " XMLLINT=xmllint XSLTPROC=xsltproc"
+EXTRA_OECONF_append = " BASH=/bin/bash GCP=/bin/cp XMLLINT=xmllint XSLTPROC=xsltproc"
 
 do_install_append() {
     install -d ${D}${sysconfdir}/xml/