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
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
|
Index: hbci4java-2.5.12-src/chipcard/src/frontend/Makefile
===================================================================
--- hbci4java-2.5.12-src.orig/chipcard/src/frontend/Makefile
+++ hbci4java-2.5.12-src/chipcard/src/frontend/Makefile
@@ -4,8 +4,9 @@ INCLUDES = -I../include -I$(JAVA_HOME)/i
WARNINGS = -Wall
# removed "-Werror -pedantic" because of dlsym() typecast problem
-CC = g++
-CFLAGS = -fPIC $(DEFINES) $(INCLUDES) $(WARNINGS)
+CXX ?= g++
+AR ?= ar
+CXXFLAGS += -fPIC $(DEFINES) $(INCLUDES) $(WARNINGS)
LIBS = -L../../bin -lzkachip-highlevel -lzkachip-lowlevel
SOURCES = frontend.cpp
@@ -15,16 +16,16 @@ OBJECTS = ../../bin/frontend.o
.SUFFIXES: .cpp .o
../../bin/%.o: %.cpp
- $(CC) -c -o $@ $(CFLAGS) $<
+ $(CXX) -c -o $@ $(CXXFLAGS) $(LDFLAGS) $<
all: depend ../../bin/libhbci4java-card-linux.so
depend: Makefile.depend
Makefile.depend: $(SOURCES)
- for file in $(SOURCES); do echo -n "../../bin/"; gcc $(CFLAGS) -MM $$file; done >Makefile.depend
+ for file in $(SOURCES); do echo -n "../../bin/"; $(CXX) $(CXXFLAGS) $(LDFLAGS) -MM $$file; done >Makefile.depend
../../bin/libhbci4java-card-linux.so: $(OBJECTS) ../../bin/libzkachip-highlevel.a ../../bin/libzkachip-lowlevel.a
- $(CC) -fPIC -shared -o $@ $(OBJECTS) $(LIBS)
+ $(CXX) $(LDFLAGS) -fPIC -shared -o $@ $(OBJECTS) $(LIBS)
include Makefile.depend
Index: hbci4java-2.5.12-src/chipcard/src/highlevel/Makefile
===================================================================
--- hbci4java-2.5.12-src.orig/chipcard/src/highlevel/Makefile
+++ hbci4java-2.5.12-src/chipcard/src/highlevel/Makefile
@@ -4,9 +4,9 @@ INCLUDES = -I../include
WARNINGS = -Wall
# removed "-Werror -pedantic" because of dlsym() typecast problem
-CC = g++
-AR = ar
-CFLAGS = -fPIC $(DEFINES) $(INCLUDES) $(WARNINGS)
+CXX ?= g++
+AR ?= ar
+CXXFLAGS += -fPIC $(DEFINES) $(INCLUDES) $(WARNINGS)
SOURCES = hbci_cardtype.cpp \
ddv_decrypt.cpp \
@@ -37,14 +37,14 @@ OBJECTS = ../../bin/hbci_cardtype.o \
.SUFFIXES: .cpp .o
../../bin/%.o: %.cpp
- $(CC) -c -o $@ $(CFLAGS) $<
+ $(CXX) -c -o $@ $(CXXFLAGS) $(LDFLAGS) $<
all: depend ../../bin/libzkachip-highlevel.a
depend: Makefile.depend
Makefile.depend: $(SOURCES)
- for file in $(SOURCES); do echo -n "../../bin/"; gcc $(CFLAGS) -MM $$file; done >Makefile.depend
+ for file in $(SOURCES); do echo -n "../../bin/"; $(CXX) $(CXXFLAGS) $(LDFLAGS) -MM $$file; done >Makefile.depend
../../bin/libzkachip-highlevel.a: $(OBJECTS)
$(AR) rcsv $@ $(OBJECTS)
Index: hbci4java-2.5.12-src/chipcard/src/lowlevel/Makefile
===================================================================
--- hbci4java-2.5.12-src.orig/chipcard/src/lowlevel/Makefile
+++ hbci4java-2.5.12-src/chipcard/src/lowlevel/Makefile
@@ -4,9 +4,9 @@ INCLUDES = -I../include
WARNINGS = -Wall
# removed "-Werror -pedantic" because of dlsym() typecast problem
-CC = g++
-AR = ar
-CFLAGS = -fPIC $(DEFINES) $(INCLUDES) $(WARNINGS)
+CXX ?= g++
+AR ?= ar
+CXXFLAGS += -fPIC $(DEFINES) $(INCLUDES) $(WARNINGS)
SOURCES = atr.cpp \
bcs.cpp \
@@ -41,14 +41,14 @@ OBJECTS = ../../bin/atr.o \
.SUFFIXES: .cpp .o
../../bin/%.o: %.cpp
- $(CC) -c -o $@ $(CFLAGS) $<
+ $(CXX) -c -o $@ $(CXXFLAGS) $(LDFLAGS) $<
all: depend ../../bin/libzkachip-lowlevel.a
depend: Makefile.depend
Makefile.depend: $(SOURCES)
- for file in $(SOURCES); do echo -n "../../bin/"; gcc $(CFLAGS) -MM $$file; done >Makefile.depend
+ for file in $(SOURCES); do echo -n "../../bin/"; $(CXX) $(CXXFLAGS) $(LDFLAGS) -MM $$file; done >Makefile.depend
../../bin/libzkachip-lowlevel.a: $(OBJECTS)
$(AR) rcsv $@ $(OBJECTS)
Index: hbci4java-2.5.12-src/chipcard/src/tools/Makefile
===================================================================
--- hbci4java-2.5.12-src.orig/chipcard/src/tools/Makefile
+++ hbci4java-2.5.12-src/chipcard/src/tools/Makefile
@@ -4,8 +4,9 @@ INCLUDES = -I../include
WARNINGS = -Wall
# removed "-Werror -pedantic" because of dlsym() typecast problem
-CC = g++
-CFLAGS = -fPIC $(DEFINES) $(INCLUDES) $(WARNINGS)
+CXX ?= g++
+AR ?= ar
+CXXFLAGS += -fPIC $(DEFINES) $(INCLUDES) $(WARNINGS)
LIBS = -L../../bin -lzkachip-highlevel -lzkachip-lowlevel -ldl
SOURCES = t_hbci_cardinfo.cpp \
@@ -29,15 +30,15 @@ PROGRAMS = ../../bin/t_hbci_cardinfo \
.SUFFIXES: .cpp .o
../../bin/%.o: %.cpp
- $(CC) -c -o $@ $(CFLAGS) $<
+ $(CXX) -c -o $@ $(CXXFLAGS) $(LDFLAGS) $<
../../bin/%: ../../bin/%.o ../../bin/libzkachip-highlevel.a ../../bin/libzkachip-lowlevel.a
- $(CC) -fPIC -o $@ $< $(LIBS)
+ $(CXX) -fPIC -o $@ $< $(LIBS)
all: depend $(PROGRAMS)
depend: Makefile.depend
Makefile.depend: $(SOURCES)
- for file in $(SOURCES); do echo -n "../../bin/"; gcc $(CFLAGS) -MM $$file; done >Makefile.depend
+ for file in $(SOURCES); do echo -n "../../bin/"; $(CXX) $(CXXFLAGS) $(LDFLAGS) -MM $$file; done >Makefile.depend
include Makefile.depend
|