FFmpeg build/packaging tweaks from Brad:

- Stop using --disable-optimization to have the port obey the CFLAGS
  but instead modify the configure script appropriately
- Move most of the DESCR into the pkg-readme
- Remove unnecessary CPPFLAGS that was being added to CONFIGURE_ENV
This commit is contained in:
sthen 2011-09-04 09:22:43 +00:00
parent 312cba7ce7
commit c1291ffb7e
5 changed files with 42 additions and 37 deletions

View File

@ -1,11 +1,11 @@
# $OpenBSD: Makefile,v 1.80 2011/08/28 11:17:48 sthen Exp $
# $OpenBSD: Makefile,v 1.81 2011/09/04 09:22:43 sthen Exp $
COMMENT= audio/video converter and streamer
V= 20110408
DISTNAME= ffmpeg-git-${V}
PKGNAME= ffmpeg-${V}
REVISION= 8
REVISION= 9
CATEGORIES= graphics multimedia
MASTER_SITES= http://comstyle.com/source/
@ -80,7 +80,6 @@ CONFIGURE_ARGS+= ${CONFIGURE_SHARED} \
--disable-indev=oss \
--disable-iwmmxt \
--disable-neon \
--disable-optimizations \
--disable-outdev=oss \
--enable-gpl \
--enable-libgsm \
@ -105,8 +104,7 @@ CONFIGURE_ENV+= LIBavcodec_EXTRALIBS="${LIBavcodec_EXTRALIBS}" \
LIBavutil_EXTRALIBS="${LIBavutil_EXTRALIBS}" \
LIBpostproc_EXTRALIBS="${LIBpostproc_EXTRALIBS}" \
LIBswscale_EXTRALIBS="${LIBswscale_EXTRALIBS}" \
TMPDIR=${WRKTMP} \
CPPFLAGS="-I${X11BASE}/include"
TMPDIR=${WRKTMP}
VERSION_FLAGS= libavcodec_VERSION=${LIBavcodec_VERSION} \
libavdevice_VERSION=${LIBavdevice_VERSION} \

View File

@ -1,6 +1,6 @@
$OpenBSD: patch-configure,v 1.26 2011/04/12 22:59:07 sthen Exp $
$OpenBSD: patch-configure,v 1.27 2011/09/04 09:22:43 sthen Exp $
--- configure.orig Wed Apr 6 17:29:22 2011
+++ configure Fri Apr 8 16:46:29 2011
+++ configure Wed Aug 24 20:28:01 2011
@@ -1087,7 +1087,6 @@ HAVE_LIST="
lzo1x_999_compress
machine_ioctl_bt848_h
@ -44,25 +44,26 @@ $OpenBSD: patch-configure,v 1.26 2011/04/12 22:59:07 sthen Exp $
enabled libmp3lame && require "libmp3lame >= 3.98.3" lame/lame.h lame_set_VBR_quality -lmp3lame
enabled libnut && require libnut libnut.h nut_demuxer_init -lnut
enabled libopencore_amrnb && require libopencore_amrnb opencore-amrnb/interf_dec.h Decoder_Interface_init -lopencore-amrnb
@@ -2997,8 +2995,6 @@ enabled extra_warnings && check_cflags -Winline
@@ -2997,7 +2995,6 @@ enabled extra_warnings && check_cflags -Winline
# add some linker flags
check_ldflags -Wl,--warn-common
-check_ldflags '-Wl,-rpath-link,\$(BUILD_ROOT)/libpostproc -Wl,-rpath-link,\$(BUILD_ROOT)/libswscale -Wl,-rpath-link,\$(BUILD_ROOT)/libavfilter -Wl,-rpath-link,\$(BUILD_ROOT)/libavdevice -Wl,-rpath-link,\$(BUILD_ROOT)/libavformat -Wl,-rpath-link,\$(BUILD_ROOT)/libavcodec -Wl,-rpath-link,\$(BUILD_ROOT)/libavutil'
-test_ldflags -Wl,-Bsymbolic && append SHFLAGS -Wl,-Bsymbolic
test_ldflags -Wl,-Bsymbolic && append SHFLAGS -Wl,-Bsymbolic
echo "X{};" > $TMPV
if test_ldflags -Wl,--version-script,$TMPV; then
@@ -3355,7 +3351,7 @@ EOF
test -n "$malloc_prefix" &&
echo "#define MALLOC_PREFIX $malloc_prefix" >>$TMPH
-if enabled small || disabled optimizations; then
+if enabled small; then
echo "#undef av_always_inline" >> $TMPH
if enabled small; then
echo "#define av_always_inline inline" >> $TMPH
@@ -3438,8 +3434,7 @@ Version: $version
@@ -3016,10 +3013,6 @@ fi
if enabled small; then
add_cflags $size_cflags
optimizations="small"
-elif enabled optimizations; then
- add_cflags $speed_cflags
-else
- add_cflags $noopt_cflags
fi
check_cflags -fno-math-errno
check_cflags -fno-signed-zeros
@@ -3438,8 +3431,7 @@ Version: $version
Requires: $(enabled shared || echo $requires)
Requires.private: $(enabled shared && echo $requires)
Conflicts:
@ -72,7 +73,7 @@ $OpenBSD: patch-configure,v 1.26 2011/04/12 22:59:07 sthen Exp $
Cflags: -I\${includedir}
EOF
cat <<EOF > $name/$name-uninstalled.pc
@@ -3458,10 +3453,10 @@ Cflags: -I\${includedir}
@@ -3458,10 +3450,10 @@ Cflags: -I\${includedir}
EOF
}

View File

@ -1,17 +1,2 @@
FFmpeg is a complete solution to record, convert and stream audio and
video. It includes libavcodec, the leading audio/video codec library.
bktr(4) support (amd64/i386/powerpc only) may be controlled through the
following environment variables:
BKTR_DEV={0|1|2|3|4}: Selects device input (tuner, camera, ...)
BKTR_FORMAT={1|2|3|4|5|6}:
1 PAL
2 NTSC
3 SECAM
4 PALN
5 PALM
6 NTSCJ
BKTR_FREQUENCY=xxx.yy: Sets frequency in MHz

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST,v 1.19 2011/04/12 22:59:07 sthen Exp $
@comment $OpenBSD: PLIST,v 1.20 2011/09/04 09:22:43 sthen Exp $
%%SHARED%%
@bin bin/ffmpeg
@bin bin/ffplay
@ -91,6 +91,7 @@ share/doc/ffmpeg/ffprobe.html
share/doc/ffmpeg/ffserver.html
share/doc/ffmpeg/general.html
share/doc/ffmpeg/libavfilter.html
share/doc/pkg-readmes/${FULLPKGNAME}
share/examples/ffmpeg/
share/examples/ffmpeg/ffserver.conf
share/ffmpeg/

View File

@ -0,0 +1,20 @@
$OpenBSD: README,v 1.1 2011/09/04 09:22:43 sthen Exp $
+-----------------------------------------------------------------------
| Running ${FULLPKGNAME} on OpenBSD
+-----------------------------------------------------------------------
bktr(4) support (amd64/i386/powerpc only) may be controlled through the
following environment variables:
BKTR_DEV={0|1|2|3|4}: Selects device input (tuner, camera, ...)
BKTR_FORMAT={1|2|3|4|5|6}:
1 PAL
2 NTSC
3 SECAM
4 PALN
5 PALM
6 NTSCJ
BKTR_FREQUENCY=xxx.yy: Sets frequency in MHz