summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: fbaa1c0e9dc7e6ef2071b51fbee8054846f7bdc6 (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
# Maintainer: ksj <podhorsky.ksj@gmail.com>
# Contributor: ksj <podhorsky.ksj@gmail.com>

_gitname=geany
pkgname=$_gitname-gtk3-git
pkgver=1.31.0.r52.gfca450e10
pkgrel=1
pkgdesc="Fast and lightweight IDE (git version)"
arch=('x86_64' 'i686')
url="https://github.com/$_gitname/$_gitname"
license=('GPL2')
depends=('desktop-file-utils' 'hicolor-icon-theme' 'gtk3')
makedepends=('git' 'intltool' 'lua' 'perl-xml-parser')
optdepends=('geany-plugins: additional functionality' 'vte: terminal support' 'python2: Python 2 support')
conflicts=("$_gitname")
provides=("$_gitname=$pkgver")
install="$pkgname.install"
source=($_gitname::git://github.com/$_gitname/$_gitname.git)
md5sums=('SKIP')

pkgver() {
    cd $_gitname
    (
        set -o pipefail
        git describe --long --tag | sed -r 's/([^-]*-g)/r\1/;s/-/./g' ||
        printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
    )
}

prepare() {
    cd $_gitname

    # Syntax highlighting for PKGBUILD files
    sed -i 's/Sh=/Sh=PKGBUILD;/' data/filetype_extensions.conf
}

build() {
    cd $_gitname
    export CFLAGS="${CFLAGS} -D_FILE_OFFSET_BITS=64"
    ./autogen.sh --enable-gtk3 --disable-html-docs --prefix=/usr
    make
}

check() {
    cd $_gitname
    make check
}
package() {
    cd $_gitname
    make PREFIX=/usr DESTDIR="$pkgdir" install
}