|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] libxl: fix api check Makefile
# HG changeset patch
# User Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
# Date 1346667721 -3600
# Node ID d27de715b2edd2ae347944491b8dfe739e5ae4bb
# Parent 8c2cd070f258ba7dbdf3f6ca318a284a44378078
libxl: fix api check Makefile
Touch the libxl.api-ok stamp file, and unconditionally put in place
the new _libxl.api-for-check. This avoids needlessly rerunning the
preprocessor on libxl.h each time we call "make".
Ensure that _libxl.api-for-check gets the CFLAGS used for xl, so that
if it is asked for in a standalone make run it can find xentoollog.h.
Remove *.api-ok on clean.
Also fix .gitignore.
Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
Committed-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
---
diff -r 8c2cd070f258 -r d27de715b2ed .gitignore
--- a/.gitignore Mon Sep 03 11:22:00 2012 +0100
+++ b/.gitignore Mon Sep 03 11:22:01 2012 +0100
@@ -189,7 +189,8 @@ tools/libxl/xl
tools/libxl/testenum
tools/libxl/testenum.c
tools/libxl/tmp.*
-tools/libxl/libxl.api-for-check
+tools/libxl/_libxl.api-for-check
+tools/libxl/*.api-ok
tools/libaio/src/*.ol
tools/libaio/src/*.os
tools/misc/cpuperf/cpuperf-perfcntr
diff -r 8c2cd070f258 -r d27de715b2ed .hgignore
--- a/.hgignore Mon Sep 03 11:22:00 2012 +0100
+++ b/.hgignore Mon Sep 03 11:22:01 2012 +0100
@@ -188,6 +188,7 @@
^tools/libxl/tmp\..*$
^tools/libxl/.*\.new$
^tools/libxl/_libxl\.api-for-check
+^tools/libxl/libxl\.api-ok
^tools/libvchan/vchan-node[12]$
^tools/libaio/src/.*\.ol$
^tools/libaio/src/.*\.os$
diff -r 8c2cd070f258 -r d27de715b2ed tools/libxl/Makefile
--- a/tools/libxl/Makefile Mon Sep 03 11:22:00 2012 +0100
+++ b/tools/libxl/Makefile Mon Sep 03 11:22:01 2012 +0100
@@ -85,7 +85,8 @@ LIBXLU_OBJS = libxlu_cfg_y.o libxlu_cfg_
CLIENTS = xl testidl libxl-save-helper
XL_OBJS = xl.o xl_cmdimpl.o xl_cmdtable.o xl_sxp.o
-$(XL_OBJS): CFLAGS += $(CFLAGS_libxenctrl) # For xentoollog.h
+$(XL_OBJS) _libxl.api-for-check: \
+ CFLAGS += $(CFLAGS_libxenctrl) # For xentoollog.h
$(XL_OBJS): CFLAGS += $(CFLAGS_libxenlight)
$(XL_OBJS): CFLAGS += -include $(XEN_ROOT)/tools/config.h # libxl_json.h needs
it.
@@ -116,12 +117,13 @@ genpath-target = $(call buildmakevars2fi
libxl.api-ok: check-libxl-api-rules _libxl.api-for-check
$(PERL) $^
+ touch $@
_%.api-for-check: %.h
$(CC) $(CPPFLAGS) $(CFLAGS) $(CFLAGS_$*.o) -c -E $< $(APPEND_CFLAGS) \
-DLIBXL_EXTERNAL_CALLERS_ONLY=LIBXL_EXTERNAL_CALLERS_ONLY \
>$@.new
- $(call move-if-changed,$@.new,$@)
+ mv -f $@.new $@
_paths.h: genpath
sed -e "s/\([^=]*\)=\(.*\)/#define \1 \2/g" $@.tmp >$@.2.tmp
@@ -211,7 +213,7 @@ install: all
clean:
$(RM) -f _*.h *.o *.so* *.a $(CLIENTS) $(DEPS)
$(RM) -f _*.c *.pyc _paths.*.tmp _*.api-for-check
- $(RM) -f testidl.c.new testidl.c
+ $(RM) -f testidl.c.new testidl.c *.api-ok
distclean: clean
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |