[Q] Native ARM Compiler - Android Q&A, Help & Troubleshooting

Hello every xda members,
I have some little questions,
Is there anyone who have a working native toolchain (binutils, gcc, newlib) that I can run under my Android Phone to build binaries directly under the phone using a terminal ?
Is there any other way to program/compile applications/binaries directly on the phone ?
I want to develop on the phone without any computer.
Thanks for your help

I was wondering the same. Found this:
specificimpulses.blogspot.com/2011/01/my-android-speaks-fortran-yours-can-too.html for building fortran natively, I think. Shouldn't be much different. Gcc is a bear to compile, at least as of 3.3.1(last time I built a cross compiler)

Here you go....
First one is ndk r23b aarch64 I built paralloid and its static busybox using this(after modifying paraloids build script a bit) I have only used it within a debian chroot, so I know it works outside termux environment. also has x86_64 toolchain alongside aarch64
GitHub - lzhiyong/termux-ndk: android-ndk for termux
android-ndk for termux. Contribute to lzhiyong/termux-ndk development by creating an account on GitHub.
github.com
I have never used this one, but It may be relevent, its the r21e ndk(r23b has bugs, this may work around)
EDIT:This r21e ndk just built the static busybox for aarch64 where r23b would only build armv7a also this one seems to have the 4.9 binaries in all archs!
GitHub - zaharchenko-main/termux-ndk: android-ndk for termux
android-ndk for termux. Contribute to zaharchenko-main/termux-ndk development by creating an account on GitHub.
github.com
Just noticed I answered this a decade late.
Leaving more native devel tools for my future reference...
Building arm64-v8a ndk toolchain to run on device
Now I know I've done this before. But I think I had to make an entire Application.mk file. I am trying to use either the Windows or Linux NDKr19 to build a standalone toolchain that contains ONLY the arm64 executable binaries. (essentially...
forum.xda-developers.com

Androw said:
Hello every xda members,
I have some little questions,
Is there anyone who have a working native toolchain (binutils, gcc, newlib) that I can run under my Android Phone to build binaries directly under the phone using a terminal ?
Is there any other way to program/compile applications/binaries directly on the phone ?
I want to develop on the phone without any computer.
Thanks for your help
Click to expand...
Click to collapse
@Androw
Prior to your next posting please read the guidances that are stuck on top of every forum like
[ATTN] : Read before posting - Any questions posted here will be MOVED or CLOSED
Please read the below before posting. Any questions not development related will be moved or closed. Forum Searching | Posting | The Basics: (Make sure you've read them before starting a new thread) Forum Rules Forum Search Google Forum...
forum.xda-developers.com
I've moved the thread to Q&A.
Regards
Oswald Boelcke
Senior Moderator

Related

[Q] Android Sycall Interception

Hi,
Could someone please tell me how I could intercept all the syscalls while the phone is running?
I build the kernel from source code, and load it on the Nexus S 4G device, and I have already compiled a syscall interception module for Ubuntu. But, I do not know how a syscall interception LKM would look like for android, and how it could be incorporated into the kernel's source code to be compiled automatically when the kernel is built.
Would someone please help?
::Saman
Please use the Q&A Forum for questions Thanks
Moving to Q&A

Mixing-in neon in armv6 builds

I build for regular armeabi with -march=armv6, but in my project I have some neon optimized code and I enable that code at run-time after checking if the cpu supports neon. The app obviously has to run on older devices as well.
So, how the hell am I supposed to do that simple task with android crappy build?
I can't specify extra c-flags for some files. To build for neon with this crapware you absolutely have to enable armeabi-7a which means that compiler if free to generate armv6t2 or armv7 instructions, which means that binary might sigill on older devices. The only way for me do that simple task is to build neon asm manually and use the static lib in the main armeabi project.
Seriously, is android build one more example of ridiculous crapware made from regular makefiles so that you can't actually do normal makefiles anymore? Is there official android forum, where I could ask that question from them, or it's also disfunctional?
thanks
Please use the Q&A Forum for questions &
Read the Forum Rules Ref Posting
Moving to Q&A

[Guide][CM]Where did it go? Android compile differences from ROMs.

UNDER CONSTRUCTION
I present you, the guide to locations in Android source in comparison to compiled ROMs.
You can of course also look this up in makefiles
I've tried to divide it into easy categories.
folders/apps
frameworks/base/core --> /system/framework/framework-res.apk
frameworks/base/policy --> /system/framework/policy.jar
frameworks/base/packages/System-UI --> /system/priv-app/SystemUI.apk
packages --> most of system/app
excluded from that: Development.apk, DocumentsUI.apk, PacProcessor.apk, PicoTts.apk, Term.apk, ThemeChooser.apk, WAPPushManager.apk, WhisperPush.apk
files
Changes to the setup
files in here are imported and used along the files your device tree specifies. Changes for all devices can therefor best be made to:
vendor/cm/config
You can change toolchains in envsetup.sh which is in build.
This commit changes the inline kernel toolchain to the 4.7 GCC Linaro toolchain.
https://github.com/TeamFun/android_build/commit/73b914051a03afd81ad8ccaf39058aa6ae5af4ea
Toolchains used for compiling ROM components are supposed to be in "prebuilts/gcc/linux-x86/arm"
If you want to contribute to this, put the info in here:
https://docs.google.com/document/d/1zun26nTWR7p54-SAP0Ol5oPX8bC4QjL9z3tm-Gz7UF8/edit?usp=sharing
Shoot me a PM and I'll make sure to put it in the guide.
You know you can write as "OP in Construction" so that there will not be any useless replies or questions
You know as this is the original Development section
Users do go mad over incomplete threads.
Just thought I do help you
Venomous Viper 119 said:
@ OP : Just PM to eagleeye uncle . He'll move it for you
Sent from my GT-S5830 using xda premium
Click to expand...
Click to collapse
That wouldn't get you anywhere as he isn't a moderator for Samsung forums.
You should PM either myself, andyharney or efrant as we are the most active moderators for Samsung International forums. Or use the report button and whichever one if us is online will deal with it.

[Q][i545] Adding Driver Modules to Kernel

Ok now I dont concider myself a developer, however I dont mind getting my hands dirty. First of all Im sure that its not dependant on being a Verizon Varient S4, however that's the device I have and would like to do this for. I will be making a git to comply with the GPL and will hope to make a guide for XDA.
Now I've done alot of research regarding this topic, not just for Android specifically, but Linux in general. Before I go flashing Kernels on my device I want to make sure I fully understand the process which is where you guys can help me out. My goal is to add a Wireless driver module to my s4.
1. Set up build environment
- I will be using Ubuntu 12.04 LTS as my build environment
- Install all dependencies required to compile the kernel
- Download Android NDK and SDK (NDK for toolchain/SDK for adb and fastboot)
- Make working directory
2. The wireless drivers should be in the kernel, if not grab them from kernel.org (compat-wireless)
- Creat Makefile for ath9k (the drivers I plan on testing)
- config and make the ath9k.ko
3. Compile Kernel
- Compile the Kernel (cross-compile with toolchain of course)
- Create Flashable zip with the zImage and the ath9k module
4. Flash and insmod
- Flash kernel through recovery
- Either run insmod /path/to/module/ath9k.ko or create a bash script
- Use my USB device
- Either rmmod ath9k or create bash script
So now my question is would this be the correct procedure?
bump
well, this thread makes me curious as hell whether or not you can mod the kernel to do this.
Moving to I545 Q/A forum.

[Q&A] [SOURCE] Cyanogenmod Source Highly Compressed

Q&A for [SOURCE] Cyanogenmod Source Highly Compressed
Some developers prefer that questions remain separate from their main development thread to help keep things organized. Placing your question within this thread will increase its chances of being answered by a member of the community or by the developer.
Before posting, please use the forum search and read through the discussion thread for [SOURCE] Cyanogenmod Source Highly Compressed. If you can't find an answer, post it here, being sure to give as much information as possible (firmware version, steps to reproduce, logcat if available) so that you can get help.
Thanks for understanding and for helping to keep XDA neat and tidy!
Special Thanks
I really wanna thank you for this impressive favor that you did , because I really stuck with such stupidly bad internet speed.
thanks alot
Edit: Sorry about this post because its not a question
Need help!
Can anyone make a tutorial how to build for a specific device using compressed source ..
chendur1212 said:
Can anyone make a tutorial how to build for a specific device using compressed source ..
Click to expand...
Click to collapse
Read this first:
http://wiki.cyanogenmod.org/w/Development
In short->
- Extract the compressed sources and cd from terminal into their folder.
- Run these commands:
Code:
source build/envsetup.sh
breakfast <device codename>
cd android/system/device/<vendor name>/<device codename>
./extract-files.sh
brunch <device codename>
Here "<vendor name>" is name of vendor for your phone and <device codename> is ... well, your device codename.
For example, for building for nexus 4 (vendor = lge (commonly known as LG), codename = mako), the commands would be:
Code:
source build/envsetup.sh
breakfast mako
cd android/system/device/lge/mako
./extract-files.sh
brunch <device codename>
Also, this implies that official Cyanogenmod exists for your device. If it doesnt, then you will have to follow a porting tutorial instead (which is much more complex and judging, you would need to learn much more stuff like building kernels, decompiling their ramdisks, debugging etc).
Go here if anybody still reading this. Thanks. http://forum.xda-developers.com/showthread.php?t=3231109
Sent from my ONE A2003 using Tapatalk

Categories

Resources