diff --git a/CMakeLists.txt b/CMakeLists.txt index 0e509fc..02f9705 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,4 +3,4 @@ cmake_minimum_required(VERSION 2.8) aux_source_directory(. SRC_LIST) add_executable(${PROJECT_NAME} ${SRC_LIST}) target_compile_options(${PROJECT_NAME} PRIVATE -g -std=c++11) -target_link_libraries(${PROJECT_NAME} poppler-cpp pthread boost_program_options) +target_link_libraries(${PROJECT_NAME} poppler-cpp pthread boost_program_options boost_regex) diff --git a/main.cpp b/main.cpp index 35ccb32..0e64a15 100644 --- a/main.cpp +++ b/main.cpp @@ -3,8 +3,8 @@ #include #include #include -#include +#include #include #include #include @@ -41,6 +41,9 @@ void render_pages(document *doc, int first, int last, int step, const string& fm bool validate_output(const string& output) { + using boost::regex; + using boost::sregex_iterator; + if (output.empty()) { cout << "Output format must be specified" << endl; return false;