summaryrefslogtreecommitdiff
path: root/extra/nx-common/PKGBUILD
blob: ee36eb8f25be2bb8c64d4483b0a5022350dd95ff (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
# $Id: PKGBUILD 157435 2012-04-28 09:58:39Z andyrtr $
# Maintainer: Tobias Powalowski <tpowa@archlinux.org>
# Contributed: eliott <eliott@solarblue.net>, Andre Naumann <anaumann@SPARCed.org>

pkgname=nx-common
pkgver=3.5.0
pkgrel=5
pkgdesc="NoMachine NX common package for client and server"
arch=('i686' 'x86_64' 'mips64el')
license=('GPL')
url="http://nomachine.com/"
depends=('libjpeg-turbo' 'libpng' 'openssl' 'gcc-libs' 'libxcomp') # 'bash'
makedepends=('xorg-server-devel' 'nx-headers')
source=(http://64.34.173.142/download/$pkgver/sources/nxcompsh-$pkgver-1.tar.gz
        http://64.34.173.142/download/$pkgver/sources/nxssh-$pkgver-2.tar.gz
        nxcompsh-gcc43.patch)
options=('!libtool')
md5sums=('84ade443b79ea079380b754aba9d392e'
         'f52fcdb38e09f8dcfb9ff0344dfbbbd6'
         'b6c279654dac421fc3dd1a27d66ff53c')

build() {
  # nxcompsh
  cd ${srcdir}/nxcompsh
  patch -Np1 -i ${srcdir}/nxcompsh-gcc43.patch
  ./configure --prefix=/usr/lib/nx
  make

  # nxssh
  cd ${srcdir}/nxssh
  sed -i "s:NX.h:nx/NX.h:g" clientloop.c packet.c proxy.c
  ./configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
  make
}

package() {
  install -dm755 ${pkgdir}/usr/{bin,lib/nx}

  # nxcompsh
  cd ${srcdir}/nxcompsh
  cp -a libXcompsh.so* ${pkgdir}/usr/lib/nx
  cd ${pkgdir}/usr/lib/
  ln -sv /usr/lib/nx/libXcompsh.so{,.3,.3.5.0} .
  # ^ really needed?

  # nxssh
  cd ${srcdir}/nxssh
  install -D -m755 nxssh ${pkgdir}/usr/lib/nx/bin/nxssh
  cd ${pkgdir}/usr/bin
  ln -sv /usr/lib/nx/bin/nxssh .
}