fluid icon indicating copy to clipboard operation
fluid copied to clipboard

Fluid fails to build on the Linux/ARM64 platform [FEATURES]

Open odidev opened this issue 3 years ago • 4 comments
trafficstars

What feature you'd like to add:

Hi Team,

I am working with Fluid on the Linux/ARM64 platform. Following the documentation here, I tried building fluid binaries from source using make build, but failing at it, with the below logs:

# github.com/agiledragon/gomonkey 
vendor/github.com/agiledragon/gomonkey/patch.go:163:10: undefined: buildJmpDirective 
make: *** [Makefile:109: vet] Error 123 

It is because gomonkey version 2.0.2+incompatible is used in fluid, which does not support Linux/ARM64. However, the ARM64 support has been added in gomonkey from version 2.2.0 onwards.

Following this old closed fluid PR here, I tried updating the gomonkey version to 2.2.0 in the source code, but make build failed again with the below logs:

pkg/ddc/alluxio/cache_test.go:29:2: cannot find package "." in: 
        /home/ubuntu/go/src/github.com/fluid-cloudnative/fluid/vendor/github.com/agiledragon/gomonkey/v2 

May I know, do you have plans to add Linux/ARM64 support in Fluid? If yes, I will be happy to help. Can you please provide pointers on the above issues while updating gomonkey version?

odidev avatar Dec 17 '21 13:12 odidev

@odidev , I'm happy to hear that you are working on fluid for ARM64 platform. Yes, definitely yes. we are going to support ARM64 platform in future. For your issue, seems the following package doesn't work correctly. And it's for unit test, you are welcome to fix it. And if there is any issue you encounter in fixing it. please let me know. thanks.

"github.com/smartystreets/goconvey/convey"

You can also reach me by email. My email address is [email protected].

cheyang avatar Dec 18 '21 07:12 cheyang

@cheyang, Thank you for the response.

I have successfully generated the binaries by deleting the content of gomonkey in the vendor directory, creating v2 folder in gomonkey, cloning the gomonkey’s fresh master branch in the v2 folder, and editing GOARCH to arm64 in the makefile.

However, unit-test is failing on the Linux/ARM64 platform with SIGILL and configuration errors. Kindly find the error logs in the attached file here: fluid_test_failure_logs_ARM64.txt

Can you please provide some pointers on how can I resolve these issues? It seems many sub-packages are failing.

odidev avatar Dec 23 '21 11:12 odidev

Hi Team, can you please review the error logs above and suggest pointers regarding the errors while testing on the ARM64 platform?

odidev avatar Jan 05 '22 14:01 odidev

@cheyang, could you please have a look at this and share your suggestion on the same?

odidev avatar Jan 03 '23 11:01 odidev