写功能unistd.h中需要在Unix上,有关Windows呢? [英] write function requires unistd.h on Unix, what about windows?

查看:239
本文介绍了写功能unistd.h中需要在Unix上,有关Windows呢?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经从Linux计算机变成一个窗口和我在遇到麻烦编译我的code,因为这两个操作系统并不共享相同的头文件。

I've changed from a linux computer to a windows and I'm having trouble compiling my code because these two OS don't share the same header files.

由于unistd.h中不包含明显,视觉C不知道是什么阅读()的write()的close() socklen_t的() bzero()功能。谁能帮我这个?

Since the unistd.h is not obviously included, Visual C doesn't know what read(), write(), close(), socklen_t() and bzero()functions are. Can anyone help me with this?

我GOOGLE了这一点:<一href=\"http://stackoverflow.com/questions/341817/is-there-a-replacement-for-unistd-h-for-windows-visual-c\">is有没有一个unistd.h中替代Windows(的Visual C)?

I've googled this: is there a replacement for unistd.h for Windows (Visual C)?

我不知道如何unistd.h中的作品,我也不知道该怎么code我自己。可有人请联系我一个?

I have no idea how unistd.h works, nor do I know how to code my own. Can someone please link me to one?

推荐答案

您最好的选择是使用 MinGW的编译程序,其中包括(除其他事项外)海湾合作委员会(和它的头)。尝试安装了,然后编译程序,看看是否一切正常确定。

Your best bet is to use MinGW to compile the program, which includes (among other things) GCC (and its headers). Try installing that and then compiling your program and see if everything works OK.

这篇关于写功能unistd.h中需要在Unix上,有关Windows呢?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