在上一节说了如何对不同版本gcc进行适配。
这一节主要是外部静态库编译的配置记录。
以下的库都是编译32位的版本,如果需要64位只需要把-m32去掉即可
udev
仓库地址:https://git.kernel.org/pub/scm/linux/hotplug/udev.git
1 | wget https://git.kernel.org/pub/scm/linux/hotplug/udev.git/snapshot/udev-173.tar.gz |
x264
官网:https://www.videolan.org/developers/x264.html
1 | wget http://download.videolan.org/pub/videolan/x264/snapshots/last_stable_x264.tar.bz2 |
值得注意的是,x264在config里并没有提供编译32位的选项。如果本机是64,但是要编译32位的x264。需要手动改写configure脚本
在 706 行,进行位数判断时,加入host_cpu=i386
强行使用32位编译
SDL2
1 | cd |
SDL_Image2
1 | wget https://www.libsdl.org/projects/SDL_image/release/SDL2_image-2.0.3.zip |
libpng
1 | wget |
libxcb
1 | wget https://xcb.freedesktop.org/dist/libxcb-1.13.tar.gz |
libXdmcp
X11相关库的地址: https://www.x.org/releases/individual/lib/
1 | wget https://www.x.org/releases/individual/lib/libXdmcp-1.1.1.tar.gz |
libXau
1 | wget https://www.x.org/releases/individual/lib/libXau-1.0.7.tar.gz |
libX11
1 | wget https://www.x.org/releases/individual/lib/libX11-1.6.5.tar.gz |
libXi
1 | wget https://www.x.org/releases/individual/lib/libXi-1.7.8.tar.gz |
libXest
1 | wget https://www.x.org/releases/individual/lib/libXext-1.3.3.tar.gz |
libXtst
1 | wget https://www.x.org/releases/individual/lib/libXtst-1.2.3.tar.gz |
libz
1 | wget https://zlib.net/zlib-1.2.11.tar.gz |