Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

zephir build gives an compile time error #1944

Closed
atishamte opened this issue Oct 4, 2019 · 8 comments
Labels
bug

Comments

@atishamte
Copy link

@atishamte atishamte commented Oct 4, 2019

In file included from /root/zephir/phpext/ext/kernel/string.c:51:0:
/root/zephir/phpext/ext/kernel/string.c: In function ‘zephir_preg_match’:
./kernel/memory.h:82:66: error: ‘ZEPHIR_METHOD_GLOBALS_PTR’ undeclared (first use in this function)
 #define zephir_memory_observe(var) zephir_do_memory_observe(var, ZEPHIR_METHOD_GLOBALS_PTR);
                                                                  ^
./kernel/memory.h:94:2: note: in expansion of macro ‘zephir_memory_observe’
  zephir_memory_observe(z); \
  ^
/root/zephir/phpext/ext/kernel/string.c:1117:2: note: in expansion of macro ‘ZEPHIR_INIT_VAR’
  ZEPHIR_INIT_VAR(&tmp_flags);
  ^
./kernel/memory.h:82:66: note: each undeclared identifier is reported only once for each function it appears in
 #define zephir_memory_observe(var) zephir_do_memory_observe(var, ZEPHIR_METHOD_GLOBALS_PTR);
                                                                  ^
./kernel/memory.h:94:2: note: in expansion of macro ‘zephir_memory_observe’
  zephir_memory_observe(z); \
  ^
/root/zephir/phpext/ext/kernel/string.c:1117:2: note: in expansion of macro ‘ZEPHIR_INIT_VAR’
  ZEPHIR_INIT_VAR(&tmp_flags);
  ^
/root/zephir/phpext/ext/kernel/string.c: In function ‘zephir_json_encode’:
/root/zephir/phpext/ext/kernel/string.c:1194:2: warning: implicit declaration of function ‘ZEPHIR_NULL’ [-Wimplicit-function-declaration]
  ZEPHIR_NULL(&zopts);
  ^
make: *** [kernel/string.lo] Error 1
In file included from /root/zephir/phpext/ext/kernel/string.c:51:0:
/root/zephir/phpext/ext/kernel/string.c: In function ‘zephir_preg_match’:
./kernel/memory.h:82:66: error: ‘ZEPHIR_METHOD_GLOBALS_PTR’ undeclared (first use in this function)
 #define zephir_memory_observe(var) zephir_do_memory_observe(var, ZEPHIR_METHOD_GLOBALS_PTR);
                                                                  ^
./kernel/memory.h:94:2: note: in expansion of macro ‘zephir_memory_observe’
  zephir_memory_observe(z); \
  ^
/root/zephir/phpext/ext/kernel/string.c:1117:2: note: in expansion of macro ‘ZEPHIR_INIT_VAR’
  ZEPHIR_INIT_VAR(&tmp_flags);
  ^
./kernel/memory.h:82:66: note: each undeclared identifier is reported only once for each function it appears in
 #define zephir_memory_observe(var) zephir_do_memory_observe(var, ZEPHIR_METHOD_GLOBALS_PTR);
                                                                  ^
./kernel/memory.h:94:2: note: in expansion of macro ‘zephir_memory_observe’
  zephir_memory_observe(z); \
  ^
/root/zephir/phpext/ext/kernel/string.c:1117:2: note: in expansion of macro ‘ZEPHIR_INIT_VAR’
  ZEPHIR_INIT_VAR(&tmp_flags);
  ^
/root/zephir/phpext/ext/kernel/string.c: In function ‘zephir_json_encode’:
/root/zephir/phpext/ext/kernel/string.c:1194:2: warning: implicit declaration of function ‘ZEPHIR_NULL’ [-Wimplicit-function-declaration]
  ZEPHIR_NULL(&zopts);
  ^
make: *** [kernel/string.lo] Error 1
@atishamte

This comment has been minimized.

Copy link
Author

@atishamte atishamte commented Oct 4, 2019

PHP 7.0.33-0ubuntu0.16.04.6 (cli) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies
with Zend OPcache v7.0.33-0ubuntu0.16.04.6, Copyright (c) 1999-2017, by Zend Technologies

@atishamte

This comment has been minimized.

Copy link
Author

@atishamte atishamte commented Oct 4, 2019

I have rollback the version form 0.12.6 to 0.12.4 and it worked.
Some blunder happened in .5 and .6 I guess

@sergeyklay

This comment has been minimized.

Copy link
Member

@sergeyklay sergeyklay commented Oct 4, 2019

@atishamte Please double check Zephir version. I fixed this issue (introduced in 0.12.5): #1942 and released 0.12.6 with this fix: https://github.com/phalcon/zephir/blob/master/CHANGELOG.md#0126---2019-10-03

@atishamte

This comment has been minimized.

Copy link
Author

@atishamte atishamte commented Oct 4, 2019

But the error occurred in version 0.12.6.

@sergeyklay sergeyklay closed this in 9be0236 Oct 4, 2019
@sergeyklay

This comment has been minimized.

Copy link
Member

@sergeyklay sergeyklay commented Oct 4, 2019

@atishamte I've fixed this right now. Could you please try development branch by any chance? Note, you'll need clone this repo, switch to the development branch and run composer install. Finally, use ./zephir from the project root.

@sergeyklay sergeyklay added the bug label Oct 4, 2019
@atishamte

This comment has been minimized.

Copy link
Author

@atishamte atishamte commented Oct 4, 2019

Ok. I will update you ASAP

@sergeyklay

This comment has been minimized.

Copy link
Member

@sergeyklay sergeyklay commented Oct 4, 2019

@atishamte Try latest stable Zephir I released about a hour ago

@atishamte

This comment has been minimized.

Copy link
Author

@atishamte atishamte commented Oct 4, 2019

Yup. It's fixed now.

dreamsxin added a commit to dreamsxin/zephir that referenced this issue Nov 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.