尝试在macOS上使用CMake,结果发生了以下情况:ipsw-patch/CMakeLists.txt:19(消息):



这是我第一次在这里发帖,很抱歉我的帖子格式和术语可能不正确。我正试图使用CMake制作一个名为";xpwn";在macOS上。CMakeLists.txt文件包含此

cmake_minimum_required(VERSION 2.6)
project (XPwn)
# We want win32 executables to build staticly by default, since it's more difficult to keep the shared libraries straight on Windows
IF(WIN32)
SET(BUILD_STATIC ON CACHE BOOL "Force compilation with static libraries")
ELSE(WIN32)
SET(BUILD_STATIC OFF CACHE BOOL "Force compilation with static libraries")
ENDIF(WIN32)
IF(BUILD_STATIC)
SET(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
ENDIF(BUILD_STATIC)
include_directories (${PROJECT_SOURCE_DIR}/includes)
add_subdirectory (common)
add_subdirectory (minizip)
add_subdirectory (dmg)
add_subdirectory (hdutil)
add_subdirectory (hfs)
add_subdirectory (ipsw-patch)
add_subdirectory (dfu-util)
add_subdirectory (xpwn)
add_subdirectory (idevice)
add_subdirectory (pwnmetheus2)
add_subdirectory (dripwn)
install(FILES README.markdown DESTINATION . RENAME README.txt)
install(FILES LICENSE DESTINATION . RENAME LICENSE.txt)
IF(WIN32 OR APPLE)
SET(CPACK_GENERATOR "ZIP")
ELSE(WIN32 OR APPLE)
SET(CPACK_GENERATOR "TBZ2")
ENDIF(WIN32 OR APPLE)
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "XPwn")
SET(CPACK_PACKAGE_VENDOR "iPhone Dev Team")
SET(CPACK_PACKAGE_DESCRIPTION_FILE "${PROJECT_SOURCE_DIR}/README.markdown")
SET(CPACK_RESOURCE_FILE_README "${PROJECT_SOURCE_DIR}/README.markdown")
SET(CPACK_RESOURCE_FILE_LICENSE "${PROJECT_SOURCE_DIR}/LICENSE")
SET(CPACK_PACKAGE_VERSION_MAJOR "0")
SET(CPACK_PACKAGE_VERSION_MINOR "5")
SET(CPACK_PACKAGE_VERSION_PATCH "8")
SET(CPACK_PACKAGE_EXECUTABLES "xpwn" "XPwn Pwner")
SET(CPACK_PACKAGE_EXECUTABLES "ipsw" "IPSW Tool")
SET(CPACK_PACKAGE_EXECUTABLES "hdutil" "Apple disk image utility")
SET(CPACK_PACKAGE_EXECUTABLES "dmg" "Apple DMG utility")
SET(CPACK_PACKAGE_EXECUTABLES "hfsplus" "Apple HFS+ utility")
INCLUDE(CPack)

终端吐出

CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 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 Error at ipsw-patch/CMakeLists.txt:19 (message):
libcrypto is required for ipsw!

-- Configuring incomplete, errors occurred!

关于我该如何解决这个问题,有什么想法吗?如果我需要任何其他文件,请告诉我

更新:现在更令人困惑了。。。

CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 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.

-- Found OpenSSL: /usr/local/Cellar/openssl@1.1/1.1.1k/lib/libcrypto.dylib (found version "1.1.1k")  
CMake Error at ipsw-patch/CMakeLists.txt:19 (message):
libcrypto is required for ipsw!

-- Configuring incomplete, errors occurred!

它好像找到了?但它没有?

我也遇到了同样的问题,但它发生在openssl@3上。为了修复它,我只是更改了文件:

  1. /usr/local/lib/libcrypto.dylib
  2. /usr/local/lib/libssl.dylib
  3. /usr/local/include/openssl

链接到openssl@1.1,现在可以编译了。

对我来说,brew自动安装了openssl@3,所以我不得不再次安装openssl才能获得更低的版本。

最新更新