Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/c/64.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C termiox.h的Linux等价物是什么?_C_Linux_Rhel - Fatal编程技术网

C termiox.h的Linux等价物是什么?

C termiox.h的Linux等价物是什么?,c,linux,rhel,C,Linux,Rhel,我有一个古老的调制解调器接口库,它最初是为Solaris和Linux制作的,我正在尝试看看它是否适用于Linux 在Linux上编译时,我看到: #if ! defined(WIN32) #include <string.h> #include <fcntl.h> #include <sys/stat.h> #include <sys/types.h> #include <stdlib.h> #include <stdio.h&

我有一个古老的调制解调器接口库,它最初是为Solaris和Linux制作的,我正在尝试看看它是否适用于Linux

在Linux上编译时,我看到:

#if ! defined(WIN32)

#include <string.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <stdlib.h>
#include <stdio.h>
#include <unistd.h>
#include <sys/ioctl.h>
#include <sys/time.h>
#include <termios.h>
#include <sys/termiox.h>
#如果!已定义(WIN32)
#包括
#包括
#包括
#包括
#包括
#包括
#包括
#包括
#包括
#包括
#包括
它似乎无法找到termiox.h的位置,当我搜索它时,它只显示termios.h的结果

我不能简单地删除引用,因为有很多人打电话给它

有人知道Linux下termiox调用是在哪里定义的吗

操作系统版本是RHEL 5.5

引用termiox库的代码只是表示忽略termiox选项:

 /home/local/NT/jayanthv/8.7/CallBur/lib/unix.c(556): error: struct "<unnamed>" has no field "termiox"
 if( modem_opt_ignore_termiox == No && ioctl( modem_handle, TCSETX, &mattr_current.termiox ) < 0 )
/home/local/NT/jayanthv/8.7/CallBur/lib/unix.c(556):错误:struct“”没有字段“termiox”
if(modem_opt_ignore_termiox==No&&ioctl(modem_handle、TCSETX和mattr_current.termiox)<0)

我是否应该继续添加“如果”!围绕代码定义了()吗?

不要拿古语开玩笑。它的底部写着:

提供termiox(7I)系统调用是为了与兼容 不鼓励以前的版本及其使用。相反,termio(7I) 建议进行系统调用

该手册页的日期为1990年。从那时起:

termio.h

此头文件已过时,已被POSIX标准的一部分
termios.h
替换。这两个头文件非常相似。但是,
termios.h
不包含与
termio.h
相同的头文件。因此,您应该确保直接查看
termios.h
标题,以确保它包含应用程序所需的所有内容


所以termiox被termio所取代,termio被termios所取代。

它似乎来自AIX——您需要在termiox.h中定义哪些调用/结构?也就是说,在没有include的情况下进行编译时会出现什么错误?编辑:我们的SunOS服务器似乎也有termiox。我已经用信息更新了这个问题,你认为忽略调用termiox的代码是明智的吗?很难说——我个人会继续尝试:)你发布的ioctl调用基本上将modem_handle的流量控制设置设置为mattr_current.termiox中的设置。mattr_current.termiox是如何初始化的?顺便说一句,这里是SunOS termiox手册页:我刚刚删除了对termiox的所有引用