Ian, this one is special just for you. I''m sending it as an attachment because my email client will mangle it. This patch will remove the cmake dependency from xen prior to autoconf stubdom This patch applies ontop of [VTPM v7 3/8] vtpm/vtpmmgr and required libs to stubdom/Makefile You can apply it to your tree by doing the following: git rebase -i <VTPM v7 3/8 revision> Select to EDIT the 3/8 revision patch -p1 < 0004-Remove-vtpm-from-default-build-targets.patch git commit --amend git rebase --continue You will hit conflicts with the autoconf patch, just edit stubdom/Makefile and accept all of the updates from the autoconf patch. Namely changing the TARGETS variable, build rule, and install rule git add stubdom/Makefile git commit git rebase --continue If you''d prefer not to go through these gyrations, I can send an updated full vtpm patchset with the fix merged in. _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
On Thu, 2012-12-13 at 15:22 +0000, Matthew Fioravante wrote:> Ian, this one is special just for you. I''m sending it as an attachment > because my email client will mangle it. > This patch will remove the cmake dependency from xen prior to autoconf > stubdomThanks, I merged this as described and also folded "Disable caml-stubdom by default" into the patch which added it enabled. However this still fails for me when vtpm is not enabled: make[1]: *** No rule to make target `mini-os-x86_64-vtpm'', needed by `vtpm-stubdom''. Stop. make[1]: Leaving directory `/local/scratch/ianc/devel/committer.git/stubdom'' make: *** [install-stubdom] Error 2 Something to with vtpmmgr not being conditional? I''ve pushed my current branch to: git://xenbits.xen.org/people/ianc/xen-unstable.git vtpm2 Please can you fixup and resubmit the whole thing? It would be useful to take all my [ijc -- did foo] comments and either remove them or add something to the main changelog. Ian.
On Tue, 2012-12-18 at 11:31 +0000, Ian Campbell wrote:> On Thu, 2012-12-13 at 15:22 +0000, Matthew Fioravante wrote: > > Ian, this one is special just for you. I''m sending it as an attachment > > because my email client will mangle it. > > This patch will remove the cmake dependency from xen prior to autoconf > > stubdom > > Thanks, I merged this as described and also folded "Disable caml-stubdom > by default" into the patch which added it enabled. > > However this still fails for me when vtpm is not enabled: > make[1]: *** No rule to make target `mini-os-x86_64-vtpm'', needed by `vtpm-stubdom''. Stop. > make[1]: Leaving directory `/local/scratch/ianc/devel/committer.git/stubdom'' > make: *** [install-stubdom] Error 2 > > Something to with vtpmmgr not being conditional?Looks like a simple thinko. I''ll merge the following into "stubdom: Add autoconf", hopefully my testing won''t find any other issues. Please try and remember to test both with and without any new option you are adding in the future. Ian. commit 569b8782415325b27897434f4893945769c45296 Author: Ian Campbell <ian.campbell@citrix.com> Date: Tue Dec 18 11:41:32 2012 +0000 install-vtpmmgr should depend on vtpmmgrdom not vtpm-stubdom diff --git a/stubdom/Makefile b/stubdom/Makefile index 709b71e..7519683 100644 --- a/stubdom/Makefile +++ b/stubdom/Makefile @@ -476,7 +476,7 @@ install-vtpm: vtpm-stubdom $(INSTALL_DIR) "$(DESTDIR)$(XENFIRMWAREDIR)" $(INSTALL_PROG) mini-os-$(XEN_TARGET_ARCH)-vtpm/mini-os.gz "$(DESTDIR)$(XENFIRMWAREDIR)/vtpm-stubdom.gz" -install-vtpmmgr: vtpm-stubdom +install-vtpmmgr: vtpmmgrdom $(INSTALL_DIR) "$(DESTDIR)$(XENFIRMWAREDIR)" $(INSTALL_PROG) mini-os-$(XEN_TARGET_ARCH)-vtpmmgr/mini-os.gz "$(DESTDIR)$(XENFIRMWAREDIR)/vtpmmgrdom.gz"
On Tue, 2012-12-18 at 11:46 +0000, Ian Campbell wrote:> On Tue, 2012-12-18 at 11:31 +0000, Ian Campbell wrote: > > On Thu, 2012-12-13 at 15:22 +0000, Matthew Fioravante wrote: > > > Ian, this one is special just for you. I'm sending it as an attachment > > > because my email client will mangle it. > > > This patch will remove the cmake dependency from xen prior to autoconf > > > stubdom > > > > Thanks, I merged this as described and also folded "Disable caml-stubdom > > by default" into the patch which added it enabled. > > > > However this still fails for me when vtpm is not enabled: > > make[1]: *** No rule to make target `mini-os-x86_64-vtpm', needed by `vtpm-stubdom'. Stop. > > make[1]: Leaving directory `/local/scratch/ianc/devel/committer.git/stubdom' > > make: *** [install-stubdom] Error 2 > > > > Something to with vtpmmgr not being conditional? > > Looks like a simple thinko. I'll merge the following into "stubdom: Add > autoconf", hopefully my testing won't find any other issues.I was just about to push this out when I though "hrm, maybe I should check this with cmake installed". I'm afraid it is broken. Spew is below. Looks like it's not finding the gmp headers -- I can see them in stubdom/gmp-x86_64/gmp.h but I can't see anything which looks like it adds the necessary -I to CFLAGS or anywhere. Branch is at: git://xenbits.xen.org/people/ianc/xen-unstable.git vtpm3 Sorry if I've broken something somewhere along the way. Please can you test fully both with and without cmake and resubmit. For reference the script I run before committing is: #!/bin/bash set -ex export PATH=/usr/lib/ccache:$PATH ( make distclean -j12 -s git clean -f -dx ./configure make dist -j12 -s find dist | sort > ../FILE_LIST ) 2>&1 | tee ../COMMITTER.LOG This makes pretty sure it is doing a fresh build with no left over cruft installed. Ian. cc -mno-red-zone -O1 -fno-omit-frame-pointer -m64 -mno-red-zone -fno-reorder-blocks -fno-asynchronous-unwind-tables -m64 -g -fno-strict-aliasing -std=gnu99 -Wall -Wstrict-prototypes -Wdeclaration-after-statement -fno-stack-protector -fno-exceptions -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include -D__MINIOS__ -DHAVE_LIBC -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include/posix -isystem /local/scratch/ianc/devel/committer.git/stubdom/../tools/xenstore -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include/x86 -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include/x86/x86_64 -U __linux__ -U __FreeBSD__ -U __sun__ -nostdinc -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include/posix -isystem /local/scratch/ianc/devel/committer.git/stubdom/cross-root-x86_64/x86_64-xen-elf/include -isystem /usr/lib/gcc/x86_64-linux-gnu/4.4.5/include -isystem /local/scratch/ianc/devel/committer.git/stubdom/lwip-x86_64/src/include -isystem /local/scratch/ianc/devel/committer.git/stubdom/lwip-x86_64/src/include/ipv4 -I/local/scratch/ianc/devel/committer.git/stubdom/include -I/local/scratch/ianc/devel/committer.git/stubdom/../xen/include -I../tpm_emulator-x86_64/build -I../tpm_emulator-x86_64/tpm -I../tpm_emulator-x86_64/crypto -I../tpm_emulator-x86_64 -c -o vtpm.o vtpm.c In file included from ../tpm_emulator-x86_64/crypto/rsa.h:22, from ../tpm_emulator-x86_64/tpm/tpm_structures.h:22, from ../tpm_emulator-x86_64/tpm/tpm_marshalling.h:21, from vtpm.c:31: ../tpm_emulator-x86_64/crypto/bn.h:27:17: error: gmp.h: No such file or directory In file included from ../tpm_emulator-x86_64/crypto/rsa.h:22, from ../tpm_emulator-x86_64/tpm/tpm_structures.h:22, from ../tpm_emulator-x86_64/tpm/tpm_marshalling.h:21, from vtpm.c:31: ../tpm_emulator-x86_64/crypto/bn.h:28: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘tpm_bn_t’ ../tpm_emulator-x86_64/crypto/bn.h:31: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:33: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:35: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:37: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:39: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:41: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:43: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:45: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:47: error: expected ‘)’ before ‘out’ ../tpm_emulator-x86_64/crypto/bn.h:49: error: expected declaration specifiers or ‘...’ before ‘tpm_bn_t’ ../tpm_emulator-x86_64/crypto/bn.h:51: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:53: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:55: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:57: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:59: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:61: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:63: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:65: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:67: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:69: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:71: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:73: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:75: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:77: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:79: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:81: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:83: error: expected ‘)’ before ‘res’ In file included from ../tpm_emulator-x86_64/tpm/tpm_structures.h:22, from ../tpm_emulator-x86_64/tpm/tpm_marshalling.h:21, from vtpm.c:31: ../tpm_emulator-x86_64/crypto/rsa.h:25: error: expected specifier-qualifier-list before ‘tpm_bn_t’ ../tpm_emulator-x86_64/crypto/rsa.h:35: error: expected specifier-qualifier-list before ‘tpm_bn_t’ In file included from ../tpm_emulator-x86_64/tpm/tpm_marshalling.h:21, from vtpm.c:31: ../tpm_emulator-x86_64/tpm/tpm_structures.h: In function ‘free_TPM_PERMANENT_DATA’: ../tpm_emulator-x86_64/tpm/tpm_structures.h:2244: error: ‘tpm_rsa_private_key_t’ has no member named ‘size’ make[2]: *** [vtpm.o] Error 1 make[2]: Leaving directory `/local/scratch/ianc/devel/committer.git/stubdom/vtpm' make[1]: *** [vtpm] Error 2 make[1]: Leaving directory `/local/scratch/ianc/devel/committer.git/stubdom' make: *** [install-stubdom] Error 2 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
Fioravante, Matthew E.
2012-Dec-18 15:23 UTC
Re: [PATCH special] vtpm fix cmake dependency
What os are you using? I've noticed problems with gmp on Ubuntu. -----Original Message----- From: Ian Campbell [mailto:Ian.Campbell@citrix.com] Sent: Tuesday, December 18, 2012 9:13 AM To: Fioravante, Matthew E. Cc: xen-devel@lists.xen.org Subject: Re: [Xen-devel] [PATCH special] vtpm fix cmake dependency On Tue, 2012-12-18 at 11:46 +0000, Ian Campbell wrote:> On Tue, 2012-12-18 at 11:31 +0000, Ian Campbell wrote: > > On Thu, 2012-12-13 at 15:22 +0000, Matthew Fioravante wrote: > > > Ian, this one is special just for you. I'm sending it as an > > > attachment because my email client will mangle it. > > > This patch will remove the cmake dependency from xen prior to > > > autoconf stubdom > > > > Thanks, I merged this as described and also folded "Disable > > caml-stubdom by default" into the patch which added it enabled. > > > > However this still fails for me when vtpm is not enabled: > > make[1]: *** No rule to make target `mini-os-x86_64-vtpm', needed by `vtpm-stubdom'. Stop. > > make[1]: Leaving directory `/local/scratch/ianc/devel/committer.git/stubdom' > > make: *** [install-stubdom] Error 2 > > > > Something to with vtpmmgr not being conditional? > > Looks like a simple thinko. I'll merge the following into "stubdom: > Add autoconf", hopefully my testing won't find any other issues.I was just about to push this out when I though "hrm, maybe I should check this with cmake installed". I'm afraid it is broken. Spew is below. Looks like it's not finding the gmp headers -- I can see them in stubdom/gmp-x86_64/gmp.h but I can't see anything which looks like it adds the necessary -I to CFLAGS or anywhere. Branch is at: git://xenbits.xen.org/people/ianc/xen-unstable.git vtpm3 Sorry if I've broken something somewhere along the way. Please can you test fully both with and without cmake and resubmit. For reference the script I run before committing is: #!/bin/bash set -ex export PATH=/usr/lib/ccache:$PATH ( make distclean -j12 -s git clean -f -dx ./configure make dist -j12 -s find dist | sort > ../FILE_LIST ) 2>&1 | tee ../COMMITTER.LOG This makes pretty sure it is doing a fresh build with no left over cruft installed. Ian. cc -mno-red-zone -O1 -fno-omit-frame-pointer -m64 -mno-red-zone -fno-reorder-blocks -fno-asynchronous-unwind-tables -m64 -g -fno-strict-aliasing -std=gnu99 -Wall -Wstrict-prototypes -Wdeclaration-after-statement -fno-stack-protector -fno-exceptions -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include -D__MINIOS__ -DHAVE_LIBC -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include/posix -isystem /local/scratch/ianc/devel/committer.git/stubdom/../tools/xenstore -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include/x86 -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include/x86/x86_64 -U __linux__ -U __FreeBSD__ -U __sun__ -nostdinc -isystem /local/scratch/ianc/devel/committer.git/stubdom/../extras/mini-os/include/posix -isystem /local/scratch/ianc/devel/committer.git/stubdom/cross-root-x86_64/x86_64-xen-elf/include -isystem /usr/lib/gcc/x86_64-linux-gnu/4.4.5/include -isystem /local/scratch/ianc/devel/committer.git/stubdom/lwip-x86_64/src/include -isystem /local/scratch/ianc/devel/committer.git/stubdom/lwip-x86_64/src/include/ipv4 -I/local/scratch/ianc/devel/committer.git/stubdom/include -I/local/scratch/ianc/devel/committer.git/stubdom/../xen/include -I../tpm_emulator-x86_64/build -I../tpm_emulator-x86_64/tpm -I../tpm_emulator-x86_64/crypto -I../tpm_emulator-x86_64 -c -o vtpm.o vtpm.c In file included from ../tpm_emulator-x86_64/crypto/rsa.h:22, from ../tpm_emulator-x86_64/tpm/tpm_structures.h:22, from ../tpm_emulator-x86_64/tpm/tpm_marshalling.h:21, from vtpm.c:31: ../tpm_emulator-x86_64/crypto/bn.h:27:17: error: gmp.h: No such file or directory In file included from ../tpm_emulator-x86_64/crypto/rsa.h:22, from ../tpm_emulator-x86_64/tpm/tpm_structures.h:22, from ../tpm_emulator-x86_64/tpm/tpm_marshalling.h:21, from vtpm.c:31: ../tpm_emulator-x86_64/crypto/bn.h:28: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘tpm_bn_t’ ../tpm_emulator-x86_64/crypto/bn.h:31: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:33: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:35: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:37: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:39: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:41: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:43: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:45: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:47: error: expected ‘)’ before ‘out’ ../tpm_emulator-x86_64/crypto/bn.h:49: error: expected declaration specifiers or ‘...’ before ‘tpm_bn_t’ ../tpm_emulator-x86_64/crypto/bn.h:51: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:53: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:55: error: expected ‘)’ before ‘a’ ../tpm_emulator-x86_64/crypto/bn.h:57: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:59: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:61: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:63: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:65: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:67: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:69: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:71: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:73: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:75: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:77: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:79: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:81: error: expected ‘)’ before ‘res’ ../tpm_emulator-x86_64/crypto/bn.h:83: error: expected ‘)’ before ‘res’ In file included from ../tpm_emulator-x86_64/tpm/tpm_structures.h:22, from ../tpm_emulator-x86_64/tpm/tpm_marshalling.h:21, from vtpm.c:31: ../tpm_emulator-x86_64/crypto/rsa.h:25: error: expected specifier-qualifier-list before ‘tpm_bn_t’ ../tpm_emulator-x86_64/crypto/rsa.h:35: error: expected specifier-qualifier-list before ‘tpm_bn_t’ In file included from ../tpm_emulator-x86_64/tpm/tpm_marshalling.h:21, from vtpm.c:31: ../tpm_emulator-x86_64/tpm/tpm_structures.h: In function ‘free_TPM_PERMANENT_DATA’: ../tpm_emulator-x86_64/tpm/tpm_structures.h:2244: error: ‘tpm_rsa_private_key_t’ has no member named ‘size’ make[2]: *** [vtpm.o] Error 1 make[2]: Leaving directory `/local/scratch/ianc/devel/committer.git/stubdom/vtpm' make[1]: *** [vtpm] Error 2 make[1]: Leaving directory `/local/scratch/ianc/devel/committer.git/stubdom' make: *** [install-stubdom] Error 2 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
Top posting! On Tue, 2012-12-18 at 15:23 +0000, Fioravante, Matthew E. wrote:> What os are you using? I''ve noticed problems with gmp on Ubuntu.Debian. But the stub domain should be using its own built copy of gmp, the host''s installed version should be irrelevant. If something is building against /usr/include/gmp.h then that is wrong. Ian.