Skip to content

Commit

Permalink
Merge pull request #2084 from phalcon/feature/macos-builds
Browse files Browse the repository at this point in the history
Provide ability to build and test Zephir under macOS
  • Loading branch information
sergeyklay authored Apr 26, 2020
2 parents 1694c3b + b1c27c3 commit a335f24
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
matrix:
os:
- ubuntu-18.04
- macos-latest

php:
- '7.0'
Expand Down Expand Up @@ -108,6 +109,10 @@ jobs:
sudo rm -f /etc/apt/sources.list.d/dotnetdev.list
sudo rm -f /etc/apt/sources.list.d/azure*.list
- name: Install System Dependencies (macOS)
if: startsWith(runner.os, 'macOS')
run: brew install re2c

- name: Install System Dependencies (Linux)
if: startsWith(runner.os, 'Linux')
run: |
Expand Down Expand Up @@ -162,7 +167,18 @@ jobs:
zephir stubs
zephir api
- name: Compile Test Project
- name: Compile Test Project (macOS)
if: startsWith(runner.os, 'macOS')
run: |
# These variables are needed to produce non optimized code
CFLAGS="-O0 -g"
CXXFLAGS="-O0 -g"
# Export variables in the subshell to not shadow global variables
( export CFLAGS CXXFLAGS; zephir compile ) || false
- name: Compile Test Project (Linux)
if: startsWith(runner.os, 'Linux')
run: |
# These variables are needed to produce non optimized code as well as for code coverage
LDFLAGS="--coverage"
Expand Down
2 changes: 1 addition & 1 deletion ext/php_test.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#define PHP_TEST_VERSION "1.0.0"
#define PHP_TEST_EXTNAME "test"
#define PHP_TEST_AUTHOR "Phalcon Team and contributors"
#define PHP_TEST_ZEPVERSION "0.12.18-26d47456"
#define PHP_TEST_ZEPVERSION "0.12.18-$Id$"
#define PHP_TEST_DESCRIPTION "Description <b>test</b> for<br/>Test Extension."

typedef struct _zephir_struct_db {
Expand Down

0 comments on commit a335f24

Please sign in to comment.