diff --git a/.circleci/config.yml b/.circleci/config.yml deleted file mode 100644 index bceba9db..00000000 --- a/.circleci/config.yml +++ /dev/null @@ -1,198 +0,0 @@ -aliases: - - &is_main_branch - equal: [ main, << pipeline.git.branch >> ] - -commands: - print_rust_version_info: - description: Rust toolchain version info - steps: - - run: - name: Rust version info - command: | - rustup show - rustc --version - cargo --version - rustup --version - - install_rustup: - description: Install rustup - steps: - - run: - name: Install rustup - command: | - curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain=none - - init_opam: - description: Initialize opam - steps: - - run: - name: Init opam - command: | - opam init --compiler=5.1.1 --disable-sandboxing -y - - setup_ocaml_tp: - description: Write symlinks shim/third-party/ocaml - steps: - - run: - name: Setup third-party/ocaml directory - command: | - # Assumes OPAM_SWITCH_PREFIX has been set already. - ./ocaml-setup.sh - - setup_linux_env: - description: Linux installation steps - steps: - - install_rustup - - print_rust_version_info - - run: - name: Aptitude install - command: | - sudo apt-get update - sudo apt-get install libssl-dev cmake clang lld opam zstd - - init_opam - - run: - name: Set environment variables - command: | - echo 'source "$HOME"/.cargo/env' >> "$BASH_ENV" - echo 'eval $(opam env)' >> "$BASH_ENV" - - setup_ocaml_tp - - setup_macos_env: - description: macOS installation steps - steps: - - install_rustup - - print_rust_version_info - - run: - name: Brew install - command: | - brew install cmake coreutils opam llvm zstd wget - - init_opam - - run: - name: Set environment variables - command: | - echo 'source "$HOME"/.cargo/env' >> "$BASH_ENV" - echo 'export PATH=/usr/local/opt/llvm/bin:/opt/homebrew/bin:"$PATH"' >> "$BASH_ENV" - echo 'eval $(opam env)' >> "$BASH_ENV" - - setup_ocaml_tp - - cargo: - description: Use cargo to build & test - steps: - - run: - name: Cargo build & test - command: | - cargo build - cargo test - - install_buck: - description: Download latest buck2 - parameters: - triple: - type: string - steps: - - run: - name: Install buck - command: | - wget https://github.com/facebook/buck2/releases/download/latest/buck2-<>.zst - zstd -d buck2-<>.zst -o buck2 - chmod +x buck2 - sudo ln -s $(pwd)/buck2 /usr/local/bin/buck2 - - - install_reindeer: - description: Use cargo to install reindeer - steps: - - run: - name: Install reindeer - command: | - cargo install --git https://github.com/facebookincubator/reindeer.git reindeer --force - - reindeer: - description: Use reindeer to vendor & buckify rust 3rd-party deps - steps: - - run: - name: Run reindeer steps - command: | - reindeer --third-party-dir shim/third-party/rust buckify - - buck_tp: - description: Use buck to build third-party deps - steps: - - run: - name: Build 3rd party rust. - command: | - buck2 build shim//third-party/... -v 2 - - buck_ocamlrep: - description: Use buck to build ocamlrep - steps: - - run: - name: Build ocamlrep. - command: | - buck2 build root//... -v 2 - -version: 2.1 -orbs: - rust: circleci/rust@1.6.0 -jobs: - linux-cargo-build-and-test: - description: | - Linux cargo build & test - docker: - - image: cimg/rust:1.65.0 - resource_class: xlarge - steps: - - checkout - - setup_linux_env - - cargo - - macos-cargo-build-and-test: - description: | - macOS cargo build & test - macos: - xcode: "14.2.0" - resource_class: macos.m1.medium.gen1 - steps: - - checkout - - setup_macos_env - - cargo - - linux-buck-build: - description: | - Linux buck build - docker: - - image: cimg/rust:1.65.0 - resource_class: xlarge - steps: - - checkout - - setup_linux_env - - install_buck: - triple: "x86_64-unknown-linux-gnu" - - install_reindeer - - reindeer - - buck_tp - - buck_ocamlrep - - macos-buck-build: - description: | - macOS buck build - macos: - xcode: "14.2.0" - resource_class: macos.m1.medium.gen1 - steps: - - checkout - - setup_macos_env - - install_buck: - triple: "aarch64-apple-darwin" - - install_reindeer - - reindeer - - buck_tp - - buck_ocamlrep - -workflows: - build-test: - jobs: - - linux-cargo-build-and-test - - macos-cargo-build-and-test - - linux-buck-build - - macos-buck-build