LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-07-2009, 01:27 AM   #1
lulatsch
LQ Newbie
 
Registered: Nov 2008
Posts: 24

Rep: Reputation: 15
Unhappy installing knockd


I am trying to install knockd from the knock-0.5.tar.gz.

The ./configure works fine, but when I do make:

Code:
[root@testbox knock-0.5]# make
gcc -g -O2 -g -Wall -pedantic -fno-exceptions -D_GNU_SOURCE -I. -o src/knockd.o -c src/knockd.c
src/knockd.c:134: error: âPATH_MAXâ undeclared here (not in a function)
src/knockd.c: In function âparseconfigâ:
src/knockd.c:438: warning: unused variable âlineâ
src/knockd.c: In function âget_next_one_time_sequenceâ:
src/knockd.c:695: warning: unused variable âlineâ
src/knockd.c: In function âsniffâ:
src/knockd.c:1386: warning: unused variable âparsed_stop_cmdâ
src/knockd.c:1385: warning: unused variable âparsed_start_cmdâ
make: *** [src/knockd.o] Error 1

I alternatively tried to install with the knock-0.5-4.src.rpm.

Here it also fails with:

Code:
[root@testbox knocksrcrpm]# rpmbuild --rebuild knock-0.5-4.src.rpm
Installing knock-0.5-4.src.rpm
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.v4qqY5
+ umask 022
+ cd /root/rpmbuild/BUILD
+ cd /root/rpmbuild/BUILD
+ rm -rf knock-0.5
+ /usr/bin/gzip -dc /root/rpmbuild/SOURCES/knock-0.5.tar.gz
+ /bin/tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd knock-0.5
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ echo 'Patch #0 (knock-0.5-syslog.patch):'
Patch #0 (knock-0.5-syslog.patch):
+ /bin/cat /root/rpmbuild/SOURCES/knock-0.5-syslog.patch
+ /usr/bin/patch -s -p1 -b --suffix .syslog --fuzz=0
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.k0hwSJ
+ umask 022
+ cd /root/rpmbuild/BUILD
+ cd knock-0.5
+ export CFLAGS=-I/usr/include/pcap
+ CFLAGS=-I/usr/include/pcap
+ CFLAGS=-I/usr/include/pcap
+ export CFLAGS
+ CXXFLAGS='-O2 -g -march=i386 -mtune=i686'
+ export CXXFLAGS
+ FFLAGS='-O2 -g -march=i386 -mtune=i686'
+ export FFLAGS
+ ./configure --host=i686-pc-linux-gnu --build=i686-pc-linux-gnu --target=i386-redhat-linux --program-prefix= --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/var/lib --mandir=/usr/share/man --infodir=/usr/share/info
checking for i686-pc-linux-gnu-gcc... no
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking for i686-pc-linux-gnu-g++... no
checking for i686-pc-linux-gnu-c++... no
checking for i686-pc-linux-gnu-gpp... no
checking for i686-pc-linux-gnu-aCC... no
checking for i686-pc-linux-gnu-CC... no
checking for i686-pc-linux-gnu-cxx... no
checking for i686-pc-linux-gnu-cc++... no
checking for i686-pc-linux-gnu-cl... no
checking for i686-pc-linux-gnu-FCC... no
checking for i686-pc-linux-gnu-KCC... no
checking for i686-pc-linux-gnu-RCC... no
checking for i686-pc-linux-gnu-xlC_r... no
checking for i686-pc-linux-gnu-xlC... no
checking for g++... no
checking for c++... no
checking for gpp... no
checking for aCC... no
checking for CC... no
checking for cxx... no
checking for cc++... no
checking for cl... no
checking for FCC... no
checking for KCC... no
checking for RCC... no
checking for xlC_r... no
checking for xlC... no
checking whether we are using the GNU C++ compiler... no
checking whether g++ accepts -g... no
checking for a BSD-compatible install... /usr/bin/install -c
checking for pcap_open_live in -lpcap... yes
checking how to run the C preprocessor... gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/wait.h that is POSIX.1 compatible... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking arpa/inet.h usability... yes
checking arpa/inet.h presence... yes
checking for arpa/inet.h... yes
checking pcap.h usability... yes
checking pcap.h presence... yes
checking for pcap.h... yes
checking netdb.h usability... yes
checking netdb.h presence... yes
checking for netdb.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking for unistd.h... (cached) yes
checking for an ANSI C-conforming const... yes
checking for size_t... yes
checking whether struct tm is in sys/time.h or time.h... time.h
checking for pid_t... yes
checking for unistd.h... (cached) yes
checking vfork.h usability... no
checking vfork.h presence... no
checking for vfork.h... no
checking for fork... yes
checking for vfork... yes
checking for working fork... yes
checking for working vfork... (cached) yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
checking return type of signal handlers... void
checking for vprintf... yes
checking for _doprnt... no
checking for inet_ntoa... yes
checking for memmove... yes
checking for strcasecmp... yes
checking for strdup... yes
checking for strstr... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
+ /usr/bin/make
gcc -O2 -g -march=i386 -mtune=i686 -I/usr/include/pcap -g -Wall -pedantic -fno-exceptions -D_GNU_SOURCE -I. -o src/knockd.o -c src/knockd.c
src/knockd.c:134: error: âPATH_MAXâ undeclared here (not in a function)
src/knockd.c: In function âparseconfigâ:
src/knockd.c:438: warning: unused variable âlineâ
src/knockd.c: In function âget_next_one_time_sequenceâ:
src/knockd.c:695: warning: unused variable âlineâ
src/knockd.c: In function âsniffâ:
src/knockd.c:1386: warning: unused variable âparsed_stop_cmdâ
src/knockd.c:1385: warning: unused variable âparsed_start_cmdâ
make: *** [src/knockd.o] Error 1
error: Bad exit status from /var/tmp/rpm-tmp.k0hwSJ (%build)


RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.k0hwSJ (%build)
I am running on it on an up to date Fedora 11. Please help
 
Old 08-12-2009, 12:47 AM   #2
lulatsch
LQ Newbie
 
Registered: Nov 2008
Posts: 24

Original Poster
Rep: Reputation: 15
For all the others waiting (in vain) for a reply;

The solution is to add a

Quote:
#include <limits.h>
to the includes in list.h
 
  


Reply

Tags
compile, configure, fedora, source



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Simpler knockd to open SSH on remote server? littlebigman Linux - Software 1 04-01-2009 06:13 AM
Toshiba Satellite 110CS installing pdf reader, installing linux nappy501 Linux - Laptop and Netbook 3 10-11-2008 10:45 AM
Knockd ryanoa Linux - Security 3 10-10-2006 06:03 PM
Installing the nvidia driver off the web site and installing rpm in ubuntu? darkhatter Ubuntu 3 02-19-2006 02:44 PM
knockd gong Linux - Security 1 07-03-2005 06:49 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:28 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration