Commit Graph

12 Commits

Author SHA1 Message Date
Sam James 9e0ff1f5b3 Fix various minor issues with Gentoo; make CI pass
This patch contains the known set of changes needed to make a gentoo
image build successfully.

- Standardize use of GENTOO_EMERGE_DEFAULT_OPTS, reduce duplication of
  options set there.
- Correct the cleanup commands to reflect standard Gentoo good
  practices by omitting --complete-graph, which is unneeded with --deep,
  and using --changed-use instead of --newuse to reduce unneeded package
  churn.
- Stop using deprecated layman command to manage reposiotry overlays,
  instead use new supported eselect-repository
- Set new USE flags required for LVM and installkernel. This was
  communicated via a Gentoo news item and is a required cleanup.
- Remove now-invalid skip of gpg if using musl

This is the set of changes needed to get the CI job passing and make DIB
build images at all, and we'd like to land them, but there are still
items we'd like to complete to enhance Gentoo support in DIB:
- Optional, built-in support for Gentoo binhosts -- where you can set a
  DIB_GENTOO_BINHOST=true (or similar) and have the binhost enabled by
  default.
- Make the default configuration of EMERGE_DEFAULT_OPTS more easily
  managed in a DIB-style manner, e.g. setting --quiet vs --verbose based
  on the value of DIB_DEBUG_TRACE.

Signed-Off-By: Jay Faulkner <jay@jvf.cc>
Signed-Off-By: Sam James <sam@gentoo.org>
Co-Authored-By: Sam James <sam@gentoo.org>
Change-Id: Idab82a9fa986fcc56fe4e1e1bf0445c7306b2858
2024-02-05 22:11:46 +00:00
Matthew Thode 4d5ba1497c
simplify updating python versions in gentoo
portage now generates /etc/python-exec/python-exec.conf based on the
order of PYTHON_TARGETS in /etc/portage/make.conf

fixes an issue where ARCH was being detected as amd64 not x86_64
fixes kernel installs (virtual/dist-kernel)

standardizes simple if statements (note, the 'shorthand' method will
pass the exit code back to shell but the 'longhand' does not).

Change-Id: I74041c232bc6ab4d6e67a4ecfaa759aa4a5feb6c
Signed-off-by: Matthew Thode <mthode@mthode.org>
2021-01-27 11:34:09 -06:00
Matthew Thode bea81bd234
update gentoo to allow building arm64 images
Adds:

1. grub-efi package mappings
2. efi-64 support
3. default (openrc) arm64 profile
4. systemd arm64 profile

Cleans up the keywords and use flags in 02-gentoo-02-flags.  Most stuff
was stablized.  Also cleaned up some formatting for the if statements.

Enables less trusted overlays (up to the end user to verify).

in 10-gentoo-image I cleaned up some bash lint things as well.
using && instead of -a and avoiding $?

Change-Id: I3dffe1aab4bbdc4946a9bf2269bf0cde49529a4e
2020-08-17 23:50:39 -05:00
Matthew Thode 64787d8ec2
add musl profile to gentoo
Change-Id: Id954ffe4d9b019c7e7bb648725ff7f976c929b4d
2020-06-22 18:37:30 -05:00
Matthew Thode 041bdd331a
use stage3 instead of stage4 for gentoo builds
The main reason for using the stage4 is now gone (kernel compile).
Install and use the distro provided binary kernel package.

In addition to this, set the locale and timezone, beyond that very
little was done in the gentoo stage4.

Change-Id: I541b7d9b807e2357398ae1c249b1978958dd1137
Signed-off-by: Matthew Thode <mthode@mthode.org>
2020-05-27 18:50:16 -05:00
Zuul 3d995645e6 Merge "update version of open-iscsi that is installed on musl" 2019-07-30 02:37:18 +00:00
Matthew Thode f1d7e902e3
support alternate portage directories
The 17.1 profile changed the defaults used in portage for where we store
our repo, distfiles and binpkgs.  Some portage related variables need to
be set deterministically.  17.1 is no enabled for Systemd's profile.

Change-Id: Ib55f6875c5cb461c3c530b51d7420ce3dc8da360
2019-07-26 19:30:01 -05:00
Matthew Thode ed95b4eba1
update version of open-iscsi that is installed on musl
Newer versions of open-iscsi seem to compile on Gentoo / musl.  Use them
if we can.  This also removes the cap on open-iscsi.

Change-Id: I596cb61494e459a419bce6a63deff89f9e78fe23
2019-07-22 14:30:32 -05:00
Matthew Thode 3ad8235180 simplify overlay logic for Gentoo
openssl/cryptography versions are updated/stable
musl profiles need newer versions of open-iscsi masked as upstream
doesn't want to work with multiple libcs

Change-Id: If5baf339516390ae332015928557c6bb734486c2
2018-10-18 00:21:31 +00:00
Matthew Thode 89f95a5351
enable caching for gentoo builds
To facilitate this I've created two new environment variables to set
the environment and default options for package actions.

eval is needed for the export as it preserves quotes.

Change-Id: Ib03651ee8dacd48cd1c135afd57cd31101356056
Signed-off-by: Matthew Thode <mthode@mthode.org>
2018-10-15 23:17:37 -05:00
Matthew Thode b9f1c7a22f
better handle existing keywords files/directories
The existing directories are needed for stage building (a part of the
Gentoo build process).  Normally these directories are empty, but there
are times where overrides need to be defined.  This commit handles
existing overrides for keywords.  For historical reasons the overrides
were able to be put in different files and directories, this
centralizes them.

This also updates the version of openssl/cryptography that works with
or without bindist.

Change-Id: I62c934ed305a711a4a9a3ef01fa55ad142aebb78
2018-06-25 09:20:52 -05:00
Matthew Thode c4f83f2311 Enable support for Gentoo overlays
This is intended to eventually support building musl-libc based images,
which need the musl overlay.

Change-Id: I8f5429ffa64e74c860772d9a00ff0b7eebb7721a
2017-11-30 05:14:00 +00:00