Frogging-Family / wine-tkg-git

The wine-tkg build systems, to create custom Wine and Proton builds
840 stars 148 forks source link

Proton build issue on Garuda #1159

Closed IdrisKalp closed 2 months ago

IdrisKalp commented 2 months ago

System cannot install dependencies for Garuda, throwing error:

wine-tkg-git/wine-tkg-scripts/deps: line 686: _install_post_garuda: no command

Adding this piece at line 60 on wine-tkg-scripts/deps script fixes:

if [[ "${_os}" == "garuda" ]]; then _os="arch" fi

v1993 commented 2 months ago

I ran into the same problem on Manjaro and another person on CachyOS. I think the better fix for this would be checking for field ID_LIKE from /etc/os-release, something like

_os_name() {
  local _os, _os_like
  if [ ! -f /etc/os-release ]; then
    if [ -f /etc/debian_version ]; then
      _os="debian"
    elif [ -f /etc/ubuntu_version ]; then
      _os="ubuntu"
    elif [ -f /etc/redhat-release ]; then
      _os="redhat"
    elif [ -f /etc/fedora-release ]; then
      _os="fedora"
    elif [ -f /etc/arch-release ]; then
      _os="arch"
    else
      _os="unknown"
    fi
  else
    _os=$(source /etc/os-release && echo ${ID})
    _os_like=$(source /etc/os-release && echo ${ID_LIKE})
  fi
  # specific fix for linux mint, which had a different ID in /etc/os-release, but supports ubuntu and debian packages
  # so we force the script to use ubuntu's packages (the hack seems to work on virginia and above)
  # added fix for arch-based distros
  if [[ "${_os}" == "linuxmint" ]] || [[ "${_os}" == "mint" ]]; then
    _os="ubuntu"
  elif [[ "${_os_like}" == "arch" ]]; then
    _os="arch"
  fi
  echo -ne "${_os}"
}