From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27409 invoked by alias); 22 Oct 2009 18:26:14 -0000 Received: (qmail 27399 invoked by uid 22791); 22 Oct 2009 18:26:13 -0000 X-SWARE-Spam-Status: No, hits=-1.3 required=5.0 tests=AWL,BAYES_50,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail-pz0-f203.google.com (HELO mail-pz0-f203.google.com) (209.85.222.203) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 22 Oct 2009 18:26:09 +0000 Received: by pzk41 with SMTP id 41so6394633pzk.0 for ; Thu, 22 Oct 2009 11:26:07 -0700 (PDT) Received: by 10.114.163.26 with SMTP id l26mr14790725wae.173.1256235967875; Thu, 22 Oct 2009 11:26:07 -0700 (PDT) Received: from Paullaptop (203-214-142-52.perm.iinet.net.au [203.214.142.52]) by mx.google.com with ESMTPS id 20sm412511pxi.15.2009.10.22.11.26.05 (version=SSLv3 cipher=RC4-MD5); Thu, 22 Oct 2009 11:26:07 -0700 (PDT) Message-ID: <85E0DD6F65614AB7B95B6B6768D8FD80@Paullaptop> From: "Paul Edwards" To: "Ulrich Weigand" Cc: "Ulrich Weigand" , References: <200910221803.n9MI33he012461@d12av02.megacenter.de.ibm.com> In-Reply-To: <200910221803.n9MI33he012461@d12av02.megacenter.de.ibm.com> Subject: Re: i370 port - constructing compile script Date: Thu, 22 Oct 2009 22:04:00 -0000 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="Windows-1252"; reply-type=original Content-Transfer-Encoding: 7bit Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2009-10/txt/msg00454.txt.bz2 Hi Ulrich. I'll try out some of those things. I have some initial comments. > Hmmm, the access() use probably needs to be guarded by a configure > check. Or else you might provide a MVS-specific implementation of > "access" (if that is possible), and compile it into libiberty by > providing an EXTRA_OFILES setting in a host makefile fragment; Probably too many of them. Just like open() etc in GCC main. I'll see what can be faked up, now that I know those object files are basically mandatory. > in 3.4 these are set in config.table: > case "${host}" in > rs6000-ibm-aix3.1 | rs6000-ibm-aix) > frag=mh-aix ;; > *-*-cxux7*) frag=mh-cxux7 ;; > *-*-freebsd2.1.*) frag=mh-fbsd21 ;; > *-*-freebsd2.2.[012]) frag=mh-fbsd21 ;; > i370-*-opened*) frag=mh-openedition ;; > i[34567]86-*-windows*) frag=mh-windows ;; > esac > > As to the pex-unix.c, you certainly should provide a MVS-specific > version of the PEX callbacks. They are selected in configure.ac: > > # Figure out which version of pexecute to use. > case "${host}" in > *-*-mingw* | *-*-winnt*) pexecute=pex-win32.o ;; > *-*-msdosdjgpp*) pexecute=pex-djgpp.o ;; > *-*-msdos*) pexecute=pex-msdos.o ;; > *-*-os2-emx*) pexecute=pex-os2.o ;; > *) pexecute=pex-unix.o ;; > esac Ok, thanks. > Your MVS version might be just a dummy that always fails. Ok. > Even better would be a version that actually works; in this > case all the "single-exectuable" hacks would become superfluous. Having a single executable, especially in my environment where only assembler code is ever generated, has its own merits even if a working system() can be done in the future. > Note that e.g. pex-msdos.c implements the required callbacks > solely in terms of the C99 "system" routine. If you at least > have this facility available on MVS, you might be able to just > use the msdos version? I don't have a working system that can execute another C program yet. Note that C90 leaves the behaviour of system() as "implementation defined". Well, on my system, I can do a system() to call some simple programs that clear the screen. In one environment on my system, anyway. :-) >> Finally, even with this in place, the build process stopped at >> the next roadblock. The file "genmodes.c" couldn't be >> compiled. I was surprised to see that it was being compiled >> with i370-mvspdp-gcc. The genmodes "needs" to be run on >> Unix still. It's only the source code that IT generates that >> needs to be cross-compiled. > > If this happens, then something went very wrong during configure. > Did you make sure to use the proper build / host / target flags? > In particular, the --build= configure argument must be present > and refer to the build architecture. This is used to determine > which architecture to build the generator programs for. Yes, I have all 3 specified, with --build of i686-linux. Now that I know that the generator files are meant to be built with the i686 gcc, I'll try to find out where it's picking that up from. BFN. Paul.