From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11974 invoked by alias); 8 Nov 2002 02:10:44 -0000 Mailing-List: contact libc-hacker-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-hacker-owner@sources.redhat.com Received: (qmail 11938 invoked from network); 8 Nov 2002 02:10:44 -0000 Received: from unknown (HELO are.twiddle.net) (64.81.246.98) by sources.redhat.com with SMTP; 8 Nov 2002 02:10:44 -0000 Received: (from rth@localhost) by are.twiddle.net (8.11.6/8.11.6) id gA82AYm04150; Thu, 7 Nov 2002 18:10:34 -0800 Date: Thu, 07 Nov 2002 18:10:00 -0000 From: Richard Henderson To: Roland McGrath Cc: davidm@hpl.hp.com, libc-hacker@sources.redhat.com, hjl@lucon.org Subject: Re: patch to make init_array work (2nd version; resend) Message-ID: <20021107181034.B4047@twiddle.net> Mail-Followup-To: Roland McGrath , davidm@hpl.hp.com, libc-hacker@sources.redhat.com, hjl@lucon.org References: <15818.57443.807212.759018@napali.hpl.hp.com> <200211072158.gA7Lwqu29021@magilla.sf.frob.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <200211072158.gA7Lwqu29021@magilla.sf.frob.com>; from roland@redhat.com on Thu, Nov 07, 2002 at 01:58:52PM -0800 X-SW-Source: 2002-11/txt/msg00034.txt.bz2 On Thu, Nov 07, 2002 at 01:58:52PM -0800, Roland McGrath wrote: > That seems like a reasonable thing to do, though it's unfortunate it means > changing all the platforms' start.S files. For preinit_array+init_array, > start.S could just contain the code in the .init section, no? But probably > it is better to write generic _init/_fini replacements in C. I think the best solution is to write static void do_all_init(void) { // Loop over .preinit_array // Loop over .init_array _init (); } or whatever the proper ordering is, and then pass this new function to __libc_start_main. r~