bgruening / conda_r_skeleton_helper

Cleaning up Conda r-packages
MIT License
47 stars 32 forks source link

Drop binary relocating code #36

Closed SylvainCorlay closed 3 years ago

SylvainCorlay commented 5 years ago

The recipes generated with this skeleton include a section in build.sh covering the case where it include pre-build binaries and performs a relocation to the installation prefix.

Given conda-forge's policy to not include pre-built libraries, maybe this should be dropped completely?

jdblischak commented 5 years ago

@SylvainCorlay I agree this is annoying. This helper script is quite crude (it just does string substitutions based on pattern matching). The code to handle pre-built binaries tends to also include if/else logic that would be cumbersome to handle using this line-by-line approach. Ideally there would be an argument to conda skeleton cran that would disable this unnecessary logic. Would you be interested in investigating the skeleton source code to determine if such an argument already exists or how difficult it would be to add one?

jdblischak commented 5 years ago

@SylvainCorlay Have you had a chance to look at this? I skimmed through the arguments. The current arguments --use-binaries-ver and --use-when-no-binary do not appear to provide a way to disable this behavior.

  --use-binaries-ver USE_BINARIES_VER
                        Repackage binaries from version provided by argument
                        instead of building from source. (default: None)
  --use-when-no-binary {src,old,src-old,old-src,error}
                        Sometimes binaries are not available at the correct
                        version for a given platform (macOS). You can use this
                        flag to specify what fallback to take, either
                        compiling from source or using an older binary or
                        trying one then the other. (default: src)

Thus I'd recommend opening an Issue at the conda-build repo to add an argument to disable the use of binary packages.

jdblischak commented 3 years ago

This was caused by a typo in the upstream conda skeleton cran template. It was fixed in https://github.com/conda/conda-build/commit/023fa6b9ae5013fef5991ea61d6c677202f01290

xref: https://github.com/conda/conda-build/pull/4143