StoreyLab / lfa

logistic factor analysis
GNU General Public License v3.0
15 stars 8 forks source link

1.28.2: compile error #6

Closed starsareintherose closed 1 year ago

starsareintherose commented 1 year ago
* installing *source* package ‘lfa’ ...
** using staged installation
** libs
using C compiler: ‘gcc (GCC) 12.2.1 20230201’
gcc -I"/usr/include/R/" -DNDEBUG   -I/usr/local/include    -fpic  -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions         -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security         -fstack-clash-protection -fcf-protection -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects  -c fastmat.c -o fastmat.o
gcc -I"/usr/include/R/" -DNDEBUG   -I/usr/local/include    -fpic  -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions         -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security         -fstack-clash-protection -fcf-protection -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects  -c lfa-init.c -o lfa-init.o
gcc -I"/usr/include/R/" -DNDEBUG   -I/usr/local/include    -fpic  -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions         -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security         -fstack-clash-protection -fcf-protection -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects  -c lfa.c -o lfa.o
gcc -I"/usr/include/R/" -DNDEBUG   -I/usr/local/include    -fpic  -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions         -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security         -fstack-clash-protection -fcf-protection -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects  -c lreg.c -o lreg.o
In file included from /usr/include/R/R.h:78,
                 from lfa.h:4,
                 from fastmat.c:1:
fastmat.c: In function ‘mv’:
fastmat.c:22:14: error: too few arguments to function ‘dgemv_’
   22 |     F77_CALL(dgemv)(&tr,dimA,dimA+1,&alpha,A,dimA,v,&one,&zero,ret,&one);
      |              ^~~~~
/usr/include/R/R_ext/RS.h:77:25: note: in definition of macro ‘F77_CALL’
   77 | # define F77_CALL(x)    x ## _
      |                         ^
/usr/include/R/R_ext/BLAS.h:107:10: note: declared here
  107 | F77_NAME(dgemv)(const char *trans, const int *m, const int *n,
      |          ^~~~~
/usr/include/R/R_ext/RS.h:77:25: note: in definition of macro ‘F77_CALL’
   77 | # define F77_CALL(x)    x ## _
      |                         ^
/usr/include/R/R_ext/BLAS.h:107:1: note: in expansion of macro ‘F77_NAME’
  107 | F77_NAME(dgemv)(const char *trans, const int *m, const int *n,
      | ^~~~~~~~
fastmat.c: In function ‘tmv’:
fastmat.c:48:14: error: too few arguments to function ‘dgemv_’
   48 |     F77_CALL(dgemv)(&tr,dimA,dimA+1,&alpha,A,dimA,v,&one,&zero,ret,&one);
      |              ^~~~~
/usr/include/R/R_ext/RS.h:77:25: note: in definition of macro ‘F77_CALL’
   77 | # define F77_CALL(x)    x ## _
      |                         ^
/usr/include/R/R_ext/BLAS.h:107:10: note: declared here
  107 | F77_NAME(dgemv)(const char *trans, const int *m, const int *n,
      |          ^~~~~
/usr/include/R/R_ext/RS.h:77:25: note: in definition of macro ‘F77_CALL’
   77 | # define F77_CALL(x)    x ## _
      |                         ^
/usr/include/R/R_ext/BLAS.h:107:1: note: in expansion of macro ‘F77_NAME’
  107 | F77_NAME(dgemv)(const char *trans, const int *m, const int *n,
      | ^~~~~~~~
make: *** [/usr/lib64/R/etc/Makeconf:191: fastmat.o] Error 1
make: *** Waiting for unfinished jobs....
In file included from /usr/include/R/R.h:78,
                 from lfa.h:4,
                 from lreg.c:1:
lreg.c: In function ‘lreg’:
lreg.c:49:18: error: too few arguments to function ‘dgemv_’
   49 |         F77_CALL(dgemv)(&tr,dimX,dimX+1,&alpha,X,dimX,b,&ione,&zero,p,&ione);
      |                  ^~~~~
/usr/include/R/R_ext/RS.h:77:25: note: in definition of macro ‘F77_CALL’
   77 | # define F77_CALL(x)    x ## _
      |                         ^
/usr/include/R/R_ext/BLAS.h:107:10: note: declared here
  107 | F77_NAME(dgemv)(const char *trans, const int *m, const int *n,
      |          ^~~~~
/usr/include/R/R_ext/RS.h:77:25: note: in definition of macro ‘F77_CALL’
   77 | # define F77_CALL(x)    x ## _
      |                         ^
/usr/include/R/R_ext/BLAS.h:107:1: note: in expansion of macro ‘F77_NAME’
  107 | F77_NAME(dgemv)(const char *trans, const int *m, const int *n,
      | ^~~~~~~~
lreg.c:120:18: error: too few arguments to function ‘dgemv_’
  120 |         F77_CALL(dgemv)(&tr,dimX+1,dimX+1,&one,w,dimX+1,f,&ione,&one,b,&ione);
      |                  ^~~~~
/usr/include/R/R_ext/RS.h:77:25: note: in definition of macro ‘F77_CALL’
   77 | # define F77_CALL(x)    x ## _
      |                         ^
/usr/include/R/R_ext/BLAS.h:107:10: note: declared here
  107 | F77_NAME(dgemv)(const char *trans, const int *m, const int *n,
      |          ^~~~~
/usr/include/R/R_ext/RS.h:77:25: note: in definition of macro ‘F77_CALL’
   77 | # define F77_CALL(x)    x ## _
      |                         ^
/usr/include/R/R_ext/BLAS.h:107:1: note: in expansion of macro ‘F77_NAME’
  107 | F77_NAME(dgemv)(const char *trans, const int *m, const int *n,
      | ^~~~~~~~
make: *** [/usr/lib64/R/etc/Makeconf:191: lreg.o] Error 1
ERROR: compilation failed for package ‘lfa’
* removing ‘/build/r-lfa/src/lfa’
* restoring previous ‘/build/r-lfa/src/lfa’
alexviiia commented 1 year ago

Hi, if you are an lfa user, I can't tell which version of lfa you are installing, but I believe I have already fixed this issue on GitHub (it has not been propagated to Bioconductor, unfortunately). To test this, can you try installing the latest GitHub version?

# install.packages("devtools") # run if devtools is not already installed
devtools::install_github("StoreyLab/lfa")

If that works, then that's your workaround for now. Let me know!

I am trying to update the Bioconductor versions, but unfortunately it is unnecessarily complicated by various reasons. So I wouldn't hold my breath.

starsareintherose commented 1 year ago

@sukanka Could you confirm it via your workaround

sukanka commented 1 year ago

Hi, if you are an lfa user, I can't tell which version of lfa you are installing, but I believe I have already fixed this issue on GitHub (it has not been propagated to Bioconductor, unfortunately). To test this, can you try installing the latest GitHub version?

# install.packages("devtools") # run if devtools is not already installed
devtools::install_github("StoreyLab/lfa")

If that works, then that's your workaround for now. Let me know!

I am trying to update the Bioconductor versions, but unfortunately it is unnecessarily complicated by various reasons. So I wouldn't hold my breath.

Thanks for your advice, this error is fixed in https://github.com/StoreyLab/lfa/commit/8f3a885eaeabe6b7201d3542be27ab86a65c2a22