ia64/xen-unstable

changeset 17046:7e91007fa727

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@eu.citrix.com>
author Keir Fraser <keir.fraser@citrix.com>
date Tue Feb 12 15:03:07 2008 +0000 (2008-02-12)
parents 761604c6136d
children 2424c6a3a0ed
files Config.mk config/MiniOS.mk config/StdGNU.mk config/SunOS.mk stubdom/Makefile tools/libxc/Makefile
line diff
     1.1 --- a/Config.mk	Tue Feb 12 14:59:22 2008 +0000
     1.2 +++ b/Config.mk	Tue Feb 12 15:03:07 2008 +0000
     1.3 @@ -28,14 +28,6 @@ DESTDIR     ?= /
     1.4  include $(XEN_ROOT)/config/$(XEN_OS).mk
     1.5  include $(XEN_ROOT)/config/$(XEN_TARGET_ARCH).mk
     1.6  
     1.7 -ifeq ($(stubdom),y)
     1.8 -include $(XEN_ROOT)/extras/mini-os/Config.mk
     1.9 -CFLAGS += $(DEF_CFLAGS) $(ARCH_CFLAGS)
    1.10 -CPPFLAGS += $(DEF_CPPFLAGS) $(ARCH_CPPFLAGS) $(extra_incl)
    1.11 -ASFLAGS += $(DEF_ASFLAGS) $(ARCH_ASFLAGS)
    1.12 -LDFLAGS += $(DEF_LDFLAGS) $(ARCH_LDFLAGS)
    1.13 -endif
    1.14 -
    1.15  ifneq ($(EXTRA_PREFIX),)
    1.16  EXTRA_INCLUDES += $(EXTRA_PREFIX)/include
    1.17  EXTRA_LIB += $(EXTRA_PREFIX)/$(LIBLEAFDIR)
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/config/MiniOS.mk	Tue Feb 12 15:03:07 2008 +0000
     2.3 @@ -0,0 +1,9 @@
     2.4 +include $(XEN_ROOT)/config/StdGNU.mk
     2.5 +include $(XEN_ROOT)/extras/mini-os/Config.mk
     2.6 +CFLAGS += $(DEF_CFLAGS) $(ARCH_CFLAGS)
     2.7 +CPPFLAGS += $(DEF_CPPFLAGS) $(ARCH_CPPFLAGS) $(extra_incl)
     2.8 +ASFLAGS += $(DEF_ASFLAGS) $(ARCH_ASFLAGS)
     2.9 +LDFLAGS += $(DEF_LDFLAGS) $(ARCH_LDFLAGS)
    2.10 +
    2.11 +# Override settings for this OS
    2.12 +PTHREAD_LIBS =
     3.1 --- a/config/StdGNU.mk	Tue Feb 12 14:59:22 2008 +0000
     3.2 +++ b/config/StdGNU.mk	Tue Feb 12 15:03:07 2008 +0000
     3.3 @@ -35,6 +35,7 @@ PRIVATE_BINDIR = $(PRIVATE_PREFIX)/bin
     3.4  
     3.5  SOCKET_LIBS =
     3.6  CURSES_LIBS = -lncurses
     3.7 +PTHREAD_LIBS = -lpthread
     3.8  UTIL_LIBS = -lutil
     3.9  SONAME_LDFLAG = -soname
    3.10  SHLIB_CFLAGS = -shared
     4.1 --- a/config/SunOS.mk	Tue Feb 12 14:59:22 2008 +0000
     4.2 +++ b/config/SunOS.mk	Tue Feb 12 15:03:07 2008 +0000
     4.3 @@ -39,6 +39,7 @@ SunOS_LIBDIR_x86_64 = /usr/sfw/lib/amd64
     4.4  
     4.5  SOCKET_LIBS = -lsocket
     4.6  CURSES_LIBS = -lcurses
     4.7 +PTHREAD_LIBS = -lpthread
     4.8  UTIL_LIBS =
     4.9  SONAME_LDFLAG = -h
    4.10  SHLIB_CFLAGS = -R $(SunOS_LIBDIR) -shared
     5.1 --- a/stubdom/Makefile	Tue Feb 12 14:59:22 2008 +0000
     5.2 +++ b/stubdom/Makefile	Tue Feb 12 15:03:07 2008 +0000
     5.3 @@ -1,5 +1,7 @@
     5.4  XEN_ROOT = ..
     5.5  
     5.6 +export XEN_OS=MiniOS
     5.7 +
     5.8  include $(XEN_ROOT)/Config.mk
     5.9  export stubdom=y
    5.10  export debug=y
     6.1 --- a/tools/libxc/Makefile	Tue Feb 12 14:59:22 2008 +0000
     6.2 +++ b/tools/libxc/Makefile	Tue Feb 12 15:03:07 2008 +0000
     6.3 @@ -25,13 +25,11 @@ ifneq ($(stubdom),y)
     6.4  CTRL_SRCS-y       += xc_resume.c
     6.5  endif
     6.6  CTRL_SRCS-$(CONFIG_X86) += xc_pagetab.c
     6.7 -ifneq ($(stubdom),y)
     6.8  CTRL_SRCS-$(CONFIG_Linux) += xc_linux.c
     6.9  CTRL_SRCS-$(CONFIG_SunOS) += xc_solaris.c
    6.10  CTRL_SRCS-$(CONFIG_X86_Linux) += xc_ptrace.c xc_ptrace_core.c
    6.11  CTRL_SRCS-$(CONFIG_NetBSD) += xc_netbsd.c
    6.12 -endif
    6.13 -CTRL_SRCS-$(stubdom) += xc_minios.c
    6.14 +CTRL_SRCS-$(CONFIG_MiniOS) += xc_minios.c
    6.15  
    6.16  GUEST_SRCS-y :=
    6.17  GUEST_SRCS-y += xg_private.c
    6.18 @@ -75,10 +73,6 @@ CFLAGS   += -Wp,-MD,.$(@F).d
    6.19  LDFLAGS  += -L.
    6.20  DEPS     = .*.d
    6.21  
    6.22 -ifneq ($(stubdom),y)
    6.23 -LDLIBS   = -lpthread
    6.24 -endif
    6.25 -
    6.26  CTRL_LIB_OBJS := $(patsubst %.c,%.o,$(CTRL_SRCS-y))
    6.27  CTRL_PIC_OBJS := $(patsubst %.c,%.opic,$(CTRL_SRCS-y))
    6.28  
    6.29 @@ -152,7 +146,7 @@ libxenctrl.so.$(MAJOR): libxenctrl.so.$(
    6.30  	ln -sf $< $@
    6.31  
    6.32  libxenctrl.so.$(MAJOR).$(MINOR): $(CTRL_PIC_OBJS)
    6.33 -	$(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenctrl.so.$(MAJOR) $(SHLIB_CFLAGS) -o $@ $^ $(LDLIBS)
    6.34 +	$(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenctrl.so.$(MAJOR) $(SHLIB_CFLAGS) -o $@ $^ $(PTHREAD_LIBS)
    6.35  
    6.36  # libxenguest
    6.37  
    6.38 @@ -165,7 +159,7 @@ libxenguest.so.$(MAJOR): libxenguest.so.
    6.39  	ln -sf $< $@
    6.40  
    6.41  libxenguest.so.$(MAJOR).$(MINOR): $(GUEST_PIC_OBJS) libxenctrl.so
    6.42 -	$(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenguest.so.$(MAJOR) $(SHLIB_CFLAGS) -o $@ $(GUEST_PIC_OBJS) -lz -lxenctrl $(LDLIBS)
    6.43 +	$(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenguest.so.$(MAJOR) $(SHLIB_CFLAGS) -o $@ $(GUEST_PIC_OBJS) -lz -lxenctrl $(PTHREAD_LIBS)
    6.44  
    6.45  -include $(DEPS)
    6.46