FreeBSD Bugzilla – Attachment 161155 Details for
Bug 203182
[maintainer update] net/libbgpdump: update to 1.4.99.15
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
patch to update libbgpdump to 1.4.99.15
patch-libbgpdump (text/plain), 575.79 KB, created by
mjl
on 2015-09-17 23:24:13 UTC
(
hide
)
Description:
patch to update libbgpdump to 1.4.99.15
Filename:
MIME Type:
Creator:
mjl
Created:
2015-09-17 23:24:13 UTC
Size:
575.79 KB
patch
obsolete
>diff -uNr libbgpdump/Makefile libbgpdump-new/Makefile >--- libbgpdump/Makefile 2014-08-16 08:24:06.000000000 +1200 >+++ libbgpdump-new/Makefile 2015-09-18 11:12:01.928397000 +1200 >@@ -1,11 +1,9 @@ > # $FreeBSD: head/net/libbgpdump/Makefile 365034 2014-08-15 20:24:06Z pi $ > > PORTNAME= libbgpdump >-PORTVERSION= 1.4.99.13 >-PORTREVISION= 3 >+PORTVERSION= 1.4.99.15 > CATEGORIES= net > MASTER_SITES= http://www.ris.ripe.net/source/bgpdump/ >-EXTRACT_SUFX= .tgz > > MAINTAINER= mjl@luckie.org.nz > COMMENT= Analyzing dump files produced by Zebra/Quagga or MRT >@@ -14,18 +12,19 @@ > > GNU_CONFIGURE= yes > USE_LDCONFIG= yes >+USES= tar:tgz > > OPTIONS_DEFINE= DOCS EXAMPLES > > do-install: >- @${INSTALL_PROGRAM} ${WRKSRC}/bgpdump ${STAGEDIR}${PREFIX}/bin >- @${INSTALL_DATA} ${WRKSRC}/libbgpdump.* ${STAGEDIR}${PREFIX}/lib >- @${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libbgpdump.so >+ ${INSTALL_PROGRAM} ${WRKSRC}/bgpdump ${STAGEDIR}${PREFIX}/bin >+ ${INSTALL_DATA} ${WRKSRC}/libbgpdump.* ${STAGEDIR}${PREFIX}/lib >+ ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libbgpdump.so > .for i in bgpdump_attr.h bgpdump_formats.h bgpdump_lib.h >- @${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${PREFIX}/include >+ ${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${PREFIX}/include > .endfor >- @${MKDIR} ${STAGEDIR}${DOCSDIR} ${STAGEDIR}${EXAMPLESDIR} >- @${INSTALL_DATA} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR} >- @${INSTALL_DATA} ${WRKSRC}/example.c ${STAGEDIR}${EXAMPLESDIR} >+ ${MKDIR} ${STAGEDIR}${DOCSDIR} ${STAGEDIR}${EXAMPLESDIR} >+ ${INSTALL_DATA} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR} >+ ${INSTALL_DATA} ${WRKSRC}/example.c ${STAGEDIR}${EXAMPLESDIR} > > .include <bsd.port.mk> >diff -uNr libbgpdump/distinfo libbgpdump-new/distinfo >--- libbgpdump/distinfo 2014-01-23 04:30:13.000000000 +1300 >+++ libbgpdump-new/distinfo 2015-09-18 11:06:58.307974000 +1200 >@@ -1,2 +1,2 @@ >-SHA256 (libbgpdump-1.4.99.13.tgz) = 7551a285fa5c0885aec7290e1f316e58968baab70a4f3467f8f70868d338311e >-SIZE (libbgpdump-1.4.99.13.tgz) = 84083 >+SHA256 (libbgpdump-1.4.99.15.tgz) = 04ad874a745541ec88c87639cb6cfdddaba4db515360855108bc9d65f14b7576 >+SIZE (libbgpdump-1.4.99.15.tgz) = 131580 >diff -uNr libbgpdump/files/patch-bgpdump.c libbgpdump-new/files/patch-bgpdump.c >--- libbgpdump/files/patch-bgpdump.c 2014-07-25 15:50:02.000000000 +1200 >+++ libbgpdump-new/files/patch-bgpdump.c 1970-01-01 12:00:00.000000000 +1200 >@@ -1,13 +0,0 @@ >---- bgpdump.c.old 2014-07-24 13:02:50.000000000 +0000 >-+++ bgpdump.c 2014-07-24 13:03:27.000000000 +0000 >-@@ -164,10 +164,6 @@ >- exit(1); >- } >- >-- // more efficient then line buffering >-- char buffer[16000]; >-- setbuffer(stdout, buffer, sizeof buffer); >-- >- BGPDUMP *my_dump = bgpdump_open_dump(argv[0]); >- >- do { >diff -uNr libbgpdump/files/patch-util.c libbgpdump-new/files/patch-util.c >--- libbgpdump/files/patch-util.c 2014-08-16 08:24:06.000000000 +1200 >+++ libbgpdump-new/files/patch-util.c 1970-01-01 12:00:00.000000000 +1200 >@@ -1,29 +0,0 @@ >---- util.c.orig 2014-08-15 12:58:56.000000000 -0700 >-+++ util.c 2014-08-15 13:01:14.000000000 -0700 >-@@ -29,6 +29,7 @@ >- #include <syslog.h> >- #include <time.h> >- #include <string.h> >-+#include <inttypes.h> >- >- static bool use_syslog = true; >- >-@@ -110,17 +111,7 @@ >- >- int int2str(uint32_t value, char* str) >- { >-- const int LEN = 11; >-- char b[LEN]; >-- int i = LEN; >-- b[i--] = '\0'; >-- >-- do { >-- b[i--] = (char)(48 + (value % 10)); >-- } while (value /= 10); >-- >-- memcpy(str, b + i + 1, LEN - i); >-- return LEN - i - 1; >-+ return snprintf(str, 11, "%"PRIu32, value); >- } >- >- static void ti2s(uint32_t value) { >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/.cvsignore libbgpdump-new/work/libbgpdump-1.4.99.15/.cvsignore >--- libbgpdump/work/libbgpdump-1.4.99.15/.cvsignore 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/.cvsignore 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1 @@ >+.project >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/.hg_archival.txt libbgpdump-new/work/libbgpdump-1.4.99.15/.hg_archival.txt >--- libbgpdump/work/libbgpdump-1.4.99.15/.hg_archival.txt 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/.hg_archival.txt 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,5 @@ >+repo: fc85b5d83c23266299237988401380dcb3d3c4f3 >+node: 0cb1a4c59d10ba20de237a0a2b072df8829634ea >+branch: default >+latesttag: 1.4.99.15 >+latesttagdistance: 2 >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/.hgignore libbgpdump-new/work/libbgpdump-1.4.99.15/.hgignore >--- libbgpdump/work/libbgpdump-1.4.99.15/.hgignore 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/.hgignore 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,18 @@ >+\.o$ >+\.pbxuser$ >+\.mode1v3$ >+\.swp$ >+^bgpdump-config.h$ >+^config.log$ >+^config.status$ >+^bgpdump$ >+^testbgpdump$ >+^libbgpdump.a$ >+^libbgpdump.so$ >+^Makefile$ >+^test_out/.* >+^build/ >+^bgpdump.spec$ >+~$ >+^libbgpdump-.*\.tgz$ >+^autom4te.cache/ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/.hgtags libbgpdump-new/work/libbgpdump-1.4.99.15/.hgtags >--- libbgpdump/work/libbgpdump-1.4.99.15/.hgtags 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/.hgtags 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,9 @@ >+6271706a4a0e495b2cc5e48822d0d73abfc55807 1.4.98.7 >+e9617d1b0fa959ad3436797701d027958b335667 1.4.99.8 >+aeead79922f7eeac5d8e678b43101deef02cf847 1.4.99.9 >+397bfe76c57fe46694ac06735843575683c772e6 1.4.99.10 >+4cce25d5026009a1ba2924afa8b10907ecf4498e 1.4.99.11 >+9fe2f50927688e4560941e655b3c970c4b668540 1.4.99.12 >+b8e3ed2b370ca220f46bfa59193665dfdee5d5ef 1.4.99.13 >+c4c53146f09af40a0068992d67a345a05ac54514 1.4.99.14 >+d8e8bcf60eb4c7ce065b2744d6a32003c728d8b2 1.4.99.15 >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/COPYING libbgpdump-new/work/libbgpdump-1.4.99.15/COPYING >--- libbgpdump/work/libbgpdump-1.4.99.15/COPYING 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/COPYING 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,309 @@ >+ >+Copyright (C) 2007 - 2011 RIPE NCC >+ >+Permission to use, copy, modify, and distribute this software and its >+documentation for any purpose and without fee is hereby granted, provided >+that the above copyright notice appear in all copies and that both that >+copyright notice and this permission notice appear in supporting >+documentation, and that the name of the author not be used in advertising or >+publicity pertaining to distribution of the software without specific, >+written prior permission. >+ >+THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+---------------------------------------------------------------------------- >+ >+Parts of this code have been engineered after analiyzing GNU Zebra's >+source code and therefore might contain declarations/code from GNU >+Zebra, Copyright (C) 1999 Kunihiro Ishiguro. Zebra is a free routing >+software, distributed under the GNU General Public License. A copy of >+this license is included with libbgpdump. >+ >+---------------------------------------------------------------------------- >+ >+ GNU GENERAL PUBLIC LICENSE >+ Version 2, June 1991 >+ >+ Copyright (C) 1989, 1991 Free Software Foundation, Inc. >+ 675 Mass Ave, Cambridge, MA 02139, USA >+ Everyone is permitted to copy and distribute verbatim copies >+ of this license document, but changing it is not allowed. >+ >+ Preamble >+ >+ The licenses for most software are designed to take away your >+freedom to share and change it. By contrast, the GNU General Public >+License is intended to guarantee your freedom to share and change free >+software--to make sure the software is free for all its users. This >+General Public License applies to most of the Free Software >+Foundation's software and to any other program whose authors commit to >+using it. (Some other Free Software Foundation software is covered by >+the GNU Library General Public License instead.) You can apply it to >+your programs, too. >+ >+ When we speak of free software, we are referring to freedom, not >+price. Our General Public Licenses are designed to make sure that you >+have the freedom to distribute copies of free software (and charge for >+this service if you wish), that you receive source code or can get it >+if you want it, that you can change the software or use pieces of it >+in new free programs; and that you know you can do these things. >+ >+ To protect your rights, we need to make restrictions that forbid >+anyone to deny you these rights or to ask you to surrender the rights. >+These restrictions translate to certain responsibilities for you if you >+distribute copies of the software, or if you modify it. >+ >+ For example, if you distribute copies of such a program, whether >+gratis or for a fee, you must give the recipients all the rights that >+you have. You must make sure that they, too, receive or can get the >+source code. And you must show them these terms so they know their >+rights. >+ >+ We protect your rights with two steps: (1) copyright the software, and >+(2) offer you this license which gives you legal permission to copy, >+distribute and/or modify the software. >+ >+ Also, for each author's protection and ours, we want to make certain >+that everyone understands that there is no warranty for this free >+software. If the software is modified by someone else and passed on, we >+want its recipients to know that what they have is not the original, so >+that any problems introduced by others will not reflect on the original >+authors' reputations. >+ >+ Finally, any free program is threatened constantly by software >+patents. We wish to avoid the danger that redistributors of a free >+program will individually obtain patent licenses, in effect making the >+program proprietary. To prevent this, we have made it clear that any >+patent must be licensed for everyone's free use or not licensed at all. >+ >+ The precise terms and conditions for copying, distribution and >+modification follow. >+ >+ GNU GENERAL PUBLIC LICENSE >+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION >+ >+ 0. This License applies to any program or other work which contains >+a notice placed by the copyright holder saying it may be distributed >+under the terms of this General Public License. The "Program", below, >+refers to any such program or work, and a "work based on the Program" >+means either the Program or any derivative work under copyright law: >+that is to say, a work containing the Program or a portion of it, >+either verbatim or with modifications and/or translated into another >+language. (Hereinafter, translation is included without limitation in >+the term "modification".) Each licensee is addressed as "you". >+ >+Activities other than copying, distribution and modification are not >+covered by this License; they are outside its scope. The act of >+running the Program is not restricted, and the output from the Program >+is covered only if its contents constitute a work based on the >+Program (independent of having been made by running the Program). >+Whether that is true depends on what the Program does. >+ >+ 1. You may copy and distribute verbatim copies of the Program's >+source code as you receive it, in any medium, provided that you >+conspicuously and appropriately publish on each copy an appropriate >+copyright notice and disclaimer of warranty; keep intact all the >+notices that refer to this License and to the absence of any warranty; >+and give any other recipients of the Program a copy of this License >+along with the Program. >+ >+You may charge a fee for the physical act of transferring a copy, and >+you may at your option offer warranty protection in exchange for a fee. >+ >+ 2. You may modify your copy or copies of the Program or any portion >+of it, thus forming a work based on the Program, and copy and >+distribute such modifications or work under the terms of Section 1 >+above, provided that you also meet all of these conditions: >+ >+ a) You must cause the modified files to carry prominent notices >+ stating that you changed the files and the date of any change. >+ >+ b) You must cause any work that you distribute or publish, that in >+ whole or in part contains or is derived from the Program or any >+ part thereof, to be licensed as a whole at no charge to all third >+ parties under the terms of this License. >+ >+ c) If the modified program normally reads commands interactively >+ when run, you must cause it, when started running for such >+ interactive use in the most ordinary way, to print or display an >+ announcement including an appropriate copyright notice and a >+ notice that there is no warranty (or else, saying that you provide >+ a warranty) and that users may redistribute the program under >+ these conditions, and telling the user how to view a copy of this >+ License. (Exception: if the Program itself is interactive but >+ does not normally print such an announcement, your work based on >+ the Program is not required to print an announcement.) >+ >+These requirements apply to the modified work as a whole. If >+identifiable sections of that work are not derived from the Program, >+and can be reasonably considered independent and separate works in >+themselves, then this License, and its terms, do not apply to those >+sections when you distribute them as separate works. But when you >+distribute the same sections as part of a whole which is a work based >+on the Program, the distribution of the whole must be on the terms of >+this License, whose permissions for other licensees extend to the >+entire whole, and thus to each and every part regardless of who wrote it. >+ >+Thus, it is not the intent of this section to claim rights or contest >+your rights to work written entirely by you; rather, the intent is to >+exercise the right to control the distribution of derivative or >+collective works based on the Program. >+ >+In addition, mere aggregation of another work not based on the Program >+with the Program (or with a work based on the Program) on a volume of >+a storage or distribution medium does not bring the other work under >+the scope of this License. >+ >+ 3. You may copy and distribute the Program (or a work based on it, >+under Section 2) in object code or executable form under the terms of >+Sections 1 and 2 above provided that you also do one of the following: >+ >+ a) Accompany it with the complete corresponding machine-readable >+ source code, which must be distributed under the terms of Sections >+ 1 and 2 above on a medium customarily used for software interchange; or, >+ >+ b) Accompany it with a written offer, valid for at least three >+ years, to give any third party, for a charge no more than your >+ cost of physically performing source distribution, a complete >+ machine-readable copy of the corresponding source code, to be >+ distributed under the terms of Sections 1 and 2 above on a medium >+ customarily used for software interchange; or, >+ >+ c) Accompany it with the information you received as to the offer >+ to distribute corresponding source code. (This alternative is >+ allowed only for noncommercial distribution and only if you >+ received the program in object code or executable form with such >+ an offer, in accord with Subsection b above.) >+ >+The source code for a work means the preferred form of the work for >+making modifications to it. For an executable work, complete source >+code means all the source code for all modules it contains, plus any >+associated interface definition files, plus the scripts used to >+control compilation and installation of the executable. However, as a >+special exception, the source code distributed need not include >+anything that is normally distributed (in either source or binary >+form) with the major components (compiler, kernel, and so on) of the >+operating system on which the executable runs, unless that component >+itself accompanies the executable. >+ >+If distribution of executable or object code is made by offering >+access to copy from a designated place, then offering equivalent >+access to copy the source code from the same place counts as >+distribution of the source code, even though third parties are not >+compelled to copy the source along with the object code. >+ >+ 4. You may not copy, modify, sublicense, or distribute the Program >+except as expressly provided under this License. Any attempt >+otherwise to copy, modify, sublicense or distribute the Program is >+void, and will automatically terminate your rights under this License. >+However, parties who have received copies, or rights, from you under >+this License will not have their licenses terminated so long as such >+parties remain in full compliance. >+ >+ 5. You are not required to accept this License, since you have not >+signed it. However, nothing else grants you permission to modify or >+distribute the Program or its derivative works. These actions are >+prohibited by law if you do not accept this License. Therefore, by >+modifying or distributing the Program (or any work based on the >+Program), you indicate your acceptance of this License to do so, and >+all its terms and conditions for copying, distributing or modifying >+the Program or works based on it. >+ >+ 6. Each time you redistribute the Program (or any work based on the >+Program), the recipient automatically receives a license from the >+original licensor to copy, distribute or modify the Program subject to >+these terms and conditions. You may not impose any further >+restrictions on the recipients' exercise of the rights granted herein. >+You are not responsible for enforcing compliance by third parties to >+this License. >+ >+ 7. If, as a consequence of a court judgment or allegation of patent >+infringement or for any other reason (not limited to patent issues), >+conditions are imposed on you (whether by court order, agreement or >+otherwise) that contradict the conditions of this License, they do not >+excuse you from the conditions of this License. If you cannot >+distribute so as to satisfy simultaneously your obligations under this >+License and any other pertinent obligations, then as a consequence you >+may not distribute the Program at all. For example, if a patent >+license would not permit royalty-free redistribution of the Program by >+all those who receive copies directly or indirectly through you, then >+the only way you could satisfy both it and this License would be to >+refrain entirely from distribution of the Program. >+ >+If any portion of this section is held invalid or unenforceable under >+any particular circumstance, the balance of the section is intended to >+apply and the section as a whole is intended to apply in other >+circumstances. >+ >+It is not the purpose of this section to induce you to infringe any >+patents or other property right claims or to contest validity of any >+such claims; this section has the sole purpose of protecting the >+integrity of the free software distribution system, which is >+implemented by public license practices. Many people have made >+generous contributions to the wide range of software distributed >+through that system in reliance on consistent application of that >+system; it is up to the author/donor to decide if he or she is willing >+to distribute software through any other system and a licensee cannot >+impose that choice. >+ >+This section is intended to make thoroughly clear what is believed to >+be a consequence of the rest of this License. >+ >+ 8. If the distribution and/or use of the Program is restricted in >+certain countries either by patents or by copyrighted interfaces, the >+original copyright holder who places the Program under this License >+may add an explicit geographical distribution limitation excluding >+those countries, so that distribution is permitted only in or among >+countries not thus excluded. In such case, this License incorporates >+the limitation as if written in the body of this License. >+ >+ 9. The Free Software Foundation may publish revised and/or new versions >+of the General Public License from time to time. Such new versions will >+be similar in spirit to the present version, but may differ in detail to >+address new problems or concerns. >+ >+Each version is given a distinguishing version number. If the Program >+specifies a version number of this License which applies to it and "any >+later version", you have the option of following the terms and conditions >+either of that version or of any later version published by the Free >+Software Foundation. If the Program does not specify a version number of >+this License, you may choose any version ever published by the Free Software >+Foundation. >+ >+ 10. If you wish to incorporate parts of the Program into other free >+programs whose distribution conditions are different, write to the author >+to ask for permission. For software which is copyrighted by the Free >+Software Foundation, write to the Free Software Foundation; we sometimes >+make exceptions for this. Our decision will be guided by the two goals >+of preserving the free status of all derivatives of our free software and >+of promoting the sharing and reuse of software generally. >+ >+ NO WARRANTY >+ >+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY >+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN >+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES >+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED >+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF >+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS >+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE >+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, >+REPAIR OR CORRECTION. >+ >+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING >+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR >+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, >+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING >+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED >+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY >+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER >+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE >+POSSIBILITY OF SUCH DAMAGES. >+ >+ END OF TERMS AND CONDITIONS >+ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/ChangeLog libbgpdump-new/work/libbgpdump-1.4.99.15/ChangeLog >--- libbgpdump/work/libbgpdump-1.4.99.15/ChangeLog 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/ChangeLog 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,197 @@ >+========================================================== >+The current maintainer of this library is the >+RIPE NCC information services department. >+ >+You can reach us at https://bitbucket.org/ripencc/bgpdump >+ >+PLEASE DO NOT E-MAIL INDIVIDUAL DEVELOPERS ABOUT >+ISSUES, AS YOUR E-MAIL MAY BE LOST >+========================================================== >+ >+2015-07-16 Max Lapan <mlapan@ripe.net> >+ * -p option to show packet index >+ >+2011-01-25 Devin Bayer <dbayer@ripe.net> >+ * move development to bitbucket >+ >+2010-10-21 Devin Bayer <dbayer@ripe.net> v1.4.99.13 >+ * fix configure script for Darwin >+ >+2010-09-24 Devin Bayer <dbayer@ripe.net> v1.4.99.12 >+ * Remove --disable-ipv6 flag >+ * Fix parsing of IPv6 NEXT_HOP attributes >+ * Add clearer command-line options >+ * Add logging to STDERR >+ * Add dumping to files instead of STDOUT >+ * Add regression test suite >+ >+2009-11-24 Roman Kalyakin <roman@ripe.net> v1.4.99.11 >+ * Fixed incorrect output when running with -m which was >+ introduced by a change in one of the previous versions. >+ (issue IS-439) >+ >+2009-10-13 Ruben van Staveren <ruben@ripe.net> >+ * Fix segfaults with empty AS path on -m/-M >+ (issue IS-292) >+ Patch contributed by Lorenzo Colitti <lorenzo@google.com> >+ >+2009-07-29 Erik Romijn <eromijn@ripe.net> >+ * Fixing incorrect as path length count in case of AS_(CONFED_)SEQUENCE >+ (issue IS-141) >+ Patch contributed by Toby Ehrenkranz <tehrenkr@cs.uoregon.edu> >+ * Added support for the ORIGINATOR_ID and CLUSTER_LIST attributes >+ (issue IS-181) >+ Patch contributed by Maurizio Pizzonia <pizzonia@dia.uniroma3.it> >+ * Fixed signedness of MED and localpref (issue IS-180) >+ Patch contributed by Steve Hill <cheesy@sackheads.org> >+ * Implemented conditional checking for compression libraries (issue IS-179) >+ Patch contributed by Steve Hill <cheesy@sackheads.org> >+ >+2009-07-27 Ruben van Staveren <ruben@ripe.net> >+ * Enabled extra compiler warnings >+ * Fixed some potentially unsafe constructs (pointer arithmetic, >+ signed/unsigned comparisons, shadowed variables) >+ >+2009-07-22 Ruben van Staveren <ruben@ripe.net> >+ * Fixed a case where during -M dumps aspaths where printed for entries that >+ did not have their BGP_ATTR_AS_PATH flag set. Such entries will now print >+ an empty field. Reported by many people. >+ * Changed -fpic to -fPIC: newer gccs coerce -fpic to -fPIC any way. >+ difference is that with -fpic the global offset table has a maximum size >+ * Fixed nit in getopt handling >+ * Added distclean target >+ * In bgpdump_free_mp_info(), set pointers to NULL after freeing them. >+ Reported by Robert Kisteleki <robertk@ripe.net> >+ * Default output for 32bit ASN numbers is now ASPLAIN >+ >+2008-02-01 Erik Romijn <eromijn@ripe.net> >+ * Fixed a few memleaks based on a patch from >+ Antony Antony <antony@phenome.org> >+ (Ticket NCC#2007064868) >+ * Fixed compiling with --disable-ipv6 based on a patch >+ from Haniff Rahbari <hnrahbari@yahoo.com> >+ (Ticket NCC#2007111325) >+ * Fixed a few warnings, mostly based on a patch from >+ Bruno Quoitin <bruno.quoitin@uclouvain.be> >+ (Ticket NCC#2007123069) >+ * Made bgpdump's usage message nicer >+ >+2007-06-21 Erik Romijn <eromijn@ripe.net> >+ * Fixed incorrect dump time display for some cases >+ >+2007-06-06 Erik Romijn <eromijn@ripe.net> >+ * Set proper compile options to work on Mac OS X 10.4 >+ >+2007-06-01 Erik Romijn <eromijn@ripe.net> >+ * Fixed several bugs in 64-bit PC support and added >+ bzip2 support, credit goes to >+ Bernhard Tellenbach <betellen@tik.ee.ethz.ch> >+ for providing patches. >+ * Fixed incorrect IPv6 nexthops in -M/-m output >+ >+2007-03-29 Erik Romijn <eromijn@ripe.net> >+ * Fixed a serious segfault in the insertion of update dumps >+ >+2007-03-28 Erik Romijn <eromijn@ripe.net> >+ * Fixed a large memory leak in TABLE_DUMP_V2 processing >+ >+2007-03-27 Erik Romijn <eromijn@ripe.net> >+ * Fixed a bug causing segfaults on processing some MP_REACH_NLRI's >+ >+2007-03-09 Erik Romijn <eromijn@ripe.net> >+ * Updated TABLE_DUMP_V2 support to comply with draft-ietf-grow-mrt-04 >+ >+2007-03-07 Erik Romijn <eromijn@ripe.net> >+ * Built in TABLE_DUMP_V2 support >+ * Rename ..MESSAGE32 to ..MESSAGE_AS4 >+ * Fixed bug where -M always crashed >+ >+2007-02-01 Erik Romijn <eromijn@ripe.net> >+ * Minor fix in ASN32 support >+ >+2006-10-20 Lorenzo Colitti <lorenzo@ripe.net> >+ * Implement ASN32 support >+ >+2005-11-08 Young Hyun <youngh@caida.org> >+ * IPv6 prefixes were not printed properly by bgpdump. >+ >+2004-02-10 Lorenzo Colitti <lorenzo@ripe.net> >+ * Fix a stupid crash when reading truncated prefixes. >+ >+2004-02-09 Lorenzo Colitti <lorenzo@ripe.net> >+ * Decode unknown attributes properly. >+ * Fix a crash when reading truncated prefixes. >+ >+2004-02-04 Hong-wei Kong <hong-wei_kong@agilent.com> >+ * Add a new option (-t dump|change) to bgpdump. If '-t dump' is >+ specified, then the decoding result with '-m' / '-M' option will >+ show the timestamp when these routes are dumped. If '-t change' is >+ specified, then the decoding result with '-m' / '-M' option will >+ show the timestamp when the routes were last time changed. This >+ option only works with routing table dumps. >+ >+2004-01-16 Lorenzo Colitti <lorenzo@ripe.net> >+ * Fix compile errors under cygwin (only IPv4 works though) >+ >+2003-12-18 Hong-Wei Kong <hong-wei_kong@agilent.com> >+ * Added support for dumping BGP routing table entries in >+ machine-readable format (-m). Previously -m was only supported >+ for BGP messages >+ >+2003-12-16 Shufu Mao <msf98@mails.tsinghua.edu.cn> >+ * Revised the decoding of BGP routing table dump to make the result >+ identical to route_btoa >+ >+2003-12-15 Lorenzo Colitti <lorenzo@ripe.net> >+ * Proper autoconf support: check for features instead of target >+ systems, remove extra .h files and only use configure.in, use >+ Makefile.in instead of Make.include, link both static and >+ shared library, check for ar and ranlib, etc. >+ * Changed INET6 to BGPDUMP_HAVE_IPV6 >+ (N.B. Docs are not updated yet) >+ * Fixed possible endianness issues on Sparc. >+ * Fixed a crash while decoding NOTIFICATION messages >+ >+2003-11-26 Shufu Mao <msf98@mails.tsinghua.edu.cn> >+ >+ * Workaround for zebra "NOIP" bug >+ * Preliminary autoconf support (./configure; make) >+ * Added option to disable IPv6. If this option is specified to >+ ./configure, the library is compiled without IPv6 support. >+ The default is to turn on IPv6 if the necessary headers are >+ available. >+ >+2003-11-25 Lorenzo Colitti <lorenzo@ripe.net> >+ >+ * Added support for OPEN and NOTIFICATION messages. >+ * Better workarounds for corrupt data produced by zebra/quagga bugs. >+ * The library now keeps track of how many records were parsed and how >+ many were successfully parsed. >+ * Better error reporting. Now an error will be logged through syslog >+ whenever a record cannot be decoded. >+ * Agilent Labs contributed bgpdump, a tool which emulates route_btoa >+ using libbgpdump. This should be a drop-in replacement for people >+ currently using route_btoa and supports IPv6 on all platforms. >+ >+2003-10-15 Lorenzo Colitti <lorenzo@ripe.net> >+ >+ * 1.3.1 beta released >+ * Added support for reading from gzipped input files and gzipped stdin. >+ NOTE: this means you must now link with zlib! >+ * Changed Makefile to build a shared library by default. >+ * Renamed test program from test2 to testbgpdump. >+ >+2003-10-15 Lorenzo Colitti <lorenzo@ripe.net> >+ >+ * 1.3 beta released >+ * Added IPv6 support. Note that this changes some interfaces! >+ See README.ipv6 for details. >+ * Set announce and withdraw arrays to NULL to avoid segfaults if there >+ is a parse error. >+ * Change mstream behaviour so it always returns zero bytes if reading >+ past the end of a packet. This eliminates non-deterministic >+ behaviour (random segfaults, infinite loops, ...) when parsing >+ corrupt data, including the consequences of the zebra "update packet >+ truncated at 4096 bytes" bug. >+ * Other fixes to handle corrupt data better. >+ * Other miscellaneous fixes. >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/Makefile libbgpdump-new/work/libbgpdump-1.4.99.15/Makefile >--- libbgpdump/work/libbgpdump-1.4.99.15/Makefile 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/Makefile 2015-09-16 20:23:15.000000000 +1200 >@@ -0,0 +1,64 @@ >+ >+CC = gcc -fPIC >+CFLAGS = -g -O3 -Wall -Wsystem-headers -Wno-format-y2k -Wno-sign-compare -Wcast-align -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wswitch -Wshadow >+COMPILE = $(CC) $(CFLAGS) $(INCLUDES) >+ >+LD = gcc >+LDFLAGS = -dynamiclib >+RANLIB = ranlib >+ >+SYS_LIBS= -lbz2 -lz >+ >+prefix = /usr/local >+exec_prefix = ${prefix} >+bindir = ${exec_prefix}/bin >+libdir = ${exec_prefix}/lib >+includedir = ${prefix}/include >+ >+LIB_H = bgpdump_attr.h bgpdump_formats.h bgpdump_lib.h bgpdump_mstream.h >+LIB_O = bgpdump_lib.o bgpdump_mstream.o cfile_tools.o util.o inet_ntop.o >+OTHER = *.in configure bgpdump.spec README* ChangeLog License* >+ >+all: libbgpdump.so bgpdump >+ >+libbgpdump.a: $(LIB_H) $(LIB_O) Makefile cfile_tools.h util.h >+ ar r libbgpdump.a $(LIB_O) >+ $(RANLIB) libbgpdump.a >+ >+libbgpdump.so: libbgpdump.a >+ $(COMPILE) $(LDFLAGS) -o libbgpdump.so $(LIB_O) $(SYS_LIBS) >+ >+example: example.c libbgpdump.a >+ $(COMPILE) -o example example.c libbgpdump.a $(SYS_LIBS) >+ >+bgpdump: bgpdump.c libbgpdump.a >+ $(COMPILE) -o bgpdump bgpdump.c libbgpdump.a $(SYS_LIBS) >+ >+check-clean: >+ rm -f test_out/*.bgp.gz >+ >+check: check-clean bgpdump >+ ./test.sh >+ >+clean: check-clean >+ rm -f libbgpdump.so libbgpdump.a example bgpdump $(LIB_O) >+ >+distclean: clean >+ rm -Rf config.log config.status *.dSYM core *.core autom4te.cache bgpdump-config.h Makefile >+ rm -Rf $(PKG) >+ >+install: all >+ install -d $(bindir) $(includedir) $(libdir) >+ install bgpdump $(bindir) >+ install $(LIB_H) $(includedir) >+ install libbgpdump.so libbgpdump.a $(libdir) >+ >+PKG=libbgpdump-1.4.99.15 >+dist: >+ mkdir $(PKG) >+ ln *.h *.c $(OTHER) $(PKG) >+ tar -czf $(PKG).tgz $(PKG) >+ rm $(PKG)/* && rmdir $(PKG) >+ >+rpm: dist >+ rpmbuild -v -ta $(PKG).tgz >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/Makefile.in libbgpdump-new/work/libbgpdump-1.4.99.15/Makefile.in >--- libbgpdump/work/libbgpdump-1.4.99.15/Makefile.in 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/Makefile.in 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,64 @@ >+ >+CC = @CC@ -fPIC >+CFLAGS = @CFLAGS@ >+COMPILE = $(CC) $(CFLAGS) $(INCLUDES) >+ >+LD = @CC@ >+LDFLAGS = @LDFLAGS@ >+RANLIB = @RANLIB@ >+ >+SYS_LIBS= @LIBS@ >+ >+prefix = @prefix@ >+exec_prefix = @exec_prefix@ >+bindir = @bindir@ >+libdir = @libdir@ >+includedir = @includedir@ >+ >+LIB_H = bgpdump_attr.h bgpdump_formats.h bgpdump_lib.h bgpdump_mstream.h >+LIB_O = bgpdump_lib.o bgpdump_mstream.o cfile_tools.o util.o inet_ntop.o >+OTHER = *.in configure bgpdump.spec README* ChangeLog License* >+ >+all: libbgpdump.so bgpdump >+ >+libbgpdump.a: $(LIB_H) $(LIB_O) Makefile cfile_tools.h util.h >+ ar r libbgpdump.a $(LIB_O) >+ $(RANLIB) libbgpdump.a >+ >+libbgpdump.so: libbgpdump.a >+ $(COMPILE) $(LDFLAGS) -o libbgpdump.so $(LIB_O) $(SYS_LIBS) >+ >+example: example.c libbgpdump.a >+ $(COMPILE) -o example example.c libbgpdump.a $(SYS_LIBS) >+ >+bgpdump: bgpdump.c libbgpdump.a >+ $(COMPILE) -o bgpdump bgpdump.c libbgpdump.a $(SYS_LIBS) >+ >+check-clean: >+ rm -f test_out/*.bgp.gz >+ >+check: check-clean bgpdump >+ ./test.sh >+ >+clean: check-clean >+ rm -f libbgpdump.so libbgpdump.a example bgpdump $(LIB_O) >+ >+distclean: clean >+ rm -Rf config.log config.status *.dSYM core *.core autom4te.cache bgpdump-config.h Makefile >+ rm -Rf $(PKG) >+ >+install: all >+ install -d $(bindir) $(includedir) $(libdir) >+ install bgpdump $(bindir) >+ install $(LIB_H) $(includedir) >+ install libbgpdump.so libbgpdump.a $(libdir) >+ >+PKG=@PACKAGE_NAME@-@PACKAGE_VERSION@ >+dist: >+ mkdir $(PKG) >+ ln *.h *.c $(OTHER) $(PKG) >+ tar -czf $(PKG).tgz $(PKG) >+ rm $(PKG)/* && rmdir $(PKG) >+ >+rpm: dist >+ rpmbuild -v -ta $(PKG).tgz >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/README libbgpdump-new/work/libbgpdump-1.4.99.15/README >--- libbgpdump/work/libbgpdump-1.4.99.15/README 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/README 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,8 @@ >+== libBGPdump == >+ >+A C library designed to help with analyzing dump >+files produced by Zebra/Quagga or MRT. Documenation >+is available at: >+ >+https://bitbucket.org/ripencc/bgpdump/wiki/Home >+ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/autom4te.cache/output.0 libbgpdump-new/work/libbgpdump-1.4.99.15/autom4te.cache/output.0 >--- libbgpdump/work/libbgpdump-1.4.99.15/autom4te.cache/output.0 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/autom4te.cache/output.0 2015-09-16 20:22:47.000000000 +1200 >@@ -0,0 +1,5019 @@ >+@%:@! /bin/sh >+@%:@ From configure.in Revision. >+@%:@ Guess values for system-dependent variables and create Makefiles. >+@%:@ Generated by GNU Autoconf 2.69 for libbgpdump 1.4.99.15. >+@%:@ >+@%:@ Report bugs to <ris@ripe.net>. >+@%:@ >+@%:@ >+@%:@ Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. >+@%:@ >+@%:@ >+@%:@ This configure script is free software; the Free Software Foundation >+@%:@ gives unlimited permission to copy, distribute and modify it. >+## -------------------- ## >+## M4sh Initialization. ## >+## -------------------- ## >+ >+# Be more Bourne compatible >+DUALCASE=1; export DUALCASE # for MKS sh >+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : >+ emulate sh >+ NULLCMD=: >+ # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which >+ # is contrary to our usage. Disable this feature. >+ alias -g '${1+"$@"}'='"$@"' >+ setopt NO_GLOB_SUBST >+else >+ case `(set -o) 2>/dev/null` in @%:@( >+ *posix*) : >+ set -o posix ;; @%:@( >+ *) : >+ ;; >+esac >+fi >+ >+ >+as_nl=' >+' >+export as_nl >+# Printing a long string crashes Solaris 7 /usr/bin/printf. >+as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo >+# Prefer a ksh shell builtin over an external printf program on Solaris, >+# but without wasting forks for bash or zsh. >+if test -z "$BASH_VERSION$ZSH_VERSION" \ >+ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='print -r --' >+ as_echo_n='print -rn --' >+elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='printf %s\n' >+ as_echo_n='printf %s' >+else >+ if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then >+ as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' >+ as_echo_n='/usr/ucb/echo -n' >+ else >+ as_echo_body='eval expr "X$1" : "X\\(.*\\)"' >+ as_echo_n_body='eval >+ arg=$1; >+ case $arg in @%:@( >+ *"$as_nl"*) >+ expr "X$arg" : "X\\(.*\\)$as_nl"; >+ arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; >+ esac; >+ expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" >+ ' >+ export as_echo_n_body >+ as_echo_n='sh -c $as_echo_n_body as_echo' >+ fi >+ export as_echo_body >+ as_echo='sh -c $as_echo_body as_echo' >+fi >+ >+# The user is always right. >+if test "${PATH_SEPARATOR+set}" != set; then >+ PATH_SEPARATOR=: >+ (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { >+ (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || >+ PATH_SEPARATOR=';' >+ } >+fi >+ >+ >+# IFS >+# We need space, tab and new line, in precisely that order. Quoting is >+# there to prevent editors from complaining about space-tab. >+# (If _AS_PATH_WALK were called with IFS unset, it would disable word >+# splitting by setting IFS to empty value.) >+IFS=" "" $as_nl" >+ >+# Find who we are. Look in the path if we contain no directory separator. >+as_myself= >+case $0 in @%:@(( >+ *[\\/]* ) as_myself=$0 ;; >+ *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break >+ done >+IFS=$as_save_IFS >+ >+ ;; >+esac >+# We did not find ourselves, most probably we were run as `sh COMMAND' >+# in which case we are not to be found in the path. >+if test "x$as_myself" = x; then >+ as_myself=$0 >+fi >+if test ! -f "$as_myself"; then >+ $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 >+ exit 1 >+fi >+ >+# Unset variables that we do not need and which cause bugs (e.g. in >+# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" >+# suppresses any "Segmentation fault" message there. '((' could >+# trigger a bug in pdksh 5.2.14. >+for as_var in BASH_ENV ENV MAIL MAILPATH >+do eval test x\${$as_var+set} = xset \ >+ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : >+done >+PS1='$ ' >+PS2='> ' >+PS4='+ ' >+ >+# NLS nuisances. >+LC_ALL=C >+export LC_ALL >+LANGUAGE=C >+export LANGUAGE >+ >+# CDPATH. >+(unset CDPATH) >/dev/null 2>&1 && unset CDPATH >+ >+# Use a proper internal environment variable to ensure we don't fall >+ # into an infinite loop, continuously re-executing ourselves. >+ if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then >+ _as_can_reexec=no; export _as_can_reexec; >+ # We cannot yet assume a decent shell, so we have to provide a >+# neutralization value for shells without unset; and this also >+# works around shells that cannot unset nonexistent variables. >+# Preserve -v and -x to the replacement shell. >+BASH_ENV=/dev/null >+ENV=/dev/null >+(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV >+case $- in @%:@ (((( >+ *v*x* | *x*v* ) as_opts=-vx ;; >+ *v* ) as_opts=-v ;; >+ *x* ) as_opts=-x ;; >+ * ) as_opts= ;; >+esac >+exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} >+# Admittedly, this is quite paranoid, since all the known shells bail >+# out after a failed `exec'. >+$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 >+as_fn_exit 255 >+ fi >+ # We don't want this to propagate to other subprocesses. >+ { _as_can_reexec=; unset _as_can_reexec;} >+if test "x$CONFIG_SHELL" = x; then >+ as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : >+ emulate sh >+ NULLCMD=: >+ # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which >+ # is contrary to our usage. Disable this feature. >+ alias -g '\${1+\"\$@\"}'='\"\$@\"' >+ setopt NO_GLOB_SUBST >+else >+ case \`(set -o) 2>/dev/null\` in @%:@( >+ *posix*) : >+ set -o posix ;; @%:@( >+ *) : >+ ;; >+esac >+fi >+" >+ as_required="as_fn_return () { (exit \$1); } >+as_fn_success () { as_fn_return 0; } >+as_fn_failure () { as_fn_return 1; } >+as_fn_ret_success () { return 0; } >+as_fn_ret_failure () { return 1; } >+ >+exitcode=0 >+as_fn_success || { exitcode=1; echo as_fn_success failed.; } >+as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } >+as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } >+as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } >+if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : >+ >+else >+ exitcode=1; echo positional parameters were not saved. >+fi >+test x\$exitcode = x0 || exit 1 >+test -x / || exit 1" >+ as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO >+ as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO >+ eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && >+ test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 >+test \$(( 1 + 1 )) = 2 || exit 1" >+ if (eval "$as_required") 2>/dev/null; then : >+ as_have_required=yes >+else >+ as_have_required=no >+fi >+ if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : >+ >+else >+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+as_found=false >+for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ as_found=: >+ case $as_dir in @%:@( >+ /*) >+ for as_base in sh bash ksh sh5; do >+ # Try only shells that exist, to save several forks. >+ as_shell=$as_dir/$as_base >+ if { test -f "$as_shell" || test -f "$as_shell.exe"; } && >+ { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : >+ CONFIG_SHELL=$as_shell as_have_required=yes >+ if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : >+ break 2 >+fi >+fi >+ done;; >+ esac >+ as_found=false >+done >+$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && >+ { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : >+ CONFIG_SHELL=$SHELL as_have_required=yes >+fi; } >+IFS=$as_save_IFS >+ >+ >+ if test "x$CONFIG_SHELL" != x; then : >+ export CONFIG_SHELL >+ # We cannot yet assume a decent shell, so we have to provide a >+# neutralization value for shells without unset; and this also >+# works around shells that cannot unset nonexistent variables. >+# Preserve -v and -x to the replacement shell. >+BASH_ENV=/dev/null >+ENV=/dev/null >+(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV >+case $- in @%:@ (((( >+ *v*x* | *x*v* ) as_opts=-vx ;; >+ *v* ) as_opts=-v ;; >+ *x* ) as_opts=-x ;; >+ * ) as_opts= ;; >+esac >+exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} >+# Admittedly, this is quite paranoid, since all the known shells bail >+# out after a failed `exec'. >+$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 >+exit 255 >+fi >+ >+ if test x$as_have_required = xno; then : >+ $as_echo "$0: This script requires a shell more modern than all" >+ $as_echo "$0: the shells that I found on your system." >+ if test x${ZSH_VERSION+set} = xset ; then >+ $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" >+ $as_echo "$0: be upgraded to zsh 4.3.4 or later." >+ else >+ $as_echo "$0: Please tell bug-autoconf@gnu.org and ris@ripe.net about >+$0: your system, including any error possibly output before >+$0: this message. Then install a modern shell, or manually >+$0: run the script under such a shell if you do have one." >+ fi >+ exit 1 >+fi >+fi >+fi >+SHELL=${CONFIG_SHELL-/bin/sh} >+export SHELL >+# Unset more variables known to interfere with behavior of common tools. >+CLICOLOR_FORCE= GREP_OPTIONS= >+unset CLICOLOR_FORCE GREP_OPTIONS >+ >+## --------------------- ## >+## M4sh Shell Functions. ## >+## --------------------- ## >+@%:@ as_fn_unset VAR >+@%:@ --------------- >+@%:@ Portably unset VAR. >+as_fn_unset () >+{ >+ { eval $1=; unset $1;} >+} >+as_unset=as_fn_unset >+ >+@%:@ as_fn_set_status STATUS >+@%:@ ----------------------- >+@%:@ Set @S|@? to STATUS, without forking. >+as_fn_set_status () >+{ >+ return $1 >+} @%:@ as_fn_set_status >+ >+@%:@ as_fn_exit STATUS >+@%:@ ----------------- >+@%:@ Exit the shell with STATUS, even in a "trap 0" or "set -e" context. >+as_fn_exit () >+{ >+ set +e >+ as_fn_set_status $1 >+ exit $1 >+} @%:@ as_fn_exit >+ >+@%:@ as_fn_mkdir_p >+@%:@ ------------- >+@%:@ Create "@S|@as_dir" as a directory, including parents if necessary. >+as_fn_mkdir_p () >+{ >+ >+ case $as_dir in #( >+ -*) as_dir=./$as_dir;; >+ esac >+ test -d "$as_dir" || eval $as_mkdir_p || { >+ as_dirs= >+ while :; do >+ case $as_dir in #( >+ *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( >+ *) as_qdir=$as_dir;; >+ esac >+ as_dirs="'$as_qdir' $as_dirs" >+ as_dir=`$as_dirname -- "$as_dir" || >+$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$as_dir" : 'X\(//\)[^/]' \| \ >+ X"$as_dir" : 'X\(//\)$' \| \ >+ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$as_dir" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ test -d "$as_dir" && break >+ done >+ test -z "$as_dirs" || eval "mkdir $as_dirs" >+ } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" >+ >+ >+} @%:@ as_fn_mkdir_p >+ >+@%:@ as_fn_executable_p FILE >+@%:@ ----------------------- >+@%:@ Test if FILE is an executable regular file. >+as_fn_executable_p () >+{ >+ test -f "$1" && test -x "$1" >+} @%:@ as_fn_executable_p >+@%:@ as_fn_append VAR VALUE >+@%:@ ---------------------- >+@%:@ Append the text in VALUE to the end of the definition contained in VAR. Take >+@%:@ advantage of any shell optimizations that allow amortized linear growth over >+@%:@ repeated appends, instead of the typical quadratic growth present in naive >+@%:@ implementations. >+if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : >+ eval 'as_fn_append () >+ { >+ eval $1+=\$2 >+ }' >+else >+ as_fn_append () >+ { >+ eval $1=\$$1\$2 >+ } >+fi # as_fn_append >+ >+@%:@ as_fn_arith ARG... >+@%:@ ------------------ >+@%:@ Perform arithmetic evaluation on the ARGs, and store the result in the >+@%:@ global @S|@as_val. Take advantage of shells that can avoid forks. The arguments >+@%:@ must be portable across @S|@(()) and expr. >+if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : >+ eval 'as_fn_arith () >+ { >+ as_val=$(( $* )) >+ }' >+else >+ as_fn_arith () >+ { >+ as_val=`expr "$@" || test $? -eq 1` >+ } >+fi # as_fn_arith >+ >+ >+@%:@ as_fn_error STATUS ERROR [LINENO LOG_FD] >+@%:@ ---------------------------------------- >+@%:@ Output "`basename @S|@0`: error: ERROR" to stderr. If LINENO and LOG_FD are >+@%:@ provided, also output the error to LOG_FD, referencing LINENO. Then exit the >+@%:@ script with STATUS, using 1 if that was 0. >+as_fn_error () >+{ >+ as_status=$1; test $as_status -eq 0 && as_status=1 >+ if test "$4"; then >+ as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 >+ fi >+ $as_echo "$as_me: error: $2" >&2 >+ as_fn_exit $as_status >+} @%:@ as_fn_error >+ >+if expr a : '\(a\)' >/dev/null 2>&1 && >+ test "X`expr 00001 : '.*\(...\)'`" = X001; then >+ as_expr=expr >+else >+ as_expr=false >+fi >+ >+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then >+ as_basename=basename >+else >+ as_basename=false >+fi >+ >+if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then >+ as_dirname=dirname >+else >+ as_dirname=false >+fi >+ >+as_me=`$as_basename -- "$0" || >+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ >+ X"$0" : 'X\(//\)$' \| \ >+ X"$0" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X/"$0" | >+ sed '/^.*\/\([^/][^/]*\)\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ >+# Avoid depending upon Character Ranges. >+as_cr_letters='abcdefghijklmnopqrstuvwxyz' >+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' >+as_cr_Letters=$as_cr_letters$as_cr_LETTERS >+as_cr_digits='0123456789' >+as_cr_alnum=$as_cr_Letters$as_cr_digits >+ >+ >+ as_lineno_1=$LINENO as_lineno_1a=$LINENO >+ as_lineno_2=$LINENO as_lineno_2a=$LINENO >+ eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && >+ test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { >+ # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) >+ sed -n ' >+ p >+ /[$]LINENO/= >+ ' <$as_myself | >+ sed ' >+ s/[$]LINENO.*/&-/ >+ t lineno >+ b >+ :lineno >+ N >+ :loop >+ s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ >+ t loop >+ s/-\n.*// >+ ' >$as_me.lineno && >+ chmod +x "$as_me.lineno" || >+ { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } >+ >+ # If we had to re-execute with $CONFIG_SHELL, we're ensured to have >+ # already done that, so ensure we don't try to do so again and fall >+ # in an infinite loop. This has already happened in practice. >+ _as_can_reexec=no; export _as_can_reexec >+ # Don't try to exec as it changes $[0], causing all sort of problems >+ # (the dirname of $[0] is not the place where we might find the >+ # original and so on. Autoconf is especially sensitive to this). >+ . "./$as_me.lineno" >+ # Exit status is that of the last command. >+ exit >+} >+ >+ECHO_C= ECHO_N= ECHO_T= >+case `echo -n x` in @%:@((((( >+-n*) >+ case `echo 'xy\c'` in >+ *c*) ECHO_T=' ';; # ECHO_T is single tab character. >+ xy) ECHO_C='\c';; >+ *) echo `echo ksh88 bug on AIX 6.1` > /dev/null >+ ECHO_T=' ';; >+ esac;; >+*) >+ ECHO_N='-n';; >+esac >+ >+rm -f conf$$ conf$$.exe conf$$.file >+if test -d conf$$.dir; then >+ rm -f conf$$.dir/conf$$.file >+else >+ rm -f conf$$.dir >+ mkdir conf$$.dir 2>/dev/null >+fi >+if (echo >conf$$.file) 2>/dev/null; then >+ if ln -s conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s='ln -s' >+ # ... but there are two gotchas: >+ # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. >+ # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. >+ # In both cases, we have to default to `cp -pR'. >+ ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || >+ as_ln_s='cp -pR' >+ elif ln conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s=ln >+ else >+ as_ln_s='cp -pR' >+ fi >+else >+ as_ln_s='cp -pR' >+fi >+rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file >+rmdir conf$$.dir 2>/dev/null >+ >+if mkdir -p . 2>/dev/null; then >+ as_mkdir_p='mkdir -p "$as_dir"' >+else >+ test -d ./-p && rmdir ./-p >+ as_mkdir_p=false >+fi >+ >+as_test_x='test -x' >+as_executable_p=as_fn_executable_p >+ >+# Sed expression to map a string onto a valid CPP name. >+as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" >+ >+# Sed expression to map a string onto a valid variable name. >+as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" >+ >+ >+test -n "$DJDIR" || exec 7<&0 </dev/null >+exec 6>&1 >+ >+# Name of the host. >+# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, >+# so uname gets run too. >+ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` >+ >+# >+# Initializations. >+# >+ac_default_prefix=/usr/local >+ac_clean_files= >+ac_config_libobj_dir=. >+LIB@&t@OBJS= >+cross_compiling=no >+subdirs= >+MFLAGS= >+MAKEFLAGS= >+ >+# Identity of this package. >+PACKAGE_NAME='libbgpdump' >+PACKAGE_TARNAME='libbgpdump' >+PACKAGE_VERSION='1.4.99.15' >+PACKAGE_STRING='libbgpdump 1.4.99.15' >+PACKAGE_BUGREPORT='ris@ripe.net' >+PACKAGE_URL='' >+ >+ac_unique_file="bgpdump_lib.c" >+# Factoring default headers for most tests. >+ac_includes_default="\ >+#include <stdio.h> >+#ifdef HAVE_SYS_TYPES_H >+# include <sys/types.h> >+#endif >+#ifdef HAVE_SYS_STAT_H >+# include <sys/stat.h> >+#endif >+#ifdef STDC_HEADERS >+# include <stdlib.h> >+# include <stddef.h> >+#else >+# ifdef HAVE_STDLIB_H >+# include <stdlib.h> >+# endif >+#endif >+#ifdef HAVE_STRING_H >+# if !defined STDC_HEADERS && defined HAVE_MEMORY_H >+# include <memory.h> >+# endif >+# include <string.h> >+#endif >+#ifdef HAVE_STRINGS_H >+# include <strings.h> >+#endif >+#ifdef HAVE_INTTYPES_H >+# include <inttypes.h> >+#endif >+#ifdef HAVE_STDINT_H >+# include <stdint.h> >+#endif >+#ifdef HAVE_UNISTD_H >+# include <unistd.h> >+#endif" >+ >+ac_subst_vars='LTLIBOBJS >+LIB@&t@OBJS >+EGREP >+GREP >+CPP >+RANLIB >+OBJEXT >+EXEEXT >+ac_ct_CC >+CPPFLAGS >+LDFLAGS >+CFLAGS >+CC >+target_alias >+host_alias >+build_alias >+LIBS >+ECHO_T >+ECHO_N >+ECHO_C >+DEFS >+mandir >+localedir >+libdir >+psdir >+pdfdir >+dvidir >+htmldir >+infodir >+docdir >+oldincludedir >+includedir >+localstatedir >+sharedstatedir >+sysconfdir >+datadir >+datarootdir >+libexecdir >+sbindir >+bindir >+program_transform_name >+prefix >+exec_prefix >+PACKAGE_URL >+PACKAGE_BUGREPORT >+PACKAGE_STRING >+PACKAGE_VERSION >+PACKAGE_TARNAME >+PACKAGE_NAME >+PATH_SEPARATOR >+SHELL' >+ac_subst_files='' >+ac_user_opts=' >+enable_option_checking >+' >+ ac_precious_vars='build_alias >+host_alias >+target_alias >+CC >+CFLAGS >+LDFLAGS >+LIBS >+CPPFLAGS >+CPP' >+ >+ >+# Initialize some variables set by options. >+ac_init_help= >+ac_init_version=false >+ac_unrecognized_opts= >+ac_unrecognized_sep= >+# The variables have the same names as the options, with >+# dashes changed to underlines. >+cache_file=/dev/null >+exec_prefix=NONE >+no_create= >+no_recursion= >+prefix=NONE >+program_prefix=NONE >+program_suffix=NONE >+program_transform_name=s,x,x, >+silent= >+site= >+srcdir= >+verbose= >+x_includes=NONE >+x_libraries=NONE >+ >+# Installation directory options. >+# These are left unexpanded so users can "make install exec_prefix=/foo" >+# and all the variables that are supposed to be based on exec_prefix >+# by default will actually change. >+# Use braces instead of parens because sh, perl, etc. also accept them. >+# (The list follows the same order as the GNU Coding Standards.) >+bindir='${exec_prefix}/bin' >+sbindir='${exec_prefix}/sbin' >+libexecdir='${exec_prefix}/libexec' >+datarootdir='${prefix}/share' >+datadir='${datarootdir}' >+sysconfdir='${prefix}/etc' >+sharedstatedir='${prefix}/com' >+localstatedir='${prefix}/var' >+includedir='${prefix}/include' >+oldincludedir='/usr/include' >+docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' >+infodir='${datarootdir}/info' >+htmldir='${docdir}' >+dvidir='${docdir}' >+pdfdir='${docdir}' >+psdir='${docdir}' >+libdir='${exec_prefix}/lib' >+localedir='${datarootdir}/locale' >+mandir='${datarootdir}/man' >+ >+ac_prev= >+ac_dashdash= >+for ac_option >+do >+ # If the previous option needs an argument, assign it. >+ if test -n "$ac_prev"; then >+ eval $ac_prev=\$ac_option >+ ac_prev= >+ continue >+ fi >+ >+ case $ac_option in >+ *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; >+ *=) ac_optarg= ;; >+ *) ac_optarg=yes ;; >+ esac >+ >+ # Accept the important Cygnus configure options, so we can diagnose typos. >+ >+ case $ac_dashdash$ac_option in >+ --) >+ ac_dashdash=yes ;; >+ >+ -bindir | --bindir | --bindi | --bind | --bin | --bi) >+ ac_prev=bindir ;; >+ -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) >+ bindir=$ac_optarg ;; >+ >+ -build | --build | --buil | --bui | --bu) >+ ac_prev=build_alias ;; >+ -build=* | --build=* | --buil=* | --bui=* | --bu=*) >+ build_alias=$ac_optarg ;; >+ >+ -cache-file | --cache-file | --cache-fil | --cache-fi \ >+ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) >+ ac_prev=cache_file ;; >+ -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ >+ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) >+ cache_file=$ac_optarg ;; >+ >+ --config-cache | -C) >+ cache_file=config.cache ;; >+ >+ -datadir | --datadir | --datadi | --datad) >+ ac_prev=datadir ;; >+ -datadir=* | --datadir=* | --datadi=* | --datad=*) >+ datadir=$ac_optarg ;; >+ >+ -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ >+ | --dataroo | --dataro | --datar) >+ ac_prev=datarootdir ;; >+ -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ >+ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) >+ datarootdir=$ac_optarg ;; >+ >+ -disable-* | --disable-*) >+ ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` >+ # Reject names that are not valid shell variable names. >+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && >+ as_fn_error $? "invalid feature name: $ac_useropt" >+ ac_useropt_orig=$ac_useropt >+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` >+ case $ac_user_opts in >+ *" >+"enable_$ac_useropt" >+"*) ;; >+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" >+ ac_unrecognized_sep=', ';; >+ esac >+ eval enable_$ac_useropt=no ;; >+ >+ -docdir | --docdir | --docdi | --doc | --do) >+ ac_prev=docdir ;; >+ -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) >+ docdir=$ac_optarg ;; >+ >+ -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) >+ ac_prev=dvidir ;; >+ -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) >+ dvidir=$ac_optarg ;; >+ >+ -enable-* | --enable-*) >+ ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` >+ # Reject names that are not valid shell variable names. >+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && >+ as_fn_error $? "invalid feature name: $ac_useropt" >+ ac_useropt_orig=$ac_useropt >+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` >+ case $ac_user_opts in >+ *" >+"enable_$ac_useropt" >+"*) ;; >+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" >+ ac_unrecognized_sep=', ';; >+ esac >+ eval enable_$ac_useropt=\$ac_optarg ;; >+ >+ -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ >+ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ >+ | --exec | --exe | --ex) >+ ac_prev=exec_prefix ;; >+ -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ >+ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ >+ | --exec=* | --exe=* | --ex=*) >+ exec_prefix=$ac_optarg ;; >+ >+ -gas | --gas | --ga | --g) >+ # Obsolete; use --with-gas. >+ with_gas=yes ;; >+ >+ -help | --help | --hel | --he | -h) >+ ac_init_help=long ;; >+ -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) >+ ac_init_help=recursive ;; >+ -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) >+ ac_init_help=short ;; >+ >+ -host | --host | --hos | --ho) >+ ac_prev=host_alias ;; >+ -host=* | --host=* | --hos=* | --ho=*) >+ host_alias=$ac_optarg ;; >+ >+ -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) >+ ac_prev=htmldir ;; >+ -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ >+ | --ht=*) >+ htmldir=$ac_optarg ;; >+ >+ -includedir | --includedir | --includedi | --included | --include \ >+ | --includ | --inclu | --incl | --inc) >+ ac_prev=includedir ;; >+ -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ >+ | --includ=* | --inclu=* | --incl=* | --inc=*) >+ includedir=$ac_optarg ;; >+ >+ -infodir | --infodir | --infodi | --infod | --info | --inf) >+ ac_prev=infodir ;; >+ -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) >+ infodir=$ac_optarg ;; >+ >+ -libdir | --libdir | --libdi | --libd) >+ ac_prev=libdir ;; >+ -libdir=* | --libdir=* | --libdi=* | --libd=*) >+ libdir=$ac_optarg ;; >+ >+ -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ >+ | --libexe | --libex | --libe) >+ ac_prev=libexecdir ;; >+ -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ >+ | --libexe=* | --libex=* | --libe=*) >+ libexecdir=$ac_optarg ;; >+ >+ -localedir | --localedir | --localedi | --localed | --locale) >+ ac_prev=localedir ;; >+ -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) >+ localedir=$ac_optarg ;; >+ >+ -localstatedir | --localstatedir | --localstatedi | --localstated \ >+ | --localstate | --localstat | --localsta | --localst | --locals) >+ ac_prev=localstatedir ;; >+ -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ >+ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) >+ localstatedir=$ac_optarg ;; >+ >+ -mandir | --mandir | --mandi | --mand | --man | --ma | --m) >+ ac_prev=mandir ;; >+ -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) >+ mandir=$ac_optarg ;; >+ >+ -nfp | --nfp | --nf) >+ # Obsolete; use --without-fp. >+ with_fp=no ;; >+ >+ -no-create | --no-create | --no-creat | --no-crea | --no-cre \ >+ | --no-cr | --no-c | -n) >+ no_create=yes ;; >+ >+ -no-recursion | --no-recursion | --no-recursio | --no-recursi \ >+ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) >+ no_recursion=yes ;; >+ >+ -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ >+ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ >+ | --oldin | --oldi | --old | --ol | --o) >+ ac_prev=oldincludedir ;; >+ -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ >+ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ >+ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) >+ oldincludedir=$ac_optarg ;; >+ >+ -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) >+ ac_prev=prefix ;; >+ -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) >+ prefix=$ac_optarg ;; >+ >+ -program-prefix | --program-prefix | --program-prefi | --program-pref \ >+ | --program-pre | --program-pr | --program-p) >+ ac_prev=program_prefix ;; >+ -program-prefix=* | --program-prefix=* | --program-prefi=* \ >+ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) >+ program_prefix=$ac_optarg ;; >+ >+ -program-suffix | --program-suffix | --program-suffi | --program-suff \ >+ | --program-suf | --program-su | --program-s) >+ ac_prev=program_suffix ;; >+ -program-suffix=* | --program-suffix=* | --program-suffi=* \ >+ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) >+ program_suffix=$ac_optarg ;; >+ >+ -program-transform-name | --program-transform-name \ >+ | --program-transform-nam | --program-transform-na \ >+ | --program-transform-n | --program-transform- \ >+ | --program-transform | --program-transfor \ >+ | --program-transfo | --program-transf \ >+ | --program-trans | --program-tran \ >+ | --progr-tra | --program-tr | --program-t) >+ ac_prev=program_transform_name ;; >+ -program-transform-name=* | --program-transform-name=* \ >+ | --program-transform-nam=* | --program-transform-na=* \ >+ | --program-transform-n=* | --program-transform-=* \ >+ | --program-transform=* | --program-transfor=* \ >+ | --program-transfo=* | --program-transf=* \ >+ | --program-trans=* | --program-tran=* \ >+ | --progr-tra=* | --program-tr=* | --program-t=*) >+ program_transform_name=$ac_optarg ;; >+ >+ -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) >+ ac_prev=pdfdir ;; >+ -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) >+ pdfdir=$ac_optarg ;; >+ >+ -psdir | --psdir | --psdi | --psd | --ps) >+ ac_prev=psdir ;; >+ -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) >+ psdir=$ac_optarg ;; >+ >+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \ >+ | -silent | --silent | --silen | --sile | --sil) >+ silent=yes ;; >+ >+ -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) >+ ac_prev=sbindir ;; >+ -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ >+ | --sbi=* | --sb=*) >+ sbindir=$ac_optarg ;; >+ >+ -sharedstatedir | --sharedstatedir | --sharedstatedi \ >+ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ >+ | --sharedst | --shareds | --shared | --share | --shar \ >+ | --sha | --sh) >+ ac_prev=sharedstatedir ;; >+ -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ >+ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ >+ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ >+ | --sha=* | --sh=*) >+ sharedstatedir=$ac_optarg ;; >+ >+ -site | --site | --sit) >+ ac_prev=site ;; >+ -site=* | --site=* | --sit=*) >+ site=$ac_optarg ;; >+ >+ -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) >+ ac_prev=srcdir ;; >+ -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) >+ srcdir=$ac_optarg ;; >+ >+ -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ >+ | --syscon | --sysco | --sysc | --sys | --sy) >+ ac_prev=sysconfdir ;; >+ -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ >+ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) >+ sysconfdir=$ac_optarg ;; >+ >+ -target | --target | --targe | --targ | --tar | --ta | --t) >+ ac_prev=target_alias ;; >+ -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) >+ target_alias=$ac_optarg ;; >+ >+ -v | -verbose | --verbose | --verbos | --verbo | --verb) >+ verbose=yes ;; >+ >+ -version | --version | --versio | --versi | --vers | -V) >+ ac_init_version=: ;; >+ >+ -with-* | --with-*) >+ ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` >+ # Reject names that are not valid shell variable names. >+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && >+ as_fn_error $? "invalid package name: $ac_useropt" >+ ac_useropt_orig=$ac_useropt >+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` >+ case $ac_user_opts in >+ *" >+"with_$ac_useropt" >+"*) ;; >+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" >+ ac_unrecognized_sep=', ';; >+ esac >+ eval with_$ac_useropt=\$ac_optarg ;; >+ >+ -without-* | --without-*) >+ ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` >+ # Reject names that are not valid shell variable names. >+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && >+ as_fn_error $? "invalid package name: $ac_useropt" >+ ac_useropt_orig=$ac_useropt >+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` >+ case $ac_user_opts in >+ *" >+"with_$ac_useropt" >+"*) ;; >+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" >+ ac_unrecognized_sep=', ';; >+ esac >+ eval with_$ac_useropt=no ;; >+ >+ --x) >+ # Obsolete; use --with-x. >+ with_x=yes ;; >+ >+ -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ >+ | --x-incl | --x-inc | --x-in | --x-i) >+ ac_prev=x_includes ;; >+ -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ >+ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) >+ x_includes=$ac_optarg ;; >+ >+ -x-libraries | --x-libraries | --x-librarie | --x-librari \ >+ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) >+ ac_prev=x_libraries ;; >+ -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ >+ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) >+ x_libraries=$ac_optarg ;; >+ >+ -*) as_fn_error $? "unrecognized option: \`$ac_option' >+Try \`$0 --help' for more information" >+ ;; >+ >+ *=*) >+ ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` >+ # Reject names that are not valid shell variable names. >+ case $ac_envvar in #( >+ '' | [0-9]* | *[!_$as_cr_alnum]* ) >+ as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; >+ esac >+ eval $ac_envvar=\$ac_optarg >+ export $ac_envvar ;; >+ >+ *) >+ # FIXME: should be removed in autoconf 3.0. >+ $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 >+ expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && >+ $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 >+ : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" >+ ;; >+ >+ esac >+done >+ >+if test -n "$ac_prev"; then >+ ac_option=--`echo $ac_prev | sed 's/_/-/g'` >+ as_fn_error $? "missing argument to $ac_option" >+fi >+ >+if test -n "$ac_unrecognized_opts"; then >+ case $enable_option_checking in >+ no) ;; >+ fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; >+ *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; >+ esac >+fi >+ >+# Check all directory arguments for consistency. >+for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ >+ datadir sysconfdir sharedstatedir localstatedir includedir \ >+ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ >+ libdir localedir mandir >+do >+ eval ac_val=\$$ac_var >+ # Remove trailing slashes. >+ case $ac_val in >+ */ ) >+ ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` >+ eval $ac_var=\$ac_val;; >+ esac >+ # Be sure to have absolute directory names. >+ case $ac_val in >+ [\\/$]* | ?:[\\/]* ) continue;; >+ NONE | '' ) case $ac_var in *prefix ) continue;; esac;; >+ esac >+ as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" >+done >+ >+# There might be people who depend on the old broken behavior: `$host' >+# used to hold the argument of --host etc. >+# FIXME: To remove some day. >+build=$build_alias >+host=$host_alias >+target=$target_alias >+ >+# FIXME: To remove some day. >+if test "x$host_alias" != x; then >+ if test "x$build_alias" = x; then >+ cross_compiling=maybe >+ elif test "x$build_alias" != "x$host_alias"; then >+ cross_compiling=yes >+ fi >+fi >+ >+ac_tool_prefix= >+test -n "$host_alias" && ac_tool_prefix=$host_alias- >+ >+test "$silent" = yes && exec 6>/dev/null >+ >+ >+ac_pwd=`pwd` && test -n "$ac_pwd" && >+ac_ls_di=`ls -di .` && >+ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || >+ as_fn_error $? "working directory cannot be determined" >+test "X$ac_ls_di" = "X$ac_pwd_ls_di" || >+ as_fn_error $? "pwd does not report name of working directory" >+ >+ >+# Find the source files, if location was not specified. >+if test -z "$srcdir"; then >+ ac_srcdir_defaulted=yes >+ # Try the directory containing this script, then the parent directory. >+ ac_confdir=`$as_dirname -- "$as_myself" || >+$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$as_myself" : 'X\(//\)[^/]' \| \ >+ X"$as_myself" : 'X\(//\)$' \| \ >+ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$as_myself" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ srcdir=$ac_confdir >+ if test ! -r "$srcdir/$ac_unique_file"; then >+ srcdir=.. >+ fi >+else >+ ac_srcdir_defaulted=no >+fi >+if test ! -r "$srcdir/$ac_unique_file"; then >+ test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." >+ as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" >+fi >+ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" >+ac_abs_confdir=`( >+ cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" >+ pwd)` >+# When building in place, set srcdir=. >+if test "$ac_abs_confdir" = "$ac_pwd"; then >+ srcdir=. >+fi >+# Remove unnecessary trailing slashes from srcdir. >+# Double slashes in file names in object file debugging info >+# mess up M-x gdb in Emacs. >+case $srcdir in >+*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; >+esac >+for ac_var in $ac_precious_vars; do >+ eval ac_env_${ac_var}_set=\${${ac_var}+set} >+ eval ac_env_${ac_var}_value=\$${ac_var} >+ eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} >+ eval ac_cv_env_${ac_var}_value=\$${ac_var} >+done >+ >+# >+# Report the --help message. >+# >+if test "$ac_init_help" = "long"; then >+ # Omit some internal or obsolete options to make the list less imposing. >+ # This message is too long to be a string in the A/UX 3.1 sh. >+ cat <<_ACEOF >+\`configure' configures libbgpdump 1.4.99.15 to adapt to many kinds of systems. >+ >+Usage: $0 [OPTION]... [VAR=VALUE]... >+ >+To assign environment variables (e.g., CC, CFLAGS...), specify them as >+VAR=VALUE. See below for descriptions of some of the useful variables. >+ >+Defaults for the options are specified in brackets. >+ >+Configuration: >+ -h, --help display this help and exit >+ --help=short display options specific to this package >+ --help=recursive display the short help of all the included packages >+ -V, --version display version information and exit >+ -q, --quiet, --silent do not print \`checking ...' messages >+ --cache-file=FILE cache test results in FILE [disabled] >+ -C, --config-cache alias for \`--cache-file=config.cache' >+ -n, --no-create do not create output files >+ --srcdir=DIR find the sources in DIR [configure dir or \`..'] >+ >+Installation directories: >+ --prefix=PREFIX install architecture-independent files in PREFIX >+ @<:@@S|@ac_default_prefix@:>@ >+ --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX >+ @<:@PREFIX@:>@ >+ >+By default, \`make install' will install all the files in >+\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify >+an installation prefix other than \`$ac_default_prefix' using \`--prefix', >+for instance \`--prefix=\$HOME'. >+ >+For better control, use the options below. >+ >+Fine tuning of the installation directories: >+ --bindir=DIR user executables [EPREFIX/bin] >+ --sbindir=DIR system admin executables [EPREFIX/sbin] >+ --libexecdir=DIR program executables [EPREFIX/libexec] >+ --sysconfdir=DIR read-only single-machine data [PREFIX/etc] >+ --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] >+ --localstatedir=DIR modifiable single-machine data [PREFIX/var] >+ --libdir=DIR object code libraries [EPREFIX/lib] >+ --includedir=DIR C header files [PREFIX/include] >+ --oldincludedir=DIR C header files for non-gcc [/usr/include] >+ --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] >+ --datadir=DIR read-only architecture-independent data [DATAROOTDIR] >+ --infodir=DIR info documentation [DATAROOTDIR/info] >+ --localedir=DIR locale-dependent data [DATAROOTDIR/locale] >+ --mandir=DIR man documentation [DATAROOTDIR/man] >+ --docdir=DIR documentation root @<:@DATAROOTDIR/doc/libbgpdump@:>@ >+ --htmldir=DIR html documentation [DOCDIR] >+ --dvidir=DIR dvi documentation [DOCDIR] >+ --pdfdir=DIR pdf documentation [DOCDIR] >+ --psdir=DIR ps documentation [DOCDIR] >+_ACEOF >+ >+ cat <<\_ACEOF >+_ACEOF >+fi >+ >+if test -n "$ac_init_help"; then >+ case $ac_init_help in >+ short | recursive ) echo "Configuration of libbgpdump 1.4.99.15:";; >+ esac >+ cat <<\_ACEOF >+ >+Some influential environment variables: >+ CC C compiler command >+ CFLAGS C compiler flags >+ LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a >+ nonstandard directory <lib dir> >+ LIBS libraries to pass to the linker, e.g. -l<library> >+ CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if >+ you have headers in a nonstandard directory <include dir> >+ CPP C preprocessor >+ >+Use these variables to override the choices made by `configure' or to help >+it to find libraries and programs with nonstandard names/locations. >+ >+Report bugs to <ris@ripe.net>. >+_ACEOF >+ac_status=$? >+fi >+ >+if test "$ac_init_help" = "recursive"; then >+ # If there are subdirs, report their specific --help. >+ for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue >+ test -d "$ac_dir" || >+ { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || >+ continue >+ ac_builddir=. >+ >+case "$ac_dir" in >+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; >+*) >+ ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` >+ # A ".." for each directory in $ac_dir_suffix. >+ ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` >+ case $ac_top_builddir_sub in >+ "") ac_top_builddir_sub=. ac_top_build_prefix= ;; >+ *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; >+ esac ;; >+esac >+ac_abs_top_builddir=$ac_pwd >+ac_abs_builddir=$ac_pwd$ac_dir_suffix >+# for backward compatibility: >+ac_top_builddir=$ac_top_build_prefix >+ >+case $srcdir in >+ .) # We are building in place. >+ ac_srcdir=. >+ ac_top_srcdir=$ac_top_builddir_sub >+ ac_abs_top_srcdir=$ac_pwd ;; >+ [\\/]* | ?:[\\/]* ) # Absolute name. >+ ac_srcdir=$srcdir$ac_dir_suffix; >+ ac_top_srcdir=$srcdir >+ ac_abs_top_srcdir=$srcdir ;; >+ *) # Relative name. >+ ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix >+ ac_top_srcdir=$ac_top_build_prefix$srcdir >+ ac_abs_top_srcdir=$ac_pwd/$srcdir ;; >+esac >+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix >+ >+ cd "$ac_dir" || { ac_status=$?; continue; } >+ # Check for guested configure. >+ if test -f "$ac_srcdir/configure.gnu"; then >+ echo && >+ $SHELL "$ac_srcdir/configure.gnu" --help=recursive >+ elif test -f "$ac_srcdir/configure"; then >+ echo && >+ $SHELL "$ac_srcdir/configure" --help=recursive >+ else >+ $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 >+ fi || ac_status=$? >+ cd "$ac_pwd" || { ac_status=$?; break; } >+ done >+fi >+ >+test -n "$ac_init_help" && exit $ac_status >+if $ac_init_version; then >+ cat <<\_ACEOF >+libbgpdump configure 1.4.99.15 >+generated by GNU Autoconf 2.69 >+ >+Copyright (C) 2012 Free Software Foundation, Inc. >+This configure script is free software; the Free Software Foundation >+gives unlimited permission to copy, distribute and modify it. >+_ACEOF >+ exit >+fi >+ >+## ------------------------ ## >+## Autoconf initialization. ## >+## ------------------------ ## >+ >+@%:@ ac_fn_c_try_compile LINENO >+@%:@ -------------------------- >+@%:@ Try to compile conftest.@S|@ac_ext, and return whether this succeeded. >+ac_fn_c_try_compile () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ rm -f conftest.$ac_objext >+ if { { ac_try="$ac_compile" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_compile") 2>conftest.err >+ ac_status=$? >+ if test -s conftest.err; then >+ grep -v '^ *+' conftest.err >conftest.er1 >+ cat conftest.er1 >&5 >+ mv -f conftest.er1 conftest.err >+ fi >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } && { >+ test -z "$ac_c_werror_flag" || >+ test ! -s conftest.err >+ } && test -s conftest.$ac_objext; then : >+ ac_retval=0 >+else >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+ ac_retval=1 >+fi >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ as_fn_set_status $ac_retval >+ >+} @%:@ ac_fn_c_try_compile >+ >+@%:@ ac_fn_c_try_cpp LINENO >+@%:@ ---------------------- >+@%:@ Try to preprocess conftest.@S|@ac_ext, and return whether this succeeded. >+ac_fn_c_try_cpp () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ if { { ac_try="$ac_cpp conftest.$ac_ext" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err >+ ac_status=$? >+ if test -s conftest.err; then >+ grep -v '^ *+' conftest.err >conftest.er1 >+ cat conftest.er1 >&5 >+ mv -f conftest.er1 conftest.err >+ fi >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } > conftest.i && { >+ test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || >+ test ! -s conftest.err >+ }; then : >+ ac_retval=0 >+else >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+ ac_retval=1 >+fi >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ as_fn_set_status $ac_retval >+ >+} @%:@ ac_fn_c_try_cpp >+ >+@%:@ ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES >+@%:@ ------------------------------------------------------- >+@%:@ Tests whether HEADER exists, giving a warning if it cannot be compiled using >+@%:@ the include files in INCLUDES and setting the cache variable VAR >+@%:@ accordingly. >+ac_fn_c_check_header_mongrel () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ if eval \${$3+:} false; then : >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+else >+ # Is the header compilable? >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 >+$as_echo_n "checking $2 usability... " >&6; } >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+$4 >+@%:@include <$2> >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_header_compiler=yes >+else >+ ac_header_compiler=no >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 >+$as_echo "$ac_header_compiler" >&6; } >+ >+# Is the header present? >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 >+$as_echo_n "checking $2 presence... " >&6; } >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+@%:@include <$2> >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ ac_header_preproc=yes >+else >+ ac_header_preproc=no >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 >+$as_echo "$ac_header_preproc" >&6; } >+ >+# So? What about this header? >+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( >+ yes:no: ) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 >+$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 >+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} >+ ;; >+ no:yes:* ) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 >+$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 >+$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 >+$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 >+$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 >+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} >+( $as_echo "## --------------------------- ## >+## Report this to ris@ripe.net ## >+## --------------------------- ##" >+ ) | sed "s/^/$as_me: WARNING: /" >&2 >+ ;; >+esac >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ eval "$3=\$ac_header_compiler" >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+fi >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ >+} @%:@ ac_fn_c_check_header_mongrel >+ >+@%:@ ac_fn_c_try_run LINENO >+@%:@ ---------------------- >+@%:@ Try to link conftest.@S|@ac_ext, and return whether this succeeded. Assumes >+@%:@ that executables *can* be run. >+ac_fn_c_try_run () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ if { { ac_try="$ac_link" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' >+ { { case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_try") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; }; then : >+ ac_retval=0 >+else >+ $as_echo "$as_me: program exited with status $ac_status" >&5 >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+ ac_retval=$ac_status >+fi >+ rm -rf conftest.dSYM conftest_ipa8_conftest.oo >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ as_fn_set_status $ac_retval >+ >+} @%:@ ac_fn_c_try_run >+ >+@%:@ ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES >+@%:@ ------------------------------------------------------- >+@%:@ Tests whether HEADER exists and can be compiled using the include files in >+@%:@ INCLUDES, setting the cache variable VAR accordingly. >+ac_fn_c_check_header_compile () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+$4 >+@%:@include <$2> >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ eval "$3=yes" >+else >+ eval "$3=no" >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ >+} @%:@ ac_fn_c_check_header_compile >+ >+@%:@ ac_fn_c_check_type LINENO TYPE VAR INCLUDES >+@%:@ ------------------------------------------- >+@%:@ Tests whether TYPE exists after having included INCLUDES, setting cache >+@%:@ variable VAR accordingly. >+ac_fn_c_check_type () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ eval "$3=no" >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+$4 >+int >+main () >+{ >+if (sizeof ($2)) >+ return 0; >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+$4 >+int >+main () >+{ >+if (sizeof (($2))) >+ return 0; >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ >+else >+ eval "$3=yes" >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ >+} @%:@ ac_fn_c_check_type >+ >+@%:@ ac_fn_c_try_link LINENO >+@%:@ ----------------------- >+@%:@ Try to link conftest.@S|@ac_ext, and return whether this succeeded. >+ac_fn_c_try_link () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ rm -f conftest.$ac_objext conftest$ac_exeext >+ if { { ac_try="$ac_link" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link") 2>conftest.err >+ ac_status=$? >+ if test -s conftest.err; then >+ grep -v '^ *+' conftest.err >conftest.er1 >+ cat conftest.er1 >&5 >+ mv -f conftest.er1 conftest.err >+ fi >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } && { >+ test -z "$ac_c_werror_flag" || >+ test ! -s conftest.err >+ } && test -s conftest$ac_exeext && { >+ test "$cross_compiling" = yes || >+ test -x conftest$ac_exeext >+ }; then : >+ ac_retval=0 >+else >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+ ac_retval=1 >+fi >+ # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information >+ # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would >+ # interfere with the next link command; also delete a directory that is >+ # left behind by Apple's compiler. We do this before executing the actions. >+ rm -rf conftest.dSYM conftest_ipa8_conftest.oo >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ as_fn_set_status $ac_retval >+ >+} @%:@ ac_fn_c_try_link >+ >+@%:@ ac_fn_c_check_func LINENO FUNC VAR >+@%:@ ---------------------------------- >+@%:@ Tests whether FUNC exists, setting the cache variable VAR accordingly >+ac_fn_c_check_func () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+/* Define $2 to an innocuous variant, in case <limits.h> declares $2. >+ For example, HP-UX 11i <limits.h> declares gettimeofday. */ >+#define $2 innocuous_$2 >+ >+/* System header to define __stub macros and hopefully few prototypes, >+ which can conflict with char $2 (); below. >+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since >+ <limits.h> exists even on freestanding compilers. */ >+ >+#ifdef __STDC__ >+# include <limits.h> >+#else >+# include <assert.h> >+#endif >+ >+#undef $2 >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char $2 (); >+/* The GNU C library defines this for functions which it implements >+ to always fail with ENOSYS. Some functions are actually named >+ something starting with __ and the normal name is an alias. */ >+#if defined __stub_$2 || defined __stub___$2 >+choke me >+#endif >+ >+int >+main () >+{ >+return $2 (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ eval "$3=yes" >+else >+ eval "$3=no" >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ >+} @%:@ ac_fn_c_check_func >+cat >config.log <<_ACEOF >+This file contains any messages produced by compilers while >+running configure, to aid debugging if configure makes a mistake. >+ >+It was created by libbgpdump $as_me 1.4.99.15, which was >+generated by GNU Autoconf 2.69. Invocation command line was >+ >+ $ $0 $@ >+ >+_ACEOF >+exec 5>>config.log >+{ >+cat <<_ASUNAME >+## --------- ## >+## Platform. ## >+## --------- ## >+ >+hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` >+uname -m = `(uname -m) 2>/dev/null || echo unknown` >+uname -r = `(uname -r) 2>/dev/null || echo unknown` >+uname -s = `(uname -s) 2>/dev/null || echo unknown` >+uname -v = `(uname -v) 2>/dev/null || echo unknown` >+ >+/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` >+/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` >+ >+/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` >+/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` >+/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` >+/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` >+/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` >+/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` >+/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` >+ >+_ASUNAME >+ >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ $as_echo "PATH: $as_dir" >+ done >+IFS=$as_save_IFS >+ >+} >&5 >+ >+cat >&5 <<_ACEOF >+ >+ >+## ----------- ## >+## Core tests. ## >+## ----------- ## >+ >+_ACEOF >+ >+ >+# Keep a trace of the command line. >+# Strip out --no-create and --no-recursion so they do not pile up. >+# Strip out --silent because we don't want to record it for future runs. >+# Also quote any args containing shell meta-characters. >+# Make two passes to allow for proper duplicate-argument suppression. >+ac_configure_args= >+ac_configure_args0= >+ac_configure_args1= >+ac_must_keep_next=false >+for ac_pass in 1 2 >+do >+ for ac_arg >+ do >+ case $ac_arg in >+ -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; >+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \ >+ | -silent | --silent | --silen | --sile | --sil) >+ continue ;; >+ *\'*) >+ ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; >+ esac >+ case $ac_pass in >+ 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; >+ 2) >+ as_fn_append ac_configure_args1 " '$ac_arg'" >+ if test $ac_must_keep_next = true; then >+ ac_must_keep_next=false # Got value, back to normal. >+ else >+ case $ac_arg in >+ *=* | --config-cache | -C | -disable-* | --disable-* \ >+ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ >+ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ >+ | -with-* | --with-* | -without-* | --without-* | --x) >+ case "$ac_configure_args0 " in >+ "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; >+ esac >+ ;; >+ -* ) ac_must_keep_next=true ;; >+ esac >+ fi >+ as_fn_append ac_configure_args " '$ac_arg'" >+ ;; >+ esac >+ done >+done >+{ ac_configure_args0=; unset ac_configure_args0;} >+{ ac_configure_args1=; unset ac_configure_args1;} >+ >+# When interrupted or exit'd, cleanup temporary files, and complete >+# config.log. We remove comments because anyway the quotes in there >+# would cause problems or look ugly. >+# WARNING: Use '\'' to represent an apostrophe within the trap. >+# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. >+trap 'exit_status=$? >+ # Save into config.log some information that might help in debugging. >+ { >+ echo >+ >+ $as_echo "## ---------------- ## >+## Cache variables. ## >+## ---------------- ##" >+ echo >+ # The following way of writing the cache mishandles newlines in values, >+( >+ for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do >+ eval ac_val=\$$ac_var >+ case $ac_val in #( >+ *${as_nl}*) >+ case $ac_var in #( >+ *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 >+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; >+ esac >+ case $ac_var in #( >+ _ | IFS | as_nl) ;; #( >+ BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( >+ *) { eval $ac_var=; unset $ac_var;} ;; >+ esac ;; >+ esac >+ done >+ (set) 2>&1 | >+ case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( >+ *${as_nl}ac_space=\ *) >+ sed -n \ >+ "s/'\''/'\''\\\\'\'''\''/g; >+ s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" >+ ;; #( >+ *) >+ sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" >+ ;; >+ esac | >+ sort >+) >+ echo >+ >+ $as_echo "## ----------------- ## >+## Output variables. ## >+## ----------------- ##" >+ echo >+ for ac_var in $ac_subst_vars >+ do >+ eval ac_val=\$$ac_var >+ case $ac_val in >+ *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; >+ esac >+ $as_echo "$ac_var='\''$ac_val'\''" >+ done | sort >+ echo >+ >+ if test -n "$ac_subst_files"; then >+ $as_echo "## ------------------- ## >+## File substitutions. ## >+## ------------------- ##" >+ echo >+ for ac_var in $ac_subst_files >+ do >+ eval ac_val=\$$ac_var >+ case $ac_val in >+ *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; >+ esac >+ $as_echo "$ac_var='\''$ac_val'\''" >+ done | sort >+ echo >+ fi >+ >+ if test -s confdefs.h; then >+ $as_echo "## ----------- ## >+## confdefs.h. ## >+## ----------- ##" >+ echo >+ cat confdefs.h >+ echo >+ fi >+ test "$ac_signal" != 0 && >+ $as_echo "$as_me: caught signal $ac_signal" >+ $as_echo "$as_me: exit $exit_status" >+ } >&5 >+ rm -f core *.core core.conftest.* && >+ rm -f -r conftest* confdefs* conf$$* $ac_clean_files && >+ exit $exit_status >+' 0 >+for ac_signal in 1 2 13 15; do >+ trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal >+done >+ac_signal=0 >+ >+# confdefs.h avoids OS command line length limits that DEFS can exceed. >+rm -f -r conftest* confdefs.h >+ >+$as_echo "/* confdefs.h */" > confdefs.h >+ >+# Predefined preprocessor variables. >+ >+cat >>confdefs.h <<_ACEOF >+@%:@define PACKAGE_NAME "$PACKAGE_NAME" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+@%:@define PACKAGE_TARNAME "$PACKAGE_TARNAME" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+@%:@define PACKAGE_VERSION "$PACKAGE_VERSION" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+@%:@define PACKAGE_STRING "$PACKAGE_STRING" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+@%:@define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+@%:@define PACKAGE_URL "$PACKAGE_URL" >+_ACEOF >+ >+ >+# Let the site file select an alternate cache file if it wants to. >+# Prefer an explicitly selected file to automatically selected ones. >+ac_site_file1=NONE >+ac_site_file2=NONE >+if test -n "$CONFIG_SITE"; then >+ # We do not want a PATH search for config.site. >+ case $CONFIG_SITE in @%:@(( >+ -*) ac_site_file1=./$CONFIG_SITE;; >+ */*) ac_site_file1=$CONFIG_SITE;; >+ *) ac_site_file1=./$CONFIG_SITE;; >+ esac >+elif test "x$prefix" != xNONE; then >+ ac_site_file1=$prefix/share/config.site >+ ac_site_file2=$prefix/etc/config.site >+else >+ ac_site_file1=$ac_default_prefix/share/config.site >+ ac_site_file2=$ac_default_prefix/etc/config.site >+fi >+for ac_site_file in "$ac_site_file1" "$ac_site_file2" >+do >+ test "x$ac_site_file" = xNONE && continue >+ if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 >+$as_echo "$as_me: loading site script $ac_site_file" >&6;} >+ sed 's/^/| /' "$ac_site_file" >&5 >+ . "$ac_site_file" \ >+ || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "failed to load site script $ac_site_file >+See \`config.log' for more details" "$LINENO" 5; } >+ fi >+done >+ >+if test -r "$cache_file"; then >+ # Some versions of bash will fail to source /dev/null (special files >+ # actually), so we avoid doing that. DJGPP emulates it as a regular file. >+ if test /dev/null != "$cache_file" && test -f "$cache_file"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 >+$as_echo "$as_me: loading cache $cache_file" >&6;} >+ case $cache_file in >+ [\\/]* | ?:[\\/]* ) . "$cache_file";; >+ *) . "./$cache_file";; >+ esac >+ fi >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 >+$as_echo "$as_me: creating cache $cache_file" >&6;} >+ >$cache_file >+fi >+ >+# Check that the precious variables saved in the cache have kept the same >+# value. >+ac_cache_corrupted=false >+for ac_var in $ac_precious_vars; do >+ eval ac_old_set=\$ac_cv_env_${ac_var}_set >+ eval ac_new_set=\$ac_env_${ac_var}_set >+ eval ac_old_val=\$ac_cv_env_${ac_var}_value >+ eval ac_new_val=\$ac_env_${ac_var}_value >+ case $ac_old_set,$ac_new_set in >+ set,) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 >+$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} >+ ac_cache_corrupted=: ;; >+ ,set) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 >+$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} >+ ac_cache_corrupted=: ;; >+ ,);; >+ *) >+ if test "x$ac_old_val" != "x$ac_new_val"; then >+ # differences in whitespace do not lead to failure. >+ ac_old_val_w=`echo x $ac_old_val` >+ ac_new_val_w=`echo x $ac_new_val` >+ if test "$ac_old_val_w" != "$ac_new_val_w"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 >+$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} >+ ac_cache_corrupted=: >+ else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 >+$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} >+ eval $ac_var=\$ac_old_val >+ fi >+ { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 >+$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 >+$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} >+ fi;; >+ esac >+ # Pass precious variables to config.status. >+ if test "$ac_new_set" = set; then >+ case $ac_new_val in >+ *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; >+ *) ac_arg=$ac_var=$ac_new_val ;; >+ esac >+ case " $ac_configure_args " in >+ *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. >+ *) as_fn_append ac_configure_args " '$ac_arg'" ;; >+ esac >+ fi >+done >+if $ac_cache_corrupted; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 >+$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} >+ as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 >+fi >+## -------------------- ## >+## Main body of script. ## >+## -------------------- ## >+ >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+ >+ >+ >+ac_config_headers="$ac_config_headers bgpdump-config.h" >+ >+ >+CFLAGS="-g -O3 $CFLAGS -Wall" >+CFLAGS="$CFLAGS -Wsystem-headers -Wno-format-y2k -Wno-sign-compare -Wcast-align" >+CFLAGS="$CFLAGS -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wswitch -Wshadow" >+ >+# Checks for programs. >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+if test -n "$ac_tool_prefix"; then >+ # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. >+set dummy ${ac_tool_prefix}gcc; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$CC"; then >+ ac_cv_prog_CC="$CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_CC="${ac_tool_prefix}gcc" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+CC=$ac_cv_prog_CC >+if test -n "$CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 >+$as_echo "$CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+fi >+if test -z "$ac_cv_prog_CC"; then >+ ac_ct_CC=$CC >+ # Extract the first word of "gcc", so it can be a program name with args. >+set dummy gcc; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_ac_ct_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$ac_ct_CC"; then >+ ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_ac_ct_CC="gcc" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+ac_ct_CC=$ac_cv_prog_ac_ct_CC >+if test -n "$ac_ct_CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 >+$as_echo "$ac_ct_CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ if test "x$ac_ct_CC" = x; then >+ CC="" >+ else >+ case $cross_compiling:$ac_tool_warned in >+yes:) >+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 >+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} >+ac_tool_warned=yes ;; >+esac >+ CC=$ac_ct_CC >+ fi >+else >+ CC="$ac_cv_prog_CC" >+fi >+ >+if test -z "$CC"; then >+ if test -n "$ac_tool_prefix"; then >+ # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. >+set dummy ${ac_tool_prefix}cc; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$CC"; then >+ ac_cv_prog_CC="$CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_CC="${ac_tool_prefix}cc" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+CC=$ac_cv_prog_CC >+if test -n "$CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 >+$as_echo "$CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+ fi >+fi >+if test -z "$CC"; then >+ # Extract the first word of "cc", so it can be a program name with args. >+set dummy cc; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$CC"; then >+ ac_cv_prog_CC="$CC" # Let the user override the test. >+else >+ ac_prog_rejected=no >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then >+ ac_prog_rejected=yes >+ continue >+ fi >+ ac_cv_prog_CC="cc" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+if test $ac_prog_rejected = yes; then >+ # We found a bogon in the path, so make sure we never use it. >+ set dummy $ac_cv_prog_CC >+ shift >+ if test $@%:@ != 0; then >+ # We chose a different compiler from the bogus one. >+ # However, it has the same basename, so the bogon will be chosen >+ # first if we set CC to just the basename; use the full file name. >+ shift >+ ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" >+ fi >+fi >+fi >+fi >+CC=$ac_cv_prog_CC >+if test -n "$CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 >+$as_echo "$CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+fi >+if test -z "$CC"; then >+ if test -n "$ac_tool_prefix"; then >+ for ac_prog in cl.exe >+ do >+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. >+set dummy $ac_tool_prefix$ac_prog; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$CC"; then >+ ac_cv_prog_CC="$CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_CC="$ac_tool_prefix$ac_prog" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+CC=$ac_cv_prog_CC >+if test -n "$CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 >+$as_echo "$CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+ test -n "$CC" && break >+ done >+fi >+if test -z "$CC"; then >+ ac_ct_CC=$CC >+ for ac_prog in cl.exe >+do >+ # Extract the first word of "$ac_prog", so it can be a program name with args. >+set dummy $ac_prog; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_ac_ct_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$ac_ct_CC"; then >+ ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_ac_ct_CC="$ac_prog" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+ac_ct_CC=$ac_cv_prog_ac_ct_CC >+if test -n "$ac_ct_CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 >+$as_echo "$ac_ct_CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+ test -n "$ac_ct_CC" && break >+done >+ >+ if test "x$ac_ct_CC" = x; then >+ CC="" >+ else >+ case $cross_compiling:$ac_tool_warned in >+yes:) >+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 >+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} >+ac_tool_warned=yes ;; >+esac >+ CC=$ac_ct_CC >+ fi >+fi >+ >+fi >+ >+ >+test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "no acceptable C compiler found in \$PATH >+See \`config.log' for more details" "$LINENO" 5; } >+ >+# Provide some information about the compiler. >+$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 >+set X $ac_compile >+ac_compiler=$2 >+for ac_option in --version -v -V -qversion; do >+ { { ac_try="$ac_compiler $ac_option >&5" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_compiler $ac_option >&5") 2>conftest.err >+ ac_status=$? >+ if test -s conftest.err; then >+ sed '10a\ >+... rest of stderr output deleted ... >+ 10q' conftest.err >conftest.er1 >+ cat conftest.er1 >&5 >+ fi >+ rm -f conftest.er1 conftest.err >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } >+done >+ >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+ac_clean_files_save=$ac_clean_files >+ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" >+# Try to create an executable without -o first, disregard a.out. >+# It will help us diagnose broken compilers, and finding out an intuition >+# of exeext. >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 >+$as_echo_n "checking whether the C compiler works... " >&6; } >+ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` >+ >+# The possible output files: >+ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" >+ >+ac_rmfiles= >+for ac_file in $ac_files >+do >+ case $ac_file in >+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; >+ * ) ac_rmfiles="$ac_rmfiles $ac_file";; >+ esac >+done >+rm -f $ac_rmfiles >+ >+if { { ac_try="$ac_link_default" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link_default") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; then : >+ # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. >+# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' >+# in a Makefile. We should not override ac_cv_exeext if it was cached, >+# so that the user can short-circuit this test for compilers unknown to >+# Autoconf. >+for ac_file in $ac_files '' >+do >+ test -f "$ac_file" || continue >+ case $ac_file in >+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) >+ ;; >+ [ab].out ) >+ # We found the default executable, but exeext='' is most >+ # certainly right. >+ break;; >+ *.* ) >+ if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; >+ then :; else >+ ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` >+ fi >+ # We set ac_cv_exeext here because the later test for it is not >+ # safe: cross compilers may not add the suffix if given an `-o' >+ # argument, so we may need to know it at that point already. >+ # Even if this section looks crufty: it has the advantage of >+ # actually working. >+ break;; >+ * ) >+ break;; >+ esac >+done >+test "$ac_cv_exeext" = no && ac_cv_exeext= >+ >+else >+ ac_file='' >+fi >+if test -z "$ac_file"; then : >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+$as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error 77 "C compiler cannot create executables >+See \`config.log' for more details" "$LINENO" 5; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 >+$as_echo "yes" >&6; } >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 >+$as_echo_n "checking for C compiler default output file name... " >&6; } >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 >+$as_echo "$ac_file" >&6; } >+ac_exeext=$ac_cv_exeext >+ >+rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out >+ac_clean_files=$ac_clean_files_save >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 >+$as_echo_n "checking for suffix of executables... " >&6; } >+if { { ac_try="$ac_link" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; then : >+ # If both `conftest.exe' and `conftest' are `present' (well, observable) >+# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will >+# work properly (i.e., refer to `conftest.exe'), while it won't with >+# `rm'. >+for ac_file in conftest.exe conftest conftest.*; do >+ test -f "$ac_file" || continue >+ case $ac_file in >+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; >+ *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` >+ break;; >+ * ) break;; >+ esac >+done >+else >+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "cannot compute suffix of executables: cannot compile and link >+See \`config.log' for more details" "$LINENO" 5; } >+fi >+rm -f conftest conftest$ac_cv_exeext >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 >+$as_echo "$ac_cv_exeext" >&6; } >+ >+rm -f conftest.$ac_ext >+EXEEXT=$ac_cv_exeext >+ac_exeext=$EXEEXT >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+@%:@include <stdio.h> >+int >+main () >+{ >+FILE *f = fopen ("conftest.out", "w"); >+ return ferror (f) || fclose (f) != 0; >+ >+ ; >+ return 0; >+} >+_ACEOF >+ac_clean_files="$ac_clean_files conftest.out" >+# Check that the compiler produces executables we can run. If not, either >+# the compiler is broken, or we cross compile. >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 >+$as_echo_n "checking whether we are cross compiling... " >&6; } >+if test "$cross_compiling" != yes; then >+ { { ac_try="$ac_link" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } >+ if { ac_try='./conftest$ac_cv_exeext' >+ { { case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_try") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; }; then >+ cross_compiling=no >+ else >+ if test "$cross_compiling" = maybe; then >+ cross_compiling=yes >+ else >+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "cannot run C compiled programs. >+If you meant to cross compile, use \`--host'. >+See \`config.log' for more details" "$LINENO" 5; } >+ fi >+ fi >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 >+$as_echo "$cross_compiling" >&6; } >+ >+rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out >+ac_clean_files=$ac_clean_files_save >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 >+$as_echo_n "checking for suffix of object files... " >&6; } >+if ${ac_cv_objext+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+rm -f conftest.o conftest.obj >+if { { ac_try="$ac_compile" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_compile") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; then : >+ for ac_file in conftest.o conftest.obj conftest.*; do >+ test -f "$ac_file" || continue; >+ case $ac_file in >+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; >+ *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` >+ break;; >+ esac >+done >+else >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "cannot compute suffix of object files: cannot compile >+See \`config.log' for more details" "$LINENO" 5; } >+fi >+rm -f conftest.$ac_cv_objext conftest.$ac_ext >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 >+$as_echo "$ac_cv_objext" >&6; } >+OBJEXT=$ac_cv_objext >+ac_objext=$OBJEXT >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 >+$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } >+if ${ac_cv_c_compiler_gnu+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+#ifndef __GNUC__ >+ choke me >+#endif >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_compiler_gnu=yes >+else >+ ac_compiler_gnu=no >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+ac_cv_c_compiler_gnu=$ac_compiler_gnu >+ >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 >+$as_echo "$ac_cv_c_compiler_gnu" >&6; } >+if test $ac_compiler_gnu = yes; then >+ GCC=yes >+else >+ GCC= >+fi >+ac_test_CFLAGS=${CFLAGS+set} >+ac_save_CFLAGS=$CFLAGS >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 >+$as_echo_n "checking whether $CC accepts -g... " >&6; } >+if ${ac_cv_prog_cc_g+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_save_c_werror_flag=$ac_c_werror_flag >+ ac_c_werror_flag=yes >+ ac_cv_prog_cc_g=no >+ CFLAGS="-g" >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_prog_cc_g=yes >+else >+ CFLAGS="" >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ >+else >+ ac_c_werror_flag=$ac_save_c_werror_flag >+ CFLAGS="-g" >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_prog_cc_g=yes >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+ ac_c_werror_flag=$ac_save_c_werror_flag >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 >+$as_echo "$ac_cv_prog_cc_g" >&6; } >+if test "$ac_test_CFLAGS" = set; then >+ CFLAGS=$ac_save_CFLAGS >+elif test $ac_cv_prog_cc_g = yes; then >+ if test "$GCC" = yes; then >+ CFLAGS="-g -O2" >+ else >+ CFLAGS="-g" >+ fi >+else >+ if test "$GCC" = yes; then >+ CFLAGS="-O2" >+ else >+ CFLAGS= >+ fi >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 >+$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } >+if ${ac_cv_prog_cc_c89+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_cv_prog_cc_c89=no >+ac_save_CC=$CC >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <stdarg.h> >+#include <stdio.h> >+struct stat; >+/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ >+struct buf { int x; }; >+FILE * (*rcsopen) (struct buf *, struct stat *, int); >+static char *e (p, i) >+ char **p; >+ int i; >+{ >+ return p[i]; >+} >+static char *f (char * (*g) (char **, int), char **p, ...) >+{ >+ char *s; >+ va_list v; >+ va_start (v,p); >+ s = g (p, va_arg (v,int)); >+ va_end (v); >+ return s; >+} >+ >+/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has >+ function prototypes and stuff, but not '\xHH' hex character constants. >+ These don't provoke an error unfortunately, instead are silently treated >+ as 'x'. The following induces an error, until -std is added to get >+ proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an >+ array size at least. It's necessary to write '\x00'==0 to get something >+ that's true only with -std. */ >+int osf4_cc_array ['\x00' == 0 ? 1 : -1]; >+ >+/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters >+ inside strings and character constants. */ >+#define FOO(x) 'x' >+int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; >+ >+int test (int i, double x); >+struct s1 {int (*f) (int a);}; >+struct s2 {int (*f) (double a);}; >+int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); >+int argc; >+char **argv; >+int >+main () >+{ >+return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; >+ ; >+ return 0; >+} >+_ACEOF >+for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ >+ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" >+do >+ CC="$ac_save_CC $ac_arg" >+ if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_prog_cc_c89=$ac_arg >+fi >+rm -f core conftest.err conftest.$ac_objext >+ test "x$ac_cv_prog_cc_c89" != "xno" && break >+done >+rm -f conftest.$ac_ext >+CC=$ac_save_CC >+ >+fi >+# AC_CACHE_VAL >+case "x$ac_cv_prog_cc_c89" in >+ x) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 >+$as_echo "none needed" >&6; } ;; >+ xno) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 >+$as_echo "unsupported" >&6; } ;; >+ *) >+ CC="$CC $ac_cv_prog_cc_c89" >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 >+$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; >+esac >+if test "x$ac_cv_prog_cc_c89" != xno; then : >+ >+fi >+ >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+ >+if test -n "$ac_tool_prefix"; then >+ # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. >+set dummy ${ac_tool_prefix}ranlib; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_RANLIB+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$RANLIB"; then >+ ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+RANLIB=$ac_cv_prog_RANLIB >+if test -n "$RANLIB"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 >+$as_echo "$RANLIB" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+fi >+if test -z "$ac_cv_prog_RANLIB"; then >+ ac_ct_RANLIB=$RANLIB >+ # Extract the first word of "ranlib", so it can be a program name with args. >+set dummy ranlib; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$ac_ct_RANLIB"; then >+ ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_ac_ct_RANLIB="ranlib" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB >+if test -n "$ac_ct_RANLIB"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 >+$as_echo "$ac_ct_RANLIB" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ if test "x$ac_ct_RANLIB" = x; then >+ RANLIB=":" >+ else >+ case $cross_compiling:$ac_tool_warned in >+yes:) >+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 >+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} >+ac_tool_warned=yes ;; >+esac >+ RANLIB=$ac_ct_RANLIB >+ fi >+else >+ RANLIB="$ac_cv_prog_RANLIB" >+fi >+ >+ >+# Checks for header files. >+ >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 >+$as_echo_n "checking how to run the C preprocessor... " >&6; } >+# On Suns, sometimes $CPP names a directory. >+if test -n "$CPP" && test -d "$CPP"; then >+ CPP= >+fi >+if test -z "$CPP"; then >+ if ${ac_cv_prog_CPP+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ # Double quotes because CPP needs to be expanded >+ for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" >+ do >+ ac_preproc_ok=false >+for ac_c_preproc_warn_flag in '' yes >+do >+ # Use a header file that comes with gcc, so configuring glibc >+ # with a fresh cross-compiler works. >+ # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since >+ # <limits.h> exists even on freestanding compilers. >+ # On the NeXT, cc -E runs the code through the compiler's parser, >+ # not just through cpp. "Syntax error" is here to catch this case. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+@%:@ifdef __STDC__ >+@%:@ include <limits.h> >+@%:@else >+@%:@ include <assert.h> >+@%:@endif >+ Syntax error >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ >+else >+ # Broken: fails on valid input. >+continue >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+ >+ # OK, works on sane cases. Now check whether nonexistent headers >+ # can be detected and how. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+@%:@include <ac_nonexistent.h> >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ # Broken: success on invalid input. >+continue >+else >+ # Passes both tests. >+ac_preproc_ok=: >+break >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+ >+done >+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. >+rm -f conftest.i conftest.err conftest.$ac_ext >+if $ac_preproc_ok; then : >+ break >+fi >+ >+ done >+ ac_cv_prog_CPP=$CPP >+ >+fi >+ CPP=$ac_cv_prog_CPP >+else >+ ac_cv_prog_CPP=$CPP >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 >+$as_echo "$CPP" >&6; } >+ac_preproc_ok=false >+for ac_c_preproc_warn_flag in '' yes >+do >+ # Use a header file that comes with gcc, so configuring glibc >+ # with a fresh cross-compiler works. >+ # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since >+ # <limits.h> exists even on freestanding compilers. >+ # On the NeXT, cc -E runs the code through the compiler's parser, >+ # not just through cpp. "Syntax error" is here to catch this case. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+@%:@ifdef __STDC__ >+@%:@ include <limits.h> >+@%:@else >+@%:@ include <assert.h> >+@%:@endif >+ Syntax error >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ >+else >+ # Broken: fails on valid input. >+continue >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+ >+ # OK, works on sane cases. Now check whether nonexistent headers >+ # can be detected and how. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+@%:@include <ac_nonexistent.h> >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ # Broken: success on invalid input. >+continue >+else >+ # Passes both tests. >+ac_preproc_ok=: >+break >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+ >+done >+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. >+rm -f conftest.i conftest.err conftest.$ac_ext >+if $ac_preproc_ok; then : >+ >+else >+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "C preprocessor \"$CPP\" fails sanity check >+See \`config.log' for more details" "$LINENO" 5; } >+fi >+ >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+ >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 >+$as_echo_n "checking for grep that handles long lines and -e... " >&6; } >+if ${ac_cv_path_GREP+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -z "$GREP"; then >+ ac_path_GREP_found=false >+ # Loop through the user's path and test for each of PROGNAME-LIST >+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_prog in grep ggrep; do >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" >+ as_fn_executable_p "$ac_path_GREP" || continue >+# Check for GNU ac_path_GREP and select it if it is found. >+ # Check for GNU $ac_path_GREP >+case `"$ac_path_GREP" --version 2>&1` in >+*GNU*) >+ ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; >+*) >+ ac_count=0 >+ $as_echo_n 0123456789 >"conftest.in" >+ while : >+ do >+ cat "conftest.in" "conftest.in" >"conftest.tmp" >+ mv "conftest.tmp" "conftest.in" >+ cp "conftest.in" "conftest.nl" >+ $as_echo 'GREP' >> "conftest.nl" >+ "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break >+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break >+ as_fn_arith $ac_count + 1 && ac_count=$as_val >+ if test $ac_count -gt ${ac_path_GREP_max-0}; then >+ # Best one so far, save it but keep looking for a better one >+ ac_cv_path_GREP="$ac_path_GREP" >+ ac_path_GREP_max=$ac_count >+ fi >+ # 10*(2^10) chars as input seems more than enough >+ test $ac_count -gt 10 && break >+ done >+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;; >+esac >+ >+ $ac_path_GREP_found && break 3 >+ done >+ done >+ done >+IFS=$as_save_IFS >+ if test -z "$ac_cv_path_GREP"; then >+ as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 >+ fi >+else >+ ac_cv_path_GREP=$GREP >+fi >+ >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 >+$as_echo "$ac_cv_path_GREP" >&6; } >+ GREP="$ac_cv_path_GREP" >+ >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 >+$as_echo_n "checking for egrep... " >&6; } >+if ${ac_cv_path_EGREP+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 >+ then ac_cv_path_EGREP="$GREP -E" >+ else >+ if test -z "$EGREP"; then >+ ac_path_EGREP_found=false >+ # Loop through the user's path and test for each of PROGNAME-LIST >+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_prog in egrep; do >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" >+ as_fn_executable_p "$ac_path_EGREP" || continue >+# Check for GNU ac_path_EGREP and select it if it is found. >+ # Check for GNU $ac_path_EGREP >+case `"$ac_path_EGREP" --version 2>&1` in >+*GNU*) >+ ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; >+*) >+ ac_count=0 >+ $as_echo_n 0123456789 >"conftest.in" >+ while : >+ do >+ cat "conftest.in" "conftest.in" >"conftest.tmp" >+ mv "conftest.tmp" "conftest.in" >+ cp "conftest.in" "conftest.nl" >+ $as_echo 'EGREP' >> "conftest.nl" >+ "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break >+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break >+ as_fn_arith $ac_count + 1 && ac_count=$as_val >+ if test $ac_count -gt ${ac_path_EGREP_max-0}; then >+ # Best one so far, save it but keep looking for a better one >+ ac_cv_path_EGREP="$ac_path_EGREP" >+ ac_path_EGREP_max=$ac_count >+ fi >+ # 10*(2^10) chars as input seems more than enough >+ test $ac_count -gt 10 && break >+ done >+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;; >+esac >+ >+ $ac_path_EGREP_found && break 3 >+ done >+ done >+ done >+IFS=$as_save_IFS >+ if test -z "$ac_cv_path_EGREP"; then >+ as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 >+ fi >+else >+ ac_cv_path_EGREP=$EGREP >+fi >+ >+ fi >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 >+$as_echo "$ac_cv_path_EGREP" >&6; } >+ EGREP="$ac_cv_path_EGREP" >+ >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 >+$as_echo_n "checking for ANSI C header files... " >&6; } >+if ${ac_cv_header_stdc+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <stdlib.h> >+#include <stdarg.h> >+#include <string.h> >+#include <float.h> >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_header_stdc=yes >+else >+ ac_cv_header_stdc=no >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+ >+if test $ac_cv_header_stdc = yes; then >+ # SunOS 4.x string.h does not declare mem*, contrary to ANSI. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <string.h> >+ >+_ACEOF >+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | >+ $EGREP "memchr" >/dev/null 2>&1; then : >+ >+else >+ ac_cv_header_stdc=no >+fi >+rm -f conftest* >+ >+fi >+ >+if test $ac_cv_header_stdc = yes; then >+ # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <stdlib.h> >+ >+_ACEOF >+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | >+ $EGREP "free" >/dev/null 2>&1; then : >+ >+else >+ ac_cv_header_stdc=no >+fi >+rm -f conftest* >+ >+fi >+ >+if test $ac_cv_header_stdc = yes; then >+ # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. >+ if test "$cross_compiling" = yes; then : >+ : >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <ctype.h> >+#include <stdlib.h> >+#if ((' ' & 0x0FF) == 0x020) >+# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') >+# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) >+#else >+# define ISLOWER(c) \ >+ (('a' <= (c) && (c) <= 'i') \ >+ || ('j' <= (c) && (c) <= 'r') \ >+ || ('s' <= (c) && (c) <= 'z')) >+# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) >+#endif >+ >+#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) >+int >+main () >+{ >+ int i; >+ for (i = 0; i < 256; i++) >+ if (XOR (islower (i), ISLOWER (i)) >+ || toupper (i) != TOUPPER (i)) >+ return 2; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_run "$LINENO"; then : >+ >+else >+ ac_cv_header_stdc=no >+fi >+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ >+ conftest.$ac_objext conftest.beam conftest.$ac_ext >+fi >+ >+fi >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 >+$as_echo "$ac_cv_header_stdc" >&6; } >+if test $ac_cv_header_stdc = yes; then >+ >+$as_echo "@%:@define STDC_HEADERS 1" >>confdefs.h >+ >+fi >+ >+# On IRIX 5.3, sys/types and inttypes.h are conflicting. >+for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ >+ inttypes.h stdint.h unistd.h >+do : >+ as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` >+ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default >+" >+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : >+ cat >>confdefs.h <<_ACEOF >+@%:@define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 >+_ACEOF >+ >+fi >+ >+done >+ >+ >+for ac_header in arpa/inet.h netinet/in.h syslog.h >+do : >+ as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` >+ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" >+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : >+ cat >>confdefs.h <<_ACEOF >+@%:@define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 >+_ACEOF >+ >+fi >+ >+done >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 >+$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } >+if ${ac_cv_struct_tm+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <sys/types.h> >+#include <time.h> >+ >+int >+main () >+{ >+struct tm tm; >+ int *p = &tm.tm_sec; >+ return !p; >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_struct_tm=time.h >+else >+ ac_cv_struct_tm=sys/time.h >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 >+$as_echo "$ac_cv_struct_tm" >&6; } >+if test $ac_cv_struct_tm = sys/time.h; then >+ >+$as_echo "@%:@define TM_IN_SYS_TIME 1" >>confdefs.h >+ >+fi >+ >+ >+# Check for u_*_t >+ac_fn_c_check_type "$LINENO" "u_char_t" "ac_cv_type_u_char_t" "$ac_includes_default" >+if test "x$ac_cv_type_u_char_t" = xyes; then : >+ >+else >+ >+$as_echo "@%:@define u_char_t uchar_t" >>confdefs.h >+ >+fi >+ >+ac_fn_c_check_type "$LINENO" "u_int8_t" "ac_cv_type_u_int8_t" "$ac_includes_default" >+if test "x$ac_cv_type_u_int8_t" = xyes; then : >+ >+else >+ >+$as_echo "@%:@define u_int8_t uint8_t" >>confdefs.h >+ >+fi >+ >+ac_fn_c_check_type "$LINENO" "u_int16_t" "ac_cv_type_u_int16_t" "$ac_includes_default" >+if test "x$ac_cv_type_u_int16_t" = xyes; then : >+ >+else >+ >+$as_echo "@%:@define u_int16_t uint16_t" >>confdefs.h >+ >+fi >+ >+ac_fn_c_check_type "$LINENO" "u_int32_t" "ac_cv_type_u_int32_t" "$ac_includes_default" >+if test "x$ac_cv_type_u_int32_t" = xyes; then : >+ >+else >+ >+$as_echo "@%:@define u_int32_t uint32_t" >>confdefs.h >+ >+fi >+ >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gzopen in -lz" >&5 >+$as_echo_n "checking for gzopen in -lz... " >&6; } >+if ${ac_cv_lib_z_gzopen+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_check_lib_save_LIBS=$LIBS >+LIBS="-lz $LIBS" >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char gzopen (); >+int >+main () >+{ >+return gzopen (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ ac_cv_lib_z_gzopen=yes >+else >+ ac_cv_lib_z_gzopen=no >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+LIBS=$ac_check_lib_save_LIBS >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_gzopen" >&5 >+$as_echo "$ac_cv_lib_z_gzopen" >&6; } >+if test "x$ac_cv_lib_z_gzopen" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+@%:@define HAVE_LIBZ 1 >+_ACEOF >+ >+ LIBS="-lz $LIBS" >+ >+else >+ >+$as_echo "@%:@define DONT_HAVE_GZ 1" >>confdefs.h >+ >+fi >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BZ2_bzReadOpen in -lbz2" >&5 >+$as_echo_n "checking for BZ2_bzReadOpen in -lbz2... " >&6; } >+if ${ac_cv_lib_bz2_BZ2_bzReadOpen+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_check_lib_save_LIBS=$LIBS >+LIBS="-lbz2 $LIBS" >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char BZ2_bzReadOpen (); >+int >+main () >+{ >+return BZ2_bzReadOpen (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ ac_cv_lib_bz2_BZ2_bzReadOpen=yes >+else >+ ac_cv_lib_bz2_BZ2_bzReadOpen=no >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+LIBS=$ac_check_lib_save_LIBS >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bz2_BZ2_bzReadOpen" >&5 >+$as_echo "$ac_cv_lib_bz2_BZ2_bzReadOpen" >&6; } >+if test "x$ac_cv_lib_bz2_BZ2_bzReadOpen" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+@%:@define HAVE_LIBBZ2 1 >+_ACEOF >+ >+ LIBS="-lbz2 $LIBS" >+ >+else >+ >+$as_echo "@%:@define DONT_HAVE_BZ2 1" >>confdefs.h >+ >+fi >+ >+ >+# Check for inet_ntoa in -lnsl if not found (Solaris) >+for ac_func in inet_ntoa >+do : >+ ac_fn_c_check_func "$LINENO" "inet_ntoa" "ac_cv_func_inet_ntoa" >+if test "x$ac_cv_func_inet_ntoa" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+@%:@define HAVE_INET_NTOA 1 >+_ACEOF >+ >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_ntoa in -lnsl" >&5 >+$as_echo_n "checking for inet_ntoa in -lnsl... " >&6; } >+if ${ac_cv_lib_nsl_inet_ntoa+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_check_lib_save_LIBS=$LIBS >+LIBS="-lnsl $LIBS" >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char inet_ntoa (); >+int >+main () >+{ >+return inet_ntoa (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ ac_cv_lib_nsl_inet_ntoa=yes >+else >+ ac_cv_lib_nsl_inet_ntoa=no >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+LIBS=$ac_check_lib_save_LIBS >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_inet_ntoa" >&5 >+$as_echo "$ac_cv_lib_nsl_inet_ntoa" >&6; } >+if test "x$ac_cv_lib_nsl_inet_ntoa" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+@%:@define HAVE_LIBNSL 1 >+_ACEOF >+ >+ LIBS="-lnsl $LIBS" >+ >+else >+ as_fn_error 1 "inet_ntoa not found" "$LINENO" 5 >+fi >+ >+fi >+done >+ >+for ac_func in inet_ntop >+do : >+ ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" >+if test "x$ac_cv_func_inet_ntop" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+@%:@define HAVE_INET_NTOP 1 >+_ACEOF >+ >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_ntop in -lnsl" >&5 >+$as_echo_n "checking for inet_ntop in -lnsl... " >&6; } >+if ${ac_cv_lib_nsl_inet_ntop+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_check_lib_save_LIBS=$LIBS >+LIBS="-lnsl $LIBS" >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char inet_ntop (); >+int >+main () >+{ >+return inet_ntop (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ ac_cv_lib_nsl_inet_ntop=yes >+else >+ ac_cv_lib_nsl_inet_ntop=no >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+LIBS=$ac_check_lib_save_LIBS >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_inet_ntop" >&5 >+$as_echo "$ac_cv_lib_nsl_inet_ntop" >&6; } >+if test "x$ac_cv_lib_nsl_inet_ntop" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+@%:@define HAVE_LIBNSL 1 >+_ACEOF >+ >+ LIBS="-lnsl $LIBS" >+ >+else >+ as_fn_error 1 "inet_ntop not found" "$LINENO" 5 >+fi >+ >+fi >+done >+ >+ >+case `uname` in >+ Darwin*) LDFLAGS="$LDFLAGS -dynamiclib" ;; >+ *) LDFLAGS="$LDFLAGS -shared" ;; >+esac >+ >+ >+ >+ >+ac_config_files="$ac_config_files bgpdump.spec Makefile" >+ >+cat >confcache <<\_ACEOF >+# This file is a shell script that caches the results of configure >+# tests run on this system so they can be shared between configure >+# scripts and configure runs, see configure's option --config-cache. >+# It is not useful on other systems. If it contains results you don't >+# want to keep, you may remove or edit it. >+# >+# config.status only pays attention to the cache file if you give it >+# the --recheck option to rerun configure. >+# >+# `ac_cv_env_foo' variables (set or unset) will be overridden when >+# loading this file, other *unset* `ac_cv_foo' will be assigned the >+# following values. >+ >+_ACEOF >+ >+# The following way of writing the cache mishandles newlines in values, >+# but we know of no workaround that is simple, portable, and efficient. >+# So, we kill variables containing newlines. >+# Ultrix sh set writes to stderr and can't be redirected directly, >+# and sets the high bit in the cache file unless we assign to the vars. >+( >+ for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do >+ eval ac_val=\$$ac_var >+ case $ac_val in #( >+ *${as_nl}*) >+ case $ac_var in #( >+ *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 >+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; >+ esac >+ case $ac_var in #( >+ _ | IFS | as_nl) ;; #( >+ BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( >+ *) { eval $ac_var=; unset $ac_var;} ;; >+ esac ;; >+ esac >+ done >+ >+ (set) 2>&1 | >+ case $as_nl`(ac_space=' '; set) 2>&1` in #( >+ *${as_nl}ac_space=\ *) >+ # `set' does not quote correctly, so add quotes: double-quote >+ # substitution turns \\\\ into \\, and sed turns \\ into \. >+ sed -n \ >+ "s/'/'\\\\''/g; >+ s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" >+ ;; #( >+ *) >+ # `set' quotes correctly as required by POSIX, so do not add quotes. >+ sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" >+ ;; >+ esac | >+ sort >+) | >+ sed ' >+ /^ac_cv_env_/b end >+ t clear >+ :clear >+ s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ >+ t end >+ s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ >+ :end' >>confcache >+if diff "$cache_file" confcache >/dev/null 2>&1; then :; else >+ if test -w "$cache_file"; then >+ if test "x$cache_file" != "x/dev/null"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 >+$as_echo "$as_me: updating cache $cache_file" >&6;} >+ if test ! -f "$cache_file" || test -h "$cache_file"; then >+ cat confcache >"$cache_file" >+ else >+ case $cache_file in #( >+ */* | ?:*) >+ mv -f confcache "$cache_file"$$ && >+ mv -f "$cache_file"$$ "$cache_file" ;; #( >+ *) >+ mv -f confcache "$cache_file" ;; >+ esac >+ fi >+ fi >+ else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 >+$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} >+ fi >+fi >+rm -f confcache >+ >+test "x$prefix" = xNONE && prefix=$ac_default_prefix >+# Let make expand exec_prefix. >+test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' >+ >+DEFS=-DHAVE_CONFIG_H >+ >+ac_libobjs= >+ac_ltlibobjs= >+U= >+for ac_i in : $LIB@&t@OBJS; do test "x$ac_i" = x: && continue >+ # 1. Remove the extension, and $U if already installed. >+ ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' >+ ac_i=`$as_echo "$ac_i" | sed "$ac_script"` >+ # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR >+ # will be set to the directory where LIBOBJS objects are built. >+ as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" >+ as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' >+done >+LIB@&t@OBJS=$ac_libobjs >+ >+LTLIBOBJS=$ac_ltlibobjs >+ >+ >+ >+: "${CONFIG_STATUS=./config.status}" >+ac_write_fail=0 >+ac_clean_files_save=$ac_clean_files >+ac_clean_files="$ac_clean_files $CONFIG_STATUS" >+{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 >+$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} >+as_write_fail=0 >+cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 >+#! $SHELL >+# Generated by $as_me. >+# Run this file to recreate the current configuration. >+# Compiler output produced by configure, useful for debugging >+# configure, is in config.log if it exists. >+ >+debug=false >+ac_cs_recheck=false >+ac_cs_silent=false >+ >+SHELL=\${CONFIG_SHELL-$SHELL} >+export SHELL >+_ASEOF >+cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 >+## -------------------- ## >+## M4sh Initialization. ## >+## -------------------- ## >+ >+# Be more Bourne compatible >+DUALCASE=1; export DUALCASE # for MKS sh >+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : >+ emulate sh >+ NULLCMD=: >+ # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which >+ # is contrary to our usage. Disable this feature. >+ alias -g '${1+"$@"}'='"$@"' >+ setopt NO_GLOB_SUBST >+else >+ case `(set -o) 2>/dev/null` in @%:@( >+ *posix*) : >+ set -o posix ;; @%:@( >+ *) : >+ ;; >+esac >+fi >+ >+ >+as_nl=' >+' >+export as_nl >+# Printing a long string crashes Solaris 7 /usr/bin/printf. >+as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo >+# Prefer a ksh shell builtin over an external printf program on Solaris, >+# but without wasting forks for bash or zsh. >+if test -z "$BASH_VERSION$ZSH_VERSION" \ >+ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='print -r --' >+ as_echo_n='print -rn --' >+elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='printf %s\n' >+ as_echo_n='printf %s' >+else >+ if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then >+ as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' >+ as_echo_n='/usr/ucb/echo -n' >+ else >+ as_echo_body='eval expr "X$1" : "X\\(.*\\)"' >+ as_echo_n_body='eval >+ arg=$1; >+ case $arg in @%:@( >+ *"$as_nl"*) >+ expr "X$arg" : "X\\(.*\\)$as_nl"; >+ arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; >+ esac; >+ expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" >+ ' >+ export as_echo_n_body >+ as_echo_n='sh -c $as_echo_n_body as_echo' >+ fi >+ export as_echo_body >+ as_echo='sh -c $as_echo_body as_echo' >+fi >+ >+# The user is always right. >+if test "${PATH_SEPARATOR+set}" != set; then >+ PATH_SEPARATOR=: >+ (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { >+ (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || >+ PATH_SEPARATOR=';' >+ } >+fi >+ >+ >+# IFS >+# We need space, tab and new line, in precisely that order. Quoting is >+# there to prevent editors from complaining about space-tab. >+# (If _AS_PATH_WALK were called with IFS unset, it would disable word >+# splitting by setting IFS to empty value.) >+IFS=" "" $as_nl" >+ >+# Find who we are. Look in the path if we contain no directory separator. >+as_myself= >+case $0 in @%:@(( >+ *[\\/]* ) as_myself=$0 ;; >+ *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break >+ done >+IFS=$as_save_IFS >+ >+ ;; >+esac >+# We did not find ourselves, most probably we were run as `sh COMMAND' >+# in which case we are not to be found in the path. >+if test "x$as_myself" = x; then >+ as_myself=$0 >+fi >+if test ! -f "$as_myself"; then >+ $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 >+ exit 1 >+fi >+ >+# Unset variables that we do not need and which cause bugs (e.g. in >+# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" >+# suppresses any "Segmentation fault" message there. '((' could >+# trigger a bug in pdksh 5.2.14. >+for as_var in BASH_ENV ENV MAIL MAILPATH >+do eval test x\${$as_var+set} = xset \ >+ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : >+done >+PS1='$ ' >+PS2='> ' >+PS4='+ ' >+ >+# NLS nuisances. >+LC_ALL=C >+export LC_ALL >+LANGUAGE=C >+export LANGUAGE >+ >+# CDPATH. >+(unset CDPATH) >/dev/null 2>&1 && unset CDPATH >+ >+ >+@%:@ as_fn_error STATUS ERROR [LINENO LOG_FD] >+@%:@ ---------------------------------------- >+@%:@ Output "`basename @S|@0`: error: ERROR" to stderr. If LINENO and LOG_FD are >+@%:@ provided, also output the error to LOG_FD, referencing LINENO. Then exit the >+@%:@ script with STATUS, using 1 if that was 0. >+as_fn_error () >+{ >+ as_status=$1; test $as_status -eq 0 && as_status=1 >+ if test "$4"; then >+ as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 >+ fi >+ $as_echo "$as_me: error: $2" >&2 >+ as_fn_exit $as_status >+} @%:@ as_fn_error >+ >+ >+@%:@ as_fn_set_status STATUS >+@%:@ ----------------------- >+@%:@ Set @S|@? to STATUS, without forking. >+as_fn_set_status () >+{ >+ return $1 >+} @%:@ as_fn_set_status >+ >+@%:@ as_fn_exit STATUS >+@%:@ ----------------- >+@%:@ Exit the shell with STATUS, even in a "trap 0" or "set -e" context. >+as_fn_exit () >+{ >+ set +e >+ as_fn_set_status $1 >+ exit $1 >+} @%:@ as_fn_exit >+ >+@%:@ as_fn_unset VAR >+@%:@ --------------- >+@%:@ Portably unset VAR. >+as_fn_unset () >+{ >+ { eval $1=; unset $1;} >+} >+as_unset=as_fn_unset >+@%:@ as_fn_append VAR VALUE >+@%:@ ---------------------- >+@%:@ Append the text in VALUE to the end of the definition contained in VAR. Take >+@%:@ advantage of any shell optimizations that allow amortized linear growth over >+@%:@ repeated appends, instead of the typical quadratic growth present in naive >+@%:@ implementations. >+if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : >+ eval 'as_fn_append () >+ { >+ eval $1+=\$2 >+ }' >+else >+ as_fn_append () >+ { >+ eval $1=\$$1\$2 >+ } >+fi # as_fn_append >+ >+@%:@ as_fn_arith ARG... >+@%:@ ------------------ >+@%:@ Perform arithmetic evaluation on the ARGs, and store the result in the >+@%:@ global @S|@as_val. Take advantage of shells that can avoid forks. The arguments >+@%:@ must be portable across @S|@(()) and expr. >+if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : >+ eval 'as_fn_arith () >+ { >+ as_val=$(( $* )) >+ }' >+else >+ as_fn_arith () >+ { >+ as_val=`expr "$@" || test $? -eq 1` >+ } >+fi # as_fn_arith >+ >+ >+if expr a : '\(a\)' >/dev/null 2>&1 && >+ test "X`expr 00001 : '.*\(...\)'`" = X001; then >+ as_expr=expr >+else >+ as_expr=false >+fi >+ >+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then >+ as_basename=basename >+else >+ as_basename=false >+fi >+ >+if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then >+ as_dirname=dirname >+else >+ as_dirname=false >+fi >+ >+as_me=`$as_basename -- "$0" || >+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ >+ X"$0" : 'X\(//\)$' \| \ >+ X"$0" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X/"$0" | >+ sed '/^.*\/\([^/][^/]*\)\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ >+# Avoid depending upon Character Ranges. >+as_cr_letters='abcdefghijklmnopqrstuvwxyz' >+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' >+as_cr_Letters=$as_cr_letters$as_cr_LETTERS >+as_cr_digits='0123456789' >+as_cr_alnum=$as_cr_Letters$as_cr_digits >+ >+ECHO_C= ECHO_N= ECHO_T= >+case `echo -n x` in @%:@((((( >+-n*) >+ case `echo 'xy\c'` in >+ *c*) ECHO_T=' ';; # ECHO_T is single tab character. >+ xy) ECHO_C='\c';; >+ *) echo `echo ksh88 bug on AIX 6.1` > /dev/null >+ ECHO_T=' ';; >+ esac;; >+*) >+ ECHO_N='-n';; >+esac >+ >+rm -f conf$$ conf$$.exe conf$$.file >+if test -d conf$$.dir; then >+ rm -f conf$$.dir/conf$$.file >+else >+ rm -f conf$$.dir >+ mkdir conf$$.dir 2>/dev/null >+fi >+if (echo >conf$$.file) 2>/dev/null; then >+ if ln -s conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s='ln -s' >+ # ... but there are two gotchas: >+ # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. >+ # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. >+ # In both cases, we have to default to `cp -pR'. >+ ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || >+ as_ln_s='cp -pR' >+ elif ln conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s=ln >+ else >+ as_ln_s='cp -pR' >+ fi >+else >+ as_ln_s='cp -pR' >+fi >+rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file >+rmdir conf$$.dir 2>/dev/null >+ >+ >+@%:@ as_fn_mkdir_p >+@%:@ ------------- >+@%:@ Create "@S|@as_dir" as a directory, including parents if necessary. >+as_fn_mkdir_p () >+{ >+ >+ case $as_dir in #( >+ -*) as_dir=./$as_dir;; >+ esac >+ test -d "$as_dir" || eval $as_mkdir_p || { >+ as_dirs= >+ while :; do >+ case $as_dir in #( >+ *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( >+ *) as_qdir=$as_dir;; >+ esac >+ as_dirs="'$as_qdir' $as_dirs" >+ as_dir=`$as_dirname -- "$as_dir" || >+$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$as_dir" : 'X\(//\)[^/]' \| \ >+ X"$as_dir" : 'X\(//\)$' \| \ >+ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$as_dir" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ test -d "$as_dir" && break >+ done >+ test -z "$as_dirs" || eval "mkdir $as_dirs" >+ } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" >+ >+ >+} @%:@ as_fn_mkdir_p >+if mkdir -p . 2>/dev/null; then >+ as_mkdir_p='mkdir -p "$as_dir"' >+else >+ test -d ./-p && rmdir ./-p >+ as_mkdir_p=false >+fi >+ >+ >+@%:@ as_fn_executable_p FILE >+@%:@ ----------------------- >+@%:@ Test if FILE is an executable regular file. >+as_fn_executable_p () >+{ >+ test -f "$1" && test -x "$1" >+} @%:@ as_fn_executable_p >+as_test_x='test -x' >+as_executable_p=as_fn_executable_p >+ >+# Sed expression to map a string onto a valid CPP name. >+as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" >+ >+# Sed expression to map a string onto a valid variable name. >+as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" >+ >+ >+exec 6>&1 >+## ----------------------------------- ## >+## Main body of $CONFIG_STATUS script. ## >+## ----------------------------------- ## >+_ASEOF >+test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+# Save the log message, to keep $0 and so on meaningful, and to >+# report actual input values of CONFIG_FILES etc. instead of their >+# values after options handling. >+ac_log=" >+This file was extended by libbgpdump $as_me 1.4.99.15, which was >+generated by GNU Autoconf 2.69. Invocation command line was >+ >+ CONFIG_FILES = $CONFIG_FILES >+ CONFIG_HEADERS = $CONFIG_HEADERS >+ CONFIG_LINKS = $CONFIG_LINKS >+ CONFIG_COMMANDS = $CONFIG_COMMANDS >+ $ $0 $@ >+ >+on `(hostname || uname -n) 2>/dev/null | sed 1q` >+" >+ >+_ACEOF >+ >+case $ac_config_files in *" >+"*) set x $ac_config_files; shift; ac_config_files=$*;; >+esac >+ >+case $ac_config_headers in *" >+"*) set x $ac_config_headers; shift; ac_config_headers=$*;; >+esac >+ >+ >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+# Files that config.status was made for. >+config_files="$ac_config_files" >+config_headers="$ac_config_headers" >+ >+_ACEOF >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+ac_cs_usage="\ >+\`$as_me' instantiates files and other configuration actions >+from templates according to the current configuration. Unless the files >+and actions are specified as TAGs, all are instantiated by default. >+ >+Usage: $0 [OPTION]... [TAG]... >+ >+ -h, --help print this help, then exit >+ -V, --version print version number and configuration settings, then exit >+ --config print configuration, then exit >+ -q, --quiet, --silent >+ do not print progress messages >+ -d, --debug don't remove temporary files >+ --recheck update $as_me by reconfiguring in the same conditions >+ --file=FILE[:TEMPLATE] >+ instantiate the configuration file FILE >+ --header=FILE[:TEMPLATE] >+ instantiate the configuration header FILE >+ >+Configuration files: >+$config_files >+ >+Configuration headers: >+$config_headers >+ >+Report bugs to <ris@ripe.net>." >+ >+_ACEOF >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" >+ac_cs_version="\\ >+libbgpdump config.status 1.4.99.15 >+configured by $0, generated by GNU Autoconf 2.69, >+ with options \\"\$ac_cs_config\\" >+ >+Copyright (C) 2012 Free Software Foundation, Inc. >+This config.status script is free software; the Free Software Foundation >+gives unlimited permission to copy, distribute and modify it." >+ >+ac_pwd='$ac_pwd' >+srcdir='$srcdir' >+test -n "\$AWK" || AWK=awk >+_ACEOF >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+# The default lists apply if the user does not specify any file. >+ac_need_defaults=: >+while test $# != 0 >+do >+ case $1 in >+ --*=?*) >+ ac_option=`expr "X$1" : 'X\([^=]*\)='` >+ ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` >+ ac_shift=: >+ ;; >+ --*=) >+ ac_option=`expr "X$1" : 'X\([^=]*\)='` >+ ac_optarg= >+ ac_shift=: >+ ;; >+ *) >+ ac_option=$1 >+ ac_optarg=$2 >+ ac_shift=shift >+ ;; >+ esac >+ >+ case $ac_option in >+ # Handling of the options. >+ -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) >+ ac_cs_recheck=: ;; >+ --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) >+ $as_echo "$ac_cs_version"; exit ;; >+ --config | --confi | --conf | --con | --co | --c ) >+ $as_echo "$ac_cs_config"; exit ;; >+ --debug | --debu | --deb | --de | --d | -d ) >+ debug=: ;; >+ --file | --fil | --fi | --f ) >+ $ac_shift >+ case $ac_optarg in >+ *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; >+ '') as_fn_error $? "missing file argument" ;; >+ esac >+ as_fn_append CONFIG_FILES " '$ac_optarg'" >+ ac_need_defaults=false;; >+ --header | --heade | --head | --hea ) >+ $ac_shift >+ case $ac_optarg in >+ *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; >+ esac >+ as_fn_append CONFIG_HEADERS " '$ac_optarg'" >+ ac_need_defaults=false;; >+ --he | --h) >+ # Conflict between --help and --header >+ as_fn_error $? "ambiguous option: \`$1' >+Try \`$0 --help' for more information.";; >+ --help | --hel | -h ) >+ $as_echo "$ac_cs_usage"; exit ;; >+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \ >+ | -silent | --silent | --silen | --sile | --sil | --si | --s) >+ ac_cs_silent=: ;; >+ >+ # This is an error. >+ -*) as_fn_error $? "unrecognized option: \`$1' >+Try \`$0 --help' for more information." ;; >+ >+ *) as_fn_append ac_config_targets " $1" >+ ac_need_defaults=false ;; >+ >+ esac >+ shift >+done >+ >+ac_configure_extra_args= >+ >+if $ac_cs_silent; then >+ exec 6>/dev/null >+ ac_configure_extra_args="$ac_configure_extra_args --silent" >+fi >+ >+_ACEOF >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+if \$ac_cs_recheck; then >+ set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion >+ shift >+ \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 >+ CONFIG_SHELL='$SHELL' >+ export CONFIG_SHELL >+ exec "\$@" >+fi >+ >+_ACEOF >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+exec 5>>config.log >+{ >+ echo >+ sed 'h;s/./-/g;s/^.../@%:@@%:@ /;s/...$/ @%:@@%:@/;p;x;p;x' <<_ASBOX >+@%:@@%:@ Running $as_me. @%:@@%:@ >+_ASBOX >+ $as_echo "$ac_log" >+} >&5 >+ >+_ACEOF >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+_ACEOF >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+ >+# Handling of arguments. >+for ac_config_target in $ac_config_targets >+do >+ case $ac_config_target in >+ "bgpdump-config.h") CONFIG_HEADERS="$CONFIG_HEADERS bgpdump-config.h" ;; >+ "bgpdump.spec") CONFIG_FILES="$CONFIG_FILES bgpdump.spec" ;; >+ "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; >+ >+ *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; >+ esac >+done >+ >+ >+# If the user did not use the arguments to specify the items to instantiate, >+# then the envvar interface is used. Set only those that are not. >+# We use the long form for the default assignment because of an extremely >+# bizarre bug on SunOS 4.1.3. >+if $ac_need_defaults; then >+ test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files >+ test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers >+fi >+ >+# Have a temporary directory for convenience. Make it in the build tree >+# simply because there is no reason against having it here, and in addition, >+# creating and moving files from /tmp can sometimes cause problems. >+# Hook for its removal unless debugging. >+# Note that there is a small window in which the directory will not be cleaned: >+# after its creation but before its name has been assigned to `$tmp'. >+$debug || >+{ >+ tmp= ac_tmp= >+ trap 'exit_status=$? >+ : "${ac_tmp:=$tmp}" >+ { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status >+' 0 >+ trap 'as_fn_exit 1' 1 2 13 15 >+} >+# Create a (secure) tmp directory for tmp files. >+ >+{ >+ tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && >+ test -d "$tmp" >+} || >+{ >+ tmp=./conf$$-$RANDOM >+ (umask 077 && mkdir "$tmp") >+} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 >+ac_tmp=$tmp >+ >+# Set up the scripts for CONFIG_FILES section. >+# No need to generate them if there are no CONFIG_FILES. >+# This happens for instance with `./config.status config.h'. >+if test -n "$CONFIG_FILES"; then >+ >+ >+ac_cr=`echo X | tr X '\015'` >+# On cygwin, bash can eat \r inside `` if the user requested igncr. >+# But we know of no other shell where ac_cr would be empty at this >+# point, so we can use a bashism as a fallback. >+if test "x$ac_cr" = x; then >+ eval ac_cr=\$\'\\r\' >+fi >+ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` >+if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then >+ ac_cs_awk_cr='\\r' >+else >+ ac_cs_awk_cr=$ac_cr >+fi >+ >+echo 'BEGIN {' >"$ac_tmp/subs1.awk" && >+_ACEOF >+ >+ >+{ >+ echo "cat >conf$$subs.awk <<_ACEOF" && >+ echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && >+ echo "_ACEOF" >+} >conf$$subs.sh || >+ as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 >+ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` >+ac_delim='%!_!# ' >+for ac_last_try in false false false false false :; do >+ . ./conf$$subs.sh || >+ as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 >+ >+ ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` >+ if test $ac_delim_n = $ac_delim_num; then >+ break >+ elif $ac_last_try; then >+ as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 >+ else >+ ac_delim="$ac_delim!$ac_delim _$ac_delim!! " >+ fi >+done >+rm -f conf$$subs.sh >+ >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && >+_ACEOF >+sed -n ' >+h >+s/^/S["/; s/!.*/"]=/ >+p >+g >+s/^[^!]*!// >+:repl >+t repl >+s/'"$ac_delim"'$// >+t delim >+:nl >+h >+s/\(.\{148\}\)..*/\1/ >+t more1 >+s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ >+p >+n >+b repl >+:more1 >+s/["\\]/\\&/g; s/^/"/; s/$/"\\/ >+p >+g >+s/.\{148\}// >+t nl >+:delim >+h >+s/\(.\{148\}\)..*/\1/ >+t more2 >+s/["\\]/\\&/g; s/^/"/; s/$/"/ >+p >+b >+:more2 >+s/["\\]/\\&/g; s/^/"/; s/$/"\\/ >+p >+g >+s/.\{148\}// >+t delim >+' <conf$$subs.awk | sed ' >+/^[^""]/{ >+ N >+ s/\n// >+} >+' >>$CONFIG_STATUS || ac_write_fail=1 >+rm -f conf$$subs.awk >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+_ACAWK >+cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && >+ for (key in S) S_is_set[key] = 1 >+ FS = "" >+ >+} >+{ >+ line = $ 0 >+ nfields = split(line, field, "@") >+ substed = 0 >+ len = length(field[1]) >+ for (i = 2; i < nfields; i++) { >+ key = field[i] >+ keylen = length(key) >+ if (S_is_set[key]) { >+ value = S[key] >+ line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) >+ len += length(value) + length(field[++i]) >+ substed = 1 >+ } else >+ len += 1 + keylen >+ } >+ >+ print line >+} >+ >+_ACAWK >+_ACEOF >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then >+ sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" >+else >+ cat >+fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ >+ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 >+_ACEOF >+ >+# VPATH may cause trouble with some makes, so we remove sole $(srcdir), >+# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and >+# trailing colons and then remove the whole line if VPATH becomes empty >+# (actually we leave an empty line to preserve line numbers). >+if test "x$srcdir" = x.; then >+ ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ >+h >+s/// >+s/^/:/ >+s/[ ]*$/:/ >+s/:\$(srcdir):/:/g >+s/:\${srcdir}:/:/g >+s/:@srcdir@:/:/g >+s/^:*// >+s/:*$// >+x >+s/\(=[ ]*\).*/\1/ >+G >+s/\n// >+s/^[^=]*=[ ]*$// >+}' >+fi >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+fi # test -n "$CONFIG_FILES" >+ >+# Set up the scripts for CONFIG_HEADERS section. >+# No need to generate them if there are no CONFIG_HEADERS. >+# This happens for instance with `./config.status Makefile'. >+if test -n "$CONFIG_HEADERS"; then >+cat >"$ac_tmp/defines.awk" <<\_ACAWK || >+BEGIN { >+_ACEOF >+ >+# Transform confdefs.h into an awk script `defines.awk', embedded as >+# here-document in config.status, that substitutes the proper values into >+# config.h.in to produce config.h. >+ >+# Create a delimiter string that does not exist in confdefs.h, to ease >+# handling of long lines. >+ac_delim='%!_!# ' >+for ac_last_try in false false :; do >+ ac_tt=`sed -n "/$ac_delim/p" confdefs.h` >+ if test -z "$ac_tt"; then >+ break >+ elif $ac_last_try; then >+ as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 >+ else >+ ac_delim="$ac_delim!$ac_delim _$ac_delim!! " >+ fi >+done >+ >+# For the awk script, D is an array of macro values keyed by name, >+# likewise P contains macro parameters if any. Preserve backslash >+# newline sequences. >+ >+ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* >+sed -n ' >+s/.\{148\}/&'"$ac_delim"'/g >+t rset >+:rset >+s/^[ ]*#[ ]*define[ ][ ]*/ / >+t def >+d >+:def >+s/\\$// >+t bsnl >+s/["\\]/\\&/g >+s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ >+D["\1"]=" \3"/p >+s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p >+d >+:bsnl >+s/["\\]/\\&/g >+s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ >+D["\1"]=" \3\\\\\\n"\\/p >+t cont >+s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p >+t cont >+d >+:cont >+n >+s/.\{148\}/&'"$ac_delim"'/g >+t clear >+:clear >+s/\\$// >+t bsnlc >+s/["\\]/\\&/g; s/^/"/; s/$/"/p >+d >+:bsnlc >+s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p >+b cont >+' <confdefs.h | sed ' >+s/'"$ac_delim"'/"\\\ >+"/g' >>$CONFIG_STATUS || ac_write_fail=1 >+ >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+ for (key in D) D_is_set[key] = 1 >+ FS = "" >+} >+/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { >+ line = \$ 0 >+ split(line, arg, " ") >+ if (arg[1] == "#") { >+ defundef = arg[2] >+ mac1 = arg[3] >+ } else { >+ defundef = substr(arg[1], 2) >+ mac1 = arg[2] >+ } >+ split(mac1, mac2, "(") #) >+ macro = mac2[1] >+ prefix = substr(line, 1, index(line, defundef) - 1) >+ if (D_is_set[macro]) { >+ # Preserve the white space surrounding the "#". >+ print prefix "define", macro P[macro] D[macro] >+ next >+ } else { >+ # Replace #undef with comments. This is necessary, for example, >+ # in the case of _POSIX_SOURCE, which is predefined and required >+ # on some systems where configure will not decide to define it. >+ if (defundef == "undef") { >+ print "/*", prefix defundef, macro, "*/" >+ next >+ } >+ } >+} >+{ print } >+_ACAWK >+_ACEOF >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+ as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 >+fi # test -n "$CONFIG_HEADERS" >+ >+ >+eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " >+shift >+for ac_tag >+do >+ case $ac_tag in >+ :[FHLC]) ac_mode=$ac_tag; continue;; >+ esac >+ case $ac_mode$ac_tag in >+ :[FHL]*:*);; >+ :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; >+ :[FH]-) ac_tag=-:-;; >+ :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; >+ esac >+ ac_save_IFS=$IFS >+ IFS=: >+ set x $ac_tag >+ IFS=$ac_save_IFS >+ shift >+ ac_file=$1 >+ shift >+ >+ case $ac_mode in >+ :L) ac_source=$1;; >+ :[FH]) >+ ac_file_inputs= >+ for ac_f >+ do >+ case $ac_f in >+ -) ac_f="$ac_tmp/stdin";; >+ *) # Look for the file first in the build tree, then in the source tree >+ # (if the path is not absolute). The absolute path cannot be DOS-style, >+ # because $ac_f cannot contain `:'. >+ test -f "$ac_f" || >+ case $ac_f in >+ [\\/$]*) false;; >+ *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; >+ esac || >+ as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; >+ esac >+ case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac >+ as_fn_append ac_file_inputs " '$ac_f'" >+ done >+ >+ # Let's still pretend it is `configure' which instantiates (i.e., don't >+ # use $as_me), people would be surprised to read: >+ # /* config.h. Generated by config.status. */ >+ configure_input='Generated from '` >+ $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' >+ `' by configure.' >+ if test x"$ac_file" != x-; then >+ configure_input="$ac_file. $configure_input" >+ { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 >+$as_echo "$as_me: creating $ac_file" >&6;} >+ fi >+ # Neutralize special characters interpreted by sed in replacement strings. >+ case $configure_input in #( >+ *\&* | *\|* | *\\* ) >+ ac_sed_conf_input=`$as_echo "$configure_input" | >+ sed 's/[\\\\&|]/\\\\&/g'`;; #( >+ *) ac_sed_conf_input=$configure_input;; >+ esac >+ >+ case $ac_tag in >+ *:-:* | *:-) cat >"$ac_tmp/stdin" \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; >+ esac >+ ;; >+ esac >+ >+ ac_dir=`$as_dirname -- "$ac_file" || >+$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$ac_file" : 'X\(//\)[^/]' \| \ >+ X"$ac_file" : 'X\(//\)$' \| \ >+ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$ac_file" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ as_dir="$ac_dir"; as_fn_mkdir_p >+ ac_builddir=. >+ >+case "$ac_dir" in >+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; >+*) >+ ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` >+ # A ".." for each directory in $ac_dir_suffix. >+ ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` >+ case $ac_top_builddir_sub in >+ "") ac_top_builddir_sub=. ac_top_build_prefix= ;; >+ *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; >+ esac ;; >+esac >+ac_abs_top_builddir=$ac_pwd >+ac_abs_builddir=$ac_pwd$ac_dir_suffix >+# for backward compatibility: >+ac_top_builddir=$ac_top_build_prefix >+ >+case $srcdir in >+ .) # We are building in place. >+ ac_srcdir=. >+ ac_top_srcdir=$ac_top_builddir_sub >+ ac_abs_top_srcdir=$ac_pwd ;; >+ [\\/]* | ?:[\\/]* ) # Absolute name. >+ ac_srcdir=$srcdir$ac_dir_suffix; >+ ac_top_srcdir=$srcdir >+ ac_abs_top_srcdir=$srcdir ;; >+ *) # Relative name. >+ ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix >+ ac_top_srcdir=$ac_top_build_prefix$srcdir >+ ac_abs_top_srcdir=$ac_pwd/$srcdir ;; >+esac >+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix >+ >+ >+ case $ac_mode in >+ :F) >+ # >+ # CONFIG_FILE >+ # >+ >+_ACEOF >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+# If the template does not know about datarootdir, expand it. >+# FIXME: This hack should be removed a few years after 2.60. >+ac_datarootdir_hack=; ac_datarootdir_seen= >+ac_sed_dataroot=' >+/datarootdir/ { >+ p >+ q >+} >+/@datadir@/p >+/@docdir@/p >+/@infodir@/p >+/@localedir@/p >+/@mandir@/p' >+case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in >+*datarootdir*) ac_datarootdir_seen=yes;; >+*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 >+$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} >+_ACEOF >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+ ac_datarootdir_hack=' >+ s&@datadir@&$datadir&g >+ s&@docdir@&$docdir&g >+ s&@infodir@&$infodir&g >+ s&@localedir@&$localedir&g >+ s&@mandir@&$mandir&g >+ s&\\\${datarootdir}&$datarootdir&g' ;; >+esac >+_ACEOF >+ >+# Neutralize VPATH when `$srcdir' = `.'. >+# Shell code in configure.ac might set extrasub. >+# FIXME: do we really want to maintain this feature? >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+ac_sed_extra="$ac_vpsub >+$extrasub >+_ACEOF >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+:t >+/@[a-zA-Z_][a-zA-Z_0-9]*@/!b >+s|@configure_input@|$ac_sed_conf_input|;t t >+s&@top_builddir@&$ac_top_builddir_sub&;t t >+s&@top_build_prefix@&$ac_top_build_prefix&;t t >+s&@srcdir@&$ac_srcdir&;t t >+s&@abs_srcdir@&$ac_abs_srcdir&;t t >+s&@top_srcdir@&$ac_top_srcdir&;t t >+s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t >+s&@builddir@&$ac_builddir&;t t >+s&@abs_builddir@&$ac_abs_builddir&;t t >+s&@abs_top_builddir@&$ac_abs_top_builddir&;t t >+$ac_datarootdir_hack >+" >+eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ >+ >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ >+test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && >+ { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && >+ { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ >+ "$ac_tmp/out"`; test -z "$ac_out"; } && >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' >+which seems to be undefined. Please make sure it is defined" >&5 >+$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' >+which seems to be undefined. Please make sure it is defined" >&2;} >+ >+ rm -f "$ac_tmp/stdin" >+ case $ac_file in >+ -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; >+ *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; >+ esac \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ ;; >+ :H) >+ # >+ # CONFIG_HEADER >+ # >+ if test x"$ac_file" != x-; then >+ { >+ $as_echo "/* $configure_input */" \ >+ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" >+ } >"$ac_tmp/config.h" \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 >+$as_echo "$as_me: $ac_file is unchanged" >&6;} >+ else >+ rm -f "$ac_file" >+ mv "$ac_tmp/config.h" "$ac_file" \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ fi >+ else >+ $as_echo "/* $configure_input */" \ >+ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ >+ || as_fn_error $? "could not create -" "$LINENO" 5 >+ fi >+ ;; >+ >+ >+ esac >+ >+done # for ac_tag >+ >+ >+as_fn_exit 0 >+_ACEOF >+ac_clean_files=$ac_clean_files_save >+ >+test $ac_write_fail = 0 || >+ as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 >+ >+ >+# configure is writing to config.log, and then calls config.status. >+# config.status does its own redirection, appending to config.log. >+# Unfortunately, on DOS this fails, as config.log is still kept open >+# by configure, so config.status won't be able to write to it; its >+# output is simply discarded. So we exec the FD to /dev/null, >+# effectively closing config.log, so it can be properly (re)opened and >+# appended to by config.status. When coming back to configure, we >+# need to make the FD available again. >+if test "$no_create" != yes; then >+ ac_cs_success=: >+ ac_config_status_args= >+ test "$silent" = yes && >+ ac_config_status_args="$ac_config_status_args --quiet" >+ exec 5>/dev/null >+ $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false >+ exec 5>>config.log >+ # Use ||, not &&, to avoid exiting from the if with $? = 1, which >+ # would make configure fail if this is the last instruction. >+ $ac_cs_success || as_fn_exit 1 >+fi >+if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 >+$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} >+fi >+ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/autom4te.cache/requests libbgpdump-new/work/libbgpdump-1.4.99.15/autom4te.cache/requests >--- libbgpdump/work/libbgpdump-1.4.99.15/autom4te.cache/requests 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/autom4te.cache/requests 2015-09-16 20:22:49.000000000 +1200 >@@ -0,0 +1,77 @@ >+# This file was generated. >+# It contains the lists of macros which have been traced. >+# It can be safely removed. >+ >+@request = ( >+ bless( [ >+ '0', >+ 1, >+ [ >+ '/usr/local/Cellar/autoconf/2.69/share/autoconf' >+ ], >+ [ >+ '/usr/local/Cellar/autoconf/2.69/share/autoconf/autoconf/autoconf.m4f', >+ 'configure.in' >+ ], >+ { >+ 'AC_FC_FREEFORM' => 1, >+ 'AC_PROG_LIBTOOL' => 1, >+ 'AC_LIBSOURCE' => 1, >+ 'AC_CONFIG_LIBOBJ_DIR' => 1, >+ 'AM_PROG_MOC' => 1, >+ '_LT_AC_TAGCONFIG' => 1, >+ '_AM_COND_ENDIF' => 1, >+ 'AC_CONFIG_LINKS' => 1, >+ 'AM_ENABLE_MULTILIB' => 1, >+ 'LT_SUPPORTED_TAG' => 1, >+ 'AM_GNU_GETTEXT' => 1, >+ 'AM_INIT_AUTOMAKE' => 1, >+ 'LT_INIT' => 1, >+ 'AC_CONFIG_AUX_DIR' => 1, >+ 'AH_OUTPUT' => 1, >+ 'AM_PROG_F77_C_O' => 1, >+ 'AC_DEFINE_TRACE_LITERAL' => 1, >+ 'AC_FC_PP_DEFINE' => 1, >+ 'AM_PROG_CC_C_O' => 1, >+ 'AM_PROG_FC_C_O' => 1, >+ 'AM_POT_TOOLS' => 1, >+ 'AM_GNU_GETTEXT_INTL_SUBDIR' => 1, >+ 'AM_NLS' => 1, >+ 'AM_CONDITIONAL' => 1, >+ 'AC_REQUIRE_AUX_FILE' => 1, >+ 'AM_SILENT_RULES' => 1, >+ '_AM_SUBST_NOTMAKE' => 1, >+ '_AM_MAKEFILE_INCLUDE' => 1, >+ 'LT_CONFIG_LTDL_DIR' => 1, >+ 'AC_FC_SRCEXT' => 1, >+ 'AM_MAKEFILE_INCLUDE' => 1, >+ 'm4_pattern_forbid' => 1, >+ 'AM_PROG_AR' => 1, >+ 'AC_SUBST_TRACE' => 1, >+ 'm4_sinclude' => 1, >+ 'AM_XGETTEXT_OPTION' => 1, >+ 'sinclude' => 1, >+ '_m4_warn' => 1, >+ 'AC_SUBST' => 1, >+ 'AM_PATH_GUILE' => 1, >+ 'AC_CONFIG_HEADERS' => 1, >+ 'AM_AUTOMAKE_VERSION' => 1, >+ 'AC_CANONICAL_HOST' => 1, >+ 'AC_CANONICAL_SYSTEM' => 1, >+ '_AM_COND_IF' => 1, >+ 'AC_CONFIG_FILES' => 1, >+ 'AC_CONFIG_SUBDIRS' => 1, >+ 'm4_pattern_allow' => 1, >+ 'include' => 1, >+ 'AC_CANONICAL_TARGET' => 1, >+ 'AC_CANONICAL_BUILD' => 1, >+ 'AM_MAINTAINER_MODE' => 1, >+ 'AC_FC_PP_SRCEXT' => 1, >+ '_AM_COND_ELSE' => 1, >+ 'AM_PROG_CXX_C_O' => 1, >+ 'm4_include' => 1, >+ 'AC_INIT' => 1 >+ } >+ ], 'Autom4te::Request' ) >+ ); >+ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/autom4te.cache/traces.0 libbgpdump-new/work/libbgpdump-1.4.99.15/autom4te.cache/traces.0 >--- libbgpdump/work/libbgpdump-1.4.99.15/autom4te.cache/traces.0 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/autom4te.cache/traces.0 2015-09-16 20:22:47.000000000 +1200 >@@ -0,0 +1,307 @@ >+m4trace:configure.in:4: -1- AC_INIT([libbgpdump], [1.4.99.15], [ris@ripe.net]) >+m4trace:configure.in:4: -1- m4_pattern_forbid([^_?A[CHUM]_]) >+m4trace:configure.in:4: -1- m4_pattern_forbid([_AC_]) >+m4trace:configure.in:4: -1- m4_pattern_forbid([^LIBOBJS$], [do not use LIBOBJS directly, use AC_LIBOBJ (see section `AC_LIBOBJ vs LIBOBJS']) >+m4trace:configure.in:4: -1- m4_pattern_allow([^AS_FLAGS$]) >+m4trace:configure.in:4: -1- m4_pattern_forbid([^_?m4_]) >+m4trace:configure.in:4: -1- m4_pattern_forbid([^dnl$]) >+m4trace:configure.in:4: -1- m4_pattern_forbid([^_?AS_]) >+m4trace:configure.in:4: -1- AC_SUBST([SHELL]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([SHELL]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^SHELL$]) >+m4trace:configure.in:4: -1- AC_SUBST([PATH_SEPARATOR]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([PATH_SEPARATOR]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PATH_SEPARATOR$]) >+m4trace:configure.in:4: -1- AC_SUBST([PACKAGE_NAME], [m4_ifdef([AC_PACKAGE_NAME], ['AC_PACKAGE_NAME'])]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([PACKAGE_NAME]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_NAME$]) >+m4trace:configure.in:4: -1- AC_SUBST([PACKAGE_TARNAME], [m4_ifdef([AC_PACKAGE_TARNAME], ['AC_PACKAGE_TARNAME'])]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([PACKAGE_TARNAME]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_TARNAME$]) >+m4trace:configure.in:4: -1- AC_SUBST([PACKAGE_VERSION], [m4_ifdef([AC_PACKAGE_VERSION], ['AC_PACKAGE_VERSION'])]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([PACKAGE_VERSION]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_VERSION$]) >+m4trace:configure.in:4: -1- AC_SUBST([PACKAGE_STRING], [m4_ifdef([AC_PACKAGE_STRING], ['AC_PACKAGE_STRING'])]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([PACKAGE_STRING]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_STRING$]) >+m4trace:configure.in:4: -1- AC_SUBST([PACKAGE_BUGREPORT], [m4_ifdef([AC_PACKAGE_BUGREPORT], ['AC_PACKAGE_BUGREPORT'])]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([PACKAGE_BUGREPORT]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$]) >+m4trace:configure.in:4: -1- AC_SUBST([PACKAGE_URL], [m4_ifdef([AC_PACKAGE_URL], ['AC_PACKAGE_URL'])]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([PACKAGE_URL]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_URL$]) >+m4trace:configure.in:4: -1- AC_SUBST([exec_prefix], [NONE]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([exec_prefix]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^exec_prefix$]) >+m4trace:configure.in:4: -1- AC_SUBST([prefix], [NONE]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([prefix]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^prefix$]) >+m4trace:configure.in:4: -1- AC_SUBST([program_transform_name], [s,x,x,]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([program_transform_name]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^program_transform_name$]) >+m4trace:configure.in:4: -1- AC_SUBST([bindir], ['${exec_prefix}/bin']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([bindir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^bindir$]) >+m4trace:configure.in:4: -1- AC_SUBST([sbindir], ['${exec_prefix}/sbin']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([sbindir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^sbindir$]) >+m4trace:configure.in:4: -1- AC_SUBST([libexecdir], ['${exec_prefix}/libexec']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([libexecdir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^libexecdir$]) >+m4trace:configure.in:4: -1- AC_SUBST([datarootdir], ['${prefix}/share']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([datarootdir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^datarootdir$]) >+m4trace:configure.in:4: -1- AC_SUBST([datadir], ['${datarootdir}']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([datadir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^datadir$]) >+m4trace:configure.in:4: -1- AC_SUBST([sysconfdir], ['${prefix}/etc']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([sysconfdir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^sysconfdir$]) >+m4trace:configure.in:4: -1- AC_SUBST([sharedstatedir], ['${prefix}/com']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([sharedstatedir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^sharedstatedir$]) >+m4trace:configure.in:4: -1- AC_SUBST([localstatedir], ['${prefix}/var']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([localstatedir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^localstatedir$]) >+m4trace:configure.in:4: -1- AC_SUBST([includedir], ['${prefix}/include']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([includedir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^includedir$]) >+m4trace:configure.in:4: -1- AC_SUBST([oldincludedir], ['/usr/include']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([oldincludedir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^oldincludedir$]) >+m4trace:configure.in:4: -1- AC_SUBST([docdir], [m4_ifset([AC_PACKAGE_TARNAME], >+ ['${datarootdir}/doc/${PACKAGE_TARNAME}'], >+ ['${datarootdir}/doc/${PACKAGE}'])]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([docdir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^docdir$]) >+m4trace:configure.in:4: -1- AC_SUBST([infodir], ['${datarootdir}/info']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([infodir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^infodir$]) >+m4trace:configure.in:4: -1- AC_SUBST([htmldir], ['${docdir}']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([htmldir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^htmldir$]) >+m4trace:configure.in:4: -1- AC_SUBST([dvidir], ['${docdir}']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([dvidir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^dvidir$]) >+m4trace:configure.in:4: -1- AC_SUBST([pdfdir], ['${docdir}']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([pdfdir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^pdfdir$]) >+m4trace:configure.in:4: -1- AC_SUBST([psdir], ['${docdir}']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([psdir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^psdir$]) >+m4trace:configure.in:4: -1- AC_SUBST([libdir], ['${exec_prefix}/lib']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([libdir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^libdir$]) >+m4trace:configure.in:4: -1- AC_SUBST([localedir], ['${datarootdir}/locale']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([localedir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^localedir$]) >+m4trace:configure.in:4: -1- AC_SUBST([mandir], ['${datarootdir}/man']) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([mandir]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^mandir$]) >+m4trace:configure.in:4: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_NAME]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_NAME$]) >+m4trace:configure.in:4: -1- AH_OUTPUT([PACKAGE_NAME], [/* Define to the full name of this package. */ >+@%:@undef PACKAGE_NAME]) >+m4trace:configure.in:4: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_TARNAME]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_TARNAME$]) >+m4trace:configure.in:4: -1- AH_OUTPUT([PACKAGE_TARNAME], [/* Define to the one symbol short name of this package. */ >+@%:@undef PACKAGE_TARNAME]) >+m4trace:configure.in:4: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_VERSION]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_VERSION$]) >+m4trace:configure.in:4: -1- AH_OUTPUT([PACKAGE_VERSION], [/* Define to the version of this package. */ >+@%:@undef PACKAGE_VERSION]) >+m4trace:configure.in:4: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_STRING]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_STRING$]) >+m4trace:configure.in:4: -1- AH_OUTPUT([PACKAGE_STRING], [/* Define to the full name and version of this package. */ >+@%:@undef PACKAGE_STRING]) >+m4trace:configure.in:4: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_BUGREPORT]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$]) >+m4trace:configure.in:4: -1- AH_OUTPUT([PACKAGE_BUGREPORT], [/* Define to the address where bug reports for this package should be sent. */ >+@%:@undef PACKAGE_BUGREPORT]) >+m4trace:configure.in:4: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_URL]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^PACKAGE_URL$]) >+m4trace:configure.in:4: -1- AH_OUTPUT([PACKAGE_URL], [/* Define to the home page for this package. */ >+@%:@undef PACKAGE_URL]) >+m4trace:configure.in:4: -1- AC_SUBST([DEFS]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([DEFS]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^DEFS$]) >+m4trace:configure.in:4: -1- AC_SUBST([ECHO_C]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([ECHO_C]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^ECHO_C$]) >+m4trace:configure.in:4: -1- AC_SUBST([ECHO_N]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([ECHO_N]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^ECHO_N$]) >+m4trace:configure.in:4: -1- AC_SUBST([ECHO_T]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([ECHO_T]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^ECHO_T$]) >+m4trace:configure.in:4: -1- AC_SUBST([LIBS]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([LIBS]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^LIBS$]) >+m4trace:configure.in:4: -1- AC_SUBST([build_alias]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([build_alias]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^build_alias$]) >+m4trace:configure.in:4: -1- AC_SUBST([host_alias]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([host_alias]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^host_alias$]) >+m4trace:configure.in:4: -1- AC_SUBST([target_alias]) >+m4trace:configure.in:4: -1- AC_SUBST_TRACE([target_alias]) >+m4trace:configure.in:4: -1- m4_pattern_allow([^target_alias$]) >+m4trace:configure.in:6: -1- AC_CONFIG_HEADERS([bgpdump-config.h]) >+m4trace:configure.in:13: -1- AC_SUBST([CC]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) >+m4trace:configure.in:13: -1- AC_SUBST([CFLAGS]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([CFLAGS]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^CFLAGS$]) >+m4trace:configure.in:13: -1- AC_SUBST([LDFLAGS]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([LDFLAGS]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^LDFLAGS$]) >+m4trace:configure.in:13: -1- AC_SUBST([LIBS]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([LIBS]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^LIBS$]) >+m4trace:configure.in:13: -1- AC_SUBST([CPPFLAGS]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([CPPFLAGS]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^CPPFLAGS$]) >+m4trace:configure.in:13: -1- AC_SUBST([CC]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) >+m4trace:configure.in:13: -1- AC_SUBST([CC]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) >+m4trace:configure.in:13: -1- AC_SUBST([CC]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) >+m4trace:configure.in:13: -1- AC_SUBST([CC]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) >+m4trace:configure.in:13: -1- AC_SUBST([ac_ct_CC]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([ac_ct_CC]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^ac_ct_CC$]) >+m4trace:configure.in:13: -1- AC_SUBST([EXEEXT], [$ac_cv_exeext]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([EXEEXT]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^EXEEXT$]) >+m4trace:configure.in:13: -1- AC_SUBST([OBJEXT], [$ac_cv_objext]) >+m4trace:configure.in:13: -1- AC_SUBST_TRACE([OBJEXT]) >+m4trace:configure.in:13: -1- m4_pattern_allow([^OBJEXT$]) >+m4trace:configure.in:14: -1- AC_SUBST([RANLIB]) >+m4trace:configure.in:14: -1- AC_SUBST_TRACE([RANLIB]) >+m4trace:configure.in:14: -1- m4_pattern_allow([^RANLIB$]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_ARPA_INET_H], [/* Define to 1 if you have the <arpa/inet.h> header file. */ >+@%:@undef HAVE_ARPA_INET_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_NETINET_IN_H], [/* Define to 1 if you have the <netinet/in.h> header file. */ >+@%:@undef HAVE_NETINET_IN_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_SYSLOG_H], [/* Define to 1 if you have the <syslog.h> header file. */ >+@%:@undef HAVE_SYSLOG_H]) >+m4trace:configure.in:17: -1- AC_SUBST([CPP]) >+m4trace:configure.in:17: -1- AC_SUBST_TRACE([CPP]) >+m4trace:configure.in:17: -1- m4_pattern_allow([^CPP$]) >+m4trace:configure.in:17: -1- AC_SUBST([CPPFLAGS]) >+m4trace:configure.in:17: -1- AC_SUBST_TRACE([CPPFLAGS]) >+m4trace:configure.in:17: -1- m4_pattern_allow([^CPPFLAGS$]) >+m4trace:configure.in:17: -1- AC_SUBST([CPP]) >+m4trace:configure.in:17: -1- AC_SUBST_TRACE([CPP]) >+m4trace:configure.in:17: -1- m4_pattern_allow([^CPP$]) >+m4trace:configure.in:17: -1- AC_SUBST([GREP]) >+m4trace:configure.in:17: -1- AC_SUBST_TRACE([GREP]) >+m4trace:configure.in:17: -1- m4_pattern_allow([^GREP$]) >+m4trace:configure.in:17: -1- AC_SUBST([EGREP]) >+m4trace:configure.in:17: -1- AC_SUBST_TRACE([EGREP]) >+m4trace:configure.in:17: -1- m4_pattern_allow([^EGREP$]) >+m4trace:configure.in:17: -1- AC_DEFINE_TRACE_LITERAL([STDC_HEADERS]) >+m4trace:configure.in:17: -1- m4_pattern_allow([^STDC_HEADERS$]) >+m4trace:configure.in:17: -1- AH_OUTPUT([STDC_HEADERS], [/* Define to 1 if you have the ANSI C header files. */ >+@%:@undef STDC_HEADERS]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_SYS_TYPES_H], [/* Define to 1 if you have the <sys/types.h> header file. */ >+@%:@undef HAVE_SYS_TYPES_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_SYS_STAT_H], [/* Define to 1 if you have the <sys/stat.h> header file. */ >+@%:@undef HAVE_SYS_STAT_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_STDLIB_H], [/* Define to 1 if you have the <stdlib.h> header file. */ >+@%:@undef HAVE_STDLIB_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_STRING_H], [/* Define to 1 if you have the <string.h> header file. */ >+@%:@undef HAVE_STRING_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_MEMORY_H], [/* Define to 1 if you have the <memory.h> header file. */ >+@%:@undef HAVE_MEMORY_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_STRINGS_H], [/* Define to 1 if you have the <strings.h> header file. */ >+@%:@undef HAVE_STRINGS_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_INTTYPES_H], [/* Define to 1 if you have the <inttypes.h> header file. */ >+@%:@undef HAVE_INTTYPES_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_STDINT_H], [/* Define to 1 if you have the <stdint.h> header file. */ >+@%:@undef HAVE_STDINT_H]) >+m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_UNISTD_H], [/* Define to 1 if you have the <unistd.h> header file. */ >+@%:@undef HAVE_UNISTD_H]) >+m4trace:configure.in:18: -1- AC_DEFINE_TRACE_LITERAL([TM_IN_SYS_TIME]) >+m4trace:configure.in:18: -1- m4_pattern_allow([^TM_IN_SYS_TIME$]) >+m4trace:configure.in:18: -1- AH_OUTPUT([TM_IN_SYS_TIME], [/* Define to 1 if your <sys/time.h> declares `struct tm\'. */ >+@%:@undef TM_IN_SYS_TIME]) >+m4trace:configure.in:21: -2- AC_DEFINE_TRACE_LITERAL([u_char_t]) >+m4trace:configure.in:21: -2- m4_pattern_allow([^u_char_t$]) >+m4trace:configure.in:21: -2- AH_OUTPUT([u_char_t], [/* Define if system headers do not define u_char_t */ >+@%:@undef u_char_t]) >+m4trace:configure.in:22: -2- AC_DEFINE_TRACE_LITERAL([u_int8_t]) >+m4trace:configure.in:22: -2- m4_pattern_allow([^u_int8_t$]) >+m4trace:configure.in:22: -2- AH_OUTPUT([u_int8_t], [/* Define if system headers do not define u_int8_t */ >+@%:@undef u_int8_t]) >+m4trace:configure.in:23: -2- AC_DEFINE_TRACE_LITERAL([u_int16_t]) >+m4trace:configure.in:23: -2- m4_pattern_allow([^u_int16_t$]) >+m4trace:configure.in:23: -2- AH_OUTPUT([u_int16_t], [/* Define if system headers do not define u_int16_t */ >+@%:@undef u_int16_t]) >+m4trace:configure.in:24: -2- AC_DEFINE_TRACE_LITERAL([u_int32_t]) >+m4trace:configure.in:24: -2- m4_pattern_allow([^u_int32_t$]) >+m4trace:configure.in:24: -2- AH_OUTPUT([u_int32_t], [/* Define if system headers do not define u_int32_t */ >+@%:@undef u_int32_t]) >+m4trace:configure.in:26: -2- AC_DEFINE_TRACE_LITERAL([DONT_HAVE_GZ]) >+m4trace:configure.in:26: -2- m4_pattern_allow([^DONT_HAVE_GZ$]) >+m4trace:configure.in:26: -2- AH_OUTPUT([DONT_HAVE_GZ], [/* Define if libz not present */ >+@%:@undef DONT_HAVE_GZ]) >+m4trace:configure.in:26: -1- AH_OUTPUT([HAVE_LIBZ], [/* Define to 1 if you have the `z\' library (-lz). */ >+@%:@undef HAVE_LIBZ]) >+m4trace:configure.in:26: -1- AC_DEFINE_TRACE_LITERAL([HAVE_LIBZ]) >+m4trace:configure.in:26: -1- m4_pattern_allow([^HAVE_LIBZ$]) >+m4trace:configure.in:27: -2- AC_DEFINE_TRACE_LITERAL([DONT_HAVE_BZ2]) >+m4trace:configure.in:27: -2- m4_pattern_allow([^DONT_HAVE_BZ2$]) >+m4trace:configure.in:27: -2- AH_OUTPUT([DONT_HAVE_BZ2], [/* Define if libbzip2 not present */ >+@%:@undef DONT_HAVE_BZ2]) >+m4trace:configure.in:27: -1- AH_OUTPUT([HAVE_LIBBZ2], [/* Define to 1 if you have the `bz2\' library (-lbz2). */ >+@%:@undef HAVE_LIBBZ2]) >+m4trace:configure.in:27: -1- AC_DEFINE_TRACE_LITERAL([HAVE_LIBBZ2]) >+m4trace:configure.in:27: -1- m4_pattern_allow([^HAVE_LIBBZ2$]) >+m4trace:configure.in:30: -2- AH_OUTPUT([HAVE_LIBNSL], [/* Define to 1 if you have the `nsl\' library (-lnsl). */ >+@%:@undef HAVE_LIBNSL]) >+m4trace:configure.in:30: -2- AC_DEFINE_TRACE_LITERAL([HAVE_LIBNSL]) >+m4trace:configure.in:30: -2- m4_pattern_allow([^HAVE_LIBNSL$]) >+m4trace:configure.in:30: -1- AH_OUTPUT([HAVE_INET_NTOA], [/* Define to 1 if you have the `inet_ntoa\' function. */ >+@%:@undef HAVE_INET_NTOA]) >+m4trace:configure.in:30: -1- AC_DEFINE_TRACE_LITERAL([HAVE_INET_NTOA]) >+m4trace:configure.in:30: -1- m4_pattern_allow([^HAVE_INET_NTOA$]) >+m4trace:configure.in:31: -2- AH_OUTPUT([HAVE_LIBNSL], [/* Define to 1 if you have the `nsl\' library (-lnsl). */ >+@%:@undef HAVE_LIBNSL]) >+m4trace:configure.in:31: -2- AC_DEFINE_TRACE_LITERAL([HAVE_LIBNSL]) >+m4trace:configure.in:31: -2- m4_pattern_allow([^HAVE_LIBNSL$]) >+m4trace:configure.in:31: -1- AH_OUTPUT([HAVE_INET_NTOP], [/* Define to 1 if you have the `inet_ntop\' function. */ >+@%:@undef HAVE_INET_NTOP]) >+m4trace:configure.in:31: -1- AC_DEFINE_TRACE_LITERAL([HAVE_INET_NTOP]) >+m4trace:configure.in:31: -1- m4_pattern_allow([^HAVE_INET_NTOP$]) >+m4trace:configure.in:38: -1- AC_SUBST([CFLAGS]) >+m4trace:configure.in:38: -1- AC_SUBST_TRACE([CFLAGS]) >+m4trace:configure.in:38: -1- m4_pattern_allow([^CFLAGS$]) >+m4trace:configure.in:39: -1- AC_SUBST([LIBS]) >+m4trace:configure.in:39: -1- AC_SUBST_TRACE([LIBS]) >+m4trace:configure.in:39: -1- m4_pattern_allow([^LIBS$]) >+m4trace:configure.in:41: -1- AC_CONFIG_FILES([bgpdump.spec Makefile]) >+m4trace:configure.in:41: -1- _m4_warn([obsolete], [AC_OUTPUT should be used without arguments. >+You should run autoupdate.], []) >+m4trace:configure.in:41: -1- AC_SUBST([LIB@&t@OBJS], [$ac_libobjs]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([LIB@&t@OBJS]) >+m4trace:configure.in:41: -1- m4_pattern_allow([^LIB@&t@OBJS$]) >+m4trace:configure.in:41: -1- AC_SUBST([LTLIBOBJS], [$ac_ltlibobjs]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([LTLIBOBJS]) >+m4trace:configure.in:41: -1- m4_pattern_allow([^LTLIBOBJS$]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([top_builddir]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([top_build_prefix]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([srcdir]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([abs_srcdir]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([top_srcdir]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([abs_top_srcdir]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([builddir]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([abs_builddir]) >+m4trace:configure.in:41: -1- AC_SUBST_TRACE([abs_top_builddir]) >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump-config.h libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump-config.h >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump-config.h 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump-config.h 2015-09-16 20:23:15.000000000 +1200 >@@ -0,0 +1,95 @@ >+/* bgpdump-config.h. Generated from bgpdump-config.h.in by configure. */ >+/* bgpdump-config.h.in. Generated from configure.in by autoheader. */ >+ >+/* Define if libbzip2 not present */ >+/* #undef DONT_HAVE_BZ2 */ >+ >+/* Define if libz not present */ >+/* #undef DONT_HAVE_GZ */ >+ >+/* Define to 1 if you have the <arpa/inet.h> header file. */ >+#define HAVE_ARPA_INET_H 1 >+ >+/* Define to 1 if you have the `inet_ntoa' function. */ >+#define HAVE_INET_NTOA 1 >+ >+/* Define to 1 if you have the `inet_ntop' function. */ >+#define HAVE_INET_NTOP 1 >+ >+/* Define to 1 if you have the <inttypes.h> header file. */ >+#define HAVE_INTTYPES_H 1 >+ >+/* Define to 1 if you have the `bz2' library (-lbz2). */ >+#define HAVE_LIBBZ2 1 >+ >+/* Define to 1 if you have the `nsl' library (-lnsl). */ >+/* #undef HAVE_LIBNSL */ >+ >+/* Define to 1 if you have the `z' library (-lz). */ >+#define HAVE_LIBZ 1 >+ >+/* Define to 1 if you have the <memory.h> header file. */ >+#define HAVE_MEMORY_H 1 >+ >+/* Define to 1 if you have the <netinet/in.h> header file. */ >+#define HAVE_NETINET_IN_H 1 >+ >+/* Define to 1 if you have the <stdint.h> header file. */ >+#define HAVE_STDINT_H 1 >+ >+/* Define to 1 if you have the <stdlib.h> header file. */ >+#define HAVE_STDLIB_H 1 >+ >+/* Define to 1 if you have the <strings.h> header file. */ >+#define HAVE_STRINGS_H 1 >+ >+/* Define to 1 if you have the <string.h> header file. */ >+#define HAVE_STRING_H 1 >+ >+/* Define to 1 if you have the <syslog.h> header file. */ >+#define HAVE_SYSLOG_H 1 >+ >+/* Define to 1 if you have the <sys/stat.h> header file. */ >+#define HAVE_SYS_STAT_H 1 >+ >+/* Define to 1 if you have the <sys/types.h> header file. */ >+#define HAVE_SYS_TYPES_H 1 >+ >+/* Define to 1 if you have the <unistd.h> header file. */ >+#define HAVE_UNISTD_H 1 >+ >+/* Define to the address where bug reports for this package should be sent. */ >+#define PACKAGE_BUGREPORT "ris@ripe.net" >+ >+/* Define to the full name of this package. */ >+#define PACKAGE_NAME "libbgpdump" >+ >+/* Define to the full name and version of this package. */ >+#define PACKAGE_STRING "libbgpdump 1.4.99.15" >+ >+/* Define to the one symbol short name of this package. */ >+#define PACKAGE_TARNAME "libbgpdump" >+ >+/* Define to the home page for this package. */ >+#define PACKAGE_URL "" >+ >+/* Define to the version of this package. */ >+#define PACKAGE_VERSION "1.4.99.15" >+ >+/* Define to 1 if you have the ANSI C header files. */ >+#define STDC_HEADERS 1 >+ >+/* Define to 1 if your <sys/time.h> declares `struct tm'. */ >+/* #undef TM_IN_SYS_TIME */ >+ >+/* Define if system headers do not define u_char_t */ >+#define u_char_t uchar_t >+ >+/* Define if system headers do not define u_int16_t */ >+/* #undef u_int16_t */ >+ >+/* Define if system headers do not define u_int32_t */ >+/* #undef u_int32_t */ >+ >+/* Define if system headers do not define u_int8_t */ >+/* #undef u_int8_t */ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump-config.h.in libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump-config.h.in >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump-config.h.in 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump-config.h.in 2015-09-16 20:22:47.000000000 +1200 >@@ -0,0 +1,94 @@ >+/* bgpdump-config.h.in. Generated from configure.in by autoheader. */ >+ >+/* Define if libbzip2 not present */ >+#undef DONT_HAVE_BZ2 >+ >+/* Define if libz not present */ >+#undef DONT_HAVE_GZ >+ >+/* Define to 1 if you have the <arpa/inet.h> header file. */ >+#undef HAVE_ARPA_INET_H >+ >+/* Define to 1 if you have the `inet_ntoa' function. */ >+#undef HAVE_INET_NTOA >+ >+/* Define to 1 if you have the `inet_ntop' function. */ >+#undef HAVE_INET_NTOP >+ >+/* Define to 1 if you have the <inttypes.h> header file. */ >+#undef HAVE_INTTYPES_H >+ >+/* Define to 1 if you have the `bz2' library (-lbz2). */ >+#undef HAVE_LIBBZ2 >+ >+/* Define to 1 if you have the `nsl' library (-lnsl). */ >+#undef HAVE_LIBNSL >+ >+/* Define to 1 if you have the `z' library (-lz). */ >+#undef HAVE_LIBZ >+ >+/* Define to 1 if you have the <memory.h> header file. */ >+#undef HAVE_MEMORY_H >+ >+/* Define to 1 if you have the <netinet/in.h> header file. */ >+#undef HAVE_NETINET_IN_H >+ >+/* Define to 1 if you have the <stdint.h> header file. */ >+#undef HAVE_STDINT_H >+ >+/* Define to 1 if you have the <stdlib.h> header file. */ >+#undef HAVE_STDLIB_H >+ >+/* Define to 1 if you have the <strings.h> header file. */ >+#undef HAVE_STRINGS_H >+ >+/* Define to 1 if you have the <string.h> header file. */ >+#undef HAVE_STRING_H >+ >+/* Define to 1 if you have the <syslog.h> header file. */ >+#undef HAVE_SYSLOG_H >+ >+/* Define to 1 if you have the <sys/stat.h> header file. */ >+#undef HAVE_SYS_STAT_H >+ >+/* Define to 1 if you have the <sys/types.h> header file. */ >+#undef HAVE_SYS_TYPES_H >+ >+/* Define to 1 if you have the <unistd.h> header file. */ >+#undef HAVE_UNISTD_H >+ >+/* Define to the address where bug reports for this package should be sent. */ >+#undef PACKAGE_BUGREPORT >+ >+/* Define to the full name of this package. */ >+#undef PACKAGE_NAME >+ >+/* Define to the full name and version of this package. */ >+#undef PACKAGE_STRING >+ >+/* Define to the one symbol short name of this package. */ >+#undef PACKAGE_TARNAME >+ >+/* Define to the home page for this package. */ >+#undef PACKAGE_URL >+ >+/* Define to the version of this package. */ >+#undef PACKAGE_VERSION >+ >+/* Define to 1 if you have the ANSI C header files. */ >+#undef STDC_HEADERS >+ >+/* Define to 1 if your <sys/time.h> declares `struct tm'. */ >+#undef TM_IN_SYS_TIME >+ >+/* Define if system headers do not define u_char_t */ >+#undef u_char_t >+ >+/* Define if system headers do not define u_int16_t */ >+#undef u_int16_t >+ >+/* Define if system headers do not define u_int32_t */ >+#undef u_int32_t >+ >+/* Define if system headers do not define u_int8_t */ >+#undef u_int8_t >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump.c libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump.c >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump.c 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump.c 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,1738 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+Parts of this code have been engineered after analiyzing GNU Zebra's >+source code and therefore might contain declarations/code from GNU >+Zebra, Copyright (C) 1999 Kunihiro Ishiguro. Zebra is a free routing >+software, distributed under the GNU General Public License. A copy of >+this license is included with libbgpdump. >+ >+Original Author: Shufu Mao(msf98@mails.tsinghua.edu.cn) >+*/ >+ >+#include "bgpdump-config.h" >+#include "bgpdump_lib.h" >+#include "util.h" >+ >+#include <time.h> >+#include <unistd.h> >+#include <fcntl.h> >+#include <stdlib.h> >+#include <netinet/in.h> >+#include <sys/socket.h> >+#include <arpa/inet.h> >+#include <stdbool.h> >+ >+static void process(BGPDUMP_ENTRY *entry); >+static void process_bgpdump_mrtd_bgp(BGPDUMP_ENTRY *entry); >+static void show_ipv4_address(struct in_addr ip); >+static void show_attr(attributes_t *attr); >+static void show_prefixes(int count,struct prefix *prefix); >+static void table_line_announce_1(struct mp_nlri *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str); >+static void table_line_announce(struct prefix *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str); >+static void mrtd_table_line_withdraw(struct prefix *prefix, int count, BGPDUMP_ENTRY *entry, char *time_str); >+static void mrtd_table_line_announce(struct prefix *prefix, int count, BGPDUMP_ENTRY *entry, char *time_str); >+static void table_line_withdraw(struct prefix *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str); >+static void table_line_mrtd_route(BGPDUMP_MRTD_TABLE_DUMP *route,BGPDUMP_ENTRY *entry); >+static void table_line_dump_v2_prefix(BGPDUMP_TABLE_DUMP_V2_PREFIX *e,BGPDUMP_ENTRY *entry); >+static char *describe_origin(int origin); >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ void show_prefixes6(int count,struct prefix *prefix); >+ static void table_line_withdraw6(struct prefix *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str); >+ static void table_line_announce6(struct mp_nlri *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str); >+#endif >+ >+static void show_line_prefix(const char* format, long long ts, const char* time_str, const char* type); >+ >+/* If no aspath was present as a string in the packet, return an empty string >+ * so everything stays machine parsable */ >+static char *attr_aspath(attributes_t *a) { >+ if(a->flag & ATTR_FLAG_BIT(BGP_ATTR_AS_PATH) && a->aspath && a->aspath->str) { >+ return a->aspath->str; >+ } >+ return ""; >+} >+ >+static int mode=0; >+static int timetype=0; >+static int show_packet_index = 0; >+static int packet_index = 0; >+ >+static const char USAGE[] = "\ >+bgpdump version " PACKAGE_VERSION "\n\ >+Usage: bgpdump [-m|-M] [-t dump|-t change] [-O <output-file>] <input-file>\n\ >+bgpdump translates binary MRT files (possibly compressed) into readable output\n\ >+Output mode:\n\ >+ -H multi-line, human-readable (the default)\n\ >+ -m one-line per entry with unix timestamps\n\ >+ -M one-line per entry with human readable timestamps\n\ >+ (there are other differences between -m and -M)\n\ >+\n\ >+Common options:\n\ >+ -O <file> output to <file> instead of STDOUT\n\ >+ -s log to syslog (the default)\n\ >+ -v log to STDERR\n\ >+\n\ >+Options for -m and -M modes:\n\ >+ -t dump timestamps for RIB dumps reflect the time of the dump (the default)\n\ >+ -t change timestamps for RIB dumps reflect the last route modification\n\ >+ -p show packet index at second position\n\ >+\n\ >+Special options:\n\ >+ -T run unit tests and exit\n\ >+\n"; >+ >+extern char *optarg; >+extern int optind; >+ >+int main(int argc, char *argv[]) { >+ >+ char c; >+ int fd; >+ bool usage_error = false; >+ bool use_syslog = true; >+ >+ log_to_stderr(); >+ >+ while ((c=getopt(argc,argv,"if:o:t:mMHO:svTp"))!=-1) >+ switch(c) >+ { >+ case 'H': >+ mode=0; >+ break; >+ case 'm': >+ mode=1; >+ break; >+ case 'M': >+ mode=2; >+ break; >+ case 't': >+ if(strcmp(optarg,"dump")==0){ >+ timetype=0; >+ } else if(strcmp(optarg,"change")==0){ >+ timetype=1; >+ } else { >+ printf("unknown -t option\n"); >+ exit(1); >+ } >+ break; >+ case 'O': >+ fprintf(stderr, "redirecting output to '%s'\n", optarg); >+ fd = open(optarg, O_WRONLY|O_CREAT, 0666); >+ if(fd < 0 || 0 > dup2(fd, STDOUT_FILENO)) { >+ perror("can't open output file"); >+ exit(1); >+ } >+ break; >+ case 's': >+ use_syslog = true; >+ break; >+ case 'v': >+ use_syslog = false; >+ break; >+ case 'i': >+ case 'f': >+ case 'o': >+ warn("ignoring option '-%c'", c); >+ break; >+ case 'T': >+ test_fmt_ip(); >+ test_utils(); >+ exit(0); >+ case 'p': >+ show_packet_index = 1; >+ break; >+ case '?': >+ default: >+ usage_error = true; >+ } >+ argc -= optind; >+ argv += optind; >+ >+ if(use_syslog) { >+ debug("logging to syslog"); >+ log_to_syslog(); >+ } >+ >+ if(usage_error || argc != 1) { >+ if(argc != 1) >+ err("you must supply exactly one file to process"); >+ fprintf(stderr, "%s", USAGE); >+ exit(1); >+ } >+ >+ // more efficient then line buffering >+ // static char buffer[16000]; >+ // setbuffer(stdout, buffer, sizeof buffer); >+ >+ BGPDUMP *my_dump = bgpdump_open_dump(argv[0]); >+ if(! my_dump) >+ return 1; >+ >+ do { >+ BGPDUMP_ENTRY *my_entry = bgpdump_read_next(my_dump); >+ if(my_entry) { >+ process(my_entry); >+ bgpdump_free_mem(my_entry); >+ packet_index++; >+ } >+ } while(my_dump->eof==0); >+ >+ bgpdump_close_dump(my_dump); >+ >+ return 0; >+} >+ >+const char *bgp_state_name[] = { >+ "Unknown", >+ "Idle", >+ "Connect", >+ "Active", >+ "Opensent", >+ "Openconfirm", >+ "Established", >+ NULL >+}; >+ >+void process(BGPDUMP_ENTRY *entry) { >+ >+ struct tm *date; >+ char time_str[128]; >+ char time_str2[128]; >+ char time_str_fixed[128]; >+ char prefix[BGPDUMP_ADDRSTRLEN]; >+ >+ date=gmtime(&entry->time); >+ time2str(date,time_str); >+ time2str(date,time_str_fixed); >+ if (mode==0) >+ { >+ printf("TIME: %s\n", time_str); >+ } >+ //printf("TIME: %s",asctime(gmtime(&entry->time))); >+ //printf("LENGTH : %u\n", entry->length); >+ switch(entry->type) { >+ case BGPDUMP_TYPE_MRTD_TABLE_DUMP: >+ if(mode==0){ >+ const char *prefix_str = NULL; >+ switch(entry->subtype){ >+#ifdef BGPDUMP_HAVE_IPV6 >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6: >+ printf("TYPE: TABLE_DUMP/INET6\n"); >+ prefix_str = fmt_ipv6(entry->body.mrtd_table_dump.prefix,prefix); >+ break; >+ >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6_32BIT_AS: >+ printf("TYPE: TABLE_DUMP/INET6_32BIT_AS\n"); >+ prefix_str = fmt_ipv6(entry->body.mrtd_table_dump.prefix,prefix); >+ break; >+ >+#endif >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP: >+ printf("TYPE: TABLE_DUMP/INET\n"); >+ prefix_str = inet_ntoa(entry->body.mrtd_table_dump.prefix.v4_addr); >+ break; >+ >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP_32BIT_AS: >+ printf("TYPE: TABLE_DUMP/INET_32BIT_AS\n"); >+ prefix_str = inet_ntoa(entry->body.mrtd_table_dump.prefix.v4_addr); >+ break; >+ >+ default: >+ printf("Error: unknown table type %d\n", entry->subtype); >+ return; >+ >+ } >+ printf("VIEW: %d\n",entry->body.mrtd_table_dump.view); >+ printf("SEQUENCE: %d\n",entry->body.mrtd_table_dump.sequence); >+ printf("PREFIX: %s/%d\n",prefix_str,entry->body.mrtd_table_dump.mask); >+ printf("FROM:"); >+ switch(entry->subtype) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6: >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6_32BIT_AS: >+ >+ fmt_ipv6(entry->body.mrtd_table_dump.peer_ip,prefix); >+ printf("%s ",prefix); >+ break; >+#endif >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP: >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP_32BIT_AS: >+ if (entry->body.mrtd_table_dump.peer_ip.v4_addr.s_addr != 0x00000000L) >+ printf("%s ",inet_ntoa(entry->body.mrtd_table_dump.peer_ip.v4_addr)); >+ else >+ printf("N/A "); >+ >+ } >+ printf("AS%u\n",entry->body.mrtd_table_dump.peer_as); >+ >+ //printf("FROM: %s AS%d\n",inet_ntoa(entry->body.mrtd_table_dump.peer_ip.v4_addr),entry->body.mrtd_table_dump.peer_as); >+ //time2str(localtime(&entry->body.mrtd_table_dump.uptime),time_str2); >+ time2str(gmtime(&entry->body.mrtd_table_dump.uptime),time_str2); >+ printf("ORIGINATED: %s\n",time_str2); >+ if (entry->attr && entry->attr->len) >+ show_attr(entry->attr); >+ >+ printf("STATUS: 0x%x\n",entry->body.mrtd_table_dump.status); >+ >+ >+ //printf(" UPTIME : %s",asctime(gmtime(&entry->body.mrtd_table_dump.uptime))); >+ //printf(" PEER IP : %s\n",inet_ntoa(entry->body.mrtd_table_dump.peer_ip)); >+ //printf(" PEER IP : %s\n",inet_ntoa(entry->body.mrtd_table_dump.peer_ip.v4_addr)); >+ //printf(" PEER AS : %d\n",entry->body.mrtd_table_dump.peer_as); >+ } >+ else if (mode ==1 || mode ==2) // -m -M >+ { >+ table_line_mrtd_route(&entry->body.mrtd_table_dump,entry); >+ } >+ break; >+ >+ case BGPDUMP_TYPE_TABLE_DUMP_V2: >+ if(mode == 0){ >+ char peer_ip[BGPDUMP_ADDRSTRLEN]; >+ //char time_str[30]; >+ int i; >+ >+ BGPDUMP_TABLE_DUMP_V2_PREFIX *e; >+ e = &entry->body.mrtd_table_dump_v2_prefix; >+ >+ if(e->afi == AFI_IP){ >+ strncpy(prefix, inet_ntoa(e->prefix.v4_addr), BGPDUMP_ADDRSTRLEN); >+#ifdef BGPDUMP_HAVE_IPV6 >+ } else if(e->afi == AFI_IP6){ >+ fmt_ipv6(e->prefix, prefix); >+#endif >+ } >+ >+ for(i = 0; i < e->entry_count; i++){ >+ // This is slightly nasty - as we want to print multiple entries >+ // for multiple peers, we may need to print another TIME ourselves >+ if(i) printf("\nTIME: %s\n",time_str_fixed); >+ if(e->afi == AFI_IP){ >+ printf("TYPE: TABLE_DUMP_V2/IPV4_UNICAST\n"); >+#ifdef BGPDUMP_HAVE_IPV6 >+ } else if(e->afi == AFI_IP6){ >+ printf("TYPE: TABLE_DUMP_V2/IPV6_UNICAST\n"); >+#endif >+ } >+ printf("PREFIX: %s/%d\n",prefix, e->prefix_length); >+ printf("SEQUENCE: %d\n",e->seq); >+ >+ if(e->entries[i].peer->afi == AFI_IP){ >+ fmt_ipv4(e->entries[i].peer->peer_ip, peer_ip); >+#ifdef BGPDUMP_HAVE_IPV6 >+ } else if (e->entries[i].peer->afi == AFI_IP6){ >+ fmt_ipv6(e->entries[i].peer->peer_ip, peer_ip); >+#endif >+ } else { >+ sprintf(peer_ip, "[N/A, unsupported AF]"); >+ } >+ printf("FROM: %s AS%u\n", peer_ip, e->entries[i].peer->peer_as); >+ time_t time_temp = (time_t)((e->entries[i]).originated_time); >+ time2str(gmtime(&time_temp),time_str); >+ printf("ORIGINATED: %s\n",time_str); >+ if (e->entries[i].attr && e->entries[i].attr->len) >+ show_attr(e->entries[i].attr); >+ } >+ } else if (mode==1 || mode==2) { // -m -M >+ table_line_dump_v2_prefix(&entry->body.mrtd_table_dump_v2_prefix,entry); >+ } >+ break; >+ >+ case BGPDUMP_TYPE_MRTD_BGP: >+ process_bgpdump_mrtd_bgp(entry); >+ break; >+ >+ case BGPDUMP_TYPE_ZEBRA_BGP: >+ >+ switch(entry->subtype) >+ { >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE: >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE_AS4: >+ >+ switch(entry->body.zebra_message.type) >+ { >+ case BGP_MSG_UPDATE: >+ if (mode ==0) >+ { >+ printf("TYPE: BGP4MP/MESSAGE/Update\n"); >+ if (entry->body.zebra_message.source_as) >+ { >+ printf("FROM:"); >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ >+ fmt_ipv6(entry->body.zebra_message.source_ip,prefix); >+ printf(" %s ",prefix); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ if (entry->body.zebra_message.source_ip.v4_addr.s_addr != 0x00000000L) >+ printf(" %s ",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr)); >+ else >+ printf(" N/A "); >+ } >+ printf("AS%u\n",entry->body.zebra_message.source_as); >+ } >+ if (entry->body.zebra_message.destination_as) >+ { >+ printf("TO:"); >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ >+ fmt_ipv6(entry->body.zebra_message.destination_ip,prefix); >+ printf(" %s ",prefix); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ if (entry->body.zebra_message.destination_ip.v4_addr.s_addr != 0x00000000L) >+ printf(" %s ",inet_ntoa(entry->body.zebra_message.destination_ip.v4_addr)); >+ else >+ printf(" N/A "); >+ } >+ printf("AS%u\n",entry->body.zebra_message.destination_as); >+ } >+ if (entry->attr && entry->attr->len) >+ show_attr(entry->attr); >+ if (entry->body.zebra_message.cut_bytes) >+ { >+ u_int16_t cutted,idx; >+ u_int8_t buf[128]; >+ >+ printf(" INCOMPLETE PACKET: %d bytes cutted\n",entry->body.zebra_message.cut_bytes); >+ printf(" INCOMPLETE PART: "); >+ if (entry->body.zebra_message.incomplete.orig_len) >+ { >+ cutted=entry->body.zebra_message.incomplete.prefix.len/8+1; >+ buf[0]=entry->body.zebra_message.incomplete.orig_len; >+ memcpy(buf+1,&entry->body.zebra_message.incomplete.prefix.address,cutted-1); >+ >+ for (idx=0;idx<cutted;idx++) >+ { >+ if (buf[idx]<0x10) >+ printf("0%x ",buf[idx]); >+ else >+ printf("%x ",buf[idx]); >+ } >+ } >+ printf("\n"); >+ } >+ if(! entry->attr) >+ return; >+ if ((entry->body.zebra_message.withdraw_count) || (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_UNREACH_NLRI))) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ if ((entry->body.zebra_message.withdraw_count)||(entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST]->prefix_count) || (entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST]->prefix_count) || (entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count) ||(entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST] && entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST]->prefix_count) || (entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST]->prefix_count) || (entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST]->prefix_count) ) >+ >+#else >+ if ((entry->body.zebra_message.withdraw_count)||(entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST]->prefix_count) || (entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST]->prefix_count) || (entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count)) >+ >+#endif >+ printf("WITHDRAW\n"); >+ if (entry->body.zebra_message.withdraw_count) >+ show_prefixes(entry->body.zebra_message.withdraw_count,entry->body.zebra_message.withdraw); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST]->prefix_count) >+ show_prefixes(entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST]->prefix_count,entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST]->nlri); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST]->prefix_count) >+ show_prefixes(entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST]->prefix_count,entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST]->nlri); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count) >+ show_prefixes(entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count,entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST]->nlri); >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ if (entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST] && entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST]->prefix_count) >+ show_prefixes6(entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST]->prefix_count,entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST]->nlri); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST]->prefix_count) >+ show_prefixes6(entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST]->prefix_count,entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST]->nlri); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST]->prefix_count) >+ show_prefixes6(entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST]->prefix_count,entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST]->nlri); >+#endif >+ } >+ if ( (entry->body.zebra_message.announce_count) || (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_REACH_NLRI))) >+ { >+ printf("ANNOUNCE\n"); >+ if (entry->body.zebra_message.announce_count) >+ show_prefixes(entry->body.zebra_message.announce_count,entry->body.zebra_message.announce); >+ >+ if (entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST] && entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST]->prefix_count) >+ show_prefixes(entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST]->prefix_count,entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST]->nlri); >+ >+ if (entry->attr->mp_info->announce[AFI_IP][SAFI_MULTICAST] && entry->attr->mp_info->announce[AFI_IP][SAFI_MULTICAST]->prefix_count) >+ show_prefixes(entry->attr->mp_info->announce[AFI_IP][SAFI_MULTICAST]->prefix_count,entry->attr->mp_info->announce[AFI_IP][SAFI_MULTICAST]->nlri); >+ >+ if (entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count) >+ show_prefixes(entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count,entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST]->nlri); >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ if (entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST] && entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->prefix_count) >+ show_prefixes6(entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->prefix_count,entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->nlri); >+ >+ if (entry->attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST] && entry->attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST]->prefix_count) >+ show_prefixes6(entry->attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST]->prefix_count,entry->attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST]->nlri); >+ >+ if (entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST]->prefix_count) >+ show_prefixes6(entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST]->prefix_count,entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST]->nlri); >+#endif >+ } >+ } >+ else if (mode == 1 || mode == 2) //-m -M >+ { >+ if ((entry->body.zebra_message.withdraw_count) || (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_UNREACH_NLRI))) >+ { >+ >+ table_line_withdraw(entry->body.zebra_message.withdraw,entry->body.zebra_message.withdraw_count,entry,time_str); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST]->prefix_count) >+ table_line_withdraw(entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST]->nlri,entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST]->prefix_count,entry,time_str); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST]->prefix_count) >+ table_line_withdraw(entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST]->nlri,entry->attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST]->prefix_count,entry,time_str); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count) >+ table_line_withdraw(entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST]->nlri,entry->attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count,entry,time_str); >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ if (entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST] && entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST]->prefix_count) >+ table_line_withdraw6(entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST]->nlri,entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST]->prefix_count,entry,time_str); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST]->prefix_count) >+ table_line_withdraw6(entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST]->nlri,entry->attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST]->prefix_count,entry,time_str); >+ >+ if (entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST]->prefix_count) >+ table_line_withdraw6(entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST]->nlri,entry->attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST]->prefix_count,entry,time_str); >+#endif >+ >+ } >+ if ( (entry->body.zebra_message.announce_count) || (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_REACH_NLRI))) >+ { >+ table_line_announce(entry->body.zebra_message.announce,entry->body.zebra_message.announce_count,entry,time_str); >+ if (entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST] && entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST]->prefix_count) >+ table_line_announce_1(entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST],entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST]->prefix_count,entry,time_str); >+ if (entry->attr->mp_info->announce[AFI_IP][SAFI_MULTICAST] && entry->attr->mp_info->announce[AFI_IP][SAFI_MULTICAST]->prefix_count) >+ table_line_announce_1(entry->attr->mp_info->announce[AFI_IP][SAFI_MULTICAST],entry->attr->mp_info->announce[AFI_IP][SAFI_MULTICAST]->prefix_count,entry,time_str); >+ if (entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count) >+ table_line_announce_1(entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST],entry->attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST]->prefix_count,entry,time_str); >+#ifdef BGPDUMP_HAVE_IPV6 >+ if (entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST] && entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->prefix_count) >+ table_line_announce6(entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST],entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->prefix_count,entry,time_str); >+ if (entry->attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST] && entry->attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST]->prefix_count) >+ table_line_announce6(entry->attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST],entry->attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST]->prefix_count,entry,time_str); >+ if (entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST] && entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST]->prefix_count) >+ table_line_announce6(entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST],entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST]->prefix_count,entry,time_str); >+#endif >+ >+ } >+ } >+ break; >+ >+ case BGP_MSG_OPEN: >+ if (mode != 0) >+ break; >+ printf("TYPE: BGP4MP/MESSAGE/Open\n"); >+ if (entry->body.zebra_message.source_as) >+ { >+ printf("FROM:"); >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ >+ fmt_ipv6(entry->body.zebra_message.source_ip,prefix); >+ printf(" %s ",prefix); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ if (entry->body.zebra_message.source_ip.v4_addr.s_addr != 0x00000000L) >+ printf(" %s ",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr)); >+ else >+ printf(" N/A "); >+ } >+ printf("AS%u\n",entry->body.zebra_message.source_as); >+ } >+ if (entry->body.zebra_message.destination_as) >+ { >+ printf("TO:"); >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ >+ fmt_ipv6(entry->body.zebra_message.destination_ip,prefix); >+ printf(" %s ",prefix); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ if (entry->body.zebra_message.destination_ip.v4_addr.s_addr != 0x00000000L) >+ printf(" %s ",inet_ntoa(entry->body.zebra_message.destination_ip.v4_addr)); >+ else >+ printf(" N/A "); >+ } >+ printf("AS%u\n",entry->body.zebra_message.destination_as); >+ } >+ >+ printf("VERSION: %d\n",entry->body.zebra_message.version); >+ printf("AS: %u\n",entry->body.zebra_message.my_as); >+ printf("HOLD_TIME: %d\n",entry->body.zebra_message.hold_time); >+ printf("ID: %s\n",inet_ntoa(entry->body.zebra_message.bgp_id)); >+ printf("OPT_PARM_LEN: %d\n",entry->body.zebra_message.opt_len); >+ break; >+ >+ case BGP_MSG_NOTIFY: >+ if (mode != 0) >+ break; >+ printf("TYPE: BGP4MP/MESSAGE/Notify\n"); >+ if (entry->body.zebra_message.source_as) >+ { >+ printf("FROM:"); >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ >+ fmt_ipv6(entry->body.zebra_message.source_ip,prefix); >+ printf(" %s ",prefix); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ if (entry->body.zebra_message.source_ip.v4_addr.s_addr != 0x00000000L) >+ printf(" %s ",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr)); >+ else >+ printf(" N/A "); >+ } >+ printf("AS%u\n",entry->body.zebra_message.source_as); >+ } >+ if (entry->body.zebra_message.destination_as) >+ { >+ printf("TO:"); >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ >+ fmt_ipv6(entry->body.zebra_message.destination_ip,prefix); >+ printf(" %s ",prefix); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ if (entry->body.zebra_message.destination_ip.v4_addr.s_addr != 0x00000000L) >+ printf(" %s ",inet_ntoa(entry->body.zebra_message.destination_ip.v4_addr)); >+ else >+ printf(" N/A "); >+ } >+ printf("AS%u\n",entry->body.zebra_message.destination_as); >+ } >+ >+ switch (entry->body.zebra_message.error_code) >+ { >+ case 1: >+ printf(" ERROR CODE : 1 (Message Header Error)\n"); >+ switch(entry->body.zebra_message.sub_error_code) >+ { >+ case 1: >+ printf(" SUB ERROR : 1 (Connection Not Synchronized)\n"); >+ break; >+ >+ case 2: >+ printf(" SUB ERROR : 2 (Bad Message Length)\n"); >+ break; >+ >+ case 3: >+ printf(" SUB ERROR : 3 (Bad Message Type)\n"); >+ break; >+ >+ default: >+ printf(" SUB ERROR : %d\n",entry->body.zebra_message.sub_error_code); >+ break; >+ } >+ break; >+ case 2: >+ printf(" ERROR CODE : 2 (OPEN Message Error)\n"); >+ switch(entry->body.zebra_message.sub_error_code) >+ { >+ case 1: >+ printf(" SUB ERROR : 1 (Unsupported Version Number)\n"); >+ break; >+ >+ case 2: >+ printf(" SUB ERROR : 2 (Bad Peer AS)\n"); >+ break; >+ >+ case 3: >+ printf(" SUB ERROR : 3 (Bad BGP Identifier)\n"); >+ break; >+ >+ case 4: >+ printf(" SUB ERROR : 4 (Unsupported Optional Parameter)\n"); >+ break; >+ >+ case 5: >+ printf(" SUB ERROR : 5 (Authentication Failure)\n"); >+ break; >+ >+ case 6: >+ printf(" SUB ERROR : 6 (Unacceptable Hold Time)\n"); >+ break; >+ >+ default: >+ printf(" SUB ERROR : %d\n",entry->body.zebra_message.sub_error_code); >+ break; >+ } >+ break; >+ case 3: >+ printf(" ERROR CODE : 3 (UPDATE Message Error)\n"); >+ switch(entry->body.zebra_message.sub_error_code) >+ { >+ case 1: >+ printf(" SUB ERROR : 1 (Malformed Attribute List)\n"); >+ break; >+ >+ case 2: >+ printf(" SUB ERROR : 2 (Unrecognized Well-known Attribute)\n"); >+ break; >+ >+ case 3: >+ printf(" SUB ERROR : 3 (Missing Well-known Attribute)\n"); >+ break; >+ >+ case 4: >+ printf(" SUB ERROR : 4 (Attribute Flags Error)\n"); >+ break; >+ >+ case 5: >+ printf(" SUB ERROR : 5 (Attribute Length Error)\n"); >+ break; >+ >+ case 6: >+ printf(" SUB ERROR : 6 (Invalid ORIGIN Attribute)\n"); >+ break; >+ >+ case 7: >+ printf(" SUB ERROR : 7 (AS Routing Loop)\n"); >+ break; >+ >+ case 8: >+ printf(" SUB ERROR : 8 (Invalid NEXT-HOP Attribute)\n"); >+ break; >+ >+ case 9: >+ printf(" SUB ERROR : 9 (Optional Attribute Error)\n"); >+ break; >+ >+ case 10: >+ printf(" SUB ERROR : 10 (Invalid Network Field)\n"); >+ break; >+ >+ case 11: >+ printf(" SUB ERROR : 11 (Malformed AS-PATH)\n"); >+ break; >+ >+ default: >+ printf(" SUB ERROR : %d\n",entry->body.zebra_message.sub_error_code); >+ break; >+ } >+ break; >+ case 4: >+ printf(" ERROR CODE : 4 (Hold Timer Expired)\n"); >+ break; >+ case 5: >+ printf(" ERROR CODE : 5 (Finite State Machine Error)\n"); >+ break; >+ case 6: >+ printf(" ERROR CODE : 6 (Cease)\n"); >+ break; >+ default: >+ printf(" ERROR CODE : %d\n",entry->body.zebra_message.error_code); >+ break; >+ >+ } >+ break; >+ >+ case BGP_MSG_KEEPALIVE: >+ if ( mode != 0) >+ break; >+ >+ printf("TYPE: BGP4MP/MESSAGE/Keepalive\n"); >+ if (entry->body.zebra_message.source_as) >+ { >+ printf("FROM:"); >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ >+ fmt_ipv6(entry->body.zebra_message.source_ip,prefix); >+ printf(" %s ",prefix); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ if (entry->body.zebra_message.source_ip.v4_addr.s_addr != 0x00000000L) >+ printf(" %s ",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr)); >+ else >+ printf(" N/A "); >+ } >+ printf("AS%u\n",entry->body.zebra_message.source_as); >+ } >+ if (entry->body.zebra_message.destination_as) >+ { >+ printf("TO:"); >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ >+ fmt_ipv6(entry->body.zebra_message.destination_ip,prefix); >+ printf(" %s ",prefix); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ if (entry->body.zebra_message.destination_ip.v4_addr.s_addr != 0x00000000L) >+ printf(" %s ",inet_ntoa(entry->body.zebra_message.destination_ip.v4_addr)); >+ else >+ printf(" N/A "); >+ } >+ printf("AS%u\n",entry->body.zebra_message.destination_as); >+ } >+ >+ >+ break; >+ } >+ break; >+ >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_STATE_CHANGE: >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_STATE_CHANGE_AS4: >+ if (mode==0) >+ { >+ printf("TYPE: BGP4MP/STATE_CHANGE\n"); >+ >+ printf("PEER:"); >+ switch(entry->body.zebra_state_change.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ >+ fmt_ipv6(entry->body.zebra_state_change.source_ip,prefix); >+ printf(" %s ",prefix); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ if (entry->body.zebra_state_change.source_ip.v4_addr.s_addr != 0x00000000L) >+ printf(" %s ",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr)); >+ else >+ printf(" N/A "); >+ } >+ //if (entry->body.zebra_message.source_ip.s_addr != 0x00000000L) >+ // printf(" %s ",inet_ntoa(entry->body.zebra_message.source_ip)); >+ //else >+ // printf(" N/A "); >+ printf("AS%u\n",entry->body.zebra_state_change.source_as); >+ >+ printf("STATE: %s/%s\n",bgp_state_name[entry->body.zebra_state_change.old_state],bgp_state_name[entry->body.zebra_state_change.new_state]); >+ } >+ else if (mode==1 || mode==2 ) //-m -M >+ { >+ switch(entry->body.zebra_state_change.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ fmt_ipv6(entry->body.zebra_state_change.source_ip,prefix); >+ show_line_prefix("BGP4MP", entry->time, time_str, "STATE"); >+ printf("%s|%u|%d|%d\n", >+ prefix, >+ entry->body.zebra_state_change.source_as, >+ entry->body.zebra_state_change.old_state, >+ entry->body.zebra_state_change.new_state); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ show_line_prefix("BGP4MP", entry->time, time_str, "STATE"); >+ printf("%s|%u|%d|%d\n", >+ inet_ntoa(entry->body.zebra_state_change.source_ip.v4_addr), >+ entry->body.zebra_state_change.source_as, >+ entry->body.zebra_state_change.old_state, >+ entry->body.zebra_state_change.new_state); >+ break; >+ } >+ } >+ break; >+ >+ } >+ break; >+ } >+ if (mode==0) >+ printf("\n"); >+} >+ >+// print line prefix with respect of mode and show_packet_index flags >+// output will have format: >+// format|[packet_index|]time|type| >+void show_line_prefix(const char* format, long long ts, const char* time_str, const char* type) >+{ >+ printf("%s|", format); >+ if (show_packet_index) >+ printf("%d|", packet_index); >+ >+ if (mode == 1) >+ printf("%lld|", ts); >+ else >+ printf("%s|", time_str); >+ >+ printf("%s|", type); >+} >+ >+ >+void process_bgpdump_mrtd_bgp(BGPDUMP_ENTRY *entry) { >+ struct tm *date; >+ char time_str[128]; >+ date=gmtime(&entry->time); >+ time2str(date,time_str); >+ >+ switch (entry->subtype) { >+ case BGPDUMP_SUBTYPE_MRTD_BGP_UPDATE: >+ case BGPDUMP_SUBTYPE_MRTD_BGP_KEEPALIVE: >+ if (mode == 0) { >+ if (entry->subtype == BGPDUMP_SUBTYPE_MRTD_BGP_UPDATE) >+ printf("TYPE: BGP/MESSAGE/Update\n"); >+ else >+ printf("TYPE: BGP/MESSAGE/Keepalive\n"); >+ if (entry->body.mrtd_message.source_as) { >+ printf("FROM:"); >+ show_ipv4_address(entry->body.mrtd_message.source_ip); >+ printf("AS%u\n", entry->body.mrtd_message.source_as); >+ } >+ if (entry->body.mrtd_message.destination_as) { >+ printf("TO:"); >+ show_ipv4_address(entry->body.mrtd_message.destination_ip); >+ printf("AS%u\n", entry->body.mrtd_message.destination_as); >+ } >+ if (entry->attr && entry->attr->len) >+ show_attr(entry->attr); >+ if (entry->body.mrtd_message.withdraw_count) { >+ printf("WITHDRAW\n"); >+ show_prefixes(entry->body.mrtd_message.withdraw_count, entry->body.mrtd_message.withdraw); >+ } >+ if (entry->body.mrtd_message.announce_count) { >+ printf("ANNOUNCE\n"); >+ show_prefixes(entry->body.mrtd_message.announce_count, entry->body.mrtd_message.announce); >+ } >+ } >+ else { >+ if (entry->subtype != BGPDUMP_SUBTYPE_MRTD_BGP_UPDATE) >+ break; >+ if (entry->body.mrtd_message.withdraw_count) >+ mrtd_table_line_withdraw(entry->body.mrtd_message.withdraw, entry->body.mrtd_message.withdraw_count, >+ entry, time_str); >+ if (entry->body.mrtd_message.announce_count) >+ mrtd_table_line_announce(entry->body.mrtd_message.announce, entry->body.mrtd_message.announce_count, >+ entry, time_str); >+ } >+ break; >+ case BGPDUMP_SUBTYPE_MRTD_BGP_STATE_CHANGE: >+ if (mode == 0) { >+ printf("TYPE: BGP/STATE_CHANGE\n"); >+ printf("PEER:"); >+ show_ipv4_address(entry->body.mrtd_state_change.destination_ip); >+ printf("AS%u\n", entry->body.mrtd_state_change.destination_as); >+ printf("STATE: %s/%s\n", bgp_state_name[entry->body.mrtd_state_change.old_state], >+ bgp_state_name[entry->body.mrtd_state_change.new_state]); >+ } >+ else if (mode == 1 || mode == 2) { >+ show_line_prefix("BGP", entry->time, time_str, "STATE"); >+ printf("%s|%u|%d|%d\n", >+ inet_ntoa(entry->body.mrtd_state_change.destination_ip), >+ entry->body.mrtd_state_change.destination_as, >+ entry->body.mrtd_state_change.old_state, >+ entry->body.mrtd_state_change.new_state); >+ } >+ break; >+ default: >+ if (mode == 0) { >+ printf("TYPE: Subtype %d not supported yet\n", entry->subtype); >+ } >+ } >+} >+ >+ >+void mrtd_table_line_withdraw(struct prefix *prefix, int count, BGPDUMP_ENTRY *entry, char *time_str) { >+ int i; >+ >+ for (i = 0; i < count; i++) { >+ show_line_prefix("BGP", entry->time, time_str, "W"); >+ printf("%s|%u|%s/%d\n", inet_ntoa(entry->body.mrtd_message.source_ip), >+ entry->body.mrtd_message.source_as, >+ inet_ntoa(prefix[i].address.v4_addr), prefix[i].len); >+ } >+} >+ >+ >+void mrtd_table_line_announce(struct prefix *prefix, int count, BGPDUMP_ENTRY *entry, char *time_str) { >+ int i, npref, nmed; >+ char *aggregate = entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_ATOMIC_AGGREGATE) ? "AG" : "NAG"; >+ >+ for (i = 0; i < count; i++) { >+ show_line_prefix("BGP", entry->time, time_str, "A"); >+ printf("%s|%u", inet_ntoa(entry->body.mrtd_message.source_ip), >+ entry->body.mrtd_message.source_as); >+ printf("|%s/%d|%s|%s", inet_ntoa(prefix[i].address.v4_addr), prefix[i].len, >+ attr_aspath(entry->attr), describe_origin(entry->attr->origin)); >+ if (mode == 1) { >+ npref = ((entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF)) == 0) ? 0 : entry->attr->local_pref; >+ nmed = ((entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC)) == 0) ? 0 : entry->attr->med; >+ printf("|%s|%u|%u", inet_ntoa(entry->attr->nexthop), npref, nmed); >+ >+ if ((entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_COMMUNITIES)) != 0) >+ printf("%s|%s|", entry->attr->community->str+1, aggregate); >+ else >+ printf("|%s|", aggregate); >+ >+ if (entry->attr->aggregator_addr.s_addr != -1) >+ printf("%u %s|\n", entry->attr->aggregator_as, inet_ntoa(entry->attr->aggregator_addr)); >+ else >+ printf("|\n"); >+ } >+ else >+ printf("\n"); >+ } >+} >+ >+ >+ >+void show_ipv4_address(struct in_addr ip) { >+ if (ip.s_addr != 0x00000000L) >+ printf(" %s ", inet_ntoa(ip)); >+ else >+ printf(" N/A "); >+} >+ >+ >+void show_attr(attributes_t *attr) { >+ >+ if(attr != NULL) { >+ >+ if( (attr->flag & ATTR_FLAG_BIT (BGP_ATTR_ORIGIN) ) !=0 ) >+ { >+ switch (attr->origin) >+ { >+ case 0: >+ printf("ORIGIN: IGP\n"); >+ break; >+ case 1: >+ printf("ORIGIN: EGP\n"); >+ break; >+ case 2: >+ printf("ORIGIN: INCOMPLETE\n"); >+ >+ } >+ >+ } >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_AS_PATH) ) !=0) >+ printf("ASPATH: %s\n",attr->aspath->str); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_NEXT_HOP) ) !=0) >+ printf("NEXT_HOP: %s\n",inet_ntoa(attr->nexthop)); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC) ) !=0) >+ printf("MULTI_EXIT_DISC: %u\n",attr->med); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF) ) !=0) >+ printf("LOCAL_PREF: %u\n",attr->local_pref); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_ATOMIC_AGGREGATE) ) !=0) >+ printf("ATOMIC_AGGREGATE\n"); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_AGGREGATOR) ) !=0) >+ printf("AGGREGATOR: AS%u %s\n",attr->aggregator_as,inet_ntoa(attr->aggregator_addr)); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_ORIGINATOR_ID) ) !=0) >+ printf("ORIGINATOR_ID: %s\n",inet_ntoa(attr->originator_id)); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_CLUSTER_LIST) ) !=0) >+ { >+ int cluster_index; >+ >+ printf("CLUSTER_LIST: "); >+ >+ for (cluster_index = 0;cluster_index<attr->cluster->length;cluster_index++) >+ printf("%s ",inet_ntoa(attr->cluster->list[cluster_index])); >+ printf("\n"); >+ } >+ >+ int idx; >+ for (idx=0;idx<attr->unknown_num;idx++) >+ { >+ struct unknown_attr *unknown = attr->unknown + idx; >+ printf(" UNKNOWN_ATTR(%i, %i, %i):", unknown->flag, unknown->type, unknown->len); >+ int b; >+ for(b = 0; b < unknown->len; ++b) >+ printf(" %02x", unknown->raw[b]); >+ printf("\n"); >+ } >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_REACH_NLRI) )!=0) >+ { >+ printf("MP_REACH_NLRI"); >+#ifdef BGPDUMP_HAVE_IPV6 >+ if (attr->mp_info->announce[AFI_IP6][SAFI_UNICAST] || attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST] || attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST]) >+ >+ { >+ char buf[128]; >+ >+ if (attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]) >+ { >+ printf("(IPv6 Unicast)\n"); >+ printf("NEXT_HOP: %s\n",fmt_ipv6(attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->nexthop,buf)); >+ if (attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->nexthop_len==32) >+ printf("NEXT_HOP: %s\n",fmt_ipv6(attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->nexthop_local,buf)); >+ } >+ else if (attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST]) >+ { >+ printf("(IPv6 Multicast)\n"); >+ printf("NEXT_HOP: %s\n",fmt_ipv6(attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST]->nexthop,buf)); >+ if (attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST]->nexthop_len==32) >+ printf("NEXT_HOP: %s\n",fmt_ipv6(attr->mp_info->announce[AFI_IP6][SAFI_MULTICAST]->nexthop_local,buf)); >+ >+ } >+ else >+ { >+ printf("(IPv6 Both unicast and multicast)\n"); >+ printf("NEXT_HOP: %s\n",fmt_ipv6(attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST]->nexthop,buf)); >+ if (attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST]->nexthop_len==32) >+ printf("NEXT_HOP: %s\n",fmt_ipv6(attr->mp_info->announce[AFI_IP6][SAFI_UNICAST_MULTICAST]->nexthop_local,buf)); >+ >+ >+ } >+ } >+ else >+#endif >+ { >+ >+ if (attr->mp_info->announce[AFI_IP][SAFI_UNICAST]) >+ { >+ printf("(IPv4 Unicast)\n"); >+ printf("NEXT_HOP: %s\n",inet_ntoa(attr->mp_info->announce[AFI_IP][SAFI_UNICAST]->nexthop.v4_addr)); >+ if (attr->mp_info->announce[AFI_IP][SAFI_UNICAST]->nexthop_len==32) >+ printf("NEXT_HOP: %s\n",inet_ntoa(attr->mp_info->announce[AFI_IP][SAFI_UNICAST]->nexthop_local.v4_addr)); >+ >+ } >+ else if (attr->mp_info->announce[AFI_IP][SAFI_MULTICAST]) >+ { >+ printf("(IPv4 Multicast)\n"); >+ printf("NEXT_HOP: %s\n",inet_ntoa(attr->mp_info->announce[AFI_IP][SAFI_MULTICAST]->nexthop.v4_addr)); >+ if (attr->mp_info->announce[AFI_IP][SAFI_MULTICAST]->nexthop_len==32) >+ printf("NEXT_HOP: %s\n",inet_ntoa(attr->mp_info->announce[AFI_IP][SAFI_MULTICAST]->nexthop_local.v4_addr)); >+ >+ >+ } >+ else if (attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST]) >+ { >+ printf("(IPv4 Both unicast and multicast)\n"); >+ printf("NEXT_HOP: %s\n",inet_ntoa(attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST]->nexthop.v4_addr)); >+ if (attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST]->nexthop_len==32) >+ printf("NEXT_HOP: %s\n",inet_ntoa(attr->mp_info->announce[AFI_IP][SAFI_UNICAST_MULTICAST]->nexthop_local.v4_addr)); >+ >+ >+ } >+ >+ } >+ } >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_UNREACH_NLRI) )!=0) >+ { >+ printf("MP_UNREACH_NLRI"); >+#ifdef BGPDUMP_HAVE_IPV6 >+ if (attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST] || attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST] || attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST_MULTICAST]) >+ >+ { >+ >+ if (attr->mp_info->withdraw[AFI_IP6][SAFI_UNICAST]) >+ { >+ printf("(IPv6 Unicast)\n"); >+ } >+ else if (attr->mp_info->withdraw[AFI_IP6][SAFI_MULTICAST]) >+ { >+ printf("(IPv6 Multicast)\n"); >+ >+ } >+ else >+ { >+ printf("(IPv6 Both unicast and multicast)\n"); >+ >+ >+ } >+ } >+ else >+#endif >+ { >+ >+ if (attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST]) >+ { >+ printf("(IPv4 Unicast)\n"); >+ >+ } >+ else if (attr->mp_info->withdraw[AFI_IP][SAFI_MULTICAST]) >+ { >+ printf("(IPv4 Multicast)\n"); >+ >+ >+ } >+ else if (attr->mp_info->withdraw[AFI_IP][SAFI_UNICAST_MULTICAST]) >+ { >+ printf("(IPv4 Both unicast and multicast)\n"); >+ >+ >+ } >+ >+ } >+ } >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_COMMUNITIES) ) !=0) >+ printf("COMMUNITY:%s\n",attr->community->str); >+ } >+ >+} >+ >+void show_prefixes(int count,struct prefix *prefix) { >+ int i; >+ for(i=0;i<count;i++) >+ printf(" %s/%d\n",inet_ntoa(prefix[i].address.v4_addr),prefix[i].len); >+} >+#ifdef BGPDUMP_HAVE_IPV6 >+void show_prefixes6(int count,struct prefix *prefix) >+{ >+ int i; >+ char buf[128]; >+ >+ for (i=0;i<count;i++) >+ printf(" %s/%d\n",fmt_ipv6(prefix[i].address,buf),prefix[i].len); >+} >+#endif >+ >+ >+static void table_line_withdraw(struct prefix *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str) >+{ >+ int idx; >+ char buf[128]; >+ >+ for (idx=0;idx<count;idx++) >+ { >+ show_line_prefix("BGP4MP", entry->time, time_str, "W"); >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ printf("%s|%u|", >+ fmt_ipv6(entry->body.zebra_message.source_ip,buf), >+ entry->body.zebra_message.source_as); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ printf("%s|%u|", >+ inet_ntoa(entry->body.zebra_message.source_ip.v4_addr), >+ entry->body.zebra_message.source_as); >+ break; >+ } >+ printf("%s/%d\n",inet_ntoa(prefix[idx].address.v4_addr),prefix[idx].len); >+ } >+} >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ >+static void table_line_withdraw6(struct prefix *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str) >+{ >+ int idx; >+ char buf[128]; >+ char buf1[128]; >+ >+ for (idx=0;idx<count;idx++) >+ { >+ show_line_prefix("BGP4MP", entry->time, time_str, "W"); >+ switch(entry->body.zebra_message.address_family) >+ { >+ case AFI_IP6: >+ printf("%s|%u|%s/%d\n", >+ fmt_ipv6(entry->body.zebra_message.source_ip,buf1), >+ entry->body.zebra_message.source_as, >+ fmt_ipv6(prefix[idx].address,buf),prefix[idx].len); >+ break; >+ case AFI_IP: >+ default: >+ printf("%s|%u|%s/%d\n", >+ fmt_ipv4(entry->body.zebra_message.source_ip,buf1), >+ entry->body.zebra_message.source_as, >+ fmt_ipv6(prefix[idx].address,buf),prefix[idx].len); >+ break; >+ } >+ } >+} >+#endif >+ >+ >+static void table_line_announce(struct prefix *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str) >+{ >+ int idx ; >+ char buf[128]; >+ char tmp2[20]; >+ unsigned int npref; >+ unsigned int nmed; >+ >+ if (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_ATOMIC_AGGREGATE)) >+ sprintf(tmp2,"AG"); >+ else >+ sprintf(tmp2,"NAG"); >+ >+ for (idx=0;idx<count;idx++) >+ { >+ show_line_prefix("BGP4MP", entry->time, time_str, "A"); >+ if (mode == 1) >+ { >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ printf("%s|%u|",fmt_ipv6(entry->body.zebra_message.source_ip,buf),entry->body.zebra_message.source_as); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ printf("%s|%u|",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr),entry->body.zebra_message.source_as); >+ break; >+ } >+ printf("%s/%d|%s|%s|",inet_ntoa(prefix[idx].address.v4_addr),prefix[idx].len,attr_aspath(entry->attr),describe_origin(entry->attr->origin)); >+ npref=entry->attr->local_pref; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF) ) ==0) >+ npref=0; >+ nmed=entry->attr->med; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC) ) ==0) >+ nmed=0; >+ >+ printf("%s|%u|%u|",inet_ntoa(entry->attr->nexthop),npref,nmed); >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_COMMUNITIES) ) !=0) >+ printf("%s|%s|",entry->attr->community->str+1,tmp2); >+ else >+ printf("|%s|",tmp2); >+ >+ if (entry->attr->aggregator_addr.s_addr != -1) >+ printf("%u %s|\n",entry->attr->aggregator_as,inet_ntoa(entry->attr->aggregator_addr)); >+ else >+ printf("|\n"); >+ } >+ else >+ { >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ printf("%s|%u|",fmt_ipv6(entry->body.zebra_message.source_ip,buf),entry->body.zebra_message.source_as); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ printf("%s|%u|",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr),entry->body.zebra_message.source_as); >+ break; >+ } >+ printf("%s/%d|%s|%s\n",inet_ntoa(prefix[idx].address.v4_addr),prefix[idx].len,attr_aspath(entry->attr),describe_origin(entry->attr->origin)); >+ >+ } >+ } >+ >+} >+static void table_line_announce_1(struct mp_nlri *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str) >+{ >+ int idx ; >+ char buf[128]; >+ char tmp2[20]; >+ unsigned int npref; >+ unsigned int nmed; >+ >+ if (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_ATOMIC_AGGREGATE)) >+ sprintf(tmp2,"AG"); >+ else >+ sprintf(tmp2,"NAG"); >+ >+ for (idx=0;idx<count;idx++) >+ { >+ show_line_prefix("BGP4MP", entry->time, time_str, "A"); >+ if (mode == 1) >+ { >+ if (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_REACH_NLRI)) >+ { >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ printf("%s|%u|",fmt_ipv6(entry->body.zebra_message.source_ip,buf),entry->body.zebra_message.source_as); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ printf("%s|%u|",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr),entry->body.zebra_message.source_as); >+ break; >+ } >+ printf("%s/%d|%s|%s|",inet_ntoa(prefix->nlri[idx].address.v4_addr),prefix->nlri[idx].len,attr_aspath(entry->attr),describe_origin(entry->attr->origin)); >+ >+ npref=entry->attr->local_pref; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF) ) ==0) >+ npref=0; >+ nmed=entry->attr->med; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC) ) ==0) >+ nmed=0; >+ >+ printf("%s|%d|%d|",inet_ntoa(entry->attr->nexthop),npref,nmed); >+ //printf("%s|%d|%d|",inet_ntoa(prefix->nexthop.v4_addr),entry->attr->local_pref,entry->attr->med); >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_COMMUNITIES) ) !=0) >+ printf("%s|%s|",entry->attr->community->str+1,tmp2); >+ else >+ printf("|%s|",tmp2); >+ >+ } >+ else >+ { >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ printf("%s|%u|",fmt_ipv6(entry->body.zebra_message.source_ip,buf),entry->body.zebra_message.source_as); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ printf("%s|%u|",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr),entry->body.zebra_message.source_as); >+ break; >+ } >+ printf("%s/%d|%s|%s|",inet_ntoa(prefix->nlri[idx].address.v4_addr),prefix->nlri[idx].len,attr_aspath(entry->attr),describe_origin(entry->attr->origin)); >+ >+ npref=entry->attr->local_pref; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF) ) ==0) >+ npref=0; >+ nmed=entry->attr->med; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC) ) ==0) >+ nmed=0; >+ >+ printf("%s|%d|%d|",inet_ntoa(entry->attr->nexthop),npref,nmed); >+ //printf("%s|%d|%d|",inet_ntoa(entry->attr->nexthop),entry->attr->local_pref,entry->attr->med); >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_COMMUNITIES) ) !=0) >+ printf("%s|%s|",entry->attr->community->str+1,tmp2); >+ else >+ printf("|%s|",tmp2); >+ >+ >+ } >+ if (entry->attr->aggregator_addr.s_addr != -1) >+ printf("%u %s|\n",entry->attr->aggregator_as,inet_ntoa(entry->attr->aggregator_addr)); >+ else >+ printf("|\n"); >+ } >+ else >+ { >+ switch(entry->body.zebra_message.address_family) >+ { >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ printf("%s|%u|",fmt_ipv6(entry->body.zebra_message.source_ip,buf),entry->body.zebra_message.source_as); >+ break; >+#endif >+ case AFI_IP: >+ default: >+ printf("%s|%u|",inet_ntoa(entry->body.zebra_message.source_ip.v4_addr),entry->body.zebra_message.source_as); >+ break; >+ } >+ printf("%s/%d|%s|%s\n",inet_ntoa(prefix->nlri[idx].address.v4_addr),prefix->nlri[idx].len,attr_aspath(entry->attr),describe_origin(entry->attr->origin)); >+ >+ } >+ } >+ >+} >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+static void table_line_announce6(struct mp_nlri *prefix,int count,BGPDUMP_ENTRY *entry,char *time_str) >+{ >+ int idx ; >+ char buf[128]; >+ char buf1[128]; >+ char buf2[128]; >+ char tmp2[20]; >+ unsigned int npref; >+ unsigned int nmed; >+ >+ if (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_ATOMIC_AGGREGATE)) >+ sprintf(tmp2,"AG"); >+ else >+ sprintf(tmp2,"NAG"); >+ >+ for (idx=0;idx<count;idx++) >+ { >+ show_line_prefix("BGP4MP", entry->time, time_str, "A"); >+ if (mode == 1) >+ { >+ switch(entry->body.zebra_message.address_family) >+ { >+ case AFI_IP6: >+ >+ npref=entry->attr->local_pref; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF) ) ==0) >+ npref=0; >+ nmed=entry->attr->med; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC) ) ==0) >+ nmed=0; >+ >+ printf("%s|%u|%s/%d|%s|%s|%s|%u|%u|",fmt_ipv6(entry->body.zebra_message.source_ip,buf1),entry->body.zebra_message.source_as,fmt_ipv6(prefix->nlri[idx].address,buf2),prefix->nlri[idx].len,attr_aspath(entry->attr),describe_origin(entry->attr->origin),fmt_ipv6(prefix->nexthop,buf),npref,nmed); >+ break; >+ case AFI_IP: >+ default: >+ >+ npref=entry->attr->local_pref; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF) ) ==0) >+ npref=0; >+ nmed=entry->attr->med; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC) ) ==0) >+ nmed=0; >+ >+ //printf("%s|%d|%d|",inet_ntoa(entry->attr->nexthop),nprof,nmed); >+ printf("%s|%u|%s/%d|%s|%s|%s|%u|%u|",fmt_ipv4(entry->body.zebra_message.source_ip,buf1),entry->body.zebra_message.source_as,fmt_ipv6(prefix->nlri[idx].address,buf2),prefix->nlri[idx].len,attr_aspath(entry->attr),describe_origin(entry->attr->origin),fmt_ipv6(prefix->nexthop,buf),npref,nmed); >+ break; >+ } >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_COMMUNITIES) ) !=0) >+ printf("%s|%s|",entry->attr->community->str+1,tmp2); >+ else >+ printf("|%s|",tmp2); >+ >+ >+ if (entry->attr->aggregator_addr.s_addr != -1) >+ printf("%u %s|\n",entry->attr->aggregator_as,inet_ntoa(entry->attr->aggregator_addr)); >+ else >+ printf("|\n"); >+ >+ } >+ else >+ { >+ switch(entry->body.zebra_message.address_family) >+ { >+ case AFI_IP6: >+ printf("%s|%u|%s/%d|%s|%s\n",fmt_ipv6(entry->body.zebra_message.source_ip,buf1),entry->body.zebra_message.source_as,fmt_ipv6(prefix->nlri[idx].address,buf),prefix->nlri[idx].len,attr_aspath(entry->attr),describe_origin(entry->attr->origin)); >+ break; >+ case AFI_IP: >+ default: >+ printf("%s|%u|%s/%d|%s|%s\n",fmt_ipv4(entry->body.zebra_message.source_ip,buf1),entry->body.zebra_message.source_as,fmt_ipv6(prefix->nlri[idx].address,buf),prefix->nlri[idx].len,attr_aspath(entry->attr),describe_origin(entry->attr->origin)); >+ break; >+ } >+ } >+ >+ } >+ >+} >+#endif >+ >+ >+static void table_line_mrtd_route(BGPDUMP_MRTD_TABLE_DUMP *route,BGPDUMP_ENTRY *entry) >+{ >+ >+ struct tm *date = NULL; >+ char tmp2[20]; >+ unsigned int npref; >+ unsigned int nmed; >+ char time_str[20]; >+ char peer[BGPDUMP_ADDRSTRLEN], prefix[BGPDUMP_ADDRSTRLEN], nexthop[BGPDUMP_ADDRSTRLEN]; >+ >+ if (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_ATOMIC_AGGREGATE)) >+ sprintf(tmp2,"AG"); >+ else >+ sprintf(tmp2,"NAG"); >+ >+ if (timetype==0) { >+ date=gmtime(&entry->time); >+ time2str(date,time_str); >+ show_line_prefix("TABLE_DUMP", entry->time, time_str, "B"); >+ } >+ else { >+ date=gmtime(&route->uptime); >+ time2str(date,time_str); >+ show_line_prefix("TABLE_DUMP", route->uptime, time_str, "B"); >+ } >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ if (entry->subtype == AFI_IP6) >+ { >+ fmt_ipv6(route->peer_ip,peer); >+ fmt_ipv6(route->prefix,prefix); >+ } >+ else >+#endif >+ { >+ strncpy(peer, inet_ntoa(route->peer_ip.v4_addr), BGPDUMP_ADDRSTRLEN); >+ strncpy(prefix, inet_ntoa(route->prefix.v4_addr), BGPDUMP_ADDRSTRLEN); >+ } >+ >+ if (mode == 1) >+ { >+ printf("%s|%u|",peer,route->peer_as); >+ printf("%s/%d|%s|%s|",prefix,route->mask, >+ attr_aspath(entry->attr),describe_origin(entry->attr->origin)); >+ >+ npref=entry->attr->local_pref; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF) ) ==0) >+ npref=0; >+ nmed=entry->attr->med; >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC) ) ==0) >+ nmed=0; >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ if ((entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_REACH_NLRI)) && entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]) >+ { >+ fmt_ipv6(entry->attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->nexthop,nexthop); >+ } >+ else >+#endif >+ { >+ strncpy(nexthop, inet_ntoa(entry->attr->nexthop), BGPDUMP_ADDRSTRLEN); >+ } >+ printf("%s|%u|%u|",nexthop,npref,nmed); >+ >+ if( (entry->attr->flag & ATTR_FLAG_BIT(BGP_ATTR_COMMUNITIES) ) !=0) >+ printf("%s|%s|",entry->attr->community->str+1,tmp2); >+ else >+ printf("|%s|",tmp2); >+ >+ if (entry->attr->aggregator_addr.s_addr != -1) >+ printf("%u %s|\n",entry->attr->aggregator_as,inet_ntoa(entry->attr->aggregator_addr)); >+ else >+ printf("|\n"); >+ } >+ else >+ { >+ printf("%s|%u|",peer,route->peer_as); >+ printf("%s/%d|%s|%s\n",prefix,route->mask,attr_aspath(entry->attr),describe_origin(entry->attr->origin)); >+ } >+ >+} >+ >+static char *describe_origin(int origin) { >+ if(origin == 0) return "IGP"; >+ if(origin == 1) return "EGP"; >+ return "INCOMPLETE"; >+} >+ >+static void table_line_dump_v2_prefix(BGPDUMP_TABLE_DUMP_V2_PREFIX *e,BGPDUMP_ENTRY *entry) >+{ >+ struct tm *date = NULL; >+ unsigned int npref; >+ unsigned int nmed; >+ char time_str[20]; >+ char peer[BGPDUMP_ADDRSTRLEN], prefix[BGPDUMP_ADDRSTRLEN], nexthop[BGPDUMP_ADDRSTRLEN]; >+ >+ int i; >+ >+ for(i = 0; i < e->entry_count; i++) { >+ attributes_t *attr = e->entries[i].attr; >+ if(! attr) >+ continue; >+ >+ char *origin = describe_origin(attr->origin); >+ char *aspath_str = (attr->aspath) ? attr->aspath->str: ""; >+ char *aggregate = attr->flag & ATTR_FLAG_BIT(BGP_ATTR_ATOMIC_AGGREGATE) ? "AG" : "NAG"; >+ >+ if(e->entries[i].peer->afi == AFI_IP){ >+ fmt_ipv4(e->entries[i].peer->peer_ip, peer); >+#ifdef BGPDUMP_HAVE_IPV6 >+ } else if(e->entries[i].peer->afi == AFI_IP6){ >+ fmt_ipv6(e->entries[i].peer->peer_ip, peer); >+#endif >+ } >+ >+ if(e->afi == AFI_IP) { >+ fmt_ipv4(e->prefix, prefix); >+#ifdef BGPDUMP_HAVE_IPV6 >+ } else if(e->afi == AFI_IP6) { >+ fmt_ipv6(e->prefix, prefix); >+#endif >+ } >+ >+ if (timetype==0) { >+ date=gmtime(&entry->time); >+ time2str(date,time_str); >+ show_line_prefix("TABLE_DUMP2", entry->time, time_str, "B"); >+ } >+ else { >+ time_t time_temp = (time_t)((e->entries[i]).originated_time); >+ date=gmtime(&time_temp); >+ time2str(date,time_str); >+ show_line_prefix("TABLE_DUMP2", e->entries[i].originated_time, time_str, "B"); >+ } >+ >+ if (mode == 1) >+ { >+ printf("%s|%u|",peer,e->entries[i].peer->peer_as); >+ printf("%s/%d|%s|%s|",prefix,e->prefix_length,aspath_str,origin); >+ >+ npref=attr->local_pref; >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF) ) ==0) >+ npref=0; >+ nmed=attr->med; >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC) ) ==0) >+ nmed=0; >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ if ((attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_REACH_NLRI)) && attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]) >+ { >+ fmt_ipv6(attr->mp_info->announce[AFI_IP6][SAFI_UNICAST]->nexthop,nexthop); >+ } >+ else >+#endif >+ { >+ strncpy(nexthop, inet_ntoa(attr->nexthop), BGPDUMP_ADDRSTRLEN); >+ } >+ printf("%s|%u|%u|",nexthop,npref,nmed); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_COMMUNITIES) ) !=0) >+ printf("%s|%s|",attr->community->str+1,aggregate); >+ else >+ printf("|%s|",aggregate); >+ >+ if (attr->aggregator_addr.s_addr != -1) >+ printf("%u %s|\n",attr->aggregator_as,inet_ntoa(attr->aggregator_addr)); >+ else >+ printf("|\n"); >+ } >+ else >+ { >+ printf("%s|%u|",peer,e->entries[i].peer->peer_as); >+ printf("%s/%d|%s|%s\n",prefix,e->prefix_length,aspath_str,origin); >+ >+ } >+ } >+ >+} >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump.spec libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump.spec >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump.spec 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump.spec 2015-09-16 20:23:14.000000000 +1200 >@@ -0,0 +1,60 @@ >+Summary: MRT file reader >+Name: libbgpdump >+Version: 1.4.99.15 >+Release: 1 >+License: GPL >+URL: http://www.ris.ripe.net/source/ >+Vendor: RIPE NCC Information Services department >+Group: System Environment/Libraries >+Source: libbgpdump-1.4.99.15.tgz >+BuildRoot: /var/tmp/%{name}-root >+BuildRequires: bzip2-devel zlib-devel >+ >+%description >+This library reads MRT files as, amongst others, produced >+by the RIPE NCC routing information service. >+ >+This library is maintained by the RIPE NCC Information >+Services department: ris@ripe.net >+ >+%package devel >+Summary: Libraries, includes to develop applications with %{name}. >+Group: Development/Libraries >+Requires: %{name} = %{version} >+ >+%description devel >+The %{name}-devel package contains the header files and static libraries for >+building applications which use %{name}. >+ >+ >+%prep >+%setup >+ >+%build >+%configure >+make CFLAGS="$RPM_OPT_FLAGS" >+ >+%install >+rm -rf %{buildroot} >+%makeinstall >+ >+%clean >+rm -rf %{buildroot} >+ >+%files >+%defattr(0755,root,root) >+%{_bindir}/bgpdump >+%defattr(-,root,root) >+%{_libdir}/libbgpdump.a >+%{_libdir}/libbgpdump.so >+ >+%files devel >+%defattr(-,root,root) >+%{_includedir}/bgpdump_attr.h >+%{_includedir}/bgpdump_formats.h >+%{_includedir}/bgpdump_lib.h >+%{_includedir}/bgpdump_mstream.h >+ >+%changelog >+* Wed Jul 04 2008 Erik Romijn <eromijn@ripe.net> 1.4.99.9-1 >+- Initial release >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump.spec.in libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump.spec.in >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump.spec.in 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump.spec.in 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,60 @@ >+Summary: MRT file reader >+Name: @PACKAGE_NAME@ >+Version: @PACKAGE_VERSION@ >+Release: 1 >+License: GPL >+URL: http://www.ris.ripe.net/source/ >+Vendor: RIPE NCC Information Services department >+Group: System Environment/Libraries >+Source: @PACKAGE_NAME@-@PACKAGE_VERSION@.tgz >+BuildRoot: /var/tmp/%{name}-root >+BuildRequires: bzip2-devel zlib-devel >+ >+%description >+This library reads MRT files as, amongst others, produced >+by the RIPE NCC routing information service. >+ >+This library is maintained by the RIPE NCC Information >+Services department: ris@ripe.net >+ >+%package devel >+Summary: Libraries, includes to develop applications with %{name}. >+Group: Development/Libraries >+Requires: %{name} = %{version} >+ >+%description devel >+The %{name}-devel package contains the header files and static libraries for >+building applications which use %{name}. >+ >+ >+%prep >+%setup >+ >+%build >+%configure >+make CFLAGS="$RPM_OPT_FLAGS" >+ >+%install >+rm -rf %{buildroot} >+%makeinstall >+ >+%clean >+rm -rf %{buildroot} >+ >+%files >+%defattr(0755,root,root) >+%{_bindir}/bgpdump >+%defattr(-,root,root) >+%{_libdir}/libbgpdump.a >+%{_libdir}/libbgpdump.so >+ >+%files devel >+%defattr(-,root,root) >+%{_includedir}/bgpdump_attr.h >+%{_includedir}/bgpdump_formats.h >+%{_includedir}/bgpdump_lib.h >+%{_includedir}/bgpdump_mstream.h >+ >+%changelog >+* Wed Jul 04 2008 Erik Romijn <eromijn@ripe.net> 1.4.99.9-1 >+- Initial release >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_attr.h libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_attr.h >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_attr.h 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_attr.h 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,226 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+Parts of this code have been engineered after analiyzing GNU Zebra's >+source code and therefore might contain declarations/code from GNU >+Zebra, Copyright (C) 1999 Kunihiro Ishiguro. Zebra is a free routing >+software, distributed under the GNU General Public License. A copy of >+this license is included with libbgpdump. >+ >+Original Author: Dan Ardelean (dan@ripe.net) >+*/ >+ >+#ifndef _BGPDUMP_ATTR_H >+#define _BGPDUMP_ATTR_H >+ >+#include <sys/types.h> >+#include <netinet/in.h> >+ >+/* BGP Attribute flags. */ >+#define BGP_ATTR_FLAG_OPTIONAL 0x80 /* Attribute is optional. */ >+#define BGP_ATTR_FLAG_TRANS 0x40 /* Attribute is transitive. */ >+#define BGP_ATTR_FLAG_PARTIAL 0x20 /* Attribute is partial. */ >+#define BGP_ATTR_FLAG_EXTLEN 0x10 /* Extended length flag. */ >+ >+/* BGP attribute type codes. */ >+#define BGP_ATTR_ORIGIN 1 >+#define BGP_ATTR_AS_PATH 2 >+#define BGP_ATTR_NEXT_HOP 3 >+#define BGP_ATTR_MULTI_EXIT_DISC 4 >+#define BGP_ATTR_LOCAL_PREF 5 >+#define BGP_ATTR_ATOMIC_AGGREGATE 6 >+#define BGP_ATTR_AGGREGATOR 7 >+#define BGP_ATTR_COMMUNITIES 8 >+#define BGP_ATTR_ORIGINATOR_ID 9 >+#define BGP_ATTR_CLUSTER_LIST 10 >+#define BGP_ATTR_DPA 11 >+#define BGP_ATTR_ADVERTISER 12 >+#define BGP_ATTR_RCID_PATH 13 >+#define BGP_ATTR_MP_REACH_NLRI 14 >+#define BGP_ATTR_MP_UNREACH_NLRI 15 >+#define BGP_ATTR_EXT_COMMUNITIES 16 >+#define BGP_ATTR_NEW_AS_PATH 17 >+#define BGP_ATTR_NEW_AGGREGATOR 18 >+ >+/* Flag macro */ >+#define ATTR_FLAG_BIT(X) (1 << ((X) - 1)) >+ >+/* BGP ASPATH attribute defines */ >+#define AS_HEADER_SIZE 2 >+ >+#define AS_SET 1 >+#define AS_SEQUENCE 2 >+#define AS_CONFED_SEQUENCE 3 >+#define AS_CONFED_SET 4 >+ >+#define AS_SEG_START 0 >+#define AS_SEG_END 1 >+ >+#define ASPATH_STR_DEFAULT_LEN 32 >+#define ASPATH_STR_ERROR "! Error !" >+ >+/* BGP COMMUNITY attribute defines */ >+ >+#define COMMUNITY_NO_EXPORT 0xFFFFFF01 >+#define COMMUNITY_NO_ADVERTISE 0xFFFFFF02 >+#define COMMUNITY_NO_EXPORT_SUBCONFED 0xFFFFFF03 >+#define COMMUNITY_LOCAL_AS 0xFFFFFF03 >+ >+#define com_nthval(X,n) ((X)->val + (n)) >+ >+/* MP-BGP address families */ >+#ifdef BGPDUMP_HAVE_IPV6 >+#define AFI_IP 1 >+#define AFI_IP6 2 >+#define BGPDUMP_MAX_AFI AFI_IP6 >+#else >+#define AFI_IP 1 >+#define BGPDUMP_MAX_AFI AFI_IP >+#endif >+ >+#define SAFI_UNICAST 1 >+#define SAFI_MULTICAST 2 >+#define SAFI_UNICAST_MULTICAST 3 >+#define BGPDUMP_MAX_SAFI SAFI_UNICAST_MULTICAST >+ >+struct unknown_attr >+{ >+ int flag; >+ int type; >+ int len; >+ u_char *raw; >+}; >+ >+typedef u_int32_t as_t; >+ >+typedef struct attr attributes_t; >+struct attr >+{ >+ /* Flag of attribute is set or not. */ >+ u_int32_t flag; >+ >+ /* Attributes. */ >+ int origin; >+ struct in_addr nexthop; >+ u_int32_t med; >+ u_int32_t local_pref; >+ as_t aggregator_as; >+ struct in_addr aggregator_addr; >+ u_int32_t weight; >+ struct in_addr originator_id; >+ struct cluster_list *cluster; >+ >+ struct aspath *aspath; >+ struct community *community; >+ struct ecommunity *ecommunity; >+ struct transit *transit; >+ >+ /* libbgpdump additions */ >+ >+ struct mp_info *mp_info; >+ u_int16_t len; >+ caddr_t data; >+ >+ u_int16_t unknown_num; >+ struct unknown_attr *unknown; >+ >+ /* ASN32 support */ >+ struct aspath *new_aspath; >+ struct aspath *old_aspath; >+ as_t new_aggregator_as; >+ as_t old_aggregator_as; >+ struct in_addr new_aggregator_addr; >+ struct in_addr old_aggregator_addr; >+}; >+ >+struct community >+{ >+ int size; >+ u_int32_t *val; >+ char *str; >+}; >+ >+struct cluster_list >+{ >+ int length; >+ struct in_addr *list; >+}; >+ >+struct transit >+{ >+ int length; >+ u_char *val; >+}; >+ >+struct aspath >+{ >+ u_int8_t asn_len; >+ int length; >+ int count; >+ caddr_t data; >+ char *str; >+}; >+ >+struct assegment >+{ >+ u_char type; >+ u_char length; >+ char data[0]; >+}; >+ >+struct mp_info { >+ /* AFI and SAFI start from 1, so the arrays must be 1-based */ >+ struct mp_nlri *withdraw[BGPDUMP_MAX_AFI+1][BGPDUMP_MAX_SAFI+1]; >+ struct mp_nlri *announce[BGPDUMP_MAX_AFI+1][BGPDUMP_MAX_SAFI+1]; >+}; >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+#define MP_IPV6_ANNOUNCE(m) ((m)->announce[AFI_IP6][SAFI_UNICAST]) >+#define MP_IPV6_WITHDRAW(m) ((m)->withdraw[AFI_IP6][SAFI_UNICAST]) >+#endif >+ >+typedef union union_BGPDUMP_IP_ADDRESS { >+ struct in_addr v4_addr; >+ struct in6_addr v6_addr; >+} BGPDUMP_IP_ADDRESS; >+ >+ >+#define BGPDUMP_ADDRSTRLEN 46 >+ >+#define ASN16_LEN sizeof(u_int16_t) >+#define ASN32_LEN sizeof(u_int32_t) >+ >+#define AS_TRAN 23456 >+ >+struct prefix { >+ BGPDUMP_IP_ADDRESS address; >+ u_char len; >+}; >+ >+#define MAX_PREFIXES 2050 >+struct mp_nlri { >+ u_char nexthop_len; >+ >+ BGPDUMP_IP_ADDRESS nexthop; >+ BGPDUMP_IP_ADDRESS nexthop_local; >+ >+ u_int16_t prefix_count; >+ struct prefix nlri[MAX_PREFIXES]; >+}; >+ >+#endif /* _BGPDUMP_ATTR_H */ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_formats.h libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_formats.h >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_formats.h 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_formats.h 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,263 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+Parts of this code have been engineered after analiyzing GNU Zebra's >+source code and therefore might contain declarations/code from GNU >+Zebra, Copyright (C) 1999 Kunihiro Ishiguro. Zebra is a free routing >+software, distributed under the GNU General Public License. A copy of >+this license is included with libbgpdump. >+ >+Original Author: Dan Ardelean (dan@ripe.net) >+*/ >+ >+#ifndef _BGPDUMP_FORMATS_H >+#define _BGPDUMP_FORMATS_H >+ >+#include "bgpdump_attr.h" >+ >+#include <stdio.h> >+#include <sys/types.h> >+#include <string.h> >+#include <netinet/in.h> >+ >+/* type and subtypes values */ >+/* RFC6396 */ >+#define BGPDUMP_TYPE_MRTD_BGP 5 >+#define BGPDUMP_SUBTYPE_MRTD_BGP_NULL 0 >+#define BGPDUMP_SUBTYPE_MRTD_BGP_UPDATE 1 >+#define BGPDUMP_SUBTYPE_MRTD_BGP_PREFUPDATE 2 >+#define BGPDUMP_SUBTYPE_MRTD_BGP_STATE_CHANGE 3 >+#define BGPDUMP_SUBTYPE_MRTD_BGP_SYNC 4 >+#define BGPDUMP_SUBTYPE_MRTD_BGP_OPEN 5 >+#define BGPDUMP_SUBTYPE_MRTD_BGP_NOTIFICATION 6 >+#define BGPDUMP_SUBTYPE_MRTD_BGP_KEEPALIVE 7 >+#define BGPDUMP_SUBTYPE_MRTD_BGP_ROUT_REFRESH 133 >+ >+#define BGPDUMP_TYPE_MRTD_TABLE_DUMP 12 >+#define BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP 1 >+#define BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6 2 >+#define BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP_32BIT_AS 3 >+#define BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6_32BIT_AS 4 >+ >+#define BGPDUMP_TYPE_TABLE_DUMP_V2 13 >+#define BGPDUMP_SUBTYPE_TABLE_DUMP_V2_PEER_INDEX_TABLE 1 >+#define BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_IPV4_UNICAST 2 >+#define BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_IPV4_MULTICAST 3 >+#define BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_IPV6_UNICAST 4 >+#define BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_IPV6_MULTICAST 5 >+#define BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_GENERIC 6 >+#define BGPDUMP_PEERTYPE_TABLE_DUMP_V2_AFI_IP 0 >+#define BGPDUMP_PEERTYPE_TABLE_DUMP_V2_AFI_IP6 1 >+#define BGPDUMP_PEERTYPE_TABLE_DUMP_V2_AS2 0 >+#define BGPDUMP_PEERTYPE_TABLE_DUMP_V2_AS4 2 >+#define BGPDUMP_TYPE_TABLE_DUMP_V2_MAX_VIEWNAME_LEN 255 >+ >+/* Zebra record types */ >+#define BGPDUMP_TYPE_ZEBRA_BGP 16 /* MSG_PROTOCOL_BGP4MP */ >+#define BGPDUMP_SUBTYPE_ZEBRA_BGP_STATE_CHANGE 0 /* BGP4MP_STATE_CHANGE */ >+#define BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE 1 /* BGP4MP_MESSAGE */ >+#define BGPDUMP_SUBTYPE_ZEBRA_BGP_ENTRY 2 /* BGP4MP_ENTRY */ >+#define BGPDUMP_SUBTYPE_ZEBRA_BGP_SNAPSHOT 3 /* BGP4MP_SNAPSHOT */ >+#define BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE_AS4 4 /* BGP4MP_MESSAGE_AS4 */ >+#define BGPDUMP_SUBTYPE_ZEBRA_BGP_STATE_CHANGE_AS4 5 /* BGP4MP_STATE_CHANGE_AS4 */ >+ >+/* BGP state - defined in RFC1771 */ >+#define BGP_STATE_IDLE 1 >+#define BGP_STATE_CONNECT 2 >+#define BGP_STATE_ACTIVE 3 >+#define BGP_STATE_OPENSENT 4 >+#define BGP_STATE_OPENCONFIRM 5 >+#define BGP_STATE_ESTABLISHED 6 >+ >+/* BGP message types */ >+#define BGP_MSG_OPEN 1 >+#define BGP_MSG_UPDATE 2 >+#define BGP_MSG_NOTIFY 3 >+#define BGP_MSG_KEEPALIVE 4 >+#define BGP_MSG_ROUTE_REFRESH_01 5 >+#define BGP_MSG_ROUTE_REFRESH 128 >+ >+typedef struct struct_BGPDUMP_MRTD_TABLE_DUMP { >+ u_int16_t view; >+ u_int16_t sequence; >+ BGPDUMP_IP_ADDRESS prefix; >+ u_char mask; >+ u_char status; >+ time_t uptime; >+ BGPDUMP_IP_ADDRESS peer_ip; >+ as_t peer_as; >+ u_int16_t attr_len; >+} BGPDUMP_MRTD_TABLE_DUMP; >+ >+ >+typedef struct struct_BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE_ENTRY { >+ u_char afi; >+ BGPDUMP_IP_ADDRESS peer_ip; >+ struct in_addr peer_bgp_id; >+ as_t peer_as; >+} BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE_ENTRY; >+ >+typedef struct struct_BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE { >+ struct in_addr local_bgp_id; >+ char view_name[BGPDUMP_TYPE_TABLE_DUMP_V2_MAX_VIEWNAME_LEN]; >+ uint16_t peer_count; >+ BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE_ENTRY *entries; >+} BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE; >+ >+typedef struct struct_BGPDUMP_TABLE_DUMP_V2_ROUTE_ENTRY { >+ uint16_t peer_index; >+ uint32_t originated_time; >+ BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE_ENTRY *peer; >+ attributes_t *attr; >+} BGPDUMP_TABLE_DUMP_V2_ROUTE_ENTRY; >+ >+typedef struct struct_BGPDUMP_TABLE_DUMP_V2_PREFIX { >+ uint32_t seq; >+ uint16_t afi; >+ uint8_t safi; >+ u_char prefix_length; >+ BGPDUMP_IP_ADDRESS prefix; >+ uint16_t entry_count; >+ BGPDUMP_TABLE_DUMP_V2_ROUTE_ENTRY *entries; >+} BGPDUMP_TABLE_DUMP_V2_PREFIX; >+ >+ >+ >+/* For Zebra BGP4MP_STATE_CHANGE */ >+typedef struct struct_BGPDUMP_ZEBRA_STATE_CHANGE { >+ as_t source_as; >+ as_t destination_as; >+ u_int16_t interface_index; >+ u_int16_t address_family; >+ BGPDUMP_IP_ADDRESS source_ip; >+ BGPDUMP_IP_ADDRESS destination_ip; >+ u_int16_t old_state; >+ u_int16_t new_state; >+} BGPDUMP_ZEBRA_STATE_CHANGE; >+ >+struct zebra_incomplete { >+ u_int16_t afi; >+ u_int8_t orig_len; >+ struct prefix prefix; >+}; >+ >+/* For Zebra BGP4MP_MESSAGE */ >+typedef struct struct_BGPDUMP_ZEBRA_MESSAGE { >+ /* Zebra header */ >+ as_t source_as; >+ as_t destination_as; >+ u_int16_t interface_index; >+ u_int16_t address_family; >+ BGPDUMP_IP_ADDRESS source_ip; >+ BGPDUMP_IP_ADDRESS destination_ip; >+ >+ /* BGP packet header fields */ >+ u_int16_t size; >+ u_char type; >+ >+ /* For OPEN packets */ >+ u_char version; >+ as_t my_as; >+ u_int16_t hold_time; >+ struct in_addr bgp_id; >+ u_char opt_len; >+ u_char *opt_data; >+ >+ /* For UPDATE packets */ >+ u_int16_t withdraw_count; >+ u_int16_t announce_count; >+ struct prefix withdraw[MAX_PREFIXES]; >+ struct prefix announce[MAX_PREFIXES]; >+ >+ /* For corrupt update dumps */ >+ u_int16_t cut_bytes; >+ struct zebra_incomplete incomplete; >+ >+ /* For NOTIFY packets */ >+ u_char error_code; >+ u_char sub_error_code; >+ u_int16_t notify_len; >+ u_char *notify_data; >+ >+} BGPDUMP_ZEBRA_MESSAGE; >+ >+/* For Zebra BGP4MP_ENTRY */ >+typedef struct struct_BGPDUMP_ZEBRA_ENTRY { >+ u_int16_t view; >+ u_int16_t status; >+ time_t time_last_change; >+ u_int16_t address_family; >+ u_char SAFI; >+ u_char next_hop_len; >+ u_char prefix_length; >+ u_char *address_prefix; >+ u_int16_t empty; >+ u_char *bgp_atribute; >+} BGPDUMP_ZEBRA_ENTRY; >+ >+/* For Zebra BGP4MP_SNAPSHOT */ >+typedef struct struct_BGPDUMP_ZEBRA_SNAPSHOT { >+ u_int16_t view; >+ u_int16_t file; >+} BGPDUMP_ZEBRA_SNAPSHOT; >+ >+typedef struct struct_BGPDUMP_MRTD_MESSAGE { >+ u_int16_t source_as; >+ struct in_addr source_ip; >+ u_int16_t destination_as; >+ struct in_addr destination_ip; >+ >+ u_int16_t withdraw_count; >+ u_int16_t announce_count; >+ struct prefix withdraw[MAX_PREFIXES]; >+ struct prefix announce[MAX_PREFIXES]; >+ >+ /* For corrupt update dumps */ >+ struct zebra_incomplete incomplete; >+} BGPDUMP_MRTD_MESSAGE; >+ >+typedef struct struct_BGPDUMP_MRTD_STATE_CHANGE { >+ u_int16_t destination_as; >+ struct in_addr destination_ip; >+ u_int16_t old_state; >+ u_int16_t new_state; >+} BGPDUMP_MRTD_STATE_CHANGE; >+ >+typedef union union_BGPDUMP_BODY { >+ BGPDUMP_MRTD_MESSAGE mrtd_message; >+ BGPDUMP_MRTD_STATE_CHANGE mrtd_state_change; >+ BGPDUMP_MRTD_TABLE_DUMP mrtd_table_dump; >+ BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE mrtd_table_dump_v2_peer_table; >+ BGPDUMP_TABLE_DUMP_V2_PREFIX mrtd_table_dump_v2_prefix; >+ BGPDUMP_ZEBRA_STATE_CHANGE zebra_state_change; >+ BGPDUMP_ZEBRA_MESSAGE zebra_message; >+ BGPDUMP_ZEBRA_ENTRY zebra_entry; >+ BGPDUMP_ZEBRA_SNAPSHOT zebra_snapshot; >+} BGPDUMP_BODY; >+ >+/* The MRT header. Common to all records. */ >+typedef struct struct_BGPDUMP_ENTRY { >+ time_t time; >+ u_int16_t type; >+ u_int16_t subtype; >+ u_int32_t length; >+ attributes_t *attr; >+ BGPDUMP_BODY body; >+} BGPDUMP_ENTRY; >+ >+#endif >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_lib.c libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_lib.c >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_lib.c 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_lib.c 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,1431 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+Parts of this code have been engineered after analiyzing GNU Zebra's >+source code and therefore might contain declarations/code from GNU >+Zebra, Copyright (C) 1999 Kunihiro Ishiguro. Zebra is a free routing >+software, distributed under the GNU General Public License. A copy of >+this license is included with libbgpdump. >+*/ >+ >+#include "bgpdump-config.h" >+#include "cfile_tools.h" >+#include "bgpdump_lib.h" >+#include "bgpdump_mstream.h" >+#include "util.h" >+ >+#include <sys/stat.h> >+#include <stdlib.h> >+#include <unistd.h> >+#include <stdbool.h> >+ >+#include <netinet/in.h> >+#include <sys/socket.h> >+#include <arpa/inet.h> >+ >+#include <zlib.h> >+#include <assert.h> >+ >+void bgpdump_free_attr(attributes_t *attr); >+static int process_mrtd_table_dump(struct mstream *s,BGPDUMP_ENTRY *entry); >+static int process_mrtd_table_dump_v2(struct mstream *s,BGPDUMP_ENTRY *entry); >+static int process_mrtd_table_dump_v2_peer_index_table(struct mstream *s,BGPDUMP_ENTRY *entry); >+static int process_mrtd_table_dump_v2_ipv4_unicast(struct mstream *s,BGPDUMP_ENTRY *entry); >+static int process_mrtd_table_dump_v2_ipv6_unicast(struct mstream *s,BGPDUMP_ENTRY *entry); >+static int process_zebra_bgp(struct mstream *s,BGPDUMP_ENTRY *entry); >+static int process_zebra_bgp_state_change(struct mstream *s,BGPDUMP_ENTRY *entry, u_int8_t asn_len); >+ >+static int process_zebra_bgp_message(struct mstream *s,BGPDUMP_ENTRY *entry, u_int8_t asn_len); >+static int process_zebra_bgp_message_update(struct mstream *s,BGPDUMP_ENTRY *entry, u_int8_t asn_len); >+static int process_zebra_bgp_message_open(struct mstream *s,BGPDUMP_ENTRY *entry, u_int8_t asn_len); >+static int process_zebra_bgp_message_notify(struct mstream *s,BGPDUMP_ENTRY *entry); >+ >+static int process_zebra_bgp_entry(struct mstream *s,BGPDUMP_ENTRY *entry); >+static int process_zebra_bgp_snapshot(struct mstream *s,BGPDUMP_ENTRY *entry); >+ >+static attributes_t *process_attributes(struct mstream *s, u_int8_t asn_len, struct zebra_incomplete *incomplete); >+static void process_attr_aspath_string(struct aspath *as); >+static char aspath_delimiter_char (u_char type, u_char which); >+static void process_attr_community_string(struct community *com); >+ >+static void process_mp_announce(struct mstream *s, struct mp_info *info, struct zebra_incomplete *incomplete); >+static void process_mp_withdraw(struct mstream *s, struct mp_info *info, struct zebra_incomplete *incomplete); >+static int read_prefix_list(struct mstream *s, u_int16_t af, struct prefix *prefixes, struct zebra_incomplete *incomplete); >+ >+static as_t read_asn(struct mstream *s, as_t *asn, u_int8_t len); >+static struct aspath *create_aspath(u_int16_t len, u_int8_t asn_len); >+static void aspath_error(struct aspath *as); >+static int check_new_aspath(struct aspath *aspath); >+static void process_asn32_trans(attributes_t *attr, u_int8_t asn_len); >+static struct aspath *asn32_merge_paths(struct aspath *path, struct aspath *newpath); >+static void asn32_expand_16_to_32(char *dst, char *src, int len); >+ >+BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE *table_dump_v2_peer_index_table = NULL; >+ >+#if defined(linux) >+static size_t strlcat(char *dst, const char *src, size_t size); >+#endif >+ >+char *bgpdump_version(void) { >+ return PACKAGE_VERSION; >+} >+ >+ >+BGPDUMP *bgpdump_open_dump(const char *filename) { >+ >+ CFRFILE *f = cfr_open(filename); >+ if(! f) { >+ perror("can't open dumpfile"); >+ return NULL; >+ } >+ >+ BGPDUMP *this_dump = malloc(sizeof(BGPDUMP)); >+ strcpy(this_dump->filename, "[STDIN]"); >+ if(filename && strcmp(filename, "-")) { >+ strcpy(this_dump->filename, filename); >+ } >+ >+ this_dump->f = f; >+ this_dump->eof=0; >+ this_dump->parsed = 0; >+ this_dump->parsed_ok = 0; >+ >+ return this_dump; >+} >+ >+void bgpdump_close_dump(BGPDUMP *dump) { >+ if(dump!=NULL) { >+ >+ if(table_dump_v2_peer_index_table){ >+ if(table_dump_v2_peer_index_table->entries) { >+ free(table_dump_v2_peer_index_table->entries); >+ table_dump_v2_peer_index_table->entries = NULL; >+ } >+ free(table_dump_v2_peer_index_table); >+ table_dump_v2_peer_index_table = NULL; >+ } >+ cfr_close(dump->f); >+ free(dump); >+ } >+} >+ >+BGPDUMP_ENTRY* bgpdump_read_next(BGPDUMP *dump) { >+ assert(dump); >+ >+ BGPDUMP_ENTRY *this_entry=NULL; >+ struct mstream s; >+ u_char *buffer; >+ int ok=0; >+ u_int32_t bytes_read; >+ >+ this_entry = malloc(sizeof(BGPDUMP_ENTRY)); >+ >+ bytes_read = cfr_read_n(dump->f, &(this_entry->time), 4); >+ bytes_read += cfr_read_n(dump->f, &(this_entry->type), 2); >+ bytes_read += cfr_read_n(dump->f, &(this_entry->subtype), 2); >+ bytes_read += cfr_read_n(dump->f, &(this_entry->length), 4); >+ if(bytes_read != 12) { >+ if(bytes_read > 0) { >+ /* Malformed record */ >+ dump->parsed++; >+ err("bgpdump_read_next: incomplete MRT header (%d bytes read, expecting 12)", >+ bytes_read); >+ } >+ /* Nothing more to read, quit */ >+ free(this_entry); >+ dump->eof=1; >+ return(NULL); >+ } >+ >+ dump->parsed++; >+ >+ /* Intel byte ordering stuff ... */ >+ this_entry->type=ntohs(this_entry->type); >+ this_entry->subtype=ntohs(this_entry->subtype); >+ this_entry->time=ntohl(this_entry->time); >+ this_entry->length=ntohl(this_entry->length); >+ >+ this_entry->attr=NULL; >+ >+ buffer = malloc(this_entry->length); >+ bytes_read = cfr_read_n(dump->f, buffer, this_entry->length); >+ if(bytes_read != this_entry->length) { >+ err("bgpdump_read_next: incomplete dump record (%d bytes read, expecting %d)", >+ bytes_read, this_entry->length); >+ free(this_entry); >+ free(buffer); >+ dump->eof=1; >+ return(NULL); >+ } >+ >+ >+ ok=0; >+ mstream_init(&s,buffer,this_entry->length); >+ >+ switch(this_entry->type) { >+ case BGPDUMP_TYPE_MRTD_BGP: >+ ok = process_mrtd_bgp(&s,this_entry); >+ break; >+ case BGPDUMP_TYPE_MRTD_TABLE_DUMP: >+ ok = process_mrtd_table_dump(&s,this_entry); >+ break; >+ case BGPDUMP_TYPE_ZEBRA_BGP: >+ ok = process_zebra_bgp(&s,this_entry); >+ break; >+ case BGPDUMP_TYPE_TABLE_DUMP_V2: >+ ok = process_mrtd_table_dump_v2(&s,this_entry); >+ break; >+ } >+ >+ free(buffer); >+ if(ok) { >+ dump->parsed_ok++; >+ } else { >+ bgpdump_free_mem(this_entry); >+ return NULL; >+ } >+ return this_entry; >+} >+ >+static void bgpdump_free_mp_info(struct mp_info *info) { >+ u_int16_t afi; >+ u_int8_t safi; >+ >+ for(afi = 1; afi <= BGPDUMP_MAX_AFI; afi++) { >+ for(safi = 1; safi < BGPDUMP_MAX_SAFI; safi++) { >+ if(info->announce[afi][safi]) >+ free(info->announce[afi][safi]); >+ info->announce[afi][safi] = NULL; >+ if(info->withdraw[afi][safi]) { >+ free(info->withdraw[afi][safi]); >+ info->withdraw[afi][safi] = NULL; >+ } >+ } >+ } >+ >+ free(info); >+} >+ >+void bgpdump_free_mem(BGPDUMP_ENTRY *entry) { >+ >+ if(entry!=NULL) { >+ >+ bgpdump_free_attr(entry->attr); >+ >+ switch(entry->type) { >+ case BGPDUMP_TYPE_ZEBRA_BGP: >+ switch(entry->subtype) { >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE: >+ switch(entry->body.zebra_message.type) { >+ case BGP_MSG_NOTIFY: >+ if(entry->body.zebra_message.notify_data) >+ free(entry->body.zebra_message.notify_data); >+ break; >+ case BGP_MSG_OPEN: >+ if(entry->body.zebra_message.opt_data) >+ free(entry->body.zebra_message.opt_data); >+ break; >+ } >+ break; >+ } >+ break; >+ case BGPDUMP_TYPE_TABLE_DUMP_V2: >+ if(entry->subtype == BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_IPV4_UNICAST || >+ entry->subtype == BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_IPV6_UNICAST ){ >+ >+ BGPDUMP_TABLE_DUMP_V2_PREFIX *e; >+ e = &entry->body.mrtd_table_dump_v2_prefix; >+ int i; >+ >+ for(i = 0; i < e->entry_count; i++){ >+ bgpdump_free_attr(e->entries[i].attr); >+ } >+ free(e->entries); >+ } >+ break; >+ } >+ >+ free(entry); >+ } >+} >+ >+void bgpdump_free_attr(attributes_t *attr){ >+ if(attr != NULL) { >+ u_int16_t i; >+ struct aspath *path, *pathstofree[3] = { attr->aspath, attr->old_aspath, attr->new_aspath }; >+ for(i = 0; i < sizeof(pathstofree) / sizeof(pathstofree[0]); i++) { >+ path = pathstofree[i]; >+ if(path) { >+ if(path->data) >+ free(path->data); >+ if(path->str) >+ free(path->str); >+ free(path); >+ } >+ } >+ >+ if(attr->community != NULL) { >+ if(attr->community->val != NULL) >+ free(attr->community->val); >+ >+ if(attr->community->str != NULL) >+ free(attr->community->str); >+ >+ free(attr->community); >+ } >+ >+ if(attr->data != NULL) >+ free(attr->data); >+ >+ if(attr->mp_info != NULL) >+ bgpdump_free_mp_info(attr->mp_info); >+ >+ if(attr->cluster != NULL) { >+ free(attr->cluster->list); >+ free(attr->cluster); >+ } >+ >+ if (attr->unknown_num) { >+ for (i = 0; i < attr->unknown_num; i++) >+ free(attr->unknown[i].raw); >+ free(attr->unknown); >+ } >+ >+ free(attr); >+ } >+} >+ >+ >+int process_mrtd_bgp(struct mstream *s, BGPDUMP_ENTRY *entry) { >+ switch(entry->subtype) { >+ case BGPDUMP_SUBTYPE_MRTD_BGP_UPDATE: >+ case BGPDUMP_SUBTYPE_MRTD_BGP_KEEPALIVE: >+ read_asn(s, &entry->body.mrtd_message.source_as, ASN16_LEN); >+ entry->body.mrtd_message.source_ip = mstream_get_ipv4(s); >+ >+ read_asn(s, &entry->body.mrtd_message.destination_as, ASN16_LEN); >+ entry->body.mrtd_message.destination_ip = mstream_get_ipv4(s); >+ >+ mstream_t withdraw_stream = mstream_copy(s, mstream_getw(s, NULL)); >+ entry->body.mrtd_message.withdraw_count = read_prefix_list(&withdraw_stream, AFI_IP, >+ entry->body.mrtd_message.withdraw, >+ &entry->body.mrtd_message.incomplete); >+ >+ entry->attr = process_attributes(s, ASN16_LEN, &entry->body.mrtd_message.incomplete); >+ >+ entry->body.mrtd_message.announce_count = read_prefix_list(s, AFI_IP, >+ entry->body.mrtd_message.announce, >+ &entry->body.mrtd_message.incomplete); >+ break; >+ case BGPDUMP_SUBTYPE_MRTD_BGP_STATE_CHANGE: >+ read_asn(s, &entry->body.mrtd_state_change.destination_as, ASN16_LEN); >+ entry->body.mrtd_state_change.destination_ip = mstream_get_ipv4(s); >+ entry->body.mrtd_state_change.old_state = mstream_getw(s, NULL); >+ entry->body.mrtd_state_change.new_state = mstream_getw(s, NULL); >+ break; >+ } >+ return 1; >+} >+ >+int process_mrtd_table_dump(struct mstream *s,BGPDUMP_ENTRY *entry) { >+ int afi = entry->subtype; >+ u_int8_t asn_len; >+ u_int32_t temp_time = 0; >+ mstream_getw(s,&entry->body.mrtd_table_dump.view); >+ mstream_getw(s,&entry->body.mrtd_table_dump.sequence); >+ switch(afi) { >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP: >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP_32BIT_AS: >+ entry->body.mrtd_table_dump.prefix.v4_addr = mstream_get_ipv4(s); >+ break; >+#ifdef BGPDUMP_HAVE_IPV6 >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6: >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6_32BIT_AS: >+ mstream_get(s, &entry->body.mrtd_table_dump.prefix.v6_addr.s6_addr, 16); >+ break; >+#endif >+ default: >+ warn("process_mrtd_table_dump: unknown AFI %d", afi); >+ mstream_get(s, NULL, mstream_can_read(s)); >+ return 0; >+ } >+ mstream_getc(s,&entry->body.mrtd_table_dump.mask); >+ mstream_getc(s,&entry->body.mrtd_table_dump.status); >+ mstream_getl(s,&temp_time); >+ (entry->body).mrtd_table_dump.uptime = temp_time; >+ >+ switch(afi) { >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP: >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP_32BIT_AS: >+ entry->body.mrtd_table_dump.peer_ip.v4_addr = mstream_get_ipv4(s); >+ break; >+#ifdef BGPDUMP_HAVE_IPV6 >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6: >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6_32BIT_AS: >+ mstream_get(s, &entry->body.mrtd_table_dump.peer_ip.v6_addr.s6_addr, 16); >+ break; >+#endif >+ } >+ >+ switch(afi) { >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP: >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6: >+ asn_len = ASN16_LEN; >+ break; >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP_32BIT_AS: >+ case BGPDUMP_SUBTYPE_MRTD_TABLE_DUMP_AFI_IP6_32BIT_AS: >+ asn_len = ASN32_LEN; >+ break; >+ default: >+ assert(0); // unreachable >+ } >+ >+ read_asn(s,&entry->body.mrtd_table_dump.peer_as, asn_len); >+ >+ entry->attr = process_attributes(s, asn_len, NULL); >+ >+ return 1; >+} >+ >+ >+int process_mrtd_table_dump_v2(struct mstream *s,BGPDUMP_ENTRY *entry) { >+ >+ switch(entry->subtype){ >+ case BGPDUMP_SUBTYPE_TABLE_DUMP_V2_PEER_INDEX_TABLE: >+ return process_mrtd_table_dump_v2_peer_index_table(s, entry); >+ break; >+ case BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_IPV4_UNICAST: >+ return process_mrtd_table_dump_v2_ipv4_unicast(s, entry); >+ break; >+ case BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_IPV6_UNICAST: >+ return process_mrtd_table_dump_v2_ipv6_unicast(s, entry); >+ break; >+ case BGPDUMP_SUBTYPE_TABLE_DUMP_V2_RIB_GENERIC: >+ //return process_mrtd_table_dump_v2_generic(s, entry); >+ break; >+ } >+ >+ return 0; >+} >+ >+int process_mrtd_table_dump_v2_peer_index_table(struct mstream *s,BGPDUMP_ENTRY *entry) { >+ BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE *t; >+ uint16_t i; >+ uint8_t peertype; >+ uint16_t view_name_len; >+ >+ if(table_dump_v2_peer_index_table){ >+ if(table_dump_v2_peer_index_table->entries) >+ free(table_dump_v2_peer_index_table->entries); >+ free(table_dump_v2_peer_index_table); >+ } >+ >+ table_dump_v2_peer_index_table = malloc(sizeof(BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE)); >+ t = table_dump_v2_peer_index_table; >+ t->entries = NULL; >+ >+ t->local_bgp_id = mstream_get_ipv4(s); >+ >+ mstream_getw(s,&view_name_len); >+ strcpy(t->view_name, ""); >+ >+ // view_name_len is without trailing \0 >+ if(view_name_len+1 > BGPDUMP_TYPE_TABLE_DUMP_V2_MAX_VIEWNAME_LEN) { >+ warn("process_mrtd_table_dump_v2_peer_index_table: view name length more than maximum length (%d), ignoring view name", BGPDUMP_TYPE_TABLE_DUMP_V2_MAX_VIEWNAME_LEN); >+ } else { >+ mstream_get(s, t->view_name, view_name_len); >+ t->view_name[view_name_len] = 0; >+ } >+ >+ mstream_getw(s,&t->peer_count); >+ >+ t->entries = malloc(sizeof(BGPDUMP_TABLE_DUMP_V2_PEER_INDEX_TABLE_ENTRY) * t->peer_count); >+ if(t->entries == NULL){ >+ err("process_mrtd_table_dump_v2_peer_index_table: failed to allocate memory for index table"); >+ return 0; >+ } >+ >+ for(i=0; i < t->peer_count; i++) { >+ mstream_getc(s,&peertype); >+ t->entries[i].afi = AFI_IP; >+#ifdef BGPDUMP_HAVE_IPV6 >+ if(peertype & BGPDUMP_PEERTYPE_TABLE_DUMP_V2_AFI_IP6) >+ t->entries[i].afi = AFI_IP6; >+#endif >+ >+ t->entries[i].peer_bgp_id = mstream_get_ipv4(s); >+ >+ if(t->entries[i].afi == AFI_IP) >+ t->entries[i].peer_ip.v4_addr = mstream_get_ipv4(s); >+#ifdef BGPDUMP_HAVE_IPV6 >+ else >+ mstream_get(s, &t->entries[i].peer_ip.v6_addr.s6_addr, 16); >+#endif >+ >+ >+ if(peertype & BGPDUMP_PEERTYPE_TABLE_DUMP_V2_AS4) >+ read_asn(s, &t->entries[i].peer_as, 4); >+ else >+ read_asn(s, &t->entries[i].peer_as, 2); >+ >+ } >+ return 0; >+} >+ >+ >+int process_mrtd_table_dump_v2_ipv4_unicast(struct mstream *s, BGPDUMP_ENTRY *entry){ >+ BGPDUMP_TABLE_DUMP_V2_PREFIX *prefixdata; >+ prefixdata = &entry->body.mrtd_table_dump_v2_prefix; >+ uint16_t i; >+ >+ prefixdata->afi = AFI_IP; >+ prefixdata->safi = SAFI_UNICAST; >+ >+ mstream_getl(s, &prefixdata->seq); >+ mstream_getc(s, &prefixdata->prefix_length); >+ bzero(&prefixdata->prefix.v4_addr.s_addr, 4); >+ mstream_get(s, &prefixdata->prefix.v4_addr.s_addr, (prefixdata->prefix_length+7)/8); >+ mstream_getw(s, &prefixdata->entry_count); >+ >+ prefixdata->entries = malloc(sizeof(BGPDUMP_TABLE_DUMP_V2_ROUTE_ENTRY) * prefixdata->entry_count); >+ if(prefixdata->entries == NULL){ >+ err("process_mrtd_table_dump_v2_ipv4_unicast: failed to allocate memory for entry table"); >+ return 0; >+ } >+ >+ for(i=0; i < prefixdata->entry_count; i++){ >+ BGPDUMP_TABLE_DUMP_V2_ROUTE_ENTRY *e; >+ e = &prefixdata->entries[i]; >+ >+ mstream_getw(s, &e->peer_index); >+ e->peer = &table_dump_v2_peer_index_table->entries[e->peer_index]; >+ mstream_getl(s, &e->originated_time); >+ >+ e->attr = process_attributes(s, 4, NULL); >+ } >+ >+ return 1; >+} >+ >+ >+int process_mrtd_table_dump_v2_ipv6_unicast(struct mstream *s, BGPDUMP_ENTRY *entry){ >+#ifdef BGPDUMP_HAVE_IPV6 >+ BGPDUMP_TABLE_DUMP_V2_PREFIX *prefixdata; >+ prefixdata = &entry->body.mrtd_table_dump_v2_prefix; >+ uint16_t i; >+ >+ prefixdata->afi = AFI_IP6; >+ prefixdata->safi = SAFI_UNICAST; >+ >+ mstream_getl(s, &prefixdata->seq); >+ >+ mstream_getc(s, &prefixdata->prefix_length); >+ bzero(&prefixdata->prefix.v6_addr.s6_addr, 16); >+ mstream_get(s, &prefixdata->prefix.v6_addr.s6_addr, (prefixdata->prefix_length+7)/8); >+ >+ mstream_getw(s, &prefixdata->entry_count); >+ >+ prefixdata->entries = malloc(sizeof(BGPDUMP_TABLE_DUMP_V2_ROUTE_ENTRY) * prefixdata->entry_count); >+ if(prefixdata->entries == NULL){ >+ err("process_mrtd_table_dump_v2_ipv6_unicast: failed to allocate memory for entry table"); >+ return 0; >+ } >+ >+ for(i=0; i < prefixdata->entry_count; i++){ >+ BGPDUMP_TABLE_DUMP_V2_ROUTE_ENTRY *e; >+ e = &prefixdata->entries[i]; >+ >+ mstream_getw(s, &e->peer_index); >+ e->peer = &table_dump_v2_peer_index_table->entries[e->peer_index]; >+ mstream_getl(s, &e->originated_time); >+ >+ e->attr = process_attributes(s, 4, NULL); >+ } >+ >+#endif >+ return 1; >+} >+ >+int process_zebra_bgp(struct mstream *s,BGPDUMP_ENTRY *entry) { >+ switch(entry->subtype) { >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_STATE_CHANGE: >+ return process_zebra_bgp_state_change(s, entry, ASN16_LEN); >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_STATE_CHANGE_AS4: >+ return process_zebra_bgp_state_change(s, entry, ASN32_LEN); >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE: >+ return process_zebra_bgp_message(s, entry, ASN16_LEN); >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE_AS4: >+ return process_zebra_bgp_message(s, entry, ASN32_LEN); >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_ENTRY: >+ return process_zebra_bgp_entry(s,entry); >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_SNAPSHOT: >+ return process_zebra_bgp_snapshot(s, entry); >+ default: >+ warn("process_zebra_bgp: unknown subtype %d", entry->subtype); >+ return 0; >+ } >+} >+ >+int process_zebra_bgp_state_change(struct mstream *s,BGPDUMP_ENTRY *entry, u_int8_t asn_len) { >+ read_asn(s, &entry->body.zebra_state_change.source_as, asn_len); >+ read_asn(s, &entry->body.zebra_state_change.destination_as, asn_len); >+ >+ /* Work around Zebra dump corruption. >+ * N.B. I don't see this in quagga 0.96.4 any more. Is it fixed? */ >+ if (entry->length == 8) { >+ warn("process_zebra_bgp_state_change: 8-byte state change (zebra bug?)"); >+ >+ mstream_getw(s,&entry->body.zebra_state_change.old_state); >+ mstream_getw(s,&entry->body.zebra_state_change.new_state); >+ >+ /* Fill in with dummy values */ >+ entry->body.zebra_state_change.interface_index = 0; >+ entry->body.zebra_state_change.address_family = AFI_IP; >+ entry->body.zebra_state_change.source_ip.v4_addr.s_addr = 0; >+ entry->body.zebra_state_change.destination_ip.v4_addr.s_addr = 0; >+ >+ return 1; >+ } >+ >+ mstream_getw(s,&entry->body.zebra_state_change.interface_index); >+ mstream_getw(s,&entry->body.zebra_state_change.address_family); >+ >+ switch(entry->body.zebra_state_change.address_family) { >+ case AFI_IP: >+ // length could be 20 or 24 (asn16 vs asn32) >+ if(entry->length != 20 && entry->length != 24) { >+ warn("process_zebra_bgp_state_change: bad length %d", >+ entry->length); >+ return 0; >+ } >+ >+ entry->body.zebra_state_change.source_ip.v4_addr = mstream_get_ipv4(s); >+ entry->body.zebra_state_change.destination_ip.v4_addr = mstream_get_ipv4(s); >+ break; >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ // length could be 44 or 48 (asn16 vs asn32) >+ if(entry->length != 44 && entry->length != 48) { >+ warn("process_zebra_bgp_state_change: bad length %d", >+ entry->length); >+ return 0; >+ } >+ >+ mstream_get(s, &entry->body.zebra_state_change.source_ip.v6_addr.s6_addr, 16); >+ mstream_get(s, &entry->body.zebra_state_change.destination_ip.v6_addr.s6_addr, 16); >+ break; >+#endif >+ default: >+ warn("process_zebra_bgp_state_change: unknown AFI %d", >+ entry->body.zebra_state_change.address_family); >+ return 0; >+ } >+ mstream_getw(s,&entry->body.zebra_state_change.old_state); >+ mstream_getw(s,&entry->body.zebra_state_change.new_state); >+ >+ return 1; >+} >+ >+int process_zebra_bgp_message(struct mstream *s,BGPDUMP_ENTRY *entry, u_int8_t asn_len) { >+ u_char marker[16]; /* BGP marker */ >+ >+ read_asn(s, &entry->body.zebra_message.source_as, asn_len); >+ read_asn(s, &entry->body.zebra_message.destination_as, asn_len); >+ mstream_getw(s,&entry->body.zebra_message.interface_index); >+ mstream_getw(s,&entry->body.zebra_message.address_family); >+ >+ entry->body.zebra_message.opt_len = 0; >+ entry->body.zebra_message.opt_data = NULL; >+ entry->body.zebra_message.notify_len = 0; >+ entry->body.zebra_message.notify_data = NULL; >+ >+ switch(entry->body.zebra_message.address_family) { >+ case AFI_IP: >+ entry->body.zebra_message.source_ip.v4_addr = mstream_get_ipv4(s); >+ entry->body.zebra_message.destination_ip.v4_addr = mstream_get_ipv4(s); >+ mstream_get (s, marker, 16); >+ break; >+#ifdef BGPDUMP_HAVE_IPV6 >+ case AFI_IP6: >+ mstream_get(s,&entry->body.zebra_message.source_ip.v6_addr.s6_addr, 16); >+ mstream_get(s,&entry->body.zebra_message.destination_ip.v6_addr.s6_addr, 16); >+ mstream_get (s, marker, 16); >+ break; >+#endif >+ case 0xFFFF: >+ /* Zebra doesn't dump ifindex or src/dest IPs in OPEN >+ * messages. Work around it. */ >+ if (entry->body.zebra_message.interface_index == 0xFFFF) { >+ memset(marker, 0xFF, 4); >+ mstream_get (s, marker + 4, 12); >+ entry->body.zebra_message.interface_index = 0; >+ entry->body.zebra_message.address_family = AFI_IP; >+ entry->body.zebra_message.source_ip.v4_addr.s_addr = 0; >+ entry->body.zebra_message.destination_ip.v4_addr.s_addr = 0; >+ break; >+ } >+ /* Note fall through! If we don't recognize this type of data corruption, we say >+ * the address family is unsupported (since FFFF is not a valid address family) */ >+ default: >+ /* unsupported address family */ >+ warn("process_zebra_bgp_message: unsupported AFI %d", >+ entry->body.zebra_message.address_family); >+ return 0; >+ } >+ >+ if(memcmp(marker, "\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377", 16) != 0) { >+ /* bad marker... ignore packet */ >+ warn( >+ "bgp_message: bad marker: %02x.%02x.%02x.%02x.%02x.%02x.%02x.%02x.%02x.%02x.%02x.%02x.%02x.%02x.%02x.%02x", >+ marker[0],marker[1],marker[2],marker[3],marker[4],marker[5],marker[6],marker[7], >+ marker[8],marker[9],marker[10],marker[11],marker[12],marker[13],marker[14],marker[15]); >+ return 0; >+ } >+ >+ mstream_getw(s,&entry->body.zebra_message.size); >+ >+ int expected = entry->body.zebra_message.size - sizeof(marker) - sizeof(u_int16_t); >+ >+ mstream_t copy = mstream_copy(s, expected); >+ >+ entry->body.zebra_message.cut_bytes = expected - mstream_can_read(©); >+ >+ switch(mstream_getc (©, &entry->body.zebra_message.type)) { >+ case BGP_MSG_OPEN: >+ return process_zebra_bgp_message_open(©, entry, asn_len); >+ case BGP_MSG_UPDATE: >+ return process_zebra_bgp_message_update(©, entry, asn_len); >+ case BGP_MSG_NOTIFY: >+ return process_zebra_bgp_message_notify(©, entry); >+ case BGP_MSG_KEEPALIVE: >+ /* Nothing to do */ >+ return 1; >+ case BGP_MSG_ROUTE_REFRESH_01: >+ /* Not implemented yet */ >+ warn("bgp_message: MSG_ROUTE_REFRESH_01 not implemented yet"); >+ return 0; >+ case BGP_MSG_ROUTE_REFRESH: >+ /* Not implemented yet */ >+ warn("bgp_message: MSG_ROUTE_REFRESH not implemented yet"); >+ return 0; >+ default: >+ warn("bgp_message: unknown BGP message type %d", >+ entry->body.zebra_message.type); >+ return 0; >+ } >+} >+ >+int process_zebra_bgp_message_notify(struct mstream *s, BGPDUMP_ENTRY *entry) { >+ mstream_getc(s, &entry->body.zebra_message.error_code); >+ mstream_getc(s, &entry->body.zebra_message.sub_error_code); >+ entry->body.zebra_message.notify_len = entry->body.zebra_message.size - 21; >+ >+ if(entry->body.zebra_message.notify_len > 0) { >+ entry->body.zebra_message.notify_data = malloc(entry->body.zebra_message.notify_len); >+ mstream_get(s, entry->body.zebra_message.notify_data, entry->body.zebra_message.notify_len); >+ } >+ >+ return 1; >+} >+ >+int process_zebra_bgp_message_open(struct mstream *s, BGPDUMP_ENTRY *entry, u_int8_t asn_len) { >+ mstream_getc(s, &entry->body.zebra_message.version); >+ read_asn(s, &entry->body.zebra_message.my_as, asn_len); >+ mstream_getw(s, &entry->body.zebra_message.hold_time); >+ entry->body.zebra_message.bgp_id = mstream_get_ipv4(s); >+ mstream_getc(s, &entry->body.zebra_message.opt_len); >+ >+ if(entry->body.zebra_message.opt_len) { >+ entry->body.zebra_message.opt_data = malloc(entry->body.zebra_message.opt_len); >+ mstream_get(s, entry->body.zebra_message.opt_data, entry->body.zebra_message.opt_len); >+ } >+ >+ return 1; >+} >+ >+int process_zebra_bgp_message_update(struct mstream *s, BGPDUMP_ENTRY *entry, u_int8_t asn_len) { >+ entry->body.zebra_message.incomplete.orig_len = 0; >+ >+ mstream_t withdraw_stream = mstream_copy(s, mstream_getw(s, NULL)); >+ entry->body.zebra_message.withdraw_count = read_prefix_list(&withdraw_stream, AFI_IP, >+ entry->body.zebra_message.withdraw, >+ &entry->body.zebra_message.incomplete); >+ >+ entry->attr = process_attributes(s, asn_len, &entry->body.zebra_message.incomplete); >+ >+ entry->body.zebra_message.announce_count = read_prefix_list(s, AFI_IP, >+ entry->body.zebra_message.announce, >+ &entry->body.zebra_message.incomplete); >+ >+ return 1; >+} >+ >+int process_zebra_bgp_entry(struct mstream *s, BGPDUMP_ENTRY *entry) { >+ warn("process_zebra_bgp_entry: record type not implemented yet"); >+ return 0; >+} >+ >+int process_zebra_bgp_snapshot(struct mstream *s, BGPDUMP_ENTRY *entry) { >+ warn("process_zebra_bgp_snapshot: record type not implemented yet"); >+ return 0; >+} >+ >+static attributes_t *attr_init(struct mstream *s, int len) { >+ >+ attributes_t *attr = malloc(sizeof(struct attr)); >+ >+ attr->data=malloc(len); >+ memcpy(attr->data, &s->start[s->position], len); >+ >+ attr->len = len; >+ attr->flag = 0; >+ attr->origin = -1; >+ attr->nexthop.s_addr = INADDR_NONE; >+ attr->med = -1; >+ attr->local_pref = -1; >+ attr->aggregator_as = -1; >+ attr->aggregator_addr.s_addr = INADDR_NONE; >+ attr->weight = -1; >+ >+ attr->originator_id.s_addr = -1; >+ attr->cluster = NULL; >+ >+ attr->aspath = NULL; >+ attr->community = NULL; >+ attr->transit = NULL; >+ attr->mp_info = calloc(1, sizeof(struct mp_info));; >+ >+ attr->unknown_num = 0; >+ attr->unknown = NULL; >+ >+ attr->new_aspath = NULL; >+ attr->old_aspath = NULL; >+ attr->new_aggregator_as = -1; >+ attr->new_aggregator_addr.s_addr = INADDR_NONE; >+ >+ return attr; >+} >+ >+static void process_unknown_attr(struct mstream *s, attributes_t *attr, int flag, int type, int len) { >+ /* Unknown attribute. Save as is */ >+ attr->unknown_num++; >+ attr->unknown = realloc(attr->unknown, attr->unknown_num * sizeof(struct unknown_attr)); >+ >+ /* Pointer to the unknown attribute we want to fill in */ >+ struct unknown_attr unknown = { >+ .flag = flag, >+ .type = type, >+ .len = len, >+ .raw = malloc(len) >+ }; >+ >+ attr->unknown[attr->unknown_num - 1] = unknown; >+ >+ mstream_get(s, unknown.raw, len); >+} >+ >+static void process_one_attr(struct mstream *outer_stream, attributes_t *attr, u_int8_t asn_len, struct zebra_incomplete *incomplete) { >+ int flag = mstream_getc(outer_stream, NULL); >+ int type = mstream_getc(outer_stream, NULL); >+ int len; >+ >+ if(flag & BGP_ATTR_FLAG_EXTLEN) >+ len = mstream_getw(outer_stream,NULL); >+ else >+ len = mstream_getc(outer_stream,NULL); >+ >+ //info("flag:%-2i type:%-2i length:%i", flag, type, len); >+ >+ mstream_t ms = mstream_copy(outer_stream, len), *s = &ms; >+ if(mstream_can_read(s) != len) { >+ warn("ERROR attribute is truncated: expected=%u remaining=%u\n", len, mstream_can_read(s)); >+ return; >+ } >+ >+ /* Take note of all attributes, including unknown ones */ >+ if(type <= sizeof(attr->flag) * 8) >+ attr->flag |= ATTR_FLAG_BIT(type); >+ >+ switch(type) { >+ case BGP_ATTR_MP_REACH_NLRI: >+ process_mp_announce(s, attr->mp_info, incomplete); >+ break; >+ case BGP_ATTR_MP_UNREACH_NLRI: >+ process_mp_withdraw(s, attr->mp_info, incomplete); >+ break; >+ case BGP_ATTR_ORIGIN: >+ assert(attr->origin == -1); >+ attr->origin = mstream_getc(s, NULL); >+ break; >+ case BGP_ATTR_AS_PATH: >+ assert(! attr->aspath); >+ attr->aspath = create_aspath(len, asn_len); >+ mstream_get(s, attr->aspath->data, len); >+ process_attr_aspath_string(attr->aspath); >+ break; >+ case BGP_ATTR_NEXT_HOP: >+ assert(INADDR_NONE == attr->nexthop.s_addr); >+ attr->nexthop = mstream_get_ipv4(s); >+ break; >+ case BGP_ATTR_MULTI_EXIT_DISC: >+ assert(-1 == attr->med); >+ mstream_getl(s,&attr->med); >+ break; >+ case BGP_ATTR_LOCAL_PREF: >+ assert(-1 == attr->local_pref); >+ mstream_getl(s,&attr->local_pref); >+ break; >+ case BGP_ATTR_ATOMIC_AGGREGATE: >+ break; >+ case BGP_ATTR_AGGREGATOR: >+ assert(-1 == attr->new_aggregator_as); >+ read_asn(s, &attr->aggregator_as, asn_len); >+ attr->aggregator_addr = mstream_get_ipv4(s); >+ break; >+ case BGP_ATTR_COMMUNITIES: >+ assert(! attr->community); >+ attr->community = malloc(sizeof(struct community)); >+ attr->community->size = len / 4; >+ attr->community->val = malloc(len); >+ mstream_get(s,attr->community->val,len); >+ attr->community->str = NULL; >+ process_attr_community_string(attr->community); >+ break; >+ case BGP_ATTR_NEW_AS_PATH: >+ assert(! attr->new_aspath); >+ attr->new_aspath = create_aspath(len, ASN32_LEN); >+ mstream_get(s,attr->new_aspath->data, len); >+ process_attr_aspath_string(attr->new_aspath); >+ /* AS_CONFED_SEQUENCE and AS_CONFED_SET segments invalid in NEW_AS_PATH */ >+ check_new_aspath(attr->new_aspath); >+ break; >+ case BGP_ATTR_NEW_AGGREGATOR: >+ assert(-1 == attr->new_aggregator_as); >+ read_asn(s, &attr->new_aggregator_as, ASN32_LEN); >+ attr->new_aggregator_addr = mstream_get_ipv4(s); >+ break; >+ case BGP_ATTR_ORIGINATOR_ID: >+ assert(INADDR_NONE == attr->originator_id.s_addr); >+ attr->originator_id = mstream_get_ipv4(s); >+ break; >+ case BGP_ATTR_CLUSTER_LIST: >+ assert(! attr->cluster); >+ attr->cluster = malloc(sizeof(struct cluster_list)); >+ attr->cluster->length = len/4; >+ attr->cluster->list = malloc((attr->cluster->length) * sizeof(struct in_addr)); >+ >+ int i; // cluster index >+ for (i = 0; i < attr->cluster->length; i++) >+ attr->cluster->list[i] = mstream_get_ipv4(s); >+ break; >+ default: >+ process_unknown_attr(s, attr, flag, type, len); >+ } >+} >+ >+attributes_t *process_attributes(struct mstream *s, u_int8_t asn_len, struct zebra_incomplete *incomplete) { >+ int total = mstream_getw(s, NULL); >+ >+ attributes_t *attr = attr_init(s, total); >+ mstream_t copy = mstream_copy(s, total); >+ >+ if(mstream_can_read(©) != total) >+ warn("entry is truncated: expected=%u remaining=%u", total, mstream_can_read(©)); >+ >+ while(mstream_can_read(©)) >+ process_one_attr(©, attr, asn_len, incomplete); >+ >+ // Once all attributes have been read, take care of ASN32 transition >+ process_asn32_trans(attr, asn_len); >+ >+ return attr; >+} >+ >+struct aspath *create_aspath(u_int16_t len, u_int8_t asn_len) { >+ struct aspath *aspath = malloc(sizeof(struct aspath)); >+ if(aspath) { >+ aspath->asn_len = asn_len; >+ aspath->length = len; >+ aspath->count = 0; >+ aspath->str = NULL; >+ if(len > 0) >+ aspath->data = malloc(len); >+ else >+ aspath->data = NULL; >+ } >+ return aspath; >+} >+ >+void aspath_error(struct aspath *as) { >+ as->count = 0; >+ >+ if(as->str) { >+ free(as->str); >+ as->str = NULL; >+ } >+ >+ as->str = malloc(strlen(ASPATH_STR_ERROR) + 1); >+ strcpy(as->str, ASPATH_STR_ERROR); >+} >+ >+void process_attr_aspath_string(struct aspath *as) { >+ const int MAX_ASPATH_LEN = 8000; >+ as->str = malloc(MAX_ASPATH_LEN); >+ >+ /* Set default values */ >+ int space = 0; >+ u_char type = AS_SEQUENCE; >+ int pos = 0; >+ >+ /* Set initial pointer. */ >+ caddr_t pnt = as->data; >+ caddr_t end = pnt + as->length; >+ struct assegment *segment = NULL; >+ >+ while (pnt < end) { >+ int i; >+ >+ /* For fetch value. */ >+ segment = (struct assegment *) pnt; >+ >+ /* Check AS type validity. */ >+ if ((segment->type != AS_SET) && >+ (segment->type != AS_SEQUENCE) && >+ (segment->type != AS_CONFED_SET) && >+ (segment->type != AS_CONFED_SEQUENCE)) >+ { >+ aspath_error(as); >+ return; >+ } >+ >+ /* Check AS length. */ >+ if ((pnt + (segment->length * as->asn_len) + AS_HEADER_SIZE) > end) >+ { >+ aspath_error(as); >+ return; >+ } >+ >+ /* If segment type is changed, print previous type's end >+ character. */ >+ if (type != AS_SEQUENCE) >+ as->str[pos++] = aspath_delimiter_char (type, AS_SEG_END); >+ if (space) >+ as->str[pos++] = ' '; >+ >+ if (segment->type != AS_SEQUENCE) >+ as->str[pos++] = aspath_delimiter_char (segment->type, AS_SEG_START); >+ >+ space = 0; >+ >+ /* Increment as->count - NOT ignoring CONFED_SETS/SEQUENCES any more. >+ I doubt anybody was relying on this behaviour anyway. */ >+ switch(segment->type) { >+ case AS_SEQUENCE: >+ case AS_CONFED_SEQUENCE: >+ as->count += segment->length; >+ break; >+ case AS_SET: >+ case AS_CONFED_SET: >+ as->count += 1; >+ break; >+ } >+ >+ for (i = 0; i < segment->length; i++) >+ { >+ as_t asn; >+ >+ if (space) >+ { >+ if (segment->type == AS_SET >+ || segment->type == AS_CONFED_SET) >+ as->str[pos++] = ','; >+ else >+ as->str[pos++] = ' '; >+ } >+ else >+ space = 1; >+ >+ int asn_pos = i * as->asn_len; >+ switch(as->asn_len) { >+ case ASN16_LEN: >+ asn = ntohs (*(u_int16_t *) (segment->data + asn_pos)); >+ break; >+ case ASN32_LEN: >+ asn = ntohl (*(u_int32_t *) (segment->data + asn_pos)); >+ break; >+ default: >+ assert("invalid asn_len" && false); >+ } >+ >+ pos += int2str(asn, as->str + pos); >+ if(pos > MAX_ASPATH_LEN - 100) { >+ strcpy(as->str + pos, "..."); >+ return; >+ }; >+ } >+ >+ type = segment->type; >+ pnt += (segment->length * as->asn_len) + AS_HEADER_SIZE; >+ } >+ >+ if (segment && segment->type != AS_SEQUENCE) >+ as->str[pos++] = aspath_delimiter_char (segment->type, AS_SEG_END); >+ >+ as->str[pos] = '\0'; >+} >+ >+char aspath_delimiter_char (u_char type, u_char which) { >+ int i; >+ struct >+ { >+ int type; >+ char start; >+ char end; >+ } aspath_delim_char [] = >+ { >+ { AS_SET, '{', '}' }, >+ { AS_SEQUENCE, ' ', ' ' }, >+ { AS_CONFED_SET, '[', ']' }, >+ { AS_CONFED_SEQUENCE, '(', ')' }, >+ { 0, '\0', '\0' } >+ }; >+ >+ for (i = 0; aspath_delim_char[i].type != 0; i++) >+ { >+ if (aspath_delim_char[i].type == type) >+ { >+ if (which == AS_SEG_START) >+ return aspath_delim_char[i].start; >+ else if (which == AS_SEG_END) >+ return aspath_delim_char[i].end; >+ } >+ } >+ return ' '; >+} >+ >+ >+void process_attr_community_string(struct community *com) { >+ >+ char buf[BUFSIZ]; >+ int i; >+ u_int32_t comval; >+ u_int16_t as; >+ u_int16_t val; >+ >+ memset (buf, 0, BUFSIZ); >+ >+ for (i = 0; i < com->size; i++) >+ { >+ memcpy (&comval, com_nthval (com, i), sizeof (u_int32_t)); >+ comval = ntohl (comval); >+ switch (comval) >+ { >+ case COMMUNITY_NO_EXPORT: >+ strlcat (buf, " no-export", BUFSIZ); >+ break; >+ case COMMUNITY_NO_ADVERTISE: >+ strlcat (buf, " no-advertise", BUFSIZ); >+ break; >+ case COMMUNITY_LOCAL_AS: >+ strlcat (buf, " local-AS", BUFSIZ); >+ break; >+ default: >+ as = (comval >> 16) & 0xFFFF; >+ val = comval & 0xFFFF; >+ snprintf (buf + strlen (buf), BUFSIZ - strlen (buf), >+ " %d:%d", as, val); >+ break; >+ } >+ } >+ >+ com->str = malloc(strlen(buf)+1); >+ strcpy(com->str, buf); >+} >+ >+static struct mp_nlri *get_nexthop(struct mstream *s, u_int16_t afi) { >+ struct mp_nlri *nlri = calloc(1, sizeof(struct mp_nlri)); >+ >+ nlri->nexthop_len = mstream_getc(s, NULL); >+ >+ // sometimes nexthop_len is 0 - not sure what this means (see IS-626) >+ // if(mp_nlri->nexthop_len == 0) >+ // return len; >+ >+ if(afi == AFI_IP) { >+ assert(nlri->nexthop_len == 4); >+ nlri->nexthop.v4_addr = mstream_get_ipv4(s); >+ return nlri; >+ } >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ assert(afi == AFI_IP6); >+ mstream_get(s, &nlri->nexthop.v6_addr, 16); >+ if(nlri->nexthop_len == 32) { >+ /* Is there also a link-local address? */ >+ mstream_get(s, &nlri->nexthop_local.v6_addr.s6_addr, 16); >+ } else if(nlri->nexthop_len != 16) { >+ warn("process_mp_announce: unknown MP nexthop length %d", nlri->nexthop_len); >+ } >+#endif >+ return nlri; >+} >+ >+void process_mp_announce(struct mstream *s, struct mp_info *info, struct zebra_incomplete *incomplete) { >+ u_int16_t afi; >+ u_int8_t safi; >+ >+ // look for MRT abbreviated MP_NLRI packets >+ if(s->start[s->position] != 0) { >+ assert(info->announce[AFI_IP6][SAFI_UNICAST] == NULL); >+ info->announce[AFI_IP6][SAFI_UNICAST] = get_nexthop(s, AFI_IP6); >+ return; >+ } >+ >+ mstream_getw(s, &afi); >+ mstream_getc(s, &safi); >+ >+ if(afi > BGPDUMP_MAX_AFI || safi > BGPDUMP_MAX_SAFI) { >+ warn("process_mp_announce: unknown protocol(AFI=%d, SAFI=%d)!", afi, safi); >+ return; >+ } >+ >+ if(info->announce[afi][safi] != NULL) { >+ warn("process_mp_announce: two MP_NLRI for the same protocol(%d, %d)!", afi, safi); >+ return; >+ } >+ >+ info->announce[afi][safi] = get_nexthop(s, afi); >+ >+ // SNPA is defunct and num_snpa should always be 0 >+ u_int8_t num_snpa; >+ if(mstream_getc(s, &num_snpa)) >+ warn("process_mp_announce: MP_NLRI contains SNPAs, skipping"); >+ for(; num_snpa > 0; --num_snpa) { >+ mstream_get(s, NULL, mstream_getc(s, NULL)); >+ } >+ >+ info->announce[afi][safi]->prefix_count = read_prefix_list(s, afi, info->announce[afi][safi]->nlri, incomplete); >+} >+ >+void process_mp_withdraw(struct mstream *s, struct mp_info *info, struct zebra_incomplete *incomplete) { >+ u_int16_t afi; >+ u_int8_t safi; >+ struct mp_nlri *mp_nlri; >+ >+ mstream_getw(s, &afi); >+ mstream_getc(s, &safi); >+ >+ /* Do we know about this address family? */ >+ if(afi > BGPDUMP_MAX_AFI || safi > BGPDUMP_MAX_SAFI) { >+ warn("process_mp_withdraw: unknown AFI,SAFI %d,%d!", afi, safi); >+ return; >+ } >+ >+ /* If there are 2 NLRI's for the same protocol, fail but don't burn and die */ >+ if(info->withdraw[afi][safi] != NULL) { >+ warn("process_mp_withdraw: update contains more than one MP_NLRI with AFI,SAFI %d,%d!", afi, safi); >+ return; >+ } >+ >+ /* Allocate structure */ >+ mp_nlri = malloc(sizeof(struct mp_nlri)); >+ memset(mp_nlri, 0, sizeof(struct mp_nlri)); >+ info->withdraw[afi][safi] = mp_nlri; >+ >+ mp_nlri->prefix_count = read_prefix_list(s, afi, mp_nlri->nlri, incomplete); >+} >+ >+static int read_prefix_list(struct mstream *s, u_int16_t afi, struct prefix *prefixes, struct zebra_incomplete *incomplete) { >+ int count = 0; >+ >+ while(mstream_can_read(s)) { >+ u_int8_t p_len = mstream_getc(s,NULL); // length in bits >+ u_int8_t p_bytes = (p_len + 7) / 8; >+ >+ /* Truncated prefix list? */ >+ if(mstream_can_read(s) < p_bytes) { >+ if(! incomplete) >+ break; >+ >+ /* Put prefix in incomplete structure */ >+ incomplete->afi = afi; >+ incomplete->orig_len = p_len; >+ incomplete->prefix = (struct prefix) { >+ .len = mstream_can_read(s) * 8 >+ }; >+ mstream_get(s, &incomplete->prefix.address, p_bytes); >+ break; >+ } >+ >+ struct prefix *prefix = prefixes + count; >+ >+ if(count++ > MAX_PREFIXES) >+ continue; >+ >+ *prefix = (struct prefix) { .len = p_len }; >+ mstream_get(s, &prefix->address, p_bytes); >+ } >+ >+ if(count > MAX_PREFIXES) { >+ err("too many prefixes (%i > %i)", count, MAX_PREFIXES); >+ return MAX_PREFIXES; >+ } >+ >+ return count; >+} >+ >+static as_t read_asn(struct mstream *s, as_t *asn, u_int8_t len) { >+ u_int16_t asn16; >+ >+ assert(len == sizeof(u_int32_t) || len == sizeof(u_int16_t)); >+ switch(len) { >+ case sizeof(u_int32_t): >+ return mstream_getl(s, asn); >+ case sizeof(u_int16_t): >+ mstream_getw(s, &asn16); >+ if(asn) >+ *asn = asn16; >+ return asn16; >+ default: >+ /* Not reached. Avoid compiler warning */ >+ return 0; >+ } >+} >+ >+int check_new_aspath(struct aspath *aspath) { >+ struct assegment *segment; >+ for(segment = (struct assegment *) aspath->data; >+ segment < (struct assegment *) (aspath->data + aspath->length); >+ segment = (struct assegment *) ((char *) segment + sizeof(*segment) + segment->length * ASN32_LEN)) { >+ if(segment->type == AS_CONFED_SEQUENCE || segment->type == AS_CONFED_SET) { >+ warn("check_new_aspath: invalid segment of type AS_CONFED_%s in NEW_AS_PATH", >+ segment->type == AS_CONFED_SET ? "SET" : "SEQUENCE"); >+ return 0; >+ } >+ } >+ return 1; >+} >+ >+void process_asn32_trans(attributes_t *attr, u_int8_t asn_len) { >+ if(asn_len == ASN32_LEN) { >+ /* These attributes "SHOULD NOT" be used with ASN32. */ >+ if(attr->flag & ATTR_FLAG_BIT(BGP_ATTR_NEW_AS_PATH)) >+ warn("process_asn32_trans: ASN32 message contains NEW_AS_PATH attribute"); >+ >+ if(attr->flag & ATTR_FLAG_BIT(BGP_ATTR_NEW_AGGREGATOR)) >+ warn("process_asn32_trans: ASN32 message contains NEW_AGGREGATOR attribute"); >+ >+ /* Don't compute anything, just leave AS_PATH and AGGREGATOR as they are */ >+ return; >+ } >+ >+ /* Process NEW_AGGREGATOR */ >+ if(attr->flag & ATTR_FLAG_BIT(BGP_ATTR_AGGREGATOR) && >+ attr->flag & ATTR_FLAG_BIT(BGP_ATTR_NEW_AGGREGATOR)) { >+ /* Both AGGREGATOR and NEW_AGGREGATOR present, merge */ >+ if(attr->aggregator_as != AS_TRAN) { >+ /* Don't do anything */ >+ return; >+ } else { >+ attr->old_aggregator_as = attr->aggregator_as; >+ attr->old_aggregator_addr = attr->aggregator_addr; >+ attr->aggregator_as = attr->new_aggregator_as; >+ attr->aggregator_addr = attr->new_aggregator_addr; >+ } >+ } >+ >+ /* Process NEW_AS_PATH */ >+ if(! (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_NEW_AS_PATH))) >+ return; >+ >+ // attr->aspath may be NULL, at least in case of MP_UNREACH_NLRI >+ if(attr->aspath == NULL) return; >+ if(attr->aspath->count < attr->new_aspath->count) { >+ return; >+ } >+ >+ /* Merge paths */ >+ attr->old_aspath = attr->aspath; >+ attr->aspath = asn32_merge_paths(attr->old_aspath, attr->new_aspath); >+ if(attr->aspath) { >+ process_attr_aspath_string(attr->aspath); >+ } >+} >+ >+struct aspath *asn32_merge_paths(struct aspath *path, struct aspath *newpath) { >+ struct aspath *mergedpath = create_aspath(0, ASN32_LEN); >+ struct assegment *segment, *mergedsegment; >+ int newlen; >+ >+ /* Keep copying segments from AS_PATH until our path is as long as AS_PATH - NEW_AS_PATH. */ >+ segment = (struct assegment *) (path->data); >+ while(mergedpath->count < path->count - newpath->count) { >+ /* Make room */ >+ newlen = mergedpath->length + sizeof(struct assegment) + segment->length * ASN32_LEN; >+ mergedpath->data = realloc(mergedpath->data, newlen); >+ >+ /* Create a new AS-path segment */ >+ mergedsegment = (struct assegment *) (mergedpath->data + mergedpath->length); >+ >+ /* Copy segment over. AS_PATH contains 16-bit ASes, so expand */ >+ mergedsegment->type = segment->type; >+ mergedsegment->length = segment->length; >+ asn32_expand_16_to_32(mergedsegment->data, segment->data, segment->length); >+ >+ /* Update length */ >+ mergedpath->length = newlen; >+ if(segment->type == AS_SET || segment->type == AS_CONFED_SET) { >+ mergedpath->count += 1; >+ } else { >+ mergedpath->count += segment->length; >+ /* Did we copy too many ASes over? */ >+ if(mergedpath->count > path->count - newpath->count) { >+ mergedsegment->length -= mergedpath->count - (path->count - newpath->count); >+ mergedpath->length -= (mergedpath->count - (path->count - newpath->count)) * ASN32_LEN; >+ } >+ } >+ } >+ >+ /* Append NEW_AS_PATH to merged path */ >+ mergedpath->data = realloc(mergedpath->data, mergedpath->length + newpath->length); >+ memcpy(mergedpath->data + mergedpath->length, newpath->data, newpath->length); >+ mergedpath->length += newpath->length; >+ >+ return mergedpath; >+} >+ >+void asn32_expand_16_to_32(char *dst, char *src, int len) { >+ u_int32_t *dstarray = (u_int32_t *) dst; >+ u_int16_t *srcarray = (u_int16_t *) src; >+ int i; >+ >+ for(i = 0; i < len; i++) { >+ dstarray[i] = htonl(ntohs(srcarray[i])); >+ } >+} >+ >+#if defined(linux) >+size_t strlcat(char *dst, const char *src, size_t size) { >+ if (strlen (dst) + strlen (src) >= size) >+ return -1; >+ >+ strcat (dst, src); >+ >+ return (strlen(dst)); >+} >+#endif >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_lib.h libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_lib.h >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_lib.h 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_lib.h 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,64 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+Parts of this code have been engineered after analiyzing GNU Zebra's >+source code and therefore might contain declarations/code from GNU >+Zebra, Copyright (C) 1999 Kunihiro Ishiguro. Zebra is a free routing >+software, distributed under the GNU General Public License. A copy of >+this license is included with libbgpdump. >+ >+Original Author: Dan Ardelean (dan@ripe.net) >+*/ >+ >+#ifndef _BGPDUMP_LIB_H >+#define _BGPDUMP_LIB_H >+ >+#include <stdio.h> >+ >+#define BGPDUMP_HAVE_IPV6 >+ >+#include "bgpdump_attr.h" >+#include "bgpdump_formats.h" >+ >+#define BGPDUMP_MAX_FILE_LEN 1024 >+#define BGPDUMP_MAX_AS_PATH_LEN 2000 >+ >+// if you include cfile_tools.h, include it first >+#ifndef _CFILE_TOOLS_DEFINES >+typedef struct _CFRFILE CFRFILE; >+#endif >+ >+typedef struct struct_BGPDUMP { >+ CFRFILE *f; >+ int f_type; >+ int eof; >+ char filename[BGPDUMP_MAX_FILE_LEN]; >+ int parsed; >+ int parsed_ok; >+} BGPDUMP; >+ >+/* prototypes */ >+ >+BGPDUMP *bgpdump_open_dump(const char *filename); >+void bgpdump_close_dump(BGPDUMP *dump); >+BGPDUMP_ENTRY* bgpdump_read_next(BGPDUMP *dump); >+void bgpdump_free_mem(BGPDUMP_ENTRY *entry); >+ >+char *bgpdump_version(void); >+ >+#endif >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_mstream.c libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_mstream.c >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_mstream.c 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_mstream.c 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,103 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+Parts of this code have been engineered after analiyzing GNU Zebra's >+source code and therefore might contain declarations/code from GNU >+Zebra, Copyright (C) 1999 Kunihiro Ishiguro. Zebra is a free routing >+software, distributed under the GNU General Public License. A copy of >+this license is included with libbgpdump. >+ >+Original Author: Dan Ardelean (dan@ripe.net) >+*/ >+ >+#include "bgpdump-config.h" >+#include "bgpdump_mstream.h" >+ >+#include <stdio.h> >+#include <string.h> >+#include <netinet/in.h> >+ >+void mstream_init(struct mstream *s, u_char *buffer, u_int32_t len) { >+ s->start=buffer; >+ s->position=0; >+ s->len=len; >+} >+ >+u_char mstream_getc(struct mstream *s, u_char *d) { >+ u_char data; >+ >+ mstream_get(s, &data, sizeof(data)); >+ if(d!=NULL) memcpy(d,&data,sizeof(data)); >+ return data; >+} >+ >+u_int16_t mstream_getw(struct mstream *s, u_int16_t *d) { >+ u_int16_t data; >+ >+ mstream_get(s, &data, sizeof(data)); >+ data=ntohs(data); >+ if(d!=NULL) memcpy(d,&data,sizeof(data)); >+ return data; >+} >+ >+u_int32_t mstream_getl(struct mstream *s, u_int32_t *d) { >+ u_int32_t data; >+ >+ mstream_get(s, &data, sizeof(data)); >+ data=ntohl(data); >+ if(d!=NULL) memcpy(d,&data,sizeof(data)); >+ return data; >+} >+ >+struct in_addr mstream_get_ipv4(struct mstream *s) { >+ struct in_addr addr; >+ >+ mstream_get(s, &addr.s_addr, 4); >+ return addr; >+} >+ >+u_int32_t mstream_can_read(struct mstream *s) { >+ return s->len - s->position; >+} >+ >+// construct a partial mstream >+mstream_t mstream_copy(mstream_t *s, int len) { >+ mstream_t copy = {0}; >+ copy.start = s->start + s->position; >+ copy.len = mstream_get(s, NULL, len); >+ return copy; >+} >+ >+u_int32_t mstream_get (struct mstream *s, void *d, u_int32_t len) { >+ int room = mstream_can_read(s); >+ >+ if(room >= len) { >+ if(d) memcpy(d, s->start + s->position, len); >+ s->position += len; >+ return len; >+ } else { >+ /* Reading past end of buffer! >+ Zero out extra bytes and set position to end of buffer */ >+ if(d) { >+ memcpy(d, s->start + s->position, room); >+ memset((char *)d + room, 0, len - room); >+ } >+ s->position = s->len; >+ return room; >+ } >+} >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_mstream.h libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_mstream.h >--- libbgpdump/work/libbgpdump-1.4.99.15/bgpdump_mstream.h 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bgpdump_mstream.h 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,49 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+Parts of this code have been engineered after analiyzing GNU Zebra's >+source code and therefore might contain declarations/code from GNU >+Zebra, Copyright (C) 1999 Kunihiro Ishiguro. Zebra is a free routing >+software, distributed under the GNU General Public License. A copy of >+this license is included with libbgpdump. >+ >+Original Author: Dan Ardelean (dan@ripe.net) >+*/ >+ >+#ifndef _BGPDUMP_MSTREAM_H >+#define _BGPDUMP_MSTREAM_H >+ >+#include <sys/types.h> >+#include <netinet/in.h> >+ >+typedef struct mstream { >+ u_char *start; >+ u_int16_t position; >+ u_int32_t len; >+} mstream_t; >+ >+void mstream_init(struct mstream *s, u_char *buffer,u_int32_t len); >+u_char mstream_getc(struct mstream *s, u_char *d); >+u_int16_t mstream_getw(struct mstream *s, u_int16_t *d); >+u_int32_t mstream_getl(struct mstream *s, u_int32_t *d); >+struct in_addr mstream_get_ipv4(struct mstream *s); >+u_int32_t mstream_can_read(struct mstream *s); >+u_int32_t mstream_get (struct mstream *s, void *d, u_int32_t len); >+mstream_t mstream_copy(mstream_t *s, int len); >+ >+#endif >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/bootstrap.sh libbgpdump-new/work/libbgpdump-1.4.99.15/bootstrap.sh >--- libbgpdump/work/libbgpdump-1.4.99.15/bootstrap.sh 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/bootstrap.sh 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,5 @@ >+#!/bin/sh >+ >+autoheader >+autoconf >+./configure >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/cfile_tools.c libbgpdump-new/work/libbgpdump-1.4.99.15/cfile_tools.c >--- libbgpdump/work/libbgpdump-1.4.99.15/cfile_tools.c 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/cfile_tools.c 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,551 @@ >+/** >+ cfile_tools.c >+ >+ A library to deal transparently with possibly compressed files. >+ Documentation in the function headers and in cfile_tools.h >+ >+ Copyright (C) 2004 by Arno Wagner <arno.wagner@acm.org> >+ Distributed under the Gnu Public License version 2 or the modified >+ BSD license (see file COPYING) >+ >+ Support for gzip added by Bernhard Tellenbach <bernhard.tellenbach@gmail.com> >+*/ >+ >+#define _GNU_SOURCE >+#define _FILE_OFFSET_BITS 64 >+ >+//#ifndef DONT_HAVE_BZ2 >+//#include <bzlib.h> >+//#endif >+ >+#include <stdlib.h> >+#include <string.h> >+#include <errno.h> >+#include <assert.h> >+#include "cfile_tools.h" >+ >+// Concrete formats. remember to adjust CFR_NUM_FORMATS if changed! >+// Note: 0, 1 are special entries. >+ >+const char * cfr_formats[CFR_NUM_FORMATS] = { >+ "not open", // 0 >+ "uncompressed", // 1 >+#ifndef DONT_HAVE_BZ2 >+ "bzip2", // 2 >+#endif >+#ifndef DONT_HAVE_GZ >+ "gzip", // 3 >+#endif >+}; >+ >+const char * cfr_extensions[CFR_NUM_FORMATS] = { >+ "", // 0 >+ "", // 1 >+#ifndef DONT_HAVE_BZ2 >+ ".bz2", // 2 >+#endif >+#ifndef DONT_HAVE_GZ >+ ".gz" // 3 >+#endif >+}; >+ >+ >+// Prototypes of non API functions (don't use these from outside this file) >+const char * _cfr_compressor_strerror(int format, int err); >+const char * _bz2_strerror(int err); >+ >+ >+// API Functions >+ >+CFRFILE *cfr_open(const char *path) { >+ /*******************************/ >+ // Analog to 'fopen'. Error in result has to be tested using >+ // 'cfr_error' on the result! >+ // Note: The user needs to free the reurn value! >+ // Opens a possibly compressed file for reading. >+ // File type is determined by file name ending >+ >+ int format, ext_len, name_len; >+ CFRFILE * retval = NULL; >+ >+ // determine file format >+ name_len = strlen(path); >+ format = 2; // skip specials 0, 1 >+ >+ // Do action dependent on file format >+ retval = (CFRFILE *) calloc(1,sizeof(CFRFILE)); >+ retval->eof = 0; >+ retval->error1 = 0; >+ retval->error2 = 0; >+ >+ >+#ifndef DONT_HAVE_GZ >+ if((path == NULL) || (strcmp(path, "-") == 0)) { >+ /* dump from stdin */ >+ gzFile *f; >+ while (format < CFR_NUM_FORMATS) { >+ if (strcmp(cfr_extensions[format], ".gz") == 0) >+ break; >+ format ++; >+ } >+ f = gzdopen(0, "r"); >+ if(f == NULL) { >+ free(retval); >+ return (NULL); >+ } >+ retval->data2 = f; >+ retval->format = format; >+ return (retval); >+ } >+#endif >+ while (format < CFR_NUM_FORMATS) { >+ ext_len = strlen(cfr_extensions[format]); >+ if (strncmp(cfr_extensions[format], >+ path+(name_len-ext_len), >+ ext_len) == 0 >+ ) break; >+ format ++; >+ } >+ if (format >= CFR_NUM_FORMATS) >+ format = 1; // uncompressed >+ retval->format = format; >+ >+ switch (format) { >+ case 1: // uncompressed >+ { >+ FILE * in; >+ in = fopen(path,"r"); >+ if (in == NULL) { >+ free(retval); >+ return(NULL); >+ } >+ retval->data1 = in; >+ return(retval); >+ } >+ break; >+#ifndef DONT_HAVE_BZ2 >+ case 2: // bzip2 >+ { >+ int bzerror; >+ BZFILE * bzin; >+ FILE * in; >+ >+ retval->bz2_stream_end = 0; >+ >+ // get file >+ in = fopen(path,"r"); >+ if (in == NULL) { >+ free(retval); >+ return(NULL); >+ } >+ retval->data1 = in; >+ >+ // bzip2ify file >+ bzin = BZ2_bzReadOpen( &bzerror, in, 0, 0, NULL, 0); >+ if (bzerror != BZ_OK) { >+ errno = bzerror; >+ BZ2_bzReadClose( &bzerror, bzin); >+ fclose(in); >+ free(retval); >+ return(NULL); >+ } >+ retval->data2 = bzin; >+ return(retval); >+ } >+ break; >+#endif >+#ifndef DONT_HAVE_GZ >+ case 3: // gzip >+ { >+ gzFile *f; >+ // get file >+ f = gzopen(path, "r"); >+ if(f == NULL) { >+ free(retval); >+ return (NULL); >+ } >+ retval->data2 = f; >+ return (retval); >+ } >+ break; >+#endif >+ default: // this is an internal error, no diag yet. >+ fprintf(stderr,"illegal format '%d' in cfr_open!\n", format); >+ exit(1); >+ } >+ return NULL; >+} >+ >+ >+ >+int cfr_close(CFRFILE *stream) { >+ /**************************/ >+ // Analog to 'fclose'. >+ // FIXME - why is stream->* set, then freed? >+ if (stream == NULL || stream->closed) { >+ errno = EBADF; >+ return -1; >+ } >+ >+ int retval = -1; >+ >+ switch (stream->format) { >+ case 1: // uncompressed >+ retval = fclose((FILE *)(stream->data1)); >+ stream->error1 = retval; >+ break; >+ case 2: // bzip2 >+ #ifndef DONT_HAVE_BZ2 >+ BZ2_bzReadClose( &stream->error2, (BZFILE *)stream->data2); >+ stream->error1 = retval = fclose((FILE *)(stream->data1)); >+ break; >+ #endif >+ case 3: // gzip >+ #ifndef DONT_HAVE_GZ >+ if(stream->data2!=NULL) >+ retval = gzclose(stream->data2); >+ stream->error2 = retval; >+ break; >+ #endif >+ default: // internal error >+ assert("illegal stream->format" && 0); >+ } >+ free(stream); >+ return(retval); >+} >+ >+size_t cfr_read_n(CFRFILE *stream, void *ptr, size_t bytes) { >+ /******************************************************************/ >+ // Wrapper, will return either 'bytes' (the number of bytes to read) or 0 >+ return(cfr_read(ptr, bytes, 1, stream)*bytes); >+} >+ >+size_t cfr_read(void *ptr, size_t size, size_t nmemb, CFRFILE *stream) { >+ /******************************************************************/ >+ // Analog to 'fread'. Will not return with partial elements, only >+ // full ones. Hence calling this function with one large element >+ // size will result in a complete or no read. >+ >+ size_t retval = 0; >+ if (stream == NULL) return(0); >+ >+ // shortcut >+ if (stream->eof) return(0); >+ >+ switch (stream->format) { >+ case 1: // uncompressed >+ { >+ FILE * in; >+ in = (FILE *)(stream->data1); >+ retval = fread(ptr, size, nmemb, in); >+ if (retval != nmemb) { >+ // fprintf(stderr,"short read!!!\n"); >+ stream->eof = feof(in); >+ stream->error1 = ferror(in); >+ retval = 0; >+ } >+ return (retval); >+ } >+ break; >+#ifndef DONT_HAVE_BZ2 >+ case 2: // bzip2 >+ { >+ BZFILE * bzin; >+ int bzerror; >+ int buffsize; >+ >+ if (stream->bz2_stream_end == 1) { >+ // feof-behaviour: Last read did consume last byte but not more >+ stream->eof = 1; >+ return(0); >+ } >+ >+ bzerror = BZ_OK; >+ bzin = (BZFILE *) (stream->data2); >+ buffsize = size * nmemb; >+ >+ retval = BZ2_bzRead(&bzerror, bzin, ptr, buffsize); >+ >+ if (bzerror == BZ_STREAM_END ) { >+ stream->bz2_stream_end = 1; >+ stream->error2 = bzerror; >+ if (retval == buffsize) { >+ // feof-behaviour: no eof yet >+ } else { >+ // feof-behaviour: read past end, set eof >+ stream->eof = 1; >+ retval = 0; >+ } >+ return(retval/size); >+ } >+ if (bzerror == BZ_OK) { >+ // Normal case, no error. >+ // A short read here is an error, so catch it >+ if (retval == buffsize) { >+ return(retval/size); >+ } >+ } >+ >+ // Other error... >+ stream->error2 = bzerror; >+ BZ2_bzReadClose( &bzerror, bzin ); >+ if (bzerror != BZ_OK) { >+ stream->error2 = bzerror; >+ } >+ retval = fclose((FILE *)(stream->data1)); >+ stream->error1 = retval; >+ stream->closed = 1; >+ return(0); >+ } >+ break; >+#endif >+#ifndef DONT_HAVE_GZ >+ case 3: // gzip >+ { >+ gzFile * in; >+ in = (gzFile *)(stream->data2); >+ retval = gzread(in, ptr, size*nmemb); >+ if (retval != nmemb*size) { >+ // fprintf(stderr,"short read!!!\n"); >+ stream->eof = gzeof(in); >+ stream->error2 = errno; >+ retval = 0; >+ } >+ return (retval/size); >+ } >+ break; >+#endif >+ default: // this is an internal error, no diag yet. >+ fprintf(stderr,"illegal format '%d' in cfr_read!\n",stream->format); >+ exit(1); >+ } >+} >+ >+ >+ >+ >+ >+ssize_t cfr_getline(char **lineptr, size_t *n, CFRFILE *stream) { >+ /************************************************************/ >+ // May not be very efficient, since it uses single-char reads >+ // for formats where there is no native getline in the library. >+ // For bzip2 the speedup for additional buffering was only 5% >+ // so I dropped it. >+ // Returns -1 in case of an error. >+ >+ if (stream == NULL) return(-1); >+ >+ switch (stream->format) { >+ case 1: // uncompressed >+ { >+ if (fgets(*lineptr, *n, (FILE *)(stream->data1)) == NULL) { >+ stream->error1 = errno; >+ return -1; >+ } >+ return 0; >+ } >+ break; >+ >+#ifndef DONT_HAVE_BZ2 >+ case 2: // bzip2 >+ { >+ size_t count; >+ char c; >+ size_t ret; >+ >+ //bzin = (BZFILE *) (stream->data2); >+ >+ // allocate initial buffer if none was passed or size was zero >+ if (*lineptr == NULL) { >+ *lineptr = (char *) calloc(120, 1); >+ *n = 120; >+ } >+ if (*n == 0) { >+ *n = 120; >+ *lineptr = (char *) realloc(*lineptr, *n); // to avoid memory-leaks >+ } >+ >+ count = 0; >+ // read until '\n' >+ do { >+ ret = cfr_read(&c, 1, 1, stream); >+ if (ret != 1) { >+ return(-1); >+ } >+ count ++; >+ if (count >= *n) { >+ *n = 2 * *n; >+ *lineptr = (char *) realloc(*lineptr, *n); >+ if (*lineptr == NULL) { >+ stream->error1 = errno; >+ return(-1); >+ } >+ } >+ (*lineptr)[count-1] = c; >+ } while (c != '\n'); >+ (*lineptr)[count] = 0; >+ return(count); >+ } >+ break; >+#endif >+#ifndef DONT_HAVE_GZ >+ case 3: // gzip >+ { >+ char * return_ptr = gzgets((gzFile *)(stream->data2), *lineptr, *n ); >+ if (return_ptr == Z_NULL) { >+ stream->error2 = errno; >+ return(-1); >+ } >+ return *n; >+ >+ } >+ break; >+#endif >+ default: // this is an internal error, no diag yet. >+ fprintf(stderr,"illegal format '%d' in cfr_getline!\n",stream->format); >+ exit(1); >+ return(-1); >+ } >+} >+ >+ >+ >+int cfr_eof(CFRFILE *stream) { >+ // Returns true on end of file/end of compressed data. >+ // The end of the compressed data is regarded as end of file >+ // in this library, embedded or multiple compressed data per >+ // file is not supported by this library. >+ // >+ // Note: The sematics is that cfr_eof is true only after >+ // the first byte after the end of file was read. Some compressors >+ // report EOF already when the last availale character has been >+ // read (far more sensible IMO), but for consistency we follow the >+ // convention of the standard c library here. >+ >+ return(stream->eof); >+} >+ >+ >+ >+int cfr_error(CFRFILE *stream) { >+ // Returns true on error. >+ // Errors can be ordinary errors from fopen.fclose/fread >+ // or can originate from the underlying compression. >+ // This function just returns 0 when there is no error or >+ // 1 in case of error. >+ // To get a more detailed report cfr_strerror will try to >+ // come up with a description of the whole situation. >+ // For numeric details, more query functions would need to be >+ // implemented. >+ >+ if (stream == NULL) return(1); >+ return(stream->error1 || stream->error2); >+} >+ >+ >+char * cfr_strerror(CFRFILE *stream) { >+ // Result is "stream-i/o: <stream-error> <compressor>[: <compressor error>]" >+ // Do not modify result. >+ // Result may change on subsequent call to this function. >+ >+ static char res[120]; >+ char * msg, * msg2; >+ >+ if (stream == NULL) { >+ asprintf(&msg,"Error: stream is NULL, i.e. not opened"); >+ return(msg); >+ } >+ >+ asprintf(&msg, >+ "stream-i/o: %s, %s [%s]", >+ stream->eof?"EOF":"", >+ strerror(stream->error1), >+ cfr_compressor_str(stream)); >+ if (stream->format == 2) { >+ asprintf(&msg2, >+ "%s: %s", >+ msg, >+ _cfr_compressor_strerror(stream->format, stream->error2)); >+ free(msg); >+ msg = msg2; >+ } >+ if (stream->format == 3) { >+ asprintf(&msg2, >+ "%s: %s", >+ msg, >+ gzerror((gzFile*)(stream->data2), &(stream->error2))); >+ free(msg); >+ msg = msg2; >+ } >+ snprintf(res, 120, "%s", msg); >+ res[119] = 0; >+ free(msg); >+ return(res); >+} >+ >+const char * cfr_compressor_str(CFRFILE *stream) { >+ // Returns the name of the compressor used >+ >+ if ((stream->format < 0) || (stream->format >= CFR_NUM_FORMATS)) { >+ return("undefined compression type"); >+ } else { >+ return (cfr_formats[stream->format]); >+ } >+} >+ >+ >+// Utility functions for compressor errors. >+// * Not part of the API, do not call directly as they may change! * >+ >+const char * _cfr_compressor_strerror(int format, int err) { >+ // Transforms error code to string for all compressors >+ >+ switch (format) { >+ case 0: >+ return("file not open"); >+ break; >+ >+ case 1: >+ return("file not compressed"); >+ break; >+ >+#ifndef DONT_HAVE_BZ2 >+ case 2: >+ return(_bz2_strerror(err)); >+ break; >+#endif >+#ifndef DONT_HAVE_GZ >+ case 3: >+ return NULL; >+ break; >+#endif >+ default: >+ return("unknowen compressor code"); >+ } >+} >+ >+#ifndef DONT_HAVE_BZ2 >+const char * _bz2_strerror(int err) { >+ // Since bzlib does not have strerror, we do it here manually. >+ // This works for version 1.0 of 21 March 2000 of bzlib.h >+ >+ switch (err) { >+ case BZ_OK: return("BZ_OK"); >+ case BZ_RUN_OK: return("BZ_RUN_OK"); >+ case BZ_FLUSH_OK: return("BZ_FLUSH_OK"); >+ case BZ_FINISH_OK: return("BZ_FINISH_OK"); >+ case BZ_STREAM_END: return("BZ_STREAM_END"); >+ case BZ_SEQUENCE_ERROR: return("BZ_SEQUENCE_ERROR"); >+ case BZ_PARAM_ERROR: return("BZ_PARAM_ERROR"); >+ case BZ_MEM_ERROR: return("BZ_MEM_ERROR"); >+ case BZ_DATA_ERROR: return("BZ_DATA_ERROR"); >+ case BZ_DATA_ERROR_MAGIC: return("BZ_DATA_ERROR_MAGIC"); >+ case BZ_IO_ERROR: return("BZ_IO_ERROR"); >+ case BZ_UNEXPECTED_EOF: return("BZ_UNEXPECTED_EOF"); >+ case BZ_OUTBUFF_FULL: return("BZ_OUTBUFF_FULL"); >+ case BZ_CONFIG_ERROR: return("BZ_CONFIG_ERROR"); >+ default: return("unknowen bzip2 error code"); >+ } >+} >+#endif >+ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/cfile_tools.h libbgpdump-new/work/libbgpdump-1.4.99.15/cfile_tools.h >--- libbgpdump/work/libbgpdump-1.4.99.15/cfile_tools.h 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/cfile_tools.h 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,91 @@ >+/** >+ cfile_tools.h >+ A small library containing tools for dealing with files >+ that are compressed with different compressors or not compressed >+ at all. The idea is to recognize the compression automagically >+ and transparently. Files can be opened for reading or writing, >+ but not both. Reading and writing is by different function classes. >+ Access is sequential only. >+ >+ Copyright (C) 2004 by Arno Wagner <arno.wagner@acm.org> >+ Distributed under the Gnu Public License version 2 or the modified >+ BSD license (see file COPYING) >+ >+ Support for gzip added by Bernhard Tellenbach <bernhard.tellenbach@gmail.com> >+ >+ Function prefixes are: >+ cfr_ = compressed file read >+ >+ Supported: >+ Reading: >+ - type recognition from file name extension >+ - standard input (filename: '-' ) >+ - no compression >+ - bzip2 >+ - gzip >+*/ >+ >+#ifndef _CFILE_TOOLS_DEFINES >+#define _CFILE_TOOLS_DEFINES >+ >+#define _GNU_SOURCE >+#define _FILE_OFFSET_BITS 64 >+ >+#include <stdio.h> >+#include <unistd.h> >+ >+#ifndef DONT_HAVE_BZ2 >+#include <bzlib.h> >+#endif >+ >+#ifndef DONT_HAVE_GZ >+#include <zlib.h> >+#endif >+ >+// Types >+ >+struct _CFRFILE { >+ int format; // 0 = not open, 1 = uncompressed, 2 = bzip2, 3 = gzip >+ int eof; // 0 = not eof >+ int closed; // indicates whether fclose has been called, 0 = not yet >+ int error1; // errors from the sytem, 0 = no error >+ int error2; // for error messages from the compressor >+ FILE * data1; // for filehandle of the system >+ void * data2; // addtional handle(s) of the compressor >+ // compressor specific stuff >+ int bz2_stream_end; // True when a bz2 stream has ended. Needed since >+ // further reading returns error and not eof. >+}; >+ >+typedef struct _CFRFILE CFRFILE; >+ >+// Formats >+ >+#ifndef DONT_HAVE_BZ2 >+ #ifndef DONT_HAVE_GZ >+ #define CFR_NUM_FORMATS 4 >+ #else >+ #define CFR_NUM_FORMATS 3 >+ #endif >+#else >+ #define CFR_NUM_FORMATS 2 >+#endif >+ >+// Functions >+ >+CFRFILE * cfr_open(const char *path); >+int cfr_close(CFRFILE *stream); >+size_t cfr_read(void *ptr, size_t size, size_t nmemb, CFRFILE *stream); >+size_t cfr_read_n(CFRFILE *stream, void *ptr, size_t bytes); >+ssize_t cfr_getline(char **lineptr, size_t *n, CFRFILE *stream); >+int cfr_eof(CFRFILE *stream); >+int cfr_error(CFRFILE *stream); >+char * cfr_strerror(CFRFILE *stream); >+const char * cfr_compressor_str(CFRFILE *stream); >+ >+#ifndef DONT_HAVE_BZ2 >+const char * _bz2_strerror(int err); >+#endif >+ >+ >+#endif >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/config.status libbgpdump-new/work/libbgpdump-1.4.99.15/config.status >--- libbgpdump/work/libbgpdump-1.4.99.15/config.status 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/config.status 2015-09-16 20:23:11.000000000 +1200 >@@ -0,0 +1,997 @@ >+#! /bin/sh >+# Generated by configure. >+# Run this file to recreate the current configuration. >+# Compiler output produced by configure, useful for debugging >+# configure, is in config.log if it exists. >+ >+debug=false >+ac_cs_recheck=false >+ac_cs_silent=false >+ >+SHELL=${CONFIG_SHELL-/bin/sh} >+export SHELL >+## -------------------- ## >+## M4sh Initialization. ## >+## -------------------- ## >+ >+# Be more Bourne compatible >+DUALCASE=1; export DUALCASE # for MKS sh >+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : >+ emulate sh >+ NULLCMD=: >+ # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which >+ # is contrary to our usage. Disable this feature. >+ alias -g '${1+"$@"}'='"$@"' >+ setopt NO_GLOB_SUBST >+else >+ case `(set -o) 2>/dev/null` in #( >+ *posix*) : >+ set -o posix ;; #( >+ *) : >+ ;; >+esac >+fi >+ >+ >+as_nl=' >+' >+export as_nl >+# Printing a long string crashes Solaris 7 /usr/bin/printf. >+as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo >+# Prefer a ksh shell builtin over an external printf program on Solaris, >+# but without wasting forks for bash or zsh. >+if test -z "$BASH_VERSION$ZSH_VERSION" \ >+ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='print -r --' >+ as_echo_n='print -rn --' >+elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='printf %s\n' >+ as_echo_n='printf %s' >+else >+ if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then >+ as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' >+ as_echo_n='/usr/ucb/echo -n' >+ else >+ as_echo_body='eval expr "X$1" : "X\\(.*\\)"' >+ as_echo_n_body='eval >+ arg=$1; >+ case $arg in #( >+ *"$as_nl"*) >+ expr "X$arg" : "X\\(.*\\)$as_nl"; >+ arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; >+ esac; >+ expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" >+ ' >+ export as_echo_n_body >+ as_echo_n='sh -c $as_echo_n_body as_echo' >+ fi >+ export as_echo_body >+ as_echo='sh -c $as_echo_body as_echo' >+fi >+ >+# The user is always right. >+if test "${PATH_SEPARATOR+set}" != set; then >+ PATH_SEPARATOR=: >+ (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { >+ (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || >+ PATH_SEPARATOR=';' >+ } >+fi >+ >+ >+# IFS >+# We need space, tab and new line, in precisely that order. Quoting is >+# there to prevent editors from complaining about space-tab. >+# (If _AS_PATH_WALK were called with IFS unset, it would disable word >+# splitting by setting IFS to empty value.) >+IFS=" "" $as_nl" >+ >+# Find who we are. Look in the path if we contain no directory separator. >+as_myself= >+case $0 in #(( >+ *[\\/]* ) as_myself=$0 ;; >+ *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break >+ done >+IFS=$as_save_IFS >+ >+ ;; >+esac >+# We did not find ourselves, most probably we were run as `sh COMMAND' >+# in which case we are not to be found in the path. >+if test "x$as_myself" = x; then >+ as_myself=$0 >+fi >+if test ! -f "$as_myself"; then >+ $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 >+ exit 1 >+fi >+ >+# Unset variables that we do not need and which cause bugs (e.g. in >+# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" >+# suppresses any "Segmentation fault" message there. '((' could >+# trigger a bug in pdksh 5.2.14. >+for as_var in BASH_ENV ENV MAIL MAILPATH >+do eval test x\${$as_var+set} = xset \ >+ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : >+done >+PS1='$ ' >+PS2='> ' >+PS4='+ ' >+ >+# NLS nuisances. >+LC_ALL=C >+export LC_ALL >+LANGUAGE=C >+export LANGUAGE >+ >+# CDPATH. >+(unset CDPATH) >/dev/null 2>&1 && unset CDPATH >+ >+ >+# as_fn_error STATUS ERROR [LINENO LOG_FD] >+# ---------------------------------------- >+# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are >+# provided, also output the error to LOG_FD, referencing LINENO. Then exit the >+# script with STATUS, using 1 if that was 0. >+as_fn_error () >+{ >+ as_status=$1; test $as_status -eq 0 && as_status=1 >+ if test "$4"; then >+ as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 >+ fi >+ $as_echo "$as_me: error: $2" >&2 >+ as_fn_exit $as_status >+} # as_fn_error >+ >+ >+# as_fn_set_status STATUS >+# ----------------------- >+# Set $? to STATUS, without forking. >+as_fn_set_status () >+{ >+ return $1 >+} # as_fn_set_status >+ >+# as_fn_exit STATUS >+# ----------------- >+# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. >+as_fn_exit () >+{ >+ set +e >+ as_fn_set_status $1 >+ exit $1 >+} # as_fn_exit >+ >+# as_fn_unset VAR >+# --------------- >+# Portably unset VAR. >+as_fn_unset () >+{ >+ { eval $1=; unset $1;} >+} >+as_unset=as_fn_unset >+# as_fn_append VAR VALUE >+# ---------------------- >+# Append the text in VALUE to the end of the definition contained in VAR. Take >+# advantage of any shell optimizations that allow amortized linear growth over >+# repeated appends, instead of the typical quadratic growth present in naive >+# implementations. >+if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : >+ eval 'as_fn_append () >+ { >+ eval $1+=\$2 >+ }' >+else >+ as_fn_append () >+ { >+ eval $1=\$$1\$2 >+ } >+fi # as_fn_append >+ >+# as_fn_arith ARG... >+# ------------------ >+# Perform arithmetic evaluation on the ARGs, and store the result in the >+# global $as_val. Take advantage of shells that can avoid forks. The arguments >+# must be portable across $(()) and expr. >+if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : >+ eval 'as_fn_arith () >+ { >+ as_val=$(( $* )) >+ }' >+else >+ as_fn_arith () >+ { >+ as_val=`expr "$@" || test $? -eq 1` >+ } >+fi # as_fn_arith >+ >+ >+if expr a : '\(a\)' >/dev/null 2>&1 && >+ test "X`expr 00001 : '.*\(...\)'`" = X001; then >+ as_expr=expr >+else >+ as_expr=false >+fi >+ >+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then >+ as_basename=basename >+else >+ as_basename=false >+fi >+ >+if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then >+ as_dirname=dirname >+else >+ as_dirname=false >+fi >+ >+as_me=`$as_basename -- "$0" || >+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ >+ X"$0" : 'X\(//\)$' \| \ >+ X"$0" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X/"$0" | >+ sed '/^.*\/\([^/][^/]*\)\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ >+# Avoid depending upon Character Ranges. >+as_cr_letters='abcdefghijklmnopqrstuvwxyz' >+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' >+as_cr_Letters=$as_cr_letters$as_cr_LETTERS >+as_cr_digits='0123456789' >+as_cr_alnum=$as_cr_Letters$as_cr_digits >+ >+ECHO_C= ECHO_N= ECHO_T= >+case `echo -n x` in #((((( >+-n*) >+ case `echo 'xy\c'` in >+ *c*) ECHO_T=' ';; # ECHO_T is single tab character. >+ xy) ECHO_C='\c';; >+ *) echo `echo ksh88 bug on AIX 6.1` > /dev/null >+ ECHO_T=' ';; >+ esac;; >+*) >+ ECHO_N='-n';; >+esac >+ >+rm -f conf$$ conf$$.exe conf$$.file >+if test -d conf$$.dir; then >+ rm -f conf$$.dir/conf$$.file >+else >+ rm -f conf$$.dir >+ mkdir conf$$.dir 2>/dev/null >+fi >+if (echo >conf$$.file) 2>/dev/null; then >+ if ln -s conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s='ln -s' >+ # ... but there are two gotchas: >+ # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. >+ # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. >+ # In both cases, we have to default to `cp -pR'. >+ ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || >+ as_ln_s='cp -pR' >+ elif ln conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s=ln >+ else >+ as_ln_s='cp -pR' >+ fi >+else >+ as_ln_s='cp -pR' >+fi >+rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file >+rmdir conf$$.dir 2>/dev/null >+ >+ >+# as_fn_mkdir_p >+# ------------- >+# Create "$as_dir" as a directory, including parents if necessary. >+as_fn_mkdir_p () >+{ >+ >+ case $as_dir in #( >+ -*) as_dir=./$as_dir;; >+ esac >+ test -d "$as_dir" || eval $as_mkdir_p || { >+ as_dirs= >+ while :; do >+ case $as_dir in #( >+ *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( >+ *) as_qdir=$as_dir;; >+ esac >+ as_dirs="'$as_qdir' $as_dirs" >+ as_dir=`$as_dirname -- "$as_dir" || >+$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$as_dir" : 'X\(//\)[^/]' \| \ >+ X"$as_dir" : 'X\(//\)$' \| \ >+ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$as_dir" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ test -d "$as_dir" && break >+ done >+ test -z "$as_dirs" || eval "mkdir $as_dirs" >+ } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" >+ >+ >+} # as_fn_mkdir_p >+if mkdir -p . 2>/dev/null; then >+ as_mkdir_p='mkdir -p "$as_dir"' >+else >+ test -d ./-p && rmdir ./-p >+ as_mkdir_p=false >+fi >+ >+ >+# as_fn_executable_p FILE >+# ----------------------- >+# Test if FILE is an executable regular file. >+as_fn_executable_p () >+{ >+ test -f "$1" && test -x "$1" >+} # as_fn_executable_p >+as_test_x='test -x' >+as_executable_p=as_fn_executable_p >+ >+# Sed expression to map a string onto a valid CPP name. >+as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" >+ >+# Sed expression to map a string onto a valid variable name. >+as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" >+ >+ >+exec 6>&1 >+## ----------------------------------- ## >+## Main body of $CONFIG_STATUS script. ## >+## ----------------------------------- ## >+# Save the log message, to keep $0 and so on meaningful, and to >+# report actual input values of CONFIG_FILES etc. instead of their >+# values after options handling. >+ac_log=" >+This file was extended by libbgpdump $as_me 1.4.99.15, which was >+generated by GNU Autoconf 2.69. Invocation command line was >+ >+ CONFIG_FILES = $CONFIG_FILES >+ CONFIG_HEADERS = $CONFIG_HEADERS >+ CONFIG_LINKS = $CONFIG_LINKS >+ CONFIG_COMMANDS = $CONFIG_COMMANDS >+ $ $0 $@ >+ >+on `(hostname || uname -n) 2>/dev/null | sed 1q` >+" >+ >+# Files that config.status was made for. >+config_files=" bgpdump.spec Makefile" >+config_headers=" bgpdump-config.h" >+ >+ac_cs_usage="\ >+\`$as_me' instantiates files and other configuration actions >+from templates according to the current configuration. Unless the files >+and actions are specified as TAGs, all are instantiated by default. >+ >+Usage: $0 [OPTION]... [TAG]... >+ >+ -h, --help print this help, then exit >+ -V, --version print version number and configuration settings, then exit >+ --config print configuration, then exit >+ -q, --quiet, --silent >+ do not print progress messages >+ -d, --debug don't remove temporary files >+ --recheck update $as_me by reconfiguring in the same conditions >+ --file=FILE[:TEMPLATE] >+ instantiate the configuration file FILE >+ --header=FILE[:TEMPLATE] >+ instantiate the configuration header FILE >+ >+Configuration files: >+$config_files >+ >+Configuration headers: >+$config_headers >+ >+Report bugs to <ris@ripe.net>." >+ >+ac_cs_config="" >+ac_cs_version="\ >+libbgpdump config.status 1.4.99.15 >+configured by ./configure, generated by GNU Autoconf 2.69, >+ with options \"$ac_cs_config\" >+ >+Copyright (C) 2012 Free Software Foundation, Inc. >+This config.status script is free software; the Free Software Foundation >+gives unlimited permission to copy, distribute and modify it." >+ >+ac_pwd='/Users/mlapan/tmp/0/ripencc-bgpdump-0cb1a4c59d10' >+srcdir='.' >+test -n "$AWK" || AWK=awk >+# The default lists apply if the user does not specify any file. >+ac_need_defaults=: >+while test $# != 0 >+do >+ case $1 in >+ --*=?*) >+ ac_option=`expr "X$1" : 'X\([^=]*\)='` >+ ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` >+ ac_shift=: >+ ;; >+ --*=) >+ ac_option=`expr "X$1" : 'X\([^=]*\)='` >+ ac_optarg= >+ ac_shift=: >+ ;; >+ *) >+ ac_option=$1 >+ ac_optarg=$2 >+ ac_shift=shift >+ ;; >+ esac >+ >+ case $ac_option in >+ # Handling of the options. >+ -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) >+ ac_cs_recheck=: ;; >+ --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) >+ $as_echo "$ac_cs_version"; exit ;; >+ --config | --confi | --conf | --con | --co | --c ) >+ $as_echo "$ac_cs_config"; exit ;; >+ --debug | --debu | --deb | --de | --d | -d ) >+ debug=: ;; >+ --file | --fil | --fi | --f ) >+ $ac_shift >+ case $ac_optarg in >+ *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; >+ '') as_fn_error $? "missing file argument" ;; >+ esac >+ as_fn_append CONFIG_FILES " '$ac_optarg'" >+ ac_need_defaults=false;; >+ --header | --heade | --head | --hea ) >+ $ac_shift >+ case $ac_optarg in >+ *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; >+ esac >+ as_fn_append CONFIG_HEADERS " '$ac_optarg'" >+ ac_need_defaults=false;; >+ --he | --h) >+ # Conflict between --help and --header >+ as_fn_error $? "ambiguous option: \`$1' >+Try \`$0 --help' for more information.";; >+ --help | --hel | -h ) >+ $as_echo "$ac_cs_usage"; exit ;; >+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \ >+ | -silent | --silent | --silen | --sile | --sil | --si | --s) >+ ac_cs_silent=: ;; >+ >+ # This is an error. >+ -*) as_fn_error $? "unrecognized option: \`$1' >+Try \`$0 --help' for more information." ;; >+ >+ *) as_fn_append ac_config_targets " $1" >+ ac_need_defaults=false ;; >+ >+ esac >+ shift >+done >+ >+ac_configure_extra_args= >+ >+if $ac_cs_silent; then >+ exec 6>/dev/null >+ ac_configure_extra_args="$ac_configure_extra_args --silent" >+fi >+ >+if $ac_cs_recheck; then >+ set X /bin/sh './configure' $ac_configure_extra_args --no-create --no-recursion >+ shift >+ $as_echo "running CONFIG_SHELL=/bin/sh $*" >&6 >+ CONFIG_SHELL='/bin/sh' >+ export CONFIG_SHELL >+ exec "$@" >+fi >+ >+exec 5>>config.log >+{ >+ echo >+ sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX >+## Running $as_me. ## >+_ASBOX >+ $as_echo "$ac_log" >+} >&5 >+ >+ >+# Handling of arguments. >+for ac_config_target in $ac_config_targets >+do >+ case $ac_config_target in >+ "bgpdump-config.h") CONFIG_HEADERS="$CONFIG_HEADERS bgpdump-config.h" ;; >+ "bgpdump.spec") CONFIG_FILES="$CONFIG_FILES bgpdump.spec" ;; >+ "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; >+ >+ *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; >+ esac >+done >+ >+ >+# If the user did not use the arguments to specify the items to instantiate, >+# then the envvar interface is used. Set only those that are not. >+# We use the long form for the default assignment because of an extremely >+# bizarre bug on SunOS 4.1.3. >+if $ac_need_defaults; then >+ test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files >+ test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers >+fi >+ >+# Have a temporary directory for convenience. Make it in the build tree >+# simply because there is no reason against having it here, and in addition, >+# creating and moving files from /tmp can sometimes cause problems. >+# Hook for its removal unless debugging. >+# Note that there is a small window in which the directory will not be cleaned: >+# after its creation but before its name has been assigned to `$tmp'. >+$debug || >+{ >+ tmp= ac_tmp= >+ trap 'exit_status=$? >+ : "${ac_tmp:=$tmp}" >+ { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status >+' 0 >+ trap 'as_fn_exit 1' 1 2 13 15 >+} >+# Create a (secure) tmp directory for tmp files. >+ >+{ >+ tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && >+ test -d "$tmp" >+} || >+{ >+ tmp=./conf$$-$RANDOM >+ (umask 077 && mkdir "$tmp") >+} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 >+ac_tmp=$tmp >+ >+# Set up the scripts for CONFIG_FILES section. >+# No need to generate them if there are no CONFIG_FILES. >+# This happens for instance with `./config.status config.h'. >+if test -n "$CONFIG_FILES"; then >+ >+ >+ac_cr=`echo X | tr X '\015'` >+# On cygwin, bash can eat \r inside `` if the user requested igncr. >+# But we know of no other shell where ac_cr would be empty at this >+# point, so we can use a bashism as a fallback. >+if test "x$ac_cr" = x; then >+ eval ac_cr=\$\'\\r\' >+fi >+ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` >+if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then >+ ac_cs_awk_cr='\\r' >+else >+ ac_cs_awk_cr=$ac_cr >+fi >+ >+echo 'BEGIN {' >"$ac_tmp/subs1.awk" && >+cat >>"$ac_tmp/subs1.awk" <<\_ACAWK && >+S["LTLIBOBJS"]="" >+S["LIBOBJS"]="" >+S["EGREP"]="/usr/bin/grep -E" >+S["GREP"]="/usr/bin/grep" >+S["CPP"]="gcc -E" >+S["RANLIB"]="ranlib" >+S["OBJEXT"]="o" >+S["EXEEXT"]="" >+S["ac_ct_CC"]="gcc" >+S["CPPFLAGS"]="" >+S["LDFLAGS"]=" -dynamiclib" >+S["CFLAGS"]="-g -O3 -Wall -Wsystem-headers -Wno-format-y2k -Wno-sign-compare -Wcast-align -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wswitch -Wshadow" >+S["CC"]="gcc" >+S["target_alias"]="" >+S["host_alias"]="" >+S["build_alias"]="" >+S["LIBS"]="-lbz2 -lz " >+S["ECHO_T"]="" >+S["ECHO_N"]="" >+S["ECHO_C"]="\\c" >+S["DEFS"]="-DHAVE_CONFIG_H" >+S["mandir"]="${datarootdir}/man" >+S["localedir"]="${datarootdir}/locale" >+S["libdir"]="${exec_prefix}/lib" >+S["psdir"]="${docdir}" >+S["pdfdir"]="${docdir}" >+S["dvidir"]="${docdir}" >+S["htmldir"]="${docdir}" >+S["infodir"]="${datarootdir}/info" >+S["docdir"]="${datarootdir}/doc/${PACKAGE_TARNAME}" >+S["oldincludedir"]="/usr/include" >+S["includedir"]="${prefix}/include" >+S["localstatedir"]="${prefix}/var" >+S["sharedstatedir"]="${prefix}/com" >+S["sysconfdir"]="${prefix}/etc" >+S["datadir"]="${datarootdir}" >+S["datarootdir"]="${prefix}/share" >+S["libexecdir"]="${exec_prefix}/libexec" >+S["sbindir"]="${exec_prefix}/sbin" >+S["bindir"]="${exec_prefix}/bin" >+S["program_transform_name"]="s,x,x," >+S["prefix"]="/usr/local" >+S["exec_prefix"]="${prefix}" >+S["PACKAGE_URL"]="" >+S["PACKAGE_BUGREPORT"]="ris@ripe.net" >+S["PACKAGE_STRING"]="libbgpdump 1.4.99.15" >+S["PACKAGE_VERSION"]="1.4.99.15" >+S["PACKAGE_TARNAME"]="libbgpdump" >+S["PACKAGE_NAME"]="libbgpdump" >+S["PATH_SEPARATOR"]=":" >+S["SHELL"]="/bin/sh" >+_ACAWK >+cat >>"$ac_tmp/subs1.awk" <<_ACAWK && >+ for (key in S) S_is_set[key] = 1 >+ FS = "" >+ >+} >+{ >+ line = $ 0 >+ nfields = split(line, field, "@") >+ substed = 0 >+ len = length(field[1]) >+ for (i = 2; i < nfields; i++) { >+ key = field[i] >+ keylen = length(key) >+ if (S_is_set[key]) { >+ value = S[key] >+ line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) >+ len += length(value) + length(field[++i]) >+ substed = 1 >+ } else >+ len += 1 + keylen >+ } >+ >+ print line >+} >+ >+_ACAWK >+if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then >+ sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" >+else >+ cat >+fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ >+ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 >+fi # test -n "$CONFIG_FILES" >+ >+# Set up the scripts for CONFIG_HEADERS section. >+# No need to generate them if there are no CONFIG_HEADERS. >+# This happens for instance with `./config.status Makefile'. >+if test -n "$CONFIG_HEADERS"; then >+cat >"$ac_tmp/defines.awk" <<\_ACAWK || >+BEGIN { >+D["PACKAGE_NAME"]=" \"libbgpdump\"" >+D["PACKAGE_TARNAME"]=" \"libbgpdump\"" >+D["PACKAGE_VERSION"]=" \"1.4.99.15\"" >+D["PACKAGE_STRING"]=" \"libbgpdump 1.4.99.15\"" >+D["PACKAGE_BUGREPORT"]=" \"ris@ripe.net\"" >+D["PACKAGE_URL"]=" \"\"" >+D["STDC_HEADERS"]=" 1" >+D["HAVE_SYS_TYPES_H"]=" 1" >+D["HAVE_SYS_STAT_H"]=" 1" >+D["HAVE_STDLIB_H"]=" 1" >+D["HAVE_STRING_H"]=" 1" >+D["HAVE_MEMORY_H"]=" 1" >+D["HAVE_STRINGS_H"]=" 1" >+D["HAVE_INTTYPES_H"]=" 1" >+D["HAVE_STDINT_H"]=" 1" >+D["HAVE_UNISTD_H"]=" 1" >+D["HAVE_ARPA_INET_H"]=" 1" >+D["HAVE_NETINET_IN_H"]=" 1" >+D["HAVE_SYSLOG_H"]=" 1" >+D["u_char_t"]=" uchar_t" >+D["HAVE_LIBZ"]=" 1" >+D["HAVE_LIBBZ2"]=" 1" >+D["HAVE_INET_NTOA"]=" 1" >+D["HAVE_INET_NTOP"]=" 1" >+ for (key in D) D_is_set[key] = 1 >+ FS = "" >+} >+/^[\t ]*#[\t ]*(define|undef)[\t ]+[_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ][_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]*([\t (]|$)/ { >+ line = $ 0 >+ split(line, arg, " ") >+ if (arg[1] == "#") { >+ defundef = arg[2] >+ mac1 = arg[3] >+ } else { >+ defundef = substr(arg[1], 2) >+ mac1 = arg[2] >+ } >+ split(mac1, mac2, "(") #) >+ macro = mac2[1] >+ prefix = substr(line, 1, index(line, defundef) - 1) >+ if (D_is_set[macro]) { >+ # Preserve the white space surrounding the "#". >+ print prefix "define", macro P[macro] D[macro] >+ next >+ } else { >+ # Replace #undef with comments. This is necessary, for example, >+ # in the case of _POSIX_SOURCE, which is predefined and required >+ # on some systems where configure will not decide to define it. >+ if (defundef == "undef") { >+ print "/*", prefix defundef, macro, "*/" >+ next >+ } >+ } >+} >+{ print } >+_ACAWK >+ as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 >+fi # test -n "$CONFIG_HEADERS" >+ >+ >+eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " >+shift >+for ac_tag >+do >+ case $ac_tag in >+ :[FHLC]) ac_mode=$ac_tag; continue;; >+ esac >+ case $ac_mode$ac_tag in >+ :[FHL]*:*);; >+ :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; >+ :[FH]-) ac_tag=-:-;; >+ :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; >+ esac >+ ac_save_IFS=$IFS >+ IFS=: >+ set x $ac_tag >+ IFS=$ac_save_IFS >+ shift >+ ac_file=$1 >+ shift >+ >+ case $ac_mode in >+ :L) ac_source=$1;; >+ :[FH]) >+ ac_file_inputs= >+ for ac_f >+ do >+ case $ac_f in >+ -) ac_f="$ac_tmp/stdin";; >+ *) # Look for the file first in the build tree, then in the source tree >+ # (if the path is not absolute). The absolute path cannot be DOS-style, >+ # because $ac_f cannot contain `:'. >+ test -f "$ac_f" || >+ case $ac_f in >+ [\\/$]*) false;; >+ *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; >+ esac || >+ as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; >+ esac >+ case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac >+ as_fn_append ac_file_inputs " '$ac_f'" >+ done >+ >+ # Let's still pretend it is `configure' which instantiates (i.e., don't >+ # use $as_me), people would be surprised to read: >+ # /* config.h. Generated by config.status. */ >+ configure_input='Generated from '` >+ $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' >+ `' by configure.' >+ if test x"$ac_file" != x-; then >+ configure_input="$ac_file. $configure_input" >+ { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 >+$as_echo "$as_me: creating $ac_file" >&6;} >+ fi >+ # Neutralize special characters interpreted by sed in replacement strings. >+ case $configure_input in #( >+ *\&* | *\|* | *\\* ) >+ ac_sed_conf_input=`$as_echo "$configure_input" | >+ sed 's/[\\\\&|]/\\\\&/g'`;; #( >+ *) ac_sed_conf_input=$configure_input;; >+ esac >+ >+ case $ac_tag in >+ *:-:* | *:-) cat >"$ac_tmp/stdin" \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; >+ esac >+ ;; >+ esac >+ >+ ac_dir=`$as_dirname -- "$ac_file" || >+$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$ac_file" : 'X\(//\)[^/]' \| \ >+ X"$ac_file" : 'X\(//\)$' \| \ >+ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$ac_file" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ as_dir="$ac_dir"; as_fn_mkdir_p >+ ac_builddir=. >+ >+case "$ac_dir" in >+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; >+*) >+ ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` >+ # A ".." for each directory in $ac_dir_suffix. >+ ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` >+ case $ac_top_builddir_sub in >+ "") ac_top_builddir_sub=. ac_top_build_prefix= ;; >+ *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; >+ esac ;; >+esac >+ac_abs_top_builddir=$ac_pwd >+ac_abs_builddir=$ac_pwd$ac_dir_suffix >+# for backward compatibility: >+ac_top_builddir=$ac_top_build_prefix >+ >+case $srcdir in >+ .) # We are building in place. >+ ac_srcdir=. >+ ac_top_srcdir=$ac_top_builddir_sub >+ ac_abs_top_srcdir=$ac_pwd ;; >+ [\\/]* | ?:[\\/]* ) # Absolute name. >+ ac_srcdir=$srcdir$ac_dir_suffix; >+ ac_top_srcdir=$srcdir >+ ac_abs_top_srcdir=$srcdir ;; >+ *) # Relative name. >+ ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix >+ ac_top_srcdir=$ac_top_build_prefix$srcdir >+ ac_abs_top_srcdir=$ac_pwd/$srcdir ;; >+esac >+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix >+ >+ >+ case $ac_mode in >+ :F) >+ # >+ # CONFIG_FILE >+ # >+ >+# If the template does not know about datarootdir, expand it. >+# FIXME: This hack should be removed a few years after 2.60. >+ac_datarootdir_hack=; ac_datarootdir_seen= >+ac_sed_dataroot=' >+/datarootdir/ { >+ p >+ q >+} >+/@datadir@/p >+/@docdir@/p >+/@infodir@/p >+/@localedir@/p >+/@mandir@/p' >+case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in >+*datarootdir*) ac_datarootdir_seen=yes;; >+*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 >+$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} >+ ac_datarootdir_hack=' >+ s&@datadir@&${datarootdir}&g >+ s&@docdir@&${datarootdir}/doc/${PACKAGE_TARNAME}&g >+ s&@infodir@&${datarootdir}/info&g >+ s&@localedir@&${datarootdir}/locale&g >+ s&@mandir@&${datarootdir}/man&g >+ s&\${datarootdir}&${prefix}/share&g' ;; >+esac >+ac_sed_extra="/^[ ]*VPATH[ ]*=[ ]*/{ >+h >+s/// >+s/^/:/ >+s/[ ]*$/:/ >+s/:\$(srcdir):/:/g >+s/:\${srcdir}:/:/g >+s/:@srcdir@:/:/g >+s/^:*// >+s/:*$// >+x >+s/\(=[ ]*\).*/\1/ >+G >+s/\n// >+s/^[^=]*=[ ]*$// >+} >+ >+:t >+/@[a-zA-Z_][a-zA-Z_0-9]*@/!b >+s|@configure_input@|$ac_sed_conf_input|;t t >+s&@top_builddir@&$ac_top_builddir_sub&;t t >+s&@top_build_prefix@&$ac_top_build_prefix&;t t >+s&@srcdir@&$ac_srcdir&;t t >+s&@abs_srcdir@&$ac_abs_srcdir&;t t >+s&@top_srcdir@&$ac_top_srcdir&;t t >+s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t >+s&@builddir@&$ac_builddir&;t t >+s&@abs_builddir@&$ac_abs_builddir&;t t >+s&@abs_top_builddir@&$ac_abs_top_builddir&;t t >+$ac_datarootdir_hack >+" >+eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ >+ >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ >+test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && >+ { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && >+ { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ >+ "$ac_tmp/out"`; test -z "$ac_out"; } && >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' >+which seems to be undefined. Please make sure it is defined" >&5 >+$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' >+which seems to be undefined. Please make sure it is defined" >&2;} >+ >+ rm -f "$ac_tmp/stdin" >+ case $ac_file in >+ -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; >+ *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; >+ esac \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ ;; >+ :H) >+ # >+ # CONFIG_HEADER >+ # >+ if test x"$ac_file" != x-; then >+ { >+ $as_echo "/* $configure_input */" \ >+ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" >+ } >"$ac_tmp/config.h" \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 >+$as_echo "$as_me: $ac_file is unchanged" >&6;} >+ else >+ rm -f "$ac_file" >+ mv "$ac_tmp/config.h" "$ac_file" \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ fi >+ else >+ $as_echo "/* $configure_input */" \ >+ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ >+ || as_fn_error $? "could not create -" "$LINENO" 5 >+ fi >+ ;; >+ >+ >+ esac >+ >+done # for ac_tag >+ >+ >+as_fn_exit 0 >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/configure libbgpdump-new/work/libbgpdump-1.4.99.15/configure >--- libbgpdump/work/libbgpdump-1.4.99.15/configure 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/configure 2015-09-16 20:22:49.000000000 +1200 >@@ -0,0 +1,5019 @@ >+#! /bin/sh >+# From configure.in Revision. >+# Guess values for system-dependent variables and create Makefiles. >+# Generated by GNU Autoconf 2.69 for libbgpdump 1.4.99.15. >+# >+# Report bugs to <ris@ripe.net>. >+# >+# >+# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. >+# >+# >+# This configure script is free software; the Free Software Foundation >+# gives unlimited permission to copy, distribute and modify it. >+## -------------------- ## >+## M4sh Initialization. ## >+## -------------------- ## >+ >+# Be more Bourne compatible >+DUALCASE=1; export DUALCASE # for MKS sh >+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : >+ emulate sh >+ NULLCMD=: >+ # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which >+ # is contrary to our usage. Disable this feature. >+ alias -g '${1+"$@"}'='"$@"' >+ setopt NO_GLOB_SUBST >+else >+ case `(set -o) 2>/dev/null` in #( >+ *posix*) : >+ set -o posix ;; #( >+ *) : >+ ;; >+esac >+fi >+ >+ >+as_nl=' >+' >+export as_nl >+# Printing a long string crashes Solaris 7 /usr/bin/printf. >+as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo >+# Prefer a ksh shell builtin over an external printf program on Solaris, >+# but without wasting forks for bash or zsh. >+if test -z "$BASH_VERSION$ZSH_VERSION" \ >+ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='print -r --' >+ as_echo_n='print -rn --' >+elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='printf %s\n' >+ as_echo_n='printf %s' >+else >+ if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then >+ as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' >+ as_echo_n='/usr/ucb/echo -n' >+ else >+ as_echo_body='eval expr "X$1" : "X\\(.*\\)"' >+ as_echo_n_body='eval >+ arg=$1; >+ case $arg in #( >+ *"$as_nl"*) >+ expr "X$arg" : "X\\(.*\\)$as_nl"; >+ arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; >+ esac; >+ expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" >+ ' >+ export as_echo_n_body >+ as_echo_n='sh -c $as_echo_n_body as_echo' >+ fi >+ export as_echo_body >+ as_echo='sh -c $as_echo_body as_echo' >+fi >+ >+# The user is always right. >+if test "${PATH_SEPARATOR+set}" != set; then >+ PATH_SEPARATOR=: >+ (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { >+ (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || >+ PATH_SEPARATOR=';' >+ } >+fi >+ >+ >+# IFS >+# We need space, tab and new line, in precisely that order. Quoting is >+# there to prevent editors from complaining about space-tab. >+# (If _AS_PATH_WALK were called with IFS unset, it would disable word >+# splitting by setting IFS to empty value.) >+IFS=" "" $as_nl" >+ >+# Find who we are. Look in the path if we contain no directory separator. >+as_myself= >+case $0 in #(( >+ *[\\/]* ) as_myself=$0 ;; >+ *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break >+ done >+IFS=$as_save_IFS >+ >+ ;; >+esac >+# We did not find ourselves, most probably we were run as `sh COMMAND' >+# in which case we are not to be found in the path. >+if test "x$as_myself" = x; then >+ as_myself=$0 >+fi >+if test ! -f "$as_myself"; then >+ $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 >+ exit 1 >+fi >+ >+# Unset variables that we do not need and which cause bugs (e.g. in >+# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" >+# suppresses any "Segmentation fault" message there. '((' could >+# trigger a bug in pdksh 5.2.14. >+for as_var in BASH_ENV ENV MAIL MAILPATH >+do eval test x\${$as_var+set} = xset \ >+ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : >+done >+PS1='$ ' >+PS2='> ' >+PS4='+ ' >+ >+# NLS nuisances. >+LC_ALL=C >+export LC_ALL >+LANGUAGE=C >+export LANGUAGE >+ >+# CDPATH. >+(unset CDPATH) >/dev/null 2>&1 && unset CDPATH >+ >+# Use a proper internal environment variable to ensure we don't fall >+ # into an infinite loop, continuously re-executing ourselves. >+ if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then >+ _as_can_reexec=no; export _as_can_reexec; >+ # We cannot yet assume a decent shell, so we have to provide a >+# neutralization value for shells without unset; and this also >+# works around shells that cannot unset nonexistent variables. >+# Preserve -v and -x to the replacement shell. >+BASH_ENV=/dev/null >+ENV=/dev/null >+(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV >+case $- in # (((( >+ *v*x* | *x*v* ) as_opts=-vx ;; >+ *v* ) as_opts=-v ;; >+ *x* ) as_opts=-x ;; >+ * ) as_opts= ;; >+esac >+exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} >+# Admittedly, this is quite paranoid, since all the known shells bail >+# out after a failed `exec'. >+$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 >+as_fn_exit 255 >+ fi >+ # We don't want this to propagate to other subprocesses. >+ { _as_can_reexec=; unset _as_can_reexec;} >+if test "x$CONFIG_SHELL" = x; then >+ as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : >+ emulate sh >+ NULLCMD=: >+ # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which >+ # is contrary to our usage. Disable this feature. >+ alias -g '\${1+\"\$@\"}'='\"\$@\"' >+ setopt NO_GLOB_SUBST >+else >+ case \`(set -o) 2>/dev/null\` in #( >+ *posix*) : >+ set -o posix ;; #( >+ *) : >+ ;; >+esac >+fi >+" >+ as_required="as_fn_return () { (exit \$1); } >+as_fn_success () { as_fn_return 0; } >+as_fn_failure () { as_fn_return 1; } >+as_fn_ret_success () { return 0; } >+as_fn_ret_failure () { return 1; } >+ >+exitcode=0 >+as_fn_success || { exitcode=1; echo as_fn_success failed.; } >+as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } >+as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } >+as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } >+if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : >+ >+else >+ exitcode=1; echo positional parameters were not saved. >+fi >+test x\$exitcode = x0 || exit 1 >+test -x / || exit 1" >+ as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO >+ as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO >+ eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && >+ test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 >+test \$(( 1 + 1 )) = 2 || exit 1" >+ if (eval "$as_required") 2>/dev/null; then : >+ as_have_required=yes >+else >+ as_have_required=no >+fi >+ if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : >+ >+else >+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+as_found=false >+for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ as_found=: >+ case $as_dir in #( >+ /*) >+ for as_base in sh bash ksh sh5; do >+ # Try only shells that exist, to save several forks. >+ as_shell=$as_dir/$as_base >+ if { test -f "$as_shell" || test -f "$as_shell.exe"; } && >+ { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : >+ CONFIG_SHELL=$as_shell as_have_required=yes >+ if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : >+ break 2 >+fi >+fi >+ done;; >+ esac >+ as_found=false >+done >+$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && >+ { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : >+ CONFIG_SHELL=$SHELL as_have_required=yes >+fi; } >+IFS=$as_save_IFS >+ >+ >+ if test "x$CONFIG_SHELL" != x; then : >+ export CONFIG_SHELL >+ # We cannot yet assume a decent shell, so we have to provide a >+# neutralization value for shells without unset; and this also >+# works around shells that cannot unset nonexistent variables. >+# Preserve -v and -x to the replacement shell. >+BASH_ENV=/dev/null >+ENV=/dev/null >+(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV >+case $- in # (((( >+ *v*x* | *x*v* ) as_opts=-vx ;; >+ *v* ) as_opts=-v ;; >+ *x* ) as_opts=-x ;; >+ * ) as_opts= ;; >+esac >+exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} >+# Admittedly, this is quite paranoid, since all the known shells bail >+# out after a failed `exec'. >+$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 >+exit 255 >+fi >+ >+ if test x$as_have_required = xno; then : >+ $as_echo "$0: This script requires a shell more modern than all" >+ $as_echo "$0: the shells that I found on your system." >+ if test x${ZSH_VERSION+set} = xset ; then >+ $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" >+ $as_echo "$0: be upgraded to zsh 4.3.4 or later." >+ else >+ $as_echo "$0: Please tell bug-autoconf@gnu.org and ris@ripe.net about >+$0: your system, including any error possibly output before >+$0: this message. Then install a modern shell, or manually >+$0: run the script under such a shell if you do have one." >+ fi >+ exit 1 >+fi >+fi >+fi >+SHELL=${CONFIG_SHELL-/bin/sh} >+export SHELL >+# Unset more variables known to interfere with behavior of common tools. >+CLICOLOR_FORCE= GREP_OPTIONS= >+unset CLICOLOR_FORCE GREP_OPTIONS >+ >+## --------------------- ## >+## M4sh Shell Functions. ## >+## --------------------- ## >+# as_fn_unset VAR >+# --------------- >+# Portably unset VAR. >+as_fn_unset () >+{ >+ { eval $1=; unset $1;} >+} >+as_unset=as_fn_unset >+ >+# as_fn_set_status STATUS >+# ----------------------- >+# Set $? to STATUS, without forking. >+as_fn_set_status () >+{ >+ return $1 >+} # as_fn_set_status >+ >+# as_fn_exit STATUS >+# ----------------- >+# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. >+as_fn_exit () >+{ >+ set +e >+ as_fn_set_status $1 >+ exit $1 >+} # as_fn_exit >+ >+# as_fn_mkdir_p >+# ------------- >+# Create "$as_dir" as a directory, including parents if necessary. >+as_fn_mkdir_p () >+{ >+ >+ case $as_dir in #( >+ -*) as_dir=./$as_dir;; >+ esac >+ test -d "$as_dir" || eval $as_mkdir_p || { >+ as_dirs= >+ while :; do >+ case $as_dir in #( >+ *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( >+ *) as_qdir=$as_dir;; >+ esac >+ as_dirs="'$as_qdir' $as_dirs" >+ as_dir=`$as_dirname -- "$as_dir" || >+$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$as_dir" : 'X\(//\)[^/]' \| \ >+ X"$as_dir" : 'X\(//\)$' \| \ >+ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$as_dir" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ test -d "$as_dir" && break >+ done >+ test -z "$as_dirs" || eval "mkdir $as_dirs" >+ } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" >+ >+ >+} # as_fn_mkdir_p >+ >+# as_fn_executable_p FILE >+# ----------------------- >+# Test if FILE is an executable regular file. >+as_fn_executable_p () >+{ >+ test -f "$1" && test -x "$1" >+} # as_fn_executable_p >+# as_fn_append VAR VALUE >+# ---------------------- >+# Append the text in VALUE to the end of the definition contained in VAR. Take >+# advantage of any shell optimizations that allow amortized linear growth over >+# repeated appends, instead of the typical quadratic growth present in naive >+# implementations. >+if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : >+ eval 'as_fn_append () >+ { >+ eval $1+=\$2 >+ }' >+else >+ as_fn_append () >+ { >+ eval $1=\$$1\$2 >+ } >+fi # as_fn_append >+ >+# as_fn_arith ARG... >+# ------------------ >+# Perform arithmetic evaluation on the ARGs, and store the result in the >+# global $as_val. Take advantage of shells that can avoid forks. The arguments >+# must be portable across $(()) and expr. >+if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : >+ eval 'as_fn_arith () >+ { >+ as_val=$(( $* )) >+ }' >+else >+ as_fn_arith () >+ { >+ as_val=`expr "$@" || test $? -eq 1` >+ } >+fi # as_fn_arith >+ >+ >+# as_fn_error STATUS ERROR [LINENO LOG_FD] >+# ---------------------------------------- >+# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are >+# provided, also output the error to LOG_FD, referencing LINENO. Then exit the >+# script with STATUS, using 1 if that was 0. >+as_fn_error () >+{ >+ as_status=$1; test $as_status -eq 0 && as_status=1 >+ if test "$4"; then >+ as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 >+ fi >+ $as_echo "$as_me: error: $2" >&2 >+ as_fn_exit $as_status >+} # as_fn_error >+ >+if expr a : '\(a\)' >/dev/null 2>&1 && >+ test "X`expr 00001 : '.*\(...\)'`" = X001; then >+ as_expr=expr >+else >+ as_expr=false >+fi >+ >+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then >+ as_basename=basename >+else >+ as_basename=false >+fi >+ >+if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then >+ as_dirname=dirname >+else >+ as_dirname=false >+fi >+ >+as_me=`$as_basename -- "$0" || >+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ >+ X"$0" : 'X\(//\)$' \| \ >+ X"$0" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X/"$0" | >+ sed '/^.*\/\([^/][^/]*\)\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ >+# Avoid depending upon Character Ranges. >+as_cr_letters='abcdefghijklmnopqrstuvwxyz' >+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' >+as_cr_Letters=$as_cr_letters$as_cr_LETTERS >+as_cr_digits='0123456789' >+as_cr_alnum=$as_cr_Letters$as_cr_digits >+ >+ >+ as_lineno_1=$LINENO as_lineno_1a=$LINENO >+ as_lineno_2=$LINENO as_lineno_2a=$LINENO >+ eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && >+ test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { >+ # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) >+ sed -n ' >+ p >+ /[$]LINENO/= >+ ' <$as_myself | >+ sed ' >+ s/[$]LINENO.*/&-/ >+ t lineno >+ b >+ :lineno >+ N >+ :loop >+ s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ >+ t loop >+ s/-\n.*// >+ ' >$as_me.lineno && >+ chmod +x "$as_me.lineno" || >+ { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } >+ >+ # If we had to re-execute with $CONFIG_SHELL, we're ensured to have >+ # already done that, so ensure we don't try to do so again and fall >+ # in an infinite loop. This has already happened in practice. >+ _as_can_reexec=no; export _as_can_reexec >+ # Don't try to exec as it changes $[0], causing all sort of problems >+ # (the dirname of $[0] is not the place where we might find the >+ # original and so on. Autoconf is especially sensitive to this). >+ . "./$as_me.lineno" >+ # Exit status is that of the last command. >+ exit >+} >+ >+ECHO_C= ECHO_N= ECHO_T= >+case `echo -n x` in #((((( >+-n*) >+ case `echo 'xy\c'` in >+ *c*) ECHO_T=' ';; # ECHO_T is single tab character. >+ xy) ECHO_C='\c';; >+ *) echo `echo ksh88 bug on AIX 6.1` > /dev/null >+ ECHO_T=' ';; >+ esac;; >+*) >+ ECHO_N='-n';; >+esac >+ >+rm -f conf$$ conf$$.exe conf$$.file >+if test -d conf$$.dir; then >+ rm -f conf$$.dir/conf$$.file >+else >+ rm -f conf$$.dir >+ mkdir conf$$.dir 2>/dev/null >+fi >+if (echo >conf$$.file) 2>/dev/null; then >+ if ln -s conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s='ln -s' >+ # ... but there are two gotchas: >+ # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. >+ # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. >+ # In both cases, we have to default to `cp -pR'. >+ ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || >+ as_ln_s='cp -pR' >+ elif ln conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s=ln >+ else >+ as_ln_s='cp -pR' >+ fi >+else >+ as_ln_s='cp -pR' >+fi >+rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file >+rmdir conf$$.dir 2>/dev/null >+ >+if mkdir -p . 2>/dev/null; then >+ as_mkdir_p='mkdir -p "$as_dir"' >+else >+ test -d ./-p && rmdir ./-p >+ as_mkdir_p=false >+fi >+ >+as_test_x='test -x' >+as_executable_p=as_fn_executable_p >+ >+# Sed expression to map a string onto a valid CPP name. >+as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" >+ >+# Sed expression to map a string onto a valid variable name. >+as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" >+ >+ >+test -n "$DJDIR" || exec 7<&0 </dev/null >+exec 6>&1 >+ >+# Name of the host. >+# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, >+# so uname gets run too. >+ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` >+ >+# >+# Initializations. >+# >+ac_default_prefix=/usr/local >+ac_clean_files= >+ac_config_libobj_dir=. >+LIBOBJS= >+cross_compiling=no >+subdirs= >+MFLAGS= >+MAKEFLAGS= >+ >+# Identity of this package. >+PACKAGE_NAME='libbgpdump' >+PACKAGE_TARNAME='libbgpdump' >+PACKAGE_VERSION='1.4.99.15' >+PACKAGE_STRING='libbgpdump 1.4.99.15' >+PACKAGE_BUGREPORT='ris@ripe.net' >+PACKAGE_URL='' >+ >+ac_unique_file="bgpdump_lib.c" >+# Factoring default headers for most tests. >+ac_includes_default="\ >+#include <stdio.h> >+#ifdef HAVE_SYS_TYPES_H >+# include <sys/types.h> >+#endif >+#ifdef HAVE_SYS_STAT_H >+# include <sys/stat.h> >+#endif >+#ifdef STDC_HEADERS >+# include <stdlib.h> >+# include <stddef.h> >+#else >+# ifdef HAVE_STDLIB_H >+# include <stdlib.h> >+# endif >+#endif >+#ifdef HAVE_STRING_H >+# if !defined STDC_HEADERS && defined HAVE_MEMORY_H >+# include <memory.h> >+# endif >+# include <string.h> >+#endif >+#ifdef HAVE_STRINGS_H >+# include <strings.h> >+#endif >+#ifdef HAVE_INTTYPES_H >+# include <inttypes.h> >+#endif >+#ifdef HAVE_STDINT_H >+# include <stdint.h> >+#endif >+#ifdef HAVE_UNISTD_H >+# include <unistd.h> >+#endif" >+ >+ac_subst_vars='LTLIBOBJS >+LIBOBJS >+EGREP >+GREP >+CPP >+RANLIB >+OBJEXT >+EXEEXT >+ac_ct_CC >+CPPFLAGS >+LDFLAGS >+CFLAGS >+CC >+target_alias >+host_alias >+build_alias >+LIBS >+ECHO_T >+ECHO_N >+ECHO_C >+DEFS >+mandir >+localedir >+libdir >+psdir >+pdfdir >+dvidir >+htmldir >+infodir >+docdir >+oldincludedir >+includedir >+localstatedir >+sharedstatedir >+sysconfdir >+datadir >+datarootdir >+libexecdir >+sbindir >+bindir >+program_transform_name >+prefix >+exec_prefix >+PACKAGE_URL >+PACKAGE_BUGREPORT >+PACKAGE_STRING >+PACKAGE_VERSION >+PACKAGE_TARNAME >+PACKAGE_NAME >+PATH_SEPARATOR >+SHELL' >+ac_subst_files='' >+ac_user_opts=' >+enable_option_checking >+' >+ ac_precious_vars='build_alias >+host_alias >+target_alias >+CC >+CFLAGS >+LDFLAGS >+LIBS >+CPPFLAGS >+CPP' >+ >+ >+# Initialize some variables set by options. >+ac_init_help= >+ac_init_version=false >+ac_unrecognized_opts= >+ac_unrecognized_sep= >+# The variables have the same names as the options, with >+# dashes changed to underlines. >+cache_file=/dev/null >+exec_prefix=NONE >+no_create= >+no_recursion= >+prefix=NONE >+program_prefix=NONE >+program_suffix=NONE >+program_transform_name=s,x,x, >+silent= >+site= >+srcdir= >+verbose= >+x_includes=NONE >+x_libraries=NONE >+ >+# Installation directory options. >+# These are left unexpanded so users can "make install exec_prefix=/foo" >+# and all the variables that are supposed to be based on exec_prefix >+# by default will actually change. >+# Use braces instead of parens because sh, perl, etc. also accept them. >+# (The list follows the same order as the GNU Coding Standards.) >+bindir='${exec_prefix}/bin' >+sbindir='${exec_prefix}/sbin' >+libexecdir='${exec_prefix}/libexec' >+datarootdir='${prefix}/share' >+datadir='${datarootdir}' >+sysconfdir='${prefix}/etc' >+sharedstatedir='${prefix}/com' >+localstatedir='${prefix}/var' >+includedir='${prefix}/include' >+oldincludedir='/usr/include' >+docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' >+infodir='${datarootdir}/info' >+htmldir='${docdir}' >+dvidir='${docdir}' >+pdfdir='${docdir}' >+psdir='${docdir}' >+libdir='${exec_prefix}/lib' >+localedir='${datarootdir}/locale' >+mandir='${datarootdir}/man' >+ >+ac_prev= >+ac_dashdash= >+for ac_option >+do >+ # If the previous option needs an argument, assign it. >+ if test -n "$ac_prev"; then >+ eval $ac_prev=\$ac_option >+ ac_prev= >+ continue >+ fi >+ >+ case $ac_option in >+ *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; >+ *=) ac_optarg= ;; >+ *) ac_optarg=yes ;; >+ esac >+ >+ # Accept the important Cygnus configure options, so we can diagnose typos. >+ >+ case $ac_dashdash$ac_option in >+ --) >+ ac_dashdash=yes ;; >+ >+ -bindir | --bindir | --bindi | --bind | --bin | --bi) >+ ac_prev=bindir ;; >+ -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) >+ bindir=$ac_optarg ;; >+ >+ -build | --build | --buil | --bui | --bu) >+ ac_prev=build_alias ;; >+ -build=* | --build=* | --buil=* | --bui=* | --bu=*) >+ build_alias=$ac_optarg ;; >+ >+ -cache-file | --cache-file | --cache-fil | --cache-fi \ >+ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) >+ ac_prev=cache_file ;; >+ -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ >+ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) >+ cache_file=$ac_optarg ;; >+ >+ --config-cache | -C) >+ cache_file=config.cache ;; >+ >+ -datadir | --datadir | --datadi | --datad) >+ ac_prev=datadir ;; >+ -datadir=* | --datadir=* | --datadi=* | --datad=*) >+ datadir=$ac_optarg ;; >+ >+ -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ >+ | --dataroo | --dataro | --datar) >+ ac_prev=datarootdir ;; >+ -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ >+ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) >+ datarootdir=$ac_optarg ;; >+ >+ -disable-* | --disable-*) >+ ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` >+ # Reject names that are not valid shell variable names. >+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && >+ as_fn_error $? "invalid feature name: $ac_useropt" >+ ac_useropt_orig=$ac_useropt >+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` >+ case $ac_user_opts in >+ *" >+"enable_$ac_useropt" >+"*) ;; >+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" >+ ac_unrecognized_sep=', ';; >+ esac >+ eval enable_$ac_useropt=no ;; >+ >+ -docdir | --docdir | --docdi | --doc | --do) >+ ac_prev=docdir ;; >+ -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) >+ docdir=$ac_optarg ;; >+ >+ -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) >+ ac_prev=dvidir ;; >+ -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) >+ dvidir=$ac_optarg ;; >+ >+ -enable-* | --enable-*) >+ ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` >+ # Reject names that are not valid shell variable names. >+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && >+ as_fn_error $? "invalid feature name: $ac_useropt" >+ ac_useropt_orig=$ac_useropt >+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` >+ case $ac_user_opts in >+ *" >+"enable_$ac_useropt" >+"*) ;; >+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" >+ ac_unrecognized_sep=', ';; >+ esac >+ eval enable_$ac_useropt=\$ac_optarg ;; >+ >+ -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ >+ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ >+ | --exec | --exe | --ex) >+ ac_prev=exec_prefix ;; >+ -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ >+ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ >+ | --exec=* | --exe=* | --ex=*) >+ exec_prefix=$ac_optarg ;; >+ >+ -gas | --gas | --ga | --g) >+ # Obsolete; use --with-gas. >+ with_gas=yes ;; >+ >+ -help | --help | --hel | --he | -h) >+ ac_init_help=long ;; >+ -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) >+ ac_init_help=recursive ;; >+ -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) >+ ac_init_help=short ;; >+ >+ -host | --host | --hos | --ho) >+ ac_prev=host_alias ;; >+ -host=* | --host=* | --hos=* | --ho=*) >+ host_alias=$ac_optarg ;; >+ >+ -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) >+ ac_prev=htmldir ;; >+ -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ >+ | --ht=*) >+ htmldir=$ac_optarg ;; >+ >+ -includedir | --includedir | --includedi | --included | --include \ >+ | --includ | --inclu | --incl | --inc) >+ ac_prev=includedir ;; >+ -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ >+ | --includ=* | --inclu=* | --incl=* | --inc=*) >+ includedir=$ac_optarg ;; >+ >+ -infodir | --infodir | --infodi | --infod | --info | --inf) >+ ac_prev=infodir ;; >+ -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) >+ infodir=$ac_optarg ;; >+ >+ -libdir | --libdir | --libdi | --libd) >+ ac_prev=libdir ;; >+ -libdir=* | --libdir=* | --libdi=* | --libd=*) >+ libdir=$ac_optarg ;; >+ >+ -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ >+ | --libexe | --libex | --libe) >+ ac_prev=libexecdir ;; >+ -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ >+ | --libexe=* | --libex=* | --libe=*) >+ libexecdir=$ac_optarg ;; >+ >+ -localedir | --localedir | --localedi | --localed | --locale) >+ ac_prev=localedir ;; >+ -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) >+ localedir=$ac_optarg ;; >+ >+ -localstatedir | --localstatedir | --localstatedi | --localstated \ >+ | --localstate | --localstat | --localsta | --localst | --locals) >+ ac_prev=localstatedir ;; >+ -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ >+ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) >+ localstatedir=$ac_optarg ;; >+ >+ -mandir | --mandir | --mandi | --mand | --man | --ma | --m) >+ ac_prev=mandir ;; >+ -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) >+ mandir=$ac_optarg ;; >+ >+ -nfp | --nfp | --nf) >+ # Obsolete; use --without-fp. >+ with_fp=no ;; >+ >+ -no-create | --no-create | --no-creat | --no-crea | --no-cre \ >+ | --no-cr | --no-c | -n) >+ no_create=yes ;; >+ >+ -no-recursion | --no-recursion | --no-recursio | --no-recursi \ >+ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) >+ no_recursion=yes ;; >+ >+ -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ >+ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ >+ | --oldin | --oldi | --old | --ol | --o) >+ ac_prev=oldincludedir ;; >+ -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ >+ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ >+ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) >+ oldincludedir=$ac_optarg ;; >+ >+ -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) >+ ac_prev=prefix ;; >+ -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) >+ prefix=$ac_optarg ;; >+ >+ -program-prefix | --program-prefix | --program-prefi | --program-pref \ >+ | --program-pre | --program-pr | --program-p) >+ ac_prev=program_prefix ;; >+ -program-prefix=* | --program-prefix=* | --program-prefi=* \ >+ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) >+ program_prefix=$ac_optarg ;; >+ >+ -program-suffix | --program-suffix | --program-suffi | --program-suff \ >+ | --program-suf | --program-su | --program-s) >+ ac_prev=program_suffix ;; >+ -program-suffix=* | --program-suffix=* | --program-suffi=* \ >+ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) >+ program_suffix=$ac_optarg ;; >+ >+ -program-transform-name | --program-transform-name \ >+ | --program-transform-nam | --program-transform-na \ >+ | --program-transform-n | --program-transform- \ >+ | --program-transform | --program-transfor \ >+ | --program-transfo | --program-transf \ >+ | --program-trans | --program-tran \ >+ | --progr-tra | --program-tr | --program-t) >+ ac_prev=program_transform_name ;; >+ -program-transform-name=* | --program-transform-name=* \ >+ | --program-transform-nam=* | --program-transform-na=* \ >+ | --program-transform-n=* | --program-transform-=* \ >+ | --program-transform=* | --program-transfor=* \ >+ | --program-transfo=* | --program-transf=* \ >+ | --program-trans=* | --program-tran=* \ >+ | --progr-tra=* | --program-tr=* | --program-t=*) >+ program_transform_name=$ac_optarg ;; >+ >+ -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) >+ ac_prev=pdfdir ;; >+ -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) >+ pdfdir=$ac_optarg ;; >+ >+ -psdir | --psdir | --psdi | --psd | --ps) >+ ac_prev=psdir ;; >+ -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) >+ psdir=$ac_optarg ;; >+ >+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \ >+ | -silent | --silent | --silen | --sile | --sil) >+ silent=yes ;; >+ >+ -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) >+ ac_prev=sbindir ;; >+ -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ >+ | --sbi=* | --sb=*) >+ sbindir=$ac_optarg ;; >+ >+ -sharedstatedir | --sharedstatedir | --sharedstatedi \ >+ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ >+ | --sharedst | --shareds | --shared | --share | --shar \ >+ | --sha | --sh) >+ ac_prev=sharedstatedir ;; >+ -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ >+ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ >+ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ >+ | --sha=* | --sh=*) >+ sharedstatedir=$ac_optarg ;; >+ >+ -site | --site | --sit) >+ ac_prev=site ;; >+ -site=* | --site=* | --sit=*) >+ site=$ac_optarg ;; >+ >+ -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) >+ ac_prev=srcdir ;; >+ -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) >+ srcdir=$ac_optarg ;; >+ >+ -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ >+ | --syscon | --sysco | --sysc | --sys | --sy) >+ ac_prev=sysconfdir ;; >+ -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ >+ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) >+ sysconfdir=$ac_optarg ;; >+ >+ -target | --target | --targe | --targ | --tar | --ta | --t) >+ ac_prev=target_alias ;; >+ -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) >+ target_alias=$ac_optarg ;; >+ >+ -v | -verbose | --verbose | --verbos | --verbo | --verb) >+ verbose=yes ;; >+ >+ -version | --version | --versio | --versi | --vers | -V) >+ ac_init_version=: ;; >+ >+ -with-* | --with-*) >+ ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` >+ # Reject names that are not valid shell variable names. >+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && >+ as_fn_error $? "invalid package name: $ac_useropt" >+ ac_useropt_orig=$ac_useropt >+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` >+ case $ac_user_opts in >+ *" >+"with_$ac_useropt" >+"*) ;; >+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" >+ ac_unrecognized_sep=', ';; >+ esac >+ eval with_$ac_useropt=\$ac_optarg ;; >+ >+ -without-* | --without-*) >+ ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` >+ # Reject names that are not valid shell variable names. >+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && >+ as_fn_error $? "invalid package name: $ac_useropt" >+ ac_useropt_orig=$ac_useropt >+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` >+ case $ac_user_opts in >+ *" >+"with_$ac_useropt" >+"*) ;; >+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" >+ ac_unrecognized_sep=', ';; >+ esac >+ eval with_$ac_useropt=no ;; >+ >+ --x) >+ # Obsolete; use --with-x. >+ with_x=yes ;; >+ >+ -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ >+ | --x-incl | --x-inc | --x-in | --x-i) >+ ac_prev=x_includes ;; >+ -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ >+ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) >+ x_includes=$ac_optarg ;; >+ >+ -x-libraries | --x-libraries | --x-librarie | --x-librari \ >+ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) >+ ac_prev=x_libraries ;; >+ -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ >+ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) >+ x_libraries=$ac_optarg ;; >+ >+ -*) as_fn_error $? "unrecognized option: \`$ac_option' >+Try \`$0 --help' for more information" >+ ;; >+ >+ *=*) >+ ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` >+ # Reject names that are not valid shell variable names. >+ case $ac_envvar in #( >+ '' | [0-9]* | *[!_$as_cr_alnum]* ) >+ as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; >+ esac >+ eval $ac_envvar=\$ac_optarg >+ export $ac_envvar ;; >+ >+ *) >+ # FIXME: should be removed in autoconf 3.0. >+ $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 >+ expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && >+ $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 >+ : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" >+ ;; >+ >+ esac >+done >+ >+if test -n "$ac_prev"; then >+ ac_option=--`echo $ac_prev | sed 's/_/-/g'` >+ as_fn_error $? "missing argument to $ac_option" >+fi >+ >+if test -n "$ac_unrecognized_opts"; then >+ case $enable_option_checking in >+ no) ;; >+ fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; >+ *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; >+ esac >+fi >+ >+# Check all directory arguments for consistency. >+for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ >+ datadir sysconfdir sharedstatedir localstatedir includedir \ >+ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ >+ libdir localedir mandir >+do >+ eval ac_val=\$$ac_var >+ # Remove trailing slashes. >+ case $ac_val in >+ */ ) >+ ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` >+ eval $ac_var=\$ac_val;; >+ esac >+ # Be sure to have absolute directory names. >+ case $ac_val in >+ [\\/$]* | ?:[\\/]* ) continue;; >+ NONE | '' ) case $ac_var in *prefix ) continue;; esac;; >+ esac >+ as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" >+done >+ >+# There might be people who depend on the old broken behavior: `$host' >+# used to hold the argument of --host etc. >+# FIXME: To remove some day. >+build=$build_alias >+host=$host_alias >+target=$target_alias >+ >+# FIXME: To remove some day. >+if test "x$host_alias" != x; then >+ if test "x$build_alias" = x; then >+ cross_compiling=maybe >+ elif test "x$build_alias" != "x$host_alias"; then >+ cross_compiling=yes >+ fi >+fi >+ >+ac_tool_prefix= >+test -n "$host_alias" && ac_tool_prefix=$host_alias- >+ >+test "$silent" = yes && exec 6>/dev/null >+ >+ >+ac_pwd=`pwd` && test -n "$ac_pwd" && >+ac_ls_di=`ls -di .` && >+ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || >+ as_fn_error $? "working directory cannot be determined" >+test "X$ac_ls_di" = "X$ac_pwd_ls_di" || >+ as_fn_error $? "pwd does not report name of working directory" >+ >+ >+# Find the source files, if location was not specified. >+if test -z "$srcdir"; then >+ ac_srcdir_defaulted=yes >+ # Try the directory containing this script, then the parent directory. >+ ac_confdir=`$as_dirname -- "$as_myself" || >+$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$as_myself" : 'X\(//\)[^/]' \| \ >+ X"$as_myself" : 'X\(//\)$' \| \ >+ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$as_myself" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ srcdir=$ac_confdir >+ if test ! -r "$srcdir/$ac_unique_file"; then >+ srcdir=.. >+ fi >+else >+ ac_srcdir_defaulted=no >+fi >+if test ! -r "$srcdir/$ac_unique_file"; then >+ test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." >+ as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" >+fi >+ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" >+ac_abs_confdir=`( >+ cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" >+ pwd)` >+# When building in place, set srcdir=. >+if test "$ac_abs_confdir" = "$ac_pwd"; then >+ srcdir=. >+fi >+# Remove unnecessary trailing slashes from srcdir. >+# Double slashes in file names in object file debugging info >+# mess up M-x gdb in Emacs. >+case $srcdir in >+*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; >+esac >+for ac_var in $ac_precious_vars; do >+ eval ac_env_${ac_var}_set=\${${ac_var}+set} >+ eval ac_env_${ac_var}_value=\$${ac_var} >+ eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} >+ eval ac_cv_env_${ac_var}_value=\$${ac_var} >+done >+ >+# >+# Report the --help message. >+# >+if test "$ac_init_help" = "long"; then >+ # Omit some internal or obsolete options to make the list less imposing. >+ # This message is too long to be a string in the A/UX 3.1 sh. >+ cat <<_ACEOF >+\`configure' configures libbgpdump 1.4.99.15 to adapt to many kinds of systems. >+ >+Usage: $0 [OPTION]... [VAR=VALUE]... >+ >+To assign environment variables (e.g., CC, CFLAGS...), specify them as >+VAR=VALUE. See below for descriptions of some of the useful variables. >+ >+Defaults for the options are specified in brackets. >+ >+Configuration: >+ -h, --help display this help and exit >+ --help=short display options specific to this package >+ --help=recursive display the short help of all the included packages >+ -V, --version display version information and exit >+ -q, --quiet, --silent do not print \`checking ...' messages >+ --cache-file=FILE cache test results in FILE [disabled] >+ -C, --config-cache alias for \`--cache-file=config.cache' >+ -n, --no-create do not create output files >+ --srcdir=DIR find the sources in DIR [configure dir or \`..'] >+ >+Installation directories: >+ --prefix=PREFIX install architecture-independent files in PREFIX >+ [$ac_default_prefix] >+ --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX >+ [PREFIX] >+ >+By default, \`make install' will install all the files in >+\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify >+an installation prefix other than \`$ac_default_prefix' using \`--prefix', >+for instance \`--prefix=\$HOME'. >+ >+For better control, use the options below. >+ >+Fine tuning of the installation directories: >+ --bindir=DIR user executables [EPREFIX/bin] >+ --sbindir=DIR system admin executables [EPREFIX/sbin] >+ --libexecdir=DIR program executables [EPREFIX/libexec] >+ --sysconfdir=DIR read-only single-machine data [PREFIX/etc] >+ --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] >+ --localstatedir=DIR modifiable single-machine data [PREFIX/var] >+ --libdir=DIR object code libraries [EPREFIX/lib] >+ --includedir=DIR C header files [PREFIX/include] >+ --oldincludedir=DIR C header files for non-gcc [/usr/include] >+ --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] >+ --datadir=DIR read-only architecture-independent data [DATAROOTDIR] >+ --infodir=DIR info documentation [DATAROOTDIR/info] >+ --localedir=DIR locale-dependent data [DATAROOTDIR/locale] >+ --mandir=DIR man documentation [DATAROOTDIR/man] >+ --docdir=DIR documentation root [DATAROOTDIR/doc/libbgpdump] >+ --htmldir=DIR html documentation [DOCDIR] >+ --dvidir=DIR dvi documentation [DOCDIR] >+ --pdfdir=DIR pdf documentation [DOCDIR] >+ --psdir=DIR ps documentation [DOCDIR] >+_ACEOF >+ >+ cat <<\_ACEOF >+_ACEOF >+fi >+ >+if test -n "$ac_init_help"; then >+ case $ac_init_help in >+ short | recursive ) echo "Configuration of libbgpdump 1.4.99.15:";; >+ esac >+ cat <<\_ACEOF >+ >+Some influential environment variables: >+ CC C compiler command >+ CFLAGS C compiler flags >+ LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a >+ nonstandard directory <lib dir> >+ LIBS libraries to pass to the linker, e.g. -l<library> >+ CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if >+ you have headers in a nonstandard directory <include dir> >+ CPP C preprocessor >+ >+Use these variables to override the choices made by `configure' or to help >+it to find libraries and programs with nonstandard names/locations. >+ >+Report bugs to <ris@ripe.net>. >+_ACEOF >+ac_status=$? >+fi >+ >+if test "$ac_init_help" = "recursive"; then >+ # If there are subdirs, report their specific --help. >+ for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue >+ test -d "$ac_dir" || >+ { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || >+ continue >+ ac_builddir=. >+ >+case "$ac_dir" in >+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; >+*) >+ ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` >+ # A ".." for each directory in $ac_dir_suffix. >+ ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` >+ case $ac_top_builddir_sub in >+ "") ac_top_builddir_sub=. ac_top_build_prefix= ;; >+ *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; >+ esac ;; >+esac >+ac_abs_top_builddir=$ac_pwd >+ac_abs_builddir=$ac_pwd$ac_dir_suffix >+# for backward compatibility: >+ac_top_builddir=$ac_top_build_prefix >+ >+case $srcdir in >+ .) # We are building in place. >+ ac_srcdir=. >+ ac_top_srcdir=$ac_top_builddir_sub >+ ac_abs_top_srcdir=$ac_pwd ;; >+ [\\/]* | ?:[\\/]* ) # Absolute name. >+ ac_srcdir=$srcdir$ac_dir_suffix; >+ ac_top_srcdir=$srcdir >+ ac_abs_top_srcdir=$srcdir ;; >+ *) # Relative name. >+ ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix >+ ac_top_srcdir=$ac_top_build_prefix$srcdir >+ ac_abs_top_srcdir=$ac_pwd/$srcdir ;; >+esac >+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix >+ >+ cd "$ac_dir" || { ac_status=$?; continue; } >+ # Check for guested configure. >+ if test -f "$ac_srcdir/configure.gnu"; then >+ echo && >+ $SHELL "$ac_srcdir/configure.gnu" --help=recursive >+ elif test -f "$ac_srcdir/configure"; then >+ echo && >+ $SHELL "$ac_srcdir/configure" --help=recursive >+ else >+ $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 >+ fi || ac_status=$? >+ cd "$ac_pwd" || { ac_status=$?; break; } >+ done >+fi >+ >+test -n "$ac_init_help" && exit $ac_status >+if $ac_init_version; then >+ cat <<\_ACEOF >+libbgpdump configure 1.4.99.15 >+generated by GNU Autoconf 2.69 >+ >+Copyright (C) 2012 Free Software Foundation, Inc. >+This configure script is free software; the Free Software Foundation >+gives unlimited permission to copy, distribute and modify it. >+_ACEOF >+ exit >+fi >+ >+## ------------------------ ## >+## Autoconf initialization. ## >+## ------------------------ ## >+ >+# ac_fn_c_try_compile LINENO >+# -------------------------- >+# Try to compile conftest.$ac_ext, and return whether this succeeded. >+ac_fn_c_try_compile () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ rm -f conftest.$ac_objext >+ if { { ac_try="$ac_compile" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_compile") 2>conftest.err >+ ac_status=$? >+ if test -s conftest.err; then >+ grep -v '^ *+' conftest.err >conftest.er1 >+ cat conftest.er1 >&5 >+ mv -f conftest.er1 conftest.err >+ fi >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } && { >+ test -z "$ac_c_werror_flag" || >+ test ! -s conftest.err >+ } && test -s conftest.$ac_objext; then : >+ ac_retval=0 >+else >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+ ac_retval=1 >+fi >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ as_fn_set_status $ac_retval >+ >+} # ac_fn_c_try_compile >+ >+# ac_fn_c_try_cpp LINENO >+# ---------------------- >+# Try to preprocess conftest.$ac_ext, and return whether this succeeded. >+ac_fn_c_try_cpp () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ if { { ac_try="$ac_cpp conftest.$ac_ext" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err >+ ac_status=$? >+ if test -s conftest.err; then >+ grep -v '^ *+' conftest.err >conftest.er1 >+ cat conftest.er1 >&5 >+ mv -f conftest.er1 conftest.err >+ fi >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } > conftest.i && { >+ test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || >+ test ! -s conftest.err >+ }; then : >+ ac_retval=0 >+else >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+ ac_retval=1 >+fi >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ as_fn_set_status $ac_retval >+ >+} # ac_fn_c_try_cpp >+ >+# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES >+# ------------------------------------------------------- >+# Tests whether HEADER exists, giving a warning if it cannot be compiled using >+# the include files in INCLUDES and setting the cache variable VAR >+# accordingly. >+ac_fn_c_check_header_mongrel () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ if eval \${$3+:} false; then : >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+else >+ # Is the header compilable? >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 >+$as_echo_n "checking $2 usability... " >&6; } >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+$4 >+#include <$2> >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_header_compiler=yes >+else >+ ac_header_compiler=no >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 >+$as_echo "$ac_header_compiler" >&6; } >+ >+# Is the header present? >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 >+$as_echo_n "checking $2 presence... " >&6; } >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <$2> >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ ac_header_preproc=yes >+else >+ ac_header_preproc=no >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 >+$as_echo "$ac_header_preproc" >&6; } >+ >+# So? What about this header? >+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( >+ yes:no: ) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 >+$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 >+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} >+ ;; >+ no:yes:* ) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 >+$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 >+$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 >+$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 >+$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 >+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} >+( $as_echo "## --------------------------- ## >+## Report this to ris@ripe.net ## >+## --------------------------- ##" >+ ) | sed "s/^/$as_me: WARNING: /" >&2 >+ ;; >+esac >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ eval "$3=\$ac_header_compiler" >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+fi >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ >+} # ac_fn_c_check_header_mongrel >+ >+# ac_fn_c_try_run LINENO >+# ---------------------- >+# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes >+# that executables *can* be run. >+ac_fn_c_try_run () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ if { { ac_try="$ac_link" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' >+ { { case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_try") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; }; then : >+ ac_retval=0 >+else >+ $as_echo "$as_me: program exited with status $ac_status" >&5 >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+ ac_retval=$ac_status >+fi >+ rm -rf conftest.dSYM conftest_ipa8_conftest.oo >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ as_fn_set_status $ac_retval >+ >+} # ac_fn_c_try_run >+ >+# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES >+# ------------------------------------------------------- >+# Tests whether HEADER exists and can be compiled using the include files in >+# INCLUDES, setting the cache variable VAR accordingly. >+ac_fn_c_check_header_compile () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+$4 >+#include <$2> >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ eval "$3=yes" >+else >+ eval "$3=no" >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ >+} # ac_fn_c_check_header_compile >+ >+# ac_fn_c_check_type LINENO TYPE VAR INCLUDES >+# ------------------------------------------- >+# Tests whether TYPE exists after having included INCLUDES, setting cache >+# variable VAR accordingly. >+ac_fn_c_check_type () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ eval "$3=no" >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+$4 >+int >+main () >+{ >+if (sizeof ($2)) >+ return 0; >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+$4 >+int >+main () >+{ >+if (sizeof (($2))) >+ return 0; >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ >+else >+ eval "$3=yes" >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ >+} # ac_fn_c_check_type >+ >+# ac_fn_c_try_link LINENO >+# ----------------------- >+# Try to link conftest.$ac_ext, and return whether this succeeded. >+ac_fn_c_try_link () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ rm -f conftest.$ac_objext conftest$ac_exeext >+ if { { ac_try="$ac_link" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link") 2>conftest.err >+ ac_status=$? >+ if test -s conftest.err; then >+ grep -v '^ *+' conftest.err >conftest.er1 >+ cat conftest.er1 >&5 >+ mv -f conftest.er1 conftest.err >+ fi >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } && { >+ test -z "$ac_c_werror_flag" || >+ test ! -s conftest.err >+ } && test -s conftest$ac_exeext && { >+ test "$cross_compiling" = yes || >+ test -x conftest$ac_exeext >+ }; then : >+ ac_retval=0 >+else >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+ ac_retval=1 >+fi >+ # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information >+ # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would >+ # interfere with the next link command; also delete a directory that is >+ # left behind by Apple's compiler. We do this before executing the actions. >+ rm -rf conftest.dSYM conftest_ipa8_conftest.oo >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ as_fn_set_status $ac_retval >+ >+} # ac_fn_c_try_link >+ >+# ac_fn_c_check_func LINENO FUNC VAR >+# ---------------------------------- >+# Tests whether FUNC exists, setting the cache variable VAR accordingly >+ac_fn_c_check_func () >+{ >+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 >+$as_echo_n "checking for $2... " >&6; } >+if eval \${$3+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+/* Define $2 to an innocuous variant, in case <limits.h> declares $2. >+ For example, HP-UX 11i <limits.h> declares gettimeofday. */ >+#define $2 innocuous_$2 >+ >+/* System header to define __stub macros and hopefully few prototypes, >+ which can conflict with char $2 (); below. >+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since >+ <limits.h> exists even on freestanding compilers. */ >+ >+#ifdef __STDC__ >+# include <limits.h> >+#else >+# include <assert.h> >+#endif >+ >+#undef $2 >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char $2 (); >+/* The GNU C library defines this for functions which it implements >+ to always fail with ENOSYS. Some functions are actually named >+ something starting with __ and the normal name is an alias. */ >+#if defined __stub_$2 || defined __stub___$2 >+choke me >+#endif >+ >+int >+main () >+{ >+return $2 (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ eval "$3=yes" >+else >+ eval "$3=no" >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+fi >+eval ac_res=\$$3 >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 >+$as_echo "$ac_res" >&6; } >+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno >+ >+} # ac_fn_c_check_func >+cat >config.log <<_ACEOF >+This file contains any messages produced by compilers while >+running configure, to aid debugging if configure makes a mistake. >+ >+It was created by libbgpdump $as_me 1.4.99.15, which was >+generated by GNU Autoconf 2.69. Invocation command line was >+ >+ $ $0 $@ >+ >+_ACEOF >+exec 5>>config.log >+{ >+cat <<_ASUNAME >+## --------- ## >+## Platform. ## >+## --------- ## >+ >+hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` >+uname -m = `(uname -m) 2>/dev/null || echo unknown` >+uname -r = `(uname -r) 2>/dev/null || echo unknown` >+uname -s = `(uname -s) 2>/dev/null || echo unknown` >+uname -v = `(uname -v) 2>/dev/null || echo unknown` >+ >+/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` >+/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` >+ >+/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` >+/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` >+/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` >+/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` >+/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` >+/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` >+/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` >+ >+_ASUNAME >+ >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ $as_echo "PATH: $as_dir" >+ done >+IFS=$as_save_IFS >+ >+} >&5 >+ >+cat >&5 <<_ACEOF >+ >+ >+## ----------- ## >+## Core tests. ## >+## ----------- ## >+ >+_ACEOF >+ >+ >+# Keep a trace of the command line. >+# Strip out --no-create and --no-recursion so they do not pile up. >+# Strip out --silent because we don't want to record it for future runs. >+# Also quote any args containing shell meta-characters. >+# Make two passes to allow for proper duplicate-argument suppression. >+ac_configure_args= >+ac_configure_args0= >+ac_configure_args1= >+ac_must_keep_next=false >+for ac_pass in 1 2 >+do >+ for ac_arg >+ do >+ case $ac_arg in >+ -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; >+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \ >+ | -silent | --silent | --silen | --sile | --sil) >+ continue ;; >+ *\'*) >+ ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; >+ esac >+ case $ac_pass in >+ 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; >+ 2) >+ as_fn_append ac_configure_args1 " '$ac_arg'" >+ if test $ac_must_keep_next = true; then >+ ac_must_keep_next=false # Got value, back to normal. >+ else >+ case $ac_arg in >+ *=* | --config-cache | -C | -disable-* | --disable-* \ >+ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ >+ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ >+ | -with-* | --with-* | -without-* | --without-* | --x) >+ case "$ac_configure_args0 " in >+ "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; >+ esac >+ ;; >+ -* ) ac_must_keep_next=true ;; >+ esac >+ fi >+ as_fn_append ac_configure_args " '$ac_arg'" >+ ;; >+ esac >+ done >+done >+{ ac_configure_args0=; unset ac_configure_args0;} >+{ ac_configure_args1=; unset ac_configure_args1;} >+ >+# When interrupted or exit'd, cleanup temporary files, and complete >+# config.log. We remove comments because anyway the quotes in there >+# would cause problems or look ugly. >+# WARNING: Use '\'' to represent an apostrophe within the trap. >+# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. >+trap 'exit_status=$? >+ # Save into config.log some information that might help in debugging. >+ { >+ echo >+ >+ $as_echo "## ---------------- ## >+## Cache variables. ## >+## ---------------- ##" >+ echo >+ # The following way of writing the cache mishandles newlines in values, >+( >+ for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do >+ eval ac_val=\$$ac_var >+ case $ac_val in #( >+ *${as_nl}*) >+ case $ac_var in #( >+ *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 >+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; >+ esac >+ case $ac_var in #( >+ _ | IFS | as_nl) ;; #( >+ BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( >+ *) { eval $ac_var=; unset $ac_var;} ;; >+ esac ;; >+ esac >+ done >+ (set) 2>&1 | >+ case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( >+ *${as_nl}ac_space=\ *) >+ sed -n \ >+ "s/'\''/'\''\\\\'\'''\''/g; >+ s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" >+ ;; #( >+ *) >+ sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" >+ ;; >+ esac | >+ sort >+) >+ echo >+ >+ $as_echo "## ----------------- ## >+## Output variables. ## >+## ----------------- ##" >+ echo >+ for ac_var in $ac_subst_vars >+ do >+ eval ac_val=\$$ac_var >+ case $ac_val in >+ *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; >+ esac >+ $as_echo "$ac_var='\''$ac_val'\''" >+ done | sort >+ echo >+ >+ if test -n "$ac_subst_files"; then >+ $as_echo "## ------------------- ## >+## File substitutions. ## >+## ------------------- ##" >+ echo >+ for ac_var in $ac_subst_files >+ do >+ eval ac_val=\$$ac_var >+ case $ac_val in >+ *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; >+ esac >+ $as_echo "$ac_var='\''$ac_val'\''" >+ done | sort >+ echo >+ fi >+ >+ if test -s confdefs.h; then >+ $as_echo "## ----------- ## >+## confdefs.h. ## >+## ----------- ##" >+ echo >+ cat confdefs.h >+ echo >+ fi >+ test "$ac_signal" != 0 && >+ $as_echo "$as_me: caught signal $ac_signal" >+ $as_echo "$as_me: exit $exit_status" >+ } >&5 >+ rm -f core *.core core.conftest.* && >+ rm -f -r conftest* confdefs* conf$$* $ac_clean_files && >+ exit $exit_status >+' 0 >+for ac_signal in 1 2 13 15; do >+ trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal >+done >+ac_signal=0 >+ >+# confdefs.h avoids OS command line length limits that DEFS can exceed. >+rm -f -r conftest* confdefs.h >+ >+$as_echo "/* confdefs.h */" > confdefs.h >+ >+# Predefined preprocessor variables. >+ >+cat >>confdefs.h <<_ACEOF >+#define PACKAGE_NAME "$PACKAGE_NAME" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+#define PACKAGE_TARNAME "$PACKAGE_TARNAME" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+#define PACKAGE_VERSION "$PACKAGE_VERSION" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+#define PACKAGE_STRING "$PACKAGE_STRING" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" >+_ACEOF >+ >+cat >>confdefs.h <<_ACEOF >+#define PACKAGE_URL "$PACKAGE_URL" >+_ACEOF >+ >+ >+# Let the site file select an alternate cache file if it wants to. >+# Prefer an explicitly selected file to automatically selected ones. >+ac_site_file1=NONE >+ac_site_file2=NONE >+if test -n "$CONFIG_SITE"; then >+ # We do not want a PATH search for config.site. >+ case $CONFIG_SITE in #(( >+ -*) ac_site_file1=./$CONFIG_SITE;; >+ */*) ac_site_file1=$CONFIG_SITE;; >+ *) ac_site_file1=./$CONFIG_SITE;; >+ esac >+elif test "x$prefix" != xNONE; then >+ ac_site_file1=$prefix/share/config.site >+ ac_site_file2=$prefix/etc/config.site >+else >+ ac_site_file1=$ac_default_prefix/share/config.site >+ ac_site_file2=$ac_default_prefix/etc/config.site >+fi >+for ac_site_file in "$ac_site_file1" "$ac_site_file2" >+do >+ test "x$ac_site_file" = xNONE && continue >+ if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 >+$as_echo "$as_me: loading site script $ac_site_file" >&6;} >+ sed 's/^/| /' "$ac_site_file" >&5 >+ . "$ac_site_file" \ >+ || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "failed to load site script $ac_site_file >+See \`config.log' for more details" "$LINENO" 5; } >+ fi >+done >+ >+if test -r "$cache_file"; then >+ # Some versions of bash will fail to source /dev/null (special files >+ # actually), so we avoid doing that. DJGPP emulates it as a regular file. >+ if test /dev/null != "$cache_file" && test -f "$cache_file"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 >+$as_echo "$as_me: loading cache $cache_file" >&6;} >+ case $cache_file in >+ [\\/]* | ?:[\\/]* ) . "$cache_file";; >+ *) . "./$cache_file";; >+ esac >+ fi >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 >+$as_echo "$as_me: creating cache $cache_file" >&6;} >+ >$cache_file >+fi >+ >+# Check that the precious variables saved in the cache have kept the same >+# value. >+ac_cache_corrupted=false >+for ac_var in $ac_precious_vars; do >+ eval ac_old_set=\$ac_cv_env_${ac_var}_set >+ eval ac_new_set=\$ac_env_${ac_var}_set >+ eval ac_old_val=\$ac_cv_env_${ac_var}_value >+ eval ac_new_val=\$ac_env_${ac_var}_value >+ case $ac_old_set,$ac_new_set in >+ set,) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 >+$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} >+ ac_cache_corrupted=: ;; >+ ,set) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 >+$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} >+ ac_cache_corrupted=: ;; >+ ,);; >+ *) >+ if test "x$ac_old_val" != "x$ac_new_val"; then >+ # differences in whitespace do not lead to failure. >+ ac_old_val_w=`echo x $ac_old_val` >+ ac_new_val_w=`echo x $ac_new_val` >+ if test "$ac_old_val_w" != "$ac_new_val_w"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 >+$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} >+ ac_cache_corrupted=: >+ else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 >+$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} >+ eval $ac_var=\$ac_old_val >+ fi >+ { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 >+$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 >+$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} >+ fi;; >+ esac >+ # Pass precious variables to config.status. >+ if test "$ac_new_set" = set; then >+ case $ac_new_val in >+ *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; >+ *) ac_arg=$ac_var=$ac_new_val ;; >+ esac >+ case " $ac_configure_args " in >+ *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. >+ *) as_fn_append ac_configure_args " '$ac_arg'" ;; >+ esac >+ fi >+done >+if $ac_cache_corrupted; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+ { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 >+$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} >+ as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 >+fi >+## -------------------- ## >+## Main body of script. ## >+## -------------------- ## >+ >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+ >+ >+ >+ac_config_headers="$ac_config_headers bgpdump-config.h" >+ >+ >+CFLAGS="-g -O3 $CFLAGS -Wall" >+CFLAGS="$CFLAGS -Wsystem-headers -Wno-format-y2k -Wno-sign-compare -Wcast-align" >+CFLAGS="$CFLAGS -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wswitch -Wshadow" >+ >+# Checks for programs. >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+if test -n "$ac_tool_prefix"; then >+ # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. >+set dummy ${ac_tool_prefix}gcc; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$CC"; then >+ ac_cv_prog_CC="$CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_CC="${ac_tool_prefix}gcc" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+CC=$ac_cv_prog_CC >+if test -n "$CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 >+$as_echo "$CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+fi >+if test -z "$ac_cv_prog_CC"; then >+ ac_ct_CC=$CC >+ # Extract the first word of "gcc", so it can be a program name with args. >+set dummy gcc; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_ac_ct_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$ac_ct_CC"; then >+ ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_ac_ct_CC="gcc" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+ac_ct_CC=$ac_cv_prog_ac_ct_CC >+if test -n "$ac_ct_CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 >+$as_echo "$ac_ct_CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ if test "x$ac_ct_CC" = x; then >+ CC="" >+ else >+ case $cross_compiling:$ac_tool_warned in >+yes:) >+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 >+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} >+ac_tool_warned=yes ;; >+esac >+ CC=$ac_ct_CC >+ fi >+else >+ CC="$ac_cv_prog_CC" >+fi >+ >+if test -z "$CC"; then >+ if test -n "$ac_tool_prefix"; then >+ # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. >+set dummy ${ac_tool_prefix}cc; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$CC"; then >+ ac_cv_prog_CC="$CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_CC="${ac_tool_prefix}cc" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+CC=$ac_cv_prog_CC >+if test -n "$CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 >+$as_echo "$CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+ fi >+fi >+if test -z "$CC"; then >+ # Extract the first word of "cc", so it can be a program name with args. >+set dummy cc; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$CC"; then >+ ac_cv_prog_CC="$CC" # Let the user override the test. >+else >+ ac_prog_rejected=no >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then >+ ac_prog_rejected=yes >+ continue >+ fi >+ ac_cv_prog_CC="cc" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+if test $ac_prog_rejected = yes; then >+ # We found a bogon in the path, so make sure we never use it. >+ set dummy $ac_cv_prog_CC >+ shift >+ if test $# != 0; then >+ # We chose a different compiler from the bogus one. >+ # However, it has the same basename, so the bogon will be chosen >+ # first if we set CC to just the basename; use the full file name. >+ shift >+ ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" >+ fi >+fi >+fi >+fi >+CC=$ac_cv_prog_CC >+if test -n "$CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 >+$as_echo "$CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+fi >+if test -z "$CC"; then >+ if test -n "$ac_tool_prefix"; then >+ for ac_prog in cl.exe >+ do >+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. >+set dummy $ac_tool_prefix$ac_prog; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$CC"; then >+ ac_cv_prog_CC="$CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_CC="$ac_tool_prefix$ac_prog" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+CC=$ac_cv_prog_CC >+if test -n "$CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 >+$as_echo "$CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+ test -n "$CC" && break >+ done >+fi >+if test -z "$CC"; then >+ ac_ct_CC=$CC >+ for ac_prog in cl.exe >+do >+ # Extract the first word of "$ac_prog", so it can be a program name with args. >+set dummy $ac_prog; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_ac_ct_CC+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$ac_ct_CC"; then >+ ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_ac_ct_CC="$ac_prog" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+ac_ct_CC=$ac_cv_prog_ac_ct_CC >+if test -n "$ac_ct_CC"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 >+$as_echo "$ac_ct_CC" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+ test -n "$ac_ct_CC" && break >+done >+ >+ if test "x$ac_ct_CC" = x; then >+ CC="" >+ else >+ case $cross_compiling:$ac_tool_warned in >+yes:) >+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 >+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} >+ac_tool_warned=yes ;; >+esac >+ CC=$ac_ct_CC >+ fi >+fi >+ >+fi >+ >+ >+test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "no acceptable C compiler found in \$PATH >+See \`config.log' for more details" "$LINENO" 5; } >+ >+# Provide some information about the compiler. >+$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 >+set X $ac_compile >+ac_compiler=$2 >+for ac_option in --version -v -V -qversion; do >+ { { ac_try="$ac_compiler $ac_option >&5" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_compiler $ac_option >&5") 2>conftest.err >+ ac_status=$? >+ if test -s conftest.err; then >+ sed '10a\ >+... rest of stderr output deleted ... >+ 10q' conftest.err >conftest.er1 >+ cat conftest.er1 >&5 >+ fi >+ rm -f conftest.er1 conftest.err >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } >+done >+ >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+ac_clean_files_save=$ac_clean_files >+ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" >+# Try to create an executable without -o first, disregard a.out. >+# It will help us diagnose broken compilers, and finding out an intuition >+# of exeext. >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 >+$as_echo_n "checking whether the C compiler works... " >&6; } >+ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` >+ >+# The possible output files: >+ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" >+ >+ac_rmfiles= >+for ac_file in $ac_files >+do >+ case $ac_file in >+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; >+ * ) ac_rmfiles="$ac_rmfiles $ac_file";; >+ esac >+done >+rm -f $ac_rmfiles >+ >+if { { ac_try="$ac_link_default" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link_default") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; then : >+ # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. >+# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' >+# in a Makefile. We should not override ac_cv_exeext if it was cached, >+# so that the user can short-circuit this test for compilers unknown to >+# Autoconf. >+for ac_file in $ac_files '' >+do >+ test -f "$ac_file" || continue >+ case $ac_file in >+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) >+ ;; >+ [ab].out ) >+ # We found the default executable, but exeext='' is most >+ # certainly right. >+ break;; >+ *.* ) >+ if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; >+ then :; else >+ ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` >+ fi >+ # We set ac_cv_exeext here because the later test for it is not >+ # safe: cross compilers may not add the suffix if given an `-o' >+ # argument, so we may need to know it at that point already. >+ # Even if this section looks crufty: it has the advantage of >+ # actually working. >+ break;; >+ * ) >+ break;; >+ esac >+done >+test "$ac_cv_exeext" = no && ac_cv_exeext= >+ >+else >+ ac_file='' >+fi >+if test -z "$ac_file"; then : >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+$as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error 77 "C compiler cannot create executables >+See \`config.log' for more details" "$LINENO" 5; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 >+$as_echo "yes" >&6; } >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 >+$as_echo_n "checking for C compiler default output file name... " >&6; } >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 >+$as_echo "$ac_file" >&6; } >+ac_exeext=$ac_cv_exeext >+ >+rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out >+ac_clean_files=$ac_clean_files_save >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 >+$as_echo_n "checking for suffix of executables... " >&6; } >+if { { ac_try="$ac_link" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; then : >+ # If both `conftest.exe' and `conftest' are `present' (well, observable) >+# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will >+# work properly (i.e., refer to `conftest.exe'), while it won't with >+# `rm'. >+for ac_file in conftest.exe conftest conftest.*; do >+ test -f "$ac_file" || continue >+ case $ac_file in >+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; >+ *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` >+ break;; >+ * ) break;; >+ esac >+done >+else >+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "cannot compute suffix of executables: cannot compile and link >+See \`config.log' for more details" "$LINENO" 5; } >+fi >+rm -f conftest conftest$ac_cv_exeext >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 >+$as_echo "$ac_cv_exeext" >&6; } >+ >+rm -f conftest.$ac_ext >+EXEEXT=$ac_cv_exeext >+ac_exeext=$EXEEXT >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <stdio.h> >+int >+main () >+{ >+FILE *f = fopen ("conftest.out", "w"); >+ return ferror (f) || fclose (f) != 0; >+ >+ ; >+ return 0; >+} >+_ACEOF >+ac_clean_files="$ac_clean_files conftest.out" >+# Check that the compiler produces executables we can run. If not, either >+# the compiler is broken, or we cross compile. >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 >+$as_echo_n "checking whether we are cross compiling... " >&6; } >+if test "$cross_compiling" != yes; then >+ { { ac_try="$ac_link" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_link") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; } >+ if { ac_try='./conftest$ac_cv_exeext' >+ { { case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_try") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; }; then >+ cross_compiling=no >+ else >+ if test "$cross_compiling" = maybe; then >+ cross_compiling=yes >+ else >+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "cannot run C compiled programs. >+If you meant to cross compile, use \`--host'. >+See \`config.log' for more details" "$LINENO" 5; } >+ fi >+ fi >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 >+$as_echo "$cross_compiling" >&6; } >+ >+rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out >+ac_clean_files=$ac_clean_files_save >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 >+$as_echo_n "checking for suffix of object files... " >&6; } >+if ${ac_cv_objext+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+rm -f conftest.o conftest.obj >+if { { ac_try="$ac_compile" >+case "(($ac_try" in >+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; >+ *) ac_try_echo=$ac_try;; >+esac >+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" >+$as_echo "$ac_try_echo"; } >&5 >+ (eval "$ac_compile") 2>&5 >+ ac_status=$? >+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 >+ test $ac_status = 0; }; then : >+ for ac_file in conftest.o conftest.obj conftest.*; do >+ test -f "$ac_file" || continue; >+ case $ac_file in >+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; >+ *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` >+ break;; >+ esac >+done >+else >+ $as_echo "$as_me: failed program was:" >&5 >+sed 's/^/| /' conftest.$ac_ext >&5 >+ >+{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "cannot compute suffix of object files: cannot compile >+See \`config.log' for more details" "$LINENO" 5; } >+fi >+rm -f conftest.$ac_cv_objext conftest.$ac_ext >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 >+$as_echo "$ac_cv_objext" >&6; } >+OBJEXT=$ac_cv_objext >+ac_objext=$OBJEXT >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 >+$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } >+if ${ac_cv_c_compiler_gnu+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+#ifndef __GNUC__ >+ choke me >+#endif >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_compiler_gnu=yes >+else >+ ac_compiler_gnu=no >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+ac_cv_c_compiler_gnu=$ac_compiler_gnu >+ >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 >+$as_echo "$ac_cv_c_compiler_gnu" >&6; } >+if test $ac_compiler_gnu = yes; then >+ GCC=yes >+else >+ GCC= >+fi >+ac_test_CFLAGS=${CFLAGS+set} >+ac_save_CFLAGS=$CFLAGS >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 >+$as_echo_n "checking whether $CC accepts -g... " >&6; } >+if ${ac_cv_prog_cc_g+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_save_c_werror_flag=$ac_c_werror_flag >+ ac_c_werror_flag=yes >+ ac_cv_prog_cc_g=no >+ CFLAGS="-g" >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_prog_cc_g=yes >+else >+ CFLAGS="" >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ >+else >+ ac_c_werror_flag=$ac_save_c_werror_flag >+ CFLAGS="-g" >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_prog_cc_g=yes >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+ ac_c_werror_flag=$ac_save_c_werror_flag >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 >+$as_echo "$ac_cv_prog_cc_g" >&6; } >+if test "$ac_test_CFLAGS" = set; then >+ CFLAGS=$ac_save_CFLAGS >+elif test $ac_cv_prog_cc_g = yes; then >+ if test "$GCC" = yes; then >+ CFLAGS="-g -O2" >+ else >+ CFLAGS="-g" >+ fi >+else >+ if test "$GCC" = yes; then >+ CFLAGS="-O2" >+ else >+ CFLAGS= >+ fi >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 >+$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } >+if ${ac_cv_prog_cc_c89+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_cv_prog_cc_c89=no >+ac_save_CC=$CC >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <stdarg.h> >+#include <stdio.h> >+struct stat; >+/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ >+struct buf { int x; }; >+FILE * (*rcsopen) (struct buf *, struct stat *, int); >+static char *e (p, i) >+ char **p; >+ int i; >+{ >+ return p[i]; >+} >+static char *f (char * (*g) (char **, int), char **p, ...) >+{ >+ char *s; >+ va_list v; >+ va_start (v,p); >+ s = g (p, va_arg (v,int)); >+ va_end (v); >+ return s; >+} >+ >+/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has >+ function prototypes and stuff, but not '\xHH' hex character constants. >+ These don't provoke an error unfortunately, instead are silently treated >+ as 'x'. The following induces an error, until -std is added to get >+ proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an >+ array size at least. It's necessary to write '\x00'==0 to get something >+ that's true only with -std. */ >+int osf4_cc_array ['\x00' == 0 ? 1 : -1]; >+ >+/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters >+ inside strings and character constants. */ >+#define FOO(x) 'x' >+int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; >+ >+int test (int i, double x); >+struct s1 {int (*f) (int a);}; >+struct s2 {int (*f) (double a);}; >+int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); >+int argc; >+char **argv; >+int >+main () >+{ >+return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; >+ ; >+ return 0; >+} >+_ACEOF >+for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ >+ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" >+do >+ CC="$ac_save_CC $ac_arg" >+ if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_prog_cc_c89=$ac_arg >+fi >+rm -f core conftest.err conftest.$ac_objext >+ test "x$ac_cv_prog_cc_c89" != "xno" && break >+done >+rm -f conftest.$ac_ext >+CC=$ac_save_CC >+ >+fi >+# AC_CACHE_VAL >+case "x$ac_cv_prog_cc_c89" in >+ x) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 >+$as_echo "none needed" >&6; } ;; >+ xno) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 >+$as_echo "unsupported" >&6; } ;; >+ *) >+ CC="$CC $ac_cv_prog_cc_c89" >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 >+$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; >+esac >+if test "x$ac_cv_prog_cc_c89" != xno; then : >+ >+fi >+ >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+ >+if test -n "$ac_tool_prefix"; then >+ # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. >+set dummy ${ac_tool_prefix}ranlib; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_RANLIB+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$RANLIB"; then >+ ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+RANLIB=$ac_cv_prog_RANLIB >+if test -n "$RANLIB"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 >+$as_echo "$RANLIB" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ >+fi >+if test -z "$ac_cv_prog_RANLIB"; then >+ ac_ct_RANLIB=$RANLIB >+ # Extract the first word of "ranlib", so it can be a program name with args. >+set dummy ranlib; ac_word=$2 >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 >+$as_echo_n "checking for $ac_word... " >&6; } >+if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -n "$ac_ct_RANLIB"; then >+ ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. >+else >+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then >+ ac_cv_prog_ac_ct_RANLIB="ranlib" >+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 >+ break 2 >+ fi >+done >+ done >+IFS=$as_save_IFS >+ >+fi >+fi >+ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB >+if test -n "$ac_ct_RANLIB"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 >+$as_echo "$ac_ct_RANLIB" >&6; } >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 >+$as_echo "no" >&6; } >+fi >+ >+ if test "x$ac_ct_RANLIB" = x; then >+ RANLIB=":" >+ else >+ case $cross_compiling:$ac_tool_warned in >+yes:) >+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 >+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} >+ac_tool_warned=yes ;; >+esac >+ RANLIB=$ac_ct_RANLIB >+ fi >+else >+ RANLIB="$ac_cv_prog_RANLIB" >+fi >+ >+ >+# Checks for header files. >+ >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 >+$as_echo_n "checking how to run the C preprocessor... " >&6; } >+# On Suns, sometimes $CPP names a directory. >+if test -n "$CPP" && test -d "$CPP"; then >+ CPP= >+fi >+if test -z "$CPP"; then >+ if ${ac_cv_prog_CPP+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ # Double quotes because CPP needs to be expanded >+ for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" >+ do >+ ac_preproc_ok=false >+for ac_c_preproc_warn_flag in '' yes >+do >+ # Use a header file that comes with gcc, so configuring glibc >+ # with a fresh cross-compiler works. >+ # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since >+ # <limits.h> exists even on freestanding compilers. >+ # On the NeXT, cc -E runs the code through the compiler's parser, >+ # not just through cpp. "Syntax error" is here to catch this case. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#ifdef __STDC__ >+# include <limits.h> >+#else >+# include <assert.h> >+#endif >+ Syntax error >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ >+else >+ # Broken: fails on valid input. >+continue >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+ >+ # OK, works on sane cases. Now check whether nonexistent headers >+ # can be detected and how. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <ac_nonexistent.h> >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ # Broken: success on invalid input. >+continue >+else >+ # Passes both tests. >+ac_preproc_ok=: >+break >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+ >+done >+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. >+rm -f conftest.i conftest.err conftest.$ac_ext >+if $ac_preproc_ok; then : >+ break >+fi >+ >+ done >+ ac_cv_prog_CPP=$CPP >+ >+fi >+ CPP=$ac_cv_prog_CPP >+else >+ ac_cv_prog_CPP=$CPP >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 >+$as_echo "$CPP" >&6; } >+ac_preproc_ok=false >+for ac_c_preproc_warn_flag in '' yes >+do >+ # Use a header file that comes with gcc, so configuring glibc >+ # with a fresh cross-compiler works. >+ # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since >+ # <limits.h> exists even on freestanding compilers. >+ # On the NeXT, cc -E runs the code through the compiler's parser, >+ # not just through cpp. "Syntax error" is here to catch this case. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#ifdef __STDC__ >+# include <limits.h> >+#else >+# include <assert.h> >+#endif >+ Syntax error >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ >+else >+ # Broken: fails on valid input. >+continue >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+ >+ # OK, works on sane cases. Now check whether nonexistent headers >+ # can be detected and how. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <ac_nonexistent.h> >+_ACEOF >+if ac_fn_c_try_cpp "$LINENO"; then : >+ # Broken: success on invalid input. >+continue >+else >+ # Passes both tests. >+ac_preproc_ok=: >+break >+fi >+rm -f conftest.err conftest.i conftest.$ac_ext >+ >+done >+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. >+rm -f conftest.i conftest.err conftest.$ac_ext >+if $ac_preproc_ok; then : >+ >+else >+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 >+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} >+as_fn_error $? "C preprocessor \"$CPP\" fails sanity check >+See \`config.log' for more details" "$LINENO" 5; } >+fi >+ >+ac_ext=c >+ac_cpp='$CPP $CPPFLAGS' >+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' >+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' >+ac_compiler_gnu=$ac_cv_c_compiler_gnu >+ >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 >+$as_echo_n "checking for grep that handles long lines and -e... " >&6; } >+if ${ac_cv_path_GREP+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if test -z "$GREP"; then >+ ac_path_GREP_found=false >+ # Loop through the user's path and test for each of PROGNAME-LIST >+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_prog in grep ggrep; do >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" >+ as_fn_executable_p "$ac_path_GREP" || continue >+# Check for GNU ac_path_GREP and select it if it is found. >+ # Check for GNU $ac_path_GREP >+case `"$ac_path_GREP" --version 2>&1` in >+*GNU*) >+ ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; >+*) >+ ac_count=0 >+ $as_echo_n 0123456789 >"conftest.in" >+ while : >+ do >+ cat "conftest.in" "conftest.in" >"conftest.tmp" >+ mv "conftest.tmp" "conftest.in" >+ cp "conftest.in" "conftest.nl" >+ $as_echo 'GREP' >> "conftest.nl" >+ "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break >+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break >+ as_fn_arith $ac_count + 1 && ac_count=$as_val >+ if test $ac_count -gt ${ac_path_GREP_max-0}; then >+ # Best one so far, save it but keep looking for a better one >+ ac_cv_path_GREP="$ac_path_GREP" >+ ac_path_GREP_max=$ac_count >+ fi >+ # 10*(2^10) chars as input seems more than enough >+ test $ac_count -gt 10 && break >+ done >+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;; >+esac >+ >+ $ac_path_GREP_found && break 3 >+ done >+ done >+ done >+IFS=$as_save_IFS >+ if test -z "$ac_cv_path_GREP"; then >+ as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 >+ fi >+else >+ ac_cv_path_GREP=$GREP >+fi >+ >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 >+$as_echo "$ac_cv_path_GREP" >&6; } >+ GREP="$ac_cv_path_GREP" >+ >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 >+$as_echo_n "checking for egrep... " >&6; } >+if ${ac_cv_path_EGREP+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 >+ then ac_cv_path_EGREP="$GREP -E" >+ else >+ if test -z "$EGREP"; then >+ ac_path_EGREP_found=false >+ # Loop through the user's path and test for each of PROGNAME-LIST >+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ for ac_prog in egrep; do >+ for ac_exec_ext in '' $ac_executable_extensions; do >+ ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" >+ as_fn_executable_p "$ac_path_EGREP" || continue >+# Check for GNU ac_path_EGREP and select it if it is found. >+ # Check for GNU $ac_path_EGREP >+case `"$ac_path_EGREP" --version 2>&1` in >+*GNU*) >+ ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; >+*) >+ ac_count=0 >+ $as_echo_n 0123456789 >"conftest.in" >+ while : >+ do >+ cat "conftest.in" "conftest.in" >"conftest.tmp" >+ mv "conftest.tmp" "conftest.in" >+ cp "conftest.in" "conftest.nl" >+ $as_echo 'EGREP' >> "conftest.nl" >+ "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break >+ diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break >+ as_fn_arith $ac_count + 1 && ac_count=$as_val >+ if test $ac_count -gt ${ac_path_EGREP_max-0}; then >+ # Best one so far, save it but keep looking for a better one >+ ac_cv_path_EGREP="$ac_path_EGREP" >+ ac_path_EGREP_max=$ac_count >+ fi >+ # 10*(2^10) chars as input seems more than enough >+ test $ac_count -gt 10 && break >+ done >+ rm -f conftest.in conftest.tmp conftest.nl conftest.out;; >+esac >+ >+ $ac_path_EGREP_found && break 3 >+ done >+ done >+ done >+IFS=$as_save_IFS >+ if test -z "$ac_cv_path_EGREP"; then >+ as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 >+ fi >+else >+ ac_cv_path_EGREP=$EGREP >+fi >+ >+ fi >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 >+$as_echo "$ac_cv_path_EGREP" >&6; } >+ EGREP="$ac_cv_path_EGREP" >+ >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 >+$as_echo_n "checking for ANSI C header files... " >&6; } >+if ${ac_cv_header_stdc+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <stdlib.h> >+#include <stdarg.h> >+#include <string.h> >+#include <float.h> >+ >+int >+main () >+{ >+ >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_header_stdc=yes >+else >+ ac_cv_header_stdc=no >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+ >+if test $ac_cv_header_stdc = yes; then >+ # SunOS 4.x string.h does not declare mem*, contrary to ANSI. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <string.h> >+ >+_ACEOF >+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | >+ $EGREP "memchr" >/dev/null 2>&1; then : >+ >+else >+ ac_cv_header_stdc=no >+fi >+rm -f conftest* >+ >+fi >+ >+if test $ac_cv_header_stdc = yes; then >+ # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <stdlib.h> >+ >+_ACEOF >+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | >+ $EGREP "free" >/dev/null 2>&1; then : >+ >+else >+ ac_cv_header_stdc=no >+fi >+rm -f conftest* >+ >+fi >+ >+if test $ac_cv_header_stdc = yes; then >+ # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. >+ if test "$cross_compiling" = yes; then : >+ : >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <ctype.h> >+#include <stdlib.h> >+#if ((' ' & 0x0FF) == 0x020) >+# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') >+# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) >+#else >+# define ISLOWER(c) \ >+ (('a' <= (c) && (c) <= 'i') \ >+ || ('j' <= (c) && (c) <= 'r') \ >+ || ('s' <= (c) && (c) <= 'z')) >+# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) >+#endif >+ >+#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) >+int >+main () >+{ >+ int i; >+ for (i = 0; i < 256; i++) >+ if (XOR (islower (i), ISLOWER (i)) >+ || toupper (i) != TOUPPER (i)) >+ return 2; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_run "$LINENO"; then : >+ >+else >+ ac_cv_header_stdc=no >+fi >+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ >+ conftest.$ac_objext conftest.beam conftest.$ac_ext >+fi >+ >+fi >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 >+$as_echo "$ac_cv_header_stdc" >&6; } >+if test $ac_cv_header_stdc = yes; then >+ >+$as_echo "#define STDC_HEADERS 1" >>confdefs.h >+ >+fi >+ >+# On IRIX 5.3, sys/types and inttypes.h are conflicting. >+for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ >+ inttypes.h stdint.h unistd.h >+do : >+ as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` >+ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default >+" >+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : >+ cat >>confdefs.h <<_ACEOF >+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 >+_ACEOF >+ >+fi >+ >+done >+ >+ >+for ac_header in arpa/inet.h netinet/in.h syslog.h >+do : >+ as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` >+ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" >+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : >+ cat >>confdefs.h <<_ACEOF >+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 >+_ACEOF >+ >+fi >+ >+done >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 >+$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } >+if ${ac_cv_struct_tm+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+#include <sys/types.h> >+#include <time.h> >+ >+int >+main () >+{ >+struct tm tm; >+ int *p = &tm.tm_sec; >+ return !p; >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_compile "$LINENO"; then : >+ ac_cv_struct_tm=time.h >+else >+ ac_cv_struct_tm=sys/time.h >+fi >+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 >+$as_echo "$ac_cv_struct_tm" >&6; } >+if test $ac_cv_struct_tm = sys/time.h; then >+ >+$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h >+ >+fi >+ >+ >+# Check for u_*_t >+ac_fn_c_check_type "$LINENO" "u_char_t" "ac_cv_type_u_char_t" "$ac_includes_default" >+if test "x$ac_cv_type_u_char_t" = xyes; then : >+ >+else >+ >+$as_echo "#define u_char_t uchar_t" >>confdefs.h >+ >+fi >+ >+ac_fn_c_check_type "$LINENO" "u_int8_t" "ac_cv_type_u_int8_t" "$ac_includes_default" >+if test "x$ac_cv_type_u_int8_t" = xyes; then : >+ >+else >+ >+$as_echo "#define u_int8_t uint8_t" >>confdefs.h >+ >+fi >+ >+ac_fn_c_check_type "$LINENO" "u_int16_t" "ac_cv_type_u_int16_t" "$ac_includes_default" >+if test "x$ac_cv_type_u_int16_t" = xyes; then : >+ >+else >+ >+$as_echo "#define u_int16_t uint16_t" >>confdefs.h >+ >+fi >+ >+ac_fn_c_check_type "$LINENO" "u_int32_t" "ac_cv_type_u_int32_t" "$ac_includes_default" >+if test "x$ac_cv_type_u_int32_t" = xyes; then : >+ >+else >+ >+$as_echo "#define u_int32_t uint32_t" >>confdefs.h >+ >+fi >+ >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gzopen in -lz" >&5 >+$as_echo_n "checking for gzopen in -lz... " >&6; } >+if ${ac_cv_lib_z_gzopen+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_check_lib_save_LIBS=$LIBS >+LIBS="-lz $LIBS" >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char gzopen (); >+int >+main () >+{ >+return gzopen (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ ac_cv_lib_z_gzopen=yes >+else >+ ac_cv_lib_z_gzopen=no >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+LIBS=$ac_check_lib_save_LIBS >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_gzopen" >&5 >+$as_echo "$ac_cv_lib_z_gzopen" >&6; } >+if test "x$ac_cv_lib_z_gzopen" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+#define HAVE_LIBZ 1 >+_ACEOF >+ >+ LIBS="-lz $LIBS" >+ >+else >+ >+$as_echo "#define DONT_HAVE_GZ 1" >>confdefs.h >+ >+fi >+ >+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BZ2_bzReadOpen in -lbz2" >&5 >+$as_echo_n "checking for BZ2_bzReadOpen in -lbz2... " >&6; } >+if ${ac_cv_lib_bz2_BZ2_bzReadOpen+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_check_lib_save_LIBS=$LIBS >+LIBS="-lbz2 $LIBS" >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char BZ2_bzReadOpen (); >+int >+main () >+{ >+return BZ2_bzReadOpen (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ ac_cv_lib_bz2_BZ2_bzReadOpen=yes >+else >+ ac_cv_lib_bz2_BZ2_bzReadOpen=no >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+LIBS=$ac_check_lib_save_LIBS >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bz2_BZ2_bzReadOpen" >&5 >+$as_echo "$ac_cv_lib_bz2_BZ2_bzReadOpen" >&6; } >+if test "x$ac_cv_lib_bz2_BZ2_bzReadOpen" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+#define HAVE_LIBBZ2 1 >+_ACEOF >+ >+ LIBS="-lbz2 $LIBS" >+ >+else >+ >+$as_echo "#define DONT_HAVE_BZ2 1" >>confdefs.h >+ >+fi >+ >+ >+# Check for inet_ntoa in -lnsl if not found (Solaris) >+for ac_func in inet_ntoa >+do : >+ ac_fn_c_check_func "$LINENO" "inet_ntoa" "ac_cv_func_inet_ntoa" >+if test "x$ac_cv_func_inet_ntoa" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+#define HAVE_INET_NTOA 1 >+_ACEOF >+ >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_ntoa in -lnsl" >&5 >+$as_echo_n "checking for inet_ntoa in -lnsl... " >&6; } >+if ${ac_cv_lib_nsl_inet_ntoa+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_check_lib_save_LIBS=$LIBS >+LIBS="-lnsl $LIBS" >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char inet_ntoa (); >+int >+main () >+{ >+return inet_ntoa (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ ac_cv_lib_nsl_inet_ntoa=yes >+else >+ ac_cv_lib_nsl_inet_ntoa=no >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+LIBS=$ac_check_lib_save_LIBS >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_inet_ntoa" >&5 >+$as_echo "$ac_cv_lib_nsl_inet_ntoa" >&6; } >+if test "x$ac_cv_lib_nsl_inet_ntoa" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+#define HAVE_LIBNSL 1 >+_ACEOF >+ >+ LIBS="-lnsl $LIBS" >+ >+else >+ as_fn_error 1 "inet_ntoa not found" "$LINENO" 5 >+fi >+ >+fi >+done >+ >+for ac_func in inet_ntop >+do : >+ ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" >+if test "x$ac_cv_func_inet_ntop" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+#define HAVE_INET_NTOP 1 >+_ACEOF >+ >+else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_ntop in -lnsl" >&5 >+$as_echo_n "checking for inet_ntop in -lnsl... " >&6; } >+if ${ac_cv_lib_nsl_inet_ntop+:} false; then : >+ $as_echo_n "(cached) " >&6 >+else >+ ac_check_lib_save_LIBS=$LIBS >+LIBS="-lnsl $LIBS" >+cat confdefs.h - <<_ACEOF >conftest.$ac_ext >+/* end confdefs.h. */ >+ >+/* Override any GCC internal prototype to avoid an error. >+ Use char because int might match the return type of a GCC >+ builtin and then its argument prototype would still apply. */ >+#ifdef __cplusplus >+extern "C" >+#endif >+char inet_ntop (); >+int >+main () >+{ >+return inet_ntop (); >+ ; >+ return 0; >+} >+_ACEOF >+if ac_fn_c_try_link "$LINENO"; then : >+ ac_cv_lib_nsl_inet_ntop=yes >+else >+ ac_cv_lib_nsl_inet_ntop=no >+fi >+rm -f core conftest.err conftest.$ac_objext \ >+ conftest$ac_exeext conftest.$ac_ext >+LIBS=$ac_check_lib_save_LIBS >+fi >+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_inet_ntop" >&5 >+$as_echo "$ac_cv_lib_nsl_inet_ntop" >&6; } >+if test "x$ac_cv_lib_nsl_inet_ntop" = xyes; then : >+ cat >>confdefs.h <<_ACEOF >+#define HAVE_LIBNSL 1 >+_ACEOF >+ >+ LIBS="-lnsl $LIBS" >+ >+else >+ as_fn_error 1 "inet_ntop not found" "$LINENO" 5 >+fi >+ >+fi >+done >+ >+ >+case `uname` in >+ Darwin*) LDFLAGS="$LDFLAGS -dynamiclib" ;; >+ *) LDFLAGS="$LDFLAGS -shared" ;; >+esac >+ >+ >+ >+ >+ac_config_files="$ac_config_files bgpdump.spec Makefile" >+ >+cat >confcache <<\_ACEOF >+# This file is a shell script that caches the results of configure >+# tests run on this system so they can be shared between configure >+# scripts and configure runs, see configure's option --config-cache. >+# It is not useful on other systems. If it contains results you don't >+# want to keep, you may remove or edit it. >+# >+# config.status only pays attention to the cache file if you give it >+# the --recheck option to rerun configure. >+# >+# `ac_cv_env_foo' variables (set or unset) will be overridden when >+# loading this file, other *unset* `ac_cv_foo' will be assigned the >+# following values. >+ >+_ACEOF >+ >+# The following way of writing the cache mishandles newlines in values, >+# but we know of no workaround that is simple, portable, and efficient. >+# So, we kill variables containing newlines. >+# Ultrix sh set writes to stderr and can't be redirected directly, >+# and sets the high bit in the cache file unless we assign to the vars. >+( >+ for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do >+ eval ac_val=\$$ac_var >+ case $ac_val in #( >+ *${as_nl}*) >+ case $ac_var in #( >+ *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 >+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; >+ esac >+ case $ac_var in #( >+ _ | IFS | as_nl) ;; #( >+ BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( >+ *) { eval $ac_var=; unset $ac_var;} ;; >+ esac ;; >+ esac >+ done >+ >+ (set) 2>&1 | >+ case $as_nl`(ac_space=' '; set) 2>&1` in #( >+ *${as_nl}ac_space=\ *) >+ # `set' does not quote correctly, so add quotes: double-quote >+ # substitution turns \\\\ into \\, and sed turns \\ into \. >+ sed -n \ >+ "s/'/'\\\\''/g; >+ s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" >+ ;; #( >+ *) >+ # `set' quotes correctly as required by POSIX, so do not add quotes. >+ sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" >+ ;; >+ esac | >+ sort >+) | >+ sed ' >+ /^ac_cv_env_/b end >+ t clear >+ :clear >+ s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ >+ t end >+ s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ >+ :end' >>confcache >+if diff "$cache_file" confcache >/dev/null 2>&1; then :; else >+ if test -w "$cache_file"; then >+ if test "x$cache_file" != "x/dev/null"; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 >+$as_echo "$as_me: updating cache $cache_file" >&6;} >+ if test ! -f "$cache_file" || test -h "$cache_file"; then >+ cat confcache >"$cache_file" >+ else >+ case $cache_file in #( >+ */* | ?:*) >+ mv -f confcache "$cache_file"$$ && >+ mv -f "$cache_file"$$ "$cache_file" ;; #( >+ *) >+ mv -f confcache "$cache_file" ;; >+ esac >+ fi >+ fi >+ else >+ { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 >+$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} >+ fi >+fi >+rm -f confcache >+ >+test "x$prefix" = xNONE && prefix=$ac_default_prefix >+# Let make expand exec_prefix. >+test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' >+ >+DEFS=-DHAVE_CONFIG_H >+ >+ac_libobjs= >+ac_ltlibobjs= >+U= >+for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue >+ # 1. Remove the extension, and $U if already installed. >+ ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' >+ ac_i=`$as_echo "$ac_i" | sed "$ac_script"` >+ # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR >+ # will be set to the directory where LIBOBJS objects are built. >+ as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" >+ as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' >+done >+LIBOBJS=$ac_libobjs >+ >+LTLIBOBJS=$ac_ltlibobjs >+ >+ >+ >+: "${CONFIG_STATUS=./config.status}" >+ac_write_fail=0 >+ac_clean_files_save=$ac_clean_files >+ac_clean_files="$ac_clean_files $CONFIG_STATUS" >+{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 >+$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} >+as_write_fail=0 >+cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 >+#! $SHELL >+# Generated by $as_me. >+# Run this file to recreate the current configuration. >+# Compiler output produced by configure, useful for debugging >+# configure, is in config.log if it exists. >+ >+debug=false >+ac_cs_recheck=false >+ac_cs_silent=false >+ >+SHELL=\${CONFIG_SHELL-$SHELL} >+export SHELL >+_ASEOF >+cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 >+## -------------------- ## >+## M4sh Initialization. ## >+## -------------------- ## >+ >+# Be more Bourne compatible >+DUALCASE=1; export DUALCASE # for MKS sh >+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : >+ emulate sh >+ NULLCMD=: >+ # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which >+ # is contrary to our usage. Disable this feature. >+ alias -g '${1+"$@"}'='"$@"' >+ setopt NO_GLOB_SUBST >+else >+ case `(set -o) 2>/dev/null` in #( >+ *posix*) : >+ set -o posix ;; #( >+ *) : >+ ;; >+esac >+fi >+ >+ >+as_nl=' >+' >+export as_nl >+# Printing a long string crashes Solaris 7 /usr/bin/printf. >+as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo >+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo >+# Prefer a ksh shell builtin over an external printf program on Solaris, >+# but without wasting forks for bash or zsh. >+if test -z "$BASH_VERSION$ZSH_VERSION" \ >+ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='print -r --' >+ as_echo_n='print -rn --' >+elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then >+ as_echo='printf %s\n' >+ as_echo_n='printf %s' >+else >+ if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then >+ as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' >+ as_echo_n='/usr/ucb/echo -n' >+ else >+ as_echo_body='eval expr "X$1" : "X\\(.*\\)"' >+ as_echo_n_body='eval >+ arg=$1; >+ case $arg in #( >+ *"$as_nl"*) >+ expr "X$arg" : "X\\(.*\\)$as_nl"; >+ arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; >+ esac; >+ expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" >+ ' >+ export as_echo_n_body >+ as_echo_n='sh -c $as_echo_n_body as_echo' >+ fi >+ export as_echo_body >+ as_echo='sh -c $as_echo_body as_echo' >+fi >+ >+# The user is always right. >+if test "${PATH_SEPARATOR+set}" != set; then >+ PATH_SEPARATOR=: >+ (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { >+ (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || >+ PATH_SEPARATOR=';' >+ } >+fi >+ >+ >+# IFS >+# We need space, tab and new line, in precisely that order. Quoting is >+# there to prevent editors from complaining about space-tab. >+# (If _AS_PATH_WALK were called with IFS unset, it would disable word >+# splitting by setting IFS to empty value.) >+IFS=" "" $as_nl" >+ >+# Find who we are. Look in the path if we contain no directory separator. >+as_myself= >+case $0 in #(( >+ *[\\/]* ) as_myself=$0 ;; >+ *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR >+for as_dir in $PATH >+do >+ IFS=$as_save_IFS >+ test -z "$as_dir" && as_dir=. >+ test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break >+ done >+IFS=$as_save_IFS >+ >+ ;; >+esac >+# We did not find ourselves, most probably we were run as `sh COMMAND' >+# in which case we are not to be found in the path. >+if test "x$as_myself" = x; then >+ as_myself=$0 >+fi >+if test ! -f "$as_myself"; then >+ $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 >+ exit 1 >+fi >+ >+# Unset variables that we do not need and which cause bugs (e.g. in >+# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" >+# suppresses any "Segmentation fault" message there. '((' could >+# trigger a bug in pdksh 5.2.14. >+for as_var in BASH_ENV ENV MAIL MAILPATH >+do eval test x\${$as_var+set} = xset \ >+ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : >+done >+PS1='$ ' >+PS2='> ' >+PS4='+ ' >+ >+# NLS nuisances. >+LC_ALL=C >+export LC_ALL >+LANGUAGE=C >+export LANGUAGE >+ >+# CDPATH. >+(unset CDPATH) >/dev/null 2>&1 && unset CDPATH >+ >+ >+# as_fn_error STATUS ERROR [LINENO LOG_FD] >+# ---------------------------------------- >+# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are >+# provided, also output the error to LOG_FD, referencing LINENO. Then exit the >+# script with STATUS, using 1 if that was 0. >+as_fn_error () >+{ >+ as_status=$1; test $as_status -eq 0 && as_status=1 >+ if test "$4"; then >+ as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack >+ $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 >+ fi >+ $as_echo "$as_me: error: $2" >&2 >+ as_fn_exit $as_status >+} # as_fn_error >+ >+ >+# as_fn_set_status STATUS >+# ----------------------- >+# Set $? to STATUS, without forking. >+as_fn_set_status () >+{ >+ return $1 >+} # as_fn_set_status >+ >+# as_fn_exit STATUS >+# ----------------- >+# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. >+as_fn_exit () >+{ >+ set +e >+ as_fn_set_status $1 >+ exit $1 >+} # as_fn_exit >+ >+# as_fn_unset VAR >+# --------------- >+# Portably unset VAR. >+as_fn_unset () >+{ >+ { eval $1=; unset $1;} >+} >+as_unset=as_fn_unset >+# as_fn_append VAR VALUE >+# ---------------------- >+# Append the text in VALUE to the end of the definition contained in VAR. Take >+# advantage of any shell optimizations that allow amortized linear growth over >+# repeated appends, instead of the typical quadratic growth present in naive >+# implementations. >+if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : >+ eval 'as_fn_append () >+ { >+ eval $1+=\$2 >+ }' >+else >+ as_fn_append () >+ { >+ eval $1=\$$1\$2 >+ } >+fi # as_fn_append >+ >+# as_fn_arith ARG... >+# ------------------ >+# Perform arithmetic evaluation on the ARGs, and store the result in the >+# global $as_val. Take advantage of shells that can avoid forks. The arguments >+# must be portable across $(()) and expr. >+if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : >+ eval 'as_fn_arith () >+ { >+ as_val=$(( $* )) >+ }' >+else >+ as_fn_arith () >+ { >+ as_val=`expr "$@" || test $? -eq 1` >+ } >+fi # as_fn_arith >+ >+ >+if expr a : '\(a\)' >/dev/null 2>&1 && >+ test "X`expr 00001 : '.*\(...\)'`" = X001; then >+ as_expr=expr >+else >+ as_expr=false >+fi >+ >+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then >+ as_basename=basename >+else >+ as_basename=false >+fi >+ >+if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then >+ as_dirname=dirname >+else >+ as_dirname=false >+fi >+ >+as_me=`$as_basename -- "$0" || >+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ >+ X"$0" : 'X\(//\)$' \| \ >+ X"$0" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X/"$0" | >+ sed '/^.*\/\([^/][^/]*\)\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\/\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ >+# Avoid depending upon Character Ranges. >+as_cr_letters='abcdefghijklmnopqrstuvwxyz' >+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' >+as_cr_Letters=$as_cr_letters$as_cr_LETTERS >+as_cr_digits='0123456789' >+as_cr_alnum=$as_cr_Letters$as_cr_digits >+ >+ECHO_C= ECHO_N= ECHO_T= >+case `echo -n x` in #((((( >+-n*) >+ case `echo 'xy\c'` in >+ *c*) ECHO_T=' ';; # ECHO_T is single tab character. >+ xy) ECHO_C='\c';; >+ *) echo `echo ksh88 bug on AIX 6.1` > /dev/null >+ ECHO_T=' ';; >+ esac;; >+*) >+ ECHO_N='-n';; >+esac >+ >+rm -f conf$$ conf$$.exe conf$$.file >+if test -d conf$$.dir; then >+ rm -f conf$$.dir/conf$$.file >+else >+ rm -f conf$$.dir >+ mkdir conf$$.dir 2>/dev/null >+fi >+if (echo >conf$$.file) 2>/dev/null; then >+ if ln -s conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s='ln -s' >+ # ... but there are two gotchas: >+ # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. >+ # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. >+ # In both cases, we have to default to `cp -pR'. >+ ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || >+ as_ln_s='cp -pR' >+ elif ln conf$$.file conf$$ 2>/dev/null; then >+ as_ln_s=ln >+ else >+ as_ln_s='cp -pR' >+ fi >+else >+ as_ln_s='cp -pR' >+fi >+rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file >+rmdir conf$$.dir 2>/dev/null >+ >+ >+# as_fn_mkdir_p >+# ------------- >+# Create "$as_dir" as a directory, including parents if necessary. >+as_fn_mkdir_p () >+{ >+ >+ case $as_dir in #( >+ -*) as_dir=./$as_dir;; >+ esac >+ test -d "$as_dir" || eval $as_mkdir_p || { >+ as_dirs= >+ while :; do >+ case $as_dir in #( >+ *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( >+ *) as_qdir=$as_dir;; >+ esac >+ as_dirs="'$as_qdir' $as_dirs" >+ as_dir=`$as_dirname -- "$as_dir" || >+$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$as_dir" : 'X\(//\)[^/]' \| \ >+ X"$as_dir" : 'X\(//\)$' \| \ >+ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$as_dir" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ test -d "$as_dir" && break >+ done >+ test -z "$as_dirs" || eval "mkdir $as_dirs" >+ } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" >+ >+ >+} # as_fn_mkdir_p >+if mkdir -p . 2>/dev/null; then >+ as_mkdir_p='mkdir -p "$as_dir"' >+else >+ test -d ./-p && rmdir ./-p >+ as_mkdir_p=false >+fi >+ >+ >+# as_fn_executable_p FILE >+# ----------------------- >+# Test if FILE is an executable regular file. >+as_fn_executable_p () >+{ >+ test -f "$1" && test -x "$1" >+} # as_fn_executable_p >+as_test_x='test -x' >+as_executable_p=as_fn_executable_p >+ >+# Sed expression to map a string onto a valid CPP name. >+as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" >+ >+# Sed expression to map a string onto a valid variable name. >+as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" >+ >+ >+exec 6>&1 >+## ----------------------------------- ## >+## Main body of $CONFIG_STATUS script. ## >+## ----------------------------------- ## >+_ASEOF >+test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+# Save the log message, to keep $0 and so on meaningful, and to >+# report actual input values of CONFIG_FILES etc. instead of their >+# values after options handling. >+ac_log=" >+This file was extended by libbgpdump $as_me 1.4.99.15, which was >+generated by GNU Autoconf 2.69. Invocation command line was >+ >+ CONFIG_FILES = $CONFIG_FILES >+ CONFIG_HEADERS = $CONFIG_HEADERS >+ CONFIG_LINKS = $CONFIG_LINKS >+ CONFIG_COMMANDS = $CONFIG_COMMANDS >+ $ $0 $@ >+ >+on `(hostname || uname -n) 2>/dev/null | sed 1q` >+" >+ >+_ACEOF >+ >+case $ac_config_files in *" >+"*) set x $ac_config_files; shift; ac_config_files=$*;; >+esac >+ >+case $ac_config_headers in *" >+"*) set x $ac_config_headers; shift; ac_config_headers=$*;; >+esac >+ >+ >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+# Files that config.status was made for. >+config_files="$ac_config_files" >+config_headers="$ac_config_headers" >+ >+_ACEOF >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+ac_cs_usage="\ >+\`$as_me' instantiates files and other configuration actions >+from templates according to the current configuration. Unless the files >+and actions are specified as TAGs, all are instantiated by default. >+ >+Usage: $0 [OPTION]... [TAG]... >+ >+ -h, --help print this help, then exit >+ -V, --version print version number and configuration settings, then exit >+ --config print configuration, then exit >+ -q, --quiet, --silent >+ do not print progress messages >+ -d, --debug don't remove temporary files >+ --recheck update $as_me by reconfiguring in the same conditions >+ --file=FILE[:TEMPLATE] >+ instantiate the configuration file FILE >+ --header=FILE[:TEMPLATE] >+ instantiate the configuration header FILE >+ >+Configuration files: >+$config_files >+ >+Configuration headers: >+$config_headers >+ >+Report bugs to <ris@ripe.net>." >+ >+_ACEOF >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" >+ac_cs_version="\\ >+libbgpdump config.status 1.4.99.15 >+configured by $0, generated by GNU Autoconf 2.69, >+ with options \\"\$ac_cs_config\\" >+ >+Copyright (C) 2012 Free Software Foundation, Inc. >+This config.status script is free software; the Free Software Foundation >+gives unlimited permission to copy, distribute and modify it." >+ >+ac_pwd='$ac_pwd' >+srcdir='$srcdir' >+test -n "\$AWK" || AWK=awk >+_ACEOF >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+# The default lists apply if the user does not specify any file. >+ac_need_defaults=: >+while test $# != 0 >+do >+ case $1 in >+ --*=?*) >+ ac_option=`expr "X$1" : 'X\([^=]*\)='` >+ ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` >+ ac_shift=: >+ ;; >+ --*=) >+ ac_option=`expr "X$1" : 'X\([^=]*\)='` >+ ac_optarg= >+ ac_shift=: >+ ;; >+ *) >+ ac_option=$1 >+ ac_optarg=$2 >+ ac_shift=shift >+ ;; >+ esac >+ >+ case $ac_option in >+ # Handling of the options. >+ -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) >+ ac_cs_recheck=: ;; >+ --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) >+ $as_echo "$ac_cs_version"; exit ;; >+ --config | --confi | --conf | --con | --co | --c ) >+ $as_echo "$ac_cs_config"; exit ;; >+ --debug | --debu | --deb | --de | --d | -d ) >+ debug=: ;; >+ --file | --fil | --fi | --f ) >+ $ac_shift >+ case $ac_optarg in >+ *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; >+ '') as_fn_error $? "missing file argument" ;; >+ esac >+ as_fn_append CONFIG_FILES " '$ac_optarg'" >+ ac_need_defaults=false;; >+ --header | --heade | --head | --hea ) >+ $ac_shift >+ case $ac_optarg in >+ *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; >+ esac >+ as_fn_append CONFIG_HEADERS " '$ac_optarg'" >+ ac_need_defaults=false;; >+ --he | --h) >+ # Conflict between --help and --header >+ as_fn_error $? "ambiguous option: \`$1' >+Try \`$0 --help' for more information.";; >+ --help | --hel | -h ) >+ $as_echo "$ac_cs_usage"; exit ;; >+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \ >+ | -silent | --silent | --silen | --sile | --sil | --si | --s) >+ ac_cs_silent=: ;; >+ >+ # This is an error. >+ -*) as_fn_error $? "unrecognized option: \`$1' >+Try \`$0 --help' for more information." ;; >+ >+ *) as_fn_append ac_config_targets " $1" >+ ac_need_defaults=false ;; >+ >+ esac >+ shift >+done >+ >+ac_configure_extra_args= >+ >+if $ac_cs_silent; then >+ exec 6>/dev/null >+ ac_configure_extra_args="$ac_configure_extra_args --silent" >+fi >+ >+_ACEOF >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+if \$ac_cs_recheck; then >+ set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion >+ shift >+ \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 >+ CONFIG_SHELL='$SHELL' >+ export CONFIG_SHELL >+ exec "\$@" >+fi >+ >+_ACEOF >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+exec 5>>config.log >+{ >+ echo >+ sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX >+## Running $as_me. ## >+_ASBOX >+ $as_echo "$ac_log" >+} >&5 >+ >+_ACEOF >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+_ACEOF >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+ >+# Handling of arguments. >+for ac_config_target in $ac_config_targets >+do >+ case $ac_config_target in >+ "bgpdump-config.h") CONFIG_HEADERS="$CONFIG_HEADERS bgpdump-config.h" ;; >+ "bgpdump.spec") CONFIG_FILES="$CONFIG_FILES bgpdump.spec" ;; >+ "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; >+ >+ *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; >+ esac >+done >+ >+ >+# If the user did not use the arguments to specify the items to instantiate, >+# then the envvar interface is used. Set only those that are not. >+# We use the long form for the default assignment because of an extremely >+# bizarre bug on SunOS 4.1.3. >+if $ac_need_defaults; then >+ test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files >+ test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers >+fi >+ >+# Have a temporary directory for convenience. Make it in the build tree >+# simply because there is no reason against having it here, and in addition, >+# creating and moving files from /tmp can sometimes cause problems. >+# Hook for its removal unless debugging. >+# Note that there is a small window in which the directory will not be cleaned: >+# after its creation but before its name has been assigned to `$tmp'. >+$debug || >+{ >+ tmp= ac_tmp= >+ trap 'exit_status=$? >+ : "${ac_tmp:=$tmp}" >+ { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status >+' 0 >+ trap 'as_fn_exit 1' 1 2 13 15 >+} >+# Create a (secure) tmp directory for tmp files. >+ >+{ >+ tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && >+ test -d "$tmp" >+} || >+{ >+ tmp=./conf$$-$RANDOM >+ (umask 077 && mkdir "$tmp") >+} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 >+ac_tmp=$tmp >+ >+# Set up the scripts for CONFIG_FILES section. >+# No need to generate them if there are no CONFIG_FILES. >+# This happens for instance with `./config.status config.h'. >+if test -n "$CONFIG_FILES"; then >+ >+ >+ac_cr=`echo X | tr X '\015'` >+# On cygwin, bash can eat \r inside `` if the user requested igncr. >+# But we know of no other shell where ac_cr would be empty at this >+# point, so we can use a bashism as a fallback. >+if test "x$ac_cr" = x; then >+ eval ac_cr=\$\'\\r\' >+fi >+ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` >+if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then >+ ac_cs_awk_cr='\\r' >+else >+ ac_cs_awk_cr=$ac_cr >+fi >+ >+echo 'BEGIN {' >"$ac_tmp/subs1.awk" && >+_ACEOF >+ >+ >+{ >+ echo "cat >conf$$subs.awk <<_ACEOF" && >+ echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && >+ echo "_ACEOF" >+} >conf$$subs.sh || >+ as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 >+ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` >+ac_delim='%!_!# ' >+for ac_last_try in false false false false false :; do >+ . ./conf$$subs.sh || >+ as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 >+ >+ ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` >+ if test $ac_delim_n = $ac_delim_num; then >+ break >+ elif $ac_last_try; then >+ as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 >+ else >+ ac_delim="$ac_delim!$ac_delim _$ac_delim!! " >+ fi >+done >+rm -f conf$$subs.sh >+ >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && >+_ACEOF >+sed -n ' >+h >+s/^/S["/; s/!.*/"]=/ >+p >+g >+s/^[^!]*!// >+:repl >+t repl >+s/'"$ac_delim"'$// >+t delim >+:nl >+h >+s/\(.\{148\}\)..*/\1/ >+t more1 >+s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ >+p >+n >+b repl >+:more1 >+s/["\\]/\\&/g; s/^/"/; s/$/"\\/ >+p >+g >+s/.\{148\}// >+t nl >+:delim >+h >+s/\(.\{148\}\)..*/\1/ >+t more2 >+s/["\\]/\\&/g; s/^/"/; s/$/"/ >+p >+b >+:more2 >+s/["\\]/\\&/g; s/^/"/; s/$/"\\/ >+p >+g >+s/.\{148\}// >+t delim >+' <conf$$subs.awk | sed ' >+/^[^""]/{ >+ N >+ s/\n// >+} >+' >>$CONFIG_STATUS || ac_write_fail=1 >+rm -f conf$$subs.awk >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+_ACAWK >+cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && >+ for (key in S) S_is_set[key] = 1 >+ FS = "" >+ >+} >+{ >+ line = $ 0 >+ nfields = split(line, field, "@") >+ substed = 0 >+ len = length(field[1]) >+ for (i = 2; i < nfields; i++) { >+ key = field[i] >+ keylen = length(key) >+ if (S_is_set[key]) { >+ value = S[key] >+ line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) >+ len += length(value) + length(field[++i]) >+ substed = 1 >+ } else >+ len += 1 + keylen >+ } >+ >+ print line >+} >+ >+_ACAWK >+_ACEOF >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then >+ sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" >+else >+ cat >+fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ >+ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 >+_ACEOF >+ >+# VPATH may cause trouble with some makes, so we remove sole $(srcdir), >+# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and >+# trailing colons and then remove the whole line if VPATH becomes empty >+# (actually we leave an empty line to preserve line numbers). >+if test "x$srcdir" = x.; then >+ ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ >+h >+s/// >+s/^/:/ >+s/[ ]*$/:/ >+s/:\$(srcdir):/:/g >+s/:\${srcdir}:/:/g >+s/:@srcdir@:/:/g >+s/^:*// >+s/:*$// >+x >+s/\(=[ ]*\).*/\1/ >+G >+s/\n// >+s/^[^=]*=[ ]*$// >+}' >+fi >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+fi # test -n "$CONFIG_FILES" >+ >+# Set up the scripts for CONFIG_HEADERS section. >+# No need to generate them if there are no CONFIG_HEADERS. >+# This happens for instance with `./config.status Makefile'. >+if test -n "$CONFIG_HEADERS"; then >+cat >"$ac_tmp/defines.awk" <<\_ACAWK || >+BEGIN { >+_ACEOF >+ >+# Transform confdefs.h into an awk script `defines.awk', embedded as >+# here-document in config.status, that substitutes the proper values into >+# config.h.in to produce config.h. >+ >+# Create a delimiter string that does not exist in confdefs.h, to ease >+# handling of long lines. >+ac_delim='%!_!# ' >+for ac_last_try in false false :; do >+ ac_tt=`sed -n "/$ac_delim/p" confdefs.h` >+ if test -z "$ac_tt"; then >+ break >+ elif $ac_last_try; then >+ as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 >+ else >+ ac_delim="$ac_delim!$ac_delim _$ac_delim!! " >+ fi >+done >+ >+# For the awk script, D is an array of macro values keyed by name, >+# likewise P contains macro parameters if any. Preserve backslash >+# newline sequences. >+ >+ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* >+sed -n ' >+s/.\{148\}/&'"$ac_delim"'/g >+t rset >+:rset >+s/^[ ]*#[ ]*define[ ][ ]*/ / >+t def >+d >+:def >+s/\\$// >+t bsnl >+s/["\\]/\\&/g >+s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ >+D["\1"]=" \3"/p >+s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p >+d >+:bsnl >+s/["\\]/\\&/g >+s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ >+D["\1"]=" \3\\\\\\n"\\/p >+t cont >+s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p >+t cont >+d >+:cont >+n >+s/.\{148\}/&'"$ac_delim"'/g >+t clear >+:clear >+s/\\$// >+t bsnlc >+s/["\\]/\\&/g; s/^/"/; s/$/"/p >+d >+:bsnlc >+s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p >+b cont >+' <confdefs.h | sed ' >+s/'"$ac_delim"'/"\\\ >+"/g' >>$CONFIG_STATUS || ac_write_fail=1 >+ >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+ for (key in D) D_is_set[key] = 1 >+ FS = "" >+} >+/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { >+ line = \$ 0 >+ split(line, arg, " ") >+ if (arg[1] == "#") { >+ defundef = arg[2] >+ mac1 = arg[3] >+ } else { >+ defundef = substr(arg[1], 2) >+ mac1 = arg[2] >+ } >+ split(mac1, mac2, "(") #) >+ macro = mac2[1] >+ prefix = substr(line, 1, index(line, defundef) - 1) >+ if (D_is_set[macro]) { >+ # Preserve the white space surrounding the "#". >+ print prefix "define", macro P[macro] D[macro] >+ next >+ } else { >+ # Replace #undef with comments. This is necessary, for example, >+ # in the case of _POSIX_SOURCE, which is predefined and required >+ # on some systems where configure will not decide to define it. >+ if (defundef == "undef") { >+ print "/*", prefix defundef, macro, "*/" >+ next >+ } >+ } >+} >+{ print } >+_ACAWK >+_ACEOF >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+ as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 >+fi # test -n "$CONFIG_HEADERS" >+ >+ >+eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " >+shift >+for ac_tag >+do >+ case $ac_tag in >+ :[FHLC]) ac_mode=$ac_tag; continue;; >+ esac >+ case $ac_mode$ac_tag in >+ :[FHL]*:*);; >+ :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; >+ :[FH]-) ac_tag=-:-;; >+ :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; >+ esac >+ ac_save_IFS=$IFS >+ IFS=: >+ set x $ac_tag >+ IFS=$ac_save_IFS >+ shift >+ ac_file=$1 >+ shift >+ >+ case $ac_mode in >+ :L) ac_source=$1;; >+ :[FH]) >+ ac_file_inputs= >+ for ac_f >+ do >+ case $ac_f in >+ -) ac_f="$ac_tmp/stdin";; >+ *) # Look for the file first in the build tree, then in the source tree >+ # (if the path is not absolute). The absolute path cannot be DOS-style, >+ # because $ac_f cannot contain `:'. >+ test -f "$ac_f" || >+ case $ac_f in >+ [\\/$]*) false;; >+ *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; >+ esac || >+ as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; >+ esac >+ case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac >+ as_fn_append ac_file_inputs " '$ac_f'" >+ done >+ >+ # Let's still pretend it is `configure' which instantiates (i.e., don't >+ # use $as_me), people would be surprised to read: >+ # /* config.h. Generated by config.status. */ >+ configure_input='Generated from '` >+ $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' >+ `' by configure.' >+ if test x"$ac_file" != x-; then >+ configure_input="$ac_file. $configure_input" >+ { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 >+$as_echo "$as_me: creating $ac_file" >&6;} >+ fi >+ # Neutralize special characters interpreted by sed in replacement strings. >+ case $configure_input in #( >+ *\&* | *\|* | *\\* ) >+ ac_sed_conf_input=`$as_echo "$configure_input" | >+ sed 's/[\\\\&|]/\\\\&/g'`;; #( >+ *) ac_sed_conf_input=$configure_input;; >+ esac >+ >+ case $ac_tag in >+ *:-:* | *:-) cat >"$ac_tmp/stdin" \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; >+ esac >+ ;; >+ esac >+ >+ ac_dir=`$as_dirname -- "$ac_file" || >+$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ >+ X"$ac_file" : 'X\(//\)[^/]' \| \ >+ X"$ac_file" : 'X\(//\)$' \| \ >+ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || >+$as_echo X"$ac_file" | >+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)[^/].*/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\/\)$/{ >+ s//\1/ >+ q >+ } >+ /^X\(\/\).*/{ >+ s//\1/ >+ q >+ } >+ s/.*/./; q'` >+ as_dir="$ac_dir"; as_fn_mkdir_p >+ ac_builddir=. >+ >+case "$ac_dir" in >+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; >+*) >+ ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` >+ # A ".." for each directory in $ac_dir_suffix. >+ ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` >+ case $ac_top_builddir_sub in >+ "") ac_top_builddir_sub=. ac_top_build_prefix= ;; >+ *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; >+ esac ;; >+esac >+ac_abs_top_builddir=$ac_pwd >+ac_abs_builddir=$ac_pwd$ac_dir_suffix >+# for backward compatibility: >+ac_top_builddir=$ac_top_build_prefix >+ >+case $srcdir in >+ .) # We are building in place. >+ ac_srcdir=. >+ ac_top_srcdir=$ac_top_builddir_sub >+ ac_abs_top_srcdir=$ac_pwd ;; >+ [\\/]* | ?:[\\/]* ) # Absolute name. >+ ac_srcdir=$srcdir$ac_dir_suffix; >+ ac_top_srcdir=$srcdir >+ ac_abs_top_srcdir=$srcdir ;; >+ *) # Relative name. >+ ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix >+ ac_top_srcdir=$ac_top_build_prefix$srcdir >+ ac_abs_top_srcdir=$ac_pwd/$srcdir ;; >+esac >+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix >+ >+ >+ case $ac_mode in >+ :F) >+ # >+ # CONFIG_FILE >+ # >+ >+_ACEOF >+ >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+# If the template does not know about datarootdir, expand it. >+# FIXME: This hack should be removed a few years after 2.60. >+ac_datarootdir_hack=; ac_datarootdir_seen= >+ac_sed_dataroot=' >+/datarootdir/ { >+ p >+ q >+} >+/@datadir@/p >+/@docdir@/p >+/@infodir@/p >+/@localedir@/p >+/@mandir@/p' >+case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in >+*datarootdir*) ac_datarootdir_seen=yes;; >+*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 >+$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} >+_ACEOF >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+ ac_datarootdir_hack=' >+ s&@datadir@&$datadir&g >+ s&@docdir@&$docdir&g >+ s&@infodir@&$infodir&g >+ s&@localedir@&$localedir&g >+ s&@mandir@&$mandir&g >+ s&\\\${datarootdir}&$datarootdir&g' ;; >+esac >+_ACEOF >+ >+# Neutralize VPATH when `$srcdir' = `.'. >+# Shell code in configure.ac might set extrasub. >+# FIXME: do we really want to maintain this feature? >+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 >+ac_sed_extra="$ac_vpsub >+$extrasub >+_ACEOF >+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 >+:t >+/@[a-zA-Z_][a-zA-Z_0-9]*@/!b >+s|@configure_input@|$ac_sed_conf_input|;t t >+s&@top_builddir@&$ac_top_builddir_sub&;t t >+s&@top_build_prefix@&$ac_top_build_prefix&;t t >+s&@srcdir@&$ac_srcdir&;t t >+s&@abs_srcdir@&$ac_abs_srcdir&;t t >+s&@top_srcdir@&$ac_top_srcdir&;t t >+s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t >+s&@builddir@&$ac_builddir&;t t >+s&@abs_builddir@&$ac_abs_builddir&;t t >+s&@abs_top_builddir@&$ac_abs_top_builddir&;t t >+$ac_datarootdir_hack >+" >+eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ >+ >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ >+test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && >+ { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && >+ { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ >+ "$ac_tmp/out"`; test -z "$ac_out"; } && >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' >+which seems to be undefined. Please make sure it is defined" >&5 >+$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' >+which seems to be undefined. Please make sure it is defined" >&2;} >+ >+ rm -f "$ac_tmp/stdin" >+ case $ac_file in >+ -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; >+ *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; >+ esac \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ ;; >+ :H) >+ # >+ # CONFIG_HEADER >+ # >+ if test x"$ac_file" != x-; then >+ { >+ $as_echo "/* $configure_input */" \ >+ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" >+ } >"$ac_tmp/config.h" \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 >+$as_echo "$as_me: $ac_file is unchanged" >&6;} >+ else >+ rm -f "$ac_file" >+ mv "$ac_tmp/config.h" "$ac_file" \ >+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 >+ fi >+ else >+ $as_echo "/* $configure_input */" \ >+ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ >+ || as_fn_error $? "could not create -" "$LINENO" 5 >+ fi >+ ;; >+ >+ >+ esac >+ >+done # for ac_tag >+ >+ >+as_fn_exit 0 >+_ACEOF >+ac_clean_files=$ac_clean_files_save >+ >+test $ac_write_fail = 0 || >+ as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 >+ >+ >+# configure is writing to config.log, and then calls config.status. >+# config.status does its own redirection, appending to config.log. >+# Unfortunately, on DOS this fails, as config.log is still kept open >+# by configure, so config.status won't be able to write to it; its >+# output is simply discarded. So we exec the FD to /dev/null, >+# effectively closing config.log, so it can be properly (re)opened and >+# appended to by config.status. When coming back to configure, we >+# need to make the FD available again. >+if test "$no_create" != yes; then >+ ac_cs_success=: >+ ac_config_status_args= >+ test "$silent" = yes && >+ ac_config_status_args="$ac_config_status_args --quiet" >+ exec 5>/dev/null >+ $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false >+ exec 5>>config.log >+ # Use ||, not &&, to avoid exiting from the if with $? = 1, which >+ # would make configure fail if this is the last instruction. >+ $ac_cs_success || as_fn_exit 1 >+fi >+if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then >+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 >+$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} >+fi >+ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/configure.in libbgpdump-new/work/libbgpdump-1.4.99.15/configure.in >--- libbgpdump/work/libbgpdump-1.4.99.15/configure.in 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/configure.in 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,41 @@ >+dnl Process this file with autoconf to produce a configure script. >+AC_REVISION($Revision$) >+ >+AC_INIT([libbgpdump], 1.4.99.15, [ris@ripe.net]) >+AC_CONFIG_SRCDIR([bgpdump_lib.c]) >+AC_CONFIG_HEADERS([bgpdump-config.h]) >+ >+CFLAGS="-g -O3 $CFLAGS -Wall" >+CFLAGS="$CFLAGS -Wsystem-headers -Wno-format-y2k -Wno-sign-compare -Wcast-align" >+CFLAGS="$CFLAGS -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wswitch -Wshadow" >+ >+# Checks for programs. >+AC_PROG_CC >+AC_PROG_RANLIB >+ >+# Checks for header files. >+AC_CHECK_HEADERS([arpa/inet.h netinet/in.h syslog.h]) >+AC_STRUCT_TM >+ >+# Check for u_*_t >+AC_CHECK_TYPE(u_char_t, , AC_DEFINE(u_char_t, uchar_t, [Define if system headers do not define u_char_t])) >+AC_CHECK_TYPE(u_int8_t, , AC_DEFINE(u_int8_t, uint8_t, [Define if system headers do not define u_int8_t])) >+AC_CHECK_TYPE(u_int16_t, , AC_DEFINE(u_int16_t, uint16_t, [Define if system headers do not define u_int16_t])) >+AC_CHECK_TYPE(u_int32_t, , AC_DEFINE(u_int32_t, uint32_t, [Define if system headers do not define u_int32_t])) >+ >+AC_CHECK_LIB(z, gzopen, [], AC_DEFINE(DONT_HAVE_GZ, 1, Define if libz not present)) >+AC_CHECK_LIB(bz2, BZ2_bzReadOpen, [], AC_DEFINE(DONT_HAVE_BZ2, 1, Define if libbzip2 not present)) >+ >+# Check for inet_ntoa in -lnsl if not found (Solaris) >+AC_CHECK_FUNCS(inet_ntoa, [], AC_CHECK_LIB(nsl, inet_ntoa, [], AC_MSG_ERROR([inet_ntoa not found],1))) >+AC_CHECK_FUNCS(inet_ntop, [], AC_CHECK_LIB(nsl, inet_ntop, [], AC_MSG_ERROR([inet_ntop not found],1))) >+ >+case `uname` in >+ Darwin*) LDFLAGS="$LDFLAGS -dynamiclib" ;; >+ *) LDFLAGS="$LDFLAGS -shared" ;; >+esac >+ >+AC_SUBST(CFLAGS) >+AC_SUBST(LIBS) >+ >+AC_OUTPUT([bgpdump.spec Makefile]) >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/example.c libbgpdump-new/work/libbgpdump-1.4.99.15/example.c >--- libbgpdump/work/libbgpdump-1.4.99.15/example.c 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/example.c 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,433 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+Parts of this code have been engineered after analiyzing GNU Zebra's >+source code and therefore might contain declarations/code from GNU >+Zebra, Copyright (C) 1999 Kunihiro Ishiguro. Zebra is a free routing >+software, distributed under the GNU General Public License. A copy of >+this license is included with libbgpdump. >+ >+Author: Dan Ardelean (dan@ripe.net) >+*/ >+ >+#include "bgpdump_lib.h" >+#include <time.h> >+ >+#include <stdlib.h> >+#include <netinet/in.h> >+#include <sys/socket.h> >+#include <arpa/inet.h> >+ >+ void process(BGPDUMP_ENTRY *entry); >+ void show_attr(attributes_t *attr); >+ void show_prefixes(int count,struct prefix *prefix); >+#ifdef BGPDUMP_HAVE_IPV6 >+ void show_v6_prefixes(int count, struct prefix *prefix); >+#endif >+ >+int main(int argc, char **argv) { >+ BGPDUMP *my_dump; >+ BGPDUMP_ENTRY *my_entry=NULL; >+ >+ if(argc>1) { >+ my_dump=bgpdump_open_dump(argv[1]); >+ } else { >+ my_dump=bgpdump_open_dump("dumps/updates.20020701.0032"); >+ } >+ >+ if(my_dump==NULL) { >+ printf("Error opening dump file ...\n"); >+ exit(1); >+ } >+ >+ do { >+//fprintf(stdout, "Offset: %d\n", gztell(my_dump->f)); >+ my_entry=bgpdump_read_next(my_dump); >+ if(my_entry!=NULL) { >+ process(my_entry); >+ bgpdump_free_mem(my_entry); >+ } >+ } while(my_dump->eof==0); >+ >+ bgpdump_close_dump(my_dump); >+//fprintf(stderr, "%s: OK=%d, BAD=%d (%f%% OK)\n", my_dump->filename, my_dump->parsed_ok, my_dump->parsed - my_dump->parsed_ok, (float) my_dump->parsed_ok / my_dump->parsed * 100); >+ >+ return 0; >+} >+ >+char *bgp_state_name[] = { >+ "Unknown", >+ "IDLE", >+ "CONNECT", >+ "ACTIVE", >+ "OPEN_SENT", >+ "OPEN_CONFIRM", >+ "ESTABLISHED", >+ NULL >+}; >+ >+char *bgp_message_types[] = { >+ "Unknown", >+ "Open", >+ "Update/Withdraw", >+ "Notification", >+ "Keepalive" >+}; >+ >+char *notify_codes[] = { >+ "Unknown", >+ "Message Header Error", >+ "OPEN Message Error", >+ "UPDATE Message Error", >+ "Hold Timer Expired", >+ "Finite State Machine Error", >+ "Cease" >+}; >+ >+char *notify_subcodes[][12] = { >+ { NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }, >+ /* Message Header Error */ >+ { >+ "None", >+ "Connection Not Synchronized", >+ "Bad Message Length", >+ "Bad Message Type", >+ NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL >+ }, >+ /* OPEN Message Error */ >+ { >+ "None", >+ "Unsupported Version Number", >+ "Bad Peer AS", >+ "Bad BGP Identifier", >+ "Unsupported Optional Parameter", >+ "Authentication Failure", >+ "Unacceptable Hold Time", >+ NULL, NULL, NULL, NULL, NULL >+ }, >+ /* UPDATE Message Error */ >+ { >+ "None", >+ "Malformed Attribute List", >+ "Unrecognized Well-known Attribute", >+ "Missing Well-known Attribute", >+ "Attribute Flags Error", >+ "Attribute Length Error", >+ "Invalid ORIGIN Attribute", >+ "AS Routing Loop", >+ "Invalid NEXT_HOP Attribute", >+ "Optional Attribute Error", >+ "Invalid Network Field", >+ "Malformed AS_PATH" >+ }, >+ /* Hold Timer Expired */ >+ { "None", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }, >+ /* Finite State Machine Error */ >+ { "None", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }, >+ /* Cease */ >+ { "None", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL } >+ >+}; >+ >+void process(BGPDUMP_ENTRY *entry) { >+ char prefix[BGPDUMP_ADDRSTRLEN], peer_ip[BGPDUMP_ADDRSTRLEN]; >+ char source_ip[BGPDUMP_ADDRSTRLEN], destination_ip[BGPDUMP_ADDRSTRLEN]; >+ struct mp_nlri *mp_announce, *mp_withdraw; >+ int i, code, subcode; >+ BGPDUMP_TABLE_DUMP_V2_PREFIX *e; >+ >+if(entry->type == BGPDUMP_TYPE_ZEBRA_BGP && entry->subtype == BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE && entry->body.zebra_message.type == BGP_MSG_KEEPALIVE) return; >+if(entry->type == BGPDUMP_TYPE_ZEBRA_BGP && entry->subtype == BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE && entry->body.zebra_message.type == BGP_MSG_OPEN) return; >+if(entry->type == BGPDUMP_TYPE_ZEBRA_BGP && entry->subtype == BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE && entry->body.zebra_message.type == BGP_MSG_NOTIFY) return; >+if(entry->type == BGPDUMP_TYPE_ZEBRA_BGP && entry->subtype == BGPDUMP_SUBTYPE_ZEBRA_BGP_STATE_CHANGE && entry->length == 8) return; >+ >+ printf("TIME : %s",asctime(gmtime(&entry->time))); >+ printf("LENGTH : %u\n", entry->length); >+ switch(entry->type) { >+ case BGPDUMP_TYPE_MRTD_TABLE_DUMP: >+ if(entry->subtype == AFI_IP) { >+ strcpy(prefix, inet_ntoa(entry->body.mrtd_table_dump.prefix.v4_addr)); >+ strcpy(peer_ip, inet_ntoa(entry->body.mrtd_table_dump.peer_ip.v4_addr)); >+#ifdef BGPDUMP_HAVE_IPV6 >+ } else if(entry->subtype == AFI_IP6) { >+ inet_ntop(AF_INET6, &entry->body.mrtd_table_dump.prefix.v6_addr, prefix, >+ sizeof(prefix)); >+ inet_ntop(AF_INET6, &entry->body.mrtd_table_dump.peer_ip.v6_addr, peer_ip, >+ sizeof(peer_ip)); >+#endif >+ } else { >+ *prefix = '\0'; >+ *peer_ip = '\0'; >+ } >+ printf("TYPE : BGP Table Dump Entry\n"); >+ printf(" VIEW : %d\n",entry->body.mrtd_table_dump.view); >+ printf(" SEQUENCE : %d\n",entry->body.mrtd_table_dump.sequence); >+ printf(" PREFIX : %s/%d\n",prefix,entry->body.mrtd_table_dump.mask); >+ printf(" STATUS : %d\n",entry->body.mrtd_table_dump.status); >+ printf(" UPTIME : %s",asctime(gmtime(&entry->body.mrtd_table_dump.uptime))); >+ printf(" PEER IP : %s\n",peer_ip); >+ printf(" PEER AS : %u\n",entry->body.mrtd_table_dump.peer_as); >+ show_attr(entry->attr); >+ break; >+ >+ case BGPDUMP_TYPE_TABLE_DUMP_V2: >+ >+ e = &entry->body.mrtd_table_dump_v2_prefix; >+ >+ if(e->afi == AFI_IP) { >+ strcpy(prefix, inet_ntoa(e->prefix.v4_addr)); >+#ifdef BGPDUMP_HAVE_IPV6 >+ } else if(e->afi == AFI_IP6) { >+ inet_ntop(AF_INET6, &e->prefix.v6_addr, prefix, INET6_ADDRSTRLEN); >+#endif >+ } else { >+ printf("Error: BGP table dump version 2 entry with unknown subtype\n"); >+ break; >+ } >+ >+ for(i = 0; i < e->entry_count; i++){ >+ if(i){ >+ printf("\nTIME : %s",asctime(gmtime(&entry->time))); >+ printf("LENGTH : %u\n", entry->length); >+ } >+ >+ >+ printf("TYPE : BGP Table Dump version 2 Entry\n"); >+ printf(" SEQUENCE : %d\n",e->seq); >+ printf(" PREFIX : %s/%d\n",prefix,e->prefix_length); >+ >+ if(e->entries[i].peer->afi == AFI_IP){ >+ inet_ntop(AF_INET, &e->entries[i].peer->peer_ip, peer_ip, INET6_ADDRSTRLEN); >+#ifdef BGPDUMP_HAVE_IPV6 >+ } else if (e->entries[i].peer->afi == AFI_IP6){ >+ inet_ntop(AF_INET6, &e->entries[i].peer->peer_ip, peer_ip, INET6_ADDRSTRLEN); >+#endif >+ } else { >+ sprintf(peer_ip, "N/A, unsupported AF"); >+ } >+ printf(" PEER IP : %s\n",peer_ip); >+ printf(" PEER AS : %u\n",e->entries[i].peer->peer_as); >+ >+ show_attr(e->entries[i].attr); >+ } >+ >+ break; >+ >+ case BGPDUMP_TYPE_ZEBRA_BGP: >+ printf("TYPE : Zebra BGP \n"); >+ if(entry->body.zebra_message.address_family == AFI_IP) { >+ strcpy(source_ip, inet_ntoa(entry->body.zebra_message.source_ip.v4_addr)); >+ strcpy(destination_ip, inet_ntoa(entry->body.zebra_message.destination_ip.v4_addr)); >+#ifdef BGPDUMP_HAVE_IPV6 >+ } else if(entry->body.zebra_message.address_family == AFI_IP6) { >+ inet_ntop(AF_INET6, &entry->body.zebra_message.source_ip.v6_addr, source_ip, >+ sizeof(source_ip)); >+ inet_ntop(AF_INET6, &entry->body.zebra_message.destination_ip.v6_addr, destination_ip, >+ sizeof(destination_ip)); >+#endif >+ } else { >+ *source_ip = '\0'; >+ *destination_ip = '\0'; >+ } >+ switch(entry->subtype) { >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE: >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE_AS4: >+ printf("SUBTYPE : Zebra BGP Message"); >+ if(entry->subtype == BGPDUMP_SUBTYPE_ZEBRA_BGP_MESSAGE_AS4) { >+ printf(" (32-bit ASN)\n"); >+ } else { >+ printf("\n"); >+ } >+ printf(" SOURCE_AS : %u\n",entry->body.zebra_message.source_as); >+ printf(" DEST_AS : %u\n",entry->body.zebra_message.destination_as); >+ printf(" INTERFACE : %d\n",entry->body.zebra_message.interface_index); >+ printf(" SOURCE_IP : %s\n",source_ip); >+ printf(" DEST_IP : %s\n",destination_ip); >+ >+ if(entry->body.zebra_message.type > sizeof(bgp_message_types) / sizeof(bgp_message_types[0])) >+ printf("MESSAGE TYPE : Unknown\n"); >+ else >+ printf("MESSAGE TYPE : %s\n", bgp_message_types[entry->body.zebra_message.type]); >+ >+ switch(entry->body.zebra_message.type) { >+ case BGP_MSG_UPDATE: >+ printf("WITHDRAW :\n"); >+ show_prefixes(entry->body.zebra_message.withdraw_count,entry->body.zebra_message.withdraw); >+#ifdef BGPDUMP_HAVE_IPV6 >+ if(entry->attr->mp_info && >+ (mp_withdraw = MP_IPV6_WITHDRAW(entry->attr->mp_info)) != NULL) { >+ show_v6_prefixes(mp_withdraw->prefix_count, mp_withdraw->nlri); >+ } >+#endif >+ printf("ANNOUNCE :\n"); >+ show_prefixes(entry->body.zebra_message.announce_count,entry->body.zebra_message.announce); >+#ifdef BGPDUMP_HAVE_IPV6 >+ if(entry->attr->mp_info && >+ (mp_announce = MP_IPV6_ANNOUNCE(entry->attr->mp_info)) != NULL) { >+ show_v6_prefixes(mp_announce->prefix_count, mp_announce->nlri); >+ } >+#endif >+ break; >+ case BGP_MSG_KEEPALIVE: >+ /* Nothing to do */ >+ break; >+ case BGP_MSG_OPEN: >+ printf(" VERSION : %d\n",entry->body.zebra_message.version); >+ printf(" MY_ASN : %u\n",entry->body.zebra_message.my_as); >+ printf(" HOLD_TIME : %d\n",entry->body.zebra_message.hold_time); >+ printf(" ROUTER_ID : %s\n",inet_ntoa(entry->body.zebra_message.bgp_id)); >+ printf(" OPTION_LEN : %d\n",entry->body.zebra_message.opt_len); >+ printf(" OPTION_DATA :"); >+ for(i = 0; i < entry->body.zebra_message.opt_len; i++) { >+ printf(" %02x", entry->body.zebra_message.opt_data[i]); >+ } >+ printf("\n"); >+ break; >+ case BGP_MSG_NOTIFY: >+ code = entry->body.zebra_message.error_code; >+ subcode = entry->body.zebra_message.sub_error_code; >+ >+ printf(" CODE : %d", code); >+ if(code >= sizeof(notify_codes) / sizeof(notify_codes[0])) >+ printf(" (Unknown)\n"); >+ else >+ printf(" (%s)\n", notify_codes[code]); >+ >+ printf(" SUBCODE : %d", subcode); >+ if(code >= sizeof(notify_codes) / sizeof(notify_codes[0]) || >+ subcode >= sizeof(notify_subcodes[0]) / sizeof(notify_subcodes[0][0]) || >+ notify_subcodes[code][subcode] == NULL) >+ printf(" (Unknown)\n"); >+ else >+ printf(" (%s)\n", notify_subcodes[code][subcode]); >+ >+ printf(" DATA :"); >+ for(i = 0; i < entry->body.zebra_message.notify_len; i++) { >+ printf(" %02x", entry->body.zebra_message.notify_data[i]); >+ } >+ printf("\n"); >+ break; >+ default: >+ break; >+ } >+ break; >+ >+ case BGPDUMP_SUBTYPE_ZEBRA_BGP_STATE_CHANGE: >+ printf("SUBTYPE : Zebra BGP State Change\n"); >+ printf(" SOURCE_AS : %u\n",entry->body.zebra_state_change.source_as); >+ printf(" DEST_AS : %u\n",entry->body.zebra_state_change.destination_as); >+ printf(" INTERFACE : %d\n",entry->body.zebra_state_change.interface_index); >+ printf(" SOURCE_IP : %s\n",source_ip); >+ printf(" DEST_IP : %s\n",destination_ip); >+ printf(" OLD_STATE : %s\n",bgp_state_name[entry->body.zebra_state_change.old_state]); >+ printf(" NEW_STATE : %s\n",bgp_state_name[entry->body.zebra_state_change.new_state]); >+ show_attr(entry->attr); >+ break; >+ >+ default: >+ printf("SUBTYPE : Unknown %d\n", entry->subtype); >+ } >+ show_attr(entry->attr); >+ break; >+ default: >+ printf("TYPE : Unknown %d\n", entry->type); >+ show_attr(entry->attr); >+ >+ } >+ printf("\n"); >+} >+ >+void show_attr(attributes_t *attr) { >+ int have_nexthop = 0; >+ printf("ATTRIBUTES :\n"); >+ >+ if(attr != NULL) { >+ printf(" ATTR_LEN : %d\n",attr->len); >+ >+ if( (attr->flag & ATTR_FLAG_BIT (BGP_ATTR_ORIGIN) ) !=0 ) printf(" ORIGIN : %d\n",attr->origin); >+ else printf(" ORIGIN : N/A\n"); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_AS_PATH) ) !=0) printf(" ASPATH : %s\n",attr->aspath->str); >+ else printf(" ASPATH : N/A\n"); >+ >+ printf(" NEXT_HOP : "); >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_NEXT_HOP) ) !=0) { >+ have_nexthop = 1; >+ printf("%s", inet_ntoa(attr->nexthop)); >+ } >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MP_REACH_NLRI)) && >+ MP_IPV6_ANNOUNCE(attr->mp_info) != NULL) { >+ char addr[INET6_ADDRSTRLEN]; >+ struct mp_nlri *mp_nlri = MP_IPV6_ANNOUNCE(attr->mp_info); >+ u_int8_t len = mp_nlri->nexthop_len; >+ >+ if(have_nexthop) >+ printf(" "); >+ >+ have_nexthop = 1; >+ printf("%s", inet_ntop(AF_INET6, &mp_nlri->nexthop, addr, sizeof(addr))); >+ if(len == 32) >+ printf(" %s", inet_ntop(AF_INET6, &mp_nlri->nexthop_local, addr, sizeof(addr))); >+ } >+#endif >+ >+ printf(have_nexthop ? "\n" : "N/A\n"); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_MULTI_EXIT_DISC) ) !=0) printf(" MED : %d\n",attr->med); >+ else printf(" MED : N/A\n"); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_LOCAL_PREF) ) !=0) printf(" LOCAL_PREF : %d\n",attr->local_pref); >+ else printf(" LOCAL_PREF : N/A\n"); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_ATOMIC_AGGREGATE) ) !=0) printf(" ATOMIC_AGREG : Present\n"); >+ else printf(" ATOMIC_AGREG : N/A\n"); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_AGGREGATOR) ) !=0) printf(" AGGREGATOR : %s AS%u\n",inet_ntoa(attr->aggregator_addr),attr->aggregator_as); >+ else printf(" AGGREGATOR : N/A\n"); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_COMMUNITIES) ) !=0) printf(" COMMUNITIES : %s\n",attr->community->str); >+ else printf(" COMMUNITIES : N/A\n"); >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_NEW_AS_PATH) ) !=0) { >+ printf(" NEW_ASPATH : %s\n",attr->new_aspath->str); >+ printf(" OLD_ASPATH : %s\n",attr->old_aspath->str); >+ } >+ >+ if( (attr->flag & ATTR_FLAG_BIT(BGP_ATTR_NEW_AGGREGATOR) ) !=0) printf(" NEW_AGGREGTR : %s AS%u\n",inet_ntoa(attr->new_aggregator_addr),attr->new_aggregator_as); >+ } >+} >+ >+void show_prefixes(int count,struct prefix *prefix) { >+ int i; >+ for(i=0;i<count;i++) >+ printf(" %s/%d\n",inet_ntoa(prefix[i].address.v4_addr),prefix[i].len); >+} >+ >+#ifdef BGPDUMP_HAVE_IPV6 >+void show_v6_prefixes(int count, struct prefix *prefix) { >+ int i; >+ char str[INET6_ADDRSTRLEN]; >+ >+ for(i=0;i<count;i++){ >+ inet_ntop(AF_INET6, &prefix[i].address.v6_addr, str, sizeof(str)); >+ printf(" %s/%d\n",str, prefix[i].len); >+ } >+} >+#endif >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/inet_ntop.c libbgpdump-new/work/libbgpdump-1.4.99.15/inet_ntop.c >--- libbgpdump/work/libbgpdump-1.4.99.15/inet_ntop.c 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/inet_ntop.c 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,259 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+*/ >+ >+/* >+ * Copyright (c) 2000 Apple Computer, Inc. All rights reserved. >+ * >+ * @APPLE_OSREFERENCE_LICENSE_HEADER_START@ >+ * >+ * This file contains Original Code and/or Modifications of Original Code >+ * as defined in and that are subject to the Apple Public Source License >+ * Version 2.0 (the 'License'). You may not use this file except in >+ * compliance with the License. The rights granted to you under the License >+ * may not be used to create, or enable the creation or redistribution of, >+ * unlawful or unlicensed copies of an Apple operating system, or to >+ * circumvent, violate, or enable the circumvention or violation of, any >+ * terms of an Apple operating system software license agreement. >+ * >+ * Please obtain a copy of the License at >+ * http://www.opensource.apple.com/apsl/ and read it before using this file. >+ * >+ * The Original Code and all software distributed under the License are >+ * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER >+ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, >+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, >+ * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. >+ * Please see the License for the specific language governing rights and >+ * limitations under the License. >+ * >+ * @APPLE_OSREFERENCE_LICENSE_HEADER_END@ >+ */ >+ >+/* >+ * Copyright 1994, 1995 Massachusetts Institute of Technology >+ * >+ * Permission to use, copy, modify, and distribute this software and >+ * its documentation for any purpose and without fee is hereby >+ * granted, provided that both the above copyright notice and this >+ * permission notice appear in all copies, that both the above >+ * copyright notice and this permission notice appear in all >+ * supporting documentation, and that the name of M.I.T. not be used >+ * in advertising or publicity pertaining to distribution of the >+ * software without specific, written prior permission. M.I.T. makes >+ * no representations about the suitability of this software for any >+ * purpose. It is provided "as is" without express or implied >+ * warranty. >+ * >+ * THIS SOFTWARE IS PROVIDED BY M.I.T. ``AS IS''. M.I.T. DISCLAIMS >+ * ALL EXPRESS OR IMPLIED WARRANTIES WITH REGARD TO THIS SOFTWARE, >+ * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF >+ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT >+ * SHALL M.I.T. BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, >+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT >+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF >+ * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND >+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, >+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT >+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF >+ * SUCH DAMAGE. >+ */ >+ >+#include <sys/param.h> >+#include <netinet/in.h> >+#include <string.h> >+#include <stdio.h> >+#include <stdbool.h> >+#include <assert.h> >+#include <sys/types.h> >+#include <sys/socket.h> >+#include <arpa/inet.h> >+ >+#include "util.h" >+ >+const char OCTETS[][4] = { >+ "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", >+ "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "27", "28", "29", "30", "31", >+ "32", "33", "34", "35", "36", "37", "38", "39", "40", "41", "42", "43", "44", "45", "46", "47", >+ "48", "49", "50", "51", "52", "53", "54", "55", "56", "57", "58", "59", "60", "61", "62", "63", >+ "64", "65", "66", "67", "68", "69", "70", "71", "72", "73", "74", "75", "76", "77", "78", "79", >+ "80", "81", "82", "83", "84", "85", "86", "87", "88", "89", "90", "91", "92", "93", "94", "95", >+ "96", "97", "98", "99", >+ "100", "101", "102", "103", "104", "105", "106", "107", "108", "109", >+ "110", "111", "112", "113", "114", "115", "116", "117", "118", "119", "120", "121", "122", >+ "123", "124", "125", "126", "127", "128", "129", "130", "131", "132", "133", "134", "135", >+ "136", "137", "138", "139", "140", "141", "142", "143", "144", "145", "146", "147", "148", >+ "149", "150", "151", "152", "153", "154", "155", "156", "157", "158", "159", "160", "161", >+ "162", "163", "164", "165", "166", "167", "168", "169", "170", "171", "172", "173", "174", >+ "175", "176", "177", "178", "179", "180", "181", "182", "183", "184", "185", "186", "187", >+ "188", "189", "190", "191", "192", "193", "194", "195", "196", "197", "198", "199", "200", >+ "201", "202", "203", "204", "205", "206", "207", "208", "209", "210", "211", "212", "213", >+ "214", "215", "216", "217", "218", "219", "220", "221", "222", "223", "224", "225", "226", >+ "227", "228", "229", "230", "231", "232", "233", "234", "235", "236", "237", "238", "239", >+ "240", "241", "242", "243", "244", "245", "246", "247", "248", "249", "250", "251", "252", >+ "253", "254", "255" >+}; >+ >+char *fmt_ipv4(BGPDUMP_IP_ADDRESS addr, char *buffer) >+{ >+ assert(buffer); >+ uint8_t *ap = (uint8_t *)&addr.v4_addr.s_addr; >+ >+ int pos = 0; >+ int i; >+ for(i = 0; i < 4; ++i) { >+ const char *octet = OCTETS[ap[i]]; >+ buffer[pos++] = octet[0]; >+ octet[1] ? buffer[pos++] = octet[1] : (void)0; >+ octet[2] ? buffer[pos++] = octet[2] : (void)0; >+ buffer[pos++] = '.'; >+ } >+ >+ buffer[pos - 1] = '\0'; >+ >+ return buffer; >+} >+ >+char *fmt_ipv6(BGPDUMP_IP_ADDRESS addr, char *buffer) >+{ >+ static const char hexchars[] = "0123456789abcdef"; >+ >+ assert(buffer); >+ >+ /* check for mapped or compat addresses */ >+ bool m = IN6_IS_ADDR_V4MAPPED(&addr.v6_addr); >+ bool c = IN6_IS_ADDR_V4COMPAT(&addr.v6_addr); >+ if (m || c) { >+ char buffer2[100]; >+ BGPDUMP_IP_ADDRESS mapped = { .v4_addr.s_addr = ((uint32_t *)addr.v6_addr.s6_addr)[3] }; >+ >+ sprintf(buffer, "::%s%s", m ? "ffff:" : "", fmt_ipv4(mapped, buffer2)); >+ return buffer; >+ } >+ >+ char hexa[8][5]; >+ int zr[8]; >+ size_t len; >+ uint8_t x8, hx8; >+ uint16_t x16; >+ >+ int i, k = 0; >+ for (i = 0; i < 16; i += 2) { >+ int j = 0; >+ bool skip = 1; >+ >+ memset(hexa[k], 0, 5); >+ >+ x8 = addr.v6_addr.s6_addr[i]; >+ >+ hx8 = x8 >> 4; >+ if (hx8 != 0) >+ { >+ skip = 0; >+ hexa[k][j++] = hexchars[hx8]; >+ } >+ >+ hx8 = x8 & 0x0f; >+ if ((skip == 0) || ((skip == 1) && (hx8 != 0))) >+ { >+ skip = 0; >+ hexa[k][j++] = hexchars[hx8]; >+ } >+ >+ x8 = addr.v6_addr.s6_addr[i + 1]; >+ >+ hx8 = x8 >> 4; >+ if ((skip == 0) || ((skip == 1) && (hx8 != 0))) >+ { >+ hexa[k][j++] = hexchars[hx8]; >+ } >+ >+ hx8 = x8 & 0x0f; >+ hexa[k][j] = hexchars[hx8]; >+ >+ k++; >+ } >+ >+ /* find runs of zeros for :: convention */ >+ int j = 0; >+ for (i = 7; i >= 0; i--) >+ { >+ zr[i] = j; >+ x16 = ((uint16_t *)addr.v6_addr.s6_addr)[i]; >+ if (x16 == 0) j++; >+ else j = 0; >+ zr[i] = j; >+ } >+ >+ /* find longest run of zeros */ >+ k = -1; >+ j = 0; >+ for(i = 0; i < 8; i++) >+ { >+ if (zr[i] > j) >+ { >+ k = i; >+ j = zr[i]; >+ } >+ } >+ >+ for(i = 0; i < 8; i++) >+ { >+ if (i != k) zr[i] = 0; >+ } >+ >+ len = 0; >+ for (i = 0; i < 8; i++) >+ { >+ if (zr[i] != 0) >+ { >+ /* check for leading zero */ >+ if (i == 0) >+ buffer[len++] = ':'; >+ buffer[len++] = ':'; >+ i += (zr[i] - 1); >+ continue; >+ } >+ for (j = 0; hexa[i][j] != '\0'; j++) >+ buffer[len++] = hexa[i][j]; >+ if (i != 7) >+ buffer[len++] = ':'; >+ } >+ >+ buffer[len] = '\0'; >+ >+ return buffer; >+} >+ >+static void test_roundtrip(char *str) >+{ >+ BGPDUMP_IP_ADDRESS addr; >+ inet_pton(AF_INET6, str, &addr.v6_addr); >+ char tmp[1000]; >+ fmt_ipv6(addr, tmp); >+ printf("%s -> %s [%s]\n", str, tmp, strcmp(str, tmp) ? "ERROR" : "ok"); >+} >+ >+void test_fmt_ip() >+{ >+ test_roundtrip("fe80::"); >+ test_roundtrip("2001:db8::1"); >+ test_roundtrip("::ffff:192.168.2.1"); >+ test_roundtrip("::192.168.1.2"); >+ test_roundtrip("2001:7f8:30::2:1:0:8447"); >+} >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/util.c libbgpdump-new/work/libbgpdump-1.4.99.15/util.c >--- libbgpdump/work/libbgpdump-1.4.99.15/util.c 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/util.c 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,93 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+ Created by Devin Bayer on 9/1/10. >+*/ >+ >+#include "util.h" >+ >+#include <stdlib.h> >+#include <stdio.h> >+#include <stdarg.h> >+#include <assert.h> >+#include <stdbool.h> >+#include <syslog.h> >+#include <time.h> >+#include <string.h> >+ >+static bool use_syslog = true; >+ >+void log_to_syslog() { >+ use_syslog = true; >+} >+ >+void log_to_stderr() { >+ use_syslog = false; >+} >+ >+#define log(lvl, lvl_str) \ >+ va_list args; \ >+ va_start(args, fmt); \ >+ _log(LOG_##lvl, #lvl_str, fmt, args) >+ >+static char *now_str() { >+ static char buffer[1000]; >+ time_t now = time(0); >+ strftime(buffer, sizeof buffer, "%Y-%m-%d %H:%M:%S", localtime(&now)); >+ return buffer; >+} >+ >+static void _log(int lvl, char *lvl_str, const char *fmt, va_list args) { >+ if(use_syslog) { >+ syslog(lvl, fmt, args); >+ } else { >+ char prefix[strlen(fmt) + 1000]; >+ sprintf(prefix, "%s [%s] %s\n", now_str(), lvl_str, fmt); >+ vfprintf(stderr, prefix, args); >+ } >+} >+ >+void err(const char *fmt, ...) { log(ERR, error); } >+void warn(const char *fmt, ...) { log(WARNING, warn); } >+void debug(const char *fmt, ...) { log(INFO, info); } >+ >+void time2str(struct tm* date,char *time_str) >+{ >+ sprintf(time_str, "%02d/%02d/%02d %02d:%02d:%02d", date->tm_mon+1, date->tm_mday, date->tm_year%100, >+ date->tm_hour, date->tm_min, date->tm_sec); >+} >+ >+int int2str(uint32_t value, char* str) >+{ >+ return sprintf(str, "%u", value); >+} >+ >+static void ti2s(uint32_t value) { >+ char buf[100], ref[100]; >+ sprintf(ref, "%u", value); >+ int len = int2str(value, buf); >+ printf("%s =?= %s (%i)\n", ref, buf, len); >+} >+ >+void test_utils() >+{ >+ ti2s(0); >+ ti2s(99999); >+ ti2s(4294967295L); >+} >+ >diff -uNr libbgpdump/work/libbgpdump-1.4.99.15/util.h libbgpdump-new/work/libbgpdump-1.4.99.15/util.h >--- libbgpdump/work/libbgpdump-1.4.99.15/util.h 1970-01-01 12:00:00.000000000 +1200 >+++ libbgpdump-new/work/libbgpdump-1.4.99.15/util.h 2015-07-17 03:16:25.000000000 +1200 >@@ -0,0 +1,45 @@ >+/* >+ Copyright (c) 2007 - 2010 RIPE NCC - All Rights Reserved >+ >+ Permission to use, copy, modify, and distribute this software and its >+ documentation for any purpose and without fee is hereby granted, provided >+ that the above copyright notice appear in all copies and that both that >+ copyright notice and this permission notice appear in supporting >+ documentation, and that the name of the author not be used in advertising or >+ publicity pertaining to distribution of the software without specific, >+ written prior permission. >+ >+ THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING >+ ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS; IN NO EVENT SHALL >+ AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY >+ DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN >+ AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF >+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. >+ >+ Created by Devin Bayer on 9/1/10. >+*/ >+ >+#ifndef _UTIL_H >+#define _UTIL_H >+#include <time.h> >+ >+#include "bgpdump_attr.h" >+ >+void log_to_stderr(void); >+void log_to_syslog(void); >+ >+void err(const char *fmt, ...) __attribute__((format(printf, 1, 2))); >+void warn(const char *fmt, ...) __attribute__((format(printf, 1, 2))); >+void debug(const char *fmt, ...) __attribute__((format(printf, 1, 2))); >+ >+// system inet_ntop() functions format IPv6 addresses >+// inconsistently, so use these versions >+char *fmt_ipv4(BGPDUMP_IP_ADDRESS addr, char *buffer); >+char *fmt_ipv6(BGPDUMP_IP_ADDRESS addr, char *buffer); >+void test_fmt_ip(void); >+ >+void time2str(struct tm* date,char *time_str); >+int int2str(uint32_t value, char* str); >+void test_utils(void); >+ >+#endif
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 203182
:
161155
|
161156