aboutsummaryrefslogtreecommitdiffstats
path: root/meson.build
diff options
context:
space:
mode:
authorThomas Heijligen <thomas.heijligen@secunet.com>2022-04-25 14:54:10 +0200
committerThomas Heijligen <src@posteo.de>2022-05-12 08:51:43 +0000
commitf5d33e26e030337364e84626fca1b9200b4dcff8 (patch)
tree604502e7af389db1f1a9475a0a790213fe9ca63a /meson.build
parentc287de2e09e7a80861b0cd93c2956be3a087eb4c (diff)
downloadflashrom-f5d33e26e030337364e84626fca1b9200b4dcff8.tar.gz
flashrom-f5d33e26e030337364e84626fca1b9200b4dcff8.tar.bz2
flashrom-f5d33e26e030337364e84626fca1b9200b4dcff8.zip
meson: relocate add_project_arguments() for IS_WINDOWS
Change-Id: I6afb65fabf858449f2706bf250588225a94c1871 Signed-off-by: Thomas Heijligen <thomas.heijligen@secunet.com> Reviewed-on: https://review.coreboot.org/c/flashrom/+/63827 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Edward O'Callaghan <quasisec@chromium.org> Reviewed-by: Peter Marheine <pmarheine@chromium.org> Reviewed-by: Anastasia Klimchuk <aklm@chromium.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build11
1 files changed, 5 insertions, 6 deletions
diff --git a/meson.build b/meson.build
index 6b088f06..56ff9706 100644
--- a/meson.build
+++ b/meson.build
@@ -36,12 +36,6 @@ add_project_arguments('-D_POSIX_C_SOURCE=200809L', language : 'c') # required fo
add_project_arguments('-D_BSD_SOURCE', language : 'c') # required for glibc < v2.19
add_project_arguments('-DFLASHROM_VERSION="' + meson.project_version() + '"', language : 'c')
-if host_machine.system() in ['cygwin', 'windows']
- add_project_arguments('-DIS_WINDOWS=1', language : 'c')
-else
- add_project_arguments('-DIS_WINDOWS=0', language : 'c')
-endif
-
# get defaults from configure
config_atahpt = get_option('config_atahpt')
config_atapromise = get_option('config_atapromise')
@@ -174,6 +168,11 @@ endif
if cc.check_header('sys/utsname.h')
add_project_arguments('-DHAVE_UTSNAME=1', language : 'c')
endif
+if host_machine.system() in ['cygwin', 'windows']
+ add_project_arguments('-DIS_WINDOWS=1', language : 'c')
+else
+ add_project_arguments('-DIS_WINDOWS=0', language : 'c')
+endif
srcs += 'platform/memaccess.c'