aboutsummaryrefslogtreecommitdiffstats
path: root/tools/debugger/gdbsx/xg/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'tools/debugger/gdbsx/xg/Makefile')
-rw-r--r--tools/debugger/gdbsx/xg/Makefile36
1 files changed, 36 insertions, 0 deletions
diff --git a/tools/debugger/gdbsx/xg/Makefile b/tools/debugger/gdbsx/xg/Makefile
new file mode 100644
index 0000000000..4ea695987e
--- /dev/null
+++ b/tools/debugger/gdbsx/xg/Makefile
@@ -0,0 +1,36 @@
+XEN_ROOT = ../../../..
+include ../Rules.mk
+
+XG_HDRS := xg_public.h
+XG_OBJS := xg_main.o
+
+CFLAGS += $(INCLUDES) -I. -I../../../include
+
+
+.PHONY: all
+all: build
+
+.PHONY: build
+build: xen-headers xg_all.a $(XG_HDRS) $(XG_OBJS) Makefile
+# build: mk-symlinks xg_all.a $(XG_HDRS) $(XG_OBJS) Makefile
+# build: mk-symlinks xg_all.a
+
+xg_all.a: $(XG_OBJS) Makefile $(XG_HDRS)
+ ar cr $@ $(XG_OBJS) # problems using -m32 in ld
+# $(LD) -b elf32-i386 $(LDFLAGS) -r -o $@ $^
+# $(CC) -m32 -c -o $@ $^
+
+xen-headers:
+ $(MAKE) -C ../../../check
+ $(MAKE) -C ../../../include
+
+# xg_main.o: xg_main.c Makefile $(XG_HDRS)
+#$(CC) -c $(CFLAGS) -o $@ $<
+
+# %.o: %.c $(XG_HDRS) Makefile -- doesn't work as it won't overwrite Rules.mk
+#%.o: %.c -- doesn't recompile when .c changed
+
+.PHONY: clean
+clean:
+ rm -rf xen xg_all.a $(XG_OBJS)
+