All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tyler Retzlaff <roretzla@linux.microsoft.com>
To: dev@dpdk.org
Cc: bruce.richardson@intel.com,
	Tyler Retzlaff <roretzla@linux.microsoft.com>
Subject: [PATCH v2 2/3] build: determine execution environment at config time
Date: Thu, 26 Jan 2023 10:03:23 -0800	[thread overview]
Message-ID: <1674756204-25965-3-git-send-email-roretzla@linux.microsoft.com> (raw)
In-Reply-To: <1674756204-25965-1-git-send-email-roretzla@linux.microsoft.com>

Move execution environment determination and definitions to config. The
RTE_EXEC_ENV macros are actually used by libraries built before EAL.

Currently it does not matter that this is determined in lib/eal since
the definitions are consumed before anything is built including libs
built before lib/eal. By moving this logic to config it allows kvargs
and telemetry to be built without EAL.

No functional change intended.

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 config/meson.build  | 8 ++++++++
 lib/eal/meson.build | 8 --------
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/config/meson.build b/config/meson.build
index 898b743..e0b9e4e 100644
--- a/config/meson.build
+++ b/config/meson.build
@@ -14,6 +14,14 @@ foreach env:supported_exec_envs
     set_variable('is_' + env, exec_env == env)
 endforeach
 
+exec_envs = {'freebsd': 0, 'linux': 1, 'windows': 2}
+foreach env, id:exec_envs
+    dpdk_conf.set('RTE_ENV_' + env.to_upper(), id)
+    dpdk_conf.set10('RTE_EXEC_ENV_IS_' + env.to_upper(), (exec_env == env))
+endforeach
+dpdk_conf.set('RTE_EXEC_ENV', exec_envs[exec_env])
+dpdk_conf.set('RTE_EXEC_ENV_' + exec_env.to_upper(), 1)
+
 # MS linker requires special treatment.
 # TODO: use cc.get_linker_id() with Meson >= 0.54
 is_ms_compiler = is_windows and (cc.get_id() == 'msvc')
diff --git a/lib/eal/meson.build b/lib/eal/meson.build
index 056beb9..26c638f 100644
--- a/lib/eal/meson.build
+++ b/lib/eal/meson.build
@@ -10,14 +10,6 @@ if not is_windows
     subdir('unix')
 endif
 
-exec_envs = {'freebsd': 0, 'linux': 1, 'windows': 2}
-foreach env, id:exec_envs
-    dpdk_conf.set('RTE_ENV_' + env.to_upper(), id)
-    dpdk_conf.set10('RTE_EXEC_ENV_IS_' + env.to_upper(), (exec_env == env))
-endforeach
-dpdk_conf.set('RTE_EXEC_ENV', exec_envs[exec_env])
-
-dpdk_conf.set('RTE_EXEC_ENV_' + exec_env.to_upper(), 1)
 subdir(exec_env)
 
 subdir(arch_subdir)
-- 
1.8.3.1


  parent reply	other threads:[~2023-01-26 18:03 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-25 19:25 [PATCH 0/3] unblock the use of the MSVC compiler Tyler Retzlaff
2023-01-25 19:25 ` [PATCH 1/3] build: " Tyler Retzlaff
2023-01-26 10:07   ` Bruce Richardson
2023-01-25 19:25 ` [PATCH 2/3] build: determine execution environment at config time Tyler Retzlaff
2023-01-26 10:09   ` Bruce Richardson
2023-01-25 19:25 ` [PATCH 3/3] build: limit what is built when using MSVC compiler Tyler Retzlaff
2023-01-26 11:10   ` Bruce Richardson
2023-01-26 17:28     ` Tyler Retzlaff
2023-01-26 17:34       ` Bruce Richardson
2023-01-26 17:36         ` Tyler Retzlaff
2023-01-26 18:03 ` [PATCH v2 0/3] unblock the use of the " Tyler Retzlaff
2023-01-26 18:03   ` [PATCH v2 1/3] build: " Tyler Retzlaff
2023-01-26 18:03   ` Tyler Retzlaff [this message]
2023-01-26 18:03   ` [PATCH v2 3/3] build: limit what is built when using " Tyler Retzlaff
2023-01-26 18:18     ` Bruce Richardson
2023-01-26 18:05   ` [PATCH v2 0/3] unblock the use of the " Tyler Retzlaff
2023-04-25 20:08 ` [PATCH v3 0/4] enable " Tyler Retzlaff
2023-04-25 20:08   ` [PATCH v3 1/4] build: unblock the " Tyler Retzlaff
2023-08-11 13:31     ` David Marchand
2023-04-25 20:08   ` [PATCH v3 2/4] build: determine execution environment at config time Tyler Retzlaff
2023-04-25 20:08   ` [PATCH v3 3/4] build: limit what is built when using MSVC compiler Tyler Retzlaff
2023-08-11 13:31     ` David Marchand
2023-04-25 20:08   ` [PATCH v3 4/4] build: enable MSVC specific compiler options Tyler Retzlaff
2023-08-11 18:24 ` [PATCH v4 0/4] enable use of the MSVC compiler Tyler Retzlaff
2023-08-11 18:24   ` [PATCH v4 1/4] build: unblock the " Tyler Retzlaff
2023-08-14  8:27     ` Bruce Richardson
2023-08-14  9:07       ` Dmitry Kozlyuk
2023-08-14  9:12         ` Bruce Richardson
2023-08-11 18:24   ` [PATCH v4 2/4] build: determine execution environment at config time Tyler Retzlaff
2023-08-11 18:24   ` [PATCH v4 3/4] build: limit what is built when using MSVC compiler Tyler Retzlaff
2023-08-11 18:26     ` Tyler Retzlaff
2023-08-11 18:24   ` [PATCH v4 4/4] build: enable MSVC specific compiler options Tyler Retzlaff
2023-08-14  8:30     ` Bruce Richardson
2023-08-14 16:10       ` Tyler Retzlaff
2023-08-14 16:46         ` Bruce Richardson
2023-08-14 18:28           ` Morten Brørup
2023-08-15 13:21     ` David Marchand
2023-08-16 21:56 ` [PATCH v5 0/4] enable use of the MSVC compiler Tyler Retzlaff
2023-08-16 21:56   ` [PATCH v5 1/4] build: unblock the " Tyler Retzlaff
2023-08-16 21:56   ` [PATCH v5 2/4] build: determine execution environment at config time Tyler Retzlaff
2023-08-16 21:56   ` [PATCH v5 3/4] build: limit what is built when using MSVC compiler Tyler Retzlaff
2023-08-16 21:56   ` [PATCH v5 4/4] build: enable MSVC specific compiler options Tyler Retzlaff
2023-08-17  8:33     ` Bruce Richardson
2023-08-25  8:43   ` [PATCH v5 0/4] enable use of the MSVC compiler David Marchand

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1674756204-25965-3-git-send-email-roretzla@linux.microsoft.com \
    --to=roretzla@linux.microsoft.com \
    --cc=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.