This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: cygwin usage on Windows


Greetings, Csaba Raduly!

>> I have a question that I am sure must have been addressed before, but I
>> cannot find it after days of searching. Of course I am a Newbie with cygwin.
>>
>> I have completed an installation, successfully, I think on an x386 platform
>> w/ Win XP SP3 OS.
>>
>> I can compile a C program from within the cywgin shell (terminal) but cannot
>> do so from a windows page.

This is not strictly Cygwin question, but a common OS level knowledge that is
necessary to operate any complex suite of tools.

>> Attempting to run the executable from the latter,  generate a terse error
>> response, "This application has failed to start because cygwin1.dll was not
>> found. Re-installing the application may fix this problem".
>>
>> Is this the actual mode of performance (executable to be run only from the
>> cygwin shell and not from Windos page) or have I lost functionality along
>> the way?

I have no idea, what you mean by "windows page", but if you want to run
compiled programs directly, you have two choices:

1. If you just need them to work, compile them as native applications. They
would know nothing of Cygwin, would run in native environment and generally
"just work". 
2. If you intend to use Cygwin tools (such as grep, diff, etc.) in your daily
works, along with your compiled tools, make Cygwin part of your system, e.g.
by adding location of cygwin1.dll to your PATH environment variable.

> Cygwin programs need to be able to load cygwin1.dll
> You need to add C:\cygwin\bin to the Windows PATH; then cygwin1.dll
> will be found even when running programs from the command prompt.
> This is a step you have to perform manually; the installer does not do it.

This is not about cygwin1.dll only, else it would be enough to add it to app
paths and call it a day. This is about whole suite of tools that POSIX
standard mandates to be available at specific location, but scripts often
neglect to specify it explicitly.

> There are some potential name clashes between Windows programs and
> Cygwin programs; e.g. find

I would rather call ping. Windows(DOS) FIND is such a poor tool, I seldom
remember using it for good cause.

> If you put C:\cygwin\bin before C:\windows\system32 and type just the
> name of the program, you'll get the Cygwin version even from a Windows
> prompt (which is what I usually do, because I can't remember using the
> Windows version of find). If you put C:\cygwin\bin after
> C:\Windows\system32, you'll get the Windows version.

> From a Cygwin shell, you get the Cygwin version by default (unless you
> change the path in your bash startup script), because Cygwin does some
> magic with the path to get its own bin directory to the front.


--
WBR,
Andrey Repin (anrdaemon@yandex.ru) 17.03.2014, <18:07>

Sorry for my terrible english...


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]