Compare commits

..

10 Commits

Author SHA1 Message Date
openeuler-ci-bot
5acb885784
!26 [sync] PR-24: Migrate to openEuler Git LFS service for 24.03-LTS-SP1
From: @openeuler-sync-bot 
Reviewed-by: @wk333 
Signed-off-by: @wk333
2024-12-05 07:42:45 +00:00
jchzhou
57717b9bac Migrate to openEuler Git LFS service
Signed-off-by: jchzhou <zhoujiacheng@iscas.ac.cn>
(cherry picked from commit e8c99622155a4b87855736683a490eefed9e594c)
2024-12-05 15:41:34 +08:00
openeuler-ci-bot
adde7e40ba
!15 Upgrade to 2.4
From: @starlet-dx 
Reviewed-by: @wk333 
Signed-off-by: @wk333
2024-01-16 02:02:06 +00:00
starlet-dx
2d4b52f553 Upgrade to 2.4 2024-01-10 17:30:10 +08:00
openeuler-ci-bot
9a0f3e4bf8
!14 fix install error due to sphinx upgrade remove jquery.js
From: @cherry530 
Reviewed-by: @caodongxia 
Signed-off-by: @caodongxia
2023-07-29 07:58:37 +00:00
cherry530
656b7f6fe8 fix build error
Signed-off-by: cherry530 <707078654@qq.com>
2023-07-29 15:23:58 +08:00
openeuler-ci-bot
34de3b9c49
!13 Upload the integral source archive file -- libabigail-2.2.tar.xz
From: @chenyanpanX 
Reviewed-by: @caodongxia 
Signed-off-by: @caodongxia
2023-07-05 11:47:31 +00:00
chenyanpanX
01e6d1166c Upload the integral source archive file -- libabigail-2.2.tar.xz 2023-04-19 23:44:46 +08:00
openeuler-ci-bot
6a626bef8f
!12 Upgrade package to 2.2 version
From: @cherry530 
Reviewed-by: @caodongxia 
Signed-off-by: @caodongxia
2023-04-13 08:06:46 +00:00
cherry530
a8c12536bc Upgrade 2.2
Signed-off-by: cherry530 <707078654@qq.com>
2023-04-13 14:27:03 +08:00
11 changed files with 26 additions and 392 deletions

1
.gitattributes vendored Normal file
View File

@ -0,0 +1 @@
*.tar.xz filter=lfs diff=lfs merge=lfs -text

2
.lfsconfig Normal file
View File

@ -0,0 +1,2 @@
[lfs]
url = https://artlfs.openeuler.openatom.cn/src-openEuler/libabigail

View File

@ -1,25 +0,0 @@
From ab8228fb82a9806b978aff4cc693900729eb0e03 Mon Sep 17 00:00:00 2001
From: caodongxia <315816521@qq.com>
Date: Thu, 20 May 2021 21:11:22 +0800
Subject: [PATCH] create patch
---
build-aux/ltmain.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/build-aux/ltmain.sh b/build-aux/ltmain.sh
index e9c06d7..375e99c 100644
--- a/build-aux/ltmain.sh
+++ b/build-aux/ltmain.sh
@@ -6523,7 +6523,7 @@ func_mode_link ()
old_convenience=
deplibs=
old_deplibs=
- compiler_flags="-specs=/usr/lib/rpm/redhat/redhat-hardened-ld"
+ compiler_flags="-specs=/usr/lib/rpm/generic-hardened-ld"
linker_flags=
dllsearchpath=
lib_search_path=`pwd`
--
2.27.0

View File

@ -1,50 +0,0 @@
From a2263db66eb8ae10614ac1c4ab942bda8c7cd78c Mon Sep 17 00:00:00 2001
From: Xiaole He via Libabigail <libabigail@sourceware.org>
Date: Mon, 19 Sep 2022 18:03:50 +0800
Subject: [PATCH] abg-reader: fix comment of function
In 'src/abg-reader.cc', the function
'walk_xml_node_to_map_type_ids(read_context& ctxt, xmlNodePtr node)'
finds all of the child nodes of 'node' that has the 'id' attribute,
and then put the child node into map where the 'id' of the child node
as key and the child node itself as the value.
But the comment for this function writes:
/* src/abg-reader.cc begin */
/// Walk an entire XML sub-tree to build a map where the key is the
/// the value of the 'id' attribute (for type definitions) and the key
/// is the xml node containing the 'id' attribute.
...
static void
walk_xml_node_to_map_type_ids(read_context& ctxt,
xmlNodePtr node)
...
/* src/abg-reader.cc end */
The second and third lines of the comment above says the the child node
as the key of the map, but it should be the value of the map.
This patch fix the problematic comment described above, from
'and the key is the xml node' to 'and the value is the xml node'.
* src/abg-reader.cc (walk_xml_node_to_map_type_ids): fix comment
Signed-off-by: Xiaole He <hexiaole@kylinos.cn>
Signed-off-by: Dodji Seketeli <dodji@redhat.com>
---
src/abg-reader.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/abg-reader.cc b/src/abg-reader.cc
index 1ca36b7..1df3515 100644
--- a/src/abg-reader.cc
+++ b/src/abg-reader.cc
@@ -1418,7 +1418,7 @@ advance_cursor(read_context& ctxt)
}
/// Walk an entire XML sub-tree to build a map where the key is the
-/// the value of the 'id' attribute (for type definitions) and the key
+/// the value of the 'id' attribute (for type definitions) and the value
/// is the xml node containing the 'id' attribute.
///
/// @param ctxt the context of the reader.
--
2.27.0

