summaryrefslogtreecommitdiff
path: root/src/ccache.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/ccache.hpp')
-rw-r--r--src/ccache.hpp18
1 files changed, 15 insertions, 3 deletions
diff --git a/src/ccache.hpp b/src/ccache.hpp
index 510563a4..a3d0be77 100644
--- a/src/ccache.hpp
+++ b/src/ccache.hpp
@@ -1,5 +1,5 @@
// Copyright (C) 2002-2007 Andrew Tridgell
-// Copyright (C) 2009-2022 Joel Rosdahl and other contributors
+// Copyright (C) 2009-2023 Joel Rosdahl and other contributors
//
// See doc/AUTHORS.adoc for a complete list of contributors.
//
@@ -19,11 +19,13 @@
#pragma once
-#include "Config.hpp"
+#include <Args.hpp>
+#include <Config.hpp>
#include <functional>
#include <string>
#include <string_view>
+#include <vector>
class Context;
@@ -37,6 +39,16 @@ using FindExecutableFunction =
int ccache_main(int argc, const char* const* argv);
// Tested by unit tests.
+struct ArgvParts
+{
+ bool masquerading_as_compiler = true;
+ std::vector<std::string> config_settings;
+ Args compiler_and_args;
+};
+
+ArgvParts split_argv(int argc, const char* const* argv);
+
void find_compiler(Context& ctx,
- const FindExecutableFunction& find_executable_function);
+ const FindExecutableFunction& find_executable_function,
+ bool masquerading_as_compiler);
CompilerType guess_compiler(std::string_view path);