From: Wen Congyang <wency@cn.fujitsu.com>
To: Shriram Rajagopalan <rshriram@cs.ubc.ca>
Cc: Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
Ian Campbell <ian.campbell@citrix.com>,
xen-devel@lists.xen.org
Subject: Re: [PATCH 4 of 4 RFC] xl/remus: Add libnl3 dependency to autoconf scripts and libxl/Makefile
Date: Fri, 26 Jul 2013 17:44:08 +0800 [thread overview]
Message-ID: <51F244E8.5090701@cn.fujitsu.com> (raw)
In-Reply-To: <c4c05e4e4e022343935b.1374736170@athos.nss.cs.ubc.ca>
At 07/25/2013 03:09 PM, Shriram Rajagopalan Wrote:
> Add dependency on libnl3 version 3.2.17 or higher to autoconf.
> Add include flags and link to relevant libraries in tools/libxl/Makefile.
Is it OK to use libnl, not libnl3?
Some systems(For example: RHEL6) don't have libnl3.
>
> Signed-off-by: Shriram Rajagopalan <rshriram@cs.ubc.ca>
>
> diff -r bef729fc4336 -r c4c05e4e4e02 tools/configure.ac
> --- a/tools/configure.ac Thu Jul 25 00:02:22 2013 -0700
> +++ b/tools/configure.ac Thu Jul 25 00:02:33 2013 -0700
> @@ -171,4 +171,12 @@ AC_SUBST(libiconv)
> # Checks for header files.
> AC_CHECK_HEADERS([yajl/yajl_version.h sys/eventfd.h])
>
> +# Checks for libnl3 libraries and headers.
> +PKG_CHECK_MODULES(LIBNL3, libnl-3.0 >= 3.2.17 libnl-route-3.0 >= 3.2.17, [have_libnl3=yes], [have_libnl3=no])
> +if (test "${have_libnl3}" = "yes"); then
> + CFLAGS+="-I$LIBNL3_CFLAGS"
> +else
> + AC_MSG_ERROR([Need libnl version 3.2.17 or higher])
> +fi
> +
> AC_OUTPUT()
> diff -r bef729fc4336 -r c4c05e4e4e02 tools/libxl/Makefile
> --- a/tools/libxl/Makefile Thu Jul 25 00:02:22 2013 -0700
> +++ b/tools/libxl/Makefile Thu Jul 25 00:02:33 2013 -0700
> @@ -13,7 +13,7 @@ XLUMINOR = 0
>
> CFLAGS += -Werror -Wno-format-zero-length -Wmissing-declarations \
> -Wno-declaration-after-statement -Wformat-nonliteral
> -CFLAGS += -I. -fPIC
> +CFLAGS += -I. -fPIC -I /usr/local/include/libnl3/
Hmm, why use /usr/local?
Thanks
Wen Congyang
>
> ifeq ($(CONFIG_Linux),y)
> LIBUUID_LIBS += -luuid
> @@ -29,7 +29,7 @@ CFLAGS_LIBXL += $(CFLAGS_libblktapctl)
> CFLAGS_LIBXL += -Wshadow
>
> CFLAGS += $(PTHREAD_CFLAGS)
> -LDFLAGS += $(PTHREAD_LDFLAGS)
> +LDFLAGS += $(PTHREAD_LDFLAGS) -L/usr/local/lib/libnl3/
> LIBXL_LIBS += $(PTHREAD_LIBS)
>
> LIBXLU_LIBS =
> @@ -68,6 +68,7 @@ ifeq ($(BISON),)
> endif
>
> LIBXL_LIBS += -lyajl
> +LIBXL_LIBS += -lnl-3 -lnl-route-3
>
> LIBXL_OBJS = flexarray.o libxl.o libxl_create.o libxl_dm.o libxl_pci.o \
> libxl_dom.o libxl_exec.o libxl_xshelp.o libxl_device.o \
> @@ -92,7 +93,7 @@ CLIENTS = xl testidl libxl-save-helper
> CFLAGS_XL += $(CFLAGS_libxenlight)
> CFLAGS_XL += -Wshadow
>
> -XL_OBJS = xl.o xl_cmdimpl.o xl_cmdtable.o xl_sxp.o
> +XL_OBJS = xl.o xl_cmdimpl.o xl_cmdtable.o xl_sxp.o xl_netbuf.o
> $(XL_OBJS) _libxl.api-for-check: \
> CFLAGS += $(CFLAGS_libxenctrl) # For xentoollog.h
> $(XL_OBJS): CFLAGS += $(CFLAGS_XL)
> @@ -189,7 +190,7 @@ libxlutil.a: $(LIBXLU_OBJS)
> $(AR) rcs libxlutil.a $^
>
> xl: $(XL_OBJS) libxlutil.so libxenlight.so
> - $(CC) $(LDFLAGS) -o $@ $(XL_OBJS) libxlutil.so $(LDLIBS_libxenlight) $(LDLIBS_libxenctrl) -lyajl $(APPEND_LDFLAGS)
> + $(CC) $(LDFLAGS) -o $@ $(XL_OBJS) libxlutil.so $(LDLIBS_libxenlight) $(LDLIBS_libxenctrl) -lyajl -lnl-3 -lnl-route-3 $(APPEND_LDFLAGS)
>
> libxl-save-helper: $(SAVE_HELPER_OBJS) libxenlight.so
> $(CC) $(LDFLAGS) -o $@ $(SAVE_HELPER_OBJS) $(LDLIBS_libxenctrl) $(LDLIBS_libxenguest) $(APPEND_LDFLAGS)
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> http://lists.xen.org/xen-devel
>
next prev parent reply other threads:[~2013-07-26 9:44 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-25 7:09 [PATCH 0 of 4 RFC] xl - Remus network buffering support Shriram Rajagopalan
2013-07-25 7:09 ` [PATCH 1 of 4 RFC] xl/remus : Network buffering setup helper functions Shriram Rajagopalan
2013-07-29 15:42 ` Ian Campbell
2013-07-29 18:00 ` Shriram Rajagopalan
2013-07-30 10:44 ` Ian Campbell
2013-07-25 7:09 ` [PATCH 2 of 4 RFC] xl/remus: Network buffering cmdline switch, setup/teardown Shriram Rajagopalan
2013-07-29 15:49 ` Ian Campbell
2013-07-29 19:00 ` Shriram Rajagopalan
2013-07-30 10:50 ` Ian Campbell
2013-07-30 15:25 ` Shriram Rajagopalan
2013-07-30 15:39 ` Ian Campbell
2013-07-25 7:09 ` [PATCH 3 of 4 RFC] xl/remus: Control network buffering in remus callbacks Shriram Rajagopalan
2013-07-29 16:06 ` Ian Campbell
2013-08-07 15:41 ` Ian Jackson
2013-08-07 15:38 ` Ian Jackson
2013-08-07 21:51 ` Shriram Rajagopalan
2013-08-08 11:07 ` Ian Jackson
2013-07-25 7:09 ` [PATCH 4 of 4 RFC] xl/remus: Add libnl3 dependency to autoconf scripts and libxl/Makefile Shriram Rajagopalan
2013-07-26 9:44 ` Wen Congyang [this message]
2013-07-26 13:51 ` Shriram Rajagopalan
2013-07-26 9:56 ` David Vrabel
2013-07-26 13:56 ` Shriram Rajagopalan
2013-07-29 5:58 ` Wen Congyang
2013-07-29 13:07 ` Shriram Rajagopalan
2013-07-29 15:41 ` David Vrabel
2013-07-30 16:11 ` [PATCH 0 of 4 RFC] xl - Remus network buffering support Roger Pau Monné
2013-07-31 8:33 ` Ian Campbell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=51F244E8.5090701@cn.fujitsu.com \
--to=wency@cn.fujitsu.com \
--cc=ian.campbell@citrix.com \
--cc=rshriram@cs.ubc.ca \
--cc=stefano.stabellini@eu.citrix.com \
--cc=xen-devel@lists.xen.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.