cmake/Source/cmSetPropertyCommand.h

68 lines
2.4 KiB
C
Raw Normal View History

2016-10-30 18:24:19 +01:00
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
file Copyright.txt or https://cmake.org/licensing for details. */
2021-09-14 00:13:48 +02:00
#pragma once
2018-01-26 17:06:56 +01:00
#include "cmConfigure.h" // IWYU pragma: keep
2017-07-20 19:35:53 +02:00
2017-04-14 19:02:05 +02:00
#include <string>
#include <vector>
2020-08-30 11:54:41 +02:00
class cmMakefile;
2017-04-14 19:02:05 +02:00
class cmExecutionStatus;
2021-09-14 00:13:48 +02:00
class cmSourceFile;
2020-02-01 23:06:01 +01:00
bool cmSetPropertyCommand(std::vector<std::string> const& args,
cmExecutionStatus& status);
2020-08-30 11:54:41 +02:00
namespace SetPropertyCommand {
bool HandleSourceFileDirectoryScopes(
cmExecutionStatus& status, std::vector<std::string>& source_file_directories,
std::vector<std::string>& source_file_target_directories,
std::vector<cmMakefile*>& directory_makefiles);
bool HandleSourceFileDirectoryScopeValidation(
cmExecutionStatus& status, bool source_file_directory_option_enabled,
bool source_file_target_option_enabled,
std::vector<std::string>& source_file_directories,
std::vector<std::string>& source_file_target_directories);
2021-09-14 00:13:48 +02:00
bool HandleAndValidateSourceFileDirectoryScopes(
2020-08-30 11:54:41 +02:00
cmExecutionStatus& status, bool source_directories_option_encountered,
bool source_target_directories_option_encountered,
std::vector<std::string>& source_directories,
std::vector<std::string>& source_target_directories,
std::vector<cmMakefile*>& source_file_directory_makefiles);
2023-12-07 09:12:54 +01:00
bool HandleTestDirectoryScopes(cmExecutionStatus& status,
std::string& test_directory,
cmMakefile*& directory_makefile);
bool HandleTestDirectoryScopeValidation(cmExecutionStatus& status,
bool test_directory_option_enabled,
std::string& test_directory);
bool HandleAndValidateTestDirectoryScopes(
cmExecutionStatus& status, bool test_directory_option_encountered,
std::string& test_directory, cmMakefile*& test_directory_makefile);
2020-08-30 11:54:41 +02:00
std::string MakeSourceFilePathAbsoluteIfNeeded(
cmExecutionStatus& status, const std::string& source_file_path, bool needed);
void MakeSourceFilePathsAbsoluteIfNeeded(
cmExecutionStatus& status,
std::vector<std::string>& source_files_absolute_paths,
std::vector<std::string>::const_iterator files_it_begin,
std::vector<std::string>::const_iterator files_it_end, bool needed);
2021-09-14 00:13:48 +02:00
enum class PropertyOp
{
Remove,
Set,
Append,
AppendAsString
};
bool HandleAndValidateSourceFilePropertyGENERATED(
cmSourceFile* sf, std::string const& propertyValue,
PropertyOp op = PropertyOp::Set);
}