File 7-zip.spec of Package 7-zip

#
# spec file for package 7-zip
#
# Copyright (c) 2021 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/
#


%define _over   2102
###%%define         _lto_cflags      %%{nil}
Name:           7-zip
Version:        21.02_alpha
Release:        0
Summary:        File archiver with a high compression ratio
### recheck
License:        LGPL
URL:            https://www.7-zip.org/
Source0:        https://www.7-zip.org/a/7z%{_over}-src.7z
###
###BuildRequires:  asmc
BuildRequires:  dos2unix
BuildRequires:  gcc-c++
BuildRequires:  p7zip-full
### see about this
Conflicts:      p7zip
Conflicts:      p7zip-full

%description
A file archiver with a high compression ratio.

%prep
%setup -q -c
dos2unix DOC/*.txt

%build
cd CPP/7zip/Bundles/Alone2                 # -Werror gives us heartache
make %{?_smp_mflags} -f ../../cmpl_gcc.mak CFLAGS_WARN_WALL="-Wall -Wextra"
### CFLAGS="%{optflags}" CXXFLAGS="%{optflags}"


#To compile 7-Zip for Linux with Asmc for x86-64:
#cd CPP/7zip/Bundles/Alone2
#make -j -f ../../cmpl_gcc_x64.mak

%install
install -Dt %{buildroot}%{_bindir} -m0755 CPP/7zip/Bundles/Alone2/b/g/7zz
ln -sf 7zz %{buildroot}%{_bindir}/7z

%files
%license DOC/copying.txt DOC/License.txt DOC/unRarLicense.txt
%doc DOC/7zC.txt DOC/7zFormat.txt DOC/lzma.txt DOC/Methods.txt DOC/readme.txt DOC/src-history.txt
%{_bindir}/7z
%{_bindir}/7zz

%changelog
openSUSE Build Service is sponsored by