File idutils.spec of Package idutils

# spec file for package idutils
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
# 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

Name:           idutils
Version:        4.6
Release:        0
Summary:        Language-Independent Identifier Database Tool
License:        GPL-2.0+
Group:          Productivity/Text/Utilities
Source2:        %{name}.keyring
BuildRequires:  emacs-nox
BuildRequires:  xz
Requires(preun): %{install_info_prereq}
Requires(post): %{install_info_prereq}
Recommends:     %{name}-lang
Provides:       id-utils
Obsoletes:      id-utils
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

Mkid is a simple, fast, high-capacity, and language-independent
identifier database tool.  Actually, the term identifier is too
limiting--mkid stores tokens, be they program identifiers of any form,
literal numbers, or ordinary words.  Database queries can be issued
from the command line or from within Emacs, serving as an augmented
tags facility.


%setup -q

# fix gets compile error
sed -i -e '/gets is a security/d' lib/
make %{?_smp_mflags}

make DESTDIR=%{buildroot} install %{?_smp_mflags}
install -d %{buildroot}%{_localstatedir}/lib/idutils
mv %{buildroot}%{_datadir}/ %{buildroot}%{_localstatedir}/lib/idutils
ln -s ../..%{_localstatedir}/lib/idutils/ %{buildroot}%{_datadir}/
# Conflict with libuser
rm -f %{buildroot}%{_mandir}/man1/lid.1
%find_lang %{name}

if test -f %{_infodir}/; then
  mv %{_infodir}/ %{_infodir}/
  %install_info_delete --info-dir=%{_infodir} %{_infodir}/
  mv %{_infodir}/ %{_infodir}/
%install_info --info-dir=%{_infodir} %{_infodir}/

%install_info_delete --info-dir=%{_infodir} %{_infodir}/

%config %{_localstatedir}/lib/idutils/
%dir %{_localstatedir}/lib/idutils

%files lang -f %{name}.lang

openSUSE Build Service is sponsored by