summaryrefslogtreecommitdiffstats
path: root/support
Commit message (Collapse)AuthorAgeFilesLines
...
* check-uniq-files: fix code styleRicardo Martincoski2018-01-291-1/+3
| | | | | | | | | | | Fix these warnings: E128 continuation line under-indented for visual indent E302 expected 2 blank lines, found 1 E305 expected 2 blank lines after class or function definition, found 1 Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Yann E. MORIN <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* graph-depends: fix code styleRicardo Martincoski2018-01-292-28/+48
| | | | | | | | | | | | | | | | | | | Fix these warnings: E122 continuation line missing indentation or outdented E127 continuation line over-indented for visual indent E128 continuation line under-indented for visual indent E202 whitespace before ']' E221 multiple spaces before operator E225 missing whitespace around operator E231 missing whitespace after ',' E302 expected 2 blank lines, found 1 E305 expected 2 blank lines after class or function definition, found 1 E502 the backslash is redundant between brackets E713 test for membership should be 'not in' Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* merge_config.sh: add br2-external supportIlya Kuzmich2018-01-291-1/+7
| | | | | | | | | | Pass BR2_EXTERNAL value via -e option. This will prevent merge_config.sh from silently eating any symbols defined in external trees on a clean buildroot tree invocation. Signed-off-by: Ilya Kuzmich <ilya.kuzmich@gmail.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* tests: add test for post-fakeroot scriptYann E. MORIN2018-01-154-13/+7
| | | | | | | | | | | | | | | | | | Currently, only post-build and post-image scripts were tested, each with their own test-script. The two test-scripts only differ in the name of the log file they create, and it is based on the name of the script, so it is easy to share the script. This allows us to easily re-use it for testing post-fakeroot scripts. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Cc: Ricardo Martincoski <ricardo.martincoski@gmail.com> Reviewed-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Tested-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/kconfig: ppply upstream nconfig ncurses/ncursesw fixGuillermo A. Amaral2018-01-153-1/+48
| | | | | | | | | | | | | | | | | | | | | Buildroot's "make nconfig" command stopped working a while ago on Gentoo systems. Running the command would result in a crash. The issue is caused by lxdialog's cflags which are also used to build nconfig; It would detect *ncursesw* and turn on WIDECHAR support -- but the Makefile would still link to plain *ncurses* while building nconfig (which was built without WIDECHAR support). This would cause a crash after using *wattrset* on a WINDOW instance. WIDECHAR *wattrset* would try to set the _color member in the WINDOW struct which does not exist in the NON-WIDECHAR ncurses instance. It would end up clobbering data outside the struct (usually _line entries). An upstream patch fixes the issue, so we're applying it to Buildroot's kconfig. Signed-off-by: Guillermo A. Amaral <g@maral.me> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/dockerfile: add directives to run as non-rootYann E. MORIN2018-01-121-0/+7
| | | | | | | | | | | | | | | | | | | | Currently, our jobs on the gitlab-ci infra are running as root, which is problematic for two reasons: - this is not the usual way Buildroot is built; - it may miss issues where running as non-root is problematic. So, complement our Dockerfile with directives to add a new user and run everything as that user, as demonstrated by this build job: https://gitlab.com/ymorin/buildroot-ci/-/jobs/46929562 Additional, enforce an UTF-8 locale while running. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Peter Korsgaard <peter@korsgaard.com> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/config-fragments: br-powerpc-internal-full: remove old optionRomain Naour2018-01-121-1/+0
| | | | | | | | | | | | | | | | | BR2_TOOLCHAIN_BUILDROOT_INET_IPV6 has been removed with the commit [1]. Since this option is still in br-powerpc-internal-full config-fragment, the powerpc configuration is droped by autobuild-run script: WARN: toolchain can't be used Missing: BR2_TOOLCHAIN_BUILDROOT_INET_IPV6=y [Sat, 06 Jan 2018 03:03:43] WARN: failed to generate configuration [1] 4bcacfd2c05f45171c011d4af7731c6f848819a4 Signed-off-by: Romain Naour <romain.naour@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* dependencies: correct dependencies for top-level parallel buildArnout Vandecappelle (Essensium/Mind)2018-01-081-0/+2
| | | | | | | | | | | | | | | | | | | | Commit 4932c8a7cc94277b3d53cecd935f725b91cfa9fe introduced the core-dependencies target to make sure that the dependencies.sh script runs before we attempt to compile any host tool, so that the absence of a compiler is properly detected. However, this relied on the left-to-right evaluation of dependencies. This will no longer be true when we enable top-level parallel build. Fix this by letting DEPENDENCIES_HOST_PREREQ depend on core-dependencies. Note that it is not possible to remove the dependencies <- core-dependencies. Indeed, it is possible that DEPENDENCIES_HOST_PREREQ is completely empty, and in that case we still need to check core-dependencies. Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* core-dependencies: remove unneeded HOSTCCArnout Vandecappelle (Essensium/Mind)2018-01-081-4/+3
| | | | | | | | | | | | | dependencies.sh uses HOSTCC_NOCCACHE directly, and this variable is exported from the top-level Makefile, so there is no need to pass HOSTCC to it. HOSTCC is not used at all in dependencies.sh. Thus, we also no longer need to apply the HOSTCC override for core-dependencies. The core-depencies rule doesn't use HOSTCC or HOSTCXX. Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/scripts: sort pie chartsThomas De Schampheleire2018-01-022-2/+2
| | | | | | | | | | Make sure that the pie charts produced by 'graph-build' and 'graph-size' targets are sorted on the size of each piece of the pie. Otherwise, making visual analysis is difficult, as one needs to look at the legends of each piece and do the sorting manually in their head. Signed-off-by: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* fs/iso9660: fix transparent (de)compressionYann E. MORIN2018-01-021-0/+1
| | | | | | | | | | | | | | | | | | | | | | It needs mkzftree from zisofs-tools, so we add a dependency to it, and we call that one explicitly (to avoid using the one from the host in PATH). It also needs the the uncompressed kernel image, but because it is already in target/ so it gets compressed by mkzftree. We have two options: - compress everything but the kernel image, - compress everything, kernel included, and recopy it later. We choose the latter, because it is the simplest solution. So, we always define the kernel-copy hook, but only register it when needed. Finally, it needs a kernel with support for transparent (de)compression, so we update the existing test config. Reported-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* core/tests: add test for compressed iso9660Yann E. MORIN2017-12-311-0/+41
| | | | | | | Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> [Thomas: really set the transparent compression option, take into account the renaming of the option.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/testing: TestATFMarvell needs BR2_TARGET_UBOOT_NEEDS_DTC=yThomas Petazzoni2017-12-121-0/+1
| | | | | | | | | | | | The Marvell U-Boot needs DTC to build, so the test case fails to build on systems where dtc isn't available. We add BR2_TARGET_UBOOT_NEEDS_DTC=y to make sure that we build our own DTC. Fixes: https://gitlab.com/buildroot.org/buildroot/-/jobs/44126707 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/scripts/genimage.sh: show usage when invoked incorrectlyLuca Ceresoli2017-12-111-1/+5
| | | | | | [Peter: use ${0}] Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/testing: add tests for ATFThomas Petazzoni2017-12-082-0/+79
| | | | | | | | | These new tests only do build tests, but allow to quickly verify that the ATF/U-Boot combinations for vexpress, Allwinner and Marvell platforms all continue to build properly. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* Merge branch 'next'Thomas Petazzoni2017-12-011-0/+40
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This merges the next branch accumulated during the 2017.11 release cycle back into the master branch. A few conflicts had to be resolved: - In the DEVELOPERS file, because Fabrice Fontaine was added as a developer for libupnp in master, and for libupnp18 in next. Resolution is simple: add him for both. - linux/Config.in, because we updated the 4.13.x release used by default in master, while we moved to 4.14 in next. Resolution: use 4.14. - package/libupnp/libupnp.hash: a hash for the license file was added in master, while the package was bumped into next. Resolution: keep the hash for the license file, and keep the hash for the newest version of libupnp. - package/linux-headers/Config.in.host: default version of the kernel headers for 4.13 was bumped to the latest 4.13.x in master, but was changed to 4.14 in next. Resolution: use 4.14. - package/samba4/: samba was bumped to 4.6.11 in master for security reasons, but was bumped to 4.7.3 in next. Resolution: keep 4.7.3. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
| * core: check files are not touched by more than one packageYann E. MORIN2017-11-271-0/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, we do nothing about packages that touch the same file: given a specific configuration, the result is reproducible (even though it might not be what the user expected) because the build order is guaranteed. However, when we later introduce top-level parallel build, we will no longer be able to guarantee a build order, by the mere way of it being parallel. Reconciliating all those modified files will be impossible to do automatically. The only way will be to refuse such situations. As a preliminary step, introduce a helper script that detects files that are being moified by two or more packages, and reports them and the impacted packages, at the end of the build. The list being reported at the end of the build will make it prominently visible in autobuilder results, so we can assess the problem, if any. Later on, calling that helper script can be done right after the package installation step, to bail out early. Thanks Arnout for the pythonist way to write default dictionaries! ;-) Note: doing it in python rather than a shell script is impressively faster: where the shell script takes ~1.2s on a minimalist build, the python script only takes ~0.015s, that is about 80 times faster. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Cc: Peter Korsgaard <peter@korsgaard.com> Cc: Baruch Siach <baruch@tkos.co.il> Cc: Peter Seiderer <ps.report@gmx.net> [Thomas: rename script without .py extension.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* | Update for 2017.112017.11Peter Korsgaard2017-11-301-1/+1
| | | | | | | | Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* | support/scripts/size-stats: avoid divide-by-zeroAndrey Yurovsky2017-11-291-2/+10
| | | | | | | | | | | | | | | | | | | | Some packages (ex: skeleton-init-systemd) have a zero size so we cannot divide by the package size. In that case make their percent zero explicitly and avoid a ZeroDivisionError exception. Signed-off-by: Andrey Yurovsky <yurovsky@gmail.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* | support/download: svn non-interactive in BR2_SVNSam Voss2017-11-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of overriding the _svn command and injecting --non-interactive, change the default value of BR2_SVN to include this flag so the end user can choose not to use the flag. This change helps users behind corporate system rules which may not allow them to locally cache credentials and require interactive mode. Signed-off-by: Sam Voss <sam.voss@rockwellcollins.com> [Originally implemented by] CC: "Yann E. MORIN" <yann.morin.1998@free.fr> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* | support/config-fragments: update ARC pre-built toolchainThomas Petazzoni2017-11-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | This is needed to get the autobuilders to use a toolchain that includes the fix merged in 9d544feb8a277a43abec889450f917017d666e49 ("fwup: fix for ARC toolchain"). In addition, this new toolchain version also fixes for real the RPATH issue that should have been fixed by f90f28a6dfe85439d11e5fd83f2462ff29502e11, but wasn't done properly. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* | support/config-fragments: update ARC toolchainThomas Petazzoni2017-11-141-1/+1
|/ | | | | | | | | | | | | | | | | | | | | | | | | This commit updates the br-arcle-hs38 configuration fragment to use a slightly updated ARC toolchain in which the RPATH of the ar and ranlib tools have been manually fixed to be correct. This is a temporary workaround until the issue gets resolved properly in the RPATH fixing logic, and is needed to fix a number of build issues. Fixes: http://autobuild.buildroot.net/results/0ae0d6eba6e2cd8d2298cc4ba6380b8c3e9dd86a/ (libnl) http://autobuild.buildroot.net/results/fa9bdad8d8b57d1db7f22abdb063ade470e9f938/ (pcsc-lite) http://autobuild.buildroot.net/results/fca2ad71c7d446e4738834a1f220d950bce5fddd/ (alsa-lib) http://autobuild.buildroot.net/results/945c60ff942dfd3daa4da27f5e19470e3d97aed4/ (libcap) Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/config-fragments/autobuild: update toolchains for 2017.11-rc1Thomas Petazzoni2017-11-1131-55/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | All Buildroot pre-built toolchains have been rebuilt with Buildroot 2017.11-rc1, so that they have the latest version of glibc/musl/uClibc, and also the latest gcc/binutils updates. Specifically, this will fix the build failures on Blackfin that were due to the missing accept4() support: http://autobuild.buildroot.net/results/8b5a72dd7cde685f6f68f46aeee8b1b60c96d559/ (openobex) http://autobuild.buildroot.net/results/b19dd9ed29944d7f79c6f824669e3baaa0bb045a/ (libiio) In terms of changes to the toolchains: - AArch64 glibc toolchain changed to use 4.4 kernel headers instead of 4.1, in order to increase the variety of kernel header versions being tested. - Most configurations now use 4.13 kernel headers instead of 4.12 (except the configurations that were explicitly using an older kernel headers version) - The mips64 n64 configuration is changed from using gcc 4.9 to gcc 5, since another ARM configuration already tests gcc 4.9. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* suport/download: force svn to be non-interactiveYann E. MORIN2017-11-051-1/+1
| | | | | | | | | | | Fixes: http://autobuild.buildroot.org/results/2af/2af7412846c576089f8596857ab8c81ac31c1bed/ Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Cc: André Hentschel <nerv@dawncrow.de> Reviewed-by: André Hentschel <nerv@dawncrow.de> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* dependencies: always use HOSTCC_NOCACHE for DEPENDENCIES_HOST_PREREQAlfredo Alvarez Fernandez2017-10-221-2/+2
| | | | | | | | | | | | | | | | | | | | | | | Currently, HOSTCC and HOSTCXX are set to their _NOCACHE variants in the 'dependencies' target. This is needed because at that time, ccache is not built yet - host-ccache is one of the dependencies. However, because this override is only specified for the 'dependencies' target (and thereby gets inherited by its dependencies), the override is only applied when the package is reached through the 'dependencies' target. This is not the case when one of DEPENDENCIES_HOST_PREREQ is built directly from the command line, e.g. when doing 'make host-ccache'. So in that case, ccache will be built with ccache... which fails of course. To fix this, directly apply the override to the DEPENCIES_HOST_PREREQ targets. Note that this only fixes the issue for 'make host-ccache', NOT for e.g. 'make host-ccache-configure'. Signed-off-by: Alfredo Alvarez Fernandez <alfredo.alvarez_fernandez@nokia.com> [Arnout: improve commit message] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* support/config-fragments/autobuild: add ARC glibc fragmentAlexey Brodkin2017-10-212-0/+5
| | | | | | | | | | glibc is now supported for ARC so let's kick-start autobuilders with glibc toolchain for ARC HS. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Cc: Arnout Vandecappelle <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/testing: update ISO9660 test case Linux kernelThomas Petazzoni2017-10-212-11/+36
| | | | | | | | | | | The Linux 4.0 kernel doesn't build with gcc 6.x, which is used since the toolchain update in commit 193dfffa834a4cd76bc7b41089bd93d4c37dfc65 ("support/testing: use more recent toolchains"). So let's update to Linux 4.11 instead (like the existing Qemu x86 defconfig does), and update the kernel configuration file accordingly. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/testing: use more recent toolchainsThomas Petazzoni2017-10-213-9/+7
| | | | | | | With the hard disk crash of autobuild.b.o, we lost old toolchains, so use the latest toolchains, which have been restored. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/run-tests: export download dirYann E. MORIN2017-10-101-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, the download directory, when specified with the -d option, is only used to store the files downloaded by the testing infra, not those downloaded by Buildroot. So, we end up with this situation: BR2_DL_DIR | -d DIR | test downloads | BR downloads ------------+----------+------------------+-------------- unset | unset | [error] | [error] unset | set | in $(DIR) | in $(TOP_DIR)/dl set | unset | in $(BR2_DL_DIR) | in $(BR2_DL_DIR) set | set | in $(DIR) | in $(BR2_DL_DIR) This is not very consistent. We change the behaviour so that the value of -d always takes precedence, and is used by Buildroot as well, giving this new behaviour: BR2_DL_DIR | -d DIR | test downloads | BR downloads ------------+----------+------------------+-------------- unset | unset | [error] | [error] unset | set | in $(DIR) | in $(DIR) set | unset | in $(BR2_DL_DIR) | in $(BR2_DL_DIR) set | set | in $(DIR) | in $(DIR) Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/kconfig: fix usage typo and align verb tensesThomas De Schampheleire2017-10-102-2/+2
| | | | | | | | Fix typo 'selectes' -> 'selects'. Additionally, change 'will exclude' to 'excludes' to align with 'selects'. Signed-off-by: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/testing: fix remaining code styleRicardo Martincoski2017-10-061-2/+2
| | | | | | | | | | Fix the remaining code style warnings from flake8: - properly indent continuation lines; - use proper code to test a parameter is not None. Cc: Yann E. MORIN <yann.morin.1998@free.fr> Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* testing/tests/init: use lowercase method namesRicardo Martincoski2017-10-064-39/+39
| | | | | | | | | | | | | | Use method naming convention from PEP8 as other test cases already do. sed \ -e 's,startEmulator,start_emulator,g' \ -e 's,checkInit,check_init,g' \ -e 's,checkNetwork,check_network,g' \ -i support/testing/tests/init/*.py Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* support/testing: fix code styleRicardo Martincoski2017-10-0621-20/+59
| | | | | | | | | | | Fix the trivial warnings from flake8: - remove modules imported but unused; - use 2 lines before class or module level method; - remove blank line at end of file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* support/testing: standardize defconfig fragments styleRicardo Martincoski2017-10-0614-250/+255
| | | | | | | | | | | | | | Change all defconfig fragments to take advantage of "cf3cd4388a support/tests: allow properly indented config fragment". Make each defconfig fragment: - start after a backslash; - be declared as a multi-line string literal; - be indented one level more than the variable that contains it. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* support/testing: allow to indent ccache defconfig fragmentRicardo Martincoski2017-10-062-4/+3
| | | | | | | | | | | | | | | | | | Move the strip out of leading spaces in defconfig fragments from the BRTest class to the Builder class. It actually postpones the strip out, consequentially allowing test cases to post-process the defconfig in their own __init__ before calling the __init__ method from BRTest. Moving this code to the Builder class also allows any new test class that inherits from BRTest to reuse the same code even if the new class overrides the setUp method. At same time, prepend a newline to the jlevel handling otherwise it would stop working for defconfig fragments that don't end in a newline. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Yann E. MORIN <yann.morin.1998@free.fr> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* support/check-rpath: recognise PIEYann E. MORIN2017-09-271-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | We sanity-check the host executables that they have a correct RPATH pointing to the host libraries. This is currently done by looking for all files in $(HOST_DIR) that match the 'ELF executable' pattern (a bit more complex, but that's idea). However, when an executable is built with -fPIE of -fpie, it no longer appears to be an 'ELF executable', but it rather looks like an 'ELF sheard object' (like if it were an library. So, we miss those files. It turns out that the problem is a real one, because quite a few mainline distros, expecially those based on Debian for example, have already switched to generating PIE code by default, and thus we miss on a whole class of systems.. We fix that by simply looking if we can find an ELF interpreter in each file. If we there is one, this is an ELF executable; if not, it may be anything else: we don't care (not even about ELF libraries). Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Arnout Vandecappelle <arnout@mind.be> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* boot/grub: removeYann E. MORIN2017-09-232-57/+0
| | | | | | | | | | | | | | | | | | | | | | grub is no longer maintained: it is stuck at version 0.97 with huge patches that have no opportunity to be applied upstream, as upstream has even renamed it grub-legacy. Besides, it no longer builds correctly with recent binutils versions, and even the huge patches we could grab from Debian do not help the slightest. Since upstream really considers it dead, and there are at least two alternatives (grub2 and syslinux), just remove grub. Add a legacy entry. Remove the test cases as well. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Cc: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* support/scripts/apply-patches.sh: do not apply patches with renamesThomas Petazzoni2017-09-191-0/+5
| | | | | | | | | | | | | | | | | | | | | | Patches with renames apply properly with patch >= 2.7, but not with older patch versions. Since "git format-patch" by default generates patches with renames, Buildroot developers often don't realize that their patches will not apply properly on build machines that have patch < 2.7. In order to prevent such a situation from happening again, this commit adds some logic in apply-patches.sh to refuse applying patches that contain renames. Note that just searching for '^rename' is not sufficient, since the patch commit message may contain the words "rename from" or "rename to" as well. Therefore, the grep expression is made as accurate as possible, checking both. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> [Arnout: spaces instead of tabs (suggested by Yann); extend commit message.] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* support/download: fix check_one_hash descriptionGaël PORTAY2017-09-191-2/+3
| | | | | | | | | | | Function check_one_hash takes three arguments: - algo hash - known hash - file to hash Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* download/git: force gzip compression level 6Petr Kulhavy2017-09-121-1/+1
| | | | | | | | | | | | | Force gzip compression level 6 when calculating hash of a downloaded GIT repo. To make sure the tar->gzip->checksum chain always provides consistent result.` The script was relying on the default compression level, which must not be necessarily consistent among different gzip versions. The level 6 is gzip's current default compression level. Signed-off-by: Petr Kulhavy <brain@jikos.cz> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/tests: use relative test_dirYann E. MORIN2017-09-051-2/+2
| | | | | | | | | | | | | | | When we list the available tests, we use test_dir, which is set from the path of the script. However, when we run the tests, we use the hard-coded path. Ditto to find the config file. For consistency, always use test_dir. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Cc: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/scripts/check-bin-arch: fix symbolic link checkThomas Petazzoni2017-09-051-1/+1
| | | | | | | | | | | | Commit c96b8675ea03a5d3194d439f740c725dd239ed1a ("support/scripts/check-bin-arch: ignore symbolic links") was bogus, because it tested ${f}, which is the relative path of the file inside ${TARGET_DIR}, so we end up testing if ${f} on the system is a symbolic link. This commit fixes that by testing ${TARGET_DIR}/${f}. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/scripts/check-bin-arch: ignore symbolic linksThomas Petazzoni2017-09-041-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since commit da32b49f0091ee9dfb613e0f00973bf6893bfa84 ("instrumentation: extend packages-file-list.txt with symlinks and directories"), the packages-file-list.txt also contains symbolic links. Therefore, check-bin-arch is now also checking symbolic links. However, symbolic links in $(TARGET_DIR) can have absolute path as targets, such as: $ ls -l output/target/sbin/ifdown lrwxrwxrwx 1 thomas thomas 10 Sep 3 15:55 output/target/sbin/ifdown -> /sbin/ifup Therefore, we are now potentially checking a host binary, which obviously makes check-bin-arch fail. This commit changes check-bin-arch to ignore symbolic links. Indeed, we have two cases: - The symbolic link really points to something that will in the rootfs (such as /sbin/ifup above). In this case, /sbin/ifup will be checked separately by check-bin-arch. - The symbolic link doesn't point to something that will be in the rootfs, and that is not a problem from the perspective of check-bin-arch, which checks the architecture of target binaries. Fixes: http://autobuild.buildroot.net/results/16d384a0183d477646ac7692feb65f00dde7d068/ (vim) http://autobuild.buildroot.net/results/50429c0f63a8befff9e20899327b9a8d754d99be/ (ifupdown) http://autobuild.buildroot.net/results/1db65973e782bfa61abcbccd3501bfd235f77288/ (gawk) Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* Update for 2017.082017.08Peter Korsgaard2017-09-021-1/+1
| | | | Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/testing: allow to use a multiplier for timeoutsRicardo Martincoski2017-08-103-4/+22
| | | | | | | | | | | | | Add a parameter to run-tests to act as a multiplier for all timeouts of emulator. It can be used to avoid sporadic failures on slow host machines as well in elastic runners on the cloud. Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> [Arnout: rename multiplier to timeout_multiplier everywhere] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* support/testing: add runtime testing for read-only systemdYann E. MORIN2017-08-022-0/+71
| | | | | | | | | | | | | | | | | | We add the 3 following combinations: - basic systemd, read-only, network w/ ifupdown - basic systemd, read-only, network w/ networkd - full systemd, read-only, network w/ networkd The tests just verify what the /sbin/init binary is, and that we were able to grab an IP address. More tests can be added later, for example to check each systemd features (journal, tmpfiles...) Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> [Arnout: regenerate .gitlab-ci.yml] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/testing: add runtime testing for init systemsYann E. MORIN2017-08-025-0/+228
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "builtin" kernel does not boot a systemd-based system, so we resort to building the same one as currently used by our qemu_arm_vexpress_defconfig. We test the 8 following combinations: - busybox, read-only, without network - busybox, read-only, with network - busybox, read-write, without network - busybox, read-write, with network - basic systemd, read-write, network w/ ifupdown - basic systemd, read-write, network w/ networkd - full systemd, read-write, network w/ networkd - no init system, read-only, without network The tests just verify what the /sbin/init binary is, and that we were able to grab an IP address. More tests can be added later, for example to check each systemd features (journal, tmpfiles...) Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Cc: Arnout Vandecappelle <arnout@mind.be> [Arnout: update .gitlab-ci.yml] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* testing/infra/emulator: remove qemu warnings about audioRicardo Martincoski2017-07-311-1/+2
| | | | | | | | | | | | | | | | | The default audio backend for qemu is configured at compile time. It generates annoying warning messages to qemu's stderr when running our tests, like these: pulseaudio: set_sink_input_volume() failed pulseaudio: Reason: Invalid argument pulseaudio: set_sink_input_mute() failed pulseaudio: Reason: Invalid argument Explicitly set the audio backend to "none" at runtime to remove those messages from our logs. There is no command line argument for this, so use an environment variable when starting qemu. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/config-fragments/autobuild: fix ARM internal fragmentThomas Petazzoni2017-07-291-1/+0
| | | | | | | | | | | | | | | | | The toolchain configuration used by the autobuilders to test the internal toolchain backend on ARM contains an option that no longer exists: BR2_UCLIBC_VERSION_NG. This option has been removed since uClibc-ng has been made the one and only uClibc version supported. Due to this option no longer existing, this toolchain configuration was in fact never used, because the randgenconfig script validates that a toolchain configuration is valid by checking that all lines are still present in the final .config. Therefore, this commit removes the bogus option, which will make sure this toolchain config gets used again by our autobuilders. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* toolchain-configs.csv: remove unused libc columnArnout Vandecappelle2017-07-251-52/+52
| | | | | | | | This column is not used by either genrandconfig or test-pkg, so remove it. Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
OpenPOWER on IntegriCloud