操作
安装预构建二进制文件¶
您可能需要查看 openSUSE 构建服务仓库,我们有以下可用软件包:- CentOS 5
- Debian 7.0 (wheezy)
- Fedora 13
- Redhat RHEL 5
- openSUSE 11.1, 11.2, 11.3 和 Factory
- SUSE Linux Enterprise 11
- Ubuntu 9.10 (karmic), 10.04 (lucid)
- http://download.opensuse.org/repositories/server:/http/ (https://build.opensuse.org/project/show?project=server%3Ahttp)
- http://download.opensuse.org/repositories/home:/stbuehler:/lighttpd2/ (https://build.opensuse.org/project/show?project=home%3Astbuehler%3Alighttpd2)
您还可以使用“nightlies”仓库;我们的 buildbot 会在每次 git 提交后自动更新它(它可能依赖于 home:stbuehler:lighttpd2 的软件包) - Debian 构建版本可在 https://debian.lighttpd.net/ 获取
从源代码安装¶
依赖项¶
- C 编译器 :)
- pkg-config - 查找许多库的最佳方式
- meson
- libev
- libidn
- ragel
- glib2.0 (>= 2.16)
- lua 5.1 (可选) (强烈推荐) (必须是 lua 5.1;不能是其他 lua 版本)
- zlib1g (可选:用于 mod_deflate deflate/gzip 压缩)
- libbz2 (可选:用于 mod_deflate bzip2 压缩)
- libssl (可选:用于 ssl)
获取源代码¶
您可以检出我们的 git 源代码,或者从 https://download.lighttpd.net/lighttpd/snapshots-2.0.x/ 获取 distbuild tar 包
git checkout¶
- 首次:
git clone https://git.lighttpd.net/lighttpd/lighttpd2.git && cd lighttpd2
这会在您当前目录中创建一个名为 "lighttpd2" 的新目录,其中包含源代码。 - 更新:
git pull
如果您应用了自己的补丁,您可能需要使用git fetch; git rebase origin/master
来保留您的补丁,或者使用git fetch; git reset --hard origin/master
来使用我们当前的最新版本。
- lighttpd2-master.zip
- lighttpd2-master.tar.gz
它与 git checkout 相同(当然不包含 .git 目录),在这里也算作“git checkout” :)
这些 tar 包与 distbuild tar 包不同!
distbuild¶
像往常一样下载并解压:tar -xf https://download.lighttpd.net/lighttpd/snapshots-2.0.x/lighttpd-2.0.0-snap-XXX.tar.gz
配置 + 构建¶
meson setup --buildtype debugoptimized -Dbzip2=false --prefix /usr/local build cd build meson compile meson test
安装¶
meson install