Re: [libav-devel] [PATCH] configure: Simplify and fix avfoundation indev handling

2016-12-05 Thread Diego Biurrun
On Thu, Dec 01, 2016 at 03:34:48PM +0100, Diego Biurrun wrote:
> Handle extralibs in the standard way, add missing pthreads dependency.
> Also globally check for -fobj-arc with Objective-C compilers since
> that option is useful for other Objective-C code as well.
> ---
> 
> Needs some testing on OS X.

Testing and OKed by Vito on IRC.

Diego
___
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel


[libav-devel] [PATCH] configure: Simplify and fix avfoundation indev handling

2016-12-01 Thread Diego Biurrun
Handle extralibs in the standard way, add missing pthreads dependency.
Also globally check for -fobj-arc with Objective-C compilers since
that option is useful for other Objective-C code as well.
---

Needs some testing on OS X.

 configure | 10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/configure b/configure
index 4cdb239..6e29aae 100755
--- a/configure
+++ b/configure
@@ -2362,7 +2362,8 @@ xwma_demuxer_select="riffdec"
 # indevs / outdevs
 alsa_indev_deps="alsa_asoundlib_h snd_pcm_htimestamp"
 alsa_outdev_deps="alsa_asoundlib_h"
-avfoundation_indev_deps="AVFoundation_AVFoundation_h"
+avfoundation_indev_deps="AVFoundation_AVFoundation_h objc_arc pthreads"
+avfoundation_indev_extralibs="-framework Foundation -framework AVFoundation 
-framework CoreVideo -framework CoreMedia"
 bktr_indev_deps_any="dev_bktr_ioctl_bt848_h machine_ioctl_bt848_h 
dev_video_bktr_ioctl_bt848_h dev_ic_bt8xx_h"
 dv1394_indev_deps="dv1394"
 dv1394_indev_select="dv_demuxer"
@@ -4722,10 +4723,7 @@ check_header linux/fb.h
 check_header linux/videodev2.h
 check_struct linux/videodev2.h "struct v4l2_frmivalenum" discrete
 
-check_header AVFoundation/AVFoundation.h &&
-check_objcflags -fobjc-arc &&
-add_extralibs -framework Foundation -framework AVFoundation -framework 
CoreVideo -framework CoreMedia ||
-disable AVFoundation_AVFoundation_h
+check_header AVFoundation/AVFoundation.h
 
 check_header sys/videoio.h
 
@@ -4828,6 +4826,8 @@ check_disable_warning -Wno-switch
 check_disable_warning -Wno-format-zero-length
 check_disable_warning -Wno-pointer-sign
 
+check_objcflags -fobjc-arc && enable objc_arc
+
 # add some linker flags
 check_ldflags -Wl,--warn-common
 check_ldflags 
-Wl,-rpath-link=libswscale:libavfilter:libavdevice:libavformat:libavcodec:libavutil:libavresample
-- 
2.1.4

___
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel