这是indexloc提供的服务,不要输入任何密码
Skip to content

Multiple cmake issues when trying to build #1584

@elirnm

Description

@elirnm

I'm trying to build the current version on Windows 11 and running into several problems in the cmake config step. I'm running the following command from the openage\build folder:

cmake -DCMAKE_TOOLCHAIN_FILE=..\vcpkg\scripts\buildsystems\vcpkg.cmake -G "Visual Studio 17 2022" -A x64 -DDOWNLOAD_NYAN=YES -DFLEX_EXECUTABLE=..\flex\win_flex.exe ..

My cmake version is 3.28.0-rc1

The first issue is it failing with

CMake Error at CMakeLists.txt:207 (project):
  VERSION "v0.5.2" format invalid.

It seems to not like the "v" and manually editing the version to just "0.5.2" fixed that problem.

The second issue is it failing with

CMake Error at libopenage/CMakeLists.txt:53 (find_package):
  By not providing "Findtoml11.cmake" in CMAKE_MODULE_PATH this project has
  asked CMake to find a package configuration file provided by "toml11", but
  CMake did not find one.

  Could not find a package configuration file provided by "toml11" with any
  of the following names:

    toml11Config.cmake
    toml11-config.cmake

  Add the installation prefix of "toml11" to CMAKE_PREFIX_PATH or set
  "toml11_DIR" to a directory containing one of the above files.  If "toml11"
  provides a separate development package or SDK, be sure it has been
  installed.


-- Configuring incomplete, errors occurred!

I have toml11 installed in vcpkg but cmake isn't seeing that and I can't figure out how to make it do so. I tried adding the directory to -DCMAKE_PREFIX_PATH and also copying the toml11Config.cmake file to various other folders but always got the same error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: buildsystemRelated to our cmake/python buildsystembugBehaving differently as it should behaveos: windowsWindows-specific issue

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions