mirror of
https://frontier.innolan.net/github/amigaos-cross-toolchain6.git
synced 2024-10-19 10:29:55 +00:00
Fixed a bug with Python headers on 64-bit Debian.
This commit is contained in:
@@ -454,7 +454,7 @@ def make(name, target=None, **makevars):
|
||||
def require_header(header, lang, msg='', symbol=None, value=None):
|
||||
debug('require_header "%s"', header)
|
||||
|
||||
cmd = {'c': '{cc}', 'c++': '{cxx}'}[lang]
|
||||
cmd = {'c': os.environ['CC'], 'c++': os.environ['CXX']}[lang]
|
||||
cmd = fill_in(cmd).split()
|
||||
proc = subprocess.Popen(cmd + ['-fsyntax-only', '-x', lang, '-'],
|
||||
stdin=subprocess.PIPE,
|
||||
|
||||
+11
-9
@@ -216,6 +216,9 @@ def build():
|
||||
else:
|
||||
CC, CXX = 'gcc', 'g++'
|
||||
|
||||
CC = find_executable(CC)
|
||||
CXX = find_executable(CXX)
|
||||
|
||||
"""
|
||||
On 64-bit architecture GNU Assembler crashes writing out an object, due to
|
||||
(probably) miscalculated structure sizes. There could be some other bugs
|
||||
@@ -225,10 +228,9 @@ def build():
|
||||
|
||||
ARCH = '-m32' if platform.machine() == 'x86_64' else ''
|
||||
|
||||
environ['CC'] = ' '.join([find_executable(CC), ARCH])
|
||||
environ['CXX'] = ' '.join([find_executable(CXX), ARCH])
|
||||
|
||||
environ['PATH'] = ":".join([path.join('{target}', 'bin'),
|
||||
environ['CC'] = CC + ' ' + ARCH
|
||||
environ['CXX'] = CXX + ' ' + ARCH
|
||||
environ['PATH'] = ':'.join([path.join('{target}', 'bin'),
|
||||
path.join('{host}', 'bin'),
|
||||
environ['PATH']])
|
||||
|
||||
@@ -248,12 +250,12 @@ def build():
|
||||
require_header('ncurses.h', 'c', 'libncurses-dev package missing')
|
||||
|
||||
py_ver = 'python%d.%d' % (sys.version_info.major, sys.version_info.minor)
|
||||
with env(CC=CC, CXX=CXX):
|
||||
require_header(path.join(py_ver, 'Python.h'), 'c',
|
||||
'python-dev package missing')
|
||||
|
||||
require_header(path.join(py_ver, 'Python.h'), 'c',
|
||||
'python-dev package missing')
|
||||
|
||||
unpack('python-lha', work_dir='{build}')
|
||||
python_setup('python-lha')
|
||||
unpack('python-lha', work_dir='{build}')
|
||||
python_setup('python-lha')
|
||||
|
||||
unpack('{m4}')
|
||||
configure('{m4}', '--prefix={host}')
|
||||
|
||||
Reference in New Issue
Block a user