Bug 235057 - databases/mongodb36: support arm64/aarch64
Summary: databases/mongodb36: support arm64/aarch64
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: arm64 Any
: --- Affects Some People
Assignee: Kurt Jaeger
URL:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2019-01-18 23:19 UTC by Ronald Klop
Modified: 2019-02-05 22:32 UTC (History)
5 users (show)

See Also:
pi: maintainer-feedback+


Attachments
patch to compile on aarch64 (105.12 KB, patch)
2019-01-18 23:19 UTC, Ronald Klop
no flags Details | Diff
aarch64 changes in its own extra_patches directory (106.31 KB, patch)
2019-01-20 13:52 UTC, Ronald Klop
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ronald Klop 2019-01-18 23:19:30 UTC
Created attachment 201255 [details]
patch to compile on aarch64

Like PR 229602 I created a patch to build this port on aarch64 (RPI3). This enable the unifi5 port.
It is currently only build tested and should not have any effect on the existing amd64 version.
Comment 1 dev 2019-01-19 20:12:55 UTC
Hi Ronald, thanks for this!

Support for more architectures is welcome, but I sadly lack the hardware and bandwidth to address aarch64 port issues if or when they occur. If you're happy to submit the aarch64 build to more rigourous testing and help with those in the future, you have my blessing!
Comment 2 Ronald Klop 2019-01-20 13:52:33 UTC
Created attachment 201285 [details]
aarch64 changes in its own extra_patches directory

Thank you for your trust.
I'm willing to support the aarch64 version.
For clarity I created a new patch which has the patches for aarch64 in its own files/aarch64 directory and only applies them for aarch64 using the EXTRA_PATCHES construction.
So there is no change (and no possible regression) in the amd64 version.

Are you able to commit this or do we need to find somebody?

NB: This runs on my RPI3B+ now as the unifi5 controller. Not much of a stress test, but it works as expected.
Comment 3 Li-Wen Hsu freebsd_committer freebsd_triage 2019-01-23 18:27:04 UTC
I did a poudriere build test and confirm that it doesn't affect amd64 (build) on 11.2 and 12.0.

BTW, Ronald, this is a big patch, does it make sense to send to the upstream?
Comment 4 Ronald Klop 2019-01-24 13:59:44 UTC
(In reply to Li-Wen Hsu from comment #3)
About sending the patches upstream.
See: https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!msg/mongodb-dev/cq4mL8WzMgA/soc3YVc_EQAJ
It discusses this a little bit about the similar port to MongoDB 3.4.
I think upstream will commit some or all the patches if somebody makes the patches available for their master branch.
Comment 5 Kurt Jaeger freebsd_committer freebsd_triage 2019-02-04 13:17:48 UTC
I'll commit it soon, after PR#234316
Comment 6 Kurt Jaeger freebsd_committer freebsd_triage 2019-02-04 19:27:41 UTC
I tried to build it in poudriere, after creating a test jail for arm:

  poudriere jail -c -j arm -a arm64.aarch64 -m svn+ssh -v head@r340443

Result: The build of gettext-runtime hangs in the configure script at

checking whether // is distinct from /...

and never finishes. Any ideas ?
Comment 7 Ronald Klop 2019-02-04 20:37:03 UTC
(In reply to Kurt Jaeger from comment #6)
On my rpi3 gettext-runtime builds fine.
Comment 8 Mikael Urankar freebsd_committer freebsd_triage 2019-02-04 21:14:33 UTC
(In reply to Kurt Jaeger from comment #6)
It's a known qemu bug, I think it's fixed with https://github.com/seanbruno/qemu-bsd-user/pull/72
Comment 9 Kurt Jaeger freebsd_committer freebsd_triage 2019-02-05 09:48:36 UTC
Thanks for the pointer, I tested the patch from that issue with qemu, no change.
Comment 10 Mikael Urankar freebsd_committer freebsd_triage 2019-02-05 14:31:17 UTC
(In reply to Kurt Jaeger from comment #9)
try this one instead:
https://reviews.freebsd.org/D18835
Comment 11 Kurt Jaeger freebsd_committer freebsd_triage 2019-02-05 16:36:29 UTC
Build continues, so testbuilding right now. (I'm impressed that there's a knob
to cope with that issue 8-)
Comment 12 Kurt Jaeger freebsd_committer freebsd_triage 2019-02-05 22:31:10 UTC
testbuild on current was successful. Committed, thanks!
Comment 13 commit-hook freebsd_committer freebsd_triage 2019-02-05 22:32:03 UTC
A commit references this bug:

Author: pi
Date: Tue Feb  5 22:31:02 UTC 2019
New revision: 492274
URL: https://svnweb.freebsd.org/changeset/ports/492274

Log:
  databases/mongodb36: support arm64.aarch64

  - see
    https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!msg/mongodb-dev/cq4mL8WzMgA/soc3YVc_EQAJ
    for upstream discussion

  PR:		235057
  Submitted by:	Ronald Klop <ronald-lists@klop.ws>
  Reviewed by:	lwhsu, mikael.urankar@gmail.com
  Approved by:	dev@dudu.ro (maintainer)

Changes:
  head/databases/mongodb36/Makefile
  head/databases/mongodb36/files/aarch64/
  head/databases/mongodb36/files/aarch64/patch-src_third__party_IntelRDFPMathLib20U1_LIBRARY_src_bid__functions.h
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_SConscript
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src0.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src1.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src10.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src11.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src12.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src13.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src14.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src15.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src16.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src17.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src18.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src19.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src2.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src20.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src21.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src22.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src23.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src24.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src25.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src26.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src27.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src28.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src29.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src3.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src30.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src31.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src32.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src33.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src4.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src5.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src6.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src7.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src8.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_Unified__cpp__js__src9.cpp
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_build_js-confdefs.h
  head/databases/mongodb36/files/aarch64/patch-src_third__party_mozjs-45_platform_aarch64_freebsd_include_js-config.h