Mac platform under Luajit-2.1.0-beta2 compiled Android I686-linux-android-clang:command not found

Source: Internet
Author: User

When updating Luajit2.1beta2 today, compiling Android has been an error.
/applications/xcode.app/contents/developer/usr/bin/make-c Srcmake[1]:/users/apple/android/android-ndk-r10c// Toolchains/x86-4.9/prebuilt/darwin-x86_64/bin/i686-linux-android-clang:command not foundmake[1]:/Users/apple/ Android/android-ndk-r10c//toolchains/x86-4.9/prebuilt/darwin-x86_64/bin/i686-linux-android-clang:command not FOUNDMAKE[1]:/users/apple/android/android-ndk-r10c//toolchains/x86-4.9/prebuilt/darwin-x86_64/bin/ I686-linux-android-clang:command not foundmake[1]:/users/apple/android/android-ndk-r10c//toolchains/x86-4.9/ Prebuilt/darwin-x86_64/bin/i686-linux-android-clang:command not foundmake[1]:/users/apple/android/ Android-ndk-r10c//toolchains/x86-4.9/prebuilt/darwin-x86_64/bin/i686-linux-android-clang:command not foundmake[1 ]:/users/apple/android/android-ndk-r10c//toolchains/x86-4.9/prebuilt/darwin-x86_64/bin/  I686-linux-android-clang:command not foundmakefile:264: * * * unsupported target architecture. Stop.make: * * * [default] Error 2

Reading the most src/makefile found added to this sentence
Ifeq (windows,$ (findstring windows,$ (OS)) $ (msystem) $ (term))  host_sys= Windows  host_rm= delelse  host_ Sys:= $ (Shell uname-s)  Ifneq (, $ (findstring mingw,$ (Host_sys)))    host_sys= Windows    host_msys= MINGW  endif  Ifneq (, $ (findstring cygwin,$ (Host_sys)))    host_sys= Windows    host_msys= CYGWIN  endif  # Use Clang for OSX host.  Ifeq (darwin,$ (Host_sys))    default_cc= clang  endifendif


Compile the default clang under Mac, NDK is no I686-linux-android-clang,

Modified to the default GCC made a judgment

  # Use Clang for OSX host.  Ifeq (darwin,$ (Host_sys))    Ifneq (Linux, $ (target_sys))      default_cc= clang    endif  endif

Paste the Luajit compilation code




#!/bin/shdir= "$ (CD" $ (dirname "${bash_source[0"} ")" && pwd) "Host_os= ' uname-s | TR "[: Upper:]" "[: Lower:]" ' srcdir= $DIR/srccd "$SRCDIR" ndk= $NDK _rootndkabi=8ndkver= $NDK/toolchains/ arm-linux-androideabi-4.9ndkp= $NDKVER/prebuilt/${host_os}-x86_64/bin/arm-linux-androideabi-ndkf= "--sysroot $NDK /platforms/android-$NDKABI/arch-arm "# Android/arm, Armeabi (ARMv5TE soft-float), Android 2.2+ (Froyo) destdir= $DIR/ Prebuilt/android/armeabirm "$DESTDIR"/*.amake cleanmake host_cc= "Gcc-m32" cross= $NDKP target_sys=linux TARGET_FLAGS= "$NDKF" if [-f $SRCDIR/src/libluajit.a]; Then MV $SRCDIR/src/libluajit.a $DESTDIR/libluajit.afi;# android/arm, armeabi-v7a (ARMv7 VFP), Android 4.0+ (ICS) Ndkarc H= "-march=armv7-a-mfloat-abi=softfp-wl,--fix-cortex-a8" destdir= $DIR/prebuilt/android/armeabi-v7arm "$DESTDIR"/* . Amake cleanmake host_cc= "Gcc-m32" cross= $NDKP target_sys=linux target_flags= "$NDKF $NDKARCH" if [-F $SRCDIR/src/ LIBLUAJIT.A]; Then MV $SRCDIR/src/libluajit.a $DESTDIR/libluajit.afi;# anDroid/x86, x86 (i686 SSE3), Android 4.0+ (ICS) ndkabi=18destdir= $DIR/prebuilt/android/x86ndkver= $NDK/toolchains/ x86-4.9ndkp= $NDKVER/prebuilt/${host_os}-x86_64/bin/i686-linux-android-ndkf= "--sysroot $NDK/platforms/android-$ Ndkabi/arch-x86 "rm" $DESTDIR "/*.amake cleanmake host_cc=" Gcc-m32 "cross= $NDKP target_sys=linux target_flags=" $NDKF " If [-f $SRCDIR/src/libluajit.a]; Then MV $SRCDIR/src/libluajit.a $DESTDIR/libluajit.afi;make Clean



Mac platform under Luajit-2.1.0-beta2 compiled Android I686-linux-android-clang:command not found

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.