census-instrumentation / opencensus-php

A stats collection and distributed tracing framework
Apache License 2.0
202 stars 83 forks source link

PHP 8 compatibility? #267

Closed MrMage closed 3 years ago

MrMage commented 3 years ago

I have tried to compile this extension with PHP 8, but ran into a lot of errors (see below).

Did anyone create a fork of this library that is compatible with PHP 8 yet?

  RUN git clone --recursive --depth=1 https://github.com/census-instrumentation/opencensus-php.git   && cd opencensus-php/ext   && phpize   && ./configure   && make -j $  (nproc)   && mv modules/opencensus.so ../..   && cd ../..   && rm -rf opencensus-php
   ---> Running in 5aa070962d2f
  Cloning into 'opencensus-php'...
  Configuring for:
  PHP Api Version:         20200930
  Zend Module Api No:      20200930
  Zend Extension Api No:   420200930
  checking for grep that handles long lines and -e... /usr/bin/grep
  checking for egrep... /usr/bin/grep -E
  checking for a sed that does not truncate output... /usr/bin/sed
  checking for pkg-config... /usr/bin/pkg-config
  checking pkg-config is at least version 0.9.0... yes
  checking for cc... cc
  checking whether the C compiler works... yes
  checking for C compiler default output file name... a.out
  checking for suffix of executables... 
  checking whether we are cross compiling... no
  checking for suffix of object files... o
  checking whether we are using the GNU C compiler... yes
  checking whether cc accepts -g... yes
  checking for cc option to accept ISO C89... none needed
  checking how to run the C preprocessor... cc -E
  checking for icc... no
  checking for suncc... no
  checking for system library directory... lib
  checking if compiler supports -R... no
  checking if compiler supports -Wl,-rpath,... yes
  checking build system type... x86_64-pc-linux-gnu
  checking host system type... x86_64-pc-linux-gnu
  checking target system type... x86_64-pc-linux-gnu
  checking for PHP prefix... /usr
checking for PHP includes... -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/  php/20200930/ext -I/usr/include/php/20200930/ext/date/lib
  checking for PHP extension directory... /usr/lib/php/20200930
  checking for PHP installed headers prefix... /usr/include/php/20200930
  checking if debug is enabled... no
  checking if zts is enabled... no
  checking for gawk... no
  checking for nawk... nawk
  checking if nawk is broken... no
  checking whether to enable my extension... yes, shared
  checking how to print strings... printf
  checking for a sed that does not truncate output... (cached) /usr/bin/sed
  checking for fgrep... /usr/bin/grep -F
  checking for ld used by cc... /usr/bin/ld
  checking if the linker (/usr/bin/ld) is GNU ld... yes
  checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
  checking the name lister (/usr/bin/nm -B) interface... BSD nm
  checking whether ln -s works... yes
  checking the maximum length of command line arguments... 1572864
  checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop
  checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop
  checking for /usr/bin/ld option to reload object files... -r
  checking for objdump... objdump
  checking how to recognize dependent libraries... pass_all
  checking for dlltool... no
  checking how to associate runtime and link libraries... printf %s\n
  checking for ar... ar
  checking for archiver @FILE support... @
  checking for strip... strip
  checking for ranlib... ranlib
  checking for gawk... (cached) nawk
  checking command to parse /usr/bin/nm -B output from cc object... ok
  checking for sysroot... no
  checking for a working dd... /usr/bin/dd
  checking how to truncate binary pipes... /usr/bin/dd bs=4096 count=1
  checking for mt... no
  checking if : is a manifest tool... no
  checking for ANSI C header files... yes
  checking for sys/types.h... yes
  checking for sys/stat.h... yes
  checking for stdlib.h... yes
  checking for string.h... yes
  checking for memory.h... yes
  checking for strings.h... yes
  checking for inttypes.h... yes
  checking for stdint.h... yes
  checking for unistd.h... yes
  checking for dlfcn.h... yes
  checking for objdir... .libs
  checking if cc supports -fno-rtti -fno-exceptions... no
  checking for cc option to produce PIC... -fPIC -DPIC
  checking if cc PIC flag -fPIC -DPIC works... yes
  checking if cc static flag -static works... yes
  checking if cc supports -c -o file.o... yes
  checking if cc supports -c -o file.o... (cached) yes
  checking whether the cc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
  checking whether -lc should be explicitly linked in... no
  checking dynamic linker characteristics... GNU/Linux ld.so
  checking how to hardcode library paths into programs... immediate
  checking whether stripping libraries is possible... yes
  checking if libtool supports shared libraries... yes
  checking whether to build shared libraries... yes
  checking whether to build static libraries... no
  configure: patching config.h.in
  configure: creating ./config.status
  config.status: creating config.h
  config.status: executing libtool commands
/bin/bash /var/www/html/opencensus-php/ext/libtool --mode=compile cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib  -DHAVE_CONFIG_H  -g -O2    -c /var/www/html/opencensus-php/ext/opencensus.c -o   opencensus.lo 
/bin/bash /var/www/html/opencensus-php/ext/libtool --mode=compile cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib  -DHAVE_CONFIG_H  -g -O2    -c /var/www/html/opencensus-php/ext/varint.c -o   varint.lo 
/bin/bash /var/www/html/opencensus-php/ext/libtool --mode=compile cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib  -DHAVE_CONFIG_H  -g -O2    -c /var/www/html/opencensus-php/ext/  opencensus_core_daemonclient.c -o opencensus_core_daemonclient.lo 
/bin/bash /var/www/html/opencensus-php/ext/libtool --mode=compile cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib  -DHAVE_CONFIG_H  -g -O2    -c /var/www/html/opencensus-php/ext/  opencensus_trace.c -o opencensus_trace.lo 
/bin/bash /var/www/html/opencensus-php/ext/libtool --mode=compile cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib  -DHAVE_CONFIG_H  -g -O2    -c /var/www/html/opencensus-php/ext/  opencensus_trace_span.c -o opencensus_trace_span.lo 
/bin/bash /var/www/html/opencensus-php/ext/libtool --mode=compile cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib  -DHAVE_CONFIG_H  -g -O2    -c /var/www/html/opencensus-php/ext/  opencensus_trace_context.c -o opencensus_trace_context.lo 
/bin/bash /var/www/html/opencensus-php/ext/libtool --mode=compile cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib  -DHAVE_CONFIG_H  -g -O2    -c /var/www/html/opencensus-php/ext/  opencensus_trace_annotation.c -o opencensus_trace_annotation.lo 
libtool: compile:  cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/  20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /var/www/html/opencensus-php/ext/opencensus.c  -fPIC -DPIC -o .libs/opencensus.o
libtool: compile:  cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /var/www/html/opencensus-php/ext/opencensus_core_daemonclient.c  -fPIC -DPIC -o .libs/  opencensus_core_daemonclient.o
libtool: compile:  cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /var/www/html/opencensus-php/ext/opencensus_trace.c  -fPIC -DPIC -o .libs/opencensus_trace.  o
libtool: compile:  cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/  20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /var/www/html/opencensus-php/ext/varint.c  -fPIC -DPIC -o .libs/varint.o
libtool: compile:  cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /var/www/html/opencensus-php/ext/opencensus_trace_span.c  -fPIC -DPIC -o .libs/  opencensus_trace_span.o
libtool: compile:  cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /var/www/html/opencensus-php/ext/opencensus_trace_context.c  -fPIC -DPIC -o .libs/  opencensus_trace_context.o
libtool: compile:  cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c  -fPIC -DPIC -o .libs/  opencensus_trace_annotation.o
/bin/bash /var/www/html/opencensus-php/ext/libtool --mode=compile cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib  -DHAVE_CONFIG_H  -g -O2    -c /var/www/html/opencensus-php/ext/  opencensus_trace_link.c -o opencensus_trace_link.lo 
libtool: compile:  cc -I. -I/var/www/html/opencensus-php/ext -I/var/www/html/opencensus-php/ext/include -I/var/www/html/opencensus-php/ext/main -I/var/www/html/opencensus-php/ext -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /var/www/html/opencensus-php/ext/opencensus_trace_link.c  -fPIC -DPIC -o .libs/  opencensus_trace_link.o
  In file included from /var/www/html/opencensus-php/ext/php_opencensus.h:25,
                   from /var/www/html/opencensus-php/ext/opencensus_core_daemonclient.c:29:
  /var/www/html/opencensus-php/ext/opencensus_trace.h:45:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     45 | void opencensus_trace_clear(int reset TSRMLS_DC);
        |                                       ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.h:46:67: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     46 | void opencensus_trace_execute_ex (zend_execute_data *execute_data TSRMLS_DC);
        |                                                                   ^~~~~~~~~
  make: *** [Makefile:212: opencensus_core_daemonclient.lo] Error 1
  make: *** Waiting for unfinished jobs....
  In file included from /var/www/html/opencensus-php/ext/php_opencensus.h:25,
                   from /var/www/html/opencensus-php/ext/opencensus.c:17:
  /var/www/html/opencensus-php/ext/opencensus_trace.h:45:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     45 | void opencensus_trace_clear(int reset TSRMLS_DC);
        |                                       ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.h:46:67: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     46 | void opencensus_trace_execute_ex (zend_execute_data *execute_data TSRMLS_DC);
        |                                                                   ^~~~~~~~~
  In file included from /var/www/html/opencensus-php/ext/php_opencensus.h:25,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_span.c:94:
  /var/www/html/opencensus-php/ext/opencensus_trace.h:45:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     45 | void opencensus_trace_clear(int reset TSRMLS_DC);
        |                                       ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.h:46:67: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     46 | void opencensus_trace_execute_ex (zend_execute_data *execute_data TSRMLS_DC);
        |                                                                   ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan___construct':
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:118:47: error: expected ')' before 'TSRMLS_CC'
    118 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "a", &zval_span_options) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:118:9: error: too few arguments to function 'zend_parse_parameters'
    118 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "a", &zval_span_options) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_span.c:94:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_update_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:124:56: note: in expansion of macro 'getThis'
    124 |         zend_update_property(opencensus_trace_span_ce, getThis(), ZSTR_VAL(k), strlen(ZSTR_VAL(k)), v);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:387:74: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    387 | ZEND_API void zend_update_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zval *value);
        |                                                             ~~~~~~~~~~~~~^~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan___destruct':
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:130:113: error: expected ')' before 'TSRMLS_CC'
    130 |     zv = zend_read_property(opencensus_trace_span_ce, getThis(), "attributes", sizeof("attributes") - 1, 0, &val TSRMLS_CC);
        |                                                                                                                 ^~~~~~~~~~
        |                                                                                                                 )
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_span.c:94:
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:130:55: note: in expansion of macro 'getThis'
    130 |     zv = zend_read_property(opencensus_trace_span_ce, getThis(), "attributes", sizeof("attributes") - 1, 0, &val TSRMLS_CC);
        |                                                       ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:132:103: error: expected ')' before 'TSRMLS_CC'
    132 |     zv = zend_read_property(opencensus_trace_span_ce, getThis(), "links", sizeof("links") - 1, 0, &val TSRMLS_CC);
        |                                                                                                       ^~~~~~~~~~
        |                                                                                                       )
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_span.c:94:
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:132:55: note: in expansion of macro 'getThis'
    132 |     zv = zend_read_property(opencensus_trace_span_ce, getThis(), "links", sizeof("links") - 1, 0, &val TSRMLS_CC);
        |                                                       ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c: In function 'zim_OpenCensusTraceContext___construct':
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c:64:47: error: expected ')' before 'TSRMLS_CC'
     64 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "h", &context_options) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c:64:9: error: too few arguments to function 'zend_parse_parameters'
     64 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "h", &context_options) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:134:113: error: expected ')' before 'TSRMLS_CC'
    134 |     zv = zend_read_property(opencensus_trace_span_ce, getThis(), "timeEvents", sizeof("timeEvents") - 1, 0, &val TSRMLS_CC);
        |                                                                                                                 ^~~~~~~~~~
        |                                                                                                                 )
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_span.c:94:
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:134:55: note: in expansion of macro 'getThis'
    134 |     zv = zend_read_property(opencensus_trace_span_ce, getThis(), "timeEvents", sizeof("timeEvents") - 1, 0, &val TSRMLS_CC);
        |                                                       ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_context.h:20,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_context.c:46:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_name':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:150:56: note: in expansion of macro 'getThis'
    150 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "name", sizeof("name") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_update_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c:69:59: note: in expansion of macro 'getThis'
     69 |         zend_update_property(opencensus_trace_context_ce, getThis(), ZSTR_VAL(k), strlen(ZSTR_VAL(k)), v);
        |                                                           ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:387:74: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    387 | ZEND_API void zend_update_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zval *value);
        |                                                             ~~~~~~~~~~~~~^~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c: In function 'zim_OpenCensusTraceContext_spanId':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c:85:59: note: in expansion of macro 'getThis'
     85 |     val = zend_read_property(opencensus_trace_context_ce, getThis(), "spanId", sizeof("spanId") - 1, 1, &rv);
        |                                                           ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_spanId':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:167:56: note: in expansion of macro 'getThis'
    167 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "spanId", sizeof("spanId") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c: In function 'zim_OpenCensusTraceContext_traceId':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c:102:59: note: in expansion of macro 'getThis'
    102 |     val = zend_read_property(opencensus_trace_context_ce, getThis(), "traceId", sizeof("traceId") - 1, 1, &rv);
        |                                                           ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_parentSpanId':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:184:56: note: in expansion of macro 'getThis'
    184 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "parentSpanId", sizeof("parentSpanId") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c: In function 'opencensus_trace_context_minit':
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_attributes':
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c:122:112: error: expected ')' before 'TSRMLS_CC'
    122 |     zend_declare_property_null(opencensus_trace_context_ce, "spanId", sizeof("spanId") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_context.c:123:114: error: expected ')' before 'TSRMLS_CC'
    123 |     zend_declare_property_null(opencensus_trace_context_ce, "traceId", sizeof("traceId") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                  ^~~~~~~~~
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:201:56: note: in expansion of macro 'getThis'
    201 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "attributes", sizeof("attributes") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_links':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:222:56: note: in expansion of macro 'getThis'
    222 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "links", sizeof("links") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_timeEvents':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:243:56: note: in expansion of macro 'getThis'
    243 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "timeEvents", sizeof("timeEvents") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_startTime':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:264:56: note: in expansion of macro 'getThis'
    264 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "startTime", sizeof("startTime") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_endTime':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:281:56: note: in expansion of macro 'getThis'
    281 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "endTime", sizeof("endTime") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_stackTrace':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:298:56: note: in expansion of macro 'getThis'
    298 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "stackTrace", sizeof("stackTrace") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_kind':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:319:56: note: in expansion of macro 'getThis'
    319 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "kind", sizeof("kind") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_sameProcessAsParentSpan':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:336:56: note: in expansion of macro 'getThis'
    336 |     val = zend_read_property(opencensus_trace_span_ce, getThis(), "sameProcessAsParentSpan", sizeof("sameProcessAsParentSpan") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:343:5: error: expected ';' before '}' token
    343 |     }
        |     ^
  In file included from /var/www/html/opencensus-php/ext/php_opencensus.h:25,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
  /var/www/html/opencensus-php/ext/opencensus_trace.h:45:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     45 | void opencensus_trace_clear(int reset TSRMLS_DC);
        |                                       ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.h:46:67: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     46 | void opencensus_trace_execute_ex (zend_execute_data *execute_data TSRMLS_DC);
        |                                                                   ^~~~~~~~~
  make: *** [Makefile:208: opencensus.lo] Error 1
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_span.c:94:
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:349:69: error: 'ZEND_ACC_DTOR' undeclared (first use in this function); did you mean 'ZEND_ACC_CTOR'?
    349 |     PHP_ME(OpenCensusTraceSpan, __destruct, NULL, ZEND_ACC_PUBLIC | ZEND_ACC_DTOR)
        |                                                                     ^~~~~~~~~~~~~
  /usr/include/php/20200930/Zend/zend_API.h:77:162: note: in definition of macro 'ZEND_RAW_FENTRY'
   77 | #define ZEND_RAW_FENTRY(zend_name, name, arg_info, flags)   { zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1),   flags },
      |                                                                                                                                                                    ^~~~~
  /usr/include/php/20200930/main/php.h:389:25: note: in expansion of macro 'ZEND_ME'
    389 | #define PHP_ME          ZEND_ME
        |                         ^~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:349:5: note: in expansion of macro 'PHP_ME'
    349 |     PHP_ME(OpenCensusTraceSpan, __destruct, NULL, ZEND_ACC_PUBLIC | ZEND_ACC_DTOR)
        |     ^~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:349:69: note: each undeclared identifier is reported only once for each function it appears in
    349 |     PHP_ME(OpenCensusTraceSpan, __destruct, NULL, ZEND_ACC_PUBLIC | ZEND_ACC_DTOR)
        |                                                                     ^~~~~~~~~~~~~
  /usr/include/php/20200930/Zend/zend_API.h:77:162: note: in definition of macro 'ZEND_RAW_FENTRY'
   77 | #define ZEND_RAW_FENTRY(zend_name, name, arg_info, flags)   { zend_name, name, arg_info, (uint32_t) (sizeof(arg_info)/sizeof(struct _zend_internal_arg_info)-1),   flags },
      |                                                                                                                                                                    ^~~~~
  /usr/include/php/20200930/main/php.h:389:25: note: in expansion of macro 'ZEND_ME'
    389 | #define PHP_ME          ZEND_ME
        |                         ^~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:349:5: note: in expansion of macro 'PHP_ME'
    349 |     PHP_ME(OpenCensusTraceSpan, __destruct, NULL, ZEND_ACC_PUBLIC | ZEND_ACC_DTOR)
        |     ^~~~~~
  make: *** [Makefile:218: opencensus_trace_context.lo] Error 1
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'opencensus_trace_span_minit':
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:372:91: error: expected ')' before 'TSRMLS_CC'
    372 |       opencensus_trace_span_ce, "name", sizeof("name") - 1, "unknown", ZEND_ACC_PROTECTED TSRMLS_CC
        |                                                                                           ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:374:109: error: expected ')' before 'TSRMLS_CC'
    374 |     zend_declare_property_null(opencensus_trace_span_ce, "spanId", sizeof("spanId") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                             ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:375:121: error: expected ')' before 'TSRMLS_CC'
    375 |     zend_declare_property_null(opencensus_trace_span_ce, "parentSpanId", sizeof("parentSpanId") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                         ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:376:115: error: expected ')' before 'TSRMLS_CC'
    376 |     zend_declare_property_null(opencensus_trace_span_ce, "startTime", sizeof("startTime") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                   ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:377:111: error: expected ')' before 'TSRMLS_CC'
    377 |     zend_declare_property_null(opencensus_trace_span_ce, "endTime", sizeof("endTime") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:378:117: error: expected ')' before 'TSRMLS_CC'
    378 |     zend_declare_property_null(opencensus_trace_span_ce, "attributes", sizeof("attributes") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                     ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:379:117: error: expected ')' before 'TSRMLS_CC'
    379 |     zend_declare_property_null(opencensus_trace_span_ce, "stackTrace", sizeof("stackTrace") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                     ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:380:107: error: expected ')' before 'TSRMLS_CC'
    380 |     zend_declare_property_null(opencensus_trace_span_ce, "links", sizeof("links") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                           ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:381:117: error: expected ')' before 'TSRMLS_CC'
    381 |     zend_declare_property_null(opencensus_trace_span_ce, "timeEvents", sizeof("timeEvents") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                     ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:382:105: error: expected ')' before 'TSRMLS_CC'
    382 |     zend_declare_property_null(opencensus_trace_span_ce, "kind", sizeof("kind") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                         ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:383:143: error: expected ')' before 'TSRMLS_CC'
    383 |     zend_declare_property_null(opencensus_trace_span_ce, "sameProcessAsParentSpan", sizeof("sameProcessAsParentSpan") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c: In function 'zim_OpenCensusTraceSpan_sameProcessAsParentSpan':
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:388:13: error: invalid storage class for function 'annotation_dtor'
    388 | static void annotation_dtor(zval *zv)
        |             ^~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:396:13: error: invalid storage class for function 'link_dtor'
    396 | static void link_dtor(zval *zv)
        |             ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:403:13: error: invalid storage class for function 'message_event_dtor'
    403 | static void message_event_dtor(zval *zv)
        |             ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:410:13: error: invalid storage class for function 'time_event_dtor'
    410 | static void time_event_dtor(zval *zv)
        |             ^~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:600:12: error: invalid storage class for function 'opencensus_trace_time_event_to_zval'
    600 | static int opencensus_trace_time_event_to_zval(opencensus_trace_time_event_t *time_event, zval *zv)
        |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:612:12: error: invalid storage class for function 'opencensus_trace_update_time_events'
    612 | static int opencensus_trace_update_time_events(opencensus_trace_span_t *span, zval *return_value)
        |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:623:12: error: invalid storage class for function 'opencensus_trace_update_links'
    623 | static int opencensus_trace_update_links(opencensus_trace_span_t *span, zval *return_value)
        |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:635:83: error: expected ';', ',' or ')' before 'TSRMLS_DC'
    635 | int opencensus_trace_span_to_zval(opencensus_trace_span_t *trace_span, zval *span TSRMLS_DC)
        |                                                                                   ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_span.c:669:1: error: expected declaration or statement at end of input
    669 | }
        | ^
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'opencensus_trace_ginit':
/var/www/html/opencensus-php/ext/opencensus_trace.c:38:23: error: 'opencensus_trace_execute_ex' undeclared (first use in this function); did you mean   'opencensus_trace_execute_internal'?
     38 |     zend_execute_ex = opencensus_trace_execute_ex;
        |                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~
        |                       opencensus_trace_execute_internal
  /var/www/html/opencensus-php/ext/opencensus_trace.c:38:23: note: each undeclared identifier is reported only once for each function it appears in
  make: *** [Makefile:216: opencensus_trace_span.lo] Error 1
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'opencensus_trace_rshutdown':
/var/www/html/opencensus-php/ext/opencensus_trace.c:73:2: warning: implicit declaration of function 'opencensus_trace_clear'; did you mean 'zif_opencensus_trace_clear'?   [-Wimplicit-function-declaration]
     73 |  opencensus_trace_clear(0 TSRMLS_CC);
        |  ^~~~~~~~~~~~~~~~~~~~~~
        |  zif_opencensus_trace_clear
  /var/www/html/opencensus-php/ext/opencensus_trace.c:73:26: error: expected ')' before 'TSRMLS_CC'
     73 |  opencensus_trace_clear(0 TSRMLS_CC);
        |                          ^~~~~~~~~~
        |                          )
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'span_id_from_options':
/var/www/html/opencensus-php/ext/opencensus_trace.c:99:40: warning: passing argument 1 of '_php_math_longtobase' makes integer from pointer without a cast   [-Wint-conversion]
     99 |             str = _php_math_longtobase(val, 16);
        |                                        ^~~
        |                                        |
        |                                        zval * {aka struct _zval_struct *}
  In file included from /var/www/html/opencensus-php/ext/opencensus_trace.c:21:
  /usr/include/php/20200930/ext/standard/php_math.h:24:22: note: expected 'zend_long' {aka 'long int'} but argument is of type 'zval *' {aka 'struct _zval_struct *'}
     24 | PHPAPI zend_string * _php_math_longtobase(zend_long arg, int base);
        |                      ^~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_add_attribute':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:143:47: error: expected ')' before 'TSRMLS_CC'
    143 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "SS|a", &k, &v, &options) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:143:9: error: too few arguments to function 'zend_parse_parameters'
    143 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "SS|a", &k, &v, &options) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_add_annotation':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:176:47: error: expected ')' before 'TSRMLS_CC'
    176 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "S|a", &description, &options) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:176:9: error: too few arguments to function 'zend_parse_parameters'
    176 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "S|a", &description, &options) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_add_link':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:210:47: error: expected ')' before 'TSRMLS_CC'
    210 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "SS|a", &trace_id, &span_id, &options) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:210:9: error: too few arguments to function 'zend_parse_parameters'
    210 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "SS|a", &trace_id, &span_id, &options) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_add_message_event':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:244:47: error: expected ')' before 'TSRMLS_CC'
    244 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "SS|a", &type, &id, &options) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:244:9: error: too few arguments to function 'zend_parse_parameters'
    244 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "SS|a", &type, &id, &options) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: At top level:
  /var/www/html/opencensus-php/ext/opencensus_trace.c:294:185: error: expected ';', ',' or ')' before 'TSRMLS_DC'
  294 | static int opencensus_trace_call_user_function_callback(zval *args, int num_args, zend_execute_data *execute_data, opencensus_trace_span_t *span, zval *callback,   zval *callback_result TSRMLS_DC)
      |                                                                                                                                                                                           ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'generate_span_id':
/var/www/html/opencensus-php/ext/opencensus_trace.c:331:33: warning: passing argument 1 of '_php_math_longtobase' makes integer from pointer without a cast   [-Wint-conversion]
    331 |     return _php_math_longtobase(&zv, 16);
        |                                 ^~~
        |                                 |
        |                                 zval * {aka struct _zval_struct *}
  In file included from /var/www/html/opencensus-php/ext/opencensus_trace.c:21:
  /usr/include/php/20200930/ext/standard/php_math.h:24:22: note: expected 'zend_long' {aka 'long int'} but argument is of type 'zval *' {aka 'struct _zval_struct *'}
     24 | PHPAPI zend_string * _php_math_longtobase(zend_long arg, int base);
        |                      ^~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: At top level:
  /var/www/html/opencensus-php/ext/opencensus_trace.c:338:129: error: expected ';', ',' or ')' before 'TSRMLS_DC'
    338 | static opencensus_trace_span_t *opencensus_trace_begin(zend_string *name, zend_execute_data *execute_data, zend_string *span_id TSRMLS_DC)
        |                                                                                                                                 ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_begin':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:429:47: error: expected ')' before 'TSRMLS_CC'
    429 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "S|a", &function_name, &span_options) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:429:9: error: too few arguments to function 'zend_parse_parameters'
    429 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "S|a", &function_name, &span_options) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
