Hi,
As a final small suggestion, you should try
installing MOSEK using the MSI installer (link to download win64 installer) and then
restart your system before installing Rmosek in the usual fashion. You can see if the MOSEK binary directory is listed under PATH by issuing the command echo %PATH% in the command prompt.
Regarding what "builder.R" does: it will set the variables that are used during the compilation of Rmosek. But, when loading the library, it is windows that needs to know where the MOSEK libraries are. That is done via the PATH variable.
If nothing has worked so far, then you can do the following to debug your issue:
1.) Install Rmosek like usual but turn off test loading in the final step, i.e. use the call install.rmosek(INSTALL_opts="--no-test-load"). This should then allow the installation to go through without any issues.
2.) Install
WinDbg to your system (you only need WinDbg, so you can uncheck all the other options that will be suggested when installing Windows SDK).
3.) Open a command prompt, type C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\gflags /i Rterm.exe +sls. (gflags is usually installed on the path shown)
4.) Start an R session and get the associated process id by Sys.getpid()
5.) Launch WinDbg (found in the same folder as gflags), press F6 and type in the process id from the previous step. Type 'g' in the prompt that opens and press enter.
6.) Now, go back to the R session and try library(Rmosek) in the R process you started. This will lead to a library load failure (similar to what you have been seeing so far during your installation process).
7.) Within the windbg prompt (from step 5), you will be able to see which DLL load failure was the culprit.
Now, if the DLL that cannot be loaded turns out to be mosek64_9_3.dll, then it essentially means that MOSEK was not installed correctly in the first place. In any case, I ask that you share the output of step 7 above so that I can see if it is something I can help with.
I hope this helps.
Regards,
Utkarsh