From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Mike Gran Newsgroups: gmane.lisp.guile.devel,gmane.lisp.guile.bugs Subject: Re: Guile with win32 cross compiling Date: Tue, 5 Apr 2011 12:43:44 -0700 (PDT) Message-ID: <628216.88114.qm@web37906.mail.mud.yahoo.com> Reply-To: Mike Gran NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1302033480 4872 80.91.229.12 (5 Apr 2011 19:58:00 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 5 Apr 2011 19:58:00 +0000 (UTC) Cc: "bug-guile@gnu.org" , "guile-devel@gnu.org" To: Volker Grabsch , Andy Wingo Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Tue Apr 05 21:57:54 2011 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Q7CNu-00068s-5g for guile-devel@m.gmane.org; Tue, 05 Apr 2011 21:57:54 +0200 Original-Received: from localhost ([127.0.0.1]:35539 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q7CAT-0008OI-8c for guile-devel@m.gmane.org; Tue, 05 Apr 2011 15:44:01 -0400 Original-Received: from [140.186.70.92] (port=35988 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q7CAF-0008MY-VX for guile-devel@gnu.org; Tue, 05 Apr 2011 15:43:49 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q7CAE-000072-LY for guile-devel@gnu.org; Tue, 05 Apr 2011 15:43:47 -0400 Original-Received: from web37906.mail.mud.yahoo.com ([209.191.91.168]:32537) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1Q7CAE-00006s-Cn for guile-devel@gnu.org; Tue, 05 Apr 2011 15:43:46 -0400 Original-Received: (qmail 88891 invoked by uid 60001); 5 Apr 2011 19:43:44 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1302032624; bh=VV2D4eFw+sreuc1Y/Vlki76AFUoR1D40LH07ngAaKa4=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Reply-To:Subject:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding; b=CsNF+Q5GYWkkfjfeGOSojCxvsSL69b1oYc38LYcZMtgcxq81M5yG7wLJPUUmGkinG6pD2rscfpF9/7sSf3Cx4uwXn1Liu2HkP6CM5w0yIJaV/noMwCR/aRUhayVLUoLtwriNMv/JtW6KdDu7Fwk1A2wkIs73dr4sUhtuIehIM0s= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Reply-To:Subject:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding; b=VslysCBjYLpUjOGkO3IxGt4pAWBfm+G9/L0+iqf+HEXvWsWJ2toYgoefyhOsISVnmL2q/LbJLAol8KwUav0Iv9mY6ey52IIg9Xc0bkznuQI4EBHf4fORi54+k72nxgR8f+jfpxROyHuK2CyJ6ZR26797lCIz2O2cPG7fzoW8eLQ=; X-YMail-OSG: Os5xP7EVM1lC4t61TKtTU60eA7Vxp75YB_mwBgdRBEeGPRY P.GrEURd2u_dHPnrh1xeY._E7ebpTEeQXPGT.Jjh2QNrE2EbxMyMmHWmmptm 7FAK3Edk.haWip0Aus9v2E9LTGdkaTZ17hpW_7qymtFg8BFhC3FFEPlw8jFw WdZR22lM8Jyc1zIc3TCWXHNid3N57fR5yVmPNJ7xGmxuB39w3uEryXLc9ZD. 0dlmeQx3IpDt12J7SevcTpPDluP09uG1zczQ8Fi6MLNZQjyOCOfAy7IrmmZ8 iyQ3e5SBhmwOFb13Vr7qbdru3zh8j30x1bDkGB8ObWoXlzZHurK_33Hqxoau 7n6qoo7AYHOsci1v3QEh48PH6wAwBeNECYfMvMLhRszb4SncI0CJVc.DDUCr uvhrPw76rrMgsIsI- Original-Received: from [71.130.210.132] by web37906.mail.mud.yahoo.com via HTTP; Tue, 05 Apr 2011 12:43:44 PDT X-Mailer: YahooMailWebService/0.8.109.295617 X-detected-operating-system: by eggs.gnu.org: FreeBSD 6.x (1) X-Received-From: 209.191.91.168 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:12165 gmane.lisp.guile.bugs:5428 Archived-At: > =A0 =A0 "Portability fixes for win32 cross compiling"=0A> =A0 =A0 http://= www.mail-archive.com/guile-devel@gnu.org/msg05308.html=0A> =0A> > In any ca= se, I don't understand the mechanism here, but I believe the=0A> > point wa= s to make it so that #include would not pull in=0A> > iconv he= aders.=A0 gen-scmconfig looks up the value of the constants for=0A> > iconv= conversion handlers, and writes them into scmconfig.h.=A0 Your patch=0A> >= undoes that.=0A> > =0A> > What problem are you working around here?=0A> = =0A> The problem is that this mechanism works completely against the=0A> na= ture of cross compiling.=0A> =0A> The issue exists in all attempts to cross= compile guile, but they=0A> become extreme when cross compiling on a Unix = system for MinGW,=0A> as those systems are very different.=0A> =0A> Gen-scm= config is a code generator, so it has to be built using=0A> the native tool= chain. However, it is supposed to write take its=0A> values from the of the cross tool chain. Thus, the=0A> "/usr/include" equivalent of t= he cross tool chain is added to=0A> the include path when compiling gen-scm= config. And here the=0A> trouble starts, because mixing headers of various = toolchains=0A> is never a good idea. Among others, basic headers like =0A> are now taken from the cross toolchain, referring to objects that= =0A> don't even exist in the native toolchain, causing the build to=0A> fai= l with all kinds of strange error messages.=0A=0AThere was a recent=A0discu= ssion about these sorts of builds at=0Ahttp://lists.gnu.org/archive/html/au= tomake/2011-04/msg00014.html=0A=A0=0A> =0A> > > The other open issue is als= o a known one: the missing mmap()=0A> > > function under Windows. After som= e research, I found a promising=0A> > > mmap()/munmap() implementation for = Windows in a free software=0A> > > project:=0A> > >=0A> > > http://code.goo= gle.com/p/flvmeta/source/browse/trunk/src/mmap.h?r=3D74=0A> > > http://code= .google.com/p/flvmeta/source/browse/trunk/src/mmap.c?r=3D74=0A> > >=0A> > >= Maybe this is worth integrating into guile?=0A> > =0A> > You know, not onl= y do we not rely on MAP_SHARED -- I switched it to use=0A> > PRIVATE, just = now -- we didn't actually need mmap at all.=A0 I just=0A> > changed it to u= se read(2) if mmap is not available, and it seems to work=0A> > fine, just = a little (5-10%) slower to start up.=A0 That should help our=0A> > unfortun= ate friends working on Windows :)=0A> =0A> That's good news. Maybe this wil= l enable me to include the next guile=0A> release in mingw-cross-env - a pr= oject dedicated to all those unfortunate=0A> friends. :-)=A0 Using mingw-cr= oss-env and Wine, they at least don't have=0A> to actually run Windows just= to build and test their project's Windows=0A> port. ;-)=0A> =0A> =0A> Gree= ts,=0A> Volker=0A> =0A> -- =0A> Volker Grabsch=0A> ---<<(())>>---=0A