Skip to content

EmmyLua/EmmyLuaDebugger

Repository files navigation

๐Ÿš€ EmmyLua Debugger

Build Status Lua Version

High-performance cross-platform Lua debugger with full debugging features including breakpoints, variable watch, stack trace, and more.


โœจ Features

  • ๐ŸŽฏ Full Debugging Features - Breakpoints, step execution, variable watch, stack trace
  • ๐ŸŒ Cross-Platform Support - Windows, macOS, Linux
  • โšก High Performance - Efficient debugging communication based on TCP protocol
  • ๐Ÿ”ง Easy Integration - Supports multiple Lua versions and game engine integration

๐ŸŽฎ Supported Platforms

Platform Status Notes
Windows x64 โœ… Fully supported
macOS โœ… Intel & Apple Silicon
Linux โœ… any

๐Ÿ”ง Lua Support

Lua Version Status Notes
Lua 5.1 โœ… Fully supported
Lua 5.2 โœ… Fully supported
Lua 5.3 โœ… Fully supported
Lua 5.4 โœ… Fully supported
LuaJIT โœ… Fully supported

๐Ÿš€ Quick Start

1. Clone the Repository

git clone https://github.com/EmmyLua/EmmyLuaDebugger.git
cd EmmyLuaDebugger

2. Build the Project

Windows (Visual Studio)

mkdir build
cd build
cmake .. -DEMMY_LUA_VERSION=54
cmake --build . --config Release

macOS/Linux

mkdir build
cd build
cmake .. -DEMMY_LUA_VERSION=54 -DCMAKE_BUILD_TYPE=Release
cmake --build . --config Release

3. Basic Usage

Integrate the debugger in your Lua code:

-- Load the debugger module
local dbg = require('emmy_core')

-- Start the TCP debug server
dbg.tcpListen('localhost', 9966)

-- Wait for IDE connection
dbg.waitIDE()

-- Set a strong breakpoint here
dbg.breakHere()

-- Your Lua code
print("Hello, EmmyLua Debugger!")

Connect the debugger in your IDE:

  1. Open an IDE that supports EmmyLua (e.g., IntelliJ IDEA + EmmyLua plugin)
  2. Configure the debug connection: TCP Connect mode, address localhost:9966
  3. Click to start debugging
  4. Set breakpoints in your code and enjoy debugging!

๐Ÿ“š Documentation

๐Ÿ› ๏ธ Build Options

Option Default Description
EMMY_LUA_VERSION 54 Lua version (51/52/53/54/jit)
EMMY_USE_LUA_SOURCE OFF Whether to build with Lua source

Advanced Build Examples

# Build for a specific version
cmake .. -DEMMY_LUA_VERSION=53 
# Build using Lua source
cmake .. -DEMMY_USE_LUA_SOURCE=ON

Development Environment Setup

  1. Install required build tools:

    • Windows: Visual Studio 2019+
    • macOS: Xcode + Command Line Tools
    • Linux: GCC 7+ or Clang 6+
  2. Install CMake 3.11+

  3. Clone and build the project:

    git clone --recursive https://github.com/EmmyLua/EmmyLuaDebugger.git
    cd EmmyLuaDebugger
    mkdir build && cd build
    cmake ..
    cmake --build .

๐Ÿ™ Acknowledgements

  • libuv - Cross-platform asynchronous I/O library
  • nlohmann/json - Modern C++ JSON library
  • Lua - Powerful embedded scripting language

๐Ÿ“ž Support & Contact


โญ If you find this project helpful, please give us a Star! โญ

Made with โค๏ธ by EmmyLua Team

About

EmmyLua Debugger

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 15