mcc generates an executable - exe runs but can't actually plot a map located in a matlab toolbox - how do I compile to get the plotting working?

7 views (last 30 days)
I've tried the following:
mcc -m QuickLook
It generates my executable and when i run it, the GUI opens just fine. When I go to plot a map onto an axes on my figure, it is trying to access the following file:
C:\Program Files\MATLAB\R2010bSP1\toolbox\map\mapdemos\landareas.shp
It cannot find the file and the executable crashes and the figure is left incomplete.
If I just run the GUI in Matlab, it works. If I run the executable in MATLAB (or outside) it behaves the same way and crashes. How do I compile so that this file is included?
My path includes all necessary recursive paths already. I also tried using -I and including a path to the mapdemos folder but that didn't resolve the issue either. Help!

Answers (1)

Walter Roberson
Walter Roberson on 28 Jan 2014
Did you try using -a to add the file to your build? You might also have to slightly modify the calling sequence of whatever uses the file, in order that it will know where to look for the file. See ctfroot()
  7 Comments
Matt
Matt on 29 Jan 2014
Well my new question then would be why the -a option didn't appear to do a darn thing for me. I added the file to my current working directory and it DID add it, but it did not add it with the -a option. Any guesses as to why not?

Sign in to comment.

Categories

Find more on Standalone Applications in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!