File mingw64-glibmm2.spec of Package mingw64-glibmm2

#
# spec file for package mingw64-glibmm2
#
# 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/
#

# Update baselibs.conf when changing this
%define so_ver -2_68-1
# Define a baseversion to ease updates
%define base_ver 2.68
# Define upstream name
%define _name glibmm

Name:           mingw64-glibmm2
Version:        2.68.2
Release:        0
Summary:        C++ Interface for Glib
License:        LGPL-2.1-or-later
Group:          Development/Libraries/C and C++
Url:            https://www.gtkmm.org/
Source:         https://download.gnome.org/sources/glibmm/%{base_ver}/%{_name}-%{version}.tar.xz
#!BuildIgnore: post-build-checks
BuildRequires:  gcc-c++
BuildRequires:  glib2-devel
BuildRequires:  m4
BuildRequires:  mingw64-cross-gcc-c++
BuildRequires:  mingw64-cross-meson
BuildRequires:  mingw64-cross-pkg-config
BuildRequires:  mingw64(pkg:gio-2.0)
BuildRequires:  mingw64(pkg:glib-2.0) >= 2.61.2
BuildRequires:  mingw64(pkg:gmodule-2.0)
BuildRequires:  mingw64(pkg:gobject-2.0)
BuildRequires:  mingw64(pkg:sigc++-3.0)
BuildRequires:  xz
%_mingw64_package_header_debug
BuildArch:      noarch

%description
Glibmm is the official C++ interface for the popular cross-platform
library Glib. It provides non-UI API that is not available in standard
C++ and makes it possible for gtkmm to wrap GObject-based APIs.

%package -n mingw64-libglibmm%{so_ver}
Summary:        C++ Interface for Glib
Group:          System/Libraries

%description -n mingw64-libglibmm%{so_ver}
Glibmm is the official C++ interface for the popular cross-platform
library Glib. It provides non-UI API that is not available in standard
C++ and makes it possible for gtkmm to wrap GObject-based APIs.

%package -n mingw64-libgiomm%{so_ver}
Summary:        C++ Interface for Gio
Group:          System/Libraries

%description -n mingw64-libgiomm%{so_ver}
Glibmm is the official C++ interface for the popular cross-platform
library Glib. It provides non-UI API that is not available in standard
C++ and makes it possible for gtkmm to wrap GObject-based APIs.

%package devel
Summary:        Development files for the Glib C++ API
Group:          Development/Libraries/C and C++
Requires:       mingw64-libgiomm%{so_ver} = %{version}
Requires:       mingw64-libglibmm%{so_ver} = %{version}
Provides:       %{name}-doc = %{version}
Obsoletes:      %{name}-doc < %{version}

%description devel
Glibmm is the official C++ interface for the popular cross-platform
library Glib. It provides non-UI API that is not available in standard
C++ and makes it possible for gtkmm to wrap GObject-based APIs.

%_mingw64_debug_package

%prep
%autosetup -p1 -n %{_name}-%{version}
chmod -x NEWS

%build
%_mingw64_meson \
	%{nil}
%_mingw64_meson_build

%install
%_mingw64_meson_install

# fix W: non-executable-script
chmod a+x %buildroot/%{_mingw64_libdir}/glibmm-%{base_ver}/proc/generate_wrap_init.pl
chmod a+x %buildroot/%{_mingw64_libdir}/glibmm-%{base_ver}/proc/gmmproc 

%files -n mingw64-libglibmm%{so_ver}
%license COPYING
%{_mingw64_bindir}/libglibmm-%{base_ver}*.dll
%{_mingw64_bindir}/libglibmm_generate_extra_defs-%{base_ver}*.dll

%files -n mingw64-libgiomm%{so_ver}
%{_mingw64_bindir}/libgiomm-%{base_ver}*.dll

%files devel
%doc AUTHORS ChangeLog NEWS README
%{_mingw64_libdir}/*.dll.a
%{_mingw64_libdir}/pkgconfig/*.pc
%{_mingw64_includedir}/*
%{_mingw64_libdir}/glibmm-%{base_ver}
%{_mingw64_libdir}/giomm-%{base_ver}

%changelog
openSUSE Build Service is sponsored by