Subversion Repositories DevTools

Rev

Rev 7118 | Rev 7128 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 7118 Rev 7123
Line 380... Line 380...
380
 
380
 
381
        // Deal with test builds here as they may impact upon package attributes
381
        // Deal with test builds here as they may impact upon package attributes
382
        //    eg: dependency collection and build standard differences
382
        //    eg: dependency collection and build standard differences
383
        //    Note: Done before mPackageDependencyCollection is setup
383
        //    Note: Done before mPackageDependencyCollection is setup
384
        //
384
        //
-
 
385
        Phase phase = new Phase("processPackages");
385
        if ( mDaemon )
386
        if ( mDaemon )
386
        {
387
        {
387
            // Process test builds - they are in their own collection
388
            // Process test builds - they are in their own collection
-
 
389
            phase.setPhase("TestBuilds");
388
            for (Iterator<Package> it = mPackageCollectionTest.iterator(); it.hasNext(); )
390
            for (Iterator<Package> it = mPackageCollectionTest.iterator(); it.hasNext(); )
389
            {
391
            {
390
                Package p = it.next();
392
                Package p = it.next();
391
                mLogger.info("planRelease package test build {}", p.mAlias);
393
                mLogger.info("planRelease package test build {}", p.mAlias);
392
 
394
 
Line 414... Line 416...
414
            }
416
            }
415
        }
417
        }
416
 
418
 
417
        // Set up mPackageDependencyCollection on each package
419
        // Set up mPackageDependencyCollection on each package
418
        //    Examine the dependencies by alias and convert this to a 'package' selected from the released package set
420
        //    Examine the dependencies by alias and convert this to a 'package' selected from the released package set
-
 
421
        phase.setPhase("setPackageDependencyCollection");
419
        mLogger.debug("planRelease setup setPackageDependencyCollection");
422
        mLogger.debug("planRelease setup setPackageDependencyCollection");
420
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
423
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
421
        {
424
        {
422
            Package p = it.next();
425
            Package p = it.next();
423
 
426
 
Line 430... Line 433...
430
        }    
433
        }    
431
 
434
 
432
        // Detect and deal with circular dependencies
435
        // Detect and deal with circular dependencies
433
        // Examine all packages under consideration
436
        // Examine all packages under consideration
434
        //
437
        //
-
 
438
        phase.setPhase("Detect Circular Dependencies");
435
        mLogger.debug("planRelease deal with circular dependencies");
439
        mLogger.debug("planRelease deal with circular dependencies");
436
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
440
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
437
        {
441
        {
438
            Package p = it.next();
442
            Package p = it.next();
439
 
443
 
Line 454... Line 458...
454
            }
458
            }
455
        }
459
        }
456
 
460
 
457
        // Scan for packages with missing dependencies
461
        // Scan for packages with missing dependencies
458
        //    ie: The dependent package is not in the package Collection
462
        //    ie: The dependent package is not in the package Collection
-
 
463
        phase.setPhase("Scan missing dpendencies");
459
        mLogger.debug("planRelease use the fully built mPackageDependencyCollection");
464
        mLogger.debug("planRelease use the fully built mPackageDependencyCollection");
460
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
465
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
461
        {
466
        {
462
            Package p = it.next();
467
            Package p = it.next();
463
 
468
 
Line 491... Line 496...
491
                }
496
                }
492
            }
497
            }
493
        }
498
        }
494
 
499
 
495
        // Detect packages with no build standard and exclude them from the build
500
        // Detect packages with no build standard and exclude them from the build
-
 
501
        phase.setPhase("Scan not reproducible");
496
        mLogger.debug("planRelease process packages which are not reproducible");
502
        mLogger.debug("planRelease process packages which are not reproducible");
