From 5f6ed9b7774a70882eecbb45e78ee31cafb53c71 Mon Sep 17 00:00:00 2001
From: j <0x006A@0x2620.org>
Date: Fri, 5 Aug 2011 12:19:04 +0200
Subject: [PATCH] large file support
---
Makefile | 4 +---
src/oxframe.c | 12 ++++++++++++
2 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/Makefile b/Makefile
index 94b8746..1d100ad 100644
--- a/Makefile
+++ b/Makefile
@@ -6,7 +6,6 @@ BINDIR ?= ${DESTDIR}${PREFIX}/bin
MAN1DIR ?= ${DESTDIR}${PREFIX}/man/man1
CC ?= gcc
-CFLAGS ?= -D_FILE_OFFSET_BITS=64
CFLAGS += -Wall -ffast-math -fsigned-char
CFLAGS += -I. -Isrc -Isrc/halloc
@@ -15,8 +14,7 @@ INSTALL = install
INCLUDEFLAGS ?= `pkg-config --cflags oggplay nestegg` `imlib2-config --cflags`
LINKFLAGS ?= -L${PREFIX}/lib
LINKFLAGS += `imlib2-config --libs`
-LINKFLAGS += `pkg-config --libs oggplay nestegg`
-LINKFLAGS += -lvpx
+LINKFLAGS += `pkg-config --libs oggplay nestegg vpx`
all: ${PROG}
diff --git a/src/oxframe.c b/src/oxframe.c
index e4ff7eb..1f8a6e0 100644
--- a/src/oxframe.c
+++ b/src/oxframe.c
@@ -16,6 +16,18 @@
* You should have received a copy of the GNU General Public License
* along with This program. If not, see .
*/
+#if !defined(_GNU_SOURCE)
+#define _GNU_SOURCE
+#endif
+#if !defined(_LARGEFILE_SOURCE)
+#define _LARGEFILE_SOURCE
+#endif
+#if !defined(_LARGEFILE64_SOURCE)
+#define _LARGEFILE64_SOURCE
+#endif
+#if !defined(_FILE_OFFSET_BITS)
+#define _FILE_OFFSET_BITS 64
+#endif
#include
#include