Neil:
> On Wed, 16 Dec 2020 18:30:47 +0100 (CET), k...@aspodata.se wrote:
> > What can I do to make ./configure below use the suggested option ?
> Try EXTRA_ECONF="--with-tcl=/usr/lib64" emerge -1a ngspice

 Thanks, that solved the configure problem.

 Now I got another, where has sys_errlist.h gone,
 and how do I resolve this:

*****************
/bin/sh ../../../libtool  --tag=CC   --mode=compile x86_64-pc-linux-gnu-gcc 
-DHAVE_CONFIG_H   -I. -I. -I../../../src/include -I../../../src/include 
-I../../../src/frontend  -I/usr/include -shared -O2pc
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. 
-I../../../src/include -I../../../src/include -I../../../src/frontend 
-I/usr/include -O2 -pipe -I/usr/include -fopenmp -c graf.c  -fCo
In file included from gnuplot.c:13:0:
gnuplot.c: In function ?<80><98>ft_gnuplot?<80><99>:
../../../src/include/ngspice/ngspice.h:284:57: error: 
?<80><98>sys_errlist?<80><99> undeclared (first use in this function)
 #define perror(string) fprintf(stderr,"%s: %s\n",string,sys_errlist[errno])
                                                         ^
gnuplot.c:129:9: note: in expansion of macro ?<80><98>perror?<80><99>
         perror(filename);
         ^~~~~~
../../../src/include/ngspice/ngspice.h:284:57: note: each undeclared identifier 
is reported only once for each function it appears in
 #define perror(string) fprintf(stderr,"%s: %s\n",string,sys_errlist[errno])
                                                         ^
gnuplot.c:129:9: note: in expansion of macro ?<80><98>perror?<80><99>
         perror(filename);
         ^~~~~~
gnuplot.c: In function ?<80><98>ft_writesimple?<80><99>:
../../../src/include/ngspice/ngspice.h:284:57: error: 
?<80><98>sys_errlist?<80><99> undeclared (first use in this function)
 #define perror(string) fprintf(stderr,"%s: %s\n",string,sys_errlist[errno])
                                                         ^
gnuplot.c:360:9: note: in expansion of macro ?<80><98>perror?<80><99>
         perror(filename);
         ^~~~~~
make[3]: *** [Makefile:452: gnuplot.lo] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory 
'/Net/gentoo/tmpdir/portage/sci-electronics/ngspice-27-r1/work/ngspice-27-binaries/src/frontend/plotting'
make[2]: *** [Makefile:827: all-recursive] Error 1
make[2]: Leaving directory 
'/Net/gentoo/tmpdir/portage/sci-electronics/ngspice-27-r1/work/ngspice-27-binaries/src/frontend'
make[1]: *** [Makefile:1387: all-recursive] Error 1
make[1]: Leaving directory 
'/Net/gentoo/tmpdir/portage/sci-electronics/ngspice-27-r1/work/ngspice-27-binaries/src'
make: *** [Makefile:440: all-recursive] Error 1
*****************

 Since the header file is the same as last time:
# md5sum  work/ngspice-27/src/include/ngspice/ngspice.h 
/usr/include/ngspice/ngspice.h 
e695c3d756b1b934563779766bfd7881  work/ngspice-27/src/include/ngspice/ngspice.h
e695c3d756b1b934563779766bfd7881  /usr/include/ngspice/ngspice.h

 there must be something else at play here.
$ find  /usr/include -type f -name \*.h | xargs grep sys_errlist
/usr/include/X11/Xw32defs.h:#  define sys_errlist _sys_errlist
/usr/include/nspr/prerror.h:** (sys_errlist); this allows errno values to be 
used directly in the
/usr/include/schily/errno.h:extern      char    *sys_errlist[];
/usr/include/ngspice/ngspice.h:#define perror(string) fprintf(stderr,"%s: 
%s\n",string,sys_errlist[errno])
/usr/include/ngspice/ngspice.h:#define perror(string) fprintf(stderr, "%s: 
%s\n", string, sys_errlist[errno])
$ grep sys_errlist.h /var/db/pkg/*/*/CONTENTS
$

 I have a crosscompiler that has sys_errlist[]:

/home/local/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/arm-linux-gnueabihf/libc/usr/include/stdio.h:#include
 <bits/sys_errlist.h>

$ tail -7 
/home/local/gcc-linaro-7.2.1-2017.11-x86_64_arm-linux-gnueabihf/arm-linux-gnueabihf/libc/usr/include/bits/sys_errlist.h
 
extern int sys_nerr;
extern const char *const sys_errlist[];
#endif
#ifdef  __USE_GNU
extern int _sys_nerr;
extern const char *const _sys_errlist[];
#endif

Regards,
/Karl Hammar


Reply via email to