updated makefile
This commit is contained in:
parent
d22c0606c1
commit
dc96712a2d
5 changed files with 15 additions and 14 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -1,2 +1,2 @@
|
|||
build
|
||||
tests/2.in
|
||||
tests
|
||||
|
|
|
|||
4
main.c
4
main.c
|
|
@ -6,8 +6,8 @@
|
|||
#include <time.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#define DEFAULT_NN 10000000
|
||||
#define DEFAULT_N 1001
|
||||
#define DEFAULT_NN 100000
|
||||
#define DEFAULT_N 101
|
||||
#define DEFAULT_B 10
|
||||
#define END_PROGRAM -1
|
||||
#define SUCCESS 0
|
||||
|
|
|
|||
16
makefile
16
makefile
|
|
@ -12,13 +12,19 @@ build/tape.o: tape.c build
|
|||
build:
|
||||
mkdir -p build
|
||||
|
||||
tests:
|
||||
mkdir -p tests
|
||||
|
||||
clean:
|
||||
rm -rf build
|
||||
rm -rf build tests
|
||||
|
||||
run: build/main
|
||||
build/main -f tests/2.in | less
|
||||
run: build/main tests/1.in
|
||||
build/main -f tests/1.in | less
|
||||
|
||||
debug: build/main
|
||||
lldb -- build/main -f tests/2.in
|
||||
debug: build/main tests/1.in
|
||||
lldb -- build/main -f tests/1.in
|
||||
|
||||
tests/1.in: build/main tests
|
||||
build/main -f tests/1.in -r
|
||||
|
||||
.PHONY: clean run debug
|
||||
|
|
|
|||
1
tape.h
1
tape.h
|
|
@ -20,6 +20,7 @@ void sort_buffer(buffer* buff);
|
|||
int read_buffer(buffer* buff, tape* tape);
|
||||
// writes everything
|
||||
int write_buffer(buffer* buff, tape* tape);
|
||||
// for debugging
|
||||
void print_buffer(buffer* buff);
|
||||
|
||||
void clear_tape(tape* tape);
|
||||
|
|
|
|||
|
|
@ -1,6 +0,0 @@
|
|||
11 123 312 312 323 3
|
||||
543 3435 34 5342 532 54
|
||||
344 43534 222 435 2345 23
|
||||
2345 234 23423 455 44 4
|
||||
2345 23222 222 2245 4554 10
|
||||
2345 22 2 22 2 3
|
||||
Loading…
Add table
Add a link
Reference in a new issue