Hi all,

To start, apologies for my mailer... if it's in plain-text mode it still
appears to auto-format anything that is pasted in, including patches.
So I had to attach my silly little patch.  If this is unacceptable, I'm
willing to switch over to mutt (I wanted to do it sooner or later
anyway...), but it'll take me longer.

I attempted to do a patch for the current CVS code but found that
there's no 'configure' file, so there was no way for me to test my
modification.  So this patch is based against release 0.46.  I'm happy
to update the patch for the CVS version if someone can educate me on how
to configure/make/install from a CVS checkout.

Anyways... the patch.  We've been working on writing a BSP for WindRiver
PNE Linux.  WindRiver's build/development structure makes the patches in
the QUILT_PATCHES directory symlinks.  The directories themselves aren't
symlinks, rather the end file is a link off to a patch somewhere else.
For us that link points to our "layer" for WRLinux, which is in
subversion.  The default behavior for quilt is when doing a refresh, to
first do an 'rm -f' on the file, followed by writing the file out.  This
unfortunately blows away the symlink and then creates a real file in
it's place, resulting in the patch in our subversion area not getting
the update.

The modification I did is to enable a non-default behavior with
QUILT_NO_RM_SYMLINKS=yes in the quiltrc file.  All this does is prevent
the 'rm' step from happening (the file is then just overwritten,
preserving the link).

Let me know if there's any way for me to improve the patch.  Thanks!
Chris






diff -urN quilt-0.46/quilt.quiltrc quilt-0.46.wrlinkmod/quilt.quiltrc
--- quilt-0.46/quilt.quiltrc	2006-06-12 11:54:47.000000000 -0500
+++ quilt-0.46.wrlinkmod/quilt.quiltrc	2008-01-28 14:54:44.000000000 -0600
@@ -25,3 +25,9 @@
 # Use a specific editor for quilt (defaults to the value of $EDITOR before
 # sourcing this configuration file, or vi if $EDITOR wasn't set).
 #EDITOR=nedit
+
+#If you're so lucky as to be using a Windriver Linux product, and your
+#patch files are actually symlinks, this option set to yes will allow
+#the symlink to be preserved (resulting in the file the link is pointing to
+#to be refreshed).
+QUILT_NO_RM_SYMLINKS=yes
diff -urN quilt-0.46/quilt/scripts/patchfns.in quilt-0.46.wrlinkmod/quilt/scripts/patchfns.in
--- quilt-0.46/quilt/scripts/patchfns.in	2006-09-19 09:44:47.000000000 -0500
+++ quilt-0.46.wrlinkmod/quilt/scripts/patchfns.in	2008-01-28 14:56:14.000000000 -0600
@@ -749,7 +749,13 @@
 {
 	local filename="$1"
 
-	[ -e "$filename" ] && rm -f "$filename"
+	if [ -e "$filename" ]
+	then
+		if [ "$QUILT_NO_RM_SYMLINKS" != "yes" ]
+		then
+			rm -f "$filename"
+		fi
+	fi
 
 	case "$filename" in
 	*.gz)
_______________________________________________
Quilt-dev mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/quilt-dev

Reply via email to