- 主题:求救,sendmail_c出错,rh9.0下
[Compiling bbs_sendmail.c]
bbs_sendmail.c: In function `bbs_sendmail':
bbs_sendmail.c:712: `OWNSENDMAIL' undeclared (first
use in this function)
bbs_sendmail.c:712: (Each undeclared identifier is
reported only once
bbs_sendmail.c:712: for each function it appears in
.)
make[2]: *** [bbs_sendmail.lo] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
--
FROM 166.111.198.*
没定义这个变量。
我在bbs_sendmail.c里面加了一个定义:char OWNSENDMAIL就好了。
【 在 tphs (En-CS-Maths) 的大作中提到: 】
: [Compiling bbs_sendmail.c]
: bbs_sendmail.c: In function `bbs_sendmail':
: bbs_sendmail.c:712: `OWNSENDMAIL' undeclared (first
: ...................
--
FROM 202.115.68.*
这样做不好,configure 脚本应该会自动检测 sendmail,
然后在 config.h 里面添加宏定义:
#define OWNSENDMAIL "/usr/.../sendmail"
【 在 xiaobug (虫子) 的大作中提到: 】
: 没定义这个变量。
: 我在bbs_sendmail.c里面加了一个定义:char OWNSENDMAIL就好了。
--
FROM 166.111.160.*
在config.h中:
我添加了:
----------------------------------------------------------
........
/* Define like PROTOTYPES; this can be used by system headers. */
#define __PROTOTYPES 1
/* Define to empty if `const' does not conform to ANSI C. */
/* #undef const */
/* Define as `__inline' if that's what the C compiler calls it, or to nothing
if it is not supported. */
/* #undef inline */
/* Define to rpl_malloc if the replacement function should be used. */
/* #undef malloc */
/* Define to `int' if <sys/types.h> does not define. */
/* #undef mode_t */
/* Define to `long' if <sys/types.h> does not define. */
/* #undef off_t */
/* Define to `int' if <sys/types.h> does not define. */
/* #undef pid_t */
/* Define to `unsigned' if <sys/types.h> does not define. */
/* #undef size_t */
/* Define as `fork' if `vfork' does not work. */
/* #undef vfork */
#define OWNSENDMAIL "/usr/.../sendmail"
------------------------------------------
最后一句即是,make后提示:
--------------------------------------------
[Compiling bbs_sendmail.c]
bbs_sendmail.c: In function `bbs_sendmail':
bbs_sendmail.c:712: `OWNSENDMAIL' undeclared (first use in this function)
bbs_sendmail.c:712: (Each undeclared identifier is reported only once
bbs_sendmail.c:712: for each function it appears in.)
make[2]: *** [bbs_sendmail.lo] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
[root@localhost smthbbs-1.2.1]#
-------------------------------------------
是不是"/usr/.../sendmail"中"..."要改成别的路径才行?如果是要改成什么讷?
【 在 flyriver (江~~每天进步一点点) 的大作中提到: 】
: 这样做不好,configure 脚本应该会自动检测 sendmail,
: 然后在 config.h 里面添加宏定义:
: #define OWNSENDMAIL "/usr/.../sendmail"
--
修改:foxle FROM 211.157.101.*
FROM 211.157.101.*
这个问题已经确认是 1.2.1 的 configure 脚本的一个 bug,CVS 上的文件已经得到修正。
对于 1.2.1,如果碰到这个问题,一个解决办法是在 configure 时添加
--without-libesmtp 参数,如果使用 contrib/build-RH9.sh 的话,
在这个文件的最后那个 configure 命令参数 --with-mysql 之后加上
--without-libesmtp。
【 在 tphs (En-CS-Maths) 的大作中提到: 】
: [Compiling bbs_sendmail.c]
: bbs_sendmail.c: In function `bbs_sendmail':
: bbs_sendmail.c:712: `OWNSENDMAIL' undeclared (first
: ...................
--
FROM 221.216.157.*