C Errors on compiling
i'm doing my B.Tech project on Portknocking concept while i implementing portknocking in C using Fedora Core 6 these errors are came.... plz suggest any solutions for that plz its very urgent......
eventhough i installed openssl and libslack packages these errors are came... [root@localhost ~]# cc knock.h [root@localhost ~]# cc knockc.c /tmp/ccmAMaEo.o: In function `main': knockc.c: (.text+0x59a): undefined reference to `BF_set_key' knockc.c:(.text+0x5c4): undefined reference to `BF_ecb_encrypt' collect2: ld returned 1 exit status [root@localhost ~]# cc knockd.c knockd.c:29:33: error: md5.h: No such file or directory knockd.c: In function ‘main’: knockd.c:110: warning: passing argument 2 of ‘signal’ from incompatible pointer type knockd.c:111: warning: passing argument 2 of ‘signal’ from incompatible pointer type knockd.c:115: warning: comparison between pointer and integer knockd.c:147: warning: passing argument 1 of ‘strcmp’ makes pointer from integer without a cast |
2 things: firstly, marking your thread as Urgent is a big no-no here. We are all volunteers and do this on our own time, no problem is more urgent than any other. Secondly, this forum is purely a place to say "hello", you won't get any technical answers in this forum so I have moved your thread to the Fedora forum.
|
I have also renamed your thread to give it a meaningful title.
|
is this code that you have written yourself ?
if so have you included the right headers and linked to correct libs? |
First, a lot of my post will be guessing since you make no revelations about your code nor your install paths for openssl. Second, there is no point to “cc knock.h” as it should be used as a header file. Third, you need to not only install openssl, but to use it (i.e., tell the compiler where to find the include files and the linker what libs to link). For your first error (in knockc.c) it compiles fine, but there is a linking error. Most likely you need to link to the ssl library (try “cc -lssl -lcrypto -ldl -o knockc knockc.c”). For your second error (knockd.c) the compiler can’t find the file “md5.h” you can either change “#include <md5.h>” to “#include <openssl/md5.h>” or specify the include path the compiler should use (i.e., “cc -I/usr/include/openssl -o knockd knockd.c”).
|
Quote:
No i downloaded this coding from Portknocking.org and eventhough i installed openssl and libslack the errors are came..... so plz suggest any other solutions.............. |
and the code dosn't have a make file?
or install instructions? |
Quote:
|
tel me ur solution i'll try......
|
Umm…
Did you not see this? |
i already tried it will work for knockc only not for knockd...... in knockd the main error is undefined reference to MD5file() function......
|
I guess if anyone wants to see his code you can look at his other post a few spots down on the main fedora page.
http://www.linuxquestions.org/questi...d.php?t=547233 Don't double post. |
All times are GMT -5. The time now is 06:02 PM. |