RE: Execute "ssh-host-config" from Windows command-line (or from a C program)

2007-04-03 Thread Fabio Román Arbelo



  Right, that's what you'd expect, because the backticks mean "execute this
command, then substitute all the output it generates in place on the command
line".  So you're telling bash to run ssh-host config and then treat all the
messages it outputs as commands to execute!

  Also, because you didn't pass --login to bash, it hasn't run .bashrc or any
of the other things that would set the path, which might account for some of
the 'command not found' problems.

  Also, you just trashed ssh-host-config by using u2d when what was suggested
was in fact d2u.  You'd better go and d2u it now.  Perhaps twice, just to be
on the safe side.  Then try that first command again, but remove the
backticks.

cheers,
  DaveK
--
Can't think of a witty .sigline today


Ok, now it works.

   c:\cygwin\bin> d2u ssh-host-config
   c:\cygwin\bin> bash --login -c "/bin/ssh-host-config -y -c "ntsec" 
-p 1"


Thanks very much for your help!


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



[Packaging error] gnome-icon-theme-2.14.2-1

2007-04-03 Thread Dr. Volker Zell
Hi

/usr/share/pkgconfig/gnome-icon-theme.pc from gnome-icon-theme-2.14.2-1
should be in /usr/lib/pkgconfig/gnome-icon-theme.pc

Ciao
  Volker


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



[Packaging error] Re: [ANNOUNCEMENT] Updated: mingw-runtime-3.12-1

2007-04-03 Thread Dr. Volker Zell
> Chris Sutcliffe writes:

> I've made a new version of the mingw-runtime available for download.
> For a list of changes see below.

Man pages should go to /usr/share/man/...

Ciao
  Volker


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



[Packaging error] Re: [ANNOUNCEMENT] Updated: bsflite-0.82-2

2007-04-03 Thread Dr. Volker Zell
> Jonathan C Allen writes:

> PACKAGE DESCRIPTION
> ===

> BSFlite - A minimalist console AIM client

Man pages should go to /usr/share/man/...

Ciao
  Volker


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



[Packaging error] Re: [ANNOUNCEMENT] Updated: fltk-1.1.8r5648

2007-04-03 Thread Dr. Volker Zell
> Teun Burgers writes:

> NEWS:
> =
> fltk is now released in 4 parts

> - fltk-doc:   HTML documentation, man-pages, sample code

The following man pages should be removed from the package:

/usr/share/man/cat1/fltk-config.1.gz
/usr/share/man/cat1/fluid.1.gz
/usr/share/man/cat3/fltk.3.gz

Ciao
  Volker


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: [ANNOUNCEMENT] Updated Cygwin Package: fetchmail-6.3.6-1

2007-04-03 Thread Dr. Volker Zell
> Jason Tishler writes:

> New News:
> === 
> I have updated the version of fetchmail to 6.3.6-1.  The tarballs should
> be available on a Cygwin mirror near you shortly.

> The only change between this version and the previous one is the
> following:

> o update to version 6.3.6

The following files

/usr/lib/python2.4/
/usr/lib/python2.4/site-packages/
/usr/lib/python2.4/site-packages/fetchmailconf.py
/usr/lib/python2.4/site-packages/fetchmailconf.pyc
/usr/lib/python2.4/site-packages/fetchmailconf.pyo

should go to /usr/lib/python2.5 now that python2.5 is out.

Ciao
  Volker


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



[ANNOUNCEMENT] Updated: asciidoc-8.2.0-1

2007-04-03 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

A new version of the asciidoc package, asciidoc 8.2.0-1, is now available
for download, replacing 8.1.0-1 as current.

NEWS:
=
This is a new upstream release, and converts to python 2.5 instead of 2.4.
  Upstream changes are attached.  See also the package documentation in
/usr/share/doc/asciidoc-8.2.0/.

DESCRIPTION:

AsciiDoc is a text document format for writing short documents, articles,
books and UNIX man pages. AsciiDoc files can be translated to HTML and
DocBook markups using the asciidoc(1) command. AsciiDoc is highly
configurable: both the AsciiDoc source file syntax and the backend output
markups (which can be almost any type of SGML/XML markup) can be
customized and extended by the user.

UPDATE:
===
To update your installation, click on the "Install Cygwin now" link on the
http://cygwin.com/ web page.  This downloads setup.exe to your system.
Save it and run setup, answer the questions and pick up 'asciidoc' from
the 'Devel' category.

DOWNLOAD:
=
Note that downloads from sources.redhat.com (aka cygwin.com) aren't
allowed due to bandwidth limitations.  This means that you will need to
find a mirror which has this update, please choose the one nearest to you:
http://cygwin.com/mirrors.html

QUESTIONS:
==
If you want to make a point or ask a question the Cygwin mailing list is
the appropriate place.

- --
Eric Blake
volunteer cygwin asciidoc maintainer

CYGWIN-ANNOUNCE UNSUBSCRIBE INFO:
=
To unsubscribe to the cygwin-announce mailing list, look at the
"List-Unsubscribe: " tag in the email header of this message.  Send email
to the address specified there.  It will be in the format:

[EMAIL PROTECTED]

If you need more information on unsubscribing, start reading here:

http://sources.redhat.com/lists.html#unsubscribe-simple

Please read *all* of the information on unsubscribing that is available
starting at this URL.
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.5 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGElQF84KuGfSFAYARAk3hAKC4PQi8ewNbyNFxbRRbxCt4zhTNFwCgvENd
1E7oHgRob+tAQ2/cIhvVx5Y=
=BM7w
-END PGP SIGNATURE-
Version 8.2.0 (2007-04-04)

   Additions and changes
 * A Vim syntax file is now included in the AsciiDoc distribution
   (inspired by Felix Obenhuber's asciidoc.vim script). You can find
   it (along with a Vim filetype detection script in the distribution
   ./vim/ directory (the scripts are installed automatically by the
   AsciiDoc installer ./install.sh). See Appendix J of the AsciiDoc
   User Guide for details.
 * Added toclevel attribute (1..4) which sets the number of title
   levels reported in the table of contents. Defaults to 2 and must
   be used with the toc attribute. Example usage:

 $ asciidoc -a toc -a toclevels=3 doc/asciidoc.txt
 * Added a listindex attribute which is the current list item index
   (1..). If this attribute appears outside a list its value is the
   number of items in the most recently closed list.
 * The single line titles syntax now accepts trailing suffixes --
   this syntax matches the title line syntax of a number of popular
   Wiki markups.
 * If a QuoteBlock has no attribution or citetitle then the DocBook
element is not generated (previously generated empty
element).
 * If the text of a labeled list item is blank then no texttag is
   written.
 * An end of line backslash performs line continuation for horizontal
   labeled list items.
 * The Revision line now accommodates Subversion $Id markers (in
   addition to CVS and RCS markers). Thanks to Tiago Sturmer Daitx
   for this patch.
 * Implemented a2x(1) option --skip-asciidoc which allows a2x(1) to
   convert DocBook XML files not derived from AsciiDoc sources.
 * If a2x(1) --doctype option is not specified it defaults to manpage
   if --format=manpage else defaults to article (previously --doctype
   always defaulted to article).
 * Added an External Resources section to the [1]AsciiDoc home page.

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/

Re: Varibles not working in do loop...

2007-04-03 Thread Kevin Markle

Larry Hall (Cygwin) formulated on Monday :

Andrew Louie wrote:

On 4/2/07, Kevin Markle  wrote:

Larry Hall (Cygwin) expressed precisely :
> Kevin Markle wrote:



What does this mean please and or would you send me your copy that
works fine?
"$LOG" == > "".  In these cases, the "hang" is 'cat' waiting for input
from the command
> line.


I think he means that in the line:


UPDATES_NEEDED=`cat $LOG | grep "updates detected" | tail -1`


cat $LOG... will hang if $LOG == "" because "cat" is waiting for input.



Precisely.


That helps but my problem is the line above where it get the value for 
LOG for whatever reason doesn't get the value of LOG in the for loop 
but can outside of the loop... :o)





--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: SIGTSTP and select

2007-04-03 Thread Bob Rossi
On Mon, Apr 02, 2007 at 08:37:53PM -0400, Christopher Faylor wrote:
> On Mon, Apr 02, 2007 at 08:07:23PM -0400, Bob Rossi wrote:
> >I'm not exactly sure what has changed since the last release to cause
> >this issue. However, here it is.
> >
> >When ctrl-z is typed, CGDB receives a SIGTSTP on both linux and cygwin.
> >When CGDB is at the select loop and this happens on linux select returns
> >-1 and errno is set to EINTR. My code simple does a 'continue' when this
> >happens and the select loop is reentered. All works well. On cygwin,
> >select does not return with -1. (I didn't check the return value but I
> >can, I just compare to -1 in an if statement). In fact, select also
> >detects that input is ready on stdin. This causes CGDB to get to a read
> >system call (which is non blocking) and the read system call fails with
> >errno set to EAGAIN. This causes CGDB to exit.
> >
> >The main loop looks something like this,
> >  if (select (max + 1, &rset, NULL, NULL, NULL) == -1)
> >{ 
> >  if (errno == EINTR)
> >continue;
> >  ..
> >}
> >
> >  if (FD_ISSET (STDIN_FILENO, &rset)) {
> >handle_stdin
> >  }
> >
> >So, my question is, is there a bug with select on cygwin? Is select
> >working properly and I should handle the read call differently? Why does
> >it act differently than linux?
> 
> You say that something changed between different releases but you don't
> mention what those releases are.  Is this releases of Cygwin?  If so,
> what releases?
> 
> If this is as easy to demonstrate as you say, then a simple test case
> is definitely called for.

Hi Christopher,

Attached is the test case. If I run it under linux, and then type ctrl-z, I 
never get into the user_input_loop call. If I run it in cygwin, I do.

Hopefully I'm doing something wrong here. Please advise!

Thanks,
Bob Rossi

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: Varibles not working in do loop...

2007-04-03 Thread Dave Korn
On 03 April 2007 15:07, Kevin Markle wrote:

> Larry Hall (Cygwin) formulated on Monday :
>> Andrew Louie wrote:
>>> On 4/2/07, Kevin Markle  wrote:
 Larry Hall (Cygwin) expressed precisely :
> Kevin Markle wrote:
>>> 
 What does this mean please and or would you send me your copy that works
 fine? "$LOG" == > "".  In these cases, the "hang" is 'cat' waiting for
 input from the command
> line.
>>> 
>>> I think he means that in the line:
>>> 
 UPDATES_NEEDED=`cat $LOG | grep "updates detected" | tail -1`
>>> 
>>> cat $LOG... will hang if $LOG == "" because "cat" is waiting for input.
>>> 
>> 
>> Precisely.
> 
> That helps but my problem is the line above where it get the value for
> LOG for whatever reason doesn't get the value of LOG in the for loop
> but can outside of the loop... :o)

  You mean this line?

LOG=`ls -al $DIR | grep $t | grep WINDOWS`

  You're listing the contents of the directory, trying to find the one line
that contains the name of the file ($t) you're currently considering.  Then
you're using grep a second time to only select (from that one line) any lines
that contain the text 'WINDOWS'.  Presumably none of the files in
1group_1a_dev_clientlist.out have the word "WINDOWS" in their name.

  What are you *trying* to do with that second grep?

cheers,
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: SIGTSTP and select

2007-04-03 Thread Bob Rossi
On Tue, Apr 03, 2007 at 10:13:20AM -0400, Bob Rossi wrote:
> On Mon, Apr 02, 2007 at 08:37:53PM -0400, Christopher Faylor wrote:
> > On Mon, Apr 02, 2007 at 08:07:23PM -0400, Bob Rossi wrote:
> > >I'm not exactly sure what has changed since the last release to cause
> > >this issue. However, here it is.
> > >
> > >When ctrl-z is typed, CGDB receives a SIGTSTP on both linux and cygwin.
> > >When CGDB is at the select loop and this happens on linux select returns
> > >-1 and errno is set to EINTR. My code simple does a 'continue' when this
> > >happens and the select loop is reentered. All works well. On cygwin,
> > >select does not return with -1. (I didn't check the return value but I
> > >can, I just compare to -1 in an if statement). In fact, select also
> > >detects that input is ready on stdin. This causes CGDB to get to a read
> > >system call (which is non blocking) and the read system call fails with
> > >errno set to EAGAIN. This causes CGDB to exit.
> > >
> > >The main loop looks something like this,
> > >  if (select (max + 1, &rset, NULL, NULL, NULL) == -1)
> > >{ 
> > >  if (errno == EINTR)
> > >continue;
> > >  ..
> > >}
> > >
> > >  if (FD_ISSET (STDIN_FILENO, &rset)) {
> > >handle_stdin
> > >  }
> > >
> > >So, my question is, is there a bug with select on cygwin? Is select
> > >working properly and I should handle the read call differently? Why does
> > >it act differently than linux?
> > 
> > You say that something changed between different releases but you don't
> > mention what those releases are.  Is this releases of Cygwin?  If so,
> > what releases?
> > 
> > If this is as easy to demonstrate as you say, then a simple test case
> > is definitely called for.
> 
> Hi Christopher,
> 
> Attached is the test case. If I run it under linux, and then type ctrl-z, I 
> never get into the user_input_loop call. If I run it in cygwin, I do.
> 
> Hopefully I'm doing something wrong here. Please advise!

Ouch. Attached.

Bob Rossi
#include 
#include 
#include 
#include 
#include 
#include 
#include 

static struct termios term_attributes;

int 
tty_cbreak (int fd, struct termios *orig)
{
  struct termios buf;
   
  if (tcgetattr (fd, &buf) < 0)
return -1;

  /* Save the original state, for resetting later */
  *orig = buf;
  
  buf.c_lflag &= ~(ECHO | ICANON);
  buf.c_iflag &= ~(ICRNL | INLCR);
  buf.c_cc[VMIN] = 1;
  buf.c_cc[VTIME] = 0;

#if defined (VLNEXT) && defined (_POSIX_VDISABLE)
  buf.c_cc[VLNEXT] = _POSIX_VDISABLE;
#endif

#if defined (VDSUSP) && defined (_POSIX_VDISABLE)
  buf.c_cc[VDSUSP] = _POSIX_VDISABLE;
#endif

  if (tcsetattr (fd, TCSAFLUSH, &buf) < 0)
return -1;

  return 0;   
}

int 
tty_set_attributes (int fd, struct termios *buf)
{
  if (tcsetattr (fd, TCSAFLUSH, buf) < 0)
return -1;
  
  return 0;   
}

int
user_input_loop ()
{
   fprintf (stderr, "HERE\r\n");
   return 0;
}

static int
main_loop (void)
{
  fd_set rset;
  int max = STDIN_FILENO;

  for (;;)
  {
 /* Reset the fd_set, and watch for input from GDB or stdin */
 FD_ZERO (&rset);

 FD_SET (STDIN_FILENO, &rset);

 /* Wait for input */
 if (select (max + 1, &rset, NULL, NULL, NULL) == -1)
 {
if (errno == EINTR)
   continue;
else
{
   fprintf (stderr, __FILE__, __LINE__,
 "select failed: %s", strerror (errno));
   return -1;
}
 }

 /* Input received:  Handle it */
 if (FD_ISSET (STDIN_FILENO, &rset)) {
if (user_input_loop () == -1)
   return -1;
 }
  }

  return 0;
}

int
main (int argc, char *argv[])
{
  if (tty_cbreak (STDIN_FILENO, &term_attributes) == -1)
{
  fprintf (stderr, __FILE__, __LINE__, "tty_cbreak error");
  exit (-1);
}

  /* Enter main loop */
  main_loop ();

  if (tty_set_attributes (STDIN_FILENO, &term_attributes) == -1)
fprintf (stderr, __FILE__, __LINE__, "tty_reset error");

  return 0;
}

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/

Re: Varibles not working in do loop...

2007-04-03 Thread Kevin Markle

Dave Korn pretended :

On 03 April 2007 15:07, Kevin Markle wrote:


Larry Hall (Cygwin) formulated on Monday :

Andrew Louie wrote:

On 4/2/07, Kevin Markle  wrote:

Larry Hall (Cygwin) expressed precisely :

Kevin Markle wrote:



What does this mean please and or would you send me your copy that works
fine? "$LOG" == > "".  In these cases, the "hang" is 'cat' waiting for
input from the command

line.


I think he means that in the line:


UPDATES_NEEDED=`cat $LOG | grep "updates detected" | tail -1`


cat $LOG... will hang if $LOG == "" because "cat" is waiting for input.



Precisely.


That helps but my problem is the line above where it get the value for
LOG for whatever reason doesn't get the value of LOG in the for loop
but can outside of the loop... :o)


  You mean this line?

LOG=`ls -al $DIR | grep $t | grep WINDOWS`

  You're listing the contents of the directory, trying to find the one line
that contains the name of the file ($t) you're currently considering.  Then
you're using grep a second time to only select (from that one line) any lines
that contain the text 'WINDOWS'.  Presumably none of the files in
1group_1a_dev_clientlist.out have the word "WINDOWS" in their name.

  What are you *trying* to do with that second grep?

cheers,
  DaveK


There are 2 files related to each client listed in the file 
1group_1a_dev_clientlist.out the first grep grabs both files and the 
second one get the specific log with the work windows in it:


