aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDoug Freed <dwfreed@mtu.edu>2024-07-30 01:08:02 +0000
committerAndreas K. Hüttel <dilfridge@gentoo.org>2024-07-30 13:06:05 +0200
commit35e6088eda0c2c8197c16382f3ba29a69eea60ec (patch)
treefcaa2f4782846ddf387727f0ce6a3b04fadd31b6 /catalyst
parentstagebase: clean up config_profile_link (diff)
downloadcatalyst-35e6088eda0c2c8197c16382f3ba29a69eea60ec.tar.gz
catalyst-35e6088eda0c2c8197c16382f3ba29a69eea60ec.tar.bz2
catalyst-35e6088eda0c2c8197c16382f3ba29a69eea60ec.zip
stagebase: create profile link for ROOT too
Signed-off-by: Andreas K. Hüttel <dilfridge@gentoo.org>
Diffstat (limited to 'catalyst')
-rw-r--r--catalyst/base/stagebase.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/catalyst/base/stagebase.py b/catalyst/base/stagebase.py
index df2da7ef..ad7cd12e 100644
--- a/catalyst/base/stagebase.py
+++ b/catalyst/base/stagebase.py
@@ -883,6 +883,17 @@ class StageBase(TargetBase, ClearBase, GenBase):
make_profile.symlink_to(os.path.relpath(chroot_profile_path, chroot_port_conf),
target_is_directory=True)
+ if self.settings['root_path'] != '/':
+ log.info('Configuring ROOT profile link...')
+
+ # stage_path is chroot_path + root_path
+ root_port_conf = Path(self.settings['stage_path'] + self.settings['port_conf'])
+ root_make_profile = root_port_conf / 'make.profile'
+ root_make_profile.unlink(missing_ok=True)
+
+ root_make_profile.symlink_to(os.path.relpath(chroot_profile_path, root_port_conf),
+ target_is_directory=True)
+
def setup_confdir(self):
if "autoresume" in self.settings["options"] \
and self.resume.is_enabled("setup_confdir"):