Hey Ondrej ! Could you tell us how to modify the gcc spec file to get that working ? I am trying to compile php8.2-8.2.4 on debian unstable on a starfive risc-v board. > Linux starfive 5.15.0-starfive #1 SMP Sun Mar 26 12:29:48 EDT 2023 > riscv64 GNU/Linux
Manuels patch does not seem to work for me, i still get > lcrypt -lrt -lstdc++ -lrt -lm -lxml2 -lgssapi_krb5 -lkrb5 -lk5crypto > -lcom_err -lssl -lcrypto -lpcre2-8 -lz -lsodium -largon2 -lrt -ldl - > lcrypt > /usr/bin/ld: Zend/zend_execute_API.o: in function > `zend_check_arg_send_type': > ./ext-build/./Zend/zend_compile.h:1038: undefined reference to > `__atomic_exchange_1' > /usr/bin/ld: Zend/zend_atomic.o: in function > `zend_atomic_bool_exchange_ex': > ./ext-build/./Zend/zend_atomic.h:105: undefined reference to > `__atomic_exchange_1' > collect2: error: ld returned 1 exit status Thanks, KK On Sun, 15 Jan 2023 23:58:28 +0100 =?utf-8?Q?Ond=C5=99ej_Sur=C3=BD?= <ond...@sury.org> wrote: > <html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto">This makes absolutely no sense. C11 does not specify that some random library is needed for a language feature.<div><br></div><div>I would rather suggest to patch gcc to add <span style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0); font-size: medium; -webkit-text-size-adjust: auto; background-color: rgb(232, 232, 232);">--as-needed -latomic --no-as-needed</span>by default, than bugging random programs using C11 (that’s 11 years ago) to link with -latomic, see:</div><div><br></div><div><div style="display: block;" class=""><div style="-webkit-user-select: all; -webkit-user-drag: element; display: inline-block;" class="apple-rich- link" draggable="true" role="link" data- url="https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81358"><a style="border-radius:10px;font-family:-apple-system, Helvetica, Arial, sans-serif;display:block;-webkit-user-select:none;width:300px;user- select:none;-webkit-user-modify:read-only;user-modify:read- only;overflow:hidden;text-decoration:none;" class="lp-rich-link" rel="nofollow" href="https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81358" dir="ltr" role="button" draggable="false" width="300"><table style="table- layout:fixed;border-collapse:collapse;width:300px;background- color:#E9E9EB;font-family:-apple-system, Helvetica, Arial, sans- serif;" class="lp-rich-link-emailBaseTable" cellpadding="0" cellspacing="0" border="0" width="300"><tbody><tr><td vertical- align="center"><table bgcolor="#E9E9EB" cellpadding="0" cellspacing="0" width="300" style="font-family:-apple-system, Helvetica, Arial, sans-serif;table-layout:fixed;background- color:rgba(233, 233, 235, 1);" class="lp-rich-link- captionBar"><tbody><tr><td style="padding:8px 0px 8px 0px;" class="lp- rich-link-captionBar-textStackItem"><div style="max- width:100%;margin:0px 16px 0px 16px;overflow:hidden;" class="lp-rich- link-captionBar-textStack"><div style="word-wrap:break-word;font- weight:500;font-size:12px;overflow:hidden;text-overflow:ellipsis;text- align:left;" class="lp-rich-link-captionBar-textStack-topCaption- leading"><a rel="nofollow" href="https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81358" style="text- decoration: none" draggable="false"><font color="#000000" style="color: rgba(0, 0, 0, 1);">81358 – libatomic not automatically linked with C11 code</font></a></div><div style="word-wrap:break- word;font-weight:400;font-size:11px;overflow:hidden;text- overflow:ellipsis;text-align:left;" class="lp-rich-link-captionBar- textStack-bottomCaption-leading"><a rel="nofollow" href="https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81358" style="text- decoration: none" draggable="false"><font color="#A2A2A9" style="color: rgba(60, 60, 67, 0.6);">gcc.gnu.org</font></a></div></div></td><td style="padding:6px 12px 6px 0px;" class="lp-rich-link-captionBar-rightIconItem" width="36"><a rel="nofollow" href="https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81358" draggable="false"><img style="pointer-events:none !important;display:inline-block;width:36px;height:36px;border- radius:3px;" width="36" height="36" draggable="false" class="lp-rich- link-captionBar-rightIcon" alt="favicon.ico" src="cid:D0DAA5A0-EF42- 4F5E-9935- 69489D64468C"></a></td></tr></tbody></table></td></tr></tbody></table> </a></div></div><div><br></div><div>That would help seamlessly bootstrap the platform right now.</div><br>Ondrej<br><div dir="ltr"><span style="background-color: rgba(255, 255, 255, 0);">-- </span><div><span style="background-color: rgba(255, 255, 255, 0);">Ondřej Surý <ond...@sury.org> (He/Him)</span></div></div><div dir="ltr"><br><blockquote type="cite">On 15. 1. 2023, at 23:39, Manuel A. Fernandez Montecelo <manuel.montez...@gmail.com> wrote:<br><br></blockquote></div><blockquote type="cite"><div dir="ltr"><span>Hi,</span><br><span></span><br><span>On Sun, 4 Dec 2022 at 21:15, Manuel A. Fernandez Montecelo</span><br><span><m...@debian.org> wrote:</span><br><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>Source: php8.2</span><br></blockquote><blockquote type="cite"><span>Severity: wishlist</span><br></blockquote><blockquote type="cite"><span>Tags: ftbfs patch</span><br></blockquote><blockquote type="cite"><span>User: debian-ri...@lists.debian.org</span><br></blockquote><blockquote type="cite"><span>Usertags: riscv64</span><br></blockquote><blockquote type="cite"><span>X-Debbugs-Cc: m...@debian.org, locutusofb...@debian.org, bba...@debian.org</span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>Hi,</span><br></blockquote><blockquote type="cite"><span></span><br></blockquote><blockquote type="cite"><span>The package still in experimental builds with the changes attached, I built the</span><br></blockquote><blockquote type="cite"><span>package locally on this architecture, so please include it (or add an equivalent</span><br></blockquote><blockquote type="cite"><span>solution) in the next uploads, at least before moving to unstable.</span><br></blockquote><span></span><br><span>Gentle ping?</span><br><span></span><br><span>There are several packages (PHP modules or similar) waiting with</span><br><span>Dep-Wait on a newer version of php8.2, so it would be nice to have</span><br><span>this patch applied to have php8.2 building successfully and so</span><br><span>avoiding these problems altogether.</span><br><span></span><br><span></span><br><span>Cheers.< /span><br><span>-- </span><br><span>Manuel A. Fernandez Montecelo <manuel.montez...@gmail.com></span><br><span></span><br></div></ blockquote></div></body></html>