public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [edk2-devel] [PATCH] BaseTools: Add FMMT BinPipWrappers
@ 2023-07-26  7:16 Yuwei Chen
  2023-07-28  2:03 ` 回复: " gaoliming via groups.io
  0 siblings, 1 reply; 2+ messages in thread
From: Yuwei Chen @ 2023-07-26  7:16 UTC (permalink / raw)
  To: devel; +Cc: Rebecca Cran, Liming Gao, Bob Feng

Cc: Rebecca Cran <rebecca@bsdio.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Bob Feng <bob.c.feng@intel.com>
Signed-off-by: Yuwei Chen <yuwei.chen@intel.com>
---
 BaseTools/BinPipWrappers/PosixLike/FMMT       | 12 ++++++++++++
 BaseTools/BinPipWrappers/WindowsLike/FMMT.bat |  3 +++
 2 files changed, 15 insertions(+)
 create mode 100755 BaseTools/BinPipWrappers/PosixLike/FMMT
 create mode 100644 BaseTools/BinPipWrappers/WindowsLike/FMMT.bat

diff --git a/BaseTools/BinPipWrappers/PosixLike/FMMT b/BaseTools/BinPipWrappers/PosixLike/FMMT
new file mode 100755
index 0000000000..9d143c7fc6
--- /dev/null
+++ b/BaseTools/BinPipWrappers/PosixLike/FMMT
@@ -0,0 +1,12 @@
+#!/usr/bin/env bash
+#python `dirname $0`/RunToolFromSource.py `basename $0` $*
+
+# If a ${PYTHON_COMMAND} command is available, use it in preference to python
+if command -v ${PYTHON_COMMAND} >/dev/null 2>&1; then
+    python_exe=${PYTHON_COMMAND}
+fi
+
+full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
+cmd=${full_cmd##*/}
+
+exec "${python_exe:-python}" -m edk2basetools.$cmd.$cmd "$@"
diff --git a/BaseTools/BinPipWrappers/WindowsLike/FMMT.bat b/BaseTools/BinPipWrappers/WindowsLike/FMMT.bat
new file mode 100644
index 0000000000..d347d64844
--- /dev/null
+++ b/BaseTools/BinPipWrappers/WindowsLike/FMMT.bat
@@ -0,0 +1,3 @@
+@setlocal
+@set ToolName=%~n0%
+@%PYTHON_COMMAND% -m edk2basetools.%ToolName%.%ToolName% %*
-- 
2.39.1.windows.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#107262): https://edk2.groups.io/g/devel/message/107262
Mute This Topic: https://groups.io/mt/100366342/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* 回复: [edk2-devel] [PATCH] BaseTools: Add FMMT BinPipWrappers
  2023-07-26  7:16 [edk2-devel] [PATCH] BaseTools: Add FMMT BinPipWrappers Yuwei Chen
@ 2023-07-28  2:03 ` gaoliming via groups.io
  0 siblings, 0 replies; 2+ messages in thread
From: gaoliming via groups.io @ 2023-07-28  2:03 UTC (permalink / raw)
  To: devel, yuwei.chen; +Cc: 'Rebecca Cran', 'Bob Feng'

Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>

> -----邮件原件-----
> 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Yuwei Chen
> 发送时间: 2023年7月26日 15:17
> 收件人: devel@edk2.groups.io
> 抄送: Rebecca Cran <rebecca@bsdio.com>; Liming Gao
> <gaoliming@byosoft.com.cn>; Bob Feng <bob.c.feng@intel.com>
> 主题: [edk2-devel] [PATCH] BaseTools: Add FMMT BinPipWrappers
> 
> Cc: Rebecca Cran <rebecca@bsdio.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Bob Feng <bob.c.feng@intel.com>
> Signed-off-by: Yuwei Chen <yuwei.chen@intel.com>
> ---
>  BaseTools/BinPipWrappers/PosixLike/FMMT       | 12 ++++++++++++
>  BaseTools/BinPipWrappers/WindowsLike/FMMT.bat |  3 +++
>  2 files changed, 15 insertions(+)
>  create mode 100755 BaseTools/BinPipWrappers/PosixLike/FMMT
>  create mode 100644 BaseTools/BinPipWrappers/WindowsLike/FMMT.bat
> 
> diff --git a/BaseTools/BinPipWrappers/PosixLike/FMMT
> b/BaseTools/BinPipWrappers/PosixLike/FMMT
> new file mode 100755
> index 0000000000..9d143c7fc6
> --- /dev/null
> +++ b/BaseTools/BinPipWrappers/PosixLike/FMMT
> @@ -0,0 +1,12 @@
> +#!/usr/bin/env bash
> +#python `dirname $0`/RunToolFromSource.py `basename $0` $*
> +
> +# If a ${PYTHON_COMMAND} command is available, use it in preference to
> python
> +if command -v ${PYTHON_COMMAND} >/dev/null 2>&1; then
> +    python_exe=${PYTHON_COMMAND}
> +fi
> +
> +full_cmd=${BASH_SOURCE:-$0} # see
> http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a
> good choice here
> +cmd=${full_cmd##*/}
> +
> +exec "${python_exe:-python}" -m edk2basetools.$cmd.$cmd "$@"
> diff --git a/BaseTools/BinPipWrappers/WindowsLike/FMMT.bat
> b/BaseTools/BinPipWrappers/WindowsLike/FMMT.bat
> new file mode 100644
> index 0000000000..d347d64844
> --- /dev/null
> +++ b/BaseTools/BinPipWrappers/WindowsLike/FMMT.bat
> @@ -0,0 +1,3 @@
> +@setlocal
> +@set ToolName=%~n0%
> +@%PYTHON_COMMAND% -m
> edk2basetools.%ToolName%.%ToolName% %*
> --
> 2.39.1.windows.1
> 
> 
> 
> 
> 





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#107307): https://edk2.groups.io/g/devel/message/107307
Mute This Topic: https://groups.io/mt/100403646/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-07-28  2:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-26  7:16 [edk2-devel] [PATCH] BaseTools: Add FMMT BinPipWrappers Yuwei Chen
2023-07-28  2:03 ` 回复: " gaoliming via groups.io

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox