packaging: Bump up to 0.10.0
[platform/upstream/libxkbcommon.git] / packaging / libxkbcommon.spec
1 Name:           libxkbcommon
2 Version:        0.10.0
3 Release:        0
4 License:        MIT
5 Summary:        Wayland libxkbcommon library
6 Url:            http://wayland.freedesktop.org/
7 Group:          Development/Libraries
8
9 Source:         %{name}-%{version}.tar.xz
10 #X-Vcs-Url:     https://github.com/xkbcommon/libxkbcommon.git
11 Source1001:     libxkbcommon.manifest
12 BuildRequires:  meson
13 BuildRequires:  bison
14 BuildRequires:  flex
15 BuildRequires:  libtool >= 2
16 BuildRequires:  pkgconfig(xorg-macros) >= 1.8
17 BuildRequires:  python
18 BuildRequires:  xkb-tizen-data
19 BuildRequires:  gawk
20
21 ## This BuildRequires is needed when an enable-wayland option is true.
22 #BuildRequires:  pkgconfig(wayland-client)
23 #BuildRequires:  wayland-protocols
24
25 %global TZ_SYS_RO_SHARE  %{?TZ_SYS_RO_SHARE:%TZ_SYS_RO_SHARE}%{!?TZ_SYS_RO_SHARE:/usr/share}
26
27 %description
28 Keyboard handling library using XKB data.
29
30 %package devel
31 Summary:        Development files for the Wayland libxkbcommon library
32 Group:          Development/Libraries
33 Requires:       %{name} = %{version}-%{release}
34
35 %description devel
36 Keyboard handling library using XKB data.
37
38 This package contains the development headers for the library found
39 in %{name}.
40
41 %prep
42 %setup -q
43 cp %{SOURCE1001} .
44
45 # Generate tizen keymap header
46 export TZ_SYS_RO_SHARE="%{TZ_SYS_RO_SHARE}"
47 chmod a+x ./make_tizen_keymap.sh
48 ./make_tizen_keymap.sh
49 chmod a+x ./gen_tables.sh
50 ./gen_tables.sh
51
52 %build
53 meson setup \
54     -Denable-x11=false \
55     -Denable-docs=false \
56     -Denable-wayland=false \
57         --prefix /usr \
58         --libdir %{_libdir} \
59         builddir
60 ninja -C builddir all
61
62 %install
63 export DESTDIR=%{buildroot}
64 ninja -C builddir install
65
66 %post  -p /sbin/ldconfig
67
68 %postun  -p /sbin/ldconfig
69
70 %files
71 %manifest %{name}.manifest
72 %defattr(-,root,root)
73 %license COPYING
74 %{_libdir}/libxkbcommon.so.0*
75
76 %files devel
77 %manifest %{name}.manifest
78 %defattr(-,root,root)
79 %{_includedir}/xkbcommon
80 %{_libdir}/libxkbcommon.so
81 %{_libdir}/pkgconfig/xkbcommon.pc
82