Package Details: proton-ge-custom 2:GE.Proton9.22-1

Git Clone URL: https://aur.archlinux.org/proton-ge-custom.git (read-only, click to copy)
Package Base: proton-ge-custom
Description: Compatibility tool for Steam Play based on Wine and additional components, GloriousEggroll's custom build
Upstream URL: https://github.com/GloriousEggroll/proton-ge-custom
Keywords: dxvk proton steam valve vkd3d wine
Licenses: custom
Provides: proton
Submitter: loathingkernel
Maintainer: loathingkernel
Last Packager: loathingkernel
Votes: 41
Popularity: 3.11
First Submitted: 2020-03-23 23:52 (UTC)
Last Updated: 2024-12-30 14:02 (UTC)

Dependencies (117)

Required by (7)

Sources (12)

Pinned Comments

loathingkernel commented on 2023-10-12 10:43 (UTC) (edited on 2023-10-12 10:45 (UTC) by loathingkernel)

@rekman, thank you for looking into CUDA issues, at least it gives me an idea on how to fix it. That being said, my position remains to build it in a clean chroot, away from the locally installed packages. It is not feasible for me to carry patches for the build systems of various subprojects in the long run.

By enabling the 0003-AUR-Remove-kaldi-openfst-vosk-api-modules-because-of patch, you lose voice recognition which I assume is not that big of a loss as I haven't encountered a use for it, so I think it is an acceptable alternative.

patlefort commented on 2022-09-22 00:33 (UTC)

Compilation will fail if you happen to have jwasm installed, due to vulkan loader. Workaround: uninstall jwasm or add this line to prepape() in the PKGBUILD:

sed -i 's/VULKAN_LOADER_CMAKE_ARGS = -DUSE_MASM=OFF/VULKAN_LOADER_CMAKE_ARGS = -DUSE_MASM=OFF -DJWASM_FOUND=0/' "$srcdir/$pkgname/Makefile.in"

loathingkernel commented on 2020-11-21 10:28 (UTC) (edited on 2022-09-13 10:55 (UTC) by loathingkernel)

Notes about this package

  • If you encounter issues while using this package, please contact me here first before reporting an issue to the upstream repository.

  • Don't post logs, link to them. If you are using Manjaro, another derivative or an AUR helper, please mention it, I DO NOT TEST AGAINST THEM AND I CANNOT KNOW WHAT MIGHT BE WRONG WITH THE DISTRO/HELPER OF YOUR CHOICE.

  • It takes a LOT of time and space to build. Building with multiple jobs helps but might cause builds to fail in rare cases. Be sure to have at least 16GB of RAM if you are building on tmpfs

  • It is NOT built against Steam Linux Runtime (Sniper, Soldier, etc) and as such it doesn't require it. Still, is detected by Steam and works properly (preferable through steam-native).

  • This PKGBUILD uses CFLAGS, CXXFLAGS and LDFLAGS hardcoded in the PKGBUILD itself. By default it uses the same C[XX]FLAGS as upstream, namely -march=nocona and -mtune=core-avx2. To change them you will have to edit the PKGBUILD itself. Due to the nature of this package some flags can cause it to fail to build or not function properly. I try to filter them out but it is based on testing. If you have a feeling that compile-time options are involved in the issues you are having please include them in your comment. Currently the filtered options are -fstack-protector-{,-strong,-all}(dxvk and vkd3d only), -fno-plt, -z,relro, -z,now. Also the use of AVX instructions is disabled through -mno-avx.

  • If you are not using CFLAGS and CXXFLAGS specific to your system this package won't offer much in terms of performance as the upstream build flags already target the nocona (Core2) architecture. It will possibly perform worse than upstream. The only benefits you get is not depending on steam linux runtime as well as linking to Arch libraries. If you still want to build it, you can uncomment the relevant lines in the PKGBUILD to enable CFLAGS and CXXFLAGS similar to the upstream.

  • There have been reports with afdko failing to find its dependencies during building. I can't do anything about that as I don't maintain that package. It is NOT an issue with this package and I haven't found a way to not depend on it. Please don't report fails due to afdko (or any of its python- dependencies, they are pulled in due to afdko and only used by that), it has been discussed enough. There are possible workarounds in the comments.

  • It contains a patch to store game prefixes in the main Steam Library under $HOME/.local/share/Steam/steamapps/compatdata. It helps with isolation of game prefixes between users and works around issues with shared libraries on NTFS partitions due to drive symlinks. To enable it, set the PROTON_USER_COMPAT_DATA env variable to 1.

  • This package requires a Rust 32 bit target, please run rustup target install i686-unknown-linux-gnu BEFORE posting any issues if you're using rustup.

Latest Comments

« First ‹ Previous 1 .. 21 22 23 24 25 26 27 28 29 30 31 .. 34 Next › Last »

gyscos commented on 2021-05-18 15:29 (UTC) (edited on 2021-05-18 15:32 (UTC) by gyscos)

I guess openexr is an optional build dependency for the bundled gst-plugins-bad? (EDIT: seems like it) That'd be why if installed system-wide, gst-plugins-bad will try (and fail) to compile support for it, but it not installed, gst-plugins-bad will just skip it? In that case it may be better to force-disable this, rather than rely on auto-detection.

Though in my case after uninstalling openexr, building this package did go further, but failed building OpenXR-loader instead, with undefined references to std::experimental::filesystem. Will update later with the error message...

loathingkernel commented on 2021-05-17 21:00 (UTC)

There is no bundled version, at least not in the form of a submodule. This could be fixed in the latest version. I will look into updating to that once I have a bit of spare time. Downgrading is not an option as a few other things depend on it from the official repos.

gyscos commented on 2021-05-17 20:33 (UTC)

Does not seem to compile when openexr 3.0.1-2 (from the official repository) is installed.

../../proton-ge-custom/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp: At global scope:
../../proton-ge-custom/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp:45:11: error: ‘Int64’ does not name a type; did you mean ‘gint64’?
   45 |   virtual Int64 tellg ();
      |           ^~~~~
      |           gint64

(openexr 3.0 replaced Int64 with int64_t).

Should it try to compile using a bundled version?

superboringdev commented on 2021-04-28 21:15 (UTC) (edited on 2021-04-28 21:18 (UTC) by superboringdev)

Thanks. I changed it to -march=native -mtune=native -O3, I think that should be as good as it can get, right? -march=nocona -mtune=core-avx2 is pretty old

EDIT: I'm using an i7-4770 which is Haswell architecture.

loathingkernel commented on 2021-04-28 20:47 (UTC) (edited on 2021-04-28 20:50 (UTC) by loathingkernel)

Glad to hear it built correctly. The PKGBUILD is rather messy with the pinned versions and the global makeflags but it made me realize something I had forgot. Later on I have commented the CFLAGS and CXXFLAGS as specified by upstream. Since you are building with basic x86_64 as your -march you might want to enable them to be at least on par with that upstream in terms of performance.

superboringdev commented on 2021-04-28 20:39 (UTC)

Yup, I think I misinterpreted what the PKGBUILD was doing. Anyway, it finished building. Here's my dirty PKGBUILD, if that helps:

# Maintainer: loathingkernel <loathingkernel _a_ gmail _d_ com>

pkgname=proton-ge-custom
_srctag=6.4-GE-1
_commit=c595f7e8b1f3910185dba422d1a94599878f2bc5
pkgver=${_srctag//-/.}
_geckover=2.47.1
_monover=5.1.1
pkgrel=2
epoch=1
pkgdesc="Compatibility tool for Steam Play based on Wine and additional components. GloriousEggroll's custom build"
arch=(x86_64)
url="https://github.com/GloriousEggroll/proton-ge-custom"
license=('custom')
depends=(
  fontconfig      lib32-fontconfig
  lcms2           lib32-lcms2
  libxml2         lib32-libxml2
  libxcursor      lib32-libxcursor
  libxrandr       lib32-libxrandr
  libxdamage      lib32-libxdamage
  libpulse        lib32-libpulse
  gsm             lib32-gsm
  libxi           lib32-libxi
  gettext         lib32-gettext
  freetype2       lib32-freetype2
  glu             lib32-glu
  libsm           lib32-libsm
  gcc-libs        lib32-gcc-libs
  libpcap         lib32-libpcap
  desktop-file-utils
  python
  steam-native-runtime
  cabextract
)
makedepends=(autoconf ncurses bison perl fontforge flex mingw-w64-gcc
  mingw-w64-tools
  meson
  cargo
  rust                  lib32-rust-libs
  giflib                lib32-giflib
  libpng                lib32-libpng
  gnutls                lib32-gnutls
  libxinerama           lib32-libxinerama
  libxcomposite         lib32-libxcomposite
  libxmu                lib32-libxmu
  libxxf86vm            lib32-libxxf86vm
  libldap               lib32-libldap
  mpg123                lib32-mpg123
  openal                lib32-openal
  v4l-utils             lib32-v4l-utils
  libpulse              lib32-libpulse
  alsa-lib              lib32-alsa-lib
  libxcomposite         lib32-libxcomposite
  mesa                  lib32-mesa
  mesa-libgl            lib32-mesa-libgl
  opencl-icd-loader     lib32-opencl-icd-loader
  libxslt               lib32-libxslt
  gst-plugins-base-libs lib32-gst-plugins-base-libs
  vulkan-icd-loader     lib32-vulkan-icd-loader
  sdl2                  lib32-sdl2
  libgphoto2
  sane
  gsm
  vulkan-headers
  samba
  opencl-headers
  git
  cmake
  python-virtualenv
  python-pip
  nasm
  glslang
)
optdepends=(
  giflib                lib32-giflib
  libpng                lib32-libpng
  libldap               lib32-libldap
  gnutls                lib32-gnutls
  mpg123                lib32-mpg123
  openal                lib32-openal
  v4l-utils             lib32-v4l-utils
  alsa-plugins          lib32-alsa-plugins
  alsa-lib              lib32-alsa-lib
  libjpeg-turbo         lib32-libjpeg-turbo
  libxcomposite         lib32-libxcomposite
  libxinerama           lib32-libxinerama
  opencl-icd-loader     lib32-opencl-icd-loader
  libxslt               lib32-libxslt
  gst-plugins-base-libs lib32-gst-plugins-base-libs
  sdl2                  lib32-sdl2
  speex                 lib32-speex
  opus                  lib32-opus
  libgphoto2
  sane
  gsm
  cups
  samba           dosbox
)
makedepends=(${makedepends[@]} ${depends[@]})
#install=${pkgname}.install
source=(
    proton-ge-custom::git+https://github.com/xdevs23/proton-ge-custom.git#commit=${_commit}
    wine::git://source.winehq.org/git/wine.git#commit=41df83c50e1c3cfdd6e8ffb65de7838f8503632c
    wine-staging::git+https://github.com/wine-staging/wine-staging.git#commit=f8b6fde40c2cafda9ffedd0944065177952a16d4
    vkd3d-proton::git+https://github.com/HansKristian-Work/vkd3d-proton.git#commit=b7dfa99e57c8ddad83b513bdc843ccb4c0860d95
    dxvk::git+https://github.com/doitsujin/dxvk.git#commit=cf4ff820be2354efa30aa19a655643b908d6622d
    openvr::git+https://github.com/ValveSoftware/openvr.git#commit=52065df3d6f3af96300dac98cdf7397f26abfcd7
    OpenXR-SDK::git+https://github.com/KhronosGroup/OpenXR-SDK.git#commit=5197afbf199c026eca82a47a8573ed10b0c6fa4e
    ffmpeg::git+https://git.ffmpeg.org/ffmpeg.git#commit=192d1d34eb3668fa27f433e96036340e1e5077a0
    liberation-fonts::git+https://github.com/liberationfonts/liberation-fonts.git
    SPIRV-Headers::git+https://github.com/KhronosGroup/SPIRV-Headers.git
    Vulkan-Headers::git+https://github.com/KhronosGroup/Vulkan-Headers.git
    dxil-spirv::git+https://github.com/HansKristian-Work/dxil-spirv.git
    FAudio::git+https://github.com/FNA-XNA/FAudio.git#commit=920d2228c982f9a2f97276f2e51fbf8ed507963c
    protonfixes-gloriouseggroll::git+https://github.com/gloriouseggroll/protonfixes.git#commit=7ed0543bb118094cf10a61364b7917127f855187
    lsteamclient-gloriouseggroll::git+https://github.com/gloriouseggroll/lsteamclient.git#commit=f5e6dde79cdb255df2c78649db064587cc7f395f
    vrclient_x64-gloriouseggroll::git+https://github.com/gloriouseggroll/vrclient_x64.git#commit=efa15adf7c41b35d8541c346e8a1bfd800428d0a
    gstreamer::git+https://gitlab.freedesktop.org/gstreamer/gstreamer.git#commit=a42fe476d3ee5576921f67a331464065ec33b9a4
    gst-orc::git+https://gitlab.freedesktop.org/gstreamer/orc.git#commit=629864f073ae003e63c026c1de2407fec713cb53
    gst-plugins-base::git+https://gitlab.freedesktop.org/gstreamer/gst-plugins-base.git#commit=2cc319ee13f6b72df3d432b7c75aca81feb260e5
    gst-plugins-good::git+https://gitlab.freedesktop.org/gstreamer/gst-plugins-good.git#commit=e816c6cd73c9e0676828c9e227a049ebad3d019f
    gst-plugins-bad::git+https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad.git#commit=382e373d9be363f1e21b12990a4d12f1ecb6df41
    gst-plugins-ugly::git+https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly.git#commit=ad60e5463f591caa1c8470f180fd0ef8fce4a802
    gst-libav::git+https://gitlab.freedesktop.org/gstreamer/gst-libav.git#commit=67fc1e5c6c5e578dce250ae6310de71a0f5f8ec3
    https://dl.winehq.org/wine/wine-gecko/${_geckover}/wine-gecko-${_geckover}-x86{,_64}.tar.bz2
    https://github.com/madewokherd/wine-mono/releases/download/wine-mono-${_monover}/wine-mono-${_monover}-x86.tar.xz
    proton-unfuck_makefile.patch
    proton-disable_lock.patch
    proton-user_compat_data.patch
    dxvk-extraopts.patch
    vkd3d-extraopts.patch
    patches-remove_leftover_patch.patch
)
noextract=(
    wine-gecko-${_geckover}-{x86,x86_64}.tar.bz2
    wine-mono-${_monover}-x86.tar.xz
)

#-- Compiler and Linker Flags
#CPPFLAGS=""
CFLAGS="-march=x86-64 -mtune=native -O3 -pipe -fcf-protection"
CXXFLAGS="$CFLAGS"
LDFLAGS="-Wl,-O1,--sort-common,--as-needed"
#RUSTFLAGS="-C opt-level=2"
#-- Make Flags: change this for DistCC/SMP systems
#MAKEFLAGS="-j2"
#-- Debugging flags
DEBUG_CFLAGS="-g -fvar-tracking-assignments"
DEBUG_CXXFLAGS="-g -fvar-tracking-assignments"
#DEBUG_RUSTFLAGS="-C debuginfo=2"

prepare() {
    # I know this is fugly and it should NOT be done
    # but the afdko package from AUR breaks regularly.
    # Install it from pip in a virtualenv
    virtualenv --app-data "$srcdir"/afdko/cache --no-wheel afdko
    source afdko/bin/activate
    pip install --no-cache-dir afdko

    [ ! -d gecko ] && mkdir gecko
    mv wine-gecko-${_geckover}-x86{,_64}.tar.bz2 gecko/

    [ ! -d mono ] && mkdir mono
    mv wine-mono-${_monover}-x86.tar.xz mono/

    [ ! -d build ] && mkdir build
    cd proton-ge-custom
    for submodule in ffmpeg openvr OpenXR-SDK fonts/liberation-fonts FAudio vkd3d-proton; do
        git submodule init "${submodule}"
        git config submodule."${submodule}".url "$srcdir"/"${submodule#*/}"
        git submodule update "${submodule}"
    done

    for submodule in wine wine-staging dxvk; do
        git submodule init "${submodule}"
        git config submodule."${submodule}".url "$srcdir"/"${submodule#*/}"
        git submodule update "${submodule}"
    done

    for submodule in gstreamer gst-{plugins-{base,good,bad,ugly},libav,orc}; do
        git submodule init "${submodule}"
        git config submodule."${submodule}".url "$srcdir"/"${submodule#*/}"
        git submodule update "${submodule}"
    done

    pushd vkd3d-proton
    for submodule in subprojects/{dxil-spirv,Vulkan-Headers,SPIRV-Headers}; do
        git submodule init "${submodule}"
        git config submodule."${submodule}".url "$srcdir"/"${submodule#*/}"
        git submodule update "${submodule}"
    done
    pushd subprojects/dxil-spirv
    git submodule init third_party/spirv-headers
    git config submodule.third_party/spirv-headers.url "$srcdir"/SPIRV-Headers
    git submodule update third_party/spirv-headers
    popd
    popd

    for submodule in lsteamclient vrclient_x64 protonfixes; do
        git submodule init "${submodule}"
        git config submodule."${submodule}".url "$srcdir"/"${submodule#*/}-gloriouseggroll"
        git submodule update "${submodule}"
    done

    patch -p1 -i "$srcdir"/patches-remove_leftover_patch.patch
    ./patches/protonprep-nofshack.sh

    patch -p1 -i "$srcdir"/proton-unfuck_makefile.patch
    patch -p1 -i "$srcdir"/proton-disable_lock.patch
    patch -p1 -i "$srcdir"/proton-user_compat_data.patch

    # Export CFLAGS used by upstream if building for redistribution
    # -O2 is adjusted to -O3 since AVX is disabled
#    export CFLAGS="-O3 -march=nocona -mtune=core-avx2"
#    export CXXFLAGS="-O3 -march=nocona -mtune=core-avx2"

    # Uncomment to enable extra optimizations
    # Patch crossfiles with extra optimizations from makepkg.conf
    patch -p1 -i "$srcdir"/dxvk-extraopts.patch
    patch -p1 -i "$srcdir"/vkd3d-extraopts.patch
    local dxvk_cflags="$CFLAGS"
    local dxvk_ldflags="$LDFLAGS"
    # Filter known bad flags before applying optimizations
    # Filter fstack-protector{ ,-all,-strong} flag for MingW.
    # https://github.com/Joshua-Ashton/d9vk/issues/476
    dxvk_cflags="${dxvk_cflags// -fstack-protector*([\-all|\-strong])/}"
    # Doesn't compile with these flags in MingW so remove them.
    # They are also filtered in Wine PKGBUILDs so remove them
    # for winelib versions too.
    dxvk_cflags="${dxvk_cflags/ -fno-plt/}"
    dxvk_ldflags="${dxvk_ldflags/,-z,now/}"
    dxvk_ldflags="${dxvk_ldflags/,-z,relro/}"
    # If using -march=native and the CPU supports AVX, launching a d3d9
    # game can cause an Unhandled exception. The cause seems to be the
    # combination of AVX instructions and tree vectorization (implied by O3),
    # all tested archictures from sandybridge to haswell are affected.
    # Disabling AVX (and AVX2 as a side-effect).
    # Since Wine 5.16 AVX is supported. Testing showed 32bit applications
    # crashing with AVX regardless, but 64bit applications worked just fine.
    # So disable AVX only for the 32bit binaries and AVX2 for the 64bit.
    # AVX2 seems to degrade performance. So disregard the above.
    # Relevant Wine issues
    # https://bugs.winehq.org/show_bug.cgi?id=45289
    # https://bugs.winehq.org/show_bug.cgi?id=43516
    dxvk64_cflags="$dxvk_cflags -mno-avx"
    dxvk32_cflags="$dxvk_cflags -mno-avx"

    sed -i dxvk/build-win64.txt \
        -e "s|@CARGS@|\'${dxvk64_cflags// /\',\'}\'|g" \
        -e "s|@LDARGS@|\'${dxvk_ldflags// /\',\'}\'|g"
    sed -i dxvk/build-win32.txt \
        -e "s|@CARGS@|\'${dxvk32_cflags// /\',\'}\'|g" \
        -e "s|@LDARGS@|\'${dxvk_ldflags// /\',\'}\'|g"
    sed -i vkd3d-proton/build-win64.txt \
        -e "s|@CARGS@|\'${dxvk64_cflags// /\',\'}\'|g" \
        -e "s|@LDARGS@|\'${dxvk_ldflags// /\',\'}\'|g"
    sed -i vkd3d-proton/build-win32.txt \
        -e "s|@CARGS@|\'${dxvk32_cflags// /\',\'}\'|g" \
        -e "s|@LDARGS@|\'${dxvk_ldflags// /\',\'}\'|g"
}

build() {
    cd build
    ../proton-ge-custom/configure.sh \
        --steam-runtime=native \
        --no-steam-runtime \
        --with-ffmpeg \
        --build-name="${pkgname}"

    # Use -mno-avx for wine too
    # https://bugs.winehq.org/show_bug.cgi?id=45289
    # https://bugs.winehq.org/show_bug.cgi?id=43516
    export CFLAGS+=" -mno-avx"
    export CXXFLAGS+=" -mno-avx"
    # From wine-staging PKGBUILD
    # Doesn't compile without remove these flags as of 4.10
    export CFLAGS="${CFLAGS/ -fno-plt/}"
    export CXXFLAGS="${CXXFLAGS/ -fno-plt/}"
    export LDFLAGS="${LDFLAGS/,-z,now/}"
    # MingW Wine builds fail with relro
    export LDFLAGS="${LDFLAGS/,-z,relro/}"

    export WINEESYNC=0
    export WINEFSYNC=0
    export CARGO_HOME="$srcdir/build/cargo"
    SUBMAKE_JOBS="${MAKEFLAGS/-j/}" \
        SYSTEM_GECKO=0 \
        SYSTEM_MONO=0 \
        make -j1 dist
}

package() {
    cd build

    local _compatdir="$pkgdir/usr/share/steam/compatibilitytools.d"
    mkdir -p "$_compatdir"
    cp -rf --no-dereference --preserve=mode,links dist "$_compatdir/${pkgname}"

    mkdir -p "$pkgdir/usr/share/licenses/${pkgname}"
    mv "$_compatdir/${pkgname}"/LICENSE{,.OFL} \
        "$pkgdir/usr/share/licenses/${pkgname}"

    cd "$_compatdir/${pkgname}/dist"
    i686-w64-mingw32-strip --strip-unneeded \
        $(find lib/wine -iname "*.dll" -or -iname "*.exe")
    x86_64-w64-mingw32-strip --strip-unneeded \
        $(find lib64/wine -iname "*.dll" -or -iname "*.exe")

    local _geckodir="share/wine/gecko/wine-gecko-${_geckover}"
    i686-w64-mingw32-strip --strip-unneeded \
        $(find "$_geckodir"-x86 -iname "*.dll" -or -iname "*.exe")
    x86_64-w64-mingw32-strip --strip-unneeded \
        $(find "$_geckodir"-x86_64 -iname "*.dll" -or -iname "*.exe")

    local _monodir="share/wine/mono/wine-mono-${_monover}"
    i686-w64-mingw32-strip --strip-unneeded \
        $(find "$_monodir"/lib/mono -iname "*.dll" -or -iname "*.exe")
    i686-w64-mingw32-strip --strip-unneeded \
        "$_monodir"/lib/x86/*.dll \
        $(find "$_monodir" -iname "*x86.dll" -or -iname "*x86.exe")
    x86_64-w64-mingw32-strip --strip-unneeded \
        "$_monodir"/lib/x86_64/*.dll \
        $(find "$_monodir" -iname "*x86_64.dll" -or -iname "*x86_64.exe")
}

sha256sums=('SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            'SKIP'
            '06a00cedf391ee07bbca0b3282e5c8ad9d950446d50648d2ff417716816fd1ab'
            'ea5246e4c91d1aa1226658e1749b6e5d0e9353b52b14df79c4b93b6e61a3c59e'
            'b17ac815afbf5eef768c4e8d50800be02af75c8b230d668e239bad99616caa82'
            '1f376915e7c47107ae21479e4f56017a2324558ed22f2a7a9b9dd63c0062a1c1'
            '8263a3ffb7f8e7a5d81bfbffe1843d6f84502d3443fe40f065bcae02b36ba954'
            '20f7cd3e70fad6f48d2f1a26a485906a36acf30903bf0eefbf82a7c400e248f3'
            '23cba1756adc4a76de963414994ffc964047ab1d6f1949fe8133135a91ac0473'
            '7c5f9c20e41c0cd7d0d18867950a776608cef43e0ab9ebad2addb61e613fe17a'
            '28818da77650aa45d655f84900b3fc33f8f4b40a4133b301069a8753a18f3e3b'
)

Yes, I've added the CFLAGS etc. in here even though that's not how you're supposed to do it.

loathingkernel commented on 2021-04-28 20:04 (UTC) (edited on 2021-04-28 20:07 (UTC) by loathingkernel)

This is how submodule update works.

I don't know if -fcf-protection will cause issues. I am still on my previous CFLAGS. Hopefully it won't.

superboringdev commented on 2021-04-28 19:53 (UTC)

Thanks.

From the looks of it, it appears as though the PKGBUILD is cloning the submodules and placing them in the tree manually. Just to be sure, I have pinned as many as I could to what the upstream specifies.

As for the flags, I have removed some of them.

Before:

#CPPFLAGS=""
CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions \
        -Wp,-D_FORTIFY_SOURCE=2,-D_GLIBCXX_ASSERTIONS \
        -Wformat -Werror=format-security \
        -fstack-clash-protection -fcf-protection"
CXXFLAGS="$CFLAGS"
LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now"
#RUSTFLAGS="-C opt-level=2"
#-- Make Flags: change this for DistCC/SMP systems
#MAKEFLAGS="-j2"
#-- Debugging flags
DEBUG_CFLAGS="-g -fvar-tracking-assignments"
DEBUG_CXXFLAGS="-g -fvar-tracking-assignments"
#DEBUG_RUSTFLAGS="-C debuginfo=2"

After:

#-- Compiler and Linker Flags
#CPPFLAGS=""
CFLAGS="-march=x86-64 -mtune=native -O2 -pipe -fcf-protection"
CXXFLAGS="$CFLAGS"
LDFLAGS="-Wl,-O1,--sort-common,--as-needed"
#RUSTFLAGS="-C opt-level=2"
#-- Make Flags: change this for DistCC/SMP systems
#MAKEFLAGS="-j2"
#-- Debugging flags
DEBUG_CFLAGS="-g -fvar-tracking-assignments"
DEBUG_CXXFLAGS="-g -fvar-tracking-assignments"
#DEBUG_RUSTFLAGS="-C debuginfo=2"

I hope this is enough. Back to building and I'll report if it works.

loathingkernel commented on 2021-04-28 19:44 (UTC) (edited on 2021-04-28 19:53 (UTC) by loathingkernel)

The dependencies are already pinned in specific commits as they are specified by upstream. That is how git submodules work. Your issue has to do with the new CFLAGS from arch if you look a bit above in your log. The same issue exists in plain wine. It doesn't like _FORTIFY_SOURCE being redefined. I myself still expecting to see how they will handle such issues in the official wine package to update this.

superboringdev commented on 2021-04-28 19:18 (UTC) (edited on 2021-04-28 19:46 (UTC) by superboringdev)

I can't seem to get anything to build. Official GE instructions (with Vagrant) fail, this one fails, too, even in a chroot:

gcc -m64 -c -o tools/widl/header.o ../../proton-ge-custom/wine/tools/widl/header.c -Itools/widl \
  -I../../proton-ge-custom/wine/tools/widl -Iinclude -I../../proton-ge-custom/wine/include \
  -D__WINESRC__ -Wall -pipe -fcf-protection=none -fno-stack-protector -fno-strict-aliasing \
  -Wdeclaration-after-statement -Wempty-body -Wignored-qualifiers -Winit-self \
  -Wno-packed-not-aligned -Wshift-overflow=2 -Wstrict-prototypes -Wtype-limits \
  -Wunused-but-set-parameter -Wvla -Wwrite-strings -Wpointer-arith -Wlogical-op -gdwarf-2 \
  -gstrict-dwarf -I/build/proton-ge-custom/src/build/obj-tools64/include -g -march=x86-64 -mtune=generic -O2 -pipe -fexceptions         -Wp,-D_FORTIFY_SOURCE=2,-D_GLIBCXX_ASSERTIONS         -Wformat -Werror=format-security         -fstack-clash-protection -fcf-protection -mno-avx -mfpmath=sse -fwrapv -fno-strict-aliasing -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0
<command-line>: warning: "_FORTIFY_SOURCE" redefined
<command-line>: note: this is the location of the previous definition
during RTL pass: final
../../proton-ge-custom/wine/dlls/winecrt0/exception.c: In function ‘unwind_frame’:
../../proton-ge-custom/wine/dlls/winecrt0/exception.c:93:1: internal compiler error: in seh_emit_stackalloc, at config/i386/winnt.c:1043
   93 | }
      | ^
Please submit a full bug report,
with preprocessed source if appropriate.
See <https://bugs.archlinux.org/> for instructions.
{standard input}: Assembler messages:
{standard input}: Error: open CFI at the end of file; missing .cfi_endproc directive
make[2]: *** [Makefile:255303: dlls/winecrt0/exception.cross.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory '/build/proton-ge-custom/src/build/obj-wine64'
make[1]: *** [../proton-ge-custom/build/makefile_base.mak:1740: wine64-intermediate] Error 2
make[1]: Leaving directory '/build/proton-ge-custom/src/build'
make: *** [../proton-ge-custom/build/makefile_base.mak:17: nested_make] Error 2

Will attempt to pin the dependencies to specific commits and see if that helps...

EDIT: should be important to say that I'm trying to build 6.4. I did a git hard reset to achieve this.