Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Build and configure Geocouch

Change-Id: I1b91a94894cc5ef93a840d1191cb6d07b3dbdbcd
Reviewed-on: http://review.couchbase.org/9756
Reviewed-by: Jens Alfke <jens@couchbase.com>
Reviewed-by: Dale Harvey <daleharvey@arandomurl.com>
Tested-by: Dale Harvey <daleharvey@arandomurl.com>
  • Loading branch information...
commit 3f2a09ded793cc5e14359e01d6c796af85d573b9 1 parent 3e2b3a6
@daleharvey daleharvey authored Dale Harvey committed
View
13 Framework/Resources/default_ios.ini
@@ -43,3 +43,16 @@ ios_driver={couch_ios, start_link, []}
bind_address = 127.0.0.1 ; only local clients: will not accept HTTP connections over WiFi
port = 0 ; means server will pick an available port when it starts
+[daemons]
+spatial_manager={couch_spatial, start_link, []}
+
+[httpd_db_handlers]
+_spatial_cleanup = {couch_httpd_spatial, handle_spatial_cleanup_req}
+
+[httpd_design_handlers]
+_spatial = {couch_httpd_spatial, handle_spatial_req}
+_spatial/_list = {couch_httpd_spatial_list, handle_spatial_list_req}
+_spatial/_info = {couch_httpd_spatial, handle_design_info_req}
+_spatial/_compact = {couch_httpd_spatial, handle_compact_req}
+;deprecated API
+_spatiallist = {couch_httpd_spatial_list, handle_spatial_list_req_deprecated}
View
24 Framework/Scripts/build_erlang_packages.sh
@@ -15,13 +15,23 @@ echo "Copying erlang dir to ${ERLANG_DSTDIR}"
ditto "${SRCROOT}/erlang" "${ERLANG_DSTDIR}"
# Now compile the Erlang libraries we build from source:
-$COMPILE couchdb "couch.erl couch_api_wrap.erl couch_api_wrap_httpc.erl couch_app.erl couch_app_server.erl couch_app_server_emonk.erl couch_app_server_erlang.erl couch_auth_cache.erl couch_btree.erl couch_changes.erl couch_compaction_daemon.erl couch_compress.erl couch_compress_types.erl couch_config.erl couch_config_writer.erl couch_db.erl couch_db_frontend.erl couch_db_update_notifier.erl couch_db_update_notifier_sup.erl couch_db_updater.erl couch_doc.erl couch_drv.erl couch_event_sup.erl couch_external_manager.erl couch_external_server.erl couch_file.erl couch_httpc_pool.erl couch_httpd.erl couch_httpd_auth.erl couch_httpd_db.erl couch_httpd_external.erl couch_httpd_misc_handlers.erl couch_httpd_oauth.erl couch_httpd_proxy.erl couch_httpd_replicator.erl couch_httpd_rewrite.erl couch_httpd_show.erl couch_httpd_stats_handlers.erl couch_httpd_vhost.erl couch_httpd_view.erl couch_httpd_view_merger.erl couch_internal_load_gen.erl couch_key_tree.erl couch_log.erl couch_native_process.erl couch_os_daemons.erl couch_os_process.erl couch_primary_sup.erl couch_query_servers.erl couch_ref_counter.erl couch_rep_sup.erl couch_replication_manager.erl couch_replication_notifier.erl couch_replicator.erl couch_replicator_doc_copier.erl couch_replicator_rev_finder.erl couch_replicator_utils.erl couch_secondary_sup.erl couch_server.erl couch_server_sup.erl couch_stats_aggregator.erl couch_stats_collector.erl couch_stream.erl couch_task_status.erl couch_util.erl couch_uuids.erl couch_view.erl couch_view_compactor.erl couch_view_group.erl couch_view_merger.erl couch_view_server.erl couch_view_server_emonk.erl couch_view_server_erlang.erl couch_view_server_os.erl couch_view_updater.erl couch_work_queue.erl json_stream_parse.erl couch_ios.erl" "$ERLANG_DSTDIR/lib/couch/ebin"
-$COMPILE erlang-oauth "oauth.erl oauth_hmac_sha1.erl oauth_http.erl oauth_plaintext.erl oauth_rsa_sha1.erl oauth_unix.erl oauth_uri.erl" "$ERLANG_DSTDIR/lib/erlang-oauth/ebin"
-$COMPILE ibrowse "ibrowse.erl ibrowse_app.erl ibrowse_http_client.erl ibrowse_lb.erl ibrowse_lib.erl ibrowse_sup.erl ibrowse_test.erl" "$ERLANG_DSTDIR/lib/ibrowse"
-$COMPILE mochiweb "mochifmt.erl mochifmt_records.erl mochifmt_std.erl mochiglobal.erl mochihex.erl mochijson.erl mochijson2.erl mochilists.erl mochilogfile2.erl mochinum.erl mochitemp.erl mochiutf8.erl mochiweb.erl mochiweb_acceptor.erl mochiweb_app.erl mochiweb_charref.erl mochiweb_cookies.erl mochiweb_cover.erl mochiweb_echo.erl mochiweb_headers.erl mochiweb_html.erl mochiweb_http.erl mochiweb_io.erl mochiweb_mime.erl mochiweb_multipart.erl mochiweb_request.erl mochiweb_request_tests.erl mochiweb_response.erl mochiweb_skel.erl mochiweb_socket.erl mochiweb_socket_server.erl mochiweb_sup.erl mochiweb_util.erl reloader.erl" "$ERLANG_DSTDIR/lib/mochiweb/ebin"
-$COMPILE ejson "ejson.erl mochijson2.erl mochinum.erl" "$ERLANG_DSTDIR/lib/ejson/ebin"
-$COMPILE snappy "snappy.erl" "$ERLANG_DSTDIR/lib/snappy/ebin"
-$COMPILE emonk/src "emonk.erl" "$ERLANG_DSTDIR/lib/emonk/ebin"
+$COMPILE "../../vendor/couchdb/src/couchdb" "couch.erl couch_api_wrap.erl couch_api_wrap_httpc.erl couch_app.erl couch_app_server.erl couch_app_server_emonk.erl couch_app_server_erlang.erl couch_auth_cache.erl couch_btree.erl couch_changes.erl couch_compaction_daemon.erl couch_compress.erl couch_compress_types.erl couch_config.erl couch_config_writer.erl couch_db.erl couch_db_frontend.erl couch_db_update_notifier.erl couch_db_update_notifier_sup.erl couch_db_updater.erl couch_doc.erl couch_drv.erl couch_event_sup.erl couch_external_manager.erl couch_external_server.erl couch_file.erl couch_httpc_pool.erl couch_httpd.erl couch_httpd_auth.erl couch_httpd_db.erl couch_httpd_external.erl couch_httpd_misc_handlers.erl couch_httpd_oauth.erl couch_httpd_proxy.erl couch_httpd_replicator.erl couch_httpd_rewrite.erl couch_httpd_show.erl couch_httpd_stats_handlers.erl couch_httpd_vhost.erl couch_httpd_view.erl couch_httpd_view_merger.erl couch_internal_load_gen.erl couch_key_tree.erl couch_log.erl couch_native_process.erl couch_os_daemons.erl couch_os_process.erl couch_primary_sup.erl couch_query_servers.erl couch_ref_counter.erl couch_rep_sup.erl couch_replication_manager.erl couch_replication_notifier.erl couch_replicator.erl couch_replicator_doc_copier.erl couch_replicator_rev_finder.erl couch_replicator_utils.erl couch_secondary_sup.erl couch_server.erl couch_server_sup.erl couch_stats_aggregator.erl couch_stats_collector.erl couch_stream.erl couch_task_status.erl couch_util.erl couch_uuids.erl couch_view.erl couch_view_compactor.erl couch_view_group.erl couch_view_merger.erl couch_view_server.erl couch_view_server_emonk.erl couch_view_server_erlang.erl couch_view_server_os.erl couch_view_updater.erl couch_work_queue.erl json_stream_parse.erl couch_ios.erl" "$ERLANG_DSTDIR/lib/couch/ebin"
+
+$COMPILE "../../vendor/couchdb/src/erlang-oauth" "oauth.erl oauth_hmac_sha1.erl oauth_http.erl oauth_plaintext.erl oauth_rsa_sha1.erl oauth_unix.erl oauth_uri.erl" "$ERLANG_DSTDIR/lib/erlang-oauth/ebin"
+
+$COMPILE "../../vendor/couchdb/src/ibrowse" "ibrowse.erl ibrowse_app.erl ibrowse_http_client.erl ibrowse_lb.erl ibrowse_lib.erl ibrowse_sup.erl ibrowse_test.erl" "$ERLANG_DSTDIR/lib/ibrowse"
+
+$COMPILE "../../vendor/couchdb/src/mochiweb" "mochifmt.erl mochifmt_records.erl mochifmt_std.erl mochiglobal.erl mochihex.erl mochijson.erl mochijson2.erl mochilists.erl mochilogfile2.erl mochinum.erl mochitemp.erl mochiutf8.erl mochiweb.erl mochiweb_acceptor.erl mochiweb_app.erl mochiweb_charref.erl mochiweb_cookies.erl mochiweb_cover.erl mochiweb_echo.erl mochiweb_headers.erl mochiweb_html.erl mochiweb_http.erl mochiweb_io.erl mochiweb_mime.erl mochiweb_multipart.erl mochiweb_request.erl mochiweb_request_tests.erl mochiweb_response.erl mochiweb_skel.erl mochiweb_socket.erl mochiweb_socket_server.erl mochiweb_sup.erl mochiweb_util.erl reloader.erl" "$ERLANG_DSTDIR/lib/mochiweb/ebin"
+
+$COMPILE "../../vendor/couchdb/src/ejson" "ejson.erl mochijson2.erl mochinum.erl" "$ERLANG_DSTDIR/lib/ejson/ebin"
+
+$COMPILE "../../vendor/couchdb/src/snappy" "snappy.erl" "$ERLANG_DSTDIR/lib/snappy/ebin"
+
+$COMPILE "../../vendor/couchdb/src/emonk/src" "emonk.erl" "$ERLANG_DSTDIR/lib/emonk/ebin"
+
+$COMPILE "../../vendor/geocouch/src/geocouch" "couch_httpd_spatial.erl couch_spatial.erl couch_spatial_compactor.erl couch_spatial_updater.erl couch_httpd_spatial_list.erl couch_spatial_group.erl geocouch_duplicates.erl" "$ERLANG_DSTDIR/lib/geocouch/ebin" "../../../couchdb/src/couchdb"
+
+$COMPILE "../../vendor/geocouch/src/vtree" "vtree.erl vtree_bulk.erl vtree_insbench.erl vtreestats.erl vtreeviz.erl" "$ERLANG_DSTDIR/lib/geocouch/ebin" "../../../couchdb/src/couchdb"
# Strip debug info & symbols out of the .beam files -- this saves a LOT of disk space:
echo "Stripping .beam files..."
View
12 Framework/Scripts/compile_erlang_dir.sh
@@ -6,10 +6,16 @@
# specified by the manifest.
#
# Usage:
-# build_app.sh sourcedirname filelist dstdir
+# build_app.sh sourcedirname filelist dstdir [includedir]
set -e # Bail out if any command returns an error
echo "Building $1 into $3"
-cd "../../vendor/couchdb/src/$1"
-erlc -W0 +compressed -o "$3" $2
+mkdir -p $3
+cd $1
+
+if [ $# -ne 4 ]; then
+ erlc -W0 +compressed -o "$3" $2
+else
+ erlc -W0 +compressed -I $4 -o "$3" $2
+fi
Please sign in to comment.
Something went wrong with that request. Please try again.