# Maintainer: Tony Sokhon <tonyskn@gmail.com>
# Contributor: Ebubekir KARUL <ebubekirkarul@yandex.com>
# Contributor: Gaurish Sharma <contact@gaurishsharma.com>
# Contributor: Massimiliano Torromeo <massimiliano.torromeo@gmail.com>
# Contributor: Katrina L. Halliwell <rambaldi.kat.47@gmail.com>
# Contributor: Eugenio Ferreira <eugfcl@gmail.com>
pkgname=lighttable
pkgver=0.6.5
pkgrel=1
pkgdesc="New interactive IDE that lets you modify running programs and embed anything from websites to games."
url="http://www.lighttable.com/"
license=('GPLv3')
depends=(nss libx11 libxrandr libpng gconf)
options=(!strip)
arch=('i686' 'x86_64')
source=(lighttable
$pkgname-$pkgver-$CARCH.tar.gz::http://d35ac8ww5dfjyg.cloudfront.net/playground/bins/$pkgver/LightTableLinux.tar.gz
lighttable.desktop
lighttable.png)
md5sums=('e772b3547fdc3a6e32f81e7303422fd1'
'fe4f06707eb1eff509d3dce965019528'
'04a62702b59810a36bca7623bf9e932c'
'f8c055be2f047ff4aaffdd028f62f027')
if [[ "$CARCH" == "x86_64" ]]; then
source[1]=$pkgname-$pkgver-$CARCH.tar.gz::http://d35ac8ww5dfjyg.cloudfront.net/playground/bins/$pkgver/LightTableLinux64.tar.gz
md5sums[1]='94d3f5906db70bfc272686160ae90d67'
fi
package() {
install -D -m755 lighttable "$pkgdir/usr/bin/lighttable"
_destdir="$pkgdir/opt/LightTable"
install -dm755 $_destdir
#rm "$srcdir/LightTable/debug.log"
mv $srcdir/LightTable/* $_destdir
mkdir -p "${pkgdir}"/usr/share/{applications,pixmaps}
install -m644 "${startdir}"/lighttable.desktop "${pkgdir}/usr/share/applications/"
install -m644 "${startdir}"/lighttable.png "${pkgdir}"/usr/share/pixmaps/lighttable.png
#for more info, https://github.com/Kodowa/Light-Table-Playground/issues/161
ln -s /usr/lib/libudev.so "$_destdir/libudev.so.0"
}