Gentoo Archives: gentoo-portage-dev

From: Zac Medico <zmedico@g.o>
To: gentoo-portage-dev@l.g.o
Subject: Re: [gentoo-portage-dev] [PATCH v2] install-qa-check.d: issue warnings for 32bit ELFs not using LFS
Date: Sat, 30 May 2015 18:23:04
Message-Id: 5569FFFF.8030504@gentoo.org
In Reply to: Re: [gentoo-portage-dev] [PATCH v2] install-qa-check.d: issue warnings for 32bit ELFs not using LFS by Mike Frysinger
1 On 05/30/2015 07:36 AM, Mike Frysinger wrote:
2 > On 26 May 2015 08:58, Zac Medico wrote:
3 >> On 05/26/2015 07:24 AM, Mike Frysinger wrote:
4 >>> + # Only check on 32-bit systems. Filtering by $ARCH here isn't perfect, but
5 >>> + # it should be good enough for our needs.
6 >>> + case ${ARCH} in
7 >>> + arm|mips|ppc|sh|x86) ;;
8 >>> + *) return ;;
9 >>> + esac
10 >>
11 >> Shouldn't we also enable this for 64-bit archs when multilib is enabled?
12 >
13 > yes, but i think we should start here first. getting multilib right is kind of
14 > a pain. this should give us enough coverage i think to get people to start
15 > filing bugs which implicitly covers multilib users. once the dust has settled,
16 > we can look at expanding the multilib coverage. although that would really
17 > require a python implementation, and the current install hooks logic implicitly
18 > requires every file to be bash.
19 >
20 > to use your pkg-config example, it installs 32bit & 64bit ELFs into /usr/bin.
21 > we can't scan all 32bit ELFs because it would incorrectly flag ILP32 ABIs like
22 > x32 & n32.
23
24 Our compute_multilib_category function has logic that could be used to
25 separate and filter them:
26
27 https://gitweb.gentoo.org/proj/portage.git/tree/pym/portage/dep/soname/multilib_category.py
28
29 > ideally we'd scan the whole multilib dir, but that too runs into problems.
30 > when /usr/lib is the path for both x86 multilib and non-multilib content (like
31 > libexec stuff), we can't blindly scan & reject all ELFs in there. the previous
32 > note about ILP32 applies here too.
33 >
34 > so if we're happy with this implementation, i'll start a thread on gentoo-dev so
35 > people aren't caught by surprise, and we can merge this for the next release.
36 > -mike
37 >
38
39 Okay, fine.
40 --
41 Thanks,
42 Zac

Replies