From e1fbac3ca13d37d2625c11d30cfdece4327b446b Mon Sep 17 00:00:00 2001 From: Yuri Kunde Schlesner Date: Wed, 6 May 2015 04:06:12 -0300 Subject: Common: Remove common.h --- src/common/CMakeLists.txt | 1 - src/common/bit_field.h | 2 +- src/common/break_points.cpp | 1 - src/common/break_points.h | 2 +- src/common/chunk_file.h | 3 ++- src/common/common.h | 21 --------------------- src/common/common_paths.h | 3 --- src/common/concurrent_ring_buffer.h | 2 +- src/common/emu_window.h | 6 +++--- src/common/file_util.cpp | 6 ++++-- src/common/file_util.h | 2 +- src/common/hash.cpp | 1 + src/common/hash.h | 2 +- src/common/linear_disk_cache.h | 2 +- src/common/logging/text_formatter.cpp | 1 + src/common/math_util.cpp | 6 +++--- src/common/math_util.h | 2 +- src/common/mem_arena.cpp | 6 +++++- src/common/mem_arena.h | 2 +- src/common/memory_util.cpp | 3 ++- src/common/misc.cpp | 4 +++- src/common/string_util.cpp | 4 +++- src/common/string_util.h | 2 +- src/common/symbols.h | 4 +++- src/common/thread.h | 1 - src/common/thread_queue_list.h | 2 -- src/common/thunk.h | 2 +- src/common/timer.cpp | 4 ++-- src/common/timer.h | 2 +- 29 files changed, 43 insertions(+), 56 deletions(-) delete mode 100644 src/common/common.h (limited to 'src/common') diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt index daa2d59de..9a9f1a46b 100644 --- a/src/common/CMakeLists.txt +++ b/src/common/CMakeLists.txt @@ -27,7 +27,6 @@ set(HEADERS bit_field.h break_points.h chunk_file.h - common.h common_funcs.h common_paths.h common_types.h diff --git a/src/common/bit_field.h b/src/common/bit_field.h index 8eab054b8..1f3ecf844 100644 --- a/src/common/bit_field.h +++ b/src/common/bit_field.h @@ -35,7 +35,7 @@ #include #include -#include "common/common.h" +#include "common/common_funcs.h" /* * Abstract bitfield class diff --git a/src/common/break_points.cpp b/src/common/break_points.cpp index 15055bd4e..023a485a4 100644 --- a/src/common/break_points.cpp +++ b/src/common/break_points.cpp @@ -2,7 +2,6 @@ // Licensed under GPLv2 or any later version // Refer to the license.txt file included. -#include "common/common.h" #include "common/debug_interface.h" #include "common/break_points.h" #include "common/logging/log.h" diff --git a/src/common/break_points.h b/src/common/break_points.h index 4b26cf90d..f0a55e7b1 100644 --- a/src/common/break_points.h +++ b/src/common/break_points.h @@ -7,7 +7,7 @@ #include #include -#include "common/common.h" +#include "common/common_types.h" class DebugInterface; diff --git a/src/common/chunk_file.h b/src/common/chunk_file.h index 3f97d56bf..dcd80525e 100644 --- a/src/common/chunk_file.h +++ b/src/common/chunk_file.h @@ -34,8 +34,9 @@ #include #include -#include "common/common.h" +#include "common/common_types.h" #include "common/file_util.h" +#include "common/logging/log.h" template struct LinkedListItem : public T diff --git a/src/common/common.h b/src/common/common.h deleted file mode 100644 index a9d3a6e6a..000000000 --- a/src/common/common.h +++ /dev/null @@ -1,21 +0,0 @@ -// Copyright 2013 Dolphin Emulator Project / 2014 Citra Emulator Project -// Licensed under GPLv2 or any later version -// Refer to the license.txt file included. - -#pragma once - -// DO NOT EVER INCLUDE directly _or indirectly_ from this file -// since it slows down the build a lot. - -#include -#include -#include - -#include "common/assert.h" -#include "common/logging/log.h" -#include "common/common_types.h" -#include "common/common_funcs.h" -#include "common/common_paths.h" -#include "common/platform.h" - -#include "swap.h" diff --git a/src/common/common_paths.h b/src/common/common_paths.h index 440b06060..2903f2cf2 100644 --- a/src/common/common_paths.h +++ b/src/common/common_paths.h @@ -4,9 +4,6 @@ #pragma once -// Make sure we pick up USER_DIR if set in config.h -#include "common/common.h" - // Directory separators, do we need this? #define DIR_SEP "/" #define DIR_SEP_CHR '/' diff --git a/src/common/concurrent_ring_buffer.h b/src/common/concurrent_ring_buffer.h index fc18e6c86..c5889513a 100644 --- a/src/common/concurrent_ring_buffer.h +++ b/src/common/concurrent_ring_buffer.h @@ -10,7 +10,7 @@ #include #include -#include "common/common.h" // for NonCopyable +#include "common/common_types.h" // for NonCopyable namespace Common { diff --git a/src/common/emu_window.h b/src/common/emu_window.h index e0fc12a48..8eca6b5d5 100644 --- a/src/common/emu_window.h +++ b/src/common/emu_window.h @@ -4,11 +4,11 @@ #pragma once -#include "common/common.h" -#include "common/scm_rev.h" -#include "common/string_util.h" +#include "common/common_types.h" #include "common/key_map.h" #include "common/math_util.h" +#include "common/scm_rev.h" +#include "common/string_util.h" /** * Abstraction class used to provide an interface between emulation code and the frontend diff --git a/src/common/file_util.cpp b/src/common/file_util.cpp index 946c4261a..7cdd1484f 100644 --- a/src/common/file_util.cpp +++ b/src/common/file_util.cpp @@ -2,9 +2,11 @@ // Licensed under GPLv2 or any later version // Refer to the license.txt file included. - -#include "common/common.h" +#include "common/assert.h" +#include "common/common_funcs.h" +#include "common/common_paths.h" #include "common/file_util.h" +#include "common/logging/log.h" #ifdef _WIN32 #include diff --git a/src/common/file_util.h b/src/common/file_util.h index 86aab2e3d..b65829291 100644 --- a/src/common/file_util.h +++ b/src/common/file_util.h @@ -11,7 +11,7 @@ #include #include -#include "common/common.h" +#include "common/common_types.h" #include "common/string_util.h" // User directory indices for GetUserPath diff --git a/src/common/hash.cpp b/src/common/hash.cpp index 3e62beff4..b0b3613f6 100644 --- a/src/common/hash.cpp +++ b/src/common/hash.cpp @@ -4,6 +4,7 @@ #include +#include "common/common_funcs.h" // For rotl #include "common/hash.h" #include "common/platform.h" diff --git a/src/common/hash.h b/src/common/hash.h index 3ac42bc44..0afaf0e37 100644 --- a/src/common/hash.h +++ b/src/common/hash.h @@ -4,7 +4,7 @@ #pragma once -#include "common/common.h" +#include "common/common_types.h" u32 HashFletcher(const u8* data_u8, size_t length); // FAST. Length & 1 == 0. u32 HashAdler32(const u8* data, size_t len); // Fairly accurate, slightly slower diff --git a/src/common/linear_disk_cache.h b/src/common/linear_disk_cache.h index 74ce74aba..48529cf42 100644 --- a/src/common/linear_disk_cache.h +++ b/src/common/linear_disk_cache.h @@ -4,7 +4,7 @@ #pragma once -#include "common/common.h" +#include "common/common_types.h" #include // defined in Version.cpp diff --git a/src/common/logging/text_formatter.cpp b/src/common/logging/text_formatter.cpp index 36c91c4f6..45be6d0a1 100644 --- a/src/common/logging/text_formatter.cpp +++ b/src/common/logging/text_formatter.cpp @@ -14,6 +14,7 @@ #include "common/logging/log.h" #include "common/logging/text_formatter.h" +#include "common/common_funcs.h" #include "common/string_util.h" namespace Log { diff --git a/src/common/math_util.cpp b/src/common/math_util.cpp index a83592dd2..bcb70cae5 100644 --- a/src/common/math_util.cpp +++ b/src/common/math_util.cpp @@ -2,12 +2,12 @@ // Licensed under GPLv2 or any later version // Refer to the license.txt file included. +#include +#include // Necessary on OS X, but not Linux -#include "common/common.h" +#include "common/common_types.h" #include "common/math_util.h" -#include // Necessary on OS X, but not Linux - namespace MathUtil { diff --git a/src/common/math_util.h b/src/common/math_util.h index 43b0e0dc3..52f579cf7 100644 --- a/src/common/math_util.h +++ b/src/common/math_util.h @@ -4,7 +4,7 @@ #pragma once -#include "common/common.h" +#include "common/common_types.h" #include #include diff --git a/src/common/mem_arena.cpp b/src/common/mem_arena.cpp index 76c70701d..f233d4a3a 100644 --- a/src/common/mem_arena.cpp +++ b/src/common/mem_arena.cpp @@ -17,12 +17,16 @@ #include -#include "common/memory_util.h" +#include "common/logging/log.h" #include "common/mem_arena.h" +#include "common/memory_util.h" #include "common/string_util.h" #ifndef _WIN32 #include +#include +#include + #ifdef ANDROID #include #include diff --git a/src/common/mem_arena.h b/src/common/mem_arena.h index 3379d2529..d514fe58c 100644 --- a/src/common/mem_arena.h +++ b/src/common/mem_arena.h @@ -21,7 +21,7 @@ #include #endif -#include "common/common.h" +#include "common/common_types.h" // This class lets you create a block of anonymous RAM, and then arbitrarily map views into it. // Multiple views can mirror the same section of the block, which makes it very convient for emulating diff --git a/src/common/memory_util.cpp b/src/common/memory_util.cpp index 7e69d31cb..2087a1184 100644 --- a/src/common/memory_util.cpp +++ b/src/common/memory_util.cpp @@ -3,7 +3,8 @@ // Refer to the license.txt file included. -#include "common/common.h" +#include "common/common_funcs.h" +#include "common/logging/log.h" #include "common/memory_util.h" #include "common/string_util.h" diff --git a/src/common/misc.cpp b/src/common/misc.cpp index e33055d10..53cacf37c 100644 --- a/src/common/misc.cpp +++ b/src/common/misc.cpp @@ -2,10 +2,12 @@ // Licensed under GPLv2 or any later version // Refer to the license.txt file included. -#include "common/common.h" +#include "common/common_funcs.h" #ifdef _WIN32 #include +#else +#include #endif // Neither Android nor OS X support TLS diff --git a/src/common/string_util.cpp b/src/common/string_util.cpp index 3264dd51a..6563611fd 100644 --- a/src/common/string_util.cpp +++ b/src/common/string_util.cpp @@ -4,7 +4,9 @@ #include -#include "common/common.h" +#include "common/common_funcs.h" +#include "common/common_paths.h" +#include "common/logging/log.h" #include "common/string_util.h" #ifdef _MSC_VER diff --git a/src/common/string_util.h b/src/common/string_util.h index 74974263f..a60a84696 100644 --- a/src/common/string_util.h +++ b/src/common/string_util.h @@ -10,7 +10,7 @@ #include #include -#include "common/common.h" +#include "common/common_types.h" namespace Common { diff --git a/src/common/symbols.h b/src/common/symbols.h index f76cb6b1e..6b62b011e 100644 --- a/src/common/symbols.h +++ b/src/common/symbols.h @@ -5,8 +5,10 @@ #pragma once #include +#include +#include -#include "common/common.h" +#include "common/common_types.h" struct TSymbol { diff --git a/src/common/thread.h b/src/common/thread.h index 5fdb6baeb..7bc419497 100644 --- a/src/common/thread.h +++ b/src/common/thread.h @@ -4,7 +4,6 @@ #pragma once -// Don't include common.h here as it will break LogManager #include "common/common_types.h" #include #include diff --git a/src/common/thread_queue_list.h b/src/common/thread_queue_list.h index 4f27fc899..12455d7c4 100644 --- a/src/common/thread_queue_list.h +++ b/src/common/thread_queue_list.h @@ -9,8 +9,6 @@ #include -#include "common/common.h" - namespace Common { template diff --git a/src/common/thunk.h b/src/common/thunk.h index 4fb7c98e1..533480056 100644 --- a/src/common/thunk.h +++ b/src/common/thunk.h @@ -6,7 +6,7 @@ #include -#include "common/common.h" +#include "common/common_types.h" // This simple class creates a wrapper around a C/C++ function that saves all fp state // before entering it, and restores it upon exit. This is required to be able to selectively diff --git a/src/common/timer.cpp b/src/common/timer.cpp index a6682ea19..b99835ac7 100644 --- a/src/common/timer.cpp +++ b/src/common/timer.cpp @@ -12,9 +12,9 @@ #include #endif -#include "common/common.h" -#include "common/timer.h" +#include "common/common_types.h" #include "common/string_util.h" +#include "common/timer.h" namespace Common { diff --git a/src/common/timer.h b/src/common/timer.h index 4b44c33a0..b5f0f2585 100644 --- a/src/common/timer.h +++ b/src/common/timer.h @@ -4,7 +4,7 @@ #pragma once -#include "common/common.h" +#include "common/common_types.h" #include namespace Common -- cgit v1.2.3