summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile39
1 files changed, 36 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 28d302e0..5f21f32d 100644
--- a/Makefile
+++ b/Makefile
@@ -52,20 +52,28 @@ DEV_DEBUG_FORCE=
# Where exactly do the pieces go?
# UB_DIR = utility binary directory
# ULP_DIR = pkgconfig directory, usually /usr/lib/pkgconfig
+# UI_DIR = include directory for library headers
+# US_DIR = shared data directory (for static content like devkeys)
# DF_DIR = utility defaults directory
# VB_DIR = vboot binary directory for dev-mode-only scripts
ifeq (${MINIMAL},)
# Host install just puts everything where it's told
UB_DIR=${DESTDIR}/bin
-ULP_DIR=${DESTDIR}/${LIBDIR}/pkgconfig
+UL_DIR=${DESTDIR}/${LIBDIR}
+ULP_DIR=${UL_DIR}/pkgconfig
+UI_DIR=${DESTDIR}/include/vboot
+US_DIR=${DESTDIR}/share/vboot
DF_DIR=${DESTDIR}/default
VB_DIR=${DESTDIR}/bin
else
# Target install puts things into different places
UB_DIR=${DESTDIR}/usr/bin
-ULP_DIR=${DESTDIR}/usr/${LIBDIR}/pkgconfig
+UL_DIR=${DESTDIR}/usr/${LIBDIR}
+ULP_DIR=${UL_DIR}/pkgconfig
+UI_DIR=${DESTDIR}/usr/include/vboot
+US_DIR=${DESTDIR}/usr/share/vboot
DF_DIR=${DESTDIR}/etc/default
-VB_DIR=${DESTDIR}/usr/share/vboot/bin
+VB_DIR=${US_DIR}/bin
endif
# Where to install the (exportable) executables for testing?
@@ -785,6 +793,9 @@ clean:
install: cgpt_install utils_install signing_install futil_install \
pc_files_install
+.PHONY: install_dev
+install_dev: headers_install lib_install
+
.PHONY: install_mtd
install_mtd: install cgpt_wrapper_install
@@ -960,6 +971,28 @@ ${TINYHOSTLIB}: ${TINYHOSTLIB_OBJS}
@${PRINTF} " AR $(subst ${BUILD}/,,$@)\n"
${Q}ar qc $@ $^
+.PHONY: headers_install
+headers_install:
+ @${PRINTF} " INSTALL HEADERS\n"
+ ${Q}mkdir -p ${UI_DIR}
+ ${Q}${INSTALL} -t ${UI_DIR} -m644 \
+ host/include/* \
+ firmware/include/gpt.h \
+ firmware/include/tlcl.h \
+ firmware/include/tss_constants.h
+
+.PHONY: lib_install
+lib_install: ${HOSTLIB}
+ @${PRINTF} " INSTALL HOSTLIB\n"
+ ${Q}mkdir -p ${UL_DIR}
+ ${Q}${INSTALL} -t ${UL_DIR} -m644 $^
+
+.PHONY: devkeys_install
+devkeys_install:
+ @${PRINTF} " INSTALL DEVKEYS\n"
+ ${Q}mkdir -p ${US_DIR}/devkeys
+ ${Q}${INSTALL} -t ${US_DIR}/devkeys -m644 tests/devkeys/*
+
# ----------------------------------------------------------------------------
# CGPT library and utility