Created
July 27, 2012 02:08
-
-
Save opensiriusfox/3185810 to your computer and use it in GitHub Desktop.
OMXPlayer Patch to enable Native Raspberry Pi Builds (Jul 26 2012) [FOR ec4e7bc41d6d2f2c6ace48a0752bf82756f4ff40]
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff -rupN Makefile Makefile | |
--- Makefile 2012-07-26 14:20:21.179058001 -0700 | |
+++ Makefile 2012-07-26 14:45:18.667563466 -0700 | |
@@ -1,6 +1,6 @@ | |
include Makefile.include | |
-CFLAGS+=-DSTANDALONE -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -DTARGET_POSIX -D_LINUX -fPIC -DPIC -D_REENTRANT -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -DHAVE_CMAKE_CONFIG -D__VIDEOCORE4__ -U_FORTIFY_SOURCE -Wall -DHAVE_OMXLIB -DUSE_EXTERNAL_FFMPEG -DHAVE_LIBAVCODEC_AVCODEC_H -DHAVE_LIBAVUTIL_OPT_H -DHAVE_LIBAVUTIL_MEM_H -DHAVE_LIBAVUTIL_AVUTIL_H -DHAVE_LIBAVFORMAT_AVFORMAT_H -DHAVE_LIBAVFILTER_AVFILTER_H -DOMX -DOMX_SKIP64BIT -ftree-vectorize -pipe -DUSE_EXTERNAL_OMX -DTARGET_RASPBERRY_PI -DUSE_EXTERNAL_LIBBCM_HOST -Wno-psabi -I$(SDKSTAGE)/opt/vc/include/ | |
+CFLAGS+=-DSTANDALONE -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -DTARGET_POSIX -D_LINUX -fPIC -DPIC -D_REENTRANT -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -DHAVE_CMAKE_CONFIG -D__VIDEOCORE4__ -U_FORTIFY_SOURCE -Wall -DHAVE_OMXLIB -DUSE_EXTERNAL_FFMPEG -DHAVE_LIBAVCODEC_AVCODEC_H -DHAVE_LIBAVUTIL_OPT_H -DHAVE_LIBAVUTIL_MEM_H -DHAVE_LIBAVUTIL_AVUTIL_H -DHAVE_LIBAVFORMAT_AVFORMAT_H -DHAVE_LIBAVFILTER_AVFILTER_H -DOMX -DOMX_SKIP64BIT -ftree-vectorize -pipe -DUSE_EXTERNAL_OMX -DTARGET_RASPBERRY_PI -DUSE_EXTERNAL_LIBBCM_HOST -Wno-psabi -I/opt/vc/include/ | |
LDFLAGS+=-L./ -lc -lWFC -lGLESv2 -lEGL -lbcm_host -lopenmaxil -Lffmpeg_compiled/usr/local/lib/ | |
INCLUDES+=-I./ -Ilinux -Iffmpeg_compiled/usr/local/include/ | |
@@ -57,9 +57,9 @@ ffmpeg: | |
dist: omxplayer.bin | |
mkdir -p omxplayer-dist/usr/lib/omxplayer | |
- mkdir -p omxplayer-dist/usr/usr/bin | |
+ mkdir -p omxplayer-dist/usr/bin | |
mkdir -p omxplayer-dist/usr/share/doc | |
- cp omxplayer omxplayer.bin omxplayer-dist/usr/usr/bin | |
+ cp omxplayer omxplayer.bin omxplayer-dist/usr/bin | |
cp COPYING omxplayer-dist/usr/share/doc/ | |
cp README.md omxplayer-dist/usr/share/doc/README | |
cp -a ffmpeg_compiled/usr/local/lib/*.so* omxplayer-dist/usr/lib/omxplayer/ | |
diff -rupN Makefile.ffmpeg Makefile.ffmpeg | |
--- Makefile.ffmpeg 2012-07-26 14:20:21.179058001 -0700 | |
+++ Makefile.ffmpeg 2012-07-26 14:44:39.435263500 -0700 | |
@@ -8,18 +8,18 @@ all: checkout configure compile | |
copy: | |
find ffmpeg -name '*.so*' -exec cp {} . \; | |
- $(HOST)-strip *.so* | |
+ strip *.so* | |
compile: | |
cd ffmpeg; \ | |
- make -j9 | |
+ make | |
configure: | |
cd ffmpeg; \ | |
CFLAGS="$(CFLAGS) ${INCLUDES}" \ | |
LDFLAGS="" \ | |
./configure \ | |
- --extra-cflags="-mfpu=vfp -mfloat-abi=softfp -mno-apcs-stack-check -mstructure-size-boundary=32 -mno-sched-prolog" \ | |
+ --extra-cflags="-mfpu=vfp -mfloat-abi=hard -mno-apcs-stack-check -mstructure-size-boundary=32 -mno-sched-prolog" \ | |
--enable-cross-compile \ | |
--enable-shared \ | |
--disable-static \ | |
@@ -52,9 +52,7 @@ configure: | |
--enable-armv6 \ | |
--enable-armvfp \ | |
--enable-hardcoded-tables \ | |
- --disable-runtime-cpudetect \ | |
- --disable-debug \ | |
- --cross-prefix=$(HOST)- | |
+ --disable-debug | |
clean: | |
@rm -rf ffmpeg | |
@@ -64,6 +62,6 @@ checkout: | |
cd ffmpeg; git checkout master; git checkout 13a7bd70c8d94c5a46c14e7ac23a170b77eff52e | |
install: | |
- cd ffmpeg; make -j9 DESTDIR="$(WORK)/ffmpeg_compiled" install | |
- $(HOST)-strip ffmpeg_compiled/usr/local/lib/*.so | |
+ cd ffmpeg; make DESTDIR="$(WORK)/ffmpeg_compiled" install | |
+ strip ffmpeg_compiled/usr/local/lib/*.so | |
diff -rupN Makefile.include Makefile.include | |
--- Makefile.include 2012-07-26 14:20:21.189058001 -0700 | |
+++ Makefile.include 2012-07-26 14:42:09.955361245 -0700 | |
@@ -1,37 +1,7 @@ | |
-USE_BUILDROOT=1 | |
- | |
-ifeq ($(USE_BUILDROOT), 1) | |
-BUILDROOT :=/opt/xbmc-bcm/buildroot | |
-SDKSTAGE :=$(BUILDROOT)/output/staging | |
-TARGETFS :=$(BUILDROOT)/output/target | |
-TOOLCHAIN :=$(BUILDROOT)/output/host/usr/ | |
-HOST :=arm-unknown-linux-gnueabi | |
-SYSROOT :=$(BUILDROOT)/output/host/usr/arm-unknown-linux-gnueabi/sysroot | |
-else | |
-BUILDROOT :=/opt/bcm-rootfs | |
-SDKSTAGE :=/opt/bcm-rootfs | |
-TARGETFS :=/opt/bcm-rootfs | |
-TOOLCHAIN :=/usr/local/bcm-gcc | |
-HOST :=bcm2708 | |
-SYSROOT :=$(TOOLCHAIN)/arm-bcm2708-linux-gnueabi/sys-root | |
-endif | |
- | |
-JOBS=7 | |
- | |
-CFLAGS := -isystem$(PREFIX)/include | |
CXXFLAGS := $(CFLAGS) | |
CPPFLAGS := $(CFLAGS) | |
-LDFLAGS := -L$(BUILDROOT)/lib | |
-LD := $(TOOLCHAIN)/bin/$(HOST)-ld --sysroot=$(SYSROOT) | |
-CC := $(TOOLCHAIN)/bin/$(HOST)-gcc --sysroot=$(SYSROOT) | |
-CXX := $(TOOLCHAIN)/bin/$(HOST)-g++ --sysroot=$(SYSROOT) | |
-OBJDUMP := $(TOOLCHAIN)/bin/$(HOST)-objdump | |
-RANLIB := $(TOOLCHAIN)/bin/$(HOST)-ranlib | |
-STRIP := $(TOOLCHAIN)/bin/$(HOST)-strip | |
-AR := $(TOOLCHAIN)/bin/$(HOST)-ar | |
CXXCP := $(CXX) -E | |
-PATH := $(PREFIX)/bin:$(BUILDROOT)/output/host/usr/bin:$(PATH) | |
-CFLAGS += -pipe -mfloat-abi=softfp -mcpu=arm1176jzf-s -fomit-frame-pointer -mabi=aapcs-linux -mtune=arm1176jzf-s -mfpu=vfp -Wno-psabi -mno-apcs-stack-check -O3 -mstructure-size-boundary=32 -mno-sched-prolog | |
-LDFLAGS += -L$(SDKSTAGE)/lib -L$(SDKSTAGE)/usr/lib -L$(SDKSTAGE)/opt/vc/lib/ | |
-INCLUDES += -isystem$(SDKSTAGE)/staging/usr/include -isystem$(SDKSTAGE)/staging/opt/vc/include -isystem$(SYSROOT)/usr/include -isystem$(SDKSTAGE)/opt/vc/include/interface/vcos/pthreads | |
+CFLAGS += -pipe -mfloat-abi=hard -mcpu=arm1176jzf-s -fomit-frame-pointer -mabi=aapcs-linux -mtune=arm1176jzf-s -mfpu=vfp -Wno-psabi -mno-apcs-stack-check -O3 -mstructure-size-boundary=32 -mno-sched-prolog | |
+LDFLAGS += -L/lib -L/usr/lib -L/opt/vc/lib/ | |
+INCLUDES += -isystem/usr/include -isystem/opt/vc/include -isystem/usr/include -isystem/opt/vc/include/interface/vcos/pthreads | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment