summaryrefslogtreecommitdiff
path: root/community/mg/PKGBUILD
blob: 89f11c138498e085db6405591d9bd565cee850c2 (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
# $Id: PKGBUILD 99913 2013-10-31 02:26:20Z allan $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Hannes Rist <hrist@phreeknet.org>

pkgname=mg
pkgver=20130922
pkgrel=2
pkgdesc="mg is Micro GNU/emacs, this is a portable version of the mg maintained by the OpenBSD team."
arch=('i686' 'x86_64' 'mips64el')
url="http://homepage.boetes.org/software/mg/"
depends=('ncurses' 'libbsd')
makedepends=('bmake' 'libclens')
license=('custom')
source=(http://homepage.boetes.org/software/mg/mg-$pkgver.tar.gz
	cleanup.patch)
md5sums=('35bd196ab32bae3531d6bc48be8779d0'
         'abcea6e34c05425a52101b7c7fb60e7a')

prepare() {
  cd $srcdir/$pkgname-$pkgver
  patch -p1 <$srcdir/cleanup.patch

  # The scripts building this package won't see and fix the warnings,
  # even if they make the build fail.
  sed -ri '/^CFLAGS\+=/d' Makefile*
}

build() {
  cd $srcdir/$pkgname-$pkgver
  bmake prefix=/usr
}

package() {
  cd $srcdir/$pkgname-$pkgver

  mkdir -p $pkgdir/usr/bin
  bmake install INSTALL=install prefix=/usr DESTDIR=$pkgdir BINDIR=/usr/bin

  mkdir -p $pkgdir/usr/share/
  install -D -m0644 README $pkgdir/usr/share/licenses/$pkgname/README
}