Illegal Instruction: 4

Help
2013-02-09
2013-06-12
  • Peter Single

    Peter Single - 2013-02-09

    I'm using Mac OS X Lion 10.7.5 on an Air.

    I followed the instructions 10.1 for loading in MAC OS X.

    Opened command window, have tried lots of variants:
    $ ngspice
    $ ngspice test.cir
    $ ngspice < test.cir

    I get "Illegal Instruction: 4" every time.

    Now the circuit test.cir runs with LTSpice scad3.exe. Here it is.

    * Spice file
    V1 10 0 1
    R1 10 0 1
    .op
    .end

    Any help appreciated. I'm sure its some dumb thing.

     
  • Peter Single

    Peter Single - 2013-02-09

    Illegal Instruction: 4 is an OS X error message that comes from running a binary on a different version of OS X to the one the program was compiled on. The example given (Google knows all) is going from Lion to Mountain Lion. The message is to do with stack allocation. So the solution would appear to be to compile ngspice on the target machine, and not bother with method 10.1.

    Maybe a disclaimer in the instructions may be worth adding i.e. method 10.1 is good when it works, else build it yourself.

     
  • Peter Single

    Peter Single - 2013-02-10

    Have realized instructions assume that Xcode and the command line tools are installed. Through that.

    After getting these in place, make ran clean.

    However, now I get "Segmentation fault: 11" regardless of the input.

     
  • Peter Single

    Peter Single - 2013-02-11

    Sorry, being a bit slow. Missed the last line about "make install", so was running the old binary installed by the mac installer previously. Now good. Running with correct output.

    Thanks for making this available, Now can't wait to get on with things.

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks