[gnome-continuous/wip/platform: 1/9] Add platform support



commit d9eba5e0316517f83fadb51ceaa1a6e7c827e31c
Author: Alexander Larsson <alexl redhat com>
Date:   Fri Sep 5 16:08:02 2014 +0200

    Add platform support
    
    Components marked as tags=["platform"] in the manifest gets installed
    in two new target types, "platform" (only runtime tree) and "sdk"
    (runtime and devel stuff). Tags with "sdk" will only be in the sdk.
    This will be used to create the app runtime and SDK for Gnome
    sandboxed apps.

 src/js/tasks/task-build.js |   29 +++++++++++++++++++++++++++--
 1 files changed, 27 insertions(+), 2 deletions(-)
---
diff --git a/src/js/tasks/task-build.js b/src/js/tasks/task-build.js
index 4d0df93..cbc26b0 100644
--- a/src/js/tasks/task-build.js
+++ b/src/js/tasks/task-build.js
@@ -1348,6 +1348,8 @@ const TaskBuild = new Lang.Class({
         let componentToArches = {};
 
         let runtimeComponents = [];
+        let platformComponents = [];
+        let sdkComponents = [];
         let hwtestComponents = [];
         let develComponents = [];
         let testingComponents = [];
@@ -1376,6 +1378,23 @@ const TaskBuild = new Lang.Class({
                develComponents.push(component);
             }
 
+            if (!isHWTestOnly) {
+               develComponents.push(component);
+            }
+
+            let tags = component['tags'] || [];
+            for (let j = 0; j < tags.length; j++) {
+               let tag = tags[j];
+
+               if (tag == 'platform') {
+                   platformComponents.push(component);
+                   sdkComponents.push(component);
+                }
+               if (tag == 'sdk') {
+                   sdkComponents.push(component);
+                }
+            }
+
            let isNoarch = component['noarch'] || false;
            let componentArches;
             if (isNoarch) {
@@ -1435,7 +1454,7 @@ const TaskBuild = new Lang.Class({
        }
 
         let targetsList = [];
-       let componentTypes = ['runtime', 'hwtest', 'devel-debug'];
+       let componentTypes = ['runtime', 'hwtest', 'devel-debug', 'platform', 'sdk'];
         for (let i = 0; i < componentTypes.length; i++) {
            let targetComponentType = componentTypes[i];
             for (let i = 0; i < architectures.length; i++) {
@@ -1459,6 +1478,10 @@ const TaskBuild = new Lang.Class({
                let targetComponents;
                 if (targetComponentType == 'runtime') {
                     targetComponents = runtimeComponents;
+                } else if (targetComponentType == 'platform') {
+                    targetComponents = platformComponents;
+                } else if (targetComponentType == 'sdk') {
+                    targetComponents = sdkComponents;
                 } else if (targetComponentType == 'hwtest') {
                     targetComponents = hwtestComponents;
                 } else {
@@ -1478,8 +1501,10 @@ const TaskBuild = new Lang.Class({
                    }
                     let binaryName = component['name'] + '/' + architecture;
                     let componentRef = {'name': binaryName};
-                    if (targetComponentType == 'runtime' || targetComponentType == 'hwtest') {
+                    if (targetComponentType == 'runtime' || targetComponentType == 'hwtest' || 
targetComponentType == 'platform') {
                         componentRef['trees'] = ['/runtime'];
+                   } else if (targetComponentType == 'sdk') {
+                        componentRef['trees'] = ['/runtime', '/devel', '/debug'];
                    } else if (targetComponentType == 'devel-debug') {
                         componentRef['trees'] = ['/runtime', '/devel', '/tests', '/doc', '/debug'];
                    }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]