Imported Upstream version 0.7.17
Vincent Bernat
8 years ago
0 | 0.7.17 [2015-09-09 17:06:34 +0200]: | |
1 | ||
2 | - [fb700b0966c9] build: .git may be a file (Vincent Bernat) | |
3 | - [2f23ece4985c] NEWS: add some entries for 0.7.17 (Vincent Bernat) | |
4 | - [b4f78b30b0b3] lldpcli: display a warning when a configuration file is not found (Vincent Bernat) | |
5 | - [d988ce0ccf6d] netlink: workaround veth being peered together through IFLA_LINK (Vincent Bernat) | |
6 | - [948c19d0eeb2] build: add a marker at the end of third-party configure (Vincent Bernat) | |
7 | - [696f7f6fe839] build: make --with-embedded-libevent a tri-state switch (Vincent Bernat) | |
8 | - [f8688c96fb31] build: don't let autoreconf rely on AC_CONFIG_SUBDIRS macro (Vincent Bernat) | |
9 | - [8e8d9a270b31] build: automatically reuse regular configure args for distcheck (Vincent Bernat) | |
10 | - [a069490369d0] build: run ./configure for libevent even when not needed (Vincent Bernat) | |
11 | - [848cc66197c2] build: only enable silent rules if they are not disabled (Vincent Bernat) | |
12 | - [3940008c5fce] build: replace AC_CONFIG_SUBDIRS with custom version (Vincent Bernat) | |
13 | - [96beef68762f] cdp: compute default platform when updating the chassis (Vincent Bernat) | |
14 | - [fc37317f7cd2] cdp: make the default platform name really the kernel name (Baptiste Daroussin) | |
15 | - [4f6ba6c38fb3] build: propagate appropriate build flags in src/compat (Vincent Bernat) | |
16 | - [58920eb1532f] osx: remove unneeded patch for launchd (Vincent Bernat) | |
17 | - [f363bce70a09] osx: fix configure command line in Homebrew (Vincent Bernat) | |
18 | - [6bf87f4dec03] osx: restore use of _lldpd/_lldpd user/group in Homebrew (Vincent Bernat) | |
19 | - [c65f44ec7a69] osx: synchronize a bit with official HomeBrew formula (Vincent Bernat) | |
20 | - [db04d99f0bff] README: incorrect instructions for OS X (Vincent Bernat) | |
21 | - [a7125859f001] debian: update symbol versioning (Vincent Bernat) | |
22 | - [2b00cbf9d548] client: parse options only once (Vincent Bernat) | |
23 | - [506526477e8b] client: make lldpctl also accepts `-u` flag (Vincent Bernat) | |
24 | - [839d72d04429] Merge pull request #128 from baloo/patch-1 (Vincent Bernat) | |
25 | - [3bd5a8780ca8] Typo in README.md (Arthur Gautier) | |
26 | - [6845388d7656] debian: don't complain about too recent Standards-Version (Vincent Bernat) | |
27 | - [e410dec40f82] debian: add a lintian override for debian-revision-should-not-be-zero (Vincent Bernat) | |
28 | - [5d81ecdd370f] redhat: on RHEL 5, use --enable-oldies (Vincent Bernat) | |
29 | - [62f5cd089705] travis: also test when oldies are enabled (Vincent Bernat) | |
30 | - [689ed13125cf] travis: don't add too many alternatives in configure (Vincent Bernat) | |
31 | ||
0 | 32 | 0.7.16 [2015-08-07 11:13:19 +0200]: |
1 | 33 | |
2 | 34 | - [96a1dec9d105] release: prepare 0.7.16 (Vincent Bernat) |
11 | 11 | |
12 | 12 | __force-changelog-generation: |
13 | 13 | ChangeLog: __force-changelog-generation |
14 | $(AM_V_GEN)if test -d $(top_srcdir)/.git; then \ | |
14 | $(AM_V_GEN)if test -e $(top_srcdir)/.git; then \ | |
15 | 15 | prev=$$(git describe --tags --always --match '[0-9]*' 2> /dev/null) ; \ |
16 | 16 | for tag in $$(git tag | $(EGREP) '^[0-9]+(\.[0-9]+){1,}$$' | sort -t. -k 1,1nr -k 2,2nr -k 3,3nr); do \ |
17 | 17 | if [ x"$$prev" = x ]; then prev=$$tag ; fi ; \ |
33 | 33 | |
34 | 34 | # systemd and launchd files are not installed in the prefix, don't |
35 | 35 | # request them for distcheck |
36 | DISTCHECK_CONFIGURE_FLAGS = \ | |
36 | DISTCHECK_CONFIGURE_FLAGS = $(CONFIGURE_ARGS) \ | |
37 | 37 | --with-sysusersdir=no \ |
38 | 38 | --with-systemdsystemunitdir=no \ |
39 | 39 | --with-launchddaemonsdir=no |
125 | 125 | $(top_srcdir)/m4/ax_ld_check_flag.m4 \ |
126 | 126 | $(top_srcdir)/m4/ax_lib_readline.m4 \ |
127 | 127 | $(top_srcdir)/m4/ax_prog_doxygen.m4 \ |
128 | $(top_srcdir)/m4/jansson.m4 $(top_srcdir)/m4/json-c.m4 \ | |
128 | $(top_srcdir)/m4/config_subdirs.m4 $(top_srcdir)/m4/jansson.m4 \ | |
129 | $(top_srcdir)/m4/json-c.m4 \ | |
129 | 130 | $(top_srcdir)/m4/ld-version-script.m4 \ |
130 | 131 | $(top_srcdir)/m4/libevent.m4 $(top_srcdir)/m4/libtool.m4 \ |
131 | 132 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
451 | 452 | sbindir = @sbindir@ |
452 | 453 | sharedstatedir = @sharedstatedir@ |
453 | 454 | srcdir = @srcdir@ |
454 | subdirs = @subdirs@ | |
455 | 455 | sysconfdir = @sysconfdir@ |
456 | 456 | systemdsystemunitdir = @systemdsystemunitdir@ |
457 | 457 | sysusersdir = @sysusersdir@ |
494 | 494 | |
495 | 495 | # systemd and launchd files are not installed in the prefix, don't |
496 | 496 | # request them for distcheck |
497 | DISTCHECK_CONFIGURE_FLAGS = \ | |
497 | DISTCHECK_CONFIGURE_FLAGS = $(CONFIGURE_ARGS) \ | |
498 | 498 | --with-sysusersdir=no \ |
499 | 499 | --with-systemdsystemunitdir=no \ |
500 | 500 | --with-launchddaemonsdir=no |
1082 | 1082 | |
1083 | 1083 | __force-changelog-generation: |
1084 | 1084 | ChangeLog: __force-changelog-generation |
1085 | $(AM_V_GEN)if test -d $(top_srcdir)/.git; then \ | |
1085 | $(AM_V_GEN)if test -e $(top_srcdir)/.git; then \ | |
1086 | 1086 | prev=$$(git describe --tags --always --match '[0-9]*' 2> /dev/null) ; \ |
1087 | 1087 | for tag in $$(git tag | $(EGREP) '^[0-9]+(\.[0-9]+){1,}$$' | sort -t. -k 1,1nr -k 2,2nr -k 3,3nr); do \ |
1088 | 1088 | if [ x"$$prev" = x ]; then prev=$$tag ; fi ; \ |
0 | lldpd (0.7.17) | |
1 | * Fix: | |
2 | + Fix an infinite loop when using veth on Linux 4.1+ kernels. | |
3 | + Make CDP advertise the appropriate kernel name as platform, | |
4 | not just "Linux". | |
5 | * Change: | |
6 | + Fix the way libevent configure is called. | |
7 | ||
0 | 8 | lldpd (0.7.16) |
1 | 9 | * Change: |
2 | 10 | + For Linux, 2.6.32 is now the minimal required kernel. When using |
82 | 82 | SDK=/Developer/SDKs/MacOSX10.6.sdk |
83 | 83 | mkdir build && cd build |
84 | 84 | ../configure --prefix=/usr --localstatedir=/var --sysconfdir=/private/etc --with-embedded-libevent \ |
85 | --without-json --without-snmp | |
85 | --without-json --without-snmp \ | |
86 | 86 | CFLAGS="-mmacosx-version-min=10.6 -isysroot $SDK" \ |
87 | 87 | LDFLAGS="-mmacosx-version-min=10.6 -isysroot $SDK" |
88 | 88 | make -C osx pkg ARCHS="i386 x86_64" |
203 | 203 | ----------- |
204 | 204 | |
205 | 205 | During development, you may want to execute lldpd at its current |
206 | location inside of doing `make install`. The correct way to do this is | |
206 | location instead of doing `make install`. The correct way to do this is | |
207 | 207 | to issue the following command: |
208 | 208 | |
209 | 209 | sudo libtool execute src/daemon/lldpd -L $PWD/src/client/lldpcli -d |
1466 | 1466 | m4_include([m4/ax_ld_check_flag.m4]) |
1467 | 1467 | m4_include([m4/ax_lib_readline.m4]) |
1468 | 1468 | m4_include([m4/ax_prog_doxygen.m4]) |
1469 | m4_include([m4/config_subdirs.m4]) | |
1469 | 1470 | m4_include([m4/jansson.m4]) |
1470 | 1471 | m4_include([m4/json-c.m4]) |
1471 | 1472 | m4_include([m4/ld-version-script.m4]) |
1 | 1 | |
2 | 2 | set -e |
3 | 3 | |
4 | [ ! -d .gitmodules ] || { | |
4 | [ ! -e .gitmodules ] || { | |
5 | 5 | echo "autogen.sh: updating git submodules" |
6 | 6 | git submodule init |
7 | 7 | git submodule update |
61 | 61 | } |
62 | 62 | |
63 | 63 | |
64 | SUBDIRS="" | |
65 | for dir in *; do | |
66 | [ -d "$dir" ] || continue | |
67 | [ -f "$dir"/configure.ac ] || [ -f "$dir"/configure.in ] || continue | |
68 | SUBDIRS="$SUBDIRS $dir" | |
69 | done | |
70 | ||
64 | 71 | echo "autogen.sh: start libtoolize to get ltmain.sh" |
65 | 72 | ${LIBTOOLIZE} --copy --force |
66 | 73 | echo "autogen.sh: reconfigure with autoreconf" |
67 | ${AUTORECONF} -vif -I m4 || { | |
74 | ${AUTORECONF} -vif --no-recursive -I m4 . $SUBDIRS || { | |
68 | 75 | echo "autogen.sh: autoreconf has failed ($?), let's do it manually" |
69 | for dir in $PWD *; do | |
70 | [ -d "$dir" ] || continue | |
71 | [ -f "$dir"/configure.ac ] || [ -f "$dir"/configure.in ] || continue | |
76 | for dir in $PWD $SUBDIRS; do | |
72 | 77 | echo "autogen.sh: configure `basename $dir`" |
73 | 78 | (cd "$dir" && ${ACLOCAL} -I m4 ${ACLOCAL_FLAGS}) |
74 | 79 | (cd "$dir" && check_pkg_config) |
0 | 0 | #! /bin/sh |
1 | 1 | # Guess values for system-dependent variables and create Makefiles. |
2 | # Generated by GNU Autoconf 2.69 for lldpd 0.7.16. | |
2 | # Generated by GNU Autoconf 2.69 for lldpd 0.7.17. | |
3 | 3 | # |
4 | 4 | # Report bugs to <https://github.com/vincentbernat/lldpd/issues>. |
5 | 5 | # |
589 | 589 | # Identity of this package. |
590 | 590 | PACKAGE_NAME='lldpd' |
591 | 591 | PACKAGE_TARNAME='lldpd' |
592 | PACKAGE_VERSION='0.7.16' | |
593 | PACKAGE_STRING='lldpd 0.7.16' | |
592 | PACKAGE_VERSION='0.7.17' | |
593 | PACKAGE_STRING='lldpd 0.7.17' | |
594 | 594 | PACKAGE_BUGREPORT='https://github.com/vincentbernat/lldpd/issues' |
595 | 595 | PACKAGE_URL='http://vincentbernat.github.io/lldpd/' |
596 | 596 | |
632 | 632 | #endif" |
633 | 633 | |
634 | 634 | ac_config_libobj_dir=src/compat |
635 | enable_option_checking=no | |
636 | 635 | ac_subst_vars='am__EXEEXT_FALSE |
637 | 636 | am__EXEEXT_TRUE |
638 | 637 | LTLIBOBJS |
657 | 656 | LLDPD_PID_FILE |
658 | 657 | LLDPD_CTL_SOCKET |
659 | 658 | PRIVSEP_CHROOT |
660 | runstatedir | |
661 | 659 | PRIVSEP_GROUP |
662 | 660 | PRIVSEP_USER |
663 | 661 | DTRACE |
692 | 690 | LIBEVENT_LDFLAGS |
693 | 691 | LIBEVENT_EMBEDDED_FALSE |
694 | 692 | LIBEVENT_EMBEDDED_TRUE |
695 | subdirs | |
696 | 693 | LIBEVENT_LIBS |
697 | 694 | LIBEVENT_CFLAGS |
698 | 695 | CHECK_LIBS |
867 | 864 | docdir |
868 | 865 | oldincludedir |
869 | 866 | includedir |
867 | runstatedir | |
870 | 868 | localstatedir |
871 | 869 | sharedstatedir |
872 | 870 | sysconfdir |
967 | 965 | JSONC_LIBS |
968 | 966 | SECCOMP_CFLAGS |
969 | 967 | SECCOMP_LIBS' |
970 | ac_subdirs_all='libevent' | |
968 | ||
971 | 969 | |
972 | 970 | # Initialize some variables set by options. |
973 | 971 | ac_init_help= |
1005 | 1003 | sysconfdir='${prefix}/etc' |
1006 | 1004 | sharedstatedir='${prefix}/com' |
1007 | 1005 | localstatedir='${prefix}/var' |
1006 | runstatedir='${localstatedir}/run' | |
1008 | 1007 | includedir='${prefix}/include' |
1009 | 1008 | oldincludedir='/usr/include' |
1010 | 1009 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' |
1257 | 1256 | | -silent | --silent | --silen | --sile | --sil) |
1258 | 1257 | silent=yes ;; |
1259 | 1258 | |
1259 | -runstatedir | --runstatedir | --runstatedi | --runstated \ | |
1260 | | --runstate | --runstat | --runsta | --runst | --runs \ | |
1261 | | --run | --ru | --r) | |
1262 | ac_prev=runstatedir ;; | |
1263 | -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ | |
1264 | | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ | |
1265 | | --run=* | --ru=* | --r=*) | |
1266 | runstatedir=$ac_optarg ;; | |
1267 | ||
1260 | 1268 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
1261 | 1269 | ac_prev=sbindir ;; |
1262 | 1270 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
1394 | 1402 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
1395 | 1403 | datadir sysconfdir sharedstatedir localstatedir includedir \ |
1396 | 1404 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ |
1397 | libdir localedir mandir | |
1405 | libdir localedir mandir runstatedir | |
1398 | 1406 | do |
1399 | 1407 | eval ac_val=\$$ac_var |
1400 | 1408 | # Remove trailing slashes. |
1507 | 1515 | # Omit some internal or obsolete options to make the list less imposing. |
1508 | 1516 | # This message is too long to be a string in the A/UX 3.1 sh. |
1509 | 1517 | cat <<_ACEOF |
1510 | \`configure' configures lldpd 0.7.16 to adapt to many kinds of systems. | |
1518 | \`configure' configures lldpd 0.7.17 to adapt to many kinds of systems. | |
1511 | 1519 | |
1512 | 1520 | Usage: $0 [OPTION]... [VAR=VALUE]... |
1513 | 1521 | |
1547 | 1555 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
1548 | 1556 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
1549 | 1557 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
1558 | --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] | |
1550 | 1559 | --libdir=DIR object code libraries [EPREFIX/lib] |
1551 | 1560 | --includedir=DIR C header files [PREFIX/include] |
1552 | 1561 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
1577 | 1586 | |
1578 | 1587 | if test -n "$ac_init_help"; then |
1579 | 1588 | case $ac_init_help in |
1580 | short | recursive ) echo "Configuration of lldpd 0.7.16:";; | |
1589 | short | recursive ) echo "Configuration of lldpd 0.7.17:";; | |
1581 | 1590 | esac |
1582 | 1591 | cat <<\_ACEOF |
1583 | 1592 | |
1638 | 1647 | --with-sysroot=DIR Search for dependent libraries within DIR |
1639 | 1648 | (or the compiler's sysroot if not specified). |
1640 | 1649 | --with-embedded-libevent |
1641 | Force the use of embedded libevent [default=no] | |
1650 | Use embedded libevent [default=auto] | |
1642 | 1651 | --with-pkgconfigdir pkg-config installation directory |
1643 | 1652 | ['${libdir}/pkgconfig'] |
1644 | 1653 | --with-readline Enable the use of readline-like library |
1777 | 1786 | test -n "$ac_init_help" && exit $ac_status |
1778 | 1787 | if $ac_init_version; then |
1779 | 1788 | cat <<\_ACEOF |
1780 | lldpd configure 0.7.16 | |
1789 | lldpd configure 0.7.17 | |
1781 | 1790 | generated by GNU Autoconf 2.69 |
1782 | 1791 | |
1783 | 1792 | Copyright (C) 2012 Free Software Foundation, Inc. |
2378 | 2387 | This file contains any messages produced by compilers while |
2379 | 2388 | running configure, to aid debugging if configure makes a mistake. |
2380 | 2389 | |
2381 | It was created by lldpd $as_me 0.7.16, which was | |
2390 | It was created by lldpd $as_me 0.7.17, which was | |
2382 | 2391 | generated by GNU Autoconf 2.69. Invocation command line was |
2383 | 2392 | |
2384 | 2393 | $ $0 $@ |
3252 | 3261 | |
3253 | 3262 | # Define the identity of the package. |
3254 | 3263 | PACKAGE='lldpd' |
3255 | VERSION='0.7.16' | |
3264 | VERSION='0.7.17' | |
3256 | 3265 | |
3257 | 3266 | |
3258 | 3267 | cat >>confdefs.h <<_ACEOF |
22216 | 22225 | |
22217 | 22226 | # Libevent |
22218 | 22227 | |
22219 | ||
22220 | ||
22221 | 22228 | # Do we require embedded libevent? |
22222 | 22229 | |
22223 | 22230 | # Check whether --with-embedded-libevent was given. |
22224 | 22231 | if test "${with_embedded_libevent+set}" = set; then : |
22225 | 22232 | withval=$with_embedded_libevent; |
22233 | else | |
22234 | with_embedded_libevent=auto | |
22226 | 22235 | fi |
22227 | 22236 | |
22228 | 22237 | if test x"$with_embedded_libevent" = x"yes"; then |
22289 | 22298 | echo "$LIBEVENT_PKG_ERRORS" >&5 |
22290 | 22299 | |
22291 | 22300 | |
22292 | # No appropriate version, let's use the shipped copy | |
22293 | { $as_echo "$as_me:${as_lineno-$LINENO}: using shipped libevent" >&5 | |
22301 | # No appropriate version, let's use the shipped copy if possible | |
22302 | if test x"$with_embedded_libevent" = x"auto"; then | |
22303 | { $as_echo "$as_me:${as_lineno-$LINENO}: using shipped libevent" >&5 | |
22294 | 22304 | $as_echo "$as_me: using shipped libevent" >&6;} |
22295 | LIBEVENT_EMBEDDED=1 | |
22305 | LIBEVENT_EMBEDDED=1 | |
22306 | else | |
22307 | as_fn_error $? "*** libevent not found" "$LINENO" 5 | |
22308 | fi | |
22296 | 22309 | |
22297 | 22310 | elif test $pkg_failed = untried; then |
22298 | 22311 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
22299 | 22312 | $as_echo "no" >&6; } |
22300 | 22313 | |
22301 | # No appropriate version, let's use the shipped copy | |
22302 | { $as_echo "$as_me:${as_lineno-$LINENO}: using shipped libevent" >&5 | |
22314 | # No appropriate version, let's use the shipped copy if possible | |
22315 | if test x"$with_embedded_libevent" = x"auto"; then | |
22316 | { $as_echo "$as_me:${as_lineno-$LINENO}: using shipped libevent" >&5 | |
22303 | 22317 | $as_echo "$as_me: using shipped libevent" >&6;} |
22304 | LIBEVENT_EMBEDDED=1 | |
22318 | LIBEVENT_EMBEDDED=1 | |
22319 | else | |
22320 | as_fn_error $? "*** libevent not found" "$LINENO" 5 | |
22321 | fi | |
22305 | 22322 | |
22306 | 22323 | else |
22307 | 22324 | LIBEVENT_CFLAGS=$pkg_cv_LIBEVENT_CFLAGS |
22337 | 22354 | |
22338 | 22355 | else |
22339 | 22356 | |
22340 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using shipped libevent" >&5 | |
22357 | if test x"$with_embedded_libevent" = x"auto"; then | |
22358 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using shipped libevent" >&5 | |
22341 | 22359 | $as_echo "no, using shipped libevent" >&6; } |
22342 | LIBEVENT_EMBEDDED=1 | |
22360 | LIBEVENT_EMBEDDED=1 | |
22361 | else | |
22362 | as_fn_error $? "*** unusable system libevent" "$LINENO" 5 | |
22363 | fi | |
22343 | 22364 | |
22344 | 22365 | fi |
22345 | 22366 | rm -f core conftest.err conftest.$ac_objext \ |
22356 | 22377 | LIBEVENT_LDFLAGS="\$(top_builddir)/libevent/libevent.la" |
22357 | 22378 | fi |
22358 | 22379 | |
22359 | # Override configure arguments | |
22360 | ac_configure_args="$ac_configure_args --disable-libevent-regress --disable-thread-support --disable-openssl" | |
22361 | ac_configure_args="$ac_configure_args --disable-malloc-replacement --disable-debug-mode --enable-function-sections" | |
22362 | ac_configure_args="$ac_configure_args --disable-shared --with-pic --enable-static --enable-silent-rules" | |
22363 | subdirs="$subdirs libevent" | |
22380 | # Call ./configure in libevent. Need it for make dist... | |
22381 | libevent_configure_args="$libevent_configure_args --disable-libevent-regress" | |
22382 | libevent_configure_args="$libevent_configure_args --disable-thread-support" | |
22383 | libevent_configure_args="$libevent_configure_args --disable-openssl" | |
22384 | libevent_configure_args="$libevent_configure_args --disable-malloc-replacement" | |
22385 | libevent_configure_args="$libevent_configure_args --disable-debug-mode" | |
22386 | libevent_configure_args="$libevent_configure_args --enable-function-sections" | |
22387 | libevent_configure_args="$libevent_configure_args --disable-shared" | |
22388 | libevent_configure_args="$libevent_configure_args --with-pic" | |
22389 | libevent_configure_args="$libevent_configure_args --enable-static" | |
22390 | ||
22391 | ac_sub_configure_args= | |
22392 | ac_prev= | |
22393 | eval "set x $ac_configure_args" | |
22394 | shift | |
22395 | for ac_arg | |
22396 | do | |
22397 | if test -n "$ac_prev"; then | |
22398 | ac_prev= | |
22399 | continue | |
22400 | fi | |
22401 | case $ac_arg in | |
22402 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
22403 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
22404 | ac_prev=cache_file ;; | |
22405 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
22406 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \ | |
22407 | | --c=*) | |
22408 | ;; | |
22409 | --config-cache | -C) | |
22410 | ;; | |
22411 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
22412 | ac_prev=srcdir ;; | |
22413 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
22414 | ;; | |
22415 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
22416 | ac_prev=prefix ;; | |
22417 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
22418 | ;; | |
22419 | --disable-option-checking) | |
22420 | ;; | |
22421 | *) | |
22422 | case $ac_arg in | |
22423 | *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
22424 | esac | |
22425 | as_fn_append ac_sub_configure_args " '$ac_arg'" ;; | |
22426 | esac | |
22427 | done | |
22428 | ||
22429 | # Always prepend --prefix to ensure using the same prefix | |
22430 | # in subdir configurations. | |
22431 | ac_arg="--prefix=$prefix" | |
22432 | case $ac_arg in | |
22433 | *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
22434 | esac | |
22435 | ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args" | |
22436 | ||
22437 | # Always prepend --disable-option-checking to silence warnings, since | |
22438 | # different subdirs can have different --enable and --with options. | |
22439 | ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args" | |
22440 | ||
22441 | # Silent rules | |
22442 | case $enable_silent_rules in | |
22443 | no) ac_sub_configure_args="$ac_sub_configure_args --disable-silent-rules" ;; | |
22444 | *) ac_sub_configure_args="$ac_sub_configure_args --enable-silent-rules" ;; | |
22445 | esac | |
22446 | ||
22447 | # Add additional options | |
22448 | ac_sub_configure_args="$ac_sub_configure_args $libevent_configure_args" | |
22449 | ||
22450 | ac_popdir=`pwd` | |
22451 | ac_dir="libevent" | |
22452 | ||
22453 | ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)" | |
22454 | $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5 | |
22455 | $as_echo "$ac_msg" >&6 | |
22456 | as_dir="$ac_dir"; as_fn_mkdir_p | |
22457 | ac_builddir=. | |
22458 | ||
22459 | case "$ac_dir" in | |
22460 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
22461 | *) | |
22462 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
22463 | # A ".." for each directory in $ac_dir_suffix. | |
22464 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
22465 | case $ac_top_builddir_sub in | |
22466 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
22467 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
22468 | esac ;; | |
22469 | esac | |
22470 | ac_abs_top_builddir=$ac_pwd | |
22471 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
22472 | # for backward compatibility: | |
22473 | ac_top_builddir=$ac_top_build_prefix | |
22474 | ||
22475 | case $srcdir in | |
22476 | .) # We are building in place. | |
22477 | ac_srcdir=. | |
22478 | ac_top_srcdir=$ac_top_builddir_sub | |
22479 | ac_abs_top_srcdir=$ac_pwd ;; | |
22480 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
22481 | ac_srcdir=$srcdir$ac_dir_suffix; | |
22482 | ac_top_srcdir=$srcdir | |
22483 | ac_abs_top_srcdir=$srcdir ;; | |
22484 | *) # Relative name. | |
22485 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
22486 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
22487 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
22488 | esac | |
22489 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix | |
22490 | ||
22491 | ||
22492 | cd "$ac_dir" | |
22493 | ||
22494 | ac_sub_configure=$ac_srcdir/configure | |
22495 | ||
22496 | # Make the cache file name correct relative to the subdirectory. | |
22497 | case $cache_file in | |
22498 | [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;; | |
22499 | *) # Relative name. | |
22500 | ac_sub_cache_file=$ac_top_build_prefix$cache_file ;; | |
22501 | esac | |
22502 | ||
22503 | { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5 | |
22504 | $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;} | |
22505 | # The eval makes quoting arguments work. | |
22506 | eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \ | |
22507 | --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" || | |
22508 | as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5 | |
22509 | ||
22510 | ac_msg="=== end of configure in $ac_dir (`pwd`/$ac_dir)" | |
22511 | $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5 | |
22512 | $as_echo "$ac_msg" >&6 | |
22513 | cd "$ac_popdir" | |
22514 | ||
22364 | 22515 | |
22365 | 22516 | if test x"$LIBEVENT_EMBEDDED" != x; then |
22366 | 22517 | LIBEVENT_EMBEDDED_TRUE= |
25815 | 25966 | # report actual input values of CONFIG_FILES etc. instead of their |
25816 | 25967 | # values after options handling. |
25817 | 25968 | ac_log=" |
25818 | This file was extended by lldpd $as_me 0.7.16, which was | |
25969 | This file was extended by lldpd $as_me 0.7.17, which was | |
25819 | 25970 | generated by GNU Autoconf 2.69. Invocation command line was |
25820 | 25971 | |
25821 | 25972 | CONFIG_FILES = $CONFIG_FILES |
25882 | 26033 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
25883 | 26034 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" |
25884 | 26035 | ac_cs_version="\\ |
25885 | lldpd config.status 0.7.16 | |
26036 | lldpd config.status 0.7.17 | |
25886 | 26037 | configured by $0, generated by GNU Autoconf 2.69, |
25887 | 26038 | with options \\"\$ac_cs_config\\" |
25888 | 26039 | |
27915 | 28066 | # would make configure fail if this is the last instruction. |
27916 | 28067 | $ac_cs_success || as_fn_exit 1 |
27917 | 28068 | fi |
27918 | ||
27919 | # | |
27920 | # CONFIG_SUBDIRS section. | |
27921 | # | |
27922 | if test "$no_recursion" != yes; then | |
27923 | ||
27924 | # Remove --cache-file, --srcdir, and --disable-option-checking arguments | |
27925 | # so they do not pile up. | |
27926 | ac_sub_configure_args= | |
27927 | ac_prev= | |
27928 | eval "set x $ac_configure_args" | |
27929 | shift | |
27930 | for ac_arg | |
27931 | do | |
27932 | if test -n "$ac_prev"; then | |
27933 | ac_prev= | |
27934 | continue | |
27935 | fi | |
27936 | case $ac_arg in | |
27937 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
27938 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
27939 | ac_prev=cache_file ;; | |
27940 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
27941 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \ | |
27942 | | --c=*) | |
27943 | ;; | |
27944 | --config-cache | -C) | |
27945 | ;; | |
27946 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
27947 | ac_prev=srcdir ;; | |
27948 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
27949 | ;; | |
27950 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
27951 | ac_prev=prefix ;; | |
27952 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
27953 | ;; | |
27954 | --disable-option-checking) | |
27955 | ;; | |
27956 | *) | |
27957 | case $ac_arg in | |
27958 | *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
27959 | esac | |
27960 | as_fn_append ac_sub_configure_args " '$ac_arg'" ;; | |
27961 | esac | |
27962 | done | |
27963 | ||
27964 | # Always prepend --prefix to ensure using the same prefix | |
27965 | # in subdir configurations. | |
27966 | ac_arg="--prefix=$prefix" | |
27967 | case $ac_arg in | |
27968 | *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
27969 | esac | |
27970 | ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args" | |
27971 | ||
27972 | # Pass --silent | |
27973 | if test "$silent" = yes; then | |
27974 | ac_sub_configure_args="--silent $ac_sub_configure_args" | |
27975 | fi | |
27976 | ||
27977 | # Always prepend --disable-option-checking to silence warnings, since | |
27978 | # different subdirs can have different --enable and --with options. | |
27979 | ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args" | |
27980 | ||
27981 | ac_popdir=`pwd` | |
27982 | for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue | |
27983 | ||
27984 | # Do not complain, so a configure script can configure whichever | |
27985 | # parts of a large source tree are present. | |
27986 | test -d "$srcdir/$ac_dir" || continue | |
27987 | ||
27988 | ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)" | |
27989 | $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5 | |
27990 | $as_echo "$ac_msg" >&6 | |
27991 | as_dir="$ac_dir"; as_fn_mkdir_p | |
27992 | ac_builddir=. | |
27993 | ||
27994 | case "$ac_dir" in | |
27995 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
27996 | *) | |
27997 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
27998 | # A ".." for each directory in $ac_dir_suffix. | |
27999 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
28000 | case $ac_top_builddir_sub in | |
28001 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
28002 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
28003 | esac ;; | |
28004 | esac | |
28005 | ac_abs_top_builddir=$ac_pwd | |
28006 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
28007 | # for backward compatibility: | |
28008 | ac_top_builddir=$ac_top_build_prefix | |
28009 | ||
28010 | case $srcdir in | |
28011 | .) # We are building in place. | |
28012 | ac_srcdir=. | |
28013 | ac_top_srcdir=$ac_top_builddir_sub | |
28014 | ac_abs_top_srcdir=$ac_pwd ;; | |
28015 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
28016 | ac_srcdir=$srcdir$ac_dir_suffix; | |
28017 | ac_top_srcdir=$srcdir | |
28018 | ac_abs_top_srcdir=$srcdir ;; | |
28019 | *) # Relative name. | |
28020 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
28021 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
28022 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
28023 | esac | |
28024 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix | |
28025 | ||
28026 | ||
28027 | cd "$ac_dir" | |
28028 | ||
28029 | # Check for guested configure; otherwise get Cygnus style configure. | |
28030 | if test -f "$ac_srcdir/configure.gnu"; then | |
28031 | ac_sub_configure=$ac_srcdir/configure.gnu | |
28032 | elif test -f "$ac_srcdir/configure"; then | |
28033 | ac_sub_configure=$ac_srcdir/configure | |
28034 | elif test -f "$ac_srcdir/configure.in"; then | |
28035 | # This should be Cygnus configure. | |
28036 | ac_sub_configure=$ac_aux_dir/configure | |
28037 | else | |
28038 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5 | |
28039 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;} | |
28040 | ac_sub_configure= | |
28041 | fi | |
28042 | ||
28043 | # The recursion is here. | |
28044 | if test -n "$ac_sub_configure"; then | |
28045 | # Make the cache file name correct relative to the subdirectory. | |
28046 | case $cache_file in | |
28047 | [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;; | |
28048 | *) # Relative name. | |
28049 | ac_sub_cache_file=$ac_top_build_prefix$cache_file ;; | |
28050 | esac | |
28051 | ||
28052 | { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5 | |
28053 | $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;} | |
28054 | # The eval makes quoting arguments work. | |
28055 | eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \ | |
28056 | --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" || | |
28057 | as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5 | |
28058 | fi | |
28059 | ||
28060 | cd "$ac_popdir" | |
28061 | done | |
28062 | fi | |
28063 | 28069 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
28064 | 28070 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
28065 | 28071 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} |
28 | 28 | if [ -f .dist-version ]; then |
29 | 29 | # Get the version from the file distributed in the tarball. |
30 | 30 | version=$(cat .dist-version) |
31 | elif [ -d .git ]; then | |
31 | elif [ -e .git ]; then | |
32 | 32 | # Ger the version from the git repository. |
33 | 33 | version=$(git describe --tags --always --match [0-9]* 2> /dev/null) |
34 | 34 |
0 | 0 | #!/bin/sh |
1 | 1 | # install - install a program, script, or datafile |
2 | 2 | |
3 | scriptversion=2013-12-25.23; # UTC | |
3 | scriptversion=2014-09-12.12; # UTC | |
4 | 4 | |
5 | 5 | # This originates from X11R5 (mit/util/scripts/install.sh), which was |
6 | 6 | # later released in X11R6 (xc/config/util/install.sh) with the |
323 | 323 | # is incompatible with FreeBSD 'install' when (umask & 300) != 0. |
324 | 324 | ;; |
325 | 325 | *) |
326 | # $RANDOM is not portable (e.g. dash); use it when possible to | |
327 | # lower collision chance | |
326 | 328 | tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ |
327 | trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 | |
328 | ||
329 | trap 'ret=$?; rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null; exit $ret' 0 | |
330 | ||
331 | # As "mkdir -p" follows symlinks and we work in /tmp possibly; so | |
332 | # create the $tmpdir first (and fail if unsuccessful) to make sure | |
333 | # that nobody tries to guess the $tmpdir name. | |
329 | 334 | if (umask $mkdir_umask && |
330 | exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 | |
335 | $mkdirprog $mkdir_mode "$tmpdir" && | |
336 | exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1 | |
331 | 337 | then |
332 | 338 | if test -z "$dir_arg" || { |
333 | 339 | # Check for POSIX incompatibilities with -m. |
334 | 340 | # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or |
335 | 341 | # other-writable bit of parent directory when it shouldn't. |
336 | 342 | # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. |
337 | ls_ld_tmpdir=`ls -ld "$tmpdir"` | |
343 | test_tmpdir="$tmpdir/a" | |
344 | ls_ld_tmpdir=`ls -ld "$test_tmpdir"` | |
338 | 345 | case $ls_ld_tmpdir in |
339 | 346 | d????-?r-*) different_mode=700;; |
340 | 347 | d????-?--*) different_mode=755;; |
341 | 348 | *) false;; |
342 | 349 | esac && |
343 | $mkdirprog -m$different_mode -p -- "$tmpdir" && { | |
344 | ls_ld_tmpdir_1=`ls -ld "$tmpdir"` | |
350 | $mkdirprog -m$different_mode -p -- "$test_tmpdir" && { | |
351 | ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"` | |
345 | 352 | test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" |
346 | 353 | } |
347 | 354 | } |
348 | 355 | then posix_mkdir=: |
349 | 356 | fi |
350 | rmdir "$tmpdir/d" "$tmpdir" | |
357 | rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" | |
351 | 358 | else |
352 | 359 | # Remove any dirs left behind by ancient mkdir implementations. |
353 | rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null | |
360 | rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null | |
354 | 361 | fi |
355 | 362 | trap '' 0;; |
356 | 363 | esac;; |
516 | 516 | prefix = @prefix@ |
517 | 517 | program_transform_name = @program_transform_name@ |
518 | 518 | psdir = @psdir@ |
519 | runstatedir = @runstatedir@ | |
519 | 520 | sbindir = @sbindir@ |
520 | 521 | sharedstatedir = @sharedstatedir@ |
521 | 522 | srcdir = @srcdir@ |
766 | 766 | docdir |
767 | 767 | oldincludedir |
768 | 768 | includedir |
769 | runstatedir | |
769 | 770 | localstatedir |
770 | 771 | sharedstatedir |
771 | 772 | sysconfdir |
853 | 854 | sysconfdir='${prefix}/etc' |
854 | 855 | sharedstatedir='${prefix}/com' |
855 | 856 | localstatedir='${prefix}/var' |
857 | runstatedir='${localstatedir}/run' | |
856 | 858 | includedir='${prefix}/include' |
857 | 859 | oldincludedir='/usr/include' |
858 | 860 | docdir='${datarootdir}/doc/${PACKAGE}' |
1105 | 1107 | | -silent | --silent | --silen | --sile | --sil) |
1106 | 1108 | silent=yes ;; |
1107 | 1109 | |
1110 | -runstatedir | --runstatedir | --runstatedi | --runstated \ | |
1111 | | --runstate | --runstat | --runsta | --runst | --runs \ | |
1112 | | --run | --ru | --r) | |
1113 | ac_prev=runstatedir ;; | |
1114 | -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ | |
1115 | | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ | |
1116 | | --run=* | --ru=* | --r=*) | |
1117 | runstatedir=$ac_optarg ;; | |
1118 | ||
1108 | 1119 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
1109 | 1120 | ac_prev=sbindir ;; |
1110 | 1121 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
1242 | 1253 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
1243 | 1254 | datadir sysconfdir sharedstatedir localstatedir includedir \ |
1244 | 1255 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ |
1245 | libdir localedir mandir | |
1256 | libdir localedir mandir runstatedir | |
1246 | 1257 | do |
1247 | 1258 | eval ac_val=\$$ac_var |
1248 | 1259 | # Remove trailing slashes. |
1395 | 1406 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
1396 | 1407 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
1397 | 1408 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
1409 | --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] | |
1398 | 1410 | --libdir=DIR object code libraries [EPREFIX/lib] |
1399 | 1411 | --includedir=DIR C header files [PREFIX/include] |
1400 | 1412 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
313 | 313 | prefix = @prefix@ |
314 | 314 | program_transform_name = @program_transform_name@ |
315 | 315 | psdir = @psdir@ |
316 | runstatedir = @runstatedir@ | |
316 | 317 | sbindir = @sbindir@ |
317 | 318 | sharedstatedir = @sharedstatedir@ |
318 | 319 | srcdir = @srcdir@ |
332 | 332 | prefix = @prefix@ |
333 | 333 | program_transform_name = @program_transform_name@ |
334 | 334 | psdir = @psdir@ |
335 | runstatedir = @runstatedir@ | |
335 | 336 | sbindir = @sbindir@ |
336 | 337 | sharedstatedir = @sharedstatedir@ |
337 | 338 | srcdir = @srcdir@ |
587 | 587 | prefix = @prefix@ |
588 | 588 | program_transform_name = @program_transform_name@ |
589 | 589 | psdir = @psdir@ |
590 | runstatedir = @runstatedir@ | |
590 | 591 | sbindir = @sbindir@ |
591 | 592 | sharedstatedir = @sharedstatedir@ |
592 | 593 | srcdir = @srcdir@ |
0 | # | |
1 | # lldp_CONFIG_SUBDIRS | |
2 | # | |
3 | # This is almost like AC_CONFIG_SUBDIRS but it will take additional | |
4 | # arguments for ./configure. Also, ./configure is not delayed. Be sure | |
5 | # to call that late enough. | |
6 | ||
7 | AC_DEFUN([lldp_CONFIG_SUBDIRS], [ | |
8 | ac_sub_configure_args= | |
9 | ac_prev= | |
10 | eval "set x $ac_configure_args" | |
11 | shift | |
12 | for ac_arg | |
13 | do | |
14 | if test -n "$ac_prev"; then | |
15 | ac_prev= | |
16 | continue | |
17 | fi | |
18 | case $ac_arg in | |
19 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
20 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
21 | ac_prev=cache_file ;; | |
22 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
23 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \ | |
24 | | --c=*) | |
25 | ;; | |
26 | --config-cache | -C) | |
27 | ;; | |
28 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
29 | ac_prev=srcdir ;; | |
30 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
31 | ;; | |
32 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
33 | ac_prev=prefix ;; | |
34 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
35 | ;; | |
36 | --disable-option-checking) | |
37 | ;; | |
38 | *) | |
39 | case $ac_arg in | |
40 | *\'*) ac_arg=`AS_ECHO(["$ac_arg"]) | sed "s/'/'\\\\\\\\''/g"` ;; | |
41 | esac | |
42 | AS_VAR_APPEND([ac_sub_configure_args], [" '$ac_arg'"]) ;; | |
43 | esac | |
44 | done | |
45 | ||
46 | # Always prepend --prefix to ensure using the same prefix | |
47 | # in subdir configurations. | |
48 | ac_arg="--prefix=$prefix" | |
49 | case $ac_arg in | |
50 | *\'*) ac_arg=`AS_ECHO(["$ac_arg"]) | sed "s/'/'\\\\\\\\''/g"` ;; | |
51 | esac | |
52 | ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args" | |
53 | ||
54 | # Always prepend --disable-option-checking to silence warnings, since | |
55 | # different subdirs can have different --enable and --with options. | |
56 | ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args" | |
57 | ||
58 | # Silent rules | |
59 | case $enable_silent_rules in | |
60 | no) ac_sub_configure_args="$ac_sub_configure_args --disable-silent-rules" ;; | |
61 | *) ac_sub_configure_args="$ac_sub_configure_args --enable-silent-rules" ;; | |
62 | esac | |
63 | ||
64 | # Add additional options | |
65 | ac_sub_configure_args="$ac_sub_configure_args $2" | |
66 | ||
67 | ac_popdir=`pwd` | |
68 | ac_dir="m4_normalize([$1])" | |
69 | ||
70 | ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)" | |
71 | _AS_ECHO_LOG([$ac_msg]) | |
72 | _AS_ECHO([$ac_msg]) | |
73 | AS_MKDIR_P(["$ac_dir"]) | |
74 | _AC_SRCDIRS(["$ac_dir"]) | |
75 | ||
76 | cd "$ac_dir" | |
77 | ||
78 | ac_sub_configure=$ac_srcdir/configure | |
79 | ||
80 | # Make the cache file name correct relative to the subdirectory. | |
81 | case $cache_file in | |
82 | [[\\/]]* | ?:[[\\/]]* ) ac_sub_cache_file=$cache_file ;; | |
83 | *) # Relative name. | |
84 | ac_sub_cache_file=$ac_top_build_prefix$cache_file ;; | |
85 | esac | |
86 | ||
87 | AC_MSG_NOTICE([running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir]) | |
88 | # The eval makes quoting arguments work. | |
89 | eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \ | |
90 | --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" || | |
91 | AC_MSG_ERROR([$ac_sub_configure failed for $ac_dir]) | |
92 | ||
93 | ac_msg="=== end of configure in $ac_dir (`pwd`/$ac_dir)" | |
94 | _AS_ECHO_LOG([$ac_msg]) | |
95 | _AS_ECHO([$ac_msg]) | |
96 | cd "$ac_popdir" | |
97 | ]) |
6 | 6 | AC_ARG_WITH([embedded-libevent], |
7 | 7 | AS_HELP_STRING( |
8 | 8 | [--with-embedded-libevent], |
9 | [Force the use of embedded libevent @<:@default=no@:>@] | |
10 | )) | |
9 | [Use embedded libevent @<:@default=auto@:>@] | |
10 | ), [], [with_embedded_libevent=auto]) | |
11 | 11 | if test x"$with_embedded_libevent" = x"yes"; then |
12 | 12 | LIBEVENT_EMBEDDED=1 |
13 | 13 | else |
26 | 26 | [ |
27 | 27 | AC_MSG_RESULT([yes]) |
28 | 28 | ], [ |
29 | AC_MSG_RESULT([no, using shipped libevent]) | |
30 | LIBEVENT_EMBEDDED=1 | |
29 | if test x"$with_embedded_libevent" = x"auto"; then | |
30 | AC_MSG_RESULT([no, using shipped libevent]) | |
31 | LIBEVENT_EMBEDDED=1 | |
32 | else | |
33 | AC_MSG_ERROR([*** unusable system libevent]) | |
34 | fi | |
31 | 35 | ]) |
32 | 36 | CFLAGS="$_save_CFLAGS" |
33 | 37 | LIBS="$_save_LIBS" |
34 | 38 | ], [ |
35 | # No appropriate version, let's use the shipped copy | |
36 | AC_MSG_NOTICE([using shipped libevent]) | |
37 | LIBEVENT_EMBEDDED=1 | |
39 | # No appropriate version, let's use the shipped copy if possible | |
40 | if test x"$with_embedded_libevent" = x"auto"; then | |
41 | AC_MSG_NOTICE([using shipped libevent]) | |
42 | LIBEVENT_EMBEDDED=1 | |
43 | else | |
44 | AC_MSG_ERROR([*** libevent not found]) | |
45 | fi | |
38 | 46 | ]) |
39 | 47 | fi |
40 | 48 | |
44 | 52 | LIBEVENT_LDFLAGS="\$(top_builddir)/libevent/libevent.la" |
45 | 53 | fi |
46 | 54 | |
47 | # Override configure arguments | |
48 | ac_configure_args="$ac_configure_args --disable-libevent-regress --disable-thread-support --disable-openssl" | |
49 | ac_configure_args="$ac_configure_args --disable-malloc-replacement --disable-debug-mode --enable-function-sections" | |
50 | ac_configure_args="$ac_configure_args --disable-shared --with-pic --enable-static --enable-silent-rules" | |
51 | AC_CONFIG_SUBDIRS([libevent]) | |
55 | # Call ./configure in libevent. Need it for make dist... | |
56 | libevent_configure_args="$libevent_configure_args --disable-libevent-regress" | |
57 | libevent_configure_args="$libevent_configure_args --disable-thread-support" | |
58 | libevent_configure_args="$libevent_configure_args --disable-openssl" | |
59 | libevent_configure_args="$libevent_configure_args --disable-malloc-replacement" | |
60 | libevent_configure_args="$libevent_configure_args --disable-debug-mode" | |
61 | libevent_configure_args="$libevent_configure_args --enable-function-sections" | |
62 | libevent_configure_args="$libevent_configure_args --disable-shared" | |
63 | libevent_configure_args="$libevent_configure_args --with-pic" | |
64 | libevent_configure_args="$libevent_configure_args --enable-static" | |
65 | lldp_CONFIG_SUBDIRS([libevent], [$libevent_configure_args]) | |
66 | ||
52 | 67 | AM_CONDITIONAL([LIBEVENT_EMBEDDED], [test x"$LIBEVENT_EMBEDDED" != x]) |
53 | 68 | AC_SUBST([LIBEVENT_LIBS]) |
54 | 69 | AC_SUBST([LIBEVENT_CFLAGS]) |
95 | 95 | $(top_srcdir)/m4/ax_ld_check_flag.m4 \ |
96 | 96 | $(top_srcdir)/m4/ax_lib_readline.m4 \ |
97 | 97 | $(top_srcdir)/m4/ax_prog_doxygen.m4 \ |
98 | $(top_srcdir)/m4/jansson.m4 $(top_srcdir)/m4/json-c.m4 \ | |
98 | $(top_srcdir)/m4/config_subdirs.m4 $(top_srcdir)/m4/jansson.m4 \ | |
99 | $(top_srcdir)/m4/json-c.m4 \ | |
99 | 100 | $(top_srcdir)/m4/ld-version-script.m4 \ |
100 | 101 | $(top_srcdir)/m4/libevent.m4 $(top_srcdir)/m4/libtool.m4 \ |
101 | 102 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
339 | 340 | sbindir = @sbindir@ |
340 | 341 | sharedstatedir = @sharedstatedir@ |
341 | 342 | srcdir = @srcdir@ |
342 | subdirs = @subdirs@ | |
343 | 343 | sysconfdir = @sysconfdir@ |
344 | 344 | systemdsystemunitdir = @systemdsystemunitdir@ |
345 | 345 | sysusersdir = @sysusersdir@ |
96 | 96 | $(top_srcdir)/m4/ax_ld_check_flag.m4 \ |
97 | 97 | $(top_srcdir)/m4/ax_lib_readline.m4 \ |
98 | 98 | $(top_srcdir)/m4/ax_prog_doxygen.m4 \ |
99 | $(top_srcdir)/m4/jansson.m4 $(top_srcdir)/m4/json-c.m4 \ | |
99 | $(top_srcdir)/m4/config_subdirs.m4 $(top_srcdir)/m4/jansson.m4 \ | |
100 | $(top_srcdir)/m4/json-c.m4 \ | |
100 | 101 | $(top_srcdir)/m4/ld-version-script.m4 \ |
101 | 102 | $(top_srcdir)/m4/libevent.m4 $(top_srcdir)/m4/libtool.m4 \ |
102 | 103 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
397 | 398 | sbindir = @sbindir@ |
398 | 399 | sharedstatedir = @sharedstatedir@ |
399 | 400 | srcdir = @srcdir@ |
400 | subdirs = @subdirs@ | |
401 | 401 | sysconfdir = @sysconfdir@ |
402 | 402 | systemdsystemunitdir = @systemdsystemunitdir@ |
403 | 403 | sysusersdir = @sysusersdir@ |
106 | 106 | $(top_srcdir)/m4/ax_ld_check_flag.m4 \ |
107 | 107 | $(top_srcdir)/m4/ax_lib_readline.m4 \ |
108 | 108 | $(top_srcdir)/m4/ax_prog_doxygen.m4 \ |
109 | $(top_srcdir)/m4/jansson.m4 $(top_srcdir)/m4/json-c.m4 \ | |
109 | $(top_srcdir)/m4/config_subdirs.m4 $(top_srcdir)/m4/jansson.m4 \ | |
110 | $(top_srcdir)/m4/json-c.m4 \ | |
110 | 111 | $(top_srcdir)/m4/ld-version-script.m4 \ |
111 | 112 | $(top_srcdir)/m4/libevent.m4 $(top_srcdir)/m4/libtool.m4 \ |
112 | 113 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
428 | 429 | sbindir = @sbindir@ |
429 | 430 | sharedstatedir = @sharedstatedir@ |
430 | 431 | srcdir = @srcdir@ |
431 | subdirs = @subdirs@ | |
432 | 432 | sysconfdir = @sysconfdir@ |
433 | 433 | systemdsystemunitdir = @systemdsystemunitdir@ |
434 | 434 | sysusersdir = @sysusersdir@ |
384 | 384 | { |
385 | 385 | struct stat statbuf; |
386 | 386 | if (stat(arg, &statbuf) == -1) { |
387 | log_info("lldpctl", "cannot find configuration file/directory %s", | |
387 | log_warn("lldpctl", "cannot find configuration file/directory %s", | |
388 | 388 | arg); |
389 | 389 | return; |
390 | 390 | } |
431 | 431 | int ch, debug = 1, rc = EXIT_FAILURE; |
432 | 432 | const char *fmt = "plain"; |
433 | 433 | lldpctl_conn_t *conn = NULL; |
434 | const char *options = is_lldpctl(argv[0])?"hdvf:":"hdsvf:c:u:"; | |
434 | const char *options = is_lldpctl(argv[0])?"hdvf:u:":"hdsvf:c:u:"; | |
435 | 435 | |
436 | 436 | int gotinputs = 0; |
437 | 437 | struct inputs inputs; |
441 | 441 | |
442 | 442 | signal(SIGHUP, SIG_IGN); |
443 | 443 | |
444 | /* Initialize logging */ | |
444 | /* Get and parse command line options */ | |
445 | optind = 1; | |
445 | 446 | while ((ch = getopt(argc, argv, options)) != -1) { |
446 | 447 | switch (ch) { |
447 | 448 | case 'd': debug++; break; |
448 | 449 | case 's': debug--; break; |
449 | } | |
450 | } | |
451 | log_init(debug, __progname); | |
452 | lldpctl_log_level(debug); | |
453 | ||
454 | /* Get and parse command line options */ | |
455 | optind = 1; | |
456 | while ((ch = getopt(argc, argv, options)) != -1) { | |
457 | switch (ch) { | |
458 | case 'd': break; | |
459 | case 's': break; | |
460 | 450 | case 'h': |
461 | 451 | usage(); |
462 | 452 | break; |
471 | 461 | fmt = optarg; |
472 | 462 | break; |
473 | 463 | case 'c': |
474 | gotinputs = 1; | |
464 | if (!gotinputs) { | |
465 | log_init(debug, __progname); | |
466 | lldpctl_log_level(debug); | |
467 | gotinputs = 1; | |
468 | } | |
475 | 469 | input_append(optarg, &inputs, 1); |
476 | 470 | break; |
477 | 471 | default: |
478 | 472 | usage(); |
479 | 473 | } |
474 | } | |
475 | ||
476 | if (!gotinputs) { | |
477 | log_init(debug, __progname); | |
478 | lldpctl_log_level(debug); | |
480 | 479 | } |
481 | 480 | |
482 | 481 | /* Disable SIGPIPE */ |
0 | AM_CFLAGS = $(LLDP_CFLAGS) | |
1 | AM_CPPFLAGS = $(LLDP_CPPFLAGS) | |
2 | AM_LDFLAGS = $(LLDP_LDFLAGS) | |
3 | ||
0 | 4 | noinst_LTLIBRARIES = libcompat.la |
1 | 5 | |
2 | 6 | libcompat_la_SOURCES = compat.h empty.c |
95 | 95 | $(top_srcdir)/m4/ax_ld_check_flag.m4 \ |
96 | 96 | $(top_srcdir)/m4/ax_lib_readline.m4 \ |
97 | 97 | $(top_srcdir)/m4/ax_prog_doxygen.m4 \ |
98 | $(top_srcdir)/m4/jansson.m4 $(top_srcdir)/m4/json-c.m4 \ | |
98 | $(top_srcdir)/m4/config_subdirs.m4 $(top_srcdir)/m4/jansson.m4 \ | |
99 | $(top_srcdir)/m4/json-c.m4 \ | |
99 | 100 | $(top_srcdir)/m4/ld-version-script.m4 \ |
100 | 101 | $(top_srcdir)/m4/libevent.m4 $(top_srcdir)/m4/libtool.m4 \ |
101 | 102 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
360 | 361 | sbindir = @sbindir@ |
361 | 362 | sharedstatedir = @sharedstatedir@ |
362 | 363 | srcdir = @srcdir@ |
363 | subdirs = @subdirs@ | |
364 | 364 | sysconfdir = @sysconfdir@ |
365 | 365 | systemdsystemunitdir = @systemdsystemunitdir@ |
366 | 366 | sysusersdir = @sysusersdir@ |
368 | 368 | top_build_prefix = @top_build_prefix@ |
369 | 369 | top_builddir = @top_builddir@ |
370 | 370 | top_srcdir = @top_srcdir@ |
371 | AM_CFLAGS = $(LLDP_CFLAGS) | |
372 | AM_CPPFLAGS = $(LLDP_CPPFLAGS) | |
373 | AM_LDFLAGS = $(LLDP_LDFLAGS) | |
371 | 374 | noinst_LTLIBRARIES = libcompat.la |
372 | 375 | libcompat_la_SOURCES = compat.h empty.c |
373 | 376 | libcompat_la_LIBADD = @LTLIBOBJS@ |
163 | 163 | $(top_srcdir)/m4/ax_ld_check_flag.m4 \ |
164 | 164 | $(top_srcdir)/m4/ax_lib_readline.m4 \ |
165 | 165 | $(top_srcdir)/m4/ax_prog_doxygen.m4 \ |
166 | $(top_srcdir)/m4/jansson.m4 $(top_srcdir)/m4/json-c.m4 \ | |
166 | $(top_srcdir)/m4/config_subdirs.m4 $(top_srcdir)/m4/jansson.m4 \ | |
167 | $(top_srcdir)/m4/json-c.m4 \ | |
167 | 168 | $(top_srcdir)/m4/ld-version-script.m4 \ |
168 | 169 | $(top_srcdir)/m4/libevent.m4 $(top_srcdir)/m4/libtool.m4 \ |
169 | 170 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
537 | 538 | sbindir = @sbindir@ |
538 | 539 | sharedstatedir = @sharedstatedir@ |
539 | 540 | srcdir = @srcdir@ |
540 | subdirs = @subdirs@ | |
541 | 541 | sysconfdir = @sysconfdir@ |
542 | 542 | systemdsystemunitdir = @systemdsystemunitdir@ |
543 | 543 | sysusersdir = @sysusersdir@ |
1059 | 1059 | fatal("localchassis", "failed to set minimal system description"); |
1060 | 1060 | } |
1061 | 1061 | } |
1062 | if (cfg->g_config.c_platform == NULL) | |
1063 | cfg->g_config.c_platform = strdup(un.sysname); | |
1062 | 1064 | |
1063 | 1065 | /* Check routing */ |
1064 | 1066 | if (lldpd_routing_enabled(cfg)) { |
442 | 442 | if (iface1->lower_idx != -1 && iface1->lower_idx != iface1->index) |
443 | 443 | TAILQ_FOREACH(iface2, ifs, next) { |
444 | 444 | if (iface1->lower_idx == iface2->index) { |
445 | iface1->lower = iface2; | |
445 | if (iface2->lower_idx == iface1->index) { | |
446 | /* Workaround a bug introduced in Linux 4.1 */ | |
447 | iface2->lower_idx = iface2->index; | |
448 | iface1->lower_idx = iface1->index; | |
449 | } else iface1->lower = iface2; | |
446 | 450 | break; |
447 | 451 | } |
448 | 452 | } |
30 | 30 | cdp_send(struct lldpd *global, |
31 | 31 | struct lldpd_hardware *hardware, int version) |
32 | 32 | { |
33 | const char *platform = "Linux"; | |
33 | const char *platform = "Unknown"; | |
34 | 34 | struct lldpd_chassis *chassis; |
35 | 35 | struct lldpd_mgmt *mgmt; |
36 | 36 | struct lldpd_port *port; |
198 | 198 | |
199 | 199 | /* Platform */ |
200 | 200 | if (global && global->g_config.c_platform) platform = global->g_config.c_platform; |
201 | ||
201 | 202 | if (!( |
202 | 203 | POKE_START_CDP_TLV(CDP_TLV_PLATFORM) && |
203 | 204 | POKE_BYTES(platform, strlen(platform)) && |
100 | 100 | $(top_srcdir)/m4/ax_ld_check_flag.m4 \ |
101 | 101 | $(top_srcdir)/m4/ax_lib_readline.m4 \ |
102 | 102 | $(top_srcdir)/m4/ax_prog_doxygen.m4 \ |
103 | $(top_srcdir)/m4/jansson.m4 $(top_srcdir)/m4/json-c.m4 \ | |
103 | $(top_srcdir)/m4/config_subdirs.m4 $(top_srcdir)/m4/jansson.m4 \ | |
104 | $(top_srcdir)/m4/json-c.m4 \ | |
104 | 105 | $(top_srcdir)/m4/ld-version-script.m4 \ |
105 | 106 | $(top_srcdir)/m4/libevent.m4 $(top_srcdir)/m4/libtool.m4 \ |
106 | 107 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
405 | 406 | sbindir = @sbindir@ |
406 | 407 | sharedstatedir = @sharedstatedir@ |
407 | 408 | srcdir = @srcdir@ |
408 | subdirs = @subdirs@ | |
409 | 409 | sysconfdir = @sysconfdir@ |
410 | 410 | systemdsystemunitdir = @systemdsystemunitdir@ |
411 | 411 | sysusersdir = @sysusersdir@ |
102 | 102 | $(top_srcdir)/m4/ax_ld_check_flag.m4 \ |
103 | 103 | $(top_srcdir)/m4/ax_lib_readline.m4 \ |
104 | 104 | $(top_srcdir)/m4/ax_prog_doxygen.m4 \ |
105 | $(top_srcdir)/m4/jansson.m4 $(top_srcdir)/m4/json-c.m4 \ | |
105 | $(top_srcdir)/m4/config_subdirs.m4 $(top_srcdir)/m4/jansson.m4 \ | |
106 | $(top_srcdir)/m4/json-c.m4 \ | |
106 | 107 | $(top_srcdir)/m4/ld-version-script.m4 \ |
107 | 108 | $(top_srcdir)/m4/libevent.m4 $(top_srcdir)/m4/libtool.m4 \ |
108 | 109 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
658 | 659 | sbindir = @sbindir@ |
659 | 660 | sharedstatedir = @sharedstatedir@ |
660 | 661 | srcdir = @srcdir@ |
661 | subdirs = @subdirs@ | |
662 | 662 | sysconfdir = @sysconfdir@ |
663 | 663 | systemdsystemunitdir = @systemdsystemunitdir@ |
664 | 664 | sysusersdir = @sysusersdir@ |
106 | 106 | struct packet *pkt; |
107 | 107 | in_addr_t addr; |
108 | 108 | struct lldpd_mgmt *mgmt; |
109 | struct lldpd cfg = { | |
110 | .g_config = { | |
111 | .c_platform = "Linux" | |
112 | } | |
113 | }; | |
109 | 114 | |
110 | 115 | /* Populate port and chassis */ |
111 | 116 | hardware.h_lport.p_id_subtype = LLDP_PORTID_SUBTYPE_IFNAME; |
127 | 132 | TAILQ_INSERT_TAIL(&chassis.c_mgmt, mgmt, m_entries); |
128 | 133 | |
129 | 134 | /* Build packet */ |
130 | n = cdpv1_send(NULL, &hardware); | |
135 | n = cdpv1_send(&cfg, &hardware); | |
131 | 136 | if (n != 0) { |
132 | 137 | fail("unable to build packet"); |
133 | 138 | return; |
235 | 240 | in_addr_t addr2; |
236 | 241 | struct lldpd_mgmt *mgmt1; |
237 | 242 | struct lldpd_mgmt *mgmt2; |
243 | struct lldpd cfg = { | |
244 | .g_config = { | |
245 | .c_platform = "Linux" | |
246 | } | |
247 | }; | |
238 | 248 | |
239 | 249 | /* Populate port and chassis */ |
240 | 250 | hardware.h_lport.p_id_subtype = LLDP_PORTID_SUBTYPE_LLADDR; |
261 | 271 | TAILQ_INSERT_TAIL(&chassis.c_mgmt, mgmt2, m_entries); |
262 | 272 | |
263 | 273 | /* Build packet */ |
264 | n = cdpv2_send(NULL, &hardware); | |
274 | n = cdpv2_send(&cfg, &hardware); | |
265 | 275 | if (n != 0) { |
266 | 276 | fail("unable to build packet"); |
267 | 277 | return; |