delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/10/14/13:21:44

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
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
Date: Thu, 14 Oct 2004 13:21:32 -0400 (EDT)
From: Igor Pechtchanski <pechtcha AT cs DOT nyu DOT edu>
Reply-To: cygwin AT cygwin DOT com
To: Robert Pendell <shinji257 AT gmail DOT com>
cc: cygwin AT cygwin DOT com
Subject: Re: non-interactive cygwin setup
In-Reply-To: <fdb072ec041014005024de5e85@mail.gmail.com>
Message-ID: <Pine.GSO.4.61.0410141320180.24756@slinky.cs.nyu.edu>
References: <20041013210453 DOT GJ8866 AT trixie DOT casa DOT cgf DOT cx> <-5983807241930201449 AT unknownmsgid> <fdb072ec041014005024de5e85 AT mail DOT gmail DOT com>
MIME-Version: 1.0
X-Scanned-By: MIMEDefang 2.39

On Thu, 14 Oct 2004, Robert Pendell wrote:

> Well there are ways to make a console/gui hybrid application (or at
> least I read that it could be done) but there are a few tricks that
> you have to pull.  It would be invisible to the end-user in the end
> though.

];-> <http://cygwin.com/acronyms/#PTC> ];->

> On Thu, 14 Oct 2004 01:12:20 -0500, Gary R. Van Sickle <g DOT r DOT vansickle AT XXXXXXXX DOT XXX DOT XXX> wrote:

Oh, and <http://cygwin.com/acronyms/#PCYMTNQREAIYR>.  Thanks.
	Igor

> > [snip]
> > > >I thought if a GUI app called printf it generally caused a console
> > > >to be opened for it.  Maybe that's only with msvcrt.  In any case,
> > > >the fact is that it is being run from a cmdline and so it certainly
> > > >can communicate with the console.  The presence of command-line
> > > >options in argc/argv could be taken as a fairly strong hint that it
> > > >was being run from a shell rather than an icon.  And there's always
> > > >"isatty (1)" if you really really want to be sure.
> > >
> > > This is a windows limitation.  GUI apps (apps created with
> > > -mwindows) can't send output to or receive input from the
> > > console.  Of course, a GUI can interpret command line
> > > information.  It just cannot send output to the console that
> > > started it.
> > >
> > > You could use AllocConsole to create a separate console which
> > > the GUI could then use, however.
> >
> > Here's a maybe-less-icky way to do it.  Have two exes, one "setup.exe"
> > which is a 100% command-line program that normally just spawns
> > "winsetup.exe", the current GUI setup, and goes away.  Give it
> > "--help", and it prints help in the regular command-line way and
> > exits.  Yeah, two exes, but worse tragedies have happened.
> > --
> > Gary R. Van Sickle

-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha AT cs DOT nyu DOT edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor AT watson DOT ibm DOT com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Happiness lies in being privileged to work hard for long hours in doing
whatever you think is worth doing."  -- Dr. Jubal Harshaw

--
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/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019