conda-forge / perl-feedstock

A conda-smithy repository for perl.
BSD 3-Clause "New" or "Revised" License
3 stars 32 forks source link

perl: error while loading shared libraries: libcrypt.so.1 #37

Closed jfallmann closed 5 years ago

jfallmann commented 5 years ago

Issue: Freshly installed conda, created fresh env for perl, when trying to run perl this error pops up: perl: error while loading shared libraries: libcrypt.so.1: cannot open shared object file: No such file or directory
Environment (conda list):

``` $ conda list Name Version Build Channel _libgcc_mutex 0.1 main libgcc-ng 9.1.0 hdf63c60_0 libstdcxx-ng 9.1.0 hdf63c60_0 perl 5.26.2 h516909a_1006 conda-forge perl-app-cpanminus 1.7044 pl526_1 bioconda perl-autoloader 5.74 pl526_2 bioconda perl-capture-tiny 0.48 pl526_0 bioconda perl-carp 1.38 pl526_3 bioconda perl-constant 1.33 pl526_1 bioconda perl-data-dumper 2.173 pl526_0 bioconda perl-dbi 1.642 pl526_0 bioconda perl-dynaloader 1.25 pl526_1 bioconda perl-encode 2.88 pl526_1 bioconda perl-exporter 5.72 pl526_1 bioconda perl-extutils-cppguess 0.12 pl526h6bb024c_3 bioconda perl-extutils-makemaker 7.36 pl526_1 bioconda perl-file-find 1.27 pl526_1 bioconda perl-file-path 2.16 pl526_0 bioconda perl-file-slurp 9999.27 pl526_0 bioconda perl-file-spec 3.48_01 pl526_1 bioconda perl-file-temp 0.2304 pl526_2 bioconda perl-findbin-real 1.05 pl526h1341992_0 bioconda perl-getopt-long 2.50 pl526_1 bioconda perl-ipc-cmd 1.02 pl526_0 bioconda perl-list-util 1.38 pl526_1 bioconda perl-locale-maketext-simple 0.21 pl526_2 bioconda perl-math-cdf 0.1 pl526h14c3975_5 bioconda perl-math-round 0.07 pl526_1 bioconda perl-module-corelist 5.20190524 pl526_0 bioconda perl-module-load 0.32 pl526_1 bioconda perl-module-load-conditional 0.68 pl526_2 bioconda perl-module-metadata 1.000036 pl526_0 bioconda perl-params-check 0.38 pl526_1 bioconda perl-parent 0.236 pl526_1 bioconda perl-path-class 0.37 pl526_1 bioconda perl-perl-ostype 1.010 pl526_1 bioconda perl-perlio-gzip 0.20 pl526h84994c4_1 bioconda perl-pod-escapes 1.07 pl526_1 bioconda perl-pod-simple 3.35 pl526_1 bioconda perl-pod-usage 1.69 pl526_1 bioconda perl-posix 1.38_03 pl526_1 bioconda perl-set-intervaltree 0.11 pl526_1 bioconda perl-socket 2.027 pl526_1 bioconda perl-symbol 1.07 pl526_1 bioconda perl-test 1.26 pl526_1 bioconda perl-test-harness 3.42 pl526_0 bioconda perl-tie-hash 1.05 pl526_1 bioconda perl-tie-hash-indexed 0.05 pl526_1 bioconda perl-time-hires 1.9760 pl526h14c3975_1 bioconda perl-version 0.9924 pl526_0 bioconda perl-xsloader 0.24 pl526_0 bioconda zlib 1.2.11 h516909a_1005 conda-forge ```


Details about conda and system ( conda info ):

``` $ conda info active environment : perl active env location : /home/fall/anaconda3/envs/perl shell level : 2 user config file : /home/fall/.condarc populated config files : /home/fall/.condarc conda version : 4.7.5 conda-build version : 3.18.7 python version : 3.7.3.final.0 virtual packages : base environment : /home/fall/anaconda3 (writable) channel URLs : https://conda.anaconda.org/conda-forge/linux-64 https://conda.anaconda.org/conda-forge/noarch https://conda.anaconda.org/bioconda/linux-64 https://conda.anaconda.org/bioconda/noarch https://repo.anaconda.com/pkgs/main/linux-64 https://repo.anaconda.com/pkgs/main/noarch https://repo.anaconda.com/pkgs/r/linux-64 https://repo.anaconda.com/pkgs/r/noarch https://conda.anaconda.org/r/linux-64 https://conda.anaconda.org/r/noarch package cache : /home/fall/anaconda3/pkgs /home/fall/.conda/pkgs envs directories : /home/fall/anaconda3/envs /home/fall/.conda/envs platform : linux-64 user-agent : conda/4.7.5 requests/2.22.0 CPython/3.7.3 Linux/5.1.17-300.fc30.x86_64 fedora/30 glibc/2.29 UID:GID : 1000:1000 netrc file : None offline mode : False ```


Details about .condarc:

``` channel_priority: strict channels: - conda-forge - bioconda - defaults - r ```
scopatz commented 5 years ago

