source: sasview/sansview/setup_mac.py @ 8a7d922

ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalccostrafo411magnetic_scattrelease-4.1.1release-4.1.2release-4.2.2release_4.0.1ticket-1009ticket-1094-headlessticket-1242-2d-resolutionticket-1243ticket-1249ticket885unittest-saveload
Last change on this file since 8a7d922 was e6093db, checked in by Jae Cho <jhjcho@…>, 15 years ago

updated lxml version #

  • Property mode set to 100644
File size: 1.4 KB
RevLine 
[8d143e8]1"""
[46e7e82]2This is a setup.py script partly generated by py2applet
[8d143e8]3
4Usage:
5    python setup.py py2app
6"""
7from setuptools import setup
[01255b5]8import periodictable.xsf
9import DataLoader.readers 
10from distutils.sysconfig import get_python_lib
11import os
12
13DATA_FILES = []
[81875d2]14RESOURCES_FILES = []
[01255b5]15
16#Periodictable data file
[81875d2]17DATA_FILES = periodictable.data_files()
[01255b5]18
[46e7e82]19#invariant and calculator help doc
20import sans.perspectives.calculator as calculator
21DATA_FILES += calculator.data_files()
22import sans.perspectives.invariant as invariant
23DATA_FILES += invariant.data_files()
24
[81875d2]25#CANSAxml reader data files
26RESOURCES_FILES.append(os.path.join(DataLoader.readers.get_data_path(),'defaults.xml'))
[8d143e8]27
[67ffb10]28# Locate libxml2 library
29lib_locs = ['/usr/local/lib', '/usr/lib']
30libxml_path = None
31for item in lib_locs:
[e6093db]32    libxml_path_test = '%s/libxml2.2.dylib' % item
[2eb3a682]33    if os.path.isfile(libxml_path_test): 
34        libxml_path = libxml_path_test
[67ffb10]35if libxml_path == None:
36    raise RuntimeError, "Could not find libxml2 on the system"
37
[8d143e8]38APP = ['sansview.py']
[46e7e82]39DATA_FILES += ['images','test','plugins','media']
[81875d2]40OPTIONS = {'argv_emulation': True,
41           'packages': ['lxml','periodictable'],
42           'iconfile': 'images/ball.icns',
[67ffb10]43           'frameworks':[libxml_path],
[81875d2]44           'resources': RESOURCES_FILES
[8d143e8]45           }
46
47setup(
48    app=APP,
49    data_files=DATA_FILES,
[01255b5]50    include_package_data= True,
[8d143e8]51    options={'py2app': OPTIONS},
52    setup_requires=['py2app'],
53)
Note: See TracBrowser for help on using the repository browser.