Commit Graph

814 Commits (ce9d2526f802951989ff0842a3828f7ad76126b8)

Author SHA1 Message Date
Sam Grove 5d7317626c Merge pull request #2249 from c1728p9/client_nanostack_and_seperated
Client nanostack and seperated
2016-07-26 14:30:33 -05:00
Jimmy Brisson 0a2c35c62b Force installation of dependencies in entry points 2016-07-26 14:08:26 -05:00
Sam Grove f9d38bff37 Merge pull request #2062 from bridadan/shorten-test-binary-name
Changing name of test binaries to just test case folder name.
2016-07-26 00:24:08 -05:00
Sam Grove 381b352df5 Merge pull request #2168 from c1728p9/remove_float_printf
Remove floating point formatting in newlib nano
2016-07-26 00:20:45 -05:00
Russ Butler cef844f6bf Break apart client and nanostack dependencies
Move the library files used by both nanostack and client into a common
location.  This allows both client and nanostack to be built stand-alone.

The patch moves the following libraries into a common location:
-mbed-client-c
-mbed-client-randlib
-mbed-trace
-nanostack-hal-mbed-cmsis-rtos
-nanostack-libservice
-sal-stack-nanostack-eventloop

And moves the library 'coap-service' from client into nanostack.
2016-07-26 00:00:20 -05:00
Brian Daniels 7b20b0f8f7 Making mcu and toolchain required parameters for test.py
Also renaming 'target' variable to 'mcu' to match make.py
2016-07-25 14:44:09 -05:00
Brian Daniels 1618e608e7 Test discovery now uses build and toolchain logic
Previously, test discovery throught test.py used its own logic to find
tests. This was mostly a subset of the rules used during the build
process. It respected .mbedignore files, but it did not respect TARGET_,
TOOLCHAIN_, and FEATURES_ directories. This change now uses the same logic
used during building to respect these folders. Tests under these folders
that are not being pulled in for the given target will be ignored.
2016-07-25 14:43:52 -05:00
Sam Grove 03e99031e7 Merge pull request #2225 from theotherjimmy/fix-project-args-traceback
Fix #2223
2016-07-22 18:03:25 -05:00
Brian Daniels 51c575dcc6 Fixed traceback in build_api (typo of resources variable in build_library) 2016-07-22 17:49:54 -05:00
Sam Grove aec3695cc5 Merge pull request #2188 from screamerbg/build-common
[Tools] Unify common routines in build_api.py
2016-07-22 17:04:25 -05:00
Mihail Stoyanov ac86584c42 Unify common routines in build_api.py
Introduce prepare_toolchain() which handles:
 * deduplication of src_paths
 * config initialization
 * toolchain initialization
 * toolchain flags
 * returns toolchain
Introduce scan_resources() which handles:
 * scanning of sources
 * scanning of include dirs
 * inclusion of addition include dirs
 * returns resources
