mirror of
https://github.com/flatcar/scripts.git
synced 2025-08-24 07:51:03 +02:00
remove(app-crypt/trousers): Drop unneeded TPM code.
This simplifies the build process, we have no need for trousers or other tpm related things from ChromeOS. Bump vboot_reference so it no longer needs trousers as a build dependency.
This commit is contained in:
parent
4e7856f32e
commit
fd5da441ca
@ -1,55 +0,0 @@
|
||||
# Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header$
|
||||
|
||||
EAPI="2"
|
||||
CROS_WORKON_COMMIT="310a21ef24ace14b4d6e8095172445494f54ff25"
|
||||
CROS_WORKON_TREE="33cbcef6b44783d7ece0dcb7f5bdaa49b9e29123"
|
||||
CROS_WORKON_PROJECT="chromiumos/third_party/tpm-emulator"
|
||||
|
||||
inherit cmake-utils cros-workon toolchain-funcs
|
||||
|
||||
DESCRIPTION="TPM Emulator with small google-local changes"
|
||||
LICENSE="GPL-2"
|
||||
HOMEPAGE="//https://developer.berlios.de/projects/tpm-emulator"
|
||||
SLOT="0"
|
||||
IUSE="doc"
|
||||
KEYWORDS="amd64 arm x86"
|
||||
|
||||
DEPEND="app-crypt/trousers
|
||||
dev-libs/gmp"
|
||||
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
src_configure() {
|
||||
tc-export CC CXX LD AR RANLIB NM
|
||||
CHROMEOS=1 cmake-utils_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
cmake-utils_src_compile
|
||||
# This would be normally done in kernel module build, but we have
|
||||
# copied the kernel module to the kernel tree.
|
||||
TPMD_DEV_SRC_DIR="${S}/tpmd_dev/linux"
|
||||
TPMD_DEV_BUILD_DIR="${CMAKE_BUILD_DIR}/tpmd_dev/linux"
|
||||
mkdir -p "${TPMD_DEV_BUILD_DIR}"
|
||||
sed -e "s/\$TPM_GROUP/tss/g" \
|
||||
< "${TPMD_DEV_SRC_DIR}/tpmd_dev.rules.in" \
|
||||
> "${TPMD_DEV_BUILD_DIR}/tpmd_dev.rules"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
# TODO(semenzato): need these for emerge on host, to run tpm_lite tests.
|
||||
# insinto /usr/lib
|
||||
# doins "${CMAKE_BUILD_DIR}/tpm/libtpm.a"
|
||||
# doins "${CMAKE_BUILD_DIR}/crypto/libcrypto.a"
|
||||
# doins "${CMAKE_BUILD_DIR}/tpmd/unix/libtpmemu.a"
|
||||
# insinto /usr/include
|
||||
# doins "${S}/tpmd/unix/tpmemu.h"
|
||||
exeinto /usr/sbin
|
||||
doexe "${CMAKE_BUILD_DIR}/tpmd/unix/tpmd"
|
||||
insinto /etc/udev/rules.d
|
||||
TPMD_DEV_BUILD_DIR="${CMAKE_BUILD_DIR}/tpmd_dev/linux"
|
||||
RULES_FILE="${TPMD_DEV_BUILD_DIR}/tpmd_dev.rules"
|
||||
newins "${RULES_FILE}" 80-tpmd_dev.rules
|
||||
}
|
@ -1,53 +0,0 @@
|
||||
# Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header$
|
||||
|
||||
EAPI="2"
|
||||
CROS_WORKON_PROJECT="chromiumos/third_party/tpm-emulator"
|
||||
|
||||
inherit cmake-utils cros-workon toolchain-funcs
|
||||
|
||||
DESCRIPTION="TPM Emulator with small google-local changes"
|
||||
LICENSE="GPL-2"
|
||||
HOMEPAGE="//https://developer.berlios.de/projects/tpm-emulator"
|
||||
SLOT="0"
|
||||
IUSE="doc"
|
||||
KEYWORDS="~amd64 ~arm ~x86"
|
||||
|
||||
DEPEND="app-crypt/trousers
|
||||
dev-libs/gmp"
|
||||
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
src_configure() {
|
||||
tc-export CC CXX LD AR RANLIB NM
|
||||
CHROMEOS=1 cmake-utils_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
cmake-utils_src_compile
|
||||
# This would be normally done in kernel module build, but we have
|
||||
# copied the kernel module to the kernel tree.
|
||||
TPMD_DEV_SRC_DIR="${S}/tpmd_dev/linux"
|
||||
TPMD_DEV_BUILD_DIR="${CMAKE_BUILD_DIR}/tpmd_dev/linux"
|
||||
mkdir -p "${TPMD_DEV_BUILD_DIR}"
|
||||
sed -e "s/\$TPM_GROUP/tss/g" \
|
||||
< "${TPMD_DEV_SRC_DIR}/tpmd_dev.rules.in" \
|
||||
> "${TPMD_DEV_BUILD_DIR}/tpmd_dev.rules"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
# TODO(semenzato): need these for emerge on host, to run tpm_lite tests.
|
||||
# insinto /usr/lib
|
||||
# doins "${CMAKE_BUILD_DIR}/tpm/libtpm.a"
|
||||
# doins "${CMAKE_BUILD_DIR}/crypto/libcrypto.a"
|
||||
# doins "${CMAKE_BUILD_DIR}/tpmd/unix/libtpmemu.a"
|
||||
# insinto /usr/include
|
||||
# doins "${S}/tpmd/unix/tpmemu.h"
|
||||
exeinto /usr/sbin
|
||||
doexe "${CMAKE_BUILD_DIR}/tpmd/unix/tpmd"
|
||||
insinto /etc/udev/rules.d
|
||||
TPMD_DEV_BUILD_DIR="${CMAKE_BUILD_DIR}/tpmd_dev/linux"
|
||||
RULES_FILE="${TPMD_DEV_BUILD_DIR}/tpmd_dev.rules"
|
||||
newins "${RULES_FILE}" 80-tpmd_dev.rules
|
||||
}
|
@ -1,39 +0,0 @@
|
||||
# Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=2
|
||||
CROS_WORKON_COMMIT="e3afe51c44ea5b1ebbc6fc6561c46fd0608cde2a"
|
||||
CROS_WORKON_TREE="c6b3d8822b63163c977a8d4e0bc9ef3c9cd7b011"
|
||||
CROS_WORKON_PROJECT="chromiumos/third_party/trousers"
|
||||
|
||||
inherit cros-workon autotest
|
||||
|
||||
DESCRIPTION="Trousers TPM tests"
|
||||
HOMEPAGE="http://www.chromium.org/"
|
||||
SRC_URI=""
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="x86 arm amd64"
|
||||
DEPEND="app-crypt/trousers
|
||||
!<chromeos-base/autotest-tests-0.0.1-r1521"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
# Enable autotest by default.
|
||||
IUSE="${IUSE} +autotest"
|
||||
|
||||
IUSE_TESTS="
|
||||
+tests_hardware_TPM
|
||||
"
|
||||
|
||||
IUSE="${IUSE} ${IUSE_TESTS}"
|
||||
|
||||
CROS_WORKON_LOCALNAME=trousers
|
||||
|
||||
# path from root of repo
|
||||
AUTOTEST_CLIENT_SITE_TESTS=autotest
|
||||
|
||||
function src_compile {
|
||||
# for Makefile
|
||||
export TROUSERS_DIR=${WORKDIR}/${P}
|
||||
autotest_src_compile
|
||||
}
|
@ -1,37 +0,0 @@
|
||||
# Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=2
|
||||
CROS_WORKON_PROJECT="chromiumos/third_party/trousers"
|
||||
|
||||
inherit cros-workon autotest
|
||||
|
||||
DESCRIPTION="Trousers TPM tests"
|
||||
HOMEPAGE="http://www.chromium.org/"
|
||||
SRC_URI=""
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~x86 ~arm ~amd64"
|
||||
DEPEND="app-crypt/trousers
|
||||
!<chromeos-base/autotest-tests-0.0.1-r1521"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
# Enable autotest by default.
|
||||
IUSE="${IUSE} +autotest"
|
||||
|
||||
IUSE_TESTS="
|
||||
+tests_hardware_TPM
|
||||
"
|
||||
|
||||
IUSE="${IUSE} ${IUSE_TESTS}"
|
||||
|
||||
CROS_WORKON_LOCALNAME=trousers
|
||||
|
||||
# path from root of repo
|
||||
AUTOTEST_CLIENT_SITE_TESTS=autotest
|
||||
|
||||
function src_compile {
|
||||
# for Makefile
|
||||
export TROUSERS_DIR=${WORKDIR}/${P}
|
||||
autotest_src_compile
|
||||
}
|
@ -1,68 +0,0 @@
|
||||
# Copyright 1999-2009 Gentoo Foundation
|
||||
# Copyright 2010 Google, Inc.
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header$
|
||||
|
||||
EAPI="2"
|
||||
CROS_WORKON_COMMIT="e3afe51c44ea5b1ebbc6fc6561c46fd0608cde2a"
|
||||
CROS_WORKON_TREE="c6b3d8822b63163c977a8d4e0bc9ef3c9cd7b011"
|
||||
CROS_WORKON_PROJECT="chromiumos/third_party/trousers"
|
||||
|
||||
inherit autotools base cros-workon eutils linux-info
|
||||
|
||||
DESCRIPTION="An open-source TCG Software Stack (TSS) v1.1 implementation"
|
||||
HOMEPAGE="http://trousers.sf.net"
|
||||
LICENSE="CPL-1.0"
|
||||
KEYWORDS="amd64 arm x86"
|
||||
SLOT="0"
|
||||
IUSE="doc tss_trace"
|
||||
|
||||
RDEPEND=">=dev-libs/openssl-0.9.7"
|
||||
|
||||
DEPEND="${RDEPEND}
|
||||
dev-util/pkgconfig"
|
||||
|
||||
## TODO: Check if this patch is useful for us.
|
||||
## PATCHES=( "${FILESDIR}/${PN}-0.2.3-nouseradd.patch" )
|
||||
|
||||
pkg_setup() {
|
||||
# New user/group for the daemon
|
||||
enewgroup tss
|
||||
enewuser tss -1 -1 /var/lib/tpm tss
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
base_src_prepare
|
||||
|
||||
sed -e "s/-Werror //" -i configure.in
|
||||
if use tss_trace ; then
|
||||
# Enable tracing of TSS calls.
|
||||
export CFLAGS="$CFLAGS -DTSS_TRACE"
|
||||
fi
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
tc-export CC CXX AR RANLIB LD NM
|
||||
export CCFLAGS="$CFLAGS"
|
||||
emake
|
||||
}
|
||||
|
||||
src_install() {
|
||||
keepdir /var/lib/tpm
|
||||
emake DESTDIR="${D}" install || die
|
||||
dodoc AUTHORS ChangeLog NICETOHAVES README TODO
|
||||
use doc && dodoc doc/*
|
||||
newinitd "${FILESDIR}/tcsd.initd" tcsd
|
||||
newconfd "${FILESDIR}/tcsd.confd" tcsd
|
||||
|
||||
# Install the empty system.data files
|
||||
dodir /etc/trousers
|
||||
insinto /etc/trousers
|
||||
doins "${S}"/dist/system.data.*
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "If you have problems starting tcsd, please check permissions and"
|
||||
elog "ownership on /dev/tpm* and ~tss/system.data"
|
||||
}
|
@ -1,66 +0,0 @@
|
||||
# Copyright 1999-2009 Gentoo Foundation
|
||||
# Copyright 2010 Google, Inc.
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header$
|
||||
|
||||
EAPI="2"
|
||||
CROS_WORKON_PROJECT="chromiumos/third_party/trousers"
|
||||
|
||||
inherit autotools base cros-workon eutils linux-info
|
||||
|
||||
DESCRIPTION="An open-source TCG Software Stack (TSS) v1.1 implementation"
|
||||
HOMEPAGE="http://trousers.sf.net"
|
||||
LICENSE="CPL-1.0"
|
||||
KEYWORDS="~amd64 ~arm ~x86"
|
||||
SLOT="0"
|
||||
IUSE="doc tss_trace"
|
||||
|
||||
RDEPEND=">=dev-libs/openssl-0.9.7"
|
||||
|
||||
DEPEND="${RDEPEND}
|
||||
dev-util/pkgconfig"
|
||||
|
||||
## TODO: Check if this patch is useful for us.
|
||||
## PATCHES=( "${FILESDIR}/${PN}-0.2.3-nouseradd.patch" )
|
||||
|
||||
pkg_setup() {
|
||||
# New user/group for the daemon
|
||||
enewgroup tss
|
||||
enewuser tss -1 -1 /var/lib/tpm tss
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
base_src_prepare
|
||||
|
||||
sed -e "s/-Werror //" -i configure.in
|
||||
if use tss_trace ; then
|
||||
# Enable tracing of TSS calls.
|
||||
export CFLAGS="$CFLAGS -DTSS_TRACE"
|
||||
fi
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
tc-export CC CXX AR RANLIB LD NM
|
||||
export CCFLAGS="$CFLAGS"
|
||||
emake
|
||||
}
|
||||
|
||||
src_install() {
|
||||
keepdir /var/lib/tpm
|
||||
emake DESTDIR="${D}" install || die
|
||||
dodoc AUTHORS ChangeLog NICETOHAVES README TODO
|
||||
use doc && dodoc doc/*
|
||||
newinitd "${FILESDIR}/tcsd.initd" tcsd
|
||||
newconfd "${FILESDIR}/tcsd.confd" tcsd
|
||||
|
||||
# Install the empty system.data files
|
||||
dodir /etc/trousers
|
||||
insinto /etc/trousers
|
||||
doins "${S}"/dist/system.data.*
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "If you have problems starting tcsd, please check permissions and"
|
||||
elog "ownership on /dev/tpm* and ~tss/system.data"
|
||||
}
|
@ -1 +0,0 @@
|
||||
chromeos-installshim-0.0.1.ebuild
|
@ -1,61 +0,0 @@
|
||||
# Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=4
|
||||
|
||||
DESCRIPTION="Chrome OS Install Shim (meta package)"
|
||||
HOMEPAGE="http://src.chromium.org"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 arm x86"
|
||||
|
||||
X86_DEPEND="
|
||||
sys-boot/syslinux
|
||||
"
|
||||
|
||||
# Factory installer
|
||||
RDEPEND="
|
||||
x86? ( ${X86_DEPEND} )
|
||||
amd64? ( ${X86_DEPEND} )
|
||||
arm? (
|
||||
chromeos-base/u-boot-scripts
|
||||
)
|
||||
app-arch/sharutils
|
||||
app-crypt/trousers
|
||||
app-shells/bash
|
||||
app-shells/dash
|
||||
chromeos-base/board-devices
|
||||
chromeos-base/chromeos-auth-config
|
||||
chromeos-base/chromeos-base
|
||||
chromeos-base/chromeos-factoryinstall
|
||||
chromeos-base/chromeos-init
|
||||
chromeos-base/dev-install
|
||||
chromeos-base/vboot_reference
|
||||
net-firewall/iptables
|
||||
net-misc/tlsdate
|
||||
>=sys-apps/baselayout-2.0.0
|
||||
sys-apps/coreutils
|
||||
sys-apps/dbus
|
||||
sys-apps/flashrom
|
||||
sys-apps/grep
|
||||
sys-apps/mawk
|
||||
sys-apps/module-init-tools
|
||||
sys-apps/mosys
|
||||
sys-apps/net-tools
|
||||
sys-apps/pv
|
||||
sys-apps/rootdev
|
||||
sys-apps/sed
|
||||
sys-apps/shadow
|
||||
sys-apps/upstart
|
||||
sys-apps/util-linux
|
||||
sys-apps/which
|
||||
sys-auth/pam_pwdfile
|
||||
sys-fs/e2fsprogs
|
||||
sys-process/lsof
|
||||
sys-process/procps
|
||||
virtual/chromeos-bsp
|
||||
virtual/udev
|
||||
"
|
||||
|
||||
S=${WORKDIR}
|
@ -1 +0,0 @@
|
||||
vboot_reference-1.0.ebuild
|
@ -0,0 +1 @@
|
||||
vboot_reference-9999.ebuild
|
@ -1,53 +0,0 @@
|
||||
# Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI="4"
|
||||
CROS_WORKON_COMMIT="ca5a891a95a5c300e85fe6899a5297b91f476eb4"
|
||||
CROS_WORKON_PROJECT="coreos/vboot_reference"
|
||||
CROS_WORKON_REPO="git://github.com"
|
||||
CROS_WORKON_LOCALDIR="src/platform"
|
||||
|
||||
inherit cros-debug cros-workon cros-au
|
||||
|
||||
DESCRIPTION="Chrome OS verified boot tools"
|
||||
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 arm x86"
|
||||
IUSE="cros_host"
|
||||
|
||||
RDEPEND="dev-libs/libyaml
|
||||
dev-libs/openssl
|
||||
sys-apps/util-linux"
|
||||
DEPEND="app-crypt/trousers
|
||||
${RDEPEND}"
|
||||
|
||||
src_compile() {
|
||||
mkdir "${S}"/build-main
|
||||
tc-export CC AR CXX PKG_CONFIG
|
||||
cros-debug-add-NDEBUG
|
||||
# Vboot reference knows the flags to use
|
||||
unset CFLAGS
|
||||
emake BUILD="${S}"/build-main \
|
||||
ARCH=$(tc-arch) all
|
||||
unset CC AR CXX PKG_CONFIG
|
||||
}
|
||||
|
||||
src_test() {
|
||||
emake BUILD="${S}"/build-main \
|
||||
ARCH=$(tc-arch) runtests
|
||||
}
|
||||
|
||||
src_install() {
|
||||
einfo "Installing programs"
|
||||
# Installing on the host
|
||||
emake BUILD="${S}"/build-main DESTDIR="${D}/usr/bin" install
|
||||
|
||||
# Install public headers to /build/${BOARD}/usr/include/vboot
|
||||
einfo "Installing header files"
|
||||
insinto /usr/include/vboot
|
||||
doins firmware/include/* host/include/*
|
||||
|
||||
einfo "Installing host library"
|
||||
dolib.a build-main/libvboot_host.a
|
||||
}
|
@ -6,20 +6,25 @@ CROS_WORKON_PROJECT="coreos/vboot_reference"
|
||||
CROS_WORKON_REPO="git://github.com"
|
||||
CROS_WORKON_LOCALDIR="src/platform"
|
||||
|
||||
if [[ "${PV}" == 9999 ]]; then
|
||||
KEYWORDS="~amd64 ~arm ~x86"
|
||||
else
|
||||
CROS_WORKON_COMMIT="f634c54e9e2374243ecc3e93ef18925f4a439251"
|
||||
KEYWORDS="amd64 arm x86"
|
||||
fi
|
||||
|
||||
inherit cros-debug cros-workon cros-au
|
||||
|
||||
DESCRIPTION="Chrome OS verified boot tools"
|
||||
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~arm ~x86"
|
||||
IUSE="cros_host"
|
||||
|
||||
RDEPEND="dev-libs/libyaml
|
||||
dev-libs/openssl
|
||||
sys-apps/util-linux"
|
||||
DEPEND="app-crypt/trousers
|
||||
${RDEPEND}"
|
||||
DEPEND="${RDEPEND}"
|
||||
|
||||
src_compile() {
|
||||
mkdir "${S}"/build-main
|
||||
|
Loading…
x
Reference in New Issue
Block a user