mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Michael Grzeschik <m.grzeschik@pengutronix.de>
To: ptxdist@pengutronix.de
Cc: Marc Kleine-Budde <mkl@pengutronix.de>
Subject: [ptxdist] [PATCH 4/5] tpm2-abrmd: added
Date: Mon, 16 Oct 2017 13:02:26 +0200	[thread overview]
Message-ID: <20171016110227.20681-5-m.grzeschik@pengutronix.de> (raw)
In-Reply-To: <20171016110227.20681-1-m.grzeschik@pengutronix.de>

From: Marc Kleine-Budde <mkl@pengutronix.de>

---
 patches/tpm2-abrmd-1.1.1-51-g1f83a5f/autogen.sh    |  1 +
 projectroot/etc/group                              |  1 +
 projectroot/etc/passwd                             |  1 +
 .../system-services/com.intel.tss2.Tabrmd.service  |  5 ++
 rules/tpm2-abrmd.in                                | 17 +++++
 rules/tpm2-abrmd.make                              | 72 ++++++++++++++++++++++
 6 files changed, 97 insertions(+)
 create mode 100755 patches/tpm2-abrmd-1.1.1-51-g1f83a5f/autogen.sh
 create mode 100644 projectroot/usr/share/dbus-1/system-services/com.intel.tss2.Tabrmd.service
 create mode 100644 rules/tpm2-abrmd.in
 create mode 100644 rules/tpm2-abrmd.make

diff --git a/patches/tpm2-abrmd-1.1.1-51-g1f83a5f/autogen.sh b/patches/tpm2-abrmd-1.1.1-51-g1f83a5f/autogen.sh
new file mode 100755
index 000000000..e62625c77
--- /dev/null
+++ b/patches/tpm2-abrmd-1.1.1-51-g1f83a5f/autogen.sh
@@ -0,0 +1 @@
+./bootstrap
diff --git a/projectroot/etc/group b/projectroot/etc/group
index 452be04a2..ad1aee5f4 100644
--- a/projectroot/etc/group
+++ b/projectroot/etc/group
@@ -20,6 +20,7 @@ lock:x:114:
 audio:x:115:
 input:x:116:
 mysql:x:117:
+tss:x:118:
 systemd-journal:x:201:
 systemd-network:x:202:
 systemd-journal-gateway:x:206:
diff --git a/projectroot/etc/passwd b/projectroot/etc/passwd
index 65653c044..dc6a7e2cd 100644
--- a/projectroot/etc/passwd
+++ b/projectroot/etc/passwd
@@ -4,6 +4,7 @@ ftp:x:11:101:ftp user:/home:/bin/false
 www:x:12:102:www user:/home:/bin/false
 sshd:x:100:65534:SSH Server:/var/run/sshd:/bin/false
 mysql:x:101:117:mySQL Server:/var/run/mysql:/bin/false
+tss:x:102:118:TSS Daemon User:/dev/null:/bin/false
 messagebus:x:103:104:messagebus:/dev/null:/bin/false
 systemd-network:x:202:202:systemd-network:/dev/null:/bin/false
 systemd-resolve:x:203:65534:systemd-resolve:/dev/null:/bin/false
