Gentoo Archives: gentoo-alt

From: Benda Xu <heroxbd@g.o>
To: "François Bissey" <francois.bissey@×××××××××××××.nz>
Cc: gentoo-alt@l.g.o
Subject: Re: [gentoo-alt] RAP on ppc64 (SLES11.1)
Date: Sun, 29 Jan 2017 02:50:14
Message-Id: 87y3xueg1u.fsf@gentoo.org
In Reply to: [gentoo-alt] RAP on ppc64 (SLES11.1) by "François Bissey"
1 Hi François,
2
3 François Bissey <francois.bissey@×××××××××××××.nz> writes:
4
5 > I now have a working RAP environment on ppc64.
6 > So here is a bit of recipe to achieve this:
7 > * There is no current ppc64 profile, so one has to be
8 > created during stage 1.
9 > I copied the ppc64 from prefix/linux to prefix/linux-standalone.
10 > Replace make.default inside prefix/linux-standalone/ppc64
11 > by the one in prefix/linux-standalone/amd64.
12 > Copy the "legacy" folder from prefix/linux-standalone/amd64
13 > to prefix/linux-standalone/ppc64.
14
15 Thanks!
16
17 > * Make sure help2man is installed on the host system (for bison).
18
19 I don't remember if the bare minimal OpenSUSE 42.1 needed this.
20
21 > * I would like the following patch to be considered
22 > for the bootstrap script
23 > --- bootstrap-rap.sh.orig 2017-01-24 12:20:27.304355158 +1300
24 >
25 >
26 > +++ bootstrap-rap.sh 2017-01-24 12:34:30.325185905 +1300
27 >
28 >
29 > @@ -1382,8 +1382,8 @@
30 >
31 >
32 > sys-libs/ncurses
33 >
34 >
35 > sys-libs/readline
36 >
37 >
38 > app-shells/bash
39 >
40 >
41 > - sys-apps/sed
42 > app-arch/xz-utils
43 > + sys-apps/sed
44
45 > The latest version of sed is compressed with xz which
46 > means the bootstrap will fail if xz-utils is not installed
47 > in /bin or /usr/bin.
48 > Newer distro probably have it but not older ones.
49 > So we should move xz-utils before sed.
50
51 Which tarball (URL) did it use?
52
53 > + PERL_NOT_INSTALLED=0
54 >
55 >
56 > if [[ ! -x "${ROOT}"/usr/bin/perl ]]; then
57 >
58 >
59 > # trick "perl -V:apiversion" check of
60 > glibc-2.19.
61 >
62 > echo -e "#!${ROOT}/bin/sh\necho
63 > 'apiversion=9999'" > "${ROOT}"/usr/bin/perl
64 >
65 > chmod +x "${ROOT}"/usr/bin/perl
66 >
67 >
68 > + PERL_NOT_INSTALLED=1
69 >
70 > - rm "${ROOT}"/usr/bin/perl
71 >
72 >
73 > + # Do not mindlessly remove perl. Only if it wasnt
74 > present in the first place.
75 >
76 > + [[ ${PERL_NOT_INSTALLED} == 1 ]] && rm
77 > "${ROOT}"/usr/bin/perl
78 >
79 > else
80
81 > The other part of the patch is specific to RAP and is
82 > vexing. RAP adds a fake perl executable before building
83 > glibc in case perl is not already there - and remove it,
84 > unconditionally. So you are here you had a failure in stage3
85 > after glibc has been merged and then perl has been merged.
86 > You fixed whatever needs fixing and restart the bootstrap
87 > and it removes your perl binary. And then you spend some
88 > time wondering why autoconf failed while emerging something.
89 > So I added a guard - only remove the perl executable if it is
90 > the fake one. I guess that could be improved by actually
91 > checking the file itself for the content of the fake perl.
92
93 Sorry for this, I added a guard
94
95 https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=db54c48edfb3d7c5c482326c8c57d3823941f456
96
97 > * As per another post the current bits to set the RAP glibc
98 > to be used by gcc are not sufficient for ppc64. My profile.bashrc
99 > has the following
100 > if [[ ${CATEGORY}/${PN} == sys-devel/gcc && ${EBUILD_PHASE} ==
101 > configure ]]; then
102 > cd "${S}"
103 > einfo "Prefixifying dynamic linkers..."
104 > for h in gcc/config/*/*linux*.h; do
105 > ebegin " Updating $h"
106 > sed -i -r "/_DYNAMIC_LINKER/s,([\":])(/lib),\1${EPREFIX}\2,g" $h
107 > eend $?
108 > done
109 >
110 >
111 > The only change being to the sed line.
112
113 Nice.
114
115 I am wondering if it is feasible to grant me access to a ppc64 box with
116 SLES 11.1 to test out these patch before committing to the
117 repositories.
118
119 Yours,
120 Benda

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies

Subject Author
Re: [gentoo-alt] RAP on ppc64 (SLES11.1) Francois Bissey <francois.bissey@×××××××××××××.nz>
Re: [gentoo-alt] RAP on ppc64 (SLES11.1) Fabian Groffen <grobian@g.o>