Blame abi-compliance-checker.spec

Bernhard M. Wiedemann 0bae9b
#
Bernhard M. Wiedemann 0bae9b
# spec file for package abi-compliance-checker
Bernhard M. Wiedemann 0bae9b
#
Bernhard M. Wiedemann 0baf5d
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
Bernhard M. Wiedemann 0bae9b
#
Bernhard M. Wiedemann 0bae9b
# All modifications and additions to the file contributed by third parties
Bernhard M. Wiedemann 0bae9b
# remain the property of their copyright owners, unless otherwise agreed
Bernhard M. Wiedemann 0bae9b
# upon. The license for this file, and modifications and additions to the
Bernhard M. Wiedemann 0bae9b
# file, is the same license as for the pristine package itself (unless the
Bernhard M. Wiedemann 0bae9b
# license for the pristine package is not an Open Source License, in which
Bernhard M. Wiedemann 0bae9b
# case the license is the MIT License). An "Open Source License" is a
Bernhard M. Wiedemann 0bae9b
# license that conforms to the Open Source Definition (Version 1.9)
Bernhard M. Wiedemann 0bae9b
# published by the Open Source Initiative.
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0baf5d
# Please submit bugfixes or comments via https://bugs.opensuse.org/
Bernhard M. Wiedemann 0bae9b
#
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0bae9b
Name:           abi-compliance-checker
Bernhard M. Wiedemann 0bae9b
Version:        2.3
Bernhard M. Wiedemann 0bae9b
Release:        0
Bernhard M. Wiedemann 0bae9b
Summary:        A Compliance Checker For library ABIs
Bernhard M. Wiedemann 0bae9b
License:        LGPL-2.1-only
Bernhard M. Wiedemann 0bae9b
Url:            https://lvc.github.io/abi-compliance-checker
Bernhard M. Wiedemann 0bae9b
Source0:        https://github.com/lvc/abi-compliance-checker/archive/%{version}/%{name}-%{version}.tar.gz
Bernhard M. Wiedemann 0bae9b
BuildRequires:  fdupes
Bernhard M. Wiedemann 0bae9b
BuildRequires:  gcc-c++
Bernhard M. Wiedemann 0bae9b
BuildRequires:  help2man
Bernhard M. Wiedemann 0bae9b
Requires:       abi-dumper >= 1.1
Bernhard M. Wiedemann 0bae9b
Requires:       binutils
Bernhard M. Wiedemann 0bae9b
Requires:       coreutils
Bernhard M. Wiedemann 0bae9b
Requires:       cpio
Bernhard M. Wiedemann 0bae9b
Requires:       ctags
Bernhard M. Wiedemann 0bae9b
Requires:       diffutils
Bernhard M. Wiedemann 0bae9b
Requires:       file
Bernhard M. Wiedemann 0bae9b
Requires:       gcc-c++
Bernhard M. Wiedemann 0bae9b
Requires:       gzip
Bernhard M. Wiedemann 0bae9b
Requires:       perl-base
Bernhard M. Wiedemann 0bae9b
Requires:       rpm
Bernhard M. Wiedemann 0bae9b
Requires:       tar
Bernhard M. Wiedemann 0bae9b
BuildArch:      noarch
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0bae9b
%description
Bernhard M. Wiedemann 0bae9b
ABI Compliance Checker (ACC) is an easy-to-use tool for checking
Bernhard M. Wiedemann 0bae9b
backward binary compatibility (BC) of a shared C/C++ library.
Bernhard M. Wiedemann 0bae9b
It checks header files along with shared libraries of old and new
Bernhard M. Wiedemann 0bae9b
versions and analyzes changes in Application Binary Interface (ABI)
Bernhard M. Wiedemann 0bae9b
that may cause compatibility problems: changes in calling stack,
Bernhard M. Wiedemann 0bae9b
v-table changes, removed symbols, etc. Breakage of the binary
Bernhard M. Wiedemann 0bae9b
compatibility may result in crashing or incorrect behavior of
Bernhard M. Wiedemann 0bae9b
applications built with an old version of the library if they run on
Bernhard M. Wiedemann 0bae9b
a new one. The tool is intended for library developers and operating
Bernhard M. Wiedemann 0bae9b
system maintainers who are interested in ensuring binary
Bernhard M. Wiedemann 0bae9b
compatibility, i.e. allow old applications to run with newer library
Bernhard M. Wiedemann 0bae9b
versions without the need to recompile.
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0bae9b
%prep
Bernhard M. Wiedemann 0bae9b
%setup -q
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0bae9b
%build
Bernhard M. Wiedemann 0bae9b
chmod 0755 %{name}.pl
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0bae9b
%install
Bernhard M. Wiedemann 0bae9b
mkdir -vp %{buildroot}%{_prefix}
Bernhard M. Wiedemann 0bae9b
perl Makefile.pl --install --prefix=%{_prefix} --destdir=%{buildroot}
Bernhard M. Wiedemann 0bae9b
# Generate man page with help2man
Bernhard M. Wiedemann 0bae9b
mkdir -p %{buildroot}%{_mandir}/man1
Bernhard M. Wiedemann 0bae9b
ln -s %{name}.pl %{name}
Bernhard M. Wiedemann 0bae9b
help2man -h "--info" -N -o %{name}.1 ./%{name}
Bernhard M. Wiedemann 0bae9b
install -m 0644 %{name}.1 %{buildroot}%{_mandir}/man1
Bernhard M. Wiedemann 0bae9b
%fdupes %{buildroot}
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0bae9b
%check
Bernhard M. Wiedemann 0bae9b
# aarch64 needs -fPIC option and noarch package cannot use %%ifarch
Bernhard M. Wiedemann 0bae9b
./%{name} \
Bernhard M. Wiedemann 0bae9b
  -gcc-options -fPIC \
Bernhard M. Wiedemann 0bae9b
  -test
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0bae9b
%files
Bernhard M. Wiedemann 0bae9b
%doc README.md doc
Bernhard M. Wiedemann 0bae9b
%license LICENSE
Bernhard M. Wiedemann 0bae9b
%{_bindir}/*
Bernhard M. Wiedemann 0bae9b
%{_datadir}/%{name}
Bernhard M. Wiedemann 0bae9b
%{_mandir}/man*/*
Bernhard M. Wiedemann 0bae9b
Bernhard M. Wiedemann 0bae9b
%changelog