Path: blob/main/astro/celestia/files/celestia-1.6.1-lua-5.2.patch
16462 views
diff -Naur celestia-1.6.1.orig/configure celestia-1.6.1/configure1--- celestia-1.6.1.orig/configure 2011-06-05 20:33:27.000000000 +02002+++ celestia-1.6.1/configure 2013-08-22 06:31:25.124482730 +02003@@ -28444,6 +28444,3350 @@4pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"5elif test -n "$PKG_CONFIG"; then6if test -n "$PKG_CONFIG" && \7+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.2 >= 5.2.0\""; } >&58+ ($PKG_CONFIG --exists --print-errors "lua5.2 >= 5.2.0") 2>&59+ ac_status=$?10+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&511+ test $ac_status = 0; }; then12+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua5.2 >= 5.2.0" 2>/dev/null`13+else14+ pkg_failed=yes15+fi16+ else17+ pkg_failed=untried18+fi19+if test -n "$LUA_LIBS"; then20+ pkg_cv_LUA_LIBS="$LUA_LIBS"21+ elif test -n "$PKG_CONFIG"; then22+ if test -n "$PKG_CONFIG" && \23+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.2 >= 5.2.0\""; } >&524+ ($PKG_CONFIG --exists --print-errors "lua5.2 >= 5.2.0") 2>&525+ ac_status=$?26+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&527+ test $ac_status = 0; }; then28+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua5.2 >= 5.2.0" 2>/dev/null`29+else30+ pkg_failed=yes31+fi32+ else33+ pkg_failed=untried34+fi35+36+37+38+if test $pkg_failed = yes; then39+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&540+$as_echo "no" >&6; }41+42+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then43+ _pkg_short_errors_supported=yes44+else45+ _pkg_short_errors_supported=no46+fi47+ if test $_pkg_short_errors_supported = yes; then48+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua5.2 >= 5.2.0" 2>&1`49+ else50+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua5.2 >= 5.2.0" 2>&1`51+ fi52+ # Put the nasty error message in config.log where it belongs53+ echo "$LUA_PKG_ERRORS" >&554+55+56+pkg_failed=no57+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&558+$as_echo_n "checking for LUA... " >&6; }59+60+if test -n "$LUA_CFLAGS"; then61+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"62+ elif test -n "$PKG_CONFIG"; then63+ if test -n "$PKG_CONFIG" && \64+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.2.0\""; } >&565+ ($PKG_CONFIG --exists --print-errors "lua >= 5.2.0") 2>&566+ ac_status=$?67+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&568+ test $ac_status = 0; }; then69+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.2.0" 2>/dev/null`70+else71+ pkg_failed=yes72+fi73+ else74+ pkg_failed=untried75+fi76+if test -n "$LUA_LIBS"; then77+ pkg_cv_LUA_LIBS="$LUA_LIBS"78+ elif test -n "$PKG_CONFIG"; then79+ if test -n "$PKG_CONFIG" && \80+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.2.0\""; } >&581+ ($PKG_CONFIG --exists --print-errors "lua >= 5.2.0") 2>&582+ ac_status=$?83+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&584+ test $ac_status = 0; }; then85+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.2.0" 2>/dev/null`86+else87+ pkg_failed=yes88+fi89+ else90+ pkg_failed=untried91+fi92+93+94+95+if test $pkg_failed = yes; then96+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&597+$as_echo "no" >&6; }98+99+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then100+ _pkg_short_errors_supported=yes101+else102+ _pkg_short_errors_supported=no103+fi104+ if test $_pkg_short_errors_supported = yes; then105+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.2.0" 2>&1`106+ else107+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.2.0" 2>&1`108+ fi109+ # Put the nasty error message in config.log where it belongs110+ echo "$LUA_PKG_ERRORS" >&5111+112+113+pkg_failed=no114+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5115+$as_echo_n "checking for LUA... " >&6; }116+117+if test -n "$LUA_CFLAGS"; then118+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"119+ elif test -n "$PKG_CONFIG"; then120+ if test -n "$PKG_CONFIG" && \121+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1.0\""; } >&5122+ ($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1.0") 2>&5123+ ac_status=$?124+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5125+ test $ac_status = 0; }; then126+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua5.1 >= 5.1.0" 2>/dev/null`127+else128+ pkg_failed=yes129+fi130+ else131+ pkg_failed=untried132+fi133+if test -n "$LUA_LIBS"; then134+ pkg_cv_LUA_LIBS="$LUA_LIBS"135+ elif test -n "$PKG_CONFIG"; then136+ if test -n "$PKG_CONFIG" && \137+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1.0\""; } >&5138+ ($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1.0") 2>&5139+ ac_status=$?140+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5141+ test $ac_status = 0; }; then142+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua5.1 >= 5.1.0" 2>/dev/null`143+else144+ pkg_failed=yes145+fi146+ else147+ pkg_failed=untried148+fi149+150+151+152+if test $pkg_failed = yes; then153+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5154+$as_echo "no" >&6; }155+156+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then157+ _pkg_short_errors_supported=yes158+else159+ _pkg_short_errors_supported=no160+fi161+ if test $_pkg_short_errors_supported = yes; then162+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua5.1 >= 5.1.0" 2>&1`163+ else164+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua5.1 >= 5.1.0" 2>&1`165+ fi166+ # Put the nasty error message in config.log where it belongs167+ echo "$LUA_PKG_ERRORS" >&5168+169+170+pkg_failed=no171+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5172+$as_echo_n "checking for LUA... " >&6; }173+174+if test -n "$LUA_CFLAGS"; then175+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"176+ elif test -n "$PKG_CONFIG"; then177+ if test -n "$PKG_CONFIG" && \178+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&5179+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&5180+ ac_status=$?181+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5182+ test $ac_status = 0; }; then183+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.1.0" 2>/dev/null`184+else185+ pkg_failed=yes186+fi187+ else188+ pkg_failed=untried189+fi190+if test -n "$LUA_LIBS"; then191+ pkg_cv_LUA_LIBS="$LUA_LIBS"192+ elif test -n "$PKG_CONFIG"; then193+ if test -n "$PKG_CONFIG" && \194+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&5195+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&5196+ ac_status=$?197+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5198+ test $ac_status = 0; }; then199+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.1.0" 2>/dev/null`200+else201+ pkg_failed=yes202+fi203+ else204+ pkg_failed=untried205+fi206+207+208+209+if test $pkg_failed = yes; then210+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5211+$as_echo "no" >&6; }212+213+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then214+ _pkg_short_errors_supported=yes215+else216+ _pkg_short_errors_supported=no217+fi218+ if test $_pkg_short_errors_supported = yes; then219+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.1.0" 2>&1`220+ else221+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.1.0" 2>&1`222+ fi223+ # Put the nasty error message in config.log where it belongs224+ echo "$LUA_PKG_ERRORS" >&5225+226+227+pkg_failed=no228+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5229+$as_echo_n "checking for LUA... " >&6; }230+231+if test -n "$LUA_CFLAGS"; then232+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"233+ elif test -n "$PKG_CONFIG"; then234+ if test -n "$PKG_CONFIG" && \235+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&5236+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&5237+ ac_status=$?238+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5239+ test $ac_status = 0; }; then240+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`241+else242+ pkg_failed=yes243+fi244+ else245+ pkg_failed=untried246+fi247+if test -n "$LUA_LIBS"; then248+ pkg_cv_LUA_LIBS="$LUA_LIBS"249+ elif test -n "$PKG_CONFIG"; then250+ if test -n "$PKG_CONFIG" && \251+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&5252+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&5253+ ac_status=$?254+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5255+ test $ac_status = 0; }; then256+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`257+else258+ pkg_failed=yes259+fi260+ else261+ pkg_failed=untried262+fi263+264+265+266+if test $pkg_failed = yes; then267+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5268+$as_echo "no" >&6; }269+270+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then271+ _pkg_short_errors_supported=yes272+else273+ _pkg_short_errors_supported=no274+fi275+ if test $_pkg_short_errors_supported = yes; then276+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`277+ else278+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`279+ fi280+ # Put the nasty error message in config.log where it belongs281+ echo "$LUA_PKG_ERRORS" >&5282+283+284+pkg_failed=no285+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5286+$as_echo_n "checking for LUA... " >&6; }287+288+if test -n "$LUA_CFLAGS"; then289+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"290+ elif test -n "$PKG_CONFIG"; then291+ if test -n "$PKG_CONFIG" && \292+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5293+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5294+ ac_status=$?295+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5296+ test $ac_status = 0; }; then297+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`298+else299+ pkg_failed=yes300+fi301+ else302+ pkg_failed=untried303+fi304+if test -n "$LUA_LIBS"; then305+ pkg_cv_LUA_LIBS="$LUA_LIBS"306+ elif test -n "$PKG_CONFIG"; then307+ if test -n "$PKG_CONFIG" && \308+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5309+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5310+ ac_status=$?311+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5312+ test $ac_status = 0; }; then313+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`314+else315+ pkg_failed=yes316+fi317+ else318+ pkg_failed=untried319+fi320+321+322+323+if test $pkg_failed = yes; then324+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5325+$as_echo "no" >&6; }326+327+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then328+ _pkg_short_errors_supported=yes329+else330+ _pkg_short_errors_supported=no331+fi332+ if test $_pkg_short_errors_supported = yes; then333+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`334+ else335+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`336+ fi337+ # Put the nasty error message in config.log where it belongs338+ echo "$LUA_PKG_ERRORS" >&5339+340+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5341+$as_echo "no" >&6; }342+elif test $pkg_failed = untried; then343+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5344+$as_echo "no" >&6; }345+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5346+$as_echo "no" >&6; }347+else348+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS349+ LUA_LIBS=$pkg_cv_LUA_LIBS350+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5351+$as_echo "yes" >&6; }352+ LUA_VER=0x050000353+fi354+355+elif test $pkg_failed = untried; then356+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5357+$as_echo "no" >&6; }358+359+pkg_failed=no360+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5361+$as_echo_n "checking for LUA... " >&6; }362+363+if test -n "$LUA_CFLAGS"; then364+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"365+ elif test -n "$PKG_CONFIG"; then366+ if test -n "$PKG_CONFIG" && \367+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5368+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5369+ ac_status=$?370+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5371+ test $ac_status = 0; }; then372+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`373+else374+ pkg_failed=yes375+fi376+ else377+ pkg_failed=untried378+fi379+if test -n "$LUA_LIBS"; then380+ pkg_cv_LUA_LIBS="$LUA_LIBS"381+ elif test -n "$PKG_CONFIG"; then382+ if test -n "$PKG_CONFIG" && \383+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5384+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5385+ ac_status=$?386+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5387+ test $ac_status = 0; }; then388+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`389+else390+ pkg_failed=yes391+fi392+ else393+ pkg_failed=untried394+fi395+396+397+398+if test $pkg_failed = yes; then399+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5400+$as_echo "no" >&6; }401+402+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then403+ _pkg_short_errors_supported=yes404+else405+ _pkg_short_errors_supported=no406+fi407+ if test $_pkg_short_errors_supported = yes; then408+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`409+ else410+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`411+ fi412+ # Put the nasty error message in config.log where it belongs413+ echo "$LUA_PKG_ERRORS" >&5414+415+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5416+$as_echo "no" >&6; }417+elif test $pkg_failed = untried; then418+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5419+$as_echo "no" >&6; }420+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5421+$as_echo "no" >&6; }422+else423+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS424+ LUA_LIBS=$pkg_cv_LUA_LIBS425+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5426+$as_echo "yes" >&6; }427+ LUA_VER=0x050000428+fi429+430+else431+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS432+ LUA_LIBS=$pkg_cv_LUA_LIBS433+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5434+$as_echo "yes" >&6; }435+ LUA_VER=0x050000436+fi437+438+elif test $pkg_failed = untried; then439+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5440+$as_echo "no" >&6; }441+442+pkg_failed=no443+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5444+$as_echo_n "checking for LUA... " >&6; }445+446+if test -n "$LUA_CFLAGS"; then447+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"448+ elif test -n "$PKG_CONFIG"; then449+ if test -n "$PKG_CONFIG" && \450+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&5451+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&5452+ ac_status=$?453+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5454+ test $ac_status = 0; }; then455+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`456+else457+ pkg_failed=yes458+fi459+ else460+ pkg_failed=untried461+fi462+if test -n "$LUA_LIBS"; then463+ pkg_cv_LUA_LIBS="$LUA_LIBS"464+ elif test -n "$PKG_CONFIG"; then465+ if test -n "$PKG_CONFIG" && \466+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&5467+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&5468+ ac_status=$?469+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5470+ test $ac_status = 0; }; then471+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`472+else473+ pkg_failed=yes474+fi475+ else476+ pkg_failed=untried477+fi478+479+480+481+if test $pkg_failed = yes; then482+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5483+$as_echo "no" >&6; }484+485+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then486+ _pkg_short_errors_supported=yes487+else488+ _pkg_short_errors_supported=no489+fi490+ if test $_pkg_short_errors_supported = yes; then491+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`492+ else493+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`494+ fi495+ # Put the nasty error message in config.log where it belongs496+ echo "$LUA_PKG_ERRORS" >&5497+498+499+pkg_failed=no500+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5501+$as_echo_n "checking for LUA... " >&6; }502+503+if test -n "$LUA_CFLAGS"; then504+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"505+ elif test -n "$PKG_CONFIG"; then506+ if test -n "$PKG_CONFIG" && \507+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5508+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5509+ ac_status=$?510+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5511+ test $ac_status = 0; }; then512+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`513+else514+ pkg_failed=yes515+fi516+ else517+ pkg_failed=untried518+fi519+if test -n "$LUA_LIBS"; then520+ pkg_cv_LUA_LIBS="$LUA_LIBS"521+ elif test -n "$PKG_CONFIG"; then522+ if test -n "$PKG_CONFIG" && \523+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5524+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5525+ ac_status=$?526+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5527+ test $ac_status = 0; }; then528+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`529+else530+ pkg_failed=yes531+fi532+ else533+ pkg_failed=untried534+fi535+536+537+538+if test $pkg_failed = yes; then539+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5540+$as_echo "no" >&6; }541+542+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then543+ _pkg_short_errors_supported=yes544+else545+ _pkg_short_errors_supported=no546+fi547+ if test $_pkg_short_errors_supported = yes; then548+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`549+ else550+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`551+ fi552+ # Put the nasty error message in config.log where it belongs553+ echo "$LUA_PKG_ERRORS" >&5554+555+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5556+$as_echo "no" >&6; }557+elif test $pkg_failed = untried; then558+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5559+$as_echo "no" >&6; }560+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5561+$as_echo "no" >&6; }562+else563+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS564+ LUA_LIBS=$pkg_cv_LUA_LIBS565+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5566+$as_echo "yes" >&6; }567+ LUA_VER=0x050000568+fi569+570+elif test $pkg_failed = untried; then571+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5572+$as_echo "no" >&6; }573+574+pkg_failed=no575+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5576+$as_echo_n "checking for LUA... " >&6; }577+578+if test -n "$LUA_CFLAGS"; then579+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"580+ elif test -n "$PKG_CONFIG"; then581+ if test -n "$PKG_CONFIG" && \582+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5583+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5584+ ac_status=$?585+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5586+ test $ac_status = 0; }; then587+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`588+else589+ pkg_failed=yes590+fi591+ else592+ pkg_failed=untried593+fi594+if test -n "$LUA_LIBS"; then595+ pkg_cv_LUA_LIBS="$LUA_LIBS"596+ elif test -n "$PKG_CONFIG"; then597+ if test -n "$PKG_CONFIG" && \598+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5599+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5600+ ac_status=$?601+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5602+ test $ac_status = 0; }; then603+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`604+else605+ pkg_failed=yes606+fi607+ else608+ pkg_failed=untried609+fi610+611+612+613+if test $pkg_failed = yes; then614+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5615+$as_echo "no" >&6; }616+617+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then618+ _pkg_short_errors_supported=yes619+else620+ _pkg_short_errors_supported=no621+fi622+ if test $_pkg_short_errors_supported = yes; then623+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`624+ else625+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`626+ fi627+ # Put the nasty error message in config.log where it belongs628+ echo "$LUA_PKG_ERRORS" >&5629+630+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5631+$as_echo "no" >&6; }632+elif test $pkg_failed = untried; then633+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5634+$as_echo "no" >&6; }635+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5636+$as_echo "no" >&6; }637+else638+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS639+ LUA_LIBS=$pkg_cv_LUA_LIBS640+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5641+$as_echo "yes" >&6; }642+ LUA_VER=0x050000643+fi644+645+else646+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS647+ LUA_LIBS=$pkg_cv_LUA_LIBS648+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5649+$as_echo "yes" >&6; }650+ LUA_VER=0x050000651+fi652+653+else654+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS655+ LUA_LIBS=$pkg_cv_LUA_LIBS656+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5657+$as_echo "yes" >&6; }658+ LUA_VER=0x050100659+fi660+661+elif test $pkg_failed = untried; then662+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5663+$as_echo "no" >&6; }664+665+pkg_failed=no666+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5667+$as_echo_n "checking for LUA... " >&6; }668+669+if test -n "$LUA_CFLAGS"; then670+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"671+ elif test -n "$PKG_CONFIG"; then672+ if test -n "$PKG_CONFIG" && \673+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&5674+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&5675+ ac_status=$?676+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5677+ test $ac_status = 0; }; then678+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.1.0" 2>/dev/null`679+else680+ pkg_failed=yes681+fi682+ else683+ pkg_failed=untried684+fi685+if test -n "$LUA_LIBS"; then686+ pkg_cv_LUA_LIBS="$LUA_LIBS"687+ elif test -n "$PKG_CONFIG"; then688+ if test -n "$PKG_CONFIG" && \689+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&5690+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&5691+ ac_status=$?692+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5693+ test $ac_status = 0; }; then694+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.1.0" 2>/dev/null`695+else696+ pkg_failed=yes697+fi698+ else699+ pkg_failed=untried700+fi701+702+703+704+if test $pkg_failed = yes; then705+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5706+$as_echo "no" >&6; }707+708+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then709+ _pkg_short_errors_supported=yes710+else711+ _pkg_short_errors_supported=no712+fi713+ if test $_pkg_short_errors_supported = yes; then714+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.1.0" 2>&1`715+ else716+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.1.0" 2>&1`717+ fi718+ # Put the nasty error message in config.log where it belongs719+ echo "$LUA_PKG_ERRORS" >&5720+721+722+pkg_failed=no723+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5724+$as_echo_n "checking for LUA... " >&6; }725+726+if test -n "$LUA_CFLAGS"; then727+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"728+ elif test -n "$PKG_CONFIG"; then729+ if test -n "$PKG_CONFIG" && \730+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&5731+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&5732+ ac_status=$?733+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5734+ test $ac_status = 0; }; then735+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`736+else737+ pkg_failed=yes738+fi739+ else740+ pkg_failed=untried741+fi742+if test -n "$LUA_LIBS"; then743+ pkg_cv_LUA_LIBS="$LUA_LIBS"744+ elif test -n "$PKG_CONFIG"; then745+ if test -n "$PKG_CONFIG" && \746+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&5747+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&5748+ ac_status=$?749+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5750+ test $ac_status = 0; }; then751+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`752+else753+ pkg_failed=yes754+fi755+ else756+ pkg_failed=untried757+fi758+759+760+761+if test $pkg_failed = yes; then762+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5763+$as_echo "no" >&6; }764+765+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then766+ _pkg_short_errors_supported=yes767+else768+ _pkg_short_errors_supported=no769+fi770+ if test $_pkg_short_errors_supported = yes; then771+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`772+ else773+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`774+ fi775+ # Put the nasty error message in config.log where it belongs776+ echo "$LUA_PKG_ERRORS" >&5777+778+779+pkg_failed=no780+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5781+$as_echo_n "checking for LUA... " >&6; }782+783+if test -n "$LUA_CFLAGS"; then784+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"785+ elif test -n "$PKG_CONFIG"; then786+ if test -n "$PKG_CONFIG" && \787+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5788+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5789+ ac_status=$?790+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5791+ test $ac_status = 0; }; then792+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`793+else794+ pkg_failed=yes795+fi796+ else797+ pkg_failed=untried798+fi799+if test -n "$LUA_LIBS"; then800+ pkg_cv_LUA_LIBS="$LUA_LIBS"801+ elif test -n "$PKG_CONFIG"; then802+ if test -n "$PKG_CONFIG" && \803+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5804+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5805+ ac_status=$?806+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5807+ test $ac_status = 0; }; then808+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`809+else810+ pkg_failed=yes811+fi812+ else813+ pkg_failed=untried814+fi815+816+817+818+if test $pkg_failed = yes; then819+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5820+$as_echo "no" >&6; }821+822+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then823+ _pkg_short_errors_supported=yes824+else825+ _pkg_short_errors_supported=no826+fi827+ if test $_pkg_short_errors_supported = yes; then828+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`829+ else830+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`831+ fi832+ # Put the nasty error message in config.log where it belongs833+ echo "$LUA_PKG_ERRORS" >&5834+835+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5836+$as_echo "no" >&6; }837+elif test $pkg_failed = untried; then838+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5839+$as_echo "no" >&6; }840+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5841+$as_echo "no" >&6; }842+else843+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS844+ LUA_LIBS=$pkg_cv_LUA_LIBS845+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5846+$as_echo "yes" >&6; }847+ LUA_VER=0x050000848+fi849+850+elif test $pkg_failed = untried; then851+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5852+$as_echo "no" >&6; }853+854+pkg_failed=no855+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5856+$as_echo_n "checking for LUA... " >&6; }857+858+if test -n "$LUA_CFLAGS"; then859+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"860+ elif test -n "$PKG_CONFIG"; then861+ if test -n "$PKG_CONFIG" && \862+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5863+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5864+ ac_status=$?865+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5866+ test $ac_status = 0; }; then867+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`868+else869+ pkg_failed=yes870+fi871+ else872+ pkg_failed=untried873+fi874+if test -n "$LUA_LIBS"; then875+ pkg_cv_LUA_LIBS="$LUA_LIBS"876+ elif test -n "$PKG_CONFIG"; then877+ if test -n "$PKG_CONFIG" && \878+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&5879+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&5880+ ac_status=$?881+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5882+ test $ac_status = 0; }; then883+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`884+else885+ pkg_failed=yes886+fi887+ else888+ pkg_failed=untried889+fi890+891+892+893+if test $pkg_failed = yes; then894+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5895+$as_echo "no" >&6; }896+897+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then898+ _pkg_short_errors_supported=yes899+else900+ _pkg_short_errors_supported=no901+fi902+ if test $_pkg_short_errors_supported = yes; then903+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`904+ else905+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`906+ fi907+ # Put the nasty error message in config.log where it belongs908+ echo "$LUA_PKG_ERRORS" >&5909+910+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5911+$as_echo "no" >&6; }912+elif test $pkg_failed = untried; then913+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5914+$as_echo "no" >&6; }915+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5916+$as_echo "no" >&6; }917+else918+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS919+ LUA_LIBS=$pkg_cv_LUA_LIBS920+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5921+$as_echo "yes" >&6; }922+ LUA_VER=0x050000923+fi924+925+else926+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS927+ LUA_LIBS=$pkg_cv_LUA_LIBS928+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5929+$as_echo "yes" >&6; }930+ LUA_VER=0x050000931+fi932+933+elif test $pkg_failed = untried; then934+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5935+$as_echo "no" >&6; }936+937+pkg_failed=no938+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5939+$as_echo_n "checking for LUA... " >&6; }940+941+if test -n "$LUA_CFLAGS"; then942+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"943+ elif test -n "$PKG_CONFIG"; then944+ if test -n "$PKG_CONFIG" && \945+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&5946+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&5947+ ac_status=$?948+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5949+ test $ac_status = 0; }; then950+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`951+else952+ pkg_failed=yes953+fi954+ else955+ pkg_failed=untried956+fi957+if test -n "$LUA_LIBS"; then958+ pkg_cv_LUA_LIBS="$LUA_LIBS"959+ elif test -n "$PKG_CONFIG"; then960+ if test -n "$PKG_CONFIG" && \961+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&5962+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&5963+ ac_status=$?964+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5965+ test $ac_status = 0; }; then966+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`967+else968+ pkg_failed=yes969+fi970+ else971+ pkg_failed=untried972+fi973+974+975+976+if test $pkg_failed = yes; then977+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5978+$as_echo "no" >&6; }979+980+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then981+ _pkg_short_errors_supported=yes982+else983+ _pkg_short_errors_supported=no984+fi985+ if test $_pkg_short_errors_supported = yes; then986+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`987+ else988+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`989+ fi990+ # Put the nasty error message in config.log where it belongs991+ echo "$LUA_PKG_ERRORS" >&5992+993+994+pkg_failed=no995+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5996+$as_echo_n "checking for LUA... " >&6; }997+998+if test -n "$LUA_CFLAGS"; then999+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1000+ elif test -n "$PKG_CONFIG"; then1001+ if test -n "$PKG_CONFIG" && \1002+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51003+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51004+ ac_status=$?1005+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51006+ test $ac_status = 0; }; then1007+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1008+else1009+ pkg_failed=yes1010+fi1011+ else1012+ pkg_failed=untried1013+fi1014+if test -n "$LUA_LIBS"; then1015+ pkg_cv_LUA_LIBS="$LUA_LIBS"1016+ elif test -n "$PKG_CONFIG"; then1017+ if test -n "$PKG_CONFIG" && \1018+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51019+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51020+ ac_status=$?1021+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51022+ test $ac_status = 0; }; then1023+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1024+else1025+ pkg_failed=yes1026+fi1027+ else1028+ pkg_failed=untried1029+fi1030+1031+1032+1033+if test $pkg_failed = yes; then1034+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51035+$as_echo "no" >&6; }1036+1037+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1038+ _pkg_short_errors_supported=yes1039+else1040+ _pkg_short_errors_supported=no1041+fi1042+ if test $_pkg_short_errors_supported = yes; then1043+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1044+ else1045+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1046+ fi1047+ # Put the nasty error message in config.log where it belongs1048+ echo "$LUA_PKG_ERRORS" >&51049+1050+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51051+$as_echo "no" >&6; }1052+elif test $pkg_failed = untried; then1053+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51054+$as_echo "no" >&6; }1055+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51056+$as_echo "no" >&6; }1057+else1058+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1059+ LUA_LIBS=$pkg_cv_LUA_LIBS1060+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51061+$as_echo "yes" >&6; }1062+ LUA_VER=0x0500001063+fi1064+1065+elif test $pkg_failed = untried; then1066+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51067+$as_echo "no" >&6; }1068+1069+pkg_failed=no1070+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51071+$as_echo_n "checking for LUA... " >&6; }1072+1073+if test -n "$LUA_CFLAGS"; then1074+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1075+ elif test -n "$PKG_CONFIG"; then1076+ if test -n "$PKG_CONFIG" && \1077+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51078+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51079+ ac_status=$?1080+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51081+ test $ac_status = 0; }; then1082+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1083+else1084+ pkg_failed=yes1085+fi1086+ else1087+ pkg_failed=untried1088+fi1089+if test -n "$LUA_LIBS"; then1090+ pkg_cv_LUA_LIBS="$LUA_LIBS"1091+ elif test -n "$PKG_CONFIG"; then1092+ if test -n "$PKG_CONFIG" && \1093+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51094+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51095+ ac_status=$?1096+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51097+ test $ac_status = 0; }; then1098+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1099+else1100+ pkg_failed=yes1101+fi1102+ else1103+ pkg_failed=untried1104+fi1105+1106+1107+1108+if test $pkg_failed = yes; then1109+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51110+$as_echo "no" >&6; }1111+1112+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1113+ _pkg_short_errors_supported=yes1114+else1115+ _pkg_short_errors_supported=no1116+fi1117+ if test $_pkg_short_errors_supported = yes; then1118+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1119+ else1120+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1121+ fi1122+ # Put the nasty error message in config.log where it belongs1123+ echo "$LUA_PKG_ERRORS" >&51124+1125+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51126+$as_echo "no" >&6; }1127+elif test $pkg_failed = untried; then1128+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51129+$as_echo "no" >&6; }1130+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51131+$as_echo "no" >&6; }1132+else1133+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1134+ LUA_LIBS=$pkg_cv_LUA_LIBS1135+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51136+$as_echo "yes" >&6; }1137+ LUA_VER=0x0500001138+fi1139+1140+else1141+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1142+ LUA_LIBS=$pkg_cv_LUA_LIBS1143+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51144+$as_echo "yes" >&6; }1145+ LUA_VER=0x0500001146+fi1147+1148+else1149+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1150+ LUA_LIBS=$pkg_cv_LUA_LIBS1151+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51152+$as_echo "yes" >&6; }1153+ LUA_VER=0x0501001154+fi1155+1156+else1157+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1158+ LUA_LIBS=$pkg_cv_LUA_LIBS1159+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51160+$as_echo "yes" >&6; }1161+ LUA_VER=0x0501001162+fi1163+1164+elif test $pkg_failed = untried; then1165+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51166+$as_echo "no" >&6; }1167+1168+pkg_failed=no1169+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51170+$as_echo_n "checking for LUA... " >&6; }1171+1172+if test -n "$LUA_CFLAGS"; then1173+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1174+ elif test -n "$PKG_CONFIG"; then1175+ if test -n "$PKG_CONFIG" && \1176+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1.0\""; } >&51177+ ($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1.0") 2>&51178+ ac_status=$?1179+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51180+ test $ac_status = 0; }; then1181+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua5.1 >= 5.1.0" 2>/dev/null`1182+else1183+ pkg_failed=yes1184+fi1185+ else1186+ pkg_failed=untried1187+fi1188+if test -n "$LUA_LIBS"; then1189+ pkg_cv_LUA_LIBS="$LUA_LIBS"1190+ elif test -n "$PKG_CONFIG"; then1191+ if test -n "$PKG_CONFIG" && \1192+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1.0\""; } >&51193+ ($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1.0") 2>&51194+ ac_status=$?1195+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51196+ test $ac_status = 0; }; then1197+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua5.1 >= 5.1.0" 2>/dev/null`1198+else1199+ pkg_failed=yes1200+fi1201+ else1202+ pkg_failed=untried1203+fi1204+1205+1206+1207+if test $pkg_failed = yes; then1208+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51209+$as_echo "no" >&6; }1210+1211+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1212+ _pkg_short_errors_supported=yes1213+else1214+ _pkg_short_errors_supported=no1215+fi1216+ if test $_pkg_short_errors_supported = yes; then1217+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua5.1 >= 5.1.0" 2>&1`1218+ else1219+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua5.1 >= 5.1.0" 2>&1`1220+ fi1221+ # Put the nasty error message in config.log where it belongs1222+ echo "$LUA_PKG_ERRORS" >&51223+1224+1225+pkg_failed=no1226+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51227+$as_echo_n "checking for LUA... " >&6; }1228+1229+if test -n "$LUA_CFLAGS"; then1230+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1231+ elif test -n "$PKG_CONFIG"; then1232+ if test -n "$PKG_CONFIG" && \1233+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&51234+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&51235+ ac_status=$?1236+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51237+ test $ac_status = 0; }; then1238+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.1.0" 2>/dev/null`1239+else1240+ pkg_failed=yes1241+fi1242+ else1243+ pkg_failed=untried1244+fi1245+if test -n "$LUA_LIBS"; then1246+ pkg_cv_LUA_LIBS="$LUA_LIBS"1247+ elif test -n "$PKG_CONFIG"; then1248+ if test -n "$PKG_CONFIG" && \1249+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&51250+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&51251+ ac_status=$?1252+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51253+ test $ac_status = 0; }; then1254+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.1.0" 2>/dev/null`1255+else1256+ pkg_failed=yes1257+fi1258+ else1259+ pkg_failed=untried1260+fi1261+1262+1263+1264+if test $pkg_failed = yes; then1265+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51266+$as_echo "no" >&6; }1267+1268+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1269+ _pkg_short_errors_supported=yes1270+else1271+ _pkg_short_errors_supported=no1272+fi1273+ if test $_pkg_short_errors_supported = yes; then1274+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.1.0" 2>&1`1275+ else1276+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.1.0" 2>&1`1277+ fi1278+ # Put the nasty error message in config.log where it belongs1279+ echo "$LUA_PKG_ERRORS" >&51280+1281+1282+pkg_failed=no1283+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51284+$as_echo_n "checking for LUA... " >&6; }1285+1286+if test -n "$LUA_CFLAGS"; then1287+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1288+ elif test -n "$PKG_CONFIG"; then1289+ if test -n "$PKG_CONFIG" && \1290+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&51291+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&51292+ ac_status=$?1293+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51294+ test $ac_status = 0; }; then1295+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`1296+else1297+ pkg_failed=yes1298+fi1299+ else1300+ pkg_failed=untried1301+fi1302+if test -n "$LUA_LIBS"; then1303+ pkg_cv_LUA_LIBS="$LUA_LIBS"1304+ elif test -n "$PKG_CONFIG"; then1305+ if test -n "$PKG_CONFIG" && \1306+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&51307+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&51308+ ac_status=$?1309+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51310+ test $ac_status = 0; }; then1311+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`1312+else1313+ pkg_failed=yes1314+fi1315+ else1316+ pkg_failed=untried1317+fi1318+1319+1320+1321+if test $pkg_failed = yes; then1322+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51323+$as_echo "no" >&6; }1324+1325+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1326+ _pkg_short_errors_supported=yes1327+else1328+ _pkg_short_errors_supported=no1329+fi1330+ if test $_pkg_short_errors_supported = yes; then1331+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`1332+ else1333+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`1334+ fi1335+ # Put the nasty error message in config.log where it belongs1336+ echo "$LUA_PKG_ERRORS" >&51337+1338+1339+pkg_failed=no1340+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51341+$as_echo_n "checking for LUA... " >&6; }1342+1343+if test -n "$LUA_CFLAGS"; then1344+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1345+ elif test -n "$PKG_CONFIG"; then1346+ if test -n "$PKG_CONFIG" && \1347+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51348+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51349+ ac_status=$?1350+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51351+ test $ac_status = 0; }; then1352+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1353+else1354+ pkg_failed=yes1355+fi1356+ else1357+ pkg_failed=untried1358+fi1359+if test -n "$LUA_LIBS"; then1360+ pkg_cv_LUA_LIBS="$LUA_LIBS"1361+ elif test -n "$PKG_CONFIG"; then1362+ if test -n "$PKG_CONFIG" && \1363+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51364+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51365+ ac_status=$?1366+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51367+ test $ac_status = 0; }; then1368+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1369+else1370+ pkg_failed=yes1371+fi1372+ else1373+ pkg_failed=untried1374+fi1375+1376+1377+1378+if test $pkg_failed = yes; then1379+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51380+$as_echo "no" >&6; }1381+1382+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1383+ _pkg_short_errors_supported=yes1384+else1385+ _pkg_short_errors_supported=no1386+fi1387+ if test $_pkg_short_errors_supported = yes; then1388+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1389+ else1390+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1391+ fi1392+ # Put the nasty error message in config.log where it belongs1393+ echo "$LUA_PKG_ERRORS" >&51394+1395+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51396+$as_echo "no" >&6; }1397+elif test $pkg_failed = untried; then1398+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51399+$as_echo "no" >&6; }1400+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51401+$as_echo "no" >&6; }1402+else1403+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1404+ LUA_LIBS=$pkg_cv_LUA_LIBS1405+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51406+$as_echo "yes" >&6; }1407+ LUA_VER=0x0500001408+fi1409+1410+elif test $pkg_failed = untried; then1411+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51412+$as_echo "no" >&6; }1413+1414+pkg_failed=no1415+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51416+$as_echo_n "checking for LUA... " >&6; }1417+1418+if test -n "$LUA_CFLAGS"; then1419+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1420+ elif test -n "$PKG_CONFIG"; then1421+ if test -n "$PKG_CONFIG" && \1422+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51423+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51424+ ac_status=$?1425+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51426+ test $ac_status = 0; }; then1427+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1428+else1429+ pkg_failed=yes1430+fi1431+ else1432+ pkg_failed=untried1433+fi1434+if test -n "$LUA_LIBS"; then1435+ pkg_cv_LUA_LIBS="$LUA_LIBS"1436+ elif test -n "$PKG_CONFIG"; then1437+ if test -n "$PKG_CONFIG" && \1438+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51439+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51440+ ac_status=$?1441+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51442+ test $ac_status = 0; }; then1443+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1444+else1445+ pkg_failed=yes1446+fi1447+ else1448+ pkg_failed=untried1449+fi1450+1451+1452+1453+if test $pkg_failed = yes; then1454+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51455+$as_echo "no" >&6; }1456+1457+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1458+ _pkg_short_errors_supported=yes1459+else1460+ _pkg_short_errors_supported=no1461+fi1462+ if test $_pkg_short_errors_supported = yes; then1463+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1464+ else1465+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1466+ fi1467+ # Put the nasty error message in config.log where it belongs1468+ echo "$LUA_PKG_ERRORS" >&51469+1470+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51471+$as_echo "no" >&6; }1472+elif test $pkg_failed = untried; then1473+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51474+$as_echo "no" >&6; }1475+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51476+$as_echo "no" >&6; }1477+else1478+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1479+ LUA_LIBS=$pkg_cv_LUA_LIBS1480+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51481+$as_echo "yes" >&6; }1482+ LUA_VER=0x0500001483+fi1484+1485+else1486+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1487+ LUA_LIBS=$pkg_cv_LUA_LIBS1488+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51489+$as_echo "yes" >&6; }1490+ LUA_VER=0x0500001491+fi1492+1493+elif test $pkg_failed = untried; then1494+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51495+$as_echo "no" >&6; }1496+1497+pkg_failed=no1498+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51499+$as_echo_n "checking for LUA... " >&6; }1500+1501+if test -n "$LUA_CFLAGS"; then1502+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1503+ elif test -n "$PKG_CONFIG"; then1504+ if test -n "$PKG_CONFIG" && \1505+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&51506+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&51507+ ac_status=$?1508+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51509+ test $ac_status = 0; }; then1510+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`1511+else1512+ pkg_failed=yes1513+fi1514+ else1515+ pkg_failed=untried1516+fi1517+if test -n "$LUA_LIBS"; then1518+ pkg_cv_LUA_LIBS="$LUA_LIBS"1519+ elif test -n "$PKG_CONFIG"; then1520+ if test -n "$PKG_CONFIG" && \1521+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&51522+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&51523+ ac_status=$?1524+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51525+ test $ac_status = 0; }; then1526+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`1527+else1528+ pkg_failed=yes1529+fi1530+ else1531+ pkg_failed=untried1532+fi1533+1534+1535+1536+if test $pkg_failed = yes; then1537+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51538+$as_echo "no" >&6; }1539+1540+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1541+ _pkg_short_errors_supported=yes1542+else1543+ _pkg_short_errors_supported=no1544+fi1545+ if test $_pkg_short_errors_supported = yes; then1546+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`1547+ else1548+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`1549+ fi1550+ # Put the nasty error message in config.log where it belongs1551+ echo "$LUA_PKG_ERRORS" >&51552+1553+1554+pkg_failed=no1555+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51556+$as_echo_n "checking for LUA... " >&6; }1557+1558+if test -n "$LUA_CFLAGS"; then1559+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1560+ elif test -n "$PKG_CONFIG"; then1561+ if test -n "$PKG_CONFIG" && \1562+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51563+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51564+ ac_status=$?1565+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51566+ test $ac_status = 0; }; then1567+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1568+else1569+ pkg_failed=yes1570+fi1571+ else1572+ pkg_failed=untried1573+fi1574+if test -n "$LUA_LIBS"; then1575+ pkg_cv_LUA_LIBS="$LUA_LIBS"1576+ elif test -n "$PKG_CONFIG"; then1577+ if test -n "$PKG_CONFIG" && \1578+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51579+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51580+ ac_status=$?1581+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51582+ test $ac_status = 0; }; then1583+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1584+else1585+ pkg_failed=yes1586+fi1587+ else1588+ pkg_failed=untried1589+fi1590+1591+1592+1593+if test $pkg_failed = yes; then1594+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51595+$as_echo "no" >&6; }1596+1597+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1598+ _pkg_short_errors_supported=yes1599+else1600+ _pkg_short_errors_supported=no1601+fi1602+ if test $_pkg_short_errors_supported = yes; then1603+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1604+ else1605+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1606+ fi1607+ # Put the nasty error message in config.log where it belongs1608+ echo "$LUA_PKG_ERRORS" >&51609+1610+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51611+$as_echo "no" >&6; }1612+elif test $pkg_failed = untried; then1613+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51614+$as_echo "no" >&6; }1615+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51616+$as_echo "no" >&6; }1617+else1618+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1619+ LUA_LIBS=$pkg_cv_LUA_LIBS1620+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51621+$as_echo "yes" >&6; }1622+ LUA_VER=0x0500001623+fi1624+1625+elif test $pkg_failed = untried; then1626+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51627+$as_echo "no" >&6; }1628+1629+pkg_failed=no1630+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51631+$as_echo_n "checking for LUA... " >&6; }1632+1633+if test -n "$LUA_CFLAGS"; then1634+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1635+ elif test -n "$PKG_CONFIG"; then1636+ if test -n "$PKG_CONFIG" && \1637+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51638+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51639+ ac_status=$?1640+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51641+ test $ac_status = 0; }; then1642+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1643+else1644+ pkg_failed=yes1645+fi1646+ else1647+ pkg_failed=untried1648+fi1649+if test -n "$LUA_LIBS"; then1650+ pkg_cv_LUA_LIBS="$LUA_LIBS"1651+ elif test -n "$PKG_CONFIG"; then1652+ if test -n "$PKG_CONFIG" && \1653+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51654+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51655+ ac_status=$?1656+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51657+ test $ac_status = 0; }; then1658+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1659+else1660+ pkg_failed=yes1661+fi1662+ else1663+ pkg_failed=untried1664+fi1665+1666+1667+1668+if test $pkg_failed = yes; then1669+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51670+$as_echo "no" >&6; }1671+1672+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1673+ _pkg_short_errors_supported=yes1674+else1675+ _pkg_short_errors_supported=no1676+fi1677+ if test $_pkg_short_errors_supported = yes; then1678+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1679+ else1680+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1681+ fi1682+ # Put the nasty error message in config.log where it belongs1683+ echo "$LUA_PKG_ERRORS" >&51684+1685+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51686+$as_echo "no" >&6; }1687+elif test $pkg_failed = untried; then1688+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51689+$as_echo "no" >&6; }1690+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51691+$as_echo "no" >&6; }1692+else1693+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1694+ LUA_LIBS=$pkg_cv_LUA_LIBS1695+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51696+$as_echo "yes" >&6; }1697+ LUA_VER=0x0500001698+fi1699+1700+else1701+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1702+ LUA_LIBS=$pkg_cv_LUA_LIBS1703+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51704+$as_echo "yes" >&6; }1705+ LUA_VER=0x0500001706+fi1707+1708+else1709+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1710+ LUA_LIBS=$pkg_cv_LUA_LIBS1711+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51712+$as_echo "yes" >&6; }1713+ LUA_VER=0x0501001714+fi1715+1716+elif test $pkg_failed = untried; then1717+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51718+$as_echo "no" >&6; }1719+1720+pkg_failed=no1721+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51722+$as_echo_n "checking for LUA... " >&6; }1723+1724+if test -n "$LUA_CFLAGS"; then1725+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1726+ elif test -n "$PKG_CONFIG"; then1727+ if test -n "$PKG_CONFIG" && \1728+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&51729+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&51730+ ac_status=$?1731+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51732+ test $ac_status = 0; }; then1733+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.1.0" 2>/dev/null`1734+else1735+ pkg_failed=yes1736+fi1737+ else1738+ pkg_failed=untried1739+fi1740+if test -n "$LUA_LIBS"; then1741+ pkg_cv_LUA_LIBS="$LUA_LIBS"1742+ elif test -n "$PKG_CONFIG"; then1743+ if test -n "$PKG_CONFIG" && \1744+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&51745+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&51746+ ac_status=$?1747+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51748+ test $ac_status = 0; }; then1749+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.1.0" 2>/dev/null`1750+else1751+ pkg_failed=yes1752+fi1753+ else1754+ pkg_failed=untried1755+fi1756+1757+1758+1759+if test $pkg_failed = yes; then1760+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51761+$as_echo "no" >&6; }1762+1763+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1764+ _pkg_short_errors_supported=yes1765+else1766+ _pkg_short_errors_supported=no1767+fi1768+ if test $_pkg_short_errors_supported = yes; then1769+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.1.0" 2>&1`1770+ else1771+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.1.0" 2>&1`1772+ fi1773+ # Put the nasty error message in config.log where it belongs1774+ echo "$LUA_PKG_ERRORS" >&51775+1776+1777+pkg_failed=no1778+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51779+$as_echo_n "checking for LUA... " >&6; }1780+1781+if test -n "$LUA_CFLAGS"; then1782+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1783+ elif test -n "$PKG_CONFIG"; then1784+ if test -n "$PKG_CONFIG" && \1785+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&51786+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&51787+ ac_status=$?1788+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51789+ test $ac_status = 0; }; then1790+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`1791+else1792+ pkg_failed=yes1793+fi1794+ else1795+ pkg_failed=untried1796+fi1797+if test -n "$LUA_LIBS"; then1798+ pkg_cv_LUA_LIBS="$LUA_LIBS"1799+ elif test -n "$PKG_CONFIG"; then1800+ if test -n "$PKG_CONFIG" && \1801+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&51802+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&51803+ ac_status=$?1804+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51805+ test $ac_status = 0; }; then1806+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`1807+else1808+ pkg_failed=yes1809+fi1810+ else1811+ pkg_failed=untried1812+fi1813+1814+1815+1816+if test $pkg_failed = yes; then1817+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51818+$as_echo "no" >&6; }1819+1820+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1821+ _pkg_short_errors_supported=yes1822+else1823+ _pkg_short_errors_supported=no1824+fi1825+ if test $_pkg_short_errors_supported = yes; then1826+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`1827+ else1828+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`1829+ fi1830+ # Put the nasty error message in config.log where it belongs1831+ echo "$LUA_PKG_ERRORS" >&51832+1833+1834+pkg_failed=no1835+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51836+$as_echo_n "checking for LUA... " >&6; }1837+1838+if test -n "$LUA_CFLAGS"; then1839+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1840+ elif test -n "$PKG_CONFIG"; then1841+ if test -n "$PKG_CONFIG" && \1842+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51843+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51844+ ac_status=$?1845+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51846+ test $ac_status = 0; }; then1847+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1848+else1849+ pkg_failed=yes1850+fi1851+ else1852+ pkg_failed=untried1853+fi1854+if test -n "$LUA_LIBS"; then1855+ pkg_cv_LUA_LIBS="$LUA_LIBS"1856+ elif test -n "$PKG_CONFIG"; then1857+ if test -n "$PKG_CONFIG" && \1858+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51859+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51860+ ac_status=$?1861+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51862+ test $ac_status = 0; }; then1863+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1864+else1865+ pkg_failed=yes1866+fi1867+ else1868+ pkg_failed=untried1869+fi1870+1871+1872+1873+if test $pkg_failed = yes; then1874+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51875+$as_echo "no" >&6; }1876+1877+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1878+ _pkg_short_errors_supported=yes1879+else1880+ _pkg_short_errors_supported=no1881+fi1882+ if test $_pkg_short_errors_supported = yes; then1883+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1884+ else1885+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1886+ fi1887+ # Put the nasty error message in config.log where it belongs1888+ echo "$LUA_PKG_ERRORS" >&51889+1890+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51891+$as_echo "no" >&6; }1892+elif test $pkg_failed = untried; then1893+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51894+$as_echo "no" >&6; }1895+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51896+$as_echo "no" >&6; }1897+else1898+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1899+ LUA_LIBS=$pkg_cv_LUA_LIBS1900+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51901+$as_echo "yes" >&6; }1902+ LUA_VER=0x0500001903+fi1904+1905+elif test $pkg_failed = untried; then1906+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51907+$as_echo "no" >&6; }1908+1909+pkg_failed=no1910+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51911+$as_echo_n "checking for LUA... " >&6; }1912+1913+if test -n "$LUA_CFLAGS"; then1914+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1915+ elif test -n "$PKG_CONFIG"; then1916+ if test -n "$PKG_CONFIG" && \1917+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51918+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51919+ ac_status=$?1920+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51921+ test $ac_status = 0; }; then1922+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1923+else1924+ pkg_failed=yes1925+fi1926+ else1927+ pkg_failed=untried1928+fi1929+if test -n "$LUA_LIBS"; then1930+ pkg_cv_LUA_LIBS="$LUA_LIBS"1931+ elif test -n "$PKG_CONFIG"; then1932+ if test -n "$PKG_CONFIG" && \1933+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&51934+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&51935+ ac_status=$?1936+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&51937+ test $ac_status = 0; }; then1938+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`1939+else1940+ pkg_failed=yes1941+fi1942+ else1943+ pkg_failed=untried1944+fi1945+1946+1947+1948+if test $pkg_failed = yes; then1949+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51950+$as_echo "no" >&6; }1951+1952+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then1953+ _pkg_short_errors_supported=yes1954+else1955+ _pkg_short_errors_supported=no1956+fi1957+ if test $_pkg_short_errors_supported = yes; then1958+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1959+ else1960+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`1961+ fi1962+ # Put the nasty error message in config.log where it belongs1963+ echo "$LUA_PKG_ERRORS" >&51964+1965+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51966+$as_echo "no" >&6; }1967+elif test $pkg_failed = untried; then1968+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51969+$as_echo "no" >&6; }1970+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51971+$as_echo "no" >&6; }1972+else1973+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1974+ LUA_LIBS=$pkg_cv_LUA_LIBS1975+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51976+$as_echo "yes" >&6; }1977+ LUA_VER=0x0500001978+fi1979+1980+else1981+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS1982+ LUA_LIBS=$pkg_cv_LUA_LIBS1983+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&51984+$as_echo "yes" >&6; }1985+ LUA_VER=0x0500001986+fi1987+1988+elif test $pkg_failed = untried; then1989+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&51990+$as_echo "no" >&6; }1991+1992+pkg_failed=no1993+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&51994+$as_echo_n "checking for LUA... " >&6; }1995+1996+if test -n "$LUA_CFLAGS"; then1997+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"1998+ elif test -n "$PKG_CONFIG"; then1999+ if test -n "$PKG_CONFIG" && \2000+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&52001+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&52002+ ac_status=$?2003+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52004+ test $ac_status = 0; }; then2005+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`2006+else2007+ pkg_failed=yes2008+fi2009+ else2010+ pkg_failed=untried2011+fi2012+if test -n "$LUA_LIBS"; then2013+ pkg_cv_LUA_LIBS="$LUA_LIBS"2014+ elif test -n "$PKG_CONFIG"; then2015+ if test -n "$PKG_CONFIG" && \2016+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&52017+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&52018+ ac_status=$?2019+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52020+ test $ac_status = 0; }; then2021+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`2022+else2023+ pkg_failed=yes2024+fi2025+ else2026+ pkg_failed=untried2027+fi2028+2029+2030+2031+if test $pkg_failed = yes; then2032+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52033+$as_echo "no" >&6; }2034+2035+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2036+ _pkg_short_errors_supported=yes2037+else2038+ _pkg_short_errors_supported=no2039+fi2040+ if test $_pkg_short_errors_supported = yes; then2041+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`2042+ else2043+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`2044+ fi2045+ # Put the nasty error message in config.log where it belongs2046+ echo "$LUA_PKG_ERRORS" >&52047+2048+2049+pkg_failed=no2050+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52051+$as_echo_n "checking for LUA... " >&6; }2052+2053+if test -n "$LUA_CFLAGS"; then2054+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2055+ elif test -n "$PKG_CONFIG"; then2056+ if test -n "$PKG_CONFIG" && \2057+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52058+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52059+ ac_status=$?2060+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52061+ test $ac_status = 0; }; then2062+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2063+else2064+ pkg_failed=yes2065+fi2066+ else2067+ pkg_failed=untried2068+fi2069+if test -n "$LUA_LIBS"; then2070+ pkg_cv_LUA_LIBS="$LUA_LIBS"2071+ elif test -n "$PKG_CONFIG"; then2072+ if test -n "$PKG_CONFIG" && \2073+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52074+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52075+ ac_status=$?2076+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52077+ test $ac_status = 0; }; then2078+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2079+else2080+ pkg_failed=yes2081+fi2082+ else2083+ pkg_failed=untried2084+fi2085+2086+2087+2088+if test $pkg_failed = yes; then2089+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52090+$as_echo "no" >&6; }2091+2092+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2093+ _pkg_short_errors_supported=yes2094+else2095+ _pkg_short_errors_supported=no2096+fi2097+ if test $_pkg_short_errors_supported = yes; then2098+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2099+ else2100+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2101+ fi2102+ # Put the nasty error message in config.log where it belongs2103+ echo "$LUA_PKG_ERRORS" >&52104+2105+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52106+$as_echo "no" >&6; }2107+elif test $pkg_failed = untried; then2108+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52109+$as_echo "no" >&6; }2110+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52111+$as_echo "no" >&6; }2112+else2113+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2114+ LUA_LIBS=$pkg_cv_LUA_LIBS2115+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52116+$as_echo "yes" >&6; }2117+ LUA_VER=0x0500002118+fi2119+2120+elif test $pkg_failed = untried; then2121+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52122+$as_echo "no" >&6; }2123+2124+pkg_failed=no2125+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52126+$as_echo_n "checking for LUA... " >&6; }2127+2128+if test -n "$LUA_CFLAGS"; then2129+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2130+ elif test -n "$PKG_CONFIG"; then2131+ if test -n "$PKG_CONFIG" && \2132+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52133+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52134+ ac_status=$?2135+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52136+ test $ac_status = 0; }; then2137+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2138+else2139+ pkg_failed=yes2140+fi2141+ else2142+ pkg_failed=untried2143+fi2144+if test -n "$LUA_LIBS"; then2145+ pkg_cv_LUA_LIBS="$LUA_LIBS"2146+ elif test -n "$PKG_CONFIG"; then2147+ if test -n "$PKG_CONFIG" && \2148+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52149+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52150+ ac_status=$?2151+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52152+ test $ac_status = 0; }; then2153+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2154+else2155+ pkg_failed=yes2156+fi2157+ else2158+ pkg_failed=untried2159+fi2160+2161+2162+2163+if test $pkg_failed = yes; then2164+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52165+$as_echo "no" >&6; }2166+2167+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2168+ _pkg_short_errors_supported=yes2169+else2170+ _pkg_short_errors_supported=no2171+fi2172+ if test $_pkg_short_errors_supported = yes; then2173+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2174+ else2175+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2176+ fi2177+ # Put the nasty error message in config.log where it belongs2178+ echo "$LUA_PKG_ERRORS" >&52179+2180+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52181+$as_echo "no" >&6; }2182+elif test $pkg_failed = untried; then2183+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52184+$as_echo "no" >&6; }2185+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52186+$as_echo "no" >&6; }2187+else2188+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2189+ LUA_LIBS=$pkg_cv_LUA_LIBS2190+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52191+$as_echo "yes" >&6; }2192+ LUA_VER=0x0500002193+fi2194+2195+else2196+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2197+ LUA_LIBS=$pkg_cv_LUA_LIBS2198+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52199+$as_echo "yes" >&6; }2200+ LUA_VER=0x0500002201+fi2202+2203+else2204+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2205+ LUA_LIBS=$pkg_cv_LUA_LIBS2206+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52207+$as_echo "yes" >&6; }2208+ LUA_VER=0x0501002209+fi2210+2211+else2212+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2213+ LUA_LIBS=$pkg_cv_LUA_LIBS2214+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52215+$as_echo "yes" >&6; }2216+ LUA_VER=0x0501002217+fi2218+2219+else2220+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2221+ LUA_LIBS=$pkg_cv_LUA_LIBS2222+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52223+$as_echo "yes" >&6; }2224+ LUA_VER=0x0502002225+fi2226+2227+elif test $pkg_failed = untried; then2228+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52229+$as_echo "no" >&6; }2230+2231+pkg_failed=no2232+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52233+$as_echo_n "checking for LUA... " >&6; }2234+2235+if test -n "$LUA_CFLAGS"; then2236+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2237+ elif test -n "$PKG_CONFIG"; then2238+ if test -n "$PKG_CONFIG" && \2239+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.2.0\""; } >&52240+ ($PKG_CONFIG --exists --print-errors "lua >= 5.2.0") 2>&52241+ ac_status=$?2242+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52243+ test $ac_status = 0; }; then2244+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.2.0" 2>/dev/null`2245+else2246+ pkg_failed=yes2247+fi2248+ else2249+ pkg_failed=untried2250+fi2251+if test -n "$LUA_LIBS"; then2252+ pkg_cv_LUA_LIBS="$LUA_LIBS"2253+ elif test -n "$PKG_CONFIG"; then2254+ if test -n "$PKG_CONFIG" && \2255+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.2.0\""; } >&52256+ ($PKG_CONFIG --exists --print-errors "lua >= 5.2.0") 2>&52257+ ac_status=$?2258+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52259+ test $ac_status = 0; }; then2260+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.2.0" 2>/dev/null`2261+else2262+ pkg_failed=yes2263+fi2264+ else2265+ pkg_failed=untried2266+fi2267+2268+2269+2270+if test $pkg_failed = yes; then2271+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52272+$as_echo "no" >&6; }2273+2274+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2275+ _pkg_short_errors_supported=yes2276+else2277+ _pkg_short_errors_supported=no2278+fi2279+ if test $_pkg_short_errors_supported = yes; then2280+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.2.0" 2>&1`2281+ else2282+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.2.0" 2>&1`2283+ fi2284+ # Put the nasty error message in config.log where it belongs2285+ echo "$LUA_PKG_ERRORS" >&52286+2287+2288+pkg_failed=no2289+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52290+$as_echo_n "checking for LUA... " >&6; }2291+2292+if test -n "$LUA_CFLAGS"; then2293+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2294+ elif test -n "$PKG_CONFIG"; then2295+ if test -n "$PKG_CONFIG" && \2296+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1.0\""; } >&52297+ ($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1.0") 2>&52298+ ac_status=$?2299+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52300+ test $ac_status = 0; }; then2301+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua5.1 >= 5.1.0" 2>/dev/null`2302+else2303+ pkg_failed=yes2304+fi2305+ else2306+ pkg_failed=untried2307+fi2308+if test -n "$LUA_LIBS"; then2309+ pkg_cv_LUA_LIBS="$LUA_LIBS"2310+ elif test -n "$PKG_CONFIG"; then2311+ if test -n "$PKG_CONFIG" && \2312+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1.0\""; } >&52313+ ($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1.0") 2>&52314+ ac_status=$?2315+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52316+ test $ac_status = 0; }; then2317+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua5.1 >= 5.1.0" 2>/dev/null`2318+else2319+ pkg_failed=yes2320+fi2321+ else2322+ pkg_failed=untried2323+fi2324+2325+2326+2327+if test $pkg_failed = yes; then2328+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52329+$as_echo "no" >&6; }2330+2331+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2332+ _pkg_short_errors_supported=yes2333+else2334+ _pkg_short_errors_supported=no2335+fi2336+ if test $_pkg_short_errors_supported = yes; then2337+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua5.1 >= 5.1.0" 2>&1`2338+ else2339+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua5.1 >= 5.1.0" 2>&1`2340+ fi2341+ # Put the nasty error message in config.log where it belongs2342+ echo "$LUA_PKG_ERRORS" >&52343+2344+2345+pkg_failed=no2346+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52347+$as_echo_n "checking for LUA... " >&6; }2348+2349+if test -n "$LUA_CFLAGS"; then2350+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2351+ elif test -n "$PKG_CONFIG"; then2352+ if test -n "$PKG_CONFIG" && \2353+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&52354+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&52355+ ac_status=$?2356+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52357+ test $ac_status = 0; }; then2358+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.1.0" 2>/dev/null`2359+else2360+ pkg_failed=yes2361+fi2362+ else2363+ pkg_failed=untried2364+fi2365+if test -n "$LUA_LIBS"; then2366+ pkg_cv_LUA_LIBS="$LUA_LIBS"2367+ elif test -n "$PKG_CONFIG"; then2368+ if test -n "$PKG_CONFIG" && \2369+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&52370+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&52371+ ac_status=$?2372+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52373+ test $ac_status = 0; }; then2374+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.1.0" 2>/dev/null`2375+else2376+ pkg_failed=yes2377+fi2378+ else2379+ pkg_failed=untried2380+fi2381+2382+2383+2384+if test $pkg_failed = yes; then2385+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52386+$as_echo "no" >&6; }2387+2388+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2389+ _pkg_short_errors_supported=yes2390+else2391+ _pkg_short_errors_supported=no2392+fi2393+ if test $_pkg_short_errors_supported = yes; then2394+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.1.0" 2>&1`2395+ else2396+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.1.0" 2>&1`2397+ fi2398+ # Put the nasty error message in config.log where it belongs2399+ echo "$LUA_PKG_ERRORS" >&52400+2401+2402+pkg_failed=no2403+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52404+$as_echo_n "checking for LUA... " >&6; }2405+2406+if test -n "$LUA_CFLAGS"; then2407+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2408+ elif test -n "$PKG_CONFIG"; then2409+ if test -n "$PKG_CONFIG" && \2410+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&52411+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&52412+ ac_status=$?2413+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52414+ test $ac_status = 0; }; then2415+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`2416+else2417+ pkg_failed=yes2418+fi2419+ else2420+ pkg_failed=untried2421+fi2422+if test -n "$LUA_LIBS"; then2423+ pkg_cv_LUA_LIBS="$LUA_LIBS"2424+ elif test -n "$PKG_CONFIG"; then2425+ if test -n "$PKG_CONFIG" && \2426+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&52427+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&52428+ ac_status=$?2429+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52430+ test $ac_status = 0; }; then2431+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`2432+else2433+ pkg_failed=yes2434+fi2435+ else2436+ pkg_failed=untried2437+fi2438+2439+2440+2441+if test $pkg_failed = yes; then2442+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52443+$as_echo "no" >&6; }2444+2445+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2446+ _pkg_short_errors_supported=yes2447+else2448+ _pkg_short_errors_supported=no2449+fi2450+ if test $_pkg_short_errors_supported = yes; then2451+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`2452+ else2453+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`2454+ fi2455+ # Put the nasty error message in config.log where it belongs2456+ echo "$LUA_PKG_ERRORS" >&52457+2458+2459+pkg_failed=no2460+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52461+$as_echo_n "checking for LUA... " >&6; }2462+2463+if test -n "$LUA_CFLAGS"; then2464+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2465+ elif test -n "$PKG_CONFIG"; then2466+ if test -n "$PKG_CONFIG" && \2467+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52468+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52469+ ac_status=$?2470+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52471+ test $ac_status = 0; }; then2472+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2473+else2474+ pkg_failed=yes2475+fi2476+ else2477+ pkg_failed=untried2478+fi2479+if test -n "$LUA_LIBS"; then2480+ pkg_cv_LUA_LIBS="$LUA_LIBS"2481+ elif test -n "$PKG_CONFIG"; then2482+ if test -n "$PKG_CONFIG" && \2483+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52484+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52485+ ac_status=$?2486+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52487+ test $ac_status = 0; }; then2488+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2489+else2490+ pkg_failed=yes2491+fi2492+ else2493+ pkg_failed=untried2494+fi2495+2496+2497+2498+if test $pkg_failed = yes; then2499+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52500+$as_echo "no" >&6; }2501+2502+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2503+ _pkg_short_errors_supported=yes2504+else2505+ _pkg_short_errors_supported=no2506+fi2507+ if test $_pkg_short_errors_supported = yes; then2508+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2509+ else2510+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2511+ fi2512+ # Put the nasty error message in config.log where it belongs2513+ echo "$LUA_PKG_ERRORS" >&52514+2515+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52516+$as_echo "no" >&6; }2517+elif test $pkg_failed = untried; then2518+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52519+$as_echo "no" >&6; }2520+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52521+$as_echo "no" >&6; }2522+else2523+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2524+ LUA_LIBS=$pkg_cv_LUA_LIBS2525+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52526+$as_echo "yes" >&6; }2527+ LUA_VER=0x0500002528+fi2529+2530+elif test $pkg_failed = untried; then2531+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52532+$as_echo "no" >&6; }2533+2534+pkg_failed=no2535+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52536+$as_echo_n "checking for LUA... " >&6; }2537+2538+if test -n "$LUA_CFLAGS"; then2539+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2540+ elif test -n "$PKG_CONFIG"; then2541+ if test -n "$PKG_CONFIG" && \2542+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52543+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52544+ ac_status=$?2545+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52546+ test $ac_status = 0; }; then2547+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2548+else2549+ pkg_failed=yes2550+fi2551+ else2552+ pkg_failed=untried2553+fi2554+if test -n "$LUA_LIBS"; then2555+ pkg_cv_LUA_LIBS="$LUA_LIBS"2556+ elif test -n "$PKG_CONFIG"; then2557+ if test -n "$PKG_CONFIG" && \2558+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52559+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52560+ ac_status=$?2561+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52562+ test $ac_status = 0; }; then2563+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2564+else2565+ pkg_failed=yes2566+fi2567+ else2568+ pkg_failed=untried2569+fi2570+2571+2572+2573+if test $pkg_failed = yes; then2574+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52575+$as_echo "no" >&6; }2576+2577+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2578+ _pkg_short_errors_supported=yes2579+else2580+ _pkg_short_errors_supported=no2581+fi2582+ if test $_pkg_short_errors_supported = yes; then2583+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2584+ else2585+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2586+ fi2587+ # Put the nasty error message in config.log where it belongs2588+ echo "$LUA_PKG_ERRORS" >&52589+2590+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52591+$as_echo "no" >&6; }2592+elif test $pkg_failed = untried; then2593+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52594+$as_echo "no" >&6; }2595+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52596+$as_echo "no" >&6; }2597+else2598+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2599+ LUA_LIBS=$pkg_cv_LUA_LIBS2600+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52601+$as_echo "yes" >&6; }2602+ LUA_VER=0x0500002603+fi2604+2605+else2606+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2607+ LUA_LIBS=$pkg_cv_LUA_LIBS2608+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52609+$as_echo "yes" >&6; }2610+ LUA_VER=0x0500002611+fi2612+2613+elif test $pkg_failed = untried; then2614+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52615+$as_echo "no" >&6; }2616+2617+pkg_failed=no2618+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52619+$as_echo_n "checking for LUA... " >&6; }2620+2621+if test -n "$LUA_CFLAGS"; then2622+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2623+ elif test -n "$PKG_CONFIG"; then2624+ if test -n "$PKG_CONFIG" && \2625+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&52626+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&52627+ ac_status=$?2628+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52629+ test $ac_status = 0; }; then2630+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`2631+else2632+ pkg_failed=yes2633+fi2634+ else2635+ pkg_failed=untried2636+fi2637+if test -n "$LUA_LIBS"; then2638+ pkg_cv_LUA_LIBS="$LUA_LIBS"2639+ elif test -n "$PKG_CONFIG"; then2640+ if test -n "$PKG_CONFIG" && \2641+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&52642+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&52643+ ac_status=$?2644+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52645+ test $ac_status = 0; }; then2646+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`2647+else2648+ pkg_failed=yes2649+fi2650+ else2651+ pkg_failed=untried2652+fi2653+2654+2655+2656+if test $pkg_failed = yes; then2657+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52658+$as_echo "no" >&6; }2659+2660+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2661+ _pkg_short_errors_supported=yes2662+else2663+ _pkg_short_errors_supported=no2664+fi2665+ if test $_pkg_short_errors_supported = yes; then2666+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`2667+ else2668+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`2669+ fi2670+ # Put the nasty error message in config.log where it belongs2671+ echo "$LUA_PKG_ERRORS" >&52672+2673+2674+pkg_failed=no2675+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52676+$as_echo_n "checking for LUA... " >&6; }2677+2678+if test -n "$LUA_CFLAGS"; then2679+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2680+ elif test -n "$PKG_CONFIG"; then2681+ if test -n "$PKG_CONFIG" && \2682+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52683+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52684+ ac_status=$?2685+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52686+ test $ac_status = 0; }; then2687+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2688+else2689+ pkg_failed=yes2690+fi2691+ else2692+ pkg_failed=untried2693+fi2694+if test -n "$LUA_LIBS"; then2695+ pkg_cv_LUA_LIBS="$LUA_LIBS"2696+ elif test -n "$PKG_CONFIG"; then2697+ if test -n "$PKG_CONFIG" && \2698+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52699+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52700+ ac_status=$?2701+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52702+ test $ac_status = 0; }; then2703+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2704+else2705+ pkg_failed=yes2706+fi2707+ else2708+ pkg_failed=untried2709+fi2710+2711+2712+2713+if test $pkg_failed = yes; then2714+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52715+$as_echo "no" >&6; }2716+2717+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2718+ _pkg_short_errors_supported=yes2719+else2720+ _pkg_short_errors_supported=no2721+fi2722+ if test $_pkg_short_errors_supported = yes; then2723+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2724+ else2725+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2726+ fi2727+ # Put the nasty error message in config.log where it belongs2728+ echo "$LUA_PKG_ERRORS" >&52729+2730+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52731+$as_echo "no" >&6; }2732+elif test $pkg_failed = untried; then2733+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52734+$as_echo "no" >&6; }2735+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52736+$as_echo "no" >&6; }2737+else2738+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2739+ LUA_LIBS=$pkg_cv_LUA_LIBS2740+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52741+$as_echo "yes" >&6; }2742+ LUA_VER=0x0500002743+fi2744+2745+elif test $pkg_failed = untried; then2746+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52747+$as_echo "no" >&6; }2748+2749+pkg_failed=no2750+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52751+$as_echo_n "checking for LUA... " >&6; }2752+2753+if test -n "$LUA_CFLAGS"; then2754+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2755+ elif test -n "$PKG_CONFIG"; then2756+ if test -n "$PKG_CONFIG" && \2757+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52758+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52759+ ac_status=$?2760+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52761+ test $ac_status = 0; }; then2762+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2763+else2764+ pkg_failed=yes2765+fi2766+ else2767+ pkg_failed=untried2768+fi2769+if test -n "$LUA_LIBS"; then2770+ pkg_cv_LUA_LIBS="$LUA_LIBS"2771+ elif test -n "$PKG_CONFIG"; then2772+ if test -n "$PKG_CONFIG" && \2773+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52774+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52775+ ac_status=$?2776+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52777+ test $ac_status = 0; }; then2778+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2779+else2780+ pkg_failed=yes2781+fi2782+ else2783+ pkg_failed=untried2784+fi2785+2786+2787+2788+if test $pkg_failed = yes; then2789+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52790+$as_echo "no" >&6; }2791+2792+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2793+ _pkg_short_errors_supported=yes2794+else2795+ _pkg_short_errors_supported=no2796+fi2797+ if test $_pkg_short_errors_supported = yes; then2798+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2799+ else2800+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`2801+ fi2802+ # Put the nasty error message in config.log where it belongs2803+ echo "$LUA_PKG_ERRORS" >&52804+2805+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52806+$as_echo "no" >&6; }2807+elif test $pkg_failed = untried; then2808+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52809+$as_echo "no" >&6; }2810+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52811+$as_echo "no" >&6; }2812+else2813+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2814+ LUA_LIBS=$pkg_cv_LUA_LIBS2815+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52816+$as_echo "yes" >&6; }2817+ LUA_VER=0x0500002818+fi2819+2820+else2821+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2822+ LUA_LIBS=$pkg_cv_LUA_LIBS2823+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52824+$as_echo "yes" >&6; }2825+ LUA_VER=0x0500002826+fi2827+2828+else2829+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS2830+ LUA_LIBS=$pkg_cv_LUA_LIBS2831+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&52832+$as_echo "yes" >&6; }2833+ LUA_VER=0x0501002834+fi2835+2836+elif test $pkg_failed = untried; then2837+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52838+$as_echo "no" >&6; }2839+2840+pkg_failed=no2841+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52842+$as_echo_n "checking for LUA... " >&6; }2843+2844+if test -n "$LUA_CFLAGS"; then2845+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2846+ elif test -n "$PKG_CONFIG"; then2847+ if test -n "$PKG_CONFIG" && \2848+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&52849+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&52850+ ac_status=$?2851+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52852+ test $ac_status = 0; }; then2853+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.1.0" 2>/dev/null`2854+else2855+ pkg_failed=yes2856+fi2857+ else2858+ pkg_failed=untried2859+fi2860+if test -n "$LUA_LIBS"; then2861+ pkg_cv_LUA_LIBS="$LUA_LIBS"2862+ elif test -n "$PKG_CONFIG"; then2863+ if test -n "$PKG_CONFIG" && \2864+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.1.0\""; } >&52865+ ($PKG_CONFIG --exists --print-errors "lua >= 5.1.0") 2>&52866+ ac_status=$?2867+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52868+ test $ac_status = 0; }; then2869+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.1.0" 2>/dev/null`2870+else2871+ pkg_failed=yes2872+fi2873+ else2874+ pkg_failed=untried2875+fi2876+2877+2878+2879+if test $pkg_failed = yes; then2880+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52881+$as_echo "no" >&6; }2882+2883+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2884+ _pkg_short_errors_supported=yes2885+else2886+ _pkg_short_errors_supported=no2887+fi2888+ if test $_pkg_short_errors_supported = yes; then2889+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.1.0" 2>&1`2890+ else2891+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.1.0" 2>&1`2892+ fi2893+ # Put the nasty error message in config.log where it belongs2894+ echo "$LUA_PKG_ERRORS" >&52895+2896+2897+pkg_failed=no2898+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52899+$as_echo_n "checking for LUA... " >&6; }2900+2901+if test -n "$LUA_CFLAGS"; then2902+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2903+ elif test -n "$PKG_CONFIG"; then2904+ if test -n "$PKG_CONFIG" && \2905+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&52906+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&52907+ ac_status=$?2908+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52909+ test $ac_status = 0; }; then2910+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`2911+else2912+ pkg_failed=yes2913+fi2914+ else2915+ pkg_failed=untried2916+fi2917+if test -n "$LUA_LIBS"; then2918+ pkg_cv_LUA_LIBS="$LUA_LIBS"2919+ elif test -n "$PKG_CONFIG"; then2920+ if test -n "$PKG_CONFIG" && \2921+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&52922+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&52923+ ac_status=$?2924+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52925+ test $ac_status = 0; }; then2926+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`2927+else2928+ pkg_failed=yes2929+fi2930+ else2931+ pkg_failed=untried2932+fi2933+2934+2935+2936+if test $pkg_failed = yes; then2937+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52938+$as_echo "no" >&6; }2939+2940+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2941+ _pkg_short_errors_supported=yes2942+else2943+ _pkg_short_errors_supported=no2944+fi2945+ if test $_pkg_short_errors_supported = yes; then2946+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`2947+ else2948+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`2949+ fi2950+ # Put the nasty error message in config.log where it belongs2951+ echo "$LUA_PKG_ERRORS" >&52952+2953+2954+pkg_failed=no2955+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&52956+$as_echo_n "checking for LUA... " >&6; }2957+2958+if test -n "$LUA_CFLAGS"; then2959+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"2960+ elif test -n "$PKG_CONFIG"; then2961+ if test -n "$PKG_CONFIG" && \2962+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52963+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52964+ ac_status=$?2965+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52966+ test $ac_status = 0; }; then2967+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2968+else2969+ pkg_failed=yes2970+fi2971+ else2972+ pkg_failed=untried2973+fi2974+if test -n "$LUA_LIBS"; then2975+ pkg_cv_LUA_LIBS="$LUA_LIBS"2976+ elif test -n "$PKG_CONFIG"; then2977+ if test -n "$PKG_CONFIG" && \2978+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&52979+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&52980+ ac_status=$?2981+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&52982+ test $ac_status = 0; }; then2983+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`2984+else2985+ pkg_failed=yes2986+fi2987+ else2988+ pkg_failed=untried2989+fi2990+2991+2992+2993+if test $pkg_failed = yes; then2994+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&52995+$as_echo "no" >&6; }2996+2997+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then2998+ _pkg_short_errors_supported=yes2999+else3000+ _pkg_short_errors_supported=no3001+fi3002+ if test $_pkg_short_errors_supported = yes; then3003+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`3004+ else3005+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`3006+ fi3007+ # Put the nasty error message in config.log where it belongs3008+ echo "$LUA_PKG_ERRORS" >&53009+3010+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53011+$as_echo "no" >&6; }3012+elif test $pkg_failed = untried; then3013+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53014+$as_echo "no" >&6; }3015+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53016+$as_echo "no" >&6; }3017+else3018+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3019+ LUA_LIBS=$pkg_cv_LUA_LIBS3020+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53021+$as_echo "yes" >&6; }3022+ LUA_VER=0x0500003023+fi3024+3025+elif test $pkg_failed = untried; then3026+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53027+$as_echo "no" >&6; }3028+3029+pkg_failed=no3030+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&53031+$as_echo_n "checking for LUA... " >&6; }3032+3033+if test -n "$LUA_CFLAGS"; then3034+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"3035+ elif test -n "$PKG_CONFIG"; then3036+ if test -n "$PKG_CONFIG" && \3037+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&53038+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&53039+ ac_status=$?3040+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&53041+ test $ac_status = 0; }; then3042+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`3043+else3044+ pkg_failed=yes3045+fi3046+ else3047+ pkg_failed=untried3048+fi3049+if test -n "$LUA_LIBS"; then3050+ pkg_cv_LUA_LIBS="$LUA_LIBS"3051+ elif test -n "$PKG_CONFIG"; then3052+ if test -n "$PKG_CONFIG" && \3053+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&53054+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&53055+ ac_status=$?3056+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&53057+ test $ac_status = 0; }; then3058+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`3059+else3060+ pkg_failed=yes3061+fi3062+ else3063+ pkg_failed=untried3064+fi3065+3066+3067+3068+if test $pkg_failed = yes; then3069+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53070+$as_echo "no" >&6; }3071+3072+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then3073+ _pkg_short_errors_supported=yes3074+else3075+ _pkg_short_errors_supported=no3076+fi3077+ if test $_pkg_short_errors_supported = yes; then3078+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`3079+ else3080+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`3081+ fi3082+ # Put the nasty error message in config.log where it belongs3083+ echo "$LUA_PKG_ERRORS" >&53084+3085+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53086+$as_echo "no" >&6; }3087+elif test $pkg_failed = untried; then3088+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53089+$as_echo "no" >&6; }3090+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53091+$as_echo "no" >&6; }3092+else3093+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3094+ LUA_LIBS=$pkg_cv_LUA_LIBS3095+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53096+$as_echo "yes" >&6; }3097+ LUA_VER=0x0500003098+fi3099+3100+else3101+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3102+ LUA_LIBS=$pkg_cv_LUA_LIBS3103+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53104+$as_echo "yes" >&6; }3105+ LUA_VER=0x0500003106+fi3107+3108+elif test $pkg_failed = untried; then3109+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53110+$as_echo "no" >&6; }3111+3112+pkg_failed=no3113+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&53114+$as_echo_n "checking for LUA... " >&6; }3115+3116+if test -n "$LUA_CFLAGS"; then3117+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"3118+ elif test -n "$PKG_CONFIG"; then3119+ if test -n "$PKG_CONFIG" && \3120+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&53121+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&53122+ ac_status=$?3123+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&53124+ test $ac_status = 0; }; then3125+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`3126+else3127+ pkg_failed=yes3128+fi3129+ else3130+ pkg_failed=untried3131+fi3132+if test -n "$LUA_LIBS"; then3133+ pkg_cv_LUA_LIBS="$LUA_LIBS"3134+ elif test -n "$PKG_CONFIG"; then3135+ if test -n "$PKG_CONFIG" && \3136+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua50 >= 5.0.0 lua50 < 5.1.0\""; } >&53137+ ($PKG_CONFIG --exists --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0") 2>&53138+ ac_status=$?3139+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&53140+ test $ac_status = 0; }; then3141+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua50 >= 5.0.0 lua50 < 5.1.0" 2>/dev/null`3142+else3143+ pkg_failed=yes3144+fi3145+ else3146+ pkg_failed=untried3147+fi3148+3149+3150+3151+if test $pkg_failed = yes; then3152+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53153+$as_echo "no" >&6; }3154+3155+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then3156+ _pkg_short_errors_supported=yes3157+else3158+ _pkg_short_errors_supported=no3159+fi3160+ if test $_pkg_short_errors_supported = yes; then3161+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`3162+ else3163+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua50 >= 5.0.0 lua50 < 5.1.0" 2>&1`3164+ fi3165+ # Put the nasty error message in config.log where it belongs3166+ echo "$LUA_PKG_ERRORS" >&53167+3168+3169+pkg_failed=no3170+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&53171+$as_echo_n "checking for LUA... " >&6; }3172+3173+if test -n "$LUA_CFLAGS"; then3174+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"3175+ elif test -n "$PKG_CONFIG"; then3176+ if test -n "$PKG_CONFIG" && \3177+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&53178+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&53179+ ac_status=$?3180+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&53181+ test $ac_status = 0; }; then3182+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`3183+else3184+ pkg_failed=yes3185+fi3186+ else3187+ pkg_failed=untried3188+fi3189+if test -n "$LUA_LIBS"; then3190+ pkg_cv_LUA_LIBS="$LUA_LIBS"3191+ elif test -n "$PKG_CONFIG"; then3192+ if test -n "$PKG_CONFIG" && \3193+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&53194+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&53195+ ac_status=$?3196+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&53197+ test $ac_status = 0; }; then3198+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`3199+else3200+ pkg_failed=yes3201+fi3202+ else3203+ pkg_failed=untried3204+fi3205+3206+3207+3208+if test $pkg_failed = yes; then3209+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53210+$as_echo "no" >&6; }3211+3212+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then3213+ _pkg_short_errors_supported=yes3214+else3215+ _pkg_short_errors_supported=no3216+fi3217+ if test $_pkg_short_errors_supported = yes; then3218+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`3219+ else3220+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`3221+ fi3222+ # Put the nasty error message in config.log where it belongs3223+ echo "$LUA_PKG_ERRORS" >&53224+3225+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53226+$as_echo "no" >&6; }3227+elif test $pkg_failed = untried; then3228+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53229+$as_echo "no" >&6; }3230+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53231+$as_echo "no" >&6; }3232+else3233+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3234+ LUA_LIBS=$pkg_cv_LUA_LIBS3235+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53236+$as_echo "yes" >&6; }3237+ LUA_VER=0x0500003238+fi3239+3240+elif test $pkg_failed = untried; then3241+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53242+$as_echo "no" >&6; }3243+3244+pkg_failed=no3245+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&53246+$as_echo_n "checking for LUA... " >&6; }3247+3248+if test -n "$LUA_CFLAGS"; then3249+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"3250+ elif test -n "$PKG_CONFIG"; then3251+ if test -n "$PKG_CONFIG" && \3252+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&53253+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&53254+ ac_status=$?3255+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&53256+ test $ac_status = 0; }; then3257+ pkg_cv_LUA_CFLAGS=`$PKG_CONFIG --cflags "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`3258+else3259+ pkg_failed=yes3260+fi3261+ else3262+ pkg_failed=untried3263+fi3264+if test -n "$LUA_LIBS"; then3265+ pkg_cv_LUA_LIBS="$LUA_LIBS"3266+ elif test -n "$PKG_CONFIG"; then3267+ if test -n "$PKG_CONFIG" && \3268+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua >= 5.0.0 lua < 5.1.0\""; } >&53269+ ($PKG_CONFIG --exists --print-errors "lua >= 5.0.0 lua < 5.1.0") 2>&53270+ ac_status=$?3271+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&53272+ test $ac_status = 0; }; then3273+ pkg_cv_LUA_LIBS=`$PKG_CONFIG --libs "lua >= 5.0.0 lua < 5.1.0" 2>/dev/null`3274+else3275+ pkg_failed=yes3276+fi3277+ else3278+ pkg_failed=untried3279+fi3280+3281+3282+3283+if test $pkg_failed = yes; then3284+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53285+$as_echo "no" >&6; }3286+3287+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then3288+ _pkg_short_errors_supported=yes3289+else3290+ _pkg_short_errors_supported=no3291+fi3292+ if test $_pkg_short_errors_supported = yes; then3293+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`3294+ else3295+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua >= 5.0.0 lua < 5.1.0" 2>&1`3296+ fi3297+ # Put the nasty error message in config.log where it belongs3298+ echo "$LUA_PKG_ERRORS" >&53299+3300+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53301+$as_echo "no" >&6; }3302+elif test $pkg_failed = untried; then3303+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53304+$as_echo "no" >&6; }3305+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53306+$as_echo "no" >&6; }3307+else3308+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3309+ LUA_LIBS=$pkg_cv_LUA_LIBS3310+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53311+$as_echo "yes" >&6; }3312+ LUA_VER=0x0500003313+fi3314+3315+else3316+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3317+ LUA_LIBS=$pkg_cv_LUA_LIBS3318+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53319+$as_echo "yes" >&6; }3320+ LUA_VER=0x0500003321+fi3322+3323+else3324+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3325+ LUA_LIBS=$pkg_cv_LUA_LIBS3326+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53327+$as_echo "yes" >&6; }3328+ LUA_VER=0x0501003329+fi3330+3331+else3332+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3333+ LUA_LIBS=$pkg_cv_LUA_LIBS3334+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53335+$as_echo "yes" >&6; }3336+ LUA_VER=0x0501003337+fi3338+3339+elif test $pkg_failed = untried; then3340+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&53341+$as_echo "no" >&6; }3342+3343+pkg_failed=no3344+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&53345+$as_echo_n "checking for LUA... " >&6; }3346+3347+if test -n "$LUA_CFLAGS"; then3348+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"3349+ elif test -n "$PKG_CONFIG"; then3350+ if test -n "$PKG_CONFIG" && \3351{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1.0\""; } >&53352($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1.0") 2>&53353ac_status=$?3354@@ -29486,6 +32830,22 @@3355$as_echo "yes" >&6; }3356LUA_VER=0x0501003357fi3358+3359+else3360+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3361+ LUA_LIBS=$pkg_cv_LUA_LIBS3362+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53363+$as_echo "yes" >&6; }3364+ LUA_VER=0x0502003365+fi3366+3367+else3368+ LUA_CFLAGS=$pkg_cv_LUA_CFLAGS3369+ LUA_LIBS=$pkg_cv_LUA_LIBS3370+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&53371+$as_echo "yes" >&6; }3372+ LUA_VER=0x0502003373+fi3374if (test "$LUA_VER" = "0x050000"); then33753376pkg_failed=no3377diff -Naur celestia-1.6.1.orig/src/celengine/scriptorbit.cpp celestia-1.6.1/src/celengine/scriptorbit.cpp3378--- celestia-1.6.1.orig/src/celengine/scriptorbit.cpp 2011-06-05 18:11:09.000000000 +02003379+++ celestia-1.6.1/src/celengine/scriptorbit.cpp 2013-08-22 06:31:25.112482528 +02003380@@ -73,8 +73,7 @@33813382if (!moduleName.empty())3383{3384- lua_pushstring(luaState, "require");3385- lua_gettable(luaState, LUA_GLOBALSINDEX);3386+ lua_getglobal(luaState, "require");3387if (!lua_isfunction(luaState, -1))3388{3389clog << "Cannot load ScriptedOrbit package: 'require' function is unavailable\n";3390@@ -92,8 +91,7 @@3391}33923393// Get the orbit generator function3394- lua_pushstring(luaState, funcName.c_str());3395- lua_gettable(luaState, LUA_GLOBALSINDEX);3396+ lua_getglobal(luaState, funcName.c_str());33973398if (lua_isfunction(luaState, -1) == 0)3399{3400@@ -157,9 +155,8 @@3401luaOrbitObjectName = GenerateScriptObjectName();34023403// Attach the name to the script orbit3404- lua_pushstring(luaState, luaOrbitObjectName.c_str());3405lua_pushvalue(luaState, -2); // dup the orbit object on top of stack3406- lua_settable(luaState, LUA_GLOBALSINDEX);3407+ lua_setglobal(luaState, luaOrbitObjectName.c_str());34083409// Now, call orbit object methods to get the bounding radius3410// and valid time range.3411@@ -206,8 +203,7 @@3412{3413Point3d pos(0.0, 0.0, 0.0);34143415- lua_pushstring(luaState, luaOrbitObjectName.c_str());3416- lua_gettable(luaState, LUA_GLOBALSINDEX);3417+ lua_getglobal(luaState, luaOrbitObjectName.c_str());3418if (lua_istable(luaState, -1))3419{3420lua_pushstring(luaState, "position");3421diff -Naur celestia-1.6.1.orig/src/celengine/scriptrotation.cpp celestia-1.6.1/src/celengine/scriptrotation.cpp3422--- celestia-1.6.1.orig/src/celengine/scriptrotation.cpp 2011-06-05 18:11:09.000000000 +02003423+++ celestia-1.6.1/src/celengine/scriptrotation.cpp 2013-08-22 06:31:25.112482528 +02003424@@ -74,8 +74,7 @@34253426if (!moduleName.empty())3427{3428- lua_pushstring(luaState, "require");3429- lua_gettable(luaState, LUA_GLOBALSINDEX);3430+ lua_getglobal(luaState, "require");3431if (!lua_isfunction(luaState, -1))3432{3433clog << "Cannot load ScriptedRotation package: 'require' function is unavailable\n";3434@@ -93,8 +92,7 @@3435}34363437// Get the rotation generator function3438- lua_pushstring(luaState, funcName.c_str());3439- lua_gettable(luaState, LUA_GLOBALSINDEX);3440+ lua_getglobal(luaState, funcName.c_str());34413442if (lua_isfunction(luaState, -1) == 0)3443{3444@@ -131,9 +129,8 @@3445luaRotationObjectName = GenerateScriptObjectName();34463447// Attach the name to the script rotation3448- lua_pushstring(luaState, luaRotationObjectName.c_str());3449lua_pushvalue(luaState, -2); // dup the rotation object on top of stack3450- lua_settable(luaState, LUA_GLOBALSINDEX);3451+ lua_setglobal(luaState, luaRotationObjectName.c_str());34523453// Get the rest of the rotation parameters; they are all optional.3454period = SafeGetLuaNumber(luaState, -1, "period", 0.0);3455@@ -160,8 +157,7 @@3456{3457if (tjd != lastTime || !cacheable)3458{3459- lua_pushstring(luaState, luaRotationObjectName.c_str());3460- lua_gettable(luaState, LUA_GLOBALSINDEX);3461+ lua_getglobal(luaState, luaRotationObjectName.c_str());3462if (lua_istable(luaState, -1))3463{3464lua_pushstring(luaState, "orientation");3465diff -Naur celestia-1.6.1.orig/src/celestia/celx.cpp celestia-1.6.1/src/celestia/celx.cpp3466--- celestia-1.6.1.orig/src/celestia/celx.cpp 2011-06-05 18:11:13.000000000 +02003467+++ celestia-1.6.1/src/celestia/celx.cpp 2013-08-22 06:31:25.114482561 +02003468@@ -51,6 +51,10 @@3469#include "celx.h"3470#include "celestiacore.h"34713472+#ifndef lua_open3473+#define lua_open() luaL_newstate()3474+#endif3475+3476using namespace std;34773478const char* CelxLua::ClassNames[] =3479@@ -294,14 +298,7 @@34803481static void getField(lua_State* l, int index, const char* key)3482{3483- // When we move to Lua 5.1, this will be replaced by:3484- // lua_getfield(l, index, key);3485- lua_pushstring(l, key);3486-3487- if (index != LUA_GLOBALSINDEX && index != LUA_REGISTRYINDEX)3488- lua_gettable(l, index - 1);3489- else3490- lua_gettable(l, index);3491+ lua_getfield(l, index, key);3492}349334943495@@ -583,8 +580,7 @@3496lua_pop(state,1);3497}3498}3499- lua_pushstring(costate, CleanupCallback);3500- lua_gettable(costate, LUA_GLOBALSINDEX);3501+ lua_getglobal(costate, CleanupCallback);3502if (lua_isnil(costate, -1))3503{3504return;3505@@ -654,7 +650,11 @@3506// luaL_error(L, "too many arguments to resume");3507lua_xmove(L, co, narg);35083509+#if LUA_VER >= 0x0502003510+ status = lua_resume(co, NULL, narg);3511+#else3512status = lua_resume(co, narg);3513+#endif3514#if LUA_VER >= 0x0501003515if (status == 0 || status == LUA_YIELD)3516#else3517@@ -768,8 +768,7 @@3518int stack_top = lua_gettop(costate);3519#endif3520bool result = true;3521- lua_pushstring(costate, KbdCallback);3522- lua_gettable(costate, LUA_GLOBALSINDEX);3523+ lua_getglobal(costate, KbdCallback);3524lua_pushstring(costate, c_p);3525timeout = getTime() + 1.0;3526if (lua_pcall(costate, 1, 1, 0) != 0)3527@@ -961,8 +960,11 @@3528lua_pushstring(state, streamname.c_str());3529lua_settable(state, LUA_REGISTRYINDEX);3530}3531-3532+#if LUA_VER >= 0x0502003533+ int status = lua_load(state, readStreamChunk, &info, streamname.c_str(), NULL);3534+#else3535int status = lua_load(state, readStreamChunk, &info, streamname.c_str());3536+#endif3537if (status != 0)3538cout << "Error loading script: " << lua_tostring(state, -1) << '\n';35393540@@ -3157,8 +3159,7 @@3541if (lua_toboolean(l, 2))3542{3543// Check for existence of charEntered:3544- lua_pushstring(l, KbdCallback);3545- lua_gettable(l, LUA_GLOBALSINDEX);3546+ lua_getglobal(l, KbdCallback);3547if (lua_isnil(l, -1))3548{3549Celx_DoError(l, "script requested keyboard, but did not provide callback");3550@@ -3559,16 +3560,14 @@3551return false;3552}35533554- lua_pushstring(state, "KM_PER_MICROLY");3555lua_pushnumber(state, (lua_Number)KM_PER_LY/1e6);3556- lua_settable(state, LUA_GLOBALSINDEX);3557+ lua_setglobal(state, "KM_PER_MICROLY");35583559loadLuaLibs(state);35603561// Create the celestia object3562- lua_pushstring(state, "celestia");3563celestia_new(state, appCore);3564- lua_settable(state, LUA_GLOBALSINDEX);3565+ lua_setglobal(state, "celestia");3566// add reference to appCore in the registry3567lua_pushstring(state, "celestia-appcore");3568lua_pushlightuserdata(state, static_cast<void*>(appCore));3569@@ -3604,7 +3603,7 @@3570void LuaState::setLuaPath(const string& s)3571{3572#if LUA_VER >= 0x0501003573- lua_getfield(state, LUA_GLOBALSINDEX, "package");3574+ lua_getglobal(state, "package");3575lua_pushstring(state, s.c_str());3576lua_setfield(state, -2, "path");3577lua_pop(state, 1);3578@@ -4118,7 +4117,7 @@3579openLuaLibrary(state, LUA_LOADLIBNAME, luaopen_package);35803581// Disallow loadlib3582- lua_getfield(state, LUA_GLOBALSINDEX, "package");3583+ lua_getglobal(state, "package");3584lua_pushnil(state);3585lua_setfield(state, -2, "loadlib");3586lua_pop(state, 1);3587diff -Naur celestia-1.6.1.orig/src/celestia/celx_gl.cpp celestia-1.6.1/src/celestia/celx_gl.cpp3588--- celestia-1.6.1.orig/src/celestia/celx_gl.cpp 2011-06-05 18:11:13.000000000 +02003589+++ celestia-1.6.1/src/celestia/celx_gl.cpp 2013-08-22 06:31:25.114482561 +02003590@@ -221,7 +221,6 @@3591void LoadLuaGraphicsLibrary(lua_State* l)3592{3593CelxLua celx(l);3594- lua_pushstring(l, "gl");3595lua_newtable(l);35963597celx.registerMethod("Frustum", gl_Frustum);3598@@ -259,11 +258,10 @@3599celx.registerValue("NEAREST", GL_NEAREST);3600celx.registerValue("SRC_ALPHA", GL_SRC_ALPHA);3601celx.registerValue("ONE_MINUS_SRC_ALPHA", GL_ONE_MINUS_SRC_ALPHA);3602- lua_settable(l, LUA_GLOBALSINDEX);3603+ lua_setglobal(l, "gl");36043605- lua_pushstring(l, "glu");3606lua_newtable(l);3607celx.registerMethod("LookAt", glu_LookAt);3608celx.registerMethod("Ortho2D", glu_Ortho2D);3609- lua_settable(l, LUA_GLOBALSINDEX);3610+ lua_setglobal(l, "glu");3611}361236133614