Commit Graph

74 Commits

Author SHA1 Message Date
qinglin.li fcce176707 scripts: use additional_kmi_symbol_lists add symboi [1/1]
PD#SWPL-180503

Problem:
add symbol not modify android/abi_gki_aarch64_amlogic file

Solution:
use additional_kmi_symbol_lists add symbol

Verify:
local

Change-Id: I992ce14f3511e1203b32ac3c4ffa07be1a3009ed
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2024-08-07 21:49:18 -07:00
qinglin.li eefcce1d57 scripts: support customer dir dts [1/1]
PD#OTT-62864

Problem:
support customer dir dts

Solution:
support customer dir dts

Verify:
local

Change-Id: Ic09d7eb113df5a9735a2d8f0732544f3adec9730
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2024-07-25 06:07:44 -07:00
Qinglin Li 7b2ea218b7 yocto needs to be compatible with the previous kernel version 5.4, and is assigned to the amlogic directory by default.
Revert "scripts: support customer dir dts [1/1]"

This reverts commit 435a1dbfda.

Change-Id: I79ac10b4918cd94dbdc307662e5481915f7fa8d1
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2024-07-24 02:07:56 -07:00
qinglin.li 435a1dbfda scripts: support customer dir dts [1/1]
PD#OTT-62864

Problem:
support customer dir dts

Solution:
support customer dir dts

Verify:
local

Change-Id: I83ca376102fbcba3aeaad328cfe7a943173d15f8
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2024-07-23 06:06:01 -07:00
Wanwei Jiang c32c643171 build: optimize android build time [1/1]
PD#SWPL-172042

Problem:
optimize android build time

Solution:
1. further optimization based on mk.sh fast build mode
2. enable build system_dlkm image

Verify:
local

Change-Id: I121bac2d05d5929147fde9c2c86024af2db2b13b
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2024-07-22 20:11:52 -07:00
qinglin.li 71c0eed79d scripts: optimize build time [1/1]
PD#SWPL-172042

Problem:
optimize autopatch run time

Solution:
autopatch Asynchronous loading based on directory.
Fetch git information only once, based on directory.
mod_probe function use array instead of file can save time

Verify:
local

Change-Id: Ica47d23a867ce1aa5b534d7bfa0a85db33a37f5f
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2024-07-22 20:11:47 -07:00
Wanwei Jiang ea102c00ab build: optimize fatload build speed [1/1]
PD#SWPL-172042

Problem:
optimize fatload build speed

Solution:
1. use --lto=none
2. use --notrim
3. use --nokmi_symbol_list_strict_mode
4. reduce unnecessary constructions, such as system_dlkm and initramfs
5. modules, modules.dep and other files are copied from intermediate files

Verify:
local

Change-Id: Idb5c57a9a6ab357351341efb93fb6a79aeca5d0c
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2024-07-22 20:11:43 -07:00
Dezhen Wang f228de583d Scripts: android T build system_dlkm.img [1/1]
PD#SWPL-175594

Problem:
android T should sync with android u for function of
replace gki product and should build system_dlkm.img

Solution:
build system_dlkm.img

Verify:
sc2

Change-Id: I868c86ecefcd237e9ddfcc5b5ffa1c2e23cc8008
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2024-07-19 01:59:44 -07:00
Dezhen Wang c7e8fdac79 scripts: support building command SKIP_RM_OUTDIR=1 for smarthome [1/1]
PD#SWPL-161245

Problem:
building command SKIP_RM_OUTDIR=1 will fail because last build remain
the staging dir

Solution:
remove staging dir in last build

Verify:
local

Change-Id: I057b5d33def309197b43627ff88976a86580ce4a
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2024-03-20 22:33:32 -07:00
Dezhen Wang 3f17b46e37 scripts: fix build error when compress with lzma [1/1]
PD#SWPL-129222

Problem:
some services will lead to build error when compress with lzma

Solution:
not set specified name

Verify:
local

Change-Id: I6ad2e765f50c40279b0e9d24667b573d54efe0f2
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-12-28 04:49:16 -07:00
Dezhen Wang 0ac8a6ac70 Script: support build kernel image in lzma format [1/1]
PD#SWPL-129222

Problem:
there is no dts for ac214 to bringup Newton gpt on kernel 5.15 + uboot 2015
we need the dts for ac214 first

Solution:
support build kernel image and boot.img in lzma format

Verify:
local

Change-Id: I60b6bd9b974abe3114ba3ad557013963c122b3b3
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-12-13 22:59:12 -07:00
Wanwei Jiang 10a025346b script: close ko build [1/1]
PD#SWPL-142586

Problem:
failed to insmod closed ko in gki project

Solution:
remove lto=none

Verify:
ohm

Change-Id: Iac7c9d6325c475f09f3b3483b7a8c6afa546a01e
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-10-22 20:04:24 -07:00
Wanwei Jiang 19f88f5099 patch: tidying up patches related to the build environment [1/1]
PD#SWPL-137860

Problem:
tidying up patches related to the build environment

Solution:
1. merge patches
2. delete unused patches

Verify:
ohm

Change-Id: Ie441c4e54a83cb12734d477af7de84153dc05e90
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-09-04 07:53:35 -07:00
qinglin.li feb92b24d6 module: add modules out add and remove function [1/2]
PD#SWPL-134106

Problem:
add modules out add and remove function

Solution:
add modules out add and remove function

Verify:
local

Change-Id: I836b63a2074b9bc480627da690d9c4240104e729
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2023-08-29 03:59:05 -07:00
Dezhen Wang ad3fffe07e scripts: separate the code for building android 32bit from 64bit [1/1]
PD#SWPL-134884

Problem:
the script is not clear

Solution:
separate the code for building android 32bit from 64bit.

Verify:
local

Change-Id: I116fd122061abf059f0134c94c09198f822b5c0a
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-08-25 20:03:35 -07:00
Qinglin Li 8c3c51983b Revert "modules: remove modules out list [1/2]"
This reverts commit 6ea7d6e204.

Change-Id: Id5ffc6e06cdb384ed31f3d3f9dfb43e02014d1da
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2023-08-10 21:48:59 -07:00
qinglin.li 6ea7d6e204 modules: remove modules out list [1/2]
PD#SWPL-134106

Problem:
remove modules out list

Solution:
remove modules out list

Verify:
local

Change-Id: I6d4d13b6779d73133367735aee08814d5dbfb1a6
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2023-08-09 02:58:55 -07:00
Wanwei Jiang 7c582c0027 customer: support customized modules loading sequence [1/3]
PD#SWPL-132930

Problem:
support customized modules loading sequence

Solution:
1. priority of module loading order files:
${MODULES_SEQUENCE_LIST} > scripts/amlogic/modules_sequence_list
2. solving the problem of bazel output directory
3. export GKI_MODULES_LIST

Verify:
ohm planck

Change-Id: I31951289377e880017fd49b245641c14e001ffe3
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-07-27 23:05:10 -07:00
Wanwei Jiang 0bde312111 customer: support for external driver kconfig [1/3]
PD#SWPL-132650

Problem:
support for external driver kconfig

Solution:
support for external driver kconfig

Verify:
ohm planck

Change-Id: Ib7180059b02ee7c4d8984201bfe192d961680bad
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-07-24 05:08:37 -07:00
qinglin.li 7cf37c0d62 kasan: bazel add kasan support [1/2]
PD#SWPL-128976

Problem:
bazel add kasan support

Solution:
add --kasan support

Verify:
local

Change-Id: I493e17ba66fd79a36b53c57bdcee7a7c52711f67
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2023-07-17 21:06:48 -07:00
qinglin.li 62b23335d8 bazel: support some build command --upgrade [1/2]
PD#SWPL-127872

Problem:
support some build command --upgrade

Solution:
support some build command --upgrade

Verify:
5.15

Change-Id: Ic5f90990d14b40bc1408c88d12f15b86622261c0
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2023-07-14 03:28:39 -07:00
Wanwei Jiang e542675e9e android: support gki2.0 gki1.0 and nonGKI [1/1]
PD#SWPL-130287