[EMAIL PROTECTED] /cygdrive/e/wsus/group_1a_DEV
$ ls -al
total 27992
drwxrwxrwx+ 2 Administrators    0 Apr  2 16:51 .
drwx--+ 6 Administrators    0 Apr  3 10:41 ..
-rwx--+ 1 Administrators  1284874 Mar 29 01:19 
bvapp1_WINDOWSUpdate.log
-rwx--+ 1 Administrators    27394 Apr  3 10:03 
bvapp1_asr.log



DIR="cygdrive/e/wsus/group_1a_DEV"

for t in `cat $DIR/1group_1a_dev_clientlist.out`
do

echo $t
#LOG=`ls -al $FILE | grep $T | grep WINDOWS | gawk '{print $9}'`
#LOG=`ls -al cygdrive/e/wsus/group_1a_DEV  | grep $t | grep WINDOWS | 
gawk '{print $9}'`

LOG=`ls -al $DIR | grep $t | grep WINDOWS`
echo $t
echo The value of LOG is $LOG
UPDATES_NEEDED=`cat $LOG | grep "updates detected" | tail -1`
echo $UPDATES_NEEDED

done


Thanks!




--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Varibles not working in do loop...

2007-04-03 Thread Andrew Louie

On 4/3/07, Kevin Markle  wrote:


There are 2 files related to each client listed in the file
1group_1a_dev_clientlist.out the first grep grabs both files and the
second one get the specific log with the work windows in it:

[EMAIL PROTECTED] /cygdrive/e/wsus/group_1a_DEV
$ ls -al
total 27992
drwxrwxrwx+ 2 Administrators    0 Apr  2 16:51 .
drwx--+ 6 Administrators    0 Apr  3 10:41 ..
-rwx--+ 1 Administrators  1284874 Mar 29 01:19
bvapp1_WINDOWSUpdate.log
-rwx--+ 1 Administrators    27394 Apr  3 10:03
bvapp1_asr.log

DIR="cygdrive/e/wsus/group_1a_DEV"

for t in `cat $DIR/1group_1a_dev_clientlist.out`


Does this "1group_1a_dev_clientlist.out" file exist in the DIR?
I didn't notice it in your directory listing there



--
-Andrew Louie

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: Varibles not working in do loop...

2007-04-03 Thread Dave Korn
On 03 April 2007 15:46, Kevin Markle wrote:

> Dave Korn pretended :

>>   What are you *trying* to do with that second grep?

> There are 2 files related to each client listed in the file
> 1group_1a_dev_clientlist.out the first grep grabs both files and the
> second one get the specific log with the work windows in it:
> 
> [EMAIL PROTECTED] /cygdrive/e/wsus/group_1a_DEV
> $ ls -al
> total 27992
> drwxrwxrwx+ 2 Administrators    0 Apr  2 16:51 .
> drwx--+ 6 Administrators    0 Apr  3 10:41 ..
> -rwx--+ 1 Administrators  1284874 Mar 29 01:19
> bvapp1_WINDOWSUpdate.log
> -rwx--+ 1 Administrators    27394 Apr  3 10:03
> bvapp1_asr.log
> 
> 
> DIR="cygdrive/e/wsus/group_1a_DEV"
> 
> for t in `cat $DIR/1group_1a_dev_clientlist.out`
> do
> 
> echo $t
> #LOG=`ls -al $FILE | grep $T | grep WINDOWS | gawk '{print $9}'`
> #LOG=`ls -al cygdrive/e/wsus/group_1a_DEV  | grep $t | grep WINDOWS |
> gawk '{print $9}'`
> LOG=`ls -al $DIR | grep $t | grep WINDOWS`
> echo $t
> echo The value of LOG is $LOG
> UPDATES_NEEDED=`cat $LOG | grep "updates detected" | tail -1`
> echo $UPDATES_NEEDED
> 
> done


  So, what output do you see when you run it?  I see 


/artimi/software/firmware $ ./script
bvapp1_WINDOWSUpdate.log
bvapp1_WINDOWSUpdate.log
The value of LOG is -rw-r--r-- 1 dk Domain Users 0 Apr 3 15:54
bvapp1_WINDOWSUpd
ate.log
cat: invalid option -- r
Try `cat --help' for more information.

bvapp1_asr.log
bvapp1_asr.log
The value of LOG is

... and then it hangs, waiting for cat, as before.  Note that you probably
want to be using "ls -1", not "ls -l" (that's a digit one instead of letter
l).  What is actually in your 1group_1a_dev_clientlist.out file?  Can you
please double check it really does have the relevant filenames in it?  Try
adding some extra lines around where you set LOG:

LOG1=`ls -al $DIR`
echo LOG1 is ${LOG1}
LOG2=`ls -al $DIR | grep $t`
echo LOG2 is ${LOG2}
LOG3=`ls -al $DIR | grep $t | grep WINDOWS`
echo LOG3 is ${LOG3}


  ***PING!  

  I bet you have dos line endings in your 1group_1a_dev_clientlist.out file.
That means that in the lines:

> for t in `cat $DIR/1group_1a_dev_clientlist.out`
> do
> 
> echo $t

t is not equal to "bvapp1_WINDOWSUpdate.log", it is equal to
"bvapp1_WINDOWSUpdate.log\r", which is not the name of the file!  You should
be able to fix this by either running d2u on the  1group_1a_dev_clientlist.out
file, or you could replace the for loop in your script like so:

for t in `cat $DIR/1group_1a_dev_clientlist.out | d2u`


cheers,
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Varibles not working in do loop...

2007-04-03 Thread Kevin Markle

Andrew Louie brought next idea :

On 4/3/07, Kevin Markle  wrote:


There are 2 files related to each client listed in the file
1group_1a_dev_clientlist.out the first grep grabs both files and the
second one get the specific log with the work windows in it:

[EMAIL PROTECTED] /cygdrive/e/wsus/group_1a_DEV
$ ls -al
total 27992
drwxrwxrwx+ 2 Administrators    0 Apr  2 16:51 .
drwx--+ 6 Administrators    0 Apr  3 10:41 ..
-rwx--+ 1 Administrators  1284874 Mar 29 01:19
bvapp1_WINDOWSUpdate.log
-rwx--+ 1 Administrators    27394 Apr  3 10:03
bvapp1_asr.log

DIR="cygdrive/e/wsus/group_1a_DEV"

for t in `cat $DIR/1group_1a_dev_clientlist.out`


Does this "1group_1a_dev_clientlist.out" file exist in the DIR?
I didn't notice it in your directory listing there


It was I have moved it as I continue to have problems with varibles but 
only in functions and for loops. Everything works fine from the command 
line but not from within loops or functions??





--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Varibles not working in do loop...

2007-04-03 Thread Kevin Markle

Dave Korn wrote on 4/3/2007 :

On 03 April 2007 15:46, Kevin Markle wrote:


Dave Korn pretended :



  What are you *trying* to do with that second grep?



There are 2 files related to each client listed in the file
1group_1a_dev_clientlist.out the first grep grabs both files and the
second one get the specific log with the work windows in it:

[EMAIL PROTECTED] /cygdrive/e/wsus/group_1a_DEV
$ ls -al
total 27992
drwxrwxrwx+ 2 Administrators    0 Apr  2 16:51 .
drwx--+ 6 Administrators    0 Apr  3 10:41 ..
-rwx--+ 1 Administrators  1284874 Mar 29 01:19
bvapp1_WINDOWSUpdate.log
-rwx--+ 1 Administrators    27394 Apr  3 10:03
bvapp1_asr.log


DIR="cygdrive/e/wsus/group_1a_DEV"

for t in `cat $DIR/1group_1a_dev_clientlist.out`
do

echo $t
#LOG=`ls -al $FILE | grep $T | grep WINDOWS | gawk '{print $9}'`
#LOG=`ls -al cygdrive/e/wsus/group_1a_DEV  | grep $t | grep WINDOWS |
gawk '{print $9}'`
LOG=`ls -al $DIR | grep $t | grep WINDOWS`
echo $t
echo The value of LOG is $LOG
UPDATES_NEEDED=`cat $LOG | grep "updates detected" | tail -1`
echo $UPDATES_NEEDED

done



  So, what output do you see when you run it?  I see 



/artimi/software/firmware $ ./script
bvapp1_WINDOWSUpdate.log
bvapp1_WINDOWSUpdate.log
The value of LOG is -rw-r--r-- 1 dk Domain Users 0 Apr 3 15:54
bvapp1_WINDOWSUpd
ate.log
cat: invalid option -- r
Try `cat --help' for more information.

bvapp1_asr.log
bvapp1_asr.log
The value of LOG is

... and then it hangs, waiting for cat, as before.  Note that you probably
want to be using "ls -1", not "ls -l" (that's a digit one instead of letter
l).  What is actually in your 1group_1a_dev_clientlist.out file?  Can you
please double check it really does have the relevant filenames in it?  Try
adding some extra lines around where you set LOG:

