This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

fatal error #6001: cannot open file Permission denied

Guru 15580 points

CCSV5.5, MSP430 tools, Windows 7 64-bit

What in the world would suddenly cause this permission error?

fatal error #6001: cannot open file
"C:\ti\ccsv5\tools\compiler\msp430_4.2.1\lib\rts430x_lc_ld_eabi.lib":
<Linking>
Permission denied

I've seen it once before but cannot remember how to get rid of it. 

  • I don't have much experience with Windows permissions issues.  I'm looking for some help on that.  In the meantime, I have one suggestion which may help.  

    Using Windows File Explorer, go to the directory which contains that RTS library file.  Right click on it and choose Properties.  Click on the Security tab.  You'll see a button for editing the file permissions.  Perhaps some change in the file permissions will make it work.

    Thanks and regards,

    -George

  • George,

    Thanks for the tip. However, I now remember what fixed this problem in the past. I SIMPLY CHANGED COMPILER VERSIONS in Project->Properties.

    I know it makes no sense, but I found this fix somewhere on the forum and it worked. Now, on to other more important issues, like debugging my own code...:)

  • So after two years this is still a problem (since I am now unable to change the compiler version for this project). I have narrowed down the problem to the attributes of this specific file (C:\ti\ccsv5\tools\compiler\msp430_4.2.1\lib\rts430x_lc_ld_eabi.lib). For some reason this file has different security attributes than all other .lib files in this folder. I have tried in vain to change the security attributes but nothing seems to help.

    Can someone tell me why Windows 7 is classifying ONLY this file with special administrator privileges?

    Here are two screen shots of the properties windows of the secured file (rts430x_lc_ld_eabi.lib) and an usecured file in the same folder (rts430x_lc_sd_eabi.lib).

    As you can see, the first file has additional adminstrator requirements, whereas the second file does not.

    How do I change the attributes of the first file to match all others?

  • MikeH said:
    For some reason this file has different security attributes than all other .lib files in this folder. I have tried in vain to change the security attributes but nothing seems to help.

    Can someone tell me why Windows 7 is classifying ONLY this file with special administrator privileges?

    The rts430x_lc_ld_eabi.lib file is not present after a compiler installation, but is created by "mklib" when first needed.

    Whereas rts430x_lc_sd_eabi.lib is present after a compiler installation.

    Therefore, the difference in security attributes for rts430x_lc_ld_eabi.lib may be caused by the user settings when a project which uses rts430x_lc_sd_eabi.lib (EABI with Large code model and Large data model) is first built.

    On a Windows 7 64-bit machine I created a project which caused rts430x_lc_ld_eabi.lib to be built and it didn't have any difference security attributes from the other .lib files.

    I don't understand what in Windows 7 could cause the permission problem. To investigate you could try:

    a) Rename the existing C:\ti\ccsv5\tools\compiler\msp430_4.2.1\lib directory to a different name, e.g. lib_no_permission

    [As an experiment found that Windows 7 doesn't prevent you renaming a directory if you don't have permission to a file within the directory]

    b) Create a new C:\ti\ccsv5\tools\compiler\msp430_4.2.1\lib directory, and copy the contents for the original directory with the exception of the  rts430x_lc_ld_eabi.lib file.

    c) Re-build the CCS project which uses the rts430x_lc_ld_eabi.lib from the 4.2.1 compiler. This should cause the linker to re-create the rts430x_lc_ld_eabi.lib library. If that succeeds, then check the security attributes on the newly created rts430x_lc_ld_eabi.lib 

  • mklib does not currently deal with Windows-specific attributes, so generated libraries should have the default attributes.  I'm not familiar with how Windows deals with default attributes, so I'll have to do a little research.

    In the meantime, you should work around the problem by building all of the libraries once outside of CCS and setting the appropriate permissions.  You can build all of the missing libraries as indicated at http://processors.wiki.ti.com/index.php/Mklib#Shared_or_read-only_library_directory. Then set the attributes appropriately.

    TI defect report SDSCM00049493 (unfixed, unpublished) is a request for a study of directory permissions problems when using mklib to build libraries.  However, it is not yet resolved.  I mention it to tie this thread to the defect report.

  • I'm a chinese user ,i have met the same problem also .Could you tell me how did you get rid of the problem ? Detail message will be appericate.
    thank you
  • I am unable to reproduce the problem.  Thus I am not sure what causes it, or how to fix it.  In addition to the suggestions already in the this thread, here is another idea to consider.

    Rename the problem library and build again.  The linker will invoke mklib to create the now missing library from scratch.  This newly built library may behave better.

    Thanks and regards,

    -George

  • I had the exact same problem with a Library file, cannot open file permission denied. What fixed it for me was the following: view file properties, Security tab, Advanced, change permissions ... then click "Enable inheritance". Now recompile and the error goes away.