Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Regenerate from zproject #2293

Merged
merged 1 commit into from
Aug 6, 2024
Merged
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
2 changes: 1 addition & 1 deletion bindings/jni/czmq-jni-native/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ dependencies {
// ------------------------------------------------------------------
// Build section

tasks.register('copyLibs', type: Copy) {
tasks.register('copyLibs', Copy) {
def libraryPaths = []
if (project.hasProperty('buildPrefix')) {
if (osdetector.os == 'windows') {
Expand Down
15 changes: 10 additions & 5 deletions bindings/jni/czmq-jni/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ dependencies {
// ------------------------------------------------------------------
// Build section

tasks.register('generateJniHeaders', type: Exec, dependsOn: 'classes') {
tasks.register('generateJniHeaders', Exec) {
dependsOn 'classes'
def classpath = sourceSets.main.output.classesDirs
def appclasspath = configurations.runtimeClasspath.files*.getAbsolutePath().join(File.pathSeparator)
def nativeIncludes = 'src/native/include'
Expand Down Expand Up @@ -81,13 +82,15 @@ tasks.withType(Test).configureEach {
}
}

tasks.register('initCMake', type: Exec, dependsOn: 'generateJniHeaders') {
tasks.register('initCMake', Exec) {
dependsOn 'generateJniHeaders'
workingDir 'build'
def prefixPath = hasNotEmptyProperty('buildPrefix') ? "-DCMAKE_PREFIX_PATH=$project.buildPrefix" : ''
commandLine 'cmake', "$prefixPath", '..'
}

tasks.register('buildNative', type: Exec, dependsOn: 'initCMake') {
tasks.register('buildNative', Exec) {
dependsOn 'initCMake'
if (osdetector.os == 'windows') {
commandLine 'cmake',
'--build', 'build',
Expand All @@ -106,12 +109,14 @@ test.dependsOn buildNative
// ------------------------------------------------------------------
// Install and Publish section

tasks.register('sourcesJar', type: Jar, dependsOn: 'classes') {
tasks.register('sourcesJar', Jar) {
dependsOn 'classes'
archiveClassifier = 'sources'
from sourceSets.main.allSource
}

tasks.register('javadocJar', type: Jar, dependsOn: 'javadoc') {
tasks.register('javadocJar', Jar) {
dependsOn 'javadoc'
archiveClassifier = 'javadoc'
from javadoc.destinationDir
}
Expand Down
Loading