… | |
… | |
14 | EOF |
14 | EOF |
15 | exit 1; |
15 | exit 1; |
16 | } |
16 | } |
17 | |
17 | |
18 | print "*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***\n\n"; |
18 | print "*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***\n\n"; |
19 | |
|
|
20 | if ($] < 5.006) { |
|
|
21 | print <<EOF; |
|
|
22 | |
|
|
23 | *** |
|
|
24 | *** WARNING: This module is quite low-level and uses undocumented perl |
|
|
25 | *** internals to do it's job. While it seems to work fine with perl-5.[6-10] |
|
|
26 | *** it has not been tested with older versions. If it compiles and passes the |
|
|
27 | *** testsuite, it should work. Otherwise you should either upgrade or fix it ;) |
|
|
28 | *** |
|
|
29 | *** Marc Lehmann <schmorp\@schmorp.de> |
|
|
30 | *** |
|
|
31 | |
|
|
32 | EOF |
|
|
33 | } |
|
|
34 | |
19 | |
35 | if (eval { require Event }) { |
20 | if (eval { require Event }) { |
36 | if ($Event::VERSION < 0.86 or $Event::VERSION == 0.88) { |
21 | if ($Event::VERSION < 0.86 or $Event::VERSION == 0.88) { |
37 | print <<EOF |
22 | print <<EOF |
38 | |
23 | |
… | |
… | |
49 | $EVENT = 1; |
34 | $EVENT = 1; |
50 | $DEFINE .= " -DHAVE_EVENT=1"; |
35 | $DEFINE .= " -DHAVE_EVENT=1"; |
51 | print "\nEvent version $Event::VERSION found, building Event support.\n\n"; |
36 | print "\nEvent version $Event::VERSION found, building Event support.\n\n"; |
52 | } |
37 | } |
53 | } else { |
38 | } else { |
54 | print "\n*** Event not found, not build Event support.\n\n"; |
39 | print "\n*** Event not found, not building Event support.\n\n"; |
55 | } |
40 | } |
56 | |
41 | |
57 | if (eval { require EV }) { |
42 | if (eval { require EV }) { |
58 | if ($EV::VERSION < 3.3) { |
43 | if ($EV::VERSION < 3.3) { |
59 | print <<EOF |
44 | print <<EOF |
60 | |
45 | |
61 | *** |
46 | *** |
62 | *** WARNING: Event version $EV::VERSION found, NOT building EV support. |
47 | *** WARNING: EV version $EV::VERSION found, NOT building EV support. |
63 | *** |
48 | *** |
64 | *** This version is ABI-incompatible with Coro, please upgrade to at least 3.3. |
49 | *** This version is ABI-incompatible with Coro, please upgrade to at least 3.3. |
65 | *** |
50 | *** |
66 | |
51 | |
67 | EOF |
52 | EOF |
… | |
… | |
69 | $EV = 1; |
54 | $EV = 1; |
70 | $DEFINE .= " -DHAVE_EV=1"; |
55 | $DEFINE .= " -DHAVE_EV=1"; |
71 | print "\nEV version $EV::VERSION found, building EV support.\n\n"; |
56 | print "\nEV version $EV::VERSION found, building EV support.\n\n"; |
72 | } |
57 | } |
73 | } else { |
58 | } else { |
74 | print "\n*** EV not found, not build EV support.\n\n"; |
59 | print "\n*** EV not found, not building EV support.\n\n"; |
75 | } |
60 | } |
76 | |
61 | |
77 | WriteMakefile( |
62 | WriteMakefile( |
78 | dist => { |
63 | dist => { |
79 | PREOP => 'pod2text Coro.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;', |
64 | PREOP => 'pod2text Coro.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;', |
… | |
… | |
84 | VERSION_FROM => "Coro.pm", |
69 | VERSION_FROM => "Coro.pm", |
85 | DIR => ['Coro', ($EVENT ? 'Event' : ()), ($EV ? "EV" : ())], |
70 | DIR => ['Coro', ($EVENT ? 'Event' : ()), ($EV ? "EV" : ())], |
86 | PREREQ_PM => { |
71 | PREREQ_PM => { |
87 | common::sense => 0, |
72 | common::sense => 0, |
88 | Scalar::Util => 0.00, |
73 | Scalar::Util => 0.00, |
89 | AnyEvent => 4.81, |
74 | AnyEvent => 5.0, |
90 | Storable => 2.15, |
75 | Storable => 2.15, |
91 | Time::HiRes => 0, |
76 | Time::HiRes => 0, |
92 | Guard => 0.5, |
77 | Guard => 0.5, |
93 | |
78 | |
94 | # for Coro::Event |
79 | # for Coro::Event |
… | |
… | |
97 | # for Coro::EV |
82 | # for Coro::EV |
98 | #EV => 3.3, |
83 | #EV => 3.3, |
99 | |
84 | |
100 | # for Coro::AIO |
85 | # for Coro::AIO |
101 | #IO::AIO => 2.3, |
86 | #IO::AIO => 2.3, |
102 | #AnyEvent::AIO => 1.0, |
87 | #AnyEvent::AIO => 1.1, |
103 | |
88 | |
104 | # for Coro::BDB |
89 | # for Coro::BDB |
105 | #BDB => 1.5, |
90 | #BDB => 1.5, |
106 | #AnyEvent::BDB => 1.0, |
91 | #AnyEvent::BDB => 1.0, |
107 | }, |
92 | }, |
… | |
… | |
121 | }, |
106 | }, |
122 | PM => { |
107 | PM => { |
123 | 'Coro.pm' => '$(INST_LIBDIR)/Coro.pm', |
108 | 'Coro.pm' => '$(INST_LIBDIR)/Coro.pm', |
124 | |
109 | |
125 | 'Coro/State.pm' => '$(INST_LIBDIR)/Coro/State.pm', |
110 | 'Coro/State.pm' => '$(INST_LIBDIR)/Coro/State.pm', |
|
|
111 | 'Coro/jit-amd64-unix.pl' => '$(INST_LIBDIR)/Coro/jit-amd64-unix.pl', |
126 | |
112 | |
127 | 'Coro/MakeMaker.pm' => '$(INST_LIBDIR)/Coro/MakeMaker.pm', |
113 | 'Coro/MakeMaker.pm' => '$(INST_LIBDIR)/Coro/MakeMaker.pm', |
128 | 'Coro/CoroAPI.h' => '$(INST_LIBDIR)/Coro/CoroAPI.h', |
114 | 'Coro/CoroAPI.h' => '$(INST_LIBDIR)/Coro/CoroAPI.h', |
129 | |
115 | |
130 | # 'Coro/Cont.pm' => '$(INST_LIBDIR)/Coro/Cont.pm', |
116 | # 'Coro/Cont.pm' => '$(INST_LIBDIR)/Coro/Cont.pm', |