Bug 208175 - security/gnutls: Rename max_align_t definition conflicting with libc++
Summary: security/gnutls: Rename max_align_t definition conflicting with libc++
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Tijl Coosemans
URL:
Keywords:
Depends on:
Blocks: 208158
  Show dependency treegraph
 
Reported: 2016-03-21 10:15 UTC by Dimitry Andric
Modified: 2016-03-21 12:43 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (bdrewery)


Attachments
Rename conflicting max_align_t definition (949 bytes, patch)
2016-03-21 10:15 UTC, Dimitry Andric
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dimitry Andric freebsd_committer 2016-03-21 10:15:45 UTC
Created attachment 168448 [details]
Rename conflicting max_align_t definition

In bug 208158, I asked for an exp-run with updated libc++.  It turns out that security/gnutls attempts to redefine max_align_t, which is also present in libc++'s copy of stddef.h, and this conflicts.

Since gnutls doesn't really use the type at all, I thought it was easiest to simply rename the type to gnu_max_align_t.  This avoids any compilation errors of C++ sources in gnutls.

Alternatively, the whole block defining max_align_t could be deleted, but that is a more invasive change, and I don't know how the configure script will handle that...
Comment 1 Tijl Coosemans freebsd_committer 2016-03-21 10:52:56 UTC
Just append ac_cv_type_max_align_t=yes to CONFIGURE_ARGS in the port Makefile.
Comment 2 Dimitry Andric freebsd_committer 2016-03-21 11:47:51 UTC
(In reply to Tijl Coosemans from comment #1)
> Just append ac_cv_type_max_align_t=yes to CONFIGURE_ARGS in the port
> Makefile.

If that prevents gnutls from rolling its own copy, then it is even better, yes.
Comment 3 commit-hook freebsd_committer 2016-03-21 12:04:32 UTC
A commit references this bug:

Author: tijl
Date: Mon Mar 21 12:03:40 UTC 2016
New revision: 411557
URL: https://svnweb.freebsd.org/changeset/ports/411557

Log:
  - Take maintainer.
  - Fix a build problem with upcoming libc++.

  PR:		207768, 208175
  Approved by:	bdrewery (maintainer)

Changes:
  head/security/gnutls/Makefile