NetBSD Problem Report #46700

From Ephaeton@gmx.net  Fri Jul 13 15:59:17 2012
Return-Path: <Ephaeton@gmx.net>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
	by www.NetBSD.org (Postfix) with ESMTP id B2F1B63B85F
	for <gnats-bugs@gnats.NetBSD.org>; Fri, 13 Jul 2012 15:59:16 +0000 (UTC)
Message-Id: <20120713155910.20BF413631@agamemnon.entropie.local>
Date: Fri, 13 Jul 2012 11:59:10 -0400 (EDT)
From: Ephaeton@gmx.net
Reply-To: Ephaeton@gmx.net
To: gnats-bugs@gnats.NetBSD.org
Subject: pkgsrc-2012Q2 vlc2 won't build
X-Send-Pr-Version: 3.95

>Number:         46700
>Category:       pkg
>Synopsis:       pkgsrc-2012Q2 vlc2 won't build
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Jul 13 16:00:00 +0000 2012
>Closed-Date:    Mon Sep 02 15:18:25 +0000 2019
>Last-Modified:  Mon Sep 02 15:18:25 +0000 2019
>Originator:     Martin S. Weber
>Release:        NetBSD 5.1_STABLE
>Organization:

>Environment:


System: NetBSD agamemnon.entropie.local 5.1_STABLE NetBSD 5.1_STABLE (AGAMEMNON5) #3: Thu Dec 8 09:45:09 EST 2011 root@agamemnon.entropie.local:/space/obj/sys/arch/i386/compile/AGAMEMNON5 i386
Architecture: i386
Machine: i386
>Description:
vlc2 won't build because of an undeclared constant: O_DIRECTORY.
...
gnutls.c: In function 'gnutls_Addx509Directory':
gnutls.c:472: error: 'O_DIRECTORY' undeclared (first use in this function)
gnutls.c:472: error: (Each undeclared identifier is reported only once
gnutls.c:472: error: for each function it appears in.)
gmake[5]: *** [libgnutls_plugin_la-gnutls.lo] Error 1

O_DIRECTORY only exists in two files in my sources:
$ grep -lr O_DIRECTORY /space/obj/multimedia/vlc2/work/vlc-2.0.1/     
/space/obj/multimedia/vlc2/work/vlc-2.0.1/modules/access/dtv/linux.c
/space/obj/multimedia/vlc2/work/vlc-2.0.1/modules/misc/gnutls.c

Removing O_DIRECTORY makes the compilation continue, and as no other source
file mentions it, that might actually be the correct fix.


>How-To-Repeat:
get pkgsrc2012Q2 sources and try to build vlc2


>Fix:


>Release-Note:

>Audit-Trail:
From: Matthew Mondor <mm_lists@pulsar-zone.net>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/46700: pkgsrc-2012Q2 vlc2 won't build
Date: Sat, 14 Jul 2012 01:24:43 -0400

 On Fri, 13 Jul 2012 16:00:01 +0000 (UTC)
 Ephaeton@gmx.net wrote:

 > gnutls.c: In function 'gnutls_Addx509Directory':
 > gnutls.c:472: error: 'O_DIRECTORY' undeclared (first use in this function)
 > gnutls.c:472: error: (Each undeclared identifier is reported only once
 > gnutls.c:472: error: for each function it appears in.)
 > gmake[5]: *** [libgnutls_plugin_la-gnutls.lo] Error 1

 Just to provide more information to this PR: open(2) O_DIRECTORY
 (fcntl.h) was introduced in netbsd-6, it's possible that the new
 package needs a patch to also support netbsd-5
 -- 
 Matt

From: David Holland <dholland-pbugs@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/46700: pkgsrc-2012Q2 vlc2 won't build
Date: Sun, 15 Jul 2012 14:39:03 +0000

 On Fri, Jul 13, 2012 at 04:00:01PM +0000, Ephaeton@gmx.net wrote:
  > vlc2 won't build because of an undeclared constant: O_DIRECTORY.
  > ...
  > gnutls.c: In function 'gnutls_Addx509Directory':
  > gnutls.c:472: error: 'O_DIRECTORY' undeclared (first use in this function)
  > gnutls.c:472: error: (Each undeclared identifier is reported only once
  > gnutls.c:472: error: for each function it appears in.)
  > gmake[5]: *** [libgnutls_plugin_la-gnutls.lo] Error 1

 should be sufficient to insert

 #ifndef O_DIRECTORY
 #define O_DIRECTORY 0
 #endif

 -- 
 David A. Holland
 dholland@netbsd.org

State-Changed-From-To: open->closed
State-Changed-By: maya@NetBSD.org
State-Changed-When: Mon, 02 Sep 2019 15:18:25 +0000
State-Changed-Why:
wontfix for build issues for netbsd-5 today.


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.