Apply patch from upstream to fix a warning.
This allows build of the gstreamer1 libvisual plugin with -Werror. PR: ports/191189 Submitted by: kwm
This commit is contained in:
parent
4ffa30e22c
commit
610e63f3e6
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=359607
@ -3,7 +3,7 @@
|
||||
|
||||
PORTNAME= libvisual
|
||||
PORTVERSION= 0.4.0
|
||||
PORTREVISION= 3
|
||||
PORTREVISION= 4
|
||||
CATEGORIES= graphics
|
||||
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION}
|
||||
PKGNAMESUFFIX= 04
|
||||
@ -14,8 +14,7 @@ COMMENT= Abstraction library that sits between apps and visual plugin
|
||||
LICENSE= GPLv2
|
||||
LICENSE_FILE= ${WRKSRC}/COPYING
|
||||
|
||||
USE_AUTOTOOLS= libtool
|
||||
USES= gettext pathfix pkgconfig
|
||||
USES= gettext libtool:keepla pathfix pkgconfig
|
||||
GNU_CONFIGURE= yes
|
||||
CPPFLAGS+= -I${LOCALBASE}/include ${PTHREAD_CFLAGS}
|
||||
LDFLAGS+= -L${LOCALBASE}/lib ${PTHREAD_LIBS}
|
||||
|
55
graphics/libvisual04/files/patch-libvisual-lv_defines.h
Normal file
55
graphics/libvisual04/files/patch-libvisual-lv_defines.h
Normal file
@ -0,0 +1,55 @@
|
||||
--- lv_defines.h.orig 2006-01-22 13:23:37.000000000 +0000
|
||||
+++ libvisual/lv_defines.h 2014-06-24 19:56:46.961214708 +0100
|
||||
@@ -39,14 +39,13 @@
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#ifdef NULL
|
||||
-#undef NULL
|
||||
+# ifndef __cplusplus
|
||||
+# define NULL ((void *) 0)
|
||||
+# else
|
||||
+# define NULL 0
|
||||
+# endif
|
||||
#endif
|
||||
|
||||
-/**
|
||||
- * NULL define.
|
||||
- */
|
||||
-#define NULL ((void *) 0)
|
||||
-
|
||||
#ifndef FALSE
|
||||
/**
|
||||
* FALSE define.
|
||||
@@ -63,17 +62,21 @@
|
||||
|
||||
/* Compiler specific optimalization macros */
|
||||
#if __GNUC__ >= 3
|
||||
-# define inline inline __attribute__ ((always_inline))
|
||||
-# define __malloc __attribute__ ((malloc))
|
||||
-# define __packed __attribute__ ((packed))
|
||||
-# define VIS_LIKELY(x) __builtin_expect (!!(x), 1)
|
||||
-# define VIS_UNLIKELY(x) __builtin_expect (!!(x), 0)
|
||||
+# ifndef __cplusplus
|
||||
+# define inline inline __attribute__ ((always_inline))
|
||||
+# endif
|
||||
+# define VIS_ATTR_MALLOC __attribute__ ((malloc))
|
||||
+# define VIS_ATTR_PACKED __attribute__ ((packed))
|
||||
+# define VIS_LIKELY(x) __builtin_expect (!!(x), 1)
|
||||
+# define VIS_UNLIKELY(x) __builtin_expect (!!(x), 0)
|
||||
#else
|
||||
-# define inline /* no inline */
|
||||
-# define __malloc /* no malloc */
|
||||
-# define __packed /* no packed */
|
||||
-# define VIS_LIKELY(x) (x)
|
||||
-# define VIS_UNLIKELY(x) (x)
|
||||
-#endif
|
||||
+# ifndef __cplusplus
|
||||
+# define inline /* no inline */
|
||||
+# endif
|
||||
+# define VIS_ATTR_MALLOC /* no malloc */
|
||||
+# define VIS_ATTR_PACKED /* no packed */
|
||||
+# define VIS_LIKELY(x) (x)
|
||||
+# define VIS_UNLIKELY(x) (x)
|
||||
+#endif /* __GNUC__ >= 3 */
|
||||
|
||||
#endif /* _LV_DEFINES_H */
|
15
graphics/libvisual04/files/patch-libvisual-lv_mem.h
Normal file
15
graphics/libvisual04/files/patch-libvisual-lv_mem.h
Normal file
@ -0,0 +1,15 @@
|
||||
--- libvisual/lv_mem.h.orig 2014-06-24 19:51:48.637214311 +0100
|
||||
+++ libvisual/lv_mem.h 2014-06-24 19:53:14.723215426 +0100
|
||||
@@ -76,9 +76,9 @@
|
||||
|
||||
/* prototypes */
|
||||
int visual_mem_initialize (void);
|
||||
-void *visual_mem_malloc (visual_size_t nbytes) __malloc;
|
||||
-void *visual_mem_malloc0 (visual_size_t nbytes) __malloc;
|
||||
-void *visual_mem_realloc (void *ptr, visual_size_t nbytes) __malloc;
|
||||
+void *visual_mem_malloc (visual_size_t nbytes) VIS_ATTR_MALLOC;
|
||||
+void *visual_mem_malloc0 (visual_size_t nbytes) VIS_ATTR_MALLOC;
|
||||
+void *visual_mem_realloc (void *ptr, visual_size_t nbytes) VIS_ATTR_MALLOC;
|
||||
int visual_mem_free (void *ptr);
|
||||
|
||||
/* Optimal performance functions set by visual_mem_initialize(). */
|
@ -43,10 +43,10 @@ include/libvisual%%VER%%/libvisual/lv_ui.h
|
||||
include/libvisual%%VER%%/libvisual/lv_utils.h
|
||||
include/libvisual%%VER%%/libvisual/lv_video.h
|
||||
include/libvisual%%VER%%/libvisual/lvconfig.h
|
||||
lib/libvisual%%VER%%.a
|
||||
lib/libvisual%%VER%%.la
|
||||
lib/libvisual%%VER%%.so
|
||||
lib/libvisual%%VER%%.so.0
|
||||
lib/libvisual%%VER%%.so.0.0.0
|
||||
libdata/pkgconfig/libvisual%%VER%%.pc
|
||||
share/locale/es_AR/LC_MESSAGES/libvisual%%VER%%.mo
|
||||
share/locale/es_ES/LC_MESSAGES/libvisual%%VER%%.mo
|
||||
|
Loading…
Reference in New Issue
Block a user