diff --git a/HISTORY.rst b/HISTORY.rst index ffc9b7f0..2c41f427 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -4,6 +4,14 @@ Release Notes PlatformIO 2.0 -------------- +2.8.2 (2016-01-29) +~~~~~~~~~~~~~~~~~~ + +* Corrected RAM size for NXP LPC1768 based boards + (`issue #484 `_) +* Exclude only ``test`` and ``tests`` folders from build process +* Reverted ``-Wl,-whole-archive`` hook for ST STM32 and mbed + 2.8.1 (2016-01-29) ~~~~~~~~~~~~~~~~~~ diff --git a/docs/projectconf.rst b/docs/projectconf.rst index d026b33c..93aeabc4 100644 --- a/docs/projectconf.rst +++ b/docs/projectconf.rst @@ -205,7 +205,7 @@ format of this option is ``C-like long integer`` value with ``L`` suffix. The 1 Hertz is equal to ``1L``, then 16 Mhz (Mega Hertz) is equal to ``16000000L``. The full list of ``board_f_cpu`` for the popular embedded platforms you can -find in *Boards* section of :ref:`platforms`. See "Frequency" column. You can +find in *Boards* section of :ref:`platforms`. See "Frequency" column. You can overclock a board by specifying a ``board_f_cpu`` value other than the default. @@ -335,8 +335,9 @@ be applied in theirs order. `GLOB Patterns `_ are allowed. By default, ``src_filter`` is predefined to -``+<*> -<.git/> - -``, which means "includes ALL files, then -exclude ``.git`` and ``svn`` repository folders and exclude ``examples`` folder. +``+<*> -<.git/> - - - - -``, +which means "includes ALL files, then +exclude ``.git`` and ``svn`` repository folders, ``example`` ... folder. This option can be set by global environment variable :envvar:`PLATFORMIO_SRC_FILTER`. diff --git a/platformio/__init__.py b/platformio/__init__.py index 94a227fb..234572c2 100644 --- a/platformio/__init__.py +++ b/platformio/__init__.py @@ -14,7 +14,7 @@ import sys -VERSION = (2, 8, 1) +VERSION = (2, 8, 2) __version__ = ".".join([str(s) for s in VERSION]) __title__ = "platformio" diff --git a/platformio/boards/nxplpc.json b/platformio/boards/nxplpc.json index f85f5302..de29b022 100644 --- a/platformio/boards/nxplpc.json +++ b/platformio/boards/nxplpc.json @@ -9,7 +9,7 @@ "name": "NXP mbed LPC1768", "platform": "nxplpc", "upload": { - "maximum_ram_size": 32768, + "maximum_ram_size": 65536, "maximum_size": 524288 }, "url": "http://developer.mbed.org/platforms/mbed-LPC1768/", @@ -105,7 +105,7 @@ "name": "u-blox C027", "platform": "nxplpc", "upload": { - "maximum_ram_size": 32768, + "maximum_ram_size": 65536, "maximum_size": 524288 }, "url": "https://developer.mbed.org/platforms/u-blox-C027/", diff --git a/platformio/builder/scripts/frameworks/mbed.py b/platformio/builder/scripts/frameworks/mbed.py index 76903afd..84465d4a 100644 --- a/platformio/builder/scripts/frameworks/mbed.py +++ b/platformio/builder/scripts/frameworks/mbed.py @@ -195,6 +195,20 @@ def get_build_flags(data): return flags +def _mbed_whole_archive_hook(flags): + if (not isinstance(flags, list) or + env.get("BOARD_OPTIONS", {}).get("platform") != "ststm32"): + return flags + + for pos, flag in enumerate(flags[:]): + if isinstance(flag, basestring): + continue + flags.insert(pos, "-Wl,-whole-archive") + flags.insert(pos + 2, "-Wl,-no-whole-archive") + + return flags + + board_type = env.subst("$BOARD") variant = MBED_VARIANTS[ board_type] if board_type in MBED_VARIANTS else board_type.upper() @@ -205,6 +219,8 @@ build_flags = get_build_flags(eixdata) variant_dir = join("$PLATFORMFW_DIR", "variant", variant) env.Replace( + _mbed_whole_archive_hook=_mbed_whole_archive_hook, + _LIBFLAGS="${_mbed_whole_archive_hook(%s)}" % env.get("_LIBFLAGS")[2:-1], CPPFLAGS=build_flags.get("CPPFLAGS", []), CFLAGS=build_flags.get("CFLAGS", []), CXXFLAGS=build_flags.get("CXXFLAGS", []), diff --git a/platformio/builder/tools/platformio.py b/platformio/builder/tools/platformio.py index b1401944..7ecfa34e 100644 --- a/platformio/builder/tools/platformio.py +++ b/platformio/builder/tools/platformio.py @@ -27,8 +27,9 @@ from platformio.util import pioversion_to_intstr SRC_BUILD_EXT = ["c", "cpp", "S", "spp", "SPP", "sx", "s", "asm", "ASM"] SRC_HEADER_EXT = ["h", "hpp"] SRC_DEFAULT_FILTER = " ".join([ - "+<*>", "-<.git%s>" % sep, "-" % sep, "-" % sep, - "-" % sep + "+<*>", "-<.git%s>" % sep, "-" % sep, + "-" % sep, "-" % sep, + "-" % sep, "-" % sep ])