sf icon indicating copy to clipboard operation
sf copied to clipboard

R CMD check rgdal_1.5-27.tar.gz --no-manual --no-examples failed when test [email protected] on centos8_aarch64

Open Tom-python0121 opened this issue 3 years ago • 2 comments

Hello,I meet a problem:R CMD check rgdal_1.5-27.tar.gz --no-manual --no-examples failed when test [email protected] on centos8_aarch64

Steps to reproduce the issue

[root@localhost spack-stage-r-rgdal-1.5-27-3msh35x3szpwfl4oh7z4ciwo3blxatal]# R CMD check rgdal_1.5-27.tar.gz --no-manual --no-examples
* using log directory ‘/home/all_spack_env/spack_stage/root/spack-stage-r-rgdal-1.5-27-3msh35x3szpwfl4oh7z4ciwo3blxatal/rgdal.Rcheck’
* using R version 4.0.4 (2021-02-15)
* using platform: aarch64-unknown-linux-gnu (64-bit)
* using session charset: UTF-8
* using options ‘--no-examples --no-manual’
* checking for file ‘rgdal/DESCRIPTION’ ... OK
* this is package ‘rgdal’ version ‘1.5-27’
* checking package namespace information ... OK
* checking package dependencies ...Warning: unable to access index for repository https://CRAN.R-project.org/src/contrib:
  Line starting '<!DOCTYPE html ...' is malformed!
 OK
* checking if this is a source package ... OK
* checking if there is a namespace ... OK
* checking for executable files ... OK
* checking for hidden files and directories ... OK
* checking for portable file names ... OK
* checking for sufficient/correct file permissions ... OK
* checking whether package ‘rgdal’ can be installed ... OK
* checking installed package size ... NOTE
  installed size is  8.6Mb
  sub-directories of 1Mb or more:
    doc        3.4Mb
    pictures   1.3Mb
* checking package directory ... OK
* checking ‘build’ directory ... OK
* checking DESCRIPTION meta-information ... OK
* checking top-level files ... OK
* checking for left-over files ... OK
* checking index information ... OK
* checking package subdirectories ... OK
* checking R files for non-ASCII characters ... OK
* checking R files for syntax errors ... OK
* checking whether the package can be loaded ... OK
* checking whether the package can be loaded with stated dependencies ... OK
* checking whether the package can be unloaded cleanly ... OK
* checking whether the namespace can be loaded with stated dependencies ... OK
* checking whether the namespace can be unloaded cleanly ... OK
* checking loading without being on the library search path ... OK
* checking dependencies in R code ... OK
* checking S3 generic/method consistency ... OK
* checking replacement functions ... OK
* checking foreign function calls ... OK
* checking R code for possible problems ... OK
* checking Rd files ... OK
* checking Rd metadata ... OK
* checking Rd cross-references ... OK
* checking for missing documentation entries ... OK
* checking for code/documentation mismatches ... OK
* checking Rd \usage sections ... OK
* checking Rd contents ... OK
* checking for unstated dependencies in examples ... OK
* checking contents of ‘data’ directory ... OK
* checking data for non-ASCII characters ... OK
* checking data for ASCII and uncompressed saves ... OK
* checking line endings in shell scripts ... OK
* checking line endings in C/C++/Fortran sources/headers ... OK
* checking line endings in Makefiles ... OK
* checking compilation flags in Makevars ... OK
* checking for GNU extensions in Makefiles ... OK
* checking for portable use of $(BLAS_LIBS) and $(LAPACK_LIBS) ... OK
* checking use of PKG_*FLAGS in Makefiles ... OK
* checking compiled code ... OK
* checking installed files from ‘inst/doc’ ... OK
* checking files in ‘vignettes’ ... OK
* checking examples ... SKIPPED
* checking for unstated dependencies in ‘tests’ ... OK
* checking tests ...
  Running ‘srs_rendering.R’
 ERROR
