[Nook Color Android Development] fattire:
More on building with Linaro...

So, a couple new items on the road to building with the linaro toolchain instead of the one I've been using. I have been playing with this somewhat with the 3.0 kernel, but I gotta go for the evening so thought I'd post my progress so someone can pick it up if they want.

So!

1. start with a working cm9 build w/3.0. I posted more about this in the other thread and some of you have reported successfully building the 3.0 build.

2. Download a nightly of the 4.7 linaro toolchain. I am using the 4.7 version rather than the trunk version. I uncompiled it (you can bunzip2 it and then tar -xvf it) here:

~/Development/linaro/android-toolchain-eabi-4.7

But you can put it anywhere.

3. I repo synced, then applied the two linero patches from cm9 gerrit as discussed previously:

here and here.

4. Since i'm using the new hardware/ti/omap3 repo from omapzoom, and since linaro doesn't provide patches for it, I had to do my own hacky patches that let it compile. (I know they're awful but for now they work)

5. I also added the following changes to device/bn/encore/BoardConfig.mk so that it would use the linaro optimizations:

+ARCH_ARM_HAVE_ARMV7A := true

-TARGET_GLOBAL_CFLAGS += -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp

-TARGET_GLOBAL_CPPFLAGS += -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp

+TARGET_GLOBAL_CFLAGS += -O3 -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp -fmodulo-sched -fmodulo-sched-allow-regmoves

+TARGET_GLOBAL_CPPFLAGS += -O3 -mtune=cortex-a8 -mfpu=neon -mfloat-abi=softfp -fmodulo-sched -fmodulo-sched-allow-regmoves

7. To do the actual build, "lunch" as normal, then do this command:

make -j9 TARGET_TOOLS_PREFIX=~/Development/linaro/android-toolchain-eabi-4.7/bin/arm-linux-androideabi- bacon

You can replace that TARGET_TOOLS_PREFIX to point to wherever you put the linero toolchain.

8. Wait while it builds to see what happens.

6. I got a build error that may be simply something screwy in the repository for right now, so I don't recommend you trying this part unless you need it:

diff --git a/src/com/android/settings/cyanogenmod/LockscreenTargets.java b/src/com/android/settings/cyanogenmod/LockscreenTargets.ja
index 0c2e107..9a67443 100644
--- a/src/com/android/settings/cyanogenmod/LockscreenTargets.java
+++ b/src/com/android/settings/cyanogenmod/LockscreenTargets.java
@@ -110,7 +110,7 @@ public class LockscreenTargets extends Fragment implements ShortcutPickHelper.On
mResources = getResources();
mIsLandscape = mResources.getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE;
mTargetOffset = mIsLandscape && !mIsScreenLarge ? 2 : 0;
- mTargetInset = mResources.getDimensionPixelSize(com.android.internal.R.dimen.lockscreen_target_inset);
+// mTargetInset = mResources.getDimensionPixelSize(com.android.internal.R.dimen.lockscreen_target_inset);
mIconPicker = new IconPicker(mActivity, this);
mPicker = new ShortcutPickHelper(mActivity, this);
mImageTmp = new File(mActivity.getCacheDir() + "/target.tmp");

The result I get right now: the build finishes, and it comes up, but for some reason init gets stuck on netd. I don't have the time to track it down now, but I thought I'd post what I'd done in case some entrepreneur wanted to explore a little :)

ft