1
0
mirror of https://git.openwrt.org/openwrt/openwrt.git synced 2024-10-19 05:58:53 +02:00
openwrt/scripts
Jo-Philipp Wich bf5d32af2a scripts/package-metadata.pl: inhibit compile deps on missing build types
When a package declares a PKG_BUILD_DEPENDENCY or HOST_BUILD_DEPENDENCY on
a not existing build type, the metadata script will emit a reference to an
unresolvable build target in tmp/.packagedeps, causing the make process to
fail hard in a way not catchable by the IGNORE_ERRORS mechanism.

In a situation where a package "test-a" declares a build dependency
"PKG_BUILD_DEPENDS:=test-b/host" while the Makefile of "test-b" does not
implement a HostBuild, make fails with an unrecoverable error in the form:

    make[1]: Entering directory '...'
    make[1]: *** No rule to make target 'package/test-b/host/compile',
                 needed by 'package/test-a/compile'.  Stop.
    make[1]: Leaving directory '...'
    .../toplevel.mk:200: recipe for target 'package/test-a/compile' failed
    make: *** [package/test-a/compile] Error 2

Extend the metadata generation script to catch such unresolved references
and emit a visable warning upon detection.

After this change, the script will emit a warning similar to:

    WARNING: Makefile "package/test-a/Makefile" has a build dependency on
    "test-b/host" but "package/test-b/Makefile" does not implement a
    "host" build type

Fixes a global build cluster outage which occured after the "python-cffi"
feed package removed its HostBuild which the "python-cryptography" package
build-depended on.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
2017-07-27 00:37:05 +02:00
..
config
flashing
arm-magic.sh
brcmImage.pl
bundle-libraries.sh build: bundle-libraries.sh: do not override argv[0] in inner exec calls 2017-07-24 13:39:21 +02:00
checkpatch.pl
clang-gcc-wrapper
clean-package.sh
cleanfile
cleanpatch
combined-ext-image.sh
combined-image.sh scripts: make all scripts executable 2017-07-14 04:09:16 +02:00
config.guess
config.rpath
config.sub
deptest.sh
diffconfig.sh
dl_cleanup.py
download.pl scripts/download.pl: Adjust URLs 2017-07-21 08:09:45 +02:00
env
ext-toolchain.sh
feeds
fixup-makefile.pl
gen_image_generic.sh scripts/gen_image_generic.sh: drop NOGRUB variable 2017-07-14 04:09:16 +02:00
gen-dependencies.sh
get_source_date_epoch.sh
getver.sh
ipkg-build
ipkg-make-index.sh
kconfig.pl
make-ipkg-dir.sh
md5sum
metadata.pm
mkhash.c
mkits.sh
om-fwupgradecfg-gen.sh scripts: make all scripts executable 2017-07-14 04:09:16 +02:00
package-metadata.pl scripts/package-metadata.pl: inhibit compile deps on missing build types 2017-07-27 00:37:05 +02:00
pad_image
patch-kernel.sh
patch-specs.sh
portable_date.sh
qemustart
redboot-script.pl
relink-lib.sh
remote-gdb
rstrip.sh
slugimage.pl
srecimage.pl
strip-kmod.sh
symlink-tree.sh
sysupgrade-tar.sh
target-metadata.pl
timestamp.pl
ubinize-image.sh