Can libpcap be compiled for iPhone/armv6?

牧云@^-^@ 提交于 2019-12-01 12:55:52

pcap.c isn't the source to libpcap, it's one of the source files to libpcap. You'd have to compile all the source files and build them into a library.

Doing

CFLAGS="-I /Users/abnev/libpcap/include -arch armv6 -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS3.1.3.sdk" ./configure

might produce a Makefile that would cross-compile libpcap for iOS.

I presume you will be installing libpcap, or the application built using it, on a jailbroken iPhone, at least if you're going to be capturing packets, because you would need root access in order for libpcap to be able to open a BPF device in order to be able to capture.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!