Changeset e615a0d in sasview


Ignore:
Timestamp:
Dec 22, 2011 3:21:24 PM (12 years ago)
Author:
Jae Cho <jhjcho@…>
Branches:
master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
1eae432
Parents:
30ad350
Message:

defined is_64bit before being used

File:
1 edited

Legend:

Unmodified
Added
Removed
  • setup.py

    r30ad350 re615a0d  
    77 
    88import sys 
     9 
    910import os 
    1011import platform 
     
    4849if os.path.isdir(sans_dir): 
    4950    f_path = os.path.join(sans_dir, "sansview.log") 
    50     if sys.platform =='darwin' or sys.platform == 'win32': 
    51         if os.path.isfile(f_path): 
    52             os.remove(f_path) 
    53         f_path = os.path.join(sans_dir, 'config', "custom_config.py") 
    54         if os.path.isfile(f_path): 
    55             os.remove(f_path) 
    56         f_path = os.path.join(sans_dir, 'plugin_models') 
    57         if os.path.isdir(f_path): 
    58             for file in os.listdir(f_path):  
    59                 if file in plugin_model_list: 
    60                     file_path =  os.path.join(f_path, file) 
    61                     os.remove(file_path) 
    62  
    63  
     51    if os.path.isfile(f_path): 
     52        os.remove(f_path) 
     53    f_path = os.path.join(sans_dir, 'config', "custom_config.py") 
     54    if os.path.isfile(f_path): 
     55        os.remove(f_path) 
     56    f_path = os.path.join(sans_dir, 'plugin_models') 
     57    if os.path.isdir(f_path): 
     58        for file in os.listdir(f_path):  
     59            if file in plugin_model_list: 
     60                file_path =  os.path.join(f_path, file) 
     61                os.remove(file_path) 
     62                     
     63# 'sys.maxsize' and 64bit: Not supported for python2.5 
     64is_64bits = False 
     65if sys.version_info >= (2, 6): 
     66    is_64bits = sys.maxsize > 2**32 
     67     
     68     
    6469enable_openmp = True                     
    6570if sys.argv[-1] == "-nomp": 
     
    8186    def build_extensions(self): 
    8287        # Get 64-bitness 
    83         if sys.version_info >= (2, 6): 
    84             is_64bits = sys.maxsize > 2**32 
    85         else: 
    86             # 'sys.maxsize' and 64bit: Not supported for python2.5 
    87             is_64bits = False 
    88          
    8988        c = self.compiler.compiler_type 
    9089        print "Compiling with %s (64bit=%s)" % (c, str(is_64bits)) 
Note: See TracChangeset for help on using the changeset viewer.