Official Release
This version isn't recommended for use, as lua.exe and lua_debug.exe doesn't output anything from stdout or stderr.
The product now exemplifies a product that can be put to use. This build uses lua5.3.4. Licenses included with the src.
- Added arguments using the -n switch
- Fixed up some formatting
- Uses correct #include for unix versus windows
- Tries to support c89 only if accepting // comments
- Updated help message
- Moved copyright to always print in the stdout
Includes testing.lua, which prints out arguments inputted using the -n switch at the end.
Compiled on Intel machine using mingw64.
Instructions:
Make a folder in your C:\Program Files\ or where ever and make a 'bin' folder. Shove lua.exe and luaw.exe into it. Add this 'bin' folder to your path. C:\Program Files\LuaConsole\bin, for example.
Use luaw when you want to do stuff in lua and have the interpreter at your fingertips, or just
@echo off
rem Debug version
rem Compile everything debug
gcc -Wall -Wextra -O0 -g3 -c *.c
rem Link lua_debug.exe
gcc -Wall -Wextra -O0 -g3 -mwindows -o lua_debug.exe console.o additions.o -llua
rem Link luaw_debug.exe
gcc -Wall -Wextra -O0 -g3 -o luaw_debug.exe consolew.o additions.o -llua
rem Release version
rem Compile everything release
gcc -Wall -Wextra -O2 -g0 -c *.c
rem Link luaw.exe
gcc -Wall -Wextra -O2 -g0 -mwindows -o lua.exe console.o additions.o -llua
rem Link lua.exe
gcc -Wall -Wextra -O2 -g0 -o luaw.exe consolew.o additions.o -llua