summaryrefslogtreecommitdiff
blob: f8fc79d9b231947975d24030b6029b8fcf75c15e (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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-misc/nx-x11/nx-x11-1.4.0-r2.ebuild,v 1.3 2004/09/13 00:33:37 pvdabeel Exp $

inherit eutils

MY_PN="${PN//x11/X11}"
MY_PV="${PV}-3"
DESCRIPTION="A special version of the X11 libraries supporting NX compression technology"
HOMEPAGE="http://www.nomachine.com/developers.php"
URI_BASE="http://www.nomachine.com/download/snapshot/nxsources/"
URI_BASE2="http://www.nomachine.com/download/nxsources/"
SRC_NX_X11="${MY_PN}-${MY_PV}.tar.gz"
SRC_NXAGENT="nxagent-1.4.0-47.tar.gz"
SRC_NXAUTH="nxauth-1.4.0-1.tar.gz"
SRC_NXCOMP="nxcomp-1.4.0-23.tar.gz"
SRC_NXCOMPEXT="nxcompext-1.4.0-3.tar.gz"
SRC_NXVIEWER="nxviewer-1.4.0-2.tar.gz"
SRC_NXDESKTOP="nxdesktop-1.4.0-36.tar.gz"
SRC_NXESD="nxesd-1.4.0-1.tar.gz"
SRC_URI="$URI_BASE/${SRC_NX_X11} $URI_BASE/${SRC_NXAGENT} $URI_BASE/${SRC_NXAUTH} $URI_BASE/${SRC_NXCOMP} $URI_BASE/${SRC_NXCOMPEXT} $URI_BASE/${SRC_NXVIEWER} $URI_BASE/${SRC_NXDESKTOP} $URI_BASE/${SRC_NXESD}"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~x86 ~ppc"
IUSE=""
#RESTRICT="nostrip"
DEPEND="virtual/x11"
#RDEPEND=""
S=${WORKDIR}/${MY_PN}

src_unpack() {
	# we can't use ${A} because of bug #61977
	unpack ${SRC_NX_X11}
	unpack ${SRC_NXAGENT}
	unpack ${SRC_NXAUTH}
	unpack ${SRC_NXCOMP}
	unpack ${SRC_NXCOMPEXT}
	unpack ${SRC_NXVIEWER}
	unpack ${SRC_NXDESKTOP}
	unpack ${SRC_NXESD}

	cd ${S}
	epatch ${FILESDIR}/${PN}-${PV}.xprint.patch
}

src_compile() {
	emake World || die "unable to build nx-11"

	cd ../nxviewer
	xmkmf || die "unable to create makefile for nxviewer"
	emake World || die "unable to make nxviewer"

	cd ../nxdesktop
	./configure --prefix=/usr/NX --mandir=/usr/share/man --sharedir=/usr/share || die "Unable to configure nxdesktop"
	emake || die "Unable to build nxdesktop"

	return

	# mxesd support will have to wait for a later release

	cd ../nxesd
	econf --prefix=/usr/NX || die "Unable to configure nxesd"
	emake || die "Unable to build nxesd"
}

src_install() {
	into /usr/NX

	dobin programs/Xserver/nxagent
	dobin programs/nxauth/nxauth
	dobin ../nxviewer/nxviewer/nxviewer
	dobin ../nxviewer/nxpasswd/nxpasswd
	dobin ../nxdesktop/nxdesktop

	dolib ../nxcomp/libXcomp.so
	dolib ../nxcompext/libXcompext.so
	dolib lib/X11/libX11.so
	dolib lib/Xext/libXext.so
	dolib lib/Xrender/libXrender.so

	preplib /usr/NX

	insinto /usr/X11R6/include
	doins ../nxcomp/NX.h

	dodir /var/lib/nxserver

	return

	# nxesd support will have to wait for a later release

	cd ../nxesd
	emake DESTDIR=${D} install || die "unable to install nxesd"
}