Ticket #399: 3.23.57.patch
File 3.23.57.patch, 3.4 KB (added by mike.mclean@…, 21 years ago) |
---|
-
Portfile
old new 1 1 # $Id: Portfile,v 1.28 2003/03/03 06:13:24 mij Exp $ 2 2 3 # mysql 3.23.57 Portfile 4 # 5 # - Includes server/client variant modificatins from bchesneau@mac.com, bug #399 6 # http://www.opendarwin.org/bugzilla/show_bug.cgi?id=399 7 # 8 # - Includes platform fixes from harlan+opendarwinbugs@pfcs.com, bug #390 9 # http://www.opendarwin.org/bugzilla/show_bug.cgi?id=390 10 # 11 # - Some systems might still want the 3.23.x verison of MySQL. This Portfile renames 12 # the Port to "mysql3" in anticipation of a new port being created for the MySQL 4 13 # series, named "mysql4" 14 # 15 # - Introduces a variant for InnoDB tables 16 # 17 18 19 3 20 PortSystem 1.0 4 name mysql 5 version 3.23.5 221 name mysql3 22 version 3.23.57 6 23 categories databases 7 maintainers eric@opendarwin.org24 maintainers eric@opendarwin.org 8 25 description Multithreaded SQL database server 9 26 long_description MySQL is an open-source, multi-threaded SQL database \ 10 27 with a command syntax very similar to mSQL. 11 28 homepage http://www.mysql.com/ 12 platforms darwin 29 platforms darwin sunos 13 30 master_sites ftp://ftp.sunet.se/pub/unix/databases/relational/mysql/Downloads/MySQL-3.23/ \ 14 31 ftp://ftp.FreeBSD.org/pub/FreeBSD/distfiles/ \ 15 http://distfiles.opendarwin.org/ :lt32 http://distfiles.opendarwin.org/ 16 33 17 set filename ${portname}-${portversion}${extract.sufx}18 distfiles ${filename} ltconfig13:lt ltmain13:lt 34 set distname mysql-${portversion} 35 set filename mysql-${portversion}${extract.sufx} 19 36 extract.only ${filename} 20 depends_lib lib:libdl.1:dlcompat 37 distfiles ${filename} 38 variant darwin { 39 depends_lib lib:libdl.1:dlcompat 40 } 21 41 22 checksums mysql-3.23.52.tar.gz md5 \ 23 88705b7f38e64b5c21ebb68c77b75e5a \ 24 ltconfig13 md5 ea53f42a550c9f9e653758a8ed91574e \ 25 ltmain13 md5 e094ae92724c4015dbab97de151c2525 26 27 post-patch { system "cp ${distpath}/ltconfig13 ${worksrcpath}/ltconfig" 28 system "cp ${distpath}/ltmain13 ${worksrcpath}/ltmain.sh" 29 } 42 checksums mysql-3.23.57.tar.gz md5 892f7d97af1ce7502e89d824031abd05 30 43 31 44 set dbdir ${prefix}/var/db/mysql 32 45 33 46 configure.env LDFLAGS=-L${prefix}/lib\\ -lncurses \ 34 47 CPPFLAGS=-I${prefix}/include 35 48 36 configure.args --localstatedir=${dbdir} \ 37 --without-bench 49 variant sunos { 50 configure.env LDFLAGS=-L${prefix}/lib CPPFLAGS=-I${prefix}/include 51 } 38 52 39 pre-install { system "install -o root -m 755 -d ${dbdir}" } 53 configure.args --localstatedir=${dbdir} --without-server --sysconfdir=${prefix}/etc --without-bench 40 54 41 variant server { 55 variant innodb { configure.args-append --with-innodb } 56 57 variant server { 42 58 depends_run path:/Library/StartupItems/DarwinPortsStartup:DarwinPortsStartup 59 configure.args --localstatedir=${dbdir} --sysconfdir=${prefix}/etc --with-innodb --without-bench 60 pre-install { system "install -o mysql -g mysql -m 775 -d ${dbdir}" 61 } 62 43 63 44 64 post-install { 45 65 addgroup mysql … … 48 68 49 69 #system "${destroot}${prefix}/bin/mysql_install_db" 50 70 #system "chown -R mysql:mysql ${dbdir}" 51 71 #system "chmod -R 777 ${prefix}/var/run 72 52 73 system "install -o root -m 755 -d ${destroot}${prefix}/etc/rc.d" 53 74 set script [open ${destroot}${prefix}/etc/rc.d/mysql.sh w 0755] 54 75 puts $script "#!/bin/sh" 55 76 puts $script "${prefix}/bin/safe_mysqld --user=mysql &" 56 77 close $script 78 system "cd ${workpath}/${worksrcdir} && \ 79 cp support-files/my-medium.cnf ${destroot}${prefix}/etc/my.cnf" 57 80 } 58 81 }