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

Bug 822531

Summary: sci-libs/libqalculate-3.21.0 - qalc.cc: error: b_ret was not declared in this scope
Product: Gentoo Linux Reporter: Toralf Förster <toralf>
Component: Current packagesAssignee: Gentoo Science Related Packages <sci>
Status: CONFIRMED ---    
Severity: normal CC: admin
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: emerge-info.txt
emerge-history.txt
environment
etc.portage.tar.bz2
logs.tar.bz2
sci-libs:libqalculate-3.21.0:20211109-005156.log
temp.tar.bz2

Description Toralf Förster gentoo-dev 2021-11-09 08:13:49 UTC
x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I..  -DPACKAGE_DATA_DIR=\""/usr/share"\" -I.. -I../libqalculate -I/usr/include/libxml2     -pipe -march=native -fno-diagnostics-color -O2 -c -o qalc.o qalc.cc
qalc.cc: In function 'bool ask_implicit()':
qalc.cc:5024:50: error: 'b_ret' was not declared in this scope
 5024 |                 if(!fgets(buffer, 1000, stdin)) {b_ret = false; break;}
      |                                                  ^~~~~
make[2]: *** [Makefile:540: qalc.o] Error 1
make[2]: Leaving directory '/var/tmp/portage/sci-libs/libqalculate-3.21.0/work/libqalculate-3.21.0/src'

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

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1_no_multilib_hardened-j4-20211105-190003

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

gcc-config -l:
 [1] x86_64-pc-linux-gnu-11.2.0 *
clang version 13.0.0
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/13/bin
/usr/lib/llvm/13
13.0.0
Python 3.9.8
Available Ruby profiles:
  [1]   ruby26 (with Rubygems)
  [2]   ruby27 (with Rubygems)
  [3]   ruby30 (with Rubygems) *
Available Rust versions:
  [1]   rust-1.56.1 *
The Glorious Glasgow Haskell Compilation System, version 8.10.4
php cli:

  HEAD of ::gentoo
commit b7d9ade0b35c10d18807c6cf7537b7d2a3beadf4
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Mon Nov 8 22:51:43 2021 +0000

    2021-11-08 22:51:40 UTC

emerge -qpvO sci-libs/libqalculate
[ebuild  N    ] sci-libs/libqalculate-3.21.0  USE="-curl -gnuplot -icu -readline"
Comment 1 Toralf Förster gentoo-dev 2021-11-09 08:13:51 UTC
Created attachment 749667 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2021-11-09 08:13:52 UTC
Created attachment 749670 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2021-11-09 08:13:53 UTC
Created attachment 749673 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2021-11-09 08:13:55 UTC
Created attachment 749676 [details]
etc.portage.tar.bz2
Comment 5 Toralf Förster gentoo-dev 2021-11-09 08:13:56 UTC
Created attachment 749679 [details]
logs.tar.bz2
Comment 6 Toralf Förster gentoo-dev 2021-11-09 08:13:57 UTC
Created attachment 749682 [details]
sci-libs:libqalculate-3.21.0:20211109-005156.log
Comment 7 Toralf Förster gentoo-dev 2021-11-09 08:13:58 UTC
Created attachment 749685 [details]
temp.tar.bz2
Comment 8 Richard Li 2021-12-17 16:03:44 UTC
Hit the same problem.


The package doesn't compile with USE=-readline.  Temporary workaround is to add USE=readline.

Relevant code:

#ifdef HAVE_LIBREADLINE
		char *rlbuffer = readline(": ");
		if(!rlbuffer) break;
		string svalue = rlbuffer;
		free(rlbuffer);
#else
		fputs(": ", stdout);
		if(!fgets(buffer, 1000, stdin)) {b_ret = false; break;}
		string svalue = buffer;
#endif