Menu

Error compile JAGS

runjags
2023-01-28
2023-05-29
  • syifaulkhusna

    syifaulkhusna - 2023-01-28

    Dear all, I try to add new modules into JAGS. When I compile it, there’s no error massage, but it doesn’t create any file .dll in sub-folder of modules , it’s only create file .a and .la .

    Do anyone know what happen?

    Thank you so much!

    -Syf.

     
  • syifaulkhusna

    syifaulkhusna - 2023-01-29

    I use JAGS 4.3.1 msys in Rtools4.2 . I already compile paretoprior modules but also doesn't create any file .dll

     
  • Matt Denwood

    Matt Denwood - 2023-02-03

    This is really a question for the JAGS forum (https://sourceforge.net/p/mcmc-jags/discussion/) as it doesn't seem to involve runjags. However, before you post there, I would include more information detailing exactly you have done so far - i.e. all the steps for how you are compiling, not just "when I compile it" - as well as a link to the source code you are trying to compile.

    In case you are not aware of it, there is also an article that explains how to create a module (https://psycnet.apa.org/record/2014-07832-002), although I personally find this very challenging to follow on Windows (although I am not a Windows user to be fair). However, it is much easier to create a JAGS module within an R package than as a standalone module - see https://github.com/ku-awdc/JAGSmodule for a (relatively) minimal example of how to do this (although the distribution implemented is flawed, the code works in principle). The major advantage of this is that a is platform-independent R source package can be created. The only disadvantage is that you are tied to the rjags interface (and dependent packages that use this, e.g. the rjags method of runjags).

     

    Last edit: Matt Denwood 2023-02-03
    • syifaulkhusna

      syifaulkhusna - 2023-05-29

      thankyou so much for your solution. My problem has been solved.
      This is my code before :
      CXX="g++ -m64" \
      ./configure LDFLAGS="-L/c/Progra~1/JAGS/JAGS-4.3.0/x64/bin"
      CXXFLAGS="-I/c/Progra~1/JAGS/JAGS-4.3.0/include"
      make win64-install

      And this is the solution code :
      CXX="g++ -m64" \
      ./configure --host=x86_64-w64-mingw32.static.posix LDFLAGS="-L/c/Progra~1/JAGS/JAGS-4.3.1/x64/bin" CXXFLAGS="-I/c/Progra~1/JAGS/JAGS-4.3.1/include"
      make win64-install

      After I run that code, it created the dll file

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.