Adding main file...

This commit is contained in:
Ognjen Milan Robovic 2023-11-13 21:05:10 -05:00
parent f10547203f
commit c24cd6b99e
2 changed files with 27 additions and 22 deletions

View File

@ -4,23 +4,26 @@ set -xe
clang -DSTATIC_SOURCE -g -Weverything -O0 -o xhartae xhartae.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o chapters/chapter_0.o chapters/chapter_0.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o chapters/chapter_1.o chapters/chapter_1.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o chapters/chapter_2.o chapters/chapter_2.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o chapters/chapter_3.o chapters/chapter_3.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o chapter/chapter_0.o chapter/chapter_0.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o chapter/chapter_1.o chapter/chapter_1.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o chapter/chapter_2.o chapter/chapter_2.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o chapter/chapter_3.o chapter/chapter_3.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o chapter/chapter_4.o chapter/chapter_4.c
gcc -g -Wall -Wextra -Wpedantic -O0 -c -o xhartae.o xhartae.c
gcc -o xhartae xhartae.o chapters/chapter_0.o chapters/chapter_1.o chapters/chapter_2.o chapters/chapter_3.o
gcc -o xhartae xhartae.o chapter/chapter_0.o chapter/chapter_1.o chapter/chapter_2.o chapter/chapter_3.o chapter/chapter_4.o
splint -weak -warnposix -retvalother -syntax -type chapters/chapter_0.h
splint -weak -warnposix -retvalother -syntax -type chapters/chapter_0.c
splint -weak -warnposix -retvalother -syntax -type chapters/chapter_1.h
splint -weak -warnposix -retvalother -syntax -type chapters/chapter_1.c
splint -weak -warnposix -retvalother -syntax -type chapters/chapter_2.h
splint -weak -warnposix -retvalother -syntax -type chapters/chapter_2.c
splint -weak -warnposix -retvalother -syntax -type chapters/chapter_3.h
splint -weak -warnposix -retvalother -syntax -type chapters/chapter_3.c
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_0.h
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_0.c
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_1.h
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_1.c
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_2.h
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_2.c
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_3.h
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_3.c
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_4.h
splint -weak -warnposix -retvalother -syntax -type chapter/chapter_4.c
splint -weak -warnposix -retvalother -syntax -type xhartae.c
valgrind --show-leak-kinds=all --leak-check=full ./xhartae

View File

@ -7,15 +7,17 @@ It is distributed in the hope that it will be useful or harmful, it really depen
*/
#ifdef STATIC_SOURCE
#include "chapters/chapter_0.c"
#include "chapters/chapter_1.c"
#include "chapters/chapter_2.c"
#include "chapters/chapter_3.c"
#include "chapter/chapter_0.c"
#include "chapter/chapter_1.c"
#include "chapter/chapter_2.c"
#include "chapter/chapter_3.c"
#include "chapter/chapter_4.c"
#else
#include "chapters/chapter_0.h"
#include "chapters/chapter_1.h"
#include "chapters/chapter_2.h"
#include "chapters/chapter_3.h"
#include "chapter/chapter_0.h"
#include "chapter/chapter_1.h"
#include "chapter/chapter_2.h"
#include "chapter/chapter_3.h"
#include "chapter/chapter_4.h"
#endif
/*
@ -137,7 +139,7 @@ int main (int argc, char * * argv) {
curses_synchronize ();
}
print ("/1%f/-\n/2// %s/-\n%i\n", 69.1, "Heyo", 420);
program_view_c_file ("program/hello_world.c", curses_screen_width, curses_screen_height, 0, 0);
return (EXIT_SUCCESS);
}