-
-
Notifications
You must be signed in to change notification settings - Fork 466
[EN] How to build and setup on Linux
Make sure you are using S.T.A.L.K.E.R.: Call Of Pripyat 1.6.02, your system supports OpenGL 4.1 and has the following packages: git, cmake, GLEW, FreeImage, FreeImagePlus, Lockfile, OpenAL, TBB, Crypto++, Theora, Ogg, SDL2, LZO, Jpeg.
To install this software in Debian, Ubuntu, and their derivatives run the command:
sudo apt install git cmake libglew-dev libfreeimage-dev libfreeimageplus-dev liblockfile-dev libopenal-dev libtbb-dev libcrypto++-dev libogg-dev libtheora-dev libvorbis-dev libsdl2-dev liblzo2-dev libjpeg-dev libreadline-dev
In case you are Fedora user:
sudo dnf install git cmake glew-devel freeimage-devel freeimage-plus-devel liblockfile-devel openal-devel tbb-devel cryptopp-devel libogg-devel libtheora-devel libvorbis-devel SDL2-devel lzo-devel libjpeg-turbo-devel readline-devel
For Arch Linux:
sudo pacman -S gcc git cmake make libglvnd libjpeg6-turbo ncurses pcre2 pcre glew sdl2 openal intel-tbb crypto++ liblockfile freeimage libogg libtheora libvorbis lzo lzop libjpeg-turbo
For Gentoo:
sudo emerge --ask gcc git cmake make libglvnd libjpeg-turbo ncurses libpcre2 libpcre glew libsdl2 media-libs/openal tbb crypto++ liblockfile freeimage libogg libtheora libvorbis lzo lzop
Then clone the repository with its submodules:
git clone https://github.com/OpenXRay/xray-16.git --recursive
After this, the xray-16 directory should appear in the working directory. You need to create the build directory and go there:
cd xray-16 && mkdir bin && cd bin
Then configure the build directory by running this command. Please pay attention to its output. It will contain errors if some of the requirements were not properly installed.
cmake ..
You can customize the build by adding some options to configuration command.
To enable debugging:
cmake .. -DCMAKE_BUILD_TYPE=RelWithDebInfo
Or
cmake .. -DCMAKE_BUILD_TYPE=Debug
To use clang:
Clang is not supported, but feel free to try it:
CC=clang CXX=clang++ cmake ..
To include all optimizations for your machine:
CFLAGS="-march=native" CXXFLAGS="-march=native" cmake ..
Then, to build the project, run this command.
make -jX
Replace X with the number of your processor's cores
To put the log and errors to different files:
make -jX >out.log 2>error.log
To install the binaries without making a package, run:
make install
Alternatively, a .deb
package can be created to install via dpkg
make package
sudo dpkg -i openxray_1.6.02_amd64.deb
Before running, put game resources in ~/.local/share/GSC Game World/S.T.A.L.K.E.R. - Call of Pripyat/,
e.g. via steamcmd
:
steamcmd "+@sSteamCmdForcePlatformType windows" +login <your_steam_username> \
+force_install_dir ~/.local/share/GSC Game World/S.T.A.L.K.E.R. - Call of Pripyat/ +app_update 41700 +quit
Start the game by running this command:
xr_3da
Or, if game resources are located in another place:
xr_3da -fsltx <path/to/>/fsgame.ltx
Or if you want to debug with gdb:
DEBUGGER="gdb --ex=r --args" xr_3da
If you have a S.T.A.L.K.E.R.: Call Pripyat windows installer, e.g. if you have a
CD or the GOG version, you can run wine setup.exe
to start the installation.
You may have issues if you're installing to a path that has spaces, so we
recommend you to install it to c:\cop
(it's usually ~/.wine/drive_c/cop
in
linux).
If you are using GOG version then you should rename the Localization
directory
to localization
, otherwise you will face the issue #684.
If you are using Russian version, you need to install patch 1.6.02. You can download it from the official page.
If you're using Steam, you can find the resources in
{STEAM_DIR}/steamapps/common/Stalker - Call of Pripyat
(if you did not manually install it in different directory).
Home
English
- Русский
- Українська
- Беларуская
- Polski
- Český