File: build.gradle

package info (click to toggle)
pdftk-java 3.3.3-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 6,992 kB
  • sloc: java: 48,283; xml: 202; sh: 55; perl: 19; makefile: 10
file content (57 lines) | stat: -rw-r--r-- 1,298 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
plugins {
    id 'java'
    id 'application'
    id 'com.diffplug.spotless' version '6.10.0'
    id 'com.github.johnrengelman.shadow' version '7.1.2'
    id 'org.mikeneck.graalvm-native-image' version '1.4.1'
}

sourceCompatibility = 1.8
tasks.withType(JavaCompile) {
  options.encoding = "UTF-8"
}

sourceSets {
    main {
        java {
            srcDirs = ['java']
        }
        resources {
            srcDirs = ['java']
            include "**/*.afm"
            include "**/*.txt"
        }
    }
}

mainClassName = 'com.gitlab.pdftk_java.pdftk'

repositories {
    mavenCentral()
}

dependencies {
    implementation 'org.apache.commons:commons-lang3:3.12.0'
    implementation 'org.bouncycastle:bcprov-jdk18on:1.71'
}

nativeImage {
  mainClass = mainClassName
  executableName = 'pdftk'
  arguments(
      '-H:ResourceConfigurationFiles=META-INF/native-image/resource-config.json',
      '-H:ReflectionConfigurationFiles=META-INF/native-image/reflect-config.json',
      '--no-fallback',
      '-H:+AddAllCharsets',
      '-H:Log=registerResource:',
      '-H:GenerateDebugInfo=' + (project.hasProperty('generatedebuginfo') ? '1' : '0'),
  )
}

spotless {
    java {
        target 'java/com/gitlab/pdftk_java/*.java'
        googleJavaFormat()
        removeUnusedImports()
    }
}