gradle-jextract
Introduction: Gradle plugin that generates Java bindings from native library headers using Jextract
Tags:
This is a Gradle plugin that adds Jextract to a Gradle build.
Quick Start
plugins {
`java-library`
id("de.infolektuell.jextract") version "x.y.z"
}
repositories {
mavenCentral()
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(25)
}
}
jextract.libraries {
val greeting by registering {
header = layout.projectDirectory.file("src/main/public/greeting.h")
headerClassName = "Greeting"
targetPackage = "com.example.greeting"
useSystemLoadLibrary = true
libraries.add("greeting")
}
sourceSets.named("main") {
jextract.libraries.addLater(greeting)
}
}
Please visit the Setup guide on the documentation website for more details.
Change history
See GitHub Releases or the changelog file for releases and changes.
