Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 467142 - cross building with <tuple>-emerge fails becuase ${PORTDIR}/embedded doesn't have parent
Summary: cross building with <tuple>-emerge fails becuase ${PORTDIR}/embedded doesn't ...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Embedded Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-04-25 01:35 UTC by Anthony Basile
Modified: 2019-10-30 22:42 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Anthony Basile gentoo-dev 2013-04-25 01:35:43 UTC
hen cross building with mips64el-gentoo-linux-uclibc-emerge, or any <tuple>-emerge, one hits the following problem:

mips64el-gentoo-linux-uclibc-emerge -eq system
DEBUG /usr/mips64el-gentoo-linux-uclibc/etc/make.profile /usr/mips64el-gentoo-linux-uclibc/etc/make.profile/parent /usr/portage/profiles
DEBUG False False True


!!! /usr/mips64el-gentoo-linux-uclibc/etc/make.profile is not a symlink and will probably prevent most merges.
DEBUG /etc/portage/make.profile /etc/portage/make.profile/parent /usr/portage/profiles
DEBUG False True True

 * IMPORTANT: 1 news items need reading for repository 'gentoo'.
 * Use eselect news to read news items.

 * ARCH is not set... Are you missing the '/usr/mips64el-gentoo-linux-
 * uclibc/etc/portage/make.profile' symlink? Is the symlink correct? Is
 * your portage tree complete?

Note, I've added two debug lines to /usr/lib/portage/pym/portage/package/ebuild/config.py in the following context around line 1014:

print("DEBUG %s %s %s" % (self.profile_path, os.path.join(self.profile_path, "parent"), os.path.join(self["PORTDIR"], "profiles") ))
print("DEBUG %s %s %s" % (not self.profile_path, exists_raise_eaccess(os.path.join(self.profile_path, "parent")), exists_raise_eaccess(os.path.join(self["PORTDIR"], "profiles"))))

profile_broken = not self.profile_path or \
	not exists_raise_eaccess(os.path.join(self.profile_path, "parent")) and \
	exists_raise_eaccess(os.path.join(self["PORTDIR"], "profiles"))

if profile_broken:
	abs_profile_path = None
	for x in (PROFILE_PATH, 'etc/make.profile'):
		...

The reason for the failure is that profile_broken is true if there is no parent file in the profile directory and embedded does not have one.
Comment 1 Anthony Basile gentoo-dev 2013-04-25 01:39:04 UTC
To be complete, the symlink exists:

# ls -alh /usr/mips64el-gentoo-linux-uclibc/etc/make.profile
lrwxrwxrwx 1 root root 30 Apr 24 21:28 /usr/mips64el-gentoo-linux-uclibc/etc/make.profile -> /usr/portage/profiles/embedded
Comment 2 Zac Medico gentoo-dev 2013-04-25 01:49:09 UTC
If necessary, I guess we could change that 'parent' sanity check to also check for some other distinguishing files, such as the 'packages' file.
Comment 3 Zac Medico gentoo-dev 2013-04-25 01:53:57 UTC
You might want to consider creating arch-specific embedded profiles though. It looks like it would probably be safe to have them inherit from the existing arch/$ARCH mixins.
Comment 4 Zac Medico gentoo-dev 2013-04-25 01:57:51 UTC
Well, looks like arch/mips is a little different from the others, since it inherits from the big global base profile. The other ones don't.
Comment 5 Zac Medico gentoo-dev 2013-05-03 01:54:58 UTC
(In reply to comment #0)
> !!! /usr/mips64el-gentoo-linux-uclibc/etc/make.profile is not a symlink and
> will probably prevent most merges.

The above warning is silenced by this commit:

http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=18aa5cc076a5597ba7e256f316835606bb5b6df9

>  * ARCH is not set... Are you missing the '/usr/mips64el-gentoo-linux-
>  * uclibc/etc/portage/make.profile' symlink? Is the symlink correct? Is
>  * your portage tree complete?

You can avoid the ARCH warning by creating arch-specific embedded profiles as suggested in comment #3.
Comment 6 Anthony Basile gentoo-dev 2013-08-20 20:33:19 UTC
Zac, just cleaning up older bugs here.  This is fixed, isnt' it?
Comment 7 Zac Medico gentoo-dev 2013-08-20 20:50:58 UTC
I still don't see any arch-specific embedded profiles.
Comment 8 Anthony Basile gentoo-dev 2013-08-20 21:02:56 UTC
(In reply to Zac Medico from comment #7)
> I still don't see any arch-specific embedded profiles.

Okay so there's a second part here.  I thought the commit fixed everything.

Adding arch specific embedded profiles would require changes to crossdev too that sets up the sym link.  Let me look into that.
Comment 9 Sergei Trofimovich (RETIRED) gentoo-dev 2019-10-30 22:42:40 UTC
https://gitweb.gentoo.org/proj/crossdev.git/commit/?id=393e1cd0c6d3ac81fa166bafe6065d42849f622c generates local profiles for all targets. Should be solved now.