From 9c76d2dbb68296c7bbbb41e8c7eddbc62ef97f81 Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Wed, 6 Apr 2016 01:29:57 +0200 Subject: [PATCH 1/4] Travis: build luajit from source (2.0.4 as of now) --- .travis.yml | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/.travis.yml b/.travis.yml index 03cfc2556..7b9b30ed1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,12 +5,10 @@ env: matrix: # Note: luarocks does not work with Lua 5.0. - LUA=5.1 LGIVER= LUANAME=lua5.1 + # luajit: installed from source. + - LUA=5.1 LGIVER= LUANAME=luajit-2.0 LUALIBRARY=/usr/lib/libluajit-5.1.so LUAROCKS_ARGS=--lua-suffix=jit-2.0.4 - LUA=5.2 LGIVER= LUANAME=lua5.2 BUILD_APIDOC=true DO_COVERAGE=true - LUA=5.2 LGIVER=0.7.1 LUANAME=lua5.2 - # luajit: requires --lua-suffix=jit-2.0.0-beta9 in Ubuntu precise. - # Later versions seem to provide a `luajit` symlink, so `jit` would be enough. - # See http://packages.ubuntu.com/precise/i386/luajit/filelist. - - LUA=5.1 LGIVER= LUANAME=luajit-5.1 INSTALL_PKGS="luajit" LUAINCLUDE=/usr/include/luajit-2.0 LUAROCKS_ARGS=--lua-suffix=jit-2.0.2 # Lua 5.3 isn't available in Ubuntu trusty, so some magic below installs it - LUA=5.3 LGIVER= LUANAME=lua5.3 LUALIBRARY=/usr/lib/liblua.so global: @@ -46,13 +44,18 @@ install: (cd src && make SYSCFLAGS="-DLUA_USE_LINUX -ULUA_COMPAT_5_2" SYSLIBS="-Wl,-E -ldl -lreadline" LUA_A=liblua.so MYCFLAGS="-fPIC" RANLIB=: AR="gcc -shared -ldl -o" liblua.so) || exit 1 sudo make INSTALL_TOP=/usr/ INSTALL_INC=${LUAINCLUDE} TO_LIB=liblua.so linux install || exit 1 cd .. + elif [[ "$LUANAME" == "luajit-2.0" ]]; then + git clone http://luajit.org/git/luajit-2.0.git + cd luajit-2.0 + sudo make install PREFIX=/usr + cd .. + + # "Create" /usr/bin/lua if needed (Yup, this is a bad hack) + if [ ! -e "/usr/bin/lua" ]; then sudo ln -s /usr/bin/luajit /usr/bin/lua; fi else sudo apt-get install -y lib${LUANAME}-dev ${LUANAME} ${INSTALL_PKGS} fi - # "Create" /usr/bin/lua if needed (Yup, this is a bad hack) - - if [ ! -e "/usr/bin/lua" ]; then sudo ln -s /usr/bin/luajit /usr/bin/lua; fi - # Install luarocks (for the selected Lua version). - travis_retry wget https://keplerproject.github.io/luarocks/releases/luarocks-2.3.0.tar.gz - tar xf luarocks-2.3.0.tar.gz From 7cbbfdf1814c7093e64532f81442270a400ea7d0 Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Wed, 6 Apr 2016 01:48:30 +0200 Subject: [PATCH 2/4] Travis: move luarocks install into single block --- .travis.yml | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/.travis.yml b/.travis.yml index 7b9b30ed1..c0162136c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -57,13 +57,14 @@ install: fi # Install luarocks (for the selected Lua version). - - travis_retry wget https://keplerproject.github.io/luarocks/releases/luarocks-2.3.0.tar.gz - - tar xf luarocks-2.3.0.tar.gz - - cd luarocks-2.3.0 - - ./configure --lua-version=$LUA --with-lua-include=${LUAINCLUDE} ${LUAROCKS_ARGS} - - make build - - sudo make install - - cd .. + - | + travis_retry wget https://keplerproject.github.io/luarocks/releases/luarocks-2.3.0.tar.gz + tar xf luarocks-2.3.0.tar.gz + cd luarocks-2.3.0 + ./configure --lua-version=$LUA --with-lua-include=${LUAINCLUDE} ${LUAROCKS_ARGS} + make build + sudo make install + cd .. # lgi. - sudo apt-get install -y gir1.2-pango-1.0 libgirepository1.0-dev From 7116fda78de96b93fef9711e09b12edfd00edca2 Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Wed, 6 Apr 2016 02:06:30 +0200 Subject: [PATCH 3/4] Travis: cleanup LGIVER matrix assignment --- .travis.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index c0162136c..c39ead1f9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,13 +4,13 @@ language: c env: matrix: # Note: luarocks does not work with Lua 5.0. - - LUA=5.1 LGIVER= LUANAME=lua5.1 + - LUA=5.1 LUANAME=lua5.1 # luajit: installed from source. - - LUA=5.1 LGIVER= LUANAME=luajit-2.0 LUALIBRARY=/usr/lib/libluajit-5.1.so LUAROCKS_ARGS=--lua-suffix=jit-2.0.4 - - LUA=5.2 LGIVER= LUANAME=lua5.2 BUILD_APIDOC=true DO_COVERAGE=true - - LUA=5.2 LGIVER=0.7.1 LUANAME=lua5.2 + - LUA=5.1 LUANAME=luajit-2.0 LUALIBRARY=/usr/lib/libluajit-5.1.so LUAROCKS_ARGS=--lua-suffix=jit-2.0.4 + - LUA=5.2 LUANAME=lua5.2 BUILD_APIDOC=true DO_COVERAGE=true + - LUA=5.2 LUANAME=lua5.2 LGIVER=0.7.1 # Lua 5.3 isn't available in Ubuntu trusty, so some magic below installs it - - LUA=5.3 LGIVER= LUANAME=lua5.3 LUALIBRARY=/usr/lib/liblua.so + - LUA=5.3 LUANAME=lua5.3 LUALIBRARY=/usr/lib/liblua.so global: # Secure token to push to gh-pages. - secure: "LZxt9559+V3qJMdVgmKW4RYTt8ZINooex/qsnoEJUtZloj/eFNG4COT2z6a2yeH2tKWzknCsmV9nLPJiNEA2KLcyqDhjFQvJwKmsBuhGUmLyeQgfenjweorRjO8NT18X1SAEUXAMnClPu+OeTDs4BAuVn5foGZ7xpcRg2E+j2mc=" From 5eec87e0430fb2559295e18ff4defe46a0fba8ab Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Wed, 6 Apr 2016 02:12:48 +0200 Subject: [PATCH 4/4] Travis: move BUILD_APIDOC=true (Lua 5.2) to the beginning --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index c39ead1f9..edee88096 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,11 +3,11 @@ dist: trusty language: c env: matrix: + - LUA=5.2 LUANAME=lua5.2 BUILD_APIDOC=true DO_COVERAGE=true # Note: luarocks does not work with Lua 5.0. - LUA=5.1 LUANAME=lua5.1 # luajit: installed from source. - LUA=5.1 LUANAME=luajit-2.0 LUALIBRARY=/usr/lib/libluajit-5.1.so LUAROCKS_ARGS=--lua-suffix=jit-2.0.4 - - LUA=5.2 LUANAME=lua5.2 BUILD_APIDOC=true DO_COVERAGE=true - LUA=5.2 LUANAME=lua5.2 LGIVER=0.7.1 # Lua 5.3 isn't available in Ubuntu trusty, so some magic below installs it - LUA=5.3 LUANAME=lua5.3 LUALIBRARY=/usr/lib/liblua.so