Check-in [88d2f36ad4]
Overview
Comment:Refer to correct PC/SC headers and link to zlib in final target
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 88d2f36ad4acc74e6712b8105569d14449698e7b
User & Date: rkeene on 2016-02-04 17:50:08
Other Links: manifest | tags
Context
2016-02-04
18:07
Create a native manifest for CACKey on Chrome and other fixups check-in: b0a1326758 user: rkeene tags: trunk
17:50
Refer to correct PC/SC headers and link to zlib in final target check-in: 88d2f36ad4 user: rkeene tags: trunk
17:36
Better work towards a Chrome plugin check-in: 7c7e9cf4fc user: rkeene tags: trunk
Changes

Modified build/chrome/Makefile from [b979ca24ac] to [9643cb7ce4].

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
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






-
+










-
+
















+
+
+
+
+





-
+







CC       = pnacl-clang
CXX      = pnacl-clang++
AR       = pnacl-ar
RANLIB   = pnacl-ranlib
FINALIZE = pnacl-finalize

CACKEY_LIBS = -Llib -lcackey
CACKEY_LIBS = -Llib -lcackey -lz
PCSC_LIBS   = -Llib -lpcsc -L${NACL_SDK_ROOT}/lib/pnacl/Release -lppapi -lppapi_cpp
LIBS        = $(CACKEY_LIBS) $(PCSC_LIBS)
CFLAGS      = -Wall -I${NACL_SDK_ROOT}/include
CXXFLAGS    = $(CFLAGS)

PATH += :${NACL_SDK_ROOT}/toolchain/linux_pnacl/bin
export PATH

all: cackey.pexe

cackey.pexe: cackey-chrome.o cackey-chrome-init.o lib/libcackey.a lib/libpcsc.a
cackey.pexe: cackey-chrome.o cackey-chrome-init.o lib/libcackey.a lib/libpcsc.a lib/libz.a
	$(CXX) -o cackey.pexe.new cackey-chrome.o cackey-chrome-init.o $(LIBS)
	$(FINALIZE) cackey.pexe.new
	mv cackey.pexe.new cackey.pexe

lib/libcackey.a: build-deps
	mkdir -p lib
	rm -f lib/libcackey.a
	rm -rf workdir-*
	./build-deps
	cd lib && ln -s ../workdir-*.inst/lib/libcackey.a .

lib/libpcsc.a: lib/libcackey.a
	mkdir -p lib
	rm -f lib/libpcsc.a
	cd lib && ln -s ../workdir-*.inst/lib/libpcsc.a .

lib/libz.a: lib/libcackey.a
	mkdir -p lib
	rm -f lib/libz.a
	cd lib && ln -s ../workdir-*.inst/lib/libz.a .

cackey-chrome.o: cackey-chrome.c
cackey-chrome-init.o: cackey-chrome-init.cc

clean:
	rm -rf workdir-*
	rm -f lib/libcackey.a lib/libpcsc.a
	rm -f lib/libcackey.a lib/libpcsc.a lib/libz.a
	-rmdir lib
	rm -f cackey-chrome.o cackey-chrome-init.o
	rm -f cackey.pexe

distclean: clean

.PHONY: all clean distclean

Modified build/chrome/build-deps from [cf02f45fdc] to [93232701c1].

193
194
195
196
197
198
199
200



201
202
203
204
205
206
207
193
194
195
196
197
198
199

200
201
202
203
204
205
206
207
208
209







-
+
+
+








		./bootstrap.sh --prefix="${instdir}" --with-python=false --without-libraries='atomic,chrono,container,context,coroutine,date_time,exception,filesystem,graph,graph_parallel,iostreams,locale,log,math,mpi,program_options,python,random,regex,serialization,signals,system,test,thread,timer,wave' || exit 1

		echo "using gcc : pnacl : ${CXX} ;" >> project-config.jam

		./b2 --debug-configuration toolset=gcc-pnacl target-os=linux link=static runtime-link=static || exit 1

		./bjam install || exit 1
		./bjam install | grep -v '^common.copy '

		exit 0
	) || return 1

	rm -rf "${workdir}"

	return 0
}

302
303
304
305
306
307
308
309

310
311
312
313
314
315
316
304
305
306
307
308
309
310

311
312
313
314
315
316
317
318







-
+







	buildPCSC || return 1

	(
		cd ../.. || exit 1

		make distclean

		./configure --host=nacl --with-pcsc-libs="-lpcsc" cackey_cv_pcsc_works=okay || exit 1
		./configure --host=nacl --with-pcsc-headers="${instdir}/include/PCSC" --with-pcsc-libs="-lpcsc" cackey_cv_pcsc_works=okay || exit 1
		make || exit 1
	) || return 1

	mkdir -p "${instdir}/lib"
	cp ../../libcackey.a ../../libcackey_g.a "${instdir}/lib" || return 1

	return 0