我现在已经从源头上遵守了lighttpd

./configure --prefix=/home/lighttpd \
--without-pcre \
--without-zlib \
--without-bzip2

我还尝试了-enable static--disable shared选项,但是模块仍然从lib目录加载
我想用一个二进制文件编译所有lighttpd模块,而不是从lib目录加载,怎么做?

最佳答案

交叉发布到https://redmine.lighttpd.net/boards/3/topics/6615
Lighttpd可以使用SCons或make静态构建。简要地:
烤饼:
$scons-j 4 build_static=1 build_dynamic=0 prefix=/custom/inst/path安装
品牌:
#编辑src/Makefile.am,并在“if LIGHTTPD_STATIC”部分中,使用要包含在静态生成中的每个模块更新LIGHTTPD_SOURCES,或者只使用已经存在的整个列表
$LIGHTTPD_STATIC=yes./configure-C--enable STATIC=yes
$制造
https://redmine.lighttpd.net/boards/3/topics/5912中的更多详细信息
[编辑]要使用“make”静态构建,请使用lighttpd git master branch或lighttpd 1.4.40+

关于c - 如何静态编译lighttpd模块,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/37077497/

10-11 16:35