Changeset 119618


Ignore:
Timestamp:
May 2, 2014, 3:13:06 PM (5 years ago)
Author:
snc@…
Message:

base: replace eval with expand

Location:
trunk/base/src/port1.0
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/base/src/port1.0/portconfigure.tcl

    r119184 r119618  
    8080        (![info exists option_defaults(${type}.cmd)] && [set ${type}.cmd] eq ${type})
    8181        )} {
    82             eval [linsert $dep 0 depends_build-append]
     82            depends_build-append {*}$dep
    8383    }
    8484}
     
    100100            automake.cmd    -
    101101            autoconf.cmd {
    102                 eval [linsert $configure_map(autoconf) 0 depends_build-delete]
     102                depends_build-delete $configure_map(autoconf)
    103103            }
    104104            xmkmf.cmd {
    105                 eval [linsert $configure_map(xmkmf) 0 depends_build-delete]
     105                depends_build-delete $configure_map(xmkmf)
    106106            }
    107107            use_xmkmf {
    108108                if {[tbool args]} {
    109                     eval [linsert $configure_map(xmkmf) 0 depends_build-append]
     109                    depends_build-appendl $configure_map(xmkmf)
    110110                }
    111111            }
     
    233233    foreach {re fmt} $valid_compilers {
    234234        if {[set matches [regexp -inline $re $compiler]] ne ""} {
    235             set compiler_name [eval [linsert [lrange $matches 1 end] 0 format $fmt]]
     235            set compiler_name [format $fmt {*}[lrange $matches 1 end]]
    236236            break
    237237        }
     
    388388    foreach {re fmt} $valid_compiler_ports {
    389389        if {[set matches [regexp -inline $re $compiler]] ne ""} {
    390             return [eval [linsert [lrange $matches 1 end] 0 format $fmt]]
     390            return [format $fmt {*}[lrange $matches 1 end]
    391391        }
    392392    }
     
    703703        } {
    704704            set value [option configure.[string tolower $env_var]]
    705             eval [linsert $value 0 append_to_environment_value configure $env_var]
     705            append_to_environment_value configure $env_var $value
    706706        }
    707707
     
    720720
    721721        # add extra flags that are conditional on whether we're building universal
    722         eval [linsert [get_canonical_archflags cc] 0 append_to_environment_value configure CFLAGS]
     722        append_to_environment_value configure CFLAGS {*}[get_canonical_archflags cc]
    723723        foreach tool {cxx objc objcxx cpp f77 f90 fc ld} {
    724724            if {[catch {get_canonical_archflags $tool} flags]} {
     
    726726            }
    727727            set env_var [string toupper $tool]FLAGS
    728             eval [linsert $flags 0 append_to_environment_value configure $env_var]
     728            append_to_environment_value configure $env_var {*}$flags
    729729        }
    730730        if {[variant_exists universal] && [variant_isset universal]} {
    731             eval [linsert ${configure.universal_args} 0 configure.pre_args-append]
     731            configure.pre_args-append ${configure.universal_args}
    732732        } else {
    733733            foreach env_var {CFLAGS CXXFLAGS OBJCFLAGS OBJCXXFLAGS FFLAGS F90FLAGS FCFLAGS LDFLAGS} {
  • trunk/base/src/port1.0/portutil.tcl

    r118455 r119618  
    28242824        lappend exec-lipo -arch ${arch} ${base}/${arch}${file}
    28252825    }
    2826     eval exec ${exec-lipo} [list -create -output ${target}${file}]
     2826    exec ${exec-lipo} {*}[list -create -output ${target}${file}]
    28272827}
    28282828
Note: See TracChangeset for help on using the changeset viewer.