File squashfs-tools.spec of Package squashfs-tools

#
# spec file for package squashfs-tools
#
# Copyright (c) 2022 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:           squashfs-tools
Version:        4.5.1
Release:        0
Summary:        Squashfs image helper tools
License:        GPL-2.0-only
Group:          System/Filesystems
URL:            https://github.com/plougher/squashfs-tools
Source:         https://github.com/plougher/squashfs-tools/archive/refs/tags/%{version}.tar.gz#/squashfs-tools-%{version}.tar.gz
BuildRequires:  gcc
BuildRequires:  lzma-devel
BuildRequires:  lzo-devel
BuildRequires:  make
BuildRequires:  zlib-devel

%description
Tools to create and extract Squashfs filesystems.

%prep
%setup -q

%build
cd %{name}
%make_build LZO_SUPPORT=1 \
     XZ_SUPPORT=1

%install
mkdir -p %{buildroot}%{_mandir}/man1/
install -m 0644 manpages/mksquashfs.1 manpages/unsquashfs.1 %{buildroot}%{_mandir}/man1/
cd %{name}
mkdir -p %{buildroot}%{_bindir}/
install -m 0755 mksquashfs unsquashfs %{buildroot}%{_bindir}/

%files
%doc ACKNOWLEDGEMENTS README-4.* CHANGES USAGE
%license COPYING
%{_bindir}/mksquashfs
%{_bindir}/unsquashfs
%{_mandir}/man1/mksquashfs.1%{ext_man}
%{_mandir}/man1/unsquashfs.1%{ext_man}

%changelog
openSUSE Build Service is sponsored by