Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 11-02-2009, 05:51 PM   #1
LQ Newbie
Registered: Jul 2009
Posts: 7

Rep: Reputation: 0
Unhappy No bc or dc calculater

I am tring to do floating point arithmetic on command-line.
I'm using Knoppix 6 with kernel, init 2.86, GUI LXDE
No, bc or dc calculator. I downloaded bc-1.06, extracted it in
/usr. I cd to bc-1.06 folder where is located. At
the command-line typed ./configure, this was the stdout:

loading cache ./config.cache
checking for BSD compatible install ..usr/bin/install-c
checking whether build environment is same .. yes
checking whether make sets ${MAKE} .. no
checking for working aclocal .. missing
checking for working autoconf .. missing
checking for working automake .. missing
checking for working autoheader .. missing
checking for working makeinfo .. missing
checking for gcc .. gcc
checking whether we are using GNU c .. yes
checking whether gcc accepts -g .. yes
checking how to run the c preprocessor .. gcc-E
checking for minix /config.h .. no
checking for flex .. no
checking for lex .. no
./configure line 1186: flex: command not found
checking for flrx .. lex
checking for yywrap in -LL .. no
checking lex .. lex command not found
configure error: can not find output from lex giving up:

After that typed make at command-line stdout:
make command not found
Can someone please tell me what I'm doing wrong, or what I'm missing?
Old 11-02-2009, 06:23 PM   #2
Registered: Feb 2004
Location: Sydney - Australia
Distribution: Ubuntu, OpenSUSE, Mythbuntu, Embedded Linux
Posts: 46

Rep: Reputation: 18
The error code is pointing out that you must have "lex" loaded and installed before you can compile the "bc" program because it needs "lex" and its libraries.

So, simple get "lex" and install.

Old 11-02-2009, 06:37 PM   #3
LQ 5k Club
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016 CentOS6.9 CentOS7.3 + 50+ other Linux OS, for test only.
Posts: 16,705

Rep: Reputation: 3294Reputation: 3294Reputation: 3294Reputation: 3294Reputation: 3294Reputation: 3294Reputation: 3294Reputation: 3294Reputation: 3294Reputation: 3294Reputation: 3294

' lex ' : The name for the open source lexer is "flex"
Old 11-03-2009, 03:11 PM   #4
LQ Guru
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288
Also note that python and awk can also do floating point in case bc is not available.



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 > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:21 AM.

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