Attention is currently required from: Xiang Wang, Stefan Reinauer. Edward O'Callaghan has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/49599 )
Change subject: flashrom.c: automatic generated programmer_enum.h ......................................................................
Patch Set 2: Code-Review+1
(13 comments)
File .gitignore:
https://review.coreboot.org/c/flashrom/+/49599/comment/193ff446_f1dd30e5 PS2, Line 12: programmer_enum.h programmer_table.h
Patchset:
PS2: Very cool.
File Makefile:
https://review.coreboot.org/c/flashrom/+/49599/comment/da40c0dd_5ffc4c26 PS2, Line 656: h programmer_table.o
File flashrom.c:
https://review.coreboot.org/c/flashrom/+/49599/comment/c587ed19_a9ac4318 PS2, Line 43: #include "programmer_table.c" This greatly improves things so thank you for working on this!
One minor thing here, instead of including the C file how about compile it as an object and have the table defined in programmer_table.h ?
File meson.build:
https://review.coreboot.org/c/flashrom/+/49599/comment/bb9fe30a_61736aeb PS2, Line 364: srcs += 'programmer.c' \n srcs += 'programmer_table.c'
File programmer.h:
https://review.coreboot.org/c/flashrom/+/49599/comment/d0791b60_de7aa9f1 PS2, Line 27: programmer_enum.h" programmer_table.h
File util/generator_programmer_enum.sh:
https://review.coreboot.org/c/flashrom/+/49599/comment/f8310eaa_13bd1348 PS2, Line 1: #! /bin/bash #!/usr/bin/sh
Flashrom works on a number of non-Linux systems and I don't think you precisely need bash here.
https://review.coreboot.org/c/flashrom/+/49599/comment/1bba17bb_2d4a296b PS2, Line 17: programmer_enum programmer_table.h
https://review.coreboot.org/c/flashrom/+/49599/comment/fdadd3d2_c398f63d PS2, Line 18: ENUM_PROGRAMMER_H __PROGRAMMER_TABLE_H__
https://review.coreboot.org/c/flashrom/+/49599/comment/b2581232_22104a0c PS2, Line 25: extern const struct programmer_entry programmer_table[];
https://review.coreboot.org/c/flashrom/+/49599/comment/8e3ae6d3_1e659706 PS2, Line 30: programmer_enum.h programmer_table.h
https://review.coreboot.org/c/flashrom/+/49599/comment/529a78de_bad343c2 PS2, Line 37: programmer_enum.h programmer_table.h
https://review.coreboot.org/c/flashrom/+/49599/comment/ce3ff643_ac388be5 PS2, Line 41: f /* __PROGRAMMER_TABLE_H__ */