File kmflcomp.spec of Package kmflcomp
#
# spec file for package kmflcomp
#
# Copyright (c) 2024 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: kmflcomp
Version: 0.9.10
Release: 0
Summary: Keyboard Compiler for KMFL
License: GPL-2.0-or-later
Group: System/X11/Utilities
URL: https://kmfl.sourceforge.net/
Source0: http://download.sourceforge.net/kmfl/%{name}-%{version}.tar.gz
Source1: http://download.sourceforge.net/kmfl/KMFL-Compiler.sxw
# PATCH-FIX-OPENSUSE kmflcomp-shared.patch lazy.kent@opensuse.org -- link to a shared library
Patch0: kmflcomp-shared.patch
# PATCH-FIX-UPSTREAM kmflcomp-0.9.10-version.patch lazy.kent@opensuse.org -- fix displayed program version
Patch1: kmflcomp-0.9.10-version.patch
Patch2: kmflcomp-0.9.10-incompatible-pointer-types.patch
BuildRequires: bison
BuildRequires: libX11-devel
%description
KMFLcomp is an application to create the compiled keyboard files used by
LIBKMFL from the keyboard source files specifying the rules for keyboard
mapping.
%package -n libkmflcomp0
Summary: KMFLcomp Shared Library
Group: System/Libraries
%description -n libkmflcomp0
Library to compile Keyman-style keyboard layout files.
%package devel
Summary: KMFLcomp Development Files
Group: Development/Libraries/C and C++
Requires: libkmflcomp0 = %{version}
Provides: libkmflcomp-devel = %{version}
Obsoletes: libkmflcomp-devel < 0.9.10
%description devel
Development files for KMFL compiler.
%prep
%autosetup -p1
install -m 0644 %{SOURCE1} .
%build
%configure --disable-static
%make_build
%install
%make_install
rm -rf %{buildroot}{%{_prefix}/doc,%{_libdir}/libkmflcomp.*a}
%post -n libkmflcomp0 -p /sbin/ldconfig
%postun -n libkmflcomp0 -p /sbin/ldconfig
%files
%license COPYING
%doc AUTHORS ChangeLog KMFL-Compiler.sxw
%{_bindir}/%{name}
%files -n libkmflcomp0
%{_libdir}/*.so.*
%files devel
%{_includedir}/kmfl
%{_libdir}/*.so
%changelog