我有一个非常大的“老”(形成我作为一个新毕业的)客户服务器项目。客户端是用于Windows的c ++,我设法编译它,但服务器在Linux上,这是一个痛苦,因为我不知道Linux编程。我试图让它在Ubuntu 14.04中运行
我收到此错误
checking for db_new in -ldb_psql... no
configure: error: db_psql missing; install extc
所以我搜索了他们提供的文件夹,并在一个包含configure.in文件的文件夹中找到了一些名为db_psql的文件。我在那里使用了终端并使用了命令
autoreconf -fis
给了我这个:
aclocal: warning: autoconf input should be named 'configure.ac', not 'configure.in'
libtoolize: putting auxiliary files in `.'.
libtoolize: linking file `./ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'.
libtoolize: linking file `m4/libtool.m4'
libtoolize: linking file `m4/ltoptions.m4'
libtoolize: linking file `m4/ltsugar.m4'
libtoolize: linking file `m4/ltversion.m4'
libtoolize: linking file `m4/lt~obsolete.m4'
libtoolize: Consider adding `-I m4' to ACLOCAL_AMFLAGS in Makefile.am.
aclocal: warning: autoconf input should be named 'configure.ac', not 'configure.in'
automake: warning: autoconf input should be named 'configure.ac', not 'configure.in'
automake: warning: autoconf input should be named 'configure.ac', not 'configure.in'
然后我使用命令
./configure
但这给了我两个错误,说缺少其他包,我安装它们,然后它说
checking for ZLB_Compress in -lzlib... no
configure: error: zlib missing
我被困在这里。似乎没什么用。我甚至在Ubuntu软件中心搜索“zlib”并在那里安装了所有东西(我安装了zlib1g-dev和许多其他人)。我使用了--with-zlib-dir = / usr
我在configure.in
中有这段代码AC_CHECK_LIB([zlib], [ZLB_Compress],
[AMADEUS_LIBS="-lzlib $AMADEUS_LIBS"],
[AC_MSG_ERROR([zlib missing])])
和配置中的这个
#ifdef __cplusplus
extern "C"
#endif
char ZLB_Compress ();
int
main ()
{
return ZLB_Compress ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_zlib_ZLB_Compress=yes
else
ac_cv_lib_zlib_ZLB_Compress=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_zlib_ZLB_Compress" >&5
$as_echo "$ac_cv_lib_zlib_ZLB_Compress" >&6; }
if test "x$ac_cv_lib_zlib_ZLB_Compress" = xyes; then :
AMADEUS_LIBS="-lzlib $AMADEUS_LIBS"
else
as_fn_error $? "zlib missing" "$LINENO" 5
fi