#!/usr/bin/make -f

%:
	dh $@ --buildsystem=gradle --with maven-repo-helper

override_dh_auto_build:
	dh_auto_build -- -Dorg.gradle.jvmargs="-Xbootclasspath/a:/usr/share/java/gradle-helper-hook.jar:/usr/share/java/maven-repo-helper.jar --add-opens=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED" jar \
		-x :picocli-annotation-processing-tests:jar \
		-x :picocli-examples:compileGroovy \
		-x :picocli-examples:jar \
		-x :picocli-shell-jline3:jar \
		-x :picocli-spring-boot-starter:jar \
		-x :picocli-groovy:jar

# tests are disabled until we have com.github.stefanbirkner:system-rules:1.x
override_dh_auto_test:

override_dh_auto_configure:
	dh_auto_configure $@
	rsync -Lav ../debian/built-components/ debian/ || true