diff options
author | ahze <ahze@FreeBSD.org> | 2005-04-21 13:06:03 +0000 |
---|---|---|
committer | ahze <ahze@FreeBSD.org> | 2005-04-21 13:06:03 +0000 |
commit | 650826bdf535fcb85fc5ec4ebf3286dbeea73cb5 (patch) | |
tree | 8ea3f9357cac2d865cb3a078d0ab26024c9ab5dd /multimedia/x264 | |
parent | 57e91132aa3b574200e9691377a234139a128614 (diff) | |
download | FreeBSD-ports-650826bdf535fcb85fc5ec4ebf3286dbeea73cb5.zip FreeBSD-ports-650826bdf535fcb85fc5ec4ebf3286dbeea73cb5.tar.gz |
- Update to 0.0.20050421 (cvs snapshot)
Diffstat (limited to 'multimedia/x264')
-rw-r--r-- | multimedia/x264/Makefile | 29 | ||||
-rw-r--r-- | multimedia/x264/distinfo | 4 | ||||
-rw-r--r-- | multimedia/x264/files/patch-Makefile | 77 | ||||
-rw-r--r-- | multimedia/x264/files/patch-configure | 22 | ||||
-rw-r--r-- | multimedia/x264/files/patch-encoder_encoder.c | 27 |
5 files changed, 70 insertions, 89 deletions
diff --git a/multimedia/x264/Makefile b/multimedia/x264/Makefile index a6aed1a..58e8bb3 100644 --- a/multimedia/x264/Makefile +++ b/multimedia/x264/Makefile @@ -6,7 +6,7 @@ # PORTNAME= x264 -PORTVERSION= 0.0.20050125 +PORTVERSION= 0.0.20050421 CATEGORIES= multimedia MASTER_SITES= ${MASTER_SITE_LOCAL:S|$|ahze/|} # http://download.videolan.org/pub/videolan/contrib/ \ @@ -22,9 +22,9 @@ WRKSRC= ${WRKDIR}/${DISTNAME} USE_REINPLACE= yes USE_GMAKE= yes ALL_TARGET= default -SHLIB_VER= 0 -CFLAGS+= -DSYS_FREEBSD +SHLIB_VER= 1 INSTALLS_SHLIB= yes +HAS_CONFIGURE= yes PLIST_FILES= bin/x264 \ include/x264.h \ @@ -35,34 +35,29 @@ PLIST_FILES= bin/x264 \ OPTIONS= DEBUG "Enable Debugging" Off \ OPTIMIZED_CFLAGS "Enable Optimized CFLAGS" Off +CONFIGURE_ARGS+= --extra-cflags="${CPPFLAGS} ${CFLAGS} -fPIC" \ + --extra-ldflags="${LDFLAGS}" + .include <bsd.port.pre.mk> .if ${ARCH}=="i386" BUILD_DEPENDS+= nasm:${PORTSDIR}/devel/nasm - -CFLAGS+= -DARCH_X86 MAKE_ENV+= ARCH_X86="1" -.if ${MACHINE_CPU:Mmmx} -CFLAGS+= -DHAVE_MMXEXT -.endif -.if ${MACHINE_CPU:Msse} -CFLAGS+= -DHAVE_SSE2 .endif + +.if ${ARCH}=="amd64" +BUILD_DEPENDS+= yasm:${PORTSDIR}/devel/yasm +MAKE_ENV+= ARCH_X86_64="1" .endif .if !defined(WITH_DEBUG) -MAKE_ENV+= NDEBUG="1" +CONFIGURE_ARGS+= --enable-debug .endif .if defined(WITH_OPTIMIZED_CFLAGS) -CFLAGS+= -O2 -funroll-loops +CFLAGS+= -O2 -funroll-loops -ffast-math .endif -post-patch: - @${REINPLACE_CMD} -e 's|%%CFLAGS%%|${CPPFLAGS} ${CFLAGS}|; \ - s|%%SHLIB_VER%%|${SHLIB_VER}|; \ - s|-lm|${LDFLAGS} -lm|' ${WRKSRC}/${MAKEFILE} - do-install: ${INSTALL_PROGRAM} ${WRKSRC}/x264 ${PREFIX}/bin ${INSTALL_DATA} ${WRKSRC}/x264.h ${PREFIX}/include diff --git a/multimedia/x264/distinfo b/multimedia/x264/distinfo index ab337c6..c4e752c 100644 --- a/multimedia/x264/distinfo +++ b/multimedia/x264/distinfo @@ -1,2 +1,2 @@ -MD5 (x264-20050125.tar.bz2) = 8e43454d1062f84703b3193b1bce8769 -SIZE (x264-20050125.tar.bz2) = 160325 +MD5 (x264-20050421.tar.bz2) = efc6015056884e1228567c7a30e32fd0 +SIZE (x264-20050421.tar.bz2) = 186455 diff --git a/multimedia/x264/files/patch-Makefile b/multimedia/x264/files/patch-Makefile index 6a8172d..05eb5a7 100644 --- a/multimedia/x264/files/patch-Makefile +++ b/multimedia/x264/files/patch-Makefile @@ -1,59 +1,50 @@ ---- Makefile.orig Tue Jan 25 16:36:54 2005 -+++ Makefile Mon Jan 31 01:14:20 2005 -@@ -12,18 +12,19 @@ - encoder/set.c encoder/macroblock.c encoder/cabac.c \ - encoder/cavlc.c encoder/encoder.c encoder/eval.c x264.c - --ifdef SYS_MACOSX --PFLAGS=-DARCH_PPC -DSYS_MACOSX -faltivec --SRCS= $(SRCS_COMMON) common/ppc/mc.c common/ppc/pixel.c --else --PFLAGS=-DARCH_X86 -DHAVE_MMXEXT -DHAVE_SSE2 -DHAVE_MALLOC_H +--- Makefile.orig Thu Apr 21 08:02:33 2005 ++++ Makefile Thu Apr 21 08:11:28 2005 +@@ -10,7 +10,7 @@ + encoder/cavlc.c encoder/encoder.c encoder/eval.c + + # MMX/SSE optims +-ifeq ($(ARCH),X86) +ifdef ARCH_X86 - SRCS= $(SRCS_COMMON) common/i386/mc-c.c common/i386/dct-c.c common/i386/predict.c - ASMSRC= common/i386/dct-a.asm common/i386/cpu-a.asm common/i386/pixel-a.asm common/i386/mc-a.asm - OBJASM= $(ASMSRC:%.asm=%.o) -+else -+SRCS= $(SRCS_COMMON) + SRCS += common/i386/mc-c.c common/i386/dct-c.c common/i386/predict.c + ASMSRC = common/i386/dct-a.asm common/i386/cpu-a.asm \ + common/i386/pixel-a.asm common/i386/mc-a.asm \ +@@ -19,7 +19,7 @@ endif --CC=gcc --CFLAGS=-Wall -I. -O4 -funroll-loops -D__X264__ $(PFLAGS) -+SHARED_LIB= libx264.so -+SHARED_LIB_VER= $(SHARED_LIB).%%SHLIB_VER%% -+ -+CFLAGS=-I. -D__X264__ %%CFLAGS%% -fPIC -+ - ifdef NDEBUG - CFLAGS+=-s -DNDEBUG - else -@@ -39,14 +40,17 @@ + # MMX/SSE optims +-ifeq ($(ARCH),X86_64) ++ifdef ARCH_X86_64 + SRCS += common/amd64/mc-c.c common/amd64/dct-c.c common/amd64/predict.c + ASMSRC = common/amd64/dct-a.asm common/amd64/cpu-a.asm \ + common/amd64/pixel-a.asm common/amd64/mc-a.asm \ +@@ -35,19 +35,25 @@ OBJS = $(SRCS:%.c=%.o) DEP = depend --default: $(DEP) x264 -+default: $(DEP) x264 $(SHARED_LIB_VER) +-default: $(DEP) x264$(EXE) ++SHARED_LIB = libx264.so ++SHARED_LIB_VER = $(SHARED_LIB).1 ++ ++default: $(DEP) x264$(EXE) $(SHARED_LIB_VER) - libx264.a: $(OBJS) $(OBJASM) + libx264.a: .depend $(OBJS) $(OBJASM) ar rc libx264.a $(OBJS) $(OBJASM) ranlib libx264.a --x264: libx264.a x264.o -- $(CC) $(CFLAGS) -o x264 x264.o libx264.a -lm -+x264: $(SHARED_LIB_VER) x264.o -+ $(CC) $(CFLAGS) -o x264 x264.o $(SHARED_LIB_VER) -lm +-x264$(EXE): libx264.a x264.o +- $(CC) -o $@ x264.o libx264.a $(LDFLAGS) ++x264$(EXE): $(SHARED_LIB_VER) x264.o ++ $(CC) -o $@ x264.o $(SHARED_LIB_VER) $(LDFLAGS) + +$(SHARED_LIB_VER): $(OBJS) libx264.a + $(CC) $(CFLAGS) -shared -Wl,-soname,$(SHARED_LIB_VER) -o $(SHARED_LIB_VER) $(OBJS) $(OBJASM) -lm - checkasm: testing/checkasm.c libx264.a - $(CC) $(CFLAGS) -o checkasm $< libx264.a -lm -@@ -56,7 +60,7 @@ + x264vfw.dll: libx264.a $(wildcard vfw/*.c vfw/*.h) + make -C vfw/build/cygwin - .depend: $(SRCS) x264.c - rm -f .depend -- $(foreach SRC, $(SRCS) x264.c, $(CC) $(CFLAGS) $(SRC) -MM -MT $(SRC:%.c=%.o) 1>> .depend;) -+ $(CC) -MM $(CFLAGS) $(SRCS) x264.c 1> .depend +-checkasm: testing/checkasm.o libx264.a ++checkasm: testing/checkasm.o $(SHARED_LIB_VER) + $(CC) -o $@ $< libx264.a $(LDFLAGS) - depend: .depend - ifneq ($(wildcard .depend),) + %.o: %.asm diff --git a/multimedia/x264/files/patch-configure b/multimedia/x264/files/patch-configure new file mode 100644 index 0000000..a45657d --- /dev/null +++ b/multimedia/x264/files/patch-configure @@ -0,0 +1,22 @@ +--- configure.orig Thu Apr 21 08:03:47 2005 ++++ configure Thu Apr 21 08:08:16 2005 +@@ -22,8 +22,8 @@ + debug="no" + vfw="no" + +-CC="gcc" +-CFLAGS="-Wall -I. -O4 -funroll-loops -ffast-math -D__X264__" ++#CC="gcc" ++CFLAGS="-Wall -I. -D__X264__" + LDFLAGS="" + + AS="nasm" +@@ -75,7 +75,7 @@ + ARCH="X86" + CFLAGS="$CFLAGS -DHAVE_MMXEXT -DHAVE_SSE2" + ;; +- x86_64) ++ x86_64 | amd64) + ARCH="X86_64" + CFLAGS="$CFLAGS -DHAVE_MMXEXT -DHAVE_SSE2" + AS="yasm" diff --git a/multimedia/x264/files/patch-encoder_encoder.c b/multimedia/x264/files/patch-encoder_encoder.c deleted file mode 100644 index 5395a23..0000000 --- a/multimedia/x264/files/patch-encoder_encoder.c +++ /dev/null @@ -1,27 +0,0 @@ ---- encoder/encoder.c.orig Tue Jan 25 21:28:32 2005 -+++ encoder/encoder.c Tue Jan 25 21:30:21 2005 -@@ -1113,12 +1113,14 @@ - if( i_slice_type == SLICE_TYPE_P && !h->param.rc.b_stat_read - && h->param.i_scenecut_threshold >= 0 ) - { -+ int i_gop_size; - int i_mb_i = h->stat.frame.i_mb_count[I_4x4] + h->stat.frame.i_mb_count[I_16x16]; - int i_mb_p = h->stat.frame.i_mb_count[P_L0] + h->stat.frame.i_mb_count[P_8x8]; - int i_mb_s = h->stat.frame.i_mb_count[P_SKIP]; - int i_mb = h->sps->i_mb_width * h->sps->i_mb_height; - int64_t i_inter_cost = h->stat.frame.i_inter_cost; - int64_t i_intra_cost = h->stat.frame.i_intra_cost; -+ float f_bias; - - float f_thresh_max = h->param.i_scenecut_threshold / 100.0; - /* ratio of 10 pulled out of thin air */ -@@ -1126,8 +1128,7 @@ - / ( h->param.i_keyint_max * 4 ); - if( h->param.i_keyint_min == h->param.i_keyint_max ) - f_thresh_min= f_thresh_max; -- float f_bias; -- int i_gop_size = h->fenc->i_frame - h->frames.i_last_idr; -+ i_gop_size = h->fenc->i_frame - h->frames.i_last_idr; - - /* macroblock_analyse() doesn't further analyse skipped mbs, - * so we have to guess their cost */ |