Changeset a8d882a in sasview


Ignore:
Timestamp:
Feb 20, 2015 1:40:19 AM (9 years ago)
Author:
Peter Parker
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:
59b1b92
Parents:
0721c3d
git-author:
Peter Parker <peter.parker@…> (02/20/15 01:39:49)
git-committer:
Peter Parker <peter.parker@…> (02/20/15 01:40:19)
Message:

Let's see if this pulls in documentation to the Mac installer.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sasview/setup_mac.py

    r3a39c2e ra8d882a  
    2020import sys 
    2121import platform 
     22 
     23from distutils.util import get_platform 
     24root = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) 
     25platform = '%s-%s'%(get_platform(),sys.version[:3]) 
     26build_path = os.path.join(root, 'build','lib.'+platform) 
     27sys.path.insert(0, build_path) 
    2228 
    2329ICON = local_config.SetupIconFile_mac 
     
    5864if os.path.isfile("BUILD_NUMBER"): 
    5965    DATA_FILES.append("BUILD_NUMBER") 
     66 
     67# See if the documentation has been built, and if so include it. 
     68doc_path = os.path.join(build_path, "doc") 
     69if os.path.exists(doc_path): 
     70    for dirpath, dirnames, filenames in os.walk(doc_path): 
     71        for filename in filenames: 
     72            sub_dir = os.path.join("doc", os.path.relpath(dirpath, doc_path)) 
     73            data_files.append((sub_dir, [os.path.join(dirpath, filename)])) 
     74else: 
     75    raise Exception("You must first build the documentation before creating an installer.") 
    6076     
    6177# locate file extensions 
Note: See TracChangeset for help on using the changeset viewer.