Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[libffi] build failure on macOS #16269

Closed
autoantwort opened this issue Feb 17, 2021 · 3 comments · Fixed by #16285
Closed

[libffi] build failure on macOS #16269

autoantwort opened this issue Feb 17, 2021 · 3 comments · Fixed by #16285
Assignees
Labels
category:port-bug The issue is with a library, which is something the port should already support

Comments

@autoantwort
Copy link
Contributor

Host Environment

  • OS: macOS 11 with Apple Silicon
  • Compiler: Apple clang version 12.0.0 (clang-1200.0.32.29)

To Reproduce
Steps to reproduce the behavior:
./vcpkg install libffi

Failure logs

Starting package 83/89: libffi:x64-osx
Building package libffi[core]:x64-osx...
-- Downloading https://github.com/libffi/libffi/archive/v3.3.tar.gz -> libffi-libffi-v3.3.tar.gz...
-- Extracting source /Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/downloads/libffi-libffi-v3.3.tar.gz
-- Applying patch win64-disable-stackframe-check.patch
-- Applying patch win32-disable-stackframe-check.patch
-- Using source at /Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/buildtrees/libffi/src/v3.3-8557367958.clean
-- Configuring x64-osx-dbg
CMake Error at scripts/cmake/vcpkg_execute_required_process.cmake:108 (message):
    Command failed: /Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/downloads/tools/cmake-3.19.2-osx/cmake-3.19.2-macos-universal/CMake.app/Contents/bin/cmake /Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/buildtrees/libffi/src/v3.3-8557367958.clean -DFFI_CONFIG_FILE=/Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/ports/libffi/fficonfig.h -DCMAKE_MAKE_PROGRAM=/Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/downloads/tools/ninja-1.10.1-osx/ninja -DCMAKE_SYSTEM_NAME=Darwin -DBUILD_SHARED_LIBS=OFF -DVCPKG_CHAINLOAD_TOOLCHAIN_FILE=/Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/scripts/toolchains/osx.cmake -DVCPKG_TARGET_TRIPLET=x64-osx -DVCPKG_SET_CHARSET_FLAG=ON -DVCPKG_PLATFORM_TOOLSET=external -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON -DCMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY=ON -DCMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_SKIP=TRUE -DCMAKE_VERBOSE_MAKEFILE=ON -DVCPKG_APPLOCAL_DEPS=OFF -DCMAKE_TOOLCHAIN_FILE=/Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/scripts/buildsystems/vcpkg.cmake -DCMAKE_ERROR_ON_ABSOLUTE_INSTALL_DESTINATION=ON -DVCPKG_CXX_FLAGS= -DVCPKG_CXX_FLAGS_RELEASE= -DVCPKG_CXX_FLAGS_DEBUG= -DVCPKG_C_FLAGS= -DVCPKG_C_FLAGS_RELEASE= -DVCPKG_C_FLAGS_DEBUG= -DVCPKG_CRT_LINKAGE=dynamic -DVCPKG_LINKER_FLAGS= -DVCPKG_LINKER_FLAGS_RELEASE= -DVCPKG_LINKER_FLAGS_DEBUG= -DVCPKG_TARGET_ARCHITECTURE=x64 -DCMAKE_INSTALL_LIBDIR:STRING=lib -DCMAKE_INSTALL_BINDIR:STRING=bin -D_VCPKG_ROOT_DIR=/Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg -D_VCPKG_INSTALLED_DIR=/Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/installed -DVCPKG_MANIFEST_INSTALL=OFF -DCMAKE_OSX_ARCHITECTURES=x86_64 -DFFI_SKIP_HEADERS=ON -G Ninja -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/packages/libffi_x64-osx/debug
    Working Directory: /Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/buildtrees/libffi/x64-osx-dbg
    Error code: 1
    See logs for more information:
      /Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/buildtrees/libffi/config-x64-osx-dbg-out.log
      /Users/leanderSchulten/git_projekte/Lichtsteuerung/vcpkg/buildtrees/libffi/config-x64-osx-dbg-err.log

Call Stack (most recent call first):
  scripts/cmake/vcpkg_configure_cmake.cmake:328 (vcpkg_execute_required_process)
  ports/libffi/portfile.cmake:17 (vcpkg_configure_cmake)
  scripts/ports.cmake:128 (include)


Error: Building package libffi:x64-osx failed with: BUILD_FAILED
Please ensure you're using the latest portfiles with `./vcpkg update`, then
submit an issue at https://github.com/Microsoft/vcpkg/issues including:
  Package: libffi:x64-osx
  Vcpkg version: 2021-01-13-unknownhash

CMakeOutput.log
CMakeError.log
config-x64-osx-dbg-err.log
config-x64-osx-dbg-out.log

@NancyLi1013
Copy link
Contributor

Hi @autoantwort

Thanks for posting this issue.

CMake Error at CMakeLists.txt:17 (message):
  Unknown processor: arm64

set(KNOWN_PROCESSORS x86 x86_64 AMD64 ARM ARM64 i386 armv7l armv7-a aarch64)

Could you please update ARM64 as arm64 in CMakeLists.txt and then try to rebuild libffi?https://github.com/microsoft/vcpkg/blob/master/ports/libffi/CMakeLists.txt#L14

@NancyLi1013 NancyLi1013 added the category:port-bug The issue is with a library, which is something the port should already support label Feb 18, 2021
@autoantwort
Copy link
Contributor Author

Could you please update ARM64 as arm64 in CMakeLists.txt and then try to rebuild libffi?https://github.com/microsoft/vcpkg/blob/master/ports/libffi/CMakeLists.txt#L14

Yes that worked. I have create #16285, can you also look at #16051 :)

@MikeCernea
Copy link

Thank you Nancy, had the same issue as autoantwort and the line #14 fix did the trick for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:port-bug The issue is with a library, which is something the port should already support
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants