Subversion Repositories DevTools

Rev

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

Rev 5677 Rev 5679
Line 74... Line 74...
74
    #   Platform specific definitions
74
    #   Platform specific definitions
75
    #
75
    #
76
    if ( $product eq "MS6001" )
76
    if ( $product eq "MS6001" )
77
    {
77
    {
78
        $productFound = $product;
78
        $productFound = $product;
79
        push @flags , '--eeprom_size=32768';
79
#push @flags , '--eeprom_size=32768';
80
Warning("TODO: eeprom size");
80
Warning("TODO: eeprom size");
81
 
81
 
82
        #   Compiler flags and definitions
82
        #   Compiler flags and definitions
83
        push @defines, '_MS6001;
83
        push @defines, '_MS6001';
84
 
84
 
85
        #   Assembler flags and definitions
85
        #   Assembler flags and definitions
86
        push @asdefines, '_MS6001';
86
        push @asdefines, '_MS6001';
87
    }
87
    }
88
    elsif ( $product )
88
    elsif ( $product )
Line 95... Line 95...
95
    {
95
    {
96
        #
96
        #
97
        #   Compiler flags and definitions
97
        #   Compiler flags and definitions
98
        #
98
        #
99
Warning("TODO: Compiler Flags");
99
Warning("TODO: Compiler Flags");
100
        push @flags , '-v6';
100
#       push @flags , '-v6';
101
        push @flags , '-ms';
101
#       push @flags , '-ms';
102
        push @flags , '-y';
102
#       push @flags , '-y';
103
        push @flags , '--enhanced_core';
103
#       push @flags , '--enhanced_core';
104
        push @flags , '--diag_suppress=pa050';
104
#       push @flags , '--diag_suppress=pa050';
105
        push @flags , '--initializers_in_flash';
105
#       push @flags , '--initializers_in_flash';
106
        push @flags , '--require_prototypes';
106
#       push @flags , '--require_prototypes';
107
 
107
 
108
        push @defines, '_EEP_EOW_MODE=IDLE_EEP_WRITE';
108
        push @defines, '_EEP_EOW_MODE=IDLE_EEP_WRITE';
109
 
109
 
110
 
110
 
111
        #
111
        #
112
        #   Assembler flags and definitions
112
        #   Assembler flags and definitions
113
        #
113
        #
114
Warning("TODO: Assembler Flags");
114
Warning("TODO: Assembler Flags");
115
        push @asflags , '-v6';                  # processor configuration
115
#       push @asflags , '-v6';                  # processor configuration
116
        push @asflags , '-s+';                  # Case-sensitive user symbols
116
#       push @asflags , '-s+';                  # Case-sensitive user symbols
117
        push @asflags , '-t8';                  # tab spacing...
117
#       push @asflags , '-t8';                  # tab spacing...
118
        push @asflags , '-u_enhancedCore';      # enable AVR-specific enhanced instructions
118
#       push @asflags , '-u_enhancedCore';      # enable AVR-specific enhanced instructions
119
 
119
 
120
        push @asdefines, '__MEMORY_MODEL__=2';
120
        push @asdefines, '__MEMORY_MODEL__=2';
121
        push @asdefines, '__HAS_ELPM__=1 ';
121
        push @asdefines, '__HAS_ELPM__=1 ';
122
        push @asdefines, '__HAS_ENHANCED_CORE__=1 ';
122
        push @asdefines, '__HAS_ENHANCED_CORE__=1 ';
123
        push @asdefines, 'ASSEMBLER';
123
        push @asdefines, 'ASSEMBLER';
Line 170... Line 170...
170
    ToolsetDefine ( "#" );
170
    ToolsetDefine ( "#" );
171
    ToolsetDefine ( "avr_iar_ver         = $version" );
171
    ToolsetDefine ( "avr_iar_ver         = $version" );
172
    ToolsetDefine ( "avr_iar_prod        = $product" );
172
    ToolsetDefine ( "avr_iar_prod        = $product" );
173
    ToolsetDefine ( "" );
173
    ToolsetDefine ( "" );
174
    ToolsetDefine ( "#" );
174
    ToolsetDefine ( "#" );
175
    ToolsetDefines( "CORTEX IAR.def" );
175
    ToolsetDefines( "cortexm3_iar.def" );
176
    ToolsetRules  ( "avr_iar.rul" );
176
    ToolsetRules  ( "avr_iar.rul" );
177
    ToolsetRules  ( "standard.rul" );
177
    ToolsetRules  ( "standard.rul" );
178
 
178
 
179
    #
179
    #
180
    #   Specify compiler parameters
180
    #   Specify compiler parameters
Line 437... Line 437...
437
}
437
}
438
 
438
 
439
#
439
#
440
#   Extend the list of libraries with compiler specific libraries
440
#   Extend the list of libraries with compiler specific libraries
441
#
441
#
442
    push( @$pLibs, "\$(avr_linker_lib)" );
442
#    push( @$pLibs, "\$(avr_linker_lib)" );
-
 
443
Warning("TODO: Add toolset library-1");
443
 
444
 
444
#
445
#
445
#   Create a ToolsetPrinter
446
#   Create a ToolsetPrinter
446
#
447
#
447
    my ($io) = ToolsetPrinter::New();
448
    my ($io) = ToolsetPrinter::New();
Line 504... Line 505...
504
    #   This bit of magic will be performed by the LD_IAR recipe
505
    #   This bit of magic will be performed by the LD_IAR recipe
505
    #
506
    #
506
    $io->SetTag( "${name}_ld" );                            # macro tag
507
    $io->SetTag( "${name}_ld" );                            # macro tag
507
    $io->Label( "Linker commands", $name );                 # label
508
    $io->Label( "Linker commands", $name );                 # label
508
 
509
 
509
    $io->Cmd("-S" );                                        # Silent
510
#    $io->Cmd("-S" );                                        # Silent
510
    $io->Cmd("-Omotorola=$s19" );                           # Output file
511
#    $io->Cmd("-Omotorola=$s19" );                           # Output file
511
    $io->Cmd("-o $d90" );                                   # Output file
512
    $io->Cmd("-o $d90" );                                   # Output file
512
    $io->Cmd("-l $map" );                                   # Map file
513
    $io->Cmd("-l $map" );                                   # Map file
513
    $io->Cmd("-r" );                                        # Output with debug
514
#    $io->Cmd("-r" );                                        # Output with debug
514
    $io->Cmd("-z" );                                        # Reduce segment overlap errors
515
#    $io->Cmd("-z" );                                        # Reduce segment overlap errors
515
    $io->Cmd("-xmsn" );                                     # Add info to the map file
516
    $io->Cmd("-xmsn" );                                     # Add info to the map file
516
    $io->Cmd("-p100" );                                     # Number of line per page
517
#    $io->Cmd("-p100" );                                     # Number of line per page
517
    $io->Cmd("-f $script" );                                # User script file
518
    $io->Cmd("-f $script" );                                # User script file
-
 
519
Warning("TODO: Add Linker commands");
518
 
520
 
519
    $io->ObjList( $name, $pObjs, \&ToolsetObjRecipe );      # Object files
521
    $io->ObjList( $name, $pObjs, \&ToolsetObjRecipe );      # Object files
520
 
522
 
521
    #
523
    #
522
    #   Specify the library files
524
    #   Specify the library files
523
    #
525
    #
524
    $io->Cmd( '"-I$(avr_linker_lib_dir)"' );                # Toolset library directory
526
#    $io->Cmd( '"-I$(avr_linker_lib_dir)"' );                # Toolset library directory
-
 
527
Warning("TODO: Add toolset library-2");
525
    $io->LibList( $name, $pLibs, \&ToolsetLibRecipe );      # Specify the libraries too
528
    $io->LibList( $name, $pLibs, \&ToolsetLibRecipe );      # Specify the libraries too
526
    $io->Newline();
529
    $io->Newline();
527
 
530
 
528
    #.. Dependency link,
531
    #.. Dependency link,
529
    #   Create a library dependency file
532
    #   Create a library dependency file
Line 551... Line 554...
551
 
554
 
552
    $io->Label( "SXML File", $name );
555
    $io->Label( "SXML File", $name );
553
    $io->Prt( "$sxml: $s19\n");
556
    $io->Prt( "$sxml: $s19\n");
554
    $io->Prt( "\t\$(call GENERATE_SXML, \\" .
557
    $io->Prt( "\t\$(call GENERATE_SXML, \\" .
555
              "\n\t\t\$(BINDIR)/${name}$exe, \\" .
558
              "\n\t\t\$(BINDIR)/${name}$exe, \\" .
556
              "\n\t\t$sxml,$type_text,$major,$minor,$patch,$build)\n"
559
              "\n\t\t$sxml,$type_text,$major,$minor,$patch,$build,InsideSecure)\n"
557
              );
560
              );
558
    $io->Newline();
561
    $io->Newline();
559
 
562
 
560
    #
563
    #
561
    #   Generated files to be added to the program file list
564
    #   Generated files to be added to the program file list