-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathMakefile
More file actions
27 lines (19 loc) · 672 Bytes
/
Copy pathMakefile
File metadata and controls
27 lines (19 loc) · 672 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
PREFIX = /usr
PAMDIR = $(PREFIX)/lib/security
CC = cc
CFLAGS = -Os -Wall -Wextra -Wpedantic -Wconversion -Werror
PAMFLAGS = $$(pkg-config --cflags --libs pam)
RUNTIME_DIR_PARENT = /run/user
pam_dumb_runtime_dir.so: pam_dumb_runtime_dir.c
$(CC) -o $@ pam_dumb_runtime_dir.c -shared -fPIC -std=c99 \
$(PAMFLAGS) $(CFLAGS) $(LDFLAGS) \
'-DRUNTIME_DIR_PARENT="$(RUNTIME_DIR_PARENT)"'
.PHONY: all install uninstall clean
all: pam_dumb_runtime_dir.so
install: pam_dumb_runtime_dir.so
mkdir -p $(DESTDIR)$(PAMDIR)
cp -f pam_dumb_runtime_dir.so $(DESTDIR)$(PAMDIR)
uninstall:
rm -f $(DESTDIR)$(PAMDIR)/pam_dumb_runtime_dir.so
clean:
rm -f pam_dumb_runtime_dir.so