Changeset 87 for trunk


Ignore:
Timestamp:
Apr 15, 2006, 6:58:32 PM (19 years ago)
Author:
dmik
Message:
  • Fixed EXPRESSION HAS NO VALUE when too few oject files were supplied on the command line.
  • Added the '-version' command line switch that defines a string to replace all occurences of the new '${version}' macro found in a DEF template.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/mkspecs/os2-g++/emxexpw.cmd

    r8 r87  
    5858Opt.!DefFile         = ''
    5959Opt.!LibName         = ''
     60Opt.!LibVersion      = ''
    6061Opt.!DefTemplate     = ''
    6162Opt.!DefMap          = ''
     
    142143        call lineout G.!ObjectListFile
    143144    end
     145    else
     146        G.!ObjectListFile = ''
    144147
    145148    if (Opt.!DefMap == '') then do
     
    177180            call lineout Opt.!DefFile
    178181
    179             call SysFileDelete G.!ObjectListFile
    180             G.!ObjectListFile = ''
     182            if (G.!ObjectListFile \= '') then do
     183                call SysFileDelete G.!ObjectListFile
     184                G.!ObjectListFile = ''
     185            end
    181186
    182187            if (rc \== 0) then
     
    209214        if (rc \== 0) then call Error E_EMXEXPFailed, rc
    210215
    211         call SysFileDelete G.!ObjectListFile
    212         G.!ObjectListFile = ''
     216        if (G.!ObjectListFile \= '') then do
     217            call SysFileDelete G.!ObjectListFile
     218            G.!ObjectListFile = ''
     219        end
    213220
    214221        /* parse the temporary DEF file and combine with G.!Exports */
     
    306313            if (epos == 0) then do
    307314                str = Replace(str, '${name}', Opt.!LibName)
     315                str = Replace(str, '${version}', Opt.!LibVersion)
    308316                call lineout Opt.!DefFile, str
    309317            end
     
    323331        str = linein(Opt.!DefTemplate)
    324332        str = Replace(str, '${name}', Opt.!LibName)
     333        str = Replace(str, '${version}', Opt.!LibVersion)
    325334        call lineout Opt.!DefFile, str
    326335    end
     
    615624                    Opt.!LibName = G.!opts.i
    616625                end
     626                when (o == 'version') then do
     627                    i = i + 1
     628                    Opt.!LibVersion = G.!opts.i
     629                end
    617630                when (o == 'template') then do
    618631                    i = i + 1
     
    666679    say '   -def <file>             : Output DEF file [required]'
    667680    say '   -name <string>          : Library name [default: DEF file w/o extension]'
     681    say '   -version <string>       : Library version [default: none]'
    668682    say '   -template <file>        : DEF file template [default: none]'
    669683    say '   -map <file>             : Input/output map file [default: none]'
     
    692706    say
    693707    say '-  ${name} is replaced with the library name;'
     708    say '-  ${version} is replaced with the library version;'
    694709    say '-  ${exports} is replaced with the list of exported entries.'
    695710
Note: See TracChangeset for help on using the changeset viewer.