File mingw64-libmodman.spec of Package mingw64-libmodman

#
# spec file for package mingw64-libmodman
#
# 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-libmodman
Version:        2.0.1
Release:        0
Summary:        A Module Management Library
License:        LGPL-2.1-or-later
Group:          System/Libraries
Url:            http://code.google.com/p/libmodman/
Source:         libmodman-%{version}.tar.gz
Patch0:         libmodman-2.0.1-windows.patch
BuildRequires:  mingw64-cross-cmake
BuildRequires:  mingw64-cross-binutils
BuildRequires:  mingw64-cross-gcc
BuildRequires:  mingw64-cross-gcc-c++
BuildRequires:  mingw64-filesystem
%_mingw64_package_header_debug
BuildArch:      noarch
#!BuildIgnore: post-build-checks

%description
The Module Loading library offers the choice to use prelinked libraries
from your application out of a pool.

%package devel
Summary:        A Module Management Library - Development headers
Group:          System/Libraries

%description devel
The Module Loading library offers the choice to use prelinked libraries
from your application out of a pool.

This package is needed to develop applications using libmodman.

%_mingw64_debug_package

%prep
%setup -q -n libmodman-%{version}
%patch -P 0 -p1 -b .windows

%build
rm -rf CMakeCache.txt
%{_mingw64_cmake} \
	-DCMAKE_RC_COMPILER="%{_bindir}/%{_mingw64_windres}" \
	-DSHARE_INSTALL_DIR=%{_mingw64_datadir} .
%{_mingw64_cmake_build}

%install
%{_mingw64_cmake_install}
mkdir -p %{buildroot}%{_mingw64_bindir}
mv %{buildroot}%{_mingw64_libdir}/*.dll %{buildroot}%{_mingw64_bindir}

%files
%defattr(-,root,root)
%{_mingw64_bindir}/libmodman.dll

%files devel
%defattr(-,root,root)
%{_mingw64_libdir}/libmodman.dll.a
%{_mingw64_includedir}/libmodman/module.hpp
%{_mingw64_includedir}/libmodman/module_manager.hpp
%{_mingw64_datadir}/cmake/Modules/Findlibmodman.cmake

%changelog
openSUSE Build Service is sponsored by