|
From: Andrea D'A. <and...@gm...> - 2011-02-17 09:28:00
|
Hello, in 4.4.2 src/variable.c:247 the _Macintosh macro is checked to see if the system is a Mac but who's supposed to set such a macro? It's not one of gcc's predefined macro on OS X (not since a few major versions at least). The current resulting default fontpath is /usr/X11R6/lib/X11/fonts/Type1 that isn't even present on a standard 10.6 system. I've changed _Macintosh to __APPLE__ in order to have a consistent default fontpath value [1] Btw why do a few paths in variable.c have a trailing exclamation mark while others don't? Regards -- Andrea [1] http://trac.macports.org/browser/trunk/dports/math/gnuplot/files/patch-src-variable_c.diff |
|
From: Ethan A M. <sf...@us...> - 2011-02-18 19:44:15
|
On Thursday, February 17, 2011 01:27:49 am Andrea D'Amore wrote: > Hello, > in 4.4.2 src/variable.c:247 the _Macintosh macro is checked to see if > the system is a Mac but who's supposed to set such a macro? It's not > one of gcc's predefined macro on OS X (not since a few major versions > at least). I would guess that it dates back to pre-OSX days. Gnuplot's mac terminal was added sometime in the early 1990s, so maybe the macro brackets code added for compilation on a Mac Classic? Ethan |
|
From: Andrea D'A. <and...@gm...> - 2011-02-18 21:02:48
|
On Fri, Feb 18, 2011 at 8:42 PM, Ethan A Merritt <sf...@us...> wrote: > I would guess that it dates back to pre-OSX days. > Gnuplot's mac terminal was added sometime in the early 1990s, > so maybe the macro brackets code added for compilation on a Mac Classic? That's my guess too, I've found references to Metrowerks, author of Codewarrior, and Symantec compiler for mac. Nowadays that macro is useless and should be changed. > Ethan Regards -- Andrea |
|
From: Hans-Bernhard B. <HBB...@t-...> - 2011-02-18 22:06:21
|
On 18.02.2011 22:00, Andrea D'Amore wrote: > 2011/2/18 Hans-Bernhard Bröker<HBB...@t-...>: >> Yeah. But are those platforms themselves as consistent across versions as >> you're making gnuplot treat them? > > What platforms are you referring to with "those"? The old one that (still) defined _Macintosh, and the new one that defines __APPLE__ instead. Speaking of which, __APPLE__ seems a little too loose to be the identifying macro of Mac OS (whatever the current version of it is). >> I.e. are there really fonts in >> directories like /System/Library/Fonts etc. on a current-day MacOS? > Yes, there are. Well, OK then. |
|
From: Andrea D'A. <and...@gm...> - 2011-02-19 08:22:22
|
2011/2/18 Hans-Bernhard Bröker <HBB...@t-...>: > The old one that (still) defined _Macintosh, and the new one that defines > __APPLE__ instead. Do you mean changing that would break support for Apple's System serie of operating systems? Is there anyone on the list that can confirm such systems can still build current gnuplot sources? > Speaking of which, __APPLE__ seems a little too loose to > be the identifying macro of Mac OS (whatever the current version of it is). >From what I can see there's little choice, I've seen quite a few sources in MacPorts and they all use __APPLE__, these are macros on my system: $ gcc -dM -E - < /dev/null | grep -i "APPLE\|MAC\|DAR" #define __APPLE_CC__ 5664 #define __APPLE__ 1 #define __VERSION__ "4.2.1 (Apple Inc. build 5664)" #define __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ 1066 #define __MACH__ 1 >>> I.e. are there really fonts in >>> directories like /System/Library/Fonts etc. on a current-day MacOS? >> Yes, there are. > Well, OK then. Even if there weren't fonts an existing empty directory is still better than a directory not existing at all. Anyway those are defaults paths for font on OS X, they are respectively: system, installation specific and user fonts. Regards -- Andrea |
|
From: Andrea D'A. <and...@gm...> - 2011-02-18 21:00:45
|
2011/2/18 Hans-Bernhard Bröker <HBB...@t-...>: >> It's not one of gcc's predefined macro on OS X (not since a few major >> versions at least). > >> The current resulting default fontpath is >> /usr/X11R6/lib/X11/fonts/Type1 that isn't even present on a standard >> 10.6 system. >> I've changed _Macintosh to __APPLE__ in order to have a consistent >> default fontpath value [1] > > Yeah. But are those platforms themselves as consistent across versions as > you're making gnuplot treat them? What platforms are you referring to with "those"? > I.e. are there really fonts in > directories like /System/Library/Fonts etc. on a current-day MacOS? Yes, there are. Regards -- Andrea |