/var/www/html/opencensus-php/ext/opencensus_trace.c:435:16: warning: implicit declaration of function 'opencensus_trace_begin'; did you mean 'opencensus_trace_rinit'?   [-Wimplicit-function-declaration]
    435 |         span = opencensus_trace_begin(function_name, execute_data, NULL TSRMLS_CC);
        |                ^~~~~~~~~~~~~~~~~~~~~~
        |                opencensus_trace_rinit
  /var/www/html/opencensus-php/ext/opencensus_trace.c:435:73: error: expected ')' before 'TSRMLS_CC'
    435 |         span = opencensus_trace_begin(function_name, execute_data, NULL TSRMLS_CC);
        |                                                                         ^~~~~~~~~
/var/www/html/opencensus-php/ext/opencensus_trace.c:435:14: warning: assignment to 'opencensus_trace_span_t *' {aka 'struct opencensus_trace_span_t *'} from 'int' makes   pointer from integer without a cast [-Wint-conversion]
    435 |         span = opencensus_trace_begin(function_name, execute_data, NULL TSRMLS_CC);
        |              ^
  /var/www/html/opencensus-php/ext/opencensus_trace.c:440:75: error: expected ')' before 'TSRMLS_CC'
    440 |         span = opencensus_trace_begin(function_name, execute_data, span_id TSRMLS_CC);
        |                                                                           ^~~~~~~~~~
        |                                                                           )
