File newflasher.spec of Package newflasher

#
# spec file for package newflasher
#
# Copyright (c) 2025 Enrico Belleri (kilgore.trout@idesmi.eu)
# Copyright (c) 2022 Mikel Pérez (io@mikelpr.com)
#
# 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.


Name:           newflasher
Version:        58
Release:        0
Summary:        Flash Sony Xperia firmwares for XZ Premium phones and later
License:        MIT
URL:            https://github.com/munjeni/newflasher
Source0:        https://github.com/munjeni/newflasher/archive/refs/tags/%{version}.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires:  pkgconfig
BuildRequires:  pkgconfig(expat)
BuildRequires:  pkgconfig(zlib)

%description
This experimental software allows you to flash firmwares acquired
through XperiFirm to Sony phones including and newer than the XZ Premium.

%prep
%autosetup -p1

%build
%make_build
%make_build newflasher.1.gz

%install
# the make install target wants to use real root privileges
# so can't use the %%make_install macro
mkdir -p %{buildroot}%{_bindir}/
install -m 755 newflasher %{buildroot}%{_bindir}/newflasher
mkdir -p %{buildroot}%{_mandir}/man1
install -m 644 newflasher.1.gz %{buildroot}%{_mandir}/man1

%files
%doc readme.md
%{_bindir}/%{name}
%{_mandir}/man1/newflasher.1.gz

%changelog
openSUSE Build Service is sponsored by