Menu

#43 bugs module now links to libgfortran shared library

v1.0_(example)
open
None
1
2015-10-13
2015-10-12
No

Some modules e.g. glm, bugs use the libgfortran shared library in JAGS 4 on OS X. After running make, otool -L src/modules/bugs/.libs/bugs.so gives:

src/modules/bugs/.libs/bugs.so:
/System/Library/Frameworks/Accelerate.framework/Versions/A/Accelerate (compatibility version 1.0.0, current version 4.0.0)
/usr/local/lib/libjrmath.0.dylib (compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1197.1.1)
/usr/local/lib/libjags.4.dylib (compatibility version 5.0.0, current version 5.0.0)
/usr/local/lib/libgfortran.2.dylib (compatibility version 3.0.0, current version 3.0.0)
/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 120.0.0)

[The 2nd-last line does not appear in JAGS 3]

I am wondering if this addition is an (accidental?) by-product of the check facility rather than a change in the modules themselves? If so, could the build setup be modified to remove the dependency on this external library?

If not, this means that either:
1) The user needs to install gfortran
2) The Mac OS X installer needs to bundle the required elements of gfortran - gfortran 4.2.3 is listed as GPL-2 on CRAN so I guess this may be possible with due attribution...

Any thoughts?

Sorry that I missed this while building/testing the binary....

Discussion

  • Martyn Plummer

    Martyn Plummer - 2015-10-13

    Not your fault. As soon as you successfully built JAGS 4.0.0 and ran the tests I released it. We should include a period for binary testing in the beta period.

    Now, this change does not relate to the tests but is much older. It can be reverted without any penalty. If you check out branch release-4_patched you will find a candidate for JAGS 4.0.1, which has the same linkage as JAGS 3.4.0.

    There is one thing that confuses me. The glm module has actual Fortran code. This is was also the case in 3.4.0. So why doesn't this induce a dependency on libgfortran?

     
  • Martyn Plummer

    Martyn Plummer - 2015-10-13

    PS You may need to run autoreconf -fis in the source directory, and start with a clean build directory.

     
  • Matt Denwood

    Matt Denwood - 2015-10-13

    Thanks Martyn. I can confirm this passes make check, and that the resulting .so files show no dependency on libgfortran (and that JAGS loads fine when libgfortran is removed). I am currently creating a squeaky-clean install of OS X just to make absolutely sure ...

    Do you want to officially release this as JAGS 4.0.1 or shall I just update the OS X installer as there have been no other changes?

    As far as the glm module goes - there is a build dependency on gfortran (and always has been), but the built glm.so file doesn't use libgfortran.dylib so there is no need for gfortran to be installed at run time (I guess all of the fortran code must be compiled and bundled inside glm.so).

     
  • Martyn Plummer

    Martyn Plummer - 2015-10-13
     
  • Martyn Plummer

    Martyn Plummer - 2015-10-13

    That's great. I've tagged the current state of the jags-4_release branch as the 4.0.1 release.

    I think you should just update the Mac OS X installer. There's no point pushing a full release as this change makes no difference at all on other platforms.

     
  • Matt Denwood

    Matt Denwood - 2015-10-13

    That's built and on sourceforge now. I confirmed it ran on a clean system (with only JAGS and then with JAGS+R+rjags) so hopefully that should be it sorted.

    Could you close this ticket? I don't think I can do that from my account!

     

Anonymous
Anonymous

Add attachments
Cancel