summaryrefslogtreecommitdiff
path: root/util/bucts/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'util/bucts/Makefile')
-rw-r--r--util/bucts/Makefile21
1 files changed, 21 insertions, 0 deletions
diff --git a/util/bucts/Makefile b/util/bucts/Makefile
new file mode 100644
index 0000000000..3bc73ee3d6
--- /dev/null
+++ b/util/bucts/Makefile
@@ -0,0 +1,21 @@
+CC:=gcc
+OBJ:=bucts.o
+VERSION:=$(shell git describe)
+CFLAGS+=-Wall
+
+ifeq ($(shell uname), FreeBSD)
+ CFLAGS += -I/usr/local/include
+ LDFLAGS += -L/usr/local/lib
+endif
+
+all: bucts
+
+bucts: $(OBJ)
+ $(CC) -o $@ $(OBJ) $(LDFLAGS) -lpci
+
+%.o: %.c
+ $(CC) $(CFLAGS) -DVERSION='"$(VERSION)"' -c $<
+
+.PHONY: clean
+clean:
+ rm -f bucts $(OBJ)