michael-mammut
michael-mammut

Reputation: 2783

Error while compiling in Zephir

I'm trying a simple "Hello World" in Zephir. I created the project with zephir init utils.

The json contains the namespace:

  "namespace":"utils",
  "name":"utils"

I followed these steps


PHP 5.3.27 (cli) (built: Nov 19 2013 08:41:19)
Copyright (c) 1997-2013 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2013 Zend Technologies

GNU Make 3.81

Zephir version 0.9.2a-dev

gcc-Version 4.4.7 20120313 (Red Hat 4.4.7-3) (GCC)

Error Message

[root@localhost utils]# php -r 'echo PHP_BINARY, "\n";'; /usr/local/share/php-5.6.19/bin/php [root@localhost utils]# zephir build PHP Warning: PHP Startup: zephir_parser: Unable to initialize module Module compiled with module API=20090626 PHP compiled with module API=20131226 These options need to match in Unknown on line 0 Fatal error: Call to undefined function Zephir\zephir_parse_file() in /usr/local/share/zephir/Library/CompilerFile.php on line 173

Upvotes: 0

Views: 314

Answers (1)

Zamrony P. Juhara
Zamrony P. Juhara

Reputation: 5262

I believe your phpize is for PHP 5.3 but you try to use PHP 5.6 binary. Try to run phpize -v to view your PHP Api version.

Upvotes: 0

Related Questions