blob: 0e19261c056d0b0acee0d9c2ff843cd10c39eb26 (
plain)
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
58
59
60
61
62
63
64
|
# Maintainer: Jefferson Gonzalez <jgmdev@gmail.com>
pkgname=pragtical
pkgver=3.12.4
pkgrel=1
pkgdesc='The practical and pragmatic code editor.'
arch=('x86_64')
url="https://github.com/pragtical/pragtical"
license=('MIT')
depends=(
# Editor Dependencies
'luajit' 'sdl3' 'sdl3_image' 'libiconv' 'freetype2' 'harfbuzz' 'pcre2' 'uchardet' 'hicolor-icon-theme'
# Plugin Manager Dependencies
'lua' 'zlib' 'mbedtls' 'libgit2' 'libzip' 'xz'
)
makedepends=('meson>=0.63' 'git')
source=(
"https://github.com/pragtical/pragtical/archive/refs/tags/v$pkgver.tar.gz"
)
sha256sums=('c1e635bb86cf2f0bfd52667988529238a93c01819f1df685a187f4ce970926f3')
build() {
cd "pragtical-$pkgver"
local pgo
local lua="-Duse_system_lua=true"
if [ -n "$PGO" ]; then
pgo="-Db_pgo=generate"
lua="-Duse_system_lua=false"
fi
local global_data
if [ -n "$GLOBAL" ]; then
global_data="-global"
fi
arch-meson --wrap-mode default --buildtype release $pgo -Db_lto=true \
-Dstrip=true -Doptimization=3 -Drenderer_backend=sdlgpu $lua \
build
if [ -n "$PGO" ]; then
meson compile -C build
case "$XDG_SESSION_TYPE" in
wayland|x11)
./scripts/run-local $global_data build run -n scripts/lua/pgo.lua
;;
*)
SDL_VIDEO_DRIVER="dummy" \
./scripts/run-local $global_data build run -n scripts/lua/pgo.lua
;;
esac
meson configure -Db_pgo=use build
fi
meson compile -C build
}
package() {
cd "pragtical-$pkgver"
DESTDIR="$pkgdir" meson install -C build
mkdir -p "$pkgdir/usr/share/licenses/$pkgname/"
ln -s "/usr/share/doc/pragtical/licenses.md" "$pkgdir/usr/share/licenses/$pkgname/LICENSE.md"
}
|