Skip to content

Revert "Bump jni from 0.19.0 to 0.21.1 in /native (#131)" (#151) #350

Revert "Bump jni from 0.19.0 to 0.21.1 in /native (#131)" (#151)

Revert "Bump jni from 0.19.0 to 0.21.1 in /native (#131)" (#151) #350

Workflow file for this run

# This workflow will build the browser and publish it to GitHub Packages
name: Build browser
on: push
env:
RUSTFLAGS: "-Dwarnings"
jobs:
browser-jni:
runs-on: windows-2022
steps:
- uses: actions/checkout@v4
- name: Set up Workspace
run: |
mkdir -p cef/Release
rm -rf java/org.eclipse.set.browser.cef.win32/res/cef
mkdir -p java/org.eclipse.set.browser.cef.win32/res/cef
mkdir -p java/org.eclipse.set.browser.lib/res
shell: bash
- name: Cache CEF
id: cef-cache
uses: actions/cache@v4
with:
path: |
java/org.eclipse.set.browser.cef.win32/res/cef
cef/Release/libcef.lib
cef/Release/LICENSE.txt
cef/include
key: ${{ hashFiles('CEF_VERSION.txt') }}
- name: Download CEF
if: steps.cef-cache.outputs.cache-hit != 'true'
run: |
VERSION=$(grep -E -v ^# ../CEF_VERSION.txt)
curl -o cef.tar.bz2 https://cef-builds.spotifycdn.com/$VERSION.tar.bz2
tar xf cef.tar.bz2 $VERSION/include --strip-components 1
working-directory: cef
shell: bash
- name: Extract CEF
if: steps.cef-cache.outputs.cache-hit != 'true'
run: |
VERSION=$(grep -E -v ^# ../../CEF_VERSION.txt)
tar xf ../cef.tar.bz2 $VERSION/LICENSE.txt $VERSION/Resources --strip-components 1
tar xf ../cef.tar.bz2 $VERSION/Release/libcef.lib --strip-components 2
tar xf ../cef.tar.bz2 --wildcards $VERSION/Release/*.dll --wildcards $VERSION/Release/*.bin --strip-components 2
cp -r *.dll *.bin Resources/* LICENSE.txt ../../java/org.eclipse.set.browser.cef.win32/res/cef
working-directory: cef/Release
shell: bash
- name: Build Rust
run: cargo clean && cargo clippy --all-features && cargo build --release --features gen
working-directory: native
shell: bash
- name: Archive binaries
uses: actions/upload-artifact@v4
with:
name: chromium-swt-libs
path: native/target/release/chromium_*.*
retention-days: 1
build:
needs:
- browser-jni
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
- name: Setup Java
uses: eclipse-set/build/.github/actions/setup-java@main
- name: Set up Workspace
run: |
mkdir -p cef/Release
rm -rf java/org.eclipse.set.browser.cef.win32/res/cef
mkdir -p java/org.eclipse.set.browser.cef.win32/res/cef
mkdir -p java/org.eclipse.set.browser.lib/res
- name: Cache CEF
id: cef-cache
uses: actions/cache@v4
with:
path: |
java/org.eclipse.set.browser.cef.win32/res/cef
cef/Release/libcef.lib
cef/Release/LICENSE.txt
key: ${{ hashFiles('CEF_VERSION.txt') }}
- name: Download CEF
if: steps.cef-cache.outputs.cache-hit != 'true'
run: |
VERSION=$(grep -E -v ^# ../../CEF_VERSION.txt)
wget https://cef-builds.spotifycdn.com/$VERSION.tar.bz2 -O cef.tar.bz2
tar xf cef.tar.bz2 $VERSION/LICENSE.txt $VERSION/Resources --strip-components 1
tar xf cef.tar.bz2 $VERSION/Release/libcef.lib --strip-components 2
tar xf cef.tar.bz2 --wildcards $VERSION/Release/*.dll --wildcards $VERSION/Release/*.bin --strip-components 2
cp -r *.dll *.bin Resources/* LICENSE.txt ../../java/org.eclipse.set.browser.cef.win32/res/cef
ls -avl ../../java/org.eclipse.set.browser.cef.win32/res/cef
working-directory: cef/Release
- name: Fetch Rust binaries
uses: actions/download-artifact@v4
with:
name: chromium-swt-libs
path: java/org.eclipse.set.browser.lib/res/
- name: Build
run: mvn -T 1.5C -B clean verify
- name: Publish
run: mvn -T 1.5C -B deploy -DaltDeploymentRepository=set-github::https://maven.pkg.github.com/${{ github.repository }}
if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/tags/')
env:
GITHUB_TOKEN: ${{ github.token }}
- name: Trigger SET
if: github.ref == 'refs/heads/main' && github.repository_owner == 'eclipse-set'
uses: peter-evans/repository-dispatch@ff45666b9427631e3450c54a1bcbee4d9ff4d7c0 # v3.0.0
with:
token: ${{ secrets.GH_BOT_TOKEN }}
repository: eclipse-set/set
event-type: "Rebuild with browser update ${{ github.run_number }}"