• Masahiro Yamada's avatar
    Build: refactor BL32 build rules · 9cd15239
    Masahiro Yamada authored
    This complicated if-conditional combo was introduced by commit
    70d1fc53
    
     ("Fix build error when `BL32` is not defined") in order
    to fix the compile error of "make all" when SPD=opteed is given.
    
    The requirement for the build system is like follows:
    
     - If both BL32 and BL32_SOURCES are defined, the former takes
       precedence.
    
     - If BL32 is undefined but BL32_SOURCES is defined, we compile
       BL32 from the source files.
    
     - We want to let the build fail if neither of them is defined,
       but we want to check it only when we are building FIP.
    
    Refactor the code to not call FIP_ADD_IMG twice.  The behavior is
    still the same.
    Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
    9cd15239
Makefile 25.7 KB