2023-12-20 21:37:41 +00:00
|
|
|
#!/bin/bash -e
|
|
|
|
|
2022-08-09 09:29:02 +00:00
|
|
|
if [ ! -f /.dockerenv ] && [ ! -f /home/docs/omw_luadoc_docker ]; then
|
|
|
|
echo 'This script installs lua-5.1, luarocks, and openmwluadocumentor to $HOME. Should be used only in docker.'
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
echo "Install lua 5.1"
|
|
|
|
cd ~
|
|
|
|
curl -R -O https://www.lua.org/ftp/lua-5.1.5.tar.gz
|
|
|
|
tar -zxf lua-5.1.5.tar.gz
|
|
|
|
rm lua-5.1.5.tar.gz
|
|
|
|
cd lua-5.1.5/
|
|
|
|
make linux
|
|
|
|
cd ~
|
|
|
|
PATH=$PATH:~/lua-5.1.5/src
|
|
|
|
|
|
|
|
echo "Install luarocks"
|
2023-01-27 18:53:10 +00:00
|
|
|
luarocksV="3.9.2"
|
|
|
|
wget https://luarocks.org/releases/luarocks-$luarocksV.tar.gz
|
|
|
|
tar zxpf luarocks-$luarocksV.tar.gz
|
|
|
|
rm luarocks-$luarocksV.tar.gz
|
|
|
|
cd luarocks-$luarocksV/
|
2022-08-09 09:29:02 +00:00
|
|
|
./configure --with-lua-bin=$HOME/lua-5.1.5/src --with-lua-include=$HOME/lua-5.1.5/src --prefix=$HOME/luarocks
|
|
|
|
make build
|
|
|
|
make install
|
|
|
|
cd ~
|
2023-01-27 18:53:10 +00:00
|
|
|
rm -r luarocks-$luarocksV
|
2022-08-09 09:29:02 +00:00
|
|
|
PATH=$PATH:~/luarocks/bin
|
|
|
|
|
|
|
|
echo "Install openmwluadocumentor"
|
|
|
|
git clone https://gitlab.com/ptmikheev/openmw-luadocumentor.git
|
2023-02-11 11:51:43 +00:00
|
|
|
cd openmw-luadocumentor
|
2023-12-23 13:23:12 +00:00
|
|
|
git checkout 78577b255d19a1f4f4f539662e00357936b73c33
|
2023-02-11 11:51:43 +00:00
|
|
|
luarocks make luarocks/openmwluadocumentor-0.2.0-1.rockspec
|
2022-08-09 09:29:02 +00:00
|
|
|
cd ~
|
|
|
|
rm -r openmw-luadocumentor
|