React Native 'config.h' file not found 问题、 'glog/logging.h' file not found 问题、configure: error: C compiler cannot create executables问题解决过程记录
1、在github 上面 git clone 一个RN 项目代码,npm install (yarn)后,准备运行iOS工程,发现'config.h' file not found ,恶心!!!
百度发现:这个是常见错误,只需要在项目根目录下(里面包含node_modules文件夹)运行以下命令(下面的两行同时复制,终端运行)即可解决:
cd node_modules/react-native/third-party/glog-0.3.4
../../scripts/ios-configure-glog.sh
注意:具体的版本号要根据报错的提示来定
2、20190225 发现 'glog/logging.h' file not found 的问题(RN 版本 0.58),解决方式(参照上面的,复制下面2行,终端执行):
cd node_modules/react-native/third-party/glog-0.3.5
../../scripts/ios-configure-glog.sh
3、讨厌的错误,如下:
configure: error: C compiler cannot create executables
See `config.log' for more details
这个很是令人讨厌!!!出现的原因可能也不一致,下面列举不同时间出现的问题,解决方案和猜想。
20181123运行正常的项目,突然间就出现了config.h' file not found。按照上面的解决方式解决后,运行正常。第二天升级了mac 系统到macOS Mojave (版本10.14);Xcode 更新到Version 10.1 (10B61) 后,又出现了
configure: error: C compiler cannot create executables
See `config.log' for more details
当时百度上说是要安装 GCC 。就用:brew install gcc 安装了下最新版本的gcc 。但是安装完了之后,依然报如下错误(郁闷):
xcrun: error: SDK "iphoneos" cannot be located
xcrun: error: unable to lookup item 'Path' in SDK 'iphoneos'
configure: error: C compiler cannot create executables
See `config.log' for more details
最后有效解决方案:
打开xcode...,偏好设置 ,如下图,command line tools 要选中一个 (这个可能是当时安装了两个版本的XCODE,导致没有选择一个)。

20190313 发现glog/logging.h' file not found 问题后,按照上面20190225问题解决,却出现了 关键词如下的错误:
configure: error: C compiler cannot create executables
See `config.log' for more details
过程描述:前几天还是正常运行的,只是换了一个模拟器的机子,就出现了glog/logging.h' file not found ,按照上面的方式执行脚本,但是执行的过程中,出现了 configure: error: C compiler cannot create executables 问题。
解决方法及猜想: 1、glog/logging.h' file not found出现可能跟换模拟器有关(只是猜想)2、configure: error: C compiler cannot create executables 的出现可能跟刚才执行的另外一个RN项目有关,终端在开着另外一个RN项目的本地服务。解决方式:将终端关闭,再次运行项目,一切OK 。
React Native 'config.h' file not found 问题、 'glog/logging.h' file not found 问题、configure: error: C compiler cannot create executables问题解决过程记录的更多相关文章
- 安装RabbitMQ编译erlang时,checking for c compiler default output file name... configure:error:C compiler cannot create executables See 'config.log' for more details.
checking for c compiler default output file name... configure:error:C compiler cannot create executa ...
- 将React Native 集成进现有OC项目中(过程记录) 、jsCodeLocation 生成方式总结
将RN集成到现有OC项目应该是最常见的,特别是已经有OC项目的,不太可能会去专门搞个纯RN的项目.又因为RN不同版本,引用的依赖可能不尽相同,所以特别说明下,本文参考的文档是React Native ...
- Swift Modules for React Native
React Native is an Objective-C application framework that bridges JavaScript applications running in ...
- React Native纯干货总结
随着项目也渐渐到了尾声,之前的项目是mobile开发,采用的是React Native.为即将要开始做RN项目或者已经做过的小伙伴可以参考借鉴,也顺便自己做一下之前项目的总结. 文章比较长,可以选择自 ...
- React Native在window下的环境搭建(一)
React Native官方开发文档 以下是本人抄录的: 初次接触React Native感觉和React很像,却是有点类似,但不完全是,React Native有自己的组件对象,不过它也自定义的组件 ...
- 深入浅出React Native 1: 环境配置
该教程主要介绍如何用react native来开发iOS,所以首先,你需要有一台mac,当然黑苹果也是可以的~ 创建一个react native的项目只需要安装以下五个组件~~(但....坑爹的是,不 ...
- React Native iOS环境搭建
前段时间React Native for Android发布,感觉React Native会越来越多的公司开始研究.使用.所以周六也抽空搭建了iOS的开发环境,以便以后利用空闲的时间能够学习一下. 废 ...
- [书籍精读]《React Native精解与实战》精读笔记分享
写在前面 书籍介绍:本书由架构师撰写,包含ReactNative框架底层原理,以及与iOS.Android混合开发案例,精选了大量实例代码,方便读者快速学习.主要内容分为两大部分,第1部分" ...
- React Native新项目启动报错'React/RCTBridgeDelegate.h' file not found
React Native版本:0.60.4 解决方法: cd ios pod deintegrate pod install 然后重新启动就好了(示例页面变样了( ⊙ o ⊙ )) END------ ...
随机推荐
- November 09th, 2017 Week 45th Thursday
If we did all the things we are capable of, we would literally astound ourselves. 我们如果尽全力去完成我们能做到的事情 ...
- nginx 添加虚拟主机 支持php 伪静态
1添加虚拟主机 进入 /usr/local/nginx/conf/vhost 目录, 创建虚拟主机配置文件 demo.neoease.com.conf ({域名}.conf). 2. 打开配置文件, ...
- Linux平台安装Oracle11gR2数据库
1. 数据库安装先决条件 1.1 认证的操作系统检查确认 o RHEL4,OEL4 - update 7 or greater o RHEL5,OEL5 - 5.2 or greater o RHEL ...
- Codeforces Round #553 (Div. 2)B. Dima and a Bad XOR 思维构造+异或警告
题意: 给出一个矩阵n(<=500)*m(<=500)每一行任选一个数 异或在一起 求一个 异或在一起不为0 的每行的取值列号 思路: 异或的性质 交换律 x1^x2^x3==x3^x2 ...
- OpenCV——staturate_cast、掩模操作
saturate_cast<>()模板函数,用于溢出保护 //大致的原理如下 ) data=; elseif(data>) data=; 掩模操作:https://blog.csdn ...
- setattr
setatt r给对象的属性赋值,若属性不存在,先创建再赋值 用法 setattr(object, name, values) object -- 对象. name -- 字符串,对象属性. valu ...
- 理解JavaScript中的作用域链
理解了作用域链,闭包就不难理解了,所以本文主要谈一谈我对作用域链的理解. 关于JavaScript中变量的作用域,全局变量在程序中始终都有定义.局部变量在声明它的函数体内以及其内部所嵌套的函数内始 ...
- scp 免密登录ssh-copy-id 如何使用非22端口 + rsync 同步远程机器的文件到本地
其中:id_rsa为私钥文件,id_rsa.pub为公钥文件 ssh-copy-id -i ~/.ssh/id_rsa.pub "-p 2122 root@IP " 我的:s ...
- Kubernetes哪一点最打动你?或者,它发布过的哪一项特性让你认为最厉害?
kubernates 打动我的地方应该是他解决了docker 的一个痛点,各个docker之间的通信以及集成管理.因为这跟微服务很像,微服务之间也是需要通信和统一管理.知识总是相同的,在这里就体现出来 ...
- day66
今日内容: 1 orm介绍 1 tools--->Run manage.py Task python3 manage.py makemigrations 只需要敲命令:makem ...