Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , 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: Tue, 21 Dec 2004 15:25:47 -0500 (EST) From: Igor Pechtchanski Reply-To: cygwin AT cygwin DOT com To: george young cc: cygwin AT cygwin DOT com Subject: Re: can a postinstall script be other than shell? In-Reply-To: <20041221134503.2def234b.gry@ll.mit.edu> Message-ID: References: <20041221134503 DOT 2def234b DOT gry AT ll DOT mit DOT edu> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Tue, 21 Dec 2004, george young wrote: > Can a postinstall script be other than a shell script? > > I gather that setup looks for *.sh, but if I name a file > /etc/postinstall/foobar.sh, and it contains: > > #!/bin/python > ...some python code... > > will it work? Or do I have to have a skeleton shell script > that calls my python script? Yes. A postinstall script is invoked by calling 'sh -c script' (as opposed to 'sh script') so it should honor the shebang line. In other words, it will work. Note, however, that if python acquires a postinstall script at some point, you'll need to make sure that by the time your postinstall script runs, python's postinstall script has run. Setup has logic for this, but due to one of its numerous bugs, postinstall scripts aren't run in dependency order. Igor -- 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! "The Sun will pass between the Earth and the Moon tonight for a total Lunar eclipse..." -- WCBS Radio Newsbrief, Oct 27 2004, 12:01 pm EDT -- 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/