1 | PortSystem 1.0 |
---|
2 | name mod_perl |
---|
3 | version 1.29 |
---|
4 | revision 1.0 |
---|
5 | categories www |
---|
6 | platforms darwin freebsd |
---|
7 | maintainers bchesneau@mac.com |
---|
8 | description Embeds a Perl interpreter in the Apache server |
---|
9 | homepage http://perl.apache.org/ |
---|
10 | master_sites http://mirror.telentente.com/pub/apache/dist/perl/ \ |
---|
11 | http://apache.mirror.digitalspace.net/perl/ \ |
---|
12 | http://www.apache.inetcosmos.org/dist/perl/ \ |
---|
13 | http://www.rge.com/pub/infosystems/apache/perl/ \ |
---|
14 | http://mirrors.ccs.neu.edu/Apache/dist/perl/ |
---|
15 | |
---|
16 | checksums mod_perl-1.29.tar.gz md5 1491931790509b9af06fc037d02b0e7a |
---|
17 | depends_lib bin:${prefix}/perl5\.8\.4:perl5.8 |
---|
18 | |
---|
19 | |
---|
20 | |
---|
21 | platform darwin 6 { |
---|
22 | depends_lib-append lib:libdl.1:dlcompat |
---|
23 | |
---|
24 | if { ![variant_isset apache_layout] } { |
---|
25 | depends_lib-append path:${prefix}/sbin/apxs:apache |
---|
26 | } |
---|
27 | } |
---|
28 | |
---|
29 | platform darwin 7 { |
---|
30 | |
---|
31 | if { ![variant_isset apache_layout] } { |
---|
32 | depends_lib-append path:${prefix}/sbin/apxs:apache |
---|
33 | } |
---|
34 | } |
---|
35 | |
---|
36 | |
---|
37 | platform freebsd { |
---|
38 | if { ![variant_isset apache_layout] } { |
---|
39 | depends_lib-append path:${prefix}/sbin/apxs:apache |
---|
40 | } |
---|
41 | } |
---|
42 | |
---|
43 | variant apache_layout { |
---|
44 | depends_lib-append path:${prefix}/apache/bin/apxs:apache |
---|
45 | } |
---|
46 | |
---|
47 | |
---|
48 | configure.env LANG=C \ |
---|
49 | LC_ALL=C |
---|
50 | |
---|
51 | configure.pre_args |
---|
52 | configure { |
---|
53 | |
---|
54 | if { [variant_isset apache_layout] } { |
---|
55 | set APXS ${prefix}/apache/bin/apxs |
---|
56 | } else { |
---|
57 | set APXS ${prefix}/sbin/apxs |
---|
58 | } |
---|
59 | |
---|
60 | system "cd ${workpath}/${worksrcdir} && \ |
---|
61 | perl Makefile.PL USE_APXS=1 \ |
---|
62 | PREFIX=${prefix} \ |
---|
63 | WITH_APXS={APXS} EVERYTHING=1 \ |
---|
64 | PERL_EXTRA_CFLAGS='-DDEFAULT_PATH=\"/bin:/usr/bin:${prefix}/bin\"'" |
---|
65 | |
---|
66 | |
---|
67 | } |
---|
68 | |
---|
69 | destroot.target all pure_install doc_install |
---|
70 | |
---|
71 | post-destroot { |
---|
72 | |
---|
73 | if { [variant_isset apache_layout] } { |
---|
74 | file mkdir ${destroot}${prefix}/apache/include/modules/perl |
---|
75 | system "install -m 755 ${worksrcpath}/src/modules/perl/*.h \ |
---|
76 | ${destroot}${prefix}/apache/include/modules/perl" |
---|
77 | |
---|
78 | |
---|
79 | file mkdir ${destroot}${prefix}/apache/libexec |
---|
80 | system "install -m 755 ${worksrcpath}/apaci/libperl.so ${destroot}${prefix}/apache/libexec/" |
---|
81 | } else { |
---|
82 | file mkdir ${destroot}${prefix}/include/apache/modules/perl |
---|
83 | system "install -m 755 ${worksrcpath}/src/modules/perl/*.h \ |
---|
84 | ${destroot}${prefix}/include/apache/modules/perl" |
---|
85 | |
---|
86 | |
---|
87 | file mkdir ${destroot}${prefix}/libexec/apache |
---|
88 | system "install -m 755 ${worksrcpath}/apaci/libperl.so ${destroot}${prefix}/libexec/apache/" |
---|
89 | } |
---|
90 | |
---|
91 | cd ${destroot}${prefix}/lib/perl5/site_perl/5.8.4/darwin-2level/auto/mod_perl/ |
---|
92 | system "cat .packlist | sed s#${destroot}/#\/#g >.packlist.new" |
---|
93 | system "mv .packlist.new .packlist" |
---|
94 | |
---|
95 | |
---|
96 | } |
---|
97 | |
---|
98 | post-install { |
---|
99 | ui_msg "\nIf this your first install, you might want" |
---|
100 | ui_msg " * enable mod_perl in apache :\n" |
---|
101 | if { [variant_isset apache_layout] } { |
---|
102 | ui_msg "cd ${prefix}/apache/libexec" |
---|
103 | } else { |
---|
104 | ui_msg "cd ${prefix}/libexec/apache" |
---|
105 | } |
---|
106 | ui_msg "apxs -a -e -n \"perl\" libperl.so\n" |
---|
107 | ui_msg " * And then relaunch apache \n" |
---|
108 | ui_msg "apachectl graceful\n" |
---|
109 | } |
---|
110 | |
---|