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

build: introduce a CMake based build #70

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

compnerd
Copy link
Member

@compnerd compnerd commented Feb 6, 2024

This enables building DocC as a CMake project. Doing so is motivated by toolchain build times. By using CMake instead of SPM, we see an overall reduction of ~7% in the total toolchain build time on Windows.

@compnerd
Copy link
Member Author

@swift-ci please test

@compnerd
Copy link
Member Author

@swift-ci please test

Sources/SymbolKit/CMakeLists.txt Show resolved Hide resolved
#]]

add_library(SymbolKit
Mixin/Mixin+Equals.swift
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have similar concerns as I raised in swiftlang/swift-docc#818 (review) about the ongoing maintenance burden of this separate file list. It is slightly lessened in this repository because it doesn't get updated as frequently but I like if this was automatically kept up-to-date or at least if there was an easy way for another contributor to regenerate this file list based on find Sources/SymbolKit -type f -name "*.swift" | sort or something similar.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is effectively what the list is - but this should only be run on the CI as you may have other sources which are not yet included in the build in your local tree.

@compnerd
Copy link
Member Author

@swift-ci please test

This enables building DocC as a CMake project. Doing so is motivated by
toolchain build times. By using CMake instead of SPM, we see an overall
reduction of ~7% in the total toolchain build time on Windows.
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

Successfully merging this pull request may close these issues.

2 participants