Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
language: erlang

env:
global:
- LUAROCKS_BASE=luarocks-2.0.13
matrix:
- "LUA=lua5.1 LUA_DEV=liblua5.1-dev LUA_VER=5.1 LUA_SFX=5.1 LUA_INCDIR=/usr/include/lua5.1"
- "LUA=lua5.2 LUA_DEV=liblua5.2-dev LUA_VER=5.2 LUA_SFX=5.2 LUA_INCDIR=/usr/include/lua5.2"
- "LUA=luajit LUA_DEV=libluajit-5.1-dev LUA_VER=5.1 LUA_SFX=jit-2.0.0-beta9 LUA_INCDIR=/usr/include/luajit-2.0"

branches:
only:
- stream

before_install:
- "sudo apt-get install $LUA"
- "sudo apt-get install $LUA_DEV"
- "lua$LUA_SFX -v"
# Install a recent luarocks release
- wget http://luarocks.org/releases/$LUAROCKS_BASE.tar.gz
- tar zxvpf $LUAROCKS_BASE.tar.gz
- cd $LUAROCKS_BASE
- ./configure
--lua-version=$LUA_VER --lua-suffix=$LUA_SFX --with-lua-include="$LUA_INCDIR"
- sudo make
- sudo make install
- cd $TRAVIS_BUILD_DIR

install:
- sudo apt-get install openssl
- sudo luarocks install lunitx
- sudo luarocks make rockspecs/luacrypto-git-1.rockspec

script: "cd tests/unit && lunit.sh -i lua$LUA_SFX run.lua"

notifications:
email:
on_success: change
on_failure: always
23 changes: 15 additions & 8 deletions rockspecs/luacrypto-git-1.rockspec
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,14 @@ digests (MD5, SHA-1, HMAC, and more), encryption, decryption and crypto-grade ra
dependencies = {
"lua >= 5.1",
}
external_dependencies = {
OPENSSL = {
header = "openssl/evp.h"
}
}
source = {
url = [[git://github.com/mkottman/luacrypto.git]],
dir = "luacrypto"
url = "https://github.com/mkottman/luacrypto/archive/master.zip",
dir = "luacrypto-master",
}
build = {
platforms = {
Expand All @@ -22,12 +27,14 @@ build = {
install_command = [[copy ".\Release\crypto.dll" "$(LIBDIR)\crypto.dll" /y ]]
},
unix = {
type = "make",
variables = {
INCONCERT_DEVEL = "$(INCONCERT_DEVEL)",
LUA_LUADIR = "$(LUADIR)",
LUA_LIBDIR = "$(LIBDIR)",
LUA_PREFIX = "$(PREFIX)"
type = "builtin",
modules = {
crypto = {
sources = "src/lcrypto.c",
incdirs = "$(OPENSSL_INCDIR)",
libdirs = "$(OPENSSL_LIBDIR)",
libraries = "crypto",
}
}
}
},
Expand Down
Loading