[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [PATCH RFC] tools/xenlight: Create xenlight Makefile



Created basic Makfele for the Golang xenlight
project so that the project is built and
installed. A template template is alo added.
---
 tools/Makefile                    | 15 +++++++++++++++
 tools/golang/xenlight/Makefile    | 29 +++++++++++++++++++++++++++++
 tools/golang/xenlight/xenlight.go |  7 +++++++
 3 files changed, 51 insertions(+)
 create mode 100644 tools/golang/xenlight/Makefile
 create mode 100644 tools/golang/xenlight/xenlight.go

diff --git a/tools/Makefile b/tools/Makefile
index 71515b4..b89f06b 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -11,6 +11,7 @@ SUBDIRS-y += misc
 SUBDIRS-y += examples
 SUBDIRS-y += hotplug
 SUBDIRS-y += xentrace
+SUBDIRS-y += golang/xenlight
 SUBDIRS-$(CONFIG_XCUTILS) += xcutils
 SUBDIRS-$(CONFIG_X86) += firmware
 SUBDIRS-y += console
@@ -311,6 +312,20 @@ subdir-install-debugger/gdbsx: .phony
 subdir-all-debugger/gdbsx: .phony
        $(MAKE) -C debugger/gdbsx all
 
+subdir-all-golang/xenlight: .phony
+       $(MAKE) -C golang/xenlight all
+
+subdir-clean-golang/xenlight: .phony
+       $(MAKE) -C golang/xenlight clean
+
+subdir-install-golang/xenlight: .phony
+       $(MAKE) -C golang/xenlight install
+
+subdir-build-golang/xenlight: .phony
+       $(MAKE) -C golang/xenlight build
+
+subdir-distclean-golang/xenlight: .phony
+       $(MAKE) -C golang/xenlight distclean
 
 subdir-clean-debugger/kdd subdir-distclean-debugger/kdd: .phony
        $(MAKE) -C debugger/kdd clean
diff --git a/tools/golang/xenlight/Makefile b/tools/golang/xenlight/Makefile
new file mode 100644
index 0000000..c723c1d
--- /dev/null
+++ b/tools/golang/xenlight/Makefile
@@ -0,0 +1,29 @@
+XEN_ROOT=$(CURDIR)/../../..
+include $(XEN_ROOT)/tools/Rules.mk
+
+BINARY = xenlightgo
+GO = go
+
+.PHONY: all
+all: build
+
+.PHONY: build
+build: xenlight
+
+.PHONY: install
+install: build
+       [ -f $(BINARY) ] || $(INSTALL_PROG) xenlight.go $(DESTDIR)$(bindir)
+
+.PHONY: clean
+clean:
+       $(RM) $(BINARY)
+
+.PHONY: distclean
+distclean: clean
+
+
+xenlight: xenlight.go
+       $(GO) build -o $(BINARY) xenlight.go
+
+
+-include $(DEPS)
diff --git a/tools/golang/xenlight/xenlight.go 
b/tools/golang/xenlight/xenlight.go
new file mode 100644
index 0000000..50e8d8d
--- /dev/null
+++ b/tools/golang/xenlight/xenlight.go
@@ -0,0 +1,7 @@
+package main
+
+import "fmt"
+
+func main() {
+       fmt.Println("vim-go")
+}
-- 
2.7.4


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.