rpms/gnucap/devel gnucap-0.34-debian.patch, NONE, 1.1 gnucap.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2

Hans de Goede (jwrdegoede) fedora-extras-commits at redhat.com
Thu Apr 27 19:29:33 UTC 2006


Author: jwrdegoede

Update of /cvs/extras/rpms/gnucap/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv4631/devel

Modified Files:
	.cvsignore sources 
Added Files:
	gnucap-0.34-debian.patch gnucap.spec 
Log Message:
auto-import gnucap-0.34-2 on branch devel from gnucap-0.34-2.src.rpm

gnucap-0.34-debian.patch:

--- NEW FILE gnucap-0.34-debian.patch ---
--- gnucap-0.34.orig/doc/whatisit
+++ gnucap-0.34/doc/whatisit
@@ -1,4 +1,4 @@
-ACS is a general purpose circuit simulator.  It performs nonlinear
+Gnucap is a general purpose circuit simulator.  It performs nonlinear
 dc and transient analyses, fourier analysis, and ac analysis
 linearized at an operating point.  It is fully interactive and
 command driven.  It can also be run in batch mode or as a server.
@@ -6,7 +6,7 @@
 for the MOSFET (level 1-7) and diode are included in this
 release.
 
-ACS is not based on Berkeley Spice, but some of the models have been
+Gnucap is not based on Berkeley Spice, but some of the models have been
 derived from the Berleley models.
 
 Since it is fully interactive, it is possible to make changes and
@@ -19,7 +19,7 @@
 bipolar design.
 
 In batch mode it is mostly Spice compatible, so it is often possible
-to use the same file for both ACS and Spice.
+to use the same file for both Gnucap and Spice.
 
 The analog simulation is based on traditional nodal analysis with
 iteration by Newton's method and LU decomposition.  An event queue
@@ -36,11 +36,11 @@
 experimental and needs work.  There will be substantial improvements
 in future releases.
 
-ACS also has a simple behavioral modeling language that allows
+Gnucap also has a simple behavioral modeling language that allows
 simple behavioral descriptions of most components including capacitors
 and inductors.
 
-ACS uses an object oriented approach to modeling.  Complex models like
+Gnucap uses an object oriented approach to modeling.  Complex models like
 MOSFETS are made of simpler ones like resistors, capacitors, diodes,
 and any other models that may already exist.  The model designer does
 not need to worry about details like convergence checking, bypass
@@ -54,17 +54,13 @@
 If you are tired of Spice and want a second opinion, you want to
 play with the circuit and want a simulator that is interactive, or
 you want to study the source code and want something easier to
-follow than Spice, try ACS.
+follow than Spice, try Gnucap.
 
-ACS is an ongoing research project.  It is being released in a
+Gnucap is an ongoing research project.  It is being released in a
 preliminary phase in hopes that it will be useful and that others
 will use it as a thrust or base for their research.  I also hope
 for some comments that may help me direct my research.
 
-ACS ftp sites:
-	ftp://sunsite.unc.edu/pub/Linux/apps/circuits/acs-0.27.tar.gz
-	ftp://ftp.geda.seul.org/pub/geda/dist/acs-0.27.tar.gz
-	http://www.geda.seul.org/dist/acs-0.27.tar.gz
 
 Albert Davis
 aldavis at ieee.org
--- gnucap-0.34.orig/src/bm.cc
+++ gnucap-0.34/src/bm.cc
@@ -207,7 +207,8 @@
 /*--------------------------------------------------------------------------*/
 void EVAL_BM_ACTION_BASE::tr_finish_tdv(ELEMENT* d, double val)const
 {
-  d->_y0 = FPOLY1(CPOLY1(ioffset(d->_y0.x), 0., val));
+  CPOLY1 cp1(ioffset(d->_y0.x), 0., val);
+  d->_y0 = FPOLY1(cp1);
   tr_final_adjust(&(d->_y0), false);
 }
 /*--------------------------------------------------------------------------*/
--- gnucap-0.34.orig/src/e_card.h
+++ gnucap-0.34/src/e_card.h
@@ -32,6 +32,7 @@
 // external
 class CS;
 class COMMON_COMPONENT;
+CARD_LIST::fat_iterator findbranch(CS&,CARD_LIST::fat_iterator);
 /*--------------------------------------------------------------------------*/
 class CARD : public CKT_BASE {
 private:
--- gnucap-0.34.orig/src/d_vcvs.cc
+++ gnucap-0.34/src/d_vcvs.cc
@@ -58,7 +58,8 @@
     assert(_y0.f0 != LINEAR);
     store_values();
     q_load();
-    _m0 = CPOLY1(_y0);
+    CPOLY1 cp1(_y0);
+    _m0 =cp1;
     _m0 *= -_loss0;
   }else{
     assert(conchk(_loss0, 1./OPT::shortckt));
--- gnucap-0.34.orig/src/u_sdp.h
+++ gnucap-0.34/src/u_sdp.h
@@ -29,6 +29,9 @@
 #include "ap.h"
 /*--------------------------------------------------------------------------*/
 class OMSTREAM;
+class SDP;
+bool get(CS& cmd, const std::string& key, SDP* value,
+	 AP_MOD mod, double scale);
 /*--------------------------------------------------------------------------*/
 class SDP {
   friend bool get(CS& cmd, const std::string& key, SDP* value,
--- gnucap-0.34.orig/src/e_storag.cc
+++ gnucap-0.34/src/e_storag.cc
@@ -78,7 +78,8 @@
   _dt = NOT_VALID;
   _i0 = _q[0] = _q[1] = _q[2] = _q[3] = FPOLY1(0., 0., 0.);
   _it1_f0 = 0.;
-  _m1 = _m0 = CPOLY1(0., 0., 0.);
+  CPOLY1 cp1(0., 0., 0.);
+  _m1 = _m0 = cp1;
   assert(_loss0 == 0.);
   assert(_loss1 == 0.);
   if (!using_tr_eval()){
--- gnucap-0.34.orig/src/d_admit.cc
+++ gnucap-0.34/src/d_admit.cc
@@ -56,7 +56,8 @@
     assert(_y0.f0 != LINEAR);
     store_values();
     q_load();
-    _m0 = CPOLY1(_y0);
+    CPOLY1 cp1(_y0);
+    _m0 = cp1;
   }else{
     assert(_y0.f0 == LINEAR);
     assert(_y0.f1 == value());
@@ -171,7 +172,8 @@
 bool DEV_CPOLY_G::do_tr()
 {
   assert(_values);
-  _m0 = CPOLY1(0., _values[0], _values[1]);
+  CPOLY1 cp1(0., _values[0], _values[1]);
+  _m0 = cp1;
   return do_tr_con_chk_and_q();
 }
 /*--------------------------------------------------------------------------*/
@@ -193,7 +195,8 @@
     }}
   }}
   trace2("", _values[0], c0);
-  _m0 = CPOLY1(0., c0, _values[1]);
+  CPOLY1 cp1(0., c0, _values[1]);
+  _m0 = cp1;
 
   return do_tr_con_chk_and_q();
 }
--- gnucap-0.34.orig/src/e_compon.h
+++ gnucap-0.34/src/e_compon.h
@@ -43,6 +43,9 @@
 }
 /*--------------------------------------------------------------------------*/
 enum {CC_STATIC=27342}; // mid-sized arbitrary positive int
+class COMMON_COMPONENT;
+void attach_common(COMMON_COMPONENT* c, COMMON_COMPONENT** to);
+void detach_common(COMMON_COMPONENT** from);
 // pass this as an argument to a common constructor to mark it as static,
 // so it won't be deleted
 /*--------------------------------------------------------------------------*/
--- gnucap-0.34.orig/src/d_cap.cc
+++ gnucap-0.34/src/d_cap.cc
@@ -49,7 +49,8 @@
   _i0.f0 = differentiate();
   _i0.f1 = tr_c_to_g(_q[0].f1, _i0.f1);
 
-  _m0 = CPOLY1(_i0);
+  CPOLY1 cp1(_i0);
+  _m0 = cp1;
   return converged();
 }
 /*--------------------------------------------------------------------------*/
@@ -172,7 +173,8 @@
     }}
   }}
   
-  _m0 = CPOLY1(0., _vi0[0], _vi0[1]);
+  CPOLY1 cp1(0., _vi0[0], _vi0[1]);
+  _m0 = cp1;
   return do_tr_con_chk_and_q();
 }
 /*--------------------------------------------------------------------------*/
--- gnucap-0.34.orig/src/l_timer.h
+++ gnucap-0.34/src/l_timer.h
@@ -25,6 +25,8 @@
 #define U_TIMER_H
 #include "io_.h"
 /*--------------------------------------------------------------------------*/
+class TIMER;
+TIMER	operator-(const TIMER&,const TIMER&);
 class TIMER {
 private:
   enum {_T_NAME_LEN = 8};
--- gnucap-0.34.orig/ibis/model-in.cc
+++ gnucap-0.34/ibis/model-in.cc
@@ -145,23 +145,23 @@
 /*--------------------------------------------------------------------------*/
 void Model_Base::Type::parse(CS& file)
 {
-       set(file, "Terminator",	   &_type, mtTERMINATOR)
-    || set(file, "Input_ECL",	   &_type, mtINPUT_ECL)
-    || set(file, "Input",	   &_type, mtINPUT)
-    || set(file, "I/O_open_sink",  &_type, mtIO_OPEN_SINK)
-    || set(file, "I/O_open_drain", &_type, mtIO_OPEN_DRAIN)
-    || set(file, "I/O_open_source",&_type, mtIO_OPEN_SOURCE)
-    || set(file, "I/O_ECL",	   &_type, mtIO_ECL)
-    || set(file, "I/O",		   &_type, mtIO)
-    || set(file, "3-state_ECL",    &_type, mt3STATE_ECL)
-    || set(file, "3-state",	   &_type, mt3STATE)
-    || set(file, "Output_ECL",	   &_type, mtOUTPUT_ECL)
-    || set(file, "Output",	   &_type, mtOUTPUT)
-    || set(file, "Open_sink",	   &_type, mtOPEN_SINK)
-    || set(file, "Open_drain",	   &_type, mtOPEN_DRAIN)
-    || set(file, "Open_source",    &_type, mtOPEN_SOURCE)
-    || set(file, "Series_switch",  &_type, mtSERIES_SWITCH)
-    || set(file, "Series",	   &_type, mtSERIES)
+       set(file, "Terminator",	   (int*)&_type, (int)mtTERMINATOR)
+    || set(file, "Input_ECL",	   (int*)&_type, (int)mtINPUT_ECL)
+    || set(file, "Input",	   (int*)&_type, (int)mtINPUT)
+    || set(file, "I/O_open_sink",  (int*)&_type, (int)mtIO_OPEN_SINK)
+    || set(file, "I/O_open_drain", (int*)&_type, (int)mtIO_OPEN_DRAIN)
+    || set(file, "I/O_open_source",(int*)&_type, (int)mtIO_OPEN_SOURCE)
+    || set(file, "I/O_ECL",	   (int*)&_type, (int)mtIO_ECL)
+    || set(file, "I/O",		   (int*)&_type, (int)mtIO)
+    || set(file, "3-state_ECL",    (int*)&_type, (int)mt3STATE_ECL)
+    || set(file, "3-state",	   (int*)&_type, (int)mt3STATE)
+    || set(file, "Output_ECL",	   (int*)&_type, (int)mtOUTPUT_ECL)
+    || set(file, "Output",	   (int*)&_type, (int)mtOUTPUT)
+    || set(file, "Open_sink",	   (int*)&_type, (int)mtOPEN_SINK)
+    || set(file, "Open_drain",	   (int*)&_type, (int)mtOPEN_DRAIN)
+    || set(file, "Open_source",    (int*)&_type, (int)mtOPEN_SOURCE)
+    || set(file, "Series_switch",  (int*)&_type, (int)mtSERIES_SWITCH)
+    || set(file, "Series",	   (int*)&_type, (int)mtSERIES)
     || file.warn(0, "illegal model type");
 }
 /*--------------------------------------------------------------------------*/
@@ -235,8 +235,8 @@
 /*--------------------------------------------------------------------------*/
 void IO_Base::Polarity::parse(CS& file)
 {
-       set(file, "Non-Inverting", &_p, pNON_INVERTING)
-    || set(file, "Inverting",	  &_p, pINVERTING)
+       set(file, "Non-Inverting", (int*)&_p, (int)pNON_INVERTING)
+    || set(file, "Inverting",	  (int*)&_p, (int)pINVERTING)
     || file.warn(0, "need Inverting or Non-Inverting");
 }
 /*--------------------------------------------------------------------------*/
--- gnucap-0.34.orig/ibis/base.h
+++ gnucap-0.34/ibis/base.h
@@ -40,7 +40,7 @@
 class Base
 {
 private:
-  explicit Base(const Base&) {unreachable();}
+//  explicit Base(const Base&) {unreachable();}
   // This private base copy constructor inhibits generation of
   // copy constructors for its derived classes.
 protected:
--- gnucap-0.34.orig/ibis/comp-in.cc
+++ gnucap-0.34/ibis/comp-in.cc
@@ -24,8 +24,8 @@
 /*--------------------------------------------------------------------------*/
 void Component::Pin_Die::parse(CS& file)
 {
-       set(file, "Pin", &_pd, pdPIN)
-    || set(file, "Die", &_pd, pdDIE)
+       set(file, "Pin", (int*)&_pd, (int)pdPIN)
+    || set(file, "Die", (int*)&_pd, (int)pdDIE)
     || file.warn(0, "need Pin or Die");
 }
 /*--------------------------------------------------------------------------*/
--- gnucap-0.34.orig/ibis/file-in.cc
+++ gnucap-0.34/ibis/file-in.cc
@@ -25,9 +25,9 @@
 /*--------------------------------------------------------------------------*/
 void Redistribution::parse(CS& file)
 {
-       set(file, "Yes",	    &_r, dYES)
-    || set(file, "No",	    &_r, dNO)
-    || set(file, "Specific",&_r, dSPECIFIC)
+       set(file, "Yes",	    (int*)&_r, (int)dYES)
+    || set(file, "No",	    (int*)&_r, (int)dNO)
+    || set(file, "Specific",(int*)&_r, (int)dSPECIFIC)
     || file.warn(0, "need Yes, No, or Specific");
 }
 /*--------------------------------------------------------------------------*/
--- gnucap-0.34.orig/modelgen/mg_.h
+++ gnucap-0.34/modelgen/mg_.h
@@ -118,7 +118,7 @@
 	}
 	T* p = new T(file);
 	{if (!file.stuck(&here)) {
-	  _list.push_back(p);
+	  this->_list.push_back(p);
 	}else {
 	  delete p;
 	  file.warn(0, "not valid here");
@@ -137,7 +137,7 @@
     int here = file.cursor();
     T* m = new T(file);
     {if (!file.stuck(&here)) {
-      _list.push_back(m);
+      this->_list.push_back(m);
     }else{
       delete m;
       file.warn(0, "what's this??");
--- gnucap-0.34.orig/examples/runall
+++ gnucap-0.34/examples/runall
@@ -1,16 +1,16 @@
-#
-$1 -b eq2-145.ckt
-$1 -b eq2-289.ckt
-$1 -b eq2-577.ckt
-$1 -b eq3-1153.ckt
-$1 -b eq4-2305.ckt
-$1 -b eqboost.ckt
-$1 -b eqflat.ckt 
-$1 -b eqmodify.ckt
-$1 -b killzap.ckt
-$1 -b nmos100.ckt
-$1 -b nmos18.ckt 
-$1 -b nmos30.ckt 
-$1 -b nmp100.ckt 
-$1 -b opamp-ol.ckt
-$1 -b opamp-vf.ckt
+#!/bin/sh
+gnucap -b eq2-145.ckt
+gnucap -b eq2-289.ckt
+gnucap -b eq2-577.ckt
+gnucap -b eq3-1153.ckt
+gnucap -b eq4-2305.ckt
+gnucap -b eqboost.ckt
+gnucap -b eqflat.ckt 
+gnucap -b eqmodify.ckt
+gnucap -b killzap.ckt
+gnucap -b nmos100.ckt
+gnucap -b nmos18.ckt 
+gnucap -b nmos30.ckt 
+gnucap -b nmp100.ckt 
+gnucap -b opamp-ol.ckt
+gnucap -b opamp-vf.ckt


--- NEW FILE gnucap.spec ---
Name:           gnucap
Version:        0.34
Release:        2%{?dist}
Summary:        The Gnu Circuit Analysis Package
Group:          Applications/Engineering
License:        GPL
URL:            http://www.geda.seul.org/tools/gnucap
Source0:        http://www.geda.seul.org/tools/gnucap/archive/%{name}-%{version}.tar.gz
Patch0:         gnucap-0.34-debian.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires:  readline-devel

%description
The primary component is a general purpose circuit simulator. It performs
nonlinear dc and transient analyses, fourier analysis, and ac analysis. Spice
compatible models for the MOSFET (level 1-7), BJT, and diode are included in
this release. Gnucap is not based on Spice, but some of the models have been
derived from the Berkeley models. Unlike Spice, the engine is designed to do
true mixed-mode simulation. Most of the code is in place for future support of
event driven analog simulation, and true multi-rate simulation.


%prep
%setup -q
%patch0 -p1 -z .debian
%{__sed} -i 's!/usr/lib!%{_libdir}!g' src/configure 
%{__sed} -i 's!ln -s!ln!g' src/Make1
%{__sed} -i 's!ln -s!ln!g' src/Make.aux
mv doc/acs-tutorial doc/gnucap-tutorial


%build
# Don't use %%configure because this is not an autotools-generated
# configure script and will choke on some of the default configure switches.
./configure --prefix=%{_prefix}
make %{?_smp_mflags} \
  CCFLAGS="$RPM_OPT_FLAGS -DHAS_READLINE -DUNIX -DNDEBUG -I. -I.."


%install
# make install uses hardcoded /usr/bin etc paths, so we must do this DIY
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_bindir} $RPM_BUILD_ROOT%{_mandir}/man1
install -m 755 src/O/gnucap $RPM_BUILD_ROOT%{_bindir}
install -m 755 ibis/O/gnucap-ibis $RPM_BUILD_ROOT%{_bindir}
install -m 755 modelgen/O/gnucap-modelgen $RPM_BUILD_ROOT%{_bindir}
install -m 644 doc/gnucap.1 doc/gnucap-ibis.1 $RPM_BUILD_ROOT%{_mandir}/man1


%clean
rm -rf $RPM_BUILD_ROOT


%files
%defattr(-,root,root,-)
%doc doc/COPYING doc/history doc/relnotes.* doc/gnucap-tutorial doc/whatisit
%doc man/gnucap-man.pdf man/html
%{_bindir}/%{name}*
%{_mandir}/man1/%{name}*.1.gz


%changelog
* Thu Apr 27 2006 Hans de Goede <j.w.r.degoede at hhs.nl> 0.34-2
- add %%{?_smp_mflags} to the make command (bz 189699)

* Sun Apr 23 2006 Hans de Goede <j.w.r.degoede at hhs.nl> 0.34-1
- Initial spec file


Index: .cvsignore
===================================================================
RCS file: /cvs/extras/rpms/gnucap/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore	27 Apr 2006 19:28:44 -0000	1.1
+++ .cvsignore	27 Apr 2006 19:29:32 -0000	1.2
@@ -0,0 +1 @@
+gnucap-0.34.tar.gz


Index: sources
===================================================================
RCS file: /cvs/extras/rpms/gnucap/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources	27 Apr 2006 19:28:44 -0000	1.1
+++ sources	27 Apr 2006 19:29:32 -0000	1.2
@@ -0,0 +1 @@
+0d346f02a38c544fda6f8d7ec4f8b45e  gnucap-0.34.tar.gz




More information about the fedora-extras-commits mailing list