File mingw64-tre.spec of Package mingw64-tre

#
# spec file for package mingw64-tre
#
# Copyright (c) 2014 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/
#


Name:           mingw64-tre
Version:        0.8.0
Release:        0
Summary:        POSIX compatible regexp library with approximate matching
License:        BSD-3-Clause
Group:          System/Libraries
Url:            http://laurikari.net/tre/
Source0:        http://laurikari.net/tre/tre-%{version}.tar.bz2
Patch0:         tre.diff
BuildRequires:  mingw64-cross-binutils
BuildRequires:  mingw64-cross-gcc
BuildRequires:  mingw64-cross-pkg-config
BuildRequires:  mingw64-filesystem
BuildRequires:  mmv
%_mingw64_package_header_debug
BuildArch:      noarch
#!BuildIgnore: post-build-checks

%description
TRE is a lightweight, robust, and efficient POSIX compatible regexp
matching library with some exciting features such as approximate
matching.

%package -n mingw64-libtre5
Summary:        POSIX compatible regexp library with approximate matching
Group:          System/Libraries

%description -n mingw64-libtre5
TRE is a lightweight, robust, and efficient POSIX compatible regexp
matching library with some exciting features such as approximate
matching.

%package devel
Summary:        POSIX compatible regexp library with approximate matching
Group:          Development/Libraries/C and C++

%description devel
TRE is a lightweight, robust, and efficient POSIX compatible regexp
matching library with some exciting features such as approximate
matching.

%package -n mingw64-agrep
Summary:        Another powerful grep with interesting features
Group:          Productivity/Text/Utilities

%description -n mingw64-agrep
agrep is another powerful grep which has the  ability to search for
approximate patterns as well as block oriented search.

%_mingw64_debug_package

%prep
%setup -q -n tre-%{version}
%patch -P 0 -p1

%build
%{_mingw64_env}
%{_mingw64_configure} --enable-shared
make %{?_smp_mflags}

%install
make DESTDIR=%{buildroot} install %{?_smp_mflags}
mmv %{buildroot}/%{_mingw64_bindir}/%{_mingw64_target}-\* "%{buildroot}/%{_mingw64_bindir}/#1"
mmv %{buildroot}/%{_mingw64_mandir}/man1/%{_mingw64_target}-\* "%{buildroot}/%{_mingw64_mandir}/man1/#1"

#rm -f $RPM_BUILD_ROOT/%{_mingw64_libdir}/*.la
#rm -rf $RPM_BUILD_ROOT/usr/share/locale/

%files -n mingw64-libtre5
%defattr (-, root, root)
%{_mingw64_bindir}/libtre*.dll

%files devel
%defattr (-, root, root)
%doc ABOUT-NLS AUTHORS LICENSE NEWS README THANKS TODO
%doc doc/default.css doc/tre-api.html doc/tre-syntax.html
%{_mingw64_includedir}/*
%{_mingw64_libdir}/libtre.dll.a
%{_mingw64_libdir}/pkgconfig/*

%files -n mingw64-agrep
%defattr (-, root, root)
%{_mingw64_bindir}/agrep.exe
%{_mingw64_mandir}/man1/agrep.1.gz

%changelog
openSUSE Build Service is sponsored by