updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / geogebra / PKGBUILD
blob7f42983e386c36c0715707f9d3e1e315b78ca47a
1 # Maintainer: moostik <mooostik_at_gmail.com>
3 pkgname=geogebra
4 pkgver=4.0.20.0
5 pkgrel=1
6 pkgdesc="Dynamic mathematics software with interactive graphics, algebra and spreadsheet"
7 arch=('any')
8 url="http://www.geogebra.org/"
9 license=('custom:GPL and CCPL:by-sa')
10 # Application and source code under GPL / Language files under CCPL:by-sa
11 depends=('java-runtime' 'shared-mime-info' 'hicolor-icon-theme' 'desktop-file-utils' 'xdg-utils')
12 optdepends=('kde-thumbnailer-geogebra: generates thumbnails of GeoGebra files in KDE'
13             'gnome-thumbnailer-geogebra: generates thumbnails of GeoGebra files in GNOME'
14             'geogebra-prim: adds a menu entry for the primary school version')
15 install='geogebra.install'
16 source=("http://${pkgname}.googlecode.com/files/GeoGebra-Unixlike-Installer-${pkgver}.tar.gz"
17         "${pkgname}.patch"
18         "${pkgname}.desktop.patch")
19 md5sums=('ad2c31b255e8633a63712b778fa1ff9f'
20          '77625adf901f2356e38f1256ad29b75b'
21          '534c4b9b618b6c75c8cf8abde6856232')
23 package() {
24   cd "${srcdir}/${pkgname}-${pkgver}"
25   patch -p0 < "${srcdir}/${pkgname}.patch"
26   patch -p0 < "${srcdir}/${pkgname}.desktop.patch"
27   # Installing application
28   install -d -m755 "${pkgdir}/usr/share/java/${pkgname}/unsigned"
29   install -D -m644 *.jar "${pkgdir}/usr/share/java/${pkgname}"
30   install -D -m644 unsigned/*.jar "${pkgdir}/usr/share/java/${pkgname}/unsigned"
31   install -D -m755 "${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
32   # Copying icons
33   for _size in "16x16" "22x22" "24x24" "32x32" "36x36" "48x48" "64x64" "72x72" "96x96" "128x128" "192x192" "256x256" "scalable"
34   do
35     install -d -m755 "${pkgdir}/usr/share/icons/hicolor/${_size}/"{apps,mimetypes}
36     install -D -m644 "icons/hicolor/${_size}/apps/${pkgname}".* "${pkgdir}/usr/share/icons/hicolor/${_size}/apps"
37     install -D -m644 "icons/hicolor/${_size}/mimetypes/application-vnd.${pkgname}".*.* "${pkgdir}/usr/share/icons/hicolor/${_size}/mimetypes"
38   done
39   # Creating menu item
40   install -D -m644 "${pkgname}.desktop" "${pkgdir}/usr/share/applications/${pkgname}.desktop"
41   # Installing mime-type
42   install -D -m644 "${pkgname}.xml" "${pkgdir}/usr/share/mime/packages/${pkgname}.xml"
43   # Installing license
44   install -D -m644 _LICENSE.txt "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"