1 |
On 09/21/2014 17:55, Anthony G. Basile wrote: |
2 |
> On 09/17/14 16:19, Anthony G. Basile wrote: |
3 |
[snip] |
4 |
> |
5 |
> This isn't going to work. The problem is that the above structure doesn't |
6 |
> distinguish between mips/o32 and mips64/o32 (and equivalent el versions). Now |
7 |
> mips64/o32 is funny, but possible: it would be o32 (a 32-bit abi) on 64 bit |
8 |
> arch/kernel, like ppc64-32ul. The structure is possible at the level of |
9 |
> profile/arch, but it would mean a deep restructuring of default/linux/mips/13.0. |
10 |
|
11 |
Err, I've been using this setup for the last 9+ years? My Octane and O2 both |
12 |
boot mips64 kernels and run an o32-only userland. It works fine with the |
13 |
current profile setup. You just use a mips-unknown-linux-gnu CHOST. I may not |
14 |
be able to fully utilize all of the CPU registers like I would under n32, but |
15 |
that's never been an issue for me. |
16 |
|
17 |
So there should be no need to differentiate at the userland level between |
18 |
mips/o32 and mips64/o32. As long as the CHOST is set correctly, o32 will work |
19 |
fine under a mips64 kernel (caveat: make sure CONFIG_MIPS32_O32 is set in the |
20 |
kernel). |
21 |
|
22 |
Correct me if wrong, but it seems the core problem here is that multilib |
23 |
inherits from the o32 base profile. While I think the proper longterm fix is |
24 |
to have more discrete, modular/pluggable profile components (like OOP and |
25 |
multiple base classes), that's not going to happen in Portage for a long time. |
26 |
|
27 |
So I think the solution is to split the profiles into "mips" and "mips64", |
28 |
i.e., 32/ and 64/ under the 'mips' base profile folder. 32/ contains |
29 |
everything needed to run pure o32-only under either a mips or mips64 kernel. |
30 |
I.e., mips-unknown-linux-gnu CHOST. So on my Octane, /etc/portage/make.profile |
31 |
symlinks to /usr/portage/default/linux/mips/32/<VERSION>/ |
32 |
|
33 |
64/ is where the fun is at. I think the default ABI there should be n32 at the |
34 |
base, with a subprofile for multilib that itself contains subprofiles to handle |
35 |
the combinations of ABIs desired. Still have to workout what CHOST you use for |
36 |
the base (GNU standard for n32 is mips64-unknown-linux-gnueabin32). multilib |
37 |
would just use mips64-unknown-linux-gnu, and -mabi would be passed to gcc to |
38 |
pick the ABI to build for. |
39 |
|
40 |
Also, if we are going to do any kind of reorganizing of the profiles, let's not |
41 |
do it under 13.0. Personally, I'd like to get away from datestamps as profile |
42 |
versions (13.0 refers to 2013) and either pick a fixed version number that we |
43 |
increment or come up with some other kind of versioning scheme. Or just do |
44 |
away with it altogether and have something like a "stable" profile where things |
45 |
work and an "unstable" branch that only exists when we're doing insane changes |
46 |
to the profiles, which after testing, becomes "stable" (and current "stable" |
47 |
becomes "oldstable" or such). |
48 |
|
49 |
If we have to stick with datestamped versions, then use 15.0. Cause it'll be |
50 |
2015 by the time this goes active. |
51 |
|
52 |
rough draft of the top-level layout. Doesn't care about chosen libc, ISA, or |
53 |
<VERSION>, but does reflect endianness. |
54 |
|
55 |
default/linux/mips |
56 |
| |
57 |
|-32/ |
58 |
| |-be/ |
59 |
| |-le/ |
60 |
| |
61 |
|-64/ |
62 |
| |-be/ |
63 |
| |-le/ |
64 |
| | |
65 |
| |-multilib/ |
66 |
| | |-be/ |
67 |
| | |-le/ |
68 |
| | |
69 |
| |
70 |
|
71 |
|
72 |
> Maybe we just don't want to support mips64/o32? I'm starting to lean towards |
73 |
> Ian's simple but asymmetric solution of turning off o32 in the inheriting |
74 |
> profiles. |
75 |
|
76 |
NAK |
77 |
|
78 |
-- |
79 |
Joshua Kinard |
80 |
Gentoo/MIPS |
81 |
kumba@g.o |
82 |
4096R/D25D95E3 2011-03-28 |
83 |
|
84 |
"The past tempts us, the present confuses us, the future frightens us. And our |
85 |
lives slip away, moment by moment, lost in that vast, terrible in-between." |
86 |
|
87 |
--Emperor Turhan, Centauri Republic |