Summary: | [patch] lang/ocaml: respect CC | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | Ports & Packages | Reporter: | h h <aakuusta> | ||||||||
Component: | Individual Port(s) | Assignee: | Brendan Fabeny <bf> | ||||||||
Status: | Closed FIXED | ||||||||||
Severity: | Affects Only Me | ||||||||||
Priority: | Normal | ||||||||||
Version: | Latest | ||||||||||
Hardware: | Any | ||||||||||
OS: | Any | ||||||||||
Attachments: |
|
Description
h h
2011-09-05 21:10:01 UTC
Responsible Changed From-To: freebsd-ports-bugs->stas Over to maintainer (via the GNATS Auto Assign Tool) Responsible Changed From-To: stas->tabthorpe - back to the heap Responsible Changed From-To: tabthorpe->freebsd-ports-bugs Really give back to the heap Being the new maintainer of lang/ocaml, I recently received notification of this PR. Did you compile OCaml with something different that gcc? While OCaml should be compiled by any ANSI C compiler, examination of the ./configure script in source displays many gcc-specific behaviors. I would appreciate details you can supply there. BTW I think this fix belongs the upstream ./configure script, so I will submit a bug report or a patch on the OCaml bug tracking system. Responsible Changed From-To: freebsd-ports-bugs->bf I'll take it. http://www.freebsd.org/cgi/query-pr.cgi?pr=160492 Date: Sat, 17 Dec 2011 08:55:22 -0500 Dear Jan, Thank you for your patch. I tested your patch at home on amd64, it works fine and the ocaml compiler prepared with gcc=46 (your suggested test) succesfully does its job (until now!). I think we can have your patch in FreeBSD, I prepared an updated version that also bumps PORTREVISION. I also raised the issue upstream: http://caml.inria.fr/mantis/view.php?id=5418 Best, Michael When looking over this patch, I found a number of other problems that need to be fixed: -- There is no need to set USE_LDCONFIG=yes, because we don't expose versioned shared libraries in ${PREFIX}/lib to rtld for general use. -- After revision 1.54 of the port Makefile, it was intended that ocaml should use a threaded tcl/tk, and to this end, DEPENDS_ARGS sets WITH_THREADS. But this is risky, and it is not having the desired effect, partly because the ocaml configure script looks for the wrong libraries in the right directories. Remove it, and set USE_TK_THREADS instead when needed, while explicitly including the desired library names in CONFIGURE_ARGS. While here, remove the obsolete "-with-pthread" from CONFIGURE_ARGS, which is ignored by the ocaml configure script. Also, explicitly disallow tcl/tk 8.6, which causes the configure script to fail; and adjust the wish shebang line in an example script (we can't use PATCH_TK_SCRIPTS from bsd.tcl.mk for this because its replacements are not sufficiently general, and it interferes with post-patch). -- Through a logic error in the port Makefile, packages built WITHOUT_X11 were being conflated with those built merely WITHOUT_TK. Fix this by not overwriting SFX and CONFLICTS for the WITHOUT_X11 packages. -- Respect LDFLAGS when linking -- we may need to do this for LTO, stack protection, rpath arguments (like those in bsd.gcc.mk) that help the resulting binaries find the compiler shared libraries at runtime, etc. Adjust the flags so that they can used indirectly, with the compiler, and directly, with the linker. (The adjustment in the latter case is not foolproof, but should work for most reasonable choices of flags, and that is all we need.) -- remove the hard-coded libdl that causes failures when searching for libbfd from the configure script (our dlopen is in libc, as the computation of dllib should have already established -- this will enable compilers using devel/binutils, like lang/gcc4*, to use this functionality). -- use the proper toolchain elements in the configure script, instead of hard-coding "ar", "ld", and "ranlib". --expose the testsuite, so we can more easily determine if ocaml has problems -- do this in a way so that a single test failure won't cause "make -k check" to grind to a halt, or issue partial logs. --use dirrmtry for lib/ocaml in pkg-plist, instead of explicitly defining it in the Makefile If you agree, I will commit these changes. Regards, b. bf 2012-02-23 00:21:15 UTC FreeBSD ports repository Modified files: lang/ocaml Makefile pkg-plist Log: respect CC [1]; fix Tcl/Tk dependencies; don't conflate -nox11 and -notk; add a test target; clean up PR: 160492 [1] Submitted by: J. Beich (partial patch; under various pseudonyms?) [1] Approved by: maintainer Revision Changes Path 1.76 +35 -7 ports/lang/ocaml/Makefile 1.38 +1 -0 ports/lang/ocaml/pkg-plist _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org" State Changed From-To: open->closed Committed, with minor changes. Thanks! |