| 1 |
@echo off |
| 2 |
|
| 3 |
call :init "%~dp0." |
| 4 |
goto top |
| 5 |
|
| 6 |
:init |
| 7 |
rem call init2 for treatments last directory separator |
| 8 |
call :init2 "%~dp1." |
| 9 |
goto :eof |
| 10 |
|
| 11 |
:init2 |
| 12 |
set MRUBY_PACKAGE_DIR=%~f1 |
| 13 |
goto :eof |
| 14 |
|
| 15 |
:top |
| 16 |
shift |
| 17 |
if "%0" equ "" goto :eof |
| 18 |
if "%0" equ "--cc" goto cc |
| 19 |
if "%0" equ "--cflags" goto cflags |
| 20 |
if "%0" equ "--cxx" goto cxx |
| 21 |
if "%0" equ "--cxxflags" goto cxxflags |
| 22 |
if "%0" equ "--as" goto as |
| 23 |
if "%0" equ "--asflags" goto asflags |
| 24 |
if "%0" equ "--objc" goto objc |
| 25 |
if "%0" equ "--objcflags" goto objcflags |
| 26 |
if "%0" equ "--ld" goto ld |
| 27 |
if "%0" equ "--ldflags" goto ldflags |
| 28 |
if "%0" equ "--ldflags-before-libs" goto ldflagsbeforelibs |
| 29 |
if "%0" equ "--libs" goto libs |
| 30 |
if "%0" equ "--libmruby-path" goto libmrubypath |
| 31 |
if "%0" equ "--help" goto showhelp |
| 32 |
echo Invalid Option |
| 33 |
goto :eof |
| 34 |
|
| 35 |
:cc |
| 36 |
echo MRUBY_CC |
| 37 |
goto top |
| 38 |
|
| 39 |
:cflags |
| 40 |
echo MRUBY_CFLAGS |
| 41 |
goto top |
| 42 |
|
| 43 |
:cxx |
| 44 |
echo MRUBY_CXX |
| 45 |
goto top |
| 46 |
|
| 47 |
:cxxflags |
| 48 |
echo MRUBY_CXXFLAGS |
| 49 |
goto top |
| 50 |
|
| 51 |
:as |
| 52 |
echo MRUBY_AS |
| 53 |
goto top |
| 54 |
|
| 55 |
:asflags |
| 56 |
echo MRUBY_ASFLAGS |
| 57 |
goto top |
| 58 |
|
| 59 |
:objc |
| 60 |
echo MRUBY_OBJC |
| 61 |
goto top |
| 62 |
|
| 63 |
:objcflags |
| 64 |
echo MRUBY_OBJCFLAGS |
| 65 |
goto top |
| 66 |
|
| 67 |
:ld |
| 68 |
echo MRUBY_LD |
| 69 |
goto top |
| 70 |
|
| 71 |
:libs |
| 72 |
echo MRUBY_LIBS |
| 73 |
goto top |
| 74 |
|
| 75 |
:ldflags |
| 76 |
echo MRUBY_LDFLAGS |
| 77 |
goto top |
| 78 |
|
| 79 |
:ldflagsbeforelibs |
| 80 |
echo MRUBY_LDFLAGS_BEFORE_LIBS |
| 81 |
goto top |
| 82 |
|
| 83 |
:libmrubypath |
| 84 |
echo MRUBY_LIBMRUBY_PATH |
| 85 |
goto top |
| 86 |
|
| 87 |
:showhelp |
| 88 |
echo Usage: mruby-config [switches] |
| 89 |
echo switches: |
| 90 |
echo --cc print C compiler name |
| 91 |
echo --cflags print flags passed to C compiler |
| 92 |
echo --cxx print C++ compiler name |
| 93 |
echo --cxxflags print flags passed to C++ compiler |
| 94 |
echo --as print assembler name |
| 95 |
echo --asflags print flags passed to assembler |
| 96 |
echo --objc print Objective C compiler name |
| 97 |
echo --objcflags print flags passed to Objective C compiler |
| 98 |
echo --ld print linker name |
| 99 |
echo --ldflags print flags passed to linker |
| 100 |
echo --ldflags-before-libs print flags passed to linker before linked libraries |
| 101 |
echo --libs print linked libraries |
| 102 |
echo --libmruby-path print libmruby path |