Linux
huanghxyz
这个作者很懒,什么都没留下…
展开
-
error: expected ')' before numeric constant
学习Linux C时遇到的问题,地址:https://akaedu.github.io/book/ch21s04.html 写一个assert函数/* main.c */#include "xassert.h"#include <stdio.h>#include <stdlib.h>int main(void){ assert(2>3)...原创 2019-02-15 16:35:24 · 7413 阅读 · 0 评论 -
int $0x80 段错误
《Linux C编程一站式学习》中第 18 章 x86汇编程序基础 1. 最简单的汇编程序.section .data # 全局变量区.section .text # 代码区.global _start # _start要被链接器用到,在目标文件的符号表中是全局符号_start:movl $1, %eax # _exit系统调用号为1movl $4, %ebx # ebx值传给_e...原创 2019-02-18 13:44:12 · 917 阅读 · 4 评论 -
Windows 搭建 Linux开发环境 mingw+msys
Windows 搭建 Linux开发环境1. mingwMinGW | Minimalist GNU for Windowshttp://www.mingw.org/安装包主页 https://osdn.net/projects/mingw/downloads/68260/mingw-get-setup.exe/下载地址:mingw-get-setup.exehttps...原创 2019-02-13 09:24:41 · 1061 阅读 · 0 评论 -
Windows 搭建 Linux开发环境 cygwin
主页:Cygwinhttps://cygwin.com/下载主页:Cygwin Installationhttps://cygwin.com/install.html下载地址:setup-x86.exehttps://cygwin.com/setup-x86.exe这似乎是个悖论,虽然有国内的镜像网站可以安装,但是又不提供安装程序文件setup-x86.exe,这个都下载不下来,...原创 2019-02-13 13:56:35 · 2219 阅读 · 0 评论 -
MinGW Cygwin 对比
字符编码cygmin支持中文ANSI 终端mintty (notepad++中设置ANSI,汉字显示正常;设置UTF-8,显示乱码) mingw输入我 显示\322 终端bashANSI 终端bash(notepad++中设置ANSI,汉字显示正常;设置UTF-8,显示乱码)另:1. mingw当前文件夹可以直接打开文件,不用添加“./”2. cygw...原创 2019-02-13 16:14:40 · 771 阅读 · 0 评论 -
readelf: Error: Not an ELF file - it has the wrong magic bytes at the start
Windows 下 MinGW Cygwin 下gcc编译$ gcc main.c stack.c -o main自动生成main.exe使用readelf查看报错$ readelf -a main.exereadelf: Error: Not an ELF file - it has the wrong magic bytes at the start分析:使用...原创 2019-02-19 13:37:06 · 5401 阅读 · 0 评论