From de80e9337d812c47087ef568be2b3af2e1bbaf04 Mon Sep 17 00:00:00 2001 From: Anup Patel Date: Mon, 8 Aug 2022 09:33:14 +0530 Subject: Makefile: Compile lib/utils sources separately for each platform Currently, if same build directory is used to compile two different platforms then lib/utils objects are shared for these platforms. We will be having platform specific configs to enable/disable drivers in lib/utils and select compile time options for lib/utils sources. This means lib/utils sources will now be compiled in a platform specific way. To tackle above, we update top-level Makefile as follows: 1) Don't create libsbiutils.a anymore because this can't be shared between platforms. 2) Compile lib/utils sources separately for each platform. 3) Add comments showing which make rules are for lib/sbi, lib/utils, firmware, and platform sources. Signed-off-by: Anup Patel Tested-by: Andrew Jones Acked-by: Atish Patra Tested-by: Atish Patra --- scripts/create-binary-archive.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts') diff --git a/scripts/create-binary-archive.sh b/scripts/create-binary-archive.sh index 43c54523..261a45ad 100755 --- a/scripts/create-binary-archive.sh +++ b/scripts/create-binary-archive.sh @@ -118,7 +118,7 @@ build_opensbi() { # Build and install generic library echo "Build and install generic library XLEN=${BUILD_RISCV_XLEN}" echo "" - make -C "${BUILD_OPENSBI_SOURCE_PATH}" O="${BUILD_OUTPUT_PATH}/${BUILD_NAME}" I="${BUILD_OUTPUT_PATH}/${BUILD_ARCHIVE_NAME}" PLATFORM_RISCV_XLEN="${BUILD_RISCV_XLEN}" install_libsbi install_libsbiutils -j "${BUILD_NUM_THREADS}" + make -C "${BUILD_OPENSBI_SOURCE_PATH}" O="${BUILD_OUTPUT_PATH}/${BUILD_NAME}" I="${BUILD_OUTPUT_PATH}/${BUILD_ARCHIVE_NAME}" PLATFORM_RISCV_XLEN="${BUILD_RISCV_XLEN}" install_libsbi -j "${BUILD_NUM_THREADS}" echo "" # Build and install relevant platforms -- cgit v1.2.3