FS#22253 - [srcpac] does not handle multiple packages in one PKGBUILD

Attached to Project: Arch Linux
Opened by Andrej Podzimek (andrej) - Thursday, 30 December 2010, 02:28 GMT
Last edited by Andrea Scarpino (BaSh) - Monday, 10 October 2011, 10:41 GMT
Task Type Feature Request
Category Arch Projects
Status Closed
Assigned To Andrea Scarpino (BaSh)
Architecture All
Severity Medium
Priority Normal
Reported Version 3.4.1
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:

srcpac cannot find/build packages that do not have a separate directory in ABS. This applies to most KDE components and many other packages, for instance clang, finch, some parts of GCC and the like.

Additional info:
* package version(s)
0.9-1

Steps to reproduce:

A simple example:
srcpac -Sb clang # This fails...
pacman -Si clang # ...although the package does exist. (It is defined in llvm's PKGBUILD.)

Another example:
yes Y | srcpac -Syub # This will fail to find/build nearly all KDE packages (for the reasons mentioned above).

It might be helpful to make some (closely related) adjustments:
1) Symlink ABS directories that contain "compound" PKGBUILDs automatically, so that they can be found by the names of all subpackages. For instance:
ln -s llvm llvm-ocaml
ln -s llvm clang
ln -s llvm clang-analyzer
2) For "non-compound" packages (where $pkgname is not an array), implicitly define package_$pkgname() { package{}; } somewhere in makepkg, for backward compatibility.
3) Teach srcpac to use the --pkg option of makepkg.
This task depends upon

Closed by  Andrea Scarpino (BaSh)
Monday, 10 October 2011, 10:41 GMT
Reason for closing:  Implemented
Additional comments about closing:  https://projects.archlinux.org/srcpac.gi t/commit/?id=b4c974fb04322a5515585c25250 a83e7374f5311
Comment by Andrej Podzimek (andrej) - Thursday, 30 December 2010, 02:31 GMT
Well, suggestion (2) is obsolete, since makepkg obviously handles --pkg gracefully even with non-compound PKGBUILDs.
Comment by Andrej Podzimek (andrej) - Monday, 11 April 2011, 03:19 GMT
srcpac 0.10.2-1 does not work at all. There are 296 packages to update, as reported by pacman -Syu (mostly KDE-related), whereas srcpac -Syub says there is *nothing* to update, after >5 minutes of 100% CPU usage.
Comment by Andrea Scarpino (BaSh) - Tuesday, 12 April 2011, 15:37 GMT
please post output so I can work on it.
Comment by Andrej Podzimek (andrej) - Thursday, 14 April 2011, 17:50 GMT
Well, there's not much to post. For instance, srcpac currently outputs this:

# srcpac -Sub

Source Targets: xorg-server

Proceed? [Y/n]

But when you call pacman (on the same system and without the -y switch, of course), you get the following:

# pacman -Su
:: Starting full system upgrade...
resolving dependencies...
looking for inter-conflicts...

Targets (378): libmysqlclient-5.5.11-1 mysql-clients-5.5.11-1 mysql-5.5.11-1 akonadi-1.5.2-1 audacious-plugins-2.4.4-3 avahi-0.6.30-1 xproto-7.0.21-1 libx11-1.4.3-2
consolekit-0.4.3-3 kdebase-workspace-4.6.2-2 bluedevil-1.0.4-1 bluez-4.91-1 bzr-2.3.1-1 llvm-2.9-1 clang-2.9-1 clang-analyzer-2.9-1 taglib-1.7-1 clementine-0.7.1-1
libgpg-error-1.9-3 libgcrypt-1.4.6-2 crda-1.1.1-3 dhcpcd-5.2.12-1 dmraid-1.0.0.rc16.3-1 eclipse-emf-2.6.1-1 eclipse-gef-3.6.2-1 eventlog-0.2.12-2
filesystem-2011.04-1 fakeroot-1.15.1-1 xextproto-7.2.0-1 fixesproto-5.0-1 giflib-4.1.6-4 libtiff-3.9.5-1 gdal-1.8.0-3 git-1.7.4.4-1 gnokii-0.6.30-2 libtasn1-2.9-1
gnutls-2.12.2-1 google-gadgets-common-0.11.2-3 xdg-utils-1.1.0rc1-2 gstreamer0.10-base-0.10.32-4 libthai-0.1.15-1 pango-1.28.4-2 gstreamer0.10-base-plugins-0.10.32-4
google-gadgets-qt-0.11.2-3 gstreamer0.10-bad-0.10.21-3 xvidcore-1.3.1-1 libdc1394-2.1.3-1 gstreamer0.10-bad-plugins-0.10.21-3 gstreamer0.10-good-0.10.28-1
gstreamer0.10-good-plugins-0.10.28-1 icedtea-web-1.0.2-1 icedtea-web-doc-1.0.2-1 xz-5.0.2-1 imagemagick-6.6.9.4-1 imagemagick-doc-6.6.9.4-1 intellij-idea-libs-10.0.3-1
strigi-git20110405-1 kdelibs-4.6.2-1 ntrack-1:13-1 cifs-utils-4.9-2 smbclient-3.5.8-2 oxygen-icons-4.6.2-1 kdebase-runtime-4.6.2-1 kaffeine-1.2.1-1
kde-l10n-cs-4.6.2-1 kde-l10n-sk-4.6.2-1 kde-l10n-uk-4.6.2-1 kdeaccessibility-colorschemes-4.6.2-1 kdeaccessibility-iconthemes-4.6.2-1 kdeaccessibility-jovie-4.6.2-1
kdeaccessibility-kaccessible-4.6.2-1 kdeaccessibility-kmag-4.6.2-1 kdeaccessibility-kmousetool-4.6.2-1 kdeaccessibility-kmouth-4.6.2-1 kdeadmin-kcron-4.6.2-1
kdeadmin-ksystemlog-4.6.2-1 kdeadmin-kuser-4.6.2-1 kdebindings-python-4.6.2-1 pycups-1.9.55-1 system-config-printer-common-1.3.2-1
kdeadmin-system-config-printer-kde-4.6.2-1 kdeartwork-aurorae-4.6.2-1 kdeartwork-colorschemes-4.6.2-1 kdeartwork-desktopthemes-4.6.2-1 kdeartwork-emoticons-4.6.2-1
kdeartwork-iconthemes-4.6.2-1 kdegraphics-libs-4.6.2-1 kdeartwork-kscreensaver-4.6.2-1 kdeartwork-sounds-4.6.2-1 kdeartwork-styles-4.6.2-1 kdeartwork-wallpapers-4.6.2-1
kdeartwork-weatherwallpapers-4.6.2-1 kdebase-lib-4.6.2-1 kdebase-dolphin-4.6.2-1 kdebase-kdepasswd-4.6.2-1 kdebase-kdialog-4.6.2-1 kdebase-keditbookmarks-4.6.2-1
kdebase-kfind-4.6.2-1 kdebase-konqueror-4.6.2-1 kdebase-konsole-4.6.2-1 kdebase-kwrite-4.6.2-1 kdebase-plasma-4.6.2-1 poppler-0.16.4-1 poppler-qt-0.16.4-1
kdegraphics-okular-4.6.2-1 kdebindings-smoke-4.6.2-1 kdebindings-csharp-4.6.2-1 kdebindings-ruby-4.6.2-1 kdeedu-data-4.6.2-1 kdeedu-libkdeedu-4.6.2-1
kdeedu-marble-4.6.2-1 kdegames-libkdegames-4.6.2-1 kdegames-libkmahjongg-4.6.2-1 kdegraphics-gwenview-4.6.2-1 kdegraphics-kamera-4.6.2-1
kdegraphics-kcolorchooser-4.6.2-1 kdegraphics-kgamma-4.6.2-1 kdegraphics-kolourpaint-4.6.2-1 kdegraphics-kruler-4.6.2-1 kdegraphics-ksnapshot-4.6.2-1
kdemultimedia-dragonplayer-4.6.2-1 kdemultimedia-ffmpegthumbs-4.6.2-1 kdemultimedia-juk-4.6.2-1 kdemultimedia-kioslave-4.6.2-1 kdemultimedia-kmix-4.6.2-1
kdemultimedia-kscd-4.6.2-1 kdemultimedia-mplayerthumbs-4.6.2-1 kdenetwork-filesharing-4.6.2-1 kdenetwork-kdnssd-4.6.2-1 kdenetwork-kget-4.6.2-1 kdepimlibs-4.6.2-1
kdenetwork-kopete-4.6.2-1 kdenetwork-kppp-4.6.2-1 kdenetwork-krdc-4.6.2-1 kdenetwork-krfb-4.6.2-1 kdepim-libkdepim-4.4.10-2 kdepim-akonadiconsole-4.4.10-2
kdepim-akregator-4.4.10-2 kdepim-blogilo-4.4.10-2 kdepim-console-4.4.10-2 kdepim-kaddressbook-4.4.10-2 kdepim-kalarm-4.4.10-2 kdepim-kjots-4.4.10-2
kdepim-kleopatra-4.4.10-2 kdepim-kmail-4.4.10-2 kdepim-knode-4.4.10-2 kdepim-knotes-4.4.10-2 kdepim-korganizer-4.4.10-2 kdepim-kontact-4.4.10-2
kdepim-kresources-4.4.10-2 kdepim-ktimetracker-4.4.10-2 kdepim-wizards-4.4.10-2 kdeplasma-addons-applets-bball-4.6.2-1 kdeplasma-addons-applets-binary-clock-4.6.2-1
kdeplasma-addons-applets-blackboard-4.6.2-1 kdeplasma-addons-applets-bookmarks-4.6.2-1 kdeplasma-addons-applets-bubblemon-4.6.2-1
kdeplasma-addons-applets-calculator-4.6.2-1 kdeplasma-addons-applets-charselect-4.6.2-1 kdeplasma-addons-libs-4.6.2-1 kdeplasma-addons-applets-comic-4.6.2-1
kdeplasma-addons-applets-community-4.6.2-1 kdeplasma-addons-applets-dict-4.6.2-1 kdeplasma-addons-applets-eyes-4.6.2-1 kdeplasma-addons-applets-fifteenpuzzle-4.6.2-1
kdeplasma-addons-applets-filewatcher-4.6.2-1 kdeplasma-addons-applets-frame-4.6.2-1 kdeplasma-addons-applets-fuzzy-clock-4.6.2-1
kdeplasma-addons-applets-incomingmsg-4.6.2-1 kdeplasma-addons-applets-kdeobservatory-4.6.2-1 kdeplasma-addons-applets-kimpanel-4.6.2-1
kdeplasma-addons-applets-knowledgebase-4.6.2-1 kdeplasma-addons-applets-kolourpicker-4.6.2-1 kdeplasma-addons-applets-konqprofiles-4.6.2-1
kdeplasma-addons-applets-konsoleprofiles-4.6.2-1 kdeplasma-addons-applets-lancelot-4.6.2-1 kdeplasma-addons-applets-leavenote-4.6.2-1
kdeplasma-addons-applets-life-4.6.2-1 kdeplasma-addons-applets-luna-4.6.2-1 kdeplasma-addons-applets-magnifique-4.6.2-1 kdeplasma-addons-applets-mediaplayer-4.6.2-1
kdeplasma-addons-applets-microblog-4.6.2-1 kdeplasma-addons-applets-news-4.6.2-1 kdeplasma-addons-applets-notes-4.6.2-1 kdeplasma-addons-applets-nowplaying-4.6.2-1
kdeplasma-addons-applets-paste-4.6.2-1 kdeplasma-addons-applets-pastebin-4.6.2-1 kdeplasma-addons-applets-plasmaboard-4.6.2-1 kdeplasma-addons-applets-previewer-4.6.2-1
kdeplasma-addons-applets-qalculate-4.6.2-1 kdeplasma-addons-applets-rememberthemilk-4.6.2-1 kdeplasma-addons-applets-rssnow-4.6.2-1
kdeplasma-addons-applets-showdashboard-4.6.2-1 kdeplasma-addons-applets-showdesktop-4.6.2-1 kdeplasma-addons-applets-social-news-4.6.2-1
kdeplasma-addons-applets-spellcheck-4.6.2-1 kdeplasma-addons-applets-systemloadviewer-4.6.2-1 kdeplasma-addons-applets-timer-4.6.2-1
kdeplasma-addons-applets-unitconverter-4.6.2-1 kdeplasma-addons-applets-weather-4.6.2-1 kdeplasma-addons-applets-weatherstation-4.6.2-1
kdeplasma-addons-applets-webslice-4.6.2-1 kdeplasma-addons-containments-4.6.2-1 kdeplasma-addons-runners-audioplayercontrol-4.6.2-1
kdeplasma-addons-runners-browserhistory-4.6.2-1 kdeplasma-addons-runners-characters-4.6.2-1 kdeplasma-addons-runners-contacts-4.6.2-1
kdeplasma-addons-runners-converter-4.6.2-1 kdeplasma-addons-runners-datetime-4.6.2-1 kdeplasma-addons-runners-events-4.6.2-1 kdeplasma-addons-runners-katesessions-4.6.2-1
kdeplasma-addons-runners-konquerorsessions-4.6.2-1 kdeplasma-addons-runners-konsolesessions-4.6.2-1 kdeplasma-addons-runners-kopete-4.6.2-1
kdeplasma-addons-runners-mediawiki-4.6.2-1 kdeplasma-addons-runners-spellchecker-4.6.2-1 kdeplasma-addons-wallpapers-mandelbrot-4.6.2-1
kdeplasma-addons-wallpapers-marble-4.6.2-1 kdeplasma-addons-wallpapers-pattern-4.6.2-1 kdeplasma-addons-wallpapers-virus-4.6.2-1
kdeplasma-addons-wallpapers-weather-4.6.2-1 kdesdk-cervisia-4.6.2-1 kdesdk-kompare-4.6.2-1 kdesdk-dolphin-plugins-4.6.2-1 kdesdk-kapptemplate-4.6.2-1
kdesdk-kate-4.6.2-1 kdesdk-kcachegrind-4.6.2-1 kdesdk-kdeaccounts-plugin-4.6.2-1 kdesdk-kdepalettes-4.6.2-1 kdesdk-kioslave-4.6.2-1 kdesdk-kmtrace-4.6.2-1
kdesdk-kpartloader-4.6.2-1 kdesdk-kprofilemethod-4.6.2-1 kdesdk-kstartperf-4.6.2-1 kdesdk-kuiviewer-4.6.2-1 kdesdk-lokalize-4.6.2-1 kdesdk-okteta-4.6.2-1
kdesdk-poxml-4.6.2-1 kdesdk-scripts-4.6.2-1 kdesdk-strigi-analyzer-4.6.2-1 kdesdk-umbrello-4.6.2-1 kdetoys-amor-4.6.2-1 kdetoys-kteatime-4.6.2-1 kdetoys-ktux-4.6.2-1
kdeutils-ark-4.6.2-1 kdeutils-filelight-4.6.2-1 kdeutils-kcalc-4.6.2-1 kdeutils-kcharselect-4.6.2-1 kdeutils-kdf-4.6.2-1 kdeutils-kfloppy-4.6.2-1 kdeutils-kgpg-4.6.2-1
kdeutils-kremotecontrol-4.6.2-1 kdeutils-ktimer-4.6.2-1 kdeutils-kwallet-4.6.2-1 kdeutils-printer-applet-4.6.2-1 kdeutils-superkaramba-4.6.2-1 kdeutils-sweeper-4.6.2-1
kdevplatform-1.2.2-1 kdevelop-4.2.2-1 kdewebdev-kfilereplace-4.6.2-1 kdewebdev-kimagemapeditor-4.6.2-1 kdewebdev-klinkstatus-4.6.2-1 kdewebdev-kommander-4.6.2-1
kernel26-2.6.38.2-1 kernel26-docs-2.6.38.2-1 koffice-filters-2.3.3-3 koffice-servicetypes-2.3.3-3 koffice-libs-2.3.3-3 koffice-interfaces-2.3.3-3
koffice-templates-2.3.3-3 koffice-karbon-2.3.3-3 koffice-karbon-doc-2.3.3-3 koffice-plugins-2.3.3-3 koffice-kspread-2.3.3-3 koffice-kexi-2.3.3-3
koffice-kexi-doc-2.3.3-3 koffice-kounavail-2.3.3-3 koffice-pics-2.3.3-3 koffice-kword-2.3.3-3 koffice-kplato-2.3.3-3 koffice-kpresenter-2.3.3-3
koffice-kpresenter-doc-2.3.3-3 koffice-krita-2.3.3-3 koffice-kspread-doc-2.3.3-3 koffice-thesaurus-doc-2.3.3-3 koffice-tools-2.3.3-3 libbonobo-2.32.1-1
libbonoboui-2.24.5-1 libdrm-2.4.25-1 libegl-7.10.2-2 libgles-7.10.2-2 libproxy-0.4.6-6 libreoffice-cs-3.3.2-2 libreoffice-de-3.3.2-2 libreoffice-fr-3.3.2-2
libxfixes-5.0-1 libva-1.0.12-1 libvirt-0.9.0-1 ortp-0.16.5-1 mediastreamer-2.7.3-1 linphone-3.4.3-2 libirman-0.4.5-2 lirc-utils-1:0.9.0-2 llvm-ocaml-2.9-1
mc-4.7.5.2-1 mdadm-3.2.1-1 mesa-7.10.2-2 vlc-1.1.9-1 me-tv-2.0.1-1 mercurial-1.8.2-1 nasm-2.09.08-1 nasm-doc-2.09.08-1 ncurses-5.9-1 ntp-4.2.6.p3-3 opera-11.10-1
oxygen-icons-svg-4.6.2-1 phonon-gstreamer-4.5.0-1 php-5.3.6-2 php-apache-5.3.6-2 php-cgi-5.3.6-2 php-curl-5.3.6-2 php-embed-5.3.6-2 php-enchant-5.3.6-2
php-fpm-5.3.6-2 php-gd-5.3.6-2 php-gmp-5.3.6-2 php-intl-5.3.6-2 php-ldap-5.3.6-2 php-mcrypt-5.3.6-2 php-mssql-5.3.6-2 php-odbc-5.3.6-2 php-pear-5.3.6-2
php-pgsql-5.3.6-2 php-pspell-5.3.6-2 php-snmp-5.3.6-2 php-sqlite-5.3.6-2 php-tidy-5.3.6-2 php-xsl-5.3.6-2 poppler-glib-0.16.4-1 python-distribute-0.6.15-3
python2-distribute-0.6.15-3 qmmp-0.5.0-1 qtcurve-gtk2-1.8.8-1 qtcurve-kde3-1.8.5-1 qtcurve-kde4-1.8.7-1 redland-1.0.12-6 redland-storage-mysql-1.0.12-6
redland-storage-postgresql-1.0.12-6 redland-storage-sqlite-1.0.12-6 redland-storage-virtuoso-1.0.12-6 rsync-3.0.8-1 skype-2.2.0.25-1 startup-notification-0.10-2
sudo-1.8.1-1 syslog-ng-3.2.2-2 texi2html-5.0-1 tomcat-5.5.33-1 tzdata-2011e-1 usbutils-002-1 v86d-0.1.10-1 vala-0.12.0-1 virt-manager-0.8.7-2 vlc-plugin-1.1.9-1
wine-1.3.17-1 winetricks-20110402-1 xf86-input-evdev-2.6.0-3 xf86-input-joystick-1.5.99_git20110318-1 xf86-input-synaptics-1.4.0-2 xf86-input-vmmouse-12.7.0-2
xf86-video-vesa-2.3.0-5 xkeyboard-config-2.2.1-1 xorg-server-common-1.10.0.902-1 xorg-server-1.10.0.902-1 xorg-server-devel-1.10.0.902-1 xorg-server-xdmx-1.10.0.902-1
xorg-server-xephyr-1.10.0.902-1 xorg-server-xnest-1.10.0.902-1 xorg-server-xvfb-1.10.0.902-1