/var/www/html/opencensus-php/ext/opencensus_trace.c:440:14: warning: assignment to 'opencensus_trace_span_t *' {aka 'struct opencensus_trace_span_t *'} from 'int' makes   pointer from integer without a cast [-Wint-conversion]
    440 |         span = opencensus_trace_begin(function_name, execute_data, span_id TSRMLS_CC);
        |              ^
  /var/www/html/opencensus-php/ext/opencensus_trace.c: At top level:
  /var/www/html/opencensus-php/ext/opencensus_trace.c:474:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
    474 | void opencensus_trace_clear(int reset TSRMLS_DC)
        |                                       ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_clear':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:505:29: error: expected ')' before 'TSRMLS_CC'
    505 |     opencensus_trace_clear(1 TSRMLS_CC);
        |                             ^~~~~~~~~~
        |                             )
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_set_context':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:518:47: error: expected ')' before 'TSRMLS_CC'
    518 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "S|S", &trace_id, &parent_span_id) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:518:9: error: too few arguments to function 'zend_parse_parameters'
    518 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "S|S", &trace_id, &parent_span_id) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_context':
/var/www/html/opencensus-php/ext/opencensus_trace.c:541:63: warning: passing argument 2 of 'zend_update_property_str' from incompatible pointer type   [-Wincompatible-pointer-types]
    541 |         zend_update_property_str(opencensus_trace_context_ce, return_value, "spanId", sizeof("spanId") - 1, span->span_id);
        |                                                               ^~~~~~~~~~~~
        |                                                               |
        |                                                               zval * {aka struct _zval_struct *}
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
/usr/include/php/20200930/Zend/zend_API.h:392:78: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    392 | ZEND_API void zend_update_property_str(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_string *value);
        |                                                                 ~~~~~~~~~~~~~^~~~~~
