Changeset 642a025 in sasview for sansmodels/src


Ignore:
Timestamp:
Jan 5, 2012 11:36:14 AM (13 years ago)
Author:
Mathieu Doucet <doucetm@…>
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:
bbbed8c
Parents:
6e10cff
Message:

remove files that are generated by build

Location:
sansmodels/src/python_wrapper
Files:
43 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • sansmodels/src/python_wrapper/WrapperGenerator.py

    r2d1b700 r642a025  
    5656    """ 
    5757     
    58     def __init__(self, filename, output_dir='.'): 
     58    def __init__(self, filename, output_dir='.', c_wrapper_dir='.'): 
    5959        """ Initialization """ 
    6060         
     
    9292        ## output directory for wrappers 
    9393        self.output_dir = output_dir 
     94        self.c_wrapper_dir = c_wrapper_dir 
    9495         
    9596         
     
    291292            The file is written in C[PYTHONCLASS].c 
    292293        """ 
    293         file_path = os.path.join(self.output_dir, "C"+self.pythonClass+'.cpp') 
     294        file_path = os.path.join(self.c_wrapper_dir, "C"+self.pythonClass+'.cpp') 
    294295        file = open(file_path, 'w') 
    295296         
     
    417418            The file is written in ../[PYTHONCLASS].py 
    418419        """ 
    419         file_path = os.path.join(self.output_dir, "../sans/models/"+self.pythonClass+'.py') 
     420        file_path = os.path.join(self.output_dir, self.pythonClass+'.py') 
    420421        file = open(file_path, 'w') 
    421422        template = open(os.path.join(os.path.dirname(__file__), "modelTemplate.txt"), 'r') 
  • sansmodels/src/python_wrapper/wrapping.py

    r2d1b700 r642a025  
    44from WrapperGenerator import WrapperGenerator 
    55 
    6 def generate_wrappers(header_dir, output_dir='.'): 
     6def generate_wrappers(header_dir, output_dir='.', c_wrapper_dir='.'): 
    77    nModels=0 
    88    for item in os.listdir(header_dir): 
     
    1111            nModels += 1 
    1212            name = toks[0] 
    13             app = WrapperGenerator(os.path.join(header_dir, name+".h"), output_dir=output_dir) 
     13            app = WrapperGenerator(os.path.join(header_dir, name+".h"),  
     14                                   output_dir=output_dir, 
     15                                   c_wrapper_dir=c_wrapper_dir) 
    1416            app.read() 
    1517            app.write_c_wrapper() 
     
    2022if __name__ == '__main__': 
    2123    header_dir = os.path.join('..', 'c_extensions') 
    22     generate_wrappers(header_dir) 
     24    generate_wrappers(header_dir, output_dir="../sans/models/", c_wrapper_dir='.') 
    2325 
    2426 
Note: See TracChangeset for help on using the changeset viewer.