On 24 Aug 2010, at 17:47, Morton, John wrote:
However when I compile the simplest possible "hello world" on RHEL 5.4 (a fedora variant) I always get the following assembler errors:
Error: suffix or operands invalid for "push" Error: suffix or operands invalid for "pop"
Does anyone know what is causing these errors - and/or a fix for them?
This means that GPC is generating 32 bit code, but that it is being assembled as 32 bit code. Try passing the "-m32" parameter to gp/gpc, and if that does not work, try -Wa,-m32. Note that you may have to install 32 bit versions of all dev packages (including libc-dev) that you need, unless those are installed by default.
Background:
The development system does NOT have gcc installed (since gcc cannot be installed on the machines that will be running our application).
I don't understand this condition. They presumably won't have GPC installed either, but only your application. Why does it matter what is installed on the machine that compiles the application?
On the dev system I installed the 2002 gpc BINARY (the "gpc-2.1-with-gcc.i686-pc-linux-gnu.tar.gz" file) from the gnu-pascal.de/binary/ web page. I also tried the 20070904 Linux binary downloaded from brandeis.edu and got exactly the same results.
Both downloads are i686 versions. Will these versions work on x68_64 Linux variants?
Yes, x86-64 Linux systems in general (and RHEL in particular) can perfectly run 32 bit applications.
Jonas