Skip to content

Fix a bug using ELF as output extension #6229

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 27, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions tools/toolchains/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1129,8 +1129,10 @@ def link_program(self, r, tmp_path, name):
mkdir(new_path)

filename = name+'.'+ext
# Absolute path of the final linked file
full_path = join(tmp_path, filename)
elf = join(tmp_path, name + '.elf')
bin = None if ext is 'elf' else join(tmp_path, filename)
bin = None if ext == 'elf' else full_path
map = join(tmp_path, name + '.map')

r.objects = sorted(set(r.objects))
Expand All @@ -1154,7 +1156,7 @@ def link_program(self, r, tmp_path, name):
self.var("compile_succeded", True)
self.var("binary", filename)

return bin, needed_update
return full_path, needed_update

# THIS METHOD IS BEING OVERRIDDEN BY THE MBED ONLINE BUILD SYSTEM
# ANY CHANGE OF PARAMETERS OR RETURN VALUES WILL BREAK COMPATIBILITY
Expand Down