BKSalman / ytdlp-gui

a very simple GUI for ytdlp written in Rust
GNU General Public License v3.0
277 stars 16 forks source link

Add 3rd option for AUR package - local rustup #14

Closed idc77 closed 1 year ago

idc77 commented 1 year ago

I, for one, have installed rustup outside of the community package. However when trying to install this package from the AUR I'm only presented with

:: There are 2 providers available for cargo:
:: Repository extra
    1) rust 
:: Repository community
    2) rustup 

There should be

:: There are 2 providers available for cargo:
:: Repository extra
    1) rust 
:: Repository community
    2) rustup 
:: Already installed rustup
    3) local rustup
BKSalman commented 1 year ago

this is probably from the package dependencies

https://github.com/BKSalman/ytdlp-gui/blob/75732d12e3ec8123be11ac47a1dc2374d8cfcd31/aur/PKGBUILD#LL12C46-L12C46

the package manager is trying to install rustup since it wasn't installed through it, I'm not sure what's the optimal way to fix this issue, since I don't use Arch.

if you can recommend a fix for this that would be nice

mohad12211 commented 1 year ago

@idc77 Pacman looks for the package rustup not the binary rustup, it can't see your locally installed rustup binary. You have two options to solve this, either by making a dummy package that provides rust and cargo, so that when you install a program from the AUR that depends on rust, it will recognize the dummy package. or by uninstalling your current installation and install rustup from the arch repos then use rustup to install the toolchain, this is the recommended way since rustup will install the toolchain at ~/.rustup and pacman will recognize that you have rust installed, the only downside here is that you can't do rustup self update because the package needs to be updated by pacman, and that's not really an issue because it will probably be updated quickly by the maintainers.

BKSalman commented 1 year ago

since this issue can't be solved from my side, I'm going to close it, thanks for providing a good explanation @mohad12211 :+1: