Annocheck: Remove dependency upon libiberty.

Resolves: #2217864
This commit is contained in:
Nick Clifton 2023-07-03 17:05:57 +01:00
parent c2e42d19a9
commit 2b29db5a14
3 changed files with 22 additions and 12 deletions

1
.gitignore vendored
View File

@ -1,3 +1,4 @@
/annobin-12.09.tar.xz /annobin-12.09.tar.xz
/annobin-12.10.tar.xz /annobin-12.10.tar.xz
/annobin-12.14.tar.xz /annobin-12.14.tar.xz
/annobin-12.18.tar.xz

View File

@ -8,7 +8,7 @@ BuildRequires: scl-utils-build
Name: %{?scl_prefix}annobin Name: %{?scl_prefix}annobin
Summary: Annotate and examine compiled binary files Summary: Annotate and examine compiled binary files
Version: 12.14 Version: 12.18
Release: 1%{?dist} Release: 1%{?dist}
License: GPLv3+ License: GPLv3+
URL: https://sourceware.org/annobin/ URL: https://sourceware.org/annobin/
@ -45,8 +45,7 @@ URL: https://sourceware.org/annobin/
# checking logic or when building on RHEL-7 or earlier. # checking logic or when building on RHEL-7 or earlier.
%global with_hard_gcc_version_requirement 1 %global with_hard_gcc_version_requirement 1
#XX# %%bcond_without plugin_rebuild %bcond_without plugin_rebuild
%bcond_with plugin_rebuild
# Allow the building of annobin without using annobin itself. # Allow the building of annobin without using annobin itself.
# This is because if we are bootstrapping a new build environment we can have # This is because if we are bootstrapping a new build environment we can have
# a new version of gcc installed, but without a new of annobin installed. # a new version of gcc installed, but without a new of annobin installed.
@ -61,9 +60,9 @@ URL: https://sourceware.org/annobin/
# to gcc breaks the version installed into the buildroot. Mote however that # to gcc breaks the version installed into the buildroot. Mote however that
# uncommenting the lines below will result in annocheck not passing the rpminspect # uncommenting the lines below will result in annocheck not passing the rpminspect
# tests.... # tests....
# %%if %%{without plugin_rebuild} %if %{without plugin_rebuild}
%undefine _annotated_build %undefine _annotated_build
# %%endif %endif
#--------------------------------------------------------------------------------- #---------------------------------------------------------------------------------
@ -85,7 +84,9 @@ Patch02: annobin-tmp-skip-libannocheck-test.patch
%{?scl:Requires:%scl_require_package %{scl} gcc} %{?scl:Requires:%scl_require_package %{scl} gcc}
BuildRequires: %{?scl_prefix}gcc BuildRequires: %{?scl_prefix}gcc
BuildRequires: %{?scl_prefix}annobin-plugin-gcc
%define gcc_for_annobin %{?_scl_root}/usr/bin/gcc %define gcc_for_annobin %{?_scl_root}/usr/bin/gcc
%define gxx_for_annobin %{?_scl_root}/usr/bin/g++
#--------------------------------------------------------------------------------- #---------------------------------------------------------------------------------
@ -178,7 +179,6 @@ Summary: A tool for checking the security hardening status of binaries
BuildRequires: elfutils elfutils-devel elfutils-libelf-devel rpm-devel make BuildRequires: elfutils elfutils-devel elfutils-libelf-devel rpm-devel make
BuildRequires: %{?scl_prefix}gcc BuildRequires: %{?scl_prefix}gcc
BuildRequires: %{?scl_prefix}binutils-devel
%if %{with debuginfod} %if %{with debuginfod}
BuildRequires: elfutils-debuginfod-client-devel BuildRequires: elfutils-debuginfod-client-devel
@ -197,14 +197,12 @@ Summary: A library for checking the security hardening status of binaries
BuildRequires: elfutils elfutils-devel elfutils-libelf-devel rpm-devel make BuildRequires: elfutils elfutils-devel elfutils-libelf-devel rpm-devel make
BuildRequires: %{?scl_prefix}gcc BuildRequires: %{?scl_prefix}gcc
BuildRequires: %{?scl_prefix}binutils-devel
%if %{with debuginfod} %if %{with debuginfod}
BuildRequires: elfutils-debuginfod-client-devel BuildRequires: elfutils-debuginfod-client-devel
%endif %endif
Requires: %{name}-docs = %{version}-%{release} Requires: %{name}-docs = %{version}-%{release}
Requires: %{?scl_prefix}binutils-devel
%description libannocheck %description libannocheck
Installs the libannocheck library which uses the notes generated by the Installs the libannocheck library which uses the notes generated by the
@ -413,7 +411,7 @@ export CLANG_TARGET_OPTIONS="-mbranch-protection=standard"
export CLANG_TARGET_OPTIONS="-mabi=ibmlongdouble" export CLANG_TARGET_OPTIONS="-mabi=ibmlongdouble"
%endif %endif
CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS" CXXFLAGS="$CFLAGS" %configure ${CONFIG_ARGS} || cat config.log CC=%gcc_for_annobin CXX=%gxx_for_annobin CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS" CXXFLAGS="$CFLAGS" %configure ${CONFIG_ARGS} || cat config.log
%make_build %make_build
@ -429,7 +427,7 @@ BUILD_FLAGS="-fplugin=%{_tmppath}/tmp_annobin.so"
# Disable the standard annobin plugin so that we do get conflicts. # Disable the standard annobin plugin so that we do get conflicts.
# Note - rpm-4.10 uses a different way of evaluating macros. # Note - rpm-4.10 uses a different way of evaluating macros.
%if 0%{?rhel} && 0%{?rhel} < 7 %if 0%{?rhel} && 0%{?rhel} < 9
OPTS="$(rpm --eval '%undefine _annotated_build %build_cflags %build_ldflags')" OPTS="$(rpm --eval '%undefine _annotated_build %build_cflags %build_ldflags')"
%else %else
OPTS="$(rpm --undefine=_annotated_build --eval '%build_cflags %build_ldflags')" OPTS="$(rpm --undefine=_annotated_build --eval '%build_cflags %build_ldflags')"
@ -439,7 +437,7 @@ OPTS="$(rpm --undefine=_annotated_build --eval '%build_cflags %build_ldflags')"
# .attach_to_group pseudo op (eg RHEL-7) then enable the next line. # .attach_to_group pseudo op (eg RHEL-7) then enable the next line.
# BUILD_FLAGS="$BUILD_FLAGS -fplugin-arg-tmp_annobin-no-attach" # BUILD_FLAGS="$BUILD_FLAGS -fplugin-arg-tmp_annobin-no-attach"
make -C gcc-plugin CXXFLAGS="$OPTS $BUILD_FLAGS" make -C gcc-plugin CXX=%gxx_for_annobin CXXFLAGS="$OPTS $BUILD_FLAGS"
rm %{_tmppath}/tmp_annobin.so rm %{_tmppath}/tmp_annobin.so
%endif %endif
@ -552,6 +550,17 @@ make check GCC=%gcc_for_annobin
#--------------------------------------------------------------------------------- #---------------------------------------------------------------------------------
%changelog %changelog
* Mon Jul 03 2023 Nick Clifton <nickc@redhat.com> - 12.18-1
- Annocheck: Remove dependency upon libiberty.
* Fri Jun 30 2023 Nick Clifton <nickc@redhat.com> - 12.17-1
- Annocheck: Add detection of known parts of libstdc++-nonshared.a that contain gaps. (#2217864)
* Tue Jun 27 2023 Nick Clifton <nickc@redhat.com> - 12.16-1
- Spec File: Rebuild with annobin annotation. (#2217814)
- Annocheck: Ignore weak/undef function symbols when checking to see if a binary contains code. (#2217840)
- Annocheck: Add --suppress-version-warnings option.
* Thu Jun 22 2023 Nick Clifton <nickc@redhat.com> - 12.14-1 * Thu Jun 22 2023 Nick Clifton <nickc@redhat.com> - 12.14-1
- Annocheck: Do not ignore separate debuginfo files that do not contain any DWARF. (#2144553) - Annocheck: Do not ignore separate debuginfo files that do not contain any DWARF. (#2144553)
- Annocheck: Ignore /dev/null filename in string notes. - Annocheck: Ignore /dev/null filename in string notes.

View File

@ -1 +1 @@
SHA512 (annobin-12.14.tar.xz) = 2adb057aefc7dc03cdef34f7d1054ead8f6cb6dabec88bd0e262357a0f456f9cb349b1eba238382cc5fa5f733e360f586282af9081178ff123e68518bb01c1be SHA512 (annobin-12.18.tar.xz) = 580c3b24103c9e9e262c156ae2d472addfe3c1d65c343677d0de2b706b15e8368fad67e62bf2a5308eb4dc197a56bd01497861cbd300660158990ed9bf746c78