ci: remove using IDF_XTENSA_TOOLCHAIN_URL because there are idf_tools.json and multi-target support

This commit is contained in:
Anton Maklakov 2019-11-13 14:39:58 +07:00
parent f2ef0509e3
commit c5d20275dd
2 changed files with 1 additions and 31 deletions

View file

@ -33,14 +33,11 @@ variables:
IDF_SKIP_CHECK_SUBMODULES: 1
UNIT_TEST_BUILD_SYSTEM: cmake
# IDF environment
IDF_PATH: "$CI_PROJECT_DIR"
BATCH_BUILD: "1"
V: "0"
APPLY_BOT_FILTER_SCRIPT: "$CI_PROJECT_DIR/tools/ci/apply_bot_filter.py"
CHECKOUT_REF_SCRIPT: "$CI_PROJECT_DIR/tools/ci/checkout_project_ref.py"
CUSTOM_TOOLCHAIN_PATH: "/opt/xtensa-custom"
# Docker images
BOT_DOCKER_IMAGE_TAG: ":latest"
@ -53,25 +50,6 @@ variables:
.apply_bot_filter: &apply_bot_filter
python $APPLY_BOT_FILTER_SCRIPT || exit 0
.setup_custom_toolchain: &setup_custom_toolchain |
if [ "$IDF_XTENSA_TOOLCHAIN_URL" ] ; then
echo "Use a custom toolchain: ${IDF_XTENSA_TOOLCHAIN_URL:-Unknown}"
rm -rf "$CUSTOM_TOOLCHAIN_PATH" &&
mkdir -p -v "$CUSTOM_TOOLCHAIN_PATH" &&
pushd "$CUSTOM_TOOLCHAIN_PATH" &&
curl -sSL -o xtensa-custom.xxx "$IDF_XTENSA_TOOLCHAIN_URL" &&
ls -l xtensa-custom.xxx &&
tar xf xtensa-custom.xxx --strip-components 1 &&
ls -l . &&
popd
PATH=$CUSTOM_TOOLCHAIN_PATH/bin:$PATH
export PATH
fi
.cleanup_custom_toolchain: &cleanup_custom_toolchain |
echo "Cleaning up $CUSTOM_TOOLCHAIN_PATH"
rm -rf "$CUSTOM_TOOLCHAIN_PATH"
.setup_tools_unless_target_test: &setup_tools_unless_target_test |
if [ "$CI_JOB_STAGE" != "target_test" ]; then
tools/idf_tools.py --non-interactive install && eval "$(tools/idf_tools.py --non-interactive export)" || exit 1
@ -93,13 +71,10 @@ before_script:
- echo -e "Host gitlab.espressif.cn\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
# Set some options and environment for CI
- source tools/ci/configure_ci_environment.sh
- *setup_tools_unless_target_test
- *fetch_submodules
- *setup_custom_toolchain
# used for check scripts which we want to run unconditionally
.before_script_lesser_nofilter:
variables:
@ -108,7 +83,6 @@ before_script:
- echo "Not setting up GitLab key, not fetching submodules, not applying bot filter"
- source tools/ci/setup_python.sh
- source tools/ci/configure_ci_environment.sh
- *setup_custom_toolchain
# used for everything else where we want to do no prep, except for bot filter
.before_script_lesser:
@ -120,10 +94,6 @@ before_script:
# apply bot filter in before script
- *apply_bot_filter
- source tools/ci/configure_ci_environment.sh
- *setup_custom_toolchain
after_script:
- *cleanup_custom_toolchain
.check_job_template:
stage: check

View file

@ -191,7 +191,7 @@ test_idf_tools:
extends: .host_test_template
script:
# Remove Xtensa and ULP toolchains from the PATH, tests will expect a clean environment
- export PATH=$(p=$(echo $PATH | tr ":" "\n" | grep -v "/root/.espressif/tools\|/opt/espressif${CUSTOM_TOOLCHAIN_PATH:+\|${CUSTOM_TOOLCHAIN_PATH}}" | tr "\n" ":"); echo ${p%:})
- export PATH=$(p=$(echo $PATH | tr ":" "\n" | grep -v "/root/.espressif/tools\|/opt/espressif" | tr "\n" ":"); echo ${p%:})
- cd ${IDF_PATH}/tools/test_idf_tools
- ${IDF_PATH}/tools/ci/multirun_with_pyenv.sh ./test_idf_tools.py