Bug 261491

Summary: net/ntp: Fails to build: error: use of undeclared identifier 'PROC_STACKGAP_CTL' (4.2.8p15)
Product: Ports & Packages Reporter: tomasz.sowinski
Component: Individual Port(s)Assignee: Cy Schubert <cy>
Status: Closed FIXED    
Severity: Affects Some People Keywords: needs-qa
Priority: --- Flags: koobs: maintainer-feedback+
koobs: merge-quarterly?
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
My build log of ntp
none
Fix ASLR build none

Description tomasz.sowinski 2022-01-26 12:04:07 UTC
I have problem with building port mentioned in summary.

FreeBSD details:
FreeBSD dlna.nucleus.malbork.pl 13.0-STABLE FreeBSD 13.0-STABLE #33 stable/13-n249136-c595625abe8: Mon Jan 24 20:52:23 CET 2022     root@host.nucleus.malbork.pl:/usr/obj/usr/src/amd64.amd64/sys/NUCLEUS  amd64

Problem decriprion:

--- refclock_gpsdjson.o ---
mv -f .deps/refclock_gpsdjson.Tpo .deps/refclock_gpsdjson.Po
--- ntp_io.o ---
mv -f .deps/ntp_io.Tpo .deps/ntp_io.Po
--- ntp_proto.o ---
1 warning generated.
mv -f .deps/ntp_proto.Tpo .deps/ntp_proto.Po
--- ntp_request.o ---
mv -f .deps/ntp_request.Tpo .deps/ntp_request.Po
--- ntp_config.o ---
6 warnings generated.
mv -f .deps/ntp_config.Tpo .deps/ntp_config.Po
--- ntp_crypto.o ---
mv -f .deps/ntp_crypto.Tpo .deps/ntp_crypto.Po
--- ntp_control.o ---
mv -f .deps/ntp_control.Tpo .deps/ntp_control.Po
1 error

make[6]: stopped in /var/ports/basejail/usr/ports/net/ntp/work/ntp-4.2.8p15/ntpd

make[5]: stopped in /var/ports/basejail/usr/ports/net/ntp/work/ntp-4.2.8p15/ntpd

make[4]: stopped in /var/ports/basejail/usr/ports/net/ntp/work/ntp-4.2.8p15

make[3]: stopped in /var/ports/basejail/usr/ports/net/ntp/work/ntp-4.2.8p15
===> Compilation failed unexpectedly.
Try to set MAKE_JOBS_UNSAFE=yes and rebuild before reporting the failure to
the maintainer.
*** Error code 1

Stop.
make[2]: stopped in /basejail/usr/ports/net/ntp
*** Error code 1

Stop.
make[1]: stopped in /basejail/usr/ports/net/ntp
*** Error code 1

Stop.
make: stopped in /basejail/usr/ports/net/ntp
Comment 1 Cy Schubert freebsd_committer freebsd_triage 2022-01-26 13:54:40 UTC
This is not enough of a log to see why it failed. Upload the complete log as an attachment, please.
Comment 2 tomasz.sowinski 2022-01-26 18:02:29 UTC
Created attachment 231361 [details]
My build log of ntp
Comment 3 Cy Schubert freebsd_committer freebsd_triage 2022-01-26 18:07:43 UTC
It's stack gap.
Comment 4 Cy Schubert freebsd_committer freebsd_triage 2022-01-26 18:11:13 UTC
What is the output of, grep __FreeBSD_version /usr/include/sys/param.h ?
Comment 5 Cy Schubert freebsd_committer freebsd_triage 2022-01-26 18:16:45 UTC
Created attachment 231362 [details]
Fix ASLR build

This will fix the problem.
Comment 6 commit-hook freebsd_committer freebsd_triage 2022-01-26 22:31:48 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=646499bcb3f4f8e8ba96b767d102d674091c674c

commit 646499bcb3f4f8e8ba96b767d102d674091c674c
Author:     Cy Schubert <cy@FreeBSD.org>
AuthorDate: 2022-01-26 18:18:22 +0000
Commit:     Cy Schubert <cy@FreeBSD.org>
CommitDate: 2022-01-26 22:29:53 +0000

    net/ntp: Fix build on older FreeBSD

    Fix stackgap build on older FreeBSD.

    PR:             261491
    Reported by:    tomasz.sowinski@nucleus.malbork.pl
    MFH:            2022Q1

 net/ntp/files/patch-ntpd_ntpd.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
Comment 7 commit-hook freebsd_committer freebsd_triage 2022-01-26 22:33:49 UTC
A commit in branch 2022Q1 references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=f330af79fbae3022f144a56e80ec6492701a8907

commit f330af79fbae3022f144a56e80ec6492701a8907
Author:     Cy Schubert <cy@FreeBSD.org>
AuthorDate: 2022-01-26 18:18:22 +0000
Commit:     Cy Schubert <cy@FreeBSD.org>
CommitDate: 2022-01-26 22:32:17 +0000

    net/ntp: Fix build on older FreeBSD

    Fix stackgap build on older FreeBSD.

    PR:             261491
    Reported by:    tomasz.sowinski@nucleus.malbork.pl

    (cherry picked from commit 646499bcb3f4f8e8ba96b767d102d674091c674c)

 net/ntp/files/patch-ntpd_ntpd.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
Comment 8 Cy Schubert freebsd_committer freebsd_triage 2022-01-26 23:54:33 UTC
Fixed.