Skip to content

configure: UDUNITS2_LIB not fully considered during conftest procedure #16

Description

@neumannd

Hi,

I have an issue with respect to compiling the R udunits2 package when the udunits2 library is not installed to a default location. UDUNITS2_LIB seems not to be considered during some steps of the contest procedure.

This function call

install.packages('udunits2_0.13.tar.gz', configure.vars="UDUNITS2_INCLUDE=path_to_include UDUNITS2_LIB=path_to_lib")

leads to an error:

...
checking udunits2.h usability... yes
checking udunits2.h presence... yes
checking for udunits2.h... yes
checking for ut_read_xml in -ludunits2... no
-----Error: libudunits2.a not found-----
...

Instead

install.packages('udunits2_0.13.tar.gz', configure.vars="UDUNITS2_INCLUDE=path_to_include UDUNITS2_LIB=path_to_lib LIBS=-Lpath_to_lib")

solves the issue:

...
checking udunits2.h usability... yes
checking udunits2.h presence... yes
checking for udunits2.h... yes
checking for ut_read_xml in -ludunits2... yes
...

Thus, -L${UDUNITS2_LIB} seems not to be set properly or too late. The same issue occurs when I provide --with-udunits2-lib=....

My system:

  • R v3.3.3
  • xUbuntu 16.04

I had a brief look into the configure.ac and tried to find out the problem (and provide a pull request) but did not find it. Since the header files were found, UDUNITS2_INCLUDE seems to be used. Strange that UDUNITS2_LIB is not used properly.

edit:

  • I used the master branch of the Rudunits2 github repository
  • When I do the same with the udunits2_0.13.tar.gz file from Cran neither the headers nor the libraries are found ... .

Cheers,
Daniel

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions