diff --git a/.github/workflows/DockerImages/Dockerfile.builddeps b/.github/workflows/DockerImages/Dockerfile.builddeps index d810f186c5..e574886db8 100644 --- a/.github/workflows/DockerImages/Dockerfile.builddeps +++ b/.github/workflows/DockerImages/Dockerfile.builddeps @@ -4,7 +4,7 @@ LABEL description="Debian Stable Slim image with Racket build dependencies pre-i RUN apt-get update && \ apt-get upgrade -y && \ - apt-get install -y unzip python libxml2-dev libfindbin-libs-perl make gcc clang uuid-dev git && \ + apt-get install -y unzip python libxml2-dev libfindbin-libs-perl make gcc uuid-dev git clang && \ apt-get clean CMD ["bash"] diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 406f372466..852dc407a9 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -4,17 +4,47 @@ on: [pull_request] jobs: - buildtest-unixstyle: - strategy: - matrix: - os: [ubuntu-18.04, macos-latest] + buildtest-linux: + container: + image: racket/racket-ci:testdeps + options: --init - runs-on: ${{ matrix.os }} + runs-on: ubuntu-18.04 steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: Build - run: make CPUS="3" PKGS="racket-test db-test unstable-flonum-lib net-test" + run: make CPUS=$(nproc) PKGS="racket-test db-test unstable-flonum-lib net-test" + - name: Test + run: | + export PATH=$PATH:`pwd`/racket/bin + raco test -l tests/racket/test + racket -l tests/racket/contract/all + raco test -l tests/json/json + raco test -l tests/file/main + raco test -l tests/net/head + raco test -l tests/net/uri-codec + raco test -l tests/net/url + raco test -l tests/net/url-port + raco test -l tests/net/encoders + raco test -l tests/openssl/basic + raco test -l tests/openssl/https + raco test -l tests/match/main + raco test -l tests/zo-path + raco test -c tests/xml + raco test -c tests/future + raco test -l tests/db/all-tests + raco test -c tests/stxparse + raco test -c tests/syntax + + buildtest-macos: + + runs-on: macos-latest + + steps: + - uses: actions/checkout@v2 + - name: Build + run: make CPUS=$(sysctl -n hw.physicalcpu) PKGS="racket-test db-test unstable-flonum-lib net-test" - name: Test run: | export PATH=$PATH:`pwd`/racket/bin @@ -46,7 +76,7 @@ jobs: # Version: VisualStudio/16.3.6+29418.71 # Location: C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: Build working-directory: .\racket\src\worksp shell: cmd diff --git a/.github/workflows/ci-push.yml b/.github/workflows/ci-push_linux.yml similarity index 63% rename from .github/workflows/ci-push.yml rename to .github/workflows/ci-push_linux.yml index 89e9785ffd..69f2de946c 100644 --- a/.github/workflows/ci-push.yml +++ b/.github/workflows/ci-push_linux.yml @@ -1,4 +1,4 @@ -name: CI +name: CI Linux on: [push] @@ -9,23 +9,19 @@ jobs: # component finishes building. build-racketcgc: + runs-on: ubuntu-18.04 + container: + image: racket/racket-ci:builddeps + strategy: fail-fast: false matrix: - os: [ubuntu-18.04, macos-latest] - cify: [cify, nocify] - - runs-on: ${{ matrix.os }} - env: - RACKET_EXTRA_CONFIGURE_ARGS: "" - + cify: [cify, nocify] + steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 with: fetch-depth: 100 - - name: Setup OS specific configure args - if: runner.os == 'macOS' - run: echo "::set-env name=RACKET_EXTRA_CONFIGURE_ARGS::--enable-macprefix $RACKET_EXTRA_CONFIGURE_ARGS" - name: Setup cify if enabled if: matrix.cify == 'cify' run: echo "::set-env name=CIFY_OPTION::--enable-cify" @@ -36,9 +32,8 @@ jobs: working-directory: ./racket/src run: > ./configure - --prefix=${{ runner.temp }}/racketcgc + --prefix=/usr/local/racketcgc --enable-werror - $RACKET_EXTRA_CONFIGURE_ARGS --enable-cgcdefault --enable-jit --enable-foreign @@ -51,47 +46,41 @@ jobs: - name: Building working-directory: ./racket/src run: | - export cpus=$(grep -c ^processor /proc/cpuinfo) + export cpus=$(nproc) make -l $cpus -j $((cpus+1)) - name: Installing working-directory: ./racket/src run: make -j $((cpus+1)) install - name: Tarballing - working-directory: ${{ runner.temp }} - run: tar -cvjf racketcgc-${{ matrix.os }}-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 racketcgc - - uses: actions/upload-artifact@v1 + working-directory: /usr/local + run: tar -cvjf /tmp/racketcgc-debian10-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 racketcgc + - uses: actions/upload-artifact@v2 with: - name: racketcgc-${{ matrix.os }}-${{ matrix.cify }}-x64_git${{ github.sha }} - path: ${{ runner.temp }}/racketcgc-${{ matrix.os }}-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 + name: racketcgc-debian10-${{ matrix.cify }}-x64_git${{ github.sha }} + path: /tmp/racketcgc-debian10-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 build-racket3m: + runs-on: ubuntu-18.04 + container: + image: racket/racket-ci:builddeps + + needs: build-racketcgc + strategy: fail-fast: false matrix: - os: [ubuntu-18.04, macos-latest] - cc: [gcc, clang] cify: [cify, nocify] + cc: [gcc, clang] jit: [jit, nojit] efp: [efp, noefp] exclude: - - os: macos-latest - cc: gcc - jit: nojit efp: efp - - runs-on: ${{ matrix.os }} - needs: build-racketcgc - - env: - RACKET_EXTRA_CONFIGURE_ARGS: "" - + steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 with: fetch-depth: 100 - - name: Setup OS specific configure args - if: runner.os == 'macOS' - run: echo "::set-env name=RACKET_EXTRA_CONFIGURE_ARGS::--enable-macprefix $RACKET_EXTRA_CONFIGURE_ARGS" - name: Setup cify if enabled if: matrix.cify == 'cify' run: echo "::set-env name=CIFY_OPTION::--enable-cify" @@ -110,23 +99,22 @@ jobs: - name: Setup efp if disabled if: matrix.efp == 'noefp' run: echo "::set-env name=EFP_OPTIONS::--disable-extflonums --disable-places --disable-futures" - - uses: actions/download-artifact@v1 + - uses: actions/download-artifact@v2 with: - name: racketcgc-${{ matrix.os }}-nocify-x64_git${{ github.sha }} - path: ${{ runner.temp }} + name: racketcgc-debian10-nocify-x64_git${{ github.sha }} + path: /tmp - name: Untar - working-directory: ${{ runner.temp }} - run: tar -xvjf racketcgc-${{ matrix.os }}-nocify-x64_git${{ github.sha }}.tar.bz2 + working-directory: /usr/local + run: tar -xvjf /tmp/racketcgc-debian10-nocify-x64_git${{ github.sha }}.tar.bz2 - name: Configuring Racket 3m working-directory: ./racket/src env: CC: ${{ matrix.cc }} run: > ./configure - --prefix=${{ runner.temp }}/racket3m + --prefix=/usr/local/racket3m --enable-werror - $RACKET_EXTRA_CONFIGURE_ARGS - --enable-racket=${{ runner.temp }}/racketcgc/bin/racket + --enable-racket=/usr/local/racketcgc/bin/racket --enable-foreign --enable-float --disable-docs @@ -137,7 +125,7 @@ jobs: - name: Building working-directory: ./racket/src run: | - export cpus=$(grep -c ^processor /proc/cpuinfo) + export cpus=$(nproc) make -l $cpus -j $((cpus+1)) - name: Installing working-directory: ./racket/src @@ -147,50 +135,36 @@ jobs: # gcc build only. Therefore this condition ensure we only perform the tarball # and artifact upload on MacOS or (on Linux) if we are building with gcc. - name: Tarballing - if: matrix.cc == 'gcc' || matrix.os == 'macos-latest' - working-directory: ${{ runner.temp }} - run: tar -cvjf racket3m-${{ matrix.os }}-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha}}.tar.bz2 racket3m - - uses: actions/upload-artifact@v1 - if: matrix.cc == 'gcc' || matrix.os == 'macos-latest' + working-directory: /usr/local + run: tar -cvjf /tmp/racket3m-debian10-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha}}.tar.bz2 racket3m + - uses: actions/upload-artifact@v2 + if: matrix.cc == 'gcc' with: - name: racket3m-${{ matrix.os }}-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha }} - path: ${{ runner.temp }}/racket3m-${{ matrix.os }}-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha }}.tar.bz2 + name: racket3m-debian10-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha }} + path: /tmp/racket3m-debian10-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha }}.tar.bz2 build-racketcs: + runs-on: ubuntu-18.04 + container: + image: racket/racket-ci:builddeps + + needs: build-racketcgc + strategy: fail-fast: false matrix: - os: [ubuntu-18.04, macos-latest] cc: [gcc, clang] - exclude: - - os: macos-latest - cc: gcc - - runs-on: ${{ matrix.os }} - needs: build-racketcgc - - env: - RACKET_EXTRA_CONFIGURE_ARGS: "" - steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 with: fetch-depth: 100 - - name: Setup OS specific configure args - if: runner.os == 'macOS' - run: echo "::set-env name=RACKET_EXTRA_CONFIGURE_ARGS::--enable-macprefix $RACKET_EXTRA_CONFIGURE_ARGS" - - uses: actions/download-artifact@v1 + - uses: actions/download-artifact@v2 with: - name: racketcgc-${{ matrix.os }}-nocify-x64_git${{ github.sha }} - path: ${{ runner.temp }} + name: racketcgc-debian10-nocify-x64_git${{ github.sha }} + path: /tmp - name: Untar - working-directory: ${{ runner.temp }} - run: tar -xvjf racketcgc-${{ matrix.os }}-nocify-x64_git${{ github.sha}}.tar.bz2 - - name: Install pkg dependencies - if: runner.os == 'Linux' - run: | - sudo apt update - sudo apt install -y git uuid-dev + working-directory: /usr/local + run: tar -xvjf /tmp/racketcgc-debian10-nocify-x64_git${{ github.sha}}.tar.bz2 - name: Checking out ChezScheme working-directory: ./racket/src run: git clone --depth=1 --recurse-submodules -j3 https://github.com/racket/ChezScheme @@ -200,9 +174,9 @@ jobs: CC: ${{ matrix.cc }} run: > ./configure - --prefix=${{ runner.temp }}/racketcs + --prefix=/usr/local/racketcs $RACKET_EXTRA_CONFIGURE_ARGS - --enable-racket=${{ runner.temp }}/racketcgc/bin/racket + --enable-racket=/usr/local/racketcgc/bin/racket --enable-compress --disable-docs --enable-pthread @@ -211,38 +185,18 @@ jobs: - name: Building working-directory: ./racket/src run: | - export cpus=$(grep -c ^processor /proc/cpuinfo) + export cpus=$(nproc) make -l $cpus -j $((cpus+1)) - name: Installing working-directory: ./racket/src run: make -j $((cpus+1)) install - name: Tarballing - if: matrix.cc == 'gcc' || matrix.os == 'macos-latest' - working-directory: ${{ runner.temp }} - run: tar -cvjf racketcs-${{ matrix.os }}-x64_git${{ github.sha}}.tar.bz2 racketcs - - uses: actions/upload-artifact@v1 - if: matrix.cc == 'gcc' || matrix.os == 'macos-latest' + working-directory: /usr/local + run: tar -cvjf /tmp/racketcs-debian10-x64_git${{ github.sha}}.tar.bz2 racketcs + - uses: actions/upload-artifact@v2 with: - name: racketcs-${{ matrix.os }}-x64_git${{ github.sha }} - path: ${{ runner.temp }}/racketcs-${{ matrix.os }}-x64_git${{ github.sha }}.tar.bz2 - - build-win: - runs-on: windows-latest - - # According to - # https://help.github.com/en/actions/automating-your-workflow-with-github-actions/software-installed-on-github-hosted-runners#windows-server-2019 - # VS2019 is what is installed in the hosted runners: - # Version: VisualStudio/16.3.6+29418.71 - # Location: C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise - steps: - - uses: actions/checkout@v1 - - name: Build - working-directory: .\racket\src\worksp - shell: cmd - run: | - call msvcprep.bat x86_amd64 - call build.bat - call ..\..\racket.exe csbuild.rkt -- --recurse-submodules --depth=1 + name: racketcs-debian10-x64_git${{ github.sha }} + path: /tmp/racketcs-debian10-x64_git${{ github.sha }}.tar.bz2 # Tests # Unfortunately Actions does not support atm yaml anchors @@ -250,28 +204,29 @@ jobs: # Note: the reason we cannot transform this into a matrix # build is because we cannot use variables in the needs keyword. test-cgc: - strategy: - fail-fast: false - matrix: - os: [ubuntu-18.04, macos-latest] - cify: [cify, nocify] - - runs-on: ${{ matrix.os }} + runs-on: ubuntu-18.04 + container: + image: racket/racket-ci:testdeps + options: --init needs: build-racketcgc + strategy: + fail-fast: false + matrix: + cify: [cify, nocify] + steps: - - uses: actions/checkout@v1 - - uses: actions/download-artifact@v1 + - uses: actions/checkout@v2 + - uses: actions/download-artifact@v2 with: - name: racketcgc-${{ matrix.os }}-${{ matrix.cify }}-x64_git${{ github.sha }} - path: ${{ runner.temp }} + name: racketcgc-debian10-${{ matrix.cify }}-x64_git${{ github.sha }} + path: /tmp - name: Untar - working-directory: ${{ runner.temp }} - run: tar -xvjf racketcgc-${{ matrix.os }}-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 + working-directory: /usr/local + run: tar -xvjf /tmp/racketcgc-debian10-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 - name: Extend PATH with Racket executable - working-directory: ${{ runner.temp }} - run: echo "::set-env name=PATH::$PWD/racketcgc/bin:$PATH" + run: echo "::set-env name=PATH::/usr/local/racketcgc/bin:$PATH" - name: Check for Racket run: racket --version - name: Install catalog @@ -320,10 +275,16 @@ jobs: run: raco test -c tests/syntax test-3m: + runs-on: ubuntu-18.04 + container: + image: racket/racket-ci:testdeps + options: --init + + needs: build-racket3m + strategy: fail-fast: false matrix: - os: [ubuntu-18.04, macos-latest] cify: [cify, nocify] jit: [jit, nojit] efp: [efp, noefp] @@ -331,22 +292,17 @@ jobs: - jit: nojit efp: efp - runs-on: ${{ matrix.os }} - - needs: build-racket3m - steps: - - uses: actions/checkout@v1 - - uses: actions/download-artifact@v1 + - uses: actions/checkout@v2 + - uses: actions/download-artifact@v2 with: - name: racket3m-${{ matrix.os }}-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha }} - path: ${{ runner.temp }} + name: racket3m-debian10-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha }} + path: /tmp - name: Untar - working-directory: ${{ runner.temp }} - run: tar -xvjf racket3m-${{ matrix.os }}-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha }}.tar.bz2 + working-directory: /usr/local + run: tar -xvjf /tmp/racket3m-debian10-${{ matrix.cify }}-${{ matrix.jit }}-${{ matrix.efp }}-x64_git${{ github.sha }}.tar.bz2 - name: Extend PATH with Racket executable - working-directory: ${{ runner.temp }} - run: echo "::set-env name=PATH::$PWD/racket3m/bin:$PATH" + run: echo "::set-env name=PATH::/usr/local/racket3m/bin:$PATH" - name: Check for Racket run: racket --version - name: Install catalog and required packages @@ -393,27 +349,24 @@ jobs: run: raco test -l tests/db/all-tests test-cs: - strategy: - fail-fast: false - matrix: - os: [ubuntu-18.04, macos-latest] - - runs-on: ${{ matrix.os }} + runs-on: ubuntu-18.04 + container: + image: racket/racket-ci:testdeps + options: --init needs: build-racketcs steps: - - uses: actions/checkout@v1 - - uses: actions/download-artifact@v1 + - uses: actions/checkout@v2 + - uses: actions/download-artifact@v2 with: - name: racketcs-${{ matrix.os }}-x64_git${{ github.sha }} - path: ${{ runner.temp }} + name: racketcs-debian10-x64_git${{ github.sha }} + path: /tmp - name: Untar - working-directory: ${{ runner.temp }} - run: tar -xvjf racketcs-${{ matrix.os }}-x64_git${{ github.sha }}.tar.bz2 + working-directory: /usr/local + run: tar -xvjf /tmp/racketcs-debian10-x64_git${{ github.sha }}.tar.bz2 - name: Extend PATH with Racket executable - working-directory: ${{ runner.temp }} - run: echo "::set-env name=PATH::$PWD/racketcs/bin:$PATH" + run: echo "::set-env name=PATH::/usr/local/racketcs/bin:$PATH" - name: Check for Racket run: racket --version - name: Install catalog and required packages diff --git a/.github/workflows/ci-push_macos.yml b/.github/workflows/ci-push_macos.yml new file mode 100644 index 0000000000..8f8dd0da26 --- /dev/null +++ b/.github/workflows/ci-push_macos.yml @@ -0,0 +1,368 @@ +name: CI MacOS + +on: [push] + +jobs: + +# Build jobs +# These jobs build each Racket component separately and tests on the component start as soon as each +# component finishes building. + + build-racketcgc: + strategy: + fail-fast: false + matrix: + cify: [cify, nocify] + + runs-on: macos-latest + env: + RACKET_EXTRA_CONFIGURE_ARGS: "" + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 100 + - name: Setup cify if enabled1 + if: matrix.cify == 'cify' + run: echo "::set-env name=CIFY_OPTION::--enable-cify" + - name: Setup cify if disabled + if: matrix.cify == 'nocify' + run: echo "::set-env name=CIFY_OPTION::--disable-cify" + - name: Configuring Racket CGC + working-directory: ./racket/src + run: > + ./configure + --prefix=$GITHUB_WORKSPACE/racketcgc + $RACKET_EXTRA_CONFIGURE_ARGS + --enable-cgcdefault + --enable-jit + --enable-foreign + --enable-macprefix + --enable-places + --enable-futures + --enable-float + $CIFY_OPTION + --enable-pthread + --disable-docs + - name: Building + working-directory: ./racket/src + run: | + export cpus=$(sysctl -n hw.physicalcpu) + make CFLAGS="-Werror" -l $cpus -j $((cpus+1)) + - name: Installing + working-directory: ./racket/src + run: make -j $((cpus+1)) install + - name: Tarballing + working-directory: ${{ github.workspace }} + run: tar -cvjf racketcgc-macos-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 racketcgc + - uses: actions/upload-artifact@v2 + with: + name: racketcgc-macos-${{ matrix.cify }}-x64_git${{ github.sha }} + path: ${{ github.workspace }}/racketcgc-macos-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 + + build-racket3m: + strategy: + fail-fast: false + matrix: + cify: [cify, nocify] + + runs-on: macos-latest + + needs: build-racketcgc + + env: + RACKET_EXTRA_CONFIGURE_ARGS: "" + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 100 + - name: Setup cify if enabled + if: matrix.cify == 'cify' + run: echo "::set-env name=CIFY_OPTION::--enable-cify" + - name: Setup cify if disabled + if: matrix.cify == 'nocify' + run: echo "::set-env name=CIFY_OPTION::--disable-cify" + - uses: actions/download-artifact@v2 + with: + name: racketcgc-macos-nocify-x64_git${{ github.sha }} + path: ${{ runner.temp }} + - name: Untar + working-directory: ${{ github.workspace }} + run: tar -xvjf ${{ runner.temp }}/racketcgc-macos-nocify-x64_git${{ github.sha }}.tar.bz2 + - name: Configuring Racket 3m + working-directory: ./racket/src + env: + CC: clang + run: > + ./configure + --prefix=$GITHUB_WORKSPACE/racket3m + $RACKET_EXTRA_CONFIGURE_ARGS + --enable-racket=$GITHUB_WORKSPACE/racketcgc/bin/racket + --enable-jit + --enable-foreign + --enable-macprefix + --enable-places + --enable-futures + --enable-float + --disable-docs + $CIFY_OPTION + --enable-pthread + - name: Building + working-directory: ./racket/src + run: | + export cpus=$(sysctl -n hw.physicalcpu) + make CFLAGS="-Werror" -l $cpus -j $((cpus+1)) + - name: Installing + working-directory: ./racket/src + run: make -j $((cpus+1)) install + - name: Tarballing + working-directory: ${{ github.workspace }} + run: tar -cvjf racket3m-macos-${{ matrix.cify }}-x64_git${{ github.sha}}.tar.bz2 racket3m + - uses: actions/upload-artifact@v2 + with: + name: racket3m-macos-${{ matrix.cify }}-x64_git${{ github.sha }} + path: ${{ github.workspace }}/racket3m-macos-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 + + build-racketcs: + runs-on: macos-latest + needs: build-racketcgc + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 100 + - uses: actions/download-artifact@master + with: + name: racketcgc-macos-nocify-x64_git${{ github.sha }} + path: ${{ runner.temp }} + - name: Untar + working-directory: ${{ github.workspace }} + run: tar -xvjf ${{ runner.temp }}/racketcgc-macos-nocify-x64_git${{ github.sha}}.tar.bz2 + - name: Checking out ChezScheme + working-directory: ./racket/src + run: git clone --depth=1 --recurse-submodules -j3 https://github.com/racket/ChezScheme + - name: Configuring Racket CS + working-directory: ./racket/src + env: + CC: ${{ matrix.cc }} + run: > + ./configure + --prefix=$GITHUB_WORKSPACE/racketcs + --enable-racket=$GITHUB_WORKSPACE/racketcgc/bin/racket + --enable-macprefix + --enable-compress + --disable-docs + --enable-pthread + --enable-csdefault + --enable-csonly + - name: Building + working-directory: ./racket/src + run: | + export cpus=$(sysctl -n hw.physicalcpu) + make -l $cpus -j $((cpus+1)) + - name: Installing + working-directory: ./racket/src + run: make -j $((cpus+1)) install + - name: Tarballing + working-directory: ${{ github.workspace }} + run: tar -cvjf racketcs-macos-x64_git${{ github.sha}}.tar.bz2 racketcs + - uses: actions/upload-artifact@v2 + with: + name: racketcs-macos-x64_git${{ github.sha }} + path: ${{ github.workspace }}/racketcs-macos-x64_git${{ github.sha }}.tar.bz2 + + # Tests + # Unfortunately Actions does not support atm yaml anchors + # otherwise all the following jobs could be simplified + # Note: the reason we cannot transform this into a matrix + # build is because we cannot use variables in the needs keyword. + test-cgc: + strategy: + fail-fast: false + matrix: + cify: [cify, nocify] + + runs-on: macos-latest + + needs: build-racketcgc + + steps: + - uses: actions/checkout@v2 + - uses: actions/download-artifact@v2 + with: + name: racketcgc-macos-${{ matrix.cify }}-x64_git${{ github.sha }} + path: ${{ github.workspace }} + - name: Untar + working-directory: ${{ github.workspace }} + run: tar -xvjf racketcgc-macos-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 + - name: Extend PATH with Racket executable + working-directory: ${{ github.workspace }} + run: echo "::set-env name=PATH::$PWD/racketcgc/bin:$PATH" + - name: Check for Racket + run: racket --version + - name: Install catalog + run: | + racket -l- pkg/dirs-catalog --immediate $PWD/rktcat $PWD/pkgs/ + raco pkg config --set catalogs $PWD/rktcat/ https://pkgs.racket-lang.org https://planet-compats.racket-lang.org + - name: Install racket-test dependency + run: raco pkg install --auto racket-test + - name: Run tests/racket/test + run: raco test -l tests/racket/test + - name: Run tests/racket/contract/all + run: racket -l tests/racket/contract/all + - name: Run tests/json/json + run: raco test -l tests/json/json + - name: Run tests/file/main + run: raco test -l tests/file/main + - name: Run tests/net/head + run: raco test -l tests/net/head + - name: Run tests/net/uri-codec + run: raco test -l tests/net/uri-codec + - name: Run tests/net/url + run: raco test -l tests/net/url + - name: Run tests/net/url-port + run: raco test -l tests/net/url-port + - name: Run tests/net/encoders + run: raco test -l tests/net/encoders + - name: Run tests/openssl/basic + run: raco test -l tests/openssl/basic + - name: Run tests/openssl/https + run: raco test -l tests/openssl/https + - name: Run tests/match/main + run: raco test -l tests/match/main + - name: Run tests/zo-path + run: raco test -l tests/zo-path + - name: Run tests/xml + run: raco test -c tests/xml + - name: Run tests/stxparse + run: raco test -c tests/stxparse + - name: Install db tests dependency + run: raco pkg install --auto db-test + - name: Run db tests + run: raco test -l tests/db/all-tests + + test-3m: + strategy: + fail-fast: false + matrix: + cify: [cify, nocify] + + runs-on: macos-latest + + needs: build-racket3m + + steps: + - uses: actions/checkout@v2 + - uses: actions/download-artifact@master + with: + name: racket3m-macos-${{ matrix.cify }}-x64_git${{ github.sha }} + path: ${{ github.workspace }} + - name: Untar + working-directory: ${{ github.workspace }} + run: tar -xvjf racket3m-macos-${{ matrix.cify }}-x64_git${{ github.sha }}.tar.bz2 + - name: Extend PATH with Racket executable + working-directory: ${{ github.workspace }} + run: echo "::set-env name=PATH::$PWD/racket3m/bin:$PATH" + - name: Check for Racket + run: racket --version + - name: Install catalog and required packages + run: | + racket -l- pkg/dirs-catalog --immediate $PWD/rktcat $PWD/pkgs/ + raco pkg config --set catalogs $PWD/rktcat/ https://pkgs.racket-lang.org https://planet-compats.racket-lang.org + - name: Install racket-test dependency + run: raco pkg install --auto racket-test + - name: Run tests/racket/test + run: raco test -l tests/racket/test + - name: Run tests/racket/contract/all + run: racket -l tests/racket/contract/all + - name: Run tests/json/json + run: raco test -l tests/json/json + - name: Run tests/file/main + run: raco test -l tests/file/main + - name: Run tests/net/head + run: raco test -l tests/net/head + - name: Run tests/net/uri-codec + run: raco test -l tests/net/uri-codec + - name: Run tests/net/url + run: raco test -l tests/net/url + - name: Run tests/net/url-port + run: raco test -l tests/net/url-port + - name: Run tests/net/encoders + run: raco test -l tests/net/encoders + - name: Run tests/openssl/basic + run: raco test -l tests/openssl/basic + - name: Run tests/openssl/https + run: raco test -l tests/openssl/https + - name: Run tests/match/main + run: raco test -l tests/match/main + - name: Run tests/zo-path + run: raco test -l tests/zo-path + - name: Run tests/xml + run: raco test -c tests/xml + - name: Run tests/stxparse + run: raco test -c tests/stxparse + - name: Install db tests dependency + run: raco pkg install --auto db-test + - name: Run db tests + run: raco test -l tests/db/all-tests + + test-cs: + runs-on: macos-latest + + needs: build-racketcs + + steps: + - uses: actions/checkout@v2 + - uses: actions/download-artifact@v2 + with: + name: racketcs-macos-x64_git${{ github.sha }} + path: ${{ github.workspace }} + - name: Untar + working-directory: ${{ github.workspace }} + run: tar -xvjf racketcs-macos-x64_git${{ github.sha }}.tar.bz2 + - name: Extend PATH with Racket executable + working-directory: ${{ github.workspace }} + run: echo "::set-env name=PATH::$PWD/racketcs/bin:$PATH" + - name: Check for Racket + run: racket --version + - name: Install catalog and required packages + run: | + racket -l- pkg/dirs-catalog --immediate $PWD/rktcat $PWD/pkgs/ + raco pkg config --set catalogs $PWD/rktcat/ https://pkgs.racket-lang.org https://planet-compats.racket-lang.org + - name: Install racket-test dependency + run: raco pkg install --auto racket-test + - name: Run tests/racket/test + run: raco test -l tests/racket/test + - name: Run tests/racket/contract/all + run: racket -l tests/racket/contract/all + - name: Run tests/json/json + run: raco test -l tests/json/json + - name: Run tests/file/main + run: raco test -l tests/file/main + - name: Run tests/net/head + run: raco test -l tests/net/head + - name: Run tests/net/uri-codec + run: raco test -l tests/net/uri-codec + - name: Run tests/net/url + run: raco test -l tests/net/url + - name: Run tests/net/url-port + run: raco test -l tests/net/url-port + - name: Run tests/net/encoders + run: raco test -l tests/net/encoders + - name: Run tests/openssl/basic + run: raco test -l tests/openssl/basic + - name: Run tests/openssl/https + run: raco test -l tests/openssl/https + - name: Run tests/match/main + run: raco test -l tests/match/main + - name: Run tests/zo-path + run: raco test -l tests/zo-path + - name: Run tests/xml + run: raco test -c tests/xml + - name: Run tests/stxparse + run: raco test -c tests/stxparse + - name: Install db tests dependency + run: raco pkg install --auto db-test + - name: Run db tests + run: raco test -l tests/db/all-tests diff --git a/.github/workflows/ci-push_win.yml b/.github/workflows/ci-push_win.yml new file mode 100644 index 0000000000..bf01bb0cd5 --- /dev/null +++ b/.github/workflows/ci-push_win.yml @@ -0,0 +1,27 @@ +name: CI Win + +on: [push] + +jobs: + +# Build jobs +# These jobs build each Racket component separately and tests on the component start as soon as each +# component finishes building. + + build-win: + runs-on: windows-latest + + # According to + # https://help.github.com/en/actions/automating-your-workflow-with-github-actions/software-installed-on-github-hosted-runners#windows-server-2019 + # VS2019 is what is installed in the hosted runners: + # Version: VisualStudio/16.3.6+29418.71 + # Location: C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise + steps: + - uses: actions/checkout@v2 + - name: Build + working-directory: .\racket\src\worksp + shell: cmd + run: | + call msvcprep.bat x86_amd64 + call build.bat + call ..\..\racket.exe csbuild.rkt -- --recurse-submodules --depth=1