View Issue Details

IDProjectCategoryView StatusLast Update
0001557XdebugInstallationpublic2018-06-12 12:47
Reporterjwoods Assigned Toderick  
PrioritylowSeverityminorReproducibilityalways
Status closedResolutionfixed 
PlatformSolarisOSSolaris x86OS Version11.3.29.5.0
Product Version2.6.0 
Fixed in Version2.6.1 
Summary0001557: Compile error: "void function cannot return value", in xdebug_stack.c, line 1159
Description

Our PHP was compiled using the Solaris Studio 12.6 compiler instead of GCC.

The "make" fails on xdebug_stack.c, with the error:
"{path}/xdebug_stasck.c", line 1159: void function cannot return value"

Steps To Reproduce

export CC=cc
export CFLAGS="-m64"

phpize --clean
phpize

./configure --enable-xdebug
make

Additional Information

The function xdebug_build_fname() is declared as a void function. Yet, within the function, there is a recursive call to itself, on line 1159.

I suspect that the GCC compiler doesn't complain about this, or only generates a warning. But the Solaris Studio compiler errors out altogether.

Removing the "return" from this line causes the code to compile. I suspect that is the fix.

TagsNo tags attached.
Operating SystemSolaris x86
PHP Version7.1.15-7.1.19

Activities

derick

2018-06-12 12:47

administrator   ~0004672

Fixed in GIT - thanks for your report!

It's curious why GCC doesn't warn about this though. I did have a try at finding out what the C standard actually says, but couldn't find it either way in there either. Let's hope this fixes the compile for you.

Issue History

Date Modified Username Field Change
2018-06-11 16:41 jwoods New Issue
2018-06-12 12:47 derick Note Added: 0004672
2018-06-12 12:47 derick Status new => closed
2018-06-12 12:47 derick Assigned To => derick
2018-06-12 12:47 derick Resolution open => fixed
2018-06-12 12:47 derick Fixed in Version => 2.6.1