Subversion Repositories DevTools

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
227 dpurdie 1
# -*- mode: perl; tabs: 8; indent-width: 4; show-tabs: yes; -*-
2
# Copyright (C) 1998-2004 ERG Transit Systems, All rights reserved
3
#
4
# Module name   : Makelib.pl
5
# Module type   : Makefile system
6
#
7
# Description:
8
#       This modules builds the primary makefile for each directory,
9
#       used in conjunction with Makelib.pl2.  The produced makefile
10
#       acts as a frontend to platform builds.
11
#
12
# Notes:
13
#
14
#                       *** DO NOT DETAB ***
15
#
16
#       Beware the use of space v's tab characters within the
17
#       makefile generation sessions.
18
#
19
#.........................................................................#
20
 
21
require 5.6.1;
22
use strict;
23
use warnings;
24
use JatsEnv;
25
use JatsMakeInfo qw(:create);
26
 
27
our $MakelibVersion         = "2.33";           # makelib.pl version
28
 
29
our $Generated              = 10;               # Generated error code ..
30
 
31
our $ScmRoot                = "";
32
our $ScmSrcDir              = "";
33
our $ScmMakelib             = "";
34
our @ScmDepends             = ();
35
our $ScmForce               = 0;
36
our $ScmExpert              = 0;
37
our $ScmAll                 = 0;
38
our $ProjectBase            = "";               # Base of the user's project
39
our $ScmInterface           = "interface";
40
 
41
our @SUBDIRS                = ();
42
our @PLATFORMS              = ();
43
our %PLATFORMARGS           = ();
44
our @DEFINES                = "";
45
our @RULES                  = ();
46
 
47
our %PACKAGE_DIST           = ();
48
 
49
our $ROOTMAKEFILE           = 0;
50
our $PLATFORMINCLUDED       = 0;
51
our @BUILDPLATFORMS         = ();
52
 
53
 
54
#.. Running under 'buildlib.pl' ?
55
#
56
unless ( $::ScmBuildlib )
57
{
58
    MakeLibInit();
59
}
60
 
61
sub MakeLibInit
62
{
63
    my ( $argc );                               # argument count
64
 
65
#.. Test environment
66
#
67
    EnvImport( "GBE_BIN" );
68
    EnvImport( "GBE_PERL" );
69
    EnvImport( "GBE_TOOLS" );
70
    EnvImport( "GBE_CONFIG" );
71
    EnvImport( "GBE_MACHTYPE" );
72
 
73
#.. Common stuff
74
#
75
    require "$::GBE_TOOLS/common.pl";
76
 
77
    CommonInit( "makelib " );
78
    Debug( "version:   $MakelibVersion" );
79
 
80
#.. Parse command line
81
#       makefile.pl  rootdir Makelib.pl [options ...]
82
#
83
    $::ScmRoot    = StripDrive( ${ARGV[0]} );
84
    $::ProjectBase= $::ScmRoot;
85
    $::ScmMakelib = ${ARGV[1]};
86
 
87
    Debug( "ARGV:      @ARGV" );
88
    Debug( "Root:      $::ScmRoot" );
89
    Debug( "Makelib:   $::ScmMakelib" );
90
 
91
    $argc = 2;
92
    while ($_ = $ARGV[ $argc++ ])
93
    {
94
        last if ( ! /^-/ );                     # end of options
95
 
96
        Debug( "option:    $_" );
97
 
98
        /^-h$|^-help$|^--help$|^--usage$|^-?$/ && MLUsage();
99
 
100
                                                # long arguments
101
        if (/^--interface=(.*)/) {
102
            $::ScmInterface = $1;
103
            Debug( "Interface: $::ScmInterface" );
104
            next;
105
        }
106
 
107
        if (/^--expert(.*)/) {
108
            if ($1) {
109
                $::ScmExpert = $1;
110
            } else {
111
                $::ScmExpert = 1;
112
            }
113
            Debug( "Expert:    $::ScmExpert" );
114
            next;
115
        }
116
 
117
        if (/^--all/) {
118
            $::ScmAll = 1;
119
            Debug( "All:       $::ScmAll" );
120
            next;
121
        }
122
 
123
        last if (/^--$/);                       # end of arguments
124
 
125
        if (/^-D(.*)/) {
126
            if ($1) {
127
                $::ScmDebug = $1;
128
            } else {
129
                $::ScmDebug = $ARGV[0];
130
                $argc++;
131
            }
132
            Debug( "ScmDebug:  $::ScmDebug" );
133
            next;
134
        }
135
 
136
        next if (/^-V/ && ($::ScmVerbose = 1));
137
 
138
        next if (/^-F/ && ($::ScmForce   = 1));
139
 
140
        if (/^-.*/) {                           # unknown option
141
            MLUsage( "unknown option '$_'\n\n" );
142
        }
143
    }
144
 
145
 
146
#.. Get the stuff from the platform definition file
147
#
148
    ConfigLoad();
149
 
150
#.. Get the stuff from the package definition file
151
#
152
    require "$::ScmRoot/package.pl"
153
        if ( -f "$::ScmRoot/package.pl" );
154
}
155
 
156
#   MLUsage ---
157
#       Makelib command line usage.
158
#..
159
 
160
sub MLUsage
161
{
162
    my( $msg ) = @_;
163
 
164
    print "makefile $msg\n\n"
165
        if ( $msg ne "" );
166
 
167
    print "Usage: perl makefile.pl <ROOTDIR> <Makelib.pl> [options]\n
168
Valid options:
169
\t-V                Verbose mode.
170
\t-D<debug-level>   Set the debug level.
171
\t                  except all SCM support files are removed (eg CVS).
172
\n";
173
    exit(42);
174
}
175
 
176
#-------------------------------------------------------------------------------
177
# Function        : SubDir
178
#
179
# Description     : Recurse into the specified sub directories
180
#                   This is one of the very few directives in a 'makefile.pl'
181
#                   that is processed by this script - all the others are
182
#                   processed by makelib.pl2.
183
#
184
#                   This directive MUST appear before the 'Platform' directive
185
#
186
# Inputs          : List of sub directories to visit
187
#
188
# Returns         : Nothing
189
#
190
sub SubDir
191
{
192
    my( @NewDirs );
193
    Debug( "SubDir(@_)" );
194
    Error ("Directive 'SubDir' not allowed in this context") if ( $::ScmBuildlib  );
195
 
196
    #
197
    #   Support different constructs:
198
    #       'dir1 dir2'
199
    #       'dir1','dir2'
200
    #
201
    @NewDirs = map { split /\s+/ } @_;
202
    @NewDirs = grep { defined $_ } @NewDirs;
203
 
204
    foreach my $ThisDir ( @NewDirs )
205
    {
206
        Warning ("SubDir contains a '\\' character: $ThisDir" )
207
            if ( $ThisDir =~ m~\\~);
208
 
209
        if ( grep /^$ThisDir$/, @::SUBDIRS )
210
        {
211
            Warning( "Duplicate SubDir '$ThisDir' -- ignored." );
212
            next;
213
        }
214
        if ( ! ( -e $ThisDir and -d $ThisDir ) )
215
        {
216
            Error( "SubDir(): Subdirectory not found: '$ThisDir'",
217
                   "Current directory: $::Cwd" );
218
        }
219
        if ( ! -f $ThisDir . '/makefile.pl' )
220
        {
221
            Error( "SubDir(): makefile.pl not found in subdirectory: '$ThisDir'",
222
                   "Current directory: $::Cwd" );
223
        }
224
 
225
        push(@::SUBDIRS, $ThisDir);
226
    }
227
}
228
 
229
 
230
#-------------------------------------------------------------------------------
231
# Function        : RootMakefile
232
#
233
# Description     : This function is called from buildlib.pl prior to the
234
#                   generation of the root makefile. The Root Makefile is
235
#                   different to the others in this it does not have any platform
236
#                   specific makefiles associated with it. It is simply used to
237
#                   invoke the makefile in the 'src' subdirectory
238
#
239
# Inputs          : None
240
#
241
# Returns         : Nothing
242
#
243
sub RootMakefile
244
{
245
    Error ("Directive 'RootMakefile' not allowed in this context") if ( $::ScmBuildlib  );
246
    $::ROOTMAKEFILE = 1;
247
}
248
 
249
 
250
sub PackageDist
251
{
252
    my( $name, @elements ) = @_;
253
    Error ("Directive 'PackageDist' not allowed in this context") if ( $::ScmBuildlib  );
254
 
255
    foreach ( @elements ) {
256
        HashJoin( \%::PACKAGE_DIST, $;, $name, "$_" );
257
    }
258
}
259
 
260
 
261
sub Define
262
{
263
    Error ("Directive 'Define' not allowed in this context") if ( $::ScmBuildlib  );
264
    push( @::DEFINES, @_ );
265
}
266
 
267
 
268
sub Defines
269
{
270
    my( $path, $script ) = @_;
271
    my( $line );
272
    Error ("Directive 'Defines' not allowed in this context") if ( $::ScmBuildlib  );
273
 
274
    $script = Exists( $path, $script, "Defines" );
275
    open( SCRIPT, $script ) ||
276
        Error( "cannot open '$script'" );
277
    while (<SCRIPT>) {
278
        $_ =~ s/\s*(\n|$)//;                    # kill trailing whitespace & nl
279
        push( @::DEFINES, $_ );
280
    }
281
    push( @::ScmDepends, "$script" );           # makefile dependencies
282
    close( SCRIPT );
283
}
284
 
285
 
286
sub Rule
287
{
288
    Error ("Directive 'Rule' not allowed in this context") if ( $::ScmBuildlib  );
289
    push( @::RULES, @_ );
290
}
291
 
292
 
293
sub Rules
294
{
295
    Error ("Directive 'Rules' not allowed in this context") if ( $::ScmBuildlib  );
296
    my( $path, $script ) = @_;
297
    my( $line );
298
 
299
    $script = Exists( $path, $script, "Rules" );
300
    open( SCRIPT, $script ) ||
301
        Error( "cannot open '$script'" );
302
    while (<SCRIPT>) {
303
        $_ =~ s/\s*(\n|$)//;                    # kill trailing whitespace & nl
304
        push( @::RULES, $_ );
305
    }
306
    push( @::ScmDepends, "$script" );           # makefile dependencies
307
    close( SCRIPT );
308
}
309
 
310
#-------------------------------------------------------------------------------
311
# Function        : Platform
312
#
313
# Description     : Within "makelib.pl" the Platform directive is processed
314
#                   in such a manner as to trigger the verification and
315
#                   generation of Makefile and xxxxx.mk files in the tree
316
#                   below the makefile.pl
317
#
318
# Inputs          : A list of platforms for which the body of the makefile.pl
319
#                   are to be processed + GBE_PLATFORM
320
#
321
#                   "*", ...            - A wildcard for all platforms
322
#                                         Options include
323
#                                           --Targets (Not Products)
324
#                                           --Products
325
#                                           --NoPlatformBuilds
326
#                                           !xxx - Exclude a platform
327
#
328
#                   "--NoPlatformBuilds"
329
#
330
#                   "xxx"[, "yyy"]*     - A list of platforms and aliases
331
#
332
#                   "!xxx"              - A platform to be excluded
333
#
334
# Returns         :
335
#
336
sub Platform
337
{
338
    my ( @platforms ) = @_;
339
    my ( $dir, $exitVal, $platform );
340
    my $noplatforms = 0;
341
    my $defplatforms = 0;
342
    my %platforms;
343
 
344
    Debug( "Platform(@_)" );
345
    Error ("Directive 'Platform' not allowed in this context") if ( $::ScmBuildlib  );
346
 
347
    #
348
    #   Import user platform specification (GBE_PLATFORM)
349
    #   Note: This is also used by the Makefile and it cannot be
350
    #         alias expanded or sanitised. Its not really really useful
351
    #
352
    #   Only use GB_PLATFORM if the user has not specified to build ALL
353
    #   makefiles.
354
    #
355
    my %filter;
356
    my $filter_present = 0;
357
 
358
    if (  $::ScmAll == 0  )
359
    {
360
        foreach ( split( ' ', $ENV{ "GBE_PLATFORM" } || '' ) )
361
        {
362
            $filter{$_} = 1;
363
            $filter_present = 1;
364
        }
365
    }
366
 
367
    #
368
    #   Expand out the directive platform list (and optional arguments)
369
    #   Expand wildcards and aliases
370
    #
371
    #   Handle format
372
    #       Platform ('*', '--Options', [!Name]);
373
    #       Platform ('--NoPlatformBuilds' );
374
    #       Platform ('Name', '--Options', [!Name] );
375
    #       Platform ('!Name' );
376
    #
377
    #
378
    if ( $platforms[0] && $platforms[0] eq '*' )
379
    {
380
        my( $targets, $products );              # options
381
        my( @args );
382
        my( @exclude );
383
 
384
        $targets = $products = 0;
385
 
386
        foreach $_ ( @platforms ) {
387
            next if ( /^\*$/);
388
            next if ( /^--Targets$/ && ($targets = 1));
389
            next if ( /^--Products$/ && ($products = 1));
390
            next if ( /^--NoPlatformBuilds/ && ($noplatforms = 1));
391
            next if ( /^--/ && push @args, $_ );
392
            next if ( /^!/  && push @exclude, $_ );
393
            Warning( "Platform: unknown option $_ -- ignored\n" );
394
        }
395
 
396
        #
397
        #   Determine the list of platforms to expand the '*' into
398
        #   The result may be modified by optional arguments
399
        #       --Targets           # Expands to all targets
400
        #       --Products          # Expands to all products
401
        #       OtherWise           # Expands to all build platforms
402
        #
403
        @platforms = ();                        # zap list
404
 
405
                                                # 'all' platforms
406
        push( @platforms, @::DEFBUILDPLATFORMS )
407
            unless ( $targets | $products );
408
 
409
        #
410
        #   Expand the '*' into a list of platforms that are NOT products
411
        #
412
        if ( $targets && defined( %::ScmBuildPlatforms ) )
413
        {                                       # targets
414
            foreach my $key (keys %::ScmBuildPlatforms) {
415
                push( @platforms, $key )
416
                    if (! defined( %::ScmBuildProducts ) ||
417
                            ! scalar $::ScmBuildProducts{ $key } );
418
            }
419
        }
420
 
421
        #
422
        #   Expand the '*' into a list of platforms that are 'products'
423
        #
424
        if ( $products && defined( %::ScmBuildProducts ) )
425
        {                                       # products
426
            foreach my $key (keys %::ScmBuildProducts) {
427
                push( @platforms, $key );
428
            }
429
        }
430
 
431
        #
432
        #   Distribute arguments over all expanded platforms
433
        #
434
        if ( @args )
435
        {
436
            my @baseplatforms;
437
            foreach  ( @platforms )
438
            {
439
                push @baseplatforms, $_, @args;
440
            }
441
            @platforms = @baseplatforms;
442
        }
443
 
444
        #
445
        #   Place the excluded platforms at the end of the list
446
        #
447
        push @platforms, ExpandPlatforms( @exclude );
448
 
449
    }
450
    elsif ( scalar @platforms == 1 && $platforms[0] eq "--NoPlatformBuilds" )
451
    {                                           # short-cut
452
        $noplatforms = 1;
453
        @platforms = @::DEFBUILDPLATFORMS;
454
    }
455
    else
456
    {                                           # aliasing
457
        @platforms = ExpandPlatforms( @platforms );
458
        #
459
        #   Process excluded platform lists
460
        #   Migrate excluded platforms to the end of the list
461
        #
462
        my (@include, @exclude);
463
 
464
        foreach ( @platforms )
465
        {
466
            next if ( m/^!/ && push @exclude, $_ );
467
            push @include, $_;
468
        }
469
 
470
        #
471
        #   If no included platforms have been found then assume that the
472
        #   list is an exclusion list and seed the platform list with
473
        #   a set of defualt platforms - like '*'
474
        #
475
        #
476
        @include = @::DEFBUILDPLATFORMS unless @include;
477
        @platforms = ( @include, @exclude );
478
    }
479
 
480
    $platform = "";                             # current platform
481
 
482
    #
483
    #   Process the directives expanded list of platforms
484
    #
485
 
486
    #
487
    #   Generate a HASH of lowercase known platform names
488
    #   This will be used to quickly validate platform names
489
    #
490
    my %lc_platforms;
491
    foreach  ( @::BUILDPLATFORMS )
492
    {
493
        $lc_platforms{ lc($_) } = $_;
494
    }
495
 
496
FILTER:
497
    foreach $_ ( @platforms )
498
    {
499
        if ( ! /^--(.*)/ )
500
        {
501
            $_ =~ s/^\s*//g;                    # leading white space
502
            $_ =~ s/\s*(\n|$)//;                # trailing white space
503
 
504
 
505
            #
506
            #   Remove specific platforms from the list
507
            #
508
            $defplatforms = 1;
509
            if ( m/!(.*)/ )
510
            {
511
                Verbose( "Excluded platform removed: $1" );
512
                delete $platforms{$1};
513
                next FILTER;
514
            }
515
 
516
 
517
            if ( exists $platforms{$_}  )
518
            {
519
                Warning( "duplicate platform '$_' -- ignored." );
520
                $platform = "";
521
                next FILTER;
522
            }
523
 
524
            #
525
            #   validate 'platform'
526
            #   Allow the user to have a bad case match ( Fred == fred == FRED )
527
            #
528
            my $lc_platform = lc($_);
529
            unless ( exists( $lc_platforms{$lc_platform}  ) )
530
            {
531
                Warning( "Platform '$_' not contained within BuildPlatforms -- ignored." )
532
                    unless ( exists( $::ScmBuildPlatforms{$_} ));
533
                $platform = "";
534
                next FILTER;
535
            }
536
 
537
            $lc_platform = $lc_platforms{$lc_platform};
538
            if ( $_ ne $lc_platform )
539
            {
540
                Warning( "Mixed case usage of platform '$_' -- corrected." );
541
                $_ = $lc_platform;
542
            }
543
 
544
                                                # filter 'platform'
545
            if ( $filter_present  )
546
            {
547
                if ( ! exists $filter{$_} )
548
                {
549
                    Verbose( "GBE_PLATFORM override $_ -- ignored" );
550
                    $platform = "";
551
                    next FILTER;
552
                }
553
            }
554
 
555
            #
556
            #   Platform not filtered out - must be using it.
557
            #
558
            Verbose( "Platform ... $_" );
559
            $platforms{$_} = 1;                 # Add to platform list
560
            $platform = $_;                     # new platform
561
        }
562
 
563
        elsif ( /^--NoPlatformBuilds$/ )
564
        {
565
            $noplatforms = 1;
566
        }
567
 
568
        elsif ( $platform ne "" )
569
        {                                       # other arguments
570
            Verbose( "          .. $_" );
571
 
572
            HashUniqueJoin( \%::PLATFORMARGS, $; , $platform, $1 ) ||
573
                Warning( "Duplicate argument '$platform=$_' -- ignored." );
574
        }
575
    }
576
    #
577
    #   Sort the platforms to ensure that the ordering is consistient throughout
578
    #
579
    @::PLATFORMS = sort keys %platforms;
580
 
581
    #
582
    #   Trap makefiles that don't have any platforms
583
    #   The user 'should' mark these as --NoPlatformBuilds
584
    #
585
    unless ( @::PLATFORMS )
586
    {
587
        Warning( "No platform definitions." )
588
            unless( $noplatforms || $defplatforms);
589
        $noplatforms = 1;
590
    }
591
 
592
#.. Common rules
593
#
594
    my( $file ) = Require( "$::GBE_CONFIG", "Rules", "Common rules " );
595
    push( @::ScmDepends, "$file" );
596
 
597
 
598
#.. Generate primary makefile
599
#
600
    $exitVal = Generate( $noplatforms );
601
    if ($::ROOTMAKEFILE == 1) {
602
        print STDERR "WARNING: problem generating Makefile ($exitVal)\n"
603
            unless (($exitVal == $::Generated) || ($exitVal == 0));
604
        return ($exitVal);
605
    }
606
 
607
    Debug( "Platform ExitVal:   $exitVal" );
608
    exit( $exitVal );
609
}
610
 
611
###############################################################################
612
# Private function section.
613
#       The following functions are used INTERNALLY by makelib.pl.
614
#
615
###############################################################################
616
 
617
#-------------------------------------------------------------------------------
618
# Function        : Generate
619
#
620
# Description     : Build makefiles ...
621
#                   Creates the command data files and the per-target .MK files
622
#
623
# Inputs          : $noplatforms    - 1 if this makefile does not have
624
#                                       any platforms
625
#
626
# Returns         : $exitVal
627
#
628
sub Generate
629
{
630
    my( $noplatforms ) = @_;
631
    my( $exitVal ) = 0;
632
 
633
    #.. Dont build platforms within root directory
634
    #
635
    $noplatforms = 1
636
        if ($::ROOTMAKEFILE == 1);
637
 
638
    #.. Build 'makefile'
639
    #
640
    $exitVal = GeneratePlatforms()
641
        unless ($noplatforms );
642
 
643
    GenerateMakefile( $noplatforms );
644
    $exitVal = $::Generated if ( $exitVal == 0);
645
 
646
    return $exitVal;
647
}
648
 
649
 
650
#
651
#   Note:
652
#   Currently this function will create all .mk files in the current directory
653
#
654
#   Note: Cleanup of unused .mk files is done when the WriteCommonInfo  is
655
#         processed. Makefiles that are no lonker used will be purged
656
#
657
sub GeneratePlatforms
658
{
659
    my( $exitVal, $exitVal2 ) = 0;
660
 
661
    foreach my $platform ( @::PLATFORMS )
662
    {
663
        my( $Cmdline ) = "$::GBE_PERL $0 $::ScmRoot " . $::ScmMakelib . "2" . " $platform";
664
 
665
        $Cmdline .= " --interface=$::ScmInterface"
666
            if ( $::ScmInterface ne "" );
667
 
668
        #
669
        #   Insert platform local arguments
670
        #
671
        if ($::PLATFORMARGS{ $platform })
672
        {
673
            my( @args ) = split( /$;/, $::PLATFORMARGS{ $platform } );
674
            foreach my $arg (@args) {
675
                $Cmdline .= " --arg=$arg";
676
            }
677
        }
678
 
679
        $Cmdline .= " --expert"
680
            if ( $::ScmExpert );
681
 
682
        $Cmdline .= " --all"
683
            if ( $::ScmAll );
684
 
685
        $exitVal2 = System( $Cmdline );
686
 
687
        Warning ("Problem generating $platform.mk in $::Cwd ($exitVal2)")
688
            unless (($exitVal2 == $::Generated) || ($exitVal2 == 0));
689
 
690
        if ($exitVal == 0) {
691
            $exitVal = $exitVal2;
692
        } elsif ($exitVal == $::Generated) {
693
            $exitVal = $exitVal2
694
                if ($exitVal2);
695
        }
696
    }
697
 
698
    return $exitVal;
699
}
700
 
701
#-------------------------------------------------------------------------------
702
# Function        : GenerateMakefile
703
#
704
# Description     : Generate the non-platform specific makefile
705
#                   Once upon a time this was a real makefile
706
#                   Now its a simple file and a database as this offeres greater
707
#                   flexability.
708
#
709
#                   The file, "Makefile.gbe" contains enough info to get to the
710
#                   interface directory.
711
#
712
#                   The "database" is held in the interface directory as
713
#                       Makfile.cfg     - index to locate Makefile_nn.cfg
714
#                       Makefile_nn.cfg - data from a makefile.pl
715
#
716
# Inputs          : $noplatforms        - 1: no platform makefiles in this dir
717
#
718
# Returns         : Nothing
719
#
720
sub GenerateMakefile
721
{
722
    my( $noplatforms ) = @_;
723
    my %platform_info;
724
 
725
    #
726
    #   Determine targets that are limited to either debug or production builds
727
    #   This information may come from several places
728
    #
729
    foreach my $key ( @PLATFORMS )
730
    {
731
        my @args;
732
        UniquePush (\@args, split ( /$;/, $::PLATFORMARGS{$key} ))
733
            if ($::PLATFORMARGS{$key});
734
 
735
        UniquePush (\@args, map { s/^--//; $_} split ( /$;/, $::ScmBuildPlatforms{$key} ))
736
            if($::ScmBuildPlatforms{$key});
737
 
738
        my $hasOnlyProd  =  grep /^OnlyProd/, @args;
739
        my $hasOnlyDebug =  grep /^OnlyDebug/, @args;
740
 
741
        if ( $hasOnlyProd && $hasOnlyDebug )
742
        {
743
            Warning ("Target \"$key\" has both OnlyDebug and OnlyProd options",
744
                     "Both options ignored. Target will be built" );
745
 
746
            $hasOnlyProd = $hasOnlyDebug = 0;
747
        }
748
        $platform_info{$key}{prod}  = 1 unless $hasOnlyDebug;
749
        $platform_info{$key}{debug} = 1 unless $hasOnlyProd;
750
    }
751
 
752
    #
753
    #   Update common information in the Makefile_x.cfg file
754
    #
755
    WriteCommonInfo( \@::SUBDIRS, \%platform_info, $noplatforms, $::ROOTMAKEFILE );
756
 
757
    #
758
    #.. Maintain local information in Makefile.gbe
759
    #   This allows us to locate the interface directory
760
    #
761
    Message "[Control] $::Cwd";
762
    CreateMakeInfo();
763
}
764
 
765
1;
766