aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
Commit message (Collapse)AuthorAgeFilesLines
* build: fix target metadata scan dependenciesFelix Fietkau2018-07-021-2/+2
| | | | | | | Move SCAN_DEPS to scan.mk to eliminate redundancy with scripts/feeds Add image/*.mk to SCAN_DEPS for targets to pick up newly added devices Signed-off-by: Felix Fietkau <nbd@nbd.name>
* scripts/download.py: use a more terse api for fetching git commit dateYousong Zhou2018-06-271-2/+2
| | | | | | | | | | | The previous api [1] includes in its response patch data among other things, as such the response size can vary and be big. Use another api[2] to improve it a bit [1] Get a single commit, Repositories, https://developer.github.com/v3/repos/commits/#get-a-single-commit [2] Git Commits, Git Data, https://developer.github.com/v3/git/commits/#get-a-commit Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
* build: download code from github using archive APIYousong Zhou2018-06-271-0/+421
| | | | | | | | | | | | | | | | | | | | | | | | | | A new python script scripts/download.py is added to fetch tarballs using GitHub archive API [1], then repack in a reproducible way same as the current DownloadMethod/git GitHub imposes a 60 reqs/hour rate limit on unauthenticated API access[2]. This affects fetching commit date for feeding tar --mtime= argument. However, observation indicates that archive download is NOT subject to this limit at the moment. In the rare cases where download fails because of this, we will falback to using DownloadMethod/git The missing piece in the GitHub API is that it cannot provide in the tarball dependent submodules's source code. In that case, the implementation will also fallback to using DownloadMethod/git [1] Get archive link, https://developer.github.com/v3/repos/contents/#get-archive-link [2] Rate limiting, https://developer.github.com/v3/#rate-limiting v2 <- v1: - allow passing multiple urls with --urls argument - add commit ts cache. can be helpful on retry Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
* ipq40xx: add support for the ZyXEL NBG6617Christian Lamparter2018-06-261-0/+196
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds support for ZyXEL NBG6617 Hardware highlights: SOC: IPQ4018 / QCA Dakota CPU: Quad-Core ARMv7 Processor rev 5 (v7l) Cortex-A7 DRAM: 256 MiB DDR3L-1600/1866 Nanya NT5CC128M16IP-DI @ 537 MHz NOR: 32 MiB Macronix MX25L25635F ETH: Qualcomm Atheros QCA8075 Gigabit Switch (4 x LAN, 1 x WAN) USB: 1 x 3.0 (via Synopsys DesignWare DWC3 controller in the SoC) WLAN1: Qualcomm Atheros QCA4018 2.4GHz 802.11bgn 2:2x2 WLAN2: Qualcomm Atheros QCA4018 5GHz 802.11a/n/ac 2:2x2 INPUT: RESET Button, WIFI/Rfkill Togglebutton, WPS Button LEDS: Power, WAN, LAN 1-4, WLAN 2.4GHz, WLAN 5GHz, USB, WPS Serial: WARNING: The serial port needs a TTL/RS-232 3.3v level converter! The Serial setting is 115200-8-N-1. The 1x4 .1" header comes pre-soldered. Pinout: 1. 3v3 (Label printed on the PCB), 2. RX, 3. GND, 4. TX first install / debricking / restore stock: 0. Have a PC running a tftp-server @ 192.168.1.99/24 1. connect the PC to any LAN-Ports 2. put the openwrt...-factory.bin (or V1.00(ABCT.X).bin for stock) file into the tftp-server root directory and rename it to just "ras.bin". 3. power-cycle the router and hold down the the WPS button (for 30sek) 4. Wait (for a long time - the serial console provides some progress reports. The u-boot says it best: "Please be patient". 5. Once the power LED starts to flashes slowly and the USB + WPS LEDs flashes fast at the same time. You have to reboot the device and it should then come right up. Installation via Web-UI: 0. Connect a PC to the powered-on router. It will assign your PC a IP-address via DHCP 1. Access the Web-UI at 192.168.1.1 (Default Passwort: 1234) 2. Go to the "Expert Mode" 3. Under "Maintenance", select "Firmware-Upgrade" 4. Upload the OpenWRT factory image 5. Wait for the Device to finish. It will reboot into OpenWRT without any additional actions needed. To open the ZyXEL NBG6617: 0. remove the four rubber feet glued on the backside 1. remove the four philips screws and pry open the top cover (by applying force between the plastic top housing from the backside/lan-port side) Access the real u-boot shell: ZyXEL uses a proprietary loader/shell on top of u-boot: "ZyXEL zloader v2.02" When the device is starting up, the user can enter the the loader shell by simply pressing a key within the 3 seconds once the following string appears on the serial console: | Hit any key to stop autoboot: 3 The user is then dropped to a locked shell. |NBG6617> HELP |ATEN x[,y] set BootExtension Debug Flag (y=password) |ATSE x show the seed of password generator |ATSH dump manufacturer related data in ROM |ATRT [x,y,z,u] RAM read/write test (x=level, y=start addr, z=end addr, u=iterations) |ATGO boot up whole system |ATUR x upgrade RAS image (filename) |NBG6617> In order to escape/unlock a password challenge has to be passed. Note: the value is dynamic! you have to calculate your own! First use ATSE $MODELNAME (MODELNAME is the hostname in u-boot env) to get the challange value/seed. |NBG6617> ATSE NBG6617 |012345678901 This seed/value can be converted to the password with the help of this bash script (Thanks to http://www.adslayuda.com/Zyxel650-9.html authors): - tool.sh - ror32() { echo $(( ($1 >> $2) | (($1 << (32 - $2) & (2**32-1)) ) )) } v="0x$1" a="0x${v:2:6}" b=$(( $a + 0x10F0A563)) c=$(( 0x${v:12:14} & 7 )) p=$(( $(ror32 $b $c) ^ $a )) printf "ATEN 1,%X\n" $p - end of tool.sh - |# bash ./tool.sh 012345678901 | |ATEN 1,879C711 copy and paste the result into the shell to unlock zloader. |NBG6617> ATEN 1,0046B0017430 If the entered code was correct the shell will change to use the ATGU command to enter the real u-boot shell. |NBG6617> ATGU |NBG6617# Co-authored-by: David Bauer <mail@david-bauer.net> Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: David Bauer <mail@david-bauer.net>
* scripts: Replace obsolete POSIX tmpnam in slugimage.pl with File::Temp functionTed Hess2018-06-051-4/+4
| | | | Signed-off-by: Ted Hess <thess@kitschensync.net>
* env: only use color diffs on terminalsPhilip Prindeville2018-05-051-1/+1
| | | | | | | | When sending script/env diff's output to a file or pipeline, you don't want escape characters for ANSI color sequences fouling the byte stream. Signed-off-by: Philip Prindeville <philipp@redfish-solutions.com>
* download.pl: Change OpenWrt mirrors to HTTPS.Rosen Penev2018-05-011-4/+4
| | | | | | These have supported HTTPS for quite a while. I have not seen any obvious breakage. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* download.pl: Change SourceForge address to HTTPS.Rosen Penev2018-05-011-1/+1
| | | | | | | | SourceForge has supported HTTPS for its downloads for a long time now. I have not been able to see any failures resulting from this change. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* scripts/feeds: add support for git feeds with submodulesFelix Fietkau2018-04-271-0/+6
| | | | Signed-off-by: Felix Fietkau <nbd@nbd.name>
* scripts: bundle-libraries: fix build on OS X (FS#1493)Jo-Philipp Wich2018-04-261-0/+4
| | | | | | | | This allegedly fixes compilation of the library bundler preload library on Apple OS X. The resulting executables have not been runtime tested due to a lack of suitable test hardware. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* ipq40xx: add support for OpenMesh A62Sven Eckelmann2018-04-231-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * QCA IPQ4019 * 256 MB of RAM * 32 MB of SPI NOR flash (s25fl256s1) - 2x 15 MB available; but one of the 15 MB regions is the recovery image * 2T2R 2.4 GHz - QCA4019 hw1.0 (SoC) - requires special BDF in QCA4019/hw1.0/board-2.bin with bus=ahb,bmi-chip-id=0,bmi-board-id=20,variant=OM-A62 * 2T2R 5 GHz (channel 36-64) - QCA9888 hw2.0 (PCI) - requires special BDF in QCA9888/hw2.0/board-2.bin bus=pci,bmi-chip-id=0,bmi-board-id=16,variant=OM-A62 * 2T2R 5 GHz (channel 100-165) - QCA4019 hw1.0 (SoC) - requires special BDF in QCA4019/hw1.0/board-2.bin with bus=ahb,bmi-chip-id=0,bmi-board-id=21,variant=OM-A62 * multi-color LED (controlled via red/green/blue GPIOs) * 1x button (reset; kmod-input-gpio-keys compatible) * external watchdog - triggered GPIO * 1x USB (xHCI) * TTL pins are on board (arrow points to VCC, then follows: GND, TX, RX) * 2x gigabit ethernet - phy@mdio3: + Label: Ethernet 1 + gmac0 (ethaddr) in original firmware + 802.3at POE+ - phy@mdio4: + Label: Ethernet 2 + gmac1 (eth1addr) in original firmware + 18-24V passive POE (mode B) * powered only via POE The tool ap51-flash (https://github.com/ap51-flash/ap51-flash) should be used to transfer the factory image to the u-boot when the device boots up. The initramfs image can be started using setenv bootargs 'loglevel=8 earlycon=msm_serial_dm,0x78af000 console=ttyMSM0,115200 mtdparts=spi0.0:256k(0:SBL1),128k(0:MIBIB),384k(0:QSEE),64k(0:CDT),64k(0:DDRPARAMS),64k(0:APPSBLENV),512k(0:APPSBL),64k(0:ART),64k(0:custom),64k(0:KEYS),15552k(inactive),15552k(inactive2)' tftpboot 0x84000000 openwrt-ipq40xx-openmesh_a62-initramfs-fit-uImage.itb set fdt_high 0x85000000 bootm 0x84000000 Signed-off-by: Sven Eckelmann <sven.eckelmann@openmesh.com>
* scripts: add EVA ramboot scriptValentin Spreckels2018-03-181-0/+37
| | | | | | | | | | | | Use the EVA bootloader to load a small linux system into the ram and boot it from there: ./scripts/flashing/eva_ramboot.py 192.168.178.1 path/to/initramfs-kernel.bin Signed-off-by: Valentin Spreckels <Valentin.Spreckels@Informatik.Uni-Oldenburg.DE> Acked-by: John Crispin <john@phrozen.org> [reworded commit message] Signed-off-by: Mathias Kresin <dev@kresin.me>
* build: Allow to change the FIT config section nameSven Eckelmann2018-03-171-4/+6
| | | | | | | | Some devices only boot when a special config is found in the image and completely ignore the default entry during the selection. These devices can now use the variable DEVICE_DTS_CONFIG in their device image definition. Signed-off-by: Sven Eckelmann <sven@narfation.org>
* scripts/metadata.pm: allow group-only Require-User specsMatthias Schiffer2018-02-261-2/+4
| | | | | | | | /lib/functions.sh can deal with Require-User specifications that only contain a group, but no user. Adjust metadata.pm to allow such specifications as well. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* build: cleanup leftover qconf filesAlif M. Ahmad2018-02-131-1/+1
| | | | | | | | | | ``make xconfig`` toplevel target will invoke ``make qconf`` inside ./scripts/config directory, which results a ``qconf`` executable. This commit removes leftover ``qconf`` executable during ``make config-clean``. Signed-off-by: Alif M. Ahmad <alive4ever@live.com>
* build: bundle-libraries.sh: patch bundled ld.soJo-Philipp Wich2018-02-021-0/+13
| | | | | | | | | | | Remove references to /etc/, /lib/ and /usr/ from the bundled ld.so interpreter using simple binary patching. This is needed to prevent loading host system libraries such as libnss_compat.so.2 on foreign systems, which may result in ld.so inconsistency assertions. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* scripts/qemustart: more portable array operationYousong Zhou2018-01-311-4/+4
| | | | | | | | | | | | | | | | | | The following commands output 1,2,1,1 cmd0='a=("${a[@]}" 'a'); echo "${#a}"' cmd1='a+=('a'); echo "${#a}"' bash -c "$cmd0"; zsh -c "$cmd0" bash -c "$cmd1"; zsh -c "$cmd1" The following outputs 0,1,0,0 cmd2='f() { echo "$#"; }; f "${a[@]}"' cmd3="a=(); $cmd2" bash -c "$cmd2"; zsh -c "$cmd2" bash -c "$cmd3"; zsh -c "$cmd3" Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
* metadata: do not emit broken kconfig dependency statementsJo-Philipp Wich2018-01-141-1/+1
| | | | | | | | Prevent emitting broken dependency statements when resolving references to non existing packages to an empty provider list. Fixes: 47d6b05ad3 ("metadata: always resolve dependencies through provides list") Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* scripts/feeds: fix install of packages with different source/binary namesMatthias Schiffer2018-01-141-1/+1
| | | | | | | | The logic for choice between source and binary packages was reversed. Fixes: 52719c2b67af "metadata: scripts/feeds: distinguish between source and binary packages, resolve virtual dependencies" Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: improve code readability by using (s)printf instead of string ↵Matthias Schiffer2018-01-131-13/+13
| | | | | | interpolation Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* build: remove obsolete "package feature" featureMatthias Schiffer2018-01-132-48/+1
| | | | | | | | Package "features" seem to be unused for some time. In any case, custom Config.in snippets and package PROVIDES are a much more flexible way to express similar options. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: scripts/feeds: distinguish between source and binary packages, ↵Matthias Schiffer2018-01-132-70/+112
| | | | | | | | | | resolve virtual dependencies Properly resolve build depends to source packages and runtime depends to binary packages. Dependencies on virtual packages are resolved to the first provider now. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: always resolve dependencies through provides listMatthias Schiffer2018-01-133-46/+35
| | | | | | | | | | | Instead of adding virtual packages to the normal package list, keep a separate list for provides, make each package provide itself, and resolve all dependencies through this list. This allows to use PROVIDES to replace existing packages. Fixes FS#837. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: simplify generation of build depends from runtime dependsMatthias Schiffer2018-01-131-71/+41
| | | | | | | | | | | Runtime depends cannot have a buildtype suffix, and they never refer to source package names. In addition, this adds warnings about unsatisfiable dependencies. Furthermore, this change fixes the generation of conditional build dependencies for virtual packages provided by different source packages. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: handle target build depends together with host build dependsMatthias Schiffer2018-01-131-32/+28
| | | | | | | | | | | | | | Target build depends are similar to host build depends in that they refer to source packages rather than binary packages. Therefore, it makes sense to handle them together, rather than putting them in a list together with runtime depends and trying to figure out if the entries refer to source or to binary packages afterwards. This does lead to PKG_BUILD_DEPENDS entries referring to binary package names not working anymore, which requires some fixes in the package repositories. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* build: remove package preconfig featureMatthias Schiffer2018-01-132-55/+1
| | | | | | | This feature has been unused for years, and its scope is too limited to be actually useful. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: remove redundant fields from package hashMatthias Schiffer2018-01-133-8/+9
| | | | Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: replace %subdir hash with a path field in source packagesMatthias Schiffer2018-01-132-22/+15
| | | | | | | Every single reference to subdir was concatenated with the source package name, so it makes sense to store the concatenated value instead. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: change pkg->{src} field to hold a referenceMatthias Schiffer2018-01-133-35/+34
| | | | | | | | We often want to access fields of a source packages through pkg->{src}. Allow accessing them directly instead of resolving the source hash through srcpackages. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: interate over source packages when generating MakefileMatthias Schiffer2018-01-132-26/+36
| | | | | | | | | | | | All build dependencies are between source packages. Interating over source rather than binary packages simplifies parts of the code and prepares further improvement. As a side effect, this changes the implicit default variant of a few packages (the first defined is used now instead of the lexicographically first). Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: move 'builddepends' from binary to source packagesMatthias Schiffer2018-01-133-21/+21
| | | | Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: move 'buildtypes' from binary to source packagesMatthias Schiffer2018-01-132-8/+9
| | | | | | | Build types are a property of source rather than binary packages. This is a preparation for followup cleanup. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: make srcpackage extensibleMatthias Schiffer2018-01-133-4/+6
| | | | | | | Turn the srcpackage values into hashes to allow storing more information than just binary package names. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* metadata: remove 'base-files' special caseMatthias Schiffer2018-01-131-1/+1
| | | | | | | Nothing explicitly depends on base-files, and even if it would, it would not cause any problems. Remove the unused special case. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* om-fwupgradecfg-gen.sh: add support for the A42Sven Eckelmann2018-01-131-4/+18
| | | | Signed-off-by: Sven Eckelmann <sven.eckelmann@open-mesh.com>
* combined-ext-image.sh: generate image in temp dirSven Eckelmann2018-01-131-6/+23
| | | | | | | | | | | | | The new build commands operate on the input image and use it again as output image. This conflicts with the way combined-ext-image.sh was operating. It required that input and output files are different files and and that it can write freely to the output file. This can be avoided when all intermediate build steps by combined-ext-image.sh are done in a temporary directory. The output file is then only overwritten in the last step. Signed-off-by: Sven Eckelmann <sven.eckelmann@open-mesh.com>
* scripts/package-metadata.pl: remove broken detection of self-dependenciesMatthias Schiffer2018-01-041-5/+0
| | | | | | | | | | | | | A self-dependency is not an error worth a warning; rather, it is very common: whenever there are dependencies between different binary packages originating from the same source package, such dependencies occur. Not actually generating dependency rules is correct, but already handled a few lines below. A typo prevented this redundant rule from working, which is the reason the warning was not actually printed. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
* base-files: allow skipping of hash verificationJo-Philipp Wich2017-12-141-1/+1
| | | | | | | | | | | | | | | | | | | | | When calling a download target, hash verification is now completely skipped if we set PKG_HASH=skip. This allows to easily bump package version: $ make package/<mypackage>/download PKG_HASH=skip V=s $ make package/<mypackage>/check FIXUP=1 V=s This will download the new version of the package, and then automatically update PKG_HASH with the hash of the new version. Of course, it is still the responsibility of the packager to ensure that the new tarball is legitimate, because it is downloaded from a possibly untrusted source. Fixes: b30ba14e ("scripts/download.pl: fail loudly if provided hash is unsupported") Signed-off-by: Baptiste Jonglez <git@bitsofnetworks.org> Signed-off-by: Jo-Philipp Wich <jo@mein.io> Acked-by: Stijn Tintel <stijn@linux-ipv6.be> Signed-off-by: John Crispin <john@phrozen.org>
* merge: targets: update image generation and targetsZoltan HERPAI2017-12-082-7/+7
| | | | Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
* merge: base: update base-files and basic configZoltan HERPAI2017-12-082-2/+2
| | | | Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
* scripts/config: add qconf files to .gitignoreAlif M. Ahmad2017-11-021-0/+6
| | | | | | | | | This commit adds qconf related files to .gitignore. The files to be tracked are qconf.cc, qconf.h, and images.c. The files to be ignored are qconf*.o, qconf*, qconf.moc, and .tmp_qtcheck. Signed-off-by: Alif M. Ahmad <alive4ever@live.com>
* scripts/config: Add qconf target to MakefileAlif M. Ahmad2017-11-021-0/+56
| | | | | | | | | | qconf is kconfig UI utilizing QT toolkit. This makes it possible to use graphical interface interaction to configure LEDE build target. This commit adds qconf target to ./script/config/Makefile to be used by toplevel ``make xconfig`` later. Signed-off-by: Alif M. Ahmad <alive4ever@live.com>
* scripts/config: add -DKBUILD_NO_NLS to CXXFLAGSFelix Fietkau2017-11-021-0/+1
| | | | | | Preparation for adding C++ code which needs the same flag Signed-off-by: Felix Fietkau <nbd@nbd.name>
* scripts/config: import qconfAlif M. Ahmad2017-11-023-0/+2526
| | | | | | Import qconf.cc, qconf.h, and images.c from linux kernel 4.9.13 archive. Signed-off-by: Alif M. Ahmad <alive4ever@live.com>
* treewide: fix shellscript syntax errors/typosLorenzo Santina2017-09-131-1/+1
| | | | | | | | | Fix multiple syntax errors in shelscripts (of packages only) These errors were causing many conditions to not working properly Signed-off-by: Lorenzo Santina <lorenzo.santina@edu.unito.it> [increase PKG_RELEASE, drop command substitution from directip.sh] Signed-off-by: Mathias Kresin <dev@kresin.em>
* scripts/download.pl: fail loudly if provided hash is unsupportedBaptiste Jonglez2017-09-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | Currently, if the provided hash is unsupported (length different from 32 or 64 bytes), we happily download the requested file without any kind of checksum verification. This is quite dangerous and may provide a false sense of security, because a single typo in the hash (e.g. one character deleted by mistake) may skip checksum verification entirely. Instead, fail immediately if we don't support the provided hash. In particular, if an external package repository decides to change the hash algorithm one day, we will now fail loudly instead of skipping checksum verification without complaints. Note: if some users of scripts/download.pl knowingly provide an empty hash because they don't need checksum verification, this change will break them. This does not seem to be the case currently, but if this feature is ever needed, an option should be added to download.pl instead of relying on the hash being empty. Fixes: eaa4eba10a89 ("scripts/download.pl: add SHA-256 support") Signed-off-by: Baptiste Jonglez <git@bitsofnetworks.org>
* scripts/dowload.pl: use glob to expand target dirZoltan Gyarmati2017-08-301-1/+1
| | | | | | | | | | | | | | If CONFIG_DOWNLOAD_FOLDER is set to for example "~/dl", the download script fails to create the .hash and .dl files with the following errors: Cannot create file ~/dl/dropbear-2017.75.tar.bz2.dl: No such file or directory sh: 1: cannot create ~/dl/dropbear-2017.75.tar.bz2.hash: Directory nonexistent If the tarball already exists in the ~/dl dir, it's properly found and used, so this issue only affects the download.pl script. This patch calls glob() on the target dir parameter, which will expand `~`. Signed-off-by: Zoltan Gyarmati <mr.zoltan.gyarmati@gmail.com>
* scripts/package-metadata.pl: inhibit compile deps on missing build typesJo-Philipp Wich2017-07-271-6/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* build: bundle-libraries.sh: do not override argv[0] in inner exec callsJo-Philipp Wich2017-07-241-1/+3
| | | | | | | | | | | Only mangle argv[0] of the first executed process and leave the argument vector of subsequent invocations as-is to allow child programs to properly discover resources relative to their binary locations. Fixes "cc1" discovery when executing the host gcc through the bundled "ccache" executable. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
* scripts/download.pl: Adjust URLsDaniel Engberg2017-07-211-5/+5
| | | | | | | | | | | | Internet2 isn't considered a trusted issuer meaning that https links to rit.edu will fail. The host mirror.csclub.uwaterloo.ca has a trusted SSL cert and peering is good so it can replace rit.edu without performance issues. Signed-off-by: Daniel Engberg <daniel.engberg.lists@pyret.net> [Jo-Philipp Wich: rewrapped commit message] Signed-off-by: Jo-Philipp Wich <jo@mein.io>