test_build.sh: Compare output for -L of Make and Meson builds

Change-Id: I3bbf63e7efe7dd9c504c31f1a1e5794a2b09a74a
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.sourcearcade.org/c/flashprog/+/142
diff --git a/test_build.sh b/test_build.sh
index ecdcace..74118fb 100755
--- a/test_build.sh
+++ b/test_build.sh
@@ -36,4 +36,10 @@
 	eval ${MESONCMD} setup ${MESONARGS--D programmer=all --buildtype release} "${TEMP_DIR}/build"
 	ninja ${CPUS:+-j${CPUS}} -C "${TEMP_DIR}/build"
 	test_prog "${TEMP_DIR}/build/flashprog"
+
+	if [ "${MAKECMD}" -a ! "${CROSS_COMPILE}" ]; then
+		./flashprog -L >"${TEMP_DIR}/flashprog.supported"
+		"${TEMP_DIR}/build/flashprog" -L >"${TEMP_DIR}/mashprog.supported"
+		diff -u "${TEMP_DIR}/flashprog.supported" "${TEMP_DIR}/mashprog.supported"
+	fi
 fi