Automate installation of DXVK, D9VK + Wine/Wine Staging & update GPU drivers + PlayonLinux wineprefixes (Debian/Ubuntu/Mint/Arch Linux/Manjaro)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

168 lines
4.5 KiB

  1. ########################################################
  2. # Common properties
  3. pkg_name="dxvk-git"
  4. pkg_license="custom --copyrightfile ../LICENSE"
  5. pkg_maintainer="${USER} <${USER}@unknown>"
  6. pkg_section="otherosfs"
  7. pkg_priority="optional"
  8. pkg_arch="all"
  9. dxvx_relative_builddir="debian/source/dxvk-master"
  10. pkg_commondesc="Vulkan-based D3D11 and D3D10 implementation for Linux / Wine"
  11. pkg_longdesc="
  12. A Vulkan-based translation layer for Direct3D 10/11 which
  13. allows running 3D applications on Linux using Wine.
  14. "
  15. pkg_giturl="https://github.com/doitsujin/dxvk"
  16. pkg_homeurl="https://github.com/doitsujin/dxvk"
  17. git_commithash=${git_commithash_dxvk}
  18. pkg_gitver="git describe --long | sed 's/\-[a-z].*//; s/\-/\./; s/[a-z]//g'"
  19. pkg_installfile="./debian/install"
  20. pkg_controlfile="./debian/control"
  21. pkg_rulesfile="./debian/rules"
  22. ########################################################
  23. # Debian rules file section
  24. pkg_debrules="\
  25. #!/usr/bin/make -f
  26. %:
  27. dh \$@
  28. override_dh_auto_configure:
  29. override_dh_usrlocal:
  30. override_dh_install:
  31. # Compile DXVK
  32. bash ./package-release.sh master debian/source/ --no-package
  33. # Tell deb builder to create DXVK x32 & x64 subfolders
  34. for arch in 32 64; do mkdir -p ${dxvx_relative_builddir}/x${arch}; done
  35. # Make a proper executable script folder for setup_dxvk.verb file
  36. mkdir -p ${dxvx_relative_builddir}/bin
  37. echo -e \"#!/bin/sh\nwinetricks --force /usr/share/dxvk/setup_dxvk.verb\" > \"${dxvx_relative_builddir}/bin/setup_dxvk\"
  38. chmod +x "${dxvx_relative_builddir}/bin/setup_dxvk"
  39. dh_install
  40. "
  41. ########################################################
  42. # Debian install file section
  43. pkg_debinstall="\
  44. ${dxvx_relative_builddir}/setup_dxvk.verb usr/share/dxvk/
  45. ${dxvx_relative_builddir}/bin/* usr/bin/
  46. $(for arch in 32 64; do echo -e ${dxvx_relative_builddir}/x${arch}/* usr/share/dxvk/x${arch}/; done)
  47. "
  48. ########################################################
  49. # Debian control file subfields
  50. # Debian control file Overrides section
  51. pkg_overrides=(
  52. empty
  53. )
  54. # Debian control file Suggests section
  55. pkg_suggests=(
  56. empty
  57. )
  58. # Debian control file Conflicts section
  59. pkg_conflicts=(
  60. empty
  61. )
  62. # Debian control file Breaks section
  63. pkg_breaks=(
  64. empty
  65. )
  66. # Debian control file Replaces section
  67. pkg_replaces=(
  68. empty
  69. )
  70. # Debian control file Provides section
  71. pkg_provides=(
  72. empty
  73. )
  74. ############################
  75. # Build time dependencies
  76. pkg_deps_build=(
  77. #${_coredeps[*]}
  78. 'meson'
  79. 'glslang'
  80. 'gcc-mingw-w64-x86-64'
  81. 'gcc-mingw-w64-i686'
  82. 'g++-mingw-w64-x86-64'
  83. 'g++-mingw-w64-i686'
  84. 'mingw-w64-x86-64-dev'
  85. 'mingw-w64-i686-dev'
  86. )
  87. # Runtime dependencies
  88. pkg_deps_runtime=(
  89. 'wine'
  90. 'winetricks'
  91. )
  92. # Extra fields for Debian control file Source section
  93. pkg_extra_1=(
  94. empty
  95. )
  96. # Extra fields for Debian control file Package section
  97. pkg_extra_2=(
  98. empty
  99. )
  100. ############################
  101. # Deb builder execution field
  102. # Do not build either debug symbols or doc files
  103. pkg_debbuilder="DEB_BUILD_OPTIONS=\"strip nodocs noddebs\" dpkg-buildpackage -us -uc -b --source-option=--include-binaries"
  104. ########################################################
  105. # Contents of Debian control file
  106. # This is a necessary variable setting for array loops below
  107. IFS=$'\n'
  108. pkg_debcontrol="\
  109. Source: ${pkg_name}
  110. Section: ${pkg_section}
  111. Priority: ${pkg_priority}
  112. Maintainer: ${pkg_maintainer}
  113. Build-Depends: debhelper (>=9), $(if [[ ${pkg_deps_build[0]} != "empty" ]]; then \
  114. for w in ${pkg_deps_build[@]}; do printf '%s, ' ${w}; done; fi)
  115. Standards-Version: 4.1.3
  116. Homepage: ${pkg_homeurl}
  117. $(if [[ ${pkg_extra_1[0]} != "empty" ]]; then for w in ${pkg_extra_1[@]}; do echo ${w}; done ; fi)
  118. Package: ${pkg_name}
  119. Architecture: ${pkg_arch}
  120. Depends: \${shlibs:Depends}, \${misc:Depends}, $(if [[ ${pkg_deps_runtime[0]} != "empty" ]]; then \
  121. for w in ${pkg_deps_runtime[@]}; do printf '%s, ' ${w}; done; fi)
  122. Description: ${pkg_commondesc}
  123. $(echo -e ${pkg_longdesc} | sed 's/^/ /g; s/\n/\n /g')
  124. $(if [[ ${pkg_extra_2[0]} != "empty" ]]; then for w in ${pkg_extra_2[@]}; do echo ${w}; done ; fi)
  125. $(if [[ ${pkg_suggests[0]} != "empty" ]]; then echo "Suggests: $(echo ${_kg_suggests[*]} | sed 's/\s/, /g')"; fi)
  126. $(if [[ ${pkg_conflicts[0]} != "empty" ]]; then echo "Conflicts: $(echo ${pkg_overrides[*]} | sed 's/\s/, /g')"; fi)
  127. $(if [[ ${pkg_breaks[0]} != "empty" ]]; then echo "Breaks: $(echo ${pkg_overrides[*]} | sed 's/\s/, /g')"; fi)
  128. $(if [[ ${pkg_replaces[0]} != "empty" ]]; then echo "Replaces: $(echo ${pkg_overrides[*]} | sed 's/\s/, /g')"; fi)
  129. $(if [[ ${pkg_provides[0]} != "empty" ]]; then echo "Provides: $(echo ${pkg_overrides[*]} | sed 's/\s/, /g')"; fi)
  130. "
  131. unset IFS