1 # TODO: modbus, system hidapi, openhaptics, ghost, wiiuse(GPL v3), libnifalcon, intersense, nidaqmx, viewpoint, phasespace, libfreespace
2 # NATIONAL_INSTRUMENTS, NIDAQ, USDIGITAL, MICROSCRIBE, MONITONNODE, TRIVISIOCOLIBRI ???
5 %bcond_without apidocs # do not build and package API docs
6 %bcond_without gpm # GPM Linux mouse interface support (GPL v2+)
7 %bcond_with mpi # MPI support
8 %bcond_without java # Java binding
10 %define with_gpl 0%{?with_gpm:1}
11 Summary: Virtual Reality Peripheral Network
12 Summary(pl.UTF-8): Sieć peryferiów do rzeczywistości wirtualnej (VR)
15 %define fver %(echo %{version} | tr . _)
17 License: Boost v1.0 (VRPN)%{?with_gpl:, depends on GPL libraries}
19 Source0: http://www.cs.unc.edu/Research/vrpn/downloads/%{name}_%{fver}.zip
20 # Source0-md5: 6cb32e51e6420385f2006f1aae58b457
21 Patch0: %{name}-install.patch
22 Patch1: %{name}-jsoncpp.patch
23 URL: http://www.cs.unc.edu/Research/vrpn/
24 BuildRequires: cmake >= 2.8.3
25 %{?with_apidocs:BuildRequires: doxygen}
26 %{?with_gpm:BuildRequires: gpm-devel}
27 BuildRequires: hidapi-devel >= 0.7.0
29 BuildRequires: jsoncpp-devel >= 0.7.0
30 BuildRequires: libstdc++-devel
31 BuildRequires: libusb-devel >= 1.0
32 %{?with_mpi:BuildRequires: mpi-devel}
33 BuildRequires: perl-Parse-RecDescent
34 BuildRequires: perl-base
35 BuildRequires: python-devel >= 1:2.7
36 BuildRequires: swig-python
37 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
40 The Virtual-Reality Peripheral Network (VRPN) is a set of classes
41 within a library and a set of servers that are designed to implement a
42 network-transparent interface between application programs and the set
43 of physical devices (tracker, etc.) used in a virtual-reality (VR)
44 system. The idea is to have a PC or other host at each VR station that
45 controls the peripherals (tracker, button device, haptic device,
46 analog inputs, sound, etc). VRPN provides connections between the
47 application and all of the devices using the appropriate
48 class-of-service for each type of device sharing this link. The
49 application remains unaware of the network topology. Note that it is
50 possible to use VRPN with devices that are directly connected to the
51 machine that the application is running on, either using separate
52 control programs or running all as a single program.
54 %description -l pl.UTF-8
55 VRPN (Virtual-Reality Peripheral Network) to biblioteka klas i zestaw
56 serwerów zaprojektowanych jako implementacja przezroczystego sieciowo
57 interfejsu między aplikacjami a zbiorem urządzeń fizycznych (takich
58 jak tracker), używanych w systemie wirtualnej rzeczywistości (VR).
59 Idea polega na umieszczeniu komputera PC lub innego na każdej stacji
60 kontrolującej urządzenia peryferyjne (tracker, przyciski, urządzenie
61 haptyczne, wejścia analogowe, dźwiękowe itp.). VRPN zapewnia
62 połączenia między aplikacją a wszystkimi urządzeniami używającymi
63 odpowiedniej klasy usług dla każdego typu urządzeń współdzielących to
64 połączenie. Dla aplikacji topologia sieci nie ma znaczenia. Należy
65 zauważyć, że można używać oprogramowania VRPN z urządzeniami
66 podłączonymi bezpośrednio do maszyny, na której działa aplikacja -
67 albo przy użyciu osobnych programów sterujących, albo w ramach
71 Summary: Header files for VRPN library
72 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki VRPN
73 Group: Development/Libraries
74 Requires: %{name} = %{version}-%{release}
77 Header files for VRPN library.
79 %description devel -l pl.UTF-8
80 Pliki nagłówkowe biblioteki VRPN.
83 Summary: VRPN API documentation
84 Summary(pl.UTF-8): Dokumentacja API biblioteki VRPN
88 API documentation for VRPN library.
90 %description apidocs -l pl.UTF-8
91 Dokumentacja API biblioteki VRPN.
94 Summary: Java binding to VRPN
95 Summary(pl.UTF-8): Wiązanie Javy do bibliotek VRPN
97 Requires: %{name} = %{version}-%{release}
99 %description -n java-vrpn
100 Java binding to VRPN.
102 %description -n java-vrpn -l pl.UTF-8
103 Wiązanie Javy do bibliotek VRPN.
105 %package -n python-vrpn
106 Summary: Python binding to VRPN
107 Summary(pl.UTF-8): Wiązania Pythona do bibliotek VRPN
108 Group: Libraries/Java
109 Requires: %{name} = %{version}-%{release}
111 %description -n python-vrpn
112 Python binding to VRPN.
114 %description -n python-vrpn -l pl.UTF-8
115 Wiązania Pythona do bibliotek VRPN.
126 -DSYSCONF_INSTALL_DIR=%{_sysconfdir}/vrpn \
127 %{?with_gpl:-DVRPN_GPL_SERVER=ON} \
128 -DVRPN_USE_GPM_MOUSE=%{?with_gpm:ON}%{!?with_gpm:OFF} \
129 -DVRPN_USE_LOCAL_HIDAPI=OFF \
130 -DVRPN_USE_LOCAL_JSONCPP=OFF \
131 -DVRPN_USE_MPI=%{?with_mpi:ON}%{!?with_mpi:OFF} \
132 -DVRPN_BUILD_PYTHON=ON
141 rm -rf $RPM_BUILD_ROOT
143 %{__make} -C build install \
144 DESTDIR=$RPM_BUILD_ROOT
146 %{__rm} $RPM_BUILD_ROOT%{_bindir}/{c_interface_example,checklogfile,client_and_server,clock_drift_estimator,forcedevice_test_client,forward,forwarderClient,last_of_sequence,logfilesenders,logfiletypes,printcereal,printvals,run_auxiliary_logger,sample_analog,sample_server,test*,text,textServer,tracker_to_poser}
148 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/source-docs
150 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
151 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
155 rm -rf $RPM_BUILD_ROOT
157 %post -p /sbin/ldconfig
158 %postun -p /sbin/ldconfig
161 %defattr(644,root,root,755)
162 %doc ChangeLog Format README README.Legal
163 %attr(755,root,root) %{_bindir}/add_vrpn_cookie
164 %attr(755,root,root) %{_bindir}/bdbox_client
165 %attr(755,root,root) %{_bindir}/ff_client
166 %attr(755,root,root) %{_bindir}/phan_client
167 %attr(755,root,root) %{_bindir}/sound_client
168 %attr(755,root,root) %{_bindir}/sphere_client
169 %attr(755,root,root) %{_bindir}/vrpn_HID_device_watcher
170 %attr(755,root,root) %{_bindir}/vrpn_LamportClock
171 %attr(755,root,root) %{_bindir}/vrpn_ping
172 %attr(755,root,root) %{_bindir}/vrpn_print_devices
173 %attr(755,root,root) %{_bindir}/vrpn_print_messages
174 %attr(755,root,root) %{_bindir}/vrpn_print_performance
175 %attr(755,root,root) %{_bindir}/vrpn_server
176 %attr(755,root,root) %{_bindir}/vrpn_streamPrint
177 %dir %{_sysconfdir}/vrpn
178 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/vrpn/vrpn.cfg
179 %attr(755,root,root) %{_libdir}/libgpsnmea.so
180 %attr(755,root,root) %{_libdir}/libquat.so
181 %attr(755,root,root) %{_libdir}/libvrpn.so
182 %attr(755,root,root) %{_libdir}/libvrpn_atmel.so
183 %attr(755,root,root) %{_libdir}/libvrpn_timecode_generator.so
184 %attr(755,root,root) %{_libdir}/libvrpnserver.so
187 %defattr(644,root,root,755)
188 %{_includedir}/latLonCoord.h
189 %{_includedir}/nmeaParser.h
190 %{_includedir}/quat.h
191 %{_includedir}/utmCoord.h
192 %{_includedir}/vrpn_*.h
196 %defattr(644,root,root,755)
197 %attr(755,root,root) %{_libdir}/libjava_vrpn.so
198 %{_javadir}/vrpn-%{version}.jar
201 %files -n python-vrpn
202 %defattr(644,root,root,755)
204 %attr(755,root,root) %{py_sitedir}/_vrpn_*.so
205 %attr(755,root,root) %{py_sitedir}/vrpn_*.py[co]
206 # "handwritten" binding
207 %attr(755,root,root) %{py_sitedir}/vrpn.so
211 %defattr(644,root,root,755)
212 %doc build/doxygen/docs-generated/html/*