How do I change the "Default Installation Folder" in the matlab compiler to %ProgramFiles (x86)%

45 visualizzazioni (ultimi 30 giorni)
I am using the deploytool to make a standalone executable in Windows. In order to run correctly, I need the executable to be installed in a specific folder in "...\Program Files (x86)\..." rather than "...\Program Files\...".
I am given the options for %ProgramFiles% or %AppData% but cannot find a way to edit the default to something other than one of these two. I would appreciate any help in finding a way to change the default install location to the (x86) folder. Thanks for you help.
  2 Commenti
mohammad ibrahim
mohammad ibrahim il 25 Mar 2021
Hello
Now in 2021, can we change the default installation folder ?
actually, if the deployed application copies some file , the application should be installed in a folder where no administrative rights are required. "Program Files" needs usually administrative rights to allow copying files
if we cant change the default installation folder, is there a method to overcome the "administrative rights" issue ?
thanks
Chris Plumlee
Chris Plumlee il 30 Mag 2023
I agree this is an annoyance. I write manufacturing test programs and install them together in C:\[company name]\[test name] where they can be maintained together with other test programs.

Accedi per commentare.

Risposte (1)

Sruthi Ayloo
Sruthi Ayloo il 8 Lug 2014
Modificato: Sruthi Ayloo il 8 Lug 2014
From MATLAB R2013b onwards, there is no direct way to select a folder you want the executable to be installed. There is a workaround though. For the executable to be installed in Program Files (x86), select %Program Files% as the default installation folder and give the path as:
\..\Program Files (x86)\<executable folder name>\
This navigates to the folder where the Program Files is present. It then selects Program Files(x86) and then the folder where the executable has to be created. The self-extracting executable will respect these settings.
  2 Commenti
Dan Dresser
Dan Dresser il 30 Lug 2014
Modificato: Dan Dresser il 30 Lug 2014
What about earlier versions of Matlab then? I have 2011b and I'm trying to accomplish exactly this....
EDIT: Matlab and VS2008 are already installed....when I ask Matlab to locate installed compilers it misses VS2008 because it's looking in "...\Program Files\..." when it should be looking in "...\Program Files (x86)\..."
Thanks!
Thomas
Thomas il 25 Lug 2023
Modificato: Thomas il 25 Lug 2023
Using \..\ in the deploytool 'Default Installation folder' box to go to any location appears to have stopped working some time after 2019b.
You can now use the compiler.package.installer option 'DefaultInstallationDir' to specify the path directly. (results, ,'C:\XRite\BMSolveEXE')
You can also use createDeploymentScript to convert your existing .prj to a file, and then edit packageOpts.DefaultInstallationDir in the resulting output script. Instead of using '%ProgramFiles%\..\whatever', use '%SystemDrive%\whatever'.
(I am using 2023a.)

Accedi per commentare.

Categorie

Scopri di più su Introduction to Installation and Licensing in Help Center e File Exchange

Prodotti

Community Treasure Hunt

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

Start Hunting!

Translated by