File pulseview.spec of Package failed_pulseview

Name:           pulseview
Version:        0.4.2
Release:        1.1
Summary:        PulseView - GUI for sigrok logic analyzers and similar devices

License:        GPL-2.0-or-later
URL:            https://sigrok.org
Source0:        pulseview-0.4.2.tar.gz
Patch0:         0001-Fix-building-with-Qt-5.15.patch
Patch1:         0001-Fix-broken-build-due-to-C-template-behind-C-linkage.patch

BuildRequires:  cmake
BuildRequires:  pkg-config
BuildRequires:  gcc-c++
BuildRequires:  qt5-qtbase-devel
BuildRequires:  qt5-linguist
BuildRequires:  boost-devel
BuildRequires:  glibmm2_4-devel
BuildRequires:  libsigrokcxx-devel
BuildRequires:  libsigrokdecode-devel
BuildRequires:  libusb-1_0-devel
BuildRequires:  libftdi1-devel
BuildRequires:  hidapi-devel
BuildRequires:  libmount-devel
BuildRequires:  libblkid-devel

%description
PulseView is the main graphical user interface for sigrok (logic
analyzers and similar devices).

%prep
%setup -q -n %{name}-%{version}
%patch0 -p1
%patch1 -p1

%build
# Ensure we build with at least C++14. Boost.Math and recent Boost
# versions require C++14; some distributions and older CMakeLists
# force -std=c++11, so explicitly append -std=c++14 to override.
export CXXFLAGS="$CXXFLAGS -std=c++14"
export CFLAGS="$CFLAGS -std=c11"

# Standard cmake out-of-source build
mkdir -p build
cd build
%cmake .. -G "Unix Makefiles" \
  -DCMAKE_INSTALL_PREFIX=/usr \
  -DCMAKE_INSTALL_LIBDIR=lib64 \
  -DBUILD_SHARED_LIBS=ON \
  -DDISABLE_WERROR=TRUE
make %{?_smp_mflags}

%install
cd build
make DESTDIR=%{buildroot} install

%files
%license LICENSE
%doc README.md
/usr/bin/pulseview
/usr/lib64/*/pulseview
/usr/share/applications/pulseview.desktop
/usr/share/icons/hicolor/*/apps/pulseview*.png
/usr/share/man/man1/pulseview.1*

%changelog
* Sun Aug 10 2025 Your Name <you@example.com> - 0.4.2-1.1
- Build with C++14 to satisfy Boost.Math / Boost >=1.82 requirements
openSUSE Build Service is sponsored by