Kernel Configuration - Nexus Platform join failed - android

I am doing kernel configuration for ICS. I needed to enable Posix message queue as it is required in one of our applications. But enabling this option resulted in error. The make was successfull. But the image could not be loaded. The dmesg was:-
disagrees about version of symbol module_layout.
init: untracked pid 2038 exited.
logcat :-
mknod : '/dev/nexus_proxy' failed
NEXUS_Platform_Join [CONSTRUCTOR] failed.

Looks like you rebuilt only the kernel.
You need to build any kernel-modules (*.ko files) and
update them onto the filesystem.
Here is a detailed discussion on the disagrees about version of symbol error.

Related

Android Kernel Configs

I am a newbie in Android13 I have setup the AOSP by following steps-
repo init -u https://android.googlesource.com/platform/manifest -b android-13.0.0_r31
repo sync
source build/envsetup.sh
lunch aosp_cf_x86_auto-userdebug
emulator
But I am getting following errors:
> WARNING: encryption is off
> WARNING: lavapipe is not a conformant vulkan implementation, testing use only.
> WARNING: Ignoring invalid http proxy: Bad format: invalid port number (must be decimal)
> INFO: IniFile.cpp:177: Failed to process .ini file /home/dsx1pu/.android/emu-update-last-check.ini for reading.
> WARNING: UpdateCheck: Failure: Error
> WARNING: UpdateCheck: failed to get the latest version, skipping check (current version '30.3.0-6946397')
> WARNING: UpdateCheck: Failure: Error
> ^CSaving state on exit with session uptime 28291 ms
>
Note: I am working inside Virtual Box.
My requirement is I want to explore the automotive OS and to somehow build from source code and emulate any one of the product on my x86 laptop.
So I can experiment with the AOSP and see the effect on my emulated automotive device what are different approaches.
I was thinking if I can work inside qemu. Please suggest.
Also I see following options, what are these and how they differ:
aosp_car_x86_64-userdebug
car_x86_64-userdebug
what is the difference between the two?
Please excuse me if something is irrevalant in the question.
Please guide.. considering me as a beginner.
Also suggest any article or put some light on android build process.
Any knowledge shared or experience is highly appreciated.
Also to end I will be really thannkful if someone can suggest some forums and community to follow to acquire the knowledge of Android Automotive OS.
Thanks!

Getting a custom ramdisk to boot on Android

I am working on a "GNU/Linux on Android" type of project that is based on Mikael Q. Kuisma's work here .
I built a tool that downloads a toolchain, compiles the kernel, archives the custom ramdisk, and finally bundles them into a boot image.
Expected result:
Kernel boots.
Ramdisk gets loaded and /init is executed using /sbin/busybox.
Actual result:
Kernel does boot.
The kernel never seems to reach /init, and hangs without panicking.
I've tried adding calls to /sbin/busybox poweroff in the /init script to see if it was actually reaching execution, nothing changed.
I identified a few points that seemed problematic, one being this:
[ 3.880314] Warning: unable to open an initial console.
[ 3.880429] Waiting for root device ... # Might be the problem.
[ 4.882304] lct will vote for sdp current
[ 4.882437] pmi632_charger: smblib_update_usb_type: lct v02 battery charge APSD=SDP PD=0
[ 4.889933] msm-dwc3 7000000.ssusb: DWC3 exited from low power mode
[ 5.520181] of_batterydata_get_best_profile: light_4000mAh found
[ 8.760236] cfg_timer_func enter
[ 8.760267] cfg_work_routine enter
# Nothing appears after this point...
I have included the source code for my build tool with the kernel log buffer in this git repository. You can find the defconfig I used for the kernel build here.
Any help would be appreciated. :)

recipe for target 'ninja_wrapper' failed / flex core dumps

First time android builder here. I used to do a lot of roll your own back on FreeBSD in the day. Getting back into geekdom with android.
I am trying to build android-7.0.0_r14 for the Nexus 6 NBD90Z to run under emulation. I plan to eventually build for my actual phone and this config is pretty close. I am building on ubuntu 18.04 LTS which is newer than what the docs recommend. Maybe that is a bit adventurous.
Here is what I get when I run make.
... snip
build/core/base_rules.mk:316: warning: ignoring old commands for target
out/target/product/shamu/system/lib/soundfx/libqcomvoiceprocessing.so'
Starting build with ninja
ninja: Entering directory.'
ninja: warning: multiple rules generate out/target/product/shamu/system/etc/gps.conf. builds involving this target will not be correct; continuing anyway [-w dupbuild=warn]
[ 0% 1/35600] Lex: libaidl-common <= system/tools/aidl/aidl_language_l.ll
FAILED: /bin/bash -c "prebuilts/misc/linux-x86/flex/flex-2.5.39 -oout/host/linux-x86/obj/STATIC_LIBRARIES/libaidl-common_intermediates/aidl_language_l.cpp system/tools/aidl/aidl_language_l.ll"
flex-2.5.39: loadlocale.c:130: _nl_intern_locale_data: Assertion `cnt < (sizeof (_nl_value_type_LC_TIME) / sizeof (_nl_value_type_LC_TIME[0]))' failed.
Aborted (core dumped)
ninja: build stopped: subcommand failed.
build/core/ninja.mk:148: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
A core dump for flex was not produced in spite of the error message given.
out/host/linux-x86/obj/STATIC_LIBRARIES/libaidl-common_intermediates/aidl_language_l.cpp does not exist. That entire folder is empty. It would seem that something is not downloading/copying the aidl_language_l.cpp.
Any ideas on what I might have messed up?
I am still a little confused at the complexity of git/repo/make/ninja/soong/lunch to conduct a build. It is likely that I missed something obvious.
Thanks,
Jason C. Wells
Just replace your make by export LC_ALL=C make or put the export in your .bashrc
After I looked at this a little closer I realized the prebuilt prebuilts/misc/linux-x86/flex/flex-2.5.39 would dump core with no arguments. I created a soft link to /usr/bin/flex. Compilation seems to be proceeding.
I haven't answered why the prebuilt was dumping. My goal is to compile android, not troubleshoot the tools.
I performed Snorky's steps. I deleted my output directory for libaidl-common_intermediates. I deleted my soft link and restored the android tree version of flex. I re-ran make at the top of the local repo. The build proceeded past the error above and stopped at a new error. It appears that Snorky's answer worked.
Doh! I'm new so S.O. didn't give credit for my upvote.

Cannot compile bazel needed for tensorflow-android

I'm trying to explore the tensorflow android demo. I want to adapt the app using android studio.
However when I simply follow the instructions I get compilation errors no matter what I do:
Trying to compile tensorflow using bazel and NDK r12b:
$bazel build -c opt //tensorflow/examples/android:tensorflow_demo
ERROR: /home/myUser/libs/tensorflow_android/WORKSPACE:3:1: //external:io_bazel_rules_closure: no such attribute 'urls' in 'http_archive' rule.
ERROR: /home/myUser/libs/tensorflow_android/WORKSPACE:3:1: //external:io_bazel_rules_closure: missing value for mandatory attribute 'url' in 'http_archive' rule.
ERROR: com.google.devtools.build.lib.packages.BuildFileContainsErrorsException: error loading package '': Encountered error while reading extension file 'closure/defs.bzl': no such package '#io_bazel_rules_closure//closure': error loading package 'external': Could not load //external package.
INFO: Elapsed time: 0.129s
Trying to compile a newer version of bazel following this advice:
$bazel version
Build label: 0.2.3-jdk7 // This is my current version of bazel
via apt-get:
$sudo apt-get upgrade bazel
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
E: Unable to locate package bazel
from source (tried bazel-0.4.2 and bazel-0.5.0):
$./compile.sh
INFO: You can skip this first step by providing a path to the bazel binary as second argument:
INFO: ./compile.sh compile /path/to/bazel
🍃 Building Bazel from scratch
ERROR: JDK version (1.7) is lower than 1.8, please set $JAVA_HOME.
or
$bazel build //src:bazel
ERROR: /home/myUser/libs/bazel/bazel-0.4.2/tools/build_rules/genproto.bzl:45:16: Traceback (most recent call last):
File "/home/myUser/libs/bazel/bazel-0.4.2/tools/build_rules/genproto.bzl", line 42
rule(gensrcjar_impl, attrs = {"src": at..."), <2 more arguments>), "_proto_compiler": attr.label(default = Label("//third_party/p..."), <4 more arguments>), "_jar": attr.label(default = Label("#bazel_tools//t..."), <4 more arguments>), "_jdk": attr.label(default = Label("#bazel_tools//t..."), ...)}, ..."})
File "/home/myUser/libs/bazel/bazel-0.4.2/tools/build_rules/genproto.bzl", line 45, in rule
attr.label(allow_files = proto_filetype, sing...)
allow_files should be a boolean or a filetype object.
ERROR: /home/myUser/libs/bazel/bazel-0.4.2/src/BUILD:130:1: error loading package 'src/main/protobuf': Extension file 'tools/build_rules/genproto.bzl' has errors and referenced by '//src:embedded_tools'.
ERROR: Loading failed; build aborted.
INFO: Elapsed time: 0.251s
switching aroung java-versions to see whether the bazel compiling issues come from there:
$sudo update-alternatives --config java
There are 4 choices for the alternative java (providing /usr/bin/java).
Selection Path Priority Status
------------------------------------------------------------
0 /usr/lib/jvm/java-8-oracle/jre/bin/java 1074 auto mode
1 /usr/lib/jvm/java-7-openjdk-amd64/jre/bin/java 1071 manual mode
* 2 /usr/lib/jvm/java-7-oracle/jre/bin/java 1072 manual mode
3 /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java 1069 manual mode
4 /usr/lib/jvm/java-8-oracle/jre/bin/java 1074 manual mode
No luck so far :-/. Has anyone successfully compiled tensorflow for android from source?
What version of Tensorflow, NDK, bazel, java are required / compatible with each other? Do I really need bazel? (never worked with it anyway) Can't I just compile the android demo in android-studio like any other app?
I'm using Ubuntu 14.04, Cuda8.0, cudnn_v5.1, Titan X Pascal (not sure if these things matter)
Installing Bazel on Ubuntu can be done without compiling.
Follow all steps of the dedicated documentation: Install Bazel on Ubuntu

Installing compile samples 4.0 failed nvidia

While installing NVidia Android CodeWorks I have received an error at the very end of the installation process saying :
installing compile samples 4.0 failed nvidia
Return Code: 2Compile Samples failed. Please check the /home/user/NVPACK//_installer/compile.log. You can send it to TegraDeveloperPack-Users#nvidia.com if you can not resolve it.
Does anyone know how to solve this problem please
So that other people having the same problem might go on something for I have not found an optimal solution to this problem.
I have managed to solve it by simply copying my version of jdk (which is jdk1.8.0_101) to the specified Nvidia Codeworks folder and renaming to the one missing in the log (...\Nvidia\Codeworks_installer\compile.log - \Nvidia\Codeworks\jdk1.8.0_77" does not exist.) In my case it compiled successfully, however it must be noted that this is not a good solution. Messing around with the environment valuables might be a reasonable place to start otherwise.
If your log file shows:
Error: JAVA_HOME is not defined correctly.
make: *** [antbuild_Basic_debug] Error 1
We cannot execute /usr/bin/java
Makefile.Basic.mk:92: recipe for target 'antbuild_Basic_debug' failed
you can fix it by creating a soft link like this:
sudo ln -s $JAVA_HOME/bin/java /usr/bin/java

Categories

Resources