Eric Park | c993199 | 2019-07-29 13:10:53 +0900 | [diff] [blame^] | 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | <!doctype html> |
| 6 | <html lang="en" class="no-js"> |
| 7 | <head> |
| 8 | |
| 9 | <meta charset="utf-8"> |
| 10 | <meta name="viewport" content="width=device-width,initial-scale=1"> |
| 11 | <meta http-equiv="x-ua-compatible" content="ie=edge"> |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | <meta name="lang:clipboard.copy" content="Copy to clipboard"> |
| 17 | |
| 18 | <meta name="lang:clipboard.copied" content="Copied to clipboard"> |
| 19 | |
| 20 | <meta name="lang:search.language" content="en"> |
| 21 | |
| 22 | <meta name="lang:search.pipeline.stopwords" content="True"> |
| 23 | |
| 24 | <meta name="lang:search.pipeline.trimmer" content="True"> |
| 25 | |
| 26 | <meta name="lang:search.result.none" content="No matching documents"> |
| 27 | |
| 28 | <meta name="lang:search.result.one" content="1 matching document"> |
| 29 | |
| 30 | <meta name="lang:search.result.other" content="# matching documents"> |
| 31 | |
| 32 | <meta name="lang:search.tokenizer" content="[\s\-]+"> |
| 33 | |
| 34 | <link rel="shortcut icon" href="../../assets/images/favicon.png"> |
| 35 | <meta name="generator" content="mkdocs-1.0.4, mkdocs-material-4.4.0"> |
| 36 | |
| 37 | |
| 38 | |
| 39 | <title>BuildGuide - Team Bliss</title> |
| 40 | |
| 41 | |
| 42 | |
| 43 | <link rel="stylesheet" href="../../assets/stylesheets/application.0284f74d.css"> |
| 44 | |
| 45 | |
| 46 | |
| 47 | |
| 48 | <script src="../../assets/javascripts/modernizr.74668098.js"></script> |
| 49 | |
| 50 | |
| 51 | |
| 52 | <link href="https://fonts.gstatic.com" rel="preconnect" crossorigin> |
| 53 | <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,400i,700|Roboto+Mono&display=fallback"> |
| 54 | <style>body,input{font-family:"Roboto","Helvetica Neue",Helvetica,Arial,sans-serif}code,kbd,pre{font-family:"Roboto Mono","Courier New",Courier,monospace}</style> |
| 55 | |
| 56 | |
| 57 | <link rel="stylesheet" href="../../assets/fonts/material-icons.css"> |
| 58 | |
| 59 | |
| 60 | |
| 61 | |
| 62 | |
| 63 | |
| 64 | </head> |
| 65 | |
| 66 | <body dir="ltr"> |
| 67 | |
| 68 | <svg class="md-svg"> |
| 69 | <defs> |
| 70 | |
| 71 | |
| 72 | </defs> |
| 73 | </svg> |
| 74 | <input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="__drawer" autocomplete="off"> |
| 75 | <input class="md-toggle" data-md-toggle="search" type="checkbox" id="__search" autocomplete="off"> |
| 76 | <label class="md-overlay" data-md-component="overlay" for="__drawer"></label> |
| 77 | |
| 78 | <a href="#buildguide" tabindex="1" class="md-skip"> |
| 79 | Skip to content |
| 80 | </a> |
| 81 | |
| 82 | |
| 83 | <header class="md-header" data-md-component="header"> |
| 84 | <nav class="md-header-nav md-grid"> |
| 85 | <div class="md-flex"> |
| 86 | <div class="md-flex__cell md-flex__cell--shrink"> |
| 87 | <a href="../.." title="Team Bliss" class="md-header-nav__button md-logo"> |
| 88 | |
| 89 | <i class="md-icon"></i> |
| 90 | |
| 91 | </a> |
| 92 | </div> |
| 93 | <div class="md-flex__cell md-flex__cell--shrink"> |
| 94 | <label class="md-icon md-icon--menu md-header-nav__button" for="__drawer"></label> |
| 95 | </div> |
| 96 | <div class="md-flex__cell md-flex__cell--stretch"> |
| 97 | <div class="md-flex__ellipsis md-header-nav__title" data-md-component="title"> |
| 98 | |
| 99 | <span class="md-header-nav__topic"> |
| 100 | Team Bliss |
| 101 | </span> |
| 102 | <span class="md-header-nav__topic"> |
| 103 | |
| 104 | BuildGuide |
| 105 | |
| 106 | </span> |
| 107 | |
| 108 | </div> |
| 109 | </div> |
| 110 | <div class="md-flex__cell md-flex__cell--shrink"> |
| 111 | |
| 112 | <label class="md-icon md-icon--search md-header-nav__button" for="__search"></label> |
| 113 | |
| 114 | <div class="md-search" data-md-component="search" role="dialog"> |
| 115 | <label class="md-search__overlay" for="__search"></label> |
| 116 | <div class="md-search__inner" role="search"> |
| 117 | <form class="md-search__form" name="search"> |
| 118 | <input type="text" class="md-search__input" name="query" placeholder="Search" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="query" data-md-state="active"> |
| 119 | <label class="md-icon md-search__icon" for="__search"></label> |
| 120 | <button type="reset" class="md-icon md-search__icon" data-md-component="reset" tabindex="-1"> |
| 121 |  |
| 122 | </button> |
| 123 | </form> |
| 124 | <div class="md-search__output"> |
| 125 | <div class="md-search__scrollwrap" data-md-scrollfix> |
| 126 | <div class="md-search-result" data-md-component="result"> |
| 127 | <div class="md-search-result__meta"> |
| 128 | Type to start searching |
| 129 | </div> |
| 130 | <ol class="md-search-result__list"></ol> |
| 131 | </div> |
| 132 | </div> |
| 133 | </div> |
| 134 | </div> |
| 135 | </div> |
| 136 | |
| 137 | </div> |
| 138 | |
| 139 | </div> |
| 140 | </nav> |
| 141 | </header> |
| 142 | |
| 143 | <div class="md-container"> |
| 144 | |
| 145 | |
| 146 | |
| 147 | |
| 148 | <main class="md-main"> |
| 149 | <div class="md-main__inner md-grid" data-md-component="container"> |
| 150 | |
| 151 | |
| 152 | <div class="md-sidebar md-sidebar--primary" data-md-component="navigation"> |
| 153 | <div class="md-sidebar__scrollwrap"> |
| 154 | <div class="md-sidebar__inner"> |
| 155 | <nav class="md-nav md-nav--primary" data-md-level="0"> |
| 156 | <label class="md-nav__title md-nav__title--site" for="__drawer"> |
| 157 | <a href="../.." title="Team Bliss" class="md-nav__button md-logo"> |
| 158 | |
| 159 | <i class="md-icon"></i> |
| 160 | |
| 161 | </a> |
| 162 | Team Bliss |
| 163 | </label> |
| 164 | |
| 165 | <ul class="md-nav__list" data-md-scrollfix> |
| 166 | |
| 167 | |
| 168 | |
| 169 | |
| 170 | |
| 171 | |
| 172 | <li class="md-nav__item"> |
| 173 | <a href="../.." title="Welcome to the wiki!" class="md-nav__link"> |
| 174 | Welcome to the wiki! |
| 175 | </a> |
| 176 | </li> |
| 177 | |
| 178 | |
| 179 | |
| 180 | |
| 181 | |
| 182 | |
| 183 | |
| 184 | <li class="md-nav__item md-nav__item--nested"> |
| 185 | |
| 186 | <input class="md-toggle md-nav__toggle" data-md-toggle="nav-2" type="checkbox" id="nav-2"> |
| 187 | |
| 188 | <label class="md-nav__link" for="nav-2"> |
| 189 | Bliss OS |
| 190 | </label> |
| 191 | <nav class="md-nav" data-md-component="collapsible" data-md-level="1"> |
| 192 | <label class="md-nav__title" for="nav-2"> |
| 193 | Bliss OS |
| 194 | </label> |
| 195 | <ul class="md-nav__list" data-md-scrollfix> |
| 196 | |
| 197 | |
| 198 | |
| 199 | |
| 200 | |
| 201 | |
| 202 | |
| 203 | <li class="md-nav__item"> |
| 204 | <a href="../../Bliss OS/" title="Index" class="md-nav__link"> |
| 205 | Index |
| 206 | </a> |
| 207 | </li> |
| 208 | |
| 209 | |
| 210 | </ul> |
| 211 | </nav> |
| 212 | </li> |
| 213 | |
| 214 | |
| 215 | |
| 216 | |
| 217 | |
| 218 | |
| 219 | |
| 220 | |
| 221 | |
| 222 | <li class="md-nav__item md-nav__item--active md-nav__item--nested"> |
| 223 | |
| 224 | <input class="md-toggle md-nav__toggle" data-md-toggle="nav-3" type="checkbox" id="nav-3" checked> |
| 225 | |
| 226 | <label class="md-nav__link" for="nav-3"> |
| 227 | BlissRoms |
| 228 | </label> |
| 229 | <nav class="md-nav" data-md-component="collapsible" data-md-level="1"> |
| 230 | <label class="md-nav__title" for="nav-3"> |
| 231 | BlissRoms |
| 232 | </label> |
| 233 | <ul class="md-nav__list" data-md-scrollfix> |
| 234 | |
| 235 | |
| 236 | |
| 237 | |
| 238 | |
| 239 | |
| 240 | |
| 241 | <li class="md-nav__item"> |
| 242 | <a href="../" title="Index" class="md-nav__link"> |
| 243 | Index |
| 244 | </a> |
| 245 | </li> |
| 246 | |
| 247 | |
| 248 | |
| 249 | |
| 250 | |
| 251 | |
| 252 | |
| 253 | |
| 254 | |
| 255 | <li class="md-nav__item md-nav__item--active"> |
| 256 | |
| 257 | <input class="md-toggle md-nav__toggle" data-md-toggle="toc" type="checkbox" id="__toc"> |
| 258 | |
| 259 | |
| 260 | |
| 261 | |
| 262 | <label class="md-nav__link md-nav__link--active" for="__toc"> |
| 263 | BuildGuide |
| 264 | </label> |
| 265 | |
| 266 | <a href="./" title="BuildGuide" class="md-nav__link md-nav__link--active"> |
| 267 | BuildGuide |
| 268 | </a> |
| 269 | |
| 270 | |
| 271 | <nav class="md-nav md-nav--secondary"> |
| 272 | |
| 273 | |
| 274 | |
| 275 | |
| 276 | |
| 277 | <label class="md-nav__title" for="__toc">Table of contents</label> |
| 278 | <ul class="md-nav__list" data-md-scrollfix> |
| 279 | |
| 280 | <li class="md-nav__item"> |
| 281 | <a href="#updated-for-pie-p90" title="Updated for Pie (p9.0)" class="md-nav__link"> |
| 282 | Updated for Pie (p9.0) |
| 283 | </a> |
| 284 | |
| 285 | <nav class="md-nav"> |
| 286 | <ul class="md-nav__list"> |
| 287 | |
| 288 | <li class="md-nav__item"> |
| 289 | <a href="#introduction" title="Introduction" class="md-nav__link"> |
| 290 | Introduction |
| 291 | </a> |
| 292 | |
| 293 | </li> |
| 294 | |
| 295 | <li class="md-nav__item"> |
| 296 | <a href="#preparation" title="Preparation" class="md-nav__link"> |
| 297 | Preparation |
| 298 | </a> |
| 299 | |
| 300 | </li> |
| 301 | |
| 302 | <li class="md-nav__item"> |
| 303 | <a href="#install-the-jdk" title="Install the JDK" class="md-nav__link"> |
| 304 | Install the JDK |
| 305 | </a> |
| 306 | |
| 307 | </li> |
| 308 | |
| 309 | <li class="md-nav__item"> |
| 310 | <a href="#install-build-tools" title="Install build tools" class="md-nav__link"> |
| 311 | Install build tools |
| 312 | </a> |
| 313 | |
| 314 | </li> |
| 315 | |
| 316 | <li class="md-nav__item"> |
| 317 | <a href="#install-source-code-tools" title="Install source code tools" class="md-nav__link"> |
| 318 | Install source code tools |
| 319 | </a> |
| 320 | |
| 321 | <nav class="md-nav"> |
| 322 | <ul class="md-nav__list"> |
| 323 | |
| 324 | <li class="md-nav__item"> |
| 325 | <a href="#what-is-source" title="What is source?" class="md-nav__link"> |
| 326 | What is source? |
| 327 | </a> |
| 328 | |
| 329 | </li> |
| 330 | |
| 331 | <li class="md-nav__item"> |
| 332 | <a href="#what-if-i-need-repo-globally" title="What if I need repo globally?" class="md-nav__link"> |
| 333 | What if I need repo globally? |
| 334 | </a> |
| 335 | |
| 336 | </li> |
| 337 | |
| 338 | </ul> |
| 339 | </nav> |
| 340 | |
| 341 | </li> |
| 342 | |
| 343 | <li class="md-nav__item"> |
| 344 | <a href="#download" title="Download" class="md-nav__link"> |
| 345 | Download |
| 346 | </a> |
| 347 | |
| 348 | </li> |
| 349 | |
| 350 | <li class="md-nav__item"> |
| 351 | <a href="#build" title="Build" class="md-nav__link"> |
| 352 | Build |
| 353 | </a> |
| 354 | |
| 355 | <nav class="md-nav"> |
| 356 | <ul class="md-nav__list"> |
| 357 | |
| 358 | <li class="md-nav__item"> |
| 359 | <a href="#i-get-an-error-about-no-bacon-targets-to-build-against-whats-wrong" title="I get an error about no bacon targets to build against, what's wrong?" class="md-nav__link"> |
| 360 | I get an error about no bacon targets to build against, what's wrong? |
| 361 | </a> |
| 362 | |
| 363 | </li> |
| 364 | |
| 365 | </ul> |
| 366 | </nav> |
| 367 | |
| 368 | </li> |
| 369 | |
| 370 | <li class="md-nav__item"> |
| 371 | <a href="#after-building" title="After building" class="md-nav__link"> |
| 372 | After building |
| 373 | </a> |
| 374 | |
| 375 | </li> |
| 376 | |
| 377 | <li class="md-nav__item"> |
| 378 | <a href="#troubleshooting" title="Troubleshooting" class="md-nav__link"> |
| 379 | Troubleshooting |
| 380 | </a> |
| 381 | |
| 382 | </li> |
| 383 | |
| 384 | <li class="md-nav__item"> |
| 385 | <a href="#conclusion" title="Conclusion" class="md-nav__link"> |
| 386 | Conclusion |
| 387 | </a> |
| 388 | |
| 389 | </li> |
| 390 | |
| 391 | <li class="md-nav__item"> |
| 392 | <a href="#looking-for-the-next-tutorial" title="Looking for the next tutorial?" class="md-nav__link"> |
| 393 | Looking for the next tutorial? |
| 394 | </a> |
| 395 | |
| 396 | </li> |
| 397 | |
| 398 | </ul> |
| 399 | </nav> |
| 400 | |
| 401 | </li> |
| 402 | |
| 403 | |
| 404 | |
| 405 | |
| 406 | |
| 407 | </ul> |
| 408 | |
| 409 | </nav> |
| 410 | |
| 411 | </li> |
| 412 | |
| 413 | |
| 414 | |
| 415 | |
| 416 | |
| 417 | |
| 418 | |
| 419 | <li class="md-nav__item"> |
| 420 | <a href="../build-tips/" title="Build Tips" class="md-nav__link"> |
| 421 | Build Tips |
| 422 | </a> |
| 423 | </li> |
| 424 | |
| 425 | |
| 426 | </ul> |
| 427 | </nav> |
| 428 | </li> |
| 429 | |
| 430 | |
| 431 | |
| 432 | |
| 433 | |
| 434 | |
| 435 | |
| 436 | <li class="md-nav__item md-nav__item--nested"> |
| 437 | |
| 438 | <input class="md-toggle md-nav__toggle" data-md-toggle="nav-4" type="checkbox" id="nav-4"> |
| 439 | |
| 440 | <label class="md-nav__link" for="nav-4"> |
| 441 | Common |
| 442 | </label> |
| 443 | <nav class="md-nav" data-md-component="collapsible" data-md-level="1"> |
| 444 | <label class="md-nav__title" for="nav-4"> |
| 445 | Common |
| 446 | </label> |
| 447 | <ul class="md-nav__list" data-md-scrollfix> |
| 448 | |
| 449 | |
| 450 | |
| 451 | |
| 452 | |
| 453 | |
| 454 | |
| 455 | <li class="md-nav__item"> |
| 456 | <a href="../../common/" title="Index" class="md-nav__link"> |
| 457 | Index |
| 458 | </a> |
| 459 | </li> |
| 460 | |
| 461 | |
| 462 | |
| 463 | |
| 464 | |
| 465 | |
| 466 | |
| 467 | <li class="md-nav__item"> |
| 468 | <a href="../../common/git-started/" title="Git Started" class="md-nav__link"> |
| 469 | Git Started |
| 470 | </a> |
| 471 | </li> |
| 472 | |
| 473 | |
| 474 | </ul> |
| 475 | </nav> |
| 476 | </li> |
| 477 | |
| 478 | |
| 479 | |
| 480 | |
| 481 | |
| 482 | |
| 483 | |
| 484 | <li class="md-nav__item md-nav__item--nested"> |
| 485 | |
| 486 | <input class="md-toggle md-nav__toggle" data-md-toggle="nav-5" type="checkbox" id="nav-5"> |
| 487 | |
| 488 | <label class="md-nav__link" for="nav-5"> |
| 489 | Infrastructure |
| 490 | </label> |
| 491 | <nav class="md-nav" data-md-component="collapsible" data-md-level="1"> |
| 492 | <label class="md-nav__title" for="nav-5"> |
| 493 | Infrastructure |
| 494 | </label> |
| 495 | <ul class="md-nav__list" data-md-scrollfix> |
| 496 | |
| 497 | |
| 498 | |
| 499 | |
| 500 | |
| 501 | |
| 502 | |
| 503 | <li class="md-nav__item"> |
| 504 | <a href="../../infrastructure/" title="Index" class="md-nav__link"> |
| 505 | Index |
| 506 | </a> |
| 507 | </li> |
| 508 | |
| 509 | |
| 510 | </ul> |
| 511 | </nav> |
| 512 | </li> |
| 513 | |
| 514 | |
| 515 | </ul> |
| 516 | </nav> |
| 517 | </div> |
| 518 | </div> |
| 519 | </div> |
| 520 | |
| 521 | |
| 522 | <div class="md-sidebar md-sidebar--secondary" data-md-component="toc"> |
| 523 | <div class="md-sidebar__scrollwrap"> |
| 524 | <div class="md-sidebar__inner"> |
| 525 | |
| 526 | <nav class="md-nav md-nav--secondary"> |
| 527 | |
| 528 | |
| 529 | |
| 530 | |
| 531 | |
| 532 | <label class="md-nav__title" for="__toc">Table of contents</label> |
| 533 | <ul class="md-nav__list" data-md-scrollfix> |
| 534 | |
| 535 | <li class="md-nav__item"> |
| 536 | <a href="#updated-for-pie-p90" title="Updated for Pie (p9.0)" class="md-nav__link"> |
| 537 | Updated for Pie (p9.0) |
| 538 | </a> |
| 539 | |
| 540 | <nav class="md-nav"> |
| 541 | <ul class="md-nav__list"> |
| 542 | |
| 543 | <li class="md-nav__item"> |
| 544 | <a href="#introduction" title="Introduction" class="md-nav__link"> |
| 545 | Introduction |
| 546 | </a> |
| 547 | |
| 548 | </li> |
| 549 | |
| 550 | <li class="md-nav__item"> |
| 551 | <a href="#preparation" title="Preparation" class="md-nav__link"> |
| 552 | Preparation |
| 553 | </a> |
| 554 | |
| 555 | </li> |
| 556 | |
| 557 | <li class="md-nav__item"> |
| 558 | <a href="#install-the-jdk" title="Install the JDK" class="md-nav__link"> |
| 559 | Install the JDK |
| 560 | </a> |
| 561 | |
| 562 | </li> |
| 563 | |
| 564 | <li class="md-nav__item"> |
| 565 | <a href="#install-build-tools" title="Install build tools" class="md-nav__link"> |
| 566 | Install build tools |
| 567 | </a> |
| 568 | |
| 569 | </li> |
| 570 | |
| 571 | <li class="md-nav__item"> |
| 572 | <a href="#install-source-code-tools" title="Install source code tools" class="md-nav__link"> |
| 573 | Install source code tools |
| 574 | </a> |
| 575 | |
| 576 | <nav class="md-nav"> |
| 577 | <ul class="md-nav__list"> |
| 578 | |
| 579 | <li class="md-nav__item"> |
| 580 | <a href="#what-is-source" title="What is source?" class="md-nav__link"> |
| 581 | What is source? |
| 582 | </a> |
| 583 | |
| 584 | </li> |
| 585 | |
| 586 | <li class="md-nav__item"> |
| 587 | <a href="#what-if-i-need-repo-globally" title="What if I need repo globally?" class="md-nav__link"> |
| 588 | What if I need repo globally? |
| 589 | </a> |
| 590 | |
| 591 | </li> |
| 592 | |
| 593 | </ul> |
| 594 | </nav> |
| 595 | |
| 596 | </li> |
| 597 | |
| 598 | <li class="md-nav__item"> |
| 599 | <a href="#download" title="Download" class="md-nav__link"> |
| 600 | Download |
| 601 | </a> |
| 602 | |
| 603 | </li> |
| 604 | |
| 605 | <li class="md-nav__item"> |
| 606 | <a href="#build" title="Build" class="md-nav__link"> |
| 607 | Build |
| 608 | </a> |
| 609 | |
| 610 | <nav class="md-nav"> |
| 611 | <ul class="md-nav__list"> |
| 612 | |
| 613 | <li class="md-nav__item"> |
| 614 | <a href="#i-get-an-error-about-no-bacon-targets-to-build-against-whats-wrong" title="I get an error about no bacon targets to build against, what's wrong?" class="md-nav__link"> |
| 615 | I get an error about no bacon targets to build against, what's wrong? |
| 616 | </a> |
| 617 | |
| 618 | </li> |
| 619 | |
| 620 | </ul> |
| 621 | </nav> |
| 622 | |
| 623 | </li> |
| 624 | |
| 625 | <li class="md-nav__item"> |
| 626 | <a href="#after-building" title="After building" class="md-nav__link"> |
| 627 | After building |
| 628 | </a> |
| 629 | |
| 630 | </li> |
| 631 | |
| 632 | <li class="md-nav__item"> |
| 633 | <a href="#troubleshooting" title="Troubleshooting" class="md-nav__link"> |
| 634 | Troubleshooting |
| 635 | </a> |
| 636 | |
| 637 | </li> |
| 638 | |
| 639 | <li class="md-nav__item"> |
| 640 | <a href="#conclusion" title="Conclusion" class="md-nav__link"> |
| 641 | Conclusion |
| 642 | </a> |
| 643 | |
| 644 | </li> |
| 645 | |
| 646 | <li class="md-nav__item"> |
| 647 | <a href="#looking-for-the-next-tutorial" title="Looking for the next tutorial?" class="md-nav__link"> |
| 648 | Looking for the next tutorial? |
| 649 | </a> |
| 650 | |
| 651 | </li> |
| 652 | |
| 653 | </ul> |
| 654 | </nav> |
| 655 | |
| 656 | </li> |
| 657 | |
| 658 | |
| 659 | |
| 660 | |
| 661 | |
| 662 | </ul> |
| 663 | |
| 664 | </nav> |
| 665 | </div> |
| 666 | </div> |
| 667 | </div> |
| 668 | |
| 669 | |
| 670 | <div class="md-content"> |
| 671 | <article class="md-content__inner md-typeset"> |
| 672 | |
| 673 | |
| 674 | |
| 675 | <h1 id="buildguide">BuildGuide</h1> |
| 676 | <h2 id="updated-for-pie-p90">Updated for Pie (p9.0)</h2> |
| 677 | <h3 id="introduction">Introduction</h3> |
| 678 | <p>This is the official guide to build BlissRoms for your device. In this guide, we will only cover official devices with actual maintainers. We will not delve into porting devices.</p> |
| 679 | <p>The golden rule to building is patience. If something breaks, wait for your maintainer to fix it, send a polite message to your maintainer, or better yet, try and fix it yourself. Then you can make a merge request and contribute!</p> |
| 680 | <p>Let’s get started.</p> |
| 681 | <h3 id="preparation">Preparation</h3> |
| 682 | <p>Prerequisites of this guide: Linux box, at least 200GB space of HDD, at least 8GB RAM. A decent CPU (or CPUs if you have a server motherboard) is recommended.</p> |
| 683 | <p>You may try building on crappy hardware but there is no guarantee your build will succeed or even function at all.</p> |
| 684 | <h3 id="install-the-jdk">Install the JDK</h3> |
| 685 | <p>Install OpenJDK:</p> |
| 686 | <pre><code>sudo apt install openjdk-8-jdk |
| 687 | </code></pre> |
| 688 | <h3 id="install-build-tools">Install build tools</h3> |
| 689 | <p>For Ubuntu 16.x:</p> |
| 690 | <pre><code>sudo apt install bison build-essential curl flex git gnupg gperf libesd0-dev liblz4-tool libncurses5-dev libsdl1.2-dev libwxgtk3.0-dev libxml2 libxml2-utils lzop maven pngcrush schedtool squashfs-tools xsltproc zip zlib1g-dev g++-multilib gcc-multilib lib32ncurses5-dev lib32readline6-dev lib32z1-dev git-core libc6-dev-i386 x11proto-core-dev libx11-dev lib32z-dev ccache libgl1-mesa-dev unzip |
| 691 | </code></pre> |
| 692 | <p>For Ubuntu 18.x (or newer):</p> |
| 693 | <pre><code>sudo apt install bison build-essential curl flex git gnupg gperf liblz4-tool libncurses5-dev libsdl1.2-dev libwxgtk3.0-dev libxml2 libxml2-utils lzop maven pngcrush schedtool squashfs-tools xsltproc zip zlib1g-dev g++-multilib gcc-multilib lib32ncurses5-dev lib32readline-dev lib32z1-dev libc6-dev-i386 x11proto-core-dev libx11-dev ccache libgl1-mesa-dev unzip python |
| 694 | </code></pre> |
| 695 | <h3 id="install-source-code-tools">Install source code tools</h3> |
| 696 | <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 Bliss's GitHub, and find what repositories you need to actually build Android.</p> |
| 697 | <p>Create a <code>~/bin</code> directory for <code>repo</code> to live in:</p> |
| 698 | <pre><code>mkdir -p ~/bin |
| 699 | </code></pre> |
| 700 | <p>The <code>-p</code> flag instructs <code>mkdir</code> to <em>only</em> create the directory if it does not exist in the first place. Now download the <code>repo</code> tool into <code>~/bin</code>:</p> |
| 701 | <pre><code>curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo |
| 702 | </code></pre> |
| 703 | <p>Make <code>repo</code> executable:</p> |
| 704 | <pre><code>chmod a+x ~/bin/repo |
| 705 | </code></pre> |
| 706 | <p>And add it to PATH:</p> |
| 707 | <pre><code>nano .bashrc |
| 708 | </code></pre> |
| 709 | <p>Scroll to the end of the file and type these lines:</p> |
| 710 | <pre><code># Export ~/bin |
| 711 | export PATH=~/bin:$PATH |
| 712 | </code></pre> |
| 713 | <p>Ctrl-O and enter to save, then Ctrl-X to exit nano. Now either logout and login again (or reboot), or <code>source</code> the file:</p> |
| 714 | <pre><code>source .bashrc |
| 715 | </code></pre> |
| 716 | <p>Which can be shortened to:</p> |
| 717 | <pre><code>. .bashrc |
| 718 | </code></pre> |
| 719 | <h4 id="what-is-source">What is <code>source</code>?</h4> |
| 720 | <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> |
| 721 | <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> |
| 722 | <h4 id="what-if-i-need-repo-globally">What if I need <code>repo</code> globally?</h4> |
| 723 | <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> |
| 724 | <pre><code>curl https://storage.googleapis.com/git-repo-downloads/repo > ~/repo |
| 725 | sudo mv ~/repo /usr/bin/ |
| 726 | chmod a+x /usr/bin/repo |
| 727 | </code></pre> |
| 728 | <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> |
| 729 | <p>Now we’re ready to download the source code.</p> |
| 730 | <h3 id="download">Download</h3> |
| 731 | <p>Create a directory for the source:</p> |
| 732 | <pre><code>mkdir -p ~/bliss/p9.0 |
| 733 | cd ~/bliss/p9.0 |
| 734 | </code></pre> |
| 735 | <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> |
| 736 | <pre><code>git config --global user.email “randy.mcrandyface@hotmail.net” |
| 737 | git config --global user.name “Randy McRandyface” |
| 738 | </code></pre> |
| 739 | <p>Now, we’re ready to initialize. We need to tell <code>repo</code> which manifest to read:</p> |
| 740 | <pre><code>repo init -u https://github.com/BlissRoms/platform_manifest.git -b p9.0 |
| 741 | </code></pre> |
| 742 | <p><code>-b</code> is for the branch, and we’re on <code>p9.0</code>, Android Pie. It’ll take a couple of seconds. You may need to type <code>y</code> for the color prompt.</p> |
| 743 | <p>Then sync the source:</p> |
| 744 | <pre><code>repo sync -j24 -c |
| 745 | </code></pre> |
| 746 | <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> |
| 747 | <pre><code>repo sync -j4 -c |
| 748 | </code></pre> |
| 749 | <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> |
| 750 | <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> |
| 751 | <h3 id="build">Build</h3> |
| 752 | <p>Set up the build environment:</p> |
| 753 | <pre><code>. build/envsetup.sh |
| 754 | </code></pre> |
| 755 | <p>This is the initialization file we talked about earlier up top. This "initializes" the environment, and imports a bunch of useful build commands required to build your device. Again, you need to remember to <code>source</code> this file every time you log out and log back in, or launch a new <code>bash</code>/Terminal instance.</p> |
| 756 | <p>Define what device you’re going to build. For example, the Nexus 5X, has a codename of <code>bullhead</code>. You can check your specific device's codename on GitHub or on Google. Execute:</p> |
| 757 | <pre><code>breakfast bullhead |
| 758 | </code></pre> |
| 759 | <p>What does this do? <code>breakfast</code> searches repositories for your device "tree", which contains all the details needed to make the build suitable for your device. CPU, kernel info, device screen size, whether the board has Bluetooth, NFC, what frequencies the build needs for Wi-Fi, and a bunch of other things. <code>breakfast</code> will automatically search in the <code>BlissRoms-Devices</code> GitHub repository, and grab your device tree for you.</p> |
| 760 | <p>Okay, so we have the device tree set up. Feel free to browse around the source code to see what changed. You should see folders added to <code>device/</code>, <code>kernel/</code> and <code>vendor/</code>. A shortcut:</p> |
| 761 | <pre><code>croot |
| 762 | </code></pre> |
| 763 | <p>will dump you back in the root of the source code tree. So if you’ve been going through folders and don’t have any idea where you are, you can use the above command. This command, however, requires you to have <code>source</code>d <code>build/envsetup.sh</code> earlier.</p> |
| 764 | <p>So we’re ready to build! Run</p> |
| 765 | <pre><code>brunch bullhead |
| 766 | </code></pre> |
| 767 | <p>But what is <code>brunch</code>? It is a compact form of these commands:</p> |
| 768 | <pre><code>breakfast bullhead |
| 769 | mka bacon |
| 770 | </code></pre> |
| 771 | <p><code>brunch</code> will automatically pull the device trees again or check if it’s there already by running <code>breakfast</code>. Then it’ll call upon the build system to build a full <code>.zip</code> for your device.</p> |
| 772 | <p>Therefore, if you have already run <code>breakfast</code>, you can just run:</p> |
| 773 | <pre><code>mka bacon |
| 774 | </code></pre> |
| 775 | <p>The build process will take a long time. Prepare to wait a few hours, even on a decent machine.</p> |
| 776 | <h4 id="i-get-an-error-about-no-bacon-targets-to-build-against-whats-wrong">I get an error about no <code>bacon</code> targets to build against, what's wrong?</h4> |
| 777 | <p>Sometimes there is a bug, or the ROM developers do not implement a <code>bacon</code> target to build against. In this case, you will need to find what name they use to initialize a full build of the ROM. Conventionally, it is supposed to be <code>bacon</code>, but some ROM developers change this name inadvertently, or actually have a bug that causes the build target to never be found. If you cannot locate the build target, ask the developers of the ROM. Alternatively, you can try poking around in <code>build/make/core/Makefile</code> to see what the build target name is.</p> |
| 778 | <h3 id="after-building">After building</h3> |
| 779 | <p>There are two outcomes to a build - either it fails and you get a red error message from <code>make</code>, or it succeeds and you see the Bliss logo in ASCII. If you encounter the former, you need to go back and fix whatever it's complaining about. Typically, 90% of the time the problem will be in your device tree. For the other 10%, submit a bug report to the ROM developers. Be sure to include the full log of your build to help diagnose the problem, and your device tree.</p> |
| 780 | <p>If you face the latter, congratulations! You've successfully built BlissRoms for your device. Grab the artifacts for your device:</p> |
| 781 | <pre><code>cd out/target/product/bullhead/ |
| 782 | </code></pre> |
| 783 | <p>In here, you’ll find a <code>.zip</code> that goes along the lines of <code>Bliss-v11.5-Stable-bullhead-UNOFFICIAL-20180213-0621.zip</code>. Install TWRP, flash the build to your device, and enjoy!</p> |
| 784 | <h3 id="troubleshooting">Troubleshooting</h3> |
| 785 | <p>If your build failed, there are a couple things you can try.</p> |
| 786 | <ul> |
| 787 | <li>Try a fresh <code>repo sync</code> to make your repository up to date. Sometimes, the Internet connection between you and GitHub can be flaky. In rare cases a commit merge might be ongoing, and you might've grabbed an incomplete merge. Mostly, this should fix the issue 70% of the time.</li> |
| 788 | <li>Make sure your dependencies are installed correctly. Error messages help out a lot here! Often it will say <code>shared/linked library not found</code> or something along those lines.</li> |
| 789 | <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> |
| 790 | <li>Make sure you’re at the root of the build tree. Again, to quickly jump there, use <code>croot</code>.</li> |
| 791 | <li>Make sure you ran <code>breakfast</code> correctly and it did not error out. Missing device files will prevent successful builds.</li> |
| 792 | <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 via a program like Prime95.</li> |
| 793 | </ul> |
| 794 | <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> |
| 795 | <h3 id="conclusion">Conclusion</h3> |
| 796 | <p>Building a ROM is very hard and tedious and the results are very rewarding! If you managed to follow along, congratulations!</p> |
| 797 | <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> |
| 798 | <p>-- Eric Park (ideaman924)</p> |
| 799 | <h3 id="looking-for-the-next-tutorial">Looking for the next tutorial?</h3> |
| 800 | <p>Check out <a href="../build-tips/">some tips to optimize your build experience.</a></p> |
| 801 | |
| 802 | |
| 803 | |
| 804 | |
| 805 | |
| 806 | |
| 807 | |
| 808 | |
| 809 | |
| 810 | </article> |
| 811 | </div> |
| 812 | </div> |
| 813 | </main> |
| 814 | |
| 815 | |
| 816 | <footer class="md-footer"> |
| 817 | |
| 818 | <div class="md-footer-nav"> |
| 819 | <nav class="md-footer-nav__inner md-grid"> |
| 820 | |
| 821 | <a href="../" title="Index" class="md-flex md-footer-nav__link md-footer-nav__link--prev" rel="prev"> |
| 822 | <div class="md-flex__cell md-flex__cell--shrink"> |
| 823 | <i class="md-icon md-icon--arrow-back md-footer-nav__button"></i> |
| 824 | </div> |
| 825 | <div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title"> |
| 826 | <span class="md-flex__ellipsis"> |
| 827 | <span class="md-footer-nav__direction"> |
| 828 | Previous |
| 829 | </span> |
| 830 | Index |
| 831 | </span> |
| 832 | </div> |
| 833 | </a> |
| 834 | |
| 835 | |
| 836 | <a href="../build-tips/" title="Build Tips" class="md-flex md-footer-nav__link md-footer-nav__link--next" rel="next"> |
| 837 | <div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title"> |
| 838 | <span class="md-flex__ellipsis"> |
| 839 | <span class="md-footer-nav__direction"> |
| 840 | Next |
| 841 | </span> |
| 842 | Build Tips |
| 843 | </span> |
| 844 | </div> |
| 845 | <div class="md-flex__cell md-flex__cell--shrink"> |
| 846 | <i class="md-icon md-icon--arrow-forward md-footer-nav__button"></i> |
| 847 | </div> |
| 848 | </a> |
| 849 | |
| 850 | </nav> |
| 851 | </div> |
| 852 | |
| 853 | <div class="md-footer-meta md-typeset"> |
| 854 | <div class="md-footer-meta__inner md-grid"> |
| 855 | <div class="md-footer-copyright"> |
| 856 | |
| 857 | powered by |
| 858 | <a href="https://www.mkdocs.org">MkDocs</a> |
| 859 | and |
| 860 | <a href="https://squidfunk.github.io/mkdocs-material/"> |
| 861 | Material for MkDocs</a> |
| 862 | </div> |
| 863 | |
| 864 | </div> |
| 865 | </div> |
| 866 | </footer> |
| 867 | |
| 868 | </div> |
| 869 | |
| 870 | <script src="../../assets/javascripts/application.245445c6.js"></script> |
| 871 | |
| 872 | <script>app.initialize({version:"1.0.4",url:{base:"../.."}})</script> |
| 873 | |
| 874 | |
| 875 | </body> |
| 876 | </html> |