1

我正在尝试在 jaibroken iPad 3 上的 iOS 6.1 上安装本机 NodeJS。我已经安装了 apt、自定义 python 2.7.3、GNU C 编译器(带有第三方 libgcc)、修改了 nodejs ./configure 以使用 gcc,但在配置过程中有一些问题:

#check if we have lastest python
ipad:/var/mobile/node-v0.8.18 root# python
Python 2.7.3 (default, Aug 11 2012, 10:54:38)
[GCC 4.2.1 Compatible Apple Clang 3.0 (tags/Apple/clang-211.11)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> exit()

#check if we have working gcc
ipad:/var/mobile/node-v0.8.18 root# gcc
gcc: no input files
root@localhost's password:

ipad:~ root# cd /var/mobile/node-v0.8.18
ipad:/var/mobile/node-v0.8.18 root# ./configure
{ 'target_defaults': { 'cflags': [],
                       'default_configuration': 'Release',
                       'defines': [],
                       'include_dirs': [],
                       'libraries': []},
  'variables': { 'armv7': 0,
                 'clang': 0,
                 'gcc_version': 42,
                 'host_arch': 'arm',
                 'node_install_npm': 'true',
                 'node_install_waf': 'true',
                 'node_prefix': '',
                 'node_shared_openssl': 'false',
                 'node_shared_v8': 'false',
                 'node_shared_zlib': 'false',
                 'node_tag': '',
                 'node_unsafe_optimizations': 0,
                 'node_use_dtrace': 'false',
                 'node_use_etw': 'false',
                 'node_use_openssl': 'true',
                 'target_arch': 'arm',
                 'v8_no_strict_aliasing': 1,
                 'v8_use_arm_eabi_hardfloat': 'false',
                 'v8_use_snapshot': 'true'}}
creating  ./config.gypi
creating  ./config.mk
Traceback (most recent call last):
  File "tools/gyp_node", line 58, in <module>
    run_gyp(gyp_args)
  File "tools/gyp_node", line 18, in run_gyp
    rc = gyp.main(args)
  File "./tools/gyp/pylib/gyp/__init__.py", line 511, in main
    return gyp_main(args)
  File "./tools/gyp/pylib/gyp/__init__.py", line 503, in gyp_main
    generator.GenerateOutput(flat_list, targets, data, params)
  File "./tools/gyp/pylib/gyp/generator/make.py", line 2095, in GenerateOutput
    part_of_all=qualified_target in needed_targets)
  File "./tools/gyp/pylib/gyp/generator/make.py", line 764, in Write
    self.Pchify))
  File "./tools/gyp/pylib/gyp/generator/make.py", line 1137, in WriteSources
    cflags = self.xcode_settings.GetCflags(configname)
  File "./tools/gyp/pylib/gyp/xcode_emulation.py", line 260, in GetCflags
    sdk_root = self._SdkPath()
  File "./tools/gyp/pylib/gyp/xcode_emulation.py", line 247, in _SdkPath
    return os.path.join(self._GetSdkBaseDir(),
  File "./tools/gyp/pylib/gyp/xcode_emulation.py", line 230, in _GetSdkBaseDir
    stderr=subprocess.STDOUT)
  File "/usr/lib/python2.7/subprocess.py", line 679, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/subprocess.py", line 1249, in _execute_child
    raise child_exception
OSError: [Errno 2] No such file or directory

我必须解决各种问题:

  • 缺少 python 构建要素
  • ./configure 仍然尝试使用 xcode 来处理我指定使用 gcc 的面部之外的东西:

    CC = os.environ.get('CC', 'cc')

至:

CC = os.environ.get('GCC', 'gcc')

然后我得到列出的错误。有什么建议么?谢谢!

4

0 回答 0