/[packages]/cauldron/nx/current/SPECS/nx.spec
ViewVC logotype

Contents of /cauldron/nx/current/SPECS/nx.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 216547 - (show annotations) (download)
Thu Mar 1 20:33:17 2012 UTC (12 years, 1 month ago) by obgr_seneca
File size: 8737 byte(s)
removed unneeded BR on x11-devel
1 %define srcname %{name}-libs
2
3 %define _pkglibdir %{_libdir}/nx
4 %define _pkgincdir %{_includedir}/nx
5 %define _pkgdatadir %{_datadir}/nx
6 %define _pkglibexecdir %{_libexecdir}/nx
7
8 %define lib_major_xcompext 3
9 %define lib_name_xcompext %mklibname xcompext %{lib_major_xcompext}
10
11 %define lib_major_nxx11 0
12 %define lib_name_nxx11 %mklibname nxX11_ %{lib_major_nxx11}
13
14 %define lib_major_nxcomp 3
15 %define lib_name_nxcomp %mklibname xcomp %{lib_major_nxcomp}
16
17
18 Name: nx
19 Version: 3.5.0.11
20 Release: %mkrel 1
21 Summary: NX core libraries
22 License: GPLv2
23 Group: Networking/Remote access
24 Url: http://x2go.org/
25
26 Source0: http://code.x2go.org/releases/source/%{srcname}/%{srcname}_%{version}-full.tar.gz
27
28 BuildRequires: autoconf
29 BuildRequires: gcc-c++
30 BuildRequires: jpeg-devel
31 BuildRequires: pkgconfig(libpng)
32 BuildRequires: pkgconfig(zlib)
33 BuildRequires: pkgconfig(liblzma)
34
35 %description
36 NoMachine NX is the next-generation X compression and roundtrip
37 suppression scheme. It can operate remote X11 sessions over
38 56k modem dialup links or anything better.
39 This package uses the patched and redistributed sources from the
40 x2go project.
41
42 %package -n %{lib_name_nxx11}
43 Summary: Nx-X11 lib for NX
44 Group: System/Libraries
45 Provides: nxX11 = %{version}-%{release}
46
47 %description -n %{lib_name_nxx11}
48 NX-X11 lib for the NX framework
49
50 %package -n %{lib_name_nxcomp}
51 Summary: Xcomp library for NX
52 Group: System/Libraries
53 Provides: xcomp = %{version}-%{release}
54
55 %description -n %{lib_name_nxcomp}
56 Xcomp library for NX subsystem
57
58 %package -n %{lib_name_xcompext}
59 Summary: Xcompext/Xcompshad library for NX
60 Group: System/Libraries
61 Provides: xcompext = %{version}-%{release}
62 Provides: xcompshad = %{version}-%{release}
63
64 %description -n %{lib_name_xcompext}
65 Xcompext and Xcompshad library needed by the NX framework
66
67 %package -n nxproxy
68 Summary: Provide the protocol compression and caching part of the NX scheme
69 Group: Networking/Remote access
70
71 %description -n nxproxy
72 The nxproxy runs on the X server side of the wire and thus accompanies
73 the nxagent running on X client side. It provides the protocol
74 compression and caching part of the NX scheme.
75
76 %package -n nxagent
77 Summary: NX X server based on Xnest
78 Group: Networking/Remote access
79
80 %description -n nxagent
81 The nxagent is an X server based on Xnest, but modified
82 for the purpose of reducing roundtrips over high-latency
83 networks significantly. It is run on the client side of X,
84 that is, on the machine where X clients run. It connects,
85 over the wire, to your regular X server, possibly through nxproxy.
86
87 %package -n x2goagent
88 Summary: Wrapper arround nxagent to use with x2goserver
89 Group: Networking/Remote access
90 Requires: nxagent
91
92 %description -n x2goagent
93 The x2goagent is a wrapper arround nxagent, that is used for running
94 x2goserver
95
96 %prep
97 %setup -q -n %{srcname}_%{version}
98
99 %build
100
101 cat >"tmp_configure" <<EOF
102 export CFLAGS="-O2 -g -pipe -Wformat -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4"
103 %ifarch x86_64 ppc64
104 export CFLAGS="$CFLAGS -fPIC -DPIC"
105 %endif
106 export CXXFLAGS="$CFLAGS"
107 export RPM_OPT_FLAGS="$CFLAGS"
108 export LDFLAGS="%{?__global_ldflags} -Wl,-rpath,%{_pkglibdir}"
109
110 CONFIGURE_TOP=".";
111 /usr/lib/rpm/mageia/force-as-needed-for-shared-lib-in-libtool ;
112 /usr/lib/rpm/mageia/drop-ld-no-undefined-for-shared-lib-modules-in-libtool ;
113 /usr/lib/rpm/mageia/fix-libtool-ltmain-from-overlinking ;
114 /usr/lib/rpm/mageia/fix-libtool-from-moving-options-after-libs ;
115 /usr/lib/rpm/mageia/fix-dlsearch-path-in-libtool-for-multilib lib64 ;
116 (cd ; [ ! -f configure.in -a ! -f configure.ac ] || libtoolize --copy --force);
117 [ -f ./configure.in -o -f /configure.ac ] &&
118 CONFIGURE_XPATH="--x-includes=/usr/include --x-libraries=/usr/lib64"
119 ./configure --prefix=%{_prefix} --exec-prefix=%{_prefix} --bindir=%{_bindir} \
120 --sbindir=%{_sbindir} --sysconfdir=%{_sysconfdir} --datadir=%{_datadir} \
121 --includedir=%{_includedir} --libdir=%{_libdir} --libexecdir=%{_libdir} \
122 --localstatedir=%{_localstatedir} --mandir=%{_mandir} \
123 --infodir=%{_infodir}
124 EOF
125
126 chmod a+x tmp_configure
127 make CONFIGURE="$PWD/tmp_configure"
128
129 %install
130 #%makeinstall_std PREFIX="%{_prefix}" \
131 # INSTALL_DIR="install -dm0755" \
132 # INSTALL_FILE="install -pm0644" \
133 # INSTALL_PROGRAM="install -pm0755"
134 #rm -rf %{buildroot}%{_sysconfdir}/fonts
135 #rm -rf %{buildroot}%{_includedir}/GL
136 #find %{buildroot} -name "*.la" -delete
137 #find %{buildroot} -name "*.a" -delete
138 mkdir -p %{buildroot}%{_bindir}
139 mkdir -p %{buildroot}%{_pkglibdir}
140 mkdir -p %{buildroot}%{_pkglibexecdir}
141 mkdir -p %{buildroot}%{_mandir}/man1
142
143 # install X11 Support Libraries and Agents
144 install -pm0755 \
145 nx-X11/lib/freetype2/libNX_freetype.so.*.* \
146 nx-X11/lib/X11/libNX_X11.so.*.* \
147 nx-X11/lib/Xau/libNX_Xau.so.*.* \
148 nx-X11/lib/Xcomposite/libNX_Xcomposite.so.*.* \
149 nx-X11/lib/Xdamage/libNX_Xdamage.so.*.* \
150 nx-X11/lib/Xdmcp/libNX_Xdmcp.so.*.* \
151 nx-X11/lib/Xext/libNX_Xext.so.*.* \
152 nx-X11/lib/Xfixes/libNX_Xfixes.so.*.* \
153 nx-X11/lib/Xinerama/libNX_Xinerama.so.*.* \
154 nx-X11/lib/Xpm/libNX_Xpm.so.*.* \
155 nx-X11/lib/Xrandr/libNX_Xrandr.so.*.* \
156 nx-X11/lib/Xrender/libNX_Xrender.so.*.* \
157 nx-X11/lib/Xtst/libNX_Xtst.so.*.* \
158 %{buildroot}%{_pkglibdir}
159 install -pm0755 nx-X11/programs/Xserver/nxagent \
160 %{buildroot}%{_pkglibexecdir}
161 install -pm0755 nx-X11/programs/nxauth/nxauth \
162 %{buildroot}%{_pkglibexecdir}
163
164 # install Compression Libraries and Proxy
165 install -pm0755 nxcomp/libXcomp.so.*.* \
166 nxcompext/libXcompext.so.*.* \
167 nxcompshad/libXcompshad.so.*.* \
168 %{buildroot}%{_pkglibdir}
169 install -pm0755 nxproxy/nxproxy %{buildroot}%{_pkglibexecdir}
170
171 # set up shared lib symlinks
172 /sbin/ldconfig -n %{buildroot}%{_pkglibdir}
173
174 cat > %{buildroot}%{_bindir}/nxagent << EOF
175 #!/bin/sh
176 LD_LIBRARY_PATH="%{_pkglibdir}:\$LD_LIBRARY_PATH" exec "%{_pkglibexecdir}/nxagent" "\$@"
177 EOF
178
179 cat > %{buildroot}%{_bindir}/nxauth << EOF
180 #!/bin/sh
181 LD_LIBRARY_PATH="%{_pkglibdir}:\$LD_LIBRARY_PATH" exec "%{_pkglibexecdir}/nxauth" "\$@"
182 EOF
183
184 cat > %{buildroot}%{_bindir}/nxproxy << EOF
185 #!/bin/sh
186 LD_LIBRARY_PATH="%{_pkglibdir}:\$LD_LIBRARY_PATH" exec "%{_pkglibexecdir}/nxproxy" "\$@"
187 EOF
188
189 # create x2goagent symlink
190 ln -s %{_bindir}/nxagent %{buildroot}%{_bindir}/x2goagent
191 mkdir -p %{buildroot}%{_datadir}/pixmaps/
192 mkdir -p %{buildroot}%{_mandir}/man1/
193 install -pm0644 nx-X11/programs/Xserver/hw/nxagent/x2go.xpm %{buildroot}%{_datadir}/pixmaps/
194 install -pm0644 nx-X11/programs/Xserver/hw/nxagent/man/x2goagent.1 %{buildroot}%{_mandir}/man1/
195 install -pm0644 nx-X11/programs/Xserver/hw/nxagent/man/nxagent.1 %{buildroot}%{_mandir}/man1/
196 install -pm0644 nxproxy/man/nxproxy.1 %{buildroot}%{_mandir}/man1/
197
198 #install doc files
199 for i in nxcomp nxcompext nxcompshad nxproxy nx-X11 \
200 nx-X11/programs/nxauth nx-X11/programs/Xserver/hw/nxagent; do
201 for j in CHANGELOG COPYING LICENSE; do
202 [ -f $i/$j ] && install -Dpm 0644 $i/$j \
203 %{buildroot}%{_defaultdocdir}/%{name}-%{version}/${i##*/}/$j
204 done
205 done
206
207 %files -n nxproxy
208 %dir %{_pkglibdir}
209 %dir %{_defaultdocdir}/%{name}-%{version}
210 %{_pkglibdir}/nxproxy
211 %attr(0755,root,root) %{_bindir}/nxproxy
212 %{_mandir}/man1/nxproxy*
213 %doc %{_defaultdocdir}/%{name}-%{version}/nxproxy
214
215 %files -n nxagent
216 %dir %{_pkglibdir}
217 %dir %{_defaultdocdir}/%{name}-%{version}
218 %{_pkglibdir}/nxagent
219 %attr(0755,root,root) %{_bindir}/nxagent
220 %{_mandir}/man1/nxagent*
221 %doc %{_defaultdocdir}/%{name}-%{version}/nxagent
222
223 %files -n %{lib_name_nxx11}
224 %dir %{_pkglibdir}
225 %dir %{_defaultdocdir}/%{name}-%{version}
226 %{_pkglibdir}/libNX_freetype*.so.*
227 %{_pkglibdir}/libNX_X11*.so.*
228 %{_pkglibdir}/libNX_Xau*.so.*
229 %{_pkglibdir}/libNX_Xcomposite*.so.*
230 %{_pkglibdir}/libNX_Xdamage*.so.*
231 %{_pkglibdir}/libNX_Xdmcp*.so.*
232 %{_pkglibdir}/libNX_Xext*.so.*
233 %{_pkglibdir}/libNX_Xfixes*.so.*
234 %{_pkglibdir}/libNX_Xinerama*.so.*
235 %{_pkglibdir}/libNX_Xpm*.so.*
236 %{_pkglibdir}/libNX_Xrandr*.so.*
237 %{_pkglibdir}/libNX_Xrender*.so.*
238 %{_pkglibdir}/libNX_Xtst*.so.*
239 %{_pkglibdir}/nxauth
240 %attr(0755,root,root) %{_bindir}/nxauth
241 %doc %{_defaultdocdir}/%{name}-%{version}/nx-X11
242 %doc %{_defaultdocdir}/%{name}-%{version}/nxauth
243
244 %files -n %{lib_name_nxcomp}
245 %dir %{_pkglibdir}
246 %dir %{_defaultdocdir}/%{name}-%{version}
247 %{_pkglibdir}/libXcomp.so.*
248 %doc %{_defaultdocdir}/%{name}-%{version}/nxcomp
249
250 %files -n %{lib_name_xcompext}
251 %dir %{_pkglibdir}
252 %dir %{_defaultdocdir}/%{name}-%{version}
253 %{_pkglibdir}/libXcompext.so.*
254 %{_pkglibdir}/libXcompshad.so.*
255 %doc %{_defaultdocdir}/%{name}-%{version}/nxcompext
256 %doc %{_defaultdocdir}/%{name}-%{version}/nxcompshad
257
258 %files -n x2goagent
259 %{_bindir}/x2goagent
260 %{_mandir}/man1/x2goagent*
261 %{_datadir}/pixmaps/x2go.xpm

  ViewVC Help
Powered by ViewVC 1.1.30