Hello, current Port (1.16.5), and 1.17.x updates fail to build on FreeBSD: > FAILED: lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o > /usr/bin/cc -DiIsLibraryBuild -I/tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/include -I/tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/.build/lib/the_Foundation -I/usr/local/include -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -O2 -pipe -fstack-protector-strong -fno-strict-aliasing > -DNDEBUG -std=gnu11 -Wall -Wpedantic -Werror -Wno-deprecated-declarations -Wno-format-pedantic -Wno-format -msse4.1 -MD -MT lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o -MF lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o.d -o lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o -c /tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/src/punycode.c > In file included from /tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/src/punycode.c:41: > /usr/local/include/unistr.h:203:39: error: [[]] attributes are a C2x extension [-Werror,-Wc2x-extensions] > 203 | const uint32_t *s, _GL_ATTRIBUTE_MAYBE_UNUSED size_t n) > | ^ > /usr/local/include/unistring/cdefs.h:44:37: note: expanded from macro '_GL_ATTRIBUTE_MAYBE_UNUSED' > 44 | # define _GL_ATTRIBUTE_MAYBE_UNUSED _UC_ATTRIBUTE_MAYBE_UNUSED > | ^ > /usr/local/include/unistring/cdefs.h:105:37: note: expanded from macro '_UC_ATTRIBUTE_MAYBE_UNUSED' > 105 | # define _UC_ATTRIBUTE_MAYBE_UNUSED [[__maybe_unused__]] > | ^ > In file included from /tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/src/punycode.c:41: > /usr/local/include/unistr.h:270:13: error: [[]] attributes are a C2x extension [-Werror,-Wc2x-extensions] > 270 | _GL_ATTRIBUTE_MAYBE_UNUSED size_t n) > | ^ > /usr/local/include/unistring/cdefs.h:44:37: note: expanded from macro '_GL_ATTRIBUTE_MAYBE_UNUSED' > 44 | # define _GL_ATTRIBUTE_MAYBE_UNUSED _UC_ATTRIBUTE_MAYBE_UNUSED > | ^ > /usr/local/include/unistring/cdefs.h:105:37: note: expanded from macro '_UC_ATTRIBUTE_MAYBE_UNUSED' > 105 | # define _UC_ATTRIBUTE_MAYBE_UNUSED [[__maybe_unused__]] > | ^ > 2 errors generated. > ninja: build stopped: subcommand failed. > *** Error code 1
Logs: https://portsfallout.com/port/29942/
the culprits here are -std=gnu11 and -Wpedantic if the compiler is to be pedantic about the standard, then it has to error out on things that aren't a standard (yet) try removing the -Wpedantic and see where that leads us to
(In reply to Mina Galić from comment #2) Ah awesome, thanks, I will have a look and report back.
I patched ${WRKSRC}/lib/the_Foundation/CMakeLists.txt to remove the -Wpedantic, the error remains the same: > [ 75% 92/122] /usr/bin/cc -DiIsLibraryBuild -I/tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/include -I/tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/.build/lib/the_Foundation -I/usr/local/include -O2 -pipe -Wc2x-extensions -fstack-protector-strong -fno-strict-aliasing -O2 -pipe -Wc2x-extensions -fstack-protector-strong -fno-strict-aliasing -DNDEBUG -std=gnu11 -Wall -Werror -Wno-deprecated-declarations -Wno-format-pedantic -Wno-format -msse4.1 -MD -MT lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o -MF lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o.d -o lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o -c /tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/src/punycode.c > FAILED: lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o > /usr/bin/cc -DiIsLibraryBuild -I/tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/include -I/tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/.build/lib/the_Foundation -I/usr/local/include -O2 -pipe -Wc2x-extensions -fstack-protector-strong -fno-strict-aliasing -O2 -pipe -Wc2x-extensions -fstack-protector-strong -fno-strict-aliasing -DNDEBUG -std=gnu11 -Wall -Werror -Wno-deprecated-declarations -Wno-format-pedantic -Wno-format -msse4.1 -MD -MT lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o -MF lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o.d -o lib/the_Foundation/CMakeFiles/the_Foundation.dir/src/punycode.c.o -c /tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/src/punycode.c > In file included from /tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/src/punycode.c:41: > /usr/local/include/unistr.h:203:39: error: [[]] attributes are a C2x extension [-Werror,-Wc2x-extensions] > 203 | const uint32_t *s, _GL_ATTRIBUTE_MAYBE_UNUSED size_t n) > | ^ > /usr/local/include/unistring/cdefs.h:44:37: note: expanded from macro '_GL_ATTRIBUTE_MAYBE_UNUSED' > 44 | # define _GL_ATTRIBUTE_MAYBE_UNUSED _UC_ATTRIBUTE_MAYBE_UNUSED > | ^ > /usr/local/include/unistring/cdefs.h:105:37: note: expanded from macro '_UC_ATTRIBUTE_MAYBE_UNUSED' > 105 | # define _UC_ATTRIBUTE_MAYBE_UNUSED [[__maybe_unused__]] > | ^ > In file included from /tmp/lagrange/net/fafnir/git/worktrees/lagrange-20240107/www/lagrange/work/lagrange-1.17.5/lib/the_Foundation/src/punycode.c:41: > /usr/local/include/unistr.h:270:13: error: [[]] attributes are a C2x extension [-Werror,-Wc2x-extensions] > 270 | _GL_ATTRIBUTE_MAYBE_UNUSED size_t n) > | ^ > /usr/local/include/unistring/cdefs.h:44:37: note: expanded from macro '_GL_ATTRIBUTE_MAYBE_UNUSED' > 44 | # define _GL_ATTRIBUTE_MAYBE_UNUSED _UC_ATTRIBUTE_MAYBE_UNUSED > | ^ > /usr/local/include/unistring/cdefs.h:105:37: note: expanded from macro '_UC_ATTRIBUTE_MAYBE_UNUSED' > 105 | # define _UC_ATTRIBUTE_MAYBE_UNUSED [[__maybe_unused__]] > | ^ > 2 errors generated. > ninja: build stopped: subcommand failed. > *** Error code 1 > > Stop. > make[1]: stopped in /net/fafnir/git/worktrees/lagrange-20240107/www/lagrange > *** Error code 1 > > Stop. > make: stopped in /net/fafnir/git/worktrees/lagrange-20240107/www/lagrange
I cheated a little by downgrading errors to warnings with this in the port Makefile: CMAKE_ARGS+= -DTFDN_ENABLE_WARN_ERROR=OFF That is telling "the_Foundation" to not fail on the warnings coming from the libunistring port, I think. :)
(In reply to Sean Farley from comment #5) Thanks Sean, It would be nice to avoid attenuating the compiler's constraints, however, the solution is beyond me. Thanks for the tip anyways, I am testing an updated patch from bug #274414 at the moment, so far so good.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=b04495aa52fc2e75bfbeea6670de6c5c52c944db commit b04495aa52fc2e75bfbeea6670de6c5c52c944db Author: Nathan Fisher <nfisher.sr@gmail.com> AuthorDate: 2024-07-28 12:16:08 +0000 Commit: Vladimir Druzenko <vvd@FreeBSD.org> CommitDate: 2024-07-28 12:16:08 +0000 www/lagrange: update 1.16.5 → 1.17.6 Fix several crashes and memory leaks. Fix build on 15-CURRENT. Changelogs: https://github.com/skyjake/lagrange/releases/tag/v1.16.6 https://github.com/skyjake/lagrange/releases/tag/v1.16.7 https://github.com/skyjake/lagrange/releases/tag/v1.17.0 https://github.com/skyjake/lagrange/releases/tag/v1.17.1 https://github.com/skyjake/lagrange/releases/tag/v1.17.2 https://github.com/skyjake/lagrange/releases/tag/v1.17.3 https://github.com/skyjake/lagrange/releases/tag/v1.17.4 https://github.com/skyjake/lagrange/releases/tag/v1.17.5 https://github.com/skyjake/lagrange/releases/tag/v1.17.6 PR: 274414 276190 Approved by: lcook (maintainer, timeout > 6 months) MFH: 2024Q3 www/lagrange/Makefile | 6 +++--- www/lagrange/distinfo | 6 +++--- .../patch-lib_the__Foundation_src_tlsrequest.c | 21 --------------------- 3 files changed, 6 insertions(+), 27 deletions(-)
A commit in branch 2024Q3 references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=8674554e7b333a31b6c5549be46ed85cf431fbbe commit 8674554e7b333a31b6c5549be46ed85cf431fbbe Author: Nathan Fisher <nfisher.sr@gmail.com> AuthorDate: 2024-07-28 12:16:08 +0000 Commit: Vladimir Druzenko <vvd@FreeBSD.org> CommitDate: 2024-07-28 12:28:32 +0000 www/lagrange: update 1.16.5 → 1.17.6 Fix several crashes and memory leaks. Fix build on 15-CURRENT. Changelogs: https://github.com/skyjake/lagrange/releases/tag/v1.16.6 https://github.com/skyjake/lagrange/releases/tag/v1.16.7 https://github.com/skyjake/lagrange/releases/tag/v1.17.0 https://github.com/skyjake/lagrange/releases/tag/v1.17.1 https://github.com/skyjake/lagrange/releases/tag/v1.17.2 https://github.com/skyjake/lagrange/releases/tag/v1.17.3 https://github.com/skyjake/lagrange/releases/tag/v1.17.4 https://github.com/skyjake/lagrange/releases/tag/v1.17.5 https://github.com/skyjake/lagrange/releases/tag/v1.17.6 PR: 274414 276190 Approved by: lcook (maintainer, timeout > 6 months) MFH: 2024Q3 (cherry picked from commit b04495aa52fc2e75bfbeea6670de6c5c52c944db) www/lagrange/Makefile | 6 +++--- www/lagrange/distinfo | 6 +++--- .../patch-lib_the__Foundation_src_tlsrequest.c | 21 --------------------- 3 files changed, 6 insertions(+), 27 deletions(-)