|Summary:||2.7.10 beta2 with X/Motif binary no longer runs (address sanitizer)|
|Product:||XQuartz||Reporter:||Dušan Peterc <dusan.peterc>|
|Component:||Other||Assignee:||Jeremy Huddleston Sequoia <jeremyhu>|
|Status:||RESOLVED INVALID||QA Contact:||Jeremy Huddleston Sequoia <jeremyhu>|
|Version:||development (betas, rcs, git)|
|OS:||Mac OS X (All)|
|i915 platform:||i915 features:|
Description Dušan Peterc 2016-08-28 22:33:10 UTC
If i try to run an X/Motif binary, I get the following error: ==1135==AddressSanitizer CHECK failed: /opt/local/var/macports/build/_Users_jeremy_src_macports_trunk_dports_lang_llvm-3.8/clang-3.8/work/release_38/projects/compiler-rt/lib/asan/asan_globals.cc:147 "((AddrIsAlignedByGranularity(g->beg))) != (0)" (0x0, 0x0) Software used to work on the previous versions of XQuartz (2.7.9 and older) I don't have a simple source code test, but it can be reproduced by installing demo version of ArahWeave http://www.arahne.si/download/software-demo/62-download/installation-instructions/302-mac-os-x.html and running it from terminal as ./aw/aweave The binary is compiled for 32 bits.
Comment 1 Jeremy Huddleston Sequoia 2016-08-29 08:31:14 UTC
OpenMotif is broken. libXt.6.dylib was provided as a workaround to try and not break existing applications that rely on OpenMotif's broken behavior. I suggest you try and fix OpenMotif
Comment 2 Dušan Peterc 2016-08-29 10:37:28 UTC
Thank you for your reply. How it is OpenMotif broken? It has worked for many years on many platforms. If you can point me in the direction of the error, I can try to recompile motif and try to fix the error. OpenMotif is still maintained and I can try to push the changes upstream. I don't quite understand the remark regarding the libXt.6.dylib workaround. You mean it is no longer provided, and this now causes the problem to manifest itself? Isn't libXt.6.dylib part of XQuartz? Is it related to flat namespace problem? By the way - address sanitation in clang is supposed to slow down the program two times. This is only enabled in the beta version of XQuartz? There are many Motif based programs, and if XQuartz does not work with Motif, a good % of old Unix software will no longer run (DDD, Nedit, grace, xpdf, Siemens NX, XEphem, ...)
Comment 3 Jeremy Huddleston Sequoia 2016-08-30 05:20:14 UTC
See https://echelog.com/logs/browse/macports/1452121200 and do some other google searches for vendorShellClassRec and vendorShellWidgetClass. Also note that I fixed the issue in libXaw and libXaw3d (eg: https://lists.x.org/archives/xorg-devel/2016-January/048467.html), but OpenMotif looks like it needs a bit more massaging to fix properly. [08:24:00] <howarth> jeremyhu_, it appears that any package which links executables against motif needs to link the flat-namespace libXt [08:25:00] <howarth> so 'require_active_variants xorg-libXt flat_namespace' needs to be added to any port that depends on openmotif [08:25:24] <howarth> and builds executables (rather than shared libs) [08:25:58] <jeremyhu_> nope [08:27:01] <jeremyhu_> You just need it it the openmotif port because it will enforce the requirement for you. [08:27:08] <jeremyhu_> The bug is with openmotif. [08:28:30] <howarth> have they really tightened up the require_active_variants in MacPorts? [08:28:49] <howarth> my prior experiences with pymol was that it was rather loose in enforcement [08:29:27] <jeremyhu_> not sure what you mean by that. If someone tries to install openmotif and the libXt isn't +flat_namespace, the install will fail. [08:32:11] <howarth> require_active_variants tcl "" corefoundation [08:32:11] <howarth> require_active_variants tk "" quartz [08:32:38] <jeremyhu_> howarth: FWIW, you should spend your effort trying to fix openmotif instead. [08:32:41] <howarth> doesn't force the replacement of the existing tcl/tk ports that are installed when building pymol [08:32:59] <jeremyhu_> See http://pastebin.com/vdaq1gwD as a suggested starting point. It looks like it needs additional work though because nedit doesn't launch with it. [08:35:45] <jeremyhu_> howarth: A quick look through looks like there are a bunch of vendorShellClassRec references that I need to get pointed at _XmVendorShellClassRec instead.
Comment 4 Dušan Peterc 2016-08-30 21:58:19 UTC
Thank you very much, I will try to make this change to my own version of Motif to see if that will help. http://pastebin.com/vdaq1gwD If not, I will try to include my own copy of Xt with the application. Or we will go back to virtual machines. So sad, after all this effort, and it runs so well on Snow Leopard.
Comment 5 Jeremy Huddleston Sequoia 2016-08-31 02:07:42 UTC
You can continue to link against the libXt.6.dylib instead of the libXt.7.dylib until OpenMotif fixes the bug.
Comment 6 Dušan Peterc 2016-08-31 11:04:46 UTC
Thanks for the tip!