Xcode 编译运行旧项目报错解决之路
运行几年前做的项目,发现各种编译报错,一个一个解决记录下:
1、Xcode(Xcode9)编译运行报错,但是在 issue navigatior 栏看不到错误信息;
解决方案:在 show report navigator 栏查看编译错误信息:
Showing All Messages
The operation couldn’t be completed. Unable to log in with account '**@**.com'. (The login details for account '**@**.com' were rejected.)
根据错误信息显示,说这个账户失效了(之前公司的Apple ID),需要在偏好设置中移除相应账户即可。
继续编译,下一个报错信息:
2、error: implicit declaration of function 'ether_ntoa' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
strcpy(temp, (char *)ether_ntoa(LLADDR(sdl)));
解决方案:找到错误位置,引用类库:
导入这三个头文件即可,
#include <sys/types.h>
#include <sys/socket.h>
#include <net/ethernet.h> 然后上面那行代码会有一个警告:"Incompatible pointer types passing 'caddr_t' (aka 'char *') to parameter of type 'const struct ether_addr *'" ;
可以在LLADDR的前面加上(const struct ether_addr *) 也就是这样:
strcpy(temp, (char *)ether_ntoa((const struct ether_addr *)LLADDR(sdl)));
这样就没有警告了。
3、.xib: Compiling IB documents for earlier than iOS 7 is no longer supported. 工程是14年之前 Xcode创建的,升级到Xcode9后报错。
解决方案:将builds For 改成 iOS10之后就可以了。
解决完成,大功告成,编译运行成功。接下来就是各种适配问题了 。
Xcode 编译运行旧项目报错解决之路的更多相关文章
- 运行springboot项目报错:Field userMapper in XX required a bean of type 'xx' that could not be found.
运行springboot项目报错: *************************** APPLICATION FAILED TO START ************************** ...
- Android——eclipse下运行android项目报错 Conversion to Dalvik format failed with error 1解决
在eclipse中导入android项目,项目正常没有任何错误,但是运行时候会报错,(clean什么的都没用了.....)如图: 百度大神大多说是jdk的问题,解决: 右键项目-Properties如 ...
- quick3.3final版创建项目报错解决
PHP Notice: Undefined index: QUICK_V3_ROOT in 405,469,497,520,551这5行代码都访问了一个环境变量$_ENV['QUICK_V3_ROO ...
- Mac运行React Native安卓项目报错解决
传送门参考: 下面的这个链接很详细了,一步一步就好.... https://github.com/NARUTOyuyang/React-Native 然而在运行react-native run-and ...
- npm run dev运行Vue项目报错:Node Sass does not yet support your current environment
导入Vue项目后,#npm run dev 报错: error in ./src/pages/hello.vue Module build failed: Error: Node Sass does ...
- 运行springboot项目报错 Error running 'ResourceApplication': Command line is too long. Shorten comma
方法1 IDEA 运行报错:Error running '***': Command line is too long 技术标签: IDEA Error running 'Test': Com ...
- IDEA新建SpringMVC项目报错解决办法
网页运行的错误: HTTP Status 500 - Handler processing failed; nested exception is java.lang.NoClassDefFoundE ...
- 运行gulp项目报错:AssertionError: Task function must be specified。
一.问题描述: gulp项目在本地windows 10机器上跑没有任何问题,但是放在centos 7虚拟机上跑报错:AssertionError: Task function must be spec ...
- 【原创】Eclipse导入Android项目报错解决
1.点击报错的项目--->右键--->Properties--->选择Android--->将Project Build Target选择其一勾上-->Is Librar ...
随机推荐
- DTU DeepLearning: exercise 7
torch activation functions: sigmoid, relu, tanh, softplus. https://morvanzhou.github.io/tutorials/ma ...
- (转)hashmap hashtable 的区别 Hash table 内部的数据结构
转自:http://www.cnblogs.com/carbs/archive/2012/07/04/2576995.html Hashtable 和 HashMap 做为 Map 的基本特性 两者都 ...
- AcWing 793. 高精度乘法
https://www.acwing.com/problem/content/795/ #include<bits/stdc++.h> using namespace std; //A*b ...
- find & grep 总 结
前言 关于本文 总 结 了 find.grep常 规 用 法,正 则 表 达 式,find与 grep合 用 以 及 自 定 义 搜 索 函 数 等 什么是find和grep find 和 grep ...
- 题解【Codeforces438D】The Child and Sequence
题目描述 At the children's day, the child came to Picks's house, and messed his house up. Picks was angr ...
- C语言是菜鸟和大神的分水岭
作为一门古老的编程语言,C语言已经坚挺了好几十年了,初学者从C语言入门,大学将C语言视为基础课程.不管别人如何抨击,如何唱衰,C语言就是屹立不倒:Java.C#.Python.PHP.Perl 等都有 ...
- 励志成为优产的母猪--------猜数游戏 ,历史记录,pickle保存,队列deque
# pickle 可以处理复杂的序列化语法.(例如自定义的类的方法,游戏的存档等),存档以文件的形式保存 参见 https://www.cnblogs.com/abobo/p/8080447.html ...
- bistoury建库建表(一)
bistoury DROP TABLE IF EXISTS bistoury_app; CREATE TABLE bistoury_app( id INT UNSIGNED auto_incremen ...
- C#常用的form窗体属性(最大化、最小化、窗体居中)
一.窗体居中 //窗体居中 this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; 二.去掉最小化.最大化 ...
- 网络常识---tracert
当打不开一个网页,可以是用如下命令查看请求的数据走到哪里了 在命令行中输入“tracert ”并在后面加入一个IP地址,可以查询从本机到该IP地址所在的电脑要经过的路由器及其IP地址