Skip to content

test: use llvm-strings instead of strings #19767

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

Merged
merged 1 commit into from
Oct 9, 2018

Conversation

compnerd
Copy link
Member

@compnerd compnerd commented Oct 8, 2018

We should have the LLVM build which provides most of the tools that we need.
strings is amongst them. Add a new llvm-strings substitution from lit and
use that instead of strings. This helps with Windows which does not have a
strings tool.

Replace this paragraph with a description of your changes and rationale. Provide links to external references/discussions if appropriate.

Resolves SR-NNNN.

@compnerd
Copy link
Member Author

compnerd commented Oct 8, 2018

CC: @vedantk @jrose-apple

@compnerd
Copy link
Member Author

compnerd commented Oct 8, 2018

@swift-ci please test

@vedantk
Copy link
Contributor

vedantk commented Oct 8, 2018

LGTM, thanks.

@gottesmm
Copy link
Contributor

gottesmm commented Oct 8, 2018

@vedantk @compnerd I think you need to make this a cmake dependency as well. Here:

https://github.com/apple/swift/blob/25c02ced293e50bd109a347db8fd3fdd5df8877d/test/CMakeLists.txt#L49

@gottesmm
Copy link
Contributor

gottesmm commented Oct 8, 2018

We are generally doing that for all tools that we rely on for our lit testing.

We should have the LLVM build which provides most of the tools that we need.
`strings` is amongst them.  Add a new `llvm-strings` substitution from lit and
use that instead of `strings`.  This helps with Windows which does not have a
`strings` tool.
@compnerd
Copy link
Member Author

compnerd commented Oct 8, 2018

@swift-ci please test and merge

@compnerd
Copy link
Member Author

compnerd commented Oct 8, 2018

@swift-ci please test macOS platform

@compnerd compnerd merged commit 4700241 into swiftlang:master Oct 9, 2018
@compnerd compnerd deleted the strings branch October 9, 2018 01:53
@@ -374,6 +375,7 @@ config.substitutions.append( ('%llvm-dis', config.llvm_dis) )
config.substitutions.append( ('%swift-demangle-yamldump', config.swift_demangle_yamldump) )
config.substitutions.append( ('%Benchmark_O', config.benchmark_o) )
config.substitutions.append( ('%Benchmark_Driver', config.benchmark_driver) )
config.substitutions.append( ('%llvm-strings', config.llvm_strings) )
Copy link
Contributor

@jrose-apple jrose-apple Oct 22, 2018

Choose a reason for hiding this comment

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

Nitpick: Please don't add a substitution for this. The LLVM tools are already in the search path, so you can just say llvm-strings. (We rely on this already for things like not.)

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.

4 participants