www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2011/12/02/12:39:43

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-2.7 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD
X-Spam-Check-By: sourceware.org
Message-ID: <4ED90D35.6070306@etr-usa.com>
Date: Fri, 02 Dec 2011 10:39:01 -0700
From: Warren Young <warren AT etr-usa DOT com>
User-Agent: Mozilla/5.0 (Windows NT 6.0; WOW64; rv:8.0) Gecko/20111105 Thunderbird/8.0
MIME-Version: 1.0
To: Cygwin-L <cygwin AT cygwin DOT com>
Subject: Re: best way to prevent a cygwin build?
References: <4ED88260 DOT 8010004 AT cs DOT cmu DOT edu>
In-Reply-To: <4ED88260.8010004@cs.cmu.edu>
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
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

On 12/2/2011 12:46 AM, Paul Allen Newell wrote:
>
> I am not happy with having to run two separate source trees and would
> like a way (as in "best standard") to add something to any Maya makefile
> which will prevent execution if it is being compiled on Cygwin.

You might get better answers if you give an example of what you mean by 
"prevent execution".  Not because we don't know what that means in 
general, but because it *is* too general.

For example, if what you were after is to have some programs in a system 
compiled conditionally, Automake + Autoconf makes that easy:

https://www.gnu.org/s/hello/manual/automake/Conditional-Programs.html

If you want something else suppressed, the answer might be different.

Generally speaking, any time you want to do some up-front tests for 
platform compatibility issues that affect how a program gets built, 
Autoconf is probably a good answer.  It is not a pretty tool, but it's 
one of those tools that keeps getting reinvented poorly, so it remains 
the most popular out of lack of better alternatives.

On one of my projects, I use another Automake competitor, Bakefile. 
Bakefile builds Autoconf Makefile.in files, generic GNU Makefiles, 
Visual C++ project files, Xcode project files, etc., all from a single 
high-level description of what you want built.  You can include things 
conditionally based on platform or pretty much any criterion you can 
code up in a Python extension to Bakefile.  Bakefile is not in the 
Cygwin package repo, however, partly because it doesn't build cleanly on 
Cygwin.  The native Windows port works just fine with Cygwin, though.

You might also look at cmake, which competes with the Autotools and 
Bakefile, and *is* in the Cygwin package repo.  I can't tell you 
anything more about it.

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

- Raw text -


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