Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 20 Apr 2015 14:02:04 +0000 (UTC)
From:      Jan Beich <jbeich@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r384361 - head/games/openbor/files
Message-ID:  <201504201402.t3KE241s012534@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jbeich
Date: Mon Apr 20 14:02:03 2015
New Revision: 384361
URL: https://svnweb.freebsd.org/changeset/ports/384361

Log:
  Apply r379037 instead of trying to use C11's max_align_t
  
  While here use my own comment within the file in order to:
  - Avoid $FreeBSD$ keywords in patches (per Porter's Handbook)
  - Improve rationale
  
  Suggested by:	marino

Added:
  head/games/openbor/files/patch-source_webmlib_halloc
     - copied, changed from r384350, head/multimedia/libvpx/files/patch-nestegg_halloc_src
Deleted:
  head/games/openbor/files/patch-source_webmlib_halloc_align.h

Copied and modified: head/games/openbor/files/patch-source_webmlib_halloc (from r384350, head/multimedia/libvpx/files/patch-nestegg_halloc_src)
==============================================================================
--- head/multimedia/libvpx/files/patch-nestegg_halloc_src	Mon Apr 20 11:57:47 2015	(r384350, copy source)
+++ head/games/openbor/files/patch-source_webmlib_halloc	Mon Apr 20 14:02:03 2015	(r384361)
@@ -1,12 +1,23 @@
+C11 defines different max_align_t in stddef.h. It may either come from
+compiler (GCC, Clang) or provided by the system (DragonFly, musl libc).
+FreeBSD's Clang has neither due to bug 193594.
 
-$FreeBSD$
+So, keep the old behavior by renaming the type here to avoid building
+with -ansi (upstream nestegg) or -std=gnu89 (SUSE).
 
-Fix build on modern gcc which defines max_align_t for C11
-It renames the locale definition to avoid the name clash.
+  In file included from source/webmlib/halloc/halloc.c:19:0:
+  source/webmlib/halloc/align.h:42:25: error: conflicting types for 'max_align_t'
+   typedef union max_align max_align_t;
+                           ^
+  In file included from source/webmlib/halloc/halloc.h:18:0,
+                   from source/webmlib/halloc/halloc.c:18:
+  /usr/local/lib/gcc5/**/include/stddef.h:429:3: note: previous declaration of 'max_align_t' was here
+   } max_align_t;
+     ^
 
---- nestegg/halloc/src/align.h.orig
-+++ nestegg/halloc/src/align.h
-@@ -30,7 +30,7 @@
+--- source/webmlib/halloc/align.h.orig	2015-04-09 22:13:36 UTC
++++ source/webmlib/halloc/align.h
+@@ -39,7 +39,7 @@ union max_align
  	void (*q)(void);
  };
  
@@ -15,12 +26,9 @@ It renames the locale definition to avoi
  
  #endif
  
-
-$FreeBSD$
-
---- nestegg/halloc/src/halloc.c.orig
-+++ nestegg/halloc/src/halloc.c
-@@ -30,7 +30,7 @@
+--- source/webmlib/halloc/halloc.c.orig	2015-04-09 22:13:36 UTC
++++ source/webmlib/halloc/halloc.c
+@@ -30,7 +30,7 @@ typedef struct hblock
  #endif
  	hlist_item_t  siblings; /* 2 pointers */
  	hlist_head_t  children; /* 1 pointer  */



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201504201402.t3KE241s012534>