Hello. I'm trying to build the last version of ngspice on FreeBSD. I stuck on the following error:
After some research I found that TCGETS and TCSETS are linux specific ioctls. Since this is complete terra incognita for me, would you please give some hint on what to use as replacement for these definitions on FreeBSD?
Many thanks!
===========
Edit
===========
I was able to build ngspice_rework34 successfully once I added ``--enable-shared'' option. Here is my configure command:
Here are most of the packages that I installed (reading the INSTALL file from ngspice archive
Probably some other tools like autotools and gmake are required.
Also please refer to the port's Makefile:
I didn't run any simulations yet, but I hope it works well.
Good luck!
PS: Also I changed two Makefiles (one in release direcory, where I did 'configure' and one in the main directory) and replaced cc with gcc9. Don't know if this is required, just the change stood there after I discovered ``--enable-shared''
../../../../src/frontend/parser/complete.c: In function 'cp_ccon':
../../../../src/frontend/parser/complete.c:394:24: error: 'TCGETS' undeclared (first use in this function); did you mean 'TIOCGETA'?
394 | # define TERM_GET TCGETS
| ^~~~~~
../../../../src/frontend/parser/complete.c:413:37: note: in expansion of macro 'TERM_GET'
413 | (void) ioctl(fileno(cp_in), TERM_GET, &OS_Buf);
| ^~~~~~~~
../../../../src/frontend/parser/complete.c:394:24: note: each undeclared identifier is reported only once for each function it appears in
394 | # define TERM_GET TCGETS
| ^~~~~~
../../../../src/frontend/parser/complete.c:413:37: note: in expansion of macro 'TERM_GET'
413 | (void) ioctl(fileno(cp_in), TERM_GET, &OS_Buf);
| ^~~~~~~~
../../../../src/frontend/parser/complete.c:395:24: error: 'TCSETS' undeclared (first use in this function); did you mean 'TIOCSETD'?
395 | # define TERM_SET TCSETS
| ^~~~~~
../../../../src/frontend/parser/complete.c:422:37: note: in expansion of macro 'TERM_SET'
422 | (void) ioctl(fileno(cp_in), TERM_SET, &sbuf);
| ^~~~~~~~
After some research I found that TCGETS and TCSETS are linux specific ioctls. Since this is complete terra incognita for me, would you please give some hint on what to use as replacement for these definitions on FreeBSD?
Many thanks!
===========
Edit
===========
I was able to build ngspice_rework34 successfully once I added ``--enable-shared'' option. Here is my configure command:
CPPFLAGS="-I/usr/local/include -I/usr/local/include/freetype2 -I/usr/local/include/ncurses" ../configure --enable-cider --with-x --disable-debug --prefix=/opt/ngspice34 --with-readline=yes --enable-shared
Here are most of the packages that I installed (reading the INSTALL file from ngspice archive
pkg install bison flex libXaw libXmu libXext libXft fontconfig libXrender libX11 readline freetype2
Probably some other tools like autotools and gmake are required.
Also please refer to the port's Makefile:
[ports] Contents of /head/cad/ngspice_rework/Makefile
svnweb.freebsd.org
I didn't run any simulations yet, but I hope it works well.
Good luck!
PS: Also I changed two Makefiles (one in release direcory, where I did 'configure' and one in the main directory) and replaced cc with gcc9. Don't know if this is required, just the change stood there after I discovered ``--enable-shared''