diff options
author | Mingli Yu <mingli.yu@windriver.com> | 2022-06-02 13:46:40 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-06-04 11:28:23 +0100 |
commit | b4a12cfb9ce3e71b92dd82f50bb39fdc45560586 (patch) | |
tree | b93dc1dc1c38ef990baeeca43e334f8202896990 /meta/recipes-devtools/perl/files | |
parent | 366e7e620bb749a247a1f7288f0ed8cedd529ded (diff) | |
download | poky-b4a12cfb9ce3e71b92dd82f50bb39fdc45560586.tar.gz |
perl: Fix build with gcc-12
Fix the build failure when debug build is enabled.
Add DEBUG_BUILD = "1" in conf/local.conf.
$ bitbake perl
| In function 'dynprep',
inlined from 'S_sortsv_flags_impl' at pp_sort.c:358:20,
inlined from 'sortsv_amagic_i_ncmp' at pp_sort.c:572:5:
| pp_sort.c:1232:1: error: inlining failed in call to 'always_inline' 'S_amagic_i_ncmp': function not considered for inlining
| 1232 | S_amagic_i_ncmp(pTHX_ SV *const a, SV *const b)
(From OE-Core rev: 880296e68cfd92cfd4c9474972c8d8e6f21a2a40)
Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/perl/files')
-rw-r--r-- | meta/recipes-devtools/perl/files/0001-Fix-build-with-gcc-12.patch | 143 |
1 files changed, 143 insertions, 0 deletions
diff --git a/meta/recipes-devtools/perl/files/0001-Fix-build-with-gcc-12.patch b/meta/recipes-devtools/perl/files/0001-Fix-build-with-gcc-12.patch new file mode 100644 index 0000000000..1d98e1389b --- /dev/null +++ b/meta/recipes-devtools/perl/files/0001-Fix-build-with-gcc-12.patch | |||
@@ -0,0 +1,143 @@ | |||
1 | From ee957eb9e4ec29a462cdbb2f3bbe29d4270534ef Mon Sep 17 00:00:00 2001 | ||
2 | From: Mingli Yu <mingli.yu@windriver.com> | ||
3 | Date: Thu, 2 Jun 2022 13:01:37 +0800 | ||
4 | Subject: [PATCH] proto.h: Fix build with gcc-12 | ||
5 | |||
6 | Fixes: | ||
7 | In function 'dynprep', | ||
8 | inlined from 'S_sortsv_flags_impl' at pp_sort.c:358:20, | ||
9 | inlined from 'sortsv_amagic_i_ncmp' at pp_sort.c:572:5: | ||
10 | pp_sort.c:1232:1: error: inlining failed in call to 'always_inline' 'S_amagic_i_ncmp': function not considered for inlining | ||
11 | 1232 | S_amagic_i_ncmp(pTHX_ SV *const a, SV *const b) | ||
12 | |||
13 | Upstream-Status: Submitted [https://github.com/Perl/perl5/pull/19808] | ||
14 | |||
15 | Signed-off-by: Mingli Yu <mingli.yu@windriver.com> | ||
16 | --- | ||
17 | proto.h | 42 ++++++++++++++---------------------------- | ||
18 | 1 file changed, 14 insertions(+), 28 deletions(-) | ||
19 | |||
20 | diff --git a/proto.h b/proto.h | ||
21 | index faca6d1..3a76c04 100644 | ||
22 | --- a/proto.h | ||
23 | +++ b/proto.h | ||
24 | @@ -5606,50 +5606,43 @@ STATIC SSize_t S_unpack_rec(pTHX_ struct tempsym* symptr, const char *s, const c | ||
25 | #endif | ||
26 | #if defined(PERL_IN_PP_SORT_C) | ||
27 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
28 | -PERL_STATIC_FORCE_INLINE I32 S_amagic_cmp(pTHX_ SV *const str1, SV *const str2) | ||
29 | - __attribute__always_inline__; | ||
30 | +PERL_STATIC_FORCE_INLINE I32 S_amagic_cmp(pTHX_ SV *const str1, SV *const str2); | ||
31 | #define PERL_ARGS_ASSERT_AMAGIC_CMP \ | ||
32 | assert(str1); assert(str2) | ||
33 | #endif | ||
34 | |||
35 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
36 | -PERL_STATIC_FORCE_INLINE I32 S_amagic_cmp_desc(pTHX_ SV *const str1, SV *const str2) | ||
37 | - __attribute__always_inline__; | ||
38 | +PERL_STATIC_FORCE_INLINE I32 S_amagic_cmp_desc(pTHX_ SV *const str1, SV *const str2); | ||
39 | #define PERL_ARGS_ASSERT_AMAGIC_CMP_DESC \ | ||
40 | assert(str1); assert(str2) | ||
41 | #endif | ||
42 | |||
43 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
44 | -PERL_STATIC_FORCE_INLINE I32 S_amagic_i_ncmp(pTHX_ SV *const a, SV *const b) | ||
45 | - __attribute__always_inline__; | ||
46 | +PERL_STATIC_FORCE_INLINE I32 S_amagic_i_ncmp(pTHX_ SV *const a, SV *const b); | ||
47 | #define PERL_ARGS_ASSERT_AMAGIC_I_NCMP \ | ||
48 | assert(a); assert(b) | ||
49 | #endif | ||
50 | |||
51 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
52 | -PERL_STATIC_FORCE_INLINE I32 S_amagic_i_ncmp_desc(pTHX_ SV *const a, SV *const b) | ||
53 | - __attribute__always_inline__; | ||
54 | +PERL_STATIC_FORCE_INLINE I32 S_amagic_i_ncmp_desc(pTHX_ SV *const a, SV *const b); | ||
55 | #define PERL_ARGS_ASSERT_AMAGIC_I_NCMP_DESC \ | ||
56 | assert(a); assert(b) | ||
57 | #endif | ||
58 | |||
59 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
60 | -PERL_STATIC_FORCE_INLINE I32 S_amagic_ncmp(pTHX_ SV *const a, SV *const b) | ||
61 | - __attribute__always_inline__; | ||
62 | +PERL_STATIC_FORCE_INLINE I32 S_amagic_ncmp(pTHX_ SV *const a, SV *const b); | ||
63 | #define PERL_ARGS_ASSERT_AMAGIC_NCMP \ | ||
64 | assert(a); assert(b) | ||
65 | #endif | ||
66 | |||
67 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
68 | -PERL_STATIC_FORCE_INLINE I32 S_amagic_ncmp_desc(pTHX_ SV *const a, SV *const b) | ||
69 | - __attribute__always_inline__; | ||
70 | +PERL_STATIC_FORCE_INLINE I32 S_amagic_ncmp_desc(pTHX_ SV *const a, SV *const b); | ||
71 | #define PERL_ARGS_ASSERT_AMAGIC_NCMP_DESC \ | ||
72 | assert(a); assert(b) | ||
73 | #endif | ||
74 | |||
75 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
76 | -PERL_STATIC_FORCE_INLINE I32 S_cmp_desc(pTHX_ SV *const str1, SV *const str2) | ||
77 | - __attribute__always_inline__; | ||
78 | +PERL_STATIC_FORCE_INLINE I32 S_cmp_desc(pTHX_ SV *const str1, SV *const str2); | ||
79 | #define PERL_ARGS_ASSERT_CMP_DESC \ | ||
80 | assert(str1); assert(str2) | ||
81 | #endif | ||
82 | @@ -5671,51 +5664,44 @@ PERL_STATIC_FORCE_INLINE void S_sortsv_flags_impl(pTHX_ SV** array, size_t num_e | ||
83 | #endif | ||
84 | |||
85 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
86 | -PERL_STATIC_FORCE_INLINE I32 S_sv_i_ncmp(pTHX_ SV *const a, SV *const b) | ||
87 | - __attribute__always_inline__; | ||
88 | +PERL_STATIC_FORCE_INLINE I32 S_sv_i_ncmp(pTHX_ SV *const a, SV *const b); | ||
89 | #define PERL_ARGS_ASSERT_SV_I_NCMP \ | ||
90 | assert(a); assert(b) | ||
91 | #endif | ||
92 | |||
93 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
94 | -PERL_STATIC_FORCE_INLINE I32 S_sv_i_ncmp_desc(pTHX_ SV *const a, SV *const b) | ||
95 | - __attribute__always_inline__; | ||
96 | +PERL_STATIC_FORCE_INLINE I32 S_sv_i_ncmp_desc(pTHX_ SV *const a, SV *const b); | ||
97 | #define PERL_ARGS_ASSERT_SV_I_NCMP_DESC \ | ||
98 | assert(a); assert(b) | ||
99 | #endif | ||
100 | |||
101 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
102 | -PERL_STATIC_FORCE_INLINE I32 S_sv_ncmp(pTHX_ SV *const a, SV *const b) | ||
103 | - __attribute__always_inline__; | ||
104 | +PERL_STATIC_FORCE_INLINE I32 S_sv_ncmp(pTHX_ SV *const a, SV *const b); | ||
105 | #define PERL_ARGS_ASSERT_SV_NCMP \ | ||
106 | assert(a); assert(b) | ||
107 | #endif | ||
108 | |||
109 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
110 | -PERL_STATIC_FORCE_INLINE I32 S_sv_ncmp_desc(pTHX_ SV *const a, SV *const b) | ||
111 | - __attribute__always_inline__; | ||
112 | +PERL_STATIC_FORCE_INLINE I32 S_sv_ncmp_desc(pTHX_ SV *const a, SV *const b); | ||
113 | #define PERL_ARGS_ASSERT_SV_NCMP_DESC \ | ||
114 | assert(a); assert(b) | ||
115 | #endif | ||
116 | |||
117 | # if defined(USE_LOCALE_COLLATE) | ||
118 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
119 | -PERL_STATIC_FORCE_INLINE I32 S_amagic_cmp_locale(pTHX_ SV *const str1, SV *const str2) | ||
120 | - __attribute__always_inline__; | ||
121 | +PERL_STATIC_FORCE_INLINE I32 S_amagic_cmp_locale(pTHX_ SV *const str1, SV *const str2); | ||
122 | #define PERL_ARGS_ASSERT_AMAGIC_CMP_LOCALE \ | ||
123 | assert(str1); assert(str2) | ||
124 | #endif | ||
125 | |||
126 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
127 | -PERL_STATIC_FORCE_INLINE I32 S_amagic_cmp_locale_desc(pTHX_ SV *const str1, SV *const str2) | ||
128 | - __attribute__always_inline__; | ||
129 | +PERL_STATIC_FORCE_INLINE I32 S_amagic_cmp_locale_desc(pTHX_ SV *const str1, SV *const str2); | ||
130 | #define PERL_ARGS_ASSERT_AMAGIC_CMP_LOCALE_DESC \ | ||
131 | assert(str1); assert(str2) | ||
132 | #endif | ||
133 | |||
134 | #ifndef PERL_NO_INLINE_FUNCTIONS | ||
135 | -PERL_STATIC_FORCE_INLINE I32 S_cmp_locale_desc(pTHX_ SV *const str1, SV *const str2) | ||
136 | - __attribute__always_inline__; | ||
137 | +PERL_STATIC_FORCE_INLINE I32 S_cmp_locale_desc(pTHX_ SV *const str1, SV *const str2); | ||
138 | #define PERL_ARGS_ASSERT_CMP_LOCALE_DESC \ | ||
139 | assert(str1); assert(str2) | ||
140 | #endif | ||
141 | -- | ||
142 | 2.25.1 | ||
143 | |||