[fpc-pascal] Compiling FPC for SPARC

Vincent Snijders vsnijders at quicknet.nl
Thu Aug 3 08:50:04 CEST 2006


Mark Morgan Lloyd schreef:
> Tomas Hajny wrote:
> 
>> I propose to check with the 2.0.4-rc2 sources. You can get these from
>> ftp://ftp.freepascal.org/pub/fpc/beta/2.0.4-rc2/source/,
> 
> That builds (make cycle) OK on/for linux-i386 using FPC 2.0.2, but on
> linux-sparc using FPC 2.0.0 I get:
> 
> Target OS: Linux for SPARC
> Compiling system.pp
> ..
> rtti.inc(268,9) Warning: Comment level 2 found
> ossysc.inc(192,14) Error: Identifier not found "syscall_nr_exit_group"
> system.pp(271) Fatal: There were 1 errors compiling module, stopping
> system.pp(271) Error: Compilation aborted
> make[5]: *** [system.ppu] Error 1
> make[5]: Leaving directory
> `/home/markMLl/pascal/src/fpcbuild_2_0_4_rc2_exp/fpcsrc/rtl/linux'
> make[4]: *** [linux_all] Error 2
> 
> I seem to have three choices:
> 
> i)   Find the file in the 2.0.2 sources that SPARC 2.0.0 couldn't compile, and
>      see if there's some hack that will fix this.
> 
> ii)  Ditto for 2.0.4 sources (possibly easier since the compiler isn't bombing).
> 
> iii) Compile 2.0.2 on i386 to target SPARC, and see if that will compile the
>      2.0.2 source.
> 
> My gut feeling is (iii), but any suggestions would be appreciated.
> 

Look up the syscall_nr_exit_group (the number for exit_group syscall) for sparc and 
add it to rtl/linux/sparc/sysnr.inc and try to compile again.

This syscall was not used in fpc 2.0.2, but was added afterwards. You might find 
more of those.

Vincent



More information about the fpc-pascal mailing list