Bug 223288 - www/lighttpd: fix build without IPV6
Summary: www/lighttpd: fix build without IPV6
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Guido Falsi
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-28 15:01 UTC by Piotr Kubaj
Modified: 2017-10-31 16:08 UTC (History)
2 users (show)

See Also:
pkubaj: maintainer-feedback+


Attachments
patch (1.16 KB, patch)
2017-10-28 15:01 UTC, Piotr Kubaj
no flags Details | Diff
patch (2.08 KB, patch)
2017-10-31 14:56 UTC, Piotr Kubaj
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Piotr Kubaj freebsd_committer freebsd_triage 2017-10-28 15:01:39 UTC
Created attachment 187538 [details]
patch

This patch fixes the build with IPV6 disabled.

It's already upstream:
https://redmine.lighttpd.net/issues/2832

Tested on 11.1-STABLE.
Comment 1 commit-hook freebsd_committer freebsd_triage 2017-10-28 16:01:25 UTC
A commit references this bug:

Author: madpilot
Date: Sat Oct 28 16:00:57 UTC 2017
New revision: 453061
URL: https://svnweb.freebsd.org/changeset/ports/453061

Log:
  Fix runtime problem when lighttpd is built with IPV6 option turned
  on.

  PR:		223288
  Submitted by:	Piotr Kubaj <pkubaj@anongoth.pl> (maintainer)
  Obtained from:	https://redmine.lighttpd.net/issues/2832

Changes:
  head/www/lighttpd/Makefile
  head/www/lighttpd/files/patch-patch-src__network.c
Comment 2 Guido Falsi freebsd_committer freebsd_triage 2017-10-28 16:01:50 UTC
Committed. Thanks!
Comment 3 Piotr Kubaj freebsd_committer freebsd_triage 2017-10-28 16:13:27 UTC
(In reply to Guido Falsi from comment #2)
It was actually a build-time problem, so a PORTREVISION bump was completely unnecessary.
Comment 4 Guido Falsi freebsd_committer freebsd_triage 2017-10-28 17:18:54 UTC
Before committing I made a quick test with the port as is and it actually built for me, with IPV6 option on, which is the default.

I also did test it with IPV6 on and off before committing the update on the previous PR.

Also I cannot find any lighttpd build failure on the pkg-fallout mailing list [1], so it did build successfully in the cluster too.

So I actually think the PORTREVISION bump was needed.

[1] https://lists.freebsd.org/pipermail/freebsd-pkg-fallout/
Comment 5 Guido Falsi freebsd_committer freebsd_triage 2017-10-28 17:20:54 UTC
Ooops.

You are right.

I just noticed misread the subject of this PR as "with IPV6". My fault.

I stand corrected. Unluckily there's nothing that can be done once portrevision is bumped.
Comment 6 edgeman 2017-10-31 14:28:27 UTC
This port still won't build for me with IPV6 turned off.
Builds fine with it on.
11.1-RELEASE-p2
Errors in network.c referencing 6 vs 4 issues:
eg.
network.c:82:30: error: no member named 'sin6_port' in 'struct sockaddr_in'; did you mean 'sin_port'?
network.c:82:25: error: no member named 'ipv6' in 'union sock_addr'; did you mean 'ipv4'?
network.c:82:30: error: no member named 'sin6_port' in 'struct sockaddr_in'; did you mean 'sin_port'?

In make config I only have BZIP2, DOCS enabled. If I turn on IPV6 it builds.
Comment 7 Piotr Kubaj freebsd_committer freebsd_triage 2017-10-31 14:56:25 UTC
Created attachment 187611 [details]
patch

Sorry, here's a correct patch.

Note that this is a SVN patch, you can't just drop it into files/.
Comment 8 Piotr Kubaj freebsd_committer freebsd_triage 2017-10-31 14:57:51 UTC
Changing status.
Comment 9 commit-hook freebsd_committer freebsd_triage 2017-10-31 15:26:32 UTC
A commit references this bug:

Author: madpilot
Date: Tue Oct 31 15:26:06 UTC 2017
New revision: 453242
URL: https://svnweb.freebsd.org/changeset/ports/453242

Log:
  - Really fix build when IPV6 option is disabled
  - Correctly rename patch file

  PR:		223288
  Submitted by:	Piotr Kubaj <pkubaj@anongoth.pl> (maintainer)
  Reported by:	edgeman@gmail.com

Changes:
  head/www/lighttpd/files/patch-patch-src__network.c
  head/www/lighttpd/files/patch-src_network.c
Comment 10 Guido Falsi freebsd_committer freebsd_triage 2017-10-31 15:28:31 UTC
Fix committed.

The last patch you posted still contained errors, #elif in place of #else and ipv in place of ipv4.

Anyway I did an hasty job on my previous commit which is all my fault.

I committed a fixed version of the patch.
Comment 11 edgeman 2017-10-31 16:08:40 UTC
Builds for me now. Thanks!