1;;; Lepton EDA netlister 2;;; Copyright (C) 2016 gEDA Contributors 3;;; Copyright (C) 2018 Lepton EDA Contributors 4; 5; This program is free software; you can redistribute it and/or modify 6; it under the terms of the GNU General Public License as published by 7; the Free Software Foundation; either version 2 of the License, or 8; (at your option) any later version. 9; 10; This program is distributed in the hope that it will be useful, 11; but WITHOUT ANY WARRANTY; without even the implied warranty of 12; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13; GNU General Public License for more details. 14; 15; You should have received a copy of the GNU General Public License 16; along with this program; if not, write to the Free Software 17; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 18 19(use-modules (netlist partlist) 20 (netlist partlist common) 21 (netlist attrib compare) 22 (netlist schematic) 23 (netlist schematic toplevel)) 24 25(define (partslist2 output-filename) 26 (display 27 (partlist->string 28 (make-partlist (schematic-package-names (toplevel-schematic)) 29 '(device value footprint refdes)) 30 #:sort-order `((device . ,string-ci<?) 31 (value . ,value<?) 32 (footprint . ,string-ci<?) 33 (refdes . ,refdes<?)) 34 #:output-order '(refdes device value footprint #{}#) 35 #:header ".START\n.." 36 #:footer "\n.END\n" 37 #:prepend-names? #t 38 #:remove '((device . "include")) 39 ))) 40