From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andy Wingo Newsgroups: gmane.lisp.guile.devel Subject: Re: MinGW-related patches that were reported in 2014 but not applied Date: Sat, 16 Jul 2016 15:39:23 +0200 Message-ID: <87twfpvh10.fsf@pobox.com> References: <8337na7mfp.fsf@gnu.org> <87inw6x9qj.fsf@pobox.com> <83h9bp6d1i.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1468676398 32460 80.91.229.3 (16 Jul 2016 13:39:58 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 16 Jul 2016 13:39:58 +0000 (UTC) Cc: guile-devel@gnu.org To: Eli Zaretskii Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Sat Jul 16 15:39:50 2016 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1bOPoq-0001eM-GM for guile-devel@m.gmane.org; Sat, 16 Jul 2016 15:39:48 +0200 Original-Received: from localhost ([::1]:37511 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bOPop-0001ts-Iy for guile-devel@m.gmane.org; Sat, 16 Jul 2016 09:39:47 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40908) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bOPok-0001sq-4f for guile-devel@gnu.org; Sat, 16 Jul 2016 09:39:43 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bOPoi-0002Cb-UE for guile-devel@gnu.org; Sat, 16 Jul 2016 09:39:41 -0400 Original-Received: from pb-sasl2.pobox.com ([64.147.108.67]:52456 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bOPoc-0002AZ-Cr; Sat, 16 Jul 2016 09:39:34 -0400 Original-Received: from sasl.smtp.pobox.com (unknown [127.0.0.1]) by pb-sasl2.pobox.com (Postfix) with ESMTP id 2AC782BCC6; Sat, 16 Jul 2016 09:39:31 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=sasl; bh=uTcj0NzPc0Awgu07QRKJXbScb6Q=; b=DV+JUz h99Xa4LIHie8eVNNBwoHUZV79SCZpiupox6lOgXjU6BjGen2uArHR1P9MdSSSO6c TsDYty3RwcO3woYNSO+F0nQiuGDkx7FY4ZXedd8+F9I2wFb0FuxAHgct12/7S8l4 4L5DSUO96HdpUwbzcrzIKW97b2LiZbus4gqYc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=pobox.com; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; q=dns; s=sasl; b=I8uBhzH04khvoDstQGS6q5I+g1p8aFG0 RRuRA5TEQEgsbS//7z4OHh7NfwcJUFDE3uClEnuVQQXZzdVar/ySQPBHoDSUaNd/ uyEe08opSaEv6o0fv47eYX2lWGlfLBa7O+PXpHGFREVbhVQs8P46r2lBFqRZ70+C 5J112rYugU0= Original-Received: from pb-sasl2.nyi.icgroup.com (unknown [127.0.0.1]) by pb-sasl2.pobox.com (Postfix) with ESMTP id 1E0AD2BCC5; Sat, 16 Jul 2016 09:39:31 -0400 (EDT) Original-Received: from clucks (unknown [88.160.190.192]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by pb-sasl2.pobox.com (Postfix) with ESMTPSA id 38B2D2BCC4; Sat, 16 Jul 2016 09:39:30 -0400 (EDT) In-Reply-To: <83h9bp6d1i.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 16 Jul 2016 14:24:41 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) X-Pobox-Relay-ID: B90DD1CA-4B5A-11E6-B205-28A6F1301B6D-02397024!pb-sasl2.pobox.com X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 64.147.108.67 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: "guile-devel" Xref: news.gmane.org gmane.lisp.guile.devel:18544 Archived-At: On Sat 16 Jul 2016 13:24, Eli Zaretskii writes: > diff --git a/libguile/filesys.c b/libguile/filesys.c > index 48232e8..c47c2f4 100644 > --- a/libguile/filesys.c > +++ b/libguile/filesys.c > @@ -1472,6 +1472,14 @@ SCM_DEFINE (scm_mkstemp, "mkstemp!", 1, 0, 0, > SCM_SYSCALL (rv = mkstemp (c_tmpl)); > if (rv == -1) > SCM_SYSERROR; > +#ifdef __MINGW32__ > + /* Files created by this function are used for *.go files, so make > + sure they use binary I/O, or else the produced *.go files will be > + corrupted by end-of-line conversion and ^Z "software EOF" > + misfeature. Gnulib's 'mkstemp' uses the default text mode to > + open the file . */ > + _setmode (rv, _O_BINARY); > +#endif This function is used for other purposes as well. I think the right thing here is to use the mkostemp gnulib module instead and pass O_BINARY in the flags. I have made this change in git; please let me know if it causes problems for you. Andy