Stanley Cheung | 5adb71f | 2016-02-13 00:03:02 -0800 | [diff] [blame^] | 1 | %YAML 1.2 |
| 2 | --- | |
| 3 | PHP_ARG_ENABLE(grpc, whether to enable grpc support, |
| 4 | [ --enable-grpc Enable grpc support]) |
| 5 | |
| 6 | if test "$PHP_GRPC" != "no"; then |
| 7 | dnl Write more examples of tests here... |
| 8 | |
| 9 | dnl # --with-grpc -> add include path |
| 10 | PHP_ADD_INCLUDE(../../grpc/include) |
| 11 | PHP_ADD_INCLUDE(../../grpc/src/php/ext/grpc) |
| 12 | PHP_ADD_INCLUDE(../../grpc/third_party/boringssl/include) |
| 13 | |
| 14 | PHP_ADD_LIBRARY(pthread) |
| 15 | |
| 16 | PHP_NEW_EXTENSION(grpc, |
| 17 | % for source in php_config_m4.src: |
| 18 | ${source} ${"\\"} |
| 19 | % endfor |
| 20 | % for lib in libs: |
| 21 | % if lib.name in php_config_m4.get('deps', []): |
| 22 | % for source in lib.src: |
| 23 | ${source} ${"\\"} |
| 24 | % endfor |
| 25 | % endif |
| 26 | % endfor |
| 27 | , $ext_shared, , -Wall -Werror -std=c11 ${"\\"} |
| 28 | -fvisibility=hidden -DOPENSSL_NO_ASM -D_GNU_SOURCE -DWIN32_LEAN_AND_MEAN ${"\\"} |
| 29 | -D_HAS_EXCEPTIONS=0 -DNOMINMAX) |
| 30 | fi |