Skip to content

Commit 87a978c

Browse files
committed
Move private_settings.py to root mbed_settings.py. Various updates to reflect the path changes
1 parent 5e6722d commit 87a978c

15 files changed

+32
-32
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dist
77
MANIFEST
88

99
# Private settings
10-
private_settings.py
10+
mbed_settings.py
1111

1212
# Default Build Directory
1313
.build/

docs/BUILDING.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -153,9 +153,9 @@ Workspace tools are set of Python scripts used off-line by Mbed SDK team to:
153153
Before we can run our first test we need to configure our test environment a little!
154154
Now we need to tell workspace tools where our compilers are.
155155

156-
* Please to go ```mbed/tools/``` directory and create empty file called ```private_settings.py```.
156+
* Please to go ```mbed``` directory and create empty file called ```mbed_settings.py```.
157157
```
158-
$ touch private_settings.py
158+
$ touch mbed_settings.py
159159
```
160160
* Populate this file the Python code below:
161161
```python
@@ -203,10 +203,10 @@ GCC_CR_PATH = "C:/Work/toolchains/LPCXpresso_6.1.4_194/lpcxpresso/tools/bin"
203203
IAR_PATH = "C:/Work/toolchains/iar_6_5/arm"
204204
```
205205

206-
Note: Settings in ```private_settings.py``` will overwrite variables with default values in ```mbed/tools/settings.py``` file.
206+
Note: Settings in ```mbed_settings.py``` will overwrite variables with default values in ```mbed/default_settings.py``` file.
207207

208208
## Build Mbed SDK library from sources
209-
Let's build mbed SDK library off-line from sources using your compiler. We've already cloned mbed SDK sources, we've also installed compilers and added their paths to ```private_settings.py```.
209+
Let's build mbed SDK library off-line from sources using your compiler. We've already cloned mbed SDK sources, we've also installed compilers and added their paths to ```mbed_settings.py```.
210210
We now should be ready to use workspace tools script ```build.py``` to compile and build mbed SDK from sources.
211211

212212
We are still using console. You should be already in ```mbed/tools/``` directory if not go to ```mbed/tools/``` and type below command:

docs/TESTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -492,7 +492,7 @@ $ git clone https://github.com/mbedmicro/mbed.git
492492
$ hg clone https://mbed.org/users/rgrover1/code/cpputest/
493493
```
494494

495-
After above three steps you should have proper directory structure. All you need to do now is to configure your ```private_settings.py``` in ```mbed/tools/``` directory. Please refer to mbed SDK build script documentation for details.
495+
After above three steps you should have proper directory structure. All you need to do now is to configure your ```mbed_settings.py``` in ```mbed``` directory. Please refer to mbed SDK build script documentation for details.
496496

497497
## CppUTest with mbed port
498498
To make sure you actualy have CppUTest library with mbed SDK port you can go to CppUTest ```armcc``` platform directory:

setup.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,17 @@
1616
OWNER_NAMES = 'emilmont, bogdanm'
1717
1818

19-
# If private_settings.py exists in tools, read it in a temporary file
19+
# If mbed_settings.py exists in tools, read it in a temporary file
2020
# so it can be restored later
21-
private_settings = join('tools', 'private_settings.py')
21+
mbed_settings = join('mbed_settings.py')
2222
backup = None
23-
if isfile(private_settings):
23+
if isfile(mbed_settings):
2424
backup = TemporaryFile()
25-
with open(private_settings, "rb") as f:
25+
with open(mbed_settings, "rb") as f:
2626
copyfileobj(f, backup)
2727

28-
# Create the correct private_settings.py for the distribution
29-
with open(private_settings, "wt") as f:
28+
# Create the correct mbed_settings.py for the distribution
29+
with open(mbed_settings, "wt") as f:
3030
f.write("from mbed_settings import *\n")
3131

3232
setup(name='mbed-tools',
@@ -42,8 +42,8 @@
4242
license=LICENSE,
4343
install_requires=["PrettyTable>=0.7.2", "PySerial>=2.7", "IntelHex>=1.3", "colorama>=0.3.3", "Jinja2>=2.7.3", "project-generator>=0.8.11,<0.9.0", "junit-xml", "requests", "pyYAML"])
4444

45-
# Restore previous private_settings if needed
45+
# Restore previous mbed_settings if needed
4646
if backup:
4747
backup.seek(0)
48-
with open(private_settings, "wb") as f:
48+
with open(mbed_settings, "wb") as f:
4949
copyfileobj(backup, f)

tools/buildbot/master.cfg

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -286,20 +286,20 @@ from buildbot.config import BuilderConfig
286286

287287
c['builders'] = []
288288

289-
copy_private_settings = ShellCommand(name = "copy private_settings.py",
290-
command = "cp ../private_settings.py tools/private_settings.py",
289+
copy_mbed_settings = ShellCommand(name = "copy mbed_settings.py",
290+
command = "cp ../mbed_settings.py mbed_settings.py",
291291
haltOnFailure = True,
292-
description = "Copy private_settings.py")
292+
description = "Copy mbed_settings.py")
293293

294294
mbed_build_release = BuildFactory()
295295
mbed_build_release.addStep(git_clone)
296-
mbed_build_release.addStep(copy_private_settings)
296+
mbed_build_release.addStep(copy_mbed_settings)
297297

298298
for target_name, toolchains in OFFICIAL_MBED_LIBRARY_BUILD:
299299
builder_name = "All_TC_%s" % target_name
300300
mbed_build = BuildFactory()
301301
mbed_build.addStep(git_clone)
302-
mbed_build.addStep(copy_private_settings)
302+
mbed_build.addStep(copy_mbed_settings)
303303
# Adding all chains for target
304304
for toolchain in toolchains:
305305
build_py = BuildCommand(name = "Build %s using %s" % (target_name, toolchain),

tools/host_tests/tcpecho_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
import string, random
1919
from time import time
2020

21-
from private_settings import SERVER_ADDRESS
21+
from mbed_settings import SERVER_ADDRESS
2222

2323
ECHO_PORT = 7
2424

tools/host_tests/tcpecho_server.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
from SocketServer import BaseRequestHandler, TCPServer
1818
from time import time
1919

20-
from private_settings import LOCALHOST
20+
from mbed_settings import LOCALHOST
2121

2222
MAX_INDEX = 126
2323
MEGA = float(1024 * 1024)

tools/host_tests/tcpecho_server_loop.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
ROOT = abspath(join(dirname(__file__), "..", ".."))
2121
sys.path.insert(0, ROOT)
2222

23-
from tools.private_settings import LOCALHOST
23+
from mbed_settings import LOCALHOST
2424
from SocketServer import BaseRequestHandler, TCPServer
2525

2626

tools/host_tests/udpecho_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
import string, random
1919
from time import time
2020

21-
from private_settings import CLIENT_ADDRESS
21+
from mbed_settings import CLIENT_ADDRESS
2222

2323
ECHO_PORT = 7
2424

tools/host_tests/udpecho_server.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
limitations under the License.
1616
"""
1717
from SocketServer import BaseRequestHandler, UDPServer
18-
from private_settings import SERVER_ADDRESS
18+
from mbed_settings import SERVER_ADDRESS
1919

2020
class UDP_EchoHandler(BaseRequestHandler):
2121
def handle(self):

0 commit comments

Comments
 (0)