[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] Re: [RFC2] Add stubdomain support
Keir Fraser, le Tue 12 Feb 2008 14:32:25 +0000, a écrit : > Applied Cool! > please send another patch to override XEN_OS and hence present > yourself as a new 'OS environment' to the overall build system. That'll > clean up a good number of your Makefile changes outside stubdom/. It does indeed, here it is. Make stubdom/Makefile override XEN_OS to MiniOS, and add config/MiniOS.mk. Add PTHREAD_LIBS to configs (usually holding -lpthread). Signed-off-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxxx> diff -r d0b12316994b Config.mk --- a/Config.mk Tue Feb 12 14:47:14 2008 +0000 +++ b/Config.mk Tue Feb 12 14:51:43 2008 +0000 @@ -27,14 +27,6 @@ DESTDIR ?= / include $(XEN_ROOT)/config/$(XEN_OS).mk include $(XEN_ROOT)/config/$(XEN_TARGET_ARCH).mk - -ifeq ($(stubdom),y) -include $(XEN_ROOT)/extras/mini-os/Config.mk -CFLAGS += $(DEF_CFLAGS) $(ARCH_CFLAGS) -CPPFLAGS += $(DEF_CPPFLAGS) $(ARCH_CPPFLAGS) $(extra_incl) -ASFLAGS += $(DEF_ASFLAGS) $(ARCH_ASFLAGS) -LDFLAGS += $(DEF_LDFLAGS) $(ARCH_LDFLAGS) -endif ifneq ($(EXTRA_PREFIX),) EXTRA_INCLUDES += $(EXTRA_PREFIX)/include diff -r d0b12316994b config/MiniOS.mk --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/config/MiniOS.mk Tue Feb 12 14:51:43 2008 +0000 @@ -0,0 +1,9 @@ +include $(XEN_ROOT)/config/StdGNU.mk +include $(XEN_ROOT)/extras/mini-os/Config.mk +CFLAGS += $(DEF_CFLAGS) $(ARCH_CFLAGS) +CPPFLAGS += $(DEF_CPPFLAGS) $(ARCH_CPPFLAGS) $(extra_incl) +ASFLAGS += $(DEF_ASFLAGS) $(ARCH_ASFLAGS) +LDFLAGS += $(DEF_LDFLAGS) $(ARCH_LDFLAGS) + +# Override settings for this OS +PTHREAD_LIBS = diff -r d0b12316994b config/StdGNU.mk --- a/config/StdGNU.mk Tue Feb 12 14:47:14 2008 +0000 +++ b/config/StdGNU.mk Tue Feb 12 14:51:43 2008 +0000 @@ -35,6 +35,7 @@ PRIVATE_BINDIR = $(PRIVATE_PREFIX)/bin SOCKET_LIBS = CURSES_LIBS = -lncurses +PTHREAD_LIBS = -lpthread UTIL_LIBS = -lutil SONAME_LDFLAG = -soname SHLIB_CFLAGS = -shared diff -r d0b12316994b config/SunOS.mk --- a/config/SunOS.mk Tue Feb 12 14:47:14 2008 +0000 +++ b/config/SunOS.mk Tue Feb 12 14:51:43 2008 +0000 @@ -39,6 +39,7 @@ SunOS_LIBDIR_x86_64 = /usr/sfw/lib/amd64 SOCKET_LIBS = -lsocket CURSES_LIBS = -lcurses +PTHREAD_LIBS = -lpthread UTIL_LIBS = SONAME_LDFLAG = -h SHLIB_CFLAGS = -R $(SunOS_LIBDIR) -shared diff -r d0b12316994b stubdom/Makefile --- a/stubdom/Makefile Tue Feb 12 14:47:14 2008 +0000 +++ b/stubdom/Makefile Tue Feb 12 14:51:43 2008 +0000 @@ -1,4 +1,6 @@ XEN_ROOT = .. XEN_ROOT = .. + +export XEN_OS=MiniOS include $(XEN_ROOT)/Config.mk export stubdom=y diff -r d0b12316994b tools/libxc/Makefile --- a/tools/libxc/Makefile Tue Feb 12 14:47:14 2008 +0000 +++ b/tools/libxc/Makefile Tue Feb 12 14:51:43 2008 +0000 @@ -25,13 +25,11 @@ CTRL_SRCS-y += xc_resume.c CTRL_SRCS-y += xc_resume.c endif CTRL_SRCS-$(CONFIG_X86) += xc_pagetab.c -ifneq ($(stubdom),y) CTRL_SRCS-$(CONFIG_Linux) += xc_linux.c CTRL_SRCS-$(CONFIG_SunOS) += xc_solaris.c CTRL_SRCS-$(CONFIG_X86_Linux) += xc_ptrace.c xc_ptrace_core.c CTRL_SRCS-$(CONFIG_NetBSD) += xc_netbsd.c -endif -CTRL_SRCS-$(stubdom) += xc_minios.c +CTRL_SRCS-$(CONFIG_MiniOS) += xc_minios.c GUEST_SRCS-y := GUEST_SRCS-y += xg_private.c @@ -74,10 +72,6 @@ CFLAGS += -Wp,-MD,.$(@F).d CFLAGS += -Wp,-MD,.$(@F).d LDFLAGS += -L. DEPS = .*.d - -ifneq ($(stubdom),y) -LDLIBS = -lpthread -endif CTRL_LIB_OBJS := $(patsubst %.c,%.o,$(CTRL_SRCS-y)) CTRL_PIC_OBJS := $(patsubst %.c,%.opic,$(CTRL_SRCS-y)) @@ -152,7 +146,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_CFLAGS) -o $@ $^ $(LDLIBS) + $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenctrl.so.$(MAJOR) $(SHLIB_CFLAGS) -o $@ $^ $(PTHREAD_LIBS) # libxenguest @@ -165,7 +159,7 @@ libxenguest.so.$(MAJOR): libxenguest.so. ln -sf $< $@ libxenguest.so.$(MAJOR).$(MINOR): $(GUEST_PIC_OBJS) libxenctrl.so - $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenguest.so.$(MAJOR) $(SHLIB_CFLAGS) -o $@ $(GUEST_PIC_OBJS) -lz -lxenctrl $(LDLIBS) + $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenguest.so.$(MAJOR) $(SHLIB_CFLAGS) -o $@ $(GUEST_PIC_OBJS) -lz -lxenctrl $(PTHREAD_LIBS) -include $(DEPS) _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |