Age | Commit message (Collapse) | Author |
|
This removes the flag for fast builds and generally enables pigz
in place of gzip.
Bug: 243389125
Bug: 315488400
Change-Id: I5de045f68b607befee17997c12621455379d1c8e
Signed-off-by: Matthias Maennich <maennich@google.com>
|
|
Currently, both arm64 and x86_64 kernel prebuilts belong to the same git
project. This means that the commit message for the second path has
confusing empty gitlog inside (see aosp/3018344 and aosp/3018343 for
example).
This patch fixes the issue by committing the prebuilt only once. You can
check aosp/3053322 and an example output of the script.
Bug: 291071984
Test: ./build/kernel/gki/download_from_gki --update-microdroid
Change-Id: Iad1e37d9061fba259e28e264c3cdd4788c41f07f
|
|
Describe in more detail what each flag means. This also
updates bazel help kleaf.
Test: bazel help kleaf
Change-Id: I367464aa23328f39c6f03170ccbac816e4fcb3ee
|
|
* This change introduces a new function to download files, by
contstructing a valid URL using information like build_id,
build_target and remote_filename.
* Due to hermeticity reasons, the python toolchain lacks valid
certificates to verify the downloads, for that reason, the downloads
rely on the host toolchain just for these.
* To avoid spam during these calls, and in case of any error only the
last line of the stacktrace is printed in case of any exception.
Bug: 328770706
Change-Id: I80fb8867a6d009043d0d2bb376bf0c2557774e17
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
Those patches are regularly violating the code style but not much can be
done about that.
Suggested-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I7a0bfc81895ed69bc3aad91d78cb74cd9977f852
Signed-off-by: Matthias Maennich <maennich@google.com>
|
|
Instead of creating a file that has all of
module_outs and module_implicit_outs, pass
the list directly everywhere. kernel_build
also pass the list to kernel_filegroup directly.
This makes the representation of kernel_filegroup
more straightforward to follow.
Test: TH
Bug: 332386858
Change-Id: I97a67e8ee5f343fe045b79a2016a34436c32621b
|
|
This is now deprecated and replaced by --strip_execroot.
Change-Id: I67c22d948d43cff1c72f02aee5d6567edd4c2ac9
Signed-off-by: Matthias Männich <maennich@google.com>
|
|
Import re globally.
Test: TH
Bug: N/A
Change-Id: Ifc7ab2c2922e5e1c0fc97a1aab25a8b11c6fa77e
|
|
Do not attach any --bazelrc flags when running
tools/bazel --help.
Add back integration test now that the issue in
Bazel about JDK_JAVA_OPTIONS is fixed.
Bug: 293357796
Test: TH
Change-Id: Ib65c245ecda54d1fa1c655f3dc365407570d73ec
|
|
* This is the mechanism which will make various use cases possible.
* It will be used in next changes.
Bug: 328770706
Change-Id: Ia130fb2077376a90c890037565c5936ab7d50116
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
* This is a no-op refactor.
Bug: 328770706
Change-Id: I1adb7cd4ba46f21204a163df2102f5fe02b0ece9
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
* This changes adds testing for:
* Directory creation correctly handled.
* Correct symlink of tools/bazel.
* Prebuilts setup for both relative to workspace or not.
* Little cleanup of the now obsolete create_directory class method.
Bug: 328770706
Change-Id: Ic4d5c43128f1b9a5919fc7ace1d8abd13fccb48d
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
Running with --no-tree prevents spdxcheck.py from being run and
generating an error.
Bug: 199237323
Bug: 327484174
Test: Verified no errors are encountered when running
checkpatch_presubmit on a patch with a SPDX header.
Change-Id: I7e19f400598650f260a2721f76106bd7d31e8262
Signed-off-by: Erik Staats <estaats@google.com>
|
|
* Indicating when a file is created or just updated.
Bug: 328770706
Change-Id: I8cb000373f5c2cd26dc32b51d8073cd50b9fc949
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
* `--kleaf_repo_dir` -> `--kleaf_repo`
* This is to make it consistent with init.py bootstrap script, but also
because it is easier to remember this way.
Bug: 328770706
Change-Id: I8530627699754fbf0f5561c42e4cb62e69591df6
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
* This refactors the `run` method to handle setup pieces individually,
which should make following modifications localized and easier to follow.
Bug: 328770706
Change-Id: I4c6817b5153aab046ed1698dcbd883cf365a5f1e
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
* This is for already downloaded prebuilts, next step is to add support
to download the prebuilts given a build_id.
Tested: python3 init.py --prebuilts_dir=relative/to/ddk_ws \
--local --kleaf_repo=/abs/path/to/ack
Bug: 328770706
Change-Id: I2091c39aa8f57e0efae760fb04641387680845c3
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
* This is to avoid confusion of which paths need to be relative or
absolute.
Bug: 328770706
Change-Id: Ia0d6acf4adac694f09912b219c09c94be2d8542b
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
... by removing the toolchain version file.
Instead of passing a file that contains the
toolchain version to kernel_filegroup,
just pass the toolchain version to the platforms
that kernel_filegroup takes, similar to how we
pass toolchain version to the intenral
_kernel_build() rule. kernel_filegroup infers
the toolchain version from the resolved toolchain
like kernel_env() does.
This simplifies KernelToolchainInfo and
therefore the checking code in kernel_build.
Note: This change forces kernel_filegroup_declaration
to declare a kernel_filegroup that always uses the
versioned toolchain so it is more explicit, even
if the original kernel_build uses the default toolchain.
Test: manual
Bug: 332386858
Change-Id: I1b0928015b2d1bf045fe76cc7e5b20254cd3d0a2
|
|
This was added to support
_kernel_extract_symbols.gki_modules_list_kernel_build
b81a656f616bd8af89e14783be79d44ea2f2d169
("kleaf: extract_symbols add --gki-modules."),
but it was dropped in
d5311b5ee6d222ec9567129b22b697728bcb221e
("Remove the GKI_MODULES_LIST flag and references"),
and no longer used since then.
Bug: 332386858
Change-Id: Ib92a435aaacb5569d920ab493debbdb466af369f
|
|
The name is fully_static_link, not full_static_link.
Test: build then readelf
Bug: 325514706
Change-Id: I3698f4efcf334b293c2c3d0f4642a58e493e2bb3
|
|
* This is a DDK artifact needed to list required files to download.
Bug: 328770706
Change-Id: Id0ab9ce8c9eb955fb9f490dc3307b6af582c6e81
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
Files don't prefix with colons; targets do.
So delete the colon.
Test: TH
Change-Id: I4899328eb2a06f2f6a1851d643a493d271f27550
|
|
Change-Id: If937ea4d5e624fb9961c42afb3090e76d3a9b274
|
|
Instead of using signed/certified-boot-img-<BUILD_NUMBER>.tar.gz
in the local prebuilt directory, always use signed/boot-img.tar.gz.
This avoids the need of specifying a build number in the
--local case in DDKv2.
Test: manually build trusty module against local prebuilts
Bug: 291918087
Fixes: 0dd77d200146327231f43cdd821a4ca8a65d7a1c
("kleaf: kernel_prebuilt_repo fix remote_filename formatting.")
Change-Id: I7a86578c98c276652f3c0b4bd6ca9bcb44c7d039
|
|
This fixes the following error when `auto_download_config` is set:
```
ERROR: <builtin>: fetching kernel_prebuilt_repo rule //:kleaf~~kernel_prebuilt_ext~gki_prebuilts: Traceback (most recent call last):
File ".../kleaf/impl/kernel_prebuilt_repo.bzl", line 168, column 35, in _kernel_prebuilt_repo_impl
download_configs = json.decode(repository_ctx.attr.download_configs)
Error in decode: at offset 0, unexpected end of file
```
Fixes: f389785c30ad ("kleaf: [REFACTOR] Clean up kernel_prebuilt_repo (merge)")
Bug: 291918087
Change-Id: Ibee2d7bd9d132522c5bf5f17999423171bb59630
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
* It fixes the error:
```
...kleaf/impl/declare_kernel_prebuilts.bzl", line 87, column 39, in _declare_repos
mandatory = module_tag.mandatory,
Error: unknown attribute mandatory
```
Fixes: f389785c30ad ("kleaf: [REFACTOR] Clean up kernel_prebuilt_repo (merge)")
Bug: 291918087
Change-Id: I816891ddc009c12e975856aa6f0a9eea34dbd09c
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
This reverts commit 73b75b2f0c16cb0dbb6f038e721128455e1c2c4f.
Now that WORKSPACE is almost going away, in the
bzlmod framework, prebuilts are handled with
declare_kernel_prebuilts(), where the repo name
is less important. So revert the change (logically)
so it is keyed on target names again.
Change-Id: Ia65ea604f017a6bb574de5d9b93bceb38c9c1edd
|
|
Just use the download_configs dictionary directly.
This is a step towards eradicating auto_download_config;
it should be provided by the build.
Test: TH
Bug: 291918087
Change-Id: I02a278b5f29c2fafb0142cd02afd0950e2a6fd8e
|
|
Clean up its API by merging mandatory and download_config
into a single download_configs string_dict that takes
a JSON string as its value.
Test: TH
Bug: 291918087
Change-Id: I5904ddac1676b34c9f13be4e3a9d690c46e7f4e9
|
|
Restructure download_configs so it is keyed on local
filename. This allows further cleanup on the API
of kernel_prebuilt_repo.
Test: TH
Bug: 291918087
Change-Id: Ibe75d3e325e1d419b20aba68401caffe2084b0a5
|
|
Move CI_TARGET_MAPPING.<repo_name>.gki_prebuilts_outs
into download_configs for better generalization.
Test: TH
Bug: 291918087
Change-Id: Ibc2298336e337aea3274579521ae6bda6983a36b
|
|
Move CI_TARGET_MAPPING.<repo_name>.protected_modules
into download_configs for better generalization.
Test: TH
Bug: 291918087
Change-Id: I2289212425fa269a1fc36da2937edf95214e15a1
|
|
Move CI_TARGET_MAPPING.<repo_name>.outs into download_configs
for better generalization.
Test: TH
Bug: 291918087
Change-Id: I22a91221f076e898fb85329a526176b378b32ad8
|
|
Drop outs and use outs_mapping everywhere. This
removes branching in code.
Always specifies mandatory so it is more explicit.
Bug: 291918087
Change-Id: I40ccc7be3a32b7b01f86dbccb12724448ddeaf25
|
|
Merge GKI_DOWNLOAD_CONFIGS into CI_TARGET_MAPPING.
This makes it clear that GKI_DOWNLOAD_CONFIGS are currently
only serving kernel_aarch64.
Bug: 291918087
Change-Id: I42ceae88e7d1911d75f7a121633d35416548f762
|
|
In old WORKSPACE setup, --use_prebuilt_gki
lets Kleaf downloads the prebuilts. Use
parallel download in Bazel 7.1.0 to speed
up.
Bug: 291918087
Change-Id: I3ab495b981ff5d6d24c2f09d7eb1651bbbeb1bb2
|
|
In old WORKSPACE set up, the build_number
may come from --use_prebuilt_gki that
sets the environment variable. Format
remote_filename properly in this case.
Bug: 291918087
Change-Id: Idf7587ca3c66d1663248c2c309bfbeb394151825
|
|
Attempt to set CONFIG_UNUSED_KSYMS_WHITELIST regardless
of the value in CONFIG_TRIM_UNUSED_KSYMS. The dependency
of UNUSED_KSYMS_WHITELIST on TRIM_UNUSED_KSYMS should
be opaque to Kleaf.
Test: manual
Bug: 275648361
Change-Id: I71f81050545e19b4c4bcf4e621eb396e1750de3a
|
|
Just like --make_jobs, --make_keep_going is a flag
that should not affect outputs nor triggers rebuilds.
Hence its value is placed in ctx.version_file.
Test: manually check with --debug_annotate_scripts
that MAKEFLAGS is set.
Bug: 333490909
Change-Id: If01e3136abcffca777bcf511e07b0828fdd3ada4
|
|
* The script creates the minimal file with just two configurations:
1. Enabling internet.
1. Pointing Bazel to the local registry.
* It adds initial unit testing.
Bug: 328770706
Change-Id: Iac86e4bf19339dd74f3fc8da3deb497255690c99
Signed-off-by: Ulises Mendez Martinez <umendez@google.com>
|
|
Since kernel_image() only supports the dtbo create command, it is
difficult to set up multiple dtbo configurations. This change adds
cfg_create command support when kernel_images.dtbo_config is set
Bug: 332416333
Signed-off-by: Junki Min <joonki.min@samsung.com>
Change-Id: I72eca9bbd90017d4788024da30ff66e381ff8ef8
|
|
If the two attributes are specified, downstream
targets of kernel_config should depend on the
two files in case they changes.
Test: TH
Change-Id: I1441148de162c5c9844eddf4a1bec2757f408d6c
|
|
exec, exec_test and exec_rule from
//build/bazel_common_rules/exec is marked
deprecated to prevent usage outside of _kernel_abi_dist_exec,
hermetic_exec, and hermetic_exec_test.
Let _kernel_abi_dist_exec uses the internal exec_rule
to suppress the deprecation message.
Test: TH
Bug: 329305827
Change-Id: I04858afdaee42b609ce70709e4ac802ea83c60f5
|
|
If CONFIG_* changes, with --config=local,
extract-ikconfig vmlinux must contain the
same change.
Test: TH
Bug: 312268956
Change-Id: I9064ef4bc51b01ed9953b5ed4ae99bcb5bee8719
|
|
Test: TH
Bug: 324907235
Change-Id: Ifa1a0ba50c33bed7b5e6b8c2dc41f6ce58070ead
|
|
This reverts commit 12dbebe658eff74270609c31de164de9eaee257f.
Reason for revert: breaks Pixel builds because module sizes increases, which won't fit in ramdisks.
Bug: 297608514
Change-Id: Ic2da57069faf449f4816f8ca54b14ca76cdd1b1e
|
|
Test: TH
Bug: 293260835
Change-Id: Ic973b0b8a0899477265967229cbdebdbf35859f1
|
|
If --debug is set, the kernel_build.strip_modules
attribute is ignored and modules will never be stripped.
Test: TH
Test: bazel test //build/kernel/kleaf/tests/kernel_build_test:kernel_build_strip_modules_test
Bug: 297608514
Change-Id: Ia119e810c6c0e73983a93d224f01ff4bbc3572c1
|
|
Properly wrap labels with Label().
Test: TH
Bug: 293260835
Change-Id: I860fcd04a1b83ef248eac82a3f1f366af73abbb7
|