diff options
| author | Louis Burda <quent.burda@gmail.com> | 2021-05-19 20:49:04 +0200 |
|---|---|---|
| committer | Louis Burda <quent.burda@gmail.com> | 2021-05-19 20:49:04 +0200 |
| commit | ea33a19c447df8cc3748a8b6dc8e45121fdc3570 (patch) | |
| tree | a4aaf6c2a7cf45fb9bc76b74ce2c48fa18d681de | |
| parent | edd8a25cb8b469d8649e83fbbedac9a6ae87b521 (diff) | |
| download | enowars5-service-stldoctor-ea33a19c447df8cc3748a8b6dc8e45121fdc3570.tar.gz enowars5-service-stldoctor-ea33a19c447df8cc3748a8b6dc8e45121fdc3570.zip | |
fixed flagstore patch targets and added temp file for keeping track of safe builds without recompiling each run
| -rw-r--r-- | service/.gitignore | 1 | ||||
| -rw-r--r-- | service/do.sh | 11 | ||||
| -rw-r--r-- | service/src/.gitignore | 1 | ||||
| -rw-r--r-- | service/src/patches/flagstore1.diff | 6 | ||||
| -rw-r--r-- | service/src/patches/flagstore2.diff | 6 |
5 files changed, 13 insertions, 12 deletions
diff --git a/service/.gitignore b/service/.gitignore index 648ea81..5ca3e64 100644 --- a/service/.gitignore +++ b/service/.gitignore @@ -1,3 +1,4 @@ data/* !data/.keep .cleansrc +src/.safebuild diff --git a/service/do.sh b/service/do.sh index 9a4823d..168d495 100644 --- a/service/do.sh +++ b/service/do.sh @@ -54,14 +54,19 @@ elif [ "$1" == "cleansrc" ]; then elif [ "$1" == "test" ]; then SRCDIR="$PWD/src" DATADIR="$PWD/data" bash "tests/test.sh" ${@:2} elif [ "$1" == "make" ]; then + # build a normal version cd src - - make clean + if [ -e ".safebuild" ]; then + make clean + rm ".safebuild" + fi make elif [ "$1" == "make-safe" ]; then - cd "src" + # build a 'safe' version with flagstore patches + cd src make clean + touch ".safebuild" for f in $(ls | grep '\.[ch]$'); do cp "$f" "safe_$f" diff --git a/service/src/.gitignore b/service/src/.gitignore index edaffd1..5f14e4d 100644 --- a/service/src/.gitignore +++ b/service/src/.gitignore @@ -1,5 +1,4 @@ stldoctor -scans *.o vgcore.* safe_* diff --git a/service/src/patches/flagstore1.diff b/service/src/patches/flagstore1.diff index 0b5fe05..f0f8d4a 100644 --- a/service/src/patches/flagstore1.diff +++ b/service/src/patches/flagstore1.diff @@ -1,7 +1,5 @@ -diff --git a/service/src/util.c b/service/src/util.c -index 31a2628..354bbca 100644 ---- a/service/src/util.c -+++ b/service/src/util.c +--- a/service/src/safe_util.c ++++ b/service/src/safe_util.c @@ -78,13 +78,12 @@ void freadstr(FILE *f, char **dst) { diff --git a/service/src/patches/flagstore2.diff b/service/src/patches/flagstore2.diff index ef6f524..b34a0c0 100644 --- a/service/src/patches/flagstore2.diff +++ b/service/src/patches/flagstore2.diff @@ -1,7 +1,5 @@ -diff --git a/service/src/util.c b/service/src/util.c -index 31a2628..bf272db 100644 ---- a/service/src/util.c -+++ b/service/src/util.c +--- a/service/src/safe_util.c ++++ b/service/src/safe_util.c @@ -58,7 +58,7 @@ mhash(const char *str, int len) srand(v); |
