Changeset 2175


Ignore:
Timestamp:
Mar 30, 2011 1:45:19 PM (13 years ago)
Author:
gah
Message:

updates to makefiles

Location:
trunk
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • trunk/examples/Makefile.in

    r1944 r2175  
    11
    22bindir          = @bindir@
    3 datadir         = @datadir@
    4 datarootdir     = @datarootdir@
     3datadir         = @datadir@
     4datarootdir     = @datarootdir@
    55exec_prefix     = @exec_prefix@
    66includedir      = @includedir@
     
    88mandir          = @mandir@
    99prefix          = @prefix@
    10 destdir         = $(prefix)/examples/3D
     10destdir         = $(prefix)/examples/3D
    1111
    12 SHELL           = @SHELL@
    13 INSTALL         = @INSTALL@
    14 MKDIR_P         = @MKDIR_P@
     12SHELL           = @SHELL@
     13INSTALL         = @INSTALL@
     14MKDIR_P         = @MKDIR_P@
    1515
    16 destdir         = $(prefix)/examples
     16destdir         = $(prefix)/examples
    1717
    1818FILES           = \
     
    2727                graph \
    2828                objects \
    29                 zoo
     29                zoo 
    3030
    3131
    32 .PHONY: $(SUBDIRS)
     32.PHONY:         $(SUBDIRS)
    3333
    3434all:  build
     
    4242        $(MKDIR_P) -m 0755 $(destdir)
    4343        for i in $(FILES) ; do \
    44           $(INSTALL) -m 555 $$i $(destdir) ; \
     44          $(INSTALL) -m 0555 $$i $(destdir) ; \
    4545        done
    4646        for i in $(SUBDIRS) ; do \
  • trunk/examples/app-fermi/octave/Makefile.in

    r1581 r2175  
    1515MKDIR_P         = @MKDIR_P@
    1616
    17 all: all_2 all_3
     17SUBDIRS         = 2 3
    1818
    19 all_2:
    20         $(MAKE) -C 2 all
     19all:
     20        for i in $(SUBDIRS) ; do \
     21          $(MAKE) -C $$i all || exit 1 ;\
     22        done
    2123
    22 all_3:
    23         $(MAKE) -C 3 all
    24 
    25 
    26 install: install_2 install_3
    27 
    28 install_2:
    29         $(MAKE) -C 2 install
    30 
    31 install_3:
    32         $(MAKE) -C 3 install
     24install:
     25        for i in $(SUBDIRS) ; do \
     26          $(MAKE) -C $$i install || exit 1 ;\
     27        done
    3328
    3429clean:
     30        for i in $(SUBDIRS) ; do \
     31          $(MAKE) -C $$i clean ;\
     32        done
    3533
    3634distclean: clean
  • trunk/examples/flow/Makefile.in

    r1944 r2175  
    3434        $(MKDIR_P) -m 0755 $(destdir)
    3535        for i in $(FILES) ; do \
    36           $(INSTALL) -m 444  $$i $(destdir) ; \
     36          $(INSTALL) -m 0444  $$i $(destdir) ; \
    3737        done
    3838        for i in $(examples) ; do \
  • trunk/gui/Makefile.in

    r2117 r2175  
    2828.PHONY: src scripts apps
    2929
    30 all: src scripts apps
     30SUBDIRS         = src scripts apps
    3131
    32 scripts:
    33         $(MAKE) -C scripts all
    34 src:
    35         $(MAKE) -C src all
    36 apps:
    37         $(MAKE) -C apps all
     32all:
     33        for i in $(SUBDIRS) ; do \
     34          $(MAKE) -C $$i all || exit 1 ;\
     35        done
    3836
    39 install: install_src install_scripts install_apps
     37install:
    4038        $(MKDIR_P) -m 0755 $(destdir)
    41         @for i in $(FILES); do \
     39        for i in $(FILES); do \
    4240            echo "Installing $$i" ; \
    43             $(INSTALL) -m 444 $$i $(destdir) ; \
     41            $(INSTALL) -m 0444 $$i $(destdir) ; \
    4442        done
    45         $(INSTALL) -m 444 pkgIndex.tcl $(destdir)
    46 
    47 install_scripts: scripts
    48         $(MAKE) -C scripts install
    49 install_src: src
    50         $(MAKE) -C src install
    51 install_apps: apps
    52         $(MAKE) -C apps install
     43        for i in $(SUBDIRS) ; do \
     44          $(MAKE) -C $$i install || exit 1 ;\
     45        done
    5346
    5447test:
     
    5649
    5750clean:
    58         $(MAKE) -C scripts clean
    59         $(MAKE) -C apps clean
     51        for i in $(SUBDIRS) ; do \
     52          $(MAKE) -C $$i clean ;\
     53        done
    6054
    6155distclean:
    62         $(MAKE) -C scripts distclean
    63         $(MAKE) -C apps distclean
     56        for i in $(SUBDIRS) ; do \
     57          $(MAKE) -C $$i distclean ;\
     58        done
    6459        $(RM) Makefile pkgIndex.tcl
    6560        $(RM) config.cache config.log config.status
  • trunk/gui/scripts/Makefile.in

    r2127 r2175  
    150150        @for i in $(FILES); do \
    151151            echo "Installing $$i" ; \
    152             $(INSTALL) -m 444 $$i $(destdir) ; \
     152            $(INSTALL) -m 0444 $$i $(destdir) ; \
    153153        done
    154         $(INSTALL) -m 444 tclIndex $(destdir)
     154        $(INSTALL) -m 0444 tclIndex $(destdir)
    155155
    156156install_images:
     
    158158        @for i in $(srcdir)/images/*.gif $(srcdir)/images/*.png $(srcdir)/images/*.xbm; do \
    159159            echo "Installing $$i" ; \
    160             $(INSTALL) -m 444 $$i $(destdir)/images ; \
     160            $(INSTALL) -m 0444 $$i $(destdir)/images ; \
    161161        done
    162162
  • trunk/gui/scripts/analyzer.tcl

    r1940 r2175  
    11551155#
    11561156# Used internally to determine whether pdb or lammps data represents a
    1157 # trajectory rather than a single model
     1157# trajectory rather than a single frame
    11581158# ----------------------------------------------------------------------
    11591159itcl::body Rappture::Analyzer::_isPdbTrajectory {data} {
     
    11791179#
    11801180# Used internally to determine whether pdb or lammps data represents a
    1181 # trajectory rather than a single model
     1181# trajectory rather than a single frame
    11821182# ----------------------------------------------------------------------
    11831183itcl::body Rappture::Analyzer::_isLammpsTrajectory { data } {
     
    12191219    $xmlobj put ${sequence}.about.label $seqLabel
    12201220    $xmlobj put ${sequence}.about.description $descr
    1221     $xmlobj put ${sequence}.index.label "Model"
    1222 
    1223     set modelNum 1
     1221    $xmlobj put ${sequence}.index.label "Frame"
     1222
     1223    set frameNum 0
    12241224    set numLines [llength $data]
    12251225    for { set i 0 } { $i < $numLines } { incr i } {
     
    12401240                append contents $line\n
    12411241            }
    1242             set model ${sequence}.element($modelNum)
    1243             $xmlobj put ${model}.index $modelNum
     1242            set frame ${sequence}.element($frameNum)
     1243            $xmlobj put ${frame}.index $frameNum
    12441244           
    1245             set molecule ${model}.structure.components.molecule
     1245            set molecule ${frame}.structure.components.molecule
    12461246            $xmlobj put ${molecule}.pdb $contents
    12471247            $xmlobj put ${molecule}.formula $formula
    1248             incr modelNum
     1248            incr frameNum
    12491249        }
    12501250    }
     
    12711271    $xmlobj put ${sequence}.about.label $seqLabel
    12721272    $xmlobj put ${sequence}.about.description $descr
    1273     $xmlobj put ${sequence}.index.label "Model"
    1274 
    1275     set modelNum 1
    1276     set modelContents ""
     1273    $xmlobj put ${sequence}.index.label "Frame"
     1274
     1275    set frameNum 0
     1276    set frameContents ""
    12771277    set inModel 0
    12781278    foreach line $data {
     
    12821282        }
    12831283        if {[regexp {^[\t ]*ITEM:[ \t]+ATOMS} $line] } {
    1284             if { $inModel && $modelContents != "" } {
    1285                 set model ${sequence}.element($modelNum)
    1286                 $xmlobj put ${model}.index $modelNum
     1284            if { $inModel && $frameContents != "" } {
     1285                set frame ${sequence}.element($frameNum)
     1286                $xmlobj put ${frame}.index $frameNum
    12871287               
    1288                 set molecule ${model}.structure.components.molecule
    1289                 $xmlobj put ${molecule}.lammps $modelContents
     1288                set molecule ${frame}.structure.components.molecule
     1289                $xmlobj put ${molecule}.lammps $frameContents
    12901290                $xmlobj put ${molecule}.lammpstypemap $typemap
    12911291               
    1292                 incr modelNum
    1293                 set modelContents ""
     1292                incr frameNum
     1293                set frameContents ""
    12941294            }
    12951295            set inModel 1
     
    12991299                set inModel 1
    13001300            }
    1301             append modelContents $line\n
    1302         }
    1303     }
    1304     if { $modelContents != "" } {
    1305         set model ${sequence}.element($modelNum)
    1306         $xmlobj put ${model}.index $modelNum
     1301            append frameContents $line\n
     1302        }
     1303    }
     1304    if { $frameContents != "" } {
     1305        set frame ${sequence}.element($frameNum)
     1306        $xmlobj put ${frame}.index $frameNum
    13071307       
    1308         set molecule ${model}.structure.components.molecule
    1309         $xmlobj put ${molecule}.lammps $modelContents
     1308        set molecule ${frame}.structure.components.molecule
     1309        $xmlobj put ${molecule}.lammps $frameContents
    13101310        $xmlobj put ${molecule}.lammpstypemap $typemap
    13111311    }
  • trunk/gui/scripts/controls.tcl

    r2159 r2175  
    184184        }
    185185    }
     186
     187    #
     188    # If this element has an <enable> expression, then register
     189    # its controlling widget here.
     190    #
     191    set notify [string trim [$_owner xml get $path.about.notify]]
    186192
    187193    #
  • trunk/lang/tcl/scripts/library.tcl

    r2134 r2175  
    509509        return ""
    510510    }
     511    # Expat (via tDOM) will always produce utf-8 output, regardless of the
     512    # encoding of the tool.xml.  We need to convert utf-8 to unicode for
     513    # Tcl/Tk.  This shouldn't affect ASCII tool.xml files.
     514    set string [encoding convertfrom utf-8 [$node text]]
    511515    if {$params(-decode) == "yes"} {
    512         return [Rappture::encoding::decode -- [string trim [$node text]]]
    513     } else {
    514         return [string trim [$node text]]
    515     }
     516        set string [Rappture::encoding::decode -- $string]
     517    }
     518    return [string trim $string]
    516519}
    517520
  • trunk/lang/tcl/src/RpRusage.c

    r2079 r2175  
    195195    double tval;
    196196    RpRusageStats curstats;
    197     char buffer[TCL_DOUBLE_SPACE];
     197    Tcl_Obj *listObjPtr, *objPtr;
    198198
    199199    if (RpRusageCapture(interp, &curstats) != TCL_OK) {
     
    213213    markPtr = (RpRusageStats*)Tcl_GetHashValue(entryPtr);
    214214
     215    listObjPtr = Tcl_NewListObj(0, (Tcl_Obj **)NULL);
    215216    /*
    216217     * Compute: START TIME
    217218     */
    218     Tcl_AppendElement(interp, "start");
     219    objPtr = Tcl_NewStringObj("start", 5);
     220    Tcl_ListObjAppendElement(interp, listObjPtr, objPtr);
    219221    tval = RpRusageTimeDiff(&markPtr->times, &RpRusage_Start.times);
    220     Tcl_PrintDouble(interp, tval, buffer);
    221     Tcl_AppendElement(interp, buffer);
     222    objPtr = Tcl_NewDoubleObj(tval);
     223    Tcl_ListObjAppendElement(interp, listObjPtr, objPtr);
    222224
    223225    /*
    224226     * Compute: WALL TIME
    225227     */
    226     Tcl_AppendElement(interp, "walltime");
     228    objPtr = Tcl_NewStringObj("walltime", 8);
     229    Tcl_ListObjAppendElement(interp, listObjPtr, objPtr);
    227230    tval = RpRusageTimeDiff(&curstats.times, &markPtr->times);
    228     Tcl_PrintDouble(interp, tval, buffer);
    229     Tcl_AppendElement(interp, buffer);
     231    objPtr = Tcl_NewDoubleObj(tval);
     232    Tcl_ListObjAppendElement(interp, listObjPtr, objPtr);
     233
    230234
    231235    /*
    232236     * Compute: CPU TIME = user time + system time
    233237     */
    234     Tcl_AppendElement(interp, "cputime");
     238    objPtr = Tcl_NewStringObj("cputime", 7);
     239    Tcl_ListObjAppendElement(interp, listObjPtr, objPtr);
    235240    tval = RpRusageTimeDiff(&curstats.resources.ru_utime,
    236241             &markPtr->resources.ru_utime)
    237242         + RpRusageTimeDiff(&curstats.resources.ru_stime,
    238243             &markPtr->resources.ru_stime);
    239     Tcl_PrintDouble(interp, tval, buffer);
    240     Tcl_AppendElement(interp, buffer);
    241 
     244    objPtr = Tcl_NewDoubleObj(tval);
     245    Tcl_ListObjAppendElement(interp, listObjPtr, objPtr);
     246    Tcl_SetObjResult(interp, listObjPtr);
    242247    return TCL_OK;
    243248}
Note: See TracChangeset for help on using the changeset viewer.