forked from dargueta/unicorn-lua
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement bulk read_as (dargueta#20)
* Implement bulk read_as * Add documentation * Fix wrong variable name * Overhaul, use batch reading * Move to Github Actions instead of Travis * Bump installed Lua versions * More verbose logging, add library search hints for Unicorn * Fix working directory so ctest sees the tests * Mess with LD_LIBRARY_PATH on Linux * Fix early collection bug * Fix garbage collecting crash and add __close on engines too * Add CI for Mac OS * Stop using deprecated CMake stuff * Fix included comment, upgrade LuaRocks * Lazily install rocks, not in CMake initialization * --local no longer required * Minor code cleanup, fix exit code in `configure` * Many many bugfixes and C-isms * Fix broken examples * Miscellaneous minor build stuff * Add release/debug flags to settings * Use build-specific C++ flags instead of if/else * Add installation configuration * Use `make install` in CI * Fix some typecasting, initialize arrays, use range expressions * Make test depend on test executable * Use lua_Number instead of uclua_float80, add sNaN/qNaN distinction * Use platform-independent CMake commands * Finally fix infinity/NaN problems * Fix datatypes in disabled tests * Fix install prefix for Lua 5.1 * Fix signaling NaN on Mac OS * Move templates for busted stuff into the templates dir * Make `configure` run CMake * Fix LuaJIT linker error on OSX * Consolidate generated and configured files * Context double-free test * Fix attempt to match null pointer to C registry when closing engine * LuaJIT mimics Lua 5.1.4 not 5.1.0 * Remove definition of lua_Unsigned * [DEBUG ONLY] Disable context tests * Try to fix segfault on OSX LuaJIT in lua_seti() implementation * Try verbose mode for debugging * Make engine and Lua state private variables for UCLuaEngine * Let Lua manage context allocation * Start adding tests for LuaResourceTable * Fix wrong CMake variable name in a template * Update changelog * Fix wrong function call that just happened to work * Clean up the Lua stack before crashing in allocate() * [BROKEN] Allocate contexts on the heap, use indirect pointers for the userdata * Overhaul contexts again to make them structs * Fix segfault in destructor due to modifying set as we are iterating * Delete dead code, disable lua_seti tests on OSX+LuaJIT * Remove virtualenv dir when doing `make clean` * Update changelog * Update documentation * Disable segfaulting tests * Use more thorough asserts, remove extraneous engine handle * I must be losing my mind * Check the stack when panicking before pushing an error message * [BROKEN] Require the stack to be clean when exiting a test * Unconditionally clear the stack in ul_crash_on_error tests We need this because Lua can put stuff on the stack aside from our error message that we don't know about. Since all we care about is the error message at the top of the stack, we can clear it. * Update library version Co-authored-by: Diego Argueta <620513-dargueta@users.noreply.github.com>
- Loading branch information
Showing
51 changed files
with
991 additions
and
572 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: CI | ||
|
||
on: [ push ] | ||
|
||
jobs: | ||
testing: | ||
runs-on: ${{ matrix.operating-system }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
operating-system: | ||
- ubuntu-20.04 | ||
- macos-10.15 | ||
lua-version: | ||
- "5.1" | ||
- "5.2" | ||
- "5.3" | ||
- "5.4" | ||
- "luajit2.0" | ||
steps: | ||
- uses: actions/checkout@v1 | ||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.8" | ||
- name: Install Unicorn | ||
run: ./tools/ci/install-unicorn.sh 1.0.2 | ||
- name: Set up Lua | ||
# We need the MACOSX_DEPLOYMENT_TARGET environment variable because of | ||
# a linker error that happens with LuaJIT: | ||
# https://github.com/LuaJIT/LuaJIT/issues/449 | ||
run: | | ||
export MACOSX_DEPLOYMENT_TARGET=10.14 | ||
python3 ./tools/lua_venv.py -l -o settings.json ${{ matrix.lua-version }} __lua${{ matrix.lua-version }} | ||
- name: Configure build | ||
run: python3 ./configure --venv-config settings.json --build-type debug | ||
- name: Install | ||
run: sudo make install | ||
- name: Run tests | ||
# We get a linker error if we don't mess with the library path. For some | ||
# reason, /usr/lib64 isn't on the default search path. | ||
run: | | ||
export LD_LIBRARY_PATH=/usr/lib64:${LD_LIBRARY_PATH} | ||
make test | ||
# TODO (dargueta): Test on Windows? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.