From c5bffdc43848d00ac97cfd402f33f19b506dd65c Mon Sep 17 00:00:00 2001 From: Thijs Schreijer Date: Fri, 5 Apr 2013 19:11:18 +0200 Subject: moved some blocks around to make it more logical --- install.bat | 43 ++++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 21 deletions(-) diff --git a/install.bat b/install.bat index cd02af1a..568bc0f0 100644 --- a/install.bat +++ b/install.bat @@ -269,6 +269,11 @@ IF [%INSTALL_LUA%]==[ON] ( REM Copy the LuaRocks binaries COPY bin\*.* "%BINDIR%" >NUL IF ERRORLEVEL 1 GOTO ERROR +REM Copy the LuaRocks lua source files +IF NOT EXIST "%LUADIR%\luarocks" %MKDIR% "%LUADIR%\luarocks" +IF ERRORLEVEL 1 GOTO ERROR +XCOPY /S src\luarocks\*.* "%LUADIR%\luarocks" >NUL +IF ERRORLEVEL 1 GOTO ERROR REM Create start scripts COPY src\bin\*.* "%BINDIR%" >NUL IF ERRORLEVEL 1 GOTO ERROR @@ -286,11 +291,23 @@ FOR %%C IN (luarocks luarocks-admin) DO ( ECHO ENDLOCAL>> "%BINDIR%\%%C.bat" ECHO Created LuaRocks command: %BINDIR%\%%C.bat ) -REM Copy the LuaRocks lua source files -IF NOT EXIST "%LUADIR%\luarocks" %MKDIR% "%LUADIR%\luarocks" -IF ERRORLEVEL 1 GOTO ERROR -XCOPY /S src\luarocks\*.* "%LUADIR%\luarocks" >NUL -IF ERRORLEVEL 1 GOTO ERROR +REM configure 'scripts' directory +IF [%SCRIPTS_DIR%]==[] ( + %MKDIR% "%ROCKS_TREE%"\bin >NUL + IF [%USE_MINGW%]==[] ( + REM definitly not for MinGW because of conflicting runtimes + REM but is it ok to do it for others??? + COPY lua5.1\bin\*.dll "%ROCKS_TREE%"\bin >NUL + ) +) ELSE ( + %MKDIR% "%SCRIPTS_DIR%" >NUL + IF [%USE_MINGW%]==[] ( + REM definitly not for MinGW because of conflicting runtimes + REM but is it ok to do it for others??? + COPY lua5.1\bin\*.dll "%SCRIPTS_DIR%" >NUL + ) +) + ECHO. ECHO Configuring LuaRocks... @@ -336,22 +353,6 @@ IF NOT EXIST "%CONFIG_FILE%" ( ECHO LuaRocks config file already exists: %CONFIG_FILE% ) -IF [%SCRIPTS_DIR%]==[] ( - %MKDIR% "%ROCKS_TREE%"\bin >NUL - IF [%USE_MINGW%]==[] ( - REM definitly not for MinGW because of conflicting runtimes - REM but is it ok to do it for others??? - COPY lua5.1\bin\*.dll "%ROCKS_TREE%"\bin >NUL - ) -) ELSE ( - %MKDIR% "%SCRIPTS_DIR%" >NUL - IF [%USE_MINGW%]==[] ( - REM definitly not for MinGW because of conflicting runtimes - REM but is it ok to do it for others??? - COPY lua5.1\bin\*.dll "%SCRIPTS_DIR%" >NUL - ) -) - ECHO. ECHO Creating rocktrees... IF NOT EXIST "%ROCKS_TREE%" ( -- cgit v1.2.3-55-g6feb