Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

split r header to r_devel maybe is not a good idea #7750

Closed
armgong opened this issue Jan 8, 2023 · 11 comments
Closed

split r header to r_devel maybe is not a good idea #7750

armgong opened this issue Jan 8, 2023 · 11 comments

Comments

@armgong
Copy link

armgong commented Jan 8, 2023

split r header to r_devel Maybe is not good idea. Most r user will install r packages when using R, if package contains c or fortran code, the installation will failed if r_devel not installed. Could we include r header and lib to r pacakge?

@Begasus
Copy link
Contributor

Begasus commented Jan 8, 2023

It isn't that hard, had a talk about this with someone on IRC and he told me the headers are not really needed at runtime. Could you give an example for this?

@armgong
Copy link
Author

armgong commented Jan 8, 2023

just exmaple, after installed R(r_devel not installed ) in R console run

install.packages("curl")

this will failed , because curl package (https://github.com/jeroen/curl) contains c source code , which need R headers and libs to compile.
for exmaple in https://github.com/jeroen/curl/blob/master/src/init.c , which include several R header files.
btw, lots of R packages contain c/fortran codes, if no R header files ,these packages can't build and installed. Futhermore most R user will install quite a few packages when he/she use R, no R header and lib will make install packages not so handy.

@armgong armgong changed the title split r header to r_devel maybe split r header to r_devel maybe is not a good idea Jan 8, 2023
@armgong
Copy link
Author

armgong commented Jan 8, 2023

on debian linux , it indeed split R to base and base-dev, but debian also build lots of cran r package for user to installed.

apt-cache search "^r-.*" | sort

so on debian when user install an R package , he/she can choose install pre-build package use APT , instead of R install.packages() command.
but on haiku-os or haikuports, maybe we should not pre-build a lot of R package then use pkgman install r-*** , let user himself to build package use install.packages().

@OscarL
Copy link
Contributor

OscarL commented Jan 8, 2023

For what it's worth... For Python packages we do include libs and headers as part of the main packages, as pip needs them to install/build modules that have C code, for example.

If installing packages that need compiling is the usual modus operandi for R users, and unless including the libs/headers adds way too much size to the base package, IMO[*], they should be included.

Problem with things like install.packages("curl") might be the same as with Python's packages, thou... those source packages might need to be actually patched to work OK on Haiku (thus why we have some Python packages as .hpkg files), but that seems like a separate issue to me.

[*] in my unsolicited opinion, aka... just my 2 cents.

@armgong
Copy link
Author

armgong commented Jan 8, 2023

yeah , IMO when use R ,installing packages that need compiling usually unavoidable for R users.
for the curl package demo, it is just an example, just an example.
many frequently used packages , need header and libs to compile and install

@Begasus
Copy link
Contributor

Begasus commented Jan 8, 2023

OK, I'm still not against it, one point I'd like to make, you can rund SDL games on Haiku with all the work that has been done here (runtime dependencies), if you like to create something that relies on SDL you would need the headers that are stored in the devel package (as it has been for many years and still valid), it doesn't make much change to put all this in in "one" package only, but the idea is to have a runtime dependency and a build dependency ?

@armgong
Copy link
Author

armgong commented Jan 8, 2023

IMHO, SDL itself is a library(runtime and dev dependency ) ,people write application base on it . but R is data analysis tool for most user , install an R packages is extend R function like python package(haikuports have lots python-* packages,but none R packages), so it better no split. so haikuport will not need prebuild lots of r package like python?

@Begasus
Copy link
Contributor

Begasus commented Jan 8, 2023

Doing a local build atm with all included in one package, will give you a heads up when things are fine and ready to be merged, thanks on the feedback.

@Begasus
Copy link
Contributor

Begasus commented Jan 8, 2023

Should be fixed in #7755

Could you give a notice if that one is working for you? (build on 64bit buildmaster finished, 32bit about to finish, so you can update in a short while).

@armgong
Copy link
Author

armgong commented Jan 8, 2023

test on haiku-os 64bit, uninstall and re-install R , install.packages work smoothly , thank you very much.

@armgong armgong closed this as completed Jan 8, 2023
@Begasus
Copy link
Contributor

Begasus commented Jan 9, 2023

Fixed, please make a new issue if something else comes up. :) Thanks for the reports!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants