[GUIDE] How to build Android on Windows

Search This thread

acetone802000

Senior Member
Nov 6, 2009
246
53
Amiens
OnePlus Nord
Thank you very much for your guide.

My phone is an OnePlus 3 with no Treble support

i have some errors at the "brunch" command.

1) sudo apt update && sudo apt full-upgrade -y && sudo apt install -y bc build-essential ccache curl g++-multilib gcc-multilib git gnupg gperf imagemagick lib32ncurses5-dev lib32readline-dev lib32z1-dev liblz4-tool libncurses5-dev libsdl1.2-dev libssl-dev libwxgtk3.0-dev libxml2 libxml2-utils lzop m4 openjdk-8-jdk pngcrush repo rsync schedtool squashfs-tools xsltproc zip zlib1g-dev adb
2) mkdir -p ~/android/lineage && cd android/lineage
3) repo init -u https://github.com/LineageOS/android.git -b lineage-16.0
4) repo sync
5) i had to add email and name to the repo:
git config --global user.email email@example.com.
git config --global user.name name
(not sure that i used this commands but the good commands are shown first time i made an repo sync)

5) source build/envsetup.sh
6) Add the following to .repo/local_manifests/roomservice.xml: <project name="TheMuppets/proprietary_vendor_oneplus" path="vendor/oneplus" depth="1" />
7) repo sync
8) breakfast oneplus3 <--- No error
9) brunch oneplus3 <--- Many errors

please, have you any idea where i made an error ?
Thanks in advance
errors:

ninja: no work to do.
ninja: no work to do.
No need to regenerate ninja file
No need to regenerate ninja file
[ 0% 27/67485] Building Kernel Config
make*: on entre dans le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make[1]*: on entre dans le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
GEN ./Makefile
#
# configuration written to .config
#
make[1]*: on quitte le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
make*: on quitte le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make*: on entre dans le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make[1]*: on entre dans le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
GEN ./Makefile
scripts/kconfig/conf --savedefconfig=defconfig Kconfig
make[1]*: on quitte le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
make*: on quitte le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
[ 0% 42/67485] build /home/francois/a...ows_intermediates/sepolicy_neverallows
FAILED: /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/sepolicy_neverallows
/bin/bash -c "(rm -f /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/sepolicy_neverallows ) && (ASAN_OPTIONS=detect_leaks=0 /home/francois/android/lineage/out/host/linux-x86/bin/checkpolicy -M -c 30 -o /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/sepolicy_neverallows /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/policy.conf )"
libsepol.report_failure: neverallow on line 8 of system/sepolicy/private/performanced.te (or line 31049 of policy.conf) violated by allow system_app perfprofd:binder { call };
libsepol.report_failure: neverallow on line 139 of system/sepolicy/public/netd.te (or line 19444 of policy.conf) violated by allow system_app netd:binder { call };
libsepol.report_failure: neverallow on line 1384 of system/sepolicy/public/domain.te (or line 11423 of policy.conf) violated by allow rfs_access rfs_access:capability { dac_override };
libsepol.check_assertions: 3 neverallow failures occurred
Error while expanding policy
/home/francois/android/lineage/out/host/linux-x86/bin/checkpolicy: loading policy configuration from /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/policy.conf
[ 0% 47/67485] build /home/francois/a...policy.recovery_intermediates/sepolicy
FAILED: /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy
/bin/bash -c "(ASAN_OPTIONS=detect_leaks=0 /home/francois/android/lineage/out/host/linux-x86/bin/checkpolicy -M -c 30 -o /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.tmp /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.recovery.conf ) && (/home/francois/android/lineage/out/host/linux-x86/bin/sepolicy-analyze /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.tmp permissive > /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.permissivedomains ) && (if [ "userdebug" = "user" -a -s /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.permissivedomains ]; then echo "==========" 1>&2; echo "ERROR: permissive domains not allowed in user builds" 1>&2; echo "List of invalid domains:" 1>&2; cat /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.permissivedomains 1>&2; exit 1; fi ) && (mv /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.tmp /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy )"
libsepol.report_failure: neverallow on line 7 of system/sepolicy/private/perfprofd.te (or line 32707 of policy.conf) violated by allow system_app perfprofd:binder { call };
libsepol.report_failure: neverallow on line 139 of system/sepolicy/public/netd.te (or line 19619 of policy.conf) violated by allow system_app netd:binder { call };
libsepol.report_failure: neverallow on line 1384 of system/sepolicy/public/domain.te (or line 11482 of policy.conf) violated by allow rfs_access rfs_access:capability { dac_override };
libsepol.check_assertions: 3 neverallow failures occurred
Error while expanding policy
/home/francois/android/lineage/out/host/linux-x86/bin/checkpolicy: loading policy configuration from /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.recovery.conf
[ 0% 51/67485] Building Kernel
make*: on entre dans le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make[1]*: on entre dans le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
GEN ./Makefile
scripts/kconfig/conf --silentoldconfig Kconfig
CHK include/config/kernel.release
GEN ./Makefile
CHK include/generated/uapi/linux/version.h
Using /home/francois/android/lineage/kernel/oneplus/msm8996 as source for kernel
CHK include/generated/utsrelease.h
CALL /home/francois/android/lineage/kernel/oneplus/msm8996/scripts/checksyscalls.sh
make[2]: «*include/generated/vdso-offsets.h*» est à jour.
make[2]: «*include/generated/vdso32-offsets.h*» est à jour.
CHK include/generated/compile.h
DTC arch/arm64/boot/dts/qcom/msm8996-v3-pmi8996-mtp_15801.dtb
DTC arch/arm64/boot/dts/qcom/msm8996pro-pmi8996-mtp_15811.dtb
CAT arch/arm64/boot/Image.gz-dtb
make[1]*: on quitte le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
make*: on quitte le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
Building DTBs
make*: on entre dans le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make[1]*: on entre dans le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
CHK include/config/kernel.release
GEN ./Makefile
CHK include/generated/uapi/linux/version.h
Using /home/francois/android/lineage/kernel/oneplus/msm8996 as source for kernel
CHK include/generated/utsrelease.h
CALL /home/francois/android/lineage/kernel/oneplus/msm8996/scripts/checksyscalls.sh
make[2]: «*include/generated/vdso-offsets.h*» est à jour.
make[2]: «*include/generated/vdso32-offsets.h*» est à jour.
make[1]*: on quitte le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
make*: on quitte le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
ninja: build stopped: subcommand failed.
10:36:37 ninja failed with: exit status 1
 
Last edited:

Uldiniad

Senior Member
Mar 17, 2016
346
269
Thank you very much for your guide.

My phone is an OnePlus 3 with no Treble support

i have some errors at the "brunch" command.

1) sudo apt update && sudo apt full-upgrade -y && sudo apt install -y bc build-essential ccache curl g++-multilib gcc-multilib git gnupg gperf imagemagick lib32ncurses5-dev lib32readline-dev lib32z1-dev liblz4-tool libncurses5-dev libsdl1.2-dev libssl-dev libwxgtk3.0-dev libxml2 libxml2-utils lzop m4 openjdk-8-jdk pngcrush repo rsync schedtool squashfs-tools xsltproc zip zlib1g-dev adb
2) mkdir -p ~/android/lineage && cd android/lineage
3) repo init -u https://github.com/LineageOS/android.git -b lineage-16.0
4) repo sync
5) i had to add email and name to the repo:
git config --global user.email email@example.com.
git config --global user.name name
(not sure that i used this commands but the good commands are shown first time i made an repo sync)

5) source build/envsetup.sh
6) Add the following to .repo/local_manifests/roomservice.xml: <project name="TheMuppets/proprietary_vendor_oneplus" path="vendor/oneplus" depth="1" />
7) repo sync
8) breakfast oneplus3 <--- No error
9) brunch oneplus3 <--- Many errors

please, have you any idea where i made an error ?
Thanks in advance
errors:

ninja: no work to do.
ninja: no work to do.
No need to regenerate ninja file
No need to regenerate ninja file
[ 0% 27/67485] Building Kernel Config
make*: on entre dans le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make[1]*: on entre dans le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
GEN ./Makefile
#
# configuration written to .config
#
make[1]*: on quitte le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
make*: on quitte le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make*: on entre dans le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make[1]*: on entre dans le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
GEN ./Makefile
scripts/kconfig/conf --savedefconfig=defconfig Kconfig
make[1]*: on quitte le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
make*: on quitte le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
[ 0% 42/67485] build /home/francois/a...ows_intermediates/sepolicy_neverallows
FAILED: /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/sepolicy_neverallows
/bin/bash -c "(rm -f /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/sepolicy_neverallows ) && (ASAN_OPTIONS=detect_leaks=0 /home/francois/android/lineage/out/host/linux-x86/bin/checkpolicy -M -c 30 -o /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/sepolicy_neverallows /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/policy.conf )"
libsepol.report_failure: neverallow on line 8 of system/sepolicy/private/performanced.te (or line 31049 of policy.conf) violated by allow system_app perfprofd:binder { call };
libsepol.report_failure: neverallow on line 139 of system/sepolicy/public/netd.te (or line 19444 of policy.conf) violated by allow system_app netd:binder { call };
libsepol.report_failure: neverallow on line 1384 of system/sepolicy/public/domain.te (or line 11423 of policy.conf) violated by allow rfs_access rfs_access:capability { dac_override };
libsepol.check_assertions: 3 neverallow failures occurred
Error while expanding policy
/home/francois/android/lineage/out/host/linux-x86/bin/checkpolicy: loading policy configuration from /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy_neverallows_intermediates/policy.conf
[ 0% 47/67485] build /home/francois/a...policy.recovery_intermediates/sepolicy
FAILED: /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy
/bin/bash -c "(ASAN_OPTIONS=detect_leaks=0 /home/francois/android/lineage/out/host/linux-x86/bin/checkpolicy -M -c 30 -o /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.tmp /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.recovery.conf ) && (/home/francois/android/lineage/out/host/linux-x86/bin/sepolicy-analyze /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.tmp permissive > /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.permissivedomains ) && (if [ "userdebug" = "user" -a -s /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.permissivedomains ]; then echo "==========" 1>&2; echo "ERROR: permissive domains not allowed in user builds" 1>&2; echo "List of invalid domains:" 1>&2; cat /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.permissivedomains 1>&2; exit 1; fi ) && (mv /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.tmp /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy )"
libsepol.report_failure: neverallow on line 7 of system/sepolicy/private/perfprofd.te (or line 32707 of policy.conf) violated by allow system_app perfprofd:binder { call };
libsepol.report_failure: neverallow on line 139 of system/sepolicy/public/netd.te (or line 19619 of policy.conf) violated by allow system_app netd:binder { call };
libsepol.report_failure: neverallow on line 1384 of system/sepolicy/public/domain.te (or line 11482 of policy.conf) violated by allow rfs_access rfs_access:capability { dac_override };
libsepol.check_assertions: 3 neverallow failures occurred
Error while expanding policy
/home/francois/android/lineage/out/host/linux-x86/bin/checkpolicy: loading policy configuration from /home/francois/android/lineage/out/target/product/oneplus3/obj/ETC/sepolicy.recovery_intermediates/sepolicy.recovery.conf
[ 0% 51/67485] Building Kernel
make*: on entre dans le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make[1]*: on entre dans le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
GEN ./Makefile
scripts/kconfig/conf --silentoldconfig Kconfig
CHK include/config/kernel.release
GEN ./Makefile
CHK include/generated/uapi/linux/version.h
Using /home/francois/android/lineage/kernel/oneplus/msm8996 as source for kernel
CHK include/generated/utsrelease.h
CALL /home/francois/android/lineage/kernel/oneplus/msm8996/scripts/checksyscalls.sh
make[2]: «*include/generated/vdso-offsets.h*» est à jour.
make[2]: «*include/generated/vdso32-offsets.h*» est à jour.
CHK include/generated/compile.h
DTC arch/arm64/boot/dts/qcom/msm8996-v3-pmi8996-mtp_15801.dtb
DTC arch/arm64/boot/dts/qcom/msm8996pro-pmi8996-mtp_15811.dtb
CAT arch/arm64/boot/Image.gz-dtb
make[1]*: on quitte le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
make*: on quitte le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
Building DTBs
make*: on entre dans le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
make[1]*: on entre dans le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
CHK include/config/kernel.release
GEN ./Makefile
CHK include/generated/uapi/linux/version.h
Using /home/francois/android/lineage/kernel/oneplus/msm8996 as source for kernel
CHK include/generated/utsrelease.h
CALL /home/francois/android/lineage/kernel/oneplus/msm8996/scripts/checksyscalls.sh
make[2]: «*include/generated/vdso-offsets.h*» est à jour.
make[2]: «*include/generated/vdso32-offsets.h*» est à jour.
make[1]*: on quitte le répertoire «*/home/francois/android/lineage/out/target/product/oneplus3/obj/KERNEL_OBJ*»
make*: on quitte le répertoire «*/home/francois/android/lineage/kernel/oneplus/msm8996*»
ninja: build stopped: subcommand failed.
10:36:37 ninja failed with: exit status 1

https://review.lineageos.org/q/proj...d_device_oneplus_oneplus3+branch:lineage-16.0
 
  • Like
Reactions: acetone802000
I'm getting the error when I run breakfast command
what can I do to solve these

Code:
user@Phoenix:/mnt/d/android/lineage$ breakfast bullhead && make bacon showcommands
including vendor/lineage/vendorsetup.sh
07:00:12 Could not create module-finder: finder encountered 43 errors: [/mnt/d/android/lineage/developers/build/prebuilts/gradle/WearComplicationProvidersTestSuite/.google: lstat /mnt/d/android/lineage/developers/build/prebuilts/gradle/WearComplicationProvidersTestSuite/.google: no such file or directory /mnt/d/android/lineage/frameworks/rs/tests/java_api/Refocus/res/mipmap-xxhdpi: open /mnt/d/android/lineage/frameworks/rs/tests/java_api/Refocus/res/mipmap-xxhdpi: no such file or directory /mnt/d/android/lineage/developers/build/prebuilts/gradle/RuntimePermissions/Application/src/main/res/mipmap-xxxhdpi: lstat /mnt/d/android/lineage/developers/build/prebuilts/gradle/RuntimePermissions/Application/src/main/res/mipmap-xxxhdpi: no such file or directory /mnt/d/android/lineage/developers/build/prebuilts/gradle/RuntimePermissions/Application/src/main/res/values: lstat /mnt/d/android/lineage/developers/build/prebuilts/gradle/RuntimePermissions/Application/src/main/res/values: no such file or directory /mnt/d/android/lineage/prebuilts/tools/common/m2/repository/com/jakewharton/butterknife/8.4.0: lstat /mnt/d/android/lineage/prebuilts/tools/common/m2/repository/com/jakewharton/butterknife/8.4.0: no such file or directory /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-my: lstat /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-my: no such file or directory /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-ne: lstat /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-ne: no such file or directory /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-nl: lstat /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-nl: no such file or directory /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-no: lstat /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-no: no such file or directory /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-oc: lstat /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/incallui/audioroute/res/values-oc: no such file or directory]...
Device bullhead not found. Attempting to retrieve device repository from LineageOS Github (http://github.com/LineageOS).
Found repository: android_device_lge_bullhead
Default revision: lineage-16.0
Checking branch info
Checking if device/lge/bullhead is fetched from android_device_lge_bullhead
LineageOS/android_device_lge_bullhead already fetched to device/lge/bullhead
Syncing repository to retrieve project.

... A new repo command ( 1.25) is available.
... You should upgrade soon:

    cp /mnt/d/android/lineage/.repo/repo/repo /usr/bin/repo

Fetching project LineageOS/android_device_lge_bullhead
Fetching projects: 100% (1/1)
Fetching projects: 100% (1/1), done.

Repository synced!
Looking for dependencies in device/lge/bullhead
device/lge/bullhead has no additional dependencies.
Done
07:00:50 Could not create module-finder: finder encountered 15 errors: [/mnt/d/android/lineage/packages/apps/CertInstaller/res/values-sv: lstat /mnt/d/android/lineage/packages/apps/CertInstaller/res/values-sv: no such file or directory /mnt/d/android/lineage/external/skqp/infra/bots/recipe_modules/isolate/resources: lstat /mnt/d/android/lineage/external/skqp/infra/bots/recipe_modules/isolate/resources: no such file or directory /mnt/d/android/lineage/frameworks/base/packages/SettingsProvider/res/values: open /mnt/d/android/lineage/frameworks/base/packages/SettingsProvider/res/values: no such file or directory /mnt/d/android/lineage/external/libcxx/test/std/strings/basic.string/string.ops/string_find.first.not.of: lstat /mnt/d/android/lineage/external/libcxx/test/std/strings/basic.string/string.ops/string_find.first.not.of: no such file or directory /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.7.0: lstat /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.7.0: no such file or directory /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.7.1: lstat /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.7.1: no such file or directory /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.7.3: lstat /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.7.3: no such file or directory /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.8.0: lstat /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.8.0: no such file or directory /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.9.2: lstat /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/22.9.2: no such file or directory /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/23.0.1: lstat /mnt/d/android/lineage/prebuilts/gradle-plugin/com/android/tools/lint/lint/23.0.1: no such file or directory]...
07:01:20 Could not create module-finder: finder encountered 4 errors: [/mnt/d/android/lineage/packages/providers/TvProvider/res/values-br-rFR: lstat /mnt/d/android/lineage/packages/providers/TvProvider/res/values-br-rFR: no such file or directory /mnt/d/android/lineage/external/swiftshader/third_party/LLVM/lib/Bitcode/Reader: open /mnt/d/android/lineage/external/swiftshader/third_party/LLVM/lib/Bitcode/Reader: no such file or directory /mnt/d/android/lineage/external/swiftshader/third_party/LLVM/lib/MC/MCDisassembler: open /mnt/d/android/lineage/external/swiftshader/third_party/LLVM/lib/MC/MCDisassembler: no such file or directory /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/dialer/contactphoto/res/values-mn: lstat /mnt/d/android/lineage/packages/apps/Dialer/java/com/android/dialer/contactphoto/res/values-mn: no such file or directory]

** Don't have a product spec for: 'lineage_bullhead'
** Do you have the right repo manifest?
 

Hanabishi Recca

Senior Member
Jan 27, 2015
63
36
Good guide, thanks.

Tip about filesystem case-sensitivity. Actually you can use other drives and mnt. No need to mount entire filesystem as case-sensetive.
E.g. if you want to work in D:\build, just run this command in windows cmd/powershell:
Code:
fsutil.exe file setCaseSensitiveInfo "D:\build" enable
Works fine. Now you can use /mnt/d/build as your working folder.

But this command is not recursive for exisiting subfolders (only newly created folders will inherit this flag).
So if your working folder wasn't empty, you already synced the repo and don't want to redownload it again, use script form here Recursive file case sensitivity
Perhaps due to previous case-insensitivity during sync some files were lost. Run
Code:
repo forall -c 'git reset --hard'
to fix all repos.
 
Last edited:

xHazard

Member
Apr 3, 2019
6
1
Does anyone have screenshots before I try this out myself? Also is using the Windows Store a requirement? Wondering how I'd do this on my LTSC PC.
 

Uldiniad

Senior Member
Mar 17, 2016
346
269
Does anyone have screenshots before I try this out myself? Also is using the Windows Store a requirement? Wondering how I'd do this on my LTSC PC.

If you search around you'll find screenshots in the thread. Concerning the windows store, it is the recommended way. If you get the setup working another way then good for you but don't expect support from me in that case.
 

spoiledsport

Member
Nov 20, 2009
7
2
Newbie unable to build

All

Sorry for bothering the group. I have followed the guide. I have read many posts. I have tried so many different things including starting from scratch, but I am still unable to build this thing. I am trying to build bacon.
I am getting the following error after running brunch bacon

<pre>runch bacon
including vendor/lineage/vendorsetup.sh
<b>device/oppo/common/common.mk:25: </b><font color="#CB4B16"><b>error: </b></font><b>_nic.PRODUCTS.[[device/oneplus/bacon/lineage_bacon.mk]]: "vendor/oppo/msm8974-common/msm8974-common-vendor.mk" does not exist.</b>
10:20:51 dumpvars failed with: exit status 1
Device bacon not found. Attempting to retrieve device repository from LineageOS Github (http://github.com/LineageOS).
Found repository: android_device_oneplus_bacon
Default revision: lineage-16.0
Checking branch info
Checking if device/oneplus/bacon is fetched from android_device_oneplus_bacon
LineageOS/android_device_oneplus_bacon already fetched to device/oneplus/bacon
Syncing repository to retrieve project.

... A new repo command ( 1.25) is available.
... You should upgrade soon:

cp /home/ecastro/android/lineage/.repo/repo/repo /usr/bin/repo

Fetching project LineageOS/android_device_oneplus_bacon

Repository synced!
Looking for dependencies in device/oneplus/bacon
Looking for dependencies in device/oppo/msm8974-common
Looking for dependencies in device/oppo/common
Looking for dependencies in packages/resources/devicesettings
packages/resources/devicesettings has no additional dependencies.
Looking for dependencies in kernel/oppo/msm8974
kernel/oppo/msm8974 has no additional dependencies.
Done
<b>device/oppo/common/common.mk:25: </b><font color="#CB4B16"><b>error: </b></font><b>_nic.PRODUCTS.[[device/oneplus/bacon/lineage_bacon.mk]]: "vendor/oppo/msm8974-common/msm8974-common-vendor.mk" does not exist.</b>
10:20:56 dumpvars failed with: exit status 1
<b>device/oppo/common/common.mk:25: </b><font color="#CB4B16"><b>error: </b></font><b>_nic.PRODUCTS.[[device/oneplus/bacon/lineage_bacon.mk]]: "vendor/oppo/msm8974-common/msm8974-common-vendor.mk" does not exist.</b>
10:20:59 dumpvars failed with: exit status 1

** Don&apos;t have a product spec for: &apos;lineage_bacon&apos;
** Do you have the right repo manifest?

No such item in brunch menu. Try &apos;breakfast&apos;
</pre>

my roomservice.xml file looks like

<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<project name="LineageOS/android_packages_resources_devicesettings" path="packages/resources/devicesettings" remote="github" />
<project name="TheMuppets/proprietary_vendor_oneplus" path="vendor/oneplus" remote="github" />
<project name="LineageOS/android_device_oneplus_bacon" path="device/oneplus/bacon" remote="github" />
<project name="LineageOS/android_device_oppo_msm8974-common" path="device/oppo/msm8974-common" remote="github" />
<project name="LineageOS/android_kernel_oppo_msm8974" path="kernel/oppo/msm8974" remote="github" />
<project name="LineageOS/android_device_oppo_common" path="device/oppo/common" remote="github" />
</manifest>

So now, any ideas on what should I look at next?
 

Uldiniad

Senior Member
Mar 17, 2016
346
269
All

Sorry for bothering the group. I have followed the guide. I have read many posts. I have tried so many different things including starting from scratch, but I am still unable to build this thing. I am trying to build bacon.
I am getting the following error after running brunch bacon

<pre>runch bacon
including vendor/lineage/vendorsetup.sh
<b>device/oppo/common/common.mk:25: </b><font color="#CB4B16"><b>error: </b></font><b>_nic.PRODUCTS.[[device/oneplus/bacon/lineage_bacon.mk]]: "vendor/oppo/msm8974-common/msm8974-common-vendor.mk" does not exist.</b>
10:20:51 dumpvars failed with: exit status 1
Device bacon not found. Attempting to retrieve device repository from LineageOS Github (http://github.com/LineageOS).
Found repository: android_device_oneplus_bacon
Default revision: lineage-16.0
Checking branch info
Checking if device/oneplus/bacon is fetched from android_device_oneplus_bacon
LineageOS/android_device_oneplus_bacon already fetched to device/oneplus/bacon
Syncing repository to retrieve project.

... A new repo command ( 1.25) is available.
... You should upgrade soon:

cp /home/ecastro/android/lineage/.repo/repo/repo /usr/bin/repo

Fetching project LineageOS/android_device_oneplus_bacon

Repository synced!
Looking for dependencies in device/oneplus/bacon
Looking for dependencies in device/oppo/msm8974-common
Looking for dependencies in device/oppo/common
Looking for dependencies in packages/resources/devicesettings
packages/resources/devicesettings has no additional dependencies.
Looking for dependencies in kernel/oppo/msm8974
kernel/oppo/msm8974 has no additional dependencies.
Done
<b>device/oppo/common/common.mk:25: </b><font color="#CB4B16"><b>error: </b></font><b>_nic.PRODUCTS.[[device/oneplus/bacon/lineage_bacon.mk]]: "vendor/oppo/msm8974-common/msm8974-common-vendor.mk" does not exist.</b>
10:20:56 dumpvars failed with: exit status 1
<b>device/oppo/common/common.mk:25: </b><font color="#CB4B16"><b>error: </b></font><b>_nic.PRODUCTS.[[device/oneplus/bacon/lineage_bacon.mk]]: "vendor/oppo/msm8974-common/msm8974-common-vendor.mk" does not exist.</b>
10:20:59 dumpvars failed with: exit status 1

** Don&apos;t have a product spec for: &apos;lineage_bacon&apos;
** Do you have the right repo manifest?

No such item in brunch menu. Try &apos;breakfast&apos;
</pre>

my roomservice.xml file looks like

<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<project name="LineageOS/android_packages_resources_devicesettings" path="packages/resources/devicesettings" remote="github" />
<project name="TheMuppets/proprietary_vendor_oneplus" path="vendor/oneplus" remote="github" />
<project name="LineageOS/android_device_oneplus_bacon" path="device/oneplus/bacon" remote="github" />
<project name="LineageOS/android_device_oppo_msm8974-common" path="device/oppo/msm8974-common" remote="github" />
<project name="LineageOS/android_kernel_oppo_msm8974" path="kernel/oppo/msm8974" remote="github" />
<project name="LineageOS/android_device_oppo_common" path="device/oppo/common" remote="github" />
</manifest>

So now, any ideas on what should I look at next?

maybe add this one too? https://github.com/TheMuppets/proprietary_vendor_oppo
if you read your error it says it vendor/oppo/msm8974-common does not exist
 
  • Like
Reactions: spoiledsport

Top Liked Posts

  • There are no posts matching your filters.
  • 21
    Useful resources




    https://github.com/MicrosoftDocs/WSL/issues/412#issuecomment-575923176
    12
    WSL 2.0 is OUT, build all the droids!

    Hi all,

    Microsoft just released the Windows 10 May 2020 update. But the bigger news is that it comes with WSL2. The TLDR of it is that Windows now has a Linux kernel bundled with it and that's game changing. And what that means for us is out of the box / seamless linux-like functionality for all teh things (goodbye Lineage hax patches for WSL1).

    I have updated OP https://xdaforums.com/showpost.php?p=75579631&postcount=1 and the useful resources post https://xdaforums.com/showpost.php?p=75579631&postcount=2 with the latest information I have so far. Note that with wsl2 using mnt is a readily available option and the wsl installation location can easily be changed as well :) Lots more flexibility

    Lastly, wanted to say thanks to all for your patience. I started this project while I was in the middle of university. I did this "for fun" with the goal of seeing if compiling Android on Windows (via WSL) would be remotely possible and if I personally would be able to pull that off. Apparently, I did :p. Part of this work (added with other work I did with Lineage) allowed me to get the Android job I currently have and I'm grateful for it.
    I know WSL 1 was a bit of a pain to work with and that headaches and frustration came from it. The good news, is those days are over. And the future is now.

    If you have questions that are not answered already in other posts, send them through. I will be randomly checking the thread. Although given that wsl2 doesn't need anywhere near as much maintenance as wsl1 I will probably be more hands off than I used to be (e.g. update the docs for newer versions of Android or Windows, etc.).

    Take care,
    Uldiniad
    11
    Pie (wsl flavour) is out of the oven

    Hey everyone,

    TL;DR
    It is now possible to build lineage-16.0 on wsl! Just follow the updated guide from start to finish (syncing 16.0 on top of 15.1 is not recommended) and enjoy.
    DO NOT COMPLAIN ABOUT ANY ERRORS THAT ARE NOT STRICTLY DUE TO THE BUILD ENVIRONMENT (WSL). Many devices are not ready to build yet!

    Also, as always, I recommend building on the latest version of Windows. October Update was released recently: https://www.microsoft.com/en-ca/software-download/windows10

    For those still insterested in building 15.1 (ignore the repopick step): https://web.archive.org/web/2018061...ng/guide-how-to-build-lineageos-15-1-t3750175 (as mentioned in my previous announcement, do not report any errors, I will ignore them, since I do not have the means to maintain more than one branch on wsl)

    Full version:
    It has been some time since the last update. I apologise for the crickets.
    I didn't want to write a post until I was able to guarantee I could build lineage-16.0 without issues on wsl. I downloaded the sources as soon as they were released but was unable to complete a full build for my device without cherry-picking lots of patches for it and decided against it since I wanted to reduce the scope of the errors to the build environment alone. I only recently thought of building a generic image instead (which would accomplish what I wanted). Thankfully, wsl had less problems this time cause Google were cool with updating their bison and flex prebuilts (thereby now making them 64-bit) and killed off ijar (hopefully forever). So only dex2oat needed a patch this time around :D
    The wsl-compile-lineage-16.0 patches are merged (https://review.lineageos.org/#/q/st...h:lineage-16.0+topic:wsl-compile-lineage-16.0). So no additional steps required there. Otherwise, make sure to install m4 since it spat out an error about it missing.

    Thank you for your support,

    Uldiniad

    P.S. Feel free to ask any questions related to this and check my previous announcements to know my goals and standards for this side-project (https://xdaforums.com/showpost.php?p=77321912&postcount=261 for example)
    P.P.S. I am working on making an official wiki page on the LineageOS website which will be more convenient than this thread. I might consider leaving the thread open for feedback once it is open, but I might also consider having feedback reported via official means (JIRA probably).
    6
    Want a piece of Pie?

    Hey everyone, got some news to share.

    As you may have heard, the Pie is now out of the oven. Given that,
    1. At the moment building android on WSL is 100% experimental
    2. There seems to be little to no interest from Google and Microsoft to officially support wsl as an android build environment
    3. I'm working alone with limited time and knowledge of both the android build environment and the inner workings of wsl
    4. I plan on supporting the latest version of lineage available
    I am therefore starting research and work on lineage-16.0 and will be leaving lineage-15.1 as it currently stands.
    As windows updates come, wsl will change and may bring new unforeseen errors to the oreo build environment. Since I will not be maintaing that branch anymore, it may mean that the best option to keep building 15.1 is to not update to the latest build of windows if it causes errors. Given this situation I will be paying less attention to bug reports for 15.1 as time goes by and 16.x takes its place (especially since I do not have 15.1 synced anymore and will not be able to reproduce errors).

    For 16.x, it entails I will proceed to ram my head into the wsl wall until it gives up or I do.

    Hoping we'll all get a piece of the Pie,

    Uldiniad