Menu

Compile error - Permission denied

01 Vlatce
2009-03-11
2012-09-26
  • 01 Vlatce

    01 Vlatce - 2009-03-11

    Hi.
    I have very big problem with program compiling in Dev C++. When i like to recompile my program i´ve got this error message from Dev C++:

    " Permission denied
    ld returned 1 exit status "

    Good to know that at the moment when i trying to recompile my program, it's not running in background but i still have this big problem for me.
    Can anyone help me, because this make me crazy.

     
    • cpns

      cpns - 2009-03-13

      > Actually i'm using Windows 7.

      Well if you rely on Beta OS code, you kind of have to accept incompatibilities - I am sure that is probably mentioned in the release notes for the OS!. Your responsibility as a Beta tester rather than a freeloader is report such incompatabilities.

      Why would you be at the leading (bleeding) edge of OS technology while trying to use a circa-2004 GCC release!?

      > I was tryed and CodeBlocks compiler

      Like Dev-C++ Code::Blocks is not a compiler. They both use the MinGW/GCC by default. The last official release of MinGW was for GCC 3.4.3 released November 2004.

      I stand by my suggestion that you use a different tool.

      Clifford

       
    • Wayne Keen

      Wayne Keen - 2009-03-13

      Historical note for other readers of this thread:

      The most recent release of Dev actually predates Vista, (as does the version
      of MinGW it uses, which I think is also true for Code::Blocks last release
      version) - and there were significant problems with Vista compatability,
      and still are, since there hasn't been a new release in forever.

      If you are going to run Vista + 1 (i.e. Win 7), odds are, you will probably
      some problems since nothing has changed since before Vista.

      Wayne

       
    • 01 Vlatce

      01 Vlatce - 2009-03-13

      My firend tryed Dev-C++ on his Vista SP1 and Vista without SP, but and he gets the same problem. So, the problem is not the beta version.

       
      • cpns

        cpns - 2009-03-13

        Well you will recall that I gave the same advice when I thought you were using Vista.

        Dev-C++ is known to have issues with Vista, there is no reason to believe that it is fixed in 7. The difference is that we have some experience getting it to work on Vista, with 7 all bets are off.

        I suspect it can be made to work, but IMO life is too short and time too precious to waste on debugging the tool rather than your own code.

        If you will persevere, advice on working with Vista is provided in the " PLEASE READ BEFORE POSTING A QUESTION" thread. If you have done that and it still fails, do yourself a favour and get a tool that just works!

        Clifford

         
    • cpns

      cpns - 2009-03-13

      On a different note; if you are are relying on this PC to get work done, you probably should not have installed an unfinished OS as your only option. I would suggest that you use Microsoft Virtual PC or VMWare Server (both free) to install the Beta OS as a virtual machine. That way when it all goes wrong, you are not completely stuffed.

       
    • Wayne Keen

      Wayne Keen - 2009-03-13

      It should be noted that the problems that we have seen in the past related
      to use of Dev with Vista have been largely related to getting code to
      compile at all initially (usually due to path issues). I do not recall seeing
      a problem involving a recompile of code that has compiled and run before
      successfully.

      Wayne

       
    • Wayne Keen

      Wayne Keen - 2009-03-11

      There are two ways that this happens:

      (1)Your code really is still running. If, after a restart, you can again compile, this is probably the case.

      (2) Sometimes antivirus programs can interfere with compilers. A compiler, after all, changes an executable, which is a virus-like activity.

      Wayne

       
      • Wayne Keen

        Wayne Keen - 2009-03-11

        One other possibility. Where is your file stored? Funny (bad) things can happen if it is stored in your Dev directory. We could tell this is, instead of just excerpting the error message, you would post the full compile log.

        Wayne

         
    • 01 Vlatce

      01 Vlatce - 2009-03-11

      Yes, after restart i can delete the .exe file. Before restart i even can't delete the file like he is locked by the system.
      Any solution?

      I tryed to turn off my NOD32, but the problem is still active.

      Otherwise my .exe file is stored on my desktop. And this is full error message.

      " Permission denied
      ld returned 1 exit status "

       
    • Wayne Keen

      Wayne Keen - 2009-03-11

      The compile log message is on the tab labeled "Compile Log", not the one labeled "Compiler". So, no, you did not post what I asked for. Please do so.
      The compile log contains FAR more information than any errors, it give

      I will give you better than even odds that your program, when run, did not
      in fact terminate.

      Wayne

       
    • 01 Vlatce

      01 Vlatce - 2009-03-11

      This is the error from the tab labeled Compile Log.

      Compiler: Default compiler
      Executing g++.exe...
      g++.exe "C:\Users\01 Vlatce\Desktop\vezba.cpp" -o "C:\Users\01 Vlatce\Desktop\vezba.exe" -I"D:\Dev-Cpp\lib\gcc\mingw32\3.4.2\include" -I"D:\Dev-Cpp\include\c++\3.4.2\backward" -I"D:\Dev-Cpp\include\c++\3.4.2\mingw32" -I"D:\Dev-Cpp\include\c++\3.4.2" -I"D:\Dev-Cpp\include" -L"D:\Dev-Cpp\lib"
      D:\Dev-Cpp\Bin..\lib\gcc\mingw32\3.4.2........\mingw32\bin\ld.exe: cannot open output file C:\Users\01 Vlatce\Desktop\vezba.exe: Permission denied
      collect2: ld returned 1 exit status

      Execution terminated

       
    • Wayne Keen

      Wayne Keen - 2009-03-11

      It is a very bad idea to store your project in a path with spaces in it, like:

      C:\Users\01 Vlatce\Desktop\vezba.cpp

      Wayne

      p.s. Have your read the "Please Read Before Posting a Question" thread yet?

       
    • cpns

      cpns - 2009-03-12

      So in fact the "full error message" was:

      D:\Dev-Cpp\Bin..\lib\gcc\mingw32\3.4.2........\mingw32\bin\ld.exe: cannot open output file C:\Users\01 Vlatce\Desktop\vezba.exe: Permission denied

      The "Compiler" tab is a filtered version of the "Compile Log". It filters badly, and only really copes properly with compiler messages, not linker or system errors. Other than simple coding errors, teh useful information is in the Compile Log. It is also much easier to copy & paste that text in full.

      It may be the spaces (although that does not look to be teh case in this instance), or it may be that your process has not terminated correctly so the .exe is locked. Check the Task Manager process list to see.

      Clifford

       
    • 01 Vlatce

      01 Vlatce - 2009-03-12

      I tryed to compile my program in D:\ and C:\ but the same error is appear again.
      I checked the task manager and the program was not running, but the error is appeared again, again, again... :S
      And after the error my compiled .exe program was locked by the system, and i even can't to open the compiled program. Look this image:

      http://i39.tinypic.com/15zmplu.jpg

       
    • cpns

      cpns - 2009-03-12

      We have seen this symptom on a number of occasions where the problem has never been resolved (whether by misfortune or incompetence I cannot say).

      That, coupled with the fact that you are using Vista suggests that it may be time to give up and seek a more reliable alternative. VC++ 2008 Express Edition is both free and to be honest better than Dev-C++. If you want to get work done rather than dick about troubleshooting software that is frankly too long in the tooth for Vista, that is my recommendation.

      Clifford

       
    • 01 Vlatce

      01 Vlatce - 2009-03-12

      Actually i'm using Windows 7. You suggest me to use VC++ 2008 Express Edition, but i think that the problem is not in Dev-C++. I was tryed and CodeBlocks compiler and i receive the same error and the same problem - .exe program locking.

      So my question is: Can anyone tell me how i can repair that problem (locking the programs) in my Windows? Do i have to kill some process, service?

       
    • Wayne Keen

      Wayne Keen - 2009-03-12

      The following is going to sound like I am being mean and picking on you,
      which is only partially my intent. ;)

      We are 10 posts into this thread before you reveal that you are using an
      operating system that is beta, and that very few or none of us are running?
      Doesn't that seem like the sort of information that should be presented
      in the FIRST post?

      Wayne

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.