diff --git a/README.md b/README.md index 884eeca62..0b7bb381a 100644 --- a/README.md +++ b/README.md @@ -95,27 +95,61 @@ directory containing noggit.exe, i.e. `CMAKE_INSTALL_PREFIX` configured. * If using scripting, you will also need to copy `/src/lua51.dll` to `CMAKE_INSTALL_PREFIX` ## Linux ## + +These instructions assume a working directory ``, for example `/home/myuser/` + +### Dependencies ### + On **Ubuntu** you can install the building requirements using: ```bash -sudo apt install freeglut3-dev libboost-all-dev qt5-default libstorm-dev +sudo apt install freeglut3-dev libboost-all-dev qt5-default libsdl2-dev libbz2-dev +``` + +### LuaJIT ### + +From ``, build luajit using: +```bash +git clone https://luajit.org/git/luajit.git +cd luajit +make +cd .. +``` + +`/luajit` should now exist. + +### Build Noggit ### + +From ``, clone Noggit3 (change repo as needed): +```bash +git clone https://github.com/wowdev/noggit3 ``` -Compile and build using: +`/noggit3` should now exist. + +From ``, compile and build using the following commands. +Note that `` should be written as the **full** path in the commands below. +For example: `cmake -DLUA_LIBRARIES=/home/myuser/luajit/src/libluajit.so -DLUA_INCLUDE_DIR=/home/myuser/luajit/src ../noggit3` ```bash mkdir build cd build -cmake .. +cmake -DLUA_LIBRARIES=/luajit/src/libluajit.so -DLUA_INCLUDE_DIR=/luajit/src ../noggit3 make -j $(nproc) ``` Instead of `make -j $(nproc)` you may want to pick a bigger number than `$(nproc)`, e.g. the number of `CPU cores * 1.5`. -If the build pass correctly without errors, you can go into build/bin/ -and run noggit. Note that `make install` will probably work but is not -tested, and nobody has built distributable packages in years. +From `/build`, if the build pass correctly without errors, you can finish the installation using: +```bash +cp -r ../noggit3/scripts ./bin/scripts +cp ../luajit/src/libluajit.a ./bin/libluajit.a +``` + +You can now go into `/build/bin` and run noggit. + +Note that `make install` will probably not work. # Building the Scripting documentation # To generate the scripting API documentation, install any new version of Node.js and run: