aboutsummaryrefslogtreecommitdiff
path: root/support/dependencies
Commit message (Collapse)AuthorAgeFilesLines
* Config.in: drop BR2_NEEDS_HOST_{JAVAC,JAR}Gravatar Peter Korsgaard2020-03-031-8/+0
| | | | | | | With classpath removed, no packages select these symbols any more - So drop them and their corresponding logic in dependencies.sh / genrandconfig. Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* core/dependencies: check if we need to build our own host-coreutilsGravatar Yann E. MORIN2020-01-062-0/+18
| | | | | Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* package/pkg-utils.mk: rework implementation of extractor-system-dependencyGravatar Thomas Petazzoni2019-12-172-2/+0
| | | | | | | | | | | | | | Now that we have the EXTRACTOR_PKG_DEPENDENCY.* variables available, we can use them to implement extractor-system-dependency: if for a given archive type, the corresponding EXTRACTOR_PKG_DEPENDENCY.<type> variable is empty, then it means we need the corresponding extractor tool to be provided by the system. Following this, EXTRACTOR_DEPENDENCY_PRECHECKED_EXTENSIONS is no longer used, so we can drop it from support/dependencies/. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
* support/dependencies: set cmake version min to 3.10Gravatar James Hilliard2019-10-281-2/+2
| | | | | | | | This is required by wpewebkit and webkitgtk. Signed-off-by: James Hilliard <james.hilliard1@gmail.com> Reviewed-by: Adrian Perez de Castro <aperez@igalia.com> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
* docs/manual: bump our gcc/g++ requirements to 4.8Gravatar Yann E. MORIN2019-10-271-4/+4
| | | | | | | | | | | | | | | | | | | Currently, we only require a gcc 4.4 version, which now is pretty old (released in April 2009). This requirement is not even tested nowadays, with our oldest autobuilder having a 4.7 version only. And even then, 4.7 is still old enough that it prevents us from upgrading some packages. For example cmake 3.10+ requires C++11 constructs that were only added in gcc 4.8 (when C++11 support was finally completed in gcc). So, update our requirements for gcc to at least 4.8. Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Peter Korsgaard <peter@korsgaard.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/dependencies: don't check for python on the hostGravatar Yann E. MORIN2019-10-261-14/+1
| | | | | | | | | | | We no longer have anything that needs it during the build, so we don't require it anymore. Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Peter Korsgaard <peter@korsgaard.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/dependencies/dependencies.sh: check for JSON:PP Perl moduleGravatar Adrian Perez de Castro2019-09-171-0/+4
| | | | | | | | The JSON::PP Perl module is used at build time by the webkitgtk and wpewebkit packages. Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/dependencies: Add hint for ArchLinux when host needs IA32 libsGravatar Vadim Kochan2019-05-101-0/+1
| | | | | | | | Add hint about which package needs to be installed to provide IA32 libs support for the host when it is needed. Signed-off-by: Vadim Kochan <vadim4j@gmail.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/dependencies/dependencies.sh: simplify an error messageGravatar Markus Mayer2019-04-101-2/+1
| | | | | | | | | There is no need to break the "\n" sequence using "%sn". We can just escape it. Note: the escaping backslash needs to be escaped too, because the shell will process the string before printf gets to see it. Signed-off-by: Markus Mayer <mmayer@broadcom.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/dependencies: add a check for python3Gravatar Romain Naour2019-03-152-0/+39
| | | | | | | | | | | | | | | | | | | | Since version 2.29, glibc requires python 3.4 or later to build the GNU C Library [1]. We add a new check to verify the version of python3 interpreter installed on the host. If no suitable python3 interpreter is found, define BR2_PYTHON3_HOST_DEPENDENCY to add host-python3 in package dependencies when needed. [1] https://www.sourceware.org/ml/libc-alpha/2019-01/msg00723.html Signed-off-by: Romain Naour <romain.naour@gmail.com> Tested-by: Adam Duskett <aduskett@gmail.com> Reviewed-by: Adam Duskett <aduskett@gmail.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> [Thomas: drop not so useful comment in the .mk file, as suggested by Yann E. Morin.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/dependencies: require at least CMake 3.8Gravatar Fabrice Fontaine2019-03-011-8/+3
| | | | | | | | | | | | | | | | | gerbera package in version 1.3 unfortunately now requires CMake >= 3.8 for C++17 macros: https://github.com/gerbera/gerbera/commit/b5fd39f30fb10385ec228b71377685206a609c3a So we need to bump our requirement from 3.1 to 3.8. If the host doesn't have a CMake >= 3.8, Buildroot will build its own host-cmake package. Also drop patch that relax cmake requirement on json-for-modern-cpp Fixes: - http://autobuild.buildroot.org/results/6405647b47b132ff5d0d211b92d407322d52d507 Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* infra: add force build flag for host dependenciesGravatar Bryce Ferguson2019-02-041-0/+6
| | | | | | | | | | | | | | | This commit adds a config option which will force buildroot to build all host dependencies even if they are already present on the host system. This may be a desirable option if different hosts are used to build the same source. In this case, some packages will be built on one host that are not built on another. This is problematic if build source archives are cached afterwards for offline builds. Cc: Peter Korsgaard <peter@korsgaard.com> Signed-off-by: Bryce Ferguson <bryce.ferguson@rockwellcollins.com> Signed-off-by: Matt Weber <matthew.weber@rockwellcollins.com> [Peter: reword, drop exit 1, reshuffle] Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* dependencies.sh: Check for a host python version >= 2.7Gravatar Adam Duskett2019-02-041-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Older distributions such as CentOS6 come with python2.6, which causes build failures in packages such as host-libglib2 because they require python2.7 and above. host-libglib2 will produce the error message: /bin/sh: python2.7: command not found Python2.7 is a hard-coded value in configure.ac. If one changes the value to just "python," the following stack trace is produced: Traceback (most recent call last): File "./gdbus-2.0/codegen/gdbus-codegen.in", line 55, in <module> self.outfile.write(LICENSE_STR.format(config.VERSION)) ValueError : sys.exit(codegen_main.codegen_main()) zero length field name in format Instead of supporting an ancient version of Python that had its support ended in October os 2013, it would be more pragmatic only to support Python2.7 and above. Luckily; CentOS6 has the centos-release-scl repository, which allows users to install python2.7, and Debian 8 comes with Python2.7 already, making this patch relatively low impact. Signed-off-by: Adam Duskett <Aduskett@gmail.com> [Peter: only look at major.minor to handle x.y.z with z < 10] Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* Merge branch 'next'Gravatar Peter Korsgaard2018-12-023-4/+29
|\ | | | | | | Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
| * support/dependencies: add a check for a suitable gzipGravatar Yann E. MORIN2018-11-242-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recently, some hash mismatch have been reported, both by users as well as autobuilder failures, about tarballs generated from git repositories. This turned out to be caused by users having the 'gzip' command somehow aliased to 'pigz' (which stand for: parallel implementation of gzip, which takes advantage of multi-processor system to parallelise the compression). Unfortunately, the output of pigz-compressed archives differ from that of gzip (even though they *are* valid gzip-compressed streams). Add a dependency check that ensures that gzip is not pigz. If that is the case, define a conditional dependency to host-gzip, that is used as a download dependency for packages that will generate compressed files, i.e. cvs, git, and svn. Fixes: http://autobuild.buildroot.org/results/330/3308271fc641cadb59dbf1b5ee529a84f79e6d5c/ Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Peter Korsgaard <peter@korsgaard.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Marcin Niestrój <m.niestroj@grinn-global.com> Cc: Erico Nunes <nunes.erico@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/dependencies: treat BSD-tar like the other casesGravatar Yann E. MORIN2018-11-241-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, when we detect that tar is BSD-tar, we fake an unsupported version (major, minor) and rely on the version check to reject BSD-tar. There is no reason to use such shenanigans, when we can simply reject it from the onset. Simplify the logic: - use positive logic in the condition - directly exit in error Also, comment that case like the other cases are commented. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* | make: configure host-make with host- prefixGravatar Peter Korsgaard2018-11-201-2/+2
|/ | | | | | | | | | | | | | | | | | | | | Fixes: http://autobuild.buildroot.net/results/e29/e293aadc692d2ed337881ef2172ddf66a60bc05c/ And many more. Install as 'host-make' rather than just 'make', as that otherwise confuses a number of packages when they invoke recursive / sub-make. The internal job control logic of GNU make is version dependant, so mixing versions may lead to issues like: make[1]: Entering directory `/home/peko/autobuild/instance-0/output/build/boa-0.94.14rc21' (cd src && make -w --jobserver-fds=5,6 -j) make: unrecognized option '--jobserver-fds=5,6' With this rename, only packages explicitly opting in for our host-make (using the BR2_MAKE / BR2_MAKE_HOST_DEPENDENCY logic) will use it. Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* dependencies: host-make version checkGravatar Romain Naour2018-09-082-0/+58
| | | | | | | | | | | | | | | | | | | | | | | | The host make program is already checked by dependencies.sh but we want to check the version number even if Buildroot is able to use GNU make >= 3.81 but some packages may require a more recent version. For example, since version 2.28 [1], glibc requires GNU Make >= 4.0. For packages requiring make >= 4.0, the package makefile must use: <PKG>_DEPENDENCIES = $(BR2_MAKE_HOST_DEPENDENCY) ... <PKG>_MAKE = $(BR2_MAKE) BR2_MAKE1 is also available if needed. [1] https://www.sourceware.org/ml/libc-alpha/2018-08/msg00003.html Signed-off-by: Romain Naour <romain.naour@gmail.com> Cc: Baruch Siach <baruch@tkos.co.il> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Tested-by: Matt Weber <matthew.weber@rockwellcollins.com> [Thomas: remove extraction of "bugfix" part of the version, since it's not used anywhere.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/dependencies: check for system-provided bison and flexGravatar Yann E. MORIN2018-08-201-0/+10
| | | | | | | Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Arnout Vandecappelle <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/dependencies/dependencies.sh: add details for Redhat/FedoraGravatar David De Grave (Essensium/Mind)2018-07-021-0/+2
| | | | | | | | | Add the i686 package list to install when using pre-built 32 bits binaries with a redhat/fedora host distribution (glibc.i686 and zlib.i686). Signed-off-by: David De Grave (Essensium/Mind) <david.degrave@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* dependencies.sh: add perl autodie for whoisGravatar Fabrice Fontaine2018-06-051-0/+4
| | | | | | | | | | Add dependency on perl autodie if whois package is selected Fixes: - http://autobuild.buildroot.net/results/4d2ca14580cbc73f94e86ee834fac6d2541298ec Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/dependencies: check that PATH does not contain CWDGravatar Yann E. MORIN2018-05-091-36/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | A person on IRC reported a build failure with the util-linux package, looking like this: for I in uname26 linux32 linux64 ; do \ cd /home/aep/consulting/chargery/tracker/output/target/usr/bin && ln -sf setarch $I ; \ done [...] /bin/sh: line 1: ./ln: cannot execute binary file: Exec format error /bin/sh: line 1: ./ln: cannot execute binary file: Exec format error /bin/sh: line 1: ./ln: cannot execute binary file: Exec format error The issue was an empty path in the PATH variable, which means "current working directory", causing a "ln" binary built by util-linux for the target to be used instead of the system-provided "ln". We already check a number of things in the PATH and LD_LIBRARY_PATH variables in support/dependencies/dependencies.sh, but we were not checking that PATH did not contain an empty path. This commit fixes that and takes this opportunity to simplify the test code for PATH and LD_LIBRARY_PATH. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> [Thomas: improve commit log.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* check-host-tar.sh: bump minimum tar version to 1.27 for reproducible tar ↵Gravatar Peter Korsgaard2018-04-021-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | files with long paths Fixes: http://autobuild.buildroot.net/results/b18/b187e64a61918f17f69588e2355a03286bc5808e tar 1.27 subtly changed the tar format when a GNU long link entry is added (which is done for path elements > 100 characters). The code used to set the permission mode of the link entry to 0: header = start_private_header ("././@LongLink", size, time (NULL)); FILL (header->header.mtime, '0'); FILL (header->header.mode, '0'); FILL (header->header.uid, '0'); FILL (header->header.gid, '0'); FILL (header->header.devmajor, 0); FILL (header->header.devminor, 0); This got dropped in 1.27 by commit df7b55a8f6354e3 (Fix some problems with negative and out-of-range integers), so the settings from start_private_header() are used directly - Which are: TIME_TO_CHARS (t < 0 ? 0 : min (t, MAX_OCTAL_VAL (header->header.mtime)), header->header.mtime); MODE_TO_CHARS (S_IFREG|S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH, header->header.mode); UID_TO_CHARS (0, header->header.uid); GID_TO_CHARS (0, header->header.gid); The end result is that tar >= 1.27 sets mode to 644. The consequence of this is that we create different tar files when long path names are encountered (which often happens when a package downloads a specific sha1 from a git repo) depending on the host tar version used, causing hash mismatches. As a workaround, bump our minimum tar version to 1.27. It would be nicer to only do this if we have packages from bzr/git/hg enabled, but that is an exercise for later. Signed-off-by: Peter Korsgaard <peter@korsgaard.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* core: kill DEPENDENCIES_HOST_PREREQGravatar Thomas Petazzoni2018-03-251-8/+2
| | | | | | | | | Now that DEPENDENCIES_HOST_PREREQ is no longer used anywhere, we can kill it. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* package/pkg-generic: handle host-ccache as a regular dependencyGravatar Thomas Petazzoni2018-03-251-4/+0
| | | | | | | | | | | | | | | | | | This moves the host-ccache dependency handling from DEPENDENCIES_HOST_PREREQ to a proper package dependency. When BR2_CCACHE=y, we add host-ccache as a regular dependency of all packages except: - The extractor packages host-tar, host-xz and host-lzip - host-ccache itself - host-skeleton, because all packages depend on it Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Tested-by: Matt Weber <matthew.weber@rockwellcollins.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* package/pkg-generic: handle host-lzip as an extract dependencyGravatar Thomas Petazzoni2018-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This moves the host-lzip dependency handling from DEPENDENCY_HOST_PREREQ to an extract dependency. To achieve that, check-host-lzip.mk fills in the BR2_LZIP_HOST_DEPENDENCY with host-lzip if building a host-lzip is needed. The name BR2_LZIP_HOST_DEPENDENCY has been chosen because it matches the name BR2_CMAKE_HOST_DEPENDENCY already used in check-host-cmake.mk. The BR2_LZIP_HOST_DEPENDENCY is added to all packages, except: - host-lzip, because we would otherwise depend on ourself. - host-tar, because lzip itself is delivered as a tarball, so we need to have host-lzip depend on host-tar, and not host-tar depend on host-lzip - host-skeleton, because we need to have host-lzip depend on host-skeleton, and not the opposite. We also mutually exclude host-lzip and host-xz from dependending on each other, to avoid a circular dependency. In addition, we modify lzip.mk to explicitly build host-lzip without ccache. We generally took the approach of building host-ccache *after* all the extractors have been built. [Peter: fix s/host-tar/host-lzip/ typo, fix s/xz/lzip/ typo] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* package/pkg-generic: handle host-xz as an extract dependencyGravatar Thomas Petazzoni2018-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This moves the host-xz dependency handling from DEPENDENCY_HOST_PREREQ to an extract dependency. To achieve that, check-host-xz.mk fills in the BR2_XZ_HOST_DEPENDENCY with host-xz if building a host-xz is needed. The name BR2_XZ_HOST_DEPENDENCY has been chosen because it matches the name BR2_CMAKE_HOST_DEPENDENCY already used in check-host-cmake.mk. The BR2_XZ_HOST_DEPENDENCY is added to all packages, except: - host-xz, because we would otherwise depend on ourself. - host-tar, because xz itself is delivered as a tarball, so we need to have host-xz depend on host-tar, and not host-tar depend on host-xz - host-skeleton, because we need to have host-xz depend on host-skeleton, and not the opposite. In addition, we modify xz.mk to explicitly build host-xz without ccache. We generally took the approach of building host-ccache *after* all the extractors have been built. [Peter: fix s/host-tar/host-xz/ typo] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* package/pkg-generic: handle host-tar as an extract dependencyGravatar Thomas Petazzoni2018-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This moves the host-tar dependency handling from DEPENDENCY_HOST_PREREQ to an extract dependency. To achieve that, check-host-tar.mk fills in the BR2_TAR_HOST_DEPENDENCY variable with host-tar if building a host-tar is needed. The name BR2_TAR_HOST_DEPENDENCY has been chosen because it matches the name BR2_CMAKE_HOST_DEPENDENCY already used in check-host-cmake.mk. The BR2_TAR_HOST_DEPENDENCY is added to all packages, except host-tar itself (obviously) and host-skeleton, because we depend on host-skeleton to install host-tar properly in HOST_DIR. In addition, we modify tar.mk to explicitly build host-tar without ccache: since ccache source code is available as a tarball, ccache will obviously depend on host-tar if the system tar is insufficient. Finally, to make things really clean, we also add $(BR2_TAR_HOST_DEPENDENCY) to the dependencies of the tar filesystem format, since it requires tar, so we'd better make sure we have a suitable tar. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Tested-by: Matt Weber <matthew.weber@rockwellcollins.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* core: drop no-longer used C.UTF-8 locale optionGravatar Yann E. MORIN2018-03-041-13/+0
| | | | | | | | | | | | Its use has been globbed into the more generic BR2_NEEDS_HOST_UTF8_LOCALE option now. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Peter Korsgaard <peter@korsgaard.com> Cc: Julius Kriukas <julius@kriukas.lt> Cc: Christian Stewart <kidovate@gmail.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/dependencies: unbreak check for UTF-8 localeGravatar Yann E. MORIN2018-03-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Although the UTF-8 locales in mainstream distributions all are suffixed with just 'utf8', the nomenclature is a bit ambiguous with the way they are to be specified with the various LC_* variables, suffixed there with 'UTF-8'. Also, POSIX, ISO, and IEC do not enforce any specific suffix in LC_* variables: http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap08.html#tag_08_02 """ If the locale value has the form: language[_territory][.codeset] it refers to an implementation-provided locale, where settings of language, territory, and codeset are implementation-defined. """ To avoid any confusion, use a regexp that is a bit more lax when matching locales. Also, quote the regexp, so that the '?' and '$' are not interpreted by the shell. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Peter Korsgaard <peter@korsgaard.com> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/dependencies/dependencies.sh: check for Python argparse moduleGravatar Thomas Petazzoni2018-03-031-0/+5
| | | | | | | | | | | | | | | | | | | | | | The script support/scripts/check-uniq-files uses the argparse Python module. In most recent Python versions (starting with 2.7), the argparse module is part of the standard library, and we already check for the availability of Python in support/dependencies/dependencies.sh. However, when running on an ancient distribution with Python 2.6, the argparse module is not part of the Python standard library, but available as an external module. Without this module, the build fails, because check-uniq-files, which is used in target-finalize, fails to run. To avoid this failure, this commit adds a check in support/dependencies/dependencies.sh to verify that the argparse module is available. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* systemd: switch to C.UTF-8 locale when buildingGravatar Julius Kriukas2018-03-021-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | When BR2_REPRODUCIBLE is enabled or host uses non UTF-8 capable locale building systemd fails with an error: [1/1080] Generating systemd.bg.catalog with a meson_exe.py custom command. FAILED: catalog/systemd.bg.catalog /buildroot/output/host/bin/python3 /buildroot/output/host/bin/meson --internal exe /buildroot/output/build/systemd-236/build/meson-private/meson_exe_sed_232a0623cc7ce2cd67ec72ed784b76307102ed76.dat Warning: You are using 'ANSI_X3.4-1968' which is not a Unicode-compatible locale. You might see errors if you use UTF-8 strings as filenames, as strings, or as file contents. Please switch to a UTF-8 locale for your platform. ... UnicodeDecodeError: 'ascii' codec can't decode byte 0xd0 in position 1079: ordinal not in range(128) package/pkg-generic.mk:247: recipe for target '/buildroot/output/build/systemd-236/.stamp_built' failed make: *** [/buildroot/output/build/systemd-236/.stamp_built] Error 1 This patch changes default host system locale from C to C.UTF-8 when building systemd package to fix this issue. It also introduces BR2_NEEDS_HOST_C_UTF8_LOCALE flag that checks if this locale is available on the host system. If locale is not available error message is show and build process is stopped. Signed-off-by: Julius Kriukas <julius@kriukas.lt> [Thomas: use C.UTF-8 instead of en_US.UTF-8.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* check-host-tar.sh: blacklist tar 1.30+Gravatar Peter Korsgaard2018-02-271-9/+24
| | | | | | | | | | | | | | | Tar 1.30 changed the --numeric-owner output for filenames > 100 characters, leading to hash mismatches for the tar archives we create ourselves from git. This is really a fix for a bug in earlier tar versions regarding deterministic output, so it is unlikely to be reverted in later versions. For more details, see: http://lists.busybox.net/pipermail/buildroot/2018-January/211222.html To work around this issue, blacklist tar 1.30+ similar to how we do it for pre-1.17 versions so Buildroot falls back to building host-tar. Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* dependencies.mk: check for valid host-tar before other host dependenciesGravatar Peter Korsgaard2018-02-271-1/+4
| | | | | | | | | | | | | | | | | | host-{cmake,lzip,xz} needs host-tar to extract their source code tarball, so we need to ensure that host-tar gets added to DEPENDENCIES_HOST_PREREQ before these in case they are both needed, otherwise the tools will fail to extract. With the upcoming change to blacklist modern tar versions this situation is likely to trigger more often. The real solution to this issue is the <foo>_EXTRACT_DEPENDENCIES rework, but that series is a bit too intrusive to add this close to 2018.02, so therefore this hack. Signed-off-by: Peter Korsgaard <peter@korsgaard.com> Reviewed-by: Matt Weber <matthew.weber@rockwellcollins.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/dependencies: add check for c++ multilibGravatar Gaël PORTAY2018-02-061-0/+8
| | | | | | | | | | | | Some packages build C++ 32bits host-tools and need the g++-multilib to be installed on the build machine. As example, qt5webengine builds a C++ host-tool when target is 32bits. Add the check for g++-multilib to the dependencies script; and update the Dockerfile to install g++-multilib package. Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* dependencies: correct dependencies for top-level parallel buildGravatar Arnout 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 HOSTCCGravatar Arnout 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>
* dependencies: always use HOSTCC_NOCACHE for DEPENDENCIES_HOST_PREREQGravatar Alfredo 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>
* Globally replace $(HOST_DIR)/usr/bin with $(HOST_DIR)/binGravatar Arnout Vandecappelle2017-07-054-4/+4
| | | | | | | | | | | Since things are no longer installed in $(HOST_DIR)/usr, the callers should also not refer to it. This is a mechanical change with git grep -l '$(HOST_DIR)/usr/bin' | xargs sed -i 's%$(HOST_DIR)/usr/bin%$(HOST_DIR)/bin%g' Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* core: add "cmake3" to the list of cmake candidatesGravatar Carlos Santos2017-06-241-1/+1
| | | | | | | | | This is useful on CentOS 7, whose "cmake" utility corresponds to version 2.8.12, which is too old for Buildroot. Signed-off-by: Carlos Santos <casantos@datacom.ind.br> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* core: allow having a list of "cmake" candidatesGravatar Carlos Santos2017-06-241-3/+4
| | | | | | | | | | | | | | Add the BR2_CMAKE_CANDIDATES variable, containing a list of candidates to check and use as BR2_CMAKE, if possible. This allows using "cmake3" on CentOS 7, whose default cmake corresponds to version 2.8.12. Example: $ make BR2_CMAKE_CANDIDATES="cmake cmake3" Signed-off-by: Carlos Santos <casantos@datacom.ind.br> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* core: allow check-host-cmake.sh to try several candidatesGravatar Carlos Santos2017-06-241-35/+41
| | | | | | | | | | | | | | | | | | | This is useful on CentOS 7 whose "cmake" package provides cmake 2.8.12, which is too old, but the "cmake3" package (from EPEL) provides version 3.6.3, which is satisfactory. Examples: $ sh support/dependencies/check-host-cmake.sh 2.8 cmake cmake3 /usr/bin/cmake $ sh support/dependencies/check-host-cmake.sh 3.1 cmake cmake3 /usr/bin/cmake3 $ sh support/dependencies/check-host-cmake.sh 3.8 cmake cmake3 (nothing) Signed-off-by: Carlos Santos <casantos@datacom.ind.br> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* core: reverse the argument order in check-host-cmakeGravatar Carlos Santos2017-06-242-3/+3
| | | | | | | | | Pass the minimal version before the program name. In a later change the script will become able to test a list of candidates. Signed-off-by: Carlos Santos <casantos@datacom.ind.br> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/dependencies: check PATH does not carry a \nGravatar Yann E. MORIN2017-06-081-0/+12
| | | | | | | | | | | | | | | | ... otherwise it fails spectacularly as soon as PATH is referenced in a package rule (i.e. very soon, fortunately): >>> host-lzip 1.18 Downloading /bin/bash: -c: line 0: unexpected EOF while looking for matching `"' /bin/bash: -c: line 1: syntax error: unexpected end of file Fixes # 9886. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Ciro Santilli <ciro.santilli@gmail.com> [Thomas: fix typo in message, use tabs for indentation.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* Revert "dependencies/cmake: blacklist cmake 3.7"Gravatar Yann E. MORIN2017-03-011-8/+0
| | | | | | | | | | This reverts commit 4422eca2d418e2b817b419ff6c4c62f7f4cb7871. We now have a workaround for the RPATH issue introduced in 3.7, so we can use it again. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* dependencies/cmake: blacklist cmake 3.7Gravatar Yann E. MORIN2017-02-281-0/+8
| | | | | | | | | | | | | | | | | cmake-3.7 has a bug in how it handles rpath, linking with libraries from the host. Until we completely understand the issue, just blacklist cmake-3.7. The issue has been reported upstream: http://public.kitware.com/pipermail/cmake/2017-February/064970.html Reported-by: Baruch Siach <baruch@tkos.co.il> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Jörg Krause <joerg.krause@embedded.rocks> Cc: Ben Boeckel <mathstuf@gmail.com> Cc: Samuel Martin <s.martin49@gmail.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* package: add generic support for lz archivesGravatar Baruch Siach2017-02-152-0/+19
| | | | | | | | | | This commit teaches the generic package handling code how to extract .tar.lz archives. When lzip is not installed on the host, host-lzip gets built automatically. Signed-off-by: Baruch Siach <baruch@tkos.co.il> Reviewed-by: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* package: refactor listing of extractor dependenciesGravatar Baruch Siach2017-02-151-0/+1
| | | | | | | | | | | | | | | Don't special case $(XZCAT) when constructing DL_TOOLS_DEPENDENCIES. The next commit will introduce another extractor that automatically builds when not installed. Introduce EXTRACTOR_DEPENDENCY_PRECHECKED_EXTENSIONS that lists archive extensions for which the extractor is already checked in support/dependencies/check-host-foo.mk. Use this in the newly introduced extractor-dependency to populate DL_TOOLS_DEPENDENCIES. Cc: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com> Signed-off-by: Baruch Siach <baruch@tkos.co.il> Reviewed-by: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com> [Thomas: add missing space after "firstword", as noticed by Thomas DS.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* core: do not reset DEPENDENCIES_HOST_PREREQ in dependencies.mkGravatar Jérôme Pouiller2017-01-281-2/+0
| | | | | | | | Usually, Buildroot does never initialize variables with empty content. DEPENDENCIES_HOST_PREREQ was an unjustified exception. Signed-off-by: Jérôme Pouiller <jezz@sysmic.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* support/dependencies: ensure we have 'file' on the hostGravatar Yann E. MORIN2016-12-271-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recently, the autoconf macros for libtool started using '/usr/bin/file' to determine the type of library that is generated by the toolchain. Packages that use this recent version of the libtool autoconf macros will fail in a rather dramatic way when /usr/bin/file is not present on the host: the package will still build but no shared library is generated, which in turn may cause build failures in other packages that link with it. For example, libpng's configure determines that it is not possible to build a shared library on MIPS64 because the expected output from 'file' is not present. Therefore, only a static libpng.a is built. Later, bandwithd links with -lpng but it doesn't use the pkg-config's Private-Libs (because it's not linking statically) and it doesn't have access to the NEEDED reference from the shared library. Therefore, it doesn't link with zlib and fails with pngrutil.c:(.text+0x55c): undefined reference to `inflate' We cant use host-file because it is itself an autotools package and is itself using libtool, so this would be a chicken-n-egg problem. Besides, the libtool script really wants to call /usr/bin/file, so it would not even find our host-file anyway. So, just require that '/usr/bin/file' is present on the host. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Baruch Siach <baruch@tkos.co.il> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>