summaryrefslogtreecommitdiff
path: root/community/soil/PKGBUILD
blob: 978af85cf5459ffa62fe2ac4b4ad5ee30dd3e22c (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
# $Id: PKGBUILD 64769 2012-02-18 04:26:01Z svenstaro $
# Maintainer: Sven-Hendrik Haase <sh@lutzhaase.com>

pkgname=soil
pkgver=0708
pkgrel=2
pkgdesc="tiny C lib primarily for loading textures into OpenGL"
arch=('i686' 'x86_64' 'mips64el')
url="http://www.lonesock.net/soil.html"
license=('custom:public')
makedepends=('unzip')
depends=('freeglut')
#options=('!libtool')
source=("http://www.lonesock.net/files/soil.zip")
md5sums=('4736ac4f34fd9a41fa0197eac23bbc24')

build() {
  cd "${srcdir}/Simple OpenGL Image Library/projects/makefile"
  [[ -d obj ]] && rm -r obj/
  mkdir obj/

  sed "s|LOCAL = /usr/local|LOCAL = ${pkgdir}/usr|g" -i makefile || return 1
  sed "s|CXXFLAGS = |CXXFLAGS = -fPIC |g" -i makefile || return 1
  mkdir -p ${pkgdir}/usr/{lib,include}
  make || return 1
  make install || return 1
  chmod 644 ${pkgdir}/usr/lib/libSOIL.a
}