[fpc-pascal] Bootstrapping FPC for x86_64

Graeme Geldenhuys graemeg.lists at gmail.com
Mon Nov 24 11:04:32 CET 2008


Hi,

I setup a new 64bit server in our company, running Ubuntu 8.04 LTS
(64bit). I want to us it as a 64bit testbed for our applications. So I
want to compile 64bit version of our software.

I installed all the usual compiler requirements: binutils etc...

I copied FPC 2.2.3 (latest svn revision) from my local 32bit system to
the 64bit server. I made sure my ~/.fpc.cfg file is correct. I then
ran the following script which I use for all my FPC versions on my
local machine.

---------------[ startbuild.sh ]----------------
make clean
make install INSTALL_PREFIX=/home/graemeg/programming/fpc_2.2.3
----------------[ end ]--------------------

My directory layouts are as follows
/home/graemeg/programming/fpc_2.2.3
                                                             /src
     <--- svn checkout
                                                             /bin
                                                             /lib
                                                             /.......

My fpc.cfg file reflects the compiler version number in the unit
search paths. When I try and recompile the compiler, I get the
following error.


make[3]: Entering directory
`/home/graemeg/programming/fpc_2.2.3/src/utils/fpdoc'
/home/graemeg/programming/fpc_2.2.3/src/compiler/ppc386 -Ur -Xs -O2 -n
-S2h -Fu/home/graemeg/programming/fpc_2.2.3/src/rtl/units/i386-linux
-Fu/home/graemeg/programming/fpc_2.2.3/src/packages/fcl-base/units/i386-linux
-Fu/home/graemeg/programming/fpc_2.2.3/src/packages/fcl-xml/units/i386-linux
-Fu/home/graemeg/programming/fpc_2.2.3/src/packages/fcl-passrc/units/i386-linux
-Fu/home/graemeg/programming/fpc_2.2.3/src/packages/chm/units/i386-linux
-FE. -FUunits/i386-linux -di386 -dRELEASE fpdoc.pp
/usr/bin/ld: skipping incompatible /usr/lib/crti.o when searching for
/usr/lib/crti.o
/usr/bin/ld: cannot find /usr/lib/crti.o
Error: Error while linking
Fatal: There were 1 errors compiling module, stopping
Fatal: Compilation aborted
make[3]: *** [fpdoc] Error 1
make[3]: Leaving directory `/home/graemeg/programming/fpc_2.2.3/src/utils/fpdoc'
make[2]: *** [fpdoc_all] Error 2
make[2]: Leaving directory `/home/graemeg/programming/fpc_2.2.3/src/utils'
make[1]: *** [utils_all] Error 2
make[1]: Leaving directory `/home/graemeg/programming/fpc_2.2.3/src'
make: *** [build-stamp.i386-linux] Error 2



Questions:

1)  I see it's generating a i386 compiler and not a x86_64 compiler???
 Maybe that's because I copied my 32bit FPC 2.2.3 directory to the
64bit server?

2) No idea what the error means. I do have a /usr/lib/crti.o file. But
maybe that's due to the server being 64bit and FPC is generating a
32bit executable.

3) Can I bootstrap a 64bit FPC without any previous FPC compiler?  I
don't want to download 35MB's FPC 2.2.2 just to recompile 2.2.3



Regards,
  - Graeme -


_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/



More information about the fpc-pascal mailing list