1
0
mirror of https://review.coreboot.org/flashrom.git synced 2025-04-28 23:43:42 +02:00
flashrom/platform/meson.build
Thomas Heijligen b0aec45d8c meson: use platform/ as subdir()
Move build instructions for files inside the `platform/` directory to
`platform/meson.build`. This contains instructions to build
`memaccess.c`, the right endian implementation and selecting the right
legacy command line option for the endian.

The `platform/` directory should contain code that abstracts the
underlying platform but is not involved in flashrom logic.

Change-Id: I88044a3f903f316138483dd872a6d95f8686ae69
Signed-off-by: Thomas Heijligen <thomas.heijligen@secunet.com>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/63826
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Anastasia Klimchuk <aklm@chromium.org>
2022-05-12 08:52:40 +00:00

12 lines
309 B
Meson

srcs += files(
('endian_' + host_machine.endian() + '.c'),
'memaccess.c',
)
if host_machine.endian() == 'little'
add_project_arguments('-D__FLASHROM_LITTLE_ENDIAN__=1', language : 'c')
endif
if host_machine.endian() == 'big'
add_project_arguments('-D__FLASHROM_BIG_ENDIAN__=1', language : 'c')
endif