summaryrefslogtreecommitdiffstats
path: root/userspace/Makefile
diff options
context:
space:
mode:
authorMiloslav Trmač <mitr@redhat.com>2010-08-07 07:14:40 +0200
committerMiloslav Trmač <mitr@redhat.com>2010-08-23 20:01:59 +0200
commit6e6fafa6663724240e202ee95908b476e7443075 (patch)
tree3df0272e34b5c47bf23d2bd676acd9bab73d6bba /userspace/Makefile
parent0d21420d4e3449f84ff4bd8562a33caf9ad5d63a (diff)
Abstract <linux/ncr.h> from <ncrypto.h> users
Let <ncrypto.h> users #include this header file alone, without caring about <linux/ncr.h>. To do so, set up a temporary copy of ncr.h so that the #include <linux/ncr.h> works at build time as well.
Diffstat (limited to 'userspace/Makefile')
-rw-r--r--userspace/Makefile10
1 files changed, 8 insertions, 2 deletions
diff --git a/userspace/Makefile b/userspace/Makefile
index b87bf0c..9156205 100644
--- a/userspace/Makefile
+++ b/userspace/Makefile
@@ -1,5 +1,5 @@
CC = gcc
-CFLAGS = -Wall -g -O2 -fPIC
+CFLAGS = -I. -Wall -g -O2 -fPIC
progs := ncr-setkey
@@ -15,5 +15,11 @@ libcryptodev.so: ${libobj}
ln -sf libcryptodev.so.0.0 libcryptodev.so.0
ln -sf libcryptodev.so.0.0 libcryptodev.so
+$(libobj): linux/ncr.h
+
+linux/ncr.h: ../ncr.h
+ mkdir -p linux
+ cp $< linux/ncr.h
+
clean:
- rm -f *.o *~ libcryptodev.so* ncr-setkey
+ rm -rf *.o *~ libcryptodev.so* ncr-setkey linux