CC = gcc
CFLAGS = -fPIC -O2 -I/usr/include
LDFLAGS = -shared
LIBS = -lpq

TARGET = pg_vtab.so
SRC = pg_vtab.c

all: $(TARGET)

$(TARGET): $(SRC)
	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LIBS)

clean:
	rm -f $(TARGET)
