File MiniZincIDE.spec of Package MiniZincIDE

#
# spec file for package MiniZincIDE
#
# Copyright (c) 2025 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#


Name:           MiniZincIDE
Version:        2.8.7
Release:        0
Summary:        IDE for the MiniZinc constraint modelling language
License:        MPL-2.0
URL:            http://www.minizinc.org/
Source0:        https://github.com/MiniZinc/MiniZincIDE/archive/refs/tags/%{version}.tar.gz#/%{name}-%{version}.tar.gz
# Missing git submodule
Source1:        https://gitlab.com/minizinc/cp-profiler-integration/-/archive/f16b3132df33/cp-profiler-integration-f16b3132df33.tar.gz
# PATCH-FIX-UPSTREAM
Patch0:         0001-Fix-missing-return-statement.patch
BuildRequires:  gcc-c++
BuildRequires:  hicolor-icon-theme
BuildRequires:  libQt5Gui-devel
BuildRequires:  libQt5Sql-devel
BuildRequires:  libQt5Test-devel
BuildRequires:  libQt5Widgets-devel
BuildRequires:  libqt5-qtbase-common-devel
BuildRequires:  libqt5-qtwebsockets-devel
BuildRequires:  update-desktop-files
Requires:       minizinc
Requires:       hicolor-icon-theme

%description
The MiniZinc IDE provides a graphical environment for coding
models in the MiniZinc constraint modelling language.

%prep
%setup -b1
%autosetup -p1
cp ../cp-profiler-integration*/* cp-profiler/src/cpp-integration/

%build
%qmake5 PREFIX=%{_prefix}
%make_build

%install
%qmake5_install
install -D resources/icon.png %{buildroot}/%{_datadir}/icons/hicolor/256x256/apps/MiniZincIDE.png
%suse_update_desktop_file -c MiniZincIDE MiniZincIDE "IDE for MiniZinc" MiniZincIDE MiniZincIDE Science Education Math

%files
%license LICENSE.txt
%doc MiniZincIDE/CHANGES
%{_bindir}/MiniZincIDE
%{_datadir}/icons/hicolor/*/apps/*.png
%{_datadir}/applications/MiniZincIDE.desktop

%changelog
openSUSE Build Service is sponsored by