java — сборка команды не выполняется, внешние проблемы с андроидом

Я не понимаю, в чем проблема с Android Studio, я делаю новое приложение для Android, поэтому я действительно не понимаю, где ошибка и как ее решить. (Если вам нужно что-то еще, пожалуйста, спросите меня, и я собираюсь поставить Это)

здесь я ошибка:

null
Build command failed.
Error while executing process C:\Users\Raul del Rio\AppData\Local\Android\Sdk\cmake\3.6.4111459\bin\cmake.exe with arguments {-HC:\Users\Raul del Rio\AndroidStudioProjects\MyApplication2\app -BC:\Users\Raul del Rio\AndroidStudioProjects\MyApplication2\app\.externalNativeBuild\cmake\release\armeabi-v7a -DANDROID_ABI=armeabi-v7a -DANDROID_PLATFORM=android-15 -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\Raul del Rio\AndroidStudioProjects\MyApplication2\app\build\intermediates\cmake\release\obj\armeabi-v7a -DCMAKE_BUILD_TYPE=Release -DANDROID_NDK=C:\Users\Raul del Rio\AppData\Local\Android\Sdk\ndk-bundle -DCMAKE_CXX_FLAGS= -DCMAKE_TOOLCHAIN_FILE=C:\Users\Raul del Rio\AppData\Local\Android\Sdk\ndk-bundle\build\cmake\android.toolchain.cmake -DCMAKE_MAKE_PROGRAM=C:\Users\Raul del Rio\AppData\Local\Android\Sdk\cmake\3.6.4111459\bin\ninja.exe -GAndroid Gradle - Ninja}
-- Check for working C compiler: C:/Users/Raul del Rio/AppData/Local/Android/Sdk/ndk-bundle/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe
-- Check for working C compiler: C:/Users/Raul del Rio/AppData/Local/Android/Sdk/ndk-bundle/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe -- broken
C:/Users/Raul del Rio/AndroidStudioProjects/MyApplication2
It fails with the following output:
Change Dir: C:/Users/Raul del Rio/AndroidStudioProjects/MyApplication2/app/.externalNativeBuild/cmake/release/armeabi-v7a/CMakeFiles/CMakeTmp
Run Build Command:"C:/Users/Raul del
Rio/AppData/Local/Android/Sdk/cmake/3.6.4111459/bin/ninja.exe" "cmTC_48907"[1/2] Building C object CMakeFiles/cmTC_48907.dir/testCCompiler.c.o
FAILED:
C:\Users\RAULDE~1\AppData\Local\Android\Sdk\NDK-BU~1\TOOLCH~1\llvm\prebuilt\WINDOW~1\bin\clang.exe
--target=armv7-none-linux-androideabi --gcc-toolchain="C:/Users/Raul del
Rio/AppData/Local/Android/Sdk/ndk-bundle/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64"--sysroot="C:/Users/Raul del
Rio/AppData/Local/Android/Sdk/ndk-bundle/sysroot" -isystem C:/Users/Raul
del
Rio/AppData/Local/Android/Sdk/ndk-bundle/sysroot/usr/include/arm-linux-androideabi
-D__ANDROID_API__=15 -g -DANDROID -ffunction-sections -funwind-tables
-fstack-protector-strong -no-canonical-prefixes -march=armv7-a
-mfloat-abi=softfp -mfpu=vfpv3-d16 -mthumb -Wa,--noexecstack -Wformat
-Werror=format-security -o CMakeFiles/cmTC_48907.dir/testCCompiler.c.o -c
"C:\Users\Raul del
Rio\AndroidStudioProjects\MyApplication2\app\.externalNativeBuild\cmake\release\armeabi-v7a\CMakeFiles\CMakeTmp\testCCompiler.c"error: no such file or directory: 'del'

error: no such file or directory:
'Rio/AppData/Local/Android/Sdk/ndk-bundle/sysroot/usr/include/arm-linux-androideabi'

ninja: build stopped: subcommand failed.
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt
-- Configuring incomplete, errors occurred!
See also "C:/Users/Raul del Rio/AndroidStudioProjects/MyApplication2/app/.externalNativeBuild/cmake/release/armeabi-v7a/CMakeFiles/CMakeOutput.log".
See also "C:/Users/Raul del Rio/AndroidStudioProjects/MyApplication2/app/.externalNativeBuild/cmake/release/armeabi-v7a/CMakeFiles/CMakeError.log".
Build command failed.
Error while executing process C:\Users\Raul del Rio\AppData\Local\Android\Sdk\cmake\3.6.4111459\bin\cmake.exe with arguments {-HC:\Users\Raul del Rio\AndroidStudioProjects\MyApplication2\app -BC:\Users\Raul del Rio\AndroidStudioProjects\MyApplication2\app\.externalNativeBuild\cmake\debug\armeabi-v7a -DANDROID_ABI=armeabi-v7a -DANDROID_PLATFORM=android-15 -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=C:\Users\Raul del Rio\AndroidStudioProjects\MyApplication2\app\build\intermediates\cmake\debug\obj\armeabi-v7a -DCMAKE_BUILD_TYPE=Debug -DANDROID_NDK=C:\Users\Raul del Rio\AppData\Local\Android\Sdk\ndk-bundle -DCMAKE_CXX_FLAGS= -DCMAKE_TOOLCHAIN_FILE=C:\Users\Raul del Rio\AppData\Local\Android\Sdk\ndk-bundle\build\cmake\android.toolchain.cmake -DCMAKE_MAKE_PROGRAM=C:\Users\Raul del Rio\AppData\Local\Android\Sdk\cmake\3.6.4111459\bin\ninja.exe -GAndroid Gradle - Ninja}
-- Check for working C compiler: C:/Users/Raul del Rio/AppData/Local/Android/Sdk/ndk-bundle/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe
-- Check for working C compiler: C:/Users/Raul del Rio/AppData/Local/Android/Sdk/ndk-bundle/toolchains/llvm/prebuilt/windows-x86_64/bin/clang.exe -- broken
It fails with the following output:
Change Dir: C:/Users/Raul del Rio/AndroidStudioProjects/MyApplication2/app/.externalNativeBuild/cmake/debug/armeabi-v7a/CMakeFiles/CMakeTmp
Run Build Command:"C:/Users/Raul del
Rio/AppData/Local/Android/Sdk/cmake/3.6.4111459/bin/ninja.exe" "cmTC_405c9"[1/2] Building C object CMakeFiles/cmTC_405c9.dir/testCCompiler.c.o
FAILED:
C:\Users\RAULDE~1\AppData\Local\Android\Sdk\NDK-BU~1\TOOLCH~1\llvm\prebuilt\WINDOW~1\bin\clang.exe
--target=armv7-none-linux-androideabi --gcc-toolchain="C:/Users/Raul del
Rio/AppData/Local/Android/Sdk/ndk-bundle/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64"--sysroot="C:/Users/Raul del
Rio/AppData/Local/Android/Sdk/ndk-bundle/sysroot" -isystem C:/Users/Raul
del
Rio/AppData/Local/Android/Sdk/ndk-bundle/sysroot/usr/include/arm-linux-androideabi
-D__ANDROID_API__=15 -g -DANDROID -ffunction-sections -funwind-tables
-fstack-protector-strong -no-canonical-prefixes -march=armv7-a
-mfloat-abi=softfp -mfpu=vfpv3-d16 -mthumb -Wa,--noexecstack -Wformat
-Werror=format-security -o CMakeFiles/cmTC_405c9.dir/testCCompiler.c.o -c
"C:\Users\Raul del
Rio\AndroidStudioProjects\MyApplication2\app\.externalNativeBuild\cmake\debug\armeabi-v7a\CMakeFiles\CMakeTmp\testCCompiler.c"error: no such file or directory: 'del'

error: no such file or directory:
'Rio/AppData/Local/Android/Sdk/ndk-bundle/sysroot/usr/include/arm-linux-androideabi'

ninja: build stopped: subcommand failed.
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt
-- Configuring incomplete, errors occurred!
See also "C:/Users/Raul del Rio/AndroidStudioProjects/MyApplication2/app/.externalNativeBuild/cmake/debug/armeabi-v7a/CMakeFiles/CMakeOutput.log".
See also "C:/Users/Raul del Rio/AndroidStudioProjects/MyApplication2/app/.externalNativeBuild/cmake/debug/armeabi-v7a/CMakeFiles/CMakeError.log".

когда я пытался скомпилировать, чтобы начать программировать, это было то, что я получил.

0

Решение

Попробуйте добавить:

externalNativeBuild {
cmake {
arguments '-DBUILD_TESTING=OFF', '-DANDROID_TOOLCHAIN=gcc-4.9'
cppFlags "-std=c++14 -fexceptions -frtti"}
}

в вашем defaultConfig в вашем build.gradle, Это должно заставить Android Studio использовать набор инструментов gcc по умолчанию.

1

Другие решения

Других решений пока нет …

По вопросам рекламы [email protected]