* [PATCH] Makefile: fix location of listing produced by "make subdir/foo.s"
@ 2012-07-22 23:47 Jonathan Nieder
2012-07-23 5:11 ` Junio C Hamano
0 siblings, 1 reply; 2+ messages in thread
From: Jonathan Nieder @ 2012-07-22 23:47 UTC (permalink / raw)
To: git; +Cc: Jeff King, Junio C Hamano
When I invoke "make block-sha1/sha1.s", 'make' runs $(CC) -S without
specifying where it should put its output and the output ends up in
./sha1.s. Confusing.
Add an -o option to the .s rule to fix this. We were already doing
that for most compiler invocations but had forgotten it for the
assembler listings.
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
---
Hi,
This patch is from below the scissors at
http://thread.gmane.org/gmane.comp.version-control.git/201434/focus=201485
I think it's a good change, but as usual it's nice if someone else
takes a look at it and gives it a sanity check. If it seems sane,
I'd be happy to see it applied. What do you think?
Thanks,
Jonathan
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
index 285c660e..8bfa19cd 100644
--- a/Makefile
+++ b/Makefile
@@ -2263,7 +2263,7 @@ $(ASM_OBJ): %.o: %.S GIT-CFLAGS $(missing_dep_dirs)
endif
%.s: %.c GIT-CFLAGS FORCE
- $(QUIET_CC)$(CC) -S $(ALL_CFLAGS) $(EXTRA_CPPFLAGS) $<
+ $(QUIET_CC)$(CC) -o $@ -S $(ALL_CFLAGS) $(EXTRA_CPPFLAGS) $<
ifdef USE_COMPUTED_HEADER_DEPENDENCIES
# Take advantage of gcc's on-the-fly dependency generation
--
1.7.10.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] Makefile: fix location of listing produced by "make subdir/foo.s"
2012-07-22 23:47 [PATCH] Makefile: fix location of listing produced by "make subdir/foo.s" Jonathan Nieder
@ 2012-07-23 5:11 ` Junio C Hamano
0 siblings, 0 replies; 2+ messages in thread
From: Junio C Hamano @ 2012-07-23 5:11 UTC (permalink / raw)
To: Jonathan Nieder; +Cc: git, Jeff King
Jonathan Nieder <jrnieder@gmail.com> writes:
> When I invoke "make block-sha1/sha1.s", 'make' runs $(CC) -S without
> specifying where it should put its output and the output ends up in
> ./sha1.s. Confusing.
>
> Add an -o option to the .s rule to fix this. We were already doing
> that for most compiler invocations but had forgotten it for the
> assembler listings.
>
> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
> ---
> Hi,
>
> This patch is from below the scissors at
> http://thread.gmane.org/gmane.comp.version-control.git/201434/focus=201485
>
> I think it's a good change, but as usual it's nice if someone else
> takes a look at it and gives it a sanity check. If it seems sane,
> I'd be happy to see it applied. What do you think?
>
> Thanks,
> Jonathan
Yeah, I think it is a sensible thing to do.
> Makefile | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Makefile b/Makefile
> index 285c660e..8bfa19cd 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -2263,7 +2263,7 @@ $(ASM_OBJ): %.o: %.S GIT-CFLAGS $(missing_dep_dirs)
> endif
>
> %.s: %.c GIT-CFLAGS FORCE
> - $(QUIET_CC)$(CC) -S $(ALL_CFLAGS) $(EXTRA_CPPFLAGS) $<
> + $(QUIET_CC)$(CC) -o $@ -S $(ALL_CFLAGS) $(EXTRA_CPPFLAGS) $<
>
> ifdef USE_COMPUTED_HEADER_DEPENDENCIES
> # Take advantage of gcc's on-the-fly dependency generation
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-07-23 5:11 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-22 23:47 [PATCH] Makefile: fix location of listing produced by "make subdir/foo.s" Jonathan Nieder
2012-07-23 5:11 ` Junio C Hamano
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).