Skip to content

Commit 1b3f1fa

Browse files
authored
Merge branch 'master' into typo_fixes
2 parents 7c0206b + 5eb3d48 commit 1b3f1fa

File tree

2 files changed

+21
-5
lines changed

2 files changed

+21
-5
lines changed

README.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,14 @@ The directories of Git and Mercurial executables (`git` and `hg`) need to be in
6666
* Compilers: GCC ARM, ARM Compiler 5, IAR.
6767
* IDE: Keil uVision, DS-5, IAR Workbench.
6868

69+
<span class="tips">**Note:** When installing the ARM Compiler 5 on a 64-bit Linux machine, you may need to also install the i386 architecture package:</span>
70+
71+
```
72+
$ sudo dpkg --add-architecture i386
73+
$ sudo apt-get update
74+
$ sudo apt-get install libc6:i386 libncurses5:i386 libstdc++6:i386
75+
```
76+
6977
### Video tutorial for manual installation
7078

7179
<span class="images">[![Video tutorial](http://img.youtube.com/vi/cM0dFoTuU14/0.jpg)](https://www.youtube.com/watch?v=cM0dFoTuU14)</span>
@@ -286,7 +294,7 @@ Edit `mbed_settings.py` to set your toolchain:
286294

287295
* To use the [ARM Compiler toolchain](https://developer.arm.com/products/software-development-tools/compilers/arm-compiler-5/downloads), set `ARM_PATH` to the *base* directory of your ARM Compiler installation (example: C:\Program Files\ARM\armcc5.06). The recommended version of the ARM Compiler toolchain is 5.06.
288296
* To use the [GNU ARM Embedded toolchain (GCC) version 6](https://developer.arm.com/open-source/gnu-toolchain/gnu-rm/downloads), set `GCC_ARM_PATH` to the *binary* directory of your GCC ARM installation (example: C:\Program Files\GNU Tools ARM Embedded\6 2017q2\bin). Use version 6 of GCC ARM Embedded; version 5.0 or any older version might be incompatible with the tools.
289-
* To use the [IAR EWARM toolhain](https://www.iar.com/iar-embedded-workbench/#!?architecture=ARM), set `IAR_PATH` to the *base* directory of your IAR installation. Use versions 7.80 of IAR EWARM; prior versions might be incompatible with the tools.
297+
* To use the [IAR EWARM toolchain](https://www.iar.com/iar-embedded-workbench/#!?architecture=ARM), set `IAR_PATH` to the *base* directory of your IAR installation (example: C:\Program Files (x86)\IAR Systems\Embedded Workbench 7.5\arm). Use version 7.80.x of the IAR EWARM; newer (or older) versions might be incompatible with the tools.
290298

291299
Because `mbed_settings.py` contains local settings (possibly relevant only to a single OS on a single machine), you should not check it into version control.
292300

mbed/mbed.py

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1943,12 +1943,13 @@ def publish(all_refs=None, msg=None, top=True):
19431943
dict(name=['-I', '--ignore'], action='store_true', help='Ignore errors related to unpublished libraries, unpublished or uncommitted changes, and attempt to update from associated remote repository URLs.'),
19441944
dict(name='--depth', nargs='?', help='Number of revisions to fetch from the remote repository. Default: all revisions.'),
19451945
dict(name='--protocol', nargs='?', help='Transport protocol for the source control management. Supported: https, http, ssh, git. Default: inferred from URL.'),
1946+
dict(name=['-l', '--latest-deps'], action='store_true', help='Update all dependencies to the latest revision of their current branch. WARNING: Ignores lib files'),
19461947
help='Update to branch, tag, revision or latest',
19471948
description=(
19481949
"Updates the current program or library and its dependencies to specified\nbranch, tag or revision.\n"
19491950
"Alternatively fetches from associated remote repository URL and updates to the\n"
19501951
"latest revision in the current branch."))
1951-
def update(rev=None, clean=False, clean_files=False, clean_deps=False, ignore=False, top=True, depth=None, protocol=None):
1952+
def update(rev=None, clean=False, clean_files=False, clean_deps=False, ignore=False, top=True, depth=None, protocol=None, latest_deps=False):
19521953
if top and clean:
19531954
sync()
19541955

@@ -1964,6 +1965,11 @@ def update(rev=None, clean=False, clean_files=False, clean_deps=False, ignore=Fa
19641965
"This %s is in detached HEAD state, and you won't be able to receive updates from the remote repository until you either checkout a branch or create a new one.\n"
19651966
"You can checkout a branch using \"%s checkout <branch_name>\" command before running \"mbed update\"." % (cwd_type, repo.scm.name), 1)
19661967

1968+
if repo.isdetached() and latest_deps:
1969+
warning(
1970+
"The repo %s is in detached HEAD state, and you won't be able to receive updates from the remote repository until you either checkout a branch or create a new one.\n"
1971+
"You can checkout a branch using \"%s checkout <branch_name>\" command before running \"mbed update\"." % (repo.name, repo.scm.name))
1972+
19671973
if repo.is_local and not repo.rev:
19681974
action("Skipping unpublished empty %s \"%s\"" % (
19691975
cwd_type if top else cwd_dest,
@@ -2037,7 +2043,7 @@ def update(rev=None, clean=False, clean_files=False, clean_deps=False, ignore=Fa
20372043
repo.ignore(relpath(repo.path, lib.path))
20382044
else:
20392045
with cd(lib.path):
2040-
update(lib.rev, clean=clean, clean_files=clean_files, clean_deps=clean_deps, ignore=ignore, top=False)
2046+
update(None if latest_deps else lib.rev, clean=clean, clean_files=clean_files, clean_deps=clean_deps, ignore=ignore, top=False, latest_deps=latest_deps)
20412047

20422048
if top:
20432049
program = Program(repo.path)
@@ -2246,7 +2252,7 @@ def compile_(toolchain=None, target=None, profile=False, compile_library=False,
22462252
+ (['-v'] if verbose else [])
22472253
+ args,
22482254
env=env)
2249-
2255+
22502256
if flash:
22512257
fw_name = artifact_name if artifact_name else program.name
22522258
fw_fbase = os.path.join(build_path, fw_name)
@@ -2375,10 +2381,11 @@ def test_(toolchain=None, target=None, compile_list=False, run_list=False, compi
23752381
dict(name='--source', action='append', help='Source directory. Default: . (current dir)'),
23762382
dict(name=['-c', '--clean'], action='store_true', help='Clean the build directory before compiling'),
23772383
dict(name=['-S', '--supported'], dest='supported', action='store_true', help='Shows supported matrix of targets and toolchains'),
2384+
dict(name='--app-config', dest="app_config", help="Path of an app configuration file (Default is to look for 'mbed_app.json')"),
23782385
help='Generate an IDE project',
23792386
description=(
23802387
"Generate IDE project files for the current program."))
2381-
def export(ide=None, target=None, source=False, clean=False, supported=False):
2388+
def export(ide=None, target=None, source=False, clean=False, supported=False, app_config=None):
23822389
# Gather remaining arguments
23832390
args = remainder
23842391
# Find the root of the program
@@ -2416,6 +2423,7 @@ def export(ide=None, target=None, source=False, clean=False, supported=False):
24162423
+ ['-m', target]
24172424
+ (['-c'] if clean else [])
24182425
+ list(chain.from_iterable(izip(repeat('--source'), source)))
2426+
+ (['--app-config', app_config] if app_config else [])
24192427
+ args,
24202428
env=env)
24212429

0 commit comments

Comments
 (0)