File libvarlink.spec of Package libvarlink
#
# spec file for package libvarlink
#
# 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: libvarlink
Version: 23
Release: 0
Summary: Varlink C library and command line tool
License: MIT
Group: Development/Languages/C and C++
URL: https://github.com/varlink/libvarlink
Source0: https://github.com/varlink/libvarlink/archive/refs/tags/%{version}.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires: gcc
BuildRequires: glibc-lang
BuildRequires: meson
BuildRequires: ninja
%{?suse_build_hwcaps_libs}
%description
Varlink is an interface description format and protocol that aims to make
services accessible to both humans and machines in the simplest feasible way.
A varlink interface combines the classic UNIX command line options,
STDIN/OUT/ERROR text formats, man pages, service metadata and provides the
equivalent over a single file descriptor, a.k.a. “FD3”.
Varlink is plain-text, type-safe, discoverable, self-documenting, remotable,
testable, easy to debug. Varlink is accessible from any programming
environment.
%package -n libvarlink0
Summary: Varlink C library
Group: System/Libraries
%description -n libvarlink0
Varlink is an interface description format and protocol that aims to make
services accessible to both humans and machines in the simplest feasible way.
A varlink interface combines the classic UNIX command line options,
STDIN/OUT/ERROR text formats, man pages, service metadata and provides the
equivalent over a single file descriptor, a.k.a. “FD3”.
Varlink is plain-text, type-safe, discoverable, self-documenting, remotable,
testable, easy to debug. Varlink is accessible from any programming
environment.
%package devel
Summary: Varlink C development files
Group: Development/Languages/C and C++
Requires: libvarlink0 = %{version}
%description devel
Varlink is an interface description format and protocol that aims to make
services accessible to both humans and machines in the simplest feasible way.
A varlink interface combines the classic UNIX command line options,
STDIN/OUT/ERROR text formats, man pages, service metadata and provides the
equivalent over a single file descriptor, a.k.a. “FD3”.
Varlink is plain-text, type-safe, discoverable, self-documenting, remotable,
testable, easy to debug. Varlink is accessible from any programming
environment.
%package bash-completion
Summary: Bash Completion for %{name}
Group: System/Shells
Supplements: (%{name} and bash-completion)
Requires: bash-completion
BuildArch: noarch
%description bash-completion
Bash command-line completion support for %{name}.
%package vim
Summary: Vim support for %{name}
Group: System/Shells
Supplements: (%{name} and vim)
Requires: vim
BuildArch: noarch
%description vim
Varlink is an interface description format and protocol that aims to make
services accessible to both humans and machines in the simplest feasible way.
A varlink interface combines the classic UNIX command line options,
STDIN/OUT/ERROR text formats, man pages, service metadata and provides the
equivalent over a single file descriptor, a.k.a. “FD3”.
Varlink is plain-text, type-safe, discoverable, self-documenting, remotable,
testable, easy to debug. Varlink is accessible from any programming
environment.
%package util
Summary: Varlink command line tools
Requires: %{name}-vim
Requires: %{name}-bash-completion
%description util
This contains command-line tools and vim editor support for varlink.
%prep
%autosetup -p1
%build
%meson
%meson_build
%install
%meson_install
%post -n libvarlink0 -p %{_sbindir}/ldconfig
%postun -n libvarlink0 -p %{_sbindir}/ldconfig
%files util
%{_bindir}/varlink
%license LICENSE
%doc README.md
%files devel
%{_includedir}/varlink.h
%{_libdir}/libvarlink.so
%{_libdir}/pkgconfig/libvarlink.pc
%license LICENSE
%doc README.md
%files -n libvarlink0
%{_libdir}/libvarlink.so.0
%license LICENSE
%doc README.md
%files bash-completion
%{_datadir}/bash-completion/completions/varlink
%license LICENSE
%doc README.md
%files vim
%dir %{_datadir}/vim
%dir %{_datadir}/vim/vimfiles
%dir %{_datadir}/vim/vimfiles/after
%dir %{_datadir}/vim/vimfiles/after/ftdetect
%dir %{_datadir}/vim/vimfiles/after/ftplugin
%dir %{_datadir}/vim/vimfiles/after/syntax
%{_datadir}/vim/vimfiles/after/ftdetect/varlink.vim
%{_datadir}/vim/vimfiles/after/ftplugin/varlink.vim
%{_datadir}/vim/vimfiles/after/syntax/varlink.vim
%license LICENSE
%doc README.md
%changelog