AU: Beginnings of delta support

- proto file for delta files; still needs hardlink support

- code to generate a delta update from two directory trees (old, new).

- code to parse delta update

- Actions: postinst-runner, install, bootable flag setter, filesystem
 copier, Omaha response handler, Omaha request preparer,

- misc utility functions, like StringHasSuffix(), templatized Action
 classes to feed/collect an object from another action.

- FilesystemIterator: iterates a directory tree with optional
 exclusion path. Tolerates deleting of files during iteration.

- Subprocess class: support for synchronously or asynchronously
 running an external command. Doesn't pass any env variables.

- Integration test that strings many Actions together and tests using
 actual Omaha/Lorry. Currently only tests full updates.

- New simple HTTP server for unittest that supports fake flaky
 connections.

- Some refactoring.

Review URL: http://codereview.chromium.org/466036


git-svn-id: svn://chrome-svn/chromeos/trunk@334 06c00378-0e64-4dae-be16-12b19f9950a1
diff --git a/main.cc b/main.cc
index 412020b..bbb6401 100644
--- a/main.cc
+++ b/main.cc
@@ -2,34 +2,12 @@
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
 
-#include <stdlib.h>
-#include <stdio.h>
-#include <iostream>
 #include <glib.h>
-#include <base/logging.h>
 
-#include <libxml/parser.h>
-#include <libxml/xpath.h>
-#include <libxml/xpathInternals.h>
-
-// This code runs inside the main loop
-gboolean EntryPoint(gpointer data) {
-  GMainLoop *loop = reinterpret_cast<GMainLoop*>(data);
-  LOG(INFO) << "Chrome OS Update Engine beginning";
-  g_main_loop_quit(loop);
-  return FALSE;
-}
+#include "update_engine/subprocess.h"
 
 int main(int argc, char** argv) {
-  xmlDocPtr doc = xmlNewDoc((const xmlChar*)"1.0");
-  CHECK(doc);
-  CHECK_EQ(argc, 2);
-  printf("enc: [%s]\n", xmlEncodeEntitiesReentrant(doc, (const xmlChar*)argv[1]));
-  return 0;
-  
-  
-  GMainLoop *loop = g_main_loop_new(g_main_context_default(), FALSE);
-  g_timeout_add(0, &EntryPoint, loop);
-  g_main_loop_run(loop);
+  g_thread_init(NULL);
+  chromeos_update_engine::Subprocess::Init();
   return 0;
 }