Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 870217

Summary: app-text/xpdf-4.04-r1 - /.../ error: invalid conversion from const char to char [-fpermissive]
Product: Gentoo Linux Reporter: Toralf Förster <toralf>
Component: Current packagesAssignee: Andrew Savchenko <bircoph>
Severity: normal CC:, grozin, marcel.schilling, proteuss
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
See Also:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 888703    
Attachments: emerge-info.txt

Description Toralf Förster gentoo-dev 2022-09-15 13:11:47 UTC
too long lines were shrinked:

[48/135] /usr/bin/x86_64-pc-linux-gnu-g++  -I/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04 -I/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04_build -I/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04/goo -I/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04/fofi -I/var/tmp/portage/app-text/xp
FAILED: xpdf/CMakeFiles/xpdf_objs.dir/ 
/usr/bin/x86_64-pc-linux-gnu-g++  -I/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04 -I/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04_build -I/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04/goo -I/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04/fofi -I/var/tmp/portage/app-text/xpdf-4.04/w
/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04/xpdf/ In constructor GlobalParams::GlobalParams(const char*):
/var/tmp/portage/app-text/xpdf-4.04/work/xpdf-4.04/xpdf/ error: invalid conversion from const char* to char* [-fpermissive]
  661 |   if ((paperName = systempapername())) {
      |                    ~~~~~~~~~~~~~~~^~


  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1_desktop_plasma-j4-20220912-150005


gcc-config -l:
 [1] x86_64-pc-linux-gnu-9.3.1
 [2] x86_64-pc-linux-gnu-12.2.1 *
clang/llvm (if any):
clang version 15.0.0
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/15/bin
Python 3.10.7
Available Ruby profiles:
  (none found)
Available Rust versions:
  [1]   rust-bin-1.63.0 *
The following VMs are available for generation-2:
1)	OpenJDK 17.0.5_p5 [openjdk-17]
2)	OpenJDK 8.345_p01 [openjdk-8]
3)	Eclipse Temurin JDK [openjdk-bin-11]
*)	Eclipse Temurin JDK [openjdk-bin-17]
5)	Eclipse Temurin JDK 8.345_p01 [openjdk-bin-8]
6)	Eclipse Temurin JRE [openjdk-jre-bin-17]
Available Java Virtual Machines:
  [1]   openjdk-8 
  [2]   openjdk-17 
  [3]   openjdk-bin-8 
  [4]   openjdk-bin-11 
  [5]   openjdk-bin-17  system-vm
  [6]   openjdk-jre-bin-17 

The Glorious Glasgow Haskell Compilation System, version 9.0.2
php cli (if any):
  [1]   php8.1 *
GNU Make 4.3

  HEAD of ::gentoo
commit bd6e9f4da5656ab29c4d271408b8d3a6f1277704
Author: Repository mirror & CI <>
Date:   Thu Sep 15 11:01:56 2022 +0000

    2022-09-15 11:01:56 UTC

emerge -qpvO app-text/xpdf
[ebuild  N    ] app-text/xpdf-4.04  USE="cmyk cups fontconfig i18n icons libpaper metric opi png textselect -utils -verify-sig"
Comment 1 Toralf Förster gentoo-dev 2022-09-15 13:11:48 UTC
Created attachment 805306 [details]
Comment 2 Toralf Förster gentoo-dev 2022-09-15 13:11:49 UTC
Created attachment 805309 [details]
Comment 3 Toralf Förster gentoo-dev 2022-09-15 13:11:51 UTC
Created attachment 805312 [details]
Comment 4 Toralf Förster gentoo-dev 2022-09-15 13:11:52 UTC
Created attachment 805315 [details]
Comment 5 Toralf Förster gentoo-dev 2022-09-15 13:11:53 UTC
Created attachment 805318 [details]
Comment 6 Toralf Förster gentoo-dev 2022-09-15 13:11:55 UTC
Created attachment 805321 [details]
Comment 7 Toralf Förster gentoo-dev 2022-09-15 13:11:56 UTC
Created attachment 805324 [details]
Comment 8 Agostino Sarubbo gentoo-dev 2022-09-15 15:21:49 UTC
ci has reproduced this issue with version 4.04-r1 - Updating summary.
Comment 9 Helmut Jarausch 2022-09-17 13:45:46 UTC
Just add the following line to the src_prepare section of the ebuild

	sed -i "s/char \*paperName;/const char *paperName;/" xpdf/
Comment 10 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-09-17 13:47:30 UTC
A patch would be better.
Comment 11 Andrew Savchenko gentoo-dev 2022-09-18 08:40:17 UTC
(In reply to Helmut Jarausch from comment #9)
> Just add the following line to the src_prepare section of the ebuild
> 	sed -i "s/char \*paperName;/const char *paperName;/" xpdf/

This may break xpdf with older libpaper. I need to see what exactly changed there and patch will likely check libpaper version.
Comment 12 Marcel Schilling 2023-01-09 10:16:14 UTC
Just hit this in a world update: libpaper went from 1.x to 2.x, triggering a rebuild for xpdf which faileddue to this bug. Now depclean can't resolve the dependencies due to the incomplete world update. Any chance for this to get fixed in a timely fashion or should I rather look for an alternative?
Comment 13 Larry the Git Cow gentoo-dev 2023-01-09 10:16:33 UTC
The bug has been closed via the following commit(s):

commit 7e33adc640a4a1bf32892d9144ec060f9080b2e5
Author:     Sam James <>
AuthorDate: 2023-01-09 10:16:02 +0000
Commit:     Sam James <>
CommitDate: 2023-01-09 10:16:27 +0000

    app-text/xpdf: fix build w/ libpaper-2
    Signed-off-by: Sam James <>

 app-text/xpdf/files/xpdf-4.04-libpaper-2.patch | 14 ++++++++++++++
 app-text/xpdf/xpdf-4.04-r1.ebuild              |  3 ++-
 2 files changed, 16 insertions(+), 1 deletion(-)
Comment 14 Marcel Schilling 2023-01-09 10:17:53 UTC
Wow. That was fast. XD
Thank you!
Comment 15 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-01-09 10:27:13 UTC
(In reply to Marcel Schilling from comment #14)
> Wow. That was fast. XD
> Thank you!

I'd totally forgot about this bug until I saw you CC/comment on it, so thank you!