From 9ed7d3b03980358785637ac761c6a7365a5d0c04 Mon Sep 17 00:00:00 2001 From: Stefan Frederik Date: Sat, 20 Aug 2022 13:51:20 +0200 Subject: [PATCH] remove ## from netlist if "#@attribute\\#@name" is used in format string and "attribute" is undefined or empty --- scconfig/src/gui/Makefile.plugin | 1 + scconfig/src/gui/gui.c | 2 ++ src/spice.awk | 4 ++++ 3 files changed, 7 insertions(+) diff --git a/scconfig/src/gui/Makefile.plugin b/scconfig/src/gui/Makefile.plugin index f8e1a0be..f9c07e0a 100644 --- a/scconfig/src/gui/Makefile.plugin +++ b/scconfig/src/gui/Makefile.plugin @@ -9,6 +9,7 @@ GUI_OBJS = \ $(BIN)/gui/find_cairo.o \ $(BIN)/gui/find_misc.o \ $(BIN)/gui/find_gl.o \ + $(BIN)/gui/find_sdl2.o \ $(BIN)/gui/gui.o diff --git a/scconfig/src/gui/gui.c b/scconfig/src/gui/gui.c index 385a6d8e..300c371a 100644 --- a/scconfig/src/gui/gui.c +++ b/scconfig/src/gui/gui.c @@ -12,6 +12,7 @@ #include "find_cairo.h" #include "find_misc.h" #include "find_gl.h" +#include "find_sdl2.h" void deps_gui_init() { @@ -47,4 +48,5 @@ void deps_gui_init() dep_add("libs/gui/glut/*", find_glut); dep_add("libs/gui/wgl/*", find_gui_wgl); dep_add("libs/gui/glfw/*", find_glfw); + dep_add("libs/gui/sdl2/*", find_sdl2); } diff --git a/src/spice.awk b/src/spice.awk index 257e3caa..f25ced12 100755 --- a/src/spice.awk +++ b/src/spice.awk @@ -185,6 +185,10 @@ function process( i,j, iprefix, saveinstr, savetype, saveanalysis) # dxm6[0] 0 HDD dnwell area='(50u + 73u)*(10u + 32u)' pj='2*(50u +73u)+2*(10u +32u)' #20151027 do this for all fields for(i=1; i<=NF;i++) { + + if($i ~/^##[a-zA-Z_]+/) { + sub(/^##/, "", $i) + } else if($i ~/^#[a-zA-Z_0-9]+#[a-zA-Z_]+/) { iprefix=$i sub(/^#/,"",iprefix)