diff --git a/graphics/ffmpeg/Makefile b/graphics/ffmpeg/Makefile new file mode 100644 index 00000000000..57640967e28 --- /dev/null +++ b/graphics/ffmpeg/Makefile @@ -0,0 +1,39 @@ +# $OpenBSD: Makefile,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ + +COMMENT= "audio/video converter and streamer" +DISTNAME= ffmpeg-20030622 +EXTRACT_SUFX= .tar.bz2 +CATEGORIES= graphics +MASTER_SITES= http://www.videolan.org/pub/videolan/vlc/0.6.0/contrib/ + +HOMEPAGE= http://ffmpeg.sourceforge.net/ + +MAINTAINER= Jolan Luff + +# GPL +PERMIT_DISTFILES_CDROM= "patents" +PERMIT_DISTFILES_FTP= Yes +PERMIT_PACKAGE_CDROM= Yes +PERMIT_PACKAGE_FTP= Yes + +NO_REGRESS= Yes # Possible to adapt with some work +USE_GMAKE= Yes + +CONFIGURE_STYLE=simple +CONFIGURE_ARGS+=--cc=${CC} --make=gmake ${CONFIGURE_SHARED} + +do-install: + ${INSTALL_DATA_DIR} ${PREFIX}/include/ffmpeg + ${INSTALL_DATA_DIR} ${PREFIX}/include/postproc + ${INSTALL_DATA} ${WRKBUILD}/libavcodec/{avcodec,common}.h \ + ${PREFIX}/include/ffmpeg + ${INSTALL_DATA} ${WRKBUILD}/libavcodec/libpostproc/postprocess.h \ + ${PREFIX}/include/postproc + ${INSTALL_DATA} ${WRKBUILD}/libavcodec/libavcodec.a \ + ${WRKBUILD}/libavformat/libavformat.a ${PREFIX}/lib +.if !defined(NO_SHARED_LIBS) + ${INSTALL_DATA} ${WRKBUILD}/libavcodec/libavcodec.so \ + ${PREFIX}/lib/libavcodec.so.0.0 +.endif + +.include diff --git a/graphics/ffmpeg/distinfo b/graphics/ffmpeg/distinfo new file mode 100644 index 00000000000..e88537a384a --- /dev/null +++ b/graphics/ffmpeg/distinfo @@ -0,0 +1,3 @@ +MD5 (ffmpeg-20030622.tar.bz2) = 35fa282723b0f928214788f28620c19f +RMD160 (ffmpeg-20030622.tar.bz2) = 9b5ef8cbeb22dde1c28b4b3866af0f525a00b2e1 +SHA1 (ffmpeg-20030622.tar.bz2) = d7c88a26056d23b18d56885abb4cbcc09a544230 diff --git a/graphics/ffmpeg/patches/patch-Makefile b/graphics/ffmpeg/patches/patch-Makefile new file mode 100644 index 00000000000..8229b049ffb --- /dev/null +++ b/graphics/ffmpeg/patches/patch-Makefile @@ -0,0 +1,13 @@ +$OpenBSD: patch-Makefile,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- Makefile.orig Thu Jun 12 01:42:44 2003 ++++ Makefile Wed Jul 16 20:38:48 2003 +@@ -6,8 +6,7 @@ include config.mak + + VPATH=$(SRC_PATH) + +-CFLAGS= $(OPTFLAGS) -Wall -g -I. -I$(SRC_PATH) -I$(SRC_PATH)/libavcodec -I$(SRC_PATH)/libavformat -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE +-LDFLAGS+= -g ++CFLAGS= $(OPTFLAGS) -Wall -I. -I$(SRC_PATH) -I$(SRC_PATH)/libavcodec -I$(SRC_PATH)/libavformat -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE + + ifeq ($(TARGET_GPROF),yes) + CFLAGS+=-p diff --git a/graphics/ffmpeg/patches/patch-configure b/graphics/ffmpeg/patches/patch-configure new file mode 100644 index 00000000000..c2afdbb76b8 --- /dev/null +++ b/graphics/ffmpeg/patches/patch-configure @@ -0,0 +1,41 @@ +$OpenBSD: patch-configure,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- configure.orig Sun Jun 22 06:27:05 2003 ++++ configure Wed Jul 16 20:21:00 2003 +@@ -145,6 +145,14 @@ dv1394="no" + make="gmake" + LDFLAGS="$LDFLAGS -export-dynamic" + ;; ++OpenBSD) ++a52="no" ++audio_oss="no" ++dv1394="no" ++sdl="no" # not respected ++v4l="no" ++vhook="no" ++;; + BSD/OS) + v4l="no" + audio_oss="yes" +@@ -633,14 +641,14 @@ EOF + + sdl_too_old=no + sdl=no +-if $cc -o $TMPE `sdl-config --cflags` $TMPC `sdl-config --libs` 2> /dev/null ; then +-_sdlversion=`sdl-config --version | sed 's/[^0-9]//g'` +-if test "$_sdlversion" -lt 121 ; then +-sdl_too_old=yes +-else +-sdl=yes +-fi +-fi ++#if $cc -o $TMPE `sdl-config --cflags` $TMPC `sdl-config --libs` 2> /dev/null ; then ++#_sdlversion=`sdl-config --version | sed 's/[^0-9]//g'` ++#if test "$_sdlversion" -lt 121 ; then ++#sdl_too_old=yes ++#else ++#sdl=yes ++#fi ++#fi + + if test "$sdl" = "no" ; then + ffplay=no diff --git a/graphics/ffmpeg/patches/patch-ffserver_c b/graphics/ffmpeg/patches/patch-ffserver_c new file mode 100644 index 00000000000..eee2e658834 --- /dev/null +++ b/graphics/ffmpeg/patches/patch-ffserver_c @@ -0,0 +1,12 @@ +$OpenBSD: patch-ffserver_c,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- ffserver.c.orig Fri Apr 18 15:53:48 2003 ++++ ffserver.c Thu Jul 3 21:00:29 2003 +@@ -45,6 +45,8 @@ + /* maximum number of simultaneous HTTP connections */ + #define HTTP_MAX_CONNECTIONS 2000 + ++#define RTLD_NOW 0 ++ + enum HTTPState { + HTTPSTATE_WAIT_REQUEST, + HTTPSTATE_SEND_HEADER, diff --git a/graphics/ffmpeg/patches/patch-libavcodec_Makefile b/graphics/ffmpeg/patches/patch-libavcodec_Makefile new file mode 100644 index 00000000000..1040905f54a --- /dev/null +++ b/graphics/ffmpeg/patches/patch-libavcodec_Makefile @@ -0,0 +1,14 @@ +$OpenBSD: patch-libavcodec_Makefile,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- libavcodec/Makefile.orig Sun Jun 22 06:27:12 2003 ++++ libavcodec/Makefile Wed Jul 16 20:40:58 2003 +@@ -7,8 +7,8 @@ include ../config.mak + VPATH=$(SRC_PATH)/libavcodec + + # NOTE: -I.. is needed to include config.h +-CFLAGS= $(OPTFLAGS) -Wall -g -DHAVE_AV_CONFIG_H -I.. -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE +-LDFLAGS= -g ++CFLAGS= $(OPTFLAGS) -Wall -DHAVE_AV_CONFIG_H -I.. -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE ++#LDFLAGS= -g + + OBJS= common.o utils.o mem.o allcodecs.o \ + mpegvideo.o jrevdct.o jfdctfst.o jfdctint.o\ diff --git a/graphics/ffmpeg/patches/patch-libavcodec_alpha_dsputil_alpha_c b/graphics/ffmpeg/patches/patch-libavcodec_alpha_dsputil_alpha_c new file mode 100644 index 00000000000..37944b0ee3b --- /dev/null +++ b/graphics/ffmpeg/patches/patch-libavcodec_alpha_dsputil_alpha_c @@ -0,0 +1,18 @@ +$OpenBSD: patch-libavcodec_alpha_dsputil_alpha_c,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- libavcodec/alpha/dsputil_alpha.c.orig Sat Jul 19 02:28:29 2003 ++++ libavcodec/alpha/dsputil_alpha.c Sat Jul 19 02:30:39 2003 +@@ -20,6 +20,7 @@ + #include "asm.h" + #include "../dsputil.h" + ++extern void simple_idct_axp(DCTELEM *block); + extern void simple_idct_put_axp(uint8_t *dest, int line_size, DCTELEM *block); + extern void simple_idct_add_axp(uint8_t *dest, int line_size, DCTELEM *block); + +@@ -363,5 +364,5 @@ void dsputil_init_alpha(DSPContext* c, A + + c->idct_put = simple_idct_put_axp; + c->idct_add = simple_idct_add_axp; +- c->idct_idct = simple_idct_axp; ++ c->idct = simple_idct_axp; + } diff --git a/graphics/ffmpeg/patches/patch-libavcodec_alpha_simple_idct_alpha_c b/graphics/ffmpeg/patches/patch-libavcodec_alpha_simple_idct_alpha_c new file mode 100644 index 00000000000..aeb45d2bf95 --- /dev/null +++ b/graphics/ffmpeg/patches/patch-libavcodec_alpha_simple_idct_alpha_c @@ -0,0 +1,12 @@ +$OpenBSD: patch-libavcodec_alpha_simple_idct_alpha_c,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- libavcodec/alpha/simple_idct_alpha.c.orig Sat Jul 19 02:32:13 2003 ++++ libavcodec/alpha/simple_idct_alpha.c Sat Jul 19 02:34:42 2003 +@@ -27,6 +27,8 @@ + #include "asm.h" + #include "../dsputil.h" + ++typedef int32_t int_fast32_t; ++ + extern void (*put_pixels_clamped_axp_p)(const DCTELEM *block, uint8_t *pixels, + int line_size); + extern void (*add_pixels_clamped_axp_p)(const DCTELEM *block, uint8_t *pixels, diff --git a/graphics/ffmpeg/patches/patch-libavcodec_libpostproc_postprocess_c b/graphics/ffmpeg/patches/patch-libavcodec_libpostproc_postprocess_c new file mode 100644 index 00000000000..71535acb568 --- /dev/null +++ b/graphics/ffmpeg/patches/patch-libavcodec_libpostproc_postprocess_c @@ -0,0 +1,15 @@ +$OpenBSD: patch-libavcodec_libpostproc_postprocess_c,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- libavcodec/libpostproc/postprocess.c.orig Thu Jun 12 01:42:46 2003 ++++ libavcodec/libpostproc/postprocess.c Wed Jul 16 20:12:25 2003 +@@ -72,9 +72,9 @@ try to unroll inner for(x=0 ... loop to + #include + #include + #include +-#ifdef HAVE_MALLOC_H ++/*#ifdef HAVE_MALLOC_H + #include +-#endif ++#endif*/ + //#undef HAVE_MMX2 + //#define HAVE_3DNOW + //#undef HAVE_MMX diff --git a/graphics/ffmpeg/patches/patch-libavcodec_mem_c b/graphics/ffmpeg/patches/patch-libavcodec_mem_c new file mode 100644 index 00000000000..c26ede215c7 --- /dev/null +++ b/graphics/ffmpeg/patches/patch-libavcodec_mem_c @@ -0,0 +1,16 @@ +$OpenBSD: patch-libavcodec_mem_c,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- libavcodec/mem.c.orig Thu Mar 6 05:32:02 2003 ++++ libavcodec/mem.c Wed Jul 16 20:11:37 2003 +@@ -29,9 +29,10 @@ + #undef free + #undef realloc + +-#ifdef HAVE_MALLOC_H ++/*#ifdef HAVE_MALLOC_H + #include +-#endif ++#endif*/ ++#include + + /* you can redefine av_malloc and av_free in your project to use your + memory allocator. You do not need to suppress this file because the diff --git a/graphics/ffmpeg/patches/patch-libavformat_Makefile b/graphics/ffmpeg/patches/patch-libavformat_Makefile new file mode 100644 index 00000000000..100c734af62 --- /dev/null +++ b/graphics/ffmpeg/patches/patch-libavformat_Makefile @@ -0,0 +1,12 @@ +$OpenBSD: patch-libavformat_Makefile,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- libavformat/Makefile.orig Sun Jun 22 06:28:09 2003 ++++ libavformat/Makefile Wed Jul 16 20:45:11 2003 +@@ -6,7 +6,7 @@ include ../config.mak + + VPATH=$(SRC_PATH)/libavformat + +-CFLAGS= $(OPTFLAGS) -Wall -g -I.. -I$(SRC_PATH) -I$(SRC_PATH)/libavcodec -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE ++CFLAGS= $(OPTFLAGS) -Wall -I.. -I$(SRC_PATH) -I$(SRC_PATH)/libavcodec -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE + + OBJS= utils.o cutils.o allformats.o + PPOBJS= diff --git a/graphics/ffmpeg/patches/patch-libavformat_framehook_c b/graphics/ffmpeg/patches/patch-libavformat_framehook_c new file mode 100644 index 00000000000..7eb0448c4b2 --- /dev/null +++ b/graphics/ffmpeg/patches/patch-libavformat_framehook_c @@ -0,0 +1,11 @@ +$OpenBSD: patch-libavformat_framehook_c,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +--- libavformat/framehook.c.orig Tue Feb 11 10:35:28 2003 ++++ libavformat/framehook.c Thu Jul 3 20:53:48 2003 +@@ -25,6 +25,7 @@ + #include + #endif + ++#define RTLD_NOW 0 + + typedef struct _FrameHookEntry { + struct _FrameHookEntry *next; diff --git a/graphics/ffmpeg/pkg/DESCR b/graphics/ffmpeg/pkg/DESCR new file mode 100644 index 00000000000..f890b1873ef --- /dev/null +++ b/graphics/ffmpeg/pkg/DESCR @@ -0,0 +1,2 @@ +FFmpeg is a complete solution to record, convert and stream audio and +video. It includes libavcodec, the leading audio/video codec library. diff --git a/graphics/ffmpeg/pkg/PFRAG.shared b/graphics/ffmpeg/pkg/PFRAG.shared new file mode 100644 index 00000000000..e2ca78b449f --- /dev/null +++ b/graphics/ffmpeg/pkg/PFRAG.shared @@ -0,0 +1,3 @@ +@comment $OpenBSD: PFRAG.shared,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +lib/libavcodec.so.0.0 +DYNLIBDIR(%D/lib) diff --git a/graphics/ffmpeg/pkg/PLIST b/graphics/ffmpeg/pkg/PLIST new file mode 100644 index 00000000000..8bf841258e1 --- /dev/null +++ b/graphics/ffmpeg/pkg/PLIST @@ -0,0 +1,9 @@ +@comment $OpenBSD: PLIST,v 1.1.1.1 2003/07/19 18:16:34 jolan Exp $ +include/ffmpeg/avcodec.h +include/ffmpeg/common.h +include/postproc/postprocess.h +lib/libavcodec.a +lib/libavformat.a +%%SHARED%% +@dirrm include/postproc +@dirrm include/ffmpeg