* RE: Preprocessing Assembly
@ 2002-09-12 9:08 Bruce Adams
0 siblings, 0 replies; 6+ messages in thread
From: Bruce Adams @ 2002-09-12 9:08 UTC (permalink / raw)
To: cygwin, crossgcc
> -----Original Message-----
> From: Dhananjay R. Deshpande [mailto:dhananjayd@kpit.com]
> Sent: Thursday, September 12, 2002 3:03 PM
> To: Dhananjay R. Deshpande; Bruce Adams; cygwin@cygwin.com;
> crossgcc@sources.redhat.com
> Subject: RE: Preprocessing Assembly
>
> > > Is there a way to force gcc to preprocess assembly using a switch.
> >
> > Yes. Use "-x assembler-with-cop" switch.
>
> Typo.. Use "-x assembler-with-cpp" switch.
Ah ok. Missed that one when I RTFM. You don't need the space though. One
teensy flaw.
The prebuilt rtems compiler I'm using (being stuck unable to build my own
for now) can't find cpp0. I copied that into C:\cygwin\opt\rtems\bin from
C:\cygwin\opt\rtems\lib\gcc-lib\m68k-rtems\2.95.3 and it works. However, I
now have syntax errors in my assembly but the line numbers refer to the
preprocessed output rather than the original file.
Closer inspection of my workaround to use gcc -E reveals something more
insidious and slightly
surprising. Gcc -E produces no output at all. This seems to go for both
the cygwin native gcc and
the rtems one. If I run cpp0.exe directly I get output. Neither cpp or gcc
put anything on stdout.
I know the preprocessor works (people would have noticed if it didn't!) so
what am I Missing?
Regards,
Bruce A.
============================================================================
Any opinions expressed in this e-mail are those of the individual and not
necessarily those of Tyco Electronic Product Group.
Any prices for the supply of goods or services are only valid if supported
by a formal written quotation.
This e-mail and any files transmitted with it, including replies and
forwarded copies (which may contain alterations) subsequently transmitted
from Tyco Electronic Product Group are confidential and solely for the use
of the intended recipient.
If you are not the intended recipient or the person responsible for
delivery to the intended recipient, be advised that you have received this
e-mail in error and that any use is strictly prohibited. In this event,
please notify us via e-mail at 'helpdesk.tepg@tycoint.com' or telephone on
0121 255 6499 and then delete the e-mail and any copies of it.
============================================================================
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: Preprocessing Assembly
@ 2002-09-13 7:36 Bruce Adams
0 siblings, 0 replies; 6+ messages in thread
From: Bruce Adams @ 2002-09-13 7:36 UTC (permalink / raw)
To: cygwin, crossgcc
> -----Original Message-----
> From: Bruce Adams [mailto:bruadams@tycoint.com]
> Sent: Thursday, September 12, 2002 4:39 PM
> To: cygwin@cygwin.com; crossgcc@sources.redhat.com
> Subject: RE: Preprocessing Assembly
>
>
>
>
> > -----Original Message-----
> > From: Dhananjay R. Deshpande [mailto:dhananjayd@kpit.com]
> > Sent: Thursday, September 12, 2002 3:03 PM
> > To: Dhananjay R. Deshpande; Bruce Adams; cygwin@cygwin.com;
> > crossgcc@sources.redhat.com
> > Subject: RE: Preprocessing Assembly
> >
> > > > Is there a way to force gcc to preprocess assembly
> using a switch.
> > >
> > > Yes. Use "-x assembler-with-cop" switch.
> >
> > Typo.. Use "-x assembler-with-cpp" switch.
>
> Ah ok. Missed that one when I RTFM. You don't need the
> space though. One teensy flaw.
> The prebuilt rtems compiler I'm using (being stuck unable to
> build my own for now) can't find cpp0. I copied that into
> C:\cygwin\opt\rtems\bin from
> C:\cygwin\opt\rtems\lib\gcc-lib\m68k-rtems\2.95.3 and it
> works. However, I now have syntax errors in my assembly but
> the line numbers refer to the preprocessed output rather than
> the original file. Closer inspection of my workaround to use
> gcc -E reveals something more insidious and slightly
> surprising. Gcc -E produces no output at all. This seems to
> go for both the cygwin native gcc and the rtems one. If I
> run cpp0.exe directly I get output. Neither cpp or gcc put
> anything on stdout. I know the preprocessor works (people
> would have noticed if it didn't!) so
> what am I Missing?
> Regards,
> Bruce A.
>
Okay. I have obtained part of the answer through RTFMing and
Experimentation.
Apparently gcc -E doesn't work unless I also use -x assembly-with-cpp
or equally -x c++.
My initial syntax errors were caused by the line directives output by
the preprocessor. Gcc chokes itself. If I disable those using -Wp,-P
then I at least get syntax errors relating to our assembly code, though
the line numbers only make sense if use a two stage process and investigate
the intermediate file.
Another thing it seems to dislike is the use of 0x to signify hexadecimal in
constants. I was all set to change to the alternate notation of an H at the
end when the manual (www.delorie.com/gnu/docs/binutils/as_36.html)
told me this was legal. What else am I missing? :-)
Regards,
Bruce A.
============================================================================
Any opinions expressed in this e-mail are those of the individual and not
necessarily those of Tyco Electronic Product Group.
Any prices for the supply of goods or services are only valid if supported
by a formal written quotation.
This e-mail and any files transmitted with it, including replies and
forwarded copies (which may contain alterations) subsequently transmitted
from Tyco Electronic Product Group are confidential and solely for the use
of the intended recipient.
If you are not the intended recipient or the person responsible for
delivery to the intended recipient, be advised that you have received this
e-mail in error and that any use is strictly prohibited. In this event,
please notify us via e-mail at 'helpdesk.tepg@tycoint.com' or telephone on
0121 255 6499 and then delete the e-mail and any copies of it.
============================================================================
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: Preprocessing Assembly
@ 2002-09-12 7:12 Dhananjay R. Deshpande
0 siblings, 0 replies; 6+ messages in thread
From: Dhananjay R. Deshpande @ 2002-09-12 7:12 UTC (permalink / raw)
To: Dhananjay R. Deshpande, Bruce Adams, cygwin, crossgcc
> -----Original Message-----
> From: Dhananjay R. Deshpande
> Sent: Thursday, September 12, 2002 7:29 PM
> To: Bruce Adams; cygwin@cygwin.com; crossgcc@sources.redhat.com
> Subject: RE: Preprocessing Assembly
>
>
> Hi,
>
>
> > -----Original Message-----
> > From: Bruce Adams [mailto:bruadams@tycoint.com]
> > Sent: Thursday, September 12, 2002 6:40 PM
> > To: cygwin@cygwin.com; crossgcc@sources.redhat.com
> > Subject: Preprocessing Assembly
> >
> >
> >
> > Hi,
> > I am using gcc to cross compile for m68k. I discovered
> > the following on
> >
> > the net.
> >
> > "Both .S and .s are assembler. By convention, .S is assembly
> > source that
> > needs to be preprocessed. Otherwise, gcc doesn't care."
> >
> > This is of course less than optimal on windows as the
> > file system is not case
> > sensitive. The work around is of course to invoke gcc -E
> 'manually'.
> Windows file system is case sensitive. You can have .S
> extension. May be you will have to use explorer to rename .s
> file to .S
> > Is there a way to force gcc to preprocess assembly using a switch.
>
> Yes. Use "-x assembler-with-cop" switch.
Typo.. Use "-x assembler-with-cpp" switch.
>
> Regards,
> Dhananjay
>
> > e.g. --preprocess-assembly?
> >
> > Regards,
> > Bruce A.
> >
> >
> > ==============================================================
> > ==============
> > Any opinions expressed in this e-mail are those of the
> > individual and not
> > necessarily those of Tyco Electronic Product Group.
> >
> > Any prices for the supply of goods or services are only
> > valid if supported
> > by a formal written quotation.
> >
> > This e-mail and any files transmitted with it, including
> replies and
> > forwarded copies (which may contain alterations)
> > subsequently transmitted
> > from Tyco Electronic Product Group are confidential and
> > solely for the use
> > of the intended recipient.
> >
> > If you are not the intended recipient or the person responsible for
> > delivery to the intended recipient, be advised that you have
> > received this
> > e-mail in error and that any use is strictly prohibited. In
> > this event,
> > please notify us via e-mail at 'helpdesk.tepg@tycoint.com'
> > or telephone on
> > 0121 255 6499 and then delete the e-mail and any copies of it.
> > ==============================================================
> > ==============
> >
> >
> >
> >
> >
> >
> > ------
> > Want more information? See the CrossGCC FAQ,
> > http://www.objsw.com/CrossGCC/
> > Want to unsubscribe? Send a note to
> > crossgcc-unsubscribe@sources.redhat.com
> >
> >
>
> ------
> Want more information? See the CrossGCC FAQ,
> http://www.objsw.com/CrossGCC/
> Want to unsubscribe? Send a note to
> crossgcc-unsubscribe@sources.redhat.com
>
>
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: Preprocessing Assembly
@ 2002-09-12 7:08 Dhananjay R. Deshpande
0 siblings, 0 replies; 6+ messages in thread
From: Dhananjay R. Deshpande @ 2002-09-12 7:08 UTC (permalink / raw)
To: Bruce Adams, cygwin, crossgcc
Hi,
> -----Original Message-----
> From: Bruce Adams [mailto:bruadams@tycoint.com]
> Sent: Thursday, September 12, 2002 6:40 PM
> To: cygwin@cygwin.com; crossgcc@sources.redhat.com
> Subject: Preprocessing Assembly
>
>
>
> Hi,
> I am using gcc to cross compile for m68k. I discovered
> the following on
>
> the net.
>
> "Both .S and .s are assembler. By convention, .S is assembly
> source that
> needs to be preprocessed. Otherwise, gcc doesn't care."
>
> This is of course less than optimal on windows as the
> file system is not case
> sensitive. The work around is of course to invoke gcc -E 'manually'.
Windows file system is case sensitive. You can have .S extension. May be you will have to use explorer to rename .s file to .S
> Is there a way to force gcc to preprocess assembly using a switch.
Yes. Use "-x assembler-with-cop" switch.
Regards,
Dhananjay
> e.g. --preprocess-assembly?
>
> Regards,
> Bruce A.
>
>
> ==============================================================
> ==============
> Any opinions expressed in this e-mail are those of the
> individual and not
> necessarily those of Tyco Electronic Product Group.
>
> Any prices for the supply of goods or services are only
> valid if supported
> by a formal written quotation.
>
> This e-mail and any files transmitted with it, including replies and
> forwarded copies (which may contain alterations)
> subsequently transmitted
> from Tyco Electronic Product Group are confidential and
> solely for the use
> of the intended recipient.
>
> If you are not the intended recipient or the person responsible for
> delivery to the intended recipient, be advised that you have
> received this
> e-mail in error and that any use is strictly prohibited. In
> this event,
> please notify us via e-mail at 'helpdesk.tepg@tycoint.com'
> or telephone on
> 0121 255 6499 and then delete the e-mail and any copies of it.
> ==============================================================
> ==============
>
>
>
>
>
>
> ------
> Want more information? See the CrossGCC FAQ,
> http://www.objsw.com/CrossGCC/
> Want to unsubscribe? Send a note to
> crossgcc-unsubscribe@sources.redhat.com
>
>
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
^ permalink raw reply [flat|nested] 6+ messages in thread
* Preprocessing Assembly
@ 2002-09-12 6:58 Bruce Adams
2002-09-12 8:48 ` Dan Kegel
0 siblings, 1 reply; 6+ messages in thread
From: Bruce Adams @ 2002-09-12 6:58 UTC (permalink / raw)
To: cygwin, crossgcc
Hi,
I am using gcc to cross compile for m68k. I discovered the following on
the net.
"Both .S and .s are assembler. By convention, .S is assembly source that
needs to be preprocessed. Otherwise, gcc doesn't care."
This is of course less than optimal on windows as the filesystem is not case
sensitive. The work around is of course to invoke gcc -E 'manually'.
Is there a way to force gcc to preprocess assembly using a switch.
e.g. --preprocess-assembly?
Regards,
Bruce A.
============================================================================
Any opinions expressed in this e-mail are those of the individual and not
necessarily those of Tyco Electronic Product Group.
Any prices for the supply of goods or services are only valid if supported
by a formal written quotation.
This e-mail and any files transmitted with it, including replies and
forwarded copies (which may contain alterations) subsequently transmitted
from Tyco Electronic Product Group are confidential and solely for the use
of the intended recipient.
If you are not the intended recipient or the person responsible for
delivery to the intended recipient, be advised that you have received this
e-mail in error and that any use is strictly prohibited. In this event,
please notify us via e-mail at 'helpdesk.tepg@tycoint.com' or telephone on
0121 255 6499 and then delete the e-mail and any copies of it.
============================================================================
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2002-09-13 14:02 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-12 9:08 Preprocessing Assembly Bruce Adams
-- strict thread matches above, loose matches on Subject: below --
2002-09-13 7:36 Bruce Adams
2002-09-12 7:12 Dhananjay R. Deshpande
2002-09-12 7:08 Dhananjay R. Deshpande
2002-09-12 6:58 Bruce Adams
2002-09-12 8:48 ` Dan Kegel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).