freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
Re: [freetds] FreeTDS 0.8.2 & PHP 5.2.6 won't compile php extension
- From: "James K. Lowden" <jklowden AT freetds.org>
- To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
- Subject: Re: [freetds] FreeTDS 0.8.2 & PHP 5.2.6 won't compile php extension
- Date: Mon, 3 Nov 2008 10:18:56 -0500
Alastair Hole wrote:
>
> Now when I add the '--with-dblib=shared' option to the php config
> command everything seems ok, so i run nmake and then get rather a lot of
> unresolved external symbol errors (see end of message)
>
> So my question is really does anyone know at which stage this is
> failing? Is it an issue with my build of FreeTDS or is it an issue with
> FreeTDS + PHP somehow. And has anyone successfully built freetds 0.8.2
> with php as the dblib/mssql extension on windows?
I can tell you what the problem is, but not how to fix it.
When you try to create dblib.lib, the linker is missing the .obj files
that contain the "unresolved" symbols it's complaining about. Those
symbols lie in the tds object files. Provide the linker with all the
object files it needs, and you're done.
On my system:
$ ls build/src/tds/*.o
build/src/tds/challenge.o build/src/tds/md5.o
build/src/tds/config.o build/src/tds/mem.o
build/src/tds/convert.o build/src/tds/net.o
build/src/tds/data.o build/src/tds/numeric.o
build/src/tds/des.o build/src/tds/query.o
build/src/tds/getmac.o build/src/tds/read.o
build/src/tds/gssapi.o build/src/tds/tds_checks.o
build/src/tds/hmac_md5.o build/src/tds/tdsstring.o
build/src/tds/iconv.o build/src/tds/threadsafe.o
build/src/tds/locale.o build/src/tds/token.o
build/src/tds/log.o build/src/tds/util.o
build/src/tds/login.o build/src/tds/vstrbuild.o
build/src/tds/md4.o build/src/tds/write.o
tds_prtype for example is in token.o:
$ for F in build/src/tds/*.o; do nm $F | grep tds_prtype | grep T; if [
$? = 0 ]; then echo $F; fi; done
000043b4 T tds_prtype
build/src/tds/token.o
You can use dumpbin.exe to do something similar.
It could be that you have something like tds.lib that lacks token.obj.
HTH.
--jkl
-
[freetds] FreeTDS 0.8.2 & PHP 5.2.6 won't compile php extension,
Alastair Hole, 11/03/2008
- Re: [freetds] FreeTDS 0.8.2 & PHP 5.2.6 won't compile php extension, James K. Lowden, 11/03/2008
Archive powered by MHonArc 2.6.24.