root/trunk/ports/net/macathena-machtype/files/getSysnameList.py

Revision 201, 0.6 kB (checked in by quentin, 12 years ago)

Update and fix the macathena-machtype port

  • Property svn:executable set to *
Line 
1 #!/usr/bin/env python
2
3 from commands import getoutput
4
5 arch = getoutput('arch')
6 darwin_ver = int(getoutput('uname -r').split('.')[0]) * 10
7
8 ver_list = range(darwin_ver, 70, -10)
9 x86_list = ["x86_darwin_%d" % ver for ver in ver_list]
10 ppc_list = ["ppc_darwin_%d" % ver for ver in ver_list]
11
12 if arch == 'i386' and darwin_ver >= 110:
13         versions = x86_list
14 elif arch == 'i386':
15         versions = [item for items in zip(x86_list, ppc_list) for item in items]
16 else:
17         versions = ppc_list
18
19 versions += ['share', 'common', 'any', 'all']
20
21 print 'ATHENA_SYS=%s ATHENA_SYS_COMPAT="%s"' % (versions[0], ':'.join(versions[1:]))
Note: See TracBrowser for help on using the browser.