Makefile: Compile lib/utils sources separately for each platform
authorAnup Patel <apatel@ventanamicro.com>
Mon, 8 Aug 2022 04:03:14 +0000 (09:33 +0530)
committerAnup Patel <anup@brainfault.org>
Mon, 8 Aug 2022 04:03:14 +0000 (09:33 +0530)
commitde80e9337d812c47087ef568be2b3af2e1bbaf04
tree030a1a85817105402d45d628805cf5bf909225f3
parent662e631ccef2b20d7aba5d077ae0891f6b55ad2d
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 <apatel@ventanamicro.com>
Tested-by: Andrew Jones <ajones@ventanamicro.com>
Acked-by: Atish Patra <atishp@rivosinc.com>
Tested-by: Atish Patra <atishp@rivosinc.com>
Makefile
docs/library_usage.md
scripts/create-binary-archive.sh