[FFmpeg-devel] Add libtwolame cppflags in 'configure' to prevent the use of '--extra-cflags'

Submitted by Reino Wijnsma on June 12, 2017, 11:41 p.m.

Details

Message ID 593F2693.4040805@xs4all.nl
State New
Headers show

Commit Message

Reino Wijnsma June 12, 2017, 11:41 p.m.
This patch adds libtwolame cppflags in 'configure' to prevent the use of
'--extra-cflags'. This is all that's needed to successfully
cross-compile FFmpeg with LibTwoLAME.
From 9aacc77f0dcb67d375fd3bdf4d0a1dc8d55b1cf7 Mon Sep 17 00:00:00 2001
From: Reino17 <rwijnsma@xs4all.nl>
Date: Tue, 13 Jun 2017 01:10:53 +0200
Subject: [PATCH] Add libtwolame cppflags in 'configure' to prevent the use of
 '--extra-cflags'

---
 configure | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Hendrik Leppkes June 12, 2017, 11:49 p.m.
On Tue, Jun 13, 2017 at 1:41 AM, Reino Wijnsma <rwijnsma@xs4all.nl> wrote:
> This patch adds libtwolame cppflags in 'configure' to prevent the use of
> '--extra-cflags'. This is all that's needed to successfully
> cross-compile FFmpeg with LibTwoLAME.
>

And what happens if someone were to actually compile with a shared
TwoLAME, instead of a static one?
The same can be asked about the other patches doing the same thing.

- Hendrik

Patch hide | download patch | download mbox

diff --git a/configure b/configure
index e3941f9..e2c0cb9 100755
--- a/configure
+++ b/configure
@@ -5859,7 +5859,7 @@  enabled libssh            && require_pkg_config libssh libssh/sftp.h sftp_init
 enabled libspeex          && require_pkg_config speex speex/speex.h speex_decoder_init -lspeex
 enabled libtesseract      && require_pkg_config tesseract tesseract/capi.h TessBaseAPICreate
 enabled libtheora         && require libtheora theora/theoraenc.h th_info_init -ltheoraenc -ltheoradec -logg
-enabled libtwolame        && require libtwolame twolame.h twolame_init -ltwolame &&
+enabled libtwolame        && require libtwolame twolame.h twolame_init -ltwolame -DLIBTWOLAME_STATIC && add_cppflags -DLIBTWOLAME_STATIC &&
                              { check_lib libtwolame twolame.h twolame_encode_buffer_float32_interleaved -ltwolame ||
                                die "ERROR: libtwolame must be installed and version must be >= 0.3.10"; }
 enabled libv4l2           && require_pkg_config libv4l2 libv4l2.h v4l2_ioctl