glib从github下载源码https://github.com/GNOME/glib
首先运行autogen.sh文件,自动生成编译配置文件,运行中会提醒一些依赖包的安装
(1)gtk-doc,我选择安装gtk-doc-tools: sudo apt-get install gtk-doc-tools
(2)zlib,安装zlib1g-dev
(3)libffi,安装libffi6-dev
(4)libmount,安装libmount-dev
(5)libpcre,安装libpcre3-dev
再运行make & make install
原文链接:https://www.f2er.com/ubuntu/353942.html