comp.lang.ada
 help / color / mirror / Atom feed
From: Simon Wright <simon@pushface.org>
Subject: ANN: GCC 4.9.1 for Mac OS X Mavericks and Yosemite
Date: Tue, 21 Oct 2014 15:45:50 +0100
Date: 2014-10-21T15:45:50+01:00	[thread overview]
Message-ID: <lya94pscpt.fsf@pushface.org> (raw)

GCC 4.9.1 is available at
https://sourceforge.net/projects/gnuada/files/GNAT_GCC%20Mac%20OS%20X/4.9.1/

It was built on Mavericks and is compatible with Yosemite.

The README:

This is GCC 4.9.1 built for Mac OS X Mavericks (10.9.5, Darwin
13.5.0), with Xcode 6.0.1.

gcc-4.9.1-x86_64-apple-darwin13.tar.bz2
=======================================

Compilers included: Ada, C, C++, Objective C, Objective C++, Fortran.

Tools included:

Full GPL:
  ASIS, AUnit, GDB, GNATColl, and GPRbuild from GNAT GPL 2014.

GPL with Runtime Library Exception[1]:
  XMLAda from the public SVN repository[2] at revision 233185
    (XMLAda-SVN for short).
  AWS from the public git repository[3] at commit
    e0d260e2d5dbbd93577949307935848de2390818 (AWS-git for short).

Target: x86_64-apple-darwin13
Configured with: ../gcc-4.9.1/configure \
  --prefix=/opt/gcc-4.9.1 \
  --disable-multilib \
  --disable-nls \
  --enable-languages=c,c++,ada,fortran,objc,obj-c++ \
  --host=x86_64-apple-darwin13 \
  --target=x86_64-apple-darwin13 \
  --build=x86_64-apple-darwin13 \
  --with-host-libstdcxx=-lstdc++
Thread model: posix
gcc version 4.9.1 (GCC)

MD5 (gcc-4.9.1-x86_64-apple-darwin13.tar.bz2) = f04d5d773174a4a58cdd2dd4871785a4

[1] http://www.gnu.org/licenses/gcc-exception-faq.html
[2] http://svn.eu.adacore.com/anonsvn/Dev/trunk/xmlada
[3] http://forge.open-do.org/anonscm/git/aws/aws.git

Install by
=======

$ cd /
$ sudo tar jxvf ~/Downloads/gcc-4.9.1-x86_64-apple-darwin13.tar.bz2

and put /opt/gcc-4.9.1/bin first on your PATH.

Installing GDB
--------------

gdb has to be 'code-signed' (unless you're willing to run it as root!)

Instructions are at
https://gcc.gnu.org/onlinedocs/gnat_ugn_unw/Codesigning-the-Debugger.html

Notes
=====

The compiler is GPL verson 3. The runtime has the GCC Runtime
Exception, so executables built with it can be released on proprietary
terms PROVIDED THAT they make no use of the the packages from GNAT GPL
2014, which are full GPL.

Thanks to Mario Roy <marioeroy@gmail.com> for finding the configure
flag --with-host-libstdcxx=-lstdc++, which suppresses GCC bug 61027.

Thanks to Leo Brewin <leo.brewin@internode.on.net> for reporting a
problem on Mac OS X Yosemite (10.10) ("gcc: warning: couldn't
understand kern.osversion '14.0.0'", followed by undefined symbols
__Unwind_Backtrace etc.) This corresponds to GCC PR/61407; the patch
at SVN revision 215690 (compiler parts only) was applied, see
gcc-4.9.1-yosemite.diff.

During the stage2/stage3 comparison, the build reported

   Comparing stages 2 and 3
   warning: gcc/cc1-checksum.o differs
   warning: gcc/cc1obj-checksum.o differs
   warning: gcc/cc1objplus-checksum.o differs
   warning: gcc/cc1plus-checksum.o differs
   Comparison successful.

XMLAda-SVN requires gprbuild, and gprbuild requires XMLAda. The
workround was first to build and install the GPL 2014 version, then
build gprbuild, then build and install XMLAda-SVN. One change was
required, in xmlada-svn-233185.diff.

Changes made to GPRbuild GPL 2014 are in gprbuild-gpl-2014-src.diff. They:
* remove the '-c' flag that is wrongly passed to ranlib (and isn't by
  gnatmake).
* correct a problem when building static stand-alone libraries (GCC
  bug 56616).
* remove some restrictions not provided in FSF GCC yet: No_Fixed_IO,
  No_Long_Long_Integers, No_Multiple_Elaboration.
* import the new library package GNAT.Rewrite_Data (used by
  gprslave). This had to be compiled by hand:
    $ gnatmake -a -P gprbuild -XBUILD=production g-rewdat.adb
* retain the bug in gprinstall which installs executables with
  'execute' access for the owner only rather than for all users (this
  is a problem if the installation is done by root). The change relies
  on a change in the RTS (adaint.c).
* gprslave can't call Set_File_Last_Modify_Time_Stamp (adaint.c
  again).

