Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No build in OS X 10.6.2 #2

Closed
GoogleCodeExporter opened this issue Nov 25, 2015 · 10 comments
Closed

No build in OS X 10.6.2 #2

GoogleCodeExporter opened this issue Nov 25, 2015 · 10 comments

Comments

@GoogleCodeExporter
Copy link

cc skipfish.c -o skipfish -Wall -funsigned-char -g -ggdb -U_FORTIFY_SOURCE -O3 
-Wno-
format http_client.c database.c crawler.c analysis.c report.c -lcrypto -lssl 
-lidn -lz

Results in:

http_client.c:38:18: error: idna.h: No such file or directory
http_client.c: In function ‘parse_url’:
http_client.c:275: warning: implicit declaration of function 
‘idna_to_ascii_8z’
http_client.c:275: error: ‘IDNA_SUCCESS’ undeclared (first use in this 
function)
http_client.c:275: error: (Each undeclared identifier is reported only once
http_client.c:275: error: for each function it appears in.)
report.c: In function ‘copy_static_code’:
report.c:744: warning: passing argument 3 of ‘scandir’ from incompatible 
pointer type

Original issue reported on code.google.com by thepytho...@gmail.com on 19 Mar 2010 at 10:48

@GoogleCodeExporter
Copy link
Author

Please read the documentation first. You need to install libidn on your system.

Original comment by lcam...@gmail.com on 19 Mar 2010 at 10:50

  • Changed state: Invalid

@GoogleCodeExporter
Copy link
Author

Libidn is fully built and installed.

Original comment by thepytho...@gmail.com on 19 Mar 2010 at 10:52

@GoogleCodeExporter
Copy link
Author

Then it is not in the standard include path on your operating system; if that's 
the
case, you might need to bring it with up with the OS vendor.

A workaround is to provide an additional -I<path> flag in CFLAGS in the 
Makefile. You
can locate the file by doing find /usr -name idna.h

Original comment by lcam...@google.com on 19 Mar 2010 at 10:55

@GoogleCodeExporter
Copy link
Author

Issue 3 has been merged into this issue.

Original comment by lcam...@gmail.com on 20 Mar 2010 at 12:40

@GoogleCodeExporter
Copy link
Author

Most people on OSX use a package system, darwin/mac ports or fink. So MOST of 
the 
time a library like libidn will not be in the standard path. The general 
solution to this is 
to have a configure step rather than a hard coded make file. 

The GNU conventions work well. They also call for an INSTALL file explaining 
how to 
build and install the application. As it is the README is quite weak on 
installation. 

Original comment by anarchog...@gmail.com on 20 Mar 2010 at 12:01

@GoogleCodeExporter
Copy link
Author

For what it's worth, on OSX if you download libidna directly and install it 
from source 
from here: http://ftp.gnu.org/gnu/libidn/libidn-1.18.tar.gz

Then Skipfish's make file correctly finds it in the path and you don't have to 
go mucking 
with things. 

Original comment by anarchog...@gmail.com on 20 Mar 2010 at 12:47

@GoogleCodeExporter
Copy link
Author

If your package system does not install the library in the include path, I do 
not see
this as a problem in skipfish, but with the package. As noted, compiling from 
source
works OK.

Original comment by lcam...@google.com on 20 Mar 2010 at 3:25

@GoogleCodeExporter
Copy link
Author

I think that it is worth noting that it is the *dev* package of libidn that is 
needed 
or the complete source package (which includes the headers... ".h" files). I am 
using 
Ubuntu 9.10. You can see below that I already have libidn installed, but not 
the dev 
package. Here is what I did:

21:10:19 [karl@karl-desktop] ~/Downloads$ tar xfz skipfish-1.09b.tgz
21:10:29 [karl@karl-desktop] ~/Downloads$ cd skipfish/
21:10:31 [karl@karl-desktop] ~/Downloads/skipfish$ make
cc skipfish.c -o skipfish -Wall -funsigned-char -g -ggdb -D_FORTIFY_SOURCE=0 -
I/usr/local/include/ -I/opt/local/include/ -O3 -Wno-format http_client.c 
database.c 
crawler.c analysis.c report.c -lcrypto -lssl -lidn -lz -L/usr/local/lib/ -
L/opt/local/lib
http_client.c:39:18: error: idna.h: No such file or directory
http_client.c: In function ‘parse_url’:
http_client.c:276: warning: implicit declaration of function 
‘idna_to_ascii_8z’
http_client.c:276: error: ‘IDNA_SUCCESS’ undeclared (first use in this 
function)
http_client.c:276: error: (Each undeclared identifier is reported only once
http_client.c:276: error: for each function it appears in.)
make: *** [skipfish] Error 1
21:10:38 [karl@karl-desktop] ~/Downloads/skipfish$ find /lib /usr/lib 
/usr/local/lib/ 
| grep libidn
/usr/lib/libidn.la
/usr/lib/libidn.so.11
/usr/lib/libidn.so.11.5.44
21:12:12 [karl@karl-desktop] ~/Downloads/skipfish$ sudo aptitude install 
libidn11-dev
<SNIP>
Writing extended state information... Done

21:16:03 [karl@karl-desktop] ~/Downloads/skipfish$ make
cc skipfish.c -o skipfish -Wall -funsigned-char -g -ggdb -D_FORTIFY_SOURCE=0 -
I/usr/local/include/ -I/opt/local/include/ -O3 -Wno-format http_client.c 
database.c 
crawler.c analysis.c report.c -lcrypto -lssl -lidn -lz -L/usr/local/lib/ -
L/opt/local/lib

NOTE: See dictionaries/README-FIRST to pick a dictionary for the tool.

21:16:37 [karl@karl-desktop] ~/Downloads/skipfish$ 

Original comment by karlwil...@gmail.com on 22 Mar 2010 at 1:22

@GoogleCodeExporter
Copy link
Author

This is already covered on:
http://code.google.com/p/skipfish/wiki/KnownIssues

Original comment by lcam...@gmail.com on 22 Mar 2010 at 1:44

@GoogleCodeExporter
Copy link
Author

> Most people on OSX use a package system, darwin/mac ports or fink.

For homebrew, you can do:
brew install libidn

skipfish then compiles fine

Original comment by dimi...@gmail.com on 4 Nov 2012 at 9:31

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant