Here is the step-by-step instructions for Mac OS X
1. Download sdk and ndk libraries for Mac OS X
2. Configure binutils with the following commands
./configure --target=arm-linux --disable-werror
make
sudo make install
This installation creates the /usr/local/arm-linux/bin directory.
3. a. cd /usr/local/arm-linux/bin
b. sudo mv as as_org
4. Create new "as" file with the following statements with your favorite editor.
#!/bin/sh
/usr/local/bin/arm-linuas_org -meabi=5 $@
5. sudo chmod 755 as
6. fpc revision fpc2.5.1 - 16790 {svn -r 16790}
7. Compile new fpc for linux arm
sudo make crossinstall CPU_TARGET=arm OS_TARGET=linux CROSSBINDIR=/usr/local/arm-linux/bin OPT="-dFPC_ARMEL -O- -dFPC_ABI_EABI"
8. Separate the original fpcsrc and the 2.5.1 fpc sources
sudo cp -rf packages rtl /usr/local/share/fpcsrc-2.5.1/
{You can create another directory other than fpcsrc, name doesn't matter}
9. In Lazarus, I changed these settings when compiling under linux-arm
a. Tools/IDE Options/Compiler Path/{this is the ppcrossarm compiler}
b. FPC Source Directory {in step 8}
c. Project/Compiler Options/Paths/{android-ndk-r7 directory}
10. Change local.properties sdk.dir to your sdk directory
If some of the steps are wrong or want to give some plus information please feel free to share.
And Oscar goes to Felipe for additional informations.
Thanks.