buffet: Extracted libweave into separate directory

It still has references to dbus, buffet and other ChromeOS specific
stuff.

BUG=brillo:1235
TEST=FEATURES=test emerge-gizmo buffet

Change-Id: Ib108960ee88afcf2ecdddf37ce30bd5f168c0034
Reviewed-on: https://chromium-review.googlesource.com/283509
Tested-by: Vitaly Buka <vitalybuka@chromium.org>
Reviewed-by: Alex Vakulenko <avakulenko@chromium.org>
Commit-Queue: Alex Vakulenko <avakulenko@chromium.org>
diff --git a/buffet/buffet.gyp b/buffet/buffet.gyp
index f8c0a5a..7b92439 100644
--- a/buffet/buffet.gyp
+++ b/buffet/buffet.gyp
@@ -10,7 +10,11 @@
         'system_api',
       ],
     },
-    'include_dirs': ['.'],
+    'include_dirs': [
+      '.',
+      # TODO(vitalybuka): Remove both.
+      '../libweave/include',
+    ],
   },
   'targets': [
     {
@@ -21,53 +25,53 @@
         'dbus_service_config': 'dbus_bindings/dbus-service-config.json',
       },
       'sources': [
-        'base_api_handler.cc',
-        'buffet_config.cc',
-        'commands/command_definition.cc',
-        'commands/command_dictionary.cc',
-        'commands/command_instance.cc',
-        'commands/command_manager.cc',
-        'commands/command_queue.cc',
-        'commands/dbus_command_dispatcher.cc',
-        'commands/dbus_command_proxy.cc',
-        'commands/cloud_command_proxy.cc',
-        'commands/object_schema.cc',
-        'commands/prop_constraints.cc',
-        'commands/prop_types.cc',
-        'commands/prop_values.cc',
-        'commands/schema_constants.cc',
-        'commands/schema_utils.cc',
-        'commands/user_role.cc',
-        'device_registration_info.cc',
         'dbus_bindings/org.chromium.Buffet.Command.xml',
         'dbus_bindings/org.chromium.Buffet.Manager.xml',
         'dbus_constants.cc',
         'manager.cc',
-        'notification/notification_parser.cc',
-        'notification/pull_channel.cc',
-        'notification/xml_node.cc',
-        'notification/xmpp_channel.cc',
-        'notification/xmpp_iq_stanza_handler.cc',
-        'notification/xmpp_stream_parser.cc',
-        'privet/ap_manager_client.cc',
-        'privet/cloud_delegate.cc',
-        'privet/constants.cc',
-        'privet/device_delegate.cc',
-        'privet/openssl_utils.cc',
-        'privet/peerd_client.cc',
-        'privet/privet_handler.cc',
-        'privet/privet_manager.cc',
-        'privet/security_manager.cc',
-        'privet/shill_client.cc',
-        'privet/wifi_bootstrap_manager.cc',
-        'privet/wifi_ssid_generator.cc',
-        'registration_status.cc',
-        'storage_impls.cc',
-        'states/error_codes.cc',
-        'states/state_change_queue.cc',
-        'states/state_manager.cc',
-        'states/state_package.cc',
-        'utils.cc',
+        '../libweave/src/base_api_handler.cc',
+        '../libweave/src/buffet_config.cc',
+        '../libweave/src/commands/cloud_command_proxy.cc',
+        '../libweave/src/commands/command_definition.cc',
+        '../libweave/src/commands/command_dictionary.cc',
+        '../libweave/src/commands/command_instance.cc',
+        '../libweave/src/commands/command_manager.cc',
+        '../libweave/src/commands/command_queue.cc',
+        '../libweave/src/commands/dbus_command_dispatcher.cc',
+        '../libweave/src/commands/dbus_command_proxy.cc',
+        '../libweave/src/commands/object_schema.cc',
+        '../libweave/src/commands/prop_constraints.cc',
+        '../libweave/src/commands/prop_types.cc',
+        '../libweave/src/commands/prop_values.cc',
+        '../libweave/src/commands/schema_constants.cc',
+        '../libweave/src/commands/schema_utils.cc',
+        '../libweave/src/commands/user_role.cc',
+        '../libweave/src/device_registration_info.cc',
+        '../libweave/src/notification/notification_parser.cc',
+        '../libweave/src/notification/pull_channel.cc',
+        '../libweave/src/notification/xml_node.cc',
+        '../libweave/src/notification/xmpp_channel.cc',
+        '../libweave/src/notification/xmpp_iq_stanza_handler.cc',
+        '../libweave/src/notification/xmpp_stream_parser.cc',
+        '../libweave/src/privet/ap_manager_client.cc',
+        '../libweave/src/privet/cloud_delegate.cc',
+        '../libweave/src/privet/constants.cc',
+        '../libweave/src/privet/device_delegate.cc',
+        '../libweave/src/privet/openssl_utils.cc',
+        '../libweave/src/privet/peerd_client.cc',
+        '../libweave/src/privet/privet_handler.cc',
+        '../libweave/src/privet/privet_manager.cc',
+        '../libweave/src/privet/security_manager.cc',
+        '../libweave/src/privet/shill_client.cc',
+        '../libweave/src/privet/wifi_bootstrap_manager.cc',
+        '../libweave/src/privet/wifi_ssid_generator.cc',
+        '../libweave/src/registration_status.cc',
+        '../libweave/src/states/error_codes.cc',
+        '../libweave/src/states/state_change_queue.cc',
+        '../libweave/src/states/state_manager.cc',
+        '../libweave/src/states/state_package.cc',
+        '../libweave/src/storage_impls.cc',
+        '../libweave/src/utils.cc',
       ],
       'includes': ['../common-mk/generate-dbus-adaptors.gypi'],
       'actions': [
@@ -176,32 +180,32 @@
           },
           'includes': ['../common-mk/common_test.gypi'],
           'sources': [
-            'base_api_handler_unittest.cc',
-            'buffet_testrunner.cc',
-            'buffet_config_unittest.cc',
-            'commands/cloud_command_proxy_unittest.cc',
-            'commands/command_definition_unittest.cc',
-            'commands/command_dictionary_unittest.cc',
-            'commands/command_instance_unittest.cc',
-            'commands/command_manager_unittest.cc',
-            'commands/command_queue_unittest.cc',
-            'commands/dbus_command_dispatcher_unittest.cc',
-            'commands/dbus_command_proxy_unittest.cc',
-            'commands/object_schema_unittest.cc',
-            'commands/schema_utils_unittest.cc',
-            'commands/unittest_utils.cc',
-            'device_registration_info_unittest.cc',
-            'notification/notification_parser_unittest.cc',
-            'notification/xml_node_unittest.cc',
-            'notification/xmpp_channel_unittest.cc',
-            'notification/xmpp_iq_stanza_handler_unittest.cc',
-            'notification/xmpp_stream_parser_unittest.cc',
-            'privet/privet_handler_unittest.cc',
-            'privet/security_manager_unittest.cc',
-            'privet/wifi_ssid_generator_unittest.cc',
-            'states/state_change_queue_unittest.cc',
-            'states/state_manager_unittest.cc',
-            'states/state_package_unittest.cc',
+            '../libweave/src/base_api_handler_unittest.cc',
+            '../libweave/src/buffet_config_unittest.cc',
+            '../libweave/src/buffet_testrunner.cc',
+            '../libweave/src/commands/cloud_command_proxy_unittest.cc',
+            '../libweave/src/commands/command_definition_unittest.cc',
+            '../libweave/src/commands/command_dictionary_unittest.cc',
+            '../libweave/src/commands/command_instance_unittest.cc',
+            '../libweave/src/commands/command_manager_unittest.cc',
+            '../libweave/src/commands/command_queue_unittest.cc',
+            '../libweave/src/commands/dbus_command_dispatcher_unittest.cc',
+            '../libweave/src/commands/dbus_command_proxy_unittest.cc',
+            '../libweave/src/commands/object_schema_unittest.cc',
+            '../libweave/src/commands/schema_utils_unittest.cc',
+            '../libweave/src/commands/unittest_utils.cc',
+            '../libweave/src/device_registration_info_unittest.cc',
+            '../libweave/src/notification/notification_parser_unittest.cc',
+            '../libweave/src/notification/xml_node_unittest.cc',
+            '../libweave/src/notification/xmpp_channel_unittest.cc',
+            '../libweave/src/notification/xmpp_iq_stanza_handler_unittest.cc',
+            '../libweave/src/notification/xmpp_stream_parser_unittest.cc',
+            '../libweave/src/privet/privet_handler_unittest.cc',
+            '../libweave/src/privet/security_manager_unittest.cc',
+            '../libweave/src/privet/wifi_ssid_generator_unittest.cc',
+            '../libweave/src/states/state_change_queue_unittest.cc',
+            '../libweave/src/states/state_manager_unittest.cc',
+            '../libweave/src/states/state_package_unittest.cc',
           ],
         },
       ],