Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-06-02 Thread Petr Pisar
On Sun, Jun 02, 2019 at 02:00:54PM +0200, Tim Rühsen wrote:
> On 31.05.19 21:15, Petr Pisar wrote:
> > On Thu, May 30, 2019 at 09:56:33AM -0400, Jeffrey Walton wrote:
> >> I used PERL5LIB to put teests/ on path for Perl. It looks like at
> >> least one Debian machine I have is back to the Socket::inet_ntoa
> >> problems.
> >>
> >> I'm calling it good.
> >>
> >> The Perl people need to fix Socket::inet_ntoa, and the Debian people
> >> need to make it available. I'm guessing Debian is the holdup. They
> >> will leave things broke rather than supplying an update. It is a waste
> >> of time to file a Debian bug report.
> >>
> > You can report your issues directly to Socket authors if you believe the 
> > issue
> > is not specific to Debian.
> > 
> > May I know what's your issue with Socket::inet_ntoa?
> 
> It's not about Socket::inet_ntoa (sorry for not correcting this before).
> IMO, it's about https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=887590
> 
I see. Those are the IPv6 patches for HTTP::Daemon I wrote two years ago for
RHEL.

The patches are indeed quite large and have an effect on other packages that
use HTTP::Daemon. Especially on tests. Because various packages are not
prepared for HTTP::Daemon listening on an IPv6 socket. I understand why Debian
does not want to apply them to a stable distribution. Applying them would
change a behavior and people could get mad at them.

I can see two solutions for wget. Either use 127.0.0.1 instead of localhost
everywhere, or skip the particular test if HTTP::Daemon is unable to listen on
an IPv6 while plain Socket (or IO::Socket::IP) is.

-- Petr


signature.asc
Description: PGP signature


Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-06-02 Thread Tim Rühsen
On 31.05.19 21:15, Petr Pisar wrote:
> On Thu, May 30, 2019 at 09:56:33AM -0400, Jeffrey Walton wrote:
>> I used PERL5LIB to put teests/ on path for Perl. It looks like at
>> least one Debian machine I have is back to the Socket::inet_ntoa
>> problems.
>>
>> I'm calling it good.
>>
>> The Perl people need to fix Socket::inet_ntoa, and the Debian people
>> need to make it available. I'm guessing Debian is the holdup. They
>> will leave things broke rather than supplying an update. It is a waste
>> of time to file a Debian bug report.
>>
> You can report your issues directly to Socket authors if you believe the issue
> is not specific to Debian.
> 
> May I know what's your issue with Socket::inet_ntoa?

It's not about Socket::inet_ntoa (sorry for not correcting this before).
IMO, it's about https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=887590

Regards, Tim



signature.asc
Description: OpenPGP digital signature


Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-31 Thread Petr Pisar
On Thu, May 30, 2019 at 09:56:33AM -0400, Jeffrey Walton wrote:
> I used PERL5LIB to put teests/ on path for Perl. It looks like at
> least one Debian machine I have is back to the Socket::inet_ntoa
> problems.
> 
> I'm calling it good.
> 
> The Perl people need to fix Socket::inet_ntoa, and the Debian people
> need to make it available. I'm guessing Debian is the holdup. They
> will leave things broke rather than supplying an update. It is a waste
> of time to file a Debian bug report.
> 
You can report your issues directly to Socket authors if you believe the issue
is not specific to Debian.

May I know what's your issue with Socket::inet_ntoa?

-- Petr


signature.asc
Description: PGP signature


Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Tim Rühsen


On 30.05.19 15:56, Jeffrey Walton wrote:
> On Thu, May 30, 2019 at 9:50 AM Tim Rühsen  wrote:
>>
>> On 30.05.19 12:49, Jeffrey Walton wrote:
>>> On Thu, May 30, 2019 at 6:30 AM Tim Rühsen  wrote:

 Reverted 79be99aff (passes CI). Could you give it try, please ?
>>>
>>> Where can we get that?
>>>
>>> It is not on the mirror (yet?), and https://www.gnu.org/software/wget/
>>> does not list Git or Savannah access.
>>
>> It's on Savannah and Gitlab, branch master,
>> commit b3f86f90cc5b3d3d1c2d6f720818fda9486108ec
> 
> OK, thanks.
> 
> I used PERL5LIB to put teests/ on path for Perl. It looks like at
> least one Debian machine I have is back to the Socket::inet_ntoa
> problems.

Well, using older (Debian) distributions will see that issue. The IPv6
patch has been added to Debian not long ago.

> I'm calling it good.
> 
> The Perl people need to fix Socket::inet_ntoa, and the Debian people
> need to make it available. I'm guessing Debian is the holdup. They
> will leave things broke rather than supplying an update. It is a waste
> of time to file a Debian bug report.

They don't add new functionality to Debian stable, just fixing bugs. And
that IPv6 patch can be considered as 'new feature'. Debian is just not a
rolling release - live with it or change to another distro. All has it's
pros and cons. I live pretty well with Debian unstable (since ~ 2002).
Fix and new features come in pretty fast - except as in times of freeze
(we are currently in (deep ?) freeze).

BTW, the perl people never added the missing IPv6 code. Maybe they
abandoned the module we currently use - and we should use a different
module !?. But I am not into perl on purpose - it's one of the most
stupid programming languages I have ever seen (in short: write once,
read never - hard to maintain). It's simply not 'future save'.

Regards, Tim



signature.asc
Description: OpenPGP digital signature


Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Jeffrey Walton
On Thu, May 30, 2019 at 9:50 AM Tim Rühsen  wrote:
>
> On 30.05.19 12:49, Jeffrey Walton wrote:
> > On Thu, May 30, 2019 at 6:30 AM Tim Rühsen  wrote:
> >>
> >> Reverted 79be99aff (passes CI). Could you give it try, please ?
> >
> > Where can we get that?
> >
> > It is not on the mirror (yet?), and https://www.gnu.org/software/wget/
> > does not list Git or Savannah access.
>
> It's on Savannah and Gitlab, branch master,
> commit b3f86f90cc5b3d3d1c2d6f720818fda9486108ec

OK, thanks.

I used PERL5LIB to put teests/ on path for Perl. It looks like at
least one Debian machine I have is back to the Socket::inet_ntoa
problems.

I'm calling it good.

The Perl people need to fix Socket::inet_ntoa, and the Debian people
need to make it available. I'm guessing Debian is the holdup. They
will leave things broke rather than supplying an update. It is a waste
of time to file a Debian bug report.

Jeff



Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Tim Rühsen
On 30.05.19 12:49, Jeffrey Walton wrote:
> On Thu, May 30, 2019 at 6:30 AM Tim Rühsen  wrote:
>>
>> Reverted 79be99aff (passes CI). Could you give it try, please ?
> 
> Where can we get that?
> 
> It is not on the mirror (yet?), and https://www.gnu.org/software/wget/
> does not list Git or Savannah access.

It's on Savannah and Gitlab, branch master,
commit b3f86f90cc5b3d3d1c2d6f720818fda9486108ec

Regards, Tim



signature.asc
Description: OpenPGP digital signature


Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Jeffrey Walton
On Thu, May 30, 2019 at 7:21 AM Jeffrey Walton  wrote:
>
> On Thu, May 30, 2019 at 6:49 AM Jeffrey Walton  wrote:
> >
> > On Thu, May 30, 2019 at 6:30 AM Tim Rühsen  wrote:
> > >
> > > Reverted 79be99aff (passes CI). Could you give it try, please ?
> >
> > Where can we get that?
> >
> > It is not on the mirror (yet?), and https://www.gnu.org/software/wget/
> > does not list Git or Savannah access.
>
> I performed a sed on all the *.px files. (If this was wrong let me
> know what you need).
>
> for file in $(find "$PWD" -name '*.px')
> do
> sed -e 's|env -S perl -I .|env perl|g' "$file" > "$file.fixed"
> chmod +w "$file"
> mv "$file.fixed" "$file"
> chmod +x "$file"
> chmod -w "$file"
> done
>
> The +x was needed for a few of the files (most were OK). Otherwise got
> permission denied.
>
> After the change, most tests pass. There were some failures that remained:
>
> FAIL: Test-https-pfs.px
> FAIL: Test-https-tlsv1.px
> FAIL: Test-https-tlsv1x.px
> FAIL: Test-https-selfsigned.px
> SKIP: Test-https-weboftrust.px
> FAIL: Test-https-clientcert.px
> FAIL: Test-https-crl.px
> PASS: Test-https-badcerts.px
>
> $ cd ./wget-1.20.3/tests
> $ ./Test-https-pfs.px
> Can't locate WgetFeature.pm in @INC (you may need to install the
> WgetFeature module) (@INC contains: /etc/perl
> /usr/local/lib/x86_64-linux-gnu/perl/5.24.1
> /usr/local/share/perl/5.24.1 /usr/lib/x86_64-linux-gnu/perl5/5.24
> /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.24
> /usr/share/perl/5.24 /usr/local/lib/site_perl
> /usr/lib/x86_64-linux-gnu/perl-base) at ./Test-https-pfs.px line 6.
> BEGIN failed--compilation aborted at ./Test-https-pfs.px line 6.

I don't know Perl, but it looks like this is the problem:
https://perlmaven.com/cant-locate-in-inc . And this may be the
solution: https://perlmaven.com/how-to-add-a-relative-directory-to-inc
.

I can't help but laugh at the solutions. It never ceases to amazes me
at the f**k'd up convoluted solutions engineers come up with.
Apparently 'use ./WgetFeature.pm;' would have been way too easy.

And apparently including PWD by default would have been way too easy.
We have already accepted the risk of compiling and running
Test-https-pfs.px in /some/user/directory. Using WgetFeature.pm, which
is side-by-side and needed by Test-https-pfs.px, adds no additional
risk.

Instead we have to suffer the shit the Perl people came up with. More
Darwin awards...

Jeff



Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Jeffrey Walton
On Thu, May 30, 2019 at 6:49 AM Jeffrey Walton  wrote:
>
> On Thu, May 30, 2019 at 6:30 AM Tim Rühsen  wrote:
> >
> > Reverted 79be99aff (passes CI). Could you give it try, please ?
>
> Where can we get that?
>
> It is not on the mirror (yet?), and https://www.gnu.org/software/wget/
> does not list Git or Savannah access.

I performed a sed on all the *.px files. (If this was wrong let me
know what you need).

for file in $(find "$PWD" -name '*.px')
do
sed -e 's|env -S perl -I .|env perl|g' "$file" > "$file.fixed"
chmod +w "$file"
mv "$file.fixed" "$file"
chmod +x "$file"
chmod -w "$file"
done

The +x was needed for a few of the files (most were OK). Otherwise got
permission denied.

After the change, most tests pass. There were some failures that remained:

FAIL: Test-https-pfs.px
FAIL: Test-https-tlsv1.px
FAIL: Test-https-tlsv1x.px
FAIL: Test-https-selfsigned.px
SKIP: Test-https-weboftrust.px
FAIL: Test-https-clientcert.px
FAIL: Test-https-crl.px
PASS: Test-https-badcerts.px

$ cd ./wget-1.20.3/tests
$ ./Test-https-pfs.px
Can't locate WgetFeature.pm in @INC (you may need to install the
WgetFeature module) (@INC contains: /etc/perl
/usr/local/lib/x86_64-linux-gnu/perl/5.24.1
/usr/local/share/perl/5.24.1 /usr/lib/x86_64-linux-gnu/perl5/5.24
/usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.24
/usr/share/perl/5.24 /usr/local/lib/site_perl
/usr/lib/x86_64-linux-gnu/perl-base) at ./Test-https-pfs.px line 6.
BEGIN failed--compilation aborted at ./Test-https-pfs.px line 6.

And

$ find . -name WgetFeature.pm
./WgetFeature.pm

Jeff



Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Jeffrey Walton
On Thu, May 30, 2019 at 6:30 AM Tim Rühsen  wrote:
>
> Reverted 79be99aff (passes CI). Could you give it try, please ?

Where can we get that?

It is not on the mirror (yet?), and https://www.gnu.org/software/wget/
does not list Git or Savannah access.

Jeff



Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Tim Rühsen
Reverted 79be99aff (passes CI). Could you give it try, please ?

Regards, Tim

On 30.05.19 11:57, Jeffrey Walton wrote:
> On Thu, May 30, 2019 at 5:40 AM Tim Rühsen  wrote:
>>
>> The shebang line here reads
>>
>> #!/usr/bin/env -S perl -I .
>>
>> /usr/bin/env is part of coreutils ans should know '-S', even on Debian
>> stretch.
>>
>> $ /usr/bin/env --version
>> env (GNU coreutils) 8.30
>>
>> @Jeff, what does '/usr/bin/env --help' show ? Or 'man env' ?
> 
> $ /usr/bin/env --version
> env (GNU coreutils) 8.26
> Copyright (C) 2016 Free Software Foundation, Inc.
> ...
> 
> $ /usr/bin/env --help
> Usage: /usr/bin/env [OPTION]... [-] [NAME=VALUE]... [COMMAND [ARG]...]
> Set each NAME to VALUE in the environment and run COMMAND.
> 
> Mandatory arguments to long options are mandatory for short options too.
>   -i, --ignore-environment  start with an empty environment
>   -0, --null   end each output line with NUL, not newline
>   -u, --unset=NAME remove variable from the environment
>   --help display this help and exit
>   --version  output version information and exit
> 
> A mere - implies -i.  If no COMMAND, print the resulting environment.
> 
> GNU coreutils online help: 
> Full documentation at: 
> or available locally via: info '(coreutils) env invocation'
> jwalton@tinkerboard:~/cryptopp$
> 



signature.asc
Description: OpenPGP digital signature


Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Jeffrey Walton
On Thu, May 30, 2019 at 5:40 AM Tim Rühsen  wrote:
>
> The shebang line here reads
>
> #!/usr/bin/env -S perl -I .
>
> /usr/bin/env is part of coreutils ans should know '-S', even on Debian
> stretch.
>
> $ /usr/bin/env --version
> env (GNU coreutils) 8.30
>
> @Jeff, what does '/usr/bin/env --help' show ? Or 'man env' ?

$ /usr/bin/env --version
env (GNU coreutils) 8.26
Copyright (C) 2016 Free Software Foundation, Inc.
...

$ /usr/bin/env --help
Usage: /usr/bin/env [OPTION]... [-] [NAME=VALUE]... [COMMAND [ARG]...]
Set each NAME to VALUE in the environment and run COMMAND.

Mandatory arguments to long options are mandatory for short options too.
  -i, --ignore-environment  start with an empty environment
  -0, --null   end each output line with NUL, not newline
  -u, --unset=NAME remove variable from the environment
  --help display this help and exit
  --version  output version information and exit

A mere - implies -i.  If no COMMAND, print the resulting environment.

GNU coreutils online help: 
Full documentation at: 
or available locally via: info '(coreutils) env invocation'
jwalton@tinkerboard:~/cryptopp$



Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Tim Rühsen
OK, just got a PM showing that '-S' is new. Not even known by coreutils
8.28 (used on Ubuntu 18.04). So this is a no-go and needs to be addressed.

Thanks for pointing out.

Regards, Tim

On 30.05.19 11:40, Tim Rühsen wrote:
> The shebang line here reads
> 
> #!/usr/bin/env -S perl -I .
> 
> /usr/bin/env is part of coreutils ans should know '-S', even on Debian
> stretch.
> 
> $ /usr/bin/env --version
> env (GNU coreutils) 8.30
> 
> @Jeff, what does '/usr/bin/env --help' show ? Or 'man env' ?
> 
> Regards, Tim
> 
> On 29.05.19 14:35, Darshit Shah wrote:
>> That's very weird, the shebang line in that file reads:
>>
>> ```
>> #!/usr/bin/env perl
>> ```
>>
>> No options are being passed to env there. I'm going to have to take another
>> look at this later
>>
>> * Jeffrey Walton  [190529 14:21]:
>>> Hi Everyone/Tim,
>>>
>>> Debian 9.9:
>>>
>>> $ lsb_release -a
>>> No LSB modules are available.
>>> Distributor ID: Debian
>>> Description:Debian GNU/Linux 9.9 (stretch)
>>> Release:9.9
>>> Codename:   stretch
>>>
>>> $ make check
>>> ...
>>>
>>> PASS: Test-ftp-pasv-not-supported.px
>>> FAIL: Test-https-pfs.px
>>> FAIL: Test-https-tlsv1.px
>>> FAIL: Test-https-tlsv1x.px
>>> FAIL: Test-https-selfsigned.px
>>> SKIP: Test-https-weboftrust.px
>>> FAIL: Test-https-clientcert.px
>>> FAIL: Test-https-crl.px
>>> PASS: Test-https-badcerts.px
>>>
>>> Trying to run manually:
>>>
>>> $ ./wget-1.20.3/tests/Test-https-pfs.px
>>> /usr/bin/env: invalid option -- 'S'
>>> Try '/usr/bin/env --help' for more information.
>>>
>>> And
>>>
>>> $ /usr/bin/env --version
>>> env (GNU coreutils) 8.26
>>>
>>>
>>
> 



signature.asc
Description: OpenPGP digital signature


Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-30 Thread Tim Rühsen
The shebang line here reads

#!/usr/bin/env -S perl -I .

/usr/bin/env is part of coreutils ans should know '-S', even on Debian
stretch.

$ /usr/bin/env --version
env (GNU coreutils) 8.30

@Jeff, what does '/usr/bin/env --help' show ? Or 'man env' ?

Regards, Tim

