summaryrefslogtreecommitdiff
path: root/lang/harec/files/patch-configs_freebsd.mk
blob: ee46f7d3c6a0cc5111e239bccf7e96dfd5c32b6a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
--- configs/freebsd.mk.orig	2024-07-14 11:26:54 UTC
+++ configs/freebsd.mk
@@ -5,20 +5,20 @@ ARCH = x86_64
 # variables used during build
 PLATFORM = freebsd
 ARCH = x86_64
-HARECFLAGS =
+HARECFLAGS = -a ${ARCH}
 QBEFLAGS =
 ASFLAGS =
 LDLINKFLAGS = --gc-sections -z noexecstack
-CFLAGS = -g -std=c11 -D_XOPEN_SOURCE=700 -Iinclude \
+CFLAGS += -std=c11 -D_XOPEN_SOURCE=700 -Iinclude \
 	-Wall -Wextra -Werror -pedantic -Wno-unused-parameter
-LDFLAGS =
-LIBS = -lm
+LDFLAGS ?=
+LIBS += -lm
 
 # commands used by the build script
-CC = cc
-AS = as
-LD = ld
-QBE = qbe
+CC ?= cc
+AS ?= as
+LD ?= ld
+QBE ?= qbe
 
 # build locations
 HARECACHE = .cache
@@ -26,4 +26,4 @@ DEFAULT_TARGET = $(ARCH)
 
 # variables that will be embedded in the binary with -D definitions
 DEFAULT_TARGET = $(ARCH)
-VERSION = $$(./scripts/version)
+VERSION ?= $$(./scripts/version)