Skip to content

Instantly share code, notes, and snippets.

@0livier
Created August 12, 2011 09:32
Show Gist options
  • Save 0livier/1141773 to your computer and use it in GitHub Desktop.
Save 0livier/1141773 to your computer and use it in GitHub Desktop.
Diff for compiling PHP 5.1.4 with recent Ubuntu
--- /root/php-5.1.4/php-5.1.4/ext/curl/interface.c.orig 2011-08-12 11:21:54.829741804 +0200
+++ /root/php-5.1.4/php-5.1.4/ext/curl/interface.c 2011-08-12 11:22:29.026246504 +0200
@@ -266,7 +266,7 @@
REGISTER_CURL_CONSTANT(CURLOPT_FTPAPPEND);
REGISTER_CURL_CONSTANT(CURLOPT_NETRC);
REGISTER_CURL_CONSTANT(CURLOPT_FOLLOWLOCATION);
- REGISTER_CURL_CONSTANT(CURLOPT_FTPASCII);
+ // REGISTER_CURL_CONSTANT(CURLOPT_FTPASCII);
REGISTER_CURL_CONSTANT(CURLOPT_PUT);
#if CURLOPT_MUTE != 0
REGISTER_CURL_CONSTANT(CURLOPT_MUTE);
@@ -306,7 +306,7 @@
REGISTER_CURL_CONSTANT(CURLOPT_FILETIME);
REGISTER_CURL_CONSTANT(CURLOPT_WRITEFUNCTION);
REGISTER_CURL_CONSTANT(CURLOPT_READFUNCTION);
- REGISTER_CURL_CONSTANT(CURLOPT_PASSWDFUNCTION);
+ // REGISTER_CURL_CONSTANT(CURLOPT_PASSWDFUNCTION);
REGISTER_CURL_CONSTANT(CURLOPT_HEADERFUNCTION);
REGISTER_CURL_CONSTANT(CURLOPT_MAXREDIRS);
REGISTER_CURL_CONSTANT(CURLOPT_MAXCONNECTS);
--- /root/php-5.1.4/php-5.1.4/ext/mysqli/mysqli_api.c.orig 2011-08-12 11:27:42.934238804 +0200
+++ /root/php-5.1.4/php-5.1.4/ext/mysqli/mysqli_api.c 2011-08-12 11:28:12.114238317 +0200
@@ -142,13 +142,13 @@
switch (types[ofs]) {
case 'd': /* Double */
bind[ofs].buffer_type = MYSQL_TYPE_DOUBLE;
- bind[ofs].buffer = (gptr)&Z_DVAL_PP(args[i]);
+ bind[ofs].buffer = (char*)&Z_DVAL_PP(args[i]);
bind[ofs].is_null = &stmt->param.is_null[ofs];
break;
case 'i': /* Integer */
bind[ofs].buffer_type = MYSQL_TYPE_LONG;
- bind[ofs].buffer = (gptr)&Z_LVAL_PP(args[i]);
+ bind[ofs].buffer = (char*)&Z_LVAL_PP(args[i]);
bind[ofs].is_null = &stmt->param.is_null[ofs];
break;
@@ -598,11 +598,11 @@
break;
case MYSQL_TYPE_DOUBLE:
convert_to_double_ex(&stmt->param.vars[i]);
- stmt->stmt->params[i].buffer = (gptr)&Z_LVAL_PP(&stmt->param.vars[i]);
+ stmt->stmt->params[i].buffer = (char*)&Z_LVAL_PP(&stmt->param.vars[i]);
break;
case MYSQL_TYPE_LONG:
convert_to_long_ex(&stmt->param.vars[i]);
- stmt->stmt->params[i].buffer = (gptr)&Z_LVAL_PP(&stmt->param.vars[i]);
+ stmt->stmt->params[i].buffer = (char*)&Z_LVAL_PP(&stmt->param.vars[i]);
break;
default:
break;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment