default_CONFIG = CONFIG_TEST_NUM=123 CONFIG_TEST_STR=Hello
default_CONFIG += CONFIG_TEST_APOS="Text+apostrophes"
+default_CONFIG += CONFIG_OC_LINCAN=x CONFIG_UNKNOWN=x
+
+LOCAL_CONFIG_H = toplevel_config.h
config_include_HEADERS = global.h
CONFIG_TEST_NUM=123
CONFIG_TEST_STR=Hello
CONFIG_TEST_APOS="Text+apostrophes"
+#CONFIG_OC_LINCAN=x
+#CONFIG_UNKNOWN=x
--- /dev/null
+/* Automatically generated from */
+/* config file: /home/sojka/devel/omk/tests/headers/generated/config.omk-default */
+#ifndef _LOCAL_CONFIG_H
+#define _LOCAL_CONFIG_H
+#define CONFIG_TEST_NUM 123
+#define CONFIG_TEST_STR Hello
+#define CONFIG_TEST_APOS "Text+apostrophes"
+#define CONFIG_OC_LINCAN 1
+#endif /*_LOCAL_CONFIG_H*/
test -f "$LC" || canttest "Can't find the produced local config"
grep -Fv "/* config file:" $LC | diff -u correct/lincan_config.h - || error "Local config differs"
+TLC=$(find _build -name 'toplevel_config.h')
+test -f "$TLC" || canttest "Can't find the produced local config"
+grep -Fv "/* config file:" $TLC | diff -u correct/toplevel_config.h - || error "Toplevel local config differs"
+
stat -c '%z' $LC > stat.log1
sleep 1
touch config.omk-default
make default-config || canttest
+make distclean
+LC_MESSAGES=C
+export LC_MESSAGES
make 2> stderr || canttest
grep "control reaches end of non-void function" stderr || error "Default CFLAGS are not applied"