touch screen and battery status does not work on Surface Pro 6

1,680 views
Skip to first unread message

ロジャー

unread,
Mar 27, 2019, 10:36:48 PM3/27/19
to Android-x86
According to the the tutorial of this:

Extracting the correct firmware zip and placing into /system/lib/firmware could fix the touch screen:
https://github.com/jakeday/linux-surface/tree/master/firmware

I have tried it works on their ROM, but not on Android x86 one.
May I know how could I fix the touch screen?

Thanks.

Jon West

unread,
Mar 28, 2019, 8:54:17 AM3/28/19
to Android-x86
You will have to use one of the IPTS kernels we have on the Bliss-x86 repo
https://github.com/BlissRoms-x86/kernel_common

ロジャー

unread,
Mar 28, 2019, 9:06:46 AM3/28/19
to Android-x86
Thanks for your reply.
May I know how to use this?

Jon West

unread,
Mar 28, 2019, 6:07:28 PM3/28/19
to Android-x86
You would have to switch to that branch of the source and rebuild

Jon West

unread,
Mar 28, 2019, 6:10:03 PM3/28/19
to Android-x86
$ git remote add BR-x86 https://github.com/BlissRoms-x86/kernel_common && git fetch BR-x86
$ git checkout BR-x86/k4.9.153-ipts && make clean && make mrproper && git checkout BR-x86/kernel-4.9 && git checkout BR-x86/k4.9.153-ipts


On Thursday, March 28, 2019 at 9:06:46 AM UTC-4, ロジャー wrote:

ロジャー

unread,
Mar 29, 2019, 4:41:26 AM3/29/19
to Android-x86
I have tried replacing the kernel directory, or merging the directory, both gives error message.

This is the error message when merging the kernerl directory:

Thanks.

Jon West

unread,
Mar 29, 2019, 8:13:26 PM3/29/19
to Android-x86
Why in gods name would you try merging it. Just checkout the new kernel branch and build. Doesn't get much more simpler than that. If you want the most recent kernel from Android-x86, with te IPTS commits, that would be the k4.19.24-ax86-ipts2 branch
so: 
$ git checkout BR-x86/k4.19.24-ax86-ipts2 && make clean && make mrproper && git checkout BR-x86/k4.19.24-ax86 && git checkout BR-x86/k4.19.24-ax86-ipts2

Then build

ロジャー

unread,
Mar 30, 2019, 2:41:55 AM3/30/19
to Android-x86
I have run these two commands:
$ git remote add BR-x86 https://github.com/BlissRoms-x86/kernel_common && git fetch BR-x86
$ git checkout BR-x86/k4.9.153-ipts && make clean && make mrproper && git checkout BR-x86/kernel-4.9 && git checkout BR-x86/k4.9.153-ipts

Now I have these files:

Screenshot from 2019-03-30 14-40-27.png


May I know how to use them? How to integrate them into the Android x86 ROM?


Thanks.

Jon West

unread,
Mar 30, 2019, 9:24:52 AM3/30/19
to Android-x86
Assuming you did that from /kernel, 
$ cd ..
$ . build/envsetup.sh
$ lunch android_x86_64-userdebug
$ make clean && make iso_img
Message has been deleted
Message has been deleted

ロジャー

unread,
Mar 30, 2019, 2:05:34 PM3/30/19
to Android-x86
May you please take a look on the error?
https://pastebin.com/Ncfcrvku
https://pastebin.com/q54GvrkN

Thanks.

Jon West

unread,
Mar 30, 2019, 8:52:42 PM3/30/19
to Android-x86
  1. FAILED: out/target/product/x86_64/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_opcodes.h
  2. /bin/bash -c "python external/mesa/src/compiler/nir/nir_opcodes_h.py external/mesa/src/compiler/nir/nir_opcodes.py > out/target/product/x86_64/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_opcodes.h"
  3. Traceback (most recent call last):
  4.   File "external/mesa/src/compiler/nir/nir_opcodes_h.py", line 45, in <module>
  5.     from mako.template import Template
  6. ImportError: No module named mako.template
  7. [  8% 9160/102783] build out/target/product/x86_64/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_intrinsics.h
  8. FAILED: out/target/product/x86_64/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_intrinsics.h
  9. /bin/bash -c "python external/mesa/src/compiler/nir/nir_intrinsics_h.py --outdir out/target/product/x86_64/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/ || ( out/target/product/x86_64/gen/STATIC_LIBRARIES/libmesa_nir_intermediates/nir/nir_intrinsics.h; false)"
  10. Traceback (most recent call last):
  11.   File "external/mesa/src/compiler/nir/nir_intrinsics_h.py", line 42, in <module>
  12.     from mako.template import Template
  13. ImportError: No module named mako.template
Looks like it's failing there. 

That's not in the kernel, so I don't know what you would have there. Possibly try updating Mesa to Mauro's latest 18.3.5 branch?

ロジャー

unread,
Mar 30, 2019, 10:37:48 PM3/30/19
to Android-x86
I can see the most updated commit for Oreo is on 2019-02-20.
And the branches are in Android version names.

May I know where could I find Mauro's 18.3.5 branch?

ロジャー

unread,
Mar 30, 2019, 10:52:38 PM3/30/19
to Android-x86
I have "git remote add https://github.com/mesa3d/mesa.git" in here:
android-x86/external/mesa/
and switched to 18.3.5

afterwards. can I switch back to android-x86 and build again?
Or do I need to make anything in mesa directory?

ロジャー

unread,
Mar 31, 2019, 1:51:38 AM3/31/19
to Android-x86
This is the most recent result I have got.
May you please take a look?
https://drive.google.com/file/d/1YYy_2UBr1QZJCXG685sYgz34Hekvt0CP/view?usp=sharing
Thanks.

Mauro Rossi

unread,
Mar 31, 2019, 5:25:47 AM3/31/19
to Android-x86
Hi,

On Sunday, March 31, 2019 at 4:52:38 AM UTC+2, ロジャー wrote:
I have "git remote add https://github.com/mesa3d/mesa.git" in here:
android-x86/external/mesa/
and switched to 18.3.5

afterwards. can I switch back to android-x86 and build again?
Or do I need to make anything in mesa directory?

First of all you need all build system necessary packages installed

 

AOSP build environment
----------------------


sudo apt
-get -y install git git-email repo


sudo apt
-get -y install bison g++-multilib git gperf libxml2-utils make zlib1g-dev:i386 zip


sudo apt
-get -y install git gnupg flex bison gperf build-essential \
  zip curl libc6
-dev libncurses5-dev:i386 x11proto-core-dev \
  libx11
-dev:i386 libreadline6-dev:i386 libgl1-mesa-glx:i386 \
  libgl1
-mesa-dev g++-multilib tofrodos \
  python
-markdown libxml2-utils xsltproc zlib1g-dev:i386


sudo ln
-s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so


sudo apt
-get -y install yasm squashfs-tools syslinux-utils


sudo apt
-get -y install python-mako


sudo apt install libssl
-dev libelf-dev



The external/mesa project in oreo-x86 branch is to be used as a start,
do not checkout mainstream without the oreo-x86 patches or it will not work as intended

If you want to update to 18.3.6

[use nano as default editor]

[from oreo-x86 folder]
repo sync --no-tags --no-clone-bundle external/mesa

cd external
/mesa
git remote add freedesktop https
://gitlab.freedesktop.org/mesa/mesa
git fetch freedesktop
18.3
git merge freedesktop
/18.3


[commit the merge operation with CTRL+X ]

Then rebuild
Mauro

Mauro Rossi

unread,
Mar 31, 2019, 9:27:08 AM3/31/19
to Android-x86
As soon as it is officially available, it was supposed to be releases this week

at the moment 18.3.5 is the latest available

ロジャー

unread,
Mar 31, 2019, 9:34:17 AM3/31/19
to Android-x86
Thank you for your detail tuturoail.
I will try again later when I have time.

I really hope Android-x86 or BlissOS will update to support my Surface Pro 6.
(Yet it is a good chance for me to learn building ROM LOL)

Thanks again.

ロジャー

unread,
Apr 1, 2019, 4:22:13 AM4/1/19
to Android-x86
1 warning generated.
[ 82% 84365/102783] target  C: libmesa_radv_common <= out/target/product/x86_64/obj/STATIC_LIBRARIES/libmesa_radv_common_intermediates/radv_entrypoints.c
In file included from out/target/product/x86_64/obj/STATIC_LIBRARIES/libmesa_radv_common_intermediates/radv_entrypoints.c:26:
In file included from external/mesa/src/amd/vulkan/radv_private.h:58:
external/mesa/src/amd/common/ac_gpu_info.h:39:31: warning: redefinition of typedef 'amdgpu_device_handle' is a C11 feature [-Wtypedef-redefinition]
typedef struct amdgpu_device *amdgpu_device_handle;
                              ^
external/libdrm/amdgpu/amdgpu.h:116:31: note: previous definition is here
typedef struct amdgpu_device *amdgpu_device_handle;
                              ^
1 warning generated.
[ 82% 84418/102783] //external/llvm70/lib/Target/AArch64/InstPrinter:libLLVM70AArch64AsmPrinter clang++ AArch64InstPrinter.cpp [x86]
FAILED: out/soong/.intermediates/external/llvm70/lib/Target/AArch64/InstPrinter/libLLVM70AArch64AsmPrinter/android_x86_x86_64_static_core/obj/external/llvm70/lib/Target/AArch64/InstPrinter/AArch64InstPrinter.o 
PWD=/proc/self/cwd prebuilts/clang/host/linux-x86/clang-4053586/bin/clang++ -c -Iexternal/llvm70/lib/Target/AArch64/InstPrinter  -fno-exceptions -Wno-multichar -O2 -Wa,--noexecstack -Werror=format-security -D_FORTIFY_SOURCE=2 -Wstrict-aliasing=2 -ffunction-sections -fno-short-enums -fstrict-aliasing -funwind-tables -fstack-protector-strong -no-canonical-prefixes -O2 -g -fno-strict-aliasing -msse3 -mstackrealign -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/= -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Werror=date-time -nostdlibinc -m32 -march=prescott -DUSE_SSSE3 -mssse3 -msse4 -msse4.1 -msse4.2 -Iexternal/llvm70/include -Iexternal/llvm70/device/include -Iout/soong/.intermediates/external/llvm70/llvm70-gen-attributes/gen -Iout/soong/.intermediates/external/llvm70/llvm70-gen-intrinsics/gen -Iout/soong/.intermediates/external/llvm70/llvm70-gen-revision/gen -Iexternal/llvm70/lib/Target/AArch64 -Iexternal/libcxx/include -Iexternal/libcxxabi/include -Iout/soong/.intermediates/external/llvm70/lib/Target/AArch64/llvm70-gen-aarch64/gen -Isystem/core/include -Isystem/media/audio/include -Ihardware/libhardware/include -Ihardware/libhardware_legacy/include -Ihardware/ril/include -Ilibnativehelper/include -Iframeworks/native/include -Iframeworks/native/opengl/include -Iframeworks/av/include -isystem bionic/libc/arch-x86/include -isystem bionic/libc/include -isystem bionic/libc/kernel/uapi -isystem bionic/libc/kernel/uapi/asm-x86 -isystem bionic/libc/kernel/android/scsi -isystem bionic/libc/kernel/android/uapi -Ilibnativehelper/include_deprecated -D_GNU_SOURCE -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -fomit-frame-pointer -Wall -W -Wno-sign-compare -Wno-unused-parameter -Wno-missing-field-initializers -Wwrite-strings -Werror -Dsprintf=sprintf -Wno-error=unused-lambda-capture -Wno-error=user-defined-warnings -target i686-linux-android -Bprebuilts/gcc/linux-x86/x86/x86_64-linux-android-4.9/x86_64-linux-android/bin -fPIC -D_USING_LIBCXX -std=gnu++14 -Wsign-promo -Wno-inconsistent-missing-override -Wno-null-dereference -D_LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS -Wno-thread-safety-negative -Wno-sign-promo -std=c++11 -Woverloaded-virtual -fno-rtti  -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast -Werror=address-of-temporary -Werror=return-type -MD -MF out/soong/.intermediates/external/llvm70/lib/Target/AArch64/InstPrinter/libLLVM70AArch64AsmPrinter/android_x86_x86_64_static_core/obj/external/llvm70/lib/Target/AArch64/InstPrinter/AArch64InstPrinter.o.d -o out/soong/.intermediates/external/llvm70/lib/Target/AArch64/InstPrinter/libLLVM70AArch64AsmPrinter/android_x86_x86_64_static_core/obj/external/llvm70/lib/Target/AArch64/InstPrinter/AArch64InstPrinter.o external/llvm70/lib/Target/AArch64/InstPrinter/AArch64InstPrinter.cpp
terminating with uncaught exception of type std::bad_alloc: std::bad_alloc
clang++.real: error: unable to execute command: Aborted (core dumped)
clang++.real: error: clang frontend command failed due to signal (use -v to see invocation)
Android clang version 5.0.300080  (based on LLVM 5.0.300080)
Target: i686--linux-android
Thread model: posix
InstalledDir: prebuilts/clang/host/linux-x86/clang-4053586/bin
clang++.real: note: diagnostic msg: PLEASE submit a bug report to http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and associated run script.
clang++.real: note: diagnostic msg: 
********************

PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang++.real: note: diagnostic msg: /tmp/AArch64InstPrinter-66e851.cpp
clang++.real: note: diagnostic msg: /tmp/AArch64InstPrinter-66e851.sh
clang++.real: note: diagnostic msg: 

********************
[ 82% 84425/102783] //external/llvm70/lib/Target/AArch64:libLLVM70AArch64CodeGen clang++ AArch64TargetMachine.cpp
ninja: build stopped: subcommand failed.
14:10:06 ninja failed with: exit status 1

#### failed to build some targets (02:47:02 (hh:mm:ss)) ####

building android-x86 + mesa update ends with this error

Mauro Rossi

unread,
Apr 1, 2019, 8:34:43 AM4/1/19
to Android-x86
You need to set more memory for java builds.
Search 'carnac' in this forum
12Gb of RAM are also recommended.auro

ロジャー

unread,
Apr 1, 2019, 10:45:22 AM4/1/19
to Android-x86
I have put "-Xmx12000m" as
JACK_SERVER_COMMAND="java -XX:MaxJavaStackTraceDepth=-1 -Djava.io.tmpdir=$TMPDIR $JACK_SERVER_VM_ARGUMENTS -Xmx4096m -cp $LAUNCHER_JAR $LAUNCHER_NAME
in ./prebuilts/sdk/tools/jack-admin prebuilts/sdk/tools/jack-admin, and then
./prebuilts/sdk/tools/jack-admin stop-server
./prebuilts/sdk/tools/jack-admin start-server

And then I always get a "Communication error with Jack server (52). Try 'jack-diagnose'" shortly after start making. "jack-diagnose" says the connection is normal.

I am on Ubuntu 18.04, with i5-8400 2.80GHz and 16GB RAM.
I think my computer should be good enough?

Mauro Rossi

unread,
Apr 1, 2019, 4:44:08 PM4/1/19
to Android-x86
Hi, try with 6Gbytes -Xmx6G

ロジャー

unread,
Apr 2, 2019, 9:35:43 PM4/2/19
to Android-x86
Hello,

It seems making progress.
And this is the latest error:

Thank you.
Reply all
Reply to author
Forward
0 new messages