Ich bin auf einen Fehler auf, wenn ich ein neues Projekt in Android Studio aus den Code -Samples (Hallo Jin) öffne. Wenn das Projekt geöffnet wird, wird Folgendes geöffnet: < /p>
Build command failed.
Error while executing process /opt/android-sdk/cmake/3.6.4111459/bin/cmake with arguments {-H/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/src/main/cpp -B/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a -GAndroid Gradle - Ninja -DANDROID_ABI=arm64-v8a -DANDROID_NDK=/opt/android-sdk/ndk-bundle -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/build/intermediates/cmake/arm8/release/obj/arm64-v8a -DCMAKE_BUILD_TYPE=Release -DCMAKE_MAKE_PROGRAM=/opt/android-sdk/cmake/3.6.4111459/bin/ninja -DCMAKE_TOOLCHAIN_FILE=/opt/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_PLATFORM=android-23 -DANDROID_TOOLCHAIN=clang}
-- Check for working C compiler: /opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang
-- Check for working C compiler: /opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang -- broken
-- Configuring incomplete, errors occurred!
See also "/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a/CMakeFiles/CMakeOutput.log".
See also "/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a/CMakeFiles/CMakeError.log".
CMake Error at /opt/android-sdk/cmake/3.6.4111459/share/cmake-3.6/Modules/CMakeTestCCompiler.cmake:61 (message):
The C compiler
"/opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang"
is not able to compile a simple test program.
It fails with the following output:
Change Dir: /home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a/CMakeFiles/CMakeTmp
Run Build Command:"/opt/android-sdk/cmake/3.6.4111459/bin/ninja"
"cmTC_0053d"
[1/2] Building C object CMakeFiles/cmTC_0053d.dir/testCCompiler.c.o
FAILED:
/opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang
--target=aarch64-none-linux-android
--gcc-toolchain=/opt/android-sdk/ndk-bundle/toolchains/aarch64-linux-android-4.9/prebuilt/linux-x86_64
--sysroot=/opt/android-sdk/ndk-bundle/sysroot -isystem
/opt/android-sdk/ndk-bundle/sysroot/usr/include/aarch64-linux-android
-D__ANDROID_API__=23 -g -DANDROID -ffunction-sections -funwind-tables
-fstack-protector-strong -no-canonical-prefixes -Wa,--noexecstack -Wformat
-Werror=format-security -fPIE -o
CMakeFiles/cmTC_0053d.dir/testCCompiler.c.o -c
/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a/CMakeFiles/CMakeTmp/testCCompiler.c
/opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang:
error while loading shared libraries: libncurses.so.5: cannot open shared
object file: No such file or directory
ninja: build stopped: subcommand failed.
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt
< /code>
Dieser Fehler fällt in der iDE < /p>
cmake_minimum_required(VERSION 3.4.1)
add_library(hello-jni SHARED
hello-jni.c)
# Include libraries needed for hello-jni lib
target_link_libraries(hello-jni
android
log)
Ich bin auf einen Fehler auf, wenn ich ein neues Projekt in Android Studio aus den Code -Samples (Hallo Jin) öffne. Wenn das Projekt geöffnet wird, wird Folgendes geöffnet: < /p>
[code]Build command failed. Error while executing process /opt/android-sdk/cmake/3.6.4111459/bin/cmake with arguments {-H/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/src/main/cpp -B/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a -GAndroid Gradle - Ninja -DANDROID_ABI=arm64-v8a -DANDROID_NDK=/opt/android-sdk/ndk-bundle -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/build/intermediates/cmake/arm8/release/obj/arm64-v8a -DCMAKE_BUILD_TYPE=Release -DCMAKE_MAKE_PROGRAM=/opt/android-sdk/cmake/3.6.4111459/bin/ninja -DCMAKE_TOOLCHAIN_FILE=/opt/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_PLATFORM=android-23 -DANDROID_TOOLCHAIN=clang} -- Check for working C compiler: /opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang -- Check for working C compiler: /opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang -- broken -- Configuring incomplete, errors occurred! See also "/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a/CMakeFiles/CMakeOutput.log". See also "/home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a/CMakeFiles/CMakeError.log". CMake Error at /opt/android-sdk/cmake/3.6.4111459/share/cmake-3.6/Modules/CMakeTestCCompiler.cmake:61 (message): The C compiler "/opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang" is not able to compile a simple test program. It fails with the following output: Change Dir: /home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a/CMakeFiles/CMakeTmp Run Build Command:"/opt/android-sdk/cmake/3.6.4111459/bin/ninja" "cmTC_0053d" [1/2] Building C object CMakeFiles/cmTC_0053d.dir/testCCompiler.c.o FAILED: /opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang --target=aarch64-none-linux-android --gcc-toolchain=/opt/android-sdk/ndk-bundle/toolchains/aarch64-linux-android-4.9/prebuilt/linux-x86_64 --sysroot=/opt/android-sdk/ndk-bundle/sysroot -isystem /opt/android-sdk/ndk-bundle/sysroot/usr/include/aarch64-linux-android -D__ANDROID_API__=23 -g -DANDROID -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -Wa,--noexecstack -Wformat -Werror=format-security -fPIE -o CMakeFiles/cmTC_0053d.dir/testCCompiler.c.o -c /home/max/Documents/AndroidStudioProjects/HelloJNI1/app/.externalNativeBuild/cmake/arm8Release/arm64-v8a/CMakeFiles/CMakeTmp/testCCompiler.c /opt/android-sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang: error while loading shared libraries: libncurses.so.5: cannot open shared object file: No such file or directory ninja: build stopped: subcommand failed. CMake will not be able to correctly generate this project. Call Stack (most recent call first): CMakeLists.txt < /code>
Dieser Fehler fällt in der iDE < /p>
cmake_minimum_required(VERSION 3.4.1)
add_library(hello-jni SHARED hello-jni.c)
# Include libraries needed for hello-jni lib target_link_libraries(hello-jni android log) [/code]
Ich versuche, ein altes Projekt mit CMake einzurichten, und ich möchte alle Flaggen genauso wie zuvor halten.
Der alte Projektgenerator verfügt über das Linker -Flag /Subsystem mit minimaler Subystem...
Ich möchte eine Verbindung zu meiner MongoDB -Datenbank herstellen, die in Docker ausgeführt wird. Die Anwendung beginnt anscheinend ohne Probleme, aber wenn ich versuche, eine Anfrage wie einfache...
Ich habe einen Code in einer Testsuite mit Kerberos -Authentifizierung. Diese Tests funktionieren seit Jahren wie erwartet. Da dieses spezielle Update die Funktion ACCEPTSECURITYCONTEXT mit Code...
Ich versuche, OpenCV aus dem Quellcode mit CMake und Visual Studio zu erstellen, aber der Build schlägt mit der folgenden Fehlermeldung fehl:
fatal error LNK1181: cannot open input file...