Summary: | net-analyzer/smokeping bundles and conflicts with multiple Perl modules | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Jeremy Stent <stentj> |
Component: | New packages | Assignee: | Peter Volkov (RETIRED) <pva> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | brian, chtekk, infowolfe, joost.ruis, lame, mephinet, qa |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | AMD64 | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 251464 | ||
Attachments: |
emerge --info
Proposed fix ebuild Differences between 2.4.2 and my 2.4.2-r1 |
Description
Jeremy Stent
2009-02-24 20:36:05 UTC
Created attachment 183060 [details]
emerge --info
I just ran into this as well. JSON is going to be a major major headache, unless upstream smokeping gets involved. JSON 1.x (bundled _twice_ with smokeping) and JSON 2.x are incompatible. http://search.cpan.org/~makamaka/JSON-2.14/lib/JSON.pm#INCOMPATIBLE_CHANGES_TO_OLD_VERSION Most specific to smokeping, notice that all of JSONRPC is completely removed and you're told to use JSON::RPC instead (with a completely different interface). Same thing happening here on 2 different arches. * dev-perl/CGI-Session-4.36 * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Driver.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Driver/DBI.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Driver/db_file.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Driver/file.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Driver/mysql.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Driver/postgresql.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Driver/sqlite.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/ErrorHandler.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/ID/incr.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/ID/md5.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/ID/static.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Serialize/default.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Serialize/freezethaw.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Serialize/storable.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Test/Default.pm * /usr/lib/perl5/vendor_perl/5.8.8/CGI/Session/Tutorial.pm * * dev-perl/JSON-2.12 * /usr/lib/perl5/vendor_perl/5.8.8/JSON.pm * /usr/lib/perl5/vendor_perl/5.8.8/JSON/PP.pm * /usr/lib/perl5/vendor_perl/5.8.8/JSON/PP5005.pm * /usr/lib/perl5/vendor_perl/5.8.8/JSON/PP56.pm at least with perl 5.10, there is another conflict with dev-perl/SNMP_Session-0.92-r1: * /usr/lib64/perl5/vendor_perl/5.10.1/BER.pm * /usr/lib64/perl5/vendor_perl/5.10.1/SNMP_util.pm * /usr/lib64/perl5/vendor_perl/5.10.1/SNMP_Session.pm Confirmed SNMP_Session as well. This is getting a big problem, Peter can we fix this or should be dropped? There's an easy solution to these problems. Instead of pushing all of the upstream shipped libs into vendor_perl, give smokeping its own private library path where it won't interfere, and 'use lib $targetdir' I'll hopefully be working on this soon (within the next month). That would only solve half the issue (the conflicts) without solving the problem of bundling external libraries. (In reply to comment #8) > That would only solve half the issue (the conflicts) without solving the > problem of bundling external libraries. > Actually, the problem is a violation of perl 'best practice.' If you look at larger applications, such as otrs, they ship their own complete cpan-lib so that the application knows which versions of modules it depends on it's dealing with. The issue with JSON-2 api changes is known. If you've got a suggestion for where smokeping's cpan-lib should go, please share it. 59 # Install the CGI webserver scripts 60 sed 's:^use lib:#use lib:g' -i htdocs/*.cgi.dist These lines show that the maintainer has made the choice to completely disregard upstream's 'wishes' with regards to packaging upstream's shipped versions of Digest::HMAC, Config::Grammar, JSON-1, and CGI::Session. Comments from upstream in doc/smokeping_install.txt (best viewed w/ less||more||cat): bin/smokeping Make sure all the required libraries are available and the first line of the script points to your copy of perl. Adjust the use lib lines to point to your RRDtool installation and to the Smokeping/lib directory and edit the path of the config file to be in sync with reality. That looks like upstream intends for lib/* to not be installed in vendor_perl to me, thus removing all conflicts and causing the least amount of headache to its users. The issue is still there with latest smokeping-2.4.2 please fix it or mask smokeping? Did somebody actually contact upstream? Created attachment 225365 [details]
Proposed fix ebuild
Created attachment 225367 [details, diff]
Differences between 2.4.2 and my 2.4.2-r1
(In reply to comment #10) > That looks like upstream intends for lib/* to not be installed in vendor_perl > to me, thus removing all conflicts and causing the least amount of headache to > its users. > That's how we felt, and wrote an ebuild that moves them into /usr/lib/smokeping. I've attached the ebuild we use as a proposed fix (or at least for others to use until a better fix comes along.) Note that you'll probably want to turn off 'use warnings;', as it throws quite a lot of them due to prototype mismatches. dev-perl/CGI-Session and dev-perl/SNMP_Session now dropped from bundled libs and system version will be used. With dev-perl/JSON I think bloker is current solution until somebody suggest something better (like upstream patch to rename it to JSON1). FIXED. *** Bug 461902 has been marked as a duplicate of this bug. *** |