ports/71350: [patch] databases/mysqlcc broken with mysql41-* after updating to mysql-4.1.4
Jie Gao
gaoj at cpsc.ucalgary.ca
Fri Sep 3 19:20:24 UTC 2004
>Number: 71350
>Category: ports
>Synopsis: [patch] databases/mysqlcc broken with mysql41-* after updating to mysql-4.1.4
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: update
>Submitter-Id: current-users
>Arrival-Date: Fri Sep 03 19:20:23 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator: Jie Gao
>Release: FreeBSD 5.3-BETA2 i386
>Organization:
>Environment:
System: FreeBSD aibsd-current.cpsc.ucalgary.ca 5.3-BETA2 FreeBSD 5.3-BETA2 #0: Mon Aug 30 20:16:55 MDT 2004 gaoj at aibsd-current.cpsc.ucalgary.ca:/usr/obj/usr/src/sys/AIBSD i386
>Description:
databases/mysqlcc is broken with mysql-4.1.4 because of internal api changes.
>How-To-Repeat:
build databases/mysqlcc from ports when mysql41-client is installed.
>Fix:
Apply the following pathc to the ports tree.
--- patch-databases-mysqlcc begins here ---
Index: databases/mysqlcc/files/patch-shared-src-CMySQL.cpp
===================================================================
RCS file: /home/grads/gaoj/repository/ports/databases/mysqlcc/files/patch-shared-src-CMySQL.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- databases/mysqlcc/files/patch-shared-src-CMySQL.cpp 6 Aug 2004 00:24:34 -0000 1.1
+++ databases/mysqlcc/files/patch-shared-src-CMySQL.cpp 3 Sep 2004 19:11:18 -0000 1.2
@@ -4,7 +4,7 @@
if (!isConnected())
return false;
-+#if ( MYSQL_VERSION_ID == 40103 ) || ( MYSQL_VERSION_ID == 50001 )
++#if ( MYSQL_VERSION_ID >= 50001 ) || (( MYSQL_VERSION_ID < 50000 ) && ( MYSQL_VERSION_ID >= 40103 ))
+ if (mysql_shutdown(mysql,SHUTDOWN_DEFAULT) != 0)
+#else
if (mysql_shutdown(mysql) != 0)
Index: databases/mysqlcc/files/patch-src-main.cpp
===================================================================
RCS file: databases/mysqlcc/files/patch-src-main.cpp
diff -N databases/mysqlcc/files/patch-src-main.cpp
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ databases/mysqlcc/files/patch-src-main.cpp 3 Sep 2004 19:12:09 -0000 1.1
@@ -0,0 +1,24 @@
+--- src/main.cpp.orig Fri Sep 3 12:45:47 2004
++++ src/main.cpp Fri Sep 3 12:52:15 2004
+@@ -35,6 +35,8 @@
+ #endif
+ #endif
+
++#include <mysql_version.h>
++
+ static char *progname;
+ static void usage();
+ static void print_version();
+@@ -196,7 +198,12 @@
+ load_defaults("my",load_default_groups,&argc,&argv);
+ save_argv = argv;
+ progname= argv[0];
++//Not sure about mysql-5 yet
++#if (( MYSQL_VERSION_ID >= 40104 ) && ( MYSQL_VERSION_ID < 50000 ))
++ if (handle_options(&argc, &argv, my_long_options, get_one_option, NULL))
++#else
+ if (handle_options(&argc, &argv, my_long_options, get_one_option))
++#endif
+ exit(-1);
+ if (!argv[0] || !argv[1] || (pid = atoi(argv[0])) <= 0 || (t= atoi(argv[1])) <= 0)
+ ret = mysqlcc_main(argc, argv);
--- patch-databases-mysqlcc ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list