On 29.05.19 14:35, Darshit Shah wrote:
> That's very weird, the shebang line in that file reads:
> 
> ```
> #!/usr/bin/env perl
> ```
> 
> No options are being passed to env there. I'm going to have to take another
> look at this later
> 
> * Jeffrey Walton  [190529 14:21]:
>> Hi Everyone/Tim,
>>
>> Debian 9.9:
>>
>> $ lsb_release -a
>> No LSB modules are available.
>> Distributor ID: Debian
>> Description:Debian GNU/Linux 9.9 (stretch)
>> Release:9.9
>> Codename:   stretch
>>
>> $ make check
>> ...
>>
>> PASS: Test-ftp-pasv-not-supported.px
>> FAIL: Test-https-pfs.px
>> FAIL: Test-https-tlsv1.px
>> FAIL: Test-https-tlsv1x.px
>> FAIL: Test-https-selfsigned.px
>> SKIP: Test-https-weboftrust.px
>> FAIL: Test-https-clientcert.px
>> FAIL: Test-https-crl.px
>> PASS: Test-https-badcerts.px
>>
>> Trying to run manually:
>>
>> $ ./wget-1.20.3/tests/Test-https-pfs.px
>> /usr/bin/env: invalid option -- 'S'
>> Try '/usr/bin/env --help' for more information.
>>
>> And
>>
>> $ /usr/bin/env --version
>> env (GNU coreutils) 8.26
>>
>>
> 



signature.asc
Description: OpenPGP digital signature


Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-29 Thread Jeffrey Walton
On Wed, May 29, 2019 at 8:38 AM Jeffrey Walton  wrote:
>
> On Wed, May 29, 2019 at 8:35 AM Darshit Shah  wrote:
> >
> > That's very weird, the shebang line in that file reads:
> >
> > ```
> > #!/usr/bin/env perl
> > ```
> >
> > No options are being passed to env there. I'm going to have to take another
> > look at this later
>
> Also see https://github.com/mirror/wget/blob/master/tests/Test-https-pfs.px .

I did a quick bash -x to make sure my script was not sideways
(https://github.com/noloader/Build-Scripts/blob/master/build-wget.sh#L153):

** Wget **
+ echo

+ /home/jwalton/bootstrap/bin/wget -O wget-1.20.3.tar.gz --ca-certificate=/home/
jwalton/.cacert/lets-encrypt-root-x3.pem https://ftp.gnu.org/pub/gnu/wget/wget-1
.20.3.tar.gz
--2019-05-29 08:41:06--  https://ftp.gnu.org/pub/gnu/wget/wget-1.20.3.tar.gz
Resolving ftp.gnu.org... 209.51.188.20, 2001:470:142:3::b
Connecting to ftp.gnu.org|209.51.188.20|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 4489249 (4.3M) [application/x-gzip]
Saving to: 'wget-1.20.3.tar.gz'

It looks like I am fetching the 1.20.3 tarball as expected.

Jeff



Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-29 Thread Jeffrey Walton
On Wed, May 29, 2019 at 8:35 AM Darshit Shah  wrote:
>
> That's very weird, the shebang line in that file reads:
>
> ```
> #!/usr/bin/env perl
> ```
>
> No options are being passed to env there. I'm going to have to take another
> look at this later

Also see https://github.com/mirror/wget/blob/master/tests/Test-https-pfs.px .

Jeff



Re: [Bug-wget] /usr/bin/env: invalid option -- 'S'

2019-05-29 Thread Darshit Shah
That's very weird, the shebang line in that file reads:

```
#!/usr/bin/env perl
```

No options are being passed to env there. I'm going to have to take another
look at this later

* Jeffrey Walton  [190529 14:21]:
> Hi Everyone/Tim,
> 
> Debian 9.9:
> 
> $ lsb_release -a
> No LSB modules are available.
> Distributor ID: Debian
> Description:Debian GNU/Linux 9.9 (stretch)
> Release:9.9
> Codename:   stretch
> 
> $ make check
> ...
> 
> PASS: Test-ftp-pasv-not-supported.px
> FAIL: Test-https-pfs.px
> FAIL: Test-https-tlsv1.px
> FAIL: Test-https-tlsv1x.px
> FAIL: Test-https-selfsigned.px
> SKIP: Test-https-weboftrust.px
> FAIL: Test-https-clientcert.px
> FAIL: Test-https-crl.px
> PASS: Test-https-badcerts.px
> 
> Trying to run manually:
> 
> $ ./wget-1.20.3/tests/Test-https-pfs.px
> /usr/bin/env: invalid option -- 'S'
> Try '/usr/bin/env --help' for more information.
> 
> And
> 
> $ /usr/bin/env --version
> env (GNU coreutils) 8.26
> 
> 

-- 
Thanking You,
Darshit Shah
PGP Fingerprint: 7845 120B 07CB D8D6 ECE5 FF2B 2A17 43ED A91A 35B6


signature.asc
Description: PGP signature