Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add experimental support for DXVK-native on Linux #1323

Merged
merged 2 commits into from
Jun 7, 2024
Merged

Conversation

Sanakan8472
Copy link
Contributor

This allows compiling the DX11 renderer on Linux. The main goal is to make it easier to make renderer changes on Linux without having to boot Windows. To use:

  1. Clone DXVK
  2. Change meson.build to lib_glfw = dependency('glfw3', required: false) instead of just 'glfw'.
  3. Run ./package-native.sh master ~/libDXVK --no-package
  4. export PKG_CONFIG_PATH="~/libDXVK/dxvk-native-master/usr/lib/pkgconfig"
  5. Enable EZ_BUILD_EXPERIMENTAL_DXVK

Note that you won't be able to run this without considerable effort so right now it's merely to make sure the code compiles:

  1. There is no shader compiler so if you want to run DX11, you need to get a shader cache from a Windows machine or from the Windows CI build artifacts.
  2. We conflict between two GLFW versions as EZ does not use the system version but DXVK does. You can delete our version and replace it with the system version but it's tedious.
  3. For some reason you can't load two renderers at the same time under Linux. Sub-system init for DX11 is simply skipped. Can't figure out why.
  4. Latest release of dxvk has a bug, so you need to apply at least this patch: Fixed GLFW exception at startup doitsujin/dxvk#4061
  5. You need to set the env var DXVK_WSI_DRIVER=GLFW before running any app.

Sanakan8472 and others added 2 commits June 6, 2024 19:09
This allows compiling the DX11 renderer on Linux. The main goal is to make it easier to make renderer changes on Linux without having to boot Windows. To use:
1. Clone DXVK
1. Run `./package-native.sh master ~/libDXVK --no-package`
1. `export PKG_CONFIG_PATH="~/libDXVK/dxvk-native-master/usr/lib/pkgconfig"
1. Enable `EZ_BUILD_EXPERIMENTAL_DXVK`

Note that there is no shader compiler so if you want to run DX11, you need to get a shader cache from a Windows machine or from the Windows CI build artifacts.
Copy link
Member

@jankrassnigg jankrassnigg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds like great fun.

@Sanakan8472
Copy link
Contributor Author

Sounds like great fun.

Anything is more fun than having to boot windows all the time...

@Sanakan8472 Sanakan8472 merged commit 0308efe into dev Jun 7, 2024
12 of 13 checks passed
@Sanakan8472 Sanakan8472 deleted the user/cm/DXVK branch June 7, 2024 10:19
@jankrassnigg jankrassnigg added the dev work Individual steps of larger tasks. label Aug 11, 2024
@jankrassnigg jankrassnigg added this to the Next Release milestone Aug 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dev work Individual steps of larger tasks.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants