diff options
author | Lucca Pellegrini | 2022-08-05 22:54:26 +0000 |
---|---|---|
committer | Lucca Pellegrini | 2022-08-05 22:54:26 +0000 |
commit | c4626bd059781aaf0653124d45de5f9bf30a21a4 (patch) | |
tree | e57ddbc766d4009e429bc8f958291f5926f358d9 | |
download | aur-c4626bd059781aaf0653124d45de5f9bf30a21a4.tar.gz |
Initial commit
-rw-r--r-- | .SRCINFO | 27 | ||||
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | PKGBUILD | 45 | ||||
-rw-r--r-- | remove_zig_version_check.patch | 16 |
4 files changed, 92 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..a9889eeb8382 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,27 @@ +pkgbase = mepo-git + pkgdesc = Fast, simple, and hackable OSM map viewer for Linux (development version) + pkgver = 0.4.1.250.gcd3c8e4 + pkgrel = 1 + url = https://git.sr.ht/~mil/mepo + arch = i686 + arch = x86_64 + arch = arm + arch = aarch64 + license = GPL3 + checkdepends = zig>=0.9 + makedepends = git + makedepends = zig>=0.9 + depends = dmenu + depends = jq + depends = xdotool + depends = curl + depends = sdl2 + depends = sdl2_image + depends = sdl2_ttf + depends = sdl2_gfx + provides = mepo + conflicts = mepo + source = mepo::git+https://git.sr.ht/~mil/mepo + sha512sums = SKIP + +pkgname = mepo-git diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..e4de87096539 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +src/ +pkg/ +*.tar.gz +*.zst diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..99fb584b19bd --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,45 @@ +# Maintainer: Lucca Pellegrini <luccapellegrini@gmail.com> +# Contributor: Rene Hickersberger <r@renehsz.com> +# Contributor: Robert Hamblin <hamblingreen@hotmail.com> +pkgname=mepo-git +_pkgname=mepo +pkgver=0.4.1.250.gcd3c8e4 +pkgrel=1 +pkgdesc="Fast, simple, and hackable OSM map viewer for Linux (development version)" +arch=('i686' 'x86_64' 'arm' 'aarch64') +url="https://git.sr.ht/~mil/mepo" +license=('GPL3') +depends=('dmenu' 'jq' 'xdotool' 'curl' 'sdl2' 'sdl2_image' 'sdl2_ttf' 'sdl2_gfx') +makedepends=('git' 'zig>=0.9') +checkdepends=('zig>=0.9') +provides=('mepo') +conflicts=('mepo') +changelog= +source=("$_pkgname"::"git+$url") +sha512sums=(SKIP) + +pkgver() { + cd "$_pkgname" + git describe --long --tags | sed 's/^v//;s/\\([^-]*-g\\)/r\\1/;s/-/./g' +} + +prepare() { + patch --directory="$_pkgname" --forward --strip=1 --input="$startdir/remove_zig_version_check.patch" +} + +build() { + cd "$_pkgname" + zig build -Drelease-safe=true +} + +check() { + cd "$_pkgname" + zig build test +} + +package() { + cd "$_pkgname" + mkdir -p "$pkgdir/usr/bin" + install scripts/mepo_* "$pkgdir/usr/bin/" + install "zig-out/bin/mepo" "$pkgdir/usr/bin/" +} diff --git a/remove_zig_version_check.patch b/remove_zig_version_check.patch new file mode 100644 index 000000000000..e0dc8c8626a9 --- /dev/null +++ b/remove_zig_version_check.patch @@ -0,0 +1,16 @@ +diff --unified --recursive --text --color mepo-0.4.orig/src/main.zig mepo-0.4.new/src/main.zig +--- mepo-0.4.orig/src/main.zig 2022-03-24 19:26:51.450817126 +0100 ++++ mepo-0.4.new/src/main.zig 2022-03-24 19:27:04.786754328 +0100 +@@ -7,12 +7,6 @@ + const utildbg = @import("./util/utildbg.zig"); + + pub fn main() !void { +- comptime { +- const v = builtin.zig_version; +- if (v.major != 0 or v.minor != 9 or v.patch != 1) +- @panic("Must be built against Zig 0.9.1"); +- } +- + const allocator = std.heap.c_allocator; + var stderr_on: bool = false; + var mode: enum { Graphical, Download, Version } = .Graphical; |