Skip to content

Commit

Permalink
Use pkgconfig to determine library destination
Browse files Browse the repository at this point in the history
  • Loading branch information
oskar456 committed Aug 3, 2017
1 parent ab9718e commit 7065e22
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
11 changes: 3 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
#

NAME = xt_dns
VERSION = 1.4
VERSION = 1.5
DISTFILES = *.[ch] Makefile ChangeLog

KVERSION = $(shell uname -r)
KDIR = /lib/modules/$(KVERSION)/build
MDIR = /lib/modules/$(KVERSION)/local/
XDIR = /lib/xtables/ /lib64/xtables/
XDIR = `pkg-config xtables --variable xtlibdir`
IPTABLES = iptables
IP6TABLES = ip6tables

Expand Down Expand Up @@ -50,12 +50,7 @@ module-install: xt_dns.ko
sync

userspace-install: libxt_dns.so
for xdir in $(XDIR); do \
if [ -d $${xdir} ]; then \
install *.so $${xdir}; \
break; \
fi; \
done
install libxt_dns.so $(XDIR)

clean:
rm -f libxt_dns.so config.h
Expand Down
2 changes: 1 addition & 1 deletion dkms.conf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PACKAGE_NAME="xt_dns"
PACKAGE_VERSION="1.4"
PACKAGE_VERSION="1.5"
CLEAN="make clean"
MAKE[0]="make module KVERSION=$kernelver"
BUILT_MODULE_NAME[0]="xt_dns"
Expand Down

0 comments on commit 7065e22

Please sign in to comment.