pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/36811: net/irrd fails to build without ipv6 infrastructure
>Number: 36811
>Category: pkg
>Synopsis: net/irrd fails to build without ipv6 infrastructure
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Aug 21 10:10:00 +0000 2007
>Originator: Yakovetsky Vladimir
>Release: NetBSD 4.0_BETA2
>Organization:
>Environment:
System: NetBSD darg.x.ua 4.0_BETA2 NetBSD 4.0_BETA2 (darg-1.799.2.7-mp-1.8.8.1)
#1: Tue Jul 24 16:42:00 EEST 2007
yx%darg.x.ua@localhost:/sys/arch/i386/compile/darg.mp i386
Architecture: i386
Machine: i386
>Description:
net/irrd problems:
- fails to build without ipv6 infrastructure.
- partial threads preconfiguring.
>How-To-Repeat:
("fails to build" for example)
% uname -sr
NetBSD 4.0_BETA2
% grep -i inet6 /etc/mk.conf
MKINET6= no
PKG_DEFAULT_OPTIONS+= -inet6
% nm -o --defined-only /usr/lib/*so* | grep in6addr || echo 'not found'
not found
% cd /usr/pkgsrc/net/irrd
% make -V USE_INET6
NO
% make update
...
The following variables will affect the build process of this package,
irrd-2.2.8nb2. Their current value is shown below:
* USE_INET6 = NO
...
cc -Wl,-R/usr/pkg/lib main.o telnet.o scan.o config.o commands.o database.o
update.o mirror.o uii_commands.o journal.o indicies.o rpsl_commands.o route.o
hash_spec.o templates.o irrd_util.o mirrorstatus.o statusfile.o atomic_trans.o
../../lib/libmrt.a ../../lib/libcfg.a -o irrd -L../atomic_ops -latomic_ops
-L../compat -lcompat
telnet.o: In function `listen_telnet':
telnet.c:(.text+0x1be6): undefined reference to `in6addr_any'
telnet.c:(.text+0x1c08): undefined reference to `in6addr_any'
telnet.c:(.text+0x1c1d): undefined reference to `in6addr_any'
telnet.c:(.text+0x1c26): undefined reference to `in6addr_any'
*** Error code 1
Stop.
make: stopped in /usr/obj/net/irrd/work/irrd2.2.8/src/programs/IRRd
...
=> Automatic manual page handling
pkg_create: can't stat `/usr/pkg/sbin/irrd'
=> Registering installation for irrd-2.2.8nb2
pkg_admin: irrd-2.2.8nb2: File `/usr/pkg/sbin/irrd' is in +CONTENTS but not on
filesystem!
...
>Fix:
summary: `inet6' and `threads' preconfiguring.
- mk/defaults/options.description and net/irrd/Makefile - diffs
- net/irrd/options.mk, net/irrd/patches/patch-ad
and net/irrd/patches/patch-ae - new files
--- mk/defaults/options.description.~1~
+++ mk/defaults/options.description
@@ -173,6 +173,7 @@
ipa-without-thresholds Disable thresholds support.
ipfilter
iptables
+irrd-threads Enable threads support in irrd.
irssi-perl Enable Perl support in irssi.
ispell
jasper Enable JPEG 2000 support using the jasper library.
--- net/irrd/Makefile.~1~
+++ net/irrd/Makefile
@@ -2,7 +2,7 @@
DISTNAME= irrd2.2.8
PKGNAME= irrd-2.2.8
-PKGREVISION= 2
+PKGREVISION= 3
CATEGORIES= net
MASTER_SITES= http://www.irrd.net/ \
ftp://ftp.merit.edu/radb/irrd/ \
@@ -20,15 +20,7 @@
WRKSRC= ${WRKDIR}/${DISTNAME}/src
-#PTHREAD_AUTO_VARS= yes
-#PTHREAD_OPTS+= require
-
GNU_CONFIGURE= yes
-CONFIGURE_ARGS+= --disable-thread
-
-BUILD_DEFS+= USE_INET6
-
-#CPPFLAGS+= -I${LOCALBASE}/include
REPLACE_PERL+= programs/irrdcacher/irrdcacher
REPLACE_PERL+= programs/irrdcacher/ripe2rpsl
@@ -44,14 +36,6 @@
${INSTALL_SCRIPT} irrdcacher ${PREFIX}/sbin && \
${INSTALL_SCRIPT} ripe2rpsl ${PREFIX}/sbin
-.include "../../mk/bsd.prefs.mk"
-
-.if defined(USE_INET6) && ${USE_INET6} == "YES"
-# default
-# CONFIGURE_ARGS+= --enable-ipv6
-.else
-CONFIGURE_ARGS+= --disable-ipv6
-.endif
+.include "options.mk"
-#.include "../../mk/pthread.buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
:r net/irrd/options.mk
PKG_OPTIONS_VAR= PKG_OPTIONS.irrd
PKG_SUPPORTED_OPTIONS+= inet6 irrd-threads
.include "../../mk/bsd.options.mk"
.if !empty(PKG_OPTIONS:Minet6)
CPPFLAGS+= -DINET6
.endif
.if !empty(PKG_OPTIONS:Mirrd-threads)
CONFIGURE_ARGS+= --enable-thread
.else
# use author settings for threads
.endif
:r net/irrd/patches/patch-ad
--- configure.in.~1~
+++ configure.in
@@ -6,8 +6,10 @@
dnl what OS are we?
AC_CANONICAL_HOST
-dnl initializing defaults
+dnl initializing defaults, if have not --*able-thread option
dnl I've seen a report that pthread support is shaky in FreeBSD 2.x releases
+AC_ARG_ENABLE(thread,
+[ --enable-thread enable threads],,[
case "${host_os}" in
freebsd2* )
enable_thread=no
@@ -19,10 +21,7 @@
enable_thread=no
;;
esac
-
-AC_ARG_ENABLE(thread,
-[ --disable-thread disable thread always],
-)
+])
AC_ARG_ENABLE(wall,
[ --disable-wall disable -Wall option always],
@@ -47,7 +46,7 @@
EXTRA_INCLUDE_DIRS=""
EXTRA_LIBS=""
-CPPFLAGS="-DFUNCPROTO -I../../include"
+CPPFLAGS="$CPPFLAGS -DFUNCPROTO -I../../include"
dnl defining FUNCPROTO ensures that struct library uses portotype
dnl we don't expect non-ANSI (K&R) C compilers to be used
dnl Some compiles may define __STDC__ by itself which makes it enable,
@@ -78,7 +77,7 @@
QUANTIFY="quantify"
PURIFY="purify"
-AC_DEFUN(AC_FILE_EXIST, [
+AC_DEFUN([AC_FILE_EXIST], [
if test -f "$1" >/dev/null 2>&1; then
ifelse([$2], , :, [$2])
ifelse([$3], , , [else $3])
@@ -104,29 +103,26 @@
esac
case "${host_os}" in
- solaris* )
- CRYPT_LIB="-lcrypt"
- ;;
bsdi* )
LIBS="$LIBS -lipc"
;;
- freebsd*|netbsd*|openbsd* )
- if test "$enable_thread" = yes; then
- LDFLAGS="$LDFLAGS -pthread"
- THREAD_CFLAGS="-D_THREAD_SAFE -pthread"
- fi
+ solaris*|freebsd*|netbsd*|openbsd*|linux* )
CRYPT_LIB="-lcrypt"
case "${host_os}" in
- netbsd* )
- ;;
- * )
+ freebsd*|openbsd* )
+ if test "$enable_thread" = yes; then
+ LDFLAGS="$LDFLAGS -pthread"
+ THREAD_CFLAGS="-D_THREAD_SAFE -pthread"
+ fi
ac_pthrlib="c_r"
;;
+ netbsd* )
+ if test "$enable_thread" = yes; then
+ LDFLAGS="$LDFLAGS -lpthread"
+ fi
+ ;;
esac
;;
- linux* )
- CRYPT_LIB="-lcrypt"
- ;;
osf* )
if test $CC = "cc" ; then
CPPFLAGS="$CPPFLAGS -taso -pthread"
:r patches/patch-ae
--- include/defs.h.~1~
+++ include/defs.h
@@ -17,7 +17,7 @@
/* check for IPV6 support */
#ifdef AF_INET6
-#ifdef IN6_IS_ADDR_V4MAPPED
+#if defined(IN6_IS_ADDR_V4MAPPED) && defined(INET6)
#define HAVE_IPV6
#endif
#else
Home |
Main Index |
Thread Index |
Old Index