Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Side by Side Diff: utility/Makefile

Issue 2919010: Add tpm lite to vboot reference (Closed) Base URL: ssh://gitrw.chromium.org/vboot_reference.git
Patch Set: Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tests/tpm_lite/writelimit.c ('k') | utility/tlcl_generator.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. 1 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 INCLUDES += -I./include \ 5 INCLUDES += -I./include \
6 -I$(FWDIR)/lib/include \ 6 -I$(FWDIR)/lib/include \
7 -I$(FWDIR)/lib/cgptlib/include \ 7 -I$(FWDIR)/lib/cgptlib/include \
8 -I$(FWDIR)/lib/cryptolib/include \ 8 -I$(FWDIR)/lib/cryptolib/include \
9 -I$(FWDIR)/lib/tpm_lite/include \
9 -I$(HOSTDIR)/include 10 -I$(HOSTDIR)/include
10 CFLAGS += $(INCLUDES) 11 CFLAGS += $(INCLUDES)
11 CFLAGS += -MMD -MF $@.d 12 CFLAGS += -MMD -MF $@.d
12 LIBS = $(HOSTLIB) $(FWLIB) 13 LIBS = $(HOSTLIB) $(FWLIB)
13 14
14 BUILD_ROOT = ${BUILD}/utility 15 BUILD_ROOT = ${BUILD}/utility
15 16
16 DESTDIR ?= /usr/bin 17 DESTDIR ?= /usr/bin
17 18
18 TARGET_NAMES = dumpRSAPublicKey \ 19 TARGET_NAMES = dumpRSAPublicKey \
19 dump_kernel_config \ 20 dump_kernel_config \
20 gbb_utility \ 21 gbb_utility \
21 load_kernel_test \ 22 load_kernel_test \
22 signature_digest_utility \ 23 signature_digest_utility \
24 tlcl_generator \
23 vbutil_firmware \ 25 vbutil_firmware \
24 vbutil_kernel \ 26 vbutil_kernel \
25 vbutil_key \ 27 vbutil_key \
26 vbutil_keyblock \ 28 vbutil_keyblock \
27 verify_data 29 verify_data
28 30
29 TARGET_BINS = $(addprefix ${BUILD_ROOT}/,$(TARGET_NAMES)) 31 TARGET_BINS = $(addprefix ${BUILD_ROOT}/,$(TARGET_NAMES))
30 ALL_DEPS = $(addsuffix .d,${TARGET_BINS}) 32 ALL_DEPS = $(addsuffix .d,${TARGET_BINS})
31 33
32 all: $(TARGET_BINS) 34 all: $(TARGET_BINS)
33 35
34 ${BUILD_ROOT}/dumpRSAPublicKey: dumpRSAPublicKey.c 36 ${BUILD_ROOT}/dumpRSAPublicKey: dumpRSAPublicKey.c
35 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ -lcrypto 37 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ -lcrypto
36 38
37 ${BUILD_ROOT}/dump_kernel_config: dump_kernel_config.c $(LIBS) 39 ${BUILD_ROOT}/dump_kernel_config: dump_kernel_config.c $(LIBS)
38 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto 40 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto
39 41
40 ${BUILD_ROOT}/gbb_utility: gbb_utility.cc 42 ${BUILD_ROOT}/gbb_utility: gbb_utility.cc
41 $(CXX) -DWITH_UTIL_MAIN $(CFLAGS) $< -o $@ 43 $(CXX) -DWITH_UTIL_MAIN $(CFLAGS) $< -o $@
42 44
43 ${BUILD_ROOT}/load_kernel_test: load_kernel_test.c $(LIBS) 45 ${BUILD_ROOT}/load_kernel_test: load_kernel_test.c $(LIBS)
44 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto 46 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto
45 47
46 ${BUILD_ROOT}/signature_digest_utility: signature_digest_utility.c $(LIBS) 48 ${BUILD_ROOT}/signature_digest_utility: signature_digest_utility.c $(LIBS)
47 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto 49 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto
48 50
51 ${BUILD_ROOT}/tlcl_generator: tlcl_generator.c $(LIBS)
52 $(CC) $(CFLAGS) $(INCLUDES) -fpack-struct $< -o $@ $(LIBS) -lcrypto
53
49 ${BUILD_ROOT}/vbutil_firmware: vbutil_firmware.c $(LIBS) 54 ${BUILD_ROOT}/vbutil_firmware: vbutil_firmware.c $(LIBS)
50 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto 55 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto
51 56
52 ${BUILD_ROOT}/vbutil_kernel: vbutil_kernel.c $(LIBS) 57 ${BUILD_ROOT}/vbutil_kernel: vbutil_kernel.c $(LIBS)
53 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto 58 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto
54 59
55 ${BUILD_ROOT}/vbutil_key: vbutil_key.c $(LIBS) 60 ${BUILD_ROOT}/vbutil_key: vbutil_key.c $(LIBS)
56 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto 61 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto
57 62
58 ${BUILD_ROOT}/vbutil_keyblock: vbutil_keyblock.c $(LIBS) 63 ${BUILD_ROOT}/vbutil_keyblock: vbutil_keyblock.c $(LIBS)
59 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto 64 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto
60 65
61 ${BUILD_ROOT}/verify_data: verify_data.c $(LIBS) 66 ${BUILD_ROOT}/verify_data: verify_data.c $(LIBS)
62 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto 67 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto
63 68
64 ${BUILD_ROOT}/sign_image: sign_image.c $(LIBS) 69 ${BUILD_ROOT}/sign_image: sign_image.c $(LIBS)
65 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto 70 $(CC) $(CFLAGS) $(INCLUDES) $< -o $@ $(LIBS) -lcrypto
66 71
67 install: $(TARGET_BINS) 72 install: $(TARGET_BINS)
68 mkdir -p $(DESTDIR) 73 mkdir -p $(DESTDIR)
69 cp -f $(TARGET_BINS) $(DESTDIR) 74 cp -f $(TARGET_BINS) $(DESTDIR)
70 chmod a+rx $(patsubst %,$(DESTDIR)/%,$(TARGET_NAMES)) 75 chmod a+rx $(patsubst %,$(DESTDIR)/%,$(TARGET_NAMES))
71 76
77 STRUCTURES_TMP=${BUILD}/tlcl_structures.tmp
78 STRUCTURES_SRC=${FWDIR}/lib/tpm_lite/include/tlcl_structures.h
79
80 update_tlcl_structures: ${BUILD_ROOT}/tlcl_generator
81 ${BUILD_ROOT}/tlcl_generator > $(STRUCTURES_TMP)
82 cmp -s $(STRUCTURES_TMP) $(STRUCTURES_SRC) || \
83 ( echo "%% Updating structures.h %%" && \
84 cp $(STRUCTURES_TMP) $(STRUCTURES_SRC) )
85
72 -include ${ALL_DEPS} 86 -include ${ALL_DEPS}
OLDNEW
« no previous file with comments | « tests/tpm_lite/writelimit.c ('k') | utility/tlcl_generator.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698