Add a cross-compile condition to AC_RUN_IFELSE in AC_AGI_COMPILE to make cross-compiling work.

Originally committed to SVN as r2836.
This commit is contained in:
Amar Takhar 2009-04-21 22:32:07 +00:00
parent 09d32d8151
commit 71c29969a3
1 changed files with 6 additions and 1 deletions

View File

@ -7,7 +7,12 @@ AC_DEFUN([AC_AGI_COMPILE],[
[whether $1 works], [agi_cv_with_$2],
[AC_RUN_IFELSE([$5],
[eval agi_cv_with_$2="yes"],
[eval agi_cv_with_$2="no"])
[eval agi_cv_with_$2="no"],
[if test $? -ne 0; then
eval agi_cv_with_$2="no";
else
eval agi_cv_with_$2="yes";
fi])
])
CPPFLAGS="$aegisub_save_CPPFLAGS"
LDFLAGS="$aegisub_save_LDFLAGS"