[ROM][KTU84P]AOSP from source, 4.4.4 PreFinal

Search This thread

gabx

Senior Member
Jul 24, 2011
768
318
59
Geneva, Switzerland
thnx. go test it and you will find out :p

even with another kernel , Kernel-Alucard-V2.6.6da-[22-20]-[16-04]-AOSP-EUR-KK4.4-SGIV-PWR-CORE, installation aborted.

I must do something wrong when unzipping/pushing my boot.img & modules/zipping.

Btw, never mind, as you succeed in building with GCC 4.8 and -03. Glad for you. I will although tried to see if mine is booting.

By curiosity, how did you get rid of all these [-Wsizeof-pointer-memaccess] errors ?
 

broodplank1337

Inactive Recognized Developer
Nov 24, 2011
4,992
10,155
Nijmegen
www.broodplank.net
even with another kernel , Kernel-Alucard-V2.6.6da-[22-20]-[16-04]-AOSP-EUR-KK4.4-SGIV-PWR-CORE, installation aborted.

I must do something wrong when unzipping/pushing my boot.img & modules/zipping.

Btw, never mind, as you succeed in building with GCC 4.8 and -03. Glad for you. I will although tried to see if mine is booting.

By curiosity, how did you get rid of all these [-Wsizeof-pointer-memaccess] errors ?


just flash it manually. then, no need for a zip. if you can compile a kernel you can also flash a kernel manually

dd if=/sdcard/boot.img of=/dev/block/mmcblk0p20

and modules (.ko) to /system/lib/modules

thats it

and I fixed that error by just adding -Wno-sizeof-pointer-memaccess in Makefile under KBUILD_CFLAGS

let me know results!
 

gabx

Senior Member
Jul 24, 2011
768
318
59
Geneva, Switzerland
just flash it manually. then, no need for a zip. if you can compile a kernel you can also flash a kernel manually

dd if=/sdcard/boot.img of=/dev/block/mmcblk0p20

and modules (.ko) to /system/lib/modules

ah bien voila. F** hell, I am stupid.

dd if=/sdcard/boot.img of=/dev/block/mmcblk0p20

let me know results!

--> bootloop :(
Not sure I unpack your boot.img & mkbootimg the right way thus.
1- got your boot.img form your last AOSP442-I9505-PreFinal-Sabermod_Linaro
2- $ ./split_boot s4/boot.img ---> got your boot.img-ramdisk.cpio.gz
3- with my own built zImage:
Code:
./mkbootimg --kernel zImage --ramdisk boot.img-ramdisk.cpio.gz --cmdline "androidboot.hardware=qcom user_debug=31 zcache msm_rtb.filter=0x3F ehci-hcd.park=3 maxcpus=2" -o boot.img --base "0x80200000"
- 4- at the root directory of your kernel dir :
Code:
find -type f -name "*.ko" | xargs cp -t ../modules

Thereafter adb push everything to sdcard, adb shell, mount -o rw,remount /system & dd & cp, chmod.

Anything wrong in creating the boot.img process ??
 

broodplank1337

Inactive Recognized Developer
Nov 24, 2011
4,992
10,155
Nijmegen
www.broodplank.net
ah bien voila. F** hell, I am stupid.

dd if=/sdcard/boot.img of=/dev/block/mmcblk0p20



--> bootloop :(
Not sure I unpack your boot.img & mkbootimg the right way thus.
1- got your boot.img form your last AOSP442-I9505-PreFinal-Sabermod_Linaro
2- $ ./split_boot s4/boot.img ---> got your boot.img-ramdisk.cpio.gz
3- with my own built zImage:
Code:
./mkbootimg --kernel zImage --ramdisk boot.img-ramdisk.cpio.gz --cmdline "androidboot.hardware=qcom user_debug=31 zcache msm_rtb.filter=0x3F ehci-hcd.park=3 maxcpus=2" -o boot.img --base "0x80200000"
- 4- at the root directory of your kernel dir :
Code:
find -type f -name "*.ko" | xargs cp -t ../modules

Thereafter adb push everything to sdcard, adb shell, mount -o rw,remount /system & dd & cp, chmod.

Anything wrong in creating the boot.img process ??

hmm it seems you are doing the right thing. but to be sure pls sent me the zImage and ill make an image for you as well. if mine does work there must be something wrong in your method
 

Faschoda

Senior Member
Mar 19, 2012
196
49
even with another kernel , Kernel-Alucard-V2.6.6da-[22-20]-[16-04]-AOSP-EUR-KK4.4-SGIV-PWR-CORE, installation aborted.

I must do something wrong when unzipping/pushing my boot.img & modules/zipping.

Btw, never mind, as you succeed in building with GCC 4.8 and -03. Glad for you. I will although tried to see if mine is booting.

By curiosity, how did you get rid of all these [-Wsizeof-pointer-memaccess] errors ?

Hey dude, no offense but wouldn't it be better to send brood a pm?
 

gabx

Senior Member
Jul 24, 2011
768
318
59
Geneva, Switzerland
hmm it seems you are doing the right thing. but to be sure pls sent me the zImage and ill make an image for you as well. if mine does work there must be something wrong in your method

TY. attached.

My kernel is maybe borken. I didn't use -Wno-sizeof-pointer-memaccess flag, but modified some pieces of code in the culprit functions. I understood the eroor given by sizeof(). It took a pointer as argument and size of a pointer is always 1. So I initialized a new variable this way:

Code:
	static ssize_t bufsz = sizeof(buf);
	return snprintf(buf, bufsz, "%u\n", ret);

and the error gone. I have still have doubt between ssize and size. Both work and the build went fine, but maybe one is wrong, or maybe my hack is a piece of sh*
 

Attachments

  • zImage.zip
    6.7 MB · Views: 4
  • Like
Reactions: MvL_1729

gabx

Senior Member
Jul 24, 2011
768
318
59
Geneva, Switzerland
Hey dude, no offense but wouldn't it be better to send brood a pm?


Yes, I can, but usually threads are made for this. All users can then benefit from any technical discussion, which can may be of some help.
That's the way forums/mailing lists have been working for long.

But I guess you do not care about any technical discussion, but wait for your new ROM to flash.

If the OP wants me to stop using the thread, I think he can tell me and we will go private. As far as I know, he didn't ask me to stop spamming his thread.
 

broodplank1337

Inactive Recognized Developer
Nov 24, 2011
4,992
10,155
Nijmegen
www.broodplank.net
TY. attached.

My kernel is maybe borken. I didn't use -Wno-sizeof-pointer-memaccess flag, but modified some pieces of code in the culprit functions. I understood the eroor given by sizeof(). It took a pointer as argument and size of a pointer is always 1. So I initialized a new variable this way:

Code:
	static ssize_t bufsz = sizeof(buf);
	return snprintf(buf, bufsz, "%u\n", ret);

and the error gone. I have still have doubt between ssize and size. Both work and the build went fine, but maybe one is wrong, or maybe my hack is a piece of sh*

idd gcc 4.8 is more strict. but luckily for everything is a solution.
good you found it

attached boot.img with your zImage
 

Attachments

  • boot.img.zip
    7.2 MB · Views: 5

gabx

Senior Member
Jul 24, 2011
768
318
59
Geneva, Switzerland
idd gcc 4.8 is more strict. but luckily for everything is a solution.
good you found it

attached boot.img with your zImage

and yyeeess, it boots. So I guess the one built with 4.9 will also boot, as I didn't get any build errors.
I do not know what I did wrong when mkbootimg.

I will then stop spamming the thread, as some users seem to have forgotten there is the word developers in the URL of this forum.
They certainly prefer ask for always some more pointless new functionality and wait for the next update to flash, flash and more flash.

Oh Brood, thank you for your wonderful ROM. I LOVE it and my phone is now one of the best of the world. I can even get the lottery numbers .BUT please, can I ask something:
A friend of mine has a ROM IamTheBestDev rc 4 fully optimized, and he sees his contact pictures in 3D. It would be nice to have same in your ROM.



Glad you managed to build with GCC 4.8 in a simplest way than I did with some code hacking.

I know why I stopped long time ago wasting my time here. Of course, nothing related to you Sir :)
 
  • Like
Reactions: !crazy

broodplank1337

Inactive Recognized Developer
Nov 24, 2011
4,992
10,155
Nijmegen
www.broodplank.net
and yyeeess, it boots. So I guess the one built with 4.9 will also boot, as I didn't get any build errors.
I do not know what I did wrong when mkbootimg.

I will then stop spamming the thread, as some users seem to have forgotten there is the word developers in the URL of this forum.
They certainly prefer ask for always some more pointless new functionality and wait for the next update to flash, flash and more flash.

Oh Brood, thank you for your wonderful ROM. I LOVE it and my phone is now one of the best of the world. I can even get the lottery numbers .BUT please, can I ask something:
A friend of mine has a ROM IamTheBestDev rc 4 fully optimized, and he sees his contact pictures in 3D. It would be nice to have same in your ROM.



Glad you managed to build with GCC 4.8 in a simplest way than I did with some code hacking.

I know why I stopped long time ago wasting my time here. Of course, nothing related to you Sir :)

I dont think its spam since it's specific developer talk regarding compilation of kernel for this rom. but thats just my opinion.

Anyways, thank you! I do my best :)
He should use the Dialer/Contacts app from AOSP then
 

danny_and_2

Senior Member
Sep 14, 2008
1,381
379
Denmark
I will then stop spamming the thread, as some users seem to have forgotten there is the word developers in the URL of this forum.
They certainly prefer ask for always some more pointless new functionality and wait for the next update to flash, flash and more flash.

I think it's relevant, because we/us/all help Florent improve his already perfectionistic rom made for all of us. Togehter we can make the rom better by enlightning Florent with new features from kernel to rom, he may not include everything, but some he implant.

Florent you do a hell of a job here, your support & your kindness is the reason why u are the only rom, I'll run as a daily driver.

-- Edit

Oh btw mate! Hell of a debugging job you'd have done! I take my hat off for u!
 
Last edited:
  • Like
Reactions: broodplank1337

Faschoda

Senior Member
Mar 19, 2012
196
49
and yyeeess, it boots. So I guess the one built with 4.9 will also boot, as I didn't get any build errors.
I do not know what I did wrong when mkbootimg.

I will then stop spamming the thread, as some users seem to have forgotten there is the word

I know why I stopped long time ago wasting my time here. Of course, nothing related to you Sir :)


Dude as I said it wasn't meant in an offensive way! IT was just a question. I'm sorry that I hurt your feelings and sorry for making a mistake.
 

droid_1989

Senior Member
Dec 6, 2011
869
124
Leeds
Anyone else had issues opening word or excel documents with the default viewer?

I had to download quick office to get it to appear, as it was just opening from Gmail into a white document.

Works fine with every other viewer but the default one that comes with the build...

Sent from my GT-I9505 using xda app-developers app
 

DSA

Senior Member
May 15, 2011
4,740
5,777
Dude as I said it wasn't meant in an offensive way! IT was just a question. I'm sorry that I hurt your feelings and sorry for making a mistake.

I don't think anyone's making this into an argument fella

I actually wish my (now closed) thread was full of these code/building related posts...this is exactly what XDA is about...instead most of the time its nothing like this and just requests for updates or bugs without logcats

The last few pages have been a great read for me and actually pointed a few things out I didn't know (thanks for discussing in public for us all guys)
 

gabx

Senior Member
Jul 24, 2011
768
318
59
Geneva, Switzerland
I don't think anyone's making this into an argument fella

The last few pages have been a great read for me and actually pointed a few things out I didn't know (thanks for discussing in public for us all guys)

you are welcome, even in the XDA jungle !

If you want to talk more about building kernel with GCC 4.8 & 4.9, we can find a place for it. Just PM me
 
  • Like
Reactions: DSA and giarob78

broodplank1337

Inactive Recognized Developer
Nov 24, 2011
4,992
10,155
Nijmegen
www.broodplank.net
@broodplank1337, I tried to boot your rom from a f2fs formatted system partition. But I didn't got to the bootanimation :/

L

Gesendet von meinem GT-I9505 mit Tapatalk

You also have to change the ext4 lines from fstab.qcom to f2fs. inside the ramdisk. but I also wasn't able to get a working f2fs system, but when I tested I had no recovery compatible with f2fs so that may be the cause.

See this! I think this is the fix, it includes other params, just what I was looking for: http://review.cyanogenmod.org/#/c/61952/1/rootdir/etc/fstab.qcom

found by @desalesouche
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 194
    Android KitKat 4.4.4 AOSP
    android-kitkat.png




    WORKING:
    - Screen (2D (surfaceflinger) + 3d (OpenGL ES 3.0)
    - Sound
    - GPS
    - RIL
    - SIM
    - G/E/3G/H/H+/LTE
    - Outgoing Calls
    - Incoming Calls
    - Outgoing SMS
    - Incoming SMS
    - Wifi
    - NFC
    - LED
    - Camera
    - Internal/External SD Card
    - ExFat
    - Bluetooth
    - TV-OUT (MHL)
    - Infrared (ConsumerIR)
    - Sensors
    - Netflix Playback
    - USB OTG


    Little Demonstration


    Download:


    kitkat2.png



    If you like my work please consider making a donation, I spend almost all my free time on making this rom the best :p




    Download PreFinal Release
    - Last release before 100% bug free release "final v1" (from final v1 will only increment if new android version)

    BUG COLLECTOR:
    https://code.google.com/p/aosp-s4-kk/issues

    Download:
    http://www.broodplank.net/files/AOSP444-I9505-PreFinal.zip



    Below is 4.4.2

    Download Release Candidate 5:
    check this post

    Download:
    http://www.broodplank.net/files/AOSP442-i9505-RC-5.zip


    Download Release Candidate 4:
    - Update to android-4.2.2_r2 (KVT49L)
    - Cleaner ramdisk, increase read_ahead_kb
    - Fix race condition at boot (100% Fix hang at boot)
    - General fixes on cpu behavior
    - Choose filesystem on format sdcard
    - Dalvik: char array copy optimization
    - Introduce RTC clock usage (wake on alarm when off)
    - New Wifi firmware
    - Some patches for virtual display
    - Minor chromium fixes
    - Fix video stutters
    - Use Real KitKat color Scheme (http://xdaforums.com/showthread.php?t=2634743)
    - QCOM patches for media/display
    - Disabled Qcom Enhancements, Fixes video resolution on hw decoder and crash bug
    - Tons of patches for audio/video playback
    - Update kernel to 3.4.80 with many new patches
    - New lossless kernel compression
    - Enabled support for Fast Charging
    - Camera focus fixes
    - SDcard I/O error fixes

    Download:
    http://www.broodplank.net/files/AOSP442-i9505-RC-4.zip









    Additional Information

    Getting full WiFi speed
    Go to Settings > Wi-Fi > *Press menu button* > Advanced > uncheck Wi-Fi Optimization




    Other Downloads:

    Download Gapps Lite + Root:
    I recommend this lite gapps + root package, it's only around 20mb and works great with ART
    http://www.broodplank.net/files/gapps-4.4.2-lite-with-supersu-1.86.zip


    Download Boosterpack: (Next to already partly integrated it now causes bootloops)
    The boosterpack releases are a combination of the optimized davlik / bionic libs from qualcomm.
    Next to that it includes a Linaro O3 Kernel which is compiled with an Optimized Linaro Toolchain (Thanks to @Christopher83)

    Latest release: http://www.broodplank.net/files/AOSP-4.4.2-Boosterpack-v7.zip







    Installing:
    1. Put latest release + gapps lite for 4.4.2 + root on your sdcard
    2. Reboot in recovery (make sure its compatible with 4.4.x )
    3. If coming from any other rom then a previous version of this aosp, its highly recommended to fully wipe /data to prevent bootloops
    4. Install ROM zip and then install gapps + root (the one provided by the link)
    5. Reboot your phone and enjoy my ROM





    XDA:DevDB Information
    [ROM][KTU84P]AOSP 4.4.4 from source, ROM for the Samsung Galaxy S 4

    Contributors
    broodplank1337
    ROM OS Version: 4.4.x KitKat
    ROM Kernel: Linux 3.4.x
    Based On: AOSP

    Version Information
    Status: Stable
    Current Stable Version: PreFinal
    Stable Release Date: 2014-06-21
    Current Beta Version: 13
    Beta Release Date: 2013-12-11

    Created 2013-08-13
    Last Updated 2014-06-20
    50
    Ok as some of you know I have been experimenting with AOSP 4.3 lately, and I have build it now from source (with the help of a lot of external repositories. although every file in /system/app and /system/framework is from the real aosp. so that means there are zero modifications to the system. This first build I really messy, I have compiled it with very much pain lol. It's kinda "frankenrom" right now since I have merged different builds together to get the best working system. but it works! And that's a big word when talking about the static aosp. (this is mainly because of the cm repo's else it would have never booted).
    The performance is about the same of CM-10.2. it scores around 25k in antutu, but that's the last thing I care about right now.
    I think we can get AOSP to work completely for jfltexx, it's not so hard with combined power.. it's hard to do it on your own tho.


    Vanilla-O-Meter: 86%
    (This represents the percentage of AOSP vanilla repositories used for last build)


    WORKING:
    - Screen (2D (surfaceflinger) + 3d (OpenGL ES 3.0)
    - Sound
    - GPS
    - RIL
    - SIM
    - G/3G/H/LTE
    - Outgoing Calls
    - Incoming Calls
    - Outgoing SMS
    - Incoming SMS
    - Wifi
    - NFC
    - LED
    - Camera (HDR, no green lines on front cam photo's)
    - Internal/External SD Card
    - ExFat
    - Bluetooth
    - IRDA (IR Blaster)
    - TV-OUT (MHL)




    Download:


    Download Final Release 5:
    - System wide root (all kernels)
    - Hangs at bootlogo fixed!
    - Some bug fixes to OpenGL ES3.0
    - Reverted some provisioning updates (experimental)
    - Patch for MKV playback
    - Many patches to the camera/gallery
    - LibVideoEditor fix
    - Improved ADB Error logging (stderr support)

    http://www.broodplank.net/files/aosp43-i9505-Final-R5.zip


    Download Final Release 4
    - Fixed sdcard writing bug
    - Many patches from master (maybe including the rare crash on opengl es3.0)
    - Provisioning bug (no baseband) probably fixed.
    - Kernel update to 3.4.66

    http://www.broodplank.net/files/aosp43-i9505-Final-R4.zip











    Installing:
    1. Put latest release + gapps for 4.3 on your sdcard
    2. Reboot in CWM (NO OTHER RECOVERY!!!)
    3. If coming from any other rom then a previous version of this aosp, its highly recommended to fully wipe /data to prevent bootloops
    4. Install ROM zip and then install gapps (the one provided by the link)
    5. Additionally but most likely you want to root it. use SuperSU v1.51 from Chainfire to root it



    Credits for repositories:
    - AOSP (Google)
    - CyanogenMod
    - SuperNexus

    Credits for commits:
    - CyanogenMod
    - SlimROM
    - LiquidSmooth
    - SuperNexus
    - AOSP

    Screenshots are in the attachment


    Scraps:
    (these are the attachments I posted randomly)

    - Gallery2 (deprecated since last build)
    - Linaro O3 Kernel
    - Kernel with VDD Sysfs Support (live UV/O) (deprecated since release 3)
    - Gallery2 from CM-10.2 (No green lines on front cam and hdr pics but bugged interface)
    - mini breakbeat mix (if you need to kill 8.5 minutes, listen to this)
    31
    I have made a slow start in migrating to Android L, and now that i am busy with it, I notice again how time consuming it is. Since I don't have a lot of time, don't count on me to release the first working android 5 rom for the s4 (as i did with previous versions), this simply because i don't have the time to achieve this.

    This time I will develop a bit more in lazy mode (to save time) by merging cm-12.0 sources where ever possible without touching the original aosp. (Which means no frameworks/base among many others, I will merge those directly from AOSP obviously)

    Actually I had planned to have a bot (written in bash) by now that does the merging all automatically. but I have not created it yet.. FML

    Anyways, long story short, dev started, but no turbo mode
    30
    omg it's almost working!!!

    Only 1 error left :D

    E/qdhwcomposer( 296): Failed to call ioctl MSMFB_OVERLAY_SET err=Math result not representable

    So im probably one mathematical step away from a (most likely) booting rom. :D:D Now have to find the file where that nasty calculation is made XD

    ok that one is fixed now, it was an error in the kernel.
    now with the fixed kernel it still doesn't boot unfortunately, reason, audiopolicymanager. and camera module

    im getting pretty excited right now, it the first "almost" boot in 3 days of non stop work xd
    27
    Wow I'm soooooooooooooooooooooooo close.

    - AudioPolicy is fixed (audio-caf, libhardware, libhardware_legacy)
    - All CAF drivers are fixed (audio-caf, media-caf, display-caf)
    - Unknown camera call fixed (system_core)

    Just did make clean and I'm now rebuilding it.

    According to my calculations it should boot, the only problem that I encountered next to these fixed problems is that data wasn't mounted properly, thus it couldn't boot because of that as well, this might be some flaw in the sepolicy, but I think its actually because of the ramdisk, I edited the ramdisk myself and put a (incorrect) way of mounting data in there and it picked up data, but gave some error because it wasn't mounted properly.

    :cool::cool::cool::cool::cool::cool::cool::cool:

    I bet I get it working before CM!!