User forums > General (but related to Code::Blocks)

windows 7 "permission denied" problem

<< < (5/7) > >>

Alpha:
Were there any warnings in the command prompt window?


--- Code: ---'g++' is not recognized as an internal or external command,
operable program or batch file.

--- End code ---
Means that your compiler is not on the path.

--- Quote from: Alpha on September 03, 2011, 06:31:36 pm ---First ensure mingw\bin is in your path
path C:\mingw\bin;%path%

--- End quote ---
I forgot to mention that C:\mingw\bin must (of course) point to your compiler's installation directory; on my computer, for example, it is C:\libraries\mingw, so I would type
path C:\libraries\mingw\bin;%path%


--- Code: ---g++: main.cpp: No such file or directory

--- End code ---
Means that you are in the wrong folder; type
G:
to switch to the G: drive, and
cd \
to ensure you are in the root of the drive.  Then your type
g++ main.cpp -o main.exe
to compile.  The resulting line should look like

--- Code: ---G:\>g++ main.cpp -o main.exe

--- End code ---
If there are no errors, it will produce main.exe (but it will not show any messages).

websnake:
on my computer mingw is installed on "C:\Program files\Codeblocks\Mingw"
i included it on my path successfully ( i know about DOS commands a bit).

(i found no difference on use of g++ of linux terminal and mingw's g++ btw i am not too familiar with g++)

there was no error using g++ it was just showing tons of messages but no output windows executable file or object file.

i am feeling that permission denied thing is mingw's problem because when i get the access denied error it show something is wrong about ld.exe which is a mingw file(i found that on mingw directory.)




 

Jenna:

--- Quote from: websnake on September 04, 2011, 07:57:24 pm ---there was no error using g++ it was just showing tons of messages but no output windows executable file or object file.

--- End quote ---
If you compile on the commandline, and the file does not have any errors, there should not be any messages.

Alpha:
If there is a mingw problem, I am not sure what can be done (except perhaps install a new version if you have not - like the unofficial TDM).  One other thing I can think of is that one of your project's settings may be wrong.
(ld.exe is the linker back-end that g++ calls.)

Your could post the command-line log here.

websnake:
so now i found there was a output file but it just disappered in few sec windows was not giving me any access to that file.

http://www.youtube.com/watch?v=rTJdvZOaOBY


thats why i can't see main.exe on that drive so finally it looks like it's a Mingw problem so anyone have any suggestions for that (any mingw
alternatives or anything else which will take place of mingw or a solution of the problem i am facing).

if i have wrong compiler and debugger settings then how can i resolve it?

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version