upload tizen2.0 source
[framework/uifw/xorg/util/x11-xkb-utils.git] / packaging / xorg-x11-xkb-utils.spec
1 Summary: X.Org X11 xkb utilities
2 Name: xorg-x11-xkb-utils
3 Version: 7.7
4 Release: 1
5 License: MIT
6 Group: User Interface/X
7 URL: http://www.x.org
8 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
9
10 # use the macro so the doc dir is changed automagically
11 #%define xkbutils_version 1.0.3
12 #Source0: ftp://ftp.x.org/pub/individual/app/xkbutils-%{xkbutils_version}.tar.bz2
13 #Source1: ftp://ftp.x.org/pub/individual/app/xkbcomp-1.2.4.tar.bz2
14 #Source2: ftp://ftp.x.org/pub/individual/app/xkbevd-1.1.3.tar.bz2
15 #Source3: ftp://ftp.x.org/pub/individual/app/xkbprint-1.0.3.tar.bz2
16 #Source4: ftp://ftp.x.org/pub/individual/app/setxkbmap-1.3.0.tar.bz2
17
18 Source: %{name}-%{version}.tar.gz
19
20 BuildRequires: pkgconfig
21 BuildRequires: byacc
22 BuildRequires: xorg-x11-proto-input
23 BuildRequires: libxkbfile-devel
24 BuildRequires: libX11-devel
25 BuildRequires: libXaw-devel
26 BuildRequires: libXt-devel
27 # FIXME: xkbvleds requires libXext, but autotools doesn't check/require it:
28 # gcc  -O2 -g -march=i386 -mcpu=i686   -o xkbvleds  xkbvleds-xkbvleds.o
29 # xkbvleds-LED.o xkbvleds-utils.o -lXaw7 -lXmu -lXt -lSM -lICE -lXext -lXpm -lX11 -ldl
30 # /usr/bin/ld: cannot find -lXext
31 # libXext-devel needed for xkbutils (from above error)
32 BuildRequires: libXext-devel
33 # FIXME: xkbvleds requires libXext, but autotools doesn't check/require it:
34 # gcc  -O2 -g -march=i386 -mcpu=i686   -o xkbvleds  xkbvleds-xkbvleds.o
35 # xkbvleds-LED.o xkbvleds-utils.o -lXaw7 -lXmu -lXt -lSM -lICE -lXext -lXpm -lX11 -ldl
36 # /usr/bin/ld: cannot find -lXpm
37 # libXpm-devel needed for xkbutils (from above error)
38 BuildRequires: libXpm-devel
39
40 Provides: setxkbmap xkbcomp
41 Obsoletes: XFree86 xorg-x11
42
43 %package devel
44 Summary:        X.Org X11 xkb utilities development package.
45 Group:          Development/Libraries
46 Requires:       pkgconfig
47 %description devel
48 X.Org X11 xkb utilities development files.
49
50 %package -n xorg-x11-xkb-extras
51 Summary: X.Org X11 xkb gadgets
52 Provides: xkbevd xkbprint xkbutils
53
54 %description
55 X.Org X11 xkb core utilities
56
57 %description -n xorg-x11-xkb-extras
58 X.Org X11 xkb gadgets
59
60 %prep
61 %setup -q
62 #%setup -q -c %{name}-%{version} -a1 -a2 -a3 -a4
63
64 %build
65 export CFLAGS="$CFLAGS $RPM_OPT_FLAGS -DHAVE_STRCASECMP -Os"
66 for pkg in xkbutils setxkbmap xkbcomp xkbevd xkbprint ; do
67     pushd $pkg*
68     [ $pkg == xkbcomp ] && rm xkbparse.c # force regen
69     %configure --prefix=/usr --datadir=/usr/etc
70     make %{?jobs:-j%jobs} V=1
71     popd
72 done
73
74 %install
75 rm -rf $RPM_BUILD_ROOT
76 for pkg in xkbutils setxkbmap xkbcomp xkbevd xkbprint ; do
77     pushd $pkg*
78     make install DESTDIR=$RPM_BUILD_ROOT
79     popd
80 done
81
82 %remove_docs
83
84 %clean
85 rm -rf $RPM_BUILD_ROOT
86
87 %files
88 %defattr(-,root,root,-)
89 %{_bindir}/setxkbmap
90 %{_bindir}/xkbcomp
91 #%{_mandir}/man1/setxkbmap.1*
92 #%{_mandir}/man1/xkbcomp.1*
93
94 %files -n xorg-x11-xkb-extras
95 %defattr(-,root,root,-)
96 #%doc xkbutils-%{xkbutils_version}/COPYING
97 #%doc xkbutils-%{xkbutils_version}/README
98 %{_bindir}/xkbbell
99 %{_bindir}/xkbevd
100 %{_bindir}/xkbprint
101 %{_bindir}/xkbvleds
102 %{_bindir}/xkbwatch
103 #%{_mandir}/man1/xkbbell.1*
104 #%{_mandir}/man1/xkbevd.1*
105 #%{_mandir}/man1/xkbprint.1*
106 #%{_mandir}/man1/xkbvleds.*
107 #%{_mandir}/man1/xkbwatch.*
108
109 %files devel
110 %defattr(-,root,root,-)
111 %{_libdir}/pkgconfig/xkbcomp.pc