gpt4 book ai didi

autotools - 已定义库但没有规范名称

转载 作者:行者123 更新时间:2023-12-02 23:30:47 24 4
gpt4 key购买 nike

我正在尝试使用自动工具构建一个项目并收到此错误:

$ autoreconf --install
automake: warnings are treated as errors
src/Makefile.am:3: warning: variable 'librombrowser_a_LDFLAGS' is defined but no program or
src/Makefile.am:3: library has 'librombrowser_a' as canonical name (possible typo)
autoreconf: automake failed with exit status: 1

src/Makefile.am 如下:

noinst_LIBRARIES = librombrowser.a
librombrowser_a_CPPFLAGS = $(GTK_CFLAGS)
librombrowser_a_LDFLAGS = $(GTK_LIBS)
librombrowser_a_SOURCES = \
rombrowser-app.c \
rombrowser-app.h \
rombrowser-cmds-file.c \
rombrowser-cmds-help.c \
rombrowser-cmds.h \
rombrowser-dirs.c \
rombrowser-dirs.h \
rombrowser-settings.c \
rombrowser-settings.h

bin_PROGRAMS = rombrowser
rombrowser_SOURCES = rombrowser.c
rombrowser_LDADD = librombrowser

我没看出哪里出了问题。

最佳答案

_LDFLAGS 对静态库无效,仅对可执行文件或共享库有效。您可能需要 _LIBADD。在我看来,错误消息可以改进。

关于autotools - 已定义库但没有规范名称,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23575967/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com