To reproduce this image with circuit-macros, use the following code:
.PS
cct_init
include(HOMELIB_`liblog.m4')
scale = 25.4 # Use millimetres
sec = 5 # Horizontal length of each section
vgap = 20 # Vertical gap between A and B
nowid = 11 # Need a value for width of NOR gate before use
LA: "$A$" rjust; line right_ nowid+4*sec
NO1: NOR_gate with .In1 at Here
move to (0, -vgap)
LB: "$B$" rjust; line right_ nowid+4*sec
NO2: NOR_gate with .In2 at Here
move to (2*sec, -vgap/2)
NO3: NOR_gate; line right_ sec; dot
move to NO3.Out+(sec, 0); line to (Here.x, NO1.In2.y); line to NO1.In2
move to NO3.Out+(sec, 0); line to (Here.x, NO2.In1.y); line to NO2.In1
dot(at LA+(sec, 0)); line to (Here.x, NO3.In1.y); line to NO3.In1
dot(at LB+(sec, 0)); line to (Here.x, NO3.In2.y); line to NO3.In2
move to (2*nowid+6*sec, -vgap/2)
NO4: NOR_gate; line right_ sec; "$A$ XNOR $B$" ljust
line from NO1.Out right_ sec; line to (Here.x, NO4.In1.y); line to NO4.In1
line from NO2.Out right_ sec; line to (Here.x, NO4.In2.y); line to NO4.In2
.PE