Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions .github/workflows/pr-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,15 @@ jobs:
- name: Build
run: ./gradlew clean build --no-daemon

- name: Toolkit jar smoke test
run: |
set -e
JAR=plugins/build/libs/Toolkit.jar
java -jar "$JAR" help
java -jar "$JAR" db --help
java -jar "$JAR" db archive -h
java -jar "$JAR" keystore --help

build-ubuntu:
name: Build ubuntu24 (JDK 17 / aarch64)
if: ${{ github.event_name == 'pull_request' || inputs.job == 'all' || inputs.job == 'ubuntu' }}
Expand Down Expand Up @@ -84,6 +93,15 @@ jobs:
- name: Build
run: ./gradlew clean build --no-daemon

- name: Toolkit jar smoke test
run: |
set -e
JAR=plugins/build/libs/Toolkit.jar
java -jar "$JAR" help
java -jar "$JAR" db --help
java -jar "$JAR" db archive -h
java -jar "$JAR" keystore --help

docker-build-rockylinux:
name: Build rockylinux (JDK 8 / x86_64)
if: ${{ github.event_name == 'pull_request' || inputs.job == 'all' || inputs.job == 'rockylinux' }}
Expand Down Expand Up @@ -127,6 +145,15 @@ jobs:
- name: Build
run: ./gradlew clean build --no-daemon

- name: Toolkit jar smoke test
run: |
set -e
JAR=plugins/build/libs/Toolkit.jar
java -jar "$JAR" help
java -jar "$JAR" db --help
java -jar "$JAR" db archive -h
java -jar "$JAR" keystore --help

- name: Test with RocksDB engine
run: ./gradlew :framework:testWithRocksDb --no-daemon

Expand Down Expand Up @@ -172,6 +199,15 @@ jobs:
- name: Build
run: ./gradlew clean build --no-daemon --no-build-cache

- name: Toolkit jar smoke test
run: |
set -e
JAR=plugins/build/libs/Toolkit.jar
java -jar "$JAR" help
java -jar "$JAR" db --help
java -jar "$JAR" db archive -h
java -jar "$JAR" keystore --help

- name: Test with RocksDB engine
run: ./gradlew :framework:testWithRocksDb --no-daemon --no-build-cache

Expand Down
24 changes: 23 additions & 1 deletion plugins/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,22 @@ dependencies {
exclude group: 'io.prometheus'
exclude group: 'org.aspectj'
exclude group: 'org.apache.httpcomponents'
// x86 declares io.github.tronprotocol:leveldbjni-all:1.18.2 below.
// :crypto -> :common -> :platform also transitively pulls
// org.fusesource.leveldbjni:leveldbjni-all:1.8; both jars carry
// org/iq80/leveldb/Options.class and the duplicate-entry write order
// in the fat jar can leave the 1.8 copy, which lacks
// Options.maxBatchSize(int) and breaks `db archive` at runtime.
// Drop the 1.8 transitive on x86 only; ARM64 has a single copy via
// its direct :platform declaration and no conflict.
//
// zksnark-java-sdk and commons-io are deliberately NOT mirrored from
// the :platform-direct excludes below: the plugins test runtime
// (DbLiteTest -> Spring -> ZksnarkInitService) loads classes from
// both at runtime, so :crypto must keep transitively providing them.
if (!rootProject.archInfo.isArm64) {
exclude group: 'org.fusesource.leveldbjni', module: 'leveldbjni-all'
}
}
implementation group: 'info.picocli', name: 'picocli', version: '4.6.3'
implementation group: 'com.typesafe', name: 'config', version: '1.3.2'
Expand Down Expand Up @@ -130,7 +146,13 @@ def binaryRelease(taskName, jarName, mainClass) {
from(sourceSets.main.output) {
include "/**"
}
dependsOn (project(':protocol').jar, project(':platform').jar) // explicit_dependency
// Fat jar zips up runtimeClasspath, which includes the jar outputs of
// every project dependency. Declare them all explicitly so Gradle does
// not warn about implicit_dependency and disable execution optimizations
// (and so partial / parallel builds cannot run binaryRelease before the
// dependency jars exist).
dependsOn (project(':protocol').jar, project(':platform').jar,
project(':crypto').jar, project(':common').jar) // explicit_dependency
from {
configurations.runtimeClasspath.collect { // https://docs.gradle.org/current/userguide/upgrading_version_6.html#changes_6.3
it.isDirectory() ? it : zipTree(it)
Expand Down
Loading