forked from github/server
Merge pull request #585 from ennorehling/tolua-build
allow building with lua 5.1 and matching tolua version
This commit is contained in:
commit
41db460278
7 changed files with 15 additions and 11 deletions
3
.gitmodules
vendored
3
.gitmodules
vendored
|
@ -26,6 +26,3 @@
|
||||||
path = storage
|
path = storage
|
||||||
url = https://github.com/ennorehling/storage.git
|
url = https://github.com/ennorehling/storage.git
|
||||||
branch = master
|
branch = master
|
||||||
[submodule "tolua"]
|
|
||||||
path = tolua
|
|
||||||
url = https://github.com/ennorehling/tolua.git
|
|
||||||
|
|
|
@ -12,6 +12,7 @@ addons:
|
||||||
- libsqlite3-dev
|
- libsqlite3-dev
|
||||||
- libxml2-dev
|
- libxml2-dev
|
||||||
- valgrind
|
- valgrind
|
||||||
|
- libtolua-dev
|
||||||
os:
|
os:
|
||||||
- linux
|
- linux
|
||||||
notifications:
|
notifications:
|
||||||
|
|
5
s/build
5
s/build
|
@ -35,11 +35,6 @@ fi
|
||||||
|
|
||||||
git submodule update
|
git submodule update
|
||||||
|
|
||||||
if [ -z `which tolua` ]; then
|
|
||||||
echo "build tolua"
|
|
||||||
cd $ROOT/tolua ; make
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "build eressea"
|
echo "build eressea"
|
||||||
cd $ROOT/$BUILD
|
cd $ROOT/$BUILD
|
||||||
VERSION=$(git describe --match 'v*.*.*' --tags | sed 's/^v//')
|
VERSION=$(git describe --match 'v*.*.*' --tags | sed 's/^v//')
|
||||||
|
|
13
s/cmake-init
13
s/cmake-init
|
@ -44,7 +44,18 @@ ARGS=" -DCMAKE_MODULE_PATH=$ROOT/cmake/Modules \
|
||||||
path="$(which tolua)"
|
path="$(which tolua)"
|
||||||
if [ "$HAVE_TOLUA" = "0" ] || [ -z $path ] ; then
|
if [ "$HAVE_TOLUA" = "0" ] || [ -z $path ] ; then
|
||||||
echo "tolua is not installed, building from source"
|
echo "tolua is not installed, building from source"
|
||||||
cd $ROOT/tolua ; make
|
cd $ROOT
|
||||||
|
if [ ! -d tolua ]; then
|
||||||
|
LUA_VERSION="5.1"
|
||||||
|
if [ -d /usr/include/lua5.2 ] || [ -d /usr/local/include/lua5.2 ]; then
|
||||||
|
LUA_VERSION="5.2"
|
||||||
|
fi
|
||||||
|
echo "fetching tolua ${LUA_VERSION} from github..."
|
||||||
|
git clone https://github.com/ennorehling/tolua-${LUA_VERSION}.git tolua
|
||||||
|
fi
|
||||||
|
echo "building tolua..."
|
||||||
|
cd tolua
|
||||||
|
make
|
||||||
ARGS="$ARGS -DPC_TOLUA_DIR=$ROOT/tolua"
|
ARGS="$ARGS -DPC_TOLUA_DIR=$ROOT/tolua"
|
||||||
else
|
else
|
||||||
echo "tolua is $path"
|
echo "tolua is $path"
|
||||||
|
|
|
@ -18,7 +18,6 @@ cd tests
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
[ -z $BUILD ] && BUILD=Debug ; export BUILD
|
[ -z $BUILD ] && BUILD=Debug ; export BUILD
|
||||||
cmake --version
|
|
||||||
s/cmake-init
|
s/cmake-init
|
||||||
s/build
|
s/build
|
||||||
cd $ROOT
|
cd $ROOT
|
||||||
|
|
|
@ -740,7 +740,9 @@ void kernel_done(void)
|
||||||
/* calling this function releases memory assigned to static variables, etc.
|
/* calling this function releases memory assigned to static variables, etc.
|
||||||
* calling it is optional, e.g. a release server will most likely not do it.
|
* calling it is optional, e.g. a release server will most likely not do it.
|
||||||
*/
|
*/
|
||||||
|
#ifdef USE_LIBXML2
|
||||||
xml_done();
|
xml_done();
|
||||||
|
#endif
|
||||||
attrib_done();
|
attrib_done();
|
||||||
item_done();
|
item_done();
|
||||||
message_done();
|
message_done();
|
||||||
|
|
1
tolua
1
tolua
|
@ -1 +0,0 @@
|
||||||
Subproject commit 32cc6a3e78238278bc5b1fb8566526558e5afdda
|
|
Loading…
Reference in a new issue