summaryrefslogtreecommitdiffstats
path: root/thirdparty/glog/glog-0.3.4/m4/google_namespace.m4
diff options
context:
space:
mode:
authoryalei wang <wylandrea@gmail.com>2018-03-13 01:12:00 +0000
committerGerrit Code Review <gerrit@fd.io>2018-03-13 01:12:00 +0000
commit1b031216ba4cd37943900b8759f50fd0e3a8f1cf (patch)
treeb6816d9228ddb456b6f26889d8831c2e879e47ce /thirdparty/glog/glog-0.3.4/m4/google_namespace.m4
parenta8261960bcb4d08b254b2cfce746cca166329b6a (diff)
parent71e33ec17c12e6ca43f149215ca05fc9d8b1d5a9 (diff)
Merge "Add some third-party src code for DMM"
Diffstat (limited to 'thirdparty/glog/glog-0.3.4/m4/google_namespace.m4')
-rw-r--r--thirdparty/glog/glog-0.3.4/m4/google_namespace.m436
1 files changed, 36 insertions, 0 deletions
diff --git a/thirdparty/glog/glog-0.3.4/m4/google_namespace.m4 b/thirdparty/glog/glog-0.3.4/m4/google_namespace.m4
new file mode 100644
index 0000000..79e0a6d
--- /dev/null
+++ b/thirdparty/glog/glog-0.3.4/m4/google_namespace.m4
@@ -0,0 +1,36 @@
+# Allow users to override the namespace we define our application's classes in
+# Arg $1 is the default namespace to use if --enable-namespace isn't present.
+
+# In general, $1 should be 'google', so we put all our exported symbols in a
+# unique namespace that is not likely to conflict with anyone else. However,
+# when it makes sense -- for instance, when publishing stl-like code -- you
+# may want to go with a different default, like 'std'.
+
+AC_DEFUN([AC_DEFINE_GOOGLE_NAMESPACE],
+ [google_namespace_default=[$1]
+ AC_ARG_ENABLE(namespace, [ --enable-namespace=FOO to define these Google
+ classes in the FOO namespace. --disable-namespace
+ to define them in the global namespace. Default
+ is to define them in namespace $1.],
+ [case "$enableval" in
+ yes) google_namespace="$google_namespace_default" ;;
+ no) google_namespace="" ;;
+ *) google_namespace="$enableval" ;;
+ esac],
+ [google_namespace="$google_namespace_default"])
+ if test -n "$google_namespace"; then
+ ac_google_namespace="$google_namespace"
+ ac_google_start_namespace="namespace $google_namespace {"
+ ac_google_end_namespace="}"
+ else
+ ac_google_namespace=""
+ ac_google_start_namespace=""
+ ac_google_end_namespace=""
+ fi
+ AC_DEFINE_UNQUOTED(GOOGLE_NAMESPACE, $ac_google_namespace,
+ Namespace for Google classes)
+ AC_DEFINE_UNQUOTED(_START_GOOGLE_NAMESPACE_, $ac_google_start_namespace,
+ Puts following code inside the Google namespace)
+ AC_DEFINE_UNQUOTED(_END_GOOGLE_NAMESPACE_, $ac_google_end_namespace,
+ Stops putting the code inside the Google namespace)
+])