Parcourir la source

Switched to the new library layout

Benoit Blanchon il y a 10 ans
Parent
commit
283dffc035
6 fichiers modifiés avec 25 ajouts et 41 suppressions
  1. 0 24
      ArduinoJson.cpp
  2. 0 13
      ArduinoJson.h
  3. 2 1
      CHANGELOG.md
  4. 8 0
      library.properties
  5. 2 3
      scripts/build-arduino-package.sh
  6. 13 0
      src/ArduinoJson.h

+ 0 - 24
ArduinoJson.cpp

@@ -1,24 +0,0 @@
-// Copyright Benoit Blanchon 2014-2015
-// MIT License
-//
-// Arduino JSON library
-// https://github.com/bblanchon/ArduinoJson
-
-#ifdef ARDUINO
-
-// This file is here to help the Arduino IDE find the other files.
-
-#include "src/Arduino/Print.cpp"
-#include "src/DynamicJsonBuffer.cpp"
-#include "src/Internals/IndentedPrint.cpp"
-#include "src/Internals/JsonParser.cpp"
-#include "src/Internals/List.cpp"
-#include "src/Internals/Prettyfier.cpp"
-#include "src/Internals/QuotedString.cpp"
-#include "src/Internals/StringBuilder.cpp"
-#include "src/JsonArray.cpp"
-#include "src/JsonBuffer.cpp"
-#include "src/JsonObject.cpp"
-#include "src/JsonVariant.cpp"
-
-#endif

+ 0 - 13
ArduinoJson.h

@@ -1,13 +0,0 @@
-// Copyright Benoit Blanchon 2014-2015
-// MIT License
-//
-// Arduino JSON library
-// https://github.com/bblanchon/ArduinoJson
-
-#ifdef ARDUINO
-
-// This file is here to help the Arduino IDE find the other files.
-
-#include "include/ArduinoJson.h"
-
-#endif

+ 2 - 1
CHANGELOG.md

@@ -5,7 +5,8 @@ v5.0 (currently under development)
 ----
 
 * Added support of `String` class (issue #55, #56, #70, #77)
-* Redesigned `JsonVariant` to leverage converting constructors instead of assignment operators.
+* Redesigned `JsonVariant` to leverage converting constructors instead of assignment operators
+* Switched to new library layout (requires Arduino 1.0.6 or above)
 
 **BREAKING CHANGES**:
 - `JsonObject::add()` was renamed to `set()`

+ 8 - 0
library.properties

@@ -0,0 +1,8 @@
+name=ArduinoJson
+version=5.0.0
+author=Benoit Blanchon <blog.benoitblanchon.fr>
+maintainer=Benoit Blanchon <blog.benoitblanchon.fr>
+sentence=An efficient and elegant JSON library for Arduino.
+paragraph=Like this project? Please star it on GitHub!
+url=https://github.com/bblanchon/ArduinoJson
+architectures=*

+ 2 - 3
scripts/build-arduino-package.sh

@@ -15,9 +15,8 @@ rm -f $OUTPUT
 	ArduinoJson/examples \
 	ArduinoJson/include \
 	ArduinoJson/keywords.txt \
+	ArduinoJson/library.properties \
 	ArduinoJson/LICENSE.md \
 	ArduinoJson/README.md \
 	ArduinoJson/src	\
-	ArduinoJson/ArduinoJson.h \
-	ArduinoJson/ArduinoJson.cpp	\
-    -x!ArduinoJson/src/CMakeLists.txt
+	-x!ArduinoJson/src/CMakeLists.txt

+ 13 - 0
src/ArduinoJson.h

@@ -0,0 +1,13 @@
+// Copyright Benoit Blanchon 2014-2015
+// MIT License
+//
+// Arduino JSON library
+// https://github.com/bblanchon/ArduinoJson
+
+// About this file
+// ---------------
+// This file is here to please the Arduino IDE. It must be present in the src/
+// for the IDE to find it. Feel free to ignore this file if your working in
+// another environment
+
+#include "../include/ArduinoJson.h"