diff --git a/CMakeLists.txt b/CMakeLists.txt index 51af2f7..822ee48 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,10 +6,14 @@ endif(TARGET regex) project(libregex) +add_compile_options(-pedantic -Wall) + add_library(regex STATIC src/libregex.c) add_executable(libregex src/main.c) add_subdirectory(external/libds) +set_property(TARGET regex PROPERTY C_STANDARD 90) +set_property(TARGET libregex PROPERTY C_STANDARD 90) target_include_directories(regex PUBLIC include) target_include_directories(libregex PUBLIC include) diff --git a/include/libregex.h b/include/libregex.h index 9586972..2428461 100644 --- a/include/libregex.h +++ b/include/libregex.h @@ -325,4 +325,5 @@ libregex_result regex_match_string(regex_node* root, char* string, regex_result* */ void regex_result_free(regex_result* result); -#endif \ No newline at end of file +#endif + diff --git a/src/libregex.c b/src/libregex.c index 38aea20..05ca29a 100644 --- a/src/libregex.c +++ b/src/libregex.c @@ -597,4 +597,5 @@ void regex_result_free(regex_result* result){ free(result->groups[index]); } result->matches = 0; -} \ No newline at end of file +} +