aboutsummaryrefslogtreecommitdiffstats
path: root/service
diff options
context:
space:
mode:
Diffstat (limited to 'service')
-rw-r--r--service/.gitignore1
-rw-r--r--service/do.sh11
-rw-r--r--service/src/.gitignore1
-rw-r--r--service/src/patches/flagstore1.diff6
-rw-r--r--service/src/patches/flagstore2.diff6
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);