mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-12 05:56:28 +00:00
utils/llvm-build: Add trivial quoting of slashes for CMake fragment.
llvm-svn: 143781
This commit is contained in:
parent
af23ffd465
commit
eea4a6ec84
@ -7,6 +7,19 @@ from util import *
|
||||
|
||||
###
|
||||
|
||||
def cmake_quote_string(value):
|
||||
"""
|
||||
cmake_quote_string(value) -> str
|
||||
|
||||
Return a quoted form of the given value that is suitable for use in CMake
|
||||
language files.
|
||||
"""
|
||||
|
||||
# Currently, we only handle escaping backslashes.
|
||||
value = value.replace("\\", "\\\\")
|
||||
|
||||
return value
|
||||
|
||||
def mk_quote_string_for_target(value):
|
||||
"""
|
||||
mk_quote_string_for_target(target_name) -> str
|
||||
@ -388,8 +401,9 @@ class LLVMProjectInfo(object):
|
||||
for dep in dependencies:
|
||||
print >>f, """\
|
||||
configure_file(\"%s\"
|
||||
${CMAKE_CURRENT_BINARY_DIR}/DummyConfigureOutput)""" % (dep,)
|
||||
|
||||
${CMAKE_CURRENT_BINARY_DIR}/DummyConfigureOutput)""" % (
|
||||
cmake_quote_string(dep),)
|
||||
|
||||
f.close()
|
||||
|
||||
def write_make_fragment(self, output_path):
|
||||
|
Loading…
Reference in New Issue
Block a user