1 | PortSystem 1.0 |
---|
2 | name mod_hfs_apple |
---|
3 | version 1 |
---|
4 | categories www |
---|
5 | maintainers bchesneau@mac.com |
---|
6 | description mod_hfs_apple Apache module (enforce casing in URLs which need it) |
---|
7 | platforms darwin |
---|
8 | master_sites http://www.opensource.apple.com/darwinsource/10.2.6/apache_mod_hfs_apple |
---|
9 | distfiles mod_hfs_apple.c |
---|
10 | worksrcdir mod_hfs_apple |
---|
11 | checksums mod_hfs_apple.c md5 98c628a2a8b9e971fb77d497af14b621 |
---|
12 | |
---|
13 | use_configure no |
---|
14 | extract { |
---|
15 | file mkdir ${worksrcpath} |
---|
16 | system "cp ${distpath}/mod_hfs_apple.c ${worksrcpath}" |
---|
17 | } |
---|
18 | |
---|
19 | build { |
---|
20 | |
---|
21 | # where is apache ? |
---|
22 | if { [file readable ${prefix}/sbin/apxs] } { |
---|
23 | set APXS ${prefix}/sbin/apxs |
---|
24 | } elseif { [file readable ${prefix}/apache/bin/apxs] } { |
---|
25 | set APXS ${prefix}/apache/bin/apxs |
---|
26 | } else { |
---|
27 | depends_lib path:${prefix}/sbin/apxs:apache |
---|
28 | set APXS ${prefix}/sbin/apxs |
---|
29 | } |
---|
30 | |
---|
31 | cd ${worksrcpath} |
---|
32 | system "${APXS} -c -o mod_hfs_apple.so mod_hfs_apple.c" |
---|
33 | } |
---|
34 | |
---|
35 | destroot { |
---|
36 | if { [file readable ${prefix}/sbin/apxs] } { |
---|
37 | file mkdir ${destroot}${prefix}/libexec/apache |
---|
38 | system "install -m 755 ${worksrcpath}/mod_hfs_apple.so ${destroot}${prefix}/libexec/apache/" |
---|
39 | } else { |
---|
40 | file mkdir ${destroot}${prefix}/apache/libexec |
---|
41 | system "install -m 755 ${worksrcpath}/mod_hfs_apple.so ${destroot}${prefix}/apache/libexec/" |
---|
42 | } |
---|
43 | } |
---|
44 | |
---|
45 | post-destroot { |
---|
46 | system "apxs -i -a -n \"hfs_apple\" ${worksrcpath}/mod_hfs_apple.so" |
---|
47 | } |
---|