Running the tests in ‘tests/srs_rendering.R’ failed.
Last 13 lines of output:
  > (o <- OGRSpatialRef(d, "cities"))
  [1] "+proj=longlat +datum=WGS84 +no_defs"
  > if (new_proj_and_gdal()) comment(o)
  [1] "GEOGCRS[\"WGS 84\",\n    DATUM[\"World Geodetic System 1984\",\n        ELLIPSOID[\"WGS 84\",6378137,298.257223563,\n            LENGTHUNIT[\"metre\",1]]],\n    PRIMEM[\"Greenwich\",0,\n        ANGLEUNIT[\"degree\",0.0174532925199433]],\n    CS[ellipsoidal,2],\n        AXIS[\"latitude\",north,\n            ORDER[1],\n            ANGLEUNIT[\"degree\",0.0174532925199433]],\n        AXIS[\"longitude\",east,\n            ORDER[2],\n            ANGLEUNIT[\"degree\",0.0174532925199433]],\n    ID[\"EPSG\",4326]]"
  > (o <- OGRSpatialRef(d, "scot_BNG"))
  [1] "+proj=tmerc +lat_0=49 +lon_0=-2 +k=0.9996012717 +x_0=400000 +y_0=-100000 +ellps=airy +units=m +no_defs"
  Warning message:
  In OGRSpatialRef(d, "scot_BNG") :
    Discarded datum OSGB_1936 in Proj4 definition: +proj=tmerc +lat_0=49 +lon_0=-2 +k=0.9996012717 +x_0=400000 +y_0=-100000 +ellps=airy +units=m +no_defs
  > if (new_proj_and_gdal()) comment(o)
  [1] "PROJCRS[\"OSGB 1936 / British National Grid\",\n    BASEGEOGCRS[\"OSGB 1936\",\n        DATUM[\"OSGB 1936\",\n            ELLIPSOID[\"Airy 1830\",6377563.396,299.3249646,\n                LENGTHUNIT[\"metre\",1]]],\n        PRIMEM[\"Greenwich\",0,\n            ANGLEUNIT[\"degree\",0.0174532925199433]],\n        ID[\"EPSG\",4277]],\n    CONVERSION[\"British National Grid\",\n        METHOD[\"Transverse Mercator\",\n            ID[\"EPSG\",9807]],\n        PARAMETER[\"Latitude of natural origin\",49,\n            ANGLEUNIT[\"degree\",0.0174532925199433],\n            ID[\"EPSG\",8801]],\n        PARAMETER[\"Longitude of natural origin\",-2,\n            ANGLEUNIT[\"degree\",0.0174532925199433],\n            ID[\"EPSG\",8802]],\n        PARAMETER[\"Scale factor at natural origin\",0.9996012717,\n            SCALEUNIT[\"unity\",1],\n            ID[\"EPSG\",8805]],\n        PARAMETER[\"False easting\",400000,\n            LENGTHUNIT[\"metre\",1],\n            ID[\"EPSG\",8806]],\n        PARAMETER[\"False northing\",-100000,\n            LENGTHUNIT[\"metre\",1],\n            ID[\"EPSG\",8807]]],\n    CS[Cartesian,2],\n        AXIS[\"(E)\",east,\n            ORDER[1],\n            LENGTHUNIT[\"metre\",1]],\n        AXIS[\"(N)\",north,\n            ORDER[2],\n            LENGTHUNIT[\"metre\",1]],\n    USAGE[\n        SCOPE[\"Engineering survey, topographic mapping.\"],\n        AREA[\"United Kingdom (UK) - offshore to boundary of UKCS within 49°45'N to 61°N and 9°W to 2°E; onshore Great Britain (England, Wales and Scotland). Isle of Man onshore.\"],\n        BBOX[49.75,-9,61.01,2.01]],\n    ID[\"EPSG\",27700]]"
  > (o <- OGRSpatialRef(file.path(d, "airports.gml"), "airports"))
  Error in ogrListLayers(dsn) : Cannot open data source
  Calls: OGRSpatialRef -> ogrListLayers
  Execution halted
* checking for unstated dependencies in vignettes ... OK
* checking package vignettes in ‘inst/doc’ ... OK
* checking running R code from vignettes ...
  ‘CRS_projections_transformations.Rmd’ using ‘UTF-8’... OK
  ‘PROJ6_GDAL3.Rmd’ using ‘UTF-8’... OK
  ‘OGR_shape_encoding.Rnw’ using ‘UTF-8’... OK
 OK
* checking re-building of vignette outputs ... NOTE
Error(s) in re-building vignettes:
--- re-building ‘CRS_projections_transformations.Rmd’ using rmarkdown
Pandoc is required to build R Markdown vignettes but not available. Please make sure it is installed.
Quitting from lines 24-30 (CRS_projections_transformations.Rmd)
Error: processing vignette 'CRS_projections_transformations.Rmd' failed with diagnostics:
svg: Cairo-based devices are not available for this platform
--- failed re-building ‘CRS_projections_transformations.Rmd’

--- re-building ‘PROJ6_GDAL3.Rmd’ using rmarkdown
Pandoc is required to build R Markdown vignettes but not available. Please make sure it is installed.
Quitting from lines 90-92 (PROJ6_GDAL3.Rmd)
Error: processing vignette 'PROJ6_GDAL3.Rmd' failed with diagnostics:
svg: Cairo-based devices are not available for this platform
--- failed re-building ‘PROJ6_GDAL3.Rmd’

--- re-building ‘OGR_shape_encoding.Rnw’ using Sweave
Loading required package: sp
Please note that rgdal will be retired by the end of 2023,
plan transition to sf/stars/terra functions using GDAL and PROJ
at your earliest convenience.

rgdal: version: 1.5-27, (SVN revision 1148)
Geospatial Data Abstraction Library extensions to R successfully loaded
Loaded GDAL runtime: GDAL 3.2.1, released 2020/12/29
Path to GDAL shared files: /home/all_spack_env/spack/opt/spack/linux-centos8-aarch64/gcc-8.4.1/gdal-3.2.1-bpuaa7yhadk2daa4w2lr43npxha7fm3u/share/gdal
GDAL binary built with GEOS: FALSE
Loaded PROJ runtime: Rel. 7.2.1, January 1st, 2021, [PJ_VERSION: 721]
Path to PROJ shared files: /root/.local/share/proj:/home/all_spack_env/spack/opt/spack/linux-centos8-aarch64/gcc-8.4.1/proj-7.2.1-gyd3gugg5lpj4javtlm4aijglg3f7unc/share/proj:/home/all_spack_env/spack/opt/spack/linux-centos8-aarch64/gcc-8.4.1/proj-7.2.1-gyd3gugg5lpj4javtlm4aijglg3f7unc/share/proj
PROJ CDN enabled: FALSE
Linking to sp version:1.4-5
To mute warnings of possible GDAL/OSR exportToProj4() degradation,
use options("rgdal_show_exportToProj4_warnings"="none") before loading sp or rgdal.
Read 1 item
--- finished re-building ‘OGR_shape_encoding.Rnw’

SUMMARY: processing the following files failed:
  ‘CRS_projections_transformations.Rmd’ ‘PROJ6_GDAL3.Rmd’

Error: Vignette re-building failed.
Execution halted

* DONE

Status: 1 ERROR, 2 NOTEs
See
  ‘/home/all_spack_env/spack_stage/root/spack-stage-r-rgdal-1.5-27-3msh35x3szpwfl4oh7z4ciwo3blxatal/rgdal.Rcheck/00check.log’
for details.

How can I fix it?

Tom-python0121 avatar Nov 05 '21 10:11 Tom-python0121

Centos on Arm is your choice. There is no way for anyone to reproduce this. It looks as though your GDAL build does not have the GML driver (the attempt to read a GML file fails) - to check, install rgdal and run ogrDrivers(). If there is no GML, rebuild GDAL with xerces-c and expat present, and check again. You may also check GDAL drivers with ogrinfo --formats from the command line.

rsbivand avatar Nov 05 '21 10:11 rsbivand

@rsbivand I will try it

Tom-python0121 avatar Nov 05 '21 10:11 Tom-python0121