Page MenuHomeFreeBSD

Add sysutils/uefi-edk2-bhyve-devel based on branch bhyve/edk2-stable201903
ClosedPublic

Authored by araujo on Apr 10 2019, 4:42 PM.

Details

Summary

This port is based on a new uefi-edk2 branch bhyve/edk2-stable201903 made by D Scott Phillips.
The main purpose of this -devel port is to allow us to broadly test the new bhyve uefi firmware till the original one can be replaced.

Diff Detail

Repository
rP FreeBSD ports repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

araujo created this revision.Apr 10 2019, 4:42 PM
araujo edited the summary of this revision. (Show Details)Apr 10 2019, 4:48 PM
araujo added a reviewer: bcran.

Hi @bcran,

I did only smoke tests!! Do you mind do additional tests with different guests?

Best,

bcran added inline comments.Apr 10 2019, 5:54 PM
sysutils/uefi-edk2-bhyve-devel/Makefile
5 ↗(On Diff #56058)

We should probably use the gYYYYMMDD format here instead of a version, as described in Example 5.13. of https://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/makefile-distfiles.html .

44 ↗(On Diff #56058)

Might want to add a tab here to line it up with the other lines.

50 ↗(On Diff #56058)

Could we use GH_SUBDIR to specify where the openssl checkout goes instead?

52 ↗(On Diff #56058)

Might make sense to add another ${LN} line below to symlink python instead of modifying the files here.

58 ↗(On Diff #56058)

Maybe change "FreeBSD-amd64" to "FreeBSD-${MACHINE}" ?

59 ↗(On Diff #56058)

Probably want to change all the 8 to ${GCC_DEFAULT} so it works with newer versions too (we specify GCC 8+ above).

78 ↗(On Diff #56058)

Could you copy OVMF_CODE.fd and also OVMF_VARS.fd here, please?

82 ↗(On Diff #56058)

I don't think we're supposed to have any lines after .include <bsd.port.mk>, though when I tested it the RUN_DEPENDS line removed, the CSM build failed.

bcran added a comment.Apr 10 2019, 5:56 PM

I did only smoke tests!! Do you mind do additional tests with different guests?

I already did - I reported the results to the freebsd-virtualization mailing list. Everything worked fine except for the CSM build, which is currently crashing when trying to call into the legacy BIOS.

Aside from Makefile formatting questions, this looks fine to me and makes a working UEFI binary for me.

sysutils/uefi-edk2-bhyve-devel/Makefile
82 ↗(On Diff #56058)

We definitely don't want gcc listed as a runtime dependency for this firmware package. Looking at bsd.gcc.mk, I don't see a built in way to opt out of the dependency.

araujo updated this revision to Diff 56195.Apr 14 2019, 11:21 AM

Address @bcran suggestions!

araujo marked 7 inline comments as done.Apr 14 2019, 11:24 AM
araujo added inline comments.
sysutils/uefi-edk2-bhyve-devel/Makefile
5 ↗(On Diff #56058)

Done!

44 ↗(On Diff #56058)

Done!

50 ↗(On Diff #56058)

We need to delete the content of OpensslLib prior to copy the new Openssl, not sure if GH_SUBDIR is applicable here.

52 ↗(On Diff #56058)

I have remove that, seems python is in the right path.

58 ↗(On Diff #56058)

Done!

59 ↗(On Diff #56058)

Done!

78 ↗(On Diff #56058)

Sorry, I have forgot about it. Done!

araujo marked 7 inline comments as done.Apr 14 2019, 11:34 AM
araujo updated this revision to Diff 56196.
  • Update ONLY_FOR_ARCHS that was replaced wrong.
araujo updated this revision to Diff 56197.Apr 14 2019, 11:36 AM
  • Also remove SHEBANGFIX not needed.
bcran accepted this revision.Apr 14 2019, 7:39 PM
This revision is now accepted and ready to land.Apr 14 2019, 7:39 PM
bcran added inline comments.Apr 14 2019, 7:40 PM
sysutils/uefi-edk2-bhyve-devel/Makefile
4 ↗(On Diff #56197)

The prefix of 'v' looks a bit strange without a version number now, so might want to consider removing it.

scottph added inline comments.Apr 15 2019, 7:51 PM
sysutils/uefi-edk2-bhyve-devel/Makefile
20 ↗(On Diff #56197)

extra backslash here

52 ↗(On Diff #56058)

building the port now fails for me with /bin/sh: python: not found

Fixing it this way seems reasonable: http://ix.io/1Gj3

mat added inline comments.Apr 18 2019, 1:48 PM
sysutils/uefi-edk2-bhyve-devel/Makefile
28–29 ↗(On Diff #56197)

Remove ${PREFIX}/.

41 ↗(On Diff #56197)

Wrong place in the Makefile. Should happen before options. See Chapter 15. Order of Variables in Port Makefiles.

47 ↗(On Diff #56197)

Remove, not needed.

sysutils/uefi-edk2-bhyve-devel/pkg-descr
1 ↗(On Diff #56197)

pkg-descr should be at least a couple of lines long.

This revision was automatically updated to reflect the committed changes.