John Coppens | 13 Nov 2006 20:13
Favicon

Problem compiling


Hello people.

I've tried to compile libwww with mysql support and had a few problems. (without
mysql support installation went fine)

Configure was done with  --with-mysql=/opt/mysql
(lib and include are below /opt/mysql)

the configure process gave a first indication of problems:

checking for /opt/mysql/... -L/opt -lmysql

Which isn't correct, I think. I believe it should be -L/opt/mysql/lib -lmysql

Compilation stopped:

/bin/sh ../../libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I/usr/local/include
	-I../../modules/md5 	-I../../modules/expat/xmlparse  
-DW3C_ICONS=\"/usr/local/share/w3c-libwww\"  -g -O2 -Wall -c HTSQL.c
.../../libtool: line 732: test: =: unary operator expected
rm -f .libs/HTSQL.lo
gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I/usr/local/include -I../../modules/md5
-I../../modules/expat/xmlparse -DW3C_ICONS=\"/usr/local/share/w3c-libwww\" -g -O2 -Wall -c
HTSQL.c  -fPIC -DPIC -o .libs/HTSQL.lo
In file included from HTSQL.c:19:
HTSQL.h:34:25: mysql/mysql.h: No such file or directory
In file included from HTSQL.c:19:
HTSQL.h:97: error: syntax error before '*' token
HTSQL.h:97: warning: type defaults to `int' in declaration of `HTSQL_getMysql'
(Continue reading)

Sam Varshavchik | 13 Nov 2006 23:52
Gravatar

Re: Problem compiling

John Coppens writes:

> gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I/usr/local/include -I../../modules/md5
-I../../modules/expat/xmlparse -DW3C_ICONS=\"/usr/local/share/w3c-libwww\" -g -O2 -Wall -c
HTSQL.c  -fPIC -DPIC -o .libs/HTSQL.lo
> In file included from HTSQL.c:19:
> HTSQL.h:34:25: mysql/mysql.h: No such file or directory
> In file included from HTSQL.c:19:
> HTSQL.h:97: error: syntax error before '*' token
> HTSQL.h:97: warning: type defaults to `int' in declaration of `HTSQL_getMysql'
> 
> mysql/mysql.h does exist, under   /opt/mysql/include

Well, there's your problem right there.  I do not see the "-I 
/opt/mysql/include" option anywhere.

> I'm no expert programmer, but I did compile a few apps (including some of my own)
> with mysql without problems...
> 
> Please help...

Fixing the configuration option should solve your immediate problem.  
However the best help you can have is some advice NOT to do what you've been 
doing: manually compiling large software packages and installing them in 
various random locations, by hand.

You did not mention what platform you're running.  All major Linux 
distributions, various BSD flavors, and other platforms -- they all have 
their own tools for managing software package deployment, and maintenance -- 
rpm and apt on Linux, ports on BSD, etc…  They're there for a reason, to 
(Continue reading)

OTR Comm | 14 Nov 2006 08:59

Re: Problem compiling


hello,

John Coppens wrote:
> 
> Hello people.
> 
> I've tried to compile libwww with mysql support and had a few problems. (without
> mysql support installation went fine)
> 
> Configure was done with  --with-mysql=/opt/mysql
> (lib and include are below /opt/mysql)
> 
> the configure process gave a first indication of problems:
> 
> checking for /opt/mysql/... -L/opt -lmysql
> 
> Which isn't correct, I think. I believe it should be -L/opt/mysql/lib -lmysql
> 
> Compilation stopped:
> 
> /bin/sh ../../libtool --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I/usr/local/include  
-I../../modules/md5     -I../../modules/expat/xmlparse  
-DW3C_ICONS=\"/usr/local/share/w3c-libwww\"  -g -O2 -Wall -c HTSQL.c
> .../../libtool: line 732: test: =: unary operator expected
> rm -f .libs/HTSQL.lo
> gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I/usr/local/include -I../../modules/md5
-I../../modules/expat/xmlparse -DW3C_ICONS=\"/usr/local/share/w3c-libwww\" -g -O2 -Wall -c
HTSQL.c  -fPIC -DPIC -o .libs/HTSQL.lo
> In file included from HTSQL.c:19:
(Continue reading)

xavier.torne | 14 Nov 2006 13:24

Re: Problem compiling

hi,
it's true, i used webbot with mysql and i needed to do the same that  
you explained.
I'm sending you the correct file. I use ubuntu 6.10 and webbot works  
fine. As "configure", I used:
./configure ?with-mysql=/usr/lib/libmysqlclient.a
Good luck!

Quoting OTR Comm <otrcomm <at> isp-systems.com>:

>
> hello,
>
> John Coppens wrote:
>>
>> Hello people.
>>
>> I've tried to compile libwww with mysql support and had a few   
>> problems. (without
>> mysql support installation went fine)
>>
>> Configure was done with  --with-mysql=/opt/mysql
>> (lib and include are below /opt/mysql)
>>
>> the configure process gave a first indication of problems:
>>
>> checking for /opt/mysql/... -L/opt -lmysql
>>
>> Which isn't correct, I think. I believe it should be   
>> -L/opt/mysql/lib -lmysql
(Continue reading)

Vic Bancroft | 18 Nov 2006 14:02
Picon

Re: Problem compiling


Wow, this was sent from an address that the listserv doesn't like.  
After waiting some period of time, I decided to resend.  The hope would 
be that someone could check this patch with some alternative mysql 
installations and operating systems before I commit it . . .

BTW, thanks to all the folks for the prompt followup replies !

more,
l8r,
v

Vic Bancroft wrote:

> Sam Varshavchik wrote:
>
>> Well, there's your problem right there.  I do not see the "-I 
>> /opt/mysql/include" option anywhere.
>
>
> Yup, without the include directive the compiler will not find the 
> appropriate definitions.  This is odd, since the last time I used the 
> mysql feature with mysql built out in /usr/local everythi9ng worked . . .
>
>> John Coppens writes:
>
>
>>> Please help...
>>
>>
(Continue reading)

Jan Hutař | 27 Nov 2006 17:13
Picon
Favicon

webbot -rellog file-rellog.log -relation StyleSheet

Hello,
could somebody please check if I'm not doing some stupid mistake?

$ webbot -rellog file-rellog.log -relation StyleSheet http://localhost/test/index.html

index.html:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <link rel="StyleSheet" href="./css.css" type="text/css" media="all">
    <title>This is index</title>
  </head>

  <body>

    <h1>...

File file-rellog.log is not created, but IMHO should contain something like:

StyleSheet text/css http://localhost/test/index.html css.css

Thanks a lot for any help and thoughts.

Regards,
Jan

--
Jan Hutar   Quality Assurance Engineer
jhutar <at> redhat.com        Red Hat, Inc.
(Continue reading)

Jan Hutař | 28 Nov 2006 16:57

webbot -img -alt file-alt.log

Hello,
have another question - please just check if I understand to the docs
(http://www.w3.org/Robot/User/CommandLine.html) well:
  I have 4 html files available thought http://localhost.localdomain/test/<filename>, each with one of
these lines:

alt-ok.html:     <img src='that-rocks.png' width='468' height='60' alt='Some alternate text'/>
alt-blank.html:  <img src='that-rocks.png' width='468' height='60' alt=''/>
alt-no.html:     <img src='that-rocks.png' width='468' height='60'/>
image-away.html: <img src='http://www.example.com/logo.png' width='96' height='31' alt='example'/>

all linked from index.html. Running this command:

webbot -n -depth 10 -prefix http://localhost/test/ -img -alt file-alt.log http://localhost/test/index.html

puts to file-alt.log:

http://localhost/test/alt-ok.html --> http://localhost/test/that-rocks.png
http://localhost/test/image-away.html --> http://www.redhat.com/g/chrome/logo_rh_home.png

Which seems odd to me.

Is it OK, or is it bug?

Regards,
Jan

--
Jan Hutar   Quality Assurance Engineer
jhutar <at> redhat.com        Red Hat, Inc.
(Continue reading)

Jan Hutař | 28 Nov 2006 18:11
Picon
Favicon

webbot -title file-title.log

Hello,
hopefully last question from me for some time :) When running:

webbot -n -depth 10 -prefix http://localhost/test/ -title file-title.log http://localhost/test/index.html

I gets file with only <none> fields like this one:

<none> `<none>' http://localhost/test/index.html

But when add -format or -charset option:

webbot -n -depth 10 -prefix http://localhost/test/ -format del_me.log -title file-title.log http://localhost/test/index.html

I gets right results like:

<none> `This is index' http://localhost/test/index.html

Is it OK?

Regards,
Jan

--
Jan Hutar   Quality Assurance Engineer
jhutar <at> redhat.com        Red Hat, Inc.
Vic Bancroft | 29 Nov 2006 03:32
Picon

Re: webbot -title file-title.log


Jan Hutař wrote:

>hopefully last question from me for some time :) 
>
No please feel free to ask about the behavior of the robots and such . . .

>When running:
>
>webbot -n -depth 10 -prefix http://localhost/test/ -title file-title.log http://localhost/test/index.html
>
>I gets file with only <none> fields like this one:
>
><none> `<none>' http://localhost/test/index.html
>  
>
What would you expect to see ?

>But when add -format or -charset option:
>
>webbot -n -depth 10 -prefix http://localhost/test/ -format del_me.log -title file-title.log http://localhost/test/index.html
>
>I gets right results like:
>
><none> `This is index' http://localhost/test/index.html
>
>Is it OK?
>  
>
Is there some change in the code or documentation that might make it 
(Continue reading)

Jan Hutař | 1 Dec 2006 11:13
Picon
Favicon

webbot -timeout 3 -l file-l-timeout.log

Hello again :)
I have another problem. Its: how to simulate timeout? I have following timeout.php script:

<?php

$timeout = 10;

sleep($timeout);
echo "We waited $timeout s.";

?>

and when running command:

webbot -n -depth 10 -prefix http://localhost.localdomain/test/ -timeout 3 -l file-l-timeout.log http://localhost.localdomain/test/index.html

I can see, that webbot is waiting 10 secs (not 3 as specified with "-timeout" option). When command ends,
there is a following line in file-l-timeout.log:

...
localhost - - [Fri, 01 Dec 2006 11:02:53] GET http://localhost.localdomain/test/timeout.php 200 15
...

Will be happy for any comments.

Thanks,
Jan

--
Jan Hutar   Quality Assurance Engineer
(Continue reading)


Gmane