Changeset 686 for branches


Ignore:
Timestamp:
Oct 25, 2007 1:32:39 PM (12 years ago)
Author:
jpfasano
Message:

Moved to computing of the vpath directory to the top of the function

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/testScripts/NBbuildConfig.py

    r685 r686  
    6868
    6969  #---------------------------------------------------------------------
    70   # svn checkout or update the project
     70  # Create names of directory where source is located and
     71  # and were object, libs and executables are located (vpath).
     72  # To compute vpath directory, the ./configure options need to be
     73  # generated.
    7174  #---------------------------------------------------------------------
    7275  projectBaseDir=os.path.join(configuration['rootDir'],configuration['project'])
    7376  projectCheckOutDir=os.path.join(projectBaseDir,svnVersionFlattened)
    7477
     78  vpathDir=''
     79
     80  if 'SkipProjects' in configuration :
     81    vpathDir+="No"+configuration['SkipProjects']
     82  if 'noThirdParty' in configuration :
     83    if configuration['noThirdParty'] :
     84      vpathDir+='-NoThirdParty'
     85  vpathDir=svnVersionFlattened+\
     86          configuration['configOptions']['unique']+\
     87          vpathDir
     88  vpathDir=vpathDir.replace(' ','')
     89  vpathDir=vpathDir.replace('"','')
     90  vpathDir=vpathDir.replace("'",'')
     91  vpathDir=vpathDir.replace('--enable','')
     92  if vpathDir==svnVersionFlattened : vpathDir+='-default'
     93
     94  fullVpathDir = os.path.join(projectBaseDir,vpathDir)
     95
     96  #---------------------------------------------------------------------
     97  # Create the vpath directory if it doesn't exist
     98  # and remove file that indicates prior run tested ok.
     99  #---------------------------------------------------------------------
     100  if not os.path.isdir(fullVpathDir) :
     101    os.makedirs(fullVpathDir)
     102  os.chdir(fullVpathDir)
     103  if os.path.isfile('NBallTestsPassed') : os.remove('NBallTestsPassed')
     104
     105  #---------------------------------------------------------------------
     106  # svn checkout or update the project
     107  #---------------------------------------------------------------------
    75108  # Don't get source from subversion if previously done
    76109  if projectCheckOutDir not in SVN_HISTORY :
     
    135168  #---------------------------------------------------------------------
    136169  skipOptions=''
    137   vpathDir=''
    138170
    139171  if 'SkipProjects' in configuration :
     
    146178  elif configuration['noThirdParty'] :
    147179    needSkip3PartySkipOptions=True
    148     vpathDir='-NoThirdParty'
    149180  if needSkip3PartySkipOptions :
    150181    thirdPartyBaseDir=os.path.join(projectCheckOutDir,'ThirdParty')
     
    157188    skipOptions=' COIN_SKIP_PROJECTS="'+skipOptions+'"'
    158189
    159   # Determine the build directory, and make sure it exists   
    160   vpathDir=svnVersionFlattened+\
    161           configuration['configOptions']['unique']+\
    162           vpathDir
    163   vpathDir=vpathDir.replace(' ','')
    164   vpathDir=vpathDir.replace('"','')
    165   vpathDir=vpathDir.replace("'",'')
    166   vpathDir=vpathDir.replace('--enable','')
    167   if vpathDir==svnVersionFlattened : vpathDir+='-default'
    168 
    169   fullVpathDir = os.path.join(projectBaseDir,vpathDir)
    170   if not os.path.isdir(fullVpathDir) :
    171     os.makedirs(fullVpathDir)
    172190  os.chdir(fullVpathDir)
    173191  NBlogMessages.writeMessage('  Current directory: '+fullVpathDir)
    174 
     192 
    175193  # Assemble all config options together and create config command
    176194  configOptions ="-C "+configuration['configOptions']['unique']
     
    283301  # Everything build and all tests passed.
    284302  #---------------------------------------------------------------------
    285   os.chdir(fullVpathDir)
    286   f=open('NBallTestsPassed','w')
    287   f.close()
     303  #os.chdir(fullVpathDir)
     304  #f=open('NBallTestsPassed','w')
     305  #f.close()
Note: See TracChangeset for help on using the changeset viewer.