Edit report at https://bugs.php.net/bug.php?id=64061&edit=1

 ID:                 64061
 Updated by:         [email protected]
 Reported by:        stephencoxmail at gmail dot com
 Summary:            GD extension fails to build when png.h is not found
 Status:             Open
 Type:               Bug
 Package:            GD related
 Operating System:   Windows
 PHP Version:        5.4.11
 Block user comment: N
 Private report:     N

 New Comment:

You only need to copy the error here, not the full log.


Previous Comments:
------------------------------------------------------------------------
[2013-01-25 21:35:41] mirco dot babin at gmail dot com

Regarding my previous comment, I uploaded compilation.txt to pastebin. You can 
see 
it at http://pastebin.com/p07WQCAU

------------------------------------------------------------------------
[2013-01-25 21:20:37] mirco dot babin at gmail dot com

Configure now works correctly (without the patch). I downloaded the php 5.4.11 
sources and the php 5.4 dependencies. 

Unfortunately building PHP fails. I did build php 5.4.10 correctly.

Compilation is done using the steps provided in 
https://wiki.php.net/internals/windows/stepbystepbuild on:
- Windows/XP in a VirtualBox (fully updated)
- Microsoft Visual Studio 2008 Express
- Windows SDK 6.1 command prompt (don't use the Visual Studio command prompt, 
as 
it does not execute SETENV correctly)

call configure "--enable-snapshot-build" "--disable-isapi" "--disable-cgi" "--
enable-cli" "--disable-nsapi" "--disable-apache" "--disable-apache2-2filter" "--
disable-apache2-2handler" "--disable-embed" "--enable-cli-win32" "--enable-
debug-pack" "--without-mssql" "--without-pdo-mssql" "--without-pi3web" "--
enable-com-dotnet=shared" "--with-mcrypt=static" > configured.txt 2>&1

nmake snap > compilation.txt 2>&1

I don't know how to upload compilation.txt into this bug database. Pasting is 
refused (probably too big).

------------------------------------------------------------------------
[2013-01-25 20:49:44] [email protected]

We use libpng12. However we are adding libpng 1.5 support and we will allow 
both. 
The snaps and releases use the exact same dependencies, see 
http://windows.php.net/downloads/ (phpinfo shows you the configure line, if you 
like to reproduce).

------------------------------------------------------------------------
[2013-01-25 20:23:00] stephencoxmail at gmail dot com

Updating the directory name in the dependencies seems like the more efficient 
option.

I got GD to build by switching to a different libpng (Can remember exactly), 
but 
I will post a different bug for that.

------------------------------------------------------------------------
[2013-01-25 20:14:29] mirco dot babin at gmail dot com

After downloading again:
1) http://windows.php.net/downloads/php-sdk/deps-5.4-vc9-x86.7z
2) http://windows.php.net/downloads/php-sdk/deps/libxpm-3.5.10-vc9-x86.zip

The GD extension is enabled by configure. Building php with the new 
dependencies 
fails. I post the output here, but I don't think it belongs to this bug.

As a sidenote, the patch and the new dependencies 1) conflict with each other. 
The patch renames libpng12 to libpng in config.w32. 
The new dependencies install libpng12.

So it seems like there is some mis-communication what the best path is to take. 
Updating config.w32 or updating the directoryname in the dependencies.

Configure output:
-----------------
[... Snip ...]

Checking for library vpxmt.lib ... ..\deps\lib\vpxmt.lib
Checking for library libjpeg_a.lib;libjpeg.lib ... ..\deps\lib\libjpeg_a.lib
Checking for library freetype_a.lib;freetype.lib ... ..\deps\lib\freetype_a.lib
Checking for library libpng_a.lib;libpng.lib ... ..\deps\lib\libpng_a.lib
Checking for gd.h ...  ext\gd\libgd
Checking for png.h ...  C:\php-sdk\php54dev\vc9\x86\deps\include\libpng
Checking for library libiconv_a.lib;libiconv.lib ... ..\deps\lib\libiconv_a.lib
Checking for iconv.h ...  C:\php-sdk\php54dev\vc9\x86\deps\include
Checking for library libXpm_a.lib ... ..\deps\lib\libXpm_a.lib
Checking for xpm.h ...  C:\php-sdk\php54dev\vc9\x86\deps\include\X11
Checking for library T1_StaticMD.lib ... <not found>
WARNING: t1lib not enabled; libraries and headers not found

