summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 9915a3051bce391028aeb8e88f128a2dec5186f9 (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
# Maintainer: taotieren <admin@taotieren.com>

pkgbase=lc2kicad-git
pkgname=lc2kicad-git
pkgver=alpha.0.1.6.r39.g9fe34d8
pkgrel=1
pkgdesc="A utility that converts EasyEDA files to KiCad files"
arch=('x86_64' 'i686' 'arm')
url="https://github.com/RigoLigoRLC/LC2KiCad"
license=('LGPL-3.0')
groups=()
provides=(LC2KiCad)
conflicts=(${pkgbase%-git})
replaces=()
depends=()
makedepends=(git cmake ninja)
optdepends=('kicad: Electronic schematic and printed circuit board (PCB) design tools')
backup=()
options=('!strip')
install=
source=("${pkgname%-git}::git+${url}.git")
sha256sums=('SKIP')

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

build() {
    cd "${srcdir}/${pkgname%-git}"

    cmake  -DCMAKE_INSTALL_PREFIX=/usr/bin \
        -B build \
        -G Ninja

    ninja -C build
}

package() {
    DESTDIR="${pkgdir}" ninja -C "${srcdir}"/${pkgname%-git}/build install
}