Commit 969653a4 authored by Slugger@Github's avatar Slugger@Github
Browse files

fix build on some platforms

The build fails on some of the Alpine target platforms because of
an IOException where the file write fails unless the target file
already exists.  Appears to be a groovy bug, but not sure.  This
patch should get the build thru on all platforms.
parent 8d1ad5f7
Pipeline #66366 failed with stages
in 10 minutes and 2 seconds
......@@ -9,6 +9,7 @@ arch="noarch"
license="GPL-3.0-or-later"
makedepends="git openjdk8"
depends="wireguard-tools openjdk8-jre-base sudo iputils"
source="groovy-file-bug.patch"
install="$pkgname.pre-install $pkgname.post-install"
subpackages="$pkgname-doc $pkgname-openrc"
builddir="$srcdir/piawgmgr"
......@@ -44,3 +45,4 @@ package() {
install -m644 -D "$_apkoutdir"/piawgmgr.man.gz "$pkgdir"/usr/share/man/man1/piawgmgr.gz
}
sha512sums="c3158c3aadb6b75757ed5730397a11e271e5a14a58047db17d1d93cc6edb9d429eb654c6495726ea96e1910b66305112cdc99efd9ef7f6297285188d3ad3f523 groovy-file-bug.patch"
diff --git a/build.gradle b/build.gradle
index d93b477..5cf95ca 100644
--- a/build.gradle
+++ b/build.gradle
@@ -32,6 +32,8 @@ versioning {
displayMode = 'snapshot'
snapshot = "-SNAPSHOT+${System.getenv('GITHUB_RUN_NUMBER') ?: '0'}"
branchEnv = ['PIAWGMGR_BRANCH']
+ dirty = { version -> version }
+ noWarningOnDirty = true
}
group = 'com.github.slugger.vpn.pia'
@@ -68,6 +70,7 @@ task mkver {
doLast {
def f = new File('build/full.ver')
f.delete()
+ f.createNewFile() // JRE on some platforms refuses to write unless the file already exists
f << versioning.info.full
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment