delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2008/03/12/10:13:02

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Message-ID: <47D7F2DA.D3785152@dessent.net>
Date: Wed, 12 Mar 2008 08:12:26 -0700
From: Brian Dessent <brian AT dessent DOT net>
X-Mailer: Mozilla 4.79 [en] (Windows NT 5.0; U)
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: Rebuilding gnu gcc or gnu as for the SPARC assembler
References: <fd92d14b0803120154g42c65dbel3dde13146ef13bf1 AT mail DOT gmail DOT com>
X-IsSubscribed: yes
Reply-To: cygwin AT cygwin DOT com
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

IB wrote:

> So my questions are:
> (1) Do I just change some options at the command-line to compile my
> assembly file (written in SPARC)? If so, in gcc or via as and how do I
> do this? I've tried:
> $ as -Av6 printHello.s
> as: unrecognized option '-Av6'

While gcc and binutils do support many dozens of target platforms, they
only support one specific target configuration at any time[1].  The gcc
and binutils that Cygwin provides are native tools -- they target Cygwin
and can make Cygwin binaries only[2].  To do what you're trying to do
you need to build a cross tool chain (cross-assembler, cross-linker,
cross-compiler, etc.)  That is certainly possible with Cygwin but it's
not something that is provided by default so you have to build it
yourself.  The gcc and binutils manuals are monolithic in that they
documents all supported targets and options from one document so
anything but the options in the i386 section will be irrelevant unless
you build a cross compiler.

Brian

[1] Technically through the multilib facility this definition of one
target can be stretched somewhat, but even with multilibs you are still
limited to one backend.

[2] Technically it can also make MinGW binaries with the -mno-cygwin
switch, but that's implemented by simply searching a different set of
target libraries and setting various options in the specs file, a
variation on the multilib concept.  It's still the same common i386 PE
backend in both cases however.

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

- Raw text -


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