-
Notifications
You must be signed in to change notification settings - Fork 903
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
Falco to build on aarch64 #1442
Conversation
This also supersedes the changes made for ppc64le #1225 since the only change needed here was to use moonjit instead of luajit. Many projects and OSes (like Alpine) already use moonjit as a synonim of luajit. This will likely require some testing but the next release is on December 1st so there's no better time than now. |
This PR also updates libsinsp and libscap, it's important to note that those already depend on moonjit for certain architectures and that there was a breaking change that needed to be addressed: draios/sysdig#1693 |
Note: 2.1.2 seems to be the latest moonjit that works for our lua code. Tried to update to 2.2.0 and we start having issues. I know we want to start making plans to remove lua as we already did for the outputs in #1412 so I'll just note this here and we can follow up on that if we don't make such plan in the near future.
|
I switched back to Luajit but got the latest master. See details in the commit 0a08a04 |
LGTM label has been added. Git tree hash: 38666a08c0d209db4431bccb4523719f66de4e8d
|
The minimal build fails are related to our sinsp dependency. Working on it draios/sysdig#1703 |
/hold |
This is needed because Luajit does not support many architectures such as aarch64 and ppcle64. Note: some operating systems, such as Alpine, already use moonjit as a dropin replacement for luajit. Signed-off-by: Lorenzo Fontana <[email protected]>
Related-to: draios/sysdig#1693 Signed-off-by: Lorenzo Fontana <[email protected]>
Signed-off-by: Lorenzo Fontana <[email protected]>
Signed-off-by: Lorenzo Fontana <[email protected]>
moonjit is unmaintaned [0], and lujit recently [1] added support for the aarch64 architecture. [0] https://twitter.com/siddhesh_p/status/1308594269502885889?s=20 [1] LuaJIT/LuaJIT@e9af1ab Signed-off-by: Lorenzo Fontana <[email protected]>
Signed-off-by: Lorenzo Fontana <[email protected]>
Besides all the other improvements, we are really interested in getting the Make options for other ISAs than x86_64 when it comes to compiling abseil [0]. This is what happens on aarch64 ``` make[4]: *** [Makefile:2968: /root/falco/build-musl/grpc-prefix/src/grpc/objs/opt/third_party/abseil-cpp/absl/base/internal/thread_identity.o] Error 1 c++: error: unrecognized command line option '-maes' c++: error: unrecognized command line option '-msse4' c++: error: unrecognized command line option '-msse4' c++: error: unrecognized command line option '-maes' ``` [0] grpc/grpc@bf87ec9 Signed-off-by: Lorenzo Fontana <[email protected]>
…0c6c2cb2b8d08033 Signed-off-by: Lorenzo Fontana <[email protected]>
Signed-off-by: Lorenzo Fontana <[email protected]>
Signed-off-by: Lorenzo Fontana <[email protected]>
…037422c9efb750 Signed-off-by: Lorenzo Fontana <[email protected]>
/hold cancel Ready for review |
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.
Just tried on an aarch64 instance with 18.04.5 LTS (Bionic Beaver).
It works nicely! 👏
LGTM label has been added. Git tree hash: 9c0e213a6aa767f2bd46356c2d3ec416697bb734
|
@@ -57,6 +57,7 @@ add_subdirectory("${SYSDIG_SOURCE_DIR}/driver" "${PROJECT_BINARY_DIR}/driver") | |||
# Add libscap directory | |||
add_definitions(-D_GNU_SOURCE) | |||
add_definitions(-DHAS_CAPTURE) | |||
add_definitions(-DNOCURSESUI) |
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.
💯 finally!
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.
Great job! 👏
Left a suggestion only
webserver.cpp | ||
grpc_context.cpp | ||
grpc_server_impl.cpp | ||
grpc_request_context.cpp | ||
grpc_server.cpp | ||
webserver.cpp |
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.
Is this duplicate? See line 69
webserver.cpp |
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.
yes thanks!
|
||
add_dependencies(falco string-view-lite) | ||
list( |
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.
Cool approach
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: leodido, leogr The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What type of PR is this?
/kind feature
Any specific area of the project related to this PR?
/area build
What this PR does / why we need it:
What happens here:
fntlnz-aarch64
branch, this is because we needed to add some preprocessor gates for aarch64. This needs to be changed with the specific commit id and SHA before merging aarch64 syscalls surface draios/sysdig#17011d8b747c161db457e032a023ebbff511f5de5ec2
- this is because luajit didn't tag since 2017, but they are actively developing it. Initially we wanted to switch to moonjit to support also ppc64le but the new luajit commits also address that along with the 64 bit changes needed for arm64. PleaseWhich issue(s) this PR fixes:
Fixes #520
Special notes for your reviewer:
Does this PR introduce a user-facing change?: