summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile8
1 files changed, 6 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index b7eae33..3acb272 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,5 @@
TOPDIR=$(shell pwd)
+UNAME=$(shell uname)
INSTALL=install
PREFIX=/usr
@@ -14,13 +15,16 @@ CFLAGS += -std=c99
CFLAGS += -pipe
CFLAGS += -Wall
CPPFLAGS += -D_GNU_SOURCE
-CPPFLAGS += -DUSE_PAM
CFLAGS += $(shell $(PKG_CONFIG) --cflags cairo xcb-composite xcb-xinerama xcb-atom xcb-image xcb-xkb xkbcommon xkbcommon-x11)
LIBS += $(shell $(PKG_CONFIG) --libs cairo xcb-composite xcb-xinerama xcb-atom xcb-image xcb-xkb xkbcommon xkbcommon-x11)
-LIBS += -lpam
LIBS += -lev
LIBS += -lm
+# OpenBSD lacks PAM, use bsd_auth(3) instead.
+ifneq ($(UNAME),OpenBSD)
+ LIBS += -lpam
+endif
+
FILES:=$(wildcard *.c)
FILES:=$(FILES:.c=.o)