GNATColl GPL 2014 was configured as below, which is minimal apart from
GNU Readline being enabled and PostGres being disabled. Users may wish
to reconfigure for their own requirements.

  ./configure \
    --prefix=/opt/gcc-4.9.1 \
    --build=x86_64-apple-darwin13 \
    --enable-gpl \
    --without-postgresql

resulting in

  Shared libraries:       yes (default: static)
  Gtk+:                   no (requires pkg-config and gtkada.gpr)
  Python:                 yes /System/Library/Frameworks/Python.framework/Versions/2.7 (see --with-python)
  PyGtk:                  no  (see --enable-pygtk)
  PyGObject:              no (see --enable-pygobject)
  Syslog:                 yes (see --enable-syslog)
  Readline (GPL license): yes (see --with-readline --enable-gpl)
  gmp:                    no (see --with-gmp)
  PostgreSQL:             no -L/usr/lib (see --with-postgresql)
  Sqlite:                 embedded  (see --with-sqlite)
  Iconv:                  yes (see --with-iconv)
  Projects:               yes

Changes to ASIS GPL 2014 are in asis-gpl-2014-src.diff. Only
changes necessary for the build are included.

GDB GPL 2014 built without changes (to the source: the files
binutils/nm.c and binutils/objcopy.c had to be compiled by hand
without the -Werror flag), but there are problems with 'catch
exception'; one workround is to invoke GDB with the '-readnow'
switch. See https://sourceware.org/bugzilla/show_bug.cgi?id=11385 A
word of warning: when building GDB, do NOT 'make install' from the
top-level directory; it will install all sorts of tools you didn't
want (ar, nm, ranlib ...) and which won't work properly. Instead,
'make install' from the gdb/ directory (or just copy gdb/gdb to the
compiler bin/ directory!)

AWS was configured to use secure sockets via openssl and ASIS (for
ada2wsdl). The resulting makefile.setup was

  prefix=/opt/gcc-4.9.1/bin/..
  DEFAULT_LIBRARY_TYPE=static
  ENABLE_SHARED=true
  ZLIB=true
  XMLADA=true
  ASIS=true
  IPv6=false
  SOCKET=openssl
  LDAP=false
  DEBUG=false
  PROCESSORS=0
  TARGET=x86_64-apple-darwin13

Note that, although the GPL'd ASIS is imported, only ada2wsdl uses it,
and in any case the tools are full GPL. The AWS libraries have the GCC
Runtime Library Exception.


In addition to the above, a new library gnat_util is required by ASIS
and GNATColl. A Sourceforge project to provide this has been set up at
https://sourceforge.net/projects/gnatutil/; release 4.9.1 is included
here. This is the equivalent of the Debian libgnatvsn.


             reply	other threads:[~2014-10-21 14:45 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-21 14:45 Simon Wright [this message]
2014-10-21 16:08 ` ANN: GCC 4.9.1 for Mac OS X Mavericks and Yosemite David Botton
2014-10-21 16:10   ` David Botton
2014-10-21 17:15   ` Simon Wright
2014-10-21 17:56     ` David Botton
2014-10-21 18:27       ` David Botton
2014-10-21 19:27         ` Simon Wright
2014-10-21 19:42       ` Simon Wright
2014-10-21 19:50         ` David Botton
2014-10-26  9:22 ` dptrash
2014-10-26 11:12   ` Simon Wright
2014-10-26 21:33     ` vincent.diemunsch
2014-10-28 13:34       ` David Botton
2014-10-28 19:29         ` Simon Wright
2014-10-30 12:53           ` David Botton
2014-10-30 13:32             ` Simon Wright
2014-10-30 16:36               ` David Botton
2014-10-30 17:33                 ` Simon Wright
2014-11-03 19:34                   ` Laurent
2014-11-03 19:45                     ` Laurent
2014-11-17 22:47       ` vincent.diemunsch
2014-11-19 17:13         ` Simon Wright
2014-11-20 21:19           ` vincent.diemunsch
2014-11-20 21:26             ` Simon Wright
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox