pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/43641: [net/mDNSResponder] build failure on DragonFly



>Number:         43641
>Category:       pkg
>Synopsis:       [net/mDNSResponder] build failure on DragonFly
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jul 19 13:25:00 +0000 2010
>Originator:     Tero Jääskö
>Release:        
>Organization:
>Environment:
DragonFly korento.muumilaakso 2.7-DEVELOPMENT DragonFly 
v2.7.3.340.gfb86e-DEVELOPMENT #29: Mon Jul 19 11:53:45 EEST 2010 
tero%korento.muumilaakso@localhost:/usr/obj/usr/src/sys/64_smp x86_64
>Description:
net/mDNSResponder fails to build on DragonFly system with the error message 
below. There is also one open PR #43620 on same package, but with different 
error and platform, so I dared to open a new PR.

----------------
gmake[1]: Entering directory 
`/usr/pkgsrc/net/mDNSResponder/work/mDNSResponder-214.3.2/Clients'
mkdir build
cc dns-sd.c ClientCommon.c -L../mDNSPosix/build/prod/ -ldns_sd -L/usr/lib 
-Wl,-R/usr/lib -Wl,-R/usr/pkg/lib -I../mDNSShared -Wall -o build/dns-sd
gmake[1]: Leaving directory 
`/usr/pkgsrc/net/mDNSResponder/work/mDNSResponder-214.3.2/Clients'
Clients done
Embedded Standalone Client done
Embedded Standalone Responder done
Embedded Standalone ProxyResponder done
Identify done
NetMonitor done
In file included from ../mDNSShared/DebugServices.h:50,
                 from ../mDNSShared/dnsextd_parser.y:56:
../mDNSShared/CommonServices.h:267:22: error: vxWorks.h: No such file or 
directory
In file included from ../mDNSShared/dnsextd_parser.y:56:
../mDNSShared/DebugServices.h:53:21: error: logLib.h: No such file or directory
In file included from ../mDNSShared/dnsextd.h:49,
                 from ../mDNSShared/dnsextd_parser.y:57:
/usr/include/sys/socket.h:65: error: conflicting types for 'socklen_t'
../mDNSShared/CommonServices.h:502: error: previous declaration of 'socklen_t' 
was here
In file included from ../mDNSShared/dnsextd.h:50,
                 from ../mDNSShared/dnsextd_parser.y:57:
/usr/include/netinet/in.h:313: error: redefinition of 'struct sockaddr_in'
../mDNSShared/dnsextd_parser.y: In function 'SetupOptions':
../mDNSShared/dnsextd_parser.y:591: warning: implicit declaration of function 
'inet_pton'
gmake: *** [objects/prod/dnsextd_parser.y.o] Error 1
*** Error code 2

Stop.
bmake: stopped in /usr/pkgsrc/net/mDNSResponder
*** Error code 1

Stop.
bmake: stopped in /usr/pkgsrc/net/mDNSResponder
----------------
>How-To-Repeat:
cd net/mDNSResponder
bmake
>Fix:
Separate patch:

--- mDNSShared/CommonServices.h.orig    2010-07-19 15:22:05 +0300
+++ mDNSShared/CommonServices.h 2010-07-19 15:22:47 +0300
@@ -112,6 +112,17 @@
        #endif
 #endif
 
+// DragonFly BSD
+
+#if( !defined( TARGET_OS_DRAGONFLY ) )
+       #if( defined( __DragonFly__ ) )
+               #define TARGET_OS_DRAGONFLY             1
+       #else
+               #define TARGET_OS_DRAGONFLY             0
+       #endif
+#endif
+
+
 // Solaris
 
 #if( !defined( TARGET_OS_SOLARIS ) )
@@ -138,7 +149,7 @@
        
        // No predefined macro for VxWorks so just assume VxWorks if nothing 
else is set.
        
-       #if( !macintosh && !__MACH__  && !defined( __linux__ ) && !defined ( 
__SVR4 ) && !defined ( __sun ) && !defined( __PALMOS_TRAPS__ ) && !defined( 
__PALMOS_ARMLET__ ) && !defined( _WIN32 ) && !defined(__NetBSD__))
+       #if( !macintosh && !__MACH__  && !defined( __linux__ ) && !defined ( 
__SVR4 ) && !defined ( __sun ) && !defined( __PALMOS_TRAPS__ ) && !defined( 
__PALMOS_ARMLET__ ) && !defined( _WIN32 ) && !defined(__NetBSD__) && 
!defined(__DragonFly__))
                #define TARGET_OS_VXWORKS               1
        #else
                #define TARGET_OS_VXWORKS               0
@@ -240,6 +251,13 @@
 
        #include        <arpa/inet.h>
 
+#elif ( TARGET_OS_DRAGONFLY )
+
+       // DragonFly
+
+       #include        <arpa/inet.h>
+       #include        <sys/socket.h> // for AF_INET6 definition, used later 
on ifdefs
+
 #elif( TARGET_OS_SOLARIS )
        
        // Solaris
@@ -509,7 +527,7 @@
 // - Windows
 
 #if( TARGET_LANGUAGE_C_LIKE )
-       #if( !defined(_SSIZE_T) && ( TARGET_OS_WIN32 || !defined( 
_BSD_SSIZE_T_DEFINED_ ) ) && !TARGET_OS_LINUX && !TARGET_OS_VXWORKS && 
!TARGET_OS_MAC && !TARGET_OS_NETBSD)
+       #if( !defined(_SSIZE_T) && ( TARGET_OS_WIN32 || !defined( 
_BSD_SSIZE_T_DEFINED_ ) ) && !TARGET_OS_LINUX && !TARGET_OS_VXWORKS && 
!TARGET_OS_MAC && !TARGET_OS_NETBSD && !TARGET_OS_DRAGONFLY)
                typedef int                                             ssize_t;
        #endif
 #endif

------------------

Here is an attempt to create a complete patch against pkgsrc git:

------------------

diff --git a/net/mDNSResponder/distinfo b/net/mDNSResponder/distinfo
index 2b0823b..39830bd 100644
--- a/net/mDNSResponder/distinfo
+++ b/net/mDNSResponder/distinfo
@@ -8,3 +8,4 @@ SHA1 (patch-ab) = 712e3999854215b9ea14f6d444262beef8c545b1
 SHA1 (patch-ac) = 60fd50c011dc086b6763fef617ab5f78c8ecc6b5
 SHA1 (patch-ad) = fa77b934a63bd07f9b0a4697a3c1a59d242fca19
 SHA1 (patch-ae) = ff7897253de50ac9afd1c1fd15fe73d99c4be47d
+SHA1 (patch-af) = 7d3caf9023a6d76e538585f3317870b69beef92b
diff --git a/net/mDNSResponder/patches/patch-af 
b/net/mDNSResponder/patches/patch-af
new file mode 100644
index 0000000..3b19e50
--- /dev/null
+++ b/net/mDNSResponder/patches/patch-af
@@ -0,0 +1,54 @@
+$NetBSD$
+
+--- mDNSShared/CommonServices.h.orig   2010-07-19 11:58:10 +0000
++++ mDNSShared/CommonServices.h
+@@ -112,6 +112,17 @@ Common Services and portability support 
+       #endif
+ #endif
+ 
++// DragonFly BSD
++
++#if( !defined( TARGET_OS_DRAGONFLY ) )
++      #if( defined( __DragonFly__ ) )
++              #define TARGET_OS_DRAGONFLY             1
++      #else
++              #define TARGET_OS_DRAGONFLY             0
++      #endif
++#endif
++
++
+ // Solaris
+ 
+ #if( !defined( TARGET_OS_SOLARIS ) )
+@@ -138,7 +149,7 @@ Common Services and portability support 
+       
+       // No predefined macro for VxWorks so just assume VxWorks if nothing 
else is set.
+       
+-      #if( !macintosh && !__MACH__  && !defined( __linux__ ) && !defined ( 
__SVR4 ) && !defined ( __sun ) && !defined( __PALMOS_TRAPS__ ) && !defined( 
__PALMOS_ARMLET__ ) && !defined( _WIN32 ) && !defined(__NetBSD__))
++      #if( !macintosh && !__MACH__  && !defined( __linux__ ) && !defined ( 
__SVR4 ) && !defined ( __sun ) && !defined( __PALMOS_TRAPS__ ) && !defined( 
__PALMOS_ARMLET__ ) && !defined( _WIN32 ) && !defined(__NetBSD__) && 
!defined(__DragonFly__))
+               #define TARGET_OS_VXWORKS               1
+       #else
+               #define TARGET_OS_VXWORKS               0
+@@ -240,6 +251,13 @@ Common Services and portability support 
+ 
+       #include        <arpa/inet.h>
+ 
++#elif ( TARGET_OS_DRAGONFLY )
++
++      // DragonFly
++
++      #include        <arpa/inet.h>
++      #include        <sys/socket.h> // for AF_INET6 definition, used later 
on ifdefs
++
+ #elif( TARGET_OS_SOLARIS )
+       
+       // Solaris
+@@ -509,7 +527,7 @@ Common Services and portability support 
+ // - Windows
+ 
+ #if( TARGET_LANGUAGE_C_LIKE )
+-      #if( !defined(_SSIZE_T) && ( TARGET_OS_WIN32 || !defined( 
_BSD_SSIZE_T_DEFINED_ ) ) && !TARGET_OS_LINUX && !TARGET_OS_VXWORKS && 
!TARGET_OS_MAC && !TARGET_OS_NETBSD)
++      #if( !defined(_SSIZE_T) && ( TARGET_OS_WIN32 || !defined( 
_BSD_SSIZE_T_DEFINED_ ) ) && !TARGET_OS_LINUX && !TARGET_OS_VXWORKS && 
!TARGET_OS_MAC && !TARGET_OS_NETBSD && !TARGET_OS_DRAGONFLY)
+               typedef int                                             ssize_t;
+       #endif
+ #endif



Home | Main Index | Thread Index | Old Index