Opened 4 years ago

Closed 4 years ago

Last modified 2 years ago

#60936 closed defect (fixed)

unbound @1.11.0 does not build on PPC Tiger, Mac OS X 10.4.11, because of error: 'IPV6_TCLASS' undeclared

Reported by: ballapete (Peter "Pete" Dyballa) Owned by: kencu (Ken)
Priority: Normal Milestone:
Component: ports Version: 2.6.3
Keywords: tiger Cc: snc@…, iefdev (Eric F)
Port: unbound

Description

libtool: compile:  /opt/local/bin/gcc-apple-4.2 -I. -I/opt/local/include -I/opt/local/include -I/opt/local/include -DSRCDIR=. -pipe -Os -arch ppc -D_THREAD_SAFE -pthread -c services/listen_dnsport.c  -fno-common -DPIC -o .libs/listen_dnsport.o
services/listen_dnsport.c: In function 'set_ip_dscp':
services/listen_dnsport.c:887: error: 'IPV6_TCLASS' undeclared (first use in this function)
services/listen_dnsport.c:887: error: (Each undeclared identifier is reported only once
services/listen_dnsport.c:887: error: for each function it appears in.)
make: *** [listen_dnsport.lo] Error 1
make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_unbound/unbound/work/unbound-1.11.0'
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_unbound/unbound/work/unbound-1.11.0" && /usr/bin/make -w all
Exit code: 2

Tiger does not have 'IPV6_TCLASS' defined in /usr/include/netinet6/in6.h. The IPV6_* definitions vary on Tiger from recent macOS. It also seems to be missing on Leopard, Mac OS X 10.5.x – a PowerPC only issue?

Attachments (4)

main.log (74.8 KB) - added by ballapete (Peter "Pete" Dyballa) 4 years ago.
Main.log from PPC Tiger
main.2.log (84.0 KB) - added by ballapete (Peter "Pete" Dyballa) 4 years ago.
Main.log from PPC Leopard
main.3.log (81.5 KB) - added by ballapete (Peter "Pete" Dyballa) 4 years ago.
Main.log from PPC Tiger for unbound @1.12.0_1
main.4.log (78.7 KB) - added by ballapete (Peter "Pete" Dyballa) 4 years ago.
Main.log from PPC Leopard for unbound @1.12.0_1

Download all attachments as: .zip

Change History (24)

Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Attachment: main.log added

Main.log from PPC Tiger

comment:1 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

The same failure happens on PPC Leopard, Mac OS X 10.5.8. Its /usr/include/netinet6/in6.h similar to Tiger's version.

Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Attachment: main.2.log added

Main.log from PPC Leopard

comment:2 Changed 4 years ago by iefdev (Eric F)

Cc: iefdev added

comment:3 Changed 4 years ago by iefdev (Eric F)

Try upgrade to latest. 10.5_ppc is green here: https://ports.macports.org/port/unbound/summary

comment:4 in reply to:  3 ; Changed 4 years ago by jmroot (Joshua Root)

Replying to iefdev:

10.5_ppc is green here: https://ports.macports.org/port/unbound/summary

The latest build was for version 1.9.0.

comment:5 in reply to:  3 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Replying to iefdev:

Try upgrade to latest. 10.5_ppc is green here: https://ports.macports.org/port/unbound/summary

On PPC Tiger, Mac OS X 10.4.11, I get:

./libtool --tag=CC --mode=compile /opt/local/bin/gcc-apple-4.2 -I. -I/opt/local/include -I/opt/local/include -I/opt/local/include -DSRCDIR=. -pipe -Os -arch ppc -D_THREAD_SAFE -pthread -I/opt/local/include  -o listen_dnsport.lo -c services/listen_dnsport.c
libtool: compile:  /opt/local/bin/gcc-apple-4.2 -I. -I/opt/local/include -I/opt/local/include -I/opt/local/include -DSRCDIR=. -pipe -Os -arch ppc -D_THREAD_SAFE -pthread -I/opt/local/include -c services/listen_dnsport.c  -fno-common -DPIC -o .libs/listen_dnsport.o
services/listen_dnsport.c: In function 'set_ip_dscp':
services/listen_dnsport.c:825: error: 'IPV6_TCLASS' undeclared (first use in this function)
services/listen_dnsport.c:825: error: (Each undeclared identifier is reported only once
services/listen_dnsport.c:825: error: for each function it appears in.)
make: *** [listen_dnsport.lo] Error 1
make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_unbound/unbound/work/unbound-1.12.0'

I'll try tomorrow on Leopard, Mac OS X 10.5.8.

Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Attachment: main.3.log added

Main.log from PPC Tiger for unbound @1.12.0_1

comment:6 in reply to:  3 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Replying to iefdev:

Try upgrade to latest. 10.5_ppc is green here: https://ports.macports.org/port/unbound/summary

Here's the end of the Leopard build:

./libtool --tag=CC --mode=compile /usr/bin/gcc-4.2 -I. -I/opt/local/include -I/opt/local/include -I/opt/local/include -DSRCDIR=. -pipe -Os -arch ppc -D_THREAD_SAFE -pthread -I/opt/local/include  -o listen_dnsport.lo -c services/listen_dnsport.c
libtool: compile:  /usr/bin/gcc-4.2 -I. -I/opt/local/include -I/opt/local/include -I/opt/local/include -DSRCDIR=. -pipe -Os -arch ppc -D_THREAD_SAFE -pthread -I/opt/local/include -c services/listen_dnsport.c  -fno-common -DPIC -o .libs/listen_dnsport.o
services/listen_dnsport.c: In function ‘set_ip_dscp’:
services/listen_dnsport.c:825: error: ‘IPV6_TCLASS’ undeclared (first use in this function)
services/listen_dnsport.c:825: error: (Each undeclared identifier is reported only once
services/listen_dnsport.c:825: error: for each function it appears in.)
make: *** [listen_dnsport.lo] Error 1
make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_unbound/unbound/work/unbound-1.12.0'
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_net_unbound/unbound/work/unbound-1.12.0" && /usr/bin/make -w all 

Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Attachment: main.4.log added

Main.log from PPC Leopard for unbound @1.12.0_1

comment:7 Changed 4 years ago by iefdev (Eric F)

I tried building using the same compilers and they built, so I guess it's not that.

I don't know if this is related, but this differed from my log:

:info:configure checking for -force_load linker flag... ld: unknown option: -force_load
:info:configure no

On my system: IPV6_TCLASS is in <netinet6/in6.h> if that helps.

Line 
428/* APPLE: NOTE the value of those 2 options is kept unchanged from
429 *        previous version of darwin/OS X for binary compatibility reasons
430 *        and differ from FreeBSD (values 57 and 61). See below.
431 */
432#define IPV6_RECVTCLASS         35 /* bool; recv traffic class values */
433#define IPV6_TCLASS             36 /* int; send traffic class value */

It's not in netinet6/in6.h.auto.html (via 10.5.8)

Perhaps it renamed, moved or somewhere else?

comment:8 in reply to:  4 Changed 4 years ago by iefdev (Eric F)

Replying to jmroot:

Replying to iefdev:

10.5_ppc is green here: https://ports.macports.org/port/unbound/summary

The latest build was for version 1.9.0.

You mean on ports.macports.org? When I checked earlier, just after we removed the legacysupport, it was in red (10.5/6) - and then turned green a bit later. I thought it reflected the current status.

comment:9 in reply to:  7 Changed 4 years ago by iefdev (Eric F)

Replying to iefdev:

It's not in netinet6/in6.h.auto.html (via 10.5.8)

Perhaps it renamed, moved or somewhere else?

If it's missing, maybe it's something that could/should be added to the legacy-support?

comment:10 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

On my PPC Leopard (no snow), Mac OS X 10.5.8, with Xcode 3.1.4, I have:

pete 220 /\ l `loc in6.h`
-rw-r--r--  1 root  wheel  18408 20 Sep  2007 /Developer/SDKs/MacOSX10.4u.sdk/System/Library/Frameworks/Kernel.framework/Versions/A/Headers/netinet6/in6.h
-rw-r--r--  1 root  wheel  18278 20 Sep  2007 /Developer/SDKs/MacOSX10.4u.sdk/usr/include/netinet6/in6.h
-rw-r--r--  1 root  wheel  18872 25 Mär  2008 /Developer/SDKs/MacOSX10.5.sdk/System/Library/Frameworks/Kernel.framework/Versions/A/Headers/netinet6/in6.h
-rw-r--r--  1 root  wheel  18800 25 Mär  2008 /Developer/SDKs/MacOSX10.5.sdk/usr/include/netinet6/in6.h
-rw-r--r--  1 root  wheel  18872 25 Mär  2008 /System/Library/Frameworks/Kernel.framework/Versions/A/Headers/netinet6/in6.h
-r--r--r--  1 root  wheel  18800 25 Mär  2008 /usr/include/netinet6/in6.h
pete 221 /\ grep -n IPV6_TCLASS `loc in6.h`
Exit 1
ete 222 /\ find /Developer/SDKs /usr/include /opt/local -type f -name "*.h" -exec grep -n IPV6_TCLASS {} /dev/null \;
find: /opt/local/etc/polkit-1/rules.d: Permission denied
find: /opt/local/var/macports/home/.subversion/auth: Permission denied
find: /opt/local/var/run/openldap-data: Permission denied

        Time spent in user mode   (CPU seconds) : 82.268s
        Time spent in kernel mode (CPU seconds) : 339.827s
        Total time                              : 13:14.59s
        CPU utilisation (percentage)            : 53.1%