It seems like some package needs libcrypt but does not have it as a run dep. Most of these come from bioconda and so our outside our control :frowning_face:

jfallmann commented 5 years ago

@scopatz Thx for having a look! But conda list returns: perl 5.26.2 h516909a_1006 conda-forge and a simple perl --version leads to perl: error while loading shared libraries: libcrypt.so.1: cannot open shared object file: No such file or directory I guess no bioconda package is required for this?

I just created a completely empty env, just installing perl:

conda create -n testperl perl                                                                                                                                                                                         snekke
Collecting package metadata (current_repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /home/fall/anaconda3/envs/testperl

  added / updated specs:
    - perl

The following NEW packages will be INSTALLED:

  _libgcc_mutex      pkgs/main/linux-64::_libgcc_mutex-0.1-main
  libgcc-ng          pkgs/main/linux-64::libgcc-ng-9.1.0-hdf63c60_0
  perl               conda-forge/linux-64::perl-5.26.2-h516909a_1006

which contains according to conda list:

conda list                                                                                                                                                                                                 snekke
# packages in environment at /home/fall/anaconda3/envs/testperl:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main  
libgcc-ng                 9.1.0                hdf63c60_0  
perl                      5.26.2            h516909a_1006    conda-forge

and still activating and calling perl -v leads to the same error

bgruening commented 5 years ago

@jfallmann can you reproduce this with a minimal perl environment?

jfallmann commented 5 years ago

@bgruening sorry, was too slow editing

scopatz commented 5 years ago

This does not happen on Linux for me:

scopatz@artemis ~ $ conda create -n testperl perl                                        
Collecting package metadata (repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /home/scopatz/miniconda/envs/testperl

  added / updated specs:
    - perl

The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    _libgcc_mutex-0.1          |             main           3 KB
    ------------------------------------------------------------
                                           Total:           3 KB

The following NEW packages will be INSTALLED:

  _libgcc_mutex      pkgs/main/linux-64::_libgcc_mutex-0.1-main
  libgcc-ng          pkgs/main/linux-64::libgcc-ng-9.1.0-hdf63c60_0
  perl               conda-forge/--blacklist=abi,--max-build-no/linux-64::perl-5.26.2-h516909a_1006

Downloading and Extracting Packages
_libgcc_mutex-0.1    | 3 KB      | ############################################## | 100% 
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
#
# To activate this environment, use
#
#     $ conda activate testperl
#
# To deactivate an active environment, use
#
#     $ conda deactivate

scopatz@artemis ~ $  conda activate testperl                                             
(testperl) scopatz@artemis ~ $ which perl                                                
/home/scopatz/miniconda/envs/testperl/bin/perl
(testperl) scopatz@artemis ~ $ perl -v                                                   

This is perl 5, version 26, subversion 2 (v5.26.2) built for x86_64-linux-thread-multi

Copyright 1987-2018, Larry Wall

Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.

Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl".  If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.

(testperl) scopatz@artemis ~ $  
bgruening commented 5 years ago

Also working for me:

bag@bag:~/projects/code/staged-recipes$ conda create -n testperl perl 
Collecting package metadata: done
Solving environment: done

==> WARNING: A newer version of conda exists. <==
  current version: 4.6.7
  latest version: 4.7.5

Please update conda by running

    $ conda update -n base conda

## Package Plan ##

  environment location: /home/bag/miniconda3/envs/testperl

  added / updated specs:
    - perl

The following NEW packages will be INSTALLED:

  _libgcc_mutex      pkgs/main/linux-64::_libgcc_mutex-0.1-main
  libgcc-ng          pkgs/main/linux-64::libgcc-ng-9.1.0-hdf63c60_0
  perl               conda-forge/linux-64::perl-5.26.2-h516909a_1006

Proceed ([y]/n)? y

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
#
# To activate this environment, use
#
#     $ conda activate testperl
#
# To deactivate an active environment, use
#
#     $ conda deactivate

bag@bag:~/projects/code/staged-recipes$ conda activate testperl
(testperl) bag@bag:~/projects/code/staged-recipes$ perl --version

This is perl 5, version 26, subversion 2 (v5.26.2) built for x86_64-linux-thread-multi

Copyright 1987-2018, Larry Wall

Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.

Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl".  If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.
bgruening commented 5 years ago

What is a which perl giving you?

jfallmann commented 5 years ago
which perl
~/anaconda3/envs/testperl/bin/perl

how weird is this? I'm running Fedora 30 btw, is it possible this is some OS fuckup? Just saw https://fedoraproject.org/wiki/Changes/FullyRemoveDeprecatedAndUnsafeFunctionsFromLibcrypt

It works on a machine running 5.0.6-200.fc29.x86_64, not on another with fc30, omg

jfallmann commented 5 years ago

@scopatz @bgruening Can't beleive it, really was a FC30 problem, after installing libxcrypt-compat on my system as hinted to by https://fedoraproject.org/wiki/Changes/FullyRemoveDeprecatedAndUnsafeFunctionsFromLibcrypt#Documentation everything is working as expected again, I'll close this issue, thanks for your time

scopatz commented 5 years ago

wow crazy!