Sorry, your browser cannot access this site
This page requires browser support (enable) JavaScript
Learn more >

man page: https://man7.org/linux/man-pages/man2/open.2.html const char* file = "test_file.txt"; int pfd = open(file, O_WRONLY | O_CREAT | O_APPEND, 0777); O_WRONLY:只写O_CREAT:如果不存在则创建O_...

重定向https://stackoverflow.com/questions/47719965/how-to-redirect-stdout-to-a-file-and-then-restore-stdout-back 举例#include <iostream> #include <unistd.h> #include <fcntl.h> using na...

参考教程https://terminalroot.com/how-to-hide-input-via-cli-with-cpp/?ref=morioh.com&utm_source=morioh.com man信息#include <termios.h>https://pubs.opengroup.org/onlinepubs/7908799/xsh/termios.h....

自动补全,添加历史https://blog.51cto.com/u_3078781/3287204 自定义换行符https://www.igiftidea.com/article/12962763210.html 官方文档https://web.mit.edu/gnu/doc/html/rlman_2.html 快捷键使用(该库支持的)https://flyyang.me/2017/05/0...

本例中,下载源码到$HOME/built/目录下,安装到$HOME/local/gcc-9.4.0目录下 1. 获取源码在预计放源码的目录下,比如$HOME/built/ wget -c http://ftp.gnu.org/gnu/gcc/gcc-9.4.0/gcc-9.4.0.tar.gz tar -zxvf gcc-9.4.0.tar.gz cd gcc-9.4.0 2. 下载依赖g...

1. 获取源码wget -c --no-check-certificate http://sourceforge.net/projects/boost/files/boost/1.56.0/boost_1_56_0.tar.gz #下载源码 tar -xzvf boost_1_56_0.tar.gz #解压源码 cd boost_1_56_0 #进入源码目录 2. 修改bootstrap....

关注报错信息(搜索报错号) -rdynamic -g 编译,直接gdb运行(-rdynamic可以方便监控可能的段错误) 报错型bug调试建议:bt,从最靠近栈顶你写的函数,l那个函数和上一层函数,看p info这个函数的参数对不对(如果不好p info又没有写打印代码的话,先改源码在这个函数里面刚入口的地方加打印,然后r)不断向栈底看,直到参数没有问题的函数(就是它调用接下来的函数...

设置环境变量先学习下如何设置环境变量 To make the variable settings effect for each bash shell, put the exporting command to your ~/.bashrc, the individual per-interactive-shell startup file. bash中用于设置环境变量的语法如下 expor...

strace <a.out>

vscode阅读linux源码方法一 一站式配置vscode目前存在的问题:仍然有一些红线报错,但是不影响跳转定义 vscode 安装插件 Remote-SSH:本机安装 C/C++ 插件:remote安装(在remote安装插件的方法:先Remote-SSH连接上remote) 编译内核源码[编译内核(简单版)](# 编译内核(简单版)) 获取.vscode和生成compile...