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

Ninja not found when building a cmake project (assumption that Ninja is already installed.) #20

Open
Diggory opened this issue Sep 29, 2023 · 2 comments

Comments

@Diggory
Copy link

Diggory commented Sep 29, 2023

The code appears to assume that Ninja is already installed, which it won't be unless one is actively developing Swift itself.

...
http://gb.archive.ubuntu.com/ubuntu/pool/main/z/zlib/zlib1g_1.2.11.dfsg-2ubuntu9.2_amd64.deb – 2.2 MB
http://gb.archive.ubuntu.com/ubuntu/pool/main/z/zlib/zlib1g-dev_1.2.11.dfsg-2ubuntu9.2_amd64.deb – 11.6 MB

Unpacking and copying Swift binaries for the host triple...
8455394 blocks

Unpacking Swift distribution for the target triple...

Copying Swift core libraries for the target triple into Swift SDK bundle...

Unpacking and copying `lld` linker...
CMake Deprecation Warning at /private/var/folders/d6/2m5sz0rx573drxq0b25xttl80000gn/T/swift-sdk-generator-169E0B/cmake/Modules/CMakePolicy.cmake:6 (cmake_policy):
  The OLD behavior for policy CMP0114 will be removed from a future version
  of CMake.

  The cmake-policies(7) manual explains that the OLD behaviors of all
  policies are deprecated and that a policy should be set to OLD only under
  specific short-term circumstances.  Projects should be ported to the NEW
  behavior and not rely on setting a policy to OLD.
Call Stack (most recent call first):
  CMakeLists.txt:13 (include)


CMake Error: CMake was unable to find a build program corresponding to "Ninja".  CMAKE_MAKE_PROGRAM is not set.  You probably need to select a different build tool.
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_ASM_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
Error: nonZeroExitCode(1, SwiftSDKGenerator.CommandInfo(command: "PATH=\'/bin:/usr/bin:/usr/local/bin\' cmake -B build -G Ninja -S llvm -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_PROJECTS=lld -DLLVM_TARGETS_TO_BUILD=X86", currentDirectory: Optional("/var/folders/d6/2m5sz0rx573drxq0b25xttl80000gn/T/swift-sdk-generator-169E0B"), file: "/Users/diggory/Code/OpenSource/swift-sdk-generator/Sources/SwiftSDKGenerator/Generator/LocalSwiftSDKGenerator.swift", line: 348))
diggory@MBP-16 swift-sdk-generator % 
@Diggory Diggory changed the title Ninja not found when building a cmake project (assumption that cmake is already installed.) Ninja not found when building a cmake project (assumption that Ninja is already installed.) Sep 29, 2023
@MaxDesiatov
Copy link
Contributor

Would installing ninja from Homebrew work for you as a workaround in the meantime?

@Diggory
Copy link
Author

Diggory commented Sep 29, 2023

Yes, no problem.

MaxDesiatov added a commit that referenced this issue Sep 29, 2023
Marks x86_64 support as host platform, with a footnote clarifying additional build time and requirements.

Partially addresses #20.
MaxDesiatov added a commit that referenced this issue Sep 29, 2023
Marks x86_64 support as host platform, with a footnote clarifying additional build time and requirements.

Partially addresses #20.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants