This is the mail archive of the
cygwin
mailing list for the Cygwin project.
How do start a cygwin shell session from a script ?
- From: Timothy Madden <terminatorul at gmail dot com>
- To: cygwin at cygwin dot com
- Date: Mon, 12 May 2014 13:12:23 +0300
- Subject: How do start a cygwin shell session from a script ?
- Authentication-results: sourceware.org; auth=none
Hello
I have a CMake build script for my application, that among other
things tries to build libvpx (open-source video codec, see
webmproject.org).
libvpx library v1.3.0 compiles fine by hand when I open a cygwin
terminal from the Windows start menu and type in the needed
`configure`; `make` and `make install` commands.
But when I try to invoke the cygwin shell from my build script, to run
the same 3 commands with the -lc option to sh.exe (same command line),
something happens and the build commands no longer work like in the
real mintty terminal. Then my build fails.
I believe there is something in the cygwin shell session or
environment that I do not know how to set right when invoking
$(CYGWIN_DIR)/bin/sh from my CMake script.
Is there a way for me to start a cygwin shell session from the build
script, that is identical to the one that opens in the mintty terminal
from the start menu, and run some commands there ?
I checked the environment variables and umask in the mintty terminal
and in a /bin/sh session that I launch, they are the same in both
cases. I tried using /bin/sh, /bin/bash, /bin/dash, with both --login
and -c options. But the automated build always fails, and the manual
build works.
Thank you,
Timothy Madden
--
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