You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by Apache Wiki <wi...@apache.org> on 2011/01/30 05:33:17 UTC
[Couchdb Wiki] Update of "AndroidSdCardPatch" by MattAdams
Dear Wiki user,
You have subscribed to a wiki page or wiki category on "Couchdb Wiki" for change notification.
The "AndroidSdCardPatch" page has been changed by MattAdams.
http://wiki.apache.org/couchdb/AndroidSdCardPatch
--------------------------------------------------
New page:
For use with [[Installing_on_Android]]
{{{
diff -ru /sdcard/couch/bin/couchdb ./bin/couchdb
--- /sdcard/couch/bin/couchdb 2011-01-26 16:41:44.000000000 -0700
+++ ./bin/couchdb 2011-01-26 20:17:26.000000000 -0700
@@ -1,4 +1,4 @@
-#! /bin/sh -e
+#!/system/bin/sh -e
# Licensed under the Apache License, Version 2.0 (the "License"); you may not
# use this file except in compliance with the License. You may obtain a copy of
@@ -12,6 +12,9 @@
# License for the specific language governing permissions and limitations under
# the License.
+export HOME=/sdcard
+export LD_LIBRARY_PATH=/data/data/com.your.namespace/erlang/erts-5.7.5/bin:/data/data/com.your.namespace/bin
+export PATH=/data/data/com.your.namespace/erlang/bin:$PATH
BACKGROUND=false
DEFAULT_CONFIG_DIR=/sdcard/couch/etc/couchdb/default.d
DEFAULT_CONFIG_FILE=/sdcard/couch/etc/couchdb/default.ini
@@ -222,7 +225,7 @@
touch $PID_FILE
interactive_option="+Bd -noinput"
fi
- command="/home/matt/projects/couch/android-build/couchdb/../otp/bootstrap/bin/erl $interactive_option $ERL_START_OPTIONS \
+ command="erl $interactive_option $ERL_START_OPTIONS \
-env ERL_LIBS /sdcard/couch/lib/couchdb/erlang/lib -couch_ini $start_arguments -s couch"
if test "$BACKGROUND" = "true" -a "$RECURSED" = "false"; then
$0 $background_start_arguments -b -r $RESPAWN_TIMEOUT -p $PID_FILE \
diff -ru /sdcard/couch/bin/couchjs ./bin/couchjs
--- /sdcard/couch/bin/couchjs 2011-01-26 16:41:44.000000000 -0700
+++ ./bin/couchjs 2011-01-26 20:40:05.000000000 -0700
@@ -1,4 +1,4 @@
-#! /bin/sh -e
+#!/system/bin/sh -e
# Licensed under the Apache License, Version 2.0 (the "License"); you may not
# use this file except in compliance with the License. You may obtain a copy of
@@ -63,7 +63,8 @@
}
run_couchjs () {
- exec /sdcard/couch/lib/couchdb/bin/couchjs $@
+ #exec /sdcard/couch/lib/couchdb/bin/couchjs $@
+ exec LD_LIBRARY_PATH=/data/data/com.your.namespace/bin /data/data/com.your.namespace/bin/couchjs $@
}
parse_script_option_list () {
diff -ru /sdcard/couch/etc/couchdb/default.ini ./etc/couchdb/default.ini
--- /sdcard/couch/etc/couchdb/default.ini 2011-01-26 16:41:44.000000000 -0700
+++ ./etc/couchdb/default.ini 2011-01-26 20:27:16.000000000 -0700
@@ -5,7 +5,8 @@
[couchdb]
database_dir = /sdcard/couch/var/lib/couchdb
view_index_dir = /sdcard/couch/var/lib/couchdb
-util_driver_dir = /sdcard/couch/lib/couchdb/erlang/lib/couch-1.0.1/priv/lib
+; util_driver_dir = /sdcard/couch/lib/couchdb/erlang/lib/couch-1.0.1/priv/lib
+util_driver_dir = /data/data/com.your.namespace
max_document_size = 4294967296 ; 4 GB
max_attachment_chunk_size = 4294967296 ; 4GB
os_process_timeout = 5000 ; 5 seconds. for view and external servers.
@@ -36,7 +37,8 @@
auth_cache_size = 50 ; size is number of cache entries
[query_servers]
-javascript = /sdcard/couch/bin/couchjs /sdcard/couch/share/couchdb/server/main.js
+; javascript = /sdcard/couch/bin/couchjs /sdcard/couch/share/couchdb/server/main.js
+javascript = LD_LIBRARY_PATH=/data/data/com.your.namespace/bin /data/data/com.your.namespace/bin/couchjs /sdcard/couch/share/couchdb/server/main.js
; Changing reduce_limit to false will disable reduce_limit.
; If you think you're hitting reduce_limit with a "good" reduce function,
}}}