LOG1=`ls -al $DIR`
echo LOG1 is ${LOG1}
LOG2=`ls -al $DIR | grep $t`
echo LOG2 is ${LOG2}
LOG3=`ls -al $DIR | grep $t | grep WINDOWS`
echo LOG3 is ${LOG3}


  ***PING!  

  I bet you have dos line endings in your 1group_1a_dev_clientlist.out file.
That means that in the lines:


for t in `cat $DIR/1group_1a_dev_clientlist.out`
do

echo $t


t is not equal to "bvapp1_WINDOWSUpdate.log", it is equal to
"bvapp1_WINDOWSUpdate.log\r", which is not the name of the file!  You should
be able to fix this by either running d2u on the  
1group_1a_dev_clientlist.out file, or you could replace the for loop in your 
script like so:


for t in `cat $DIR/1group_1a_dev_clientlist.out | d2u`


cheers,
  DaveK


Thank you thank you and thank you that was it oh any by the way Thank 
you!


No longer frustrated :D :D




--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: Varibles not working in do loop...

2007-04-03 Thread Dave Korn
On 03 April 2007 16:25, Kevin Markle wrote:

> Dave Korn wrote on 4/3/2007 :


>>   ***PING!  
>> 
>>   I bet you have dos line endings in your 1group_1a_dev_clientlist.out
>> file. 

> Thank you thank you and thank you that was it oh any by the way Thank
> you!
> 
> No longer frustrated :D :D

  Heh, glad I could help, but please, trim down the re-posted quote next time!
:-)


cheers,
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Varibles not working in do loop...

2007-04-03 Thread Kevin Markle

Dave Korn presented the following explanation :

On 03 April 2007 16:25, Kevin Markle wrote:


Dave Korn wrote on 4/3/2007 :




  ***PING!  

  I bet you have dos line endings in your 1group_1a_dev_clientlist.out
file. 



Thank you thank you and thank you that was it oh any by the way Thank
you!

No longer frustrated :D :D


  Heh, glad I could help, but please, trim down the re-posted quote next 
time!  :-)



cheers,
  DaveK


Not a problem about the quotes!




--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



bash improperly sets PATH containing period

2007-04-03 Thread Pavel Kudrna

Hi,
when dos(win32) path contains period, e.g. "c:." bash instead of 
converting to "/cygdrive/c" incorrectly copies

this string into PATH variable including colon!
(Such dos path containing period is legal and is used in Novell Client 
as search drives.)

Pavel Kudrna

C:\temp> path c:\temp;c:.;s:\public

C:\temp> path
PATH=c:\temp;c:.;s:\public

C:\temp> "C:\Program Files\cygwin\bin\bash.exe" --login -i

[EMAIL PROTECTED] ~
$ echo $PATH
/usr/X11R6/bin:/usr/local/bin:/usr/bin:/bin:/cygdrive/c/temp:c:.:/cygdrive/s/public:/usr/local/cint


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: bash improperly sets PATH containing period

2007-04-03 Thread Dave Korn
On 03 April 2007 17:18, Pavel Kudrna wrote:

> (Such dos path containing period is legal and is used in Novell Client
> as search drives.)

  However it is impossible to reproduce precisely in cygwin, as there is no
concept of a current directory per-drive, only one for the entire system.

> Pavel Kudrna
> 
> C:\temp> path c:\temp;c:.;s:\public
> 
> C:\temp> path
> PATH=c:\temp;c:.;s:\public
> 
> C:\temp> "C:\Program Files\cygwin\bin\bash.exe" --login -i
> 
> [EMAIL PROTECTED] ~
> $ echo $PATH
>
/usr/X11R6/bin:/usr/local/bin:/usr/bin:/bin:/cygdrive/c/temp:c:.:/cygdrive/s/p
ublic:/usr/local/cint

  But I agree this is wrong, the path-conversion code should either just use a
plain '.' as a path component or discard the entire item altogether, it
certainly shouldn't end up treating 'c' as one path component and '.' as a
separate one.



cheers,
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



1.5.24 remote launch of java gui

2007-04-03 Thread Elliston, Jack W CTR USA TRADOC NSC
I am unable to launch a java application via ssh such that it displays
the gui on the remote machine.

Setup:

Machine 1 (Linux)--ssh--> Machine 2 (WinXP w/ Cygwin 1.5.24)

Example:
At the prompt I type "java -jar Notepad.jar" in the correct directory
expecting to see the java Notepad display on Machine 2

 => I see a java process but no gui.

I see a similar problem with the main app I am trying to run.  My
application will run just fine on Machine 2 and I am able to interact
with the process (but not the GUI) and I need the GUI for some
monitoring.

Even if I set the DISPLAY=localhost:0 it will not display.

I don't want the GUI to show up on Machine 1 since the underlying
purpose is to launch a java application on multiple cygwin machines
using a looped 'ssh -f machinex "java app"' script with the gui
displaying on each remote machine.  This approach works great on linux
boxes but I cannot get a java gui to display on the cygwin machines.

I can remotely launch xterms since I do have an Xserver running on the
cygwin box.

Any help or pointers to better information would be greatly appreciated.

Thanks,
Jack


cygcheck.out
Description: cygcheck.out
--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/

cygwin or gdb question

2007-04-03 Thread Bob Rossi
Hi,

I have one more cgdb issue that seems to be cygwin related. However, it
could be a gdb issue. I'm not sure.

In verison cgdb-0.6.3 I start GDB up on a pipe and communicate with it
over the pipe. This works fine, except that GDB behaves slightly
differently when it is invoked on a pipe rather than a pty. That is, 
GDB provides interactive questions to the user when it's on a pty
and not when it's on a pipe.

In svn trunk for CGDB I began starting GDB on a pty and communicating
with it that way. This fixed a bug for a user on max os X and provided
the user with a GDB that acted more like it was on an actual terminal.

This seems to work fine on linux, however I noticed a difference on
Cygwin. I compile a large GUI application and debug it. I set
no breakpoints and type 'r', do some stuff and the GUI and then stop.
The debugger is hanging, waiting for something interesting to happen.
If I type ctrl-c on linux, it interupts the debugger so that I can
set a breakpoint or do something else interesting. If I do this on
cygwin, it doesn't interupt the program.

In fact, this isn't just a problem with CGDB, the exact same results
happen with gdb. So, is it a cygwin or gdb issue that it appears that
you can interupt the inferior when gdb is on a pipe, but not when it's
on a terminal.

Is there an easy way for me to test starting gdb on a pipe outside of
CGDB? I would like to reproduce that gdb does interupt the inferior when 
ctrl-c is typed and GDB is started on a pipe.

Thanks again,
Bob Rossi

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: cygwin or gdb question

2007-04-03 Thread Igor Peshansky
On Tue, 3 Apr 2007, Bob Rossi wrote:

> Hi,
>
> I have one more cgdb issue that seems to be cygwin related. However, it
> could be a gdb issue. I'm not sure.
>
> In verison cgdb-0.6.3 I start GDB up on a pipe and communicate with it
> over the pipe. This works fine, except that GDB behaves slightly
> differently when it is invoked on a pipe rather than a pty. That is,
> GDB provides interactive questions to the user when it's on a pty
> and not when it's on a pipe.
>
> In svn trunk for CGDB I began starting GDB on a pty and communicating
> with it that way. This fixed a bug for a user on max os X and provided
> the user with a GDB that acted more like it was on an actual terminal.
>
> This seems to work fine on linux, however I noticed a difference on
> Cygwin. I compile a large GUI application and debug it. I set
> no breakpoints and type 'r', do some stuff and the GUI and then stop.
> The debugger is hanging, waiting for something interesting to happen.
> If I type ctrl-c on linux, it interupts the debugger so that I can
> set a breakpoint or do something else interesting. If I do this on
> cygwin, it doesn't interupt the program.
>
> In fact, this isn't just a problem with CGDB, the exact same results
> happen with gdb. So, is it a cygwin or gdb issue that it appears that
> you can interupt the inferior when gdb is on a pipe, but not when it's
> on a terminal.
>
> Is there an easy way for me to test starting gdb on a pipe outside of
> CGDB? I would like to reproduce that gdb does interupt the inferior when
> ctrl-c is typed and GDB is started on a pipe.

