source: sasmodels/gen_so.py @ 306e354

core_shell_microgelscostrafo411magnetic_modelrelease_v0.94release_v0.95ticket-1257-vesicle-productticket_1156ticket_1265_superballticket_822_more_unit_tests
Last change on this file since 306e354 was 82c37f5, checked in by Piotr Rozyczko <piotr.rozyczko@…>, 9 years ago

Overwrite the default DLL_PATH for installation process

  • Property mode set to 100644
File size: 731 bytes
RevLine 
[e1454ab]1# Script to compile all C/C++ models
2# Part of the build process, referenced from setup.py
3import sys, os
4
5def main():
6    sasmodels = os.path.dirname(os.path.realpath(__file__))
7    sys.path.insert(0, sasmodels)
8    from sasmodels import generate, core
9
[82c37f5]10    # Put precompiled models in the topmost directory
11    import sasmodels.kerneldll
12    sasmodels.kerneldll.DLL_PATH="models"
13
[e1454ab]14    # Convert ../sasmodels/models/name.py to name
[bfdfb23]15    for model_name in core.list_models():
[e1454ab]16        # Choose only relevant python files
[bfdfb23]17            # model_info = core.load_model_info(model_name)
[e1454ab]18            # Run the conversion but don't delete the .so
[bfdfb23]19            model = core.precompile_dll(model_name)
[e1454ab]20
21if __name__ == "__main__":
22    main()
23
24
25
Note: See TracBrowser for help on using the repository browser.