X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=3.0 required=5.0 tests=AWL,BAYES_50,DENTIST_BODY,DKIM_SIGNED,DKIM_VALID X-Spam-Check-By: sourceware.org X-Yahoo-SMTP: 6hp7xDCswBAZFPiwXTBlX1ARAAZrOcR.nQ-- Message-ID: <4E7250F8.4010402@molconn.com> Date: Thu, 15 Sep 2011 15:24:40 -0400 From: LMH User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:6.0.2) Gecko/20110902 Firefox/6.0.2 SeaMonkey/2.3.3 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: How do I run a program compiled in cygwin from a program that is running in a Windows CMD shell? References: <4910244359 DOT 20110915185240 AT mtu-net DOT ru> <4E721B17 DOT 5080004 AT molconn DOT com> <4E7239CC DOT 9050209 AT cygwin DOT com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: 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 As stated, the mno-cygwin flag was depreciated in gcc 4. This was what you used to link to the windows c runtime instead of the cygwin dll. In other words, it let you compile with cygwin gcc and then run on a windows box that didn't have cygwin installed (very useful). Since some of your issue seemed to be with the cygwin environment, it seemed like detaching yourself from it at link time might be a good idea. Windows doesn't' know or care whether the app was compiled under gcc or visual studio if you used the no-cygwin flag, so I didn't see why it would matter how or where you called the app, from perl, bash, cmd, etc. I have never elevated to gcc 4 and have cygwin configured to only install gcc 3. I am sure you could have both installed and point to one or the other in your make file depending on what you want. If I remember right, the no-cygwin flag was depreciated before the "ming compatible cross compiler" was available, so I stayed with 3 at the time. I also had issues with 4.1 under linux. I had an app would give different floating point answers compiled wiht 4.1 compared to 3.4. This seems to have been fixed by 4.3 and the app compiled under 4.3 gives me the same answer as 3.4. I don't know if there was a bug in the early 4 versions, or what. This may have been an issue with gfortran and not gcc since it's a hybrid app. I also like the fact that 3 is closed and they aren't constantly changing the header files and such. It's very annoying to get code that compiled under an older version and won't compile any more because they changed 10 different header files and no I have to add 56 ifdef statements to compile under the new version. Version 3.4 does everything I need, so I have stuck with it, especially since I know how to cross compile with it. I suppose I will get around to getting version 4 working, but I have other fish in the pan for now. It seems like a cross compiled c app to launch your child process would be more portable, but I will look at the perl more closely later. I'm off to the dentist for now, fun, fun, fun. LMH Ted Byers wrote: > Larry Hall (Cygwin cygwin.com> writes: > >> >> On 9/15/2011 1:28 PM, Ted Byers wrote: >>> LMH molconn.com> writes: >> >> >> >>> What, exactly, does '-mno-cygwin' do? >>> >>> BTW: With gcc v 4.5.3, using 'G++ -mno-cygwin' followed by the other >>> commandline arguements needed to compile something results in an error > where >>> it complains '-mno-cygwin' is no longer valid (I forget the exact wording, > but >>> that is the gist of the error message I got). >> >> Right. '-mno-cygwin' is not a supported flag for gcc with version 4. It was >> there to allow a kind of cross compiler that targets Win32 instead of >> Cygwin. This is obviously not what you want anyway so it's of no >> consequence to you that the flag has been removed. There are now >> actual cross compilers available in Cygwin for gcc 4 that serve the purpose >> of the old '-mno-cygwin' flag. >> > Hi Larry, > > Thanks > > I installed only the gcc4 compilers (all of them, v4.5.3), but I didn't even > look for cross compilers. > > What is the name of the cross compilers (would they be those that > include 'mingw' in the name? Not having installed, them, perhaps this is a > naive question, but will they live alongside the gcc4 compilers without the > names of the compilers clashing? I recalled something about mingw, but > thought that was a completely different approach to having gcc on Windows, and > in the versions included with RTools, the names of the programs there would > definitely collide with those for gcc4 > > Thanks again > > Ted > > > -- > 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 > > -- 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