From dev-return-22424-apmail-apr-dev-archive=apr.apache.org@apr.apache.org Wed Oct 14 12:42:23 2009 Return-Path: Delivered-To: apmail-apr-dev-archive@www.apache.org Received: (qmail 51534 invoked from network); 14 Oct 2009 12:42:23 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 14 Oct 2009 12:42:23 -0000 Received: (qmail 90498 invoked by uid 500); 14 Oct 2009 12:42:22 -0000 Delivered-To: apmail-apr-dev-archive@apr.apache.org Received: (qmail 90399 invoked by uid 500); 14 Oct 2009 12:42:22 -0000 Mailing-List: contact dev-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Id: Delivered-To: mailing list dev@apr.apache.org Received: (qmail 90391 invoked by uid 99); 14 Oct 2009 12:42:22 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 14 Oct 2009 12:42:22 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of jorton@redhat.com designates 209.132.183.28 as permitted sender) Received: from [209.132.183.28] (HELO mx1.redhat.com) (209.132.183.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 14 Oct 2009 12:42:15 +0000 Received: from int-mx08.intmail.prod.int.phx2.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n9ECfr96025248 for ; Wed, 14 Oct 2009 08:41:53 -0400 Received: from turnip.manyfish.co.uk (vpn-12-111.rdu.redhat.com [10.11.12.111]) by int-mx08.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id n9ECfp2C009344 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Wed, 14 Oct 2009 08:41:53 -0400 Received: from jorton by turnip.manyfish.co.uk with local (Exim 4.69) (envelope-from ) id 1My3As-0001bb-HU for dev@apr.apache.org; Wed, 14 Oct 2009 13:41:50 +0100 Date: Wed, 14 Oct 2009 13:41:50 +0100 From: Joe Orton To: APR Developer List Subject: Re: svn commit: r824767 - in /apr/apr/trunk: build/apr_hints.m4 configure.in include/apr.h.in include/apr_os_override.h include/arch/darwin/ include/arch/darwin/apr_darwin_types.h Message-ID: <20091014124150.GA3075@redhat.com> Mail-Followup-To: APR Developer List References: <20091013135820.35F0D238889D@eris.apache.org> <20091013151855.GA15610@redhat.com> <4AD51A57.9090209@rowe-clan.net> <20091014110001.GA5327@redhat.com> <4A13EE9C-3BE1-4AED-A8AC-E0B47C29F46B@jaguNET.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <4A13EE9C-3BE1-4AED-A8AC-E0B47C29F46B@jaguNET.com> User-Agent: Mutt/1.5.19 (2009-01-05) Organization: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SL4 1TE, United Kingdom. Registered in UK and Wales under Company Registration No. 03798903 Directors: Michael Cunningham (USA), Brendan Lane (Ireland), Matt Parson (USA), Charlie Peters (USA) X-Scanned-By: MIMEDefang 2.67 on 10.5.11.21 X-Virus-Checked: Checked by ClamAV on apache.org On Wed, Oct 14, 2009 at 08:00:20AM -0400, Jim Jagielski wrote: > On Oct 14, 2009, at 7:00 AM, Joe Orton wrote: >> Reducing half of our configure-time tests to build-time compiler macro >> tests for one platform is not going to be maintainable. Why is it >> useful for Joe Random APR User to be building for more than one ABI in >> the first place? Why the heck would he care? Just pick a default and >> run with it by setting $CC to select an ABI. > > If APR is built with i386, and installed, then any apps built for > 64 bit will core dump on it. The reverse is true as well. If APR changes $CC to force a platform ABI choice as I suggested, then any apps built against APR will be (must be) built using the same $CC, inherited via `apr-N-config --cc`. Otherwise all bets are off, as has always been true. > The default is to build for *both*. And when this is done, then > the bit sizes locked in apr.h may or may not be correct depending > on how you build the app that will be *using* it. The __LP64__ > tests in the apr.h (etal) files is to ensure that depending on > how people are building *against an installed APR* will have > the right values. Otherwise, anyone shipping an APR lib must > built it for just 1 architecture and ensure that any consumers > build against just that architecture. Packagers/redistributors can build APR twice (or N times) and merge the results to get a "fat" binary - this is a problem for Darwin packagers, not for upstream. From a 10 second google, this seems to be how Apple recommend you do it: http://developer.apple.com/opensource/buildingopensourceuniversal.html I would not be averse to including (configure --enable-flag conditional) a solution like the apr-wrapper.h we use in Fedora to allow distribution of a single arch-independent apr.h which will DTRT on multiple platforms, if there's wider support for that. But that wouldn't distract from the need to build the thing twice and merge the results. > At the very least we should create an APR define that specifies > what bitsize was used APR_SIZEOF_VOIDP? Regards, Joe