]> granicus.if.org Git - esp-idf/commitdiff
ci: check that custom bootloader overrides original
authorRenz Christian Bagaporo <renz@espressif.com>
Wed, 15 May 2019 06:49:51 +0000 (14:49 +0800)
committerRenz Christian Bagaporo <renz@espressif.com>
Mon, 27 May 2019 10:45:28 +0000 (18:45 +0800)
tools/ci/test_build_system_cmake.sh

index c679acc5c6a4f53290dc22cf6de96a9fe1148643..5c434ab34fcd87d145f3a3108718f5f1878692c8 100755 (executable)
@@ -238,16 +238,13 @@ EOF
     export PATH="$OLDPATH"
     rm ./python
 
-    print_status "sdkconfig should have contents both files: sdkconfig and sdkconfig.defaults"
-    idf.py clean > /dev/null;
-    idf.py fullclean > /dev/null;
-    rm -f sdkconfig.defaults;
-    rm -f sdkconfig;
-    echo "CONFIG_PARTITION_TABLE_OFFSET=0x10000" >> sdkconfig.defaults;
-    echo "CONFIG_PARTITION_TABLE_TWO_OTA=y" >> sdkconfig;
-    idf.py reconfigure > /dev/null;
-    grep "CONFIG_PARTITION_TABLE_OFFSET=0x10000" sdkconfig || failure "The define from sdkconfig.defaults should be into sdkconfig"
-    grep "CONFIG_PARTITION_TABLE_TWO_OTA=y" sdkconfig || failure "The define from sdkconfig should be into sdkconfig"
+    print_status "Custom bootloader overrides original"
+    clean_build_dir
+    (mkdir components && cd components && cp -r $IDF_PATH/components/bootloader .)
+    idf.py build
+    grep "$PWD/components/bootloader/subproject/main/bootloader_start.c" build/bootloader/compile_commands.json \
+        || failure "Custom bootloader source files should be built instead of the original's"
+    rm -rf components
 
     print_status "All tests completed"
     if [ -n "${FAILURES}" ]; then