Exit 1
checking for -force_load linker flag... ld: unknown option: -force_load
no

is something I get regularly. Details:

configure:7237: checking for ld used by /usr/bin/gcc-4.2
configure:7304: result: /usr/libexec/gcc/powerpc-apple-darwin9/4.2.1/ld
configure:7311: checking if the linker (/usr/libexec/gcc/powerpc-apple-darwin9/4.2.1/ld) is GNU ld
configure:7326: result: no
pete 227 /\ l /usr/libexec/gcc/powerpc-apple-darwin9/4.2.1/ld
lrwxr-xr-x  1 root  wheel  18 17 Jan  2013 /usr/libexec/gcc/powerpc-apple-darwin9/4.2.1/ld -> ../../../../bin/ld
pete 228 /\ l -L /usr/libexec/gcc/powerpc-apple-darwin9/4.2.1/ld
-rwxr-xr-x  1 root  wheel  2622416 12 Jul  2008 /usr/libexec/gcc/powerpc-apple-darwin9/4.2.1/ld
pete 229 /\ /usr/libexec/gcc/powerpc-apple-darwin9/4.2.1/ld -v
@(#)PROGRAM:ld  PROJECT:ld64-85.2.1

comment:11 Changed 4 years ago by kencu (Ken)

That's not a problem:

checking for -force_load linker flag... ld: unknown option: -force_load
no

it checks for the flag, doesn't find it supported, moves on, doesn't use it. That is how it is supposed to work.

Does anyone need unbound on Leopard and Tiger? If so, I can take a look at seeing if it is fixable...

comment:12 in reply to:  11 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Replying to kencu:

Does anyone need unbound on Leopard and Tiger? If so, I can take a look at seeing if it is fixable...

GnuTLS needs it, while in turn wget und GnuPG2 need GnuTLS.

comment:13 Changed 4 years ago by kencu (Ken)

working on it.

BTW, looks like only the +dane variant of gnutls needs unbound, which I don't use, and I guess this is why I never have seen this.

What does the dane variant give you? Perhaps you don't need it?

Anyway, fix coming shortly.

comment:14 Changed 4 years ago by kencu (Ken)

Owner: set to kencu
Resolution: fixed
Status: newclosed

In 7add395fc57b540d7f3698759ff8d7bb2a37966b/macports-ports (master):

unbound: add missing ipv6 definition

fixes build on < 10.6
closes: #60936

comment:15 in reply to:  13 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

Replying to kencu:

What does the dane variant give you? Perhaps you don't need it?

DANE is an extension for HTTPS to handle self-signed certificates of a web server with the help of Certificate Authorities (CA). The web server can tell which CAs to trust. I am not sure whether it is still useful today… (or more needed than ever)

comment:16 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

unbound @1.12.0_1 built successfully on PPC Leopard, Mac OS X 10.5.8. make check does not report a single failure.

comment:17 in reply to:  16 Changed 4 years ago by iefdev (Eric F)

Replying to ballapete:

unbound @1.12.0_1 built successfully on PPC Leopard, Mac OS X 10.5.8. make check does not report a single failure.

Great to hear. Did it work on 10.4 as well?

still have my old G4 I maybe could use it on

comment:18 Changed 4 years ago by kencu (Ken)

for me it did equally well on the test suite on 10.4 PPC.

I'm not sure if the specific thing that was fixed by the patch was tested, however. It's an IPV6 thing, and so -- seemingly -- optional I guess. Glad that works for you.

To find the missing define, I don't do anything too fancy -- just look in a newer SDK with "the silver searcher" and see what it is supposed to be.

This fix could be added to the proper header in legacysupport, indeed, if there is more than just this one use of it in the ports tree. (and once we fix legacysupport 1.1 to work properly, which it presently does not, it appears).

comment:19 Changed 4 years ago by ballapete (Peter "Pete" Dyballa)

test OK here on PCC Tiger too.

comment:20 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)

With unbound @1.17.0_0 the file services/listen_dnsport.c is being patched so that it compiles. In the end the port builds and so this ticket can be closed.

Note: See TracTickets for help on using tickets.