File openboardview.spec of Package openboardview
#
# spec file for package openboardview
#
# Copyright (c) 2024, Martin Hauke <mardnh@gmx.de>
#
# 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: openboardview
Version: 9.95.2
Release: 0
Summary: Viewer for PCB layouts
License: MIT
URL: https://openboardview.org/
Source: OpenBoardView-%{version}.tar.xz
BuildRequires: hicolor-icon-theme
BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: pkgconfig
BuildRequires: pkgconfig(fontconfig)
BuildRequires: pkgconfig(gio-2.0)
BuildRequires: pkgconfig(gtk+-3.0)
# Магия для Mageia 9
%if 0%{?mageia}
BuildRequires: lib64sdl2.0-devel
BuildRequires: lib64sdl2_mixer-devel
BuildRequires: lib64sdl2.0-static-devel
BuildRequires: lib64sqlite3-devel
BuildRequires: lib64zlib-devel
%else
BuildRequires: pkgconfig(sdl2)
%endif
%if 0%{?fedora} || (0%{?suse_version} && 0%{?suse_version} < 1600)
BuildRequires: stb-devel
%else
%if 0%{?mageia} == 0
BuildRequires: pkgconfig(stb)
%endif
%endif
Provides: bundled(glad)
Provides: bundled(imgui)
Provides: bundled(utf8.h)
%description
Software for viewing PCB/Laptop/Motherboard Layouts.
%prep
%setup -q -n OpenBoardView-%{version}
%autopatch -p1
%build
%cmake \
%if 0%{?mageia}
-DSDL2_PATH=%{_prefix} \
%endif
-DCMAKE_SHARED_LINKER_FLAGS="" \
-DBUILD_SHARED_LIBS:BOOL=OFF \
-DBUILD_STATIC_LIBS:BOOL=ON
%cmake_build
%install
%cmake_install
%files
%license LICENSE
%doc README.md
%{_bindir}/openboardview
%{_datadir}/applications/openboardview.desktop
%{_datadir}/icons/hicolor/scalable/apps/openboardview.svg
%{_datadir}/metainfo/openboardview.appdata.xml
%{_datadir}/mime/packages/openboardview.xml
%changelog