diff options
author | Jari Vetoniemi <jari.vetoniemi@indooratlas.com> | 2020-03-16 18:49:26 +0900 |
---|---|---|
committer | Jari Vetoniemi <jari.vetoniemi@indooratlas.com> | 2020-03-30 00:39:06 +0900 |
commit | fcbf63e62c627deae76c1b8cb8c0876c536ed811 (patch) | |
tree | 64cb17de3f41a2b6fef2368028fbd00349946994 /jni/ruby/win32/rtname.cmd |
Fresh start
Diffstat (limited to 'jni/ruby/win32/rtname.cmd')
-rw-r--r-- | jni/ruby/win32/rtname.cmd | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/jni/ruby/win32/rtname.cmd b/jni/ruby/win32/rtname.cmd new file mode 100644 index 0000000..1f410a0 --- /dev/null +++ b/jni/ruby/win32/rtname.cmd @@ -0,0 +1,18 @@ +@echo off +set rt= +set rtver= +set osver= +for /f "usebackq" %%I in (`dumpbin -dependents %1 ^| findstr -r -i "\<msvcr.*\.dll$"`) do set rt=%%~nI +if "%rt%" == "" ( + (echo %0: %1 is not linked to msvcrt) 1>&2 + exit 1 +) +for %%i in (a b c d e f g h i j k l m n o p q r s t u v w x y z) do @call set rt=%%rt:%%i=%%i%% +if "%rt%" == "msvcrt" ( + call set rtver=60 +) else ( + call set rtver=%%rt:msvcr=%% + call set rt=msvcr%%rtver%% + call set osver=_%%rtver%% +) +for %%I in ("PLATFORM = $(TARGET_OS)%osver%" "RT = %rt%" "RT_VER = %rtver%") do @echo %%~I |