Skip to content

Commit 6db47ce

Browse files
committed
Merge branch 'release/v3.6.3'
2 parents db3b049 + 6f8b9d7 commit 6db47ce

File tree

8 files changed

+41
-9
lines changed

8 files changed

+41
-9
lines changed

HISTORY.rst

+8
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,14 @@ Release Notes
44
PlatformIO 3.0
55
--------------
66

7+
3.6.3 (2018-12-12)
8+
~~~~~~~~~~~~~~~~~~
9+
10+
* Ignore *.asm and *.ASM files when building Arduino-based library (compatibility with Arduino builder)
11+
* Fixed spurious project's "Problems" for `PlatformIO IDE for VSCode <http://docs.platformio.org/page/ide/vscode.html>`__ when ARM mbed framework is used
12+
* Fixed an issue with a broken headers list when generating ".clang_complete" for `Emacs <http://docs.platformio.org/page/ide/emacs.html>`__
13+
(`issue #1960 <https://github.com/platformio/platformio-core/issues/1960>`_)
14+
715
3.6.2 (2018-11-29)
816
~~~~~~~~~~~~~~~~~~
917

docs

platformio/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
import sys
1616

17-
VERSION = (3, 6, 2)
17+
VERSION = (3, 6, 3)
1818
__version__ = ".".join([str(s) for s in VERSION])
1919

2020
__title__ = "platformio"

platformio/app.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ def _lock_state_file(self):
122122
raise exception.HomeDirPermissionsError(dirname(self.path))
123123

124124
def _unlock_state_file(self):
125-
if self._lockfile:
125+
if hasattr(self, "_lockfile") and self._lockfile:
126126
self._lockfile.release()
127127

128128
def __del__(self):

platformio/builder/tools/piolib.py

+20-2
Original file line numberDiff line numberDiff line change
@@ -488,11 +488,29 @@ def get_include_dirs(self):
488488

489489
@property
490490
def src_filter(self):
491-
if isdir(join(self.path, "src")):
492-
return LibBuilderBase.src_filter.fget(self)
491+
src_dir = join(self.path, "src")
492+
if isdir(src_dir):
493+
src_filter = LibBuilderBase.src_filter.fget(self)
494+
for root, _, files in os.walk(src_dir, followlinks=True):
495+
found = False
496+
for fname in files:
497+
if fname.lower().endswith("asm"):
498+
found = True
499+
break
500+
if not found:
501+
continue
502+
rel_path = root.replace(src_dir, "")
503+
if rel_path.startswith(sep):
504+
rel_path = rel_path[1:] + sep
505+
src_filter.append("-<%s*.[aA][sS][mM]>" % rel_path)
506+
return src_filter
507+
493508
src_filter = []
494509
is_utility = isdir(join(self.path, "utility"))
495510
for ext in piotool.SRC_BUILD_EXT + piotool.SRC_HEADER_EXT:
511+
# arduino ide ignores files with .asm or .ASM extensions
512+
if ext.lower() == "asm":
513+
continue
496514
src_filter.append("+<*.%s>" % ext)
497515
if is_utility:
498516
src_filter.append("+<utility%s*.%s>" % (sep, ext))

platformio/ide/tpls/emacs/.clang_complete.tpl

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
% for include in includes:
2-
-I"{{include}}"
2+
-I{{include}}
33
% end
44
% for define in defines:
55
-D{{!define}}

platformio/ide/tpls/vscode/.vscode/c_cpp_properties.json.tpl

+4-1
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,16 @@
5454
% cc_stds = STD_RE.findall(cc_flags)
5555
% cxx_stds = STD_RE.findall(cxx_flags)
5656
%
57+
% # pass only architecture specific flags
58+
% cc_m_flags = " ".join([f.strip() for f in cc_flags.split(" ") if f.strip().startswith("-m")])
59+
%
5760
% if cc_stds:
5861
"cStandard": "c{{ cc_stds[-1] }}",
5962
% end
6063
% if cxx_stds:
6164
"cppStandard": "c++{{ cxx_stds[-1] }}",
6265
% end
63-
"compilerPath": "{{! _escape(cc_path) }} {{! _escape(STD_RE.sub("", cc_flags)) }}"
66+
"compilerPath": "{{! _escape(cc_path) }} {{! _escape(cc_m_flags) }}"
6467
}
6568
]
6669
}

platformio/managers/platform.py

+5-2
Original file line numberDiff line numberDiff line change
@@ -460,8 +460,7 @@ def __init__(self, manifest_path):
460460
self._manifest = util.load_json(manifest_path)
461461

462462
self.pm = PackageManager(
463-
join(util.get_home_dir(), "packages"),
464-
self._manifest.get("packageRepositories"))
463+
join(util.get_home_dir(), "packages"), self.package_repositories)
465464

466465
self.silent = False
467466
self.verbose = False
@@ -516,6 +515,10 @@ def frameworks(self):
516515
def engines(self):
517516
return self._manifest.get("engines")
518517

518+
@property
519+
def package_repositories(self):
520+
return self._manifest.get("packageRepositories")
521+
519522
@property
520523
def manifest(self):
521524
return self._manifest

0 commit comments

Comments
 (0)