Skip to content

Commit 7d99a51

Browse files
committed
rename and restructure
1 parent fec5927 commit 7d99a51

File tree

22 files changed

+148
-34
lines changed

22 files changed

+148
-34
lines changed

.clangd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
CompileFlags:
2-
Remove: [-mno-direct-extern-access]
2+
Remove: [-mno-direct-extern-access,-fconcepts-diagnostics-depth=*]
33
Compiler: clang++

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ feature_summary(WHAT PACKAGES_FOUND DESCRIPTION "Found packages:")
5959

6060
include(CMakePackageConfigHelpers)
6161

62-
install(TARGETS loggerlib quite-studio probe quite_protocol_proto
62+
install(TARGETS quite_core quite_logger quite-studio probe quite_protocol_proto
6363
EXPORT quiteTargets
6464
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
6565
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}

libs/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
add_subdirectory(logger)
2+
add_subdirectory(core)
23
add_subdirectory(protocol)
34
add_subdirectory(quite)
45
add_subdirectory(testing)

libs/core/CMakeLists.txt

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
add_library(quite_core)
2+
add_library(quite::core ALIAS quite_core)
3+
set_target_properties(quite_core PROPERTIES
4+
POSITION_INDEPENDENT_CODE ON
5+
)
6+
generate_export_header(quite_core)
7+
8+
target_include_directories(quite_core PUBLIC
9+
"$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>"
10+
"$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>"
11+
"$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>"
12+
)
13+
14+
target_link_libraries(quite_core PUBLIC
15+
fmt::fmt
16+
quill::quill
17+
)
18+
19+
target_sources(quite_core
20+
PRIVATE
21+
src/core.cpp
22+
)
23+
24+
install(DIRECTORY include/ DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}")
25+
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/quite_core_export.h" DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}")
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#pragma once
2+
#include "quite_core_export.h"
3+
4+
namespace quite
5+
{
6+
class QUITE_CORE_EXPORT MetaRegistry{
7+
8+
};
9+
}

libs/quite/include/quite/meta/meta_types.hpp renamed to libs/core/include/quite/meta/meta_types.hpp

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -24,32 +24,32 @@ struct Method
2424
std::vector<Property> parameters;
2525
};
2626

27-
class MetaType
27+
struct MetaType
2828
{
29-
std::string type_name_;
29+
std::string name;
3030

31-
std::vector<Property> properties_;
32-
std::vector<Method> signals_;
33-
std::vector<Method> functions_;
31+
std::vector<Property> properties;
32+
std::vector<Method> signals;
33+
std::vector<Method> functions;
3434
};
3535

36-
class MapType
36+
struct MapType
3737
{
38-
TypeId key_type_;
39-
TypeId value_type_;
38+
TypeId key_type;
39+
TypeId value_type;
4040
};
4141

42-
class ListType
42+
struct ListType
4343
{
44-
TypeId element_type_;
44+
TypeId value_type;
4545
};
4646

47-
class EnumType
47+
struct EnumType
4848
{
4949
using ValueName = std::string;
5050

51-
std::string type_name_;
52-
std::unordered_map<ValueName, std::int64_t> values_;
51+
std::string name;
52+
std::unordered_map<ValueName, std::int64_t> values;
5353
};
5454

5555
enum class PrimitiveType

libs/core/src/core.cpp

Whitespace-only changes.

libs/logger/CMakeLists.txt

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
1-
add_library(loggerlib)
2-
add_library(quite::logger ALIAS loggerlib)
3-
set_target_properties(loggerlib PROPERTIES
1+
add_library(quite_logger)
2+
add_library(quite::logger ALIAS quite_logger)
3+
set_target_properties(quite_logger PROPERTIES
44
POSITION_INDEPENDENT_CODE ON
55
)
6-
generate_export_header(loggerlib)
6+
generate_export_header(quite_logger)
77

8-
target_include_directories(loggerlib PUBLIC
8+
target_include_directories(quite_logger PUBLIC
99
"$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>"
1010
"$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>"
1111
"$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>"
1212
)
1313

14-
target_link_libraries(loggerlib PUBLIC
14+
target_link_libraries(quite_logger PUBLIC
1515
fmt::fmt
1616
quill::quill
1717
)
1818

19-
target_sources(loggerlib
19+
target_sources(quite_logger
2020
PRIVATE
2121
src/logger.cpp
2222
)
2323

2424
install(DIRECTORY include/ DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}")
25-
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/loggerlib_export.h" DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}")
25+
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/quite_logger_export.h" DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}")

libs/logger/include/quite/logger.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
#pragma once
22
#include <quill/LogMacros.h>
33
#include <quill/Logger.h>
4-
#include "loggerlib_export.h"
4+
#include "quite_logger_export.h"
55

66
namespace quite
77
{
8-
LOGGERLIB_EXPORT quill::Logger *create_logger(std::string_view logger_name);
8+
QUITE_LOGGER_EXPORT quill::Logger *create_logger(std::string_view logger_name);
99
}
1010

1111
#define DEFINE_LOGGER(name) \
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#pragma once
2-
#include "loggerlib_export.h"
2+
#include "quite_logger_export.h"
33
namespace quite
44
{
5-
LOGGERLIB_EXPORT void setup_logger();
5+
QUITE_LOGGER_EXPORT void setup_logger();
66
}

0 commit comments

Comments
 (0)