【转】stropts.h: No such file or directory – How to Fix
2014-06-26 20:54
465 查看
原文地址:stropts.h: No such file or directory – How to Fix 作者:xjc2694
It is a known issue that modern Linux systems are missing stropts.h file. You will probably have some problems when trying to compile software like pppd, pptp, gftp, etc from sources. Seems to be a strange thing, as you won’t get any errors in previous versions of Linux. Most recent versions of Fedora don’t contain this file, that’s why we need to know what to do if software compilation fails because of missing stropts.h.
Let’s determine when we need to have this file on our machine.When we’re compiling any “old” package from sources, we may receive the following error:
What could be the reason and why isn’t this file included into our Linux distribution?This error means that your system doesn’t support STREAMS.
Linux doesn’t support STREAMS (many years ago it was available as a third party module, but it hasn’t worked for years). stropts.h is part of a POSIX XSR option, which is not supported in modern Linux distributions. Do we really need it in Linux?
This means that software you’re trying to compile, will not use the functions listed understropts.h as they’re not supported by the operating system. So we will do a simple trick that will let you to compile your software without these functions.
Since the stropts.h is required for a successful compilation, the most simple way to solve the issue is to create a blank file named stropts.h under /usr/include. You may want to put any comments there, this way you won’t forget what was the reason to create this file.
This simple trick will help you to compile pptp (1.7.2), pppd (2.4.5), and I think that the list will be much bigger. That was just my experience, but the sense remains the same: you need this file for a successful compilation. Just create it and have fun!
It is a known issue that modern Linux systems are missing stropts.h file. You will probably have some problems when trying to compile software like pppd, pptp, gftp, etc from sources. Seems to be a strange thing, as you won’t get any errors in previous versions of Linux. Most recent versions of Fedora don’t contain this file, that’s why we need to know what to do if software compilation fails because of missing stropts.h.
Let’s determine when we need to have this file on our machine.When we’re compiling any “old” package from sources, we may receive the following error:
What could be the reason and why isn’t this file included into our Linux distribution?This error means that your system doesn’t support STREAMS.
Linux doesn’t support STREAMS (many years ago it was available as a third party module, but it hasn’t worked for years). stropts.h is part of a POSIX XSR option, which is not supported in modern Linux distributions. Do we really need it in Linux?
This means that software you’re trying to compile, will not use the functions listed understropts.h as they’re not supported by the operating system. So we will do a simple trick that will let you to compile your software without these functions.
Since the stropts.h is required for a successful compilation, the most simple way to solve the issue is to create a blank file named stropts.h under /usr/include. You may want to put any comments there, this way you won’t forget what was the reason to create this file.
This simple trick will help you to compile pptp (1.7.2), pppd (2.4.5), and I think that the list will be much bigger. That was just my experience, but the sense remains the same: you need this file for a successful compilation. Just create it and have fun!
相关文章推荐
- stropts.h: No such file or directory – How to Fix
- [linux0001]How to fix /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory
- apt-get install python2.6-dev to fix "Python.h: No such file or directory"
- Fix “Unit iptables.service failed to load: No such file or directory” Error In CentOS7
- Fix “gcc: error trying to exec ‘cc1plus’: execvp: No such file or directory” in Fedora
- How to solve DevStack error “Exception Value: /usr/bin/env: node: No such file or directory”
- 真机调试时,遇到Unable to open log device ‘/dev/log/main’: No such file or directory
- 在Ubuntu安装完成后更改默认的语言LANG,出现Cannot set LC_CTYPE to default locale: No such file or directory错误的解决办法
- sphinx启动searchd进程出现search error failed to open No such file or directory
- Unable to open log device ‘/dev/log/main’: No such file or directory
- 解决Cannot set LC_CTYPE to default locale: No such file or directory
- Unable to open log device ‘/dev/log/main’: No such file or directory
- QT:make: Nothing to be done for `first'和error:QtSql:No such file or directory
- gcc: error trying to exec 'cc1plus': execvp: No such file or directory
- arm-eabi-gcc: error trying to exec 'cc1': execvp: No such file or directory 问题的解决
- xcode error failed to launch no such file or directory
- Unable to open log device ‘/dev/log/main’: No such file or directory
- arm-eabi-gcc: error trying to exec 'cc1': execvp: No such file or directory
- postfix过滤器名称不一致导致postfix/qmg:warning: connect to transport xxxx: No such file or directory
- Unable to open log device ‘/dev/log/main’: No such file or directory