FORUMS
Remove All Ads from XDA

✦✦✦ [GUIDE] Build LineageOS ✦ How To use Github ✦✦✦

3,071 posts
Thanks Meter: 4,040
 
Post Reply Email Thread
14th November 2018, 12:57 AM |#411  
zogthegreat's Avatar
Member
Flag Montreal
Thanks Meter: 31
 
More
Grrr!!! So I was able to install the dependencies and retry compiling. 3 mins into the build, it failed again:

[ 0% 174/77640] host C++: protoc-gen-javastream <= frameworks/base/tools/streaming_proto/Errors.cpp
FAILED: /home/zog/work/los/out/host/linux-x86/obj/EXECUTABLES/protoc-gen-javastream_intermediates/Errors.o
/bin/bash -c "PWD=/proc/self/cwd /usr/bin/ccache prebuilts/clang/host/linux-x86/clang-4053586/bin/clang++ -I device/samsung/klte-common/include -I frameworks/base/tools/streaming_proto -I /home/zog/work/los/out/host/linux-x86/obj/EXECUTABLES/protoc-gen-javastream_intermediates -I /home/zog/work/los/out/host/linux-x86/gen/EXECUTABLES/protoc-gen-javastream_intermediates -I libnativehelper/include_deprecated \$(cat /home/zog/work/los/out/host/linux-x86/obj/EXECUTABLES/protoc-gen-javastream_intermediates/import_includes) -I system/core/include -I system/media/audio/include -I hardware/libhardware/include -I hardware/libhardware_legacy/include -I hardware/ril/include -I libnativehelper/include -I frameworks/native/include -I frameworks/native/opengl/include -I frameworks/av/include -c -fno-exceptions -Wno-multichar -Wa,--noexecstack -fPIC -no-canonical-prefixes -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fstack-protector -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS -O2 -g -fno-strict-aliasing --gcc-toolchain=prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8 --sysroot prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8/sysroot -fstack-protector-strong -m64 -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -DNDEBUG -UDEBUG -fdebug-prefix-map=/proc/self/cwd= -D__compiler_offsetof=__builtin_offsetof -Werror=int-conversion -Wno-reserved-id-macro -Wno-format-pedantic -Wno-unused-command-line-argument -fcolor-diagnostics -Wno-expansion-to-defined -fdebug-prefix-map=\$PWD/= -target x86_64-linux-gnu -Bprebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8/x86_64-linux/bin -Wsign-promo -Wno-inconsistent-missing-override -Wno-null-dereference -D_LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS -Wno-thread-safety-negative -isystem prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8/x86_64-linux/include/c++/4.8 -isystem prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8/x86_64-linux/include/c++/4.8/backward -isystem prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8/x86_64-linux/include/c++/4.8/x86_64-linux -std=gnu++14 -fPIE -D_USING_LIBCXX -DANDROID_STRICT -nostdinc++ -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast -Werror=address-of-temporary -Werror=return-type -MD -MF /home/zog/work/los/out/host/linux-x86/obj/EXECUTABLES/protoc-gen-javastream_intermediates/Errors.d -o /home/zog/work/los/out/host/linux-x86/obj/EXECUTABLES/protoc-gen-javastream_intermediates/Errors.o frameworks/base/tools/streaming_proto/Errors.cpp"
prebuilts/clang/host/linux-x86/clang-4053586/bin/clang++.real: error while loading shared libraries: libncurses.so.5: cannot open shared object file: No such file or directory
[ 0% 177/77640] Merge android manifest files: /home/zog/work/los/out/target/common/...works/base/core/res/AndroidManifest.xml frameworks/base/core/res/LineageManifest.xml
ninja: build stopped: subcommand failed.
19:00:39 ninja failed with: exit status 1

#### failed to build some targets (03:33 (mm:ss)) ####


I've been Googling the line 2 second line where it says "FAILED", but I haven't found anything that seems relevant. I also Googled the end part where it says "Merge android manifest files", but I can't tell if I have a problem there or not. Here is a copy of my LineageManifest.xml:

<?xml version="1.0" encoding="utf-8"?>
<!--
/*
* Copyright (c) 2017 The LineageOS Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="android">

<!-- Allows an application to override the power key action
@hide <p>Not for use by third-party applications.
-->
<permission android:name="android.permission.PREVENT_POWER_KEY "
androidrotectionLevel="signature|privileged" />

<!-- Used to launch a common app (FlipFlap) for devices with flip cover. -->
<protected-broadcast android:name="lineageos.intent.action.LID_STATE_CH ANGED" />

<!-- Used for long press power torch feature - automatic turn off on timeout -->
<protected-broadcast
android:name="com.android.server.policy.PhoneWindo wManager.ACTION_TORCH_OFF" />

<!-- Used to notify when SU is used. -->
<protected-broadcast android:name="android.intent.action.SU_SESSION_CHA NGED" />
</manifest>
 
 
18th November 2018, 08:33 AM |#412  
Junior Member
Thanks Meter: 1
 
More
Hey all

I'm trying to build LineageOS 16.0 for the note 3 (HLTE) on ubuntu 18.10, but I get some errors about O_TMPFILE.

FAILED: /home/lars/android/lineage/out/target/product/hlte/obj/SHARED_LIBRARIES/audio.primary.msm8974_intermediates/voice.o
/bin/bash -c "PWD=/proc/self/cwd /usr/bin/ccache prebuilts/clang/host/linux-x86/clang-4691093/bin/clang -I device/samsung/hlte-common/include -I external/tinyalsa/include -I external/tinycompress/include -I external/expat/lib -I system/media/audio_route/include -I system/media/audio_effects/include -I hardware/qcom/audio-caf/msm8974/hal/msm8974 -I hardware/qcom/audio-caf/msm8974/hal/audio_extn -I hardware/qcom/audio-caf/msm8974/hal/voice_extn -I hardware/qcom/audio-caf/msm8974/hal -I /home/lars/android/lineage/out/target/product/hlte/obj/SHARED_LIBRARIES/audio.primary.msm8974_intermediates -I /home/lars/android/lineage/out/target/product/hlte/gen/SHARED_LIBRARIES/audio.primary.msm8974_intermediates -I libnativehelper/include_jni \$(cat /home/lars/android/lineage/out/target/product/hlte/obj/SHARED_LIBRARIES/audio.primary.msm8974_intermediates/import_includes) -I system/core/include -I system/media/audio/include -I hardware/libhardware/include -I hardware/libhardware_legacy/include -I hardware/ril/include -I libnativehelper/include -I frameworks/native/include -I frameworks/native/opengl/include -I frameworks/av/include -isystem /home/lars/android/lineage/out/target/product/hlte/obj/include -isystem bionic/libc/include -isystem bionic/libc/kernel/uapi -isystem bionic/libc/kernel/uapi/asm-arm -isystem bionic/libc/kernel/android/scsi -isystem bionic/libc/kernel/android/uapi -c -fomit-frame-pointer -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -no-canonical-prefixes -DNDEBUG -UDEBUG -fno-exceptions -Wno-multichar -O2 -g -fno-strict-aliasing -fdebug-prefix-map=/proc/self/cwd= -D__compiler_offsetof=__builtin_offsetof -Werror=int-conversion -Wno-reserved-id-macro -Wno-format-pedantic -Wno-unused-command-line-argument -fcolor-diagnostics -Wno-expansion-to-defined -Wno-zero-as-null-pointer-constant -fdebug-prefix-map=\$PWD/= -ffunction-sections -fdata-sections -fno-short-enums -funwind-tables -fstack-protector-strong -Wa,--noexecstack -D_FORTIFY_SOURCE=2 -Wstrict-aliasing=2 -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Werror=date-time -Werror=format-security -nostdlibinc -msoft-float -march=armv7-a -mfloat-abi=softfp -mfpu=neon -mcpu=krait -mfpu=neon-vfpv4 -D__ARM_FEATURE_LPAE=1 -target arm-linux-androideabi -Bprebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.9/arm-linux-androideabi/bin -std=gnu99 -fstrict-aliasing -DPLATFORM_MSM8974 -DUSE_VENDOR_EXTN -Wno-error -DFLUENCE_ENABLED -DAFE_PROXY_ENABLED -DHFP_ENABLED -DCOMPRESS_VOIP_ENABLED -DAUDIO_EXTN_FORMATS_ENABLED -DHW_VARIANTS_ENABLED -DLOW_LATENCY_PRIMARY -DMP2_OFFLOAD_ENABLED -DLOW_LATENCY_CAPTURE_USE_CASE=1 -DHWDEP_CAL_ENABLED -fPIC -D_USING_LIBCXX -DANDROID_STRICT -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast -Werror=address-of-temporary -Werror=return-type -Wno-tautological-constant-compare -Wno-null-pointer-arithmetic -Wno-enum-compare -Wno-enum-compare-switch -MD -MF /home/lars/android/lineage/out/target/product/hlte/obj/SHARED_LIBRARIES/audio.primary.msm8974_intermediates/voice.d -o /home/lars/android/lineage/out/target/product/hlte/obj/SHARED_LIBRARIES/audio.primary.msm8974_intermediates/voice.o hardware/qcom/audio-caf/msm8974/hal/voice.c"
In file included from hardware/qcom/audio-caf/msm8974/hal/voice.c:26:
In file included from system/core/libcutils/include/cutils/log.h:1:
In file included from system/core/liblog/include/log/log.h:34:
In file included from system/core/liblog/include/log/log_read.h:26:
In file included from bionic/libc/include/fcntl.h:95:
bionic/libc/include/bits/fortify/fcntl.h:63:26: error: use of undeclared identifier 'O_TMPFILE'
__clang_error_if(__open_modes_useful(flags), "'open' " __open_too_few_args_error) {
^
bionic/libc/include/bits/fortify/fcntl.h:46:71: note: expanded from macro '__open_modes_useful'
#define __open_modes_useful(flags) (((flags) & O_CREAT) || ((flags) & O_TMPFILE) == O_TMPFILE)
^
bionic/libc/include/bits/fortify/fcntl.h:63:26: error: use of undeclared identifier 'O_TMPFILE'
bionic/libc/include/bits/fortify/fcntl.h:46:85: note: expanded from macro '__open_modes_useful'
#define __open_modes_useful(flags) (((flags) & O_CREAT) || ((flags) & O_TMPFILE) == O_TMPFILE)
^
bionic/libc/include/bits/fortify/fcntl.h:70:29: error: use of undeclared identifier 'O_TMPFILE'
__clang_warning_if(!__open_modes_useful(flags) && modes,
^
bionic/libc/include/bits/fortify/fcntl.h:46:71: note: expanded from macro '__open_modes_useful'
#define __open_modes_useful(flags) (((flags) & O_CREAT) || ((flags) & O_TMPFILE) == O_TMPFILE)
^
bionic/libc/include/bits/fortify/fcntl.h:70:29: error: use of undeclared identifier 'O_TMPFILE'
bionic/libc/include/bits/fortify/fcntl.h:46:85: note: expanded from macro '__open_modes_useful'
#define __open_modes_useful(flags) (((flags) & O_CREAT) || ((flags) & O_TMPFILE) == O_TMPFILE)
^
bionic/libc/include/bits/fortify/fcntl.h:83:26: error: use of undeclared identifier 'O_TMPFILE'
__clang_error_if(__open_modes_useful(flags), "'openat' " __open_too_few_args_error) {
^
bionic/libc/include/bits/fortify/fcntl.h:46:71: note: expanded from macro '__open_modes_useful'
#define __open_modes_useful(flags) (((flags) & O_CREAT) || ((flags) & O_TMPFILE) == O_TMPFILE)
^
bionic/libc/include/bits/fortify/fcntl.h:83:26: error: use of undeclared identifier 'O_TMPFILE'
bionic/libc/include/bits/fortify/fcntl.h:46:85: note: expanded from macro '__open_modes_useful'
#define __open_modes_useful(flags) (((flags) & O_CREAT) || ((flags) & O_TMPFILE) == O_TMPFILE)
^
bionic/libc/include/bits/fortify/fcntl.h:90:29: error: use of undeclared identifier 'O_TMPFILE'
__clang_warning_if(!__open_modes_useful(flags) && modes,
^
Any seen this before and have an idea of what is wrong?

Found out that I should:

repopick -t pie-mode-bits

https://review.lineageos.org/#/q/bra...ie-mode-bits

from this

Regards, Lars
21st November 2018, 10:24 AM |#413  
Junior Member
Thanks Meter: 4
 
More
Thanks
it helped me ... to solve some of my problems
21st November 2018, 11:04 PM |#414  
Junior Member
Thanks Meter: 0
 
More
Help S4 mini i9195 serranoltexx
Hi, my device is a Samsung S4 mini (i9195) and the codename is serranoltexx.
my repo is: //github.com/LineageOS/android.git -b cm-14.1

I make $ source build / envsetup.sh and perfect, but $ breakfast serranoltexx I get this error: build / core / product_config.mk: 254: *** _nic.PRODUCTS. [[Device / samsung / serranoltexx / lineage.mk]] : "vendor / samsung / serrano-common / serrano-common-vendor.mk" does not exist. High.
build / core / product_config.mk: 254: *** _nic.PRODUCTS. [[device / samsung / serranoltexx / lineage.mk]]: "vendor / samsung / serrano-common / serrano-common-vendor.mk" does not exist High.

** Do not have a product spec for: 'lineage_serranoltexx'
** Do you have the right repo manifest?

Jump to the option: Extracting proprietary blobs from block-based OTAs, I assemble the image well, I position myself in the directory where are the sources of my device:
~ / android / lineage / device / samsung / serranoltexx #, I enter the command ./extract-files.sh ~ / android / system_dump / and I get this error: db: error: remote object '/ system / bin / btnvtool' does not exist

I check the remote object and if it exists.

Can you give me a hand to give me light in the matter?

Thank you.
22nd November 2018, 12:01 AM |#415  
Relentless Terminator's Avatar
OP Forum Moderator
Flag Skynet
Thanks Meter: 4,040
 
Donate to Me
More
Quote:
Originally Posted by misco55

Hi, my device is a Samsung S4 mini (i9195) and the codename is serranoltexx.
my repo is: //github.com/LineageOS/android.git -b cm-14.1

I make $ source build / envsetup.sh and perfect, but $ breakfast serranoltexx I get this error: build / core / product_config.mk: 254: *** _nic.PRODUCTS. [[Device / samsung / serranoltexx / lineage.mk]] : "vendor / samsung / serrano-common / serrano-common-vendor.mk" does not exist. High.
build / core / product_config.mk: 254: *** _nic.PRODUCTS. [[device / samsung / serranoltexx / lineage.mk]]: "vendor / samsung / serrano-common / serrano-common-vendor.mk" does not exist High.

** Do not have a product spec for: 'lineage_serranoltexx'
** Do you have the right repo manifest?

Jump to the option: Extracting proprietary blobs from block-based OTAs, I assemble the image well, I position myself in the directory where are the sources of my device:
~ / android / lineage / device / samsung / serranoltexx #, I enter the command ./extract-files.sh ~ / android / system_dump / and I get this error: db: error: remote object '/ system / bin / btnvtool' does not exist

I check the remote object and if it exists.

Can you give me a hand to give me light in the matter?

Thank you.

Add repo blobs directly into manifest.
Search here https://github.com/TheMuppets
The Following User Says Thank You to Relentless Terminator For This Useful Post: [ View ] Gift Relentless Terminator Ad-Free
22nd November 2018, 12:24 AM |#416  
Junior Member
Thanks Meter: 0
 
More
[QUOTE=FSadino;78227971]Add repo blobs directly into manifest.
Search here //github.com/TheMuppets
Hi,
How add repo blobs directly into manifest.?
Thank you.
22nd November 2018, 12:35 AM |#417  
Relentless Terminator's Avatar
OP Forum Moderator
Flag Skynet
Thanks Meter: 4,040
 
Donate to Me
More
[QUOTE=misco55;78228082]
Quote:
Originally Posted by FSadino

Add repo blobs directly into manifest.
Search here //github.com/TheMuppets
Hi,
How add repo blobs directly into manifest.?
Thank you.

Please read second post.
The Following User Says Thank You to Relentless Terminator For This Useful Post: [ View ] Gift Relentless Terminator Ad-Free
22nd November 2018, 02:17 PM |#418  
zogthegreat's Avatar
Member
Flag Montreal
Thanks Meter: 31
 
More
OK, I took a big step back, wiped my hard drive and reinstalled Ubuntu 16.04. After that, I was able to successfully build LineageOS 14.1 for my Samsung S5.

I then ran "make clobber" and reinitialized my my build tree with:

repo init -u https://github.com/LineageOS/android.git -b lineage-15.1

However when I try to sync my repo, I get the following error:

Syncing work tree: 78% (512/656) error: Your local changes to the following files would be overwritten by checkout:
res/xml/device_info_settings.xml
Please, commit your changes or stash them before you can switch branches.
Aborting
Syncing work tree: 100% (656/656), done.

packages/apps/Settings/: discarding 858 commits
error: packages/apps/Settings/: LineageOS/android_packages_apps_Settings checkout b9634cdec5784b2bc341712865172b8910828d03


I've tried to add "<project name="LineageOS/android_packages_apps_Settings" path="vendor/samsung" remote="github" />" to my roomservice.xml, but I still get the same error.

Does anyone have any suggestions?

Thanks!

zog
22nd November 2018, 02:20 PM |#419  
Relentless Terminator's Avatar
OP Forum Moderator
Flag Skynet
Thanks Meter: 4,040
 
Donate to Me
More
Quote:
Originally Posted by zogthegreat

OK, I took a big step back, wiped my hard drive and reinstalled Ubuntu 16.04. After that, I was able to successfully build LineageOS 14.1 for my Samsung S5.

I then ran "make clobber" and reinitialized my my build tree with:

repo init -u https://github.com/LineageOS/android.git -b lineage-15.1

However when I try to sync my repo, I get the following error:

Syncing work tree: 78% (512/656) error: Your local changes to the following files would be overwritten by checkout:
res/xml/device_info_settings.xml
Please, commit your changes or stash them before you can switch branches.
Aborting
Syncing work tree: 100% (656/656), done.

packages/apps/Settings/: discarding 858 commits
error: packages/apps/Settings/: LineageOS/android_packages_apps_Settings checkout b9634cdec5784b2bc341712865172b8910828d03


I've tried to add "<project name="LineageOS/android_packages_apps_Settings" path="vendor/samsung" remote="github" />" to my roomservice.xml, but I still get the same error.

Does anyone have any suggestions?

Thanks!

zog

make clobber is not enough if you want to sync entirely new branches.
I recommend you create new working directory for 15.1 branch
The Following 2 Users Say Thank You to Relentless Terminator For This Useful Post: [ View ] Gift Relentless Terminator Ad-Free
22nd November 2018, 11:31 PM |#420  
zogthegreat's Avatar
Member
Flag Montreal
Thanks Meter: 31
 
More
Quote:
Originally Posted by FSadino

make clobber is not enough if you want to sync entirely new branches.
I recommend you create new working directory for 15.1 branch

Thanks FSadino!

#### build completed successfully (06:19:38 (hh:mm:ss)) ####

That did the trick!
The Following User Says Thank You to zogthegreat For This Useful Post: [ View ] Gift zogthegreat Ad-Free
23rd November 2018, 03:23 PM |#421  
zogthegreat's Avatar
Member
Flag Montreal
Thanks Meter: 31
 
More
After building LineageOS Oreo, I made a new directory and I tried to compile LineageOS Pie. When I tried to start jack server, I encountered a java error:

[email protected]:~/work/pie$ export JACK_SERVER_VM_ARGUMENTS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx6g"
[email protected]:~/work/pie$ ./prebuilts/sdk/tools/jack-admin start-server
Launching Jack server java -XX:MaxJavaStackTraceDepth=-1 -Djava.io.tmpdir=/tmp -Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx6g -cp /home/zog/.jack-server/launcher.jar com.android.jack.launcher.ServerLauncher
Jack server failed to (re)start, try 'jack-diagnose' or see Jack server log
[email protected]:~/work/pie$ ./prebuilts/sdk/tools/jack-diagnose
/home/zog/work/pie/prebuilts/jdk/jdk9/linux-x86/bin/java': Failed to parse version, please ensure you're running a supported java

[email protected]:~/work/pie$ java -version
openjdk version "9"
OpenJDK Runtime Environment (build 9+181-android4627429)
OpenJDK 64-Bit Server VM (build 9+181-android4627429, mixed mode)

Which version of java do I need for Android Pie?
Post Reply Subscribe to Thread

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes