From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: ANN: GCC 4.9.1 for Mac OS X Mavericks and Yosemite Date: Tue, 21 Oct 2014 15:45:50 +0100 Organization: A noiseless patient Spider Message-ID: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: mx02.eternal-september.org; posting-host="71797db6fbf0039ebda7a9c799ddb33f"; logging-data="727"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+4WGTpgNaRrRrlSCsOL0Mp58r4fqap8O0=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (darwin) Cancel-Lock: sha1:BU/OVY2fjfOttzG+pCjTpk0JnNQ= sha1:MyJC05JXDVPs9vBIDDxJqlQua1A= Xref: news.eternal-september.org comp.lang.ada:22632 Date: 2014-10-21T15:45:50+01:00 List-Id: 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 for finding the configure flag --with-host-libstdcxx=-lstdc++, which suppresses GCC bug 61027. Thanks to Leo Brewin 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.