Problem:
support gki2.0 gki1.0 and nonGKI

Solution:
support gki2.0 gki1.0 and nonGKI

Verify:
ohm

Change-Id: I1529b253f58c814979fa48de4cf960b34b1aff16
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-07-05 22:45:20 -07:00
Wanwei Jiang 0a519f6984 build: support --use_prebuilt_gki [1/1]
PD#SWPL-130219

Problem:
support --use_prebuilt_gki

Solution:
support --use_prebuilt_gki

Verify:
local

Change-Id: I32515737f5663b798f23ee2c69ce4b766ee1c5e6
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-07-04 07:07:56 -07:00
Dezhen Wang 1176fad163 Script: support build 32bit android kernel without build.sh [1/1]
PD#SWPL-126348

Problem:
build.sh file will remove in the future kernel version. we can not use
it to build with 32bit

Solution:
support build 32bit android kernel with clang of gcc

Verify:
local

Change-Id: I0774fc57aaac2555b8ddc99c74997204ba6763a9
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-06-30 01:50:48 -07:00
Wanwei Jiang cd1d91220d script: support google kernel build [3/3]
PD#SWPL-128563

Problem:
use tools/bazel to build

Solution:
support google kernel build

Verify:
adt4

Change-Id: I9be912bf1eb54503ca5ba4819e4504415cd2c56a
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-06-27 21:39:35 -07:00
pengzhao.liu a923dea38d kernel: Remove Makefile autoreview script [1/2]
PD#SWPL-128588

Problem:
Cannot copy files when compiling

Solution:
Remove Makefile autoreview script

Verify:
no

Change-Id: Icdbe276ef2a5c2aefe0173c0b8457c09a3b40e4b
Signed-off-by: pengzhao.liu <pengzhao.liu@amlogic.com>
2023-06-27 01:17:25 -07:00
Dezhen Wang 2006929590 Script: fix force to buld upgrade project with build.sh [2/2]
PD#SWPL-128334

Problem:
android upgrade project cannot build kernel14 with bazel

Solution:
build android upgrade project with build.sh

Verify:
local

Change-Id: Iec4f1b3c48bcea5ef866c0bdf57417bc4d1a9098
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-06-21 01:09:44 -07:00
Dezhen Wang 556827e6aa Script: optimize auto patch function [1/1]
PD#SWPL-124723

Problem:
auto patch function cannot excute in up directory

Solution:
support auto patch function in android directory

Verify:
local

Change-Id: I6bb53b5f53dc6604dbf07c9e819b68cc8a3b071d
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-06-20 03:39:36 -07:00
Dezhen Wang 0a44bf11ce Script: force to build upgrade project with build.sh [1/1]
PD#SWPL-128334

Problem:
android upgrade project cannot build kernel14 with bazel

Solution:
build android upgrade project with build.sh

Verify:
local

Change-Id: I6bb476a8890f49fe2e19931ec506e6aabbb4240a
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-06-19 21:19:28 -07:00
Dezhen Wang 850c0d2b01 Script: optimize the structure for build script [1/1]
PD#SWPL-124723

Problem:
build script mk.sh is too redundant

Solution:
optimize the structure for mk.sh and extract some command to functions in
amlogic_utils.sh

Verify:
local

Change-Id: If5c5ecfc651013169922d65128ffec88347d3ad2
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-06-07 05:18:27 -07:00
Wanwei Jiang afbfb1ad70 build: simplify compilation commands [1/2]
PD#SWPL-126432

Problem:
simplify compilation commands
./mk ohm -v common14-5.15 --sp --gki_20 --bazel
./mk oppen -v common14-5.15 --sp --gki_20 --bazel
modify to:
./mk ohm -v common14-5.15
./mk oppen -v common14-5.15

Solution:
1. --gki_20: set in the project configuration file as GKI_CONFIG=gki_20
2. --bazel: set the default value for compiling tools according to kernel

Verify:
ohm adt4 oppen

Change-Id: If3474af9b8e2dd5fb2ec0b05248387a6ad5ac81f
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-06-01 21:38:55 -07:00
Wanwei Jiang 8d1a00f53e patch: support auto lunch's patch [1/3]
PD#SWPL-124735

Problem:
the execution time of the lunch is too long for patching all kernel patches

Solution:
patching the necessary patches to avoid android compilation failure

Verify:
ohm

Change-Id: I917ec47716336cb4c896bce4aeed3229e069c3dc
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-05-31 20:54:14 -07:00
Dezhen Wang 061c478f68 Configs: add new config for android s with kernel 5.15 [1/1]
PD#SWPL-124507

Problem:
android s with kernel 5.15 have not config.

Solution:
add new config for android s with kernel 5.15

Verify:
local

Change-Id: I191ecd9724d4fc9f983d31728685ed7112cf5482
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-05-25 04:08:13 -07:00
Wanwei Jiang 92c8943985 bazel: optimize and add some function [1/2]
PD#SWPL-123803

Problem:
optimize and add some function

Solution:
1. support update symbol list
2. support abi check
3. remove db845c information
4. optimize modules_out
5. rename symbol list file name

Verify:
sc2

Change-Id: Ia816fa87ebb6047c5bf3722c613c5545d4367a9d
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-05-23 01:42:23 -07:00
qinglin.li bce5471ebe upgrade: android P upgrade [1/1]
PD#SWPL-122569

Problem:
android not vendor boot

Solution:
builtin all vendor boot modules

Verify:
local

Change-Id: I40b3a29e4cc7e3510193df91bd7af326bb999dad
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2023-05-16 03:01:29 -07:00
Dezhen Wang 7a4a7a9d50 scripts: detect the kernel version automatically in build [1/1]
PD#SWPL-121365

Problem:
build parameters is too much

Solution:
detect the kernel version automatically in build.config.constants

Verify:
local

Change-Id: Ia29f10ead028f858809bb250511fe6d601a2ee59
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-05-14 20:42:16 -07:00
Dezhen Wang a5f456a433 Script: add a new config for customer to configure android project [1/1]
PD#SWPL-123455

Problem:
customer wants to add a new config used by themself

Solution:
add a option to add new config for android project

Verify:
local

Change-Id: I2dbf851c4324e3e43e51f87a40132362ac5c3fda
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-05-12 00:37:38 -07:00
Wanwei Jiang 0df84603dc bazel: support for bazel build in the new kernel [1/1]
PD#SWPL-122095

Problem:
unable to use bazel build in the new kernel

Solution:
support for bazel build in the new kernel

Verify:
local

Change-Id: I6ee258cc46c839e000c6cc35769fa8104b14436c
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-05-09 09:30:04 -07:00
Dezhen Wang 5ad119c8e8 Script: organize the content of the mk.sh and amlogic_utils.sh [1/1]
PD#SWPL-119384

Problem:
original content is too redundant

Solution:
put some function from mk.sh to amlogic_utils.sh

Verify:
local

Change-Id: I4e464d22dce5afef4f927e1bcdd7d6313fb17b4f
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-05-06 01:00:43 -07:00
qinglin.li 5689a477f2 script: fix arm32 build failed [1/3]
PD#SWPL-116256

Problem:
planck arm32 build failed

Solution:
fix arm32 build failed

Verify:
planck

Change-Id: I49ee036eb8507dd7eb58ba08b511aa4521b19820
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2023-04-28 01:41:37 -07:00
qinglin.li d2edad5ad2 upgrade: upgrade tool [1/1]
PD#SWPL-118733

Problem:
1. build.sh and build_abi.sh remove
2. Andorid.bp redefined

Solution:
revert remove patch
rename Andorid.bp to Andorid_bp

Verify:
loacl

Change-Id: I980c5d0e066ad057f12cb8ef6d27849992946abe
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2023-04-27 14:46:25 -07:00
Wanwei Jiang 2218b8950a bazel: support use bazel tool to build [2/6]
PD#SWPL-112151

Problem:
support use bazel tool to build

Solution:
1. support use bazel tool to build for gki2.0 and gki1.0
2. amlogic.bzl(build parameter), amlogic_utils.bzl(build function)
3. change define_db845c to define_common_amlogic
4. support build external modules
5. support build dtbo
6. use project config
7. rename external(out tree) modules name

Verify:
sc2

Change-Id: If644ea18c21624fd9ad8695b5a866ce593a11b7f
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-04-24 21:16:29 -07:00
Dezhen Wang d40fa552df script: add function detect the symbol_list to submit [1/1]
PD#SWPL-118657

Problem:
there are some abi symbols in common driver which should be submitted
to google

Solution:
add the function to detect the abi symbol list

Verify:
local

Change-Id: I6bd85d146e1961d3c654b2ee6d6cb6a0e13a7a97
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-04-13 02:17:45 -07:00
Wanwei Jiang c65e4d3440 build: support gki build for common14 with build.sh [1/2]
PD#SWPL-116256

Problem:
support gki build for common14 with build.sh

Solution:
1. gki1.0 build, once build out the boot.img, system_dlkm.img,
and modules which in the vendor_boot.img and vendor_dlkm.img.
2. gki2.0 build, once build out the boot.img and system_dlkm.img
with build.config.gki.aarch64, second build out modules which
in the vendor_boot.img and vendor_dlkm.img
3. use SYSTEM_DLKM_PROPS to add selinux label for system_dlkm.img
4. add android/abi_gki_aarch64_amlogic.external include gki symbol
which used to vendor modules, kernel/Makefile add when once build

Verify:
local

Change-Id: Ib6774641f54a1dbf17083ce441604292f0652487
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-04-12 20:19:35 -07:00
Dezhen Wang ab7ba647aa Script: add a new config for customer to configure the kernel [1/1]
PD#SWPL-13204

Problem:
customer wants to add a new config used by themself

Solution:
add a option to add new config

Verify:
local

Change-Id: I3f7f0e2c8d781a9865bef16aca709db5d3372d6e
Signed-off-by: Dezhen Wang <dezhen.wang@amlogic.com>
2023-03-22 14:10:56 -07:00
Wanwei Jiang 9bf7840a51 script: check defconfig [1/1]
PD#SWPL-96062

Problem:
./mk.sh --check_defconfig fail

Solution:
references check_defconfig function in _setup_env.sh to implement this function

Verify:
arm and arm64

Change-Id: I2422c25d46faf896b0e157f2fa58de10cefc4b7a
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-03-06 01:41:35 -08:00
Wanwei Jiang 19d6cc0c8c auto_patch: change directory [1/1]
PD#SWPL-109858

Problem:
change auto_patch directory from common to auto_patch

Solution:
change auto_patch directory from common to auto_patch

Verify:
sc2

Change-Id: I5539fcae1f8edfe4c145b5c4fdebc23e79f6cf62
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-03-02 22:25:24 -08:00
qinglin.li 8d41aaf6f1 gki_20: modify break gki_20 [3/3]
PD#SWPL-101048

Problem:
add gki 2.0 check kernel build parameter

Solution:
add gki 2.0 check kernel build parameter

Verify:
local

Change-Id: I6f718c36848f39801f6eb9ec43212fbca706d986
Signed-off-by: qinglin.li <qinglin.li@amlogic.com>
2023-02-28 06:10:50 -08:00
Wanwei Jiang 0c2b2004db auto_patch: bring up androidu with common14-5.15 [1/1]
PD#SWPL-109858

Problem:
support auto patch

Solution:
modify scripts to support auto patch

Verify:
sc2

Change-Id: Ibb247019844dcbdcd3311af6e640ff637061c8c2
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-02-23 05:46:02 -08:00
Wanwei Jiang e9412eceb6 auto_patch: bring up androidu with common14-5.15 [2/3]
PD#SWPL-109858

Problem:
support auto patch

Solution:
modify scripts to support auto patch

Verify:
sc2

Change-Id: If99091e1a24bb36f58415b228d8b302087c21d09
Signed-off-by: Wanwei Jiang <wanwei.jiang@amlogic.com>
2023-02-12 22:40:26 +08:00