疑难杂症汇总

linux安装32位库

sudo apt-get install libc6-dev-i386
sudo apt-get install lib32z1

带gdb调试bochs

安装相关依赖:

sudo apt install build-essential libx11-dev libxrandr-dev libsdl1.2-dev vgabios bximage

安装脚本:进入bochs目录执行即可

#!/bin/bash
./configure --enable-debugger --enable-readline
make -j8
sudo make install
sudo mv `which bochs` `which bochs`dbg
./configure --enable-gdb-stub
make -j8
sudo make install

bochsrc脚本配置:

# enable gdb debug
gdbstub: enabled = 1, port = 1234, text_base = 0, data_base = 0, bss_base = 0

dpkg锁错误

错误提示:

E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?

解决方案:依次执行如下命令

sudo rm /var/lib/apt/lists/lock
sudo rm /var/cache/apt/archives/lock
sudo rm /var/lib/dpkg/lock*
sudo dpkg --configure -a

你可能感兴趣的:(疑难杂症)