View Single Post
Old 03-29-2013, 07:10 AM   #2
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 6,586
Karma: 6299993
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW-WIFI|K5-3G+WIFI| K4|K3-3G|DXG|K2| Rooted Nook Touch
I exported that one twice already.
if you just want to run in it a Xephyr then I already bundled it.

http://drpbox.knetconnect.com/KeK/ <-- Get tools here.
2012.03 generally builds for the higher devices but can build for all with some flags and love
2007q3 for the lower and higher ones. I personally try to build with the 2007q3 for all devices if I can as it means sure-fire support, but its an old Toolchain and some newer codebases may not like it.

You then need to pimp your toolchain a bit. say we are using the 2007q3 and you are just targetting the "under 4's" 2, DX, 3.

Grab the zip. unzip in /opt

Grab all the libs out of your kindle and dump them in /opt/arm-2007q3/arm-none-linux-gnueabi/lib

DO NOT DROP the c libs in there... it will break the toolchain...

Now "headers"... I personally cheat and just build a full buildroot then go grab my headers out of there and drop them in... /opt/arm-2007q3/arm-none-linux-gnueabi/include

Since I have a bunch of toolchains I then source whatever path I need for the toolchain like:
Quote:
. /path2007q3
(note the space after the dot)

where the file contains: me@dev ~ $ cat /path2007q3
Code:
export PATH=/opt/arm-2007q3/bin:$PATH
you can do this however you want... I like that way.

I also then source my flags for the device similarly: . /flagsk5 or . /flagsk3

To be honest Niluje provides a more complete example that this is based on on his Screensavers thread.

Let's look what is in one:

me@dev ~ $ cat /flagsk5
Quote:
export ARCH_FLAGS="-march=armv7-a -mtune=cortex-a8 -mfpu=vfpv3-d16"
export CFLAGS="-mfloat-abi=softfp -flto -O2 -ffast-math ${ARCH_FLAGS} -pipe -fomit-frame-pointer"
and the other one...

me@dev ~ $ cat /flagsk3
Quote:
export ARCH_FLAGS="-march=armv6j -mtune=arm1136jf-s -mfpu=vfp"
export CFLAGS="-U_FORTIFY_SOURCE -fno-stack-protector -O2 -fno-finite-math-only -ffast-math ${ARCH_FLAGS} -pipe -fomit-frame-pointer -fPIC"
#ARM_NO_UNALIGNED_ACCESS="-mno-unaligned-access" <-- Dx
export CXXFLAGS="-fno-stack-protector -fno-use-cxa-atexit"
export CPPFLAGS="-U_FORTIFY_SOURCE"
Those are by no means exhaustive options. If you want to be super compliant check out Nilujes work.

I have no idea if I missed anything...

Assuming a perfect world you would then

me@dev ~ $ CC=arm-none-linux-gnueabi-gcc CROSS_COMPILE=arm-none-linux-gnueabi- ./configure --build=i686-pc-linux-gnu --host=arm-none-linux-gnueabi prefix=/mnt/us/extensions/myAwesomeNewApp

make

make install


and see how you go...

Hope that helps somewhat.
Attached Thumbnails
Click image for larger version

Name:	Selection_289.png
Views:	403
Size:	11.3 KB
ID:	103636   Click image for larger version

Name:	Selection_290.png
Views:	430
Size:	53.1 KB
ID:	103637  

Last edited by twobob; 03-29-2013 at 07:12 AM.
twobob is offline   Reply With Quote