Skip to content

Commit 54b014b

Browse files
committed
[llvm-jitlink] Use '@' rather than ':' for separator in -sectcreate.
This should avoid the issue with Windows paths that have caused failures on some builders.
1 parent 39cab1a commit 54b014b

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

llvm/test/ExecutionEngine/JITLink/Generic/sectcreate.test

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# RUN: llc -filetype=obj -o %t.o %S/Inputs/main-ret-0.ll
22
# RUN: llvm-jitlink -noexec \
3-
# RUN: -sectcreate __data,%S/Inputs/sectcreate-data.txt:foo=0 \
3+
# RUN: -sectcreate __data,%S/Inputs/sectcreate-data.txt@foo=0 \
44
# RUN: %t.o
55
#
66
# Use -sectcreate to create a section from a data file.

llvm/tools/llvm-jitlink/llvm-jitlink.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ static cl::list<std::string>
165165

166166
static cl::list<std::string>
167167
SectCreate("sectcreate",
168-
cl::desc("given <sectname>,<filename>[:<sym>=<offset>,...] "
168+
cl::desc("given <sectname>,<filename>[@<sym>=<offset>,...] "
169169
"add the content of <filename> to <sectname>"),
170170
cl::cat(JITLinkCategory));
171171

@@ -1683,7 +1683,7 @@ static Error addSectCreates(Session &S,
16831683

16841684
StringRef SCArg(*SCItr);
16851685

1686-
auto [SectAndFileName, ExtraSymbolsString] = SCArg.split(':');
1686+
auto [SectAndFileName, ExtraSymbolsString] = SCArg.split('@');
16871687
auto [SectName, FileName] = SectAndFileName.rsplit(',');
16881688
if (SectName.empty())
16891689
return make_error<StringError>("In -sectcreate=" + SCArg +

0 commit comments

Comments
 (0)