Date: Sun, 3 Apr 2022 10:40:49 +1000 From: Peter Jeremy <peterj@freebsd.org> To: Xin LI <delphij@freebsd.org> Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: cd8822075a38 - main - MFV c144cc54795d: zlib 1.2.12. Message-ID: <YkjtEf%2BjP63OiWOo@server.rulingia.com> In-Reply-To: <202203311426.22VEQajW058773@gitrepo.freebsd.org> References: <202203311426.22VEQajW058773@gitrepo.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--uIQnBsqJcHo8aFTY Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2022-Mar-31 14:26:36 +0000, Xin LI <delphij@FreeBSD.org> wrote: >The branch main has been updated by delphij: > >URL: https://cgit.FreeBSD.org/src/commit/?id=3Dcd8822075a38d0734e74b1735e4= b5dbef9789170 > >commit cd8822075a38d0734e74b1735e4b5dbef9789170 >Merge: e57f6630d9d4 c144cc54795d >Author: Xin LI <delphij@FreeBSD.org> >AuthorDate: 2022-03-31 14:25:53 +0000 >Commit: Xin LI <delphij@FreeBSD.org> >CommitDate: 2022-03-31 14:25:53 +0000 > > MFV c144cc54795d: zlib 1.2.12. This breaks the build on my arm64 box: --- crc32.o --- /usr/src/sys/contrib/zlib/crc32.c:106:61: error: 'W' is not defined, evalua= tes to 0 [-Werror,-Wundef] #if defined(__aarch64__) && defined(__ARM_FEATURE_CRC32) && W =3D=3D 8 The code in sys/contrib/zlib/crc32.c:74-99 is rather convoluted but doing a test compile with '-E -dD', I get: # 57 "/usr/src/sys/contrib/zlib/crc32.c" #define N 5 # 83 "/usr/src/sys/contrib/zlib/crc32.c" #define W 8 # 97 "/usr/src/sys/contrib/zlib/crc32.c" #undef W Working through the various tests: - Z_TESTW is undefined - MAKECRCH is undefined - __aarch64__ is defined - Z_U8 is undefined - Z_U4 is undefined Z_U8 sounds like it should be defined on a 64-bit arch and there's logic in sys/contrib/zlib/zutil.h:45-54 to do so but: - Z_U8 is not predefined - Z_SOLO is defined at sys/contrib/zlib/zconf.h:13 because it's in the kern= el. The backup Z_U4 definition at sys/contrib/zlib/zconf.h:423:432 is likewise bypassed because Z_SOLO is defined. I believe that the correct fix for arm64 is along the lines of: #define Z_U8 unsigned long but I'm not sure how to weave that into the fairly complex mess of conditionals. Could you please look into the logic for arm64. And, whilst I haven't yet checked, I suspect that the lack of Z_U4 and Z_U8 definitions within the kernel is at least a misconfiguration on all architecture, even if it only actively breaks the build on arm64. --=20 Peter Jeremy --uIQnBsqJcHo8aFTY Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEE7rKYbDBnHnTmXCJ+FqWXoOSiCzQFAmJI7QdfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldEVF QjI5ODZDMzA2NzFFNzRFNjVDMjI3RTE2QTU5N0EwRTRBMjBCMzQACgkQFqWXoOSi CzTVVQ/7BhdnA0CpP1SmN799Tt/1eRze2w45jK92Y2ys90rOAb5rVZCM0csftioP EMgkUISly8l31psLRcYEGaJXXkkNX0zCsOkkzlG7CcMUSOqHuZZQsRsN/TOeQGN3 H9207Kxq6RwHiwZaYyqG3YWElcugWKbygVpK3Q8UWz/7FXhm5zl7XqK1MwAubJl7 V+HDfQqNfyLZVXWZGjLi0lIg24JhALD3o/BYasS2hnmTyiCiIBkCAgS1JeLWt2ZS DKmhKXEvLtBf94ci34ggFyHyAXu8O3CPH8hN64IQQ3HWFIK5OJyKne+voxpUnKQ+ cuegIWqKhcjOINBQVvC0B4QWo8chLk/ZnyUWfoHyysvqzQ5kBkGFRUZik8kHXClb Pn5ivsUGv4hwbaxLSSYUInGKlxhRl9p4naJfy6iPHuK+Bj4xQGOT/8wq1RqmMDbO FuyyYxmRJl4uKyUBxbjChgStDaMD62ejaNGoF4gtzKBKYIp+WRvb72nmmK7gqkic oY2I5q4SMrL5Hw4AGZfb/BpfB7Nox9Sc3pX0HUbmPlNTMIfzFNA6Vvz174X1Ojvg fRq2Nxl9Cu+osLnbguq9SgizEu1OCcF+a4c0xET/sLlH16g8FgbefL6yOxX8hmGG qZVDeVA0LDxmukbcbWIF3UKBa308birKbrbvOPTU2nWhJFU2Bbw= =yXeJ -----END PGP SIGNATURE----- --uIQnBsqJcHo8aFTY--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?YkjtEf%2BjP63OiWOo>