Bug 816544 - Circular build dependency in perl-AnyEvent-6.14-2.fc18
Circular build dependency in perl-AnyEvent-6.14-2.fc18
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: perl-AnyEvent (Show other bugs)
rawhide
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Paul Howarth
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-04-26 07:12 EDT by Paul Howarth
Modified: 2012-04-26 14:40 EDT (History)
2 users (show)

See Also:
Fixed In Version: perl-AnyEvent-7.0-1.fc18
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-04-26 14:40:15 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Paul Howarth 2012-04-26 07:12:38 EDT
perl-AnyEvent buildrequires perl(EV) for its test suite, but perl-EV also buildrequires perl(AnyEvent) for its test suite, forming a circular build dependency loop, which is an issue when bootstrapping new architectures or major new Perl versions.

Wrapping the BR: perl(EV) with a %{?perl_bootstrap} conditional will alleviate this:

diff --git a/perl-AnyEvent.spec b/perl-AnyEvent.spec
index 242e4a2..15c50a3 100644
--- a/perl-AnyEvent.spec
+++ b/perl-AnyEvent.spec
@@ -14,11 +14,16 @@ BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 #FYI this went arch specific since 6.14
 #BuildArch:      noarch
 BuildRequires:  perl(ExtUtils::MakeMaker)
-#Default recommanded loop
+#Default recommended loop
+%if 0%{!?perl_bootstrap:1}
 BuildRequires:  perl(EV)
+%endif
 # Needed for test
 BuildRequires:  perl(Test::Simple)
 
+# A noarch-turned-arch package should not have debuginfo
+%global debug_package %{nil}
+
 # RPM 4.8 style
 %{?filter_setup:
 %filter_from_requires /perl(Tk)/d; /perl(EV)/d; /perl(Irssi)/d; /perl(Qt/d; /perl(IO::Async::Loop/d; /perl(AnyEvent::Impl::Qt/d; /perl(FLTK


(no point having an empty debuginfo package either, hence the other change included above).


Whilst I'm here, I'd also like to see some more dependencies filtered. Upstream's viewpoint is that users should be able to whichever event loop they like, and there shouldn't be explicit dependencies on particular event loops, as described in Makefile.PL:

*** This module does not have ANY dependencies, even if it might look
*** otherwise. If you are building a distribution package or have
*** difficulties installing this package due to dependencies, report this
*** to the packager as a bug


So I think the following dependencies should be filtered:
REQUIRES perl(Event)  
REQUIRES perl(Event::Lib)  
REQUIRES perl(Glib) >= 1.210
REQUIRES perl(Net::SSLeay)  
REQUIRES perl(POE)

The Net::SSLeay one isn't actually an event loop, so perhaps a more appropriate fix for that would be to make a sub-package for perl-AnyEvent-TLS, though AnyEvent::Handle also makes extensive use of Net::SSLeay via a "require", so I'm not sure how well that would work.
Comment 1 Nicolas Chauvet (kwizart) 2012-04-26 07:32:45 EDT
Thx for the report. Please apply your changes.

I don't think it worth to also filter perl(Net::SSLeay) and maybe It be interesting to add it to the BR also. But then the test case must pass. (need to be tested).
Comment 2 Paul Howarth 2012-04-26 08:32:32 EDT
(In reply to comment #1)
> Thx for the report. Please apply your changes.

OK, will do, with the exception of filtering perl(Net::SSLeay)

> I don't think it worth to also filter perl(Net::SSLeay) and maybe It be
> interesting to add it to the BR also. But then the test case must pass. (need
> to be tested).

The test case passes when patched for OpenSSL 1.0.1:
https://rt.cpan.org/Public/Bug/Display.html?id=75343

Are you interested in supporting distros prior to Fedora 15 with the spec? If not, it could be cleaned up by removing buildroot boilerplate, pre-rpm-4.9 filtering etc.

Other event loop tests could be enabled by adding further buildreqs:
* perl(Event)
* perl(Event::Lib)
* perl(POE) >= 1.312 [f16 or later]
* perl(Tk)

Upstream also recommends an explicit require of Task::Weaken.

I can add all of these too if you like.
Comment 3 Nicolas Chauvet (kwizart) 2012-04-26 10:13:07 EDT
I'm fine with fixing this version. But actually I've only updated to 6.xx AnyEvent to make the update easier (which was not). It might be possible to update to current 7.0. for rawhide.

Then compatibilities be stripped down from.

Also testing others loop seems appropriate once the correct bootstrap option is set.

perl(Task::Weaken) doesn't cost much dependencies, so if it's recommanded, it probably worth to have in all cases.

Thx for your work.
Also I would appreciate another maintainer specifically for this package. Because it's more like a bridge between several components and ends to be a core piece.
Comment 4 Paul Howarth 2012-04-26 10:22:27 EDT
I can do the update to 7.0; I have a local build already:

http://www.city-fan.org/cfo-trac/browser/perl-AnyEvent/trunk/perl-AnyEvent.spec

I took the co-maintainer hint too :-)

I'll try to get the update/strip-down down later today.
Comment 5 Paul Howarth 2012-04-26 14:40:15 EDT
Build dependency cycle resolved in perl-AnyEvent-7.0-1.fc18; it builds in pass 5 of a bootstrap rebuild (see http://www.city-fan.org/~paul/perl-boot/buildorder).

Note You need to log in before you can comment on or make changes to this bug.