changed error output
This commit is contained in:
@@ -12,9 +12,6 @@ set(DEFAULT_BUILD_TYPE DEBUG)
|
|||||||
|
|
||||||
set(CMAKE_CXX_STANDARD 14)
|
set(CMAKE_CXX_STANDARD 14)
|
||||||
|
|
||||||
# Boost configuration
|
|
||||||
set(BOOST_COMPONENTS program_options thread timer chrono)
|
|
||||||
|
|
||||||
IF(NOT_PI)
|
IF(NOT_PI)
|
||||||
add_definitions(-DNOT_PI)
|
add_definitions(-DNOT_PI)
|
||||||
message("Compiling not for Pi")
|
message("Compiling not for Pi")
|
||||||
@@ -73,10 +70,13 @@ target_include_directories(${PROJECT_NAME} PUBLIC ${CMAKE_SOURCE_DIR}/include)
|
|||||||
target_include_directories(${PROJECT_NAME} PRIVATE ${CMAKE_SOURCE_DIR}/${LIB_DIR})
|
target_include_directories(${PROJECT_NAME} PRIVATE ${CMAKE_SOURCE_DIR}/${LIB_DIR})
|
||||||
|
|
||||||
######################### BOOST #########################
|
######################### BOOST #########################
|
||||||
|
# Boost configuration
|
||||||
|
set(BOOST_COMPONENTS program_options thread timer chrono)
|
||||||
find_package(Boost REQUIRED COMPONENTS ${BOOST_COMPONENTS})
|
find_package(Boost REQUIRED COMPONENTS ${BOOST_COMPONENTS})
|
||||||
if(Boost_FOUND)
|
if(Boost_FOUND)
|
||||||
# Include and link with boost
|
# Include and link with boost
|
||||||
target_include_directories(${PROJECT_NAME} PUBLIC ${Boost_INCLUDE_DIRS})
|
target_include_directories(${PROJECT_NAME} PUBLIC ${Boost_INCLUDE_DIRS})
|
||||||
|
LINK_DIRECTORIES(${Boost_LIBRARY_DIRS})
|
||||||
target_link_libraries(${PROJECT_NAME} PUBLIC ${Boost_LIBRARIES})
|
target_link_libraries(${PROJECT_NAME} PUBLIC ${Boost_LIBRARIES})
|
||||||
message ("Boost found and linked.")
|
message ("Boost found and linked.")
|
||||||
else()
|
else()
|
||||||
|
|||||||
@@ -346,7 +346,7 @@ type get_value(const std::string & name, json & object, const std::string & file
|
|||||||
}
|
}
|
||||||
catch(json::exception &e)
|
catch(json::exception &e)
|
||||||
{
|
{
|
||||||
CLOG(ERROR, OUTPUT_LOGGER) << "File " << file_name << " seems to be corrupted at " << name << ": " << e.what();
|
/*CLOG(ERROR, OUTPUT_LOGGER)*/ std::cerr << "File " << file_name << " seems to be corrupted at " << name << ": " << e.what();
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
return element;
|
return element;
|
||||||
|
|||||||
Reference in New Issue
Block a user