/[gentoo-x86]/net-misc/tightvnc/tightvnc-1.3.10-r2.ebuild
Gentoo

Contents of /net-misc/tightvnc/tightvnc-1.3.10-r2.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.8 - (hide annotations) (download)
Sun Aug 10 20:48:18 2014 UTC (5 years, 5 months ago) by slyfox
Branch: MAIN
CVS Tags: HEAD
Changes since 1.7: +2 -2 lines
QA: drop trailing '.' from DESCRIPTION

(Portage version: 2.2.11_p9/cvs/Linux x86_64, signed Manifest commit with key 611FF3AA)

1 tomwij 1.1 # Copyright 1999-2014 Gentoo Foundation
2     # Distributed under the terms of the GNU General Public License v2
3 slyfox 1.8 # $Header: /var/cvsroot/gentoo-x86/net-misc/tightvnc/tightvnc-1.3.10-r2.ebuild,v 1.7 2014/08/09 12:04:19 ago Exp $
4 tomwij 1.1
5     EAPI="5"
6    
7     inherit eutils toolchain-funcs java-pkg-opt-2
8    
9     IUSE="java tcpd server"
10    
11     S="${WORKDIR}/vnc_unixsrc"
12 slyfox 1.8 DESCRIPTION="A great client/server software package allowing remote network access to graphical desktops"
13 tomwij 1.1 SRC_URI="mirror://sourceforge/vnc-tight/${P}_unixsrc.tar.bz2
14     mirror://gentoo/${PN}.png
15     java? ( mirror://sourceforge/vnc-tight/${P}_javasrc.tar.gz )"
16     HOMEPAGE="http://www.tightvnc.com/"
17    
18 ago 1.7 KEYWORDS="alpha amd64 arm ~mips ppc ~sh sparc x86 ~x86-fbsd ~arm-linux ~x86-linux"
19 tomwij 1.1 LICENSE="GPL-2"
20     SLOT="0"
21    
22     CDEPEND="media-fonts/font-misc-misc
23     virtual/jpeg
24     server? (
25     media-fonts/font-cursor-misc
26     x11-apps/rgb
27     x11-apps/xauth
28     x11-apps/xsetroot
29     )
30     x11-libs/libX11
31     x11-libs/libXaw
32     x11-libs/libXmu
33     x11-libs/libXp
34     x11-libs/libXt
35     tcpd? ( >=sys-apps/tcp-wrappers-7.6-r2 )"
36     RDEPEND="${CDEPEND}
37     java? ( >=virtual/jre-1.4 )"
38     DEPEND="${CDEPEND}
39     java? ( >=virtual/jdk-1.4 )
40     x11-proto/xextproto
41     x11-proto/xproto
42     server? (
43     x11-proto/inputproto
44     x11-proto/kbproto
45     x11-proto/printproto
46     )
47     >=x11-misc/imake-1
48     x11-misc/gccmakedep
49     x11-misc/makedepend
50     !net-misc/tigervnc"
51    
52     pkg_setup() {
53     if ! use server;
54     then
55     echo
56     einfo "The 'server' USE flag will build tightvnc's server."
57     einfo "If '-server' is chosen only the client is built to save space."
58     einfo "Stop the build now if you need to add 'server' to USE flags.\n"
59     fi
60     }
61    
62     src_prepare() {
63     epatch "${FILESDIR}/${PN}-1.3.10-pathfixes.patch" # fixes bug 78385 and 146099
64     epatch "${FILESDIR}/${PN}-1.3.8-imake-tmpdir.patch" # fixes bug 23483
65     epatch "${FILESDIR}/${PN}-1.3.8-darwin.patch" # fixes bug 89908
66     epatch "${FILESDIR}/${PN}-1.3.8-mips.patch"
67     epatch "${FILESDIR}"/server-CVE-2007-1003.patch
68     epatch "${FILESDIR}"/server-CVE-2007-1351-1352.patch
69     epatch "${FILESDIR}"/1.3.9-fbsd.patch
70     epatch "${FILESDIR}"/1.3.9-arm.patch
71     epatch "${FILESDIR}"/1.3.9-sh.patch
72     epatch "${FILESDIR}"/${PV}-sparc.patch
73     sed -e "s:\\(/etc/\\|/usr/share/\\):${EPREFIX}\\1:g" -i vncserver || die
74    
75     if use java; then
76     cd "${WORKDIR}"
77     epatch "${FILESDIR}/${PN}-1.3.10-java-build.patch"
78     fi
79     }
80    
81     src_compile() {
82     xmkmf -a || die "xmkmf failed"
83    
84     emake -j1 CDEBUGFLAGS="${CFLAGS}" EXTRA_LDOPTIONS="${LDFLAGS}" World
85    
86     if use server; then
87     cd Xvnc || die
88     econf
89    
90     if use tcpd; then
91     local myextra="-lwrap"
92     emake -j1 EXTRA_LIBRARIES="${myextra}" \
93     CDEBUGFLAGS="${CFLAGS}" EXTRA_LDOPTIONS="${LDFLAGS}" \
94     EXTRA_DEFINES="-DUSE_LIBWRAP=1"
95     else
96     emake -j1 CDEBUGFLAGS="${CFLAGS}" EXTRA_LDOPTIONS="${LDFLAGS}"
97     fi
98     fi
99    
100     if use java; then
101     cd "${WORKDIR}/vnc_javasrc" || die
102     emake -j1 JAVACFLAGS="$(java-pkg_javac-args)" all
103     fi
104    
105     }
106    
107     src_install() {
108     # the web based interface and the java viewer need the java class files
109     if use java; then
110     java-pkg_newjar "${WORKDIR}/vnc_javasrc/VncViewer.jar"
111     java-pkg_dolauncher "${PN}-java"
112     insinto /usr/share/${PN}/classes
113     doins "${WORKDIR}"/vnc_javasrc/*.vnc || die
114     dosym /usr/share/${PN}/lib/${PN}.jar /usr/share/${PN}/classes/VncViewer.jar
115     fi
116    
117     dodir /usr/share/man/man1 /usr/bin
118     ./vncinstall "${ED}"/usr/bin "${ED}"/usr/share/man || die "vncinstall failed"
119    
120     if use server; then
121     newconfd "${FILESDIR}"/tightvnc.confd vnc
122     newinitd "${FILESDIR}"/tightvnc.initd vnc
123     else
124     rm -f "${ED}"/usr/bin/vncserver || die
125     rm -f "${ED}"/usr/share/man/man1/{Xvnc,vncserver}* || die
126     fi
127    
128     newicon "${DISTDIR}"/tightvnc.png vncviewer.png
129     make_desktop_entry vncviewer vncviewer vncviewer Network
130    
131     dodoc ChangeLog README WhatsNew
132     use java && dodoc "${FILESDIR}"/README.JavaViewer
133     newdoc vncviewer/README README.vncviewer
134     }

  ViewVC Help
Powered by ViewVC 1.1.20