From b7a42e9974a25cbe5c4dc76d0e570fb1da9e5167 Mon Sep 17 00:00:00 2001 From: Tadej Novak Date: Fri, 28 Jan 2022 21:01:43 +0100 Subject: [PATCH] Remove obsolete CI configurations (#219) --- appveyor.yml | 88 ---- circle.yml | 766 ---------------------------------- cloudformation/ci.template.js | 117 ------ platform/android/circle.yml | 371 ---------------- platform/ios/circle.yml | 544 ------------------------ platform/ios/codecov.yml | 9 - 6 files changed, 1895 deletions(-) delete mode 100644 appveyor.yml delete mode 100644 circle.yml delete mode 100644 cloudformation/ci.template.js delete mode 100644 platform/android/circle.yml delete mode 100644 platform/ios/circle.yml delete mode 100644 platform/ios/codecov.yml diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index 16e712709..000000000 --- a/appveyor.yml +++ /dev/null @@ -1,88 +0,0 @@ -platform: x64 - -image: -- Visual Studio 2015 -- Visual Studio 2017 - -environment: - PYTHON: C:\python37 - - matrix: - - configuration: Release - - configuration: Debug - -test: off - -clone_depth: 1 - -for: -- - matrix: - only: - - image: Visual Studio 2015 - - environment: - LLVM_VERSION: 5.0.1 - LLVM_HASH: 981543611D719624ACB29A2CFFD6A479CFF36E8AB5EE8A57D8ECA4F9C4C6956F - VCVARSALL: 'C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat' - QT_PREFIX: 'C:\Qt\latest\msvc2015_64\lib\cmake' - -- - matrix: - only: - - image: Visual Studio 2017 - - environment: - LLVM_VERSION: 7.0.0 - LLVM_HASH: 74b197a3959b0408adf0824be01db8dddfa2f9a967f4085af3fad900ed5fdbf6 - VCVARSALL: 'C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat' - QT_PREFIX: 'C:\Qt\latest\msvc2017_64\lib\cmake' - -cache: - - '%APPVEYOR_BUILD_FOLDER%\.git\modules' - - '%APPVEYOR_BUILD_FOLDER%\LLVM-%LLVM_VERSION%-win64.exe' - - '%APPVEYOR_BUILD_FOLDER%\cmake-3.10.1-win64-x64.zip' - - C:\clcache - -install: - - set PATH=%PYTHON%\Scripts;%PYTHON%;%PATH% - - pip install clcache - - git config --system core.longpaths true - - git submodule sync - - git submodule update --init - - git submodule foreach git submodule update --init - - ps: | - if (!(Test-Path "LLVM-$env:LLVM_VERSION-win64.exe")) { - appveyor DownloadFile "https://releases.llvm.org/$env:LLVM_VERSION/LLVM-$env:LLVM_VERSION-win64.exe" - } - scripts\check-sha256.ps1 LLVM-$env:LLVM_VERSION-win64.exe "$env:LLVM_HASH" - Start-Process -FilePath "LLVM-$env:LLVM_VERSION-win64.exe" -ArgumentList '/S',"/D=C:\LLVM-$env:LLVM_VERSION" -Wait - - ps: | - if (!(Test-Path cmake-3.10.1-win64-x64.zip)) { - appveyor DownloadFile https://cmake.org/files/v3.10/cmake-3.10.1-win64-x64.zip - } - scripts\check-sha256.ps1 cmake-3.10.1-win64-x64.zip 8251F70C85B58F3CA1F24E4A3B0637E2D609B5E4A341D00B70E02E89244D5029 - Start-Process -FilePath '7z' -ArgumentList 'x','cmake-3.10.1-win64-x64.zip','-oC:\' -Wait - -before_build: - - set PATH=C:\LLVM-%LLVM_VERSION%\bin;%PATH% - - set PATH=C:\cmake-3.10.1-win64-x64\bin;%PATH% - - set CLCACHE_DIR=c:\clcache - - set CLCACHE_CL=clang-cl - - clcache -z - - set CC=clcache - - set CXX=clcache - - set CTEST_OUTPUT_ON_FAILURE=1 - - mkdir %APPVEYOR_BUILD_FOLDER%\build - - cd %APPVEYOR_BUILD_FOLDER%\build - -build_script: - - call "%VCVARSALL%" amd64 - - cmake -G "Ninja" - -DCMAKE_BUILD_TYPE=%CONFIGURATION% - -DCMAKE_MAKE_PROGRAM="%APPVEYOR_BUILD_FOLDER%\platform\qt\ninja.exe" - -DCMAKE_PREFIX_PATH=%QT_PREFIX% - -DMBGL_WITH_QT=ON - .. - - cmake --build . --target qmapboxgl -- -j %NUMBER_OF_PROCESSORS% - - clcache -s diff --git a/circle.yml b/circle.yml deleted file mode 100644 index 62f9963b9..000000000 --- a/circle.yml +++ /dev/null @@ -1,766 +0,0 @@ -version: 2.1 - -# -# This CI configuration heavily relies on templates and CMake. Most of the -# jobs will have the following steps (usually configurable via parameters): -# prepare, build and test. -# -# 'sanity-checks' and 'baselines' are special. The former will run a series -# of checks to see if the patch has the minimum requirements for landing in -# our repository and the latter will generate new baselines for the tests -# in case the PR changes the baselines. -# -workflows: - version: 2 - development: - jobs: - - sanity-checks - - build-template: - name: android-armeabi-v7a-release - executor_name: ubuntu-eoan - target_is_android: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_INSTALL_PREFIX=/tmp/workspace/install/$CIRCLE_JOB -DCMAKE_TOOLCHAIN_FILE=/opt/android/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_CCACHE=/usr/bin/ccache -DANDROID_ABI=armeabi-v7a' - install: true - - build-template: - name: android-arm64-v8a-release - executor_name: ubuntu-eoan - target_is_android: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_INSTALL_PREFIX=/tmp/workspace/install/$CIRCLE_JOB -DCMAKE_TOOLCHAIN_FILE=/opt/android/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_CCACHE=/usr/bin/ccache -DANDROID_ABI=arm64-v8a' - build_params: '--target libmbgl-render-test-runner.so' - install: true - - build-template: - name: android-x86-release - executor_name: ubuntu-eoan - target_is_android: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_INSTALL_PREFIX=/tmp/workspace/install/$CIRCLE_JOB -DCMAKE_TOOLCHAIN_FILE=/opt/android/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_CCACHE=/usr/bin/ccache -DANDROID_ABI=x86' - build_params: '--target libmbgl-render-test-runner.so' - install: true - - build-template: - name: android-x86_64-release - executor_name: ubuntu-eoan - target_is_android: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_INSTALL_PREFIX=/tmp/workspace/install/$CIRCLE_JOB -DCMAKE_TOOLCHAIN_FILE=/opt/android/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_CCACHE=/usr/bin/ccache -DANDROID_ABI=x86_64' - build_params: '--target libmbgl-render-test-runner.so' - install: true - - build-template: - name: linux-gcc8-release - executor_name: ubuntu-eoan - target_is_linux: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_INSTALL_PREFIX=/tmp/workspace/install/$CIRCLE_JOB -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=gcc-8 -DCMAKE_CXX_COMPILER=g++-8' - install: true - metrics: true - style_tests: true - - build-template: - name: linux-gcc5-release - executor_name: ubuntu-eoan - target_is_linux: true - requires: - - linux-gcc8-release - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=gcc-5 -DCMAKE_CXX_COMPILER=g++-5' - build_params: '--target mbgl-glfw' - test_params: '-N -Q' - - build-template: - name: linux-gcc8-debug-coverage - executor_name: ubuntu-eoan - target_is_linux: true - requires: - - linux-gcc8-release - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=gcc-8 -DCMAKE_CXX_COMPILER=g++-8 -DCMAKE_BUILD_TYPE=Debug -DMBGL_WITH_COVERAGE=ON' - style_tests: true - upload_coverage: true - - build-template: - name: linux-clang8-release - executor_name: ubuntu-eoan - target_is_linux: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_INSTALL_PREFIX=/tmp/workspace/install/$CIRCLE_JOB -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=clang-8 -DCMAKE_CXX_COMPILER=clang++-8' - install: true - metrics: true - style_tests: true - - build-template: - name: FIXME-linux-asan - executor_name: ubuntu-eoan - target_is_linux: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=clang-8 -DCMAKE_CXX_COMPILER=clang++-8 -DMBGL_WITH_SANITIZER=address' - test_params: '|| true' - style_tests: true - - build-template: - name: linux-tsan - executor_name: ubuntu-eoan - target_is_linux: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=clang-8 -DCMAKE_CXX_COMPILER=clang++-8 -DMBGL_WITH_SANITIZER=thread' - style_tests: true - - build-template: - name: FIXME-linux-valgrind - executor_name: ubuntu-eoan - target_is_linux: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=clang-8 -DCMAKE_CXX_COMPILER=clang++-8 -DCMAKE_CXX_FLAGS=-DSANITIZE' - test_params: '-j 4 -E "mbgl-node|gl-benchmark" -D ExperimentalMemCheck || true' - - build-template: - name: linux-ubsan - executor_name: ubuntu-eoan - target_is_linux: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=clang-8 -DCMAKE_CXX_COMPILER=clang++-8 -DMBGL_WITH_SANITIZER=undefined' - style_tests: true - - build-template: - name: qt5-linux-gcc5-release - executor_name: ubuntu-eoan - target_is_linux: true - requires: - - sanity-checks - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=gcc-5 -DCMAKE_CXX_COMPILER=g++-5 -DMBGL_WITH_QT=ON' - - build-template: - name: qt5-macos-gcc5-release - executor_name: macos-11_1_0 - target_is_macos: true - requires: - - linux-gcc8-release - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DMBGL_WITH_QT=ON -DCMAKE_PREFIX_PATH=$(echo /usr/local/Cellar/qt/5.*/lib/cmake)' - - build-template: - name: macos-xcode11-release - executor_name: macos-11_1_0 - target_is_macos: true - requires: - - linux-gcc8-release - config_params: '-G Ninja -DCMAKE_INSTALL_PREFIX=/tmp/workspace/install/$CIRCLE_JOB -DCMAKE_CXX_COMPILER_LAUNCHER=ccache' - install: true - metrics: true - style_tests: true - - build-template: - name: macos-xcode11-debug - executor_name: macos-11_1_0 - target_is_macos: true - requires: - - macos-xcode11-release - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_BUILD_TYPE=Debug -DMBGL_WITH_COVERAGE=ON' - style_tests: true - upload_coverage: true - - build-template: - name: ios-xcode11-release - executor_name: macos-11_3_1 - target_is_macos: true - requires: - - linux-gcc8-release - config_params: '-G Xcode -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_ARCHITECTURES=arm64e -DCMAKE_OSX_SYSROOT=iphoneos -DMBGL_WITH_IOS_CCACHE=ON' - build_params: '--config Release' - - android-render-test-runner: - requires: - - linux-gcc8-release -# - android-unit-test-runner: -# requires: -# - linux-gcc8-release - - ios-render-test-runner: - requires: - - linux-gcc8-release - - ios-unit-test-runner: - requires: - - linux-gcc8-release - - baselines: - requires: - - android-arm64-v8a-release - - android-armeabi-v7a-release - - android-render-test-runner - - android-x86-release - - android-x86_64-release - - linux-clang8-release - - linux-gcc8-release - - macos-xcode11-release - - ios-render-test-runner - - trigger-pipeline: - requires: - - baselines - name: mapboxci - slug: mapbox/mapbox-gl-native-internal - - android-api-breakage: - requires: - - baselines - nightly: - triggers: - - schedule: - cron: "0 5 * * *" - filters: - branches: - only: - - master - jobs: - - build-template: - name: linux-gcc8-debug-coverage-nightly - executor_name: ubuntu-eoan - target_is_linux: true - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=gcc-8 -DCMAKE_CXX_COMPILER=g++-8 -DCMAKE_BUILD_TYPE=Debug -DMBGL_WITH_COVERAGE=ON' - style_tests: true - upload_coverage: true - - build-template: - name: macos-xcode11-debug-coverage-nightly - executor_name: macos-11_1_0 - target_is_macos: true - requires: - - linux-gcc8-debug-coverage-nightly - config_params: '-G Ninja -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_BUILD_TYPE=Debug -DMBGL_WITH_COVERAGE=ON' - style_tests: true - upload_coverage: true - publish_coverage: true - -# -# Executors: we currently support two executors, one based on Ubuntu 19.04 aka Disco -# and another based on macOS + Xcode 11.1.0. The Ubuntu executor is a lot more stable -# and will produce reproduceable builds completely offline because it uses a docker -# image with all the build dependencies preinstalled, whereas the macOS is managed -# by CircleCI and will install dependencies on build time. Build results from the macOS -# bots might differ if in meantime the macOS image gets updated. :-( -# -executors: - ubuntu-eoan: - docker: - # FIXME: Move the image to mbgl/ - - image: tmpsantos/mbgl_ci:1.9 - resource_class: xlarge - working_directory: /src - environment: - DISPLAY: :99 - UBSAN_OPTIONS: print_stacktrace=1:halt_on_error=1:report_error_type=1 - ASAN_OPTIONS: strict_string_checks=1:detect_stack_use_after_return=1:check_initialization_order=1:strict_init_order=1:halt_on_error=0 - QT_INSTALL_DOCS: /usr/share/qt5/doc - QT_VERSION: 5 - TSAN_OPTIONS: suppressions=/src/platform/linux/tsan_suppress.txt - macos-11_1_0: - macos: - xcode: '11.1.0' - environment: - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - macos-11_3_1: - macos: - xcode: '11.3.1' - environment: - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - -commands: - prepare: - steps: - - restore_cache: - keys: - - 'ccache-v1-{{ .Environment.CIRCLE_JOB }}-{{ .Branch }}-{{ .Revision }}' - - 'ccache-v1-{{ .Environment.CIRCLE_JOB }}-{{ .Branch }}-' - - 'ccache-v1-{{ .Environment.CIRCLE_JOB }}-master' - - run: - name: Prepare - command: | - git submodule sync - git submodule update --init --recursive - git gc - npm install --ignore-scripts - ulimit -c unlimited - prepare-linux: - steps: - - run: - name: Prepare Linux - background: true - command: | - Xvfb :99 -noreset -screen 0 1280x1024x24 - prepare-macos: - steps: - - run: - name: Prepare macOS - command: | - brew install cmake ccache glfw ninja pkgconfig qt chargepoint/xcparse/xcparse - brew cask install google-cloud-sdk - pip install ansi2html scipy - config: - parameters: - config_params: - type: string - steps: - - run: - name: Configure - command: | - cmake . -B build << parameters.config_params >> - build: - parameters: - build_params: - type: string - steps: - - run: - name: Build - command: | - ccache --zero-stats --max-size=2G - cmake --build build -j $(nproc 2>/dev/null || sysctl -n hw.ncpu 2>/dev/null) << parameters.build_params >> - ccache --show-stats - install: - steps: - - run: - name: Install - command: | - cmake --build build --target install/strip - test: - parameters: - test_params: - type: string - steps: - - run: - name: Test - command: | - cd build - ctest -V << parameters.test_params >> - metrics: - parameters: - step_name: - type: string - metrics_params: - type: string - steps: - - run: - name: << parameters.step_name >> - command: | - build/mbgl-render-test-runner << parameters.metrics_params >> - save: - steps: - - save_cache: - key: 'ccache-v1-{{ .Environment.CIRCLE_JOB }}-{{ .Branch }}-{{ .Revision }}' - paths: - - .git/modules - - /Users/distiller/Library/Caches/Homebrew - - node_modules - - ~/.ccache - - ~/.gradle - - run: - name: Collecting results - when: always - command: | - mkdir -p /tmp/workspace/metrics && touch /tmp/workspace/.$CIRCLE_JOB - if [ -d metrics/$CIRCLE_JOB ]; then cp -r metrics/$CIRCLE_JOB /tmp/workspace/metrics; fi - mkdir -p /tmp/tests/baselines - if [ -f baselines.patch ]; then cp baselines.patch /tmp/tests/baselines; fi - mkdir -p /tmp/tests/nitpick - if [ -f nitpick.patch ]; then cp nitpick.patch /tmp/tests/nitpick; fi - mkdir -p /tmp/tests/render - if [ -f clang-tidy.log ]; then cp clang-tidy.log /tmp/tests/clang-tidy; fi - mkdir -p /tmp/tests/render - if ls render-test/*.html 1> /dev/null 2>&1; then cp render-test/*.html /tmp/tests/render; fi - mkdir -p /tmp/tests/metrics - if ls metrics/*.html 1> /dev/null 2>&1; then cp metrics/*.html /tmp/tests/metrics; fi - mkdir -p /tmp/tests/coredumps - if ls core* 1> /dev/null 2>&1; then cp core* /tmp/tests/coredumps; fi - mkdir -p /tmp/tests/valgrind - if ls build/Testing/Temporary/MemoryChecker.*.log 1> /dev/null 2>&1; then cp build/Testing/Temporary/MemoryChecker.*.log /tmp/tests/valgrind; fi - - persist_to_workspace: - root: /tmp/workspace - paths: - - '*' - - store_artifacts: - path: /tmp/tests - destination: tests - login-google-cloud-platform: - steps: - - run: - name: Login Google Cloud Platform - command: | - echo "${GCLOUD_SERVICE_ACCOUNT_JSON}" > secret.json - gcloud auth activate-service-account --key-file secret.json --project android-gl-native - rm secret.json - login-google-cloud-platform-ios: - steps: - - run: - name: Login to IOS Google Cloud Platform - command: | - if [[ -n "${GCLOUD_SERVICE_ACCOUNT_JSON_IOS}" ]]; then - echo "${GCLOUD_SERVICE_ACCOUNT_JSON_IOS}" > iosAccount.json - gcloud auth activate-service-account --key-file iosAccount.json --project ios-mapbox-gl-native - rm iosAccount.json - fi - prepare-ios-codesign-keychain: - parameters: - directory: - type: string - steps: - - run: - name: Prepare codesign keychain - command: | - cd << parameters.directory >> - fastlane run create_keychain name:fastlane_keychain password:$FASTLANE_PASSWORD timeout:false unlock:true - fastlane match - security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k $FASTLANE_PASSWORD fastlane_keychain - codesign-ios-test-runner: - parameters: - directory: - type: string - steps: - - run: - name: Codesign iOS TestApp for running on a physical device - command: | - cp -r << parameters.directory >>/codesigning build - cd build - ./codesigning/generate-entitlements.swift - ./codesigning/codesign_all.sh - codesign -dv --verbose=4 Release-iphoneos/*.app # for debugging that app is signed or not - run-ios-test-app: - parameters: - directory: - type: string - steps: - - run: - name: Run iOS Test App on Firebase - no_output_timeout: 30m - command: | - if [[ -n "${GCLOUD_SERVICE_ACCOUNT_JSON_IOS}" ]]; then - # arrange files in a way Firebase expects it, and package them in a zip file - cp << parameters.directory >>/*_iphoneos13.2-arm64e-release.xctestrun build - cd build - zip testapp.zip -r Release-iphoneos/*.app --quiet - zip testapp.zip *_iphoneos13.2-arm64e-release.xctestrun - gcloud firebase test ios models list - gcloud firebase test ios run \ - --test testapp.zip \ - --device model=iphone11,version=13.3,locale=en,orientation=portrait --xcode-version=11.3.1 --timeout 30m \ - --verbosity=debug --no-record-video --results-dir ios-test-app-${CIRCLE_BUILD_NUM} - fi - upload-coverage-results: - steps: - - run: - name: Get coverage results - command: | - cd build - find . -type f -iname *.gcda -exec gcov -p -b {} \; - - run: - name: Upload coverage results to codecov.io - command: | - bash <(curl -sSfL https://codecov.io/bash) -X gcov || echo 'Codecov failed to upload' - publish-coverage-metrics: - steps: - - run: - name: Upload coverage metrics to s3 - command: | - if [[ $CIRCLE_BRANCH == master ]]; then - scripts/publish_core_codecoverage.js -p Linux -s Core - fi - -jobs: - ios-render-test-runner: - executor: macos-11_3_1 - steps: - - checkout - - prepare - - prepare-macos - - prepare-ios-codesign-keychain: - directory: render-test/ios - - config: - config_params: '-G Xcode -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphoneos -DMBGL_IOS_RENDER_TEST=ON -DCMAKE_OSX_ARCHITECTURES=arm64e -DMBGL_WITH_IOS_CCACHE=ON' - - build: - build_params: '--config Release' - - codesign-ios-test-runner: - directory: render-test/ios - - login-google-cloud-platform-ios - - run-ios-test-app: - directory: render-test/ios - - run: - name: Retrieve Test Result from gcloud - when: always - command: | - if [[ -n "${GCLOUD_SERVICE_ACCOUNT_JSON_IOS}" ]]; then - testResult=$(gsutil ls -d gs://test-lab-hn7kwqcz3108z-hjm4qtbqqkymk/ios-test-app-${CIRCLE_BUILD_NUM}/iphone11-13.3-en-portrait/TestLogs/) - mkdir -p render-test-app - gsutil -m cp -r $testResult render-test-app - cd render-test-app/TestLogs - xcparse attachments *.xcresult && ls - cd ../.. && mkdir -p /tmp/tests/ios-render-test - if ls render-test-app/TestLogs/*.html 1> /dev/null 2>&1; then cp render-test-app/TestLogs/*.html /tmp/tests/ios-render-test; fi - if [[ -n $(ls render-test-app/TestLogs/*.zip 2>/dev/null) ]]; then - cp render-test-app/TestLogs/*.zip metrics/ios-render-test-runner/ - cp render-test-app/TestLogs/*.zip /tmp/tests/ios-render-test - cd metrics/ios-render-test-runner/ - unzip -o *.zip - rm -rf *.zip - fi - fi - - save - ios-unit-test-runner: - executor: macos-11_3_1 - steps: - - checkout - - prepare - - prepare-macos - - prepare-ios-codesign-keychain: - directory: test/ios - - config: - config_params: '-G Xcode -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphoneos -DMBGL_IOS_UNIT_TEST=ON -DCMAKE_OSX_ARCHITECTURES=arm64e -DMBGL_WITH_IOS_CCACHE=ON' - - build: - build_params: '--config Release' - - codesign-ios-test-runner: - directory: test/ios - - login-google-cloud-platform-ios - - run-ios-test-app: - directory: test/ios - - run: - name: Retrieve Test Result from gcloud - when: always - command: | - if [[ -n "${GCLOUD_SERVICE_ACCOUNT_JSON_IOS}" ]]; then - testResult=$(gsutil ls -d gs://test-lab-hn7kwqcz3108z-hjm4qtbqqkymk/ios-test-app-${CIRCLE_BUILD_NUM}/iphone11-13.3-en-portrait/TestLogs/) - mkdir -p unit-test-app - gsutil -m cp -r $testResult unit-test-app - cd unit-test-app/TestLogs - xcparse attachments *.xcresult && ls - cd ../.. && mkdir -p /tmp/tests/unit-test - if ls unit-test-app/TestLogs/*.xml 1> /dev/null 2>&1; then cp unit-test-app/TestLogs/*.xml /tmp/tests/unit-test/results.xml; fi - fi - - save - android-api-breakage: - executor: ubuntu-eoan - steps: - - run: - name: Clone mapbox-gl-native-android in working directory - command: git clone https://github.com/mapbox/mapbox-gl-native-android.git . - - prepare - - run: - name: Update mapbox-gl-native to match PR - command: cd vendor/mapbox-gl-native && git fetch origin $CIRCLE_SHA1 && git checkout $CIRCLE_SHA1 && git submodule update --init --recursive - - run: - name: Build SDK - command: BUILDTYPE=Release make android-arm-v8 - - save - android-unit-test-runner: - executor: ubuntu-eoan - steps: - - checkout - - prepare - - run: - name: Build UnitTestRunner APK - command: | - cd test/android - ./gradlew --parallel --max-workers=8 -Pmapbox.abis=arm64-v8a app:assembleRelease app:assembleAndroidTest - - login-google-cloud-platform - - run: - name: Run UnitTestRunner on Firebase - no_output_timeout: 20m - command: | - gcloud firebase test android models list - gcloud firebase test android run --type instrumentation \ - --app test/android/app/build/outputs/apk/release/app-release.apk \ - --test test/android/app/build/outputs/apk/androidTest/release/app-release-androidTest.apk \ - --device-ids flame --os-version-ids 29 --locales en --orientations portrait --timeout 20m \ - --directories-to-pull /sdcard/test/results --results-dir unit-test-${CIRCLE_BUILD_NUM} \ - --no-record-video --no-performance-metrics - - run: - name: Retrieve Test Result from gcloud - when: always - command: | - testResult=$(gsutil ls gs://test-lab-186672a0qp5bq-ycr70axads3nc/unit-test-${CIRCLE_BUILD_NUM}/**/results/results.xml) - mkdir -p /tmp/tests/unit-test - gsutil cp $testResult /tmp/tests/unit-test - - save - android-render-test-runner: - executor: ubuntu-eoan - steps: - - checkout - - prepare - - run: - name: Build RenderTestRunner APK - command: | - cd render-test/android - ./gradlew --parallel --max-workers=8 -Pmapbox.abis=arm64-v8a app:assembleRelease app:assembleAndroidTest - - login-google-cloud-platform - - run: - name: Run RenderTestRunner Instrumentation Test on Firebase - no_output_timeout: 20m - command: | - gcloud firebase test android models list - gcloud firebase test android run --type instrumentation \ - --app render-test/android/app/build/outputs/apk/release/app-release.apk \ - --test render-test/android/app/build/outputs/apk/androidTest/release/app-release-androidTest.apk \ - --device-ids flame --os-version-ids 29 --locales en --orientations portrait --timeout 20m \ - --directories-to-pull /sdcard --results-dir render-test-app-${CIRCLE_BUILD_NUM} \ - --no-record-video --no-performance-metrics - - run: - name: Retrieve TestResult from gcloud - when: always - command: | - testResult=$(gsutil ls gs://test-lab-186672a0qp5bq-ycr70axads3nc/render-test-app-${CIRCLE_BUILD_NUM}/**/*.html) - mkdir -p /tmp/tests/render-test-app - gsutil cp $testResult /tmp/tests/render-test-app - - run: - name: Retrieve Rebaselined Metrics from gcloud - command: | - metricsResult=$(gsutil ls -d gs://test-lab-186672a0qp5bq-ycr70axads3nc/render-test-app-${CIRCLE_BUILD_NUM}/*/*/sdcard/baselines/*) || true - gsutil -m cp -r $metricsResult metrics/android-render-test-runner/ || true - mkdir -p /tmp/tests/render-test-app/rebaselined_metrics - gsutil -m cp -r $metricsResult /tmp/tests/render-test-app/rebaselined_metrics || true - - save - trigger-pipeline: - executor: ubuntu-eoan - parameters: - slug: - type: string - steps: - - checkout - - run: - name: Trigger Pipeline - command: | - scripts/ci-circleci-start-pipeline.py --target-slug << parameters.slug >> - sanity-checks: - executor: ubuntu-eoan - steps: - - checkout - - prepare - - config: - config_params: '-G Ninja -DCMAKE_C_COMPILER=clang-8 -DCMAKE_CXX_COMPILER=clang++-8' - - run: - name: Code Generators - command: | - cp build/mbgl-core.license LICENSE.mbgl-core.md - platform/default/include/mbgl/storage/offline_schema.js - scripts/generate-shaders.js - scripts/generate-style-code.js - git add -A && git diff --staged --exit-code | tee nitpick.patch - - run: - name: Validation Scripts - command: | - scripts/nitpick/submodule-pin.js - - run: - name: CMake Format - command: | - cmake-format -i $(find -name '*.cmake' -and -not -path './vendor/*/*' -and -not -path './build/*') - cmake-format -i $(find -name CMakeLists.txt -and -not -path './vendor/*/*' -and -not -path './build/*') - git diff --exit-code | tee nitpick.patch - - run: - name: Clang Format - command: | - git diff -U0 --ignore-submodules=all --no-color origin/master... *.cpp *.hpp | clang-format-diff-8 -p1 -i - git diff --exit-code | tee nitpick.patch - - run: - name: Clang Tidy - command: | - run-clang-tidy-8 -quiet -j $(nproc) -header-filter='.*' -p build $PWD/src/.*cpp $PWD/platform/.*cpp - - save - baselines: - executor: ubuntu-eoan - steps: - - checkout - - prepare - - prepare-linux - - attach_workspace: - at: /tmp/attach - - run: - name: 'Binary Size' - command: | - /tmp/attach/install/linux-gcc8-release/bin/mbgl-render-test-runner -u rebaseline -p metrics/binary-size.json - - run: - name: 'Metrics Baselines' - command: | - cp -r /tmp/attach/metrics . - git add -A && git diff --staged --exit-code | tee baselines.patch - - save - build-template: - parameters: - config_params: - type: string - default: '' - build_params: - type: string - default: '' - test_params: - type: string - default: '' - executor_name: - type: string - target_is_android: - type: boolean - default: false - target_is_linux: - type: boolean - default: false - target_is_macos: - type: boolean - default: false - install: - type: boolean - default: false - metrics: - type: boolean - default: false - style_tests: - type: boolean - default: false - upload_coverage: - type: boolean - default: false - publish_coverage: - type: boolean - default: false - executor: << parameters.executor_name >> - steps: - - checkout - - when: - condition: << parameters.target_is_android >> - steps: - - prepare - - config: - config_params: << parameters.config_params >> - - build: - build_params: << parameters.build_params >> - - when: - condition: << parameters.target_is_linux >> - steps: - - prepare - - prepare-linux - - config: - config_params: << parameters.config_params >> - - build: - build_params: << parameters.build_params >> - - test: - test_params: << parameters.test_params >> - - when: - condition: << parameters.target_is_macos >> - steps: - - prepare - - prepare-macos - - config: - config_params: << parameters.config_params >> - - build: - build_params: << parameters.build_params >> - - test: - test_params: << parameters.test_params >> - - when: - condition: << parameters.install >> - steps: - - install - - when: - condition: << parameters.style_tests >> - steps: - - metrics: - step_name: 'Style Tests' - metrics_params: '-u rebaseline -p metrics/$CIRCLE_JOB-style.json' - - when: - condition: << parameters.metrics >> - steps: - - metrics: - step_name: 'Metrics' - metrics_params: '-u rebaseline -p metrics/$CIRCLE_JOB-metrics.json' - - when: - condition: << parameters.upload_coverage >> - steps: - - upload-coverage-results - - when: - condition: << parameters.publish_coverage >> - steps: - - publish-coverage-metrics - - save diff --git a/cloudformation/ci.template.js b/cloudformation/ci.template.js deleted file mode 100644 index 64d5ba2e8..000000000 --- a/cloudformation/ci.template.js +++ /dev/null @@ -1,117 +0,0 @@ -'use strict'; - -const template = { - AWSTemplateFormatVersion: '2010-09-09', - Description: 'mapbox-gl-native-ios circleci resources', - Resources: { - BuildUser: { - Type: 'AWS::IAM::User', - Properties: { - Policies: [ - { - PolicyName: 'listBuckets', - PolicyDocument: { - Statement: [ - { - Action: [ 's3:ListBucket' ], - Effect: 'Allow', - Resource: [ 'arn:aws:s3:::mapbox' ], - Condition: { StringLike: { 's3:prefix': 'mapbox-gl-native/*' } } - }, - { - Action: [ 's3:ListBucket' ], - Resource: [ 'arn:aws:s3:::mapbox-node-binary' ], - Effect: 'Allow' - }, - { - Action: [ 's3:ListBucket' ], - Resource: [ 'arn:aws:s3:::mapbox-loading-dock' ], - Effect: 'Allow' - } - ] - } - }, - { - PolicyName: 'build-testing', - PolicyDocument: { - Statement: [ - { - Action: [ - 's3:GetObject', - 's3:GetObjectAcl', - 's3:PutObject', - 's3:PutObjectAcl' - ], - Effect: 'Allow', - Resource: [ - 'arn:aws:s3:::mapbox/mapbox-gl-native/*', - 'arn:aws:s3:::mapbox-node-binary/@mapbox/mapbox-gl-native/*', - 'arn:aws:s3:::mapbox/mapbox-gl-native/ios/builds/*' - ] - } - ] - } - }, - { - PolicyName: 'cloudwatch-metrics', - PolicyDocument: { - Statement: [ - { - Action: [ - 'cloudwatch:PutMetricData', - 'cloudwatch:GetMetricData', - 'cloudwatch:GetMetricStatistics' - ], - Effect: 'Allow', - Resource: [ '*' ] - } - ] - } - }, - { - PolicyName: 'get-signing-key', - PolicyDocument: { - Statement: [ - { - Action: [ 's3:GetObject' ], - Effect: 'Allow', - Resource: [ - 'arn:aws:s3:::mapbox/android/signing-credentials/secring.gpg' - ] - } - ] - } - }, - { - PolicyName: 'publish-metrics', - PolicyDocument: { - Statement: [ - { - Action: [ 's3:PutObject', 's3:GetObject', 's3:GetObjectAcl' ], - Effect: 'Allow', - Resource: [ - 'arn:aws:s3:::mapbox-loading-dock/raw/mobile.binarysize/*', - 'arn:aws:s3:::mapbox-loading-dock/raw/mobile.codecoverage/*', - 'arn:aws:s3:::mapbox-loading-dock/raw/mobile_staging.docs_coverage/*', - 'arn:aws:s3:::mapbox-loading-dock/raw/mobile_staging.codecoverage/*', - 'arn:aws:s3:::mapbox-loading-dock/raw/mobile_staging.github_stats/*' - ] - } - ] - } - } - ] - } - }, - BuildUserKey: { - Type: 'AWS::IAM::AccessKey', - Properties: { UserName: { Ref: 'BuildUser' } } - } - }, - Outputs: { - AccessKeyId: { Value: { Ref: 'BuildUserKey' } }, - SecretAccessKey: { Value: { 'Fn::GetAtt': [ 'BuildUserKey', 'SecretAccessKey' ] } } - } -}; - -module.exports = template; diff --git a/platform/android/circle.yml b/platform/android/circle.yml deleted file mode 100644 index af2e8f962..000000000 --- a/platform/android/circle.yml +++ /dev/null @@ -1,371 +0,0 @@ -version: 2.1 - -workflows: - version: 2 - mapbox-gl-native-android: - jobs: - - android-arm-template: - name: android-debug-arm-v8 - - android-release: - filters: - tags: - only: /android-v.*/ - -commands: - npm-install: - steps: - - run: - name: npm install - command: npm install --ignore-scripts - npm-install-vendor: - steps: - - run: - name: npm install - command: cd vendor/mapbox-gl-native && npm install --ignore-scripts - prepare-ccache: - steps: - - run: - name: Prepare ccache - command: | - # CircleCI doesn't have any way to embed arbitrary environment variables or command output - # into cache keys, so we're using the workaround of writing the desired content to a file, - # and then using `{{ checksum "filename" }}` in the cache key. - echo "$CIRCLE_BRANCH" - echo "$CIRCLE_BRANCH" > .circle-branch - echo "$CIRCLE_SHA1" - echo "$CIRCLE_SHA1" > .circle-sha1 - echo "$CIRCLE_TARGET_BRANCH" - echo "${CIRCLE_TARGET_BRANCH:master}" > .circle-target-branch - echo "$CIRCLE_MERGE_BASE" - echo "${CIRCLE_MERGE_BASE:master}" > .circle-merge-base - ccache --clear - reset-ccache-stats: - steps: - - run: - name: Clear ccache statistics - command: | - ccache --zero-stats - ccache --max-size=2G - ccache --show-stats - show-ccache-stats: - steps: - - run: - name: Show ccache statistics - command: ccache --show-stats - save-node_modules-cache: - steps: - - save_cache: - name: Save node_modules cache - key: 'node_modules/v1/{{ arch }}/{{ checksum "package.json" }}' - paths: [ "node_modules" ] - restore-node_modules-cache: - steps: - - restore_cache: - name: Restore node_modules cache - keys: - - 'node_modules/v1/{{ arch }}/{{ checksum "package.json" }}' - - 'node_modules/v1/{{ arch }}' - save-ccache: - steps: - - save_cache: - name: Save ccache - key: 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-branch" }}/{{ checksum ".circle-sha1" }}' - paths: [ "~/.ccache" ] - restore-ccache: - steps: - - restore_cache: - name: Restore ccache - keys: - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-branch" }}/{{ checksum ".circle-sha1" }}' - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-branch" }}' - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-target-branch" }}/{{ checksum ".circle-merge-base" }}' - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-target-branch" }}' - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}' - save-gradle-cache: - steps: - - save_cache: - name: Save gradle cache - key: 'gradle/v1/{{ checksum "gradle/dependencies.gradle" }}/{{ checksum "build.gradle" }}/{{ checksum "gradle/wrapper/gradle-wrapper.properties" }}' - paths: [ "/root/.gradle" ] - restore-gradle-cache: - steps: - - restore_cache: - name: Restore gradle cache - keys: - - 'gradle/v1/{{ checksum "gradle/dependencies.gradle" }}/{{ checksum "build.gradle" }}/{{ checksum "gradle/wrapper/gradle-wrapper.properties" }}' - - 'gradle/v1' - prepare-environment: - steps: - - run: - name: Prepare environment - command: touch "$BASH_ENV" && ./vendor/mapbox-gl-native/scripts/environment.js | tee -a "$BASH_ENV" - install-dependencies: - parameters: - node_modules: - type: boolean - default: true - ccache: - type: boolean - default: true - gradle: - type: boolean - default: false - steps: - - checkout - - when: - condition: << parameters.node_modules >> - steps: [ restore-node_modules-cache, npm-install ] - - when: - condition: << parameters.ccache >> - steps: [ prepare-ccache, restore-ccache, reset-ccache-stats ] - - when: - condition: << parameters.gradle >> - steps: [ restore-gradle-cache ] - save-dependencies: - parameters: - node_modules: - type: boolean - default: true - ccache: - type: boolean - default: true - gradle: - type: boolean - default: false - steps: - - when: - condition: << parameters.node_modules >> - steps: [ save-node_modules-cache ] - - when: - condition: << parameters.ccache >> - steps: [ save-ccache, show-ccache-stats ] - - when: - condition: << parameters.gradle >> - steps: [ save-gradle-cache ] - setup-llvm-symbolizer: - steps: - - run: - name: Environment Setup - command: | - # LLVM has a hard check for "llvm-symbolizer" and doesn't support suffixed executables - ln -s /usr/bin/llvm-symbolizer-* /usr/bin/llvm-symbolizer - # We'll use tee to redirect stderr to a file so we can check for sanitiziation - # https://bugs.launchpad.net/ubuntu/+source/xorg-server/+bug/1059947 - sed -i 's/"$@" 2>&1/"$@"/' /usr/bin/xvfb-run - configure-cmake: - steps: - - run: - name: CMake configuration step - command: | - mkdir -p build - cd build - cmake -DWITH_COVERAGE=${WITH_COVERAGE:0} -DWITH_OSMESA=${WITH_OSMESA:0} -DWITH_EGL=${WITH_EGL:0} .. - cd .. - login-google-cloud-platform: - steps: - - run: - name: Log in to Google Cloud Platform - command: | - if [[ -n "${GLCLOUD_SERVICE_JSON}" ]]; then - echo "${GLCLOUD_SERVICE_JSON}" > secret.json - gcloud auth activate-service-account --key-file secret.json --project mapbox-gl-native-android - rm secret.json - fi - generate-api-javadoc: - steps: - - run: - name: Generate Maps SDK API javadoc and transfer to `/android-docs` - command: | - export VERSION_TAG=${CIRCLE_TAG} - export GITHUB_TOKEN=${DANGER_GITHUB_API_TOKEN} - export DOCS_REPO="android-docs" - bash scripts/trigger-maps-documentation-deploy-steps.sh - -jobs: - # ------------------------------------------------------------------------------ - android-arm-template: - parameters: - stl: - type: string - default: "c++_static" - image: - type: string - default: android-ndk-r21b:a111a5b966 - firebase_device_id: - type: string - default: sailfish - firebase_device_os: - type: string - default: "26" - abi: - type: string - default: "arm-v8" - docker: - - image: mbgl/<< parameters.image >> - resource_class: xlarge - working_directory: /src - environment: - LIBSYSCONFCPUS: 8 - JOBS: 8 - BUILDTYPE: Debug - IS_LOCAL_DEVELOPMENT: false - MBGL_ANDROID_STL: << parameters.stl >> - steps: - - install-dependencies: { gradle: true } - - run: - name: Initialize vendor submodules - command: git submodule update --init --recursive vendor - - run: - name: Check code style - command: make android-check - - run: - name: Run Android unit tests - command: make run-android-unit-test - - run: - name: Build libmapbox-gl.so for << parameters.abi >> - command: make android-lib-<< parameters.abi >> - - run: - name: Generate Espresso sanity tests - command: make test-code-android - - run: - name: Build Test APK - command: | - if [ -n "${MAPBOX_DEVELOPER_CONFIG_XML}" ]; then - echo "${MAPBOX_DEVELOPER_CONFIG_XML}" > MapboxGLAndroidSDKTestApp/src/main/res/values/developer-config.xml - make android-ui-test-<< parameters.abi >> - fi - - save-dependencies: { gradle: true } - - login-google-cloud-platform - - run: - name: Run instrumentation tests on Firebase - no_output_timeout: 20m - command: | - if [[ -n "${GLCLOUD_SERVICE_JSON}" ]]; then - gcloud firebase test android models list - gcloud firebase test android run --type instrumentation \ - --app MapboxGLAndroidSDKTestApp/build/outputs/apk/debug/MapboxGLAndroidSDKTestApp-debug.apk \ - --test MapboxGLAndroidSDKTestApp/build/outputs/apk/androidTest/debug/MapboxGLAndroidSDKTestApp-debug-androidTest.apk \ - --device-ids << parameters.firebase_device_id >> --os-version-ids << parameters.firebase_device_os >> --locales en --orientations portrait --timeout 20m \ - --environment-variables coverage=true,coverageFile="/sdcard/coverage.ec" --directories-to-pull /sdcard --results-dir mapbox-android-sdk-${CIRCLE_BUILD_NUM} - fi - - store_artifacts: - path: MapboxGLAndroidSDKTestApp/build/outputs/apk/debug - destination: . - - store_artifacts: - path: MapboxGLAndroidSDK/build/reports/lint-results.html - - store_artifacts: - path: MapboxGLAndroidSDK/build/reports/lint-results.xml - - store_artifacts: - path: MapboxGLAndroidSDK/lint-baseline.xml - - store_artifacts: - path: MapboxGLAndroidSDKTestApp/build/reports/lint-results.html - - store_artifacts: - path: MapboxGLAndroidSDKTestApp/build/reports/lint-results.xml - - store_artifacts: - path: MapboxGLAndroidSDKTestApp/lint-baseline.xml - - store_artifacts: - path: MapboxGLAndroidSDK/build/intermediates/cmake/debug/obj - - # ------------------------------------------------------------------------------ - android-release: - docker: - - image: mbgl/android-ndk-r21b:a111a5b966 - resource_class: xlarge - working_directory: /src - environment: - LIBSYSCONFCPUS: 8 - JOBS: 8 - BUILDTYPE: Release - IS_LOCAL_DEVELOPMENT: false - steps: - - install-dependencies: { gradle: true } - - run: - name: Initialize vendor submodules - command: git submodule update --init --recursive vendor - - run: - name: Android nitpick - command: make run-android-nitpick - - run: - name: Trigger android benchmark run - command: | - if [ -n "${MOBILE_METRICS_TOKEN}" ]; then - if [[ $CIRCLE_BRANCH == master ]]; then - curl -u $MOBILE_METRICS_TOKEN -d build_parameters[CIRCLE_JOB]=android-benchmark https://circleci.com/api/v1.1/project/github/mapbox/mobile-metrics/tree/master - fi - fi - - run: - name: Trigger android binary size check - command: | - if [ -n "${MOBILE_METRICS_TOKEN}" ]; then - if [[ $CIRCLE_BRANCH == master ]]; then - curl -u ${MOBILE_METRICS_TOKEN}: -d build_parameters[CIRCLE_JOB]=android-binary-size-hydrogen https://circleci.com/api/v1.1/project/github/mapbox/mobile-metrics/tree/master - fi - fi - - run: - name: Generate Maven credentials - command: | - if [ -n "${BINTRAY_USER}" ]; then - echo "BINTRAY_USER=$BINTRAY_USER - BINTRAY_API_KEY=$BINTRAY_API_KEY - GPG_PASSPHRASE=$GPG_PASSPHRASE" - fi - - run: - name: Update version name - command: | - if [[ $CIRCLE_TAG == android-v* ]]; then - sed -i -e "s/^VERSION_NAME=.*/VERSION_NAME=${CIRCLE_TAG:9}/" MapboxGLAndroidSDK/gradle.properties - fi - - run: - name: Build package - command: make apackage - - run: - name: Build release Test App - command: | - if [ -n "${MAPBOX_DEVELOPER_CONFIG_XML}" ]; then - echo "${MAPBOX_DEVELOPER_CONFIG_XML}" > MapboxGLAndroidSDKTestApp/src/main/res/values/developer-config.xml - make android - fi - - run: - name: Generate javadoc - command: make android-javadoc - - save-dependencies: { gradle: true } - - login-google-cloud-platform - - run: - name: Run robotest of release Test App on Firebase - no_output_timeout: 10m - command: | - if [[ -n "${GLCLOUD_SERVICE_JSON}" ]]; then - if [[ $CIRCLE_BRANCH != master && $CIRCLE_TAG != android-v* ]]; then - gcloud firebase test android run --type robo \ - --app MapboxGLAndroidSDKTestApp/build/outputs/apk/release/MapboxGLAndroidSDKTestApp-release.apk \ - --device-ids sailfish --os-version-ids "26" --locales en --orientations portrait --timeout 90s - fi - fi - - run: - name: archive debugable objects - command: | - cd MapboxGLAndroidSDK/build/intermediates/cmake/release && tar -zcvf debuggable-objects.tar.gz obj && cd - - - store_artifacts: - path: MapboxGLAndroidSDKTestApp/build/outputs/apk/release - destination: . - - store_artifacts: - path: MapboxGLAndroidSDK/build/intermediates/cmake/release/debuggable-objects.tar.gz - - deploy: - name: Publish to Bintray - command: | - if [[ $CIRCLE_BRANCH == master ]] || [[ $CIRCLE_BRANCH == release-* ]] || [[ $CIRCLE_TAG == android-v* ]]; then - version=$(cat MapboxGLAndroidSDK/gradle.properties | grep "VERSION_NAME") - if [[ $version != *"SNAPSHOT"* ]]; then - make run-android-upload-to-bintray - else - make run-android-upload-to-artifactory - fi - fi - - run: - name: upload debuggable objects to release tag - command: | - if [[ $CIRCLE_TAG == android-v* ]]; then - export GITHUB_TOKEN=${DANGER_GITHUB_API_TOKEN} - python3 scripts/upload-to-github-release.py --file MapboxGLAndroidSDK/build/intermediates/cmake/release/debuggable-objects.tar.gz --release $CIRCLE_TAG --project mapbox-gl-native-android - fi - - generate-api-javadoc \ No newline at end of file diff --git a/platform/ios/circle.yml b/platform/ios/circle.yml deleted file mode 100644 index 5adca471e..000000000 --- a/platform/ios/circle.yml +++ /dev/null @@ -1,544 +0,0 @@ -version: 2.1 - -workflows: - version: 2 - mbgl-legacy: - jobs: - # - # Naming convention: {platform}-{additional description}-{build type} - # - {platform} is the client platform/framework, which may differ from - # the build platform. Specify both if applicable, e.g., "qt5-macos". - # - {additional description} optionally describes the compiler or other - # unique aspect of the build environment. - # - {build type} is typically "debug" or "release". - # - - ios-debug - - ios-debug-xcode10 - - ios-release-template: - name: ios-release - - ios-trigger-metrics: - requires: - - ios-release - filters: - branches: - only: master - - ios-release-tag: - filters: - tags: - only: /ios-.*/ - branches: - ignore: /.*/ - - macos-debug - nightly: - triggers: - - schedule: - cron: "0 5 * * *" - filters: - branches: - only: - - master - jobs: - - metrics-nightly - - ios-release-template: - name: ios-release-nightly - - ios-sanitize-nightly - - ios-sanitize-address-nightly - - ios-static-analyzer-nightly - - ios-static-analyzer-nightly-xcode10 - -commands: - npm-install: - steps: - - run: - name: npm install - command: npm install --ignore-scripts - prepare-environment: - steps: - - run: - name: Prepare environment - command: touch "$BASH_ENV" && ./scripts/environment.js | tee -a "$BASH_ENV" - prepare-submodules: - steps: - - run: - name: Prepare submodules - command: git submodule sync && git submodule update --init --recursive - prepare-ccache: - steps: - - run: - name: Prepare ccache - command: | - # CircleCI doesn't have any way to embed arbitrary environment variables or command output - # into cache keys, so we're using the workaround of writing the desired content to a file, - # and then using `{{ checksum "filename" }}` in the cache key. - echo "$CIRCLE_BRANCH" - echo "$CIRCLE_BRANCH" > .circle-branch - echo "$CIRCLE_SHA1" - echo "$CIRCLE_SHA1" > .circle-sha1 - echo "$CIRCLE_TARGET_BRANCH" - echo "${CIRCLE_TARGET_BRANCH:master}" > .circle-target-branch - echo "$CIRCLE_MERGE_BASE" - echo "${CIRCLE_MERGE_BASE:master}" > .circle-merge-base - ccache --clear - reset-ccache-stats: - steps: - - run: - name: Clear ccache statistics - command: | - ccache --zero-stats - ccache --max-size=2G - ccache --show-stats - show-ccache-stats: - steps: - - run: - name: Show ccache statistics - command: ccache --show-stats - - - save-node_modules-cache: - steps: - - save_cache: - name: Save node_modules cache - key: 'node_modules/v1/{{ arch }}/{{ checksum "package.json" }}' - paths: [ "node_modules" ] - restore-node_modules-cache: - steps: - - restore_cache: - name: Restore node_modules cache - keys: - - 'node_modules/v1/{{ arch }}/{{ checksum "package.json" }}' - - 'node_modules/v1/{{ arch }}' - save-ccache: - steps: - - save_cache: - name: Save ccache - key: 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-branch" }}/{{ checksum ".circle-sha1" }}' - paths: [ "~/.ccache" ] - restore-ccache: - steps: - - restore_cache: - name: Restore ccache - keys: - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-branch" }}/{{ checksum ".circle-sha1" }}' - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-branch" }}' - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-target-branch" }}/{{ checksum ".circle-merge-base" }}' - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}/{{ checksum ".circle-target-branch" }}' - - 'ccache/v1/{{ arch }}/{{ .Environment.CIRCLE_JOB }}' - - - install-dependencies: - parameters: - node_modules: - type: boolean - default: true - ccache: - type: boolean - default: true - steps: - - checkout - - prepare-submodules - - when: - condition: << parameters.node_modules >> - steps: [ restore-node_modules-cache, npm-install ] - - prepare-environment - - when: - condition: << parameters.ccache >> - steps: [ prepare-ccache, restore-ccache, reset-ccache-stats ] - save-dependencies: - parameters: - node_modules: - type: boolean - default: true - ccache: - type: boolean - default: true - steps: - - when: - condition: << parameters.node_modules >> - steps: [ save-node_modules-cache ] - - when: - condition: << parameters.ccache >> - steps: [ save-ccache, show-ccache-stats ] - - - configure-cmake: - steps: - - run: - name: CMake configuration step - command: | - mkdir -p build - cd build - cmake -DWITH_COVERAGE=${WITH_COVERAGE:0} -DWITH_OSMESA=${WITH_OSMESA:0} -DWITH_EGL=${WITH_EGL:0} .. - cd .. - build-ios-test: - steps: - - run: - name: Build ios-test - command: make ios-test - no_output_timeout: 20m - build-ios-integration-test: - steps: - - run: - name: Build ios-integration-test - command: make ios-integration-test - build-macos-test: - steps: - - run: - name: Build macos-test - command: make macos-test - no_output_timeout: 20m - - - check-public-symbols: - steps: - - run: - name: Check public symbols - command: make darwin-check-public-symbols - - - install-ios-packaging-dependencies: - steps: - - run: - name: Install iOS packaging dependencies - command: | - echo "ruby-2.6" > ~/.ruby-version - ./platform/ios/scripts/install-packaging-dependencies.sh - background: true - - install-macos-dependencies: - steps: - - run: - name: Install macOS dependencies - command: brew install cmake ccache pkg-config glfw3 - - trigger-metrics: - steps: - - run: - name: Trigger metrics - command: | - if [ -n "${MOBILE_METRICS_TOKEN}" ]; then - bash -c "curl -X POST --header \"Content-Type: application/json\" --data '{\"parameters\": {\"run_ios_maps_benchmark\": true, \"ci_ref\": $CIRCLE_BUILD_NUM }, \"branch\": \"master\" }' https://circleci.com/api/v2/project/github/mapbox/mobile-metrics/pipeline?circle-token=${MOBILE_METRICS_TOKEN}" - else - echo "MOBILE_METRICS_TOKEN not provided" - fi - - collect-xcode-build-logs: - steps: - - run: - name: Collect Xcode build logs - when: always - command: | - export XCODE_LOG_DIR=build/logs - mkdir -p $XCODE_LOG_DIR - cp build/*.log $XCODE_LOG_DIR - upload-xcode-build-logs: - steps: - - store_artifacts: - path: build/logs - - - notify-slack-nightly-failure: - steps: - - run: - name: Send a Slack notification on nightly failure - when: on_fail - command: | - if [[ $CIRCLE_BRANCH == master ]]; then - export SLACK_MESSAGE="Nightly build of \`$CIRCLE_JOB\` <$CIRCLE_BUILD_URL|failed>." - export SLACK_COLOR="danger" - scripts/notify-slack.sh - fi - - # - # Add this step to all regular jobs to enable skipping of certain non-code-related changes. - # - # Do not include this step in nightly or release deployment jobs. - # - # To make a job potentially skippable on changes unrelated to its platform, it must: - # - Target one of the skippable platforms: Android, iOS, or macOS. - # - Have a job name that begins with a supported platform name. - # - Not be related to core functionality or rendering tests. Job names that - # contain "render-tests" cannot be skipped by platform changes. - # - # See the script in the following step for how to implement support for other platforms. - # - check-if-this-job-can-be-skipped: - steps: - - run: - name: Check if this job can be skipped - command: | - if [[ $CIRCLE_BRANCH != master ]] && [[ $CIRCLE_BRANCH != release-* ]] && [[ -z $CIRCLE_TAG ]]; then - scripts/check-ci-job-skippability.js - fi - -jobs: - ios-debug: - macos: - xcode: "11.2.1" - environment: - BUILDTYPE: Debug - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - steps: - - install-macos-dependencies - - install-dependencies - - check-public-symbols - - run: - name: Lint podspecs and plist files - command: make ios-lint - - check-if-this-job-can-be-skipped - - build-ios-test - - save-dependencies - - collect-xcode-build-logs - - upload-xcode-build-logs - -# ------------------------------------------------------------------------------ - ios-debug-xcode10: - macos: - xcode: "10.3.0" - environment: - BUILDTYPE: Debug - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - steps: - - install-macos-dependencies - - install-dependencies - - check-public-symbols - - run: - name: Lint podspecs and plist files - command: make ios-lint - - check-if-this-job-can-be-skipped - - build-ios-test - - save-dependencies - - collect-xcode-build-logs - - upload-xcode-build-logs - -# ------------------------------------------------------------------------------ - ios-sanitize-nightly: - macos: - xcode: "11.2.1" - environment: - BUILDTYPE: Debug - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - SLACK_CHANNEL: CU0LHNNJY - steps: - - install-macos-dependencies - - install-dependencies - - run: - name: Build and run SDK unit tests with thread and undefined behavior sanitizers - command: make ios-sanitize - - run: - name: Get iOS code coverage - command: | - echo "Skipping iOS code coverage" - # Currently failing, need to update for Xcode 11 - # platform/ios/scripts/ios-code-coverage.sh CI - # - - save-dependencies - - collect-xcode-build-logs - - upload-xcode-build-logs - - notify-slack-nightly-failure - -# ------------------------------------------------------------------------------ - ios-sanitize-address-nightly: - macos: - xcode: "11.2.1" - environment: - BUILDTYPE: Debug - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - SLACK_CHANNEL: CU0LHNNJY - steps: - - install-macos-dependencies - - install-dependencies - - run: - name: Build and run SDK unit tests with address sanitizer - command: make ios-sanitize-address - - save-dependencies - - collect-xcode-build-logs - - upload-xcode-build-logs - - notify-slack-nightly-failure - -# ------------------------------------------------------------------------------ - ios-static-analyzer-nightly: - macos: - xcode: "11.2.1" - environment: - BUILDTYPE: Debug - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - SLACK_CHANNEL: CU0LHNNJY - steps: - - install-macos-dependencies - - install-dependencies - - run: - name: Build and run SDK unit tests with the static analyzer - command: make ios-static-analyzer - - save-dependencies - - collect-xcode-build-logs - - upload-xcode-build-logs - - notify-slack-nightly-failure - -# ------------------------------------------------------------------------------ - ios-static-analyzer-nightly-xcode10: - macos: - xcode: "10.3.0" - environment: - BUILDTYPE: Debug - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - SLACK_CHANNEL: CU0LHNNJY - steps: - - install-macos-dependencies - - install-dependencies - - run: - name: Build and run SDK unit tests with the static analyzer - command: make ios-static-analyzer - - save-dependencies - - collect-xcode-build-logs - - upload-xcode-build-logs - - notify-slack-nightly-failure - -# ------------------------------------------------------------------------------ - ios-release-template: - macos: - xcode: "11.2.1" - shell: /bin/bash --login -eo pipefail - environment: - BUILDTYPE: Release - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - SLACK_CHANNEL: CU0LHNNJY - steps: - - install-macos-dependencies - - install-dependencies - - check-if-this-job-can-be-skipped - - install-ios-packaging-dependencies - - run: - name: Build dynamic framework for device and simulator - command: make iframework - no_output_timeout: 20m - - deploy: - name: Upload snapshot build to s3 - command: | - if [[ $CIRCLE_BRANCH == master ]]; then - platform/ios/scripts/deploy-snapshot.sh - fi - - deploy: - name: Deploy to Mapbox CocoaPods spec repo - command: | - if [[ $CIRCLE_BRANCH == master ]]; then - platform/ios/scripts/deploy-to-cocoapods.sh - fi - - run: - name: Record size - command: | - echo "Skipping Record size step" - # Skipping due to https://github.com/mapbox/mapbox-gl-native/issues/15751 - #platform/ios/scripts/metrics.sh - - save-dependencies - - collect-xcode-build-logs - - upload-xcode-build-logs - - notify-slack-nightly-failure - -# ------------------------------------------------------------------------------ - ios-release-tag: - macos: - xcode: "11.2.1" - shell: /bin/bash --login -eo pipefail - environment: - BUILDTYPE: Release - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - SLACK_CHANNEL: CU0LHNNJY - steps: - - checkout - - run: - name: Send a Slack notification on start - command: | - export SLACK_MESSAGE="<$CIRCLE_BUILD_URL|Release build for \`$CIRCLE_TAG\` started.>" - scripts/notify-slack.sh - - install-macos-dependencies - - install-dependencies - - install-ios-packaging-dependencies - - run: - name: Trigger external deploy steps - command: | - export VERSION_TAG=${CIRCLE_TAG} - export DOCS_REPO="ios-sdk" - scripts/trigger-maps-documentation-deploy-steps.sh - - run: - name: Build, package, and upload iOS release - command: | - export VERSION_TAG=${CIRCLE_TAG} - platform/ios/scripts/deploy-packages.sh - no_output_timeout: 20m - - deploy: - name: Deploy to CocoaPods - command: platform/ios/scripts/deploy-to-cocoapods.sh - - save-dependencies - - collect-xcode-build-logs - - upload-xcode-build-logs - - run: - name: Send a Slack notification on failure - when: on_fail - command: | - export SLACK_MESSAGE="<$CIRCLE_BUILD_URL|Release build for \`$CIRCLE_TAG\` failed.>" - export SLACK_COLOR="danger" - scripts/notify-slack.sh - - run: - name: Send a Slack notification on success - when: on_success - command: | - export SLACK_MESSAGE="<$CIRCLE_BUILD_URL|Release build for \`$CIRCLE_TAG\` succeeded.>" - export SLACK_COLOR="good" - scripts/notify-slack.sh - -# ------------------------------------------------------------------------------ - ios-trigger-metrics: - macos: - xcode: "11.2.1" - steps: - - trigger-metrics - -# ------------------------------------------------------------------------------ - macos-debug: - macos: - xcode: "11.2.1" - environment: - BUILDTYPE: Debug - HOMEBREW_NO_AUTO_UPDATE: 1 - HOMEBREW_NO_INSTALL_CLEANUP: 1 - steps: - - install-macos-dependencies - - install-dependencies - - check-if-this-job-can-be-skipped - - build-macos-test - - check-public-symbols - - run: - name: Lint plist files - command: make macos-lint - - run: - name: Nitpick Darwin code generation - command: scripts/nitpick/generated-code.js darwin - - save-dependencies - - store_artifacts: - path: test/fixtures - destination: test/fixtures - - collect-xcode-build-logs - - upload-xcode-build-logs - -# ------------------------------------------------------------------------------ - metrics-nightly: - docker: - - image: mbgl/linux-gcc-5:54f59e3ac5 - working_directory: /src - environment: - LIBSYSCONFCPUS: 2 - JOBS: 2 - steps: - - install-dependencies - - run: - name: Collect GitHub statistics - command: | - scripts/publish_github_stats.js diff --git a/platform/ios/codecov.yml b/platform/ios/codecov.yml deleted file mode 100644 index 6edf660be..000000000 --- a/platform/ios/codecov.yml +++ /dev/null @@ -1,9 +0,0 @@ -ignore: - - "test/" - - "vendor/" - -coverage: - status: - project: - default: - threshold: 1%