Vcpkg: [glib] build failure

Created on 18 Nov 2019  路  6Comments  路  Source: microsoft/vcpkg

Host Environment

  • OS: MacOS Catalina 10.15.1
  • Compiler: Apple clang version 11.0.0 (clang-1100.0.33.12)
  • SDK: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk

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

Failure logs

-- Configuring x64-osx-dbg
CMake Error at scripts/cmake/vcpkg_execute_required_process.cmake:72 (message):
    Command failed: /Users/jetbrains/dev/vcpkg/downloads/tools/cmake-3.14.0-osx/cmake-3.14.0-Darwin-x86_64/CMake.app/Contents/bin/cmake /Users/jetbrains/dev/vcpkg/buildtrees/glib/src/2.52.3-34a15219ec -DHAVE_SELINUX=OFF -DGLIB_VERSION=2.52.3 -DCMAKE_MAKE_PROGRAM=/Users/jetbrains/dev/vcpkg/downloads/tools/ninja-1.8.2-osx/ninja -DCMAKE_SYSTEM_NAME=Darwin -DBUILD_SHARED_LIBS=OFF -DVCPKG_CHAINLOAD_TOOLCHAIN_FILE=/Users/jetbrains/dev/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/jetbrains/dev/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_TARGET_ARCHITECTURE=x64 -DCMAKE_INSTALL_LIBDIR:STRING=lib -DCMAKE_INSTALL_BINDIR:STRING=bin -DGLIB_SKIP_HEADERS=ON -DGLIB_SKIP_TOOLS=ON -G Ninja -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/Users/jetbrains/dev/vcpkg/packages/glib_x64-osx/debug
    Working Directory: /Users/jetbrains/dev/vcpkg/buildtrees/glib/x64-osx-dbg
    Error code: 1
    See logs for more information:
      /Users/jetbrains/dev/vcpkg/buildtrees/glib/config-x64-osx-dbg-out.log
      /Users/jetbrains/dev/vcpkg/buildtrees/glib/config-x64-osx-dbg-err.log

>>>  nano "/Users/jetbrains/dev/vcpkg/buildtrees/glib/config-x64-osx-dbg-err.log"
configure: error:
*** You must have either have gettext support in your C library, or use the
*** GNU gettext library. (http://www.gnu.org/software/gettext/gettext.html

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

Additional context
A library gettext has installed via vcpkg successfully.
config-x64-osx-dbg-err.log
config-x64-osx-dbg-out.log
CMakeOutput.log

port-bug

Most helpful comment

I was able to fix by adding the following to ports/glib/CMakeLists.txt :

set(ENV{SDKROOT} ${CMAKE_OSX_SYSROOT})

just before

execute_process(
         COMMAND "${CMAKE_SOURCE_DIR}/configure"

I do not know vcpkg well enough to suggest a correct solution.

All 6 comments

This one is also blocking me atm ...

I have a fix here FYI https://github.com/magicfoo/vcpkg/commit/b3a1ecf8e424b41d6a0875503e9fdce1a06e7a1c
I will refactor soon the whole stack to submit a clean PR

@magicfoo, cool news! Thank you very much!

I was able to fix by adding the following to ports/glib/CMakeLists.txt :

set(ENV{SDKROOT} ${CMAKE_OSX_SYSROOT})

just before

execute_process(
         COMMAND "${CMAKE_SOURCE_DIR}/configure"

I do not know vcpkg well enough to suggest a correct solution.

@magicfoo and @pdc-tstream
Thanks for looking into this issue.
Are you willing to submit a PR to fix this issue?

It's duplicated to #9012. Let's track this issue there.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

cjvaijo picture cjvaijo  路  3Comments

husseinalihazime picture husseinalihazime  路  3Comments

pkeir picture pkeir  路  3Comments

ThinkalVB picture ThinkalVB  路  3Comments

grandprixgp picture grandprixgp  路  3Comments