Trying to build LOS 14.1 from source with OMS support for Nexus 6P; failing miserably - General Questions and Answers

Okay, maybe not failing miserably, but the actual building is failing about five minutes in. I've never even used github before this, let alone considered compiling from source, so I may have messed up anywhere. In all honesty I'm posting this here to find out if there's a better, more specific place I might get help with this issue.
Trying to compile LineageOS 14.1 with Substratum support for Nexus 6P (Angler). I've been primarily following this guide from the wiki, with instructions to add Substratum support from this thread (section 4, "use the provided local manifest") and the section from this guide about adding in the proprietary files (./extract-files.sh wasn't working and I never did figure out why, but I have a feeling it's related).
I'm doing this in a brand-spanking-new install of Ubuntu 16.04.03 inside Oracle VM, running on Win10 64bit. I've got 8GB of RAM and I thought Jack might have been running out; the VM gets 6 and Jack gets 5. Didn't help. I'm not 100% certain if this is what you're looking for but this link contains an exact transcript from my terminal, where I run these exact commands in this exact order from ~/android/lineage
Code:
repo sync
source build/envsetup.sh
breakfast angler
croot
brunch angler
I'm utterly bloody lost so hopefully I've made a clear, easy mistake. Knowing my personal record, I probably managed to corrupt the process from the start. Unending thanks to anyone who can even point me in the right direction.

did you figure this out?
404 on your link, but i know when i started building roms with Jack i had to limit jack process to 2 or i'd get out of memory errors.
---------- Post added at 01:32 AM ---------- Previous post was at 01:32 AM ----------
did you figure this out?
404 on your link, but i know when i started building roms with Jack i had to limit jack process to 2 or i'd get out of memory errors.

Related

[GB DEVICE TREE] HeroC Device Tree for Gingerbread

I have posted a device tree for Gingerbread for the HeroC. This has not had a lot of mileage, so don't expect that it will be at the level of AOSPs builds, but is a starting point for those who would like to build their own GB Roms.
Credit for this should go to those who did the REAL work, such as AOSP, Lox, Elemag, Darchstar, Cyanogen, and a host of others.
My contribution was just the assembly and cleanup of the existing efforts of others.
Still plenty of issues that need working on, and not sure how much time I will have to devote to moving this forward. I have tried to make it fairly self contained, with enough information to get folks started. I will not be able to provide much support, but I am making it available in the event that it is of interest.
Special thanks to AOSP for a working ROM to look at and learn from, and appreciation for some files and info that I shamelessly kanged from his build. Also thanks to Lox and Elemag for their hero device tree which also provided some significant pieces of the puzzle.
Good luck, thanks for the community, and please continue to help each other.
You can get the device tree from github by:
git clone git://github.com/wjb/android_device_htc_heroc_gb.git
README
Basic steps to build:
1 - Get local copy of CM7 repository
2 - Get copy of the device tree into device/htc/heroc
3 - Copy modified files from 'device/htc/heroc/buildmods' to proper directories:
a) definitions.mk into 'build/core' (Temporary fix for boot.img size issue)
b) vendorsetup.sh into 'vendor/cyanogen' (Add lunch combo)
c) prelink-linux-arm-heroc.map into 'vendor/cyanogen' (Map library locations)
d) AndroidProducts.mk into 'vendor/cyanogen/products' (Add cyanogen_heroc product)
e) cyanogen_heroc.mk into 'vendor/cyanogen/products' (Add cyanogen_heroc makefile)​4 - Run get-rommanager in vendor/cyanogen directory
5 - Get proprietary files into 'vendor/htc/heroc/proprietary'
a) Put ROM (update.zip) in repo root and run 'unzip-files.sh' from the 'device/htc/heroc' directory
b) Use 'adb' to pull files from usb connected device by running 'extract-files.sh'
c) Copy files from expanded system directory on your local machine by running 'copy-files.sh'
d) Copy files from 'device/htc/heroc/proprietary' directory (also needs 'setup-makefiles.sh')​6 - Setup build environment by sourcing envsetup file '. build/envsetup.sh'
7 - Run 'lunch' to select the build target 'lunch cyanogen_heroc-eng'
8 - Build the system with make, mka, etc.
Save for Updates
gingerbread futures
downloading does it compile witch working cam sensors etc.
aaronpoweruser said:
downloading does it compile witch working cam sensors etc.
Click to expand...
Click to collapse
It does compile and build a working ROM, including camera, gps, compass, wifi, etc.
If you have built other ROMS, this should be very straightforward. If not, follow standard guides for setting up and configuring your build environment.
Whoa jaybob, you're working on GB now?
Oh hell yes. Your updating of themes made CM6 the Goliath(sp?) I loved.
Welcome from the coldness that is frozen yogurt, and into the warmth of gingerbread.
Wait, let me clarify here, jaybob, are you going to put out new builds of CM7 as it comes out, in the same way you were before? I found yours to be of far higher quality than the nightly/stable releases.
Repo Update
Updated the repo to eliminate conflicts with 'lunch' for makefiles included in the buildmods directory.
Also added the quick and dirty 'install-buildmods.sh' script to copy the files from buildmods to the appropriate directories. Executing this script from the buildmods directory takes care of the copy actions indicated in step 3.
LiquidSolstice said:
Wait, let me clarify here, jaybob, are you going to put out new builds of CM7 as it comes out, in the same way you were before? I found yours to be of far higher quality than the nightly/stable releases.
Click to expand...
Click to collapse
ATM, I am just working on getting an environment that will let me build from source as it continues to develop. Without a device tree that works, there was not much I could do.
As things progress, I may put out CM7 builds, but I am still a ways from that point. I am starting to look at the TMO Theme Chooser approach to building installable themes. This would produce themes that are independent of the ROM, which would probably end up being a lot easier than the 5 separate builds that I produced for CM6.
I have only been playing with this for a couple days so far. Fortunately, there was a lot of other development efforts to leverage. I will continue to move this forward as my time and interest allows.
jaybob413 said:
ATM, I am just working on getting an environment that will let me build from source as it continues to develop. Without a device tree that works, there was not much I could do.
As things progress, I may put out CM7 builds, but I am still a ways from that point. I am starting to look at the TMO Theme Chooser approach to building installable themes. This would produce themes that are independent of the ROM, which would probably end up being a lot easier than the 5 separate builds that I produced for CM6.
I have only been playing with this for a couple days so far. Fortunately, there was a lot of other development efforts to leverage. I will continue to move this forward as my time and interest allows.
Click to expand...
Click to collapse
Awesome, really liked your past work.
jaybob413 said:
ATM, I am just working on getting an environment that will let me build from source as it continues to develop. Without a device tree that works, there was not much I could do.
As things progress, I may put out CM7 builds, but I am still a ways from that point. I am starting to look at the TMO Theme Chooser approach to building installable themes. This would produce themes that are independent of the ROM, which would probably end up being a lot easier than the 5 separate builds that I produced for CM6.
I have only been playing with this for a couple days so far. Fortunately, there was a lot of other development efforts to leverage. I will continue to move this forward as my time and interest allows.
Click to expand...
Click to collapse
Take your time. The work you do is quality stuff.
Thanks for this! Worked great, once I actually read the "also needs 'setup-makefiles.sh'" part and ran it. For whatever reason Gallery3D didn't get built, but I just downloaded it from the market. Everything else works as expected!
Worked great! Thanks for your efforts.
Sent from my HERO200 using XDA App
Repo Update
Updated kernel, wlan.ko, and additional loadable kernel modules after kernel rebuild to add scaling_available_frequencies virtual file needed by CPU settings.
Added libspeech.so to proprietaries, and minor build config changes.

[Q] Android JNI problem. Bad build tools?

Hello, XDA. This is my first post.
Before I start out looking like I'm helpless, and keeping with the mindset that I don't expect something for nothing, I've spent the time to write up newbie-friendly guides:
(edit: Apparently, I have to make eight posts before I can post external links) I will probably accumulate eight posts in this thread, and will edit this at that point.)
Adding OpenVPN and liblzo to the AOSP source tree and compiling a kernel to support it. Includes instructions for patching OpenSSL1.0.0a to enable engine support.
Wrangling with USB permissions
Making a custom boot animation from an animated gif
If it would be better to have the content located on the forum somewhere, tell me where it ought to go.
My problem:
I am trying to roll my own ROM from AOSP (Gingerbread 2.3.4). I have been successfully building images and even kernels for the Nexus S for several weeks now. Recently, I broke something.
I've beat my head against this for three days now. I think I read the entire internet before posting here. I think there is a problem with my build tools, but I don't know where I should be looking for it, or how to test it. The problem is not in the AOSP source tree. I know this because I checked out a clean copy of it, followed Google's instructions, and I get the same result. I get the same result in both the emulator, and on the Nexus S.
When I launch the browser, this is the output from logcat:
(edit: Wow... the parser that tells me I can't post URLs is so aggressive, that I can't paste my logcat output either... I have base64 encoded it instead.)
Code:
SS9BY3Rpdml0eU1hbmFnZXIoICAgNjYpOiBTdGFydCBwcm9jIGNvbS5hbmRyb2lkLmJyb3dzZXIg
Zm9yIGFjdGl2aXR5IGNvbS5hbmRyb2lkLmJyb3dzZXIvLkJyb3dzZXJBY3Rpdml0eTogcGlkPTM1
NyB1aWQ9MTAwMjEgZ2lkcz17MzAwMywgMTAxNX0NCkkvQWN0aXZpdHlUaHJlYWQoICAzNTcpOiBQ
dWIgYnJvd3NlcjogY29tLmFuZHJvaWQuYnJvd3Nlci5Ccm93c2VyUHJvdmlkZXINCkkvQnJvd3Nl
clNldHRpbmdzKCAgMzU3KTogU2VsZWN0ZWQgc2VhcmNoIGVuZ2luZTogQWN0aXZpdHlTZWFyY2hF
bmdpbmV7YW5kcm9pZC5hcHAuU2VhcmNoYWJsZUluZm9ANDA1OTU4Yzh9DQpEL2RhbHZpa3ZtKCAg
MzU3KTogR0NfQ09OQ1VSU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WRpZD0xOiB0aHJl
YWQgZXhpdGluZyB3aXRoIHVuY2F1Z2h0IGV4Y2VwdGlvbiAoZ3JvdXA9MHg0MDAxNTU2MCkNCkkv
UHJvY2VzcyAoICAzNTcpOiBTZW5kaW5nIHNpZ25hbC4gUElEOiAzNTcgU0lHOiA5
At first, I thought maybe it was some setting specific to the browser. But then I tried another application that also calls native libraries (CSIPSimple). Whenever CSIP tries to load native libraries, I see something like this:
Code:
RC9kYWx2aWt2bSggIDQyOCk6IFRyeWluZyB0byBsb2FkIGxpYiAvZGF0YS9kYXRhL2NvbS5jc2lw
c2ltcGxlL2xpYi9saWJwanNpcGpuaS5zbyAweDQwNTEzNDg4DQpFL1BqU2VydmljZSggIDQyOCk6
IFdlIGhhdmUgYSBwcm9ibGVtIHdpdGggdGhlIGN1cnJlbnQgc3RhY2suLi4uIE5PVCBZRVQgSW1w
bGVtZW50ZWQNCkUvUGpTZXJ2aWNlKCAgNDI4KTogamF2YS5sYW5nLlVuc2F0aXNmaWVkTGlua0Vy
cm9yOiBDYW5ub3QgbG9hZCBsaWJyYXJ5OiByZWxvY19saWJyYXJ5WzEzMTVdOiAgICAzMiBjYW5u
b3QgbG9jYXRlICdfX2Rzb19oYW5kbGUnLi4uDQpFL1BqU2VydmljZSggIDQyOCk6IA0KRS9QalNl
cnZpY2UoICA0MjgpOiAJYXQgamF2YS5sYW5nLlJ1bnRpbWUubG9hZChSdW50aW1lLmphdmE6Mzk0
KQ0KRS9QalNlcnZpY2UoICA0MjgpOiAJYXQgamF2YS5sYW5nLlN5c3RlbS5sb2FkKFN5c3RlbS5q
YXZhOjUzNCkNCkUvUGpTZXJ2aWNlKCAgNDI4KTogCWF0IGNvbS5jc2lwc2ltcGxlLnBqc2lwLlBq
U2lwU2VydmljZS50cnlUb0xvYWRTdGFjayhQalNpcFNlcnZpY2UuamF2YToxMTkpDQpFL1BqU2Vy
dmljZSggIDQyOCk6IAlhdCBjb20uY3NpcHNpbXBsZS5zZXJ2aWNlLlNp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QpDQpFL1BqU2VydmljZSggIDQyOCk6IAlhdCBq
YXZhLmxhbmcucmVmbGVjdC5NZXRob2QuaW52b2tlKE1ldGhvZC5qYXZhOjUwNykNCkUvUGpTZXJ2
aWNlKCAgNDI4KTogCWF0IGNvbS5hbmRyb2lkLmludGVybmFsLm9zLlp5Z290ZUluaXQkTWV0aG9k
QW5kQXJnc0NhbGxlci5ydW4oWnlnb3RlSW5pdC5qYXZhOjgzOSkNCkUvUGpTZXJ2aWNlKCAgNDI4
KTogCWF0IGNvbS5hbmRyb2lkLmludGVybmFsLm9zLlp5Z290ZUluaXQubWFpbihaeWdvdGVJbml0
LmphdmE6NTk3KQ0KRS9QalNlcnZpY2UoICA0MjgpOiAJYXQgZGFsdmlrLnN5c3RlbS5OYXRpdmVT
dGFydC5tYWluKE5hdGl2ZSBNZXRob2Qp
Are there any veteran android devs that can point me in the correct general direction? I don't need to have my hand held, but having never written any app more complex than HelloWorld, I'm not sure where to begin debugging.
edit: As long as I'm thwarting the parser with Base64, here are the external links I am not supposed to be able to post. I hope it helps someone. Figuring all that out was a lot of work.
Code:
W0xJU1RdDQpbKl1bVVJMPSJodHRwOi8vd3d3Lmpvc2hpYW5saW5kc2F5LmNvbS9pbmRleC5waHA/
aWQ9MTEzIl1BZGRpbmcgT3BlblZQTiBhbmQgbGlibHpvIHRvIHRoZSBBT1NQIHNvdXJjZSB0cmVl
IGFuZCBjb21waWxpbmcgYSBrZXJuZWwgdG8gc3VwcG9ydCBpdC4gSW5jbHVkZXMgaW5zdHJ1Y3Rp
b25zIGZvciBwYXRjaGluZyBPcGVuU1NMMS4wLjBhIHRvIGVuYWJsZSBlbmdpbmUgc3VwcG9ydC5b
L1VSTF0NClsqXVtVUkw9Imh0dHA6Ly93d3cuam9zaGlhbmxpbmRzYXkuY29tL2luZGV4LnBocD9p
ZD0xMTIiXVdyYW5nbGluZyB3aXRoIFVTQiBwZXJtaXNzaW9uc1svVVJMXQ0KWypdW1VSTD0iaHR0
cDovL3d3dy5qb3NoaWFubGluZHNheS5jb20vaW5kZXgucGhwP2lkPTExMSJdTWFraW5nIGEgY3Vz
dG9tIGJvb3QgYW5pbWF0aW9uIGZyb20gYW4gYW5pbWF0ZWQgZ2lmWy9VUkxdDQpbL0xJU1Rd
Thanks in advance for any help you are willing to give.

[DevTOOL][2012-10-01] Fast AAPT (#2) - Speed up Eclipse/apktool/etc

Presenting: Fast AAPT - aka FAAPT
Lately Android development has been getting me down. Slow builds all over the place in many of my app projects, and my PC is blazing fast - it shouldn't all be that slow, even if you're running Eclipse!
Working on DSLR Controller has been driving me mad - testing a minor change in the underlying communications library, then building and launching the app - ugh! So I set out to fix this. I had done all the usual tricks, even gave Eclipse loads more memory (helped with regular performance, but not building) but nothing major seemed to change. Then I figured out most of the time building was spent in AAPT. So I synced my AOSP repo (2012.09.26, took a few minutes), tried to get the Windows SDK to build on my Linux box (took several hours) and finally got to actually mucking with the source.
Found the bottleneck (for my long-build-time projects at least, related to XML file compilation) and fixed it (by introducing a simple cache). "DLSR Controller" build time has gone down from 35 seconds minimum, to 2-3 seconds ( >10 times faster). Hell, I can even turn "Build Automatically" back on without getting constant delays!
Note that my build times quoted only apply to incremental internal builds. If your images still need to be "crushed" (optimized), or you're "exporting" an APK (final build for publication), build time will still be significantly longer. However, during normal development and testing (by far most builds if you're making an app in Eclipse) those stages are not performed, and builds should be lightning fast.
"Fixed" is a big word though, right now it's more of a "hack", and it needs some pollish, so the patch can be submitted to AOSP. I don't want to keep it from you for that long, so my first test build is attached - don't use it in production builds..
Patch code has been submitted to:
AOSP - #1 Cancelled, #2 Review in Progress ... superseded by ctate rewrite
AOKP - #1 Merged, #2 Merged
CM - #1 Cancelled, #2 Merged
Attached ZIP includes Linux, Windows and Mac OS X versions.
The files are drop-in replacement, but I would certainly advise you to backup the originals for your production builds! Also, don't forget to chmod/chown on Linux or it won't work.
Enjoy and leave some feedback
Will this help your project build ?
A quick way to spot if this will have effect on your slow build is as follows:
- In Eclipse, set Build output to Verbose under Window -> Preferences -> Android -> Build.
- Clean and build your project.
- If the build pauses on lines in the "(new resource id <filename> from <filename>)" format, you have the problem FAAPT fixes
(of course, you can also run aapt manually if you know how, you'll get the same output)
In a full framework build the optimizations only affect a very small portion of the actions done during the build, so you won't see any spectaculair speed increases there.
Update (#2)
I have updated the patch code to fix problems with Mac OS X compatibility, I've also included a Mac OS X binary in the new zip file.
-----
( v1: 557 )
So that's what's been killing the speed of my eclipse then. It froze so often I had to switch to AIDE on my phone. Hopefully this'll speed it up a little
Sent from my Galaxy Nexus using Tapatalk 2
Awesome work Chainfire, will play around with this in a few
Thanks brother, gonna give it a try right now on Linux
EDIT:
It works. Gave it three tries. Went consistently around 19.1 sec with FAAPT and 33.9 sec with regular AAPT. This is on the Linux version. Good job
Amazing work. Handles large resources like framework-res a lot faster.
wildstang83 said:
Thanks brother, gonna give it a try right now on Linux
EDIT:
It works. Gave it three tries. Went consistently around 19.1 sec with FAAPT and 33.9 sec with regular AAPT. This is on the Linux version. Good job
Click to expand...
Click to collapse
Glad to hear the Linux version also works! Too bad your increase is not as much as mine, but I guess it depends heavily on the amount and type of assets in your project.
Chainfire said:
Glad to hear the Linux version also works! Too bad your increase is not as much as mine, but I guess it depends heavily on the amount and type of assets in your project.
Click to expand...
Click to collapse
I tested on a theme project of mine, so its heavy in img files. Thats probably why. I'm not complaining one bit. Absolutely love it and can't wait to try it out on my other apps
Chainfire said:
Glad to hear the Linux version also works! Too bad your increase is not as much as mine, but I guess it depends heavily on the amount and type of assets in your project.
Click to expand...
Click to collapse
Indeed, tested the Windows version and yes it gives a very good result with a amount of assets, i got 7 time faster than the normal one on Eclipse, too bad we can't use it for production, we need one for Apktool .
wanam said:
Indeed, tested the Windows version and yes it gives a very good result with a amount of assets, i got 7 time faster than the normal one on Eclipse, too bad we can't use it for production, we need one for Apktool .
Click to expand...
Click to collapse
Actually, I was using it with APKTool.
Thanks CF.
Decompiling recompiling now is so fast
apktool and Maps.apk on Linux.
aapt - 29.2s to compile
faapt - 2.2s to compile
Amazing job, Chainfire!
Tested both in linux and winz....
It works great!
Untested time but noticeble faster.
What's the next step after elite rec dev for chainfire?
Thanks for the great work!
Could you post your tweaked source file(s)?
Would like to compile from source for OS X..
On my projects I see anywhere from 5 to 20x speed increase on build. Thank you for this magic.
I don't get how the google android SDK team did not optimize this (I know they done some crazy optimizations for different stuff).
Yeah, could you post your patch?
berdon said:
Yeah, could you post your patch?
Click to expand...
Click to collapse
He did say in the OP. He had to clean it up for AOSP inclusion, so just wait till you see it on Gerrit
Sent from MIUIAndroid Phone.
That is good stuff. It's gonna save me a whole lot of time. The thanks button was just not enough to thank you!
Thanks for the great work Chainfire.
Whoa! Now I will surely stop cursing while waiting for xenoAmp tu build (just not enough time to say "kurwa!")! Thank you!
I'am using ArchLinux x64 as my normal desktop OS. (Yes, I don't have Windows.) and tried it with Eclipse, but it don't work.

[Q] Cherry Picking from Gerrit and Github!

I've read a multitude of guides (i have read gitref as well) on this but I still don't really understand. I've built aosp hammerhead from source. For example, I want to add these to my aosp build:
https://github.com/AOKP/frameworks_base/commit/e6613af24e7b5551ee08d69c87177aebd28bf510
https://github.com/AOKP/frameworks_base/commit/5914039a2a9e5d9b3711e132c50816ad0ed82d6a
https://github.com/AOKP/frameworks_base/commit/e4ad05262a3012f55065369418b0abe1e1d89099
https://github.com/AOKP/frameworks_base/commit/32ece6ce7d4ea3adb1155474246579d6d2d38bea
https://github.com/AOKP/frameworks_base/commit/c2e1006adb05b80686be3a9b4f0d90d0072e60c6
So I remote added https://github.com/AOKP/frameworks_base and then tried to cherry pick using the commit numbers. I'm guessing i have to start with part 1/5 and that gives me fatal: bad revision 'e6613a'. :crying:
If anyone can explain this to me really simply that would be great.
EDIT: Okay, I realized what i was doing wrong. I was supposed to use git fetch first in order to cherry-pick from the repository. On the other hand, it is now giving me Conflicts:
core/java/android/provider/Settings.java
packages/SystemUI/res/layout-land/status_bar_recent_panel.xml
I was wondering if I could just delete my files for those and just replace it with aokp's. Would this be fine?
Thanks in advance,
Darth Yoshi

Wayland server for Android

ABANDONED
Hi! Does anyone here use Linux desktop distributions in chroot environment on Android device?
I am developing wayland protocol server for Android devices. If anyone is interested in checking my project, latest version of apk is always available here:
ftp://ftp.drivehq.com/mogryph/sparkle/
Currently I am only focused on running Xwayland as client. Also apk supports audio output.
Simplest instruction:
1. Android 6 or newer required, busybox required, root required
2. Prepare linux distribution in directory, image or on partition. Make sure you have Xwayland installed in it. Make sure you specify which DE to run (or at least xterm) in ~/.xinitrc
3. Install and start sparkle.apk
4. Press "edit user.sh", uncomment (remove #) line starting with start_generic_container. Change rest of this line to match your device:
first arg - image or partition where distribution is installed. If distribution is installed in directory and mouting is not needed, leave this arg unchanged.
second arg - mount point or directory with distribution. If you use mounting (first arg), this arg can be left unchanged.
third arg - name of the user which will be used to start Xwayland and DE. Its better to specify non-root. Also this is the user who must have .xinitrc in his home dir (see step 2).
5. Save user.sh and click "Start".
6. Any problems and crashes will be reflected in the log.
If you want audio output:
1. Compile and install driver from pcm_sparkle.tar.gz in your distribtion
2. cp 1.asoundrc ~/.asoundrc
If you have blinking problem, change upload_mode from 1 to 2 in settings. If you have bad performance, setting no_damage to true may help, but in most cases no_damage=false is better. Fastest upload mode is 0 (if it works).
If you don't trust me and don't want to give sparkle root permissions (I perfectly understand this) you don't have to. Also you can do without busybox.
But in this case, you need to understand and do a lot of things. Check sparkle's user.sh to get idea about what needs to be done. Basically:
1. You need to make /data/data/com.sion.sparkle/files accessible from inside chroot container. You can use bind bound.
2. Make sure you have tmpfs mounted over /tmp in container.
3. You may need to change selinux context on /tmp to match sparkle's context or disable SELinux.
4. You need to create new directory in /tmp, symlink sparkle's wayland socket from /data/data/com.sion.sparkle/files/wayland-0 to this dir. And export XDG_RUNTIME_DIR to point to this dir. Dir must be (ch)owned by user who will be running Xwayland and DE.
5. After all this, you can try to start Xwayland and your DE.
new version
New version
rgho.st/8Fbz64Rxj
Added x86 and x86_64 support. Actually it is rewritten almost from scratch but x86 support is the only thing others can notice...
Hello! This project is interesting. I tried you app and it works on my Xiaomi Redmi Note 4X(chromium and glmark from chrooted environment works very well)! Can you publish source code on Github, because it really interesting project?
Also I'm interested, please post it on github!
Did you put this up on github or move this thread? Looks very interesting.
1
Argh, sorry, I decided to abandon this project. You are free to delete thread. Also no copyleft-licensed components were used so I don't have to bother releasing sources.
Hentacler said:
Argh, sorry, I decided to abandon this project. You are free to delete thread. Also no copyleft-licensed components were used so I don't have to bother releasing sources.
Click to expand...
Click to collapse
Check your PM please!
1
Hello again.
For last two weeks I was rewriting it from scratch (yes. again... yes, third time).
Probably need another week to make it stable.
Currently I am not sure it runs on any device except my own 5-year old phone (LineageOS 14).
I will maintain last version here:
ftp://ftp.drivehq.com/mogryph/sparkle/
There is no English documentation, but you can see script "user.sh" to get idea about how to start xwayland. In most cases it should be enough to edit few lines in that script to make it work on another device. If you execute this script on your device with "install" argument, it is supposed to place itself into sparkle's directory and sparkle is supposed to run it ("start" function) automatically. Sparkle doesn't request root unless script does.
Here is video of sparkle working:
https://www.youtube.com/watch?v=tOSFYxCF7Q8
But it seems that KDE + video recording was too much for my old phone
Still, if you going to see video, don't close it until 2:00 where I turned of composition which caused lags.
Also on device everything looks much smoother than on video, even after 2:00.
When I watch fullscreen (1280x720) video on my device, sparkle + xwayland together add just 5% of CPU load (20% load of single core).
Thats it I guess... I tried to to discuss sparkle on 4pda.ru (russian forums), but got very bad reception. "xsdl is perfect, dont reinvent the wheel" they say. So I started to hate humanity and I decided to make sparkle personal project. Also this is last time I am solving reCAPTCHA to leave post on XDA.
Still alive
We are still alive. I've changed first post to reflect actual state. Now sparkle supports audio, auto-mouting containers and is lot more stable.
Yet there are still many things I want to improve in sparkle's core before adding new functions.
Also there are few demo videos on ftp.
Amazing!
Working great on my redmi 6 pro. Stock miui 9.9.3 rom. With linuxdeploy and sparkle from your ftp. No lag on visual and sound. My Linux distribution is alpinelinux arm64 arch.
Since first time I see your posting on 4pda. I'm interested in it. And finally it's on xda.
Thanks dev.
---------- Post added at 02:52 AM ---------- Previous post was at 02:44 AM ----------
For anyone interested in the topic. Please follow the instructions in documentation from ftp. And Translate it to eng from rus.
This sounds amazing! Just curious, is it related to https://github.com/twaik/sparkle ?
I now have it working very well on my Samsung Tab S3 using Xwayland and a tiling window manager. Firefox runs amazingly well!
Is it meant to be used only with Xwayland or will it also work with native Wayland applications?
BTW, I think if you open sourced this project and promoted it a bit, it could become quite popular. It's basically the first way to run X11 GUI applications on Android devices at full speed. If you set up a donation link, you could also get compensated for your time and effort. I'll personally contribute $20 if it's open sourced, and I'm sure others will chip in as well.
robsmith11 said:
This sounds amazing! Just curious, is it related to https://github.com/twaik/sparkle ?
Click to expand...
Click to collapse
Thanks for feedback. Nice to hear that someone managed to start this thing
Twaik's repository is clone of my very very old version of sparkle. I made that version years ago when I was just starting to learn linux and C++. Sparkle was rewritten from scratch two or three times since that version. And (I believe) current version is much better.
Regarding making it open source... Few months ago I had to find real job. Can't spend much time on personal projects any more. But I have my own strange programming style and my own vision of what sparkle should be. Not sure I want others to paint on my picture. It's probably all because of Twaik! I hate how he used old open source version of sparkle. He did terrible things to it, outraging all my beliefs Sorry!
P.S.: Yesterday I've uploaded another apk to my ftp. The file is called "sparkle-testing.apk". This version is much newer and has many fixes. But I've also changed to many things since tested version including some fundamental changes. No guarantee it will run at all on other devices. Interest is mega low and I get no test reports at all.
Hi Hentacler, I've just found your project - it looks really promising. Unfortunately, the only link currently working on this thread is to github. Is this project still live?
I have a samsung galaxy note 10+, and am using it as a laptop replacement. In addition to the android apps using Samsung Dex (Samsung's desktop solution), I have several linux distributions installed inside a chroot using userLand - so far, its working great. I'd be keen to give you project a try if it's still live, and am happy to help out with testing from my device.
Re open source - while I like your project, I'm not super interested in investing time into something that's not open sourced - I appreciate your concerns about wanting to maintain the direction, but having transparent development is pretty important to me. Is Twaik's fork of your project a better place to go?
Cheers.
tillum said:
Hi Hentacler, I've just found your project - it looks really promising. Unfortunately, the only link currently working on this thread is to github. Is this project still live?
I have a samsung galaxy note 10+, and am using it as a laptop replacement. In addition to the android apps using Samsung Dex (Samsung's desktop solution), I have several linux distributions installed inside a chroot using userLand - so far, its working great. I'd be keen to give you project a try if it's still live, and am happy to help out with testing from my device.
Re open source - while I like your project, I'm not super interested in investing time into something that's not open sourced - I appreciate your concerns about wanting to maintain the direction, but having transparent development is pretty important to me. Is Twaik's fork of your project a better place to go?
Cheers.
Click to expand...
Click to collapse
ftp://ftp.drivehq.com/mogryph/sparkle/
Link to FTP should work and there you can get two versions:
sparkle.apk - old version, but confirmed to work by 3-4 people.
sparkle-testing.apk - latest version, but only briefly tested by me.
I don't ask anyone to invest anything... Sparkle doesn't request root access or any other dangerous permissions (unless you enable automatic container mounting and starting) so it's safe to try for anyone who wants.
Btw, somewhere between these two versions I've replaced BASH container initialization script with LUA version. That was probably a bad idea. LUA script is harder to start directly as root and hacks I used may not work (currently may even cause application freeze if root access is denied). Going to revert to BASH probably. But this only touches people who want sparkle to mount container and launch everything automatically on single button press.
p.s.: Why I need to solve captcha every time I post something?
Thanks for the new release! I've updated and everything seems to be working without any changes on my Samsung Tab S3 with chroot and Arch Arm Linux.
Your changes also solved the flickering for me! The old version would flicker the screen whenever my keyboard's trackpoint activated, but it's not flickering at all any more. Performance seems to be about the same.
I think this could be quite popular, but not many people know about it. Perhaps a post on Hacker News or Reddit would raise awareness.
I understand your position on open source and maintaining control. One idea if you haven't already considered it is releasing the code with a restrictive license that forbids any forks. But either way, I'm enjoying being to properly use X11 on my tablet.
BTW, have you tried any native Wayland compositors? I don't really understand the Wayland ecosystem that well. I gave Sway a brief try, but it didn't seem to work. I've only been using XWayland.
@Hentacler Thanks for your reply! Very keen to get this working, but having a few issues. I'm unsure how to configure the user.lua file - I'm using your latest apk.
I have a non-rooted device, and am running archlinux under termux. Works fine with xsdl. I have installed xorg-server-wayland for X11. I'd appreciate any advice you have.
@robsmith11 Are you able to share how you got this working on Arch? Thanks!!!!
tillum said:
@Hentacler Thanks for your reply! Very keen to get this working, but having a few issues. I'm unsure how to configure the user.lua file - I'm using your latest apk.
I have a non-rooted device, and am running archlinux under termux. Works fine with xsdl. I have installed xorg-server-wayland for X11. I'd appreciate any advice you have.
@robsmith11 Are you able to share how you got this working on Arch? Thanks!!!!
Click to expand...
Click to collapse
I am not sure it is possible to use sparkle without root...
Sparkle makes it's directory accessible for everyone (chmod 777). Before Android 8 or 9 this was enough and xwayland from termux was able to connect to sparkle. Here is how people used to start it:
export XDG_RUNTIME_DIR=/data/data/com.sion.sparkle/files
Xwayland
But newer versions of Android brought more restrictions and termux can no longer connect to sparkle. These new restrictions are implemented using SELinux if you know what it is. Applications now have different security contexts.
But that is not all. Newest versions of android brought even more terrible meaningless restrictions effectively "killing" applications like termux and many others.
In short, from now one applications are not allowed to execute code (binary) that comes from "untrusted" sources. Termux used to download a lot of such code from it's own repositories. And now it can't. We can't even unpack binaries from assets.
So I can only help with rooted devices.
P.S. Please forgive me, but I am leaving this website. Making people solve recaptcha every time they want to post something is unacceptable level of contempt.
My mail: [email protected]
Thanks for that, will have a play. I could always just root my device. Weird about recaptcha, not having this issue. Currently through termux I have access to the whole sdcard, and am able to download packages (and distros) in it - will have a play and see what else is possible.
@tillum
I basically just followed the instructions on the first post for using Sparkle without busybox. I didn't need to modify the Lua scripts.
I'm guessing SELinux may be a problem without root. I'll try setting it up without root when I have a chance later.

Categories

Resources