Solved

about NetCat

Posted on 2007-04-01
7
326 Views
Last Modified: 2008-02-01
Hello group,

I will appreciate it if you could give me insight in my problem:

I did download the netcat and untar it. However, when I run "make linux" I get the following error:

netcat.c: In function ‘doexec’:
netcat.c:586: warning: incompatible implicit declaration of built-in function ‘execl’
/tmp/cc1BHXB9.o: In function `gethostpoop':
netcat.c:(.text+0x1217): warning: Using 'gethostbyaddr' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
netcat.c:(.text+0x1138): warning: Using 'gethostbyname' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/tmp/cc1BHXB9.o: In function `getportpoop':
netcat.c:(.text+0x39a): warning: Using 'getservbyname' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
netcat.c:(.text+0x2f7): warning: Using 'getservbyport' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/tmp/cc1BHXB9.o: In function `main':
netcat.c:(.text+0x1914): undefined reference to `res_init'
collect2: ld returned 1 exit status
make[1]: *** [nc] Error 1
make[1]: Leaving directory `/home/ramsin/sec/nc'
make: *** [linux] Error 2


Your help will be appreciated.

ak
0
Comment
Question by:akohan
  • 3
  • 3
7 Comments
 
LVL 34

Expert Comment

by:Duncan Roe
Comment Utility
Where did you read to enter "make linux"?
Just build & install the standard way (I just did, with no problems):

(in your case only) Delete the old source tree
untar the source
cd netcat-0.7.1
./configure (options of your choice: I entered ./configure --prefix=/usr --disable-nls --with-gnu-ld)
make
make install

In other words, follow the instructions in the file INSTALL.

I had no errors or warnings from make. You are talking about netcat-0.7.1 aren't you? You should not be root except probably for "make install".
0
 

Author Comment

by:akohan
Comment Utility

Hi Duncan_roe:

Thanks but I have the documentation and it says I have to go with type of os name (linux, unix, windows and ...) I have. Also, in README file!

and it work. I did mdify the source file by adding/including "resolve.h" the problem got solved. I don't know maybe it is the version that is changed because I'm using NetCat110.gtz and now I have compiled it and works fine.

This is what I have in the README file:

# makefile for netcat, based off same ol' "generic makefile".
# Usually do "make systype" -- if your systype isn't defined, try "generic"
# or something else that most closely matches, see where it goes wrong, fix
# it, and MAIL THE DIFFS back to Hobbit.



Regards,
ak
0
 
LVL 51

Expert Comment

by:ahoffmann
Comment Utility
sounds like you have not installed the proper include files and libraries to compile netcat
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 34

Expert Comment

by:Duncan Roe
Comment Utility
It seems to me you have some "unofficial" version of netcat - Google shows me 2 references to netcat110 - one in Japan and the other no country code but in a language other than English.
Glad to hear you fixed it anyway.
0
 

Author Comment

by:akohan
Comment Utility

Thanks to all for your answer. However, I will appreciate Duncan_roe if he could give me the link which is formal.

thanks,
ak
0
 
LVL 34

Accepted Solution

by:
Duncan Roe earned 50 total points
Comment Utility
0
 

Author Comment

by:akohan
Comment Utility


Thank you.
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Join & Write a Comment

How many times have you wanted to quickly do the same thing to a list but found yourself typing it again and again? I first figured out a small time saver with the up arrow to recall the last command but that can only get you so far if you have a bi…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now