User Tools

Site Tools


geda:xorn_getting_started

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
geda:xorn_getting_started [2015/09/20 17:21]
rlutz created
geda:xorn_getting_started [2020/12/16 08:42] (current)
rlutz Fix numbering
Line 1: Line 1:
 ====== Getting started with Xorn ====== ====== Getting started with Xorn ======
  
-1. Make sure that, in addition ​to the usual gEDA build dependenciesa C++ compiler (preferably ​''​g++''​) and Python 2.7 (including ​the development headers) are installed on your system.+1. First, make sure that you have the latest version of gEDA/gaf installed (version 1.10.0 or later). ​ When invoking the Python interpreter directly from a non-standard prefixyou have to add the correct PYTHONPATH (see below): either the subdirectory ''​built-packages''​ in the build treeor the appropriate ​''​site-packages'' ​directory in the installation.
  
-2. Pull the latest gEDA sources, re-run ''​./autogen.sh'',​ and configure and build the package as usual. ​ If you prefer downloading a tarball, you can pick up the Xorn sources from [[http://hedmen.org/xorn/xorn-netlist-20150903.tar.gz|here]]. ​ In either case, you don't need to install the package (but you can if you prefer to).+2. //(no longer applicable)// 
 + 
 +===== Xorn as a command-line utility =====
  
 3a. Invoke the "''​xorn''"​ executable with the option "''​%%--help%%''"​ to see a list of subcommands:​ 3a. Invoke the "''​xorn''"​ executable with the option "''​%%--help%%''"​ to see a list of subcommands:​
Line 22: Line 24:
       -g PCB some-schematic.sch       -g PCB some-schematic.sch
  
-You now know how to use Xorn as command-line utility.+===== Interacting with Xorn in C program =====
  
 4. Write a C program using libxornstorage and link it against the library: 4. Write a C program using libxornstorage and link it against the library:
Line 68: Line 70:
 If you are using a separate build directory, replace "''​-I xorn/​include''"​ with the path to the subdirectory "''​xorn/​include''"​ in the source directory. If you are using a separate build directory, replace "''​-I xorn/​include''"​ with the path to the subdirectory "''​xorn/​include''"​ in the source directory.
  
-You now know how to interact with Xorn in a C program.  ​For more information,​ see the [[http://​hedmen.org/​xorn/​doc/​api/​html/​xornstorage_8h.html|libxornstorage API documentation]] ([[http://​hedmen.org/​xorn/​doc/​api/​html/​storage.html|overview]]).+For more information,​ see the [[http://​hedmen.org/​xorn/​doc/​api/​html/​xornstorage_8h.html|libxornstorage API documentation]] ([[http://​hedmen.org/​xorn/​doc/​api/​html/​storage.html|overview]]). 
 + 
 +===== Using Xorn as a library =====
  
 5. Run the Python 2.7 interpreter with the subdirectory "''​xorn/​built-packages''"​ added to the environment variable "''​PYTHONPATH''"​. 5. Run the Python 2.7 interpreter with the subdirectory "''​xorn/​built-packages''"​ added to the environment variable "''​PYTHONPATH''"​.
Line 128: Line 132:
     class=DISCRETE     class=DISCRETE
  
-You now know how to use Xorn as a library in your own programs.+===== Writing custom netlist backends =====
  
 7. Invoke "''​xorn netlist''"​ on your schematic as above, but instead of specifying a netlist backend, use the option "''​-i''":​ 7. Invoke "''​xorn netlist''"​ on your schematic as above, but instead of specifying a netlist backend, use the option "''​-i''":​
Line 189: Line 193:
     1 packages found     1 packages found
     4 nets found     4 nets found
- 
-You now know how to write your own netlist backends to generate a custom netlist format from a set of schematics. 
  
geda/xorn_getting_started.1442784104.txt.gz · Last modified: 2015/09/20 17:21 by rlutz