File mecab.spec of Package mecab

#
# spec file for package mecab
#
# Copyright (c) 2012 SUSE LINUX Products 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 http://bugs.opensuse.org/
#

%define version 0.994

Summary: Yet Another Part-of-Speech and Morphological Analyzer
Name: mecab
BuildRequires: gcc-c++
%if 0%{?suse_version} > 0
Recommends: mecab-dic
%endif
Version: %{version}
Release: 1
Source: mecab-%{version}.tar.gz
Patch0: mecab-0.994_libexecdir.patch
License: BSD-3-Clause
URL: http://mecab.googlecode.com/svn/trunk/mecab/doc/index.html
Group: System/I18n/Japanese
BuildRoot: %{_tmppath}/%{name}-%{version}-root

%description
Yet Another Part-of-Speech and Morphological Analyzer.

Packager Note: this package is compiled with charset=UTF-8.

%package devel
Group: Development/Libraries/C and C++
Summary: Libraries for mecab developers
Requires: %{name} = %{version}

%description devel
Libraries for mecab: Yet Another Part-of-Speech and Morphological Analyzer.

Packager Note: this package is compiled with charset=UTF-8.

%prep
%autosetup -p1

%build
%configure --prefix=/usr --sysconfdir=%{_sysconfdir}/%{name} --with-charset=utf8
make all

%install
make DESTDIR=$RPM_BUILD_ROOT install

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%files
%defattr(-,root,root)
%doc README NEWS COPYING AUTHORS BSD GPL LGPL ChangeLog
%{_sysconfdir}/%{name}
%config %{_sysconfdir}/%{name}/mecabrc
%{_bindir}/*
%{_libdir}/*.so.*
%{_libdir}/*.so
%{_libexecdir}/%{name}
%{_libexecdir}/%{name}/*
%{_mandir}/man1/*

%files devel
%defattr(-,root,root)
%{_libdir}/*.a
%{_libdir}/*.la
%{_includedir}/*.h

%changelog
openSUSE Build Service is sponsored by