]> git.sesse.net Git - freerainbowtables/blob - BOINC software/BOINC client apps/distrrtgen/Makefile
64-bit fixes for distrrtgen
[freerainbowtables] / BOINC software / BOINC client apps / distrrtgen / Makefile
1 # freerainbowtables is a project for generating, distributing, and using
2 # perfect rainbow tables
3 #
4 # Copyright (C) Zhu Shuanglei <shuanglei@hotmail.com>
5 # Copyright Martin Westergaard Jørgensen <martinwj2005@gmail.com>
6 # Copyright 2009, 2010 Daniël Niggebrugge <niggebrugge@fox-it.com>
7 # Copyright 2009, 2010 James Nobis <frt@quelrod.net>
8 #
9 # This file is part of freerainbowtables.
10 #
11 # freerainbowtables is free software: you can redistribute it and/or modify
12 # it under the terms of the GNU General Public License as published by
13 # the Free Software Foundation, either version 2 of the License, or
14 # (at your option) any later version.
15 #
16 # freerainbowtables is distributed in the hope that it will be useful,
17 # but WITHOUT ANY WARRANTY; without even the implied warranty of
18 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19 # GNU General Public License for more details.
20 #
21 # You should have received a copy of the GNU General Public License
22 # along with freerainbowtables.  If not, see <http://www.gnu.org/licenses/>.
23
24 SHELL = /bin/sh
25
26 #BOINC_DIR = /home/ubuntu/boinc
27 BOINC_DIR = /usr/share/boinc-dev
28 BOINC_API_DIR = $(BOINC_DIR)/api
29 BOINC_LIB_DIR = $(BOINC_DIR)/lib
30 COMMON_LIB_DIR = /usr/lib
31
32 OPTIMIZATION = -O3
33
34 CXXFLAGS = -g \
35     -static -static-libgcc \
36     -I$(BOINC_DIR) \
37     -I$(BOINC_LIB_DIR) \
38     -I$(BOINC_API_DIR) \
39          -Wall \
40          -c \
41          -DBOINC \
42          $(OPTIMIZATION)
43
44 LFLAGS = -static -static-libgcc -Wall $(OPTIMIZATION) -L$(BOINC_API_DIR) \
45         -L$(BOINC_LIB_DIR) -L /usr/X11R6/lib -L.
46
47 LIBS = -lboinc_api -lboinc -lpthread -lssl libstdc++.a $(COMMON_LIB_DIR)/libssl.a $(COMMON_LIB_DIR)/libpthread.a
48 OBJS = ChainWalkContext.o des_enc.o des_setkey.o distrrtgen.o ecb_enc.o HashAlgorithm.o HashRoutine.o md4.o md5.o Public.o
49
50 OSNAME = $(shell uname -s)
51
52 all: distrrtgen
53
54 distrrtgen: libstdc++.a $(BOINC_API_DIR)/libboinc_api.a $(BOINC_LIB_DIR)/libboinc.a $(OBJS)
55         $(CXX) $(LFLAGS) $(OBJS) $(LIBS) -o distrrtgen
56
57 libstdc++.a:
58         ln -s `g++ -print-file-name=libstdc++.a`
59
60 clean:
61         /bin/rm -f distrrtgen *.o
62
63 distclean:
64         /bin/rm -f distrrtgen *.o libstdc++.a
65
66 rebuild: clean all
67
68 ChainWalkContext.o: ChainWalkContext.h ChainWalkContext.cpp HashRoutine.h Public.h
69         $(CXX) $(CXXFLAGS) ChainWalkContext.cpp
70
71 des_enc.o: des_enc.c des_locl.h spr.h
72         $(CXX) $(CXXFLAGS) des_enc.c
73
74 des_setkey.o: des_setkey.c des_locl.h podd.h sk.h
75         $(CXX) $(CXXFLAGS) des_setkey.c
76
77 distrrtgen.o: distrrtgen.cpp distrrtgen.h ChainWalkContext.h Public.h
78         $(CXX) $(CXXFLAGS) distrrtgen.cpp
79
80 ecb_enc.o: ecb_enc.c des_locl.h spr.h
81         $(CXX) $(CXXFLAGS) ecb_enc.c
82
83 HashAlgorithm.o: HashAlgorithm.h HashAlgorithm.cpp Public.h md4.h md5.h
84         $(CXX) $(CXXFLAGS) HashAlgorithm.cpp
85
86 HashRoutine.o: HashRoutine.h HashRoutine.cpp global.h HashAlgorithm.h
87         $(CXX) $(CXXFLAGS) HashRoutine.cpp
88
89 md4.o: md4.h md4.cpp global.h
90         $(CXX) $(CXXFLAGS) md4.cpp
91
92 md5.o: md5.h md5.cpp global.h
93         $(CXX) $(CXXFLAGS) md5.cpp
94
95 Public.o: Public.h Public.cpp global.h
96         $(CXX) $(CXXFLAGS) Public.cpp