497
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
503
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
498
        {
504
        {
499
            Package p = it.next();
505
            Package p = it.next();
500
 
506
 
Line 537... Line 543...
537
        //    ie: Package: Win32:Production and we have a BM with a class of 'Win32'
543
        //    ie: Package: Win32:Production and we have a BM with a class of 'Win32'
538
        //
544
        //
539
        //    Only exclude the failing package and not its dependents
545
        //    Only exclude the failing package and not its dependents
540
        //    May be legitimate in the release
546
        //    May be legitimate in the release
541
        //
547
        //
-
 
548
        phase.setPhase("Scan not reproducible2");
542
        mLogger.debug("planRelease process packages which are not reproducible2");
549
        mLogger.debug("planRelease process packages which are not reproducible2");
543
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
550
        for (Iterator<Package> it = mPackageCollectionAll.iterator(); it.hasNext(); )
544
        {
551
        {
545
            Package p = it.next();
552
            Package p = it.next();
546
 
553
 
Line 593... Line 600...
593
        if (mDaemon )
600
        if (mDaemon )
594
        {
601
        {
595
 
602
 
596
            //  Daemon Mode Only
603
            //  Daemon Mode Only
597
            //  Process packages which need to be ripple built
604
            //  Process packages which need to be ripple built
-
 
605
            phase.setPhase("Scan for ripples");
598
            mLogger.debug("planRelease process packages which need to be ripple built");
606
            mLogger.debug("Process packages which need to be ripple built");
599
            for (Iterator<Package> it = mPackageCollection.iterator(); it.hasNext(); )
607
            for (Iterator<Package> it = mPackageCollection.iterator(); it.hasNext(); )
600
            {
608
            {
601
                Package p = it.next();
609
                Package p = it.next();
602
 
610
 
603
                if (p.mBuildFile == 0)
611
                if (p.mBuildFile == 0)
Line 659... Line 667...
659
 
667
 
660
            //  Daemon Mode Only
668
            //  Daemon Mode Only
661
            //  Process packages which do not exist in the archive
669
            //  Process packages which do not exist in the archive
662
            //  For unit test purposes, assume all packages exist in the archive if released
670
            //  For unit test purposes, assume all packages exist in the archive if released
663
            mLogger.debug("planRelease process packages which do not exist in the archive");
671
            mLogger.debug("planRelease process packages which do not exist in the archive");
-
 
672
            phase.setPhase("Scan dpkg_archive");
664
            if ( mReleaseManager.mUseDatabase )
673
            if ( mReleaseManager.mUseDatabase )
665
            {
674
            {
666
                for (Iterator<Package> it = mPackageCollection.iterator(); it.hasNext(); )
675
                for (Iterator<Package> it = mPackageCollection.iterator(); it.hasNext(); )
667
                {
676
                {
668
                    Package p = it.next();
677
                    Package p = it.next();
Line 741... Line 750...
741
            }
750
            }
742
 
751
 
743
            //  Daemon Mode Only
752
            //  Daemon Mode Only
744
            //  Detect bad forced ripples requests and reject them
753
            //  Detect bad forced ripples requests and reject them
745
            mLogger.debug("planRelease process forced ripples");
754
            mLogger.debug("planRelease process forced ripples");
-
 
755
            phase.setPhase("Test bad ripple requests");
746
            for (Iterator<Package> it = mPackageCollectionRipple.iterator(); it.hasNext(); )
756
            for (Iterator<Package> it = mPackageCollectionRipple.iterator(); it.hasNext(); )
747
            {
757
            {
748
                Package p = it.next();
758
                Package p = it.next();
749
 
759
 
750
                if (p.mBuildFile == 0)
760
                if (p.mBuildFile == 0)
Line 772... Line 782...
772
            //  Mark Pegged and SDK packages as not to be built
782
            //  Mark Pegged and SDK packages as not to be built
773
            //  Mark RippleStoped packages as not to be build
783
            //  Mark RippleStoped packages as not to be build
774
            //  Have previously detected conflicts between pegged/sdk packages and daemon instructions
784
            //  Have previously detected conflicts between pegged/sdk packages and daemon instructions
775
            //
785
            //
776
            mLogger.debug("planRelease remove pegged and SDK packages from the build set");
786
            mLogger.debug("planRelease remove pegged and SDK packages from the build set");
-
 
787
            phase.setPhase("Remove Pegged and SDKs");
777
            for (Iterator<Package> it = mPackageCollection.iterator(); it.hasNext(); )
788
            for (Iterator<Package> it = mPackageCollection.iterator(); it.hasNext(); )
778
            {
789
            {
779
                Package p = it.next();
790
                Package p = it.next();
780
 
791
 
781
                if (p.mBuildFile == 0)
792
                if (p.mBuildFile == 0)
Line 804... Line 815...
804
 
815
 
805
            //  Daemon Mode Only
816
            //  Daemon Mode Only
806
            //  Locate Test Build Requests that cannot be satisfied - will not be built due to
817
            //  Locate Test Build Requests that cannot be satisfied - will not be built due to
807
            //  errors in dependent packages. Report the error to the user and remove the request
818
            //  errors in dependent packages. Report the error to the user and remove the request
808
            //
819
            //
-
 
820
            phase.setPhase("Scan unsatisfied test build requests");
809
            for (Iterator<Package> it = mPackageCollectionTest.iterator(); it.hasNext(); )
821
            for (Iterator<Package> it = mPackageCollectionTest.iterator(); it.hasNext(); )
810
            {
822
            {
811
                Package p = it.next();
823
                Package p = it.next();
812
 
824
 
813
                if (p.mBuildFile < 0)
825
                if (p.mBuildFile < 0)
Line 850... Line 862...
850
                    standardOut(mDependent, p.mAlias, mDependentFlag);
862
                    standardOut(mDependent, p.mAlias, mDependentFlag);
851
                    mDependentFlag = false;
863
                    mDependentFlag = false;
852
                }
864
                }
853
            }
865
            }
854
        }
866
        }
-
 
867
        phase.setPhase("End");
855
    }
868
    }
856
    
869
    
857
    /** Plan the build order.
870
    /** Plan the build order.
858
         *  Assumes that a great deal of work has been done.
871
         *  Assumes that a great deal of work has been done.
859
         *  This is a stand alone method to contain the work
872
         *  This is a stand alone method to contain the work