test-pkg: get configs from in-tree toolchain-configs.csv
Now we have the toolchain config fragments in the buildroot directory itself, it is no longer necessary to fetch it from the toolchain URL. Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Cc: Yann E. MORIN <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
This commit is contained in:
parent
ff10c72920
commit
e7b9afa70a
@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
TOOLCHAINS_URL='http://autobuild.buildroot.org/toolchains/configs/toolchain-configs.csv'
|
TOOLCHAINS_CSV='support/config-fragments/autobuild/toolchain-configs.csv'
|
||||||
|
|
||||||
main() {
|
main() {
|
||||||
local o O opts
|
local o O opts
|
||||||
@ -50,8 +50,7 @@ main() {
|
|||||||
# Extract the URLs of the toolchains; drop internal toolchains
|
# Extract the URLs of the toolchains; drop internal toolchains
|
||||||
# E.g.: http://server/path/to/name.config,arch,libc
|
# E.g.: http://server/path/to/name.config,arch,libc
|
||||||
# --> http://server/path/to/name.config
|
# --> http://server/path/to/name.config
|
||||||
toolchains=($(curl -s "${TOOLCHAINS_URL}" \
|
toolchains=($(sed -r -e 's/,.*//; /internal/d;' "${TOOLCHAINS_CSV}" \
|
||||||
|sed -r -e 's/,.*//; /internal/d;' \
|
|
||||||
|if [ ${random} -gt 0 ]; then \
|
|if [ ${random} -gt 0 ]; then \
|
||||||
sort -R |head -n ${random}
|
sort -R |head -n ${random}
|
||||||
else
|
else
|
||||||
@ -71,7 +70,6 @@ main() {
|
|||||||
nb_legal=0
|
nb_legal=0
|
||||||
for toolchainconfig in "${toolchains[@]}"; do
|
for toolchainconfig in "${toolchains[@]}"; do
|
||||||
: $((nb++))
|
: $((nb++))
|
||||||
# Using basename(1) on a URL works nicely
|
|
||||||
toolchain="$(basename "${toolchainconfig}" .config)"
|
toolchain="$(basename "${toolchainconfig}" .config)"
|
||||||
build_dir="${dir}/${toolchain}"
|
build_dir="${dir}/${toolchain}"
|
||||||
printf "%40s [%*d/%d]: " "${toolchain}" ${#nb_tc} ${nb} ${nb_tc}
|
printf "%40s [%*d/%d]: " "${toolchain}" ${#nb_tc} ${nb} ${nb_tc}
|
||||||
@ -90,17 +88,13 @@ main() {
|
|||||||
|
|
||||||
build_one() {
|
build_one() {
|
||||||
local dir="${1}"
|
local dir="${1}"
|
||||||
local url="${2}"
|
local toolchainconfig="${2}"
|
||||||
local cfg="${3}"
|
local cfg="${3}"
|
||||||
local pkg="${4}"
|
local pkg="${4}"
|
||||||
|
|
||||||
mkdir -p "${dir}"
|
mkdir -p "${dir}"
|
||||||
|
|
||||||
if ! curl -s "${url}" >"${dir}/.config"; then
|
cat "${toolchainconfig}" "support/config-fragments/minimal.config" "${cfg}" >>"${dir}/.config"
|
||||||
return 2
|
|
||||||
fi
|
|
||||||
|
|
||||||
cat "support/config-fragments/minimal.config" "${cfg}" >>"${dir}/.config"
|
|
||||||
|
|
||||||
if ! make O="${dir}" olddefconfig > "${dir}/logfile" 2>&1; then
|
if ! make O="${dir}" olddefconfig > "${dir}/logfile" 2>&1; then
|
||||||
return 2
|
return 2
|
||||||
|
Loading…
Reference in New Issue
Block a user