F_SETPIPE_SZ undeclared

爱⌒轻易说出口 提交于 2019-11-29 11:18:18
Marko

So here's the solution, thanks to Chrono Kitsune:

Put

#define _GNU_SOURCE

before any includes.

You should also pay attention to Chrono Kitsune's other comment.

F_SETPIPE_SZ/F_GETPIPE_SZ are relatively recent. Older kernels (e.g. 2.6.32 as used in RHEL6) don't have them. If you look in /usr/include/linux/fcntl.h and these constants aren't defined, then this API isn't going to work and you'll have to find some way to bypass it in whatever you're building.

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