PDA

Bekijk de volledige versie : HowTo native compilation ?



darius
05-01-2009, 23:55
Hi,

worked really hard, got help from many people and still see no chance to compile basic Linux application for a router, called Linux Dialog.

Could you kindly write HowTo native compilation ?


Please read the following thread
http://wl500g.info/showthread.php?t=17717

Linux dialog sources
http://ftp.de.debian.org/debian/pool/main/d/dialog/dialog_1.0-20060221.orig.tar.gz

============================================

created a toolchain for native compilation use:
ipkg install optware-devel

as advised by al37919

running
/opt/broadcom/opt/brcm/hndtools-mipsel-uclibc-0.9.19/bin/mipsel-uclibc-gcc

i get the follwing errors

======================
[admin@oo /opt]$ mipsel-uclibc-gcc -o helloworld
-sh: mipsel-uclibc-gcc: not found
[admin@oo /opt]$ /opt/broadcom/opt/brcm/hndtools-mipsel-uclibc-0.9.19/bin/mipsel-uclibc-gcc
/opt/broadcom/opt/brcm/hndtools-mipsel-uclibc-0.9.19/bin/mipsel-uclibc-gcc: /opt/broadcom/opt/brcm/hndtools-mipsel-uclibc-0.9.19/bin/mipsel-uclibc-gcc: 1: Syntax error: "(" unexpected
[admin@oo /opt]$ /opt/broadcom/opt/brcm/hndtools-mipsel-uclibc-0.9.19/bin/mipsel-uclibc-gcc --help
/opt/broadcom/opt/brcm/hndtools-mipsel-uclibc-0.9.19/bin/mipsel-uclibc-gcc: /opt/broadcom/opt/brcm/hndtools-mipsel-uclibc-0.9.19/bin/mipsel-uclibc-gcc: 1: Syntax error: "(" unexpected
[admin@oo /opt]$


Any sollution for syntax error "(" ?

And what directory is/was correct to save optware-devel
and how to make

/opt/broadcom/opt/brcm/hndtools-mipsel-uclibc-0.9.19/bin/mipsel-uclibc-gcc

running as
mipsel-uclibc-gcc
only ?

What is your solution ?

Tried to install
mkdir /opt
cd /opt < enter >
wget http://www.asuscom.de/pub/ASUS/wirel...3/GPL_1927.zip < enter >
tar zxf ./GPL_1927.zip < enter >
cp -R /opt/broadcom/opt/brcm /opt < enter >

==========
cd /var/tmp
wget http://oleg.wl500g.info/1.9.2.7-6b/w...2.7-6b.tar.bz2
tar xjf wl500g-1.9.2.7-6b.tar.bz2
cd wl500g-1.9.2.7-6b
make uClibc

but was low on memory (2GB pendrive)
and -j option didn't work.

Today
mipsel-uclibc-gcc

generates syntax error.

I need Linux dialog to test some shell scripts.


Darius

wpte
06-01-2009, 00:21
I already gave you this link: http://wpte.kicks-ass.net/forum/viewthread.php?thread_id=2

I''m working with this, and it works fine, since it''s the most obvious way to compile stuff...

these toolchains you have here are for machines that arent MIPS and want to compile something for MIPS called cross-compiling.
the only thing you need is GCC and some other basic things.

+ you need those ncurses headers wich I just compiled
the package dialog itself still contains some bugs, just some linking problems so I need to dive into that and fix the code:rolleyes:

darius
06-01-2009, 07:10
I already gave you this link: http://wpte.kicks-ass.net/forum/viewthread.php?thread_id=2

I''m working with this, and it works fine, since it''s the most obvious way to compile stuff...

these toolchains you have here are for machines that arent MIPS and want to compile something for MIPS called cross-compiling.
the only thing you need is GCC and some other basic things.

+ you need those ncurses headers wich I just compiled
the package dialog itself still contains some bugs, just some linking problems so I need to dive into that and fix the code:rolleyes:

Thanks.
So no chance for native dialog compilation as of today ?

I have already visited the link you provided:

==================================
Discussion Forum
Forum Threads Posts Last Post
There are no Forums defined.

New Posts - Forum with new posts since last visit.
No New Posts - Forum with no new posts since last visit.
==========================================

where to go now ?


Two other forum members already claimed Linux dialog native compilation to work

"
Lesiuk Lesiuk is offline
Member

Join Date: Aug 2008
Posts: 43
Download sources and compile it. I try it and it works. (I native compile it under my router.)

Link to sources: http://ftp.de.debian.org/debian/pool...21.orig.tar.gz
"

al37919 al37919 is offline
Forum Guru
said:\

"
to create a toolchain for native compilation use:
PHP Code:
ipkg install optware-devel
"

Darius

al37919
06-01-2009, 10:09
Well, may be instead of flooding the forum by endless and useless topics you make an effort to read what is already answered on your questions?

Hint: read two last lines of the following post 100 times until the Great Enlightenment comes to you: http://wl500g.info/showpost.php?p=126157&postcount=18

I don't think that your flood in Russian forum will be honored either.

darius
06-01-2009, 11:04
Well, may be instead of flooding the forum by endless and useless topics you make an effort to read what is already answered on your questions?

Hint: read two last lines of the following post 100 times until the Great Enlightenment comes to you: http://wl500g.info/showpost.php?p=126157&postcount=18

I don't see any flood in Russian forum will be honored either.

As there is no flood in Russian forum at all, very basic questions only,
let others to share their Linux experience.

Exhibit No.1
===========
Russian Discussion
http://wl500g.info/forumdisplay.php?f=86
My dear friend,

I am surprised by your answer and really don't know what your problem is.
You are Forum Guru.
Aren't you ?

So I have asked you very basic question how to native compile Linux dialog
and still don't have your answer

EXHIBIT No.2
===========
http://wl500g.info/showpost.php?p=126157&postcount=18

al37919 al37919 is nu online
Forum Guru

Join Date: Feb 2007
Location: ,
Posts: 2,049
Hm..., and where in this text you see the statement that this should be done on the router?
================================================== =======

I am not interested in philosophy.
I have asked very basic question and expected exact answer only.
Yes or No.

If you claim native compilation is not possible, just say so, to save my time.
But say it in plain words, avoding any philosophy.


Not giving exact anwers that's you generating the problem, forcing me to ask the same question again to other members.

None topic is endless and useless.
Native compilation is of great importance to users of Asus routers.

I don't need to read any post 100 times.
Read your answer once and run compiler and got syntax error message.

Is ")" syntax error ok for you ?

Asking questions is not flooding a forum.
Russian Discussion is populated by many experienced Linux developers
so I expect Linux dialog be compiled for a router,
by one such experienced Linux developer finally.

Native or cross compiled.

Asking question is expecting to get the right answer.
If I don't get it, I just say what I did, what results are, and ask what should I do next.

So what is your final answer to my question about native compilation of Linux dialog.

As I am not a Linux developer, Asus router user only, I expected to get help from this Forum's Guru, not another puzzle.

Can you write step-by-step Native Compile HowTo manual one day for beginners ?

If not Linux dialog, so what about native compilation of
ncurses.c / curses exaple
from
http://www.captain.at/howto-curses-example.php

Or some other solution for outputting shell script generated data to monitor screen ?
gmplot is for graphics,

installed ncurses interface
ipkg install ncurses and still don't know how to start
basic data viewer application (very very basic) on native Asus router.


As you see, I am really surprised, much more experienced Linux fans
didn't compiled Linux dialog yet.
One claimed a problem with ncurses compilation.

Have a nice day.

Darius

BTW
As your claims are totally unsupported
copy goes to my lawyer for review.

wpte
06-01-2009, 14:47
Well, may be instead of flooding the forum by endless and useless topics you make an effort to read what is already answered on your questions?

Hint: read two last lines of the following post 100 times until the Great Enlightenment comes to you: http://wl500g.info/showpost.php?p=126157&postcount=18

I don't think that your flood in Russian forum will be honored either.

yeh... gotta agree with that tbh...
darius, I don't think ur a bad guy, but we are all here to learn and help. it's free and we do it voluntairy.
you can't just come here and shout to everyone that he needs to help you.
I didn't do everything by myself, and so didn't all the others here (if I may say that), but we did find out stuff for ourself and shared it here. so others can find their way to a nice router quickly.
I love reading and posting on the forums since I keep learning here, things I might use in my study:)

anyway... sorry for my site to have a bug I didn't discovered yet:D
probably have to change a few settings there:confused:
but here you go: http://wl500g.info/showthread.php?t=14538

darius
06-01-2009, 16:14
yeh... gotta agree with that tbh...
darius, I don't think ur a bad guy, but we are all here to learn and help. it's free and we do it voluntairy.
you can't just come here and shout to everyone that he needs to help you.
I didn't do everything by myself, and so didn't all the others here (if I may say that), but we did find out stuff for ourself and shared it here. so others can find their way to a nice router quickly.
I love reading and posting on the forums since I keep learning here, things I might use in my study:)

