Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » PHP Development Tools (PDT) » Can't Configure PDT Include Path to find the GD library
Can't Configure PDT Include Path to find the GD library [message #70343] Tue, 13 May 2008 07:57 Go to next message
Eclipse UserFriend
Originally posted by: Andre_Mikulec.Hotmail.com

Hi,

I have configured my eclipse PDT include path to be the following.

H:\xampplite\php
H:\xampplite\php\ext
H:\xampplite\php\pear
H:\xampplitevhgraph

The folder H:\xampplitevhgraph contains the library class.graph1.

A snippet from class.graph1 reads


# Check for GD installation
if(!function_exists('imagecreate')) {
die('VH Graph Requires GD library with PHP');
}


In my testing index.php, I have the following code.

include('class.graph1');


When my testing index.php file runs, eclipse PDT returns the result

VH Graph Requires GD library with PHP


When browse to the url http://localhost/webs/test/index.php, the GD
graphic is returned as expected.

I performed a search for "GD" in my "php" folder.
This returned gds32.dll in my H:\xampplite\php folder.
This also returned php_gd2.dll in my H:\xampplite\php\ext folder.

That is why added
H:\xampplite\php
H:\xampplite\php\ext

to the PDT Include Path to try to help find the GD library.

Does anyoone have any idea of how I can onfigure Include Path to find the
GD library?

Thank you very much,

Andre Mikulec
Andre_Mikulec@Hotmail.com
Re: Can't Configure PDT Include Path to find the GD library [message #70363 is a reply to message #70343] Tue, 13 May 2008 08:57 Go to previous messageGo to next message
Lester Caine is currently offline Lester CaineFriend
Messages: 65
Registered: July 2009
Member
Andre Mikulec wrote:
> I have configured my eclipse PDT include path to be the following.
Not sure you have a PDT problem here - just normal PHP set-up?

> When browse to the url http://localhost/webs/test/index.php, the GD
> graphic is returned as expected.
Is that returning phpinfo? - So that GD has been switched on?

> I performed a search for "GD" in my "php" folder.
> This returned gds32.dll in my H:\xampplite\php folder.
Not relevant to GD that is the interbase/firebird client ;)

> This also returned php_gd2.dll in my H:\xampplite\php\ext folder.
That is the one for GD2

> Does anyoone have any idea of how I can onfigure Include Path to find
> the GD library?
Have you uncommented the php_gd2.dll line in php.ini and restarted PHP

Also normally I would have the library files in the web tree, but it may be
that you need to add the gd path to the 'include file' entry in php.ini. BUT I
don't think that is the case here since the library is an installed module,
and the include file would point to included php scripts not modules.

--
Lester Caine - G8HFL
-----------------------------
Contact - http://home.lsces.co.uk/lsces/wiki/?page=contact
L.S.Caine Electronic Services - http://home.lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
Re: Can't Configure PDT Include Path to find the GD library [message #70550 is a reply to message #70363] Tue, 13 May 2008 23:21 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: Andre_Mikulec.Hotmail.com

The left column shows modules that I have when I do a phpinfo() from
http://localhost/webs/test/index.php and do not have when I do a phpinfo()
from within the eclipse PDT.

The right column shows the modules that I have when I do a phpinfo() from
inside the eclipse PDT and do not have when I do a phpinfo() from within
http://localhost/webs/test/index.php. This loan library is cgi-fcgi.



zip cgi-fcgi
xsl
SQLite
sockets
soap
pdf
PDO
pdo_mssq
pdo_mysql
pgsql
mysqli
mysql
mssql
mssql
mime_magic
mbstring
imap
gettext
gd
exif
HTTP Headers Information
Apache Environment
apache2handler

I have noticed that my configuration file for
http://localhost/webs/test/index.php is the following.
H:\xampplite\apache\bin\php.ini

_ENV["PHPRC"] does not exist.

In both the H:\xampplite\php\php.ini and the
H:\xampplite\apache\bin\php.ini the
extension=php_gd2.dll
is uncommented.

To make sure I copied over the apache\bin\php.ini to the php\php.ini file.
I shut down apache.
I shut down the eclipse PDT.
I started apache.
I started the eclipse PDT.

I re-ran the phpinof() test on the eclipse PDT and the localhost.
Again, the gd library is missing from the eclipse PDT phpinof() output.


My configuration file for the eclipse pdt is the following.
F:\Documents and Settings\Administrator\Local
Settings\Temp\zend_debug\session38673.tmp\php.ini
AND
PHPRC F:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\zend_debug\session32414.t mp

Its loan contents are the following.
These include_path entries I made in the Eclipse PDT Configure Include
Path.

include_path=" .;H:\xampplitevhgraph;H:\xampplitenusoap\lib;H:\xampplite\ht docs\webs\test;H:\xampplite\php\ext;H:\xampplite\php;H:\xamp plitesmarty;H:\xampplite\php\pear "
zend_extension_ts=" H:\xamppliteeclipse\eclipse\plugins\org.zend.php.debug.debug ger.win32.x86_5.2.12.v20071210\resources\php5\ZendDebugger.d ll "

Note, "cgi" of cgi-fcgi does not exist in either php file and is still
appearing in the phpinfo() output as a library.


The org.eclipse.php.core.projectOptions.prefs file looks like the
following.

#Tue May 13 03:33:34 EDT 2008
eclipse.preferences.version=1
org.eclipse.php.core.contextRoot=
org.eclipse.php.core.defaultEncoding=
org.eclipse.php.core.includePath=<?xml version\="1.0"
encoding\="UTF-8"?>\r\n<includepath>\r\n\t<includepathentry
createdReference\="false" path\="H\:/xampplite/php" contentKind\="source"
kind\="lib">\r\n</includepathentry>\r\n<includepathentry
createdReference\="false" path\="H\:/xampplite/php/ext"
contentKind\="source"
kind\="lib">\r\n</includepathentry>\r\n<includepathentry
createdReference\="false" path\="H\:/xampplite/php/pear"
contentKind\="source"
kind\="lib">\r\n</includepathentry>\r\n<includepathentry
createdReference\="false" path\="H\:/xampplitenusoap/lib"
contentKind\="source"
kind\="lib">\r\n</includepathentry>\r\n<includepathentry
createdReference\="false" path\="H\:/xampplitevhgraph"
contentKind\="source"
kind\="lib">\r\n</includepathentry>\r\n<includepathentry
createdReference\="false" path\="H\:/xampplitesmarty"
contentKind\="source"
kind\="lib">\r\n</includepathentry>\r\n</includepath>\r\n

I have read the following from the following url:
http://www.drupal.cz/forum/instalace-drupalu/the-gd-library- for-php-is-missing-or-outdated

In order for PHP to ; read it, it must be named &#8218;php.ini&#8216;. PHP
looks for it in the current ; working directory, in the path designated by
the environment variable ; PHPRC, and in the path that was defined in
compile time (in that order). ; Under Windows, the compile-time path is
the Windows directory. The ; path in which the php.ini file is looked for
can be overridden using ; the -c argument in command line mode. ;


I have done some experimenting and testing by renaming my php.ini files to
php.ini.MISSING.
The current directory test does not seem to work for php itself.
Then enviromental variable setting of PHPRC does not work for the eclipse
PDT.

The situation seems that PHP has a built-in compiled php.ini that it loads
when it can not find a php.ini file.

The ecplipse PDT should read the PHPRC enviromental variable. It does not
do this. The eclipse PDT uses its own zend debugger. (This has been good
up to this point. Now, this does not seem so good.).
Logically, if it uses its own Zend debugger, then it applies its own
configuration PLUS whatever is found in "Configure Include Path" Projects
and Libraries.

Unfortunately, I do not see a way to 'recognize' dlls, such as GD's
php_gd2.dll


Any ideas?

Andre Mikulec
Re: Can't Configure PDT Include Path to find the GD library [message #70769 is a reply to message #70550] Wed, 14 May 2008 06:48 Go to previous messageGo to next message
Lester Caine is currently offline Lester CaineFriend
Messages: 65
Registered: July 2009
Member
Andre Mikulec wrote:
> To make sure I copied over the apache\bin\php.ini to the php\php.ini file.

C:\windows\php.ini
On all my windows systems php.ini has to be in the windows route directory ;)

--
Lester Caine - G8HFL
-----------------------------
Contact - http://home.lsces.co.uk/lsces/wiki/?page=contact
L.S.Caine Electronic Services - http://home.lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
Re: Can't Configure PDT Include Path to find the GD library [message #71067 is a reply to message #70769] Sat, 17 May 2008 12:58 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: Andre_Mikulec.Hotmail.com

"C:\windows\php.ini
On all my windows systems php.ini has to be in the windows route directory"

I tried that. I still have the same results when I use phpinfo(). When I
browse to http://localhost/webs/test/index.php I get the gd library.
When I debug within eclipse, I do not get the gd library.


Andre Mikulec
Re: Can't Configure PDT Include Path to find the GD library [message #71087 is a reply to message #70363] Sat, 17 May 2008 13:04 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: Andre_Mikulec.Hotmail.com

Perhaps, I found the php.ini and the *.dll files.

For PHP 5 and my exact version of
org.zend.php.debug.debugger.win32.x86_5.2.12.v20071210, these files seem
to be here.
H:\xamppliteeclipse\eclipse\plugins\org.zend.php.debug.debug ger.win32.x86_5.2.12.v20071210\resources\php5

Andre Mikulec
Re: Can't Configure PDT Include Path to find the GD library [message #71106 is a reply to message #71087] Sat, 17 May 2008 13:25 Go to previous message
Eclipse UserFriend
Originally posted by: Andre_Mikulec.Hotmail.com

Worked!

In
H:\xamppliteeclipse\eclipse\plugins\org.zend.php.debug.debug ger.win32.x86_5.2.12.v20071210\resources\php5
I renamed php.ini to php.ini.ORIGINAL in the folder above.
I copied my my php.ini file from apache\bin\php.ini to the folder above.

Appended the line "zend_extension_ts=.\ZendDebugger.dll" from the
php.ini.ORIGINAL to the end of the contents in php.ini in the above folder.

I restarted the eclipse PDT.

In my index.php the phpinfo() returns the gd library as it should.

Andre Mikulec
Previous Topic:Function hover and navigation
Next Topic:PDT help not showing up
Goto Forum:
  


Current Time: Fri Apr 19 15:32:34 GMT 2024

Powered by FUDForum. Page generated in 0.02102 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top