GCC troubles in FreeBSD 9

This is a discussion on GCC troubles in FreeBSD 9 within the C Programming forums, part of the General Programming Boards category; Hi, I have an installation of GCC on FreeBSD 9 which I suspect is broken somewhere, it all happend after ...

  1. #1
    Registered User
    Join Date
    Oct 2012
    Posts
    2

    Question GCC troubles in FreeBSD 9

    Hi,

    I have an installation of GCC on FreeBSD 9 which I suspect is broken somewhere, it all happend after I installed a webalizer package which started to install a new compiler.

    I can compile most things but with anything that is related with PHP I can not compile at all.

    I am getting errors like the following here:

    For PHP5-Session:
    Code:
     gcc46 -I. -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -DPHP_ATOM_INC -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/include -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/main -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fno-strict-aliasing -c /usr/ports/www/php5-session/work/php-5.4.7/ext/session/mod_user_class.c  -fPIC -DPIC -o .libs/mod_user_class.o
     gcc46 -I. -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -DPHP_ATOM_INC -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/include -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/main -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fno-strict-aliasing -c /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c  -fPIC -DPIC -o .libs/session.o
     gcc46 -I. -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -DPHP_ATOM_INC -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/include -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/main -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fno-strict-aliasing -c /usr/ports/www/php5-session/work/php-5.4.7/ext/session/mod_mm.c  -fPIC -DPIC -o .libs/mod_mm.o
     gcc46 -I. -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -DPHP_ATOM_INC -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/include -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/main -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fno-strict-aliasing -c /usr/ports/www/php5-session/work/php-5.4.7/ext/session/mod_user.c  -fPIC -DPIC -o .libs/mod_user.o
     gcc46 -I. -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -DPHP_ATOM_INC -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/include -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session/main -I/usr/ports/www/php5-session/work/php-5.4.7/ext/session -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -O2 -pipe -fno-strict-aliasing -c /usr/ports/www/php5-session/work/php-5.4.7/ext/session/mod_files.c  -fPIC -DPIC -o .libs/mod_files.o
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c: In function 'php_session_cache_limiter':
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1129:39: warning: initialization makes pointer from integer without a cast [enabled by default]
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c: In function 'php_session_send_cookie':
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1169:39: warning: initialization makes pointer from integer without a cast [enabled by default]
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c: In function 'zif_session_set_save_handler':
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1599:3: error: unknown type name 'php_shutdown_function_entry'
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1634:27: error: request for member 'arg_count' in something not a structure or union
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1635:27: error: request for member 'arguments' in something not a structure or union
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1639:27: error: request for member 'arguments' in something not a structure or union
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1644:5: error: request for member 'arguments' in something not a structure or union
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c: In function 'zif_session_register_shutdown':
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1930:2: error: unknown type name 'php_shutdown_function_entry'
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1940:25: error: request for member 'arg_count' in something not a structure or union
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1941:25: error: request for member 'arguments' in something not a structure or union
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1945:25: error: request for member 'arguments' in something not a structure or union
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:1949:3: error: request for member 'arguments' in something not a structure or union
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c: In function 'zm_startup_session':
    /usr/ports/www/php5-session/work/php-5.4.7/ext/session/session.c:2185:2: error: too many arguments to function 'zend_register_auto_global'
    /usr/local/include/php/Zend/zend_compile.h:605:14: note: declared here
    *** Error code 1
    1 error
    *** Error code 1
    
    Stop in /usr/ports/www/php5-session.
    For ROUNDCUBE (which also using PHP5-Session):
    Code:
    gcc46 -I/usr/local/include -I. -I/usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv -DPHP_ATOM_INC -I/usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/include -I/usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/main -I/usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/usr/local/include -DHAVE_CONFIG_H -I/usr/local/include -O2 -pipe -fno-strict-aliasing -c /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c  -fPIC -DPIC -o .libs/iconv.o
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:213:1: error: unknown type name 'php_output_handler'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:214:53: error: unknown type name 'php_output_context'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:327:1: error: unknown type name 'php_output_handler'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c: In function 'php_iconv_output_handler_init':
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:329:76: error: 'php_iconv_output_handler' undeclared (first use in this function)
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:329:76: note: each undeclared identifier is reported only once for each function it appears in
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c: At top level:
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:332:53: error: unknown type name 'php_output_context'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c: In function '_php_iconv_appendl':
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:401:4: warning: passing argument 2 of 'libiconv' from incompatible pointer type [enabled by default]
    /usr/local/include/iconv.h:83:15: note: expected 'const char **' but argument is of type 'char **'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c: In function 'php_iconv_string':
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:569:3: warning: passing argument 2 of 'libiconv' from incompatible pointer type [enabled by default]
    /usr/local/include/iconv.h:83:15: note: expected 'const char **' but argument is of type 'char **'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c: In function '_php_iconv_strlen':
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:683:3: warning: passing argument 2 of 'libiconv' from incompatible pointer type [enabled by default]
    /usr/local/include/iconv.h:83:15: note: expected 'const char **' but argument is of type 'char **'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c: In function '_php_iconv_substr':
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:804:3: warning: passing argument 2 of 'libiconv' from incompatible pointer type [enabled by default]
    /usr/local/include/iconv.h:83:15: note: expected 'const char **' but argument is of type 'char **'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c: In function '_php_iconv_strpos':
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:936:3: warning: passing argument 2 of 'libiconv' from incompatible pointer type [enabled by default]
    /usr/local/include/iconv.h:83:15: note: expected 'const char **' but argument is of type 'char **'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c: In function '_php_iconv_mime_encode':
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:1185:6: warning: passing argument 2 of 'libiconv' from incompatible pointer type [enabled by default]
    /usr/local/include/iconv.h:83:15: note: expected 'const char **' but argument is of type 'char **'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:1285:6: warning: passing argument 2 of 'libiconv' from incompatible pointer type [enabled by default]
    /usr/local/include/iconv.h:83:15: note: expected 'const char **' but argument is of type 'char **'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c: In function 'php_iconv_stream_filter_append_bucket':
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:2558:4: warning: passing argument 2 of 'libiconv' from incompatible pointer type [enabled by default]
    /usr/local/include/iconv.h:83:15: note: expected 'const char **' but argument is of type 'char **'
    /usr/ports/converters/php5-iconv/work/php-5.4.7/ext/iconv/iconv.c:2637:6: warning: passing argument 2 of 'libiconv' from incompatible pointer type [enabled by default]
    /usr/local/include/iconv.h:83:15: note: expected 'const char **' but argument is of type 'char **'
    *** Error code 1
    1 error
    *** Error code 1
    
    Stop in /usr/ports/converters/php5-iconv.
    *** Error code 1
    
    Stop in /usr/ports/mail/roundcube.
    *** Error code 1
    
    Stop in /usr/ports/mail/roundcube.
    Does anyone have any clue how to solve this? The most works perfectly to compile, but PHP is no no anymore

  2. #2
    Registered User
    Join Date
    Oct 2012
    Posts
    2
    No one have any ideas how I can try to solve this?

  3. #3
    Registered User
    Join Date
    May 2009
    Posts
    2,372
    Try this compiler option to see if include directory is missing.

    Code:
    -Wmissing-include-dirs
    Other useful compiler options to try
    Code:
    -Wmissing-prototypes
    -Wmissing-declarations
    Tim S.
    Last edited by stahta01; 10-30-2012 at 06:53 PM.
    "Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to produce bigger and better idiots. So far, the Universe is winning." Rick Cook

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. FreeBSD 5.4
    By ElastoManiac in forum A Brief History of Cprogramming.com
    Replies: 2
    Last Post: 12-13-2005, 05:04 PM
  2. FreeBSD rc.d
    By ginoitalo in forum Tech Board
    Replies: 1
    Last Post: 09-05-2004, 12:13 PM
  3. FreeBSD
    By confuted in forum Tech Board
    Replies: 10
    Last Post: 09-16-2003, 07:05 PM
  4. FreeBSD rocks!
    By frenchfry164 in forum A Brief History of Cprogramming.com
    Replies: 7
    Last Post: 08-25-2003, 08:11 PM
  5. Porting to FreeBSD
    By Beastie in forum Linux Programming
    Replies: 1
    Last Post: 06-15-2003, 07:37 PM

Tags for this Thread


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21