diff mbox

[RFC,01/22] Makefiles

Message ID 007501cf951e$233977c0$69ac6740$@Dovgaluk@ispras.ru
State New
Headers show

Commit Message

Pavel Dovgalyuk July 1, 2014, 11:18 a.m. UTC
Changes in main makefiles.

Signed-off-by: Pavel Dovgalyuk <pavel.dovgaluk@gmail.com>
---

Comments

Kirill Batuzov July 2, 2014, 10:46 a.m. UTC | #1
On Tue, 1 Jul 2014, Pavel Dovgaluk wrote:

> Changes in main makefiles.
> 
> Signed-off-by: Pavel Dovgalyuk <pavel.dovgaluk@gmail.com>
> ---
> 
> diff --git a/Makefile.target b/Makefile.target
> index 6089d29..357ab4d
> --- a/Makefile.target
> +++ b/Makefile.target
> @@ -76,6 +76,7 @@ all: $(PROGS) stap
>  #########################################################
>  # cpu emulator library
>  obj-y = exec.o translate-all.o cpu-exec.o
> +obj-y += replay/
>  obj-y += tcg/tcg.o tcg/optimize.o
>  obj-$(CONFIG_TCG_INTERPRETER) += tci.o
>  obj-$(CONFIG_TCG_INTERPRETER) += disas/tci.o
> @@ -85,6 +86,8 @@ obj-y += disas.o
>  obj-$(call notempty,$(TARGET_XML_FILES)) += gdbstub-xml.o
>  obj-$(call lnot,$(CONFIG_KVM)) += kvm-stub.o
>  
> +replay/replay.o replay/replay-events.o replay/replay-internal.o: CFLAGS+= -Wno-unused-result
> +
>  obj-$(CONFIG_LIBDECNUMBER) += libdecnumber/decContext.o
>  obj-$(CONFIG_LIBDECNUMBER) += libdecnumber/decNumber.o
>  obj-$(CONFIG_LIBDECNUMBER) += libdecnumber/dpd/decimal32.o
> 

Is this change really needed? I think it is better to avoid disabling
compiler warnings without a good reason clearly stated in the commit
message.

> diff --git a/net/Makefile.objs b/net/Makefile.objs
> index a06ba59..cc6f32b
> --- a/net/Makefile.objs
> +++ b/net/Makefile.objs
> @@ -1,6 +1,6 @@
>  common-obj-y = net.o queue.o checksum.o util.o hub.o
>  common-obj-y += socket.o
> -common-obj-y += dump.o
> +common-obj-y += dump.o net-replay.o
>  common-obj-y += eth.o
>  common-obj-$(CONFIG_LINUX) += l2tpv3.o
>  common-obj-$(CONFIG_POSIX) += tap.o vhost-user.o
> 
> 

This is not bisectable. You add net-replay.o to the makefile in
the patch 01/22 but net-replay.c is added only in the patch 18/22.

I've spotted similar problem with replay.h which is used before it is
added. You'll need to recombine/reorder your series.
Peter Maydell July 2, 2014, 11:14 a.m. UTC | #2
On 2 July 2014 11:46, Kirill Batuzov <batuzovk@ispras.ru> wrote:
> On Tue, 1 Jul 2014, Pavel Dovgaluk wrote:
>> +replay/replay.o replay/replay-events.o replay/replay-internal.o: CFLAGS+= -Wno-unused-result

> Is this change really needed? I think it is better to avoid disabling
> compiler warnings without a good reason clearly stated in the commit
> message.

In this case these are new files and they're not some other
project's files we're importing, so we should just make them
comply with QEMU's usual warning levels from the start.

thanks
-- PMM
diff mbox

Patch

diff --git a/Makefile.target b/Makefile.target
index 6089d29..357ab4d
--- a/Makefile.target
+++ b/Makefile.target
@@ -76,6 +76,7 @@  all: $(PROGS) stap
 #########################################################
 # cpu emulator library
 obj-y = exec.o translate-all.o cpu-exec.o
+obj-y += replay/
 obj-y += tcg/tcg.o tcg/optimize.o
 obj-$(CONFIG_TCG_INTERPRETER) += tci.o
 obj-$(CONFIG_TCG_INTERPRETER) += disas/tci.o
@@ -85,6 +86,8 @@  obj-y += disas.o
 obj-$(call notempty,$(TARGET_XML_FILES)) += gdbstub-xml.o
 obj-$(call lnot,$(CONFIG_KVM)) += kvm-stub.o
 
+replay/replay.o replay/replay-events.o replay/replay-internal.o: CFLAGS+= -Wno-unused-result
+
 obj-$(CONFIG_LIBDECNUMBER) += libdecnumber/decContext.o
 obj-$(CONFIG_LIBDECNUMBER) += libdecnumber/decNumber.o
 obj-$(CONFIG_LIBDECNUMBER) += libdecnumber/dpd/decimal32.o

diff --git a/net/Makefile.objs b/net/Makefile.objs
index a06ba59..cc6f32b
--- a/net/Makefile.objs
+++ b/net/Makefile.objs
@@ -1,6 +1,6 @@ 
 common-obj-y = net.o queue.o checksum.o util.o hub.o
 common-obj-y += socket.o
-common-obj-y += dump.o
+common-obj-y += dump.o net-replay.o
 common-obj-y += eth.o
 common-obj-$(CONFIG_LINUX) += l2tpv3.o
 common-obj-$(CONFIG_POSIX) += tap.o vhost-user.o