llvm/llvm/lib/ToolDrivers/llvm-dlltool/DlltoolDriver.cpp

//===- DlltoolDriver.cpp - dlltool.exe-compatible driver ------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
//
// Defines an interface to a dlltool.exe-compatible driver.
//
//===----------------------------------------------------------------------===//

#include "llvm/ToolDrivers/llvm-dlltool/DlltoolDriver.h"
#include "llvm/ADT/StringSwitch.h"
#include "llvm/Object/COFF.h"
#include "llvm/Object/COFFImportFile.h"
#include "llvm/Object/COFFModuleDefinition.h"
#include "llvm/Option/Arg.h"
#include "llvm/Option/ArgList.h"
#include "llvm/Option/OptTable.h"
#include "llvm/Option/Option.h"
#include "llvm/Support/Path.h"
#include "llvm/TargetParser/Host.h"

#include <optional>
#include <vector>

usingnamespacellvm;
usingnamespacellvm::object;
usingnamespacellvm::COFF;

namespace {

enum {};

#define PREFIX
#include "Options.inc"
#undef PREFIX

usingnamespacellvm::opt;
static constexpr opt::OptTable::Info InfoTable[] =;

class DllOptTable : public opt::GenericOptTable {};

// Opens a file. Path has to be resolved already.
std::unique_ptr<MemoryBuffer> openFile(const Twine &Path) {}

MachineTypes getEmulation(StringRef S) {}

MachineTypes getMachine(Triple T) {}

MachineTypes getDefaultMachine() {}

std::optional<std::string> getPrefix(StringRef Argv0) {}

bool parseModuleDefinition(StringRef DefFileName, MachineTypes Machine,
                           bool AddUnderscores,
                           std::vector<COFFShortExport> &Exports,
                           std::string &OutputFile) {}

} // namespace

int llvm::dlltoolDriverMain(llvm::ArrayRef<const char *> ArgsArr) {}