This is an automated email from the ASF dual-hosted git repository.

ronny pushed a commit to branch update-snappy
in repository https://gitbox.apache.org/repos/asf/couchdb-snappy.git

commit b9d3b0d655ab14a3d90218b37a53ca48988a841f
Author: Bryan Chan <[email protected]>
AuthorDate: Sat Feb 7 16:54:33 2015 -0500

    Support big-endian builds
---
 rebar.config.script | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/rebar.config.script b/rebar.config.script
new file mode 100644
index 0000000..f7fc761
--- /dev/null
+++ b/rebar.config.script
@@ -0,0 +1,12 @@
+case <<1:16/native>> of
+    <<1,0>> ->
+        CONFIG;
+    <<0,1>> ->
+        CXXFLAGS = [{"CXXFLAGS", "$CXXFLAGS -DWORDS_BIGENDIAN"}],
+        case lists:keyfind(port_env, 1, CONFIG) of
+            false ->
+                CONFIG ++ [{port_env, CXXFLAGS}];
+            {K, V} ->
+                lists:keyreplace(K, 1, CONFIG, {K, V ++ CXXFLAGS})
+        end
+end.

Reply via email to