Moved main function in its own CU to avoid symbol conflicts when calling other functions

This commit is contained in:
Snaipe 2015-02-11 01:25:48 +01:00
parent df1f23ef4c
commit 7e2d485d75
3 changed files with 7 additions and 5 deletions

View file

@ -40,4 +40,5 @@ libcriterion_la_SOURCES = \
src/process.c \
src/process.h \
src/stats.c \
src/stats.h
src/stats.h \
src/main.c

5
src/main.c Normal file
View file

@ -0,0 +1,5 @@
#include <criterion/criterion.h>
int main(void) {
return criterion_run_all_tests();
}

View file

@ -164,7 +164,3 @@ int criterion_run_all_tests(void) {
return strcmp("1", getenv("CRITERION_ALWAYS_SUCCEED") ?: "0") && res;
}
int main(void) {
return criterion_run_all_tests();
}