pkgload icon indicating copy to clipboard operation
pkgload copied to clipboard

Creating compilation DB does not work for some packages

Open rstub opened this issue 7 months ago • 0 comments

I have tried to enable creating the compilation DB for swephR. After

pkgload:::use_compilation_db()
devtools::load_all()

I get the message

Warning message:
Expected same number of compilation commands as object files
ℹ This is an internal error that was detected in the pkgload package.
  Please report it at https://github.com/r-lib/pkgload/issues with a reprex and the full backtrace.

To me it looks like pkgload only finds the source files in src but not those in src/libswe which are build via src/Makevars:

all: $(SHLIB)
$(SHLIB): libswe.a

LIBSWE = libswe/swedate.o libswe/swehouse.o libswe/swejpl.o libswe/swemmoon.o \
	 libswe/swemplan.o libswe/sweph.o \
	 libswe/swephlib.o libswe/swecl.o libswe/swehel.o
libswe.a: $(LIBSWE)
	$(AR) rcs libswe.a $(LIBSWE)

rstub avatar Jun 30 '24 10:06 rstub