mirror of
https://github.com/arduino/Arduino.git
synced 2025-01-30 19:52:13 +01:00
Merge branch 'ide-1.5.x-fail-when-no-platform-txt' of https://github.com/ffissore/Arduino into ide-1.5.x
This commit is contained in:
commit
81808d532e
@ -1426,8 +1426,8 @@ public class Editor extends JFrame implements RunnerListener {
|
|||||||
|
|
||||||
|
|
||||||
public void resetHandlers() {
|
public void resetHandlers() {
|
||||||
runHandler = new DefaultRunHandler();
|
runHandler = new BuildHandler();
|
||||||
presentHandler = new DefaultPresentHandler();
|
presentHandler = new BuildHandler(true);
|
||||||
stopHandler = new DefaultStopHandler();
|
stopHandler = new DefaultStopHandler();
|
||||||
exportHandler = new DefaultExportHandler();
|
exportHandler = new DefaultExportHandler();
|
||||||
exportAppHandler = new DefaultExportAppHandler();
|
exportAppHandler = new DefaultExportAppHandler();
|
||||||
@ -1917,30 +1917,28 @@ public class Editor extends JFrame implements RunnerListener {
|
|||||||
new Thread(verbose ? presentHandler : runHandler).start();
|
new Thread(verbose ? presentHandler : runHandler).start();
|
||||||
}
|
}
|
||||||
|
|
||||||
// DAM: in Arduino, this is compile
|
class BuildHandler implements Runnable {
|
||||||
class DefaultRunHandler implements Runnable {
|
|
||||||
public void run() {
|
|
||||||
try {
|
|
||||||
sketch.prepare();
|
|
||||||
sketch.build(false);
|
|
||||||
statusNotice(_("Done compiling."));
|
|
||||||
} catch (Exception e) {
|
|
||||||
status.unprogress();
|
|
||||||
statusError(e);
|
|
||||||
}
|
|
||||||
|
|
||||||
status.unprogress();
|
private final boolean verbose;
|
||||||
toolbar.deactivate(EditorToolbar.RUN);
|
|
||||||
|
public BuildHandler() {
|
||||||
|
this(false);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// DAM: in Arduino, this is compile (with verbose output)
|
public BuildHandler(boolean verbose) {
|
||||||
class DefaultPresentHandler implements Runnable {
|
this.verbose = verbose;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
try {
|
try {
|
||||||
sketch.prepare();
|
sketch.prepare();
|
||||||
sketch.build(true);
|
sketch.build(verbose);
|
||||||
statusNotice(_("Done compiling."));
|
statusNotice(_("Done compiling."));
|
||||||
|
} catch (PreferencesMapException e) {
|
||||||
|
statusError(I18n.format(
|
||||||
|
_("Error while compiling: missing '{0}' configuration parameter"),
|
||||||
|
e.getMessage()));
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
status.unprogress();
|
status.unprogress();
|
||||||
statusError(e);
|
statusError(e);
|
||||||
@ -1953,11 +1951,8 @@ public class Editor extends JFrame implements RunnerListener {
|
|||||||
|
|
||||||
class DefaultStopHandler implements Runnable {
|
class DefaultStopHandler implements Runnable {
|
||||||
public void run() {
|
public void run() {
|
||||||
try {
|
// TODO
|
||||||
// DAM: we should try to kill the compilation or upload process here.
|
// DAM: we should try to kill the compilation or upload process here.
|
||||||
} catch (Exception e) {
|
|
||||||
statusError(e);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -29,6 +29,7 @@ import processing.app.debug.Compiler.ProgressListener;
|
|||||||
import processing.app.debug.RunnerException;
|
import processing.app.debug.RunnerException;
|
||||||
import processing.app.forms.PasswordAuthorizationDialog;
|
import processing.app.forms.PasswordAuthorizationDialog;
|
||||||
import processing.app.helpers.OSUtils;
|
import processing.app.helpers.OSUtils;
|
||||||
|
import processing.app.helpers.PreferencesMapException;
|
||||||
import processing.app.packages.Library;
|
import processing.app.packages.Library;
|
||||||
import static processing.app.I18n._;
|
import static processing.app.I18n._;
|
||||||
|
|
||||||
@ -1129,7 +1130,7 @@ public class Sketch {
|
|||||||
* @return null if compilation failed, main class name if not
|
* @return null if compilation failed, main class name if not
|
||||||
* @throws RunnerException
|
* @throws RunnerException
|
||||||
*/
|
*/
|
||||||
public String build(boolean verbose) throws RunnerException {
|
public String build(boolean verbose) throws RunnerException, PreferencesMapException {
|
||||||
return build(tempBuildFolder.getAbsolutePath(), verbose);
|
return build(tempBuildFolder.getAbsolutePath(), verbose);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1142,7 +1143,7 @@ public class Sketch {
|
|||||||
*
|
*
|
||||||
* @return null if compilation failed, main class name if not
|
* @return null if compilation failed, main class name if not
|
||||||
*/
|
*/
|
||||||
public String build(String buildPath, boolean verbose) throws RunnerException {
|
public String build(String buildPath, boolean verbose) throws RunnerException, PreferencesMapException {
|
||||||
// run the preprocessor
|
// run the preprocessor
|
||||||
editor.status.progressUpdate(20);
|
editor.status.progressUpdate(20);
|
||||||
|
|
||||||
|
@ -49,10 +49,7 @@ import processing.app.I18n;
|
|||||||
import processing.app.PreferencesData;
|
import processing.app.PreferencesData;
|
||||||
import processing.app.SketchCode;
|
import processing.app.SketchCode;
|
||||||
import processing.app.SketchData;
|
import processing.app.SketchData;
|
||||||
import processing.app.helpers.FileUtils;
|
import processing.app.helpers.*;
|
||||||
import processing.app.helpers.PreferencesMap;
|
|
||||||
import processing.app.helpers.ProcessUtils;
|
|
||||||
import processing.app.helpers.StringReplacer;
|
|
||||||
import processing.app.helpers.filefilters.OnlyDirs;
|
import processing.app.helpers.filefilters.OnlyDirs;
|
||||||
import processing.app.packages.Library;
|
import processing.app.packages.Library;
|
||||||
import processing.app.packages.LibraryList;
|
import processing.app.packages.LibraryList;
|
||||||
@ -86,7 +83,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
|
|
||||||
private ProgressListener progressListener;
|
private ProgressListener progressListener;
|
||||||
|
|
||||||
static public String build(SketchData data, String buildPath, File tempBuildFolder, ProgressListener progListener, boolean verbose) throws RunnerException {
|
static public String build(SketchData data, String buildPath, File tempBuildFolder, ProgressListener progListener, boolean verbose) throws RunnerException, PreferencesMapException {
|
||||||
if (SketchData.checkSketchFile(data.getPrimaryFile()) == null)
|
if (SketchData.checkSketchFile(data.getPrimaryFile()) == null)
|
||||||
BaseNoGui.showError(_("Bad file selected"),
|
BaseNoGui.showError(_("Bad file selected"),
|
||||||
_("Bad sketch primary file or bad sketck directory structure"), null);
|
_("Bad sketch primary file or bad sketck directory structure"), null);
|
||||||
@ -338,12 +335,12 @@ public class Compiler implements MessageConsumer {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Compile sketch.
|
* Compile sketch.
|
||||||
* @param buildPath
|
* @param _verbose
|
||||||
*
|
*
|
||||||
* @return true if successful.
|
* @return true if successful.
|
||||||
* @throws RunnerException Only if there's a problem. Only then.
|
* @throws RunnerException Only if there's a problem. Only then.
|
||||||
*/
|
*/
|
||||||
public boolean compile(boolean _verbose) throws RunnerException {
|
public boolean compile(boolean _verbose) throws RunnerException, PreferencesMapException {
|
||||||
preprocess(prefs.get("build.path"));
|
preprocess(prefs.get("build.path"));
|
||||||
|
|
||||||
verbose = _verbose || PreferencesData.getBoolean("build.verbose");
|
verbose = _verbose || PreferencesData.getBoolean("build.verbose");
|
||||||
@ -404,11 +401,11 @@ public class Compiler implements MessageConsumer {
|
|||||||
|
|
||||||
// 5. extract EEPROM data (from EEMEM directive) to .eep file.
|
// 5. extract EEPROM data (from EEMEM directive) to .eep file.
|
||||||
progressListener.progress(70);
|
progressListener.progress(70);
|
||||||
compileEep();
|
runRecipe("recipe.objcopy.eep.pattern");
|
||||||
|
|
||||||
// 6. build the .hex file
|
// 6. build the .hex file
|
||||||
progressListener.progress(80);
|
progressListener.progress(80);
|
||||||
compileHex();
|
runRecipe("recipe.objcopy.hex.pattern");
|
||||||
|
|
||||||
progressListener.progress(90);
|
progressListener.progress(90);
|
||||||
return true;
|
return true;
|
||||||
@ -505,7 +502,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
|
|
||||||
private List<File> compileFiles(File outputPath, File sourcePath,
|
private List<File> compileFiles(File outputPath, File sourcePath,
|
||||||
boolean recurse, List<File> includeFolders)
|
boolean recurse, List<File> includeFolders)
|
||||||
throws RunnerException {
|
throws RunnerException, PreferencesMapException {
|
||||||
List<File> sSources = findFilesInFolder(sourcePath, "S", recurse);
|
List<File> sSources = findFilesInFolder(sourcePath, "S", recurse);
|
||||||
List<File> cSources = findFilesInFolder(sourcePath, "c", recurse);
|
List<File> cSources = findFilesInFolder(sourcePath, "c", recurse);
|
||||||
List<File> cppSources = findFilesInFolder(sourcePath, "cpp", recurse);
|
List<File> cppSources = findFilesInFolder(sourcePath, "cpp", recurse);
|
||||||
@ -514,7 +511,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
for (File file : sSources) {
|
for (File file : sSources) {
|
||||||
File objectFile = new File(outputPath, file.getName() + ".o");
|
File objectFile = new File(outputPath, file.getName() + ".o");
|
||||||
objectPaths.add(objectFile);
|
objectPaths.add(objectFile);
|
||||||
String[] cmd = getCommandCompilerS(includeFolders, file, objectFile);
|
String[] cmd = getCommandCompilerByRecipe(includeFolders, file, objectFile, "recipe.S.o.pattern");
|
||||||
execAsynchronously(cmd);
|
execAsynchronously(cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -524,7 +521,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
objectPaths.add(objectFile);
|
objectPaths.add(objectFile);
|
||||||
if (isAlreadyCompiled(file, objectFile, dependFile, prefs))
|
if (isAlreadyCompiled(file, objectFile, dependFile, prefs))
|
||||||
continue;
|
continue;
|
||||||
String[] cmd = getCommandCompilerC(includeFolders, file, objectFile);
|
String[] cmd = getCommandCompilerByRecipe(includeFolders, file, objectFile, "recipe.c.o.pattern");
|
||||||
execAsynchronously(cmd);
|
execAsynchronously(cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -534,7 +531,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
objectPaths.add(objectFile);
|
objectPaths.add(objectFile);
|
||||||
if (isAlreadyCompiled(file, objectFile, dependFile, prefs))
|
if (isAlreadyCompiled(file, objectFile, dependFile, prefs))
|
||||||
continue;
|
continue;
|
||||||
String[] cmd = getCommandCompilerCPP(includeFolders, file, objectFile);
|
String[] cmd = getCommandCompilerByRecipe(includeFolders, file, objectFile, "recipe.cpp.o.pattern");
|
||||||
execAsynchronously(cmd);
|
execAsynchronously(cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -545,7 +542,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
* Strip escape sequences used in makefile dependency files (.d)
|
* Strip escape sequences used in makefile dependency files (.d)
|
||||||
* https://github.com/arduino/Arduino/issues/2255#issuecomment-57645845
|
* https://github.com/arduino/Arduino/issues/2255#issuecomment-57645845
|
||||||
*
|
*
|
||||||
* @param dep
|
* @param line
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
protected static String unescapeDepFile(String line) {
|
protected static String unescapeDepFile(String line) {
|
||||||
@ -814,9 +811,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
System.err.print(s);
|
System.err.print(s);
|
||||||
}
|
}
|
||||||
|
|
||||||
private String[] getCommandCompilerS(List<File> includeFolders,
|
private String[] getCommandCompilerByRecipe(List<File> includeFolders, File sourceFile, File objectFile, String recipe) throws PreferencesMapException, RunnerException {
|
||||||
File sourceFile, File objectFile)
|
|
||||||
throws RunnerException {
|
|
||||||
String includes = prepareIncludes(includeFolders);
|
String includes = prepareIncludes(includeFolders);
|
||||||
PreferencesMap dict = new PreferencesMap(prefs);
|
PreferencesMap dict = new PreferencesMap(prefs);
|
||||||
dict.put("ide_version", "" + BaseNoGui.REVISION);
|
dict.put("ide_version", "" + BaseNoGui.REVISION);
|
||||||
@ -824,45 +819,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
dict.put("source_file", sourceFile.getAbsolutePath());
|
dict.put("source_file", sourceFile.getAbsolutePath());
|
||||||
dict.put("object_file", objectFile.getAbsolutePath());
|
dict.put("object_file", objectFile.getAbsolutePath());
|
||||||
|
|
||||||
try {
|
String cmd = prefs.getOrExcept(recipe);
|
||||||
String cmd = prefs.get("recipe.S.o.pattern");
|
|
||||||
return StringReplacer.formatAndSplit(cmd, dict, true);
|
|
||||||
} catch (Exception e) {
|
|
||||||
throw new RunnerException(e);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private String[] getCommandCompilerC(List<File> includeFolders,
|
|
||||||
File sourceFile, File objectFile)
|
|
||||||
throws RunnerException {
|
|
||||||
String includes = prepareIncludes(includeFolders);
|
|
||||||
|
|
||||||
PreferencesMap dict = new PreferencesMap(prefs);
|
|
||||||
dict.put("ide_version", "" + BaseNoGui.REVISION);
|
|
||||||
dict.put("includes", includes);
|
|
||||||
dict.put("source_file", sourceFile.getAbsolutePath());
|
|
||||||
dict.put("object_file", objectFile.getAbsolutePath());
|
|
||||||
|
|
||||||
String cmd = prefs.get("recipe.c.o.pattern");
|
|
||||||
try {
|
|
||||||
return StringReplacer.formatAndSplit(cmd, dict, true);
|
|
||||||
} catch (Exception e) {
|
|
||||||
throw new RunnerException(e);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private String[] getCommandCompilerCPP(List<File> includeFolders,
|
|
||||||
File sourceFile, File objectFile)
|
|
||||||
throws RunnerException {
|
|
||||||
String includes = prepareIncludes(includeFolders);
|
|
||||||
|
|
||||||
PreferencesMap dict = new PreferencesMap(prefs);
|
|
||||||
dict.put("ide_version", "" + BaseNoGui.REVISION);
|
|
||||||
dict.put("includes", includes);
|
|
||||||
dict.put("source_file", sourceFile.getAbsolutePath());
|
|
||||||
dict.put("object_file", objectFile.getAbsolutePath());
|
|
||||||
|
|
||||||
String cmd = prefs.get("recipe.cpp.o.pattern");
|
|
||||||
try {
|
try {
|
||||||
return StringReplacer.formatAndSplit(cmd, dict, true);
|
return StringReplacer.formatAndSplit(cmd, dict, true);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
@ -909,21 +866,21 @@ public class Compiler implements MessageConsumer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 1. compile the sketch (already in the buildPath)
|
// 1. compile the sketch (already in the buildPath)
|
||||||
void compileSketch(List<File> includeFolders) throws RunnerException {
|
void compileSketch(List<File> includeFolders) throws RunnerException, PreferencesMapException {
|
||||||
File buildPath = prefs.getFile("build.path");
|
File buildPath = prefs.getFile("build.path");
|
||||||
objectFiles.addAll(compileFiles(buildPath, buildPath, false, includeFolders));
|
objectFiles.addAll(compileFiles(buildPath, buildPath, false, includeFolders));
|
||||||
}
|
}
|
||||||
|
|
||||||
// 2. compile the libraries, outputting .o files to:
|
// 2. compile the libraries, outputting .o files to:
|
||||||
// <buildPath>/<library>/
|
// <buildPath>/<library>/
|
||||||
void compileLibraries(List<File> includeFolders) throws RunnerException {
|
void compileLibraries(List<File> includeFolders) throws RunnerException, PreferencesMapException {
|
||||||
for (Library lib : importedLibraries) {
|
for (Library lib : importedLibraries) {
|
||||||
compileLibrary(lib, includeFolders);
|
compileLibrary(lib, includeFolders);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void compileLibrary(Library lib, List<File> includeFolders)
|
private void compileLibrary(Library lib, List<File> includeFolders)
|
||||||
throws RunnerException {
|
throws RunnerException, PreferencesMapException {
|
||||||
File libFolder = lib.getSrcFolder();
|
File libFolder = lib.getSrcFolder();
|
||||||
File libBuildFolder = prefs.getFile(("build.path"), lib.getName());
|
File libBuildFolder = prefs.getFile(("build.path"), lib.getName());
|
||||||
|
|
||||||
@ -949,7 +906,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void recursiveCompileFilesInFolder(File srcBuildFolder, File srcFolder, List<File> includeFolders) throws RunnerException {
|
private void recursiveCompileFilesInFolder(File srcBuildFolder, File srcFolder, List<File> includeFolders) throws RunnerException, PreferencesMapException {
|
||||||
compileFilesInFolder(srcBuildFolder, srcFolder, includeFolders);
|
compileFilesInFolder(srcBuildFolder, srcFolder, includeFolders);
|
||||||
for (File subFolder : srcFolder.listFiles(new OnlyDirs())) {
|
for (File subFolder : srcFolder.listFiles(new OnlyDirs())) {
|
||||||
File subBuildFolder = new File(srcBuildFolder, subFolder.getName());
|
File subBuildFolder = new File(srcBuildFolder, subFolder.getName());
|
||||||
@ -957,7 +914,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void compileFilesInFolder(File buildFolder, File srcFolder, List<File> includeFolders) throws RunnerException {
|
private void compileFilesInFolder(File buildFolder, File srcFolder, List<File> includeFolders) throws RunnerException, PreferencesMapException {
|
||||||
createFolder(buildFolder);
|
createFolder(buildFolder);
|
||||||
List<File> objects = compileFiles(buildFolder, srcFolder, false, includeFolders);
|
List<File> objects = compileFiles(buildFolder, srcFolder, false, includeFolders);
|
||||||
objectFiles.addAll(objects);
|
objectFiles.addAll(objects);
|
||||||
@ -968,7 +925,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
// Also compiles the variant (if it supplies actual source files),
|
// Also compiles the variant (if it supplies actual source files),
|
||||||
// which are included in the link directly (not through core.a)
|
// which are included in the link directly (not through core.a)
|
||||||
void compileCore()
|
void compileCore()
|
||||||
throws RunnerException {
|
throws RunnerException, PreferencesMapException {
|
||||||
|
|
||||||
File coreFolder = prefs.getFile("build.core.path");
|
File coreFolder = prefs.getFile("build.core.path");
|
||||||
File variantFolder = prefs.getFile("build.variant.path");
|
File variantFolder = prefs.getFile("build.variant.path");
|
||||||
@ -1024,8 +981,8 @@ public class Compiler implements MessageConsumer {
|
|||||||
dict.put("object_file", file.getAbsolutePath());
|
dict.put("object_file", file.getAbsolutePath());
|
||||||
|
|
||||||
String[] cmdArray;
|
String[] cmdArray;
|
||||||
|
String cmd = prefs.getOrExcept("recipe.ar.pattern");
|
||||||
try {
|
try {
|
||||||
String cmd = prefs.get("recipe.ar.pattern");
|
|
||||||
cmdArray = StringReplacer.formatAndSplit(cmd, dict, true);
|
cmdArray = StringReplacer.formatAndSplit(cmd, dict, true);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RunnerException(e);
|
throw new RunnerException(e);
|
||||||
@ -1040,7 +997,7 @@ public class Compiler implements MessageConsumer {
|
|||||||
|
|
||||||
// 4. link it all together into the .elf file
|
// 4. link it all together into the .elf file
|
||||||
void compileLink()
|
void compileLink()
|
||||||
throws RunnerException {
|
throws RunnerException, PreferencesMapException {
|
||||||
|
|
||||||
// TODO: Make the --relax thing in configuration files.
|
// TODO: Make the --relax thing in configuration files.
|
||||||
|
|
||||||
@ -1063,8 +1020,8 @@ public class Compiler implements MessageConsumer {
|
|||||||
dict.put("ide_version", "" + BaseNoGui.REVISION);
|
dict.put("ide_version", "" + BaseNoGui.REVISION);
|
||||||
|
|
||||||
String[] cmdArray;
|
String[] cmdArray;
|
||||||
|
String cmd = prefs.getOrExcept("recipe.c.combine.pattern");
|
||||||
try {
|
try {
|
||||||
String cmd = prefs.get("recipe.c.combine.pattern");
|
|
||||||
cmdArray = StringReplacer.formatAndSplit(cmd, dict, true);
|
cmdArray = StringReplacer.formatAndSplit(cmd, dict, true);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RunnerException(e);
|
throw new RunnerException(e);
|
||||||
@ -1072,29 +1029,13 @@ public class Compiler implements MessageConsumer {
|
|||||||
execAsynchronously(cmdArray);
|
execAsynchronously(cmdArray);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 5. extract EEPROM data (from EEMEM directive) to .eep file.
|
void runRecipe(String recipe) throws RunnerException, PreferencesMapException {
|
||||||
void compileEep() throws RunnerException {
|
|
||||||
PreferencesMap dict = new PreferencesMap(prefs);
|
PreferencesMap dict = new PreferencesMap(prefs);
|
||||||
dict.put("ide_version", "" + BaseNoGui.REVISION);
|
dict.put("ide_version", "" + BaseNoGui.REVISION);
|
||||||
|
|
||||||
String[] cmdArray;
|
String[] cmdArray;
|
||||||
|
String cmd = prefs.getOrExcept(recipe);
|
||||||
try {
|
try {
|
||||||
String cmd = prefs.get("recipe.objcopy.eep.pattern");
|
|
||||||
cmdArray = StringReplacer.formatAndSplit(cmd, dict, true);
|
|
||||||
} catch (Exception e) {
|
|
||||||
throw new RunnerException(e);
|
|
||||||
}
|
|
||||||
execAsynchronously(cmdArray);
|
|
||||||
}
|
|
||||||
|
|
||||||
// 6. build the .hex file
|
|
||||||
void compileHex() throws RunnerException {
|
|
||||||
PreferencesMap dict = new PreferencesMap(prefs);
|
|
||||||
dict.put("ide_version", "" + BaseNoGui.REVISION);
|
|
||||||
|
|
||||||
String[] cmdArray;
|
|
||||||
try {
|
|
||||||
String cmd = prefs.get("recipe.objcopy.hex.pattern");
|
|
||||||
cmdArray = StringReplacer.formatAndSplit(cmd, dict, true);
|
cmdArray = StringReplacer.formatAndSplit(cmd, dict, true);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RunnerException(e);
|
throw new RunnerException(e);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user