yashsingh1/xdaforums huggingface dataset:
[Android] spookcity138:
After only a really quick look at your log there are a few avc denials. I can't say this is the reason its not booting,but build a permissive kernel and try that maybe.

---------- Post added at 08:12 PM ---------- Previous post was at 08:08 PM ----------

https://github.com/AospExtended/pla...mmit/5bb01d8711531f275adc7b03ebe8cf7f8ee8b725

https://github.com/AospExtended/pla...mmit/e54839163637612c9e17d1fdfd4aa63e419c03ec
[Android] xenreon:
Just tried that or what? If yes then you might wanna read previous replies in this thread and/or do a quick Google search
[Android] dev.kasibhatla:
I did not build that kernel. Could please elaborate or give me a link where i can read and make changes?

Or would you like to check me tree and kernel files?

Thank you
[Android] xenreon:
This by [MENTION=6552280]MSF Jarvis[/MENTION] should help, but it's also better to read the below links to understand more into sepolicy before you go:

https://source.android.com/security/selinux/

https://source.android.com/security/selinux/implement

https://source.android.com/security/selinux/device-policy

https://source.android.com/security/selinux/customize
[Android] Ripudamankaushik:
Hello everyone I am trying to build PA for my device I get a successful build but when i flash the rom it takes me to a screen saying boot sequence failed.........I am having this problem with AOSP-caf device tree and kernel for motorola g4 plus

Also when i try to use LOS device tree and kernel sources I get the following build error

INSTALL include/asm (33 files)

make: Leaving directory '/media/ripudaman/MySpace/AOSPA/kernel/motorola/msm8952'

ninja: build stopped: subcommand failed.

build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed

make: * [ninja_wrapper] Error 1

Plz somebody help me to resolve this
[Android] DiamondJohn:
I haven't tried this myself (YET!), however, this looks like an easy step http://graemehill.ca/compiling-permissive-android-kernel/ Is it really that easy? I'm away from my machine so cant even check if the var is really there

Also the reading supplied above on how to use the logs to add policies looks really easy and helpful too.
[Android] xenreon:
Without your modified sources and proper logs that info is useless.

If your issue is indeed related to sepolicy then setting it as permissive should solve it. Though if you're compiling with a ROM rather then kernel only then I suggest doing that from the tree like this
[Android] dev.kasibhatla:
My kernel files do not have that line at all.

[MENTION=5888332]xenreon[/MENTION] but the error lines of avc denials read permissive=1 and not permissive=0. Does that not mean my kernel is permissive?

Sorry if that was a bad question.

Thank you
[Android] spookcity138:
Not a bad question and I believe you're correct. As far as building a permissive kernel it really is as easy as opening arch/arm (or arm64 depending on your device) /configs/your default config file. Then find the "CONFIG_CMDLINE" section and change "selinux=enforcing" to "selinux=permissive"

It can also be done via the command line.
[Android] dev.kasibhatla:
Thank you for your reply.

My config has file has this line:

CONFIG_SECURITY_SELINUX=y

I should change it to

CONFIG_SECURITY_SELINUX=n

right?

Here is a paste of my config file in case you need it:

https://pastebin.com/xt2iMBeP
[Android] spookcity138:
No don't do that. You want that. Try to add "CONFIG_CMDLINE=androidboot.selinux=permissive” (without quotes) to your config file.
[Android] Albe96:
[emoji23][emoji23][emoji23] NO.

"CONFIG_SECURUTY_SELINUX=y" enables selinux in kernel" To Disable it You have to write -->>

"# CONFIG_SECURITY_SELINUX is not set" in defconfig, Not "CONFIG_SECURUTY_SELINUX=n"

Hope you got me! [emoji23][emoji23][emoji23]
[Android] dev.kasibhatla:
I will add that, but my boardconfig.mk (in my device tree) already has this line:

androidboot.selinux=permissive

Should i still go add that line to the config file in kernel?

Thanks

---------- Post added at 10:51 AM ---------- Previous post was at 10:50 AM ----------

I am really sorry. New to kernels. But I'll try to learn soon.
[Android] spookcity138:
If your BoardConfig has that then you're probably OK. Sorry,but if your kernel is already permissive, which it sounds like it is,I'm not real sure why your ROM doesn't boot. I'll try to look deeper into your log if I have some time later.
[Android] dev.kasibhatla:
In this log, i found this line:

[IMG="Vmalloc value"]https://drive.google.com/open?id=0B3cfRJQvTF-xbDk4dzl6ZmViZnpWSTZERkdkcXQxYlpfY3hR[/IMG]

The value seems too high, higher than the internal memory. And i compared with my tablet, and the tab has a relatively very low value vmalloc.

Is it an issue?
[Android] rajit:
help

tried eveything nbut stuck here. i5 8gb ram

prebuilts/sdk/tools/Android.mk:101: recipe for target '/home/sandip/android/system/out/host/linux-x86/obj/EXECUTABLES/jack_intermediates/jack' failed
make: *** [/home/sandip/android/system/out/host/linux-x86/obj/EXECUTABLES/jack_intermediates/jack] Error 255
make: *** Waiting for unfinished jobs....
make: Leaving directory '/home/sandip/android/system'

#### make failed to build some targets (02:44 (mm:ss)) ####

sandip@sandip-HP-Notebook:~/android/system$ jack-admin start-server
Launching Jack server java -Djava.io.tmpdir=/tmp -Dfile.encoding=UTF-8 -XX:+TieredCompilation-Xmx6G -cp /home/sandip/.jack-home/launcher.jar com.android.jack.launcher.ServerLauncher
Jack server failed to (re)start, see Jack server log
sandip@sandip-HP-Notebook:~/android/system$ jack-admin stop-server
Stopping background server
No Jack server running
sandip@sandip-HP-Notebook:~/android/system$ jack-admin start-server
Launching Jack server java -Djava.io.tmpdir=/tmp -Dfile.encoding=UTF-8 -XX:+TieredCompilation-Xmx6G -cp /home/sandip/.jack-home/launcher.jar com.android.jack.launcher.ServerLauncher
Jack server failed to (re)start, see Jack server log

[MENTION=6634418]Techie Android[/MENTION]
[Android] Techie Android:
What did you run in the terminal to execute everything? Did you look at all the posts where I had been working on it and try my solution?
[Android] rajit:
yes tried this,,

export JACK_SERVER_VM_ARGUMENTS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx4g"

./prebuilts/sdk/tools/jack-admin kill-server

./prebuilts/sdk/tools/jack-admin start-server

and also added line in /etc/fstab as you mention. but it seems its cant able to restart..
[Android] Techie Android:
Here's exactly what I do step by step:

open terminal

cd aospa (I've named my dir aospa but you would replace this with your dir name) This is the dir where you cloned the source into.

Run these command individually.

export USE_NINJA=false

export JACK_SERVER_VM_ARGUMENTS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx6G"

./prebuilts/sdk/tools/jack-admin start-server

./rom-build.sh bacon

Let me know if it worked or didn't. I'll help to my best ability.

---------- Post added at 04:01 PM ---------- Previous post was at 03:58 PM ----------

Note too that my jack server isn't running already when my commands are executed so you will need to kill it before hand if it's running.
[Android] rajit:
./prebuilts/sdk/tools/jack-admin kill-server

Killing background server

No Jack server to kill

sandip@sandip-HP-Notebook:~/android/system$ jack-admin start-server

Launching Jack server java -Djava.io.tmpdir=/tmp -Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx4096m -cp /home/sandip/.jack-home/launcher.jar com.android.jack.launcher.ServerLauncher

Jack server failed to (re)start, see Jack server log
[Android] Techie Android:
Are you not going to try the commands I gave you that worked for me?
[Android] rajit:
tried

sandip@sandip-HP-Notebook:~/android/system$ export USE_NINJA=false
sandip@sandip-HP-Notebook:~/android/system$
sandip@sandip-HP-Notebook:~/android/system$ export JACK_SERVER_VM_ARGUMENTS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx6G"
sandip@sandip-HP-Notebook:~/android/system$
sandip@sandip-HP-Notebook:~/android/system$ ./prebuilts/sdk/tools/jack-admin stop-server
Stopping background server
No Jack server running
sandip@sandip-HP-Notebook:~/android/system$ ./prebuilts/sdk/tools/jack-admin start-server
Launching Jack server java -Djava.io.tmpdir=/tmp -Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx6G -cp /home/sandip/.jack-home/launcher.jar com.android.jack.launcher.ServerLauncher
Jack server failed to (re)start, see Jack server log
[Android] Techie Android:
No I read the command there and you kill the server which you were not supposed to do. You should have already made sure it wasn't running.

---------- Post added at 03:27 PM ---------- Previous post was at 03:25 PM ----------

Give me a second I'm going to record the steps in a video and upload it to YouTube. Maybe you'll understand the steps I take in it.
[Android] rajit:
You can see their that no jack server running ?? Its not starting
[Android] Techie Android:
It was because you killed it.

sandip@sandip-HP-Notebook:~/android/system$ ./prebuilts/sdk/tools/jack-admin stop-server Stopping background server No Jack server running

This was where you went wrong.

---------- Post added at 03:45 PM ---------- Previous post was at 03:38 PM ----------

What happened was you executed the commands pertaining to the jack server and then killed it.

You basically reverted what you did.

Best thing to do if your confused wether the jack server is running or not is to simply reboot your PC. Then try my commands again. You will not have to kill the jack server then. If you do it again at that point it will mess you up.

There's only one way to run the commands and that's the way I listed them.

---------- Post added at 05:27 PM ---------- Previous post was at 04:45 PM ----------

@rajit

The video I did is taking a while to upload. I'll let you know when it's finished

---------- Post added at 05:37 PM ---------- Previous post was at 05:27 PM ----------

https://youtu.be/PH3pG8xU5QQ

Okay there you go, it's done. Hope it helps.
[Android] avirk:
See the video [MENTION=6634418]Techie Android[/MENTION] uploaded for you, still have the problem then best way to do it is this guide helped me just few days ago https://xdaforums.com/android/software/aosp-cm-los-how-to-fix-jack-server-t3575179
[Android] threehappypenguins:
Total NOOB here.

I'm running Ubuntu 16.4 in VirtualBox. Problem is, I am completely new to Linux and I'm literally copying and pasting command line. I don't understand what everything does. I'm just kind of doing it for now, learning as I go. So far, everything has worked fine. But now, I'm stuck at this part:

I found my device's device tree on github: https://github.com/j03lpr86/android_device_samsung_afyonltetmo

What do I do with it? Download the zip and put it somewhere and then extract it somewhere? If so, where? Or do I use the "Clone with HTTPS" link? If so, how do I execute it in the terminal?

Same questions with the vendor I found: https://github.com/j03lpr86/android_vendor_samsung_afyonltetmo

As for the kernel, what do I do for that? XDA doesn't have my device listed (Galaxy Avant). I downloaded the stock ROM from Sammobile. Do I extract kernel.img from that? If so, where do I place it?

There are just too many assumptions that the author of the guide makes and I don't understand what to do at this point.

I managed to also create the local_manifest.xml file (or was it supposed to be local_manifests.xml... with an s?), but I don't know what to put in it. Please help!
[Android] Techie Android:
The OP is pretty old and needs to be updated. Best thing for you to do is go to the manifest on GitHub and read it for compiling the ROM. Feel free to ask here, we're ready to help out.
[Android] threehappypenguins:
Can you provide a link? I have no idea how to "go to the manifest on GitHub." I know github.com and it hosts lots of files, and somehow linux command line can communicate with it, but that's about it.
[Android] Techie Android:
Sure. What ROM are you wanting to make? Can you find the GitHub page for it? That way I can show you what to do from there. The manifest page should be near the top.

---------- Post added at 09:01 PM ---------- Previous post was at 08:50 PM ----------

Here's some tips

You'll want to make a directory to store the source in (beware it can be very large, expect 50GB+).

mkdir source

That command will make a directory in the current location named source

cd source

will move you into that location

By default the terminal is in the home directory which is represented by a ~

cd ~

Will take you back there
[Android] threehappypenguins:
I want to make a CM 13 rom. Here is the github page: https://github.com/CyanogenMod
[Android] Techie Android:
Okay sorry I just noticed what you said earlier about your phone, I understand now. I'm not sure there's a way to compile whats on that page because from what I can tell he's of course not working on it anymore but also it seems to missing some things.
[Android] threehappypenguins:
I also already downloaded the repo. I used:

repo init -u https://github.com/CyanogenMod/android.git -b cm-13.0

And I made a directory called "android" in my home directory and downloaded it there. This guide was much clearer on what to do, but it stops short of actually going through compiling the rom.
[Android] Techie Android:
http://wiki.cyanogenmod.org/ was the link for the build instructions but as you know CyanogenMod is dead and so you can't get there. Also there's got to be support for your phone already to be able to make a ROM this way for it. You can't just go out to the source of a ROM project and make a generic ROM that will work on your phone. Sorry.

---------- Post added at 10:22 PM ---------- Previous post was at 10:19 PM ----------

https://github.com/LineageOS LineageOS is what's replaced CyanogenMod. I suggest you look over this page https://github.com/LineageOS/android and https://wiki.lineageos.org/ to get a general idea of what's involved in building a ROM from the source on GitHub for your device.

---------- Post added at 10:23 PM ---------- Previous post was at 10:22 PM ----------

https://wiki.lineageos.org/devices/ This is a list of currently supported devices.
[Android] threehappypenguins:
I'm lost. What do you mean? I can't make a CM rom or an ASOP rom or an AKOP rom or anything for my phone? Other people have made CM 11 and CM 12.1 roms for my phone. But the CM 12.1 roms don't fully work. I was just going to try and bugfix the CM 12.1 roms to make them work so I can have something newer than kitkat on my phone, but I was using Windows and it wasn't unpacking and repacking the system.new.dat file right. So I gave up and figured I'd start from scratch.

I don't understand what you mean there is no support for my phone. It's a Galaxy Avant.

I feel so hopeless. I can't afford a new phone. I would really like to learn how to port custom roms because we will forever be getting old hand-me-down phones.
[Android] Techie Android:
For supporting a new device... I'll be honest I don't know what you would have to do. I do know you will need the source code for you device to be able to work with it. https://androidforums.com/threads/lets-get-cm-onto-avant.897931/ http://opensource.samsung.com/reception/receptionSub.do?method=sub&sub=F&searchValue=SM-G386T

Whoops sorry missed your last post.

---------- Post added at 10:32 PM ---------- Previous post was at 10:30 PM ----------

Where are these ROM your talking about? I looked but didn't anything other than a post about gaining root.

---------- Post added at 10:42 PM ---------- Previous post was at 10:32 PM ----------

https://xdaforums.com/showthread.php?t=2073370 This should be more help to you than me. It has all the best links on how to do anything and everything.
[Android] Louis1977:
help me please..

make: Leaving directory '/home/louis/cos/kernel/motorola/msm8992'

[ 3% 1799/45317] -e \033[32mtarget Java:\033[0m core...obj/JAVA_LIBRARIES/core-libart_intermediates/classes)

Note: Some input files use or override a deprecated API.

Note: Recompile with -Xlint:deprecation for details.

Note: Some input files use unchecked or unsafe operations.

Note: Recompile with -Xlint:unchecked for details.

[ 3% 1799/45317] -e \033[32mtarget Java:\033[0m core...mon/obj/JAVA_LIBRARIES/core-oj_intermediates/classes)

Note: Some input files use or override a deprecated API.

Note: Recompile with -Xlint:deprecation for details.

Note: Some input files use unchecked or unsafe operations.

Note: Recompile with -Xlint:unchecked for details.

[ 3% 1799/45317] -e \033[33mhost C++:\033[0m llvm-tb... external/llvm/utils/TableGen/RegisterInfoEmitter.cpp

ninja: build stopped: subcommand failed.

make: *** [build/core/ninja.mk:152: ninja_wrapper] Error 1

make: Leaving directory '/home/louis/cos'

#### make failed to build some targets (01:52 (mm:ss)) ####

louis@louis:~/cos$
[Android] Techie Android:
You might try building without ninja by running this before compiling. That might fix it.

export USE_NINJA=false
[Android] Louis1977:
tanks and now this error

device/motorola/clark/overlay/frameworks/base/core/res/res/values/config.xml:313: error: Resource at config_deviceHardwareWakeKeys appears in overlay but not in the base package; use <add-resource> to add.

device/motorola/clark/overlay/frameworks/base/core/res/res/values/config.xml:436: error: Resource at config_uiBlurEnabled appears in overlay but not in the base package; use <add-resource> to add.

target thumb C: libc_gdtoa_32 <= bionic/libc/upstream-openbsd/lib/libc/gdtoa/strtord.c

target thumb C: libc_gdtoa_32 <= bionic/libc/upstream-openbsd/lib/libc/gdtoa/sum.c

target thumb C: libc_gdtoa_32 <= bionic/libc/upstream-openbsd/lib/libc/gdtoa/ulp.c

make: *** [build/core/package_internal.mk:371: /home/louis/cos/out/target/common/obj/APPS/framework-res_intermediates/src/R.stamp] Error 1

make: *** Waiting for unfinished jobs....

target thumb C++: libc_malloc_32 <= bionic/libc/bionic/jemalloc_wrapper.cpp

make: Leaving directory '/home/louis/cos'

#### make failed to build some targets (02:05 (mm:ss)) ####
[Android] Techie Android:
Hmm. Were there any problems when you synced the repo? Did you make sure you had all the dependencies?

---------- Post added at 10:34 PM ---------- Previous post was at 10:33 PM ----------

You should be able to go to the repo and see what is required to compile it.
[Android] Louis1977:
lokk..

<?xml version="1.0" encoding="UTF-8"?>

<manifest>

<project name="AICP/device_motorola_clark" path="device/motorola/clark" remote="github" revision="n7.1"/>

<project name="LineageOS/android_kernel_motorola_msm8992" path="kernel/motorola/msm8992" remote="github" revision="cm-14.1"/>

<project name="LineageOS/android_hardware_sony_thermanager" path="hardware/sony/thermanager" remote="github" revision="cm-14.1"/>

<project name="LineageOS/android_packages_resources_devicesettings" path="packages/resources/devicesettings" remote="github" revision="cm-14.1"/>

<project name="TheMuppets/proprietary_vendor_motorola" path="vendor/motorola" remote="github" revision="cm-14.1"/>

<project name="LineageOS/cm_platform_sdk" path="cm_platform_sdk" remote="github" revision="cm-14.1"/>

</manifest>
[Android] aoleary:
Can you explain to me the process that you used to find those two commits, so I can search for myself?

Dont want to be bothering you guys with simple questions if I can go do it myself :victory:
[Android] Techie Android:
So are you saying you don't know if you did or not? Listing multiple project repos isn't helping to answer my question. Which repo are you using? I'll look at what the dependencies are to compile it.
[Android] aoleary:
[I]device/motorola/clark/overlay/frameworks/base/core/res/res/values/config.xml:313: error: Resource at config_deviceHardwareWakeKeys appears in overlay but not in the base package; use <add-resource> to add.

device/motorola/clark/overlay/frameworks/base/core/res/res/values/config.xml:436: error: Resource at config_uiBlurEnabled appears in overlay but not in the base package; use <add-resource> to add.[/I]

Basically this means your ROM doesnt support these features, so go to the lines 313 and 436 and comment out each line in the file config.xml, located at device/motorola/clark/overlay/frameworks/base/core/res/res/values/

There is zero side effect to worry about by doing so..

<!-- This is how I comment out text in XML files -->

Then just restart your build..
[Android] Louis1977:
repo init -u https://github.com/Cosmic-OS/platform_manifest.git -b n-mr2:D

---------- Post added at 10:07 PM ---------- Previous post was at 09:45 PM ----------

tanks man Works .. I'm going to wait and see if he does not shoot some mistakes jejejeje
[Android] threehappypenguins:
I previously installed CM 11 (I had rooted it using chainfire... I think? and installed TWRP 2.8.1.0): https://www.androidfilehost.com/?w=files&flid=35854

And none of these have working wifi or camera for CM 12.1: https://www.androidfilehost.com/?w=files&flid=33415

And this rom has working wifi, but incoming calls doesn't work, neither does camera: https://androidforums.com/threads/cm12-1-caf-beta.969292/#post-7140424

So that's why I want to build my own rom. I want to learn anyways, but I also really want an updated phone. Mainly for the reason of using the new fully functioning YNAB (a budgeting app), which requires a minimum Android 5.0.

Also, just took a quick look at the link full of guides. THANK YOU. Exactly what I'm looking for. I will take a gander through there.
[Android] spookcity138:
The proper way to fix this is to do exactly what it says "add resource" You can go to /frameworks/base/core/res/res/values/config.xml and add the parts on line 313 and 436 to that file.

Just searched AEX's github for "Quick Unlock"
[Android] xenreon:
Most of that can be solved by reading the guide and using some logic. The op is making assumptions because nothing is set in stone but rather changes contextually depending on the situation. Now if you don't have the kernel source at all you can use a prebuilt kernel (Google "how to use a prebuilt kernel while building Android") although Samsung generally releases the kernel sources in the form of a tarball so you might wanna search for that first. The local_manifest part is very clearly written in the op so as I said, read it (with focus and logic, they're needed).

By no support he means the device has not been updated forward to marshmallow and up, now I'll be the bearer of bad news and say if you don't have kernel source and the person previously working on that tree you linked used prebuilt then you're pretty much doomed.

I'm pretty sure that can be done by searching The GitHub organizations and/or specific repos (depending on the case) of those roms with similar keywords you'd expect to see in the commits.
[Android] threehappypenguins:
Wouldn't my kernel source be found here? http://opensource.samsung.com/reception/receptionSub.do?method=sub&sub=F&searchValue=g386w

I'm not sure what you mean about the device being updated forward to Marshmallow. Aren't the main "ingredients" that are needed the repo from github for cm 13 (or aokp, or slimrom, etc), and the source code for the 386W (or 386T) for the Samsung Galaxy Avant?

I'm just a little confused what else would be needed.

I am really not familiar with the Linux file system, nor with command line. I am used to Windows (or even Android), where I run tools that people have written to do the job. I have also edited various codes with Notepad ++. Really amateur stuff. I really want to learn this, but I am genuinely lost.

I can edit the manifest file (is it manifest or manifests?), but I don't understand exactly where to get the information. I have a repo downloaded, I downloaded the device kernel source from the Samsung website onto my desktop (I didn't understand how to do it from command line or if I was supposed to) and all this information is just sitting here and I haven't the faintest clue of how to wade through it to get the information I need. If that makes sense.