# HG changeset patch # User Edouard Tisserant # Date 1566288491 -7200 # Node ID 2684d643f60f7754a815c73a144f14ca789e6cec # Parent 42a7ef43a0d86856ffc007fb6aa785d34b87927d Swap CTN code gen and Libraries code gen, because SVGHMI use both, and need the library part to produce hmitree before CTN part. diff -r 42a7ef43a0d8 -r 2684d643f60f ProjectController.py --- a/ProjectController.py Tue Aug 20 10:01:18 2019 +0200 +++ b/ProjectController.py Tue Aug 20 10:08:11 2019 +0200 @@ -1163,6 +1163,19 @@ def _Generate_runtime(self): buildpath = self._getBuildPath() + # CTN code gen is expected AFTER Libraries code gen, + # at least SVGHMI relies on it. + + # Generate C code and compilation params from liraries + try: + LibCFilesAndCFLAGS, LibLDFLAGS, LibExtraFiles = self.GetLibrariesCCode( + buildpath) + except Exception: + self.logger.write_error( + _("Runtime library extensions C code generation failed !\n")) + self.logger.write_error(traceback.format_exc()) + return False + # Generate C code and compilation params from confnode hierarchy try: CTNLocationCFilesAndCFLAGS, CTNLDFLAGS, CTNExtraFiles = self._Generate_C( @@ -1174,16 +1187,6 @@ self.logger.write_error(traceback.format_exc()) return False - # Generate C code and compilation params from liraries - try: - LibCFilesAndCFLAGS, LibLDFLAGS, LibExtraFiles = self.GetLibrariesCCode( - buildpath) - except Exception: - self.logger.write_error( - _("Runtime library extensions C code generation failed !\n")) - self.logger.write_error(traceback.format_exc()) - return False - self.LocationCFilesAndCFLAGS = LibCFilesAndCFLAGS + \ CTNLocationCFilesAndCFLAGS self.LDFLAGS = CTNLDFLAGS + LibLDFLAGS