Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

update ready for release

# includes big hack to help guide people into running "make install" so
# that the headers get installed; works around a pear bug.
  • Loading branch information...
commit 5a2cb4154a577bf9f8eb365748ccb0f4bff219c3 1 parent 5f026d0
Wez Furlong wez authored
12 ext/pdo/Makefile.frag
View
@@ -20,12 +20,20 @@ install-pdo-headers:
echo "hmmm"; \
fi \
done;
+ @echo ""
+ @echo ""
+ @echo "You're now ready to install PDO drivers for your database"
+ @echo "If you'd like to have PDO show up in the list of installed"
+ @echo "packages when you run \"pear list\", you may now run"
+ @echo "\"sudo pear install package.xml\""
+ @echo "this time, when prompted to press enter, you shold type"
+ @echo "\"no\" and press enter instead."
# mini hack
install: $(all_targets) $(install_targets) install-pdo-headers
$(top_srcdir)/ext/pdo/pdo_sql_parser.c: $(top_srcdir)/ext/pdo/pdo_sql_parser.re
- re2c -b $(top_srcdir)/ext/pdo/pdo_sql_parser.re > $@
+ exit 0; re2c -b $(top_srcdir)/ext/pdo/pdo_sql_parser.re > $@
$(srcdir)/pdo_sql_parser.c: $(srcdir)/pdo_sql_parser.re
- re2c -b $(srcdir)/pdo_sql_parser.re > $@
+ exit 0; re2c -b $(srcdir)/pdo_sql_parser.re > $@
36 ext/pdo/config.m4
View
@@ -1,6 +1,42 @@
dnl $Id$
dnl config.m4 for extension pdo
+AC_ARG_WITH(broken-pear-install,
+[],[
+ if test "x$withval" = "xyes"; then
+ AC_MSG_ERROR([
+Due to a bug in the pear installer you should install the PDO package manually
+using the following steps:
+
+ 1. Download the PDO package to your local machine:
+
+ % wget http://pecl.php.net/get/PDO
+
+ 2. Determine your PHP bin dir.
+ If your php5 cli binary lives at /usr/local/php5/bin/php
+ the bin dir is /usr/local/php5/bin
+
+ 3. Set your path so that your PHP bin dir is at the front:
+ export PATH="/usr/local/php5/bin:\$PATH"
+
+ 4. Manually build:
+
+ % tar xzf PDO-0.2.tgz
+ % cd PDO-0.2
+ % phpize
+ % ./configure
+ % make
+ % sudo -s
+ # make install
+ # echo extension=pdo.so >> /usr/local/php5/lib/php.ini
+
+We apologize for the inconvenience, and hope to resolve this problem
+in a future PHP/PEAR release.
+
+])
+fi
+])
+
PHP_ARG_ENABLE(pdo, whether to disable PDO support,
[ --disable-pdo Disable PHP Data Objects support], yes)
17 ext/pdo/package.xml
View
@@ -29,17 +29,26 @@
<role>lead</role>
</maintainer>
</maintainers>
+
+<!-- pear is still broken -->
+<configureoptions>
+ <configureoption name="with-broken-pear-install" default="yes" prompt="the pear installer has a bug; press enter to find out more"/>
+</configureoptions>
+
+
<description>
PDO provides a uniform data access interface, sporting advanced features such
as prepared statements and bound parameters. PDO drivers are dynamically
loadable and may be developed independently from the core, but still accessed
using the same API.
+
+ Read the documentation at http://www.php.net/pdo for more information.
</description>
<license>PHP</license>
<release>
- <state>alpha</state>
+ <state>beta</state>
<version>0.2</version>
- <date>2005-01-20</date>
+ <date>2005-02-08</date>
<notes>
Note that PDO on its own is useless.
@@ -51,7 +60,7 @@ before using PDO.
You can obtain it from http://snaps.php.net.
If you are running on Windows, you should download:
-http://snaps.php.net/win32/php5-win32-latest.zip
+http://snaps.php.net/win32/php5.0-win32-latest.zip
http://snaps.php.net/win32/PECL_5_0/php_pdo.dll
You can find additional PDO drivers at:
@@ -79,7 +88,7 @@ http://snaps.php.net/win32/PECL_5_0/
<file role="doc" name="CREDITS"/>
</filelist>
<deps>
- <dep type="php" rel="ge" version="5.0.0"/>
+ <dep type="php" rel="ge" version="5.0.3"/>
</deps>
</release>
</package>
2  ext/pdo/pdo.c
View
@@ -74,7 +74,7 @@ zend_module_entry pdo_module_entry = {
PHP_RINIT(pdo),
PHP_RSHUTDOWN(pdo),
PHP_MINFO(pdo),
- "0.1.1",
+ "0.2",
STANDARD_MODULE_PROPERTIES
};
/* }}} */
4 ext/pdo/pdo.php
View
@@ -25,7 +25,7 @@
$stmt = null;
echo "DEFAULT:\n";
-foreach ($x->queryAndIterate("select NAME, VALUE from test") as $row) {
+foreach ($x->query("select NAME, VALUE from test") as $row) {
print_r($row);
}
@@ -37,7 +37,7 @@ class Foo {
$foo = new foo;
-foreach ($x->queryAndIterate("select NAME, VALUE from test", PDO_FETCH_COLUMN, 1) as $row) {
+foreach ($x->query("select NAME, VALUE from test", PDO_FETCH_COLUMN, 1) as $row) {
debug_zval_dump($row);
}
22 ext/pdo/pdo_sql_parser.c
View
@@ -1,5 +1,5 @@
-/* Generated by re2c 0.9.3 on Sun Feb 6 19:24:41 2005 */
-#line 1 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+/* Generated by re2c 0.9.3 on Tue Feb 8 19:46:35 2005 */
+#line 1 "/data/wez/pecl/pdo/pdo_sql_parser.re"
/*
+----------------------------------------------------------------------+
| PHP Version 5 |
@@ -45,7 +45,7 @@ static int scan(Scanner *s)
char *cursor = s->cur;
std:
s->tok = cursor;
- #line 54 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+ #line 54 "/data/wez/pecl/pdo/pdo_sql_parser.re"
@@ -103,7 +103,7 @@ yy2: yyaccept = 0;
if(yych >= '\001') goto yy24;
goto yy3;
yy3:
-#line 61 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+#line 61 "/data/wez/pecl/pdo/pdo_sql_parser.re"
{ RET(PDO_PARSER_TEXT); }
#line 63 "<stdout>"
yy4: yyaccept = 0;
@@ -117,7 +117,7 @@ yy5: yych = *++YYCURSOR;
yy6: ++YYCURSOR;
goto yy7;
yy7:
-#line 60 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+#line 60 "/data/wez/pecl/pdo/pdo_sql_parser.re"
{ RET(PDO_PARSER_BIND_POS); }
#line 77 "<stdout>"
yy8: ++YYCURSOR;
@@ -127,13 +127,13 @@ yy8: ++YYCURSOR;
yy9: if(yybm[0+yych] & 8) goto yy8;
goto yy10;
yy10:
-#line 62 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+#line 62 "/data/wez/pecl/pdo/pdo_sql_parser.re"
{ RET(PDO_PARSER_TEXT); }
#line 88 "<stdout>"
yy11: ++YYCURSOR;
goto yy12;
yy12:
-#line 63 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+#line 63 "/data/wez/pecl/pdo/pdo_sql_parser.re"
{ RET(PDO_PARSER_EOI); }
#line 94 "<stdout>"
yy13: ++YYCURSOR;
@@ -143,7 +143,7 @@ yy13: ++YYCURSOR;
yy14: if(yybm[0+yych] & 16) goto yy13;
goto yy15;
yy15:
-#line 59 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+#line 59 "/data/wez/pecl/pdo/pdo_sql_parser.re"
{ RET(PDO_PARSER_BIND); }
#line 105 "<stdout>"
yy16: ++YYCURSOR;
@@ -169,7 +169,7 @@ yy20: if(yybm[0+yych] & 32) goto yy16;
if(yych <= '\'') goto yy19;
goto yy22;
yy21:
-#line 58 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+#line 58 "/data/wez/pecl/pdo/pdo_sql_parser.re"
{ RET(PDO_PARSER_TEXT); }
#line 132 "<stdout>"
yy22: ++YYCURSOR;
@@ -193,11 +193,11 @@ yy25: ++YYCURSOR;
yy26: ++YYCURSOR;
goto yy27;
yy27:
-#line 57 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+#line 57 "/data/wez/pecl/pdo/pdo_sql_parser.re"
{ RET(PDO_PARSER_TEXT); }
#line 159 "<stdout>"
}
-#line 64 "/data/wez/php-HEAD/ext/pdo/pdo_sql_parser.re"
+#line 64 "/data/wez/pecl/pdo/pdo_sql_parser.re"
}
Please sign in to comment.
Something went wrong with that request. Please try again.