llvm-config-2: Switch to using real library dependency table.
authorDaniel Dunbar <daniel@zuster.org>
Sun, 6 Nov 2011 18:04:23 +0000 (18:04 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Sun, 6 Nov 2011 18:04:23 +0000 (18:04 +0000)
 - Also, fix a refacto that left extra "all" component in list (this is now
   defined in the groups explicitly)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143879 91177308-0d34-0410-b5e6-96231b3b80d8

tools/llvm-config-2/llvm-config.cpp

index 597b80fb4fb8abc6c09375f798125a8abf1d88bc..6b27a6ed72ccf2e86b24163c64ba6c506229bcbb 100644 (file)
@@ -43,15 +43,7 @@ using namespace llvm;
 //
 // Not all components define a library, we also use "library groups" as a way to
 // create entries for pseudo groups like x86 or all-targets.
-//
-// FIXME: Include real component table.
-struct AvailableComponent {
-  const char *Name;
-  const char *Library;
-  const char *RequiredLibraries[1];
-} AvailableComponents[1] = {
-  { "all", 0, { } }
-};
+#include "LibraryDependencies.inc"
 
 /// \brief Traverse a single component adding to the topological ordering in
 /// \arg RequiredLibs.
@@ -261,7 +253,6 @@ int main(int argc, char **argv) {
       } else if (Arg == "--libfiles") {
         PrintLibFiles = true;
       } else if (Arg == "--components") {
-        OS << "all";
         for (unsigned j = 0; j != array_lengthof(AvailableComponents); ++j) {
           OS << ' ';
           OS << AvailableComponents[j].Name;