octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: MacOSX: ismac() implementation


From: John W. Eaton
Subject: Re: MacOSX: ismac() implementation
Date: Fri, 05 Oct 2007 17:54:05 -0400

On  5-Oct-2007, Thomas Treichl wrote:

| Hallo John,
| 
| I was working on this implementation and I had the idea to check for the 
| compiler macros that come with the XCode Mac developer tools (ie. the macro 
| __APPLE__) and to further check if we are running a Darwin kernel (producing 
| __MACH__ executables). Both #defines are set by gcc for Mac.

How reliable will this be if you use a different compiler?

| If you say we better should use a test for this then the only check I could 
| imagine is that we are again looking for a *darwin*
| canonical_host_type.

Config.guess uses information from uname:

    *:Darwin:*:*)
        UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
        case $UNAME_PROCESSOR in
            unknown) UNAME_PROCESSOR=powerpc ;;
        esac
        echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
        exit ;;

but I suppose even that could change.

| hope that the implementation that I send with this email is ok?

I'm still not sure what ismac() is useful for.  Is it just for Matlab
compatibility?  What is it used for in practice?

| Should Changelog descriptions normally also be part of a patch?

No, they rarely apply correctly because there are almost always some
other changes to those files that cause the context to fail to match.

It would be helful to prefix each set of entries with the file as I do
when I post patches to the list. (ChangeLog: src/ChangeLog:, etc.)

| 2007-10-05  Thomas Treichl  <address@hidden>
| 
|         * configure.in: Added '#define MACOS' for Apple Mac OS.
| 
| 2007-10-05  Thomas Treichl  <address@hidden>
| 
|         * toplev.cc: Added field for Mac OS in DEFUN octave_config_info.
| 
| 2007-10-05  Thomas Treichl  <address@hidden>
| 
|         * Makefile.in: Added ismac.m.
|         * ismac.m: New function.
|         * ispc.m: Added @seealso{ismac, isunix} in help text.
|         * isunix.m: Added @seealso{ismac, ispc} in help text.

These file names should have the subdirectory as well
(miscellaneous/Makefile:,  miscellaneous/ismac.m, etc.).

jwe
 


reply via email to

[Prev in Thread] Current Thread [Next in Thread]