Skip to content
This repository was archived by the owner on May 24, 2022. It is now read-only.

Commit 8f8c65b

Browse files
author
Brane F. Gračnar
committed
Added configuration file support.
This patch adds the following functionality: * configuration file loading * default configuration printout * printing of loaded configuration * configuration testing * nicer --help message * version printing * addresses have new syntax: [HOST]:PORT * HOST,PORT arguments are still supported Stud can still be built without configuration file support by providing NO_CONFIG_FILE=1 argument to make
1 parent 1bc2189 commit 8f8c65b

File tree

6 files changed

+1345
-462
lines changed

6 files changed

+1345
-462
lines changed

Diff for: .gitignore

+5-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,6 @@
1-
conf*
1+
conf
22
ebtree*
3+
core
4+
core.*
5+
*.o
6+
stud

Diff for: Makefile

+6-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ MANDIR = $(PREFIX)/share/man
99

1010
CFLAGS = -O2 -g -std=c99 -fno-strict-aliasing -Wall -W -D_GNU_SOURCE
1111
LDFLAGS = -lssl -lcrypto -lev
12-
OBJS = stud.o ringbuffer.o
12+
OBJS = stud.o ringbuffer.o configuration.o
1313

1414
all: realall
1515

@@ -28,6 +28,11 @@ ebtree:
2828
exit 1 )
2929
endif
3030

31+
# No config file support?
32+
ifneq ($(NO_CONFIG_FILE),)
33+
CFLAGS += -DNO_CONFIG_FILE
34+
endif
35+
3136
ALL += stud
3237
realall: $(ALL)
3338

0 commit comments

Comments
 (0)