remove golang rebuild as it's no longer a package set

This commit is contained in:
Fredrik Eriksson 2025-03-15 21:24:58 +01:00
parent a6714d037b
commit f3abc1c257
Signed by: feffe
GPG Key ID: 20651C52AADCDB8D

View File

@ -270,50 +270,6 @@ def pkg_upgrade():
# from here on we shouldn't need to rebuild the upgraded packages again # from here on we shouldn't need to rebuild the upgraded packages again
exclude_list = ' --exclude '.join(rebuild_packages.keys()).split() exclude_list = ' --exclude '.join(rebuild_packages.keys()).split()
# Rebuild go
go_packages = []
cmd = None
for package,eclasses in rebuild_packages.items():
if 'go-module' in eclasses or package == 'dev-lang/go':
go_packages.append(package)
if 'dev-lang/go' in go_packages:
log.info("Running golang-rebuild due to update of dev-lang/go")
cmd = [
EMERGE_PATH,
'--color', 'n',
'-q',
'--usepkg', 'n',
'@golang-rebuild',
'--exclude' ] + exclude_list
elif go_packages:
dependencies = []
for package in go_packages:
dependencies.extend(get_dependencies(package))
dependencies = set(dependencies)
upgraded = set(rebuild_packages.keys())
not_upgraded = dependencies-upgraded
if not_upgraded:
log.info(f'Rebuilding packages dependant of go modules {", ".join(go_packages)}')
cmd = [
EMERGE_PATH,
'--color', 'n',
'-q',
'--usepkg', 'n'] + not_upgraded
if cmd:
ret, out, err = sau.helpers.exec_cmd(cmd, timeout=72000)
if ret != 0 or err:
log.error('Rebuild of go packages returned {}'.format(ret))
for line in out.splitlines():
log.error('stdout: {}'.format(line))
for line in err.splitlines():
log.error('stderr: {}'.format(line))
raise sau.errors.UpgradeError(f'Error during go rebuild')
else:
log.info('go rebuild complete')
for line in out.splitlines():
if line.startswith(' * '):
log.warning(line)
# rebuild rust # rebuild rust
if any([x in rebuild_packages for x in ('dev-lang/rust', 'dev-lang/rust-bin')]): if any([x in rebuild_packages for x in ('dev-lang/rust', 'dev-lang/rust-bin')]):
log.info("Running rust-rebuild due to update of rust") log.info("Running rust-rebuild due to update of rust")