rwinlib / netcdf

2 stars 1 forks source link

RNetCDF broken on r-hub #2

Open mjwoods opened 5 years ago

mjwoods commented 5 years ago

I think the Windows toolchain on r-hub may have changed so that it is incompatible with the current version of rwinlib/netcdf.

I tested a version of RNetCDF that was found to work previously. Please see https://github.com/mjwoods/RNetCDF/pull/13.

The RNetCDF source code compiled successfully, but the linking step failed with errors like:

> common.o:common.c:(.text+0x2b3): undefined reference to `nc_inq_typeid'

I have confirmed that rwinlib/netcdf was downloaded successfully. I verified this by adding the following command to Makevars.win in RNetCDF:

nm ../windows/netcdf-4.4.1.1-dap/lib/i386/libnetcdf.a

The output included lines such as the following:

00000060 T _nc_inq_typeid

Note that the symbol shown above contains a leading underscore. In contrast, gcc is trying to link symbols without an underscore.

The same RNetCDF package builds correctly on https://win-builder.r-project.org.

Why are the toolchains so different on r-hub and win-builder? Is there anything we can do to ensure that rwinlib/netcdf works on both platforms?

mjwoods commented 5 years ago

In case you want to see further details, the full log output from the r-hub build is attached: RNetCDF_2.0-1_1817bc42.txt

jeroen commented 5 years ago

Can you include the full log to the build please?

mjwoods commented 5 years ago

I've attached the log in text format above for safe-keeping. Here are links to the html log and artifacts, which may disappear after a while:

https://builder.r-hub.io/status/RNetCDF_2.0-1.tar.gz-0b9ba6cc17cb7b4420a39f565d3cc46c

https://artifacts.r-hub.io/RNetCDF_2.0-1.tar.gz-0b9ba6cc17cb7b4420a39f565d3cc46c/