-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.in
103 lines (78 loc) · 3.06 KB
/
Makefile.in
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
#
# @version 0.1.2 (2010)
# @author Paolo Margara <[email protected]>
#
# Copyright 2010 Paolo Margara
#
# This file is part of Engine_cudamrg.
#
# Engine_cudamrg is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License or
# any later version.
#
# Engine_cudamrg is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Engine_cudamrg. If not, see <http://www.gnu.org/licenses/>.
#
CC = @CC@
NVCC = @NVCC@
VERSION = @VERSION@
LDFLAGS= @LDFLAGS@
NVLDFLAGS= @NVLDFLAGS@
CPPFLAGS= @CPPFLAGS@
NVCPPFLAGS= @NVCPPFLAGS@
CFLAGS= @CFLAGS@
NVCFLAGS_LIBS = @NVCFLAGS@ --compiler-options '@CFLAGS@'
NVCFLAGS_TEST = @NVCFLAGS@ --compiler-options '@CFLAGS_TEST@'
LIBS = @LIBS@
LIBNAME = libcudamrg.so
TESTNAME= teststate
LIBSRC = e_cuda.c aes_cuda.cu
TESTSRC= teststate.c aes_cuda.cu
SOURCES= aes_cuda.cu e_cuda.c teststate.c
HEADERS= aes_cuda.h
OTHERFILES= configure COPYING openssl.cnf.example README CHANGES configure.in Makefile.in
OTHER_DIRS= openssl-patch test-enc test-speed test-file
OTHER_DIRS_CONTENT= openssl-patch/openssl-0.9.8.k-apps_speed.c.patch test-enc/aes-ecb-decrypt.plt test-enc/test-enc-plot.sh test-speed/aes-ecb-decrypt.plt \
openssl-patch/openssl-0.9.8.k-crypto_evp_bio_enc.c.patch test-enc/aes-ecb-encrypt.plt test-file/test-file.sh test-speed/aes-ecb-encrypt.plt test-enc/aes-cbc-decrypt.plt \
test-enc/test-enc-cpu.sh test-speed/aes-cbc-decrypt.plt test-enc/aes-cbc-encrypt.plt test-enc/test-enc-gpu.sh test-speed/aes-cbc-encrypt.plt test-speed/test-speed.sh
ALLFILES=$(SOURCES) $(HEADERS) $(OTHERFILES) $(OTHER_DIRS)
distdir= @DISTDIR@
tarname= @TARNAME@
LIBOBJ = e_cuda.o aes_cuda.o
TESTOBJ= aes_cuda.o teststate.o
all: lib test
test: $(TESTSRC)
$(NVCC) $(NVCPPFLAGS) $(NVCFLAGS_TEST) $(NVLDFLAGS) $(LIBS) -o $(TESTNAME) $(TESTSRC)
lib: $(LIBOBJ)
$(CC) -shared -Wl,-soname,$(LIBNAME) $(CFLAGS_LIBS) $(CPPFLAGS) $(LDFLAGS) $(LIBS) -o $(LIBNAME) $(LIBOBJ)
aes_cuda.o: aes_cuda.cu
$(NVCC) $(NVCPPFLAGS) $(NVCFLAGS_LIBS) -c -o $@ aes_cuda.cu
install: lib
mkdir -p @prefix@/@ENGINEDIR@
cp $(LIBNAME) @prefix@/@ENGINEDIR@
chmod 644 @prefix@/@ENGINEDIR@/$(LIBNAME)
uninstall:
-rm -f @prefix@/@ENGINEDIR@/$(LIBNAME)
clean:
rm -f *.o *.obj lib tags core .pure *.out .nfs* *.old *.bak fluff *.linkinfo *.so *.a teststate
distclean: clean FORCE
rm -f config.* Makefile
dist: $(tarname)
$(tarname): $(distdir)
tar cvzf $(tarname) $(distdir)
rm -rf $(distdir)
$(distdir): $(ALLFILES) FORCE
mkdir -p $(distdir)
cp $(SOURCES) $(HEADERS) $(OTHERFILES) $(distdir)
for i in $(OTHER_DIRS); do mkdir -p $(distdir)/$$i; done
for i in $(OTHER_DIRS_CONTENT); do cp $$i $(distdir)/$$i; done
FORCE:
-rm -rf $(distdir)
-rm -f $(tarname)
.PHONY: all clean distclean dist FORCE install uninstall