View File

@ -1,61 +0,0 @@
From 1ed036e2573e1fc9a1a0aed720eee20a921a38ed Mon Sep 17 00:00:00 2001
From: Xiaole He <hexiaole@kylinos.cn>
Date: Sun, 16 Oct 2022 04:26:42 +0000
Subject: [PATCH 1/3] abg-ir: add missing else
In 'bind_function_type_life_time' function of 'src/abg-ir.cc', the code
obtains the member 'const environment*' of 'class function_type', that
is, the 'e' variable in below code. And assure the obtained
'environment*' is same as the 'const environment*' of the
'class translation_unit', that is, the'env' variable in below code:
/* src/abg-ir.cc begin */
1 void
2 translation_unit::bind_function_type_life_time(function_type_sptr ftype)
3 {
4 ...
5 const environment* env = get_environment();
6 ...
7 if (const environment* e = ftype->get_environment())
8 ABG_ASSERT(env == e);
9 ftype->set_environment(const_cast<environment*>(env));
10
11 if (const translation_unit* existing_tu = ftype->get_translation_unit())
12 ABG_ASSERT(existing_tu == this);
13 else
14 ftype->set_translation_unit(const_cast<translation_unit*>(this));
15 ...
/* src/abg-ir.cc end */
There was a missing 'else' between the 'line 8' and line 9', as the
explicit 'else' at the 'line 13'. Without the 'else' between the
'line 8' and line 9', there will be a redundant assignment at 'line 9'
under the condition when the 'env' is equal to 'e'.
This patch add the missing 'else' between the 'line 8' and 'line 9'.
* src/abg-ir.cc (bind_function_type_life_time): add missing
else
Signed-off-by: Xiaole He <hexiaole@kylinos.cn>
Tested-by: Xiaole He <hexiaole@kylinos.cn>
---
src/abg-ir.cc | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/abg-ir.cc b/src/abg-ir.cc
index 4f19e07..a93c494 100644
--- a/src/abg-ir.cc
+++ b/src/abg-ir.cc
@@ -1394,7 +1394,8 @@ translation_unit::bind_function_type_life_time(function_type_sptr ftype) const
// translation unit.
if (const environment* e = ftype->get_environment())
ABG_ASSERT(env == e);
- ftype->set_environment(const_cast<environment*>(env));
+ else
+ ftype->set_environment(const_cast<environment*>(env));
if (const translation_unit* existing_tu = ftype->get_translation_unit())
ABG_ASSERT(existing_tu == this);
--
2.27.0

View File

@ -1,96 +0,0 @@
From ead3e6317af191324d9044400152e9c881fc3126 Mon Sep 17 00:00:00 2001
From: Xiaole He <hexiaole@kylinos.cn>
Date: Sun, 16 Oct 2022 06:47:03 +0000
Subject: [PATCH 2/3] abg-reader: optimize if construction
In 'build_enum_type_decl' function of 'src/abg-reader.cc', the
'for loop' walk through all the child nodes of the '<enum-decl>' for
seeking '<underlying-type>' and '<enumerator>':
/* original src/abg-reader.cc begin */
static enum_type_decl_sptr
build_enum_type_decl(read_context& ctxt,
const xmlNodePtr node,
bool add_to_current_scope)
{
...
for (xmlNodePtr n = xmlFirstElementChild(node);
n;
n = xmlNextElementSibling(n))
{
if (xmlStrEqual(n->name, BAD_CAST("underlying-type")))
{
...
}
if (xmlStrEqual(n->name, BAD_CAST("enumerator")))
{
...
}
}
...
}
/* original src/abg-reader.cc end */
Here uses 2 separate 'if' statements for seeking, that is, for any
child node of the '<enum-decl>', there involves 2 'if' comparations.
Because the child node of the '<enum-decl>' is either
'<underlying-type>' or '<enumerator>', there would be a slight
optimization when use 'if-else if' construction instead, like below:
/* optimized src/abg-reader.cc begin */
for (xmlNodePtr n = xmlFirstElementChild(node);
n;
n = xmlNextElementSibling(n))
{
if (xmlStrEqual(n->name, BAD_CAST("underlying-type")))
{
...
}
else if (xmlStrEqual(n->name, BAD_CAST("enumerator")))
{
...
}
}
/* optimized src/abg-reader.cc end */
Supposing there has the test case:
/* test case begin */
<abi-instr version='1.0'>
<enum-decl name='E' filepath='../../abitests/test-enum0-v0.cc' line='1' column='6' id='type-id-2'>
<underlying-type type-id='type-id-1'/>
<enumerator name='e0' value='0'/>
<enumerator name='e2' value='1'/>
</enum-decl>
</abi-instr>
/* test case end */
When parsing the '<underlying-type>' xml tag, for the original
'src/abg-reader.cc', there involves 2 'if' comparations. But involves
only 1 'if' comparation for the optimized 'src/abg-reader.cc'.
Signed-off-by: Xiaole He <hexiaole@kylinos.cn>
Tested-by: Xiaole He <hexiaole@kylinos.cn>
Signed-off-by: Dodji Seketeli <dodji@redhat.com>
---
src/abg-reader.cc | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/src/abg-reader.cc b/src/abg-reader.cc
index 1df3515..ebb55e9 100644
--- a/src/abg-reader.cc
+++ b/src/abg-reader.cc
@@ -4356,8 +4356,7 @@ build_enum_type_decl(read_context& ctxt,
base_type_id = CHAR_STR(a);
continue;
}
-
- if (xmlStrEqual(n->name, BAD_CAST("enumerator")))
+ else if (xmlStrEqual(n->name, BAD_CAST("enumerator")))
{
string name;
int64_t value = 0;
--
2.27.0

View File

@ -1,112 +0,0 @@
From 1058fa9cecaef8f39066a4d76b82c97f7f5b10ea Mon Sep 17 00:00:00 2001
From: Xiaole He <hexiaole@kylinos.cn>
Date: Sun, 16 Oct 2022 07:02:25 +0000
Subject: [PATCH 3/3] abg-diff-utils: fix typo in comments
Fix typo in comments, from 'pased' to 'passed'.
* src/abg-diff-utils.h: fix typo in comments
Signed-off-by: Xiaole He <hexiaole@kylinos.cn>
Signed-off-by: Dodji Seketeli <dodji@redhat.com>
---
include/abg-diff-utils.h | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/include/abg-diff-utils.h b/include/abg-diff-utils.h
index 0628950..0389d7c 100644
--- a/include/abg-diff-utils.h
+++ b/include/abg-diff-utils.h
@@ -803,7 +803,7 @@ struct deep_ptr_eq_functor
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param k the number of the diagonal on which we want to find the
@@ -942,7 +942,7 @@ end_of_fr_d_path_in_k(int k, int d,
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param k the number of the diagonal on which we want to find the
@@ -1116,7 +1116,7 @@ is_match_point(RandomAccessOutputIterator a_begin,
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param a_begin an iterator pointing to the begining of sequence A.
@@ -1308,7 +1308,7 @@ print_snake(RandomAccessOutputIterator a_begin,
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param a the first sequence we care about.
@@ -1444,7 +1444,7 @@ snake_end_points(const snake& s, point&, point&);
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param a_base the iterator to the base of the first sequence.
@@ -1653,7 +1653,7 @@ compute_diff(RandomAccessOutputIterator a_base,
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param a_start an iterator to the beginning of the first sequence
@@ -1719,7 +1719,7 @@ compute_diff(RandomAccessOutputIterator a_begin,
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param a_base the iterator to the base of the first sequence.
@@ -1779,7 +1779,7 @@ compute_diff(RandomAccessOutputIterator a_base,
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param a_start an iterator to the beginning of the first sequence
@@ -1879,7 +1879,7 @@ compute_diff(RandomAccessOutputIterator a_begin,
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param a_base the iterator to the base of the first sequence.
@@ -1935,7 +1935,7 @@ compute_diff(RandomAccessOutputIterator a_base,
/// call operator member returning a boolean and taking two arguments
/// that must be of the same type as the one pointed to by the @ref
/// RandomAccessOutputIterator template parameter. This functor is
-/// used to compare the elements referred to by the iterators pased in
+/// used to compare the elements referred to by the iterators passed in
/// argument to this function.
///
/// @param a_start an iterator to the beginning of the first sequence
--
2.27.0

View File

@ -1,36 +0,0 @@
From 08ed347ebfd108c9c1de0ba65f9a947fda1617ab Mon Sep 17 00:00:00 2001
From: Dodji Seketeli <dodji@redhat.com>
Date: Fri, 2 Dec 2022 15:59:13 +0000
Subject: [PATCH] Bug 29829 - dwarf-reader: Allow DIEs to be in a lexical block
Normally, ABI-relevant DWARF DIEs (types and decls) should be at
namespace level. There are real-life cases where such a DIE might be
defined in a lexical block.
This patch teaches the DWARF reader to handle such cases.
* src/abg-dwarf-reader.cc (get_scope_for_die): Support
DW_TAG_lexical_block as DIE scope.
Signed-off-by: Dodji Seketeli <dodji@redhat.com>
---
src/abg-dwarf-reader.cc | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/abg-dwarf-reader.cc b/src/abg-dwarf-reader.cc
index 1d6ad24..895a55d 100644
--- a/src/abg-dwarf-reader.cc
+++ b/src/abg-dwarf-reader.cc
@@ -10961,7 +10961,8 @@ get_scope_for_die(read_context& ctxt,
scope_decl_sptr s;
type_or_decl_base_sptr d;
if (dwarf_tag(&parent_die) == DW_TAG_subprogram
- || dwarf_tag(&parent_die) == DW_TAG_array_type)
+ || dwarf_tag(&parent_die) == DW_TAG_array_type
+ || dwarf_tag(&parent_die) == DW_TAG_lexical_block)
// this is an entity defined in a scope that is a function.
// Normally, I would say that this should be dropped. But I have
// seen a case where a typedef DIE needed by a function parameter
--
2.27.0

Binary file not shown.

3
libabigail-2.4.tar.xz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:5fe76b6344188a95f693b84e1b8731443d274a4c4b0ebee18fc00d9aedac8509
size 357840964

View File

@ -1,18 +1,12 @@
Name: libabigail
Version: 2.0
Release: 4
Version: 2.4
Release: 2
Summary: ABI generic analysis and instrumentation library
License: LGPLv3+
URL: https://sourceware.org/libabigail/
Source0: http://mirrors.kernel.org/sourceware/libabigail/libabigail-%{version}.tar.gz
Patch0000: 0001-compiler-flags.patch
Patch0001: 0002-abg-reader-fix-comment-of-function.patch
Patch0002: 0003-abg-ir-add-missing-else.patch
Patch0003: 0004-abg-reader-optimize-if-construction.patch
Patch0004: 0005-abg-diff-utils-fix-typo-in-comments.patch
Patch0005: 0006-Bug-29829-dwarf-reader-Allow-DIEs-to-be-in-a-lexical.patch
Source0: http://mirrors.kernel.org/sourceware/libabigail/libabigail-%{version}.tar.xz
BuildRequires: gcc-c++ libtool elfutils-devel libxml2-devel doxygen
BuildRequires: python3-sphinx texinfo dos2unix dpkg python3-devel python3-rpm
BuildRequires: python3-sphinx texinfo dpkg python3-devel python3-rpm
BuildRequires: python3-mock python3-unittest2 python3-pyxdg wget mailcap
%description
@ -57,7 +51,6 @@ cd ..
%make_install
%delete_la
make -C doc/manuals install-man-and-info-doc DESTDIR=%{buildroot}
dos2unix doc/manuals/html/_static/jquery.js
%check
time make check || (cat tests/test-suite.log && exit 2)
@ -79,7 +72,7 @@ fi
%files
%{_bindir}/{abicompat,abidiff,abidw,abilint,abipkgdiff,kmidiff}
%{_libdir}/{libabigail.so.0,libabigail.so.0.0.0}
%{_libdir}/{libabigail.so.3,libabigail.so.3.0.0}
%{_libdir}/libabigail/default.abignore
%files devel
@ -96,6 +89,21 @@ fi
%doc doc/manuals/html/* README AUTHORS ChangeLog
%changelog
* Thu Dec 05 2024 jchzhou <zhoujiacheng@iscas.ac.cn> - 2.4-2
- Migrate to openEuler Git LFS service
* Wed Jan 10 2024 yaoxin <yao_xin001@hoperun.com> - 2.4-1
- Upgrade to 2.4
* Sat Jul 29 2023 xu_ping <707078654@qq.com> - 2.2-3
- fix install error due to sphinx upgrade remove jquery.js
* Wed Apr 19 2023 ChenYanpan <chenyanpan@xfusion.com> - 2.2-2
- Upload the integral source archive file -- libabigail-2.2.tar.xz
* Wed Apr 12 2023 xu_ping <707078654@qq.com> - 2.2-1
- Upgrade to 2.2
* Fri Dec 9 2022 Xiaole He <hexiaole@kylinos.cn> - 2.0-4
- backport patch:0006 to fix coredump of libxul.so from thunderbird rpm