[FFmpeg-devel] [PATCH] libavformat, libswscale: fix warning for deprecated macros
Ganesh Ajjanagadde
gajjanagadde at gmail.com
Thu Jun 4 18:40:58 CEST 2015
Version 2.20 of glibc deprecates _BSD_SOURCE and _SVID_SOURCE
and replaces with _DEFAULT_SOURCE
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde at gmail.com>
---
libavformat/img2dec.c | 2 +-
libavformat/udp.c | 2 +-
libswscale/utils.c | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/libavformat/img2dec.c b/libavformat/img2dec.c
index 0830f00..7ce7bf6 100644
--- a/libavformat/img2dec.c
+++ b/libavformat/img2dec.c
@@ -20,7 +20,7 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#define _BSD_SOURCE
+#define _DEFAULT_SOURCE
#include <sys/stat.h>
#include "libavutil/avstring.h"
#include "libavutil/log.h"
diff --git a/libavformat/udp.c b/libavformat/udp.c
index d40ea97..5210b38 100644
--- a/libavformat/udp.c
+++ b/libavformat/udp.c
@@ -24,7 +24,7 @@
* UDP protocol
*/
-#define _BSD_SOURCE /* Needed for using struct ip_mreq with recent glibc */
+#define _DEFAULT_SOURCE /* Needed for using struct ip_mreq with recent glibc */
#include "avformat.h"
#include "avio_internal.h"
diff --git a/libswscale/utils.c b/libswscale/utils.c
index f9f4ec6..ab1aa9e 100644
--- a/libswscale/utils.c
+++ b/libswscale/utils.c
@@ -20,7 +20,7 @@
#include "config.h"
-#define _SVID_SOURCE // needed for MAP_ANONYMOUS
+#define _DEFAULT_SOURCE // needed for MAP_ANONYMOUS
#define _DARWIN_C_SOURCE // needed for MAP_ANON
#include <inttypes.h>
#include <math.h>
--
2.4.2
More information about the ffmpeg-devel
mailing list