[gtkada] patch for mac

Chris Douty Chris_Douty at ampex.com
Mon Jul 26 20:31:24 CEST 2004


On Saturday, July 24, 2004, at 02:42 AM, Arnaud Charlet wrote:
[snip]
>> First question:  Do you require a particular autoconf version?  If 
>> not,
>> then I will not include the diffs to configure since they are
>> redundant.  Whoever applies the patch can run autoconf.
>
> Right (we always use the same version to avoid extra diffs in CVS,
> but you can ignore this part).
>
> What I'd suggest as a first step is to disable build of shared gtkada 
> libs
> on MacOS. That will simplify things greatly, and will avoid having lots
> of darwin specific code. Once we have a clean integration/support
> of darwin without shared libs, the support for shared libs can be added
> as an extra step without blocking everything.
>
> To disable shared lib, simply set BUILD_SHARED=no in aclocal.m4 for 
> darwin

That's what I did first.  For the current GNAT on OS X 10.3 I don't 
think any other modifications are necessary other than replacing 
config.guess and config.sub.  Basic static libraries are easy.

It would be nice to provide a configure argument --with-shared=(yes|no) 
rather than hacking at aclocal.m4.  Some folks probably need a static 
library even on an OS where you build shared by default, unless both 
variants are built.


> Also note that system conditional code/sections are only allowed in the
> configure-related files (Aclocal.m4, configure.in), not in Makefiles.
>
> So if you have darwin conditional code in Makefile, please factor 
> these out
> and move them to aclocal.m4 if possible, thanks.

You already have a conditional section on BUILD_SHARED in the 
Makefiles.  Darwin uses significantly different arguments to build 
shared libraries than ELF-based OSes.  This seemed like the easiest 
solution, but it probably requires GNUMake.  If you banish if's from 
the Makefiles then I will need to do radical surgery on the whole build 
system.  Note that many other projects use GNU libtool to handle 
library building mechanics.  I'd prefer not to because it is really 
complicated.

>
>> I hope to get some of these issues sorted out soon.  I get the sense
>> that there is now a desire to spin a release that builds against GTK+
>> 2.4.x, and since most Mac users are going to get that version I'd like
>> to see GtkAda build out of the box as it were.  If necessary I could
>
> That would be nice indeed.
>
> Thanks for your effort.

If I can get some time tonight (I've got a 2 month-old to contend with 
:-) I will try to spin out a working patch that builds static GtkAda 
for darwin.  Then I'll follow up with a dynamic library version.

Cheers,
	Chris

-- 
Christopher Douty <Chris_Douty at ampexdata.com> +1-650-367-3129
Senior Engineer, Software & Systems  - AMPEX Data Systems Corp.




More information about the gtkada mailing list