DBD:mysql on MacIntel 10.4.8

DBD:mysql on MacIntel 10.4.8

am 25.11.2006 13:18:15 von Alex Demmler

--Apple-Mail-2--681181901
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
charset=US-ASCII;
delsp=yes;
format=flowed

Hi Folks!

I cant get it installed, anny help would be perfect:

macbook:~/Desktop/DBD-mysql-3.0008_1 ademmler$ sudo perl Makefile.PL
--cflags="-I/usr/local/mysql/include -Os -arch i386 -fno-common" --
libs="-L/usr/local/mysql/lib -lmysqlclient -lz -lm"

The arguments I found on this HowTo (http://jayallen.org/journey/
2006/04/dbd-mysql-build-problems-on-mac-book-pro), without I have
much more errors.

I will use the following settings for compiling and testing:

cflags (User's choice) = -I/usr/local/mysql/include -Os -
arch i386 -fno-common
embedded (mysql_config ) =
libs (User's choice) = -L/usr/local/mysql/lib -
lmysqlclient -lz -lm
mysql_config (guessed ) = mysql_config
nocatchstderr (default ) = 0
nofoundrows (default ) = 0
ps-protocol (default ) = 1
ssl (guessed ) = 0
testdb (default ) = test
testhost (default ) =
testpassword (default ) =
testsocket (default ) =
testuser (default ) =

To change these settings, see 'perl Makefile.PL --help' and
'perldoc INSTALL'.

Using DBI 1.53 (for perl 5.008006 on darwin-thread-multi-2level)
installed in /Library/Perl/5.8.6/darwin-thread-multi-2level/auto/DBI/
Writing Makefile for DBD::mysql
macbook:~/Desktop/DBD-mysql-3.0008_1 ademmler$ make
cc -c -I/Library/Perl/5.8.6/darwin-thread-multi-2level/auto/DBI -I/
usr/local/mysql/include -Os -arch i386 -fno-common -
DDBD_MYSQL_INSERT_ID_IS_GOOD -g -g -pipe -fno-common -DPERL_DARWIN -
no-cpp-precomp -fno-strict-aliasing -I/usr/local/include -O3 -
DVERSION=\"3.0008_1\" -DXS_VERSION=\"3.0008_1\" "-I/System/Library/
Perl/5.8.6/darwin-thread-multi-2level/CORE" dbdimp.c
dbdimp.c: In function 'mysql_dr_connect':
dbdimp.c:1702: error: 'ulong' undeclared (first use in this function)
dbdimp.c:1702: error: (Each undeclared identifier is reported only once
dbdimp.c:1702: error: for each function it appears in.)
dbdimp.c:1702: error: parse error before numeric constant
make: *** [dbdimp.o] Error 1



Regards Alex

--Apple-Mail-2--681181901--

Re: DBD:mysql on MacIntel 10.4.8

am 27.11.2006 07:38:44 von Christian Hoermann

Hello,

I am not really sure how exactly you can solve the problem, but since
no one else has replied yet, I'll try to help.

> dbdimp.c: In function 'mysql_dr_connect':
> dbdimp.c:1702: error: 'ulong' undeclared (first use in this function)
> dbdimp.c:1702: error: (Each undeclared identifier is reported only once
> dbdimp.c:1702: error: for each function it appears in.)
> dbdimp.c:1702: error: parse error before numeric constant

ulong should be decalred in the MySQL file "my_global.h" (and maybe
also some other files). You should check that you have all the MySQL
files, including this one, at /usr/local/mysql/include (as this is
what you specified under the --cflags). (If it's elsewhere for some
reason, you should add another -I option to the --cflags.)

If it seems to be there correctly, have a look inside at about line
825 (depending on your version of MySQL):
#if !defined(HAVE_ULONG) && !defined(TARGET_OS_LINUX) && !defined(__USE_MISC)
typedef unsigned long ulong; /* Short for unsigned long */
#endif
Possibly, the #if check fails, even though ulong is not defined. You
can try to add this line:
typedef unsigned long ulong;
to the DBD::mysql header file ("dbdimp.h"), at the very top, probably
best before the includes.

Best Regards,

Christian

--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org