This is the mail archive of the mailing list for the glibc project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: building every released version of GCC starting with 4.1.2, with appropriate matching glibc

On 06.04.2017 22:58, Toebs Douglass wrote:
> Hi, everyone.
> I am the author of a library of a portable, platform-independent
> lock-free data structures, written in C.
> I wish to compile the library, the test application and the benchmark
> application on every released version of GCC, starting with version
> 4.1.2, using the appropriate glibc.
> Unless I do this, I cannot know the code compiles and runs on the GCCs
> end-users may be using.
> I have emailed here both the GCC and glibc help mailing lists, as I have
> seen that achieving this goal is something which involves a good deal of
> knowledge in both domains.
> I have read many times the suggestion to use a VM and an old distro;
> this is not viable, as the nature of lock-free is that race conditions
> are a major concern, and so the test machines need to be going flat-out,
> not in a VM.  Moreover, benchmarking on a VM is in many ways inherently
> undesirable.
> I would like to say lest readers imagine I am lightly asking for help
> that although I have a day job, and so cannot work on this all the time,
> I have spent now nine weeks trying to achieve this goal.
> I am to begin with trying only to build on my system the same version of
> GCC as the system GCC.  I am aware there are issues involved in trying
> to compile much earlier version of GCC, where stepping-stone GCCs must
> be made, but this is for the future; right now, I simply want to get *a*
> GCC compiled.  I will in the future also if I can be making native
> builds on arm, aarch64 and mipsel, but this also is not for thinking
> about now.
> My current high-level understanding is as follows;
> 1. create a directory to use as the sysroot
> 2. build binutils using the system native GCC, install to the sysroot
> 3. export the linux headers to sysroot
> 4. export glibc headers to sysroot
> 5. build GCC the first time (with appropriate version of mpfr, gmp, mpc)
> and the system glibc
> 6. now build glibc with the GCC from #5
> 7. build GCC the second time, using the glibc from #6
> 8. and we're done
> If there are mistakes here, and if they can be sorted out, then we can
> turn to more detail and the actual commands I'm issuing.

NetBSD portable packages (pkgsrc) ship with gcc2, gcc3, gcc42, 43, 44,
45, 46, 47, 48, 49, 5, 6, 7.

You should be able to build them on any glibc version on a glibc system
(gcc2 has no amd64 target). Older versions might require additional
patches for bootstrapping with newer gcc.

Attachment: signature.asc
Description: OpenPGP digital signature

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]