December 28th, 2019 rev1
Change-Id: Ibe61c94cfee17225b80f04a7b0845eaf51a32658
diff --git a/BlissRoms/build-guide/index.html b/BlissRoms/build-guide/index.html
index 1920922..fe9ccae 100644
--- a/BlissRoms/build-guide/index.html
+++ b/BlissRoms/build-guide/index.html
@@ -376,13 +376,6 @@
</li>
- <li class="md-nav__item">
- <a href="#what-if-i-need-repo-globally" class="md-nav__link">
- What if I need repo globally?
- </a>
-
-</li>
-
</ul>
</nav>
@@ -393,19 +386,6 @@
Download
</a>
- <nav class="md-nav">
- <ul class="md-nav__list">
-
- <li class="md-nav__item">
- <a href="#i-still-dont-know-how-much-cpu-threads-i-have-how-do-i-check" class="md-nav__link">
- I still don't know how much CPU threads I have. How do I check?
- </a>
-
-</li>
-
- </ul>
- </nav>
-
</li>
<li class="md-nav__item">
@@ -682,13 +662,6 @@
</li>
- <li class="md-nav__item">
- <a href="#what-if-i-need-repo-globally" class="md-nav__link">
- What if I need repo globally?
- </a>
-
-</li>
-
</ul>
</nav>
@@ -699,19 +672,6 @@
Download
</a>
- <nav class="md-nav">
- <ul class="md-nav__list">
-
- <li class="md-nav__item">
- <a href="#i-still-dont-know-how-much-cpu-threads-i-have-how-do-i-check" class="md-nav__link">
- I still don't know how much CPU threads I have. How do I check?
- </a>
-
-</li>
-
- </ul>
- </nav>
-
</li>
<li class="md-nav__item">
@@ -816,7 +776,7 @@
<pre><code>sudo apt install git gnupg flex bison gperf build-essential zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 lib32ncurses5-dev x11proto-core-dev libx11-dev lib32z-dev lib32z1-dev ccache libgl1-mesa-dev libxml2 libxml2-utils xsltproc unzip squashfs-tools python python-mako libssl-dev ninja-build lunzip syslinux syslinux-utils gettext genisoimage bc xorriso liblz4-tool libncurses5-dev libsdl1.2-dev libwxgtk3.0-dev lzop maven pngcrush schedtool lib32readline-dev
</code></pre>
<h3 id="install-source-code-tools">Install source code tools</h3>
-<p>Now we need to get the source code via a program named <code>repo</code>, made by Google. The primary function of <code>repo</code> is to read a manifest file located in BlissRoms's GitHub organization, and find what repositories you need to actually build Android.</p>
+<p>Now we need to get the source code via a program named <code>repo</code>. The primary function of <code>repo</code> is to read a manifest file located in BlissRoms's GitHub organization, and find what repositories you need to actually build Android.</p>
<p>Create a <code>~/bin</code> directory for <code>repo</code>:</p>
<pre><code>mkdir -p ~/bin
</code></pre>
@@ -842,40 +802,23 @@
<h4 id="what-is-source">What is <code>source</code>?</h4>
<p><code>source</code> is a <code>bash</code> command to read aliases, functions, and commands from the specified file. Typically, you'll supply <code>bash</code> with a configuration file such as <code>.bashrc</code> or <code>.bash_profile</code>, or an initialization file such as <code>envsetup.sh</code>. The difference is that while the configuration file lists configuration and user-defined aliases and functions, initialization files typically hold build commands such as <code>breakfast</code>, <code>brunch</code>, and <code>lunch</code>. Without those commands building would be significantly harder as you would have to memorize the long command to invoke a build manually!</p>
<p>But why do you need to run it after modifying a file? Well, <code>bash</code> cannot automatically detect changes in our files. To solve this, we either <code>source</code> it or log out and log back in, forcing <code>bash</code> to reload configuration files. Keep this in mind, because unlike configuration files, if you forget to <code>source</code> initialization files, build commands will not function!</p>
-<h4 id="what-if-i-need-repo-globally">What if I need <code>repo</code> globally?</h4>
-<p>If you need the <code>repo</code> tool to be available anywhere, you will need to first download <code>repo</code> to your home directory, move it with <code>sudo</code> and give it executable permissions. The exact commands are as follows:</p>
-<pre><code>curl https://storage.googleapis.com/git-repo-downloads/repo > ~/repo
-sudo mv ~/repo /usr/bin/
-chmod a+x /usr/bin/repo
-</code></pre>
-<p><code>repo</code> will now work anywhere, without any <code>.bashrc</code> modifications. However, these steps aren’t recommended as <code>repo</code> might become a security risk if a vulnerability is found.</p>
-<p>Now we’re ready to download the source code.</p>
<h3 id="download">Download</h3>
<p>Create a directory for the source:</p>
<pre><code>mkdir -p ~/bliss/q
cd ~/bliss/q
</code></pre>
<p>Before we download, we need to tell <code>repo</code> and <code>git</code> who we are. Run the following commands, substituting your information:</p>
-<pre><code>git config --global user.email “randy.mcrandyface@hotmail.net”
-git config --global user.name “Randy McRandyface”
+<pre><code>git config --global user.email "john.appleseed@example.com"
+git config --global user.name "John Appleseed"
</code></pre>
<p>Now, we’re ready to initialize. We need to tell <code>repo</code> which manifest to read:</p>
<pre><code>repo init -u https://github.com/BlissRoms/platform_manifest.git -b q
</code></pre>
<p><code>-b</code> is for the branch, and we’re on <code>q</code>, Android 10. It’ll take a couple of seconds. You may need to type <code>y</code> for the color prompt.</p>
<p>Then sync the source:</p>
-<pre><code>repo sync -j24 -c
+<pre><code>repo sync -j$(nproc --all) -c
</code></pre>
-<p><code>-j</code> is for threads. Typically, your CPU core count is your thread count, unless you’re using an older Intel CPU with hyperthreading. In that case, the thread count is double the count of your CPU cores. Newer CPUs have dropped hyperthreading unless you have the i9, so check how many threads you have. If you have four threads, you would run:</p>
-<pre><code>repo sync -j4 -c
-</code></pre>
-<p><code>-c</code> is for pulling in only the current branch, instead of the entire history. This is useful if you need the downloads fast and don’t want the entire history to be downloaded. This is used by default unless specified otherwise.</p>
-<h4 id="i-still-dont-know-how-much-cpu-threads-i-have-how-do-i-check">I still don't know how much CPU threads I have. How do I check?</h4>
-<p>Run <code>nproc</code>. The output should be something like this:</p>
-<pre><code>rwaterspf1@test:~$ nproc
-24
-</code></pre>
-<p>This means that there are 24 threads in your machine.</p>
+<p><em>Note: For more information about the <code>repo</code> tool, visit the <a href="../build-tips/">Build Tips guide</a> to learn more about the <a href="../build-tips/#repo-optimization-tips">repo flags</a>.</em></p>
<p><code>repo</code> will start downloading all the code. That’s going to be slow, even on a fiber network. Expect downloads to take more than a couple hours.</p>
<h3 id="build">Build</h3>
<p>Set up the build environment:</p>
@@ -927,9 +870,10 @@
<li>Make sure you sourced <code>build/envsetup.sh</code>. This is especially common and worth suspecting if none of the build commands like <code>breakfast</code> and <code>lunch</code> work. If you have <code>repo sync</code>ed do this again.</li>
<li>Make sure you’re at the root of the build tree. Again, to quickly jump there, use <code>croot</code>.</li>
<li>Make sure you ran <code>breakfast</code> correctly and it did not error out. Missing device files will prevent successful builds.</li>
-<li>Make sure your computer itself isn’t faulty. HDDs usually die first, followed by RAM. SSDs rarely die but failure is not unheard of. In extremely rare cases, your CPU may have a defect. If you're unsure, run a stress test using a program like Prime95.</li>
+<li>Make sure your computer meets minimum requirements to compile AOSP. Chances are, you need more memory/CPU power to complete a build.</li>
+<li>Make sure your computer isn't faulty. This is unlikely, but to check, use a stress-test program like Prime95.</li>
</ul>
-<p>If something goes wrong and you've tried everything above, first use Google to look up your error! Most of the errors you encounter is due to misconfiguration and wrong commands entered. More often than not, Google will have the answer you are looking for. If you're still stuck and nothing fixes the problem, then ask us via our Telegram Build Support chat.</p>
+<p>If something goes wrong and you've tried everything above, first use Google to look up your error! Most of the errors you encounter is due to misconfiguration and wrong commands entered. More often than not, Google will have the answer you are looking for. If you're still stuck and nothing fixes the problem, then ask us via <a href="https://t.me/Team_Bliss_Build_Support">our Telegram Build Support chat.</a> (Please only ask issues about BlissRoms, not other custom ROMs as we are unable to assist with those!)</p>
<h3 id="conclusion">Conclusion</h3>
<p>Building a ROM is very hard and tedious and the results are very rewarding! If you managed to follow along, congratulations!</p>
<p>After you finish building, you can try out the Git Started guide. Make changes, commit, and send them off to our Gerrit for review! Or better yet, download experimental commits not ready for the mainline repositories and review them! Again, ROM building is a fun project you can work with. I hope this guide was a lot of fun to run through!</p>