anyway... sorry for my site to have a bug I didn't discovered yet:D
probably have to change a few settings there:confused:
but here you go: http://wl500g.info/showthread.php?t=14538

wpte, I don't think ur a bad guy,

visited the above thread and followed your HowTo

ipkg update
ipkg upgrade

ipkg install optware-devel
ipkg install buildroot

Downloaded the source into /opt/dialog directory

./configure --prefix=/opt
make
make install

===========
The issue is, when I run
./configure --prefix=/opt


[admin@oo dialog]$ ./configure --prefix=/opt/dialog
checking for package version... 1.1
checking for package patch date... 20080819
checking for gcc... gcc
checking for C compiler default output... configure: error: C compiler cannot create executables

Ok. I am low on memory
and mayby I should copy dialog sources
into /mnt/share/dialog directory
as advised by wpte

I tested gcc, running it alone from a command line and it generated "(" syntax error.

How could I debug to see what's wrong ?

I am a beginner in Linux compilation.

As you can see there is a problem with c compiler.
How to debug it ?

Darius

darius
06-01-2009, 16:19
follow-up

logfile

[admin@oo dialog]$ ipkg update
Downloading http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/Packages .gz

Inflating http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/Packages.g z
Updated list of available packages in /opt/lib/ipkg/lists/optware
Successfully terminated.
[admin@oo dialog]$ ipkg upgrade
Upgrading bluez-hcidump on /opt/ from 1.40-1 to 1.42-1...
Downloading http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/bluez-hc idump_1.42-1_mipsel.ipk
Upgrading bluez-libs on /opt/ from 3.17-1 to 3.36-1...
Downloading http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/bluez-li bs_3.36-1_mipsel.ipk
Upgrading bluez-utils on /opt/ from 3.17-1 to 3.36-3...
Downloading http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/bluez-ut ils_3.36-3_mipsel.ipk
Upgrading hdparm on /opt/ from 8.9-1 to 9.6-1...
Downloading http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/hdparm_9 .6-1_mipsel.ipk
Upgrading libpng on /opt/ from 1.2.33-1 to 1.2.34-1...
Downloading http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/libpng_1 .2.34-1_mipsel.ipk
Configuring bluez-hcidump
Configuring bluez-libs
Configuring bluez-utils
Configuring hdparm
update-alternatives: Linking //opt/sbin/hdparm to /opt/sbin/hdparm-hdparm
Configuring libpng
Successfully terminated.
[admin@oo dialog]$ ipkg install optware-devel
Package optware-devel (6.8-9) installed in /opt/ is up to date.
Nothing to be done
Successfully terminated.
[admin@oo dialog]$ ipkg install buildroot
Package buildroot (4.1.1-13) installed in /opt/ is up to date.
Nothing to be done
Successfully terminated.
[admin@oo dialog]$
=======

[admin@oo dialog]$ ./configure --prefix=/opt/dialog
checking for package version... 1.1
checking for package patch date... 20080819
checking for gcc... gcc
checking for C compiler default output... configure: error: C compiler cannot create executables
[admin@oo dialog]$

============
follow-up 2

[admin@oo dialog]$ df
Filesystem 1K-blocks Used Available Use% Mounted on
rootfs 3008 3008 0 100% /
/dev/root 3008 3008 0 100% /
/dev/discs/disc0/part2
1198832 1155480 0 100% /opt
/dev/discs/disc0/part3
2140816 68444 1963624 4% /tmp/mnt/disc0_3
[admin@oo dialog]$

Do I need to free some space to run configuration ?

Darius

=============
follow-up 3

how did you create a new directory share in /mnt ?

you said:
"

I''ve uploaded the file to /mnt/share/apache
cd to the directory
"

[admin@oo /mnt]$ ls
[admin@oo /mnt]$ mkdir share
cannot create directory `share': Read-only file system
[admin@oo /mnt]$


D.

wpte
06-01-2009, 17:25
[admin@oo dialog]$ ./configure --prefix=/opt/dialog
checking for package version... 1.1
checking for package patch date... 20080819
checking for gcc... gcc
checking for C compiler default output... configure: error: C compiler cannot create executables



that last line is most likely ur problem, for some reason you can get errors during install.

try this code to reinstall the whole compile package (also in my howto)

ipkg update
ipkg install -force-overwrite -force-reinstall optware-devel autoconf automake bash bison bzip2 coreutils diffutils file findutils flex gawk groff libstdc++ libtool make m4 ncurses openssl patch perl pkgconfig python rsync sed svn tar wget-ssl buildroot

anyway... you get a syntax error, wich means there are some missing/to mutch signs like ()[] etc.
Debugging is done via putting breakpoints down... but since I think you can't do that, nor have the software for it... you can better use the lots of debugging flag turned on:

make -d

native compiling is always tricky since not everything is supported on a mipsel device...

now there isn't mutch else to say about this, because compiling is always tricky, and you do need to know basic programming skills at C or C++ to properly fix things.

darius
06-01-2009, 18:22
that last line is most likely ur problem, for some reason you can get errors during install.

try this code to reinstall the whole compile package (also in my howto)


anyway... you get a syntax error, wich means there are some missing/to mutch signs like ()[] etc.
Debugging is done via putting breakpoints down... but since I think you can't do that, nor have the software for it... you can better use the lots of debugging flag turned on:


native compiling is always tricky since not everything is supported on a mipsel device...

now there isn't mutch else to say about this, because compiling is always tricky, and you do need to know basic programming skills at C or C++ to properly fix things.

thanks again
and have a look at errors generated while reinstalling packages

Ok. Compiling is always tricky, but we all use the same firmware, the same hardware, the same packages, so compiling is a deterministic process
and we should get the same results for the same configuration and settings.

Frankly speaking I don't anyone but me, claiming native compilation problems.
On the other hand, I don't anyone claiming successful native compilation of any package, any program in c.

You have ever succeeded in native compilation ?
If so, how did you manage to create any directory in /mnt read only directory ?

logfile
....
update-alternatives: Linking //opt/bin/sed to /opt/bin/gnu-sed
Configuring svn
Configuring tar
update-alternatives: Linking //opt/bin/tar to /opt/bin/gnutar
Configuring wget-ssl
An error ocurred, return value: 22.
Collected errors:
ipkg_download: ERROR: Command failed with return value 1: `wget -q -P /opt/ipkg-F1bzOx http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/buildroot_4.1.1-13_mipsel.ipk'
Failed to download buildroot. Perhaps you need to run 'ipkg update'?
[admin@oo /mnt]$

memory usage
++++++++++++
[admin@oo ncurses]$ df
Filesystem 1K-blocks Used Available Use% Mounted on
rootfs 3008 3008 0 100% /
/dev/root 3008 3008 0 100% /
/dev/discs/disc0/part2
1198832 1157340 0 100% /opt
/dev/discs/disc0/part3
2140816 68444 1963624 4% /tmp/mnt/disc0_3
[admin@oo ncurses]$

Any idea what's wrong ?

/opt/ipkg-F1bzOx looks like broken temporary download

Darius

wpte
06-01-2009, 20:14
You have ever succeeded in native compilation ?
If so, how did you manage to create any directory in /mnt read only directory ?

When you read... do you think?:rolleyes:
I have my hdd mounted on /mnt (because it's shorter, duh!)
maybe you have it mounted on /tmp/harddisk
I dunno, just place it somewhere you can access it!:rolleyes:

and yes, I had several properly compiled packages under oleg:
libupnp, wol, Ocaml, openssh, openvpn, ncurses and some others.

some other guys reading my how-to managed to compile things like extra PHP includes.

+ just start off with something easy and small to compile, so you can get the grip on it and feel the way compiling happens.

darius
06-01-2009, 20:27
When you read... do you think?:rolleyes:
I have my hdd mounted on /mnt (because it's shorter, duh!)
maybe you have it mounted on /tmp/harddisk
I dunno, just place it somewhere you can access it!:rolleyes:

and yes, I had several properly compiled packages under oleg:
libupnp, wol, Ocaml, openssh, openvpn, ncurses and some others.

some other guys reading my how-to managed to compile things like extra PHP includes.

+ just start off with something easy and small to compile, so you can get the grip on it and feel the way compiling happens.


When you read... do you think?
as you can see my last 2 follow-ups
there is permanent problem with buildroot download.
So how could I compile anything easy or small at all .

Could you verify buildroot download on your native Linux machine ?

Darius


[admin@oo /mnt]$ ipkg install -force-overwrite -force-reinstall buildroot
Reinstalling buildroot (4.1.1-13) on /opt/...
Downloading http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/buildroot_4.1.1-13_mipsel.ipk
Nothing to be done
An error ocurred, return value: 22.
Collected errors:
ipkg_download: ERROR: Command failed with return value 1: `wget -q -P /opt/ipkg-cF3Erv http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable/buildroot_4.1.1-13_mipsel.ipk'
Failed to download buildroot. Perhaps you need to run 'ipkg update'?
[admin@oo /mnt]$

wpte
06-01-2009, 20:50
maybe ur disk is full? it takes 42MB to download...

darius
06-01-2009, 21:56
maybe ur disk is full? it takes 42MB to download...

must be the case

Filesystem 1K-blocks Used Available Use% Mounted on
rootfs 3008 3008 0 100% /
/dev/root 3008 3008 0 100% /
/dev/discs/disc0/part2
1198832 1148840 0 100% /opt
/dev/discs/disc0/part3
2140816 70716 1961352 4% /tmp/mnt/disc0_3
[admin@oo root]$

Any chance to free /opt
What ipkg, files should I remove ?

Darius

My ipkg list_installed

adduser - 1.10.3-1 - a multi-call binary for login and user account administration
apr - 1.3.3-1 - Apache Portable Runtime library
apr-util - 1.3.4-2 - Apache Portable Runtime utilities library
autoconf - 2.61-2 - Creating scripts to configure source code packages using templates
automake - 1.10-2 - Creates GNU standards-compliant Makefiles from template files
bash - 3.2.33-1 - A bourne style shell
bison - 2.3-2 - a general-purpose parser generator that converts an annotated context-free grammar into an LALR(1) or GLR parser for that gramm
bluez-hcidump - 1.42-1 - Bluetooth packet analyzer.
bluez-libs - 3.36-1 - Bluetooth libraries.
bluez-utils - 3.36-3 - Bluetooth utilities.
buildroot - 4.1.1-13 - uClibc compilation toolchain
bzip2 - 1.0.5-1 - Very high-quality data compression program
coreutils - 6.12-2 - Bunch of heavyweight *nix core utilities
cron - 4.1-7 - Standard vixie cron, with cron.d addition
cyrus-sasl-libs - 2.1.22-2 - Provides client or server side authentication (see RFC 2222).
dbus - 1.1.1-3 - D-Bus is a message bus system, a simple way for applications to talk to one another.
diffutils - 2.8.1-6 - contains gnu diff, cmp, sdiff and diff3 to display differences between and among text files
e2fslibs - 1.41.2-1 - Ext2 Filesystem Libraries
e2fsprogs - 1.41.2-1 - Ext2 Filesystem Utilities
expat - 2.0.1-1 - XML Parser library
file - 4.26-1 - Ubiquitous file identification utility.
findutils - 4.2.32-1 - File finding utilities
flex - 2.5.35-1 - Generates programs that perform pattern-matching on text.
fontconfig - 2.5.0-0 - Font configuration library
freetype - 2.3.6-1 - Free truetype library
gawk - 3.1.6-1 - Gnu AWK interpreter
gconv-modules - 2.2.5-7 - Provides gconv modules missing from the firmware. These are used by glibc iconv() implementation.
gdbm - 1.8.3-2 - GNU dbm is a set of database routines that use extensible hashing. It works similar to the standard UNIX dbm routines.
glib - 2.16.6-1 - The GLib library of C routines.
gpsd - 2.37-1 - A daemon that communicates with GPS receiver and provides data to other applications.
groff - 1.19.2-2 - front-end for the groff document formatting system
gzip - 1.2.4a-3 - GNU Zip data compression program
hdparm - 9.6-1 - Linux hard drive parameter utility
ipkg-opt - 0.99.163-10 - The Itsy Package Manager
less - 418-1 - Less file browser
libdb - 4.2.52-3 - Berkeley DB Libraries
libgd - 2.0.35-2 - An ANSI C library for the dynamic creation of images
libjpeg - 6b-2 - collection of jpeg tools
libpng - 1.2.34-1 - Portable Network Graphics Libraries
libtool - 1.5.24-1 - Library tools.
libuclibc++ - 0.2.2-8 - C++ standard library designed for use in embedded systems
libuclibc++ - 0.2.2-8 - C++ standard library designed for use in embedded systems
libxml2 - 2.7.2-1 - Libxml2 is the XML C parser and toolkit developed for the Gnome project.
lighttpd - 1.4.20-1 - A fast webserver with minimal memory footprint.
m4 - 1.4.12-1 - gnu macro processor and compiler front end
make - 3.81-2 - examines files and runs commands necessary for compilation
mc - 4.6.1-3 - Midnight Commander File Manager
microcom - 102-1 - A minicom-like serial terminal emulator with scripting support.
mysql - 4.1.22-2 - Popular free SQL database system
nano - 2.1.7-1 - A pico like editor
ncurses - 5.7-1 - NCurses libraries
ncursesw - 5.7-1 - NCurses libraries with wide char support.
neon - 0.28.3-1 - an HTTP and WebDAV client library, with a C interface
nload - 0.7.2-1 - Nload is a console application which monitors network traffic and bandwidth usage in real time
openldap-libs - 2.3.43-1 - Open Lightweight Directory Access Protocol
openssl - 0.9.7m-5 - Openssl provides the ssl implementation in libraries libcrypto and libssl, and is needed by many other applications and librari
optware-devel - 6.8-9 - This is a meta package that bundles all the packages required for optware native development.
patch - 2.5.9-3 - applies a diff to produce a patched file
pcre - 7.8-1 - Perl-compatible regular expression library
perl - 5.8.8-20 - Practical Extraction and Report Language.
pkgconfig - 0.15.0-1 - Package configuration tool
ppp - 2.4.3-1 - PPP is the Point-to-Point Protocol daemon.
procps - 3.2.7-6 - PROCPS System Utilities
python25 - 2.5.4-1 - Python is an interpreted, interactive, object-oriented programming language.
readline - 5.2-2 - The GNU Readline library provides a set of functions for use by applications that allow users to edit command lines as they are
rsync - 3.0.5-1 - fast remote file copy program (like rcp)
screen - 4.0.3-2 - A screen manager that supports multiple logins on single terminal
sed - 4.1.5-3 - Stream editor.
slang - 2.1.4-1 - S-Lang is a multi-platform library designed to allow a developer to create robust multi-platform software.
sqlite - 3.6.4-1 - SQLite is a small C library that implements a self-contained, embeddable, zero-configuration SQL database engine.
svn - 1.5.5-1 - a compelling replacement for CVS
tar - 1.21-1 - heavyweight version of the Tape ARchiver
termcap - 1.3.1-2 - Terminal emulation library
uclibc-opt - 0.9.28-13 - micro C library for embedded Linux systems
unrar - 3.7.8-1 - unrar is an application that can decompress files and archives created using the RAR compression scheme
unzip - 5.52-3 - A (de)compression library for the ZIP format
wget-ssl - 1.11.4-1 - A network utility to retrieve files from the Web
zip - 2.32-1 - a compression and file packaging utility.
zlib - 1.2.3-3 - zlib is a library implementing the 'deflate' compression system.

darius
06-01-2009, 22:24
maybe ur disk is full? it takes 42MB to download...

ok
what files, directories can I safely delete ?

is /opt/broadcom/src
really necessary
as I removed
cross-compilation
GPL_1927.zip
i
or is part of optware-devel ipkg
I installed ?


Darius

darius
07-01-2009, 13:47
Hi,

please follow this logfile and tell me what can be done
with the last error notice

configure: error: No curses header-files found

Darius
===============================================

[admin@oo dialog]$ ./configure --prefix=/opt/dialog
checking for package version... 1.1
checking for package patch date... 20080819
checking for gcc... gcc
checking for C compiler default output... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for executable suffix...
checking for object suffix... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking how to run the C preprocessor... ./configure: ./configure: 1898: egrep: not found
./configure: ./configure: 1898: egrep: not found
gcc -E
./configure: ./configure: 1975: egrep: not found
./configure: ./configure: 1975: egrep: not found
checking whether gcc needs -traditional... no
checking whether make sets ${MAKE}... yes
checking for ranlib... ranlib
checking for a BSD compatible install... /opt/bin/install -c
checking for ar... ar
checking for POSIXized ISC... no
checking for gcc option to accept ANSI C... none needed
checking for an ANSI C-conforming const... yes
checking for makeflags variable...
checking if filesystem supports mixed-case filenames... yes
checking for ctags... no
checking for etags... no
checking if you want to see long compiling messages... yes
checking build system type... mipsel-unknown-linux-gnu
checking host system type... mipsel-unknown-linux-gnu
Configuring for linux-gnu
checking if gcc -U and -D options work together... yes
checking if we must define _GNU_SOURCE... yes
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... 64
checking for _LARGE_FILES value needed for large files... no
checking for _LARGEFILE_SOURCE value needed for large files... no
checking for fseeko... yes
checking whether to use struct dirent64... no
checking version of gcc... 4.1.1
checking if you want to check for gcc warnings... no
checking for ANSI C header files... ./configure: ./configure: 4126: egrep: not f ound
no
checking for inline... inline
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for off_t... yes
checking for size_t... yes
checking for working alloca.h... yes
checking for alloca... yes
checking for stdlib.h... (cached) yes
checking for unistd.h... (cached) yes
checking for getpagesize... yes
checking for working mmap... yes
checking whether we are using the GNU C Library 2.1 or newer... no
checking for argz.h... ./configure: ./configure: 1: egrep: not found
no
checking for limits.h... ./configure: ./configure: 1: egrep: not found
yes
checking for locale.h... ./configure: ./configure: 1: egrep: not found
yes
checking for nl_types.h... ./configure: ./configure: 1: egrep: not found
yes
checking for malloc.h... ./configure: ./configure: 1: egrep: not found
yes
checking for stddef.h... ./configure: ./configure: 1: egrep: not found
yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for unistd.h... (cached) yes
checking for sys/param.h... ./configure: ./configure: 1: egrep: not found
yes
checking for feof_unlocked... yes
checking for fgets_unlocked... yes
checking for getcwd... yes
checking for getegid... yes
checking for geteuid... yes
checking for getgid... yes
checking for getuid... yes
checking for mempcpy... yes
checking for munmap... yes
checking for putenv... yes
checking for setenv... yes
checking for setlocale... yes
checking for stpcpy... yes
checking for strchr... yes
checking for strcasecmp... yes
checking for strdup... yes
checking for strtoul... yes
checking for tsearch... yes
checking for __argz_count... no
checking for __argz_stringify... no
checking for __argz_next... no
checking for iconv... yes
checking for iconv declaration...
extern size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, ch ar * *outbuf, size_t *outbytesleft);
checking for nl_langinfo and CODESET... yes
checking for LC_MESSAGES... yes
checking whether NLS is requested... no
checking if -lm needed for math functions... yes
checking if you want to use dmalloc for testing... no
checking if you want to use dbmalloc for testing... no
checking if you want to use purify for testing... no
checking if you want to use valgrind for testing... no
checking if you want to perform memory-leak testing...
checking if you want --trace option... yes
checking if you want to build libraries with libtool... no
checking for extra include directories... no
checking if we have identified curses headers... none
configure: error: No curses header-files found
[admin@oo dialog]$

darius
07-01-2009, 14:26
ncurses installed

--------------------------

Makefile

all:: ncurses

ncurses: ncurses.c
gcc -o $@ $? -lncurses

clean::
rm -f ncurses

.PHONY: clean

============


source file .c

#include <time.h>
#include <curses.h>

int current_getch;
int doloop = 1;
static WINDOW *mainwnd;
static WINDOW *screen;
WINDOW *my_win;

int now_sec, now_min, now_hour, now_day, now_wday, now_month, now_year;
time_t now;
struct tm *now_tm;

void screen_init(void) {
mainwnd = initscr();
noecho();
cbreak();
nodelay(mainwnd, TRUE);
refresh(); // 1)
wrefresh(mainwnd);
screen = newwin(13, 27, 1, 1);
box(screen, ACS_VLINE, ACS_HLINE);
}

static void update_display(void) {
curs_set(0);
mvwprintw(screen,1,1,"-------- HEADER --------");
mvwprintw(screen,3,6,"TIME: %d:%d:%d", now_hour, now_min, now_sec);
mvwprintw(screen,5,6,"DATE: %d-%d-%d", now_day, now_month, now_year);
mvwprintw(screen,7,6,"PRESS q TO END");
mvwprintw(screen,10,1,"-------- FOOTER --------");
wrefresh(screen);
refresh();
}

void screen_end(void) {
endwin();
}

void maketime(void) {
// Get the current date/time
now = time (NULL);
now_tm = localtime (&now);
now_sec = now_tm->tm_sec;
now_min = now_tm->tm_min;
now_hour = now_tm->tm_hour;
now_day = now_tm->tm_mday;
now_wday = now_tm->tm_wday;
now_month = now_tm->tm_mon + 1;
now_year = now_tm->tm_year + 1900;
}

int main(void) {
screen_init();
while (doloop) {
current_getch = getch();
if (current_getch == 113) {
doloop = 0;
}
maketime();
update_display();
sleep(1);
}
screen_end();
printf("TEST ENDS\n");
return 0;
}

============


[admin@oo ncurses]$ make
gcc -o ncurses ncurses.c -lncurses
ncurses.c:2:20: error: curses.h: No such file or directory
ncurses.c:6: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ncurses.c:7: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ncurses.c:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ncurses.c: In function 'screen_init':
ncurses.c:15: error: 'mainwnd' undeclared (first use in this function)
ncurses.c:15: error: (Each undeclared identifier is reported only once
ncurses.c:15: error: for each function it appears in.)
ncurses.c:18: error: 'TRUE' undeclared (first use in this function)
ncurses.c:21: error: 'screen' undeclared (first use in this function)
ncurses.c:22: error: 'ACS_VLINE' undeclared (first use in this function)
ncurses.c:22: error: 'ACS_HLINE' undeclared (first use in this function)
ncurses.c: In function 'update_display':
ncurses.c:27: error: 'screen' undeclared (first use in this function)
ncurses.c: In function 'main':
ncurses.c:65: warning: incompatible implicit declaration of built-in function 'printf'
make: *** [ncurses] Error 1

darius
13-01-2009, 10:33
Hi,

downloaded, unrarred and installed
ncurses by wpte

run
[admin@oo dialog]$ ./configure --prefix=/opt


.................
...
checking if we have identified curses headers... none
configure: error: No curses header-files found

Any idea how to get Linux dialog finally compiled ?

Darius

wpte
13-01-2009, 16:17
Hi,

downloaded, unrarred and installed
ncurses by wpte

run
[admin@oo dialog]$ ./configure --prefix=/opt


.................
...
checking if we have identified curses headers... none
configure: error: No curses header-files found

Any idea how to get Linux dialog finally compiled ?

Darius


are you sure you placed the files in the correct folder?
I get this output:

checking if we have identified curses headers... curses.h
checking for curses.h... yes

you can also specify the right dir with:
./configure --with-curses-dir=[the dir you installed ncruses in]

darius
13-01-2009, 17:57
are you sure you placed the files in the correct folder?
I get this output:


you can also specify the right dir with:
./configure --with-curses-dir=[the dir you installed ncruses in]

Ok.
So tell me the right installation procedure and how to start with,
step by step.
Where download ncurses-5.7.rar to
and what commands, switches should I use with
unrar ... ncurses-5.7.rar

Mayby I should use an installer for uncurses to chmod for directories ?

Darius

wpte
13-01-2009, 20:07
well... I expect people to look inside an archive before just extracting it anywhere:rolleyes:

the archive contains the folder opt, referring as your disk mounted as opt....

so if you use command line (and it works), you should first cd to home:

cd /
now you can unrar it I guess, if it works the same way as tar in commandline.

you can also extract it simply by winrar to a samba share of your /opt

darius
13-01-2009, 22:31
well... I expect people to look inside an archive before just extracting it anywhere:rolleyes:

the archive contains the folder opt, referring as your disk mounted as opt....

so if you use command line (and it works), you should first cd to home:

now you can unrar it I guess, if it works the same way as tar in commandline.

you can also extract it simply by winrar to a samba share of your /opt

Ok.
I downloaded your .tar twice.
First into root directory and started to unrar it.
(/opt as /is read only-system)
The process was very slow so I terminated it (/opt is low on memory)
and get it untarred into 3rd partition disc0_3
than copied /opt directory tree into /opt on the 2nd partition (home).
I was surprised to see all of archive files chmodded to 644
as binaries should get 755 mode.

Slow extracting of archives on /opt
worked really fast on /tmp/mnt
seting 644 mode to every extracted file.

Did your archive come with file attributes some set to 644 and some to 755 ?

Or should I set attributes manually ?

Darius

wpte
13-01-2009, 23:53
Did your archive come with file attributes some set to 644 and some to 755 ?

Or should I set attributes manually ?

Darius

If you unrar them via samba, the attributes should be allright.
note that winrar doesnt use any attributes!
so if you unrar it via command line you probably should.

darius
14-01-2009, 10:13
If you unrar them via samba, the attributes should be allright.
note that winrar doesnt use any attributes!
so if you unrar it via command line you probably should.

lost my message
========
Your submission could not be processed because you have logged in since the previous page was loaded.

Please push the back button and reload the previous window.
===========
rar doesn't preserve attributes (from the net).

set 755 to /opt/bin unrarred
what should I next ?

did you provide install script, as you keep requsting me to install
your rarred ncurses
and directory tree has no special install script
or /opt/ncurses directory

tried to download and unpack ncurses.ipkg
I installed from ipkg
unfortunately can't get it downloaded and saved to disk with wget or lynx .

(from the net)
tar can do the job to preserve file/directories attributes

The only install I can do is to copy your unrarred ncurses /opt tree
into root /opt tree

And finally, what is your suggestion for option directory to run
as I don't have specific directory for your unrarred and copied ncurses

so run ./configure as below
[admin@oo dialog]$ ./configure --prefix=/opt



checking if you want to build libraries with libtool... no
checking for extra include directories... no
checking if we have identified curses headers... none
configure: error: No curses header-files found
[admin@oo dialog]$


And the last but not least

Is your ncurses package not in conflict with ipkg ncurses package I have already installed ?
as I don't see it named as ncurses-devel

Darius

darius
14-01-2009, 12:15
If you unrar them via samba, the attributes should be allright.
note that winrar doesnt use any attributes!
so if you unrar it via command line you probably should.

Hi,
I got it from cache

==================

If you unrar them via samba, the attributes should be allright.
note that winrar doesnt use any attributes!
so if you unrar it via command line you probably should.

Ok.
I native downloaded and unrarred your archives.
Linux file system only no samba.

(from the net)
=============
Tar is an archiver that collects all files and attributes (important on Linux; not so very much on Windows) into one stream.

Obviously, you didn't read that rar archives do not preserve file attributes and permissions.


Re: D2X-XL posted by Anonymous @ 71.229.81.55 on Nov 17 2006 7:58 AM
Another issue with using rar and zip is that they don't allow for the enhanced linux file attributes, such as file ownership and so forth; making a backup of your system using rar will NOT give you a real "backup", but a disaster.
===========
Ok.
So I chmod 755 bin directory in untarred /opt
than copied into root /opt


------------------
BTW
ncurses is ipkg package I installed earlier from ipkg list
----------
ncurses - 5.7-1 - NCurses libraries
ncursesw - 5.7-1 - NCurses libraries with wide char support.


Is using ncurses developed by you in /opt not in conflict with the ncurses from ipkg ?


logfile
...
...
checking if we have identified curses headers... none
configure: error: No curses header-files found
[admin@oo dialog]$

So what attributes should I set for each of directories in your ncurses
(unrarred package).
/bin set to 755
is it ok
as I run compilation as admin ?

And what place is right for installation of ncurses, you have mentioned earlier,

"
you can also specify the right dir with:
./configure --with-curses-dir=[the dir you installed ncruses in]
"

I set ./configure --prefix=/opt
as your ncurses comes as /opt directory tree
so what is your suggestion
as you keep insisting on me to install unrarred ncurses.
Did you provide install script ?

As unrarred ncurses directory tree has not
/opt/ncurses directory
already created by me to native compile
ncurses.c program.



Tried to download and untar ncurses as ipk package to see
file /directory attributes
http://ipkg.nslu2-linux.org/feeds/optware/wl500g/cross/stable/
but can't get wget or http lynx to download and save it to disk.


Darius

=================

wpte
14-01-2009, 13:09
I don't understand what you want now...

if you just unrar it, ncurses should be installed. (so no extra script available now, maybe there should be linking, but as far as I know, it runs without any linking the headers)
you should see my build as a patch for the ipkg install.

darius
14-01-2009, 13:53
I don't understand what you want now...

read my post once again.

Your rarred ncurses come with mode set to 644 (so no execution rights)
So I unrarred your ncurses to temporary directory to see files modes
set to 644 for ever file, binaries either.
Changed mode for binaries to 755 and still nothing.

if you just unrar it, ncurses should be installed. (so no extra script available now, maybe there should be linking, but as far as I know, it runs without any linking the headers)

Ok.
Just have a look what Linux modes are respectively set to files in your ncurses and let me them know, especially binaries


you should see my build as a patch for the ipkg install.

ok.
don't you have tarzipped archives for download ?

I will try again.


=========
unrarred your ncurses from /opt directory
run
[admin@oo dialog]$ ./configure --prefix=/opt

and again

....
...

checking for extra include directories... no
checking if we have identified curses headers... none
configure: error: No curses header-files found
[admin@oo dialog]$


Could you c&p your logfile showing
your
[admin@oo dialog]$ ./configure --prefix=/opt

Did you installed ipkg ncurses first ,
than your patch ?

Have so successfully and finally compiled
Linux dialog and could you attach binaries to your post ?


Darius

darius
15-01-2009, 18:04
follow-up

installed patch as advised

cd /
untar /source/of/archives.tar.gz

run
[admin@oo dialog]$ ./configure --prefix=/opt
from Linux dialog sources directory



...
...
checking for extra include directories... no
checking if we have identified curses headers... none
configure: error: No curses header-files found
[admin@oo dialog]$

tried to compile ncurses based example c code from the net

[admin@oo ncurses]$ make
gcc -o ncurses ncurses.c -lncurses
ncurses.c:2:20: error: curses.h: No such file or directory
ncurses.c:6: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ncurses.c:7: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ncurses.c:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
ncurses.c: In function 'screen_init':
ncurses.c:15: error: 'mainwnd' undeclared (first use in this function)
ncurses.c:15: error: (Each undeclared identifier is reported only once
ncurses.c:15: error: for each function it appears in.)
ncurses.c:18: error: 'TRUE' undeclared (first use in this function)
ncurses.c:21: error: 'screen' undeclared (first use in this function)
ncurses.c:22: error: 'ACS_VLINE' undeclared (first use in this function)
ncurses.c:22: error: 'ACS_HLINE' undeclared (first use in this function)
ncurses.c: In function 'update_display':
ncurses.c:27: error: 'screen' undeclared (first use in this function)
ncurses.c: In function 'main':
ncurses.c:65: warning: incompatible implicit declaration of built-in function 'printf'
make: *** [ncurses] Error 1
[admin@oo ncurses]$

Any idea.
Example ncurses.c c code comes from net , Makefile either

Darius

darius
24-03-2009, 17:28
Hi,

tried to native compile Debian Dialog today as ncurses-dev is available.

What's wrong ?

Darius

run
./configure --prefix=/opt/dialog

[code]

[admin@oo dialog]$ ./configure --prefix=/opt/dialog
checking for package version... 1.1
checking for package patch date... 20080819
checking for gcc... gcc
checking for C compiler default output... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for executable suffix...
checking for object suffix... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking how to run the C preprocessor... ./configure: ./configure: 1898: egrep: not found
./configure: ./configure: 1898: egrep: not found
gcc -E
./configure: ./configure: 1975: egrep: not found
./configure: ./configure: 1975: egrep: not found
checking whether gcc needs -traditional... no
checking whether make sets ${MAKE}... yes
checking for ranlib... ranlib
checking for a BSD compatible install... /opt/bin/install -c
checking for ar... ar
checking for POSIXized ISC... no
checking for gcc option to accept ANSI C... none needed
checking for an ANSI C-conforming const... yes
checking for makeflags variable...
checking if filesystem supports mixed-case filenames... yes
checking for ctags... no
checking for etags... no
checking if you want to see long compiling messages... yes
checking build system type... mipsel-unknown-linux-gnu
checking host system type... mipsel-unknown-linux-gnu
Configuring for linux-gnu
checking if gcc -U and -D options work together... yes
checking if we must define _GNU_SOURCE... yes
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... 64
checking for _LARGE_FILES value needed for large files... no
checking for _LARGEFILE_SOURCE value needed for large files... no
checking for fseeko... yes
checking whether to use struct dirent64... no
checking version of gcc... 4.1.1
checking if you want to check for gcc warnings... no
checking for ANSI C header files... ./configure: ./configure: 4126: egrep: not found
no
checking for inline... inline
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for off_t... yes
checking for size_t... yes
checking for working alloca.h... yes
checking for alloca... yes
checking for stdlib.h... (cached) yes
checking for unistd.h... (cached) yes
checking for getpagesize... yes
checking for working mmap... yes
checking whether we are using the GNU C Library 2.1 or newer... no
checking for argz.h... ./configure: ./configure: 1: egrep: not found
no
checking for limits.h... ./configure: ./configure: 1: egrep: not found
yes
checking for locale.h... ./configure: ./configure: 1: egrep: not found
yes
checking for nl_types.h... ./configure: ./configure: 1: egrep: not found
yes
checking for malloc.h... ./configure: ./configure: 1: egrep: not found
yes
checking for stddef.h... ./configure: ./configure: 1: egrep: not found
yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for unistd.h... (cached) yes
checking for sys/param.h... ./configure: ./configure: 1: egrep: not found
yes
checking for feof_unlocked... yes
checking for fgets_unlocked... yes
checking for getcwd... yes
checking for getegid... yes
checking for geteuid... yes
checking for getgid... yes
checking for getuid... yes
checking for mempcpy... yes
checking for munmap... yes
checking for putenv... yes
checking for setenv... yes
checking for setlocale... yes
checking for stpcpy... yes
checking for strchr... yes
checking for strcasecmp... yes
checking for strdup... yes
checking for strtoul... yes
checking for tsearch... yes
checking for __argz_count... no
checking for __argz_stringify... no
checking for __argz_next... no
checking for iconv... yes
checking for iconv declaration...
extern size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
checking for nl_langinfo and CODESET... yes
checking for LC_MESSAGES... yes
checking whether NLS is requested... no
checking if -lm needed for math functions... yes
checking if you want to use dmalloc for testing... no
checking if you want to use dbmalloc for testing... no
checking if you want to use purify for testing... no
checking if you want to use valgrind for testing... no
checking if you want to perform memory-leak testing...
checking if you want --trace option... yes
checking if you want to build libraries with libtool... no
checking for extra include directories... no
checking if we have identified curses headers... curses.h
checking for curses.h... ./configure: ./configure: 1: egrep: not found
yes
checking for terminfo header... term.h
checking for ncurses version... 5.7.20081102
checking if we have identified curses libraries... no
checking for tgoto... no
checking for tgoto in -lncurses... yes
checking for initscr in -lncurses... yes
checking if you want extra dialogs... yes
checking if you want config-file support... yes
checking if you want Xdialog-style dialogs... yes
checking if you want the form dialog... yes
checking if you want the gauge dialog... yes
checking if you want the tailbox dialog... yes
checking if you want the mixedform dialog... yes
checking if you want the mixedgauge dialog... yes
checking if you want the wide-curses features... no
checking for ANSI C header files... (cached) no
checking whether time.h and sys/time.h may both be included... yes
checking for dirent.h that defines DIR... yes
checking for opendir in -ldir... no
checking for search.h... ./configure: ./configure: 1: egrep: not found
yes
checking for unistd.h... (cached) yes
checking for term.h... (cached) term.h
checking return type of signal handlers... void
checking for _nc_free_and_exit... yes
checking for strcasecmp... (cached) yes
checking for tsearch... (cached) yes
checking for waitpid... yes
checking if we must define _XOPEN_SOURCE_EXTENDED... unknown
checking for flushinp... yes
checking for getbegx... yes
checking for getbegy... yes
checking for getbegyx... yes
checking for getcurx... yes
checking for getcury... yes
checking for getmaxx... yes
checking for getmaxy... yes
checking for getmaxyx... yes
checking for getparx... yes
checking for getpary... yes
checking for getparyx... yes
checking for use_default_colors... yes
checking for wget_wch... no
checking for start_color... yes
checking for chtype typedef... yes
checking if chtype is scalar or struct... scalar
checking for sys/wait.h... ./configure: ./configure: 1: egrep: not found
yes
checking for union wait... no
checking if we must include wchar.h to declare mbstate_t... yes
configure: creating ./config.status
config.status: creating dialog-config
config.status: creating makefile
config.status: creating headers-sh
config.status: creating samples/install/makefile
config.status: creating dlg_config.h
config.status: dlg_config.h is unchanged
[admin@oo dialog]$

darius
24-03-2009, 17:30
follow-up

than run
make
what's wrong ?
Is system time an issue ?

Darius




/opt/include/ncursest/curses.h:753: error: previous declaration of 'wclrtobot' was here
./curses.h:681: error: conflicting types for 'wclrtoeol'
/opt/include/ncursest/curses.h:754: error: previous declaration of 'wclrtoeol' was here
./curses.h:682: error: conflicting types for 'wcolor_set'
/opt/include/ncursest/curses.h:755: error: previous declaration of 'wcolor_set' was here
./curses.h:683: error: conflicting types for 'wdelch'
/opt/include/ncursest/curses.h:757: error: previous declaration of 'wdelch' was here
./curses.h:684: error: expected declaration specifiers or '...' before '-' token
./curses.h:684: error: conflicting types for 'winsdelln'
/opt/include/ncursest/curses.h:770: error: previous declaration of 'winsdelln' was here
./curses.h:685: error: conflicting types for 'wechochar'
/opt/include/ncursest/curses.h:759: error: previous declaration of 'wechochar' was here
./curses.h:686: error: conflicting types for 'werase'
/opt/include/ncursest/curses.h:760: error: previous declaration of 'werase' was here
./curses.h:687: error: conflicting types for 'wgetch'
/opt/include/ncursest/curses.h:761: error: previous declaration of 'wgetch' was here
./curses.h:688: error: conflicting types for 'wgetnstr'
/opt/include/ncursest/curses.h:762: error: previous declaration of 'wgetnstr' was here
./curses.h:689: error: expected declaration specifiers or '...' before '-' token
./curses.h:689: error: conflicting types for 'wgetnstr'
/opt/include/ncursest/curses.h:762: error: previous declaration of 'wgetnstr' was here
./curses.h:690: error: conflicting types for 'whline'
/opt/include/ncursest/curses.h:764: error: previous declaration of 'whline' was here
./curses.h:691: error: conflicting types for 'winch'
/opt/include/ncursest/curses.h:765: error: previous declaration of 'winch' was here
./curses.h:692: error: conflicting types for 'winchnstr'
/opt/include/ncursest/curses.h:766: error: previous declaration of 'winchnstr' was here
./curses.h:693: error: expected declaration specifiers or '...' before '-' token
./curses.h:693: error: conflicting types for 'winchnstr'
/opt/include/ncursest/curses.h:766: error: previous declaration of 'winchnstr' was here
./curses.h:694: error: conflicting types for 'winnstr'
/opt/include/ncursest/curses.h:768: error: previous declaration of 'winnstr' was here
./curses.h:695: error: conflicting types for 'winsch'
/opt/include/ncursest/curses.h:769: error: previous declaration of 'winsch' was here
./curses.h:696: error: conflicting types for 'winsdelln'
/opt/include/ncursest/curses.h:770: error: previous declaration of 'winsdelln' was here
./curses.h:697: error: expected declaration specifiers or '...' before numeric constant
./curses.h:697: error: conflicting types for 'winsdelln'
/opt/include/ncursest/curses.h:770: error: previous declaration of 'winsdelln' was here
./curses.h:698: error: expected declaration specifiers or '...' before '-' token
./curses.h:698: error: conflicting types for 'winnstr'
/opt/include/ncursest/curses.h:768: error: previous declaration of 'winnstr' was here
./curses.h:699: error: conflicting types for 'wmove'
/opt/include/ncursest/curses.h:775: error: previous declaration of 'wmove' was here
./curses.h:700: error: conflicting types for 'wnoutrefresh'
/opt/include/ncursest/curses.h:776: error: previous declaration of 'wnoutrefresh' was here
./curses.h:702: error: conflicting types for 'wprintw'
/opt/include/ncursest/curses.h:778: error: previous declaration of 'wprintw' was here
./curses.h:703: error: conflicting types for 'wredrawln'
/opt/include/ncursest/curses.h:779: error: previous declaration of 'wredrawln' was here
./curses.h:704: error: conflicting types for 'wrefresh'
/opt/include/ncursest/curses.h:780: error: previous declaration of 'wrefresh' was here
./curses.h:705: error: conflicting types for 'wresize'
/opt/include/ncursest/curses.h:852: error: previous declaration of 'wresize' was here
./curses.h:707: error: conflicting types for 'wscanw'
/opt/include/ncursest/curses.h:782: error: previous declaration of 'wscanw' was here
./curses.h:708: error: conflicting types for 'wscrl'
/opt/include/ncursest/curses.h:783: error: previous declaration of 'wscrl' was here
./curses.h:709: error: conflicting types for 'wsetscrreg'
/opt/include/ncursest/curses.h:784: error: previous declaration of 'wsetscrreg' was here
./curses.h:710: error: expected declaration specifiers or '...' before numeric constant
./curses.h:710: error: conflicting types for 'wattrset'
/opt/include/ncursest/curses.h:743: error: previous declaration of 'wattrset' was here
./curses.h:711: error: expected declaration specifiers or '...' before numeric constant
./curses.h:711: error: conflicting types for 'wattrset'
/opt/include/ncursest/curses.h:743: error: previous declaration of 'wattrset' was here
./curses.h:712: error: conflicting types for 'wtimeout'
/opt/include/ncursest/curses.h:789: error: previous declaration of 'wtimeout' was here
./curses.h:713: error: conflicting types for 'wtouchln'
/opt/include/ncursest/curses.h:790: error: previous declaration of 'wtouchln' was here
./curses.h:716: error: conflicting types for 'wvline'
/opt/include/ncursest/curses.h:791: error: previous declaration of 'wvline' was here
make: *** [trace.o] Error 1
[admin@oo dialog]$

darius
24-03-2009, 17:32
dialog native compilation

another failed attemp

Darius



make
-----
...
.
/opt/include/ncursest/curses.h:753: error: previous declaration of 'wclrtobot' was here
./curses.h:681: error: conflicting types for 'wclrtoeol'
/opt/include/ncursest/curses.h:754: error: previous declaration of 'wclrtoeol' was here
./curses.h:682: error: conflicting types for 'wcolor_set'
/opt/include/ncursest/curses.h:755: error: previous declaration of 'wcolor_set' was here
./curses.h:683: error: conflicting types for 'wdelch'
/opt/include/ncursest/curses.h:757: error: previous declaration of 'wdelch' was here
./curses.h:684: error: expected declaration specifiers or '...' before '-' token
./curses.h:684: error: conflicting types for 'winsdelln'
/opt/include/ncursest/curses.h:770: error: previous declaration of 'winsdelln' was here
./curses.h:685: error: conflicting types for 'wechochar'
/opt/include/ncursest/curses.h:759: error: previous declaration of 'wechochar' was here
./curses.h:686: error: conflicting types for 'werase'
/opt/include/ncursest/curses.h:760: error: previous declaration of 'werase' was here
./curses.h:687: error: conflicting types for 'wgetch'
/opt/include/ncursest/curses.h:761: error: previous declaration of 'wgetch' was here
./curses.h:688: error: conflicting types for 'wgetnstr'
/opt/include/ncursest/curses.h:762: error: previous declaration of 'wgetnstr' was here
./curses.h:689: error: expected declaration specifiers or '...' before '-' token
./curses.h:689: error: conflicting types for 'wgetnstr'
/opt/include/ncursest/curses.h:762: error: previous declaration of 'wgetnstr' was here
./curses.h:690: error: conflicting types for 'whline'
/opt/include/ncursest/curses.h:764: error: previous declaration of 'whline' was here
./curses.h:691: error: conflicting types for 'winch'
/opt/include/ncursest/curses.h:765: error: previous declaration of 'winch' was here
./curses.h:692: error: conflicting types for 'winchnstr'
/opt/include/ncursest/curses.h:766: error: previous declaration of 'winchnstr' was here
./curses.h:693: error: expected declaration specifiers or '...' before '-' token
./curses.h:693: error: conflicting types for 'winchnstr'
/opt/include/ncursest/curses.h:766: error: previous declaration of 'winchnstr' was here
./curses.h:694: error: conflicting types for 'winnstr'
/opt/include/ncursest/curses.h:768: error: previous declaration of 'winnstr' was here
./curses.h:695: error: conflicting types for 'winsch'
/opt/include/ncursest/curses.h:769: error: previous declaration of 'winsch' was here
./curses.h:696: error: conflicting types for 'winsdelln'
/opt/include/ncursest/curses.h:770: error: previous declaration of 'winsdelln' was here
./curses.h:697: error: expected declaration specifiers or '...' before numeric constant
./curses.h:697: error: conflicting types for 'winsdelln'
/opt/include/ncursest/curses.h:770: error: previous declaration of 'winsdelln' was here
./curses.h:698: error: expected declaration specifiers or '...' before '-' token
./curses.h:698: error: conflicting types for 'winnstr'
/opt/include/ncursest/curses.h:768: error: previous declaration of 'winnstr' was here
./curses.h:699: error: conflicting types for 'wmove'
/opt/include/ncursest/curses.h:775: error: previous declaration of 'wmove' was here
./curses.h:700: error: conflicting types for 'wnoutrefresh'
/opt/include/ncursest/curses.h:776: error: previous declaration of 'wnoutrefresh' was here
./curses.h:702: error: conflicting types for 'wprintw'
/opt/include/ncursest/curses.h:778: error: previous declaration of 'wprintw' was here
./curses.h:703: error: conflicting types for 'wredrawln'
/opt/include/ncursest/curses.h:779: error: previous declaration of 'wredrawln' was here
./curses.h:704: error: conflicting types for 'wrefresh'
/opt/include/ncursest/curses.h:780: error: previous declaration of 'wrefresh' was here
./curses.h:705: error: conflicting types for 'wresize'
/opt/include/ncursest/curses.h:852: error: previous declaration of 'wresize' was here
./curses.h:707: error: conflicting types for 'wscanw'
/opt/include/ncursest/curses.h:782: error: previous declaration of 'wscanw' was here
./curses.h:708: error: conflicting types for 'wscrl'
/opt/include/ncursest/curses.h:783: error: previous declaration of 'wscrl' was here
./curses.h:709: error: conflicting types for 'wsetscrreg'
/opt/include/ncursest/curses.h:784: error: previous declaration of 'wsetscrreg' was here
./curses.h:710: error: expected declaration specifiers or '...' before numeric constant
./curses.h:710: error: conflicting types for 'wattrset'
/opt/include/ncursest/curses.h:743: error: previous declaration of 'wattrset' was here
./curses.h:711: error: expected declaration specifiers or '...' before numeric constant
./curses.h:711: error: conflicting types for 'wattrset'
/opt/include/ncursest/curses.h:743: error: previous declaration of 'wattrset' was here
./curses.h:712: error: conflicting types for 'wtimeout'
/opt/include/ncursest/curses.h:789: error: previous declaration of 'wtimeout' was here
./curses.h:713: error: conflicting types for 'wtouchln'
/opt/include/ncursest/curses.h:790: error: previous declaration of 'wtouchln' was here
./curses.h:716: error: conflicting types for 'wvline'
/opt/include/ncursest/curses.h:791: error: previous declaration of 'wvline' was here
make: *** [trace.o] Error 1


[admin@oo dialog]$

darius
26-03-2009, 14:38
...

LEDIR=\"/opt/dialog/share/locale\" -c dialog.c
gcc -o dialog dialog.o -L. -ldialog -lncurses -lm -L/lib
[admin@oo dialog]$ make install
making install
./mkdirs.sh /opt/dialog/bin
mkdir /opt/dialog/bin
/opt/bin/install -c dialog /opt/dialog/bin/`echo dialog |sed s,x,x,`
./mkdirs.sh /opt/dialog/man/man1
mkdir /opt/dialog/man
mkdir /opt/dialog/man/man1
/opt/bin/install -c -m 644 ./dialog.1 /opt/dialog/man/man1/`echo dialog |sed s,x,x,`.1
made install
[admin@oo dialog]$ dialog
-sh: dialog: not found
[admin@oo dialog]$ cd .
[admin@oo dialog]$ /
-sh: /: Permission denied
[admin@oo dialog]$ cd .
[admin@oo dialog]$ cd ..
[admin@oo /opt]$ cd ..
[admin@oo /]$ mc



[admin@oo /]$ dialog
-sh: dialog: not found
[admin@oo /]$ cd opt/dialog
[admin@oo dialog]$ dialog
-sh: dialog: not found

[admin@oo samples]$ editbox
-sh: editbox: not found
[admin@oo samples]$ sh editbox
[admin@oo samples]$ sh dialog .msgbox .Hello from the Linux Blog!. 5 50
sh: Can't open dialog
[admin@oo samples]$


Darius

DrChair
26-03-2009, 22:57
i'd look in /opt/dialog/bin

darius
26-03-2009, 23:47
i'd look in /opt/dialog/bin

Thanks.
Exactly the case, I am just testing.
What I need is to set profile and environment
to let me run dialog from a command line.

It works, really works, thanks to ncurses-dev library compiled by al37919.

Tribute goes to al37919 and others, who supported my efforts in the last 3 months.

Darius

al37919
27-03-2009, 08:04
darius, I'm pretty happy that I succeeded to help you somehow, however, as moderator of Russian forum I cleaned up your activity there. It includes 9 topics about this fucking dialog. I see at least ten more topics about the same question in other forums over which I don't have authority.

Read carefully this: http://wl500g.info/faq.php?faq=general#faq_the_rules

Especially the following:
Try to solve your problem first!
Always read the manual and take a look at the support page of the manufacturer. Try searching google, google groups and offcourse the search function at the forum. A lot of FAQs at other forums have solutions. If a question ... is easy to solve or find yourself, than it is not the intention to post it here.
Post your topic in the right forum.
Place a topic only once in one forum (no double or cross posting)

By violations of these rules you show your disrespect to the community.

Please, treat this message as official warning

darius
27-03-2009, 14:45
follow up

did exactly the same as someone on Linux forum advised me to do yesterday
and again today

PATH=$PATH:/opt/dialog/bin
export PATH

than
flashfs save && flashfs commit && flashfs enable && reboot

and on reboot

[admin@oo root]$ dialog
-sh: dialog: not found
[admin@oo root]$ ./dialog
-sh: ./dialog: not found
[admin@oo root]$ cd /
[admin@oo /]$ cd opt/dialog/bin
[admin@oo bin]$ ./dialog
cdialog (ComeOn Dialog!) version 1.1-20080819
Copyright 2000-2007,2008 Thomas E. Dickey
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

* Display dialog boxes from shell scripts *

Did edited /profile files manually, appending path /opt/dialog/bin
and still no result.

Any solution ?

Darius




darius, I'm pretty happy that I succeeded to help you somehow, however, as moderator of Russian forum I cleaned up your activity there. It includes 9 topics about this fucking dialog. I see at least ten more topics about the same question in other forums over which I don't have authority.

Read carefully this: http://wl500g.info/faq.php?faq=general#faq_the_rules

Especially the following:
• Try to solve your problem first!
Always read the manual and take a look at the support page of the manufacturer. Try searching google, google groups and offcourse the search function at the forum. A lot of FAQs at other forums have solutions. If a question ... is easy to solve or find yourself, than it is not the intention to post it here.
• Post your topic in the right forum.
• Place a topic only once in one forum (no double or cross posting)

By violations of these rules you show your disrespect to the community.

Please, treat this message as official warning

My dear friend,

the following comes exactly from the same FAQ
"
Placing a reply
• Be helpfull at all times.
• Show respect for other users and the forum.
• Keep reactions ontopic.
"
Try to solve your problem first!

Exactly. I tried to compile dialog many times, library provided by wpte.
Failed.
It was you, who has compiled curses.h and published on Russian forum.
I am really not experienced to do that job on myself.

Linux dialog is very basic interactive tool in Linux.
So I did expected dialog to be part of ipkg.

English and Russian forums are made of really experienced Linux developers,
so if you claim, 8 or 10 requests for help, generated no response,
so why should expect to get any help from Google search, if the problem
is Asus router related only.

And why do you call highly intelligent interactive tool for testing and running shell scripts a "fucked dialog" ?

Asus router WL-500gP V2 is my only Linux machine.
Another is Nokia Internet Tablet, running Debian and dialog of course,
coming already compiled, no installation needed at all.

So what is "fucked dialog" for you is highly valued Linux application for me.

I respect the community, I asked always relevant questions and got or didn't get replies.
Russian forum is more active than english.

If you care for russian on russian forum, no problem.
I can translate my questions into russian.

And finally.
It was only you, you have helped me with ncurses library.

Now I have to go to other Linux forums, looking for help, how to configure
environment, my user profile to have dialog be run from a command line.

I have 4 Linux books on my desk and no word about it.

Darius

DrChair
27-03-2009, 18:44
follow up

did exactly the same as someone on Linux forum advised me to do yesterday
and again today

PATH=$PATH:/opt/dialog/bin
export PATH

than
flashfs save && flashfs commit && flashfs enable && reboot


PATH isn't stored in flashfs, so that's useless

Just add it to the PATH statement in /tmp/etc/profile and save the flash

darius
27-03-2009, 20:14
PATH isn't stored in flashfs, so that's useless

Just add it to the PATH statement in /tmp/etc/profile and save the flash

Hi,
save the flash stays for what ?

Darius

forum search for /tmp/etc/profile
only 4 search results
http://wl500g.info/search.php?searchid=2844818



wengi
http://wl500g.info/showthread.php?t=10432&highlight=%2Ftmp%2Fetc%2Fprofile&page=2

Weil /tmp flchtig ist!
Du musst das entweder auf Deiner Platte (/opt) oder im Flash speichern und Deine post-boot dementsprechen anpassen.

wengi

http://wl500g.info/showthread.php?t=10432&highlight=%2Ftmp%2Fetc%2Fprofile


newbiefan
http://wl500g.info/showthread.php?t=12527&highlight=%2Ftmp%2Fetc%2Fprofile


"
When your progs are not found in /opt/bin aso., it looks like your profile is not complete: cat /tmp/etc/profile should show you all dirs where progs/binaries/scripts are stored. If necessary, you can edit your profile with vi and store it with flashfs save && flashfs commit && flashfs enable && reboot

But usually when installing everything according howto, it should be there.
Anyhow, just to allow you a comarision, find attached my profile.

http://wl500g.info/attachment.php?attachmentid=2298&d=1200862935
# /etc/profile

export PATH=/opt/sbin:/opt/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
export PS1="[\u@\h \W]\$ "

[ -x /usr/local/etc/profile ] && . /usr/local/etc/profile
[ -x /opt/etc/profile ] && . /opt/etc/profile

"


by wengi
http://wl500g.info/showthread.php?t=10307

14. Adjust profile
To make life easier at the command promt you will add some alias.
Code:

vi /opt/etc/profile

The file should be executable (chmod ...).
The content (Edit the nload settings!):
Quote:
# Some alias for making life easier

# To start nload with DSL 6000 settings: 'nld'
alias nld="nload -t 200 -s 7 -i 6656 -o 640 -u H eth1"

# Make ls default -la with color coding
alias ls="ls --color=auto -la"

# Make pss a grep ps function
alias pss="ps axf | grep"

# df human readable (Only works with coreutils installed!)
# alias df="df -h"
There is one more line if you installed midnight commander.

Make it executable:
Code:

chmod +x /opt/etc/profile

Save, reboot:
Code:

flashfs save && flashfs commit && flashfs enable && reboot

You can verify your modification by entering 'alias':
Quote:
[admin@blechbuechse root]$ alias
ls='ls --color=auto -la'
nld='nload -t 200 -s 7 -i 6656 -o 640 -u H eth1'
pss='ps axf | grep'

darius
27-03-2009, 22:07
PATH isn't stored in flashfs, so that's useless

Just add it to the PATH statement in /tmp/etc/profile and save the flash

follow-up 2

path /opt/dialog/bin
is already in my /opt/etc/profile
so saved in the flash, as /opt is part2 on HDD flash stick


# Bash initialization script
#

PS1="[\u@\h \W]$ "
PATH=/opt/dialog/bin:/opt/sbin:/opt/bin:/sbin:/bin:/usr/sbin:/usr/bin
LD_LIBRARY_PATH=/opt/lib:${LD_LIBRARY_PATH}

export PS1 PATH LD_LIBRARY_PATH


-----
follow-up 3

Problem solved by my friend
Now I can run dialog examples from a command line.

Darius

dp79
30-08-2009, 00:09
Hi,

I followed wpte's tutorial, but I get this error right after installing optware-devel and buildroot:


-sh: ./configure: not found

What am I missing?

BTW... I'm trying to compile aircrack-ng (for having airodump working only)

Cheers,
dp79

dp79
30-08-2009, 11:28
Well...I just found out, that it doesn't work, because the aircrack-ng tarball doesn't contain "configure" file. Anyway, I kept searching and I found a solution for openwrt (running on a fonera). Could anybody tell me if anything similar can be done on oleg's firmware?

The original in Spanish: http://www.bitsdelocos.es/2009/08/portando-aircrack-ng-1-0-a-la-fonera/

Translated to English: http://translate.google.hu/translate?js=y&prev=_t&hl=hu&ie=UTF-8&u=http%3A%2F%2Fwww.bitsdelocos.es%2F2009%2F08%2Fpo rtando-aircrack-ng-1-0-a-la-fonera%2F&sl=es&tl=en&history_state0=

Many thanks ahead!

Cheers,
dp79

wpte
30-08-2009, 15:15
Well...I just found out, that it doesn't work, because the aircrack-ng tarball doesn't contain "configure" file. Anyway, I kept searching and I found a solution for openwrt (running on a fonera). Could anybody tell me if anything similar can be done on oleg's firmware?

The original in Spanish: http://www.bitsdelocos.es/2009/08/portando-aircrack-ng-1-0-a-la-fonera/

Translated to English: http://translate.google.hu/translate?js=y&prev=_t&hl=hu&ie=UTF-8&u=http%3A%2F%2Fwww.bitsdelocos.es%2F2009%2F08%2Fpo rtando-aircrack-ng-1-0-a-la-fonera%2F&sl=es&tl=en&history_state0=

Many thanks ahead!

Cheers,
dp79

when the ./configure file is not there... you can create it yourself in most cases by executing:

autoconf
(will make some errors pop up about perl, no worries about that tho)
and if that doesn't work, you usually need to edit the makefile, for setting the prefix etc.
always read the text files like "readme", "INSTALL" before trying to compile something;)

dp79
01-09-2009, 17:32
Hi wpte!

Actually the readme only instructs to run the make and install commands, so there in no word about configuring anything. Autoconf says that it requires an input file, which obviously is not among the files in directory. According to the Spanish solution, I guess we don't need to run ./configure, we only need to edit the makefile. The problem is that I don't know the parameters for Oleg's firmware...

Thanks a lot for you guidance again!

dp79