https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89542
Bug ID: 89542
Summary: Error reported on incorrect line number when using GCC
to compile .S files using #include
Product: gcc
Version: 4.2.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: preprocessor
Assignee: unassigned at gcc dot gnu.org
Reporter: puffydaemon at gmail dot com
Target Milestone: ---
Hi!
I am coding a bootloader for my own operating system, and the way I am
compiling the bootloader seems to be something tricky to GAS because it reports
a line far away from the original... I am using comments with # instead of //
or /**/ because it works and I prefer (maybe this is the problem).
The URL of the project is
https://github.com/hombrelogico/MyOwnOperatingSystem/tree/master/bootloader
Please, clone and run make to see more deeply if you need, but basically I am
on OpenBSD, the GCC version is specified before, and it says that asm
instruction on line XX is wrong, but on that line there's not for example a
`mov' instruction, as it reports...
Sorry because I can't expose better my error, I've read the bug reporting
rules, but can't report better...
I know I am using GCC to compile what I would be able with GAS, but as I need
to build a self-relocated binary, I prefer to pass by the CPP to remove
comments and build a big one file.
But seems that, it is generated bad after the CPP and/or when passed to GAS...
Thanks in advance, have a nice day.