Bug 221894

Summary: [patch] adapt ports tree to new 'armv7' architecture
Product: Ports & Packages Reporter: Mark Linimon <linimon>
Component: Ports FrameworkAssignee: Port Management Team <portmgr>
Status: Closed FIXED    
Severity: Affects Many People CC: herbert, mikael, mmel, ports-bugs, sylvain
Priority: --- Keywords: patch
Version: LatestFlags: linimon: exp-run?
Hardware: Any   
OS: Any   
See Also: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221903
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221902
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221901
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221900
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221899
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221898
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221897
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221896
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221895
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221905
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221908
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221921
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221922
Attachments:
Description Flags
patch to the overall tree, including individual patches in referenced PRs
none
patch to the overall tree, including individual patches in referenced PRs
none
updated patch taking recent commits into account none

Description Mark Linimon freebsd_committer freebsd_triage 2017-08-29 12:00:45 UTC
The src tree is in the process of splitting the 32-bit arm bits into the existing 'armv6' and the new 'armv7'.  I am developing a patch to the entire tree to allow this.

The approach is to duplicate any special-case code for armv6 to armv7.  In most cases this will be, for example, NOT_FOR_ARCHS gaining an armv7 entry.  These will probably not need too much testing.

Other changes are more invasive.  In addition to the overall total patch I will soon attach to this PR, I will open separate PRs for various pieces of it for those types of changes, or changes that affect ports with many dependencies (devel/llvm*, lang/gcc*, lang/perl5*), and reference them here.

My suggestion is to have at least 2 exp-runs:

 - the first, on amd64, to prove "first, do no harm".  I am running tests here
   which I want to have pass before submitting the entire patch.

 - the second, with qemu and arch set to 'armv7'.  I expect this run will be
   at _least_ as good as the armv6 one; there may be certain ports which will
   actually build on armv7 and not on armv6.  Nevertheless, we have to check for
   regressions.

 - another would be with qemu/armv6, again, to prove no regressions.
