./configure,语法错误:意外标记(lighttpd)

./configure,语法错误:意外标记(lighttpd)

我想构建 lighttpd 的修改版本。我按照这个教程:

下载并构建适用于 Lighttpd 的 H264 流模块(版本 2)

这是我到目前为止所做的:

apt get install lighttpd
apt get install automake autoconf libtool 
cd /var/tmp
wget http://h264.code-shop.com/download/lighttpd-1.4.18_mod_h264_streaming-2.2.9.tar.gz
tar -zxvf lighttpd-1.4.18_mod_h264_streaming-2.2.9.tar.gz
wget http://download.lighttpd.net/lighttpd/releases-1.4.x/lighttpd-1.4.28.tar.gz
tar ... 

将所有文件和数据复制到目录和 Makefile.am 后,我输入:

./autogen.sh


./autogen.sh: running `libtoolize --copy --force'
libtoolize: putting auxiliary files in `.'.
libtoolize: copying file `./ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'.
libtoolize: copying file `m4/libtool.m4'
libtoolize: copying file `m4/ltoptions.m4'
libtoolize: copying file `m4/ltsugar.m4'
libtoolize: copying file `m4/ltversion.m4'
libtoolize: copying file `m4/lt~obsolete.m4'
./autogen.sh: running `aclocal -I m4'
./autogen.sh: running `autoheader'
./autogen.sh: running `automake --add-missing --copy --foreign'
Makefile.am:8: lib_LTLIBRARIES must be set with `=' before using `+='

./configure --enable-maintainer-mode --prefix=${HOME}/test/lighttpd-1.4.28

控制台返回:

    ...
        checking for pkg-config... no
        checking for libev support... ./configure: line 12184: syntax error near unexpected token `LIBEV,'
./configure: line 12184: `      PKG_CHECK_MODULES(LIBEV, libev, ,'
root@foo...

有些人通过安装“pkg-config”解决了这个问题。我安装了这个包,但仍然无法运行配置。

编辑:这是这一行配置文件的来源

LIBEV_CFLAGS=""
LIBEV_LIBS=""

    if test "$WITH_LIBEV" != "no"; then
            PKG_CHECK_MODULES(LIBEV, libev, ,
                    dnl no pkg-config for libev, searching manually:

                    if test "$WITH_LIBEV" != "yes"; then
                            LIBEV_CFLAGS="-I$WITH_LIBEV/include"
                            LIBEV_LIBS="-L$WITH_LIBEV/lib -lev"
  else

          AC_CHECK_HEADERS([ev.h],[
                                AC_CHECK_LIB([ev], [ev_loop], [
                                                LIBEV_CFLAGS=""
                                                LIBEV_LIBS="-lev"
                                        ],[
                                        AC_MSG_ERROR([libev not found])
                                        ]
                                )],[
                                        AC_MSG_ERROR([libev not found])
                                ]
                        )
                fi
        )

答案1

lighttpd-1.4.28 不是最新的。您可能正在遭受lighttpd 错误 #2300 lighttpd-1.x 未检测到 Libev-4.0,此问题已在 1.4.29 中修复(从 2.0 向后移植)。

否则,请尝试:

  • 仔细检查您的依赖项(特别需要的版本autoconf等),如 h264.code-shop.com 说明中记录的那样
  • 确保您可以lighttpd从源代码构建没有h264 模块,让您一次可以解决一个问题

相关内容