1 | PortSystem 1.0 |
---|
2 | name phpmyadmin |
---|
3 | version 2.5.4 |
---|
4 | categories www |
---|
5 | maintainers bchesneau@mac.com |
---|
6 | description web-based utility to manage MySQL databases |
---|
7 | platforms darwin freebsd |
---|
8 | |
---|
9 | distfiles phpMyAdmin-${version}-php.tar.gz |
---|
10 | distname phpMyAdmin-${version}-php |
---|
11 | master_sites sourceforge http://distfiles.opendarwin.org/ |
---|
12 | master_sites.mirror_subdir ${name} |
---|
13 | extract.only ${distname}${extract.sufx} |
---|
14 | checksums phpMyAdmin-2.5.4-php.tar.gz md5 76fc7216aa2f132888c7173a6668af46 |
---|
15 | worksrcdir phpMyAdmin-${version} |
---|
16 | |
---|
17 | |
---|
18 | |
---|
19 | variant apache_layout { |
---|
20 | depends_lib-append path:${prefix}/apache/bin/apxs:apache |
---|
21 | path:${apache_path}/apache/libexec/libphp4.so:php4 |
---|
22 | } |
---|
23 | |
---|
24 | variant apache { |
---|
25 | if { ! [variant_isset apache_layout] } { |
---|
26 | depends_lib-append path:${prefix}/sbin/apxs:apache |
---|
27 | path:${apache_path}/libexec/apache/libphp4.so:php4 |
---|
28 | } |
---|
29 | } |
---|
30 | |
---|
31 | variant apache { |
---|
32 | depends_lib path:${apache_path}/sbin/apxs:apache \ |
---|
33 | path:${apache_path}/libexec/apache/libphp4.so:php4 |
---|
34 | } |
---|
35 | |
---|
36 | variant apache2 { |
---|
37 | depends_lib path:${prefix}/apache2/bin/apxs:apache2 \ |
---|
38 | path:${prefix}/apache2/modules/libphp4.so:php4 |
---|
39 | |
---|
40 | } |
---|
41 | |
---|
42 | variant mysql { |
---|
43 | depends_lib-append lib:libmysqlclient:mysql |
---|
44 | } |
---|
45 | |
---|
46 | variant mysql4 { |
---|
47 | depends_lib-append lib:libmysqlclient:mysql4 |
---|
48 | } |
---|
49 | |
---|
50 | use_configure no |
---|
51 | |
---|
52 | configure { } |
---|
53 | |
---|
54 | build { } |
---|
55 | |
---|
56 | destroot { |
---|
57 | if { [variant_isset apache] } { |
---|
58 | if { [variant_isset apache_layout] } { |
---|
59 | file mkdir ${destroot}${prefix}/apache/htdocs |
---|
60 | system "mv ${workpath}/${worksrcdir} ${destroot}${prefix}/apache/htdocs/phpmyadmin" |
---|
61 | system "chown -R root:admin ${destroot}${prefix}/apache/htdocs/phpmyadmin" |
---|
62 | |
---|
63 | if { [file exists ${prefix}/apache/htdocs/phpmyadmin/config.inc.php] } { |
---|
64 | system "mv ${destroot}${prefix}/apache/htdocs/phpmyadmin/config.inc.php ${destroot}${prefix}/apache/htdocs/phpmyadmin/config.inc.php.sample" |
---|
65 | } |
---|
66 | } else { |
---|
67 | file mkdir ${destroot}${prefix}/www/data |
---|
68 | system "mv ${workpath}/${worksrcdir} ${destroot}${prefix}/www/data/phpmyadmin" |
---|
69 | system "chown -R root:admin ${destroot}${prefix}/www/data/phpmyadmin" |
---|
70 | |
---|
71 | if { [file exists ${prefix}/www/data/phpmyadmin/config.inc.php] } { |
---|
72 | system "mv ${destroot}${prefix}/www/data/phpmyadmin/config.inc.php ${destroot}${prefix}/www/data/phpmyadmin/config.inc.php.sample" |
---|
73 | } |
---|
74 | |
---|
75 | |
---|
76 | } |
---|
77 | } |
---|
78 | |
---|
79 | if { [variant_isset apache2] } { |
---|
80 | file mkdir ${destroot}${prefix}/apache2/htdocs |
---|
81 | system "mv ${workpath}/${worksrcdir} ${destroot}${prefix}/apache2/htdocs/phpmyadmin" |
---|
82 | system "chown -R root:admin ${destroot}${prefix}/apache2/htdocs/phpmyadmin" |
---|
83 | |
---|
84 | if { [file exists ${prefix}/apache2/htdocs/phpmyadmin/config.inc.php] } { |
---|
85 | system "mv ${destroot}${prefix}/apache2/htdocs/phpmyadmin/config.inc.php ${destroot}${prefix}/apache2/htdocs/phpmyadmin/config.inc.php.sample" |
---|
86 | } |
---|
87 | } |
---|
88 | |
---|
89 | } |
---|