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 e2d0317df3
commit ff7ee2e776

View file

@ -7,7 +7,12 @@ AC_DEFUN([AC_AGI_COMPILE],[
[whether $1 works], [agi_cv_with_$2], [whether $1 works], [agi_cv_with_$2],
[AC_RUN_IFELSE([$5], [AC_RUN_IFELSE([$5],
[eval agi_cv_with_$2="yes"], [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" CPPFLAGS="$aegisub_save_CPPFLAGS"
LDFLAGS="$aegisub_save_LDFLAGS" LDFLAGS="$aegisub_save_LDFLAGS"