NOTICE: This version of the NSF Unidata web site (archive.unidata.ucar.edu) is no longer being updated.
Current content can be found at unidata.ucar.edu.
To learn about what's going on, see About the Archive Site.
Dave, Thanks for offering to take a look at the logfile. I'm attaching it, along with the config.cache I used. The command used was: ./configure --disable-dap --disable-libxml2 CPPFLAGS="-I/home/root/WRF/include" LDFLAGS="-L/home/root/WRF/lib" --host=riscv64-linux-gnu --build=riscv64-linux-gnu --cache-file=config.cache 2>&1 | tee configure-net.out Alvaro ________________________________ From: Dave Allured - NOAA Affiliate <dave.allured@xxxxxxxx> Sent: Monday, May 26, 2025 2:03 PM To: Alvaro Fernandez <afernandez@xxxxxxxxxxxxxxx> Cc: netcdfgroup@xxxxxxxxxxxxxxxx <netcdfgroup@xxxxxxxxxxxxxxxx> Subject: Re: [netcdfgroup] Difficulty configuring NETCDF on Linux QEMU This is the first time you received an email from this sender (dave.allured@xxxxxxxx). Exercise caution when clicking links, opening attachments or taking further action, before validating its authenticity. > configure: error: cannot compute sizeof (size_t) There is a known generic problem in configure scripts. Internally they use a small C program for type checking. Sometimes that test program fails for some other reason, something like library not found; and the error message does not report the real problem. That is probably what is happening here. A careful examination of config.log may reveal the real problem. Feel free to post config.log as link or attachment, and I will take a look. Alternatively, try building netCDF with Cmake rather than configure. It uses completely different code for testing system features. On Mon, May 26, 2025 at 11:24 AM Alvaro Fernandez <afernandez@xxxxxxxxxxxxxxx<mailto:afernandez@xxxxxxxxxxxxxxx>> wrote: Hi, I'm trying to build NETCDF on (a QEMU emulation of) a RISC-V platform we're developing. I've successfully built other libraries (like HDF5, zlib, etc.) on this QEMU with gcc 14.2.0. However, I am having difficulty completing the configuration phase of the NETCDF build process. This machine will not be accessing the web or pulling down anything, so I disabled DAP and XML, and am not giving it curl. I started with this configure command: ./configure --disable-dap --disable-libxml2 CPPFLAGS="-I/home/root/WRF/include" LDFLAGS="-L/home/root/WRF/lib" 2>&1 | tee configure-net.out But I get errors like: checking size of size_t... configure: error: in '/home/root/repos/netcdf-c-4.9.3': configure: error: cannot compute sizeof (size_t) See 'config.log' for more details I reasoned that the configure script might be confused about the host or built targets, so I decided to be explicit. Below is the latest attempt. I added the cache file: root@qemuriscv64:~/repos/netcdf-c-4.9.3# cat config.cache ac_cv_sizeof_off_t=8 And then I ran: ./configure --disable-dap --disable-libxml2 CPPFLAGS="-I/home/root/WRF/include" LDFLAGS="-L/home/root/WRF/lib" --host=riscv64-linux-gnu --build=riscv64-linux-gnu --cache-file=config.cache 2>&1 | tee configure-net.out It fails with the same error. This error is detected in line 26715 of the configure script. I see from the comments that this test serves to guard against an error in the HP compiler. Is this still a useful test? I would suspect our toolchain usually, but it's built hdf5 and multiple other applications. Thanks in advance, Alvaro Fernandez, PhD Inspire Semi
Attachment:
config.cache
Description: config.cache
Attachment:
config.log
Description: config.log
Attachment:
configure-net.out
Description: configure-net.out
netcdfgroup
archives: