Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(352)

Unified Diff: third_party/grpc/templates/config.m4.template

Issue 1932353002: Initial checkin of gRPC to third_party/ Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/grpc/templates/binding.gyp.template ('k') | third_party/grpc/templates/gRPC.podspec.template » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/grpc/templates/config.m4.template
diff --git a/third_party/grpc/templates/config.m4.template b/third_party/grpc/templates/config.m4.template
new file mode 100644
index 0000000000000000000000000000000000000000..5847d456f51c89c941065e04344f86ce0a2f4469
--- /dev/null
+++ b/third_party/grpc/templates/config.m4.template
@@ -0,0 +1,59 @@
+%YAML 1.2
+--- |
+ PHP_ARG_ENABLE(grpc, whether to enable grpc support,
+ [ --enable-grpc Enable grpc support])
+
+ if test "$PHP_GRPC" != "no"; then
+ dnl Write more examples of tests here...
+
+ dnl # --with-grpc -> add include path
+ PHP_ADD_INCLUDE(../../grpc/include)
+ PHP_ADD_INCLUDE(../../grpc/src/php/ext/grpc)
+ PHP_ADD_INCLUDE(../../grpc/third_party/boringssl/include)
+
+ LIBS="-lpthread $LIBS"
+
+ GRPC_SHARED_LIBADD="-lpthread $GRPC_SHARED_LIBADD"
+ PHP_ADD_LIBRARY(pthread)
+
+ PHP_ADD_LIBRARY(dl,,GRPC_SHARED_LIBADD)
+ PHP_ADD_LIBRARY(dl)
+
+ case $host in
+ *darwin*) ;;
+ *)
+ PHP_ADD_LIBRARY(rt,,GRPC_SHARED_LIBADD)
+ PHP_ADD_LIBRARY(rt)
+ ;;
+ esac
+
+ PHP_NEW_EXTENSION(grpc,
+ % for source in php_config_m4.src:
+ ${source} ${"\\"}
+ % endfor
+ % for lib in libs:
+ % if lib.name in php_config_m4.get('deps', []):
+ % for source in lib.src:
+ ${source} ${"\\"}
+ % endfor
+ % endif
+ % endfor
+ , $ext_shared, , -Wall -Werror ${"\\"}
+ -Wno-parentheses-equality -Wno-unused-value -std=c11 ${"\\"}
+ -fvisibility=hidden -DOPENSSL_NO_ASM -D_GNU_SOURCE -DWIN32_LEAN_AND_MEAN ${"\\"}
+ -D_HAS_EXCEPTIONS=0 -DNOMINMAX)
+
+ PHP_ADD_BUILD_DIR($ext_builddir/src/php/ext/grpc)
+ <%
+ dirs = {}
+ for lib in libs:
+ if lib.name in php_config_m4.get('deps', []):
+ for source in lib.src:
+ dirs[source[:source.rfind('/')]] = 1
+ dirs = dirs.keys()
+ dirs.sort()
+ %>
+ % for dir in dirs:
+ PHP_ADD_BUILD_DIR($ext_builddir/${dir})
+ % endfor
+ fi
« no previous file with comments | « third_party/grpc/templates/binding.gyp.template ('k') | third_party/grpc/templates/gRPC.podspec.template » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698