delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=0.9 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,TW_LN |
X-Spam-Check-By: | sourceware.org |
Message-ID: | <4BF15EC1.5050909@gmail.com> |
Date: | Mon, 17 May 2010 16:20:33 +0100 |
From: | Dave Korn <dave DOT korn DOT cygwin AT gmail DOT com> |
Reply-To: | Cygwin Mailing List <cygwin AT cygwin DOT com> |
User-Agent: | Thunderbird 2.0.0.17 (Windows/20080914) |
MIME-Version: | 1.0 |
To: | Cygwin Mailing List <cygwin AT cygwin DOT com> |
CC: | Luis Vital <lvital DOT mail AT gmail DOT com> |
Subject: | Re: NCurses |
References: | <B7B82A8978F44899B941945E1CA4A5FC AT paikea> |
In-Reply-To: | <B7B82A8978F44899B941945E1CA4A5FC@paikea> |
X-IsSubscribed: | yes |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
On 17/05/2010 15:50, Luis Vital wrote: > Hi Dave, > > I appologise for comming back to you but I am experiencing some problems > with NCurses under Cygwin. Hi Luis, Please keep the discussion on the list, for all the reasons described at http://cygwin.com/acronyms/#PPIOSPE. > As they say on the documentation I wrote this program: > > #include <ncurses.h> > int main() > { > initscr(); /* Start curses mode */ > printw("Hello World !!!"); /* Print Hello World */ > refresh(); /* Print it on to the real screen */ > getch(); /* Wait for user input */ > endwin(); /* End curses mode */ > > return 0; > } > > I compile it with: gcc Hello.c -lncurses > > But I got the folowing error messages: > > /tmp/ccnsdh1e.o:Hello.c:(.text+0x3c): undefined reference to `_stdscr' > /tmp/ccnsdh1e.o:Hello.c:(.text+0x49): undefined reference to `_stdscr' That's peculiar, it shouldn't have worked at all. The "ncurses.h" file doesn't live in /usr/include directly, but in a subdir called /usr/include/ncurses, so with your #include statement as you have it there, I get: > $ gcc h.c -lncurses > h.c:1:21: error: ncurses.h: No such file or directory when I try to compile your example. If I change the example to #include "ncurses/ncurses.h", I get a fully working compile. It seems possible you have a bogus ncurses.h in your /usr/include, for some reason? You should make sure you have installed the regular cygwin libncurses-devel package (using setup.exe) to get the ncurses headers and link libraries (maybe you should try reinstalling it even if you do already have it). cheers, DaveK -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |