Thread (1 message) 1 message, 1 author, 2012-01-09

Re: [PATCH] dtc: Implement -d option to write out a dependency file

From: David Gibson <hidden>
Date: 2012-01-09 23:33:13

On Mon, Jan 09, 2012 at 01:33:29PM -0700, Stephen Warren wrote:
This will allow callers to rebuild .dtb files when any of the /include/d
.dtsi files are modified, not just the top-level .dts file.

Signed-off-by: Stephen Warren <redacted>
[snip]
+	if (depname) {
+		depfile = fopen(depname, "w");
+		if (!depfile)
+			die("Couldn't open dependency file %s: %s\n", depname,
+			    strerror(errno));
+		fputs(outname, depfile);
+		fputc(':', depfile);
Please just use fprintf, instead of all this jiggery pokery with fputs
and fputc.  It's much clearer and the performance difference is
meanningless.

Otherwise, nice patch.

-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help