diff mbox

[FFmpeg-devel,1/7] build: fix objcc header check

Message ID 20170906095806.3070-1-u@pkh.me
State New
Headers show

Commit Message

Clément Bœsch Sept. 6, 2017, 9:58 a.m. UTC
From: Clément Bœsch <cboesch@gopro.com>

$headers is a variable set in the context of other functions (we don't
use the "local" keyword in our scripts, so those variables are global).

Currently, when checking for AVFoundation/AVFoundation.h, the actual
enabled header is math.h.

Similarly, when testing for QuartzCore/CoreImage.h, the actual enabled
header is CoreGraphics/CoreGraphics.h.

This is completely broken and may be the reason why these checks are
made in random places.
---
 configure | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Thilo Borgmann Sept. 6, 2017, 8:05 p.m. UTC | #1
Hi,

Am 06.09.17 um 11:58 schrieb Clément Bœsch:
> From: Clément Bœsch <cboesch@gopro.com>
> 
> $headers is a variable set in the context of other functions (we don't
> use the "local" keyword in our scripts, so those variables are global).
> 
> Currently, when checking for AVFoundation/AVFoundation.h, the actual
> enabled header is math.h.
> 
> Similarly, when testing for QuartzCore/CoreImage.h, the actual enabled
> header is CoreGraphics/CoreGraphics.h.
> 
> This is completely broken and may be the reason why these checks are
> made in random places.

thus it was just a typo like the patch 1 suggested?

Patch 1-5 ok!
For patch 6-7 maybe someone else can have a closer look.

Thanks!
-Thilo
Clément Bœsch Sept. 7, 2017, 2:07 p.m. UTC | #2
On Wed, Sep 06, 2017 at 10:05:40PM +0200, Thilo Borgmann wrote:
> Hi,
> 
> Am 06.09.17 um 11:58 schrieb Clément Bœsch:
> > From: Clément Bœsch <cboesch@gopro.com>
> > 
> > $headers is a variable set in the context of other functions (we don't
> > use the "local" keyword in our scripts, so those variables are global).
> > 
> > Currently, when checking for AVFoundation/AVFoundation.h, the actual
> > enabled header is math.h.
> > 
> > Similarly, when testing for QuartzCore/CoreImage.h, the actual enabled
> > header is CoreGraphics/CoreGraphics.h.
> > 
> > This is completely broken and may be the reason why these checks are
> > made in random places.
> 
> thus it was just a typo like the patch 1 suggested?
> 

What do you mean by "like the patch 1 suggested"? This is the patch 1.
And yeah, I guess it's a typo from day 1 (a2c6a99ba5). I didn't check if
the code was valid back then thanks to a side effect (basically if
check_cc was setting headers=$1 somewhere), but it's definitely broken
currently.

> Patch 1-5 ok!
> For patch 6-7 maybe someone else can have a closer look.

I'll wait a little more and push the patchset.

Thanks
Clément Bœsch Sept. 8, 2017, 4:59 p.m. UTC | #3
On Thu, Sep 07, 2017 at 04:07:41PM +0200, Clément Bœsch wrote:
[...]
> > Patch 1-5 ok!
> > For patch 6-7 maybe someone else can have a closer look.
> 
> I'll wait a little more and push the patchset.
> 

Patchset applied, thanks
diff mbox

Patch

diff --git a/configure b/configure
index 2f3fa2ba3d..54fe846fea 100755
--- a/configure
+++ b/configure
@@ -1117,7 +1117,7 @@  check_header_objcc(){
     {
        echo "#include <$header>"
        echo "int main(void) { return 0; }"
-    } | check_objcc && check_stat "$TMPO" && enable_safe $headers
+    } | check_objcc && check_stat "$TMPO" && enable_safe $header
 }
 
 check_func(){