Bug 200102

Summary: lang/ocaml fails to build on armv6
Product: Ports & Packages Reporter: mikael.urankar
Component: Individual Port(s)Assignee: freebsd-ports-bugs mailing list <ports-bugs>
Status: Closed FIXED    
Severity: Affects Only Me CC: freebsd-arm, marino, michipili, sbruno
Priority: --- Flags: bugzilla: maintainer-feedback? (michipili)
Version: Latest   
Hardware: arm   
OS: Any   
URL: http://chips.ysv.freebsd.org/data/11armv6-default/2015-05-09_16h52m01s/logs/errors/ocaml-4.02.1.log
Attachments:
Description Flags
fix arm build
none
softvfp removal none

Description mikael.urankar 2015-05-10 15:04:34 UTC
Created attachment 156613 [details]
fix arm build

Hi,

The latest update broke the build on arm, the attached patch fixes that.

build log:
http://mikael.urankar.free.fr/FreeBSD/arm/build_logs/ocaml-4.02.1.log
Comment 1 Michael Grünewald 2015-05-10 15:11:47 UTC
Comment on attachment 156613 [details]
fix arm build

Thank you Mikael for your quick fix! As I cannot reach to an
ARM architecture to test it, I will not, but I am confident you
did this already.

As far as I (maintainer) am concerned, this patch can be merged.
Comment 2 mikael.urankar 2015-05-15 15:15:52 UTC
Created attachment 156801 [details]
softvfp removal

I think we can drop the mfpu=softvfp option in CONFIGURE_ARGS, it works fine without it.
build log:
http://mikael.urankar.free.fr/index.php?dir=arm/build_logs/&file=ocaml-4.02.1_softvfp_removal.log
Comment 3 John Marino freebsd_committer 2015-05-19 09:39:47 UTC
Is this PR still valid?  If so, do the patches still apply?  Can any obsolete patch be marked "obsolete" so they don't confused others?
Comment 4 mikael.urankar 2015-05-19 09:53:37 UTC
Yes this PR is still valid.
Comment 5 John Marino freebsd_committer 2015-05-19 09:55:44 UTC
It took 1 second of looking at the PR to realize that patch will not apply.
Comment 6 mikael.urankar 2015-05-19 12:39:00 UTC
Hi John,

As you can see, I've opened the PR the 2015-05-10 and you have updated lang/ocaml the 2015-05-13 (r386233). You're commit 'broke' my first patch and I've forgotten to update my ports tree before submitting the second one so I agree with you my patch doesn't apply now.
Comment 7 John Marino freebsd_committer 2015-05-19 12:42:25 UTC
but I did ask you if it still applied today.  You didn't answer that but rather the other part of the question, so you reasonably implied it did still apply.

In any case, the patch needs an update.  (or somebody needs to see the intent and do it manually as it is not hard to do that)
Comment 8 Sean Bruno freebsd_committer 2015-05-31 15:28:14 UTC
As of today, this does not build/package for armv6.

http://tasty.ysv.freebsd.org/data/11armv6-default/2015-05-30_00h44m22s/logs/errors/ocaml-4.02.1.log

=======================<phase: package        >============================
===>  Building package for ocaml-4.02.1
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/arg.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/array.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/arrayLabels.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/buffer.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/bytes.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/bytesLabels.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/callback.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/camlinternalFormat.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/camlinternalFormatBasics.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/camlinternalLazy.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/camlinternalMod.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/camlinternalOO.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/char.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/complex.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/digest.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/filename.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/format.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/gc.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/genlex.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/hashtbl.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/int32.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/int64.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/lazy.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/lexing.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/list.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/listLabels.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/map.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/marshal.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/moreLabels.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/nativeint.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/obj.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/oo.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/parsing.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/pervasives.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/printexc.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/printf.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/queue.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/random.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/scanf.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/set.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/sort.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/stack.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/stdLabels.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/stream.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/string.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/stringLabels.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/sys.p.cmx: No such file or directory
pkg-static: Unable to access file /wrkdirs/usr/ports/lang/ocaml/work/stage/usr/local/lib/ocaml/weak.p.cmx: No such file or directory
*** Error code 1

Stop.
make: stopped in /usr/ports/lang/ocaml
Comment 9 John Marino freebsd_committer 2015-05-31 17:39:47 UTC
Sean, it's not like you are telling us anything new.

I guess we were waiting for Mikael to submit a new patch and I guess he was expecting somebody just to fix his patch.

It's a quick fix so I guess I'll just do it, but telling us it's broken when that's already been established doesn't add much.
Comment 10 John Marino freebsd_committer 2015-05-31 17:45:22 UTC
AFAICT, Sean's report is different from Mikael's.  Even when I add Mikael's patch, chances are ARMv6 will still be broken.  If that's the case, a new PR is warranted.
Comment 11 commit-hook freebsd_committer 2015-05-31 17:49:04 UTC
A commit references this bug:

Author: marino
Date: Sun May 31 17:49:00 UTC 2015
New revision: 388125
URL: https://svnweb.freebsd.org/changeset/ports/388125

Log:
  lang/ocaml: Remove softvfp option from ARMv6 build (no longer required)

  PR:		200102
  Submitted by:	Mikael Urankar
  Approved by:	maintainer (assumed good, not able to test)

Changes:
  head/lang/ocaml/Makefile
Comment 12 John Marino freebsd_committer 2015-05-31 17:50:42 UTC
As I said, if ARMv6 is still broken then a dedicated PR needs to be open.  It's a different problem than the one originally reported by this PR.
Comment 13 Michael Grünewald 2015-05-31 19:20:59 UTC
I reviewed the patch and Seans's report, and I am confident that Sean's issue
should be solved by the patch – the problem being that *profiling* libraries
are not compiled on arm and Mikael's patch tells the plist about this.

Sean, can you test this with John's last commit?
Comment 14 Sean Bruno freebsd_committer 2015-05-31 20:31:07 UTC
(In reply to Michael Grünewald from comment #13)
confirmed!  Thanks for your help everyone!

===> No pkg-plist issues found (check-plist)
====>> Checking for staging violations... done
=======================<phase: package        >============================
===>  Building package for ocaml-4.02.1
===========================================================================
=======================<phase: install-mtree  >============================
===========================================================================
====>> Recording filesystem state for preinst... done
=======================<phase: install        >============================
===>  Installing for ocaml-4.02.1
===>   ocaml-4.02.1 depends on file: /usr/local/libdata/pkgconfig/x11.pc - found
===>  Checking if ocaml already installed
===>   Registering installation for ocaml-4.02.1
[11armv6-default] Installing ocaml-4.02.1...
===> SECURITY REPORT: 
      This port has installed the following files which may act as network
      servers and may therefore pose a remote security risk to the system.
/usr/local/bin/ocamlbuild.native
/usr/local/bin/ocamldoc.opt
/usr/local/lib/ocaml/unix.cmxs
/usr/local/lib/ocaml/stublibs/dllunix.so
/usr/local/bin/ocamlbuild

      If there are vulnerabilities in these programs there may be a security
      risk to the system. FreeBSD makes no guarantee about the security of
      ports included in the Ports Collection. Please type 'make deinstall'
      to deinstall the port if this is a concern.

      For more information, and contact details about the security
      status of this software, see the following webpage: 
http://caml.inria.fr/ocaml/
===========================================================================
====>> Checking shared library dependencies
 0x00000001 NEEDED               Shared library: [libX11.so.6]
 0x00000001 NEEDED               Shared library: [libc.so.7]
 0x00000001 NEEDED               Shared library: [libm.so.5]
 0x00000001 NEEDED               Shared library: [libncurses.so.8]
 0x00000001 NEEDED               Shared library: [libthr.so.3]
=======================<phase: deinstall      >============================
===>  Deinstalling for ocaml
===>   Deinstalling ocaml-4.02.1
Updating database digests format... done
Checking integrity... done (0 conflicting)
Deinstallation has been requested for the following 1 packages (of 0 packages in the universe):

Installed packages to be REMOVED:
        ocaml-4.02.1

The operation will free 69 MiB.
[11armv6-default] [1/1] Deinstalling ocaml-4.02.1...
[11armv6-default] [1/1] Deleting files for ocaml-4.02.1... done
===========================================================================
====>> Checking for extra files and directories
=======================<phase: Interactive    >============================
[00:49:12] ====>> Installing packages
[00:49:12] ====>> Installing run-depends for lang/ocaml
===>   ocaml-4.02.1 depends on file: /usr/local/libdata/pkgconfig/x11.pc - found
[00:49:13] ====>> Installing lang/ocaml
[11armv6-default] Installing ocaml-4.02.1...
[11armv6-default] Extracting ocaml-4.02.1: 100%
[00:49:23] ====>> Installing local Pkg repository to /usr/local/etc/pkg/repos