summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: b63f3e858cb6bdbc8dc7e1b0a51eacc7b871eaa5 (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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# Maintainer: Muflone http://www.muflone.com/contacts/english/

pkgname=freeoffice
pkgver=763
pkgrel=1
pkgdesc="A complete, reliable, lightning-fast and Microsoft Office-compatible office suite with a word processor, spreadsheet, and presentation graphics software."
arch=('i686' 'x86_64')
url="http://www.freeoffice.com/"
license=('custom')
depends=('xdg-utils' 'shared-mime-info' 'gtk-update-icon-cache' 'desktop-file-utils')
depends_i686=('libxrender' 'libxrandr' 'libgl')
depends_x86_64=('lib32-gcc-libs' 'lib32-libxmu' 'lib32-libxrender' 'lib32-libxrandr' 'lib32-libgl')
install="${pkgname}.install"
source=("http://www.softmaker.net/down/softmaker-${pkgname}-${pkgver}.tgz"
        "${pkgname}-textmaker"
        "${pkgname}-planmaker"
        "${pkgname}-presentations"
        "${pkgname}-textmaker.desktop"
        "${pkgname}-planmaker.desktop"
        "${pkgname}-presentations.desktop")
sha256sums=('d540b0f6aab2268248dd2ac2b700bfbf0557c600186fe5c399761d681cbd0134'
            '0437328f3fddf93e18ad3df270971802c2e0fcaf3f030588c1301767a968da69'
            'c90e2575c71f03f0b627e4f6c70f437b9c40e5878bf9f553a4244b4a1f6dbd3c'
            'e6bc7608e58f44b55654c5d1fc93d442a400de638e2cbc6d5a3b3a8fbceaa0e4'
            '1554213ee9058a6594e2b92e47891ad58e593a4ea7d678c755cd32e263f43da8'
            '518913a4e3edb1f38dec65b865cf0687d5a4a5a1ecaa7fb5d653d5516a4d2ff8'
            '2b305734e63c5fba12def3c6ddfa79ef711f1c857fe68250b0d03d56df2bd980')

build() {
  [ -d "${pkgname}" ] && rm -rf "${pkgname}"
  mkdir "${pkgname}"
  tar xz -f freeoffice.tgz -C "${pkgname}"
}

package() {
  msg2 "Installing package files..."
  install -d "${pkgdir}/usr/lib"
  cp -r "${srcdir}/${pkgname}" "${pkgdir}/usr/lib"
  msg2 "Installing license file..."
  install -d "${pkgdir}/usr/share/licenses/${pkgname}"
  ln -s "/usr/lib/${pkgname}/license.txt" "${pkgdir}/usr/share/licenses/${pkgname}/license.txt"
  msg2 "Installing program executables..."
  install -d "${pkgdir}/usr/bin"
  install -m 755 -t "${pkgdir}/usr/bin" "${srcdir}/${pkgname}-planmaker"
  install -m 755 -t "${pkgdir}/usr/bin" "${srcdir}/${pkgname}-textmaker"
  install -m 755 -t "${pkgdir}/usr/bin" "${srcdir}/${pkgname}-presentations"
  msg2 "Installing icons..."
  for size in 16 32 48
  do
    install -d "${pkgdir}/usr/share/icons/hicolor/${size}x${size}/apps"
    ln -s "/usr/lib/${pkgname}/icons/pml_${size}.png" "${pkgdir}/usr/share/icons/hicolor/${size}x${size}/apps/${pkgname}-planmaker.png"
    ln -s "/usr/lib/${pkgname}/icons/prl_${size}.png" "${pkgdir}/usr/share/icons/hicolor/${size}x${size}/apps/${pkgname}-presentations.png"
    ln -s "/usr/lib/${pkgname}/icons/tml_${size}.png" "${pkgdir}/usr/share/icons/hicolor/${size}x${size}/apps/${pkgname}-textmaker.png"

    install -d "${pkgdir}/usr/share/icons/hicolor/${size}x${size}/mimetypes"
    ln -s "/usr/lib/${pkgname}/icons/pmd_${size}.png" "${pkgdir}/usr/share/icons/hicolor/${size}x${size}/mimetypes/application-x-pmd.png"
    ln -s "/usr/lib/${pkgname}/icons/prd_${size}.png" "${pkgdir}/usr/share/icons/hicolor/${size}x${size}/mimetypes/application-x-prd.png"
    ln -s "/usr/lib/${pkgname}/icons/tmd_${size}.png" "${pkgdir}/usr/share/icons/hicolor/${size}x${size}/mimetypes/application-x-tmd.png"
  done
  msg2 "Installing desktop files..."
  install -d "${pkgdir}/usr/share/applications"
  install -m 755 -t "${pkgdir}/usr/share/applications" "${pkgname}-textmaker.desktop"
  install -m 755 -t "${pkgdir}/usr/share/applications" "${pkgname}-planmaker.desktop"
  install -m 755 -t "${pkgdir}/usr/share/applications" "${pkgname}-presentations.desktop"
  msg2 "Installing mime file..."
  install -d "${pkgdir}/usr/share/mime/packages"
  install -m 644 -t "${pkgdir}/usr/share/mime/packages" "${srcdir}/${pkgname}/mime/softmaker-freeoffice16.xml"
}