Score:0

Problem installing Perl module Sys::Info::Driver::Linux

gb flag

I am running Linux on Windows (Ubuntu) to install a bioinformatics software (MEME Suite - Installation Guide). Please bear in mind I do not have much experience using Linux.

I am following the instructions and I need to install some Perl modules.

I was able to install all the required ones via sudo cpan except Sys::Info.

When I run sudo cpan Sys::Info this is the first error I find on the log:

Running install for module 'Sys::Info'
Checksum for /root/.cpan/sources/authors/id/B/BU/BURAK/Sys-Info-0.7811.tar.gz ok
'YAML' not installed, will not store persistent state
Configuring B/BU/BURAK/Sys-Info-0.7811.tar.gz with Makefile.PL
Checking if your kit is complete...
Looks good
Warning: prerequisite Sys::Info::Driver::Linux 0.78 not found.

Then, when it tries to install Sys::Info::Driver::Linux, I get the following error:

t/03-basic.t ............. UNAME: Linux DESKTOP-IO6J8UE 4.4.0-19041-Microsoft #1237-Microsoft Sat Sep 11 14:32:00 PST 2021 x86_64 x86_64 x86_64 GNU/Linux
t/03-basic.t ............. 1/? Use of uninitialized value $name in string eq at /root/.cpan/build/Sys-Info-Driver-Linux-0.7905-8/blib/lib/Sys/Info/Driver/Linux/OS.pm line 102. Use of uninitialized value $name in string eq at /root/.cpan/build/Sys-Info-Driver-Linux-0.7905-8/blib/lib/Sys/Info/Driver/Linux/OS.pm line 102.
Use of uninitialized value $name in string eq at /root/.cpan/build/Sys-Info-Driver-Linux-0.7905-8/blib/lib/Sys/Info/Driver/Linux/OS.pm line 102.
Use of uninitialized value $name in string eq at /root/.cpan/build/Sys-Info-Driver-Linux-0.7905-8/blib/lib/Sys/Info/Driver/Linux/OS.pm line 102.
Use of uninitialized value $name in string eq at /root/.cpan/build/Sys-Info-Driver-Linux-0.7905-8/blib/lib/Sys/Info/Driver/Linux/OS.pm line 102.
Use of uninitialized value $name in string eq at /root/.cpan/build/Sys-Info-Driver-Linux-0.7905-8/blib/lib/Sys/Info/Driver/Linux/OS.pm line 102.
Use of uninitialized value $name in string eq at /root/.cpan/build/Sys-Info-Driver-Linux-0.7905-8/blib/lib/Sys/Info/Driver/Linux/OS.pm line 102.
Use of uninitialized value $name in string eq at /root/.cpan/build/Sys-Info-Driver-Linux-0.7905-8/blib/lib/Sys/Info/Driver/Linux/OS.pm line 102.
Use of uninitialized value $name in string eq at /root/.cpan/build/Sys-Info-Driver-Linux-0.7905-8/blib/lib/Sys/Info/Driver/Linux/OS.pm line 102.
I can not open file /proc/swaps for reading: No such file or directory at /usr/local/share/perl/5.30.0/Test/Sys/Info/Driver.pm line 92.
Looks like your test exited with 2 just after 65.

Probably it has something to do with my Linux on Windows installation, but I am completely lost. I can provide the full log if needed.

EDIT: I found the OS.pm file and the possible error:

# user methods
sub is_root {
    return 0 if defined &Sys::Info::EMULATE;
    my $name = login_name();
    my $id   = POSIX::geteuid();
    my $gid  = POSIX::getegid();
    return 0 if $@;
    return 0 if ! defined $id || ! defined $gid;
    return $id == 0 && $gid == 0 && $name eq 'root';
}

Any advice would be much appreciated!

Knud Larsen avatar
by flag
Tests are often omitted : `sudo apt install libsys-info-driver-linux-perl ` → **universe** ....... https://packages.ubuntu.com/focal/perl/ . ..... Alternatively → Sys-Info-Driver-Linux-0.7905.tar.gz → `perl Makefile.PL && make && sudo make install`
eggrandio avatar
gb flag
Thank you so much! I was able to finally install them via `sudo apt install libsys-info-perl` `
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.