Bug 2179882
| Summary: | cube: Inconsistency in autoconf checks regarding AC_INCLUDES_DEFAULT | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Florian Weimer <fweimer> | ||||
| Component: | cube | Assignee: | Florian Weimer <fweimer> | ||||
| Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
| Severity: | unspecified | Docs Contact: | |||||
| Priority: | unspecified | ||||||
| Version: | rawhide | CC: | dave.love, orion | ||||
| Target Milestone: | --- | ||||||
| Target Release: | --- | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | cube-4.8.1-2.fc39 | Doc Type: | If docs needed, set a value | ||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2023-03-20 12:56:44 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Bug Depends On: | |||||||
| Bug Blocks: | 2141798 | ||||||
| Attachments: |
|
||||||
I've forwarded it to the maintainers, thanks. Is this just a problem for gcc 14, i.e. not imminent? (In reply to Dave Love from comment #1) > I've forwarded it to the maintainers, thanks. Okay, then I'll hold off sending my message. I'm testing a patch. > Is this just a problem for gcc 14, i.e. not imminent? I want to add approximating -Werror flags to the default flags fairly soon, certainly before GCC 14 lands in December or so. For upstream, it might be more pressing because they also have users with Clang, which has already made the switch. Created attachment 1952064 [details]
cube-configure-c99.patch
This patch seems to work. Upstream may need a different approach (e.g. for systems which do not have <unistd.h>).
|
ac_cube_posix_functions.m4 uses AC_CHECK_DECLS (which implies AC_INCLUDES_DEFAULT headers) to check for gethostid, gethosname, followed by a check for link-time availability using AC_LINK_IFELSE (not AC_CHECK_FUNC). The way AC_LINK_IFELSE used, AC_INCLUDES_DEFAULT headers are not applied, so the condition #if !HAVE_DECL_GETHOSTID long gethostid(void); #endif does not give the right result because <unistd.h> is not included at this point even though HAVE_DECL_GETHOSTID is defined. This causes problems with future compilers which do not support implicit function declarations. Filing this here because upstream does not seem to have a public bug tracker.