summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.txt6
-rw-r--r--Makefile8
-rw-r--r--include/agbsum.h2
3 files changed, 13 insertions, 3 deletions
diff --git a/CHANGELOG.txt b/CHANGELOG.txt
index 42fadc8..2fa62cb 100644
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -1,3 +1,9 @@
+| B
+
+- Fortify sources;
+- Enable debug symbols;
+- Enable optimisations;
+
| A
- Use generic makefile instead of CMake;
diff --git a/Makefile b/Makefile
index 0708815..8c17af6 100644
--- a/Makefile
+++ b/Makefile
@@ -1,16 +1,18 @@
RM := rm -f
CFLAGS = \
+ -D_FORTIFY_SOURCE=2 \
+ -D_GNU_SOURCE \
-Iinclude \
+ -O3 \
-Wall \
-Wextra \
-Wmissing-declarations \
-Wpedantic \
+ -g \
-o$(@) \
-std=c99
-BIN := agbsum
-
OBJS := \
src/chkpar.o \
src/exi.o \
@@ -22,6 +24,8 @@ OBJS := \
src/pat.o \
src/red.o
+BIN := agbsum
+
$(BIN): $(OBJS)
$(CC) -o$(BIN) $(OBJS)
diff --git a/include/agbsum.h b/include/agbsum.h
index e0f207c..a7fa31b 100644
--- a/include/agbsum.h
+++ b/include/agbsum.h
@@ -24,7 +24,7 @@
# define noreturn
#endif
-#define agb_rel ((uint64_t)+0xAu)
+#define agb_rel ((uint64_t)+0xBu)
#define agb_romsrt ((size_t)+0xA0u)
#define agb_chksumoff ((size_t)+0xBDu-agb_romsrt)