FS#46213 - [systemd] Don't use $pkgname in paths in split packages

Attached to Project: Arch Linux
Opened by Que Quotion (quequotion) - Sunday, 06 September 2015, 11:29 GMT
Last edited by Dave Reisner (falconindy) - Sunday, 06 September 2015, 18:20 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To Thomas Bächler (brain0)
Dave Reisner (falconindy)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description: systemd's pkgbuild is a split package that uses $pkgname to refer to the directory where the source is extracted. Build fails when building one of the other packages with "makepkg --pkg targetpkg" because makepkg will use the given package name for $pkgname, but the directory is always "systemd".

Rather, as a split package this one should have a "pkgbase" variable defined and use $pkgbase in non-split functions like prepare() and build().


Additional info:
* package version(s)
* config and/or log files etc.

Details in this forum thread:
https://bbs.archlinux.org/viewtopic.php?pid=1559685

Steps to reproduce:

1. Download the systemd package source files
2. Make one of the split packages (makepkg --pkg libsystemd)
This task depends upon

Closed by  Dave Reisner (falconindy)
Sunday, 06 September 2015, 18:20 GMT
Reason for closing:  Fixed
Additional comments about closing:  Fixed in SVN, will not be release until systemd 226.
Comment by Dave Reisner (falconindy) - Sunday, 06 September 2015, 18:08 GMT
Note that this *only* works because the git repo name happens to match the pkgbase.

I'm happy to fix this, but it seems like a bug in makepkg that the value of 'pkgname' varies depending on the options passed to makepkg. Specifically this:

https://projects.archlinux.org/pacman.git/tree/scripts/makepkg.sh.in#n2067

Is a convenient, but really poor hack.

edit: then again, it's also probably poor form to refer to $pkgname at all when it's declared as an array...

Loading...