Skip to content

Build error with zstd library when compiling on Windows with Clang #246

Description

@NJ-TR

Description

I'm trying to build MarathonRecomp on Windows 11 using Visual Studio Community 2026 and the Clang compiler, and I ran into an issue while building the libzstd_shared target of the zstd library.

What happens:
The build proceeds to around step 503 out of 869, then fails with:

error : no such file or directory: 'build/MarathonRecomp/tools/XenosRecomp/thirdparty/zstd/build/cmake/../../lib'

The static libzstd_static library builds fine, and all other dependencies compile successfully — only the shared/dynamic target fails because its relative path resolves incorrectly when building from the out/build/... directory.

Steps I've already tried:

  • Ran git submodule update --init --recursive — all zstd files are present and correct
  • Added absolute paths to zstd's lib folder in the root CMakeLists.txt — fixed the main build, but not the libzstd_shared sub-target
  • Fully cleared the CMake cache, deleted the out and .vs folders — the error still repeats

Questions:
Is this a known issue when building on Windows with Clang? Is there a workaround or a small CMake adjustment I can apply locally? Or is there something else I should try?

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions