ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/Coro/Makefile.PL
Revision: 1.26
Committed: Fri Nov 24 15:34:33 2006 UTC (17 years, 5 months ago) by root
Content type: text/plain
Branch: MAIN
CVS Tags: stack_sharing
Changes since 1.25: +1 -1 lines
Log Message:
*** empty log message ***

File Contents

# Content
1 use ExtUtils::MakeMaker;
2
3 if ($] < 5.006) {
4 print <<EOF;
5
6 ***
7 *** WARNING: This module is quite low-level and uses undocumented perl
8 *** internals to do it's job. While it seems to work fine with perl-5.[6-9]
9 *** it has not been tested with older versions. If it compiles and passes the
10 *** testsuite, it should work. Otherwise you should either upgrade or fix it ;)
11 ***
12 *** Marc Lehmann <schmorp\@schmorp.de>
13 ***
14
15 EOF
16 }
17
18 if (eval { require Event }) {
19 if ($Event::VERSION < 0.86 or $Event::VERSION == 0.88) {
20 print <<EOF
21
22 ***
23 *** WARNING: Event version $Event::VERSION found, NOT building Event support.
24 ***
25 *** This version of Event is broken. The only currently known non-broken
26 *** versions of Event are 0.87 and 0.89+. Please install one of those
27 *** versions.
28 ***
29
30 EOF
31 } else {
32 $EVENT = 1;
33 $DEFINE .= " -DHAVE_EVENT=1";
34 print "\nEvent version $Event::VERSION found, building Event support.\n\n";
35 }
36 print "\n";
37 } else {
38 print "\n*** Event not found, not build Event support.\n\n";
39 }
40
41 WriteMakefile(
42 dist => {
43 PREOP => 'pod2text Coro.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
44 COMPRESS => 'gzip -9v',
45 SUFFIX => '.gz',
46 },
47 NAME => "Coro",
48 VERSION_FROM => "Coro.pm",
49 DIR => ['Coro', ($EVENT ? 'Event' : ())],
50 PREREQ_PM => {
51 Scalar::Util => 0.00,
52
53 # for Coro::Event
54 Event => 0.86,
55
56 # for Coro::AIO, Coro::Util
57 IO::AIO => 1.6,
58 AnyEvent => 2.1,
59 },
60 PM => {
61 'Coro.pm' => '$(INST_LIBDIR)/Coro.pm',
62
63 'Coro/State.pm' => '$(INST_LIBDIR)/Coro/State.pm',
64
65 'Coro/MakeMaker.pm' => '$(INST_LIBDIR)/Coro/MakeMaker.pm',
66 'Coro/CoroAPI.h' => '$(INST_LIBDIR)/Coro/CoroAPI.h',
67
68 'Coro/Cont.pm' => '$(INST_LIBDIR)/Coro/Cont.pm',
69
70 'Coro/Specific.pm' => '$(INST_LIBDIR)/Coro/Specific.pm',
71
72 'Coro/Timer.pm' => '$(INST_LIBDIR)/Coro/Timer.pm',
73 'Coro/Signal.pm' => '$(INST_LIBDIR)/Coro/Signal.pm',
74 'Coro/Channel.pm' => '$(INST_LIBDIR)/Coro/Channel.pm',
75 'Coro/Semaphore.pm' => '$(INST_LIBDIR)/Coro/Semaphore.pm',
76 'Coro/SemaphoreSet.pm'=> '$(INST_LIBDIR)/Coro/SemaphoreSet.pm',
77 'Coro/RWLock.pm' => '$(INST_LIBDIR)/Coro/RWLock.pm',
78
79 'Coro/Util.pm' => '$(INST_LIBDIR)/Coro/Util.pm',
80 'Coro/Select.pm' => '$(INST_LIBDIR)/Coro/Select.pm',
81 'Coro/Handle.pm' => '$(INST_LIBDIR)/Coro/Handle.pm',
82 'Coro/Socket.pm' => '$(INST_LIBDIR)/Coro/Socket.pm',
83
84 'Coro/AIO.pm' => '$(INST_LIBDIR)/Coro/AIO.pm',
85 'Coro/LWP.pm' => '$(INST_LIBDIR)/Coro/LWP.pm',
86 },
87 );
88
89 sub MY::postamble {
90 <<EOF;
91
92 # set \$VERSION in all modules
93 setver:
94 \$(PERL) -pi -e 's/^(\\s*(our\\s*)?\\\$\$VERSION\\s*=\\s*).*\$\$/\$\${1}\$(VERSION);/' *.pm Coro/*.pm Event/*.pm
95
96 EOF
97 }
98
99