comparison setup.py @ 6241:a718e66836e8

setup.py: os.uname is not available on Windows
author Bryan O'Sullivan <bos@serpentine.com>
date Wed, 12 Mar 2008 15:33:43 -0700
parents 39cfcef4f463
children 0d0939b2d272
comparison
equal deleted inserted replaced
6240:6679405e95da 6241:a718e66836e8
59 Extension('mercurial.diffhelpers', ['mercurial/diffhelpers.c']) 59 Extension('mercurial.diffhelpers', ['mercurial/diffhelpers.c'])
60 ] 60 ]
61 61
62 packages = ['mercurial', 'mercurial.hgweb', 'hgext', 'hgext.convert'] 62 packages = ['mercurial', 'mercurial.hgweb', 'hgext', 'hgext.convert']
63 63
64 if sys.platform == 'linux2' and os.uname()[2] > '2.6':
65 # the inotify extension is only usable with Linux 2.6 kernels
66 ext_modules.append(Extension('hgext.inotify.linux._inotify',
67 ['hgext/inotify/linux/_inotify.c']))
68 packages.extend(['hgext.inotify', 'hgext.inotify.linux'])
69
70 try: 64 try:
71 import posix 65 import posix
72 ext_modules.append(Extension('mercurial.osutil', ['mercurial/osutil.c'])) 66 ext_modules.append(Extension('mercurial.osutil', ['mercurial/osutil.c']))
67
68 if sys.platform == 'linux2' and os.uname()[2] > '2.6':
69 # the inotify extension is only usable with Linux 2.6 kernels
70 ext_modules.append(Extension('hgext.inotify.linux._inotify',
71 ['hgext/inotify/linux/_inotify.c']))
72 packages.extend(['hgext.inotify', 'hgext.inotify.linux'])
73 except ImportError: 73 except ImportError:
74 pass 74 pass
75 75
76 setup(name='mercurial', 76 setup(name='mercurial',
77 version=mercurial.version.get_version(), 77 version=mercurial.version.get_version(),