2016-07-22 22:21:39 +01:00
Sam Grove 1880daef0d Merge pull request #2215 from geky/tools-cumulative-overrides
[tools] Modified config to aggregate cumulative overrides against targets
2016-07-22 16:16:41 -05:00
Jimmy Brisson a603bb0e01 Fix "project.py --help - typerror type argument unexpected" (#2223) 2016-07-22 12:59:57 -05:00
Christopher Haster a5ea143c77 Updated config tests to match change in error message 2016-07-22 00:35:13 -05:00
Christopher Haster 9bd7a2fe72 Added proper support for the extra_labels target override
Due to dependencies between the config/target systems, the config
has been modified to preparse the mbed_app.json for overrides.
This means that attributes with dependencies in the targets are
only valid at the application level. A hard error has been
added for these attributes if they are supplied at the library
level.
2016-07-22 00:35:13 -05:00
Christopher Haster f2051b217a Modified config to explicitly update cumulative attributes in targets
Modified '_process_config_and_overrides' to update cumulative
attributes based on cumulative overrides found during walking config
files.

This should remove most of the disparity between the config target
cumulative overrides and cumulative attributes set in targets.json.
These cumulative overrides are updated after the global target
instantiation though, which may cause internal build tool state
dependent on cumulative attributes to not correctly reflect all
cumulative overrides.
2016-07-22 00:35:13 -05:00
Christopher Haster 0fcb20e8c1 Generalized handling of cumulative attributes in target overrides
In tools/config.py, Config now aggregates all cumulative attributes in
target overrides.

{
  "target_overrides": {
    "K64F": {
      "target.features_add": ["UVISOR"],
      "target.extra_labels_add": ["UVISOR_SUPPORTED"],
      "target.macros_add": ["UVISOR_MACRO"],
      "target.device_has_add": ["UVISOR_HAS"]
    }
  }
}

Note: no action is performed on overrides yet
2016-07-22 00:35:13 -05:00
Sam Grove f817ec136c Merge pull request #2142 from theotherjimmy/anti-remove-repo
[tools-build,make,test] Disallow parent of repo as --build args
2016-07-21 22:11:28 -05:00
Sam Grove b10276cbef Merge pull request #2173 from theotherjimmy/abstract-base-class
[toolchains]Abstractify the mbedToolchain base class.
2016-07-21 22:10:49 -05:00
Sam Grove 702707dee7 Merge pull request #2166 from theotherjimmy/prevent-traceback-during-export
Preventing a traceback when a library is not built during export
2016-07-21 22:09:52 -05:00
Martin Kojtal dd010097ba Merge pull request #2159 from jeromecoutant/PR_dev_NUCLEO_F207ZG
New STM32 board : NUCLEO_F207ZG
2016-07-21 11:13:33 +01:00
0xc0170 3f5c794b6c Export - define ProGenDef outside of the loop
This saves ~329 calls.
2016-07-21 09:41:38 +01:00
Bogdan Marinescu 51540d08d5 Merge pull request #2177 from mbedmicro/build_on_config_change
Rebuild sources if configuration is changed
2016-07-20 14:52:08 +03:00
Jimmy Brisson 9759382166 prevent test form removeing the root dir 2016-07-19 09:33:03 -05:00
Jimmy Brisson 52855b53cf [tools-build,make,project] Disallow parent of repo as --build args
Resolves #2081
2016-07-19 09:32:44 -05:00
Jimmy Brisson 684644b1b1 [project.py] Preventing a traceback when a library is not built during export 2016-07-19 08:58:24 -05:00
Bogdan Marinescu fd757d3b84 Merge pull request #2180 from mbedmicro/online-build-system
[Tools] mbed Online Build System support and improvements
2016-07-19 16:30:48 +03:00
Mihail Stoyanov ad87f9da34 Document code and mark which methods are used by the online build system 2016-07-19 11:16:05 +01:00
Mihail Stoyanov 74b7f9e923 mbed Online Build System support:
* added/improved global chroot support
* added RESPONSE_FILES flag to support optional response files (on linux the cmd param length is 2 megabytes). Default True
* added unified handling for archive and link response file (similar to includes)
* added COMPILE_C_AS_CPP flag to support compiling of c files as cpp. Default False
* added mbedToolchain.init() for post __init__ hooks
* added caching to mbedToolchain.need_update() to reduce IO hits
* added support to identify compiler warning/error column (supports ARMCC, GCC and IAR). Errors/warnings now report file@line,col
* added global TOOLCHAIN_PATHS which allows overriding/changing of the toolchain paths. Also simplified ARM-related paths
* added target.json to mbed library release (by @0xc0170)* migrated compile_worker() to utils.py for lightweight thread initialization
* improved run_cmd() performance by removing unnecessary check about the command being executed (should be checked once in the relevant toolchain instead)
* removed remnants of Goanna support (should be reimplemented as hooks to compile/link/archive instead)
* fixes for Python 2.7 compatibility (by @0xc0170)
* fixes for Exporters (by @0xc0170)
2016-07-19 11:14:42 +01:00
Martin Kojtal 5cd73170ba Merge pull request #2185 from yogpan01/master
Changing -O2 parameter to -Os
2016-07-19 10:42:34 +01:00
Bogdan Marinescu 8ab89c1131 Merge pull request #2175 from mbedmicro/release
Release v122
2016-07-19 11:34:15 +03:00
Bogdan Marinescu 474915c22c Merge pull request #2186 from 0xc0170/fix_issue2183
Fix issue2183
2016-07-19 11:31:35 +03:00
0xc0170 edf015ad92 Merge branch 'master' into release
Conflicts:
	tools/export/uvision4.py
	tools/export/uvision5.py
2016-07-19 08:44:34 +01:00
0xc0170 028f722868 uvision5 - remove init, not used 2016-07-19 08:30:35 +01:00
0xc0170 f80b62ed00 exporter - fix TARGETS property via descriptors
Fixes #2183 issue.
2016-07-19 08:30:21 +01:00
0xc0170 bf2ad16c69 project - zip and src check if empty fix
Regression from #2179. Fixes #2184.
2016-07-18 15:47:01 +01:00
Yogesh Pande e6043daa04 Changing -O2 parameter to -Os
This commit includes
- Changing build option parameter from -O2 to -Os to reduce flash size of the
  final binary pacakge.
  The original parameter of -O2 is kept to circumvent the error
  http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46762 .
 But this error has been long fixed and released in latest 4.9.x GCC compiler.

 This change is necessary to reduce the generated binary size of mbed Client component to
avoid problem of getting images over 512 kB which is causing application to crash because of
Configuration Store problem https://github.com/ARMmbed/configuration-store/issues/21
2016-07-18 13:59:39 +03:00
Martin Kojtal 3ea625c8eb Merge pull request #2161 from PrzemekWirkus/devel_memap_summary_fields
[Tools] Replace in memap CSV report fields
2016-07-18 11:41:18 +01:00
Mihail Stoyanov 4e1ac4dba2 Merge pull request #2179 from sarahmarshy/progen_build_tests_v2
IDE build tests with progen
2016-07-16 17:54:46 +01:00
Martin Kojtal 7251a8ccae Merge pull request #2176 from 0xc0170/fix_#2171
Exporters - progen TARGETS lazy evaluated
2016-07-15 23:55:48 +01:00
Sarah Marsh b969fa5bb1 IDE build tests with progen 2016-07-15 13:25:35 -05:00
Jimmy Brisson bccbe48f3f Updated all docstrings to be compatible with PEP 257
It's nicer to be compatible with the standards.

I have added one more field to the description of each function:
Side effects. This feild contains the expected side effects of
running a particular method. If the side effects of a method are
None, it is expected that the function does not change anything in
any envoronment and that running it multiple times with the same
arguments will produce the same result every time. That is when
Side effects is non, the method is expected to be pure.
2016-07-15 10:51:47 -05:00
Jimmy Brisson 4fc8c56410 Replace pass with rais NotImplemented in each abstact method
The methods themselfes do nothing within the abstract base class
mbedToolchain. This change enforces that toolchains do not call
these methods that contain no implementation.
2016-07-15 10:17:35 -05:00
Jimmy Brisson f6b8cf05b0 Add a test that exercises the abstract base class checking
The test simply tries to instantiate each class exposed as part of the
TOOLCHAIN_CLASSES map. This is a test that each toolchain class
implements the required API, as the mbedToolchain will not allow the
instantiation of a subclass without a part of that API.
2016-07-15 10:10:40 -05:00
Jimmy Brisson 17833e8f58 Abstractify the mbedToolchain base class
The mbedToolchain class calls many members of it's subclasses, expecting
them to implement a particular API. This change adds a requirement to
each subclass that requires them to implement this expected API.

The API consists of these methods:
 - parse_dependencies
 - parse_ouptut
 - get_config_option
 - compile_c
 - compile_cpp
 - link
 - archive
 - binary
2016-07-15 10:07:56 -05:00
Bogdan Marinescu a558c49240 Rebuild sources if configuration is changed
This commit adds a check for configuration data changes. If a change in
configuration data is detected, all the sources in the tree are rebuilt.

This is a fix for #2073. #2162 was originally proposed as a fix, but it
was agreed that `--preinclude` is a more convenient way to include
configuration data, since it can be used to change the behaviour of
source files that don't include "mbed_config.h" directly, which is a big
advantage when importing 3rd party source trees. Compared to #2162, this
commit has the disadvantage of rebuilding all the source files if a
configuration change is detected, but it was agreed that the advantage
of using `--preinclude` outweighs the disadvantage of the increased
compilation time.
2016-07-15 16:37:46 +03:00
0xc0170 f95265f38d Exporters - progen TARGETS lazy evaluated
To speed up project.py, use @property for TARGETS.
When exporters are used, it would ask progen for all targets support
(number of tools x number of targets), this takes a lot of  time, thus
lazily evaluated, and TARGETS are for backaward compatibility, not currently
used by project.py but by other scripts to check if a target is supported.

Profiling:
```
python tools\project.py -m K64F -i uvision -n MBED_10 -b

Before the change:
       1    0.000    0.000    0.010    0.010 definitions.py:113(get_tool_definition)
      824    0.004    0.000    2.990    0.004 definitions.py:124(is_supported)
        1    0.000    0.000    0.000    0.000 definitions.py:145(get_debugger)
        1    0.002    0.002    0.044    0.044 definitions.py:15(<module>)
      384    0.002    0.000    2.986    0.008 definitions.py:26(_load_record)
        1    0.000    0.000    0.000    0.000 definitions.py:32(ProGenMcus)
      992    0.055    0.000    1.959    0.002 definitions.py:34(__init__)
     1376    0.002    0.000    0.003    0.000 definitions.py:40(get_mcus)
      384    0.001    0.000    1.070    0.003 definitions.py:43(get_mcu_record)
        1    0.000    0.000    0.000    0.000 definitions.py:50(ProGenTargets)
      992    0.000    0.000    0.000    0.000 definitions.py:52(__init__)
     1196    0.002    0.000    0.004    0.000 definitions.py:55(get_targets)
      204    0.001    0.000    1.922    0.009 definitions.py:58(get_mcu_record)
        1    0.000    0.000    0.000    0.000 definitions.py:67(get_debugger)
        1    0.000    0.000    0.000    0.000 definitions.py:74(ProGenDef)
      992    0.008    0.000    1.973    0.002 definitions.py:83(__init__)

Days              : 0
Hours             : 0
Minutes           : 0
Seconds           : 4
Milliseconds      : 723
Ticks             : 47237302
TotalDays         : 5.46728032407407E-05
TotalHours        : 0.00131214727777778
TotalMinutes      : 0.0787288366666667
TotalSeconds      : 4.7237302
TotalMilliseconds : 4723.7302

After the change:

        1    0.000    0.000    0.010    0.010 definitions.py:113(get_tool_definition)
        2    0.000    0.000    0.025    0.012 definitions.py:124(is_supported)
        1    0.000    0.000    0.000    0.000 definitions.py:145(get_debugger)
        1    0.002    0.002    0.042    0.042 definitions.py:15(<module>)
        3    0.000    0.000    0.035    0.012 definitions.py:26(_load_record)
        1    0.000    0.000    0.000    0.000 definitions.py:32(ProGenMcus)
        2    0.000    0.000    0.005    0.002 definitions.py:34(__init__)
        5    0.000    0.000    0.000    0.000 definitions.py:40(get_mcus)
        3    0.000    0.000    0.000    0.000 definitions.py:43(get_mcu_record)
        1    0.000    0.000    0.000    0.000 definitions.py:50(ProGenTargets)
        2    0.000    0.000    0.000    0.000 definitions.py:52(__init__)
        5    0.000    0.000    0.000    0.000 definitions.py:55(get_targets)
        3    0.000    0.000    0.035    0.012 definitions.py:58(get_mcu_record)
        1    0.000    0.000    0.000    0.000 definitions.py:67(get_debugger)
        1    0.000    0.000    0.000    0.000 definitions.py:74(ProGenDef)
        2    0.000    0.000    0.005    0.003 definitions.py:83(__init__)

Days              : 0
Hours             : 0
Minutes           : 0
Seconds           : 1
Milliseconds      : 178
Ticks             : 11780618
TotalDays         : 1.3634974537037E-05
TotalHours        : 0.000327239388888889
TotalMinutes      : 0.0196343633333333
TotalSeconds      : 1.1780618
TotalMilliseconds : 1178.0618
```
2016-07-15 14:02:57 +01:00
Martin Kojtal 3d20b10b4d Merge pull request #2172 from theotherjimmy/enfoce-supported-toolchains
[tools-build.py]Enforce supported toolchains
2016-07-15 09:02:14 +01:00
Martin Kojtal 3a2b752169 Merge pull request #2174 from theotherjimmy/return-from-build
[tools/build_api] Retrun truthy value on success from build_*
2016-07-15 09:01:31 +01:00
Sam Grove eca0c69e6c Merge pull request #2141 from theotherjimmy/project-argparse
[Project.py] Make -i and -m optional
2016-07-14 18:00:20 -05:00
Jimmy Brisson 6aa2bbb801 [tools/build_api] Retrun truthy value on success from build_*
before:
```
$  python tools/build.py  -m NRF51_DK --source . -t GCC_ARM,ARM --build build --silent
[SNIP]
Completed in: (3.39)s

Build skipped:
  * GCC_ARM::NRF51_DK
  * ARM::NRF51_DK

```
after:
```
$  python tools/build.py  -m NRF51_DK --source . -t GCC_ARM,ARM --build build --silent
[SNIP]
Completed in: (3.43)s

Build successes:
  * GCC_ARM::NRF51_DK
  * ARM::NRF51_DK

```
2016-07-14 13:55:51 -05:00
Jimmy Brisson 24fcb4700b [tools-build.py]Enforce supported toolchains
by skipping unsupported combinations
2016-07-14 13:29:55 -05:00
0xc0170 125754bf31 Exporter uvision - fix build_dir, only windows slashes allowed
uvision errors otherwise, not possible to create a path.
2016-07-14 14:21:05 +01:00
Russ Butler 546b5dec7c Remove floating point formatting in newlib nano
Remove special case targets which have floating point enabled in
Newlib Nano from gcc.py.  To enable floating point printf/scanf
for a target configure it to use the 'standard' default build in
targets.json rather than 'small'.
2016-07-13 18:48:43 -05:00
0xc0170 9c3801b7b5 Config - fix - use basetring to check if a target is string 2016-07-13 14:59:48 +01:00
Bogdan Marinescu d0d023ab58 Merge pull request #2122 from theotherjimmy/colorized-output
Colorized the short Warnings/Errors generated by the toolchains
2016-07-13 14:21:15 +03:00
Przemek Wirkus bba13ddad2 Replace in memap CSV report fields
Changes:
* This change impacts #2047
* In code summary columns were shortened and names changed a bit,
  see [here](https://github.com/mbedmicro/mbed/pull/2047/files?w=1#diff-f9cb941bde5647a5763e18fc220efc51R410)
* There is a need to allign memap CSV report fields (summary columns) with what
  is in code now. This discrapency may create problems when generating reports
  in the future. All columns should have the same name.
* memap CSV sumamry fields names changes:
  'total_static_ram' -> 'static_ram'
  'allocated_heap' -> 'heap'
  'allocated_stack' -> 'stack'

See example of discrepancy:

'total_static_ram' vs 'static_ram'
'allocated_heap' vs 'heap'
'allocated_stack' vs 'stack'

What is in code and presented with prettytable:

+----------------------------------------+--------+-----------+------------+-------+-------+-----------+-------------+
| name                                   | target | toolchain | static_ram | stack |  heap | total_ram | total_flash |
+----------------------------------------+--------+-----------+------------+-------+-------+-----------+-------------+
| tests-mbed_drivers-c_strings           | K64F   | GCC_ARM   |      11468 | 32768 | 65540 |    109776 |       74182 |
| tests-mbed_drivers-callback            | K64F   | GCC_ARM   |      11980 | 32768 | 65540 |    110288 |       88406 |
| tests-mbedmicro-rtos-mbed-threads      | K64F   | GCC_ARM   |      11468 | 32768 | 65540 |    109776 |       75918 |
| tests-mbedmicro-rtos-mbed-timer        | K64F   | GCC_ARM   |      10788 | 32768 | 65540 |    109096 |       68534 |
+----------------------------------------+--------+-----------+------------+-------+-------+-----------+-------------+

vs CSV:

```
total_static_ram,allocated_heap,allocated_stack,total_ram,total_flash
10788,65540,32768,109096,67486
```

vs memstats_map.JSON:

```json
[
    {
        "module": "Fill",
        "size": {
            ".data": 4,
            ".bss": 2257,
            ".text": 173
        }
    },

    {
        "summary": {
            "total_flash": 67486,
            "allocated_stack": 32768,
            "total_static_ram": 10788,
            "total_ram": 109096,
            "allocated_heap": 65540
        }
    }
]
```
2016-07-13 11:25:04 +01:00
Bogdan Marinescu e9d225bb96 Merge pull request #2151 from mbedmicro/verbose_json_errors
More verrbose errors for JSON parsing
2016-07-13 10:29:31 +03:00
Bogdan Marinescu 33dd3fe8ad More verrbose errors for JSON parsing
This commit adds information about the location of problematic JSON
files when reporting a JSON parsing error.

Before this commit:

```
[ERROR] Expecting property name: line 7 column 9 (char 188)
```

After this commit:

```
Error parsing 'core/mbed_lib.json':
[ERROR] Expecting property name: line 7 column 9 (char 188)
```
2016-07-12 18:52:34 +03:00
jeromecoutant 8d3cdfea59 tools update to add NUCLEO_F207ZG 2016-07-12 16:38:11 +02:00
Bogdan Marinescu 9704edfca7 Fix add_py_targets and tests
Previously, add_py_targets assumed that it is not an error to add an
existing target if that target was previously added using
add_py_targets. This was done to aid testing, but it was weird, error
prone and broke with the latest changes to the caching mechanism. With
this commit:

- it is always an error to add a target that was previously added, which
  is much more consistent.
- tests for the configuration mechanism use the newly added
  'set_targets_json_location' function to clear the internal caches in
  targets.py (and thus all previously added custom targets). As a side
  effect, this commit also tests the 'set_targets_json_location'
  function itself.
2016-07-12 14:42:21 +03:00
Bogdan Marinescu 117b21df8f It's now possible to specify the location of targets.json
With this change, it becomes possible to use targets.py with any
targets.json, not just the default one in ../hal/targets.json.
targets.py will still be initialized with the default targets.json, but
the code can then call "set_targets_json_location" to specify the new
location of targets.json. set_targets_json_location modifies all the
data "in place"; that is, it doesn't create a new TARGET_MAP,
TARGET_NAMES or alike, but rather modified the existing ones. This is
important, because code using this construct:

from tools.targets import TARGET_MAP

can work unmodified with this change.
2016-07-12 13:03:47 +03:00
Jimmy Brisson 50dbce9e74 Fixes to function caching in targets.py
Now funnctions are looked up in the cache using a (function name,
arguments) key, which makes it possible to cache different invocations
of the functions (with different arguments).
Also applied the @cached attribute to get_target.
2016-07-12 13:03:40 +03:00
Jimmy Brisson cebe292c5e [Project.py] Make -i and -m optional
Resolves #2135
2016-07-11 10:38:50 -05:00
Jimmy Brisson e2c88373ee Replace color definitions with colorama constants 2016-07-11 09:41:23 -05:00
Jimmy Brisson bac254c7a3 Add documentation of the notify parameter to mbedToolchain 2016-07-11 09:41:23 -05:00
Jimmy Brisson 12492c17b8 Call colorized notify when --color for build.py, make.py, test.py 2016-07-11 09:41:23 -05:00
Jimmy Brisson 6b8bde9471 Update event dict with toolchain, use toolchain for wrapping 2016-07-11 09:41:23 -05:00
Jimmy Brisson 21f025e601 Add a setting for colorization map so that it may be overwritten by the user 2016-07-11 09:41:23 -05:00
Jimmy Brisson 3aacdb4421 Implement colorization in it's own file 2016-07-11 09:41:23 -05:00
Jimmy Brisson f4254c4fee Add colorization option to default options parser
should be picked up by most cli's
2016-07-11 09:41:14 -05:00
0xc0170 359d33cc16 Revert part of the FPU change
We keep target.core names, it defines if CPU contains FPU, as it's common - Cortex M4F/M7F.
We add Cortex M7FD for double precision FPU.
2016-07-11 10:39:23 +01:00
Jimmy Brisson 61c63b3789 Argument error when memap's input file does not exist 2016-07-07 15:29:36 -05:00
Jimmy Brisson 122fa93a70 Allow make.py to accpet just --source 2016-07-07 15:29:36 -05:00
Jimmy Brisson 6d0716c69b Ignore extra MCUs and toolchains in get_config.py 2016-07-07 15:29:36 -05:00
Jimmy Brisson 254dccdad3 Remove checking for existance of build directory 2016-07-07 15:29:36 -05:00
Jimmy Brisson 7a4bee8c0e nargs="*" -> action="append" 2016-07-07 15:29:36 -05:00
Jimmy Brisson bca12206f1 Allow --source to be specified more than once 2016-07-07 15:29:36 -05:00
Jimmy Brisson 4c5bfaa3d8 Allow --source with -n and -p, or alone; name projects conditionally 2016-07-07 15:29:36 -05:00
Jimmy Brisson 5f18943641 Revert parsing of mutiple ides on command line 2016-07-07 15:29:36 -05:00
Jimmy Brisson 9040d27967 Rework the force types to match case
for example, argparse_force_uppercase_type will now correctly parse uARM to uARM
2016-07-07 15:29:36 -05:00
Jimmy Brisson b4b514ea2f Correct test_name_known, now use argparse_many for lists
also updated all consumers of test_name_known
2016-07-07 15:29:36 -05:00
Jimmy Brisson 5052e97b17 Force conversion of all -i, -m, -t to the correct case 2016-07-07 15:29:36 -05:00
Jimmy Brisson 6fda53b8b8 Add documentation for the argparser utilities 2016-07-07 15:29:36 -05:00
Jimmy Brisson 59ae690f9b Correct style in tests.py 2016-07-07 15:29:36 -05:00
Jimmy Brisson d6bee561ab Squash weird import bug 2016-07-07 15:29:36 -05:00
Jimmy Brisson 0ec8199c55 Revert "Revert "Generalize flag handling""
This reverts commit 33cec194c6.
2016-07-07 15:29:36 -05:00
0xc0170 935f537573 Build release - add copy targets.json file 2016-07-07 12:04:49 +01:00
Przemek Wirkus 12a01f61ca Add summary for test building
When users are building tests with `mbed compile --tests` whey will by default
get memory map breakdown report.
This can be suppresed in the future with command line switch. For now it is
visible each time users build test cases.
List is sorted by project name created with `build_project` API.

Changes:
* `build_project` now returns tuple (this breaks build_api.build_project API!)
* Memmap script got a aggregation function to print summary from small 'JSON'
  partial reports.
* Report is generated by `test_api.build_tests` function only!

Example:
```
+----------------------------------------------------------------------+--------+-----------+-------------+------------+-------+-------+-----------+
| name                                                                 | target | toolchain | total_flash | static_ram | stack |  heap | total_ram |
+----------------------------------------------------------------------+--------+-----------+-------------+------------+-------+-------+-----------+
| features-feature_ipv4-tests-mbedmicro-net-nist_internet_time_service | K64F   | GCC_ARM   |      132136 |      62288 | 32768 | 65536 |    160592 |
| features-feature_ipv4-tests-mbedmicro-net-tcp_client_echo            | K64F   | GCC_ARM   |      125613 |      62448 | 32768 | 65540 |    160756 |
| features-feature_ipv4-tests-mbedmicro-net-tcp_client_hello_world     | K64F   | GCC_ARM   |      125949 |      62448 | 32768 | 65540 |    160756 |
| features-feature_ipv4-tests-mbedmicro-net-udp_echo_client            | K64F   | GCC_ARM   |      123613 |      62276 | 32768 | 65536 |    160580 |
| features-storage-tests-cfstore-add_del                               | K64F   | GCC_ARM   |       96080 |      13052 | 32768 | 65540 |    111360 |
| features-storage-tests-cfstore-close                                 | K64F   | GCC_ARM   |       95520 |      12004 | 32768 | 65540 |    110312 |
| features-storage-tests-cfstore-create                                | K64F   | GCC_ARM   |       99144 |      13036 | 32768 | 65540 |    111344 |
| features-storage-tests-cfstore-example1                              | K64F   | GCC_ARM   |       98592 |      12368 | 32768 | 65536 |    110672 |
| features-storage-tests-cfstore-example2                              | K64F   | GCC_ARM   |       95232 |      12012 | 32768 | 65540 |    110320 |
| features-storage-tests-cfstore-example3                              | K64F   | GCC_ARM   |       95264 |      11856 | 32768 | 65536 |    110160 |
| features-storage-tests-cfstore-example4                              | K64F   | GCC_ARM   |       92632 |      12012 | 32768 | 65540 |    110320 |
| features-storage-tests-cfstore-example5                              | K64F   | GCC_ARM   |       92344 |      11856 | 32768 | 65536 |    110160 |
| features-storage-tests-cfstore-find                                  | K64F   | GCC_ARM   |       96344 |      13028 | 32768 | 65540 |    111336 |
| features-storage-tests-cfstore-find2                                 | K64F   | GCC_ARM   |       93192 |      12004 | 32768 | 65540 |    110312 |
| features-storage-tests-cfstore-flash                                 | K64F   | GCC_ARM   |       97784 |      12532 | 32768 | 65540 |    110840 |
| features-storage-tests-cfstore-flush                                 | K64F   | GCC_ARM   |       96464 |      12012 | 32768 | 65540 |    110320 |
| features-storage-tests-cfstore-flush2                                | K64F   | GCC_ARM   |       95056 |      12004 | 32768 | 65540 |    110312 |
| features-storage-tests-cfstore-init                                  | K64F   | GCC_ARM   |       93120 |      12012 | 32768 | 65540 |    110320 |
| features-storage-tests-cfstore-misc                                  | K64F   | GCC_ARM   |       96808 |      12516 | 32768 | 65540 |    110824 |
| features-storage-tests-cfstore-open                                  | K64F   | GCC_ARM   |       98632 |      12540 | 32768 | 65540 |    110848 |
| features-storage-tests-cfstore-read                                  | K64F   | GCC_ARM   |       94112 |      12540 | 32768 | 65540 |    110848 |
| features-storage-tests-cfstore-write                                 | K64F   | GCC_ARM   |       94488 |      12004 | 32768 | 65540 |    110312 |
| features-storage-tests-flash_journal-basicapi                        | K64F   | GCC_ARM   |      104712 |      21236 | 32768 | 65540 |    119544 |
| frameworks-utest-tests-unit_tests-basic_test                         | K64F   | GCC_ARM   |       71534 |      11468 | 32768 | 65540 |    109776 |
| frameworks-utest-tests-unit_tests-case_async_validate                | K64F   | GCC_ARM   |       74598 |      11468 | 32768 | 65540 |    109776 |
| frameworks-utest-tests-unit_tests-case_control_async                 | K64F   | GCC_ARM   |       74630 |      11476 | 32768 | 65540 |    109784 |
| frameworks-utest-tests-unit_tests-case_control_repeat                | K64F   | GCC_ARM   |       72790 |      11452 | 32768 | 65540 |    109760 |
| frameworks-utest-tests-unit_tests-case_selection                     | K64F   | GCC_ARM   |       72302 |      11468 | 32768 | 65540 |    109776 |
| frameworks-utest-tests-unit_tests-case_setup_failure                 | K64F   | GCC_ARM   |       72630 |      11468 | 32768 | 65540 |    109776 |
| frameworks-utest-tests-unit_tests-case_teardown_failure              | K64F   | GCC_ARM   |       72790 |      11468 | 32768 | 65540 |    109776 |
| frameworks-utest-tests-unit_tests-control_type                       | K64F   | GCC_ARM   |       82462 |      11468 | 32768 | 65540 |    109776 |
| frameworks-utest-tests-unit_tests-minimal_async_scheduler            | K64F   | GCC_ARM   |       72182 |      11468 | 32768 | 65540 |    109776 |
| frameworks-utest-tests-unit_tests-minimal_scheduler                  | K64F   | GCC_ARM   |       71998 |      11468 | 32768 | 65540 |    109776 |
| frameworks-utest-tests-unit_tests-test_assertion_failure_test_setup  | K64F   | GCC_ARM   |       71710 |      11460 | 32768 | 65540 |    109768 |
| frameworks-utest-tests-unit_tests-test_setup_case_selection_failure  | K64F   | GCC_ARM   |       71702 |      11468 | 32768 | 65540 |    109776 |
| frameworks-utest-tests-unit_tests-test_setup_failure                 | K64F   | GCC_ARM   |       71710 |      11468 | 32768 | 65540 |    109776 |
| tests-integration-basic                                              | K64F   | GCC_ARM   |       67566 |      10780 | 32768 | 65540 |    109088 |
| tests-integration-threaded_blinky                                    | K64F   | GCC_ARM   |       68326 |      10780 | 32768 | 65540 |    109088 |
| tests-mbed_drivers-c_strings                                         | K64F   | GCC_ARM   |       74438 |      11468 | 32768 | 65540 |    109776 |
| tests-mbed_drivers-callback                                          | K64F   | GCC_ARM   |       88310 |      11972 | 32768 | 65540 |    110280 |
| tests-mbed_drivers-dev_null                                          | K64F   | GCC_ARM   |       90213 |      10784 | 32768 | 65540 |    109092 |
| tests-mbed_drivers-echo                                              | K64F   | GCC_ARM   |       71918 |      11468 | 32768 | 65540 |    109776 |
| tests-mbed_drivers-generic_tests                                     | K64F   | GCC_ARM   |       77624 |      11468 | 32768 | 65540 |    109776 |
| tests-mbed_drivers-rtc                                               | K64F   | GCC_ARM   |       85854 |      11308 | 32768 | 65540 |    109616 |
| tests-mbed_drivers-stl_features                                      | K64F   | GCC_ARM   |       80726 |      11476 | 32768 | 65540 |    109784 |
| tests-mbed_drivers-ticker                                            | K64F   | GCC_ARM   |       70974 |      11308 | 32768 | 65540 |    109616 |
| tests-mbed_drivers-ticker_2                                          | K64F   | GCC_ARM   |       70790 |      11308 | 32768 | 65540 |    109616 |
| tests-mbed_drivers-ticker_3                                          | K64F   | GCC_ARM   |       71038 |      11308 | 32768 | 65540 |    109616 |
| tests-mbed_drivers-timeout                                           | K64F   | GCC_ARM   |       70886 |      11308 | 32768 | 65540 |    109616 |
| tests-mbed_drivers-wait_us                                           | K64F   | GCC_ARM   |       70414 |      11308 | 32768 | 65540 |    109616 |
| tests-mbedmicro-mbed-attributes                                      | K64F   | GCC_ARM   |       71534 |      11460 | 32768 | 65540 |    109768 |
| tests-mbedmicro-mbed-call_before_main                                | K64F   | GCC_ARM   |       73112 |      10780 | 32768 | 65540 |    109088 |
| tests-mbedmicro-mbed-cpp                                             | K64F   | GCC_ARM   |       73400 |      10780 | 32768 | 65540 |    109088 |
| tests-mbedmicro-mbed-div                                             | K64F   | GCC_ARM   |       73176 |      10780 | 32768 | 65540 |    109088 |
| tests-mbedmicro-rtos-mbed-basic                                      | K64F   | GCC_ARM   |       68390 |      10780 | 32768 | 65540 |    109088 |
| tests-mbedmicro-rtos-mbed-isr                                        | K64F   | GCC_ARM   |       74480 |      10780 | 32768 | 65540 |    109088 |
| tests-mbedmicro-rtos-mbed-mail                                       | K64F   | GCC_ARM   |       74992 |      11300 | 32768 | 65540 |    109608 |
| tests-mbedmicro-rtos-mbed-mutex                                      | K64F   | GCC_ARM   |       74048 |      10780 | 32768 | 65540 |    109088 |
| tests-mbedmicro-rtos-mbed-queue                                      | K64F   | GCC_ARM   |       74912 |      11300 | 32768 | 65540 |    109608 |
| tests-mbedmicro-rtos-mbed-semaphore                                  | K64F   | GCC_ARM   |       74296 |      10780 | 32768 | 65540 |    109088 |
| tests-mbedmicro-rtos-mbed-signals                                    | K64F   | GCC_ARM   |       74328 |      10780 | 32768 | 65540 |    109088 |
| tests-mbedmicro-rtos-mbed-threads                                    | K64F   | GCC_ARM   |       75214 |      11460 | 32768 | 65540 |    109768 |
| tests-mbedmicro-rtos-mbed-timer                                      | K64F   | GCC_ARM   |       68430 |      10780 | 32768 | 65540 |    109088 |
| tests-storage_abstraction-basicapi                                   | K64F   | GCC_ARM   |      107808 |      28908 | 32768 | 65540 |    127216 |
+----------------------------------------------------------------------+--------+-----------+-------------+------------+-------+-------+-----------+
```

Refactored after code review

Refactored parse() function

Polishing

Moved memory usage reporting function call to test.py to group all reporters in one place

Bug-fix: on ARM toolchain we were not fetching statistics from last element of memap result list
2016-07-07 08:35:20 +01:00
Sam Grove 458b46c803 Merge pull request #1873 from theotherjimmy/file-reporter
Adds a simple text file report format
2016-07-06 16:45:43 -05:00
Sam Grove 36ff1f73ce Merge pull request #2106 from theotherjimmy/fix-makefile
[Exporter-gcc_arm] do builds from project directory when --source is specified
2016-07-06 15:33:28 -05:00
Jimmy Brisson 3697dedb78 Reverse order of relativizing paths and unixifing paths
'cause windows silly path separator is the same as the escape character
2016-07-06 13:54:33 -05:00
Jimmy Brisson 3cf8bfbfb7 Allow spaces in paths passed to mkdir and rm on bash 2016-07-06 12:51:14 -05:00
Jimmy Brisson fbccf8dfc9 Force shell use when in bash/sh mode 2016-07-06 12:49:38 -05:00
Jimmy Brisson c2d66865be Correct batch detection algorimthm
There are two shell-like things that we care about
 bash: does environment varible expansion with $
 batch: does environment varible expansion by surrounding something with %

so to detect batch, try to expand a variable on the shell with $.
If you get a $ back, you are in batch!
2016-07-06 11:32:01 -05:00
Martin Kojtal e237d157dd Merge pull request #2113 from ohagendorf/gcc_export
[bugfix gcc_arm] build+make <-> export project+make: different results
2016-07-06 13:49:10 +01:00
Olaf Hagendorf bd614a2a11 [bugfix gcc_arm] build+make <-> export project+make: different results
when in target.json "default_build": "small" is configured
- build.py+make.py
  - uses linker option --specs=nano.specs
  - macro MBED_RTOS_SINGLE_THREAD is defined
- exporting with project.py + make Makefile
  - doesn't use the linker option --specs=nano.specs
  - doesn't contain macro MBED_RTOS_SINGLE_THREAD
2016-07-06 13:35:09 +02:00
Olaf Hagendorf 7f2f0bc5c6 repairing a minor typo in exporters.py 2016-07-06 13:34:59 +02:00
Bogdan Marinescu b8c64cd275 Merge pull request #2102 from mbedmicro/fix_tests_with_config
Fix tests with config
2016-07-06 11:09:20 +03:00
Jimmy Brisson 61ee30efb2 Fix normal export (no --source) 2016-07-05 12:04:36 -05:00
Jimmy Brisson fa527cf45e Rework vpaths and include file locating 2016-07-05 11:51:27 -05:00
Jimmy Brisson 4b7f591d33 Fix the makefile template
- Corrects a python barf when something in features is None
 - Corrects makefile to prevent barf when using make -f
2016-07-05 10:16:50 -05:00
Bogdan Marinescu fbb26a405c Fix tests.py so it can work with application defined targets
With this patch in place, tests.py uses targets names instead of target
instances, which makes it possible to use application defined targets
with tests.
2016-07-05 15:52:53 +03:00
Bogdan Marinescu 36a577e1ef Make build_tests work with target names, not just Target instances
With this change, custom targets defined by the application being
tested in its mbed_app.json file can be used with tests. Note that
`build_project` already accepts both target names and instances, so the
call to `build_project` inside `build_tests` will still work.
2016-07-05 15:47:26 +03:00
Bogdan Marinescu e3d29fe5d2 Improve configuration handling in build_project
The configuration object is now created early in the build_project
function. This way, if there's a mbed_app.json that contains a custom
target, that target is taken into account. This is useful (for example)
when compiling tests for an application that defines a custom target.
2016-07-05 15:40:12 +03:00
0xc0170 3b84b42a53 Build release - use target.release to produce release tuple 2016-07-05 10:50:29 +01:00
Olaf Hagendorf 4fe41d4edd fpu with single/double precision - removing redundancy
- removing redundancy as discussed in PR #2087:
 - in target.json the core option can have only this values : "Cortex-M0", "Cortex-M0+", "Cortex-M1", "Cortex-M3", "Cortex-M4", "Cortex-M7", "Cortex-A9" - Cortex-M4F and Cortex-M7F removed
 - in target.json an additional fpu option with values: "single" and "double" can be used
- build and export scripts are changed to handle this

- tested (compiling, running on hardware) with nucleo_f767 (cortex-m7 with double precision fpu), nucleo_f746 (cortex-m7 with single precision fpu), nucleo_f446 and nucleo_l467 (cortex-m4 with single precision fpu), teensy31 (cortex-m4 without fpu - only build test), nucleo_l073 (cortex-m0)
- singletest results are added to PR #2087 comments
2016-07-04 22:08:31 +02:00
Olaf Hagendorf ea196e2adb fpu with single/double precision - bugfix and extension
- creating new core name Cortex_M7F_DP for a target with a double precision fpu
- adding new core name to arm.py to set compiler/linker flags to a double precision fpu when configured in target.json
- up to now: gcc wrote flag for a double precision fpu -> target with STM32F746 didn't run when using double variables - mcu has only single precision fpu
- changing gcc.py to use single precision for Cortex-M7 und double precision for Cortex_M7F_DP

tested with NUCLEO_F746, NUCLEO_F767 and build.py+make.py and exporting with project.py + compiling/flashing

- iar.py need a similar extention - I didn't change that yet because
  - did not run at the moment - python exception
  - currently worked on in PR #1948
2016-07-04 22:08:30 +02:00
Erwan GOURIOU eaf77ed37f [STM32F4xx][NUCLEO_F429ZI] Add on for NUCLEO_F429ZI export and tests 2016-07-04 15:20:12 +02:00
Erwan Gouriou 9bb08291ce [STM32F4xx] Add support for NUCLEO_F429ZI 2016-07-04 14:00:41 +02:00
Laurent Meunier 4e1a3351b2 [NUCLEO_F446ZE] Add to build and export scripts 2016-07-04 11:44:28 +02:00
Olaf Hagendorf 4211f7581e [NUCLEO_F7xx] adding F767 to build_release and adding default_build to target.json 2016-07-01 16:27:20 +02:00
ohagendorf fdda915a8a [NUCLEO_F767ZI] adding target to rtos lib 2016-07-01 15:19:30 +02:00
ohagendorf 9ddbb1f831 [NUCLEO_F767] move gcc template to new path 2016-07-01 15:17:25 +02:00
Olaf Hagendorf 3ac68aae06 typo in target names for travis build 2016-07-01 15:17:21 +02:00
ohagendorf cc537f7449 adding gccarm and uvision5 exporter 2016-07-01 15:17:21 +02:00
Martin Kojtal 62604b45b2 Merge pull request #1880 from zgoda/generic_bluepill
Support for Blue Pill
2016-07-01 14:52:04 +02:00
Martin Kojtal 6350b2d904 Merge pull request #2046 from sarahmarshy/patch-2
Changed reference to old rtos location
2016-07-01 13:33:40 +02:00
Sam Grove 185676300d Merge pull request #2060 from theotherjimmy/cleanup-make-export
[Exporters-gcc_arm] Clean up the source directory
2016-06-30 13:01:54 -05:00
Jimmy Brisson 3850c2628b Force all to be the default target 2016-06-30 11:43:01 -05:00
Jimmy Brisson 6c1c7a5955 Check for OSTYPE instead of OS
It better detects sh vs. batch
2016-06-30 11:28:32 -05:00
Sam Grove 197c4b516b Merge pull request #2076 from bridadan/relative-paths-test-spec
Relative paths in test spec file
2016-06-30 11:01:07 -05:00
Jimmy Brisson d6d0202236 Move binaries from bin to .build 2016-06-30 10:55:34 -05:00
Jimmy Brisson 5d014661c2 Redo window mkdir; add cross-platform rmdir 2016-06-30 10:55:10 -05:00
Jimmy Brisson 6867499da3 Test for existance of dir before creating it 2016-06-30 10:55:04 -05:00
Jimmy Brisson 6971b1e1b4 update mkdir to be cross-platform 2016-06-30 10:51:19 -05:00
Jimmy Brisson 7b5831247d Make the efm32 targets use the common makefile template 2016-06-30 10:51:19 -05:00
Jimmy Brisson 63f4e6a279 sam*::gcc_arm targets extend the common makefile 2016-06-30 10:51:19 -05:00
Jimmy Brisson 86585197da rework the common template to place objects into bin 2016-06-30 10:51:18 -05:00
Brian Daniels b7186bb604 Test spec paths are now relative to tool execution directory
This commit also normalizes the paths produced by the the test spec to
Unix style paths to increase portability of the file.
2016-06-30 09:32:13 -05:00
svastm 505814147d [NUCLEO_L432KC] Add RTOS support 2016-06-30 15:05:09 +02:00
svastm 2198dccd6e [NUCLEO_L432KC] Add to build and export scripts 2016-06-30 14:50:35 +02:00
Jarek Zgoda 2731bc7da3 Template moved to new tools directory 2016-06-30 12:36:19 +02:00
Jarek Zgoda 59623d62f9 One more occurence to be renamed 2016-06-30 12:36:19 +02:00
Jarek Zgoda 3006f70552 Support for Blue Pill 2016-06-30 12:36:18 +02:00
Sam Grove 472ac772f9 Merge pull request #2056 from theotherjimmy/pass-files-to-source
Enable passing individual files to --source options
2016-06-29 17:08:30 -05:00
Jimmy Brisson cd9261d168 Add documentation 2016-06-29 11:20:34 -05:00
Jimmy Brisson ce1cddcd8b Prefix non-public api with an underscore 2016-06-29 11:11:54 -05:00
Jimmy Brisson c7acb7c293 Enable passing individual files to scan_resources 2016-06-29 11:10:12 -05:00
Brian Daniels 27aea960bc Changing name of test binaries to just test case folder name.
This mitigates the Windows paths issue by shortening the test binary name to just the
test case folder name instead of the full unique test name used by the
tools. This doesn't solve the Windows path limit of 260 characters, but it
does reduce the characters used.
2016-06-28 18:48:13 -05:00
Jimmy Brisson feea8d59e1 Fix a bug that caused the gcc_arm exporter to fail
Resolves #2048
2016-06-28 11:11:03 -05:00
Sam Grove ec1ec7c3e2 Merge pull request #2015 from mlnx/memap_improvements
[memap] Improve wording on stack/heap and minor improvements
2016-06-28 11:00:10 -05:00
Sam Grove 5ea1953755 Merge pull request #2045 from 0xc0170/fix_iar_vla
iar - remove --vla flag for exporters
2016-06-28 10:52:00 -05:00
Martin Kojtal 5534f34d0e Merge pull request #2033 from screamerbg/env-var-paths
[Tools] Add MBED_ prefix to compilers environment variables
2016-06-28 17:32:42 +02:00
sarahmarshy 06706da749 Changed reference to old rtos location 2016-06-28 10:25:48 -05:00
0xc0170 d2a216f3a0 iar - remove --vla flag for exporters
The template file already enables VLA as it's for C only. This --vla flag
causes conflicts with --cpp flag that is enabled implicitly if C++ is enabled.
2016-06-28 17:15:48 +02:00
Mihail Stoyanov b8cc5988bb Merge pull request #2036 from screamerbg/fix-tests1
[Testing] Disable test MBED_39 being commonly failed test
2016-06-28 15:18:28 +01:00
Bogdan Marinescu 986ed4f22c Merge pull request #2043 from 0xc0170/fix_uvision_libpath
armcc - remove libpath from ld flags
2016-06-28 16:36:33 +03:00
Martin Kojtal a84b7e71e2 Merge pull request #2042 from DanKupiniak/export_elmo_f411re_to_gcc_arm
Export ELMO_F411RE projects to offline GCC ARM Make project.
2016-06-28 15:34:11 +02:00
0xc0170 29f806bb64 armcc - remove libpath from ld flags
libpath is not required for exporters, as they provide default paths.
This caused problems when paths are not correct for mbed tools, a project
fails to build as path is not found.
2016-06-28 14:58:26 +02:00
0xc0170 f44ff94fc3 uvision4/5 - remove no-vla for exporters
IDE has C/C++ tab, thus this only cxx flag would be applied for
C files.
2016-06-28 14:15:34 +02:00
Daniel Kupiniak bb29ed8991 Export ELMO_F411RE projects to offline GCC ARM Make project. 2016-06-28 14:14:48 +02:00
0xc0170 35c90753c0 Project - fix zip rename argument 2016-06-28 10:22:47 +02:00
Bogdan Marinescu af71d87adc Merge pull request #1975 from theotherjimmy/export-mbed-conf
[Exporters] Update exporters to include and use mbed_conf.h (Was #1964)
2016-06-28 11:15:22 +03:00
Martin Kojtal 96e533c361 Merge pull request #2034 from sarahmarshy/patch-1
[Exporters] Conflicting zip name
2016-06-28 07:28:41 +02:00
Mihail Stoyanov 51157ba073 Disable test MBED_39 being commonly failed test 2016-06-27 23:55:45 +01:00
Mihail Stoyanov b67d425f09 Add MBED_ prefix to compilers environment variables 2016-06-27 23:27:43 +01:00
sarahmarshy beb0be99d8 Conflicting zip name
The boolean zip passed as a parameter conflicts with the zip exporter class imported.
2016-06-27 17:20:13 -05:00
Jimmy Brisson 855cc91550 Force program_cycle_s to be used as an attribue everywhere 2016-06-27 16:01:52 -05:00
Jimmy Brisson 8e11fa2071 Undelete defines from IAR 2016-06-27 14:36:35 -05:00
Jimmy Brisson 7b83c30ba1 for file in `ls tofor file in `ls tools/export`; do sed -i tools/export/$file -e "s/MBED_CONF_ACTIVE/MBED_CONFIG_HEADER_SUPPORTED/"; done 2016-06-27 14:06:42 -05:00
Jimmy Brisson 4746beb256 Switch to = style for preincludes
relpaces the --preinclude mbed_config.h with --preinclude=mbed_config.h
2016-06-27 14:06:42 -05:00
Jimmy Brisson f92d3ec9be Move name of config file to one location 2016-06-27 14:06:42 -05:00
Jimmy Brisson 3a273f78f2 Create and enable exporter flag mbed_conf_active for exporters
The mbed_conf_active feature disables configuration macros on the
command line and replaces them with a preinclude header file
2016-06-27 14:06:42 -05:00
Jimmy Brisson c06dad55d9 Change uVisoun[45] to get preincludes 2016-06-27 14:06:42 -05:00
Jimmy Brisson a1b73c9b7e Fix typo after rebase 2016-06-27 14:06:41 -05:00
Mihail Stoyanov 879ae8c6bd Fixed gcc.py typo
get_conifg_option -> get_config_option
2016-06-27 14:06:41 -05:00
Jimmy Brisson d9b4109143 Update progen-style flags with the toolchains include mbed_conf.h 2016-06-27 14:06:41 -05:00
Jimmy Brisson 5532fb8697 Export command line for including mbed_conf.h from toolchains 2016-06-27 14:06:34 -05:00
Jimmy Brisson 4f29483255 Update exporters to include the generated mbed_conf.h 2016-06-27 13:59:56 -05:00
Sam Grove f7ad7d2e27 Merge pull request #2005 from screamerbg/env-var-paths
[Tools] Add environmental variables support for toolchain paths
2016-06-27 11:41:58 -05:00
Sam Grove f3e15ebfa3 Merge pull request #2020 from mbedmicro/fix_iar_asm_options
Fixed config-related options for the IAR assembler
2016-06-27 11:37:59 -05:00
Bogdan Marinescu 676cfbb695 Merge pull request #2028 from mbedmicro/add_project_folders
Change directory generation for project files.
2016-06-27 18:52:18 +03:00
Martin Kojtal 2acd3bbf2f Merge pull request #2023 from screamerbg/misc-scripts
Move non-essential scripts to tools/misc/
2016-06-27 17:51:56 +02:00
Bogdan Marinescu 2852932367 Change directory generation for project files.
Before this PR:

```
Successful exports:
  * K64F::uvision       .\projectfiles\uvision\Unnamed_Project_K64F
```

After this PR:

```
Successful exports:
  * K64F::uvision       .\projectfiles\uvision_K64F\Unnamed_Project
```

The directory name now contains <ide>_<target>, and there's a single
project per directory as a result.
2016-06-27 18:16:46 +03:00
Marcelo Salazar d50139c8e3 Minor tweaks 2016-06-27 15:02:05 +01:00
Martin Kojtal fdb401ce4e Exporter - source_relative name fix
relative did not contain enough details what's the intention with
this flag.
2016-06-27 15:29:21 +02:00
Martin Kojtal 5800af11b3 Exporters - add source_relative flag
if we work with relative sources, the flag should be set to True, otherwise
False.

This fixes wrong paths when exporting with --source argument. The exporter would
assume sources were copied, and thus reference them all within the root of the generated
project.
2016-06-27 15:25:44 +02:00
Mihail Stoyanov 925781c6a7 Move non-essential scripts to tools/misc/ 2016-06-27 14:11:38 +01:00
Bogdan Marinescu b4e8cf655d Fixed config-related options for the IAR assembler
The IAR assembler doesn't accept '--preinclude', but it accepts -D.
This commit changes the way the config-related macros are propagated
to the IAR assembler to use '-D' instead of '--preinclude'. This is
the only change related to functionality, the others are small,
backward compatible changes to the config code to make passing arguments
to the toolchain instances easier.

Tested by compiled blinky with IAR, GCC_ARM and ARM for K64F.
2016-06-27 15:54:38 +03:00
Marcelo Salazar fbd8a41fed Reverted changes and improved wording 2016-06-27 13:31:56 +01:00
Marcelo Salazar c0f53ccb21 [memap] Removing stack/heap and minor improvements
- Removing stack & heap (dynamic) RAM information
  This information was misleading and shouldn't be shown in memap.
  E.g. each task may have its own stack region configured at run time.

- Adding 'bytes' unit in the total memory info

- Right aligment of numbers, so it is easier to compare numbers
2016-06-27 11:44:01 +01:00
Mihail Stoyanov faa427db77 Add environmental variables support for toolchain paths
Also updated license of settings.py and default_settings.py and added
comments
2016-06-24 23:03:08 +01:00
Sam Grove 33cec194c6 Revert "Generalize flag handling" 2016-06-24 16:39:01 -05:00
Sam Grove 667d49ed8f Merge pull request #1985 from kjbracey-arm/iar_vlas
Turn on C99 VLAs in IAR
2016-06-24 16:13:22 -05:00
Sam Grove 6dd11c76e4 Merge pull request #1976 from theotherjimmy/memap-args
Generalize flag handling
2016-06-24 15:03:50 -05:00
Jimmy Brisson 7b3ef2179f Make mcu and tool arguments many and update all consumers of them 2016-06-24 14:23:19 -05:00
Jimmy Brisson d757f35d15 Update style 2016-06-24 14:23:19 -05:00
Jimmy Brisson 7e5deaa7d0 standardize on nargs="*" 2016-06-24 14:23:19 -05:00
Jimmy Brisson 3276854f49 fix parse error in test.py and make -n + -p comma separated 2016-06-24 14:23:19 -05:00
Jimmy Brisson 439d2e8539 Add -S, -L, and --source to the project.py mutually exclusive group 2016-06-24 14:23:19 -05:00
Jimmy Brisson 053efc6864 Add -S, -L, and --source to the mutually exclusive group 2016-06-24 14:23:19 -05:00
Jimmy Brisson c969a4c784 Better test completion and everything that can be is columnated 2016-06-24 14:23:17 -05:00
Jimmy Brisson 91c45a7b6f Improve test -n and -p failure messages 2016-06-24 14:22:48 -05:00
Jimmy Brisson 2fc4d64b07 Brought test_api.py and users into the new order of argument parsing 2016-06-24 14:22:48 -05:00
Jimmy Brisson 18868ff3fb Convert project.py to the new style of argument parsing 2016-06-24 14:22:47 -05:00
Jimmy Brisson c5ac2cfdec Create type combinator many 2016-06-24 14:22:47 -05:00
Jimmy Brisson e4c6bcd724 Move test parsers to tests.py 2016-06-24 14:22:47 -05:00
Jimmy Brisson b98c8c1c33 Generalize all appropriate arguments and check for file existance 2016-06-24 14:22:47 -05:00
Jimmy Brisson 43e036d6e1 Move to argparse from optparse 2016-06-24 14:22:47 -05:00
Jimmy Brisson 52a7f64d67 Generalize parsing types 2016-06-24 14:22:41 -05:00
Sam Grove 0bbac4138d Merge pull request #1999 from screamerbg/fix-ignore-root
Fixed .mbedignore logic to ignore the walk() root
2016-06-23 22:40:35 -05:00
Sam Grove d3a6ac3f5f Merge pull request #1995 from geky/fix-debug-info
[tools] Reorder option handling in toolchains
2016-06-23 22:34:18 -05:00
Mihail Stoyanov 5f92574163 Merge pull request #1986 from svastm/fix_report
Fix html report exporter row tag
2016-06-24 02:26:30 +01:00
Mihail Stoyanov 6c53baf7d2 Fixed match walk() root against the ignore list.
For example .mbedignore in tools/ contains '*' and naturally should match all files, folders including tools/ itself. Without this fix, tools/ is added to the include path
2016-06-24 01:24:09 +01:00
Jimmy Brisson ee8a02c6ab Generalize export format flag input 2016-06-23 15:45:31 -05:00
Jimmy Brisson f442fd9394 Broaden acceptable toolchain spec; improved incorrect toolchain error 2016-06-23 15:45:31 -05:00
Kevin Bracey b74546c731 Warn about or prevent VLA use in C++
ARM and GNU compilers currently are in a mode where they will accept VLAs
in C++ as an extension. IAR does not accept them in C++.

Avoid potential portability surprises by making GCC warn, and
deactivating the extension in ArmCC.
2016-06-23 09:57:05 +03:00
Kevin Bracey 80a03e1787 Turn on C99 VLAs in IAR
IAR defaults to C99 mode, but doesn't enable VLAs by default. Enable them
to make it more conformant.

We don't have much if any code using actual variable-length arrays, but
variably-modified types are occasionally used. The same switch controls
both.

(VLAs were actually already enabled in most of the project export
templates, but not the build script).
2016-06-23 09:34:12 +03:00
Christopher Haster 5a4c5df4dc [tools] Reordered option handling in toolchains
Options were parsed and logged before per-toolchain
logging was setup.

Fixes #1990
2016-06-22 09:23:33 -05:00
Bogdan Marinescu f864b8439f Merge pull request #1983 from mbedmicro/fix_config_tests
Fix K64F-based config tests
2016-06-22 16:47:32 +03:00
svastm e4f38b031f Fix html report exporter row tag 2016-06-22 11:36:22 +02:00
Mihail Stoyanov 541c478dbf Remove tracking of existing mbed_config.h in the source tree 2016-06-21 23:43:09 +01:00
Mihail Stoyanov 4d68152ef1 Rename mbed_conf.h to mbed_config.h
Following the pattern device_has to DEVICE_, features to FEATURE_,
the mbed config system should map to mbed_config.h
2016-06-21 23:41:04 +01:00
Sam Grove 3a01862a4f Merge pull request #1967 from screamerbg/fix-double-ignores
Fixed double-ignored files that cause python exception
2016-06-21 17:36:01 -05:00
Jimmy Brisson 65517d6513 Removes units to make the table fit without scrolling on github 2016-06-21 16:30:29 -05:00
Jimmy Brisson 6906b97ba0 Adds a simple text file report format
Should resolve #1583
2016-06-21 16:20:19 -05:00
Bogdan Marinescu 20583ba172 Fix K64F-based config tests
PR #1974 added a new configuration parameter to K64F, which in turn made
some tests break, because they found an unexpected configuration
parameter. Fixed by defining a special target for the tests
(test_target) that can be used independently of the actual mbed targets.
2016-06-21 19:58:03 +03:00
Mihail Stoyanov e835c48cc8 Rename ignore_ptrs to ignore_patterns
Add comments to code
2016-06-17 23:27:50 +01:00
Bogdan Marinescu 6858117ff2 Conversion of boolean configuration parameters to integers
Boolean configuration parameters will now be generated as integers (1
for True, 0 for False).
2016-06-17 12:56:10 +03:00
Bogdan Marinescu 8f8733480a Remove redundant whitespaces 2016-06-17 12:19:11 +03:00
Mihail Stoyanov fb5c4a6381 Fixed double-ignored files that cause python exception
Also simplify build scanning logic and add comments
2016-06-17 00:46:14 +01:00
Mihail Stoyanov 89bb38f683 Fixed exporters to support features
Unified how resources are loaded into the configuration system
(Config.load_resources) and applied it to build_api and exporters
2016-06-16 18:12:04 +01:00
Martin Kojtal 1e18ea230a Merge pull request #1957 from mbedmicro/config_headers
Configuration in header files - step 1
2016-06-16 18:47:15 +02:00
Bogdan Marinescu a164224acf Changed prefix file name to mbed_conf.h
Also changed some function names to make it clear that the prefix
headers feature is only used for config.
2016-06-16 17:01:41 +03:00
Bogdan Marinescu 85eca37d29 Added toolchain support for configuration in prefix headers
This commit uses the previously introduced feature of generating
configuration data as a C header file rather than as command line macro
definitions. Each toolchain was modified to use prefix headers if
requested, and build_api.py was modified to set up the toolchain's
prefix header content using the data generated by the config system.

Tested by compiling blinky for GCC and ARMCC. I'm having a few issues
with my IAR license currently, but both ARMCC and IAR use the same
`--preinclude` option for prefix headers, so this shouldn't be an issue.

Note that at the moment all exporters still use the previous
configuration data mechanism (individual macro definitions as opposed to
a prefix header). Exporters will be updated in one or more PRs that will
follow.
2016-06-16 16:13:50 +03:00
Bogdan Marinescu 80a70fcb51 Simplified string formatting expressions in get_config_data_header 2016-06-16 11:41:22 +03:00
Mihail Stoyanov e44566b319 Fix libraries being built with features support 2016-06-16 00:31:25 +01:00
Sam Grove ac1a63f1a1 Merge pull request #1956 from screamerbg/fix-features3
Fixed features not being included
2016-06-15 23:13:26 +01:00
Sam Grove 934951a002 Merge pull request #1955 from theotherjimmy/name-libs
Add -N/--artifact-name argument to parser to name libraries
2016-06-15 22:30:19 +01:00
Sam Grove 605cb86ba7 Merge pull request #1954 from 0xc0170/fix_project_report
Export - project name fix (.zip)
2016-06-15 22:29:03 +01:00
Sam Grove 44e706e5b2 Merge pull request #1948 from 0xc0170/fix_iar
iar - fix flags for cmd and exporters
2016-06-15 22:27:03 +01:00
Bogdan Marinescu ab0a5a53c2 Configuration in header files - step 1
The current implementation of the configuration system "compiles" the
configuration parameters to macros defined on the command line. This
works, but has a few limitations:

- it can bring back the maximum command line length issues in Windows.
- depending on the type of the configuration parameter, it might require
  special quoting of its value in the command line.
- various 3rd party IDE/tools seem to have some limitations regarding
  the total length of the macros that can be defined.

This commit is the first step in replacing the current mechanism with
one that generates configuration in header files that will be
automatically included, instead of command line macro definitions. The
commit only adds the method for generating the header file, it doesn't
actually change the way config is used yet (that will happen in step 2),
thus it is backwards compatible. The logic of the configuration system
itself is unchanged (in fact, the whole change (not only this commit) is
supposed to be completely transparent for the users of the configuration
system).

The commit also fixes an issue in tools/get_config.py that appeared as a
result of a recent PR: the signature of "get_config" in
tools/build_api.py changed, but tools/get_config.py was not updated.
2016-06-16 00:23:04 +03:00
Mihail Stoyanov a81746c8f6 Fix for features not being included
Also improve compile speed by not re-scanning the source locations
2016-06-15 22:21:31 +01:00
Jimmy Brisson 6de4ea7e6f Adds -N/--artifact-name argument to parser
Only makes sence for --source builds (which only work with --build)
2016-06-15 15:07:25 -05:00
0xc0170 c16c75f2af iar - fix flags for cmd and exporters
Exporters and cmd do not share all flags, some asm and c flags are not the same (cpu, fpu)
2016-06-15 21:04:48 +01:00
Martin Kojtal 7c08e36ec7 tools/project - export report fix name
Previously it was .zip always, even when using sources. This patch fixes it:`

```
Successful exports:
  * K64F::uvision       path\projectfiles\uvision\Unnamed_Project_K64F
```
2016-06-15 18:54:17 +01:00
Sam Grove 7e0e6854b9 Merge pull request #1940 from geky/fix-features
[build tools] Added better support for features and recursive configs
2016-06-15 18:46:38 +01:00
Christopher Haster 0d9d4639cd [build tools] Added proper namespace for features
per @bogdanm
2016-06-15 10:34:32 -05:00
Mihail Stoyanov 99ed4e03f1 Restore original compile sources routine 2016-06-15 17:18:40 +01:00
Sam Grove fd983d1c6c Merge pull request #1937 from bridadan/fix-tests-softdevices
Fixing test builds for devices with softdevices.
2016-06-15 15:25:51 +01:00
Brian Daniels 5a46ac773b Fixing test builds for devices with softdevices.
Previously, .hex files were not copied when building source as a library.
This prevents builds that pre compile source as a library and then
includes the build directory as the only source (because there is no
softdevice present). This PR copies hex files when compiling source
as a library.
2016-06-15 15:21:16 +01:00
Christopher Haster 41daccf8d9 [build tools] Fixed masked out configuration error 2016-06-15 08:38:20 -05:00
Christopher Haster f45dc15aa8 [build tools] Added test for configurations set from same level as feature 2016-06-15 08:38:20 -05:00
Christopher Haster e70efe3a41 [build tools] Made config settings compatible with features system
per @screamerbg
2016-06-15 08:38:20 -05:00
Christopher Haster 6da324fa3f [build tools] Added test coverage for config features feature 2016-06-15 08:38:20 -05:00
Christopher Haster d9749b0447 [build tools] Added list of supported features
per @screamerbg
2016-06-15 08:38:20 -05:00
Christopher Haster ce0606a756 [build tools] Added better support for features and recursive configs
per @screamerbg
2016-06-15 08:38:20 -05:00
Sam Grove 2a4a02caa7 Merge pull request #1944 from mbedmicro/ctrl-c-traceback
Fixes the python traceback when the user does ctrl+c during compilation
2016-06-15 12:29:21 +01:00
Mihail Stoyanov edc1fa1865 Fixes the python traceback when the user does ctrl+c during compilation 2016-06-15 01:08:35 +01:00
Mihail Stoyanov d0db5c94e5 Removed IAR --vla flag which breaks compatibility with IAR Workbench 2016-06-15 00:06:43 +01:00
Sam Grove 7d0060aa7b Revert "Fix iar exporter - flags duplication and consolidations" 2016-06-14 23:31:57 +01:00
0xc0170 dea0b1d598 iar template - disable vla 2016-06-14 21:39:02 +01:00
Martin Kojtal 9b5adb8cd1 Merge pull request #1752 from svastm/add_nucleo_l011k4
Add NUCLEO_L011K4
2016-06-14 22:00:28 +02:00
Martin Kojtal ba69e82fc7 Merge pull request #1850 from LMESTM/dev_new_serial_complete_test
Add a serial transmission complete test
2016-06-14 21:54:48 +02:00
Martin Kojtal 1f9d28346f Merge pull request #1924 from 0xc0170/fix_armcc
Fix armcc ulib template - removal
2016-06-14 20:06:26 +02:00
Martin Kojtal cfa4d0c855 Merge pull request #1938 from 0xc0170/fix_iar
Fix iar exporter - flags duplication and consolidations
2016-06-14 18:45:16 +02:00
0xc0170 69c3da581d iar - flags consolidation
- vla flag is not compatible with c++ (not supported), it generates an error
in the IDE. Therefore we remove it
- common flags - add dlib and thum to the common flags.
- cpu flag is for only runtime cmd, IDE sets it via defined MCU, not required.
2016-06-14 16:19:39 +01:00
Mihail Stoyanov ffa45c9935 Merge pull request #1932 from geky/fix-dup-feature-defines
Removed duplicate feature declarations
2016-06-14 15:59:47 +01:00
0xc0170 bf6b88aa62 iar template - fix output obj - generate a binary 2016-06-14 14:37:04 +01:00
Olaf Hagendorf e829d8b34d [uviosn5] some fixes for PR #1933
- one missing import
- typo: uvision instead of uvision5 used
2016-06-14 14:53:22 +02:00
0xc0170 58aa227a8c armcc - fix libpath - windows spaces 2016-06-14 13:03:15 +01:00
Martin Kojtal 262b2e4a46 Merge pull request #1933 from 0xc0170/fix_uvision_cpp
uvision - remove --cpp flag from exporters
2016-06-14 13:43:02 +02:00
0xc0170 a3e1143317 uvision - remove --cpp flag from exporters
The cpp files are by default compiled with --cpp. Including this flag, causing
C files compiled as C++ files. Thus we remove them. We could potentionally
remove it from cxx flags as well.
2016-06-14 12:33:26 +01:00
Laurent Meunier 8cb46bc602 Add a serial transmission complete test
This automated test makes sure that the serial
syncrhonous API ensures a full transmission before
the function returns. The complete string sent by
printf shall be completely transferred before printf
returns and the sleep modes are called.

mbed Issue #1849
2016-06-14 12:03:22 +02:00
Christopher Haster 54118c09a6 Removed duplicate feature declarations 2016-06-13 23:23:03 -05:00
Mihail Stoyanov bd2159db26 Merge pull request #1930 from mbedmicro/iar-fix
Fixed flag for IAR
2016-06-14 05:09:10 +01:00
Mihail Stoyanov 3fa9ed79a5 Fixed flag for IAR 2016-06-14 04:42:45 +01:00
Brian Daniels 1bcd64301a Lower case test names, blob matching test names, and sort test names for prints 2016-06-14 02:14:45 +01:00
Brian Daniels f622c591e8 Handling exceptions throughout test flow 2016-06-14 02:14:44 +01:00
Brian Daniels 6796025e78 Fixes for logs and test logic in tools 2016-06-14 02:14:42 +01:00
Mihail Stoyanov dcff9b15e7 Minor update to tools - logging of tests and output 2016-06-14 01:57:01 +01:00
0xc0170 269697d6d4 targets - remove ulib template
armcc provides command line option for choosing a lib type, and we use this,
thus a template is not needed.
2016-06-14 00:41:45 +01:00
0xc0170 4ebdb4556c uvision template - remove injected misc flags (already defined as armcc flags) 2016-06-14 00:26:27 +01:00
Martin Kojtal bb8994b270 Merge pull request #1903 from ytsuboi/master
[HRM1017] Update exporting template
2016-06-13 23:38:01 +02:00
Martin Kojtal b28f7108f7 Merge pull request #1918 from ARM-software/master
[BEETLE] Enable RTOS on Beetle
2016-06-13 23:06:25 +02:00
0xc0170 724715002a uvision - flags consolidation
Remove error for include system path in the exporters. Assembly does not use
armcc flags, fails to build, as those are not valid armasm.
2016-06-13 17:53:08 +01:00
0xc0170 dbc940b9b3 uvision exporter - use only c flags
cxx flags are not needed as uvision uses C/C++ tab (thus c_flags only)
2016-06-13 17:22:27 +01:00
0xc0170 160030052b armcc - fix include path for armcc bin file correction 2016-06-13 16:55:56 +01:00
0xc0170 0b2c37a17c uvision exporter - fix cxx flag - remove ld flags
This was a bug, as ld flags should not be part of cxx flags. They result as some
options not recognized.
2016-06-13 16:51:54 +01:00
0xc0170 a92bf1c3b8 Tools/project - project dir should be the list
The project dir if using just project.py shall be a list of directories.
2016-06-13 16:51:40 +01:00
Vincenzo Frascino f8d7a76128 [BEETLE] Enable RTOS on Beetle
This patch enables RTOS support on Beetle.
It contains:
* Updated Beetle Startup code for ARMCC
* Modified SysTick Driver
* RTOS specific configuration parameters
* RTOS specific test suite enablement

Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
2016-06-13 16:21:19 +01:00
0xc0170 88054fa959 IAR - add ld flags to link hook 2016-06-13 16:02:50 +01:00
0xc0170 dde970dc4a Tools/export - iar fix misc dictionary update
progen defines flags as misc, thus we need to add flags to misc.
2016-06-13 16:02:48 +01:00
Jimmy Brisson a4baaf8d5c Move IAR linker flags into the DEFAULT_FLAGS dict 2016-06-13 16:02:47 +01:00
Jimmy Brisson 685f4ed648 Adds -funsigned-char to default gcc args
It would resolve #1525, but for the fact that KDS is used.
2016-06-13 16:02:45 +01:00
Jimmy Brisson c6fc70e461 Updates exportes to use flags from toolchains
Affects the following exporters:
    - amtelstudio
    - codered
    - emblocks
    - gcc_arm
    - iar
    - simplicityv3
2016-06-13 16:02:43 +01:00
Jimmy Brisson e3b9def8cf Refactors all toolchains to have flags api 2016-06-13 15:58:23 +01:00
Martin Kojtal 3a0d5611dd Merge pull request #1911 from mbedmicro/config-tests
Config tests, GCC flags, requirements.txt
2016-06-13 16:52:49 +02:00
Vincenzo Frascino 4f61cfd7f6 [BEETLE] Add support for GCC ARM exporter
This patch adds support for GCC ARM exporter to the Beetle Target.

Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
2016-06-13 14:26:47 +01:00
Vincenzo Frascino c1442139a0 [BEETLE] Add support for uVision 5 exporter
This patch adds support for uVision 5 exporter to the Beetle Target.

Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
2016-06-13 14:26:45 +01:00
Vincenzo Frascino 0d3268b61c [BEETLE] Add initial support
This patch adds support for the BEETLE Target. The compilers supported by
this target are:
* ARMCC
* GCC ARM

The exporters and the CMSIS/HAL components will follow in future patches.

Signed-off-by: Vincenzo Frascino <vincenzo.frascino@arm.com>
2016-06-13 11:55:33 +01:00
svastm c9bf3ca2fd [NUCLEO_L011K4] Add to the build and export scripts 2016-06-13 10:24:19 +02:00
Sam Grove 5acdad9fd7 Merge pull request #1907 from c1728p9/only_allow_one_thread_for_unsafe_stdlib
Only allow one thread for unsafe stdlib
2016-06-12 22:03:07 +01:00
Martin Kojtal 7bb4378f2d Merge pull request #1901 from theotherjimmy/uvision4-alias
Add alias for uvision4 exporter
2016-06-12 22:00:16 +02:00
Mihail Stoyanov 0034ffb716 Add tests to the config system. Add GCC flags to support uVisor 2016-06-12 19:04:41 +01:00
Russ Butler 3db2c030d2 Only allow one thread on unsafe standard libs
When using a standard library which does not support multi-threading
allow only one thread to be used.  This allows the code to remain
safe.
2016-06-12 18:18:40 +01:00
Mihail Stoyanov 8f4cb59002 Added script for detecting connected mbed targets/boards 2016-06-12 10:59:51 +01:00
Mihail Stoyanov 9dbf80722d Aligned make.py and build.py options 2016-06-12 01:06:15 +01:00
Christopher Haster 2d38065e1f [build tools] Added support for completely overriding cumulative attributes 2016-06-11 15:45:11 -05:00
Christopher Haster 36904fad1f [build tools] Moved cumulative attributes into target overrides
Attributes now get the filtering provided by target_overrides:
{
    "name": "cmsis-nodejs-SQL-x86",
    "target_overrides": {
        "*": {
            "device_has": ["SILLY_STRING", "FIRE"]
        },
        "SHOE": {
            "features_add": ["SMELLS_FUNNY"],
            "features_remove": ["SMELLS_NICE"],
        }
    }
}

per @screamerbg
2016-06-11 15:30:26 -05:00
Christopher Haster e3bde44b87 [build tools] Added support for cumulative attributes in configs directly
in mbed_lib.json:
{
    "name": "cmsis-nodejs-SQL-x86",
    "features_add": ["SMELLS_FUNNY"],
    "features_remove": ["SMELLS_NICE"],
    "device_has": ["SILLY_STRING", "FIRE"]
}
2016-06-11 14:44:59 -05:00
Yoshihiro TSUBOI 3c2229a2b1 [HRM1017] Update exporting template
changed merging softdevice from s110 to s130
2016-06-11 08:06:06 +09:00
Jimmy Brisson e333f9008f Add alias for uvision4 exporter
it is now called both uvision (old name) and uvision4 (new alias)
2016-06-10 14:22:30 -05:00
Mihail Stoyanov f6acb1ffb4 Forward ported changes to tools 2016-06-10 15:19:02 +01:00
Mihail Stoyanov 51c10165ca Fixed toolchain flags so exporters can use them 2016-06-10 13:12:21 +01:00
Mihail Stoyanov 75a18ff1a3 Add config system macros to exporters
Support various exporter features
2016-06-10 11:27:23 +01:00
Mihail Stoyanov 9f62d70fbf Update project generator script to allow working with any source
Update test exporters script
Update travis build script
Added config system CLI script
Fixed building of legacy libraries and layouts
2016-06-10 02:24:27 +01:00
Mihail Stoyanov c2e3001739 Add config system, memap, updates to build_api and toolchains 2016-06-09 23:50:03 +01:00
Mihail Stoyanov 773dab514e Add --source option to both build.py and make.py. Also add test.py script for compiling and listing tests 2016-06-09 23:11:23 +01:00
Mihail Stoyanov 87a978c4e8 Move private_settings.py to root mbed_settings.py. Various updates to reflect the path changes 2016-06-09 22:24:05 +01:00
Mihail Stoyanov 5e6722dbab Ported updates to targets, utils and settings scripts 2016-06-09 22:05:35 +01:00
Mihail Stoyanov 42c62abed1 Further changes to reflect workspace_tools to tools rename 2016-06-09 21:40:54 +01:00
Mihail Stoyanov 3d45b2cdbb Renamed workspace_tools folder to tools 2016-06-09 21:34:53 +01:00