summaryrefslogtreecommitdiff
path: root/Ports/awk/patches/0001-Make-it-possible-to-override-HOSTCC-and-CC-from-the-.patch
blob: c2dc8c75acce51e6f99d395794af65e02735cbb6 (plain)
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
From 54cc5812382bc7d3b5e2d1ef0c3a18a60fa896b7 Mon Sep 17 00:00:00 2001
From: Mattias Nilsson <mattias.nilsson@nshift.com>
Date: Mon, 4 Apr 2022 22:05:38 +0200
Subject: [PATCH 1/2] Make it possible to override HOSTCC and CC from the
 environment

---
 makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/makefile b/makefile
index 9ceaaad..6b9dff5 100644
--- a/makefile
+++ b/makefile
@@ -31,8 +31,8 @@ CFLAGS = -O2
 #CC = gcc -Wall -g -Wwrite-strings
 #CC = gcc -O4 -Wall -pedantic -fno-strict-aliasing
 #CC = gcc -fprofile-arcs -ftest-coverage # then gcov f1.c; cat f1.c.gcov
-HOSTCC = gcc -g -Wall -pedantic -Wcast-qual
-CC = $(HOSTCC)  # change this is cross-compiling.
+HOSTCC ?= gcc -g -Wall -pedantic -Wcast-qual
+CC ?= $(HOSTCC)  # change this is cross-compiling.
 
 # By fiat, to make our lives easier, yacc is now defined to be bison.
 # If you want something else, you're on your own.
-- 
2.36.1