Android开发GoogleMap遇到的INSTALL_FAILED_MISSING_SHARED_LIBRARY错误

本文介绍了解决Android开发中使用GoogleMap遇到的INSTALL_FAILED_MISSING_SHARED_LIBRARY错误的方法。问题在于选择了错误的API,正确的做法是在创建项目时选择Google API而非Android API。

用Android开发GoogleMap,在运行程序时出现INSTALL_FAILED_MISSING_SHARED_LIBRARY错误,查找资料之后发现问题所在:原来开发GoogleMap时要用到Google的API,解决方法如下:

     在 新建项目的时侯要选择相应的Google  API,而不是 Android API,这样问题就解决了。

The C compiler identification is MSVC 19.44.35215.0 The CXX compiler identification is MSVC 19.44.35215.0 Detecting C compiler ABI info Detecting C compiler ABI info - done Check for working C compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.44.35207/bin/Hostx64/x64/cl.exe - skipped Detecting C compile features Detecting C compile features - done Detecting CXX compiler ABI info Detecting CXX compiler ABI info - done Check for working CXX compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.44.35207/bin/Hostx64/x64/cl.exe - skipped Detecting CXX compile features Detecting CXX compile features - done target changed from "" to "auto" CMake Warning at cmakeFindModules/OptimizeForArchitecture.cmake:170 (message): Your CPU (family 6, model 183) is not known. Auto-detection of optimization flags failed and will use the 65nm Core 2 CPU settings. Call Stack (most recent call first): cmakeFindModules/OptimizeForArchitecture.cmake:229 (AutodetectHostArchitecture) CMakeLists.txt:131 (OptimizeForArchitecture) Detected CPU: merom Performing Test check_c_compiler_flag__arch_SSE2 Performing Test check_c_compiler_flag__arch_SSE2 - Success Performing Test check_cxx_compiler_flag__arch_SSE2 Performing Test check_cxx_compiler_flag__arch_SSE2 - Success Checking for C++11 compiler Checking for C++11 compiler - available Found OpenMP_C: -openmp (found version "2.0") Found OpenMP_CXX: -openmp (found version "2.0") Found OpenMP: TRUE (found version "2.0") Eigen 3.4.0 found (include: E:/openmvg/openMVG/src/third_party/eigen) CoinUtils 2.10.13 found (include: E:/openmvg/openMVG/src/dependencies/osi_clp/CoinUtils/src) Clp 1.16.10 found (include: E:/openmvg/openMVG/src/dependencies/osi_clp/Clp/src) You are attempting to build without Osi. Please use cmake variable -DOSI_INCLUDE_DIR_HINTS:STRING="PATH" or OSI_INCLUDE_DIR_HINTS env. variable to a valid Osi path. Or install last Osi version. CMake Deprecation Warning at dependencies/osi_clp/CMakeLists.txt:6 (CMAKE_MINIMUM_REQUIRED): Compatibility with CMake < 3.5 will be removed from a future version of CMake. Update the VERSION argument <min> value or use a ...<max> suffix to tell CMake that the project does not need compatibility with older versions. Lemon found (include: E:/openmvg/openMVG/src/third_party/lemon/lemon) CMake Warning (dev) at F:/CMake/share/cmake-3.30/Modules/FetchContent.cmake:1373 (message): The DOWNLOAD_EXTRACT_TIMESTAMP option was not given and policy CMP0135 is not set. The policy's OLD behavior will be used. When using a URL download, the timestamps of extracted files should preferably be that of the time of extraction, otherwise code that depends on the extracted contents might not be rebuilt if the URL changes. The OLD behavior preserves the timestamps from the archive instead, but this is usually not what you want. Update your project to the NEW behavior or specify the DOWNLOAD_EXTRACT_TIMESTAMP option with a value of true to avoid this robustness issue. Call Stack (most recent call first): CMakeLists.txt:438 (FetchContent_Declare) This warning is for project developers. Use -Wno-dev to suppress it. Compiler: MSVC 19.44.35215.0 (C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.44.35207/bin/Hostx64/x64/cl.exe) Rerun SDK install version: 0.25.0 CMake Deprecation Warning at third_party/lemon/CMakeLists.txt:1 (CMAKE_MINIMUM_REQUIRED): Compatibility with CMake < 3.5 will be removed from a future version of CMake. Update the VERSION argument <min> value or use a ...<max> suffix to tell CMake that the project does not need compatibility with older versions. CMake Warning (dev) at third_party/lemon/CMakeLists.txt:13 (INCLUDE): Policy CMP0148 is not set: The FindPythonInterp and FindPythonLibs modules are removed. Run "cmake --help-policy CMP0148" for policy details. Use the cmake_policy command to set the policy and suppress this warning. This warning is for project developers. Use -Wno-dev to suppress it. Found PythonInterp: F:/Anaconda3/python.exe (found version "3.12.4") Could NOT find Wget (missing: WGET_EXECUTABLE) Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE) Could NOT find Ghostscript (missing: GHOSTSCRIPT_EXECUTABLE) Could NOT find COIN (missing: COIN_INCLUDE_DIR COIN_CBC_LIBRARY COIN_CBC_SOLVER_LIBRARY COIN_CGL_LIBRARY COIN_CLP_LIBRARY COIN_COIN_UTILS_LIBRARY COIN_OSI_LIBRARY COIN_OSI_CBC_LIBRARY COIN_OSI_CLP_LIBRARY) Looking for sys/types.h Looking for sys/types.h - found Looking for stdint.h Looking for stdint.h - found Looking for stddef.h Looking for stddef.h - found Check size of long long Check size of long long - done CMake Deprecation Warning at third_party/jpeg/CMakeLists.txt:2 (cmake_minimum_required): Compatibility with CMake < 3.5 will be removed from a future version of CMake. Update the VERSION argument <min> value or use a ...<max> suffix to tell CMake that the project does not need compatibility with older versions. Looking for stdlib.h Looking for stdlib.h - found CMake Deprecation Warning at third_party/png/CMakeLists.txt:9 (cmake_minimum_required): Compatibility with CMake < 3.5 will be removed from a future version of CMake. Update the VERSION argument <min> value or use a ...<max> suffix to tell CMake that the project does not need compatibility with older versions. CMake Deprecation Warning at third_party/ceres-solver/CMakeLists.txt:32 (cmake_minimum_required): Compatibility with CMake < 3.5 will be removed from a future version of CMake. Update the VERSION argument <min> value or use a ...<max> suffix to tell CMake that the project does not need compatibility with older versions. CMake Deprecation Warning at third_party/ceres-solver/CMakeLists.txt:33 (cmake_policy): Compatibility with CMake < 3.5 will be removed from a future version of CMake. Update the VERSION argument <min> value or use a ...<max> suffix to tell CMake that the project does not need compatibility with older versions. =============================================================== Ceres-solver configuration. =============================================================== Detected Ceres version: 1.13.0 from E:/openmvg/openMVG/src/third_party/ceres-solver/include/ceres/version.h Eigen 3.4.0 found (include: E:/openmvg/openMVG/src/third_party/eigen) -- Found Eigen version 3.4.0: E:/openmvg/openMVG/src/third_party/eigen =============================================================== Enabling the use of Eigen as a sparse linear algebra library for solving the nonlinear least squares problems. Enabling this option results in an LGPL licensed version of Ceres Solver as the Simplicial Cholesky factorization in Eigen is licensed under the LGPL. =============================================================== Performing Test CMAKE_HAVE_LIBC_PTHREAD Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed Looking for pthread_create in pthreads Looking for pthread_create in pthreads - not found Looking for pthread_create in pthread Looking for pthread_create in pthread - not found Found Threads: TRUE -- Did not find LAPACK library, disabling LAPACK support. -- Did not find BLAS library, disabling LAPACK support. -- Building without SuiteSparse. -- Building without CXSPARSE. -- Google Flags disabled; no tests or tools will be built! -- Compiling minimal glog substitute into Ceres. -- Using minimal glog substitute (include): internal/ceres/miniglog -- Building with OpenMP. Performing Test COMPILER_HAS_CXX11_FLAG Performing Test COMPILER_HAS_CXX11_FLAG - Success Looking for C++ include unordered_map Looking for C++ include unordered_map - found Performing Test HAVE_UNORDERED_MAP_IN_STD_NAMESPACE Performing Test HAVE_UNORDERED_MAP_IN_STD_NAMESPACE - Success -- Found unordered_map/set in std namespace. Looking for C++ include memory Looking for C++ include memory - found Performing Test HAVE_SHARED_PTR_IN_STD_NAMESPACE Performing Test HAVE_SHARED_PTR_IN_STD_NAMESPACE - Success -- Found shared_ptr in std namespace using <memory> header. -- Building Ceres as a static library. Performing Test HAVE_UNDERSCORE_PREFIXED_BESSEL_FUNCTIONS Performing Test HAVE_UNDERSCORE_PREFIXED_BESSEL_FUNCTIONS - Success Creating configured Ceres config.h output directory: D:/Openmvg/third_party/ceres-solver/config/ceres/internal Enabling CERES_USE_EIGEN_SPARSE in Ceres config.h Enabling CERES_NO_LAPACK in Ceres config.h Enabling CERES_NO_SUITESPARSE in Ceres config.h Enabling CERES_NO_CXSPARSE in Ceres config.h Enabling CERES_USE_OPENMP in Ceres config.h Enabling CERES_STD_UNORDERED_MAP in Ceres config.h Enabling CERES_MSVC_USE_UNDERSCORE_PREFIXED_BESSEL_FUNCTIONS in Ceres config.h -- Do not build any example. =============================================================== Ceres-solver configuration end. =============================================================== Configured Eigen 3.4.0 ** Found Qt5, GUI modules will be build Found Sphinx: F:/Anaconda3/Scripts/sphinx-build.exe Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE) Doxygen need to be installed to generate the doxygen documentation ** OpenMVG version: 2.1.0 ** Build Shared libs: OFF ** Build OpenMVG tests: OFF ** Build OpenMVG softwares: ON ** Build OpenMVG GUI softwares: ON ** Build OpenMVG documentation: ON ** Build OpenMVG samples applications: ON ** Build OpenMVG openGL examples: OFF ** Use Rerun logging: ON ** Enable code coverage generation: OFF ** Enable OpenMP parallelization: ON ** Build OpenCV+OpenMVG samples programs: OFF ** Use OpenCV SIFT features: OFF ** Use LiGT for global translation estimation: ON CEREAL: (internal) EIGEN: 3.4.0 (internal) CERES: 1.13.0 (internal) LIBTIFF: 4.5.1 (external) LIBPNG: (internal) LIBJPEG (internal) CLP: 1.16.10 (internal) COINUTILS: 2.10.13 (internal) OSI: (internal) LEMON: 1.3 (internal) Configuring done (47.4s)
最新发布
09-12
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值