build: add `fingerprint' target

This commit is contained in:
Franco Fichtner 2019-07-02 08:26:40 +02:00
parent 0f0b6b44b5
commit b22e911fab
4 changed files with 45 additions and 5 deletions

View File

@ -24,11 +24,12 @@
# SUCH DAMAGE. # SUCH DAMAGE.
STEPS= arm base boot chroot clean compress confirm core distfiles \ STEPS= arm base boot chroot clean compress confirm core distfiles \
download dvd info kernel nano plugins ports prefetch print \ download dvd fingerprint info kernel nano plugins ports \
rebase release rename rewind serial sign skim test update \ prefetch print rebase release rename rewind serial sign \
upload verify vga vm xtools skim test update upload verify vga vm xtools
SCRIPTS= batch hotfix nightly SCRIPTS= batch hotfix nightly
.PHONY: ${STEPS}
.PHONY: ${STEPS} ${SCRIPTS}
PAGER?= less PAGER?= less

View File

@ -370,6 +370,11 @@ out on the system can be printed using:
# make info # make info
Repositories that have signing keys can show the current
fingerprint using:
# make fingerprint
Last but not least, in case build variables needs to be inspected, Last but not least, in case build variables needs to be inspected,
they can be printed selectively using: they can be printed selectively using:

View File

@ -256,7 +256,7 @@ export PRODUCT_PLUGIN="os-*${PRODUCT_SUFFIX}"
case "${SELF}" in case "${SELF}" in
confirm|info|print) confirm|fingerprint|info|print)
;; ;;
*) *)
if [ -z "${PRINT_ENV_SKIP}" ]; then if [ -z "${PRINT_ENV_SKIP}" ]; then

34
build/fingerprint.sh Normal file
View File

@ -0,0 +1,34 @@
#!/bin/sh
# Copyright (c) 2019 Franco Fichtner <franco@opnsense.org>
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
# SUCH DAMAGE.
set -e
SELF=fingerprint
. ./common.sh
${PRODUCT_SIGNCHK}