其他分享
首页 > 其他分享> > android-在Mac(NDK)中生成电报源时出错

android-在Mac(NDK)中生成电报源时出错

作者:互联网

我正在尝试在OS X El Capitan中构建电报源,但看到此错误.

我尝试安装NDK,CMake,LLDB.

我在Android Studio 2,Android Studio 3中尝试过.

我试图将它们添加到〜/ .bash_profile中:

export ANDROID_SDK=/Users/aaa/Library/Android/sdk
export ANDROID_NDK=/Users/aaa/Library/Android/sdk/ndk-bundle
export PATH="$PATH:$ANDROID_SDK/tools:$ANDROID_SDK/platform-tools:$ANDROID_NDK"

但是我仍然遇到与其他NDK项目相同的错误,但仍然有错误.

我试图在pastebin.com中上载完整的日志,…但是我无法将总大小设为7mb.我在服务器中上传,链接为:https://static.sajadabasi.ir/ask.txt

错误(时间太长,所以我发布了一些包含错误的部分,希望对您有用).:

    External Native Build Issues
    Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=x86 NDK_ALL_ABIS=x86 NDK_DEBUG=0 APP_PLATFORM=android-16 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/foss/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/foss/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/foss/lib/x86/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/foss/lib/x86/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/foss/lib/x86/gdb.setup
    mkdir -p /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/foss/obj/local/x86/objs/tmessages.27/./opus/src
     Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=armeabi-v7a NDK_ALL_ABIS=armeabi-v7a NDK_DEBUG=0 APP_PLATFORM=android-16 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/foss/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/foss/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/foss/lib/armeabi-v7a/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/foss/lib/armeabi-v7a/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/foss/lib/armeabi-v7a/gdb.setup
    mkdir -p /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/foss/obj/local/armeabi-v7a/objs/tmessages.27/./opus/src
     echo [armeabi-v7a] "Compile arm    ": "tmessages.27 <= IntroRenderer.c"
    Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=x86 NDK_ALL_ABIS=x86 NDK_DEBUG=1 APP_PLATFORM=android-16 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/debug/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/debug/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/debug/lib/x86/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/debug/lib/x86/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/debug/lib/x86/gdb.setup
    Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=x86 NDK_ALL_ABIS=x86 NDK_DEBUG=0 APP_PLATFORM=android-16 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/release/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/release/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/release/lib/x86/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/release/lib/x86/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/fat/release/lib/x86/gdb.setup
    echo [x86] "Compile++      ": "tmessages.27 <= NativeLoader.cpp"
    Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=armeabi-v7a NDK_ALL_ABIS=armeabi-v7a NDK_DEBUG=1 APP_PLATFORM=android-23 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/debug/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/debug/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/debug/lib/armeabi-v7a/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/debug/lib/armeabi-v7a/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/debug/lib/armeabi-v7a/gdb.setup
    mkdir -p /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/debug/lib/armeabi-v7a
      echo [armeabi-v7a] "Compile++ arm  ": "tmessages.27 <= NativeLoader.cpp"
    Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=armeabi-v7a NDK_ALL_ABIS=armeabi-v7a NDK_DEBUG=0 APP_PLATFORM=android-23 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/foss/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/foss/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/foss/lib/armeabi-v7a/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/foss/lib/armeabi-v7a/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/foss/lib/armeabi-v7a/gdb.setup
    mkdir -p /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7_SDK23/foss/obj/local/armeabi-v7a/objs/tmessages.27/./opus/src
       echo [armeabi-v7a] "Compile arm    ": "tmessages.27 <= mlp_data.c"
     Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=x86 NDK_ALL_ABIS=x86 NDK_DEBUG=0 APP_PLATFORM=android-23 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/foss/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/foss/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/foss/lib/x86/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/foss/lib/x86/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/foss/lib/x86/gdb.setup
  echo [x86] "Compile++      ": "tmessages.27 <= rotate_gcc.cc"
    lt/darwin-x86_64/bin/i686-linux-android-g++ -MMD -MP -MF /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/foss/obj/local/x86/objs/tmessages.27/./libyuv/source/rotate_gcc.o.d -ffunction-sections -funwind-tables -no-canonical-prefixes  -g -fstack-protector-strong -fno-exceptions -fno-rtti -O2 -DNDEBUG  -I./jni/opus/include -I./jni/opus/silk -I./jni/opus/silk/fixed -I./jni/opus/celt -I./jni/opus/ -I./jni/opus/opusfile -I./jni/libyuv/include -I./jni/boringssl/include -I./jni/breakpad/common/android/include -I./jni/breakpad -I./jni/ffmpeg/include -I./jni/intro -I/Users/aaa/Library/Android/sdk/ndk-bundle/sources/cxx-stl/gnu-libstdc++/4.9/include -I/Users/aaa/Library/Android/sdk/ndk-bundle/sources/cxx-stl/gnu-libstdc++/4.9/libs/x86/include -I/Users/aaa/Library/Android/sdk/ndk-bundle/sources/cxx-stl/gnu-libstdc++/4.9/include/backward -I/Users/aaa/Library/Android/sdk/ndk-bundle/sources/android/cpufeatures -I/Users/aaa/Library/Android/sdk/ndk-bundle/sources/cxx-stl/gnu-libstdc++/4.9/include -I/Users/aaa/Library/Android/sdk/ndk-bundle/sources/cxx-stl/gnu-libstdc++/4.9/libs/x86/include -I/Users/aaa/Library/Android/sdk/ndk-bundle/sources/cxx-stl/gnu-libstdc++/4.9/include/backward -I/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni     -DANDROID -w -std=c11 -Os -DNULL=0 -DSOCKLEN_T=socklen_t -DLOCALE_NOT_USED -D_LARGEFILE_SOURCE=1 -D_FILE_OFFSET_BITS=64 -Drestrict='' -D__EMX__ -DOPUS_BUILD -DFIXED_POINT -DUSE_ALLOCA -DHAVE_LRINT -DHAVE_LRINTF -fno-math-errno -DANDROID_NDK -DDISABLE_IMPORTGL -fno-strict-aliasing -fprefetch-loop-arrays -DAVOID_TABLES -DANDROID_TILE_BASED_DECODE -DANDROID_ARMV6_IDCT -ffast-math -D__STDC_CONSTANT_MACROS -Dx86fix -D__ANDROID_API__=14 -Wa,--noexecstack -Wformat -Werror=format-security -mstackrealign -mstack-protector-guard=global -DBSD=1 -ffast-math -Os -funroll-loops -std=c++11 -Dx86fix -frtti -fexceptions  --sysroot /Users/aaa/Library/Android/sdk/ndk-bundle/sysroot -isystem /Users/aaa/Library/Android/sdk/ndk-bundle/sysroot/usr/include/i686-linux-android -c  /Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/./libyuv/source/rotate_gcc.cc -o /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/foss/obj/local/x86/objs/tmessages.27/./libyuv/source/rotate_gcc.o
      mkdir -p /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/foss/obj/local/x86/objs/tmessages.27/.
    echo [x86] "Compile++      ": "tmessages.27 <= NativeLoader.cpp"
    Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=x86 NDK_ALL_ABIS=x86 NDK_DEBUG=0 APP_PLATFORM=android-16 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/release/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/release/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/release/lib/x86/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/release/lib/x86/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/release/lib/x86/gdb.setup
    mkdir -p /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/release/obj/local/x86/objs/tmessages.27/./opus/src
    echo [x86] "Compile        ": "tmessages.27 <= opus.c"
    Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=armeabi-v7a NDK_ALL_ABIS=armeabi-v7a NDK_DEBUG=0 APP_PLATFORM=android-16 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/release/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/release/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/release/lib/armeabi-v7a/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/release/lib/armeabi-v7a/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/release/lib/armeabi-v7a/gdb.setup
    mkdir -p /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/armv7/release/obj/local/armeabi-v7a/objs/tmessages.27/./opus/src
    echo [armeabi-v7a] "Compile++ arm  ": "tmessages.27 <= NativeLoader.cpp"
    Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=x86 NDK_ALL_ABIS=x86 NDK_DEBUG=0 APP_PLATFORM=android-16 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/foss/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/foss/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/foss/lib/x86/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/foss/lib/x86/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/foss/lib/x86/gdb.setup
    mkdir -p /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86/foss/obj/local/x86/objs/tmessages.27/./opus/src
   echo [x86] "Compile++      ": "tmessages.27 <= NativeLoader.cpp"
    Build command failed.
    Error while executing process /Users/aaa/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/aaa/Downloads/Telegram-master/TMessagesProj/jni/Application.mk APP_ABI=x86 NDK_ALL_ABIS=x86 NDK_DEBUG=1 APP_PLATFORM=android-23 NDK_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/debug/obj NDK_LIBS_OUT=/Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/debug/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-14 APP_SHORT_COMMANDS=false LOCAL_SHORT_COMMANDS=false -B -n}
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/debug/lib/x86/*
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/debug/lib/x86/gdbserver
    rm -f /Users/aaa/Downloads/Telegram-master/TMessagesProj/build/intermediates/ndkBuild/x86_SDK23/debug/lib/x86/gdb.setup

解决方法:

我通过这些命令下载了代码,并解决了错误.

git clone git@github.com:DrKLO/Telegram.git
git submodule update --init --recursive

标签:telegram,android-ndk,ndk-build,android,macos
来源: https://codeday.me/bug/20191025/1929428.html