Comment 1 Antoine Brodin freebsd_committer 2017-08-29 12:25:22 UTC
(In reply to Mark Linimon from comment #0)
We don't do exp-runs on qemu.
Comment 2 Mark Linimon freebsd_committer freebsd_triage 2017-08-29 12:33:02 UTC
(In reply to Antoine Brodin from comment #1)

IIUC you will be doing production runs on armv7 soon enough.  IMHO an -exp run would be a good way to get a running start.
Comment 3 Mark Linimon freebsd_committer freebsd_triage 2017-08-29 12:34:19 UTC
At some point a TRYBROKEN armv7 run should also be done.  The patches "assume" that anything broken on armv6 is also going to be broken on armv7.  As a first approximation that's probably true.  (It is also easier to remove a few uneccesary lines that try to add hundreds piecemeal.)
Comment 4 Mark Linimon freebsd_committer freebsd_triage 2017-08-29 13:11:02 UTC
Created attachment 185879 [details]
patch to the overall tree, including individual patches in referenced PRs
Comment 5 Mark Linimon freebsd_committer freebsd_triage 2017-08-29 20:37:36 UTC
Created attachment 185891 [details]
patch to the overall tree, including individual patches in referenced PRs
Comment 6 Mikael Urankar freebsd_committer 2017-08-30 07:40:19 UTC
We can remove the following comment in lang/go14, it was a qemu bug and it's fixed:
# NB: apparently this failure is only when running under emulation via
# qemu; it works fine on native hardware.  Let's leave the line in as a
# reminder, but commented out for now while this is being investigated.
#BROKEN_armv6=          Fails to configure: wait: interrupted system call
Comment 7 Mark Linimon freebsd_committer freebsd_triage 2017-08-30 20:23:00 UTC
Patch is currently being tested via

  poudriere +
  patched qemu script +
  https://reviews.freebsd.org/D12010 + 
  https://reviews.freebsd.org/D12027

which I expect to blow up any moment now.
Comment 8 Mark Linimon freebsd_committer freebsd_triage 2017-08-30 20:25:07 UTC
fwiw, the ports from 221895-221922 have now correctly built on amd64.  I have not tested the resulting packages for correctness, however; nor have I tested all the trivial ones not included in those patches.
Comment 9 Mark Linimon freebsd_committer freebsd_triage 2017-08-30 22:54:03 UTC
(In reply to Mark Linimon from comment #7)

===> usr.bin/svn/lib/libsvn_wc (installconfig)
[01:31:51] ====>> Starting make native-xtools with 8 jobs
make: make: don't know how to make native-xtools. Stop
Comment 10 Mark Linimon freebsd_committer freebsd_triage 2017-09-01 14:54:54 UTC
(In reply to Mark Linimon from comment #9)

I get the same buildworld failure on arm.armv6 and arm.armv7.  So I can't regression-test the patches on armvN for now.  Suggestions would be appreciated.
Comment 11 Mark Linimon freebsd_committer freebsd_triage 2017-09-01 15:04:02 UTC
Created attachment 185974 [details]
updated patch taking recent commits into account
Comment 12 Mikael Urankar freebsd_committer 2017-09-01 17:24:16 UTC
(In reply to Mark Linimon from comment #10)
This is what I've done to build a poudriere jail for armv7:

cd /usr/src
svn up
svn patch /root/D12010.diff


poudriere jails -c -j 12armv7 -v head -a arm.armv7 -m svn+http -x -P /root/D12010.diff
Comment 13 Sylvain Garrigues 2017-10-09 19:36:32 UTC
*** Bug 222882 has been marked as a duplicate of this bug. ***
Comment 14 commit-hook freebsd_committer 2017-10-10 21:32:08 UTC
A commit references this bug:

Author: linimon
Date: Tue Oct 10 21:31:35 UTC 2017
New revision: 451721
URL: https://svnweb.freebsd.org/changeset/ports/451721

Log:
  For ports that are explicitly enabled on armv6, also enable them
  on armv7.  This has not been tested with an -exp run but should
  "do no harm".

  PR:		221894 (partial)

Changes:
  head/audio/wavpack/Makefile
  head/audio/wavplay/Makefile
  head/comms/java-simple-serial-connector/Makefile
  head/databases/db48/Makefile
  head/databases/influxdb/Makefile
  head/databases/mysql55-server/Makefile
  head/databases/mysql56-server/Makefile
  head/databases/soci/Makefile
  head/devel/cld/Makefile
  head/devel/cxxtools/Makefile
  head/devel/gdb/Makefile
  head/devel/hwloc/Makefile
  head/devel/judy/Makefile
  head/games/scummvm/Makefile
  head/graphics/graphviz/Makefile
  head/graphics/libdrm/Makefile
  head/graphics/mesa-dri/Makefile
  head/graphics/opencv/Makefile
  head/java/bouncycastle15/Makefile
  head/lang/erlang/Makefile
  head/lang/erlang-runtime17/Makefile
  head/lang/erlang-runtime18/Makefile
  head/lang/erlang-runtime19/Makefile
  head/lang/erlang-runtime20/Makefile
  head/lang/go/Makefile
  head/lang/go14/Makefile
  head/lang/luajit/Makefile
  head/lang/mono/Makefile
  head/lang/swi-pl/Makefile
  head/math/lp_solve/Makefile
  head/multimedia/ffmpeg0/Makefile
  head/multimedia/mplayer/Makefile.options
  head/net/appkonference/Makefile
  head/net/yate/Makefile
  head/net-mgmt/kapacitor/Makefile
  head/science/openkim/Makefile
  head/security/cryptlib/Makefile
  head/security/py-cryptlib_py/Makefile
  head/sysutils/cloudabi-utils/Makefile
  head/sysutils/syslinux/Makefile
  head/sysutils/yum/Makefile
  head/www/node/Makefile
  head/www/node6/Makefile
  head/x11-wm/blackbox/Makefile
Comment 15 Michal Meloun freebsd_committer 2017-10-12 05:52:39 UTC
It seems that some of patches is missing in commit.
Mainly:
multimedia/ffmpeg
lang/ruby*
math/cln
net/freerdp

Can you, please, also commit these patches?
Thanks
Comment 16 Mark Linimon freebsd_committer freebsd_triage 2017-10-14 00:52:55 UTC
(In reply to Michal Meloun from comment #15)

This is the first of what will be a series of commits.  They were the easiest ones that did not take big risks with important packages.

I have been traveling for several weeks; I think the others will have to wait until I get back home.
Comment 17 Mark Linimon freebsd_committer freebsd_triage 2017-11-30 08:36:03 UTC
A greatly updated version of this patch has been committed.
Comment 18 Michal Meloun freebsd_committer 2017-12-05 08:26:06 UTC
*** Bug 223676 has been marked as a duplicate of this bug. ***