Update of /cvsroot/monetdb/clients/src/php/Cimpl
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv7517/src/php/Cimpl
Modified Files:
Makefile.ag php_monetdb.c
Log Message:
propagated changes of Tuesday Nov 06 2007 - Thursday Nov 08 2007
from the Clients_1-20 branch to the development trunk
Index: Makefile.ag
===================================================================
RCS file: /cvsroot/monetdb/clients/src/php/Cimpl/Makefile.ag,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- Makefile.ag 6 Nov 2007 14:35:00 -0000 1.6
+++ Makefile.ag 8 Nov 2007 19:13:44 -0000 1.7
@@ -22,22 +22,12 @@
# we need this flag to allow for a name that does not start with "lib"
monetdb_la_LDFLAGS = -module
-# GNU's gcc does not like to compile swig-generated code
-# (at least not with our strict X_CFLAGS), complaining about
-# "warning: dereferencing type-punned pointer will break strict-aliasing
rules",
-# "warning: unused variable '...'",
-# "warning: '...' defined but not used", and/or
-# 'error: "..." is not defined'.
-# Hence, we use GCC_SWIG_CFLAGS to disable the respective warning
-# as locally as possbile via "-Wno-strict-aliasing -Wno-unused-variable
-Wno-unused-function -Wno-undef".
-# Intel's icc does not like to compile swig-generated code
-# (at least not with our strict X_CFLAGS), complaining about
-# 'error #869: parameter "..." was never referenced',
-# 'error #177: function "..." was declared but never referenced', and/or
-# 'error #310: old-style parameter list (anachronism)'.
-# Hence, we use ICC_SWIG_CFLAGS to disable the respective warning
-# as locally as possbile via "-wd869 -wd177 -wd310".
-# (See also buildtools/conf/MonetDB.m4.)
+# Both GNU's gcc and Intel's icc do not like to compile swig-generated code
+# with our strict X_CFLAGS.
+# Instead of diabling the strict X_CFLAGS completely,
+# we use GCC_SWIG_CFLAGS and ICC_SWIG_CFLAGS, respectively,
+# to disable only the problematic warnings/errors as locally as possbile.
+# See buildtools/conf/MonetDB.m4 for details.
CFLAGS = $(GCC_SWIG_CFLAGS) $(ICC_SWIG_CFLAGS) -DCOMPILE_DL_MONETDB=1
-D_GNU_SOURCE
SUBDIRS = examples
Index: php_monetdb.c
===================================================================
RCS file: /cvsroot/monetdb/clients/src/php/Cimpl/php_monetdb.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- php_monetdb.c 6 Nov 2007 14:35:00 -0000 1.8
+++ php_monetdb.c 8 Nov 2007 19:13:45 -0000 1.9
@@ -377,9 +377,6 @@
*/
PHP_MINIT_FUNCTION(monetdb)
{
- /* unused parameters */
- (void) type;
-
ZEND_INIT_MODULE_GLOBALS(monetdb, php_monetdb_init_globals, NULL);
REGISTER_INI_ENTRIES();
@@ -431,9 +428,6 @@
*/
PHP_MSHUTDOWN_FUNCTION(monetdb)
{
- /* unused parameters */
- (void) type;
-
UNREGISTER_INI_ENTRIES();
zend_hash_destroy(&MG(notices));
zend_hash_destroy(&MG(errors));
@@ -446,10 +440,6 @@
*/
PHP_RINIT_FUNCTION(monetdb)
{
- /* unused parameters */
- (void) type;
- (void) module_number;
-
MG(default_link)=-1;
MG(num_links) = MG(num_persistent);
return SUCCESS;
@@ -460,10 +450,6 @@
*/
PHP_RSHUTDOWN_FUNCTION(monetdb)
{
- /* unused parameters */
- (void) type;
- (void) module_number;
-
/* clean up notice messages */
zend_hash_clean(&MG(notices));
zend_hash_clean(&MG(errors));
@@ -518,11 +504,6 @@
Mconn *monetdb;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
argc = ZEND_NUM_ARGS();
if (argc > 7 ||
zend_get_parameters_array_ex(argc, args) != SUCCESS)
@@ -725,11 +706,6 @@
int id;
Mconn *monetdb;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
switch (ZEND_NUM_ARGS()) {
case 0:
id = MG(default_link);
@@ -778,11 +754,6 @@
int id = -1;
Mconn *monetdb;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
switch(ZEND_NUM_ARGS()) {
case 0:
id = MG(default_link);
@@ -881,11 +852,6 @@
int id;
Mconn *monetdb;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS()
TSRMLS_CC, "r", &monetdb_link) == SUCCESS) {
id = -1;
} else {
@@ -921,11 +887,6 @@
Mresult *monetdb_result;
php_monetdb_result_handle *monetdb_result_h;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
switch(ZEND_NUM_ARGS()) {
case 1:
if (zend_get_parameters_ex(1, &query)==FAILURE) {
@@ -1344,11 +1305,6 @@
Mresult *monetdb_result;
php_monetdb_result_handle *monetdb_result_h;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1,
&result)==FAILURE) {
WRONG_PARAM_COUNT;
}
@@ -1407,11 +1363,6 @@
int id = -1;
php_monetdb_notice **notice;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r",
&monetdb_link) ==
FAILURE) {
return;
@@ -1438,11 +1389,6 @@
Mresult *monetdb_result;
php_monetdb_result_handle *monetdb_result_h;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &result,
&field)==FAILURE) {
WRONG_PARAM_COUNT;
}
@@ -1515,11 +1461,6 @@
php_monetdb_result_handle *monetdb_result_h;
int i;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &result,
&field)==FAILURE) {
WRONG_PARAM_COUNT;
}
@@ -1552,11 +1493,6 @@
int field_offset, monetdb_row;
char *data;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if ((ZEND_NUM_ARGS() != 3 || zend_get_parameters_ex(3, &result, &row,
&field)==FAILURE) &&
(ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &result,
&field)==FAILURE)) {
WRONG_PARAM_COUNT;
@@ -1643,11 +1579,6 @@
zval *ctor_params = NULL;
zend_class_entry *ce = NULL;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (into_object) {
char *class_name;
int class_name_len;
@@ -1878,11 +1809,6 @@
long row;
php_monetdb_result_handle *monetdb_result_h;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rl", &result,
&row) == FAILURE) {
return;
}
@@ -1911,11 +1837,6 @@
php_monetdb_result_handle *monetdb_result_h;
int field_offset, monetdb_row;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if ((ZEND_NUM_ARGS() != 3 || zend_get_parameters_ex(3, &result, &row,
&field)==FAILURE) &&
(ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &result,
&field)==FAILURE)) {
WRONG_PARAM_COUNT;
@@ -2014,11 +1935,6 @@
zval **result;
php_monetdb_result_handle *monetdb_result_h;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1,
&result)==FAILURE) {
WRONG_PARAM_COUNT;
}
@@ -2039,12 +1955,6 @@
char *from = NULL, *to = NULL, *ret = NULL;
int to_len;
int from_len;
-
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s",
&from, &from_len) ==
FAILURE) {
return;
@@ -2066,11 +1976,6 @@
int id = -1;
Mconn *monetdb_conn;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS()
TSRMLS_CC, "r",
&monetdb_link)
== FAILURE) {
RETURN_FALSE;
@@ -2090,11 +1995,6 @@
int id = -1;
Mconn *monetdb_conn;
- /* unused parameters */
- (void) return_value_ptr;
- (void) this_ptr;
- (void) return_value_used;
-
if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS()
TSRMLS_CC, "r",
&monetdb_link)
== FAILURE) {
RETURN_FALSE;
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Monetdb-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-checkins