Hi, all. I'm trying to compile OpenSSH-3.0.2p1 on a Linux libc5 system, and it fails when compiling packet.c with the following: gcc -g -O2 -Wall -Wpointer-arith -Wno-uninitialized -I. -I. -DETCDIR=\"/etc/ssh\" -D_PATH_SSH_PROGRAM=\"/usr/bin/ssh\" -D_PATH_SSH_ASKPASS_DEFAULT=\"/usr/libexec/ssh-askpass\" -D_PATH_SFTP_SERVER=\"/usr/libexec/sftp-server\" -D_PATH_SSH_PIDDIR=\"/var/run\" -DHAVE_CONFIG_H -c packet.c packet.c: In function `packet_set_interactive': packet.c:1211: `TCP_NODELAY' undeclared (first use in this function) packet.c:1211: (Each undeclared identifier is reported only once packet.c:1211: for each function it appears in.) The naive solution of adding: #include <linux/tcp.h> doesn't work: gcc -g -O2 -Wall -Wpointer-arith -Wno-uninitialized -I. -I. -DETCDIR=\"/etc/ssh\" -D_PATH_SSH_PROGRAM=\"/usr/bin/ssh\" -D_PATH_SSH_ASKPASS_DEFAULT=\"/usr/libexec/ssh-askpass\" -D_PATH_SFTP_SERVER=\"/usr/libexec/sftp-server\" -D_PATH_SSH_PIDDIR=\"/var/run\" -DHAVE_CONFIG_H -c packet.c In file included from packet.c:62: /usr/include/linux/tcp.h:23: redefinition of `struct tcphdr' so I fell back to adding the following: #define TCP_NODELAY 1 Brute force, but it works. Regards, Richard.... Permanent: rgooch at atnf.csiro.au Current: rgooch at ras.ucalgary.ca
On Mon, 24 Dec 2001, Richard Gooch wrote:> Hi, all. I'm trying to compile OpenSSH-3.0.2p1 on a Linux libc5 > system, and it fails when compiling packet.c with the following:[snip - compilation failing on missing TCP_NODELAY]> The naive solution of adding: > #include <linux/tcp.h> > doesn't work:[snip - compliation failing on redef of struct tcphdr]> so I fell back to adding the following: > #define TCP_NODELAY 1 > > Brute force, but it works.I can't think of any clean way we can get autoconf to work around this header breakage, but at least your message is in the archives (for those who bother to search them :) -d -- | By convention there is color, \\ Damien Miller <djm at mindrot.org> | By convention sweetness, By convention bitterness, \\ www.mindrot.org | But in reality there are atoms and space - Democritus (c. 400 BCE)
Circa 2001-Dec-24 16:43:16 -0700 dixit Richard Gooch: : Hi, all. I'm trying to compile OpenSSH-3.0.2p1 on a Linux libc5 : system, and it fails when compiling packet.c with the following: : : gcc -g -O2 -Wall -Wpointer-arith -Wno-uninitialized -I. -I. -DETCDIR=\"/etc/ssh\" -D_PATH_SSH_PROGRAM=\"/usr/bin/ssh\" -D_PATH_SSH_ASKPASS_DEFAULT=\"/usr/libexec/ssh-askpass\" -D_PATH_SFTP_SERVER=\"/usr/libexec/sftp-server\" -D_PATH_SSH_PIDDIR=\"/var/run\" -DHAVE_CONFIG_H -c packet.c : packet.c: In function `packet_set_interactive': : packet.c:1211: `TCP_NODELAY' undeclared (first use in this function) : packet.c:1211: (Each undeclared identifier is reported only once : packet.c:1211: for each function it appears in.) That's odd. I don't get any such error when compiling on Red Hat Linux 4.2 (libc-5.3.12-18.4, kernel-2.0.35). Richard, what are the details of the platform you're compiling on? -- jim knoble | jmknoble at pobox.com | http://www.pobox.com/~jmknoble/ (GnuPG fingerprint: 31C4:8AAC:F24E:A70C:4000::BBF4:289F:EAA8:1381:1491) -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 262 bytes Desc: not available Url : http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20011226/8e57678f/attachment.bin