pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/mk



Module Name:    pkgsrc
Committed By:   rillig
Date:           Sun Jan 31 17:27:41 UTC 2016

Modified Files:
        pkgsrc/mk: subst.mk
        pkgsrc/mk/wrapper: bsd.wrapper.mk

Log Message:
Fixed subst.mk not to corrupt files

Up to now, using subst.mk may have led to file corruption during active
package development. This happened when a sed(1) command had a syntax
error, in which case the whole sed(1) command was terminated, leaving an
empty original file behind.

This commit changes that behavior by applying the sed(1) commands to
the original file and saving the result in a temporary file. Only
after that succeeded is the original file overwritten.

During this rewrite, SUBST_POSTCMD has been removed, since it was
only used in one place (mk/wrapper), and since it relied on the exact
sequence of the internal commands. No package in either main pkgsrc
or pkgsrc-wip uses this variable right now.


To generate a diff of this commit:
cvs rdiff -u -r1.54 -r1.55 pkgsrc/mk/subst.mk
cvs rdiff -u -r1.93 -r1.94 pkgsrc/mk/wrapper/bsd.wrapper.mk

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index