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
1
vote
0 answers

How do we include Android.bp in vendor/manufacturer/device

I have created Android.bp in vendor/manufacturer/device/module/Android.bp Android.bp prebuilt_etc { name: "foo", src: "bar", vendor: true, } when I run mka foo ninja doesnt see the module but soong can find errors in the Android.bp…
Bret Joseph
  • 185
  • 8
1
vote
0 answers

How do I write an Android.bp for kernel modules?

I want to use cc_prebuilt_library_shared { name: "wlan", relative_install_path: "modules", target: { android_arm: { srcs: "lib/wlan.ko" } }, vendor: true } My concern is that when it's installed it…
Bret Joseph
  • 185
  • 8
1
vote
0 answers

Android Soong: How to depend on library within APEX

To have a shared library dependency, i need to include the following in my blueprint. cc_library_shared { name: "libdependent", shared_libs: [ "libsample" ], } To include the same library in an APEX image, I need to use the following…
Sway
  • 317
  • 1
  • 7
1
vote
0 answers

How to write Android.bp to support multiple build variants?

I am trying to maintain common code across devices. Few files needs to be modified based on device model. How can I write Android.bp to support multiple build variants based on device type(model)?
srbhakta
  • 75
  • 2
  • 5
1
vote
0 answers

How aosp build a aar file?

I want to build a aosp project(SystemUI) with Android studio. But it dependency some libs (e.g. SettingsLib), I know the settingslib is build by android_library. So how do build the settingsLib to a aar format file, then I can import it to android…
Jannicus
  • 11
  • 1
1
vote
1 answer

AOSP build failure using soong

I am trying to build an Android Open Source Project automotive image with a preinstalled system application using soong. The android system application is written in Kotlin. Android.bp android_app { name: "CarApp", srcs: ["src/**/*.kt",…
ah27
  • 11
  • 4
1
vote
0 answers

Should cc_tests in AOSP be on system or vendor?

What vendor settings should I apply to cc_tests? (vendor or system?) I noticed one of my cc_tests relied on libgcov which is only available on the system, which suggests to me that maybe tests are a system only thing. If my poor understanding of…
Matt
  • 1,928
  • 24
  • 44
1
vote
1 answer

How to copy specific headers in Soong

How can I extract specific files in Soong to use as headers? I was recently writing a blueprint (Android.bp) file for paho-mqtt-c. My consumers require MQTTClient.h which paho-mqtt-c stores in src/ - what I would consider a "private" location. …
Matt
  • 1,928
  • 24
  • 44
1
vote
1 answer

Android rebuilds static library when the binary is compiled

I have a binary in Android that links to a static library A. Static library libA depends on multiple shared libraries. The binary does not do anything except it imports a class from the static library and executes a simple function. However, the…
Moaaz Ali
  • 93
  • 15
1
vote
1 answer

Can not find file in android.bp

i build a so file in Android.bp,i use the "include_dirs" to find the ".h" file,but it can not find,here is my code codeA named A.bp cc_library_static {name :"liba" , static_libs:['libb']} codeB name B.bp cc_library_static {name…
tianyu
  • 119
  • 1
  • 10
1
vote
1 answer

How do I import a split_config.$arch.apk in Android.bp?

Android.bp android_app_import { name: "Wikipedia", apk: "Wikipedia.apk", dpi_variants: { xhdpi: { apk: "split_config.xhdpi.apk", }, }, arch_variants: { armeabi_v7a: { apk: "split_config.armeabi_v7a.apk", …
On Demand
  • 65
  • 5
1
vote
0 answers

Header file not found while using soong build Android.bp in AOSP

I am trying to build my HAL implementation and service using Android.bp Soong build. Even though the build process is successful with Android.mk, after converting this Android.mk file into Android.bp, the build process is failed with the error as…
hugtech
  • 877
  • 3
  • 11
  • 16
1
vote
1 answer

Erro: unrecognized module type android_app_import. when building AOSP 10 r20+

Just started to build AOSP, for my Redmi Note 6 Pro Got error "android_app_import" unrecognized module type My PC (Arch Linux) uname --all Linux DEdSeC-PC 5.4.6-arch3-1 #1 SMP PREEMPT Tue, 24 Dec 2019 04:36:53 +0000 x86_64 GNU/Linux Sources Device…
1
vote
1 answer

how to make Soong and Kati translate ninja rules in parallel?

Android build system has Soong and Kati where: Soong translates .bp file to .ninja files Kati translates .mk files to .ninja files When profiling the AOSP build time with soong_ui, I saw these translation processes occurred sequentially which I…
Chen Xie
  • 3,849
  • 8
  • 27
  • 46
1
vote
1 answer

What does CC means in Soong?

There are a lot of references to cc in AOSP Soong. In this file, for example: https://android.googlesource.com/platform/build/soong/+/master/cc/cc.go I have several hypothesis: Compiler Collection (as in gcc) Cross Compiler C, C++ C compiler (as…
Hugo y
  • 1,421
  • 10
  • 20