Bug 1311869 - wrong codemodel paths in /usr/share/ngspice/scripts/spinit
Summary: wrong codemodel paths in /usr/share/ngspice/scripts/spinit
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: ngspice
Version: 23
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Mamoru TASAKA
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 1311870 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-02-25 09:01 UTC by Artem Prokshin
Modified: 2016-07-09 23:52 UTC (History)
3 users (show)

Fixed In Version: ngspice-26-4.fc24 ngspice-26-4.fc23
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-07-05 04:58:45 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Artem Prokshin 2016-02-25 09:01:09 UTC
Description of problem:

File /usr/share/ngspice/scripts/spinit has codemodel paths:

 codemodel /usr/lib64/tclspice/ngspice/spice2poly.cm

* The other codemodels
 codemodel /usr/lib64/tclspice/ngspice/analog.cm
 codemodel /usr/lib64/tclspice/ngspice/digital.cm
 codemodel /usr/lib64/tclspice/ngspice/xtradev.cm
 codemodel /usr/lib64/tclspice/ngspice/xtraevt.cm

but actual place of '.cm'-files is

/usr/lib64/ngspice/

Version-Release number of selected component (if applicable):

ngspice-26-1.fc23.x86_64
The same misconfiguration is in i686 version.

How reproducible:


Steps to Reproduce:
1. make sure tclspice-26-1.fc23.x86_64 is not installed:
dnf remove tclspice

2.make file foo.cir with sample shown in 12.1 Code Model Element & .MODEL Cards of manual /usr/share/doc/ngspice/ngspice-26.pdf

reproduce bug 
* 
a1 1 2 amp 
.model amp gain ( gain =5.0)

3. /bin/ngspice foo.cir

Actual results:


user@localhost bug]$ /bin/ngspice foo.cir
/usr/lib64/tclspice/ngspice/spice2poly.cm: cannot open shared object file: No such file or directory
Error: Library /usr/lib64/tclspice/ngspice/spice2poly.cm couldn't be loaded!
/usr/lib64/tclspice/ngspice/analog.cm: cannot open shared object file: No such file or directory
Error: Library /usr/lib64/tclspice/ngspice/analog.cm couldn't be loaded!
/usr/lib64/tclspice/ngspice/digital.cm: cannot open shared object file: No such file or directory
Error: Library /usr/lib64/tclspice/ngspice/digital.cm couldn't be loaded!
/usr/lib64/tclspice/ngspice/xtradev.cm: cannot open shared object file: No such file or directory
Error: Library /usr/lib64/tclspice/ngspice/xtradev.cm couldn't be loaded!
/usr/lib64/tclspice/ngspice/xtraevt.cm: cannot open shared object file: No such file or directory
Error: Library /usr/lib64/tclspice/ngspice/xtraevt.cm couldn't be loaded!
******
** ngspice-26 : Circuit level simulation program
** The U. C. Berkeley CAD Group
** Copyright 1985-1994, Regents of the University of California.
** Please get your ngspice manual from http://ngspice.sourceforge.net/docs.html
** Please file your bug-reports at http://ngspice.sourceforge.net/bugrep.html
** Creation Date: Sat Oct 10 04:33:45 UTC 2015
******

Circuit: reproduce bug

Error on line 3 : a1 1 2 amp
   MIF-ERROR - unable to find definition of model amp
Warning: Model issue on line 4 : .model amp gain ( gain=5.0) ...
  Unknown model type gain - ignored
ngspice 3735 -> quit
ngspice-26 done


Expected results:


Additional info:

Comment 1 Artem Prokshin 2016-02-25 09:47:12 UTC
*** Bug 1311870 has been marked as a duplicate of this bug. ***

Comment 2 Fedora Admin XMLRPC Client 2016-04-26 03:45:54 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 3 Fedora Admin XMLRPC Client 2016-06-25 05:17:51 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 4 Mamoru TASAKA 2016-06-25 05:19:13 UTC
I will take a look at this.

Comment 5 Mamoru TASAKA 2016-06-28 09:31:52 UTC
The problem here is that spinit from tclspice installation overwrites spinit from ngspice installation,

Since it seems that ngspice uses spinit while tclspice (actually libspice.so) _seems_ to use tclspinit, as far as I am not wrong spinit installed by tclspice can be simply thrown away.

Comment 6 Artem Prokshin 2016-06-28 11:29:58 UTC
I have never installed tclspice, so spinit is actually installed by ngspice itself.

Comment 7 Mamoru TASAKA 2016-06-28 11:49:27 UTC
By the way, are you still using F-23? Or have you updated your system to F-24?

Comment 8 Mamoru TASAKA 2016-06-28 11:54:31 UTC
(In reply to Artem Prokshin from comment #6)
> I have never installed tclspice, so spinit is actually installed by ngspice
> itself.

Well, I meant here is that spinit from tclspice installation "on build" (i.e "make install" on tclspice side) overwrites spinit from nspice installation "on build" (i.e. "make install" on ngspice side).

Comment 9 Artem Prokshin 2016-06-28 12:36:46 UTC
I am still running F-23. I have couple boxes with x64 and couple with i386.
I could install F-24-beta at one box in a day or two.

Comment 10 Artem Prokshin 2016-06-28 12:42:20 UTC
Sources from http://ngspice.sourceforge.net/ have right spinit.

Comment 11 Mamoru TASAKA 2016-06-28 14:07:38 UTC
Would you try this?

http://koji.fedoraproject.org/koji/taskinfo?taskID=14687343

Comment 12 Artem Prokshin 2016-06-29 10:49:45 UTC
I downloaded rpm from http://koji.fedoraproject.org/koji/taskinfo?taskID=14687347

more specific
https://kojipkgs.fedoraproject.org//work/tasks/7347/14687347/ngspice-26-3.900.fc23.x86_64.rpm

Sounds like the error is eliminated:

1)
[user@localhost bug]$ rpm -qf /usr/share/ngspice/scripts/spinit
ngspice-26-3.900.fc23.x86_64

[user@localhost bug]$ cat /usr/share/ngspice/scripts/spinit
...
* The other codemodels
 codemodel /usr/lib64/ngspice/analog.cm
 codemodel /usr/lib64/ngspice/digital.cm
 codemodel /usr/lib64/ngspice/xtradev.cm
 codemodel /usr/lib64/ngspice/xtraevt.cm
...

2)
[user@localhost bug]$ cat foo.cir
reproduce bug 
* 
a1 1 2 amp 
.model amp gain ( gain =5.0)

[user@localhost bug]$ ngspice foo.cir 
******
** ngspice-26 : Circuit level simulation program
** The U. C. Berkeley CAD Group
** Copyright 1985-1994, Regents of the University of California.
** Please get your ngspice manual from http://ngspice.sourceforge.net/docs.html
** Please file your bug-reports at http://ngspice.sourceforge.net/bugrep.html
** Creation Date: Tue Jun 28 12:07:35 UTC 2016
******

Circuit: reproduce bug

Comment 13 Mamoru TASAKA 2016-06-29 11:39:13 UTC
Thank you for confirming. 

I will push the modified rpm as updates later formally (with bodhi), so for now I reopen this bug (when bodhi pushes fixed rpm formally, this bug will be then closed).

Comment 14 Fedora Update System 2016-06-30 04:57:48 UTC
ngspice-26-4.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-04bcc4e7fe

Comment 15 Fedora Update System 2016-06-30 04:58:44 UTC
ngspice-26-4.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-a8d80244f6

Comment 16 Fedora Update System 2016-06-30 22:26:21 UTC
ngspice-26-4.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-04bcc4e7fe

Comment 17 Fedora Update System 2016-06-30 22:54:25 UTC
ngspice-26-4.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-a8d80244f6

Comment 18 Fedora Update System 2016-07-05 04:58:43 UTC
ngspice-26-4.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 19 Fedora Update System 2016-07-09 23:52:35 UTC
ngspice-26-4.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.