Subject: gcc-3.3.1, with gnat, java, c++, fortran, objc and c
From: "Gerrit P. Haase" <[email-masked]>
To: [email-masked]
Date: Sat, 16 Aug 2003 13:42:18 +0200

Hallo all,

I have just finished building gcc-3.3.1 based on MinGW patch with
the latest Cygwin test release 1.5.2, the MinGW patch was slightly
extended/fixed, below minimalistic test succeeds for all languages.
The C++ binaries are about 10% smaller as with previous versions.
I uploaded my latest patchfile (diff against vanilla gcc-3.3.1 source)
and also my buildscripts: http://angfaenger.de/cygwin-1.5/gcc/
I'll upload the binary package tomorrow, so there is GNAT for
Cygwin available then, will announce it separatly tomorrow.

It is also possible to use the Cygwin gnat compiler from David
Billinghurst to bootstrap GCC with Ada, this is what I did too, please
see the README at the above website.  There were some problems for me,
I couldn't use David's gcc-3.2 to bootstrap gcc because of a segfault
at some point (235kb C source file couldn't be compiled), so I used my
own gcc-3.3 to bootstrap GCC and David's gnatgcc to bootstrap GNAT,
and I think the default cygwin gcc-3.2-x build should also be able to
bootstrap GCC 3.3.1, though I didn't tried it.

Ultra minimalistic compiler test gcc-3.3.1 (umini.sh):

#! /bin/sh
set -x
# GNAT:
echo 'with Text_Io; use Text_Io;' > hello.adb
echo 'procedure hello is' >> hello.adb
echo 'begin' >> hello.adb
echo '  put ("Hello world!");' >> hello.adb
echo 'end hello;' >> hello.adb
/usr/bin/gnatmake hello
./hello
# GCJ:
echo 'public class Hello_j {' > Hello_j.java
echo 'public static void main(String[] args) {' >> Hello_j.java
echo '        System.out.println("Just another Java hacker,");' >> Hello_j.java
echo '        }' >> Hello_j.java
echo '}' >> Hello_j.java
/usr/bin/gcj --main=Hello_j Hello_j.java -o Hello_j
./Hello_j
# G++:
echo '#include<iostream>' > pointersize.cc
echo 'using namespace std;' >> pointersize.cc
echo '#define VOID_PTR void *' >> pointersize.cc
echo 'int main() {' >> pointersize.cc
echo '  cout << "__CYGWIN__ pointer size is: " << (int)sizeof(VOID_PTR) << "\n";' >> pointersize.cc
echo '}' >> pointersize.cc
/usr/bin/g++ -o pointersize pointersize.cc
./pointersize
# G77:
echo '       print *,"Hello world!"' > hello.f
echo '       end' >> hello.f
/usr/bin/g77 -o hello_f hello.f
./hello_f
# OBJC
echo '/*   hello.m' > hello.m
echo ' *   gcc -o hello hello.m -lobjc' >> hello.m
echo ' */' >> hello.m
echo 'main()' >> hello.m
echo '{' >> hello.m
echo '    printf("Hello World,\n");' >> hello.m
echo '}' >> hello.m
/usr/bin/gcc -o hello_o hello.m -lobjc
./hello_o
# C
echo '#include <stdio.h>' > hello.c
echo 'int main() {' >> hello.c
echo '  puts("hello, world");' >> hello.c
echo '  return 0;' >> hello.c
echo '}' >> hello.c
/usr/bin/gcc -o hello_c hello.c
./hello_c

Gerrit
-- 
=^..^=

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/