diff --git a/projectroot/usr/share/dbus-1/system-services/com.intel.tss2.Tabrmd.service b/projectroot/usr/share/dbus-1/system-services/com.intel.tss2.Tabrmd.service
new file mode 100644
index 000000000..f5749a49f
--- /dev/null
+++ b/projectroot/usr/share/dbus-1/system-services/com.intel.tss2.Tabrmd.service
@@ -0,0 +1,5 @@
+[D-BUS Service]
+Name=com.intel.tss2.Tabrmd
+Exec=/usr/sbin/tpm2-abrmd
+User=tss
+SystemdService=tpm2-abrmd.service
diff --git a/rules/tpm2-abrmd.in b/rules/tpm2-abrmd.in
new file mode 100644
index 000000000..de76f60a6
--- /dev/null
+++ b/rules/tpm2-abrmd.in
@@ -0,0 +1,17 @@
+## SECTION=tpm
+
+config TPM2_ABRMD
+	tristate
+	select HOST_AUTOTOOLS_AUTOCONF_ARCHIVE
+	select DBUS
+	select GLIB
+	select TPM2_TSS
+	prompt "tpm2-abrmd"
+	help
+	  TPM2 Access Broker & Resource Management Daemon implementing
+	  the TCG spec.
+
+	  This is a system daemon implementing the TPM2 access broker
+	  (TAB) & Resource Manager (RM) spec from the TCG. The daemon
+	  (tpm2-abrmd) is implemented using Glib and the GObject
+	  system.
diff --git a/rules/tpm2-abrmd.make b/rules/tpm2-abrmd.make
new file mode 100644
index 000000000..8d982106a
--- /dev/null
+++ b/rules/tpm2-abrmd.make
@@ -0,0 +1,72 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2017 by Marc Kleine-Budde <mkl@pengutronix.de>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_TPM2_ABRMD) += tpm2-abrmd
+
+#
+# Paths and names
+#
+TPM2_ABRMD_VERSION	:= 1.1.1-51-g1f83a5f
+TPM2_ABRMD_MD5		:= 78fed24c27f35b407a2bc67b153f7521
+TPM2_ABRMD		:= tpm2-abrmd-$(TPM2_ABRMD_VERSION)
+TPM2_ABRMD_SUFFIX	:= tar.gz
+TPM2_ABRMD_URL		:= https://github.com/01org/tpm2-abrmd.git;tag=$(TPM2_ABRMD_VERSION)
+TPM2_ABRMD_SOURCE	:= $(SRCDIR)/$(TPM2_ABRMD).$(TPM2_ABRMD_SUFFIX)
+TPM2_ABRMD_DIR		:= $(BUILDDIR)/$(TPM2_ABRMD)
+TPM2_ABRMD_LICENSE	:= BSD-2-Clause
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+#
+# autoconf
+#
+TPM2_ABRMD_CONF_TOOL	:= autoconf
+TPM2_ABRMD_CONF_OPT	:= \
+	$(CROSS_AUTOCONF_USR) \
+	--with-dbuspolicydir=/usr/share/dbus-1/system.d \
+	--with-systemdsystemunitdir=/lib/systemd/system \
+	--with-udevrulesdir=/lib/udev/rules.d
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/tpm2-abrmd.targetinstall:
+	@$(call targetinfo)
+
+	@$(call install_init, tpm2-abrmd)
+	@$(call install_fixup, tpm2-abrmd,PRIORITY,optional)
+	@$(call install_fixup, tpm2-abrmd,SECTION,base)
+	@$(call install_fixup, tpm2-abrmd,AUTHOR,"Marc Kleine-Budde <mkl@pengutronix.de>")
+	@$(call install_fixup, tpm2-abrmd,DESCRIPTION,missing)
+
+	@$(call install_lib, tpm2-abrmd, 0, 0, 0644, libtcti-tabrmd)
+	@$(call install_copy, tpm2-abrmd, 0, 0, 0755, -, /usr/sbin/tpm2-abrmd)
+
+	@$(call install_copy, tpm2-abrmd, 0, 0, 0644, -, \
+		/usr/share/dbus-1/system.d/tpm2-abrmd.conf)
+	@$(call install_copy, tpm2-abrmd, 0, 0, 0644, -, \
+		/lib/systemd/system/tpm2-abrmd.service)
+	@$(call install_copy, tpm2-abrmd, 0, 0, 0644, -, \
+		/lib/udev/rules.d/tpm-udev.rules)
+
+	@$(call install_alternative, tpm2-abrmd, 0, 0, 0644, \
+		/usr/share/dbus-1/system-services/com.intel.tss2.Tabrmd.service)
+
+	@$(call install_finish, tpm2-abrmd)
+
+	@$(call touch)
+
+# vim: syntax=make
-- 
2.11.0


_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

  parent reply	other threads:[~2017-10-16 11:02 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-16 11:02 [ptxdist] [PATCH 0/5] tpm2: added tools and daemon Michael Grzeschik
2017-10-16 11:02 ` [ptxdist] [PATCH 1/5] host-autotools-autoconf-archive: added Michael Grzeschik
2017-10-16 11:02 ` [ptxdist] [PATCH 2/5] tpm: add menu Michael Grzeschik
2017-10-16 11:02 ` [ptxdist] [PATCH 3/5] tpm2-tss: added Michael Grzeschik
2017-10-16 12:46   ` Roland Hieber
2017-10-16 12:51     ` Michael Grzeschik
2017-10-16 13:28       ` Michael Olbrich
2017-10-19  7:34         ` Marc Kleine-Budde
2017-10-19 15:31           ` Michael Olbrich
2017-10-16 11:02 ` Michael Grzeschik [this message]
2017-10-16 11:02 ` [ptxdist] [PATCH 5/5] tpm2-tools: added Michael Grzeschik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171016110227.20681-5-m.grzeschik@pengutronix.de \
    --to=m.grzeschik@pengutronix.de \
    --cc=mkl@pengutronix.de \
    --cc=ptxdist@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox