Re: Wickham-Jones ExtendGraphics for OS X?
- To: mathgroup at smc.vnet.net
- Subject: [mg125204] Re: Wickham-Jones ExtendGraphics for OS X?
- From: Murray Eisenberg <murray at math.umass.edu>
- Date: Wed, 29 Feb 2012 07:21:06 -0500 (EST)
- Delivered-to: email@example.com
- References: <201202271142.GAA29404@smc.vnet.net>
- Reply-to: murray at math.umass.edu
I can start each of "image" and "mandelbrot" from the command line. I can give each a link-name, as you showed. But I still cannot get any of the ExtendGraphics packages delaunay.m, mandelbrot.m, Contour.m to load properly inside Mathematica -- in each case getting an error that the specified file "is not a MathLink executable". The value of DYLD_LIBRARY_PATH is empty, and what I read says this variable is not supposed to be used in OS X anymore. (I'm getting well beyond my depth here...) On 2/27/12 6:42 AM, Patrick Scheibe wrote: > Hi Murray, > > yes, the gcc complains about the code produced by mprep, but this is a > warning only and no error . On my MacBook I get the same warning, > when I use gcc, still the MathLink program runs fine. > > Did you check to start the the "image" program from the command-line and > give it a link-name like "blub" and try to install this link by > > lnk = Install[LinkConnect["blub"]] > > inside Mathematica? If this runs, then your DYLD_LIBRARY_PATH is maybe > not usable inside Mathematica. In this case you have to create/adjust > your ~/.MacOSX/environment.plist file so that GUI-programs like > Mathematica have a correct DYLD_LIBRARY_PATH. See here  how to do > that. > > Cheers > Patrick > >  You may know the famous joke: > A guy is standing on the corner of the street smoking one cigarette > after another. A lady walking by notices him and says > "Hey, don't you know that those things can kill you? I mean, didn't you > see the giant warning on the box?!" > "That's OK" says the guy, puffing casually "I'm a computer programmer" > "So? What's that got to do with anything?" > "We don't care about warnings. We only care about errors." > >  > https://developer.apple.com/library/mac/#documentation/MacOSX/Conceptual/BPRuntimeConfig/Articles/EnvironmentVars.html > > On Sun, 2012-02-26 at 04:22 -0500, Murray Eisenberg wrote: >> Compiling as you showed worked just fine to produce the MathLink >> executables 'delaunay' and 'contour.' >> >> However, there were compiler warnings when I applied gcc for both >> 'image' and 'mandelbrot', as follows (where i use "\" for continuation >> of input because the long command line input won't fit on a single line >> here: >> >> $ $MLROOT/mprep image.tm> image.tm.c >> $ gcc -o image -I$MLROOT -L$MLROOT -lMLi3 -lstdc++ -framework \ >> Foundation -lm image.tm.c >> image.tm.c: In function =91sendimage=92: >> image.tm.c:308: warning: incompatible implicit declaration of >> built-in function =91malloc=92 >> image.tm.c:321: warning: incompatible implicit declaration of >> built-in function =91sprintf=92 >> image.tm.c: At top level: >> image.tm.c:344: warning: prototype for =91sendimage=92 follows >> non-prototype definition >> >> $ $MLROOT/mprep mandelbrot.tm> mandelbrot.tm.c >> $ gcc -o mandelbrot -I$MLROOT -L$MLROOT -lMLi3 -lstdc++ -framework \ >> Foundation -lm mandelbrot.tm.c >> mandelbrot.tm.c:402: warning: prototype for =91sendimage=92 follows >> non-prototype definition >> >> And then, of course, when I load either ExtendGraphics`Image` or >> ExtendGraphics`Mandelbrot`, I get an error: >> >> LinkOpen::linke: Specified file is not a MathLink executable... >> >> Can you suggest how to fix this. Or, in the alternative, supply >> Macintosh OS X versions of the executables 'mandelbrot' and 'image' >> (compatible with current OS X versions). >> >> On 2/20/12 2:44 AM, Patrick Scheibe wrote: >>> Hi Murray, >>> >>> did you try to compile this by yourself? Here on Linux it builds fine >>> and it does not need any Solaris library. The paths in the "build" file >>> are outdated. That's why you cannot simply use it. Try it on the >>> commandline by yourself. What you have to find is the MathLink dev >>> directory in your Mathematica installation. Here it is under >>> >>> /usr/local/Wolfram/Mathematica/8.0/SystemFiles/Links/MathLink/DeveloperKit/Linux-x86-64/ >>> >>> I assume on your machine it will be under something like >>> >>> /Applications/Mathematica.app/SystemFiles/Links/MathLink/DeveloperKit/CompilerAdditions/ >>> >>> Let's say this path is $MLROOT, then you have to do the following: >>> >>> $MLROOT/mprep delaunay.tm> delaunay.tm.c >>> gcc -o delaunay -I$MLROOT -L$MLROOT -lMLi3 \ >>> -lstdc++ -framework Foundation -lm delaunay.tm.c >>> >>> (Remove the backslash and input the last two lines as one!) >>> This should compile fine the delaunay-triangulation and should work for >>> all the other programms too. >>> >>> Cheers >>> Patrick >>> >>> >>> On Sun, 2012-02-19 at 06:29 -0500, Murray Eisenberg wrote: >>>> Many years ago, Tom Wickham-Jones wrote a book, "Mathematica Graphics:= >> >>>> Techniques& Applications", which I own. It was accompanied by the >>>> ExtendGraphics application, which included nice packages for drawing the >>>> Mandelbrot set and Delaunay set, among other things. >>>> >>>> The application is also available at: >>>> >>>> http://library.wolfram.com/infocenter/Books/3753/ >>>> >>>> But they don't work with Mathematica 8, at least under Mac OS X. The >>>> .zip download includes Windows .exe binaries; the .tar download includes >>>> ingredients for compiling binaries (including a "build" file, but the >>>> build fails under OS X due to missing libraries from Solaris). >>>> >>>> Anybody have a version of the requisite binary files that work with >>>> current Mathematica under OS X 10.7 (Lion)? >>>> >>> >>> >>> >> >> -- >> Murray Eisenberg murray at math.umass.edu >> Mathematics& Statistics Dept. >> Lederle Graduate Research Tower phone 413 549-1020 (H) >> University of Massachusetts 413 545-2859 (W) >> 710 North Pleasant Street fax 413 545-1801 >> Amherst, MA 01003-9305 >> >> > > > -- Murray Eisenberg murray at math.umass.edu Mathematics & Statistics Dept. Lederle Graduate Research Tower phone 413 549-1020 (H) University of Massachusetts 413 545-2859 (W) 710 North Pleasant Street fax 413 545-1801 Amherst, MA 01003-9305
- Re: Wickham-Jones ExtendGraphics for OS X?
- From: Patrick Scheibe <firstname.lastname@example.org>
- Re: Wickham-Jones ExtendGraphics for OS X?