diff options
| author | Nico Weber <nicolasweber@gmx.de> | 2018-04-20 17:21:10 +0000 |
|---|---|---|
| committer | Nico Weber <nicolasweber@gmx.de> | 2018-04-20 17:21:10 +0000 |
| commit | 3a1b697d6e4ae861ef23965e2d4948aeb5b065b0 (patch) | |
| tree | a428524c8d248c1a09f4f36bfd5184de88588807 /llvm/utils/llvm-build/llvmbuild/main.py | |
| parent | a1e299f58b2340a3c452f567626ed4baa62f8818 (diff) | |
| download | bcm5719-llvm-3a1b697d6e4ae861ef23965e2d4948aeb5b065b0.tar.gz bcm5719-llvm-3a1b697d6e4ae861ef23965e2d4948aeb5b065b0.zip | |
Remove llvm-build's --configure-target-def-file.
It was added 6.5 years ago in r144345, but was never hooked up and has been
unused since. If _you_ do use this, feel free to revert, but add a comment
on where it's used.
https://reviews.llvm.org/D45262
llvm-svn: 330455
Diffstat (limited to 'llvm/utils/llvm-build/llvmbuild/main.py')
| -rw-r--r-- | llvm/utils/llvm-build/llvmbuild/main.py | 49 |
1 files changed, 1 insertions, 48 deletions
diff --git a/llvm/utils/llvm-build/llvmbuild/main.py b/llvm/utils/llvm-build/llvmbuild/main.py index 0dfa3d18c50..4533c650630 100644 --- a/llvm/utils/llvm-build/llvmbuild/main.py +++ b/llvm/utils/llvm-build/llvmbuild/main.py @@ -4,7 +4,6 @@ import os import sys import llvmbuild.componentinfo as componentinfo -import llvmbuild.configutil as configutil from llvmbuild.util import fatal, note @@ -376,7 +375,7 @@ subdirectories = %s f.write("""\ //===- llvm-build generated file --------------------------------*- C++ -*-===// // -// Component Library Depenedency Table +// Component Library Dependency Table // // Automatically generated file, do not edit! // @@ -761,9 +760,6 @@ def main(): help=( "If given, an alternate path to search for LLVMBuild.txt files"), action="store", default=None, metavar="PATH") - group.add_option("", "--build-root", dest="build_root", metavar="PATH", - help="Path to the build directory (if needed) [%default]", - action="store", default=None) parser.add_option_group(group) group = OptionGroup(parser, "Output Options") @@ -785,14 +781,6 @@ def main(): dest="write_cmake_exports_fragment", metavar="PATH", help="Write the CMake exports information to PATH", action="store", default=None) - group.add_option("", "--configure-target-def-file", - dest="configure_target_def_files", - help="""Configure the given file at SUBPATH (relative to -the inferred or given source root, and with a '.in' suffix) by replacing certain -substitution variables with lists of targets that support certain features (for -example, targets with AsmPrinters) and write the result to the build root (as -given by --build-root) at the same SUBPATH""", - metavar="SUBPATH", action="append", default=None) parser.add_option_group(group) group = OptionGroup(parser, "Configuration Options") @@ -863,40 +851,5 @@ given by --build-root) at the same SUBPATH""", project_info.write_cmake_exports_fragment(opts.write_cmake_exports_fragment, opts.optional_components) - # Configure target definition files, if requested. - if opts.configure_target_def_files: - # Verify we were given a build root. - if not opts.build_root: - parser.error("must specify --build-root when using " - "--configure-target-def-file") - - # Create the substitution list. - available_targets = [ci for ci in project_info.component_infos - if ci.type_name == 'TargetGroup'] - substitutions = [ - ("@LLVM_ENUM_TARGETS@", - ' '.join('LLVM_TARGET(%s)' % ci.name - for ci in available_targets)), - ("@LLVM_ENUM_ASM_PRINTERS@", - ' '.join('LLVM_ASM_PRINTER(%s)' % ci.name - for ci in available_targets - if ci.has_asmprinter)), - ("@LLVM_ENUM_ASM_PARSERS@", - ' '.join('LLVM_ASM_PARSER(%s)' % ci.name - for ci in available_targets - if ci.has_asmparser)), - ("@LLVM_ENUM_DISASSEMBLERS@", - ' '.join('LLVM_DISASSEMBLER(%s)' % ci.name - for ci in available_targets - if ci.has_disassembler))] - - # Configure the given files. - for subpath in opts.configure_target_def_files: - inpath = os.path.join(source_root, subpath + '.in') - outpath = os.path.join(opts.build_root, subpath) - result = configutil.configure_file(inpath, outpath, substitutions) - if not result: - note("configured file %r hasn't changed" % outpath) - if __name__=='__main__': main() |

