tf_fuzz: refactor includes to only include what is needed
* Refactor Makefile to automatically gather prerequisites.
* Change the includes (using include-what-you-need) so that files only
include the specific headers they need. Many includes are also now
inside the .hpp files instead of the .cpp files.
This improves editor support: previously, external symbols in .hpp
files would not be resolved by clangd due to .hpp files not having any
imports.
Change-Id: Iece03f81c35aa43ac026aaeb49b87d2c4acf07cd
Signed-off-by: Nik Dewally <Nik.Dewally@arm.com>
diff --git a/tf_fuzz/tfz-cpp/class_forwards.hpp b/tf_fuzz/tfz-cpp/class_forwards.hpp
index 6099fbe..893cdd9 100644
--- a/tf_fuzz/tfz-cpp/class_forwards.hpp
+++ b/tf_fuzz/tfz-cpp/class_forwards.hpp
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+ * Copyright (c) 2019-2024, Arm Limited. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*
@@ -23,42 +23,34 @@
class expect_info;
class set_data_info;
class asset_name_id_info;
-
// variables.hpp:
class variable_info;
-
// template_line.hpp:
class template_line;
class sst_template_line;
class key_template_line;
class policy_template_line;
-
// sst_template_line.hpp:
class set_sst_template_line;
class remove_sst_template_line;
class read_sst_template_line;
-
// crypto_template_line.hpp:
class set_key_template_line;
class remove_key_template_line;
class read_key_template_line;
class set_policy_template_line;
class read_policy_template_line;
-
// security.hpp:
class security;
class security_hash;
-
// psa_call.hpp:
class psa_call;
class sst_call;
class crypto_call;
-
// sst_call.hpp:
class sst_set_call;
class sst_get_call;
class sst_remove_call;
-
// crypto_call.hpp:
class policy_call;
class key_call;
@@ -88,26 +80,20 @@
class destroy_key_call;
-
// psa_asset.hpp:
class psa_asset;
-
// sst_asset.hpp:
class sst_asset;
-
// crypto_asset.hpp:
class crypto_asset;
class key_asset;
class policy_asset;
class key_asset;
-
// boilerplate.hpp"
//enum class boilerplate_texts; not really a "class," and no need to forward-reference it anyway
class boilerplate;
-
// gibberish.hpp:
class gibberish;
-
// tf_fuzz.hpp:
class tf_fuzz_info;