LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-03-2013, 02:08 AM   #1
Gurpreet1
LQ Newbie
 
Registered: Sep 2013
Posts: 1

Rep: Reputation: Disabled
To find the version of ncurses installed on linux system though shell command


I have ncurses installed on my system ubuntu 13.04.
But how can i check the version of ncurses installed on my system through linux shell command.
 
Old 09-03-2013, 02:31 AM   #2
evo2
LQ Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and CentOS
Posts: 6,724

Rep: Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705
Hi,

you can use your package manager. Example with dpkg:
Code:
 dpkg -l '*ncurses*' | grep '^ii'
Evo2.
 
Old 09-03-2013, 02:55 AM   #3
dickey
Member
 
Registered: Jun 2009
Posts: 43

Rep: Reputation: 18
That works for Debian/Ubuntu. Other systems may use rpm. But that's the package version,
which may not be what was requested.

Generally the utilities tic and infocmp are installed, and they give the ncurses
version itself with a "-V" option.
 
Old 09-03-2013, 03:05 AM   #4
evo2
LQ Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and CentOS
Posts: 6,724

Rep: Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705Reputation: 1705
Hi,
Quote:
Originally Posted by dickey View Post
That works for Debian/Ubuntu.
the OP specified Ubuntu, so he got an Ubuntu specific answer.

Quote:
Originally Posted by dickey View Post
But that's the package version, which may not be what was requested.
The package version includes the ncurses version.

Using tic or incocmp will only report about that particular version of ncurses that they are using (ie the ncurses version of ncurses-bin, or if you want distro non-specific ncurses version they are linked against) and not the versions of all ncurses packages installed.

Evo2.
 
Old 12-21-2018, 06:14 AM   #5
shevegen
Member
 
Registered: May 2004
Distribution: Slackware / GoboLinux / LFS / VoidLinux
Posts: 145

Rep: Reputation: 26
> Using tic or incocmp will only report about that particular version of ncurses that they are using
> (ie the ncurses version of ncurses-bin, or if you want distro non-specific ncurses version they
> are linked against) and not the versions of all ncurses packages installed.

What do mean with "all ncurses packages installed"?

How can you install multiple ncurses version via your distro manager? For example at /usr/bin/tic
there may be only one tic, not more than one, so I am curious how you resolve this situation.

(Of course I know how to resolve it on non-FHS systems such as GoboLinux; and I am aware of
hacks such as gentoo's eselect, but I am still curious to hear how you resolve this on FHS
systems.)

tic will work very well since the cases where people on FHS use multiple versions of ncurses
will be very, very small. The ideal way would be to have a .pc file for ncurses distributed
by default. Querying the soname may also be useful - even in the event that there is more
than one version, the sonames will always have a higher number when released at a later time,
which can be used in scripts to check for their version.

I had the same problem as the threadstarter since I have a gem written in ruby that queries
lots of host-systems, a bit like the script used in linux from scratch. I thought about what
the best way would be but the tic-way suggested by dickey is highly superior, since it is
distribution-agnostic rather than debian-constrained as the comment before stated via
dpkg. Not everyone uses debian, bro.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to find the linux operating system version in SLES/RHEL? vedam.psg Linux - Software 4 03-11-2014 07:49 AM
Linux File System. Can't find Installed pkg. Ace Blackwell Slackware 6 01-27-2013 12:08 AM
How to find the installed version of a rpm package in a system?? Arighna Linux - Newbie 10 09-21-2011 09:22 AM
Linux Command to find the OS version of remote host. jeesun Linux - General 1 12-29-2010 08:38 PM
Package ncurses-5.6-20.20080927.fc10.i386 already installed and latest version folatutor Linux - Newbie 1 02-26-2009 05:27 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:52 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration