Questions tagged [android-soong]

Soong is the replacement for the old Android make-based build system. It replaces Android.mk files with Android.bp files, which are JSON-like simple declarative descriptions of modules to build.

Soong is the replacement for the old Android make-based build system. It replaces Android.mk files with Android.bp files, which are JSON-like simple declarative descriptions of modules to build.

See https://android.googlesource.com/platform/build/soong/

82 questions
0
votes
1 answer

AOSP ERROR: Dex2oat failed to compile a boot image.It is likely that the boot classpath is inconsistent

I'm trying to build android 12. I was using Ubuntu 22.04.2 where it worked successfully. Now I've installed a fresh Ubuntu 22.04.3 which is using a new kernel and I started getting this error: ERROR: Dex2oat failed to compile a boot image.It is…
0
votes
0 answers

The Android.mk and the bp file exist in the same directory

The mk file and the bp file exist in the same directory. Which one will take effect? Which one will take effect? I want to konw which I should modify. I checked the Android official website, but I didn't find a clear answer.
SpongeBab
  • 3
  • 3
0
votes
1 answer

Add own module/library to AOSP in separate Android.bp file

I would like to build my own library during the AOSP build process and I'd like to be able to build the library with a stand-alone command, i.e., without building complete AOSP. I've put the source files of my library into a separate folder and…
lina_2299
  • 53
  • 4
0
votes
2 answers

Android.bp for a Android Studio Native C++ App

Could someone show me an example of Android.bp for the Android Studio Native C++ app to compile it in AOSP source? It can be for the 'hello world' auto generated project. Is there a tool that auto generates it? Thank you
0
votes
0 answers

Compile native app for aosp with debug_info in Android.bp

I wanna to debug an native app with lldb but the executable is not created with debug_info. My Android.bp: cc_binary { name: "native_algtest", vendor: true, srcs: [ "algorithms/algorithms.cpp", …
0
votes
1 answer

android_app_import corrupts APK

I'm trying to add some prebuilt apps to my AOSP built, using this blueprint: android_app_import { name: "App", apk: "App.apk", presigned: true, dex_preopt: { enabled: false, }, privileged: true, product_specific:…
artem
  • 16,382
  • 34
  • 113
  • 189
0
votes
2 answers

Repo sync fails with "repo is not tracking a remote branch"

When I try to run repo sync I get this error: info: A new version of repo is available warning: repo is not tracking a remote branch, so it will not receive updates repo reset: error: Entry 'git_superproject.py' not uptodate. Cannot merge. fatal:…
Top4o
  • 547
  • 6
  • 19
0
votes
0 answers

How to measure coverage of a libFuzzer fuzzer harness on Android Automotive X86_64 emulator?

I want to measure the code coverage of the libFuzzer fuzzer harness of the CAN hardware interface that comes with the AOSP, written in C++. I've attempted to use the Clang flags that allows that and generate a LLVM profile file, but the file is not…
0
votes
0 answers

How to skip the“ inject version” step when compiling adb from AOSP

I add "-g" option when compiling adb.exe for debug, but gdb said the symbol table in adb.exe not found, so I simply add these parameters in Android.bp to export the symbol table to pdb and then use windbg to debug it. @@ -487,7 +489,8 @@…
傅继晗
  • 927
  • 1
  • 8
  • 14
0
votes
0 answers

Soong build Error: this class can only be used as an annotation or as an argument to @UseExperimental

I am Using soong build system with kotlin and want to opt in for experimental APIs to be used in the code I have added @file:OptIn(kotlinx.coroutines.ExperimentalCoroutinesApi::class) in kotling file but upon compiling I get error stated as error:…
Pratik Patil
  • 101
  • 1
  • 5
0
votes
1 answer

How to include AIDL-generated headers in native code in AOSP?

I have a native module under /devices: - module -- aidl --- com ---- my ----- package ------ IMyInterface.aidl -- Android.mk -- Proxy.h -- Proxy.cpp I want to use binder in this module. My Android.mk: LOCAL_PATH := $(call my-dir) $(call…
artem
  • 16,382
  • 34
  • 113
  • 189
0
votes
0 answers

GaiException while resolving domain on AOSP platform app

I added an app to AOSP and it has the "platform" certificate. When I just install it on my device it resolves the domain just fine, but as a system app I get an GaiException: android_getaddrinfo failed: EAI_NODATA (No address associated with…
0
votes
1 answer

Package android.media.tv.tuner is not found in android.jar file

From this documentation We can see many "android.media.tv.tuner" package reference. From the SDK source code provided by SDK Manager (in AppData\Local\Android\Sdk\sources\android-30\android for example), this package is indeed present. But from the…
0
votes
0 answers

Unable to build Android 12 car target aosp_car_arm-userdebug

I can successfully build Android 12 Car for emulator using commands: source build/envsetup.sh lunch sdk_car_x86_64-userdebug m But I'm getting the error when try to build image for arm: source build/envsetup.sh lunch aosp_car_arm-userdebug…
Igor
  • 11
0
votes
0 answers

Implementing Android.bp for generating shared library

Consider the following files : abc.c #ifdef MY_FLAG #include int main() { printf("hello world\n"); } #endif Android.bp cc_defaults { name: "my_defaults_1", srcs: ["abc.c"], } cc_defaults { name: "my_defaults_2", …