Yes.  Use CYGWIN=tty or rxvt.
Igor
-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED] | [EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_Igor Peshansky, Ph.D. (name changed!)
 |,4-  ) )-,_. ,\ (  `'-'   old name: Igor Pechtchanski
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Freedom is just another word for "nothing left to lose"...  -- Janis Joplin

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: 1.5.24 remote launch of java gui

2007-04-03 Thread Igor Peshansky
On Tue, 3 Apr 2007, Elliston, Jack W  CTR USA TRADOC NSC wrote:

> I am unable to launch a java application via ssh such that it displays
> the gui on the remote machine.
>
> Setup:
>
> Machine 1 (Linux)--ssh--> Machine 2 (WinXP w/ Cygwin 1.5.24)
>
> Example:
> At the prompt I type "java -jar Notepad.jar" in the correct directory
> expecting to see the java Notepad display on Machine 2
>
>  => I see a java process but no gui.
>
> I see a similar problem with the main app I am trying to run.  My
> application will run just fine on Machine 2 and I am able to interact
> with the process (but not the GUI) and I need the GUI for some
> monitoring.
>
> Even if I set the DISPLAY=localhost:0 it will not display.
>
> I don't want the GUI to show up on Machine 1 since the underlying
> purpose is to launch a java application on multiple cygwin machines
> using a looped 'ssh -f machinex "java app"' script with the gui
> displaying on each remote machine.  This approach works great on linux
> boxes but I cannot get a java gui to display on the cygwin machines.
>
> I can remotely launch xterms since I do have an Xserver running on the
> cygwin box.
>
> Any help or pointers to better information would be greatly appreciated.

There is no Cygwin version of Java.  Therefore, you're starting a Windows
version of Java, which is not an X application.  You will not be able to
forward the display, unless you use something like rdesktop or VNC.
Igor
-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED] | [EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_Igor Peshansky, Ph.D. (name changed!)
 |,4-  ) )-,_. ,\ (  `'-'   old name: Igor Pechtchanski
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Freedom is just another word for "nothing left to lose"...  -- Janis Joplin

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: 1.5.24 remote launch of java gui

2007-04-03 Thread Dave Korn
On 03 April 2007 17:57, Igor Peshansky wrote:

> There is no Cygwin version of Java.  Therefore, you're starting a Windows
> version of Java, which is not an X application.  You will not be able to
> forward the display

  He doesn't want to.  He wants the display to appear on the same remote
machine where the java process is being launched.


cheers,
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: 1.5.24 remote launch of java gui

2007-04-03 Thread Igor Peshansky
On Tue, 3 Apr 2007, Dave Korn wrote:

> On 03 April 2007 17:57, Igor Peshansky wrote:
>
> > There is no Cygwin version of Java.  Therefore, you're starting a Windows
> > version of Java, which is not an X application.  You will not be able to
> > forward the display
>
>   He doesn't want to.  He wants the display to appear on the same remote
> machine where the java process is being launched.

So he does.  Then he'll just need to check the "Allow service to interact
with the desktop" checkbox in the service properties (or use the -i
cygrunsrv flag).  Unless he uses privilege separation, in which case he's
out of luck (as this option is only available for services running as
"system").
Igor
-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED] | [EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_Igor Peshansky, Ph.D. (name changed!)
 |,4-  ) )-,_. ,\ (  `'-'   old name: Igor Pechtchanski
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Freedom is just another word for "nothing left to lose"...  -- Janis Joplin

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



grep and exact matches help..

2007-04-03 Thread Kevin Markle

Hello,

I can't seem to find a way to get grep to do exact matches in cygwin. I 
have looked at the man pages and can find nothing? :/





--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: grep and exact matches help..

2007-04-03 Thread Dave Korn
On 03 April 2007 18:33, Kevin Markle wrote:

> Hello,
> 
> I can't seem to find a way to get grep to do exact matches in cygwin. I
> have looked at the man pages and can find nothing? :/

  grep only does exact matches if you don't use any of the wildcard chars,
perhaps 'exact matches' isn't quite what you mean.  Are you perhaps looking
for the '-o' option?  Or do you mean you want to match an entire line, in
which case put '^' at the start of your comparison-string and '$' at the end.


cheers,
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: 1.5.24 remote launch of java gui

2007-04-03 Thread Elliston, Jack W CTR USA TRADOC NSC
OK.  Now I am bit confused.

I am not trying to run a service on the remote cygwin box and so I don't
see how I would 'check the "Allow service to interact with the desktop"
checkbox' or why I would use the cygrunsrv application.

I just need to run the java app on machine 2 via a ssh connection from
machine 1.  I want the app to display it gui on machine 2.

I don't really even think the Xserver is required since the app runs on
machine 2 when launched on machine 2 without an Xserver installed.

Jack

-Original Message-
From: Igor Peshansky [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, April 03, 2007 12:30 PM
To: Dave Korn
Cc: cygwin@cygwin.com; Elliston, Jack W CTR USA TRADOC NSC
Subject: RE: 1.5.24 remote launch of java gui

On Tue, 3 Apr 2007, Dave Korn wrote:

> On 03 April 2007 17:57, Igor Peshansky wrote:
>
> > There is no Cygwin version of Java.  Therefore, you're starting a 
> > Windows version of Java, which is not an X application.  You will 
> > not be able to forward the display
>
>   He doesn't want to.  He wants the display to appear on the same 
> remote machine where the java process is being launched.

So he does.  Then he'll just need to check the "Allow service to
interact with the desktop" checkbox in the service properties (or use
the -i cygrunsrv flag).  Unless he uses privilege separation, in which
case he's out of luck (as this option is only available for services
running as "system").
Igor
-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED] |
[EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_Igor Peshansky, Ph.D. (name
changed!)
 |,4-  ) )-,_. ,\ (  `'-'   old name: Igor Pechtchanski
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Freedom is just another word for "nothing left to lose"...  -- Janis
Joplin

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: 1.5.24 remote launch of java gui

2007-04-03 Thread Dave Korn
On 03 April 2007 18:44, Elliston, Jack W CTR USA TRADOC NSC wrote:

> OK.  Now I am bit confused.
> 
> I am not trying to run a service on the remote cygwin box and so I don't
> see how I would 'check the "Allow service to interact with the desktop"
> checkbox' or why I would use the cygrunsrv application.

  I believe that would be referring to the sshd service, which you most
certainly /are/ running on the remote machine!

> I just need to run the java app on machine 2 via a ssh connection from
> machine 1.  I want the app to display it gui on machine 2.
> 
> I don't really even think the Xserver is required since the app runs on
> machine 2 when launched on machine 2 without an Xserver installed.

  Yep, but since you've come in via ssh, you are logged in as a remote
('network') user, which gives you less rights than a local ('interactive')
user who is actually sat at the console.  Specifically, processes launched by
remote user's can't get at the local user's desktop, in order to try and
protect against security violations, and you need to relax this restriction
for your sshd-launched java.exe to be able to open a window on the desktop.

  The checkbox in question is on the "Log On" tab of the Properties page of
the "CYGWIN sshd" service as seen in the services manager
(Start->Run->"services.msc").


cheers,
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: 1.5.24 remote launch of java gui

2007-04-03 Thread Igor Peshansky
Ugh, top-posting...  Reformatted.

On Tue, 3 Apr 2007, Elliston, Jack W  CTR USA TRADOC NSC wrote:

> -Original Message-
> From: Igor Peshansky [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, April 03, 2007 12:30 PM
> To: Dave Korn
> Cc: [EMAIL PROTECTED]; Elliston, Jack W CTR USA TRADOC NSC

.  Thanks.

> Subject: RE: 1.5.24 remote launch of java gui
>
> > On Tue, 3 Apr 2007, Dave Korn wrote:
> >
> > > On 03 April 2007 17:57, Igor Peshansky wrote:
> > >
> > > > There is no Cygwin version of Java.  Therefore, you're starting a
> > > > Windows version of Java, which is not an X application.  You will
> > > > not be able to forward the display
> > >
> > >   He doesn't want to.  He wants the display to appear on the same
> > > remote machine where the java process is being launched.
> >
> > So he does.  Then he'll just need to check the "Allow service to
> > interact with the desktop" checkbox in the service properties (or use
> > the -i cygrunsrv flag).  Unless he uses privilege separation, in which
> > case he's out of luck (as this option is only available for services
> > running as "system").
> > Igor
>
> OK.  Now I am bit confused.

So are we.

> I am not trying to run a service on the remote cygwin box and so I don't
> see how I would 'check the "Allow service to interact with the desktop"
> checkbox' or why I would use the cygrunsrv application.

Your remote box is Cygwin, and you're logging in via ssh, right?  That
means that you *are* most likely running sshd as a service.

> I just need to run the java app on machine 2 via a ssh connection from
> machine 1.  I want the app to display it gui on machine 2.

Exactly.  When you log in via ssh, the sshd service spawns your Java
application.  To be able to display the resulting window, it needs your
permission to "interact with the desktop".

> I don't really even think the Xserver is required since the app runs on
> machine 2 when launched on machine 2 without an Xserver installed.

