File mingw64-expat.spec of Package mingw64-expat

#
# spec file for package mingw64-expat
#
# Copyright (c) 2016 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 http://bugs.opensuse.org/
#

%global unversion 2_7_1
Name:           mingw64-expat
Version:        2.7.1
Release:        0
Summary:        MinGW Windows port of expat XML parser library
License:        MIT
Group:          Development/Libraries/C and C++
URL:            https://libexpat.github.io
Source0:        https://github.com/libexpat/libexpat/releases/download/R_%{unversion}/expat-%{version}.tar.xz
BuildRequires:  mingw64-cross-gcc-c++
BuildRequires:  mingw64-cross-pkg-config
%_mingw64_package_header_debug
BuildArch:      noarch

%description
This is expat, the C library for parsing XML, written by James Clark. Expat
is a stream oriented XML parser. This means that you register handlers with
the parser prior to starting the parse. These handlers are called when the
parser discovers the associated structures in the document being parsed. A
start tag is an example of the kind of structures for which you may
register handlers.

%package -n mingw64-libexpat1
Summary:        MinGW Windows port of expat XML parser library
Group:          System/Libraries

%description -n mingw64-libexpat1
This is expat, the C library for parsing XML, written by James Clark. Expat
is a stream oriented XML parser. This means that you register handlers with
the parser prior to starting the parse. These handlers are called when the
parser discovers the associated structures in the document being parsed. A
start tag is an example of the kind of structures for which you may
register handlers.

%package -n mingw64-libexpat-devel
Summary:        MinGW Windows port of expat XML parser library
Group:          Development/Libraries/C and C++
Requires:       mingw64-libexpat1

%description -n mingw64-libexpat-devel
This is expat, the C library for parsing XML, written by James Clark. Expat
is a stream oriented XML parser. This means that you register handlers with
the parser prior to starting the parse. These handlers are called when the
parser discovers the associated structures in the document being parsed. A
start tag is an example of the kind of structures for which you may
register handlers.

%_mingw64_debug_package

%prep
%setup -q -n expat-%{version}

%build
%{_mingw64_configure} \
	--disable-static --enable-shared
make %{?_smp_mflags} || make

%install
make DESTDIR=%{buildroot} install %{?_smp_mflags}

%files
%{_mingw64_bindir}/xmlwf.exe
%{_mingw64_mandir}/man1
%{_mingw64_datadir}/doc

%files -n mingw64-libexpat1
%{_mingw64_bindir}/libexpat-1.dll

%files -n mingw64-libexpat-devel
%{_mingw64_includedir}/expat.h
%{_mingw64_includedir}/expat_config.h
%{_mingw64_includedir}/expat_external.h
%{_mingw64_libdir}/libexpat.dll.a
%{_mingw64_libdir}/pkgconfig/expat.pc
%{_mingw64_libdir}/cmake/expat-%{version}

%changelog
openSUSE Build Service is sponsored by