On 28/01/16 19:29, Dave Tucker wrote:
Current status...
1) Made some changes to build-rr.sh to allow you to specify the board using
`-b` e.g `./build-rr.sh -b rp hwi`
2) Initial cut at adapting `boardreg.h` for the BCM2835 (RPi A/B)
Things I haven't done yet:
1) Looked at any of the other files borrowed from the integrator-cp port
2) Managed to get any changes I've made so far to compile
3) Figured out how to eventually build an SD-card image with kernel.img + the
BCM blob
I'm currently blocked on finding a reliable cross compiler.
Using the recommended CFLAGS="-march=armv6zk -mcpu=arm1176jz-s -mfloat-abi=hard
-mfpu=vfp"
The one from https://github.com/raspberrypi/tools fails as it claims that the
CPU doesn't support `ldrexh` or `strexh` (spoiler: it does)
I've tried the Debian/Ubuntu cross-compiler but this also fails to compile a
sample program with:
`sorry, unimplemented: Thumb-1 hard-float VFP ABI`
See
http://wiki.rumpkernel.org/Info%3A-Notes-on-hardware-platforms#raspberry-pi
I filed a NetBSD PR about that "spoiler" years ago, don't remember what
the conclusion was off the top of my head, but anyway, the workaround
should be fine. At least it worked when I last was building for RPi.
Therefore I had no choice but to use crosstools-ng to build a new compiler
using the following config: https://gist.github.com/8dde0f90101d3194e9f0
This still fails:
`obj-evbearmhf-el-hw-raspberrypi/dest.stage/include/arm/aeabi.h:186:44: error:
unknown type name 'size_t'`
Don't know about that one, maybe some problem with the compiler. I'd
try the above-mentioned method first.