Total Download Size: 814.03 MB
Total Installed Size: 2254.96 MB

Proceed with installation? [Y/n]

This is really a *big* difference.
Comment by Andrea Scarpino (BaSh) - Tuesday, 19 April 2011, 10:49 GMT
status with 0.10.3?
Comment by Andrea Scarpino (BaSh) - Tuesday, 19 April 2011, 11:23 GMT
Still is broke. I found the error, hope to fix it soon and release 0.10.4
Comment by Andrea Scarpino (BaSh) - Tuesday, 19 April 2011, 13:37 GMT
Ok, should work now using -git.
Can you test it so I can release 0.10.4? Thanks
Comment by Andrej Podzimek (andrej) - Tuesday, 19 April 2011, 14:40 GMT
Tested with today's (15:30 GMT) srcpac-git:

1) There seems to be no latency with -Syub, but srcpac does not suggest any updates (unlike pacman).
2) With -Sub only, srcpac hogs 100% of one core for a very long time (>10 minutes on my Core i7-820QM), but seems to produce a reasonable list of packages afterwards.

I'm now testing whether the compiled update process works, which might take long...
Comment by Andrea Scarpino (BaSh) - Tuesday, 19 April 2011, 15:28 GMT
1) is fixed on git
2) The algorithm to get the pkgbase of a package scan the whole /var/abs, for every args. I know, I need to improve this.
Comment by Andrej Podzimek (andrej) - Friday, 08 July 2011, 16:34 GMT
Something's still wrong with srcpac. For instance, it just said
'Build failed for: kdebase-workspace kdebindings kde-l10n libreoffice perl-libapreq2 php redland subversion',
totally ignoring the recent huge KDE update. With pacman -Syu, 356 updates were found.

But perhaps this is not caused by srcpac at all... It may be closely related to another issue: https://bugs.archlinux.org/task/24537?project=1&opened=3107
Comment by Andrea Scarpino (BaSh) - Saturday, 01 October 2011, 08:53 GMT
Is this solved with srcpac-git?
Comment by Andrej Podzimek (andrej) - Saturday, 08 October 2011, 13:20 GMT
Yes, it seems to be solved ... at the first glance. I'll definitely test it on multiple other machines this week and report back what happens. There seem to be many improvements, so I'm looking forward to testing this.

Quite a lot of things have changed in srcpac since my last hacking session ( FS#25628 ) :-) I'll also try to forward-port my -z option once I have time for that, preferably with proper handling of core/extra and community Git repos. The -z option might solve some of the race conditions between pacman's binary repositories and the ABS tree. (The point was that when the ABS tree is older than pacman's repositories, it hurts much more than vice versa. Getting PKGBUILDs from Git instead of ABS might be therefore slightly better for unattended updates.)
Comment by Andrea Scarpino (BaSh) - Saturday, 08 October 2011, 13:27 GMT
Yep, I rewrote some code to speed up it a bit and to better handle split packages. Testing is really appreciated, thanks!

About your git option, I prefer to fix ABS instead.
Comment by Andrej Podzimek (andrej) - Saturday, 08 October 2011, 13:52 GMT
> About your git option, I prefer to fix ABS instead.

So do I. But judging by the reactions of some people here [https://bugs.archlinux.org/task/24537], I don't believe it will be fixed any time soon. The „we have no obligation“ and „this is OUR distro“ statements say that loud and clear. (And I really started planning to move to Gentoo afterwards, but fortunately, I found out that not all community members share the same „shut up“ opinion.)

An interesting solution might be to base ABS on a Git branch in which PKGBUILDs of packages currently present in binary repositories would reside. Then it would all work just like -z suggests, with no need for -z. :-)

Loading...