Skip to content

Building from Source

Tyler Wilding edited this page Jan 17, 2018 · 3 revisions

If you encounter any issues after following these steps or want more information, take a look at the steps on the official PCSX2 wiki - https://wiki.pcsx2.net/PCSX2_Documentation/Compiling_on_Windows

Dependencies

  • Make sure to remove any existing Microsoft Visual C++ 2010 Redistributable Packages installations before attempting to install the SDK

Additional Components Required from Visual Studio Installer

  • Desktop Development with C++ (Workload not an Individual Component)
    • Because PCSX2 is largely a C++ repo, we will require the C++ libraries and headers
  • Windows 8.1 SDK and UCRT SDK
    • Because PCSX2 targets Windows 8.1 at this time, we will stick with that, and so we require the Windows 8.1 SDK as well

Building from Source

Please note that using the debug versions of the plugins adds a massive amount of overhead to PCSX2 and it will run incredibly slowly. If you are experiencing very slow performance when running the build version, check to make sure you are not using *-dbg plugins.

Additionally, if you have no interest in debugging the plugins themselves then you can build using the Debug configuration and use the normal release version plugins when configuring PCSX2.

Getting the Repository

A recursive clone is required as there is a 3rdparty submodule https://github.com/PCSX2/xz that must also be pulled down. To do this, clone the repository like so:

git clone --recursive https://github.com/xTVaser/pcsx2-rr.git (or your fork's URL)

Building Steps

  1. Open PCSX2_suite.sln with Visual Studio 2017
  2. Select either the Debug or the Release configuration.
  3. Build > Build Solution
    1. If you have done a previous build with a different configuration and run into problems it might be a good idea to run Build > Rebuild Solution, or even Clean Solution.
    2. This will take a substantial amount of time if it is your first compilation, small changes will result in a much more minimal build after this initial one

Once complete you can run the exe directly from the /bin folder, or run it via Visual Studio

Contributing

Please develop either on rr-dev or branch off of rr-dev. Do not commit directly to master...submit a pull request to merge into master instead.

Debug or Release Config?

The debug config is more or less exactly the same as the release config with the exception that it excludes all compiler optimizations so full debugging of the source code is possible.

The debug config will also build the *-dbg versions of the plugins and pcsx2 binaries/dlls.

Excluding Plugins from the Build

By default, all necessary plugins are configured to be built from source. To exclude some plugins from being built or to check if they are being built:

Right click the Solution > Properties > Project Dependencies > and uncheck or check the boxes for the 'pcsx2' project.