[Samba] Samba with Mysql, compilation problem.

MARTIN Pierre HicksCorp at GMail.com
Thu Sep 22 10:56:07 GMT 2005


Hello Collen,

I've just try what you suggested. I have now a new error which is
"*Can't find MySQL libraries while MySQL support is requested.*"
But now, the configure script returns an error, not the compilation 
itselve (Since the make command is not started unless configure tells 
"i'm fine go ahead"  :-) )

The configure script was called with these args:
*--cache-file=./config.cache --with-fhs --enable-shared --enable-static 
--prefix=/usr --sysconfdir=/etc --libdir=/etc/samba 
--with-privatedir=/etc/samba --with-piddir=/var/run/samba 
--localstatedir=/var --with-netatalk --with-pam --with-syslog 
--with-utmp --with-readline --with-pam_smbpass --with-libsmbclient 
--with-winbind --with-msdfs --with-automount --with-tdbsam --with-ldap 
--with-python=python2.3 --with-expsam=mysql --with-shared-modules=pdb_mysql*

My actual filesystem configuration is as follows:

    * /usr/local/mysql/include/mysql is symlinked to /usr/include/mysql,
      so i virtualy have mysql.h and other header files in
      /usr/include/mysql/*
    * /usr/local/mysql/lib/mysql is symlinked to /usr/lib/mysql, so i
      also virtually have all mysql libraries in /usr/lib/mysql/*

look:
"*ls /usr/lib/mysql/*" gives
*libdbug.a  libmerge.a   libmyisammrg.a    libmysqlclient.la  
libmysqlclient.so.14      libmystrings.a  libnisam.a  libheap.a  
libmyisam.a  libmysqlclient.a  libmysqlclient.so  
libmysqlclient.so.14.0.0  libmysys.a      libvio.a*

and "*ls /usr/include/mysql/*"
*errmsg.h    my_alloc.h   my_getopt.h  my_no_pthread.h  mysqld_error.h  
mysql_version.h  readline.h     sslopt-longopts.h  keycache.h  
my_config.h  my_global.h  my_pthread.h     mysql_embed.h   
my_sys.h         sql_common.h   sslopt-vars.h   m_ctype.h   my_dbug.h    
my_list.h    my_semaphore.h   mysql.h         my_xml.h         
sql_state.h    typelib.h  m_string.h  my_dir.h     my_net.h     
mysql_com.h      mysql_time.h    raid.h           sslopt-case.h*

But it seems that the configure script doesn't knows where to look in.

I'm going to make further tests with the "*--with-mysql-prefix*" and 
"*--with-mysql-exec-prefix*", giving them some additionnal paths, in 
fact i dont know what more i can do :'(

Anyway, thank you for the help!

Take care,
Pierre

(C)ollen wrote:

> hmm.. try
>
> ./configure --with-expsam=mysql --with-shared-modules=pdb_mysql
>
> mysql lib's in the: /usr/lib/mysql (symlink will do)
> mysql headers in the: /usr/include/mysql (symlink will do)
>
> you can compile the mysql_backend into samba so there isn't an 
> external module !
>
> your problem is that samba can't find the header files from mysql (.h)
> I think that the guy's from debian left the mysql backend out,
> coz' it's somewhat experimental, and lackes support..
> never the less, it works, and we have it up and running for almost 
> 2years now!!
>
> have fun
>
> Collen Blijenberg (MLHJ)
>
> MARTIN Pierre wrote:
>
>> First i would like to say hello to everybody here, because i am new 
>> to this ML.
>>
>> So here is the description of my problem:
>> I began with a clean samba installation from the stable branch few 
>> monthes ago, everything was just fine, i have a linux box which was 
>> sharing files for another linux workstation and two WinXP laptops. 
>> The sharing linux box is a debian stable branch O/S, which is my 
>> choice for a long time now.
>>
>> Few weeks ago, i decided to make my sparkling samba installation 
>> virtual-users aware, and i began to crawl on various websites, all 
>> explaining the smb.conf parametters to give. I figured out that i was 
>> just not able to make it run because of a main problem, the apt-get 
>> samba gave me a non mysql-powered-samba version :(
>>
>> So i removed the samba package from the computer, and dowloaded the 
>> debian source of it. Basic source, untared, and had a look to the 
>> debian/rule file. I saw there was any parametters given about mysql 
>> building, so i also had a look at the configure script's options. It 
>> always compiles the brand new warm .deb packages (after i fixed some 
>> lacky dependencies, i had to make a fake mysql-common package by 
>> myselve, because i already had mysql installed from sources and did 
>> not want to install the deb package, etc...). I'm now totally lost, i 
>> have try everything and i can't get this pdb_mysql.so "plugin" ready :(
>>
>> So maybe i have miss something, maybe there is another way to make it 
>> as i wish to be, maybe there is a simple way to indirectly link samba 
>> to mysql with pam (I don't know PAM rules at all, i neither don't 
>> know how it works).
>>
>> It has been 4 days i'm looking for a solution, mailing random people 
>> i find on websites, no answers from them.
>>
>> Please if somebody has any clue, let me know a link, a sound, a 
>> color, anything to find a way to make it work...
>> Anything to make it work from the stable .deb packages appreciated too.
>>
>> Thank you a lot!
>>
>> Pierre.
>>
>> P.S.: Here is the current configure parametters i use extracted from 
>> my rule file:
>>                --cache-file=./config.cache --with-fhs --enable-shared 
>> --enable-static --prefix=/usr --sysconfdir=/etc --libdir=/etc/samba 
>> --with-privatedir=/etc/samba --with-piddir=/var/run/samba 
>> --localstatedir=/var --with-netatalk --with-pam --with-syslog 
>> --with-utmp --with-readline --with-pam_smbpass --with-libsmbclient 
>> --with-winbind --with-msdfs --with-automount --with-tdbsam 
>> --with-ldap --with-python=python2.3 --with-mysql --enable-mysql 
>> --with-mysql-prefix=/usr/local/mysql --with-expsam=mysql
>
>



More information about the samba mailing list