Changeset 616:6b8f73f06f07 in make_builder


Ignore:
Timestamp:
12.08.2014 23:05:39 (6 years ago)
Author:
Max Reichardt <mreichardt@…>
Branch:
default
Phase:
public
Message:

A more helpful error message is now displayed, when final handler of a target cannot be determined (as requested by Thomas in rrlab ticket #163)

Location:
src/makebuilder
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/makebuilder/MakeFileBuilder.java

    r605 r616  
    8585    private final List<String> errorMessages = new ArrayList<String>(); 
    8686 
     87    /** Single MakefileBuilder instance */ 
     88    private static MakeFileBuilder instance; 
     89 
     90    /** 
     91     * @return Single MakefileBuilder instance 
     92     */ 
     93    public static MakeFileBuilder getInstance() { 
     94        return instance; 
     95    } 
     96 
    8797    public static void main(String[] args) { 
    8898 
     
    113123     */ 
    114124    public MakeFileBuilder(String relBuildDir, String relTempBuildDir) { 
     125        instance = this; 
    115126 
    116127        // init source scanner and paths 
  • src/makebuilder/ext/finroc/FinrocBuildEntity.java

    r615 r616  
    2626 
    2727import makebuilder.BuildEntity; 
     28import makebuilder.MakeFileBuilder; 
    2829import makebuilder.Makefile; 
    2930import makebuilder.SourceFileHandler; 
     
    9394                } 
    9495            } 
     96            finalHandlerDetermined = true; 
    9597            if (finalHandler == null) { 
    96                 System.out.println(Util.color("warning: cannot determine final handler for target " + toString(), Util.Color.RED, true)); 
    97             } 
    98             finalHandlerDetermined = true; 
     98                MakeFileBuilder.getInstance().printCannotBuildError(this, ": Target contains no source files to compile", Util.Color.RED); 
     99            } 
    99100        } 
    100101        return finalHandler; 
Note: See TracChangeset for help on using the changeset viewer.