Skip to content

Commit 3796257

Browse files
committed
Add Makefile for sockhub
1 parent d82f023 commit 3796257

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

contrib/pg_xtm/sockhub/Makefile

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
CC = gcc
2+
CFLAGS = -c -I. -Wall -O0 -g
3+
LD = $(CC)
4+
LDFLAGS = -g
5+
AR = ar
6+
ARFLAGS = -cru
7+
8+
all: sockhub libsockhub.a
9+
10+
sockhup.o: sockhub.c sockhub.h
11+
$(CC) $(CFLAGS) sockhub.c
12+
13+
sockhup_main.o: sockhub_main.c sockhub.h
14+
$(CC) $(CFLAGS) sockhub_main.c
15+
16+
libsockhub.a: sockhub.o
17+
rm -f libsockhub.a
18+
$(AR) $(ARFLAGS) libsockhub.a sockhub.o
19+
20+
sockhub: sockhub_main.o libsockhub.a
21+
$(LD) $(LDFLAGS) -o sockhub sockhub_main.o libsockhub.a
22+
23+
clean:
24+
rm *.o *.a

0 commit comments

Comments
 (0)