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

Mark bc as a package dependency #2974

Closed
Tuetuopay opened this issue Apr 25, 2016 · 11 comments
Closed

Mark bc as a package dependency #2974

Tuetuopay opened this issue Apr 25, 2016 · 11 comments

Comments

@Tuetuopay
Copy link

Tuetuopay commented Apr 25, 2016

On some systems, the bc utility is not present in the default install, making the math command unusable. This has been tested on CentOS 7 Minimal and Debian 7, where fish was installed through the package manager, as explained here.

Reproduction Steps:

  1. Install fish using the steps given here
  2. Do any kind of math, e.g. math 2+2

Expected behavior:

We should get the expected math output, as stated in the docs.

tuetuopay@server ~> math 2+2
4

Observed behavior:

The math command fails saying the bc is unknown.

tuetuopay@server ~> math 2+2
env: bc: No such file or directory

(the error message might be a little off, as I translated it from French)

Additional information:

Clean CentOS 7 Minimal install. The problem was fixed by installing the bc package with yum.


Fish version: 2.2.0

Operating system: CentOS 7 Minimal and Debian 7, and fish was installed from the repositories from OpenSUSE following this guide (linked from fish's homepage).

Terminal or terminal emulator: Cygwin

@ghost
Copy link

ghost commented Apr 25, 2016

isn't it bc not gc?

@Tuetuopay
Copy link
Author

Ooops yeah, editing

@Tuetuopay Tuetuopay changed the title Mark gc as a package dependency Mark bc as a package dependency Apr 25, 2016
@isudak
Copy link

isudak commented Apr 26, 2016

I can't reproduce the error that you describe. I think the problem is in your OS.

First, fish.rpm depends on 'bc':

$ rpm -q --qf "%{DISTRIBUTION}" --nosignature -R -p fish-2.2.0-3.2.x86_64.rpm 
shells:fish:release:2 / CentOS_7/bin/sh
/bin/sh
/usr/bin/env
/usr/bin/pkg-config
bc
config(fish) = 2.2.0-3.2
libc.so.6()(64bit)
...

How did you install the package without dependencies? Yum must install them.

Second. I installed CentOS-7-x86_64-Minimal-1511.iso, download a repo-file with:

[root@localhost ~]# cd /etc/yum.repos.d
[root@localhost ~]# wget http://download.opensuse.org/repositories/shell:fish:release:2/CentOS_7/shells:fish:release:2.repo

Then install fish-shell:

[root@localhost yum.repos.d]# yum install fish
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
...
Resolving Dependencies
--> Running transaction check
---> Package fish.x86_64 0:2.2.0-3.2 will be installed
--> Processing Dependency: bc for package: fish-2.2.0-3.2.x86_64
--> Running transaction check
---> Package bc.x86_64 0:1.06.95-13.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

===================================================================================
 Package    Arch         Version                 Repository                   Size
===================================================================================
Installing:
 fish       x86_64       2.2.0-3.2               shells_fish_release_2       1.2 M
Installing for dependencies:
 bc         x86_64       1.06.95-13.el7          base                        115 k

Transaction Summary
===================================================================================
Install  1 Package (+1 Dependent package)

Total download size: 1.3 M
Installed size: 5.5 M
Is this ok [y/d/N]: y
...
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : bc-1.06.95-13.el7.x86_64                                        1/2 
  Installing : fish-2.2.0-3.2.x86_64                                           2/2 
  Verifying  : fish-2.2.0-3.2.x86_64                                           1/2 
  Verifying  : bc-1.06.95-13.el7.x86_64                                        2/2 

Installed:
  fish.x86_64 0:2.2.0-3.2                                                          

Dependency Installed:
  bc.x86_64 0:1.06.95-13.el7                                                       

Complete!
[root@localhost yum.repos.d]# fish
Welcome to fish, the friendly interactive shell
Type help for instructions on how to use fish
root@localhost /e/yum.repos.d# math 2+2
4
root@localhost /e/yum.repos.d# 

@Tuetuopay
Copy link
Author

On CentOS, I did the same as you (wget in /etc/yum.repos.d then yum install fish), but bc is not a dependency.

[root@localhost yum.repos.d] # yum deplist fish
Modules complémentaires chargés : fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.ircam.fr
 * epel: vesta.informatik.rwth-aachen.de
 * extras: mirrors.ircam.fr
 * updates: mirrors.ircam.fr
paquet : fish.x86_64 2.2.0-7.el7
  dépendance   : /bin/sh
   provider: bash.x86_64 4.2.46-19.el7
  dépendance   : /usr/bin/python3.4
   provider: python34.x86_64 3.4.3-4.el7
  dépendance   : libc.so.6(GLIBC_2.15)(64bit)
   provider: glibc.x86_64 2.17-106.el7_2.4
  dépendance   : libgcc_s.so.1()(64bit)
   provider: libgcc.x86_64 4.8.5-4.el7
  dépendance   : libm.so.6()(64bit)
   provider: glibc.x86_64 2.17-106.el7_2.4
  dépendance   : libncurses.so.5()(64bit)
   provider: ncurses-libs.x86_64 5.9-13.20130511.el7
  dépendance   : libpthread.so.0()(64bit)
   provider: glibc.x86_64 2.17-106.el7_2.4
  dépendance   : libpthread.so.0(GLIBC_2.2.5)(64bit)
   provider: glibc.x86_64 2.17-106.el7_2.4
  dépendance   : libpthread.so.0(GLIBC_2.3.2)(64bit)
   provider: glibc.x86_64 2.17-106.el7_2.4
  dépendance   : librt.so.1()(64bit)
   provider: glibc.x86_64 2.17-106.el7_2.4
  dépendance   : librt.so.1(GLIBC_2.2.5)(64bit)
   provider: glibc.x86_64 2.17-106.el7_2.4
  dépendance   : libstdc++.so.6()(64bit)
   provider: libstdc++.x86_64 4.8.5-4.el7
  dépendance   : libstdc++.so.6(CXXABI_1.3)(64bit)
   provider: libstdc++.x86_64 4.8.5-4.el7
  dépendance   : libstdc++.so.6(GLIBCXX_3.4)(64bit)
   provider: libstdc++.x86_64 4.8.5-4.el7
  dépendance   : libstdc++.so.6(GLIBCXX_3.4.15)(64bit)
   provider: libstdc++.x86_64 4.8.5-4.el7
  dépendance   : libtinfo.so.5()(64bit)
   provider: ncurses-libs.x86_64 5.9-13.20130511.el7
  dépendance   : rtld(GNU_HASH)
   provider: glibc.x86_64 2.17-106.el7_2.4
   provider: glibc.i686 2.17-106.el7_2.4
[root@localhost yum.repos.d] #

On debian, there indeed is a problem with my system, as bc is a dependency (according to apt-cache showpkg fish) but it didn't get installed o_O

@Tuetuopay
Copy link
Author

I just found the root cause on centos : yum installed the package from the epel repository, and not from suse repo.

[root@localhost yum.repos.d] # yum info fish
Modules complémentaires chargés : fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.ircam.fr
 * epel: vesta.informatik.rwth-aachen.de
 * extras: mirrors.ircam.fr
 * updates: mirrors.ircam.fr
Paquets installés
Nom                 : fish
Architecture        : x86_64
Version             : 2.2.0
Révision            : 7.el7
Taille              : 5.2 M
Dépôt               : installed
Depuis le dépôt     : epel
Résumé              : A friendly interactive shell
URL                 : http://fishshell.com/
Licence             : GPLv2
Description         : fish is a fully-equipped command line shell (like bash or zsh) that is
                    : smart and user-friendly. fish supports powerful features like syntax
                    : highlighting, autosuggestions, and tab completions that just work, with
                    : nothing to learn or configure.

[root@localhost yum.repos.d] #

So I guess the culprits are the epel maintainers and not the fish maintainers :/

@isudak
Copy link

isudak commented Apr 26, 2016

@Tuetuopay Good for you! Is it time to close the issue?

@Tuetuopay
Copy link
Author

I guess so, unless the package in the epel repo is maintained by the fish maintainers

@isudak
Copy link

isudak commented Apr 26, 2016

Hmm.. According to the changelog (https://dl.fedoraproject.org/pub/epel/7/SRPMS/f/fish-2.2.0-7.el7.src.rpm):

%changelog

  • Sat Jan 02 2016 Oliver Haessler oliver@redhat.com - 2.2.0-7
  • included patch directly into the spec file
  • added new patch for using python3.4 on EPEL 7
  • excluded ppc64le as the fish_tests fail for this arch

the maintainer is from RedHat...

@Tuetuopay
Copy link
Author

Tuetuopay commented Apr 26, 2016

Yup, filing an issue in their bugzilla atm, the issue can be closed.

@zanchey
Copy link
Member

zanchey commented Apr 26, 2016

Yep - please take this up with downstream.

@zanchey zanchey closed this as completed Apr 26, 2016
@andrew-schulman
Copy link
Contributor

In Cygwin I added REQUIRES="bc" to the Cygport build script, to enforce the dependency on bc.

@krader1961 krader1961 added this to the will-not-implement milestone Mar 25, 2017
christianrondeau added a commit to christianrondeau/termux-packages that referenced this issue Apr 22, 2017
See fish-shell/fish-shell#2974

This will only fail at runtime in some autocomplete commands, if the dependency is not installed.
fornwall pushed a commit to termux/termux-packages that referenced this issue Apr 22, 2017
See fish-shell/fish-shell#2974

This will only fail at runtime in some autocomplete commands, if the dependency is not installed.
its-pointless pushed a commit to its-pointless/termux-packages that referenced this issue May 7, 2017
See fish-shell/fish-shell#2974

This will only fail at runtime in some autocomplete commands, if the dependency is not installed.
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants