-
Notifications
You must be signed in to change notification settings - Fork 30
Expand file tree
/
Copy pathMakefile
More file actions
47 lines (37 loc) · 758 Bytes
/
Makefile
File metadata and controls
47 lines (37 loc) · 758 Bytes
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
38
39
40
41
42
43
44
45
46
47
### Makefile
###
### Create: 2009-12-17
### Updated: 2012-06-21
###
UNAME ?= $(shell uname -s)
WINVER ?= $(shell ver)
CC=gcc
CFLAGS=
LDLIBS=
## for Mac OS X environment, use one of options
ifeq ($(UNAME), Darwin)
CFLAGS=-DBIND_8_COMPAT=1
LDLIBS=-lresolv
endif
## for Solaris
ifeq ($(UNAME), SunOS)
LDLIBS=-lresolv -lsocket -lnsl
endif
## for Microsoft Windows native
ifeq ($(findstring Windows, ${WINVER}), Windows)
ifeq (${CC}, clang)
CFLAGS=-ccc-gcc-name llvm-gcc.exe
LDLIBS=-ccc-gcc-name llvm-gcc.exe
endif
LDLIBS := ${LDLIBS} -lws2_32 -liphlpapi
endif
all: connect
connect: connect.o
connect.o: connect.c
##
clean:
rm -f connect.o *~
veryclean: clean
rm -f connect connect.exe
rebuild: veryclean all
### End of Makefile