packaging: Bump up to 1.0.3
[platform/upstream/libxkbcommon.git] / packaging / libxkbcommon.spec
1 Name:           libxkbcommon
2 Version:        1.0.3
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         -Denable-xkbregistry=false \
58         --prefix /usr \
59         --libdir %{_libdir} \
60         builddir
61 ninja -C builddir all
62
63 %install
64 export DESTDIR=%{buildroot}
65 ninja -C builddir install
66
67 %post  -p /sbin/ldconfig
68
69 %postun  -p /sbin/ldconfig
70
71 %files
72 %manifest %{name}.manifest
73 %defattr(-,root,root)
74 %license COPYING
75 %{_libdir}/libxkbcommon.so.0*
76
77 %files devel
78 %manifest %{name}.manifest
79 %defattr(-,root,root)
80 %{_includedir}/xkbcommon
81 %{_libdir}/libxkbcommon.so
82 %{_libdir}/pkgconfig/xkbcommon.pc
83