From a5569eeb48d0b5258bd440fb4a70429936aef859 Mon Sep 17 00:00:00 2001 From: Ioannis Tsakpinis Date: Thu, 24 Sep 2020 21:09:54 +0300 Subject: [PATCH] CI configuration --- .gitattributes | 1 + .github/workflows/CI.yml | 164 +++++ DISABLED.appveyor.yml | 52 ++ DISABLED.travis.yml | 152 +++++ config/build-bindings.xml | 10 +- config/macos/build.xml | 582 +++++++++--------- .../lwjgl/meow/src/main/c/meow_intrinsics.h | 4 +- 7 files changed, 672 insertions(+), 293 deletions(-) create mode 100644 .gitattributes create mode 100644 .github/workflows/CI.yml create mode 100644 DISABLED.appveyor.yml create mode 100644 DISABLED.travis.yml diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000000..7745062629 --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +* -text diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml new file mode 100644 index 0000000000..c376409a27 --- /dev/null +++ b/.github/workflows/CI.yml @@ -0,0 +1,164 @@ +name: LWJGL Build + +on: + push: + branches: + - master + +env: + AWS_DEFAULT_REGION: us-east-1 + AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + S3_PARAMS: --acl public-read --cache-control "public,must-revalidate,proxy-revalidate,max-age=0" + ANT_OPTS: -Xmx1G + +jobs: + linux: + name: Linux + runs-on: ubuntu-16.04 + strategy: + fail-fast: false + matrix: + ARCH: [x64, arm32, arm64] + include: + # ----- + - ARCH: x64 + PACKAGES: gcc-4.8 g++-4.8 gcc-4.9 g++-4.9 xorg-dev libgtk-3-dev libglu-dev libgl1-mesa-glx libx11-dev + NATIVE_PARAMS: -Dgcc.libpath.opengl=/usr/lib/x86_64-linux-gnu/mesa + - ARCH: arm32 + PACKAGES: gcc-4.8-arm-linux-gnueabihf g++-4.8-arm-linux-gnueabihf gcc-4.9-arm-linux-gnueabihf g++-4.9-arm-linux-gnueabihf libc6-dev-armhf-cross + CROSS_ARCH: armhf + CROSS_PACKAGES: libglu-dev:armhf libgl1-mesa-glx:armhf libx11-dev:armhf + NATIVE_PARAMS: -Dgcc.libpath.opengl=/usr/lib/arm-linux-gnueabihf/mesa + - ARCH: arm64 + PACKAGES: gcc-4.8-aarch64-linux-gnu g++-4.8-aarch64-linux-gnu gcc-4.9-aarch64-linux-gnu g++-4.9-aarch64-linux-gnu libc6-dev-arm64-cross + CROSS_ARCH: arm64 + CROSS_PACKAGES: libglu-dev:arm64 libgl1-mesa-glx:arm64 libx11-dev:arm64 + NATIVE_PARAMS: -Dgcc.libpath.opengl=/usr/lib/aarch64-linux-gnu/mesa + env: + JAVA_HOME: jdk8 + LWJGL_BUILD_TYPE: nightly + LWJGL_BUILD_ARCH: ${{matrix.ARCH}} + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 3 + - run: | + sudo apt-get -yq install ${{matrix.PACKAGES}} + curl https://cdn.azul.com/zulu/bin/zulu8.52.0.23-ca-fx-jdk8.0.282-linux_x64.tar.gz --output jdk8.tar.gz + mkdir jdk8 + tar xf jdk8.tar.gz -C jdk8 --strip-components 1 + name: Install dependencies + - run: | + if [[ "${{matrix.ARCH}}" != "mips64" ]] + then + sudo sed -i 's/deb http/deb [arch=amd64,i386] http/' /etc/apt/sources.list + sudo grep "ubuntu.com/ubuntu" /etc/apt/sources.list | sudo tee /etc/apt/sources.list.d/ports.list + sudo sed -i 's/amd64,i386/armhf,arm64/' /etc/apt/sources.list.d/ports.list + sudo sed -i 's#http://.*/ubuntu#http://ports.ubuntu.com/ubuntu-ports#' /etc/apt/sources.list.d/ports.list + else + sudo apt-get -yq install gcc-5-mips64el-linux-gnuabi64 libc6-dev-mips64el-cross + sudo rm -rf /etc/apt/sources.list + sudo sh -c "echo 'deb http://deb.debian.org/debian buster main' >> /etc/apt/sources.list" + fi + sudo dpkg --add-architecture ${{matrix.CROSS_ARCH}} + sudo apt-get update || true + if: contains(matrix.ARCH, 'x64') != true + name: Prepare cross-compilation + - run: sudo apt-get -yq --allow-unauthenticated --no-install-suggests --no-install-recommends install ${{matrix.CROSS_PACKAGES}} -o Dpkg::Options::="--force-overwrite" + if: contains(matrix.ARCH, 'x64') != true + name: Install cross-compilation dependencies + - run: ant hydrate-kotlinc clean-generated generate + name: Hydrate generator + - run: ant compile + name: Build Java + - run: ant compile-native -Dgcc.version=4.8 ${{matrix.NATIVE_PARAMS}} + name: Build native + - run: ant tests + name: Run tests + - run: ant upload-native + name: Upload artifacts + + macos: + name: macOS + runs-on: macos-latest + strategy: + fail-fast: false + matrix: + ARCH: [x64, arm64] + include: + - ARCH: x64 + CMAKE_PARAMS: -DCMAKE_OSX_DEPLOYMENT_TARGET=10.9 + - ARCH: arm64 + CMAKE_PARAMS: -DCMAKE_OSX_DEPLOYMENT_TARGET=10.9 + env: + JAVA_HOME: jdk8 + LWJGL_BUILD_TYPE: nightly + LWJGL_BUILD_ARCH: ${{matrix.ARCH}} + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 3 + - run: | + curl https://cdn.azul.com/zulu/bin/zulu8.52.0.23-ca-fx-jdk8.0.282-macosx_x64.tar.gz --output jdk8.tar.gz + mkdir jdk8 + tar xf jdk8.tar.gz -C jdk8 --strip-components 1 + name: Install dependencies + - run: ant hydrate-kotlinc clean-generated generate + name: Hydrate generator + - run: ant compile + name: Build Java + - run: ant compile-native + name: Build native + - run: ant tests + name: Run tests + - run: ant upload-native + name: Upload artifacts + + windows: + name: Windows + runs-on: windows-latest + strategy: + fail-fast: false + matrix: + ARCH: [x86, x64, arm64] + include: + - ARCH: x86 + JDK: zulu8.52.0.23-ca-fx-jdk8.0.282-win_i686 + MSVC_ARCH: amd64_x86 + - ARCH: x64 + JDK: zulu8.52.0.23-ca-fx-jdk8.0.282-win_x64 + MSVC_ARCH: amd64 + - ARCH: arm64 + JDK: zulu8.52.0.23-ca-fx-jdk8.0.282-win_x64 + MSVC_ARCH: amd64_arm64 + env: + JAVA_HOME: ${{matrix.JDK}} + LWJGL_BUILD_TYPE: nightly + LWJGL_BUILD_ARCH: ${{matrix.ARCH}} + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 3 + - run: | + git clone https://github.com/LWJGL-CI/OculusSDK.git ../OculusSDK + Invoke-WebRequest https://cdn.azul.com/zulu/bin/${{matrix.JDK}}.zip -OutFile jdk.zip + Expand-Archive -Path jdk.zip -DestinationPath .\ + name: Install dependencies + - run: ant hydrate-kotlinc clean-generated generate + shell: cmd + name: Generate bindings + - run: ant compile + shell: cmd + name: Build Java + - run: | + call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{matrix.MSVC_ARCH}} + ant compile-native + shell: cmd + name: Build native + - run: ant tests + shell: cmd + name: Run tests + - run: ant upload-native + shell: cmd + name: Upload artifacts \ No newline at end of file diff --git a/DISABLED.appveyor.yml b/DISABLED.appveyor.yml new file mode 100644 index 0000000000..af98f2c61b --- /dev/null +++ b/DISABLED.appveyor.yml @@ -0,0 +1,52 @@ +version: '{build}' +skip_tags: true +image: Visual Studio 2019 +clone_depth: 3 +environment: + AWS_ACCESS_KEY_ID: + secure: 7jhk0oV/vjFsOcsAHLMUcNGUGLuGmnuPxGH0ce/Vky8= + AWS_SECRET_ACCESS_KEY: + secure: 5KKYpsIHwYHHh5ud0U7Ss0rLumv6G8tkS6abh1B9aq4wY6+1kq5fN/3E5BsdBVKy + AWS_DEFAULT_REGION: us-east-1 + ANT_OPTS: -Xmx1G + matrix: + - ARCH: x64 + PLATFORM: amd64 + JAVA_HOME: C:\Program Files\Java\jdk1.8.0 + - ARCH: x86 + PLATFORM: amd64_x86 + JAVA_HOME: C:\Program Files (x86)\Java\jdk1.8.0 +matrix: + fast_finish: true +build_script: +- cmd: >- + appveyor DownloadFile https://www.apache.org/dist/ant/binaries/%APACHE_ANT%-bin.zip -FileName ant.zip + + 7z x ant.zip + + move %APACHE_ANT% ant + + set PATH=%PATH%;ant\bin + + "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvarsall.bat" %PLATFORM% + + git clone https://github.com/LWJGL-CI/OculusSDK.git ../OculusSDK + + ant hydrate-kotlinc + + ant compile + + ant compile-native + + ant tests + + ant upload-native +test: off +notifications: +- provider: Email + to: + - iotsakp@gmail.com + subject: LWJGL 3 CI + on_build_success: true + on_build_failure: true + on_build_status_changed: true \ No newline at end of file diff --git a/DISABLED.travis.yml b/DISABLED.travis.yml new file mode 100644 index 0000000000..62592fffa4 --- /dev/null +++ b/DISABLED.travis.yml @@ -0,0 +1,152 @@ +git: + depth: 3 +env: + global: + - secure: "AzM98HKS2RDP+/WdvsFiEqTbVPwLBEAtNXDQPR7cV1gAEZoNhri/iINnRAHtECgVQDt2gKmxEiyOA07zMKPpt5PwhoyZUnICwxl1t2FOkTL4LlfI+3ew1rf4F8wmaSQX/BRT7b3IgyEI0RFRCow8KH49X8xdEtAFYJB3YFu2Y6M=" + - secure: "BDNmD9y3mdZEQoFgXW2dC1FawofkThFwbITidMqeKLxSstNxQGKCpxOFAV604kaTGsf7ihpdm8WYE5IjHKTaoewdQ9hLXZPtswWXq5Ebe2gKHqJVNZa2bFD6hQBD2S7BLWWeAVIoLkyfV/QLnplOquUZTXWZ3TW2A+IXzQE+AnE=" + - AWS_DEFAULT_REGION: "us-east-1" + - JDK_LINUX: https://cdn.azul.com/zulu/bin/zulu8.48.0.53-ca-fx-jdk8.0.265-linux_x64.tar.gz + - JDK_MACOS: https://cdn.azul.com/zulu/bin/zulu8.48.0.53-ca-fx-jdk8.0.265-macosx_x64.tar.gz + - ANT_OPTS: -Xmx1G + +matrix: + include: + + # ----------------- + - name: "Linux x64" + # ----------------- + dist: xenial + language: java + + addons: + apt: + packages: + - ant + - gcc-4.8 + - g++-4.8 + - gcc-4.9 + - g++-4.9 + - xorg-dev + - libgtk-3-dev + - libglu-dev + - libgl1-mesa-glx + - libx11-dev + + before_install: + - pip install --user awscli + - export PATH=$PATH:$HOME/.local/bin + + script: + - export LWJGL_BUILD_TYPE=nightly + - curl $JDK_LINUX --output jdk8.tar.gz + - mkdir jdk8 && tar xf jdk8.tar.gz -C jdk8 --strip-components 1 + - export JAVA_HOME=$TRAVIS_BUILD_DIR/jdk8 + - ant hydrate-kotlinc + - ant compile + - ant compile-native -Dgcc.version=4.8 -Dgcc.libpath.opengl=/usr/lib/x86_64-linux-gnu/mesa + - ant tests + - ant upload-native + + # ----------------- + - name: "Linux arm32" + # ----------------- + dist: xenial + language: java + + addons: + apt: + packages: + - ant + - gcc-4.8-arm-linux-gnueabihf + - g++-4.8-arm-linux-gnueabihf + - gcc-4.9-arm-linux-gnueabihf + - g++-4.9-arm-linux-gnueabihf + - libc6-dev-armhf-cross + + before_install: + - pip install --user awscli + - export PATH=$PATH:$HOME/.local/bin + - sudo sed -i 's/deb http/deb [arch=amd64,i386] http/' /etc/apt/sources.list + - sudo grep "ubuntu.com/ubuntu" /etc/apt/sources.list | sudo tee /etc/apt/sources.list.d/ports.list + - sudo sed -i 's/amd64,i386/armhf,arm64/' /etc/apt/sources.list.d/ports.list + - sudo sed -i 's#http://.*/ubuntu#http://ports.ubuntu.com/ubuntu-ports#' /etc/apt/sources.list.d/ports.list + - sudo dpkg --add-architecture armhf + - sudo apt-get update || true + - sudo apt-get -yq install libglu-dev:armhf libgl1-mesa-glx:armhf libx11-dev:armhf -o Dpkg::Options::="--force-overwrite" + + script: + - export LWJGL_BUILD_TYPE=nightly + - export LWJGL_BUILD_ARCH=arm32 + - curl $JDK_LINUX --output jdk8.tar.gz + - mkdir jdk8 && tar xf jdk8.tar.gz -C jdk8 --strip-components 1 + - export JAVA_HOME=$TRAVIS_BUILD_DIR/jdk8 + - ant hydrate-kotlinc + - ant compile + - ant compile-native -Dgcc.version=4.8 -Dgcc.libpath.opengl=/usr/lib/arm-linux-gnueabihf/mesa + - ant tests + - ant upload-native + + # ----------------- + - name: "Linux arm64" + # ----------------- + dist: xenial + language: java + jdk: openjdk8 + + addons: + apt: + packages: + - ant + - gcc-4.8-aarch64-linux-gnu + - g++-4.8-aarch64-linux-gnu + - gcc-4.9-aarch64-linux-gnu + - g++-4.9-aarch64-linux-gnu + - libc6-dev-arm64-cross + + before_install: + - pip install --user awscli + - export PATH=$PATH:$HOME/.local/bin + - sudo sed -i 's/deb http/deb [arch=amd64,i386] http/' /etc/apt/sources.list + - sudo grep "ubuntu.com/ubuntu" /etc/apt/sources.list | sudo tee /etc/apt/sources.list.d/ports.list + - sudo sed -i 's/amd64,i386/armhf,arm64/' /etc/apt/sources.list.d/ports.list + - sudo sed -i 's#http://.*/ubuntu#http://ports.ubuntu.com/ubuntu-ports#' /etc/apt/sources.list.d/ports.list + - sudo dpkg --add-architecture arm64 + - sudo apt-get update || true + - sudo apt-get -yq install libglu-dev:arm64 libgl1-mesa-glx:arm64 libx11-dev:arm64 -o Dpkg::Options::="--force-overwrite" + + script: + - export LWJGL_BUILD_TYPE=nightly + - export LWJGL_BUILD_ARCH=arm64 + - curl $JDK_LINUX --output jdk8.tar.gz + - mkdir jdk8 && tar xf jdk8.tar.gz -C jdk8 --strip-components 1 + - export JAVA_HOME=$TRAVIS_BUILD_DIR/jdk8 + - ant hydrate-kotlinc + - ant compile + - ant compile-native -Dgcc.version=4.8 -Dgcc.libpath.opengl=/usr/lib/aarch64-linux-gnu/mesa + - ant tests + - ant upload-native + + # ----------------- + - name: "macOS" + # ----------------- + language: objective-c + osx_image: xcode11.3 + compiler: clang + + before_install: + - brew update + + install: + - brew install ant + - brew install awscli + + script: + - export LWJGL_BUILD_TYPE=nightly + - curl $JDK_MACOS --output jdk8.tar.gz + - mkdir jdk8 && tar xf jdk8.tar.gz -C jdk8 --strip-components 1 + - export JAVA_HOME=$TRAVIS_BUILD_DIR/jdk8 + - ant hydrate-kotlinc + - ant compile + - ant compile-native + - ant tests + - ant upload-native \ No newline at end of file diff --git a/config/build-bindings.xml b/config/build-bindings.xml index 14abb3d770..9cc3743eeb 100644 --- a/config/build-bindings.xml +++ b/config/build-bindings.xml @@ -15,8 +15,13 @@ This script is included in /config/build-definitions.xml. - - + + + + + + + @@ -74,6 +79,7 @@ This script is included in /config/build-definitions.xml. + diff --git a/config/macos/build.xml b/config/macos/build.xml index ffe75f9339..94d5936be4 100644 --- a/config/macos/build.xml +++ b/config/macos/build.xml @@ -41,7 +41,9 @@ - + + + @@ -63,6 +65,7 @@ + @@ -121,10 +124,10 @@ - - - - + + + + @@ -137,6 +140,7 @@ + @@ -162,283 +166,283 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + - + + + + - - - - - - - - - - - - - - - + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -455,18 +459,18 @@ - - - - - - - - - - - - + + + + + + + + + + + + diff --git a/modules/lwjgl/meow/src/main/c/meow_intrinsics.h b/modules/lwjgl/meow/src/main/c/meow_intrinsics.h index f9c6ff3596..2b1e1554e2 100644 --- a/modules/lwjgl/meow/src/main/c/meow_intrinsics.h +++ b/modules/lwjgl/meow/src/main/c/meow_intrinsics.h @@ -150,9 +150,9 @@ typedef struct { static int MeowHashesAreEqualImpl(meow_u128 A, meow_u128 B) { - uint8x16_t Powers = { + uint8x16_t Powers = {.n128_u8={ 1, 2, 4, 8, 16, 32, 64, 128, 1, 2, 4, 8, 16, 32, 64, 128, - }; + }}; uint8x16_t Input = vceqq_u8(A, B); uint64x2_t Mask = vpaddlq_u32(vpaddlq_u16(vpaddlq_u8(vandq_u8(Input, Powers))));