NetBSD Problem Report #57070

From  Sun Oct 23 21:45:29 2022
Return-Path: <>
Received: from ( [])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	(Client CN "", Issuer " CA" (not verified))
	by (Postfix) with ESMTPS id 1252E1A921F
	for <>; Sun, 23 Oct 2022 21:45:29 +0000 (UTC)
Message-Id: <>
Date: Sun, 23 Oct 2022 21:45:19 GMT
Subject: multimedia/handbrake doesn't build
X-Send-Pr-Version: 3.95

>Number:         57070
>Category:       pkg
>Synopsis:       multimedia/handbrake doesn't build on NetBSD
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Oct 23 21:50:00 +0000 2022
>Closed-Date:    Sun Apr 09 18:24:39 +0000 2023
>Last-Modified:  Sun Apr 09 18:24:39 +0000 2023
>Originator:     John Klos
>Release:        NetBSD 9.2_STABLE


System: NetBSD 9.2_STABLE NetBSD 9.2_STABLE (DAISY) #0: Sun Mar 13 01:23:07 UTC 2022 amd64
Architecture: x86_64
Machine: amd64

On NetBSD 9.2/amd64 with pkgsrc from today (23-Oct-2022), multimedia/handbrake fails:
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile
config.status: executing libtool commands
touch gtk/.stamp.configure
*** Error code 2

make[1]: stopped in /usr/pkgsrc/multimedia/handbrake
*** Error code 1

with options -gtk3, it fails differently:
../libhb/lang.c:291:35: warning: array subscript has type 'char' [-Wchar-subscripts]
  291 |     code_string[2] = tolower( code[2] );
      |                                   ^
../libhb/hb.c:18:10: fatal error: turbojpeg.h: No such file or directory
   18 | #include <turbojpeg.h>
      |          ^~~~~~~~~~~~~
compilation terminated.
gmake: *** [../libhb/module.rules:12: libhb/hb.o] Error 1
gmake: *** Waiting for unfinished jobs....
*** Error code 2

make[1]: stopped in /usr/pkgsrc/multimedia/handbrake
*** Error code 1




From: Iain Hibbert <>
Subject: Re: pkg/57070 multimedia/handbrake doesn't build
Date: Sat, 8 Apr 2023 12:44:50 +0100 (BST)


 This failure is because handbrake requires libjpeg-turbo and the file does not select it correctly:

 % cd /usr/pkgsrc/multimedia/handbrake
 % make -V '${JPEG_DEFAULT}' -V '${JPEG_ACCEPTED}' -V '${JPEG_TYPE}'

 This I guessed was because the tiff file has already 
 included before JPEG_ACCEPTED is set. However, setting 
 that explicitly still does not work:

 % make JPEG_ACCEPTED=libjpeg-turbo -V '${JPEG_DEFAULT}' -V '${JPEG_ACCEPTED}' -V '${JPEG_TYPE}'

 So there are cascading failures here which I did not follow as I see that 
 it cannot work anyway, as graphics/jpeg and graphics/libjpeg-turbo are 
 conflicting, so in fact a package cannot really define JPEG_ACCEPTED until 
 the conflict is overcome.

 (multimedia/handbrake is the only package which defines JPEG_ACCEPTED)

 Adding JPEG_DEFAULT=libjpeg-turbo to /etc/mk.conf will allow handbrake to 
 build successfully. However, you may need to rebuild all your packages in 
 that case.

 I have not looked in detail but see that handbrake internally has a 
 libjpeg-turbo module, which is possibly built as static and linked right 
 in, perhaps that would be a better solution


From: "Iain Hibbert" <>
Subject: PR/57070 CVS commit: pkgsrc/multimedia/handbrake
Date: Sun, 9 Apr 2023 08:57:20 +0000

 Module Name:	pkgsrc
 Committed By:	plunky
 Date:		Sun Apr  9 08:57:19 UTC 2023

 Modified Files:
 	pkgsrc/multimedia/handbrake: Makefile distinfo
 	pkgsrc/multimedia/handbrake/patches: patch-make-include-main.defs

 Log Message:
 fix build

 HandBrake requires libjpeg-turbo, and as this conflicts with the default libjpeg
 which is used by gtk3, remove the jpeg dependency and provide libjpeg-turbo
 directly, which will be linked statically.

 fixes PR#57070

 To generate a diff of this commit:
 cvs rdiff -u -r1.90 -r1.91 pkgsrc/multimedia/handbrake/Makefile
 cvs rdiff -u -r1.17 -r1.18 pkgsrc/multimedia/handbrake/distinfo
 cvs rdiff -u -r1.3 -r1.4 \

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

State-Changed-From-To: open->closed
State-Changed-When: Sun, 09 Apr 2023 18:24:39 +0000
fixed the issue


NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.47 2022/09/11 19:34:41 kim Exp $
$NetBSD:,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2023 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.