yashsingh1/xdaforums huggingface dataset:
[OnePlus 3 Guides, News, & Discussion] MrGimpGrumble:
I followed you guide step by step but after i do "brunch oneplus3" i get this;

Repository synced!

Looking for dependencies

Done

build/core/product_config.mk:250: *** _nic.PRODUCTS.[[device/oneplus/oneplus3/cm.mk]]: "vendor/qcom/binaries/msm8996/graphics/graphics-vendor.mk" does not exist. Stop.

build/core/product_config.mk:250: *** _nic.PRODUCTS.[[device/oneplus/oneplus3/cm.mk]]: "vendor/qcom/binaries/msm8996/graphics/graphics-vendor.mk" does not exist. Stop.

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

** Do you have the right repo manifest?

No such item in brunch menu. Try 'breakfast'
[OnePlus 3 Guides, News, & Discussion] madeferro:
Read page 6
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
Take the lines from page 7 from my post and add them to your roomservice.xml
[OnePlus 3 Guides, News, & Discussion] cohaolain:
Will update everything and post again here when I'm home :)
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
How long do you work?
[OnePlus 3 Guides, News, & Discussion] cohaolain:
Monday-Thursday I have school at 9-6, Fridays from 9-4. Then I work on a lot of different voluntary jobs outside school, which I work on at home. I don't actually have a job at the moment, I quit my job as a sales assistant in a retailer earlier this year so I'd have more time to study and do my own work :) I'm 16, so I don't have to have a job, and I only had it so I could save up money to build my PC :)
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
Ah interesting :)
[OnePlus 3 Guides, News, & Discussion] cohaolain:
Everything's updated guys! :D

Huge thanks to [MENTION=6180398]madeferro[/MENTION] for the missing manifest line and to [MENTION=6211832]panther124[/MENTION] for finding the commands to setting the RAM limit :)

Hope everything's working smoothly now!

I've updated the guide to fix your problem. Please redo your roomservice.xml with the 'nano' command.

You'll also need to perform the steps under "setting RAM for building process" to ensure you don't have a memory overhead error, those steps were just added now :)

SSDs are recommended for building CyanogenMod. Will mention that in the guide now :) If you already have an SSD, it might be the VM that's bottlenecking.
[OnePlus 3 Guides, News, & Discussion] madeferro:
I get this error every time:

1)

[ 33% 17001/50997] Protoc: /home/made/android/system/out/target/common/obj/JAVA_LIBRARIES/sap...tatic_intermediates/src/proto/Proto.stamp <= hardware/ril-caf/librilutils/proto/sap-api.protoninja: fatal: fork: Cannot allocate memory

build/core/ninja.mk:151: fallo en las instrucciones para el objetivo 'ninja_wrapper'

make: *** [ninja_wrapper] Error 1

make: se sale del directorio '/home/made/android/system'

#### make failed to build some targets (01:11:24 (hh:mm:ss)) ####

2) time

[ 33% 17032/51002] build /home/made/an..._current_intermediates/classes.dex.tocninja: fatal: fork: Cannot allocate memory

build/core/ninja.mk:151: fallo en las instrucciones para el objetivo 'ninja_wrapper'

make: *** [ninja_wrapper] Error 1

make: se sale del directorio '/home/made/android/system'

#### make failed to build some targets (01:17:53 (hh:mm:ss)) ####
[OnePlus 3 Guides, News, & Discussion] MrGimpGrumble:
OK, so this is the furthest i've gotten so far haha...

i am using parallels on a macbook pro FYI. followed all instructions etc;

Usage: javac <options> <source files>
use -help for a list of possible options
[ 4% 2300/51002] target Java: tzdata_update (/home/Nate/android/sys...arget/common/obj/JAVA_LIBRARIES/tzdata_update_intermediates/classes)
ninja: build stopped: subcommand failed.
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
make: Leaving directory '/home/Nate/android/system'

#### make failed to build some targets (13:46 (mm:ss)) ####

this looks different then the others with RAM and CACHE etc... any ideas what i may have done wrong?

Thanks!
[OnePlus 3 Guides, News, & Discussion] MrGimpGrumble:
In CM13 build manual by CM they state to go here: ~/android/system/build/tools/releasetools/common.py

and to change the -Xmx2048m is this the same as export JACK_SERVER_VM_ARGUMENTS=”-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx4g” ??

Thanks
[OnePlus 3 Guides, News, & Discussion] cohaolain:
Memory error.... hmmmm.

How much RAM is dedicated to your VM? Also try replace the line 'export JACK......' with the amount of RAM your VM has - 1 where I'm going to write '7'.

export JACK_SERVER_VM_ARGUMENTS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx7g"
[OnePlus 3 Guides, News, & Discussion] cohaolain:
I'm not sure.... And I can't see how running a VM on a mac would make a difference :(
[OnePlus 3 Guides, News, & Discussion] cohaolain:
Also I think these are the same, but if you want to see if it makes any difference to you be my guest :) Also [MENTION=6180398]madeferro[/MENTION] you might want to give this a go if increasing VM RAM and using the first method of changing the RAM don't work :)
[OnePlus 3 Guides, News, & Discussion] madeferro:
I think we need 8gb ram unfortunately to build cm 14.
[OnePlus 3 Guides, News, & Discussion] MrGimpGrumble:
I just increased it from 4gb to 6gb. Unfortunately I only have 8gb total on my MacBook...

I may have to try using my desktop as I have much more RAM to utilize.. thanks
[OnePlus 3 Guides, News, & Discussion] colourfuldays:
Hi all friends!I am using this method to build Victara,but I faced problem.plz can anyone help me?
[OnePlus 3 Guides, News, & Discussion] slothdabski:
You should probably post in a moto forum. This thread is specific to oneplus 3
[OnePlus 3 Guides, News, & Discussion] cohaolain:
Better suited to moto forums ;) Although this error was a result of a commit that broke all CM14 builds for a while. The fix has now been merged into the main repo, so 'repo sync' should fix it. Fair play for using the guide for a different phone :) Glad it's being used well :P
[OnePlus 3 Guides, News, & Discussion] colourfuldays:
I didn't find the guide article in moto forums?,so I had to ask here?.

but I appreciate you to help me find the solution! thank u!?
[OnePlus 3 Guides, News, & Discussion] mikey1975:
First of all, many thanks for this guide, was looking for a long time on getting started building own ROM. :good:

I have been looking back and forward in many threads, but until now, still unable to get a build completed.

Tried als previously described here to edit some lines of code, but keep having these ninja errors... :confused:

Usage: javac <options> <source files>

use -help for a list of possible options

ninja: build stopped: subcommand failed.

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

make: *** [ninja_wrapper] Error 1

make: Leaving directory '/home/android/Desktop/MICHAEL'

#### make failed to build some targets ####

android@builduntu-VM:~/Desktop/MICHAEL$

Am I missing something somewhere...??
[OnePlus 3 Guides, News, & Discussion] slothdabski:
Have you tried disabling ninja?

Use:

export USE_NINJA=false

Add that line to your .bashrc file for it apply to every build you run, if it solves your error
[OnePlus 3 Guides, News, & Discussion] cohaolain:
Haven't posted over there since the end of this guide applies only to the OP3, but will hopefully be branching the guide out a bit more in the near future :P

Could you send a bit more detail of what came right before the error?

Although this might indeed fix stuff I'd still rather make it work in ninja, maybe this is a temporary error that's broke ninja but compiles fine without? Cause I've seen people build successfully with this guide in the past week with ninja :L
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
Hey i tried it again and it does not work anymore.

I had success last week
[OnePlus 3 Guides, News, & Discussion] cohaolain:
Can you send a screenshot of the error window and any important information before that? :)

Want to find out if this is a CM issue :L
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
the same as the other people here.

sub command failed

ninja error

one time at 1hour and 30 minutes and the other time at 30 minutes.

the problem is i give up now. i had success but this is enough. i installed aicp 12 so i do not have to build cm14 by myself.

the wait time and the errors. i am tired of that. sorry for that :/

maybe i will re install ubuntu and try it again. because my ubuntu is full with trash. i deleted the source so many time that my disc is nearly full. and the paper bin will not clear.
[OnePlus 3 Guides, News, & Discussion] jamal2367:
Building CM14
[OnePlus 3 Guides, News, & Discussion] mikey1975:
Thanks for the advice, will try when can spare a free moment at my computer. ;)

- EDIT - Tried to follow your advice, did a -make clean- command and then -repo sync-.

Got this following error;

yncing work tree: 12% (71/588) fatal: Unable to create '/home/android/Desktop/MICHAEL/external/cros/system_api/.git/index.lock': File exists.

If no other git process is currently running, this probably means a

git process crashed in this repository earlier. Make sure no other git

process is running and remove the file manually to continue.

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

error: external/cros/system_api/: platform/external/cros/system_api checkout 661a1e472cb3254899a6e2b4c00e605119debca3

android@builduntu-VM:~/Desktop/MICHAEL$
[OnePlus 3 Guides, News, & Discussion] colourfuldays:
Did u solve this issue？

update:I faced this issue too .but I'm sure I certainly installed Java,so I just reboot system and it never happen again.
[OnePlus 3 Guides, News, & Discussion] colourfuldays:
well finally I fix this issue.if anyone face this issue so just follow the message located to failed files and add resource .that can fix issue!
[OnePlus 3 Guides, News, & Discussion] colourfuldays:
sorry guys I bother your again,i hope someone can give me ideas?

very very appreciate!!
[OnePlus 3 Guides, News, & Discussion] SamuelBegui:
I was experiencing the same thing during my try at building CM14, is the Ninja compiler not working for CM14?
[OnePlus 3 Guides, News, & Discussion] slothdabski:
I'm not sure. I learned to build from a nexus thread when I had a nexus 6. That tutorial said to just disable ninja if you get any errors related to it. It always seems to work when I get a ninja error. Since that was a nexus thread about building an aosp rom, the reason probably isn't related to CM.

Is there any disadvantage to disabling ninja?
[OnePlus 3 Guides, News, & Discussion] superior888:
Great thread. I'm building now. Can someone explain how cherry picks work?
[OnePlus 3 Guides, News, & Discussion] slothdabski:
http://xdaforums.com/showthread.php?t=2763236

The hardest part is going through code to fix conflicts. Good luck!!!
[OnePlus 3 Guides, News, & Discussion] colourfuldays:
yeah I've completed my own cm14.Thx this excellent guide!

but why in my product there is no zip file?last time I build RR when the completed ,the zip files was also in the product,why this time not?

edit:the next time I used brunch rather make ,and everything was alright including installation package.
[OnePlus 3 Guides, News, & Discussion] mikey1975:
Not yet, still trying and looking around a lot.

Found these manuals, which I personally found very usefully: https://source.android.com/source/index.html - https://wiki.cyanogenmod.org/w/Build_for_oneplus3
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
It says that no Jack Server Installation was found.

I installed ubuntu New but it does not work
[OnePlus 3 Guides, News, & Discussion] slothdabski:
git clone https://github.com/akhilnarang/scripts

cd scripts

ls

bash

should be one of the scripts in the folder for your particular architecture. The script will install everything needed for building

---------- Post added at 03:19 PM ---------- Previous post was at 03:15 PM ----------

If you're still getting jack server errors, try making the following script by making a txt file:

#!/bin/bash
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

Replace the 4g with the gigs of ram in your build macing, 8g, 16g, etc

Save it without an extension, then

chmod 755 killjack

Put it in your build folder and run

./killjack

Prior to building
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
marcoj@marcoj-desktop:~/android/system$ export JACK_SERVER_VM_ARGUMENTS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx7g"

marcoj@marcoj-desktop:~/android/system$ ./prebuilts/sdk/tools/jack-admin kill-server

Killing background server

No Jack server to kill

marcoj@marcoj-desktop:~/android/system$ ./prebuilts/sdk/tools/jack-admin start-server

Jack server installation not found

or

marcoj@marcoj-desktop:~/android/system$ ./killjack

Killing background server

No Jack server to kill

Jack server installation not found

marcoj@marcoj-desktop:~/android/system$
[OnePlus 3 Guides, News, & Discussion] slothdabski:
Did you run the script from github first and did it install everything successfully?
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
yes.
[OnePlus 3 Guides, News, & Discussion] superior8888:
Seems like cm14.1 is on the way. Anyone try to compile?

Skickat från min ONEPLUS A3003 via Tapatalk
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
i will try. but with the jack error it does not work. i will download another prepared ubuntu which MUST work because i built a cm14 on this already successful
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
downloaded the cm14.1 source successful.

making roomservice.xml now.

can i take the old manifest text for cm14.1?

only change the cm14.0 to 14.1?

sorry for two posts :/

forgot that i had made a post already
[OnePlus 3 Guides, News, & Discussion] slothdabski:
You have to check the repo to see if there is a new branch for 14.1. If not, then leave it as cm14.0
[OnePlus 3 Guides, News, & Discussion] cohaolain:
To build for 14.1, run repo init again but change cm-14.0 to cm-14.1. Then open the roomservice.xml file and change all the cm-14.0 lines to cm-14.1, and finally run repo sync. You should now be able to build as usual :)
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
To update just run repo sync?

Because someone said that the pocket mode fix is already but i made an updated ZIP and it is not fixed
[OnePlus 3 Guides, News, & Discussion] cohaolain:
You need to cherry-pick it manually. It hasn't been verified yet, meaning it hasn't been merged into the official repositories yet. You can find the two pocket mode commits for cm-14.1 on review.cyanogenmod.com if you search for pocket mode. You'll need both parts one and two. You'll have the right ones if my name's beside them, I committed them :P

Sorry it took so long to get back to you, I've been working on my own ROM and I must've missed your post quote in my notifications :(

Edit: sorry mate, I only read the username now and realised I already talked to you about this a few days ago! ;)
[OnePlus 3 Guides, News, & Discussion] Roi007leaf:
Hey bro,is it possible to flash SuperSU on your builds?
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
I cherry picked it but it is not included :(

I made repo sync and after that i cherry picked the two commits from you. There was no error.

I am New with cherry picking so i read an guide in the Internet for this

http://xdaforums.com/showpost.php?p=52925641&postcount=2

I like building Android so much that i will not give up :)
[OnePlus 3 Guides, News, & Discussion] cohaolain:
That's weird, it works fine for me.

'cd kernel/oneplus/msm8996 && git status' and let me know what it says :)
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
Ok when i am home.

I remember with git status it says something with a red Text and only one line. There was a number.

Idk. But when i am home i will look again.

Something with "dis......"
[OnePlus 3 Guides, News, & Discussion] gururoop:
Can anyone please tell me what commit needs to be cherry picked to have data traffic monitor on statusbar in CM14.1?
[OnePlus 3 Guides, News, & Discussion] cohaolain:
There isn't one :/
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
here it is:

marcoj@marcoj-desktop:~/android/system/kernel/oneplus/msm8996$ git status
HEAD detached from 4a37fcf
nothing to commit, working directory clean
[OnePlus 3 Guides, News, & Discussion] mikey1975:
- DELETED-
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
that is not a error. that is a command which you should use.

[MENTION=1177459]coha[/MENTION]colain see my post above
[OnePlus 3 Guides, News, & Discussion] cohaolain:
Run this command:

cd ~/android/system/kernel/oneplus/msm8996 && repo start cm-14.1 && git fetch http://review.cyanogenmod.org/CyanogenMod/android_kernel_oneplus_msm8996 refs/changes/43/168143/1 && git cherry-pick FETCH_HEAD && git status

And let me know what it says.

You should get something like "1 commit ahead of cm-14.1" which means you have one commit more than the official branch (the pocket mode commit). If you do, the cherry-pick went fine.

Then for part two of the commit, run the following:

cd ~/android/system/device/oneplus/oneplus3 && repo start cm-14.1 && git fetch http://review.cyanogenmod.org/CyanogenMod/android_device_oneplus_oneplus3 refs/changes/29/167929/3 && git cherry-pick FETCH_HEAD && git status

You should also get the "1 commit ahead" type message.

Always run the repo start *branch name* before making any changes or cherry picks in a repository to make sure all changes are tracked properly :) Sorry I didn't mention that already.

If all that works well, you should be able to build fine with the pocket mode working! :P
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
I will try if i am back from school :D

Thank you
[OnePlus 3 Guides, News, & Discussion] mikey1975:
My bad, wrong copy/paste... :o
[OnePlus 3 Guides, News, & Discussion] Roi007leaf:
My god the cannot allocate memory error.. Is hell
[OnePlus 3 Guides, News, & Discussion] gururoop:
I tried building crdroid in a virtualbox image and got the following error:

Internal compiler error (version 1.2-rc4 'Carnac' (298900 f95d7bdecfceb327f9d201a1348397ed8a843843 by android-jack-team@google.com)).
com.android.sched.scheduler.MultiWorkersScheduleInstance$SequentialTask cannot be cast to com.android.sched.scheduler.MultiWorkersScheduleInstance$ShutdownTask.
Warning: This may have produced partial or corrupted output.
make: *** [/home/gururoop/android/crdroid/out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/with-local/classes.dex] Error 41
make: *** Waiting for unfinished jobs....

#### make failed to build some targets (18:52:28 (hh:mm:ss)) ####

any ideas what went wrong?
[OnePlus 3 Guides, News, & Discussion] Ph0enix_216:
If you Google "make error 41"out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/with-local/classes.dex]" then you might be able to find an instance where someone else got that error, and see if they got the solution from someone else.

Just my $.02
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
Google it

I solved mostly All my problem with Google.

So do Not waste you time and wait for an answer
[OnePlus 3 Guides, News, & Discussion] ibaii:
Sorry if the answer is in the previous pages but still get the same error:

ninja: build stopped: subcommand failed.

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

make: *** [ninja_wrapper] Error 1

make: Leaving directory '/home/ibaii/android/system'
[OnePlus 3 Guides, News, & Discussion] gururoop:
I successfully built crdroid from source, but as is the case with official release, it is missing the option to kill an app by holding back button in developer options. Is there a commit that can be cherry picked to bring the option in this rom?
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
Run 'repo init roomservice.xml'

And then repo Sync again

And then built again
[OnePlus 3 Guides, News, & Discussion] Acxjet:
And you know what? Thanks, man! It fixed my Ninja errors, and allowed me to build the rom
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
Yeah glad to hear that!

I had the same Problem.

[MENTION=5552241]cohaolain[/MENTION]

I think you can make a q&a for Main Problems like this
[OnePlus 3 Guides, News, & Discussion] mikey1975:
Today finally compiled my first build, took 3hrs 10min to complete. :)

Now try to locate where the .zip file is located, and start testing on my phone.:p

Package Complete: /home/michael/android/system/out/target/product/oneplus3/cm-13.0-20161110-UNOFFICIAL-oneplus3.zip

#### make completed successfully (02:52:18 (hh:mm:ss)) ####
[OnePlus 3 Guides, News, & Discussion] twinnfamous:
that's a Javac error. make sure proper version of Javac is used as well as it being in the path. I forgot the exact command but it's the same as configuring Java just with a c after
[OnePlus 3 Guides, News, & Discussion] aadityarulez:
Is there any way to know the size of the repo for cm14.1? I've download over 40gb now.
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
Try this from my previous post
[OnePlus 3 Guides, News, & Discussion] aadityarulez:
I'm new to compiling roms? I thought repo sync needs a source for the repo, how does initializing roomservice work?
[OnePlus 3 Guides, News, & Discussion] MarcoLK:
I dont know exactly. But These ninja errors comes from the local Manifest (roomservice.xml)

You have to initialize this to prevent errors
[OnePlus 3 Guides, News, & Discussion] mikey1975:
Found this;

Building for a specific device

I usually build under a "screen" as I'm building on a remote machine, so that SSH disconnects don't affect the build. So let's enter into a "screen",

screen

In this guide, I'm building CyanogenMod for the OnePlus 3, so I use the device name "oneplus3" here to specify building CyanogenMod for the OnePlus 3

source build/envsetup.sh

breakfast oneplus3

Loading in the device specific blobs

Edit the roomservice.xml file to ensure it has all the correct repos listed,

nano ~/android/system/.repo/local_manifests/roomservice.xml

And make sure it contains the following,

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

<manifest>

<project name="CyanogenMod/android_device_oppo_common" path="device/oppo/common" remote="github" revision="cm-14.0" />

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

<project name="TheMuppets/proprietary_vendor_oneplus" path="vendor/oneplus" remote="github" revision="cm-14.0" />

<project name="CyanogenMod/android_device_oneplus_oneplus3" path="device/oneplus/oneplus3" remote="github" revision="cm-14.0" />

<project name="CyanogenMod/android_kernel_oneplus_msm8996" path="kernel/oneplus/msm8996" remote="github" revision="cm-14.0" />

<project name="CyanogenMod/android_external_sony_boringssl-compat" path="external/sony/boringssl-compat" remote="github" revision="cm-14.0" />

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

<project name="CyanogenMod/android_vendor_nxp-nfc_opensource_Nfc" path="vendor/nxp-nfc/opensource/Nfc" remote="github" revision="cm-14.0" />

<project name="CyanogenMod/android_vendor_nxp-nfc_opensource_frameworks" path="vendor/nxp-nfc/opensource/frameworks" remote="github" revision="cm-14.0" />

<project name="CyanogenMod/android_vendor_nxp-nfc_opensource_libnfc-nci" path="vendor/nxp-nfc/opensource/libnfc-nci" remote="github" revision="cm-14.0" />

</manifest>

The "TheMuppets/proprietary_vendor_oneplus" line is important, as it contains all the proprietary blobs for the OnePlus 3.

Save the file and then run a sync again,

cd ~/android/system/

repo sync

It shouldn't take long this time, as it only downloads the proprietary blobs.
[OnePlus 3 Guides, News, & Discussion] aadityarulez:
I am trying to sync sources for aosp for 7.0. The download is at 41gb and still going on. Does anyone know how much size is the source code? Sorry it's not about CM.
[OnePlus 3 Guides, News, & Discussion] Ost268:
hardware/ril-caf/librilutils/proto/sap-api.pb.h error compiling cm14.1