NetBSD Problem Report #53381

From www@NetBSD.org  Mon Jun 18 03:59:13 2018
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 8BC7B7A1B5
	for <gnats-bugs@gnats.NetBSD.org>; Mon, 18 Jun 2018 03:59:13 +0000 (UTC)
Message-Id: <20180618035912.59EAA7A26B@mollari.NetBSD.org>
Date: Mon, 18 Jun 2018 03:59:12 +0000 (UTC)
From: santhosh.raju@gmail.com
Reply-To: santhosh.raju@gmail.com
To: gnats-bugs@NetBSD.org
Subject: audio/pulseaudio: build is broken in FreeBSD 11.1-RELEASE
X-Send-Pr-Version: www-1.0

>Number:         53381
>Category:       pkg
>Synopsis:       audio/pulseaudio: build is broken in FreeBSD 11.1-RELEASE
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-pkg-people
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jun 18 04:00:00 +0000 2018
>Closed-Date:    Sat Jul 07 14:13:44 +0000 2018
>Last-Modified:  Sat Jul 07 14:13:44 +0000 2018
>Originator:     Santhosh Raju
>Release:        pkgsrc-current
>Organization:
>Environment:
FreeBSD fox.trouble.is 11.1-RELEASE-p10 FreeBSD 11.1-RELEASE-p10 #0: Tue May  8 05:21:56 UTC 2018     root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC  amd64
>Description:
pulseaudio fails to build via pkgsrc when run in FreeBSD 11.1-RELEASE. It fails with a message regarding undefined references to various structs.

Partial build output:

gmake[3]: Entering directory '/usr/pkgsrc/audio/pulseaudio/work/pulseaudio-11.1/src'
  CCLD     libprotocol-cli.la
  CCLD     module-cli.la
  CCLD     module-simple-protocol-tcp.la
  CCLD     module-device-manager.la
  CCLD     module-device-restore.la
  CCLD     module-stream-restore.la
  CCLD     module-oss.la
  CC       modules/raop/libraop_la-raop-client.lo
modules/raop/raop-client.c:666:12: warning: cast from 'const uint8_t *' (aka 'const unsigned char *') to 'uint32_t *' (aka 'unsigned int *') increases required alignment from 1 to 4
      [-Wcast-align]
    data = (uint32_t *) (packet + sizeof(udp_timing_header));
           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
modules/raop/raop-client.c:685:24: error: variable has incomplete type 'struct sockaddr_in'
    struct sockaddr_in sa4;
                       ^
modules/raop/raop-client.c:685:12: note: forward declaration of 'struct sockaddr_in'
    struct sockaddr_in sa4;

...

Makefile:625: recipe for target 'all' failed
gmake: *** [all] Error 2
*** Error code 2

Stop.
>How-To-Repeat:
1. Get current pkgsrc via CVS 
2. Prepare and bootstrap pkgsrc in FreeBSD 11.1-RELEASE
3. cd audio/pulseaudio && bmake
4. After sometime the build fails with the error mentioned in the "Full description"
>Fix:
Added the missing network headers for FreeBSD 11.1.

Steps to fix

1. Apply the following patch in audio/pulseaudio 

--- src/modules/raop/raop-client.h.orig 2018-06-17 16:45:13.878136000 +0000
+++ src/modules/raop/raop-client.h
@@ -26,6 +26,11 @@
 #include <pulsecore/memchunk.h>
 #include <pulsecore/rtpoll.h>

+#if defined (__FreeBSD__)
+#include <sys/socket.h>
+#include <netinet/in.h>
+#endif
+
 typedef enum pa_raop_protocol {
     PA_RAOP_PROTOCOL_TCP,
     PA_RAOP_PROTOCOL_UDP

>Release-Note:

>Audit-Trail:

Responsible-Changed-From-To: pkg-manager->freebsd-pkg-people
Responsible-Changed-By: hauke@NetBSD.org
Responsible-Changed-When: Mon, 18 Jun 2018 18:00:43 +0000
Responsible-Changed-Why:
FreeBSD issue.


From: "Maya Rashish" <maya@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/53381 CVS commit: pkgsrc/audio/pulseaudio
Date: Tue, 19 Jun 2018 02:25:59 +0000

 Module Name:	pkgsrc
 Committed By:	maya
 Date:		Tue Jun 19 02:25:58 UTC 2018

 Modified Files:
 	pkgsrc/audio/pulseaudio: distinfo
 Added Files:
 	pkgsrc/audio/pulseaudio/patches: patch-src_modules_raop_raop-client.h

 Log Message:
 pulseaudio: fix build on FreeBSD11. Include missing headers.

 From Santhosh Raju in PR pkg/53381


 To generate a diff of this commit:
 cvs rdiff -u -r1.64 -r1.65 pkgsrc/audio/pulseaudio/distinfo
 cvs rdiff -u -r0 -r1.1 \
     pkgsrc/audio/pulseaudio/patches/patch-src_modules_raop_raop-client.h

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

State-Changed-From-To: open->needs-pullups
State-Changed-By: maya@NetBSD.org
State-Changed-When: Tue, 19 Jun 2018 02:54:52 +0000
State-Changed-Why:
Document my laziness with regards to pullups.
(So it can be closed once 2018Q2 comes around)


State-Changed-From-To: needs-pullups->closed
State-Changed-By: maya@NetBSD.org
State-Changed-When: Sat, 07 Jul 2018 14:13:44 +0000
State-Changed-Why:
2018Q2 out, including this fix. (older is not supported)


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.