yashsingh1/xdaforums huggingface dataset:
[Android Software/Hacking General [Developers Only]] TheMorpheus:
I'm trying to build OmniRom for N8000 and I get this error:

including ./abi/cpp/Android.mk ...
including ./android/build/libs/host/Android.mk ...
including ./android/build/target/board/Android.mk ...
including ./android/build/tools/Android.mk ...
including ./android/frameworks/rs/Android.mk ...
including ./art/Android.mk ...
including ./bionic/Android.mk ...
including ./bootable/diskinstaller/Android.mk ...
including ./bootable/recovery/Android.mk ...
including ./build/libs/host/Android.mk ...
build/core/base_rules.mk:134: *** build/libs/host: MODULE.HOST.STATIC_LIBRARIES.libhost already defined by android/build/libs/host. Stop.

I've tried with linaro 4.8 and google toolchain

<!-- LINARO TOOLCHAIN -->
<project name="JustArchi/linaro.git" path="prebuilts/gcc/linux-x86/arm/arm-eabi-4.8" remote="github" revision="4.8-eabi" />
<project name="JustArchi/linaro.git" path="prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.8" remote="github" revision="4.8-androideabi" />

<!-- GOOGLE GCC TOOLCHAIN -->
<!-- <project name="platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.8" path="prebuilts/gcc/linux-x86/arm/arm-eabi-4.8" revision="master" /> -->
<!-- <project name="platform/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.8" path="prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.8" revision="master" /> -->
[Android Software/Hacking General [Developers Only]] UtkarshGupta:
+1 on n7100 with cyanogenmod - imgur.com/LHbatCR
[Android Software/Hacking General [Developers Only]] JustArchi:
I know it, but Google Store depends on libskia, webp is not included standalone.
[Android Software/Hacking General [Developers Only]] desalesouche:
Hi. If i understand well i can use older prebuilt libskia or a recent one compiled with google toolchain 4.7?
[Android Software/Hacking General [Developers Only]] 95A31:
What you mean with "webp is not included standalone" ?

It is statically linked, so the library (for my device) are in out/target/product/kumquat/obj/STATIC_LIBRARIES/libwebp-decode_intermediates/ and

out/target/product/kumquat/obj/STATIC_LIBRARIES/libwebp-encode_intermediates/. Readme look like say that they are not included in android system image.

Yes
[Android Software/Hacking General [Developers Only]] JustArchi:
I meant exactly the same what you said. It's then linked to libskia.so, so if you want "end-user-solution", you need to replace whole libskia.so.

As I said, you pushed me into the right direction, I forked android_external_webp, synced with master AOSP branch, and I'll try to upstream it to current webp version to see if it helps.

https://github.com/JustArchi/android_external_webp

I'll let you know if I find "nice" solution.
[Android Software/Hacking General [Developers Only]] 95A31:
Ok, I will provide you the precompiled libwebp-* so it can be used on compiletime by libskia (asap I fix boot on my devices :silly:)
[Android Software/Hacking General [Developers Only]] noname55804:
So evrything has compiled well using the GCC 4.9 toolchain from your new repo, thanks for that [MENTION=5161352]JustArchi[/MENTION]

But i also got those glitches in Playstore, but i read that you´re already working on a fix ;)

Now i wanna head over to your commits. First of i dont now if i should aplly the Cm or the Omni commit to a LiquidSmooth repo, but i think Omni fits better as Omni is AOSP as well as Liquid. Is that right?

And next, in LiquidSmooth you already have the option to built with different O flags from Os to O3. I didnt use them before because i didnt know what they stand for. Now i think that O3 would have been the best option...anyway when i´ve cherry.picked your commit, do i still have to use those flags or does the magic happen automaticly?:D

Thanks in advance
[Android Software/Hacking General [Developers Only]] 95A31:
[MENTION=5161352]JustArchi[/MENTION]

Workaround: https://github.com/AndroidOpenSourc...mmit/4fb7aba33f0c8a9e1de6d3901a59d72e8614dd0f
[Android Software/Hacking General [Developers Only]] JustArchi:
Forget about that :).

I promised to solve this mystery, when I find the culprit, alright?

Here is the real, clean and professional fix -> https://github.com/JustArchi/android_external_webp/commit/36c6201fbb108d6b757f860e2cd57f3982191662

Now I'm awaiting for the developer award of the year :).
[Android Software/Hacking General [Developers Only]] JustArchi:
After a bit deeper investigation this commit standalone should fix the issue -> https://github.com/JustArchi/android_external_webp/commit/637b3888090dea7d79aa51731186938f8f0edf4d

Go ahead and try it guys before trying my upstream commit above :).
[Android Software/Hacking General [Developers Only]] jamieg71:
I ain't gonna say your a genius... But

Thanx for this
[Android Software/Hacking General [Developers Only]] noname55804:
So to use this fix (which is really awesome BTW) we just go in our webp directory and cherry-pick this?

And don't forget about my question down below

So evrything has compiled well using the GCC 4.9 toolchain from your new repo, thanks for that [MENTION=5161352]JustArchi[/MENTION]

But i also got those glitches in Playstore, but i read that you´re already working on a fix ;)

Now i wanna head over to your commits. First of i dont now if i should aplly the Cm or the Omni commit to a LiquidSmooth repo, but i think Omni fits better as Omni is AOSP as well as Liquid. Is that right?

And next, in LiquidSmooth you already have the option to built with different O flags from Os to O3. I didnt use them before because i didnt know what they stand for. Now i think that O3 would have been the best option...anyway when i´ve cherry.picked your commit, do i still have to use those flags or does the magic happen automaticly?:D

Thanks in advance
[Android Software/Hacking General [Developers Only]] 95A31:
Hahaha you win :good:

EDIT:

Can you fix also this? https://github.com/AndroidOpenSourc...mmit/7c83c8974fea4fcef16e424121253d2c91f9eae8

EDIT 2 + 3:

For linaro 4.10 witch fix i should use?

- LOCAL_GCC_VERSION >= 0x409

- LOCAL_GCC_VERSION == 0x4010

- LOCAL_GCC_VERSION == 0x410
[Android Software/Hacking General [Developers Only]] JustArchi:
What's wrong with libstlport? I didn't face any issue with it.

Any reproducable case?
[Android Software/Hacking General [Developers Only]] noname55804:
So to use this fix (which is really awesome BTW) we just go in our webp directory and cherry-pick this?

I've now tried to apply your Optimisation for Omni to my Liquid Repo. I resolved all conflict as good as I can but I got a lot of errors. May anybody can help me?

Did I resolved the conflicts wrong?

Should I try the CM Optimisations?

Is there an easy solution for this?

And I've still the question in my mind if I need to type -o3 into the build command after I used you opti's

Edit (forgot the screens :D):
[Android Software/Hacking General [Developers Only]] tsubus:
I've known about this for a while, but never tried it till now. I've added the patch and I'm now using SaberMod 4.8 on both ROM and kernel (full O3). So far I've been successfull with Nexus 5, i9300, and HTC Desire Z, all running the same ROM (CM11-based). I'm now compiling for jflte, hopefully I don't have to do too much to get the kernel to compile.

Anyway, just wanted to say thank you for you work and show you some results.
[Android Software/Hacking General [Developers Only]] xboxfanj:
Excellent job on the Play Store fix, Archi.
[Android Software/Hacking General [Developers Only]] 95A31:
I mean this: http://xdaforums.com/showpost.php?p=54280659&postcount=1269 If i remember fine there are some problem with aliasing and linking to libart. It will be nice if i can compile 100% of sources without prebuild binaries otherwise nvm, it is working anyway :cyclops:. I tryed to filter out some of your optimization flags in the stlport's Android.mk but I do not have so deep knowledge in compiling stuff.
[Android Software/Hacking General [Developers Only]] marcomarinho:
This is a little OT.

I added the Inline kernel config to the device tree, but compiled the stock kernel

https://github.com/EuclideanROM/platform_device_asus_grouper/commit/dbef69f8086259405656482bb4eb1ad3ea90fe29

Anyone know how to fix this to build a custom kernel?
[Android Software/Hacking General [Developers Only]] noname55804:
So, i apllied this and it dint solve the issue, should i try the commit from post #788?

And i´m still stuck at your commits, i tried it again and still getting the issues i mentioned in post #794.

Is there a fix for that or did i make a mistake at resolving the conflicts?

If so, may someone can help me out?

https://drive.google.com/folderview?id=0BynyXuamxhDBU2kxdFpVVjJrMUU&usp=sharing

I´d really appreciate it :)
[Android Software/Hacking General [Developers Only]] kidkoala_uk:
These should allow inline kernel building.

https://github.com/SimpleAOSP/android_build/commit/47be16cbdf093762a586eb0213359be723d5aa43

https://github.com/SimpleAOSP/android_build/commit/cd6e992c7c6ac1aefbcd5b3433c76c728ce6eb8b
[Android Software/Hacking General [Developers Only]] marcomarinho:
But I already had it :(

https://github.com/EuclideanROM/platform_build
[Android Software/Hacking General [Developers Only]] JustArchi:
Did you make clean and empty ccache?

Actually I didn't test it standalone as I upstreamed whole libwebp core. My commit must work, fix standalone may not.
[Android Software/Hacking General [Developers Only]] noname55804:
So should I try the larger commit you mentioned in the post above the standalone?

Yes I did. I really don't know what is causing this but if this not a common issue it must have smth to do with the conflicts I might resolved wrong? If you have time I'd really appreciate it if you could look into the 3 files with the conflicts.
[Android Software/Hacking General [Developers Only]] giveme13s:
Got the same errors as above, and tried adding -Wno-sizeof-pointer-memaccess in TARGET_arm_CFLAGS, but errors still persisted on both gcc 4.8 of linaro and google.

However, after adding the below line (in red) in file Makefile (kernel source), the above errors are gone.

KBUILD_CFLAGS := -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs \
-fno-strict-aliasing -fno-common \
-Werror-implicit-function-declaration \
-Wno-format-security \
[COLOR=Red] -Wno-sizeof-pointer-memaccess \[/COLOR]
-fno-delete-null-pointer-checks
KBUILD_AFLAGS_KERNEL :=
KBUILD_CFLAGS_KERNEL :

Posting this for maybe it can help anyone with same problems
[Android Software/Hacking General [Developers Only]] noname55804:
So I tried the larger commit and it finally fixes the glitches. Thanks [MENTION=5161352]JustArchi[/MENTION]

But I still want to try your Optimizations bit I've no clue how to solve the issues.

Any help?
[Android Software/Hacking General [Developers Only]] JustArchi:
Oh yeah, it's nice to point that android_build flags have no outcome on the kernel compiling, as it uses it's own set of flags (KBUILD_FLAGS).
[Android Software/Hacking General [Developers Only]] mastero9017:
Something is still broken?

https://github.com/ArchiDroid/ArchiDroid/issues/5
[Android Software/Hacking General [Developers Only]] JustArchi:
http://i.imgur.com/duqbiPK.jpg

Misc issue, probably I'll solve it soon.

IMPORTANT NEWS!

As previously stated, I've added all AOSP's and Linaro's toolchains to one common repo:

https://github.com/ArchiDroid/Toolchain

From now on all other repos (including JustArchi/Toolchain and JustArchi/Linaro) are DEPRECATED and will be removed at any time.

If you wish to use my repo (Linaro), you can find valid working examples of adding toolchain of your choice in my ArchiDroid manifest:

https://github.com/ArchiDroid/ArchiDroid/blob/master/__build/roomservice.xml

NOTICE: ArchiDroid has now "unified" toolchain selectable in the manifest and not android_build itself:

https://github.com/ArchiDroid/android_build/commit/0f99609fea5414225479f425b737ab09c854cdff

Applying above commit means that build will search in arm-eabi-ArchiDroid and arm-linux-androideabi-ArchiDroid for valid toolchain. This has number of benefits, mostly important - I don't need to bump version in my repo everytime I'm changing the toolchain, I can do it via manifest only, and it also doesn't matter if I switch from linaro 4.9 to AOSP's 4.8 or whatever.

NOTICE #2: I started working on "unified" ArchiDroid tree across all devices.

This means that YOU can bring ArchiDroid to your device, if you're patient enough, you like what I'm doing and want to benefit from all ArchiDroid improvements, including AROMA installer and so on.

Common ArchiDroid tree:

https://github.com/ArchiDroid/ArchiDroid

Manifest:

https://github.com/ArchiDroid/ArchiDroid/blob/master/__build/roomservice.xml

Build script:

https://github.com/ArchiDroid/ArchiDroid/blob/master/__build/build.sh

Example of bringup for i9300:

https://github.com/ArchiDroid/ArchiDroid/commit/fe510e8eb0cb30d127cd07df098e84a076da0ee3

https://github.com/ArchiDroid/ArchiDroid/commit/0b987314326382679044635dd6675a992955094f

ArchiDroid is NOT only a CyanogenMod built from source. After initial compiling, it's then merged with the ArchiDroid (core) including AROMA installer, bunch of apps, tweaks, scripts and so on. However, getting working source-built build is core for going further.

If you're interested in developing/bringing ArchiDroid to your device, let me know if you need a helpful hand.

(I'm still busy organizing everything in my repo, so this is pretty alpha statement, consider it done when I'm done with my 3 devices - Galaxy S3, Xperia M, LG e610)

Cheers!
[Android Software/Hacking General [Developers Only]] satyr007:
2nd:

/omni/kernel/lge/hammerhead/drivers/usb/gadget/f_qdss.c: In function 'qdss_bind_config':

/omni/kernel/lge/hammerhead/drivers/usb/gadget/f_qdss.c:599:38: warning: argument to 'sizeof' in 'strncmp' call is the same expression as the second source; did you mean to provide an explicit length? [-Wsizeof-pointer-memaccess]

FIX:

in 2 places find and overwrite

- if (!strncmp(name, ch->name, sizeof(ch->name))) {

+ if (!strcmp(name, ch->name)) {

3rd:

/omni/kernel/lge/hammerhead/net/bluetooth/hci_conn.c: In function 'hci_le_ltk_reply':

/omni/kernel/lge/hammerhead/net/bluetooth/hci_conn.c:406:28: warning: argument to 'sizeof' in 'memcpy' call is the same pointer type '__u8 *' as the destination; expected '__u8' or an explicit length [-Wsizeof-pointer-memaccess]

FIX:

void hci_le_ltk_reply(struct hci_conn *conn, u8 ltk[16])

{

struct hci_dev *hdev = conn->hdev;

struct hci_cp_le_ltk_reply cp;

BT_DBG("%p", conn);

memset(&cp, 0, sizeof(cp));

cp.handle = cpu_to_le16(conn->handle);

memcpy(cp.ltk, ltk, sizeof(cp.ltk));

hci_send_cmd(hdev, HCI_OP_LE_LTK_REPLY, sizeof(cp), &cp);

}
[Android Software/Hacking General [Developers Only]] desalesouche:
if you read a few post above (#804 ) you have another way to fix that i believe?

correct me if i am wrong.

what is best?
[Android Software/Hacking General [Developers Only]] satyr007:
U can disable all warnings without fixing them. -Wno-sizeof-pointer-memaccess -> disables warning. Why not -W flag :>
[Android Software/Hacking General [Developers Only]] mastero9017:
One more question.Is there any toolchain optimized for cortex a15 to compile system?
[Android Software/Hacking General [Developers Only]] satyr007:
U can compile whatever u want :D I suggest sabermod, cause there are no glitches in playstore app.

http://xdaforums.com/showthread.php?t=2098133 -> linaro toolchains
[Android Software/Hacking General [Developers Only]] JustArchi:
There's no such thing as "optimized" toolchain.

Toolchain is optimized for all supported CPUs declared as -mcpu or -mtune.

If you have correct non-brain-damaged build, using "optimized" toolchain over "generic" one doesn't change anything, as -mcpu flag is passed REGARDLESS.

The only thing that "optimized" toolchain does, is making this specific -mcpu flag default, in other words, passing it to every compiled chunk, WHICH IS ALREADY DONE during building AOSP. The only place when it could come useful is the kernel, as kernel uses it's own set of flags, but that doesn't change the fact that you can fix this one as well.

Another placebo that people trust.
[Android Software/Hacking General [Developers Only]] JustArchi:
Official Linaro toolchains (in newest versions from snapshots) are available in my repo, the ones you linked are unofficial self-built. Not even mentioning that these toolchains include only arm-eabi for kernel compiling.

And the fact that SaberMod doesn't have a bug which exists in Linaro, Google's GCC and GCC itself, is not cool, as it indicates that SaberMod is missing something that exists in official GCC. For me this indicates that either SaberMod reverted some official commits or is desynced with the upstream, either way, I don't like it.
[Android Software/Hacking General [Developers Only]] sidneyk:
In building omni, I had to revert back to Google 4.8 tool chains as Sabermod 4.8.4 started not building when I updated my host system which brought in new versions of isl, cloog, gcc 4.9.x that revealed that the Sabermod I was using had dependencies on certain, lower versions of isl, cloog, etc. Neither Sabermod 4.8.4 or Google 4.8 give me the artifacted Playstore icons. I'll get brave and try Linaro again at some point. For the record, my host system is Arch Linux, which is cutting edge up to date rolling release.
[Android Software/Hacking General [Developers Only]] ezio84:
Are those BT and layout issues also noticeable with the first releases of Linaro 4.8 and Google 4.8 (like THIS)?

Thanks.

PS: and thanks JA for your amazing work!
[Android Software/Hacking General [Developers Only]] JustArchi:
Google's 4.8 is fine, I'm using it.

Linaro no clue.
[Android Software/Hacking General [Developers Only]] ezio84:
Thanks, i'll try to use it :)

Another stupid question, about the playstore fix (is it needed for Google's 4.8, right?):

https://github.com/JustArchi/android_external_webp/commit/36c6201fbb108d6b757f860e2cd57f3982191662

I'm compiling Slimkat, and this is the webp line in the default manifest:

<project path="external/webp" name="platform/external/webp" />

So i assume it downloads the webp project from aosp.

Can i change it with the Cyanogen project or your one to apply the commit?

Thanks.
[Android Software/Hacking General [Developers Only]] sidneyk:
Not needed for Google gcc 4.8. Playstore works fine.
[Android Software/Hacking General [Developers Only]] DualJoe:
Which version do you provide exactly there (21Jun)?

To my understanding latest 4.9 is this and 4.8 is this.

1) We still need 4.8 for Android/CM11 or is it possible now to build with 4.9 as well?

2) You build your roms with official Google 'arm-linux-androideabi-4.8' from NDK r10b?

3) Not sure if that's correct but Google doesn't seem to provide a prebuilt 'arm-eabi-' toolchain for kernels. How is it supposed to compile kernels with their toolchains?
[Android Software/Hacking General [Developers Only]] sidneyk:
Google does provide both prebuilt tool chains for 4.8 in their repos. They only have a prebuilt 4.9 for arm-eabi (for kernel). Archi has several prebuilt linaro tool chains in his repos.
[Android Software/Hacking General [Developers Only]] DualJoe:
The other way round. There is only an 'arm-linux-androideabi-4.9' for roms, none for kernels. But yes, i now see the arm-eabi-4.8 in their repo. Probably need to be pulled by NDK dev scripts first...
[Android Software/Hacking General [Developers Only]] sidneyk:
I knew it was one or the other, didn't have it in front of me.
[Android Software/Hacking General [Developers Only]] albertusac:
Which type I should choose for SlimKat?
[Android Software/Hacking General [Developers Only]] seadersn:
i'll try omnirom commits first on slimkat. omnirom is more optimized than cm (at least for g2) so i think this is a good base to start with :)
[Android Software/Hacking General [Developers Only]] ezio84:
https://github.com/Minux31/android_build/commit/0e23553f272d0060bc45666ca710272cdea66ef2
[Android Software/Hacking General [Developers Only]] JustArchi:
Check commits, I always write the date or the release of specific toolchain in latest commit.

https://github.com/ArchiDroid/Toolchain

I'm not building ANY of these toolchain myself. All of them come either from a valid release, or from daily snapshot.

AOSP comes from official Google's AOSP repo. NDK comes from Google's NDK, while Linaro varies between daily snapshots and release, depending what is newest at the moment.

And ArchiDroid is at the moment built with AOSP's 4.8. Check this to learn why.
[Android Software/Hacking General [Developers Only]] WhoDunnit:
Thank you for this patch. Seems to do it's magic out of the box. I compiled cm11 for i9300 with this and Google toolchains 4.8 and it seems to work well, only some xbin apps like su are not compiled or included in the final zip. I don't see any problems in the compile logs. Is there see something I overlooked?

Thanks.
[Android Software/Hacking General [Developers Only]] JustArchi:
Yep, you built user variant, and it doesn't have su by default.

https://github.com/ArchiDroid/android_vendor_cm/commit/bdb6e0438974926c6ca3c6dead0f8f47ba04ff9d

https://github.com/ArchiDroid/Superuser/commit/10761b121dd10400bf8ae3a0278427923eb87e24
[Android Software/Hacking General [Developers Only]] desalesouche:
02 vs 03

@ JustArchi

hi all...

Now the battle is, O2 or O3? This is tough choice, here are some facts:

1. Kernel compiled with O2 has 4902 KB, with O3 4944 KB, so O3 is 42 KB bigger.

2. ROM compiled with O3 is 3 MB larger than O2 after zip compression. Fast overview: 97 binaries in /system/bin and 2 binaries in /system/xbin + 283 libraries in /system/lib and other files, about 400 files in total. 3 MB / 400 = 7,5 KB per file size increase.

with theses commits from mokke os build folder the problem is "solved"... i mean png crusher reduce the size of rom...

https://github.com/DESHONOR/android_build/commit/c54ce9366d1e9fff81dd4a0532a3d21b1e09ae20

https://github.com/DESHONOR/android_build/commit/f8c5342d9992f16f09fdd107501ce3977aaf8e31

https://github.com/DESHONOR/android_build/commit/1c9156a794caf4eee823a111740ff45bb997e994

you have to install pngcrusher from terminal: "sudo apt-get install pngquant"

then in terminal cd in cm sources and do "chmod 777 build/tools/releasetools/pngcrusher"

then build ...

see screenshots with before and after pngcrusher:

before: http://www.mediafire.com/view/3ax3o882o3r3v16/archi cm build b4 png.png#

after: http://www.mediafire.com/view/j2xl2wwa4jzzxb0/archi cm after pngcrusher.png#
[Android Software/Hacking General [Developers Only]] desalesouche:
cm change and archi...

what about that commit cm did?

https://github.com/CyanogenMod/android_build/commit/8907b775376211e73a566e8c9ef65e5b76cba1af

i did cm build with linaro_4.9.1 ---> nothing special

i did a cm build with gcc linaro_4.9.2 and that commit.-----> nice speed ...

i did a cm build with archi v3 optimization + recent above cm commit.---- i didn't notice special more = about same speed and fluidity.

what about you guys?
[Android Software/Hacking General [Developers Only]] GeyerA:
Hi Archi,

I picked your V3 optimisations https://github.com/GeyerA/android_build/commit/a389c6d79a91e5e0a8b98121e449acbb0e887643 and build my AOSP ROM but got compilation errors. So I changed the -O3 to -Os as described in the core/combo/TARGET_linux-arm.mk which then built just fine. What is the impact from -O3 to -Os? Is there anything else to get it build with -O3? BTW, I use googles gcc 4.8. Thanks!
[Android Software/Hacking General [Developers Only]] Lazy79:
You need to post the build error. I guess it should be easy to solve when you're using this toolchain. Some here have already experiences in making the source -O3 ready. ☺
[Android Software/Hacking General [Developers Only]] k2wl:
where are the toolchains on github???

i cant find one.