|
|
self.valid_values.extend(["version_stamp","target","subarch",\ | self.valid_values.extend(["version_stamp","target","subarch",\ |
"rel_type","profile","snapshot","source_subpath","portage_confdir",\ | "rel_type","profile","snapshot","source_subpath","portage_confdir",\ |
"cflags","cxxflags","ldflags","cbuild","chost","hostuse","portage_overlay",\ | "cflags","cxxflags","ldflags","cbuild","chost","hostuse","portage_overlay",\ |
"distcc_hosts","makeopts","pkgcache_path","kerncache_path"]) |
"distcc_hosts","makeopts","pkgcache_path","kerncache_path","extra_mounts"]) |
| |
self.set_valid_build_kernel_vars(addlargs) | self.set_valid_build_kernel_vars(addlargs) |
generic_target.__init__(self,myspec,addlargs) | generic_target.__init__(self,myspec,addlargs) |
|
|
self.mounts.append("/tmp/kerncache") | self.mounts.append("/tmp/kerncache") |
self.mountmap["/tmp/kerncache"]=self.settings["kerncache_path"] | self.mountmap["/tmp/kerncache"]=self.settings["kerncache_path"] |
| |
|
if self.settings.has_key("extra_mounts"): |
|
for extra_mount in self.settings["extra_mounts"].split(): |
|
if ':' in extra_mount: |
|
extra_mount_source, extra_mount_target = extra_mount.split(':', 1) |
|
else: |
|
extra_mount_source = extra_mount_target = extra_mount |
|
self.mounts.append(extra_mount_target) |
|
self.mountmap[extra_mount_target] = extra_mount_source |
|
|
if self.settings.has_key("CCACHE"): | if self.settings.has_key("CCACHE"): |
if os.environ.has_key("CCACHE_DIR"): | if os.environ.has_key("CCACHE_DIR"): |
ccdir=os.environ["CCACHE_DIR"] | ccdir=os.environ["CCACHE_DIR"] |
|
|
print "Configuring profile link..." | print "Configuring profile link..." |
cmd("rm -f "+self.settings["chroot_path"]+"/etc/make.profile",\ | cmd("rm -f "+self.settings["chroot_path"]+"/etc/make.profile",\ |
"Error zapping profile link",env=self.env) | "Error zapping profile link",env=self.env) |
cmd("ln -sf ../usr/portage/profiles/"+self.settings["target_profile"]+\ |
if self.settings['target_profile'][0] == '/': |
" "+self.settings["chroot_path"]+"/etc/make.profile","Error creating profile link",env=self.env) |
symlink_target = self.settings["target_profile"] |
|
else: |
|
symlink_target = "../usr/portage/profiles/"+self.settings["target_profile"] |
|
cmd("ln -sf " + symlink_target + " " + \ |
|
self.settings["chroot_path"]+"/etc/make.profile","Error creating profile link",env=self.env) |
touch(self.settings["autoresume_path"]+"config_profile_link") | touch(self.settings["autoresume_path"]+"config_profile_link") |
| |
def setup_confdir(self): | def setup_confdir(self): |