aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-04-21 13:56:06 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-04-21 13:56:06 +0200
commitfa29e89d41658557860ff790570fe68b3c464bd3 (patch)
tree6307e9187edab927447616470a1d6eaf0998f474
parentf6cb3827dfb86db876f8b5bbdbb26e95bcbbbaa5 (diff)
parenta32e45df82751784f9461f01310e63f4bed721dc (diff)
downloadffmpeg-fa29e89d41658557860ff790570fe68b3c464bd3.tar.gz
Merge commit 'a32e45df82751784f9461f01310e63f4bed721dc' into release/1.1
* commit 'a32e45df82751784f9461f01310e63f4bed721dc': configure: Support preprocessor macros as header names Merged-by: Michael Niedermayer <michaelni@gmx.at>
-rwxr-xr-xconfigure11
1 files changed, 9 insertions, 2 deletions
diff --git a/configure b/configure
index d4635a4ae6..d8120659ff 100755
--- a/configure
+++ b/configure
@@ -797,6 +797,13 @@ check_ld(){
check_cmd $ld $LDFLAGS $flags $(ld_o $TMPE) $TMPO $libs $extralibs
}
+print_include(){
+ hdr=$1
+ test "${hdr%.h}" = "${hdr}" &&
+ echo "#include $hdr" ||
+ echo "#include <$hdr>"
+}
+
check_code(){
log check_code "$@"
check=$1
@@ -805,7 +812,7 @@ check_code(){
shift 3
{
for hdr in $headers; do
- echo "#include <$hdr>"
+ print_include $hdr
done
echo "int main(void) { $code; return 0; }"
} | check_$check "$@"
@@ -889,7 +896,7 @@ check_func_headers(){
shift 2
{
for hdr in $headers; do
- echo "#include <$hdr>"
+ print_include $hdr
done
for func in $funcs; do
echo "long check_$func(void) { return (long) $func; }"