On Mon, Nov 07, 2011 at 03:35:27PM +1000, Allan McRae wrote: > On 02/11/11 22:49, Martti Kühne wrote: > >I'd like to see support for split packages, too, maybe I'll add it some > >time. Using it locally, while improving my dwm patches. > >Different approaches include playing around with $PATH, use absolute start > >paths for testing, but once I got used to this way, I just can't resist it > >any more... :) > > > > > I do not understand the comment about split packages? How do they > change anything to do with extracting and replacing the checksum > arrays?
Well, the script does not extract any checksum from a PKGBUILD and does currently not care about *sums assignments within functions, as may be the case with split packages. However I'd like to add that in a later version. > > Also the comment about $PATH confuses me... Testing a package one is working on can be done in several ways, one could add the source directory to PATH or create symlinks, or use ./blah... In case of a window manager the latter isn't comfortable, since it includes modifying ~/.xinitrc, hence my seemingly far-fetched mentioning of $PATH. > > I have not looked at your script in detail, but there is quite a lot > of discussion about various approaches to doing this in the > following bug report: https://bugs.archlinux.org/task/15051 . Any > script being added to contrib should support updating the variety of > checksums makepkg accepts. Good point. The way I'm doing it is pretty generic, although for now I'm literally muting any /^md5sums=\(/ assignment. Insertion of a sum is done by simply redirecting the output of `makepkg -g`. Afaict checksums arrays can be identified uniquely because they exclusively contain the string "sums=("? The script is based on the fact that the checksums array of a package is placed before any empty line before the first of the /(build|check|package)/ function definitions, in a current version also skipping /^_.*/ lines to work with VCS packages ("_blahurl" and "_blahrepo" and the like). cheers! mar77i
