yashsingh1/xdaforums huggingface dataset:
[Galaxy Note 4 General] LenAsh:
Without the mod to add the number line, it looks like this.

I *thought* I'd simply copied yours...

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

<manifest>

<project name="underscoremone/android_kernel_samsung_trlte" path="kernel/samsung/trlte" remote="github" revision="cm-14.1" />

<project name="underscoremone/android_device_samsung_trlte-common" path="device/samsung/trlte-common" remote="github" revision="cm-14.1" />

<project name="underscoremone/android_device_samsung_trltexx" path="device/samsung/trltexx" remote="github" revision="cm-14.1" />

<project name="underscoremone/proprietary_vendor_samsung_trlte" path="vendor/samsung" remote="github" revision="cm-14.1" />

<project name="LineageOS/android_device_samsung_qcom-common" path="device/samsung/qcom-common" remote="github" revision="cm-14.1" />

<project name="LineageOS/android_external_stlport" path="external/stlport" remote="github" revision="cm-14.1" />

<project name="LineageOS/android_device_qcom_common" path="device/qcom/common" remote="github" revision="cm-14.1" />

<project name="LineageOS/android_packages_resources_devicesettings" path="packages/resources/devicesettings" remote="github" />

<project name="LineageOS/android_packages_apps_FlipFlap" path="packages/apps/FlipFlap" remote="github" />

<project name="LineageOS/android_hardware_sony_timekeep" path="hardware/sony/timekeep" remote="github" />

<project name="LineageOS/android_hardware_samsung" path="hardware/samsung" remote="github" />

</manifest>
[Galaxy Note 4 General] LenAsh:
Shared above...
[Galaxy Note 4 General] nepal12:
I got following error on repo sync: Where did I do wrong

com/android/tools/lint/lint-api/24.4.0-beta5/lint-api-24.4.0-beta5-sources.jar.sha1

com/android/tools/lint/lint-api/24.4.0-beta5/lint-api-24.4.0-beta5.jar

Please move or remove them before you can switch branches.

Aborting

Syncing work tree: 100% (592/592), done.
[Galaxy Note 4 General] ripee:
[MENTION=4467696]AndyYan[/MENTION], Make 2 roomservice.xml files. Unless both your devices share the same repo for the same source code, ie. blobs, you have to copy them over to the local_manifests folder separately. Here's my build script for trltevzw:

#!/bin/bash

cd ~/android/lineageos
make clean
cd .repo/local_manifests
wget https://raw.githubusercontent.com/ripee/roomservices/cm-14.1/trltetmo.xml
mv trltetmo.xml roomservice.xml
cd ../..
repo sync --force-sync
. build/envsetup.sh
brunch trltetmo
mv ~/android/lineageos/out/target/product/trltetmo/*UNOFFICIAL*.zip ~/builds/
make clean
cd ~/builds
ftp -inv uploads.androidfilehost.com <<EOF
user ripee <password>
cd auto/SamsungGalaxyNote4/160137-trltetmo
mput *trltetmo.zip /
bye
EOF

I download the raw data of the roomservice.xml file then rename it to roomservice.xml. This is to overwrite the previous build's roomservice.xml, for whichever device I happened to have built before this one. I have a combined roomservice.xml for trltetmo and trltexx, but this is just an example for trltetmo.
[Galaxy Note 4 General] AndyYan:
[MENTION=6005084]ripee[/MENTION] From what I understand, won't using a new roomservice.xml remove local files of whatever repo that's not in the xml? My network is metered and doesn't permit me to download gigabytes of repo content every time...
[Galaxy Note 4 General] ripee:
On top of downloading the entire code base the first time you run the repo init command, you will only download each entire repo in your roomservice.xml file the first time you sync, that's why it's important to have enough space in your build enviroment to handle both the source code and the compiled data (each build needs ~25GB). Even if you replace a repo in your roomservice.xml that you've previously synced with another one of it's kind, ie. another kernel, the first repo will remain in your build environment and the new one will be added alongside it. Again, make sure you have enough disk space. When you sync a repo that's already on your system, only the changes sync your last sync will be downloaded, which takes only a few seconds on a fast connection.
[Galaxy Note 4 General] AndyYan:
Sounds good, but does that also mean if I delete a repo I no longer want from roomservice, the local files will continue taking up space?

"Yes" -> I need to find a way to clear up that space; "no" -> it's still not feasible to use separate roomservices for different devices.
[Galaxy Note 4 General] ripee:
Yes, they will take up space. Why isn't it feasible to use separate roomservices for different devices? It's a hard truth I had to accept when I started building.
[Galaxy Note 4 General] AndyYan:
Then do you have idea how to clean up that space?

It's great that the old files are kept, which means I can use separate roomservices without downloading much stuff every time - I'll experiment with that later.

EDIT: I tried swapping out the trlte's corresponding vendor with TheMuppets once again, and it still downloaded the whole repo. Doesn't look like any local file is reused...
[Galaxy Note 4 General] yaguphire:
How to build lineage-15.0 ? I come to find that cm14.1 manifest does not work :)
[Galaxy Note 4 General] ripee:
If you only want to build for one device, you can get away with no more than ~120GB in total for your build environment. Ubuntu takes up around 12GB, the Lineage codebase around 30GB, and you'll need ~25GB to compile each device before you'd need to make clean. If 120 sounds like too much, I set my ccache to 100GB to maximize build times, but any higher doesn't make the compiler run any faster. I can cook trlte in around half an hour! My laptop has 8 logical cores, so I let Ubuntu in VMware use 6 and 12 out of 16GB of system RAM. I'm unfamiliar with IntelliJ.
[Galaxy Note 4 General] tripLr:
where do we put those files ? roomservice.xml? and how exactly

I am creating a single text file for total noobs based on your op.

please forgive me, still reading all the posts and adding to my instructions

will post it here when i am done, i am building my first rom with these instructions

thanks

Ok, I was in the wrong folder somehow when I started repo. Everything went into my home folder not the ~/Android/lineageOS/ folder.

Working on reading all these posts.

So basically, follow the instructions, but copy the info from device.xml into roomservice.xml before you make your build?

Thanks [MENTION=6005084]ripee[/MENTION]
[Galaxy Note 4 General] ripee:
The beauty and laziness of the dependencies file in both the variant and common device trees is that, whichever entries the dev includes in them, you don't need to add to your roomservice file because those entries are automatically added to the bottom of the roomservice during the syncing procedure.

That said, in the case of all of our variants and unified builds, because all repos are in the samsung-apq8084 organizational account (except the kernel), the 2 lines per entry in dependencies doesn't specify the project name. If we didn't include all the required repos in our roomservice, the compiler would assume those repos were in LineageOS, since that's the project whose codebase we've previously synced down.

What you'd need to do is to add an extra line per entry to the dependencies file, specifying that the project in which the compiler would need to look for the dependencies repos is "samsung-apq8084" rather than LineageOS. I just populate the roomservice manually.

For devices with official support, you'd only need to add the device tree and TheMuppets blobs. The device tree's dependencies contains the common repo entry, and the common repo's dependencies usually contains entries for all the remaining repos required for that particular device. So the compiler looks for all those repos sequentially in a cascade effect.
[Galaxy Note 4 General] ripee:
It's probably too late for you now, but I made a set of batch scripts from all of _mone's instructions in the OP to automate the creation of the build environment:

To install the necessary apps and edit bashrc, I call it "build_environment.sh":

#!/bin/bash

apt-get update
apt-get -y dist-upgrade
apt-get remove -y openjdk-* icedtea-* icedtea6-*
echo | add-apt-repository ppa:openjdk-r/ppa
apt-get update -y
apt-get install -y openjdk-8-jdk
apt-get install -y git ccache automake lzop bison gperf build-essential zip curl zlib1g-dev zlib1g-dev:i386 g++-multilib python-networkx libxml2-utils bzip2 libbz2-dev libbz2-1.0 libghc-bzlib-dev squashfs-tools pngcrush schedtool dpkg-dev liblz4-tool make optipng maven
mkdir ~/bin
curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo
echo 'export PATH=~/bin:$PATH' >> ~/.bashrc
echo 'export USE_CCACHE=1' >> ~/.bashrc
echo 'export ANDROID_CCACHE_SIZE="[B]100G[/B]"' >> ~/.bashrc
echo 'export ANDROID_JACK_VM_ARGS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx[B]12G[/B]"' >> ~/.bashrc
[B]echo 'export WITH_SU=true' >> ~/.bashrc[/B]
. ~/.bashrc
mkdir ~/android

Notice that I use 12GB of sytem RAM and assign 100GB to ccache, as well as build with su. Just edit the values in bold and remove the su line if you wish.

To sync down the Lineage codebase, I call it "lineageos.sh":

#!/bin/bash

cd ~/android
mkdir lineageos
cd lineageos
repo init -u git://github.com/LineageOS/android.git -b cm-14.1
repo sync -c --force-sync --no-clone-bundle --no-tags
cd .repo
mkdir local_manifests
cd ../../..
[Galaxy Note 4 General] tripLr:
What I did is add a second hard drive and mount it as /home/(your system folder user name here)/(your build foldername)

This allows me to download my repo on to an entirely different hard drive but it still looks like it's in my directory .
[Galaxy Note 4 General] tripLr:
Holy batman, I'm building my first build

Shout out to [MENTION=6005084]ripee[/MENTION].

My noob status is elevated to notso noob

Thanks to [MENTION=6005084]ripee[/MENTION] for the XML files for the local_manifests folder

Thanks to the man pages on each command to read

Thanks to all the writers of each script needed to build and compile the different code

Still. The output of my terminal looks like putting a bunch of code in a blender when you start ?
[Galaxy Note 4 General] tripLr:
stuck on brunch

@ripee

updated

thanks for the pm

opened terminal

did sudo -s so the entire build process was in sudo mode. thanks

well it would of worked, but my build didnt like my 2gb memory limit. on my machine, got 38% after 4 hours.

interesting thing, my old laptop didnt crash. got 38% after 4 hours

ben a hel.. of a ride learning this far, now i need a build machine budget

thanks all
[Galaxy Note 4 General] tripLr:
following errors this time

used manifest from github.com/ripee for gts28wifi

From git://github.com/LineageOS/android_hardware_samsung_slsi-cm_exynos5

* [new branch] cm-14.1 -> github/cm-14.1

Fetching projects: 83% (5/6) Receiving objects: 0% (6313/3065645), 1.20 MiB remote: Total 3065645 (delta 0), reused 0 (delta 0), pack-reused 3065643

Receiving objects: 100% (3065645/3065645), 639.52 MiB | 3.63 MiB/s, done.

Resolving deltas: 100% (2584119/2584119), done.

From git://github.com/LineageOS/android_kernel_samsung_gts2

* [new branch] cm-14.1 -> github/cm-14.1

Fetching projects: 100% (6/6), done.

Checking out files: 100% (47090/47090), done.iles: 14% (7031/47090)

Syncing work tree: 100% (6/6), done.

Looking for dependencies in hardware/samsung

Dependencies file not found, bailing out.

Looking for dependencies in hardware/samsung_slsi-cm/exynos

Dependencies file not found, bailing out.

Looking for dependencies in hardware/samsung_slsi-cm/exynos5

Dependencies file not found, bailing out.

Looking for dependencies in hardware/samsung_slsi-cm/exynos5433

Dependencies file not found, bailing out.

Looking for dependencies in hardware/samsung_slsi-cm/openmax

Dependencies file not found, bailing out.

Looking for dependencies in kernel/samsung/gts2

Dependencies file not found, bailing out.

Done

build/core/product_config.mk:254: *** _nic.PRODUCTS.[[device/samsung/gts28wifi/lineage.mk]]: "vendor/samsung/gts2-common/gts2-common-vendor.mk" does not exist. Stop.

build/core/product_config.mk:254: *** _nic.PRODUCTS.[[device/samsung/gts28wifi/lineage.mk]]: "vendor/samsung/gts2-common/gts2-common-vendor.mk" does not exist. Stop.

** Don't have a product spec for: 'lineage_gts28wifi'

** Do you have the right repo manifest?

No such item in brunch menu. Try 'breakfast'

root@HP:~/Desktop/Build/LineageOS# make clean

build/core/product_config.mk:254: *** _nic.PRODUCTS.[[device/samsung/gts28wifi/lineage.mk]]: "vendor/samsung/gts2-common/gts2-common-vendor.mk" does not exist. Stop.

#### make failed to build some targets ####
[Galaxy Note 4 General] ripee:
You're missing a repo ;) probably because you're using an older version of my roomservice file. Instead, use this command when in your local_manifests folder before each build:

wget -O roomservice.xml https://raw.githubusercontent.com/ripee/local_manifests/cm-14.1/gts210ltexx_gts210wifi_gts28ltexx_gts28wifi.xml

This will download the current version of that roomservice and create the roomservice.xml filename with the raw data of that file in it. I keep my roomservices on my github precisely so that other builders have access to exactly what I know will build because I've built it myself :good:
[Galaxy Note 4 General] tripLr:
Thanks.

I tried just the above with linking to the long filename and renaming it in my folder.

It looks like I didn't get the other XML files in the git folder it was in. Will try again.

Also,

---------- Post added at 09:26 PM ---------- Previous post was at 08:40 PM ----------

here is my build_lineageos_gts28wifi.sh

#!/bin/bash

sudo -s
cd /home/triplr/Desktop/Build/LineageOS/.repo/local_manifests/
mv roomservice.xml roomservice.xml.bak
cd /home/triplr/Desktop/Build/LineageOS
make clean
repo init -u git://github.com/LineageOS/android.git -b cm-14.1
repo sync -c --force-sync --no-clone-bundle --no-tags
cd /home/triplr/Desktop/Build/LineageOS/.repo/local_manifests
wget -O roomservice.xml https://raw.githubusercontent.com/ripee/local_manifests/cm-14.1/gts210ltexx_gts210wifi_gts28ltexx_gts28wifi.xml
cd /home/triplr/Desktop/Build/LineageOS
repo sync -c --force-sync --no-clone-bundle --no-tags
. build/envsetup.sh
brunch gts28wifi

ha, i even figured out how to

do this.

just so you know, the Desktop/Build folder is actually a partition on another hard drive i could have put the lineageos folder anywhere, buts that where i had space., plus i have another folder named kernel, and rom in my build partition. command line linux is getting easier
[Galaxy Note 4 General] ripee:
You don't need to repo init the codebase before each build, that's just to initiate and sync down the source code when you create your build environment.

To reduce the download size further, try this:

repo init --depth=1 -u git://github.com/LineageOS/android.git -b cm-14.1

The --depth=1 parameter will only download the latest and second latest commits, saving lots of disk space.
[Galaxy Note 4 General] tripLr:
1st fail Jack server didn't start so build failed.

Missing log file folder in user for jack server.

Created file and path, re ran build

Jack server didn't start

Manually starred jack server, server was there. Dunno why failed.

However,

While looking at the build screen for errors

First error was camera ! Java something or other not found

Is there a way to pipe the output of the build to a log file?

Echo export build script >> buildlog.txt or something?
[Galaxy Note 4 General] ripee:
Building Oreo in Ubuntu 18.04 LTS

In order for it not to error out around 5%, citing a problem with flex, you have to add this line to bashrc:

export LANG=C

Then run source ~/.bashrc or reboot Ubuntu. The build will proceed as in Ubuntu 16.04 LTS. ;)

To add this line to bashrc as part of your build environment preparation script, add this line to that script:

echo 'export LANG=C' >> ~/.bashrc
[Galaxy Note 4 General] HorizonBam:
Every time i try to build it i get this error:

warning: string 'candidates_style' has no default translation.
warning: string 'gsm_alphabet_default_charset' has no default translation.
warning: string 'wfcSpnFormat' has no default translation.
nothing matches overlay file default_wallpaper.png, for flavor hdpi-v4
nothing matches overlay file default_wallpaper.png, for flavor xhdpi-v4
nothing matches overlay file default_wallpaper.png, for flavor xxhdpi-v4
nothing matches overlay file default_wallpaper.png, for flavor xxxhdpi-v4
[ 0% 114/31991] AAPT2 link /media/dev/External/Android/out/target/common/obj/JAVA_LIBRARIES/android-support-v7-preference_intermediates/package-res.apkninja: fatal: fork: Cannot allocate memory
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1

Can someone help?
[Zenfone 5 Q&A, Help & Troubleshooting] mdikmetas:
.my phone zenfone 6 a601CG i im many time unlock bootloader after install twrp but all time just white usb logo.

i use UL-ASUS_T00G-WW-3.23.40.60-user

help please i all try twrp

no problem unlock bootloader but twrp after problem usb logo dont open twrp
[Android Software/Hacking General [Developers Only]] M.A.K:
Reserved
[Android Software/Hacking General [Developers Only]] M.A.K:
Download updated: There was a very silly error in Patch.bat.
[Android Software/Hacking General [Developers Only]] AnonVendetta:
I'm just posting to say that my ROM won't boot after applying this patch. Fortunately, I had a backup. I'm running Resurrection Remix on a Note 4 (N910T), which is v7.1.1 and based on a mix of LineageOS and Emotion/Emotroid (the latter is AOSP). I followed the instructions to the tee. I already had adb and fastboot installed. The patch did succeed. I also tried clearing cache and dalvik cache in TWRP, but still couldn't boot. I do have GApps installed. What could have gone wrong?

Thanks!
[Android Software/Hacking General [Developers Only]] M.A.K:
Hmm... Not sure why it wouldn't work for you. I can only guess that the framework didn't re-compile properly or it wasn't pushed to system properly.

One thing you could try is boot to twrp, mount system and run patch.bat from there.
[Android Software/Hacking General [Developers Only]] holunder:
No GCN push

Hey, thank you very much for your effort! I have used your Windows Batch files in an editor to translate the process to Linux. Everything works flawlessly on my LG G4 with Lineage 14.1!

Without GCM, which is sadly a dealbreaker. It seems to need permission for "com.google.android.gms android.permission.ACCESS_FINE_LOCATION", the other three adb lines in your DisableGoogle.bat can be executed and GCM still works.

So I ask: What do I lose in privacy in not revoking permission for the line above?
[Android Software/Hacking General [Developers Only]] M.A.K:
If location permissions are allowed then google play services will keep accessing network/gps to keep track of your location. This causes all those nlp wakelocks. I did find however that using UnifiedNLP like this caused significantly less wakelocks than using the google location services. So if that's how you need it then go for it.

BTW, what's GCN push?
[Android Software/Hacking General [Developers Only]] holunder:
Sorry, I meant GCM, Google Cloud Messaging (not Notification).

The main question would be if Google still collects and tracks Wi-Fis, cell towers etc. when I don't revoke this permission. If so, the whole enterprise to get the Mozilla Location Provider to work would be rather pointless. No push notifications for Signal, Tweetings etc. is sadly not acceptable for me.
[Android Software/Hacking General [Developers Only]] M.A.K:
Ah, I can't comment on GCM as I've never used it but third party app's I use push ok. But that being said, you use GCM so that's what you need to work.

The whole point of this really is to stop google from stalking you (whether for privacy, battery or both). So yeah, I'd have to agree that using this and allowing those google location permissions would be pretty pointless.
[Android Software/Hacking General [Developers Only]] vegoja:
Works great on my op3t thanks a million
[Android Software/Hacking General [Developers Only]] sohamsen:
microG's built in unified nlp and this are same?
[Android Software/Hacking General [Developers Only]] M.A.K:
Good to know, cheers.

Yes. If you're using MicroG then this isn't useful for you.
[Android Software/Hacking General [Developers Only]] Andext:
Hi,

This method works if i disabled google play services only.

Disablepatch disabled my gps lock.

any idea?
[Android Software/Hacking General [Developers Only]] Nyakov:
The download is dead, can you reupload?
[Android Software/Hacking General [Developers Only]] Julien Faure:
Hi. With some little changes (updating java and apktool) I managed to get Patch.bat working on LOS 15.1 *but* my device did not boot anymore once the patched framework-res.apk was in place (and booted again once I piut back the original apk). Did I miss a step? Thks in advance for your help.
[Android Software/Hacking General [Developers Only]] AnonVendetta:
@Nyakov: the download isnt dead, try again.

@Julien Faure: You probably didnt do anything wrong. I tried this same patch on Resurrection Remix Nougat many months ago, ROM wouldnt boot. I suspect that you need to disable Android's signature verification for this to work. Check out Smali Patcher.
[Android Software/Hacking General [Developers Only]] Julien Faure:
Thansk a lot for the quick answer! If possible, I would like to avoid rooting (and thus avoid Magisk): is there a way to disable signature verification w/o it? Something to be done, applied, installed from TWRP for instance.
[Android Software/Hacking General [Developers Only]] AnonVendetta:
@Julien Faure: Smali patcher doesnt need root. It doesnt even need Magisk, despite being listed as a Magisk module on XDA.

Follow the steps in the SP thread. Since all you want is signature verification disabled, only check that box. Once it is successful, it will create a zip file. Extract the services.jar from that, boot into TWRP, replace your services.jar with the new one, set permissions on this file to 0644.

In the zip SP produces, there will also be zero byte (0 in size) files. These are placemarkers that tell Magisk to systemlessly delete these files. But since you wont be using Magisk, you need to look in /system/framework and manually delete these files. So just find the ones that match the paths and names of the zero byte files in the zip, delete them. If you cant find all of them, just skip the ones not present.

Because you are modifying the system partition, you may also need to disable dm-verity and/or Verified Boot (AVB). But since you're patching LOS, i dont believe it will be necessary.
[Android Software/Hacking General [Developers Only]] Julien Faure:
Wow thanks a lot again. Will report here once I will have tested that.
[Android Software/Hacking General [Developers Only]] Julien Faure:
@AnonVendetta: BTW, are you aware of any ROM (not necessarily for the 5X) which supports the UNLP + GApps configuration "out-of-the-box" w/o having to apply those patches (OP's one + Smali)? Seems to me that a lot of ROMs (if not all) decided to support the "microG as a gmscore replacement" scenario only.
[Android Software/Hacking General [Developers Only]] AnonVendetta:
@Julien Faure: No i'm not aware of any ROM that only supports UnifiedNlp.

Try with signature verification patch only, see if ROM boots. Then try UnifiedNlp patch after that.

If it doesnt work, you can send me the zip that Smali Patcher produces, i can try to patch it. I'll also need a copy of your /system/framework/ directory, just compress it into a zip file.
[Android Software/Hacking General [Developers Only]] Julien Faure:
@AnonVendetta: I'm afraid I did not explain properly what I'm looking for. I'm not looking for a ROM that only supports UnifiedNlp but for a ROM that supports UnifiedNlp (as a location provider) in addition of supporting microG (as a Play Services replacement and thus as a location provider). In short, a ROM that does not require the OP's patch! 🙂

Finally thanks for the helping hand proposal, I will get back here once I will have get a chance to try the Smali patcher patch.