Moved lite source to folders|
This commit is contained in:
		
							parent
							
								
									c2b0e223fa
								
							
						
					
					
						commit
						f36be4d5e4
					
				@ -89,8 +89,7 @@ if(SPDLOG_BUILD_BENCH)
 | 
			
		||||
endif()
 | 
			
		||||
 | 
			
		||||
if(SPDLOG_BUILD_LITE)
 | 
			
		||||
    add_subdirectory(lite)
 | 
			
		||||
    add_subdirectory(lite-example)
 | 
			
		||||
    add_subdirectory(spdlite)    
 | 
			
		||||
endif()
 | 
			
		||||
 | 
			
		||||
#---------------------------------------------------------------------------------------
 | 
			
		||||
 | 
			
		||||
@ -1,6 +0,0 @@
 | 
			
		||||
cmake_minimum_required(VERSION 3.1)
 | 
			
		||||
project(spdlog_lite)
 | 
			
		||||
 | 
			
		||||
add_library(spdlog_lite spdlite.cpp spdlite.h spdlite_global.cpp spdlite_global.h spdlite_macros.h)
 | 
			
		||||
 | 
			
		||||
target_link_libraries(spdlog_lite spdlog::spdlog)
 | 
			
		||||
							
								
								
									
										14
									
								
								spdlite/CMakeLists.txt
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								spdlite/CMakeLists.txt
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,14 @@
 | 
			
		||||
cmake_minimum_required(VERSION 3.1)
 | 
			
		||||
project(spdlite)
 | 
			
		||||
 | 
			
		||||
include_directories(${PROJECT_SOURCE_DIR}/include)
 | 
			
		||||
file(GLOB SRC_FILES ${PROJECT_SOURCE_DIR}/src/*.cpp)
 | 
			
		||||
file(GLOB HEADER_FILES ${PROJECT_SOURCE_DIR}/include/*.h)
 | 
			
		||||
 | 
			
		||||
add_library(spdlite ${SRC_FILES} ${HEADER_FILES})
 | 
			
		||||
 | 
			
		||||
target_link_libraries(spdlite spdlog::spdlog)
 | 
			
		||||
 | 
			
		||||
add_subdirectory(example)    
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -1,13 +1,11 @@
 | 
			
		||||
project(spdlog-lite-example CXX)
 | 
			
		||||
 | 
			
		||||
find_package(Threads REQUIRED)
 | 
			
		||||
project(spdlite-example CXX)
 | 
			
		||||
 | 
			
		||||
set(LITE_SOURCES example.cpp create_logger.cpp)
 | 
			
		||||
 | 
			
		||||
add_executable(${PROJECT_NAME} ${LITE_SOURCES})
 | 
			
		||||
 | 
			
		||||
include_directories(../lite)
 | 
			
		||||
find_package(Threads)
 | 
			
		||||
target_link_libraries(${PROJECT_NAME} PRIVATE Threads::Threads)
 | 
			
		||||
target_link_libraries(${PROJECT_NAME} PRIVATE spdlog_lite)
 | 
			
		||||
target_link_libraries(${PROJECT_NAME} PRIVATE spdlite)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -1,7 +1,7 @@
 | 
			
		||||
// Copyright(c) 2015-present Gabi Melman.
 | 
			
		||||
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
 | 
			
		||||
 | 
			
		||||
#include "spdlite.h"
 | 
			
		||||
#include "spdlite/spdlite.h"
 | 
			
		||||
#include "spdlog/spdlog.h"
 | 
			
		||||
#include "spdlog/sinks/basic_file_sink.h"
 | 
			
		||||
 | 
			
		||||
@ -1,11 +1,11 @@
 | 
			
		||||
// Copyright(c) 2015-present Gabi Melman.
 | 
			
		||||
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
 | 
			
		||||
 | 
			
		||||
#include "spdlite.h"
 | 
			
		||||
#include "spdlite_global.h"
 | 
			
		||||
#include "spdlite/spdlite.h"
 | 
			
		||||
#include "spdlite/spdlite_global.h"
 | 
			
		||||
 | 
			
		||||
#define SPDLITE_ACTIVE_LEVEL SPDLITE_LEVEL_TRACE
 | 
			
		||||
#include "spdlite_macros.h"
 | 
			
		||||
#include "spdlite/spdlite_macros.h"
 | 
			
		||||
int main()
 | 
			
		||||
{
 | 
			
		||||
    SPDLITE_TRACE("SOME INFO {}", 123);
 | 
			
		||||
@ -3,7 +3,7 @@
 | 
			
		||||
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
 | 
			
		||||
//
 | 
			
		||||
 | 
			
		||||
#include "spdlite.h"
 | 
			
		||||
#include "spdlite/spdlite.h"
 | 
			
		||||
#include "spdlog/spdlog.h"
 | 
			
		||||
 | 
			
		||||
static spdlog::level::level_enum to_spdlog_level(spdlite::level level)
 | 
			
		||||
@ -1,7 +1,7 @@
 | 
			
		||||
// Copyright(c) 2015-present Gabi Melman.
 | 
			
		||||
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
 | 
			
		||||
 | 
			
		||||
#include "spdlite_global.h"
 | 
			
		||||
#include "spdlite/spdlite_global.h"
 | 
			
		||||
 | 
			
		||||
spdlite::logger &spdlite::default_logger()
 | 
			
		||||
{
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user