No, Java does not use X, since it's a pure Windows application.  It uses
Win32 GDI calls.
Igor
-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED] | [EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_Igor Peshansky, Ph.D. (name changed!)
 |,4-  ) )-,_. ,\ (  `'-'   old name: Igor Pechtchanski
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Freedom is just another word for "nothing left to lose"...  -- Janis Joplin

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: grep and exact matches help..

2007-04-03 Thread Kevin Markle

In this search I want to get winops only not winops and winops-hq

[EMAIL PROTECTED] /cygdrive/e/wsus/group_1a_DEV
$ ls -al | grep winops
-rwx--+ 1 Administrators  1079474 Apr  2 19:32 
winops-hq_WINDOWSUpdate.log
-rwx--+ 1 Administrators    18993 Apr  3 13:02 
winops-hq_asr.log
-rwx--+ 1 Administrators  1242842 Apr  3 06:01 
winops_WINDOWSUpdate.log
-rwx--+ 1 Administrators    18580 Apr  3 13:02 
winops_asr.log





--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: grep and exact matches help..

2007-04-03 Thread Matthew Woehlke

Kevin Markle wrote:

In this search I want to get winops only not winops and winops-hq

[EMAIL PROTECTED] /cygdrive/e/wsus/group_1a_DEV
$ ls -al | grep winops
-rwx--+ 1 Administrators  1079474 Apr  2 19:32 
winops-hq_WINDOWSUpdate.log
-rwx--+ 1 Administrators    18993 Apr  3 13:02 
winops-hq_asr.log
-rwx--+ 1 Administrators  1242842 Apr  3 06:01 
winops_WINDOWSUpdate.log

-rwx--+ 1 Administrators    18580 Apr  3 13:02 winops_asr.log


ls -al winops

--
Matthew
Obscurity: +5


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



stdint.h bug

2007-04-03 Thread Eric Blake
Cygwin defines wint_t as unsigned int (valid, per POSIX), but then defines

#ifndef WINT_MIN
#define WINT_MIN (-2147483647 - 1)
#define WINT_MAX (2147483647)
#endif

which is invalid given the underlying type of wint_t.  Can we get this fixed 
(either make wint_t a signed type, or change WINT_MIN and WINT_MAX)?

-- 
Eric Blake



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: 1.5.24 remote launch of java gui

2007-04-03 Thread Elliston, Jack W CTR USA TRADOC NSC
 
> >
> > OK.  Now I am bit confused.
> 
> So are we.

My apologies.

> 
> > I am not trying to run a service on the remote cygwin box and so I 
> > don't see how I would 'check the "Allow service to interact 
> with the desktop"
> > checkbox' or why I would use the cygrunsrv application.
> 
> Your remote box is Cygwin, and you're logging in via ssh, 
> right?  That means that you *are* most likely running sshd as 
> a service.
> 
Duh on my part, now the earlier comment makes sense.  

So I tried the following:

1) Reconfigured sshd to NOT use privilege separation
2) Configured the sshd service TO allow interaction with the desktop

BINGO!!

It works. 

Thank you for pointing me in the right direction.

Jack

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: grep and exact matches help..

2007-04-03 Thread Dave Korn
On 03 April 2007 19:01, Kevin Markle wrote:

> In this search I want to get winops only not winops and winops-hq
> 
> [EMAIL PROTECTED] /cygdrive/e/wsus/group_1a_DEV
> $ ls -al | grep winops
> -rwx--+ 1 Administrators  1079474 Apr  2 19:32
> winops-hq_WINDOWSUpdate.log
> -rwx--+ 1 Administrators    18993 Apr  3 13:02
> winops-hq_asr.log
> -rwx--+ 1 Administrators  1242842 Apr  3 06:01
> winops_WINDOWSUpdate.log
> -rwx--+ 1 Administrators    18580 Apr  3 13:02
> winops_asr.log

  Ummm, you need to be more precise than that.  If you ask for an "exact
match", which to me means "winops not followed by anything at all" from that
search, you'll get nothing because there isn't a file called "winops".

  It seems to me that what you want is not an exact match after all; what you
want is "winops, and it may be followed by some things, but not by some other
things".  You'll need to write a regular expression that allows those first
"some things" while denying the "some other things".

  [BTW we're getting off-topic here, since this is really a generic 'grep'
question and nothing specific to cygwin at all.]

  BTW2, I assume we're still talking about your script from before.
Seriously, use "ls -1" rather than "ls -l" (that is, use a one instead of an
L), because then you get /just/ the filenames, one per line, and won't have to
worry about parsing the name out from amongst all those permission flags and
datestamps.

cheers,
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: stdint.h bug

2007-04-03 Thread Christopher Faylor
On Tue, Apr 03, 2007 at 06:15:14PM +, Eric Blake wrote:
>Cygwin defines wint_t as unsigned int (valid, per POSIX), but then defines
>
>#ifndef WINT_MIN
>#define WINT_MIN (-2147483647 - 1)
>#define WINT_MAX (2147483647)
>#endif
>
>which is invalid given the underlying type of wint_t.  Can we get this fixed 
>(either make wint_t a signed type, or change WINT_MIN and WINT_MAX)?

Patch?

cgf

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: 1.5.24 remote launch of java gui

2007-04-03 Thread Elliston, Jack W CTR USA TRADOC NSC
 

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of Elliston, Jack 
> W CTR USA TRADOC NSC
> Sent: Tuesday, April 03, 2007 1:29 PM
> To: cygwin@cygwin.com
> Subject: RE: 1.5.24 remote launch of java gui
> 
>  
> > >
> > > OK.  Now I am bit confused.
> > 
> > So are we.
> 
> My apologies.
> 
> > 
> > > I am not trying to run a service on the remote cygwin box 
> and so I 
> > > don't see how I would 'check the "Allow service to interact
> > with the desktop"
> > > checkbox' or why I would use the cygrunsrv application.
> > 
> > Your remote box is Cygwin, and you're logging in via ssh, 
> right?  That 
> > means that you *are* most likely running sshd as a service.
> > 
> Duh on my part, now the earlier comment makes sense.  
> 
> So I tried the following:
> 
> 1) Reconfigured sshd to NOT use privilege separation
> 2) Configured the sshd service TO allow interaction with the desktop
> 
> BINGO!!
> 
> It works. 
> 
OK.  Maybe I was a bit premature in declaring victory.

It works via an interactive ssh connection but does not work when using
"ssh -f machine2 app"

Am I doing something wrong?

Thanks,
Jack

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Cygwin snapshot and 'last-cache' file

2007-04-03 Thread Angelo Graziosi

The file /etc/setup/last-cache contains path in DOS-like style:

   C:\cygwin\home\Angelo\Downloads\cygwin

When a script tries to retrive this information from 'last-cache' under
the snapshot (for 1.7.0 release) there is the warning:

  cygwin warning:
  MS-DOS style path detected: C:/cygwin/home/Angelo/Downloads/cygwin
  Preferred POSIX equivalent is: /home/Angelo/Downloads/cygwin
  CYGWIN environment variable option "nodosfilewarning" turns off this
  warning.
  Consult the user's guide for more details about POSIX paths:
http://cygwin.com/cygwin-ug-net/using.html#using-pathnames


... and I remember some discussion (MAKE-3.81 etc.) in which you were
reluctanct in accepting the DOS-like paths.



  Angelo.


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Cygwin snapshot and 'last-cache' file

2007-04-03 Thread Brian Dessent
Angelo Graziosi wrote:

> The file /etc/setup/last-cache contains path in DOS-like style:
> 
>C:\cygwin\home\Angelo\Downloads\cygwin
> 
> When a script tries to retrive this information from 'last-cache' under
> the snapshot (for 1.7.0 release) there is the warning:
> 
>   cygwin warning:
>   MS-DOS style path detected: C:/cygwin/home/Angelo/Downloads/cygwin
>   Preferred POSIX equivalent is: /home/Angelo/Downloads/cygwin
>   CYGWIN environment variable option "nodosfilewarning" turns off this
>   warning.
>   Consult the user's guide for more details about POSIX paths:
> http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
> 
> ... and I remember some discussion (MAKE-3.81 etc.) in which you were
> reluctanct in accepting the DOS-like paths.

I don't get it.  The script (what script?!?) should be updated to use
cygpath on the value read from the file, e.g. dldir=$(cygpath -f
/etc/setup/last-cache), just like any script that reads a key from the
registry or some program's .ini settings file or whatever.  The fact
that setup.exe happens to store its internal settings as a win32 path is
an internal detail, the file was never meant to be read by anything
else.  Besides, setup.exe is not a Cygwin app so storing its settings as
posix paths would just be extra hassle.

Brian

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



[ANNOUNCEMENT] Updated: tzcode-2007e-1

2007-04-03 Thread Dr. Volker Zell
Hi

A new version of 'tzcode/tzdata' has been uploaded to a server near you.


DESCRIPTION:

The time zone package


CYGWIN NEWS:


 * Update to latest upstream release
 
tzcode/tzdata NEWS
==

 * Sorry no changelog available. You have to do the diff yourself.


INSTALLATION:
=
To update your installation, click on the "Install Cygwin now" link on
the http://cygwin.com/ web page.  This downloads setup.exe to your
system.  Save it and run setup, answer the questions and pick up
the above mentioned package from the 'System' category.


DOWNLOAD:
=
Note that downloads from sources.redhat.com (aka cygwin.com) aren't
allowed due to bandwidth limitations.  This means that you will need
to find a mirror which has this update, please choose the one nearest to
you: http://cygwin.com/mirrors.html


QUESTIONS:
==
If you want to make a point or ask a question the Cygwin mailing
list is the appropriate place.


CYGWIN-ANNOUNCE UNSUBSCRIBE INFO:
=
To unsubscribe to the cygwin-announce mailing list, look at the
"List-Unsubscribe: " tag in the email header of this message.  Send
email to the address specified there.  It will be in the format:

[EMAIL PROTECTED]

If you need more information on unsubscribing, start reading here:

http://sources.redhat.com/lists.html#unsubscribe-simple

Please read *all* of the information on unsubscribing that is available
starting at this URL.


Enjoy
  Volker


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Cygwin snapshot and 'last-cache' file

2007-04-03 Thread Christopher Faylor
On Tue, Apr 03, 2007 at 11:00:42PM +0200, Angelo Graziosi wrote:
>The file /etc/setup/last-cache contains path in DOS-like style:
>
>   C:\cygwin\home\Angelo\Downloads\cygwin

setup.exe is not a cygwin program.

>When a script tries to retrive this information from 'last-cache' under
>the snapshot (for 1.7.0 release) there is the warning:

"a script"?  As in a script that you wrote?

>  cygwin warning:
>  MS-DOS style path detected: C:/cygwin/home/Angelo/Downloads/cygwin
>  Preferred POSIX equivalent is: /home/Angelo/Downloads/cygwin
>  CYGWIN environment variable option "nodosfilewarning" turns off this
>  warning.
>  Consult the user's guide for more details about POSIX paths:
>http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
>
>... and I remember some discussion (MAKE-3.81 etc.) in which you were
>reluctanct in accepting the DOS-like paths.

So, if you grab some data from a random file on the system and that
file contains a DOS path and you then try to use the DOS path under
cygwin, you will get a warning which explains that it's not a good
idea to use DOS paths along with information about how to avoid getting
the warning.

Seems like everything is working as designed.  OTOH, if the above
script is something from the cygwin distribution then please be more
specific so that it can be fixed.

cgf

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: grep and exact matches help..

2007-04-03 Thread Peter Rehley


On Apr 3, 2007, at 11:00 AM, Kevin Markle wrote:


In this search I want to get winops only not winops and winops-hq

[EMAIL PROTECTED] /cygdrive/e/wsus/group_1a_DEV
$ ls -al | grep winops
-rwx--+ 1 Administrators  1079474 Apr  2 19:32 winops- 
hq_WINDOWSUpdate.log
-rwx--+ 1 Administrators    18993 Apr  3 13:02 winops- 
hq_asr.log
-rwx--+ 1 Administrators  1242842 Apr  3 06:01  
winops_WINDOWSUpdate.log
-rwx--+ 1 Administrators    18580 Apr  3 13:02  
winops_asr.log




Here is one possible solution

ls -1a | grep winops | grep -v winops-hp

or maybe this

ls -1a | sed -e '/winops-hq/d'


Peter

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Escape colour codes

2007-04-03 Thread Thorsten Kampe
* Thorsten Kampe (Mon, 19 Mar 2007 11:44:30 -)
> I'm having a problem with colour escape codes for prompts in different 
> applications and terminals. Basically it is like this.
> 
> lftp and yafc show a wrong prompt in the following terminals: cmd, 4nt, 
> console and far manager. Basically each coloured part of the prompt is 
> surrounded by two "funny faces" - the first is white and the second has 
> the desired colour.
> 
> Let's say my prompt is "[EMAIL PROTECTED]:directory" where "directory" is 
> cyan. 
> Then the prompt looks like this[1]:
> [EMAIL PROTECTED]:[FW][FC]directory[FC][FW]
> 
> The interesting thing is that the coloured prompts /do/ work in bash, zsh 
> and screen[2] with cmd, 4nt, console and FAR manager.
> 
> Also the coloured prompts from lftp and yafc show correctly in rxvt. They 
> also show correctly in Linux and Konsole so the syntax of the coloured 
> prompt is correct.

Well, I never got no answer so I had to solve this myself: IPython has 
the same problem and the reason is that the prompts are wrapped in 
\001 \002 pairs so "readline can properly know the length of each line 
and can wrap lines accordingly".

Obvioulsy all Windows terminals can't interpret those "non-visible 
characters" (or they don't ignore them like they should or readline 
doesn't "eat" them like it should).

Where is the culprit here? Cygwin readline not correctly interacting 
with non Cygwin terminals? Windows terminals not understanding common 
readline(?) escape characters?

Is there a way to solve the issue?

Patching Windows cmd is out of question so either readline had to be 
patched (if involved) or all the applications using those "\001 (^A) 
start non-visible characters, \002 (^B) end non-visible characters".


Thorsten


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: Escape colour codes

2007-04-03 Thread Matthew Woehlke

Thorsten Kampe wrote:
lftp and yafc show a wrong prompt in the following terminals: cmd, 4nt, 
console and far manager. Basically each coloured part of the prompt is 
surrounded by two "funny faces" - the first is white and the second has 
the desired colour.


I don't know what these are. Are they non-Cygwin applications that are 
looking at the environment variable 'PS1'? Cygwin apps (e.g. 'printf') 
should cope with escapes correctly even in Windows consoles (otherwise 
even bash would not work).


Obvioulsy all Windows terminals can't interpret those "non-visible 
characters" (or they don't ignore them like they should or readline 
doesn't "eat" them like it should).


Where is the culprit here? Cygwin readline not correctly interacting 
with non Cygwin terminals? Windows terminals not understanding common 
readline(?) escape characters?


Windows consoles don't understand escapes, period. Also AFAIK nothing 
except readline understands \[ and \]. But Cygwin understands escapes so 
Cygwin applications should work even in a Windows console.



Is there a way to solve the issue?


Don't use escapes in non-Cygwin programs.

--
Matthew
Obscurity: +5


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: grep and exact matches help..

2007-04-03 Thread Gary Johnson
On 2007-04-03, Dave Korn wrote:

>   BTW2, I assume we're still talking about your script from before.
> Seriously, use "ls -1" rather than "ls -l" (that is, use a one instead of an
> L), because then you get /just/ the filenames, one per line, and won't have to
> worry about parsing the name out from amongst all those permission flags and
> datestamps.

On 2007-04-03, Peter Rehley wrote:

> Here is one possible solution
> 
> ls -1a | grep winops | grep -v winops-hp
> 
> or maybe this
> 
> ls -1a | sed -e '/winops-hq/d'

If you're piping 'ls' into another command, the -1 isn't necessary.  
'ls' detects that its stdout is not a tty and delivers single-column  
output automatically.

Regards,
Gary

-- 
Gary Johnson | Agilent Technologies
[EMAIL PROTECTED] | Mobile Broadband Division
 | Spokane, Washington, USA

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Problems between rsync and current sbnapshot ?

2007-04-03 Thread Angelo Graziosi

Iwant to flag that 'rsync' seems to hang with current
(20070330) snapshot:
--
$ rsync -av --delete ftp.dante.de::CTAN/systems/win32/miktex /tmp

receiving file list ... done
--



now it hangs, it takes 100% of CPU. I must use CTRL-C:
-

rsync error: received SIGUSR1 or SIGINT (code 20) at
/home/lapo/packaging/tmp/rs
ync-2.6.6/rsync.c(163)
rsync error: received SIGUSR1 or SIGINT (code 20) at
/home/lapo/packaging/tmp/rs
ync-2.6.6/main.c(985) 
--


Reinstalling Cygwin-1.5.24 it works fine:
--
$ rsync -av --delete ftp.dante.de::CTAN/systems/win32/miktex /tmp

receiving file list ... done

sent 90 bytes  received 34685 bytes  9935.71 bytes/sec
total size is 536410581  speedup is 15425.18
---

(I have played many time intall/reinstall snapshot/cygwin-1.5.24-2 and
only with 1.5.24 it works)



Regards,

  Angelo.


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



RE: grep and exact matches help..

2007-04-03 Thread Thrall, Bryan
Gary Johnson wrote on Tuesday, April 03, 2007 5:05 PM:
> On 2007-04-03, Dave Korn wrote:
> 
>>   BTW2, I assume we're still talking about your script from before.
>> Seriously, use "ls -1" rather than "ls -l" (that is, use a one
>> instead of an L), because then you get /just/ the filenames, one per
>> line, and won't have to worry about parsing the name out from
>> amongst all those permission flags and datestamps.
> 
> On 2007-04-03, Peter Rehley wrote:
> 
>> Here is one possible solution
>> 
>> ls -1a | grep winops | grep -v winops-hp
>> 
>> or maybe this
>> 
>> ls -1a | sed -e '/winops-hq/d'
> 
> If you're piping 'ls' into another command, the -1 isn't necessary.
> 'ls' detects that its stdout is not a tty and delivers single-column
> output automatically.

Not when you use 'ls -l':

[EMAIL PROTECTED] /tmp/thrall/foo
$ ls | cat
bar
baz
[EMAIL PROTECTED] /tmp/thrall/foo
$ ls -l | cat
total 0
-rw-r--r--  1 thrall FSUsers 0 Apr  3 17:19 bar
-rw-r--r--  1 thrall FSUsers 0 Apr  3 17:19 baz
[EMAIL PROTECTED] /tmp/thrall/foo
$ ls -1 | cat
bar
baz

-- 
Bryan Thrall
FlightSafety International
[EMAIL PROTECTED]

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: grep and exact matches help..

2007-04-03 Thread Matthew Woehlke

Thrall, Bryan wrote:

Gary Johnson wrote on Tuesday, April 03, 2007 5:05 PM:

If you're piping 'ls' into another command, the -1 isn't necessary.
'ls' detects that its stdout is not a tty and delivers single-column
output automatically.


Not when you use 'ls -l':


Sure it does. There is still only one file per line. :-)

--
Matthew
Obscurity: +5


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: [Packaging error] Re: [ANNOUNCEMENT] Updated: mingw-runtime-3.12-1

2007-04-03 Thread Chris Sutcliffe

> I've made a new version of the mingw-runtime available for download.
> For a list of changes see below.

Man pages should go to /usr/share/man/...


I thought it was decided to keep the MinGW Runtime man pages separate
from the Cygwin man pages?

Chris

--
Chris Sutcliffe
http://ir0nh34d.googlepages.com
http://ir0nh34d.blogspot.com
http://emergedesktop.org

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: cygwin or gdb question

2007-04-03 Thread Bob Rossi
On Tue, Apr 03, 2007 at 12:54:57PM -0400, Igor Peshansky wrote:
> On Tue, 3 Apr 2007, Bob Rossi wrote:
> > I have one more cgdb issue that seems to be cygwin related. However, it
> > could be a gdb issue. I'm not sure.
> >
> > In verison cgdb-0.6.3 I start GDB up on a pipe and communicate with it
> > over the pipe. This works fine, except that GDB behaves slightly
> > differently when it is invoked on a pipe rather than a pty. That is,
> > GDB provides interactive questions to the user when it's on a pty
> > and not when it's on a pipe.
> >
> > In svn trunk for CGDB I began starting GDB on a pty and communicating
> > with it that way. This fixed a bug for a user on max os X and provided
> > the user with a GDB that acted more like it was on an actual terminal.
> >
> > This seems to work fine on linux, however I noticed a difference on
> > Cygwin. I compile a large GUI application and debug it. I set
> > no breakpoints and type 'r', do some stuff and the GUI and then stop.
> > The debugger is hanging, waiting for something interesting to happen.
> > If I type ctrl-c on linux, it interupts the debugger so that I can
> > set a breakpoint or do something else interesting. If I do this on
> > cygwin, it doesn't interupt the program.
> >
> > In fact, this isn't just a problem with CGDB, the exact same results
> > happen with gdb. So, is it a cygwin or gdb issue that it appears that
> > you can interupt the inferior when gdb is on a pipe, but not when it's
> > on a terminal.
> >
> > Is there an easy way for me to test starting gdb on a pipe outside of
> > CGDB? I would like to reproduce that gdb does interupt the inferior when
> > ctrl-c is typed and GDB is started on a pipe.
> 
> Yes.  Use CYGWIN=tty or rxvt.

Thanks, neither of these showed me the results that I used to get with
cgdb-0.6.3. I've actually decided that I like cgdb working exactly the
same way gdb does. So not being able to interupt the program with ctrl-c
is fine.

Thanks,
Bob Rossi

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: stdint.h bug

2007-04-03 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

According to Christopher Faylor on 4/3/2007 1:13 PM:
> On Tue, Apr 03, 2007 at 06:15:14PM +, Eric Blake wrote:
>> Cygwin defines wint_t as unsigned int (valid, per POSIX), but then defines
>>
>> #ifndef WINT_MIN
>> #define WINT_MIN (-2147483647 - 1)
>> #define WINT_MAX (2147483647)
>> #endif
>>
>> which is invalid given the underlying type of wint_t.  Can we get this fixed 
>> (either make wint_t a signed type, or change WINT_MIN and WINT_MAX)?
> 
> Patch?

Well, I was hoping for some feedback as to whether changing wint_t to be
signed was preferable over changing WINT_MIN.  But further research shows
Linux also uses an unsigned type for wint_t, so:

2007-04-03  Eric Blake  <[EMAIL PROTECTED]>

* include/stdint.h (WINT_MIN, WINT_MAX): Fix definition.

- --
Don't work too hard, make some time for fun as well!

Eric Blake [EMAIL PROTECTED]
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.5 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGEv9/84KuGfSFAYARAo1OAJ9Ig6W0WqaMfGWN4njXieB8AJb0pwCgh3FE
x5B6wtRLeWqvadttHSbl6Hw=
=fB6i
-END PGP SIGNATURE-
Index: include/stdint.h
===
RCS file: /cvs/src/src/winsup/cygwin/include/stdint.h,v
retrieving revision 1.7
diff -u -p -r1.7 stdint.h
--- include/stdint.h3 Jul 2006 12:30:04 -   1.7
+++ include/stdint.h4 Apr 2007 01:27:08 -
@@ -1,6 +1,6 @@
 /* stdint.h - integer types
 
-   Copyright 2003, 2006 Red Hat, Inc.
+   Copyright 2003, 2006, 2007 Red Hat, Inc.
 
 This file is part of Cygwin.
 
@@ -158,8 +158,8 @@ typedef unsigned long long uintmax_t;
 #endif
 
 #ifndef WINT_MIN
-#define WINT_MIN (-2147483647 - 1)
-#define WINT_MAX (2147483647)
+#define WINT_MIN 0
+#define WINT_MAX UINT_MAX
 #endif
 
 /* Macros for minimum-width integer constant expressions */

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/

RE: grep and exact matches help..

2007-04-03 Thread Dave Korn
On 03 April 2007 23:28, Matthew Woehlke wrote:

> Thrall, Bryan wrote:
>> Gary Johnson wrote on Tuesday, April 03, 2007 5:05 PM:
>>> If you're piping 'ls' into another command, the -1 isn't necessary.
>>> 'ls' detects that its stdout is not a tty and delivers single-column
>>> output automatically.
>> 
>> Not when you use 'ls -l':
> 
> Sure it does. There is still only one file per line. :-)

  It's about getting rid of the perms and datestamp of course.  Like I said in
my original post that everybody snipped...


cheers,
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



httpd

2007-04-03 Thread Terry Bailey

Hi,

I am running Cygwin on Windows 2003.  What is the best way to 
automatically start /usr/sbin/httpd automatically when I boot Windows?


Thanks,

Terry Bailey


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: httpd

2007-04-03 Thread Igor Peshansky
On Tue, 3 Apr 2007, Terry Bailey wrote:

> I am running Cygwin on Windows 2003.  What is the best way to
> automatically start /usr/sbin/httpd automatically when I boot Windows?

Install it as a service.  To see how to do this on Win2k3, examine the
ssh-host-config script from the openssh package.  You might also want to
read the ntsec section of the User's Guide.
HTH,
Igor
-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED] | [EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_Igor Peshansky, Ph.D. (name changed!)
 |,4-  ) )-,_. ,\ (  `'-'   old name: Igor Pechtchanski
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

Freedom is just another word for "nothing left to lose"...  -- Janis Joplin

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: [Packaging error] Re: [ANNOUNCEMENT] Updated: mingw-runtime-3.12-1

2007-04-03 Thread Christopher Faylor
On Tue, Apr 03, 2007 at 07:40:52PM -0400, Chris Sutcliffe wrote:
>>> I've made a new version of the mingw-runtime available for download.
>>> For a list of changes see below.
>>
>>Man pages should go to /usr/share/man/...
>
>I thought it was decided to keep the MinGW Runtime man pages separate
>from the Cygwin man pages?

Yes, it was, but I don't remember concluding that putting them in
/usr/man was the solution.  Please either don't install them at all or
put them in a mingw-specific location.

cgf

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/