| Anonymous | Login | Signup for a new account | 2013-05-20 18:19 CEST | ![]() |
| Main | My View | View Issues | Change Log | Roadmap |
| View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | |||||||
| 0004863 | OCaml | OCaml general | public | 2009-09-10 01:47 | 2012-05-07 16:06 | |||||||
| Reporter | mottl | |||||||||||
| Assigned To | doligez | |||||||||||
| Priority | normal | Severity | minor | Reproducibility | always | |||||||
| Status | resolved | Resolution | fixed | |||||||||
| Platform | OS | OS Version | ||||||||||
| Product Version | 3.11.1 | |||||||||||
| Target Version | Fixed in Version | 3.13.0+dev | ||||||||||
| Summary | 0004863: Bad architecture detection on Mac OS X 64bit | |||||||||||
| Description | Calling ocamlmklib on Mac OS X 64bit leads to a linker warning: ld: warning: -read_only_relocs cannot be used with x86_64 This seems to be due to the configure file in the OCaml distribution taking this branch: i[3456]86-*-darwin*) instead of this one: *-apple-darwin*) This, again, is a consequence of config.guess using "uname -p": the latter returns i386 even though the machine is clearly running on x86_64. It seems that using "uname -m" would work here, though I am not sure whether it would do so elsewhere. Without the "-read_only_relocs suppress" option, which is passed to the C-compiler, the warning will disappear. Here is the full verbose output of such an ocamlmklib invocation: ocamlmklib -verbose -L/sw/lib -o lacaml_stubs impl_c.o utils_c.o vec2_S_c.o vec2_D_c.o vec2_C_c.o vec2_Z_c.o mat4_S_c.o mat4_D_c.o mat4_C_c.o mat4_Z_c.o impl4_S_c.o impl4_D_c.o impl4_C_c.o impl4_Z_c.o impl2_S_c.o impl2_D_c.o impl2_C_c.o impl2_Z_c.o exp10.o -framework vecLib + gcc-4.2 -m64 -bundle -flat_namespace -undefined suppress -read_only_relocs suppress -o ./dlllacaml_stubs.so exp10.o impl2_Z_c.o impl2_C_c.o impl2_D_c.o impl2_S_c.o impl4_Z_c.o impl4_C_c.o impl4_D_c.o impl4_S_c.o mat4_Z_c.o mat4_C_c.o mat4_D_c.o mat4_S_c.o vec2_Z_c.o vec2_C_c.o vec2_D_c.o vec2_S_c.o utils_c.o impl_c.o -L/Users/mmottl/local/godi/lib -L/sw/lib -framework vecLib ld: warning: -read_only_relocs cannot be used with x86_64 + ar rc ./liblacaml_stubs.a exp10.o impl2_Z_c.o impl2_C_c.o impl2_D_c.o impl2_S_c.o impl4_Z_c.o impl4_C_c.o impl4_D_c.o impl4_S_c.o mat4_Z_c.o mat4_C_c.o mat4_D_c.o mat4_S_c.o vec2_Z_c.o vec2_C_c.o vec2_D_c.o vec2_S_c.o utils_c.o impl_c.o; ranlib ./liblacaml_stubs.a | |||||||||||
| Tags | No tags attached. | |||||||||||
| Attached Files | ||||||||||||
Relationships |
||||||
|
||||||
Notes |
|
|
(0005742) Ashish_Agarwal (reporter) 2010-12-15 21:26 |
This issue appears to have been fixed in OCaml 3.12. The problem persists in 3.11, but note the suggestion of using uname -m does not work for me; it also returns i386. $ uname -a Darwin Ashish.local 10.5.0 Darwin Kernel Version 10.5.0: Fri Nov 5 23:20:39 PDT 2010; root:xnu-1504.9.17~1/RELEASE_I386 i386 $ uname -p i386 $ uname -m i386 |
|
(0005905) doligez (manager) 2011-05-17 16:59 |
This problem disappeared because Apple's latest linkers don't support -read-only-relocs, so we had to stop using it. |
|
(0006054) mottl (reporter) 2011-07-22 05:06 |
It seems this problem is present (again?) in OCaml 3.12.1: /Users/mmottl/local/godi312//bin/ocamlmklib -o lib/bin_prot lib/common_stubs.o lib/write_stubs.o lib/read_stubs.o ld: warning: -read_only_relocs cannot be used with x86_64 |
|
(0006077) doligez (manager) 2011-08-03 17:43 |
Markus, are you using Mac OS 10.7 (Lion) ? It is not detected correctly by the configure script of 3.12.1. I'm attaching a (untested) patch to make it work with Lion. |
|
(0006081) mottl (reporter) 2011-08-03 20:11 |
Damien, yes, I'm using Lion. I unfortunately cannot easily test that the error above went away with the patch, but it at least seems that the architecture is recognized correctly now by configure. The patch will probably work. |
|
(0006122) xclerc (developer) 2011-09-12 13:35 |
The proposed patch works for me on Lion with a Core 2 Duo. |
|
(0006240) protz (manager) 2011-12-12 15:04 |
As far as I can tell, svn revision 11163 « configure correctly under Mac OS 10.7 Lion (darwin11) » (by Damien) fixes the issue, closing. |
Issue History |
|||
| Date Modified | Username | Field | Change |
| 2009-09-10 01:47 | mottl | New Issue | |
| 2010-12-15 21:26 | Ashish_Agarwal | Note Added: 0005742 | |
| 2011-05-17 16:59 | doligez | Note Added: 0005905 | |
| 2011-05-17 16:59 | doligez | Status | new => closed |
| 2011-05-17 16:59 | doligez | Resolution | open => fixed |
| 2011-05-17 16:59 | doligez | Fixed in Version | => 3.12.0 |
| 2011-07-22 05:06 | mottl | Note Added: 0006054 | |
| 2011-07-22 05:06 | mottl | Status | closed => feedback |
| 2011-07-22 05:06 | mottl | Resolution | fixed => reopened |
| 2011-08-03 17:41 | doligez | File Added: ocaml-3.12.1-macos-10.7.patch | |
| 2011-08-03 17:43 | doligez | Note Added: 0006077 | |
| 2011-08-03 20:11 | mottl | Note Added: 0006081 | |
| 2011-09-12 13:35 | xclerc | Note Added: 0006122 | |
| 2011-10-20 12:45 | xclerc | Relationship added | has duplicate 0005379 |
| 2011-12-12 15:04 | protz | Note Added: 0006240 | |
| 2011-12-12 15:04 | protz | Status | feedback => resolved |
| 2011-12-12 15:04 | protz | Fixed in Version | 3.12.0 => 3.13.0+dev |
| 2011-12-12 15:04 | protz | Resolution | reopened => fixed |
| 2011-12-12 15:04 | protz | Assigned To | => doligez |
| Copyright © 2000 - 2011 MantisBT Group |