summaryrefslogtreecommitdiffstats
path: root/llvm/utils/gn/secondary/BUILD.gn
Commit message (Collapse)AuthorAgeFilesLines
...
* [gn build] Add build file for clang/lib/Basic and dependencies, 2nd tryNico Weber2018-12-191-0/+1
| | | | | | | | | | | | | | | Adds a build file for clang-tblgen and an action for running it, and uses that to process all the .td files in include/clang/Basic. Also adds an action to write include/clang/Config/config.h and include/clang/Basic/Version.inc. Differential Revision: https://reviews.llvm.org/D55847 (The previous commit of this contained unrelated changes, so I reverted the whole previous commit and I'm now landing only what I intended to land.) llvm-svn: 349679
* Revert 349677, it contained a whole bunch of stuff I did not mean to commitNico Weber2018-12-191-1/+0
| | | | llvm-svn: 349678
* [gn build] Add build file for clang/lib/Basic and dependenciesNico Weber2018-12-191-0/+1
| | | | | | | | | | | | Adds a build file for clang-tblgen and an action for running it, and uses that to process all the .td files in include/clang/Basic. Also adds an action to write include/clang/Config/config.h and include/clang/Basic/Version.inc. Differential Revision: https://reviews.llvm.org/D55847 llvm-svn: 349677
* [gn build] Add build file for llvm-objcopyNico Weber2018-12-191-0/+6
| | | | | | | | | | Needed by check-lld. This should've been part of r349486 but I messed up. Differential Revision: https://reviews.llvm.org/D55831 llvm-svn: 349598
* [gn build] Add build file for llvm-pdbutilNico Weber2018-12-181-0/+1
| | | | | | | | Needed for check-lld. Differential Revision: https://reviews.llvm.org/D55826 llvm-svn: 349490
* [gn build] Add build file for llvm-bcanalyzerNico Weber2018-12-181-0/+1
| | | | | | | | Needed for check-lld. Differential Revision: https://reviews.llvm.org/D55824 llvm-svn: 349488
* [gn build] Add build files for llvm-ar, llvm-nm, llvm-objdump, llvm-readelfNico Weber2018-12-181-2/+25
| | | | | | | | | | | | | | | Also add build files for deps DebugInfo/Symbolize, ToolDrivers/dll-tool. Also add gn/build/libs/xar (needed by llvm-objdump). Also delete an incorrect part of the symlink description in //BUILD.gn (it used to be true before I made the symlink step write a stamp file; now it's no longer true). These are all binaries needed by check-lld that need symlinks. Differential Revision: https://reviews.llvm.org/D55743 llvm-svn: 349486
* [gn build] Add build files for opt and its dependency Transforms/CouroutinesNico Weber2018-12-171-0/+1
| | | | | | | | Needed for check-lld. Differential Revision: https://reviews.llvm.org/D55750 llvm-svn: 349324
* [gn build] Add build files for obj2yaml, yaml2obj, and lib/ObjectYAMLNico Weber2018-12-161-0/+2
| | | | | | | | The two executables are needed by check-lld. Differential Revision: https://reviews.llvm.org/D55687 llvm-svn: 349290
* [gn build] Add build files for llvm-as, llvm-dis, llvm-dwarfdump, llvm-mc, ↵Nico Weber2018-12-161-0/+7
| | | | | | | | | | FileCheck, count, not These executables are needed by check-lld. Differential Revision: https://reviews.llvm.org/D55688 llvm-svn: 349289
* [gn build] Add infrastructure to create symlinks and use it to create lld's ↵Nico Weber2018-12-141-1/+30
| | | | | | | | | | | | symlinks This is slightly involved, see the comments in the code. The GN build now builds a functional lld! Differential Revision: https://reviews.llvm.org/D55606 llvm-svn: 349096
* [gn build] Add all non-test build files for lldNico Weber2018-12-121-1/+1
| | | | | | | | | | | | Version.inc.in processing has a potentially interesting part which I've punted on for now (LLD_REVISION and LLD_REPOSITORY are set to empty strings for now). lld now builds in the gn build. But no symlinks to it are created yet, so it can't be meaningfully run yet. Differential Revision: https://reviews.llvm.org/D55593 llvm-svn: 348945
* [gn build] Add build files for lib/LTO, lib/Linker, lib/Passes, ↵Nico Weber2018-12-121-0/+1
| | | | | | | | lib/Transforms/{IPO,Instrumentation,ObjCARC} Differential Revision: https://reviews.llvm.org/D55553 llvm-svn: 348905
* [gn build] Add build files for Target/X86/... and for tools/llcNico Weber2018-12-121-3/+1
| | | | | | | | | | | | | | | | | | The tablegen setup for Target/X86 is a bit different from the CMake build: In the CMake build, Target/X86/CMakeLists.txt has a single tablegen target that does everything. But some of the generated files are only used privately by a subproject, so in the GN build some of the tablegen invocations are smaller-scoped, mostly for build cleanliness. (It helps also a tiny bit with build parallelism since now e.g. the cpp files in MCTargetDesc can build after just 3 .inc files are generated instead of being blocked on all 13. But it's not a big win, since things depending on Target still need to wait for all 11, even though all .inc file use is internal to lib/Target.) Also add a build file for llc, since now all its dependencies have build files. Differential Revision: https://reviews.llvm.org/D55524 llvm-svn: 348903
* [gn build] Add build files for lib/CodeGen, lib/Transforms/..., and ↵Nico Weber2018-12-081-1/+1
| | | | | | | | lib/Bitcode/Writer Differential Revision: https://reviews.llvm.org/D55454 llvm-svn: 348667
* [gn build] Process .def.in files in llvm/Config and add lib/Target/BUILD.gnNico Weber2018-12-061-0/+1
| | | | | | | | | | | | | | | Tweak write_cmake_config.py to also handle variable references looking @FOO@ (matching CMake's configure_file() function), and make it replace '\' 'n' in values with a newline literal since there's no good portable way of passing a real newline literal on a command line. Use that to process all the .def.in files in llvm/include/Config and add llvm/lib/Target/BUILD.gn, which (indirectly, through llvm-c/Target.h) includes them. Differential Revision: https://reviews.llvm.org/D55184 llvm-svn: 348503
* [gn build] Add action to generate VCSRevision.h and use it to add ↵Nico Weber2018-12-011-3/+1
| | | | | | | | llvm/lib/Object/BUILD.gn Differential Revision: https://reviews.llvm.org/D55090 llvm-svn: 348054
* [gn build] Add build files for llvm/lib/Bitcode/Reader and llvm/lib/MC/MCParser.Nico Weber2018-11-301-0/+2
| | | | | | Differential Revision: https://reviews.llvm.org/D55087 llvm-svn: 347995
* [gn build] Add template for running llvm-tblgen and use it to add build file ↵Nico Weber2018-11-291-1/+2
| | | | | | | | | | | | | | | | | | | for llvm/lib/IR. Also adds a boring build file for llvm/lib/BinaryFormat (needed by llvm/lib/IR). lib/IR marks Attributes and IntrinsicsEnum as public_deps (because IR's public headers include the generated .inc files), so projects depending on lib/IR will implicitly depend on them being generated. As a consequence, most targets won't have to explicitly list a dependency on these tablegen steps (contrast with intrinsics_gen in the cmake build). This doesn't yet have the optimization where tablegen's output is only updated if it's changed. Differential Revision: https://reviews.llvm.org/D55028#inline-486755 llvm-svn: 347927
* [gn build] Add enough build files to be able to build llvm-tblgen.Nico Weber2018-11-271-0/+1
| | | | | | | | | | | | | | | | Adds build files for: - llvm/lib/DebugInfo/CodeView - llvm/lib/DebugInfo/MSF - llvm/lib/MC - llvm/lib/TableGen - llvm/utils/TableGen All the build files just list sources and deps and are uninteresting. Differential Revision: https://reviews.llvm.org/D54931 llvm-svn: 347702
* [gn build] Create abi-breaking.h, config.h, llvm-config.h, and add a build ↵Nico Weber2018-11-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | file for llvm/lib/Support. The comments at the top of llvm/utils/gn/secondary/llvm/include/llvm/Config/BUILD.gn and llvm/utils/gn/build/write_cmake_config.py should explain the main bits happening in this patch. The main parts here are that these headers are generated at build time, not gn time, and that currently they don't do any actual feature checks but just hardcode most things based on the current OS, which seems to work well enough. If this stops being enough, the feature checks should each be their own action writing the result to somewhere, and the config write step should depend on those checks (so that they can run in parallel and as part of the build) -- utils/llvm/gn/README.rst already has some more words on that in "Philosophy". (write_cmake_config.py is also going to be used to write clang's clang/include/clang/Config/config.h) This also adds a few files for linking to system libraries in a consistent way if needed in llvm/utils/gn/build/libs (and moves pthread to that model).0 I'm also adding llvm/utils/gn/secondary/llvm/lib/Target/targets.gni in this patch because $native_arch is needed for writing llvm-config.h -- the rest of it will be used later, when the build files for llvm/lib/Target get added. That file describes how to select which archs to build. As a demo, also add a build file for llvm-undname and make it the default build target (it depends on everything that can currently be built). Differential Revision: https://reviews.llvm.org/D54678 llvm-svn: 347636
* Add initial scaffolding for the GN build.Nico Weber2018-11-171-0/+11
See "GN build roundtable summary; adding GN build files to the repo" on llvm-dev and cfe-dev for discussion. In particular, this build is completely unsupported. People adding new files to LLVM are not expected to update the GN build files, and reviewers are not supposed to request the gn build files to be updated. This adds just enough to be able to build llvm/lib/Demangle. It requires using a monorepo. This adds a few build config options you can set in args.gn (`gn args out/foo --list` for all): - is_debug = true to enable debug builds (defaults to release) - llvm_enable_assertions to toggle assertions (defaults to true) - clang_base_path, if set an absolute path to a locally-built clang to be used as host compiler Differential Revision: https://reviews.llvm.org/D54345 llvm-svn: 347128
OpenPOWER on IntegriCloud