1 |
Neil: |
2 |
> On Wed, 16 Dec 2020 18:30:47 +0100 (CET), karl@××××××××.se wrote: |
3 |
> > What can I do to make ./configure below use the suggested option ? |
4 |
> Try EXTRA_ECONF="--with-tcl=/usr/lib64" emerge -1a ngspice |
5 |
|
6 |
Thanks, that solved the configure problem. |
7 |
|
8 |
Now I got another, where has sys_errlist.h gone, |
9 |
and how do I resolve this: |
10 |
|
11 |
***************** |
12 |
/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 |
13 |
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 |
14 |
In file included from gnuplot.c:13:0: |
15 |
gnuplot.c: In function ?<80><98>ft_gnuplot?<80><99>: |
16 |
../../../src/include/ngspice/ngspice.h:284:57: error: ?<80><98>sys_errlist?<80><99> undeclared (first use in this function) |
17 |
#define perror(string) fprintf(stderr,"%s: %s\n",string,sys_errlist[errno]) |
18 |
^ |
19 |
gnuplot.c:129:9: note: in expansion of macro ?<80><98>perror?<80><99> |
20 |
perror(filename); |
21 |
^~~~~~ |
22 |
../../../src/include/ngspice/ngspice.h:284:57: note: each undeclared identifier is reported only once for each function it appears in |
23 |
#define perror(string) fprintf(stderr,"%s: %s\n",string,sys_errlist[errno]) |
24 |
^ |
25 |
gnuplot.c:129:9: note: in expansion of macro ?<80><98>perror?<80><99> |
26 |
perror(filename); |
27 |
^~~~~~ |
28 |
gnuplot.c: In function ?<80><98>ft_writesimple?<80><99>: |
29 |
../../../src/include/ngspice/ngspice.h:284:57: error: ?<80><98>sys_errlist?<80><99> undeclared (first use in this function) |
30 |
#define perror(string) fprintf(stderr,"%s: %s\n",string,sys_errlist[errno]) |
31 |
^ |
32 |
gnuplot.c:360:9: note: in expansion of macro ?<80><98>perror?<80><99> |
33 |
perror(filename); |
34 |
^~~~~~ |
35 |
make[3]: *** [Makefile:452: gnuplot.lo] Error 1 |
36 |
make[3]: *** Waiting for unfinished jobs.... |
37 |
make[3]: Leaving directory '/Net/gentoo/tmpdir/portage/sci-electronics/ngspice-27-r1/work/ngspice-27-binaries/src/frontend/plotting' |
38 |
make[2]: *** [Makefile:827: all-recursive] Error 1 |
39 |
make[2]: Leaving directory '/Net/gentoo/tmpdir/portage/sci-electronics/ngspice-27-r1/work/ngspice-27-binaries/src/frontend' |
40 |
make[1]: *** [Makefile:1387: all-recursive] Error 1 |
41 |
make[1]: Leaving directory '/Net/gentoo/tmpdir/portage/sci-electronics/ngspice-27-r1/work/ngspice-27-binaries/src' |
42 |
make: *** [Makefile:440: all-recursive] Error 1 |
43 |
***************** |
44 |
|
45 |
Since the header file is the same as last time: |
46 |
# md5sum work/ngspice-27/src/include/ngspice/ngspice.h /usr/include/ngspice/ngspice.h |
47 |
e695c3d756b1b934563779766bfd7881 work/ngspice-27/src/include/ngspice/ngspice.h |
48 |
e695c3d756b1b934563779766bfd7881 /usr/include/ngspice/ngspice.h |
49 |
|
50 |
there must be something else at play here. |
51 |
$ find /usr/include -type f -name \*.h | xargs grep sys_errlist |
52 |
/usr/include/X11/Xw32defs.h:# define sys_errlist _sys_errlist |
53 |
/usr/include/nspr/prerror.h:** (sys_errlist); this allows errno values to be used directly in the |
54 |
/usr/include/schily/errno.h:extern char *sys_errlist[]; |
55 |
/usr/include/ngspice/ngspice.h:#define perror(string) fprintf(stderr,"%s: %s\n",string,sys_errlist[errno]) |
56 |
/usr/include/ngspice/ngspice.h:#define perror(string) fprintf(stderr, "%s: %s\n", string, sys_errlist[errno]) |
57 |
$ grep sys_errlist.h /var/db/pkg/*/*/CONTENTS |
58 |
$ |
59 |
|
60 |
I have a crosscompiler that has sys_errlist[]: |
61 |
|
62 |
/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> |
63 |
|
64 |
$ 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 |
65 |
extern int sys_nerr; |
66 |
extern const char *const sys_errlist[]; |
67 |
#endif |
68 |
#ifdef __USE_GNU |
69 |
extern int _sys_nerr; |
70 |
extern const char *const _sys_errlist[]; |
71 |
#endif |
72 |
|
73 |
Regards, |
74 |
/Karl Hammar |