We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 30fa238 commit c701b24Copy full SHA for c701b24
.gitignore
@@ -1 +1,2 @@
1
promptus
2
+config.h
Makefile
@@ -1,5 +1,7 @@
TARGET = promptus
SRC = promptus.c
3
+CONF = config.h
4
+DEFCONF = config.def.h
5
PREFIX ?= /usr/local
6
7
CFLAGS += -O3 -std=c11 -Wall -W -pedantic
@@ -9,9 +11,12 @@ CPPFLAGS += -D_POSIX_C_SOURCE=1
9
11
10
12
all: $(TARGET)
13
-$(TARGET): config.h $(SRC)
14
+$(TARGET): $(CONF) $(SRC)
15
$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) $(SRC) -o $@
16
17
+$(CONF):
18
+ @cp -v $(DEFCONF) $(CONF)
19
+
20
install: $(TARGET)
21
mkdir -p $(DESTDIR)$(PREFIX)/bin
22
install -m755 $(TARGET) $(DESTDIR)$(PREFIX)/bin/$(TARGET)
config.h renamed to config.def.h
0 commit comments