You are not logged in.

#1 2025-10-27 12:24:28

evorster
Member
Registered: 2020-07-07
Posts: 90

How to create a package that requires one of two optional packages

I have a package that uses slint. This can use either qt or winint to draw graphics.

Either qt or winint is fine, and there is no problem with making both of these build requirements, apart from the fact that in essence, only one is really necessary, and having both adds useless bloat.

How can I make a PKGBUILD that requires some graphical toolkit, and provides a choice between qt and winint?

Last edited by evorster (2025-10-27 12:25:45)

Offline

#2 2025-10-27 12:46:28

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 14,387

Re: How to create a package that requires one of two optional packages

Is this about https://github.com/slint-ui/slint ?

Usually those kind of decisions are made by the maintainer of the package that provides slint.

slint doesn't appear to be in the repos, aur has slint-lsp-bin, slint-cpp-bin & slint-cpp .
The first 2 use qt5 , the 3rd doesn't require any toolkit.

Are you providing slint in your package ?
If not, which package is ?


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#3 2025-10-27 13:55:04

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 70,052

Re: How to create a package that requires one of two optional packages

How can I make a PKGBUILD that requires some graphical toolkit, and provides a choice between qt and winint?

By creating a hard dependency (as it is one) but on a generic entry that is provided by both UI packages.
Since you don't control at least the Qt PKGBUILD you'd introduce a meta-package slint-qt that depends on qt and provides slint-ui, the latter being the generic hard dependency for slint.

Offline

Board footer

Powered by FluxBB