summaryrefslogtreecommitdiff
path: root/community/scite/PKGBUILD
blob: 472b84759153c56298349751bc19cbbb41f0ab04 (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
# Maintainer: Thomas S Hatch <thatch45@gmail.com>
# Contributor: Corrado 'bardo' Primier <corrado.primier@mail.polimi.it>
# Contributor: Jochem Kossen <j.kossen@home.nl>
# Contributor: Daniel J Griffiths <ghost1227@archlinux.us>

pkgname=scite
pkgver=2.25
pkgrel=1
pkgdesc='A generally useful editor with facilities for building and running programs.'
arch=('i686' 'x86_64')
url='http://www.scintilla.org/SciTE.html'
license=('custom:scite')
depends=('desktop-file-utils' 'gtk2')
backup=(usr/share/scite/SciTEGlobal.properties)
install=scite.install
source=("http://downloads.sourceforge.net/sourceforge/scintilla/${pkgname}${pkgver/\./}.tgz"
        'SciTE.desktop'
        'makefile.patch')
md5sums=('58767cfbdcb4ad99cc9460f36f958995'
         '48526532ef677982a4b156ae90f25b6f'
         '87005d4c7262a1a698cde0628dc7e2a2')

build() {
  sed "s/CXXTFLAGS=-DNDEBUG -Os $(CXXBASEFLAGS)/CXXTFLAGS=-DNDEBUG ${CXXFLAGS} $(CXXBASEFLAGS)/" -i scite/gtk/makefile

  sed "s/CXXBASEFLAGS=-Wall -Wno-missing-braces -Wno-char-subscripts -pedantic -DGTK -DSCI_LEXER \$(INCLUDEDIRS)/CXXBASEFLAGS=-Wall -Wno-missing-braces -Wno-char-subscripts -pedantic ${CXXFLAGS} -DGTK -DSCI_LEXER \$(INCLUDEDIRS)/" -i scintilla/gtk/makefile

  sed "s/CXXFLAGS=-DNDEBUG -Os \$(CXXBASEFLAGS) \$(THREADFLAGS)/CXXFLAGS=-DNDEBUG ${CXXFLAGS} \$(CXXBASEFLAGS) \$(THREADFLAGS)/" -i scintilla/gtk/makefile

  cd scintilla/gtk
  make
  install -Dm644 ../License.txt \
    ${pkgdir}/usr/share/licenses/scintilla/LICENSE

  cd ${srcdir}/${pkgname}/gtk
  make

  make DESTDIR=${pkgdir} install

  install -D -m644 ../License.txt \
    ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE

  install -D -m644 ${srcdir}/SciTE.desktop \
    ${pkgdir}/usr/share/applications/

  ln -sf SciTE ${pkgdir}/usr/bin/scite
}