]> git.pld-linux.org Git - packages/cwiid.git/blob - cwiid.spec
BR: pkgconfig, rpm-pythonprov
[packages/cwiid.git] / cwiid.spec
1 %define subver  fadf11e
2 %define rel             1
3 Summary:        Wiimote interface library
4 Name:           cwiid
5 Version:        0.6.00
6 Release:        0.%{rel}.%{subver}
7 License:        GPL v2+
8 Group:          Libraries
9 #Source0:       https://github.com/abstrakraft/cwiid/archive/%{name}-%{version}/%{name}-%{version}.tar.gz
10 Source0:        https://github.com/abstrakraft/cwiid/archive/%{subver}/%{name}-%{version}-%{subver}.tar.gz
11 # Source0-md5:  2d5430a465357242514942ae82139609
12 Source1:        wmgui.desktop
13 Patch0:         wmdemo-lib.patch
14 URL:            http://abstrakraft.org/cwiid/
15 BuildRequires:  autoconf
16 BuildRequires:  automake
17 BuildRequires:  bison
18 BuildRequires:  bluez-libs-devel
19 BuildRequires:  desktop-file-utils
20 BuildRequires:  flex
21 BuildRequires:  gawk
22 BuildRequires:  gtk+2-devel
23 BuildRequires:  pkgconfig
24 BuildRequires:  python-devel >= 2.4
25 BuildRequires:  rpm-pythonprov
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 %description
29 CWiiD is a library that enables your application to communicate with a
30 wiimote using a bluetooth connection.
31
32 %package devel
33 Summary:        Development files for %{name}
34 Group:          Development/Libraries
35 Requires:       %{name} = %{version}-%{release}
36 Requires:       bluez-libs-devel
37
38 %description devel
39 The %{name}-devel package contains libraries and header files for
40 developing applications that use %{name}.
41
42 %package -n python-%{name}
43 Summary:        Python binding for %{name}
44 Group:          Development/Languages
45 Requires:       %{name} = %{version}-%{release}
46 Obsoletes:      cwiid-python2
47
48 %description -n python-%{name}
49 Python2 binding for %{name}
50
51 %package utils
52 Summary:        Wiimote connection test application
53 Group:          Applications/System
54 Requires:       %{name} = %{version}-%{release}
55 Provides:       %{name}-wmgui = %{version}-%{release}
56 Obsoletes:      cwiid-wmgui < 0.6.00-7
57
58 %description utils
59 Applications to test the wiimote connection
60
61 %package wminput
62 Summary:        Enables using the wiimote as an input source
63 # The licence must be GPLv2 instead of GPLv2+ for this package
64 # since the file wminput/action_enum.txt is GPLv2 as stated
65 # in the file.
66 License:        GPL v2
67 Group:          Applications/System
68 Requires:       %{name} = %{version}-%{release}
69 Requires:       python-%{name} = %{version}-%{release}
70
71 %description wminput
72 This program allows the user to use the wiimote to emulate normal
73 system input sources like the mouse and keyboard.
74
75 %prep
76 %setup -qc
77 mv %{name}-*/* .
78 %patch0 -p1
79
80 %build
81 %{__aclocal}
82 %{__autoconf}
83 CC="%{__cc} %{rpmcflags}"
84 %configure \
85         --disable-ldconfig
86 %{__make}
87
88 %install
89 rm -rf $RPM_BUILD_ROOT
90 %{__make} install \
91         DESTDIR=$RPM_BUILD_ROOT
92
93 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}
94
95 rm -v $RPM_BUILD_ROOT%{_libdir}/libcwiid.a
96
97 desktop-file-install --dir=$RPM_BUILD_ROOT%{_desktopdir} %{SOURCE1}
98
99 %clean
100 rm -rf $RPM_BUILD_ROOT
101
102 %post   -p /sbin/ldconfig
103 %postun -p /sbin/ldconfig
104
105 %files
106 %defattr(644,root,root,755)
107 %doc AUTHORS NEWS README COPYING ChangeLog
108 %attr(755,root,root) %{_libdir}/libcwiid.so.1.0
109 %ghost %{_libdir}/libcwiid.so.1
110
111 %files devel
112 %defattr(644,root,root,755)
113 %{_includedir}/cwiid.h
114 %{_libdir}/libcwiid.so
115 %{_pkgconfigdir}/cwiid.pc
116
117 %files -n python-%{name}
118 %defattr(644,root,root,755)
119 %attr(755,root,root) %{py_sitedir}/cwiid.so
120 %{py_sitedir}/cwiid-%{version}-py*.egg-info
121
122 %files wminput
123 %defattr(644,root,root,755)
124 %doc doc/Xmodmap doc/wminput.list
125 %dir %{_sysconfdir}/cwiid
126 %dir %{_sysconfdir}/cwiid/wminput
127 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cwiid/wminput/acc_led
128 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cwiid/wminput/acc_ptr
129 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cwiid/wminput/buttons
130 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cwiid/wminput/default
131 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cwiid/wminput/gamepad
132 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cwiid/wminput/ir_ptr
133 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cwiid/wminput/neverball
134 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cwiid/wminput/nunchuk_acc_ptr
135 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cwiid/wminput/nunchuk_stick2btn
136 %attr(755,root,root) %{_bindir}/wminput
137 %{_mandir}/man1/wminput.1*
138 %dir %{_libdir}/%{name}
139 %dir %{_libdir}/%{name}/plugins
140 %attr(755,root,root) %{_libdir}/%{name}/plugins/acc.so
141 %attr(755,root,root) %{_libdir}/%{name}/plugins/ir_ptr.so
142 %attr(755,root,root) %{_libdir}/%{name}/plugins/led.so
143 %attr(755,root,root) %{_libdir}/%{name}/plugins/nunchuk_acc.so
144 %attr(755,root,root) %{_libdir}/%{name}/plugins/nunchuk_stick2btn.so
145
146 %files utils
147 %defattr(644,root,root,755)
148 %attr(755,root,root) %{_bindir}/lswm
149 %attr(755,root,root) %{_bindir}/wmgui
150 %{_mandir}/man1/wmgui.1*
151 %{_desktopdir}/wmgui.desktop
This page took 0.099776 seconds and 3 git commands to generate.