Bug #30121 error: invalid lvalue in assignment
Submitted: 30 Jul 2007 10:00 Modified: 1 Aug 2007 7:58
Reporter: Abu Saleh Alshukaili Email Updates:
Status: Not a Bug Impact on me:
None 
Category:Connectors: DBD::mysql ( Perl ) Severity:S3 (Non-critical)
Version: 5.0.26-standard OS:Any
Assigned to: CPU Architecture:Any

[30 Jul 2007 10:00] Abu Saleh Alshukaili
Description:
Perl Version: 5.8.8
OS: RedHat ES4
DBD::mysql version -4.005

when running the make program I get the following error:

mysql.xsi: In function `XS_DBD__mysql__db_disconnect':
mysql.xsi:275: error: invalid lvalue in assignment
mysql.xsi: In function `XS_DBD__mysql__db_DESTROY':
mysql.xsi:334: error: invalid lvalue in assignment
make: *** [mysql.o] Error 1

Here is the full dump of make:

cc -c  -I/usr/local/lib/perl5/site_perl/5.8.8/i686-linux/auto/DBI -I/usr/include/mysql -g -pipe -m32 -march=i386 -mtune=pentium4 -DDBD_MYSQL_INSERT_ID_IS_GOOD -g  -fno-strict-aliasing -pipe -Wdeclaration-after-statement -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -O2   -DVERSION=\"4.005\" -DXS_VERSION=\"4.005\" -fpic "-I/usr/local/lib/perl5/5.8.8/i686-linux/CORE"   mysql.c
mysql.xsi: In function `XS_DBD__mysql__db_disconnect':
mysql.xsi:275: error: invalid lvalue in assignment
mysql.xsi: In function `XS_DBD__mysql__db_DESTROY':
mysql.xsi:334: error: invalid lvalue in assignment
make: *** [mysql.o] Error 1
 

How to repeat:
Install Perl by Compiling the Source code by downloading the current stable source. After that Compile and install DBI-1.58. The try to compile DBD-mysql-4.005 and you will get this.
[31 Jul 2007 6:27] Abu Saleh Alshukaili
Hi, 

I think I found what I was doing wrong. 

When I ran "perl Makefile.PL" for first time I ran it with a 5.8.5 version 
and once I ran "make" it has created a file called "mysql.xsi". 

After I have done this I found out that the perl which I am looking for is 
5.8.8. So I did the above again. However, the "make" step did not recreate 
"mysql.xsi". 

So fix this. I started the whole process by unzipping the original source 
file for mysql::DBD in a fresh folder and repeated the above process with 
perl 5.8.8 and thigs went fine. 

Regards, 
Abu Saleh
[1 Aug 2007 7:58] Valeriy Kravchuk
So, this problem was not a result of a bug in DBD::mysql code, it seems.