WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH 24 of 30] tools: Remove $(CFLAGS) from links lines

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH 24 of 30] tools: Remove $(CFLAGS) from links lines
From: Ian Campbell <ian.campbell@xxxxxxxxxx>
Date: Mon, 21 Mar 2011 14:44:47 +0000
Cc: Ian Campbell <ian.campbell@xxxxxxxxxx>
Delivery-date: Mon, 21 Mar 2011 08:14:24 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <patchbomb.1300718663@xxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Ian Campbell <ian.campbell@xxxxxxxxxx>
# Date 1300718506 0
# Node ID 83ba7f8b634d542fea896ab16ce3f80220d14cb1
# Parent  b298aa44524e9c36619eb00bffaa37f36c68acce
tools: Remove $(CFLAGS) from links lines.

The relevant variable in these circumstances is called $(LDFLAGS).

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>

diff -r b298aa44524e -r 83ba7f8b634d tools/blktap/drivers/Makefile
--- a/tools/blktap/drivers/Makefile     Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/blktap/drivers/Makefile     Mon Mar 21 14:41:46 2011 +0000
@@ -48,16 +48,16 @@ all: $(IBIN) qcow-util
 all: $(IBIN) qcow-util
 
 blktapctrl: $(BLKTAB-OBJS-y)
-       $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDLIBS_blktapctrl)
+       $(CC) $(LDFLAGS) -o $@ $^ $(LDLIBS_blktapctrl)
 
 tapdisk: tapdisk.o $(BLK-OBJS-y)
-       $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDLIBS_img)
+       $(CC) $(LDFLAGS) -o $@ $^ $(LDLIBS_img)
 
 .PHONY: qcow-util
 qcow-util: img2qcow qcow2raw qcow-create
 
 img2qcow qcow2raw qcow-create: %: %.o $(BLK-OBJS-y)
-       $(CC) $(CFLAGS) $(LDFLAGS) -o $* $^ $(LDLIBS_img)
+       $(CC) $(LDFLAGS) -o $* $^ $(LDLIBS_img)
 
 install: all
        $(INSTALL_PROG) $(IBIN) $(QCOW_UTIL) $(VHD_UTIL) $(DESTDIR)$(SBINDIR)
diff -r b298aa44524e -r 83ba7f8b634d tools/blktap/lib/Makefile
--- a/tools/blktap/lib/Makefile Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/blktap/lib/Makefile Mon Mar 21 14:41:46 2011 +0000
@@ -46,7 +46,7 @@ clean:
        rm -rf *.a *.so* *.o *.opic *.rpm $(LIB) *~ $(DEPS) xen TAGS
 
 libblktap.so.$(MAJOR).$(MINOR): $(OBJS_PIC) 
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,$(SONAME) 
$(SHLIB_LDFLAGS) \
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,$(SONAME) $(SHLIB_LDFLAGS) \
              -o $@ $^ $(LDLIBS)
        ln -sf libblktap.so.$(MAJOR).$(MINOR) libblktap.so.$(MAJOR)
        ln -sf libblktap.so.$(MAJOR) libblktap.so
diff -r b298aa44524e -r 83ba7f8b634d tools/blktap2/control/Makefile
--- a/tools/blktap2/control/Makefile    Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/blktap2/control/Makefile    Mon Mar 21 14:41:46 2011 +0000
@@ -56,13 +56,13 @@ build: $(IBIN) $(LIB_STATIC) $(LIB_SHARE
        ln -sf $< $@
 
 tap-ctl: tap-ctl.o $(LIBNAME).so
-       $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
+       $(CC) $(LDFLAGS) -o $@ $^
 
 $(LIB_STATIC): $(CTL_OBJS)
        $(AR) r $@ $^
 
 $(LIB_SHARED): $(CTL_PICS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -fPIC  -Wl,$(SONAME_LDFLAG) -Wl,$(LIBSONAME) 
$(SHLIB_LDFLAGS) -rdynamic $^ -o $@
+       $(CC) $(LDFLAGS) -fPIC  -Wl,$(SONAME_LDFLAG) -Wl,$(LIBSONAME) 
$(SHLIB_LDFLAGS) -rdynamic $^ -o $@
 
 install: $(IBIN) $(LIB_STATIC) $(LIB_SHARED)
        $(INSTALL_DIR) -p $(DESTDIR)$(SBINDIR)
diff -r b298aa44524e -r 83ba7f8b634d tools/blktap2/lvm/Makefile
--- a/tools/blktap2/lvm/Makefile        Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/blktap2/lvm/Makefile        Mon Mar 21 14:41:46 2011 +0000
@@ -28,7 +28,7 @@ install: all
 install: all
 
 lvm-util: lvm-util.o
-       $(CC) $(CFLAGS) -DLVM_UTIL $(LDFLAGS) -o lvm-util lvm-util.c
+       $(CC) -DLVM_UTIL $(LDFLAGS) -o lvm-util lvm-util.c
 
 clean:
        rm -rf *.o *~ $(DEPS) $(IBIN)
diff -r b298aa44524e -r 83ba7f8b634d tools/blktap2/vhd/Makefile
--- a/tools/blktap2/vhd/Makefile        Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/blktap2/vhd/Makefile        Mon Mar 21 14:41:46 2011 +0000
@@ -35,10 +35,10 @@ LIBS_DEPENDS          := lib/libvhd.so lib/vhd.
 $(LIBS_DEPENDS):subdirs-all
 
 vhd-util: vhd-util.o $(LIBS_DEPENDS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -o vhd-util vhd-util.o $(LIBS)
+       $(CC) $(LDFLAGS) -o vhd-util vhd-util.o $(LIBS)
 
 vhd-update: vhd-update.o $(LIBS_DEPENDS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -o vhd-update vhd-update.o $(LIBS)
+       $(CC) $(LDFLAGS) -o vhd-update vhd-update.o $(LIBS)
 
 install: all
        $(MAKE) subdirs-install
diff -r b298aa44524e -r 83ba7f8b634d tools/blktap2/vhd/lib/Makefile
--- a/tools/blktap2/vhd/lib/Makefile    Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/blktap2/vhd/lib/Makefile    Mon Mar 21 14:41:46 2011 +0000
@@ -56,7 +56,7 @@ build: $(LIBVHD-BUILD)
 build: $(LIBVHD-BUILD)
 
 libvhd.a: $(LIB-OBJS)
-       $(CC) $(CFLAGS) -Wl,$(SONAME_LDFLAG),$(LIBVHD-SONAME) $(SHLIB_LDFLAGS) \
+       $(CC) -Wl,$(SONAME_LDFLAG),$(LIBVHD-SONAME) $(SHLIB_LDFLAGS) \
                $(LDFLAGS) -o libvhd.so.$(LIBVHD-MAJOR).$(LIBVHD-MINOR) $^ 
$(LIBS)
        ln -sf libvhd.so.$(LIBVHD-MAJOR).$(LIBVHD-MINOR) 
libvhd.so.$(LIBVHD-MAJOR)
        ln -sf libvhd.so.$(LIBVHD-MAJOR) libvhd.so
diff -r b298aa44524e -r 83ba7f8b634d tools/console/Makefile
--- a/tools/console/Makefile    Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/console/Makefile    Mon Mar 21 14:41:46 2011 +0000
@@ -23,10 +23,10 @@ clean:
        $(RM) client/*.o daemon/*.o
 
 xenconsoled: $(patsubst %.c,%.o,$(wildcard daemon/*.c))
-       $(CC) $(CFLAGS) $^ -o $@ $(LDFLAGS) $(LDLIBS) $(LDLIBS_xenconsoled)
+       $(CC) $(LDFLAGS) $^ -o $@ $(LDLIBS) $(LDLIBS_xenconsoled)
 
 xenconsole: $(patsubst %.c,%.o,$(wildcard client/*.c))
-       $(CC) $(CFLAGS) $^ -o $@ $(LDFLAGS) $(LDLIBS) $(LDLIBS_xenconsole)
+       $(CC) $(LDFLAGS) $^ -o $@ $(LDLIBS) $(LDLIBS_xenconsole)
 
 .PHONY: install
 install: $(BIN)
diff -r b298aa44524e -r 83ba7f8b634d tools/debugger/kdd/Makefile
--- a/tools/debugger/kdd/Makefile       Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/debugger/kdd/Makefile       Mon Mar 21 14:41:46 2011 +0000
@@ -10,7 +10,7 @@ all: kdd
 all: kdd
 
 kdd: $(OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDLIBS)
+       $(CC) $(LDFLAGS) -o $@ $^ $(LDLIBS)
 
 .PHONY: clean
 clean:
diff -r b298aa44524e -r 83ba7f8b634d tools/flask/libflask/Makefile
--- a/tools/flask/libflask/Makefile     Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/flask/libflask/Makefile     Mon Mar 21 14:41:46 2011 +0000
@@ -56,6 +56,6 @@ libflask.so.$(MAJOR): libflask.so.$(MAJO
        ln -sf $< $@
 
 libflask.so.$(MAJOR).$(MINOR): $(PIC_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libflask.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^ $(LDLIBS_libxenctrl)
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libflask.so.$(MAJOR) 
$(SHLIB_LDFLAGS) -o $@ $^ $(LDLIBS_libxenctrl)
 
 -include $(DEPS)
diff -r b298aa44524e -r 83ba7f8b634d tools/flask/utils/Makefile
--- a/tools/flask/utils/Makefile        Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/flask/utils/Makefile        Mon Mar 21 14:41:46 2011 +0000
@@ -19,7 +19,7 @@ all: $(CLIENTS)
 all: $(CLIENTS)
 
 $(CLIENTS): flask-%: %.o
-       $(CC) $(CFLAGS) $(LDFLAGS) $< $(LDLIBS) -L$(LIBFLASK_ROOT) -lflask 
$(LDLIBS_libxenctrl) -o $@
+       $(CC) $(LDFLAGS) $< $(LDLIBS) -L$(LIBFLASK_ROOT) -lflask 
$(LDLIBS_libxenctrl) -o $@
 
 .PHONY: clean
 clean: 
diff -r b298aa44524e -r 83ba7f8b634d tools/libfsimage/Rules.mk
--- a/tools/libfsimage/Rules.mk Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/libfsimage/Rules.mk Mon Mar 21 14:41:46 2011 +0000
@@ -24,7 +24,7 @@ fs-install: fs-all
        $(INSTALL_PROG) $(FSLIB) $(DESTDIR)$(FSDIR)
 
 $(FSLIB): $(PIC_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) $(SHLIB_LDFLAGS) -o $@ $^ -lfsimage 
$(FS_LIBDEPS)
+       $(CC) $(LDFLAGS) $(SHLIB_LDFLAGS) -o $@ $^ -lfsimage $(FS_LIBDEPS)
 
 clean distclean:
        rm -f $(PIC_OBJS) $(FSLIB) $(DEPS)
diff -r b298aa44524e -r 83ba7f8b634d tools/libfsimage/common/Makefile
--- a/tools/libfsimage/common/Makefile  Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/libfsimage/common/Makefile  Mon Mar 21 14:41:46 2011 +0000
@@ -37,7 +37,7 @@ libfsimage.so.$(MAJOR): libfsimage.so.$(
        ln -sf $< $@
 
 libfsimage.so.$(MAJOR).$(MINOR): $(PIC_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libfsimage.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^ -lpthread
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libfsimage.so.$(MAJOR) 
$(SHLIB_LDFLAGS) -o $@ $^ -lpthread
 
 -include $(DEPS)
 
diff -r b298aa44524e -r 83ba7f8b634d tools/libxc/Makefile
--- a/tools/libxc/Makefile      Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/libxc/Makefile      Mon Mar 21 14:41:46 2011 +0000
@@ -157,7 +157,7 @@ libxenctrl.so.$(MAJOR): libxenctrl.so.$(
        ln -sf $< $@
 
 libxenctrl.so.$(MAJOR).$(MINOR): $(CTRL_PIC_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libxenctrl.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^ $(DLOPEN_LIBS) 
$(PTHREAD_LIBS)
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenctrl.so.$(MAJOR) 
$(SHLIB_LDFLAGS) -o $@ $^ $(DLOPEN_LIBS) $(PTHREAD_LIBS)
 
 # libxenguest
 
@@ -193,10 +193,10 @@ xc_dom_bzimageloader.opic: CFLAGS += $(c
 
 libxenguest.so.$(MAJOR).$(MINOR): COMPRESSION_LIBS = $(call zlib-options,l)
 libxenguest.so.$(MAJOR).$(MINOR): $(GUEST_PIC_OBJS) libxenctrl.so
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libxenguest.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $(GUEST_PIC_OBJS) 
$(COMPRESSION_LIBS) -lz $(LDLIBS_libxenctrl) $(PTHREAD_LIBS)
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenguest.so.$(MAJOR) 
$(SHLIB_LDFLAGS) -o $@ $(GUEST_PIC_OBJS) $(COMPRESSION_LIBS) -lz 
$(LDLIBS_libxenctrl) $(PTHREAD_LIBS)
 
 xenctrl_osdep_ENOSYS.so: $(OSDEP_PIC_OBJS) libxenctrl.so
-       $(CC) -g $(CFLAGS) $(LDFLAGS) $(SHLIB_LDFLAGS) -o $@ $(OSDEP_PIC_OBJS) 
$(LDLIBS_libxenctrl)
+       $(CC) -g $(LDFLAGS) $(SHLIB_LDFLAGS) -o $@ $(OSDEP_PIC_OBJS) 
$(LDLIBS_libxenctrl)
 
 -include $(DEPS)
 
diff -r b298aa44524e -r 83ba7f8b634d tools/libxen/Makefile
--- a/tools/libxen/Makefile     Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/libxen/Makefile     Mon Mar 21 14:41:46 2011 +0000
@@ -44,7 +44,7 @@ libxenapi.so.$(MAJOR): libxenapi.so.$(MA
        ln -sf $< $@
 
 libxenapi.so.$(MAJOR).$(MINOR): $(LIBXENAPI_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libxenapi.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenapi.so.$(MAJOR) 
$(SHLIB_LDFLAGS) -o $@ $^
 
 libxenapi.a: $(LIBXENAPI_OBJS)
        $(AR) rcs libxenapi.a $^
diff -r b298aa44524e -r 83ba7f8b634d tools/libxen/Makefile.dist
--- a/tools/libxen/Makefile.dist        Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/libxen/Makefile.dist        Mon Mar 21 14:41:46 2011 +0000
@@ -54,7 +54,7 @@ libxenapi.so.$(MAJOR): libxenapi.so.$(MA
        ln -sf $< $@
 
 libxenapi.so.$(MAJOR).$(MINOR): $(LIBXENAPI_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libxenapi.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenapi.so.$(MAJOR) 
$(SHLIB_LDFLAGS) -o $@ $^
 
 libxenapi.a: $(LIBXENAPI_OBJS)
        $(AR) rcs libxenapi.a $^
diff -r b298aa44524e -r 83ba7f8b634d tools/libxl/Makefile
--- a/tools/libxl/Makefile      Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/libxl/Makefile      Mon Mar 21 14:41:46 2011 +0000
@@ -85,7 +85,7 @@ libxenlight.so.$(MAJOR): libxenlight.so.
        ln -sf $< $@
 
 libxenlight.so.$(MAJOR).$(MINOR): $(LIBXL_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libxenlight.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^ $(LIBXL_LIBS)
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenlight.so.$(MAJOR) 
$(SHLIB_LDFLAGS) -o $@ $^ $(LIBXL_LIBS)
 
 libxenlight.a: $(LIBXL_OBJS)
        $(AR) rcs libxenlight.a $^
@@ -97,7 +97,7 @@ libxlutil.so.$(XLUMAJOR): libxlutil.so.$
        ln -sf $< $@
 
 libxlutil.so.$(XLUMAJOR).$(XLUMINOR): $(LIBXLU_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libxlutil.so.$(XLUMAJOR) $(SHLIB_LDFLAGS) -o $@ $^ $(LIBXLU_LIBS)
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxlutil.so.$(XLUMAJOR) 
$(SHLIB_LDFLAGS) -o $@ $^ $(LIBXLU_LIBS)
 
 libxlutil.a: $(LIBXLU_OBJS)
        $(AR) rcs libxlutil.a $^
diff -r b298aa44524e -r 83ba7f8b634d tools/misc/Makefile
--- a/tools/misc/Makefile       Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/misc/Makefile       Mon Mar 21 14:41:46 2011 +0000
@@ -58,9 +58,9 @@ clean:
        $(CC) -c $(CFLAGS) -o $@ $<
 
 xen-hvmctx xen-hvmcrash xenperf xenpm gtracestat xenlockprof xen-hptool 
xenwatchdogd: %: %.o Makefile
-       $(CC) $(CFLAGS) -o $@ $< $(LDFLAGS) $(LDLIBS_$*)
+       $(CC) $(LDFLAGS) -o $@ $< $(LDLIBS_$*)
 
 gtraceview: %: %.o Makefile
-       $(CC) $(CFLAGS) -o $@ $< $(LDFLAGS) $(CURSES_LIBS)
+       $(CC) $(LDFLAGS) -o $@ $< $(CURSES_LIBS)
 
 -include $(DEPS)
diff -r b298aa44524e -r 83ba7f8b634d tools/ocaml/Makefile.rules
--- a/tools/ocaml/Makefile.rules        Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/ocaml/Makefile.rules        Mon Mar 21 14:41:46 2011 +0000
@@ -84,7 +84,7 @@ endef
 
 define C_PROGRAM_template
  $(1): $(foreach obj,$($(1)_OBJS),$(obj).o)
-       $(call quiet-command, $(CC) $(CFLAGS) -o $$@ $$+,BIN,$$@)
+       $(call quiet-command, $(CC) $(LDFLAGS) -o $$@ $$+,BIN,$$@)
 endef
 
 -include .ocamldep.make
diff -r b298aa44524e -r 83ba7f8b634d tools/security/Makefile
--- a/tools/security/Makefile   Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/security/Makefile   Mon Mar 21 14:41:46 2011 +0000
@@ -76,7 +76,7 @@ build: $(ACM_INST_TOOLS) $(ACM_NOINST_TO
        chmod 700 $(ACM_SCRIPTS)
 
 xensec_tool: $(OBJS_TOOL)
-       $(CC) -g $(CFLAGS) $(LDFLAGS) -O0 -o $@ $^ $(LDLIBS_libxenctrl)
+       $(CC) -g $(LDFLAGS) -O0 -o $@ $^ $(LDLIBS_libxenctrl)
 
 xensec_gen: xensec_gen.py
        cp -f $^ $@
diff -r b298aa44524e -r 83ba7f8b634d tools/tests/mce-test/tools/Makefile
--- a/tools/tests/mce-test/tools/Makefile       Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/tests/mce-test/tools/Makefile       Mon Mar 21 14:41:46 2011 +0000
@@ -18,8 +18,5 @@ clean:
 clean:
        $(RM) *.o xen-mceinj
 
-%.o: %.c $(HDRS) Makefile
-       $(CC) -c $(CFLAGS) -o $@ $<
-
 xen-mceinj: %: %.o Makefile
-       $(CC) $(CFLAGS) -o $@ $< $(LDFLAGS) $(LDLIBS_libxenctrl) 
$(LDLIBS_libxenguest) $(LDLIBS_libxenstore)
+       $(CC) -o $@ $< $(LDFLAGS) $(LDLIBS_libxenctrl) $(LDLIBS_libxenguest) 
$(LDLIBS_libxenstore)
diff -r b298aa44524e -r 83ba7f8b634d tools/tests/xen-access/Makefile
--- a/tools/tests/xen-access/Makefile   Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/tests/xen-access/Makefile   Mon Mar 21 14:41:46 2011 +0000
@@ -25,10 +25,7 @@ clean:
        $(RM) *.o $(TARGETS) *~ $(DEPS)
        set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d clean; done
 
-%.o: %.c Makefile
-       $(CC) -c $(CFLAGS) -o $@ $<
+xen-access: %: %.o Makefile
+       $(CC) -o $@ $< $(LDFLAGS) $(LDLIBS_libxenctrl)
 
-xen-access: %: %.o Makefile
-       $(CC) $(CFLAGS) -o $@ $< $(LDFLAGS) $(LDLIBS_libxenctrl)
-# $(LDLIBS_libxenguest) $(LDLIBS_libxenstore)
 -include $(DEPS)
diff -r b298aa44524e -r 83ba7f8b634d tools/vtpm_manager/manager/Makefile
--- a/tools/vtpm_manager/manager/Makefile       Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/vtpm_manager/manager/Makefile       Mon Mar 21 14:41:46 2011 +0000
@@ -29,7 +29,7 @@ mrproper: clean
        rm -f *~
 
 $(BIN): $(OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) $^ $(LIBS) -o $@
+       $(CC) $(LDFLAGS) $^ $(LIBS) -o $@
 
 # libraries
 LIBS += ../tcs/libTCS.a ../util/libTCGUtils.a ../crypto/libtcpaCrypto.a
diff -r b298aa44524e -r 83ba7f8b634d tools/vtpm_manager/migration/Makefile
--- a/tools/vtpm_manager/migration/Makefile     Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/vtpm_manager/migration/Makefile     Mon Mar 21 14:41:46 2011 +0000
@@ -33,10 +33,10 @@ mrproper: clean
        rm -f *~
 
 $(BIND): $(OBJSD)
-       $(CC) $(CFLAGS) $(LDFLAGS) $^ $(LIBS) -o $@
+       $(CC) $(LDFLAGS) $^ $(LIBS) -o $@
 
 $(BINC): $(OBJSC)
-       $(CC) $(CFLAGS) $(LDFLAGS) $^ $(LIBS) -o $@
+       $(CC) $(LDFLAGS) $^ $(LIBS) -o $@
 
 # libraries
 LIBS += ../util/libTCGUtils.a
diff -r b298aa44524e -r 83ba7f8b634d tools/xcutils/Makefile
--- a/tools/xcutils/Makefile    Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/xcutils/Makefile    Mon Mar 21 14:41:46 2011 +0000
@@ -11,15 +11,14 @@ XEN_ROOT    = $(CURDIR)/../..
 XEN_ROOT       = $(CURDIR)/../..
 include $(XEN_ROOT)/tools/Rules.mk
 
-
 PROGRAMS = xc_restore xc_save readnotes lsevtchn
 
 CFLAGS += -Werror
 
-CFLAGS_xc_restore := $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest)
-CFLAGS_xc_save    := $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest) 
$(CFLAGS_libxenstore)
-CFLAGS_readnotes  := $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest)
-CFLAGS_lsevtchn   := $(CFLAGS_libxenctrl)
+CFLAGS_xc_restore.o := $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest)
+CFLAGS_xc_save.o    := $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest) 
$(CFLAGS_libxenstore)
+CFLAGS_readnotes.o  := $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest)
+CFLAGS_lsevtchn.o   := $(CFLAGS_libxenctrl)
 
 LDLIBS_xc_restore := $(LDLIBS_libxenctrl) $(LDLIBS_libxenguest)
 LDLIBS_xc_save    := $(LDLIBS_libxenctrl) $(LDLIBS_libxenguest) 
$(LDLIBS_libxenstore)
@@ -32,11 +31,8 @@ all: build
 .PHONY: build
 build: $(PROGRAMS)
 
-%.o: %.c
-       $(CC) $(CFLAGS) $(CFLAGS_$*) -c $^ -o $@
-
 $(PROGRAMS): %: %.o
-       $(CC) $(CFLAGS) $(LDFLAGS) $^ $(LDLIBS) $(LDLIBS_$*) -o $@
+       $(CC) $(LDFLAGS) $^ $(LDLIBS) $(LDLIBS_$*) -o $@
 
 .PHONY: install
 install: build
diff -r b298aa44524e -r 83ba7f8b634d tools/xenbackendd/Makefile
--- a/tools/xenbackendd/Makefile        Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/xenbackendd/Makefile        Mon Mar 21 14:41:46 2011 +0000
@@ -35,7 +35,7 @@ clean:
        rm -f $(SBIN) $(DEPS)
 
 
-%: %.c Makefile
-       $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) $< -o $@ $(LDLIBS)
+%: %.o Makefile
+       $(CC) $(LDFLAGS) $< -o $@ $(LDLIBS)
 
 -include $(DEPS)
diff -r b298aa44524e -r 83ba7f8b634d tools/xenmon/Makefile
--- a/tools/xenmon/Makefile     Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/xenmon/Makefile     Mon Mar 21 14:41:46 2011 +0000
@@ -40,9 +40,10 @@ clean:
        rm -f $(BIN) $(DEPS)
 
 
-%: %.c Makefile
-       $(CC) $(CFLAGS) $(LDFLAGS) $< -o $@ $(LDLIBS)
-xentrace_%: %.c Makefile
-       $(CC) $(CFLAGS) $(LDFLAGS) $< -o $@ $(LDLIBS)
+%: %.o Makefile
+       $(CC) $(LDFLAGS) $< -o $@ $(LDLIBS)
+
+xentrace_%: %.o Makefile
+       $(CC) $(LDFLAGS) $< -o $@ $(LDLIBS)
 
 -include $(DEPS)
diff -r b298aa44524e -r 83ba7f8b634d tools/xenpaging/Makefile
--- a/tools/xenpaging/Makefile  Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/xenpaging/Makefile  Mon Mar 21 14:41:46 2011 +0000
@@ -22,7 +22,7 @@ all: $(IBINS)
 all: $(IBINS)
 
 xenpaging: $(OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDLIBS)
+       $(CC) $(LDFLAGS) -o $@ $^ $(LDLIBS)
 
 install: all
        $(INSTALL_DIR) $(DESTDIR)/var/lib/xen/xenpaging
diff -r b298aa44524e -r 83ba7f8b634d tools/xenpmd/Makefile
--- a/tools/xenpmd/Makefile     Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/xenpmd/Makefile     Mon Mar 21 14:41:46 2011 +0000
@@ -1,8 +1,9 @@ XEN_ROOT=$(CURDIR)/../..
 XEN_ROOT=$(CURDIR)/../..
 include $(XEN_ROOT)/tools/Rules.mk
 
-CFLAGS  += -Werror
-CFLAGS  += $(CFLAGS_libxenstore)
+CFLAGS += -Werror
+CFLAGS += $(CFLAGS_libxenstore)
+
 LDLIBS += $(LDLIBS_libxenstore)
 
 BIN      = xenpmd
@@ -19,7 +20,7 @@ clean:
 clean:
        $(RM) -f $(BIN) $(DEPS)
 
-%: %.c Makefile
-       $(CC) $(CFLAGS) $(LDFLAGS) $< -o $@ $(LDLIBS)
+%: %.o Makefile
+       $(CC) $(LDFLAGS) $< -o $@ $(LDLIBS)
 
 -include $(DEPS)
diff -r b298aa44524e -r 83ba7f8b634d tools/xenstat/libxenstat/Makefile
--- a/tools/xenstat/libxenstat/Makefile Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/xenstat/libxenstat/Makefile Mon Mar 21 14:41:46 2011 +0000
@@ -49,17 +49,8 @@ all: $(LIB) $(SHLIB) $(SHLIB_LINKS)
        $(RANLIB) $@
 
 $(SHLIB): $(OBJECTS-y)
-       $(CC) $(CFLAGS) $(LDFLAGS) $(SONAME_FLAGS) $(SHLIB_LDFLAGS) -o $@ \
+       $(CC) $(LDFLAGS) $(SONAME_FLAGS) $(SHLIB_LDFLAGS) -o $@ \
            $(OBJECTS-y) $(LDLIBS-y)
-
-src/xenstat.o: src/xenstat.c src/xenstat.h src/xenstat_priv.h
-       $(CC) $(CFLAGS) $(WARN_FLAGS) -c -o $@ $<
-
-src/xenstat_linux.o: src/xenstat_linux.c src/xenstat_priv.h
-       $(CC) $(CFLAGS) $(WARN_FLAGS) -c -o $@ $<
-
-src/xenstat_solaris.o: src/xenstat_solaris.c src/xenstat_priv.h
-       $(CC) $(CFLAGS) $(WARN_FLAGS) -c -o $@ $<
 
 src/libxenstat.so.$(MAJOR): $(SHLIB)
        $(MAKE_LINK) $(<F) $@
diff -r b298aa44524e -r 83ba7f8b634d tools/xenstore/Makefile
--- a/tools/xenstore/Makefile   Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/xenstore/Makefile   Mon Mar 21 14:41:46 2011 +0000
@@ -47,19 +47,19 @@ endif
 endif
  
 xenstored: $(XENSTORED_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) $^ $(LDLIBS_libxenctrl) $(SOCKET_LIBS) -o $@
+       $(CC) $(LDFLAGS) $^ $(LDLIBS_libxenctrl) $(SOCKET_LIBS) -o $@
 
 $(CLIENTS): xenstore
        ln -f xenstore $@
 
 xenstore: xenstore_client.o $(LIBXENSTORE)
-       $(CC) $(CFLAGS) $(LDFLAGS) $< $(LDLIBS_libxenstore) $(SOCKET_LIBS) -o $@
+       $(CC) $(LDFLAGS) $< $(LDLIBS_libxenstore) $(SOCKET_LIBS) -o $@
 
 xenstore-control: xenstore_control.o $(LIBXENSTORE)
-       $(CC) $(CFLAGS) $(LDFLAGS) $< $(LDLIBS_libxenstore) $(SOCKET_LIBS) -o $@
+       $(CC) $(LDFLAGS) $< $(LDLIBS_libxenstore) $(SOCKET_LIBS) -o $@
 
 xs_tdb_dump: xs_tdb_dump.o utils.o tdb.o talloc.o
-       $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@
+       $(CC) $(LDFLAGS) $^ -o $@
 
 libxenstore.so: libxenstore.so.$(MAJOR)
        ln -sf $< $@
@@ -69,7 +69,7 @@ xs.opic: CFLAGS += -DUSE_PTHREAD
 xs.opic: CFLAGS += -DUSE_PTHREAD
 
 libxenstore.so.$(MAJOR).$(MINOR): xs.opic xs_lib.opic
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libxenstore.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^ $(SOCKET_LIBS) -lpthread
+       $(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenstore.so.$(MAJOR) 
$(SHLIB_LDFLAGS) -o $@ $^ $(SOCKET_LIBS) -lpthread
 
 libxenstore.a: xs.o xs_lib.o
        $(AR) rcs $@ $^
diff -r b298aa44524e -r 83ba7f8b634d tools/xentrace/Makefile
--- a/tools/xentrace/Makefile   Mon Mar 21 14:41:46 2011 +0000
+++ b/tools/xentrace/Makefile   Mon Mar 21 14:41:46 2011 +0000
@@ -1,9 +1,9 @@ XEN_ROOT=$(CURDIR)/../..
 XEN_ROOT=$(CURDIR)/../..
 include $(XEN_ROOT)/tools/Rules.mk
 
-CFLAGS  += -Werror
+CFLAGS += -Werror
 
-CFLAGS  += $(CFLAGS_libxenctrl)
+CFLAGS += $(CFLAGS_libxenctrl)
 LDLIBS += $(LDLIBS_libxenctrl)
 
 HDRS     = $(wildcard *.h)
@@ -49,10 +49,10 @@ clean:
 clean:
        $(RM) *.a *.so *.o *.rpm $(BIN) $(LIBBIN) $(DEPS)
 
-%: %.c $(HDRS) Makefile
-       $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LDLIBS)
-xentrace_%: %.c $(HDRS) Makefile
-       $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LDLIBS)
+%: %.o $(HDRS) Makefile
+       $(CC) $(LDFLAGS) -o $@ $< $(LDLIBS)
+xentrace_%: %.o $(HDRS) Makefile
+       $(CC) $(LDFLAGS) -o $@ $< $(LDLIBS)
 
 -include $(DEPS)
 

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>