Checking for library User32.lib ... <in LIB path> User32.Lib
Checking for library Gdi32.lib ... <in LIB path> Gdi32.Lib
Enabling extension ext\gd [shared]

[... Snip ...]


Failure building:
-----------------
Generating Code...
        "cl.exe" /D _USRDLL /D PHP5DLLTS_EXPORTS /D PHP_EXPORTS /D LIBZEND_EXPOR
TS /D TSRM_EXPORTS /D SAPI_EXPORTS /D WINVER=0x500 /D COMPILE_DL_BZ2 /D COMPILE_
DL_COM_DOTNET /D COMPILE_DL_CURL /D COMPILE_DL_ENCHANT /D COMPILE_DL_FILEINFO /D
 COMPILE_DL_GD /D COMPILE_DL_GETTEXT /D COMPILE_DL_GMP /D COMPILE_DL_IMAP /D COM
PILE_DL_INTERBASE /D COMPILE_DL_INTL /D COMPILE_DL_LDAP /D COMPILE_DL_MBSTRING /
D COMPILE_DL_OPENSSL /D COMPILE_DL_PGSQL /D COMPILE_DL_SHMOP /D COMPILE_DL_SNMP
/D COMPILE_DL_SOCKETS /D COMPILE_DL_SQLITE3 /D COMPILE_DL_SYBASE_CT /D COMPILE_D
L_TIDY /D COMPILE_DL_EXIF /D COMPILE_DL_MYSQL /D COMPILE_DL_MYSQLI /D COMPILE_DL
_PDO_FIREBIRD /D COMPILE_DL_PDO_MYSQL /D COMPILE_DL_PDO_ODBC /D COMPILE_DL_PDO_P
GSQL /D COMPILE_DL_PDO_SQLITE /D COMPILE_DL_SOAP /D COMPILE_DL_XMLRPC /D COMPILE
_DL_XSL -Iext/bcmath/libbcmath/src   -Iext/date/lib /wd4244 -Dregexec=php_regexe
c -Dregerror=php_regerror -Dregfree=php_regfree -Dregcomp=php_regcomp -Iext/ereg
/regex    /I "C:\php-sdk\php54dev\vc9\x86\deps\include"  /DHAVE_ICONV_H=1 /D PHP
_ICONV_EXPORTS  /I "C:\php-sdk\php54dev\vc9\x86\deps\include"  /DHAVE_MCRYPT_H=1
  /DHAVE_SQL_H=1 /DHAVE_SQLEXT_H=1 -Iext/pcre/pcrelib    /I "ext/date/lib"  /DHA
VE_TIMELIB_CONFIG_H=1 /I "ext\mbstring\oniguruma"  /DHAVE_ONIGURUMA_H=1  /I "C:\
php-sdk\php54dev\vc9\x86\deps\include"  /DHAVE_ZLIB_H=1 /D ZLIB_EXPORTS /I "C:\p
hp-sdk\php54dev\vc9\x86\deps\include"  /DHAVE_LIBXML_PARSER_H=1 /D LIBXML_STATIC
 /D LIBXML_STATIC_FOR_DLL /D HAVE_WIN32_THREADS /D LIBXML_STATIC   /D LIBXML_STA
