Skip to content

[wxWidgets] Add webview to find_packages for wxWidgets fails on MacOS #49232

@rmpowell77

Description

@rmpowell77

Operating system

MacOS

Compiler

clang

Steps to reproduce the behavior

Add `webview` to `find_packages` for wxWidgets fails.

  find_package(wxWidgets REQUIRED COMPONENTS net core base gl aui html webview)

Example project is CalChart (https://github.com/calband/calchart/tree/dev/investigate_webview)

Failure logs

Attempting to build:

[main] Building folder: /private/tmp/calchart_webview/calchart.git/build/mac-release 
[build] Starting build
[proc] Executing command: /opt/homebrew/bin/cmake --build /private/tmp/calchart_webview/calchart.git/build/mac-release --
[build] [0/1] Re-running CMake...
[build] -- Running vcpkg install
[build] webview2 is only supported on 'windows & (x86 | x64 | arm64)', which does not match arm64-osx. This usually means that there are known build failures, or runtime problems, when building other platforms. To ignore this and attempt to build webview2 anyway, rerun vcpkg with `--allow-unsupported`.
[build] -- Running vcpkg install - failed
[build] CMake Error at /Users/richardpowell/Development/github.com/microsoft/vcpkg.git/scripts/buildsystems/vcpkg.cmake:953 (message):
[build]   vcpkg install failed.  See logs for more information:
[build]   /tmp/calchart_webview/calchart.git/build/mac-release/vcpkg-manifest-install.log
[build] Call Stack (most recent call first):
[build]   build/mac-release/CMakeFiles/3.28.1/CMakeSystem.cmake:6 (include)
[build]   CMakeLists.txt:16 (project)
[build] 
[build] 
[build] -- Configuring incomplete, errors occurred!
[build] FAILED: [code=1] build.ninja 
[build] /opt/homebrew/Cellar/cmake/3.28.1/bin/cmake --regenerate-during-build -S/tmp/calchart_webview/calchart.git -B/tmp/calchart_webview/calchart.git/build/mac-release
[build] ninja: error: rebuilding 'build.ninja': subcommand failed
[proc] The command: /opt/homebrew/bin/cmake --build /private/tmp/calchart_webview/calchart.git/build/mac-release -- exited with code: 1
[driver] Build completed: 00:00:00.533
[build] Build finished with exit code 1

Additional context

This is likely because the vcpkg assumes that it needs to pull in webview2 for edge compatibility on windows. But Mac/linux do not need this dependency pulled in and will work with webview (1).

Metadata

Metadata

Assignees

No one assigned

    Labels

    category:port-bugThe issue is with a library, which is something the port should already support

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions