-
Notifications
You must be signed in to change notification settings - Fork 687
Add support of cross-compilation for linux-based targets. #206
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe, it is better to use mktemp utility for generation of a directory with random name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
4fc8161 to
e0f8c72
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is not related to the PR, but required for cross building. I'll push this change as a separate commit.
e456ab5 to
d8a9c3e
Compare
|
@ruben-ayrapetyan gcc version 4.7.4 (Ubuntu/Linaro 4.7.4-2ubuntu1) |
|
@ruben-ayrapetyan |
|
@egavrin, looks good. |
d8a9c3e to
74c56b1
Compare
|
Folks, I've updated the PR, please check. |
74c56b1 to
9b7ece4
Compare
tools/precommit-full-testing.sh
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe, it is better to wrap variables into quotes, like "$1". In the case, space wouldn't divide variable's value and special characters in path would not be replaced.
http://www.tldp.org/LDP/abs/html/quotingvar.html
"When referencing a variable, it is generally advisable to enclose its name in double quotes. This prevents reinterpretation of all special characters within the quoted string -- except $, ` (backquote), and \ (escape)."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree, it should be wrapped, but other our scripts doesn't follow this style. I may fix it within this PR, but we should fix this in other scripts too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
9b7ece4 to
b9b1704
Compare
|
I'll rise a separate pull request to fix other issues in scripts, likewise. |
|
PR was updated. |
5ecc00a to
8dc8678
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did the strip at the end made the x86_64 cross compilation to cause any problems?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@galpeter no, not really. I may add it back.
I think we can add native toolchain configuration with a separate PR, like Add toolchain_native.cmake.
8dc8678 to
6a1b90e
Compare
|
@galpeter PR was updated, I restored |
f855b19 to
00e00df
Compare
tools/precommit.sh
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't this pass the ${TARGETS} as the 2nd, 3rd and etc args? For example if the TARGETS are: debug.linux release.linux. the command will look like this:
./tools/precommit-full-testing.sh ${OUT_DIR} debug.linux release.linux
Maybe we need to enclose the arguments into quotes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
00e00df to
6267696
Compare
|
seems good to me. |
|
Great! Thank you! |
JerryScript-DCO-1.0-Signed-off-by: Evgeny Gavrin e.gavrin@samsung.com
Usage: - Cross compile: make debug.linux TOOLCHAIN=./build/configs/toolchain_linux_armv7l-el.cmake - Build unittests make unittests TOOLCHAIN=./build/configs/toolchain_linux_armv7l-el.cmake - Run unittests on target board ./tools/runners/run-unittests-remote.sh <ip> <login> <pass> - Run JavaScript test on target board ./tools/runners/run-tests-remote.sh debug.linux <ip> <login> <pass> JerryScript-DCO-1.0-Signed-off-by: Evgeny Gavrin e.gavrin@samsung.com
6267696 to
444bd32
Compare
Usage:
make debug.linux TOOLCHAIN=./build/configs/toolchain_linux_armv7l-el.cmake
make unittests TOOLCHAIN=./build/configs/toolchain_linux_armv7l-el.cmake
./tools/runners/run-unittests-remote.sh
./tools/runners/run-tests-remote.sh debug.linux
JerryScript-DCO-1.0-Signed-off-by: Evgeny Gavrin e.gavrin@samsung.com