Skip to content

Commit

Permalink
Travis exe releaser & lua syntax checker
Browse files Browse the repository at this point in the history
  • Loading branch information
SpiralP committed Jan 5, 2018
1 parent ca2f5c9 commit 4e99a8e
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 15 deletions.
50 changes: 37 additions & 13 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,42 @@ language: c
addons:
apt:
packages:
- libc6:i386
- libstdc++6:i386

- mingw-w64
- libc6-dev-i386
- libc6:i386
- libstdc++6:i386
- linux-libc-dev:i386
- gcc-4.8-multilib
- luajit

before_install:
# Download the lua
- wget https://github.com/Metastruct/gtravis/releases/download/travisbins/gluac.tar.xz
- tar -xf gluac.tar.xz
- export LD_LIBRARY_PATH=`pwd`/gluac${LD_LIBRARY_PATH:+:}${LD_LIBRARY_PATH:-}
# Download the lua
- |
curl -L 'https://github.com/Metastruct/gtravis/releases/download/travisbins/gluac.tar.xz' |tar -xJf - \
&& export LD_LIBRARY_PATH=`pwd`/gluac${LD_LIBRARY_PATH:+:}${LD_LIBRARY_PATH:-} \
&& export PATH=$PATH:`pwd`/gluac
# Compile luajit for windows libraries
- |
curl -L 'https://luajit.org/download/LuaJIT-2.0.5.tar.gz' |tar -xzf - \
&& pushd LuaJIT-2.0.5/src/ \
&& make HOST_CC="gcc -m32" CROSS=i686-w64-mingw32- TARGET_SYS=Windows BUILDMODE=static \
&& popd
- npm install

script:
- ls *.lua | xargs -- gluac -p --
- CC=i686-w64-mingw32-gcc NM=i686-w64-mingw32-nm make luastaticlib=./LuaJIT-2.0.5/src/libluajit.a luaincludedir=./LuaJIT-2.0.5/src/
- file *

# Set the $PATH so gluac can be executed
- export PATH=$PATH:`pwd`/gluac

- echo $PWD

script: ls *.lua | xargs -- gluac -p --
deploy:
provider: releases
api_key:
secure: "q7wkU3d934aW/8DyJOPQkV1bt8RctjWU6PD0lLyoeizpcBhso9OEeHAkdGajrW5i04V9/c7+cNXDC9Xbd9gr/OfrLRjl/rt8e/O1C/PYqYmjjnGY0q0q1nCj0ma0HrzLu8ZSH0KiTLjDn8qraQOIGoARXviLpQWbIZ0lixOWAGR+ZCwPhsu3nwCuSMukLPHe29sesaAMrfnj9OWZrLaAjnSs7hOCjQvJRBOfBI3iSzgAB7d7YVttsgrMzw7cFc2bIlQd6U1I+etrOYQ12qYZQXN8GJ/EakGQsNZTQ0Lmv0qgfTRk5+1hhz9ZuGlmZQq9OZkBYRqx+727YFZuOAG2hXQa4i6olFv8hejcHR6birlltAQ4M4Nw3YdXmFc/HV5OKB3i2Je8pOp3rnfyIVjiRYrFW07UaHO0bvsIKnGSoCOyZUlm5VX1PVjlQdW+fANJeNPoZqem/g/bR4keiMFMX+VZmyJVlV7F7Si4EhjU0pcElYlCVFM2EZsS2Z84hWYhKV182RUlanhUZtoEIqToovoMO2f4COMndmY9WQ0tFJoucw12oD8nxgCqoZqJuL2o8ytlY+HxcrSUks2KnBDcO8XN65jIEBfCr46/7GGJ4ZFOviAjn3zLE+/79U1pJEiTx/4IpceQu1Vak+NLIP8shEcK/PsaYFXK+36LLeWfZNU="
file: reslister.exe
skip_cleanup: true
on:
branch: master
branches:
only:
- master
9 changes: 7 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Msys2 mingw64.exe http://www.msys2.org/
luastaticlib = /mingw64/lib/libluajit-5.1.a
luaincludedir = /mingw64/include/luajit-2.0/
all:
test -f mdlinspect.lua || ln dist/lua/includes/modules/mdlinspect.lua
test -f binfuncs.lua || ln dist/lua/includes/modules/binfuncs.lua
luajit luastatic.lua init.lua mdlinspect.lua minigcompat.lua binfuncs.lua vstruct/lexer.lua vstruct/ast.lua vstruct/ast/*.lua vstruct/cursor.lua vstruct/io.lua vstruct/io/*.lua vstruct/init.lua vstruct/api.lua /mingw64/lib/libluajit-5.1.a -I/mingw64/include/luajit-2.0/ -o reslister.exe
luajit luastatic.lua \
init.lua \
mdlinspect.lua minigcompat.lua binfuncs.lua vstruct/lexer.lua vstruct/ast.lua vstruct/ast/*.lua vstruct/cursor.lua vstruct/io.lua vstruct/io/*.lua vstruct/init.lua vstruct/api.lua \
$(luastaticlib) \
-I$(luaincludedir) -o reslister.exe

0 comments on commit 4e99a8e

Please sign in to comment.