Re: Compiling freeradius with rlm_sql_sybase
"Paul Hampson" <[EMAIL PROTECTED]> wrote: > and the following patch to sql_sybase.c (Broken whitespace, but it > should be obvious what to change.) which I suspect is only needed > for gcc 3.2+. Added, thanks. Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Re: Compiling freeradius with rlm_sql_sybase
> I just tried it then, and the libct in Debian (0.61) built with the > following Makefile segment (although I've made slight changes to the build > system, but these should be OK) > > TARGET = rlm_sql_sybase > SRCS = sql_sybase.c > RLM_SQL_CFLAGS = $(INCLTDL) > RLM_SQL_LIBS = -lnsl -lct It connects to my mssql server! Great ! I didn't use your patch on sql_sybase.c, just modified the Makefile. Do you know if it's possible to run stored procedures on mssql from freeradius ? Mvh, Regards, Eivind Ravndal NetPower Int - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
RE: Compiling freeradius with rlm_sql_sybase
> From: Paul Hampson > Sent: Wednesday, 16 July 2003 5:41 PM > > From: Eivind Ravndal > > Sent: Wednesday, 16 July 2003 5:10 PM > > > > From: "Alan DeKok" <[EMAIL PROTECTED]> > > > To: <[EMAIL PROTECTED]> > > > > > Anybody successfully compiled freeradius with rlm_sql_sybase ? > > > > I think there's something wrong with my Makefile > > > > /freeradius-0.8.1/src/modules/rlm_sql/drivers/rlm_sql_sybase/Makefile > > > > Did you try reading it? It says you've got to edit it by hand to > > > get it to work. > > > I've read it, but I don't know what to change. So I was hoping someone > > who've compiled it successfully would paste me their MakeFile so I could get > > some ideas. I am pretty sure this line is the one which is wrong: > > --- > > RLM_SQL_LIBS > > = -L/opt/sybase/OCS-12_0/lib -ltcl -lcomn -lintl -lnsl -ldl -lm -lcs -lct > > --- > > When I comment out this line, it compiles and installs just fine, but it > > will not run since there's missing some libs. > I was going to have a play with that post-0.9, to see if I could integrate > it into the rest of the build system... But I don't use sybase so it would > be a mainly academic exercise. I just tried it then, and the libct in Debian (0.61) built with the following Makefile segment (although I've made slight changes to the build system, but these should be OK) TARGET = rlm_sql_sybase SRCS = sql_sybase.c RLM_SQL_CFLAGS = $(INCLTDL) RLM_SQL_LIBS = -lnsl -lct and the following patch to sql_sybase.c (Broken whitespace, but it should be obvious what to change.) which I suspect is only needed for gcc 3.2+. Still a ton of warnings though, mainly prototype issues from which many of the sql drivers suffer. --- /home/tbble/frcvs/branch_0_9/src/modules/rlm_sql/drivers/rlm_sql_sybase/sql_sybase.c 2002-07-30 00:59:13.0 +1000 +++ sql_sybase.c2003-07-16 17:48:52.0 +1000 @@ -344,7 +344,7 @@ if ((results_ret = ct_results(sybase_sock->command, &result_type)) == CS_SUCCEED) { if (result_type != CS_CMD_SUCCEED) { if (result_type == CS_ROW_RESULT) { - radlog(L_ERR,"rlm_sql_sybase(sql_query): sql_query processed a query returning rows. + radlog(L_ERR,"rlm_sql_sybase(sql_query): sql_query processed a query returning rows.\ Use sql_select_query instead!"); } radlog(L_ERR,"rlm_sql_sybase(sql_query): Result failure or unexpected result type from query\n%s", This was against 0.9.0-pre2, BTW. I doubt it's different in CVS HEAD, or pre3. -- = Paul "TBBle" Hampson Bubblesworth Pty Ltd (ABN: 51 095 284 361) [EMAIL PROTECTED] This is a one line proof...if we start sufficiently far to the left. -- Cambridge University Math Department - Random signature generator 3.0 by Paul "TBBle" Hampson = - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
RE: Compiling freeradius with rlm_sql_sybase
> From: Eivind Ravndal > Sent: Wednesday, 16 July 2003 5:10 PM > > From: "Alan DeKok" <[EMAIL PROTECTED]> > > To: <[EMAIL PROTECTED]> > > > Anybody successfully compiled freeradius with rlm_sql_sybase ? > > > I think there's something wrong with my Makefile > > > /freeradius-0.8.1/src/modules/rlm_sql/drivers/rlm_sql_sybase/Makefile > > Did you try reading it? It says you've got to edit it by hand to > > get it to work. > I've read it, but I don't know what to change. So I was hoping someone > who've compiled it successfully would paste me their MakeFile so I could get > some ideas. I am pretty sure this line is the one which is wrong: > --- > RLM_SQL_LIBS > = -L/opt/sybase/OCS-12_0/lib -ltcl -lcomn -lintl -lnsl -ldl -lm -lcs -lct > --- > When I comment out this line, it compiles and installs just fine, but it > will not run since there's missing some libs. Assuming you're using libct to compile it, try changing the /opt/sybase/OCS-12_0/lib to the directory where libct.so is on your system. You're also going to have to make the /opt/sybase/OCS-12_0/include on the previous instead be the directory that ctpublic.h lives in. (These two steps should be unneccessary if your libct.so lives in /usr/lib and your ctpublic.h lives in /usr/include, eg. freetds-dev package in Debian, and presumably the equivalent pacakges in other Linux distributions) Then make the TARGET line be TARGET = rlm_sql_sybase Then run make in that directory, and see if it works... Otherwise, maybe the libct you've got installed came with some documentation? I was going to have a play with that post-0.9, to see if I could integrate it into the rest of the build system... But I don't use sybase so it would be a mainly academic exercise. -- = Paul "TBBle" Hampson Bubblesworth Pty Ltd (ABN: 51 095 284 361) [EMAIL PROTECTED] This is a one line proof...if we start sufficiently far to the left. -- Cambridge University Math Department - Random signature generator 3.0 by Paul "TBBle" Hampson = - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Re: Compiling freeradius with rlm_sql_sybase
- Original Message - From: "Alan DeKok" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, July 15, 2003 6:06 PM Subject: Re: Compiling freeradius with rlm_sql_sybase > > Anybody successfully compiled freeradius with rlm_sql_sybase ? > > I think there's something wrong with my Makefile > > /freeradius-0.8.1/src/modules/rlm_sql/drivers/rlm_sql_sybase/Makefile > > Did you try reading it? It says you've got to edit it by hand to > get it to work. Yes, I've read it, but I don't know what to change. So I was hoping someone who've compiled it successfully would paste me their MakeFile so I could get some ideas. I am pretty sure this line is the one which is wrong: --- RLM_SQL_LIBS = -L/opt/sybase/OCS-12_0/lib -ltcl -lcomn -lintl -lnsl -ldl -lm -lcs -lct --- When I comment out this line, it compiles and installs just fine, but it will not run since there's missing some libs. Mvh, Regards, Eivind Ravndal NetPower Int - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Re: Compiling freeradius with rlm_sql_sybase
"Eivind Ravndal" <[EMAIL PROTECTED]> wrote: > Anybody successfully compiled freeradius with rlm_sql_sybase ? > I think there's something wrong with my Makefile > /freeradius-0.8.1/src/modules/rlm_sql/drivers/rlm_sql_sybase/Makefile Did you try reading it? It says you've got to edit it by hand to get it to work. Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Re: Compiling freeradius with rlm_sql_sybase
I had problems with MySQL with 0.8.1. Maybe try the newest snapshot from CVS? - Original Message - From: "Eivind Ravndal" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, July 15, 2003 7:09 AM Subject: Compiling freeradius with rlm_sql_sybase > Using version 0.8.1 > > Anybody successfully compiled freeradius with rlm_sql_sybase ? > I think there's something wrong with my Makefile > /freeradius-0.8.1/src/modules/rlm_sql/drivers/rlm_sql_sybase/Makefile > > could anyone please paste your Makefile for Sybase ? > > > Mvh, > Regards, > Eivind Ravndal > > - > List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html