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

Pmetrics installation #247

Open
Amitkolhe21 opened this issue Dec 10, 2024 · 9 comments
Open

Pmetrics installation #247

Amitkolhe21 opened this issue Dec 10, 2024 · 9 comments

Comments

@Amitkolhe21
Copy link

I am trying to install Pmetrics but I am gettinh this error:
Warning message:
In i.p(...) :
installation of package ‘C:/Users/salma/AppData/Local/Temp/RtmpaIkrwB/file1d1c188f4ebf/Pmetrics_2.1.1.tar.gz’ had non-zero exit status
Can you help me?
@mnneely

@Siel
Copy link
Member

Siel commented Dec 10, 2024 via email

@Amitkolhe21
Copy link
Author

12 errors generated.
make: *** [knn.o] Error 1
ERROR: compilation failed for package ‘Pmetrics’

  • removing ‘/Library/Frameworks/R.framework/Versions/4.4-arm64/Resources/library/Pmetrics’
    Warning message:
    In i.p(...) :
    installation of package ‘/var/folders/hs/xv0d3xt94pn8ks3hxqgrm17m0000gn/T//RtmpzD2sbg/file36866f77ab63/Pmetrics_2.1.1.tar.gz’ had non-zero exit status

@Amitkolhe21
Copy link
Author

I've shared the whole error message, can you help me with that? @Siel

@Siel
Copy link
Member

Siel commented Dec 12, 2024 via email

@Amitkolhe21
Copy link
Author

FYI, I'm using Mac,

And I have C language installed on it
PFA, I've attached the screenshot for your reference.
Screenshot 2024-12-12 at 9 53 31 AM

@Siel
Copy link
Member

Siel commented Dec 12, 2024

I understand. Now the error you are seeing is related to the building process of one of pmetrics internal dependencies (knn.cpp) I suppose you also have a working cpp compiler. I think your error might be related to #215. It is a problem only affecting newer MacOS systems and the solution is at the end of that thread.

@Siel
Copy link
Member

Siel commented Dec 12, 2024

I was expecting the error to be more verbose. As you can see in the issue I linked, the final error is the same but the compilation process gives more information as it fails. By the way, when writing the Makevars file, make sure you point it to the right version of the c++ compiler on your system (I usually use gcc)

@Siel
Copy link
Member

Siel commented Dec 12, 2024

If that does not work I could point you to some specific branch of Pmetrics that does not use that dependency anymore.

@Amitkolhe21
Copy link
Author

Siel, I followed the steps from the the above solution #215, but still I'm facing issue in installing the Pmetrics,
Following the error I received, for your reference.

library("remotes")
remotes::install_github("LAPKB/Pmetrics")
Downloading GitHub repo LAPKB/Pmetrics@HEAD
Running R CMD build...

  • checking for file ‘/private/var/folders/hs/xv0d3xt94pn8ks3hxqgrm17m0000gn/T/RtmpEU8h6d/remotes16dd41289e9c/LAPKB-Pmetrics-ee1b703/DESCRIPTION’ ... OK
  • preparing ‘Pmetrics’:
  • checking DESCRIPTION meta-information ... OK
  • cleaning src
  • checking for LF line-endings in source and make files and shell scripts
  • checking for empty or unneeded directories
    Removed empty directory ‘Pmetrics/inst/Examples/Runs’
    Omitted ‘LazyData’ and ‘LazyDataCompression’ from DESCRIPTION
  • building ‘Pmetrics_2.1.1.tar.gz’
  • installing source package ‘Pmetrics’ ...
    ** using staged installation
    ** libs
    sh: g++-13: command not found
    using SDK: ‘’
    g++-13 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/opt/R/arm64/include -fPIC -falign-functions=64 -Wall -g -O2 -c knn.cpp -o knn.o
    /bin/sh: g++-13: command not found
    make: *** [knn.o] Error 127
    ERROR: compilation failed for package ‘Pmetrics’
  • removing ‘/Library/Frameworks/R.framework/Versions/4.4-arm64/Resources/library/Pmetrics’
    Warning messages:
    1: In missing_devel_warning(pkgdir) :
    Package Pmetrics has compiled code, but no suitable compiler(s) were found. Installation will likely fail.
    Install XCode and make sure it works.
    2: In i.p(...) :
    installation of package ‘/var/folders/hs/xv0d3xt94pn8ks3hxqgrm17m0000gn/T//RtmpEU8h6d/file16dd3247e718/Pmetrics_2.1.1.tar.gz’ had non-zero exit status

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

No branches or pull requests

2 participants