delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2010/08/16/16:20:40

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-50.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,TW_BG,TW_GC,TW_JC,T_TO_NO_BRKTS_FREEMAIL
X-Spam-Check-By: sourceware.org
Subject: gcc-4.5 notes
From: "Yaakov (Cygwin/X)" <yselkowitz AT users DOT sourceforge DOT net>
To: cygwin AT cygwin DOT com
Date: Mon, 16 Aug 2010 15:20:25 -0500
Message-ID: <1281990025.7012.82.camel@YAAKOV04>
Mime-Version: 1.0
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

--=-8YaBSNw9Rk4NELY2zaiE
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit

Dave,

Several notes about gcc-4.5.0:

1) I'm using a new FIONREAD patch for Classpath which solves several
issues.  Matching patch for gcc-4.5 attached.

2) fix-libtool-scripts-for-latest-gcc-runtimes.sh doesn't actually do
anything; 's|echo sed|sed|g' fixes that.

3) libgnat import libs are missing:

$ gnatmake hello.adb -bargs -shared
gcc -c hello.adb
gnatbind -shared -x hello.ali
gnatlink hello.ali -shared-libgcc
/usr/lib/gcc/i686-pc-cygwin/4.5.0/../../../../i686-pc-cygwin/bin/ld:
cannot find -lgnat-4.5
collect2: ld returned 1 exit status
gnatlink: error when calling /usr/bin/gcc.exe
gnatmake: *** link failed.

Looking at gcc/ada/gcc-interface/Makefile.in, it looks like there is
supposed to be a adalib/libgnat-4.5.dll.a symlink, but it's not quite
right.  Patch for 4.5.1 attached.

4) After creating said symlink, the resulting binary outputs "Hello,
world!" but does not exit, and requires kill -f to terminate.  The same
code linked statically (IOW w/o "-bargs -shared") runs and exits
correctly.

5) Several -4-suffixed programs have no unversioned alternatives; this
includes: aot-compile, gccbug, jcf-dump, rebuild-gcj-db.  (Of course, if
we drop gcc3, or at least its alternatives, then gcc4 can be
unversioned, making this point moot.)

6) Are the gcj tools working?  If not, perhaps they should just be
dropped until they get figured out.  An alternative would be for me to
ITP my Classpath-based stack.

7) jni.h and jni_md.h should probably be shipped with gcc4-java instead
of gcc4-core.

8) It would be helpful if gcc4-core would provide a libffi.pc pkg-config
file, since for us this is *the* libffi.

HTH,


Yaakov


--=-8YaBSNw9Rk4NELY2zaiE
Content-Disposition: attachment; filename="classpath-0.98-FIONREAD.patch"
Content-Type: text/x-patch; name="classpath-0.98-FIONREAD.patch"; charset="UTF-8"
Content-Transfer-Encoding: 7bit

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35536

--- origsrc/gcc-4.5.0/libjava/classpath/native/jni/java-nio/gnu_java_nio_VMChannel.c	2007-12-28 11:49:56.000000000 -0600
+++ src/gcc-4.5.0/libjava/classpath/native/jni/java-nio/gnu_java_nio_VMChannel.c	2010-05-11 03:55:47.789066200 -0500
@@ -1601,7 +1601,7 @@ Java_gnu_java_nio_VMChannel_available (J
   if (ioctl (fd, FIONREAD, &avail) == -1)
     {
 #if defined(ENOTTY) && defined(HAVE_FSTAT)
-      if (errno == ENOTTY)
+      if (errno == ENOTTY || errno == EINVAL)
         {
           if ((fstat (fd, &statBuffer) == 0) && S_ISREG (statBuffer.st_mode))
             {


--=-8YaBSNw9Rk4NELY2zaiE
Content-Disposition: attachment; filename="gcc45-libgnat-implib.patch"
Content-Type: text/x-patch; name="gcc45-libgnat-implib.patch"; charset="UTF-8"
Content-Transfer-Encoding: 7bit

--- origsrc/gcc-4.5.1/gcc/ada/gcc-interface/Makefile.in	2010-08-15 23:57:49.606350800 -0500
+++ src/gcc-4.5.1/gcc/ada/gcc-interface/Makefile.in	2010-08-16 13:50:46.168752400 -0500
@@ -2434,10 +2444,8 @@
 	   if [ -f $(RTSDIR)/$(LIBGNAT_SHARED_LIB_PREFIX)$${file}$(hyphen)$(LIBRARY_VERSION)$(soext) ]; then \
 	      $(INSTALL) $(RTSDIR)/$(LIBGNAT_SHARED_LIB_PREFIX)$${file}$(hyphen)$(LIBRARY_VERSION)$(soext) \
 			 $(DESTDIR)$(bindir); \
-	   fi; \
-	   if [ -f $(RTSDIR)/$(LIBGNAT_SHARED_LIB_PREFIX)$${file}$(soext) ]; then \
-	      $(LN_S) $(bindir)$${file}$(hyphen)$(LIBRARY_VERSION)$(soext) \
-	      $(DESTDIR)$(ADA_RTL_OBJ_DIR)/lib$${file}$(soext); \
+	      $(LN_S) $(bindir)/$(LIBGNAT_SHARED_LIB_PREFIX)$${file}$(hyphen)$(LIBRARY_VERSION)$(soext) \
+	      $(DESTDIR)$(ADA_RTL_OBJ_DIR)/lib$${file}$(hyphen)$(LIBRARY_VERSION).dll.a; \
 	   fi; \
 	done
 # This copy must be done preserving the date on the original file.

--=-8YaBSNw9Rk4NELY2zaiE
Content-Disposition: attachment; filename="hello.adb"
Content-Type: text/x-adasrc; name="hello.adb"; charset="UTF-8"
Content-Transfer-Encoding: 7bit

with Ada.Text_IO;
 
procedure Hello is
begin
   Ada.Text_IO.Put_Line ("Hello, world!");
end Hello;


--=-8YaBSNw9Rk4NELY2zaiE
Content-Type: text/plain; charset=us-ascii

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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019