TIC /D PHP_SIMPLEXML_EXPORTS /I "ext/date/lib"  /DHAVE_TIMELIB_CONFIG_H=1 /D LIB
XML_STATIC /D LIBXML_STATIC /I "C:\php-sdk\php54dev\vc9\x86\deps\include"  /DHAV
E_LIBXML_XMLWRITER_H=1 /D LIBXML_STATIC /nologo /FD /I . /I main /I Zend /I TSRM
 /I ext /D _WINDOWS /D ZEND_WIN32=1 /D PHP_WIN32=1 /D WIN32 /D _MBCS /W3   /wd49
96 /D_USE_32BIT_TIME_T=1   /MP  /Zi /LD /MD /W3 /Ox /D NDebug /D NDEBUG /D ZEND_
WIN32_FORCE_INLINE /GF /D ZEND_DEBUG=0 /D ZTS=1 /I "C:\php-sdk\php54dev\vc9\x86\
deps\include"  /D FD_SETSIZE=256  /analyze   /wd6308 /FoRelease_TS\TSRM\ /FdRele
ase_TS\TSRM\ /FpRelease_TS\TSRM\ /FRRelease_TS\TSRM\ /c TSRM\TSRM.c TSRM\tsrm_st
rtok_r.c TSRM\tsrm_virtual_cwd.c TSRM\tsrm_win32.c
TSRM.c
tsrm_strtok_r.c
tsrm_virtual_cwd.c
tsrm_win32.c
Running Code Analysis for C/C++...
c:\php-sdk\php54dev\vc9\x86\php-5.4.10-src\tsrm\tsrm_win32.c(169) : warning C601
1: Dereferencing NULL pointer 'pTokenUser': Lines: 142, 143, 144, 145, 146, 147,
 148, 151, 164, 169
c:\php-sdk\php54dev\vc9\x86\php-5.4.10-src\tsrm\tsrm_win32.c(215) : warning C632
8: 'const char' passed as parameter '1' when 'unsigned char' is required in call
 to 'isalpha'
c:\php-sdk\php54dev\vc9\x86\php-5.4.10-src\tsrm\tsrm_win32.c(543) : warning C638
7: 'argument 1' might be '0': this does not adhere to the specification for the
function 'CloseHandle': Lines: 459, 460, 461, 462, 463, 464, 465, 466, 467, 468,
 469, 470, 471, 472, 473, 475, 480, 481, 485, 486, 489, 485, 492, 493, 494, 496,
 500, 501, 503, 504, 505, 507, 508, 510, 515, 516, 517, 520, 521, 526, 529, 530,
 535, 536, 540, 541, 542, 543
c:\php-sdk\php54dev\vc9\x86\php-5.4.10-src\tsrm\tsrm_win32.c(642) : warning C601
1: Dereferencing NULL pointer 'shm->descriptor': Lines: 593, 594, 595, 596, 598,
 602, 603, 605, 606, 608, 618, 623, 624, 625, 626, 628, 642
c:\php-sdk\php54dev\vc9\x86\php-5.4.10-src\tsrm\tsrm_win32.c(644) : warning C638
7: 'argument 1' might be '0': this does not adhere to the specification for the
function 'UnmapViewOfFile': Lines: 593, 594, 595, 596, 598, 602, 603, 605, 606,
608, 618, 623, 624, 625, 626, 628, 642, 643, 644
C:\Program Files\Microsoft Visual Studio 9.0\VC\Include\tchar.h(1659) : fatal er
ror C1001: An internal error has occurred in the compiler.
(compiler file 'msc1ast.cpp', line 1411)
 To work around this problem, try simplifying or changing the program near the l
ocations listed above.
Please choose the Technical Support command on the Visual C++
 Help menu, or open the Technical Support help file for more information
Internal Compiler Error in C:\Program Files\Microsoft Visual Studio 9.0\VC\Bin\c
l.exe.  You will be prompted to send an error report to Microsoft later.
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 9.0\VC\Bin
\cl.exe"' : return code '0x1'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 9.0\VC\Bin
\nmake.exe"' : return code '0x2'
Stop.

------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    https://bugs.php.net/bug.php?id=64061


-- 
Edit this bug report at https://bugs.php.net/bug.php?id=64061&edit=1

Reply via email to