Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 16 Jan 2016 04:43:15 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-ports-bugs@FreeBSD.org
Subject:   [Bug 206304] net-mgmt/net-snmp [PATCH] Optionalize libpkg support to better support libressl
Message-ID:  <bug-206304-13@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D206304

            Bug ID: 206304
           Summary: net-mgmt/net-snmp [PATCH] Optionalize libpkg support
                    to better support libressl
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Keywords: patch
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: zi@FreeBSD.org
          Reporter: mcdouga9@egr.msu.edu
          Assignee: zi@FreeBSD.org
          Keywords: patch
             Flags: maintainer-feedback?(zi@FreeBSD.org)

Created attachment 165650
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D165650&action=
=3Dedit
Patch to make libpkg support optional

I am submitting this patch so the "pkg" support in net-snmp can be disabled
using a compile option on the port.  Aside from the obvious effect, it can =
help
avoid a SSL library conflict.

I build all my packages in a customized poudriere jail that has NO openssl =
or
libressl support in it at all because I expect my compiled packages to pull=
 in
libressl.  I do this to avoid any chance of accidentally using openssl from
base or having software link to both openssl and libressl.  net-snmp will l=
ink
with both libressl and openssl because a currently non-optional patch adds
-lpkg.  pkg is currently required to compile with openssl, at least without=
 a
lot of work.=20=20

In a jail without base openssl like mine, trying to compile net-snmp fails
because -lpkg is used unconditionally and libpkg cannot find the openssl
library it had been linked against.  This example is represented by the
net-snmp-5.7.3_12-LIBPKG.log poudriere log that I will attach showing the
default behavior on my jail (but from my updated port).  Some site-specific
make.conf customization has been removed to avoid revealing too much about =
our
site.

net-snmp-5.7.3_12-noLIBPKG.log is an example where I've UNSET the new LIBPKG
compile option which causes it to skip using the patch which adds -lpkg to =
the
compile.  You can see in the log where it skips the patch
extra-patch-agent_Makefile.in which I renamed from patch-agent_Makefile.in.=
=20
Again in this log I skipped some site-specific make.conf customization.

I tested that the patch applies cleanly to the port, I tested it in poudrie=
re
and attached logs, I bumped the PORTREVISION.  I attempted to use a newer
"options helper" LIBPKG_EXTRA_PATCHES but I could not get it to work.  I
resorted to a 3 line .if conditional which matches the style from the rest =
of
the Makefile.

Please consider applying this to the port so I don't have to "rm
/usr/ports/net-mgmt/net-snmp/files/patch-agent_Makefile.in" every time I svn
update ports (or at minimum each time net-snmp updates, but easier to remem=
ber
to always do it).   I am willing to make changes and discuss if needed.=20
Thanks.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-206304-13>