You are not logged in.

#1 2025-11-13 21:32:58

vincav
Member
Registered: 2025-11-13
Posts: 1

[SOLVED] PKGBUILD without package() function

I am learning about the makepkg process and I came across this PKGBUILD file from the vivado AUR package, which has no package() function.

For context, this package installs vivado and/or vitis, which are proprietary software, and the build requires that you download a file from the responsible company first (as explained in PKGBUILD). The functions package_vivado() and package_vitis_() are provided, as well as package_common_pre() and package_common_post(), but no mention of package().

From PKGBUILD(5):

As a minimum, the PKGBUILD must contain a package() function which installs all the package’s files into the packaging directory.

This is because (as far as I understand) the makepkg binary calls the package() function directly. How does the build process complete if there is no package() function?

Last edited by vincav (2025-11-13 22:25:55)

Offline

#2 2025-11-13 22:20:10

mpan
Member
Registered: 2012-08-01
Posts: 1,593
Website

Re: [SOLVED] PKGBUILD without package() function

Welcome.

This PKGBUILD has the `package` functions: in line 169 and 187:

(…)
package_vivado() {
    conflicts=(vitis vivado)
    pkgdesc="$pkgdesc – Vivado edition"
    package_common_pre
    (…)
    package_common_post
}
package_vitis_() {
    provides=(vitis vivado)
    conflicts=(vitis vivado)
    pkgdesc="$pkgdesc – Vitis edition"
    package_common_pre
    install=vitis.install  # Reinstall Python wheel etc
    (…)
}
(…)

This is a split package PKGBUILD.


Paperclips in avatars? | Sometimes I seem a bit harsh — don’t get offended too easily!

Offline

Board footer

Powered by FluxBB