Skip to Content.
Sympa Menu

freetds - PHP 3.0.15 Problems: Works, sort of.

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "J. Hatch" <zone AT your-site.com>
  • To: freetds AT franklin.oit.unc.edu
  • Subject: PHP 3.0.15 Problems: Works, sort of.
  • Date: Thu, 20 Apr 2000 11:48:24 -0400 (EDT)



Boy, you guys love to keep us guessing! I spent all night (all night)
getting PHP to compile with FreeTDS. I had to put the pieces together from
the mailing list, take a guess, and basically _not_ do what the web site
says. I'm even guessing at what address to send this message to as my
confirmation message didn't say where to post.

Ok, enough griping :-).

I'm using .50 on Solaris 7 with PHP 3.0.15. I've compiled my FreeTDS as
follows:

./configure --with-tdsver=4.2 --enable-msdblib --enable-dbmfix

None of the tests worked, every one failed. I had to edit the Makefile in
each of the src/*/unittests directory to add -lnls and -lresolv becuase
configure didn't do it. Then I got segfaults for each test. I had the PWD
in my top level build directory along with an "interface" file but I had
to make my interface file /.interface because for some reason the script
wasn't opening $SYBASE/interfaces. Finally, I got all but one test to
pass.

For PHP, I _had_ to use --with-sybase-ct=/usr/local/freetds and I _had_ to
edit functions/sybase.c to rename the dbopen() calls to tdsdbopen(). I
also had to add -R/usr/local/freetds/lib to the LIBS line of the PHP
Makefile because I don't like cludging up LD_LIBRARY_PATH's and php
wouldn't run without it. Another key point (thanks to this list) was to
remove the -lcs -lcomn -lsybtcl from the MULTIPLE places it appeared in
the PHP Makefile. Finally after trying a gazillion combinations,
the one above worked.

Now for my problem. I can connect to mssql via PHP3. I can retrieve large
amounts of data (say 5cols x 575rows). However, I _cannot_ receive integer
data. I have one column that's an integer, and it always crashes PHP and
drops core. I've tried running it on the commandline setting TDSDUMP and
the log file is empty every time.

Does anyone know what might fix this? Also, I've seen lots of messages in
this list saying that upgrading to the latest snapshot fixes a lot of
these problems, however it will NOT compile on Solaris. I get an error on
login.c about FIONBIO (and so have many others on the list). I hear a
mention from Brian about a patch for this, but I cannot find it. Does
anyone know how to get the latest snapshot to compile on Solaris?

Thanks,

-Jason (tired and weary)


----------------------------------------------------------
Jason Hatch, Owner and Network Administrator
Your Site Virtual Server Solutions
(413) 499-6690 (voice) (413) 499-4504 (fax)
Visit our Web Site at http://www.your-site.com
We offer quality Web Hosting for as low as $5/mo!
----------------------------------------------------------





Archive powered by MHonArc 2.6.24.

Top of Page