[quagga-dev 3644] time to deprecate ucd-snmp?

Greg Troxel gdt at ir.bbn.com
Wed Sep 14 14:21:40 BST 2005

  [Boris asks about configure finding libnetsnmp and using LIBS in the
  environment to configure]

I think the configure script is broken, so I'm not at all averse to
changing it.

LIBS is an internal configure variable, and it's perhaps a bug that
configure uses the env variable, or perhaps a feature.  I'd expect
that on FreeBSD either

  * /usr/local/include is in default CPPFLAGS and /usr/locla/lib in
    default LDFLAGS (with -L, -R etc.)


  * ports invokes configure with CPPFLAGS and LDFLAGS set to include

On NetBSD pkgsrc, /usr/local is not in the default paths (and /usr/pkg
isn't either).  pkgsrc wrappers called buildlink3 create a shadow link
tree with the includes and libs from packages explicitly configured as
dependencies, and then tool wrapper scripts (e.g. cc) look in the
shadow tree instead of the real filesystem.  This isolate the package
build from random things on the system, including only what the
packager explicitly specified.  This is complex, but necessary in
order to avoid producing a binary package that actually depends on
something but does not list it as a dependency.  Looking in /usr/local
breaks this model, which is one unintended consequence I'm trying to

So, I think the right thing is for configure.ac to just use something
like AC_CHECK_HEADERS and AC_CHECK_LIB, which will try to compile a
program against the library, and if it succeeds include it as a
library.  It may be desirable to add complexity to keep the netsnmp
library out of the link of the other daemons, but IMHO having that
extra is a lesser evil than the current mess.

I see that the AC_CHECK_LIB style is partially followed, and all the
mess is in handling snmp headers in various places.

A question for all: is it time to deprecate ucd-snmp?  I get the
impression (but I'm not paying attention so am unsure) that net-snmp
is the logical successor to ucd-snmp which is now considered crufty
and unmaintained.  In NetBSD pkgsrc (which is a noisy measure of what
the NetBSD folks feel is relevant :-), I see net-snmp and not
ucd-snmp.  Further, net-snmp is marked to conflict with the ucd-snmp
package - which does not exist but must have in the past.

So, I think we can simplify quagga by simply dropping support for
ucd-snmp and depending on net-snmp only.  Then, the whole "look in
/usr/local" bit can be avoided since AC_CHECK_HEADERS will just work.

More information about the Quagga-dev mailing list