delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1999/12/07/17:05:25

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
X-Lotus-FromDomain: DSSI
From: "Tom Williams" <tom DOT williams AT diversifiedsoftware DOT com>
To: cygwin AT sourceware DOT cygnus DOT com
Message-ID: <88256840.007362B5.00@notesgw1.dssi-jcl.com>
Date: Tue, 7 Dec 1999 13:00:56 -0800
Subject: Re: problems compiling dev-src (Cygwin B20.1) on Linux
Mime-Version: 1.0

Here is the patch:

--- arscan.c-orig   Fri Nov  1 14:08:25 1996
+++ arscan.c   Mon Dec  6 19:12:46 1999
@@ -434,14 +434,21 @@ ar_name_equal (name, mem, truncated)
       abort ();
 #else
       struct ar_hdr hdr;
-      return !strncmp (name, mem,
-                sizeof (hdr.ar_name) -
+
+      /* Changed code to determine the truncated amount to remove
+         the #ifdef code that was in the middle of the call to strncmp
+         to fix a gcc-2.95.2 on Linux 2.2.13 compile problem.
+         Code changed by Tom Williams on 12/6/99
+         e-mail: tomdkat AT home DOT com
+       */
+      int amount = 0;
 #if !defined (__hpux) && !defined (cray)
-                1
+       amount = 1;
 #else
-                2
-#endif /* !__hpux && !cray */
-                );
+       amount = 2;
+#endif /* !__hupx && !cray */
+       return !strncmp (name, mem,
+                sizeof (hdr.ar_name) - amount);
 #endif
     }

Peace......

Tom




Chris Faylor <cgf AT cygnus DOT com> on 12/06/99 01:47:03 PM

Please respond to cygwin AT sourceware DOT cygnus DOT com

To:   Tom Williams/HQ/dssi, cygwin AT sourceware DOT cygnus DOT com
cc:
Subject:  Re: problems compiling dev-src (Cygwin B20.1) on Linux




On Mon, Dec 06, 1999 at 01:10:31PM -0500, Chris Faylor wrote:
>On Sun, Dec 05, 1999 at 06:11:26PM -0800, Tom Williams wrote:
>>Hi!  I was trying to build Cygwin B20.1 from source (dev-src) on Linux
>>(2.2.13 kernel w/ glibc-2.1.2) in an attempt to build a Linux hosted,
Win32
>>targetted cross compiler based on gcc-2.95.2.
>>
>>I found the file arscan.c would not compile due to some #ifdef coding for
>>portability in a certain function.
>>
>>How should I send in the "patch" I made to get it to properly compile?
>
>Send the patch to the mailing list.
>
>I assume that it is small enough that it won't bother anyone.
I'm sorry.  This is not a patch.  Peruse past mailing list articles for
information on generating patches.  Hint:  You use diff.
cgf







--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


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