pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/multimedia/vlc Adjust the static_assert hack to not re...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/086d3f5ec166
branches:  trunk
changeset: 348985:086d3f5ec166
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Tue Jun 21 17:58:05 2016 +0000

description:
Adjust the static_assert hack to not redefine the keyword if the
compiler itself claims C11 support.

diffstat:

 multimedia/vlc/distinfo                            |   4 ++--
 multimedia/vlc/patches/patch-include_vlc__fixups.h |  15 +++++++++------
 2 files changed, 11 insertions(+), 8 deletions(-)

diffs (59 lines):

diff -r 6e9fe7b7d932 -r 086d3f5ec166 multimedia/vlc/distinfo
--- a/multimedia/vlc/distinfo   Tue Jun 21 17:57:07 2016 +0000
+++ b/multimedia/vlc/distinfo   Tue Jun 21 17:58:05 2016 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.69 2016/05/12 15:56:15 wiz Exp $
+$NetBSD: distinfo,v 1.70 2016/06/21 17:58:05 joerg Exp $
 
 SHA1 (vlc-2.2.3.tar.xz) = 8d83c7b81e63956fdcb5cbee58cb2474d06baeae
 RMD160 (vlc-2.2.3.tar.xz) = 8c6d4194da37210fe409c965f430898fbe7f2416
@@ -8,7 +8,7 @@
 SHA1 (patch-compat_Makefile.am) = 983e9e29380702326d114274db99af72b5bdb3dd
 SHA1 (patch-compat_Makefile.in) = 809b1b00f14a5d85a17cd81b0385529ae24f39ee
 SHA1 (patch-include_vlc__common.h) = 26ab2c96230e3fbe26dd4bce60db7c5331eb3f6c
-SHA1 (patch-include_vlc__fixups.h) = 277cc7985f66fe3e8e94c75003e25aabd2f1bbfc
+SHA1 (patch-include_vlc__fixups.h) = 1a9f58b70f43fb87381d75d856682e3bcad14f6c
 SHA1 (patch-include_vlc_atomic.h) = 682ad69ece0267d41b62ef85429a8de312c17688
 SHA1 (patch-modules_access_directory.c) = 95bc95cb7eb0bf44684c04d2cecc2c4e8339f0f7
 SHA1 (patch-modules_access_file.c) = 22eb568aa5a1fea765e65a770432282024baaaf1
diff -r 6e9fe7b7d932 -r 086d3f5ec166 multimedia/vlc/patches/patch-include_vlc__fixups.h
--- a/multimedia/vlc/patches/patch-include_vlc__fixups.h        Tue Jun 21 17:57:07 2016 +0000
+++ b/multimedia/vlc/patches/patch-include_vlc__fixups.h        Tue Jun 21 17:58:05 2016 +0000
@@ -1,13 +1,13 @@
-$NetBSD: patch-include_vlc__fixups.h,v 1.2 2015/10/25 11:00:18 wiz Exp $
+$NetBSD: patch-include_vlc__fixups.h,v 1.3 2016/06/21 17:58:05 joerg Exp $
 
 on NetBSD-current, just define "uselocale", nothing else
 fixes build
 
-static_assert: a C compiler is used to detect if this symbol
-exists in assert.h, but the header file is included by a c++
-compiler too.
+static_assert: Assume that a compiler in C11 or C++11 frontend mode
+has the _Static_assert keyword, but define the macro if it is missing
+from the headers.
 
---- include/vlc_fixups.h.orig  2015-02-17 09:07:37.000000000 +0000
+--- include/vlc_fixups.h.orig  2015-04-13 19:54:35.000000000 +0000
 +++ include/vlc_fixups.h
 @@ -218,16 +218,28 @@ int posix_memalign (void **, size_t, siz
  
@@ -38,7 +38,7 @@
  static inline void freelocale(locale_t loc)
  {
      (void)loc;
-@@ -238,8 +250,9 @@ static inline locale_t newlocale(int mas
+@@ -238,9 +250,12 @@ static inline locale_t newlocale(int mas
      return NULL;
  }
  #endif
@@ -46,6 +46,9 @@
  
 -#if !defined (HAVE_STATIC_ASSERT)
 +#if !defined (static_assert)
++# if !(__STDC_VERSION__ - 0 >= 201112L || __cplusplus >= 201103L)
  # define _Static_assert(x, s) ((void) sizeof (struct { unsigned:-!(x); }))
++# endif
  # define static_assert _Static_assert
  #endif
+ 



Home | Main Index | Thread Index | Old Index