summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 649b202b4e2e3e630a49ee57c49ee60daf8ef9d8 (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
# Contributor: Tom < reztho at archlinux dot us >
# Maintainer: Heavysink <winstonwu91 at gmail>
pkgname=openmsx-git
_pkgname=openMSX
pkgver=15160.cc2e19fc1
pkgrel=1
pkgdesc="The MSX emulator that aims for perfection."
arch=('i686' 'x86_64')
url="http://openmsx.org/"
license=('custom')
depends=('libxml2' 'sdl2' 'sdl2_ttf' 'tcl' 'libpng' 'zlib' 'alsa-lib' 'glew' 'libogg' 'libtheora' 'libvorbis')
makedepends=('git' 'python')
optdepends=('python' 'jack-audio-connection-kit' 'catalyst-utils' 'nvidia-utils' 'nvidia-304xx-utils')
install=openmsx.install
provides=('openmsx')
conflicts=('openmsx')
source=("git+https://github.com/openMSX/openMSX")

pkgver() {
  cd "${srcdir}/openMSX"
  printf "%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

build() {
  cd "${srcdir}/openMSX"
  
  # Changing some default configurations...
  sed -i 's@<SDL_ttf.h>@<SDL2/SDL_ttf.h>@' build/libraries.py
  sed -i 's@SYMLINK_FOR_BINARY:=true@SYMLINK_FOR_BINARY:=false@' build/custom.mk
  sed -i 's@INSTALL_BASE:=/opt/openMSX@INSTALL_BASE:=/usr/share/openmsx@' build/custom.mk
  echo 'INSTALL_DOC_DIR:=/usr/share/doc/openmsx' >> build/custom.mk
  echo 'INSTALL_SHARE_DIR:=/usr/share/openmsx' >> build/custom.mk
  echo 'INSTALL_BINARY_DIR:=/usr/bin' >> build/custom.mk

  # Compiling
  ./configure
  make
}

package() {
  cd "${srcdir}/openMSX"
  make DESTDIR="${pkgdir}" install

  # Licenses
  mkdir -p "${pkgdir}/usr/share/licenses/openmsx"
  install -m 644 "${pkgdir}/usr/share/doc/openmsx/cbios.txt" "${pkgdir}/usr/share/licenses/openmsx/"
}

md5sums=('SKIP')