summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 40852ece6593417ee4917f711e1f88e2f4fea83d (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
# Maintainer: nobodyinperson <nobodyinperson at posteo de>
pkgname=candle-git
pkgver=v1.1.r98.3f763bc
pkgrel=1
pkgdesc="GRBL controller application with G-Code visualizer written in Qt - development version"
arch=(x86_64 aarch64)
url="https://github.com/Denvi/Candle"
license=('GPL3')
groups=()
depends=('qt5-serialport' 'qt5-base' 'hicolor-icon-theme')
makedepends=('git')
provides=("${pkgname%-git}")
conflicts=("${pkgname%-git}" "${pkgname%-git}-bin")
replaces=()
backup=()
options=()
install=
source=(
    "${pkgname%-git}"::'git+https://github.com/Denvi/Candle.git'
    "${pkgname%-git}.desktop"
    "frmmain.cpp.patch"
)
noextract=()
md5sums=('SKIP'
         'af12719ddf48d7fbef120adb03ab3cdb'
         '54cf1510a9858074b6bf54c0c174dd00')

pkgver() {
	cd "$srcdir/${pkgname%-git}"
	printf "%s" "$(git describe --tags --match 'v*' | sed 's/\([^-]*-\)g/r\1/;s/-/./g')"
}

prepare() {
	cd "$srcdir/${pkgname%-git}"
	git apply < "$srcdir/frmmain.cpp.patch"
}

build() {
	cd "$srcdir/${pkgname%-git}"
	cd src/
	qmake candle.pro
	make
}

package() {
    install -m644 "$srcdir"/"${pkgname%-git}.desktop" -Dt "$pkgdir"/usr/share/applications
	cd "$srcdir/${pkgname%-git}"
    install -m644 src/images/icon.svg -D "$pkgdir"/usr/share/icons/hicolor/scalable/apps/candle.svg
    install -m755 src/Candle -Dt "$pkgdir"/usr/bin
}