/var/www/html/opencensus-php/ext/opencensus_trace.c:543:63: warning: passing argument 2 of 'zend_update_property_str' from incompatible pointer type   [-Wincompatible-pointer-types]
    543 |         zend_update_property_str(opencensus_trace_context_ce, return_value, "spanId", sizeof("spanId") - 1, OPENCENSUS_G(trace_parent_span_id));
        |                                                               ^~~~~~~~~~~~
        |                                                               |
        |                                                               zval * {aka struct _zval_struct *}
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
/usr/include/php/20200930/Zend/zend_API.h:392:78: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    392 | ZEND_API void zend_update_property_str(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_string *value);
        |                                                                 ~~~~~~~~~~~~~^~~~~~
/var/www/html/opencensus-php/ext/opencensus_trace.c:546:63: warning: passing argument 2 of 'zend_update_property_str' from incompatible pointer type   [-Wincompatible-pointer-types]
    546 |         zend_update_property_str(opencensus_trace_context_ce, return_value, "traceId", sizeof("traceId") - 1, OPENCENSUS_G(trace_id));
        |                                                               ^~~~~~~~~~~~
        |                                                               |
        |                                                               zval * {aka struct _zval_struct *}
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
/usr/include/php/20200930/Zend/zend_API.h:392:78: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    392 | ZEND_API void zend_update_property_str(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_string *value);
        |                                                                 ~~~~~~~~~~~~~^~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: At top level:
  /var/www/html/opencensus-php/ext/opencensus_trace.c:555:67: error: expected ';', ',' or ')' before 'TSRMLS_DC'
    555 | void opencensus_trace_execute_ex (zend_execute_data *execute_data TSRMLS_DC) {
        |                                                                   ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'opencensus_trace_execute_internal':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:646:69: error: expected ')' before 'TSRMLS_CC'
    646 |     span = opencensus_trace_begin(function_name, execute_data, NULL TSRMLS_CC);
        |                                                                     ^~~~~~~~~
/var/www/html/opencensus-php/ext/opencensus_trace.c:646:10: warning: assignment to 'opencensus_trace_span_t *' {aka 'struct opencensus_trace_span_t *'} from 'int' makes   pointer from integer without a cast [-Wint-conversion]
    646 |     span = opencensus_trace_begin(function_name, execute_data, NULL TSRMLS_CC);
        |          ^
  In file included from /var/www/html/opencensus-php/ext/php_opencensus.h:25,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:45:
  /var/www/html/opencensus-php/ext/opencensus_trace.h:45:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     45 | void opencensus_trace_clear(int reset TSRMLS_DC);
        |                                       ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.h:46:67: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     46 | void opencensus_trace_execute_ex (zend_execute_data *execute_data TSRMLS_DC);
        |                                                                   ^~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:45:
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c: In function 'zim_OpenCensusTraceAnnotation_description':
/var/www/html/opencensus-php/ext/opencensus_trace.c:655:13: warning: implicit declaration of function 'opencensus_trace_call_user_function_callback'   [-Wimplicit-function-declaration]
    655 |         if (opencensus_trace_call_user_function_callback(args, num_args, execute_data, span, trace_handler, &callback_result TSRMLS_CC) == SUCCESS) {
        |             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:655:125: error: expected ')' before 'TSRMLS_CC'
    655 |         if (opencensus_trace_call_user_function_callback(args, num_args, execute_data, span, trace_handler, &callback_result TSRMLS_CC) == SUCCESS) {
        |                                                                                                                             ^~~~~~~~~~
        |                                                                                                                             )
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:63:62: note: in expansion of macro 'getThis'
     63 |     val = zend_read_property(opencensus_trace_annotation_ce, getThis(), "description", sizeof("description") - 1, 1, &rv);
        |                                                              ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c: In function 'zim_OpenCensusTraceAnnotation_time':
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_function':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:80:62: note: in expansion of macro 'getThis'
     80 |     val = zend_read_property(opencensus_trace_annotation_ce, getThis(), "time", sizeof("time") - 1, 1, &rv);
        |                                                              ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:684:47: error: expected ')' before 'TSRMLS_CC'
    684 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "S|z", &function_name, &handler) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:684:9: error: too few arguments to function 'zend_parse_parameters'
    684 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "S|z", &function_name, &handler) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c: In function 'zim_OpenCensusTraceAnnotation_options':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:97:62: note: in expansion of macro 'getThis'
     97 |     val = zend_read_property(opencensus_trace_annotation_ce, getThis(), "options", sizeof("options") - 1, 1, &rv);
        |                                                              ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_method':
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c: In function 'opencensus_trace_annotation_minit':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:713:47: error: expected ')' before 'TSRMLS_CC'
    713 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "SS|z", &class_name, &function_name, &handler) == FAILURE) {
        |                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c:713:9: error: too few arguments to function 'zend_parse_parameters'
    713 |     if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "SS|z", &class_name, &function_name, &handler) == FAILURE) {
        |         ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:118:125: error: expected ')' before 'TSRMLS_CC'
    118 |     zend_declare_property_null(opencensus_trace_annotation_ce, "description", sizeof("description") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                             ^~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace.c:17:
  /usr/include/php/20200930/Zend/zend_API.h:304:22: note: declared here
    304 | ZEND_API zend_result zend_parse_parameters(uint32_t num_args, const char *type_spec, ...);
        |                      ^~~~~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:119:111: error: expected ')' before 'TSRMLS_CC'
    119 |     zend_declare_property_null(opencensus_trace_annotation_ce, "time", sizeof("time") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:120:117: error: expected ')' before 'TSRMLS_CC'
    120 |     zend_declare_property_null(opencensus_trace_annotation_ce, "options", sizeof("options") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                                     ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.c: In function 'zif_opencensus_trace_list':
  /var/www/html/opencensus-php/ext/opencensus_trace.c:746:48: error: expected ')' before 'TSRMLS_CC'
    746 |         add_next_index_zval(return_value, &span TSRMLS_CC);
        |                                                ^~~~~~~~~~
        |                                                )
  /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c: In function 'opencensus_trace_annotation_to_zval':
/var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:155:62: warning: passing argument 2 of 'zend_update_property_str' from incompatible pointer type   [-Wincompatible-pointer-types]
    155 |     zend_update_property_str(opencensus_trace_annotation_ce, zv, "description", sizeof("description") - 1, annotation->description);
        |                                                              ^~
        |                                                              |
        |                                                              zval * {aka struct _zval_struct *}
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:45:
/usr/include/php/20200930/Zend/zend_API.h:392:78: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    392 | ZEND_API void zend_update_property_str(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_string *value);
        |                                                                 ~~~~~~~~~~~~~^~~~~~
/var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:156:65: warning: passing argument 2 of 'zend_update_property_double' from incompatible pointer type   [-Wincompatible-pointer-types]
    156 |     zend_update_property_double(opencensus_trace_annotation_ce, zv, "time", sizeof("time") - 1, annotation->time_event.time);
        |                                                                 ^~
        |                                                                 |
        |                                                                 zval * {aka struct _zval_struct *}
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:45:
/usr/include/php/20200930/Zend/zend_API.h:391:81: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    391 | ZEND_API void zend_update_property_double(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, double value);
        |                                                                    ~~~~~~~~~~~~~^~~~~~
/var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:157:58: warning: passing argument 2 of 'zend_update_property' from incompatible pointer type   [-Wincompatible-pointer-types]
    157 |     zend_update_property(opencensus_trace_annotation_ce, zv, "options", sizeof("options") - 1, &annotation->options);
        |                                                          ^~
        |                                                          |
        |                                                          zval * {aka struct _zval_struct *}
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_annotation.c:45:
/usr/include/php/20200930/Zend/zend_API.h:387:74: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    387 | ZEND_API void zend_update_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zval *value);
        |                                                             ~~~~~~~~~~~~~^~~~~~
  make: *** [Makefile:220: opencensus_trace_annotation.lo] Error 1
  make: *** [Makefile:214: opencensus_trace.lo] Error 1
  In file included from /var/www/html/opencensus-php/ext/php_opencensus.h:25,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_link.c:45:
  /var/www/html/opencensus-php/ext/opencensus_trace.h:45:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     45 | void opencensus_trace_clear(int reset TSRMLS_DC);
        |                                       ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace.h:46:67: error: expected ';', ',' or ')' before 'TSRMLS_DC'
     46 | void opencensus_trace_execute_ex (zend_execute_data *execute_data TSRMLS_DC);
        |                                                                   ^~~~~~~~~
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_link.c:45:
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c: In function 'zim_OpenCensusTraceLink_traceId':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c:63:56: note: in expansion of macro 'getThis'
     63 |     val = zend_read_property(opencensus_trace_link_ce, getThis(), "traceId", sizeof("traceId") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c: In function 'zim_OpenCensusTraceLink_spanId':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c:80:56: note: in expansion of macro 'getThis'
     80 |     val = zend_read_property(opencensus_trace_link_ce, getThis(), "spanId", sizeof("spanId") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c: In function 'zim_OpenCensusTraceLink_options':
  /usr/include/php/20200930/Zend/zend_API.h:416:73: warning: passing argument 2 of 'zend_read_property' from incompatible pointer type [-Wincompatible-pointer-types]
    416 | #define getThis()       ((Z_TYPE_P(ZEND_THIS) == IS_OBJECT) ? ZEND_THIS : NULL)
        |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
        |                                                                         |
        |                                                                         zval * {aka struct _zval_struct *}
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c:97:56: note: in expansion of macro 'getThis'
     97 |     val = zend_read_property(opencensus_trace_link_ce, getThis(), "options", sizeof("options") - 1, 1, &rv);
        |                                                        ^~~~~~~
/usr/include/php/20200930/Zend/zend_API.h:407:16: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    407 | ZEND_API zval *zend_read_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_bool silent, zval *rv);
        |                ^~~~~~~~~~~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c: In function 'opencensus_trace_link_minit':
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c:118:111: error: expected ')' before 'TSRMLS_CC'
    118 |     zend_declare_property_null(opencensus_trace_link_ce, "traceId", sizeof("traceId") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c:119:109: error: expected ')' before 'TSRMLS_CC'
    119 |     zend_declare_property_null(opencensus_trace_link_ce, "spanId", sizeof("spanId") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                             ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c:120:111: error: expected ')' before 'TSRMLS_CC'
    120 |     zend_declare_property_null(opencensus_trace_link_ce, "options", sizeof("options") - 1, ZEND_ACC_PROTECTED TSRMLS_CC);
        |                                                                                                               ^~~~~~~~~
  /var/www/html/opencensus-php/ext/opencensus_trace_link.c: In function 'opencensus_trace_link_to_zval':
/var/www/html/opencensus-php/ext/opencensus_trace_link.c:158:56: warning: passing argument 2 of 'zend_update_property_str' from incompatible pointer type   [-Wincompatible-pointer-types]
    158 |     zend_update_property_str(opencensus_trace_link_ce, zv, "traceId", sizeof("traceId") - 1, link->trace_id);
        |                                                        ^~
        |                                                        |
        |                                                        zval * {aka struct _zval_struct *}
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_link.c:45:
/usr/include/php/20200930/Zend/zend_API.h:392:78: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    392 | ZEND_API void zend_update_property_str(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_string *value);
        |                                                                 ~~~~~~~~~~~~~^~~~~~
/var/www/html/opencensus-php/ext/opencensus_trace_link.c:159:56: warning: passing argument 2 of 'zend_update_property_str' from incompatible pointer type   [-Wincompatible-pointer-types]
    159 |     zend_update_property_str(opencensus_trace_link_ce, zv, "spanId", sizeof("spanId") - 1, link->span_id);
        |                                                        ^~
        |                                                        |
        |                                                        zval * {aka struct _zval_struct *}
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_link.c:45:
/usr/include/php/20200930/Zend/zend_API.h:392:78: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    392 | ZEND_API void zend_update_property_str(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zend_string *value);
        |                                                                 ~~~~~~~~~~~~~^~~~~~
/var/www/html/opencensus-php/ext/opencensus_trace_link.c:160:52: warning: passing argument 2 of 'zend_update_property' from incompatible pointer type   [-Wincompatible-pointer-types]
    160 |     zend_update_property(opencensus_trace_link_ce, zv, "options", sizeof("options") - 1, &link->options);
        |                                                    ^~
        |                                                    |
        |                                                    zval * {aka struct _zval_struct *}
  In file included from /usr/include/php/20200930/main/php.h:36,
                   from /var/www/html/opencensus-php/ext/php_opencensus.h:24,
                   from /var/www/html/opencensus-php/ext/opencensus_trace_link.c:45:
/usr/include/php/20200930/Zend/zend_API.h:387:74: note: expected 'zend_object *' {aka 'struct _zend_object *'} but argument is of type 'zval *' {aka 'struct _zval_struct   *'}
    387 | ZEND_API void zend_update_property(zend_class_entry *scope, zend_object *object, const char *name, size_t name_length, zval *value);
        |                                                             ~~~~~~~~~~~~~^~~~~~
  make: *** [Makefile:222: opencensus_trace_link.lo] Error 1
bshaffer commented 3 years ago

The fix has been tagged and released in v0.6.0

MrMage commented 3 years ago

@bshaffer thanks, but I am referring to PHP 8. The release notes for 0.6.0 only mention a fix for PHP 7.4 in the PHP code. I am talking about the C extension being unable to compile with PHP 8.

frost-byte commented 3 years ago

@bshaffer thanks, but I am referring to PHP 8. The release notes for 0.6.0 only mention a fix for PHP 7.4 in the PHP code. I am talking about the C extension being unable to compile with PHP 8.

I'm having the same issue, I'm using 0.6.0, but when I try to build the ext, I get

opencensus_trace.h:45:39: error: expected ';', ',' or ')' before 'TSRMLS_DC'
void opencensus_trace_clear(int reset TSRMLS_DC);
                                      ^~~~~~~~~
opencensus_trace.h:46:67: error: expected ';', ',' or ')' before 'TSRMLS_DC'
void opencensus_trace_execute_ex (zend_execute_data *execute_data TSRMLS_DC);
                                                                  ^~~~~~~~~

Found this for reference to the Thread Safety Macros being Removed in php 8

MrMage commented 3 years ago

@bshaffer with PHP now being available on Cloud Functions, is there interest from Google to fix this?

Due to this issue, it is currently not possible to use Stackdriver Trace with PHP 8.

bshaffer commented 3 years ago

The c extension is not required for using cloud logging. It is an optimization. Also php 8 is not yet supported by cloud functions (or app engine).

This library is unfortunately unmaintained. But I will review your PR and see about getting this resolved. Thanks for your contribution.

In the meantime you can still use all of cloud logging and cloud error reporting without this extension on all versions of php supported by the client library.

MrMage commented 3 years ago

The c extension is not required for using cloud logging. It is an optimization. Also php 8 is not yet supported by cloud functions (or app engine).

I know, but I am using Stackdriver Trace, which does require this library.

Also, I suppose Google wants to support PHP 8 sooner or later, so it's probably in your interest to have the related libraries in a working state.

This library is unfortunately unmaintained. But I will review your PR and see about getting this resolved. Thanks for your contribution.

Thanks!

frost-byte commented 3 years ago

The c extension is not required for using cloud logging. It is an optimization. Also php 8 is not yet supported by cloud functions (or app engine).

Actually, I’ve been spending some of my free time working on a fork of https://github.com/GoogleCloudPlatform/php-docker in an effort to add 7.4.16 and 8.0.3.

I’ve been able to get the build to complete, yet this is one of a handful of extensions that doesn’t compile due to the TSRM macros being removed.

MrMage commented 3 years ago

I’ve been able to get the build to complete, yet this is one of a handful of extensions that doesn’t compile due to the TSRM macros being removed.

Good to know! Would you mind checking whether the https://github.com/Timing-GmbH/opencensus-php/tree/php8-compat branch fixes this?

Also, which other extensions are exhibiting compatibility issues?

frost-byte commented 3 years ago

Good to know! Would you mind checking whether the https://github.com/Timing-GmbH/opencensus-php/tree/php8-compat branch fixes this?

I will test out your branch and let you know!

Also, which other extensions are exhibiting compatibility issues? I've been trying to sort what the state of each extension is between php 7.3, 7.4 and 8.0 In some cases they've been incorporated into php. (json in php8, for example) In other cases they've been deprecated - apcu_bc in php 8, for example.

For php 8 I cannot build the following extensions: apm, cassandra, phalcon, ps, stackdriver_debugger, tcpwrap, v8js

apm, ps, stackdriver_debugger, tcpwrap -> won't build because the TSRM macros are still referenced.

The remaining extensions have other issues unrelated to the macros:

Cassandra isn't building because it requires a more recent version of libuv1 - the package for bionic is outdated. (I'm going to try building/packaging v1.35.0)

phalcon v5.0 is in development and will support php8, v4.1.2 supports 7.3 and 7.4

v8js isn't building for php8 - at least version 2.1.6 won't build - so I am rebuilding libv8 with an additional flag. https://github.com/phpv8/v8js/issues/397#issuecomment-465218484

frost-byte commented 3 years ago

Good to know! Would you mind checking whether the https://github.com/Timing-GmbH/opencensus-php/tree/php8-compat branch fixes this?

I was able to build your branch, I'm still working on completing the build for the images.

bshaffer commented 3 years ago

Actually, I’ve been spending some of my free time working on a fork of https://github.com/GoogleCloudPlatform/php-docker in an effort to add 7.4.16 and 8.0.3.

You are probably aware but I want to reinforce that this repo is part of appengine flexible only

frost-byte commented 3 years ago

You are probably aware but I want to reinforce that this repo is part of appengine flexible only

Yes, I am aware of that, I’ve been using the platform for quite awhile.