diff --git a/build/install b/build/install index 20d6bcc4611..99dfdc2f6d3 100755 --- a/build/install +++ b/build/install @@ -57,5 +57,13 @@ if [ -f Makefile ]; then phpize --clean fi +LIBTOOLIZE_BIN="libtoolize" + +#GNU 'libtoolize' on MAC OS X is called 'glibtoolize' +if [ `(uname -s) 2>/dev/null` == 'Darwin' ] +then + LIBTOOLIZE_BIN="glibtoolize" +fi + #Perform the compilation -phpize && ./configure --enable-phalcon && make && make install && echo -e "\nThanks for compiling Phalcon!\nBuild succeed: Please restart your web server to complete the installation" +phpize && aclocal && $LIBTOOLIZE_BIN --force && autoheader && autoconf && ./configure --enable-phalcon && make && make install && echo -e "\nThanks for compiling Phalcon!\nBuild succeed: Please restart your web server to complete the installation" diff --git a/ext/db/dialect/mysql.c b/ext/db/dialect/mysql.c index 1855228af42..75b13bb48da 100755 --- a/ext/db/dialect/mysql.c +++ b/ext/db/dialect/mysql.c @@ -163,7 +163,12 @@ PHP_METHOD(Phalcon_Db_Dialect_Mysql, getColumnDefinition){ } break; - + + case 8: + PHALCON_INIT_VAR(column_sql); + ZVAL_STRING(column_sql, "TINYINT(1)", 1); + break; + default: PHALCON_THROW_EXCEPTION_STR(phalcon_db_exception_ce, "Unrecognized MySQL data type"); return; diff --git a/ext/db/dialect/oracle.c b/ext/db/dialect/oracle.c index 3a10891881b..66f0bb5b598 100644 --- a/ext/db/dialect/oracle.c +++ b/ext/db/dialect/oracle.c @@ -135,7 +135,12 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, getColumnDefinition){ PHALCON_INIT_NVAR(column_sql); PHALCON_CONCAT_SVSVS(column_sql, "FLOAT(", size, ",", scale, ")"); break; - + + case 8: + PHALCON_INIT_VAR(column_sql); + ZVAL_STRING(column_sql, "TINYINT(1)", 1); + break; + default: PHALCON_THROW_EXCEPTION_STR(phalcon_db_exception_ce, "Unrecognized Oracle data type"); return; diff --git a/ext/db/dialect/postgresql.c b/ext/db/dialect/postgresql.c index d89bc2d07b3..779c291dd5a 100644 --- a/ext/db/dialect/postgresql.c +++ b/ext/db/dialect/postgresql.c @@ -130,6 +130,11 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition){ PHALCON_INIT_NVAR(column_sql); ZVAL_STRING(column_sql, "FLOAT", 1); break; + + case 8: + PHALCON_INIT_VAR(column_sql); + ZVAL_STRING(column_sql, "SMALLINT(1)", 1); + break; default: PHALCON_THROW_EXCEPTION_STR(phalcon_db_exception_ce, "Unrecognized PostgreSQL data type"); diff --git a/ext/db/dialect/sqlite.c b/ext/db/dialect/sqlite.c index 62afc219f5e..7de011cf178 100644 --- a/ext/db/dialect/sqlite.c +++ b/ext/db/dialect/sqlite.c @@ -131,6 +131,11 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition){ PHALCON_INIT_NVAR(column_sql); ZVAL_STRING(column_sql, "FLOAT", 1); break; + + case 8: + PHALCON_INIT_VAR(column_sql); + ZVAL_STRING(column_sql, "TINYINT(1)", 1); + break; default: PHALCON_THROW_EXCEPTION_STR(phalcon_db_exception_ce, "Unrecognized SQLite data type"); diff --git a/ext/mvc/application.c b/ext/mvc/application.c index 5ae342bca4a..e601f5d1a25 100755 --- a/ext/mvc/application.c +++ b/ext/mvc/application.c @@ -356,23 +356,7 @@ PHP_METHOD(Phalcon_Mvc_Application, handle){ * An array module definition contains a path to a module definition class */ if (Z_TYPE_P(module) == IS_ARRAY) { - if (phalcon_array_isset_string(module, SS("path"))) { - - PHALCON_OBS_VAR(path); - phalcon_array_fetch_string(&path, module, SL("path"), PH_NOISY_CC); - if (phalcon_file_exists(path TSRMLS_CC) == SUCCESS) { - if (phalcon_require(path TSRMLS_CC) == FAILURE) { - return; - } - } else { - PHALCON_INIT_NVAR(exception_msg); - PHALCON_CONCAT_SVS(exception_msg, "Module definition path '", path, "' doesn't exist"); - PHALCON_THROW_EXCEPTION_ZVAL(phalcon_mvc_application_exception_ce, exception_msg); - return; - } - } - - /** + /** * Class name used to load the module definition */ if (phalcon_array_isset_string(module, SS("className"))) { @@ -382,6 +366,24 @@ PHP_METHOD(Phalcon_Mvc_Application, handle){ PHALCON_INIT_NVAR(class_name); ZVAL_STRING(class_name, "Module", 1); } + + if (!phalcon_class_exists(class_name TSRMLS_CC)) { + if (phalcon_array_isset_string(module, SS("path"))) { + + PHALCON_OBS_VAR(path); + phalcon_array_fetch_string(&path, module, SL("path"), PH_NOISY_CC); + if (phalcon_file_exists(path TSRMLS_CC) == SUCCESS) { + if (phalcon_require(path TSRMLS_CC) == FAILURE) { + return; + } + } else { + PHALCON_INIT_NVAR(exception_msg); + PHALCON_CONCAT_SVS(exception_msg, "Module definition path '", path, "' doesn't exist"); + PHALCON_THROW_EXCEPTION_ZVAL(phalcon_mvc_application_exception_ce, exception_msg); + return; + } + } + } phalcon_call_method_p1(module_object, dependency_injector, "get", class_name);