Return-Path: X-Original-To: apmail-couchdb-commits-archive@www.apache.org Delivered-To: apmail-couchdb-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B5C2C18E11 for ; Fri, 17 Jul 2015 04:18:18 +0000 (UTC) Received: (qmail 24578 invoked by uid 500); 17 Jul 2015 04:18:18 -0000 Delivered-To: apmail-couchdb-commits-archive@couchdb.apache.org Received: (qmail 24518 invoked by uid 500); 17 Jul 2015 04:18:18 -0000 Mailing-List: contact commits-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list commits@couchdb.apache.org Received: (qmail 24505 invoked by uid 99); 17 Jul 2015 04:18:18 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 17 Jul 2015 04:18:18 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 31ABFDFA25; Fri, 17 Jul 2015 04:18:18 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: wohali@apache.org To: commits@couchdb.apache.org Date: Fri, 17 Jul 2015 04:18:18 -0000 Message-Id: X-Mailer: ASF-Git Admin Mailer Subject: [1/2] couch commit: updated refs/heads/master to 8b4af21 Repository: couchdb-couch Updated Branches: refs/heads/master 3a26ea1ba -> 8b4af2160 Support Windows build target Project: http://git-wip-us.apache.org/repos/asf/couchdb-couch/repo Commit: http://git-wip-us.apache.org/repos/asf/couchdb-couch/commit/c76a78b4 Tree: http://git-wip-us.apache.org/repos/asf/couchdb-couch/tree/c76a78b4 Diff: http://git-wip-us.apache.org/repos/asf/couchdb-couch/diff/c76a78b4 Branch: refs/heads/master Commit: c76a78b492b9a3fb33f4d72d09c950f692d2db9a Parents: 3a26ea1 Author: Joan Touzet Authored: Sat Jul 11 19:38:38 2015 -0400 Committer: Joan Touzet Committed: Fri Jul 17 00:17:46 2015 -0400 ---------------------------------------------------------------------- .gitignore | 3 +++ rebar.config.script | 10 +++++++--- 2 files changed, 10 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/couchdb-couch/blob/c76a78b4/.gitignore ---------------------------------------------------------------------- diff --git a/.gitignore b/.gitignore index ee4059b..c1a4701 100644 --- a/.gitignore +++ b/.gitignore @@ -5,6 +5,9 @@ ebin/ priv/couch_js/config.h priv/couchjs priv/couchspawnkillable +priv/*.exp +priv/*.lib +vc120.pdb .rebar/ .eunit http://git-wip-us.apache.org/repos/asf/couchdb-couch/blob/c76a78b4/rebar.config.script ---------------------------------------------------------------------- diff --git a/rebar.config.script b/rebar.config.script index 34e645c..6d4968d 100644 --- a/rebar.config.script +++ b/rebar.config.script @@ -59,6 +59,7 @@ ConfigSrc = [["#define ", K, " ", V, $\n] || {K, V} <- ConfigH], ConfigBin = iolist_to_binary(ConfigSrc), ok = CopyIfDifferent(CouchJSConfig, ConfigBin), +%% TODO support curl on Windows {JS_CFLAGS, JS_LDFLAGS} = case lists:keyfind(with_curl, 1, CouchConfig) of {with_curl, true} -> {"-DHAVE_CURL ", "-DHAVE_CURL -lmozjs185 -lcurl"}; @@ -76,6 +77,9 @@ IcuDarwinEnv = [{"CFLAGS", "-DXP_UNIX -I/usr/local/opt/icu4c/include"}, {"LDFLAGS", "-L/usr/local/opt/icu4c/lib"}], IcuBsdEnv = [{"CFLAGS", "-DXP_UNIX -I/usr/local/include"}, {"LDFLAGS", "-L/usr/local/lib"}], +IcuWinEnv = [{"CFLAGS", "/DXP_WIN /IC:\\relax\\icu\\include"}, + {"LDFLAGS", "/LIBPATH:C:\\relax\\icu\\lib64 icuin.lib icudt.lib icuuc.lib"}], + ComparePath = "priv/couch_ejson_compare.so", CompareSrc = ["priv/couch_ejson_compare/*.c"], @@ -84,17 +88,17 @@ BaseSpecs = [ {"darwin", CouchJSPath, CouchJSSrc, [{env, [{"CFLAGS", JS_CFLAGS ++ "-DXP_UNIX -I/usr/local/include/js"}, {"LDFLAGS", JS_LDFLAGS ++ " -L/usr/local/lib"}]}]}, {"linux", CouchJSPath, CouchJSSrc, [{env, [{"CFLAGS", JS_CFLAGS ++ "-DXP_UNIX -I/usr/include/js"}, {"LDFLAGS", JS_LDFLAGS ++ " -lm"}]}]}, {"bsd", CouchJSPath, CouchJSSrc, [{env, [{"CFLAGS", JS_CFLAGS ++ "-DXP_UNIX -I/usr/local/include/js"}, {"LDFLAGS", JS_LDFLAGS ++ " -L/usr/local/lib -lm"}]}]}, - {"win32", CouchJSPath, CouchJSSrc, [{env, [{"CFLAGS", JS_CFLAGS ++ "-DXP_WIN -I/usr/include/js"}, {"LDFLAGS", JS_LDFLAGS}]}]}, + {"win32", CouchJSPath, CouchJSSrc, [{env, [{"CFLAGS", "/DXP_WIN /IC:\\relax\\js-1.8.5\\js\\src"}, {"LDFLAGS", "/LIBPATH:C:\\relax\\js-1.8.5\\js\\src mozjs185-1.0.lib"}]}]}, % ICU {"darwin", IcuPath, IcuSrc, [{env, IcuEnv ++ IcuDarwinEnv}]}, {"linux", IcuPath, IcuSrc, [{env, IcuEnv}]}, {"bsd", IcuPath, IcuSrc, [{env, IcuEnv ++ IcuBsdEnv}]}, - {"win32", IcuPath, IcuSrc, [{env, IcuEnv}]}, + {"win32", IcuPath, IcuSrc, [{env, IcuEnv ++ IcuWinEnv}]}, % ejson_compare {"darwin", ComparePath, CompareSrc, [{env, IcuEnv ++ IcuDarwinEnv}]}, {"linux", ComparePath, CompareSrc, [{env, IcuEnv}]}, {"bsd", ComparePath, CompareSrc, [{env, IcuEnv ++ IcuBsdEnv}]}, - {"win32", ComparePath, CompareSrc, [{env, IcuEnv}]} + {"win32", ComparePath, CompareSrc, [{env, IcuEnv ++ IcuWinEnv}]} ], SpawnSpec = [