
Run the `clang-format.bash` script to update all our C and C++ code to a new style defined by `.clang-format`, now with "east const" enforcement. Use `clang-format` version 18. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit. Issue: #26123
64 lines
2.7 KiB
C++
64 lines
2.7 KiB
C++
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
|
|
file Copyright.txt or https://cmake.org/licensing for details. */
|
|
#pragma once
|
|
|
|
#include "cmConfigure.h" // IWYU pragma: keep
|
|
|
|
#include <string>
|
|
#include <vector>
|
|
|
|
#include "cmGeneratorTarget.h"
|
|
#include "cmNinjaTargetGenerator.h"
|
|
|
|
class cmNinjaNormalTargetGenerator : public cmNinjaTargetGenerator
|
|
{
|
|
public:
|
|
cmNinjaNormalTargetGenerator(cmGeneratorTarget* target);
|
|
~cmNinjaNormalTargetGenerator() override;
|
|
|
|
void Generate(std::string const& config) override;
|
|
|
|
private:
|
|
std::string LanguageLinkerRule(std::string const& config) const;
|
|
std::string LanguageLinkerDeviceRule(std::string const& config) const;
|
|
std::string LanguageLinkerCudaDeviceRule(std::string const& config) const;
|
|
std::string LanguageLinkerCudaDeviceCompileRule(
|
|
std::string const& config) const;
|
|
std::string LanguageLinkerCudaFatbinaryRule(std::string const& config) const;
|
|
std::string TextStubsGeneratorRule(std::string const& config) const;
|
|
bool CheckUseResponseFileForLibraries(std::string const& config) const;
|
|
char const* GetVisibleTypeName() const;
|
|
void WriteLanguagesRules(std::string const& config);
|
|
|
|
void WriteLinkRule(bool useResponseFile, std::string const& config);
|
|
void WriteDeviceLinkRules(std::string const& config);
|
|
void WriteNvidiaDeviceLinkRule(bool useResponseFile,
|
|
std::string const& config);
|
|
|
|
void WriteLinkStatement(std::string const& config,
|
|
std::string const& fileConfig, bool firstForConfig);
|
|
void WriteDeviceLinkStatement(std::string const& config,
|
|
std::string const& fileConfig,
|
|
bool firstForConfig);
|
|
void WriteDeviceLinkStatements(std::string const& config,
|
|
std::vector<std::string> const& architectures,
|
|
std::string const& output);
|
|
void WriteNvidiaDeviceLinkStatement(std::string const& config,
|
|
std::string const& fileConfig,
|
|
std::string const& outputDir,
|
|
std::string const& output);
|
|
|
|
void WriteObjectLibStatement(std::string const& config);
|
|
void WriteCxxModuleLibraryStatement(std::string const& config,
|
|
std::string const& fileConfig,
|
|
bool firstForConfig);
|
|
|
|
std::vector<std::string> ComputeLinkCmd(std::string const& config);
|
|
std::vector<std::string> ComputeDeviceLinkCmd();
|
|
|
|
// Target name info.
|
|
cmGeneratorTarget::Names TargetNames(std::string const& config) const;
|
|
std::string TargetLinkLanguage(std::string const& config) const;
|
|
std::string DeviceLinkObject;
|
|
};
|