mirror of
https://github.com/esp8266/Arduino.git
synced 2025-06-17 22:23:10 +03:00
Added a warning for library using the no longer supported "arch" folder
This commit is contained in:
@ -58,18 +58,24 @@ public class Library {
|
|||||||
// Library sanity checks
|
// Library sanity checks
|
||||||
// ---------------------
|
// ---------------------
|
||||||
|
|
||||||
// 1. Check mandatory properties
|
// Compatibility with 1.5 rev.1 libraries:
|
||||||
|
// "email" field changed to "maintainer"
|
||||||
// provide compatibility with 1.5 rev.1 libs
|
|
||||||
// ("email" field changed to "maintainer")
|
|
||||||
if (!properties.containsKey("maintainer"))
|
if (!properties.containsKey("maintainer"))
|
||||||
properties.put("maintainer", properties.get("email"));
|
properties.put("maintainer", properties.get("email"));
|
||||||
|
|
||||||
|
// Compatibility with 1.5 rev.1 libraries:
|
||||||
|
// "arch" folder no longer supported
|
||||||
|
File archFolder = new File(libFolder, "arch");
|
||||||
|
if (archFolder.isDirectory())
|
||||||
|
throw new IOException("'arch' folder is no longer supported! See "
|
||||||
|
+ "http://goo.gl/gfFJzU for more information");
|
||||||
|
|
||||||
|
// Check mandatory properties
|
||||||
for (String p : MANDATORY_PROPERTIES)
|
for (String p : MANDATORY_PROPERTIES)
|
||||||
if (!properties.containsKey(p))
|
if (!properties.containsKey(p))
|
||||||
throw new IOException("Missing '" + p + "' from library");
|
throw new IOException("Missing '" + p + "' from library");
|
||||||
|
|
||||||
// 2. Check layout
|
// Check layout
|
||||||
boolean useRecursion;
|
boolean useRecursion;
|
||||||
File srcFolder = new File(libFolder, "src");
|
File srcFolder = new File(libFolder, "src");
|
||||||
|
|
||||||
@ -88,7 +94,7 @@ public class Library {
|
|||||||
useRecursion = false;
|
useRecursion = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 3. Warn if root folder contains development leftovers
|
// Warn if root folder contains development leftovers
|
||||||
for (File file : libFolder.listFiles()) {
|
for (File file : libFolder.listFiles()) {
|
||||||
if (file.isDirectory()) {
|
if (file.isDirectory()) {
|
||||||
if (FileUtils.isSCCSOrHiddenFile(file)) {
|
if (FileUtils.isSCCSOrHiddenFile(file)) {
|
||||||
|
Reference in New Issue
Block a user