[prev in list] [next in list] [prev in thread] [next in thread] 

List:       unison-hackers
Subject:    Re: [unison-hackers] 2.9.102 Makefile error in Cygwin
From:       Derek Rayside <drayside () MIT ! EDU>
Date:       2004-09-04 19:45:54
Message-ID: Pine.LNX.4.58L.0409041539100.9179 () athena ! lcs ! mit ! edu
[Download RAW message or body]

Here's how I deal with this OSTYPE problem in the Alloy Makefile.
This deals with some variances in the values of OSTYPE on Cygwin, RedHat,
and Mac OSX.


ifndef OSTYPE
    OSTYPE := $(shell uname)

    # however, uname returns "Darwin" instead of "darwin" or "darwin6.0"
    # so let's get things into lower case
    OSTYPE := $(subst Darwin,darwin,$(OSTYPE))

else
    # this is for redhat, which says "linux-gnu" instead of "linux"
    ifeq (linux, $(findstring linux,$(OSTYPE)))
        OSTYPE = linux
    endif

endif


Derek.


On Sat, 4 Sep 2004, Andrew Schulman wrote:

> Yesterday I sent a message to this group about linking failing in Cygwin.  I
> haven't seen the message posted, but I do know the reason now.
>
> The problem is that src/Makefile.OCaml isn't correctly guessing the OSTYPE or
> OSARCH in Cygwin.  In Cygwin, OSTYPE seems to be a function of the shell, not
> an environment variable:
>
> $ echo $OSTYPE
> cygwin
> $ env | grep OSTYPE
> $
>
> As a result the Makefile uses OSTYPE= and OSARCH=, causing it to introduce
> CLIBS+=-cclib -lutil, which breaks the linking step.
>
> I haven't worked out how to detect Cygwin/gcc correctly, but a workaround for
> now is to run 'OSTYPE=win32gnuc make' or 'OSCOMP=cygwingnuc make'.  A
> permanent fix might be as simple as adding 'OSTYPE ?= $(shell echo $$OSTYPE)'
> at the top of src/Makefile.OCaml.
>
> Andrew.
>
>
>
>
> Yahoo! Groups Links
>
>
>
>
>
>


------------------------ Yahoo! Groups Sponsor --------------------~--> 
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/26EolB/TM
--------------------------------------------------------------------~-> 

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/unison-hackers/

<*> To unsubscribe from this group, send an email to:
    unison-hackers-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic